Tabs
Tabs are used to show different views or sections of content within the same context.
Figma Link
- Web Components
- Flutter
Demo
zeta-web v0.12.9
Web Components
A tab item to be used in a zeta-tab-bar
Storybook
https://design.zebra.com/web/storybook/?path=/docs/components-tab-bar--docs
Slots
| Name | Description | Type |
|---|---|---|
| default | The content of the menu item. | text |
Attributes
| Name | Description | Type | Default |
|---|---|---|---|
| active | boolean | false | |
| selected | boolean | false |
Inherited Attributes
| Name | Description | Type | Default | Inherited From |
|---|---|---|---|---|
| rounded | Whether the component is rounded or sharp.When true, rounded will set the border radius of the first child, and any children with class 'contourable-target' to --radius-minimal.Otherwise, this value will be --radius-none. | boolean | undefined | true | Contourable |
| disabled | Boolean for if component is disabled.This will apply disabled styles. | boolean | false | Interactive |
| tabIndex | The tab index of the component, used to determine the order in which elements receive focus when the user navigates through the document by pressing the Tab key. | number | 0 | Interactive |
Demo
Widgetbook
https://design.zebra.com/flutter/widgetbook/index.html#/?path=components/tabs/zetatab/tab-item
Inheritance
Object > DiagnosticableTree > Widget > StatelessWidget > Tab
Constructors
Creates a Zeta Design tab bar.
ZetaTab.new({Widget? icon, String? text, Key? key})
Properties
| Name | Description | Type | Features |
|---|---|---|---|
| child | The widget to be used as the tab's label. | Widget? | final inherited |
| hashCode | The hash code for this object. | int | no setter inherited |
| height | The height of the Tab. | double? | final inherited |
| icon | An icon to display as the tab's label. | Widget? | final inherited |
| iconMargin | The margin added around the tab's icon. | EdgeInsetsGeometry? | final inherited |
| key | Controls how one widget replaces another widget in the tree. | Key? | final inherited |
| preferredSize | The size this widget would prefer if it were otherwise unconstrained. | Size | no setter inherited |
| runtimeType | A representation of the runtime type of the object. | Type | no setter inherited |
| text | The text to display as the tab's label. | String? | final inherited |