@pubinfo/devtools 2.1.10 → 2.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.
- package/dist/client/assets/{Navbar-BQK6jUhq.js → Navbar-DYyO71VR.js} +27 -3
- package/dist/client/assets/{PanelGrids-Bd6D6enp.js → PanelGrids-rTFcKhN6.js} +4 -2
- package/dist/client/assets/{SelectTabs-CTO4P53M.js → SelectTabs-Ba4fEjYh.js} +17 -2
- package/dist/client/assets/{_plugin-vue_export-helper-D8E0syuh.js → _plugin-vue_export-helper-Ctigiz3_.js} +2 -0
- package/dist/client/assets/{component-D5gKG7wj.js → component-Cy0W8Ddj.js} +39 -4
- package/dist/client/assets/{core-D6JqxgYq.js → core-CrqZ8qrs.js} +1300 -24
- package/dist/client/assets/{css-DbgpCiOq.js → css-3PrNsnPt.js} +1 -0
- package/dist/client/assets/css-mRoPUXX2.js +2 -0
- package/dist/client/assets/{engine-oniguruma-n-bafM3H.js → engine-oniguruma-C1mOz3PQ.js} +2 -0
- package/dist/client/assets/{fetch-CFHiXvGO.js → fetch-Bz1BNH1Z.js} +159 -5
- package/dist/client/assets/{html-Tu6OX5Eq.js → html-B5Ny8iin.js} +4 -2
- package/dist/client/assets/html-g0uz4re7.js +2 -0
- package/dist/client/assets/{import-w1c5mo52.js → import-gNFdeWVi.js} +33 -4
- package/dist/client/assets/index-CWvhvxM4.js +5208 -0
- package/dist/client/assets/{issue-CCThaaVh.js → issue-Yr5hL5Lv.js} +22 -3
- package/dist/client/assets/{javascript-_FvKZjd1.js → javascript-D9OtNJpI.js} +1 -0
- package/dist/client/assets/javascript-yBXmlTMV.js +2 -0
- package/dist/client/assets/json-CDHOIUIc.js +2 -0
- package/dist/client/assets/{json-CzPoZe0r.js → json-DFv6u-UA.js} +1 -0
- package/dist/client/assets/{pages-Cq5pNVp0.js → pages-CuyX8oYZ.js} +33 -9
- package/dist/client/assets/{index-D_HRlfbv.js → runtime-core.esm-bundler-CsZVtwV7.js} +153 -4755
- package/dist/client/assets/{server-router-BJdAYxdf.js → server-router-BkLhbRZZ.js} +177 -18
- package/dist/client/assets/{typescript-BEfC8S_c.js → typescript-C6a_X60d.js} +1 -0
- package/dist/client/assets/typescript-jte7_wp4.js +2 -0
- package/dist/client/assets/{vitesse-dark-Bz6RXfkV.js → vitesse-dark-Dd6LUkEf.js} +2 -0
- package/dist/client/assets/{vitesse-light-NvDlvJl2.js → vitesse-light-LEkeIfQx.js} +2 -0
- package/dist/client/assets/{vue-DZSPIjN6.js → vue-BvqQiUzU.js} +11 -5
- package/dist/client/assets/{wasm-D0Echd05.js → wasm-bCjRd0-o.js} +2 -0
- package/dist/client/index.html +2 -1
- package/package.json +3 -3
- package/dist/client/assets/css-D-vtiAqw.js +0 -2
- package/dist/client/assets/html-74krLQbR.js +0 -2
- package/dist/client/assets/javascript-QnJdw8u5.js +0 -2
- package/dist/client/assets/json-WgRhEAOB.js +0 -2
- package/dist/client/assets/typescript-C5tShSk5.js +0 -2
|
@@ -1,7 +1,11 @@
|
|
|
1
|
-
import { B as
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
1
|
+
import { B as withDirectives, E as openBlock, F as useModel, G as isRef, N as resolveDirective, S as mergeProps, c as createBaseVNode, d as createElementBlock, g as defineComponent, h as createVNode, j as renderSlot, l as createBlock, m as createTextVNode, nt as unref, r as Fragment, u as createCommentVNode, wt as toDisplayString, x as mergeModels, xt as normalizeClass, y as h, z as withCtx } from "./runtime-core.esm-bundler-CsZVtwV7.js";
|
|
2
|
+
import { a as vModelDynamic, n as RouterLink } from "./index-CWvhvxM4.js";
|
|
3
|
+
import { f as useVModel } from "./fetch-Bz1BNH1Z.js";
|
|
4
|
+
import { t as _plugin_vue_export_helper_default } from "./_plugin-vue_export-helper-Ctigiz3_.js";
|
|
5
|
+
//#region src/client/@ui/IconTitle.vue?vue&type=script&setup=true&lang.ts
|
|
4
6
|
var _hoisted_1$3 = { class: "flex gap-3 items-center" };
|
|
7
|
+
//#endregion
|
|
8
|
+
//#region src/client/@ui/IconTitle.vue
|
|
5
9
|
var IconTitle_default = /* @__PURE__ */ defineComponent({
|
|
6
10
|
__name: "IconTitle",
|
|
7
11
|
props: {
|
|
@@ -17,6 +21,8 @@ var IconTitle_default = /* @__PURE__ */ defineComponent({
|
|
|
17
21
|
};
|
|
18
22
|
}
|
|
19
23
|
});
|
|
24
|
+
//#endregion
|
|
25
|
+
//#region src/client/@ui/Icon.vue
|
|
20
26
|
var Icon_default = /* @__PURE__ */ defineComponent({
|
|
21
27
|
__name: "Icon",
|
|
22
28
|
props: { icon: {} },
|
|
@@ -26,6 +32,8 @@ var Icon_default = /* @__PURE__ */ defineComponent({
|
|
|
26
32
|
};
|
|
27
33
|
}
|
|
28
34
|
});
|
|
35
|
+
//#endregion
|
|
36
|
+
//#region src/client/@ui/SectionBlock.vue?vue&type=script&setup=true&lang.ts
|
|
29
37
|
var _hoisted_1$2 = ["open"];
|
|
30
38
|
var _hoisted_2 = { "text-base": "" };
|
|
31
39
|
var _hoisted_3 = {
|
|
@@ -33,6 +41,8 @@ var _hoisted_3 = {
|
|
|
33
41
|
"text-sm": "",
|
|
34
42
|
op50: ""
|
|
35
43
|
};
|
|
44
|
+
//#endregion
|
|
45
|
+
//#region src/client/@ui/SectionBlock.vue
|
|
36
46
|
var SectionBlock_default = /* @__PURE__ */ _plugin_vue_export_helper_default(/* @__PURE__ */ defineComponent({
|
|
37
47
|
__name: "SectionBlock",
|
|
38
48
|
props: {
|
|
@@ -102,6 +112,11 @@ var SectionBlock_default = /* @__PURE__ */ _plugin_vue_export_helper_default(/*
|
|
|
102
112
|
};
|
|
103
113
|
}
|
|
104
114
|
}), [["__scopeId", "data-v-deaf669f"]]);
|
|
115
|
+
//#endregion
|
|
116
|
+
//#region src/client/@ui/Button.ts
|
|
117
|
+
/**
|
|
118
|
+
* 判断是否为外部链接
|
|
119
|
+
*/
|
|
105
120
|
function isExternalLink(to) {
|
|
106
121
|
if (!to) return false;
|
|
107
122
|
return /^(https?:|mailto:|tel:)/.test(to);
|
|
@@ -157,7 +172,11 @@ var Button_default = defineComponent({
|
|
|
157
172
|
};
|
|
158
173
|
}
|
|
159
174
|
});
|
|
175
|
+
//#endregion
|
|
176
|
+
//#region src/client/@ui/TextInput.vue?vue&type=script&setup=true&lang.ts
|
|
160
177
|
var _hoisted_1$1 = { class: "flex items-center border n-border-base rounded n-bg-base py-1 pl-1 pr-2 focus-within:border-primary" };
|
|
178
|
+
//#endregion
|
|
179
|
+
//#region src/client/@ui/TextInput.vue
|
|
161
180
|
var TextInput_default = /* @__PURE__ */ defineComponent({
|
|
162
181
|
__name: "TextInput",
|
|
163
182
|
props: {
|
|
@@ -186,7 +205,11 @@ var TextInput_default = /* @__PURE__ */ defineComponent({
|
|
|
186
205
|
};
|
|
187
206
|
}
|
|
188
207
|
});
|
|
208
|
+
//#endregion
|
|
209
|
+
//#region src/client/@ui/Navbar.vue?vue&type=script&setup=true&lang.ts
|
|
189
210
|
var _hoisted_1 = { class: "flex gap-4 flex-wrap items-center" };
|
|
211
|
+
//#endregion
|
|
212
|
+
//#region src/client/@ui/Navbar.vue
|
|
190
213
|
var Navbar_default = /* @__PURE__ */ defineComponent({
|
|
191
214
|
name: "Navbar",
|
|
192
215
|
__name: "Navbar",
|
|
@@ -216,4 +239,5 @@ var Navbar_default = /* @__PURE__ */ defineComponent({
|
|
|
216
239
|
};
|
|
217
240
|
}
|
|
218
241
|
});
|
|
242
|
+
//#endregion
|
|
219
243
|
export { Icon_default as a, SectionBlock_default as i, TextInput_default as n, Button_default as r, Navbar_default as t };
|
|
@@ -1,9 +1,11 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { t as _plugin_vue_export_helper_default } from "./_plugin-vue_export-helper-
|
|
1
|
+
import { E as openBlock, d as createElementBlock, j as renderSlot } from "./runtime-core.esm-bundler-CsZVtwV7.js";
|
|
2
|
+
import { t as _plugin_vue_export_helper_default } from "./_plugin-vue_export-helper-Ctigiz3_.js";
|
|
3
|
+
//#region src/client/@ui/PanelGrids.vue
|
|
3
4
|
var _sfc_main = {};
|
|
4
5
|
var _hoisted_1 = { class: "n-panel-grids-center" };
|
|
5
6
|
function _sfc_render(_ctx, _cache) {
|
|
6
7
|
return openBlock(), createElementBlock("div", _hoisted_1, [renderSlot(_ctx.$slots, "default")]);
|
|
7
8
|
}
|
|
8
9
|
var PanelGrids_default = /* @__PURE__ */ _plugin_vue_export_helper_default(_sfc_main, [["render", _sfc_render]]);
|
|
10
|
+
//#endregion
|
|
9
11
|
export { PanelGrids_default as t };
|
|
@@ -1,5 +1,7 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import { A as renderList, B as withDirectives, E as openBlock, G as isRef, Y as ref, c as createBaseVNode, d as createElementBlock, g as defineComponent, j as renderSlot, nt as unref, r as Fragment, s as computed, u as createCommentVNode, w as onBeforeUnmount, wt as toDisplayString, xt as normalizeClass } from "./runtime-core.esm-bundler-CsZVtwV7.js";
|
|
2
|
+
import { o as vModelRadio } from "./index-CWvhvxM4.js";
|
|
3
|
+
import { f as useVModel, l as useClipboard } from "./fetch-Bz1BNH1Z.js";
|
|
4
|
+
//#region src/client/composables/open-in-editor.ts
|
|
3
5
|
var OPEN_IN_EDITOR_ENDPOINT = "/__open-in-editor";
|
|
4
6
|
function normalizeFilepath(file) {
|
|
5
7
|
return file.replace(/\\/g, "/");
|
|
@@ -9,6 +11,10 @@ function buildEditorRequestPath(file, line, column) {
|
|
|
9
11
|
if (line == null) return normalized;
|
|
10
12
|
return `${normalized}:${Number.isFinite(line) ? Math.max(1, Math.round(line)) : 1}:${column != null && Number.isFinite(column) ? Math.max(1, Math.round(column)) : 1}`;
|
|
11
13
|
}
|
|
14
|
+
/**
|
|
15
|
+
* Open a source file in the local editor via Vite's `/__open-in-editor` endpoint.
|
|
16
|
+
* Falls back silently if the request fails (e.g. command not supported).
|
|
17
|
+
*/
|
|
12
18
|
async function openInEditor(file, line, column) {
|
|
13
19
|
if (!file) return false;
|
|
14
20
|
const requestPath = buildEditorRequestPath(file, line, column);
|
|
@@ -28,6 +34,8 @@ async function openInEditor(file, line, column) {
|
|
|
28
34
|
return false;
|
|
29
35
|
}
|
|
30
36
|
}
|
|
37
|
+
//#endregion
|
|
38
|
+
//#region src/client/components/FilepathItem.vue?vue&type=script&setup=true&lang.ts
|
|
31
39
|
var _hoisted_1$1 = { class: "flex gap-2 items-center group" };
|
|
32
40
|
var _hoisted_2$1 = ["title"];
|
|
33
41
|
var _hoisted_3$1 = {
|
|
@@ -36,6 +44,8 @@ var _hoisted_3$1 = {
|
|
|
36
44
|
};
|
|
37
45
|
var _hoisted_4 = ["title"];
|
|
38
46
|
var _hoisted_5 = ["title"];
|
|
47
|
+
//#endregion
|
|
48
|
+
//#region src/client/components/FilepathItem.vue
|
|
39
49
|
var FilepathItem_default = /* @__PURE__ */ defineComponent({
|
|
40
50
|
__name: "FilepathItem",
|
|
41
51
|
props: {
|
|
@@ -129,6 +139,8 @@ var FilepathItem_default = /* @__PURE__ */ defineComponent({
|
|
|
129
139
|
};
|
|
130
140
|
}
|
|
131
141
|
});
|
|
142
|
+
//#endregion
|
|
143
|
+
//#region src/client/@ui/SelectTabs.vue?vue&type=script&setup=true&lang.ts
|
|
132
144
|
var _hoisted_1 = { class: "flex flex-inline flex-wrap items-center border n-border-base rounded n-bg-base" };
|
|
133
145
|
var _hoisted_2 = ["disabled", "title"];
|
|
134
146
|
var _hoisted_3 = [
|
|
@@ -136,6 +148,8 @@ var _hoisted_3 = [
|
|
|
136
148
|
"value",
|
|
137
149
|
"title"
|
|
138
150
|
];
|
|
151
|
+
//#endregion
|
|
152
|
+
//#region src/client/@ui/SelectTabs.vue
|
|
139
153
|
var SelectTabs_default = /* @__PURE__ */ defineComponent({
|
|
140
154
|
name: "SelectTabs",
|
|
141
155
|
__name: "SelectTabs",
|
|
@@ -168,4 +182,5 @@ var SelectTabs_default = /* @__PURE__ */ defineComponent({
|
|
|
168
182
|
};
|
|
169
183
|
}
|
|
170
184
|
});
|
|
185
|
+
//#endregion
|
|
171
186
|
export { FilepathItem_default as n, SelectTabs_default as t };
|
|
@@ -1,6 +1,8 @@
|
|
|
1
|
+
//#region \0plugin-vue:export-helper
|
|
1
2
|
var _plugin_vue_export_helper_default = (sfc, props) => {
|
|
2
3
|
const target = sfc.__vccOpts || sfc;
|
|
3
4
|
for (const [key, val] of props) target[key] = val;
|
|
4
5
|
return target;
|
|
5
6
|
};
|
|
7
|
+
//#endregion
|
|
6
8
|
export { _plugin_vue_export_helper_default as t };
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { a as Icon_default, i as SectionBlock_default, r as Button_default, t as Navbar_default } from "./Navbar-
|
|
3
|
-
import { l as useClipboard, n as componentUsageFetch, o as Badge_default } from "./fetch-
|
|
4
|
-
import { n as FilepathItem_default, t as SelectTabs_default } from "./SelectTabs-
|
|
1
|
+
import { A as renderList, E as openBlock, G as isRef, M as resolveComponent, Y as ref, c as createBaseVNode, d as createElementBlock, g as defineComponent, h as createVNode, j as renderSlot, l as createBlock, m as createTextVNode, nt as unref, r as Fragment, s as computed, u as createCommentVNode, w as onBeforeUnmount, wt as toDisplayString, xt as normalizeClass, z as withCtx } from "./runtime-core.esm-bundler-CsZVtwV7.js";
|
|
2
|
+
import { a as Icon_default, i as SectionBlock_default, r as Button_default, t as Navbar_default } from "./Navbar-DYyO71VR.js";
|
|
3
|
+
import { l as useClipboard, n as componentUsageFetch, o as Badge_default } from "./fetch-Bz1BNH1Z.js";
|
|
4
|
+
import { n as FilepathItem_default, t as SelectTabs_default } from "./SelectTabs-Ba4fEjYh.js";
|
|
5
|
+
//#region ../../node_modules/.pnpm/scule@1.3.0/node_modules/scule/dist/index.mjs
|
|
5
6
|
var NUMBER_CHAR_RE = /\d/;
|
|
6
7
|
var STR_SPLITTERS = [
|
|
7
8
|
"-",
|
|
@@ -57,7 +58,11 @@ function upperFirst(str) {
|
|
|
57
58
|
function pascalCase(str, opts) {
|
|
58
59
|
return str ? (Array.isArray(str) ? str : splitByCase(str)).map((p) => upperFirst(opts?.normalize ? p.toLowerCase() : p)).join("") : "";
|
|
59
60
|
}
|
|
61
|
+
//#endregion
|
|
62
|
+
//#region src/client/components/ComponentName.vue?vue&type=script&setup=true&lang.ts
|
|
60
63
|
var _hoisted_1$3 = { class: "text-sm font-mono" };
|
|
64
|
+
//#endregion
|
|
65
|
+
//#region src/client/components/ComponentName.vue
|
|
61
66
|
var ComponentName_default = /* @__PURE__ */ defineComponent({
|
|
62
67
|
__name: "ComponentName",
|
|
63
68
|
props: { component: {} },
|
|
@@ -73,6 +78,8 @@ var ComponentName_default = /* @__PURE__ */ defineComponent({
|
|
|
73
78
|
};
|
|
74
79
|
}
|
|
75
80
|
});
|
|
81
|
+
//#endregion
|
|
82
|
+
//#region src/client/components/ComponentDetails.vue?vue&type=script&setup=true&lang.ts
|
|
76
83
|
var _hoisted_1$2 = { class: "flex flex-col gap-1 items-start of-hidden" };
|
|
77
84
|
var _hoisted_2$2 = { class: "flex gap-2 items-center px-3" };
|
|
78
85
|
var _hoisted_3$1 = {
|
|
@@ -89,6 +96,8 @@ var _hoisted_6$1 = {
|
|
|
89
96
|
"text-sm": "",
|
|
90
97
|
op75: ""
|
|
91
98
|
};
|
|
99
|
+
//#endregion
|
|
100
|
+
//#region src/client/components/ComponentDetails.vue
|
|
92
101
|
var ComponentDetails_default = /* @__PURE__ */ defineComponent({
|
|
93
102
|
__name: "ComponentDetails",
|
|
94
103
|
props: {
|
|
@@ -229,11 +238,15 @@ var ComponentDetails_default = /* @__PURE__ */ defineComponent({
|
|
|
229
238
|
};
|
|
230
239
|
}
|
|
231
240
|
});
|
|
241
|
+
//#endregion
|
|
242
|
+
//#region src/client/components/ComponentItem.vue?vue&type=script&setup=true&lang.ts
|
|
232
243
|
var _hoisted_1$1 = { class: "group flex gap-2 w-full items-center rounded px-2 py-1 hoverLbg-active" };
|
|
233
244
|
var _hoisted_2$1 = {
|
|
234
245
|
key: 0,
|
|
235
246
|
class: "ml--1 text-primary"
|
|
236
247
|
};
|
|
248
|
+
//#endregion
|
|
249
|
+
//#region src/client/components/ComponentItem.vue
|
|
237
250
|
var ComponentItem_default = /* @__PURE__ */ defineComponent({
|
|
238
251
|
__name: "ComponentItem",
|
|
239
252
|
props: {
|
|
@@ -287,6 +300,8 @@ var ComponentItem_default = /* @__PURE__ */ defineComponent({
|
|
|
287
300
|
};
|
|
288
301
|
}
|
|
289
302
|
});
|
|
303
|
+
//#endregion
|
|
304
|
+
//#region src/client/pages/component.vue?vue&type=script&setup=true&lang.ts
|
|
290
305
|
var _hoisted_1 = { class: "relative h-full flex flex-col of-hidden" };
|
|
291
306
|
var _hoisted_2 = { class: "flex items-center gap-2" };
|
|
292
307
|
var _hoisted_3 = { class: "flex-1 of-auto" };
|
|
@@ -299,10 +314,23 @@ var _hoisted_6 = {
|
|
|
299
314
|
key: 1,
|
|
300
315
|
class: "text-sm op50 px2 py1"
|
|
301
316
|
};
|
|
317
|
+
//#endregion
|
|
318
|
+
//#region src/client/pages/component.vue
|
|
302
319
|
var component_default = /* @__PURE__ */ defineComponent({
|
|
303
320
|
name: "ComponentPage",
|
|
304
321
|
__name: "component",
|
|
305
322
|
setup(__props) {
|
|
323
|
+
/**
|
|
324
|
+
* Component Usage 页面
|
|
325
|
+
*
|
|
326
|
+
* 作用:
|
|
327
|
+
* - 拉取 devtools 服务端扫描到的组件使用情况。
|
|
328
|
+
* - 支持按关键字搜索与「已使用/未使用」过滤。
|
|
329
|
+
* - 使用 SectionBlock 对不同来源包(vue/pubinfo 等)进行分组展示。
|
|
330
|
+
*
|
|
331
|
+
* 相关数据:
|
|
332
|
+
* - /__pubinfo_devtools_api/component-usage → ComponentUsagePayload
|
|
333
|
+
*/
|
|
306
334
|
const search = ref("");
|
|
307
335
|
const filterMode = ref("all");
|
|
308
336
|
const { execute, data, error, isFetching } = componentUsageFetch;
|
|
@@ -329,11 +357,17 @@ var component_default = /* @__PURE__ */ defineComponent({
|
|
|
329
357
|
});
|
|
330
358
|
return map;
|
|
331
359
|
});
|
|
360
|
+
/**
|
|
361
|
+
* 判断组件是否匹配当前过滤模式
|
|
362
|
+
*/
|
|
332
363
|
function matchesFilter(component, mode) {
|
|
333
364
|
if (mode === "using") return component.count > 0;
|
|
334
365
|
if (mode === "not-used") return component.count === 0;
|
|
335
366
|
return true;
|
|
336
367
|
}
|
|
368
|
+
/**
|
|
369
|
+
* 基于名称、包名与文件路径进行模糊匹配
|
|
370
|
+
*/
|
|
337
371
|
function matchesQuery(component, query) {
|
|
338
372
|
if (!query) return true;
|
|
339
373
|
return [
|
|
@@ -465,4 +499,5 @@ var component_default = /* @__PURE__ */ defineComponent({
|
|
|
465
499
|
};
|
|
466
500
|
}
|
|
467
501
|
});
|
|
502
|
+
//#endregion
|
|
468
503
|
export { component_default as default };
|