8bac3bad4b
feat: Localize Sleep, Diaper, Activity, and Settings pages
...
CI/CD Pipeline / Lint and Test (push) Has been cancelled
CI/CD Pipeline / E2E Tests (push) Has been cancelled
CI/CD Pipeline / Build Application (push) Has been cancelled
Added comprehensive localization to tracking and settings pages:
**Translation Keys Added:**
- Sleep: locations, status, duration formatting, success/delete messages
- Diaper: conditions, rash severity and alert, success/delete messages
- Activity: activity types, form labels, placeholders
- Settings: profile, preferences, notifications, appearance, account actions
- Common: shared labels (selectChild, noChildrenAdded, etc.)
**Pages Localized:**
1. Sleep tracking page (/app/track/sleep/page.tsx)
- All form labels and dropdowns
- Location options (crib, bed, stroller, carrier, other)
- Sleep status (completed/ongoing)
- Duration display with interpolation
- Success and delete messages
2. Diaper tracking page (/app/track/diaper/page.tsx)
- Diaper types (wet, dirty, both, dry)
- Conditions (normal, soft, hard, watery, mucus, blood)
- Rash detection with severity levels
- Alert message for diaper rash
- Recent diapers display with translated labels
3. Activity tracking page (/app/track/activity/page.tsx)
- Activity types (play, walk, music, reading, tummy time, outdoor, other)
- Duration and description fields
- Form placeholders
- Recent activities display
4. Settings page (/app/settings/page.tsx)
- Profile information section
- Preferences, notifications, appearance sections
- Account actions (logout)
- Save/saving button states
- Success message
All pages now support multi-language translation and are ready for
Spanish, French, Portuguese, and Chinese translations.
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude <noreply@anthropic.com >
2025-10-03 13:18:01 +00:00
b56f9546c2
feat: Complete high-priority i18n localization with date/time support
...
This commit implements comprehensive localization for high-priority components:
## Tracking Pages (4 files)
- Localized feeding, sleep, diaper, and medicine tracking pages
- Replaced hardcoded strings with translation keys from tracking namespace
- Added useTranslation hook integration
- All form labels, buttons, and messages now support multiple languages
## Child Dialog Components (2 files)
- Localized ChildDialog (add/edit child form)
- Localized DeleteConfirmDialog
- Added new translation keys to children.json for dialog content
- Includes validation messages and action buttons
## Date/Time Localization (14 files + new hook)
- Created useLocalizedDate hook wrapping date-fns with locale support
- Supports 5 languages: English, Spanish, French, Portuguese, Chinese
- Updated all date formatting across:
* Tracking pages (feeding, sleep, diaper, medicine)
* Activity pages (activities, history, track activity)
* Settings components (sessions, biometric, device trust)
* Analytics components (insights, growth, sleep chart, feeding graph)
- Date displays automatically adapt to user's language (e.g., "2 hours ago" → "hace 2 horas")
## Translation Updates
- Enhanced children.json with dialog section containing:
* Form field labels (name, birthDate, gender, photoUrl)
* Action buttons (add, update, delete, cancel, saving, deleting)
* Delete confirmation messages
* Validation error messages
Files changed: 17 files (+164, -113)
Languages supported: en, es, fr, pt-BR, zh-CN
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude <noreply@anthropic.com >
2025-10-03 11:49:48 +00:00