Plugins

Covers Engine Plugin SDK 2.0.0 · Interface Plugin SDK 0.2.0

Tabs

Tabs using the host's tabbed content presentation.

Import

import { Tabs } from "@dartwic/interface-sdk/ui";

Declaration

export const Tabs: HostComponent<TabsProps>;

TabsProps

Props accepted by the tabs root.

export interface TabsProps extends HostComponentProps {
    /** Controlled active tab value. */
    value?: string;
    /** Initial uncontrolled tab value. */
    defaultValue?: string;
    /** Called when the active tab changes. */
    onValueChange?: (value: string) => void;
}
PropTypeRequirementDescription
valuestringOptionalControlled active tab value.
defaultValuestringOptionalInitial uncontrolled tab value.
onValueChange(value: string) => voidOptionalCalled when the active tab changes.
classNamestringOptionalAdditional Tailwind or host CSS classes.
childrenHostNodeOptionalChild content rendered by the host component.
idstringOptionalOptional DOM identifier.
styleRecord<string, unknown>OptionalInline style values passed to the host component.