This is the primary workflow rule. Long-form guidance lives in docs/ai/.
- Classify the outcome before implementation: component, gallery page, AppFlow screen, static page, token/foundation, icon, or docs/rules.
- If outcome, target user, source design, missing states, or validation expectation is unclear, ask before building.
- Read in order:
docs/ai/project-context.md,docs/ai/operational-manifesto.md,docs/ai/workflow-contracts.md, nearby examples, thendocs/ai/review-checklist.md. - Keep boundaries: components in
packages/spring-ds-react/src/components/, gallery inapps/design-library/src/gallery/, routes inapps/design-library/src/app/library/, AppFlow registry inpersonalLoanFlow.ts. - Route shells stay thin and re-export gallery implementations.
- Pages import reusable UI from
@spring/ds-react; new reusable components must export frompackages/spring-ds-react/src/index.ts. - Token changes require approval,
npm run tokens:sync, dev-server restart for local preview, and.nextclearing before production build validation. - Code Connect placement: package-side for new reusable components and all inputs; gallery-side only for existing navigations, overlays, and
SpringSearchBar. - Do not revert unrelated user changes.
- On resume, restate outcome, phase, approval status, loop count, changed files, and next action before continuing.