javascript-time-ago 2.6.1 → 2.6.3

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 (235) hide show
  1. package/README.md +2 -2
  2. package/bundle/javascript-time-ago.js +1 -1
  3. package/bundle/javascript-time-ago.js.map +1 -1
  4. package/bundle/javascript-time-ago.min.js +1 -1
  5. package/bundle/javascript-time-ago.min.js.map +1 -1
  6. package/commonjs/FullDateFormatter.test.js +11 -9
  7. package/commonjs/FullDateFormatter.test.js.map +1 -1
  8. package/commonjs/TimeAgo.js +8 -5
  9. package/commonjs/TimeAgo.js.map +1 -1
  10. package/commonjs/TimeAgo.test.js +237 -236
  11. package/commonjs/TimeAgo.test.js.map +1 -1
  12. package/commonjs/cache.test.js +8 -6
  13. package/commonjs/cache.test.js.map +1 -1
  14. package/commonjs/isStyleObject.test.js +21 -19
  15. package/commonjs/isStyleObject.test.js.map +1 -1
  16. package/commonjs/locale.test.js +16 -14
  17. package/commonjs/locale.test.js.map +1 -1
  18. package/commonjs/steps/approximate.test.js +26 -24
  19. package/commonjs/steps/approximate.test.js.map +1 -1
  20. package/commonjs/steps/getStep.test.js +20 -18
  21. package/commonjs/steps/getStep.test.js.map +1 -1
  22. package/commonjs/steps/getStepDenominator.test.js +9 -7
  23. package/commonjs/steps/getStepDenominator.test.js.map +1 -1
  24. package/commonjs/steps/getStepMinTime.test.js +9 -7
  25. package/commonjs/steps/getStepMinTime.test.js.map +1 -1
  26. package/commonjs/steps/getTimeToNextUpdate.test.js +56 -54
  27. package/commonjs/steps/getTimeToNextUpdate.test.js.map +1 -1
  28. package/commonjs/steps/getTimeToNextUpdateForUnit.test.js +20 -18
  29. package/commonjs/steps/getTimeToNextUpdateForUnit.test.js.map +1 -1
  30. package/commonjs/steps/helpers.test.js +6 -4
  31. package/commonjs/steps/helpers.test.js.map +1 -1
  32. package/commonjs/steps/renameLegacyProperties.test.js +12 -10
  33. package/commonjs/steps/renameLegacyProperties.test.js.map +1 -1
  34. package/commonjs/steps/round.test.js +27 -25
  35. package/commonjs/steps/round.test.js.map +1 -1
  36. package/commonjs/style/approximateTime.test.js +6 -5
  37. package/commonjs/style/approximateTime.test.js.map +1 -1
  38. package/commonjs/style/mini.test.js +62 -60
  39. package/commonjs/style/mini.test.js.map +1 -1
  40. package/commonjs/style/miniMinute.test.js +27 -25
  41. package/commonjs/style/miniMinute.test.js.map +1 -1
  42. package/commonjs/style/miniMinuteNow.test.js +27 -25
  43. package/commonjs/style/miniMinuteNow.test.js.map +1 -1
  44. package/commonjs/style/miniNow.test.js +27 -25
  45. package/commonjs/style/miniNow.test.js.map +1 -1
  46. package/commonjs/style/renameLegacyProperties.test.js +9 -7
  47. package/commonjs/style/renameLegacyProperties.test.js.map +1 -1
  48. package/commonjs/style/round.test.js +81 -79
  49. package/commonjs/style/round.test.js.map +1 -1
  50. package/commonjs/style/roundMinute.test.js +50 -48
  51. package/commonjs/style/roundMinute.test.js.map +1 -1
  52. package/commonjs/style/twitter.test.js +86 -84
  53. package/commonjs/style/twitter.test.js.map +1 -1
  54. package/commonjs/style/twitterFirstMinute.test.js +33 -31
  55. package/commonjs/style/twitterFirstMinute.test.js.map +1 -1
  56. package/commonjs/style/twitterMinute.test.js +32 -30
  57. package/commonjs/style/twitterMinute.test.js.map +1 -1
  58. package/commonjs/style/twitterMinuteNow.test.js +32 -30
  59. package/commonjs/style/twitterMinuteNow.test.js.map +1 -1
  60. package/commonjs/style/twitterNow.test.js +34 -32
  61. package/commonjs/style/twitterNow.test.js.map +1 -1
  62. package/index.d.ts +46 -7
  63. package/load-all-locales/index.cjs +15 -0
  64. package/load-all-locales/index.cjs.js +15 -0
  65. package/load-all-locales/index.js +30 -0
  66. package/locale/ak.json +8 -26
  67. package/locale/ak.json.js +8 -26
  68. package/locale/am.json +3 -3
  69. package/locale/am.json.js +3 -3
  70. package/locale/ba/package.json +16 -0
  71. package/locale/ba.json +159 -0
  72. package/locale/ba.json.d.ts +4 -0
  73. package/locale/ba.json.js +159 -0
  74. package/locale/be-tarask.json +4 -4
  75. package/locale/be-tarask.json.js +4 -4
  76. package/locale/be.json +4 -4
  77. package/locale/be.json.js +4 -4
  78. package/locale/bn.json +6 -6
  79. package/locale/bn.json.js +6 -6
  80. package/locale/bs.json +36 -30
  81. package/locale/bs.json.js +36 -30
  82. package/locale/bua/package.json +16 -0
  83. package/locale/bua.json +159 -0
  84. package/locale/bua.json.d.ts +4 -0
  85. package/locale/bua.json.js +159 -0
  86. package/locale/cv.json +134 -82
  87. package/locale/cv.json.js +134 -82
  88. package/locale/en-EE/package.json +16 -0
  89. package/locale/en-EE.json +219 -0
  90. package/locale/en-EE.json.d.ts +4 -0
  91. package/locale/en-EE.json.js +219 -0
  92. package/locale/en-GE/package.json +16 -0
  93. package/locale/en-GE.json +219 -0
  94. package/locale/en-GE.json.d.ts +4 -0
  95. package/locale/en-GE.json.js +219 -0
  96. package/locale/en-LT/package.json +16 -0
  97. package/locale/en-LT.json +219 -0
  98. package/locale/en-LT.json.d.ts +4 -0
  99. package/locale/en-LT.json.js +219 -0
  100. package/locale/en-LV/package.json +16 -0
  101. package/locale/en-LV.json +219 -0
  102. package/locale/en-LV.json.d.ts +4 -0
  103. package/locale/en-LV.json.js +219 -0
  104. package/locale/en-UA/package.json +16 -0
  105. package/locale/en-UA.json +219 -0
  106. package/locale/en-UA.json.d.ts +4 -0
  107. package/locale/en-UA.json.js +219 -0
  108. package/locale/es-MX.json +2 -8
  109. package/locale/es-MX.json.js +2 -8
  110. package/locale/fr-CA.json +4 -4
  111. package/locale/fr-CA.json.js +4 -4
  112. package/locale/fr.json +4 -4
  113. package/locale/fr.json.js +4 -4
  114. package/locale/he.json +74 -86
  115. package/locale/he.json.js +74 -86
  116. package/locale/ht.json +4 -4
  117. package/locale/ht.json.js +4 -4
  118. package/locale/ie.json +15 -9
  119. package/locale/ie.json.js +15 -9
  120. package/locale/kk-Arab/package.json +16 -0
  121. package/locale/kk-Arab.json +159 -0
  122. package/locale/kk-Arab.json.d.ts +4 -0
  123. package/locale/kk-Arab.json.js +159 -0
  124. package/locale/kok-Latn.json +138 -39
  125. package/locale/kok-Latn.json.js +138 -39
  126. package/locale/kok.json +169 -64
  127. package/locale/kok.json.js +169 -64
  128. package/locale/ku.json +166 -73
  129. package/locale/ku.json.js +166 -73
  130. package/locale/mk.json +20 -20
  131. package/locale/mk.json.js +20 -20
  132. package/locale/nso/package.json +16 -0
  133. package/locale/nso.json +159 -0
  134. package/locale/nso.json.d.ts +4 -0
  135. package/locale/nso.json.js +159 -0
  136. package/locale/rm.json +151 -85
  137. package/locale/rm.json.js +151 -85
  138. package/locale/ro.json +4 -2
  139. package/locale/ro.json.js +4 -2
  140. package/locale/rw/package.json +16 -0
  141. package/locale/rw.json +159 -0
  142. package/locale/rw.json.d.ts +4 -0
  143. package/locale/rw.json.js +159 -0
  144. package/locale/scn/package.json +16 -0
  145. package/locale/scn.json +249 -0
  146. package/locale/scn.json.d.ts +4 -0
  147. package/locale/scn.json.js +249 -0
  148. package/locale/sd-Deva/package.json +16 -0
  149. package/locale/sd-Deva.json +159 -0
  150. package/locale/sd-Deva.json.d.ts +4 -0
  151. package/locale/sd-Deva.json.js +159 -0
  152. package/locale/sd.json +77 -20
  153. package/locale/sd.json.js +77 -20
  154. package/locale/shn/package.json +16 -0
  155. package/locale/shn.json +159 -0
  156. package/locale/shn.json.d.ts +4 -0
  157. package/locale/shn.json.js +159 -0
  158. package/locale/sv.json +3 -3
  159. package/locale/sv.json.js +3 -3
  160. package/locale/syr.json +27 -27
  161. package/locale/syr.json.js +27 -27
  162. package/locale/ta.json +15 -9
  163. package/locale/ta.json.js +15 -9
  164. package/locale/tn.json +27 -27
  165. package/locale/tn.json.js +27 -27
  166. package/locale/tok/package.json +16 -0
  167. package/locale/tok.json +159 -0
  168. package/locale/tok.json.d.ts +4 -0
  169. package/locale/tok.json.js +159 -0
  170. package/locale/tyv/package.json +16 -0
  171. package/locale/tyv.json +159 -0
  172. package/locale/tyv.json.d.ts +4 -0
  173. package/locale/tyv.json.js +159 -0
  174. package/locale/xh.json +18 -18
  175. package/locale/xh.json.js +18 -18
  176. package/modules/FullDateFormatter.test.js +2 -0
  177. package/modules/FullDateFormatter.test.js.map +1 -1
  178. package/modules/TimeAgo.js +8 -5
  179. package/modules/TimeAgo.js.map +1 -1
  180. package/modules/TimeAgo.test.js +190 -189
  181. package/modules/TimeAgo.test.js.map +1 -1
  182. package/modules/cache.test.js +2 -0
  183. package/modules/cache.test.js.map +1 -1
  184. package/modules/isStyleObject.test.js +19 -17
  185. package/modules/isStyleObject.test.js.map +1 -1
  186. package/modules/locale.test.js +12 -10
  187. package/modules/locale.test.js.map +1 -1
  188. package/modules/steps/approximate.test.js +2 -0
  189. package/modules/steps/approximate.test.js.map +1 -1
  190. package/modules/steps/getStep.test.js +7 -5
  191. package/modules/steps/getStep.test.js.map +1 -1
  192. package/modules/steps/getStepDenominator.test.js +6 -4
  193. package/modules/steps/getStepDenominator.test.js.map +1 -1
  194. package/modules/steps/getStepMinTime.test.js +6 -4
  195. package/modules/steps/getStepMinTime.test.js.map +1 -1
  196. package/modules/steps/getTimeToNextUpdate.test.js +36 -34
  197. package/modules/steps/getTimeToNextUpdate.test.js.map +1 -1
  198. package/modules/steps/getTimeToNextUpdateForUnit.test.js +12 -10
  199. package/modules/steps/getTimeToNextUpdateForUnit.test.js.map +1 -1
  200. package/modules/steps/helpers.test.js +4 -2
  201. package/modules/steps/helpers.test.js.map +1 -1
  202. package/modules/steps/renameLegacyProperties.test.js +8 -6
  203. package/modules/steps/renameLegacyProperties.test.js.map +1 -1
  204. package/modules/steps/round.test.js +2 -0
  205. package/modules/steps/round.test.js.map +1 -1
  206. package/modules/style/approximateTime.test.js +3 -2
  207. package/modules/style/approximateTime.test.js.map +1 -1
  208. package/modules/style/mini.test.js +58 -56
  209. package/modules/style/mini.test.js.map +1 -1
  210. package/modules/style/miniMinute.test.js +25 -23
  211. package/modules/style/miniMinute.test.js.map +1 -1
  212. package/modules/style/miniMinuteNow.test.js +25 -23
  213. package/modules/style/miniMinuteNow.test.js.map +1 -1
  214. package/modules/style/miniNow.test.js +25 -23
  215. package/modules/style/miniNow.test.js.map +1 -1
  216. package/modules/style/renameLegacyProperties.test.js +6 -4
  217. package/modules/style/renameLegacyProperties.test.js.map +1 -1
  218. package/modules/style/round.test.js +76 -74
  219. package/modules/style/round.test.js.map +1 -1
  220. package/modules/style/roundMinute.test.js +47 -45
  221. package/modules/style/roundMinute.test.js.map +1 -1
  222. package/modules/style/twitter.test.js +72 -70
  223. package/modules/style/twitter.test.js.map +1 -1
  224. package/modules/style/twitterFirstMinute.test.js +29 -27
  225. package/modules/style/twitterFirstMinute.test.js.map +1 -1
  226. package/modules/style/twitterMinute.test.js +29 -27
  227. package/modules/style/twitterMinute.test.js.map +1 -1
  228. package/modules/style/twitterMinuteNow.test.js +29 -27
  229. package/modules/style/twitterMinuteNow.test.js.map +1 -1
  230. package/modules/style/twitterNow.test.js +31 -29
  231. package/modules/style/twitterNow.test.js.map +1 -1
  232. package/package.json +129 -8
  233. /package/{bin → scripts}/create-commonjs-package-json.js +0 -0
  234. /package/{bin → scripts}/generate-load-all-locales.js +0 -0
  235. /package/{bin → scripts}/generate-locale-messages.js +0 -0
@@ -0,0 +1,16 @@
1
+ {
2
+ "private": true,
3
+ "name": "javascript-time-ago/locale/tyv",
4
+ "main": "../tyv.json",
5
+ "module": "../tyv.json.js",
6
+ "types": "../tyv.json.d.ts",
7
+ "type": "module",
8
+ "exports": {
9
+ ".": {
10
+ "types": "../tyv.json.d.ts",
11
+ "import": "../tyv.json.js",
12
+ "require": "../tyv.json"
13
+ }
14
+ },
15
+ "sideEffects": false
16
+ }
@@ -0,0 +1,159 @@
1
+ {
2
+ "locale": "tyv",
3
+ "long": {
4
+ "year": {
5
+ "previous": "эрткен чыл",
6
+ "current": "амгы чыл",
7
+ "next": "келир чыл",
8
+ "past": "-{0} y",
9
+ "future": "+{0} y"
10
+ },
11
+ "quarter": {
12
+ "previous": "last quarter",
13
+ "current": "this quarter",
14
+ "next": "next quarter",
15
+ "past": "-{0} Q",
16
+ "future": "+{0} Q"
17
+ },
18
+ "month": {
19
+ "previous": "last month",
20
+ "current": "this month",
21
+ "next": "next month",
22
+ "past": "-{0} m",
23
+ "future": "+{0} m"
24
+ },
25
+ "week": {
26
+ "previous": "last week",
27
+ "current": "this week",
28
+ "next": "next week",
29
+ "past": "-{0} w",
30
+ "future": "+{0} w"
31
+ },
32
+ "day": {
33
+ "previous": "yesterday",
34
+ "current": "today",
35
+ "next": "tomorrow",
36
+ "past": "-{0} d",
37
+ "future": "+{0} d"
38
+ },
39
+ "hour": {
40
+ "current": "this hour",
41
+ "past": "-{0} h",
42
+ "future": "+{0} h"
43
+ },
44
+ "minute": {
45
+ "current": "this minute",
46
+ "past": "-{0} min",
47
+ "future": "+{0} min"
48
+ },
49
+ "second": {
50
+ "current": "now",
51
+ "past": "-{0} s",
52
+ "future": "+{0} s"
53
+ }
54
+ },
55
+ "short": {
56
+ "year": {
57
+ "previous": "эрткен чыл",
58
+ "current": "амгы чыл",
59
+ "next": "келир чыл",
60
+ "past": "-{0} y",
61
+ "future": "+{0} y"
62
+ },
63
+ "quarter": {
64
+ "previous": "last quarter",
65
+ "current": "this quarter",
66
+ "next": "next quarter",
67
+ "past": "-{0} Q",
68
+ "future": "+{0} Q"
69
+ },
70
+ "month": {
71
+ "previous": "last month",
72
+ "current": "this month",
73
+ "next": "next month",
74
+ "past": "-{0} m",
75
+ "future": "+{0} m"
76
+ },
77
+ "week": {
78
+ "previous": "last week",
79
+ "current": "this week",
80
+ "next": "next week",
81
+ "past": "-{0} w",
82
+ "future": "+{0} w"
83
+ },
84
+ "day": {
85
+ "previous": "yesterday",
86
+ "current": "today",
87
+ "next": "tomorrow",
88
+ "past": "-{0} d",
89
+ "future": "+{0} d"
90
+ },
91
+ "hour": {
92
+ "current": "this hour",
93
+ "past": "-{0} h",
94
+ "future": "+{0} h"
95
+ },
96
+ "minute": {
97
+ "current": "this minute",
98
+ "past": "-{0} min",
99
+ "future": "+{0} min"
100
+ },
101
+ "second": {
102
+ "current": "now",
103
+ "past": "-{0} s",
104
+ "future": "+{0} s"
105
+ }
106
+ },
107
+ "narrow": {
108
+ "year": {
109
+ "previous": "эрткен чыл",
110
+ "current": "амгы чыл",
111
+ "next": "келир чыл",
112
+ "past": "-{0} y",
113
+ "future": "+{0} y"
114
+ },
115
+ "quarter": {
116
+ "previous": "last quarter",
117
+ "current": "this quarter",
118
+ "next": "next quarter",
119
+ "past": "-{0} Q",
120
+ "future": "+{0} Q"
121
+ },
122
+ "month": {
123
+ "previous": "last month",
124
+ "current": "this month",
125
+ "next": "next month",
126
+ "past": "-{0} m",
127
+ "future": "+{0} m"
128
+ },
129
+ "week": {
130
+ "previous": "last week",
131
+ "current": "this week",
132
+ "next": "next week",
133
+ "past": "-{0} w",
134
+ "future": "+{0} w"
135
+ },
136
+ "day": {
137
+ "previous": "yesterday",
138
+ "current": "today",
139
+ "next": "tomorrow",
140
+ "past": "-{0} d",
141
+ "future": "+{0} d"
142
+ },
143
+ "hour": {
144
+ "current": "this hour",
145
+ "past": "-{0} h",
146
+ "future": "+{0} h"
147
+ },
148
+ "minute": {
149
+ "current": "this minute",
150
+ "past": "-{0} min",
151
+ "future": "+{0} min"
152
+ },
153
+ "second": {
154
+ "current": "now",
155
+ "past": "-{0} s",
156
+ "future": "+{0} s"
157
+ }
158
+ }
159
+ }
@@ -0,0 +1,4 @@
1
+ import { LocaleData } from '../index.d.js';
2
+
3
+ declare const localeData: LocaleData;
4
+ export default localeData;
@@ -0,0 +1,159 @@
1
+ export default {
2
+ "locale": "tyv",
3
+ "long": {
4
+ "year": {
5
+ "previous": "эрткен чыл",
6
+ "current": "амгы чыл",
7
+ "next": "келир чыл",
8
+ "past": "-{0} y",
9
+ "future": "+{0} y"
10
+ },
11
+ "quarter": {
12
+ "previous": "last quarter",
13
+ "current": "this quarter",
14
+ "next": "next quarter",
15
+ "past": "-{0} Q",
16
+ "future": "+{0} Q"
17
+ },
18
+ "month": {
19
+ "previous": "last month",
20
+ "current": "this month",
21
+ "next": "next month",
22
+ "past": "-{0} m",
23
+ "future": "+{0} m"
24
+ },
25
+ "week": {
26
+ "previous": "last week",
27
+ "current": "this week",
28
+ "next": "next week",
29
+ "past": "-{0} w",
30
+ "future": "+{0} w"
31
+ },
32
+ "day": {
33
+ "previous": "yesterday",
34
+ "current": "today",
35
+ "next": "tomorrow",
36
+ "past": "-{0} d",
37
+ "future": "+{0} d"
38
+ },
39
+ "hour": {
40
+ "current": "this hour",
41
+ "past": "-{0} h",
42
+ "future": "+{0} h"
43
+ },
44
+ "minute": {
45
+ "current": "this minute",
46
+ "past": "-{0} min",
47
+ "future": "+{0} min"
48
+ },
49
+ "second": {
50
+ "current": "now",
51
+ "past": "-{0} s",
52
+ "future": "+{0} s"
53
+ }
54
+ },
55
+ "short": {
56
+ "year": {
57
+ "previous": "эрткен чыл",
58
+ "current": "амгы чыл",
59
+ "next": "келир чыл",
60
+ "past": "-{0} y",
61
+ "future": "+{0} y"
62
+ },
63
+ "quarter": {
64
+ "previous": "last quarter",
65
+ "current": "this quarter",
66
+ "next": "next quarter",
67
+ "past": "-{0} Q",
68
+ "future": "+{0} Q"
69
+ },
70
+ "month": {
71
+ "previous": "last month",
72
+ "current": "this month",
73
+ "next": "next month",
74
+ "past": "-{0} m",
75
+ "future": "+{0} m"
76
+ },
77
+ "week": {
78
+ "previous": "last week",
79
+ "current": "this week",
80
+ "next": "next week",
81
+ "past": "-{0} w",
82
+ "future": "+{0} w"
83
+ },
84
+ "day": {
85
+ "previous": "yesterday",
86
+ "current": "today",
87
+ "next": "tomorrow",
88
+ "past": "-{0} d",
89
+ "future": "+{0} d"
90
+ },
91
+ "hour": {
92
+ "current": "this hour",
93
+ "past": "-{0} h",
94
+ "future": "+{0} h"
95
+ },
96
+ "minute": {
97
+ "current": "this minute",
98
+ "past": "-{0} min",
99
+ "future": "+{0} min"
100
+ },
101
+ "second": {
102
+ "current": "now",
103
+ "past": "-{0} s",
104
+ "future": "+{0} s"
105
+ }
106
+ },
107
+ "narrow": {
108
+ "year": {
109
+ "previous": "эрткен чыл",
110
+ "current": "амгы чыл",
111
+ "next": "келир чыл",
112
+ "past": "-{0} y",
113
+ "future": "+{0} y"
114
+ },
115
+ "quarter": {
116
+ "previous": "last quarter",
117
+ "current": "this quarter",
118
+ "next": "next quarter",
119
+ "past": "-{0} Q",
120
+ "future": "+{0} Q"
121
+ },
122
+ "month": {
123
+ "previous": "last month",
124
+ "current": "this month",
125
+ "next": "next month",
126
+ "past": "-{0} m",
127
+ "future": "+{0} m"
128
+ },
129
+ "week": {
130
+ "previous": "last week",
131
+ "current": "this week",
132
+ "next": "next week",
133
+ "past": "-{0} w",
134
+ "future": "+{0} w"
135
+ },
136
+ "day": {
137
+ "previous": "yesterday",
138
+ "current": "today",
139
+ "next": "tomorrow",
140
+ "past": "-{0} d",
141
+ "future": "+{0} d"
142
+ },
143
+ "hour": {
144
+ "current": "this hour",
145
+ "past": "-{0} h",
146
+ "future": "+{0} h"
147
+ },
148
+ "minute": {
149
+ "current": "this minute",
150
+ "past": "-{0} min",
151
+ "future": "+{0} min"
152
+ },
153
+ "second": {
154
+ "current": "now",
155
+ "past": "-{0} s",
156
+ "future": "+{0} s"
157
+ }
158
+ }
159
+ }
package/locale/xh.json CHANGED
@@ -9,9 +9,9 @@
9
9
  "future": "+{0} y"
10
10
  },
11
11
  "quarter": {
12
- "previous": "last quarter",
13
- "current": "this quarter",
14
- "next": "next quarter",
12
+ "previous": "ikota edlulileyo",
13
+ "current": "ikota esikuyo",
14
+ "next": "ikota elandelayp",
15
15
  "past": "-{0} Q",
16
16
  "future": "+{0} Q"
17
17
  },
@@ -37,17 +37,17 @@
37
37
  "future": "+{0} d"
38
38
  },
39
39
  "hour": {
40
- "current": "this hour",
40
+ "current": "ngale yure",
41
41
  "past": "-{0} h",
42
42
  "future": "+{0} h"
43
43
  },
44
44
  "minute": {
45
- "current": "this minute",
45
+ "current": "ngalo mzuzu",
46
46
  "past": "-{0} min",
47
47
  "future": "+{0} min"
48
48
  },
49
49
  "second": {
50
- "current": "now",
50
+ "current": "ngoku",
51
51
  "past": "-{0} s",
52
52
  "future": "+{0} s"
53
53
  }
@@ -61,9 +61,9 @@
61
61
  "future": "+{0} y"
62
62
  },
63
63
  "quarter": {
64
- "previous": "last quarter",
65
- "current": "this quarter",
66
- "next": "next quarter",
64
+ "previous": "ikota edlulileyo",
65
+ "current": "ikota esikuyo",
66
+ "next": "ikota elandelayp",
67
67
  "past": "-{0} Q",
68
68
  "future": "+{0} Q"
69
69
  },
@@ -89,17 +89,17 @@
89
89
  "future": "+{0} d"
90
90
  },
91
91
  "hour": {
92
- "current": "this hour",
92
+ "current": "ngale yure",
93
93
  "past": "-{0} h",
94
94
  "future": "+{0} h"
95
95
  },
96
96
  "minute": {
97
- "current": "this minute",
97
+ "current": "ngalo mzuzu",
98
98
  "past": "-{0} min",
99
99
  "future": "+{0} min"
100
100
  },
101
101
  "second": {
102
- "current": "now",
102
+ "current": "ngoku",
103
103
  "past": "-{0} s",
104
104
  "future": "+{0} s"
105
105
  }
@@ -113,9 +113,9 @@
113
113
  "future": "+{0} y"
114
114
  },
115
115
  "quarter": {
116
- "previous": "last quarter",
117
- "current": "this quarter",
118
- "next": "next quarter",
116
+ "previous": "ikota edlulileyo",
117
+ "current": "ikota esikuyo",
118
+ "next": "ikota elandelayp",
119
119
  "past": "-{0} Q",
120
120
  "future": "+{0} Q"
121
121
  },
@@ -141,17 +141,17 @@
141
141
  "future": "+{0} d"
142
142
  },
143
143
  "hour": {
144
- "current": "this hour",
144
+ "current": "ngale yure",
145
145
  "past": "-{0} h",
146
146
  "future": "+{0} h"
147
147
  },
148
148
  "minute": {
149
- "current": "this minute",
149
+ "current": "ngalo mzuzu",
150
150
  "past": "-{0} min",
151
151
  "future": "+{0} min"
152
152
  },
153
153
  "second": {
154
- "current": "now",
154
+ "current": "ngoku",
155
155
  "past": "-{0} s",
156
156
  "future": "+{0} s"
157
157
  }
package/locale/xh.json.js CHANGED
@@ -9,9 +9,9 @@ export default {
9
9
  "future": "+{0} y"
10
10
  },
11
11
  "quarter": {
12
- "previous": "last quarter",
13
- "current": "this quarter",
14
- "next": "next quarter",
12
+ "previous": "ikota edlulileyo",
13
+ "current": "ikota esikuyo",
14
+ "next": "ikota elandelayp",
15
15
  "past": "-{0} Q",
16
16
  "future": "+{0} Q"
17
17
  },
@@ -37,17 +37,17 @@ export default {
37
37
  "future": "+{0} d"
38
38
  },
39
39
  "hour": {
40
- "current": "this hour",
40
+ "current": "ngale yure",
41
41
  "past": "-{0} h",
42
42
  "future": "+{0} h"
43
43
  },
44
44
  "minute": {
45
- "current": "this minute",
45
+ "current": "ngalo mzuzu",
46
46
  "past": "-{0} min",
47
47
  "future": "+{0} min"
48
48
  },
49
49
  "second": {
50
- "current": "now",
50
+ "current": "ngoku",
51
51
  "past": "-{0} s",
52
52
  "future": "+{0} s"
53
53
  }
@@ -61,9 +61,9 @@ export default {
61
61
  "future": "+{0} y"
62
62
  },
63
63
  "quarter": {
64
- "previous": "last quarter",
65
- "current": "this quarter",
66
- "next": "next quarter",
64
+ "previous": "ikota edlulileyo",
65
+ "current": "ikota esikuyo",
66
+ "next": "ikota elandelayp",
67
67
  "past": "-{0} Q",
68
68
  "future": "+{0} Q"
69
69
  },
@@ -89,17 +89,17 @@ export default {
89
89
  "future": "+{0} d"
90
90
  },
91
91
  "hour": {
92
- "current": "this hour",
92
+ "current": "ngale yure",
93
93
  "past": "-{0} h",
94
94
  "future": "+{0} h"
95
95
  },
96
96
  "minute": {
97
- "current": "this minute",
97
+ "current": "ngalo mzuzu",
98
98
  "past": "-{0} min",
99
99
  "future": "+{0} min"
100
100
  },
101
101
  "second": {
102
- "current": "now",
102
+ "current": "ngoku",
103
103
  "past": "-{0} s",
104
104
  "future": "+{0} s"
105
105
  }
@@ -113,9 +113,9 @@ export default {
113
113
  "future": "+{0} y"
114
114
  },
115
115
  "quarter": {
116
- "previous": "last quarter",
117
- "current": "this quarter",
118
- "next": "next quarter",
116
+ "previous": "ikota edlulileyo",
117
+ "current": "ikota esikuyo",
118
+ "next": "ikota elandelayp",
119
119
  "past": "-{0} Q",
120
120
  "future": "+{0} Q"
121
121
  },
@@ -141,17 +141,17 @@ export default {
141
141
  "future": "+{0} d"
142
142
  },
143
143
  "hour": {
144
- "current": "this hour",
144
+ "current": "ngale yure",
145
145
  "past": "-{0} h",
146
146
  "future": "+{0} h"
147
147
  },
148
148
  "minute": {
149
- "current": "this minute",
149
+ "current": "ngalo mzuzu",
150
150
  "past": "-{0} min",
151
151
  "future": "+{0} min"
152
152
  },
153
153
  "second": {
154
- "current": "now",
154
+ "current": "ngoku",
155
155
  "past": "-{0} s",
156
156
  "future": "+{0} s"
157
157
  }
@@ -1,3 +1,5 @@
1
+ import { describe, it } from 'mocha';
2
+ import { expect } from 'chai';
1
3
  import FullDateFormatter, { FallbackDateFormatter } from './FullDateFormatter.js';
2
4
  describe('FullDateFormatter', function () {
3
5
  it('should format full date', function () {
@@ -1 +1 @@
1
- {"version":3,"file":"FullDateFormatter.test.js","names":["FullDateFormatter","FallbackDateFormatter","describe","it","formatter","expect","format","Date","UTC","to","equal","include"],"sources":["../source/FullDateFormatter.test.js"],"sourcesContent":["import FullDateFormatter, { FallbackDateFormatter } from './FullDateFormatter.js'\r\n\r\ndescribe('FullDateFormatter', () => {\r\n\tit('should format full date', () => {\r\n\t\tconst formatter = new FullDateFormatter('en')\r\n\t\texpect(\r\n\t\t\tformatter.format(new Date(Date.UTC(2000, 0, 1)))\r\n\t\t).to.equal('Saturday, January 1, 2000 at 3:00:00 AM')\r\n\t})\r\n\r\n\tit('should format full date (`locales` argument)', () => {\r\n\t\tconst formatter = new FullDateFormatter(['en', 'ru'])\r\n\t\texpect(\r\n\t\t\tformatter.format(new Date(Date.UTC(2000, 0, 1)))\r\n\t\t).to.equal('Saturday, January 1, 2000 at 3:00:00 AM')\r\n\t})\r\n\r\n\tit('should format full date (timestamp)', () => {\r\n\t\tconst formatter = new FullDateFormatter('en')\r\n\t\texpect(\r\n\t\t\tformatter.format(Date.UTC(2000, 0, 1))\r\n\t\t).to.equal('Saturday, January 1, 2000 at 3:00:00 AM')\r\n\t})\r\n\r\n\tit('should fallback to non-`Intl` formatter', () => {\r\n\t\tconst formatter = new FallbackDateFormatter('en')\r\n\t\t// The output depends on the user's time zone.\r\n\t\t// Example when running in Moscow: \"Sat Jan 01 2000 03:00:00 GMT+0300 (Moscow Standard Time)\".\r\n\t\texpect(\r\n\t\t\tformatter.format(new Date(Date.UTC(2000, 1, 1)))\r\n\t\t).to.include(':00:00 GMT')\r\n\t})\r\n})"],"mappings":"AAAA,OAAOA,iBAAiB,IAAIC,qBAAqB,QAAQ,wBAAwB;AAEjFC,QAAQ,CAAC,mBAAmB,EAAE,YAAM;EACnCC,EAAE,CAAC,yBAAyB,EAAE,YAAM;IACnC,IAAMC,SAAS,GAAG,IAAIJ,iBAAiB,CAAC,IAAI,CAAC;IAC7CK,MAAM,CACLD,SAAS,CAACE,MAAM,CAAC,IAAIC,IAAI,CAACA,IAAI,CAACC,GAAG,CAAC,IAAI,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC,CAChD,CAAC,CAACC,EAAE,CAACC,KAAK,CAAC,yCAAyC,CAAC;EACtD,CAAC,CAAC;EAEFP,EAAE,CAAC,8CAA8C,EAAE,YAAM;IACxD,IAAMC,SAAS,GAAG,IAAIJ,iBAAiB,CAAC,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC;IACrDK,MAAM,CACLD,SAAS,CAACE,MAAM,CAAC,IAAIC,IAAI,CAACA,IAAI,CAACC,GAAG,CAAC,IAAI,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC,CAChD,CAAC,CAACC,EAAE,CAACC,KAAK,CAAC,yCAAyC,CAAC;EACtD,CAAC,CAAC;EAEFP,EAAE,CAAC,qCAAqC,EAAE,YAAM;IAC/C,IAAMC,SAAS,GAAG,IAAIJ,iBAAiB,CAAC,IAAI,CAAC;IAC7CK,MAAM,CACLD,SAAS,CAACE,MAAM,CAACC,IAAI,CAACC,GAAG,CAAC,IAAI,EAAE,CAAC,EAAE,CAAC,CAAC,CACtC,CAAC,CAACC,EAAE,CAACC,KAAK,CAAC,yCAAyC,CAAC;EACtD,CAAC,CAAC;EAEFP,EAAE,CAAC,yCAAyC,EAAE,YAAM;IACnD,IAAMC,SAAS,GAAG,IAAIH,qBAAqB,CAAC,IAAI,CAAC;IACjD;IACA;IACAI,MAAM,CACLD,SAAS,CAACE,MAAM,CAAC,IAAIC,IAAI,CAACA,IAAI,CAACC,GAAG,CAAC,IAAI,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC,CAChD,CAAC,CAACC,EAAE,CAACE,OAAO,CAAC,YAAY,CAAC;EAC3B,CAAC,CAAC;AACH,CAAC,CAAC","ignoreList":[]}
1
+ {"version":3,"file":"FullDateFormatter.test.js","names":["describe","it","expect","FullDateFormatter","FallbackDateFormatter","formatter","format","Date","UTC","to","equal","include"],"sources":["../source/FullDateFormatter.test.js"],"sourcesContent":["import { describe, it } from 'mocha'\r\nimport { expect } from 'chai'\r\n\r\nimport FullDateFormatter, { FallbackDateFormatter } from './FullDateFormatter.js'\r\n\r\ndescribe('FullDateFormatter', () => {\r\n\tit('should format full date', () => {\r\n\t\tconst formatter = new FullDateFormatter('en')\r\n\t\texpect(\r\n\t\t\tformatter.format(new Date(Date.UTC(2000, 0, 1)))\r\n\t\t).to.equal('Saturday, January 1, 2000 at 3:00:00 AM')\r\n\t})\r\n\r\n\tit('should format full date (`locales` argument)', () => {\r\n\t\tconst formatter = new FullDateFormatter(['en', 'ru'])\r\n\t\texpect(\r\n\t\t\tformatter.format(new Date(Date.UTC(2000, 0, 1)))\r\n\t\t).to.equal('Saturday, January 1, 2000 at 3:00:00 AM')\r\n\t})\r\n\r\n\tit('should format full date (timestamp)', () => {\r\n\t\tconst formatter = new FullDateFormatter('en')\r\n\t\texpect(\r\n\t\t\tformatter.format(Date.UTC(2000, 0, 1))\r\n\t\t).to.equal('Saturday, January 1, 2000 at 3:00:00 AM')\r\n\t})\r\n\r\n\tit('should fallback to non-`Intl` formatter', () => {\r\n\t\tconst formatter = new FallbackDateFormatter('en')\r\n\t\t// The output depends on the user's time zone.\r\n\t\t// Example when running in Moscow: \"Sat Jan 01 2000 03:00:00 GMT+0300 (Moscow Standard Time)\".\r\n\t\texpect(\r\n\t\t\tformatter.format(new Date(Date.UTC(2000, 1, 1)))\r\n\t\t).to.include(':00:00 GMT')\r\n\t})\r\n})"],"mappings":"AAAA,SAASA,QAAQ,EAAEC,EAAE,QAAQ,OAAO;AACpC,SAASC,MAAM,QAAQ,MAAM;AAE7B,OAAOC,iBAAiB,IAAIC,qBAAqB,QAAQ,wBAAwB;AAEjFJ,QAAQ,CAAC,mBAAmB,EAAE,YAAM;EACnCC,EAAE,CAAC,yBAAyB,EAAE,YAAM;IACnC,IAAMI,SAAS,GAAG,IAAIF,iBAAiB,CAAC,IAAI,CAAC;IAC7CD,MAAM,CACLG,SAAS,CAACC,MAAM,CAAC,IAAIC,IAAI,CAACA,IAAI,CAACC,GAAG,CAAC,IAAI,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC,CAChD,CAAC,CAACC,EAAE,CAACC,KAAK,CAAC,yCAAyC,CAAC;EACtD,CAAC,CAAC;EAEFT,EAAE,CAAC,8CAA8C,EAAE,YAAM;IACxD,IAAMI,SAAS,GAAG,IAAIF,iBAAiB,CAAC,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC;IACrDD,MAAM,CACLG,SAAS,CAACC,MAAM,CAAC,IAAIC,IAAI,CAACA,IAAI,CAACC,GAAG,CAAC,IAAI,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC,CAChD,CAAC,CAACC,EAAE,CAACC,KAAK,CAAC,yCAAyC,CAAC;EACtD,CAAC,CAAC;EAEFT,EAAE,CAAC,qCAAqC,EAAE,YAAM;IAC/C,IAAMI,SAAS,GAAG,IAAIF,iBAAiB,CAAC,IAAI,CAAC;IAC7CD,MAAM,CACLG,SAAS,CAACC,MAAM,CAACC,IAAI,CAACC,GAAG,CAAC,IAAI,EAAE,CAAC,EAAE,CAAC,CAAC,CACtC,CAAC,CAACC,EAAE,CAACC,KAAK,CAAC,yCAAyC,CAAC;EACtD,CAAC,CAAC;EAEFT,EAAE,CAAC,yCAAyC,EAAE,YAAM;IACnD,IAAMI,SAAS,GAAG,IAAID,qBAAqB,CAAC,IAAI,CAAC;IACjD;IACA;IACAF,MAAM,CACLG,SAAS,CAACC,MAAM,CAAC,IAAIC,IAAI,CAACA,IAAI,CAACC,GAAG,CAAC,IAAI,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC,CAChD,CAAC,CAACC,EAAE,CAACE,OAAO,CAAC,YAAY,CAAC;EAC3B,CAAC,CAAC;AACH,CAAC,CAAC","ignoreList":[]}
@@ -236,12 +236,15 @@ var TimeAgo = /*#__PURE__*/function () {
236
236
  // when the delay is longer than about `24.85` days.
237
237
  // https://stackoverflow.com/questions/3468607/why-does-settimeout-break-for-large-millisecond-delay-values
238
238
  //
239
- // To not burden the end user of this library with manually working around that bug,
240
- // this library automatically caps the returned delay to a maximum value that
241
- // still works with `setTimeout()` and doesn't break it.
239
+ // In order to not burden the end users of this library with manually working around that bug,
240
+ // this library automatically caps the returned delay to a maximum value of about `24.85` days
241
+ // which still works correctly with `setTimeout()` function and doesn't break it.
242
242
  //
243
- // The end user of this library could still opt out of this auto-workaround feature
244
- // by passing a `getTimeToNextUpdateUncapped: true` option.
243
+ // The end user of this library could still disable this automatic workaround
244
+ // by passing a `getTimeToNextUpdateUncapped: true` parameter.
245
+ // In that case, it will return the original non-modified uncapped delay
246
+ // which can be longer than `24.85` days and should be manually capped
247
+ // by the developer if it's going to be used in a `setTimeout()` call.
245
248
  //
246
249
  if (options.getTimeToNextUpdateUncapped) {
247
250
  return timeToNextUpdate;