UserDialog component bug within ShadowDOM #3527
-
Hi team, (continuing off #3196), when I encapsulate the UserDialog component into ShadowDOM, it only allows me to expand and collapse the UserDialogList once and then it remains hidden forever. I'm still unsure if this is a bug or if I'm doing something differently - would like to get some eyes on this issue. Thanks! I managed to reproduce this issue in this CodeSandbox: https://codesandbox.io/p/sandbox/paste-userdialog-in-shadowdom-6ssnln?file=%2Fsrc%2FApp.tsx%3A105%2C29 Update: The above issue does not happen if I close the popover by clicking outside or with esc key. It only happens when I attempt to close the popover with the arrow button. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 3 replies
-
So I managed to display the UserDialog by toggling "visible" in the component (I know its not ideal). However, I noticed there was another issue - the X coordinate of transform: translate(x,y) changes when closing UserDialog the second time. UserDialog will render outside of the screen/view the next time it opens out. Not sure what is causing the change in translate coordinates. CodeSandBox: https://codesandbox.io/p/sandbox/paste-userdialog-in-shadowdom-forked-spmsvr?file=%2Fsrc%2FApp.tsx%3A58%2C1-60%2C24 screen_recording.mp4 |
Beta Was this translation helpful? Give feedback.
-
Instead of relying on ShadowDOM support, I realize the easier workaround is to add/overwrite the CSS styles to address the styling differences. Closing this discussion. Thanks @TheSisb and @SiTaggart for the help 🚀 . |
Beta Was this translation helpful? Give feedback.
Instead of relying on ShadowDOM support, I realize the easier workaround is to add/overwrite the CSS styles to address the styling differences. Closing this discussion. Thanks @TheSisb and @SiTaggart for the help 🚀 .