-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
feat: backend i18n #2056
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: develop
Are you sure you want to change the base?
feat: backend i18n #2056
Conversation
|
Deployment Status: ❌ Failed |
3 similar comments
|
Deployment Status: ❌ Failed |
|
Deployment Status: ❌ Failed |
|
Deployment Status: ❌ Failed |
|
Deployment Status: ✅ Success |
5ba4ca1 to
8e37e33
Compare
|
Deployment Status: ✅ Success |
2 similar comments
|
Deployment Status: ✅ Success |
|
Deployment Status: ✅ Success |
38022d8 to
daa002a
Compare
|
Deployment Status: ✅ Success |
2 similar comments
|
Deployment Status: ✅ Success |
|
Deployment Status: ✅ Success |
371176b to
7cd6e21
Compare
|
Deployment Status: ✅ Success |
3 similar comments
|
Deployment Status: ✅ Success |
|
Deployment Status: ✅ Success |
|
Deployment Status: ✅ Success |
|
Deployment Status: ✅ Success |
1 similar comment
|
Deployment Status: ✅ Success |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR adds internationalization (i18n) support to the application using the nestjs-i18n library. The implementation enables multi-language support for notifications, email templates, and user preferences.
- Adds
nestjs-i18nlibrary (v10.5.1) for backend internationalization - Introduces user language preference storage in the database (
langfield) - Converts hardcoded email templates and notifications to use i18n keys with translation files
- Updates notification schema to support i18n messages (
messageI18nfield)
Reviewed Changes
Copilot reviewed 37 out of 38 changed files in this pull request and generated 7 comments.
Show a summary per file
| File | Description |
|---|---|
| pnpm-lock.yaml | Adds nestjs-i18n package and related dependencies |
| packages/openapi/src/user/update-lang.ts | New API endpoint for updating user language preference |
| packages/db-main-prisma/prisma/*.prisma | Adds lang field to User model and messageI18n field to Notification model |
| packages/core/src/models/notification/notification.schema.ts | Adds optional messageI18n field to notification schema |
| packages/common-i18n/src/locales/*/common.json | Adds translation templates for emails and notifications |
| apps/nextjs-app/src/features/app/components/notifications/notification-component/LinkNotification.tsx | Implements client-side i18n message rendering for notifications |
| apps/nextjs-app/src/features/app/components/LanguagePicker.tsx | Updates language picker to call new API endpoint |
| apps/nestjs-backend/src/utils/i18n.ts | Utility to resolve i18n locale path |
| apps/nestjs-backend/src/global/global.module.ts | Configures i18n module with resolvers |
| apps/nestjs-backend/src/features/user/user.service.ts | Adds user language update and sets default language on user creation |
| apps/nestjs-backend/src/features/notification/notification.service.ts | Refactors to support i18n messages in notifications |
| apps/nestjs-backend/src/features/mail-sender/mail-sender.service.ts | Converts email templates to use i18n keys |
| apps/nestjs-backend/src/features/import/open-api/*.ts | Passes user language context to import jobs for localized notifications |
Files not reviewed (1)
- pnpm-lock.yaml: Language not supported
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
apps/nestjs-backend/src/features/notification/notification.service.ts
Outdated
Show resolved
Hide resolved
apps/nestjs-backend/src/features/notification/notification.service.ts
Outdated
Show resolved
Hide resolved
c0cf54a to
f6b0111
Compare
|
Deployment Status: ✅ Success |
|
Deployment Status: ✅ Success |
1 similar comment
|
Deployment Status: ✅ Success |
aade17f to
f4ec736
Compare
|
Deployment Status: ✅ Success |
981045c to
c4ec7df
Compare
|
Deployment Status: ✅ Success |
1 similar comment
|
Deployment Status: ✅ Success |
7c2994c to
d1dae4b
Compare
|
Deployment Status: ✅ Success |
…language field to User model
8a5df71 to
d06d859
Compare
|
Deployment Status: ✅ Success |
1 similar comment
|
Deployment Status: ✅ Success |
apps/nestjs-backend/src/features/import/open-api/import-open-api.service.ts
Outdated
Show resolved
Hide resolved
|
Deployment Status: ✅ Success |
Uh oh!
There was an error while loading. Please reload this page.