WTTJ/welcome-ui

[Modal] isn't visible when we update the state during the opening

mleralec opened this issue ยท 0 comments

[Design] For which Figma library?

None

For which component/foundations?

Modal

Prioritization

High ๐ŸŒ‹

Current Behavior

When we open the modal and updating a state at the same time, the modal doesn't open (but the backdrop yes).

The data-enter attribute is forwarded to the Backdrop component but not to the Modal and the opacity remains at 0.

Reproduce:

  1. open https://codesandbox.io/s/bug-modal-while-updating-state-y544rd?file=/src/App.tsx
  2. click on the button to open the modal
  3. the backdrop is visible but not the modal

Expected Behavior

The data-enter attribute is forwarded to the Modal component too.

Screenshots / Videos

https://codesandbox.io/s/bug-modal-while-updating-state-y544rd?file=/src/App.tsx

[Tech] Welcome UI Version

5.0.5

[Tech] Browser

Google Chrome 118.0

[Tech] Operating System

MacOS