@nuxt/devtools 4.0.0-alpha.10 → 4.0.0-alpha.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/README.md +2 -0
- package/dist/chunks/analyze-build.mjs +5 -6
- package/dist/chunks/code-server.mjs +1 -2
- package/dist/chunks/data-inspector.mjs +82 -0
- package/dist/chunks/module-main.mjs +34 -104
- package/dist/chunks/vite-inspect.mjs +5 -6
- package/dist/client/200.html +1 -1
- package/dist/client/404.html +1 -1
- package/dist/client/_nuxt/__blank-ki8oaugs.js +1 -0
- package/dist/client/_nuxt/analyze-build-ie32uchi.js +1 -0
- package/dist/client/_nuxt/assets-jyg0eofj.js +6 -0
- package/dist/client/_nuxt/{auth-required-panel-mm5lidl3.js → auth-required-panel-hlhmg87z.js} +1 -1
- package/dist/client/_nuxt/builds/latest.json +1 -1
- package/dist/client/_nuxt/builds/meta/1183fbc7-b7db-4404-9ee4-7571849e8ffe.json +1 -0
- package/dist/client/_nuxt/cj10ghel.js +2 -0
- package/dist/client/_nuxt/{client-botfq0nw.js → client-iet3i2jx.js} +1 -1
- package/dist/client/_nuxt/code-diff-nh9ucmoa.js +8 -0
- package/dist/client/_nuxt/code-snippets-jzjkfinz.js +1 -0
- package/dist/client/_nuxt/{components-k5rsm3c3.js → components-oyl85tqv.js} +1 -1
- package/dist/client/_nuxt/{composable-item-o8crh7o9.js → composable-item-flzw59ca.js} +1 -1
- package/dist/client/_nuxt/composables-li5sexni.js +1 -0
- package/dist/client/_nuxt/{custom-_name_-j6w4b10b.js → custom-_name_-kwr7j680.js} +1 -1
- package/dist/client/_nuxt/{data-schema-button-j2dsypzz.js → data-schema-button-nmq5no1t.js} +1 -1
- package/dist/client/_nuxt/{data-schema-drawer-9s1351p5.js → data-schema-drawer-bvbzeooy.js} +1 -1
- package/dist/client/_nuxt/{debug-muupfuzb.js → debug-ouzogne6.js} +1 -1
- package/dist/client/_nuxt/{default-k6jiq1wt.js → default-m4s11ttb.js} +1 -1
- package/dist/client/_nuxt/dialog-i2683h8g.js +1 -0
- package/dist/client/_nuxt/dist-gklva25a.js +1 -0
- package/dist/client/_nuxt/{duration-display-kup58tqe.js → duration-display-fjuy04uz.js} +1 -1
- package/dist/client/_nuxt/{editor-bzxz1rcq.js → editor-cv8lunmj.js} +1 -1
- package/dist/client/_nuxt/{error-404-25vom0cq.js → error-404-dxv9ojo4.js} +1 -1
- package/dist/client/_nuxt/error-404.css-kdbb3rb9.css +1 -0
- package/dist/client/_nuxt/{error-500-htafeoa3.js → error-500-modjju3x.js} +1 -1
- package/dist/client/_nuxt/error-500.css-hwq7jdp9.css +1 -0
- package/dist/client/_nuxt/{error-lj28vdr1.js → error-k3ha3twu.js} +1 -1
- package/dist/client/_nuxt/{filepath-item-jdy5gc4m.js → filepath-item-m6tglha3.js} +1 -1
- package/dist/client/_nuxt/full-kcw32vsy.js +1 -0
- package/dist/client/_nuxt/fuse-ipb957gg.js +1 -0
- package/dist/client/_nuxt/{help-fab-ll6mbhgs.js → help-fab-sp6luyzp.js} +1 -1
- package/dist/client/_nuxt/{hooks-hgffr865.js → hooks-l1yy9fmc.js} +1 -1
- package/dist/client/_nuxt/{imports-i2fnwttt.js → imports-fm9nem8p.js} +1 -1
- package/dist/client/_nuxt/{launch-page-ksxhzp2z.js → launch-page-g9x94qn0.js} +1 -1
- package/dist/client/_nuxt/modules-ha9lr7ce.js +1 -0
- package/dist/client/_nuxt/nbadge-n73p68uz.js +1 -0
- package/dist/client/_nuxt/{nbutton-mtj8qzr9.js → nbutton-mxt3cxcx.js} +1 -1
- package/dist/client/_nuxt/ncard-kyrmtdmn.js +1 -0
- package/dist/client/_nuxt/{ncheckbox-mksfz5p0.js → ncheckbox-fbnq3guy.js} +1 -1
- package/dist/client/_nuxt/{ncode-block-pfi5niis.js → ncode-block-ltlsxf5u.js} +1 -1
- package/dist/client/_nuxt/ndialog-jnj3j8xn.js +3 -0
- package/dist/client/_nuxt/{ndrawer-h46qfenr.js → ndrawer-ll4inus6.js} +1 -1
- package/dist/client/_nuxt/{ndropdown-ow0z3stn.js → ndropdown-hviylh0n.js} +1 -1
- package/dist/client/_nuxt/nicon-ccnh6x2r.js +4 -0
- package/dist/client/_nuxt/{nicon-title-e2gzkzl3.js → nicon-title-ejbxuupx.js} +1 -1
- package/dist/client/_nuxt/{nlink-j55iyj5x.js → nlink-h3jrz76l.js} +1 -1
- package/dist/client/_nuxt/{nloading-k4sy0f8c.js → nloading-lhpm96ki.js} +1 -1
- package/dist/client/_nuxt/{nmarkdown-mnxob7ua.js → nmarkdown-7qnv8atx.js} +1 -1
- package/dist/client/_nuxt/{nnavbar-dwxbkqvw.js → nnavbar-f1l2np9t.js} +1 -1
- package/dist/client/_nuxt/none-ju85xmqv.js +1 -0
- package/dist/client/_nuxt/npanel-grids-fa3ah9jo.js +1 -0
- package/dist/client/_nuxt/npm-eisv4i48.js +1 -0
- package/dist/client/_nuxt/{nsection-block-cb29dqkc.js → nsection-block-nwojdml4.js} +1 -1
- package/dist/client/_nuxt/{nselect-glgbbae4.js → nselect-mnlj28vi.js} +1 -1
- package/dist/client/_nuxt/{nselect-tabs-jzyd56a1.js → nselect-tabs-i66uosc4.js} +1 -1
- package/dist/client/_nuxt/{nsplit-pane-b5ki4jwa.js → nsplit-pane-lj2kxwh2.js} +1 -1
- package/dist/client/_nuxt/{ntext-input-lzyyx3ym.js → ntext-input-j7ulf0ma.js} +1 -1
- package/dist/client/_nuxt/{ntip-oohvtkqd.js → ntip-mx3dwcmh.js} +1 -1
- package/dist/client/_nuxt/{nuxt-f4tmbbs7.js → nuxt-hj3jyofn.js} +1 -1
- package/dist/client/_nuxt/{nuxt-link-dgri2bli.js → nuxt-link-nsgkom6k.js} +1 -1
- package/dist/client/_nuxt/{nuxt-logo-gzcu6lh0.js → nuxt-logo-dead1uws.js} +1 -1
- package/dist/client/_nuxt/{open-graph-mc8dh9qn.js → open-graph-eytiti5b.js} +1 -1
- package/dist/client/_nuxt/{overview-lpfgamus.js → overview-fygybbrw.js} +1 -1
- package/dist/client/_nuxt/{pages-bv99uu3p.js → pages-fq4mkuci.js} +1 -1
- package/dist/client/_nuxt/{payload-k2hrsm04.js → payload-jw0xxl4z.js} +1 -1
- package/dist/client/_nuxt/{plugins-ljid8ktq.js → plugins-lou32v4a.js} +1 -1
- package/dist/client/_nuxt/ready-ikhds7hc.js +2 -0
- package/dist/client/_nuxt/rolldown-runtime-f96lzs6p.js +1 -0
- package/dist/client/_nuxt/{runtime-configs-lvgzbcdu.js → runtime-configs-e7x3t3tj.js} +1 -1
- package/dist/client/_nuxt/{server-route-inputs-iwv9ewrw.js → server-route-inputs-kt7x1gp6.js} +1 -1
- package/dist/client/_nuxt/server-routes-mr1qgqcl.js +7 -0
- package/dist/client/_nuxt/server-tasks-evcqaabt.js +1 -0
- package/dist/client/_nuxt/{settings-ngc5p8qn.js → settings-ipg67k9i.js} +1 -1
- package/dist/client/_nuxt/{stacktrace-list-chmjyp53.js → stacktrace-list-kruru2d1.js} +1 -1
- package/dist/client/_nuxt/{state-commands-f4h87cfl.js → state-commands-cjvbhmr2.js} +1 -1
- package/dist/client/_nuxt/{state-components-jymg7dj7.js → state-components-dzfpv5gi.js} +1 -1
- package/dist/client/_nuxt/state-editor-eqmkyoyc.js +1 -0
- package/dist/client/_nuxt/{state-modules-bewlxq5o.js → state-modules-xt0ltk0c.js} +1 -1
- package/dist/client/_nuxt/{state-routes-f5cna95h.js → state-routes-g66ss5o7.js} +1 -1
- package/dist/client/_nuxt/state-schema-c04uzwtk.js +1 -0
- package/dist/client/_nuxt/{state-tabs-m7neqayd.js → state-tabs-ntcahhqz.js} +1 -1
- package/dist/client/_nuxt/storage-if9cwvvr.js +1 -0
- package/dist/client/_nuxt/{tab-icon-nktg799o.js → tab-icon-bw4o7q2t.js} +1 -1
- package/dist/client/_nuxt/telemetry-gc8f0sai.js +1 -0
- package/dist/client/_nuxt/{timeline-o9hhhb94.js → timeline-l8l1qdht.js} +1 -1
- package/dist/client/_nuxt/unhead.dnki-vlv7-jmz34zx6.js +1 -0
- package/dist/client/_nuxt/{unocss-runtime-bjggyd5e.js → unocss-runtime-htk43m9c.js} +1 -1
- package/dist/client/_nuxt/utils-c5p5s7ov.js +1 -0
- package/dist/client/_nuxt/vendor/json-editor-vue-h1waqukq.js +3862 -0
- package/dist/client/_nuxt/vendor/{markdown-exit-n4f1gsja.js → markdown-exit-nzr6hp55.js} +6 -6
- package/dist/client/_nuxt/vendor/quicktype-core-lz5bp16m.js +929 -0
- package/dist/client/_nuxt/vendor/shiki-g3svwmfz.js +152 -0
- package/dist/client/_nuxt/vendor/unocss-hvwio62w.js +3 -0
- package/dist/client/_nuxt/vendor/vis-bjkylbfi.js +30 -0
- package/dist/client/_nuxt/{virtual-files-kcs310xn.js → virtual-files-epcme7qw.js} +1 -1
- package/dist/client/index.html +1 -1
- package/dist/module.json +1 -1
- package/dist/module.mjs +1 -1
- package/dist/runtime/plugins/vite-devtools.client.js +5 -1
- package/dist/shared/{devtools.CCWq4fFE.mjs → devtools.BNZC-DT8.mjs} +1 -0
- package/package.json +27 -42
- package/dist/client/_nuxt/__blank-dil3nwfh.js +0 -1
- package/dist/client/_nuxt/analyze-build-2e03hfez.js +0 -1
- package/dist/client/_nuxt/assets-fyld29gf.js +0 -6
- package/dist/client/_nuxt/builds/meta/dbb6f1eb-fdec-4078-b409-19d1ed6035a2.json +0 -1
- package/dist/client/_nuxt/code-diff-oxve94ak.js +0 -8
- package/dist/client/_nuxt/code-snippets-mcrkbsd4.js +0 -1
- package/dist/client/_nuxt/composables-ml69kqh9.js +0 -1
- package/dist/client/_nuxt/dialog-c7wnj3nl.js +0 -1
- package/dist/client/_nuxt/dist-d6zuldkp.js +0 -1
- package/dist/client/_nuxt/error-404.css-mpcol2vk.css +0 -1
- package/dist/client/_nuxt/error-500.css-273x0c3h.css +0 -1
- package/dist/client/_nuxt/full-gpj1mlf5.js +0 -1
- package/dist/client/_nuxt/fuse-blwyun20.js +0 -1
- package/dist/client/_nuxt/modules-dae72omf.js +0 -1
- package/dist/client/_nuxt/nbadge-oyy0wjng.js +0 -1
- package/dist/client/_nuxt/ncard-mtvdl2wf.js +0 -1
- package/dist/client/_nuxt/ndialog-dj1ywkc1.js +0 -3
- package/dist/client/_nuxt/nicon-obdu3k9r.js +0 -3
- package/dist/client/_nuxt/nju74r39.js +0 -2
- package/dist/client/_nuxt/none-md25735q.js +0 -1
- package/dist/client/_nuxt/npanel-grids-ga8arlvs.js +0 -1
- package/dist/client/_nuxt/npm-febdntx4.js +0 -1
- package/dist/client/_nuxt/ready-h6bi8le4.js +0 -1
- package/dist/client/_nuxt/rolldown-runtime-ln9q81id.js +0 -1
- package/dist/client/_nuxt/server-routes-mkqbltfh.js +0 -7
- package/dist/client/_nuxt/server-tasks-kbf4txeq.js +0 -1
- package/dist/client/_nuxt/state-editor-bg13n53w.js +0 -1
- package/dist/client/_nuxt/state-schema-espdew31.js +0 -1
- package/dist/client/_nuxt/storage-cep8dxy9.js +0 -1
- package/dist/client/_nuxt/telemetry-9f19c0i9.js +0 -1
- package/dist/client/_nuxt/unhead.dgx-hwv-uc-gaht5h60.js +0 -1
- package/dist/client/_nuxt/utils-bisj7255.js +0 -1
- package/dist/client/_nuxt/vendor/json-editor-vue-lmhxk84q.js +0 -3862
- package/dist/client/_nuxt/vendor/quicktype-core-b6sxxdgw.js +0 -929
- package/dist/client/_nuxt/vendor/shiki-abzmnals.js +0 -152
- package/dist/client/_nuxt/vendor/unocss-hqrnsbiy.js +0 -3
- package/dist/client/_nuxt/vendor/vis-i54ppuvk.js +0 -26
- package/types.d.ts +0 -1
package/README.md
CHANGED
|
@@ -177,6 +177,8 @@ Nuxt DevTools collects anonymous telemetry data about general usage. This helps
|
|
|
177
177
|
|
|
178
178
|
Nuxt DevTools' telemetry data is piped through [Nuxt Telemetry](https://github.com/nuxt/telemetry), meaning that Nuxt DevTools will respect your local and global Nuxt Telemetry settings. You can also opt-out Nuxt DevTools' telemetry in the Nuxt DevTools settings.
|
|
179
179
|
|
|
180
|
+
Nuxt DevTools also respects the [`DO_NOT_TRACK`](https://donottrack.sh/) environment variable convention — set `DO_NOT_TRACK=1` in your environment to disable Nuxt DevTools telemetry regardless of any other setting.
|
|
181
|
+
|
|
180
182
|
The data we collect is completely anonymous, not traceable to the source (using hash+seed), and only meaningful in aggregate form. No data we collect is personally identifiable or trackable.
|
|
181
183
|
|
|
182
184
|
### Events
|
|
@@ -9,26 +9,25 @@ import './module-main.mjs';
|
|
|
9
9
|
import 'node:fs';
|
|
10
10
|
import 'node:os';
|
|
11
11
|
import 'consola/utils';
|
|
12
|
-
import '
|
|
12
|
+
import 'devframe/utils/serve-static';
|
|
13
13
|
import 'vite';
|
|
14
|
-
import '../shared/devtools.
|
|
14
|
+
import '../shared/devtools.BNZC-DT8.mjs';
|
|
15
15
|
import '../dirs.mjs';
|
|
16
16
|
import 'node:path';
|
|
17
17
|
import 'node:url';
|
|
18
|
-
import '
|
|
19
|
-
import '
|
|
18
|
+
import 'node:child_process';
|
|
19
|
+
import 'node:util';
|
|
20
20
|
import 'tinyglobby';
|
|
21
21
|
import 'image-meta';
|
|
22
22
|
import 'perfect-debounce';
|
|
23
23
|
import 'destr';
|
|
24
24
|
import '../../dist/runtime/shared/hooks.js';
|
|
25
|
-
import '
|
|
25
|
+
import 'devframe/utils/hash';
|
|
26
26
|
import 'node:process';
|
|
27
27
|
import 'node:module';
|
|
28
28
|
import 'pkg-types';
|
|
29
29
|
import 'node:assert';
|
|
30
30
|
import 'node:v8';
|
|
31
|
-
import 'node:util';
|
|
32
31
|
import 'magicast';
|
|
33
32
|
import 'magicast/helpers';
|
|
34
33
|
import 'verkit';
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { createCodeServerDevframe } from '@devframes/plugin-code-server';
|
|
2
2
|
import { setupCodeServer } from '@devframes/plugin-code-server/node';
|
|
3
3
|
import { deprecate, onDevtoolsReady, NUXT_DEVTOOLS_GROUP_ID } from '@nuxt/devtools-kit';
|
|
4
|
-
import { mountDevframe } from '@vitejs/devtools-kit/node';
|
|
5
4
|
|
|
6
5
|
const RESERVED_ARGS = ["--auth", "--bind-addr", "--cookie-suffix"];
|
|
7
6
|
const RESERVED_ENV = ["PASSWORD", "HASHED_PASSWORD"];
|
|
@@ -63,7 +62,7 @@ function setup(ctx) {
|
|
|
63
62
|
supervisor?.dispose();
|
|
64
63
|
});
|
|
65
64
|
onDevtoolsReady((kit) => {
|
|
66
|
-
return
|
|
65
|
+
return kit.install(mountedDefinition, {
|
|
67
66
|
dock: {
|
|
68
67
|
groupId: NUXT_DEVTOOLS_GROUP_ID,
|
|
69
68
|
category: "modules"
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
import { registerDataSource, createDataInspectorDevframe } from '@devframes/plugin-data-inspector';
|
|
2
|
+
import { onDevtoolsReady, NUXT_DEVTOOLS_GROUP_ID, deprecate } from '@nuxt/devtools-kit';
|
|
3
|
+
|
|
4
|
+
const captured = {};
|
|
5
|
+
function normalizeViteConfig(config) {
|
|
6
|
+
return {
|
|
7
|
+
...config,
|
|
8
|
+
environments: Object.fromEntries(
|
|
9
|
+
Object.entries(config.env ?? {}).map(([key, _]) => {
|
|
10
|
+
return [key, null];
|
|
11
|
+
})
|
|
12
|
+
),
|
|
13
|
+
plugins: (config.plugins ?? []).map((i) => {
|
|
14
|
+
const clone = { ...i };
|
|
15
|
+
delete clone.api;
|
|
16
|
+
return clone;
|
|
17
|
+
}),
|
|
18
|
+
inlineConfig: null
|
|
19
|
+
};
|
|
20
|
+
}
|
|
21
|
+
function setup(ctx) {
|
|
22
|
+
const { nuxt } = ctx;
|
|
23
|
+
nuxt.hook("nitro:build:before", (nitro) => {
|
|
24
|
+
captured.nitro = nitro;
|
|
25
|
+
});
|
|
26
|
+
nuxt.hook("vite:serverCreated", (server) => {
|
|
27
|
+
captured.vite = server;
|
|
28
|
+
});
|
|
29
|
+
const dataSource = registerDataSource({
|
|
30
|
+
id: "nuxt:application",
|
|
31
|
+
title: "Nuxt Application",
|
|
32
|
+
description: "Live Nuxt, Nitro, and Vite configuration",
|
|
33
|
+
icon: "i-ph:database-duotone",
|
|
34
|
+
static: false,
|
|
35
|
+
data: () => ({
|
|
36
|
+
nuxt: nuxt.options,
|
|
37
|
+
nitro: captured.nitro?.options,
|
|
38
|
+
vite: captured.vite
|
|
39
|
+
}),
|
|
40
|
+
queries: [
|
|
41
|
+
{ title: "Overview", query: "", excludeFunctions: true },
|
|
42
|
+
{ title: "Nuxt modules", query: "nuxt.modules", excludeFunctions: true },
|
|
43
|
+
{ title: "Vite plugins", query: "vite.config.plugins", excludeFunctions: true },
|
|
44
|
+
{ title: "Vite config", query: "vite.config", excludeFunctions: true },
|
|
45
|
+
{ title: "Vite environments", query: "vite.environments", excludeFunctions: true },
|
|
46
|
+
{ title: "Nitro routes", query: "nitro.handlers", excludeFunctions: true }
|
|
47
|
+
]
|
|
48
|
+
});
|
|
49
|
+
nuxt.hook("close", () => {
|
|
50
|
+
dataSource.unregister();
|
|
51
|
+
captured.nitro = void 0;
|
|
52
|
+
captured.vite = void 0;
|
|
53
|
+
});
|
|
54
|
+
const definition = createDataInspectorDevframe({ exampleSource: false });
|
|
55
|
+
onDevtoolsReady((kit) => {
|
|
56
|
+
return kit.install(definition, {
|
|
57
|
+
dock: {
|
|
58
|
+
groupId: NUXT_DEVTOOLS_GROUP_ID,
|
|
59
|
+
category: "advanced"
|
|
60
|
+
}
|
|
61
|
+
});
|
|
62
|
+
}, nuxt);
|
|
63
|
+
}
|
|
64
|
+
function getServerData(nuxt) {
|
|
65
|
+
deprecate(nuxt, "NDT_DEP_0009", {
|
|
66
|
+
api: "getServerData()",
|
|
67
|
+
replacement: "the Nuxt Application source in the Data Inspector panel"
|
|
68
|
+
});
|
|
69
|
+
const config = captured.vite?.config;
|
|
70
|
+
return {
|
|
71
|
+
nuxt: nuxt.options,
|
|
72
|
+
nitro: captured.nitro?.options,
|
|
73
|
+
vite: {
|
|
74
|
+
server: config ? normalizeViteConfig(config) : void 0,
|
|
75
|
+
client: config ? normalizeViteConfig(config) : void 0
|
|
76
|
+
}
|
|
77
|
+
// `nuxt.options` is `@nuxt/schema`'s `NuxtOptions` while `NuxtServerData`
|
|
78
|
+
// pins the structurally-identical `nuxt/schema` one; bridge the two.
|
|
79
|
+
};
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
export { getServerData, setup };
|
|
@@ -1,31 +1,29 @@
|
|
|
1
1
|
import fs$1, { promises, statSync, realpathSync, readFileSync, existsSync, accessSync, constants } from 'node:fs';
|
|
2
2
|
import fs from 'node:fs/promises';
|
|
3
3
|
import os, { homedir } from 'node:os';
|
|
4
|
-
import { onDevtoolsReady,
|
|
4
|
+
import { onDevtoolsReady, deprecate, registerHostDiagnostics, NUXT_DEVTOOLS_GROUP_ID } from '@nuxt/devtools-kit';
|
|
5
5
|
import { logger, useNuxt, extendViteConfig, addPlugin, addVitePlugin, addTemplate, addImports } from '@nuxt/kit';
|
|
6
6
|
import { colors } from 'consola/utils';
|
|
7
|
+
import { serveStaticNodeMiddleware } from 'devframe/utils/serve-static';
|
|
7
8
|
import { join, dirname, resolve, isAbsolute } from 'pathe';
|
|
8
|
-
import sirv from 'sirv';
|
|
9
9
|
import { searchForWorkspaceRoot } from 'vite';
|
|
10
|
-
import { d as defaultAllowedExtensions, c as createDefaultTabOptions, s as setServerTasksEnabledByDefault } from '../shared/devtools.
|
|
10
|
+
import { d as defaultAllowedExtensions, c as createDefaultTabOptions, s as setServerTasksEnabledByDefault } from '../shared/devtools.BNZC-DT8.mjs';
|
|
11
11
|
import { runtimeDir, clientDir, packageDir } from '../dirs.mjs';
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import { x } from 'tinyexec';
|
|
12
|
+
import { execFile } from 'node:child_process';
|
|
13
|
+
import { promisify, format, inspect } from 'node:util';
|
|
15
14
|
import { glob } from 'tinyglobby';
|
|
16
15
|
import path, { relative, parse, dirname as dirname$1 } from 'node:path';
|
|
17
16
|
import { imageMeta } from 'image-meta';
|
|
18
17
|
import { debounce } from 'perfect-debounce';
|
|
19
18
|
import destr from 'destr';
|
|
20
19
|
import { setupHooksDebug } from '../../dist/runtime/shared/hooks.js';
|
|
21
|
-
import { hash } from '
|
|
20
|
+
import { hash } from 'devframe/utils/hash';
|
|
22
21
|
import process$1 from 'node:process';
|
|
23
22
|
import { builtinModules, createRequire } from 'node:module';
|
|
24
23
|
import { resolvePackageJSON, readPackageJSON } from 'pkg-types';
|
|
25
24
|
import { fileURLToPath as fileURLToPath$1, pathToFileURL as pathToFileURL$1 } from 'node:url';
|
|
26
25
|
import assert from 'node:assert';
|
|
27
26
|
import v8 from 'node:v8';
|
|
28
|
-
import { format, inspect } from 'node:util';
|
|
29
27
|
import { resolveModule, getPackageInfo } from 'local-pkg';
|
|
30
28
|
import { parseModule } from 'magicast';
|
|
31
29
|
import { getDefaultExportOptions, addNuxtModule } from 'magicast/helpers';
|
|
@@ -33,91 +31,7 @@ import { isLess } from 'verkit';
|
|
|
33
31
|
import { DEVTOOLS_TERMINALS_DOCK_ID } from '@vitejs/devtools-kit/constants';
|
|
34
32
|
import { normalizeBaseKey, normalizeKey, createStorage, builtinDrivers } from 'unstorage';
|
|
35
33
|
|
|
36
|
-
const version$1 = "4.0.0-alpha.
|
|
37
|
-
|
|
38
|
-
const captured = {};
|
|
39
|
-
function normalizeViteConfig(config) {
|
|
40
|
-
return {
|
|
41
|
-
...config,
|
|
42
|
-
environments: Object.fromEntries(
|
|
43
|
-
Object.entries(config.env ?? {}).map(([key, _]) => {
|
|
44
|
-
return [key, null];
|
|
45
|
-
})
|
|
46
|
-
),
|
|
47
|
-
plugins: (config.plugins ?? []).map((i) => {
|
|
48
|
-
const clone = { ...i };
|
|
49
|
-
delete clone.api;
|
|
50
|
-
return clone;
|
|
51
|
-
}),
|
|
52
|
-
inlineConfig: null
|
|
53
|
-
};
|
|
54
|
-
}
|
|
55
|
-
function setup(ctx) {
|
|
56
|
-
const { nuxt } = ctx;
|
|
57
|
-
nuxt.hook("nitro:build:before", (nitro) => {
|
|
58
|
-
captured.nitro = nitro;
|
|
59
|
-
});
|
|
60
|
-
nuxt.hook("vite:serverCreated", (server) => {
|
|
61
|
-
captured.vite = server;
|
|
62
|
-
});
|
|
63
|
-
const dataSource = registerDataSource({
|
|
64
|
-
id: "nuxt:application",
|
|
65
|
-
title: "Nuxt Application",
|
|
66
|
-
description: "Live Nuxt, Nitro, and Vite configuration",
|
|
67
|
-
icon: "i-ph:database-duotone",
|
|
68
|
-
static: false,
|
|
69
|
-
data: () => ({
|
|
70
|
-
nuxt: nuxt.options,
|
|
71
|
-
nitro: captured.nitro?.options,
|
|
72
|
-
vite: captured.vite
|
|
73
|
-
}),
|
|
74
|
-
queries: [
|
|
75
|
-
{ title: "Overview", query: "", excludeFunctions: true },
|
|
76
|
-
{ title: "Nuxt modules", query: "nuxt.modules", excludeFunctions: true },
|
|
77
|
-
{ title: "Vite plugins", query: "vite.config.plugins", excludeFunctions: true },
|
|
78
|
-
{ title: "Vite config", query: "vite.config", excludeFunctions: true },
|
|
79
|
-
{ title: "Vite environments", query: "vite.environments", excludeFunctions: true },
|
|
80
|
-
{ title: "Nitro routes", query: "nitro.handlers", excludeFunctions: true }
|
|
81
|
-
]
|
|
82
|
-
});
|
|
83
|
-
nuxt.hook("close", () => {
|
|
84
|
-
dataSource.unregister();
|
|
85
|
-
captured.nitro = void 0;
|
|
86
|
-
captured.vite = void 0;
|
|
87
|
-
});
|
|
88
|
-
const definition = createDataInspectorDevframe({ exampleSource: false });
|
|
89
|
-
onDevtoolsReady((kit) => {
|
|
90
|
-
return mountDevframe(kit, definition, {
|
|
91
|
-
dock: {
|
|
92
|
-
groupId: NUXT_DEVTOOLS_GROUP_ID,
|
|
93
|
-
category: "advanced"
|
|
94
|
-
}
|
|
95
|
-
});
|
|
96
|
-
}, nuxt);
|
|
97
|
-
}
|
|
98
|
-
function getServerData(nuxt) {
|
|
99
|
-
deprecate(nuxt, "NDT_DEP_0009", {
|
|
100
|
-
api: "getServerData()",
|
|
101
|
-
replacement: "the Nuxt Application source in the Data Inspector panel"
|
|
102
|
-
});
|
|
103
|
-
const config = captured.vite?.config;
|
|
104
|
-
return {
|
|
105
|
-
nuxt: nuxt.options,
|
|
106
|
-
nitro: captured.nitro?.options,
|
|
107
|
-
vite: {
|
|
108
|
-
server: config ? normalizeViteConfig(config) : void 0,
|
|
109
|
-
client: config ? normalizeViteConfig(config) : void 0
|
|
110
|
-
}
|
|
111
|
-
// `nuxt.options` is `@nuxt/schema`'s `NuxtOptions` while `NuxtServerData`
|
|
112
|
-
// pins the structurally-identical `nuxt/schema` one; bridge the two.
|
|
113
|
-
};
|
|
114
|
-
}
|
|
115
|
-
|
|
116
|
-
const dataInspector = {
|
|
117
|
-
__proto__: null,
|
|
118
|
-
getServerData: getServerData,
|
|
119
|
-
setup: setup
|
|
120
|
-
};
|
|
34
|
+
const version$1 = "4.0.0-alpha.12";
|
|
121
35
|
|
|
122
36
|
const RPC_NAMESPACE = "nuxt:devtools";
|
|
123
37
|
|
|
@@ -127,6 +41,7 @@ function createUniqueSessionId(baseId) {
|
|
|
127
41
|
return `${baseId}#${counter}`;
|
|
128
42
|
}
|
|
129
43
|
|
|
44
|
+
const execFileAsync = promisify(execFile);
|
|
130
45
|
const COLON_RE = /:/g;
|
|
131
46
|
function setupAnalyzeBuildRPC(ctx) {
|
|
132
47
|
const { nuxt, refresh } = ctx;
|
|
@@ -227,8 +142,8 @@ function setupAnalyzeBuildRPC(ctx) {
|
|
|
227
142
|
return builds.sort((a, b) => b.endTime - a.endTime);
|
|
228
143
|
}
|
|
229
144
|
async function git(...args) {
|
|
230
|
-
const
|
|
231
|
-
return
|
|
145
|
+
const { stdout } = await execFileAsync("git", args, { cwd: nuxt.options.rootDir });
|
|
146
|
+
return stdout.trim();
|
|
232
147
|
}
|
|
233
148
|
async function generateAnalyzeBuildName() {
|
|
234
149
|
try {
|
|
@@ -10640,7 +10555,7 @@ function setupGeneralRPC({
|
|
|
10640
10555
|
let editor = getOptions()?.behavior.openInEditor ?? void 0;
|
|
10641
10556
|
if (editor === "auto")
|
|
10642
10557
|
editor = void 0;
|
|
10643
|
-
await import('launch-editor').then((r) =>
|
|
10558
|
+
await import('devframe/utils/launch-editor').then((r) => r.launchEditor(path + suffix, editor));
|
|
10644
10559
|
return true;
|
|
10645
10560
|
} catch (e) {
|
|
10646
10561
|
console.error(e);
|
|
@@ -11855,6 +11770,10 @@ function setupStorageRPC(ctx) {
|
|
|
11855
11770
|
}
|
|
11856
11771
|
|
|
11857
11772
|
const SEND_DELAY = 5e3;
|
|
11773
|
+
function isDoNotTrackEnabled() {
|
|
11774
|
+
const value = process.env.DO_NOT_TRACK;
|
|
11775
|
+
return value === "1" || value?.toLowerCase() === "true";
|
|
11776
|
+
}
|
|
11858
11777
|
function throttle(fn, delay) {
|
|
11859
11778
|
let timer;
|
|
11860
11779
|
return () => {
|
|
@@ -11871,7 +11790,7 @@ const throttledSend = throttle(() => {
|
|
|
11871
11790
|
telemetry?.sendEvents();
|
|
11872
11791
|
}, SEND_DELAY);
|
|
11873
11792
|
function setupTelemetryRPC({ nuxt, options }) {
|
|
11874
|
-
if (options.telemetry !== false) {
|
|
11793
|
+
if (options.telemetry !== false && !isDoNotTrackEnabled()) {
|
|
11875
11794
|
nuxt.hook("telemetry:setup", (t) => {
|
|
11876
11795
|
telemetry = t;
|
|
11877
11796
|
t.eventFactories.devtools = (_, payload) => {
|
|
@@ -11895,6 +11814,8 @@ function telemetryEvent(payload, immediate = false) {
|
|
|
11895
11814
|
return;
|
|
11896
11815
|
if (getOptions()?.behavior.telemetry === false)
|
|
11897
11816
|
return;
|
|
11817
|
+
if (isDoNotTrackEnabled())
|
|
11818
|
+
return;
|
|
11898
11819
|
telemetry.createEvent("devtools", payload);
|
|
11899
11820
|
if (immediate)
|
|
11900
11821
|
telemetry.sendEvents();
|
|
@@ -12037,7 +11958,7 @@ function setupRPC(nuxt, options) {
|
|
|
12037
11958
|
// Deprecated compat shim (NDT_DEP_0009). The capture + live source now live
|
|
12038
11959
|
// in the Data Inspector integration; `getServerConfig` is served by the
|
|
12039
11960
|
// canonical `setupGeneralRPC` above.
|
|
12040
|
-
getServerData: async () => getServerData(nuxt)
|
|
11961
|
+
getServerData: async () => import('./data-inspector.mjs').then(({ getServerData }) => getServerData(nuxt))
|
|
12041
11962
|
});
|
|
12042
11963
|
async function connectDevToolsKit(kitCtx) {
|
|
12043
11964
|
if (devtoolsKitCtx || skipInSSR(kitCtx))
|
|
@@ -12118,7 +12039,10 @@ async function enableModule(options, nuxt) {
|
|
|
12118
12039
|
nuxt.options.vite.optimizeDeps ||= {};
|
|
12119
12040
|
nuxt.options.vite.optimizeDeps.include ||= [];
|
|
12120
12041
|
nuxt.options.vite.optimizeDeps.include.push(
|
|
12121
|
-
|
|
12042
|
+
// Vite DevTools 0.5's embedded client is served by the hub as an external
|
|
12043
|
+
// `embedded.js` script (see `runtime/plugins/vite-devtools.client`), so it
|
|
12044
|
+
// is no longer a bundler-resolved `@vitejs/devtools/client/inject` import to
|
|
12045
|
+
// pre-bundle here.
|
|
12122
12046
|
"nuxt > @nuxt/devtools > @vitejs/devtools-kit/client",
|
|
12123
12047
|
"nuxt > @nuxt/devtools > error-stack-parser-es",
|
|
12124
12048
|
"nuxt > @nuxt/devtools > vite-plugin-vue-tracer/client/overlay"
|
|
@@ -12240,12 +12164,11 @@ window.__NUXT_DEVTOOLS_TIME_METRIC__.appInit = Date.now()
|
|
|
12240
12164
|
const ROUTE_ANALYZE = `${ROUTE_PATH}/analyze`;
|
|
12241
12165
|
nuxt.hook("vite:serverCreated", (server) => {
|
|
12242
12166
|
const devtoolsAnalyzeDir = join(nuxt.options.rootDir, "node_modules/.cache/nuxt-devtools/analyze");
|
|
12243
|
-
server.middlewares.use(ROUTE_ANALYZE,
|
|
12167
|
+
server.middlewares.use(ROUTE_ANALYZE, serveStaticNodeMiddleware(devtoolsAnalyzeDir, { single: false }));
|
|
12244
12168
|
if (clientDirExists) {
|
|
12245
12169
|
const indexHtmlPath = join(clientDir, "index.html");
|
|
12246
12170
|
const indexContent = fs.readFile(indexHtmlPath, "utf-8");
|
|
12247
|
-
const handleStatic =
|
|
12248
|
-
dev: true,
|
|
12171
|
+
const handleStatic = serveStaticNodeMiddleware(clientDir, {
|
|
12249
12172
|
single: false
|
|
12250
12173
|
});
|
|
12251
12174
|
const handleIndex = async (res) => {
|
|
@@ -12263,13 +12186,20 @@ window.__NUXT_DEVTOOLS_TIME_METRIC__.appInit = Date.now()
|
|
|
12263
12186
|
}
|
|
12264
12187
|
});
|
|
12265
12188
|
await import('./plugin-metrics.mjs').then(({ setup }) => setup(ctx));
|
|
12266
|
-
|
|
12189
|
+
if (options.dataInspector !== false)
|
|
12190
|
+
await import('./data-inspector.mjs').then(({ setup }) => setup(ctx));
|
|
12267
12191
|
if (options.viteInspect !== false)
|
|
12268
12192
|
await import('./vite-inspect.mjs').then(({ setup }) => setup(ctx));
|
|
12269
12193
|
if (options.componentInspector !== false)
|
|
12270
12194
|
await import('./vue-tracer.mjs').then(({ setup }) => setup(ctx));
|
|
12195
|
+
if (options.codeServer?.enabled === false && options.vscode !== void 0) {
|
|
12196
|
+
deprecate(nuxt, "NDT_DEP_0008", {
|
|
12197
|
+
api: "devtools.vscode",
|
|
12198
|
+
replacement: "devtools.codeServer"
|
|
12199
|
+
});
|
|
12200
|
+
}
|
|
12271
12201
|
const integrations = [
|
|
12272
|
-
import('./code-server.mjs').then(({ setup }) => setup(ctx)),
|
|
12202
|
+
options.codeServer?.enabled !== false ? import('./code-server.mjs').then(({ setup }) => setup(ctx)) : null,
|
|
12273
12203
|
options.experimental?.timeline || options.timeline?.enabled ? import('./timeline.mjs').then(({ setup }) => setup(ctx)) : null
|
|
12274
12204
|
];
|
|
12275
12205
|
await Promise.all(integrations);
|
|
@@ -7,27 +7,26 @@ import 'node:fs';
|
|
|
7
7
|
import 'node:fs/promises';
|
|
8
8
|
import 'node:os';
|
|
9
9
|
import 'consola/utils';
|
|
10
|
+
import 'devframe/utils/serve-static';
|
|
10
11
|
import 'pathe';
|
|
11
|
-
import 'sirv';
|
|
12
12
|
import 'vite';
|
|
13
|
-
import '../shared/devtools.
|
|
13
|
+
import '../shared/devtools.BNZC-DT8.mjs';
|
|
14
14
|
import '../dirs.mjs';
|
|
15
15
|
import 'node:path';
|
|
16
16
|
import 'node:url';
|
|
17
|
-
import '
|
|
18
|
-
import '
|
|
17
|
+
import 'node:child_process';
|
|
18
|
+
import 'node:util';
|
|
19
19
|
import 'tinyglobby';
|
|
20
20
|
import 'image-meta';
|
|
21
21
|
import 'perfect-debounce';
|
|
22
22
|
import 'destr';
|
|
23
23
|
import '../../dist/runtime/shared/hooks.js';
|
|
24
|
-
import '
|
|
24
|
+
import 'devframe/utils/hash';
|
|
25
25
|
import 'node:process';
|
|
26
26
|
import 'node:module';
|
|
27
27
|
import 'pkg-types';
|
|
28
28
|
import 'node:assert';
|
|
29
29
|
import 'node:v8';
|
|
30
|
-
import 'node:util';
|
|
31
30
|
import 'magicast';
|
|
32
31
|
import 'magicast/helpers';
|
|
33
32
|
import 'verkit';
|
package/dist/client/200.html
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
<!DOCTYPE html><html><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1"><script type="importmap">{"imports":{"#entry":"/__NUXT_DEVTOOLS_BASE__/_nuxt/
|
|
1
|
+
<!DOCTYPE html><html><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1"><script type="importmap">{"imports":{"#entry":"/__NUXT_DEVTOOLS_BASE__/_nuxt/cj10ghel.js"}}</script><link rel="stylesheet" href="/__NUXT_DEVTOOLS_BASE__/_nuxt/entry.css-meav5jmw.css" crossorigin><link rel="stylesheet" href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/json-editor-vue.css-lb1ewor6.css" crossorigin><link rel="stylesheet" href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/unocss.css-bhad58wt.css" crossorigin><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/cj10ghel.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nuxt-hj3jyofn.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/json-editor-vue-h1waqukq.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/rolldown-runtime-f96lzs6p.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nicon-ccnh6x2r.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ready-ikhds7hc.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/dist-2c3gpsw0.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/shiki-g3svwmfz.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/unhead.dnki-vlv7-jmz34zx6.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/composables-li5sexni.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nuxt-link-nsgkom6k.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/utils-c5p5s7ov.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/dist-gklva25a.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/npm-eisv4i48.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/unocss-hvwio62w.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/editor-cv8lunmj.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/state-routes-g66ss5o7.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/telemetry-gc8f0sai.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nloading-lhpm96ki.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/_plugin-vue_export-helper-d9irwgla.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ntext-input-j7ulf0ma.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/tab-icon-bw4o7q2t.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nbutton-mxt3cxcx.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ndialog-jnj3j8xn.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ncard-kyrmtdmn.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/fuse-ipb957gg.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/state-tabs-ntcahhqz.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/state-commands-cjvbhmr2.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nuxt-logo-dead1uws.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/dialog-i2683h8g.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/state-schema-c04uzwtk.js"><script type="module" src="/__NUXT_DEVTOOLS_BASE__/_nuxt/cj10ghel.js" crossorigin></script><link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/default-m4s11ttb.js"><link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/full-kcw32vsy.js"><link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/none-ju85xmqv.js"><link rel="prefetch" as="style" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ncode-block.css-ivoxtfjk.css"><link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/data-schema-drawer-bvbzeooy.js"><link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nselect-mnlj28vi.js"><link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ndropdown-hviylh0n.js"><link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ncode-block-ltlsxf5u.js"><link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/client-iet3i2jx.js"><link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ndrawer-ll4inus6.js"><link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/quicktype-core-lz5bp16m.js"><link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/unocss-runtime-htk43m9c.js"><link rel="prefetch" as="style" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/error-404.css-kdbb3rb9.css"><link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/error-404-dxv9ojo4.js"><link rel="prefetch" as="style" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/error-500.css-hwq7jdp9.css"><link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/error-500-modjju3x.js"></head><body><div id="__nuxt"></div><div id="teleports"></div><script>window.__NUXT__={};window.__NUXT__.config={public:{},app:{baseURL:"/__NUXT_DEVTOOLS_BASE__/",buildId:"1183fbc7-b7db-4404-9ee4-7571849e8ffe",buildAssetsDir:"/_nuxt/",cdnURL:""}}</script><script type="application/json" data-nuxt-data="nuxt-app" data-ssr="false" id="__NUXT_DATA__">[{"prerenderedAt":1,"serverRendered":2},1787201069258,false]</script></body></html>
|
package/dist/client/404.html
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
<!DOCTYPE html><html><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1"><script type="importmap">{"imports":{"#entry":"/__NUXT_DEVTOOLS_BASE__/_nuxt/
|
|
1
|
+
<!DOCTYPE html><html><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1"><script type="importmap">{"imports":{"#entry":"/__NUXT_DEVTOOLS_BASE__/_nuxt/cj10ghel.js"}}</script><link rel="stylesheet" href="/__NUXT_DEVTOOLS_BASE__/_nuxt/entry.css-meav5jmw.css" crossorigin><link rel="stylesheet" href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/json-editor-vue.css-lb1ewor6.css" crossorigin><link rel="stylesheet" href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/unocss.css-bhad58wt.css" crossorigin><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/cj10ghel.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nuxt-hj3jyofn.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/json-editor-vue-h1waqukq.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/rolldown-runtime-f96lzs6p.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nicon-ccnh6x2r.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ready-ikhds7hc.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/dist-2c3gpsw0.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/shiki-g3svwmfz.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/unhead.dnki-vlv7-jmz34zx6.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/composables-li5sexni.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nuxt-link-nsgkom6k.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/utils-c5p5s7ov.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/dist-gklva25a.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/npm-eisv4i48.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/unocss-hvwio62w.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/editor-cv8lunmj.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/state-routes-g66ss5o7.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/telemetry-gc8f0sai.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nloading-lhpm96ki.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/_plugin-vue_export-helper-d9irwgla.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ntext-input-j7ulf0ma.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/tab-icon-bw4o7q2t.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nbutton-mxt3cxcx.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ndialog-jnj3j8xn.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ncard-kyrmtdmn.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/fuse-ipb957gg.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/state-tabs-ntcahhqz.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/state-commands-cjvbhmr2.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nuxt-logo-dead1uws.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/dialog-i2683h8g.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/state-schema-c04uzwtk.js"><script type="module" src="/__NUXT_DEVTOOLS_BASE__/_nuxt/cj10ghel.js" crossorigin></script><link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/default-m4s11ttb.js"><link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/full-kcw32vsy.js"><link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/none-ju85xmqv.js"><link rel="prefetch" as="style" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ncode-block.css-ivoxtfjk.css"><link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/data-schema-drawer-bvbzeooy.js"><link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nselect-mnlj28vi.js"><link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ndropdown-hviylh0n.js"><link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ncode-block-ltlsxf5u.js"><link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/client-iet3i2jx.js"><link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ndrawer-ll4inus6.js"><link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/quicktype-core-lz5bp16m.js"><link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/unocss-runtime-htk43m9c.js"><link rel="prefetch" as="style" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/error-404.css-kdbb3rb9.css"><link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/error-404-dxv9ojo4.js"><link rel="prefetch" as="style" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/error-500.css-hwq7jdp9.css"><link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/error-500-modjju3x.js"></head><body><div id="__nuxt"></div><div id="teleports"></div><script>window.__NUXT__={};window.__NUXT__.config={public:{},app:{baseURL:"/__NUXT_DEVTOOLS_BASE__/",buildId:"1183fbc7-b7db-4404-9ee4-7571849e8ffe",buildAssetsDir:"/_nuxt/",cdnURL:""}}</script><script type="application/json" data-nuxt-data="nuxt-app" data-ssr="false" id="__NUXT_DATA__">[{"prerenderedAt":1,"serverRendered":2},1787201069273,false]</script></body></html>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{C as e,H as t,h as n}from"./vendor/json-editor-vue-h1waqukq.js";import{t as r}from"./composables-ioamscf4.js";var i={"h-screen":``,"w-screen":``,"bg-black":``},a=e({__name:`__blank`,setup(e){return r({layout:`none`}),(e,r)=>(t(),n(`div`,i))}});export{a as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as e}from"./nuxt-hj3jyofn.js";import{C as t,S as n,h as r}from"./nicon-ccnh6x2r.js";import{C as i,H as a,Qt as o,Yt as s,a as c,b as l,bt as u,ct as d,d as f,f as p,h as m,kt as h,lt as g,m as _,p as v,q as y,x as b}from"./vendor/json-editor-vue-h1waqukq.js";import{xt as x}from"./ready-ikhds7hc.js";import{_ as S,g as C}from"./utils-c5p5s7ov.js";import{t as w}from"./npm-eisv4i48.js";import{t as T}from"./_plugin-vue_export-helper-d9irwgla.js";import{t as E}from"./ntext-input-j7ulf0ma.js";import{t as D}from"./nbutton-mxt3cxcx.js";import{t as O}from"./ndialog-jnj3j8xn.js";import{t as k}from"./state-commands-cjvbhmr2.js";import{t as A}from"./telemetry-gc8f0sai.js";import{t as j}from"./ncode-block-ltlsxf5u.js";import{t as M}from"./composables-ioamscf4.js";import{t as N}from"./filepath-item-m6tglha3.js";import{t as P}from"./npanel-grids-fa3ah9jo.js";import{t as F}from"./nsplit-pane-lj2kxwh2.js";import{t as I}from"./ntip-mx3dwcmh.js";import{t as L}from"./ncheckbox-fbnq3guy.js";import{t as R}from"./help-fab-sp6luyzp.js";var z={"h-full":``,grid:`~ rows-[max-content_1fr]`},B={flex:`~ wrap`,"w-full":``},V=[`onClick`],H={key:0,flex:`~ col gap-4 items-center justify-center`,p4:``},U={grid:`~ cols-[30px_1fr] gap-x-2 gap-y-3 items-center justify-center`,"w-100":``},W=`/__nuxt_devtools__/client`,G=Object.assign(i({__name:`BuildAnalyzeDetails`,props:{current:{},prev:{}},setup(n){let i=n,v=`${e().app.baseURL.replace(W,`/`)}/__nuxt_devtools__/analyze/`.replace(/\/+/g,`/`),S=f(()=>{let e=[{name:`Overview`,id:`overview`}];return i.current.features.bundleClient&&e.push({name:`Client Bundle`,id:`bundle-client`}),i.current.features.bundleNitro&&e.push({name:`Nitro Bundle`,id:`bundle-nitro`}),i.current.features.viteInspect&&e.push({name:`Vite Inspect`,id:`vite-inspect`}),e}),C=u(S.value[0]);function w(e){return`${((e.endTime-e.startTime)/1e3).toFixed(1)}s`}function T(e){return e<1024?`${e}B`:e<1048576?`${(e/1024).toFixed(1)}KB`:e<1073741824?`${(e/1024/1024).toFixed(1)}MB`:`${(e/1024/1024/1024).toFixed(1)}GB`}async function E(e){return r.clearAnalyzeBuilds([e])}return(e,r)=>{let i=N,u=D;return a(),m(`div`,z,[p(`div`,B,[(a(!0),m(c,null,y(S.value,(e,t)=>(a(),m(`button`,{key:t,px4:``,py2:``,border:`r base`,hover:`bg-active`,class:s(e.id===C.value?.id?``:`border-b`),onClick:t=>C.value=e},[p(`div`,{class:s(e.id===C.value?.id?``:`op30`)},o(e.name),3)],10,V))),128)),r[1]||=p(`div`,{border:`b base`,"flex-auto":``},null,-1)]),C.value?.id===`overview`?(a(),m(`div`,H,[r[15]||=p(`div`,{"flex-auto":``},null,-1),p(`div`,U,[r[10]||=p(`div`,{"i-carbon-commit":``,"text-xl":``},null,-1),p(`div`,null,[r[2]||=p(`div`,{"text-sm":``,op50:``},` Name `,-1),p(`div`,null,o(n.current.name),1)]),r[11]||=p(`div`,{"i-carbon-time":``,"text-xl":``},null,-1),p(`div`,null,[r[3]||=p(`div`,{"text-sm":``,op50:``},` Build duration `,-1),p(`div`,null,o(w(n.current)),1)]),n.current.size?.clientBundle?(a(),m(c,{key:0},[r[5]||=p(`div`,{"i-carbon-cics-program":``,"text-xl":``},null,-1),p(`div`,null,[r[4]||=p(`div`,{"text-sm":``,op50:``},` Client bundle size `,-1),p(`div`,null,o(T(n.current.size.clientBundle)),1)])],64)):_(``,!0),n.current.size?.nitroBundle?(a(),m(c,{key:1},[r[7]||=p(`div`,{"i-carbon-bare-metal-server":``,"text-xl":``},null,-1),p(`div`,null,[r[6]||=p(`div`,{"text-sm":``,op50:``},` Nitro bundle size `,-1),p(`div`,null,o(T(n.current.size.nitroBundle)),1)])],64)):_(``,!0),r[12]||=p(`div`,{"i-carbon-edge-node":``,"text-xl":``},null,-1),p(`div`,null,[r[8]||=p(`div`,{"text-sm":``,op50:``},` Built `,-1),p(`div`,null,o(h(t)(new Date(n.current.endTime))),1)]),r[13]||=p(`div`,{"i-carbon:folder-parent":``,"text-xl":``},null,-1),p(`div`,null,[r[9]||=p(`div`,{"text-sm":``,op50:``},` Report Path `,-1),b(i,{filepath:n.current.analyzeDir},null,8,[`filepath`])])]),r[16]||=p(`div`,{"flex-auto":``},null,-1),b(u,{n:`rose`,icon:`carbon-delete`,onClick:r[0]||=e=>E(n.current.name)},{default:d(()=>[...r[14]||=[l(` Delete this report `,-1)]]),_:1})])):_(``,!0),r._lazyshow1||C.value?.id===`bundle-client`?(r._lazyshow1=!0,a(),m(c,null,[g(p(`iframe`,{src:`${h(v)}${n.current.slug}/client.html`,"h-full":``,"w-full":``},null,8,[`src`]),[[x,C.value?.id===`bundle-client`]])],64)):_(`v-show-if`,!0),r._lazyshow2||C.value?.id===`bundle-nitro`?(r._lazyshow2=!0,a(),m(c,null,[g(p(`iframe`,{src:`${h(v)}${n.current.slug}/nitro.html`,"h-full":``,"w-full":``},null,8,[`src`]),[[x,C.value?.id===`bundle-nitro`]])],64)):_(`v-show-if`,!0),r._lazyshow3||C.value?.id===`vite-inspect`?(r._lazyshow3=!0,a(),m(c,null,[g(p(`iframe`,{src:`${h(v)}${n.current.slug}/.vite-inspect/`,"h-full":``,"w-full":``},null,8,[`src`]),[[x,C.value?.id===`vite-inspect`]])],64)):_(`v-show-if`,!0)])}}}),{__name:`BuildAnalyzeDetails`}),K={},q={class:`markdown-body`};function J(e,t){return a(),m(`div`,q,[...t[0]||=[p(`template`,null,[p(`div`,{class:`markdown-body`},[p(`h1`,null,`Build Analyze`),p(`p`,null,[l(`DevTools provides a build analyze tool to help you understand the size of your app in production. Whenever you start a new build, it runs the command `),p(`code`,{"v-pre":``},`nuxt build --analyze`),l(` and present the output data directly in DevTools for easy browsing and comparing.`)])])],-1)]])}var Y=T(K,[[`render`,J]]),X={flex:`~ col`},Z=[`onClick`],Q={flex:`~ gap-1 items-center wrap`,"w-full":``,"text-sm":``,op60:``},$={flex:`~ items-center justify-center wrap`,p4:``},ee={flex:`~ col gap-1`,"w-250":``,p4:``},te={flex:`~ gap-3`,mt2:``,"justify-end":``},ne=i({__name:`analyze-build`,setup(e){M({icon:`carbon-edge-node`,title:`Build Analyze`,layout:`full`,category:`analyze`,show(){return w(`^3.5.0`)}});let i=n(),g=S(),x=C(`analyze-build:slug`,``),T=f(()=>g.value?.builds.find(e=>e.slug===x.value)??g.value?.builds[0]),N=u(!1),z=u(``),B=f(()=>g.value?.builds.some(e=>e.name===z.value.trim()));async function V(){if(z.value=await r.generateAnalyzeBuildName(),!await i.start())return;A(`analyze-build:start`);let e=await r.startAnalyzeBuild(z.value);N.value&&r.revealTerminal(e)}function H(e){return`${((e.endTime-e.startTime)/1e3).toFixed(1)}s`}function U(){g.value?.activeSessionId&&r.revealTerminal(g.value.activeSessionId)}return k(()=>[{id:`action:analyze-build: start`,title:`Start a new analyze build`,icon:`i-carbon-edge-node`,action:V}]),(e,n)=>{let r=D,u=G,f=P,S=F,C=E,w=I,k=j,A=L,M=O,W=Y,K=R;return a(),m(c,null,[b(S,{"left-size":30},{left:d(()=>[p(`div`,X,[(a(!0),m(c,null,y(h(g)?.builds,e=>(a(),m(c,{key:e.slug},[p(`button`,{flex:`~ col gap1`,p3:``,"hover:bg-active":``,class:s(e.slug===T.value?.slug?`text-primary bg-active`:``),onClick:t=>x.value=e.slug},[p(`code`,null,o(e.name),1),p(`div`,Q,[n[4]||=p(`div`,{"i-carbon-time":``},null,-1),p(`span`,null,o(H(e)),1),n[5]||=p(`div`,{"flex-auto":``},null,-1),p(`span`,null,o(h(t)(new Date(e.endTime))),1)])],10,Z),n[6]||=p(`div`,{"x-divider":``},null,-1)],64))),128)),p(`div`,$,[h(g)?.isBuilding?(a(),v(r,{key:1,n:`primary`,icon:`carbon-circle-dash animate-spin`,title:`Open the output in the Terminals dock`,onClick:n[1]||=e=>U()},{default:d(()=>[...n[8]||=[l(` Building... `,-1)]]),_:1})):(a(),v(r,{key:0,n:`primary`,icon:`carbon-edge-node`,onClick:n[0]||=e=>V()},{default:d(()=>[...n[7]||=[l(` Start a new build `,-1)]]),_:1}))])])]),right:d(()=>[T.value?(a(),v(u,{key:0,current:T.value},null,8,[`current`])):(a(),v(f,{key:1}))]),_:1}),b(h(i),null,{default:d(({resolve:e})=>[b(M,{"model-value":!0,onClose:t=>e(!1)},{default:d(()=>[p(`div`,ee,[n[13]||=p(`h3`,{class:`text-lg font-medium leading-6`,mb2:``},` Start analyze build? `,-1),n[14]||=p(`p`,{op50:``},` Enter the name of the build: `,-1),b(C,{modelValue:z.value,"onUpdate:modelValue":n[2]||=e=>z.value=e,placeholder:`Build name`},null,8,[`modelValue`]),B.value?(a(),v(w,{key:0,"n-orange":``},{default:d(()=>[...n[9]||=[l(` A build with the same name already exists, continue would overrides the previous build result. `,-1)]]),_:1})):_(``,!0),n[15]||=p(`div`,{my3:``,"x-divider":``},null,-1),n[16]||=p(`p`,{op50:``},` The following command will be executed in your terminal: `,-1),b(k,{code:`npx nuxi analyze --no-serve --name=${z.value}`,lang:`bash`,px4:``,py2:``,border:`~ base rounded`,lines:!1},null,8,[`code`]),b(A,{modelValue:N.value,"onUpdate:modelValue":n[3]||=e=>N.value=e,mt2:``,n:`primary`},{default:d(()=>[...n[10]||=[l(` Open the Terminals dock `,-1)]]),_:1},8,[`modelValue`]),p(`div`,te,[b(r,{onClick:t=>e(!1)},{default:d(()=>[...n[11]||=[l(` Cancel `,-1)]]),_:1},8,[`onClick`]),b(r,{n:`solid primary`,onClick:t=>e(!0)},{default:d(()=>[...n[12]||=[l(` Start `,-1)]]),_:1},8,[`onClick`])])])]),_:2},1032,[`onClose`])]),_:1}),b(K,null,{default:d(()=>[b(W)]),_:1})],64)}}});export{ne as default};
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import{B as e,I as t,L as n,R as r,T as i,_ as a,b as o,h as s,j as c,n as l,q as u,t as d,y as f}from"./nicon-ccnh6x2r.js";import{C as p,H as m,J as h,Qt as g,X as _,Yt as v,Zt as y,a as b,b as x,bt as S,ct as C,d as w,f as T,h as E,ht as D,kt as O,lt as k,m as A,p as j,q as M,x as N}from"./vendor/json-editor-vue-h1waqukq.js";import{St as P,bt as F}from"./ready-ikhds7hc.js";import{j as I,w as L}from"./utils-c5p5s7ov.js";import{i as R,n as ee,t as te}from"./editor-cv8lunmj.js";import{t as z}from"./ntext-input-j7ulf0ma.js";import{t as B}from"./nbutton-mxt3cxcx.js";import{t as ne}from"./ndialog-jnj3j8xn.js";import{t as V}from"./fuse-ipb957gg.js";import{t as H}from"./telemetry-gc8f0sai.js";import{t as U}from"./ndropdown-hviylh0n.js";import{t as W}from"./ndrawer-ll4inus6.js";import{t as G}from"./composables-ioamscf4.js";import{t as re}from"./filepath-item-m6tglha3.js";import{t as K}from"./ncheckbox-fbnq3guy.js";import{t as q}from"./nnavbar-f1l2np9t.js";import{t as J}from"./nsection-block-nwojdml4.js";import{t as Y}from"./code-snippets-jzjkfinz.js";var X={key:0,"h-full":``,"w-full":``,flex:``,"items-center":``,"justify-center":``},ie={for:`drop-zone-input`,"text-3xl":``,hover:`text-green cursor-pointer`,"transition-all":``},ae={key:1,relative:``,"h-full":``,"w-full":``,grid:`~ rows-[max-content_1fr_max-content]`},oe={grid:`~ cols-minmax-8rem gap-8`,"overflow-auto":``,p6:``},se={flex:``,"items-center":``,"justify-center":``,"of-hidden":``,rounded:``,"rounded-t-lg":``,"bg-active":``,"object-cover":``,class:`aspect-1/1`,border:`~ base`},ce=[`src`],le={flex:`~ gap1`,"items-center":``},ue={flex:`~ gap-2`,"items-center":``,"justify-center":``,p8:``},de=Object.assign(p({__name:`AssetDropZone`,props:{modelValue:{type:Boolean,required:!0},folder:{type:String,required:!0}},setup(e){let t=e,n=/\.\w+$/,i=r(t,`modelValue`),o=S(),l=S([]);function u(e){o.value=e.target,i.value=!0}function p(e){e.target===o.value&&(i.value=!1)}function h(e){e.preventDefault()}function g(e){e.preventDefault(),y(e.dataTransfer.files)}function y(e){let t=[...e||[]];if(t.length){let e=[],n=l.value.map(e=>e.name);for(let r of t)if(n.includes(r.name)){let t=1,[i,a]=r.name.split(`.`);for(;n.includes(`${i} (${t}).${a}`);)t++;let o=`${i}-${t}.${a}`,s=new Blob([r],{type:r.type}),c=new File([s],o,{lastModified:Date.now()});e.push(c),n.push(o)}else r.type===``&&R({message:`Folders are not supported yet`,icon:`carbon:face-dissatisfied`,classes:`text-orange`}),e.push(r);l.value=[...l.value,...e]}}async function w(){if(a.value||f.value)return;H(`assets:upload`);let e=[];for(let t of l.value){let n=new FileReader;n.readAsDataURL(t);let r=(await new Promise(e=>{n.onload=()=>e(n.result)})).split(`;base64,`).pop();e.push({path:t.name,encoding:`base64`,content:r})}await s.writeStaticAssets([...e],t.folder).then(()=>{L(),R({message:`Files uploaded successfully!`,icon:`i-carbon:checkmark`})}).catch(e=>{L(),R({message:`Error uploading files: ${e?.message??`unknown`}`,icon:`i-carbon-warning`,classes:`text-red`})}),i.value=!1}function D(e){l.value?.splice(e,1)}function P(e){return URL.createObjectURL(e)}function F(e,t){let[r,i]=e.name.split(`.`),a=t.replace(n,``),o=`${a}.${i}`;return a.length===0?(alert(`File name must be at least 1 characters long`),r):(Object.defineProperty(e,"name",{value:o,writable:!1}),l.value.splice(l.value.indexOf(e),1,e),e)}function I(){l.value=[]}function L(){i.value=!1,I()}return c(`dragenter`,u),c(`dragleave`,p),c(`dragover`,h),c(`drop`,g),(e,t)=>{let n=B,r=d,a=z,o=_(`tooltip`);return m(),E(`div`,{fixed:``,"bottom-0":``,"left-13":``,"right-0":``,"top-0":``,"z-10":``,"backdrop-blur-20":``,"transition-all":``,class:v(O(i)?`opacity-100 visible`:`opacity-0 invisible`)},[k(N(n,{icon:`carbon-close`,title:`Close`,absolute:``,"right-5":``,"top-5":``,"z-20":``,"text-xl":``,border:!1,onClick:L},null,512),[[o,`Close`,void 0,{"bottom-end":!0}]]),l.value?.length?(m(),E(`div`,ae,[t[4]||=T(`div`,{px6:``,py6:``},[T(`h1`,{"text-2xl":``},` Upload `),T(`p`,{"text-sm":``,op50:``},` Drag and drop files to upload `)],-1),T(`div`,oe,[(m(!0),E(b,null,M(l.value,(e,t)=>(m(),E(`div`,{key:e.name,flex:`~ col gap-2`,relative:``,"h-50":``,"w-40":``,"items-center":``},[T(`div`,se,[T(`img`,{"h-full":``,"w-full":``,"rounded-t-lg":``,"object-cover":``,src:P(e)},null,8,ce)]),T(`div`,le,[N(a,{n:`xs`,"h-full":``,"flex-auto":``,"model-value":e.name,"onUpdate:modelValue":t=>F(e,t.target.value)},null,8,[`model-value`,`onUpdate:modelValue`]),N(n,{n:`red`,icon:`carbon-trash-can`,"h-full":``,"flex-none":``,title:`Remove file`,onClick:e=>D(t)},null,8,[`onClick`])])]))),128))]),T(`div`,ue,[l.value.length?(m(),j(n,{key:0,n:`red`,onClick:I},{default:C(()=>[N(r,{icon:`carbon-clean`}),t[2]||=x(` Clear `,-1)]),_:1})):A(``,!0),N(n,{disabled:!l.value.length,n:`primary solid`,onClick:w},{default:C(()=>[N(r,{icon:`carbon-cloud-upload`}),t[3]||=x(` Upload `,-1)]),_:1},8,[`disabled`])])])):(m(),E(`div`,X,[T(`label`,ie,[N(r,{icon:`carbon-cloud-upload`,"mr-2":``}),t[1]||=x(` Drop files here or click to select `,-1)]),T(`input`,{id:`drop-zone-input`,type:`file`,multiple:``,hidden:``,onChange:t[0]||=e=>y(e.target.files)},null,32)]))],2)}}}),{__name:`AssetDropZone`}),fe=Object.assign(p({__name:`AssetFontPreview`,props:{asset:{}},setup(e){let n=e,r=w(()=>`devtools-assets-${u(n.asset)}`);return t(w(()=>`
|
|
2
|
+
@font-face {
|
|
3
|
+
font-family: '${r.value}';
|
|
4
|
+
src: url('${n.asset.publicPath}');
|
|
5
|
+
}
|
|
6
|
+
`)),(e,t)=>(m(),E(`div`,{"of-hidden":``,style:y({fontFamily:`'${r.value}'`})},` Aa Bb Cc Dd Ee Ff Gg Hh Ii Jj Kk Ll Mm Nn Oo Pp Qq Rr Ss Tt Uu Vv Ww Xx Yy Zz `,4))}}),{__name:`AssetFontPreview`}),pe={flex:``,"items-center":``,"justify-center":``,"of-hidden":``,"bg-active":``,"object-cover":``,p1:``},me=[`src`],he={key:2,"i-carbon-document":``,"text-3xl":``,op20:``},ge={key:3,"w-full":``,"self-start":``,p4:``},_e=[`textContent`],ve={key:4},ye=[`src`,`autoplay`,`controls`],be={key:5},xe={key:0,"i-carbon-volume-up":``,"text-3xl":``,op20:``},Se=[`src`],Ce={key:6,"i-carbon-help":``,"text-3xl":``,op20:``},Z=Object.assign(p({__name:`AssetPreview`,props:{asset:{},textContent:{},detail:{type:Boolean}},setup(e){return(t,n)=>{let r=fe;return m(),E(`div`,pe,[e.asset.type===`image`?(m(),E(`img`,{key:0,src:e.asset.publicPath},null,8,me)):e.asset.type===`font`?(m(),j(r,{key:e.asset.publicPath,asset:e.asset,"self-stretch":``,p2:``,"text-2xl":``},null,8,[`asset`])):e.asset.type===`text`&&!e.textContent?(m(),E(`div`,he)):e.asset.type===`text`&&e.textContent?(m(),E(`div`,ge,[T(`pre`,{"max-h-10rem":``,"of-hidden":``,"text-xs":``,"font-mono":``,textContent:g(e.textContent)},null,8,_e)])):e.asset.type===`video`?(m(),E(`div`,ve,[T(`video`,{src:e.asset.publicPath,autoplay:e.detail,controls:e.detail},null,8,ye)])):e.asset.type===`audio`?(m(),E(`div`,be,[e.detail?(m(),E(`audio`,{key:1,src:e.asset.publicPath,controls:``},null,8,Se)):(m(),E(`div`,xe))])):(m(),E(`div`,Ce))])}}}),{__name:`AssetPreview`}),we={relative:``,flex:`~ col gap-1`,hover:`bg-active`,"items-center":``,"of-hidden":``,rounded:``,p2:``},Te={"w-full":``,"of-hidden":``,truncate:``,"ws-nowrap":``,"text-center":``,"text-xs":``},Ee=Object.assign(p({__name:`AssetGridItem`,props:{asset:{},folder:{}},setup(e){let t=e,n=w(()=>t.folder&&t.asset.path.startsWith(t.folder)?t.asset.path.slice(t.folder.length):t.asset.path);return(t,r)=>{let i=d,a=Z;return m(),E(`button`,we,[e.asset.layer?(m(),j(i,{key:0,icon:`i-carbon-layers`,absolute:``,"right-4":``,"top-4":``,"bg-primary":``})):A(``,!0),N(a,{"h-30":``,"w-30":``,rounded:``,border:`~ base`,asset:e.asset},null,8,[`asset`]),T(`div`,Te,g(n.value),1)])}}}),{__name:`AssetGridItem`}),Q=Object.assign(p({__name:`AssetListItem`,props:{item:{},index:{default:0},modelValue:{}},setup(e,{emit:t}){let n=e,i=r(n,`modelValue`,t,{passive:!0}),a=w(()=>n.item?.children?.length),o=S(!0),s=w(()=>a.value?`i-carbon-folder`:n.item.type===`image`?`i-carbon-image`:n.item.type===`video`?`i-carbon-video`:n.item.type===`audio`?`i-carbon-volume-up`:n.item.type===`font`?`i-carbon-text-small-caps`:n.item.type===`text`?`i-carbon-document`:n.item.type===`json`?`i-carbon-json`:`i-carbon-document-blank`);return(t,n)=>{let r=d,c=Q;return m(),E(`div`,null,[T(`button`,{flex:`~ gap-2`,"w-full":``,"items-center":``,hover:`bg-active`,px4:``,py1:``,style:y({paddingLeft:`calc(1rem + ${e.index*1.5}em)`}),class:v({"bg-active":!a.value&&O(i)?.filePath===e.item?.filePath}),border:`b base`,onClick:n[0]||=t=>a.value?o.value=!o.value:i.value=e.item},[T(`div`,{class:v(s.value)},null,2),T(`span`,{class:v({"flex items-center":a.value}),"flex-auto":``,"text-start":``,"text-sm":``,"font-mono":``},[x(g(e.item.path)+` `,1),e.item.layer?(m(),j(r,{key:0,icon:`i-carbon-layers`,"bg-primary":``})):A(``,!0)],2),a.value?(m(),j(r,{key:0,icon:`carbon:chevron-right`,"transform-rotate":o.value?90:0,transition:``},null,8,[`transform-rotate`])):A(``,!0)],6),o.value?h(t.$slots,`default`,{},()=>[(m(!0),E(b,null,M(e.item?.children,t=>(m(),j(c,{key:t.filepath,modelValue:O(i),"onUpdate:modelValue":n[1]||=e=>D(i)?i.value=e:null,item:t,index:e.index+1},null,8,[`modelValue`,`item`,`index`]))),128))],void 0,0):A(``,!0)])}}}),{__name:`AssetListItem`}),De={flex:`~ col gap-4`,"min-h-full":``,"w-full":``,"of-hidden":``,p4:``},Oe={flex:`~`,"items-center":``,"justify-center":``},ke={"max-w-full":``,"w-full":``,"table-fixed":``},Ae={flex:`~ gap-1`,"w-full":``,"items-center":``},je={flex:`~ gap-1`,"w-full":``,"items-center":``,"of-hidden":``},Me={"flex-auto":``,"of-hidden":``,truncate:``,"ws-pre":``,"font-mono":``},Ne={capitalize:``},Pe={key:0},Fe={op70:``},Ie={flex:`~ gap2 wrap`},Le={flex:`~ col gap-4`,"min-h-full":``,"w-full":``,"of-hidden":``,p8:``},Re={flex:`~ gap2 wrap justify-center`},ze={flex:`~ col gap-4`,"min-h-full":``,"w-full":``,"of-hidden":``,p8:``},Be={flex:`~ gap2 wrap justify-center`},Ve={flex:`~ col gap-4`,"min-h-full":``,"w-full":``,"of-hidden":``,p4:``},$={flex:``,"justify-end":``,"gap-4":``},He=Object.assign(p({__name:`AssetDetails`,props:{modelValue:{}},setup(e,{emit:t}){let i=r(e,`modelValue`,t,{passive:!0}),a=o(async()=>{if(i.value.type===`image`)return s.getImageMeta(i.value.filePath)}),c=S(!1),l=S(),u=S(0),d=o(async()=>{if(i.value.type!==`text`)return;u.value;let e=await s.getTextAssetContent(i.value.filePath);return l.value=e,e});async function f(){if(d.value!==l.value)try{await s.writeStaticAssets([{path:i.value.path,content:l.value,override:!0}],``),c.value=!1,u.value++,R({message:`Updated`,icon:`i-carbon-checkmark`,classes:`text-green`})}catch(e){console.error(e),R({message:`Something went wrong!`,icon:`i-carbon-warning`,classes:`text-red`})}}let p=L(),h=w(()=>(p.value?._installedModules||[]).some(e=>e.meta?.name===`@nuxt/image`||e.meta?.name===`@nuxt/image-edge`||e.meta?.name===`@nuxt/image-nightly`)),v=w(()=>{let e=[];if(i.value.type===`image`){let t=a.value?.width?`\n width="${a.value.width}"\n height="${a.value.height}" `:` `;return e.push({lang:`vue-html`,code:`<img${t}\n src="${i.value.publicPath}"\n/>`,name:`Plain Image`}),h.value&&e.push({lang:`vue-html`,code:`<NuxtImg${t}\n src="${i.value.publicPath}"\n/>`,name:`Nuxt Img`,docs:`https://image.nuxt.com/usage/nuxt-img`},{lang:`vue-html`,code:`<NuxtPicture${t}\n src="${i.value.publicPath}"\n/>`,name:`Nuxt Picture`,docs:`https://image.nuxt.com/usage/nuxt-picture`}),e}return e.push({lang:`html`,code:`<a download href="${i.value.publicPath}">\n Download ${i.value.path.split(`/`).slice(-1)[0]}\n</a>`,name:`Download link`}),e}),y=te(),D=ee(),M=n(()=>i.value.mtime),I=w(()=>{let e=i.value.size;return e<1024?`${e} B`:e<1048576?`${(e/1024).toFixed(2)} KB`:`${(e/1024/1024).toFixed(2)} MB`}),V=w(()=>{if(!a.value?.width||!a.value?.height)return``;let e=(t,n)=>n?e(n,t%n):t,t=e(a.value.width,a.value.height);return t>3?`${a.value.width/t}:${a.value.height/t}`:``}),H=w(()=>[`image`,`text`,`video`,`audio`,`font`].includes(i.value.type)),U=S(!1);async function W(){try{await s.deleteStaticAsset(i.value.filePath),i.value=void 0,U.value=!1,R({message:`Asset deleted`,icon:`i-carbon-checkmark`,classes:`text-green`})}catch(e){console.error(e),R({message:`Something went wrong!`,icon:`i-carbon-warning`,classes:`text-red`})}}let G=S(!1),K=S(``);async function q(){let e=i.value.filePath.split(`/`),t=e.slice(-1)[0]?.split(`.`).slice(0,-1).join(`.`);if(!K.value||K.value===t)return R({message:`Please enter a new name`,icon:`i-carbon-warning`,classes:`text-orange`});try{let t=e.slice(-1)[0]?.split(`.`).slice(-1)[0],n=`${e.slice(0,-1).join(`/`)}/${K.value}.${t}`;await s.renameStaticAsset(i.value.filePath,n),i.value=void 0,G.value=!1,R({message:`Asset renamed`,icon:`i-carbon-checkmark`,classes:`text-green`})}catch(e){console.error(e),R({message:`Something went wrong!`,icon:`i-carbon-warning`,classes:`text-red`})}}return(e,t)=>{let n=Z,r=re,o=B,s=Y,u=ne,p=z,h=_(`tooltip`);return m(),E(b,null,[T(`div`,De,[H.value?(m(),E(b,{key:0},[t[13]||=T(`div`,{flex:`~ gap2`,"mb--2":``,"items-center":``,op50:``},[T(`div`,{"x-divider":``}),T(`div`,{"flex-none":``},` Preview `),T(`div`,{"x-divider":``})],-1),T(`div`,Oe,[N(n,{detail:``,"max-h-80":``,"min-h-20":``,"min-w-20":``,"w-auto":``,rounded:``,border:`~ base`,asset:O(i),"text-content":O(d)},null,8,[`asset`,`text-content`])])],64)):A(``,!0),t[25]||=T(`div`,{flex:`~ gap2`,"mb--2":``,"items-center":``,op50:``},[T(`div`,{"x-divider":``}),T(`div`,{"flex-none":``},` Details `),T(`div`,{"x-divider":``})],-1),T(`table`,ke,[T(`tbody`,null,[T(`tr`,null,[t[14]||=T(`td`,{"w-30":``,"ws-nowrap":``,pr5:``,"text-right":``,op50:``},` Filepath `,-1),T(`td`,null,[T(`div`,Ae,[N(r,{filepath:O(i).filePath,"text-left":``},null,8,[`filepath`]),k(N(o,{"flex-none":``,title:`Open in Editor`,icon:`carbon-launch`,border:!1,onClick:t[0]||=e=>O(D)(O(i).filePath)},null,512),[[h,`Open in Editor`]])])])]),T(`tr`,null,[t[15]||=T(`td`,{"w-30":``,"ws-nowrap":``,pr5:``,"text-right":``,op50:``},` Public Path `,-1),T(`td`,null,[T(`div`,je,[T(`div`,Me,g(O(i).publicPath),1),k(N(o,{"flex-none":``,title:`Copy public path`,icon:`carbon-copy`,border:!1,onClick:t[1]||=e=>O(y)(O(i).publicPath,`assets-public-path`)},null,512),[[h,`Copy public path`]]),k(N(o,{"flex-none":``,to:O(i).publicPath,icon:`carbon-launch`,target:`_blank`,border:!1,title:`Open in browser`},null,8,[`to`]),[[h,`Open in browser`]])])])]),T(`tr`,null,[t[16]||=T(`td`,{"w-30":``,"ws-nowrap":``,pr5:``,"text-right":``,op50:``},` Type `,-1),T(`td`,Ne,g(O(i).type),1)]),O(a)?.width?(m(),E(b,{key:0},[T(`tr`,null,[t[17]||=T(`td`,{"w-30":``,"ws-nowrap":``,pr5:``,"text-right":``,op50:``},` Image Size `,-1),T(`td`,null,g(O(a).width)+` x `+g(O(a).height),1)]),V.value?(m(),E(`tr`,Pe,[t[18]||=T(`td`,{"w-30":``,"ws-nowrap":``,pr5:``,"text-right":``,op50:``},` Aspect Ratio `,-1),T(`td`,null,g(V.value),1)])):A(``,!0)],64)):A(``,!0),T(`tr`,null,[t[19]||=T(`td`,{"w-30":``,"ws-nowrap":``,pr5:``,"text-right":``,op50:``},` File size `,-1),T(`td`,null,g(I.value),1)]),T(`tr`,null,[t[20]||=T(`td`,{"w-30":``,"ws-nowrap":``,pr5:``,"text-right":``,op50:``},` Last modified `,-1),T(`td`,null,[x(g(new Date(O(i).mtime).toLocaleString())+` `,1),T(`span`,Fe,`(`+g(O(M))+`)`,1)])])])]),t[26]||=T(`div`,{flex:`~ gap2`,"mb--2":``,"items-center":``,op50:``},[T(`div`,{"x-divider":``}),T(`div`,{"flex-none":``},` Actions `),T(`div`,{"x-divider":``})],-1),T(`div`,Ie,[N(o,{to:O(i).publicPath,download:``,target:`_blank`,icon:`carbon-download`,n:`green`},{default:C(()=>[...t[21]||=[x(` Download `,-1)]]),_:1},8,[`to`]),O(i).type===`text`?(m(),j(o,{key:0,icon:`carbon-edit`,n:`cyan`,onClick:t[2]||=e=>c.value=!c.value},{default:C(()=>[...t[22]||=[x(` Edit `,-1)]]),_:1})):A(``,!0),N(o,{icon:`carbon-text-annotation-toggle`,n:`blue`,onClick:t[3]||=e=>G.value=!G.value},{default:C(()=>[...t[23]||=[x(` Rename `,-1)]]),_:1}),N(o,{icon:`carbon-delete`,n:`red`,onClick:t[4]||=e=>U.value=!U.value},{default:C(()=>[...t[24]||=[x(` Delete `,-1)]]),_:1})]),t[27]||=T(`div`,{"flex-auto":``},null,-1),v.value.length?(m(),j(s,{key:1,border:`t base`,"mx--4":``,"mb--4":``,"code-snippets":v.value},null,8,[`code-snippets`])):A(``,!0)]),N(u,{modelValue:U.value,"onUpdate:modelValue":t[6]||=e=>U.value=e},{default:C(()=>[T(`div`,Le,[t[30]||=T(`span`,null,` Are you sure you want to delete this asset? `,-1),T(`div`,Re,[N(o,{icon:`carbon-close`,onClick:t[5]||=e=>U.value=!1},{default:C(()=>[...t[28]||=[x(` Cancel `,-1)]]),_:1}),N(o,{icon:`carbon-delete`,n:`red`,onClick:W},{default:C(()=>[...t[29]||=[x(` Delete `,-1)]]),_:1})])])]),_:1},8,[`modelValue`]),N(u,{modelValue:G.value,"onUpdate:modelValue":t[9]||=e=>G.value=e},{default:C(()=>[T(`div`,ze,[N(p,{modelValue:K.value,"onUpdate:modelValue":t[7]||=e=>K.value=e,placeholder:`New name`,n:`blue`},null,8,[`modelValue`]),T(`div`,Be,[N(o,{icon:`carbon-close`,onClick:t[8]||=e=>G.value=!1},{default:C(()=>[...t[31]||=[x(` Cancel `,-1)]]),_:1}),N(o,{icon:`carbon-text-annotation-toggle`,n:`blue`,onClick:q},{default:C(()=>[...t[32]||=[x(` Rename `,-1)]]),_:1})])])]),_:1},8,[`modelValue`]),O(i).type===`text`?(m(),j(u,{key:0,modelValue:c.value,"onUpdate:modelValue":t[12]||=e=>c.value=e},{default:C(()=>[T(`div`,Ve,[k(T(`textarea`,{"onUpdate:modelValue":t[10]||=e=>l.value=e,placeholder:`Item value...`,class:`h-lg w-xl of-auto rounded-lg p-4 text-sm font-mono outline-none`,onKeydown:P(f,[`enter`])},null,544),[[F,l.value]]),T(`div`,$,[N(o,{icon:`carbon-close`,onClick:t[11]||=e=>c.value=!1},{default:C(()=>[...t[33]||=[x(` Cancel `,-1)]]),_:1}),N(o,{icon:`carbon:save`,n:`primary`,onClick:f},{default:C(()=>[...t[34]||=[x(` save `,-1)]]),_:1})])])]),_:1},8,[`modelValue`])):A(``,!0)],64)}}}),{__name:`AssetDetails`}),Ue={"h-full":``,"of-auto":``},We={"flex-none":``,flex:`~ gap2 items-center`,"text-lg":``},Ge={flex:`~ items-center justify-center`,absolute:``,"bottom--1":``,"right--1":``,"h-4":``,"w-4":``,"rounded-full":``,"bg-primary:30":``,"text-8px":``},Ke={flex:`~ col`,"w-30":``,"of-auto":``},qe={"text-xs":``,op75:``},Je={op50:``},Ye={key:0},Xe={"mt--4":``,px2:``,grid:`~ cols-minmax-8rem`},Ze={key:1,p2:``,grid:`~ cols-minmax-8rem`},Qe={key:1},$e=p({__name:`assets`,setup(t){G({icon:`carbon-image-copy`,title:`Assets`,layout:`full`});let n=I(),r=S(!1),a=S(``),o=w(()=>new V(n.value||[],{keys:[`path`]})),s=e(()=>{let e=[];for(let t of n.value||[]){let n=t.path.split(`.`).pop();n&&!e.some(e=>e.name===n)&&e.push({name:n,value:!0})}return e}),c=w(()=>(a.value?o.value.search(a.value).map(e=>e.item):n.value||[]).filter(e=>{let t=e.path.split(`.`).pop();return!t||s.some(e=>e.name===t&&e.value)})),u=w(()=>{let e={};for(let t of c.value){let n=`${t.path.split(`/`).slice(0,-1).join(`/`)}/`;e[n]||(e[n]=[]),e[n].push(t)}return Object.entries(e).sort(([e],[t])=>e.localeCompare(t))}),d=w(()=>{let e={path:`public`,children:[]},t=(e,n,r)=>{let[i,...a]=n,o=e.children.find(e=>e.path===i);o||(o={...r,path:i,children:[]},e.children.push(o)),a.length>1?t(o,a,r):a.length===1&&o.children.push({...r,path:a[0]})};return c.value.forEach(n=>{let r=n.path.split(`/`).filter(e=>e!==``);t(e,r,n)}),e.children}),f=S(),{view:p}=l(`assets`);function h(){p.value=p.value===`list`?`grid`:`list`}i(`Escape`,()=>{f.value=void 0});let v=S();return(e,t)=>{let i=B,o=K,l=U,y=q,x=de,S=Ee,w=J,D=Q,P=He,F=W,I=_(`tooltip`);return m(),E(`div`,Ue,[N(y,{ref_key:`navbar`,ref:v,search:a.value,"onUpdate:search":t[1]||=e=>a.value=e,pb2:``},{actions:C(()=>[T(`div`,We,[k(N(i,{icon:`carbon:cloud-upload`,title:`File Upload`,border:!1,onClick:t[0]||=e=>r.value=!r.value},null,512),[[I,`File Upload`,void 0,{"bottom-end":!0}]]),O(s).length?(m(),j(l,{key:0,direction:`end`,n:`sm primary`},{trigger:C(({click:e})=>[k(N(i,{icon:`carbon-filter`,border:!1,title:`Filter`,p3:``,"text-lg":``,onClick:t=>e()},null,8,[`onClick`]),[[I,`Filter`,void 0,{"bottom-end":!0}]]),T(`span`,Ge,g(O(s).length),1)]),default:C(()=>[T(`div`,Ke,[(m(!0),E(b,null,M(O(s),e=>(m(),j(o,{key:e.name,modelValue:e.value,"onUpdate:modelValue":t=>e.value=t,flex:`~ gap-2`,rounded:``,px2:``,py2:``},{default:C(()=>[T(`span`,qe,g(e.name),1)]),_:2},1032,[`modelValue`,`onUpdate:modelValue`]))),128))])]),_:1})):A(``,!0),k(N(i,{"text-lg":``,border:!1,icon:O(p)===`grid`?`i-carbon-list`:`i-carbon-grid`,title:`Toggle view`,onClick:h},null,8,[`icon`]),[[I,`Toggle View`,void 0,{"bottom-end":!0}]])])]),default:C(()=>[T(`div`,Je,[a.value?(m(),E(`span`,Ye,g(c.value.length)+` matched · `,1)):A(``,!0),T(`span`,null,g(O(n)?.length)+` assets in total`,1)])]),_:1},8,[`search`]),N(x,{modelValue:r.value,"onUpdate:modelValue":t[2]||=e=>r.value=e,folder:`/`},null,8,[`modelValue`]),O(p)===`grid`?(m(),E(b,{key:0},[u.value.length>1?(m(!0),E(b,{key:0},M(u.value,([e,t])=>(m(),j(w,{key:e,text:e,description:`${t.length} items`,open:t.length<=O(50),padding:!1},{default:C(()=>[T(`div`,Xe,[(m(!0),E(b,null,M(t,t=>(m(),j(S,{key:t.path,asset:t,folder:e,onClick:e=>f.value=t},null,8,[`asset`,`folder`,`onClick`]))),128))])]),_:2},1032,[`text`,`description`,`open`]))),128)):(m(),E(`div`,Ze,[(m(!0),E(b,null,M(c.value,e=>(m(),j(S,{key:e.path,asset:e,onClick:t=>f.value=e},null,8,[`asset`,`onClick`]))),128))]))],64)):(m(),E(`div`,Qe,[(m(!0),E(b,null,M(d.value,(e,n)=>(m(),j(D,{key:n,modelValue:f.value,"onUpdate:modelValue":t[3]||=e=>f.value=e,item:e},null,8,[`modelValue`,`item`]))),128))])),N(F,{"model-value":!!f.value,"auto-close":``,"w-120":``,top:v.value,onClose:t[5]||=e=>f.value=void 0},{default:C(()=>[f.value?(m(),j(P,{key:0,modelValue:f.value,"onUpdate:modelValue":t[4]||=e=>f.value=e},null,8,[`modelValue`])):A(``,!0)]),_:1},8,[`model-value`,`top`])])}}});export{$e as default};
|
package/dist/client/_nuxt/{auth-required-panel-mm5lidl3.js → auth-required-panel-hlhmg87z.js}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{J as e}from"./vendor/json-editor-vue-
|
|
1
|
+
import{J as e}from"./vendor/json-editor-vue-h1waqukq.js";import{t}from"./_plugin-vue_export-helper-d9irwgla.js";var n={};function r(t,n){return e(t.$slots,`default`)}var i=Object.assign(t(n,[[`render`,r]]),{__name:`AuthRequiredPanel`});export{i as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"id":"
|
|
1
|
+
{"id":"1183fbc7-b7db-4404-9ee4-7571849e8ffe","timestamp":1787201051203}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"id":"1183fbc7-b7db-4404-9ee4-7571849e8ffe","timestamp":1787201051203,"prerendered":[]}
|