/** * Copyright Aquera Inc 2023 * * This source code is licensed under the BSD-3-Clause license found in the * LICENSE file in the root directory of this source tree. */ import { TemplateResult } from 'lit'; import '../nile-icon-button/nile-icon-button'; import NileElement from '../internal/nile-element'; import type { CSSResultGroup, PropertyValueMap } from 'lit'; /** * Nile icon component. * * @tag nile-tab-group * * @slot - Used for grouping tab panels in the tab group. Must be `` elements. * @slot nav - Used for grouping tabs in the tab group. Must be `` elements. * * @event {{ name: String }} nile-tab-show - Emitted when a tab is shown. * @event {{ name: String }} nile-tab-hide - Emitted when a tab is hidden. * * @csspart base - The component's base wrapper. * @csspart nav - The tab group's navigation container where tabs are slotted in. * @csspart tabs - The container that wraps the tabs. * @csspart active-tab-indicator - The line that highlights the currently selected tab. * @csspart body - The tab group's body where tab panels are slotted in. * @csspart scroll-button - The previous/next scroll buttons that show when tabs are scrollable, an ``. * @csspart scroll-button--start - The starting scroll button. * @csspart scroll-button--end - The ending scroll button. * @csspart scroll-button__base - The scroll button's exported `base` part. * * @cssproperty --indicator-color - The color of the active tab indicator. * @cssproperty --track-color - The color of the indicator's track (the line that separates tabs from panels). * @cssproperty --track-width - The width of the indicator's track (the line that separates tabs from panels). * */ export declare class NileTabGroup extends NileElement { static styles: CSSResultGroup; private activeTab?; private mutationObserver; private resizeObserver; private tabs; private panels; tabGroup: HTMLElement; body: HTMLSlotElement; nav: HTMLElement; indicator: HTMLElement; hasScrollControls: boolean; /** The placement of the tabs. */ placement: 'top' | 'bottom' | 'start' | 'end'; /** The placement of the tabs. */ activeTabProp: string; /** Track for showing Indicators and Background. */ noTrack: boolean; /** * When set to auto, navigating tabs with the arrow keys will instantly show the corresponding tab panel. When set to * manual, the tab will receive focus but will not show until the user presses spacebar or enter. */ activation: 'auto' | 'manual'; /** Disables the scroll arrows that appear when tabs overflow. */ noScrollControls: boolean; /** Controls whether tabs are centered and have equal width */ centered: boolean; activeTabName: string; connectedCallback(): void; disconnectedCallback(): void; protected firstUpdated(_changedProperties: PropertyValueMap | Map): void; protected updated(_changedProperties: PropertyValueMap | Map): void; syncIndicator(): void; render(): TemplateResult<1>; private getAllTabs; private getAllPanels; private getActiveTab; private handleClick; setScrollControls(): void; private handleKeyDown; private handleScrollToStart; private handleScrollToEnd; private setActiveTab; private setAriaLabels; private repositionIndicator; private syncTabsAndPanels; private handleToggleFromTab; } export default NileTabGroup; declare global { interface HTMLElementTagNameMap { 'nile-tab-group': NileTabGroup; } }