You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Here are some key observations to aid the review process:
⏱️ Estimated effort to review: 2 🔵🔵⚪⚪⚪
🧪 No relevant tests
🔒 No security concerns identified
⚡ Recommended focus areas for review
Language Code Change The language code for Portuguese (Portugal) has been changed from 'pt-pt' to 'pt'. Verify that this change is consistent throughout the application and doesn't break any existing functionality.
JSON Indentation Change The JSON indentation has been changed from 4 spaces to 2 spaces. Ensure this change is intentional and consistent across all configuration files.
Language List Modification The list of supported languages has been modified. Verify that all language codes are correct and that the changes don't affect language selection functionality in the application.
cheton
changed the title
fix(i18n): rename pt-pt to pt for Portuguese (Portugal)
fix(i18n): rename pt-pt to pt for European Portuguese (Portugal)
Oct 17, 2024
-'pt', // European Portuguese (Portugal)-'pt-br', // Brazilian Portuguese (Brazil)+'pt', // European Portuguese (Portugal) - ISO 639-1 code+'pt-br', // Brazilian Portuguese (Brazil) - ISO 639-1 code with country extension
Apply this suggestion
Suggestion importance[1-10]: 7
Why:
7
Remove trailing whitespace to maintain consistency and prevent potential issues
Remove the trailing space in the translation for "Spindle On, CW (M3)". This ensures consistency with other entries and prevents potential issues with string comparisons.
Maintain consistent JSON formatting for improved readability and maintainability
Consider using a consistent format for the JSON object. The new code uses a more compact format without indentation, while the old code used indentation. For consistency and readability, it's recommended to use a consistent indentation style throughout the file.
Add more detailed comments to clarify language code choices
Consider adding a comment to explain the difference between 'pt' and 'pt-br' language codes, as it might not be immediately clear to all developers why both are necessary.
-'pt', // European Portuguese (Portugal)-'pt-br', // Brazilian Portuguese (Brazil)+'pt', // European Portuguese (Portugal) - ISO 639-1 code+'pt-br', // Brazilian Portuguese (Brazil) - ISO 639-1 code with country extension
Suggestion importance[1-10]: 7
Why:
7
Improve German translations for better clarity and idiomatic language use
Consider using more idiomatic German translations for some of the machine states. For example, "Lauf" could be changed to "In Betrieb" for better clarity.
'nl', // Dutch
'pt', // Portuguese (Portugal)
'pt-br', // Portuguese (Brazil)
'ru', // Russian
'tr', // Turkish
'uk', // Ukrainian
'zh-cn', // Simplified Chinese
-'zh-tw', // Traditional Chinese+'zh-tw' // Traditional Chinese
Suggestion importance[1-10]: 7
Why:
7
Consistency
Ensure consistency in translation format for coordinate system entries
Consider using a consistent format for the translation of "P1 (G54)" to "P6 (G59)". Currently, these entries have translations while they were empty before. Ensure this change is intentional and consistent with other language files.
✅ Clarify language code comments to accurately represent supported Portuguese variantsSuggestion Impact:The commit updated the comments for the 'pt' and 'pt-br' language codes to clarify the Portuguese variants, aligning with the suggestion's intent.
✅ Improve German translations for machine states to be more idiomatic and consistent with industry terminologySuggestion Impact:The suggestion was implemented as the translations for "run" were changed to "Lauf" and "home" to "Referenzfahrt" in the commit.
Consider using more idiomatic German translations for some of the machine states. For example, "Ausführen" could be changed to "Lauf" for "run", and "Startposition" to "Referenzfahrt" for "home".
Why: Correcting the spelling from "Suspenção" to "Suspensão" improves the accuracy of the translation, which is crucial for maintaining professionalism and clarity in the translation file.
9
Maintain alphabetical order in the language list for better organization and readability
Consider updating the order of language entries to maintain alphabetical sorting. Move the new 'pt' entry before 'pt-br' to keep the list organized.
Why: The suggestion to maintain alphabetical order in the language list improves organization and readability, making it easier for developers to locate specific entries.
8
✅ Translate missing entries in the G-code translation file to ensure completeness
Consider translating the empty strings for "Active Tool Offset (G43.1)" and "No Tool Offset (G49)" to maintain consistency in the translation file.
Why: The suggestion addresses missing translations for "Active Tool Offset (G43.1)" and "No Tool Offset (G49)", enhancing the completeness and consistency of the translation file.
8
✅ Translate missing M-code command to ensure completeness of the G-code translation file
Translate "Optional Program Stop (M1)" to maintain consistency with other translated M-code commands.
-"Optional Program Stop (M1)": "",+"Optional Program Stop (M1)": "Paragem Opcional do Programa (M1)",
[Suggestion has been applied]
Suggestion importance[1-10]: 8
Why: Translating "Optional Program Stop (M1)" fills a gap in the translation file, ensuring consistency with other translated M-code commands and improving the file's completeness.
8
✅ Standardize translations across different controller types for consistency
For consistency, consider using "Suspensão" instead of "Dormir" for the "sleep" state in the Smoothie section, matching the translation used in the Grbl section.
Why: Changing "Dormir" to "Suspensão" for the "sleep" state in the Smoothie section ensures consistency with the Grbl section, enhancing uniformity across different controller types.
7
Best practice
Maintain consistent comment formatting throughout the language list
Ensure consistency in comment formatting by adding a period at the end of the 'Dutch' comment, similar to other language comments.
Why: While the suggestion to add a period for consistency in comment formatting is valid, it is a minor stylistic improvement with limited impact on the code's functionality or readability.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
PR Type
enhancement, documentation
Description
pt-pt
topt
for Portuguese (Portugal) across various configuration files.Changes walkthrough 📝
build.config.js
Update language code for Portuguese (Portugal) in build configuration
build.config.js
pt-pt
topt
for Portuguese (Portugal).i18n.js
Modify i18n constants for Portuguese (Portugal)
src/app/constants/i18n.js
pt-pt
topt
for Portuguese (Portugal).settings.base.js
Adjust server settings for language codes
src/server/config/settings.base.js
pt-pt
topt
for Portuguese (Portugal).uk
language to Ukrainian.controller.json
Add Portuguese translations for machine states
src/app/i18n/pt/controller.json
gcode.json
Add Portuguese translations for G-code commands
src/app/i18n/pt/gcode.json
resource.json
Add comprehensive Portuguese translations for resources
src/app/i18n/pt/resource.json
config.json
Configure text direction for Portuguese (Portugal)
src/server/i18n/pt/config.json
resource.json
Add server resource translations in Portuguese
src/server/i18n/pt/resource.json