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
12
types/Dropdown/Dropdown.d.ts
vendored
12
types/Dropdown/Dropdown.d.ts
vendored
|
@ -81,6 +81,18 @@ export interface DropdownProps extends svelte.JSX.HTMLAttributes<HTMLElementTagN
|
|||
*/
|
||||
invalidText?: string;
|
||||
|
||||
/**
|
||||
* Set to `true` to indicate an warning state
|
||||
* @default false
|
||||
*/
|
||||
warn?: boolean;
|
||||
|
||||
/**
|
||||
* Specify the warning state text
|
||||
* @default ""
|
||||
*/
|
||||
warnText?: string;
|
||||
|
||||
/**
|
||||
* Specify the helper text
|
||||
* @default ""
|
||||
|
|
1
types/FluidForm/FluidForm.d.ts
vendored
1
types/FluidForm/FluidForm.d.ts
vendored
|
@ -8,5 +8,6 @@ export default class FluidForm {
|
|||
default: {};
|
||||
};
|
||||
|
||||
$on(eventname: "submit", cb: (event: WindowEventMap["submit"]) => void): () => void;
|
||||
$on(eventname: string, cb: (event: Event) => void): () => void;
|
||||
}
|
||||
|
|
12
types/ListBox/ListBox.d.ts
vendored
12
types/ListBox/ListBox.d.ts
vendored
|
@ -41,6 +41,18 @@ export interface ListBoxProps extends svelte.JSX.HTMLAttributes<HTMLElementTagNa
|
|||
* @default ""
|
||||
*/
|
||||
invalidText?: string;
|
||||
|
||||
/**
|
||||
* Set to `true` to indicate an warning state
|
||||
* @default false
|
||||
*/
|
||||
warn?: boolean;
|
||||
|
||||
/**
|
||||
* Specify the warning state text
|
||||
* @default ""
|
||||
*/
|
||||
warnText?: string;
|
||||
}
|
||||
|
||||
export default class ListBox {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue