Closed kuv2707 closed 2 weeks ago
Comment '@csoc-bot claim' to get this issue assigned or '@csoc-bot abandon' to get this issue unassigned.
@csoc-bot claim
@ritwik-69 This issue has been successfully assigned to you! 🚀
@csoc-bot claim
@realnilesh Sorry, maximum limit for assignees in this issue has reached. Please check other issues or contact a maintainer.
Description
The modal component in
library
directory was supposed to be as reusable as possible, but ended up catering to a particular use case. In other places where modals were needed, we made duplicate modals tailored to that use case only. All these modals have some common features which can be extracted into one actually reusable and configurable modal component.ESC
key closes the modal (tracked separately)Lets start with these for now. We should have a
ModalContainer
library component which accepts the following as props:We should have a context for the modal in the same way we have for toasts.
We should be able to use it like this:
Any action (click etc) on the buttons passed to the modal will close the modal.
Notes