vite-uni-dev-tool 0.0.12 → 0.0.13

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 (181) hide show
  1. package/dist/const.d.ts +133 -0
  2. package/dist/const.d.ts.map +1 -0
  3. package/dist/const.js +36 -0
  4. package/dist/core.d.ts +52 -0
  5. package/dist/core.d.ts.map +1 -0
  6. package/dist/core.js +80 -0
  7. package/dist/devConsole/index.d.ts +169 -0
  8. package/dist/devConsole/index.d.ts.map +1 -0
  9. package/dist/devConsole/index.js +270 -0
  10. package/dist/devEvent/index.d.ts +286 -0
  11. package/dist/devEvent/index.d.ts.map +1 -0
  12. package/dist/devEvent/index.js +435 -0
  13. package/dist/devEventBus/index.d.ts +42 -0
  14. package/dist/devEventBus/index.d.ts.map +1 -0
  15. package/dist/devEventBus/index.js +70 -0
  16. package/dist/devIntercept/index.d.ts +119 -0
  17. package/dist/devIntercept/index.d.ts.map +1 -0
  18. package/dist/devIntercept/index.js +582 -0
  19. package/dist/devRunJS/index.d.ts +67 -0
  20. package/dist/devRunJS/index.d.ts.map +1 -0
  21. package/dist/devStore/index.d.ts +178 -0
  22. package/dist/devStore/index.d.ts.map +1 -0
  23. package/dist/devStore/index.js +395 -0
  24. package/dist/devToolInfo/index.d.ts +17 -0
  25. package/dist/devToolInfo/index.d.ts.map +1 -0
  26. package/dist/devToolInfo/index.js +15 -0
  27. package/{dev → dist}/plugins/uniDevTool/uniDevTool.d.ts +7 -1
  28. package/dist/plugins/uniDevTool/uniDevTool.d.ts.map +1 -0
  29. package/dist/plugins/uniDevTool/uniDevTool.js +35 -0
  30. package/{dev → dist}/plugins/utils/index.d.ts +3 -0
  31. package/{dev → dist}/plugins/utils/index.d.ts.map +1 -1
  32. package/dist/plugins/utils/index.js +1 -0
  33. package/dist/type.d.ts +264 -0
  34. package/dist/type.d.ts.map +1 -0
  35. package/dist/utils/array.d.ts +2 -0
  36. package/dist/utils/array.d.ts.map +1 -0
  37. package/dist/utils/array.js +12 -0
  38. package/dist/utils/date.d.ts +19 -0
  39. package/dist/utils/date.d.ts.map +1 -0
  40. package/dist/utils/date.js +40 -0
  41. package/dist/utils/file.d.ts +11 -0
  42. package/dist/utils/file.d.ts.map +1 -0
  43. package/dist/utils/file.js +87 -0
  44. package/dist/utils/function.d.ts +28 -0
  45. package/dist/utils/function.d.ts.map +1 -0
  46. package/dist/utils/function.js +46 -0
  47. package/dist/utils/index.d.ts +11 -0
  48. package/dist/utils/index.d.ts.map +1 -0
  49. package/dist/utils/index.js +55 -0
  50. package/dist/utils/ip.d.ts +5 -0
  51. package/dist/utils/ip.d.ts.map +1 -0
  52. package/dist/utils/ip.js +21 -0
  53. package/dist/utils/language.d.ts +29 -0
  54. package/dist/utils/language.d.ts.map +1 -0
  55. package/dist/utils/language.js +50 -0
  56. package/dist/utils/object.d.ts +49 -0
  57. package/dist/utils/object.d.ts.map +1 -0
  58. package/dist/utils/object.js +118 -0
  59. package/dist/utils/page.d.ts +7 -0
  60. package/dist/utils/page.d.ts.map +1 -0
  61. package/dist/utils/page.js +7 -0
  62. package/dist/utils/platform.d.ts +4 -0
  63. package/dist/utils/platform.d.ts.map +1 -0
  64. package/dist/utils/platform.js +14 -0
  65. package/dist/utils/string.d.ts +45 -0
  66. package/dist/utils/string.d.ts.map +1 -0
  67. package/dist/utils/string.js +88 -0
  68. package/dist/utils/utils.d.ts +16 -0
  69. package/dist/utils/utils.d.ts.map +1 -0
  70. package/dist/v2/AutoSizer/utils.d.ts +5 -0
  71. package/dist/v2/AutoSizer/utils.d.ts.map +1 -0
  72. package/dist/v2/JsonPretty/hooks/useClipboard.d.ts +4 -0
  73. package/dist/v2/JsonPretty/hooks/useClipboard.d.ts.map +1 -0
  74. package/dist/v2/JsonPretty/hooks/useError.d.ts +8 -0
  75. package/dist/v2/JsonPretty/hooks/useError.d.ts.map +1 -0
  76. package/dist/v2/JsonPretty/type.d.ts +93 -0
  77. package/dist/v2/JsonPretty/type.d.ts.map +1 -0
  78. package/dist/v3/AutoSizer/utils.d.ts +5 -0
  79. package/dist/v3/AutoSizer/utils.d.ts.map +1 -0
  80. package/dist/v3/ConsoleList/staticTips.d.ts +13 -0
  81. package/dist/v3/ConsoleList/staticTips.d.ts.map +1 -0
  82. package/dist/v3/JsonPretty/hooks/useClipboard.d.ts +4 -0
  83. package/dist/v3/JsonPretty/hooks/useClipboard.d.ts.map +1 -0
  84. package/dist/v3/JsonPretty/hooks/useError.d.ts +8 -0
  85. package/dist/v3/JsonPretty/hooks/useError.d.ts.map +1 -0
  86. package/dist/v3/JsonPretty/type.d.ts +93 -0
  87. package/dist/v3/JsonPretty/type.d.ts.map +1 -0
  88. package/dist/v3/JsonPretty/utils/index.d.ts +10 -0
  89. package/dist/v3/JsonPretty/utils/index.d.ts.map +1 -0
  90. package/package.json +5 -5
  91. package/dev/components/AppInfo/index.vue +0 -36
  92. package/dev/components/AutoSizer/index.vue +0 -193
  93. package/dev/components/AutoSizer/index1.vue +0 -186
  94. package/dev/components/AutoSizer/utils.ts +0 -49
  95. package/dev/components/Button/index.vue +0 -34
  96. package/dev/components/CaptureScreen/index.vue +0 -62
  97. package/dev/components/Checkbox/index.vue +0 -40
  98. package/dev/components/CloseButton/index.vue +0 -26
  99. package/dev/components/Code/index.vue +0 -230
  100. package/dev/components/Connection/index.vue +0 -88
  101. package/dev/components/ConsoleList/Code.vue +0 -227
  102. package/dev/components/ConsoleList/ConsoleItem.vue +0 -207
  103. package/dev/components/ConsoleList/RunJSInput.vue +0 -237
  104. package/dev/components/ConsoleList/index.vue +0 -139
  105. package/dev/components/ConsoleList/staticTips.ts +0 -1145
  106. package/dev/components/DevTool/index.vue +0 -188
  107. package/dev/components/DevToolButton/index.vue +0 -210
  108. package/dev/components/DevToolTitle/index.vue +0 -21
  109. package/dev/components/DevToolWindow/index.vue +0 -1053
  110. package/dev/components/DeviceInfo/index.vue +0 -32
  111. package/dev/components/Empty/empty.png +0 -0
  112. package/dev/components/Empty/index.vue +0 -28
  113. package/dev/components/FilterInput/index.vue +0 -86
  114. package/dev/components/JsonPretty/components/Brackets/index.vue +0 -23
  115. package/dev/components/JsonPretty/components/Carets/index.vue +0 -59
  116. package/dev/components/JsonPretty/components/CheckController/index.vue +0 -125
  117. package/dev/components/JsonPretty/components/TreeNode/index.vue +0 -349
  118. package/dev/components/JsonPretty/hooks/useClipboard.ts +0 -21
  119. package/dev/components/JsonPretty/hooks/useError.ts +0 -21
  120. package/dev/components/JsonPretty/index.vue +0 -476
  121. package/dev/components/JsonPretty/type.ts +0 -125
  122. package/dev/components/JsonPretty/utils/index.ts +0 -172
  123. package/dev/components/NetworkList/NetworkDetail.vue +0 -194
  124. package/dev/components/NetworkList/NetworkItem.vue +0 -119
  125. package/dev/components/NetworkList/index.vue +0 -128
  126. package/dev/components/PiniaList/index.vue +0 -64
  127. package/dev/components/RouteList/index.vue +0 -121
  128. package/dev/components/RunJS/index.vue +0 -128
  129. package/dev/components/SettingList/index.vue +0 -222
  130. package/dev/components/SourceCode/index.vue +0 -231
  131. package/dev/components/StorageList/index.vue +0 -170
  132. package/dev/components/SystemInfo/index.vue +0 -34
  133. package/dev/components/Tabs/index.vue +0 -123
  134. package/dev/components/Tag/index.vue +0 -89
  135. package/dev/components/UniEvent/UniEventItem.vue +0 -126
  136. package/dev/components/UniEvent/index.vue +0 -98
  137. package/dev/components/UploadList/UploadDetail.vue +0 -204
  138. package/dev/components/UploadList/UploadItem.vue +0 -117
  139. package/dev/components/UploadList/index.vue +0 -117
  140. package/dev/components/VirtualList/index.vue +0 -112
  141. package/dev/components/VirtualListPro/AutoSize.vue +0 -43
  142. package/dev/components/VirtualListPro/index.vue +0 -238
  143. package/dev/components/VirtualListPro/readme.md +0 -40
  144. package/dev/components/VuexList/index.vue +0 -54
  145. package/dev/components/WebSocket/WebSocketItem.vue +0 -103
  146. package/dev/components/WebSocket/WebSocketList.vue +0 -173
  147. package/dev/components/WebSocket/index.vue +0 -124
  148. package/dev/components/WindowInfo/index.vue +0 -33
  149. package/dev/const.ts +0 -164
  150. package/dev/core.ts +0 -118
  151. package/dev/devConsole/index.ts +0 -350
  152. package/dev/devEvent/index.ts +0 -810
  153. package/dev/devEventBus/index.ts +0 -94
  154. package/dev/devIntercept/index.ts +0 -745
  155. package/dev/devRunJS/index.ts +0 -170
  156. package/dev/devStore/index.ts +0 -732
  157. package/dev/devToolInfo/index.ts +0 -26
  158. package/dev/plugins/uniDevTool/uniDevTool.d.ts.map +0 -1
  159. package/dev/plugins/uniDevTool/uniDevTool.js +0 -36
  160. package/dev/plugins/utils/index.js +0 -1
  161. package/dev/shims-uni.d.ts +0 -43
  162. package/dev/type.ts +0 -291
  163. package/dev/utils/array.ts +0 -15
  164. package/dev/utils/date.ts +0 -75
  165. package/dev/utils/file.ts +0 -121
  166. package/dev/utils/function.ts +0 -192
  167. package/dev/utils/index.d.ts +0 -6
  168. package/dev/utils/index.ts +0 -51
  169. package/dev/utils/ip.ts +0 -79
  170. package/dev/utils/language.ts +0 -77
  171. package/dev/utils/object.ts +0 -306
  172. package/dev/utils/page.ts +0 -13
  173. package/dev/utils/platform.ts +0 -14
  174. package/dev/utils/string.ts +0 -133
  175. package/dev/utils/utils.ts +0 -198
  176. /package/{dev → dist}/index.d.ts +0 -0
  177. /package/{dev → dist}/index.d.ts.map +0 -0
  178. /package/{dev → dist}/index.js +0 -0
  179. /package/{dev → dist}/plugins/uniGlobalComponents/uniGlobalComponents.d.ts +0 -0
  180. /package/{dev → dist}/plugins/uniGlobalComponents/uniGlobalComponents.d.ts.map +0 -0
  181. /package/{dev → dist}/plugins/uniGlobalComponents/uniGlobalComponents.js +0 -0
@@ -0,0 +1,55 @@
1
+ import { getValueType as r, isArray as o, isBoolean as i, isFunction as a, isNil as s, isNull as l, isNumber as p, isObject as c, isString as u, isSymbol as f, isUndefined as m, transformValueToView as n } from "./language.js";
2
+ import { calculateObjectSize as g, formatStorageSize as h, getValueByPath as d, parseValue as S, serializeCircular as T, setValueByPath as V } from "./object.js";
3
+ import { debounce as y, throttle as A } from "./function.js";
4
+ import { getFilePath as M, saveTextFileH5 as P, saveTextFileMicro as v, saveTxtFileApp as C } from "./file.js";
5
+ import { getCurrentPagePath as k } from "./page.js";
6
+ import { formatDate as B, getCurrentDate as D, sleep as H } from "./date.js";
7
+ import { escapeHTML as N, extractRowAndCol as W, extractUrl as j, hightLight as w, isMockWX as O, parseStock as U, uniqueId as X } from "./string.js";
8
+ import { getDeviceMac as R, getLanIp as E, getMicroAppIp as G, getWifiIp as J } from "./ip.js";
9
+ import { isAndroid as Q, isH5 as Y, isWX as Z } from "./platform.js";
10
+ import { chunk as $ } from "./array.js";
11
+ export {
12
+ g as calculateObjectSize,
13
+ $ as chunk,
14
+ y as debounce,
15
+ N as escapeHTML,
16
+ W as extractRowAndCol,
17
+ j as extractUrl,
18
+ B as formatDate,
19
+ h as formatStorageSize,
20
+ D as getCurrentDate,
21
+ k as getCurrentPagePath,
22
+ R as getDeviceMac,
23
+ M as getFilePath,
24
+ E as getLanIp,
25
+ G as getMicroAppIp,
26
+ d as getValueByPath,
27
+ r as getValueType,
28
+ J as getWifiIp,
29
+ w as hightLight,
30
+ Q as isAndroid,
31
+ o as isArray,
32
+ i as isBoolean,
33
+ a as isFunction,
34
+ Y as isH5,
35
+ O as isMockWX,
36
+ s as isNil,
37
+ l as isNull,
38
+ p as isNumber,
39
+ c as isObject,
40
+ u as isString,
41
+ f as isSymbol,
42
+ m as isUndefined,
43
+ Z as isWX,
44
+ U as parseStock,
45
+ S as parseValue,
46
+ P as saveTextFileH5,
47
+ v as saveTextFileMicro,
48
+ C as saveTxtFileApp,
49
+ T as serializeCircular,
50
+ V as setValueByPath,
51
+ H as sleep,
52
+ A as throttle,
53
+ n as transformValueToView,
54
+ X as uniqueId
55
+ };
@@ -0,0 +1,5 @@
1
+ export declare function getWifiIp(): string;
2
+ export declare function getLanIp(): any;
3
+ export declare function getMicroAppIp(): Promise<unknown>;
4
+ export declare function getDeviceMac(): void;
5
+ //# sourceMappingURL=ip.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ip.d.ts","sourceRoot":"","sources":["../../dev/utils/ip.ts"],"names":[],"mappings":"AAAA,wBAAgB,SAAS,WAuBxB;AAED,wBAAgB,QAAQ,QAevB;AAED,wBAAgB,aAAa,qBAe5B;AAED,wBAAgB,YAAY,SAmB3B"}
@@ -0,0 +1,21 @@
1
+ function c() {
2
+ return "";
3
+ }
4
+ function v() {
5
+ return "";
6
+ }
7
+ function g() {
8
+ return Promise.resolve("");
9
+ }
10
+ function f() {
11
+ for (var n = "", i = plus.android.importClass("java.net.NetworkInterface"), o = i.getByName("wlan0"), a = o.getHardwareAddress(), r = 0; r < a.length; r++) {
12
+ var e = "", t = a[r];
13
+ t < 0 ? e = (255 + t + 1).toString(16) : e = t.toString(16), e.length == 1 && (e = "0" + e), n += e;
14
+ }
15
+ }
16
+ export {
17
+ f as getDeviceMac,
18
+ v as getLanIp,
19
+ g as getMicroAppIp,
20
+ c as getWifiIp
21
+ };
@@ -0,0 +1,29 @@
1
+ import { DevTool } from '../type';
2
+
3
+ export declare function isNil(value: any): value is null | undefined;
4
+ export declare function isBoolean(value: any): value is boolean;
5
+ export declare function isNumber(value: any): value is number;
6
+ export declare function isObject(value: any): value is object;
7
+ export declare function isArray(value: any): value is any[];
8
+ export declare function isString(value: any): value is string;
9
+ export declare function isNull(value: any): value is null;
10
+ export declare function isUndefined(value: any): value is undefined;
11
+ export declare function isSymbol(value: any): value is symbol;
12
+ export declare function isFunction(value: any): value is Function;
13
+ /**
14
+ *
15
+ *
16
+ * @export
17
+ * @param {*} value
18
+ * @return {*} {DevTool.ValueType}
19
+ */
20
+ export declare function getValueType(value: any): DevTool.ValueType;
21
+ /**
22
+ * 将 console 入参转vue 可视值
23
+ *
24
+ * @export
25
+ * @param {*} value
26
+ * @return {*} {DevTool.ValueType}
27
+ */
28
+ export declare function transformValueToView(value: any): DevTool.ValueType;
29
+ //# sourceMappingURL=language.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"language.d.ts","sourceRoot":"","sources":["../../dev/utils/language.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,SAAS,CAAC;AACvC,wBAAgB,KAAK,CAAC,KAAK,EAAE,GAAG,GAAG,KAAK,IAAI,IAAI,GAAG,SAAS,CAE3D;AAED,wBAAgB,SAAS,CAAC,KAAK,EAAE,GAAG,GAAG,KAAK,IAAI,OAAO,CAEtD;AAED,wBAAgB,QAAQ,CAAC,KAAK,EAAE,GAAG,GAAG,KAAK,IAAI,MAAM,CAEpD;AAED,wBAAgB,QAAQ,CAAC,KAAK,EAAE,GAAG,GAAG,KAAK,IAAI,MAAM,CAEpD;AAED,wBAAgB,OAAO,CAAC,KAAK,EAAE,GAAG,GAAG,KAAK,IAAI,GAAG,EAAE,CAElD;AAED,wBAAgB,QAAQ,CAAC,KAAK,EAAE,GAAG,GAAG,KAAK,IAAI,MAAM,CAEpD;AAED,wBAAgB,MAAM,CAAC,KAAK,EAAE,GAAG,GAAG,KAAK,IAAI,IAAI,CAEhD;AAED,wBAAgB,WAAW,CAAC,KAAK,EAAE,GAAG,GAAG,KAAK,IAAI,SAAS,CAE1D;AAED,wBAAgB,QAAQ,CAAC,KAAK,EAAE,GAAG,GAAG,KAAK,IAAI,MAAM,CAEpD;AAED,wBAAgB,UAAU,CAAC,KAAK,EAAE,GAAG,GAAG,KAAK,IAAI,QAAQ,CAExD;AAED;;;;;;GAMG;AACH,wBAAgB,YAAY,CAAC,KAAK,EAAE,GAAG,GAAG,OAAO,CAAC,SAAS,CAS1D;AAED;;;;;;GAMG;AACH,wBAAgB,oBAAoB,CAAC,KAAK,EAAE,GAAG,GAAG,OAAO,CAAC,SAAS,CAUlE"}
@@ -0,0 +1,50 @@
1
+ function c(n) {
2
+ return n == null;
3
+ }
4
+ function s(n) {
5
+ return typeof n == "boolean";
6
+ }
7
+ function r(n) {
8
+ return typeof n == "number" && !isNaN(n);
9
+ }
10
+ function t(n) {
11
+ return typeof n == "object" && n !== null;
12
+ }
13
+ function i(n) {
14
+ return Array.isArray(n);
15
+ }
16
+ function e(n) {
17
+ return typeof n == "string";
18
+ }
19
+ function u(n) {
20
+ return n === null;
21
+ }
22
+ function f(n) {
23
+ return n === void 0;
24
+ }
25
+ function o(n) {
26
+ return typeof n == "symbol";
27
+ }
28
+ function y(n) {
29
+ return typeof n == "function";
30
+ }
31
+ function b(n) {
32
+ return u(n) ? "null" : f(n) ? "undefined" : r(n) ? "number" : e(n) ? "string" : i(n) ? "array" : t(n) ? "object" : o(n) ? "symbol" : "string";
33
+ }
34
+ function m(n) {
35
+ return u(n) ? "null" : f(n) ? "undefined" : e(n) ? "string" : r(n) ? "number" : s(n) ? "boolean" : o(n) ? "symbol" : i(n) ? "array" : t(n) ? "object" : "string";
36
+ }
37
+ export {
38
+ b as getValueType,
39
+ i as isArray,
40
+ s as isBoolean,
41
+ y as isFunction,
42
+ c as isNil,
43
+ u as isNull,
44
+ r as isNumber,
45
+ t as isObject,
46
+ e as isString,
47
+ o as isSymbol,
48
+ f as isUndefined,
49
+ m as transformValueToView
50
+ };
@@ -0,0 +1,49 @@
1
+ /**
2
+ * 自定义set函数 - 安全地设置嵌套对象属性
3
+ * @param obj 目标对象
4
+ * @param path 属性路径数组
5
+ * @param value 要设置的值
6
+ */
7
+ export declare function setValueByPath(obj: any, path: string, value: any): void;
8
+ export declare function getValueByPath(obj: any, path: string, defaultValue?: any): any;
9
+ /**
10
+ * 计算对象在内存中的近似大小
11
+ * @param obj 要计算大小的对象
12
+ * @returns 对象的近似大小(以字节为单位)
13
+ */
14
+ export declare function calculateObjectSize(obj: any): number;
15
+ /**
16
+ * 存储单位转换
17
+ * @param bytes 字节数
18
+ * @param options 转换选项
19
+ * @returns 转换后的存储大小字符串
20
+ */
21
+ interface FormatStorageOptions {
22
+ precision?: number;
23
+ useBinary?: boolean;
24
+ includeUnit?: boolean;
25
+ }
26
+ export declare function formatStorageSize(bytes: number, options?: FormatStorageOptions): string;
27
+ /**
28
+ * 序列化包含循环引用的对象
29
+ * @param {Object} obj - 要序列化的对象
30
+ * @param {WeakMap} [visited] - 用于记录已处理的对象(内部递归使用)
31
+ * @returns {string} - 序列化后的字符串
32
+ */
33
+ export declare function serializeCircular(obj: any, options?: {
34
+ maxDepth: number;
35
+ visited: WeakMap<any, true>;
36
+ }): string;
37
+ /**
38
+ * 处理value
39
+ * 基础类型数据直接返回value
40
+ * 引用类型数据判断 value 是否存在循环引用的情况,存在则将循环引用的第二次赋值为 [Circular]
41
+ * 最大处理 deep 层数
42
+ *
43
+ * @export
44
+ * @param {*} value
45
+ * @param {number} [deep=6]
46
+ */
47
+ export declare function parseValue(value: any, deep?: number): any;
48
+ export {};
49
+ //# sourceMappingURL=object.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"object.d.ts","sourceRoot":"","sources":["../../dev/utils/object.ts"],"names":[],"mappings":"AAEA;;;;;GAKG;AACH,wBAAgB,cAAc,CAAC,GAAG,EAAE,GAAG,EAAE,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,GAAG,QAgChE;AAED,wBAAgB,cAAc,CAAC,GAAG,EAAE,GAAG,EAAE,IAAI,EAAE,MAAM,EAAE,YAAY,CAAC,EAAE,GAAG,OAoBxE;AAED;;;;GAIG;AACH,wBAAgB,mBAAmB,CAAC,GAAG,EAAE,GAAG,GAAG,MAAM,CAkEpD;AAED;;;;;GAKG;AACH,UAAU,oBAAoB;IAC5B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,WAAW,CAAC,EAAE,OAAO,CAAC;CACvB;AAED,wBAAgB,iBAAiB,CAC/B,KAAK,EAAE,MAAM,EACb,OAAO,GAAE,oBAAyB,GACjC,MAAM,CAqBR;AAED;;;;;GAKG;AACH,wBAAgB,iBAAiB,CAC/B,GAAG,EAAE,GAAG,EACR,OAAO,GAAE;IAAE,QAAQ,EAAE,MAAM,CAAC;IAAC,OAAO,EAAE,OAAO,CAAC,GAAG,EAAE,IAAI,CAAC,CAAA;CAGvD,GACA,MAAM,CAkDR;AAED;;;;;;;;;GASG;AACH,wBAAgB,UAAU,CAAC,KAAK,EAAE,GAAG,EAAE,IAAI,GAAE,MAAU,OAwDtD"}
@@ -0,0 +1,118 @@
1
+ import { isString as g, isBoolean as p, isFunction as y, isNil as m, isObject as B } from "./language.js";
2
+ function h(t, s, e) {
3
+ if (t == null || typeof s != "string")
4
+ return;
5
+ const n = s.replace(/\[(\d+)\]/g, ".$1").split(".").filter((i) => i !== "");
6
+ if (n.length === 0)
7
+ return;
8
+ let r = t;
9
+ const f = n.length - 1;
10
+ for (let i = 0; i < f; i++) {
11
+ const c = n[i];
12
+ if (!r[c]) {
13
+ const u = n[i + 1];
14
+ r[c] = /^\d+$/.test(u) ? [] : {};
15
+ }
16
+ r = r[c];
17
+ }
18
+ r[n[f]] = e;
19
+ }
20
+ function x(t, s, e) {
21
+ if (t == null || typeof s != "string")
22
+ return e;
23
+ const n = s.replace(/\[(\d+)\]/g, ".$1").split(".").filter((f) => f !== "");
24
+ let r = t;
25
+ for (const f of n) {
26
+ if (r == null)
27
+ return e;
28
+ r = r[f];
29
+ }
30
+ return r !== void 0 ? r : e;
31
+ }
32
+ function a(t) {
33
+ var n;
34
+ if (t = $(t), t == null)
35
+ return 0;
36
+ const s = typeof t;
37
+ if (s === "boolean")
38
+ return 4;
39
+ if (s === "number")
40
+ return 8;
41
+ if (s === "string")
42
+ return t.length * 2;
43
+ if (s === "symbol" || t instanceof Date)
44
+ return 8;
45
+ if (t instanceof RegExp)
46
+ return a(t.source) + a(t.flags);
47
+ let e = 0;
48
+ if (e += 24, Array.isArray(t)) {
49
+ e += 4;
50
+ for (const r of t)
51
+ e += 8, e += a(r);
52
+ } else
53
+ for (const r in t)
54
+ (n = t == null ? void 0 : t.hasOwnProperty) != null && n.call(t, r) && (e += r.length * 2, e += 8, e += a(t[r]));
55
+ return e;
56
+ }
57
+ function S(t, s = {}) {
58
+ const { precision: e = 2, useBinary: n = !0, includeUnit: r = !0 } = s;
59
+ if (t === 0)
60
+ return r ? "0 Bytes" : "0";
61
+ const f = n ? ["B", "KiB", "MiB", "GiB", "TiB", "PiB"] : ["B", "KB", "MB", "GB", "TB", "PB"], i = n ? 1024 : 1e3;
62
+ let c = 0;
63
+ for (; t >= i && c < f.length - 1; )
64
+ t /= i, c++;
65
+ const u = t.toFixed(e);
66
+ return r ? `${u} ${f[c]}` : u;
67
+ }
68
+ function o(t, s = {
69
+ maxDepth: 10,
70
+ visited: /* @__PURE__ */ new WeakMap()
71
+ }) {
72
+ const { maxDepth: e, visited: n } = s;
73
+ return t === null || typeof t != "object" ? JSON.stringify(t) : n.has(t) ? "[Circular]" : (n.set(t, !0), t instanceof Date ? `"${t.toISOString()}"` : t instanceof RegExp ? `/^${t.source}$/${t.flags}` : e <= 0 ? typeof t == "object" ? "{}" : "[]" : Array.isArray(t) ? `[${t.map(
74
+ (c) => o(c, { maxDepth: e - 1, visited: n })
75
+ ).join(", ")}]` : `{${Object.keys(t).map((i) => {
76
+ const c = o(t[i], {
77
+ maxDepth: e - 1,
78
+ visited: n
79
+ });
80
+ return `"${i}": ${c}`;
81
+ }).join(", ")}}`);
82
+ }
83
+ function $(t, s = 6) {
84
+ const e = /* @__PURE__ */ new WeakMap();
85
+ function n(r, f, i = []) {
86
+ if (g(r))
87
+ return `${r}`;
88
+ if (p(r))
89
+ return `${r}`;
90
+ if (y(r))
91
+ return "f(...) { ... }";
92
+ if (m(r))
93
+ return `${r}`;
94
+ if (!B(r))
95
+ return r;
96
+ if (f <= 0)
97
+ return "[MaxDepth]";
98
+ if (e.has(r))
99
+ return `[Circular: ${e.get(r).join(".")}]`;
100
+ if (e.set(r, [...i]), Array.isArray(r))
101
+ return r.map(
102
+ (u, l) => n(u, f - 1, [...i, String(l)])
103
+ );
104
+ const c = {};
105
+ for (const [u, l] of Object.entries(r))
106
+ c[u] = n(l, f - 1, [...i, u]);
107
+ return c;
108
+ }
109
+ return n(t, s);
110
+ }
111
+ export {
112
+ a as calculateObjectSize,
113
+ S as formatStorageSize,
114
+ x as getValueByPath,
115
+ $ as parseValue,
116
+ o as serializeCircular,
117
+ h as setValueByPath
118
+ };
@@ -0,0 +1,7 @@
1
+ /**
2
+ * 获取当前页面地址
3
+ *
4
+ * @return {*}
5
+ */
6
+ export declare function getCurrentPagePath(): string;
7
+ //# sourceMappingURL=page.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"page.d.ts","sourceRoot":"","sources":["../../dev/utils/page.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,wBAAgB,kBAAkB,WAOjC"}
@@ -0,0 +1,7 @@
1
+ function r() {
2
+ let t = getCurrentPages(), e = t[t.length - 1];
3
+ return e && e.route ? e.route : "";
4
+ }
5
+ export {
6
+ r as getCurrentPagePath
7
+ };
@@ -0,0 +1,4 @@
1
+ export declare function isH5(): boolean;
2
+ export declare function isWX(): boolean;
3
+ export declare function isAndroid(): boolean;
4
+ //# sourceMappingURL=platform.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"platform.d.ts","sourceRoot":"","sources":["../../dev/utils/platform.ts"],"names":[],"mappings":"AAAA,wBAAgB,IAAI,IAAI,OAAO,CAE9B;AAED,wBAAgB,IAAI,YAEnB;AAED,wBAAgB,SAAS,YAKxB"}
@@ -0,0 +1,14 @@
1
+ function n() {
2
+ return !0;
3
+ }
4
+ function r() {
5
+ return !1;
6
+ }
7
+ function t() {
8
+ return !1;
9
+ }
10
+ export {
11
+ t as isAndroid,
12
+ n as isH5,
13
+ r as isWX
14
+ };
@@ -0,0 +1,45 @@
1
+ /**
2
+ * 将匹配到的字符串高亮显示
3
+ *
4
+ * @export
5
+ * @param {string} [str='']
6
+ * @param {string} [search='']
7
+ * @return {*}
8
+ */
9
+ export declare function hightLight(str?: string, search?: string): string;
10
+ export declare function escapeHTML(unsafe: string): string;
11
+ /**
12
+ * 在字符串中获取url
13
+ *
14
+ * @export
15
+ * @param {string} text
16
+ * @return {*}
17
+ */
18
+ export declare function extractUrl(text: string): string;
19
+ /**
20
+ * 获取url 中末尾的行号和列号
21
+ *
22
+ * @export
23
+ * @param {string} url
24
+ * @return {*}
25
+ */
26
+ export declare function extractRowAndCol(url: string): {
27
+ row: number;
28
+ col: number;
29
+ };
30
+ /**
31
+ * 解析栈信息
32
+ *
33
+ * @export
34
+ * @param {string} stack
35
+ * @return {*}
36
+ */
37
+ export declare function parseStock(stack: string): {
38
+ info: string;
39
+ path: string;
40
+ row: number;
41
+ col: number;
42
+ };
43
+ export declare function isMockWX(stack: string): boolean;
44
+ export declare function uniqueId(pre?: string, length?: number, chars?: string): string;
45
+ //# sourceMappingURL=string.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"string.d.ts","sourceRoot":"","sources":["../../dev/utils/string.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AACH,wBAAgB,UAAU,CAAC,GAAG,GAAE,MAAW,EAAE,MAAM,GAAE,MAAW,UAc/D;AAED,wBAAgB,UAAU,CAAC,MAAM,EAAE,MAAM,UA4BxC;AAGD;;;;;;GAMG;AACH,wBAAgB,UAAU,CAAC,IAAI,EAAE,MAAM,UAGtC;AAGD;;;;;;GAMG;AACH,wBAAgB,gBAAgB,CAAC,GAAG,EAAE,MAAM;;;EAe3C;AAUD;;;;;;GAMG;AACH,wBAAgB,UAAU,CAAC,KAAK,EAAE,MAAM;;;;;EAQvC;AAGD,wBAAgB,QAAQ,CAAC,KAAK,EAAE,MAAM,WAErC;AAED,wBAAgB,QAAQ,CACtB,GAAG,GAAE,MAAW,EAChB,MAAM,SAAK,EACX,KAAK,SAAmE,GACvE,MAAM,CAMR"}
@@ -0,0 +1,88 @@
1
+ function p(n = "", t = "") {
2
+ if (!n)
3
+ return "";
4
+ if (!t)
5
+ return n;
6
+ const o = t.replace(/[.*+?^${}()|[\]\\]/g, "\\$&"), r = new RegExp(o, "g");
7
+ return n.replace(
8
+ r,
9
+ `<span style="color:#fff; background-color: var(--dev-tool-main-color);">${t}</span>`
10
+ );
11
+ }
12
+ function i(n) {
13
+ if (!n)
14
+ return "";
15
+ const t = {
16
+ "&": "&amp;",
17
+ '"': "&quot;",
18
+ "'": "&#39;",
19
+ ">": "&gt;",
20
+ "<": "&lt;",
21
+ "=": "&#61;",
22
+ "+": "&#43;",
23
+ "-": "&#45;",
24
+ "(": "&#40;",
25
+ ")": "&#41;",
26
+ "[": "&#91;",
27
+ "]": "&#93;",
28
+ "{": "&#123;",
29
+ "}": "&#125;",
30
+ ".": "&#46;",
31
+ "?": "&#63;",
32
+ "/": "&#47;",
33
+ ":": "&#58;"
34
+ };
35
+ return n.replace(
36
+ /[&"'><=+\-().?\/:[\]{}]/g,
37
+ (o) => t[o] || o
38
+ );
39
+ }
40
+ const s = /https?:\/\/[^\s/$.?#](?:(?!\s|\)).)*/g;
41
+ function a(n) {
42
+ const t = n.match(s);
43
+ return t ? t[0] : "";
44
+ }
45
+ const c = /:(\d+)(?::(\d+))?\)?$/;
46
+ function f(n) {
47
+ const t = n.match(c);
48
+ if (t) {
49
+ const o = t[1], r = t[2];
50
+ return {
51
+ row: parseInt(o) - 1,
52
+ col: parseInt(r) - 1
53
+ };
54
+ }
55
+ return {
56
+ row: -1,
57
+ col: -1
58
+ };
59
+ }
60
+ const u = /at\s+(?:([^(]+)\s+\()?((?:[^:\/\s]+(?:\/[^:\/\s]+)*\.[^:\/\s]+)|(?:[^:]+:\/\/[^:\/\s]+(?::\d+)?(?:\/[^:\s]*)*)):(\d+)(?::(\d+))?(?:\s*\)?)?$/;
61
+ function g(n) {
62
+ const t = n.match(u);
63
+ return {
64
+ info: (t == null ? void 0 : t[1]) ?? "",
65
+ path: (t == null ? void 0 : t[2]) ?? "",
66
+ row: t != null && t[3] ? parseInt(t == null ? void 0 : t[3]) - 1 : -1,
67
+ col: t != null && t[4] ? parseInt(t == null ? void 0 : t[4]) - 1 : -1
68
+ };
69
+ }
70
+ const l = /https?:\/\/usr/;
71
+ function d(n) {
72
+ return l.test(n);
73
+ }
74
+ function w(n = "", t = 16, o = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789") {
75
+ let r = "";
76
+ for (let e = 0; e < t; e++)
77
+ r += o.charAt(Math.floor(Math.random() * o.length));
78
+ return n + r;
79
+ }
80
+ export {
81
+ i as escapeHTML,
82
+ f as extractRowAndCol,
83
+ a as extractUrl,
84
+ p as hightLight,
85
+ d as isMockWX,
86
+ g as parseStock,
87
+ w as uniqueId
88
+ };
@@ -0,0 +1,16 @@
1
+ /**
2
+ * 获取当前页面地址
3
+ *
4
+ * @return {*}
5
+ */
6
+ export declare function getCurrentPagePath(): string;
7
+ /** 截图 */
8
+ export declare function screenshot(): void;
9
+ export declare function captureScreen(option: {
10
+ success?: () => void;
11
+ }): void;
12
+ export interface DeepEqualOptions {
13
+ maxDepth?: number;
14
+ }
15
+ export declare function deepEqual(a: unknown, b: unknown, options?: DeepEqualOptions): boolean;
16
+ //# sourceMappingURL=utils.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../dev/utils/utils.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,wBAAgB,kBAAkB,WAOjC;AAED,SAAS;AACT,wBAAgB,UAAU,SAsDzB;AAGD,wBAAgB,aAAa,CAAC,MAAM,EAAE;IAAE,OAAO,CAAC,EAAE,MAAM,IAAI,CAAA;CAAE,QA4B7D;AAUD,MAAM,WAAW,gBAAgB;IAC/B,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB;AAED,wBAAgB,SAAS,CACvB,CAAC,EAAE,OAAO,EACV,CAAC,EAAE,OAAO,EACV,OAAO,GAAE,gBAAmC,GAC3C,OAAO,CAKT"}
@@ -0,0 +1,5 @@
1
+ import { ComponentInternalInstance } from 'vue';
2
+
3
+ export declare function getRect(selector: string, context: ComponentInternalInstance | null | any, node?: boolean): Promise<UniApp.NodeInfo>;
4
+ export declare function addUnit(value?: string | number): string;
5
+ //# sourceMappingURL=utils.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../dev/v2/AutoSizer/utils.ts"],"names":[],"mappings":";AAAA,OAAO,KAAK,EAAE,yBAAyB,EAA2B,MAAM,KAAK,CAAC;AAE9E,wBAAgB,OAAO,CACrB,QAAQ,EAAE,MAAM,EAChB,OAAO,EAAE,yBAAyB,GAAG,IAAI,GAAG,GAAG,EAC/C,IAAI,GAAE,OAAe,4BAmCtB;AAED,wBAAgB,OAAO,CAAC,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,MAAM,CAMvD"}
@@ -0,0 +1,4 @@
1
+ export declare function useClipboard(): {
2
+ copy: (source: string) => Promise<void>;
3
+ };
4
+ //# sourceMappingURL=useClipboard.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useClipboard.d.ts","sourceRoot":"","sources":["../../../../dev/v2/JsonPretty/hooks/useClipboard.ts"],"names":[],"mappings":"AAEA,wBAAgB,YAAY;mBAGE,MAAM;EAenC"}
@@ -0,0 +1,8 @@
1
+ type UseErrorOptions = {
2
+ emitListener: boolean;
3
+ };
4
+ export declare function useError(message: string, { emitListener }: UseErrorOptions): {
5
+ emit: () => never;
6
+ };
7
+ export {};
8
+ //# sourceMappingURL=useError.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useError.d.ts","sourceRoot":"","sources":["../../../../dev/v2/JsonPretty/hooks/useError.ts"],"names":[],"mappings":"AAEA,KAAK,eAAe,GAAG;IACrB,YAAY,EAAE,OAAO,CAAC;CACvB,CAAC;AAEF,wBAAgB,QAAQ,CAAC,OAAO,EAAE,MAAM,EAAE,EAAE,YAAY,EAAE,EAAE,eAAe;;EAc1E"}
@@ -0,0 +1,93 @@
1
+ import { CSSProperties } from 'vue';
2
+
3
+ export type JsonPrettyNodeProps = {
4
+ data: any;
5
+ rootPath: string;
6
+ indent: number;
7
+ showLength: boolean;
8
+ showDoubleQuotes: boolean;
9
+ renderNodeKey: any;
10
+ renderNodeValue: any;
11
+ };
12
+ export interface NodeDataType extends JSONFlattenReturnType {
13
+ id: number;
14
+ }
15
+ export interface JSONFlattenOptions {
16
+ key?: string;
17
+ index?: number;
18
+ showComma: boolean;
19
+ length: number;
20
+ type: 'content' | 'objectStart' | 'objectEnd' | 'objectCollapsed' | 'arrayStart' | 'arrayEnd' | 'arrayCollapsed';
21
+ }
22
+ export type JSONDataType = string | number | boolean | unknown[] | Record<string, unknown> | null;
23
+ export interface JSONFlattenReturnType extends JSONFlattenOptions {
24
+ content: string | number | null | boolean;
25
+ level: number;
26
+ path: string;
27
+ }
28
+ export type StyleValue = false | null | undefined | string | CSSProperties | Array<StyleValue>;
29
+ type SelectableType = 'single' | 'multiple' | null;
30
+ export type TreeNodeProps = Partial<{
31
+ data: any;
32
+ indent: number;
33
+ showLength: boolean;
34
+ showDoubleQuotes: boolean;
35
+ selectableType: SelectableType;
36
+ showSelectController: boolean;
37
+ showLine: boolean;
38
+ showLineNumber: boolean;
39
+ showNodeActions: boolean;
40
+ selectOnClickNode: boolean;
41
+ highlightSelectedNode: boolean;
42
+ showIcon: boolean;
43
+ theme: string;
44
+ showKeyValueSpace: boolean;
45
+ editable: boolean;
46
+ editableTrigger: string;
47
+ node: NodeDataType;
48
+ checked: boolean;
49
+ collapsed: boolean;
50
+ style: CSSProperties;
51
+ fontSize: string;
52
+ onNodeClick: (node: NodeDataType) => void;
53
+ onNodeMouseover: (node: NodeDataType) => void;
54
+ onBracketsClick: (collapsed: boolean, node: NodeDataType) => void;
55
+ onIconClick: (collapsed: boolean, node: NodeDataType) => void;
56
+ onValueChange: (value: boolean, path: string) => void;
57
+ onSelectedChange: (node: NodeDataType) => void;
58
+ }> & TreeNodeRequiredProps;
59
+ export type TreeNodeRequiredProps = {
60
+ node: NodeDataType;
61
+ rootPath: string;
62
+ nodeSelectable: (node: NodeDataType) => boolean;
63
+ };
64
+ export type TreeRequired = TreeNodeRequiredProps & {};
65
+ export type Tree = Partial<TreeNodeProps> & Partial<{
66
+ deep: number;
67
+ collapsedNodeLength: number;
68
+ virtual: boolean;
69
+ itemHeight: number;
70
+ height: number;
71
+ selectedValue: string | Array<any>;
72
+ collapsedOnClickBrackets: boolean;
73
+ style: CSSProperties;
74
+ pathCollapsible: (node: NodeDataType) => boolean;
75
+ /** 超过行数将会自动启用虚拟列表 */
76
+ autoVirtualRow: number;
77
+ } & TreeRequired>;
78
+ export interface ScrollEvent {
79
+ detail: {
80
+ scrollLeft: number;
81
+ scrollTop: number;
82
+ scrollHeight: number;
83
+ scrollWidth: number;
84
+ deltaX: number;
85
+ deltaY: number;
86
+ };
87
+ target: EventTarget;
88
+ currentTarget: EventTarget;
89
+ timeStamp: number;
90
+ type: string;
91
+ }
92
+ export {};
93
+ //# sourceMappingURL=type.d.ts.map