Skip to content

Collapsible ​

An interactive component which expands/collapses a panel.

Usage ​

Approximate web preview — the HarmonyOS rendering is the reference.

Controlled ​

Bind open with !! like v-model:open.

Approximate web preview — the HarmonyOS rendering is the reference.

API ​

Extracted from the @Param / @Event / @BuilderParam declarations in the library sources.

SCollapsible ​

shadcn-vue Collapsible: an interactive component which expands / collapses a panel.

PropTypeDefaultDescription
open!!boolean | undefinedundefinedControlled open state (use with !!). Leave undefined for uncontrolled.
defaultOpenbooleanfalse
disabledbooleanfalseIgnore trigger taps.
EventTypeDefaultDescription
onOpenChange(open: boolean) => void() => { }

Slots: children (trailing closure)

SCollapsibleTrigger ​

Toggles the collapsible when its content is tapped.

Slots: children (trailing closure)

SCollapsibleContent ​

The panel; expands / collapses with a height animation.

Slots: children (trailing closure)

MIT Licensed