-
Notifications
You must be signed in to change notification settings - Fork 14
Open
Labels
bugAn issue describing unexpected or malicious behaviour.An issue describing unexpected or malicious behaviour.confirmedThis label indicates that the issue has been reproduced and verified by the core team.This label indicates that the issue has been reproduced and verified by the core team.has workaroundA workaround exists to handle the issue until it is fixed.A workaround exists to handle the issue until it is fixed.
Description
Prerequisites
- I know how to contribute a proper bug report.
- I agree to follow the Code of Conduct.
- I have searched for existing issues that already report this problem, without success.
Liquid version
5.14.0
Framework bindings
React
Current behavior
LdModal calls ldmodalclosed 2 times on modal close.
Expected behavior
LdModal calls ldmodalclosed 1 time on modal close.
Steps to reproduce
code like this reveals is
const modalRef = useRef(null)
return (
<>
<LdModal blurryBackdrop ref={modalRef} onLdmodalclosed={() => alert('Modal closed')}>
<LdTypo style={{ textAlign: 'center' }}>I'm a modal dialog.</LdTypo>
</LdModal>
<LdButton onClick={() => modalRef.current.showModal()}>
Open Modal
</LdButton>
</>
)Code reproduction URL
https://stackblitz.com/edit/github-lmnmdfxu?file=src%2FApp.tsx
Additional information
No response
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugAn issue describing unexpected or malicious behaviour.An issue describing unexpected or malicious behaviour.confirmedThis label indicates that the issue has been reproduced and verified by the core team.This label indicates that the issue has been reproduced and verified by the core team.has workaroundA workaround exists to handle the issue until it is fixed.A workaround exists to handle the issue until it is fixed.