# SbAccordionItem A single collapsible item used within SbAccordion. ## Parameters | Parameter | Type | Default | Description | |-----------|------|---------|-------------| | Title | string | "" | Item title displayed in the header | | Disabled | bool | false | Whether the item is disabled | | DefaultExpanded | bool | false | Whether the item is initially expanded | ## Templates / Slots | Slot | Type | Description | |------|------|-------------| | Icon | RenderFragment | Icon displayed before the title | | Subtitle | RenderFragment | Subtitle displayed below the title (stacked vertically in the header) | | ChildContent | RenderFragment | Collapsible content | ## Cascading Parameters | Parameter | Type | Description | |-----------|------|-------------| | Parent | SbAccordion | Parent accordion container | ## CSS Classes - `sb-accordion-item` - Base class - `sb-accordion-item--expanded` - When item is expanded - `sb-accordion-item--disabled` - When item is disabled - `sb-accordion-item__header` - Header button - `sb-accordion-item__header-start` - Header start section - `sb-accordion-item__icon` - Icon container - `sb-accordion-item__title` - Title text - `sb-accordion-item__subtitle` - Subtitle text - `sb-accordion-item__chevron` - Expand/collapse indicator - `sb-accordion-item__content` - Content wrapper - `sb-accordion-item__content--expanded` - Expanded content - `sb-accordion-item__body` - Inner content container ## Accessibility - Uses `aria-expanded` to indicate expansion state - Uses `aria-controls` to link button to content - Content uses `hidden` attribute when collapsed ## Examples ### Basic Usage ```razor This content is revealed when expanded. ``` ### Initially Expanded ```razor This content is visible by default. This is collapsed by default. ``` ### With Icon ```razor ``` ### With Subtitle ```razor Visa ending in 4242 Update Payment Method ``` ### Disabled Item ```razor Basic features included. Requires premium subscription Advanced features content... @code { private bool isPremium = false; } ``` ### Complex Content ```razor 3 items $129.99 Item Qty Price @foreach (var item in orderItems) { @item.Name @item.Quantity @item.Price.ToString("C") } ``` ### Settings Panel ```razor English Spanish For developers only ```
This content is revealed when expanded.
This content is visible by default.
This is collapsed by default.
Basic features included.
Advanced features content...