javascript-time-ago 2.5.11 → 2.5.12

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 (433) hide show
  1. package/bundle/javascript-time-ago.js +1 -1
  2. package/bundle/javascript-time-ago.js.map +1 -1
  3. package/bundle/javascript-time-ago.min.js +1 -1
  4. package/bundle/javascript-time-ago.min.js.map +1 -1
  5. package/commonjs/LocaleDataStore.js +2 -5
  6. package/commonjs/LocaleDataStore.js.map +1 -1
  7. package/commonjs/PropTypes.js +12 -12
  8. package/commonjs/PropTypes.js.map +1 -1
  9. package/commonjs/TimeAgo.js +135 -190
  10. package/commonjs/TimeAgo.js.map +1 -1
  11. package/commonjs/TimeAgo.test.js +124 -130
  12. package/commonjs/TimeAgo.test.js.map +1 -1
  13. package/commonjs/cache.js +7 -25
  14. package/commonjs/cache.js.map +1 -1
  15. package/commonjs/cache.test.js +1 -3
  16. package/commonjs/cache.test.js.map +1 -1
  17. package/commonjs/isStyleObject.js +9 -9
  18. package/commonjs/isStyleObject.js.map +1 -1
  19. package/commonjs/isStyleObject.test.js +1 -3
  20. package/commonjs/isStyleObject.test.js.map +1 -1
  21. package/commonjs/locale.js +6 -19
  22. package/commonjs/locale.js.map +1 -1
  23. package/commonjs/locale.test.js +2 -11
  24. package/commonjs/locale.test.js.map +1 -1
  25. package/commonjs/round.js +2 -5
  26. package/commonjs/round.js.map +1 -1
  27. package/commonjs/steps/approximate.js +1 -4
  28. package/commonjs/steps/approximate.js.map +1 -1
  29. package/commonjs/steps/approximate.test.js +1 -6
  30. package/commonjs/steps/approximate.test.js.map +1 -1
  31. package/commonjs/steps/getStep.js +36 -53
  32. package/commonjs/steps/getStep.js.map +1 -1
  33. package/commonjs/steps/getStep.test.js +7 -7
  34. package/commonjs/steps/getStep.test.js.map +1 -1
  35. package/commonjs/steps/getStepDenominator.js +2 -5
  36. package/commonjs/steps/getStepDenominator.js.map +1 -1
  37. package/commonjs/steps/getStepDenominator.test.js +1 -3
  38. package/commonjs/steps/getStepDenominator.test.js.map +1 -1
  39. package/commonjs/steps/getStepMinTime.js +17 -32
  40. package/commonjs/steps/getStepMinTime.js.map +1 -1
  41. package/commonjs/steps/getStepMinTime.test.js +1 -3
  42. package/commonjs/steps/getStepMinTime.test.js.map +1 -1
  43. package/commonjs/steps/getTimeToNextUpdate.js +19 -41
  44. package/commonjs/steps/getTimeToNextUpdate.js.map +1 -1
  45. package/commonjs/steps/getTimeToNextUpdate.test.js +29 -25
  46. package/commonjs/steps/getTimeToNextUpdate.test.js.map +1 -1
  47. package/commonjs/steps/getTimeToNextUpdateForUnit.js +3 -12
  48. package/commonjs/steps/getTimeToNextUpdateForUnit.js.map +1 -1
  49. package/commonjs/steps/getTimeToNextUpdateForUnit.test.js +1 -7
  50. package/commonjs/steps/getTimeToNextUpdateForUnit.test.js.map +1 -1
  51. package/commonjs/steps/helpers.js +1 -2
  52. package/commonjs/steps/helpers.js.map +1 -1
  53. package/commonjs/steps/helpers.test.js +0 -1
  54. package/commonjs/steps/helpers.test.js.map +1 -1
  55. package/commonjs/steps/index.js +1 -6
  56. package/commonjs/steps/index.js.map +1 -1
  57. package/commonjs/steps/renameLegacyProperties.js +6 -14
  58. package/commonjs/steps/renameLegacyProperties.js.map +1 -1
  59. package/commonjs/steps/renameLegacyProperties.test.js +1 -3
  60. package/commonjs/steps/renameLegacyProperties.test.js.map +1 -1
  61. package/commonjs/steps/round.js +1 -2
  62. package/commonjs/steps/round.js.map +1 -1
  63. package/commonjs/steps/round.test.js +1 -7
  64. package/commonjs/steps/round.test.js.map +1 -1
  65. package/commonjs/steps/units.js +10 -21
  66. package/commonjs/steps/units.js.map +1 -1
  67. package/commonjs/style/approximate.js +2 -6
  68. package/commonjs/style/approximate.js.map +1 -1
  69. package/commonjs/style/approximateTime.js +2 -6
  70. package/commonjs/style/approximateTime.js.map +1 -1
  71. package/commonjs/style/approximateTime.test.js +116 -75
  72. package/commonjs/style/approximateTime.test.js.map +1 -1
  73. package/commonjs/style/getStyleByName.js +3 -29
  74. package/commonjs/style/getStyleByName.js.map +1 -1
  75. package/commonjs/style/mini.js +9 -6
  76. package/commonjs/style/mini.js.map +1 -1
  77. package/commonjs/style/mini.test.js +15 -25
  78. package/commonjs/style/mini.test.js.map +1 -1
  79. package/commonjs/style/miniMinute.js +8 -13
  80. package/commonjs/style/miniMinute.js.map +1 -1
  81. package/commonjs/style/miniMinute.test.js +11 -17
  82. package/commonjs/style/miniMinute.test.js.map +1 -1
  83. package/commonjs/style/miniMinuteNow.js +8 -13
  84. package/commonjs/style/miniMinuteNow.js.map +1 -1
  85. package/commonjs/style/miniMinuteNow.test.js +11 -17
  86. package/commonjs/style/miniMinuteNow.test.js.map +1 -1
  87. package/commonjs/style/miniNow.js +8 -13
  88. package/commonjs/style/miniNow.js.map +1 -1
  89. package/commonjs/style/miniNow.test.js +11 -17
  90. package/commonjs/style/miniNow.test.js.map +1 -1
  91. package/commonjs/style/renameLegacyProperties.js +7 -13
  92. package/commonjs/style/renameLegacyProperties.js.map +1 -1
  93. package/commonjs/style/renameLegacyProperties.test.js +1 -4
  94. package/commonjs/style/renameLegacyProperties.test.js.map +1 -1
  95. package/commonjs/style/round.js +2 -6
  96. package/commonjs/style/round.js.map +1 -1
  97. package/commonjs/style/round.test.js +51 -67
  98. package/commonjs/style/round.test.js.map +1 -1
  99. package/commonjs/style/roundMinute.js +8 -13
  100. package/commonjs/style/roundMinute.js.map +1 -1
  101. package/commonjs/style/roundMinute.test.js +20 -27
  102. package/commonjs/style/roundMinute.test.js.map +1 -1
  103. package/commonjs/style/twitter.js +34 -38
  104. package/commonjs/style/twitter.js.map +1 -1
  105. package/commonjs/style/twitter.test.js +49 -55
  106. package/commonjs/style/twitter.test.js.map +1 -1
  107. package/commonjs/style/twitterFirstMinute.js +10 -15
  108. package/commonjs/style/twitterFirstMinute.js.map +1 -1
  109. package/commonjs/style/twitterFirstMinute.test.js +16 -23
  110. package/commonjs/style/twitterFirstMinute.test.js.map +1 -1
  111. package/commonjs/style/twitterMinute.js +8 -13
  112. package/commonjs/style/twitterMinute.js.map +1 -1
  113. package/commonjs/style/twitterMinute.test.js +20 -25
  114. package/commonjs/style/twitterMinute.test.js.map +1 -1
  115. package/commonjs/style/twitterMinuteNow.js +8 -13
  116. package/commonjs/style/twitterMinuteNow.js.map +1 -1
  117. package/commonjs/style/twitterMinuteNow.test.js +20 -25
  118. package/commonjs/style/twitterMinuteNow.test.js.map +1 -1
  119. package/commonjs/style/twitterNow.js +8 -13
  120. package/commonjs/style/twitterNow.js.map +1 -1
  121. package/commonjs/style/twitterNow.test.js +18 -24
  122. package/commonjs/style/twitterNow.test.js.map +1 -1
  123. package/load-all-locales/index.cjs +32 -0
  124. package/load-all-locales/index.cjs.js +32 -0
  125. package/load-all-locales/index.js +64 -0
  126. package/locale/ak/package.json +16 -0
  127. package/locale/ak.json +267 -0
  128. package/locale/ak.json.d.ts +4 -0
  129. package/locale/ak.json.js +267 -0
  130. package/locale/bal-Latn/package.json +16 -0
  131. package/locale/bal-Latn.json +240 -0
  132. package/locale/bal-Latn.json.d.ts +4 -0
  133. package/locale/bal-Latn.json.js +240 -0
  134. package/locale/be-tarask/package.json +16 -0
  135. package/locale/be-tarask.json +259 -0
  136. package/locale/be-tarask.json.d.ts +4 -0
  137. package/locale/be-tarask.json.js +259 -0
  138. package/locale/blo/package.json +16 -0
  139. package/locale/blo.json +159 -0
  140. package/locale/blo.json.d.ts +4 -0
  141. package/locale/blo.json.js +159 -0
  142. package/locale/bn.json +5 -2
  143. package/locale/bn.json.js +5 -2
  144. package/locale/bs.json +8 -2
  145. package/locale/bs.json.js +8 -2
  146. package/locale/ccp.json +2 -8
  147. package/locale/ccp.json.js +2 -8
  148. package/locale/csw/package.json +16 -0
  149. package/locale/csw.json +180 -0
  150. package/locale/csw.json.d.ts +4 -0
  151. package/locale/csw.json.js +180 -0
  152. package/locale/cy.json +6 -12
  153. package/locale/cy.json.js +6 -12
  154. package/locale/doi/package.json +16 -0
  155. package/locale/doi.json +159 -0
  156. package/locale/doi.json.d.ts +4 -0
  157. package/locale/doi.json.js +159 -0
  158. package/locale/en-AU.json +12 -12
  159. package/locale/en-AU.json.js +12 -12
  160. package/locale/en-CZ/package.json +16 -0
  161. package/locale/en-CZ.json +219 -0
  162. package/locale/en-CZ.json.d.ts +4 -0
  163. package/locale/en-CZ.json.js +219 -0
  164. package/locale/en-ES/package.json +16 -0
  165. package/locale/en-ES.json +219 -0
  166. package/locale/en-ES.json.d.ts +4 -0
  167. package/locale/en-ES.json.js +219 -0
  168. package/locale/en-FR/package.json +16 -0
  169. package/locale/en-FR.json +219 -0
  170. package/locale/en-FR.json.d.ts +4 -0
  171. package/locale/en-FR.json.js +219 -0
  172. package/locale/en-GS/package.json +16 -0
  173. package/locale/en-GS.json +219 -0
  174. package/locale/en-GS.json.d.ts +4 -0
  175. package/locale/en-GS.json.js +219 -0
  176. package/locale/en-HU/package.json +16 -0
  177. package/locale/en-HU.json +219 -0
  178. package/locale/en-HU.json.d.ts +4 -0
  179. package/locale/en-HU.json.js +219 -0
  180. package/locale/en-ID/package.json +16 -0
  181. package/locale/en-ID.json +219 -0
  182. package/locale/en-ID.json.d.ts +4 -0
  183. package/locale/en-ID.json.js +219 -0
  184. package/locale/en-IT/package.json +16 -0
  185. package/locale/en-IT.json +219 -0
  186. package/locale/en-IT.json.d.ts +4 -0
  187. package/locale/en-IT.json.js +219 -0
  188. package/locale/en-NO/package.json +16 -0
  189. package/locale/en-NO.json +219 -0
  190. package/locale/en-NO.json.d.ts +4 -0
  191. package/locale/en-NO.json.js +219 -0
  192. package/locale/en-PL/package.json +16 -0
  193. package/locale/en-PL.json +219 -0
  194. package/locale/en-PL.json.d.ts +4 -0
  195. package/locale/en-PL.json.js +219 -0
  196. package/locale/en-PT/package.json +16 -0
  197. package/locale/en-PT.json +219 -0
  198. package/locale/en-PT.json.d.ts +4 -0
  199. package/locale/en-PT.json.js +219 -0
  200. package/locale/en-RO/package.json +16 -0
  201. package/locale/en-RO.json +219 -0
  202. package/locale/en-RO.json.d.ts +4 -0
  203. package/locale/en-RO.json.js +219 -0
  204. package/locale/en-SK/package.json +16 -0
  205. package/locale/en-SK.json +219 -0
  206. package/locale/en-SK.json.d.ts +4 -0
  207. package/locale/en-SK.json.js +219 -0
  208. package/locale/es-MX.json +12 -9
  209. package/locale/es-MX.json.js +12 -9
  210. package/locale/es-SV.json +2 -2
  211. package/locale/es-SV.json.js +2 -2
  212. package/locale/eu.json +24 -24
  213. package/locale/eu.json.js +24 -24
  214. package/locale/ha.json +119 -65
  215. package/locale/ha.json.js +119 -65
  216. package/locale/he.json +0 -6
  217. package/locale/he.json.js +0 -6
  218. package/locale/hi-Latn.json +2 -2
  219. package/locale/hi-Latn.json.js +2 -2
  220. package/locale/ht/package.json +16 -0
  221. package/locale/ht.json +207 -0
  222. package/locale/ht.json.d.ts +4 -0
  223. package/locale/ht.json.js +207 -0
  224. package/locale/id.json +1 -1
  225. package/locale/id.json.js +1 -1
  226. package/locale/ie/package.json +16 -0
  227. package/locale/ie.json +159 -0
  228. package/locale/ie.json.d.ts +4 -0
  229. package/locale/ie.json.js +159 -0
  230. package/locale/ig.json +17 -17
  231. package/locale/ig.json.js +17 -17
  232. package/locale/ii/package.json +16 -0
  233. package/locale/ii.json +165 -0
  234. package/locale/ii.json.d.ts +4 -0
  235. package/locale/ii.json.js +165 -0
  236. package/locale/is.json +4 -1
  237. package/locale/is.json.js +4 -1
  238. package/locale/kaa/package.json +16 -0
  239. package/locale/kaa.json +159 -0
  240. package/locale/kaa.json.d.ts +4 -0
  241. package/locale/kaa.json.js +159 -0
  242. package/locale/kok-Latn/package.json +16 -0
  243. package/locale/kok-Latn.json +159 -0
  244. package/locale/kok-Latn.json.d.ts +4 -0
  245. package/locale/kok-Latn.json.js +159 -0
  246. package/locale/kok.json +8 -8
  247. package/locale/kok.json.js +8 -8
  248. package/locale/ks.json +9 -9
  249. package/locale/ks.json.js +9 -9
  250. package/locale/ku.json +55 -46
  251. package/locale/ku.json.js +55 -46
  252. package/locale/lld/package.json +16 -0
  253. package/locale/lld.json +291 -0
  254. package/locale/lld.json.d.ts +4 -0
  255. package/locale/lld.json.js +291 -0
  256. package/locale/mi.json +22 -22
  257. package/locale/mi.json.js +22 -22
  258. package/locale/ms-Arab/package.json +16 -0
  259. package/locale/ms-Arab.json +159 -0
  260. package/locale/ms-Arab.json.d.ts +4 -0
  261. package/locale/ms-Arab.json.js +159 -0
  262. package/locale/nb.json +2 -2
  263. package/locale/nb.json.js +2 -2
  264. package/locale/ne.json +1 -1
  265. package/locale/ne.json.js +1 -1
  266. package/locale/nn.json +4 -4
  267. package/locale/nn.json.js +4 -4
  268. package/locale/no.json +2 -2
  269. package/locale/no.json.js +2 -2
  270. package/locale/nqo/package.json +16 -0
  271. package/locale/nqo.json +159 -0
  272. package/locale/nqo.json.d.ts +4 -0
  273. package/locale/nqo.json.js +159 -0
  274. package/locale/om/package.json +16 -0
  275. package/locale/om.json +213 -0
  276. package/locale/om.json.d.ts +4 -0
  277. package/locale/om.json.js +213 -0
  278. package/locale/or.json +1 -1
  279. package/locale/or.json.js +1 -1
  280. package/locale/qu.json +46 -46
  281. package/locale/qu.json.js +46 -46
  282. package/locale/rhg/package.json +16 -0
  283. package/locale/rhg.json +159 -0
  284. package/locale/rhg.json.d.ts +4 -0
  285. package/locale/rhg.json.js +159 -0
  286. package/locale/sl.json +12 -12
  287. package/locale/sl.json.js +12 -12
  288. package/locale/sr-Cyrl-BA.json +2 -2
  289. package/locale/sr-Cyrl-BA.json.js +2 -2
  290. package/locale/sr-Latn-BA.json +2 -2
  291. package/locale/sr-Latn-BA.json.js +2 -2
  292. package/locale/sv.json +1 -1
  293. package/locale/sv.json.js +1 -1
  294. package/locale/syr/package.json +16 -0
  295. package/locale/syr.json +303 -0
  296. package/locale/syr.json.d.ts +4 -0
  297. package/locale/syr.json.js +303 -0
  298. package/locale/ti.json +6 -6
  299. package/locale/ti.json.js +6 -6
  300. package/locale/tn/package.json +16 -0
  301. package/locale/tn.json +159 -0
  302. package/locale/tn.json.d.ts +4 -0
  303. package/locale/tn.json.js +159 -0
  304. package/locale/to.json +26 -26
  305. package/locale/to.json.js +26 -26
  306. package/locale/uk.json +1 -1
  307. package/locale/uk.json.js +1 -1
  308. package/locale/ur-IN.json +9 -6
  309. package/locale/ur-IN.json.js +9 -6
  310. package/locale/vec/package.json +16 -0
  311. package/locale/vec.json +267 -0
  312. package/locale/vec.json.d.ts +4 -0
  313. package/locale/vec.json.js +267 -0
  314. package/locale/xnr/package.json +16 -0
  315. package/locale/xnr.json +159 -0
  316. package/locale/xnr.json.d.ts +4 -0
  317. package/locale/xnr.json.js +159 -0
  318. package/locale/yo-BJ.json +17 -17
  319. package/locale/yo-BJ.json.js +17 -17
  320. package/locale/yo.json +17 -17
  321. package/locale/yo.json.js +17 -17
  322. package/modules/LocaleDataStore.js +2 -3
  323. package/modules/LocaleDataStore.js.map +1 -1
  324. package/modules/PropTypes.js +11 -7
  325. package/modules/PropTypes.js.map +1 -1
  326. package/modules/TimeAgo.js +135 -174
  327. package/modules/TimeAgo.js.map +1 -1
  328. package/modules/TimeAgo.test.js +126 -115
  329. package/modules/TimeAgo.test.js.map +1 -1
  330. package/modules/cache.js +6 -22
  331. package/modules/cache.js.map +1 -1
  332. package/modules/cache.test.js.map +1 -1
  333. package/modules/isStyleObject.js +9 -7
  334. package/modules/isStyleObject.js.map +1 -1
  335. package/modules/isStyleObject.test.js.map +1 -1
  336. package/modules/locale.js +6 -16
  337. package/modules/locale.js.map +1 -1
  338. package/modules/locale.test.js +0 -4
  339. package/modules/locale.test.js.map +1 -1
  340. package/modules/round.js +2 -3
  341. package/modules/round.js.map +1 -1
  342. package/modules/steps/approximate.js +6 -2
  343. package/modules/steps/approximate.js.map +1 -1
  344. package/modules/steps/approximate.test.js +0 -2
  345. package/modules/steps/approximate.test.js.map +1 -1
  346. package/modules/steps/getStep.js +36 -48
  347. package/modules/steps/getStep.js.map +1 -1
  348. package/modules/steps/getStep.test.js +6 -2
  349. package/modules/steps/getStep.test.js.map +1 -1
  350. package/modules/steps/getStepDenominator.js +2 -3
  351. package/modules/steps/getStepDenominator.js.map +1 -1
  352. package/modules/steps/getStepDenominator.test.js.map +1 -1
  353. package/modules/steps/getStepMinTime.js +17 -29
  354. package/modules/steps/getStepMinTime.js.map +1 -1
  355. package/modules/steps/getStepMinTime.test.js.map +1 -1
  356. package/modules/steps/getTimeToNextUpdate.js +19 -31
  357. package/modules/steps/getTimeToNextUpdate.js.map +1 -1
  358. package/modules/steps/getTimeToNextUpdate.test.js +27 -18
  359. package/modules/steps/getTimeToNextUpdate.test.js.map +1 -1
  360. package/modules/steps/getTimeToNextUpdateForUnit.js +4 -10
  361. package/modules/steps/getTimeToNextUpdateForUnit.js.map +1 -1
  362. package/modules/steps/getTimeToNextUpdateForUnit.test.js +0 -4
  363. package/modules/steps/getTimeToNextUpdateForUnit.test.js.map +1 -1
  364. package/modules/steps/helpers.js +1 -1
  365. package/modules/steps/helpers.js.map +1 -1
  366. package/modules/steps/helpers.test.js.map +1 -1
  367. package/modules/steps/index.js +2 -1
  368. package/modules/steps/index.js.map +1 -1
  369. package/modules/steps/renameLegacyProperties.js +6 -13
  370. package/modules/steps/renameLegacyProperties.js.map +1 -1
  371. package/modules/steps/renameLegacyProperties.test.js.map +1 -1
  372. package/modules/steps/round.js.map +1 -1
  373. package/modules/steps/round.test.js +0 -3
  374. package/modules/steps/round.test.js.map +1 -1
  375. package/modules/steps/units.js +5 -9
  376. package/modules/steps/units.js.map +1 -1
  377. package/modules/style/approximate.js +5 -1
  378. package/modules/style/approximate.js.map +1 -1
  379. package/modules/style/approximateTime.js +6 -2
  380. package/modules/style/approximateTime.js.map +1 -1
  381. package/modules/style/approximateTime.test.js +115 -70
  382. package/modules/style/approximateTime.test.js.map +1 -1
  383. package/modules/style/getStyleByName.js +4 -17
  384. package/modules/style/getStyleByName.js.map +1 -1
  385. package/modules/style/mini.js +8 -4
  386. package/modules/style/mini.js.map +1 -1
  387. package/modules/style/mini.test.js +14 -20
  388. package/modules/style/mini.test.js.map +1 -1
  389. package/modules/style/miniMinute.js +6 -6
  390. package/modules/style/miniMinute.js.map +1 -1
  391. package/modules/style/miniMinute.test.js +10 -12
  392. package/modules/style/miniMinute.test.js.map +1 -1
  393. package/modules/style/miniMinuteNow.js +6 -6
  394. package/modules/style/miniMinuteNow.js.map +1 -1
  395. package/modules/style/miniMinuteNow.test.js +10 -12
  396. package/modules/style/miniMinuteNow.test.js.map +1 -1
  397. package/modules/style/miniNow.js +6 -6
  398. package/modules/style/miniNow.js.map +1 -1
  399. package/modules/style/miniNow.test.js +10 -12
  400. package/modules/style/miniNow.test.js.map +1 -1
  401. package/modules/style/renameLegacyProperties.js +8 -10
  402. package/modules/style/renameLegacyProperties.js.map +1 -1
  403. package/modules/style/renameLegacyProperties.test.js +0 -1
  404. package/modules/style/renameLegacyProperties.test.js.map +1 -1
  405. package/modules/style/round.js +3 -2
  406. package/modules/style/round.js.map +1 -1
  407. package/modules/style/round.test.js +50 -62
  408. package/modules/style/round.test.js.map +1 -1
  409. package/modules/style/roundMinute.js +8 -7
  410. package/modules/style/roundMinute.js.map +1 -1
  411. package/modules/style/roundMinute.test.js +19 -22
  412. package/modules/style/roundMinute.test.js.map +1 -1
  413. package/modules/style/twitter.js +35 -32
  414. package/modules/style/twitter.js.map +1 -1
  415. package/modules/style/twitter.test.js +48 -50
  416. package/modules/style/twitter.test.js.map +1 -1
  417. package/modules/style/twitterFirstMinute.js +8 -7
  418. package/modules/style/twitterFirstMinute.js.map +1 -1
  419. package/modules/style/twitterFirstMinute.test.js +15 -18
  420. package/modules/style/twitterFirstMinute.test.js.map +1 -1
  421. package/modules/style/twitterMinute.js +6 -6
  422. package/modules/style/twitterMinute.js.map +1 -1
  423. package/modules/style/twitterMinute.test.js +19 -20
  424. package/modules/style/twitterMinute.test.js.map +1 -1
  425. package/modules/style/twitterMinuteNow.js +6 -6
  426. package/modules/style/twitterMinuteNow.js.map +1 -1
  427. package/modules/style/twitterMinuteNow.test.js +19 -20
  428. package/modules/style/twitterMinuteNow.test.js.map +1 -1
  429. package/modules/style/twitterNow.js +6 -6
  430. package/modules/style/twitterNow.js.map +1 -1
  431. package/modules/style/twitterNow.test.js +17 -19
  432. package/modules/style/twitterNow.test.js.map +1 -1
  433. package/package.json +261 -4
@@ -1,2 +1,2 @@
1
- !function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(t="undefined"!=typeof globalThis?globalThis:t||self).TimeAgo=e()}(this,(function(){"use strict";var t="en",e={},r={};function n(){return t}function o(t){return e[t]?t:r[t.toLowerCase()]?r[t.toLowerCase()]:void 0}function a(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=e.localeMatcher||"lookup";switch(r){case"lookup":case"best fit":return i(t);default:throw new RangeError('Invalid "localeMatcher" option: '.concat(r))}}function i(t){var e=o(t);if(e)return e;for(var r=t.split("-");t.length>1;){r.pop();var n=o(t=r.join("-"));if(n)return n}}var u={af:function(t){return 1==t?"one":"other"},am:function(t){return t>=0&&t<=1?"one":"other"},ar:function(t){var e=String(t).split("."),r=Number(e[0])==t&&e[0].slice(-2);return 0==t?"zero":1==t?"one":2==t?"two":r>=3&&r<=10?"few":r>=11&&r<=99?"many":"other"},ast:function(t){var e=!String(t).split(".")[1];return 1==t&&e?"one":"other"},be:function(t){var e=String(t).split("."),r=Number(e[0])==t,n=r&&e[0].slice(-1),o=r&&e[0].slice(-2);return 1==n&&11!=o?"one":n>=2&&n<=4&&(o<12||o>14)?"few":r&&0==n||n>=5&&n<=9||o>=11&&o<=14?"many":"other"},br:function(t){var e=String(t).split("."),r=Number(e[0])==t,n=r&&e[0].slice(-1),o=r&&e[0].slice(-2),a=r&&e[0].slice(-6);return 1==n&&11!=o&&71!=o&&91!=o?"one":2==n&&12!=o&&72!=o&&92!=o?"two":(3==n||4==n||9==n)&&(o<10||o>19)&&(o<70||o>79)&&(o<90||o>99)?"few":0!=t&&r&&0==a?"many":"other"},bs:function(t){var e=String(t).split("."),r=e[0],n=e[1]||"",o=!e[1],a=r.slice(-1),i=r.slice(-2),u=n.slice(-1),c=n.slice(-2);return o&&1==a&&11!=i||1==u&&11!=c?"one":o&&a>=2&&a<=4&&(i<12||i>14)||u>=2&&u<=4&&(c<12||c>14)?"few":"other"},ca:function(t){var e=String(t).split("."),r=e[0],n=!e[1],o=r.slice(-6);return 1==t&&n?"one":0!=r&&0==o&&n?"many":"other"},ceb:function(t){var e=String(t).split("."),r=e[0],n=e[1]||"",o=!e[1],a=r.slice(-1),i=n.slice(-1);return o&&(1==r||2==r||3==r)||o&&4!=a&&6!=a&&9!=a||!o&&4!=i&&6!=i&&9!=i?"one":"other"},cs:function(t){var e=String(t).split("."),r=e[0],n=!e[1];return 1==t&&n?"one":r>=2&&r<=4&&n?"few":n?"other":"many"},cy:function(t){return 0==t?"zero":1==t?"one":2==t?"two":3==t?"few":6==t?"many":"other"},da:function(t){var e=String(t).split("."),r=e[0],n=Number(e[0])==t;return 1!=t&&(n||0!=r&&1!=r)?"other":"one"},dsb:function(t){var e=String(t).split("."),r=e[0],n=e[1]||"",o=!e[1],a=r.slice(-2),i=n.slice(-2);return o&&1==a||1==i?"one":o&&2==a||2==i?"two":o&&(3==a||4==a)||3==i||4==i?"few":"other"},dz:function(t){return"other"},es:function(t){var e=String(t).split("."),r=e[0],n=!e[1],o=r.slice(-6);return 1==t?"one":0!=r&&0==o&&n?"many":"other"},ff:function(t){return t>=0&&t<2?"one":"other"},fr:function(t){var e=String(t).split("."),r=e[0],n=!e[1],o=r.slice(-6);return t>=0&&t<2?"one":0!=r&&0==o&&n?"many":"other"},ga:function(t){var e=String(t).split("."),r=Number(e[0])==t;return 1==t?"one":2==t?"two":r&&t>=3&&t<=6?"few":r&&t>=7&&t<=10?"many":"other"},gd:function(t){var e=String(t).split("."),r=Number(e[0])==t;return 1==t||11==t?"one":2==t||12==t?"two":r&&t>=3&&t<=10||r&&t>=13&&t<=19?"few":"other"},he:function(t){var e=String(t).split("."),r=e[0],n=!e[1];return 1==r&&n||0==r&&!n?"one":2==r&&n?"two":"other"},is:function(t){var e=String(t).split("."),r=e[0],n=(e[1]||"").replace(/0+$/,""),o=Number(e[0])==t,a=r.slice(-1),i=r.slice(-2);return o&&1==a&&11!=i||n%10==1&&n%100!=11?"one":"other"},ksh:function(t){return 0==t?"zero":1==t?"one":"other"},lt:function(t){var e=String(t).split("."),r=e[1]||"",n=Number(e[0])==t,o=n&&e[0].slice(-1),a=n&&e[0].slice(-2);return 1==o&&(a<11||a>19)?"one":o>=2&&o<=9&&(a<11||a>19)?"few":0!=r?"many":"other"},lv:function(t){var e=String(t).split("."),r=e[1]||"",n=r.length,o=Number(e[0])==t,a=o&&e[0].slice(-1),i=o&&e[0].slice(-2),u=r.slice(-2),c=r.slice(-1);return o&&0==a||i>=11&&i<=19||2==n&&u>=11&&u<=19?"zero":1==a&&11!=i||2==n&&1==c&&11!=u||2!=n&&1==c?"one":"other"},mk:function(t){var e=String(t).split("."),r=e[0],n=e[1]||"",o=!e[1],a=r.slice(-1),i=r.slice(-2),u=n.slice(-1),c=n.slice(-2);return o&&1==a&&11!=i||1==u&&11!=c?"one":"other"},mt:function(t){var e=String(t).split("."),r=Number(e[0])==t&&e[0].slice(-2);return 1==t?"one":2==t?"two":0==t||r>=3&&r<=10?"few":r>=11&&r<=19?"many":"other"},pa:function(t){return 0==t||1==t?"one":"other"},pl:function(t){var e=String(t).split("."),r=e[0],n=!e[1],o=r.slice(-1),a=r.slice(-2);return 1==t&&n?"one":n&&o>=2&&o<=4&&(a<12||a>14)?"few":n&&1!=r&&(0==o||1==o)||n&&o>=5&&o<=9||n&&a>=12&&a<=14?"many":"other"},pt:function(t){var e=String(t).split("."),r=e[0],n=!e[1],o=r.slice(-6);return 0==r||1==r?"one":0!=r&&0==o&&n?"many":"other"},ro:function(t){var e=String(t).split("."),r=!e[1],n=Number(e[0])==t&&e[0].slice(-2);return 1==t&&r?"one":!r||0==t||1!=t&&n>=1&&n<=19?"few":"other"},ru:function(t){var e=String(t).split("."),r=e[0],n=!e[1],o=r.slice(-1),a=r.slice(-2);return n&&1==o&&11!=a?"one":n&&o>=2&&o<=4&&(a<12||a>14)?"few":n&&0==o||n&&o>=5&&o<=9||n&&a>=11&&a<=14?"many":"other"},se:function(t){return 1==t?"one":2==t?"two":"other"},si:function(t){var e=String(t).split("."),r=e[0],n=e[1]||"";return 0==t||1==t||0==r&&1==n?"one":"other"},sl:function(t){var e=String(t).split("."),r=e[0],n=!e[1],o=r.slice(-2);return n&&1==o?"one":n&&2==o?"two":n&&(3==o||4==o)||!n?"few":"other"}};u.as=u.am,u.az=u.af,u.bg=u.af,u.bn=u.am,u.brx=u.af,u.ce=u.af,u.chr=u.af,u.de=u.ast,u.ee=u.af,u.el=u.af,u.en=u.ast,u.et=u.ast,u.eu=u.af,u.fa=u.am,u.fi=u.ast,u.fil=u.ceb,u.fo=u.af,u.fur=u.af,u.fy=u.ast,u.gl=u.ast,u.gu=u.am,u.ha=u.af,u.hi=u.am,u.hr=u.bs,u.hsb=u.dsb,u.hu=u.af,u.hy=u.ff,u.ia=u.ast,u.id=u.dz,u.ig=u.dz,u.it=u.ca,u.ja=u.dz,u.jgo=u.af,u.jv=u.dz,u.ka=u.af,u.kea=u.dz,u.kk=u.af,u.kl=u.af,u.km=u.dz,u.kn=u.am,u.ko=u.dz,u.ks=u.af,u.ku=u.af,u.ky=u.af,u.lb=u.af,u.lkt=u.dz,u.lo=u.dz,u.ml=u.af,u.mn=u.af,u.mr=u.af,u.ms=u.dz,u.my=u.dz,u.nb=u.af,u.ne=u.af,u.nl=u.ast,u.nn=u.af,u.no=u.af,u.or=u.af,u.pcm=u.am,u.ps=u.af,u.rm=u.af,u.sah=u.dz,u.sc=u.ast,u.sd=u.af,u.sk=u.cs,u.so=u.af,u.sq=u.af,u.sr=u.bs,u.su=u.dz,u.sv=u.ast,u.sw=u.ast,u.ta=u.af,u.te=u.af,u.th=u.dz,u.ti=u.pa,u.tk=u.af,u.to=u.dz,u.tr=u.af,u.ug=u.af,u.uk=u.ru,u.ur=u.ast,u.uz=u.af,u.vi=u.dz,u.wae=u.af,u.wo=u.dz,u.xh=u.af,u.yi=u.ast,u.yo=u.dz,u.yue=u.dz,u.zh=u.dz,u.zu=u.am;var c=u;function l(t){return"pt-PT"===t?t:function(t){var e=t.match(f);if(!e)throw new TypeError("Invalid locale: ".concat(t));return e[1]}(t)}var f=/^([a-z0-9]+)/i;function s(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}var p=function(){function t(e,r){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t);var n=t.supportedLocalesOf(e);if(0===n.length)throw new RangeError("Unsupported locale: "+e);if(r&&"cardinal"!==r.type)throw new RangeError('Only "cardinal" "type" is supported');this.$=c[l(n[0])]}var e,r,n;return e=t,n=[{key:"supportedLocalesOf",value:function(t){return"string"==typeof t&&(t=[t]),t.filter((function(t){return c[l(t)]}))}}],(r=[{key:"select",value:function(t){return this.$(t)}}])&&s(e.prototype,r),n&&s(e,n),Object.defineProperty(e,"prototype",{writable:!1}),t}();function y(t){return y="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},y(t)}function m(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function b(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?m(Object(r),!0).forEach((function(e){h(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):m(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function h(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function d(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null==r)return;var n,o,a=[],i=!0,u=!1;try{for(r=r.call(t);!(i=(n=r.next()).done)&&(a.push(n.value),!e||a.length!==e);i=!0);}catch(t){u=!0,o=t}finally{try{i||null==r.return||r.return()}finally{if(u)throw o}}return a}(t,e)||function(t,e){if(!t)return;if("string"==typeof t)return v(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);"Object"===r&&t.constructor&&(r=t.constructor.name);if("Map"===r||"Set"===r)return Array.from(t);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return v(t,e)}(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function v(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function g(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function w(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}var O=["second","minute","hour","day","week","month","quarter","year"],j=["auto","always"],S=["long","short","narrow"],P=["lookup","best fit"],A=function(){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};g(this,t);var o=r.numeric,i=r.style,u=r.localeMatcher;if(this.numeric="always",this.style="long",this.localeMatcher="lookup",void 0!==o){if(j.indexOf(o)<0)throw new RangeError('Invalid "numeric" option: '.concat(o));this.numeric=o}if(void 0!==i){if(S.indexOf(i)<0)throw new RangeError('Invalid "style" option: '.concat(i));this.style=i}if(void 0!==u){if(P.indexOf(u)<0)throw new RangeError('Invalid "localeMatcher" option: '.concat(u));this.localeMatcher=u}if("string"==typeof e&&(e=[e]),e.push(n()),this.locale=t.supportedLocalesOf(e,{localeMatcher:this.localeMatcher})[0],!this.locale)throw new Error("No supported locale was found");p.supportedLocalesOf(this.locale).length>0?this.pluralRules=new p(this.locale):console.warn('"'.concat(this.locale,'" locale is not supported')),"undefined"!=typeof Intl&&Intl.NumberFormat?(this.numberFormat=new Intl.NumberFormat(this.locale),this.numberingSystem=this.numberFormat.resolvedOptions().numberingSystem):this.numberingSystem="latn",this.locale=a(this.locale,{localeMatcher:this.localeMatcher})}var r,o,i;return r=t,o=[{key:"format",value:function(){var t=E(arguments),e=d(t,2),r=e[0],n=e[1];return this.getRule(r,n).replace("{0}",this.formatNumber(Math.abs(r)))}},{key:"formatToParts",value:function(){var t=E(arguments),e=d(t,2),r=e[0],n=e[1],o=this.getRule(r,n),a=o.indexOf("{0}");if(a<0)return[{type:"literal",value:o}];var i=[];return a>0&&i.push({type:"literal",value:o.slice(0,a)}),i=i.concat(this.formatNumberToParts(Math.abs(r)).map((function(t){return b(b({},t),{},{unit:n})}))),a+"{0}".length<o.length-1&&i.push({type:"literal",value:o.slice(a+"{0}".length)}),i}},{key:"getRule",value:function(t,r){var n,o=(n=this.locale,e[n])[this.style][r];if("string"==typeof o)return o;if("auto"===this.numeric)if(-2===t||-1===t){var a=o["previous".concat(-1===t?"":"-"+Math.abs(t))];if(a)return a}else if(1===t||2===t){var i=o["next".concat(1===t?"":"-"+Math.abs(t))];if(i)return i}else if(0===t&&o.current)return o.current;var u,c=o[(u=t,u<0||0===u&&function(t){return 1/t==-1/0}(u)?"past":"future")];return"string"==typeof c?c:c[this.pluralRules&&this.pluralRules.select(Math.abs(t))||"other"]||c.other}},{key:"formatNumber",value:function(t){return this.numberFormat?this.numberFormat.format(t):String(t)}},{key:"formatNumberToParts",value:function(t){return this.numberFormat&&this.numberFormat.formatToParts?this.numberFormat.formatToParts(t):[{type:"integer",value:this.formatNumber(t)}]}},{key:"resolvedOptions",value:function(){return{locale:this.locale,style:this.style,numeric:this.numeric,numberingSystem:this.numberingSystem}}}],o&&w(r.prototype,o),i&&w(r,i),Object.defineProperty(r,"prototype",{writable:!1}),t}();A.supportedLocalesOf=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if("string"==typeof t)t=[t];else if(!Array.isArray(t))throw new TypeError('Invalid "locales" argument');return t.filter((function(t){return a(t,e)}))},A.addLocale=function(t){if(!t)throw new Error("No locale data passed");e[t.locale]=t,r[t.locale.toLowerCase()]=t.locale},A.setDefaultLocale=function(e){t=e},A.getDefaultLocale=n,A.PluralRules=p;var D='Invalid "unit" argument';function k(t){if("symbol"===y(t))throw new TypeError(D);if("string"!=typeof t)throw new RangeError("".concat(D,": ").concat(t));if("s"===t[t.length-1]&&(t=t.slice(0,t.length-1)),O.indexOf(t)<0)throw new RangeError("".concat(D,": ").concat(t));return t}function T(t){if(t=Number(t),Number.isFinite&&!Number.isFinite(t))throw new RangeError("".concat('Invalid "number" argument',": ").concat(t));return t}function E(t){if(t.length<2)throw new TypeError('"unit" argument is required');return[T(t[0]),k(t[1])]}function F(t){return F="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},F(t)}function I(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}var N=function(){function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.cache={}}var e,r,n;return e=t,r=[{key:"get",value:function(){for(var t=this.cache,e=arguments.length,r=new Array(e),n=0;n<e;n++)r[n]=arguments[n];for(var o=0,a=r;o<a.length;o++){var i=a[o];if("object"!==F(t))return;t=t[i]}return t}},{key:"put",value:function(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];for(var n=e.pop(),o=e.pop(),a=this.cache,i=0,u=e;i<u.length;i++){var c=u[i];"object"!==F(a[c])&&(a[c]={}),a=a[c]}return a[o]=n}}],r&&I(e.prototype,r),n&&I(e,n),Object.defineProperty(e,"prototype",{writable:!1}),t}();function M(t){return M="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},M(t)}function R(t,e){var r="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(r)return(r=r.call(t)).next.bind(r);if(Array.isArray(t)||(r=function(t,e){if(!t)return;if("string"==typeof t)return z(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);"Object"===r&&t.constructor&&(r=t.constructor.name);if("Map"===r||"Set"===r)return Array.from(t);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return z(t,e)}(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0;return function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function z(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function x(t,e){for(var r,n=R(t);!(r=n()).done;){var o=r.value;if(e(o))return o;for(var a=o.split("-");a.length>1;)if(a.pop(),e(o=a.join("-")))return o}throw new Error("No locale data has been registered for any of the locales: ".concat(t.join(", ")))}function L(t){return L="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},L(t)}function C(t){return function(t){return void 0!==L(t)&&null!==t&&t.constructor===U}(t)&&(Array.isArray(t.steps)||Array.isArray(t.gradation)||Array.isArray(t.flavour)||"string"==typeof t.flavour||Array.isArray(t.labels)||"string"==typeof t.labels||Array.isArray(t.units)||"function"==typeof t.custom)}var U={}.constructor;var $=60,_=3600,Y=86400,q=7*Y,V=2630016,J=31556952;function B(t){switch(t){case"second":return 1;case"minute":return $;case"hour":return _;case"day":return Y;case"week":return q;case"month":return V;case"year":return J}}function G(t){return void 0!==t.factor?t.factor:B(t.unit||t.formatAs)||1}function H(t){return"floor"===t?Math.floor:Math.round}function K(t){return"floor"===t?1:.5}function Q(t){return Q="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Q(t)}function W(t,e){var r,n=e.prevStep,o=e.timestamp,a=e.now,i=e.future,u=e.round;return n&&(n.id||n.unit)&&(r=t["threshold_for_".concat(n.id||n.unit)]),void 0===r&&void 0!==t.threshold&&"function"==typeof(r=t.threshold)&&(r=r(a,i)),void 0===r&&(r=t.minTime),"object"===Q(r)&&(r=n&&n.id&&void 0!==r[n.id]?r[n.id]:r.default),"function"==typeof r&&(r=r(o,{future:i,getMinTimeForUnit:function(t,e){return X(t,e||n&&n.formatAs,{round:u})}})),void 0===r&&t.test&&(r=t.test(o,{now:a,future:i})?0:9007199254740991),void 0===r&&(n?t.formatAs&&n.formatAs&&(r=X(t.formatAs,n.formatAs,{round:u})):r=0),void 0===r&&console.warn("[javascript-time-ago] A step should specify `minTime`:\n"+JSON.stringify(t,null,2)),r}function X(t,e,r){var n,o=r.round,a=B(t);if(n=B("now"===e?t:e),void 0!==a&&void 0!==n)return a-n*(1-K(o))}function Z(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function tt(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?Z(Object(r),!0).forEach((function(e){et(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Z(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function et(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function rt(t,e,r){var n=r.now,o=r.future,a=r.round,i=r.units,u=r.getNextStep;t=function(t,e){return t.filter((function(t){var r=t.unit,n=t.formatAs;return!(r=r||n)||e.indexOf(r)>=0}))}(t,i);var c=function(t,e,r){var n=r.now,o=r.future,a=r.round;if(0===t.length)return;var i=nt(t,e,{now:n,future:o||e<0,round:a});if(-1===i)return;var u=t[i];if(u.granularity){if(0===H(a)(Math.abs(e)/G(u)/u.granularity)*u.granularity&&i>0)return t[i-1]}return u}(t,e,{now:n,future:o,round:a});return u?c?[t[t.indexOf(c)-1],c,t[t.indexOf(c)+1]]:[void 0,void 0,t[0]]:c}function nt(t,e,r){var n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0,o=W(t[n],tt({prevStep:t[n-1],timestamp:r.now-1e3*e},r));return void 0===o||Math.abs(e)<o?n-1:n===t.length-1?n:nt(t,e,r,n+1)}function ot(t,e,r){var n=r.now,o=r.round;if(B(t)){var a=1e3*B(t),i=e>n,u=Math.abs(e-n),c=H(o)(u/a)*a;return i?c>0?u-c+function(t,e){return(1-K(t))*e+1}(o,a):u-c+1:-(u-c)+function(t,e){return K(t)*e}(o,a)}}var at=31536e9;function it(t,e,r){var n=r.prevStep,o=r.nextStep,a=r.now,i=r.future,u=r.round,c=t.getTime?t.getTime():t,l=function(t){return ot(t,c,{now:a,round:u})},f=function(t,e,r){var n=r.now,o=r.future,a=r.round,i=r.prevStep;if(t){var u=function(t,e,r){var n=r.now,o=r.future,a=r.round,i=r.prevStep,u=W(t,{timestamp:e,now:n,future:o,round:a,prevStep:i});if(void 0===u)return;return o?e-1e3*u+1:0===u&&e===n?at:e+1e3*u}(t,e,{now:n,future:o,round:a,prevStep:i});if(void 0===u)return;return u-n}return o?e-n+1:at}(i?e:o,c,{future:i,now:a,round:u,prevStep:i?n:e});if(void 0!==f){var s;if(e&&(e.getTimeToNextUpdate&&(s=e.getTimeToNextUpdate(c,{getTimeToNextUpdateForUnit:l,getRoundFunction:H,now:a,future:i,round:u})),void 0===s)){var p=e.unit||e.formatAs;p&&(s=l(p))}return void 0===s?f:Math.min(s,f)}}var ut={};function ct(t){return ut[t]}function lt(t){if(!t)throw new Error("[javascript-time-ago] No locale data passed.");ut[t.locale]=t}var ft={steps:[{formatAs:"now"},{formatAs:"second"},{formatAs:"minute"},{formatAs:"hour"},{formatAs:"day"},{formatAs:"week"},{formatAs:"month"},{formatAs:"year"}],labels:"long"};function st(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function pt(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?st(Object(r),!0).forEach((function(e){yt(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):st(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function yt(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var mt=pt(pt({},ft),{},{steps:ft.steps.filter((function(t){return"second"!==t.formatAs}))}),bt=[{factor:1,unit:"now"},{threshold:1,threshold_for_now:45.5,factor:1,unit:"second"},{threshold:45.5,factor:$,unit:"minute"},{threshold:150,granularity:5,factor:$,unit:"minute"},{threshold:1350,factor:1800,unit:"half-hour"},{threshold:2550,threshold_for_minute:3150,factor:_,unit:"hour"},{threshold:73800,factor:Y,unit:"day"},{threshold:475200,factor:q,unit:"week"},{threshold:2116800,factor:V,unit:"month"},{threshold:27615168,factor:J,unit:"year"}],ht={gradation:bt,flavour:"long",units:["now","minute","hour","day","week","month","year"]},dt={gradation:bt,flavour:"long-time",units:["now","minute","hour","day","week","month","year"]};function vt(t){return t instanceof Date?t:new Date(t)}var gt=[{formatAs:"second"},{formatAs:"minute"},{formatAs:"hour"}],wt={},Ot={minTime:function(t,e){return e.future,(0,e.getMinTimeForUnit)("day")},format:function(t,e){return wt[e]||(wt[e]={}),wt[e].dayMonth||(wt[e].dayMonth=new Intl.DateTimeFormat(e,{month:"short",day:"numeric"})),wt[e].dayMonth.format(vt(t))}},jt={minTime:function(t,e){return e.future?(t-(new Date(new Date(t).getFullYear(),0).getTime()-1))/1e3:(new Date(new Date(t).getFullYear()+1,0).getTime()-t)/1e3},format:function(t,e){return wt[e]||(wt[e]={}),wt[e].dayMonthYear||(wt[e].dayMonthYear=new Intl.DateTimeFormat(e,{year:"numeric",month:"short",day:"numeric"})),wt[e].dayMonthYear.format(vt(t))}};"object"===("undefined"==typeof Intl?"undefined":M(Intl))&&"function"==typeof Intl.DateTimeFormat?gt.push(Ot,jt):gt.push({formatAs:"day"},{formatAs:"week"},{formatAs:"month"},{formatAs:"year"});var St={steps:gt,labels:["mini","short-time","narrow","short"]};function Pt(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function At(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?Pt(Object(r),!0).forEach((function(e){Dt(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Pt(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function Dt(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var kt=At(At({},St),{},{steps:[{formatAs:"now"}].concat(St.steps)});function Tt(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function Et(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?Tt(Object(r),!0).forEach((function(e){Ft(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Tt(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function Ft(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var It=Et(Et({},St),{},{steps:St.steps.filter((function(t){return"second"!==t.formatAs}))});function Nt(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function Mt(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?Nt(Object(r),!0).forEach((function(e){Rt(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Nt(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function Rt(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var zt=Mt(Mt({},It),{},{steps:[{formatAs:"now"}].concat(It.steps)});function xt(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function Lt(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?xt(Object(r),!0).forEach((function(e){Ct(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):xt(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function Ct(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var Ut=Lt(Lt({},St),{},{steps:St.steps.filter((function(t){return"second"!==t.formatAs})).map((function(t){return"minute"===t.formatAs?Lt(Lt({},t),{},{minTime:$}):t}))}),$t={steps:[{formatAs:"second"},{formatAs:"minute"},{formatAs:"hour"},{formatAs:"day"},{formatAs:"month"},{formatAs:"year"}],labels:["mini","short-time","narrow","short"]};function _t(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function Yt(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?_t(Object(r),!0).forEach((function(e){qt(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):_t(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function qt(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var Vt=Yt(Yt({},$t),{},{steps:[{formatAs:"now"}].concat($t.steps)});function Jt(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function Bt(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?Jt(Object(r),!0).forEach((function(e){Gt(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Jt(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function Gt(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var Ht=Bt(Bt({},$t),{},{steps:$t.steps.filter((function(t){return"second"!==t.formatAs}))});function Kt(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function Qt(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?Kt(Object(r),!0).forEach((function(e){Wt(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Kt(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function Wt(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var Xt=Qt(Qt({},Ht),{},{steps:[{formatAs:"now"}].concat(Ht.steps)});function Zt(t){switch(t){case"default":case"round":return ft;case"round-minute":return mt;case"approximate":default:return ht;case"time":case"approximate-time":return dt;case"mini":return $t;case"mini-now":return Vt;case"mini-minute":return Ht;case"mini-minute-now":return Xt;case"twitter":return St;case"twitter-now":return kt;case"twitter-minute":return It;case"twitter-minute-now":return zt;case"twitter-first-minute":return Ut}}function te(t){return te="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},te(t)}function ee(t,e){var r="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(r)return(r=r.call(t)).next.bind(r);if(Array.isArray(t)||(r=ne(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0;return function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function re(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null==r)return;var n,o,a=[],i=!0,u=!1;try{for(r=r.call(t);!(i=(n=r.next()).done)&&(a.push(n.value),!e||a.length!==e);i=!0);}catch(t){u=!0,o=t}finally{try{i||null==r.return||r.return()}finally{if(u)throw o}}return a}(t,e)||ne(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function ne(t,e){if(t){if("string"==typeof t)return oe(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?oe(t,e):void 0}}function oe(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function ae(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function ie(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}var ue,ce=function(){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=r.polyfill;ae(this,t),"string"==typeof e&&(e=[e]),this.locale=x(e.concat(t.getDefaultLocale()),ct),"undefined"!=typeof Intl&&Intl.NumberFormat&&(this.numberFormat=new Intl.NumberFormat(this.locale)),!1===n?(this.IntlRelativeTimeFormat=Intl.RelativeTimeFormat,this.IntlPluralRules=Intl.PluralRules):(this.IntlRelativeTimeFormat=A,this.IntlPluralRules=A.PluralRules),this.relativeTimeFormatCache=new N,this.pluralRulesCache=new N}var e,r,n;return e=t,r=[{key:"format",value:function(t,e,r){var n;r||(e&&"string"!=typeof(n=e)&&!C(n)?(r=e,e=void 0):r={}),e||(e=mt),"string"==typeof e&&(e=Zt(e));var o,a=function(t){if(t.constructor===Date||"object"===te(e=t)&&"function"==typeof e.getTime)return t.getTime();var e;if("number"==typeof t)return t;throw new Error("Unsupported relative time formatter input: ".concat(te(t),", ").concat(t))}(t),i=this.getLabels(e.flavour||e.labels),u=i.labels,c=i.labelsType;void 0!==e.now&&(o=e.now),void 0===o&&void 0!==r.now&&(o=r.now),void 0===o&&(o=Date.now());var l=(o-a)/1e3,f=r.future||l<0,s=function(t,e,r,n){var o=t.now||e&&e.now;return o?"string"==typeof o?o:n?o.future:o.past:r&&r.second&&r.second.current?r.second.current:void 0}(u,ct(this.locale).now,ct(this.locale).long,f);if(e.custom){var p=e.custom({now:o,date:new Date(a),time:a,elapsed:l,locale:this.locale});if(void 0!==p)return p}var y=function(t,e,r){var n=Object.keys(e);return r&&n.push("now"),t&&(n=t.filter((function(t){return"now"===t||n.indexOf(t)>=0}))),n}(e.units,u,s),m=r.round||e.round,b=re(rt(e.gradation||e.steps||mt.steps,l,{now:o,units:y,round:m,future:f,getNextStep:!0}),3),h=b[0],d=b[1],v=b[2],g=this.formatDateForStep(a,d,l,{labels:u,labelsType:c,nowLabel:s,now:o,future:f,round:m})||"";return r.getTimeToNextUpdate?[g,it(a,d,{nextStep:v,prevStep:h,now:o,future:f,round:m})]:g}},{key:"formatDateForStep",value:function(t,e,r,n){var o=this,a=n.labels,i=n.labelsType,u=n.nowLabel,c=n.now,l=n.future,f=n.round;if(e){if(e.format)return e.format(t,this.locale,{formatAs:function(t,e){return o.formatValue(e,t,{labels:a,future:l})},now:c,future:l});var s=e.unit||e.formatAs;if(!s)throw new Error("[javascript-time-ago] Each step must define either `formatAs` or `format()`. Step: ".concat(JSON.stringify(e)));if("now"===s)return u;var p=Math.abs(r)/G(e);e.granularity&&(p=H(f)(p/e.granularity)*e.granularity);var y=-1*Math.sign(r)*H(f)(p);switch(0===y&&(y=l?0:-0),i){case"long":case"short":case"narrow":return this.getFormatter(i).format(y,s);default:return this.formatValue(y,s,{labels:a,future:l})}}}},{key:"formatValue",value:function(t,e,r){var n=r.labels,o=r.future;return this.getFormattingRule(n,e,t,{future:o}).replace("{0}",this.formatNumber(Math.abs(t)))}},{key:"getFormattingRule",value:function(t,e,r,n){var o=n.future;if(this.locale,"string"==typeof(t=t[e]))return t;var a=t[0===r?o?"future":"past":r<0?"past":"future"]||t;return"string"==typeof a?a:a[this.getPluralRules().select(Math.abs(r))]||a.other}},{key:"formatNumber",value:function(t){return this.numberFormat?this.numberFormat.format(t):String(t)}},{key:"getFormatter",value:function(t){return this.relativeTimeFormatCache.get(this.locale,t)||this.relativeTimeFormatCache.put(this.locale,t,new this.IntlRelativeTimeFormat(this.locale,{style:t}))}},{key:"getPluralRules",value:function(){return this.pluralRulesCache.get(this.locale)||this.pluralRulesCache.put(this.locale,new this.IntlPluralRules(this.locale))}},{key:"getLabels",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];"string"==typeof t&&(t=[t]),t=(t=t.map((function(t){switch(t){case"tiny":case"mini-time":return"mini";default:return t}}))).concat("long");for(var e,r=ct(this.locale),n=ee(t);!(e=n()).done;){var o=e.value;if(r[o])return{labelsType:o,labels:r[o]}}}}],r&&ie(e.prototype,r),n&&ie(e,n),Object.defineProperty(e,"prototype",{writable:!1}),t}(),le="en";return ce.getDefaultLocale=function(){return le},ce.setDefaultLocale=function(t){return le=t},ce.addDefaultLocale=function(t){if(ue)return console.error("[javascript-time-ago] `TimeAgo.addDefaultLocale()` can only be called once. To add other locales, use `TimeAgo.addLocale()`.");ue=!0,ce.setDefaultLocale(t.locale),ce.addLocale(t)},ce.addLocale=function(t){lt(t),A.addLocale(t)},ce.locale=ce.addLocale,ce.addLabels=function(t,e,r){var n=ct(t);n||(lt({locale:t}),n=ct(t)),n[e]=r},ce}));
1
+ !function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(t="undefined"!=typeof globalThis?globalThis:t||self).TimeAgo=e()}(this,function(){"use strict";var t="en",e={},r={};function n(){return t}function o(t){return e[t]?t:r[t.toLowerCase()]?r[t.toLowerCase()]:void 0}function i(t){var e=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).localeMatcher||"lookup";switch(e){case"lookup":case"best fit":return u(t);default:throw new RangeError('Invalid "localeMatcher" option: '.concat(e))}}function u(t){var e=o(t);if(e)return e;for(var r=t.split("-");t.length>1;){r.pop();var n=o(t=r.join("-"));if(n)return n}}var a={af:function(t){return 1==t?"one":"other"},ak:function(t){return 0==t||1==t?"one":"other"},am:function(t){return t>=0&&t<=1?"one":"other"},ar:function(t){var e=String(t).split("."),r=Number(e[0])==t&&e[0].slice(-2);return 0==t?"zero":1==t?"one":2==t?"two":r>=3&&r<=10?"few":r>=11&&r<=99?"many":"other"},ast:function(t){var e=!String(t).split(".")[1];return 1==t&&e?"one":"other"},be:function(t){var e=String(t).split("."),r=Number(e[0])==t,n=r&&e[0].slice(-1),o=r&&e[0].slice(-2);return 1==n&&11!=o?"one":n>=2&&n<=4&&(o<12||o>14)?"few":r&&0==n||n>=5&&n<=9||o>=11&&o<=14?"many":"other"},blo:function(t){return 0==t?"zero":1==t?"one":"other"},br:function(t){var e=String(t).split("."),r=Number(e[0])==t,n=r&&e[0].slice(-1),o=r&&e[0].slice(-2),i=r&&e[0].slice(-6);return 1==n&&11!=o&&71!=o&&91!=o?"one":2==n&&12!=o&&72!=o&&92!=o?"two":(3==n||4==n||9==n)&&(o<10||o>19)&&(o<70||o>79)&&(o<90||o>99)?"few":0!=t&&r&&0==i?"many":"other"},bs:function(t){var e=String(t).split("."),r=e[0],n=e[1]||"",o=!e[1],i=r.slice(-1),u=r.slice(-2),a=n.slice(-1),c=n.slice(-2);return o&&1==i&&11!=u||1==a&&11!=c?"one":o&&i>=2&&i<=4&&(u<12||u>14)||a>=2&&a<=4&&(c<12||c>14)?"few":"other"},ca:function(t){var e=String(t).split("."),r=e[0],n=!e[1],o=r.slice(-6);return 1==t&&n?"one":0!=r&&0==o&&n?"many":"other"},ceb:function(t){var e=String(t).split("."),r=e[0],n=e[1]||"",o=!e[1],i=r.slice(-1),u=n.slice(-1);return o&&(1==r||2==r||3==r)||o&&4!=i&&6!=i&&9!=i||!o&&4!=u&&6!=u&&9!=u?"one":"other"},cs:function(t){var e=String(t).split("."),r=e[0],n=!e[1];return 1==t&&n?"one":r>=2&&r<=4&&n?"few":n?"other":"many"},cy:function(t){return 0==t?"zero":1==t?"one":2==t?"two":3==t?"few":6==t?"many":"other"},da:function(t){var e=String(t).split("."),r=e[0],n=Number(e[0])==t;return 1!=t&&(n||0!=r&&1!=r)?"other":"one"},dsb:function(t){var e=String(t).split("."),r=e[0],n=e[1]||"",o=!e[1],i=r.slice(-2),u=n.slice(-2);return o&&1==i||1==u?"one":o&&2==i||2==u?"two":o&&(3==i||4==i)||3==u||4==u?"few":"other"},dz:function(t){return"other"},es:function(t){var e=String(t).split("."),r=e[0],n=!e[1],o=r.slice(-6);return 1==t?"one":0!=r&&0==o&&n?"many":"other"},ff:function(t){return t>=0&&t<2?"one":"other"},fr:function(t){var e=String(t).split("."),r=e[0],n=!e[1],o=r.slice(-6);return t>=0&&t<2?"one":0!=r&&0==o&&n?"many":"other"},ga:function(t){var e=String(t).split("."),r=Number(e[0])==t;return 1==t?"one":2==t?"two":r&&t>=3&&t<=6?"few":r&&t>=7&&t<=10?"many":"other"},gd:function(t){var e=String(t).split("."),r=Number(e[0])==t;return 1==t||11==t?"one":2==t||12==t?"two":r&&t>=3&&t<=10||r&&t>=13&&t<=19?"few":"other"},he:function(t){var e=String(t).split("."),r=e[0],n=!e[1];return 1==r&&n||0==r&&!n?"one":2==r&&n?"two":"other"},is:function(t){var e=String(t).split("."),r=e[0],n=(e[1]||"").replace(/0+$/,""),o=Number(e[0])==t,i=r.slice(-1),u=r.slice(-2);return o&&1==i&&11!=u||n%10==1&&n%100!=11?"one":"other"},lt:function(t){var e=String(t).split("."),r=e[1]||"",n=Number(e[0])==t,o=n&&e[0].slice(-1),i=n&&e[0].slice(-2);return 1==o&&(i<11||i>19)?"one":o>=2&&o<=9&&(i<11||i>19)?"few":0!=r?"many":"other"},lv:function(t){var e=String(t).split("."),r=e[1]||"",n=r.length,o=Number(e[0])==t,i=o&&e[0].slice(-1),u=o&&e[0].slice(-2),a=r.slice(-2),c=r.slice(-1);return o&&0==i||u>=11&&u<=19||2==n&&a>=11&&a<=19?"zero":1==i&&11!=u||2==n&&1==c&&11!=a||2!=n&&1==c?"one":"other"},mk:function(t){var e=String(t).split("."),r=e[0],n=e[1]||"",o=!e[1],i=r.slice(-1),u=r.slice(-2),a=n.slice(-1),c=n.slice(-2);return o&&1==i&&11!=u||1==a&&11!=c?"one":"other"},mt:function(t){var e=String(t).split("."),r=Number(e[0])==t&&e[0].slice(-2);return 1==t?"one":2==t?"two":0==t||r>=3&&r<=10?"few":r>=11&&r<=19?"many":"other"},pl:function(t){var e=String(t).split("."),r=e[0],n=!e[1],o=r.slice(-1),i=r.slice(-2);return 1==t&&n?"one":n&&o>=2&&o<=4&&(i<12||i>14)?"few":n&&1!=r&&(0==o||1==o)||n&&o>=5&&o<=9||n&&i>=12&&i<=14?"many":"other"},pt:function(t){var e=String(t).split("."),r=e[0],n=!e[1],o=r.slice(-6);return 0==r||1==r?"one":0!=r&&0==o&&n?"many":"other"},ro:function(t){var e=String(t).split("."),r=!e[1],n=Number(e[0])==t&&e[0].slice(-2);return 1==t&&r?"one":!r||0==t||1!=t&&n>=1&&n<=19?"few":"other"},ru:function(t){var e=String(t).split("."),r=e[0],n=!e[1],o=r.slice(-1),i=r.slice(-2);return n&&1==o&&11!=i?"one":n&&o>=2&&o<=4&&(i<12||i>14)?"few":n&&0==o||n&&o>=5&&o<=9||n&&i>=11&&i<=14?"many":"other"},se:function(t){return 1==t?"one":2==t?"two":"other"},si:function(t){var e=String(t).split("."),r=e[0],n=e[1]||"";return 0==t||1==t||0==r&&1==n?"one":"other"},sl:function(t){var e=String(t).split("."),r=e[0],n=!e[1],o=r.slice(-2);return n&&1==o?"one":n&&2==o?"two":n&&(3==o||4==o)||!n?"few":"other"}};a.as=a.am,a.az=a.af,a.bal=a.af,a.bg=a.af,a.bn=a.am,a.brx=a.af,a.ce=a.af,a.chr=a.af,a.de=a.ast,a.doi=a.am,a.ee=a.af,a.el=a.af,a.en=a.ast,a.et=a.ast,a.eu=a.af,a.fa=a.am,a.fi=a.ast,a.fil=a.ceb,a.fo=a.af,a.fur=a.af,a.fy=a.ast,a.gl=a.ast,a.gu=a.am,a.ha=a.af,a.hi=a.am,a.hr=a.bs,a.hsb=a.dsb,a.hu=a.af,a.hy=a.ff,a.ia=a.ast,a.id=a.dz,a.ig=a.dz,a.ii=a.dz,a.it=a.ca,a.ja=a.dz,a.jgo=a.af,a.jv=a.dz,a.ka=a.af,a.kea=a.dz,a.kk=a.af,a.kl=a.af,a.km=a.dz,a.kn=a.am,a.ko=a.dz,a.ks=a.af,a.ksh=a.blo,a.ku=a.af,a.ky=a.af,a.lb=a.af,a.lkt=a.dz,a.lo=a.dz,a.ml=a.af,a.mn=a.af,a.mr=a.af,a.ms=a.dz,a.my=a.dz,a.nb=a.af,a.ne=a.af,a.nl=a.ast,a.nn=a.af,a.no=a.af,a.nqo=a.dz,a.om=a.af,a.or=a.af,a.pa=a.ak,a.pcm=a.am,a.ps=a.af,a.rm=a.af,a.sah=a.dz,a.sc=a.ast,a.sd=a.af,a.sk=a.cs,a.so=a.af,a.sq=a.af,a.sr=a.bs,a.su=a.dz,a.sv=a.ast,a.sw=a.ast,a.syr=a.af,a.ta=a.af,a.te=a.af,a.th=a.dz,a.ti=a.ak,a.tk=a.af,a.tn=a.af,a.to=a.dz,a.tr=a.af,a.ug=a.af,a.uk=a.ru,a.ur=a.ast,a.uz=a.af,a.vec=a.ca,a.vi=a.dz,a.wae=a.af,a.wo=a.dz,a.xh=a.af,a.yi=a.ast,a.yo=a.dz,a.yue=a.dz,a.zh=a.dz,a.zu=a.am;var c=a;function f(t){return"pt-PT"===t?t:function(t){var e=t.match(l);if(!e)throw new TypeError("Invalid locale: ".concat(t));return e[1]}(t)}var l=/^([a-z0-9]+)/i;function s(t){return s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},s(t)}function y(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,m(n.key),n)}}function m(t){var e=function(t,e){if("object"!=s(t)||!t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,e||"default");if("object"!=s(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==s(e)?e:e+""}var p=function(){function t(e,r){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t);var n=t.supportedLocalesOf(e);if(0===n.length)throw new RangeError("Unsupported locale: "+e);if(r&&"cardinal"!==r.type)throw new RangeError('Only "cardinal" "type" is supported');this.$=c[f(n[0])]}var e,r,n;return e=t,n=[{key:"supportedLocalesOf",value:function(t){return"string"==typeof t&&(t=[t]),t.filter(function(t){return c[f(t)]})}}],(r=[{key:"select",value:function(t){return this.$(t)}}])&&y(e.prototype,r),n&&y(e,n),Object.defineProperty(e,"prototype",{writable:!1}),t}();function b(t){return b="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},b(t)}function v(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),r.push.apply(r,n)}return r}function h(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?v(Object(r),!0).forEach(function(e){d(t,e,r[e])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):v(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))})}return t}function d(t,e,r){return(e=S(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function g(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,i,u,a=[],c=!0,f=!1;try{if(i=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;c=!1}else for(;!(c=(n=i.call(r)).done)&&(a.push(n.value),a.length!==e);c=!0);}catch(t){f=!0,o=t}finally{try{if(!c&&null!=r.return&&(u=r.return(),Object(u)!==u))return}finally{if(f)throw o}}return a}}(t,e)||function(t,e){if(t){if("string"==typeof t)return w(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?w(t,e):void 0}}(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function w(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function O(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,S(n.key),n)}}function S(t){var e=function(t,e){if("object"!=b(t)||!t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,e||"default");if("object"!=b(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==b(e)?e:e+""}var j=["second","minute","hour","day","week","month","quarter","year"],P=["auto","always"],A=["long","short","narrow"],T=["lookup","best fit"],k=function(){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t);var o=r.numeric,u=r.style,a=r.localeMatcher;if(this.numeric="always",this.style="long",this.localeMatcher="lookup",void 0!==o){if(P.indexOf(o)<0)throw new RangeError('Invalid "numeric" option: '.concat(o));this.numeric=o}if(void 0!==u){if(A.indexOf(u)<0)throw new RangeError('Invalid "style" option: '.concat(u));this.style=u}if(void 0!==a){if(T.indexOf(a)<0)throw new RangeError('Invalid "localeMatcher" option: '.concat(a));this.localeMatcher=a}if("string"==typeof e&&(e=[e]),e.push(n()),this.locale=t.supportedLocalesOf(e,{localeMatcher:this.localeMatcher})[0],!this.locale)throw new Error("No supported locale was found");p.supportedLocalesOf(this.locale).length>0?this.pluralRules=new p(this.locale):console.warn('"'.concat(this.locale,'" locale is not supported')),"undefined"!=typeof Intl&&Intl.NumberFormat?(this.numberFormat=new Intl.NumberFormat(this.locale),this.numberingSystem=this.numberFormat.resolvedOptions().numberingSystem):this.numberingSystem="latn",this.locale=i(this.locale,{localeMatcher:this.localeMatcher})}var r,o,u;return r=t,o=[{key:"format",value:function(){var t=g(I(arguments),2),e=t[0],r=t[1];return this.getRule(e,r).replace("{0}",this.formatNumber(Math.abs(e)))}},{key:"formatToParts",value:function(){var t=g(I(arguments),2),e=t[0],r=t[1],n=this.getRule(e,r),o=n.indexOf("{0}");if(o<0)return[{type:"literal",value:n}];var i=[];return o>0&&i.push({type:"literal",value:n.slice(0,o)}),i=i.concat(this.formatNumberToParts(Math.abs(e)).map(function(t){return h(h({},t),{},{unit:r})})),o+3<n.length-1&&i.push({type:"literal",value:n.slice(o+3)}),i}},{key:"getRule",value:function(t,r){var n,o=(n=this.locale,e[n])[this.style][r];if("string"==typeof o)return o;if("auto"===this.numeric)if(-2===t||-1===t){var i=o["previous".concat(-1===t?"":"-"+Math.abs(t))];if(i)return i}else if(1===t||2===t){var u=o["next".concat(1===t?"":"-"+Math.abs(t))];if(u)return u}else if(0===t&&o.current)return o.current;var a,c=o[(a=t,a<0||0===a&&function(t){return 1/t==-1/0}(a)?"past":"future")];return"string"==typeof c?c:c[this.pluralRules&&this.pluralRules.select(Math.abs(t))||"other"]||c.other}},{key:"formatNumber",value:function(t){return this.numberFormat?this.numberFormat.format(t):String(t)}},{key:"formatNumberToParts",value:function(t){return this.numberFormat&&this.numberFormat.formatToParts?this.numberFormat.formatToParts(t):[{type:"integer",value:this.formatNumber(t)}]}},{key:"resolvedOptions",value:function(){return{locale:this.locale,style:this.style,numeric:this.numeric,numberingSystem:this.numberingSystem}}}],o&&O(r.prototype,o),u&&O(r,u),Object.defineProperty(r,"prototype",{writable:!1}),t}();k.supportedLocalesOf=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if("string"==typeof t)t=[t];else if(!Array.isArray(t))throw new TypeError('Invalid "locales" argument');return t.filter(function(t){return i(t,e)})},k.addLocale=function(t){if(!t)throw new Error("No locale data passed");e[t.locale]=t,r[t.locale.toLowerCase()]=t.locale},k.setDefaultLocale=function(e){t=e},k.getDefaultLocale=n,k.PluralRules=p;var D='Invalid "unit" argument';function E(t){if("symbol"===b(t))throw new TypeError(D);if("string"!=typeof t)throw new RangeError("".concat(D,": ").concat(t));if("s"===t[t.length-1]&&(t=t.slice(0,t.length-1)),j.indexOf(t)<0)throw new RangeError("".concat(D,": ").concat(t));return t}var N='Invalid "number" argument';function F(t){if(t=Number(t),Number.isFinite&&!Number.isFinite(t))throw new RangeError("".concat(N,": ").concat(t));return t}function I(t){if(t.length<2)throw new TypeError('"unit" argument is required');return[F(t[0]),E(t[1])]}function M(t){return M="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},M(t)}function R(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,z(n.key),n)}}function z(t){var e=function(t,e){if("object"!=M(t)||!t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,e||"default");if("object"!=M(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==M(e)?e:e+""}var x=function(){function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.cache={}}var e,r,n;return e=t,r=[{key:"get",value:function(){for(var t=this.cache,e=arguments.length,r=new Array(e),n=0;n<e;n++)r[n]=arguments[n];for(var o=0,i=r;o<i.length;o++){var u=i[o];if("object"!==M(t))return;t=t[u]}return t}},{key:"put",value:function(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];for(var n=e.pop(),o=e.pop(),i=this.cache,u=0,a=e;u<a.length;u++){var c=a[u];"object"!==M(i[c])&&(i[c]={}),i=i[c]}return i[o]=n}}],r&&R(e.prototype,r),n&&R(e,n),Object.defineProperty(e,"prototype",{writable:!1}),t}();function L(t){return L="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},L(t)}function C(t,e){var r="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(r)return(r=r.call(t)).next.bind(r);if(Array.isArray(t)||(r=function(t,e){if(t){if("string"==typeof t)return U(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?U(t,e):void 0}}(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0;return function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function U(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function $(t){return $="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},$(t)}function _(t){return function(t){return void 0!==$(t)&&null!==t&&t.constructor===Y}(t)&&(Array.isArray(t.steps)||Array.isArray(t.gradation)||Array.isArray(t.flavour)||"string"==typeof t.flavour||Array.isArray(t.labels)||"string"==typeof t.labels||Array.isArray(t.units)||"function"==typeof t.custom)}var Y={}.constructor;var q=60,V=3600,J=86400,B=7*J,G=2630016,H=31556952;function K(t){switch(t){case"second":return 1;case"minute":return q;case"hour":return V;case"day":return J;case"week":return B;case"month":return G;case"year":return H}}function Q(t){return void 0!==t.factor?t.factor:K(t.unit||t.formatAs)||1}function W(t){return"floor"===t?Math.floor:Math.round}function X(t){return"floor"===t?1:.5}function Z(t){return Z="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Z(t)}function tt(t,e){var r,n=e.prevStep,o=e.timestamp,i=e.now,u=e.future,a=e.round;return n&&(n.id||n.unit)&&(r=t["threshold_for_".concat(n.id||n.unit)]),void 0===r&&void 0!==t.threshold&&"function"==typeof(r=t.threshold)&&(r=r(i,u)),void 0===r&&(r=t.minTime),"object"===Z(r)&&(r=n&&n.id&&void 0!==r[n.id]?r[n.id]:r.default),"function"==typeof r&&(r=r(o,{future:u,getMinTimeForUnit:function(t,e){return et(t,e||n&&n.formatAs,{round:a})}})),void 0===r&&t.test&&(r=t.test(o,{now:i,future:u})?0:9007199254740991),void 0===r&&(n?t.formatAs&&n.formatAs&&(r=et(t.formatAs,n.formatAs,{round:a})):r=0),void 0===r&&console.warn("[javascript-time-ago] A step should specify `minTime`:\n"+JSON.stringify(t,null,2)),r}function et(t,e,r){var n,o=r.round,i=K(t);if(n=K("now"===e?t:e),void 0!==i&&void 0!==n)return i-n*(1-X(o))}function rt(t){return rt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},rt(t)}function nt(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),r.push.apply(r,n)}return r}function ot(t,e,r){return(e=function(t){var e=function(t,e){if("object"!=rt(t)||!t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,e||"default");if("object"!=rt(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==rt(e)?e:e+""}(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function it(t,e,r){var n=r.now,o=r.future,i=r.round,u=r.units,a=r.getNextStep;t=function(t,e){return t.filter(function(t){var r=t.unit,n=t.formatAs;return!(r=r||n)||e.indexOf(r)>=0})}(t,u);var c=function(t,e,r){var n=r.now,o=r.future,i=r.round;if(0===t.length)return;var u=ut(t,e,{now:n,future:o||e<0,round:i});if(-1===u)return;var a=t[u];if(a.granularity){if(0===W(i)(Math.abs(e)/Q(a)/a.granularity)*a.granularity&&u>0)return t[u-1]}return a}(t,e,{now:n,future:o,round:i});return a?c?[t[t.indexOf(c)-1],c,t[t.indexOf(c)+1]]:[void 0,void 0,t[0]]:c}function ut(t,e,r){var n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0,o=tt(t[n],function(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?nt(Object(r),!0).forEach(function(e){ot(t,e,r[e])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):nt(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))})}return t}({prevStep:t[n-1],timestamp:r.now-1e3*e},r));return void 0===o||Math.abs(e)<o?n-1:n===t.length-1?n:ut(t,e,r,n+1)}function at(t,e,r){var n=r.now,o=r.round;if(K(t)){var i=1e3*K(t),u=e>n,a=Math.abs(e-n),c=W(o)(a/i)*i;return u?c>0?a-c+function(t,e){return(1-X(t))*e+1}(o,i):a-c+1:-(a-c)+function(t,e){return X(t)*e}(o,i)}}var ct=31536e9;function ft(t,e,r){var n=r.prevStep,o=r.nextStep,i=r.now,u=r.future,a=r.round,c=t.getTime?t.getTime():t,f=function(t){return at(t,c,{now:i,round:a})},l=function(t,e,r){var n=r.now,o=r.future,i=r.round,u=r.prevStep;if(t){var a=function(t,e,r){var n=r.now,o=r.future,i=r.round,u=r.prevStep,a=tt(t,{timestamp:e,now:n,future:o,round:i,prevStep:u});if(void 0===a)return;return o?e-1e3*a+1:0===a&&e===n?ct:e+1e3*a}(t,e,{now:n,future:o,round:i,prevStep:u});if(void 0===a)return;return a-n}return o?e-n+1:ct}(u?e:o,c,{future:u,now:i,round:a,prevStep:u?n:e});if(void 0!==l){var s;if(e&&(e.getTimeToNextUpdate&&(s=e.getTimeToNextUpdate(c,{getTimeToNextUpdateForUnit:f,getRoundFunction:W,now:i,future:u,round:a})),void 0===s)){var y=e.unit||e.formatAs;y&&(s=f(y))}return void 0===s?l:Math.min(s,l)}}var lt={};function st(t){return lt[t]}function yt(t){if(!t)throw new Error("[javascript-time-ago] No locale data passed.");lt[t.locale]=t}var mt={steps:[{formatAs:"now"},{formatAs:"second"},{formatAs:"minute"},{formatAs:"hour"},{formatAs:"day"},{formatAs:"week"},{formatAs:"month"},{formatAs:"year"}],labels:"long"};function pt(t){return pt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},pt(t)}function bt(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),r.push.apply(r,n)}return r}function vt(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?bt(Object(r),!0).forEach(function(e){ht(t,e,r[e])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):bt(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))})}return t}function ht(t,e,r){return(e=function(t){var e=function(t,e){if("object"!=pt(t)||!t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,e||"default");if("object"!=pt(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==pt(e)?e:e+""}(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var dt=vt(vt({},mt),{},{steps:mt.steps.filter(function(t){return"second"!==t.formatAs})}),gt=[{factor:1,unit:"now"},{threshold:1,threshold_for_now:45.5,factor:1,unit:"second"},{threshold:45.5,factor:q,unit:"minute"},{threshold:150,granularity:5,factor:q,unit:"minute"},{threshold:1350,factor:1800,unit:"half-hour"},{threshold:2550,threshold_for_minute:3150,factor:V,unit:"hour"},{threshold:73800,factor:J,unit:"day"},{threshold:475200,factor:B,unit:"week"},{threshold:2116800,factor:G,unit:"month"},{threshold:27615168,factor:H,unit:"year"}],wt={gradation:gt,flavour:"long",units:["now","minute","hour","day","week","month","year"]},Ot={gradation:gt,flavour:"long-time",units:["now","minute","hour","day","week","month","year"]};function St(t){return t instanceof Date?t:new Date(t)}var jt=[{formatAs:"second"},{formatAs:"minute"},{formatAs:"hour"}],Pt={},At={minTime:function(t,e){return e.future,(0,e.getMinTimeForUnit)("day")},format:function(t,e){return Pt[e]||(Pt[e]={}),Pt[e].dayMonth||(Pt[e].dayMonth=new Intl.DateTimeFormat(e,{month:"short",day:"numeric"})),Pt[e].dayMonth.format(St(t))}},Tt={minTime:function(t,e){return e.future?(t-(new Date(new Date(t).getFullYear(),0).getTime()-1))/1e3:(new Date(new Date(t).getFullYear()+1,0).getTime()-t)/1e3},format:function(t,e){return Pt[e]||(Pt[e]={}),Pt[e].dayMonthYear||(Pt[e].dayMonthYear=new Intl.DateTimeFormat(e,{year:"numeric",month:"short",day:"numeric"})),Pt[e].dayMonthYear.format(St(t))}};"object"===("undefined"==typeof Intl?"undefined":L(Intl))&&"function"==typeof Intl.DateTimeFormat?jt.push(At,Tt):jt.push({formatAs:"day"},{formatAs:"week"},{formatAs:"month"},{formatAs:"year"});var kt={steps:jt,labels:["mini","short-time","narrow","short"]};function Dt(t){return Dt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Dt(t)}function Et(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),r.push.apply(r,n)}return r}function Nt(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?Et(Object(r),!0).forEach(function(e){Ft(t,e,r[e])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Et(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))})}return t}function Ft(t,e,r){return(e=function(t){var e=function(t,e){if("object"!=Dt(t)||!t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,e||"default");if("object"!=Dt(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==Dt(e)?e:e+""}(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var It=Nt(Nt({},kt),{},{steps:[{formatAs:"now"}].concat(kt.steps)});function Mt(t){return Mt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Mt(t)}function Rt(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),r.push.apply(r,n)}return r}function zt(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?Rt(Object(r),!0).forEach(function(e){xt(t,e,r[e])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Rt(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))})}return t}function xt(t,e,r){return(e=function(t){var e=function(t,e){if("object"!=Mt(t)||!t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,e||"default");if("object"!=Mt(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==Mt(e)?e:e+""}(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var Lt=zt(zt({},kt),{},{steps:kt.steps.filter(function(t){return"second"!==t.formatAs})});function Ct(t){return Ct="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ct(t)}function Ut(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),r.push.apply(r,n)}return r}function $t(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?Ut(Object(r),!0).forEach(function(e){_t(t,e,r[e])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Ut(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))})}return t}function _t(t,e,r){return(e=function(t){var e=function(t,e){if("object"!=Ct(t)||!t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,e||"default");if("object"!=Ct(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==Ct(e)?e:e+""}(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var Yt=$t($t({},Lt),{},{steps:[{formatAs:"now"}].concat(Lt.steps)});function qt(t){return qt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},qt(t)}function Vt(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),r.push.apply(r,n)}return r}function Jt(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?Vt(Object(r),!0).forEach(function(e){Bt(t,e,r[e])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Vt(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))})}return t}function Bt(t,e,r){return(e=function(t){var e=function(t,e){if("object"!=qt(t)||!t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,e||"default");if("object"!=qt(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==qt(e)?e:e+""}(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var Gt=Jt(Jt({},kt),{},{steps:kt.steps.filter(function(t){return"second"!==t.formatAs}).map(function(t){return"minute"===t.formatAs?Jt(Jt({},t),{},{minTime:q}):t})}),Ht={steps:[{formatAs:"second"},{formatAs:"minute"},{formatAs:"hour"},{formatAs:"day"},{formatAs:"month"},{formatAs:"year"}],labels:["mini","short-time","narrow","short"]};function Kt(t){return Kt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Kt(t)}function Qt(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),r.push.apply(r,n)}return r}function Wt(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?Qt(Object(r),!0).forEach(function(e){Xt(t,e,r[e])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Qt(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))})}return t}function Xt(t,e,r){return(e=function(t){var e=function(t,e){if("object"!=Kt(t)||!t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,e||"default");if("object"!=Kt(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==Kt(e)?e:e+""}(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var Zt=Wt(Wt({},Ht),{},{steps:[{formatAs:"now"}].concat(Ht.steps)});function te(t){return te="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},te(t)}function ee(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),r.push.apply(r,n)}return r}function re(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?ee(Object(r),!0).forEach(function(e){ne(t,e,r[e])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):ee(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))})}return t}function ne(t,e,r){return(e=function(t){var e=function(t,e){if("object"!=te(t)||!t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,e||"default");if("object"!=te(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==te(e)?e:e+""}(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var oe=re(re({},Ht),{},{steps:Ht.steps.filter(function(t){return"second"!==t.formatAs})});function ie(t){return ie="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ie(t)}function ue(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),r.push.apply(r,n)}return r}function ae(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?ue(Object(r),!0).forEach(function(e){ce(t,e,r[e])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):ue(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))})}return t}function ce(t,e,r){return(e=function(t){var e=function(t,e){if("object"!=ie(t)||!t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,e||"default");if("object"!=ie(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==ie(e)?e:e+""}(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var fe=ae(ae({},oe),{},{steps:[{formatAs:"now"}].concat(oe.steps)});function le(t){switch(t){case"default":case"round":return mt;case"round-minute":return dt;case"approximate":default:return wt;case"time":case"approximate-time":return Ot;case"mini":return Ht;case"mini-now":return Zt;case"mini-minute":return oe;case"mini-minute-now":return fe;case"twitter":return kt;case"twitter-now":return It;case"twitter-minute":return Lt;case"twitter-minute-now":return Yt;case"twitter-first-minute":return Gt}}function se(t){return se="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},se(t)}function ye(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,i,u,a=[],c=!0,f=!1;try{if(i=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;c=!1}else for(;!(c=(n=i.call(r)).done)&&(a.push(n.value),a.length!==e);c=!0);}catch(t){f=!0,o=t}finally{try{if(!c&&null!=r.return&&(u=r.return(),Object(u)!==u))return}finally{if(f)throw o}}return a}}(t,e)||me(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function me(t,e){if(t){if("string"==typeof t)return pe(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?pe(t,e):void 0}}function pe(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function be(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,ve(n.key),n)}}function ve(t){var e=function(t,e){if("object"!=se(t)||!t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,e||"default");if("object"!=se(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==se(e)?e:e+""}var he,de=function(){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],r=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).polyfill;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),"string"==typeof e&&(e=[e]),this.locale=function(t,e){for(var r,n=C(t);!(r=n()).done;){var o=r.value;if(e(o))return o;for(var i=o.split("-");i.length>1;)if(i.pop(),e(o=i.join("-")))return o}throw new Error("No locale data has been registered for any of the locales: ".concat(t.join(", ")))}(e.concat(t.getDefaultLocale()),st),"undefined"!=typeof Intl&&Intl.NumberFormat&&(this.numberFormat=new Intl.NumberFormat(this.locale)),!1===r?(this.IntlRelativeTimeFormat=Intl.RelativeTimeFormat,this.IntlPluralRules=Intl.PluralRules):(this.IntlRelativeTimeFormat=k,this.IntlPluralRules=k.PluralRules),this.relativeTimeFormatCache=new x,this.pluralRulesCache=new x}var e,r,n;return e=t,r=[{key:"format",value:function(t,e,r){var n;r||(e&&"string"!=typeof(n=e)&&!_(n)?(r=e,e=void 0):r={}),e||(e=dt),"string"==typeof e&&(e=le(e));var o,i=function(t){if(t.constructor===Date||"object"===se(e=t)&&"function"==typeof e.getTime)return t.getTime();var e;if("number"==typeof t)return t;throw new Error("Unsupported relative time formatter input: ".concat(se(t),", ").concat(t))}(t),u=this.getLabels(e.flavour||e.labels),a=u.labels,c=u.labelsType;void 0!==e.now&&(o=e.now),void 0===o&&void 0!==r.now&&(o=r.now),void 0===o&&(o=Date.now());var f=(o-i)/1e3,l=r.future||f<0,s=function(t,e,r,n){var o=t.now||e&&e.now;return o?"string"==typeof o?o:n?o.future:o.past:r&&r.second&&r.second.current?r.second.current:void 0}(a,st(this.locale).now,st(this.locale).long,l);if(e.custom){var y=e.custom({now:o,date:new Date(i),time:i,elapsed:f,locale:this.locale});if(void 0!==y)return y}var m=function(t,e,r){var n=Object.keys(e);return r&&n.push("now"),t&&(n=t.filter(function(t){return"now"===t||n.indexOf(t)>=0})),n}(e.units,a,s),p=r.round||e.round,b=ye(it(e.gradation||e.steps||dt.steps,f,{now:o,units:m,round:p,future:l,getNextStep:!0}),3),v=b[0],h=b[1],d=b[2],g=this.formatDateForStep(i,h,f,{labels:a,labelsType:c,nowLabel:s,now:o,future:l,round:p})||"";return r.getTimeToNextUpdate?[g,ft(i,h,{nextStep:d,prevStep:v,now:o,future:l,round:p})]:g}},{key:"formatDateForStep",value:function(t,e,r,n){var o=this,i=n.labels,u=n.labelsType,a=n.nowLabel,c=n.now,f=n.future,l=n.round;if(e){if(e.format)return e.format(t,this.locale,{formatAs:function(t,e){return o.formatValue(e,t,{labels:i,future:f})},now:c,future:f});var s=e.unit||e.formatAs;if(!s)throw new Error("[javascript-time-ago] Each step must define either `formatAs` or `format()`. Step: ".concat(JSON.stringify(e)));if("now"===s)return a;var y=Math.abs(r)/Q(e);e.granularity&&(y=W(l)(y/e.granularity)*e.granularity);var m=-1*Math.sign(r)*W(l)(y);switch(0===m&&(m=f?0:-0),u){case"long":case"short":case"narrow":return this.getFormatter(u).format(m,s);default:return this.formatValue(m,s,{labels:i,future:f})}}}},{key:"formatValue",value:function(t,e,r){var n=r.labels,o=r.future;return this.getFormattingRule(n,e,t,{future:o}).replace("{0}",this.formatNumber(Math.abs(t)))}},{key:"getFormattingRule",value:function(t,e,r,n){var o=n.future;if(this.locale,"string"==typeof(t=t[e]))return t;var i=t[0===r?o?"future":"past":r<0?"past":"future"]||t;return"string"==typeof i?i:i[this.getPluralRules().select(Math.abs(r))]||i.other}},{key:"formatNumber",value:function(t){return this.numberFormat?this.numberFormat.format(t):String(t)}},{key:"getFormatter",value:function(t){return this.relativeTimeFormatCache.get(this.locale,t)||this.relativeTimeFormatCache.put(this.locale,t,new this.IntlRelativeTimeFormat(this.locale,{style:t}))}},{key:"getPluralRules",value:function(){return this.pluralRulesCache.get(this.locale)||this.pluralRulesCache.put(this.locale,new this.IntlPluralRules(this.locale))}},{key:"getLabels",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];"string"==typeof t&&(t=[t]),t=(t=t.map(function(t){switch(t){case"tiny":case"mini-time":return"mini";default:return t}})).concat("long");for(var e,r=st(this.locale),n=function(t,e){var r="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(r)return(r=r.call(t)).next.bind(r);if(Array.isArray(t)||(r=me(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0;return function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(t);!(e=n()).done;){var o=e.value;if(r[o])return{labelsType:o,labels:r[o]}}}}],r&&be(e.prototype,r),n&&be(e,n),Object.defineProperty(e,"prototype",{writable:!1}),t}(),ge="en";return de.getDefaultLocale=function(){return ge},de.setDefaultLocale=function(t){return ge=t},de.addDefaultLocale=function(t){if(he)return console.error("[javascript-time-ago] `TimeAgo.addDefaultLocale()` can only be called once. To add other locales, use `TimeAgo.addLocale()`.");he=!0,de.setDefaultLocale(t.locale),de.addLocale(t)},de.addLocale=function(t){yt(t),k.addLocale(t)},de.locale=de.addLocale,de.addLabels=function(t,e,r){var n=st(t);n||(yt({locale:t}),n=st(t)),n[e]=r},de});
2
2
  //# sourceMappingURL=javascript-time-ago.js.map