I am currently developing a React component that leverages the Material UI Tooltip component. Within my component, I need to manually re-position the Mui Tooltip via the root popper element (MuiTooltip-popper).
But, the Mui Tooltip is rendered with a handful of inline CSS properties out-of-the-box:
position: absolute;
transform: translate3d(792px, 68px, 0px);
top: 0px;
left: 0px;
will-change: transform;
If one attempts to provide new styles to replace these within the style attribute, the properties are simply not applied - they vanish completely. If one attempts to provide replacement styles via a class (e.g. via the CSS-in-JS approach advocated by Material UI), these styles are not applied as the inline style has precedence.
I have been able to overwrite the styles using the !important flag in my CSS class. However, doesn't feel like a very elegant solution. Is there a more "clean" way I can overwrite the styles?