plural-rules
Version:
Evaluates plural rules, so that localization libraries can choose the right plural form.
418 lines (411 loc) • 21.2 kB
JavaScript
'use strict';
var parsePluralRule = require('cldrpluralruleparser');
function parsePluralForms (serializedForms) {
return serializedForms
.split(',')
.reduce((result, serializedForm) => {
const parts = serializedForm.split(':');
result[parts[0]] = +parts[1];
return result
}, {})
}
function indexPluralForms (forms, rules) {
return Object
.keys(forms)
.reduce((result, formName) => {
let rule = forms[formName];
if (typeof rule === 'string') {
rule = rule
.trim()
.replace(/ {2}/g, ' ');
let ruleIndex = rules.indexOf(rule);
if (ruleIndex < 0) {
ruleIndex = rules.length;
rules.push(rule);
}
rule = ruleIndex;
}
if (formName.length > 17) {
formName = formName.substr(17);
}
result[formName] = rule;
return result
}, {})
}
let rules = [];
let cardinals = {};
function normalizeLocale (locale) {
return locale.toLowerCase().replace('_', '-')
}
function getLanguage (locale) {
const separator = locale.indexOf('-');
return separator > 0 && locale.substr(0, separator)
}
function getPluralRulesForCardinals (locale) {
locale = normalizeLocale(locale);
let forms = cardinals[locale];
let language;
if (forms === undefined) {
language = getLanguage(locale);
if (language) {
forms = cardinals[language];
}
}
if (forms === undefined) {
throw new Error(`Unrecognised locale: "${locale}".`)
} else if (typeof forms === 'string') {
forms = parsePluralForms(forms);
cardinals[language || locale] = forms;
}
return forms
}
function getPluralFormForCardinal (locale, count) {
const forms = typeof locale !== 'string'
? locale
: getPluralRulesForCardinals(locale);
for (const form in forms) {
const rule = forms[form];
if (parsePluralRule(rules[rule], count)) {
return form
}
}
}
function setPluralFormsForCardinals (locale, forms) {
locale = normalizeLocale(locale);
cardinals[locale] = indexPluralForms(forms, rules);
}
function populatePluralData (data) {
rules = data.rules;
cardinals = data.cardinals;
}
let supportedLocales;
function getSupportedLocales() {
if (!supportedLocales) supportedLocales = Object.keys(cardinals);
return supportedLocales
}
function getPluralFormsForLocale(locale) {
const cardinal = cardinals[locale];
if (cardinal === undefined) return
return cardinal
.split(',')
.map(form => form.substring(0, form.indexOf(':')))
}
var pluralData = {
"version": {
"_unicodeVersion": "12.1.0",
"_cldrVersion": "36"
},
"rules": [
"n = 1 @integer 1 @decimal 1.0, 1.00, 1.000, 1.0000",
"@integer 0, 2~16, 100, 1000, 10000, 100000, 1000000, … @decimal 0.0~0.9, 1.1~1.6, 10.0, 100.0, 1000.0, 10000.0, 100000.0, 1000000.0, …",
"n = 0..1 @integer 0, 1 @decimal 0.0, 1.0, 0.00, 1.00, 0.000, 1.000, 0.0000, 1.0000",
"@integer 2~17, 100, 1000, 10000, 100000, 1000000, … @decimal 0.1~0.9, 1.1~1.7, 10.0, 100.0, 1000.0, 10000.0, 100000.0, 1000000.0, …",
"i = 0 or n = 1 @integer 0, 1 @decimal 0.0~1.0, 0.00~0.04",
"@integer 2~17, 100, 1000, 10000, 100000, 1000000, … @decimal 1.1~2.6, 10.0, 100.0, 1000.0, 10000.0, 100000.0, 1000000.0, …",
"n = 0 @integer 0 @decimal 0.0, 0.00, 0.000, 0.0000",
"n = 2 @integer 2 @decimal 2.0, 2.00, 2.000, 2.0000",
"n % 100 = 3..10 @integer 3~10, 103~110, 1003, … @decimal 3.0, 4.0, 5.0, 6.0, 7.0, 8.0, 9.0, 10.0, 103.0, 1003.0, …",
"n % 100 = 11..99 @integer 11~26, 111, 1011, … @decimal 11.0, 12.0, 13.0, 14.0, 15.0, 16.0, 17.0, 18.0, 111.0, 1011.0, …",
"@integer 100~102, 200~202, 300~302, 400~402, 500~502, 600, 1000, 10000, 100000, 1000000, … @decimal 0.1~0.9, 1.1~1.7, 10.1, 100.0, 1000.0, 10000.0, 100000.0, 1000000.0, …",
"i = 1 and v = 0 @integer 1",
"@integer 0, 2~16, 100, 1000, 10000, 100000, 1000000, … @decimal 0.0~1.5, 10.0, 100.0, 1000.0, 10000.0, 100000.0, 1000000.0, …",
"n % 10 = 1 and n % 100 != 11 @integer 1, 21, 31, 41, 51, 61, 71, 81, 101, 1001, … @decimal 1.0, 21.0, 31.0, 41.0, 51.0, 61.0, 71.0, 81.0, 101.0, 1001.0, …",
"n % 10 = 2..4 and n % 100 != 12..14 @integer 2~4, 22~24, 32~34, 42~44, 52~54, 62, 102, 1002, … @decimal 2.0, 3.0, 4.0, 22.0, 23.0, 24.0, 32.0, 33.0, 102.0, 1002.0, …",
"n % 10 = 0 or n % 10 = 5..9 or n % 100 = 11..14 @integer 0, 5~19, 100, 1000, 10000, 100000, 1000000, … @decimal 0.0, 5.0, 6.0, 7.0, 8.0, 9.0, 10.0, 11.0, 100.0, 1000.0, 10000.0, 100000.0, 1000000.0, …",
"@decimal 0.1~0.9, 1.1~1.7, 10.1, 100.1, 1000.1, …",
"@integer 0~15, 100, 1000, 10000, 100000, 1000000, … @decimal 0.0~1.5, 10.0, 100.0, 1000.0, 10000.0, 100000.0, 1000000.0, …",
"n % 10 = 1 and n % 100 != 11,71,91 @integer 1, 21, 31, 41, 51, 61, 81, 101, 1001, … @decimal 1.0, 21.0, 31.0, 41.0, 51.0, 61.0, 81.0, 101.0, 1001.0, …",
"n % 10 = 2 and n % 100 != 12,72,92 @integer 2, 22, 32, 42, 52, 62, 82, 102, 1002, … @decimal 2.0, 22.0, 32.0, 42.0, 52.0, 62.0, 82.0, 102.0, 1002.0, …",
"n % 10 = 3..4,9 and n % 100 != 10..19,70..79,90..99 @integer 3, 4, 9, 23, 24, 29, 33, 34, 39, 43, 44, 49, 103, 1003, … @decimal 3.0, 4.0, 9.0, 23.0, 24.0, 29.0, 33.0, 34.0, 103.0, 1003.0, …",
"n != 0 and n % 1000000 = 0 @integer 1000000, … @decimal 1000000.0, 1000000.00, 1000000.000, …",
"@integer 0, 5~8, 10~20, 100, 1000, 10000, 100000, … @decimal 0.0~0.9, 1.1~1.6, 10.0, 100.0, 1000.0, 10000.0, 100000.0, …",
"v = 0 and i % 10 = 1 and i % 100 != 11 or f % 10 = 1 and f % 100 != 11 @integer 1, 21, 31, 41, 51, 61, 71, 81, 101, 1001, … @decimal 0.1, 1.1, 2.1, 3.1, 4.1, 5.1, 6.1, 7.1, 10.1, 100.1, 1000.1, …",
"v = 0 and i % 10 = 2..4 and i % 100 != 12..14 or f % 10 = 2..4 and f % 100 != 12..14 @integer 2~4, 22~24, 32~34, 42~44, 52~54, 62, 102, 1002, … @decimal 0.2~0.4, 1.2~1.4, 2.2~2.4, 3.2~3.4, 4.2~4.4, 5.2, 10.2, 100.2, 1000.2, …",
"@integer 0, 5~19, 100, 1000, 10000, 100000, 1000000, … @decimal 0.0, 0.5~1.0, 1.5~2.0, 2.5~2.7, 10.0, 100.0, 1000.0, 10000.0, 100000.0, 1000000.0, …",
"v = 0 and i = 1,2,3 or v = 0 and i % 10 != 4,6,9 or v != 0 and f % 10 != 4,6,9 @integer 0~3, 5, 7, 8, 10~13, 15, 17, 18, 20, 21, 100, 1000, 10000, 100000, 1000000, … @decimal 0.0~0.3, 0.5, 0.7, 0.8, 1.0~1.3, 1.5, 1.7, 1.8, 2.0, 2.1, 10.0, 100.0, 1000.0, 10000.0, 100000.0, 1000000.0, …",
"@integer 4, 6, 9, 14, 16, 19, 24, 26, 104, 1004, … @decimal 0.4, 0.6, 0.9, 1.4, 1.6, 1.9, 2.4, 2.6, 10.4, 100.4, 1000.4, …",
"i = 2..4 and v = 0 @integer 2~4",
"v != 0 @decimal 0.0~1.5, 10.0, 100.0, 1000.0, 10000.0, 100000.0, 1000000.0, …",
"@integer 0, 5~19, 100, 1000, 10000, 100000, 1000000, …",
"n = 3 @integer 3 @decimal 3.0, 3.00, 3.000, 3.0000",
"n = 6 @integer 6 @decimal 6.0, 6.00, 6.000, 6.0000",
"@integer 4, 5, 7~20, 100, 1000, 10000, 100000, 1000000, … @decimal 0.1~0.9, 1.1~1.7, 10.0, 100.0, 1000.0, 10000.0, 100000.0, 1000000.0, …",
"n = 1 or t != 0 and i = 0,1 @integer 1 @decimal 0.1~1.6",
"@integer 0, 2~16, 100, 1000, 10000, 100000, 1000000, … @decimal 0.0, 2.0~3.4, 10.0, 100.0, 1000.0, 10000.0, 100000.0, 1000000.0, …",
"v = 0 and i % 100 = 1 or f % 100 = 1 @integer 1, 101, 201, 301, 401, 501, 601, 701, 1001, … @decimal 0.1, 1.1, 2.1, 3.1, 4.1, 5.1, 6.1, 7.1, 10.1, 100.1, 1000.1, …",
"v = 0 and i % 100 = 2 or f % 100 = 2 @integer 2, 102, 202, 302, 402, 502, 602, 702, 1002, … @decimal 0.2, 1.2, 2.2, 3.2, 4.2, 5.2, 6.2, 7.2, 10.2, 100.2, 1000.2, …",
"v = 0 and i % 100 = 3..4 or f % 100 = 3..4 @integer 3, 4, 103, 104, 203, 204, 303, 304, 403, 404, 503, 504, 603, 604, 703, 704, 1003, … @decimal 0.3, 0.4, 1.3, 1.4, 2.3, 2.4, 3.3, 3.4, 4.3, 4.4, 5.3, 5.4, 6.3, 6.4, 7.3, 7.4, 10.3, 100.3, 1000.3, …",
"i = 0,1 @integer 0, 1 @decimal 0.0~1.5",
"@integer 2~17, 100, 1000, 10000, 100000, 1000000, … @decimal 2.0~3.5, 10.0, 100.0, 1000.0, 10000.0, 100000.0, 1000000.0, …",
"n = 3..6 @integer 3~6 @decimal 3.0, 4.0, 5.0, 6.0, 3.00, 4.00, 5.00, 6.00, 3.000, 4.000, 5.000, 6.000, 3.0000, 4.0000, 5.0000, 6.0000",
"n = 7..10 @integer 7~10 @decimal 7.0, 8.0, 9.0, 10.0, 7.00, 8.00, 9.00, 10.00, 7.000, 8.000, 9.000, 10.000, 7.0000, 8.0000, 9.0000, 10.0000",
"@integer 0, 11~25, 100, 1000, 10000, 100000, 1000000, … @decimal 0.0~0.9, 1.1~1.6, 10.1, 100.0, 1000.0, 10000.0, 100000.0, 1000000.0, …",
"n = 1,11 @integer 1, 11 @decimal 1.0, 11.0, 1.00, 11.00, 1.000, 11.000, 1.0000",
"n = 2,12 @integer 2, 12 @decimal 2.0, 12.0, 2.00, 12.00, 2.000, 12.000, 2.0000",
"n = 3..10,13..19 @integer 3~10, 13~19 @decimal 3.0, 4.0, 5.0, 6.0, 7.0, 8.0, 9.0, 10.0, 13.0, 14.0, 15.0, 16.0, 17.0, 18.0, 19.0, 3.00",
"@integer 0, 20~34, 100, 1000, 10000, 100000, 1000000, … @decimal 0.0~0.9, 1.1~1.6, 10.1, 100.0, 1000.0, 10000.0, 100000.0, 1000000.0, …",
"v = 0 and i % 10 = 1 @integer 1, 11, 21, 31, 41, 51, 61, 71, 101, 1001, …",
"v = 0 and i % 10 = 2 @integer 2, 12, 22, 32, 42, 52, 62, 72, 102, 1002, …",
"v = 0 and i % 100 = 0,20,40,60,80 @integer 0, 20, 40, 60, 80, 100, 120, 140, 1000, 10000, 100000, 1000000, …",
"@integer 3~10, 13~19, 23, 103, 1003, …",
"i = 2 and v = 0 @integer 2",
"v = 0 and n != 0..10 and n % 10 = 0 @integer 20, 30, 40, 50, 60, 70, 80, 90, 100, 1000, 10000, 100000, 1000000, …",
"@integer 0, 3~17, 101, 1001, … @decimal 0.0~1.5, 10.0, 100.0, 1000.0, 10000.0, 100000.0, 1000000.0, …",
"t = 0 and i % 10 = 1 and i % 100 != 11 or t != 0 @integer 1, 21, 31, 41, 51, 61, 71, 81, 101, 1001, … @decimal 0.1~1.6, 10.1, 100.1, 1000.1, …",
"@integer 0, 2~16, 100, 1000, 10000, 100000, 1000000, … @decimal 0.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0, 10.0, 100.0, 1000.0, 10000.0, 100000.0, 1000000.0, …",
"@integer 0, 3~17, 100, 1000, 10000, 100000, 1000000, … @decimal 0.0~0.9, 1.1~1.6, 10.0, 100.0, 1000.0, 10000.0, 100000.0, 1000000.0, …",
"n % 100 = 2,22,42,62,82 or n % 1000 = 0 and n % 100000 = 1000..20000,40000,60000,80000 or n != 0 and n % 1000000 = 100000 @integer 2, 22, 42, 62, 82, 102, 122, 142, 1000, 10000, 100000, … @decimal 2.0, 22.0, 42.0, 62.0, 82.0, 102.0, 122.0, 142.0, 1000.0, 10000.0, 100000.0, …",
"n % 100 = 3,23,43,63,83 @integer 3, 23, 43, 63, 83, 103, 123, 143, 1003, … @decimal 3.0, 23.0, 43.0, 63.0, 83.0, 103.0, 123.0, 143.0, 1003.0, …",
"n != 1 and n % 100 = 1,21,41,61,81 @integer 21, 41, 61, 81, 101, 121, 141, 161, 1001, … @decimal 21.0, 41.0, 61.0, 81.0, 101.0, 121.0, 141.0, 161.0, 1001.0, …",
"@integer 4~19, 100, 1004, 1000000, … @decimal 0.1~0.9, 1.1~1.7, 10.0, 100.0, 1000.1, 1000000.0, …",
"i = 0,1 and n != 0 @integer 1 @decimal 0.1~1.6",
"n % 10 = 1 and n % 100 != 11..19 @integer 1, 21, 31, 41, 51, 61, 71, 81, 101, 1001, … @decimal 1.0, 21.0, 31.0, 41.0, 51.0, 61.0, 71.0, 81.0, 101.0, 1001.0, …",
"n % 10 = 2..9 and n % 100 != 11..19 @integer 2~9, 22~29, 102, 1002, … @decimal 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0, 9.0, 22.0, 102.0, 1002.0, …",
"f != 0 @decimal 0.1~0.9, 1.1~1.7, 10.1, 100.1, 1000.1, …",
"@integer 0, 10~20, 30, 40, 50, 60, 100, 1000, 10000, 100000, 1000000, … @decimal 0.0, 10.0, 11.0, 12.0, 13.0, 14.0, 15.0, 16.0, 100.0, 1000.0, 10000.0, 100000.0, 1000000.0, …",
"n % 10 = 0 or n % 100 = 11..19 or v = 2 and f % 100 = 11..19 @integer 0, 10~20, 30, 40, 50, 60, 100, 1000, 10000, 100000, 1000000, … @decimal 0.0, 10.0, 11.0, 12.0, 13.0, 14.0, 15.0, 16.0, 100.0, 1000.0, 10000.0, 100000.0, 1000000.0, …",
"n % 10 = 1 and n % 100 != 11 or v = 2 and f % 10 = 1 and f % 100 != 11 or v != 2 and f % 10 = 1 @integer 1, 21, 31, 41, 51, 61, 71, 81, 101, 1001, … @decimal 0.1, 1.0, 1.1, 2.1, 3.1, 4.1, 5.1, 6.1, 7.1, 10.1, 100.1, 1000.1, …",
"@integer 2~9, 22~29, 102, 1002, … @decimal 0.2~0.9, 1.2~1.9, 10.2, 100.2, 1000.2, …",
"@integer 0, 2~16, 100, 1000, 10000, 100000, 1000000, … @decimal 0.0, 0.2~1.0, 1.2~1.7, 10.0, 100.0, 1000.0, 10000.0, 100000.0, 1000000.0, …",
"v != 0 or n = 0 or n % 100 = 2..19 @integer 0, 2~16, 102, 1002, … @decimal 0.0~1.5, 10.0, 100.0, 1000.0, 10000.0, 100000.0, 1000000.0, …",
"@integer 20~35, 100, 1000, 10000, 100000, 1000000, …",
"n = 0 or n % 100 = 2..10 @integer 0, 2~10, 102~107, 1002, … @decimal 0.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0, 10.0, 102.0, 1002.0, …",
"n % 100 = 11..19 @integer 11~19, 111~117, 1011, … @decimal 11.0, 12.0, 13.0, 14.0, 15.0, 16.0, 17.0, 18.0, 111.0, 1011.0, …",
"@integer 20~35, 100, 1000, 10000, 100000, 1000000, … @decimal 0.1~0.9, 1.1~1.7, 10.1, 100.0, 1000.0, 10000.0, 100000.0, 1000000.0, …",
"v = 0 and i % 10 = 2..4 and i % 100 != 12..14 @integer 2~4, 22~24, 32~34, 42~44, 52~54, 62, 102, 1002, …",
"v = 0 and i != 1 and i % 10 = 0..1 or v = 0 and i % 10 = 5..9 or v = 0 and i % 100 = 12..14 @integer 0, 5~19, 100, 1000, 10000, 100000, 1000000, …",
"@decimal 0.0~1.5, 10.0, 100.0, 1000.0, 10000.0, 100000.0, 1000000.0, …",
"i = 0..1 @integer 0, 1 @decimal 0.0~1.5",
"v = 0 and i % 10 = 1 and i % 100 != 11 @integer 1, 21, 31, 41, 51, 61, 71, 81, 101, 1001, …",
"v = 0 and i % 10 = 0 or v = 0 and i % 10 = 5..9 or v = 0 and i % 100 = 11..14 @integer 0, 5~19, 100, 1000, 10000, 100000, 1000000, …",
"n = 2..10 @integer 2~10 @decimal 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0, 9.0, 10.0, 2.00, 3.00, 4.00, 5.00, 6.00, 7.00, 8.00",
"@integer 11~26, 100, 1000, 10000, 100000, 1000000, … @decimal 1.1~1.9, 2.1~2.7, 10.1, 100.0, 1000.0, 10000.0, 100000.0, 1000000.0, …",
"n = 0,1 or i = 0 and f = 1 @integer 0, 1 @decimal 0.0, 0.1, 1.0, 0.00, 0.01, 1.00, 0.000, 0.001, 1.000, 0.0000, 0.0001, 1.0000",
"@integer 2~17, 100, 1000, 10000, 100000, 1000000, … @decimal 0.2~0.9, 1.1~1.8, 10.0, 100.0, 1000.0, 10000.0, 100000.0, 1000000.0, …",
"v = 0 and i % 100 = 1 @integer 1, 101, 201, 301, 401, 501, 601, 701, 1001, …",
"v = 0 and i % 100 = 2 @integer 2, 102, 202, 302, 402, 502, 602, 702, 1002, …",
"v = 0 and i % 100 = 3..4 or v != 0 @integer 3, 4, 103, 104, 203, 204, 303, 304, 403, 404, 503, 504, 603, 604, 703, 704, 1003, … @decimal 0.0~1.5, 10.0, 100.0, 1000.0, 10000.0, 100000.0, 1000000.0, …",
"n = 0..1 or n = 11..99 @integer 0, 1, 11~24 @decimal 0.0, 1.0, 11.0, 12.0, 13.0, 14.0, 15.0, 16.0, 17.0, 18.0, 19.0, 20.0, 21.0, 22.0, 23.0, 24.0",
"@integer 2~10, 100~106, 1000, 10000, 100000, 1000000, … @decimal 0.1~0.9, 1.1~1.7, 10.0, 100.0, 1000.0, 10000.0, 100000.0, 1000000.0, …"
],
"cardinals": {
"af": "one:0,other:1",
"ak": "one:2,other:3",
"am": "one:4,other:5",
"an": "one:0,other:1",
"ar": "zero:6,one:0,two:7,few:8,many:9,other:10",
"ars": "zero:6,one:0,two:7,few:8,many:9,other:10",
"as": "one:4,other:5",
"asa": "one:0,other:1",
"ast": "one:11,other:12",
"az": "one:0,other:1",
"be": "one:13,few:14,many:15,other:16",
"bem": "one:0,other:1",
"bez": "one:0,other:1",
"bg": "one:0,other:1",
"bho": "one:2,other:3",
"bm": "other:17",
"bn": "one:4,other:5",
"bo": "other:17",
"br": "one:18,two:19,few:20,many:21,other:22",
"brx": "one:0,other:1",
"bs": "one:23,few:24,other:25",
"ca": "one:11,other:12",
"ce": "one:0,other:1",
"ceb": "one:26,other:27",
"cgg": "one:0,other:1",
"chr": "one:0,other:1",
"ckb": "one:0,other:1",
"cs": "one:11,few:28,many:29,other:30",
"cy": "zero:6,one:0,two:7,few:31,many:32,other:33",
"da": "one:34,other:35",
"de": "one:11,other:12",
"dsb": "one:36,two:37,few:38,other:25",
"dv": "one:0,other:1",
"dz": "other:17",
"ee": "one:0,other:1",
"el": "one:0,other:1",
"en": "one:11,other:12",
"eo": "one:0,other:1",
"es": "one:0,other:1",
"et": "one:11,other:12",
"eu": "one:0,other:1",
"fa": "one:4,other:5",
"ff": "one:39,other:40",
"fi": "one:11,other:12",
"fil": "one:26,other:27",
"fo": "one:0,other:1",
"fr": "one:39,other:40",
"fur": "one:0,other:1",
"fy": "one:11,other:12",
"ga": "one:0,two:7,few:41,many:42,other:43",
"gd": "one:44,two:45,few:46,other:47",
"gl": "one:11,other:12",
"gsw": "one:0,other:1",
"gu": "one:4,other:5",
"guw": "one:2,other:3",
"gv": "one:48,two:49,few:50,many:29,other:51",
"ha": "one:0,other:1",
"haw": "one:0,other:1",
"he": "one:11,two:52,many:53,other:54",
"hi": "one:4,other:5",
"hr": "one:23,few:24,other:25",
"hsb": "one:36,two:37,few:38,other:25",
"hu": "one:0,other:1",
"hy": "one:39,other:40",
"ia": "one:11,other:12",
"id": "other:17",
"ig": "other:17",
"ii": "other:17",
"in": "other:17",
"io": "one:11,other:12",
"is": "one:55,other:56",
"it": "one:11,other:12",
"iu": "one:0,two:7,other:57",
"iw": "one:11,two:52,many:53,other:54",
"ja": "other:17",
"jbo": "other:17",
"jgo": "one:0,other:1",
"ji": "one:11,other:12",
"jmc": "one:0,other:1",
"jv": "other:17",
"jw": "other:17",
"ka": "one:0,other:1",
"kab": "one:39,other:40",
"kaj": "one:0,other:1",
"kcg": "one:0,other:1",
"kde": "other:17",
"kea": "other:17",
"kk": "one:0,other:1",
"kkj": "one:0,other:1",
"kl": "one:0,other:1",
"km": "other:17",
"kn": "one:4,other:5",
"ko": "other:17",
"ks": "one:0,other:1",
"ksb": "one:0,other:1",
"ksh": "zero:6,one:0,other:3",
"ku": "one:0,other:1",
"kw": "zero:6,one:0,two:58,few:59,many:60,other:61",
"ky": "one:0,other:1",
"lag": "zero:6,one:62,other:40",
"lb": "one:0,other:1",
"lg": "one:0,other:1",
"lkt": "other:17",
"ln": "one:2,other:3",
"lo": "other:17",
"lt": "one:63,few:64,many:65,other:66",
"lv": "zero:67,one:68,other:69",
"mas": "one:0,other:1",
"mg": "one:2,other:3",
"mgo": "one:0,other:1",
"mk": "one:23,other:70",
"ml": "one:0,other:1",
"mn": "one:0,other:1",
"mo": "one:11,few:71,other:72",
"mr": "one:0,other:1",
"ms": "other:17",
"mt": "one:0,few:73,many:74,other:75",
"my": "other:17",
"nah": "one:0,other:1",
"naq": "one:0,two:7,other:57",
"nb": "one:0,other:1",
"nd": "one:0,other:1",
"ne": "one:0,other:1",
"nl": "one:11,other:12",
"nn": "one:0,other:1",
"nnh": "one:0,other:1",
"no": "one:0,other:1",
"nqo": "other:17",
"nr": "one:0,other:1",
"nso": "one:2,other:3",
"ny": "one:0,other:1",
"nyn": "one:0,other:1",
"om": "one:0,other:1",
"or": "one:0,other:1",
"os": "one:0,other:1",
"osa": "other:17",
"pa": "one:2,other:3",
"pap": "one:0,other:1",
"pl": "one:11,few:76,many:77,other:78",
"prg": "zero:67,one:68,other:69",
"ps": "one:0,other:1",
"pt": "one:79,other:40",
"pt-pt": "one:11,other:12",
"rm": "one:0,other:1",
"ro": "one:11,few:71,other:72",
"rof": "one:0,other:1",
"root": "other:17",
"ru": "one:80,few:76,many:81,other:78",
"rwk": "one:0,other:1",
"sah": "other:17",
"saq": "one:0,other:1",
"sc": "one:11,other:12",
"scn": "one:11,other:12",
"sd": "one:0,other:1",
"sdh": "one:0,other:1",
"se": "one:0,two:7,other:57",
"seh": "one:0,other:1",
"ses": "other:17",
"sg": "other:17",
"sh": "one:23,few:24,other:25",
"shi": "one:4,few:82,other:83",
"si": "one:84,other:85",
"sk": "one:11,few:28,many:29,other:30",
"sl": "one:86,two:87,few:88,other:30",
"sma": "one:0,two:7,other:57",
"smi": "one:0,two:7,other:57",
"smj": "one:0,two:7,other:57",
"smn": "one:0,two:7,other:57",
"sms": "one:0,two:7,other:57",
"sn": "one:0,other:1",
"so": "one:0,other:1",
"sq": "one:0,other:1",
"sr": "one:23,few:24,other:25",
"ss": "one:0,other:1",
"ssy": "one:0,other:1",
"st": "one:0,other:1",
"su": "other:17",
"sv": "one:11,other:12",
"sw": "one:11,other:12",
"syr": "one:0,other:1",
"ta": "one:0,other:1",
"te": "one:0,other:1",
"teo": "one:0,other:1",
"th": "other:17",
"ti": "one:2,other:3",
"tig": "one:0,other:1",
"tk": "one:0,other:1",
"tl": "one:26,other:27",
"tn": "one:0,other:1",
"to": "other:17",
"tr": "one:0,other:1",
"ts": "one:0,other:1",
"tzm": "one:89,other:90",
"ug": "one:0,other:1",
"uk": "one:80,few:76,many:81,other:78",
"ur": "one:11,other:12",
"uz": "one:0,other:1",
"ve": "one:0,other:1",
"vi": "other:17",
"vo": "one:0,other:1",
"vun": "one:0,other:1",
"wa": "one:2,other:3",
"wae": "one:0,other:1",
"wo": "other:17",
"xh": "one:0,other:1",
"xog": "one:0,other:1",
"yi": "one:11,other:12",
"yo": "other:17",
"yue": "other:17",
"zh": "other:17",
"zu": "one:4,other:5"
}
};
populatePluralData(pluralData);
exports.getPluralFormForCardinal = getPluralFormForCardinal;
exports.getPluralFormsForLocale = getPluralFormsForLocale;
exports.getPluralRulesForCardinals = getPluralRulesForCardinals;
exports.getSupportedLocales = getSupportedLocales;
exports.setPluralFormsForCardinals = setPluralFormsForCardinals;
//# sourceMappingURL=index.cjs.map