Skip to content

Accordion Item

Child component of Accordion

API reference

Properties

PropertyAttributeDescriptionTypeDefault
descriptiondescriptionSpecifies a description for the component.string
expandedexpandedWhen true, the component is expanded.booleanfalse
headingheadingSpecifies heading text for the component.string
iconEndicon-endSpecifies an icon to display at the end of the component.string
iconFlipRtlicon-flip-rtlDisplays the iconStart and/or iconEnd as flipped when the element direction is right-to-left ("rtl")."both" | "end" | "start"
iconStarticon-startSpecifies an icon to display at the start of the component.string

Slots

NameDescription
default (unnamed)A slot for adding custom content, including nested calcite-accordion-items.
actions-endA slot for adding calcite-actions or content to the end side of the component's header.
actions-startA slot for adding calcite-actions or content to the start side of the component's header.

Styles

NameDescription
--calcite-accordion-border-colorSpecifies the component's border color.
--calcite-accordion-background-colorSpecifies the component's background color.
--calcite-accordion-text-colorSpecifies the component's text color.
--calcite-accordion-text-color-hoverSpecifies the component's main text color on hover.
--calcite-accordion-text-color-pressSpecifies the component's main text color when pressed.
--calcite-accordion-item-background-color
deprecated Use --calcite-accordion-background-color. Specifies the component's background color.
--calcite-accordion-item-border-color
deprecated Use --calcite-accordion-border-color. Specifies the component's border color.
--calcite-accordion-item-content-spaceSpecifies the component's padding.
--calcite-accordion-item-end-icon-colorSpecifies the component's iconEnd color. Falls back to --calcite-accordion-item-icon-color or current color.
--calcite-accordion-item-expand-icon-colorSpecifies the component's expand icon color.
--calcite-accordion-item-header-background-colorSpecifies the component's heading background color.
--calcite-accordion-item-header-background-color-hoverSpecifies the component's heading background color when hovered.
--calcite-accordion-item-header-background-color-pressSpecifies the component's heading background color when pressed.
--calcite-accordion-item-heading-text-colorSpecifies the component's heading text color.
--calcite-accordion-item-icon-color
deprecated Use --calcite-icon-color. Specifies the component's default icon color.
--calcite-accordion-item-start-icon-colorSpecifies the component's iconStart color. Falls back to --calcite-accordion-item-icon-color or current color.
--calcite-accordion-item-text-color
deprecated Use --calcite-accordion-text-color. Specifies the component's text color.
--calcite-accordion-item-text-color-hover
deprecated Use --calcite-accordion-text-color-hover. Specifies the component's text color on hover.
--calcite-accordion-item-text-color-press
deprecated Use --calcite-accordion-text-color-press. Specifies the component's text color on press.

Events

Methods

NameDescriptionSignature
componentOnReadyCreate a promise that resolves once component is fully loaded.componentOnReady(): Promise<void>
setFocusSets focus on the component.setFocus(): Promise<void>

Your browser is no longer supported. Please upgrade your browser for the best experience. See our browser deprecation post for more details.