@formatjs/intl-pluralrules 6.3.15 → 6.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE.md +0 -0
- package/README.md +0 -0
- package/index.d.ts +13 -1
- package/index.js +14 -63
- package/index.js.map +1 -1
- package/locale-data/af.d.ts +0 -0
- package/locale-data/af.js +2 -2
- package/locale-data/ak.d.ts +0 -0
- package/locale-data/ak.js +2 -2
- package/locale-data/am.d.ts +0 -0
- package/locale-data/am.js +2 -2
- package/locale-data/an.d.ts +0 -0
- package/locale-data/an.js +2 -2
- package/locale-data/ar.d.ts +0 -0
- package/locale-data/ar.js +32 -16
- package/locale-data/ars.d.ts +0 -0
- package/locale-data/ars.js +32 -16
- package/locale-data/as.d.ts +0 -0
- package/locale-data/as.js +14 -14
- package/locale-data/asa.d.ts +0 -0
- package/locale-data/asa.js +2 -2
- package/locale-data/ast.d.ts +0 -0
- package/locale-data/ast.js +0 -0
- package/locale-data/az.d.ts +0 -0
- package/locale-data/az.js +26 -10
- package/locale-data/bal.d.ts +0 -0
- package/locale-data/bal.js +4 -4
- package/locale-data/be.d.ts +0 -0
- package/locale-data/be.js +26 -10
- package/locale-data/bem.d.ts +0 -0
- package/locale-data/bem.js +2 -2
- package/locale-data/bez.d.ts +0 -0
- package/locale-data/bez.js +2 -2
- package/locale-data/bg.d.ts +0 -0
- package/locale-data/bg.js +2 -2
- package/locale-data/bho.d.ts +0 -0
- package/locale-data/bho.js +2 -2
- package/locale-data/blo.d.ts +0 -0
- package/locale-data/blo.js +14 -14
- package/locale-data/bm.d.ts +0 -0
- package/locale-data/bm.js +0 -0
- package/locale-data/bn.d.ts +0 -0
- package/locale-data/bn.js +14 -14
- package/locale-data/bo.d.ts +0 -0
- package/locale-data/bo.js +0 -0
- package/locale-data/br.d.ts +0 -0
- package/locale-data/br.js +28 -12
- package/locale-data/brx.d.ts +0 -0
- package/locale-data/brx.js +2 -2
- package/locale-data/bs.d.ts +0 -0
- package/locale-data/bs.js +22 -6
- package/locale-data/ca.d.ts +0 -0
- package/locale-data/ca.js +28 -12
- package/locale-data/ce.d.ts +0 -0
- package/locale-data/ce.js +2 -2
- package/locale-data/ceb.d.ts +0 -0
- package/locale-data/ceb.js +18 -2
- package/locale-data/cgg.d.ts +0 -0
- package/locale-data/cgg.js +2 -2
- package/locale-data/chr.d.ts +0 -0
- package/locale-data/chr.js +2 -2
- package/locale-data/ckb.d.ts +0 -0
- package/locale-data/ckb.js +2 -2
- package/locale-data/cs.d.ts +0 -0
- package/locale-data/cs.js +4 -4
- package/locale-data/csw.d.ts +0 -0
- package/locale-data/csw.js +2 -2
- package/locale-data/cv.d.ts +0 -0
- package/locale-data/cv.js +6 -6
- package/locale-data/cy.d.ts +0 -0
- package/locale-data/cy.js +32 -32
- package/locale-data/da.d.ts +0 -0
- package/locale-data/da.js +2 -2
- package/locale-data/de.d.ts +0 -0
- package/locale-data/de.js +0 -0
- package/locale-data/doi.d.ts +0 -0
- package/locale-data/doi.js +2 -2
- package/locale-data/dsb.d.ts +0 -0
- package/locale-data/dsb.js +24 -8
- package/locale-data/dv.d.ts +0 -0
- package/locale-data/dv.js +2 -2
- package/locale-data/dz.d.ts +0 -0
- package/locale-data/dz.js +0 -0
- package/locale-data/ee.d.ts +0 -0
- package/locale-data/ee.js +2 -2
- package/locale-data/el.d.ts +0 -0
- package/locale-data/el.js +2 -2
- package/locale-data/en.d.ts +0 -0
- package/locale-data/en.js +24 -8
- package/locale-data/eo.d.ts +0 -0
- package/locale-data/eo.js +2 -2
- package/locale-data/es.d.ts +0 -0
- package/locale-data/es.js +22 -6
- package/locale-data/et.d.ts +0 -0
- package/locale-data/et.js +0 -0
- package/locale-data/eu.d.ts +0 -0
- package/locale-data/eu.js +2 -2
- package/locale-data/fa.d.ts +0 -0
- package/locale-data/fa.js +2 -2
- package/locale-data/ff.d.ts +0 -0
- package/locale-data/ff.js +0 -0
- package/locale-data/fi.d.ts +0 -0
- package/locale-data/fi.js +0 -0
- package/locale-data/fil.d.ts +0 -0
- package/locale-data/fil.js +20 -4
- package/locale-data/fo.d.ts +0 -0
- package/locale-data/fo.js +2 -2
- package/locale-data/fr.d.ts +0 -0
- package/locale-data/fr.js +22 -6
- package/locale-data/fur.d.ts +0 -0
- package/locale-data/fur.js +2 -2
- package/locale-data/fy.d.ts +0 -0
- package/locale-data/fy.js +0 -0
- package/locale-data/ga.d.ts +0 -0
- package/locale-data/ga.js +14 -14
- package/locale-data/gd.d.ts +0 -0
- package/locale-data/gd.js +16 -16
- package/locale-data/gl.d.ts +0 -0
- package/locale-data/gl.js +0 -0
- package/locale-data/gsw.d.ts +0 -0
- package/locale-data/gsw.js +2 -2
- package/locale-data/gu.d.ts +0 -0
- package/locale-data/gu.js +14 -14
- package/locale-data/guw.d.ts +0 -0
- package/locale-data/guw.js +2 -2
- package/locale-data/gv.d.ts +0 -0
- package/locale-data/gv.js +26 -10
- package/locale-data/ha.d.ts +0 -0
- package/locale-data/ha.js +2 -2
- package/locale-data/haw.d.ts +0 -0
- package/locale-data/haw.js +2 -2
- package/locale-data/he.d.ts +0 -0
- package/locale-data/he.js +0 -0
- package/locale-data/hi.d.ts +0 -0
- package/locale-data/hi.js +14 -14
- package/locale-data/hnj.d.ts +0 -0
- package/locale-data/hnj.js +0 -0
- package/locale-data/hr.d.ts +0 -0
- package/locale-data/hr.js +22 -6
- package/locale-data/hsb.d.ts +0 -0
- package/locale-data/hsb.js +24 -8
- package/locale-data/hu.d.ts +0 -0
- package/locale-data/hu.js +4 -4
- package/locale-data/hy.d.ts +0 -0
- package/locale-data/hy.js +2 -2
- package/locale-data/ia.d.ts +0 -0
- package/locale-data/ia.js +0 -0
- package/locale-data/id.d.ts +0 -0
- package/locale-data/id.js +0 -0
- package/locale-data/ie.d.ts +0 -0
- package/locale-data/ie.js +0 -0
- package/locale-data/ig.d.ts +0 -0
- package/locale-data/ig.js +0 -0
- package/locale-data/ii.d.ts +0 -0
- package/locale-data/ii.js +0 -0
- package/locale-data/io.d.ts +0 -0
- package/locale-data/io.js +0 -0
- package/locale-data/is.d.ts +0 -0
- package/locale-data/is.js +18 -2
- package/locale-data/it.d.ts +0 -0
- package/locale-data/it.js +22 -6
- package/locale-data/iu.d.ts +0 -0
- package/locale-data/iu.js +4 -4
- package/locale-data/ja.d.ts +0 -0
- package/locale-data/ja.js +0 -0
- package/locale-data/jbo.d.ts +0 -0
- package/locale-data/jbo.js +0 -0
- package/locale-data/jgo.d.ts +0 -0
- package/locale-data/jgo.js +2 -2
- package/locale-data/jmc.d.ts +0 -0
- package/locale-data/jmc.js +2 -2
- package/locale-data/jv.d.ts +0 -0
- package/locale-data/jv.js +0 -0
- package/locale-data/jw.d.ts +0 -0
- package/locale-data/jw.js +0 -0
- package/locale-data/ka.d.ts +0 -0
- package/locale-data/ka.js +22 -6
- package/locale-data/kab.d.ts +0 -0
- package/locale-data/kab.js +0 -0
- package/locale-data/kaj.d.ts +0 -0
- package/locale-data/kaj.js +2 -2
- package/locale-data/kcg.d.ts +0 -0
- package/locale-data/kcg.js +2 -2
- package/locale-data/kde.d.ts +0 -0
- package/locale-data/kde.js +0 -0
- package/locale-data/kea.d.ts +0 -0
- package/locale-data/kea.js +0 -0
- package/locale-data/kk.d.ts +0 -0
- package/locale-data/kk.js +20 -4
- package/locale-data/kkj.d.ts +0 -0
- package/locale-data/kkj.js +2 -2
- package/locale-data/kl.d.ts +0 -0
- package/locale-data/kl.js +2 -2
- package/locale-data/km.d.ts +0 -0
- package/locale-data/km.js +0 -0
- package/locale-data/kn.d.ts +0 -0
- package/locale-data/kn.js +2 -2
- package/locale-data/ko.d.ts +0 -0
- package/locale-data/ko.js +0 -0
- package/locale-data/kok-Latn.d.ts +0 -0
- package/locale-data/kok-Latn.js +10 -10
- package/locale-data/kok.d.ts +0 -0
- package/locale-data/kok.js +10 -10
- package/locale-data/ks.d.ts +0 -0
- package/locale-data/ks.js +2 -2
- package/locale-data/ksb.d.ts +0 -0
- package/locale-data/ksb.js +2 -2
- package/locale-data/ksh.d.ts +0 -0
- package/locale-data/ksh.js +6 -6
- package/locale-data/ku.d.ts +0 -0
- package/locale-data/ku.js +2 -2
- package/locale-data/kw.d.ts +0 -0
- package/locale-data/kw.js +38 -22
- package/locale-data/ky.d.ts +0 -0
- package/locale-data/ky.js +2 -2
- package/locale-data/lag.d.ts +0 -0
- package/locale-data/lag.js +6 -6
- package/locale-data/lb.d.ts +0 -0
- package/locale-data/lb.js +2 -2
- package/locale-data/lg.d.ts +0 -0
- package/locale-data/lg.js +2 -2
- package/locale-data/lij.d.ts +0 -0
- package/locale-data/lij.js +2 -2
- package/locale-data/lkt.d.ts +0 -0
- package/locale-data/lkt.js +0 -0
- package/locale-data/lld.d.ts +0 -0
- package/locale-data/lld.js +22 -6
- package/locale-data/ln.d.ts +0 -0
- package/locale-data/ln.js +2 -2
- package/locale-data/lo.d.ts +0 -0
- package/locale-data/lo.js +2 -2
- package/locale-data/lt.d.ts +0 -0
- package/locale-data/lt.js +22 -6
- package/locale-data/lv.d.ts +0 -0
- package/locale-data/lv.js +22 -6
- package/locale-data/mas.d.ts +0 -0
- package/locale-data/mas.js +2 -2
- package/locale-data/mg.d.ts +0 -0
- package/locale-data/mg.js +2 -2
- package/locale-data/mgo.d.ts +0 -0
- package/locale-data/mgo.js +2 -2
- package/locale-data/mk.d.ts +0 -0
- package/locale-data/mk.js +26 -10
- package/locale-data/ml.d.ts +0 -0
- package/locale-data/ml.js +2 -2
- package/locale-data/mn.d.ts +0 -0
- package/locale-data/mn.js +2 -2
- package/locale-data/mo.d.ts +0 -0
- package/locale-data/mo.js +22 -6
- package/locale-data/mr.d.ts +0 -0
- package/locale-data/mr.js +10 -10
- package/locale-data/ms.d.ts +0 -0
- package/locale-data/ms.js +2 -2
- package/locale-data/mt.d.ts +0 -0
- package/locale-data/mt.js +28 -12
- package/locale-data/my.d.ts +0 -0
- package/locale-data/my.js +0 -0
- package/locale-data/nah.d.ts +0 -0
- package/locale-data/nah.js +2 -2
- package/locale-data/naq.d.ts +0 -0
- package/locale-data/naq.js +4 -4
- package/locale-data/nb.d.ts +0 -0
- package/locale-data/nb.js +2 -2
- package/locale-data/nd.d.ts +0 -0
- package/locale-data/nd.js +2 -2
- package/locale-data/ne.d.ts +0 -0
- package/locale-data/ne.js +4 -4
- package/locale-data/nl.d.ts +0 -0
- package/locale-data/nl.js +0 -0
- package/locale-data/nn.d.ts +0 -0
- package/locale-data/nn.js +2 -2
- package/locale-data/nnh.d.ts +0 -0
- package/locale-data/nnh.js +2 -2
- package/locale-data/no.d.ts +0 -0
- package/locale-data/no.js +2 -2
- package/locale-data/nqo.d.ts +0 -0
- package/locale-data/nqo.js +0 -0
- package/locale-data/nr.d.ts +0 -0
- package/locale-data/nr.js +2 -2
- package/locale-data/nso.d.ts +0 -0
- package/locale-data/nso.js +2 -2
- package/locale-data/ny.d.ts +0 -0
- package/locale-data/ny.js +2 -2
- package/locale-data/nyn.d.ts +0 -0
- package/locale-data/nyn.js +2 -2
- package/locale-data/om.d.ts +0 -0
- package/locale-data/om.js +2 -2
- package/locale-data/or.d.ts +0 -0
- package/locale-data/or.js +14 -14
- package/locale-data/os.d.ts +0 -0
- package/locale-data/os.js +2 -2
- package/locale-data/osa.d.ts +0 -0
- package/locale-data/osa.js +0 -0
- package/locale-data/pa.d.ts +0 -0
- package/locale-data/pa.js +2 -2
- package/locale-data/pap.d.ts +0 -0
- package/locale-data/pap.js +2 -2
- package/locale-data/pcm.d.ts +0 -0
- package/locale-data/pcm.js +2 -2
- package/locale-data/pl.d.ts +0 -0
- package/locale-data/pl.js +24 -8
- package/locale-data/prg.d.ts +0 -0
- package/locale-data/prg.js +22 -6
- package/locale-data/ps.d.ts +0 -0
- package/locale-data/ps.js +2 -2
- package/locale-data/pt-PT.d.ts +0 -0
- package/locale-data/pt-PT.js +20 -4
- package/locale-data/pt.d.ts +0 -0
- package/locale-data/pt.js +20 -4
- package/locale-data/rm.d.ts +0 -0
- package/locale-data/rm.js +2 -2
- package/locale-data/ro.d.ts +0 -0
- package/locale-data/ro.js +22 -6
- package/locale-data/rof.d.ts +0 -0
- package/locale-data/rof.js +2 -2
- package/locale-data/ru.d.ts +0 -0
- package/locale-data/ru.js +24 -8
- package/locale-data/rwk.d.ts +0 -0
- package/locale-data/rwk.js +2 -2
- package/locale-data/sah.d.ts +0 -0
- package/locale-data/sah.js +0 -0
- package/locale-data/saq.d.ts +0 -0
- package/locale-data/saq.js +2 -2
- package/locale-data/sat.d.ts +0 -0
- package/locale-data/sat.js +4 -4
- package/locale-data/sc.d.ts +0 -0
- package/locale-data/sc.js +2 -2
- package/locale-data/scn.d.ts +0 -0
- package/locale-data/scn.js +22 -6
- package/locale-data/sd.d.ts +0 -0
- package/locale-data/sd.js +2 -2
- package/locale-data/sdh.d.ts +0 -0
- package/locale-data/sdh.js +2 -2
- package/locale-data/se.d.ts +0 -0
- package/locale-data/se.js +4 -4
- package/locale-data/seh.d.ts +0 -0
- package/locale-data/seh.js +2 -2
- package/locale-data/ses.d.ts +0 -0
- package/locale-data/ses.js +0 -0
- package/locale-data/sg.d.ts +0 -0
- package/locale-data/sg.js +0 -0
- package/locale-data/sgs.d.ts +0 -0
- package/locale-data/sgs.js +26 -10
- package/locale-data/sh.d.ts +0 -0
- package/locale-data/sh.js +22 -6
- package/locale-data/shi.d.ts +0 -0
- package/locale-data/shi.js +6 -6
- package/locale-data/si.d.ts +0 -0
- package/locale-data/si.js +2 -2
- package/locale-data/sk.d.ts +0 -0
- package/locale-data/sk.js +4 -4
- package/locale-data/sl.d.ts +0 -0
- package/locale-data/sl.js +24 -8
- package/locale-data/sma.d.ts +0 -0
- package/locale-data/sma.js +4 -4
- package/locale-data/smi.d.ts +0 -0
- package/locale-data/smi.js +4 -4
- package/locale-data/smj.d.ts +0 -0
- package/locale-data/smj.js +4 -4
- package/locale-data/smn.d.ts +0 -0
- package/locale-data/smn.js +4 -4
- package/locale-data/sms.d.ts +0 -0
- package/locale-data/sms.js +4 -4
- package/locale-data/sn.d.ts +0 -0
- package/locale-data/sn.js +2 -2
- package/locale-data/so.d.ts +0 -0
- package/locale-data/so.js +2 -2
- package/locale-data/sq.d.ts +0 -0
- package/locale-data/sq.js +24 -8
- package/locale-data/sr.d.ts +0 -0
- package/locale-data/sr.js +22 -6
- package/locale-data/ss.d.ts +0 -0
- package/locale-data/ss.js +2 -2
- package/locale-data/ssy.d.ts +0 -0
- package/locale-data/ssy.js +2 -2
- package/locale-data/st.d.ts +0 -0
- package/locale-data/st.js +2 -2
- package/locale-data/su.d.ts +0 -0
- package/locale-data/su.js +0 -0
- package/locale-data/sv.d.ts +0 -0
- package/locale-data/sv.js +18 -2
- package/locale-data/sw.d.ts +0 -0
- package/locale-data/sw.js +0 -0
- package/locale-data/syr.d.ts +0 -0
- package/locale-data/syr.js +2 -2
- package/locale-data/ta.d.ts +0 -0
- package/locale-data/ta.js +2 -2
- package/locale-data/te.d.ts +0 -0
- package/locale-data/te.js +2 -2
- package/locale-data/teo.d.ts +0 -0
- package/locale-data/teo.js +2 -2
- package/locale-data/th.d.ts +0 -0
- package/locale-data/th.js +0 -0
- package/locale-data/ti.d.ts +0 -0
- package/locale-data/ti.js +2 -2
- package/locale-data/tig.d.ts +0 -0
- package/locale-data/tig.js +2 -2
- package/locale-data/tk.d.ts +0 -0
- package/locale-data/tk.js +20 -4
- package/locale-data/tl.d.ts +0 -0
- package/locale-data/tl.js +20 -4
- package/locale-data/tn.d.ts +0 -0
- package/locale-data/tn.js +2 -2
- package/locale-data/to.d.ts +0 -0
- package/locale-data/to.js +0 -0
- package/locale-data/tpi.d.ts +0 -0
- package/locale-data/tpi.js +0 -0
- package/locale-data/tr.d.ts +0 -0
- package/locale-data/tr.js +2 -2
- package/locale-data/ts.d.ts +0 -0
- package/locale-data/ts.js +2 -2
- package/locale-data/tzm.d.ts +0 -0
- package/locale-data/tzm.js +2 -2
- package/locale-data/ug.d.ts +0 -0
- package/locale-data/ug.js +2 -2
- package/locale-data/uk.d.ts +0 -0
- package/locale-data/uk.js +26 -10
- package/locale-data/und.d.ts +0 -0
- package/locale-data/und.js +0 -0
- package/locale-data/ur.d.ts +0 -0
- package/locale-data/ur.js +0 -0
- package/locale-data/uz.d.ts +0 -0
- package/locale-data/uz.js +2 -2
- package/locale-data/ve.d.ts +0 -0
- package/locale-data/ve.js +2 -2
- package/locale-data/vec.d.ts +0 -0
- package/locale-data/vec.js +22 -6
- package/locale-data/vi.d.ts +0 -0
- package/locale-data/vi.js +2 -2
- package/locale-data/vo.d.ts +0 -0
- package/locale-data/vo.js +2 -2
- package/locale-data/vun.d.ts +0 -0
- package/locale-data/vun.js +2 -2
- package/locale-data/wa.d.ts +0 -0
- package/locale-data/wa.js +2 -2
- package/locale-data/wae.d.ts +0 -0
- package/locale-data/wae.js +2 -2
- package/locale-data/wo.d.ts +0 -0
- package/locale-data/wo.js +0 -0
- package/locale-data/xh.d.ts +0 -0
- package/locale-data/xh.js +2 -2
- package/locale-data/xog.d.ts +0 -0
- package/locale-data/xog.js +2 -2
- package/locale-data/yi.d.ts +0 -0
- package/locale-data/yi.js +0 -0
- package/locale-data/yo.d.ts +0 -0
- package/locale-data/yo.js +0 -0
- package/locale-data/yue.d.ts +0 -0
- package/locale-data/yue.js +0 -0
- package/locale-data/zh.d.ts +0 -0
- package/locale-data/zh.js +0 -0
- package/locale-data/zu.d.ts +0 -0
- package/locale-data/zu.js +2 -2
- package/package.json +2 -2
- package/polyfill-force.d.ts +0 -0
- package/polyfill-force.js +14 -63
- package/polyfill-force.js.map +1 -1
- package/polyfill.d.ts +0 -0
- package/polyfill.iife.js +2081 -3496
- package/polyfill.js +14 -63
- package/polyfill.js.map +1 -1
- package/should-polyfill.d.ts +0 -0
- package/should-polyfill.js +0 -0
- package/should-polyfill.js.map +1 -1
package/locale-data/af.d.ts
CHANGED
|
File without changes
|
package/locale-data/af.js
CHANGED
|
@@ -10,7 +10,7 @@ if (Intl.PluralRules && typeof Intl.PluralRules.__addLocaleData === 'function')
|
|
|
10
10
|
if (isOrdinal) {
|
|
11
11
|
}
|
|
12
12
|
else {
|
|
13
|
-
if (n === 1)
|
|
13
|
+
if ((!/[1-9]/.test(decimalPart) && n === 1))
|
|
14
14
|
return "one";
|
|
15
15
|
}
|
|
16
16
|
return "other";
|
|
@@ -25,7 +25,7 @@ if (Intl.PluralRules && typeof Intl.PluralRules.__addLocaleData === 'function')
|
|
|
25
25
|
if (isOrdinal) {
|
|
26
26
|
}
|
|
27
27
|
else {
|
|
28
|
-
if (n === 1)
|
|
28
|
+
if ((!/[1-9]/.test(decimalPart) && n === 1))
|
|
29
29
|
return "one";
|
|
30
30
|
}
|
|
31
31
|
return "other";
|
package/locale-data/ak.d.ts
CHANGED
|
File without changes
|
package/locale-data/ak.js
CHANGED
|
@@ -10,7 +10,7 @@ if (Intl.PluralRules && typeof Intl.PluralRules.__addLocaleData === 'function')
|
|
|
10
10
|
if (isOrdinal) {
|
|
11
11
|
}
|
|
12
12
|
else {
|
|
13
|
-
if ((n >= 0 && n <= 1))
|
|
13
|
+
if ((!/[1-9]/.test(decimalPart) && (n >= 0 && n <= 1)))
|
|
14
14
|
return "one";
|
|
15
15
|
}
|
|
16
16
|
return "other";
|
|
@@ -25,7 +25,7 @@ if (Intl.PluralRules && typeof Intl.PluralRules.__addLocaleData === 'function')
|
|
|
25
25
|
if (isOrdinal) {
|
|
26
26
|
}
|
|
27
27
|
else {
|
|
28
|
-
if ((n >= 0 && n <= 1))
|
|
28
|
+
if ((!/[1-9]/.test(decimalPart) && (n >= 0 && n <= 1)))
|
|
29
29
|
return "one";
|
|
30
30
|
}
|
|
31
31
|
return "other";
|
package/locale-data/am.d.ts
CHANGED
|
File without changes
|
package/locale-data/am.js
CHANGED
|
@@ -11,7 +11,7 @@ if (Intl.PluralRules && typeof Intl.PluralRules.__addLocaleData === 'function')
|
|
|
11
11
|
if (isOrdinal) {
|
|
12
12
|
}
|
|
13
13
|
else {
|
|
14
|
-
if (i === 0 || n === 1)
|
|
14
|
+
if (i === 0 || (!/[1-9]/.test(decimalPart) && n === 1))
|
|
15
15
|
return "one";
|
|
16
16
|
}
|
|
17
17
|
return "other";
|
|
@@ -27,7 +27,7 @@ if (Intl.PluralRules && typeof Intl.PluralRules.__addLocaleData === 'function')
|
|
|
27
27
|
if (isOrdinal) {
|
|
28
28
|
}
|
|
29
29
|
else {
|
|
30
|
-
if (i === 0 || n === 1)
|
|
30
|
+
if (i === 0 || (!/[1-9]/.test(decimalPart) && n === 1))
|
|
31
31
|
return "one";
|
|
32
32
|
}
|
|
33
33
|
return "other";
|
package/locale-data/an.d.ts
CHANGED
|
File without changes
|
package/locale-data/an.js
CHANGED
|
@@ -10,7 +10,7 @@ if (Intl.PluralRules && typeof Intl.PluralRules.__addLocaleData === 'function')
|
|
|
10
10
|
if (isOrdinal) {
|
|
11
11
|
}
|
|
12
12
|
else {
|
|
13
|
-
if (n === 1)
|
|
13
|
+
if ((!/[1-9]/.test(decimalPart) && n === 1))
|
|
14
14
|
return "one";
|
|
15
15
|
}
|
|
16
16
|
return "other";
|
|
@@ -25,7 +25,7 @@ if (Intl.PluralRules && typeof Intl.PluralRules.__addLocaleData === 'function')
|
|
|
25
25
|
if (isOrdinal) {
|
|
26
26
|
}
|
|
27
27
|
else {
|
|
28
|
-
if (n === 1)
|
|
28
|
+
if ((!/[1-9]/.test(decimalPart) && n === 1))
|
|
29
29
|
return "one";
|
|
30
30
|
}
|
|
31
31
|
return "other";
|
package/locale-data/ar.d.ts
CHANGED
|
File without changes
|
package/locale-data/ar.js
CHANGED
|
@@ -2,6 +2,14 @@
|
|
|
2
2
|
// prettier-ignore
|
|
3
3
|
if (Intl.PluralRules && typeof Intl.PluralRules.__addLocaleData === 'function') {
|
|
4
4
|
Intl.PluralRules.__addLocaleData({"data":{"categories":{"cardinal":["few","many","one","other","two","zero"],"ordinal":["other"]},"fn":function(num, isOrdinal, exponent = 0) {
|
|
5
|
+
function modDigits(digits, divisor) {
|
|
6
|
+
let value = 0;
|
|
7
|
+
for (let index = 0; index < digits.length; index++) {
|
|
8
|
+
const digit = digits.charCodeAt(index) - 48;
|
|
9
|
+
if (digit >= 0 && digit <= 9) value = (value * 10 + digit) % divisor;
|
|
10
|
+
}
|
|
11
|
+
return value;
|
|
12
|
+
}
|
|
5
13
|
const numStr = String(num);
|
|
6
14
|
const parts = numStr.split(".");
|
|
7
15
|
const integerPart = parts[0];
|
|
@@ -10,21 +18,29 @@ if (Intl.PluralRules && typeof Intl.PluralRules.__addLocaleData === 'function')
|
|
|
10
18
|
if (isOrdinal) {
|
|
11
19
|
}
|
|
12
20
|
else {
|
|
13
|
-
if (((
|
|
14
|
-
return "
|
|
15
|
-
if (((
|
|
16
|
-
return "many";
|
|
17
|
-
if (n === 1)
|
|
21
|
+
if ((!/[1-9]/.test(decimalPart) && n === 0))
|
|
22
|
+
return "zero";
|
|
23
|
+
if ((!/[1-9]/.test(decimalPart) && n === 1))
|
|
18
24
|
return "one";
|
|
19
|
-
if (n === 2)
|
|
25
|
+
if ((!/[1-9]/.test(decimalPart) && n === 2))
|
|
20
26
|
return "two";
|
|
21
|
-
if (
|
|
22
|
-
return "
|
|
27
|
+
if ((!/[1-9]/.test(decimalPart) && (modDigits(integerPart, 100) >= 3 && modDigits(integerPart, 100) <= 10)))
|
|
28
|
+
return "few";
|
|
29
|
+
if ((!/[1-9]/.test(decimalPart) && (modDigits(integerPart, 100) >= 11 && modDigits(integerPart, 100) <= 99)))
|
|
30
|
+
return "many";
|
|
23
31
|
}
|
|
24
32
|
return "other";
|
|
25
33
|
},"pluralRanges":{"cardinal":{"few_few":"few","few_many":"many","few_other":"other","many_few":"few","many_many":"many","many_other":"other","one_few":"few","one_many":"many","one_other":"other","one_two":"other","other_few":"few","other_many":"many","other_one":"other","other_other":"other","other_two":"other","two_few":"few","two_many":"many","two_other":"other","zero_few":"few","zero_many":"many","zero_one":"zero","zero_other":"other","zero_two":"zero"},"ordinal":{}}},"locale":"ar"})
|
|
26
34
|
} else {
|
|
27
35
|
(globalThis.__FORMATJS_PLURALRULES_DATA__ = globalThis.__FORMATJS_PLURALRULES_DATA__ || []).push({"data":{"categories":{"cardinal":["few","many","one","other","two","zero"],"ordinal":["other"]},"fn":function(num, isOrdinal, exponent = 0) {
|
|
36
|
+
function modDigits(digits, divisor) {
|
|
37
|
+
let value = 0;
|
|
38
|
+
for (let index = 0; index < digits.length; index++) {
|
|
39
|
+
const digit = digits.charCodeAt(index) - 48;
|
|
40
|
+
if (digit >= 0 && digit <= 9) value = (value * 10 + digit) % divisor;
|
|
41
|
+
}
|
|
42
|
+
return value;
|
|
43
|
+
}
|
|
28
44
|
const numStr = String(num);
|
|
29
45
|
const parts = numStr.split(".");
|
|
30
46
|
const integerPart = parts[0];
|
|
@@ -33,16 +49,16 @@ if (Intl.PluralRules && typeof Intl.PluralRules.__addLocaleData === 'function')
|
|
|
33
49
|
if (isOrdinal) {
|
|
34
50
|
}
|
|
35
51
|
else {
|
|
36
|
-
if (((
|
|
37
|
-
return "
|
|
38
|
-
if (((
|
|
39
|
-
return "many";
|
|
40
|
-
if (n === 1)
|
|
52
|
+
if ((!/[1-9]/.test(decimalPart) && n === 0))
|
|
53
|
+
return "zero";
|
|
54
|
+
if ((!/[1-9]/.test(decimalPart) && n === 1))
|
|
41
55
|
return "one";
|
|
42
|
-
if (n === 2)
|
|
56
|
+
if ((!/[1-9]/.test(decimalPart) && n === 2))
|
|
43
57
|
return "two";
|
|
44
|
-
if (
|
|
45
|
-
return "
|
|
58
|
+
if ((!/[1-9]/.test(decimalPart) && (modDigits(integerPart, 100) >= 3 && modDigits(integerPart, 100) <= 10)))
|
|
59
|
+
return "few";
|
|
60
|
+
if ((!/[1-9]/.test(decimalPart) && (modDigits(integerPart, 100) >= 11 && modDigits(integerPart, 100) <= 99)))
|
|
61
|
+
return "many";
|
|
46
62
|
}
|
|
47
63
|
return "other";
|
|
48
64
|
},"pluralRanges":{"cardinal":{"few_few":"few","few_many":"many","few_other":"other","many_few":"few","many_many":"many","many_other":"other","one_few":"few","one_many":"many","one_other":"other","one_two":"other","other_few":"few","other_many":"many","other_one":"other","other_other":"other","other_two":"other","two_few":"few","two_many":"many","two_other":"other","zero_few":"few","zero_many":"many","zero_one":"zero","zero_other":"other","zero_two":"zero"},"ordinal":{}}},"locale":"ar"})
|
package/locale-data/ars.d.ts
CHANGED
|
File without changes
|
package/locale-data/ars.js
CHANGED
|
@@ -2,6 +2,14 @@
|
|
|
2
2
|
// prettier-ignore
|
|
3
3
|
if (Intl.PluralRules && typeof Intl.PluralRules.__addLocaleData === 'function') {
|
|
4
4
|
Intl.PluralRules.__addLocaleData({"data":{"categories":{"cardinal":["few","many","one","other","two","zero"],"ordinal":["other"]},"fn":function(num, isOrdinal, exponent = 0) {
|
|
5
|
+
function modDigits(digits, divisor) {
|
|
6
|
+
let value = 0;
|
|
7
|
+
for (let index = 0; index < digits.length; index++) {
|
|
8
|
+
const digit = digits.charCodeAt(index) - 48;
|
|
9
|
+
if (digit >= 0 && digit <= 9) value = (value * 10 + digit) % divisor;
|
|
10
|
+
}
|
|
11
|
+
return value;
|
|
12
|
+
}
|
|
5
13
|
const numStr = String(num);
|
|
6
14
|
const parts = numStr.split(".");
|
|
7
15
|
const integerPart = parts[0];
|
|
@@ -10,21 +18,29 @@ if (Intl.PluralRules && typeof Intl.PluralRules.__addLocaleData === 'function')
|
|
|
10
18
|
if (isOrdinal) {
|
|
11
19
|
}
|
|
12
20
|
else {
|
|
13
|
-
if (((
|
|
14
|
-
return "
|
|
15
|
-
if (((
|
|
16
|
-
return "many";
|
|
17
|
-
if (n === 1)
|
|
21
|
+
if ((!/[1-9]/.test(decimalPart) && n === 0))
|
|
22
|
+
return "zero";
|
|
23
|
+
if ((!/[1-9]/.test(decimalPart) && n === 1))
|
|
18
24
|
return "one";
|
|
19
|
-
if (n === 2)
|
|
25
|
+
if ((!/[1-9]/.test(decimalPart) && n === 2))
|
|
20
26
|
return "two";
|
|
21
|
-
if (
|
|
22
|
-
return "
|
|
27
|
+
if ((!/[1-9]/.test(decimalPart) && (modDigits(integerPart, 100) >= 3 && modDigits(integerPart, 100) <= 10)))
|
|
28
|
+
return "few";
|
|
29
|
+
if ((!/[1-9]/.test(decimalPart) && (modDigits(integerPart, 100) >= 11 && modDigits(integerPart, 100) <= 99)))
|
|
30
|
+
return "many";
|
|
23
31
|
}
|
|
24
32
|
return "other";
|
|
25
33
|
}},"locale":"ars"})
|
|
26
34
|
} else {
|
|
27
35
|
(globalThis.__FORMATJS_PLURALRULES_DATA__ = globalThis.__FORMATJS_PLURALRULES_DATA__ || []).push({"data":{"categories":{"cardinal":["few","many","one","other","two","zero"],"ordinal":["other"]},"fn":function(num, isOrdinal, exponent = 0) {
|
|
36
|
+
function modDigits(digits, divisor) {
|
|
37
|
+
let value = 0;
|
|
38
|
+
for (let index = 0; index < digits.length; index++) {
|
|
39
|
+
const digit = digits.charCodeAt(index) - 48;
|
|
40
|
+
if (digit >= 0 && digit <= 9) value = (value * 10 + digit) % divisor;
|
|
41
|
+
}
|
|
42
|
+
return value;
|
|
43
|
+
}
|
|
28
44
|
const numStr = String(num);
|
|
29
45
|
const parts = numStr.split(".");
|
|
30
46
|
const integerPart = parts[0];
|
|
@@ -33,16 +49,16 @@ if (Intl.PluralRules && typeof Intl.PluralRules.__addLocaleData === 'function')
|
|
|
33
49
|
if (isOrdinal) {
|
|
34
50
|
}
|
|
35
51
|
else {
|
|
36
|
-
if (((
|
|
37
|
-
return "
|
|
38
|
-
if (((
|
|
39
|
-
return "many";
|
|
40
|
-
if (n === 1)
|
|
52
|
+
if ((!/[1-9]/.test(decimalPart) && n === 0))
|
|
53
|
+
return "zero";
|
|
54
|
+
if ((!/[1-9]/.test(decimalPart) && n === 1))
|
|
41
55
|
return "one";
|
|
42
|
-
if (n === 2)
|
|
56
|
+
if ((!/[1-9]/.test(decimalPart) && n === 2))
|
|
43
57
|
return "two";
|
|
44
|
-
if (
|
|
45
|
-
return "
|
|
58
|
+
if ((!/[1-9]/.test(decimalPart) && (modDigits(integerPart, 100) >= 3 && modDigits(integerPart, 100) <= 10)))
|
|
59
|
+
return "few";
|
|
60
|
+
if ((!/[1-9]/.test(decimalPart) && (modDigits(integerPart, 100) >= 11 && modDigits(integerPart, 100) <= 99)))
|
|
61
|
+
return "many";
|
|
46
62
|
}
|
|
47
63
|
return "other";
|
|
48
64
|
}},"locale":"ars"})
|
package/locale-data/as.d.ts
CHANGED
|
File without changes
|
package/locale-data/as.js
CHANGED
|
@@ -9,17 +9,17 @@ if (Intl.PluralRules && typeof Intl.PluralRules.__addLocaleData === 'function')
|
|
|
9
9
|
const n = Math.abs(parseFloat(numStr));
|
|
10
10
|
const i = Math.floor(Math.abs(parseFloat(integerPart)));
|
|
11
11
|
if (isOrdinal) {
|
|
12
|
-
if (n ===
|
|
13
|
-
return "few";
|
|
14
|
-
if (n === 6)
|
|
15
|
-
return "many";
|
|
16
|
-
if ((((((n === 1 || n === 5) || n === 7) || n === 8) || n === 9) || n === 10))
|
|
12
|
+
if ((!/[1-9]/.test(decimalPart) && (((((n === 1 || n === 5) || n === 7) || n === 8) || n === 9) || n === 10)))
|
|
17
13
|
return "one";
|
|
18
|
-
if ((n === 2 || n === 3))
|
|
14
|
+
if ((!/[1-9]/.test(decimalPart) && (n === 2 || n === 3)))
|
|
19
15
|
return "two";
|
|
16
|
+
if ((!/[1-9]/.test(decimalPart) && n === 4))
|
|
17
|
+
return "few";
|
|
18
|
+
if ((!/[1-9]/.test(decimalPart) && n === 6))
|
|
19
|
+
return "many";
|
|
20
20
|
}
|
|
21
21
|
else {
|
|
22
|
-
if (i === 0 || n === 1)
|
|
22
|
+
if (i === 0 || (!/[1-9]/.test(decimalPart) && n === 1))
|
|
23
23
|
return "one";
|
|
24
24
|
}
|
|
25
25
|
return "other";
|
|
@@ -33,17 +33,17 @@ if (Intl.PluralRules && typeof Intl.PluralRules.__addLocaleData === 'function')
|
|
|
33
33
|
const n = Math.abs(parseFloat(numStr));
|
|
34
34
|
const i = Math.floor(Math.abs(parseFloat(integerPart)));
|
|
35
35
|
if (isOrdinal) {
|
|
36
|
-
if (n ===
|
|
37
|
-
return "few";
|
|
38
|
-
if (n === 6)
|
|
39
|
-
return "many";
|
|
40
|
-
if ((((((n === 1 || n === 5) || n === 7) || n === 8) || n === 9) || n === 10))
|
|
36
|
+
if ((!/[1-9]/.test(decimalPart) && (((((n === 1 || n === 5) || n === 7) || n === 8) || n === 9) || n === 10)))
|
|
41
37
|
return "one";
|
|
42
|
-
if ((n === 2 || n === 3))
|
|
38
|
+
if ((!/[1-9]/.test(decimalPart) && (n === 2 || n === 3)))
|
|
43
39
|
return "two";
|
|
40
|
+
if ((!/[1-9]/.test(decimalPart) && n === 4))
|
|
41
|
+
return "few";
|
|
42
|
+
if ((!/[1-9]/.test(decimalPart) && n === 6))
|
|
43
|
+
return "many";
|
|
44
44
|
}
|
|
45
45
|
else {
|
|
46
|
-
if (i === 0 || n === 1)
|
|
46
|
+
if (i === 0 || (!/[1-9]/.test(decimalPart) && n === 1))
|
|
47
47
|
return "one";
|
|
48
48
|
}
|
|
49
49
|
return "other";
|
package/locale-data/asa.d.ts
CHANGED
|
File without changes
|
package/locale-data/asa.js
CHANGED
|
@@ -10,7 +10,7 @@ if (Intl.PluralRules && typeof Intl.PluralRules.__addLocaleData === 'function')
|
|
|
10
10
|
if (isOrdinal) {
|
|
11
11
|
}
|
|
12
12
|
else {
|
|
13
|
-
if (n === 1)
|
|
13
|
+
if ((!/[1-9]/.test(decimalPart) && n === 1))
|
|
14
14
|
return "one";
|
|
15
15
|
}
|
|
16
16
|
return "other";
|
|
@@ -25,7 +25,7 @@ if (Intl.PluralRules && typeof Intl.PluralRules.__addLocaleData === 'function')
|
|
|
25
25
|
if (isOrdinal) {
|
|
26
26
|
}
|
|
27
27
|
else {
|
|
28
|
-
if (n === 1)
|
|
28
|
+
if ((!/[1-9]/.test(decimalPart) && n === 1))
|
|
29
29
|
return "one";
|
|
30
30
|
}
|
|
31
31
|
return "other";
|
package/locale-data/ast.d.ts
CHANGED
|
File without changes
|
package/locale-data/ast.js
CHANGED
|
File without changes
|
package/locale-data/az.d.ts
CHANGED
|
File without changes
|
package/locale-data/az.js
CHANGED
|
@@ -2,6 +2,14 @@
|
|
|
2
2
|
// prettier-ignore
|
|
3
3
|
if (Intl.PluralRules && typeof Intl.PluralRules.__addLocaleData === 'function') {
|
|
4
4
|
Intl.PluralRules.__addLocaleData({"data":{"categories":{"cardinal":["one","other"],"ordinal":["few","many","one","other"]},"fn":function(num, isOrdinal, exponent = 0) {
|
|
5
|
+
function modDigits(digits, divisor) {
|
|
6
|
+
let value = 0;
|
|
7
|
+
for (let index = 0; index < digits.length; index++) {
|
|
8
|
+
const digit = digits.charCodeAt(index) - 48;
|
|
9
|
+
if (digit >= 0 && digit <= 9) value = (value * 10 + digit) % divisor;
|
|
10
|
+
}
|
|
11
|
+
return value;
|
|
12
|
+
}
|
|
5
13
|
const numStr = String(num);
|
|
6
14
|
const parts = numStr.split(".");
|
|
7
15
|
const integerPart = parts[0];
|
|
@@ -9,21 +17,29 @@ if (Intl.PluralRules && typeof Intl.PluralRules.__addLocaleData === 'function')
|
|
|
9
17
|
const n = Math.abs(parseFloat(numStr));
|
|
10
18
|
const i = Math.floor(Math.abs(parseFloat(integerPart)));
|
|
11
19
|
if (isOrdinal) {
|
|
12
|
-
if (((
|
|
20
|
+
if (((((modDigits(integerPart, 10) === 1 || modDigits(integerPart, 10) === 2) || modDigits(integerPart, 10) === 5) || modDigits(integerPart, 10) === 7) || modDigits(integerPart, 10) === 8) || (((modDigits(integerPart, 100) === 20 || modDigits(integerPart, 100) === 50) || modDigits(integerPart, 100) === 70) || modDigits(integerPart, 100) === 80))
|
|
21
|
+
return "one";
|
|
22
|
+
if ((modDigits(integerPart, 10) === 3 || modDigits(integerPart, 10) === 4) || ((((((((modDigits(integerPart, 1000) === 100 || modDigits(integerPart, 1000) === 200) || modDigits(integerPart, 1000) === 300) || modDigits(integerPart, 1000) === 400) || modDigits(integerPart, 1000) === 500) || modDigits(integerPart, 1000) === 600) || modDigits(integerPart, 1000) === 700) || modDigits(integerPart, 1000) === 800) || modDigits(integerPart, 1000) === 900))
|
|
13
23
|
return "few";
|
|
14
|
-
if (i === 0 || (
|
|
24
|
+
if (i === 0 || modDigits(integerPart, 10) === 6 || ((modDigits(integerPart, 100) === 40 || modDigits(integerPart, 100) === 60) || modDigits(integerPart, 100) === 90))
|
|
15
25
|
return "many";
|
|
16
|
-
if ((((((i % 10) === 1 || (i % 10) === 2) || (i % 10) === 5) || (i % 10) === 7) || (i % 10) === 8) || ((((i % 100) === 20 || (i % 100) === 50) || (i % 100) === 70) || (i % 100) === 80))
|
|
17
|
-
return "one";
|
|
18
26
|
}
|
|
19
27
|
else {
|
|
20
|
-
if (n === 1)
|
|
28
|
+
if ((!/[1-9]/.test(decimalPart) && n === 1))
|
|
21
29
|
return "one";
|
|
22
30
|
}
|
|
23
31
|
return "other";
|
|
24
32
|
},"pluralRanges":{"cardinal":{"one_other":"other","other_one":"one","other_other":"other"},"ordinal":{}}},"locale":"az"})
|
|
25
33
|
} else {
|
|
26
34
|
(globalThis.__FORMATJS_PLURALRULES_DATA__ = globalThis.__FORMATJS_PLURALRULES_DATA__ || []).push({"data":{"categories":{"cardinal":["one","other"],"ordinal":["few","many","one","other"]},"fn":function(num, isOrdinal, exponent = 0) {
|
|
35
|
+
function modDigits(digits, divisor) {
|
|
36
|
+
let value = 0;
|
|
37
|
+
for (let index = 0; index < digits.length; index++) {
|
|
38
|
+
const digit = digits.charCodeAt(index) - 48;
|
|
39
|
+
if (digit >= 0 && digit <= 9) value = (value * 10 + digit) % divisor;
|
|
40
|
+
}
|
|
41
|
+
return value;
|
|
42
|
+
}
|
|
27
43
|
const numStr = String(num);
|
|
28
44
|
const parts = numStr.split(".");
|
|
29
45
|
const integerPart = parts[0];
|
|
@@ -31,15 +47,15 @@ if (Intl.PluralRules && typeof Intl.PluralRules.__addLocaleData === 'function')
|
|
|
31
47
|
const n = Math.abs(parseFloat(numStr));
|
|
32
48
|
const i = Math.floor(Math.abs(parseFloat(integerPart)));
|
|
33
49
|
if (isOrdinal) {
|
|
34
|
-
if (((
|
|
50
|
+
if (((((modDigits(integerPart, 10) === 1 || modDigits(integerPart, 10) === 2) || modDigits(integerPart, 10) === 5) || modDigits(integerPart, 10) === 7) || modDigits(integerPart, 10) === 8) || (((modDigits(integerPart, 100) === 20 || modDigits(integerPart, 100) === 50) || modDigits(integerPart, 100) === 70) || modDigits(integerPart, 100) === 80))
|
|
51
|
+
return "one";
|
|
52
|
+
if ((modDigits(integerPart, 10) === 3 || modDigits(integerPart, 10) === 4) || ((((((((modDigits(integerPart, 1000) === 100 || modDigits(integerPart, 1000) === 200) || modDigits(integerPart, 1000) === 300) || modDigits(integerPart, 1000) === 400) || modDigits(integerPart, 1000) === 500) || modDigits(integerPart, 1000) === 600) || modDigits(integerPart, 1000) === 700) || modDigits(integerPart, 1000) === 800) || modDigits(integerPart, 1000) === 900))
|
|
35
53
|
return "few";
|
|
36
|
-
if (i === 0 || (
|
|
54
|
+
if (i === 0 || modDigits(integerPart, 10) === 6 || ((modDigits(integerPart, 100) === 40 || modDigits(integerPart, 100) === 60) || modDigits(integerPart, 100) === 90))
|
|
37
55
|
return "many";
|
|
38
|
-
if ((((((i % 10) === 1 || (i % 10) === 2) || (i % 10) === 5) || (i % 10) === 7) || (i % 10) === 8) || ((((i % 100) === 20 || (i % 100) === 50) || (i % 100) === 70) || (i % 100) === 80))
|
|
39
|
-
return "one";
|
|
40
56
|
}
|
|
41
57
|
else {
|
|
42
|
-
if (n === 1)
|
|
58
|
+
if ((!/[1-9]/.test(decimalPart) && n === 1))
|
|
43
59
|
return "one";
|
|
44
60
|
}
|
|
45
61
|
return "other";
|
package/locale-data/bal.d.ts
CHANGED
|
File without changes
|
package/locale-data/bal.js
CHANGED
|
@@ -8,11 +8,11 @@ if (Intl.PluralRules && typeof Intl.PluralRules.__addLocaleData === 'function')
|
|
|
8
8
|
const decimalPart = parts[1] || "";
|
|
9
9
|
const n = Math.abs(parseFloat(numStr));
|
|
10
10
|
if (isOrdinal) {
|
|
11
|
-
if (n === 1)
|
|
11
|
+
if ((!/[1-9]/.test(decimalPart) && n === 1))
|
|
12
12
|
return "one";
|
|
13
13
|
}
|
|
14
14
|
else {
|
|
15
|
-
if (n === 1)
|
|
15
|
+
if ((!/[1-9]/.test(decimalPart) && n === 1))
|
|
16
16
|
return "one";
|
|
17
17
|
}
|
|
18
18
|
return "other";
|
|
@@ -25,11 +25,11 @@ if (Intl.PluralRules && typeof Intl.PluralRules.__addLocaleData === 'function')
|
|
|
25
25
|
const decimalPart = parts[1] || "";
|
|
26
26
|
const n = Math.abs(parseFloat(numStr));
|
|
27
27
|
if (isOrdinal) {
|
|
28
|
-
if (n === 1)
|
|
28
|
+
if ((!/[1-9]/.test(decimalPart) && n === 1))
|
|
29
29
|
return "one";
|
|
30
30
|
}
|
|
31
31
|
else {
|
|
32
|
-
if (n === 1)
|
|
32
|
+
if ((!/[1-9]/.test(decimalPart) && n === 1))
|
|
33
33
|
return "one";
|
|
34
34
|
}
|
|
35
35
|
return "other";
|
package/locale-data/be.d.ts
CHANGED
|
File without changes
|
package/locale-data/be.js
CHANGED
|
@@ -2,43 +2,59 @@
|
|
|
2
2
|
// prettier-ignore
|
|
3
3
|
if (Intl.PluralRules && typeof Intl.PluralRules.__addLocaleData === 'function') {
|
|
4
4
|
Intl.PluralRules.__addLocaleData({"data":{"categories":{"cardinal":["few","many","one","other"],"ordinal":["few","other"]},"fn":function(num, isOrdinal, exponent = 0) {
|
|
5
|
+
function modDigits(digits, divisor) {
|
|
6
|
+
let value = 0;
|
|
7
|
+
for (let index = 0; index < digits.length; index++) {
|
|
8
|
+
const digit = digits.charCodeAt(index) - 48;
|
|
9
|
+
if (digit >= 0 && digit <= 9) value = (value * 10 + digit) % divisor;
|
|
10
|
+
}
|
|
11
|
+
return value;
|
|
12
|
+
}
|
|
5
13
|
const numStr = String(num);
|
|
6
14
|
const parts = numStr.split(".");
|
|
7
15
|
const integerPart = parts[0];
|
|
8
16
|
const decimalPart = parts[1] || "";
|
|
9
17
|
const n = Math.abs(parseFloat(numStr));
|
|
10
18
|
if (isOrdinal) {
|
|
11
|
-
if (((
|
|
19
|
+
if ((!/[1-9]/.test(decimalPart) && (modDigits(integerPart, 10) === 2 || modDigits(integerPart, 10) === 3)) && (/[1-9]/.test(decimalPart) || (modDigits(integerPart, 100) !== 12 && modDigits(integerPart, 100) !== 13)))
|
|
12
20
|
return "few";
|
|
13
21
|
}
|
|
14
22
|
else {
|
|
15
|
-
if (((
|
|
23
|
+
if ((!/[1-9]/.test(decimalPart) && modDigits(integerPart, 10) === 1) && (/[1-9]/.test(decimalPart) || modDigits(integerPart, 100) !== 11))
|
|
24
|
+
return "one";
|
|
25
|
+
if ((!/[1-9]/.test(decimalPart) && (modDigits(integerPart, 10) >= 2 && modDigits(integerPart, 10) <= 4)) && (/[1-9]/.test(decimalPart) || (modDigits(integerPart, 100) < 12 || modDigits(integerPart, 100) > 14)))
|
|
16
26
|
return "few";
|
|
17
|
-
if ((
|
|
27
|
+
if ((!/[1-9]/.test(decimalPart) && modDigits(integerPart, 10) === 0) || (!/[1-9]/.test(decimalPart) && (modDigits(integerPart, 10) >= 5 && modDigits(integerPart, 10) <= 9)) || (!/[1-9]/.test(decimalPart) && (modDigits(integerPart, 100) >= 11 && modDigits(integerPart, 100) <= 14)))
|
|
18
28
|
return "many";
|
|
19
|
-
if ((n % 10) === 1 && (n % 100) !== 11)
|
|
20
|
-
return "one";
|
|
21
29
|
}
|
|
22
30
|
return "other";
|
|
23
31
|
},"pluralRanges":{"cardinal":{"few_few":"few","few_many":"many","few_one":"one","few_other":"other","many_few":"few","many_many":"many","many_one":"one","many_other":"other","one_few":"few","one_many":"many","one_one":"one","one_other":"other","other_few":"few","other_many":"many","other_one":"one","other_other":"other"},"ordinal":{}}},"locale":"be"})
|
|
24
32
|
} else {
|
|
25
33
|
(globalThis.__FORMATJS_PLURALRULES_DATA__ = globalThis.__FORMATJS_PLURALRULES_DATA__ || []).push({"data":{"categories":{"cardinal":["few","many","one","other"],"ordinal":["few","other"]},"fn":function(num, isOrdinal, exponent = 0) {
|
|
34
|
+
function modDigits(digits, divisor) {
|
|
35
|
+
let value = 0;
|
|
36
|
+
for (let index = 0; index < digits.length; index++) {
|
|
37
|
+
const digit = digits.charCodeAt(index) - 48;
|
|
38
|
+
if (digit >= 0 && digit <= 9) value = (value * 10 + digit) % divisor;
|
|
39
|
+
}
|
|
40
|
+
return value;
|
|
41
|
+
}
|
|
26
42
|
const numStr = String(num);
|
|
27
43
|
const parts = numStr.split(".");
|
|
28
44
|
const integerPart = parts[0];
|
|
29
45
|
const decimalPart = parts[1] || "";
|
|
30
46
|
const n = Math.abs(parseFloat(numStr));
|
|
31
47
|
if (isOrdinal) {
|
|
32
|
-
if (((
|
|
48
|
+
if ((!/[1-9]/.test(decimalPart) && (modDigits(integerPart, 10) === 2 || modDigits(integerPart, 10) === 3)) && (/[1-9]/.test(decimalPart) || (modDigits(integerPart, 100) !== 12 && modDigits(integerPart, 100) !== 13)))
|
|
33
49
|
return "few";
|
|
34
50
|
}
|
|
35
51
|
else {
|
|
36
|
-
if (((
|
|
52
|
+
if ((!/[1-9]/.test(decimalPart) && modDigits(integerPart, 10) === 1) && (/[1-9]/.test(decimalPart) || modDigits(integerPart, 100) !== 11))
|
|
53
|
+
return "one";
|
|
54
|
+
if ((!/[1-9]/.test(decimalPart) && (modDigits(integerPart, 10) >= 2 && modDigits(integerPart, 10) <= 4)) && (/[1-9]/.test(decimalPart) || (modDigits(integerPart, 100) < 12 || modDigits(integerPart, 100) > 14)))
|
|
37
55
|
return "few";
|
|
38
|
-
if ((
|
|
56
|
+
if ((!/[1-9]/.test(decimalPart) && modDigits(integerPart, 10) === 0) || (!/[1-9]/.test(decimalPart) && (modDigits(integerPart, 10) >= 5 && modDigits(integerPart, 10) <= 9)) || (!/[1-9]/.test(decimalPart) && (modDigits(integerPart, 100) >= 11 && modDigits(integerPart, 100) <= 14)))
|
|
39
57
|
return "many";
|
|
40
|
-
if ((n % 10) === 1 && (n % 100) !== 11)
|
|
41
|
-
return "one";
|
|
42
58
|
}
|
|
43
59
|
return "other";
|
|
44
60
|
},"pluralRanges":{"cardinal":{"few_few":"few","few_many":"many","few_one":"one","few_other":"other","many_few":"few","many_many":"many","many_one":"one","many_other":"other","one_few":"few","one_many":"many","one_one":"one","one_other":"other","other_few":"few","other_many":"many","other_one":"one","other_other":"other"},"ordinal":{}}},"locale":"be"})
|
package/locale-data/bem.d.ts
CHANGED
|
File without changes
|
package/locale-data/bem.js
CHANGED
|
@@ -10,7 +10,7 @@ if (Intl.PluralRules && typeof Intl.PluralRules.__addLocaleData === 'function')
|
|
|
10
10
|
if (isOrdinal) {
|
|
11
11
|
}
|
|
12
12
|
else {
|
|
13
|
-
if (n === 1)
|
|
13
|
+
if ((!/[1-9]/.test(decimalPart) && n === 1))
|
|
14
14
|
return "one";
|
|
15
15
|
}
|
|
16
16
|
return "other";
|
|
@@ -25,7 +25,7 @@ if (Intl.PluralRules && typeof Intl.PluralRules.__addLocaleData === 'function')
|
|
|
25
25
|
if (isOrdinal) {
|
|
26
26
|
}
|
|
27
27
|
else {
|
|
28
|
-
if (n === 1)
|
|
28
|
+
if ((!/[1-9]/.test(decimalPart) && n === 1))
|
|
29
29
|
return "one";
|
|
30
30
|
}
|
|
31
31
|
return "other";
|
package/locale-data/bez.d.ts
CHANGED
|
File without changes
|
package/locale-data/bez.js
CHANGED
|
@@ -10,7 +10,7 @@ if (Intl.PluralRules && typeof Intl.PluralRules.__addLocaleData === 'function')
|
|
|
10
10
|
if (isOrdinal) {
|
|
11
11
|
}
|
|
12
12
|
else {
|
|
13
|
-
if (n === 1)
|
|
13
|
+
if ((!/[1-9]/.test(decimalPart) && n === 1))
|
|
14
14
|
return "one";
|
|
15
15
|
}
|
|
16
16
|
return "other";
|
|
@@ -25,7 +25,7 @@ if (Intl.PluralRules && typeof Intl.PluralRules.__addLocaleData === 'function')
|
|
|
25
25
|
if (isOrdinal) {
|
|
26
26
|
}
|
|
27
27
|
else {
|
|
28
|
-
if (n === 1)
|
|
28
|
+
if ((!/[1-9]/.test(decimalPart) && n === 1))
|
|
29
29
|
return "one";
|
|
30
30
|
}
|
|
31
31
|
return "other";
|
package/locale-data/bg.d.ts
CHANGED
|
File without changes
|
package/locale-data/bg.js
CHANGED
|
@@ -10,7 +10,7 @@ if (Intl.PluralRules && typeof Intl.PluralRules.__addLocaleData === 'function')
|
|
|
10
10
|
if (isOrdinal) {
|
|
11
11
|
}
|
|
12
12
|
else {
|
|
13
|
-
if (n === 1)
|
|
13
|
+
if ((!/[1-9]/.test(decimalPart) && n === 1))
|
|
14
14
|
return "one";
|
|
15
15
|
}
|
|
16
16
|
return "other";
|
|
@@ -25,7 +25,7 @@ if (Intl.PluralRules && typeof Intl.PluralRules.__addLocaleData === 'function')
|
|
|
25
25
|
if (isOrdinal) {
|
|
26
26
|
}
|
|
27
27
|
else {
|
|
28
|
-
if (n === 1)
|
|
28
|
+
if ((!/[1-9]/.test(decimalPart) && n === 1))
|
|
29
29
|
return "one";
|
|
30
30
|
}
|
|
31
31
|
return "other";
|
package/locale-data/bho.d.ts
CHANGED
|
File without changes
|
package/locale-data/bho.js
CHANGED
|
@@ -10,7 +10,7 @@ if (Intl.PluralRules && typeof Intl.PluralRules.__addLocaleData === 'function')
|
|
|
10
10
|
if (isOrdinal) {
|
|
11
11
|
}
|
|
12
12
|
else {
|
|
13
|
-
if ((n >= 0 && n <= 1))
|
|
13
|
+
if ((!/[1-9]/.test(decimalPart) && (n >= 0 && n <= 1)))
|
|
14
14
|
return "one";
|
|
15
15
|
}
|
|
16
16
|
return "other";
|
|
@@ -25,7 +25,7 @@ if (Intl.PluralRules && typeof Intl.PluralRules.__addLocaleData === 'function')
|
|
|
25
25
|
if (isOrdinal) {
|
|
26
26
|
}
|
|
27
27
|
else {
|
|
28
|
-
if ((n >= 0 && n <= 1))
|
|
28
|
+
if ((!/[1-9]/.test(decimalPart) && (n >= 0 && n <= 1)))
|
|
29
29
|
return "one";
|
|
30
30
|
}
|
|
31
31
|
return "other";
|
package/locale-data/blo.d.ts
CHANGED
|
File without changes
|