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

Add main code for Serbian language #151

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,8 @@ var defaultPluralRules = {
if (lastTwo >= 3 && lastTwo <= 10) return 3;
return lastTwo >= 11 ? 4 : 5;
},
bosnian_serbian: russianPluralGroups,
serbian: russianPluralGroups,
bosnian: russianPluralGroups,
Comment on lines +58 to +59
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

bosnian_serbian must be preserved, or else it's a breaking change.

Suggested change
serbian: russianPluralGroups,
bosnian: russianPluralGroups,
bosnian_serbian: russianPluralGroups,
serbian: russianPluralGroups,
bosnian: russianPluralGroups,

chinese: function () { return 0; },
croatian: russianPluralGroups,
french: function (n) { return n > 1 ? 1 : 0; },
Expand Down Expand Up @@ -96,6 +97,8 @@ var defaultPluralRules = {
pluralTypeToLanguages: {
arabic: ['ar'],
bosnian_serbian: ['bs-Latn-BA', 'bs-Cyrl-BA', 'srl-RS', 'sr-RS'],
serbian: ['sr', 'sr-Cyrl', 'sr-Latn', 'sr-RS'],
bosnian: ['bs', 'bs-Cyrl', 'bs-Latn', 'bs-BA'],
ceracera marked this conversation as resolved.
Show resolved Hide resolved
chinese: ['id', 'id-ID', 'ja', 'ko', 'ko-KR', 'lo', 'ms', 'th', 'th-TH', 'zh'],
croatian: ['hr', 'hr-HR'],
german: ['fa', 'da', 'de', 'en', 'es', 'fi', 'el', 'he', 'hi-IN', 'hu', 'hu-HU', 'it', 'nl', 'no', 'pt', 'sv', 'tr'],
Expand Down