Agent skill
layout-framework
Use for any frontend layout or form arrangement work in PierceDesk. Covers Box/Container/Grid/Stack/Paper usage, responsive sizing, spacing rules, and how to align pages with the app’s layout framework. Trigger when asked to fix layout issues, align fields, create grids, or ensure design-system consistency.
Install this agent skill to your Project
npx add-skill https://github.com/majiayu000/claude-skill-registry/tree/main/skills/data/layout-framework
SKILL.md
Layout Framework Skill
Core rules (always follow)
- Use MUI v7 Grid with the
sizeprop (notxs/mdprops). - Prefer
Grid containerfor column layouts; useStackfor simple vertical rhythm. - Avoid hardcoded widths/heights; use theme spacing and responsive values (
{ xs, md }). - Wrap major sections in
Paper background={1}withp: { xs: 3, md: 5 }andborderRadius: 6unless the surrounding layout already provides a card. - Keep inputs aligned in a consistent grid (e.g., 12 / 6 / 3 / 3, 8 / 4, 6 / 6). No uneven, ad-hoc sizing.
- Use
Containeronly for page-level width constraints. Inside cards, useGridfor structure.
When to read references
- For exact examples of Box/Container/Grid/Stack usage, read:
references/component-docs-map.mdreferences/layout-patterns.md
Default layout patterns
- Two-column forms:
Grid container spacing={{ xs: 2, md: 3 }}withsize={{ xs: 12, md: 6 }}. - Primary + secondary field:
size={{ xs: 12, md: 8 }}+size={{ xs: 12, md: 4 }}. - Address block: street
12, city6, state3, zip3. - Section cards: each form block inside
Paper background={1}with internalGridorStack.
Process checklist
- Identify the page sections and their cards.
- Decide row/column structure using
Grid(avoid ad-hocsxflex sizing). - Normalize spacing with
spacing={{ xs: 2, md: 3 }}andp: { xs: 3, md: 5 }. - Verify that labels/inputs align across rows and breakpoints.
- Remove any hardcoded widths or manual flex ratios unless they map to a grid size.
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
Didn't find tool you were looking for?