Documentation
Design
Components
Tabs

EccUtilsDesignTabs Component

2.0.0-alpha.6
<ecc-utils-design-tabs/>
EccUtilsDesignTabs

Overview

The ecc-utils-design-tabs component provides a way to display content in a tabbed interface, allowing users to switch between different views within the same context. It is a compound component that gives you control over the tab list and content panels.

This component is composed of Tabs, TabsList, TabsTrigger, and TabsContent to create a complete tabbed interface.

Usage

Basic Tabs

This example shows a basic tabbed interface with two tabs.

AccountPassword

This is the account tab.

This is the password tab.

Components

ComponentTag NameDescription
Tabsecc-utils-design-tabsThe root container for the tabs.
TabsListecc-utils-design-tabs-listThe container for the tab triggers.
TabsTriggerecc-utils-design-tabs-triggerA button to activate a specific tab.
TabsContentecc-utils-design-tabs-contentThe content panel associated with a tab.

Properties

EccUtilsDesignTabs

PropertyTypeDefaultDescription
defaultValuestring""The value of the tab to be active on initial render.
valuestring""The controlled value of the active tab.

defaultValue

Sets which tab is active when the component first loads. Should match the value of one of the TabsTrigger components.

<EccUtilsDesignTabs defaultValue="account">
  ...
</EccUtilsDesignTabs>

value

Controls which tab is currently active. Used for controlled components where you manage the state externally.

<EccUtilsDesignTabs value={currentTab}>
  ...
</EccUtilsDesignTabs>

EccUtilsDesignTabsTrigger

PropertyTypeDefaultDescription
valuestring""A unique value for the tab trigger.
disabledbooleanfalseWhen true, disables the tab trigger.

value

A unique identifier for the tab trigger. This value must match the corresponding TabsContent value.

<EccUtilsDesignTabsTrigger value="account">Account</EccUtilsDesignTabsTrigger>

disabled

When true, prevents the tab from being activated and visually indicates it's unavailable.

<EccUtilsDesignTabsTrigger value="premium" disabled={true}>Premium</EccUtilsDesignTabsTrigger>

EccUtilsDesignTabsContent

PropertyTypeDefaultDescription
valuestring""A unique value for the tab content.

value

A unique identifier for the tab content. This value must match the corresponding TabsTrigger value.

<EccUtilsDesignTabsContent value="account">
  Account content goes here...
</EccUtilsDesignTabsContent>

Events

EccUtilsDesignTabs

Event NameReact Event NameDetail TypeDescription
ecc-input-changedonEccInputChanged{ value: string }Fired when the active tab changes.

ecc-input-changed

This event is fired when the user clicks on a new tab trigger.

<EccUtilsDesignTabs 
  onEccInputChanged={(event) => {
    console.log('Active tab:', event.detail.value);
  }}
>
  ...
</EccUtilsDesignTabs>
Elixir Cloud & AAICloud SDKElixir

Released under Apache 2.0 License.

Copyright © 2023-2025 ELIXIR