Home

Images

Usage

Image objects can appear inline or as block-level media. Start with these tokens:

  • --image-block-max-width to control breakout width (with mobile/print variants)

  • --image-title-* tokens to style optional titles above images

  • --image-caption-* tokens to style captions and alignment

Inline images inherit text flow and are constrained to 1.1em in height, so typography tokens drive their scale.

Tokens

Layout Tokens

TokenDescriptionDefault Value
--image-block-max-widthMaximum width for block imagesvar(--content-breakout-width)
--image-block-max-width-mobileMaximum width on mobile (640px)var(--content-breakout-width-mobile)
--image-block-max-width-printMaximum width in print100%

Title Tokens

TokenDescriptionDefault Value
--image-title-font-familyFont family for image titlesvar(--caption-font-family)
--image-title-font-sizeFont size for image titlesvar(--caption-font-size)
--image-title-colorText color for image titlesvar(--caption-color)
--image-title-line-heightLine height for image titlesvar(--caption-line-height)
--image-title-alignText alignment for titlescenter
--image-title-spacing-bottomGap between title and imagevar(--caption-spacing)

Caption Tokens

TokenDescriptionDefault Value
--image-caption-font-familyFont family for image captionsvar(--caption-font-family)
--image-caption-font-sizeFont size for image captionsvar(--caption-font-size)
--image-caption-colorText color for image captionsvar(--caption-color)
--image-caption-line-heightLine height for image captionsvar(--caption-line-height)
--image-caption-alignText alignment for captionscenter
--image-caption-spacing-topGap between image and captionvar(--caption-spacing)

Examples

Default Images

:root {
  /* No design token overrides */
}

Captioned Images

:root {
  --image-caption-align: left;
  --image-caption-font-size: var(--font-size-xs);
  --image-title-align: left;
}
Figure title A brief caption describing the image content.

Inline Images

Inline images align with surrounding text and scale to the line height:

:root {
  /* No design token overrides */
}

The icon appears inline with text.

© 2026 Stencila