ItemGroup

Layout & Structure
stable

Renderless selection container that tracks which child OrigamItem elements are selected. Single, multiple and mandatory selection modes.

Structure

Anatomy

Visual breakdown of the component's internal structure with BEM class call-outs.

Anatomy of OrigamItemGroupSchematic of the ItemGroup renderless container with three child items. origam-item ① origam-item ② selected origam-item ③ 1 origam-item-group 2 3
Anatomy of <origam-item-group> — renderless root (①) wrapping child <origam-item> elements (②③). The selected item carries the selectedClass.
1.origam-item-group
Root element. Renderless — no visual chrome. Provides group context via ORIGAM_ITEM_GROUP_KEY.
2origam-item (unselected)
Child item not currently selected. Exposes isSelected=false to its default slot.
3origam-item (selected)
Child item that is currently selected. Receives selectedClass and exposes isSelected=true.

API

Props

All props accepted by this component, with their type, default value and description.

id
string
class
string | Array<string> | object
style
string | Array<string> | object | StyleValue
tag
string
'div'
Root HTML element tag.
disabled
boolean
false
Disables all items in the group.
modelValue
any
Currently selected item value(s). Bind with v-model.
multiple
boolean
false
Allows multiple items to be selected at once.
mandatory
boolean
false
Forces at least one item to remain selected. Deselecting the last item is ignored.
max
number
Maximum number of simultaneously selected items (multiple mode only).
selectedClass
string
'origam-item--selected'
CSS class injected on each OrigamItem when it is selected. Propagated down via OrigamDefaultsProvider.

API

Slots

Content slots exposed by this component.

#default
Default slot. Exposes group selection helpers: isSelected(id), select(id, value), next(), prev(), selected (read-only ref).

API

Emits

Events emitted by this component.

@update:modelValue
any
Emitted when the selected item(s) change. Carries the new value or array of values.

API

Exposed members

Properties and methods accessible via template ref (defineExpose). Use them for programmatic control.

<T extends object>(props: T, exclude?: string[]) => Partial<T>
Utility to forward a filtered subset of props to a child.
() => void
Selects the next item in DOM order.
() => void
Selects the previous item in DOM order.
(id: number, value: boolean) => void
Programmatically toggle the selected state of an item by its internal id.
Ref<string>
Reactive CSS string generated by useStyle.
string
Unique style-sheet ID for this instance.
() => void
Injects the computed style sheet. Called automatically on mount.
() => void
Removes the injected style sheet. Called automatically on unmount.
Ref<boolean>
True once the style sheet has been injected into the DOM.

Inclusion

Accessibility

ARIA roles, keyboard navigation and focus management. Sourced from the real component template.

Keyboard interactions

Keyboard interactions
KeyAction
TabMoves focus through the child items. Keyboard navigation is delegated to the rendered child elements (e.g. origam-btn with role="button").

Notes

  • OrigamItemGroup is renderless and carries no ARIA role itself. Consumers must ensure the rendered children have appropriate roles (button, tab, radio, etc.).
  • The selectedClass is injected as a CSS class — not an ARIA attribute. Consumers are responsible for mapping the selected state to aria-pressed, aria-selected or aria-checked on their child elements.

Interactive

Playground

Edit props live and see the component update in real time. The generated code snippet updates as you change values.

Rendering the live preview…

Usage

Examples

Ready-to-paste code snippets for your templates.

Single selection

vue

Multiple selection

vue

Ecosystem

Family

Components from the same folder that share conventions and often compose together.