-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Feat(web-twig): ModalHeader hide close button prop DS-1063
- New prop for ModalHeader to hide the close button - New prop for disable escape key to close the modal - Added new demo with those new props
- Loading branch information
1 parent
ebb878c
commit 4ffd63d
Showing
7 changed files
with
125 additions
and
25 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
33 changes: 33 additions & 0 deletions
33
packages/web-twig/src/Resources/components/Modal/stories/ModalHiddenCloseButton.twig
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
<Button data-spirit-toggle="modal" data-spirit-target="#example-hidden-close-button"> | ||
Open Modal | ||
</Button> | ||
|
||
<Modal id="example-hidden-close-button" titleId="example-hidden-close-button-title" closeOnBackdropClick={ false } closeOnEscapeKeyDown={ false }> | ||
<ModalDialog> | ||
<ModalHeader modalId="example-hidden-close-button" titleId="example-hidden-close-button-title" hasCloseButton={ false }> | ||
Modal Title | ||
</ModalHeader> | ||
<ModalBody> | ||
<p> | ||
Lorem ipsum dolor sit amet, consectetur adipisicing elit. Aliquam at excepturi laudantium magnam mollitia | ||
perferendis reprehenderit, voluptate. Cum delectus dicta ducimus eligendi excepturi natus perferendis | ||
provident unde. Eveniet, iste, molestiae? | ||
</p> | ||
</ModalBody> | ||
<ModalFooter> | ||
<Button | ||
data-spirit-dismiss="modal" | ||
data-spirit-target="#example-hidden-close-button" | ||
> | ||
Primary action | ||
</Button> | ||
<Button | ||
color="secondary" | ||
data-spirit-dismiss="modal" | ||
data-spirit-target="#example-hidden-close-button" | ||
> | ||
Secondary action | ||
</Button> | ||
</ModalFooter> | ||
</ModalDialog> | ||
</Modal> |