mirror of
https://github.com/gradio-app/gradio.git
synced 2024-12-21 02:19:59 +08:00
ec28b4e7c4
* add tabs params and visible logic * add disabled logic * add tabbed_interface logic * add tab accessibility improvements * Add aria-disabled attribute to tab buttons * add e2e test * add changeset * add changeset * add tab e2e test * formatting * run generate_notebooks.py * lint * ensure tabs values update * remove tabbedinterface logic * Remove unused parameters from TabbedInterface constructor * remove test * add test * add changeset * formatting --------- Co-authored-by: gradio-pr-bot <gradio-pr-bot@users.noreply.github.com>
27 lines
548 B
Svelte
27 lines
548 B
Svelte
<script lang="ts">
|
|
import type { Gradio, SelectData } from "@gradio/utils";
|
|
import TabItem from "./shared/TabItem.svelte";
|
|
|
|
export let elem_id = "";
|
|
export let elem_classes: string[] = [];
|
|
export let label: string;
|
|
export let id: string | number;
|
|
export let gradio: Gradio<{
|
|
select: SelectData;
|
|
}>;
|
|
export let visible = true;
|
|
export let interactive = true;
|
|
</script>
|
|
|
|
<TabItem
|
|
{elem_id}
|
|
{elem_classes}
|
|
name={label}
|
|
{visible}
|
|
{interactive}
|
|
{id}
|
|
on:select={({ detail }) => gradio.dispatch("select", detail)}
|
|
>
|
|
<slot />
|
|
</TabItem>
|