mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-16 10:51:06 +00:00
feat(modal): support primaryButtonIcon prop (#1047)
This commit is contained in:
parent
f53b5472e5
commit
a8039a4d1e
8 changed files with 96 additions and 31 deletions
|
@ -42,3 +42,6 @@ Use the `secondaryButtons` prop to render two secondary buttons for a "3-button
|
|||
|
||||
<FileSource src="/framed/Modal/ModalPreventOutsideClick" />
|
||||
|
||||
### Button with icon
|
||||
|
||||
<FileSource src="/framed/Modal/ModalButtonWithIcon" />
|
||||
|
|
14
docs/src/pages/framed/Modal/ModalButtonWithIcon.svelte
Normal file
14
docs/src/pages/framed/Modal/ModalButtonWithIcon.svelte
Normal file
|
@ -0,0 +1,14 @@
|
|||
<script>
|
||||
import { Modal } from "carbon-components-svelte";
|
||||
import Send16 from "carbon-icons-svelte/lib/Send16";
|
||||
</script>
|
||||
|
||||
<Modal
|
||||
open
|
||||
modalHeading="Invite someone"
|
||||
primaryButtonText="Send invitation"
|
||||
primaryButtonIcon="{Send16}"
|
||||
secondaryButtonText="Cancel"
|
||||
>
|
||||
<p>Do you really want to invite someone?</p>
|
||||
</Modal>
|
Loading…
Add table
Add a link
Reference in a new issue