Tabs
Tabs::make()->schema([...]) renders a tab strip of Tab::make('value', 'Label')->schema([...])
children. The active tab is kept in the URL query string, and a tab’s content renders lazily on first
open.
Tabs::make()->defaultValue('details')->schema([ Tab::make('details', 'Details')->schema([ Text::make('Team details go here.'), ]), Tab::make('history', 'History')->schema([ Text::make('Recent activity for the team.'), ]),]);- activeValue:"details"
- alignment:"stretch"
- defaultValue:"details"
- orientation:"horizontal"
- queryKey:"tabs"
- confirm:null
- label:"Details"
- value:"details"
- align:null
- color:"muted"
- copyable:false
- size:"md"
- text:"Team details go here."
- confirm:null
- label:"History"
- value:"history"
- align:null
- color:"muted"
- copyable:false
- size:"md"
- text:"Recent activity for the team."
Active tab and the URL
Section titled “Active tab and the URL”->defaultValue('details')picks the tab shown when the URL names none. Otherwise the first tab wins.->queryKey('tab')sets the query-string parameter that tracks the active tab (defaults totabs), so tabs survive reloads and are shareable by URL.
Orientation and alignment
Section titled “Orientation and alignment”->orientation(Orientation::Vertical)moves the strip to the side of the panels.->alignment(TabsAlignment::…)controls how the strip sits. Horizontal tabs default toStretch(tabs share the full width);Start,Center, andEndshrink the strip to its content and pin it left, center, or right. Vertical tabs only readEnd— it moves the strip to the right of the panels; every other value keeps it on the left.
See the enums reference for the full Orientation and TabsAlignment cases.