@nuxt/devtools-nightly 2.6.4-29305197.39a0677 → 2.6.5-29306553.110ec66

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (138) hide show
  1. package/dist/chunks/module-main.mjs +26 -14
  2. package/dist/client/200.html +23 -22
  3. package/dist/client/404.html +23 -22
  4. package/dist/client/_nuxt/__blank-oybwb9u0.js +1 -0
  5. package/dist/client/_nuxt/analyze-build-oyvy2n6k.js +1 -0
  6. package/dist/client/_nuxt/{assets-oe58zq0u.js → assets-iiiil9h9.js} +1 -1
  7. package/dist/client/_nuxt/builds/latest.json +1 -1
  8. package/dist/client/_nuxt/builds/meta/4c13e94d-ac56-47f5-bbbd-0467b8121ba0.json +1 -0
  9. package/dist/client/_nuxt/{client-hkqvtzyx.js → client-kvgyopwa.js} +1 -1
  10. package/dist/client/_nuxt/code-diff.vue-bq8bth0l.js +8 -0
  11. package/dist/client/_nuxt/code-snippets.vue-i2momvvn.js +1 -0
  12. package/dist/client/_nuxt/components-kdxql4pw.js +1 -0
  13. package/dist/client/_nuxt/composable-item.vue-bd0qe28q.js +1 -0
  14. package/dist/client/_nuxt/custom-_name_-buxdzxp1.js +1 -0
  15. package/dist/client/_nuxt/data-schema-button.vue-hwc5uuo4.js +1 -0
  16. package/dist/client/_nuxt/{data-schema-drawer-ikpfkbri.js → data-schema-drawer-h78i632s.js} +1 -1
  17. package/dist/client/_nuxt/debug-0o48icu2.js +1 -0
  18. package/dist/client/_nuxt/default-cf08j011.js +1 -0
  19. package/dist/client/_nuxt/{duration-display.vue-l0zz5iex.js → duration-display.vue-juecltgn.js} +1 -1
  20. package/dist/client/_nuxt/entry.css-bgro2w4m.css +1 -0
  21. package/dist/client/_nuxt/error-404-isciqhf2.js +1 -0
  22. package/dist/client/_nuxt/error-404.css-nxlugf5l.css +1 -0
  23. package/dist/client/_nuxt/error-500-c949zj2y.js +1 -0
  24. package/dist/client/_nuxt/error-500.css-bcokcrit.css +1 -0
  25. package/dist/client/_nuxt/{error-ego8bzbx.js → error-acajsfcm.js} +1 -1
  26. package/dist/client/_nuxt/f05hqzgb.js +15 -0
  27. package/dist/client/_nuxt/filepath-item.vue-e693vfym.js +1 -0
  28. package/dist/client/_nuxt/full-gwf8k3h8.js +1 -0
  29. package/dist/client/_nuxt/help-fab.vue-le7iybnb.js +1 -0
  30. package/dist/client/_nuxt/hooks-i3c9zo45.js +1 -0
  31. package/dist/client/_nuxt/imports-pdvz452h.js +1 -0
  32. package/dist/client/_nuxt/index-fexmm3yj.js +1 -0
  33. package/dist/client/_nuxt/launch-page.vue-mubr1qiq.js +1 -0
  34. package/dist/client/_nuxt/modules-5z6nfxe1.js +1 -0
  35. package/dist/client/_nuxt/nbadge-hbh0pw7g.js +1 -0
  36. package/dist/client/_nuxt/ncheckbox.vue-cowm3nmm.js +1 -0
  37. package/dist/client/_nuxt/{ncode-block.vue-j1bpwykw.js → ncode-block.vue-nph7f5ph.js} +1 -1
  38. package/dist/client/_nuxt/ndrawer.vue-bscihm5p.js +1 -0
  39. package/dist/client/_nuxt/ndropdown.vue-mt2skirs.js +1 -0
  40. package/dist/client/_nuxt/{nicon-title.vue-mr03t3pg.js → nicon-title.vue-l5va2e26.js} +1 -1
  41. package/dist/client/_nuxt/nlink.vue-gjku6j2r.js +1 -0
  42. package/dist/client/_nuxt/{nmarkdown.vue-n5lhcplj.js → nmarkdown.vue-ho3nn7tc.js} +1 -1
  43. package/dist/client/_nuxt/nnavbar.vue-fe2vbqhk.js +1 -0
  44. package/dist/client/_nuxt/none-e00yke7p.js +1 -0
  45. package/dist/client/_nuxt/nsection-block-b1meb1ma.js +1 -0
  46. package/dist/client/_nuxt/nselect-tabs.vue-hb4dua1x.js +1 -0
  47. package/dist/client/_nuxt/nselect.vue-j457efs9.js +1 -0
  48. package/dist/client/_nuxt/{nswitch.vue-ihk2zmam.js → nswitch.vue-m7rzt1v6.js} +1 -1
  49. package/dist/client/_nuxt/{open-graph-hwba5o86.js → open-graph-hi306joh.js} +1 -1
  50. package/dist/client/_nuxt/overview-e8qf7rb9.js +1 -0
  51. package/dist/client/_nuxt/pages-kc19iifh.js +1 -0
  52. package/dist/client/_nuxt/payload-ha4336zu.js +1 -0
  53. package/dist/client/_nuxt/pinia-cmu5xh15.js +1 -0
  54. package/dist/client/_nuxt/plugins-i44pfamd.js +1 -0
  55. package/dist/client/_nuxt/render-tree-kzon7sx5.js +1 -0
  56. package/dist/client/_nuxt/runtime-configs-oedus2mc.js +1 -0
  57. package/dist/client/_nuxt/server-discovery-mfcbprv0.js +1 -0
  58. package/dist/client/_nuxt/server-route-inputs.vue-m4ax1l4d.js +1 -0
  59. package/dist/client/_nuxt/server-routes-i9u3il1o.js +9 -0
  60. package/dist/client/_nuxt/server-tasks-cfvjphup.js +1 -0
  61. package/dist/client/_nuxt/settings-hq5m70v8.js +1 -0
  62. package/dist/client/_nuxt/stacktrace-list.vue-nfhbrir6.js +1 -0
  63. package/dist/client/_nuxt/state-components-i9ev6w42.js +1 -0
  64. package/dist/client/_nuxt/state-editor.vue-byiz4hoi.js +1 -0
  65. package/dist/client/_nuxt/state-modules-c2rs6wdq.js +1 -0
  66. package/dist/client/_nuxt/storage-mlmdplne.js +1 -0
  67. package/dist/client/_nuxt/terminals-e0nyivcj.js +1 -0
  68. package/dist/client/_nuxt/timeline-dazlkvc4.js +31 -0
  69. package/dist/client/_nuxt/{unocss-runtime-eoln527w.js → unocss-runtime-njuf1ctl.js} +1 -1
  70. package/dist/client/_nuxt/vendor/json-editor-vue-gd4lkf0o.js +3902 -0
  71. package/dist/client/_nuxt/vendor/{quicktype-core-o057hwfl.js → quicktype-core-jxekulwx.js} +1 -1
  72. package/dist/client/_nuxt/vendor/unocss-nr5d25zy.js +3 -0
  73. package/dist/client/_nuxt/vendor/vis-bs03k74b.js +84 -0
  74. package/dist/client/_nuxt/virtual-files-e0zxw441.js +1 -0
  75. package/dist/client/_nuxt/vue-devtools-m76pi1vn.js +2 -0
  76. package/dist/client/_nuxt/{vue-virtual-scroller.esm-kqx3l34g.js → vue-virtual-scroller.esm-oaume2n6.js} +1 -1
  77. package/dist/client/index.html +23 -22
  78. package/dist/module.json +1 -1
  79. package/package.json +30 -30
  80. package/dist/client/_nuxt/__blank-h7gh4972.js +0 -1
  81. package/dist/client/_nuxt/analyze-build-h6dkidx5.js +0 -1
  82. package/dist/client/_nuxt/builds/meta/3619e6f2-9c27-4c4b-aada-2143e7348fa8.json +0 -1
  83. package/dist/client/_nuxt/code-diff.vue-jy5btphl.js +0 -8
  84. package/dist/client/_nuxt/code-snippets.vue-2de0d1wh.js +0 -1
  85. package/dist/client/_nuxt/components-kyf9xy2m.js +0 -1
  86. package/dist/client/_nuxt/composable-item.vue-lyurctn1.js +0 -1
  87. package/dist/client/_nuxt/custom-_name_-f0z5z5zf.js +0 -1
  88. package/dist/client/_nuxt/data-schema-button.vue-gj32e65l.js +0 -1
  89. package/dist/client/_nuxt/debug-iof3atod.js +0 -1
  90. package/dist/client/_nuxt/default-ck8sdk8k.js +0 -1
  91. package/dist/client/_nuxt/dv0e79gh.js +0 -15
  92. package/dist/client/_nuxt/entry.css-ojy5yvlc.css +0 -1
  93. package/dist/client/_nuxt/error-404-k23mnnj8.js +0 -1
  94. package/dist/client/_nuxt/error-404.css-z2gtwy9t.css +0 -1
  95. package/dist/client/_nuxt/error-500-ow1tk67n.js +0 -1
  96. package/dist/client/_nuxt/error-500.css-liy0brxy.css +0 -1
  97. package/dist/client/_nuxt/filepath-item.vue-jvnnqntk.js +0 -1
  98. package/dist/client/_nuxt/full-iirjyjb5.js +0 -1
  99. package/dist/client/_nuxt/help-fab.vue-iiy912yv.js +0 -1
  100. package/dist/client/_nuxt/hooks-da40i97a.js +0 -1
  101. package/dist/client/_nuxt/imports-g8mxyxsz.js +0 -1
  102. package/dist/client/_nuxt/index-jpk6gpmk.js +0 -1
  103. package/dist/client/_nuxt/launch-page.vue-ej8n1nol.js +0 -1
  104. package/dist/client/_nuxt/modules-d9zqk5n1.js +0 -1
  105. package/dist/client/_nuxt/nbadge-la51ie4t.js +0 -1
  106. package/dist/client/_nuxt/ncheckbox.vue-no3437wc.js +0 -1
  107. package/dist/client/_nuxt/ndrawer.vue-mok9ppy7.js +0 -1
  108. package/dist/client/_nuxt/ndropdown.vue-o8t9ic70.js +0 -1
  109. package/dist/client/_nuxt/nlink.vue-ehelr39g.js +0 -1
  110. package/dist/client/_nuxt/nnavbar.vue-cybpsded.js +0 -1
  111. package/dist/client/_nuxt/none-f0zl4gad.js +0 -1
  112. package/dist/client/_nuxt/nsection-block-ddplx9pl.js +0 -1
  113. package/dist/client/_nuxt/nselect-tabs.vue-hiwwt2n0.js +0 -1
  114. package/dist/client/_nuxt/nselect.vue-la95si0f.js +0 -1
  115. package/dist/client/_nuxt/overview-oqtc1aqt.js +0 -1
  116. package/dist/client/_nuxt/pages-eenpqko4.js +0 -1
  117. package/dist/client/_nuxt/payload-mzuxzjh9.js +0 -1
  118. package/dist/client/_nuxt/pinia-ijohlgiz.js +0 -1
  119. package/dist/client/_nuxt/plugins-hyjhe79v.js +0 -1
  120. package/dist/client/_nuxt/render-tree-dr6gtec2.js +0 -1
  121. package/dist/client/_nuxt/runtime-configs-pahcy1o7.js +0 -1
  122. package/dist/client/_nuxt/server-discovery-b8na9z7g.js +0 -1
  123. package/dist/client/_nuxt/server-route-inputs.vue-g0p9q870.js +0 -1
  124. package/dist/client/_nuxt/server-routes-mtcko0mi.js +0 -9
  125. package/dist/client/_nuxt/server-tasks-bll6cjth.js +0 -1
  126. package/dist/client/_nuxt/settings-dmjruw7n.js +0 -1
  127. package/dist/client/_nuxt/stacktrace-list.vue-g3i6ukg0.js +0 -1
  128. package/dist/client/_nuxt/state-components-hm1fypou.js +0 -1
  129. package/dist/client/_nuxt/state-editor.vue-k2eynukh.js +0 -1
  130. package/dist/client/_nuxt/state-modules-frr7rpga.js +0 -1
  131. package/dist/client/_nuxt/storage-m0qelhs8.js +0 -1
  132. package/dist/client/_nuxt/terminals-f4z14c3b.js +0 -1
  133. package/dist/client/_nuxt/timeline-n9pyujb3.js +0 -31
  134. package/dist/client/_nuxt/vendor/json-editor-vue-nstwj98r.js +0 -3857
  135. package/dist/client/_nuxt/vendor/unocss-klvjhln7.js +0 -3
  136. package/dist/client/_nuxt/vendor/vis-je6lvt05.js +0 -132
  137. package/dist/client/_nuxt/virtual-files-gffuaqhw.js +0 -1
  138. package/dist/client/_nuxt/vue-devtools-fv9dekm9.js +0 -2
@@ -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.4-29305197.39a0677";
36
+ const version$1 = "2.6.5-29306553.110ec66";
37
37
 
38
38
  const urlAlphabet = "useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";
39
39
  function randomStr(size = 16, dict = urlAlphabet) {
@@ -126,7 +126,7 @@ function setupAnalyzeBuildRPC({ nuxt, refresh, ensureDevAuthToken }) {
126
126
  const devtoolsAnalyzeDir = join(nuxt.options.rootDir, "node_modules/.cache/nuxt-devtools/analyze");
127
127
  async function startAnalyzeBuild(name) {
128
128
  if (promise)
129
- throw new Error("Already building");
129
+ throw new Error("[Nuxt DevTools] A building process is already running");
130
130
  const result = startSubprocess({
131
131
  command: "npx",
132
132
  args: ["nuxi", "analyze", "--no-serve", "--name", name],
@@ -260,6 +260,8 @@ function setupAssetsRPC({ nuxt, ensureDevAuthToken, refresh, options }) {
260
260
  for (const { layerDir, files } of dirs) {
261
261
  for (const path of files) {
262
262
  const filePath = resolve(layerDir, path);
263
+ if (!filePath.startsWith(layerDir))
264
+ continue;
263
265
  const stat = await fsp.lstat(filePath);
264
266
  const fullPath = join(baseURL, path);
265
267
  if (!uniquePaths.has(fullPath)) {
@@ -312,10 +314,12 @@ function setupAssetsRPC({ nuxt, ensureDevAuthToken, refresh, options }) {
312
314
  return await Promise.all(
313
315
  files.map(async ({ path, content, encoding, override }) => {
314
316
  let finalPath = resolve(baseDir, path);
317
+ if (!finalPath.startsWith(baseDir))
318
+ throw new Error(`[Nuxt DevTools] File ${path} is not allowed to upload, it's outside of the public directory`);
315
319
  const { ext } = parse(finalPath);
316
320
  if (extensions !== "*") {
317
321
  if (!extensions.includes(ext.toLowerCase().slice(1)))
318
- throw new Error(`File extension ${ext} is not allowed to upload, allowed extensions are: ${extensions.join(", ")}
322
+ throw new Error(`[Nuxt DevTools] File extension ${ext} is not allowed to upload, allowed extensions are: ${extensions.join(", ")}
319
323
  You can configure it in Nuxt config at \`devtools.assets.uploadExtensions\`.`);
320
324
  }
321
325
  if (!override) {
@@ -344,7 +348,7 @@ You can configure it in Nuxt config at \`devtools.assets.uploadExtensions\`.`);
344
348
  await ensureDevAuthToken(token);
345
349
  const exist = cache?.find((asset) => asset.filePath === newPath);
346
350
  if (exist)
347
- throw new Error(`File ${newPath} already exists`);
351
+ throw new Error(`[Nuxt DevTools] File ${newPath} already exists, failed to rename`);
348
352
  return await fsp.rename(oldPath, newPath);
349
353
  }
350
354
  };
@@ -8829,7 +8833,7 @@ function normalizeid(id) {
8829
8833
  if (typeof id !== "string") {
8830
8834
  id = id.toString();
8831
8835
  }
8832
- if (/(node|data|http|https|file):/.test(id)) {
8836
+ if (/(?:node|data|http|https|file):/.test(id)) {
8833
8837
  return id;
8834
8838
  }
8835
8839
  if (BUILTIN_MODULES.has(id)) {
@@ -8867,7 +8871,7 @@ function _resolve(id, options = {}) {
8867
8871
  throw new TypeError("input must be a `string` or `URL`");
8868
8872
  }
8869
8873
  }
8870
- if (/(node|data|http|https):/.test(id)) {
8874
+ if (/(?:node|data|http|https):/.test(id)) {
8871
8875
  return id;
8872
8876
  }
8873
8877
  if (BUILTIN_MODULES.has(id)) {
@@ -8952,17 +8956,21 @@ function resolvePath(id, options) {
8952
8956
  return Promise.reject(error);
8953
8957
  }
8954
8958
  }
8955
- const EXPORT_DECAL_RE = /\bexport\s+(?<declaration>(async function\s*\*?|function\s*\*?|let|const enum|const|enum|var|class))\s+\*?(?<name>[\w$]+)(?<extraNames>.*,\s*[\s\w:[\]{}]*[\w$\]}]+)*/g;
8956
- const EXPORT_NAMED_RE = /\bexport\s*{(?<exports>[^}]+?)[\s,]*}(\s*from\s*["']\s*(?<specifier>(?<="\s*)[^"]*[^\s"](?=\s*")|(?<='\s*)[^']*[^\s'](?=\s*'))\s*["'][^\n;]*)?/g;
8957
- const EXPORT_NAMED_DESTRUCT = /\bexport\s+(let|var|const)\s+(?:{(?<exports1>[^}]+?)[\s,]*}|\[(?<exports2>[^\]]+?)[\s,]*])\s+=/gm;
8958
- const EXPORT_STAR_RE = /\bexport\s*(\*)(\s*as\s+(?<name>[\w$]+)\s+)?\s*(\s*from\s*["']\s*(?<specifier>(?<="\s*)[^"]*[^\s"](?=\s*")|(?<='\s*)[^']*[^\s'](?=\s*'))\s*["'][^\n;]*)?/g;
8959
+ const EXPORT_DECAL_RE = /\bexport\s+(?<declaration>(?:async function\s*\*?|function\s*\*?|let|const enum|const|enum|var|class))\s+\*?(?<name>[\w$]+)(?<extraNames>.*,\s*[\s\w:[\]{}]*[\w$\]}]+)*/g;
8960
+ const EXPORT_NAMED_RE = /\bexport\s*{(?<exports>[^}]+?)[\s,]*}(?:\s*from\s*["']\s*(?<specifier>(?<="\s*)[^"]*[^\s"](?=\s*")|(?<='\s*)[^']*[^\s'](?=\s*'))\s*["'][^\n;]*)?/g;
8961
+ const EXPORT_NAMED_DESTRUCT = /\bexport\s+(?:let|var|const)\s+(?:{(?<exports1>[^}]+?)[\s,]*}|\[(?<exports2>[^\]]+?)[\s,]*])\s+=/gm;
8962
+ const EXPORT_STAR_RE = /\bexport\s*\*(?:\s*as\s+(?<name>[\w$]+)\s+)?\s*(?:\s*from\s*["']\s*(?<specifier>(?<="\s*)[^"]*[^\s"](?=\s*")|(?<='\s*)[^']*[^\s'](?=\s*'))\s*["'][^\n;]*)?/g;
8959
8963
  const EXPORT_DEFAULT_RE = /\bexport\s+default\s+(async function|function|class|true|false|\W|\d)|\bexport\s+default\s+(?<defaultName>.*)/g;
8964
+ const EXPORT_DEFAULT_CLASS_RE = /\bexport\s+default\s+(?<declaration>class)\s+(?<name>[\w$]+)/g;
8960
8965
  const TYPE_RE = /^\s*?type\s/;
8961
8966
  function findExports(code) {
8962
8967
  const declaredExports = matchAll(EXPORT_DECAL_RE, code, {
8963
8968
  type: "declaration"
8964
8969
  });
8965
8970
  for (const declaredExport of declaredExports) {
8971
+ if (/^export\s+(?:async\s+)?function/.test(declaredExport.code)) {
8972
+ continue;
8973
+ }
8966
8974
  const extraNamesStr = declaredExport.extraNames;
8967
8975
  if (extraNamesStr) {
8968
8976
  const extraNames = matchAll(
@@ -8994,6 +9002,9 @@ function findExports(code) {
8994
9002
  type: "default",
8995
9003
  name: "default"
8996
9004
  });
9005
+ const defaultClassExports = matchAll(EXPORT_DEFAULT_CLASS_RE, code, {
9006
+ type: "declaration"
9007
+ });
8997
9008
  const starExports = matchAll(EXPORT_STAR_RE, code, {
8998
9009
  type: "star"
8999
9010
  });
@@ -9002,6 +9013,7 @@ function findExports(code) {
9002
9013
  ...namedExports,
9003
9014
  ...destructuredExports,
9004
9015
  ...defaultExport,
9016
+ ...defaultClassExports,
9005
9017
  ...starExports
9006
9018
  ]);
9007
9019
  if (exports.length === 0) {
@@ -10781,7 +10793,7 @@ async function magicastGuard(fn, message = "") {
10781
10793
  generated = await fn();
10782
10794
  } catch (e) {
10783
10795
  logger.error(e);
10784
- throw new Error(`Magicast failed to modify Nuxt config automatically. Maybe the config are composed too dynamically that we failed to statically analyze it. ${message}`);
10796
+ throw new Error(`[Nuxt DevTools] Magicast failed to modify Nuxt config automatically. Maybe the config are composed too dynamically that we failed to statically analyze it. ${message}`);
10785
10797
  }
10786
10798
  return generated;
10787
10799
  }
@@ -10883,7 +10895,7 @@ function setupNpmRPC({ nuxt, ensureDevAuthToken }) {
10883
10895
  const code = result.exitCode;
10884
10896
  if (code !== 0) {
10885
10897
  console.error(result.stderr);
10886
- throw new Error(`Failed to install module, process exited with ${code}`);
10898
+ throw new Error(`[Nuxt DevTools] Failed to install module, process exited with ${code}`);
10887
10899
  }
10888
10900
  if (installSet.size === 0) {
10889
10901
  latestGenerated = null;
@@ -10931,7 +10943,7 @@ function setupNpmRPC({ nuxt, ensureDevAuthToken }) {
10931
10943
  const code = result.exitCode;
10932
10944
  if (code !== 0) {
10933
10945
  console.error(result.stderr);
10934
- throw new Error(`Failed to uninstall module', process exited with ${code}`);
10946
+ throw new Error(`[Nuxt DevTools] Failed to uninstall module, process exited with ${code}`);
10935
10947
  }
10936
10948
  await fsp.writeFile(filepath, generated, "utf-8");
10937
10949
  }
@@ -11420,7 +11432,7 @@ function setupRPC(nuxt, options) {
11420
11432
  if (options.disableAuthorization)
11421
11433
  return;
11422
11434
  if (token !== await getDevAuthToken())
11423
- throw new Error("Invalid dev auth token.");
11435
+ throw new Error("[Nuxt DevTools] Invalid dev auth token.");
11424
11436
  }
11425
11437
  };
11426
11438
  nuxt.devtools = ctx;
@@ -1,29 +1,30 @@
1
1
  <!DOCTYPE html><html><head><meta charset="utf-8">
2
2
  <meta name="viewport" content="width=device-width, initial-scale=1">
3
- <link rel="stylesheet" href="/__NUXT_DEVTOOLS_BASE__/_nuxt/entry.css-ojy5yvlc.css" crossorigin>
3
+ <script type="importmap">{"imports":{"#entry":"/__NUXT_DEVTOOLS_BASE__/_nuxt/f05hqzgb.js"}}</script>
4
+ <link rel="stylesheet" href="/__NUXT_DEVTOOLS_BASE__/_nuxt/entry.css-bgro2w4m.css" crossorigin>
4
5
  <link rel="stylesheet" href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/json-editor-vue.css-mqq5uooj.css" crossorigin>
5
6
  <link rel="stylesheet" href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/unocss.css-mhvipxpl.css" crossorigin>
6
- <link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/dv0e79gh.js">
7
- <link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/json-editor-vue-nstwj98r.js">
7
+ <link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/f05hqzgb.js">
8
+ <link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/json-editor-vue-gd4lkf0o.js">
8
9
  <link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/shiki-jxvjmls6.js">
9
- <link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/unocss-klvjhln7.js">
10
+ <link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/unocss-nr5d25zy.js">
10
11
  <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/markdown-it-fvu08dbs.js">
11
- <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/default-ck8sdk8k.js">
12
- <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/full-iirjyjb5.js">
13
- <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/none-f0zl4gad.js">
12
+ <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/default-cf08j011.js">
13
+ <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/full-gwf8k3h8.js">
14
+ <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/none-e00yke7p.js">
14
15
  <link rel="prefetch" as="style" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ncode-block.css-lvdc77tw.css">
15
- <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/data-schema-drawer-ikpfkbri.js">
16
- <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nselect.vue-la95si0f.js">
17
- <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nswitch.vue-ihk2zmam.js">
18
- <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ndropdown.vue-o8t9ic70.js">
19
- <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ncode-block.vue-j1bpwykw.js">
20
- <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/client-hkqvtzyx.js">
21
- <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ndrawer.vue-mok9ppy7.js">
22
- <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/quicktype-core-o057hwfl.js">
23
- <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/unocss-runtime-eoln527w.js">
24
- <link rel="prefetch" as="style" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/error-404.css-z2gtwy9t.css">
25
- <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/error-404-k23mnnj8.js">
26
- <link rel="prefetch" as="style" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/error-500.css-liy0brxy.css">
27
- <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/error-500-ow1tk67n.js">
28
- <script type="module" src="/__NUXT_DEVTOOLS_BASE__/_nuxt/dv0e79gh.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},1758311874997,false]</script>
29
- <script>window.__NUXT__={};window.__NUXT__.config={public:{},app:{baseURL:"/__NUXT_DEVTOOLS_BASE__/",buildId:"3619e6f2-9c27-4c4b-aada-2143e7348fa8",buildAssetsDir:"/_nuxt/",cdnURL:""}}</script></body></html>
16
+ <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/data-schema-drawer-h78i632s.js">
17
+ <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nselect.vue-j457efs9.js">
18
+ <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nswitch.vue-m7rzt1v6.js">
19
+ <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ndropdown.vue-mt2skirs.js">
20
+ <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ncode-block.vue-nph7f5ph.js">
21
+ <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/client-kvgyopwa.js">
22
+ <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ndrawer.vue-bscihm5p.js">
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-njuf1ctl.js">
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-isciqhf2.js">
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-c949zj2y.js">
29
+ <script type="module" src="/__NUXT_DEVTOOLS_BASE__/_nuxt/f05hqzgb.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},1758393209117,false]</script>
30
+ <script>window.__NUXT__={};window.__NUXT__.config={public:{},app:{baseURL:"/__NUXT_DEVTOOLS_BASE__/",buildId:"4c13e94d-ac56-47f5-bbbd-0467b8121ba0",buildAssetsDir:"/_nuxt/",cdnURL:""}}</script></body></html>
@@ -1,29 +1,30 @@
1
1
  <!DOCTYPE html><html><head><meta charset="utf-8">
2
2
  <meta name="viewport" content="width=device-width, initial-scale=1">
3
- <link rel="stylesheet" href="/__NUXT_DEVTOOLS_BASE__/_nuxt/entry.css-ojy5yvlc.css" crossorigin>
3
+ <script type="importmap">{"imports":{"#entry":"/__NUXT_DEVTOOLS_BASE__/_nuxt/f05hqzgb.js"}}</script>
4
+ <link rel="stylesheet" href="/__NUXT_DEVTOOLS_BASE__/_nuxt/entry.css-bgro2w4m.css" crossorigin>
4
5
  <link rel="stylesheet" href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/json-editor-vue.css-mqq5uooj.css" crossorigin>
5
6
  <link rel="stylesheet" href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/unocss.css-mhvipxpl.css" crossorigin>
6
- <link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/dv0e79gh.js">
7
- <link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/json-editor-vue-nstwj98r.js">
7
+ <link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/f05hqzgb.js">
8
+ <link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/json-editor-vue-gd4lkf0o.js">
8
9
  <link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/shiki-jxvjmls6.js">
9
- <link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/unocss-klvjhln7.js">
10
+ <link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/unocss-nr5d25zy.js">
10
11
  <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/markdown-it-fvu08dbs.js">
11
- <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/default-ck8sdk8k.js">
12
- <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/full-iirjyjb5.js">
13
- <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/none-f0zl4gad.js">
12
+ <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/default-cf08j011.js">
13
+ <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/full-gwf8k3h8.js">
14
+ <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/none-e00yke7p.js">
14
15
  <link rel="prefetch" as="style" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ncode-block.css-lvdc77tw.css">
15
- <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/data-schema-drawer-ikpfkbri.js">
16
- <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nselect.vue-la95si0f.js">
17
- <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nswitch.vue-ihk2zmam.js">
18
- <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ndropdown.vue-o8t9ic70.js">
19
- <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ncode-block.vue-j1bpwykw.js">
20
- <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/client-hkqvtzyx.js">
21
- <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ndrawer.vue-mok9ppy7.js">
22
- <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/quicktype-core-o057hwfl.js">
23
- <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/unocss-runtime-eoln527w.js">
24
- <link rel="prefetch" as="style" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/error-404.css-z2gtwy9t.css">
25
- <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/error-404-k23mnnj8.js">
26
- <link rel="prefetch" as="style" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/error-500.css-liy0brxy.css">
27
- <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/error-500-ow1tk67n.js">
28
- <script type="module" src="/__NUXT_DEVTOOLS_BASE__/_nuxt/dv0e79gh.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},1758311874997,false]</script>
29
- <script>window.__NUXT__={};window.__NUXT__.config={public:{},app:{baseURL:"/__NUXT_DEVTOOLS_BASE__/",buildId:"3619e6f2-9c27-4c4b-aada-2143e7348fa8",buildAssetsDir:"/_nuxt/",cdnURL:""}}</script></body></html>
16
+ <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/data-schema-drawer-h78i632s.js">
17
+ <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nselect.vue-j457efs9.js">
18
+ <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nswitch.vue-m7rzt1v6.js">
19
+ <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ndropdown.vue-mt2skirs.js">
20
+ <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ncode-block.vue-nph7f5ph.js">
21
+ <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/client-kvgyopwa.js">
22
+ <link rel="prefetch" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ndrawer.vue-bscihm5p.js">
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-njuf1ctl.js">
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-isciqhf2.js">
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-c949zj2y.js">
29
+ <script type="module" src="/__NUXT_DEVTOOLS_BASE__/_nuxt/f05hqzgb.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},1758393209117,false]</script>
30
+ <script>window.__NUXT__={};window.__NUXT__.config={public:{},app:{baseURL:"/__NUXT_DEVTOOLS_BASE__/",buildId:"4c13e94d-ac56-47f5-bbbd-0467b8121ba0",buildAssetsDir:"/_nuxt/",cdnURL:""}}</script></body></html>
@@ -0,0 +1 @@
1
+ import{p as e,J as n,$ as t}from"./vendor/json-editor-vue-gd4lkf0o.js";const c={"h-screen":"","w-screen":"","bg-black":""},r=e({__name:"__blank",setup(o){return(s,_)=>(t(),n("div",c))}});export{r as default};
@@ -0,0 +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-nr5d25zy.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"./dv0e79gh.js";import{_ as Ve}from"./ncheckbox.vue-no3437wc.js";import{_ as Pe}from"./ndropdown.vue-o8t9ic70.js";import{_ as Ae}from"./nnavbar.vue-cybpsded.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-nstwj98r.js";import{_ as Se}from"./nsection-block-ddplx9pl.js";import{_ as Ie}from"./filepath-item.vue-jvnnqntk.js";import{_ as Te}from"./code-snippets.vue-2de0d1wh.js";import{_ as je}from"./ndrawer.vue-mok9ppy7.js";import{D as Ee}from"./constants-b32h69zq.js";import"./vendor/shiki-jxvjmls6.js";import"./vendor/unocss-klvjhln7.js";import"./nicon-title.vue-mr03t3pg.js";import"./ncode-block.vue-j1bpwykw.js";import"./client-hkqvtzyx.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(()=>`
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-nr5d25zy.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":"3619e6f2-9c27-4c4b-aada-2143e7348fa8","timestamp":1758311842421}
1
+ {"id":"4c13e94d-ac56-47f5-bbbd-0467b8121ba0","timestamp":1758393179586}
@@ -0,0 +1 @@
1
+ {"id":"4c13e94d-ac56-47f5-bbbd-0467b8121ba0","timestamp":1758393179586,"matcher":{"static":{},"wildcard":{},"dynamic":{}},"prerendered":[]}
@@ -1 +1 @@
1
- import{n as f,O as r}from"./vendor/json-editor-vue-nstwj98r.js";let e;const n=[];function s(i){if(n.push(i),!(typeof window>"u"))return window.__NUXT_DEVTOOLS__&&n.forEach(o=>o(window.__NUXT_DEVTOOLS__)),Object.defineProperty(window,"__NUXT_DEVTOOLS__",{set(o){o&&n.forEach(t=>t(o))},get(){return e.value},configurable:!0}),()=>{n.splice(n.indexOf(i),1)}}function u(){e||(e=f(),s(o));function i(){e&&r(e)}function o(t){e.value=t,t.host&&t.host.hooks.hook("host:update:reactivity",i)}return e}const c=u();export{c as d};
1
+ import{n as f,O as r}from"./vendor/json-editor-vue-gd4lkf0o.js";let e;const n=[];function s(i){if(n.push(i),!(typeof window>"u"))return window.__NUXT_DEVTOOLS__&&n.forEach(o=>o(window.__NUXT_DEVTOOLS__)),Object.defineProperty(window,"__NUXT_DEVTOOLS__",{set(o){o&&n.forEach(t=>t(o))},get(){return e.value},configurable:!0}),()=>{n.splice(n.indexOf(i),1)}}function u(){e||(e=f(),s(o));function i(){e&&r(e)}function o(t){e.value=t,t.host&&t.host.hooks.hook("host:update:reactivity",i)}return e}const c=u();export{c as d};
@@ -0,0 +1,8 @@
1
+ import{_ as k}from"./ncode-block.vue-nph7f5ph.js";import{ao as D}from"#entry";import{p as I,q as T,k as j,E as y,U as q,$ as M}from"./vendor/json-editor-vue-gd4lkf0o.js";class z{diff(e,t,n={}){let o;typeof n=="function"?(o=n,n={}):"callback"in n&&(o=n.callback);const u=this.castInput(e,n),c=this.castInput(t,n),r=this.removeEmpty(this.tokenize(u,n)),s=this.removeEmpty(this.tokenize(c,n));return this.diffWithOptionsObj(r,s,n,o)}diffWithOptionsObj(e,t,n,o){var u;const c=d=>{if(d=this.postProcess(d,n),o){setTimeout(function(){o(d)},0);return}else return d},r=t.length,s=e.length;let l=1,i=r+s;n.maxEditLength!=null&&(i=Math.min(i,n.maxEditLength));const p=(u=n.timeout)!==null&&u!==void 0?u:1/0,f=Date.now()+p,a=[{oldPos:-1,lastComponent:void 0}];let h=this.extractCommon(a[0],t,e,0,n);if(a[0].oldPos+1>=s&&h+1>=r)return c(this.buildValues(a[0].lastComponent,t,e));let g=-1/0,w=1/0;const x=()=>{for(let d=Math.max(g,-l);d<=Math.min(w,l);d+=2){let C;const P=a[d-1],v=a[d+1];P&&(a[d-1]=void 0);let L=!1;if(v){const E=v.oldPos-d;L=v&&0<=E&&E<r}const _=P&&P.oldPos+1<s;if(!L&&!_){a[d]=void 0;continue}if(!_||L&&P.oldPos<v.oldPos?C=this.addToPath(v,!0,!1,0,n):C=this.addToPath(P,!1,!0,1,n),h=this.extractCommon(C,t,e,d,n),C.oldPos+1>=s&&h+1>=r)return c(this.buildValues(C.lastComponent,t,e))||!0;a[d]=C,C.oldPos+1>=s&&(w=Math.min(w,d-1)),h+1>=r&&(g=Math.max(g,d+1))}l++};if(o)(function d(){setTimeout(function(){if(l>i||Date.now()>f)return o(void 0);x()||d()},0)})();else for(;l<=i&&Date.now()<=f;){const d=x();if(d)return d}}addToPath(e,t,n,o,u){const c=e.lastComponent;return c&&!u.oneChangePerToken&&c.added===t&&c.removed===n?{oldPos:e.oldPos+o,lastComponent:{count:c.count+1,added:t,removed:n,previousComponent:c.previousComponent}}:{oldPos:e.oldPos+o,lastComponent:{count:1,added:t,removed:n,previousComponent:c}}}extractCommon(e,t,n,o,u){const c=t.length,r=n.length;let s=e.oldPos,l=s-o,i=0;for(;l+1<c&&s+1<r&&this.equals(n[s+1],t[l+1],u);)l++,s++,i++,u.oneChangePerToken&&(e.lastComponent={count:1,previousComponent:e.lastComponent,added:!1,removed:!1});return i&&!u.oneChangePerToken&&(e.lastComponent={count:i,previousComponent:e.lastComponent,added:!1,removed:!1}),e.oldPos=s,l}equals(e,t,n){return n.comparator?n.comparator(e,t):e===t||!!n.ignoreCase&&e.toLowerCase()===t.toLowerCase()}removeEmpty(e){const t=[];for(let n=0;n<e.length;n++)e[n]&&t.push(e[n]);return t}castInput(e,t){return e}tokenize(e,t){return Array.from(e)}join(e){return e.join("")}postProcess(e,t){return e}get useLongestToken(){return!1}buildValues(e,t,n){const o=[];let u;for(;e;)o.push(e),u=e.previousComponent,delete e.previousComponent,e=u;o.reverse();const c=o.length;let r=0,s=0,l=0;for(;r<c;r++){const i=o[r];if(i.removed)i.value=this.join(n.slice(l,l+i.count)),l+=i.count;else{if(!i.added&&this.useLongestToken){let p=t.slice(s,s+i.count);p=p.map(function(f,a){const h=n[l+a];return h.length>f.length?h:f}),i.value=this.join(p)}else i.value=this.join(t.slice(s,s+i.count));s+=i.count,i.added||(l+=i.count)}}return o}}class A extends z{constructor(){super(...arguments),this.tokenize=N}equals(e,t,n){return n.ignoreWhitespace?((!n.newlineIsToken||!e.includes(`
2
+ `))&&(e=e.trim()),(!n.newlineIsToken||!t.includes(`
3
+ `))&&(t=t.trim())):n.ignoreNewlineAtEof&&!n.newlineIsToken&&(e.endsWith(`
4
+ `)&&(e=e.slice(0,-1)),t.endsWith(`
5
+ `)&&(t=t.slice(0,-1))),super.equals(e,t,n)}}const V=new A;function W(m,e,t){return V.diff(m,e,t)}function N(m,e){e.stripTrailingCr&&(m=m.replace(/\r\n/g,`
6
+ `));const t=[],n=m.split(/(\n|\r\n)/);n[n.length-1]||n.pop();for(let o=0;o<n.length;o++){const u=n[o];o%2&&!e.newlineIsToken?t[t.length-1]+=u:t.push(u)}return t}const B=I({__name:"CodeDiff",props:{from:{},to:{},lang:{}},setup(m){const e=m;function t(r,s){const l=W(r.trim(),s.trim()),i=[],p=[],f=[];for(const a of l){const h=a.value.trimEnd().split(`
7
+ `);for(const g of h)a.added?(i.push(f.length),f.push(g)):(a.removed&&p.push(f.length),f.push(g))}return{added:i,removed:p,result:f.join(`
8
+ `)}}const n=T(()=>t(e.from,e.to));function o(r){let s=0;return r.replace(/class="shiki/,'class="shiki diff').replace(/class="line"/g,l=>(s++,n.value.added.includes(s-1)?'class="line line-added"':n.value.removed.includes(s-1)?'class="line line-removed"':l))}const u=j();y(c);function c(){const r=D(u);r&&r.querySelector(".line-added,.line-removed")?.scrollIntoView()}return(r,s)=>{const l=k;return M(),q(l,{ref_key:"elRef",ref:u,code:n.value.result,lang:r.lang,"transform-rendered":o,onLoaded:c},null,8,["code","lang"])}}});export{B as _};
@@ -0,0 +1 @@
1
+ import{_ as g}from"./ncode-block.vue-nph7f5ph.js";import{a as C,_ as x}from"#entry";import{p as S,n as w,q as B,w as N,J as n,a1 as r,$ as a,a0 as s,F as d,ag as V,a4 as i,a8 as $,X as u,U as T,V as v,ab as m,u as h}from"./vendor/json-editor-vue-gd4lkf0o.js";const D={key:0,relative:"","n-code-block":""},E={flex:"~ wrap","w-full":""},F=["onClick"],L={flex:"~ gap-2",px3:"",pb3:"",n:"sm primary"},U=S({__name:"CodeSnippets",props:{codeSnippets:{},eventType:{}},setup(f){const l=f,e=w(l.codeSnippets[0]),_=C(),b=B(()=>e.value?.lang||"text");return N(()=>{l.codeSnippets.includes(e.value)||(e.value=l.codeSnippets[0])}),(p,o)=>{const k=g,c=x;return p.codeSnippets.length?(a(),n("div",D,[s("div",E,[(a(!0),n(d,null,V(p.codeSnippets,(t,y)=>(a(),n("button",{key:y,px4:"",py2:"",border:"r base",hover:"bg-active",class:i(t===e.value?"":"border-b"),onClick:q=>e.value=t},[s("div",{class:i(t===e.value?"":"op30"),"font-mono":""},$(t.name),3)],10,F))),128)),o[1]||(o[1]=s("div",{border:"b base","flex-auto":""},null,-1))]),e.value?(a(),n(d,{key:0},[u(k,{code:e.value.code,lang:b.value,lines:!1,"w-full":"","of-auto":"",p3:""},null,8,["code","lang"]),s("div",L,[u(c,{icon:"carbon-copy",onClick:o[0]||(o[0]=t=>h(_)(e.value.code,p.eventType||`code-snippet-${e.value.name}`))},{default:v(()=>[...o[2]||(o[2]=[m(" Copy ",-1)])]),_:1}),e.value?.docs?(a(),T(c,{key:0,to:e.value.docs,target:"_blank",icon:"carbon-catalog"},{default:v(()=>[...o[3]||(o[3]=[m(" Docs ",-1)])]),_:1},8,["to"])):r("",!0)])],64)):r("",!0)])):r("",!0)}}});export{U as _};
@@ -0,0 +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};
@@ -0,0 +1 @@
1
+ import{a as $,w as U,I as E,_ as F}from"#entry";import{_ as j}from"./nmarkdown.vue-ho3nn7tc.js";import{_ as S}from"./filepath-item.vue-e693vfym.js";import{k as q}from"./index-jc4yj4to.js";import{C as y}from"./constants-b32h69zq.js";import{p as z,q as r,Z as J,U as i,$ as s,V as m,a0 as a,a4 as L,J as p,a1 as l,ab as c,a8 as _,X as b,u as k,F as x,ag as M}from"./vendor/json-editor-vue-gd4lkf0o.js";const O={rounded:"","font-mono":""},T={key:0,"text-primary":""},W={key:0},X={title:"Vue Directive"},Z={"max-w-100":""},A={px4:"",py3:"","text-sm":""},G={flex:"~ gap2",n:"primary xs"},H={border:"t base","max-h-60":"","of-auto":"",px4:"",py3:""},K={"text-sm":""},P={"text-primary":""},Q={flex:"~ col gap-2","items-start":"",pt3:"","text-sm":"",op75:""},R={key:1,"text-sm":"",op50:""},ne=z({__name:"ComposableItem",props:{item:{},isDirective:{type:Boolean,default:!1},metadata:{},filepath:{},counter:{type:Boolean,default:!0},classes:{default:"px2 py1 text-sm bg-gray:5 "}},setup(g){const o=g,C=$(),h=U(),u=r(()=>o.item.as||o.item.name),D=r(()=>{let e=u.value;return o.isDirective&&(e[0]!=="v"&&(e=`v${e}`),e=q(e)),e}),n=r(()=>o.metadata?.injectionUsage?.[u.value]?.count||0),N=r(()=>(o.metadata?.injectionUsage?.[u.value]?.moduleIds||[]).filter(e=>!e.endsWith("?macro=true"))),v=r(()=>o.item.meta?.docsUrl?o.item.meta.docsUrl:["nuxt","#app","nuxt3"].includes(o.item.from)?y.nuxt[o.item.name]:o.item.from==="vue"?y.vue[o.item.name]:null);return(e,t)=>{const w=E,I=j,f=F,V=S,B=J("VDropdown");return s(),i(B,{disabled:!o.metadata},{popper:m(()=>[a("div",Z,[a("div",A,[e.item.meta?.description?(s(),i(I,{key:0,tag:"div",pb3:"","text-sm":"",markdown:e.item.meta.description},null,8,["markdown"])):l("",!0),a("div",G,[b(f,{icon:"carbon-copy",onClick:t[0]||(t[0]=d=>k(C)(D.value,"imports-name"))},{default:m(()=>[...t[2]||(t[2]=[c(" Copy ",-1)])]),_:1}),e.filepath?(s(),i(f,{key:0,icon:"carbon-code",onClick:t[1]||(t[1]=d=>e.filepath&&k(h)(e.filepath))},{default:m(()=>[...t[3]||(t[3]=[c(" Source ",-1)])]),_:1})):l("",!0),v.value?(s(),i(f,{key:1,icon:"carbon-catalog",to:v.value,target:"_blank"},{default:m(()=>[...t[4]||(t[4]=[c(" Docs ",-1)])]),_:1},8,["to"])):l("",!0)])]),a("div",H,[n.value?(s(),p(x,{key:0},[a("div",K,[t[5]||(t[5]=a("span",{op50:""},"It has been referenced ",-1)),a("strong",P,_(n.value),1),t[6]||(t[6]=a("span",{op50:""}," times by:",-1))]),a("div",Q,[(s(!0),p(x,null,M(N.value,d=>(s(),i(V,{key:d,filepath:d},null,8,["filepath"]))),128))])],64)):(s(),p("div",R," Not in use via auto import. "))])])]),default:m(()=>[a("button",{"hover:text-primary":"",class:L([e.metadata&&!n.value?"op30 hover:op100":"",e.classes])},[a("code",O,[c(_(u.value)+" ",1),n.value&&e.counter?(s(),p("sup",T,"x"+_(n.value),1)):l("",!0)]),e.isDirective?(s(),p("sup",W,[a("abbr",X,[b(w,{icon:"tabler:hexagon-letter-d"})])])):l("",!0)],2)]),_:1},8,["disabled"])}}});export{ne as _};
@@ -0,0 +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-nr5d25zy.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};
@@ -0,0 +1 @@
1
+ import{u as r,_ as c}from"#entry";import{p as s,ai as i,ac as p,$ as _,U as m}from"./vendor/json-editor-vue-gd4lkf0o.js";const D=s({__name:"DataSchemaButton",props:{getter:{type:Function}},setup(u){const t=r();return(o,e)=>{const n=c,a=i("tooltip");return p((_(),m(n,{title:"Generate Data Schema",icon:"carbon:container-services",border:!1,onClick:e[0]||(e[0]=l=>t.value=o.getter())},null,512)),[[a,"Generate Data Schema"]])}}});export{D as _};
@@ -1,2 +1,2 @@
1
- import{_ as A}from"./nselect.vue-la95si0f.js";import{u as E,c as F,a as W,_ as q}from"./dv0e79gh.js";import{_ as z}from"./nswitch.vue-ihk2zmam.js";import{_ as J}from"./ndropdown.vue-o8t9ic70.js";import{_ as O}from"./ncode-block.vue-j1bpwykw.js";import{_ as X}from"./ndrawer.vue-mok9ppy7.js";import{A as h,d as x}from"./vendor/quicktype-core-o057hwfl.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-nstwj98r.js";import"./vendor/shiki-jxvjmls6.js";import"./vendor/unocss-klvjhln7.js";import"./client-hkqvtzyx.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(`
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-nr5d25zy.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};
@@ -0,0 +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-nr5d25zy.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};
@@ -0,0 +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-nr5d25zy.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{p as i,q as u,J as d,$ as f,a4 as l,W as o,ab as p,a0 as c,a8 as a}from"./vendor/json-editor-vue-nstwj98r.js";const m={"ml-1":"","text-xs":"",op50:""},g=i({__name:"DurationDisplay",props:{duration:{},factor:{default:1},color:{type:Boolean,default:!0}},setup(n){const t=n;function s(e){return t.color?e?(e=e*t.factor,e<.5?"text-gray:50":e>1e3?"text-red-400":e>500?"text-orange-400":e>200?"text-yellow-400":""):"text-gray-400":""}const r=u(()=>!t.duration||t.duration<1?["<1","ms"]:t.duration<1e3?[t.duration.toFixed(0),"ms"]:t.duration<1e3*60?[(t.duration/1e3).toFixed(1),"s"]:[(t.duration/1e3/60).toFixed(1),"min"]);return(e,x)=>(f(),d("div",{class:l(s(e.duration))},[o(e.$slots,"before"),p(" "+a(r.value[0]),1),c("span",m,a(r.value[1]),1),o(e.$slots,"after")],2))}});export{g as _};
1
+ import{p as i,q as u,J as d,$ as f,a4 as l,W as o,ab as p,a0 as c,a8 as a}from"./vendor/json-editor-vue-gd4lkf0o.js";const m={"ml-1":"","text-xs":"",op50:""},g=i({__name:"DurationDisplay",props:{duration:{},factor:{default:1},color:{type:Boolean,default:!0}},setup(n){const t=n;function s(e){return t.color?e?(e=e*t.factor,e<.5?"text-gray:50":e>1e3?"text-red-400":e>500?"text-orange-400":e>200?"text-yellow-400":""):"text-gray-400":""}const r=u(()=>!t.duration||t.duration<1?["<1","ms"]:t.duration<1e3?[t.duration.toFixed(0),"ms"]:t.duration<1e3*60?[(t.duration/1e3).toFixed(1),"s"]:[(t.duration/1e3/60).toFixed(1),"min"]);return(e,x)=>(f(),d("div",{class:l(s(e.duration))},[o(e.$slots,"before"),p(" "+a(r.value[0]),1),c("span",m,a(r.value[1]),1),o(e.$slots,"after")],2))}});export{g as _};