Skip to main content
Variations
<bolt-divider></bolt-divider>
<bolt-divider width="50%"></bolt-divider>

<bolt-divider width="200px"></bolt-divider>
<bolt-divider width="200px" alignment="center"></bolt-divider>

<bolt-divider width="200px" alignment="right"></bolt-divider>
Code reference
  • width (optional)
    • Adjusts width of divider
    • Takes any CSS unit: px, %, em etc.
  • alignment (optional)
    • Adjusts horizontal alignment of divider
    • Options:
      • left (default)
      • center
      • right
    • NOTE: Only use when applying a specific width.
Design guidelines
  • Dividers provide subtle visual delineation between groups of content.
  • Dividers are intended to add visual separation between elements. They are not intended to meet accessibility contrast requirements and are not focusable.
  • They are not interactive.
  • There is no padding build into the component. Padding around the divider should be set by the designer or developer.
  • When a visual division between content is desired.
  • When space alone does not provide enough assistance with visually grouping content.
  • When it is more practical to apply borders to a container than use multiple dividers.

Do

  • Use to group related content together.
  • Use to make content easier to digest.

Don't

  • Don't make a divider interactive.
  • Don't use when a border for a container would be more appropriate.
Accessibility
  • Color is Contextual so it will adapt to different backgrounds to be visible.
  • Component is non-interactive so it doesn’t have to meet contrast standards.
  • Supposed to be a subtle visual element. Would likely be ignored by screen readers.

All Bolt components have gone through accessibility testing, but please keep our accessibility guidelines in mind.

Display settings

Note: not all settings persist across pages

Default Compact (-1) Sparse (+1) XL (default) 2XL 3XL Default Min Max Light (default) System Dark Branded (default) Unbranded