@bemoje/date 0.3.1 → 1.0.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 (157) hide show
  1. package/README.md +94 -20
  2. package/index.d.ts +90 -0
  3. package/index.mjs +112 -0
  4. package/package.json +23 -16
  5. package/LICENSE +0 -21
  6. package/cjs/index.d.ts +0 -38
  7. package/cjs/index.d.ts.map +0 -1
  8. package/cjs/index.js +0 -41
  9. package/cjs/index.js.map +0 -1
  10. package/cjs/lib/assertValidDate.d.ts +0 -19
  11. package/cjs/lib/assertValidDate.d.ts.map +0 -1
  12. package/cjs/lib/assertValidDate.js +0 -36
  13. package/cjs/lib/assertValidDate.js.map +0 -1
  14. package/cjs/lib/assertValidDateDay.d.ts +0 -16
  15. package/cjs/lib/assertValidDateDay.d.ts.map +0 -1
  16. package/cjs/lib/assertValidDateDay.js +0 -24
  17. package/cjs/lib/assertValidDateDay.js.map +0 -1
  18. package/cjs/lib/assertValidDateMonth.d.ts +0 -13
  19. package/cjs/lib/assertValidDateMonth.d.ts.map +0 -1
  20. package/cjs/lib/assertValidDateMonth.js +0 -21
  21. package/cjs/lib/assertValidDateMonth.js.map +0 -1
  22. package/cjs/lib/assertValidDateYear.d.ts +0 -14
  23. package/cjs/lib/assertValidDateYear.d.ts.map +0 -1
  24. package/cjs/lib/assertValidDateYear.js +0 -22
  25. package/cjs/lib/assertValidDateYear.js.map +0 -1
  26. package/cjs/lib/constants/DAYS_IN_MONTH.d.ts +0 -5
  27. package/cjs/lib/constants/DAYS_IN_MONTH.d.ts.map +0 -1
  28. package/cjs/lib/constants/DAYS_IN_MONTH.js +0 -8
  29. package/cjs/lib/constants/DAYS_IN_MONTH.js.map +0 -1
  30. package/cjs/lib/constants/MS_IN_DAY.d.ts +0 -5
  31. package/cjs/lib/constants/MS_IN_DAY.d.ts.map +0 -1
  32. package/cjs/lib/constants/MS_IN_DAY.js +0 -8
  33. package/cjs/lib/constants/MS_IN_DAY.js.map +0 -1
  34. package/cjs/lib/constants/MS_IN_HOUR.d.ts +0 -5
  35. package/cjs/lib/constants/MS_IN_HOUR.d.ts.map +0 -1
  36. package/cjs/lib/constants/MS_IN_HOUR.js +0 -8
  37. package/cjs/lib/constants/MS_IN_HOUR.js.map +0 -1
  38. package/cjs/lib/constants/MS_IN_MINUTE.d.ts +0 -5
  39. package/cjs/lib/constants/MS_IN_MINUTE.d.ts.map +0 -1
  40. package/cjs/lib/constants/MS_IN_MINUTE.js +0 -8
  41. package/cjs/lib/constants/MS_IN_MINUTE.js.map +0 -1
  42. package/cjs/lib/constants/MS_IN_MONTH.d.ts +0 -5
  43. package/cjs/lib/constants/MS_IN_MONTH.d.ts.map +0 -1
  44. package/cjs/lib/constants/MS_IN_MONTH.js +0 -8
  45. package/cjs/lib/constants/MS_IN_MONTH.js.map +0 -1
  46. package/cjs/lib/constants/MS_IN_SECOND.d.ts +0 -5
  47. package/cjs/lib/constants/MS_IN_SECOND.d.ts.map +0 -1
  48. package/cjs/lib/constants/MS_IN_SECOND.js +0 -8
  49. package/cjs/lib/constants/MS_IN_SECOND.js.map +0 -1
  50. package/cjs/lib/constants/MS_IN_WEEK.d.ts +0 -5
  51. package/cjs/lib/constants/MS_IN_WEEK.d.ts.map +0 -1
  52. package/cjs/lib/constants/MS_IN_WEEK.js +0 -8
  53. package/cjs/lib/constants/MS_IN_WEEK.js.map +0 -1
  54. package/cjs/lib/constants/MS_IN_YEAR.d.ts +0 -5
  55. package/cjs/lib/constants/MS_IN_YEAR.d.ts.map +0 -1
  56. package/cjs/lib/constants/MS_IN_YEAR.js +0 -8
  57. package/cjs/lib/constants/MS_IN_YEAR.js.map +0 -1
  58. package/cjs/lib/dateAdjustHoursBy.d.ts +0 -8
  59. package/cjs/lib/dateAdjustHoursBy.d.ts.map +0 -1
  60. package/cjs/lib/dateAdjustHoursBy.js +0 -14
  61. package/cjs/lib/dateAdjustHoursBy.js.map +0 -1
  62. package/cjs/lib/dateCreateTimeZoneSetter.d.ts +0 -7
  63. package/cjs/lib/dateCreateTimeZoneSetter.d.ts.map +0 -1
  64. package/cjs/lib/dateCreateTimeZoneSetter.js +0 -16
  65. package/cjs/lib/dateCreateTimeZoneSetter.js.map +0 -1
  66. package/cjs/lib/dateDaysAgo.d.ts +0 -6
  67. package/cjs/lib/dateDaysAgo.d.ts.map +0 -1
  68. package/cjs/lib/dateDaysAgo.js +0 -14
  69. package/cjs/lib/dateDaysAgo.js.map +0 -1
  70. package/cjs/lib/dateWeekDayName.d.ts +0 -12
  71. package/cjs/lib/dateWeekDayName.d.ts.map +0 -1
  72. package/cjs/lib/dateWeekDayName.js +0 -19
  73. package/cjs/lib/dateWeekDayName.js.map +0 -1
  74. package/cjs/lib/daysSinceDate.d.ts +0 -13
  75. package/cjs/lib/daysSinceDate.d.ts.map +0 -1
  76. package/cjs/lib/daysSinceDate.js +0 -21
  77. package/cjs/lib/daysSinceDate.js.map +0 -1
  78. package/cjs/lib/getCentury.d.ts +0 -14
  79. package/cjs/lib/getCentury.d.ts.map +0 -1
  80. package/cjs/lib/getCentury.js +0 -22
  81. package/cjs/lib/getCentury.js.map +0 -1
  82. package/cjs/lib/getCurrentYear.d.ts +0 -33
  83. package/cjs/lib/getCurrentYear.d.ts.map +0 -1
  84. package/cjs/lib/getCurrentYear.js +0 -47
  85. package/cjs/lib/getCurrentYear.js.map +0 -1
  86. package/cjs/lib/hoursSinceDate.d.ts +0 -13
  87. package/cjs/lib/hoursSinceDate.d.ts.map +0 -1
  88. package/cjs/lib/hoursSinceDate.js +0 -21
  89. package/cjs/lib/hoursSinceDate.js.map +0 -1
  90. package/cjs/lib/isLeapYear.d.ts +0 -16
  91. package/cjs/lib/isLeapYear.d.ts.map +0 -1
  92. package/cjs/lib/isLeapYear.js +0 -24
  93. package/cjs/lib/isLeapYear.js.map +0 -1
  94. package/cjs/lib/isValidDate.d.ts +0 -21
  95. package/cjs/lib/isValidDate.d.ts.map +0 -1
  96. package/cjs/lib/isValidDate.js +0 -41
  97. package/cjs/lib/isValidDate.js.map +0 -1
  98. package/cjs/lib/isValidDateDay.d.ts +0 -17
  99. package/cjs/lib/isValidDateDay.d.ts.map +0 -1
  100. package/cjs/lib/isValidDateDay.js +0 -34
  101. package/cjs/lib/isValidDateDay.js.map +0 -1
  102. package/cjs/lib/isValidDateMonth.d.ts +0 -13
  103. package/cjs/lib/isValidDateMonth.d.ts.map +0 -1
  104. package/cjs/lib/isValidDateMonth.js +0 -19
  105. package/cjs/lib/isValidDateMonth.js.map +0 -1
  106. package/cjs/lib/isValidDateYear.d.ts +0 -16
  107. package/cjs/lib/isValidDateYear.d.ts.map +0 -1
  108. package/cjs/lib/isValidDateYear.js +0 -22
  109. package/cjs/lib/isValidDateYear.js.map +0 -1
  110. package/cjs/lib/isoDateTimestamp.d.ts +0 -16
  111. package/cjs/lib/isoDateTimestamp.d.ts.map +0 -1
  112. package/cjs/lib/isoDateTimestamp.js +0 -22
  113. package/cjs/lib/isoDateTimestamp.js.map +0 -1
  114. package/cjs/lib/isoDateTimestampForFilename.d.ts +0 -12
  115. package/cjs/lib/isoDateTimestampForFilename.d.ts.map +0 -1
  116. package/cjs/lib/isoDateTimestampForFilename.js +0 -21
  117. package/cjs/lib/isoDateTimestampForFilename.js.map +0 -1
  118. package/cjs/lib/minutesSinceDate.d.ts +0 -13
  119. package/cjs/lib/minutesSinceDate.d.ts.map +0 -1
  120. package/cjs/lib/minutesSinceDate.js +0 -21
  121. package/cjs/lib/minutesSinceDate.js.map +0 -1
  122. package/cjs/lib/monthNameDa.d.ts +0 -17
  123. package/cjs/lib/monthNameDa.d.ts.map +0 -1
  124. package/cjs/lib/monthNameDa.js +0 -43
  125. package/cjs/lib/monthNameDa.js.map +0 -1
  126. package/cjs/lib/monthNameEn.d.ts +0 -17
  127. package/cjs/lib/monthNameEn.d.ts.map +0 -1
  128. package/cjs/lib/monthNameEn.js +0 -43
  129. package/cjs/lib/monthNameEn.js.map +0 -1
  130. package/cjs/lib/monthsSinceDate.d.ts +0 -13
  131. package/cjs/lib/monthsSinceDate.d.ts.map +0 -1
  132. package/cjs/lib/monthsSinceDate.js +0 -21
  133. package/cjs/lib/monthsSinceDate.js.map +0 -1
  134. package/cjs/lib/msSinceDate.d.ts +0 -12
  135. package/cjs/lib/msSinceDate.d.ts.map +0 -1
  136. package/cjs/lib/msSinceDate.js +0 -24
  137. package/cjs/lib/msSinceDate.js.map +0 -1
  138. package/cjs/lib/numDaysInMonth.d.ts +0 -18
  139. package/cjs/lib/numDaysInMonth.d.ts.map +0 -1
  140. package/cjs/lib/numDaysInMonth.js +0 -28
  141. package/cjs/lib/numDaysInMonth.js.map +0 -1
  142. package/cjs/lib/prettyIsoDateString.d.ts +0 -14
  143. package/cjs/lib/prettyIsoDateString.d.ts.map +0 -1
  144. package/cjs/lib/prettyIsoDateString.js +0 -29
  145. package/cjs/lib/prettyIsoDateString.js.map +0 -1
  146. package/cjs/lib/secondsSinceDate.d.ts +0 -11
  147. package/cjs/lib/secondsSinceDate.d.ts.map +0 -1
  148. package/cjs/lib/secondsSinceDate.js +0 -19
  149. package/cjs/lib/secondsSinceDate.js.map +0 -1
  150. package/cjs/lib/weeksSinceDate.d.ts +0 -11
  151. package/cjs/lib/weeksSinceDate.d.ts.map +0 -1
  152. package/cjs/lib/weeksSinceDate.js +0 -19
  153. package/cjs/lib/weeksSinceDate.js.map +0 -1
  154. package/cjs/lib/yearsSinceDate.d.ts +0 -11
  155. package/cjs/lib/yearsSinceDate.d.ts.map +0 -1
  156. package/cjs/lib/yearsSinceDate.js +0 -19
  157. package/cjs/lib/yearsSinceDate.js.map +0 -1
@@ -1,16 +0,0 @@
1
- /**
2
- * Checks if a given year is a leap year.
3
- * A leap year is exactly divisible by 4 except for century years (years ending with 00).
4
- * The century year is a leap year only if it is perfectly divisible by 400.
5
- * @param year The year to check. Must be a valid year number.
6
- * @returns `true` if the year is a leap year, `false` otherwise.
7
- * @throws Will throw an error if the year is not a valid number.
8
- * @example ```ts
9
- * isLeapYear(2000); ;
10
- * //=> true
11
- * isLeapYear(2001); ;
12
- * //=> false
13
- * ```
14
- */
15
- export declare function isLeapYear(year: number): boolean;
16
- //# sourceMappingURL=isLeapYear.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"isLeapYear.d.ts","sourceRoot":"","sources":["../../../../../packages/date/src/lib/isLeapYear.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;;;;GAaG;AACH,wBAAgB,UAAU,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAGhD"}
@@ -1,24 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isLeapYear = void 0;
4
- const assertValidDateYear_1 = require("./assertValidDateYear");
5
- /**
6
- * Checks if a given year is a leap year.
7
- * A leap year is exactly divisible by 4 except for century years (years ending with 00).
8
- * The century year is a leap year only if it is perfectly divisible by 400.
9
- * @param year The year to check. Must be a valid year number.
10
- * @returns `true` if the year is a leap year, `false` otherwise.
11
- * @throws Will throw an error if the year is not a valid number.
12
- * @example ```ts
13
- * isLeapYear(2000); ;
14
- * //=> true
15
- * isLeapYear(2001); ;
16
- * //=> false
17
- * ```
18
- */
19
- function isLeapYear(year) {
20
- (0, assertValidDateYear_1.assertValidDateYear)(year);
21
- return (0 == year % 4 && 0 != year % 100) || 0 == year % 400;
22
- }
23
- exports.isLeapYear = isLeapYear;
24
- //# sourceMappingURL=isLeapYear.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"isLeapYear.js","sourceRoot":"","sources":["../../../../../packages/date/src/lib/isLeapYear.ts"],"names":[],"mappings":";;;AAAA,+DAA2D;AAE3D;;;;;;;;;;;;;GAaG;AACH,SAAgB,UAAU,CAAC,IAAY;IACrC,IAAA,yCAAmB,EAAC,IAAI,CAAC,CAAA;IACzB,OAAO,CAAC,CAAC,IAAI,IAAI,GAAG,CAAC,IAAI,CAAC,IAAI,IAAI,GAAG,GAAG,CAAC,IAAI,CAAC,IAAI,IAAI,GAAG,GAAG,CAAA;AAC9D,CAAC;AAHD,gCAGC"}
@@ -1,21 +0,0 @@
1
- /**
2
- * Checks if the provided date and time values form a valid date.
3
- * @param year The year of the date.
4
- * @param month The month of the date.
5
- * @param day The day of the date.
6
- * @param hour The hour of the time.
7
- * @param minute The minute of the time.
8
- * @param second The second of the time.
9
- * @param millisecond The millisecond of the time.
10
- * @returns A boolean indicating whether the provided date and time values form a valid date.
11
- * @example ```ts
12
- * isValidDate(2021, 12, 31, 23, 59, 59, 999);;
13
- * //=> true
14
- * isValidDate('2021', '12', '31', '23', '59', '59', '999');;
15
- * //=> true
16
- * isValidDate(2021, 13, 31, 23, 59, 59, 999);;
17
- * //=> false
18
- * ```
19
- */
20
- export declare function isValidDate(year?: number | string, month?: number | string, day?: number | string, hour?: number | string, minute?: number | string, second?: number | string, millisecond?: number | string): boolean;
21
- //# sourceMappingURL=isValidDate.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"isValidDate.d.ts","sourceRoot":"","sources":["../../../../../packages/date/src/lib/isValidDate.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AACH,wBAAgB,WAAW,CACzB,IAAI,CAAC,EAAE,MAAM,GAAG,MAAM,EACtB,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,EACvB,GAAG,CAAC,EAAE,MAAM,GAAG,MAAM,EACrB,IAAI,CAAC,EAAE,MAAM,GAAG,MAAM,EACtB,MAAM,CAAC,EAAE,MAAM,GAAG,MAAM,EACxB,MAAM,CAAC,EAAE,MAAM,GAAG,MAAM,EACxB,WAAW,CAAC,EAAE,MAAM,GAAG,MAAM,GAC5B,OAAO,CAkBT"}
@@ -1,41 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isValidDate = void 0;
4
- /**
5
- * Checks if the provided date and time values form a valid date.
6
- * @param year The year of the date.
7
- * @param month The month of the date.
8
- * @param day The day of the date.
9
- * @param hour The hour of the time.
10
- * @param minute The minute of the time.
11
- * @param second The second of the time.
12
- * @param millisecond The millisecond of the time.
13
- * @returns A boolean indicating whether the provided date and time values form a valid date.
14
- * @example ```ts
15
- * isValidDate(2021, 12, 31, 23, 59, 59, 999);;
16
- * //=> true
17
- * isValidDate('2021', '12', '31', '23', '59', '59', '999');;
18
- * //=> true
19
- * isValidDate(2021, 13, 31, 23, 59, 59, 999);;
20
- * //=> false
21
- * ```
22
- */
23
- function isValidDate(year, month, day, hour, minute, second, millisecond) {
24
- year = year ? Number(year) : 0;
25
- month = month ? Number(month) : 0;
26
- day = day ? Number(day) : 0;
27
- hour = hour ? Number(hour) : 0;
28
- minute = minute ? Number(minute) : 0;
29
- second = second ? Number(second) : 0;
30
- millisecond = millisecond ? Number(millisecond) : 0;
31
- const d = new Date(year, month - 1, day, hour, minute, second, millisecond);
32
- return (d.getFullYear() === year &&
33
- d.getMonth() + 1 === month &&
34
- d.getDate() === day &&
35
- d.getHours() === hour &&
36
- d.getMinutes() === minute &&
37
- d.getSeconds() === second &&
38
- d.getMilliseconds() === millisecond);
39
- }
40
- exports.isValidDate = isValidDate;
41
- //# sourceMappingURL=isValidDate.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"isValidDate.js","sourceRoot":"","sources":["../../../../../packages/date/src/lib/isValidDate.ts"],"names":[],"mappings":";;;AAAA;;;;;;;;;;;;;;;;;;GAkBG;AACH,SAAgB,WAAW,CACzB,IAAsB,EACtB,KAAuB,EACvB,GAAqB,EACrB,IAAsB,EACtB,MAAwB,EACxB,MAAwB,EACxB,WAA6B;IAE7B,IAAI,GAAG,IAAI,CAAC,CAAC,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;IAC9B,KAAK,GAAG,KAAK,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;IACjC,GAAG,GAAG,GAAG,CAAC,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;IAC3B,IAAI,GAAG,IAAI,CAAC,CAAC,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;IAC9B,MAAM,GAAG,MAAM,CAAC,CAAC,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;IACpC,MAAM,GAAG,MAAM,CAAC,CAAC,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;IACpC,WAAW,GAAG,WAAW,CAAC,CAAC,CAAC,MAAM,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;IACnD,MAAM,CAAC,GAAG,IAAI,IAAI,CAAC,IAAI,EAAE,KAAK,GAAG,CAAC,EAAE,GAAG,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,EAAE,WAAW,CAAC,CAAA;IAC3E,OAAO,CACL,CAAC,CAAC,WAAW,EAAE,KAAK,IAAI;QACxB,CAAC,CAAC,QAAQ,EAAE,GAAG,CAAC,KAAK,KAAK;QAC1B,CAAC,CAAC,OAAO,EAAE,KAAK,GAAG;QACnB,CAAC,CAAC,QAAQ,EAAE,KAAK,IAAI;QACrB,CAAC,CAAC,UAAU,EAAE,KAAK,MAAM;QACzB,CAAC,CAAC,UAAU,EAAE,KAAK,MAAM;QACzB,CAAC,CAAC,eAAe,EAAE,KAAK,WAAW,CACpC,CAAA;AACH,CAAC;AA1BD,kCA0BC"}
@@ -1,17 +0,0 @@
1
- /**
2
- * Checks if the given day is a valid day of the month.
3
- * @param day The day of the month. Must be an integer.
4
- * @param month The month of the year. Must be an integer.
5
- * @param year The year. Optional parameter. If not provided, the function will not check for leap years.
6
- * @returns A boolean indicating whether the day is valid for the given month and year.
7
- * @example ```ts
8
- * isValidDateDay(31, 1, 2000);
9
- * //=> true
10
- * isValidDateDay(31, 2, 2000);
11
- * //=> false
12
- * isValidDateDay(29, 2);
13
- * //=> true
14
- * ```
15
- */
16
- export declare function isValidDateDay(day: number, month: number, year?: number): boolean;
17
- //# sourceMappingURL=isValidDateDay.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"isValidDateDay.d.ts","sourceRoot":"","sources":["../../../../../packages/date/src/lib/isValidDateDay.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;;;;;GAcG;AACH,wBAAgB,cAAc,CAAC,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,MAAM,GAAG,OAAO,CAOjF"}
@@ -1,34 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isValidDateDay = void 0;
4
- const numDaysInMonth_1 = require("./numDaysInMonth");
5
- /**
6
- * Checks if the given day is a valid day of the month.
7
- * @param day The day of the month. Must be an integer.
8
- * @param month The month of the year. Must be an integer.
9
- * @param year The year. Optional parameter. If not provided, the function will not check for leap years.
10
- * @returns A boolean indicating whether the day is valid for the given month and year.
11
- * @example ```ts
12
- * isValidDateDay(31, 1, 2000);
13
- * //=> true
14
- * isValidDateDay(31, 2, 2000);
15
- * //=> false
16
- * isValidDateDay(29, 2);
17
- * //=> true
18
- * ```
19
- */
20
- function isValidDateDay(day, month, year) {
21
- if (!Number.isInteger(day))
22
- return false;
23
- if (!Number.isInteger(month))
24
- return false;
25
- if (year && !Number.isInteger(year))
26
- return false;
27
- if (day < 1)
28
- return false;
29
- if (day > (0, numDaysInMonth_1.numDaysInMonth)(month, year))
30
- return false;
31
- return true;
32
- }
33
- exports.isValidDateDay = isValidDateDay;
34
- //# sourceMappingURL=isValidDateDay.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"isValidDateDay.js","sourceRoot":"","sources":["../../../../../packages/date/src/lib/isValidDateDay.ts"],"names":[],"mappings":";;;AAAA,qDAAiD;AAEjD;;;;;;;;;;;;;;GAcG;AACH,SAAgB,cAAc,CAAC,GAAW,EAAE,KAAa,EAAE,IAAa;IACtE,IAAI,CAAC,MAAM,CAAC,SAAS,CAAC,GAAG,CAAC;QAAE,OAAO,KAAK,CAAA;IACxC,IAAI,CAAC,MAAM,CAAC,SAAS,CAAC,KAAK,CAAC;QAAE,OAAO,KAAK,CAAA;IAC1C,IAAI,IAAI,IAAI,CAAC,MAAM,CAAC,SAAS,CAAC,IAAI,CAAC;QAAE,OAAO,KAAK,CAAA;IACjD,IAAI,GAAG,GAAG,CAAC;QAAE,OAAO,KAAK,CAAA;IACzB,IAAI,GAAG,GAAG,IAAA,+BAAc,EAAC,KAAK,EAAE,IAAI,CAAC;QAAE,OAAO,KAAK,CAAA;IACnD,OAAO,IAAI,CAAA;AACb,CAAC;AAPD,wCAOC"}
@@ -1,13 +0,0 @@
1
- /**
2
- * Checks if the provided month is a valid month number (1-12).
3
- * @param month The month number to validate.
4
- * @returns A boolean indicating whether the month is valid.
5
- * @example ```ts
6
- * isValidDateMonth(5);;
7
- * //=> true
8
- * isValidDateMonth(13);;
9
- * //=> false
10
- * ```
11
- */
12
- export declare function isValidDateMonth(month: number): boolean;
13
- //# sourceMappingURL=isValidDateMonth.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"isValidDateMonth.d.ts","sourceRoot":"","sources":["../../../../../packages/date/src/lib/isValidDateMonth.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AACH,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,MAAM,GAAG,OAAO,CAEvD"}
@@ -1,19 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isValidDateMonth = void 0;
4
- /**
5
- * Checks if the provided month is a valid month number (1-12).
6
- * @param month The month number to validate.
7
- * @returns A boolean indicating whether the month is valid.
8
- * @example ```ts
9
- * isValidDateMonth(5);;
10
- * //=> true
11
- * isValidDateMonth(13);;
12
- * //=> false
13
- * ```
14
- */
15
- function isValidDateMonth(month) {
16
- return Number.isInteger(month) && month >= 1 && month <= 12;
17
- }
18
- exports.isValidDateMonth = isValidDateMonth;
19
- //# sourceMappingURL=isValidDateMonth.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"isValidDateMonth.js","sourceRoot":"","sources":["../../../../../packages/date/src/lib/isValidDateMonth.ts"],"names":[],"mappings":";;;AAAA;;;;;;;;;;GAUG;AACH,SAAgB,gBAAgB,CAAC,KAAa;IAC5C,OAAO,MAAM,CAAC,SAAS,CAAC,KAAK,CAAC,IAAI,KAAK,IAAI,CAAC,IAAI,KAAK,IAAI,EAAE,CAAA;AAC7D,CAAC;AAFD,4CAEC"}
@@ -1,16 +0,0 @@
1
- /**
2
- * Checks if the provided year is a valid date year.
3
- * @remarks This function will return true if the year is a positive integer, false otherwise.
4
- * @param year The year to be checked.
5
- * @returns A boolean indicating whether the year is valid or not.
6
- * @example ```ts
7
- * isValidDateYear(2020); ;
8
- * //=> true
9
- * isValidDateYear(-2020);;
10
- * //=> false
11
- * isValidDateYear(2020.5);;
12
- * //=> false
13
- * ```
14
- */
15
- export declare function isValidDateYear(year: number): boolean;
16
- //# sourceMappingURL=isValidDateYear.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"isValidDateYear.d.ts","sourceRoot":"","sources":["../../../../../packages/date/src/lib/isValidDateYear.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AACH,wBAAgB,eAAe,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAErD"}
@@ -1,22 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isValidDateYear = void 0;
4
- /**
5
- * Checks if the provided year is a valid date year.
6
- * @remarks This function will return true if the year is a positive integer, false otherwise.
7
- * @param year The year to be checked.
8
- * @returns A boolean indicating whether the year is valid or not.
9
- * @example ```ts
10
- * isValidDateYear(2020); ;
11
- * //=> true
12
- * isValidDateYear(-2020);;
13
- * //=> false
14
- * isValidDateYear(2020.5);;
15
- * //=> false
16
- * ```
17
- */
18
- function isValidDateYear(year) {
19
- return Number.isInteger(year) && year >= 0;
20
- }
21
- exports.isValidDateYear = isValidDateYear;
22
- //# sourceMappingURL=isValidDateYear.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"isValidDateYear.js","sourceRoot":"","sources":["../../../../../packages/date/src/lib/isValidDateYear.ts"],"names":[],"mappings":";;;AAAA;;;;;;;;;;;;;GAaG;AACH,SAAgB,eAAe,CAAC,IAAY;IAC1C,OAAO,MAAM,CAAC,SAAS,CAAC,IAAI,CAAC,IAAI,IAAI,IAAI,CAAC,CAAA;AAC5C,CAAC;AAFD,0CAEC"}
@@ -1,16 +0,0 @@
1
- /**
2
- * Converts a given date to an ISO date timestamp string.
3
- * If no date is provided, the current date and time will be used.
4
- * @param - The date to convert. Defaults to the current date and time.
5
- * @returns The ISO date timestamp string.
6
- * @example ```ts
7
- * isoDateTimestamp(new Date('2020-01-01T00:00:00Z'));;
8
- * //=> "20200101T000000Z"
9
- * ```
10
- * @example ```ts
11
- * const timestamp = isoDateTimestamp();
12
- * console.log(timestamp); // Outputs the current date and time in ISO format, e.g. "20210520T102030Z"
13
- * ```
14
- */
15
- export declare function isoDateTimestamp(date?: Date): string;
16
- //# sourceMappingURL=isoDateTimestamp.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"isoDateTimestamp.d.ts","sourceRoot":"","sources":["../../../../../packages/date/src/lib/isoDateTimestamp.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AACH,wBAAgB,gBAAgB,CAAC,IAAI,OAAa,GAAG,MAAM,CAE1D"}
@@ -1,22 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isoDateTimestamp = void 0;
4
- /**
5
- * Converts a given date to an ISO date timestamp string.
6
- * If no date is provided, the current date and time will be used.
7
- * @param - The date to convert. Defaults to the current date and time.
8
- * @returns The ISO date timestamp string.
9
- * @example ```ts
10
- * isoDateTimestamp(new Date('2020-01-01T00:00:00Z'));;
11
- * //=> "20200101T000000Z"
12
- * ```
13
- * @example ```ts
14
- * const timestamp = isoDateTimestamp();
15
- * console.log(timestamp); // Outputs the current date and time in ISO format, e.g. "20210520T102030Z"
16
- * ```
17
- */
18
- function isoDateTimestamp(date = new Date()) {
19
- return date.toISOString().replace(/\D/g, '');
20
- }
21
- exports.isoDateTimestamp = isoDateTimestamp;
22
- //# sourceMappingURL=isoDateTimestamp.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"isoDateTimestamp.js","sourceRoot":"","sources":["../../../../../packages/date/src/lib/isoDateTimestamp.ts"],"names":[],"mappings":";;;AAAA;;;;;;;;;;;;;GAaG;AACH,SAAgB,gBAAgB,CAAC,IAAI,GAAG,IAAI,IAAI,EAAE;IAChD,OAAO,IAAI,CAAC,WAAW,EAAE,CAAC,OAAO,CAAC,KAAK,EAAE,EAAE,CAAC,CAAA;AAC9C,CAAC;AAFD,4CAEC"}
@@ -1,12 +0,0 @@
1
- /**
2
- * This function takes a date object and returns a string in ISO format suitable for filenames.
3
- * If no date is provided, it uses the current date and time.
4
- * @param date The date object to be converted. Defaults to the current date and time.
5
- * @returns A string in the format "YYYY-MM-DD-HH-MM-SS-SSS".
6
- * @example ```ts
7
- * isoDateTimestampForFilename(new Date('2022-01-01T00:00:00Z'));;
8
- * //=> "2022-01-01-00-00-00-000"
9
- * ```
10
- */
11
- export declare function isoDateTimestampForFilename(date?: Date): string;
12
- //# sourceMappingURL=isoDateTimestampForFilename.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"isoDateTimestampForFilename.d.ts","sourceRoot":"","sources":["../../../../../packages/date/src/lib/isoDateTimestampForFilename.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AACH,wBAAgB,2BAA2B,CAAC,IAAI,OAAa,GAAG,MAAM,CAKrE"}
@@ -1,21 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isoDateTimestampForFilename = void 0;
4
- /**
5
- * This function takes a date object and returns a string in ISO format suitable for filenames.
6
- * If no date is provided, it uses the current date and time.
7
- * @param date The date object to be converted. Defaults to the current date and time.
8
- * @returns A string in the format "YYYY-MM-DD-HH-MM-SS-SSS".
9
- * @example ```ts
10
- * isoDateTimestampForFilename(new Date('2022-01-01T00:00:00Z'));;
11
- * //=> "2022-01-01-00-00-00-000"
12
- * ```
13
- */
14
- function isoDateTimestampForFilename(date = new Date()) {
15
- return date
16
- .toISOString()
17
- .replace(/[-:T.]/g, '-')
18
- .replace('Z', '');
19
- }
20
- exports.isoDateTimestampForFilename = isoDateTimestampForFilename;
21
- //# sourceMappingURL=isoDateTimestampForFilename.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"isoDateTimestampForFilename.js","sourceRoot":"","sources":["../../../../../packages/date/src/lib/isoDateTimestampForFilename.ts"],"names":[],"mappings":";;;AAAA;;;;;;;;;GASG;AACH,SAAgB,2BAA2B,CAAC,IAAI,GAAG,IAAI,IAAI,EAAE;IAC3D,OAAO,IAAI;SACR,WAAW,EAAE;SACb,OAAO,CAAC,SAAS,EAAE,GAAG,CAAC;SACvB,OAAO,CAAC,GAAG,EAAE,EAAE,CAAC,CAAA;AACrB,CAAC;AALD,kEAKC"}
@@ -1,13 +0,0 @@
1
- /**
2
- * Calculates the number of minutes that have passed since the given date.
3
- * @param date The date from which to calculate the number of minutes that have passed.
4
- * @returns The number of minutes that have passed since the given date.
5
- * @example ```ts
6
- * new Date('2020-01-01T00:00:00Z');;
7
- * //=> {date}
8
- * minutesSinceDate(new Date('2020-01-01T00:00:00Z'));;
9
- * //=> {number of minutes since 2020-01-01T00:00:00Z}
10
- * ```
11
- */
12
- export declare function minutesSinceDate(date: Date | number): number;
13
- //# sourceMappingURL=minutesSinceDate.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"minutesSinceDate.d.ts","sourceRoot":"","sources":["../../../../../packages/date/src/lib/minutesSinceDate.ts"],"names":[],"mappings":"AAGA;;;;;;;;;;GAUG;AACH,wBAAgB,gBAAgB,CAAC,IAAI,EAAE,IAAI,GAAG,MAAM,GAAG,MAAM,CAE5D"}
@@ -1,21 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.minutesSinceDate = void 0;
4
- const MS_IN_MINUTE_1 = require("./constants/MS_IN_MINUTE");
5
- const msSinceDate_1 = require("./msSinceDate");
6
- /**
7
- * Calculates the number of minutes that have passed since the given date.
8
- * @param date The date from which to calculate the number of minutes that have passed.
9
- * @returns The number of minutes that have passed since the given date.
10
- * @example ```ts
11
- * new Date('2020-01-01T00:00:00Z');;
12
- * //=> {date}
13
- * minutesSinceDate(new Date('2020-01-01T00:00:00Z'));;
14
- * //=> {number of minutes since 2020-01-01T00:00:00Z}
15
- * ```
16
- */
17
- function minutesSinceDate(date) {
18
- return (0, msSinceDate_1.msSinceDate)(date) / MS_IN_MINUTE_1.MS_IN_MINUTE;
19
- }
20
- exports.minutesSinceDate = minutesSinceDate;
21
- //# sourceMappingURL=minutesSinceDate.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"minutesSinceDate.js","sourceRoot":"","sources":["../../../../../packages/date/src/lib/minutesSinceDate.ts"],"names":[],"mappings":";;;AAAA,2DAAuD;AACvD,+CAA2C;AAE3C;;;;;;;;;;GAUG;AACH,SAAgB,gBAAgB,CAAC,IAAmB;IAClD,OAAO,IAAA,yBAAW,EAAC,IAAI,CAAC,GAAG,2BAAY,CAAA;AACzC,CAAC;AAFD,4CAEC"}
@@ -1,17 +0,0 @@
1
- /**
2
- * Returns the name, in Danish language, of the month corresponding to the provided month number.
3
- *
4
- * @param month - A month number between 1 and 12.
5
- * @param maxLength - The maximum length of the returned string. If not provided, the full name is returned.
6
- *
7
- * @throws if the provided month number is not a valid month.
8
- *
9
- * @example ```ts
10
- * monthNameDA(9) //=> 'September'
11
- * monthNameDA(9, 3) //=> 'Sep'
12
- * monthNameDA(9, 4) //=> 'Sept'
13
- * monthNameDA(5, 4) //=> 'Maj' // The full name is not long enough to be shortened.
14
- * ```
15
- */
16
- export declare function monthNameDa(month: number, maxLength?: number): string;
17
- //# sourceMappingURL=monthNameDa.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"monthNameDa.d.ts","sourceRoot":"","sources":["../../../../../packages/date/src/lib/monthNameDa.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;;;;;GAcG;AACH,wBAAgB,WAAW,CAAC,KAAK,EAAE,MAAM,EAAE,SAAS,CAAC,EAAE,MAAM,GAAG,MAAM,CAKrE"}
@@ -1,43 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.monthNameDa = void 0;
4
- const assertValidDateMonth_1 = require("./assertValidDateMonth");
5
- /**
6
- * Returns the name, in Danish language, of the month corresponding to the provided month number.
7
- *
8
- * @param month - A month number between 1 and 12.
9
- * @param maxLength - The maximum length of the returned string. If not provided, the full name is returned.
10
- *
11
- * @throws if the provided month number is not a valid month.
12
- *
13
- * @example ```ts
14
- * monthNameDA(9) //=> 'September'
15
- * monthNameDA(9, 3) //=> 'Sep'
16
- * monthNameDA(9, 4) //=> 'Sept'
17
- * monthNameDA(5, 4) //=> 'Maj' // The full name is not long enough to be shortened.
18
- * ```
19
- */
20
- function monthNameDa(month, maxLength) {
21
- (0, assertValidDateMonth_1.assertValidDateMonth)(month);
22
- const fullName = MONTH_NAMES_DA[month];
23
- if (maxLength === undefined)
24
- return fullName;
25
- return fullName.substring(0, maxLength);
26
- }
27
- exports.monthNameDa = monthNameDa;
28
- const MONTH_NAMES_DA = [
29
- '',
30
- 'Januar',
31
- 'Februar',
32
- 'Marts',
33
- 'April',
34
- 'Maj',
35
- 'Juni',
36
- 'Juli',
37
- 'August',
38
- 'September',
39
- 'Oktober',
40
- 'November',
41
- 'December',
42
- ];
43
- //# sourceMappingURL=monthNameDa.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"monthNameDa.js","sourceRoot":"","sources":["../../../../../packages/date/src/lib/monthNameDa.ts"],"names":[],"mappings":";;;AAAA,iEAA6D;AAE7D;;;;;;;;;;;;;;GAcG;AACH,SAAgB,WAAW,CAAC,KAAa,EAAE,SAAkB;IAC3D,IAAA,2CAAoB,EAAC,KAAK,CAAC,CAAA;IAC3B,MAAM,QAAQ,GAAG,cAAc,CAAC,KAAK,CAAC,CAAA;IACtC,IAAI,SAAS,KAAK,SAAS;QAAE,OAAO,QAAQ,CAAA;IAC5C,OAAO,QAAQ,CAAC,SAAS,CAAC,CAAC,EAAE,SAAS,CAAC,CAAA;AACzC,CAAC;AALD,kCAKC;AAED,MAAM,cAAc,GAAG;IACrB,EAAE;IACF,QAAQ;IACR,SAAS;IACT,OAAO;IACP,OAAO;IACP,KAAK;IACL,MAAM;IACN,MAAM;IACN,QAAQ;IACR,WAAW;IACX,SAAS;IACT,UAAU;IACV,UAAU;CACX,CAAA"}
@@ -1,17 +0,0 @@
1
- /**
2
- * Returns the name, in English language, of the month corresponding to the provided month number.
3
- *
4
- * @param month - A month number between 1 and 12.
5
- * @param maxLength - The maximum length of the returned string. If not provided, the full name is returned.
6
- *
7
- * @throws if the provided month number is not a valid month.
8
- *
9
- * @example ```ts
10
- * monthNameEN(9) //=> 'September'
11
- * monthNameEN(9, 3) //=> 'Sep'
12
- * monthNameEN(9, 4) //=> 'Sept'
13
- * monthNameDA(5, 4) //=> 'May' // The full name is not long enough to be shortened.
14
- * ```
15
- */
16
- export declare function monthNameEn(month: number, maxLength?: number): string;
17
- //# sourceMappingURL=monthNameEn.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"monthNameEn.d.ts","sourceRoot":"","sources":["../../../../../packages/date/src/lib/monthNameEn.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;;;;;GAcG;AACH,wBAAgB,WAAW,CAAC,KAAK,EAAE,MAAM,EAAE,SAAS,CAAC,EAAE,MAAM,GAAG,MAAM,CAKrE"}
@@ -1,43 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.monthNameEn = void 0;
4
- const assertValidDateMonth_1 = require("./assertValidDateMonth");
5
- /**
6
- * Returns the name, in English language, of the month corresponding to the provided month number.
7
- *
8
- * @param month - A month number between 1 and 12.
9
- * @param maxLength - The maximum length of the returned string. If not provided, the full name is returned.
10
- *
11
- * @throws if the provided month number is not a valid month.
12
- *
13
- * @example ```ts
14
- * monthNameEN(9) //=> 'September'
15
- * monthNameEN(9, 3) //=> 'Sep'
16
- * monthNameEN(9, 4) //=> 'Sept'
17
- * monthNameDA(5, 4) //=> 'May' // The full name is not long enough to be shortened.
18
- * ```
19
- */
20
- function monthNameEn(month, maxLength) {
21
- (0, assertValidDateMonth_1.assertValidDateMonth)(month);
22
- const fullName = MONTH_NAMES_EN[month];
23
- if (maxLength === undefined)
24
- return fullName;
25
- return fullName.substring(0, maxLength);
26
- }
27
- exports.monthNameEn = monthNameEn;
28
- const MONTH_NAMES_EN = [
29
- '',
30
- 'January',
31
- 'February',
32
- 'March',
33
- 'April',
34
- 'May',
35
- 'June',
36
- 'July',
37
- 'August',
38
- 'September',
39
- 'October',
40
- 'November',
41
- 'December',
42
- ];
43
- //# sourceMappingURL=monthNameEn.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"monthNameEn.js","sourceRoot":"","sources":["../../../../../packages/date/src/lib/monthNameEn.ts"],"names":[],"mappings":";;;AAAA,iEAA6D;AAE7D;;;;;;;;;;;;;;GAcG;AACH,SAAgB,WAAW,CAAC,KAAa,EAAE,SAAkB;IAC3D,IAAA,2CAAoB,EAAC,KAAK,CAAC,CAAA;IAC3B,MAAM,QAAQ,GAAG,cAAc,CAAC,KAAK,CAAC,CAAA;IACtC,IAAI,SAAS,KAAK,SAAS;QAAE,OAAO,QAAQ,CAAA;IAC5C,OAAO,QAAQ,CAAC,SAAS,CAAC,CAAC,EAAE,SAAS,CAAC,CAAA;AACzC,CAAC;AALD,kCAKC;AAED,MAAM,cAAc,GAAG;IACrB,EAAE;IACF,SAAS;IACT,UAAU;IACV,OAAO;IACP,OAAO;IACP,KAAK;IACL,MAAM;IACN,MAAM;IACN,QAAQ;IACR,WAAW;IACX,SAAS;IACT,UAAU;IACV,UAAU;CACX,CAAA"}
@@ -1,13 +0,0 @@
1
- /**
2
- * Calculates the number of months that have passed since the provided date.
3
- * @param date The date from which to calculate the number of passed months.
4
- * @returns The number of months that have passed since the provided date.
5
- * @example ```ts
6
- * new Date(2020, 0, 1);;
7
- * //=> {date}
8
- * monthsSinceDate(new Date(2020, 0, 1));;
9
- * //=> {number of months since January 1, 2020}
10
- * ```
11
- */
12
- export declare function monthsSinceDate(date: Date | number): number;
13
- //# sourceMappingURL=monthsSinceDate.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"monthsSinceDate.d.ts","sourceRoot":"","sources":["../../../../../packages/date/src/lib/monthsSinceDate.ts"],"names":[],"mappings":"AAGA;;;;;;;;;;GAUG;AACH,wBAAgB,eAAe,CAAC,IAAI,EAAE,IAAI,GAAG,MAAM,GAAG,MAAM,CAE3D"}
@@ -1,21 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.monthsSinceDate = void 0;
4
- const MS_IN_MONTH_1 = require("./constants/MS_IN_MONTH");
5
- const msSinceDate_1 = require("./msSinceDate");
6
- /**
7
- * Calculates the number of months that have passed since the provided date.
8
- * @param date The date from which to calculate the number of passed months.
9
- * @returns The number of months that have passed since the provided date.
10
- * @example ```ts
11
- * new Date(2020, 0, 1);;
12
- * //=> {date}
13
- * monthsSinceDate(new Date(2020, 0, 1));;
14
- * //=> {number of months since January 1, 2020}
15
- * ```
16
- */
17
- function monthsSinceDate(date) {
18
- return (0, msSinceDate_1.msSinceDate)(date) / MS_IN_MONTH_1.MS_IN_MONTH;
19
- }
20
- exports.monthsSinceDate = monthsSinceDate;
21
- //# sourceMappingURL=monthsSinceDate.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"monthsSinceDate.js","sourceRoot":"","sources":["../../../../../packages/date/src/lib/monthsSinceDate.ts"],"names":[],"mappings":";;;AAAA,yDAAqD;AACrD,+CAA2C;AAE3C;;;;;;;;;;GAUG;AACH,SAAgB,eAAe,CAAC,IAAmB;IACjD,OAAO,IAAA,yBAAW,EAAC,IAAI,CAAC,GAAG,yBAAW,CAAA;AACxC,CAAC;AAFD,0CAEC"}
@@ -1,12 +0,0 @@
1
- /**
2
- * Calculates the number of milliseconds that have passed since the provided date.
3
- * @param date The date from which to calculate the elapsed time.
4
- * @throws If the provided date is not a Date object or an integer.
5
- * @returns The number of milliseconds that have passed since the provided date.
6
- * @example ```ts
7
- * msSinceDate(new Date('2020-01-01'));;
8
- * //=> {number of milliseconds since 2020-01-01}
9
- * ```
10
- */
11
- export declare function msSinceDate(date: Date | number): number;
12
- //# sourceMappingURL=msSinceDate.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"msSinceDate.d.ts","sourceRoot":"","sources":["../../../../../packages/date/src/lib/msSinceDate.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AACH,wBAAgB,WAAW,CAAC,IAAI,EAAE,IAAI,GAAG,MAAM,GAAG,MAAM,CAQvD"}