@vue/devtools-kit 7.6.3 → 7.6.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.
package/dist/index.cjs CHANGED
@@ -3129,6 +3129,9 @@ var DevToolsV6PluginAPI = class {
3129
3129
  // component inspector
3130
3130
  notifyComponentUpdate(instance) {
3131
3131
  var _a25;
3132
+ if (devtoolsState.highPerfModeEnabled) {
3133
+ return;
3134
+ }
3132
3135
  const inspector = getActiveInspectors().find((i) => i.packageName === this.plugin.descriptor.packageName);
3133
3136
  if (inspector == null ? void 0 : inspector.id) {
3134
3137
  if (instance) {
@@ -3153,9 +3156,15 @@ var DevToolsV6PluginAPI = class {
3153
3156
  }
3154
3157
  }
3155
3158
  sendInspectorTree(inspectorId) {
3159
+ if (devtoolsState.highPerfModeEnabled) {
3160
+ return;
3161
+ }
3156
3162
  this.hooks.callHook("sendInspectorTree" /* SEND_INSPECTOR_TREE */, { inspectorId, plugin: this.plugin });
3157
3163
  }
3158
3164
  sendInspectorState(inspectorId) {
3165
+ if (devtoolsState.highPerfModeEnabled) {
3166
+ return;
3167
+ }
3159
3168
  this.hooks.callHook("sendInspectorState" /* SEND_INSPECTOR_STATE */, { inspectorId, plugin: this.plugin });
3160
3169
  }
3161
3170
  selectInspectorNode(inspectorId, nodeId) {
@@ -3166,12 +3175,18 @@ var DevToolsV6PluginAPI = class {
3166
3175
  }
3167
3176
  // timeline
3168
3177
  now() {
3178
+ if (devtoolsState.highPerfModeEnabled) {
3179
+ return 0;
3180
+ }
3169
3181
  return Date.now();
3170
3182
  }
3171
3183
  addTimelineLayer(options) {
3172
3184
  this.hooks.callHook("timelineLayerAdded" /* TIMELINE_LAYER_ADDED */, { options, plugin: this.plugin });
3173
3185
  }
3174
3186
  addTimelineEvent(options) {
3187
+ if (devtoolsState.highPerfModeEnabled) {
3188
+ return;
3189
+ }
3175
3190
  this.hooks.callHook("timelineEventAdded" /* TIMELINE_EVENT_ADDED */, { options, plugin: this.plugin });
3176
3191
  }
3177
3192
  // settings
@@ -3418,7 +3433,7 @@ function processProps(instance) {
3418
3433
  var _a25;
3419
3434
  const props = [];
3420
3435
  const propDefinitions = (_a25 = instance == null ? void 0 : instance.type) == null ? void 0 : _a25.props;
3421
- for (const key in instance.props) {
3436
+ for (const key in instance == null ? void 0 : instance.props) {
3422
3437
  const propDefinition = propDefinitions ? propDefinitions[key] : null;
3423
3438
  const camelizeKey = (0, import_devtools_shared11.camelize)(key);
3424
3439
  props.push({
@@ -3439,7 +3454,7 @@ function processProps(instance) {
3439
3454
  }
3440
3455
  function processState(instance) {
3441
3456
  const type = instance.type;
3442
- const props = type.props;
3457
+ const props = type == null ? void 0 : type.props;
3443
3458
  const getters = type.vuex && type.vuex.getters;
3444
3459
  const computedDefs = type.computed;
3445
3460
  const data = {
@@ -4238,7 +4253,7 @@ function removeRegisteredPluginApp(app) {
4238
4253
  import_devtools_shared14.target.__VUE_DEVTOOLS_KIT__REGISTERED_PLUGIN_APPS__.delete(app);
4239
4254
  }
4240
4255
  function registerDevToolsPlugin(app) {
4241
- if (import_devtools_shared14.target.__VUE_DEVTOOLS_KIT__REGISTERED_PLUGIN_APPS__.has(app))
4256
+ if (import_devtools_shared14.target.__VUE_DEVTOOLS_KIT__REGISTERED_PLUGIN_APPS__.has(app) || devtoolsState.highPerfModeEnabled)
4242
4257
  return;
4243
4258
  import_devtools_shared14.target.__VUE_DEVTOOLS_KIT__REGISTERED_PLUGIN_APPS__.add(app);
4244
4259
  devtoolsPluginBuffer.forEach((plugin) => {
@@ -4663,6 +4678,9 @@ function onDevToolsClientConnected(fn) {
4663
4678
  init_cjs_shims();
4664
4679
  function toggleHighPerfMode(state) {
4665
4680
  devtoolsState.highPerfModeEnabled = state != null ? state : !devtoolsState.highPerfModeEnabled;
4681
+ if (!state && activeAppRecord.value) {
4682
+ registerDevToolsPlugin(activeAppRecord.value.app);
4683
+ }
4666
4684
  }
4667
4685
 
4668
4686
  // src/core/component/state/format.ts
@@ -6199,7 +6217,7 @@ function getFunctionDetails(func) {
6199
6217
  return {
6200
6218
  _custom: {
6201
6219
  type: "function",
6202
- displayText: `<span style="opacity:.5;margin-right:5px;">function</span> <span style="white-space:nowrap;">${escape(name)}${args}</span>`,
6220
+ displayText: `<span style="opacity:.8;margin-right:5px;">function</span> <span style="white-space:nowrap;">${escape(name)}${args}</span>`,
6203
6221
  tooltipText: string.trim() ? `<pre>${string}</pre>` : null
6204
6222
  }
6205
6223
  };
package/dist/index.js CHANGED
@@ -3038,6 +3038,9 @@ var DevToolsV6PluginAPI = class {
3038
3038
  // component inspector
3039
3039
  notifyComponentUpdate(instance) {
3040
3040
  var _a25;
3041
+ if (devtoolsState.highPerfModeEnabled) {
3042
+ return;
3043
+ }
3041
3044
  const inspector = getActiveInspectors().find((i) => i.packageName === this.plugin.descriptor.packageName);
3042
3045
  if (inspector == null ? void 0 : inspector.id) {
3043
3046
  if (instance) {
@@ -3062,9 +3065,15 @@ var DevToolsV6PluginAPI = class {
3062
3065
  }
3063
3066
  }
3064
3067
  sendInspectorTree(inspectorId) {
3068
+ if (devtoolsState.highPerfModeEnabled) {
3069
+ return;
3070
+ }
3065
3071
  this.hooks.callHook("sendInspectorTree" /* SEND_INSPECTOR_TREE */, { inspectorId, plugin: this.plugin });
3066
3072
  }
3067
3073
  sendInspectorState(inspectorId) {
3074
+ if (devtoolsState.highPerfModeEnabled) {
3075
+ return;
3076
+ }
3068
3077
  this.hooks.callHook("sendInspectorState" /* SEND_INSPECTOR_STATE */, { inspectorId, plugin: this.plugin });
3069
3078
  }
3070
3079
  selectInspectorNode(inspectorId, nodeId) {
@@ -3075,12 +3084,18 @@ var DevToolsV6PluginAPI = class {
3075
3084
  }
3076
3085
  // timeline
3077
3086
  now() {
3087
+ if (devtoolsState.highPerfModeEnabled) {
3088
+ return 0;
3089
+ }
3078
3090
  return Date.now();
3079
3091
  }
3080
3092
  addTimelineLayer(options) {
3081
3093
  this.hooks.callHook("timelineLayerAdded" /* TIMELINE_LAYER_ADDED */, { options, plugin: this.plugin });
3082
3094
  }
3083
3095
  addTimelineEvent(options) {
3096
+ if (devtoolsState.highPerfModeEnabled) {
3097
+ return;
3098
+ }
3084
3099
  this.hooks.callHook("timelineEventAdded" /* TIMELINE_EVENT_ADDED */, { options, plugin: this.plugin });
3085
3100
  }
3086
3101
  // settings
@@ -3327,7 +3342,7 @@ function processProps(instance) {
3327
3342
  var _a25;
3328
3343
  const props = [];
3329
3344
  const propDefinitions = (_a25 = instance == null ? void 0 : instance.type) == null ? void 0 : _a25.props;
3330
- for (const key in instance.props) {
3345
+ for (const key in instance == null ? void 0 : instance.props) {
3331
3346
  const propDefinition = propDefinitions ? propDefinitions[key] : null;
3332
3347
  const camelizeKey = camelize(key);
3333
3348
  props.push({
@@ -3348,7 +3363,7 @@ function processProps(instance) {
3348
3363
  }
3349
3364
  function processState(instance) {
3350
3365
  const type = instance.type;
3351
- const props = type.props;
3366
+ const props = type == null ? void 0 : type.props;
3352
3367
  const getters = type.vuex && type.vuex.getters;
3353
3368
  const computedDefs = type.computed;
3354
3369
  const data = {
@@ -4147,7 +4162,7 @@ function removeRegisteredPluginApp(app) {
4147
4162
  target8.__VUE_DEVTOOLS_KIT__REGISTERED_PLUGIN_APPS__.delete(app);
4148
4163
  }
4149
4164
  function registerDevToolsPlugin(app) {
4150
- if (target8.__VUE_DEVTOOLS_KIT__REGISTERED_PLUGIN_APPS__.has(app))
4165
+ if (target8.__VUE_DEVTOOLS_KIT__REGISTERED_PLUGIN_APPS__.has(app) || devtoolsState.highPerfModeEnabled)
4151
4166
  return;
4152
4167
  target8.__VUE_DEVTOOLS_KIT__REGISTERED_PLUGIN_APPS__.add(app);
4153
4168
  devtoolsPluginBuffer.forEach((plugin) => {
@@ -4572,6 +4587,9 @@ function onDevToolsClientConnected(fn) {
4572
4587
  init_esm_shims();
4573
4588
  function toggleHighPerfMode(state) {
4574
4589
  devtoolsState.highPerfModeEnabled = state != null ? state : !devtoolsState.highPerfModeEnabled;
4590
+ if (!state && activeAppRecord.value) {
4591
+ registerDevToolsPlugin(activeAppRecord.value.app);
4592
+ }
4575
4593
  }
4576
4594
 
4577
4595
  // src/core/component/state/format.ts
@@ -6108,7 +6126,7 @@ function getFunctionDetails(func) {
6108
6126
  return {
6109
6127
  _custom: {
6110
6128
  type: "function",
6111
- displayText: `<span style="opacity:.5;margin-right:5px;">function</span> <span style="white-space:nowrap;">${escape(name)}${args}</span>`,
6129
+ displayText: `<span style="opacity:.8;margin-right:5px;">function</span> <span style="white-space:nowrap;">${escape(name)}${args}</span>`,
6112
6130
  tooltipText: string.trim() ? `<pre>${string}</pre>` : null
6113
6131
  }
6114
6132
  };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@vue/devtools-kit",
3
3
  "type": "module",
4
- "version": "7.6.3",
4
+ "version": "7.6.4",
5
5
  "author": "webfansplz",
6
6
  "license": "MIT",
7
7
  "repository": {
@@ -29,7 +29,7 @@
29
29
  "perfect-debounce": "^1.0.0",
30
30
  "speakingurl": "^14.0.1",
31
31
  "superjson": "^2.2.1",
32
- "@vue/devtools-shared": "^7.6.3"
32
+ "@vue/devtools-shared": "^7.6.4"
33
33
  },
34
34
  "devDependencies": {
35
35
  "@types/speakingurl": "^13.0.6",