Lhc_fl
(Linca)
16 يوليو 2024، 7:19ص
9
شكراً لردك المفصل! تم دمج إصلاح الخطأ:
main ← add-plurial-hungarian
opened 07:04AM - 16 Jul 24 UTC
Hungarian actually has a plural form (See: https://meta.discourse.org/t/issue-wi… th-pluralized-count-translation-override/316019/8)
In a past commit we introduced an external JS library to describe the plural form of the language. (https://github.com/discourse/discourse/commit/301713ef9631e52975781b60b8b4c4a0d75530cf)
https://github.com/discourse/discourse/blob/main/app/assets/javascripts/discourse-i18n/src/index.js#L7
```javascript
import * as Cardinals from "make-plural/cardinals";
```
But this JS library actually has a slightly different pluralization definition than what we use in the backend (`plurals.rb`). ruby-i18n incorrectly assumes that Hungarian does not have plural forms. This resulted in singular text being used on the front end for Hungarian, but admins were unable to find and edit the singular text in customization.
This commit adds a singular definition for Hungarian to the backend, compatible with the "make-plural/cardinals" library, thus fixing the above issue.
يضيف الإصلاح الصيغة :one للغة المجرية. قد يتمكن مترجمو Crowdin المستقبليون من محاولة إزالة %{count} للصيغة المفردة لجعلها تبدو مختلفة عن الصيغة :other.
5 إعجابات