mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-15 02:11:05 +00:00
chore: add more prop annotations
This commit is contained in:
parent
8c1ffd4cb0
commit
773b18d314
75 changed files with 877 additions and 137 deletions
|
@ -1,14 +1,29 @@
|
|||
<script>
|
||||
export let selectedIndex = -1;
|
||||
export let open = false;
|
||||
|
||||
/**
|
||||
* Set to `true` to use the inline variant
|
||||
* @type {boolean} [inline=false]
|
||||
*/
|
||||
export let inline = false;
|
||||
|
||||
/**
|
||||
* Set to `true` to enable the light variant
|
||||
* @type {boolean} [light=false]
|
||||
*/
|
||||
export let light = false;
|
||||
export let disabled = false;
|
||||
export let invalid = false;
|
||||
export let items = [];
|
||||
export let itemToString = item => item.text || item.id;
|
||||
export let itemToString = (item) => item.text || item.id;
|
||||
export let type = "default"; // "default" | "inline"
|
||||
export let size = undefined; // "sm" | "lg" | "xl"
|
||||
|
||||
/**
|
||||
* Set an id for the list box component
|
||||
* @type {string} [id]
|
||||
*/
|
||||
export let id = "ccs-" + Math.random().toString(36);
|
||||
export let name = undefined;
|
||||
export let invalidText = "";
|
||||
|
@ -24,7 +39,7 @@
|
|||
ListBox,
|
||||
ListBoxMenu,
|
||||
ListBoxMenuIcon,
|
||||
ListBoxMenuItem
|
||||
ListBoxMenuItem,
|
||||
} from "../ListBox";
|
||||
|
||||
let selectedId = undefined;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue