packages/components/eui-tabs/eui-tab-header/eui-tab-header.component.ts
Custom header content component for individual tabs within eui-tabs. Allows projection of custom content into the tab header area using CDK Portal. Enables rich tab headers with icons, badges, or custom layouts beyond simple text labels. Must be used as a child of eui-tab component to provide custom header content.
<eui-tab>
<eui-tab-header>
<eui-tab-header-label>Settings</eui-tab-header-label>
</eui-tab-header>
<eui-tab-body>Content</eui-tab-body>
</eui-tab><eui-tab>
<eui-tab-header>
<eui-tab-header-left-content>
<eui-icon-svg icon="eui-notification" size="s" />
</eui-tab-header-left-content>
<eui-tab-header-label>Notifications</eui-tab-header-label>
<eui-tab-header-sub-label>Unread messages</eui-tab-header-sub-label>
<eui-tab-header-right-content>
<eui-badge euiDanger>5</eui-badge>
</eui-tab-header-right-content>
</eui-tab-header>
<eui-tab-body>Content</eui-tab-body>
</eui-tab><eui-tab>
<eui-tab-header>
<eui-tab-header-left-content>
<eui-avatar [imageUrl]="user.avatar" euiSizeXs />
</eui-tab-header-left-content>
<div>
<eui-tab-header-label>{{ user.name }}</eui-tab-header-label>
<eui-tab-header-sub-label>{{ user.role }}</eui-tab-header-sub-label>
</div>
</eui-tab-header>
<eui-tab-body>Content</eui-tab-body>
</eui-tab>
| selector | eui-tab-header |
| templateUrl | ./eui-tab-header.component.html |
Properties |
|
| Public templatePortal |
Type : TemplatePortal
|
| templateRef |
Type : TemplateRef<HTMLElement>
|
Decorators :
@ViewChild('templateRef')
|