Skip to content
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

Localization for ColorPicker #1154

Merged
merged 1 commit into from
Dec 13, 2024
Merged

Localization for ColorPicker #1154

merged 1 commit into from
Dec 13, 2024

Conversation

diluculo
Copy link
Contributor

@diluculo diluculo commented Dec 12, 2024

This PR adds localization strings for color-related UI components in two areas:

ColorPicker UI Labels (assistance of AI tools)

Added translations for color picker interface elements in all languages:

  • RGB component labels (Red, Green, Blue)
  • HSV component labels (Hue, Saturation, Value)
  • Opacity label
  • Color Mode texts (More/Less)

Color Name Localization

Added standardized color name translations for 16 languages, derived from the UWP ColorHelper.ToDisplayName(Color) implementation.

  • While there are 138 color name keys, they map to 35 distinct color values (in en-US) !!!

The PR aims to establish a foundation for color-related localization, which will be applied to the ColorPicker (#1152) component once it is merged. Future refinements and additions will build upon this base implementation.

Pre-launch Checklist

  • I have updated CHANGELOG.md with my changes
  • I have run "dart format ." on the project
  • I have added/updated relevant documentation

@WinXaito
Copy link
Collaborator

I don't understand, did you translate using Microsoft translations or you translated yourself (with deepl or anything else?)

In the second case, I think the best is to not add these translations until someone that speak the language can translate them.

Because some of the colors translated in french are not that good.

@diluculo
Copy link
Contributor Author

@WinXaito

Let me clarify the two different parts of this PR:

  1. UI Labels (redLabel, greenLabel, etc):
    These were indeed translated with AI assistance (Claude). As you pointed out, we can review and improve these translations with native speakers' help.

  2. Color Names:
    These were not manually translated - they were extracted directly from Windows App SDK's ColorHelper.ToDisplayName() method (docs). Below screenshot is from my WinUI 3 app showing the actual French translations extracted from ColorHelper.ToDisplayName():

image

@diluculo diluculo force-pushed the colornames branch 2 times, most recently from f258fd2 to 148ef6b Compare December 13, 2024 04:28
@diluculo
Copy link
Contributor Author

I've been extracting color names through WinUI 3 app, but color name translations are missing for these locales:

  • Belarusian (be)
  • Kurdish (ku)
  • Burmese (my)
  • Uzbek (uz)

Windows App SDK's ColorHelper.ToDisplayName falls back to English names for these locales.

- Add color name translations to ARB files except for Belarusian (be), Kurdish (ku), Burmese (my), and Uzbek (uz)
- Add getLocalizedColorDisplayName to FluentLocalizationsExtension
- Add ColorPicker UI string translations
@bdlukaa bdlukaa merged commit 558e77d into bdlukaa:master Dec 13, 2024
2 of 3 checks passed
@diluculo diluculo deleted the colornames branch December 16, 2024 00:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants