Blockquote
Typographic citation component with five visual variants, author/source attribution and locale-aware decorative quote marks.
Aperçu
Rendu de l’aperçu en cours…
defaultRendu de l’aperçu en cours…
elegantRendu de l’aperçu en cours…
pullRendu de l’aperçu en cours…
minimalRendu de l’aperçu en cours…
quotedStructure
Anatomie
Décomposition visuelle de la structure interne du composant avec les appels de classes BEM.
<origam-blockquote> — 5 parts: root ①, accent bar ②, quote mark glyph ③ (variant="quoted" only), body ④, attribution footer ⑤ (author + source).- 1.origam-blockquote
- Root element. Defaults to
; overridable via tag. Carries variant, align, color and accent modifier classes.
- 2.origam-blockquote__mark--bg
- Decorative opening quote glyph. Absolute, z-index 0, opacity ~0.08. Rendered when the quoteMark prop is on — the quoted variant preset turns it on, and it is reachable on any variant.
- 3.origam-blockquote__body
- Citation body wrapper. Raised to z-index 1 by a sibling selector whenever the decorative glyph is present, so the text sits above it.
- 4.origam-blockquote__attribution
- Footer
- 5.origam-blockquote__source
- element wrapping the source label. Receives source---color token for secondary italic styling.
API
Props
Toutes les props acceptées par ce composant, avec leur type, valeur par défaut et description.
- Visual variant: "default" = left accent bar, "elegant" = serif italic, "quoted" = decorative glyph background, "pull" = centered large pull quote with top/bottom rules, "minimal" = thin bar with smaller text.
- authorstring
- Author of the citation rendered as "— Author" in the attribution footer. Can be overridden via the #author slot.
- sourcestring
- Source label (book, publication, URL label) appended after the author as ", Source". Wrapped in <cite> when the cite prop is set.
- citestring
- URL the citation references. Maps to the native cite attribute on the rendered <blockquote>.
- Locale hint for decorative quote marks (variant="quoted"). "auto" reads document.documentElement.lang at mount, falling back to "en".
- Text alignment. The pull variant forces "center" when this prop is not set. Accepts "left", "center" or "right".
- quoteMarkboolean
- idstring
- classstring | Array<string> | object
- stylestring | Array<string> | object | StyleValue
- tagstring'blockquote'
- HTML element rendered at the root. Defaults to <blockquote>; use "q" for inline citations.
- color
- Text color axis. Tokenised intents resolve to their fgSubtle shade; custom values are applied verbatim.
- accentColorTColor
- bgColor
- Accent color axis: drives the decorative bar / pull rules, the background quote glyph and the author label. Does NOT paint a surface fill.
- Border-radius token or boolean.
- roundedTopRightboolean | number | string
- roundedTopLeftboolean | number | string
- roundedBottomLeftboolean | number | string
- roundedBottomRightboolean | number | string
- roundedStartStartboolean | number | string
- roundedStartEndboolean | number | string
- roundedEndStartboolean | number | string
- roundedEndEndboolean | number | string
- elevationTElevation
- Box-shadow elevation token.
- borderboolean | number | string | TDirectionBoth | Array<TDirectionBoth>false
- Applies a border. Distinct from the variant accent bar.
- borderTopboolean | number | string
- borderLeftboolean | number | string
- borderBottomboolean | number | string
- borderRightboolean | number | string
- borderBlockboolean | number | string
- borderInlineboolean | number | string
- borderInlineStartboolean | number | string
- borderInlineEndboolean | number | string
- borderBlockStartboolean | number | string
- borderBlockEndboolean | number | string
- borderColorstring
- borderStylestring
- borderTopColorTColor
- borderRightColorTColor
- borderBottomColorTColor
- borderLeftColorTColor
- borderInlineStartColorTColor
- borderInlineEndColorTColor
- borderBlockStartColorTColor
- borderBlockEndColorTColor
- paddingboolean | number | string
- Custom padding overriding token defaults.
- paddingTopboolean | number | string
- paddingLeftboolean | number | string
- paddingBottomboolean | number | string
- paddingRightboolean | number | string
- paddingBlockboolean | number | string
- paddingInlineboolean | number | string
- paddingInlineStartboolean | number | string
- paddingInlineEndboolean | number | string
- paddingBlockStartboolean | number | string
- paddingBlockEndboolean | number | string
- marginboolean | number | string
- Custom margin. The component imposes no margin by default.
- marginTopboolean | number | string
- marginLeftboolean | number | string
- marginBottomboolean | number | string
- marginRightboolean | number | string
- marginBlockboolean | number | string
- marginInlineboolean | number | string
- marginInlineStartboolean | number | string
- marginInlineEndboolean | number | string
- marginBlockStartboolean | number | string
- marginBlockEndboolean | number | string
- fontFamilyTFontFamily
- fontSizeTFontSize
- fontWeightTFontWeight
- lineHeightTLineHeight
- letterSpacingTLetterSpacing
- fontStylestring
- textTransformTTextTransform
API
Slots
Emplacements de contenu exposés par ce composant.
- #default
- Citation body content. Rendered inside the __body div.
- #author
- Custom author rendering (link, badge, locale-formatted name). Wins over the author prop.
- #source
- Custom source rendering. Wins over the source prop. Wrapped in <cite> by default.
API
Membres exposés
Propriétés et méthodes accessibles via ref template (defineExpose). Utilisés pour le contrôle programmatique.
- ComputedRef<string>
- Resolved locale (after "auto" resolution from DOM or fallback to "en").
- ComputedRef<string>
- Locale-appropriate opening quote glyph (e.g. """ for en, "«" for fr).
- ComputedRef<string>
- Locale-appropriate closing quote glyph.
- ComputedRef<boolean>
- True when the attribution footer should render (author or source present).
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.
- Block padding of the citation container.
- Inline padding. Expanded by the accent bar width in default/elegant variants.
- Citation body font size.
- Font style. Overridden to italic in elegant and minimal variants.
- Citation body line-height.
- Citation text color. Overridden by color intent classes.
- Resolved accent color driving the bar, glyph and author label.
- Width of the decorative accent bar (default / elegant variants).
- Author attribution color.
- Size of the decorative background quote glyph (variant="quoted").
- Opacity of the background glyph.
Inclusion
Accessibilité
Rôles ARIA, navigation clavier et gestion du focus. Sourcé depuis le template réel du composant.
Rôles ARIA
Interactions clavier
| Touche | Action |
|---|---|
| Tab | Moves focus through interactive content inside the citation body if any. |
Notes
- The cite prop maps to the native cite attribute on the <blockquote>, providing the URL to assistive technologies and browser inspectors.
- The decorative quote mark (<span class="origam-blockquote__mark">) is aria-hidden="true" — it is purely decorative and not announced by screen readers.
- The em-dash before the author name (<span class="origam-blockquote__dash">) is also aria-hidden to avoid double reading.
- The source label is wrapped in <cite> for semantic correctness per the HTML spec.
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.
- dimensionvar(--origam-font__size---lg)
- Body font size.
- numbervar(--origam-font__lineHeight---relaxed)
- Body line-height.
- colorvar(--origam-color__action--primary---bg)
- Default accent bar / glyph color.
- dimension4px
- Accent bar width.
- dimension8rem
- Background glyph size in quoted variant.
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.
Default variant
Pull-quote variant
Quoted with locale marks