@nuxt/devtools-kit 0.8.2 → 0.8.4

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.
@@ -0,0 +1,172 @@
1
+ import { V as VueInspectorData, a as VueInspectorClient, H as HookInfo, P as PluginMetric, L as LoadingTimeMetric, b as ServerFunctions } from './shared/devtools-kit.8143bd0b.cjs';
2
+ export { a1 as AnalyzeBuildMeta, a2 as AnalyzeBuildsInfo, K as AssetEntry, J as AssetInfo, F as AssetType, A as AutoImportsWithMetadata, B as BasicModuleInfo, C as CategorizedTabs, Z as ClientFunctions, _ as ClientUpdateEvent, O as CodeSnippet, z as CompatibilityStatus, Q as ComponentRelationship, U as ComponentWithRelationships, Y as GetWizardArgs, G as GitHubContributor, I as ImageMeta, a0 as InstallModuleReturn, w as InstalledModuleInfo, E as MaintainerInfo, i as ModuleBuiltinTab, y as ModuleCompatibility, M as ModuleCustomTab, a4 as ModuleGlobalOptions, h as ModuleIframeTabLazyOptions, d as ModuleIframeView, f as ModuleLaunchAction, c as ModuleLaunchView, a3 as ModuleOptions, x as ModuleStaticInfo, j as ModuleTabInfo, D as ModuleType, e as ModuleVNodeView, g as ModuleView, q as NpmCommandOptions, p as NpmCommandType, a7 as NuxtDevToolsOptions, N as NuxtDevtoolsInfo, $ as NuxtDevtoolsServerContext, o as PackageManagerName, n as PackageUpdateInfo, u as Payload, v as PluginInfoWithMetic, R as RouteInfo, r as ServerRouteInfo, t as ServerRouteInput, s as ServerRouteInputType, S as SubprocessOptions, a8 as TabCategory, l as TerminalAction, k as TerminalBase, m as TerminalInfo, T as TerminalState, a5 as VSCodeIntegrationOptions, a6 as VSCodeTunnelOptions, X as WizardActions, W as WizardFunctions } from './shared/devtools-kit.8143bd0b.cjs';
3
+ import { Ref } from 'vue';
4
+ import { AppConfig } from 'nuxt/schema';
5
+ import { NuxtApp } from 'nuxt/dist/app/nuxt';
6
+ import { Hookable } from 'hookable';
7
+ import { BirpcReturn } from 'birpc';
8
+ import { BuiltinLanguage } from 'shikiji';
9
+ import { StackFrame } from 'error-stack-parser-es';
10
+ import 'nitropack';
11
+ import 'unstorage';
12
+ import 'vite-plugin-vue-inspector';
13
+ import 'unimport';
14
+ import 'vue-router';
15
+ import 'execa';
16
+ import '@nuxt/schema';
17
+
18
+ interface TimelineEventFunction {
19
+ type: 'function';
20
+ start: number;
21
+ end?: number;
22
+ name: string;
23
+ args?: any[];
24
+ result?: any;
25
+ stacktrace?: StackFrame[];
26
+ isPromise?: boolean;
27
+ }
28
+ interface TimelineEventRoute {
29
+ type: 'route';
30
+ start: number;
31
+ end?: number;
32
+ from: string;
33
+ to: string;
34
+ }
35
+ interface TimelineOptions {
36
+ enabled: boolean;
37
+ stacktrace: boolean;
38
+ arguments: boolean;
39
+ }
40
+ type TimelineEvent = TimelineEventFunction | TimelineEventRoute;
41
+ interface TimelineMetrics {
42
+ events: TimelineEvent[];
43
+ nonLiteralSymbol: symbol;
44
+ options: TimelineOptions;
45
+ }
46
+ interface TimelineEventNormalized<T> {
47
+ event: T;
48
+ segment: TimelineEventsSegment;
49
+ relativeStart: number;
50
+ relativeWidth: number;
51
+ layer: number;
52
+ }
53
+ interface TimelineEventsSegment {
54
+ start: number;
55
+ end: number;
56
+ events: TimelineEvent[];
57
+ functions: TimelineEventNormalized<TimelineEventFunction>[];
58
+ route?: TimelineEventNormalized<TimelineEventRoute>;
59
+ duration: number;
60
+ previousGap?: number;
61
+ }
62
+
63
+ interface DevToolsFrameState {
64
+ width: number;
65
+ height: number;
66
+ top: number;
67
+ left: number;
68
+ open: boolean;
69
+ route: string;
70
+ position: 'left' | 'right' | 'bottom' | 'top';
71
+ closeOnOutsideClick: boolean;
72
+ minimizePanelInactive: number;
73
+ }
74
+ interface NuxtDevtoolsClientHooks {
75
+ /**
76
+ * When the DevTools navigates, used for persisting the current tab
77
+ */
78
+ 'devtools:navigate': (path: string) => void;
79
+ /**
80
+ * Event emitted when the component inspector is updated
81
+ */
82
+ 'host:inspector:update': (data: VueInspectorData) => void;
83
+ /**
84
+ * Event emitted when the component inspector is clicked
85
+ */
86
+ 'host:inspector:click': (baseUrl: string, file: string, line: number, column: number) => void;
87
+ /**
88
+ * Event to close the component inspector
89
+ */
90
+ 'host:inspector:close': () => void;
91
+ /**
92
+ * Triggers reactivity manually, since Vue won't be reactive across frames)
93
+ */
94
+ 'host:update:reactivity': () => void;
95
+ /**
96
+ * Host action to control the DevTools navigation
97
+ */
98
+ 'host:action:navigate': (path: string) => void;
99
+ /**
100
+ * Host action to reload the DevTools
101
+ */
102
+ 'host:action:reload': () => void;
103
+ }
104
+ /**
105
+ * Host client from the App
106
+ */
107
+ interface NuxtDevtoolsHostClient {
108
+ nuxt: NuxtApp;
109
+ hooks: Hookable<NuxtDevtoolsClientHooks>;
110
+ getIframe(): HTMLIFrameElement | undefined;
111
+ inspector?: {
112
+ instance?: VueInspectorClient;
113
+ enable: () => void;
114
+ disable: () => void;
115
+ toggle: () => void;
116
+ isEnabled: Ref<boolean>;
117
+ };
118
+ devtools: {
119
+ close(): void;
120
+ open(): void;
121
+ toggle(): void;
122
+ reload(): void;
123
+ navigate(path: string): void;
124
+ /**
125
+ * Popup the DevTools frame into Picture-in-Picture mode
126
+ *
127
+ * Requires Chrome 111 with experimental flag enabled.
128
+ *
129
+ * Function is undefined when not supported.
130
+ *
131
+ * @see https://developer.chrome.com/docs/web-platform/document-picture-in-picture/
132
+ */
133
+ popup?(): any;
134
+ };
135
+ app: {
136
+ reload(): void;
137
+ navigate(path: string, hard?: boolean): void;
138
+ appConfig: AppConfig;
139
+ colorMode: Ref<'dark' | 'light'>;
140
+ frameState: Ref<DevToolsFrameState>;
141
+ };
142
+ metrics: {
143
+ clientHooks(): HookInfo[];
144
+ clientPlugins(): PluginMetric[] | undefined;
145
+ clientTimeline(): TimelineMetrics | undefined;
146
+ loading(): LoadingTimeMetric;
147
+ };
148
+ /**
149
+ * Update client
150
+ * @internal
151
+ */
152
+ syncClient(): NuxtDevtoolsHostClient;
153
+ }
154
+ interface NuxtDevtoolsClient {
155
+ rpc: BirpcReturn<ServerFunctions>;
156
+ renderCodeHighlight: (code: string, lang?: BuiltinLanguage) => {
157
+ code: string;
158
+ supported: boolean;
159
+ };
160
+ renderMarkdown: (markdown: string) => string;
161
+ colorMode: string;
162
+ extendClientRpc: <ServerFunctions = Record<string, never>, ClientFunctions = Record<string, never>>(name: string, functions: ClientFunctions) => BirpcReturn<ServerFunctions, ClientFunctions>;
163
+ }
164
+ interface NuxtDevtoolsIframeClient {
165
+ host: NuxtDevtoolsHostClient;
166
+ devtools: NuxtDevtoolsClient;
167
+ }
168
+ interface NuxtDevtoolsGlobal {
169
+ setClient(client: NuxtDevtoolsHostClient): void;
170
+ }
171
+
172
+ export { type DevToolsFrameState, HookInfo, LoadingTimeMetric, type NuxtDevtoolsClient, type NuxtDevtoolsClientHooks, type NuxtDevtoolsGlobal, type NuxtDevtoolsHostClient, type NuxtDevtoolsIframeClient, PluginMetric, ServerFunctions, type TimelineEvent, type TimelineEventFunction, type TimelineEventNormalized, type TimelineEventRoute, type TimelineEventsSegment, type TimelineMetrics, type TimelineOptions, VueInspectorClient, VueInspectorData };
@@ -0,0 +1,172 @@
1
+ import { V as VueInspectorData, a as VueInspectorClient, H as HookInfo, P as PluginMetric, L as LoadingTimeMetric, b as ServerFunctions } from './shared/devtools-kit.8143bd0b.mjs';
2
+ export { a1 as AnalyzeBuildMeta, a2 as AnalyzeBuildsInfo, K as AssetEntry, J as AssetInfo, F as AssetType, A as AutoImportsWithMetadata, B as BasicModuleInfo, C as CategorizedTabs, Z as ClientFunctions, _ as ClientUpdateEvent, O as CodeSnippet, z as CompatibilityStatus, Q as ComponentRelationship, U as ComponentWithRelationships, Y as GetWizardArgs, G as GitHubContributor, I as ImageMeta, a0 as InstallModuleReturn, w as InstalledModuleInfo, E as MaintainerInfo, i as ModuleBuiltinTab, y as ModuleCompatibility, M as ModuleCustomTab, a4 as ModuleGlobalOptions, h as ModuleIframeTabLazyOptions, d as ModuleIframeView, f as ModuleLaunchAction, c as ModuleLaunchView, a3 as ModuleOptions, x as ModuleStaticInfo, j as ModuleTabInfo, D as ModuleType, e as ModuleVNodeView, g as ModuleView, q as NpmCommandOptions, p as NpmCommandType, a7 as NuxtDevToolsOptions, N as NuxtDevtoolsInfo, $ as NuxtDevtoolsServerContext, o as PackageManagerName, n as PackageUpdateInfo, u as Payload, v as PluginInfoWithMetic, R as RouteInfo, r as ServerRouteInfo, t as ServerRouteInput, s as ServerRouteInputType, S as SubprocessOptions, a8 as TabCategory, l as TerminalAction, k as TerminalBase, m as TerminalInfo, T as TerminalState, a5 as VSCodeIntegrationOptions, a6 as VSCodeTunnelOptions, X as WizardActions, W as WizardFunctions } from './shared/devtools-kit.8143bd0b.mjs';
3
+ import { Ref } from 'vue';
4
+ import { AppConfig } from 'nuxt/schema';
5
+ import { NuxtApp } from 'nuxt/dist/app/nuxt';
6
+ import { Hookable } from 'hookable';
7
+ import { BirpcReturn } from 'birpc';
8
+ import { BuiltinLanguage } from 'shikiji';
9
+ import { StackFrame } from 'error-stack-parser-es';
10
+ import 'nitropack';
11
+ import 'unstorage';
12
+ import 'vite-plugin-vue-inspector';
13
+ import 'unimport';
14
+ import 'vue-router';
15
+ import 'execa';
16
+ import '@nuxt/schema';
17
+
18
+ interface TimelineEventFunction {
19
+ type: 'function';
20
+ start: number;
21
+ end?: number;
22
+ name: string;
23
+ args?: any[];
24
+ result?: any;
25
+ stacktrace?: StackFrame[];
26
+ isPromise?: boolean;
27
+ }
28
+ interface TimelineEventRoute {
29
+ type: 'route';
30
+ start: number;
31
+ end?: number;
32
+ from: string;
33
+ to: string;
34
+ }
35
+ interface TimelineOptions {
36
+ enabled: boolean;
37
+ stacktrace: boolean;
38
+ arguments: boolean;
39
+ }
40
+ type TimelineEvent = TimelineEventFunction | TimelineEventRoute;
41
+ interface TimelineMetrics {
42
+ events: TimelineEvent[];
43
+ nonLiteralSymbol: symbol;
44
+ options: TimelineOptions;
45
+ }
46
+ interface TimelineEventNormalized<T> {
47
+ event: T;
48
+ segment: TimelineEventsSegment;
49
+ relativeStart: number;
50
+ relativeWidth: number;
51
+ layer: number;
52
+ }
53
+ interface TimelineEventsSegment {
54
+ start: number;
55
+ end: number;
56
+ events: TimelineEvent[];
57
+ functions: TimelineEventNormalized<TimelineEventFunction>[];
58
+ route?: TimelineEventNormalized<TimelineEventRoute>;
59
+ duration: number;
60
+ previousGap?: number;
61
+ }
62
+
63
+ interface DevToolsFrameState {
64
+ width: number;
65
+ height: number;
66
+ top: number;
67
+ left: number;
68
+ open: boolean;
69
+ route: string;
70
+ position: 'left' | 'right' | 'bottom' | 'top';
71
+ closeOnOutsideClick: boolean;
72
+ minimizePanelInactive: number;
73
+ }
74
+ interface NuxtDevtoolsClientHooks {
75
+ /**
76
+ * When the DevTools navigates, used for persisting the current tab
77
+ */
78
+ 'devtools:navigate': (path: string) => void;
79
+ /**
80
+ * Event emitted when the component inspector is updated
81
+ */
82
+ 'host:inspector:update': (data: VueInspectorData) => void;
83
+ /**
84
+ * Event emitted when the component inspector is clicked
85
+ */
86
+ 'host:inspector:click': (baseUrl: string, file: string, line: number, column: number) => void;
87
+ /**
88
+ * Event to close the component inspector
89
+ */
90
+ 'host:inspector:close': () => void;
91
+ /**
92
+ * Triggers reactivity manually, since Vue won't be reactive across frames)
93
+ */
94
+ 'host:update:reactivity': () => void;
95
+ /**
96
+ * Host action to control the DevTools navigation
97
+ */
98
+ 'host:action:navigate': (path: string) => void;
99
+ /**
100
+ * Host action to reload the DevTools
101
+ */
102
+ 'host:action:reload': () => void;
103
+ }
104
+ /**
105
+ * Host client from the App
106
+ */
107
+ interface NuxtDevtoolsHostClient {
108
+ nuxt: NuxtApp;
109
+ hooks: Hookable<NuxtDevtoolsClientHooks>;
110
+ getIframe(): HTMLIFrameElement | undefined;
111
+ inspector?: {
112
+ instance?: VueInspectorClient;
113
+ enable: () => void;
114
+ disable: () => void;
115
+ toggle: () => void;
116
+ isEnabled: Ref<boolean>;
117
+ };
118
+ devtools: {
119
+ close(): void;
120
+ open(): void;
121
+ toggle(): void;
122
+ reload(): void;
123
+ navigate(path: string): void;
124
+ /**
125
+ * Popup the DevTools frame into Picture-in-Picture mode
126
+ *
127
+ * Requires Chrome 111 with experimental flag enabled.
128
+ *
129
+ * Function is undefined when not supported.
130
+ *
131
+ * @see https://developer.chrome.com/docs/web-platform/document-picture-in-picture/
132
+ */
133
+ popup?(): any;
134
+ };
135
+ app: {
136
+ reload(): void;
137
+ navigate(path: string, hard?: boolean): void;
138
+ appConfig: AppConfig;
139
+ colorMode: Ref<'dark' | 'light'>;
140
+ frameState: Ref<DevToolsFrameState>;
141
+ };
142
+ metrics: {
143
+ clientHooks(): HookInfo[];
144
+ clientPlugins(): PluginMetric[] | undefined;
145
+ clientTimeline(): TimelineMetrics | undefined;
146
+ loading(): LoadingTimeMetric;
147
+ };
148
+ /**
149
+ * Update client
150
+ * @internal
151
+ */
152
+ syncClient(): NuxtDevtoolsHostClient;
153
+ }
154
+ interface NuxtDevtoolsClient {
155
+ rpc: BirpcReturn<ServerFunctions>;
156
+ renderCodeHighlight: (code: string, lang?: BuiltinLanguage) => {
157
+ code: string;
158
+ supported: boolean;
159
+ };
160
+ renderMarkdown: (markdown: string) => string;
161
+ colorMode: string;
162
+ extendClientRpc: <ServerFunctions = Record<string, never>, ClientFunctions = Record<string, never>>(name: string, functions: ClientFunctions) => BirpcReturn<ServerFunctions, ClientFunctions>;
163
+ }
164
+ interface NuxtDevtoolsIframeClient {
165
+ host: NuxtDevtoolsHostClient;
166
+ devtools: NuxtDevtoolsClient;
167
+ }
168
+ interface NuxtDevtoolsGlobal {
169
+ setClient(client: NuxtDevtoolsHostClient): void;
170
+ }
171
+
172
+ export { type DevToolsFrameState, HookInfo, LoadingTimeMetric, type NuxtDevtoolsClient, type NuxtDevtoolsClientHooks, type NuxtDevtoolsGlobal, type NuxtDevtoolsHostClient, type NuxtDevtoolsIframeClient, PluginMetric, ServerFunctions, type TimelineEvent, type TimelineEventFunction, type TimelineEventNormalized, type TimelineEventRoute, type TimelineEventsSegment, type TimelineMetrics, type TimelineOptions, VueInspectorClient, VueInspectorData };
package/dist/types.d.ts CHANGED
@@ -1,5 +1,5 @@
1
- import { V as VueInspectorData, a as VueInspectorClient, H as HookInfo, P as PluginMetric, L as LoadingTimeMetric, b as ServerFunctions } from './hooks-d8216808.js';
2
- export { a1 as AnalyzeBuildMeta, a2 as AnalyzeBuildsInfo, K as AssetEntry, J as AssetInfo, F as AssetType, A as AutoImportsWithMetadata, B as BasicModuleInfo, C as CategorizedTabs, Z as ClientFunctions, _ as ClientUpdateEvent, O as CodeSnippet, z as CompatibilityStatus, Q as ComponentRelationship, U as ComponentWithRelationships, Y as GetWizardArgs, G as GitHubContributor, I as ImageMeta, a0 as InstallModuleReturn, w as InstalledModuleInfo, E as MaintainerInfo, i as ModuleBuiltinTab, y as ModuleCompatibility, M as ModuleCustomTab, a4 as ModuleGlobalOptions, h as ModuleIframeTabLazyOptions, d as ModuleIframeView, f as ModuleLaunchAction, c as ModuleLaunchView, a3 as ModuleOptions, x as ModuleStaticInfo, j as ModuleTabInfo, D as ModuleType, e as ModuleVNodeView, g as ModuleView, q as NpmCommandOptions, p as NpmCommandType, a7 as NuxtDevToolsOptions, N as NuxtDevtoolsInfo, $ as NuxtDevtoolsServerContext, o as PackageManagerName, n as PackageUpdateInfo, u as Payload, v as PluginInfoWithMetic, R as RouteInfo, r as ServerRouteInfo, t as ServerRouteInput, s as ServerRouteInputType, S as SubprocessOptions, a8 as TabCategory, l as TerminalAction, k as TerminalBase, m as TerminalInfo, T as TerminalState, a5 as VSCodeIntegrationOptions, a6 as VSCodeTunnelOptions, X as WizardActions, W as WizardFunctions } from './hooks-d8216808.js';
1
+ import { V as VueInspectorData, a as VueInspectorClient, H as HookInfo, P as PluginMetric, L as LoadingTimeMetric, b as ServerFunctions } from './shared/devtools-kit.8143bd0b.js';
2
+ export { a1 as AnalyzeBuildMeta, a2 as AnalyzeBuildsInfo, K as AssetEntry, J as AssetInfo, F as AssetType, A as AutoImportsWithMetadata, B as BasicModuleInfo, C as CategorizedTabs, Z as ClientFunctions, _ as ClientUpdateEvent, O as CodeSnippet, z as CompatibilityStatus, Q as ComponentRelationship, U as ComponentWithRelationships, Y as GetWizardArgs, G as GitHubContributor, I as ImageMeta, a0 as InstallModuleReturn, w as InstalledModuleInfo, E as MaintainerInfo, i as ModuleBuiltinTab, y as ModuleCompatibility, M as ModuleCustomTab, a4 as ModuleGlobalOptions, h as ModuleIframeTabLazyOptions, d as ModuleIframeView, f as ModuleLaunchAction, c as ModuleLaunchView, a3 as ModuleOptions, x as ModuleStaticInfo, j as ModuleTabInfo, D as ModuleType, e as ModuleVNodeView, g as ModuleView, q as NpmCommandOptions, p as NpmCommandType, a7 as NuxtDevToolsOptions, N as NuxtDevtoolsInfo, $ as NuxtDevtoolsServerContext, o as PackageManagerName, n as PackageUpdateInfo, u as Payload, v as PluginInfoWithMetic, R as RouteInfo, r as ServerRouteInfo, t as ServerRouteInput, s as ServerRouteInputType, S as SubprocessOptions, a8 as TabCategory, l as TerminalAction, k as TerminalBase, m as TerminalInfo, T as TerminalState, a5 as VSCodeIntegrationOptions, a6 as VSCodeTunnelOptions, X as WizardActions, W as WizardFunctions } from './shared/devtools-kit.8143bd0b.js';
3
3
  import { Ref } from 'vue';
4
4
  import { AppConfig } from 'nuxt/schema';
5
5
  import { NuxtApp } from 'nuxt/dist/app/nuxt';
@@ -169,4 +169,4 @@ interface NuxtDevtoolsGlobal {
169
169
  setClient(client: NuxtDevtoolsHostClient): void;
170
170
  }
171
171
 
172
- export { DevToolsFrameState, HookInfo, LoadingTimeMetric, NuxtDevtoolsClient, NuxtDevtoolsClientHooks, NuxtDevtoolsGlobal, NuxtDevtoolsHostClient, NuxtDevtoolsIframeClient, PluginMetric, ServerFunctions, TimelineEvent, TimelineEventFunction, TimelineEventNormalized, TimelineEventRoute, TimelineEventsSegment, TimelineMetrics, TimelineOptions, VueInspectorClient, VueInspectorData };
172
+ export { type DevToolsFrameState, HookInfo, LoadingTimeMetric, type NuxtDevtoolsClient, type NuxtDevtoolsClientHooks, type NuxtDevtoolsGlobal, type NuxtDevtoolsHostClient, type NuxtDevtoolsIframeClient, PluginMetric, ServerFunctions, type TimelineEvent, type TimelineEventFunction, type TimelineEventNormalized, type TimelineEventRoute, type TimelineEventsSegment, type TimelineMetrics, type TimelineOptions, VueInspectorClient, VueInspectorData };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@nuxt/devtools-kit",
3
3
  "type": "module",
4
- "version": "0.8.2",
4
+ "version": "0.8.4",
5
5
  "license": "MIT",
6
6
  "repository": "nuxt/devtools",
7
7
  "exports": {
@@ -29,21 +29,21 @@
29
29
  "*.mjs"
30
30
  ],
31
31
  "peerDependencies": {
32
- "nuxt": "^3.6.5",
32
+ "nuxt": "^3.7.3",
33
33
  "vite": "*"
34
34
  },
35
35
  "dependencies": {
36
- "@nuxt/kit": "^3.7.0",
37
- "@nuxt/schema": "^3.7.0",
36
+ "@nuxt/kit": "^3.7.3",
37
+ "@nuxt/schema": "^3.7.3",
38
38
  "execa": "^7.2.0"
39
39
  },
40
40
  "devDependencies": {
41
- "birpc": "^0.2.13",
41
+ "birpc": "^0.2.14",
42
42
  "error-stack-parser-es": "^0.1.1",
43
43
  "hookable": "^5.5.3",
44
44
  "unbuild": "^2.0.0",
45
- "unimport": "^3.2.0",
46
- "vite-plugin-vue-inspector": "^3.6.0",
45
+ "unimport": "^3.3.0",
46
+ "vite-plugin-vue-inspector": "^3.7.1",
47
47
  "vue-router": "^4.2.4"
48
48
  },
49
49
  "scripts": {