Pretext Frontend Motion
Overview
Use this skill when the request clearly maps to an official Pretext demo family.
Do not treat Pretext as a decorative dependency. Keep it in the actual layout path.
Typical trigger patterns:
- measure text height without DOM reflow
- auto-fit text to a fixed number of lines
- tight multilingual bubbles
- routed text around an obstacle
- algorithmic typography or glyph-field motion
- line-breaking or justification comparison
Required Workflow
- Pick the official demo family.
- Pick the matching style profile before writing code.
- Use the matching bundled example or blueprint.
- Stay in the correct API lane:
prepare+layoutfor Accordion, Bubbles, MasonryprepareWithSegments+layoutNextLinefor Dynamic Layout and Editorial EngineprepareWithSegments+layoutWithLinesfor Variable Typographic ASCIIwalkLineRangesfor width probing and layout comparison flows
- Keep the design intentional.
- Validate resize, mobile, and hot-path measurement rules.
Bundled Resources
core/bundle/references/official-notes.mdcore/bundle/references/demo-family-map.mdcore/bundle/references/prompt-recipes.mdcore/bundle/references/integration-gotchas.mdcore/bundle/examples/core/bundle/integrations/core/bundle/blueprints/
Validation Checklist
- Official demo family is explicit.
- Pretext is used for real measurement and layout.
- No DOM text measurement in the relayout hot path.
prepare()is not rerun on every resize.- The result still looks intentional on mobile widths.