@nuxt/devtools-nightly 2.6.5-29306553.110ec66 → 2.6.5-29358579.0c258d4
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/chunks/module-main.mjs +27 -27
- package/dist/client/200.html +12 -12
- package/dist/client/404.html +12 -12
- package/dist/client/_nuxt/{analyze-build-oyvy2n6k.js → analyze-build-g8sjrv2z.js} +1 -1
- package/dist/client/_nuxt/{assets-iiiil9h9.js → assets-d64fukbn.js} +1 -1
- package/dist/client/_nuxt/builds/latest.json +1 -1
- package/dist/client/_nuxt/builds/meta/6d949717-4f72-4b8f-ab4a-43add5c28ea2.json +1 -0
- package/dist/client/_nuxt/{components-kdxql4pw.js → components-m69qhybz.js} +1 -1
- package/dist/client/_nuxt/{custom-_name_-buxdzxp1.js → custom-_name_-d8xr5ols.js} +1 -1
- package/dist/client/_nuxt/{data-schema-drawer-h78i632s.js → data-schema-drawer-m0642ay4.js} +1 -1
- package/dist/client/_nuxt/{debug-0o48icu2.js → debug-muc6hlrw.js} +1 -1
- package/dist/client/_nuxt/{default-cf08j011.js → default-c2nspeqr.js} +1 -1
- package/dist/client/_nuxt/{error-404-isciqhf2.js → error-404-bfza8pjy.js} +1 -1
- package/dist/client/_nuxt/{error-500-c949zj2y.js → error-500-gvq1ofsq.js} +1 -1
- package/dist/client/_nuxt/{error-acajsfcm.js → error-kkczr13h.js} +1 -1
- package/dist/client/_nuxt/{full-gwf8k3h8.js → full-g973cipt.js} +1 -1
- package/dist/client/_nuxt/{hooks-i3c9zo45.js → hooks-j17719nd.js} +1 -1
- package/dist/client/_nuxt/{imports-pdvz452h.js → imports-i9odkp1s.js} +1 -1
- package/dist/client/_nuxt/{index-fexmm3yj.js → index-ebrbbgwp.js} +1 -1
- package/dist/client/_nuxt/{f05hqzgb.js → m8cyoooy.js} +5 -5
- package/dist/client/_nuxt/{modules-5z6nfxe1.js → modules-m73nzwro.js} +1 -1
- package/dist/client/_nuxt/{none-e00yke7p.js → none-kod0wjii.js} +1 -1
- package/dist/client/_nuxt/{open-graph-hi306joh.js → open-graph-pe9i8d76.js} +1 -1
- package/dist/client/_nuxt/{overview-e8qf7rb9.js → overview-e9eewad2.js} +1 -1
- package/dist/client/_nuxt/{pages-kc19iifh.js → pages-lcwqvn9k.js} +1 -1
- package/dist/client/_nuxt/{payload-ha4336zu.js → payload-g490ej9a.js} +1 -1
- package/dist/client/_nuxt/{pinia-cmu5xh15.js → pinia-c8puw8i8.js} +1 -1
- package/dist/client/_nuxt/{plugins-i44pfamd.js → plugins-nv3v13im.js} +1 -1
- package/dist/client/_nuxt/{render-tree-kzon7sx5.js → render-tree-2ewluw8m.js} +1 -1
- package/dist/client/_nuxt/{runtime-configs-oedus2mc.js → runtime-configs-k8otipyv.js} +1 -1
- package/dist/client/_nuxt/{server-discovery-mfcbprv0.js → server-discovery-c0ik8ywv.js} +1 -1
- package/dist/client/_nuxt/{server-routes-i9u3il1o.js → server-routes-il1kr8mz.js} +1 -1
- package/dist/client/_nuxt/{server-tasks-cfvjphup.js → server-tasks-oyf96fso.js} +1 -1
- package/dist/client/_nuxt/{settings-hq5m70v8.js → settings-ll0xqgui.js} +1 -1
- package/dist/client/_nuxt/{storage-mlmdplne.js → storage-c3flod4b.js} +1 -1
- package/dist/client/_nuxt/{terminals-e0nyivcj.js → terminals-et318vjt.js} +1 -1
- package/dist/client/_nuxt/{timeline-dazlkvc4.js → timeline-f40bnngi.js} +1 -1
- package/dist/client/_nuxt/{unocss-runtime-njuf1ctl.js → unocss-runtime-kbniizgc.js} +1 -1
- package/dist/client/_nuxt/vendor/{unocss-nr5d25zy.js → unocss-la8bop5t.js} +2 -2
- package/dist/client/_nuxt/{virtual-files-e0zxw441.js → virtual-files-dqv301q7.js} +1 -1
- package/dist/client/index.html +12 -12
- package/dist/module.json +1 -1
- package/package.json +4 -4
- package/dist/client/_nuxt/builds/meta/4c13e94d-ac56-47f5-bbbd-0467b8121ba0.json +0 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import fs, { existsSync, promises, statSync, realpathSync, readFileSync, accessSync, constants } from 'node:fs';
|
|
2
2
|
import fsp from 'node:fs/promises';
|
|
3
3
|
import os, { homedir } from 'node:os';
|
|
4
|
-
import { logger, useNuxt, addPlugin, addTemplate,
|
|
4
|
+
import { logger, useNuxt, addVitePlugin, addPlugin, addTemplate, extendViteConfig, addImports } from '@nuxt/kit';
|
|
5
5
|
import { colors } from 'consola/utils';
|
|
6
6
|
import { join, dirname as dirname$1, resolve, isAbsolute } from 'pathe';
|
|
7
7
|
import sirv from 'sirv';
|
|
@@ -33,7 +33,7 @@ import { getDefaultExportOptions, addNuxtModule } from 'magicast/helpers';
|
|
|
33
33
|
import { detectPackageManager } from 'nypm';
|
|
34
34
|
import semver from 'semver';
|
|
35
35
|
|
|
36
|
-
const version$1 = "2.6.5-
|
|
36
|
+
const version$1 = "2.6.5-29358579.0c258d4";
|
|
37
37
|
|
|
38
38
|
const urlAlphabet = "useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";
|
|
39
39
|
function randomStr(size = 16, dict = urlAlphabet) {
|
|
@@ -10983,25 +10983,27 @@ function setupServerDataRPC({
|
|
|
10983
10983
|
nuxt.hook("nitro:build:before", (_nitro) => {
|
|
10984
10984
|
nitro = _nitro;
|
|
10985
10985
|
});
|
|
10986
|
-
|
|
10987
|
-
|
|
10988
|
-
|
|
10989
|
-
|
|
10990
|
-
|
|
10991
|
-
|
|
10992
|
-
|
|
10993
|
-
|
|
10994
|
-
|
|
10995
|
-
|
|
10996
|
-
|
|
10997
|
-
|
|
10998
|
-
|
|
10999
|
-
|
|
11000
|
-
|
|
11001
|
-
|
|
11002
|
-
|
|
11003
|
-
|
|
11004
|
-
|
|
10986
|
+
addVitePlugin({
|
|
10987
|
+
name: "nuxt:devtools:config",
|
|
10988
|
+
applyToEnvironment(environment) {
|
|
10989
|
+
if (environment.name === "ssr") {
|
|
10990
|
+
return {
|
|
10991
|
+
name: "nuxt:devtools:config-retriever",
|
|
10992
|
+
enforce: "post",
|
|
10993
|
+
configResolved(config) {
|
|
10994
|
+
viteServer = normalizeViteConfig(config);
|
|
10995
|
+
}
|
|
10996
|
+
};
|
|
10997
|
+
}
|
|
10998
|
+
if (environment.name === "client") {
|
|
10999
|
+
return {
|
|
11000
|
+
name: "nuxt:devtools:config-retriever",
|
|
11001
|
+
enforce: "post",
|
|
11002
|
+
configResolved(config) {
|
|
11003
|
+
viteClient = normalizeViteConfig(config);
|
|
11004
|
+
}
|
|
11005
|
+
};
|
|
11006
|
+
}
|
|
11005
11007
|
}
|
|
11006
11008
|
});
|
|
11007
11009
|
return {
|
|
@@ -11567,7 +11569,7 @@ window.__NUXT_DEVTOOLS_TIME_METRIC__.appInit = Date.now()
|
|
|
11567
11569
|
} = setupRPC(nuxt, options);
|
|
11568
11570
|
addVitePlugin(vitePlugin);
|
|
11569
11571
|
const clientDirExists = existsSync(clientDir);
|
|
11570
|
-
|
|
11572
|
+
extendViteConfig((config) => {
|
|
11571
11573
|
config.server ||= {};
|
|
11572
11574
|
config.server.fs ||= {};
|
|
11573
11575
|
config.server.fs.allow ||= [
|
|
@@ -11581,11 +11583,9 @@ window.__NUXT_DEVTOOLS_TIME_METRIC__.appInit = Date.now()
|
|
|
11581
11583
|
config.server.watch.ignored.push("**/.nuxt/analyze/**");
|
|
11582
11584
|
config.server.watch.ignored.push("**/.cache/nuxt-devtools/**");
|
|
11583
11585
|
});
|
|
11584
|
-
|
|
11585
|
-
|
|
11586
|
-
|
|
11587
|
-
from: join(runtimeDir, "use-nuxt-devtools")
|
|
11588
|
-
});
|
|
11586
|
+
addImports({
|
|
11587
|
+
name: "useNuxtDevTools",
|
|
11588
|
+
from: join(runtimeDir, "use-nuxt-devtools")
|
|
11589
11589
|
});
|
|
11590
11590
|
const ROUTE_PATH = `${nuxt.options.app.baseURL || "/"}/__nuxt_devtools__`.replace(/\/+/g, "/");
|
|
11591
11591
|
const ROUTE_CLIENT = `${ROUTE_PATH}/client`;
|
package/dist/client/200.html
CHANGED
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
<!DOCTYPE html><html><head><meta charset="utf-8">
|
|
2
2
|
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
3
|
-
<script type="importmap">{"imports":{"#entry":"/__NUXT_DEVTOOLS_BASE__/_nuxt/
|
|
3
|
+
<script type="importmap">{"imports":{"#entry":"/__NUXT_DEVTOOLS_BASE__/_nuxt/m8cyoooy.js"}}</script>
|
|
4
4
|
<link rel="stylesheet" href="/__NUXT_DEVTOOLS_BASE__/_nuxt/entry.css-bgro2w4m.css" crossorigin>
|
|
5
5
|
<link rel="stylesheet" href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/json-editor-vue.css-mqq5uooj.css" crossorigin>
|
|
6
6
|
<link rel="stylesheet" href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/unocss.css-mhvipxpl.css" crossorigin>
|
|
7
|
-
<link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/
|
|
7
|
+
<link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/m8cyoooy.js">
|
|
8
8
|
<link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/json-editor-vue-gd4lkf0o.js">
|
|
9
9
|
<link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/shiki-jxvjmls6.js">
|
|
10
|
-
<link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/unocss-
|
|
10
|
+
<link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/unocss-la8bop5t.js">
|
|
11
11
|
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/markdown-it-fvu08dbs.js">
|
|
12
|
-
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/default-
|
|
13
|
-
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/full-
|
|
14
|
-
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/none-
|
|
12
|
+
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/default-c2nspeqr.js">
|
|
13
|
+
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/full-g973cipt.js">
|
|
14
|
+
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/none-kod0wjii.js">
|
|
15
15
|
<link rel="prefetch" as="style" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ncode-block.css-lvdc77tw.css">
|
|
16
|
-
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/data-schema-drawer-
|
|
16
|
+
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/data-schema-drawer-m0642ay4.js">
|
|
17
17
|
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nselect.vue-j457efs9.js">
|
|
18
18
|
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nswitch.vue-m7rzt1v6.js">
|
|
19
19
|
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ndropdown.vue-mt2skirs.js">
|
|
@@ -21,10 +21,10 @@
|
|
|
21
21
|
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/client-kvgyopwa.js">
|
|
22
22
|
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ndrawer.vue-bscihm5p.js">
|
|
23
23
|
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/quicktype-core-jxekulwx.js">
|
|
24
|
-
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/unocss-runtime-
|
|
24
|
+
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/unocss-runtime-kbniizgc.js">
|
|
25
25
|
<link rel="prefetch" as="style" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/error-404.css-nxlugf5l.css">
|
|
26
|
-
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/error-404-
|
|
26
|
+
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/error-404-bfza8pjy.js">
|
|
27
27
|
<link rel="prefetch" as="style" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/error-500.css-bcokcrit.css">
|
|
28
|
-
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/error-500-
|
|
29
|
-
<script type="module" src="/__NUXT_DEVTOOLS_BASE__/_nuxt/
|
|
30
|
-
<script>window.__NUXT__={};window.__NUXT__.config={public:{},app:{baseURL:"/__NUXT_DEVTOOLS_BASE__/",buildId:"
|
|
28
|
+
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/error-500-gvq1ofsq.js">
|
|
29
|
+
<script type="module" src="/__NUXT_DEVTOOLS_BASE__/_nuxt/m8cyoooy.js" crossorigin></script></head><body><div id="__nuxt"></div><div id="teleports"></div><script type="application/json" data-nuxt-data="nuxt-app" data-ssr="false" id="__NUXT_DATA__">[{"prerenderedAt":1,"serverRendered":2},1761514771684,false]</script>
|
|
30
|
+
<script>window.__NUXT__={};window.__NUXT__.config={public:{},app:{baseURL:"/__NUXT_DEVTOOLS_BASE__/",buildId:"6d949717-4f72-4b8f-ab4a-43add5c28ea2",buildAssetsDir:"/_nuxt/",cdnURL:""}}</script></body></html>
|
package/dist/client/404.html
CHANGED
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
<!DOCTYPE html><html><head><meta charset="utf-8">
|
|
2
2
|
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
3
|
-
<script type="importmap">{"imports":{"#entry":"/__NUXT_DEVTOOLS_BASE__/_nuxt/
|
|
3
|
+
<script type="importmap">{"imports":{"#entry":"/__NUXT_DEVTOOLS_BASE__/_nuxt/m8cyoooy.js"}}</script>
|
|
4
4
|
<link rel="stylesheet" href="/__NUXT_DEVTOOLS_BASE__/_nuxt/entry.css-bgro2w4m.css" crossorigin>
|
|
5
5
|
<link rel="stylesheet" href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/json-editor-vue.css-mqq5uooj.css" crossorigin>
|
|
6
6
|
<link rel="stylesheet" href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/unocss.css-mhvipxpl.css" crossorigin>
|
|
7
|
-
<link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/
|
|
7
|
+
<link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/m8cyoooy.js">
|
|
8
8
|
<link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/json-editor-vue-gd4lkf0o.js">
|
|
9
9
|
<link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/shiki-jxvjmls6.js">
|
|
10
|
-
<link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/unocss-
|
|
10
|
+
<link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/unocss-la8bop5t.js">
|
|
11
11
|
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/markdown-it-fvu08dbs.js">
|
|
12
|
-
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/default-
|
|
13
|
-
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/full-
|
|
14
|
-
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/none-
|
|
12
|
+
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/default-c2nspeqr.js">
|
|
13
|
+
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/full-g973cipt.js">
|
|
14
|
+
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/none-kod0wjii.js">
|
|
15
15
|
<link rel="prefetch" as="style" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ncode-block.css-lvdc77tw.css">
|
|
16
|
-
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/data-schema-drawer-
|
|
16
|
+
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/data-schema-drawer-m0642ay4.js">
|
|
17
17
|
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nselect.vue-j457efs9.js">
|
|
18
18
|
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nswitch.vue-m7rzt1v6.js">
|
|
19
19
|
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ndropdown.vue-mt2skirs.js">
|
|
@@ -21,10 +21,10 @@
|
|
|
21
21
|
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/client-kvgyopwa.js">
|
|
22
22
|
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ndrawer.vue-bscihm5p.js">
|
|
23
23
|
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/quicktype-core-jxekulwx.js">
|
|
24
|
-
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/unocss-runtime-
|
|
24
|
+
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/unocss-runtime-kbniizgc.js">
|
|
25
25
|
<link rel="prefetch" as="style" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/error-404.css-nxlugf5l.css">
|
|
26
|
-
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/error-404-
|
|
26
|
+
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/error-404-bfza8pjy.js">
|
|
27
27
|
<link rel="prefetch" as="style" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/error-500.css-bcokcrit.css">
|
|
28
|
-
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/error-500-
|
|
29
|
-
<script type="module" src="/__NUXT_DEVTOOLS_BASE__/_nuxt/
|
|
30
|
-
<script>window.__NUXT__={};window.__NUXT__.config={public:{},app:{baseURL:"/__NUXT_DEVTOOLS_BASE__/",buildId:"
|
|
28
|
+
<link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/error-500-gvq1ofsq.js">
|
|
29
|
+
<script type="module" src="/__NUXT_DEVTOOLS_BASE__/_nuxt/m8cyoooy.js" crossorigin></script></head><body><div id="__nuxt"></div><div id="teleports"></div><script type="application/json" data-nuxt-data="nuxt-app" data-ssr="false" id="__NUXT_DATA__">[{"prerenderedAt":1,"serverRendered":2},1761514771684,false]</script>
|
|
30
|
+
<script>window.__NUXT__={};window.__NUXT__.config={public:{},app:{baseURL:"/__NUXT_DEVTOOLS_BASE__/",buildId:"6d949717-4f72-4b8f-ab4a-43add5c28ea2",buildAssetsDir:"/_nuxt/",cdnURL:""}}</script></body></html>
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{b6 as X,b7 as j,_ as P,r as V,E as R,b8 as Y,a6 as h,a7 as ee,Z as ne,a1 as te,j as le,b9 as k,a8 as ie,Q as oe,v as re,q as ue,aj as se,M as ae}from"#entry";import{_ as de}from"./filepath-item.vue-e693vfym.js";import{p as U,q as S,k as F,J as u,$ as i,a0 as e,a1 as g,F as p,ag as L,X as d,a8 as v,u as b,V as a,ab as f,ac as D,ad as I,a4 as E,U as B}from"./vendor/json-editor-vue-gd4lkf0o.js";import{_ as me}from"./ncode-block.vue-nph7f5ph.js";import{_ as pe}from"./ncheckbox.vue-cowm3nmm.js";import{_ as ve}from"./help-fab.vue-le7iybnb.js";import"./vendor/shiki-jxvjmls6.js";import"./vendor/unocss-
|
|
1
|
+
import{b6 as X,b7 as j,_ as P,r as V,E as R,b8 as Y,a6 as h,a7 as ee,Z as ne,a1 as te,j as le,b9 as k,a8 as ie,Q as oe,v as re,q as ue,aj as se,M as ae}from"#entry";import{_ as de}from"./filepath-item.vue-e693vfym.js";import{p as U,q as S,k as F,J as u,$ as i,a0 as e,a1 as g,F as p,ag as L,X as d,a8 as v,u as b,V as a,ab as f,ac as D,ad as I,a4 as E,U as B}from"./vendor/json-editor-vue-gd4lkf0o.js";import{_ as me}from"./ncode-block.vue-nph7f5ph.js";import{_ as pe}from"./ncheckbox.vue-cowm3nmm.js";import{_ as ve}from"./help-fab.vue-le7iybnb.js";import"./vendor/shiki-jxvjmls6.js";import"./vendor/unocss-la8bop5t.js";import"./client-kvgyopwa.js";const fe={"h-full":"",grid:"~ rows-[max-content_1fr]"},ce={flex:"~ wrap","w-full":""},ye=["onClick"],be={key:0,flex:"~ col gap-4 items-center justify-center",p4:""},xe={grid:"~ cols-[30px_1fr] gap-x-2 gap-y-3 items-center justify-center","w-100":""},ge="/__nuxt_devtools__/client",_e=U({__name:"BuildAnalyzeDetails",props:{current:{},prev:{}},setup(N){const c=N,w=`${X().app.baseURL.replace(ge,"/")}/__nuxt_devtools__/analyze/`.replace(/\/+/g,"/"),y=S(()=>{const l=[{name:"Overview",id:"overview"}];return c.current.features.bundleClient&&l.push({name:"Client Bundle",id:"bundle-client"}),c.current.features.bundleNitro&&l.push({name:"Nitro Bundle",id:"bundle-nitro"}),c.current.features.viteInspect&&l.push({name:"Vite Inspect",id:"vite-inspect"}),l}),o=F(y.value[0]);function $(l){return`${((l.endTime-l.startTime)/1e3).toFixed(1)}s`}function m(l){return l<1024?`${l}B`:l<1024*1024?`${(l/1024).toFixed(1)}KB`:l<1024*1024*1024?`${(l/1024/1024).toFixed(1)}MB`:`${(l/1024/1024/1024).toFixed(1)}GB`}async function T(l){return V.clearAnalyzeBuilds(await R(),[l])}return(l,n)=>{const A=de,C=P;return i(),u("div",fe,[e("div",ce,[(i(!0),u(p,null,L(y.value,(r,t)=>(i(),u("button",{key:t,px4:"",py2:"",border:"r base",hover:"bg-active",class:E(r.id===o.value?.id?"":"border-b"),onClick:z=>o.value=r},[e("div",{class:E(r.id===o.value?.id?"":"op30")},v(r.name),3)],10,ye))),128)),n[1]||(n[1]=e("div",{border:"b base","flex-auto":""},null,-1))]),o.value?.id==="overview"?(i(),u("div",be,[n[15]||(n[15]=e("div",{"flex-auto":""},null,-1)),e("div",xe,[n[10]||(n[10]=e("div",{"i-carbon-commit":"","text-xl":""},null,-1)),e("div",null,[n[2]||(n[2]=e("div",{"text-sm":"",op50:""}," Name ",-1)),e("div",null,v(l.current.name),1)]),n[11]||(n[11]=e("div",{"i-carbon-time":"","text-xl":""},null,-1)),e("div",null,[n[3]||(n[3]=e("div",{"text-sm":"",op50:""}," Build duration ",-1)),e("div",null,v($(l.current)),1)]),l.current.size?.clientBundle?(i(),u(p,{key:0},[n[5]||(n[5]=e("div",{"i-carbon-cics-program":"","text-xl":""},null,-1)),e("div",null,[n[4]||(n[4]=e("div",{"text-sm":"",op50:""}," Client bundle size ",-1)),e("div",null,v(m(l.current.size.clientBundle)),1)])],64)):g("",!0),l.current.size?.nitroBundle?(i(),u(p,{key:1},[n[7]||(n[7]=e("div",{"i-carbon-bare-metal-server":"","text-xl":""},null,-1)),e("div",null,[n[6]||(n[6]=e("div",{"text-sm":"",op50:""}," Nitro bundle size ",-1)),e("div",null,v(m(l.current.size.nitroBundle)),1)])],64)):g("",!0),n[12]||(n[12]=e("div",{"i-carbon-edge-node":"","text-xl":""},null,-1)),e("div",null,[n[8]||(n[8]=e("div",{"text-sm":"",op50:""}," Built ",-1)),e("div",null,v(b(j)(new Date(l.current.endTime))),1)]),n[13]||(n[13]=e("div",{"i-carbon:folder-parent":"","text-xl":""},null,-1)),e("div",null,[n[9]||(n[9]=e("div",{"text-sm":"",op50:""}," Report Path ",-1)),d(A,{filepath:l.current.analyzeDir},null,8,["filepath"])])]),n[16]||(n[16]=e("div",{"flex-auto":""},null,-1)),d(C,{n:"rose",icon:"carbon-delete",onClick:n[0]||(n[0]=r=>T(l.current.name))},{default:a(()=>[...n[14]||(n[14]=[f(" Delete this report ",-1)])]),_:1})])):g("",!0),n._lazyshow1||o.value?.id==="bundle-client"?(n._lazyshow1=!0,i(),u(p,null,[D(e("iframe",{src:`${b(w)}${l.current.slug}/client.html`,"h-full":"","w-full":""},null,8,["src"]),[[I,o.value?.id==="bundle-client"]])],64)):g("v-show-if",!0),n._lazyshow2||o.value?.id==="bundle-nitro"?(n._lazyshow2=!0,i(),u(p,null,[D(e("iframe",{src:`${b(w)}${l.current.slug}/nitro.html`,"h-full":"","w-full":""},null,8,["src"]),[[I,o.value?.id==="bundle-nitro"]])],64)):g("v-show-if",!0),n._lazyshow3||o.value?.id==="vite-inspect"?(n._lazyshow3=!0,i(),u(p,null,[D(e("iframe",{src:`${b(w)}${l.current.slug}/.vite-inspect/`,"h-full":"","w-full":""},null,8,["src"]),[[I,o.value?.id==="vite-inspect"]])],64)):g("v-show-if",!0)])}}}),we={class:"markdown-body"},$e={__name:"analyze-build",setup(N,{expose:c}){return c({frontmatter:{}}),(w,y)=>(i(),u("div",we,[...y[0]||(y[0]=[e("h1",null,"Build Analyze",-1),e("p",null,[f("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 "),e("code",null,"nuxt build --analyze"),f(" and present the output data directly in DevTools for easy browsing and comparing.")],-1)])]))}},ze={flex:"~ col"},Be=["onClick"],Ce={flex:"~ gap-1 items-center wrap","w-full":"","text-sm":"",op60:""},ke={flex:"~ items-center justify-center wrap",p4:""},Ne={flex:"~ col gap-1","w-250":"",p4:""},Te={flex:"~ gap-3",mt2:"","justify-end":""},Re=U({__name:"analyze-build",setup(N){const c=se(),_=Y(),w=h(),y=ee("analyze-build:slug",""),o=S(()=>_.value?.builds.find(r=>r.slug===y.value)??_.value?.builds[0]),$=F(!1),m=F(""),T=S(()=>_.value?.builds.some(r=>r.name===m.value.trim()));async function l(){m.value=await V.generateAnalyzeBuildName(),await c.start()&&(ae("analyze-build:start"),k.value={name:m.value,processId:await V.startAnalyzeBuild(await R(),m.value)},$.value&&C())}const n=ne();function A(r){return`${((r.endTime-r.startTime)/1e3).toFixed(1)}s`}function C(){k.value?.processId&&(n.value=k.value.processId,w.push("/modules/terminals"))}return te(()=>[{id:"action:analyze-build: start",title:"Start a new analyze build",icon:"i-carbon-edge-node",action:l}]),(r,t)=>{const z=P,G=_e,q=le,M=ie,O=re,Z=ue,H=me,J=pe,K=oe,Q=$e,W=ve;return i(),u(p,null,[d(M,{"left-size":30},{left:a(()=>[e("div",ze,[(i(!0),u(p,null,L(b(_)?.builds,s=>(i(),u(p,{key:s.slug},[e("button",{flex:"~ col gap1",p3:"","hover:bg-active":"",class:E(s.slug===o.value?.slug?"text-primary bg-active":""),onClick:x=>y.value=s.slug},[e("code",null,v(s.name),1),e("div",Ce,[t[4]||(t[4]=e("div",{"i-carbon-time":""},null,-1)),e("span",null,v(A(s)),1),t[5]||(t[5]=e("div",{"flex-auto":""},null,-1)),e("span",null,v(b(j)(new Date(s.endTime))),1)])],10,Be),t[6]||(t[6]=e("div",{"x-divider":""},null,-1))],64))),128)),e("div",ke,[b(k)?(i(),B(z,{key:1,n:"primary",icon:"carbon-circle-dash animate-spin",onClick:t[1]||(t[1]=s=>C())},{default:a(()=>[...t[8]||(t[8]=[f(" Building... ",-1)])]),_:1})):(i(),B(z,{key:0,n:"primary",icon:"carbon-edge-node",onClick:t[0]||(t[0]=s=>l())},{default:a(()=>[...t[7]||(t[7]=[f(" Start a new build ",-1)])]),_:1}))])])]),right:a(()=>[o.value?(i(),B(G,{key:0,current:o.value},null,8,["current"])):(i(),B(q,{key:1}))]),_:1}),d(b(c),null,{default:a(({resolve:s})=>[d(K,{"model-value":!0,onClose:x=>s(!1)},{default:a(()=>[e("div",Ne,[t[13]||(t[13]=e("h3",{class:"text-lg font-medium leading-6",mb2:""}," Start analyze build? ",-1)),t[14]||(t[14]=e("p",{op50:""}," Enter the name of the build: ",-1)),d(O,{modelValue:m.value,"onUpdate:modelValue":t[2]||(t[2]=x=>m.value=x),placeholder:"Build name"},null,8,["modelValue"]),T.value?(i(),B(Z,{key:0,"n-orange":""},{default:a(()=>[...t[9]||(t[9]=[f(" A build with the same name already exists, continue would overrides the previous build result. ",-1)])]),_:1})):g("",!0),t[15]||(t[15]=e("div",{my3:"","x-divider":""},null,-1)),t[16]||(t[16]=e("p",{op50:""}," The following command will be executed in your terminal: ",-1)),d(H,{code:`npx nuxi analyze --no-serve --name=${m.value}`,lang:"bash",px4:"",py2:"",border:"~ base rounded",lines:!1},null,8,["code"]),d(J,{modelValue:$.value,"onUpdate:modelValue":t[3]||(t[3]=x=>$.value=x),mt2:"",n:"primary"},{default:a(()=>[...t[10]||(t[10]=[f(" Navigate to terminal ",-1)])]),_:1},8,["modelValue"]),e("div",Te,[d(z,{onClick:x=>s(!1)},{default:a(()=>[...t[11]||(t[11]=[f(" Cancel ",-1)])]),_:1},8,["onClick"]),d(z,{n:"solid primary",onClick:x=>s(!0)},{default:a(()=>[...t[12]||(t[12]=[f(" Start ",-1)])]),_:1},8,["onClick"])])])]),_:2},1032,["onClose"])]),_:1}),d(W,null,{default:a(()=>[d(Q)]),_:1})],64)}}});export{Re as default};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{G as Z,H as ee,_ as te,I as ne,J as R,K as ce,L as pe,M as me,r as W,E as X,v as se,N as ve,O as fe,c as le,A as ge,a as he,w as xe,P as be,Q as we,R as _e,S as ye,T as $e,g as ke,U as Ce}from"#entry";import{_ as Ve}from"./ncheckbox.vue-cowm3nmm.js";import{_ as Pe}from"./ndropdown.vue-mt2skirs.js";import{_ as Ae}from"./nnavbar.vue-fe2vbqhk.js";import{p as J,k as T,ai as oe,J as i,$ as o,a4 as H,u as m,ac as K,X as d,a0 as t,ab as D,F as z,ag as G,U as V,a1 as U,V as h,q as S,a2 as ae,a8 as N,W as De,j as Ne,at as Fe,a3 as Ue}from"./vendor/json-editor-vue-gd4lkf0o.js";import{_ as Se}from"./nsection-block-b1meb1ma.js";import{_ as Ie}from"./filepath-item.vue-e693vfym.js";import{_ as Te}from"./code-snippets.vue-i2momvvn.js";import{_ as je}from"./ndrawer.vue-bscihm5p.js";import{D as Ee}from"./constants-b32h69zq.js";import"./vendor/shiki-jxvjmls6.js";import"./vendor/unocss-
|
|
1
|
+
import{G as Z,H as ee,_ as te,I as ne,J as R,K as ce,L as pe,M as me,r as W,E as X,v as se,N as ve,O as fe,c as le,A as ge,a as he,w as xe,P as be,Q as we,R as _e,S as ye,T as $e,g as ke,U as Ce}from"#entry";import{_ as Ve}from"./ncheckbox.vue-cowm3nmm.js";import{_ as Pe}from"./ndropdown.vue-mt2skirs.js";import{_ as Ae}from"./nnavbar.vue-fe2vbqhk.js";import{p as J,k as T,ai as oe,J as i,$ as o,a4 as H,u as m,ac as K,X as d,a0 as t,ab as D,F as z,ag as G,U as V,a1 as U,V as h,q as S,a2 as ae,a8 as N,W as De,j as Ne,at as Fe,a3 as Ue}from"./vendor/json-editor-vue-gd4lkf0o.js";import{_ as Se}from"./nsection-block-b1meb1ma.js";import{_ as Ie}from"./filepath-item.vue-e693vfym.js";import{_ as Te}from"./code-snippets.vue-i2momvvn.js";import{_ as je}from"./ndrawer.vue-bscihm5p.js";import{D as Ee}from"./constants-b32h69zq.js";import"./vendor/shiki-jxvjmls6.js";import"./vendor/unocss-la8bop5t.js";import"./nicon-title.vue-l5va2e26.js";import"./ncode-block.vue-nph7f5ph.js";import"./client-kvgyopwa.js";const Be={key:0,"h-full":"","w-full":"",flex:"","items-center":"","justify-center":""},Le={for:"drop-zone-input","text-3xl":"",hover:"text-green cursor-pointer","transition-all":""},ze={key:1,relative:"","h-full":"","w-full":"",grid:"~ rows-[max-content_1fr_max-content]"},Oe={grid:"~ cols-minmax-8rem gap-8","overflow-auto":"",p6:""},Re={flex:"","items-center":"","justify-center":"","of-hidden":"",rounded:"","rounded-t-lg":"","bg-active":"","object-cover":"",class:"aspect-1/1",border:"~ base"},Me=["src"],Ke={flex:"~ gap1","items-center":""},qe={flex:"~ gap-2","items-center":"","justify-center":"",p8:""},Ge=J({__name:"AssetDropZone",props:{modelValue:{type:Boolean,required:!0},folder:{type:String,required:!0}},setup(L){const l=L,f=ee(l,"modelValue"),C=T(),n=T([]);function v(s){C.value=s.target,f.value=!0}function b(s){s.target===C.value&&(f.value=!1)}function j(s){s.preventDefault()}function P(s){s.preventDefault(),x(s.dataTransfer.files)}function x(s){const c=Array.from(s||[]);if(c.length){const g=[],_=n.value.map(u=>u.name);for(const u of c)if(_.includes(u.name)){let A=1;const[y,B]=u.name.split(".");for(;_.includes(`${y} (${A}).${B}`);)A++;const M=`${y}-${A}.${B}`,a=new Blob([u],{type:u.type}),e=new File([a],M,{lastModified:Date.now()});g.push(e),_.push(M)}else u.type===""&&R({message:"Folders are not supported yet",icon:"carbon:face-dissatisfied",classes:"text-orange"}),g.push(u);n.value=[...n.value,...g]}}async function E(){if(ce.value||pe.value)return;me("assets:upload");const s=[];for(const c of n.value){const g=new FileReader;g.readAsDataURL(c);const u=(await new Promise(A=>{g.onload=()=>A(g.result)})).split(";base64,").pop();s.push({path:c.name,encoding:"base64",content:u})}await W.writeStaticAssets(await X(),[...s],l.folder).then(()=>{p(),R({message:"Files uploaded successfully!",icon:"i-carbon:checkmark"})}).catch(c=>{p(),R({message:`Error uploading files: ${c?.message??"unknown"}`,icon:"i-carbon-warning",classes:"text-red"})}),f.value=!1}function q(s){n.value?.splice(s,1)}function O(s){return URL.createObjectURL(s)}function w(s,c){const[g,_]=s.name.split("."),u=c.replace(/\.\w+$/,""),A=`${u}.${_}`;return u.length===0?(alert("File name must be at least 1 characters long"),g):(Object.defineProperty(s,"name",{value:A,writable:!1}),n.value.splice(n.value.indexOf(s),1,s),s)}function r(){n.value=[]}function p(){f.value=!1,r()}return Z("dragenter",v),Z("dragleave",b),Z("dragover",j),Z("drop",P),(s,c)=>{const g=te,_=ne,u=se,A=oe("tooltip");return o(),i("div",{fixed:"","bottom-0":"","left-13":"","right-0":"","top-0":"","z-10":"","backdrop-blur-20":"","transition-all":"",class:H(m(f)?"opacity-100 visible":"opacity-0 invisible")},[K(d(g,{icon:"carbon-close",title:"Close",absolute:"","right-5":"","top-5":"","z-20":"","text-xl":"",border:!1,onClick:p},null,512),[[A,"Close",void 0,{"bottom-end":!0}]]),n.value?.length?(o(),i("div",ze,[c[4]||(c[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,[(o(!0),i(z,null,G(n.value,(y,B)=>(o(),i("div",{key:y.name,flex:"~ col gap-2",relative:"","h-50":"","w-40":"","items-center":""},[t("div",Re,[t("img",{"h-full":"","w-full":"","rounded-t-lg":"","object-cover":"",src:O(y)},null,8,Me)]),t("div",Ke,[d(u,{n:"xs","h-full":"","flex-auto":"","model-value":y.name,"onUpdate:modelValue":M=>w(y,M.target.value)},null,8,["model-value","onUpdate:modelValue"]),d(g,{n:"red",icon:"carbon-trash-can","h-full":"","flex-none":"",title:"Remove file",onClick:M=>q(B)},null,8,["onClick"])])]))),128))]),t("div",qe,[n.value.length?(o(),V(g,{key:0,n:"red",onClick:r},{default:h(()=>[d(_,{icon:"carbon-clean"}),c[2]||(c[2]=D(" Clear ",-1))]),_:1})):U("",!0),d(g,{disabled:!n.value.length,n:"primary solid",onClick:E},{default:h(()=>[d(_,{icon:"carbon-cloud-upload"}),c[3]||(c[3]=D(" Upload ",-1))]),_:1},8,["disabled"])])])):(o(),i("div",Be,[t("label",Le,[d(_,{icon:"carbon-cloud-upload","mr-2":""}),c[1]||(c[1]=D(" Drop files here or click to select ",-1))]),t("input",{id:"drop-zone-input",type:"file",multiple:"",hidden:"",onChange:c[0]||(c[0]=y=>x(y.target.files))},null,32)]))],2)}}}),Je=J({__name:"AssetFontPreview",props:{asset:{}},setup(L){const l=L,f=S(()=>`devtools-assets-${ve(l.asset)}`);return fe(S(()=>`
|
|
2
2
|
@font-face {
|
|
3
3
|
font-family: '${f.value}';
|
|
4
4
|
src: url('${l.asset.publicPath}');
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"id":"
|
|
1
|
+
{"id":"6d949717-4f72-4b8f-ab4a-43add5c28ea2","timestamp":1761514744713}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"id":"6d949717-4f72-4b8f-ab4a-43add5c28ea2","timestamp":1761514744713,"matcher":{"static":{},"wildcard":{},"dynamic":{}},"prerendered":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as ie,_ as X,a4 as re,aq as ue,A as me,B as ce,g as J,ar as de,n as fe,as as ve,S as he,Y as _e,W as be,I as ge,f as xe}from"#entry";import{J as m,$ as o,a0 as n,p as G,q as P,ab as E,a8 as O,a1 as g,W as j,X as u,U as b,V as c,u as $,F as B,ag as M,k as F,n as ye,E as we,x as ke,j as z,Z as Ce,a4 as Ne,Y as W,ai as $e,ac as Y,af as Ve}from"./vendor/json-editor-vue-gd4lkf0o.js";import{_ as De}from"./help-fab.vue-le7iybnb.js";import{_ as Pe}from"./ncheckbox.vue-cowm3nmm.js";import{_ as Z}from"./nnavbar.vue-fe2vbqhk.js";import{p as K}from"./index-jc4yj4to.js";import{_ as Q}from"./nbadge-hbh0pw7g.js";import{_ as ee}from"./filepath-item.vue-e693vfym.js";import{_ as Se}from"./ndrawer.vue-bscihm5p.js";import{D as Le,N as Be}from"./vendor/vis-bs03k74b.js";import{_ as Ie}from"./nselect-tabs.vue-hb4dua1x.js";import{_ as Te}from"./nsection-block-b1meb1ma.js";import{_ as Me}from"./nicon-title.vue-l5va2e26.js";import{D as H}from"./constants-b32h69zq.js";import{u as Ue,a as Fe}from"./state-components-i9ev6w42.js";import"./vendor/shiki-jxvjmls6.js";import"./vendor/unocss-nr5d25zy.js";const Ge={class:"markdown-body"},Ae={__name:"components",setup(D,{expose:l}){return l({frontmatter:{}}),(p,d)=>(o(),m("div",Ge,[...d[0]||(d[0]=[n("h1",null,"Components",-1),n("p",null,"Vue Components allow us to split the UI into independent and reusable pieces, and think about each piece in isolation. This is very similar to how we nest native HTML elements, but Vue implements its own component model that allow us to encapsulate custom content and logic in each component.",-1),n("p",null,"Components placed in the components/ directory are automatically registered by Nuxt. They can be used in your templates without importing them.",-1),n("p",null,[n("a",{href:"https://nuxt.com/docs/guide/directory-structure/components",target:"_blank",rel:"noopener"},"Learn more in the documentation")],-1)])]))}},Re={"text-sm":"","font-mono":""},ne=G({__name:"ComponentName",props:{component:{}},setup(D){const l=D,v=P(()=>l.component.pascalName||K(l.component.name||l.component.__name||l.component.kebabName||""));return(p,d)=>(o(),m("code",Re,[d[0]||(d[0]=n("span",{mr1:"",op20:""},"<",-1)),E(O(v.value),1),d[1]||(d[1]=n("span",{ml1:"",op20:""},"/>",-1))]))}}),ze={flex:"~ col gap1","items-start":"","of-hidden":""},Ee={flex:"~ gap2 items-center",px3:""},We={px3:"",pb2:""},Oe={key:0,border:"t base","max-h-60":"","w-full":"","of-auto":"",px3:"",py3:""},je={"text-sm":""},qe={"text-primary":""},He={key:0,flex:"~ col gap-2","items-start":"",pt3:"","text-sm":"",op75:""},Xe={key:1,border:"t base","max-h-60":"","w-full":"","of-auto":"",px3:"",py3:""},Ye={"text-sm":""},Je={"text-primary":""},Ze={key:0,flex:"~ col gap-2","items-start":"",pt3:"","text-sm":"",op75:""},oe=G({__name:"ComponentDetails",props:{component:{},dependencies:{},dependents:{}},setup(D){const l=D,v=P(()=>l.component.pascalName||K(l.component.name||l.component.__name||l.component.kebabName||"")),p=P(()=>l.component.filePath||l.component.file||l.component.__file||""),d=ie();return(s,h)=>{const i=ne,x=X,a=Q,w=ee;return o(),m("div",ze,[n("div",Ee,[u(i,{component:s.component},null,8,["component"]),s.component.meta?.docs&&typeof s.component.meta.docs=="string"?(o(),b(x,{key:0,title:"Open docs","flex-none":"",n:"xs",to:s.component.meta.docs,target:"_blank",icon:"carbon-catalog"},{default:c(()=>[...h[1]||(h[1]=[E(" Docs ",-1)])]),_:1},8,["to"])):g("",!0),u(x,{title:"Copy name","flex-none":"",n:"xs",icon:"carbon-copy",onClick:h[0]||(h[0]=_=>$(d)(`<${v.value}></${v.value}>`,"component-name"))},{default:c(()=>[...h[2]||(h[2]=[E(" Copy ",-1)])]),_:1}),s.component.global?(o(),b(a,{key:1,n:"green",title:"Registered at runtime as a global component",textContent:"runtime"})):g("",!0)]),n("div",We,[p.value?(o(),b(w,{key:0,filepath:p.value,"w-full":"","text-sm":"",op40:"","group-hover:op75":""},null,8,["filepath"])):g("",!0)]),s.dependents?(o(),m("div",Oe,[n("div",je,[n("strong",qe,O(s.dependents.length),1),h[3]||(h[3]=n("span",{op50:""}," references",-1))]),s.dependents.length?(o(),m("div",He,[(o(!0),m(B,null,M(s.dependents,_=>(o(),b(w,{key:_,filepath:_},null,8,["filepath"]))),128))])):g("",!0)])):g("",!0),s.dependencies?(o(),m("div",Xe,[n("div",Ye,[n("strong",Je,O(s.dependencies.length),1),h[4]||(h[4]=n("span",{op50:""}," dependencies",-1))]),s.dependencies.length?(o(),m("div",Ze,[(o(!0),m(B,null,M(s.dependencies,_=>(o(),b(w,{key:_,filepath:_},null,8,["filepath"]))),128))])):g("",!0)])):g("",!0),j(s.$slots,"default")])}}}),Ke={flex:"~ gap-x-3 gap-y-1 wrap","w-full":""},Qe={relative:"","h-full":"","w-full":""},en={key:0,py4:"",pt3:"",flex:"~ col"},nn={border:"t base",p4:""},on=G({__name:"ComponentsGraph",props:{components:{},relationships:{}},setup(D){const l=D,v=F(),p=F(),d=re(),s=ye(),h=ue(),i=me(),x=ce(),{componentsGraphShowNodeModules:a,componentsGraphShowGlobalComponents:w,componentsGraphShowPages:_,componentsGraphShowLayouts:k,componentsGraphShowWorkspace:S}=J("ui"),f=F(),C=F(""),r=de(C,300),A=P(()=>{const V=l.relationships||[];if(f.value){let e=function(N){!N||t.has(N)||(t.add(N),N.deps.forEach(I=>{e(V.find(U=>U.id===I))}))};const t=new Set;return e(f.value),Array.from(t)}return V}),T=P(()=>{const V=A.value.map(t=>{const N=l.components.find(R=>R.filePath===t.id),I=h.value?.find(R=>R.file===t.id),U=x.value?.find(R=>R.file===t.id),L=t.id.includes("/node_modules/")?"lib":N?N.global?"global":"user":U?"layout":I?"page":"unknown";if(!a.value&&L==="lib"||!_.value&&L==="page"||!k.value&&L==="layout"||!S.value&&L==="user"&&i.value&&!t.id.startsWith(i.value.rootDir)||!w.value&&L==="global")return null;const q=L==="layout"?"hexagon":L==="page"?"square":"dot",y=r.value&&!t.id.toLowerCase().includes(r.value.toLowerCase());return{id:t.id,label:ae(t.id),group:L,shape:q,size:15+Math.min(t.deps.length/2,8),font:{color:y?"#8885":d.value==="dark"?"white":"black"},color:y?"#8885":f.value?.id===t.id?"#82c742":void 0,extra:{id:t.id,component:N,page:I,layout:U,relationship:t}}}).filter(t=>!!t),e=A.value.flatMap(t=>t.deps.map(N=>({from:t.id,to:N,arrows:{to:{enabled:!0,scaleFactor:.8}}})));return{nodes:new Le(V),edges:e}}),te=P(()=>s.value?.component?l.relationships?.find(e=>e.id===s.value?.component?.filePath)?.deps?.map(e=>l.relationships?.find(t=>t.id===e)?.id).filter(Boolean):[]),se=P(()=>s.value?.component?l.relationships?.filter(e=>e.deps.includes(s.value.component.filePath))?.map(e=>l.relationships?.find(t=>t.id===e.id)?.id).filter(Boolean):[]);we(()=>{const V={nodes:{shape:"dot",size:16},physics:{repulsion:{centralGravity:.7,springLength:100,springConstant:.01},maxVelocity:146,solver:"forceAtlas2Based",timestep:.35,stabilization:{enabled:!0,iterations:200}},groups:{user:{color:"#42b883"},unknown:{color:"#b86542"},lib:{color:"#b4b842"},page:{color:"#42b2b8"},layout:{color:"#4256b8"}}},e=new Be(v.value,T.value,V);e.on("click",t=>{const N=t.nodes?.[0],I=T.value.nodes.get(N).extra;s.value=I}),ke(T,()=>{e.setData(T.value)})});function le(){s.value=void 0}function ae(V){const e=l.components.find(t=>t.filePath===V);return e?e.pascalName:V.replace(/.*\/components\//,"").replace(/\.vue$/,"").replace(/\/index$/,"").split("/").map(t=>t.charAt(0).toUpperCase()+t.slice(1)).join("")}function pe(){f.value=s.value?.relationship,s.value=void 0}return(V,e)=>{const t=Pe,N=Z,I=fe,U=oe,L=X,q=Se;return o(),m(B,null,[u(N,{ref_key:"navbar",ref:p,search:C.value,"onUpdate:search":e[6]||(e[6]=y=>C.value=y),absolute:"","left-0":"","right-0":"","top-0":""},{actions:c(()=>[n("div",Ke,[u(t,{modelValue:$(_),"onUpdate:modelValue":e[0]||(e[0]=y=>z(_)?_.value=y:null),n:"primary sm"},{default:c(()=>[...e[8]||(e[8]=[n("span",{op75:""},"Show pages",-1)])]),_:1},8,["modelValue"]),u(t,{modelValue:$(k),"onUpdate:modelValue":e[1]||(e[1]=y=>z(k)?k.value=y:null),n:"primary sm"},{default:c(()=>[...e[9]||(e[9]=[n("span",{op75:""},"Show layouts",-1)])]),_:1},8,["modelValue"]),u(t,{modelValue:$(S),"onUpdate:modelValue":e[2]||(e[2]=y=>z(S)?S.value=y:null),n:"primary sm"},{default:c(()=>[...e[10]||(e[10]=[n("span",{op75:""},"Show workspace",-1)])]),_:1},8,["modelValue"]),u(t,{modelValue:$(a),"onUpdate:modelValue":e[3]||(e[3]=y=>z(a)?a.value=y:null),n:"primary sm"},{default:c(()=>[...e[11]||(e[11]=[n("span",{op75:""},"Show node_modules",-1)])]),_:1},8,["modelValue"]),u(t,{modelValue:$(w),"onUpdate:modelValue":e[4]||(e[4]=y=>z(w)?w.value=y:null),n:"primary sm"},{default:c(()=>[...e[12]||(e[12]=[n("span",{op75:""},"Show global components",-1)])]),_:1},8,["modelValue"])]),f.value?(o(),m("button",{key:0,flex:"~ gap-1","flex-none":"","items-center":"","rounded-full":"","bg-gray:20":"",py1:"",pl3:"",pr2:"","text-xs":"",op50:"","hover:op100":"",onClick:e[5]||(e[5]=y=>f.value=void 0)},[...e[13]||(e[13]=[E(" Clear filter ",-1),n("div",{"i-carbon-close":""},null,-1)])])):g("",!0),e[14]||(e[14]=n("div",{"flex-auto":""},null,-1)),j(V.$slots,"default")]),_:3},8,["search"]),n("div",Qe,[n("div",{ref_key:"container",ref:v,"h-full":"","w-full":""},null,512),u(I,{absolute:"","bottom-3":"","left-3":"","border-0":"","n-glass-effect":"",p2:"",px3:"","text-sm":""},{default:c(()=>[...e[15]||(e[15]=[n("div",{grid:"~ cols-[20px_1fr] items-center gap-y-1"},[n("div",{"h-3":"","w-3":"","rounded-full":"","bg-hex-42b883":""}),n("div",{op50:""}," Component "),n("div",{"h-3":"","w-3":"","rounded-full":"","bg-hex-97c2fc":""}),n("div",{op50:""}," Global Component "),n("div",{"h-3":"","w-3":"","bg-hex-42b2b8":""}),n("div",{op50:""}," Page "),n("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 726 628","ml--1px":"","h-3":""},[n("path",{fill:"#4256b8","stroke-width":"4",d:"M723 314 543 625.8H183L3 314 183 2.2h360L723 314z"})]),n("div",{op50:""}," Layout "),n("div",{"h-3":"","w-3":"","rounded-full":"","bg-hex-b4b842":""}),n("div",{op50:""}," Library Component "),n("div",{"h-3":"","w-3":"","rounded-full":"","bg-hex-b86542":""}),n("div",{op50:""}," Unknown ")],-1)])]),_:1}),u(q,{"model-value":!!(s.value&&s.value.component),top:p.value,border:"t l base","w-80":"",onClose:le},{default:c(()=>[s.value&&s.value.component?(o(),m("div",en,[u(U,{component:s.value.component,dependencies:te.value,dependents:se.value},null,8,["component","dependencies","dependents"]),n("div",nn,[u(L,{n:"primary solid",onClick:e[7]||(e[7]=y=>pe())},{default:c(()=>[...e[16]||(e[16]=[E(" Filter to this component ",-1)])]),_:1})])])):g("",!0)]),_:1},8,["model-value","top"])])],64)}}}),tn={hover:"bg-active",class:"group",flex:"~ gap2","w-full":"","items-center":"",rounded:"",px2:"",py1:""},sn={key:0,"ml--1":"","text-primary":""},ln=G({__name:"ComponentItem",props:{component:{},dependencies:{},dependents:{}},setup(D){const l=D,v=P(()=>l.component.filePath||l.component.file||l.component.__file||"");return(p,d)=>{const s=ne,h=oe,i=Ce("VDropdown"),x=Q,a=ee;return o(),m("div",tn,[u(i,null,{popper:c(()=>[u(h,{component:p.component,dependencies:p.dependencies,dependents:p.dependents,"w-100":"",pt3:""},null,8,["component","dependencies","dependents"])]),default:c(()=>[n("button",{"hover:text-primary":"",class:Ne(p.dependents&&p.dependents.length===0?"op50":"")},[u(s,{component:p.component},null,8,["component"])],2)]),_:1}),p.dependents?.length?(o(),m("sup",sn," x"+O(p.dependents?.length),1)):g("",!0),p.component.global?(o(),b(x,{key:1,n:"green",title:"Registered at runtime as a global component",textContent:"runtime"})):g("",!0),j(p.$slots,"default"),v.value?(o(),b(a,{key:2,filepath:v.value,"text-sm":"",op25:"","group-hover:op75":""},null,8,["filepath"])):g("",!0)])}}}),an={flex:"~ gap-2 items-center"},pn={pl4:""},rn=G({__name:"ComponentsList",props:{components:{},relationships:{}},setup(D){const l=D,v=F(""),p=F("all"),d=P(()=>{const x=l.components.map(a=>ve(a,l.relationships));return p.value==="using"?x.filter(a=>a.dependents?.length):p.value==="not-used"?x.filter(a=>!a.dependents?.length):x}),s={ClientOnly:"https://nuxt.com/docs/api/components/client-only",DevOnly:"https://nuxt.com/docs/api/components/dev-only",NuxtClientFallback:"https://nuxt.com/docs/api/components/nuxt-client-fallback",NuxtPicture:"https://nuxt.com/docs/api/components/nuxt-picture",NuxtRouteAnnouncer:"https://nuxt.com/docs/api/components/nuxt-route-announcer",NuxtTime:"https://nuxt.com/docs/api/components/nuxt-time",NuxtPage:"https://nuxt.com/docs/api/components/nuxt-page",NuxtLayout:"https://nuxt.com/docs/api/components/nuxt-layout",NuxtLink:"https://nuxt.com/docs/api/components/nuxt-link",NuxtLoadingIndicator:"https://nuxt.com/docs/api/components/nuxt-loading-indicator",NuxtErrorBoundary:"https://nuxt.com/docs/api/components/nuxt-error-boundary",NuxtWelcome:"https://nuxt.com/docs/api/components/nuxt-welcome",NuxtIsland:"https://nuxt.com/docs/api/components/nuxt-island",NuxtImg:"https://nuxt.com/docs/api/components/nuxt-img"},h=P(()=>new he(d.value,{keys:["component.pascalName","component.filePath","component.kebabName"]})),i=P(()=>{const x=[],a=new Map,w=[],_=[],k={user:0,lib:0,builtin:0,runtime:0};return(v.value?h.value.search(v.value).map(f=>f.item):d.value).forEach(f=>{const C=f.component;if(C.filePath&&_e(C.filePath)){const r=be(C.filePath);if(!r)return;r==="nuxt"?(C.meta??={},C.meta.docs??=s?.[C.pascalName],w.push(f),k.builtin++):(a.has(r)||a.set(r,[]),a.get(r).push(f),k.lib++)}else C.global&&!C.filePath?(_.push(f),k.runtime++):(x.push(f),k.user++)}),{count:k,user:x,builtin:w,lib:a,runtime:_}});return(x,a)=>{const w=ge,_=Ie,k=Z,S=ln,f=Te,C=Me;return o(),m(B,null,[u(k,{search:v.value,"onUpdate:search":a[1]||(a[1]=r=>v.value=r),pb3:""},{actions:c(()=>[j(x.$slots,"default")]),default:c(()=>[n("div",an,[u(w,{icon:"carbon-filter",op50:""}),u(_,{modelValue:p.value,"onUpdate:modelValue":a[0]||(a[0]=r=>p.value=r),n:"primary sm",options:[{label:"All",value:"all"},{label:"Using",value:"using"},{label:"Not used",value:"not-used"}]},null,8,["modelValue"])])]),_:3},8,["search"]),i.value.user.length?(o(),b(f,{key:0,icon:"carbon-nominal",text:"User components",open:i.value.user.length<=$(H),description:`Total components: ${i.value.count.user}`},{default:c(()=>[(o(!0),m(B,null,M(i.value.user,r=>(o(),b(S,W({key:r.component.filePath},{ref_for:!0},r),null,16))),128))]),_:1},8,["open","description"])):g("",!0),i.value.runtime.length?(o(),b(f,{key:1,icon:"carbon-load-balancer-global",open:i.value.runtime.length<=$(H),text:"Runtime components",description:`Total components: ${i.value.count.runtime}`},{default:c(()=>[(o(!0),m(B,null,M(i.value.runtime,r=>(o(),b(S,W({key:r.component.filePath},{ref_for:!0},r),null,16))),128))]),_:1},8,["open","description"])):g("",!0),i.value.builtin.length?(o(),b(f,{key:2,icon:"simple-icons-nuxtdotjs",text:"Built-in components",description:`Total components: ${i.value.count.builtin}`},{default:c(()=>[(o(!0),m(B,null,M(i.value.builtin,r=>(o(),b(S,W({key:r.component.filePath},{ref_for:!0},r),null,16))),128))]),_:1},8,["description"])):g("",!0),i.value.lib.size?(o(),b(f,{key:3,open:i.value.count.lib<=$(H),icon:"carbon-3d-mpr-toggle",text:"Components from libraries",description:`${i.value.count.lib} components from ${i.value.lib.size} packages`},{default:c(()=>[(o(!0),m(B,null,M(i.value.lib.entries(),([r,A])=>(o(),m("div",{key:r,"ml-2":""},[u(C,{text:`${r} (${A.length})`,py1:"",op50:""},null,8,["text"]),n("div",pn,[(o(!0),m(B,null,M(A,T=>(o(),b(S,W({key:T.component.filePath},{ref_for:!0},T),null,16))),128))])]))),128))]),_:1},8,["open","description"])):g("",!0)],64)}}}),un={relative:"","h-full":"","of-auto":""},mn={"flex-none":"",flex:"~ gap3"},Pn=G({__name:"components",setup(D){const l=xe(),v=Ue(),p=Fe(),{componentsView:d}=J("ui");function s(){l.value?.inspector?.enable()}function h(){d.value=d.value==="list"?"graph":"list"}return(i,x)=>{const a=X,w=Ae,_=De,k=$e("tooltip");return o(),m(B,null,[n("div",un,[(o(),b(Ve($(d)==="list"?rn:on),{components:$(v),relationships:$(p)},{default:c(()=>[n("div",mn,[Y(u(a,{"text-lg":"",border:!1,icon:$(d)==="graph"?"i-carbon-list":"i-carbon-network-4",title:"Toggle view",onClick:h},null,8,["icon"]),[[k,"Toggle View",void 0,{"bottom-end":!0}]]),$(l)?.inspector?.isAvailable?Y((o(),b(a,{key:0,"text-lg":"",border:!1,icon:"i-tabler-focus-2",title:"Inspect Vue components",onClick:s},null,512)),[[k,"Inspect Vue components",void 0,{"bottom-end":!0}]]):g("",!0)])]),_:1},8,["components","relationships"]))]),u(_,null,{default:c(()=>[u(w)]),_:1})],64)}}});export{Pn as default};
|
|
1
|
+
import{a as ie,_ as X,a4 as re,aq as ue,A as me,B as ce,g as J,ar as de,n as fe,as as ve,S as he,Y as _e,W as be,I as ge,f as xe}from"#entry";import{J as m,$ as o,a0 as n,p as G,q as P,ab as E,a8 as O,a1 as g,W as j,X as u,U as b,V as c,u as $,F as B,ag as M,k as F,n as ye,E as we,x as ke,j as z,Z as Ce,a4 as Ne,Y as W,ai as $e,ac as Y,af as Ve}from"./vendor/json-editor-vue-gd4lkf0o.js";import{_ as De}from"./help-fab.vue-le7iybnb.js";import{_ as Pe}from"./ncheckbox.vue-cowm3nmm.js";import{_ as Z}from"./nnavbar.vue-fe2vbqhk.js";import{p as K}from"./index-jc4yj4to.js";import{_ as Q}from"./nbadge-hbh0pw7g.js";import{_ as ee}from"./filepath-item.vue-e693vfym.js";import{_ as Se}from"./ndrawer.vue-bscihm5p.js";import{D as Le,N as Be}from"./vendor/vis-bs03k74b.js";import{_ as Ie}from"./nselect-tabs.vue-hb4dua1x.js";import{_ as Te}from"./nsection-block-b1meb1ma.js";import{_ as Me}from"./nicon-title.vue-l5va2e26.js";import{D as H}from"./constants-b32h69zq.js";import{u as Ue,a as Fe}from"./state-components-i9ev6w42.js";import"./vendor/shiki-jxvjmls6.js";import"./vendor/unocss-la8bop5t.js";const Ge={class:"markdown-body"},Ae={__name:"components",setup(D,{expose:l}){return l({frontmatter:{}}),(p,d)=>(o(),m("div",Ge,[...d[0]||(d[0]=[n("h1",null,"Components",-1),n("p",null,"Vue Components allow us to split the UI into independent and reusable pieces, and think about each piece in isolation. This is very similar to how we nest native HTML elements, but Vue implements its own component model that allow us to encapsulate custom content and logic in each component.",-1),n("p",null,"Components placed in the components/ directory are automatically registered by Nuxt. They can be used in your templates without importing them.",-1),n("p",null,[n("a",{href:"https://nuxt.com/docs/guide/directory-structure/components",target:"_blank",rel:"noopener"},"Learn more in the documentation")],-1)])]))}},Re={"text-sm":"","font-mono":""},ne=G({__name:"ComponentName",props:{component:{}},setup(D){const l=D,v=P(()=>l.component.pascalName||K(l.component.name||l.component.__name||l.component.kebabName||""));return(p,d)=>(o(),m("code",Re,[d[0]||(d[0]=n("span",{mr1:"",op20:""},"<",-1)),E(O(v.value),1),d[1]||(d[1]=n("span",{ml1:"",op20:""},"/>",-1))]))}}),ze={flex:"~ col gap1","items-start":"","of-hidden":""},Ee={flex:"~ gap2 items-center",px3:""},We={px3:"",pb2:""},Oe={key:0,border:"t base","max-h-60":"","w-full":"","of-auto":"",px3:"",py3:""},je={"text-sm":""},qe={"text-primary":""},He={key:0,flex:"~ col gap-2","items-start":"",pt3:"","text-sm":"",op75:""},Xe={key:1,border:"t base","max-h-60":"","w-full":"","of-auto":"",px3:"",py3:""},Ye={"text-sm":""},Je={"text-primary":""},Ze={key:0,flex:"~ col gap-2","items-start":"",pt3:"","text-sm":"",op75:""},oe=G({__name:"ComponentDetails",props:{component:{},dependencies:{},dependents:{}},setup(D){const l=D,v=P(()=>l.component.pascalName||K(l.component.name||l.component.__name||l.component.kebabName||"")),p=P(()=>l.component.filePath||l.component.file||l.component.__file||""),d=ie();return(s,h)=>{const i=ne,x=X,a=Q,w=ee;return o(),m("div",ze,[n("div",Ee,[u(i,{component:s.component},null,8,["component"]),s.component.meta?.docs&&typeof s.component.meta.docs=="string"?(o(),b(x,{key:0,title:"Open docs","flex-none":"",n:"xs",to:s.component.meta.docs,target:"_blank",icon:"carbon-catalog"},{default:c(()=>[...h[1]||(h[1]=[E(" Docs ",-1)])]),_:1},8,["to"])):g("",!0),u(x,{title:"Copy name","flex-none":"",n:"xs",icon:"carbon-copy",onClick:h[0]||(h[0]=_=>$(d)(`<${v.value}></${v.value}>`,"component-name"))},{default:c(()=>[...h[2]||(h[2]=[E(" Copy ",-1)])]),_:1}),s.component.global?(o(),b(a,{key:1,n:"green",title:"Registered at runtime as a global component",textContent:"runtime"})):g("",!0)]),n("div",We,[p.value?(o(),b(w,{key:0,filepath:p.value,"w-full":"","text-sm":"",op40:"","group-hover:op75":""},null,8,["filepath"])):g("",!0)]),s.dependents?(o(),m("div",Oe,[n("div",je,[n("strong",qe,O(s.dependents.length),1),h[3]||(h[3]=n("span",{op50:""}," references",-1))]),s.dependents.length?(o(),m("div",He,[(o(!0),m(B,null,M(s.dependents,_=>(o(),b(w,{key:_,filepath:_},null,8,["filepath"]))),128))])):g("",!0)])):g("",!0),s.dependencies?(o(),m("div",Xe,[n("div",Ye,[n("strong",Je,O(s.dependencies.length),1),h[4]||(h[4]=n("span",{op50:""}," dependencies",-1))]),s.dependencies.length?(o(),m("div",Ze,[(o(!0),m(B,null,M(s.dependencies,_=>(o(),b(w,{key:_,filepath:_},null,8,["filepath"]))),128))])):g("",!0)])):g("",!0),j(s.$slots,"default")])}}}),Ke={flex:"~ gap-x-3 gap-y-1 wrap","w-full":""},Qe={relative:"","h-full":"","w-full":""},en={key:0,py4:"",pt3:"",flex:"~ col"},nn={border:"t base",p4:""},on=G({__name:"ComponentsGraph",props:{components:{},relationships:{}},setup(D){const l=D,v=F(),p=F(),d=re(),s=ye(),h=ue(),i=me(),x=ce(),{componentsGraphShowNodeModules:a,componentsGraphShowGlobalComponents:w,componentsGraphShowPages:_,componentsGraphShowLayouts:k,componentsGraphShowWorkspace:S}=J("ui"),f=F(),C=F(""),r=de(C,300),A=P(()=>{const V=l.relationships||[];if(f.value){let e=function(N){!N||t.has(N)||(t.add(N),N.deps.forEach(I=>{e(V.find(U=>U.id===I))}))};const t=new Set;return e(f.value),Array.from(t)}return V}),T=P(()=>{const V=A.value.map(t=>{const N=l.components.find(R=>R.filePath===t.id),I=h.value?.find(R=>R.file===t.id),U=x.value?.find(R=>R.file===t.id),L=t.id.includes("/node_modules/")?"lib":N?N.global?"global":"user":U?"layout":I?"page":"unknown";if(!a.value&&L==="lib"||!_.value&&L==="page"||!k.value&&L==="layout"||!S.value&&L==="user"&&i.value&&!t.id.startsWith(i.value.rootDir)||!w.value&&L==="global")return null;const q=L==="layout"?"hexagon":L==="page"?"square":"dot",y=r.value&&!t.id.toLowerCase().includes(r.value.toLowerCase());return{id:t.id,label:ae(t.id),group:L,shape:q,size:15+Math.min(t.deps.length/2,8),font:{color:y?"#8885":d.value==="dark"?"white":"black"},color:y?"#8885":f.value?.id===t.id?"#82c742":void 0,extra:{id:t.id,component:N,page:I,layout:U,relationship:t}}}).filter(t=>!!t),e=A.value.flatMap(t=>t.deps.map(N=>({from:t.id,to:N,arrows:{to:{enabled:!0,scaleFactor:.8}}})));return{nodes:new Le(V),edges:e}}),te=P(()=>s.value?.component?l.relationships?.find(e=>e.id===s.value?.component?.filePath)?.deps?.map(e=>l.relationships?.find(t=>t.id===e)?.id).filter(Boolean):[]),se=P(()=>s.value?.component?l.relationships?.filter(e=>e.deps.includes(s.value.component.filePath))?.map(e=>l.relationships?.find(t=>t.id===e.id)?.id).filter(Boolean):[]);we(()=>{const V={nodes:{shape:"dot",size:16},physics:{repulsion:{centralGravity:.7,springLength:100,springConstant:.01},maxVelocity:146,solver:"forceAtlas2Based",timestep:.35,stabilization:{enabled:!0,iterations:200}},groups:{user:{color:"#42b883"},unknown:{color:"#b86542"},lib:{color:"#b4b842"},page:{color:"#42b2b8"},layout:{color:"#4256b8"}}},e=new Be(v.value,T.value,V);e.on("click",t=>{const N=t.nodes?.[0],I=T.value.nodes.get(N).extra;s.value=I}),ke(T,()=>{e.setData(T.value)})});function le(){s.value=void 0}function ae(V){const e=l.components.find(t=>t.filePath===V);return e?e.pascalName:V.replace(/.*\/components\//,"").replace(/\.vue$/,"").replace(/\/index$/,"").split("/").map(t=>t.charAt(0).toUpperCase()+t.slice(1)).join("")}function pe(){f.value=s.value?.relationship,s.value=void 0}return(V,e)=>{const t=Pe,N=Z,I=fe,U=oe,L=X,q=Se;return o(),m(B,null,[u(N,{ref_key:"navbar",ref:p,search:C.value,"onUpdate:search":e[6]||(e[6]=y=>C.value=y),absolute:"","left-0":"","right-0":"","top-0":""},{actions:c(()=>[n("div",Ke,[u(t,{modelValue:$(_),"onUpdate:modelValue":e[0]||(e[0]=y=>z(_)?_.value=y:null),n:"primary sm"},{default:c(()=>[...e[8]||(e[8]=[n("span",{op75:""},"Show pages",-1)])]),_:1},8,["modelValue"]),u(t,{modelValue:$(k),"onUpdate:modelValue":e[1]||(e[1]=y=>z(k)?k.value=y:null),n:"primary sm"},{default:c(()=>[...e[9]||(e[9]=[n("span",{op75:""},"Show layouts",-1)])]),_:1},8,["modelValue"]),u(t,{modelValue:$(S),"onUpdate:modelValue":e[2]||(e[2]=y=>z(S)?S.value=y:null),n:"primary sm"},{default:c(()=>[...e[10]||(e[10]=[n("span",{op75:""},"Show workspace",-1)])]),_:1},8,["modelValue"]),u(t,{modelValue:$(a),"onUpdate:modelValue":e[3]||(e[3]=y=>z(a)?a.value=y:null),n:"primary sm"},{default:c(()=>[...e[11]||(e[11]=[n("span",{op75:""},"Show node_modules",-1)])]),_:1},8,["modelValue"]),u(t,{modelValue:$(w),"onUpdate:modelValue":e[4]||(e[4]=y=>z(w)?w.value=y:null),n:"primary sm"},{default:c(()=>[...e[12]||(e[12]=[n("span",{op75:""},"Show global components",-1)])]),_:1},8,["modelValue"])]),f.value?(o(),m("button",{key:0,flex:"~ gap-1","flex-none":"","items-center":"","rounded-full":"","bg-gray:20":"",py1:"",pl3:"",pr2:"","text-xs":"",op50:"","hover:op100":"",onClick:e[5]||(e[5]=y=>f.value=void 0)},[...e[13]||(e[13]=[E(" Clear filter ",-1),n("div",{"i-carbon-close":""},null,-1)])])):g("",!0),e[14]||(e[14]=n("div",{"flex-auto":""},null,-1)),j(V.$slots,"default")]),_:3},8,["search"]),n("div",Qe,[n("div",{ref_key:"container",ref:v,"h-full":"","w-full":""},null,512),u(I,{absolute:"","bottom-3":"","left-3":"","border-0":"","n-glass-effect":"",p2:"",px3:"","text-sm":""},{default:c(()=>[...e[15]||(e[15]=[n("div",{grid:"~ cols-[20px_1fr] items-center gap-y-1"},[n("div",{"h-3":"","w-3":"","rounded-full":"","bg-hex-42b883":""}),n("div",{op50:""}," Component "),n("div",{"h-3":"","w-3":"","rounded-full":"","bg-hex-97c2fc":""}),n("div",{op50:""}," Global Component "),n("div",{"h-3":"","w-3":"","bg-hex-42b2b8":""}),n("div",{op50:""}," Page "),n("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 726 628","ml--1px":"","h-3":""},[n("path",{fill:"#4256b8","stroke-width":"4",d:"M723 314 543 625.8H183L3 314 183 2.2h360L723 314z"})]),n("div",{op50:""}," Layout "),n("div",{"h-3":"","w-3":"","rounded-full":"","bg-hex-b4b842":""}),n("div",{op50:""}," Library Component "),n("div",{"h-3":"","w-3":"","rounded-full":"","bg-hex-b86542":""}),n("div",{op50:""}," Unknown ")],-1)])]),_:1}),u(q,{"model-value":!!(s.value&&s.value.component),top:p.value,border:"t l base","w-80":"",onClose:le},{default:c(()=>[s.value&&s.value.component?(o(),m("div",en,[u(U,{component:s.value.component,dependencies:te.value,dependents:se.value},null,8,["component","dependencies","dependents"]),n("div",nn,[u(L,{n:"primary solid",onClick:e[7]||(e[7]=y=>pe())},{default:c(()=>[...e[16]||(e[16]=[E(" Filter to this component ",-1)])]),_:1})])])):g("",!0)]),_:1},8,["model-value","top"])])],64)}}}),tn={hover:"bg-active",class:"group",flex:"~ gap2","w-full":"","items-center":"",rounded:"",px2:"",py1:""},sn={key:0,"ml--1":"","text-primary":""},ln=G({__name:"ComponentItem",props:{component:{},dependencies:{},dependents:{}},setup(D){const l=D,v=P(()=>l.component.filePath||l.component.file||l.component.__file||"");return(p,d)=>{const s=ne,h=oe,i=Ce("VDropdown"),x=Q,a=ee;return o(),m("div",tn,[u(i,null,{popper:c(()=>[u(h,{component:p.component,dependencies:p.dependencies,dependents:p.dependents,"w-100":"",pt3:""},null,8,["component","dependencies","dependents"])]),default:c(()=>[n("button",{"hover:text-primary":"",class:Ne(p.dependents&&p.dependents.length===0?"op50":"")},[u(s,{component:p.component},null,8,["component"])],2)]),_:1}),p.dependents?.length?(o(),m("sup",sn," x"+O(p.dependents?.length),1)):g("",!0),p.component.global?(o(),b(x,{key:1,n:"green",title:"Registered at runtime as a global component",textContent:"runtime"})):g("",!0),j(p.$slots,"default"),v.value?(o(),b(a,{key:2,filepath:v.value,"text-sm":"",op25:"","group-hover:op75":""},null,8,["filepath"])):g("",!0)])}}}),an={flex:"~ gap-2 items-center"},pn={pl4:""},rn=G({__name:"ComponentsList",props:{components:{},relationships:{}},setup(D){const l=D,v=F(""),p=F("all"),d=P(()=>{const x=l.components.map(a=>ve(a,l.relationships));return p.value==="using"?x.filter(a=>a.dependents?.length):p.value==="not-used"?x.filter(a=>!a.dependents?.length):x}),s={ClientOnly:"https://nuxt.com/docs/api/components/client-only",DevOnly:"https://nuxt.com/docs/api/components/dev-only",NuxtClientFallback:"https://nuxt.com/docs/api/components/nuxt-client-fallback",NuxtPicture:"https://nuxt.com/docs/api/components/nuxt-picture",NuxtRouteAnnouncer:"https://nuxt.com/docs/api/components/nuxt-route-announcer",NuxtTime:"https://nuxt.com/docs/api/components/nuxt-time",NuxtPage:"https://nuxt.com/docs/api/components/nuxt-page",NuxtLayout:"https://nuxt.com/docs/api/components/nuxt-layout",NuxtLink:"https://nuxt.com/docs/api/components/nuxt-link",NuxtLoadingIndicator:"https://nuxt.com/docs/api/components/nuxt-loading-indicator",NuxtErrorBoundary:"https://nuxt.com/docs/api/components/nuxt-error-boundary",NuxtWelcome:"https://nuxt.com/docs/api/components/nuxt-welcome",NuxtIsland:"https://nuxt.com/docs/api/components/nuxt-island",NuxtImg:"https://nuxt.com/docs/api/components/nuxt-img"},h=P(()=>new he(d.value,{keys:["component.pascalName","component.filePath","component.kebabName"]})),i=P(()=>{const x=[],a=new Map,w=[],_=[],k={user:0,lib:0,builtin:0,runtime:0};return(v.value?h.value.search(v.value).map(f=>f.item):d.value).forEach(f=>{const C=f.component;if(C.filePath&&_e(C.filePath)){const r=be(C.filePath);if(!r)return;r==="nuxt"?(C.meta??={},C.meta.docs??=s?.[C.pascalName],w.push(f),k.builtin++):(a.has(r)||a.set(r,[]),a.get(r).push(f),k.lib++)}else C.global&&!C.filePath?(_.push(f),k.runtime++):(x.push(f),k.user++)}),{count:k,user:x,builtin:w,lib:a,runtime:_}});return(x,a)=>{const w=ge,_=Ie,k=Z,S=ln,f=Te,C=Me;return o(),m(B,null,[u(k,{search:v.value,"onUpdate:search":a[1]||(a[1]=r=>v.value=r),pb3:""},{actions:c(()=>[j(x.$slots,"default")]),default:c(()=>[n("div",an,[u(w,{icon:"carbon-filter",op50:""}),u(_,{modelValue:p.value,"onUpdate:modelValue":a[0]||(a[0]=r=>p.value=r),n:"primary sm",options:[{label:"All",value:"all"},{label:"Using",value:"using"},{label:"Not used",value:"not-used"}]},null,8,["modelValue"])])]),_:3},8,["search"]),i.value.user.length?(o(),b(f,{key:0,icon:"carbon-nominal",text:"User components",open:i.value.user.length<=$(H),description:`Total components: ${i.value.count.user}`},{default:c(()=>[(o(!0),m(B,null,M(i.value.user,r=>(o(),b(S,W({key:r.component.filePath},{ref_for:!0},r),null,16))),128))]),_:1},8,["open","description"])):g("",!0),i.value.runtime.length?(o(),b(f,{key:1,icon:"carbon-load-balancer-global",open:i.value.runtime.length<=$(H),text:"Runtime components",description:`Total components: ${i.value.count.runtime}`},{default:c(()=>[(o(!0),m(B,null,M(i.value.runtime,r=>(o(),b(S,W({key:r.component.filePath},{ref_for:!0},r),null,16))),128))]),_:1},8,["open","description"])):g("",!0),i.value.builtin.length?(o(),b(f,{key:2,icon:"simple-icons-nuxtdotjs",text:"Built-in components",description:`Total components: ${i.value.count.builtin}`},{default:c(()=>[(o(!0),m(B,null,M(i.value.builtin,r=>(o(),b(S,W({key:r.component.filePath},{ref_for:!0},r),null,16))),128))]),_:1},8,["description"])):g("",!0),i.value.lib.size?(o(),b(f,{key:3,open:i.value.count.lib<=$(H),icon:"carbon-3d-mpr-toggle",text:"Components from libraries",description:`${i.value.count.lib} components from ${i.value.lib.size} packages`},{default:c(()=>[(o(!0),m(B,null,M(i.value.lib.entries(),([r,A])=>(o(),m("div",{key:r,"ml-2":""},[u(C,{text:`${r} (${A.length})`,py1:"",op50:""},null,8,["text"]),n("div",pn,[(o(!0),m(B,null,M(A,T=>(o(),b(S,W({key:T.component.filePath},{ref_for:!0},T),null,16))),128))])]))),128))]),_:1},8,["open","description"])):g("",!0)],64)}}}),un={relative:"","h-full":"","of-auto":""},mn={"flex-none":"",flex:"~ gap3"},Pn=G({__name:"components",setup(D){const l=xe(),v=Ue(),p=Fe(),{componentsView:d}=J("ui");function s(){l.value?.inspector?.enable()}function h(){d.value=d.value==="list"?"graph":"list"}return(i,x)=>{const a=X,w=Ae,_=De,k=$e("tooltip");return o(),m(B,null,[n("div",un,[(o(),b(Ve($(d)==="list"?rn:on),{components:$(v),relationships:$(p)},{default:c(()=>[n("div",mn,[Y(u(a,{"text-lg":"",border:!1,icon:$(d)==="graph"?"i-carbon-list":"i-carbon-network-4",title:"Toggle view",onClick:h},null,8,["icon"]),[[k,"Toggle View",void 0,{"bottom-end":!0}]]),$(l)?.inspector?.isAvailable?Y((o(),b(a,{key:0,"text-lg":"",border:!1,icon:"i-tabler-focus-2",title:"Inspect Vue components",onClick:s},null,512)),[[k,"Inspect Vue components",void 0,{"bottom-end":!0}]]):g("",!0)])]),_:1},8,["components","relationships"]))]),u(_,null,{default:c(()=>[u(w)]),_:1})],64)}}});export{Pn as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a4 as M,ba as j,bb as E,bc as N,a6 as V,l as B,ag as k,bd as D,r as I,n as L,j as P,aa as W}from"#entry";import{p as $,k as C,q as x,r as O,E as q,z as R,w as _,M as S,J as U,$ as n,U as u,V as y,a0 as r,ab as w,a8 as A,u as T,af as F,X}from"./vendor/json-editor-vue-gd4lkf0o.js";import{_ as z}from"./launch-page.vue-mubr1qiq.js";import"./vendor/shiki-jxvjmls6.js";import"./vendor/unocss-
|
|
1
|
+
import{a4 as M,ba as j,bb as E,bc as N,a6 as V,l as B,ag as k,bd as D,r as I,n as L,j as P,aa as W}from"#entry";import{p as $,k as C,q as x,r as O,E as q,z as R,w as _,M as S,J as U,$ as n,U as u,V as y,a0 as r,ab as w,a8 as A,u as T,af as F,X}from"./vendor/json-editor-vue-gd4lkf0o.js";import{_ as z}from"./launch-page.vue-mubr1qiq.js";import"./vendor/shiki-jxvjmls6.js";import"./vendor/unocss-la8bop5t.js";import"./nmarkdown.vue-ho3nn7tc.js";import"./client-kvgyopwa.js";const h=new Map,G=$({__name:"IframeView",props:{tab:{}},setup(f){const m=f,c=M(),d=C(),s=x(()=>m.tab.name),e=C(),t=O(j(d));q(()=>{const o=m.tab.view,l=o.persistent!==!1,b=["clipboard-write","clipboard-read"];if(h.get(s.value)&&l)e.value=h.get(s.value),e.value.style.visibility="visible";else{e.value=document.createElement("iframe"),e.value.setAttribute("allow",b.join("; ")),e.value.setAttribute("aria-label","Nuxt Devtools"),l&&h.set(s.value,e.value),e.value.src=o.src;try{e.value.style.opacity="0.01",e.value.onload=()=>{v(),i(),e.value.style.opacity="1"}}catch{e.value.style.opacity="1"}document.body.appendChild(e.value),R(p)}setTimeout(i,100)}),_(p),_(i),_(v),S(()=>{e.value&&(e.value.style.visibility="hidden")});function i(){if(!(!e.value||!e.value.contentWindow))try{const o=e.value.contentWindow.document.querySelector("html");o?.classList.toggle("dark",c.value==="dark"),o?.classList.toggle("light",c.value==="dark"),new MutationObserver(()=>{c.value=e.value?.contentWindow?.document.querySelector("html")?.classList.contains("dark")?"dark":"light"}).observe(o,{attributes:!0,attributeFilter:["class"]})}catch{}}const a=E();function v(){if(!(!e.value||!e.value.contentWindow))try{e.value.contentWindow.__NUXT_DEVTOOLS__=a.value}catch{}}function p(){e.value&&Object.assign(e.value.style,{position:"fixed",left:`${t.left}px`,top:`${t.top}px`,width:`${t.width}px`,height:`${t.height}px`,outline:"none"})}return(o,l)=>(n(),U("div",{ref_key:"anchor",ref:d,"h-full":"","w-full":""},null,512))}}),J={flex:"~ col gap2",mxa:"","items-center":""},H={"text-xl":""},K={"text-rose":""},ne=$({__name:"custom-[name]",props:{name:{}},setup(f){const m=f,c=N(),d=V(),s=x(()=>m.name??c.params.name),e=B(),t=x(()=>e.value.find(i=>i.name===s.value));return q(()=>{t.value?t.value.requireAuth&&!k.value&&D():setTimeout(()=>{t.value||d.push("/modules/overview")},2e3)}),(i,a)=>{const v=P,p=W,o=G,l=z,b=L;return t.value?t.value.requireAuth&&!T(k)?(n(),u(p,{key:1})):t.value.view.type==="iframe"?(n(),u(o,{key:2,tab:t.value},null,8,["tab"])):t.value.view.type==="vnode"?(n(),u(F(t.value.view.vnode),{key:3})):t.value.view.type==="launch"?(n(),u(l,{key:4,name:`custom-${t.value.name}`,icon:t.value.view.icon||t.value.icon,title:t.value.view.title||t.value.title,description:t.value.view.description,actions:t.value.view.actions,onAction:a[0]||(a[0]=g=>T(I).customTabAction(t.value.name,g))},null,8,["name","icon","title","description","actions"])):(n(),u(v,{key:5},{default:y(()=>[X(b,{flex:"~ col","h-full":"","items-center":"","justify-center":""},{default:y(()=>[w(" Unknown tab type "+A(t.value.view),1)]),_:1})]),_:1})):(n(),u(v,{key:0},{default:y(()=>[r("div",J,[a[3]||(a[3]=r("div",{"i-carbon-queued":"",mb2:"","text-5xl":"",op50:""},null,-1)),r("p",H,[a[1]||(a[1]=w(" Tab ",-1)),r("code",K,A(s.value),1),a[2]||(a[2]=w(" not found ",-1))]),a[4]||(a[4]=r("p",{op50:""}," It might because the module contributing this tab is not installed or enabled ",-1)),a[5]||(a[5]=r("p",{mt8:"","animate-pulse":""}," Redirecting to overview page... ",-1))])]),_:1}))}}});export{ne as default};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{_ as A}from"./nselect.vue-j457efs9.js";import{u as E,c as F,a as W,_ as q}from"#entry";import{_ as z}from"./nswitch.vue-m7rzt1v6.js";import{_ as J}from"./ndropdown.vue-mt2skirs.js";import{_ as O}from"./ncode-block.vue-nph7f5ph.js";import{_ as X}from"./ndrawer.vue-bscihm5p.js";import{A as h,d as x}from"./vendor/quicktype-core-jxekulwx.js";import{p as G,k,q as N,x as C,U as c,a1 as m,$ as n,X as d,V as r,a0 as i,J as f,F as D,ag as $,u as _,a8 as V,ae as H}from"./vendor/json-editor-vue-gd4lkf0o.js";import"./vendor/shiki-jxvjmls6.js";import"./vendor/unocss-
|
|
1
|
+
import{_ as A}from"./nselect.vue-j457efs9.js";import{u as E,c as F,a as W,_ as q}from"#entry";import{_ as z}from"./nswitch.vue-m7rzt1v6.js";import{_ as J}from"./ndropdown.vue-mt2skirs.js";import{_ as O}from"./ncode-block.vue-nph7f5ph.js";import{_ as X}from"./ndrawer.vue-bscihm5p.js";import{A as h,d as x}from"./vendor/quicktype-core-jxekulwx.js";import{p as G,k,q as N,x as C,U as c,a1 as m,$ as n,X as d,V as r,a0 as i,J as f,F as D,ag as $,u as _,a8 as V,ae as H}from"./vendor/json-editor-vue-gd4lkf0o.js";import"./vendor/shiki-jxvjmls6.js";import"./vendor/unocss-la8bop5t.js";import"./client-kvgyopwa.js";const K={border:"b base",flex:"~ items-center gap-2",sticky:"","left-0":"","right-0":"","top-0":"","z-1":"","bg-base":"",p3:""},M={key:0,flex:"~ items-center justify-center",absolute:"","bottom--1":"","right--2":"","h-4":"","w-4":"","rounded-full":"","bg-lime:30":"","text-8px":""},P={flex:"~ col","w-100":"","of-auto":"",py2:""},Q={"text-xs":"",capitalize:"",op75:""},ie=G({__name:"DataSchemaDrawer",setup(R){const s=E(),b=k(0),l=k("TypeScript"),v=N(()=>h.all.find(e=>e.displayName===l.value)),o=k(v.value?.optionDefinitions.filter(e=>typeof e.defaultValue=="boolean")),y=F(async()=>{if(b.value,!s.value)return"";const e=x.jsonInputForTargetLanguage(l.value);await e.addSource({name:s.value.name??"Data",samples:[s.value.input]});const t=new x.InputData;return t.addInput(e),(await x.quicktype({inputData:t,lang:l.value,rendererOptions:o.value?.reduce((u,p)=>(u[p.name]=p.defaultValue,u),{})})).lines.join(`
|
|
2
2
|
`)}),j=N(()=>{const e=l.value.toLocaleLowerCase();return e.startsWith("javascript")?"javascript":e.startsWith("json")?"json":e.startsWith("typescript")?"typescript":e});C(o,()=>{b.value++},{deep:!0}),C(l,()=>{o.value=v.value?.optionDefinitions.filter(e=>typeof e.defaultValue=="boolean")});const S=W();function B(){S(y.value||"")}return(e,t)=>{const w=A,u=q,p=z,L=J,I=O,T=X;return v.value?(n(),c(H,{key:0,to:"body"},[d(T,{"model-value":!!_(s)?.input,"auto-close":"","max-w-screen":"","w-2xl":"","n-code-block":"",onClose:t[2]||(t[2]=a=>s.value=null)},{default:r(()=>[i("div",K,[t[3]||(t[3]=i("p",{"mr-2":""}," Schema ",-1)),d(w,{modelValue:l.value,"onUpdate:modelValue":t[0]||(t[0]=a=>l.value=a),n:"xs primary"},{default:r(()=>[(n(!0),f(D,null,$(_(h.all),a=>(n(),f("option",{key:a.displayName},V(a.displayName),1))),128))]),_:1},8,["modelValue"]),o.value?.length?(n(),c(L,{key:0,n:"sm lime"},{trigger:r(({click:a})=>[d(u,{icon:"carbon-settings","h-full":"",onClick:g=>a()},null,8,["onClick"]),o.value?(n(),f("span",M,V(o.value.length),1)):m("",!0)]),default:r(()=>[i("div",P,[(n(!0),f(D,null,$(o.value,(a,g)=>(n(),c(p,{key:a.name,modelValue:o.value[g].defaultValue,"onUpdate:modelValue":U=>o.value[g].defaultValue=U,flex:"~ gap-2",rounded:"",px2:"",py2:""},{default:r(()=>[i("span",Q,V(a.description),1)]),_:2},1032,["modelValue","onUpdate:modelValue"]))),128))])]),_:1})):m("",!0),t[4]||(t[4]=i("div",{"flex-auto":""},null,-1)),d(u,{icon:"carbon-copy","mr-6":"","h-full":"",onClick:t[1]||(t[1]=a=>B())})]),_(y)?(n(),c(I,{key:0,lang:j.value,code:_(y)},null,8,["lang","code"])):m("",!0)]),_:1},8,["model-value"])])):m("",!0)}}});export{ie as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{_ as D}from"./nsection-block-b1meb1ma.js";import{_ as H}from"./ncheckbox.vue-cowm3nmm.js";import{g as M}from"./color-mt9xuhgy.js";import{_ as I}from"./nbadge-hbh0pw7g.js";import{p as V,q as R,U as y,$ as l,V as d,ab as P,W as j,a8 as k,a2 as z,k as p,J as u,F as x,a0 as t,X as s,a1 as $,ag as B,a4 as E,u as N}from"./vendor/json-editor-vue-gd4lkf0o.js";import{_ as W,p as O}from"#entry";import{_ as q}from"./filepath-item.vue-e693vfym.js";import{_ as J}from"./ncode-block.vue-nph7f5ph.js";import"./nicon-title.vue-l5va2e26.js";import"./vendor/shiki-jxvjmls6.js";import"./vendor/unocss-
|
|
1
|
+
import{_ as D}from"./nsection-block-b1meb1ma.js";import{_ as H}from"./ncheckbox.vue-cowm3nmm.js";import{g as M}from"./color-mt9xuhgy.js";import{_ as I}from"./nbadge-hbh0pw7g.js";import{p as V,q as R,U as y,$ as l,V as d,ab as P,W as j,a8 as k,a2 as z,k as p,J as u,F as x,a0 as t,X as s,a1 as $,ag as B,a4 as E,u as N}from"./vendor/json-editor-vue-gd4lkf0o.js";import{_ as W,p as O}from"#entry";import{_ as q}from"./filepath-item.vue-e693vfym.js";import{_ as J}from"./ncode-block.vue-nph7f5ph.js";import"./nicon-title.vue-l5va2e26.js";import"./vendor/shiki-jxvjmls6.js";import"./vendor/unocss-la8bop5t.js";import"./client-kvgyopwa.js";const K=V({__name:"NBadgeHashed",props:{text:{}},setup(_){const i=_,c=R(()=>{const a=M(i.text,50,60),r=M(i.text,50,60,.05);return{color:a,background:r}});return(a,r)=>(l(),y(I,{style:z(c.value)},{default:d(()=>[P(k(a.text),1),j(a.$slots,"default")]),_:3},8,["style"]))}}),L={flex:"~ gap-2 col",mb4:""},X={flex:"~ gap-3 items-center"},A={key:0,flex:"~ gap-1","items-center":"",p1:"",border:"~ base rounded"},G={"max-w-full":"","of-auto":""},Q={"text-center":"",op50:""},Y={flex:"~",px4:""},Z={key:0,op50:""},ee={px2:"","text-center":""},te={"of-auto":""},oe=V({__name:"DebugModuleMutationRecords",props:{moduleMutationRecords:{}},setup(_){const i=_;function c(n){return n.startsWith("/")||n.match(/^[a-z]:[\\/]/i)}const a=p(!1),r=p(!1),v=p(!1),b=p(!1),w=p(!1),m=p(""),S=R(()=>{let n=i.moduleMutationRecords;return a.value||(n=n.filter(e=>!e.name.startsWith("nuxt:")&&e.name!=="@nuxt/devtools")),r.value||(n=n.filter(e=>e.keys.join(".")!=="build.templates")),v.value||(n=n.filter(e=>e.keys.join(".")!=="build.transpile")),b.value||(n=n.filter(e=>e.keys.join(".")!=="plugins")),w.value||(n=n.filter(e=>e.method||e.value!=="[]"&&e.value!=="{}")),m.value&&(n=n.filter(e=>e.name===m.value)),n});return(n,e)=>{const f=H,g=K,F=W,U=q,T=J;return l(),u(x,null,[t("div",L,[t("div",X,[s(f,{modelValue:a.value,"onUpdate:modelValue":e[0]||(e[0]=o=>a.value=o),n:"primary"},{default:d(()=>[...e[6]||(e[6]=[t("span",{"ws-nowrap":"",op75:""},"Builtin Modules",-1)])]),_:1},8,["modelValue"]),s(f,{modelValue:r.value,"onUpdate:modelValue":e[1]||(e[1]=o=>r.value=o),n:"primary"},{default:d(()=>[...e[7]||(e[7]=[t("span",{"ws-nowrap":"",op75:""},"Templates",-1)])]),_:1},8,["modelValue"]),s(f,{modelValue:v.value,"onUpdate:modelValue":e[2]||(e[2]=o=>v.value=o),n:"primary"},{default:d(()=>[...e[8]||(e[8]=[t("span",{"ws-nowrap":"",op75:""},"Transpile",-1)])]),_:1},8,["modelValue"]),s(f,{modelValue:b.value,"onUpdate:modelValue":e[3]||(e[3]=o=>b.value=o),n:"primary"},{default:d(()=>[...e[9]||(e[9]=[t("span",{"ws-nowrap":"",op75:""},"Plugins",-1)])]),_:1},8,["modelValue"]),s(f,{modelValue:w.value,"onUpdate:modelValue":e[4]||(e[4]=o=>w.value=o),n:"primary"},{default:d(()=>[...e[10]||(e[10]=[t("span",{"ws-nowrap":"",op75:""},"Empty Initial",-1)])]),_:1},8,["modelValue"]),m.value?(l(),u("div",A,[s(g,{"font-mono":"",text:m.value},null,8,["text"]),s(F,{icon:"carbon-close",border:!1,onClick:e[5]||(e[5]=o=>m.value="")})])):$("",!0)])]),t("table",G,[e[11]||(e[11]=t("thead",{border:"b base"},[t("tr",null,[t("th",{"ws-nowrap":"",p1:"","text-center":"","font-bold":""}," Index "),t("th",{"ws-nowrap":"",p1:"","text-center":"","font-bold":""}," Module "),t("th",{"ws-nowrap":"",p1:"","text-center":"","font-bold":""}," Key Path "),t("th",{"ws-nowrap":"",p1:"","text-center":"","font-bold":""}," Method "),t("th",{"ws-nowrap":"",p1:"","text-center":"","font-bold":""}," Value ")])],-1)),t("tbody",null,[(l(!0),u(x,null,B(S.value,o=>(l(),u("tr",{key:n.moduleMutationRecords.indexOf(o),border:"b dashed transparent hover:base"},[t("td",Q,[t("div",null,k(n.moduleMutationRecords.indexOf(o)+1),1)]),t("td",null,[o.name&&c(o.name)?(l(),y(U,{key:0,filepath:o.name},null,8,["filepath"])):(l(),y(g,{key:1,role:"button","font-mono":"",text:o.name,onClick:h=>m.value=o.name},null,8,["text","onClick"]))]),t("td",null,[t("code",Y,[(l(!0),u(x,null,B(o.keys,(h,C)=>(l(),u(x,{key:C},[t("span",null,k(h),1),C<o.keys.length-1?(l(),u("span",Z," . ")):$("",!0)],64))),128))])]),t("td",ee,[s(g,{"font-mono":"",text:o.method||"=",class:E(o.method?"":"saturate-0")},null,8,["text","class"])]),t("td",te,[s(T,{code:String(o.value),lang:"ts","grammar-context-code":"let a = ","ws-normal":"","break-all":"",py1:"",lines:!1,inline:!0},null,8,["code"])])]))),128))])])],64)}}}),ne={key:0,p6:""},le={key:1},ve=V({__name:"debug",setup(_){const i=O();return(c,a)=>{const r=D;return N(i)?(l(),u("div",le,[s(r,{icon:"carbon-container-image-push-pull",text:"Module Mutation Records",description:"Records of module mutations to nuxt options"},{default:d(()=>[s(oe,{"module-mutation-records":N(i).moduleMutationRecords||[]},null,8,["module-mutation-records"])]),_:1})])):(l(),u("div",ne,[...a[0]||(a[0]=[t("div",null,"No Debug Context Found",-1),t("div",null,"Set `debug: true` in your nuxt.config.ts to enable this panel",-1)])]))}}});export{ve as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{b as o}from"#entry";import{J as t,$ as s,a0 as r,W as a}from"./vendor/json-editor-vue-gd4lkf0o.js";import"./vendor/shiki-jxvjmls6.js";import"./vendor/unocss-
|
|
1
|
+
import{b as o}from"#entry";import{J as t,$ as s,a0 as r,W as a}from"./vendor/json-editor-vue-gd4lkf0o.js";import"./vendor/shiki-jxvjmls6.js";import"./vendor/unocss-la8bop5t.js";const n={},c={"h-full":"","of-auto":"","n-panel-grids":""},l={"h-full":"","bg-base":""};function d(e,f){return s(),t("div",c,[r("div",l,[a(e.$slots,"default")])])}const u=o(n,[["render",d]]);export{u as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{b as a,d as i,e as u}from"#entry";import{J as c,$ as l,a0 as e,a8 as r,X as d,V as p,ab as f}from"./vendor/json-editor-vue-gd4lkf0o.js";import"./vendor/shiki-jxvjmls6.js";import"./vendor/unocss-
|
|
1
|
+
import{b as a,d as i,e as u}from"#entry";import{J as c,$ as l,a0 as e,a8 as r,X as d,V as p,ab as f}from"./vendor/json-editor-vue-gd4lkf0o.js";import"./vendor/shiki-jxvjmls6.js";import"./vendor/unocss-la8bop5t.js";const m={class:"antialiased bg-white dark:bg-black dark:text-white font-sans grid min-h-screen overflow-hidden place-content-center text-black"},g={class:"max-w-520px text-center z-20"},b=["textContent"],h=["textContent"],x={class:"flex items-center justify-center w-full"},y={__name:"error-404",props:{appName:{type:String,default:"Nuxt"},version:{type:String,default:""},statusCode:{type:Number,default:404},statusMessage:{type:String,default:"Not Found"},description:{type:String,default:"Sorry, the page you are looking for could not be found."},backHome:{type:String,default:"Go back home"}},setup(t){const n=t;return i({title:`${n.statusCode} - ${n.statusMessage} | ${n.appName}`,script:[{innerHTML:`!function(){const e=document.createElement("link").relList;if(!(e&&e.supports&&e.supports("modulepreload"))){for(const e of document.querySelectorAll('link[rel="modulepreload"]'))r(e);new MutationObserver((e=>{for(const o of e)if("childList"===o.type)for(const e of o.addedNodes)"LINK"===e.tagName&&"modulepreload"===e.rel&&r(e)})).observe(document,{childList:!0,subtree:!0})}function r(e){if(e.ep)return;e.ep=!0;const r=function(e){const r={};return e.integrity&&(r.integrity=e.integrity),e.referrerPolicy&&(r.referrerPolicy=e.referrerPolicy),"use-credentials"===e.crossOrigin?r.credentials="include":"anonymous"===e.crossOrigin?r.credentials="omit":r.credentials="same-origin",r}(e);fetch(e.href,r)}}();`}],style:[{innerHTML:'*,:after,:before{border-color:var(--un-default-border-color,#e5e7eb);border-style:solid;border-width:0;box-sizing:border-box}:after,:before{--un-content:""}html{line-height:1.5;-webkit-text-size-adjust:100%;font-family:ui-sans-serif,system-ui,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;font-feature-settings:normal;font-variation-settings:normal;-moz-tab-size:4;tab-size:4;-webkit-tap-highlight-color:transparent}body{line-height:inherit;margin:0}h1{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}h1,p{margin:0}*,:after,:before{--un-rotate:0;--un-rotate-x:0;--un-rotate-y:0;--un-rotate-z:0;--un-scale-x:1;--un-scale-y:1;--un-scale-z:1;--un-skew-x:0;--un-skew-y:0;--un-translate-x:0;--un-translate-y:0;--un-translate-z:0;--un-pan-x: ;--un-pan-y: ;--un-pinch-zoom: ;--un-scroll-snap-strictness:proximity;--un-ordinal: ;--un-slashed-zero: ;--un-numeric-figure: ;--un-numeric-spacing: ;--un-numeric-fraction: ;--un-border-spacing-x:0;--un-border-spacing-y:0;--un-ring-offset-shadow:0 0 transparent;--un-ring-shadow:0 0 transparent;--un-shadow-inset: ;--un-shadow:0 0 transparent;--un-ring-inset: ;--un-ring-offset-width:0px;--un-ring-offset-color:#fff;--un-ring-width:0px;--un-ring-color:rgba(147,197,253,.5);--un-blur: ;--un-brightness: ;--un-contrast: ;--un-drop-shadow: ;--un-grayscale: ;--un-hue-rotate: ;--un-invert: ;--un-saturate: ;--un-sepia: ;--un-backdrop-blur: ;--un-backdrop-brightness: ;--un-backdrop-contrast: ;--un-backdrop-grayscale: ;--un-backdrop-hue-rotate: ;--un-backdrop-invert: ;--un-backdrop-opacity: ;--un-backdrop-saturate: ;--un-backdrop-sepia: }'}]}),(k,o)=>{const s=u;return l(),c("div",m,[o[0]||(o[0]=e("div",{class:"fixed left-0 right-0 spotlight z-10"},null,-1)),e("div",g,[e("h1",{class:"font-medium mb-8 sm:text-10xl text-8xl",textContent:r(t.statusCode)},null,8,b),e("p",{class:"font-light leading-tight mb-16 px-8 sm:px-0 sm:text-4xl text-xl",textContent:r(t.description)},null,8,h),e("div",x,[d(s,{to:"/",class:"cursor-pointer gradient-border px-4 py-2 sm:px-6 sm:py-3 sm:text-xl text-md"},{default:p(()=>[f(r(t.backHome),1)]),_:1})])])])}}},N=a(y,[["__scopeId","data-v-f5f8c093"]]);export{N as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{b as s,d as a}from"#entry";import{J as i,$ as u,a0 as e,a8 as o}from"./vendor/json-editor-vue-gd4lkf0o.js";import"./vendor/shiki-jxvjmls6.js";import"./vendor/unocss-
|
|
1
|
+
import{b as s,d as a}from"#entry";import{J as i,$ as u,a0 as e,a8 as o}from"./vendor/json-editor-vue-gd4lkf0o.js";import"./vendor/shiki-jxvjmls6.js";import"./vendor/unocss-la8bop5t.js";const l={class:"antialiased bg-white dark:bg-black dark:text-white font-sans grid min-h-screen overflow-hidden place-content-center text-black"},c={class:"max-w-520px text-center"},d=["textContent"],p=["textContent"],f={__name:"error-500",props:{appName:{type:String,default:"Nuxt"},version:{type:String,default:""},statusCode:{type:Number,default:500},statusMessage:{type:String,default:"Server error"},description:{type:String,default:"This page is temporarily unavailable."}},setup(t){const r=t;return a({title:`${r.statusCode} - ${r.statusMessage} | ${r.appName}`,script:[{innerHTML:`!function(){const e=document.createElement("link").relList;if(!(e&&e.supports&&e.supports("modulepreload"))){for(const e of document.querySelectorAll('link[rel="modulepreload"]'))r(e);new MutationObserver((e=>{for(const o of e)if("childList"===o.type)for(const e of o.addedNodes)"LINK"===e.tagName&&"modulepreload"===e.rel&&r(e)})).observe(document,{childList:!0,subtree:!0})}function r(e){if(e.ep)return;e.ep=!0;const r=function(e){const r={};return e.integrity&&(r.integrity=e.integrity),e.referrerPolicy&&(r.referrerPolicy=e.referrerPolicy),"use-credentials"===e.crossOrigin?r.credentials="include":"anonymous"===e.crossOrigin?r.credentials="omit":r.credentials="same-origin",r}(e);fetch(e.href,r)}}();`}],style:[{innerHTML:'*,:after,:before{border-color:var(--un-default-border-color,#e5e7eb);border-style:solid;border-width:0;box-sizing:border-box}:after,:before{--un-content:""}html{line-height:1.5;-webkit-text-size-adjust:100%;font-family:ui-sans-serif,system-ui,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;font-feature-settings:normal;font-variation-settings:normal;-moz-tab-size:4;tab-size:4;-webkit-tap-highlight-color:transparent}body{line-height:inherit;margin:0}h1{font-size:inherit;font-weight:inherit}h1,p{margin:0}*,:after,:before{--un-rotate:0;--un-rotate-x:0;--un-rotate-y:0;--un-rotate-z:0;--un-scale-x:1;--un-scale-y:1;--un-scale-z:1;--un-skew-x:0;--un-skew-y:0;--un-translate-x:0;--un-translate-y:0;--un-translate-z:0;--un-pan-x: ;--un-pan-y: ;--un-pinch-zoom: ;--un-scroll-snap-strictness:proximity;--un-ordinal: ;--un-slashed-zero: ;--un-numeric-figure: ;--un-numeric-spacing: ;--un-numeric-fraction: ;--un-border-spacing-x:0;--un-border-spacing-y:0;--un-ring-offset-shadow:0 0 transparent;--un-ring-shadow:0 0 transparent;--un-shadow-inset: ;--un-shadow:0 0 transparent;--un-ring-inset: ;--un-ring-offset-width:0px;--un-ring-offset-color:#fff;--un-ring-width:0px;--un-ring-color:rgba(147,197,253,.5);--un-blur: ;--un-brightness: ;--un-contrast: ;--un-drop-shadow: ;--un-grayscale: ;--un-hue-rotate: ;--un-invert: ;--un-saturate: ;--un-sepia: ;--un-backdrop-blur: ;--un-backdrop-brightness: ;--un-backdrop-contrast: ;--un-backdrop-grayscale: ;--un-backdrop-hue-rotate: ;--un-backdrop-invert: ;--un-backdrop-opacity: ;--un-backdrop-saturate: ;--un-backdrop-sepia: }'}]}),(g,n)=>(u(),i("div",l,[n[0]||(n[0]=e("div",{class:"-bottom-1/2 fixed h-1/2 left-0 right-0 spotlight"},null,-1)),e("div",c,[e("h1",{class:"font-medium mb-8 sm:text-10xl text-8xl",textContent:o(t.statusCode)},null,8,d),e("p",{class:"font-light leading-tight mb-16 px-8 sm:px-0 sm:text-4xl text-xl",textContent:o(t.description)},null,8,p)])]))}},y=s(f,[["__scopeId","data-v-0818c0bd"]]);export{y as default};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{f as E,q as x}from"#entry";import{_ as N}from"./stacktrace-list.vue-nfhbrir6.js";import{p as y,q as v,J as l,$ as i,X as C,a0 as f,a1 as _,V as w,ab as S,a8 as p,U as $}from"./vendor/json-editor-vue-gd4lkf0o.js";import"./vendor/shiki-jxvjmls6.js";import"./vendor/unocss-
|
|
1
|
+
import{f as E,q as x}from"#entry";import{_ as N}from"./stacktrace-list.vue-nfhbrir6.js";import{p as y,q as v,J as l,$ as i,X as C,a0 as f,a1 as _,V as w,ab as S,a8 as p,U as $}from"./vendor/json-editor-vue-gd4lkf0o.js";import"./vendor/shiki-jxvjmls6.js";import"./vendor/unocss-la8bop5t.js";import"./filepath-item.vue-e693vfym.js";const O=/(^|@)\S+:\d+/,h=/^\s*at .*(\S+:\d+|\(native\))/m,R=/^(eval@)?(\[native code\])?$/;function b(e,a){if(typeof e.stacktrace<"u"||typeof e["opera#sourceloc"]<"u")return T(e);if(e.stack&&e.stack.match(h))return F(e);if(e.stack)return V(e);throw new Error("Cannot parse given Error object")}function m(e){if(!e.includes(":"))return[e,void 0,void 0];const o=/(.+?)(?::(\d+))?(?::(\d+))?$/.exec(e.replace(/[()]/g,""));return[o[1],o[2]||void 0,o[3]||void 0]}function d(e,a){return e}function F(e,a){return I(e.stack)}function I(e,a){return d(e.split(`
|
|
2
2
|
`).filter(t=>!!t.match(h))).map(t=>{t.includes("(eval ")&&(t=t.replace(/eval code/g,"eval").replace(/(\(eval at [^()]*)|(,.*$)/g,""));let r=t.replace(/^\s+/,"").replace(/\(eval code/g,"(").replace(/^.*?\s+/,"");const n=r.match(/ (\(.+\)$)/);r=n?r.replace(n[0],""):r;const c=m(n?n[1]:r),s=n&&r||void 0,u=["eval","<anonymous>"].includes(c[0])?void 0:c[0];return{function:s,file:u,line:c[1]?+c[1]:void 0,col:c[2]?+c[2]:void 0,raw:t}})}function V(e,a){return A(e.stack)}function A(e,a){return d(e.split(`
|
|
3
3
|
`).filter(t=>!t.match(R))).map(t=>{if(t.includes(" > eval")&&(t=t.replace(/ line (\d+)(?: > eval line \d+)* > eval:\d+:\d+/g,":$1")),!t.includes("@")&&!t.includes(":"))return{function:t};{const r=/(([^\n\r"\u2028\u2029]*".[^\n\r"\u2028\u2029]*"[^\n\r@\u2028\u2029]*(?:@[^\n\r"\u2028\u2029]*"[^\n\r@\u2028\u2029]*)*(?:[\n\r\u2028\u2029][^@]*)?)?[^@]*)@/,n=t.match(r),c=n&&n[1]?n[1]:void 0,s=m(t.replace(r,""));return{function:c,file:s[0],line:s[1]?+s[1]:void 0,col:s[2]?+s[2]:void 0,raw:t}}})}function T(e,a){return!e.stacktrace||e.message.includes(`
|
|
4
4
|
`)&&e.message.split(`
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{b as t}from"#entry";import{J as e,$ as r,W as s}from"./vendor/json-editor-vue-gd4lkf0o.js";import"./vendor/shiki-jxvjmls6.js";import"./vendor/unocss-
|
|
1
|
+
import{b as t}from"#entry";import{J as e,$ as r,W as s}from"./vendor/json-editor-vue-gd4lkf0o.js";import"./vendor/shiki-jxvjmls6.js";import"./vendor/unocss-la8bop5t.js";const c={},n={"h-full":"","of-auto":""};function a(o,f){return r(),e("div",n,[s(o.$slots,"default")])}const d=t(c,[["render",a]]);export{d as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{_ as S}from"./duration-display.vue-juecltgn.js";import{g as T}from"./color-mt9xuhgy.js";import{p as $,k as H,q as w,J as h,$ as u,a0 as o,ab as l,a4 as p,F as y,ag as F,a8 as m,a2 as V,u as k,X as _,U as C,a1 as N,V as f}from"./vendor/json-editor-vue-gd4lkf0o.js";import{_ as B}from"./nsection-block-b1meb1ma.js";import{_ as D}from"./help-fab.vue-le7iybnb.js";import{s as P,f as E}from"#entry";import"./nicon-title.vue-l5va2e26.js";import"./vendor/shiki-jxvjmls6.js";import"./vendor/unocss-
|
|
1
|
+
import{_ as S}from"./duration-display.vue-juecltgn.js";import{g as T}from"./color-mt9xuhgy.js";import{p as $,k as H,q as w,J as h,$ as u,a0 as o,ab as l,a4 as p,F as y,ag as F,a8 as m,a2 as V,u as k,X as _,U as C,a1 as N,V as f}from"./vendor/json-editor-vue-gd4lkf0o.js";import{_ as B}from"./nsection-block-b1meb1ma.js";import{_ as D}from"./help-fab.vue-le7iybnb.js";import{s as P,f as E}from"#entry";import"./nicon-title.vue-l5va2e26.js";import"./vendor/shiki-jxvjmls6.js";import"./vendor/unocss-la8bop5t.js";const O={"w-full":""},j={border:"b base"},L={"select-none":"","ws-nowrap":"",p1:"","text-right":"","font-bold":""},z={colspan:"2",p1:"",pl5:"","text-left":"","font-bold":""},A={"ws-nowrap":"",p1:"","text-center":"","font-bold":""},U={"ws-nowrap":"",p1:"","text-center":"","font-bold":""},Y={"ws-nowrap":"",p1:"","text-right":"","font-bold":""},q={"w-0":"","ws-nowrap":"","text-center":"","text-sm":"",op25:""},J={"text-sm":""},R={"ws-nowrap":""},X={"text-sm":""},G={"w-0":"","text-center":"","text-sm":""},K={"w-0":"","text-center":"","text-sm":""},M={"w-0":"","text-right":"","text-sm":""},Q=$({__name:"HooksTable",props:{hooks:{}},setup(x){const a=x,r=H("duration"),n=H("asc"),d={duration:(e,t)=>(t.duration??Number.POSITIVE_INFINITY)-(e.duration??Number.POSITIVE_INFINITY),name:(e,t)=>e.name.localeCompare(t.name),listener:(e,t)=>t.listeners-e.listeners,start:(e,t)=>t.start-e.start,executions:(e,t)=>t.executions.length-e.executions.length},g=w(()=>a.hooks.map(e=>e.start).sort((e,t)=>e-t)),b=w(()=>{const e=d[r.value],t=[...a.hooks].sort(e);return n.value==="desc"&&t.reverse(),t});function c(e){const t=e.split(":");return t.length===1?"":`${t[0]}:`}function v(e){const t=e.split(":");return t.length===1?e:t.slice(1).join(":")}function i(e){r.value===e?n.value=n.value==="asc"?"desc":"asc":r.value=e}return(e,t)=>{const I=S;return u(),h("table",O,[o("thead",j,[o("tr",null,[o("th",L,[o("button",{onClick:t[0]||(t[0]=s=>i("start"))},[t[5]||(t[5]=l(" Order ",-1)),o("div",{"ml--1":"","text-xs":"",class:p([r.value==="start"?"op50":"op0",n.value==="asc"?"carbon-arrow-down":"carbon-arrow-up"])},null,2)])]),o("th",z,[o("button",{onClick:t[1]||(t[1]=s=>i("name"))},[t[6]||(t[6]=l(" Hook name ",-1)),o("div",{"ml--1":"","text-xs":"",class:p([r.value==="name"?"op50":"op0",n.value==="asc"?"carbon-arrow-down":"carbon-arrow-up"])},null,2)])]),o("th",A,[o("button",{onClick:t[2]||(t[2]=s=>i("listener"))},[t[7]||(t[7]=l(" Listeners ",-1)),o("div",{"ml--1":"","text-xs":"",class:p([r.value==="listener"?"op50":"op0",n.value==="asc"?"carbon-arrow-down":"carbon-arrow-up"])},null,2)])]),o("th",U,[o("button",{onClick:t[3]||(t[3]=s=>i("executions"))},[t[8]||(t[8]=l(" Executions ",-1)),o("div",{"ml--1":"","text-xs":"",class:p([r.value==="executions"?"op50":"op0",n.value==="asc"?"carbon-arrow-down":"carbon-arrow-up"])},null,2)])]),o("th",Y,[o("button",{onClick:t[4]||(t[4]=s=>i("duration"))},[t[9]||(t[9]=l(" Duration ",-1)),o("div",{"ml--1":"","text-xs":"",class:p([r.value==="duration"?"op50":"op0",n.value==="asc"?"carbon-arrow-down":"carbon-arrow-up"])},null,2)])])])]),o("tbody",null,[(u(!0),h(y,null,F(b.value,s=>(u(),h("tr",{key:s.name,border:"b dashed transparent hover:base"},[o("td",q,m(g.value.indexOf(s.start)),1),o("td",{"w-0":"","ws-nowrap":"","text-right":"",style:V({color:("getHslColorFromStringHash"in e?e.getHslColorFromStringHash:k(T))(c(s.name))})},[o("code",J,m(c(s.name)),1)],4),o("td",R,[o("code",X,m(v(s.name)),1)]),o("td",G,m(s.listeners),1),o("td",K,m(s.executions.length+1),1),o("td",M,[_(I,{duration:s.duration},null,8,["duration"])])]))),128))])])}}}),W={class:"markdown-body"},Z={__name:"hooks",setup(x,{expose:a}){return a({frontmatter:{}}),(n,d)=>(u(),h("div",W,[...d[0]||(d[0]=[o("h1",null,"Hooks",-1),o("p",null,[l("Hooks are an advanced API which can be used for module development or other advanced use cases. The hooking API can be used to expand almost every aspect of Nuxt. Under the hood it is powered by "),o("a",{href:"https://github.com/unjs/hookable",target:"_blank",rel:"noopener"},"unjs/hookable"),l(".")],-1),o("p",null,[o("a",{href:"https://nuxt.com/docs/guide/going-further/hooks",target:"_blank",rel:"noopener"},"Learn more about hooks"),l(".")],-1)])]))}},ut=$({__name:"hooks",setup(x){const a=P(),r=E(),n=w(()=>r.value?.metrics.clientHooks());return(d,g)=>{const b=Q,c=B,v=Z,i=D;return u(),h(y,null,[o("div",null,[n.value?.length?(u(),C(c,{key:0,icon:"carbon-ibm-cloud-direct-link-1-dedicated-hosting",text:"Client Hooks",description:`Total hooks: ${n.value.length}`,padding:"pl4 pr6"},{default:f(()=>[_(b,{hooks:n.value},null,8,["hooks"])]),_:1},8,["description"])):N("",!0),k(a)?.length?(u(),C(c,{key:1,icon:"carbon-ibm-cloud-direct-link-2-dedicated",text:"Server Hooks",description:`Total hooks: ${k(a)?.length}`,padding:"pl4 pr6"},{default:f(()=>[_(b,{hooks:k(a)},null,8,["hooks"])]),_:1},8,["description"])):N("",!0)]),_(i,null,{default:f(()=>[_(v)]),_:1})],64)}}});export{ut as default};
|