@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.
Files changed (464) hide show
  1. package/LICENSE.md +0 -0
  2. package/README.md +0 -0
  3. package/index.d.ts +13 -1
  4. package/index.js +14 -63
  5. package/index.js.map +1 -1
  6. package/locale-data/af.d.ts +0 -0
  7. package/locale-data/af.js +2 -2
  8. package/locale-data/ak.d.ts +0 -0
  9. package/locale-data/ak.js +2 -2
  10. package/locale-data/am.d.ts +0 -0
  11. package/locale-data/am.js +2 -2
  12. package/locale-data/an.d.ts +0 -0
  13. package/locale-data/an.js +2 -2
  14. package/locale-data/ar.d.ts +0 -0
  15. package/locale-data/ar.js +32 -16
  16. package/locale-data/ars.d.ts +0 -0
  17. package/locale-data/ars.js +32 -16
  18. package/locale-data/as.d.ts +0 -0
  19. package/locale-data/as.js +14 -14
  20. package/locale-data/asa.d.ts +0 -0
  21. package/locale-data/asa.js +2 -2
  22. package/locale-data/ast.d.ts +0 -0
  23. package/locale-data/ast.js +0 -0
  24. package/locale-data/az.d.ts +0 -0
  25. package/locale-data/az.js +26 -10
  26. package/locale-data/bal.d.ts +0 -0
  27. package/locale-data/bal.js +4 -4
  28. package/locale-data/be.d.ts +0 -0
  29. package/locale-data/be.js +26 -10
  30. package/locale-data/bem.d.ts +0 -0
  31. package/locale-data/bem.js +2 -2
  32. package/locale-data/bez.d.ts +0 -0
  33. package/locale-data/bez.js +2 -2
  34. package/locale-data/bg.d.ts +0 -0
  35. package/locale-data/bg.js +2 -2
  36. package/locale-data/bho.d.ts +0 -0
  37. package/locale-data/bho.js +2 -2
  38. package/locale-data/blo.d.ts +0 -0
  39. package/locale-data/blo.js +14 -14
  40. package/locale-data/bm.d.ts +0 -0
  41. package/locale-data/bm.js +0 -0
  42. package/locale-data/bn.d.ts +0 -0
  43. package/locale-data/bn.js +14 -14
  44. package/locale-data/bo.d.ts +0 -0
  45. package/locale-data/bo.js +0 -0
  46. package/locale-data/br.d.ts +0 -0
  47. package/locale-data/br.js +28 -12
  48. package/locale-data/brx.d.ts +0 -0
  49. package/locale-data/brx.js +2 -2
  50. package/locale-data/bs.d.ts +0 -0
  51. package/locale-data/bs.js +22 -6
  52. package/locale-data/ca.d.ts +0 -0
  53. package/locale-data/ca.js +28 -12
  54. package/locale-data/ce.d.ts +0 -0
  55. package/locale-data/ce.js +2 -2
  56. package/locale-data/ceb.d.ts +0 -0
  57. package/locale-data/ceb.js +18 -2
  58. package/locale-data/cgg.d.ts +0 -0
  59. package/locale-data/cgg.js +2 -2
  60. package/locale-data/chr.d.ts +0 -0
  61. package/locale-data/chr.js +2 -2
  62. package/locale-data/ckb.d.ts +0 -0
  63. package/locale-data/ckb.js +2 -2
  64. package/locale-data/cs.d.ts +0 -0
  65. package/locale-data/cs.js +4 -4
  66. package/locale-data/csw.d.ts +0 -0
  67. package/locale-data/csw.js +2 -2
  68. package/locale-data/cv.d.ts +0 -0
  69. package/locale-data/cv.js +6 -6
  70. package/locale-data/cy.d.ts +0 -0
  71. package/locale-data/cy.js +32 -32
  72. package/locale-data/da.d.ts +0 -0
  73. package/locale-data/da.js +2 -2
  74. package/locale-data/de.d.ts +0 -0
  75. package/locale-data/de.js +0 -0
  76. package/locale-data/doi.d.ts +0 -0
  77. package/locale-data/doi.js +2 -2
  78. package/locale-data/dsb.d.ts +0 -0
  79. package/locale-data/dsb.js +24 -8
  80. package/locale-data/dv.d.ts +0 -0
  81. package/locale-data/dv.js +2 -2
  82. package/locale-data/dz.d.ts +0 -0
  83. package/locale-data/dz.js +0 -0
  84. package/locale-data/ee.d.ts +0 -0
  85. package/locale-data/ee.js +2 -2
  86. package/locale-data/el.d.ts +0 -0
  87. package/locale-data/el.js +2 -2
  88. package/locale-data/en.d.ts +0 -0
  89. package/locale-data/en.js +24 -8
  90. package/locale-data/eo.d.ts +0 -0
  91. package/locale-data/eo.js +2 -2
  92. package/locale-data/es.d.ts +0 -0
  93. package/locale-data/es.js +22 -6
  94. package/locale-data/et.d.ts +0 -0
  95. package/locale-data/et.js +0 -0
  96. package/locale-data/eu.d.ts +0 -0
  97. package/locale-data/eu.js +2 -2
  98. package/locale-data/fa.d.ts +0 -0
  99. package/locale-data/fa.js +2 -2
  100. package/locale-data/ff.d.ts +0 -0
  101. package/locale-data/ff.js +0 -0
  102. package/locale-data/fi.d.ts +0 -0
  103. package/locale-data/fi.js +0 -0
  104. package/locale-data/fil.d.ts +0 -0
  105. package/locale-data/fil.js +20 -4
  106. package/locale-data/fo.d.ts +0 -0
  107. package/locale-data/fo.js +2 -2
  108. package/locale-data/fr.d.ts +0 -0
  109. package/locale-data/fr.js +22 -6
  110. package/locale-data/fur.d.ts +0 -0
  111. package/locale-data/fur.js +2 -2
  112. package/locale-data/fy.d.ts +0 -0
  113. package/locale-data/fy.js +0 -0
  114. package/locale-data/ga.d.ts +0 -0
  115. package/locale-data/ga.js +14 -14
  116. package/locale-data/gd.d.ts +0 -0
  117. package/locale-data/gd.js +16 -16
  118. package/locale-data/gl.d.ts +0 -0
  119. package/locale-data/gl.js +0 -0
  120. package/locale-data/gsw.d.ts +0 -0
  121. package/locale-data/gsw.js +2 -2
  122. package/locale-data/gu.d.ts +0 -0
  123. package/locale-data/gu.js +14 -14
  124. package/locale-data/guw.d.ts +0 -0
  125. package/locale-data/guw.js +2 -2
  126. package/locale-data/gv.d.ts +0 -0
  127. package/locale-data/gv.js +26 -10
  128. package/locale-data/ha.d.ts +0 -0
  129. package/locale-data/ha.js +2 -2
  130. package/locale-data/haw.d.ts +0 -0
  131. package/locale-data/haw.js +2 -2
  132. package/locale-data/he.d.ts +0 -0
  133. package/locale-data/he.js +0 -0
  134. package/locale-data/hi.d.ts +0 -0
  135. package/locale-data/hi.js +14 -14
  136. package/locale-data/hnj.d.ts +0 -0
  137. package/locale-data/hnj.js +0 -0
  138. package/locale-data/hr.d.ts +0 -0
  139. package/locale-data/hr.js +22 -6
  140. package/locale-data/hsb.d.ts +0 -0
  141. package/locale-data/hsb.js +24 -8
  142. package/locale-data/hu.d.ts +0 -0
  143. package/locale-data/hu.js +4 -4
  144. package/locale-data/hy.d.ts +0 -0
  145. package/locale-data/hy.js +2 -2
  146. package/locale-data/ia.d.ts +0 -0
  147. package/locale-data/ia.js +0 -0
  148. package/locale-data/id.d.ts +0 -0
  149. package/locale-data/id.js +0 -0
  150. package/locale-data/ie.d.ts +0 -0
  151. package/locale-data/ie.js +0 -0
  152. package/locale-data/ig.d.ts +0 -0
  153. package/locale-data/ig.js +0 -0
  154. package/locale-data/ii.d.ts +0 -0
  155. package/locale-data/ii.js +0 -0
  156. package/locale-data/io.d.ts +0 -0
  157. package/locale-data/io.js +0 -0
  158. package/locale-data/is.d.ts +0 -0
  159. package/locale-data/is.js +18 -2
  160. package/locale-data/it.d.ts +0 -0
  161. package/locale-data/it.js +22 -6
  162. package/locale-data/iu.d.ts +0 -0
  163. package/locale-data/iu.js +4 -4
  164. package/locale-data/ja.d.ts +0 -0
  165. package/locale-data/ja.js +0 -0
  166. package/locale-data/jbo.d.ts +0 -0
  167. package/locale-data/jbo.js +0 -0
  168. package/locale-data/jgo.d.ts +0 -0
  169. package/locale-data/jgo.js +2 -2
  170. package/locale-data/jmc.d.ts +0 -0
  171. package/locale-data/jmc.js +2 -2
  172. package/locale-data/jv.d.ts +0 -0
  173. package/locale-data/jv.js +0 -0
  174. package/locale-data/jw.d.ts +0 -0
  175. package/locale-data/jw.js +0 -0
  176. package/locale-data/ka.d.ts +0 -0
  177. package/locale-data/ka.js +22 -6
  178. package/locale-data/kab.d.ts +0 -0
  179. package/locale-data/kab.js +0 -0
  180. package/locale-data/kaj.d.ts +0 -0
  181. package/locale-data/kaj.js +2 -2
  182. package/locale-data/kcg.d.ts +0 -0
  183. package/locale-data/kcg.js +2 -2
  184. package/locale-data/kde.d.ts +0 -0
  185. package/locale-data/kde.js +0 -0
  186. package/locale-data/kea.d.ts +0 -0
  187. package/locale-data/kea.js +0 -0
  188. package/locale-data/kk.d.ts +0 -0
  189. package/locale-data/kk.js +20 -4
  190. package/locale-data/kkj.d.ts +0 -0
  191. package/locale-data/kkj.js +2 -2
  192. package/locale-data/kl.d.ts +0 -0
  193. package/locale-data/kl.js +2 -2
  194. package/locale-data/km.d.ts +0 -0
  195. package/locale-data/km.js +0 -0
  196. package/locale-data/kn.d.ts +0 -0
  197. package/locale-data/kn.js +2 -2
  198. package/locale-data/ko.d.ts +0 -0
  199. package/locale-data/ko.js +0 -0
  200. package/locale-data/kok-Latn.d.ts +0 -0
  201. package/locale-data/kok-Latn.js +10 -10
  202. package/locale-data/kok.d.ts +0 -0
  203. package/locale-data/kok.js +10 -10
  204. package/locale-data/ks.d.ts +0 -0
  205. package/locale-data/ks.js +2 -2
  206. package/locale-data/ksb.d.ts +0 -0
  207. package/locale-data/ksb.js +2 -2
  208. package/locale-data/ksh.d.ts +0 -0
  209. package/locale-data/ksh.js +6 -6
  210. package/locale-data/ku.d.ts +0 -0
  211. package/locale-data/ku.js +2 -2
  212. package/locale-data/kw.d.ts +0 -0
  213. package/locale-data/kw.js +38 -22
  214. package/locale-data/ky.d.ts +0 -0
  215. package/locale-data/ky.js +2 -2
  216. package/locale-data/lag.d.ts +0 -0
  217. package/locale-data/lag.js +6 -6
  218. package/locale-data/lb.d.ts +0 -0
  219. package/locale-data/lb.js +2 -2
  220. package/locale-data/lg.d.ts +0 -0
  221. package/locale-data/lg.js +2 -2
  222. package/locale-data/lij.d.ts +0 -0
  223. package/locale-data/lij.js +2 -2
  224. package/locale-data/lkt.d.ts +0 -0
  225. package/locale-data/lkt.js +0 -0
  226. package/locale-data/lld.d.ts +0 -0
  227. package/locale-data/lld.js +22 -6
  228. package/locale-data/ln.d.ts +0 -0
  229. package/locale-data/ln.js +2 -2
  230. package/locale-data/lo.d.ts +0 -0
  231. package/locale-data/lo.js +2 -2
  232. package/locale-data/lt.d.ts +0 -0
  233. package/locale-data/lt.js +22 -6
  234. package/locale-data/lv.d.ts +0 -0
  235. package/locale-data/lv.js +22 -6
  236. package/locale-data/mas.d.ts +0 -0
  237. package/locale-data/mas.js +2 -2
  238. package/locale-data/mg.d.ts +0 -0
  239. package/locale-data/mg.js +2 -2
  240. package/locale-data/mgo.d.ts +0 -0
  241. package/locale-data/mgo.js +2 -2
  242. package/locale-data/mk.d.ts +0 -0
  243. package/locale-data/mk.js +26 -10
  244. package/locale-data/ml.d.ts +0 -0
  245. package/locale-data/ml.js +2 -2
  246. package/locale-data/mn.d.ts +0 -0
  247. package/locale-data/mn.js +2 -2
  248. package/locale-data/mo.d.ts +0 -0
  249. package/locale-data/mo.js +22 -6
  250. package/locale-data/mr.d.ts +0 -0
  251. package/locale-data/mr.js +10 -10
  252. package/locale-data/ms.d.ts +0 -0
  253. package/locale-data/ms.js +2 -2
  254. package/locale-data/mt.d.ts +0 -0
  255. package/locale-data/mt.js +28 -12
  256. package/locale-data/my.d.ts +0 -0
  257. package/locale-data/my.js +0 -0
  258. package/locale-data/nah.d.ts +0 -0
  259. package/locale-data/nah.js +2 -2
  260. package/locale-data/naq.d.ts +0 -0
  261. package/locale-data/naq.js +4 -4
  262. package/locale-data/nb.d.ts +0 -0
  263. package/locale-data/nb.js +2 -2
  264. package/locale-data/nd.d.ts +0 -0
  265. package/locale-data/nd.js +2 -2
  266. package/locale-data/ne.d.ts +0 -0
  267. package/locale-data/ne.js +4 -4
  268. package/locale-data/nl.d.ts +0 -0
  269. package/locale-data/nl.js +0 -0
  270. package/locale-data/nn.d.ts +0 -0
  271. package/locale-data/nn.js +2 -2
  272. package/locale-data/nnh.d.ts +0 -0
  273. package/locale-data/nnh.js +2 -2
  274. package/locale-data/no.d.ts +0 -0
  275. package/locale-data/no.js +2 -2
  276. package/locale-data/nqo.d.ts +0 -0
  277. package/locale-data/nqo.js +0 -0
  278. package/locale-data/nr.d.ts +0 -0
  279. package/locale-data/nr.js +2 -2
  280. package/locale-data/nso.d.ts +0 -0
  281. package/locale-data/nso.js +2 -2
  282. package/locale-data/ny.d.ts +0 -0
  283. package/locale-data/ny.js +2 -2
  284. package/locale-data/nyn.d.ts +0 -0
  285. package/locale-data/nyn.js +2 -2
  286. package/locale-data/om.d.ts +0 -0
  287. package/locale-data/om.js +2 -2
  288. package/locale-data/or.d.ts +0 -0
  289. package/locale-data/or.js +14 -14
  290. package/locale-data/os.d.ts +0 -0
  291. package/locale-data/os.js +2 -2
  292. package/locale-data/osa.d.ts +0 -0
  293. package/locale-data/osa.js +0 -0
  294. package/locale-data/pa.d.ts +0 -0
  295. package/locale-data/pa.js +2 -2
  296. package/locale-data/pap.d.ts +0 -0
  297. package/locale-data/pap.js +2 -2
  298. package/locale-data/pcm.d.ts +0 -0
  299. package/locale-data/pcm.js +2 -2
  300. package/locale-data/pl.d.ts +0 -0
  301. package/locale-data/pl.js +24 -8
  302. package/locale-data/prg.d.ts +0 -0
  303. package/locale-data/prg.js +22 -6
  304. package/locale-data/ps.d.ts +0 -0
  305. package/locale-data/ps.js +2 -2
  306. package/locale-data/pt-PT.d.ts +0 -0
  307. package/locale-data/pt-PT.js +20 -4
  308. package/locale-data/pt.d.ts +0 -0
  309. package/locale-data/pt.js +20 -4
  310. package/locale-data/rm.d.ts +0 -0
  311. package/locale-data/rm.js +2 -2
  312. package/locale-data/ro.d.ts +0 -0
  313. package/locale-data/ro.js +22 -6
  314. package/locale-data/rof.d.ts +0 -0
  315. package/locale-data/rof.js +2 -2
  316. package/locale-data/ru.d.ts +0 -0
  317. package/locale-data/ru.js +24 -8
  318. package/locale-data/rwk.d.ts +0 -0
  319. package/locale-data/rwk.js +2 -2
  320. package/locale-data/sah.d.ts +0 -0
  321. package/locale-data/sah.js +0 -0
  322. package/locale-data/saq.d.ts +0 -0
  323. package/locale-data/saq.js +2 -2
  324. package/locale-data/sat.d.ts +0 -0
  325. package/locale-data/sat.js +4 -4
  326. package/locale-data/sc.d.ts +0 -0
  327. package/locale-data/sc.js +2 -2
  328. package/locale-data/scn.d.ts +0 -0
  329. package/locale-data/scn.js +22 -6
  330. package/locale-data/sd.d.ts +0 -0
  331. package/locale-data/sd.js +2 -2
  332. package/locale-data/sdh.d.ts +0 -0
  333. package/locale-data/sdh.js +2 -2
  334. package/locale-data/se.d.ts +0 -0
  335. package/locale-data/se.js +4 -4
  336. package/locale-data/seh.d.ts +0 -0
  337. package/locale-data/seh.js +2 -2
  338. package/locale-data/ses.d.ts +0 -0
  339. package/locale-data/ses.js +0 -0
  340. package/locale-data/sg.d.ts +0 -0
  341. package/locale-data/sg.js +0 -0
  342. package/locale-data/sgs.d.ts +0 -0
  343. package/locale-data/sgs.js +26 -10
  344. package/locale-data/sh.d.ts +0 -0
  345. package/locale-data/sh.js +22 -6
  346. package/locale-data/shi.d.ts +0 -0
  347. package/locale-data/shi.js +6 -6
  348. package/locale-data/si.d.ts +0 -0
  349. package/locale-data/si.js +2 -2
  350. package/locale-data/sk.d.ts +0 -0
  351. package/locale-data/sk.js +4 -4
  352. package/locale-data/sl.d.ts +0 -0
  353. package/locale-data/sl.js +24 -8
  354. package/locale-data/sma.d.ts +0 -0
  355. package/locale-data/sma.js +4 -4
  356. package/locale-data/smi.d.ts +0 -0
  357. package/locale-data/smi.js +4 -4
  358. package/locale-data/smj.d.ts +0 -0
  359. package/locale-data/smj.js +4 -4
  360. package/locale-data/smn.d.ts +0 -0
  361. package/locale-data/smn.js +4 -4
  362. package/locale-data/sms.d.ts +0 -0
  363. package/locale-data/sms.js +4 -4
  364. package/locale-data/sn.d.ts +0 -0
  365. package/locale-data/sn.js +2 -2
  366. package/locale-data/so.d.ts +0 -0
  367. package/locale-data/so.js +2 -2
  368. package/locale-data/sq.d.ts +0 -0
  369. package/locale-data/sq.js +24 -8
  370. package/locale-data/sr.d.ts +0 -0
  371. package/locale-data/sr.js +22 -6
  372. package/locale-data/ss.d.ts +0 -0
  373. package/locale-data/ss.js +2 -2
  374. package/locale-data/ssy.d.ts +0 -0
  375. package/locale-data/ssy.js +2 -2
  376. package/locale-data/st.d.ts +0 -0
  377. package/locale-data/st.js +2 -2
  378. package/locale-data/su.d.ts +0 -0
  379. package/locale-data/su.js +0 -0
  380. package/locale-data/sv.d.ts +0 -0
  381. package/locale-data/sv.js +18 -2
  382. package/locale-data/sw.d.ts +0 -0
  383. package/locale-data/sw.js +0 -0
  384. package/locale-data/syr.d.ts +0 -0
  385. package/locale-data/syr.js +2 -2
  386. package/locale-data/ta.d.ts +0 -0
  387. package/locale-data/ta.js +2 -2
  388. package/locale-data/te.d.ts +0 -0
  389. package/locale-data/te.js +2 -2
  390. package/locale-data/teo.d.ts +0 -0
  391. package/locale-data/teo.js +2 -2
  392. package/locale-data/th.d.ts +0 -0
  393. package/locale-data/th.js +0 -0
  394. package/locale-data/ti.d.ts +0 -0
  395. package/locale-data/ti.js +2 -2
  396. package/locale-data/tig.d.ts +0 -0
  397. package/locale-data/tig.js +2 -2
  398. package/locale-data/tk.d.ts +0 -0
  399. package/locale-data/tk.js +20 -4
  400. package/locale-data/tl.d.ts +0 -0
  401. package/locale-data/tl.js +20 -4
  402. package/locale-data/tn.d.ts +0 -0
  403. package/locale-data/tn.js +2 -2
  404. package/locale-data/to.d.ts +0 -0
  405. package/locale-data/to.js +0 -0
  406. package/locale-data/tpi.d.ts +0 -0
  407. package/locale-data/tpi.js +0 -0
  408. package/locale-data/tr.d.ts +0 -0
  409. package/locale-data/tr.js +2 -2
  410. package/locale-data/ts.d.ts +0 -0
  411. package/locale-data/ts.js +2 -2
  412. package/locale-data/tzm.d.ts +0 -0
  413. package/locale-data/tzm.js +2 -2
  414. package/locale-data/ug.d.ts +0 -0
  415. package/locale-data/ug.js +2 -2
  416. package/locale-data/uk.d.ts +0 -0
  417. package/locale-data/uk.js +26 -10
  418. package/locale-data/und.d.ts +0 -0
  419. package/locale-data/und.js +0 -0
  420. package/locale-data/ur.d.ts +0 -0
  421. package/locale-data/ur.js +0 -0
  422. package/locale-data/uz.d.ts +0 -0
  423. package/locale-data/uz.js +2 -2
  424. package/locale-data/ve.d.ts +0 -0
  425. package/locale-data/ve.js +2 -2
  426. package/locale-data/vec.d.ts +0 -0
  427. package/locale-data/vec.js +22 -6
  428. package/locale-data/vi.d.ts +0 -0
  429. package/locale-data/vi.js +2 -2
  430. package/locale-data/vo.d.ts +0 -0
  431. package/locale-data/vo.js +2 -2
  432. package/locale-data/vun.d.ts +0 -0
  433. package/locale-data/vun.js +2 -2
  434. package/locale-data/wa.d.ts +0 -0
  435. package/locale-data/wa.js +2 -2
  436. package/locale-data/wae.d.ts +0 -0
  437. package/locale-data/wae.js +2 -2
  438. package/locale-data/wo.d.ts +0 -0
  439. package/locale-data/wo.js +0 -0
  440. package/locale-data/xh.d.ts +0 -0
  441. package/locale-data/xh.js +2 -2
  442. package/locale-data/xog.d.ts +0 -0
  443. package/locale-data/xog.js +2 -2
  444. package/locale-data/yi.d.ts +0 -0
  445. package/locale-data/yi.js +0 -0
  446. package/locale-data/yo.d.ts +0 -0
  447. package/locale-data/yo.js +0 -0
  448. package/locale-data/yue.d.ts +0 -0
  449. package/locale-data/yue.js +0 -0
  450. package/locale-data/zh.d.ts +0 -0
  451. package/locale-data/zh.js +0 -0
  452. package/locale-data/zu.d.ts +0 -0
  453. package/locale-data/zu.js +2 -2
  454. package/package.json +2 -2
  455. package/polyfill-force.d.ts +0 -0
  456. package/polyfill-force.js +14 -63
  457. package/polyfill-force.js.map +1 -1
  458. package/polyfill.d.ts +0 -0
  459. package/polyfill.iife.js +2081 -3496
  460. package/polyfill.js +14 -63
  461. package/polyfill.js.map +1 -1
  462. package/should-polyfill.d.ts +0 -0
  463. package/should-polyfill.js +0 -0
  464. package/should-polyfill.js.map +1 -1
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";
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";
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";
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";
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 (((n % 100) >= 3 && (n % 100) <= 10))
14
- return "few";
15
- if (((n % 100) >= 11 && (n % 100) <= 99))
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 (n === 0)
22
- return "zero";
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 (((n % 100) >= 3 && (n % 100) <= 10))
37
- return "few";
38
- if (((n % 100) >= 11 && (n % 100) <= 99))
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 (n === 0)
45
- return "zero";
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"})
File without changes
@@ -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 (((n % 100) >= 3 && (n % 100) <= 10))
14
- return "few";
15
- if (((n % 100) >= 11 && (n % 100) <= 99))
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 (n === 0)
22
- return "zero";
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 (((n % 100) >= 3 && (n % 100) <= 10))
37
- return "few";
38
- if (((n % 100) >= 11 && (n % 100) <= 99))
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 (n === 0)
45
- return "zero";
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"})
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 === 4)
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 === 4)
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";
File without changes
@@ -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";
File without changes
File without changes
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 (((i % 10) === 3 || (i % 10) === 4) || (((((((((i % 1000) === 100 || (i % 1000) === 200) || (i % 1000) === 300) || (i % 1000) === 400) || (i % 1000) === 500) || (i % 1000) === 600) || (i % 1000) === 700) || (i % 1000) === 800) || (i % 1000) === 900))
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 || (i % 10) === 6 || (((i % 100) === 40 || (i % 100) === 60) || (i % 100) === 90))
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 (((i % 10) === 3 || (i % 10) === 4) || (((((((((i % 1000) === 100 || (i % 1000) === 200) || (i % 1000) === 300) || (i % 1000) === 400) || (i % 1000) === 500) || (i % 1000) === 600) || (i % 1000) === 700) || (i % 1000) === 800) || (i % 1000) === 900))
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 || (i % 10) === 6 || (((i % 100) === 40 || (i % 100) === 60) || (i % 100) === 90))
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";
File without changes
@@ -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";
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 (((n % 10) === 2 || (n % 10) === 3) && ((n % 100) !== 12 && (n % 100) !== 13))
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 (((n % 10) >= 2 && (n % 10) <= 4) && ((n % 100) < 12 || (n % 100) > 14))
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 ((n % 10) === 0 || ((n % 10) >= 5 && (n % 10) <= 9) || ((n % 100) >= 11 && (n % 100) <= 14))
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 (((n % 10) === 2 || (n % 10) === 3) && ((n % 100) !== 12 && (n % 100) !== 13))
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 (((n % 10) >= 2 && (n % 10) <= 4) && ((n % 100) < 12 || (n % 100) > 14))
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 ((n % 10) === 0 || ((n % 10) >= 5 && (n % 10) <= 9) || ((n % 100) >= 11 && (n % 100) <= 14))
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"})
File without changes
@@ -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";
File without changes
@@ -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";
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";
File without changes
@@ -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";
File without changes