Skip to content
Open
Show file tree
Hide file tree
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
4 changes: 2 additions & 2 deletions packages/@internationalized/number/src/NumberParser.ts
Original file line number Diff line number Diff line change
Expand Up @@ -274,9 +274,9 @@ class NumberParserImpl {

const nonLiteralParts = new Set(['decimal', 'fraction', 'integer', 'minusSign', 'plusSign', 'group']);

// This list is derived from https://www.unicode.org/cldr/charts/43/supplemental/language_plural_rules.html#comparison and includes
// This list is derived from https://www.unicode.org/cldr/charts/49/supplemental/language_plural_rules.html#comparison and includes
// all unique numbers which we need to check in order to determine all the plural forms for a given locale.
// See: https://github.com/adobe/react-spectrum/pull/5134/files#r1337037855 for used script
// Run scripts/generateAllPlurals.mjs to generate this list.
const pluralNumbers = [
0, 4, 2, 1, 11, 20, 3, 7, 100, 21, 0.1, 1.1
];
Expand Down
4 changes: 2 additions & 2 deletions scripts/generateAllPlurals.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
* governing permissions and limitations under the License.
*/

/* Scrapes data on CLDR https://www.unicode.org/cldr/charts/44/supplemental/language_plural_rules.html#comparison
/* Scrapes data on CLDR https://www.unicode.org/cldr/charts/49/supplemental/language_plural_rules.html#comparison
* and generates a list of all possible values needed between all locales for plural rules.
* It is used by our NumberParser to generate all literal strings, ex units 1 foot, 2 feet, but other locales have more than 2 forms.
*/
Expand Down Expand Up @@ -150,7 +150,7 @@ function extractTable(dom, integerTable, fractionTable) {
return Array.from(values);
}

fetch('https://www.unicode.org/cldr/charts/44/supplemental/language_plural_rules.html#comparison')
fetch('https://www.unicode.org/cldr/charts/49/supplemental/language_plural_rules.html#comparison')
.then(async (response) => {
let data = await response.text();
const dom = new JSDOM(data);
Expand Down
Loading