Files
Momento/.agent/skills/wds-4-ux-design/templates/instructions/form-validation.instructions.md
Antigravity bd495be965
All checks were successful
Deploy to Production / Build and Deploy (push) Successful in 12s
feat: design system overhaul — sidebar, AI chats, settings, brainstorm, color cleanup
- Sidebar: dynamic brand-accent colors, brainstorm section restyled
- AI chat general: popup panel with expand/collapse, hides when contextual AI open
- AI chat contextual: tabs reordered (Actions first), X close button, height fix
- Settings: all tabs restyled, 6 new color presets (sage, terracotta, iron, etc.)
- Global color cleanup: emerald/orange hardcoded → brand-accent dynamic
- Brainstorm page: orange → brand-accent throughout
- PageEntry animation component added to key pages
- Floating AI button: bg-brand-accent instead of hardcoded black
- i18n: all 15 locales updated with new AI/billing keys
- Billing: freemium quota tracking, BYOK, stripe subscription scaffolding
- Admin: integrated into new design
- AGENTS.md + CLAUDE.md project rules added
2026-05-16 12:59:30 +00:00

55 lines
1.1 KiB
Markdown

# Form Validation
**Include when:** Page has forms or input fields
---
## Validation Rules
| Field | Rule | Error Code | Error Message |
|-------|------|------------|---------------|
| `{field-name}` | {validation-rule} | `{ERR_CODE}` | {message} |
---
## Error Messages
| Error Code | Trigger | EN | SE | Recovery |
|------------|---------|-----|-----|----------|
| `ERR_001` | {When occurs} | "{English}" | "{Swedish}" | {How to fix} |
---
## Form States
### Valid State
- All fields pass validation
- Submit button enabled
- No error indicators
### Invalid State
- Error fields highlighted
- Error messages visible
- Submit button disabled until fixed
### Submitting State
- Submit button shows loading
- Fields disabled
- Cancel option available
---
## Field Specifications
### {Field Name}
| Property | Value |
|----------|-------|
| **OBJECT ID** | `{form-field-id}` |
| Type | {text / email / password / select / etc.} |
| Required | {yes / no} |
| Placeholder EN | "{Placeholder text}" |
| Placeholder SE | "{Swedish placeholder}" |
| Validation | {rules} |
| Error Message | {message} |