mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-18 19:46:36 +00:00
feat(dropdown): support warning state
This commit is contained in:
parent
8e5beeebad
commit
038dd3ad82
8 changed files with 112 additions and 6 deletions
|
@ -51,6 +51,18 @@ Use the `itemToString` prop to format the display of individual items.
|
|||
{id: "1", text: "Email"},
|
||||
{id: "2", text: "Fax"}]}" />
|
||||
|
||||
### Invalid state
|
||||
|
||||
<Dropdown invalid invalidText="Secondary contact method must be different from the primary contact" titleText="Contact" selectedIndex={0} items="{[{id: "0", text: "Slack"},
|
||||
{id: "1", text: "Email"},
|
||||
{id: "2", text: "Fax"}]}" />
|
||||
|
||||
### Warning state
|
||||
|
||||
<Dropdown warn warnText="This contact method is not associated with your account" titleText="Contact" selectedIndex={0} items="{[{id: "0", text: "Slack"},
|
||||
{id: "1", text: "Email"},
|
||||
{id: "2", text: "Fax"}]}" />
|
||||
|
||||
### Disabled state
|
||||
|
||||
<Dropdown disabled titleText="Contact" selectedIndex={0} items="{[{id: "0", text: "Slack"},
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue