chromatic-viewports
Installation
SKILL.md
Chromatic Viewports
Configure responsive visual testing across multiple screen sizes using Chromatic's Modes API.
This skill covers:
- Setting up viewport modes in
.storybook/modes.ts - Applying modes at project, component, and story levels
- Controlling snapshot height with
cropToViewport - Migrating from the legacy
chromatic.viewportsAPI
Quick start
- Scan the project for existing viewport config: look for
chromatic.viewports(legacy) or amodes.ts/modesimport (new API). - Fetch the relevant docs from
reference/docs-map.md. - Determine whether this is a fresh setup, an extension, or a migration.
- Generate configuration files and output the checklist from
reference/output-contract.md.