import { type EventEmitter } from '../../stencil-public-runtime'; import { type IconName } from '../mud-icon/mud-icon.types'; import type { SidebarItemBadgeVariant, SidebarItemSelectDetail, SidebarItemToggleDetail } from './mud-sidebar.types'; /** * Sidebar item — a single navigation row inside a `mud-sidebar` / `mud-sidebar-group`. * * Renders as a link when `href` is set, otherwise a button. Expandable items * toggle a nested list (the `children` slot) and rotate a chevron. * * @element mud-sidebar-item * @slot - The primary label (overrides the `label` prop). * @slot children - Nested `mud-sidebar-item` elements revealed when expanded. * @part item - The interactive row. */ export declare class MudSidebarItem { /** Value reported when the item is activated. */ value?: string; /** Leading icon name. Rendered filled while the item is active, where the icon has a filled drawing. */ icon?: IconName; /** Primary label (overridden by slotted content). */ label?: string; /** Optional right-aligned secondary label. */ secondary?: string; /** Optional trailing tag text (rendered as an outlined `mud-tag`). */ tag?: string; /** Optional trailing numbered badge count. */ badge?: number; /** * How the `badge` count is drawn: `neutral` is Figma's grey numbered badge, * `notification` its red notification badge (a danger `mud-badge`). * @default 'neutral' */ badgeVariant: SidebarItemBadgeVariant; /** Render as a link to this destination. */ href?: string; /** Whether the item expands a nested list of children. */ expandable: boolean; /** Whether the nested list is expanded. */ expanded: boolean; /** Whether this item represents the current page/section. */ active: boolean; /** Whether the item is disabled. */ disabled: boolean; /** Collapsed (icon-only) rail — propagated by the parent `mud-sidebar`. @internal */ collapsed: boolean; /** * Whether the default slot holds a label of its own. Whitespace-only text does not count: an * expandable item is written with its nested items on separate lines, and that whitespace is * assigned to the default slot, which would otherwise hide the `label` fallback and leave the * button without a name. */ private hasLabelSlot; host: HTMLMudSidebarItemElement; /** Fired when a non-expandable item is activated. */ mudSelect: EventEmitter; /** Fired when an expandable item is expanded or collapsed. */ mudToggle: EventEmitter; componentWillLoad(): void; private hostHasLabelContent; private onLabelSlotChange; private handleClick; private renderBadge; private renderContent; render(): any; }