@das-fed/upf-utils 6.4.0-dev.237 → 6.4.0-dev.239

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 (217) hide show
  1. package/api-services/es5.d.ts +2 -0
  2. package/api-services/es5.js +2176 -2106
  3. package/api-services/i18n/es5.d.ts +63 -0
  4. package/api-services/index.js +1654 -1602
  5. package/api-services/index.js.gz +0 -0
  6. package/api-services/modules/app-manage/es5.d.ts +2 -0
  7. package/api-services/modules/app-manage/es5.js +2305 -2223
  8. package/api-services/modules/app-manage/index.js +1900 -1830
  9. package/api-services/modules/app-manage/index.js.gz +0 -0
  10. package/api-services/modules/authentication/es5.d.ts +2 -0
  11. package/api-services/modules/authentication/es5.js +2373 -2279
  12. package/api-services/modules/authentication/index.js +1979 -1891
  13. package/api-services/modules/authentication/index.js.gz +0 -0
  14. package/api-services/modules/bems/es5.d.ts +6 -0
  15. package/api-services/modules/bems/es5.js +2190 -2120
  16. package/api-services/modules/bems/index.js +1812 -1760
  17. package/api-services/modules/bems/index.js.gz +0 -0
  18. package/api-services/modules/contract/es5.d.ts +2 -0
  19. package/api-services/modules/contract/es5.js +2305 -2223
  20. package/api-services/modules/contract/index.js +1900 -1830
  21. package/api-services/modules/contract/index.js.gz +0 -0
  22. package/api-services/modules/duty-manage/es5.d.ts +7 -0
  23. package/api-services/modules/duty-manage/es5.js +2190 -2120
  24. package/api-services/modules/duty-manage/index.js +1813 -1761
  25. package/api-services/modules/duty-manage/index.js.gz +0 -0
  26. package/api-services/modules/enterpriseright/es5.d.ts +2 -0
  27. package/api-services/modules/enterpriseright/es5.js +2305 -2223
  28. package/api-services/modules/enterpriseright/index.js +1900 -1830
  29. package/api-services/modules/enterpriseright/index.js.gz +0 -0
  30. package/api-services/modules/es5.d.ts +21 -0
  31. package/api-services/modules/es5.js +1846 -1764
  32. package/api-services/modules/file/es5.d.ts +37 -0
  33. package/api-services/modules/file/es5.js +1900 -1818
  34. package/api-services/modules/file/index.js +1469 -1399
  35. package/api-services/modules/file/index.js.gz +0 -0
  36. package/api-services/modules/gateway-edge/es5.d.ts +2 -0
  37. package/api-services/modules/gateway-edge/es5.js +2365 -2274
  38. package/api-services/modules/gateway-edge/index.js +1973 -1889
  39. package/api-services/modules/gateway-edge/index.js.gz +0 -0
  40. package/api-services/modules/index.js +1374 -1304
  41. package/api-services/modules/index.js.gz +0 -0
  42. package/api-services/modules/iot/es5.d.ts +16 -0
  43. package/api-services/modules/iot/es5.js +2160 -2078
  44. package/api-services/modules/iot/index.js +1765 -1695
  45. package/api-services/modules/iot/index.js.gz +0 -0
  46. package/api-services/modules/justauth/es5.d.ts +3 -0
  47. package/api-services/modules/justauth/es5.js +2370 -2279
  48. package/api-services/modules/justauth/index.js +1975 -1891
  49. package/api-services/modules/justauth/index.js.gz +0 -0
  50. package/api-services/modules/knowledge/es5.d.ts +2 -0
  51. package/api-services/modules/knowledge/es5.js +2303 -2223
  52. package/api-services/modules/knowledge/index.js +1898 -1832
  53. package/api-services/modules/knowledge/index.js.gz +0 -0
  54. package/api-services/modules/link/es5.d.ts +2 -0
  55. package/api-services/modules/link/es5.js +2373 -2279
  56. package/api-services/modules/link/index.js +1979 -1891
  57. package/api-services/modules/link/index.js.gz +0 -0
  58. package/api-services/modules/permission/es5.d.ts +2 -0
  59. package/api-services/modules/permission/es5.js +2386 -2316
  60. package/api-services/modules/permission/index.js +1979 -1927
  61. package/api-services/modules/permission/index.js.gz +0 -0
  62. package/api-services/modules/platformManage/es5.d.ts +14 -0
  63. package/api-services/modules/platformManage/es5.js +2323 -2241
  64. package/api-services/modules/platformManage/index.js +1911 -1841
  65. package/api-services/modules/platformManage/index.js.gz +0 -0
  66. package/api-services/modules/portal/es5.d.ts +2 -0
  67. package/api-services/modules/portal/es5.js +2189 -2119
  68. package/api-services/modules/portal/index.js +1812 -1760
  69. package/api-services/modules/portal/index.js.gz +0 -0
  70. package/api-services/modules/space-manage/es5.d.ts +2 -0
  71. package/api-services/modules/space-manage/es5.js +2189 -2119
  72. package/api-services/modules/space-manage/index.js +1812 -1760
  73. package/api-services/modules/space-manage/index.js.gz +0 -0
  74. package/api-services/modules/super-admin/es5.d.ts +8 -0
  75. package/api-services/modules/super-admin/es5.js +2276 -2191
  76. package/api-services/modules/super-admin/index.js +1875 -1801
  77. package/api-services/modules/super-admin/index.js.gz +0 -0
  78. package/api-services/modules/supplier/es5.d.ts +6 -0
  79. package/api-services/modules/supplier/es5.js +2407 -2334
  80. package/api-services/modules/supplier/index.js +1997 -1941
  81. package/api-services/modules/supplier/index.js.gz +0 -0
  82. package/api-services/modules/supplychain-manage/es5.d.ts +2 -0
  83. package/api-services/modules/supplychain-manage/es5.js +2305 -2223
  84. package/api-services/modules/supplychain-manage/index.js +1900 -1830
  85. package/api-services/modules/supplychain-manage/index.js.gz +0 -0
  86. package/api-services/modules/systemConfiguration/es5.d.ts +2 -0
  87. package/api-services/modules/systemConfiguration/es5.js +2398 -2326
  88. package/api-services/modules/systemConfiguration/index.js +1990 -1934
  89. package/api-services/modules/systemConfiguration/index.js.gz +0 -0
  90. package/api-services/modules/tool/es5.d.ts +2 -0
  91. package/api-services/modules/tool/es5.js +2403 -2330
  92. package/api-services/modules/tool/index.js +1994 -1938
  93. package/api-services/modules/tool/index.js.gz +0 -0
  94. package/api-services/src/create-service/es5.d.ts +1 -0
  95. package/api-services/src/create-service/es5.js +2101 -2019
  96. package/api-services/src/create-service/index.js +1718 -1648
  97. package/api-services/src/create-service/index.js.gz +0 -0
  98. package/atob/es5.d.ts +2 -0
  99. package/common-info/es5.d.ts +48 -0
  100. package/common-info/es5.js +2246 -2229
  101. package/common-info/getIframeUrl/es5.d.ts +9 -0
  102. package/common-info/getInfoFromUrl/es5.d.ts +8 -0
  103. package/common-info/getPermissionMethod/es5.d.ts +77 -0
  104. package/common-info/getPermissionMethod/es5.js +2187 -2107
  105. package/common-info/getPermissionMethod/index.d.ts +27 -9
  106. package/common-info/getPermissionMethod/index.js +1774 -1708
  107. package/common-info/getPermissionMethod/index.js.gz +0 -0
  108. package/common-info/index.d.ts +1 -29
  109. package/common-info/index.js +1811 -1792
  110. package/common-info/index.js.gz +0 -0
  111. package/common-info/set-personal-info/es5.d.ts +5 -0
  112. package/common-info/set-personal-info/es5.js +1073 -997
  113. package/common-info/set-personal-info/index.js +895 -827
  114. package/common-info/set-personal-info/index.js.gz +0 -0
  115. package/common-info/type.d.ts +2 -2
  116. package/common-tools/arr-tools/es5.d.ts +15 -0
  117. package/common-tools/calc-text-width/es5.d.ts +1 -0
  118. package/common-tools/date-format/es5.d.ts +7 -0
  119. package/common-tools/es5.d.ts +15 -0
  120. package/common-tools/es5.js +9 -0
  121. package/common-tools/extract-file-name/es5.d.ts +1 -0
  122. package/common-tools/extract-file-name/es5.js +1074 -998
  123. package/common-tools/extract-file-name/index.js +889 -821
  124. package/common-tools/extract-file-name/index.js.gz +0 -0
  125. package/common-tools/get-file-extension/es5.d.ts +6 -0
  126. package/common-tools/get-url-params/es5.d.ts +46 -0
  127. package/common-tools/handle-data/es5.d.ts +34 -0
  128. package/common-tools/handle-data/es5.js +45 -7
  129. package/common-tools/handle-data/index.d.ts +16 -1
  130. package/common-tools/handle-data/index.js +1 -1
  131. package/common-tools/handle-data/index.js.gz +0 -0
  132. package/common-tools/index.d.ts +1 -0
  133. package/common-tools/index.js +1 -0
  134. package/common-tools/nest-tree-format/es5.d.ts +30 -0
  135. package/common-tools/obj-tools/es5.d.ts +7 -0
  136. package/common-tools/platform-tools/es5.d.ts +19 -0
  137. package/common-tools/queue-promise/es5.d.ts +6 -0
  138. package/common-tools/setHtmlMinWH/es5.d.ts +5 -0
  139. package/common-tools/timezone-format/es5.d.ts +28 -0
  140. package/common-tools/timezone-format/es5.js +140 -0
  141. package/common-tools/timezone-format/index.d.ts +28 -0
  142. package/common-tools/timezone-format/index.js +81 -0
  143. package/common-tools/timezone-format/index.js.gz +0 -0
  144. package/common-tools/update-browser-title/es5.d.ts +1 -0
  145. package/common-tools/update-browser-title/es5.js +1 -1
  146. package/common-tools/update-fav-icon/es5.d.ts +11 -0
  147. package/common-tools/update-fav-icon/es5.js +1 -1
  148. package/config/es5.d.ts +2 -0
  149. package/create-api-service/access-token-auto-refresh/es5.d.ts +20 -0
  150. package/create-api-service/access-token-auto-refresh/es5.js +28 -27
  151. package/create-api-service/access-token-auto-refresh/index.js +27 -26
  152. package/create-api-service/access-token-auto-refresh/index.js.gz +0 -0
  153. package/create-api-service/check-token/es5.d.ts +12 -0
  154. package/create-api-service/check-token/es5.js +1 -1
  155. package/create-api-service/es5.d.ts +8 -0
  156. package/create-api-service/es5.js +2102 -2020
  157. package/create-api-service/i18n/es5.d.ts +39 -0
  158. package/create-api-service/index.js +1719 -1649
  159. package/create-api-service/index.js.gz +0 -0
  160. package/create-api-service/proxy-sso/es5.d.ts +3 -0
  161. package/create-api-service/sso/es5.d.ts +21 -0
  162. package/create-api-service/sso/es5.js +1242 -1166
  163. package/create-api-service/sso/index.js +1006 -938
  164. package/create-api-service/sso/index.js.gz +0 -0
  165. package/create-api-service/token-refresh-shared/es5.d.ts +30 -0
  166. package/create-api-service/token-refresh-shared/es5.js +1125 -1049
  167. package/create-api-service/token-refresh-shared/index.js +927 -859
  168. package/create-api-service/token-refresh-shared/index.js.gz +0 -0
  169. package/curring-http/es5.d.ts +12 -0
  170. package/curring-http/es5.js +1442 -1366
  171. package/curring-http/index.js +1132 -1064
  172. package/curring-http/index.js.gz +0 -0
  173. package/dimple-canvas/es5.d.ts +3 -0
  174. package/directive/auth/es5.d.ts +8 -0
  175. package/directive/clickOutside/es5.d.ts +6 -0
  176. package/directive/clickOutside/es5.js +1 -1
  177. package/directive/es5.d.ts +3 -0
  178. package/directive/hoverInside/es5.d.ts +6 -0
  179. package/directive/hoverInside/es5.js +1 -1
  180. package/directive/utils/es5.d.ts +7 -0
  181. package/directive/utils/es5.js +1 -1
  182. package/dom-check-in/es5.d.ts +6 -0
  183. package/dom-watcher/es5.d.ts +25 -0
  184. package/esm-map.json +32 -7
  185. package/hooks/popup-manager/use-zindex/es5.d.ts +3 -0
  186. package/i18n-bridge/es5.d.ts +10 -0
  187. package/index.d.ts +1 -0
  188. package/index.js +1 -0
  189. package/load-js/es5.d.ts +3 -0
  190. package/nextTiken/es5.d.ts +12 -0
  191. package/oss/es5.d.ts +2 -0
  192. package/package.json +4 -3
  193. package/pinyin-first-character/es5.d.ts +2 -0
  194. package/pinyin-first-character/es5.js +47 -45
  195. package/pinyin-first-character/index.js +37 -35
  196. package/pinyin-first-character/index.js.gz +0 -0
  197. package/process-engine-info/es5.d.ts +13 -0
  198. package/pure-image-src/es5.d.ts +2 -0
  199. package/size-watcher/es5.d.ts +6 -0
  200. package/style/es5.d.ts +2 -0
  201. package/style/es5.js +11 -11
  202. package/style/index.js +10 -10
  203. package/style/index.js.gz +0 -0
  204. package/theme/es5.d.ts +92 -0
  205. package/theme/es5.js +1365 -0
  206. package/theme/index.d.ts +92 -0
  207. package/theme/index.js +871 -0
  208. package/theme/index.js.gz +0 -0
  209. package/token-tools/es5.d.ts +21 -0
  210. package/use-low-code/es5.d.ts +1 -0
  211. package/vue/es5.d.ts +1 -0
  212. package/vue/hooks/use-model-value/es5.d.ts +9 -0
  213. package/webSocket-service/es5.d.ts +41 -0
  214. package/with-install/es5.d.ts +11 -0
  215. package/hooks/use-get-auth/es5.js +0 -67
  216. package/hooks/use-get-auth/index.d.ts +0 -4
  217. package/hooks/use-get-auth/index.js +0 -19
@@ -0,0 +1,6 @@
1
+ /**
2
+ * 获取文件后缀名
3
+ * @param filename
4
+ * @returns
5
+ */
6
+ export declare const getFileExtension: (filename: string) => any;
@@ -0,0 +1,46 @@
1
+ /**
2
+ * 获取url中的参数
3
+ * @param url url地址
4
+ * @param queryName 参数名称,不传则返回参数集合
5
+ * @returns
6
+ */
7
+ export declare const getUrlParams: (allUrl?: string, queryName?: string) => any;
8
+ /**
9
+ * 拼接完整的url
10
+ * @param url pathname
11
+ * @param queryObj 参数集合
12
+ * @returns
13
+ */
14
+ export declare const getFullPath: (url: string, queryObj?: any) => string;
15
+ /**
16
+ * 删除url中指定的参数,并返回最终的url
17
+ * @param queryNames 数组,需要删除的参数名集合
18
+ * @param url 指定url
19
+ * @returns
20
+ */
21
+ export declare const funcUrlDel: (queryNames: string[], url?: string) => string;
22
+ /**
23
+ * 将url中的query参数转换成对象
24
+ * @param url url链接,域名可带可不带
25
+ * @returns params url链接参数转化的Object
26
+ */
27
+ export declare const urlParamsToObject: (url: string) => any;
28
+ /**
29
+ * 将对象转换成url中的query参数
30
+ * @param params 参数对象
31
+ * @returns url形式的参数
32
+ */
33
+ export declare const objectToUrlparams: (params: any) => string;
34
+ /**
35
+ * 给url拼接params参数
36
+ * @param url 路径
37
+ * @param pathParams 参数,数组格式
38
+ * @returns
39
+ */
40
+ export declare const addPathParamsToUrl: (url: string, pathParams: string[]) => any;
41
+ /**
42
+ * 从URL中获取origin
43
+ * @param url url
44
+ * @returns origin
45
+ */
46
+ export declare function getOriginFromUrl(url: string): any;
@@ -0,0 +1,34 @@
1
+ export type I18nResourceMap = Record<string, any>;
2
+ export interface HandleI18nDataResult {
3
+ frontEnd: Record<string, I18nResourceMap> | null;
4
+ dasUiEnd: I18nResourceMap | null;
5
+ backMsg: Record<string, I18nResourceMap> | null;
6
+ }
7
+ export interface HandleI18nDataOptions {
8
+ currentLang?: string;
9
+ baseUrl?: string;
10
+ appName?: string | string[];
11
+ isPullFrontEnd?: boolean;
12
+ isPullBack?: boolean;
13
+ isDasUI?: boolean;
14
+ fallbackBaseUrl?: string;
15
+ }
16
+ /**
17
+ * 判断是否为空值
18
+ * @param value 需要判断的值
19
+ * @returns
20
+ */
21
+ export declare const isEmpty: (value: any) => boolean;
22
+ export declare const isCurrentLangInSysLang: (lang: string) => any;
23
+ /**
24
+ * 处理多语言在打包时的数据
25
+ * @param opt
26
+ * @param opt.currentLang - 当前语言,默认 'zh-CN'
27
+ * @param opt.baseUrl - 资源基础路径,默认 '/'
28
+ * @param opt.appName - 应用名称,支持 string 或 string[],默认 'jc'
29
+ * @param opt.isPullFrontEnd - 是否加载前端资源,默认 true
30
+ * @param opt.isPullBack - 是否加载后端资源,默认 false
31
+ * @param opt.isDasUI - 是否加载 DasUI 资源,默认 false
32
+ * @param opt.fallbackBaseUrl - 回退资源路径,默认 ''
33
+ */
34
+ export declare const handleI18nData: (opt?: HandleI18nDataOptions) => Promise<HandleI18nDataResult>;
@@ -4,7 +4,7 @@ function _createForOfIteratorHelper(r, e) { var t = "undefined" != typeof Symbol
4
4
  function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }
5
5
  function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
6
6
  function _regenerator() { /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */ var e, t, r = "function" == typeof Symbol ? Symbol : {}, n = r.iterator || "@@iterator", o = r.toStringTag || "@@toStringTag"; function i(r, n, o, i) { var c = n && n.prototype instanceof Generator ? n : Generator, u = Object.create(c.prototype); return _regeneratorDefine2(u, "_invoke", function (r, n, o) { var i, c, u, f = 0, p = o || [], y = !1, G = { p: 0, n: 0, v: e, a: d, f: d.bind(e, 4), d: function d(t, r) { return i = t, c = 0, u = e, G.n = r, a; } }; function d(r, n) { for (c = r, u = n, t = 0; !y && f && !o && t < p.length; t++) { var o, i = p[t], d = G.p, l = i[2]; r > 3 ? (o = l === n) && (u = i[(c = i[4]) ? 5 : (c = 3, 3)], i[4] = i[5] = e) : i[0] <= d && ((o = r < 2 && d < i[1]) ? (c = 0, G.v = n, G.n = i[1]) : d < l && (o = r < 3 || i[0] > n || n > l) && (i[4] = r, i[5] = n, G.n = l, c = 0)); } if (o || r > 1) return a; throw y = !0, n; } return function (o, p, l) { if (f > 1) throw TypeError("Generator is already running"); for (y && 1 === p && d(p, l), c = p, u = l; (t = c < 2 ? e : u) || !y;) { i || (c ? c < 3 ? (c > 1 && (G.n = -1), d(c, u)) : G.n = u : G.v = u); try { if (f = 2, i) { if (c || (o = "next"), t = i[o]) { if (!(t = t.call(i, u))) throw TypeError("iterator result is not an object"); if (!t.done) return t; u = t.value, c < 2 && (c = 0); } else 1 === c && (t = i["return"]) && t.call(i), c < 2 && (u = TypeError("The iterator does not provide a '" + o + "' method"), c = 1); i = e; } else if ((t = (y = G.n < 0) ? u : r.call(n, G)) !== a) break; } catch (t) { i = e, c = 1, u = t; } finally { f = 1; } } return { value: t, done: y }; }; }(r, o, i), !0), u; } var a = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} t = Object.getPrototypeOf; var c = [][n] ? t(t([][n]())) : (_regeneratorDefine2(t = {}, n, function () { return this; }), t), u = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(c); function f(e) { return Object.setPrototypeOf ? Object.setPrototypeOf(e, GeneratorFunctionPrototype) : (e.__proto__ = GeneratorFunctionPrototype, _regeneratorDefine2(e, o, "GeneratorFunction")), e.prototype = Object.create(u), e; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, _regeneratorDefine2(u, "constructor", GeneratorFunctionPrototype), _regeneratorDefine2(GeneratorFunctionPrototype, "constructor", GeneratorFunction), GeneratorFunction.displayName = "GeneratorFunction", _regeneratorDefine2(GeneratorFunctionPrototype, o, "GeneratorFunction"), _regeneratorDefine2(u), _regeneratorDefine2(u, o, "Generator"), _regeneratorDefine2(u, n, function () { return this; }), _regeneratorDefine2(u, "toString", function () { return "[object Generator]"; }), (_regenerator = function _regenerator() { return { w: i, m: f }; })(); }
7
- function _regeneratorDefine2(e, r, n, t) { var i = Object.defineProperty; try { i({}, "", {}); } catch (e) { i = 0; } _regeneratorDefine2 = function _regeneratorDefine(e, r, n, t) { if (r) i ? i(e, r, { value: n, enumerable: !t, configurable: !t, writable: !t }) : e[r] = n;else { var o = function o(r, n) { _regeneratorDefine2(e, r, function (e) { return this._invoke(r, n, e); }); }; o("next", 0), o("throw", 1), o("return", 2); } }, _regeneratorDefine2(e, r, n, t); }
7
+ function _regeneratorDefine2(e, r, n, t) { var i = Object.defineProperty; try { i({}, "", {}); } catch (e) { i = 0; } _regeneratorDefine2 = function _regeneratorDefine(e, r, n, t) { function o(r, n) { _regeneratorDefine2(e, r, function (e) { return this._invoke(r, n, e); }); } r ? i ? i(e, r, { value: n, enumerable: !t, configurable: !t, writable: !t }) : e[r] = n : (o("next", 0), o("throw", 1), o("return", 2)); }, _regeneratorDefine2(e, r, n, t); }
8
8
  function asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); }
9
9
  function _asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { asyncGeneratorStep(a, r, o, _next, _throw, "next", n); } function _throw(n) { asyncGeneratorStep(a, r, o, _next, _throw, "throw", n); } _next(void 0); }); }; }
10
10
  function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
@@ -17,11 +17,49 @@ var M = function M(f) {
17
17
  return (((n = config.getConfig()) == null ? undefined : n.systemLangList) || ["zh-CN", "en-US", "zh-MO"]).includes(f);
18
18
  },
19
19
  A = /*#__PURE__*/function () {
20
- var _ref = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee4(f) {
21
- var x, _x$currentLang, n, _x$baseUrl, c, _x$appName, h, _x$isPullFrontEnd, L, _x$isPullBack, N, _x$isDasUI, O, _x$fallbackBaseUrl, a, l, y, j, r, _iterator, _step, s, $, w, u, _r, _iterator2, _step2, _s, _$, _w, _u, _r2, _s2, _t3, _t4;
20
+ var _ref = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee4() {
21
+ var f,
22
+ x,
23
+ _x$currentLang,
24
+ n,
25
+ _x$baseUrl,
26
+ c,
27
+ _x$appName,
28
+ h,
29
+ _x$isPullFrontEnd,
30
+ L,
31
+ _x$isPullBack,
32
+ N,
33
+ _x$isDasUI,
34
+ O,
35
+ _x$fallbackBaseUrl,
36
+ a,
37
+ l,
38
+ y,
39
+ j,
40
+ r,
41
+ _iterator,
42
+ _step,
43
+ s,
44
+ $,
45
+ w,
46
+ u,
47
+ _r,
48
+ _iterator2,
49
+ _step2,
50
+ _s,
51
+ _$,
52
+ _w,
53
+ _u,
54
+ _r2,
55
+ _s2,
56
+ _args4 = arguments,
57
+ _t3,
58
+ _t4;
22
59
  return _regenerator().w(function (_context4) {
23
60
  while (1) switch (_context4.p = _context4.n) {
24
61
  case 0:
62
+ f = _args4.length > 0 && _args4[0] !== undefined ? _args4[0] : {};
25
63
  x = f || {};
26
64
  _x$currentLang = x.currentLang, n = _x$currentLang === void 0 ? "zh-CN" : _x$currentLang, _x$baseUrl = x.baseUrl, c = _x$baseUrl === void 0 ? "/" : _x$baseUrl, _x$appName = x.appName, h = _x$appName === void 0 ? "jc" : _x$appName, _x$isPullFrontEnd = x.isPullFrontEnd, L = _x$isPullFrontEnd === void 0 ? true : _x$isPullFrontEnd, _x$isPullBack = x.isPullBack, N = _x$isPullBack === void 0 ? false : _x$isPullBack, _x$isDasUI = x.isDasUI, O = _x$isDasUI === void 0 ? false : _x$isDasUI, _x$fallbackBaseUrl = x.fallbackBaseUrl, a = _x$fallbackBaseUrl === void 0 ? "" : _x$fallbackBaseUrl;
27
65
  (typeof n != "string" || !n) && (n = "zh-CN");
@@ -110,7 +148,7 @@ var M = function M(f) {
110
148
  }
111
149
  }, _callee, null, [[0, 8]]);
112
150
  }));
113
- return function u(_x4) {
151
+ return function u(_x3) {
114
152
  return _ref3.apply(this, arguments);
115
153
  };
116
154
  }();
@@ -171,7 +209,7 @@ var M = function M(f) {
171
209
  }
172
210
  }, _callee2);
173
211
  }));
174
- return function U(_x5) {
212
+ return function U(_x4) {
175
213
  return _ref4.apply(this, arguments);
176
214
  };
177
215
  }();
@@ -203,7 +241,7 @@ var M = function M(f) {
203
241
  }
204
242
  }, _callee3);
205
243
  }));
206
- return function j(_x2, _x3) {
244
+ return function j(_x, _x2) {
207
245
  return _ref2.apply(this, arguments);
208
246
  };
209
247
  }();
@@ -298,7 +336,7 @@ var M = function M(f) {
298
336
  }
299
337
  }, _callee4, null, [[10, 15, 16, 17], [1, 6, 7, 8]]);
300
338
  }));
301
- return function A(_x) {
339
+ return function A() {
302
340
  return _ref.apply(this, arguments);
303
341
  };
304
342
  }();
@@ -1,3 +1,18 @@
1
+ export type I18nResourceMap = Record<string, any>;
2
+ export interface HandleI18nDataResult {
3
+ frontEnd: Record<string, I18nResourceMap> | null;
4
+ dasUiEnd: I18nResourceMap | null;
5
+ backMsg: Record<string, I18nResourceMap> | null;
6
+ }
7
+ export interface HandleI18nDataOptions {
8
+ currentLang?: string;
9
+ baseUrl?: string;
10
+ appName?: string | string[];
11
+ isPullFrontEnd?: boolean;
12
+ isPullBack?: boolean;
13
+ isDasUI?: boolean;
14
+ fallbackBaseUrl?: string;
15
+ }
1
16
  /**
2
17
  * 判断是否为空值
3
18
  * @param value 需要判断的值
@@ -16,4 +31,4 @@ export declare const isCurrentLangInSysLang: (lang: string) => any;
16
31
  * @param opt.isDasUI - 是否加载 DasUI 资源,默认 false
17
32
  * @param opt.fallbackBaseUrl - 回退资源路径,默认 ''
18
33
  */
19
- export declare const handleI18nData: (opt: any) => unknown;
34
+ export declare const handleI18nData: (opt?: HandleI18nDataOptions) => Promise<HandleI18nDataResult>;
@@ -2,7 +2,7 @@ import { getConfig as _ } from "@das-fed/upf-utils/config";
2
2
  const M = (f) => f === null || typeof f > "u" || f === "", z = (f) => {
3
3
  var n;
4
4
  return (((n = _()) == null ? void 0 : n.systemLangList) || ["zh-CN", "en-US", "zh-MO"]).includes(f);
5
- }, A = async (f) => {
5
+ }, A = async (f = {}) => {
6
6
  const x = f || {};
7
7
  let {
8
8
  currentLang: n = "zh-CN",
@@ -12,3 +12,4 @@ export * from '@das-fed/upf-utils/common-tools/update-browser-title';
12
12
  export * from '@das-fed/upf-utils/common-tools/extract-file-name';
13
13
  export * from '@das-fed/upf-utils/common-tools/get-file-extension';
14
14
  export * from '@das-fed/upf-utils/common-tools/calc-text-width';
15
+ export * from '@das-fed/upf-utils/common-tools/timezone-format';
@@ -12,3 +12,4 @@ export * from "@das-fed/upf-utils/common-tools/update-browser-title";
12
12
  export * from "@das-fed/upf-utils/common-tools/extract-file-name";
13
13
  export * from "@das-fed/upf-utils/common-tools/get-file-extension";
14
14
  export * from "@das-fed/upf-utils/common-tools/calc-text-width";
15
+ export * from "@das-fed/upf-utils/common-tools/timezone-format";
@@ -0,0 +1,30 @@
1
+ /**
2
+ * 过滤掉叶子节点,返回嵌套数组
3
+ * @param arr 要过滤的树
4
+ * @param children 子节点指定字段名,默认‘children’
5
+ * @returns 返回过滤掉叶子节点的嵌套数组
6
+ */
7
+ export declare const findNonEmptyChildrenItems: (arr: any[], children?: string) => any[];
8
+ /**
9
+ * 树形数组转扁平数组
10
+ * @param list 要拍平的树
11
+ * @param child 子节点指定字段名,默认‘children’
12
+ * @param deleteChild 是否删除children字段,默认为true
13
+ * @returns
14
+ */
15
+ export declare const flatTree: (list: any[], child?: string, deleteChild?: boolean) => any[];
16
+ /**
17
+ * 根据条件过滤节点
18
+ * @param tree 要过滤的树
19
+ * @param predicate 过滤条件,符合条件的节点保留
20
+ * @param children 子节点指定字段名,默认‘children’
21
+ * @returns
22
+ */
23
+ export declare const filterTreeArray: (tree: any[], predicate: (node: any) => boolean, children?: string) => any;
24
+ /**
25
+ * 树结构查找节点,深度优先
26
+ * @param tree 要过滤的树
27
+ * @param func 过滤条件,符合条件的节点保留(参数为函数,返回值为布尔值)
28
+ * @returns 查找到的节点
29
+ */
30
+ export declare const treeFind: (tree: any[], func: (node: any) => boolean, children?: string) => any;
@@ -0,0 +1,7 @@
1
+ /**
2
+ * 判断两个对象内容值是否相等,无关顺序
3
+ * @param a 对象一
4
+ * @param b 对象二
5
+ * @returns 相等返回true,不相等返回false
6
+ */
7
+ export declare const objEqual: (a: Record<string, any>, b: Record<string, any>) => boolean;
@@ -0,0 +1,19 @@
1
+ /**
2
+ * 判断一个 URL 路径是否是相对路径或者同域名
3
+ * @param url
4
+ * @returns
5
+ */
6
+ export declare const isRelativeOrSameDomain: (url: string) => boolean;
7
+ /**
8
+ * 自动拼接上showLayout=false参数
9
+ * @param url
10
+ * @returns
11
+ */
12
+ export declare const setShowLayout: (url: string) => string;
13
+ export declare const setShowWatermark: (url: string) => string;
14
+ /**
15
+ * url携带token
16
+ * @param url
17
+ * @returns
18
+ */
19
+ export declare const withToken: (url: string) => string;
@@ -0,0 +1,6 @@
1
+ /**
2
+ * 串行执行promise
3
+ * @param promiseFuncArr promise数组
4
+ * @returns promise
5
+ */
6
+ export declare function runPromiseByQueue(promiseFuncArr: any[]): any;
@@ -0,0 +1,5 @@
1
+ /**
2
+ * 自定义html最小宽高
3
+ * @param layout minWidth、minHeight为空则为重置
4
+ */
5
+ export declare const setHtmlMinWH: (layout?: Record<"minWidth" | "minHeight", string>) => void;
@@ -0,0 +1,28 @@
1
+ import { Dayjs } from 'dayjs';
2
+
3
+ type TimeValue = string | number | Date | Dayjs | null | undefined;
4
+ export interface TimeZoneDisplayOptions {
5
+ value?: TimeValue;
6
+ locale?: string;
7
+ format?: string;
8
+ timeZone?: string;
9
+ supportedLocales?: string[];
10
+ showDaylightSavingLabel?: boolean;
11
+ showDaylightSavingMarker?: boolean;
12
+ }
13
+ export interface TimeZoneDisplayResult {
14
+ formattedValue: string;
15
+ locale: string;
16
+ timeZone: string;
17
+ timeZoneName: string;
18
+ timeZoneLabel: string;
19
+ offsetLabel: string;
20
+ offsetMinutes: number;
21
+ isDaylightSavingTime: boolean;
22
+ daylightSavingLabel: string;
23
+ }
24
+ export declare const getClientTimeZone: () => any;
25
+ export declare const normalizeLocaleCode: (locale?: string, supportedLocales?: string[]) => any;
26
+ export declare const isDaylightSavingTime: (timeZone?: string, value?: TimeValue) => boolean;
27
+ export declare const getTimeZoneDisplayInfo: (options?: TimeZoneDisplayOptions) => TimeZoneDisplayResult;
28
+ export {};
@@ -0,0 +1,140 @@
1
+ 'use strict';
2
+
3
+ function _toConsumableArray(r) { return _arrayWithoutHoles(r) || _iterableToArray(r) || _unsupportedIterableToArray(r) || _nonIterableSpread(); }
4
+ function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
5
+ function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }
6
+ function _iterableToArray(r) { if ("undefined" != typeof Symbol && null != r[Symbol.iterator] || null != r["@@iterator"]) return Array.from(r); }
7
+ function _arrayWithoutHoles(r) { if (Array.isArray(r)) return _arrayLikeToArray(r); }
8
+ function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
9
+ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
10
+ var l = require('dayjs');
11
+ var T = require('dayjs/plugin/utc');
12
+ var w = require('dayjs/plugin/timezone');
13
+ l.extend(T);
14
+ l.extend(w);
15
+ var f = "zh-CN",
16
+ y = "YYYY.MM.DD HH:mm:ss",
17
+ D = "UTC",
18
+ m = {
19
+ zh: "夏令时",
20
+ "default": "DST"
21
+ },
22
+ u = function u() {
23
+ return l.tz.guess() || D;
24
+ },
25
+ v = function v() {
26
+ var t;
27
+ return (typeof window === "undefined" ? "undefined" : _typeof(window)) < "u" && (t = window.navigator) != null && t.language ? window.navigator.language : f;
28
+ },
29
+ S = function S(t) {
30
+ var e = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [];
31
+ var n = t || v() || f,
32
+ r = n.toLowerCase();
33
+ if (!e.length) return r === "en" ? "en-US" : r === "zh" || r === "zh-cn" ? f : n;
34
+ var a = e.find(function (i) {
35
+ return i.toLowerCase() === r;
36
+ });
37
+ if (a) return a;
38
+ var c = r.split("-")[0],
39
+ s = e.find(function (i) {
40
+ return i.toLowerCase().split("-")[0] === c;
41
+ });
42
+ return s || (c === "en" ? e.find(function (i) {
43
+ return i.toLowerCase().startsWith("en-");
44
+ }) || n : c === "zh" ? e.find(function (i) {
45
+ return i.toLowerCase().startsWith("zh-");
46
+ }) || f : n);
47
+ },
48
+ g = function g(t) {
49
+ if (l.isDayjs(t)) return t;
50
+ if (t == null || t === "") return l();
51
+ var e = l(t);
52
+ return e.isValid() ? e : l();
53
+ },
54
+ h = function h(t) {
55
+ if (!t) return u();
56
+ try {
57
+ return new Intl.DateTimeFormat(void 0, {
58
+ timeZone: t
59
+ }), t;
60
+ } catch (_unused) {
61
+ return u();
62
+ }
63
+ },
64
+ L = function L(t) {
65
+ return "UTC".concat(t);
66
+ },
67
+ z = function z(t, e) {
68
+ var o = t.match(/([+-]\d{1,2})(?::?(\d{2}))?/) || [];
69
+ if (!o[1]) return e;
70
+ var n = o[1].startsWith("-") ? "-" : "+",
71
+ r = o[1].replace(/[+-]/, "").padStart(2, "0"),
72
+ a = o[2] || "00";
73
+ return "UTC".concat(n).concat(r, ":").concat(a);
74
+ },
75
+ C = function C(t, e, o) {
76
+ var r, a;
77
+ var n = L(o.format("Z"));
78
+ try {
79
+ var c = Intl.DateTimeFormat.supportedLocalesOf([e])[0] || e,
80
+ s = (a = (r = new Intl.DateTimeFormat(c, {
81
+ timeZone: t,
82
+ timeZoneName: "long"
83
+ }).formatToParts(o.toDate()).find(function (i) {
84
+ return i.type === "timeZoneName";
85
+ })) == null ? void 0 : r.value) == null ? void 0 : a.trim();
86
+ return s ? /^(gmt|utc)/i.test(s) ? z(s, n) : s : n;
87
+ } catch (_unused2) {
88
+ return n;
89
+ }
90
+ },
91
+ Z = function Z(t, e) {
92
+ var o = e.year();
93
+ return Array.from(new Set(Array.from({
94
+ length: 12
95
+ }, function (n, r) {
96
+ var a = "".concat(r + 1).padStart(2, "0");
97
+ return l.tz("".concat(o, "-").concat(a, "-15 12:00:00"), t).utcOffset();
98
+ })));
99
+ },
100
+ b = function b(t, e) {
101
+ var o = h(t),
102
+ n = g(e).tz(o),
103
+ r = Z(o, n);
104
+ return r.length <= 1 ? false : n.utcOffset() > Math.min.apply(Math, _toConsumableArray(r));
105
+ },
106
+ A = function A(t) {
107
+ var e = t.toLowerCase().split("-")[0];
108
+ return m[e] || m["default"];
109
+ },
110
+ O = function O(t) {
111
+ var _t$showDaylightSaving;
112
+ return typeof t.showDaylightSavingLabel == "boolean" ? t.showDaylightSavingLabel : (_t$showDaylightSaving = t.showDaylightSavingMarker) !== null && _t$showDaylightSaving !== void 0 ? _t$showDaylightSaving : true;
113
+ },
114
+ U = function U() {
115
+ var t = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
116
+ var e = S(t.locale, t.supportedLocales),
117
+ o = h(t.timeZone),
118
+ n = g(t.value).tz(o),
119
+ r = C(o, e, n),
120
+ a = L(n.format("Z")),
121
+ c = b(o, n),
122
+ s = c ? A(e) : "",
123
+ i = O(t),
124
+ d = c && i ? "".concat(r, " - ").concat(s) : r;
125
+ return {
126
+ formattedValue: n.format(t.format || y),
127
+ locale: e,
128
+ timeZone: o,
129
+ timeZoneName: r,
130
+ timeZoneLabel: d,
131
+ offsetLabel: a,
132
+ offsetMinutes: n.utcOffset(),
133
+ isDaylightSavingTime: c,
134
+ daylightSavingLabel: s
135
+ };
136
+ };
137
+ exports.getClientTimeZone = u;
138
+ exports.getTimeZoneDisplayInfo = U;
139
+ exports.isDaylightSavingTime = b;
140
+ exports.normalizeLocaleCode = S;
@@ -0,0 +1,28 @@
1
+ import { Dayjs } from 'dayjs';
2
+
3
+ type TimeValue = string | number | Date | Dayjs | null | undefined;
4
+ export interface TimeZoneDisplayOptions {
5
+ value?: TimeValue;
6
+ locale?: string;
7
+ format?: string;
8
+ timeZone?: string;
9
+ supportedLocales?: string[];
10
+ showDaylightSavingLabel?: boolean;
11
+ showDaylightSavingMarker?: boolean;
12
+ }
13
+ export interface TimeZoneDisplayResult {
14
+ formattedValue: string;
15
+ locale: string;
16
+ timeZone: string;
17
+ timeZoneName: string;
18
+ timeZoneLabel: string;
19
+ offsetLabel: string;
20
+ offsetMinutes: number;
21
+ isDaylightSavingTime: boolean;
22
+ daylightSavingLabel: string;
23
+ }
24
+ export declare const getClientTimeZone: () => any;
25
+ export declare const normalizeLocaleCode: (locale?: string, supportedLocales?: string[]) => any;
26
+ export declare const isDaylightSavingTime: (timeZone?: string, value?: TimeValue) => boolean;
27
+ export declare const getTimeZoneDisplayInfo: (options?: TimeZoneDisplayOptions) => TimeZoneDisplayResult;
28
+ export {};
@@ -0,0 +1,81 @@
1
+ import l from "dayjs";
2
+ import T from "dayjs/plugin/utc";
3
+ import w from "dayjs/plugin/timezone";
4
+ l.extend(T);
5
+ l.extend(w);
6
+ const f = "zh-CN", y = "YYYY.MM.DD HH:mm:ss", D = "UTC", m = {
7
+ zh: "夏令时",
8
+ default: "DST"
9
+ }, u = () => l.tz.guess() || D, v = () => {
10
+ var t;
11
+ return typeof window < "u" && ((t = window.navigator) != null && t.language) ? window.navigator.language : f;
12
+ }, S = (t, e = []) => {
13
+ const n = t || v() || f, r = n.toLowerCase();
14
+ if (!e.length)
15
+ return r === "en" ? "en-US" : r === "zh" || r === "zh-cn" ? f : n;
16
+ const a = e.find((i) => i.toLowerCase() === r);
17
+ if (a) return a;
18
+ const c = r.split("-")[0], s = e.find((i) => i.toLowerCase().split("-")[0] === c);
19
+ return s || (c === "en" ? e.find((i) => i.toLowerCase().startsWith("en-")) || n : c === "zh" ? e.find((i) => i.toLowerCase().startsWith("zh-")) || f : n);
20
+ }, g = (t) => {
21
+ if (l.isDayjs(t)) return t;
22
+ if (t == null || t === "") return l();
23
+ const e = l(t);
24
+ return e.isValid() ? e : l();
25
+ }, h = (t) => {
26
+ if (!t) return u();
27
+ try {
28
+ return new Intl.DateTimeFormat(void 0, { timeZone: t }), t;
29
+ } catch {
30
+ return u();
31
+ }
32
+ }, L = (t) => `UTC${t}`, z = (t, e) => {
33
+ const o = t.match(/([+-]\d{1,2})(?::?(\d{2}))?/) || [];
34
+ if (!o[1]) return e;
35
+ const n = o[1].startsWith("-") ? "-" : "+", r = o[1].replace(/[+-]/, "").padStart(2, "0"), a = o[2] || "00";
36
+ return `UTC${n}${r}:${a}`;
37
+ }, C = (t, e, o) => {
38
+ var r, a;
39
+ const n = L(o.format("Z"));
40
+ try {
41
+ const c = Intl.DateTimeFormat.supportedLocalesOf([e])[0] || e, s = (a = (r = new Intl.DateTimeFormat(c, { timeZone: t, timeZoneName: "long" }).formatToParts(o.toDate()).find((i) => i.type === "timeZoneName")) == null ? void 0 : r.value) == null ? void 0 : a.trim();
42
+ return s ? /^(gmt|utc)/i.test(s) ? z(s, n) : s : n;
43
+ } catch {
44
+ return n;
45
+ }
46
+ }, Z = (t, e) => {
47
+ const o = e.year();
48
+ return Array.from(
49
+ new Set(
50
+ Array.from({ length: 12 }, (n, r) => {
51
+ const a = `${r + 1}`.padStart(2, "0");
52
+ return l.tz(`${o}-${a}-15 12:00:00`, t).utcOffset();
53
+ })
54
+ )
55
+ );
56
+ }, b = (t, e) => {
57
+ const o = h(t), n = g(e).tz(o), r = Z(o, n);
58
+ return r.length <= 1 ? !1 : n.utcOffset() > Math.min(...r);
59
+ }, A = (t) => {
60
+ const e = t.toLowerCase().split("-")[0];
61
+ return m[e] || m.default;
62
+ }, O = (t) => typeof t.showDaylightSavingLabel == "boolean" ? t.showDaylightSavingLabel : t.showDaylightSavingMarker ?? !0, U = (t = {}) => {
63
+ const e = S(t.locale, t.supportedLocales), o = h(t.timeZone), n = g(t.value).tz(o), r = C(o, e, n), a = L(n.format("Z")), c = b(o, n), s = c ? A(e) : "", i = O(t), d = c && i ? `${r} - ${s}` : r;
64
+ return {
65
+ formattedValue: n.format(t.format || y),
66
+ locale: e,
67
+ timeZone: o,
68
+ timeZoneName: r,
69
+ timeZoneLabel: d,
70
+ offsetLabel: a,
71
+ offsetMinutes: n.utcOffset(),
72
+ isDaylightSavingTime: c,
73
+ daylightSavingLabel: s
74
+ };
75
+ };
76
+ export {
77
+ u as getClientTimeZone,
78
+ U as getTimeZoneDisplayInfo,
79
+ b as isDaylightSavingTime,
80
+ S as normalizeLocaleCode
81
+ };
@@ -0,0 +1 @@
1
+ export declare const setBrowseTitle: (defaultTitle?: string) => any;
@@ -1,7 +1,7 @@
1
1
  'use strict';
2
2
 
3
3
  function _regenerator() { /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */ var e, t, r = "function" == typeof Symbol ? Symbol : {}, n = r.iterator || "@@iterator", o = r.toStringTag || "@@toStringTag"; function i(r, n, o, i) { var c = n && n.prototype instanceof Generator ? n : Generator, u = Object.create(c.prototype); return _regeneratorDefine2(u, "_invoke", function (r, n, o) { var i, c, u, f = 0, p = o || [], y = !1, G = { p: 0, n: 0, v: e, a: d, f: d.bind(e, 4), d: function d(t, r) { return i = t, c = 0, u = e, G.n = r, a; } }; function d(r, n) { for (c = r, u = n, t = 0; !y && f && !o && t < p.length; t++) { var o, i = p[t], d = G.p, l = i[2]; r > 3 ? (o = l === n) && (u = i[(c = i[4]) ? 5 : (c = 3, 3)], i[4] = i[5] = e) : i[0] <= d && ((o = r < 2 && d < i[1]) ? (c = 0, G.v = n, G.n = i[1]) : d < l && (o = r < 3 || i[0] > n || n > l) && (i[4] = r, i[5] = n, G.n = l, c = 0)); } if (o || r > 1) return a; throw y = !0, n; } return function (o, p, l) { if (f > 1) throw TypeError("Generator is already running"); for (y && 1 === p && d(p, l), c = p, u = l; (t = c < 2 ? e : u) || !y;) { i || (c ? c < 3 ? (c > 1 && (G.n = -1), d(c, u)) : G.n = u : G.v = u); try { if (f = 2, i) { if (c || (o = "next"), t = i[o]) { if (!(t = t.call(i, u))) throw TypeError("iterator result is not an object"); if (!t.done) return t; u = t.value, c < 2 && (c = 0); } else 1 === c && (t = i["return"]) && t.call(i), c < 2 && (u = TypeError("The iterator does not provide a '" + o + "' method"), c = 1); i = e; } else if ((t = (y = G.n < 0) ? u : r.call(n, G)) !== a) break; } catch (t) { i = e, c = 1, u = t; } finally { f = 1; } } return { value: t, done: y }; }; }(r, o, i), !0), u; } var a = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} t = Object.getPrototypeOf; var c = [][n] ? t(t([][n]())) : (_regeneratorDefine2(t = {}, n, function () { return this; }), t), u = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(c); function f(e) { return Object.setPrototypeOf ? Object.setPrototypeOf(e, GeneratorFunctionPrototype) : (e.__proto__ = GeneratorFunctionPrototype, _regeneratorDefine2(e, o, "GeneratorFunction")), e.prototype = Object.create(u), e; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, _regeneratorDefine2(u, "constructor", GeneratorFunctionPrototype), _regeneratorDefine2(GeneratorFunctionPrototype, "constructor", GeneratorFunction), GeneratorFunction.displayName = "GeneratorFunction", _regeneratorDefine2(GeneratorFunctionPrototype, o, "GeneratorFunction"), _regeneratorDefine2(u), _regeneratorDefine2(u, o, "Generator"), _regeneratorDefine2(u, n, function () { return this; }), _regeneratorDefine2(u, "toString", function () { return "[object Generator]"; }), (_regenerator = function _regenerator() { return { w: i, m: f }; })(); }
4
- function _regeneratorDefine2(e, r, n, t) { var i = Object.defineProperty; try { i({}, "", {}); } catch (e) { i = 0; } _regeneratorDefine2 = function _regeneratorDefine(e, r, n, t) { if (r) i ? i(e, r, { value: n, enumerable: !t, configurable: !t, writable: !t }) : e[r] = n;else { var o = function o(r, n) { _regeneratorDefine2(e, r, function (e) { return this._invoke(r, n, e); }); }; o("next", 0), o("throw", 1), o("return", 2); } }, _regeneratorDefine2(e, r, n, t); }
4
+ function _regeneratorDefine2(e, r, n, t) { var i = Object.defineProperty; try { i({}, "", {}); } catch (e) { i = 0; } _regeneratorDefine2 = function _regeneratorDefine(e, r, n, t) { function o(r, n) { _regeneratorDefine2(e, r, function (e) { return this._invoke(r, n, e); }); } r ? i ? i(e, r, { value: n, enumerable: !t, configurable: !t, writable: !t }) : e[r] = n : (o("next", 0), o("throw", 1), o("return", 2)); }, _regeneratorDefine2(e, r, n, t); }
5
5
  function _slicedToArray(r, e) { return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); }
6
6
  function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
7
7
  function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }
@@ -0,0 +1,11 @@
1
+ /**
2
+ * 设置平台的favIcon
3
+ * @param favIcon 图标
4
+ * @param defaultIcon 默认图标
5
+ */
6
+ export declare const updateFavIcon: (favIcon: string, defaultIcon?: string) => void;
7
+ /**
8
+ * 设置平台的favIcon,如果localStorage中没有则调用接口获取
9
+ * @param defaultIcon 默认图标
10
+ */
11
+ export declare const setDasHtmlIcon: (defaultIcon?: string) => any;
@@ -1,7 +1,7 @@
1
1
  'use strict';
2
2
 
3
3
  function _regenerator() { /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */ var e, t, r = "function" == typeof Symbol ? Symbol : {}, n = r.iterator || "@@iterator", o = r.toStringTag || "@@toStringTag"; function i(r, n, o, i) { var c = n && n.prototype instanceof Generator ? n : Generator, u = Object.create(c.prototype); return _regeneratorDefine2(u, "_invoke", function (r, n, o) { var i, c, u, f = 0, p = o || [], y = !1, G = { p: 0, n: 0, v: e, a: d, f: d.bind(e, 4), d: function d(t, r) { return i = t, c = 0, u = e, G.n = r, a; } }; function d(r, n) { for (c = r, u = n, t = 0; !y && f && !o && t < p.length; t++) { var o, i = p[t], d = G.p, l = i[2]; r > 3 ? (o = l === n) && (u = i[(c = i[4]) ? 5 : (c = 3, 3)], i[4] = i[5] = e) : i[0] <= d && ((o = r < 2 && d < i[1]) ? (c = 0, G.v = n, G.n = i[1]) : d < l && (o = r < 3 || i[0] > n || n > l) && (i[4] = r, i[5] = n, G.n = l, c = 0)); } if (o || r > 1) return a; throw y = !0, n; } return function (o, p, l) { if (f > 1) throw TypeError("Generator is already running"); for (y && 1 === p && d(p, l), c = p, u = l; (t = c < 2 ? e : u) || !y;) { i || (c ? c < 3 ? (c > 1 && (G.n = -1), d(c, u)) : G.n = u : G.v = u); try { if (f = 2, i) { if (c || (o = "next"), t = i[o]) { if (!(t = t.call(i, u))) throw TypeError("iterator result is not an object"); if (!t.done) return t; u = t.value, c < 2 && (c = 0); } else 1 === c && (t = i["return"]) && t.call(i), c < 2 && (u = TypeError("The iterator does not provide a '" + o + "' method"), c = 1); i = e; } else if ((t = (y = G.n < 0) ? u : r.call(n, G)) !== a) break; } catch (t) { i = e, c = 1, u = t; } finally { f = 1; } } return { value: t, done: y }; }; }(r, o, i), !0), u; } var a = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} t = Object.getPrototypeOf; var c = [][n] ? t(t([][n]())) : (_regeneratorDefine2(t = {}, n, function () { return this; }), t), u = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(c); function f(e) { return Object.setPrototypeOf ? Object.setPrototypeOf(e, GeneratorFunctionPrototype) : (e.__proto__ = GeneratorFunctionPrototype, _regeneratorDefine2(e, o, "GeneratorFunction")), e.prototype = Object.create(u), e; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, _regeneratorDefine2(u, "constructor", GeneratorFunctionPrototype), _regeneratorDefine2(GeneratorFunctionPrototype, "constructor", GeneratorFunction), GeneratorFunction.displayName = "GeneratorFunction", _regeneratorDefine2(GeneratorFunctionPrototype, o, "GeneratorFunction"), _regeneratorDefine2(u), _regeneratorDefine2(u, o, "Generator"), _regeneratorDefine2(u, n, function () { return this; }), _regeneratorDefine2(u, "toString", function () { return "[object Generator]"; }), (_regenerator = function _regenerator() { return { w: i, m: f }; })(); }
4
- function _regeneratorDefine2(e, r, n, t) { var i = Object.defineProperty; try { i({}, "", {}); } catch (e) { i = 0; } _regeneratorDefine2 = function _regeneratorDefine(e, r, n, t) { if (r) i ? i(e, r, { value: n, enumerable: !t, configurable: !t, writable: !t }) : e[r] = n;else { var o = function o(r, n) { _regeneratorDefine2(e, r, function (e) { return this._invoke(r, n, e); }); }; o("next", 0), o("throw", 1), o("return", 2); } }, _regeneratorDefine2(e, r, n, t); }
4
+ function _regeneratorDefine2(e, r, n, t) { var i = Object.defineProperty; try { i({}, "", {}); } catch (e) { i = 0; } _regeneratorDefine2 = function _regeneratorDefine(e, r, n, t) { function o(r, n) { _regeneratorDefine2(e, r, function (e) { return this._invoke(r, n, e); }); } r ? i ? i(e, r, { value: n, enumerable: !t, configurable: !t, writable: !t }) : e[r] = n : (o("next", 0), o("throw", 1), o("return", 2)); }, _regeneratorDefine2(e, r, n, t); }
5
5
  function _slicedToArray(r, e) { return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); }
6
6
  function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
7
7
  function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }