gradio/js/dropdown/Dropdown.stories.svelte
Abubakar Abid 933db53e93
Better handling of empty dataframe in gr.DataFrame (#5256)
* better handling of empty dataframe

* add changeset

* hide comments

* add changeset

* remove

* lint

* null case

* add stories

* stories

* lint

---------

Co-authored-by: gradio-pr-bot <gradio-pr-bot@users.noreply.github.com>
2023-08-18 08:20:02 -07:00

61 lines
1.1 KiB
Svelte

<script>
import { Meta, Template, Story } from "@storybook/addon-svelte-csf";
import Dropdown from "./shared/Dropdown.svelte";
</script>
<Meta
title="Components/Dropdown"
component={Dropdown}
argTypes={{
multiselect: {
control: [true, false],
description: "Whether to autoplay the video on load",
name: "multiselect",
value: false
}
}}
/>
<Template let:args>
<Dropdown {...args} />
</Template>
<Story
name="Single-select"
args={{
value: "swim",
choices: ["run", "swim", "jump"],
multiselect: false,
label: "Single-select Dropdown"
}}
/>
<Story
name="Single-select Static"
args={{
value: "swim",
choices: ["run", "swim", "jump"],
multiselect: false,
disabled: true,
label: "Single-select Dropdown"
}}
/>
<Story
name="Multiselect"
args={{
value: ["swim", "run"],
choices: ["run", "swim", "jump"],
label: "Multiselect Dropdown",
multiselect: true
}}
/>
<Story
name="Multiselect Static"
args={{
value: ["swim", "run"],
choices: ["run", "swim", "jump"],
label: "Multiselect Dropdown",
multiselect: true,
disabled: true
}}
/>