Tha gallery widget

This commit is contained in:
space-nuko
2023-04-07 12:13:03 -05:00
parent eed4e29004
commit f40e46d0c2
18 changed files with 246 additions and 40 deletions

View File

@@ -0,0 +1,29 @@
<script lang="ts">
import type { WidgetUIState } from "$lib/stores/widgetState";
import { Dropdown } from "@gradio/form";
export let item: WidgetUIState | null = null;
</script>
<div class="wrapper">
{#if item}
<Dropdown
bind:value={item.value}
choices={item.widget.options.values}
multiselect={false}
max_choices={1}
label={item.widget.name}
show_label={true}
disabled={item.widget.options.values.length === 0}
on:change
on:select
on:blur
/>
{/if}
</div>
<style>
.wrapper {
padding: 2px;
width: 100%;
}
</style>