-
Notifications
You must be signed in to change notification settings - Fork 533
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
[Feat] Translated workspace selection component and added i18n support for multiple languages #8443
Conversation
… for multiple languages
WalkthroughThe changes in this pull request focus on enhancing localization support within the workspace selection component of the application. The static text strings in the Changes
Possibly related PRs
Suggested reviewers
Poem
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
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.
Actionable comments posted: 0
🧹 Outside diff range and nitpick comments (10)
packages/desktop-ui-lib/src/lib/login/shared/ui/workspace-selection/workspace-selection.component.html (1)
9-9
: Approved with a minor suggestion: Consider pluralizing 'WORKSPACE' in the translation keyThe informational text has been successfully internationalized. However, for improved clarity and consistency, consider updating the translation key to use the plural form:
-{{ 'WORKSPACES.SELECTION.EMAIL_MULTIPLE_WORKSPACE' | translate }} +{{ 'WORKSPACES.SELECTION.EMAIL_MULTIPLE_WORKSPACES' | translate }}This change would better reflect the content of the message, which refers to multiple workspaces.
packages/ui-core/i18n/assets/i18n/zh.json (1)
Line range hint
1-4650
: Overall, the Chinese translations are comprehensive and well-structured.The zh.json file provides a thorough set of translations for what appears to be a complex application. The use of nested objects to organize related translations is a good practice, making the file more manageable and easier to navigate. The consistent use of placeholders (e.g., {{ name }}) for dynamic content is also commendable.
However, there are a few areas where the translations could be improved or clarified:
Some translations might benefit from additional context. For example, in the "TIMESHEET" section, the translation for "TILL_NOW" (到现在为止) might be clearer as "截至目前" depending on the context.
In some cases, technical terms are translated literally, which might not be the most natural in Chinese. For example, "DASHBOARD" is translated as "仪表盘", but "控制面板" might be more commonly used in software contexts.
Consider adding comments for complex or context-dependent translations to help future maintainers understand the intended meaning and usage.
To improve maintainability and clarity, consider:
- Adding comments for complex translations or those highly dependent on context.
- Reviewing technical terms to ensure they use the most natural and commonly accepted Chinese translations in software contexts.
- Having a native Chinese speaker with technical background review the translations for naturalness and accuracy.
packages/ui-core/i18n/assets/i18n/ar.json (1)
4641-4648
: New workspace-related translations added successfully.The new translations for the workspace functionality have been added correctly. The Arabic translations seem appropriate and consistent with the existing style. However, there are a couple of minor suggestions:
- Consider adding a period (.) at the end of the "FIND_WORKSPACE" translation for consistency with other similar entries.
- In the "EMAIL_MULTIPLE_WORKSPACE" translation, consider using Arabic punctuation marks for a more localized feel.
Here's a suggested improvement for the "FIND_WORKSPACE" translation:
- "FIND_WORKSPACE": "ابحث عن مساحتك الخاصة", + "FIND_WORKSPACE": "ابحث عن مساحتك الخاصة.",And for the "EMAIL_MULTIPLE_WORKSPACE" translation:
- "EMAIL_MULTIPLE_WORKSPACE": "البريد الإلكتروني مرتبط بعدة مساحات عمل، يرجى اختيار واحدة للمتابعة", + "EMAIL_MULTIPLE_WORKSPACE": "البريد الإلكتروني مرتبط بعدة مساحات عمل، يرجى اختيار واحدة للمتابعة.",packages/ui-core/i18n/assets/i18n/bg.json (1)
Line range hint
1-4662
: Overall, the Bulgarian translations are well-structured and appropriate.The file contains comprehensive translations for various parts of the application, including the newly added workspace-related strings. The translations appear to be contextually appropriate and well-formatted.
Minor suggestion for consistency:
Consider adding a period at the end of the "FIND_WORKSPACE" translation to match the style of similar phrases in the file:-"FIND_WORKSPACE": "Намерете вашето работно пространство" +"FIND_WORKSPACE": "Намерете вашето работно пространство."This change would make it consistent with other similar translations in the file that end with a period.
packages/ui-core/i18n/assets/i18n/nl.json (1)
Line range hint
4655-4657
: Server-related translations and placeholderThe file includes translations for server-related items and a placeholder for a coming soon page:
"SERVER_API": "API Server", "SERVER_API_LOG": "API Server Log", "COMING_SOON": "This page is coming soon!"Note that the "COMING_SOON" message is in English, while the rest of the file is in Dutch.
Consider translating the "COMING_SOON" message to Dutch for consistency:
-"COMING_SOON": "This page is coming soon!" +"COMING_SOON": "Deze pagina komt binnenkort!"packages/ui-core/i18n/assets/i18n/it.json (1)
Line range hint
1-4651
: Overall file structure is maintained, with minor suggestions for improvement.The Italian translation file maintains its structure and consistency throughout. However, there are a few suggestions for improvement:
- Consider adding comments to separate major sections of the translation file for better readability and maintenance.
- Ensure that all translation keys follow a consistent naming convention (e.g., all uppercase with underscores).
- Double-check that all translated strings are properly escaped, especially those containing special characters or apostrophes.
These minor improvements could enhance the maintainability of the translation file in the long run.
packages/ui-core/i18n/assets/i18n/pt.json (1)
Line range hint
4657-4657
: English text found in Portuguese translation file.The "COMING_SOON" translation is currently in English:
"COMING_SOON": "This page is coming soon!"This should be translated to Portuguese to maintain consistency and avoid confusion for users.
Suggested correction:
"COMING_SOON": "Esta página estará disponível em breve!"Please update this translation to ensure all content is in Portuguese.
packages/ui-core/i18n/assets/i18n/es.json (1)
Line range hint
4659-4659
: Untranslated "COMING_SOON" message.The "COMING_SOON" message at the end of the file has been left in English:
"COMING_SOON": "This page is coming soon!"This should be translated to Spanish to maintain consistency with the rest of the file.
Suggested translation:
"COMING_SOON": "¡Esta página estará disponible pronto!"Please update this line with the Spanish translation to ensure all content is properly localized.
packages/ui-core/i18n/assets/i18n/fr.json (1)
Line range hint
4659-4661
: Translate "COMING_SOON" message to FrenchThe translations for "SERVER_API" and "SERVER_API_LOG" are appropriate. However, the "COMING_SOON" message is still in English, which is inconsistent with the rest of the French translations in this file.
Consider translating the "COMING_SOON" message to French. A suggested translation would be:
- "COMING_SOON": "This page is coming soon!" + "COMING_SOON": "Cette page sera bientôt disponible !"packages/ui-core/i18n/assets/i18n/de.json (1)
4639-4646
: New workspace selection translations look good!The new translations for the workspace selection process have been added successfully. They provide a friendly and informative user experience in German.
For consistency, consider changing "Wähle Arbeitsbereich für" to "Arbeitsbereich auswählen für" to match the more formal tone used in other parts of the translation.
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
📒 Files selected for processing (14)
- packages/desktop-ui-lib/src/lib/login/shared/ui/workspace-selection/workspace-selection.component.html (2 hunks)
- packages/ui-core/i18n/assets/i18n/ar.json (1 hunks)
- packages/ui-core/i18n/assets/i18n/bg.json (1 hunks)
- packages/ui-core/i18n/assets/i18n/de.json (1 hunks)
- packages/ui-core/i18n/assets/i18n/en.json (1 hunks)
- packages/ui-core/i18n/assets/i18n/es.json (1 hunks)
- packages/ui-core/i18n/assets/i18n/fr.json (1 hunks)
- packages/ui-core/i18n/assets/i18n/he.json (1 hunks)
- packages/ui-core/i18n/assets/i18n/it.json (1 hunks)
- packages/ui-core/i18n/assets/i18n/nl.json (1 hunks)
- packages/ui-core/i18n/assets/i18n/pl.json (1 hunks)
- packages/ui-core/i18n/assets/i18n/pt.json (1 hunks)
- packages/ui-core/i18n/assets/i18n/ru.json (1 hunks)
- packages/ui-core/i18n/assets/i18n/zh.json (1 hunks)
🧰 Additional context used
🔇 Additional comments (28)
packages/desktop-ui-lib/src/lib/login/shared/ui/workspace-selection/workspace-selection.component.html (4)
5-7
: LGTM: Welcome message successfully internationalizedThe welcome message has been properly internationalized using appropriate translation keys. The structure maintains the original layout while allowing for multi-language support.
14-15
: LGTM: Workspace selection prompt successfully internationalizedThe workspace selection prompt has been properly internationalized while maintaining the dynamic insertion of the user's email address. This change effectively supports multi-language functionality while preserving personalization.
43-43
: LGTM: 'Open' button text successfully internationalizedThe 'Open' button text has been properly internationalized using an appropriate translation key. This change supports multi-language functionality while maintaining the existing button structure and styling.
Line range hint
1-54
: Overall: Excellent implementation of i18n support for the workspace selection componentThe changes in this file successfully implement internationalization support for the workspace selection component. All static text has been replaced with appropriate translation keys, following a consistent naming convention. The structure and functionality of the component have been preserved, ensuring that the changes only affect the text content for multi-language support.
These modifications align well with the PR objectives and will greatly enhance the application's ability to support multiple languages. Great job on maintaining consistency throughout the file and ensuring that the changes do not impact the existing functionality.
packages/ui-core/i18n/assets/i18n/ar.json (1)
Line range hint
1-4648
: Overall, the Arabic translations are well-maintained and consistent.The file
packages/ui-core/i18n/assets/i18n/ar.json
has been updated with new translations for the workspace functionality. These additions are generally well-integrated and consistent with the existing translations. Apart from the minor suggestions provided earlier, the file maintains good quality and consistency in its Arabic translations.packages/ui-core/i18n/assets/i18n/he.json (1)
4633-4640
: New workspace selection translations added successfully.The new translations for the workspace selection process have been correctly added to the Hebrew localization file. These additions will improve the user experience for Hebrew-speaking users when selecting and managing workspaces.
packages/ui-core/i18n/assets/i18n/en.json (3)
Line range hint
1-4791
: New workspace management translations added successfully.The changes in this section introduce new translations for workspace-related functionality. The additions include:
- Translations for signing in to workspaces
- Creating new workspaces
- Finding existing workspaces
- Success and failure messages for workspace sign-in
These new translations are well-structured and consistent with the existing content. They will improve the user experience for workspace management features.
4792-4799
: Workspace selection translations added successfully.This section introduces new translations specifically for the workspace selection process:
- Welcome back message
- Friendly greeting ("You look nice today!")
- Instructions for selecting a workspace when an email is associated with multiple workspaces
- Label for the workspace selection action
These additions enhance the user experience during the workspace selection process and maintain a consistent, friendly tone.
Line range hint
4800-4816
: Existing translations remain unchanged and consistent.This final section of the file contains translations for various miscellaneous items, including:
- Image-related messages
- Server API labels
- A "coming soon" message
These translations remain unchanged and do not conflict with the new workspace-related additions. The consistency of this section has been maintained.
packages/ui-core/i18n/assets/i18n/bg.json (1)
4653-4660
: New workspace-related translations added successfully.The following new keys have been added to the "WORKSPACES" section:
- "FIND_WORKSPACE": "Намерете вашето работно пространство"
- "SELECTION" subsection with various keys
These additions enhance the localization for the workspace selection component. The translations appear to be well-formed and contextually appropriate.
packages/ui-core/i18n/assets/i18n/ru.json (3)
4640-4641
: New translation added for workspace searchThe translation for "Find your workspaces" has been added in Russian. This is consistent with the application's internationalization efforts.
4641-4647
: New translations added for workspace selectionSeveral new translations have been added under the "SELECTION" key, providing Russian translations for various messages related to workspace selection. These additions enhance the user experience for Russian-speaking users.
Line range hint
1-4647
: LGTM! Translations successfully addedThe new Russian translations for workspace-related functionality have been successfully added to the file. The changes are consistent with the existing structure and style of the translations. These additions will improve the user experience for Russian-speaking users when interacting with workspace features.
packages/ui-core/i18n/assets/i18n/nl.json (3)
4643-4644
: New workspace-related translations addedThe following new translations have been added for finding workspaces:
"FIND_WORKSPACE": "Vind je werkruimtes",This addition is consistent with the existing structure and provides a Dutch translation for the "Find Workspace" functionality.
4645-4650
: New selections-related translations addedNew translations have been added under the "SELECTION" subsection:
"SELECTION": { "WELCOME_BACK": "Welkom terug!", "YOU_LOOK_NICE_TODAY": "Je ziet er vandaag goed uit!", "EMAIL_MULTIPLE_WORKSPACE": "De e-mail is gekoppeld aan meerdere werkruimtes, selecteer er een om verder te gaan", "SELECT_WORKSPACE_FOR": "Selecteer werkruimte voor", "OPEN": "Openen" }These additions provide Dutch translations for various messages related to workspace selection. The translations appear to be accurate and consistent with the existing style.
Line range hint
4651-4654
: Existing translations for image-related messagesThe following translations for image-related messages are present:
"NO_IMAGE": { "ADD_DROP": "Afbeelding toevoegen of verwijderen", "AVAILABLE": "Afbeelding niet beschikbaar" }These translations are consistent with the rest of the file and provide Dutch equivalents for image-related messages.
packages/ui-core/i18n/assets/i18n/pl.json (1)
4643-4650
: New workspace selection translations added successfully!The new translations for the workspace selection feature have been added correctly. These additions include:
- A "Find your workspaces" message
- A "Welcome back!" greeting
- A compliment "You look nice today!"
- Messages related to email association with multiple workspaces
- Instructions for selecting a workspace
- An "Open" action label
The translations appear to be grammatically correct and contextually appropriate. Good job on expanding the Polish language support for the workspace selection feature.
packages/ui-core/i18n/assets/i18n/it.json (2)
4643-4650
: New workspace selection translations added successfully.The new translations for workspace selection have been added correctly to the Italian language file. These additions include welcome messages, instructions for selecting a workspace, and related UI text. This enhancement will improve the user experience for Italian-speaking users when dealing with multiple workspaces.
Line range hint
1-4651
: Changes implemented successfully with no major issues.The addition of workspace selection translations to the Italian language file has been completed successfully. The new content is well-integrated into the existing structure, and no major issues were identified during the review. The file maintains its overall integrity and consistency.
The implemented changes will positively impact the user experience for Italian-speaking users, particularly when dealing with multiple workspaces. With the minor suggestions for improvement mentioned earlier, this update effectively enhances the localization support for the application.
packages/ui-core/i18n/assets/i18n/pt.json (3)
4643-4650
: New workspace selection translations added successfully.The following translations have been added to the "WORKSPACES.SELECTION" section:
- Welcome back message
- Compliment for the user
- Instructions for selecting a workspace when an email is associated with multiple workspaces
- Prompt to select a workspace
- "Open" button text
These additions enhance the user experience for Portuguese-speaking users when interacting with workspace selection features.
Line range hint
4651-4654
: New "NO_IMAGE" section added successfully.A new section "NO_IMAGE" has been added with two translations:
- "ADD_DROP": For adding or removing an image
- "AVAILABLE": For indicating that an image is not available
These translations will improve user understanding when dealing with image-related features in the Portuguese version of the application.
Line range hint
4655-4656
: New API server-related translations added.Two new translations have been added:
- "SERVER_API": "Servidor API"
- "SERVER_API_LOG": "Log do servidor API"
These translations will help Portuguese-speaking users better understand references to the API server and its log in the application.
packages/ui-core/i18n/assets/i18n/es.json (3)
4645-4652
: New workspace-related translations added successfully.The new translations for the "WORKSPACES" section have been added correctly. These additions include:
- A translation for finding a workspace
- A "SELECTION" subsection with welcome messages and workspace selection prompts
The new translations are consistent with the existing style and structure of the file, which is good for maintainability.
Line range hint
4653-4656
: New "NO_IMAGE" section added successfully.A new "NO_IMAGE" section has been added to the translation file, providing Spanish translations for image-related messages. This addition is well-formatted and consistent with the rest of the file. These translations will likely be used in features related to image handling, such as upload interfaces or placeholder messages for missing images.
Line range hint
4657-4658
: Server API-related translations added.Two new translations have been added for server API-related terms:
- "SERVER_API": "Servidor API"
- "SERVER_API_LOG": "Registro del servidor API"
These additions are simple and clear, providing Spanish translations for what appear to be server API features or logs.
packages/ui-core/i18n/assets/i18n/fr.json (3)
Line range hint
1-4643
: Comprehensive and well-structured translationsThe French translations provided in this segment are extensive and well-organized. The JSON structure is correct, and the translations cover a wide range of UI elements, messages, and features. The consistency in tone and style suggests a professional translation effort.
4644-4651
: Consistent workspace-related translations addedThe newly added translations for workspace-related messages are consistent with the existing content in terms of structure and style. These additions will improve the user experience for French-speaking users when interacting with workspace features.
Line range hint
4652-4658
: Appropriate translations for image-related messagesThe translations for "NO_IMAGE" related messages are appropriate and consistent with the overall style of the document. The JSON structure is correct, and the content is relevant.
☁️ Nx Cloud ReportCI is running/has finished running commands for commit 9384fc3. As they complete they will appear below. Click to see the status, the terminal output, and the build insights. 📂 See all runs for this CI Pipeline Execution
✅ Successfully ran 1 targetSent with 💌 from NxCloud. |
PR
Please note: we will close your PR without comment if you do not check the boxes above and provide ALL requested information.
Summary by CodeRabbit
New Features
Bug Fixes