diff --git a/src/ComboBox/ComboBox.Story.svelte b/src/ComboBox/ComboBox.Story.svelte index a54292b9..0568262b 100644 --- a/src/ComboBox/ComboBox.Story.svelte +++ b/src/ComboBox/ComboBox.Story.svelte @@ -30,7 +30,6 @@ } -

Currently, this component does not support items as slots.

items must be an array of objects; mandatory fields are `id` and `text`. @@ -47,8 +46,9 @@ size="small" on:click={() => { selectedIndex = 1; - }}> - Set item to 'Option 2' + }} + style="margin-top: 1rem;"> + Set item to "Option 2"

diff --git a/src/ComboBox/ComboBox.svelte b/src/ComboBox/ComboBox.svelte index c7ddd0c0..1bf2d029 100644 --- a/src/ComboBox/ComboBox.svelte +++ b/src/ComboBox/ComboBox.svelte @@ -137,6 +137,8 @@ change(1); } else if (key === 'ArrowUp') { change(-1); + } else if (key === 'Escape') { + open = false; } }} on:focus diff --git a/src/Dropdown/Dropdown.Story.svelte b/src/Dropdown/Dropdown.Story.svelte index 2e965c76..cdadcd22 100644 --- a/src/Dropdown/Dropdown.Story.svelte +++ b/src/Dropdown/Dropdown.Story.svelte @@ -21,7 +21,6 @@
{:else} -

Currently, this component does not support items as slots.

items must be an array of objects; mandatory fields are `id` and `text`. @@ -35,7 +34,7 @@ on:click={() => { selectedIndex = selectedIndex > -1 ? -1 : 1; }}> - {selectedIndex > -1 ? 'Clear selected item' : "Set item to 'Option 2'"} + {selectedIndex > -1 ? 'Clear selected item' : 'Set item to "Option 2"'}

diff --git a/src/Dropdown/Dropdown.stories.js b/src/Dropdown/Dropdown.stories.js index 6d3b9730..29ae9b30 100644 --- a/src/Dropdown/Dropdown.stories.js +++ b/src/Dropdown/Dropdown.stories.js @@ -26,10 +26,6 @@ export const Default = () => ({ disabled: boolean("Disabled (disabled)", false), light: boolean("Light variant (light)", false), titleText: text("Title (titleText)", "This is not a dropdown title."), - helperText: text( - "Helper text (helperText)", - "This is not some helper text." - ), invalid: boolean("Show form validation UI (invalid)", false), invalidText: text( "Form validation UI content (invalidText)",