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

Update and extract all messages to translate #19996

Closed
wants to merge 6 commits into from

Conversation

NabiKAZ
Copy link
Contributor

@NabiKAZ NabiKAZ commented Oct 7, 2023

Some people do not have enough technical knowledge of programming to translate and only translate phrases online on the website.
I ran the yii message/extract messages/config.php command to update all translation files and make the untranslated version of all repository statements available on the web.

@codecov
Copy link

codecov bot commented Oct 7, 2023

Codecov Report

Attention: 2026 lines in your changes are missing coverage. Please review.

Comparison is base (5eeb12f) 49.02% compared to head (a25b5d3) 47.41%.

Additional details and impacted files
@@            Coverage Diff             @@
##           master   #19996      +/-   ##
==========================================
- Coverage   49.02%   47.41%   -1.61%     
==========================================
  Files         445      445              
  Lines       42849    43397     +548     
==========================================
- Hits        21005    20575     -430     
- Misses      21844    22822     +978     
Files Coverage Δ
framework/messages/el/yii.php 0.00% <0.00%> (ø)
framework/messages/sk/yii.php 0.00% <0.00%> (ø)
framework/messages/be/yii.php 0.00% <0.00%> (ø)
framework/messages/bg/yii.php 0.00% <0.00%> (ø)
framework/messages/ja/yii.php 0.00% <0.00%> (ø)
framework/messages/zh/yii.php 0.00% <0.00%> (ø)
framework/messages/af/yii.php 0.00% <0.00%> (ø)
framework/messages/fr/yii.php 0.00% <0.00%> (ø)
framework/messages/ru/yii.php 0.81% <0.00%> (-0.02%) ⬇️
framework/messages/hi/yii.php 0.00% <0.00%> (ø)
... and 41 more

... and 15 files with indirect coverage changes

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@what-the-diff
Copy link

what-the-diff bot commented Oct 7, 2023

PR Summary

  • Arabic and Belarusian Language Enhancements
    New message lines have been added in yii.php for both Arabic and Belarusian languages, including 'Action not found', 'Aliases available: {aliases}', 'Options available: {options}', and '{compareAttribute} is invalid.'

  • Afrikaans Language Modifications
    Certain text phrases have been translated to Afrikaans in the yii.php file.

  • Existing Arabic Language Changes
    Several existing message translations in the Arabic yii.php file have been updated to improve their accuracy.

  • Azerbaijani Language Changes
    Modifications have been made to the Azerbaijani yii.php file. Several string representations about file sizes and units have been replaced with Azerbaijani translations.

  • Bulgarian, Bosnian and Catalan translations
    The files yii.php for Bulgarian, Bosnian, and Catalan languages have undergone updates with new translated strings.

  • Chinese language support
    Chinese language support has been added with new yii.php files for both Traditional Chinese (file `zh-TW/yii.php

@xicond
Copy link
Contributor

xicond commented Oct 14, 2023

what is @@{attribute} mean ?

@NabiKAZ
Copy link
Contributor Author

NabiKAZ commented Oct 15, 2023

what is @@{attribute} mean ?

The parts that no longer exist in the source are placed on both sides of the @@ string, which can be removed in the translation. for example:

'{attribute} must be less than "{compareValue}".' => '@@{attribute}, "{compareValue}" dən kiçik olmalıdır.@@',
  • Each array element represents the translation (value) of a message (key).
  • If the value is empty, the message is considered as not translated.
  • Messages that no longer need translation will have their translations
  • enclosed between a pair of '@@' marks.

@bizley
Copy link
Member

bizley commented Oct 16, 2023

Thanks, indeed it was long overdue. Could you remove the translations with @@ since we don't use them anymore, and apply alphabetical sorting for each?

@rob006
Copy link
Contributor

rob006 commented Oct 16, 2023

#19995 (comment) should be addressed first.

@NabiKAZ
Copy link
Contributor Author

NabiKAZ commented Oct 19, 2023

#19995 (comment) should be addressed first.

Merged.
And I'm waiting to this for doing another commit related this.

@rob006
Copy link
Contributor

rob006 commented Oct 19, 2023

Now there should be no zh-CN directory, since there is no such locale in config.

@NabiKAZ
Copy link
Contributor Author

NabiKAZ commented Oct 20, 2023

Now there should be no zh-CN directory, since there is no such locale in config.

From the beginning, there was no zh-CN directory.
Now according to my latest commits in this branch, now we only have zh and zh-TW in config and directories.

@rob006
Copy link
Contributor

rob006 commented Oct 20, 2023

Your PR added zh-CN directory.

c83c0307

Also, some translations could be fixed, since they only have changed placeholder name.

a1513a9c

@NabiKAZ
Copy link
Contributor Author

NabiKAZ commented Oct 20, 2023

@rob006
You're right, I'm sorry I confused you.
This was due to the yii message command that generated it automatically.

  • Now zh-CN dir has been deleted.
  • master merged and a conflict has also been resolved.
  • As for the @@s, I removed them by adding the --remove-unused parameter to the corresponding command.

@rob006
Copy link
Contributor

rob006 commented Oct 20, 2023

@NabiKAZ I created alternative PR with more translations restored: #20022

@bizley
Copy link
Member

bizley commented Oct 21, 2023

Guys, great job, looks like you managed all here, just tell me which one to merge or both and then in which order. Thank you.

@rob006
Copy link
Contributor

rob006 commented Oct 21, 2023

@bizley I think you should merge mine - it contains everything here + some fixed translations + reordering.

@bizley
Copy link
Member

bizley commented Oct 21, 2023

Closing in favour of #20022

@bizley bizley closed this Oct 21, 2023
@NabiKAZ
Copy link
Contributor Author

NabiKAZ commented Oct 21, 2023

I wrote my review here:
#20022 (comment)

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.

4 participants