Skip to content

feat(i18n): add Spanish (es) locale - #316

Open
Carmonacu wants to merge 3 commits into
Anyesh:mainfrom
Carmonacu:feat/i18n-es-locale
Open

Carmonacu wants to merge 3 commits into
Anyesh:mainfrom
Carmonacu:feat/i18n-es-locale

Conversation

@Carmonacu

@Carmonacu Carmonacu commented Nov 3, 2026 •

Copy link
Copy Markdown

Add a full Spanish (Spain) catalogue and register es alongside the existing languages, including the AI description language. English stays the default.

Description

Related Issue

Type of Change

  • Bug fix (non-breaking change that fixes an issue)
  • New feature (non-breaking change that adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation update
  • Refactoring (no functional changes)
  • CI/CD or build changes

Checklist

  • I have read the CONTRIBUTING guide
  • My code follows the project's coding style
  • I have added tests that prove my fix/feature works
  • New and existing tests pass locally
  • I have updated documentation as needed
  • My changes don't introduce new warnings or errors

Testing

Test Environment

  • Docker Compose
  • Kubernetes
  • Local development

Tests Performed

Screenshots (if applicable)

Additional Notes

Summary by Sourcery

Add Spanish localization across the application while retaining English as the default language.

New Features:

  • Add Spanish (Spain) as a supported application language with a complete translated message catalogue.
  • Enable Spanish locale selection and Spanish-language AI-generated item descriptions.

Enhancements:

  • Update locale documentation and metadata to reflect support for nine languages.

Tests:

  • Extend locale validation and date-display coverage to include Spanish.

Add a full Spanish (Spain) catalogue and register es alongside the existing
languages, including the AI description language. English stays the default.

Co-authored-by: Carmonacu <Carmonacu@users.noreply.github.com>
@github-actions

github-actions Bot commented Nov 3, 2026

Copy link
Copy Markdown
Contributor

Thanks for your first pull request to Wardrowbe! Please make sure you've read the CONTRIBUTING guide, especially the PR title format section. A maintainer will review this soon.

@github-actions github-actions Bot added javascript Pull requests that update javascript code python Pull requests that update python code labels Nov 3, 2026
@sourcery-ai

sourcery-ai Bot commented Nov 3, 2026 •

Copy link
Copy Markdown

Reviewer's Guide

Data structures

Add the Spanish message catalogue and register Spanish in the backend and frontend locale data so the application recognizes it alongside the existing languages.

  • backend/app/data/locales.json L3
  • frontend/lib/generated/locales.ts L3
  • frontend/lib/i18n/locales.ts L23
  • frontend/messages/es/analytics.json L1-69
  • frontend/messages/es/common.json L1-78
  • frontend/messages/es/constants.json L1-284
  • frontend/messages/es/dashboard.json L1-66
  • frontend/messages/es/errors.json L1-13
  • frontend/messages/es/family.json L1-97
  • frontend/messages/es/history.json L1-41
  • frontend/messages/es/learning.json L1-94
  • frontend/messages/es/nav.json L1-24
  • frontend/messages/es/notifications.json L1-99
  • frontend/messages/es/onboarding.json L1-80
  • frontend/messages/es/outfits.json L1-174
  • frontend/messages/es/pairings.json L1-36
  • frontend/messages/es/settings.json L1-148
  • frontend/messages/es/suggest.json L1-106
  • frontend/messages/es/wardrobe.json L1-328

Implementation

Add Spanish with informal tú phrasing to the language instructions used for AI-generated item descriptions.

  • backend/app/services/ai_service.py L97

Documentation

Update the contributor guide and README to state that the application supports nine languages, including Spanish.

  • CONTRIBUTING.md L154
  • README.md L56

Tests

Extend backend tests to verify Spanish is selected for localized AI descriptions and accepted as a user locale.

  • backend/tests/test_ai_service.py L44
  • backend/tests/test_users.py L188

Add Spanish expectations for localized date displays, including the relative-date label.

  • frontend/tests/date-displays.test.tsx L57-66

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey - I've found 1 issue

Prompt for AI Agents
Please address the comments from this code review:

## Individual Comments

### Comment 1
<location path="frontend/lib/i18n/locales.ts" line_range="23" />
<code_context>
   fr: { name: 'French', nativeName: 'Français', dir: 'ltr' },
   de: { name: 'German', nativeName: 'Deutsch', dir: 'ltr' },
   it: { name: 'Italian', nativeName: 'Italiano', dir: 'ltr' },
+  es: { name: 'Spanish', nativeName: 'Español', dir: 'ltr' },
 };

</code_context>
<issue_to_address>
**Spanish auth screens show English**

When spanish is selected and authentication messages are loaded, or the locale-catalog parity test runs, `loadMessages` cannot load `messages/es/auth.json` because the Spanish auth keys are missing, so it falls back to English authentication messages and the parity test fails.

Add the Spanish `auth` catalog with the keys from `en/auth.json`.
</issue_to_address>

Sourcery assessment

Needs a human reviewer. 1 finding to address first, and for Spanish users, the AI description prompt can produce Spanish text that is saved with an item; a bad translation or prompt could leave incorrect descriptions after reverting. Those records are bounded and can be edited or regenerated.

Blocking findings: frontend/lib/i18n/locales.ts:23


Sourcery is free for open source - if you like our reviews please consider sharing them ✨

Comment thread frontend/lib/i18n/locales.ts Resolved
cursoragent and others added 2 commits November 15, 2026 12:29
Co-authored-by: Carmonacu <Carmonacu@users.noreply.github.com>
Co-authored-by: Carmonacu <Carmonacu@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

javascript Pull requests that update javascript code python Pull requests that update python code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants