@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
@@ -0,0 +1,40 @@
1
+ import { LunarUtil as a } from "./LunarUtil.js";
2
+ class h {
3
+ _name;
4
+ _solar;
5
+ _jie;
6
+ _qi;
7
+ constructor(e, _) {
8
+ let i = !1, r = !1, t, s;
9
+ for (t = 0, s = a.JIE_QI.length; t < s; t++)
10
+ if (a.JIE_QI[t] === e) {
11
+ t % 2 == 0 ? r = !0 : i = !0;
12
+ break;
13
+ }
14
+ this._name = e, this._solar = _, this._jie = i, this._qi = r;
15
+ }
16
+ getName() {
17
+ return this._name;
18
+ }
19
+ getSolar() {
20
+ return this._solar;
21
+ }
22
+ setName(e) {
23
+ this._name = e;
24
+ }
25
+ setSolar(e) {
26
+ this._solar = e;
27
+ }
28
+ isJie() {
29
+ return this._jie;
30
+ }
31
+ isQi() {
32
+ return this._qi;
33
+ }
34
+ toString() {
35
+ return this.getName();
36
+ }
37
+ }
38
+ export {
39
+ h as JieQi
40
+ };