Slide

Media
stable

Horizontally scrollable slide group with drag scroll, keyboard navigation and optional arrow controls.

Structure

Anatomie

Décomposition visuelle de la structure interne du composant avec les appels de classes BEM.

Anatomy of OrigamSlideGroupSchematic of the SlideGroup component with 4 numbered internal parts. prev item 1 item 2 item 3 next 1 2 3 4 origam-slide-group
Anatomy of <origam-slide-group> — 4 internal parts: root container ①, prev affix ②, scrollable container ③, next affix ④.
1.origam-slide-group
Root flex container. Clips overflow to hide off-screen items.
2.origam-slide-group__prev
Previous arrow affix. Rendered only when showArrows is active. Hosts the #prev slot or a default OrigamIcon.
3.origam-slide-group__container
Scrollable viewport. overflow: hidden with scroll event handling for arrow state.
4.origam-slide-group__next
Next arrow affix. Rendered only when showArrows is active. Hosts the #next slot or a default OrigamIcon.

API

Props

Toutes les props acceptées par ce composant, avec leur type, valeur par défaut et description.

centerActive
boolean
false
When true, the active item is scrolled to the center of the container.
nextIcon
'mdi-chevron-right'
Icon for the "next" navigation arrow.
prevIcon
'mdi-chevron-left'
Icon for the "previous" navigation arrow.
showArrows
boolean | 'always'
false
Controls arrow visibility. false = hidden, true = shown when needed, 'always' = always visible.
tag
string
'div'
HTML element rendered at the root.
direction
'horizontal'
Scroll axis. horizontal (default) or vertical.
modelValue
string | number | string[] | number[]
The currently selected item value (or array for multi-select). Synced via v-model.
multiple
boolean
false
Allows multiple items to be selected simultaneously.
displayLevel
Responsive breakpoint below which the component is hidden.
border
boolean | string
false
Applies a border to the slide group container.
Border-radius token or boolean.

API

Slots

Emplacements de contenu exposés par ce composant.

#default
Container for slide items. Slot props expose selection helpers for child items.
#prev
Replaces the previous arrow button with custom content.
#next
Replaces the next arrow button with custom content.

API

Emits

Événements émis par ce composant.

@update:modelValue
string | number | string[] | number[]
Emitted when the selected item changes. Syncs with v-model.

API

Membres exposés

Propriétés et méthodes accessibles via ref template (defineExpose). Utilisés pour le contrôle programmatique.

<T extends object>(props: T, exclude?: string[]) => Partial<T>
Utility to forward a filtered subset of props to a child component.
Ref<string>
Reactive CSS string generated by useStyle.
string
Unique style-sheet ID for this instance.
() => void
Injects the computed style sheet into the document.
() => void
Removes the injected style sheet.
Ref<boolean>
True once the style sheet has been injected into the DOM.

Personnalisation

Variables CSS

Propriétés CSS personnalisées exposées par ce composant. Surchargez-les pour personnaliser sans perdre la compatibilité avec le thème.

Root display mode.
Root overflow clipping.
Scroll animation duration.
Minimum width of the prev/next arrow affixes.

Inclusion

Accessibilité

Rôles ARIA, navigation clavier et gestion du focus. Sourcé depuis le template réel du composant.

Rôles ARIA

group (implicit via scroll container)

Interactions clavier

Interactions clavier
ToucheAction
Arrow Left / RightMoves focus between items inside the scroll container.
TabFocuses the slide group container, then Tab moves through items.
Home / EndJumps focus to the first or last item.

Notes

  • The scroll container is keyboard-accessible. Arrow keys trigger programmatic scrollTo calls for cross-browser scroll support.

Fondation

Design tokens

Extrait des tokens de ce composant — les variables --origam-<composant>---<propriété>, déclarées dans sa feuille de tokens tenue à la main, sans étape de build.

Source
other
flex
Root display mode.
other
hidden
Root overflow.
duration
{motion.duration.medium}
Scroll transition duration.
dimension
52px
Minimum width of the prev/next arrow affixes.

Interactif

Playground

Modifiez les props en direct et observez le composant se mettre à jour. Le snippet de code généré suit vos changements.

Rendu de l’aperçu en cours…

Usage

Exemples

Extraits de code prêts à coller dans vos templates.

Basic slide group

vue

With selection

vue

Always show arrows

vue