vite-plugin-vue-devtools 0.0.22 → 0.1.1
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/README.md +15 -1
- package/dist/client/assets/{IframeView.vue_vue_type_script_setup_true_lang-7a782b7f.js → IframeView.vue_vue_type_script_setup_true_lang-6fd9a85f.js} +22 -4
- package/dist/client/assets/{VCard-1a6832d4.js → VCard-6f5067b2.js} +1 -1
- package/dist/client/assets/{VIcon.vue_vue_type_script_setup_true_lang-13ffd017.js → VIcon.vue_vue_type_script_setup_true_lang-6118ca39.js} +3 -3
- package/dist/client/assets/{VIconButton.vue_vue_type_script_setup_true_lang-186dde54.js → VIconButton.vue_vue_type_script_setup_true_lang-ae9230b8.js} +5 -5
- package/dist/client/assets/{VIconTitle.vue_vue_type_script_setup_true_lang-fc3a2149.js → VIconTitle.vue_vue_type_script_setup_true_lang-b0f889c4.js} +6 -6
- package/dist/client/assets/{VPanelGrids-2dc8992e.js → VPanelGrids-99263922.js} +1 -1
- package/dist/client/assets/{VTextInput.vue_vue_type_script_setup_true_lang-535b6d73.js → VTextInput.vue_vue_type_script_setup_true_lang-a9a84967.js} +19 -19
- package/dist/client/assets/{__inspecting-f04aca07.js → __inspecting-c48a44bd.js} +2 -2
- package/dist/client/assets/{assets-e128fa14.js → assets-da7375f2.js} +37 -37
- package/dist/client/assets/{components-5a527785.js → components-9088ee32.js} +16 -16
- package/dist/client/assets/{documentations-f1b6f767.js → documentations-a53fc5be.js} +20 -20
- package/dist/client/assets/{graph-9f30454f.js → graph-1d314269.js} +2 -2
- package/dist/client/assets/{index-ee58a812.js → index-2f57441c.js} +5982 -6405
- package/dist/client/assets/{index-f8c90594.css → index-673f3336.css} +1 -1
- package/dist/client/assets/{index-347d3959.js → index-de9a3e22.js} +1 -1
- package/dist/client/assets/{inspect-400c2b70.js → inspect-4dd467ef.js} +3 -3
- package/dist/client/assets/{npm-cd00dfa9.js → npm-aa40787f.js} +7 -7
- package/dist/client/assets/{overview-57c2cbd3.js → overview-3d7e9cc1.js} +5 -5
- package/dist/client/assets/{pages-3d8588ac.js → pages-2a327cb7.js} +12 -12
- package/dist/client/assets/{pinia-b4b2eaba.js → pinia-76305a62.js} +5 -5
- package/dist/client/assets/{routes-8e26a6ac.js → routes-eb449762.js} +7 -7
- package/dist/client/assets/{rpc-e28ef409.js → rpc-0cf10553.js} +3 -2
- package/dist/client/assets/{settings-b50a459c.js → settings-16b21837.js} +33 -11
- package/dist/client/assets/{splitpanes.es-5f60be7d.js → splitpanes.es-d9f337b4.js} +20 -20
- package/dist/client/assets/{timeline-99b31af4.js → timeline-b35c200b.js} +13 -13
- package/dist/client/index.html +2 -2
- package/dist/index.cjs +15 -4
- package/dist/index.d.ts +11 -2
- package/dist/index.mjs +15 -4
- package/package.json +22 -22
- package/src/node/Container.vue +54 -20
package/dist/client/index.html
CHANGED
|
@@ -5,8 +5,8 @@
|
|
|
5
5
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
6
6
|
<link rel="icon" href="/favicon.svg" type="image/svg+xml">
|
|
7
7
|
<title>Vue DevTools</title>
|
|
8
|
-
<script type="module" crossorigin src="./assets/index-
|
|
9
|
-
<link rel="stylesheet" href="./assets/index-
|
|
8
|
+
<script type="module" crossorigin src="./assets/index-2f57441c.js"></script>
|
|
9
|
+
<link rel="stylesheet" href="./assets/index-673f3336.css">
|
|
10
10
|
</head>
|
|
11
11
|
<body>
|
|
12
12
|
<div id="app"></div>
|
package/dist/index.cjs
CHANGED
|
@@ -13676,7 +13676,7 @@ function getVueDevtoolsPath() {
|
|
|
13676
13676
|
const pluginPath = vite.normalizePath(path$3__default.dirname(url.fileURLToPath((typeof document === 'undefined' ? require('u' + 'rl').pathToFileURL(__filename).href : (document.currentScript && document.currentScript.src || new URL('index.cjs', document.baseURI).href)))));
|
|
13677
13677
|
return pluginPath.replace(/\/dist$/, "//src/node");
|
|
13678
13678
|
}
|
|
13679
|
-
function
|
|
13679
|
+
function VitePluginVueDevTools(options = { appendTo: "" }) {
|
|
13680
13680
|
const vueDevtoolsPath = getVueDevtoolsPath();
|
|
13681
13681
|
const inspect = Inspect__default({
|
|
13682
13682
|
silent: true
|
|
@@ -13695,8 +13695,8 @@ function PluginVueDevtools() {
|
|
|
13695
13695
|
getImageMeta,
|
|
13696
13696
|
getTextAssetContent,
|
|
13697
13697
|
getPackages: () => getPackages(config.root),
|
|
13698
|
-
installPackage: (packages,
|
|
13699
|
-
...
|
|
13698
|
+
installPackage: (packages, options2 = {}) => installPackage(packages, {
|
|
13699
|
+
...options2,
|
|
13700
13700
|
cwd: config.root,
|
|
13701
13701
|
callback: (type, data) => {
|
|
13702
13702
|
if (type === "data")
|
|
@@ -13729,7 +13729,18 @@ function PluginVueDevtools() {
|
|
|
13729
13729
|
if (id === "virtual:vue-devtools-options")
|
|
13730
13730
|
return `export default ${JSON.stringify({ base: config.base })}`;
|
|
13731
13731
|
},
|
|
13732
|
+
transform(code, id) {
|
|
13733
|
+
const { appendTo } = options;
|
|
13734
|
+
if (!appendTo)
|
|
13735
|
+
return;
|
|
13736
|
+
const [filename] = id.split("?", 2);
|
|
13737
|
+
if (typeof appendTo === "string" && filename.endsWith(appendTo) || appendTo instanceof RegExp && appendTo.test(filename))
|
|
13738
|
+
return { code: `${code}
|
|
13739
|
+
import 'virtual:vue-devtools-path:app.js'` };
|
|
13740
|
+
},
|
|
13732
13741
|
transformIndexHtml(html) {
|
|
13742
|
+
if (options.appendTo)
|
|
13743
|
+
return;
|
|
13733
13744
|
return {
|
|
13734
13745
|
html,
|
|
13735
13746
|
tags: [
|
|
@@ -13757,4 +13768,4 @@ function PluginVueDevtools() {
|
|
|
13757
13768
|
];
|
|
13758
13769
|
}
|
|
13759
13770
|
|
|
13760
|
-
module.exports =
|
|
13771
|
+
module.exports = VitePluginVueDevTools;
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,14 @@
|
|
|
1
1
|
import { PluginOption } from 'vite';
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
interface VitePluginVueDevToolsOptions {
|
|
4
|
+
/**
|
|
5
|
+
* append an import to the module id ending with `appendTo` instead of adding a script into body
|
|
6
|
+
* useful for projects that do not use html file as an entry
|
|
7
|
+
*
|
|
8
|
+
* WARNING: only set this if you know exactly what it does.
|
|
9
|
+
*/
|
|
10
|
+
appendTo?: string | RegExp;
|
|
11
|
+
}
|
|
12
|
+
declare function VitePluginVueDevTools(options?: VitePluginVueDevToolsOptions): PluginOption;
|
|
4
13
|
|
|
5
|
-
export {
|
|
14
|
+
export { VitePluginVueDevToolsOptions, VitePluginVueDevTools as default };
|
package/dist/index.mjs
CHANGED
|
@@ -13650,7 +13650,7 @@ function getVueDevtoolsPath() {
|
|
|
13650
13650
|
const pluginPath = normalizePath(path$3$1.dirname(fileURLToPath(import.meta.url)));
|
|
13651
13651
|
return pluginPath.replace(/\/dist$/, "//src/node");
|
|
13652
13652
|
}
|
|
13653
|
-
function
|
|
13653
|
+
function VitePluginVueDevTools(options = { appendTo: "" }) {
|
|
13654
13654
|
const vueDevtoolsPath = getVueDevtoolsPath();
|
|
13655
13655
|
const inspect = Inspect({
|
|
13656
13656
|
silent: true
|
|
@@ -13669,8 +13669,8 @@ function PluginVueDevtools() {
|
|
|
13669
13669
|
getImageMeta,
|
|
13670
13670
|
getTextAssetContent,
|
|
13671
13671
|
getPackages: () => getPackages(config.root),
|
|
13672
|
-
installPackage: (packages,
|
|
13673
|
-
...
|
|
13672
|
+
installPackage: (packages, options2 = {}) => installPackage(packages, {
|
|
13673
|
+
...options2,
|
|
13674
13674
|
cwd: config.root,
|
|
13675
13675
|
callback: (type, data) => {
|
|
13676
13676
|
if (type === "data")
|
|
@@ -13703,7 +13703,18 @@ function PluginVueDevtools() {
|
|
|
13703
13703
|
if (id === "virtual:vue-devtools-options")
|
|
13704
13704
|
return `export default ${JSON.stringify({ base: config.base })}`;
|
|
13705
13705
|
},
|
|
13706
|
+
transform(code, id) {
|
|
13707
|
+
const { appendTo } = options;
|
|
13708
|
+
if (!appendTo)
|
|
13709
|
+
return;
|
|
13710
|
+
const [filename] = id.split("?", 2);
|
|
13711
|
+
if (typeof appendTo === "string" && filename.endsWith(appendTo) || appendTo instanceof RegExp && appendTo.test(filename))
|
|
13712
|
+
return { code: `${code}
|
|
13713
|
+
import 'virtual:vue-devtools-path:app.js'` };
|
|
13714
|
+
},
|
|
13706
13715
|
transformIndexHtml(html) {
|
|
13716
|
+
if (options.appendTo)
|
|
13717
|
+
return;
|
|
13707
13718
|
return {
|
|
13708
13719
|
html,
|
|
13709
13720
|
tags: [
|
|
@@ -13731,4 +13742,4 @@ function PluginVueDevtools() {
|
|
|
13731
13742
|
];
|
|
13732
13743
|
}
|
|
13733
13744
|
|
|
13734
|
-
export {
|
|
13745
|
+
export { VitePluginVueDevTools as default };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "vite-plugin-vue-devtools",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.1.1",
|
|
4
4
|
"packageManager": "pnpm@8.4.0",
|
|
5
5
|
"description": "A vite plugin for Vue Devtools",
|
|
6
6
|
"author": "webfansplz",
|
|
@@ -56,31 +56,31 @@
|
|
|
56
56
|
},
|
|
57
57
|
"dependencies": {
|
|
58
58
|
"@vueuse/core": "^10.1.2",
|
|
59
|
-
"algoliasearch": "^4.17.
|
|
60
|
-
"birpc": "^0.2.
|
|
59
|
+
"algoliasearch": "^4.17.1",
|
|
60
|
+
"birpc": "^0.2.12",
|
|
61
61
|
"execa": "^7.1.1",
|
|
62
62
|
"nanoid": "^4.0.2",
|
|
63
63
|
"sirv": "^2.0.3",
|
|
64
64
|
"splitpanes": "^3.1.5",
|
|
65
65
|
"vite-hot-client": "^0.2.1",
|
|
66
|
-
"vite-plugin-inspect": "^0.7.
|
|
67
|
-
"vite-plugin-vue-inspector": "^3.4.
|
|
68
|
-
"vue-router": "^4.
|
|
66
|
+
"vite-plugin-inspect": "^0.7.28",
|
|
67
|
+
"vite-plugin-vue-inspector": "^3.4.2",
|
|
68
|
+
"vue-router": "^4.2.2",
|
|
69
69
|
"xterm": "^5.1.0",
|
|
70
70
|
"xterm-addon-fit": "^0.7.0"
|
|
71
71
|
},
|
|
72
72
|
"devDependencies": {
|
|
73
|
-
"@algolia/client-search": "^4.17.
|
|
73
|
+
"@algolia/client-search": "^4.17.1",
|
|
74
74
|
"@antfu/eslint-config": "^0.38.5",
|
|
75
75
|
"@antfu/ni": "^0.21.3",
|
|
76
|
-
"@iconify/json": "^2.2.
|
|
77
|
-
"@nuxt/devtools-ui-kit": "^0.
|
|
76
|
+
"@iconify/json": "^2.2.71",
|
|
77
|
+
"@nuxt/devtools-ui-kit": "^0.5.5",
|
|
78
78
|
"@types/codemirror": "^5.60.7",
|
|
79
|
-
"@types/node": "^20.
|
|
79
|
+
"@types/node": "^20.2.5",
|
|
80
80
|
"@types/splitpanes": "^2.2.1",
|
|
81
|
-
"@unocss/eslint-config": "^0.
|
|
82
|
-
"@unocss/reset": "^0.
|
|
83
|
-
"@vitejs/plugin-vue": "^4.2.
|
|
81
|
+
"@unocss/eslint-config": "^0.52.5",
|
|
82
|
+
"@unocss/reset": "^0.52.5",
|
|
83
|
+
"@vitejs/plugin-vue": "^4.2.3",
|
|
84
84
|
"bumpp": "^9.1.0",
|
|
85
85
|
"codemirror": "^6.0.1",
|
|
86
86
|
"codemirror-theme-vars": "^0.1.2",
|
|
@@ -94,21 +94,21 @@
|
|
|
94
94
|
"npm-run-all": "^4.1.5",
|
|
95
95
|
"ohash": "^1.1.2",
|
|
96
96
|
"pathe": "^1.1.0",
|
|
97
|
-
"pinia": "^2.
|
|
98
|
-
"pnpm": "^8.
|
|
99
|
-
"rimraf": "^5.0.
|
|
97
|
+
"pinia": "^2.1.3",
|
|
98
|
+
"pnpm": "^8.6.0",
|
|
99
|
+
"rimraf": "^5.0.1",
|
|
100
100
|
"simple-git-hooks": "^2.8.1",
|
|
101
101
|
"typescript": "^5.0.4",
|
|
102
102
|
"unbuild": "^1.2.1",
|
|
103
|
-
"unocss": "^0.
|
|
104
|
-
"unplugin-auto-import": "^0.
|
|
105
|
-
"unplugin-vue-components": "^0.
|
|
103
|
+
"unocss": "^0.52.5",
|
|
104
|
+
"unplugin-auto-import": "^0.16.4",
|
|
105
|
+
"unplugin-vue-components": "^0.25.0",
|
|
106
106
|
"vis-data": "^7.1.6",
|
|
107
107
|
"vis-network": "^9.1.6",
|
|
108
|
-
"vite": "^4.3.
|
|
108
|
+
"vite": "^4.3.9",
|
|
109
109
|
"vite-dev-rpc": "^0.1.2",
|
|
110
|
-
"vite-plugin-pages": "^0.
|
|
111
|
-
"vue": "^3.
|
|
110
|
+
"vite-plugin-pages": "^0.30.1",
|
|
111
|
+
"vue": "^3.3.4",
|
|
112
112
|
"vue-virtual-scroller": "2.0.0-beta.8"
|
|
113
113
|
},
|
|
114
114
|
"simple-git-hooks": {
|
package/src/node/Container.vue
CHANGED
|
@@ -378,42 +378,76 @@ onMounted(() => {
|
|
|
378
378
|
togglePanel()
|
|
379
379
|
})
|
|
380
380
|
})
|
|
381
|
+
|
|
382
|
+
const toggleButtonRef = ref(null)
|
|
383
|
+
const modalRef = ref(null)
|
|
384
|
+
|
|
385
|
+
window.addEventListener('click', (event) => {
|
|
386
|
+
const modalEl = modalRef.value
|
|
387
|
+
const toggleButtonEl = toggleButtonRef.value
|
|
388
|
+
if (!modalEl || !toggleButtonEl || event.composedPath().includes(modalEl) || event.composedPath().includes(toggleButtonEl))
|
|
389
|
+
return
|
|
390
|
+
const frameState = localStorage.getItem('__vue-devtools-frame-state__')
|
|
391
|
+
if (frameState) {
|
|
392
|
+
const parsedFrameState = JSON.parse(frameState)
|
|
393
|
+
if (parsedFrameState.closeOnOutsideClick)
|
|
394
|
+
panelVisible.value = false
|
|
395
|
+
}
|
|
396
|
+
})
|
|
381
397
|
</script>
|
|
382
398
|
|
|
383
399
|
<template>
|
|
384
|
-
<div class="vue-devtools-panel" :style="panelPosition">
|
|
400
|
+
<div ref="modalRef" class="vue-devtools-panel" :style="panelPosition">
|
|
385
401
|
<!-- client -->
|
|
386
|
-
<iframe
|
|
387
|
-
|
|
388
|
-
|
|
402
|
+
<iframe
|
|
403
|
+
ref="iframe" :src="clientUrl" :style="{
|
|
404
|
+
'pointer-events': isDragging ? 'none' : 'auto',
|
|
405
|
+
}" @load="onLoad"
|
|
406
|
+
/>
|
|
389
407
|
<!-- resize -->
|
|
390
408
|
<template v-if="panelState.viewMode === 'default'">
|
|
391
409
|
<template v-if="panelState.position !== 'top'">
|
|
392
410
|
<div :class="resizeHorizontalClassName" :style="{ top: 0 }" @mousedown.prevent="toggleDragging('horizontal')" />
|
|
393
|
-
<div
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
411
|
+
<div
|
|
412
|
+
v-if="panelState.position !== 'left'" :class="resizeCornerClassName"
|
|
413
|
+
:style="{ top: 0, left: 0, cursor: 'nwse-resize' }" @mousedown.prevent="toggleDragging('both')"
|
|
414
|
+
/>
|
|
415
|
+
<div
|
|
416
|
+
v-if="panelState.position !== 'right'" :class="resizeCornerClassName"
|
|
417
|
+
:style="{ top: 0, right: 0, cursor: 'nesw-resize' }" @mousedown.prevent="toggleDragging('both')"
|
|
418
|
+
/>
|
|
397
419
|
</template>
|
|
398
420
|
|
|
399
421
|
<template v-if="panelState.position !== 'bottom'">
|
|
400
|
-
<div
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
<div
|
|
405
|
-
|
|
422
|
+
<div
|
|
423
|
+
:class="resizeHorizontalClassName" :style="{ bottom: 0 }"
|
|
424
|
+
@mousedown.prevent="toggleDragging('horizontal')"
|
|
425
|
+
/>
|
|
426
|
+
<div
|
|
427
|
+
v-if="panelState.position !== 'right'" :class="resizeCornerClassName"
|
|
428
|
+
:style="{ bottom: 0, right: 0, cursor: 'nwse-resize' }" @mousedown.prevent="toggleDragging('both')"
|
|
429
|
+
/>
|
|
430
|
+
<div
|
|
431
|
+
v-if="panelState.position !== 'left'" :class="resizeCornerClassName"
|
|
432
|
+
:style="{ bottom: 0, left: 0, cursor: 'nesw-resize' }" @mousedown.prevent="toggleDragging('both')"
|
|
433
|
+
/>
|
|
406
434
|
</template>
|
|
407
435
|
|
|
408
|
-
<div
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
436
|
+
<div
|
|
437
|
+
v-if="panelState.position !== 'left'" :class="resizeVerticalClassName" :style="{ left: 0 }"
|
|
438
|
+
@mousedown.prevent="toggleDragging('vertical')"
|
|
439
|
+
/>
|
|
440
|
+
<div
|
|
441
|
+
v-if="panelState.position !== 'right'" :class="resizeVerticalClassName" :style="{ right: 0 }"
|
|
442
|
+
@mousedown.prevent="toggleDragging('vertical')"
|
|
443
|
+
/>
|
|
412
444
|
</template>
|
|
413
445
|
</div>
|
|
414
446
|
<!-- toggle button -->
|
|
415
|
-
<button
|
|
416
|
-
|
|
447
|
+
<button
|
|
448
|
+
ref="toggleButtonRef" class="vue-devtools-toggle" aria-label="Toggle devtools panel" :style="toggleButtonPosition"
|
|
449
|
+
@click.prevent="togglePanel"
|
|
450
|
+
>
|
|
417
451
|
<svg viewBox="0 0 256 198" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
418
452
|
<path fill="#41B883" d="M204.8 0H256L128 220.8L0 0h97.92L128 51.2L157.44 0h47.36Z" />
|
|
419
453
|
<path fill="#41B883" d="m0 0l128 220.8L256 0h-51.2L128 132.48L50.56 0H0Z" />
|