Esc

comark-annotate

compare

Two screenshots side by side or under a slider, and their props.

Two screenshots of the same view, before and after a change. They're titled Before and After unless they set their own title, and their notes are numbered on from one to the other.

Playground
Before
Toolbar wrapping1
  1. 1
    Apply sits lower than the chips.
After
Toolbar on one row2
  1. 2
    Fixed.
1 / 2

The default. The two screenshots sit side by side and stack on a narrow screen. They zoom as one gallery.

A note with side="left" or side="right" joins the numbered list under its screenshot. Beside it, the note would press against the other screenshot and shrink its own. A note with side="top" stays above.

With mode="slider", the two screenshots share one frame: Before shows left of a divider, After right of it. Use it when the change is small and in one spot, so the reader sees it at full width.

  • Drag anywhere on the pair to move the divider, or focus its handle and use the arrow keys.
  • A click that doesn't drag zooms the pair.
  • Side notes join the numbered list, since an arrow would cross the divider.
  • Without the script, the two screenshots stack.
Prop
title What the comparison shows, read out by screen readers. Defaults to "Comparison".
mode columns (default) puts the screenshots side by side. slider lays one over the other with a divider to drag.