Tabs builder
A row of tabs. The strip publishes one [`Role::Tab`] node per tab.
A builder is RenderOnce. Construct and mount it in one expression.
use gpui_kit::navigation::Tabs;
Construct
new(ident: impl Into<Ident>) -> SelfOptions
Chain onto the value.
tab(tab: TabItem) -> Self
tabs(tabs: impl IntoIterator<Item = TabItem>) -> Self
selected(id: impl Into<SharedString>) -> Self
on_select(handler: impl Fn(SharedString, &mut Window, &mut App) + 'static) -> Self
on_close(handler: impl Fn(SharedString, &mut Window, &mut App) + 'static) -> Self
overflow_after(count: usize) -> Self
overflow_menu(menu: Entity<Menu>) -> Self
reorderable(reorderable: bool) -> Self
accepts(predicate: impl Fn(&DragItem, &DropPosition) -> bool + 'static) -> Self
on_reorder(handler: impl Fn(&DropIntent, &mut Window, &mut App) + 'static) -> SelfRendered by
Each of these compiles and is captured by the gate, so the code behind them is verified rather than written.