@unicom-cloud/utils 0.1.10 → 0.1.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (206) hide show
  1. package/caseName.js +11 -0
  2. package/className.js +5 -0
  3. package/clipboardCopy.js +6 -0
  4. package/constant.js +4 -0
  5. package/contentDisposition.js +7 -0
  6. package/cookie.js +7 -0
  7. package/date/convertTime.js +61 -0
  8. package/date/index.js +22 -0
  9. package/date.js +9 -0
  10. package/decimal.js +5 -0
  11. package/eventEmitter.js +4 -0
  12. package/file.js +6 -0
  13. package/filesize.js +8 -0
  14. package/index.js +56 -46
  15. package/invariant.js +4 -0
  16. package/is.js +92 -0
  17. package/lunar/index.js +36 -0
  18. package/lunar/lib/Holiday.js +42 -0
  19. package/lunar/lib/HolidayUtil.js +128 -0
  20. package/lunar/lib/I18n.js +1005 -0
  21. package/lunar/lib/JieQi.js +40 -0
  22. package/lunar/lib/Lunar.js +1035 -0
  23. package/lunar/lib/LunarMonth.js +150 -0
  24. package/lunar/lib/LunarTime.js +138 -0
  25. package/lunar/lib/LunarUtil.js +1752 -0
  26. package/lunar/lib/LunarYear.js +616 -0
  27. package/lunar/lib/ShouXingUtil.js +6915 -0
  28. package/lunar/lib/Solar.js +311 -0
  29. package/lunar/lib/SolarHalfYear.js +45 -0
  30. package/lunar/lib/SolarMonth.js +55 -0
  31. package/lunar/lib/SolarSeason.js +42 -0
  32. package/lunar/lib/SolarUtil.js +256 -0
  33. package/lunar/lib/SolarWeek.js +153 -0
  34. package/lunar/lib/SolarYear.js +35 -0
  35. package/lunar/lib/index.js +35 -0
  36. package/lunar.js +36 -0
  37. package/math.js +9 -0
  38. package/md5.js +4 -0
  39. package/mock.js +8 -0
  40. package/normalizeWheel.js +6 -0
  41. package/number-to-chinese/index.js +72 -0
  42. package/numberToChinese.js +4 -0
  43. package/nzh.js +4 -0
  44. package/object-keys-sort/index.js +7 -0
  45. package/objectKeysSort.js +2 -5
  46. package/package.json +1 -1
  47. package/random.js +15 -0
  48. package/screenfull.js +4 -0
  49. package/snapdom/src/api/preCache.js +26 -36
  50. package/snapdom/src/api/snapdom.js +78 -61
  51. package/snapdom/src/core/capture.js +54 -54
  52. package/snapdom/src/core/prepare.js +46 -37
  53. package/snapdom/src/modules/fonts.js +90 -92
  54. package/snapdom/src/modules/iconFonts.js +28 -0
  55. package/snapdom/src/modules/images.js +6 -6
  56. package/snapdom/src/modules/pseudo.js +51 -49
  57. package/snapdom/src/modules/styles.js +27 -7
  58. package/snapdom/src/modules/svgDefs.js +26 -0
  59. package/snapdom/src/utils/helpers.js +150 -103
  60. package/snapdom.js +6 -0
  61. package/tinycolor/index.js +46 -0
  62. package/tinycolor/src/conversion.js +143 -0
  63. package/tinycolor/src/css-color-names.js +153 -0
  64. package/tinycolor/src/format-input.js +77 -0
  65. package/tinycolor/src/from-ratio.js +21 -0
  66. package/tinycolor/src/index.js +404 -0
  67. package/tinycolor/src/random.js +221 -0
  68. package/tinycolor/src/readability.js +37 -0
  69. package/tinycolor/src/to-ms-filter.js +15 -0
  70. package/tinycolor/src/util.js +32 -0
  71. package/tinycolor.js +46 -0
  72. package/tree/index.js +10 -8
  73. package/tree/searchTree.js +54 -0
  74. package/tree.js +13 -0
  75. package/turboStream.js +6 -0
  76. package/types/case-name/index.d.ts +11 -0
  77. package/types/class-name/index.d.ts +2 -0
  78. package/types/clipboard-copy/index.d.ts +2 -0
  79. package/types/constant/address.d.ts +14 -0
  80. package/types/constant/chineseCharacters.d.ts +2 -0
  81. package/types/constant/constellations.d.ts +2 -0
  82. package/types/constant/domain.d.ts +2 -0
  83. package/types/constant/identity.d.ts +2 -0
  84. package/types/constant/index.d.ts +1 -0
  85. package/types/constant/keyboardCode.d.ts +158 -0
  86. package/types/constant/licensePlate.d.ts +2 -0
  87. package/types/constant/name.d.ts +4 -0
  88. package/types/constant/platform.d.ts +11 -0
  89. package/types/constant/protocol.d.ts +2 -0
  90. package/types/constant/ui.d.ts +14 -0
  91. package/types/content-disposition/index.d.ts +10 -0
  92. package/types/cookie/index.d.ts +4 -0
  93. package/types/cookie/src/index.d.ts +114 -0
  94. package/types/date/convertTime.d.ts +32 -0
  95. package/types/date/index.d.ts +4 -0
  96. package/types/decimal/decimal.d.ts +4 -0
  97. package/types/decimal/index.d.ts +1 -0
  98. package/types/event-emitter/index.d.ts +17 -0
  99. package/types/file/fileToURL.d.ts +2 -0
  100. package/types/file/index.d.ts +3 -0
  101. package/types/file/saveAs.d.ts +2 -0
  102. package/types/filesize/index.d.ts +2 -0
  103. package/types/filesize/src/constants.d.ts +42 -0
  104. package/types/filesize/src/filesize.d.ts +47 -0
  105. package/types/index.d.ts +25 -0
  106. package/types/invariant/index.d.ts +2 -0
  107. package/types/is/index.d.ts +53 -0
  108. package/types/lunar/index.d.ts +3 -0
  109. package/types/lunar/lib/Holiday.d.ts +17 -0
  110. package/types/lunar/lib/HolidayUtil.d.ts +23 -0
  111. package/types/lunar/lib/I18n.d.ts +23 -0
  112. package/types/lunar/lib/JieQi.d.ts +15 -0
  113. package/types/lunar/lib/Lunar.d.ts +245 -0
  114. package/types/lunar/lib/LunarMonth.d.ts +35 -0
  115. package/types/lunar/lib/LunarTime.d.ts +40 -0
  116. package/types/lunar/lib/LunarUtil.d.ts +128 -0
  117. package/types/lunar/lib/LunarYear.d.ts +61 -0
  118. package/types/lunar/lib/ShouXingUtil.d.ts +38 -0
  119. package/types/lunar/lib/Solar.d.ts +51 -0
  120. package/types/lunar/lib/SolarHalfYear.d.ts +15 -0
  121. package/types/lunar/lib/SolarMonth.d.ts +16 -0
  122. package/types/lunar/lib/SolarSeason.d.ts +15 -0
  123. package/types/lunar/lib/SolarUtil.d.ts +20 -0
  124. package/types/lunar/lib/SolarWeek.d.ts +23 -0
  125. package/types/lunar/lib/SolarYear.d.ts +12 -0
  126. package/types/lunar/lib/index.d.ts +17 -0
  127. package/types/math/index.d.ts +11 -0
  128. package/types/md5/index.d.ts +2 -0
  129. package/types/mock/MockWebSocket.d.ts +17 -0
  130. package/types/mock/MockXMLHttpRequest.d.ts +17 -0
  131. package/types/mock/index.d.ts +2 -0
  132. package/types/normalize-wheel/ExecutionEnvironment.d.ts +9 -0
  133. package/types/normalize-wheel/UserAgent_DEPRECATED.d.ts +86 -0
  134. package/types/normalize-wheel/index.d.ts +115 -0
  135. package/types/normalize-wheel/isEventSupported.d.ts +16 -0
  136. package/types/number-to-chinese/index.d.ts +11 -0
  137. package/types/nzh/cn.d.ts +8 -0
  138. package/types/nzh/hk.d.ts +8 -0
  139. package/types/nzh/index.d.ts +1 -0
  140. package/types/nzh/nzh.d.ts +36 -0
  141. package/types/nzh/src/autoGet.d.ts +8 -0
  142. package/types/nzh/src/index.d.ts +34 -0
  143. package/types/nzh/src/langs/cn_b.d.ts +10 -0
  144. package/types/nzh/src/langs/cn_s.d.ts +7 -0
  145. package/types/nzh/src/langs/hk_b.d.ts +10 -0
  146. package/types/nzh/src/langs/hk_s.d.ts +7 -0
  147. package/types/nzh/src/utils.d.ts +65 -0
  148. package/types/object-keys-sort/index.d.ts +4 -0
  149. package/types/random/address.d.ts +8 -0
  150. package/types/random/constellation.d.ts +2 -0
  151. package/types/random/image.d.ts +5 -0
  152. package/types/random/index.d.ts +40 -0
  153. package/types/random/licensePlate.d.ts +2 -0
  154. package/types/random/name.d.ts +9 -0
  155. package/types/random/number.d.ts +6 -0
  156. package/types/random/text.d.ts +13 -0
  157. package/types/random/time.d.ts +2 -0
  158. package/types/random/web.d.ts +11 -0
  159. package/types/screenfull/index.d.ts +10 -0
  160. package/types/snapdom/index.d.ts +1 -0
  161. package/types/snapdom/src/api/preCache.d.ts +8 -0
  162. package/types/snapdom/src/api/snapdom.d.ts +26 -0
  163. package/types/snapdom/src/core/cache.d.ts +11 -0
  164. package/types/snapdom/src/core/capture.d.ts +17 -0
  165. package/types/snapdom/src/core/clone.d.ts +11 -0
  166. package/types/snapdom/src/core/prepare.d.ts +8 -0
  167. package/types/snapdom/src/index.browser.d.ts +1 -0
  168. package/types/snapdom/src/index.d.ts +2 -0
  169. package/types/snapdom/src/modules/background.d.ts +10 -0
  170. package/types/snapdom/src/modules/fonts.d.ts +23 -0
  171. package/types/snapdom/src/modules/iconFonts.d.ts +2 -0
  172. package/types/snapdom/src/modules/images.d.ts +8 -0
  173. package/types/snapdom/src/modules/pseudo.d.ts +12 -0
  174. package/types/snapdom/src/modules/styles.d.ts +1 -0
  175. package/types/snapdom/src/modules/svgDefs.d.ts +19 -0
  176. package/types/snapdom/src/utils/cssTools.d.ts +38 -0
  177. package/types/snapdom/src/utils/helpers.d.ts +71 -0
  178. package/types/tinycolor/index.d.ts +2 -0
  179. package/types/tinycolor/src/conversion.d.ts +79 -0
  180. package/types/tinycolor/src/css-color-names.d.ts +4 -0
  181. package/types/tinycolor/src/format-input.d.ts +38 -0
  182. package/types/tinycolor/src/from-ratio.d.ts +14 -0
  183. package/types/tinycolor/src/index.d.ts +214 -0
  184. package/types/tinycolor/src/interfaces.d.ts +57 -0
  185. package/types/tinycolor/src/public_api.d.ts +10 -0
  186. package/types/tinycolor/src/random.d.ts +24 -0
  187. package/types/tinycolor/src/readability.d.ts +46 -0
  188. package/types/tinycolor/src/to-ms-filter.d.ts +5 -0
  189. package/types/tinycolor/src/umd_api.d.ts +22 -0
  190. package/types/tinycolor/src/util.d.ts +36 -0
  191. package/types/tree/index.d.ts +9 -0
  192. package/types/tree/searchTree.d.ts +20 -0
  193. package/types/turbo-stream/index.d.ts +1 -0
  194. package/types/turbo-stream/src/decode.d.ts +7 -0
  195. package/types/turbo-stream/src/encode.d.ts +27 -0
  196. package/types/turbo-stream/src/shared.d.ts +107 -0
  197. package/types/turbo-stream/src/turbo-stream.d.ts +4 -0
  198. package/types/ui-color/compareColorByRange.d.ts +2 -0
  199. package/types/ui-color/index.d.ts +183 -0
  200. package/types/url-toolkit/index.d.ts +2 -0
  201. package/types/url-toolkit/src/url-toolkit.d.ts +18 -0
  202. package/ui-color/compareColorByRange.js +9 -0
  203. package/ui-color/index.js +155 -0
  204. package/uiColor.js +28 -0
  205. package/urlToolkit.js +8 -0
  206. package/dayjs/index.js +0 -15
package/caseName.js ADDED
@@ -0,0 +1,11 @@
1
+ import "lodash/camelCase";
2
+ import "lodash/capitalize";
3
+ import "lodash/kebabCase";
4
+ import "lodash/lowerFirst";
5
+ import "lodash/snakeCase";
6
+ import "lodash/startCase";
7
+ import "lodash/upperFirst";
8
+ import { default as d } from "./case-name/index.js";
9
+ export {
10
+ d as default
11
+ };
package/className.js ADDED
@@ -0,0 +1,5 @@
1
+ import "lodash/isPlainObject";
2
+ import { default as e } from "./class-name/index.js";
3
+ export {
4
+ e as default
5
+ };
@@ -0,0 +1,6 @@
1
+ import "./is/index.js";
2
+ import "lodash/isString";
3
+ import { default as p } from "./clipboard-copy/index.js";
4
+ export {
5
+ p as default
6
+ };
package/constant.js ADDED
@@ -0,0 +1,4 @@
1
+ import { MATCH_MEDIA_PREFERS_COLOR_SCHEME_DARK as R } from "./constant/index.js";
2
+ export {
3
+ R as MATCH_MEDIA_PREFERS_COLOR_SCHEME_DARK
4
+ };
@@ -0,0 +1,7 @@
1
+ import { default as o, getContentDispositionFromHeader as r, getContentDispositionParametersFilenameFromHeader as i, getContentDispositionParametersFromHeader as n } from "./content-disposition/index.js";
2
+ export {
3
+ o as default,
4
+ r as getContentDispositionFromHeader,
5
+ i as getContentDispositionParametersFilenameFromHeader,
6
+ n as getContentDispositionParametersFromHeader
7
+ };
package/cookie.js ADDED
@@ -0,0 +1,7 @@
1
+ import * as o from "./cookie/src/index.js";
2
+ import { splitCookiesString as t } from "./cookie/index.js";
3
+ export {
4
+ o as cookie,
5
+ o as default,
6
+ t as splitCookiesString
7
+ };
@@ -0,0 +1,61 @@
1
+ const f = {
2
+ millisecond: 1e-3,
3
+ // 1毫秒 = 0.001秒
4
+ second: 1,
5
+ // 1秒 = 1秒
6
+ minute: 60,
7
+ // 1分钟 = 60秒
8
+ hour: 3600,
9
+ // 1小时 = 3600秒
10
+ day: 86400,
11
+ // 1天 = 86400秒
12
+ week: 604800
13
+ // 1周 = 604800秒
14
+ }, r = [
15
+ { name: "年", seconds: 365 * 24 * 60 * 60, max: 1 / 0 },
16
+ // 年没有上限
17
+ { name: "个月", seconds: 30 * 24 * 60 * 60, max: 12 },
18
+ // 月份最大12
19
+ { name: "周", seconds: 7 * 24 * 60 * 60, max: 4 },
20
+ // 周最大4(约1个月)
21
+ { name: "天", seconds: 24 * 60 * 60, max: 7 },
22
+ // 日最大7(1周)
23
+ { name: "小时", seconds: 60 * 60, max: 24 },
24
+ // 小时最大24
25
+ { name: "分钟", seconds: 60, max: 60 },
26
+ // 分钟最大60
27
+ { name: "秒", seconds: 1, max: 60 }
28
+ // 秒最大60
29
+ ];
30
+ function h(a) {
31
+ return a.max !== void 0;
32
+ }
33
+ function x(a, i = {}) {
34
+ const {
35
+ inputUnit: m = "second",
36
+ units: o = r,
37
+ maxUnitCount: c = 1 / 0,
38
+ keepZero: d = !1
39
+ } = i, l = f[m] || 1;
40
+ let e = Math.abs(a) * l;
41
+ const s = [];
42
+ for (const n of o) {
43
+ if (e <= 0 || s.length >= c) break;
44
+ let t = 0;
45
+ if (!h(n))
46
+ t = Math.floor(e / n.seconds), e %= n.seconds;
47
+ else {
48
+ const u = Math.floor(e / n.seconds);
49
+ t = Math.min(u, n.max - 1), e -= t * n.seconds;
50
+ }
51
+ (t !== 0 || d) && s.push(`${t}${n.name}`);
52
+ }
53
+ if (e > 0 && s.length < c) {
54
+ const n = o[o.length - 1];
55
+ s.push(`0${n.name}`);
56
+ }
57
+ return s.length > 0 ? s.join(" ") : `0${o[o.length - 1].name}`;
58
+ }
59
+ export {
60
+ x as default
61
+ };
package/date/index.js ADDED
@@ -0,0 +1,22 @@
1
+ import n from "dayjs";
2
+ import { default as d } from "./convertTime.js";
3
+ function l(a, u) {
4
+ let t = n.duration(a, u || "minutes");
5
+ return [
6
+ { value: t.years(), unit: "年" },
7
+ { value: t.months(), unit: "个月" },
8
+ { value: t.days(), unit: "天" },
9
+ { value: t.hours(), unit: "小时" },
10
+ { value: t.minutes(), unit: "分钟" },
11
+ { value: t.seconds(), unit: "秒" }
12
+ ].filter((e) => e.value > 0).map((e, i, o) => Math.floor(e.value) + e.unit).join("");
13
+ }
14
+ function m(a, u) {
15
+ return n(a || NaN).isValid() ? n(a).format(u || "YYYY-MM-DD HH:mm:ss") : a || "-";
16
+ }
17
+ export {
18
+ d as convertTime,
19
+ l as convertToDurationBasedOnTimeUnits,
20
+ m as dateFormat,
21
+ m as dayjsFormat
22
+ };
package/date.js ADDED
@@ -0,0 +1,9 @@
1
+ import "dayjs";
2
+ import { default as r } from "./date/convertTime.js";
3
+ import { convertToDurationBasedOnTimeUnits as m, dateFormat as d, dateFormat as i } from "./date/index.js";
4
+ export {
5
+ r as convertTime,
6
+ m as convertToDurationBasedOnTimeUnits,
7
+ d as dateFormat,
8
+ i as dayjsFormat
9
+ };
package/decimal.js ADDED
@@ -0,0 +1,5 @@
1
+ import { Decimal as f, default as l } from "./decimal/decimal.js";
2
+ export {
3
+ f as Decimal,
4
+ l as default
5
+ };
@@ -0,0 +1,4 @@
1
+ import { default as o } from "./event-emitter/index.js";
2
+ export {
3
+ o as default
4
+ };
package/file.js ADDED
@@ -0,0 +1,6 @@
1
+ import { fileToURL as r } from "./file/fileToURL.js";
2
+ import { saveAs as m } from "./file/saveAs.js";
3
+ export {
4
+ r as fileToURL,
5
+ m as saveAs
6
+ };
package/filesize.js ADDED
@@ -0,0 +1,8 @@
1
+ import * as s from "./filesize/src/constants.js";
2
+ import { filesize as a, filesize as i, partial as o } from "./filesize/src/filesize.js";
3
+ export {
4
+ a as default,
5
+ i as filesize,
6
+ s as filesizeConstants,
7
+ o as partial
8
+ };
package/index.js CHANGED
@@ -1,52 +1,62 @@
1
+ import * as o from "./date/index.js";
1
2
  import * as e from "./is/index.js";
2
- import * as o from "./math/index.js";
3
+ import * as r from "./math/index.js";
3
4
  import * as t from "./tree/index.js";
4
- import * as r from "./turbo-stream/index.js";
5
- import * as a from "./url-toolkit/index.js";
6
- import { default as p } from "./case-name/index.js";
7
- import { default as l } from "./class-name/index.js";
8
- import { default as d } from "./clipboard-copy/index.js";
9
- import { default as c, getContentDispositionFromHeader as C, getContentDispositionParametersFilenameFromHeader as _, getContentDispositionParametersFromHeader as b } from "./content-disposition/index.js";
10
- import { splitCookiesString as h } from "./cookie/index.js";
11
- import { default as z } from "./decimal/decimal.js";
12
- import { default as F } from "./event-emitter/index.js";
13
- import { fileToURL as v } from "./file/fileToURL.js";
14
- import { saveAs as T } from "./file/saveAs.js";
15
- import * as s from "./filesize/src/constants.js";
16
- import { filesize as N, partial as P } from "./filesize/src/filesize.js";
17
- import { default as A } from "./invariant/index.js";
18
- import { default as K } from "./md5/index.js";
19
- import { default as R } from "./normalize-wheel/index.js";
20
- import { default as W } from "./nzh/nzh.js";
21
- import { default as w } from "./objectKeysSort.js";
22
- import { default as G } from "./screenfull/index.js";
23
- import * as i from "./cookie/src/index.js";
5
+ import * as a from "./turbo-stream/index.js";
6
+ import * as s from "./ui-color/index.js";
7
+ import * as i from "./url-toolkit/index.js";
8
+ import { default as l } from "./case-name/index.js";
9
+ import { default as u } from "./class-name/index.js";
10
+ import { default as C } from "./clipboard-copy/index.js";
11
+ import { default as b, getContentDispositionFromHeader as h, getContentDispositionParametersFilenameFromHeader as T, getContentDispositionParametersFromHeader as g } from "./content-disposition/index.js";
12
+ import { splitCookiesString as y } from "./cookie/index.js";
13
+ import { default as D } from "./decimal/decimal.js";
14
+ import { default as S } from "./event-emitter/index.js";
15
+ import { fileToURL as H } from "./file/fileToURL.js";
16
+ import { saveAs as N } from "./file/saveAs.js";
17
+ import * as m from "./filesize/src/constants.js";
18
+ import { filesize as j, partial as A } from "./filesize/src/filesize.js";
19
+ import { default as K } from "./invariant/index.js";
20
+ import * as p from "./lunar/lib/index.js";
21
+ import { default as U } from "./md5/index.js";
22
+ import { default as $ } from "./normalize-wheel/index.js";
23
+ import { default as w } from "./number-to-chinese/index.js";
24
+ import { default as G } from "./nzh/nzh.js";
25
+ import { default as J } from "./object-keys-sort/index.js";
26
+ import { default as O } from "./screenfull/index.js";
27
+ import { TinyColor as V } from "./tinycolor/src/index.js";
28
+ import * as f from "./cookie/src/index.js";
24
29
  export {
25
- p as caseName,
26
- l as className,
27
- d as clipboardCopy,
28
- c as contentDisposition,
29
- i as cookie,
30
- z as decimal,
31
- F as eventEmitter,
32
- v as fileToURL,
33
- N as filesize,
34
- s as filesizeConstants,
35
- C as getContentDispositionFromHeader,
36
- _ as getContentDispositionParametersFilenameFromHeader,
37
- b as getContentDispositionParametersFromHeader,
38
- A as invariant,
30
+ p as Lunar,
31
+ l as caseName,
32
+ u as className,
33
+ C as clipboardCopy,
34
+ b as contentDisposition,
35
+ f as cookie,
36
+ o as date,
37
+ D as decimal,
38
+ S as eventEmitter,
39
+ H as fileToURL,
40
+ j as filesize,
41
+ m as filesizeConstants,
42
+ h as getContentDispositionFromHeader,
43
+ T as getContentDispositionParametersFilenameFromHeader,
44
+ g as getContentDispositionParametersFromHeader,
45
+ K as invariant,
39
46
  e as is,
40
- o as math,
41
- K as md5,
42
- R as normalizeWheel,
43
- W as nzh,
44
- w as objectKeysSort,
45
- P as partial,
46
- T as saveAs,
47
- G as screenfull,
48
- h as splitCookiesString,
47
+ r as math,
48
+ U as md5,
49
+ $ as normalizeWheel,
50
+ w as numberToChinese,
51
+ G as nzh,
52
+ J as objectKeysSort,
53
+ A as partial,
54
+ N as saveAs,
55
+ O as screenfull,
56
+ y as splitCookiesString,
57
+ V as tinycolor,
49
58
  t as tree,
50
- r as turboStream,
51
- a as urlToolkit
59
+ a as turboStream,
60
+ s as uiColor,
61
+ i as urlToolkit
52
62
  };
package/invariant.js ADDED
@@ -0,0 +1,4 @@
1
+ import { default as o } from "./invariant/index.js";
2
+ export {
3
+ o as default
4
+ };
package/is.js ADDED
@@ -0,0 +1,92 @@
1
+ import { default as t } from "lodash/isArguments";
2
+ import { default as o } from "lodash/isArray";
3
+ import { default as f } from "lodash/isArrayBuffer";
4
+ import { default as l } from "lodash/isArrayLike";
5
+ import { default as m } from "lodash/isArrayLikeObject";
6
+ import { default as d } from "lodash/isBoolean";
7
+ import { default as n } from "lodash/isBuffer";
8
+ import { default as y } from "lodash/isDate";
9
+ import { default as c } from "lodash/isElement";
10
+ import { default as A } from "lodash/isEmpty";
11
+ import { default as g } from "lodash/isEqual";
12
+ import { default as R } from "lodash/isEqualWith";
13
+ import { default as j } from "lodash/isError";
14
+ import { default as B } from "lodash/isFinite";
15
+ import { default as L } from "lodash/isFunction";
16
+ import { default as W } from "lodash/isInteger";
17
+ import { default as I } from "lodash/isLength";
18
+ import { default as D } from "lodash/isMap";
19
+ import { default as V } from "lodash/isMatch";
20
+ import { default as J } from "lodash/isMatchWith";
21
+ import { default as U } from "lodash/isNaN";
22
+ import { default as z } from "lodash/isNative";
23
+ import { default as H } from "lodash/isNil";
24
+ import { default as Q } from "lodash/isNull";
25
+ import { default as Y } from "lodash/isNumber";
26
+ import { default as _ } from "lodash/isObject";
27
+ import { default as ee } from "lodash/isObjectLike";
28
+ import { default as te } from "lodash/isPlainObject";
29
+ import { default as oe } from "lodash/isRegExp";
30
+ import { default as fe } from "lodash/isSafeInteger";
31
+ import { default as le } from "lodash/isSet";
32
+ import { default as me } from "lodash/isString";
33
+ import { default as de } from "lodash/isSymbol";
34
+ import { default as ne } from "lodash/isTypedArray";
35
+ import { default as ye } from "lodash/isUndefined";
36
+ import { default as ce } from "lodash/isWeakMap";
37
+ import { default as Ae } from "lodash/isWeakSet";
38
+ import { isBlob as ge, isColor as Oe, isColor2 as Re, isEmptyArray as he, isEmptyObject as je, isEmptyValue as ke, isFile as Be, isJSON as Ce, isPromise as Le, isReadableByteStreamControllerSupported as Me, isReadableStream as We, isReadableStreamDefaultControllerSupported as Fe, isReadableStreamSupported as Ie, isReadableStreamSymbolAsyncIteratorSupported as qe, isValidColor as De } from "./is/index.js";
39
+ export {
40
+ t as isArguments,
41
+ o as isArray,
42
+ f as isArrayBuffer,
43
+ l as isArrayLike,
44
+ m as isArrayLikeObject,
45
+ ge as isBlob,
46
+ d as isBoolean,
47
+ n as isBuffer,
48
+ Oe as isColor,
49
+ Re as isColor2,
50
+ y as isDate,
51
+ c as isElement,
52
+ A as isEmpty,
53
+ he as isEmptyArray,
54
+ je as isEmptyObject,
55
+ ke as isEmptyValue,
56
+ g as isEqual,
57
+ R as isEqualWith,
58
+ j as isError,
59
+ Be as isFile,
60
+ B as isFinite,
61
+ L as isFunction,
62
+ W as isInteger,
63
+ Ce as isJSON,
64
+ I as isLength,
65
+ D as isMap,
66
+ V as isMatch,
67
+ J as isMatchWith,
68
+ U as isNaN,
69
+ z as isNative,
70
+ H as isNil,
71
+ Q as isNull,
72
+ Y as isNumber,
73
+ _ as isObject,
74
+ ee as isObjectLike,
75
+ te as isPlainObject,
76
+ Le as isPromise,
77
+ Me as isReadableByteStreamControllerSupported,
78
+ We as isReadableStream,
79
+ Fe as isReadableStreamDefaultControllerSupported,
80
+ Ie as isReadableStreamSupported,
81
+ qe as isReadableStreamSymbolAsyncIteratorSupported,
82
+ oe as isRegExp,
83
+ fe as isSafeInteger,
84
+ le as isSet,
85
+ me as isString,
86
+ de as isSymbol,
87
+ ne as isTypedArray,
88
+ ye as isUndefined,
89
+ De as isValidColor,
90
+ ce as isWeakMap,
91
+ Ae as isWeakSet
92
+ };
package/lunar/index.js ADDED
@@ -0,0 +1,36 @@
1
+ import * as r from "./lib/index.js";
2
+ import { Holiday as t } from "./lib/Holiday.js";
3
+ import { HolidayUtil as f } from "./lib/HolidayUtil.js";
4
+ import { I18n as p } from "./lib/I18n.js";
5
+ import { JieQi as l } from "./lib/JieQi.js";
6
+ import { Lunar as n } from "./lib/Lunar.js";
7
+ import { LunarMonth as u } from "./lib/LunarMonth.js";
8
+ import { LunarTime as d } from "./lib/LunarTime.js";
9
+ import { LunarUtil as H } from "./lib/LunarUtil.js";
10
+ import { LunarYear as Y } from "./lib/LunarYear.js";
11
+ import { Solar as y } from "./lib/Solar.js";
12
+ import { SolarHalfYear as k } from "./lib/SolarHalfYear.js";
13
+ import { SolarMonth as J } from "./lib/SolarMonth.js";
14
+ import { SolarSeason as T } from "./lib/SolarSeason.js";
15
+ import { SolarUtil as b } from "./lib/SolarUtil.js";
16
+ import { SolarWeek as g } from "./lib/SolarWeek.js";
17
+ import { SolarYear as q } from "./lib/SolarYear.js";
18
+ export {
19
+ t as Holiday,
20
+ f as HolidayUtil,
21
+ p as I18n,
22
+ l as JieQi,
23
+ n as Lunar,
24
+ u as LunarMonth,
25
+ d as LunarTime,
26
+ H as LunarUtil,
27
+ Y as LunarYear,
28
+ y as Solar,
29
+ k as SolarHalfYear,
30
+ J as SolarMonth,
31
+ T as SolarSeason,
32
+ b as SolarUtil,
33
+ g as SolarWeek,
34
+ q as SolarYear,
35
+ r as default
36
+ };
@@ -0,0 +1,42 @@
1
+ class r {
2
+ _day;
3
+ _name;
4
+ _work;
5
+ _target;
6
+ constructor(t, e, s, _) {
7
+ this._day = r._ymd(t), this._name = e, this._work = s, this._target = r._ymd(_);
8
+ }
9
+ static _ymd(t) {
10
+ return t.indexOf("-") < 0 ? t.substring(0, 4) + "-" + t.substring(4, 6) + "-" + t.substring(6) : t;
11
+ }
12
+ getDay() {
13
+ return this._day;
14
+ }
15
+ setDay(t) {
16
+ this._day = r._ymd(t);
17
+ }
18
+ getName() {
19
+ return this._name;
20
+ }
21
+ setName(t) {
22
+ this._name = t;
23
+ }
24
+ isWork() {
25
+ return this._work;
26
+ }
27
+ setWork(t) {
28
+ this._work = t;
29
+ }
30
+ getTarget() {
31
+ return this._target;
32
+ }
33
+ setTarget(t) {
34
+ this._target = r._ymd(t);
35
+ }
36
+ toString() {
37
+ return this._day + " " + this._name + (this._work ? "调休" : "") + " " + this._target;
38
+ }
39
+ }
40
+ export {
41
+ r as Holiday
42
+ };
@@ -0,0 +1,128 @@
1
+ import { Holiday as E } from "./Holiday.js";
2
+ class n {
3
+ static NAMES = [
4
+ "元旦节",
5
+ "春节",
6
+ "清明节",
7
+ "劳动节",
8
+ "端午节",
9
+ "中秋节",
10
+ "国庆节",
11
+ "国庆中秋",
12
+ "抗战胜利日"
13
+ ];
14
+ static DATA = "200112290020020101200112300020020101200201010120020101200201020120020101200201030120020101200202091020020212200202101020020212200202121120020212200202131120020212200202141120020212200202151120020212200202161120020212200202171120020212200202181120020212200204273020020501200204283020020501200205013120020501200205023120020501200205033120020501200205043120020501200205053120020501200205063120020501200205073120020501200209286020021001200209296020021001200210016120021001200210026120021001200210036120021001200210046120021001200210056120021001200210066120021001200210076120021001200301010120030101200302011120030201200302021120030201200302031120030201200302041120030201200302051120030201200302061120030201200302071120030201200302081020030201200302091020030201200304263020030501200304273020030501200305013120030501200305023120030501200305033120030501200305043120030501200305053120030501200305063120030501200305073120030501200309276020031001200309286020031001200310016120031001200310026120031001200310036120031001200310046120031001200310056120031001200310066120031001200310076120031001200401010120040101200401171020040122200401181020040122200401221120040122200401231120040122200401241120040122200401251120040122200401261120040122200401271120040122200401281120040122200405013120040501200405023120040501200405033120040501200405043120040501200405053120040501200405063120040501200405073120040501200405083020040501200405093020040501200410016120041001200410026120041001200410036120041001200410046120041001200410056120041001200410066120041001200410076120041001200410096020041001200410106020041001200501010120050101200501020120050101200501030120050101200502051020050209200502061020050209200502091120050209200502101120050209200502111120050209200502121120050209200502131120050209200502141120050209200502151120050209200504303020050501200505013120050501200505023120050501200505033120050501200505043120050501200505053120050501200505063120050501200505073120050501200505083020050501200510016120051001200510026120051001200510036120051001200510046120051001200510056120051001200510066120051001200510076120051001200510086020051001200510096020051001200512310020060101200601010120060101200601020120060101200601030120060101200601281020060129200601291120060129200601301120060129200601311120060129200602011120060129200602021120060129200602031120060129200602041120060129200602051020060129200604293020060501200604303020060501200605013120060501200605023120060501200605033120060501200605043120060501200605053120060501200605063120060501200605073120060501200609306020061001200610016120061001200610026120061001200610036120061001200610046120061001200610056120061001200610066120061001200610076120061001200610086020061001200612300020070101200612310020070101200701010120070101200701020120070101200701030120070101200702171020070218200702181120070218200702191120070218200702201120070218200702211120070218200702221120070218200702231120070218200702241120070218200702251020070218200704283020070501200704293020070501200705013120070501200705023120070501200705033120070501200705043120070501200705053120070501200705063120070501200705073120070501200709296020071001200709306020071001200710016120071001200710026120071001200710036120071001200710046120071001200710056120071001200710066120071001200710076120071001200712290020080101200712300120080101200712310120080101200801010120080101200802021020080206200802031020080206200802061120080206200802071120080206200802081120080206200802091120080206200802101120080206200802111120080206200802121120080206200804042120080404200804052120080404200804062120080404200805013120080501200805023120080501200805033120080501200805043020080501200806074120080608200806084120080608200806094120080608200809135120080914200809145120080914200809155120080914200809276020081001200809286020081001200809296120081001200809306120081001200810016120081001200810026120081001200810036120081001200810046120081001200810056120081001200901010120090101200901020120090101200901030120090101200901040020090101200901241020090125200901251120090125200901261120090125200901271120090125200901281120090125200901291120090125200901301120090125200901311120090125200902011020090125200904042120090404200904052120090404200904062120090404200905013120090501200905023120090501200905033120090501200905284120090528200905294120090528200905304120090528200905314020090528200909276020091001200910016120091001200910026120091001200910036120091001200910046120091001200910055120091003200910065120091003200910075120091003200910085120091003200910105020091003201001010120100101201001020120100101201001030120100101201002131120100213201002141120100213201002151120100213201002161120100213201002171120100213201002181120100213201002191120100213201002201020100213201002211020100213201004032120100405201004042120100405201004052120100405201005013120100501201005023120100501201005033120100501201006124020100616201006134020100616201006144120100616201006154120100616201006164120100616201009195020100922201009225120100922201009235120100922201009245120100922201009255020100922201009266020101001201010016120101001201010026120101001201010036120101001201010046120101001201010056120101001201010066120101001201010076120101001201010096020101001201101010120110101201101020120110101201101030120110101201101301020110203201102021120110203201102031120110203201102041120110203201102051120110203201102061120110203201102071120110203201102081120110203201102121020110203201104022020110405201104032120110405201104042120110405201104052120110405201104303120110501201105013120110501201105023120110501201106044120110606201106054120110606201106064120110606201109105120110912201109115120110912201109125120110912201110016120111001201110026120111001201110036120111001201110046120111001201110056120111001201110066120111001201110076120111001201110086020111001201110096020111001201112310020120101201201010120120101201201020120120101201201030120120101201201211020120123201201221120120123201201231120120123201201241120120123201201251120120123201201261120120123201201271120120123201201281120120123201201291020120123201203312020120404201204012020120404201204022120120404201204032120120404201204042120120404201204283020120501201204293120120501201204303120120501201205013120120501201205023020120501201206224120120623201206234120120623201206244120120623201209295020120930201209305120120930201210016120121001201210026120121001201210036120121001201210046120121001201210056120121001201210066120121001201210076120121001201210086020121001201301010120130101201301020120130101201301030120130101201301050020130101201301060020130101201302091120130210201302101120130210201302111120130210201302121120130210201302131120130210201302141120130210201302151120130210201302161020130210201302171020130210201304042120130404201304052120130404201304062120130404201304273020130501201304283020130501201304293120130501201304303120130501201305013120130501201306084020130612201306094020130612201306104120130612201306114120130612201306124120130612201309195120130919201309205120130919201309215120130919201309225020130919201309296020131001201310016120131001201310026120131001201310036120131001201310046120131001201310056120131001201310066120131001201310076120131001201401010120140101201401261020140131201401311120140131201402011120140131201402021120140131201402031120140131201402041120140131201402051120140131201402061120140131201402081020140131201404052120140405201404062120140405201404072120140405201405013120140501201405023120140501201405033120140501201405043020140501201405314120140602201406014120140602201406024120140602201409065120140908201409075120140908201409085120140908201409286020141001201410016120141001201410026120141001201410036120141001201410046120141004201410056120141001201410066120141001201410076120141001201410116020141001201501010120150101201501020120150101201501030120150101201501040020150101201502151020150219201502181120150219201502191120150219201502201120150219201502211120150219201502221120150219201502231120150219201502241120150219201502281020150219201504042120150405201504052120150405201504062120150405201505013120150501201505023120150501201505033120150501201506204120150620201506214120150620201506224120150620201509038120150903201509048120150903201509058120150903201509068020150903201509265120150927201509275120150927201510016120151001201510026120151001201510036120151001201510046120151004201510056120151001201510066120151001201510076120151001201510106020151001201601010120160101201601020120160101201601030120160101201602061020160208201602071120160208201602081120160208201602091120160208201602101120160208201602111120160208201602121120160208201602131120160208201602141020160208201604022120160404201604032120160404201604042120160404201604303120160501201605013120160501201605023120160501201606094120160609201606104120160609201606114120160609201606124020160609201609155120160915201609165120160915201609175120160915201609185020160915201610016120161001201610026120161001201610036120161001201610046120161001201610056120161001201610066120161001201610076120161001201610086020161001201610096020161001201612310120170101201701010120170101201701020120170101201701221020170128201701271120170128201701281120170128201701291120170128201701301120170128201701311120170128201702011120170128201702021120170128201702041020170128201704012020170404201704022120170404201704032120170404201704042120170404201704293120170501201704303120170501201705013120170501201705274020170530201705284120170530201705294120170530201705304120170530201709306020171001201710016120171001201710026120171001201710036120171001201710045120171004201710056120171001201710066120171001201710076120171001201710086120171001201712300120180101201712310120180101201801010120180101201802111020180216201802151120180216201802161120180216201802171120180216201802181120180216201802191120180216201802201120180216201802211120180216201802241020180216201804052120180405201804062120180405201804072120180405201804082020180405201804283020180501201804293120180501201804303120180501201805013120180501201806164120180618201806174120180618201806184120180618201809225120180924201809235120180924201809245120180924201809296020181001201809306020181001201810016120181001201810026120181001201810036120181001201810046120181001201810056120181001201810066120181001201810076120181001201812290020190101201812300120190101201812310120190101201901010120190101201902021020190205201902031020190205201902041120190205201902051120190205201902061120190205201902071120190205201902081120190205201902091120190205201902101120190205201904052120190405201904062120190405201904072120190405201904283020190501201905013120190501201905023120190501201905033120190501201905043120190501201905053020190501201906074120190607201906084120190607201906094120190607201909135120190913201909145120190913201909155120190913201909296020191001201910016120191001201910026120191001201910036120191001201910046120191001201910056120191001201910066120191001201910076120191001201910126020191001202001010120200101202001191020200125202001241120200125202001251120200125202001261120200125202001271120200125202001281120200125202001291120200125202001301120200125202001311120200125202002011120200125202002021120200125202004042120200404202004052120200404202004062120200404202004263020200501202005013120200501202005023120200501202005033120200501202005043120200501202005053120200501202005093020200501202006254120200625202006264120200625202006274120200625202006284020200625202009277020201001202010017120201001202010026120201001202010036120201001202010046120201001202010056120201001202010066120201001202010076120201001202010086120201001202010106020201001202101010120210101202101020120210101202101030120210101202102071020210212202102111120210212202102121120210212202102131120210212202102141120210212202102151120210212202102161120210212202102171120210212202102201020210212202104032120210404202104042120210404202104052120210404202104253020210501202105013120210501202105023120210501202105033120210501202105043120210501202105053120210501202105083020210501202106124120210614202106134120210614202106144120210614202109185020210921202109195120210921202109205120210921202109215120210921202109266020211001202110016120211001202110026120211001202110036120211001202110046120211001202110056120211001202110066120211001202110076120211001202110096020211001202201010120220101202201020120220101202201030120220101202201291020220201202201301020220201202201311120220201202202011120220201202202021120220201202202031120220201202202041120220201202202051120220201202202061120220201202204022020220405202204032120220405202204042120220405202204052120220405202204243020220501202204303120220501202205013120220501202205023120220501202205033120220501202205043120220501202205073020220501202206034120220603202206044120220603202206054120220603202209105120220910202209115120220910202209125120220910202210016120221001202210026120221001202210036120221001202210046120221001202210056120221001202210066120221001202210076120221001202210086020221001202210096020221001202212310120230101202301010120230101202301020120230101202301211120230122202301221120230122202301231120230122202301241120230122202301251120230122202301261120230122202301271120230122202301281020230122202301291020230122202304052120230405202304233020230501202304293120230501202304303120230501202305013120230501202305023120230501202305033120230501202305063020230501202306224120230622202306234120230622202306244120230622202306254020230622202309295120230929202309306120231001202310016120231001202310026120231001202310036120231001202310046120231001202310056120231001202310066120231001202310076020231001202310086020231001202312300120240101202312310120240101202401010120240101202402041020240210202402101120240210202402111120240210202402121120240210202402131120240210202402141120240210202402151120240210202402161120240210202402171120240210202402181020240210202404042120240404202404052120240404202404062120240404202404072020240404202404283020240501202405013120240501202405023120240501202405033120240501202405043120240501202405053120240501202405113020240501202406084120240610202406094120240610202406104120240610202409145020240917202409155120240917202409165120240917202409175120240917202409296020241001202410016120241001202410026120241001202410036120241001202410046120241001202410056120241001202410066120241001202410076120241001202410126020241001202501010120250101202501261020250129202501281120250129202501291120250129202501301120250129202501311120250129202502011120250129202502021120250129202502031120250129202502041120250129202502081020250129202504042120250404202504052120250404202504062120250404202504273020250501202505013120250501202505023120250501202505033120250501202505043120250501202505053120250501202505314120250531202506014120250531202506024120250531202509287020251001202510017120251001202510027120251001202510037120251001202510047120251001202510057120251001202510067120251001202510077120251001202510087120251001202510117020251001";
15
+ static _SIZE = 18;
16
+ static _ZERO = 48;
17
+ static _TAG_REMOVE = "~";
18
+ static _NAMES_IN_USE = n.NAMES;
19
+ static _DATA_IN_USE = n.DATA;
20
+ static _padding(e) {
21
+ return (e < 10 ? "0" : "") + e;
22
+ }
23
+ static _findForward(e) {
24
+ const r = n._DATA_IN_USE.indexOf(e);
25
+ if (r < 0)
26
+ return null;
27
+ let s = n._DATA_IN_USE.substring(r);
28
+ const t = s.length % n._SIZE;
29
+ for (t > 0 && (s = s.substring(t)); s.indexOf(e) !== 0 && s.length >= n._SIZE; )
30
+ s = s.substring(n._SIZE);
31
+ return s;
32
+ }
33
+ static _findBackward(e) {
34
+ const r = n._DATA_IN_USE.lastIndexOf(e);
35
+ if (r < 0)
36
+ return null;
37
+ const s = e.length;
38
+ let t = n._DATA_IN_USE.substring(0, r + s), c = t.length;
39
+ const g = c % n._SIZE;
40
+ for (g > 0 && (t = t.substring(0, c - g)), c = t.length; c - s !== t.lastIndexOf(e) && c >= n._SIZE; )
41
+ t = t.substring(0, c - n._SIZE), c = t.length;
42
+ return t;
43
+ }
44
+ static _buildHolidayForward(e) {
45
+ const r = e.substring(0, 8), s = n._NAMES_IN_USE[e.charCodeAt(8) - n._ZERO], t = e.charCodeAt(9) === n._ZERO, c = e.substring(10, 18);
46
+ return new E(r, s, t, c);
47
+ }
48
+ static _buildHolidayBackward(e) {
49
+ const r = e.length, s = e.substring(r - 18, r - 10), t = n._NAMES_IN_USE[e.charCodeAt(r - 10) - n._ZERO], c = e.charCodeAt(r - 9) === n._ZERO, g = e.substring(r - 8);
50
+ return new E(s, t, c, g);
51
+ }
52
+ static _findHolidaysForward(e) {
53
+ const r = [];
54
+ let s = n._findForward(e);
55
+ if (s == null)
56
+ return r;
57
+ for (; s.indexOf(e) === 0; )
58
+ r.push(n._buildHolidayForward(s)), s = s.substring(n._SIZE);
59
+ return r;
60
+ }
61
+ static _findHolidaysBackward(e) {
62
+ const r = [];
63
+ let s = n._findBackward(e);
64
+ if (s == null)
65
+ return r;
66
+ let t = s.length;
67
+ const c = e.length;
68
+ for (; t - c === s.lastIndexOf(e); )
69
+ r.push(n._buildHolidayBackward(s)), s = s.substring(0, t - n._SIZE), t = s.length;
70
+ return r.reverse(), r;
71
+ }
72
+ static getHoliday(e, r = 0, s = 0) {
73
+ let t;
74
+ return r == 0 || s == 0 ? t = n._findHolidaysForward((e + "").replace(/-/g, "")) : t = n._findHolidaysForward(
75
+ e + n._padding(r) + n._padding(s)
76
+ ), t.length < 1 ? null : t[0];
77
+ }
78
+ static getHolidays(e, r = 0) {
79
+ return r == 0 ? n._findHolidaysForward(
80
+ (e + "").replace(/-/g, "")
81
+ ) : n._findHolidaysForward(
82
+ e + n._padding(r)
83
+ );
84
+ }
85
+ static getHolidaysByTarget(e, r = 0) {
86
+ return r == 0 ? n._findHolidaysBackward(
87
+ (e + "").replace(/-/g, "")
88
+ ) : n._findHolidaysBackward(
89
+ e + n._padding(r)
90
+ );
91
+ }
92
+ static _fixNames(e) {
93
+ e && (n._NAMES_IN_USE = e);
94
+ }
95
+ static _fixData(e) {
96
+ if (!e)
97
+ return;
98
+ const r = [];
99
+ for (; e.length >= n._SIZE; ) {
100
+ const s = e.substring(0, n._SIZE), t = s.substring(0, 8), c = n._TAG_REMOVE == s.substring(8, 9), g = n.getHoliday(t);
101
+ if (!g)
102
+ c || r.push(s);
103
+ else {
104
+ let u = -1;
105
+ for (let f = 0, a = n._NAMES_IN_USE.length; f < a; f++)
106
+ if (n._NAMES_IN_USE[f] === g.getName()) {
107
+ u = f;
108
+ break;
109
+ }
110
+ if (u > -1) {
111
+ const f = t + String.fromCharCode(u + n._ZERO) + (g.isWork() ? "0" : "1") + g.getTarget().replace(/-/g, "");
112
+ n._DATA_IN_USE = n._DATA_IN_USE.replace(
113
+ new RegExp(f, "g"),
114
+ c ? "" : s
115
+ );
116
+ }
117
+ }
118
+ e = e.substring(n._SIZE);
119
+ }
120
+ r.length > 0 && (n._DATA_IN_USE += r.join(""));
121
+ }
122
+ static fix(e, r) {
123
+ r ? (n._fixNames(e), n._fixData(r)) : n._fixData(e);
124
+ }
125
+ }
126
+ export {
127
+ n as HolidayUtil
128
+ };