mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-18 03:26:36 +00:00
test(modal): test secondaryButtons prop, updated click:button--secondary custom event
This commit is contained in:
parent
78caefd4d4
commit
177250e8df
2 changed files with 8 additions and 2 deletions
|
@ -15,5 +15,10 @@
|
|||
<ModalBody hasForm>
|
||||
<Checkbox labelText="I have reviewed the changes" bind:checked />
|
||||
</ModalBody>
|
||||
<ModalFooter primaryButtonText="Proceed" primaryButtonDisabled="{!checked}" />
|
||||
<ModalFooter
|
||||
primaryButtonText="Proceed"
|
||||
primaryButtonDisabled="{!checked}"
|
||||
secondaryButtons="{[{ text: 'Cancel' }, { text: 'Duplicate' }]}"
|
||||
on:click:button--secondary="{({ detail }) => {}}"
|
||||
/>
|
||||
</ComposedModal>
|
||||
|
|
|
@ -10,8 +10,9 @@
|
|||
bind:open
|
||||
modalHeading="Create database"
|
||||
primaryButtonText="Confirm"
|
||||
secondaryButtons="{[{ text: 'Cancel' }, { text: 'Duplicate' }]}"
|
||||
secondaryButtonText="Cancel"
|
||||
on:click:button--secondary="{() => (open = false)}"
|
||||
on:click:button--secondary="{({ detail }) => (open = false)}"
|
||||
on:open
|
||||
on:close
|
||||
on:submit
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue