agentleFS
emiliodominguezemiliodominguez/flow-skills/skills/flow-styles/SKILL.md

flow-styles

Skill1 starsChanged 47 days agoMITView on GitHub

CSS within the repo's styling architecture, verified in the browser. Use for layout, responsive, cascade or theming bugs in existing components. Hands off to `flow-animate` or `flow-review`.

The file

We split this skill into the rules it gives an agent

7 rules. About 0 are common, 3 are distinctive, and 4 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈3

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 4

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Read the component, reference design, tokens, stylesheet organization, browser targets, Prettier/Stylelint rules and nearby patterns.

    line 15
  2. Distinctive:

    Use existing tokens for shared values.

    line 21
  3. Very specific:

    Prefer layout primitives, intrinsic sizing, logical properties, gap, minmax() and aspect-ratio over brittle coordinates.

    line 22
  4. Very specific:

    Check support before nesting, container queries, :has(), color-mix(), view transitions or scroll-driven effects.

    line 27
  5. Distinctive:

    Check hover, focus, active, disabled, error, empty, loading and forced-colors states as relevant.

    line 41
  6. Very specific:

    Use containment, content-visibility and rendering hints only for demonstrated performance needs.

    line 45
  7. Very specific:

    Use flow-animate for a motion pass, flow-a11y for a full accessibility audit, or flow-review for implementation review.

    line 64

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Styles

Solve the visual problem inside the project's actual CSS architecture. Use newer features only for a concrete benefit within the supported browser matrix.

Phase 1: Inspect the design contract

Read the component, reference design, tokens, stylesheet organization, browser targets, Prettier/Stylelint rules and nearby patterns. Keep the existing approach (plain CSS, modules, utilities, CSS-in-JS, SCSS); never import another repository's naming or module conventions.

Phase 2: Build deliberate layout and cascade

  • Use existing tokens for shared values; keep one-off values local rather than inventing tokens.
  • Prefer layout primitives, intrinsic sizing, logical properties, gap, minmax() and aspect-ratio over brittle coordinates. Account for long text, localization and zoom.
  • Scope selectors; check specificity and source order. Add @layer only with a coherent strategy: unlayered normal styles beat layered ones and important-layer order reverses. Layers do not automatically fix a vendor override.
  • Check support before nesting, container queries, :has(), color-mix(), view transitions or scroll-driven effects; add fallbacks or targeted @supports when needed. Parser support is not proof of bug-free behavior.
  • Transition explicit properties; no transition: all or broad animation resets. Keep comments and directives that tools need.

Phase 3: Preserve accessible and reduced-motion states

  • Semantic controls, logical focus order, visible focus, sufficient contrast. Prefer :focus-visible with a fallback; never remove the only keyboard indicator. Content that must stay available to assistive technology uses a visually-hidden utility, not display: none.
  • For prefers-reduced-motion, design a reduced or static presentation that keeps content and state changes. Handle infinite iteration, delays, animation callbacks and initially hidden elements explicitly; do not blindly shorten everything. Test with the preference on.
  • Check hover, focus, active, disabled, error, empty, loading and forced-colors states as relevant.

Phase 4: Measure and inspect

Use containment, content-visibility and rendering hints only for demonstrated performance needs; containment can clip popovers and tooltips, so check anchors, scrolling and overflow. Inspect the rendered page at representative widths, text lengths and zoom with stable data and fonts. Exercise keyboard and pointer, compare with the reference, run lint/build. Without browser access, name which visual and interaction claims remain unverified.

Anti-patterns

  • A catalog of trendy CSS features unrelated to the requested design.
  • Global overrides that change unrelated components or remove focus.
  • Treating a typecheck or source screenshot as rendered verification.
  • Applying another project's SCSS/module conventions as universal rules.

Done when

  • The rendered change meets design and responsive requirements in supported targets.
  • Interaction, focus and reduced-motion behavior are verified or explicitly unverified.
  • Cascade and source follow local conventions without unrelated rewrites.

Use flow-animate for a motion pass, flow-a11y for a full accessibility audit, or flow-review for implementation review. New screens start in flow-ui, new visual directions in flow-design.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.