Skip to content

Screenshot State Guide

Screenshots should show real product states that help someone debug or understand the workflow. Avoid one perfect happy-path screenshot when the feature has meaningful states.

AreaStates to captureCurrent paths
InstallerFresh form, preflight failure, install guide, progress running, success/removalpackages/installer/docs/images/screenshots/*
MarketplaceUnconnected, connected, catalogue browsing, readiness review, manual-only install, licence entry, live progress, purchases, package operationspackages/marketplace/docs/images/screenshots/*
Admin extensionsExtensions page empty/installed, package settings page, permission deniedAdd under packages/admin/docs/images/screenshots/*.
Frontend safetyNormal anonymous page, cached page, authoring beacon disabled/enabled for adminAdd under frontend docs when frontend-authoring is installed.

Use names that describe the state, not the implementation:

marketplace-unconnected.png
marketplace-connected.png
marketplace-readiness-manual-only.png
marketplace-licence-entry.png
marketplace-install-progress.png
installer-preflight-failed.png
installer-success-remove-package.png

Include dark mode only when the visual state differs or the docs page already presents paired light/dark screenshots.

  • Use seeded data that is safe to publish.
  • Hide secrets, emails, signing values, tokens, local paths, and private domains.
  • Capture the whole viewport unless the docs need a tight crop of one control.
  • Keep mobile screenshots for workflows that materially change on mobile.
  • Update screenshots.json beside package docs when the package already uses one.

Custom Filament action behaviour needs screenshot coverage. Do not count raw actions; count states a reviewer cannot infer from a normal resource screenshot.

Standard CreateAction, EditAction, DeleteAction, DeleteBulkAction, RestoreAction, ForceDeleteAction, ReplicateAction, and view actions do not need a dedicated action screenshot when they are used without extra behaviour. The resource list, create, edit, or view screenshot is enough.

Add a screenshot when an action:

  • uses Action::make(), BulkAction::make(), StaticAction::make(), or a package-owned action class for a real workflow;
  • adds form(), schema(), wizard steps, modal content, footer actions, confirmation text, custom callbacks, mutations, or custom URLs;
  • handles import, export, publish, unpublish, sync, clone, preview, install, connect, retry, impersonation, token, or destructive behaviour.

Link the screenshot manifest back to the source file with covers:

{
"id": "publishing-studio-compare-readiness",
"target": "CompareReadinessPage",
"covers": [
"packages/publishing-studio/src/Filament/Pages/CompareReadinessPage.php"
]
}

Run npm run docs:filament-action-screenshots before finishing package work. New gaps fail npm run docs:screenshots:check.

The action checker scans this host repository by default. Set CAPELL_PACKAGES_REPO to an absolute companion-repository path only when you intentionally want to include that repository in the same check.

Flux-generated diagrams are useful for conceptual visuals at the top of docs pages. They should not be the source of truth for class names, method names, or exact request flow.

Use Flux for:

  • high-level architecture visuals;
  • onboarding illustrations;
  • state overview graphics;
  • docs covers or section headers.

Use Mermaid for:

  • exact class and registry flow;
  • sequence diagrams;
  • testable architecture;
  • anything with code symbols.

The FLUX connector must be authenticated before generating these assets. Once authenticated, create images under docs/images/diagrams/ and keep the exact Mermaid diagram beside the image in the same doc.

Core documentation captures come from scripts/screenshots/prepare-workbench.sh, which runs capell:install --demo --package-mode=core --theme=none. That seeds almost no content, because the core, admin and frontend capell.json files all declare "demo": null, and no theme is installed. Content-rich captures (for example the “Index of Practice” demo) come from the theme-submissions package’s demo content in capell-packages-4, so run those passes from capell-packages-4.

prepare-workbench.sh rewrites the shared Testbench skeleton under vendor/ and leaves a .capell-workbench-prepared marker there, because the capture serves from it. Tests and static analysis booted from a rewritten skeleton fail for reasons unrelated to the change, so composer preflight refuses to run those stages while the marker exists.

Before rewriting, preparation copies the pristine skeleton to storage/framework/testing/testbench-skeleton-pristine. scripts/local-core-screenshots.sh restores it when the run ends, whether the capture passed or failed, and removes the marker. Two cases need you to restore it yourself:

  • --keep-workbench leaves the prepared skeleton in place for a later --reuse-app run.
  • Calling prepare-workbench.sh or npm run screenshots:prepare directly has no wrapper to restore afterwards.

In either case run npm run screenshots:restore when you have finished capturing. If the copy is missing, composer reinstall orchestra/testbench-core --no-scripts also restores a pristine skeleton.

After a fresh composer install, post-autoload-dump removes vendor/orchestra/testbench-core/laravel/database/migrations; prepare-workbench.sh recreates the directory before the install step, so a manual testbench capell:install straight after composer install has nowhere to publish vendor migrations to.