@nuxt/devtools-nightly 3.2.2-29550408.69bb9b6 → 3.2.2-29550552.77c32d4
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 +141 -52
- package/dist/chunks/plugin-metrics.mjs +4 -2
- package/dist/chunks/timeline.mjs +2 -1
- package/dist/chunks/vite-inspect.mjs +7 -4
- package/dist/client/200.html +1 -1
- package/dist/client/404.html +1 -1
- package/dist/client/_nuxt/__blank-gayjf0ih.js +1 -0
- package/dist/client/_nuxt/analyze-build-bnq2cil8.js +1 -0
- package/dist/client/_nuxt/assets-fjp0hrmh.js +6 -0
- package/dist/client/_nuxt/builds/latest.json +1 -1
- package/dist/client/_nuxt/builds/meta/b4ea867d-556a-40bd-b899-5018491fcc2d.json +1 -0
- package/dist/client/_nuxt/{client-lfu9nb62.js → client-lh91kcpv.js} +1 -1
- package/dist/client/_nuxt/{client-ea5fdhj9.js → client-s5g5n0ac.js} +2 -2
- package/dist/client/_nuxt/{code-diff-otsxuk81.js → code-diff-cb7twqkt.js} +3 -3
- package/dist/client/_nuxt/{code-snippets-c0ulfayj.js → code-snippets-ho13b87l.js} +1 -1
- package/dist/client/_nuxt/components-peth8amc.js +1 -0
- package/dist/client/_nuxt/{composable-item-jjp1tvft.js → composable-item-b09pj4ca.js} +1 -1
- package/dist/client/_nuxt/custom-_name_-lfwzilnd.js +1 -0
- package/dist/client/_nuxt/{data-schema-button-fk6ozqve.js → data-schema-button-ke4komn6.js} +1 -1
- package/dist/client/_nuxt/{data-schema-drawer-mi3x7oeb.js → data-schema-drawer-dqe6w00i.js} +1 -1
- package/dist/client/_nuxt/debug-itzra6gt.js +1 -0
- package/dist/client/_nuxt/{default-n9xykcpp.js → default-bunv5fnq.js} +1 -1
- package/dist/client/_nuxt/{dev-auth-jrf61eu0.js → dev-auth-j4vxv6a1.js} +1 -1
- package/dist/client/_nuxt/{dist-jq34z2yz.js → dist-duc3zu0y.js} +1 -1
- package/dist/client/_nuxt/{duration-display-k6iuyk4f.js → duration-display-20xlusue.js} +1 -1
- package/dist/client/_nuxt/{entry.css-gx482m17.css → entry.css-ckq2wff8.css} +1 -1
- package/dist/client/_nuxt/{error-404-b375yxaj.js → error-404-c73bftho.js} +1 -1
- package/dist/client/_nuxt/error-404.css-pazrj6fo.css +1 -0
- package/dist/client/_nuxt/{error-500-marpmos8.js → error-500-75llnfh8.js} +1 -1
- package/dist/client/_nuxt/error-500.css-hlldh6hu.css +1 -0
- package/dist/client/_nuxt/error-isnb18yz.js +9 -0
- package/dist/client/_nuxt/{filepath-item-e4nchqwg.js → filepath-item-fnp9jxof.js} +1 -1
- package/dist/client/_nuxt/full-h8pokapo.js +1 -0
- package/dist/client/_nuxt/{head-k6pu038r.js → head-c2jgvqd9.js} +1 -1
- package/dist/client/_nuxt/{help-fab-hk76lwiw.js → help-fab-oc1qudll.js} +1 -1
- package/dist/client/_nuxt/hooks-i5p6cuw0.js +1 -0
- package/dist/client/_nuxt/imports-ia8eldh8.js +1 -0
- package/dist/client/_nuxt/kzt4clis.js +4 -0
- package/dist/client/_nuxt/{launch-page-k1lwfnm2.js → launch-page-kf0w74wk.js} +1 -1
- package/dist/client/_nuxt/modules-obwfskfp.js +1 -0
- package/dist/client/_nuxt/nbadge-hpznun17.js +1 -0
- package/dist/client/_nuxt/{nbutton-m0kqfedx.js → nbutton-oi1rfqiz.js} +1 -1
- package/dist/client/_nuxt/ncard-ech06vlh.js +1 -0
- package/dist/client/_nuxt/{ncheckbox-knbe2cxv.js → ncheckbox-k9nxqa1w.js} +1 -1
- package/dist/client/_nuxt/{ncode-block-o9sq6td7.js → ncode-block-coc4sua0.js} +1 -1
- package/dist/client/_nuxt/{ndrawer-ufyhcx08.js → ndrawer-ijwn9421.js} +1 -1
- package/dist/client/_nuxt/{ndropdown-lkmzobqs.js → ndropdown-moy416uy.js} +1 -1
- package/dist/client/_nuxt/{nicon-j0r9gdjm.js → nicon-m5br9nvg.js} +1 -1
- package/dist/client/_nuxt/{nicon-title-ggx25xp9.js → nicon-title-e35pdr21.js} +1 -1
- package/dist/client/_nuxt/{nlink-hz4zwb3c.js → nlink-dmk2d6qc.js} +1 -1
- package/dist/client/_nuxt/{nmarkdown-nsbirjtv.js → nmarkdown-nct1w6kn.js} +1 -1
- package/dist/client/_nuxt/{nnavbar-b0i34u17.js → nnavbar-n3j7iul1.js} +1 -1
- package/dist/client/_nuxt/none-bs12srzp.js +1 -0
- package/dist/client/_nuxt/npanel-grids-bl37sfq7.js +1 -0
- package/dist/client/_nuxt/{nsection-block-dzbgwc4z.js → nsection-block-l0c6dpg8.js} +1 -1
- package/dist/client/_nuxt/{nselect-ne66fzrs.js → nselect-kgjpj17v.js} +1 -1
- package/dist/client/_nuxt/{nselect-tabs-jgvac6a8.js → nselect-tabs-if6er1us.js} +1 -1
- package/dist/client/_nuxt/{nswitch-abl34kow.js → nswitch-b36trghq.js} +1 -1
- package/dist/client/_nuxt/{ntext-input-ozkk5xro.js → ntext-input-ngomk0u2.js} +1 -1
- package/dist/client/_nuxt/{nuxt-h34yfo3l.js → nuxt-bfozs29x.js} +1 -1
- package/dist/client/_nuxt/{nuxt-link-lrojf3ui.js → nuxt-link-mev16ngd.js} +1 -1
- package/dist/client/_nuxt/open-graph-m7wd1sxi.js +3 -0
- package/dist/client/_nuxt/overview-fauwb2xr.js +1 -0
- package/dist/client/_nuxt/pages-gnfgydad.js +1 -0
- package/dist/client/_nuxt/pages-izgjpbm4.js +1 -0
- package/dist/client/_nuxt/payload-hc17espa.js +1 -0
- package/dist/client/_nuxt/pinia-ns87k5yi.js +1 -0
- package/dist/client/_nuxt/plugins-mswypwe4.js +1 -0
- package/dist/client/_nuxt/{ready-mmkdpbhg.js → ready-szdlhgcr.js} +1 -1
- package/dist/client/_nuxt/render-tree-hec27xi7.js +1 -0
- package/dist/client/_nuxt/runtime-configs-chx5ggf0.js +1 -0
- package/dist/client/_nuxt/server-discovery-cjcj8emm.js +1 -0
- package/dist/client/_nuxt/server-route-inputs-lqwnul2k.js +1 -0
- package/dist/client/_nuxt/server-routes-e0uqj8di.js +7 -0
- package/dist/client/_nuxt/server-tasks-izz5mcrk.js +1 -0
- package/dist/client/_nuxt/settings-dhxjcakv.js +1 -0
- package/dist/client/_nuxt/{splitpanes.es-gcrxxdgy.js → splitpanes.es-ceqv8417.js} +1 -1
- package/dist/client/_nuxt/stacktrace-list-m1sv2uvd.js +1 -0
- package/dist/client/_nuxt/state-components-mnfvrbtw.js +1 -0
- package/dist/client/_nuxt/state-dkywakbf.js +1 -0
- package/dist/client/_nuxt/{state-editor-egz1k0a8.js → state-editor-epijodsw.js} +1 -1
- package/dist/client/_nuxt/{state-modules-dyb3mv6i.js → state-modules-ehax0fup.js} +1 -1
- package/dist/client/_nuxt/{state-routes-ovtjymzc.js → state-routes-m6gv5n9v.js} +1 -1
- package/dist/client/_nuxt/{state-tabs-jkd7jbwg.js → state-tabs-mo8r9nzk.js} +1 -1
- package/dist/client/_nuxt/storage-hdyfvofj.js +1 -0
- package/dist/client/_nuxt/{storage-options-os0x8zby.js → storage-options-owy2vf04.js} +1 -1
- package/dist/client/_nuxt/{telemetry-pccqt90w.js → telemetry-bagjjni2.js} +1 -1
- package/dist/client/_nuxt/terminals-hem69799.js +1 -0
- package/dist/client/_nuxt/timeline-luryae8h.js +31 -0
- package/dist/client/_nuxt/unocss-runtime-jcr8lucj.js +1 -0
- package/dist/client/_nuxt/vendor/{json-editor-vue-jlmu1vk1.js → json-editor-vue-hkofgjf7.js} +3 -3
- package/dist/client/_nuxt/vendor/shiki-niqic03h.js +153 -0
- package/dist/client/_nuxt/vendor/unocss-bj3ln324.js +3 -0
- package/dist/client/_nuxt/vendor/unocss.css-3gd0e2sv.css +1 -0
- package/dist/client/_nuxt/vendor/{vis-p9fufs7k.js → vis-id8udisj.js} +1 -1
- package/dist/client/_nuxt/virtual-files-o2l5arel.js +1 -0
- package/dist/client/_nuxt/vue-devtools-na2nb82m.js +3 -0
- package/dist/client/_nuxt/{vue-router-fwt4i0j8.js → vue-router-dxks01bs.js} +1 -1
- package/dist/client/_nuxt/{vue-virtual-scroller.esm-hq850jog.js → vue-virtual-scroller.esm-d0igfpwe.js} +1 -1
- package/dist/client/index.html +1 -1
- package/dist/dirs.mjs +2 -1
- package/dist/module.json +1 -1
- package/dist/runtime/plugins/view/client.js +2 -1
- package/dist/webcomponents/index.mjs +8 -6
- package/package.json +24 -24
- package/dist/client/_nuxt/__blank-jnbqrgps.js +0 -1
- package/dist/client/_nuxt/analyze-build-c3vdx12p.js +0 -1
- package/dist/client/_nuxt/assets-myudvi12.js +0 -6
- package/dist/client/_nuxt/builds/meta/12530810-3e16-4e21-b7b4-a7a83824f852.json +0 -1
- package/dist/client/_nuxt/components-dwnwjv62.js +0 -1
- package/dist/client/_nuxt/custom-_name_-k9wxhx5t.js +0 -1
- package/dist/client/_nuxt/debug-jzrj2rrq.js +0 -1
- package/dist/client/_nuxt/error-404.css-k620a6z0.css +0 -1
- package/dist/client/_nuxt/error-500.css-j1xt9kl6.css +0 -1
- package/dist/client/_nuxt/error-f0x29wdg.js +0 -9
- package/dist/client/_nuxt/full-ix5b85yu.js +0 -1
- package/dist/client/_nuxt/g42uya8p.js +0 -4
- package/dist/client/_nuxt/hooks-oamlzps1.js +0 -1
- package/dist/client/_nuxt/imports-rq4f924m.js +0 -1
- package/dist/client/_nuxt/modules-fev9bjof.js +0 -1
- package/dist/client/_nuxt/nbadge-h59v1exj.js +0 -1
- package/dist/client/_nuxt/ncard-qqqgbjy9.js +0 -1
- package/dist/client/_nuxt/none-bfunqbwh.js +0 -1
- package/dist/client/_nuxt/npanel-grids-m4ogaoh1.js +0 -1
- package/dist/client/_nuxt/open-graph-jokpmi3z.js +0 -3
- package/dist/client/_nuxt/overview-nrbi7ztz.js +0 -1
- package/dist/client/_nuxt/pages-heq5sr3n.js +0 -1
- package/dist/client/_nuxt/pages-nev63916.js +0 -1
- package/dist/client/_nuxt/payload-cwkdgfbg.js +0 -1
- package/dist/client/_nuxt/pinia-cmp1aao2.js +0 -1
- package/dist/client/_nuxt/plugins-h6nd4bpq.js +0 -1
- package/dist/client/_nuxt/render-tree-c25vnw9j.js +0 -1
- package/dist/client/_nuxt/runtime-configs-oyvmfkja.js +0 -1
- package/dist/client/_nuxt/server-discovery-k4kknv5h.js +0 -1
- package/dist/client/_nuxt/server-route-inputs-heqgxrjl.js +0 -1
- package/dist/client/_nuxt/server-routes-bgud29n1.js +0 -7
- package/dist/client/_nuxt/server-tasks-kx1cj481.js +0 -1
- package/dist/client/_nuxt/settings-iudhxqb4.js +0 -1
- package/dist/client/_nuxt/stacktrace-list-ivp3f076.js +0 -1
- package/dist/client/_nuxt/state-b65zn1p8.js +0 -1
- package/dist/client/_nuxt/state-components-gdb1hu1j.js +0 -1
- package/dist/client/_nuxt/storage-noqjkcnn.js +0 -1
- package/dist/client/_nuxt/terminals-jwh8xdao.js +0 -1
- package/dist/client/_nuxt/timeline-nj0c9ow3.js +0 -31
- package/dist/client/_nuxt/unocss-runtime-mfhoy4ux.js +0 -1
- package/dist/client/_nuxt/vendor/shiki-jnavg768.js +0 -152
- package/dist/client/_nuxt/vendor/unocss-o75ihzkt.js +0 -3
- package/dist/client/_nuxt/virtual-files-nyi1q55e.js +0 -1
- package/dist/client/_nuxt/vue-devtools-b8p76ncm.js +0 -3
- /package/dist/client/_nuxt/{_plugin-vue_export-helper-myijwyyb.js → _plugin-vue_export-helper-dp8rxgcg.js} +0 -0
- /package/dist/client/_nuxt/{color-m9fh6h3t.js → color-b9xoe9j2.js} +0 -0
- /package/dist/client/_nuxt/{composables-k2ak4j8d.js → composables-cwesk2q8.js} +0 -0
- /package/dist/client/_nuxt/{constants-ihoovckn.js → constants-lof1c7kz.js} +0 -0
- /package/dist/client/_nuxt/{dist-9xqq72tk.js → dist-m49wlq01.js} +0 -0
- /package/dist/client/_nuxt/{dist-h291wass.js → dist-mnod32r1.js} +0 -0
- /package/dist/client/_nuxt/vendor/{markdown-it-ocmvh7ju.js → markdown-it-bcxn77q6.js} +0 -0
- /package/dist/client/_nuxt/vendor/{quicktype-core-jebn1o7i.js → quicktype-core-f8dnflnv.js} +0 -0
- /package/dist/client/_nuxt/vendor/{xterm-du7kv949.js → xterm-ed0pys2e.js} +0 -0
|
@@ -22,7 +22,7 @@ import { setupHooksDebug } from '../../dist/runtime/shared/hooks.js';
|
|
|
22
22
|
import process$1 from 'node:process';
|
|
23
23
|
import { builtinModules, createRequire } from 'node:module';
|
|
24
24
|
import { resolvePackageJSON, readPackageJSON } from 'pkg-types';
|
|
25
|
-
import { fileURLToPath as fileURLToPath$1, pathToFileURL as pathToFileURL$1
|
|
25
|
+
import { fileURLToPath as fileURLToPath$1, pathToFileURL as pathToFileURL$1 } from 'node:url';
|
|
26
26
|
import assert from 'node:assert';
|
|
27
27
|
import v8 from 'node:v8';
|
|
28
28
|
import { format, inspect } from 'node:util';
|
|
@@ -34,7 +34,7 @@ import { detectPackageManager } from 'nypm';
|
|
|
34
34
|
import semver from 'semver';
|
|
35
35
|
import { normalizeBaseKey, normalizeKey } from 'unstorage';
|
|
36
36
|
|
|
37
|
-
const version$1 = "3.2.2-
|
|
37
|
+
const version$1 = "3.2.2-29550552.77c32d4";
|
|
38
38
|
|
|
39
39
|
const urlAlphabet = "useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";
|
|
40
40
|
function randomStr(size = 16, dict = urlAlphabet) {
|
|
@@ -119,6 +119,7 @@ async function getDevAuthToken() {
|
|
|
119
119
|
return token;
|
|
120
120
|
}
|
|
121
121
|
|
|
122
|
+
const COLON_RE = /:/g;
|
|
122
123
|
function setupAnalyzeBuildRPC({ nuxt, refresh, ensureDevAuthToken }) {
|
|
123
124
|
let builds = [];
|
|
124
125
|
let promise;
|
|
@@ -197,7 +198,7 @@ function setupAnalyzeBuildRPC({ nuxt, refresh, ensureDevAuthToken }) {
|
|
|
197
198
|
return `${branchName}#${sha}`;
|
|
198
199
|
return `${branchName}#${sha}-dirty`;
|
|
199
200
|
} catch {
|
|
200
|
-
return (/* @__PURE__ */ new Date()).toISOString().replace(
|
|
201
|
+
return (/* @__PURE__ */ new Date()).toISOString().replace(COLON_RE, "-");
|
|
201
202
|
}
|
|
202
203
|
}
|
|
203
204
|
return {
|
|
@@ -7000,7 +7001,7 @@ codes.ERR_INVALID_ARG_TYPE = createError(
|
|
|
7000
7001
|
* @param {unknown} actual
|
|
7001
7002
|
*/
|
|
7002
7003
|
(name, expected, actual) => {
|
|
7003
|
-
assert(typeof name === 'string', "'name' must be a string");
|
|
7004
|
+
assert.ok(typeof name === 'string', "'name' must be a string");
|
|
7004
7005
|
if (!Array.isArray(expected)) {
|
|
7005
7006
|
expected = [expected];
|
|
7006
7007
|
}
|
|
@@ -7024,7 +7025,7 @@ codes.ERR_INVALID_ARG_TYPE = createError(
|
|
|
7024
7025
|
const other = [];
|
|
7025
7026
|
|
|
7026
7027
|
for (const value of expected) {
|
|
7027
|
-
assert(
|
|
7028
|
+
assert.ok(
|
|
7028
7029
|
typeof value === 'string',
|
|
7029
7030
|
'All expected entries have to be of type string'
|
|
7030
7031
|
);
|
|
@@ -7032,7 +7033,7 @@ codes.ERR_INVALID_ARG_TYPE = createError(
|
|
|
7032
7033
|
if (kTypes.has(value)) {
|
|
7033
7034
|
types.push(value.toLowerCase());
|
|
7034
7035
|
} else if (classRegExp.exec(value) === null) {
|
|
7035
|
-
assert(
|
|
7036
|
+
assert.ok(
|
|
7036
7037
|
value !== 'object',
|
|
7037
7038
|
'The value "object" should be written as "Object"'
|
|
7038
7039
|
);
|
|
@@ -7127,7 +7128,7 @@ codes.ERR_INVALID_PACKAGE_TARGET = createError(
|
|
|
7127
7128
|
target.length > 0 &&
|
|
7128
7129
|
!target.startsWith('./');
|
|
7129
7130
|
if (key === '.') {
|
|
7130
|
-
assert(isImport === false);
|
|
7131
|
+
assert.ok(isImport === false);
|
|
7131
7132
|
return (
|
|
7132
7133
|
`Invalid "exports" main target ${JSON.stringify(target)} defined ` +
|
|
7133
7134
|
`in the package config ${packagePath}package.json${
|
|
@@ -7377,10 +7378,10 @@ const captureLargerStackTrace = hideStackFrames(
|
|
|
7377
7378
|
*/
|
|
7378
7379
|
function getMessage(key, parameters, self) {
|
|
7379
7380
|
const message = messages.get(key);
|
|
7380
|
-
assert(message !== undefined, 'expected `message` to be found');
|
|
7381
|
+
assert.ok(message !== undefined, 'expected `message` to be found');
|
|
7381
7382
|
|
|
7382
7383
|
if (typeof message === 'function') {
|
|
7383
|
-
assert(
|
|
7384
|
+
assert.ok(
|
|
7384
7385
|
message.length <= parameters.length, // Default options do not count.
|
|
7385
7386
|
`Code: ${key}; The provided arguments length (${parameters.length}) does not ` +
|
|
7386
7387
|
`match the required ones (${message.length}).`
|
|
@@ -7391,7 +7392,7 @@ function getMessage(key, parameters, self) {
|
|
|
7391
7392
|
const regex = /%[dfijoOs]/g;
|
|
7392
7393
|
let expectedLength = 0;
|
|
7393
7394
|
while (regex.exec(message) !== null) expectedLength++;
|
|
7394
|
-
assert(
|
|
7395
|
+
assert.ok(
|
|
7395
7396
|
expectedLength === parameters.length,
|
|
7396
7397
|
`Code: ${key}; The provided arguments length (${parameters.length}) does not ` +
|
|
7397
7398
|
`match the required ones (${expectedLength}).`
|
|
@@ -7435,7 +7436,7 @@ function determineSpecificType(value) {
|
|
|
7435
7436
|
|
|
7436
7437
|
// Manually “tree shaken” from:
|
|
7437
7438
|
// <https://github.com/nodejs/node/blob/7c3dce0/lib/internal/modules/package_json_reader.js>
|
|
7438
|
-
// Last checked on: Apr 29,
|
|
7439
|
+
// Last checked on: Apr 29, 2024.
|
|
7439
7440
|
// Removed the native dependency.
|
|
7440
7441
|
// Also: no need to cache, we do that in resolve already.
|
|
7441
7442
|
|
|
@@ -7594,7 +7595,7 @@ function getPackageType(url) {
|
|
|
7594
7595
|
|
|
7595
7596
|
// Manually “tree shaken” from:
|
|
7596
7597
|
// <https://github.com/nodejs/node/blob/7c3dce0/lib/internal/modules/esm/get_format.js>
|
|
7597
|
-
// Last checked on: Apr 29,
|
|
7598
|
+
// Last checked on: Apr 29, 2024.
|
|
7598
7599
|
|
|
7599
7600
|
|
|
7600
7601
|
const {ERR_UNKNOWN_FILE_EXTENSION} = codes;
|
|
@@ -7749,9 +7750,36 @@ function defaultGetFormatWithoutErrors(url, context) {
|
|
|
7749
7750
|
return protocolHandlers[protocol](url, context, true) || null
|
|
7750
7751
|
}
|
|
7751
7752
|
|
|
7753
|
+
// Manually “tree shaken” from:
|
|
7754
|
+
// <https://github.com/nodejs/node/blob/81a9a97/lib/internal/modules/esm/utils.js>
|
|
7755
|
+
// Last checked on: Apr 29, 2024.
|
|
7756
|
+
|
|
7757
|
+
|
|
7758
|
+
// In Node itself these values are populated from CLI arguments, before any
|
|
7759
|
+
// user code runs.
|
|
7760
|
+
// Here we just define the defaults.
|
|
7761
|
+
const DEFAULT_CONDITIONS = Object.freeze(['node', 'import']);
|
|
7762
|
+
const DEFAULT_CONDITIONS_SET$1 = new Set(DEFAULT_CONDITIONS);
|
|
7763
|
+
|
|
7764
|
+
/**
|
|
7765
|
+
* Returns the default conditions for ES module loading, as a Set.
|
|
7766
|
+
*/
|
|
7767
|
+
function getDefaultConditionsSet() {
|
|
7768
|
+
return DEFAULT_CONDITIONS_SET$1
|
|
7769
|
+
}
|
|
7770
|
+
|
|
7771
|
+
/**
|
|
7772
|
+
* @param {Array<string>} [conditions]
|
|
7773
|
+
* @returns {Set<string>}
|
|
7774
|
+
*/
|
|
7775
|
+
function getConditionsSet(conditions) {
|
|
7776
|
+
|
|
7777
|
+
return getDefaultConditionsSet()
|
|
7778
|
+
}
|
|
7779
|
+
|
|
7752
7780
|
// Manually “tree shaken” from:
|
|
7753
7781
|
// <https://github.com/nodejs/node/blob/81a9a97/lib/internal/modules/esm/resolve.js>
|
|
7754
|
-
// Last checked on: Apr 29,
|
|
7782
|
+
// Last checked on: Apr 29, 2024.
|
|
7755
7783
|
|
|
7756
7784
|
|
|
7757
7785
|
const RegExpPrototypeSymbolReplace = RegExp.prototype[Symbol.replace];
|
|
@@ -7839,7 +7867,7 @@ function emitLegacyIndexDeprecation(url, packageJsonUrl, base, main) {
|
|
|
7839
7867
|
const format = defaultGetFormatWithoutErrors(url, {parentURL: base.href});
|
|
7840
7868
|
if (format !== 'module') return
|
|
7841
7869
|
const urlPath = fileURLToPath$1(url.href);
|
|
7842
|
-
const packagePath = fileURLToPath$1(new URL
|
|
7870
|
+
const packagePath = fileURLToPath$1(new URL('.', packageJsonUrl));
|
|
7843
7871
|
const basePath = fileURLToPath$1(base);
|
|
7844
7872
|
if (!main) {
|
|
7845
7873
|
process$1.emitWarning(
|
|
@@ -7905,7 +7933,7 @@ function legacyMainResolve(packageJsonUrl, packageConfig, base) {
|
|
|
7905
7933
|
/** @type {URL | undefined} */
|
|
7906
7934
|
let guess;
|
|
7907
7935
|
if (packageConfig.main !== undefined) {
|
|
7908
|
-
guess = new URL
|
|
7936
|
+
guess = new URL(packageConfig.main, packageJsonUrl);
|
|
7909
7937
|
// Note: fs check redundances will be handled by Descriptor cache here.
|
|
7910
7938
|
if (fileExists(guess)) return guess
|
|
7911
7939
|
|
|
@@ -7920,7 +7948,7 @@ function legacyMainResolve(packageJsonUrl, packageConfig, base) {
|
|
|
7920
7948
|
let i = -1;
|
|
7921
7949
|
|
|
7922
7950
|
while (++i < tries.length) {
|
|
7923
|
-
guess = new URL
|
|
7951
|
+
guess = new URL(tries[i], packageJsonUrl);
|
|
7924
7952
|
if (fileExists(guess)) break
|
|
7925
7953
|
guess = undefined;
|
|
7926
7954
|
}
|
|
@@ -7941,7 +7969,7 @@ function legacyMainResolve(packageJsonUrl, packageConfig, base) {
|
|
|
7941
7969
|
let i = -1;
|
|
7942
7970
|
|
|
7943
7971
|
while (++i < tries.length) {
|
|
7944
|
-
guess = new URL
|
|
7972
|
+
guess = new URL(tries[i], packageJsonUrl);
|
|
7945
7973
|
if (fileExists(guess)) break
|
|
7946
7974
|
guess = undefined;
|
|
7947
7975
|
}
|
|
@@ -7953,7 +7981,7 @@ function legacyMainResolve(packageJsonUrl, packageConfig, base) {
|
|
|
7953
7981
|
|
|
7954
7982
|
// Not found.
|
|
7955
7983
|
throw new ERR_MODULE_NOT_FOUND(
|
|
7956
|
-
fileURLToPath$1(new URL
|
|
7984
|
+
fileURLToPath$1(new URL('.', packageJsonUrl)),
|
|
7957
7985
|
fileURLToPath$1(base)
|
|
7958
7986
|
)
|
|
7959
7987
|
}
|
|
@@ -8027,7 +8055,7 @@ function finalizeResolution(resolved, base, preserveSymlinks) {
|
|
|
8027
8055
|
function importNotDefined(specifier, packageJsonUrl, base) {
|
|
8028
8056
|
return new ERR_PACKAGE_IMPORT_NOT_DEFINED(
|
|
8029
8057
|
specifier,
|
|
8030
|
-
packageJsonUrl && fileURLToPath$1(new URL
|
|
8058
|
+
packageJsonUrl && fileURLToPath$1(new URL('.', packageJsonUrl)),
|
|
8031
8059
|
fileURLToPath$1(base)
|
|
8032
8060
|
)
|
|
8033
8061
|
}
|
|
@@ -8040,7 +8068,7 @@ function importNotDefined(specifier, packageJsonUrl, base) {
|
|
|
8040
8068
|
*/
|
|
8041
8069
|
function exportsNotFound(subpath, packageJsonUrl, base) {
|
|
8042
8070
|
return new ERR_PACKAGE_PATH_NOT_EXPORTED(
|
|
8043
|
-
fileURLToPath$1(new URL
|
|
8071
|
+
fileURLToPath$1(new URL('.', packageJsonUrl)),
|
|
8044
8072
|
subpath,
|
|
8045
8073
|
base && fileURLToPath$1(base)
|
|
8046
8074
|
)
|
|
@@ -8080,7 +8108,7 @@ function invalidPackageTarget(subpath, target, packageJsonUrl, internal, base) {
|
|
|
8080
8108
|
: `${target}`;
|
|
8081
8109
|
|
|
8082
8110
|
return new ERR_INVALID_PACKAGE_TARGET(
|
|
8083
|
-
fileURLToPath$1(new URL
|
|
8111
|
+
fileURLToPath$1(new URL('.', packageJsonUrl)),
|
|
8084
8112
|
subpath,
|
|
8085
8113
|
target,
|
|
8086
8114
|
internal,
|
|
@@ -8119,7 +8147,7 @@ function resolvePackageTargetString(
|
|
|
8119
8147
|
let isURL = false;
|
|
8120
8148
|
|
|
8121
8149
|
try {
|
|
8122
|
-
new URL
|
|
8150
|
+
new URL(target);
|
|
8123
8151
|
isURL = true;
|
|
8124
8152
|
} catch {
|
|
8125
8153
|
// Continue regardless of error.
|
|
@@ -8169,9 +8197,9 @@ function resolvePackageTargetString(
|
|
|
8169
8197
|
}
|
|
8170
8198
|
}
|
|
8171
8199
|
|
|
8172
|
-
const resolved = new URL
|
|
8200
|
+
const resolved = new URL(target, packageJsonUrl);
|
|
8173
8201
|
const resolvedPath = resolved.pathname;
|
|
8174
|
-
const packagePath = new URL
|
|
8202
|
+
const packagePath = new URL('.', packageJsonUrl).pathname;
|
|
8175
8203
|
|
|
8176
8204
|
if (!resolvedPath.startsWith(packagePath))
|
|
8177
8205
|
throw invalidPackageTarget(match, target, packageJsonUrl, internal, base)
|
|
@@ -8207,7 +8235,7 @@ function resolvePackageTargetString(
|
|
|
8207
8235
|
}
|
|
8208
8236
|
|
|
8209
8237
|
if (pattern) {
|
|
8210
|
-
return new URL
|
|
8238
|
+
return new URL(
|
|
8211
8239
|
RegExpPrototypeSymbolReplace.call(
|
|
8212
8240
|
patternRegEx,
|
|
8213
8241
|
resolved.href,
|
|
@@ -8216,7 +8244,7 @@ function resolvePackageTargetString(
|
|
|
8216
8244
|
)
|
|
8217
8245
|
}
|
|
8218
8246
|
|
|
8219
|
-
return new URL
|
|
8247
|
+
return new URL(subpath, resolved)
|
|
8220
8248
|
}
|
|
8221
8249
|
|
|
8222
8250
|
/**
|
|
@@ -8695,7 +8723,7 @@ function parsePackageName(specifier, base) {
|
|
|
8695
8723
|
*/
|
|
8696
8724
|
function packageResolve(specifier, base, conditions) {
|
|
8697
8725
|
if (builtinModules.includes(specifier)) {
|
|
8698
|
-
return new URL
|
|
8726
|
+
return new URL('node:' + specifier)
|
|
8699
8727
|
}
|
|
8700
8728
|
|
|
8701
8729
|
const {packageName, packageSubpath, isScoped} = parsePackageName(
|
|
@@ -8725,7 +8753,7 @@ function packageResolve(specifier, base, conditions) {
|
|
|
8725
8753
|
}
|
|
8726
8754
|
}
|
|
8727
8755
|
|
|
8728
|
-
let packageJsonUrl = new URL
|
|
8756
|
+
let packageJsonUrl = new URL(
|
|
8729
8757
|
'./node_modules/' + packageName + '/package.json',
|
|
8730
8758
|
base
|
|
8731
8759
|
);
|
|
@@ -8736,7 +8764,7 @@ function packageResolve(specifier, base, conditions) {
|
|
|
8736
8764
|
const stat = tryStatSync(packageJsonPath.slice(0, -13));
|
|
8737
8765
|
if (!stat || !stat.isDirectory()) {
|
|
8738
8766
|
lastPath = packageJsonPath;
|
|
8739
|
-
packageJsonUrl = new URL
|
|
8767
|
+
packageJsonUrl = new URL(
|
|
8740
8768
|
(isScoped ? '../../../../node_modules/' : '../../../node_modules/') +
|
|
8741
8769
|
packageName +
|
|
8742
8770
|
'/package.json',
|
|
@@ -8762,7 +8790,7 @@ function packageResolve(specifier, base, conditions) {
|
|
|
8762
8790
|
return legacyMainResolve(packageJsonUrl, packageConfig, base)
|
|
8763
8791
|
}
|
|
8764
8792
|
|
|
8765
|
-
return new URL
|
|
8793
|
+
return new URL(packageSubpath, packageJsonUrl)
|
|
8766
8794
|
// Cross-platform root check.
|
|
8767
8795
|
} while (packageJsonPath.length !== lastPath.length)
|
|
8768
8796
|
|
|
@@ -8815,6 +8843,10 @@ function shouldBeTreatedAsRelativeOrAbsolutePath(specifier) {
|
|
|
8815
8843
|
function moduleResolve(specifier, base, conditions, preserveSymlinks) {
|
|
8816
8844
|
// Note: The Node code supports `base` as a string (in this internal API) too,
|
|
8817
8845
|
// we don’t.
|
|
8846
|
+
if (conditions === undefined) {
|
|
8847
|
+
conditions = getConditionsSet();
|
|
8848
|
+
}
|
|
8849
|
+
|
|
8818
8850
|
const protocol = base.protocol;
|
|
8819
8851
|
const isData = protocol === 'data:';
|
|
8820
8852
|
const isRemote = isData || protocol === 'http:' || protocol === 'https:';
|
|
@@ -8825,7 +8857,7 @@ function moduleResolve(specifier, base, conditions, preserveSymlinks) {
|
|
|
8825
8857
|
|
|
8826
8858
|
if (shouldBeTreatedAsRelativeOrAbsolutePath(specifier)) {
|
|
8827
8859
|
try {
|
|
8828
|
-
resolved = new URL
|
|
8860
|
+
resolved = new URL(specifier, base);
|
|
8829
8861
|
} catch (error_) {
|
|
8830
8862
|
const error = new ERR_UNSUPPORTED_RESOLVE_REQUEST(specifier, base);
|
|
8831
8863
|
error.cause = error_;
|
|
@@ -8835,7 +8867,7 @@ function moduleResolve(specifier, base, conditions, preserveSymlinks) {
|
|
|
8835
8867
|
resolved = packageImportsResolve(specifier, base, conditions);
|
|
8836
8868
|
} else {
|
|
8837
8869
|
try {
|
|
8838
|
-
resolved = new URL
|
|
8870
|
+
resolved = new URL(specifier);
|
|
8839
8871
|
} catch (error_) {
|
|
8840
8872
|
// Note: actual code uses `canBeRequiredWithoutScheme`.
|
|
8841
8873
|
if (isRemote && !builtinModules.includes(specifier)) {
|
|
@@ -8848,7 +8880,7 @@ function moduleResolve(specifier, base, conditions, preserveSymlinks) {
|
|
|
8848
8880
|
}
|
|
8849
8881
|
}
|
|
8850
8882
|
|
|
8851
|
-
assert(resolved !== undefined, 'expected to be defined');
|
|
8883
|
+
assert.ok(resolved !== undefined, 'expected to be defined');
|
|
8852
8884
|
|
|
8853
8885
|
if (resolved.protocol !== 'file:') {
|
|
8854
8886
|
return resolved
|
|
@@ -9000,6 +9032,60 @@ const EXPORT_STAR_RE = /\bexport\s*\*(?:\s*as\s+(?<name>[\w$]+)\s+)?\s*(?:\s*fro
|
|
|
9000
9032
|
const EXPORT_DEFAULT_RE = /\bexport\s+default\s+(async function|function|class|true|false|\W|\d)|\bexport\s+default\s+(?<defaultName>.*)/g;
|
|
9001
9033
|
const EXPORT_DEFAULT_CLASS_RE = /\bexport\s+default\s+(?<declaration>class)\s+(?<name>[\w$]+)/g;
|
|
9002
9034
|
const TYPE_RE = /^\s*?type\s/;
|
|
9035
|
+
function _extractExtraNames(extraNamesStr) {
|
|
9036
|
+
const names = [];
|
|
9037
|
+
let depth = 0;
|
|
9038
|
+
let angleDepth = 0;
|
|
9039
|
+
let inString = false;
|
|
9040
|
+
let inTypeAnnotation = false;
|
|
9041
|
+
for (let i = 0; i < extraNamesStr.length; i++) {
|
|
9042
|
+
const char = extraNamesStr[i];
|
|
9043
|
+
if (inString) {
|
|
9044
|
+
if (char === inString) {
|
|
9045
|
+
let backslashCount = 0;
|
|
9046
|
+
for (let j = i - 1; j >= 0 && extraNamesStr[j] === "\\"; j--) {
|
|
9047
|
+
backslashCount++;
|
|
9048
|
+
}
|
|
9049
|
+
if (backslashCount % 2 === 0) {
|
|
9050
|
+
inString = false;
|
|
9051
|
+
}
|
|
9052
|
+
}
|
|
9053
|
+
continue;
|
|
9054
|
+
}
|
|
9055
|
+
if (char === '"' || char === "'" || char === "`") {
|
|
9056
|
+
inString = char;
|
|
9057
|
+
continue;
|
|
9058
|
+
}
|
|
9059
|
+
if (char === ":" && depth === 0 && angleDepth === 0) {
|
|
9060
|
+
inTypeAnnotation = true;
|
|
9061
|
+
continue;
|
|
9062
|
+
}
|
|
9063
|
+
if (char === "=" && extraNamesStr[i + 1] !== ">" && depth === 0 && angleDepth === 0) {
|
|
9064
|
+
inTypeAnnotation = false;
|
|
9065
|
+
}
|
|
9066
|
+
if (inTypeAnnotation && char === "<") {
|
|
9067
|
+
angleDepth++;
|
|
9068
|
+
continue;
|
|
9069
|
+
}
|
|
9070
|
+
if (inTypeAnnotation && char === ">" && angleDepth > 0) {
|
|
9071
|
+
angleDepth--;
|
|
9072
|
+
continue;
|
|
9073
|
+
}
|
|
9074
|
+
if (char === "(" || char === "[" || char === "{") {
|
|
9075
|
+
depth++;
|
|
9076
|
+
} else if (char === ")" || char === "]" || char === "}") {
|
|
9077
|
+
depth--;
|
|
9078
|
+
}
|
|
9079
|
+
if (char === "," && depth === 0 && angleDepth === 0) {
|
|
9080
|
+
const rest = extraNamesStr.slice(i + 1);
|
|
9081
|
+
const match = rest.match(/^\s*([\w$]+)/);
|
|
9082
|
+
if (match) {
|
|
9083
|
+
names.push(match[1]);
|
|
9084
|
+
}
|
|
9085
|
+
}
|
|
9086
|
+
}
|
|
9087
|
+
return names;
|
|
9088
|
+
}
|
|
9003
9089
|
function findExports(code) {
|
|
9004
9090
|
const declaredExports = matchAll(EXPORT_DECAL_RE, code, {
|
|
9005
9091
|
type: "declaration"
|
|
@@ -9010,12 +9096,10 @@ function findExports(code) {
|
|
|
9010
9096
|
}
|
|
9011
9097
|
const extraNamesStr = declaredExport.extraNames;
|
|
9012
9098
|
if (extraNamesStr) {
|
|
9013
|
-
const extraNames =
|
|
9014
|
-
|
|
9015
|
-
|
|
9016
|
-
|
|
9017
|
-
).map((m) => m.name).filter(Boolean);
|
|
9018
|
-
declaredExport.names = [declaredExport.name, ...extraNames];
|
|
9099
|
+
const extraNames = _extractExtraNames(extraNamesStr);
|
|
9100
|
+
if (extraNames.length > 0) {
|
|
9101
|
+
declaredExport.names = [declaredExport.name, ...extraNames];
|
|
9102
|
+
}
|
|
9019
9103
|
}
|
|
9020
9104
|
delete declaredExport.extraNames;
|
|
9021
9105
|
}
|
|
@@ -10116,6 +10200,7 @@ async function resolveBuiltinPresets(presets) {
|
|
|
10116
10200
|
return resolved.flat();
|
|
10117
10201
|
}
|
|
10118
10202
|
|
|
10203
|
+
const VALID_IDENTIFIER_RE = /^[a-z_$][\w$]*$/i;
|
|
10119
10204
|
function toJsLiteral(value, seen = /* @__PURE__ */ new Set()) {
|
|
10120
10205
|
if (value === null) {
|
|
10121
10206
|
return "null";
|
|
@@ -10164,8 +10249,7 @@ function toJsLiteral(value, seen = /* @__PURE__ */ new Set()) {
|
|
|
10164
10249
|
return JSON.stringify(value);
|
|
10165
10250
|
}
|
|
10166
10251
|
function safeKey(key) {
|
|
10167
|
-
|
|
10168
|
-
if (validIdentifier.test(key)) {
|
|
10252
|
+
if (VALID_IDENTIFIER_RE.test(key)) {
|
|
10169
10253
|
return key;
|
|
10170
10254
|
}
|
|
10171
10255
|
return JSON.stringify(key);
|
|
@@ -10219,6 +10303,9 @@ function setupOptionsRPC({ nuxt }) {
|
|
|
10219
10303
|
};
|
|
10220
10304
|
}
|
|
10221
10305
|
|
|
10306
|
+
const ABSOLUTE_PATH_RE = /^[a-z]:|^\//i;
|
|
10307
|
+
const FILE_LINE_COL_RE = /^(.*?)(:[:\d]*)$/;
|
|
10308
|
+
const MULTIPLE_SLASHES_RE$1 = /\/+/g;
|
|
10222
10309
|
function setupGeneralRPC({
|
|
10223
10310
|
nuxt,
|
|
10224
10311
|
options,
|
|
@@ -10256,7 +10343,7 @@ function setupGeneralRPC({
|
|
|
10256
10343
|
page.children?.forEach(searchChildren);
|
|
10257
10344
|
}
|
|
10258
10345
|
v.forEach(searchChildren);
|
|
10259
|
-
serverPages.push(...
|
|
10346
|
+
serverPages.push(...[...pagesSet].toSorted((a, b) => a.path.localeCompare(b.path)));
|
|
10260
10347
|
refresh("getServerPages");
|
|
10261
10348
|
});
|
|
10262
10349
|
nuxt.hook("app:resolve", (app2) => {
|
|
@@ -10373,9 +10460,9 @@ function setupGeneralRPC({
|
|
|
10373
10460
|
return Object.values(serverHooks);
|
|
10374
10461
|
},
|
|
10375
10462
|
async openInEditor(input) {
|
|
10376
|
-
if (input.startsWith("./") || !
|
|
10463
|
+
if (input.startsWith("./") || !ABSOLUTE_PATH_RE.test(input))
|
|
10377
10464
|
input = resolve(process.cwd(), input);
|
|
10378
|
-
const match = input.match(
|
|
10465
|
+
const match = input.match(FILE_LINE_COL_RE);
|
|
10379
10466
|
let suffix = "";
|
|
10380
10467
|
if (match) {
|
|
10381
10468
|
input = match[1];
|
|
@@ -10417,7 +10504,7 @@ function setupGeneralRPC({
|
|
|
10417
10504
|
return;
|
|
10418
10505
|
const token = await getDevAuthToken();
|
|
10419
10506
|
origin ||= `${nuxt.options.devServer.https ? "https" : "http"}://${nuxt.options.devServer.host === "::" ? "localhost" : nuxt.options.devServer.host || "localhost"}:${nuxt.options.devServer.port}`;
|
|
10420
|
-
const ROUTE_AUTH = `${nuxt.options.app.baseURL || "/"}/__nuxt_devtools__/auth`.replace(
|
|
10507
|
+
const ROUTE_AUTH = `${nuxt.options.app.baseURL || "/"}/__nuxt_devtools__/auth`.replace(MULTIPLE_SLASHES_RE$1, "/");
|
|
10421
10508
|
const message = [
|
|
10422
10509
|
`A browser is requesting permissions of ${colors.bold(colors.yellow("writing files and running commands"))} from the DevTools UI.`,
|
|
10423
10510
|
colors.bold(info || "Unknown"),
|
|
@@ -10923,8 +11010,7 @@ function setupNpmRPC({ nuxt, ensureDevAuthToken }) {
|
|
|
10923
11010
|
const commands = await getNpmCommand("install", name, { dev: true });
|
|
10924
11011
|
const filepath = nuxt.options._nuxtConfigFile;
|
|
10925
11012
|
let source = latestGenerated;
|
|
10926
|
-
|
|
10927
|
-
source = await fsp.readFile(filepath, "utf-8");
|
|
11013
|
+
source ??= await fsp.readFile(filepath, "utf-8");
|
|
10928
11014
|
const generated = await magicastGuard(async () => {
|
|
10929
11015
|
const mod = parseModule(source, { sourceFileName: filepath });
|
|
10930
11016
|
addNuxtModule(mod, name);
|
|
@@ -11373,7 +11459,7 @@ function setupTerminalRPC({ nuxt, rpc, refresh, ensureDevAuthToken }) {
|
|
|
11373
11459
|
}
|
|
11374
11460
|
return {
|
|
11375
11461
|
getTerminals() {
|
|
11376
|
-
return Array.from(terminals.values()
|
|
11462
|
+
return Array.from(terminals.values(), (i) => serializeTerminal(i));
|
|
11377
11463
|
},
|
|
11378
11464
|
async getTerminalDetail(token, id) {
|
|
11379
11465
|
await ensureDevAuthToken(token);
|
|
@@ -11434,6 +11520,7 @@ function setupTimelineRPC({ nuxt }) {
|
|
|
11434
11520
|
|
|
11435
11521
|
const LOG_PREFIX = colors.cyan("Nuxt DevTools:");
|
|
11436
11522
|
|
|
11523
|
+
const NUXT_WELCOME_RE = /<NuxtWelcome\s*\/>/;
|
|
11437
11524
|
const pagesIndexTemplate = `<script setup lang="ts">
|
|
11438
11525
|
const route = useRoute()
|
|
11439
11526
|
<\/script>
|
|
@@ -11458,7 +11545,7 @@ async function enablePages(nuxt) {
|
|
|
11458
11545
|
await fsp.mkdir(dirname$1(pathPageIndex), { recursive: true });
|
|
11459
11546
|
await fsp.writeFile(pathPageIndex, pagesIndexTemplate, "utf-8");
|
|
11460
11547
|
if (appContent && !appContent.includes("<NuxtPage")) {
|
|
11461
|
-
appContent = appContent.replace("</template>", " <NuxtPage />\n</template>").replace(
|
|
11548
|
+
appContent = appContent.replace("</template>", " <NuxtPage />\n</template>").replace(NUXT_WELCOME_RE, "");
|
|
11462
11549
|
await fsp.writeFile(pathApp, appContent, "utf-8");
|
|
11463
11550
|
}
|
|
11464
11551
|
logger.success("Routing creation wizard completed");
|
|
@@ -11594,6 +11681,8 @@ function setupRPC(nuxt, options) {
|
|
|
11594
11681
|
};
|
|
11595
11682
|
}
|
|
11596
11683
|
|
|
11684
|
+
const MULTIPLE_SLASHES_RE = /\/+/g;
|
|
11685
|
+
const DEVTOOLS_BASE_RE = /\/__NUXT_DEVTOOLS_BASE__\//g;
|
|
11597
11686
|
async function enableModule(options, nuxt) {
|
|
11598
11687
|
if (process.env.TEST || process.env.NODE_ENV === "test" || nuxt.options.test)
|
|
11599
11688
|
return;
|
|
@@ -11606,7 +11695,7 @@ async function enableModule(options, nuxt) {
|
|
|
11606
11695
|
await import('./analyze-build.mjs').then(({ setup }) => setup(nuxt, options));
|
|
11607
11696
|
return;
|
|
11608
11697
|
}
|
|
11609
|
-
const enabledExplicitly = nuxt.options.devtools === true || nuxt.options.devtools && nuxt.options.devtools.enabled ||
|
|
11698
|
+
const enabledExplicitly = nuxt.options.devtools === true || nuxt.options.devtools && nuxt.options.devtools.enabled || nuxt.options.modules.some((m) => m === "@nuxt/devtools" || m === "@nuxt/devtools-edge" || m === "@nuxt/devtools-nightly");
|
|
11610
11699
|
await nuxt.callHook("devtools:before");
|
|
11611
11700
|
if (options.iframeProps) {
|
|
11612
11701
|
nuxt.options.runtimeConfig.app.devtools ||= {};
|
|
@@ -11705,7 +11794,7 @@ window.__NUXT_DEVTOOLS_TIME_METRIC__.appInit = Date.now()
|
|
|
11705
11794
|
name: "useNuxtDevTools",
|
|
11706
11795
|
from: join(runtimeDir, "use-nuxt-devtools")
|
|
11707
11796
|
});
|
|
11708
|
-
const ROUTE_PATH = `${nuxt.options.app.baseURL || "/"}/__nuxt_devtools__`.replace(
|
|
11797
|
+
const ROUTE_PATH = `${nuxt.options.app.baseURL || "/"}/__nuxt_devtools__`.replace(MULTIPLE_SLASHES_RE, "/");
|
|
11709
11798
|
const ROUTE_CLIENT = `${ROUTE_PATH}/client`;
|
|
11710
11799
|
const ROUTE_AUTH = `${ROUTE_PATH}/auth`;
|
|
11711
11800
|
const ROUTE_AUTH_VERIFY = `${ROUTE_PATH}/auth-verify`;
|
|
@@ -11723,7 +11812,7 @@ window.__NUXT_DEVTOOLS_TIME_METRIC__.appInit = Date.now()
|
|
|
11723
11812
|
const handleIndex = async (res) => {
|
|
11724
11813
|
res.setHeader("Content-Type", "text/html");
|
|
11725
11814
|
res.statusCode = 200;
|
|
11726
|
-
res.write((await indexContent).replace(
|
|
11815
|
+
res.write((await indexContent).replace(DEVTOOLS_BASE_RE, `${ROUTE_CLIENT}/`));
|
|
11727
11816
|
res.end();
|
|
11728
11817
|
};
|
|
11729
11818
|
server.middlewares.use(ROUTE_CLIENT, (req, res) => {
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
const IMPORT_RE = /(?:\n|^)import (.*) from ['"](.*)['"]/g;
|
|
2
|
+
const EXPORT_DEFAULT_ARRAY_RE = /\nexport default\s*\[([\s\S]*)\]/;
|
|
1
3
|
function setup({ nuxt }) {
|
|
2
4
|
if (!nuxt.options.dev || nuxt.options.test)
|
|
3
5
|
return;
|
|
@@ -42,8 +44,8 @@ function ${WRAPPER_KEY} (plugin, src) {
|
|
|
42
44
|
})
|
|
43
45
|
}
|
|
44
46
|
`;
|
|
45
|
-
const imports = Array.from(content.matchAll(
|
|
46
|
-
content = content.replace(
|
|
47
|
+
const imports = Array.from(content.matchAll(IMPORT_RE), ([, name, path]) => ({ name, path }));
|
|
48
|
+
content = content.replace(EXPORT_DEFAULT_ARRAY_RE, (_, itemsRaw) => {
|
|
47
49
|
const items = itemsRaw.split(",").map((i2) => i2.trim()).map((i2) => {
|
|
48
50
|
const importItem = imports.find(({ name }) => name === i2);
|
|
49
51
|
if (!importItem)
|
package/dist/chunks/timeline.mjs
CHANGED
|
@@ -5,6 +5,7 @@ import 'node:path';
|
|
|
5
5
|
import 'node:url';
|
|
6
6
|
import 'is-installed-globally';
|
|
7
7
|
|
|
8
|
+
const DEFINE_UPPER_RE = /^define[A-Z]/;
|
|
8
9
|
function setup({ nuxt, options }) {
|
|
9
10
|
const helperPath = resolve(runtimeDir, "function-metrics-helpers");
|
|
10
11
|
const includeFrom = options.timeline?.functions?.includeFrom || [
|
|
@@ -16,7 +17,7 @@ function setup({ nuxt, options }) {
|
|
|
16
17
|
(i) => i.from.includes("composables")
|
|
17
18
|
];
|
|
18
19
|
const exclude = options.timeline?.functions?.exclude || [
|
|
19
|
-
|
|
20
|
+
DEFINE_UPPER_RE
|
|
20
21
|
];
|
|
21
22
|
function filter(item) {
|
|
22
23
|
if (item.type)
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
import { addCustomTab } from '@nuxt/devtools-kit';
|
|
2
2
|
import { addVitePlugin } from '@nuxt/kit';
|
|
3
3
|
|
|
4
|
+
const DOUBLE_SLASH_RE = /\/\//g;
|
|
5
|
+
const VERSION_QUERY_RE = /\?v=\w+$/;
|
|
6
|
+
const VUE_EXT_RE = /\.vue($|\?v=)/;
|
|
4
7
|
async function createVitePluginInspect(options) {
|
|
5
8
|
return await import('vite-plugin-inspect').then((r) => r.default(options));
|
|
6
9
|
}
|
|
@@ -18,7 +21,7 @@ async function setup({ nuxt, rpc }) {
|
|
|
18
21
|
category: "advanced",
|
|
19
22
|
view: {
|
|
20
23
|
type: "iframe",
|
|
21
|
-
src: `${nuxt.options.app.baseURL}${nuxt.options.app.buildAssetsDir}/__inspect/`.replace(
|
|
24
|
+
src: `${nuxt.options.app.baseURL}${nuxt.options.app.buildAssetsDir}/__inspect/`.replace(DOUBLE_SLASH_RE, "/")
|
|
22
25
|
}
|
|
23
26
|
}), nuxt);
|
|
24
27
|
async function getComponentsRelationships() {
|
|
@@ -29,10 +32,10 @@ async function setup({ nuxt, rpc }) {
|
|
|
29
32
|
}) : null) || [];
|
|
30
33
|
const components = await rpc.functions.getComponents() || [];
|
|
31
34
|
const vueModules = modules.filter((m) => {
|
|
32
|
-
const plainId = m.id.replace(
|
|
35
|
+
const plainId = m.id.replace(VERSION_QUERY_RE, "");
|
|
33
36
|
if (components.some((c) => c.filePath === plainId))
|
|
34
37
|
return true;
|
|
35
|
-
return m.id.match(
|
|
38
|
+
return m.id.match(VUE_EXT_RE);
|
|
36
39
|
});
|
|
37
40
|
const graph = vueModules.map((i) => {
|
|
38
41
|
function searchForVueDeps(id, seen = /* @__PURE__ */ new Set()) {
|
|
@@ -43,7 +46,7 @@ async function setup({ nuxt, rpc }) {
|
|
|
43
46
|
if (!module)
|
|
44
47
|
return [];
|
|
45
48
|
return module.deps.flatMap((i2) => {
|
|
46
|
-
if (vueModules.
|
|
49
|
+
if (vueModules.some((m) => m.id === i2))
|
|
47
50
|
return [i2];
|
|
48
51
|
return searchForVueDeps(i2, seen);
|
|
49
52
|
});
|
package/dist/client/200.html
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
<!DOCTYPE html><html><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1"><script type="importmap">{"imports":{"#entry":"/__NUXT_DEVTOOLS_BASE__/_nuxt/
|
|
1
|
+
<!DOCTYPE html><html><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1"><script type="importmap">{"imports":{"#entry":"/__NUXT_DEVTOOLS_BASE__/_nuxt/kzt4clis.js"}}</script><link rel="stylesheet" href="/__NUXT_DEVTOOLS_BASE__/_nuxt/entry.css-ckq2wff8.css" crossorigin><link rel="stylesheet" href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/json-editor-vue.css-lkbe0qhh.css" crossorigin><link rel="stylesheet" href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/unocss.css-3gd0e2sv.css" crossorigin><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/kzt4clis.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/_plugin-vue_export-helper-dp8rxgcg.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/rolldown-runtime-oipoa1or.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/json-editor-vue-hkofgjf7.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/state-dkywakbf.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ready-szdlhgcr.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/dist-mnod32r1.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nuxt-bfozs29x.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vue-router-dxks01bs.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/client-s5g5n0ac.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/shiki-niqic03h.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/unocss-bj3ln324.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/head-c2jgvqd9.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/dev-auth-j4vxv6a1.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nuxt-link-mev16ngd.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/dist-duc3zu0y.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/splitpanes.es-ceqv8417.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nbutton-oi1rfqiz.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nicon-m5br9nvg.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ncard-ech06vlh.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/npanel-grids-bl37sfq7.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ntext-input-ngomk0u2.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/state-routes-m6gv5n9v.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/state-tabs-mo8r9nzk.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/storage-options-owy2vf04.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/telemetry-bagjjni2.js"><script type="module" src="/__NUXT_DEVTOOLS_BASE__/_nuxt/kzt4clis.js" crossorigin></script></head><body><div id="__nuxt"></div><div id="teleports"></div><script>window.__NUXT__={};window.__NUXT__.config={public:{},app:{baseURL:"/__NUXT_DEVTOOLS_BASE__/",buildId:"b4ea867d-556a-40bd-b899-5018491fcc2d",buildAssetsDir:"/_nuxt/",cdnURL:""}}</script><script type="application/json" data-nuxt-data="nuxt-app" data-ssr="false" id="__NUXT_DATA__">[{"prerenderedAt":1,"serverRendered":2},1773033166882,false]</script></body></html>
|
package/dist/client/404.html
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
<!DOCTYPE html><html><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1"><script type="importmap">{"imports":{"#entry":"/__NUXT_DEVTOOLS_BASE__/_nuxt/
|
|
1
|
+
<!DOCTYPE html><html><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1"><script type="importmap">{"imports":{"#entry":"/__NUXT_DEVTOOLS_BASE__/_nuxt/kzt4clis.js"}}</script><link rel="stylesheet" href="/__NUXT_DEVTOOLS_BASE__/_nuxt/entry.css-ckq2wff8.css" crossorigin><link rel="stylesheet" href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/json-editor-vue.css-lkbe0qhh.css" crossorigin><link rel="stylesheet" href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/unocss.css-3gd0e2sv.css" crossorigin><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/kzt4clis.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/_plugin-vue_export-helper-dp8rxgcg.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/rolldown-runtime-oipoa1or.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/json-editor-vue-hkofgjf7.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/state-dkywakbf.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ready-szdlhgcr.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/dist-mnod32r1.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nuxt-bfozs29x.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vue-router-dxks01bs.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/client-s5g5n0ac.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/shiki-niqic03h.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/vendor/unocss-bj3ln324.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/head-c2jgvqd9.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/dev-auth-j4vxv6a1.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nuxt-link-mev16ngd.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/dist-duc3zu0y.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/splitpanes.es-ceqv8417.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nbutton-oi1rfqiz.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/nicon-m5br9nvg.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ncard-ech06vlh.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/npanel-grids-bl37sfq7.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/ntext-input-ngomk0u2.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/state-routes-m6gv5n9v.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/state-tabs-mo8r9nzk.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/storage-options-owy2vf04.js"><link rel="modulepreload" as="script" crossorigin href="/__NUXT_DEVTOOLS_BASE__/_nuxt/telemetry-bagjjni2.js"><script type="module" src="/__NUXT_DEVTOOLS_BASE__/_nuxt/kzt4clis.js" crossorigin></script></head><body><div id="__nuxt"></div><div id="teleports"></div><script>window.__NUXT__={};window.__NUXT__.config={public:{},app:{baseURL:"/__NUXT_DEVTOOLS_BASE__/",buildId:"b4ea867d-556a-40bd-b899-5018491fcc2d",buildAssetsDir:"/_nuxt/",cdnURL:""}}</script><script type="application/json" data-nuxt-data="nuxt-app" data-ssr="false" id="__NUXT_DATA__">[{"prerenderedAt":1,"serverRendered":2},1773033166885,false]</script></body></html>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{E as e,W as t,v as n}from"./vendor/json-editor-vue-hkofgjf7.js";import"./nuxt-bfozs29x.js";import{t as r}from"./composables-cwesk2q8.js";var i={"h-screen":``,"w-screen":``,"bg-black":``},a=e({__name:`__blank`,setup(e){return r({layout:`none`}),(e,r)=>(t(),n(`div`,i))}});export{a as default};
|