Blockquote
The Blockquote component displays quoted content with optional citation and source attribution. Use Blockquote to highlight quotations from external sources.Installation
Usage
Components
The Blockquote package includes three components that work together:Blockquote
The container component that wraps the quote content.Props
| Prop | Type | Default | Description |
|---|---|---|---|
element | string | 'BLOCKQUOTE' | Overrides the default element name to apply unique styles with the Customization Provider. |
url | string | - | The URL to the source of the quote. |
marginBottom | 'space0' | 'space70' | 'space70' | Remove or set the bottom margin. |
BlockquoteContent
The component that contains the quoted text.Props
| Prop | Type | Default | Description |
|---|---|---|---|
element | string | 'BLOCKQUOTE_CONTENT' | Overrides the default element name to apply unique styles with the Customization Provider. |
BlockquoteCitation
The component that displays the author and source attribution.Props
| Prop | Type | Default | Description |
|---|---|---|---|
element | string | 'BLOCKQUOTE_CITATION' | Overrides the default element name to apply unique styles with the Customization Provider. |
author | string | - | Required. The author of the quote. |
source | string | - | The source of the quote. |
Styling Details
The Blockquote has the following default styles:- Displays a decorative quote icon
- Uses
fontSize30andlineHeight30 - Default bottom margin of
space70 - Icon color:
colorTextIcon
Examples
Basic Blockquote with URL
Without URL
When no URL is provided, the source will be displayed as plain text instead of a link:Without Source
You can omit the source and just provide the author:Removing Bottom Margin
Customization
The Blockquote component can be extensively customized:Customizable Elements
The following element names are available for customization:BLOCKQUOTE: The main containerBLOCKQUOTE_ICON: The decorative quote iconINNER_BLOCKQUOTE: Inner wrapper around contentBLOCKQUOTE_CONTENT: The quote contentBLOCKQUOTE_CITATION: The citation containerBLOCKQUOTE_CITATION_AUTHOR: The author textBLOCKQUOTE_CITATION_CITE: The citation wrapperBLOCKQUOTE_CITATION_ANCHOR: The source link (when URL provided)BLOCKQUOTE_CITATION_TEXT: The source text (when no URL)
Accessibility
- Uses semantic
<blockquote>HTML element for the quoted content - The
citeattribute is automatically set on the blockquote element when a URL is provided - The quote icon is decorative and hidden from screen readers
- External links (when URL is provided) are indicated with the
showExternalprop on Anchor