@gobrand/tiempo 2.2.3 → 2.3.1

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 (260) hide show
  1. package/README.md +297 -24
  2. package/dist/addDays.d.ts +37 -0
  3. package/dist/addDays.d.ts.map +1 -0
  4. package/dist/addDays.js +8 -0
  5. package/dist/addDays.js.map +1 -0
  6. package/dist/addDays.test.d.ts +2 -0
  7. package/dist/addDays.test.d.ts.map +1 -0
  8. package/dist/addHours.d.ts +37 -0
  9. package/dist/addHours.d.ts.map +1 -0
  10. package/dist/addHours.js +8 -0
  11. package/dist/addHours.js.map +1 -0
  12. package/dist/addHours.test.d.ts +2 -0
  13. package/dist/addHours.test.d.ts.map +1 -0
  14. package/dist/addMicroseconds.d.ts +36 -0
  15. package/dist/addMicroseconds.d.ts.map +1 -0
  16. package/dist/addMicroseconds.js +8 -0
  17. package/dist/addMicroseconds.js.map +1 -0
  18. package/dist/addMicroseconds.test.d.ts +2 -0
  19. package/dist/addMicroseconds.test.d.ts.map +1 -0
  20. package/dist/addMilliseconds.d.ts +36 -0
  21. package/dist/addMilliseconds.d.ts.map +1 -0
  22. package/dist/addMilliseconds.js +8 -0
  23. package/dist/addMilliseconds.js.map +1 -0
  24. package/dist/addMilliseconds.test.d.ts +2 -0
  25. package/dist/addMilliseconds.test.d.ts.map +1 -0
  26. package/dist/addMinutes.d.ts +36 -0
  27. package/dist/addMinutes.d.ts.map +1 -0
  28. package/dist/addMinutes.js +8 -0
  29. package/dist/addMinutes.js.map +1 -0
  30. package/dist/addMinutes.test.d.ts +2 -0
  31. package/dist/addMinutes.test.d.ts.map +1 -0
  32. package/dist/addMonths.d.ts +37 -0
  33. package/dist/addMonths.d.ts.map +1 -0
  34. package/dist/addMonths.js +8 -0
  35. package/dist/addMonths.js.map +1 -0
  36. package/dist/addMonths.test.d.ts +2 -0
  37. package/dist/addMonths.test.d.ts.map +1 -0
  38. package/dist/addNanoseconds.d.ts +36 -0
  39. package/dist/addNanoseconds.d.ts.map +1 -0
  40. package/dist/addNanoseconds.js +8 -0
  41. package/dist/addNanoseconds.js.map +1 -0
  42. package/dist/addNanoseconds.test.d.ts +2 -0
  43. package/dist/addNanoseconds.test.d.ts.map +1 -0
  44. package/dist/addSeconds.d.ts +36 -0
  45. package/dist/addSeconds.d.ts.map +1 -0
  46. package/dist/addSeconds.js +8 -0
  47. package/dist/addSeconds.js.map +1 -0
  48. package/dist/addSeconds.test.d.ts +2 -0
  49. package/dist/addSeconds.test.d.ts.map +1 -0
  50. package/dist/addWeeks.d.ts +37 -0
  51. package/dist/addWeeks.d.ts.map +1 -0
  52. package/dist/addWeeks.js +8 -0
  53. package/dist/addWeeks.js.map +1 -0
  54. package/dist/addWeeks.test.d.ts +2 -0
  55. package/dist/addWeeks.test.d.ts.map +1 -0
  56. package/dist/addYears.d.ts +37 -0
  57. package/dist/addYears.d.ts.map +1 -0
  58. package/dist/addYears.js +8 -0
  59. package/dist/addYears.js.map +1 -0
  60. package/dist/addYears.test.d.ts +2 -0
  61. package/dist/addYears.test.d.ts.map +1 -0
  62. package/dist/{chunk-KD5GEHUA.js → chunk-2MP3ESL7.js} +4 -1
  63. package/dist/chunk-2MP3ESL7.js.map +1 -0
  64. package/dist/chunk-2XHAHSB6.js +14 -0
  65. package/dist/chunk-2XHAHSB6.js.map +1 -0
  66. package/dist/chunk-4NJMCCUM.js +14 -0
  67. package/dist/chunk-4NJMCCUM.js.map +1 -0
  68. package/dist/chunk-52NEOY34.js +13 -0
  69. package/dist/chunk-52NEOY34.js.map +1 -0
  70. package/dist/chunk-7ATM7AXL.js +14 -0
  71. package/dist/chunk-7ATM7AXL.js.map +1 -0
  72. package/dist/chunk-A5VVBYNT.js +14 -0
  73. package/dist/chunk-A5VVBYNT.js.map +1 -0
  74. package/dist/chunk-ADQTZVMH.js +15 -0
  75. package/dist/chunk-ADQTZVMH.js.map +1 -0
  76. package/dist/chunk-AHMKY474.js +13 -0
  77. package/dist/chunk-AHMKY474.js.map +1 -0
  78. package/dist/chunk-BH2YB4MV.js +13 -0
  79. package/dist/chunk-BH2YB4MV.js.map +1 -0
  80. package/dist/chunk-BQBLSXK2.js +13 -0
  81. package/dist/chunk-BQBLSXK2.js.map +1 -0
  82. package/dist/{chunk-GPAFAHKJ.js → chunk-BW5SFCKS.js} +4 -1
  83. package/dist/chunk-BW5SFCKS.js.map +1 -0
  84. package/dist/chunk-CY746ZUQ.js +15 -0
  85. package/dist/chunk-CY746ZUQ.js.map +1 -0
  86. package/dist/chunk-DT2EWLHU.js +14 -0
  87. package/dist/chunk-DT2EWLHU.js.map +1 -0
  88. package/dist/chunk-EEQ3REET.js +15 -0
  89. package/dist/chunk-EEQ3REET.js.map +1 -0
  90. package/dist/chunk-EYO2ZJLH.js +14 -0
  91. package/dist/chunk-EYO2ZJLH.js.map +1 -0
  92. package/dist/chunk-HDBH7RTY.js +13 -0
  93. package/dist/chunk-HDBH7RTY.js.map +1 -0
  94. package/dist/chunk-ISHZRFVN.js +15 -0
  95. package/dist/chunk-ISHZRFVN.js.map +1 -0
  96. package/dist/chunk-J6G2I2TU.js +13 -0
  97. package/dist/chunk-J6G2I2TU.js.map +1 -0
  98. package/dist/chunk-JOD4ATPE.js +15 -0
  99. package/dist/chunk-JOD4ATPE.js.map +1 -0
  100. package/dist/chunk-L4SVABDH.js +14 -0
  101. package/dist/chunk-L4SVABDH.js.map +1 -0
  102. package/dist/chunk-LDO6PRNJ.js +15 -0
  103. package/dist/chunk-LDO6PRNJ.js.map +1 -0
  104. package/dist/chunk-NRD5HRZV.js +14 -0
  105. package/dist/chunk-NRD5HRZV.js.map +1 -0
  106. package/dist/chunk-PPB62JYV.js +15 -0
  107. package/dist/chunk-PPB62JYV.js.map +1 -0
  108. package/dist/chunk-Q2F3HEXB.js +14 -0
  109. package/dist/chunk-Q2F3HEXB.js.map +1 -0
  110. package/dist/chunk-S63QUP4W.js +15 -0
  111. package/dist/chunk-S63QUP4W.js.map +1 -0
  112. package/dist/chunk-TGKWBQ7L.js +13 -0
  113. package/dist/chunk-TGKWBQ7L.js.map +1 -0
  114. package/dist/chunk-U4RNUZXO.js +13 -0
  115. package/dist/chunk-U4RNUZXO.js.map +1 -0
  116. package/dist/chunk-V27NUBXQ.js +14 -0
  117. package/dist/chunk-V27NUBXQ.js.map +1 -0
  118. package/dist/chunk-VLZ3HQQA.js +15 -0
  119. package/dist/chunk-VLZ3HQQA.js.map +1 -0
  120. package/dist/chunk-WVHAYLBW.js +13 -0
  121. package/dist/chunk-WVHAYLBW.js.map +1 -0
  122. package/dist/{chunk-NL5LWPJI.js → chunk-XEDXPI5G.js} +4 -4
  123. package/dist/chunk-XW5MLXX5.js +13 -0
  124. package/dist/chunk-XW5MLXX5.js.map +1 -0
  125. package/dist/chunk-YKBP3G7L.js +13 -0
  126. package/dist/chunk-YKBP3G7L.js.map +1 -0
  127. package/dist/index.d.ts +30 -0
  128. package/dist/index.d.ts.map +1 -1
  129. package/dist/index.js +139 -19
  130. package/dist/intlFormatDistance.js +2 -2
  131. package/dist/isSameHour.d.ts +58 -0
  132. package/dist/isSameHour.d.ts.map +1 -0
  133. package/dist/isSameHour.js +8 -0
  134. package/dist/isSameHour.js.map +1 -0
  135. package/dist/isSameHour.test.d.ts +2 -0
  136. package/dist/isSameHour.test.d.ts.map +1 -0
  137. package/dist/isSameMicrosecond.d.ts +59 -0
  138. package/dist/isSameMicrosecond.d.ts.map +1 -0
  139. package/dist/isSameMicrosecond.js +8 -0
  140. package/dist/isSameMicrosecond.js.map +1 -0
  141. package/dist/isSameMicrosecond.test.d.ts +2 -0
  142. package/dist/isSameMicrosecond.test.d.ts.map +1 -0
  143. package/dist/isSameMillisecond.d.ts +59 -0
  144. package/dist/isSameMillisecond.d.ts.map +1 -0
  145. package/dist/isSameMillisecond.js +8 -0
  146. package/dist/isSameMillisecond.js.map +1 -0
  147. package/dist/isSameMillisecond.test.d.ts +2 -0
  148. package/dist/isSameMillisecond.test.d.ts.map +1 -0
  149. package/dist/isSameMinute.d.ts +58 -0
  150. package/dist/isSameMinute.d.ts.map +1 -0
  151. package/dist/isSameMinute.js +8 -0
  152. package/dist/isSameMinute.js.map +1 -0
  153. package/dist/isSameMinute.test.d.ts +2 -0
  154. package/dist/isSameMinute.test.d.ts.map +1 -0
  155. package/dist/isSameMonth.d.ts +58 -0
  156. package/dist/isSameMonth.d.ts.map +1 -0
  157. package/dist/isSameMonth.js +8 -0
  158. package/dist/isSameMonth.js.map +1 -0
  159. package/dist/isSameMonth.test.d.ts +2 -0
  160. package/dist/isSameMonth.test.d.ts.map +1 -0
  161. package/dist/isSameNanosecond.d.ts +59 -0
  162. package/dist/isSameNanosecond.d.ts.map +1 -0
  163. package/dist/isSameNanosecond.js +8 -0
  164. package/dist/isSameNanosecond.js.map +1 -0
  165. package/dist/isSameNanosecond.test.d.ts +2 -0
  166. package/dist/isSameNanosecond.test.d.ts.map +1 -0
  167. package/dist/isSameSecond.d.ts +59 -0
  168. package/dist/isSameSecond.d.ts.map +1 -0
  169. package/dist/isSameSecond.js +8 -0
  170. package/dist/isSameSecond.js.map +1 -0
  171. package/dist/isSameSecond.test.d.ts +2 -0
  172. package/dist/isSameSecond.test.d.ts.map +1 -0
  173. package/dist/isSameWeek.d.ts +72 -0
  174. package/dist/isSameWeek.d.ts.map +1 -0
  175. package/dist/isSameWeek.js +8 -0
  176. package/dist/isSameWeek.js.map +1 -0
  177. package/dist/isSameWeek.test.d.ts +2 -0
  178. package/dist/isSameWeek.test.d.ts.map +1 -0
  179. package/dist/isSameYear.d.ts +58 -0
  180. package/dist/isSameYear.d.ts.map +1 -0
  181. package/dist/isSameYear.js +8 -0
  182. package/dist/isSameYear.js.map +1 -0
  183. package/dist/isSameYear.test.d.ts +2 -0
  184. package/dist/isSameYear.test.d.ts.map +1 -0
  185. package/dist/subDays.d.ts +20 -0
  186. package/dist/subDays.d.ts.map +1 -0
  187. package/dist/subDays.js +9 -0
  188. package/dist/subDays.js.map +1 -0
  189. package/dist/subDays.test.d.ts +2 -0
  190. package/dist/subDays.test.d.ts.map +1 -0
  191. package/dist/subHours.d.ts +20 -0
  192. package/dist/subHours.d.ts.map +1 -0
  193. package/dist/subHours.js +9 -0
  194. package/dist/subHours.js.map +1 -0
  195. package/dist/subHours.test.d.ts +2 -0
  196. package/dist/subHours.test.d.ts.map +1 -0
  197. package/dist/subMicroseconds.d.ts +19 -0
  198. package/dist/subMicroseconds.d.ts.map +1 -0
  199. package/dist/subMicroseconds.js +9 -0
  200. package/dist/subMicroseconds.js.map +1 -0
  201. package/dist/subMicroseconds.test.d.ts +2 -0
  202. package/dist/subMicroseconds.test.d.ts.map +1 -0
  203. package/dist/subMilliseconds.d.ts +19 -0
  204. package/dist/subMilliseconds.d.ts.map +1 -0
  205. package/dist/subMilliseconds.js +9 -0
  206. package/dist/subMilliseconds.js.map +1 -0
  207. package/dist/subMilliseconds.test.d.ts +2 -0
  208. package/dist/subMilliseconds.test.d.ts.map +1 -0
  209. package/dist/subMinutes.d.ts +19 -0
  210. package/dist/subMinutes.d.ts.map +1 -0
  211. package/dist/subMinutes.js +9 -0
  212. package/dist/subMinutes.js.map +1 -0
  213. package/dist/subMinutes.test.d.ts +2 -0
  214. package/dist/subMinutes.test.d.ts.map +1 -0
  215. package/dist/subMonths.d.ts +20 -0
  216. package/dist/subMonths.d.ts.map +1 -0
  217. package/dist/subMonths.js +9 -0
  218. package/dist/subMonths.js.map +1 -0
  219. package/dist/subMonths.test.d.ts +2 -0
  220. package/dist/subMonths.test.d.ts.map +1 -0
  221. package/dist/subNanoseconds.d.ts +19 -0
  222. package/dist/subNanoseconds.d.ts.map +1 -0
  223. package/dist/subNanoseconds.js +9 -0
  224. package/dist/subNanoseconds.js.map +1 -0
  225. package/dist/subNanoseconds.test.d.ts +2 -0
  226. package/dist/subNanoseconds.test.d.ts.map +1 -0
  227. package/dist/subSeconds.d.ts +19 -0
  228. package/dist/subSeconds.d.ts.map +1 -0
  229. package/dist/subSeconds.js +9 -0
  230. package/dist/subSeconds.js.map +1 -0
  231. package/dist/subSeconds.test.d.ts +2 -0
  232. package/dist/subSeconds.test.d.ts.map +1 -0
  233. package/dist/subWeeks.d.ts +20 -0
  234. package/dist/subWeeks.d.ts.map +1 -0
  235. package/dist/subWeeks.js +9 -0
  236. package/dist/subWeeks.js.map +1 -0
  237. package/dist/subWeeks.test.d.ts +2 -0
  238. package/dist/subWeeks.test.d.ts.map +1 -0
  239. package/dist/subYears.d.ts +20 -0
  240. package/dist/subYears.d.ts.map +1 -0
  241. package/dist/subYears.js +9 -0
  242. package/dist/subYears.js.map +1 -0
  243. package/dist/subYears.test.d.ts +2 -0
  244. package/dist/subYears.test.d.ts.map +1 -0
  245. package/dist/toDate.d.ts +27 -0
  246. package/dist/toDate.d.ts.map +1 -0
  247. package/dist/toDate.js +7 -0
  248. package/dist/toDate.js.map +1 -0
  249. package/dist/toDate.test.d.ts +2 -0
  250. package/dist/toDate.test.d.ts.map +1 -0
  251. package/dist/toUtc.d.ts +9 -5
  252. package/dist/toUtc.d.ts.map +1 -1
  253. package/dist/toUtc.js +1 -1
  254. package/dist/toZonedTime.d.ts +8 -4
  255. package/dist/toZonedTime.d.ts.map +1 -1
  256. package/dist/toZonedTime.js +1 -1
  257. package/package.json +1 -1
  258. package/dist/chunk-GPAFAHKJ.js.map +0 -1
  259. package/dist/chunk-KD5GEHUA.js.map +0 -1
  260. /package/dist/{chunk-NL5LWPJI.js.map → chunk-XEDXPI5G.js.map} +0 -0
package/dist/index.js CHANGED
@@ -1,3 +1,51 @@
1
+ import {
2
+ toDate
3
+ } from "./chunk-TGKWBQ7L.js";
4
+ import {
5
+ toUtc
6
+ } from "./chunk-BW5SFCKS.js";
7
+ import {
8
+ toUtcString
9
+ } from "./chunk-DMKGJY4N.js";
10
+ import {
11
+ toZonedTime
12
+ } from "./chunk-2MP3ESL7.js";
13
+ import {
14
+ today
15
+ } from "./chunk-67QHALIG.js";
16
+ import {
17
+ subMicroseconds
18
+ } from "./chunk-BQBLSXK2.js";
19
+ import {
20
+ subMilliseconds
21
+ } from "./chunk-HDBH7RTY.js";
22
+ import {
23
+ subMinutes
24
+ } from "./chunk-J6G2I2TU.js";
25
+ import {
26
+ subMonths
27
+ } from "./chunk-52NEOY34.js";
28
+ import {
29
+ subNanoseconds
30
+ } from "./chunk-WVHAYLBW.js";
31
+ import {
32
+ subSeconds
33
+ } from "./chunk-BH2YB4MV.js";
34
+ import {
35
+ subWeeks
36
+ } from "./chunk-U4RNUZXO.js";
37
+ import {
38
+ subYears
39
+ } from "./chunk-AHMKY474.js";
40
+ import {
41
+ isSameYear
42
+ } from "./chunk-VLZ3HQQA.js";
43
+ import {
44
+ now
45
+ } from "./chunk-3YGPHHB6.js";
46
+ import {
47
+ startOfDay
48
+ } from "./chunk-TW5EV3DH.js";
1
49
  import {
2
50
  startOfMonth
3
51
  } from "./chunk-TU2UNOOW.js";
@@ -8,20 +56,41 @@ import {
8
56
  startOfYear
9
57
  } from "./chunk-YR2UCUIT.js";
10
58
  import {
11
- toUtc
12
- } from "./chunk-GPAFAHKJ.js";
59
+ subDays
60
+ } from "./chunk-YKBP3G7L.js";
13
61
  import {
14
- toUtcString
15
- } from "./chunk-DMKGJY4N.js";
62
+ subHours
63
+ } from "./chunk-XW5MLXX5.js";
16
64
  import {
17
- toZonedTime
18
- } from "./chunk-KD5GEHUA.js";
65
+ isSameHour
66
+ } from "./chunk-EEQ3REET.js";
19
67
  import {
20
- today
21
- } from "./chunk-67QHALIG.js";
68
+ isSameMicrosecond
69
+ } from "./chunk-PPB62JYV.js";
70
+ import {
71
+ isSameMillisecond
72
+ } from "./chunk-ISHZRFVN.js";
73
+ import {
74
+ isSameMinute
75
+ } from "./chunk-LDO6PRNJ.js";
76
+ import {
77
+ isSameMonth
78
+ } from "./chunk-ADQTZVMH.js";
79
+ import {
80
+ isSameNanosecond
81
+ } from "./chunk-S63QUP4W.js";
82
+ import {
83
+ isSameSecond
84
+ } from "./chunk-CY746ZUQ.js";
85
+ import {
86
+ isSameWeek
87
+ } from "./chunk-JOD4ATPE.js";
88
+ import {
89
+ format
90
+ } from "./chunk-2G5RJGPR.js";
22
91
  import {
23
92
  intlFormatDistance
24
- } from "./chunk-NL5LWPJI.js";
93
+ } from "./chunk-XEDXPI5G.js";
25
94
  import {
26
95
  isAfter
27
96
  } from "./chunk-BBNNR2QH.js";
@@ -38,11 +107,11 @@ import {
38
107
  isSameDay
39
108
  } from "./chunk-RW3C2677.js";
40
109
  import {
41
- now
42
- } from "./chunk-3YGPHHB6.js";
110
+ differenceInNanoseconds
111
+ } from "./chunk-OABS374T.js";
43
112
  import {
44
- startOfDay
45
- } from "./chunk-TW5EV3DH.js";
113
+ differenceInSeconds
114
+ } from "./chunk-ZHRMURYP.js";
46
115
  import {
47
116
  differenceInWeeks
48
117
  } from "./chunk-PVAOUYXF.js";
@@ -63,8 +132,11 @@ import {
63
132
  } from "./chunk-XDVUGTUV.js";
64
133
  import "./chunk-AVGNRINZ.js";
65
134
  import {
66
- format
67
- } from "./chunk-2G5RJGPR.js";
135
+ addWeeks
136
+ } from "./chunk-DT2EWLHU.js";
137
+ import {
138
+ addYears
139
+ } from "./chunk-Q2F3HEXB.js";
68
140
  import {
69
141
  differenceInDays
70
142
  } from "./chunk-6IP245MS.js";
@@ -84,13 +156,41 @@ import {
84
156
  differenceInMonths
85
157
  } from "./chunk-BIAPE4MR.js";
86
158
  import {
87
- differenceInNanoseconds
88
- } from "./chunk-OABS374T.js";
159
+ addDays
160
+ } from "./chunk-L4SVABDH.js";
89
161
  import {
90
- differenceInSeconds
91
- } from "./chunk-ZHRMURYP.js";
162
+ addHours
163
+ } from "./chunk-4NJMCCUM.js";
164
+ import {
165
+ addMicroseconds
166
+ } from "./chunk-V27NUBXQ.js";
167
+ import {
168
+ addMilliseconds
169
+ } from "./chunk-A5VVBYNT.js";
170
+ import {
171
+ addMinutes
172
+ } from "./chunk-2XHAHSB6.js";
173
+ import {
174
+ addMonths
175
+ } from "./chunk-7ATM7AXL.js";
176
+ import {
177
+ addNanoseconds
178
+ } from "./chunk-EYO2ZJLH.js";
179
+ import {
180
+ addSeconds
181
+ } from "./chunk-NRD5HRZV.js";
92
182
  import "./chunk-MJSZNWCV.js";
93
183
  export {
184
+ addDays,
185
+ addHours,
186
+ addMicroseconds,
187
+ addMilliseconds,
188
+ addMinutes,
189
+ addMonths,
190
+ addNanoseconds,
191
+ addSeconds,
192
+ addWeeks,
193
+ addYears,
94
194
  differenceInDays,
95
195
  differenceInHours,
96
196
  differenceInMicroseconds,
@@ -112,11 +212,31 @@ export {
112
212
  isFuture,
113
213
  isPast,
114
214
  isSameDay,
215
+ isSameHour,
216
+ isSameMicrosecond,
217
+ isSameMillisecond,
218
+ isSameMinute,
219
+ isSameMonth,
220
+ isSameNanosecond,
221
+ isSameSecond,
222
+ isSameWeek,
223
+ isSameYear,
115
224
  now,
116
225
  startOfDay,
117
226
  startOfMonth,
118
227
  startOfWeek,
119
228
  startOfYear,
229
+ subDays,
230
+ subHours,
231
+ subMicroseconds,
232
+ subMilliseconds,
233
+ subMinutes,
234
+ subMonths,
235
+ subNanoseconds,
236
+ subSeconds,
237
+ subWeeks,
238
+ subYears,
239
+ toDate,
120
240
  toUtc,
121
241
  toUtcString,
122
242
  toZonedTime,
@@ -1,13 +1,13 @@
1
1
  import {
2
2
  intlFormatDistance
3
- } from "./chunk-NL5LWPJI.js";
3
+ } from "./chunk-XEDXPI5G.js";
4
+ import "./chunk-ZHRMURYP.js";
4
5
  import "./chunk-PVAOUYXF.js";
5
6
  import "./chunk-CHW2EN2O.js";
6
7
  import "./chunk-6IP245MS.js";
7
8
  import "./chunk-PIDXROVB.js";
8
9
  import "./chunk-RJY62CDU.js";
9
10
  import "./chunk-BIAPE4MR.js";
10
- import "./chunk-ZHRMURYP.js";
11
11
  import "./chunk-MJSZNWCV.js";
12
12
  export {
13
13
  intlFormatDistance
@@ -0,0 +1,58 @@
1
+ import type { Temporal } from '@js-temporal/polyfill';
2
+ /**
3
+ * Returns true if both datetimes fall in the same hour.
4
+ * Compares the year, month, day, and hour fields directly.
5
+ *
6
+ * Instant inputs are converted to UTC. For ZonedDateTime inputs, their
7
+ * timezone is preserved. Convert to a common timezone before calling if
8
+ * you need to compare from a specific perspective.
9
+ *
10
+ * @param date1 - First datetime (Instant or ZonedDateTime)
11
+ * @param date2 - Second datetime (Instant or ZonedDateTime)
12
+ * @returns true if both dates are in the same hour, false otherwise
13
+ *
14
+ * @example
15
+ * ```ts
16
+ * // Same timezone, same hour
17
+ * const start = Temporal.ZonedDateTime.from('2025-01-20T14:00:00Z[UTC]');
18
+ * const end = Temporal.ZonedDateTime.from('2025-01-20T14:59:59.999Z[UTC]');
19
+ *
20
+ * isSameHour(start, end); // true
21
+ * ```
22
+ *
23
+ * @example
24
+ * ```ts
25
+ * // Same timezone, different hours
26
+ * const hour14 = Temporal.ZonedDateTime.from('2025-01-20T14:59:59Z[UTC]');
27
+ * const hour15 = Temporal.ZonedDateTime.from('2025-01-20T15:00:00Z[UTC]');
28
+ *
29
+ * isSameHour(hour14, hour15); // false
30
+ * ```
31
+ *
32
+ * @example
33
+ * ```ts
34
+ * // Different timezones - compares their local hours
35
+ * const ny = Temporal.ZonedDateTime.from('2025-01-20T14:30:00-05:00[America/New_York]');
36
+ * const tokyo = Temporal.ZonedDateTime.from('2025-01-21T04:30:00+09:00[Asia/Tokyo]');
37
+ *
38
+ * // Same instant, different local hours from each person's perspective
39
+ * isSameHour(ny, tokyo); // false (14:xx in NY, 04:xx in Tokyo)
40
+ *
41
+ * // Convert to UTC to compare in UTC timezone
42
+ * isSameHour(ny.withTimeZone('UTC'), tokyo.withTimeZone('UTC')); // true (both 19:xx in UTC)
43
+ *
44
+ * // Convert to NY timezone to compare from NY perspective
45
+ * isSameHour(ny, tokyo.withTimeZone('America/New_York')); // true (both 14:xx in NY)
46
+ * ```
47
+ *
48
+ * @example
49
+ * ```ts
50
+ * // Instant inputs are converted to UTC
51
+ * const instant1 = Temporal.Instant.from('2025-01-20T14:15:30Z');
52
+ * const instant2 = Temporal.Instant.from('2025-01-20T14:45:50Z');
53
+ *
54
+ * isSameHour(instant1, instant2); // true (both 14:xx in UTC)
55
+ * ```
56
+ */
57
+ export declare function isSameHour(date1: Temporal.Instant | Temporal.ZonedDateTime, date2: Temporal.Instant | Temporal.ZonedDateTime): boolean;
58
+ //# sourceMappingURL=isSameHour.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"isSameHour.d.ts","sourceRoot":"","sources":["../src/isSameHour.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAGtD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAsDG;AACH,wBAAgB,UAAU,CACxB,KAAK,EAAE,QAAQ,CAAC,OAAO,GAAG,QAAQ,CAAC,aAAa,EAChD,KAAK,EAAE,QAAQ,CAAC,OAAO,GAAG,QAAQ,CAAC,aAAa,GAC/C,OAAO,CAUT"}
@@ -0,0 +1,8 @@
1
+ import {
2
+ isSameHour
3
+ } from "./chunk-EEQ3REET.js";
4
+ import "./chunk-MJSZNWCV.js";
5
+ export {
6
+ isSameHour
7
+ };
8
+ //# sourceMappingURL=isSameHour.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=isSameHour.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"isSameHour.test.d.ts","sourceRoot":"","sources":["../src/isSameHour.test.ts"],"names":[],"mappings":""}
@@ -0,0 +1,59 @@
1
+ import type { Temporal } from '@js-temporal/polyfill';
2
+ /**
3
+ * Returns true if both datetimes fall in the same microsecond.
4
+ * Compares the year, month, day, hour, minute, second, millisecond, and microsecond fields directly.
5
+ * Ignores sub-microsecond precision (nanoseconds).
6
+ *
7
+ * Instant inputs are converted to UTC. For ZonedDateTime inputs, their
8
+ * timezone is preserved. Convert to a common timezone before calling if
9
+ * you need to compare from a specific perspective.
10
+ *
11
+ * @param date1 - First datetime (Instant or ZonedDateTime)
12
+ * @param date2 - Second datetime (Instant or ZonedDateTime)
13
+ * @returns true if both dates are in the same microsecond, false otherwise
14
+ *
15
+ * @example
16
+ * ```ts
17
+ * // Same timezone, same microsecond
18
+ * const time1 = Temporal.ZonedDateTime.from('2025-01-20T14:30:45.123456Z[UTC]');
19
+ * const time2 = Temporal.ZonedDateTime.from('2025-01-20T14:30:45.123456999Z[UTC]');
20
+ *
21
+ * isSameMicrosecond(time1, time2); // true
22
+ * ```
23
+ *
24
+ * @example
25
+ * ```ts
26
+ * // Same timezone, different microseconds
27
+ * const us456 = Temporal.ZonedDateTime.from('2025-01-20T14:30:45.123456Z[UTC]');
28
+ * const us457 = Temporal.ZonedDateTime.from('2025-01-20T14:30:45.123457Z[UTC]');
29
+ *
30
+ * isSameMicrosecond(us456, us457); // false
31
+ * ```
32
+ *
33
+ * @example
34
+ * ```ts
35
+ * // Different timezones - compares their local microseconds
36
+ * const ny = Temporal.ZonedDateTime.from('2025-01-20T14:30:45.123456-05:00[America/New_York]');
37
+ * const tokyo = Temporal.ZonedDateTime.from('2025-01-21T04:30:45.987654+09:00[Asia/Tokyo]');
38
+ *
39
+ * // Same instant, different local microseconds from each person's perspective
40
+ * isSameMicrosecond(ny, tokyo); // false (14:30:45.123456 in NY, 04:30:45.987654 in Tokyo)
41
+ *
42
+ * // Convert to UTC to compare in UTC timezone
43
+ * isSameMicrosecond(ny.withTimeZone('UTC'), tokyo.withTimeZone('UTC')); // true (both 19:30:45.123456 in UTC)
44
+ *
45
+ * // Convert to NY timezone to compare from NY perspective
46
+ * isSameMicrosecond(ny, tokyo.withTimeZone('America/New_York')); // true (both 14:30:45.123456 in NY)
47
+ * ```
48
+ *
49
+ * @example
50
+ * ```ts
51
+ * // Instant inputs are converted to UTC
52
+ * const instant1 = Temporal.Instant.from('2025-01-20T14:30:45.123456789Z');
53
+ * const instant2 = Temporal.Instant.from('2025-01-20T14:30:45.123456999Z');
54
+ *
55
+ * isSameMicrosecond(instant1, instant2); // true (both 14:30:45.123456 in UTC)
56
+ * ```
57
+ */
58
+ export declare function isSameMicrosecond(date1: Temporal.Instant | Temporal.ZonedDateTime, date2: Temporal.Instant | Temporal.ZonedDateTime): boolean;
59
+ //# sourceMappingURL=isSameMicrosecond.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"isSameMicrosecond.d.ts","sourceRoot":"","sources":["../src/isSameMicrosecond.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAGtD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAuDG;AACH,wBAAgB,iBAAiB,CAC/B,KAAK,EAAE,QAAQ,CAAC,OAAO,GAAG,QAAQ,CAAC,aAAa,EAChD,KAAK,EAAE,QAAQ,CAAC,OAAO,GAAG,QAAQ,CAAC,aAAa,GAC/C,OAAO,CAcT"}
@@ -0,0 +1,8 @@
1
+ import {
2
+ isSameMicrosecond
3
+ } from "./chunk-PPB62JYV.js";
4
+ import "./chunk-MJSZNWCV.js";
5
+ export {
6
+ isSameMicrosecond
7
+ };
8
+ //# sourceMappingURL=isSameMicrosecond.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=isSameMicrosecond.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"isSameMicrosecond.test.d.ts","sourceRoot":"","sources":["../src/isSameMicrosecond.test.ts"],"names":[],"mappings":""}
@@ -0,0 +1,59 @@
1
+ import type { Temporal } from '@js-temporal/polyfill';
2
+ /**
3
+ * Returns true if both datetimes fall in the same millisecond.
4
+ * Compares the year, month, day, hour, minute, second, and millisecond fields directly.
5
+ * Ignores sub-millisecond precision (microseconds, nanoseconds).
6
+ *
7
+ * Instant inputs are converted to UTC. For ZonedDateTime inputs, their
8
+ * timezone is preserved. Convert to a common timezone before calling if
9
+ * you need to compare from a specific perspective.
10
+ *
11
+ * @param date1 - First datetime (Instant or ZonedDateTime)
12
+ * @param date2 - Second datetime (Instant or ZonedDateTime)
13
+ * @returns true if both dates are in the same millisecond, false otherwise
14
+ *
15
+ * @example
16
+ * ```ts
17
+ * // Same timezone, same millisecond
18
+ * const time1 = Temporal.ZonedDateTime.from('2025-01-20T14:30:45.123Z[UTC]');
19
+ * const time2 = Temporal.ZonedDateTime.from('2025-01-20T14:30:45.123999Z[UTC]');
20
+ *
21
+ * isSameMillisecond(time1, time2); // true
22
+ * ```
23
+ *
24
+ * @example
25
+ * ```ts
26
+ * // Same timezone, different milliseconds
27
+ * const ms123 = Temporal.ZonedDateTime.from('2025-01-20T14:30:45.123Z[UTC]');
28
+ * const ms124 = Temporal.ZonedDateTime.from('2025-01-20T14:30:45.124Z[UTC]');
29
+ *
30
+ * isSameMillisecond(ms123, ms124); // false
31
+ * ```
32
+ *
33
+ * @example
34
+ * ```ts
35
+ * // Different timezones - compares their local milliseconds
36
+ * const ny = Temporal.ZonedDateTime.from('2025-01-20T14:30:45.123-05:00[America/New_York]');
37
+ * const tokyo = Temporal.ZonedDateTime.from('2025-01-21T04:30:45.987+09:00[Asia/Tokyo]');
38
+ *
39
+ * // Same instant, different local milliseconds from each person's perspective
40
+ * isSameMillisecond(ny, tokyo); // false (14:30:45.123 in NY, 04:30:45.987 in Tokyo)
41
+ *
42
+ * // Convert to UTC to compare in UTC timezone
43
+ * isSameMillisecond(ny.withTimeZone('UTC'), tokyo.withTimeZone('UTC')); // true (both 19:30:45.123 in UTC)
44
+ *
45
+ * // Convert to NY timezone to compare from NY perspective
46
+ * isSameMillisecond(ny, tokyo.withTimeZone('America/New_York')); // true (both 14:30:45.123 in NY)
47
+ * ```
48
+ *
49
+ * @example
50
+ * ```ts
51
+ * // Instant inputs are converted to UTC
52
+ * const instant1 = Temporal.Instant.from('2025-01-20T14:30:45.123456Z');
53
+ * const instant2 = Temporal.Instant.from('2025-01-20T14:30:45.123999Z');
54
+ *
55
+ * isSameMillisecond(instant1, instant2); // true (both 14:30:45.123 in UTC)
56
+ * ```
57
+ */
58
+ export declare function isSameMillisecond(date1: Temporal.Instant | Temporal.ZonedDateTime, date2: Temporal.Instant | Temporal.ZonedDateTime): boolean;
59
+ //# sourceMappingURL=isSameMillisecond.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"isSameMillisecond.d.ts","sourceRoot":"","sources":["../src/isSameMillisecond.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAGtD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAuDG;AACH,wBAAgB,iBAAiB,CAC/B,KAAK,EAAE,QAAQ,CAAC,OAAO,GAAG,QAAQ,CAAC,aAAa,EAChD,KAAK,EAAE,QAAQ,CAAC,OAAO,GAAG,QAAQ,CAAC,aAAa,GAC/C,OAAO,CAaT"}
@@ -0,0 +1,8 @@
1
+ import {
2
+ isSameMillisecond
3
+ } from "./chunk-ISHZRFVN.js";
4
+ import "./chunk-MJSZNWCV.js";
5
+ export {
6
+ isSameMillisecond
7
+ };
8
+ //# sourceMappingURL=isSameMillisecond.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=isSameMillisecond.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"isSameMillisecond.test.d.ts","sourceRoot":"","sources":["../src/isSameMillisecond.test.ts"],"names":[],"mappings":""}
@@ -0,0 +1,58 @@
1
+ import type { Temporal } from '@js-temporal/polyfill';
2
+ /**
3
+ * Returns true if both datetimes fall in the same minute.
4
+ * Compares the year, month, day, hour, and minute fields directly.
5
+ *
6
+ * Instant inputs are converted to UTC. For ZonedDateTime inputs, their
7
+ * timezone is preserved. Convert to a common timezone before calling if
8
+ * you need to compare from a specific perspective.
9
+ *
10
+ * @param date1 - First datetime (Instant or ZonedDateTime)
11
+ * @param date2 - Second datetime (Instant or ZonedDateTime)
12
+ * @returns true if both dates are in the same minute, false otherwise
13
+ *
14
+ * @example
15
+ * ```ts
16
+ * // Same timezone, same minute
17
+ * const start = Temporal.ZonedDateTime.from('2025-01-20T14:30:00Z[UTC]');
18
+ * const end = Temporal.ZonedDateTime.from('2025-01-20T14:30:59.999Z[UTC]');
19
+ *
20
+ * isSameMinute(start, end); // true
21
+ * ```
22
+ *
23
+ * @example
24
+ * ```ts
25
+ * // Same timezone, different minutes
26
+ * const min30 = Temporal.ZonedDateTime.from('2025-01-20T14:30:59Z[UTC]');
27
+ * const min31 = Temporal.ZonedDateTime.from('2025-01-20T14:31:00Z[UTC]');
28
+ *
29
+ * isSameMinute(min30, min31); // false
30
+ * ```
31
+ *
32
+ * @example
33
+ * ```ts
34
+ * // Different timezones - compares their local minutes
35
+ * const ny = Temporal.ZonedDateTime.from('2025-01-20T14:30:45-05:00[America/New_York]');
36
+ * const tokyo = Temporal.ZonedDateTime.from('2025-01-21T04:30:45+09:00[Asia/Tokyo]');
37
+ *
38
+ * // Same instant, different local minutes from each person's perspective
39
+ * isSameMinute(ny, tokyo); // false (14:30:xx in NY, 04:30:xx in Tokyo)
40
+ *
41
+ * // Convert to UTC to compare in UTC timezone
42
+ * isSameMinute(ny.withTimeZone('UTC'), tokyo.withTimeZone('UTC')); // true (both 19:30:xx in UTC)
43
+ *
44
+ * // Convert to NY timezone to compare from NY perspective
45
+ * isSameMinute(ny, tokyo.withTimeZone('America/New_York')); // true (both 14:30:xx in NY)
46
+ * ```
47
+ *
48
+ * @example
49
+ * ```ts
50
+ * // Instant inputs are converted to UTC
51
+ * const instant1 = Temporal.Instant.from('2025-01-20T14:30:15Z');
52
+ * const instant2 = Temporal.Instant.from('2025-01-20T14:30:45Z');
53
+ *
54
+ * isSameMinute(instant1, instant2); // true (both 14:30:xx in UTC)
55
+ * ```
56
+ */
57
+ export declare function isSameMinute(date1: Temporal.Instant | Temporal.ZonedDateTime, date2: Temporal.Instant | Temporal.ZonedDateTime): boolean;
58
+ //# sourceMappingURL=isSameMinute.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"isSameMinute.d.ts","sourceRoot":"","sources":["../src/isSameMinute.ts"],"names":[],"mappings":"AAAA,OAAO,KAAI,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAGrD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAsDG;AACH,wBAAgB,YAAY,CAC1B,KAAK,EAAE,QAAQ,CAAC,OAAO,GAAG,QAAQ,CAAC,aAAa,EAChD,KAAK,EAAE,QAAQ,CAAC,OAAO,GAAG,QAAQ,CAAC,aAAa,GAC/C,OAAO,CAWT"}
@@ -0,0 +1,8 @@
1
+ import {
2
+ isSameMinute
3
+ } from "./chunk-LDO6PRNJ.js";
4
+ import "./chunk-MJSZNWCV.js";
5
+ export {
6
+ isSameMinute
7
+ };
8
+ //# sourceMappingURL=isSameMinute.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=isSameMinute.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"isSameMinute.test.d.ts","sourceRoot":"","sources":["../src/isSameMinute.test.ts"],"names":[],"mappings":""}
@@ -0,0 +1,58 @@
1
+ import type { Temporal } from '@js-temporal/polyfill';
2
+ /**
3
+ * Returns true if both datetimes fall in the same calendar month and year.
4
+ * Compares the year and month fields directly.
5
+ *
6
+ * Instant inputs are converted to UTC. For ZonedDateTime inputs, their
7
+ * timezone is preserved. Convert to a common timezone before calling if
8
+ * you need to compare from a specific perspective.
9
+ *
10
+ * @param date1 - First datetime (Instant or ZonedDateTime)
11
+ * @param date2 - Second datetime (Instant or ZonedDateTime)
12
+ * @returns true if both dates are in the same calendar month, false otherwise
13
+ *
14
+ * @example
15
+ * ```ts
16
+ * // Same timezone, same month
17
+ * const start = Temporal.ZonedDateTime.from('2025-01-01T08:00:00Z[UTC]');
18
+ * const end = Temporal.ZonedDateTime.from('2025-01-31T23:59:59Z[UTC]');
19
+ *
20
+ * isSameMonth(start, end); // true
21
+ * ```
22
+ *
23
+ * @example
24
+ * ```ts
25
+ * // Same timezone, different months
26
+ * const jan = Temporal.ZonedDateTime.from('2025-01-31T23:59:59Z[UTC]');
27
+ * const feb = Temporal.ZonedDateTime.from('2025-02-01T00:00:00Z[UTC]');
28
+ *
29
+ * isSameMonth(jan, feb); // false
30
+ * ```
31
+ *
32
+ * @example
33
+ * ```ts
34
+ * // Different timezones - compares their local calendar months
35
+ * const ny = Temporal.ZonedDateTime.from('2025-01-31T23:00:00-05:00[America/New_York]');
36
+ * const tokyo = Temporal.ZonedDateTime.from('2025-02-01T13:00:00+09:00[Asia/Tokyo]');
37
+ *
38
+ * // Same instant, different calendar months from each person's perspective
39
+ * isSameMonth(ny, tokyo); // false (Jan in NY, Feb in Tokyo)
40
+ *
41
+ * // Convert to UTC to compare in UTC timezone
42
+ * isSameMonth(ny.withTimeZone('UTC'), tokyo.withTimeZone('UTC')); // true (both Feb in UTC)
43
+ *
44
+ * // Convert to NY timezone to compare from NY perspective
45
+ * isSameMonth(ny, tokyo.withTimeZone('America/New_York')); // true (both Jan in NY)
46
+ * ```
47
+ *
48
+ * @example
49
+ * ```ts
50
+ * // Instant inputs are converted to UTC
51
+ * const instant1 = Temporal.Instant.from('2025-01-01T00:00:00Z');
52
+ * const instant2 = Temporal.Instant.from('2025-01-31T23:59:59Z');
53
+ *
54
+ * isSameMonth(instant1, instant2); // true (both Jan 2025 in UTC)
55
+ * ```
56
+ */
57
+ export declare function isSameMonth(date1: Temporal.Instant | Temporal.ZonedDateTime, date2: Temporal.Instant | Temporal.ZonedDateTime): boolean;
58
+ //# sourceMappingURL=isSameMonth.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"isSameMonth.d.ts","sourceRoot":"","sources":["../src/isSameMonth.ts"],"names":[],"mappings":"AAAA,OAAO,KAAI,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAGrD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAsDG;AACH,wBAAgB,WAAW,CACzB,KAAK,EAAE,QAAQ,CAAC,OAAO,GAAG,QAAQ,CAAC,aAAa,EAChD,KAAK,EAAE,QAAQ,CAAC,OAAO,GAAG,QAAQ,CAAC,aAAa,GAC/C,OAAO,CAKT"}
@@ -0,0 +1,8 @@
1
+ import {
2
+ isSameMonth
3
+ } from "./chunk-ADQTZVMH.js";
4
+ import "./chunk-MJSZNWCV.js";
5
+ export {
6
+ isSameMonth
7
+ };
8
+ //# sourceMappingURL=isSameMonth.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=isSameMonth.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"isSameMonth.test.d.ts","sourceRoot":"","sources":["../src/isSameMonth.test.ts"],"names":[],"mappings":""}