@vue/runtime-dom 3.6.0-alpha.7 → 3.6.0-beta.2

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.
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @vue/runtime-dom v3.6.0-alpha.7
2
+ * @vue/runtime-dom v3.6.0-beta.2
3
3
  * (c) 2018-present Yuxi (Evan) You and Vue contributors
4
4
  * @license MIT
5
5
  **/
@@ -754,13 +754,13 @@ var VueRuntimeDOM = (function (exports) {
754
754
  }
755
755
  }
756
756
  const targetMap = /* @__PURE__ */ new WeakMap();
757
- const ITERATE_KEY = Symbol(
757
+ const ITERATE_KEY = /* @__PURE__ */ Symbol(
758
758
  "Object iterate"
759
759
  );
760
- const MAP_KEY_ITERATE_KEY = Symbol(
760
+ const MAP_KEY_ITERATE_KEY = /* @__PURE__ */ Symbol(
761
761
  "Map keys iterate"
762
762
  );
763
- const ARRAY_ITERATE_KEY = Symbol(
763
+ const ARRAY_ITERATE_KEY = /* @__PURE__ */ Symbol(
764
764
  "Array iterate"
765
765
  );
766
766
  function track(target, type, key) {
@@ -2381,7 +2381,6 @@ var VueRuntimeDOM = (function (exports) {
2381
2381
  instance,
2382
2382
  11,
2383
2383
  [
2384
- // eslint-disable-next-line no-restricted-syntax
2385
2384
  msg + args.map((a) => {
2386
2385
  var _a, _b;
2387
2386
  return (_b = (_a = a.toString) == null ? void 0 : _a.call(a)) != null ? _b : JSON.stringify(a);
@@ -2761,10 +2760,10 @@ var VueRuntimeDOM = (function (exports) {
2761
2760
  }
2762
2761
  }
2763
2762
  let isFlushing = false;
2764
- function flushOnAppMount() {
2763
+ function flushOnAppMount(instance) {
2765
2764
  if (!isFlushing) {
2766
2765
  isFlushing = true;
2767
- flushPreFlushCbs();
2766
+ flushPreFlushCbs(instance);
2768
2767
  flushPostFlushCbs();
2769
2768
  isFlushing = false;
2770
2769
  }
@@ -3006,7 +3005,6 @@ var VueRuntimeDOM = (function (exports) {
3006
3005
  // (#4815)
3007
3006
  typeof window !== "undefined" && // some envs mock window but not fully
3008
3007
  window.HTMLElement && // also exclude jsdom
3009
- // eslint-disable-next-line no-restricted-syntax
3010
3008
  !((_b = (_a = window.navigator) == null ? void 0 : _a.userAgent) == null ? void 0 : _b.includes("jsdom"))
3011
3009
  ) {
3012
3010
  const replay = target.__VUE_DEVTOOLS_HOOK_REPLAY__ = target.__VUE_DEVTOOLS_HOOK_REPLAY__ || [];
@@ -3179,7 +3177,175 @@ var VueRuntimeDOM = (function (exports) {
3179
3177
  }
3180
3178
  }
3181
3179
 
3182
- const TeleportEndKey = Symbol("_vte");
3180
+ function provide(key, value) {
3181
+ {
3182
+ if (!currentInstance || currentInstance.isMounted && !isHmrUpdating) {
3183
+ warn$1(`provide() can only be used inside setup().`);
3184
+ }
3185
+ }
3186
+ if (currentInstance) {
3187
+ let provides = currentInstance.provides;
3188
+ const parentProvides = currentInstance.parent && currentInstance.parent.provides;
3189
+ if (parentProvides === provides) {
3190
+ provides = currentInstance.provides = Object.create(parentProvides);
3191
+ }
3192
+ provides[key] = value;
3193
+ }
3194
+ }
3195
+ function inject(key, defaultValue, treatDefaultAsFactory = false) {
3196
+ const instance = getCurrentGenericInstance();
3197
+ if (instance || currentApp) {
3198
+ let provides = currentApp ? currentApp._context.provides : instance ? instance.parent == null || instance.ce ? instance.appContext && instance.appContext.provides : instance.parent.provides : void 0;
3199
+ if (provides && key in provides) {
3200
+ return provides[key];
3201
+ } else if (arguments.length > 1) {
3202
+ return treatDefaultAsFactory && isFunction(defaultValue) ? defaultValue.call(instance && instance.proxy) : defaultValue;
3203
+ } else {
3204
+ warn$1(`injection "${String(key)}" not found.`);
3205
+ }
3206
+ } else {
3207
+ warn$1(`inject() can only be used inside setup() or functional components.`);
3208
+ }
3209
+ }
3210
+ function hasInjectionContext() {
3211
+ return !!(getCurrentGenericInstance() || currentApp);
3212
+ }
3213
+
3214
+ const ssrContextKey = /* @__PURE__ */ Symbol.for("v-scx");
3215
+ const useSSRContext = () => {
3216
+ {
3217
+ warn$1(`useSSRContext() is not supported in the global build.`);
3218
+ }
3219
+ };
3220
+
3221
+ function watchEffect(effect, options) {
3222
+ return doWatch(effect, null, options);
3223
+ }
3224
+ function watchPostEffect(effect, options) {
3225
+ return doWatch(
3226
+ effect,
3227
+ null,
3228
+ extend({}, options, { flush: "post" })
3229
+ );
3230
+ }
3231
+ function watchSyncEffect(effect, options) {
3232
+ return doWatch(
3233
+ effect,
3234
+ null,
3235
+ extend({}, options, { flush: "sync" })
3236
+ );
3237
+ }
3238
+ function watch(source, cb, options) {
3239
+ if (!isFunction(cb)) {
3240
+ warn$1(
3241
+ `\`watch(fn, options?)\` signature has been moved to a separate API. Use \`watchEffect(fn, options?)\` instead. \`watch\` now only supports \`watch(source, cb, options?) signature.`
3242
+ );
3243
+ }
3244
+ return doWatch(source, cb, options);
3245
+ }
3246
+ class RenderWatcherEffect extends WatcherEffect {
3247
+ constructor(instance, source, cb, options, flush) {
3248
+ super(source, cb, options);
3249
+ this.flush = flush;
3250
+ const job = () => {
3251
+ if (this.dirty) {
3252
+ this.run();
3253
+ }
3254
+ };
3255
+ if (cb) {
3256
+ this.flags |= 128;
3257
+ job.flags |= 2;
3258
+ }
3259
+ if (instance) {
3260
+ job.i = instance;
3261
+ }
3262
+ this.job = job;
3263
+ }
3264
+ notify() {
3265
+ const flags = this.flags;
3266
+ if (!(flags & 256)) {
3267
+ const flush = this.flush;
3268
+ const job = this.job;
3269
+ if (flush === "post") {
3270
+ queuePostRenderEffect(job, void 0, job.i ? job.i.suspense : null);
3271
+ } else if (flush === "pre") {
3272
+ queueJob(job, job.i ? job.i.uid : void 0, true);
3273
+ } else {
3274
+ job();
3275
+ }
3276
+ }
3277
+ }
3278
+ }
3279
+ function doWatch(source, cb, options = EMPTY_OBJ) {
3280
+ const { immediate, deep, flush = "pre", once } = options;
3281
+ if (!cb) {
3282
+ if (immediate !== void 0) {
3283
+ warn$1(
3284
+ `watch() "immediate" option is only respected when using the watch(source, callback, options?) signature.`
3285
+ );
3286
+ }
3287
+ if (deep !== void 0) {
3288
+ warn$1(
3289
+ `watch() "deep" option is only respected when using the watch(source, callback, options?) signature.`
3290
+ );
3291
+ }
3292
+ if (once !== void 0) {
3293
+ warn$1(
3294
+ `watch() "once" option is only respected when using the watch(source, callback, options?) signature.`
3295
+ );
3296
+ }
3297
+ }
3298
+ const baseWatchOptions = extend({}, options);
3299
+ baseWatchOptions.onWarn = warn$1;
3300
+ const instance = currentInstance;
3301
+ baseWatchOptions.call = (fn, type, args) => callWithAsyncErrorHandling(fn, instance, type, args);
3302
+ const effect = new RenderWatcherEffect(
3303
+ instance,
3304
+ source,
3305
+ cb,
3306
+ baseWatchOptions,
3307
+ flush
3308
+ );
3309
+ if (cb) {
3310
+ effect.run(true);
3311
+ } else if (flush === "post") {
3312
+ queuePostRenderEffect(effect.job, void 0, instance && instance.suspense);
3313
+ } else {
3314
+ effect.run(true);
3315
+ }
3316
+ const stop = effect.stop.bind(effect);
3317
+ stop.pause = effect.pause.bind(effect);
3318
+ stop.resume = effect.resume.bind(effect);
3319
+ stop.stop = stop;
3320
+ return stop;
3321
+ }
3322
+ function instanceWatch(source, value, options) {
3323
+ const publicThis = this.proxy;
3324
+ const getter = isString(source) ? source.includes(".") ? createPathGetter(publicThis, source) : () => publicThis[source] : source.bind(publicThis, publicThis);
3325
+ let cb;
3326
+ if (isFunction(value)) {
3327
+ cb = value;
3328
+ } else {
3329
+ cb = value.handler;
3330
+ options = value;
3331
+ }
3332
+ const prev = setCurrentInstance(this);
3333
+ const res = doWatch(getter, cb.bind(publicThis), options);
3334
+ setCurrentInstance(...prev);
3335
+ return res;
3336
+ }
3337
+ function createPathGetter(ctx, path) {
3338
+ const segments = path.split(".");
3339
+ return () => {
3340
+ let cur = ctx;
3341
+ for (let i = 0; i < segments.length && cur; i++) {
3342
+ cur = cur[segments[i]];
3343
+ }
3344
+ return cur;
3345
+ };
3346
+ }
3347
+
3348
+ const TeleportEndKey = /* @__PURE__ */ Symbol("_vte");
3183
3349
  const isTeleport = (type) => type.__isTeleport;
3184
3350
  const isTeleportDisabled = (props) => props && (props.disabled || props.disabled === "");
3185
3351
  const isTeleportDeferred = (props) => props && (props.defer || props.defer === "");
@@ -3551,8 +3717,8 @@ var VueRuntimeDOM = (function (exports) {
3551
3717
  return targetAnchor;
3552
3718
  }
3553
3719
 
3554
- const leaveCbKey = Symbol("_leaveCb");
3555
- const enterCbKey$1 = Symbol("_enterCb");
3720
+ const leaveCbKey = /* @__PURE__ */ Symbol("_leaveCb");
3721
+ const enterCbKey$1 = /* @__PURE__ */ Symbol("_enterCb");
3556
3722
  function useTransitionState() {
3557
3723
  const state = {
3558
3724
  isMounted: false,
@@ -4805,9 +4971,17 @@ Server rendered element contains fewer child nodes than client vdom.`
4805
4971
  }
4806
4972
  }
4807
4973
 
4808
- const requestIdleCallback = getGlobalThis().requestIdleCallback || ((cb) => setTimeout(cb, 1));
4809
- const cancelIdleCallback = getGlobalThis().cancelIdleCallback || ((id) => clearTimeout(id));
4974
+ let requestIdleCallback;
4975
+ let cancelIdleCallback;
4976
+ function ensureIdleCallbacks() {
4977
+ if (!requestIdleCallback) {
4978
+ const g = getGlobalThis();
4979
+ requestIdleCallback = g.requestIdleCallback || ((cb) => setTimeout(cb, 1));
4980
+ cancelIdleCallback = g.cancelIdleCallback || ((id) => clearTimeout(id));
4981
+ }
4982
+ }
4810
4983
  const hydrateOnIdle = (timeout = 1e4) => (hydrate) => {
4984
+ ensureIdleCallbacks();
4811
4985
  const id = requestIdleCallback(hydrate, { timeout });
4812
4986
  return () => cancelIdleCallback(id);
4813
4987
  };
@@ -5159,7 +5333,9 @@ Server rendered element contains fewer child nodes than client vdom.`
5159
5333
  }
5160
5334
  function pruneCache(filter) {
5161
5335
  cache.forEach((vnode, key) => {
5162
- const name = getComponentName(vnode.type);
5336
+ const name = getComponentName(
5337
+ isAsyncWrapper(vnode) ? vnode.type.__asyncResolved || {} : vnode.type
5338
+ );
5163
5339
  if (name && !filter(name)) {
5164
5340
  pruneCacheEntry(key);
5165
5341
  }
@@ -5461,7 +5637,7 @@ Server rendered element contains fewer child nodes than client vdom.`
5461
5637
  function resolveComponent(name, maybeSelfReference) {
5462
5638
  return resolveAsset(COMPONENTS, name, true, maybeSelfReference) || name;
5463
5639
  }
5464
- const NULL_DYNAMIC_COMPONENT = Symbol.for("v-ndc");
5640
+ const NULL_DYNAMIC_COMPONENT = /* @__PURE__ */ Symbol.for("v-ndc");
5465
5641
  function resolveDynamicComponent(component) {
5466
5642
  if (isString(component)) {
5467
5643
  return resolveAsset(COMPONENTS, component, false) || component;
@@ -5652,14 +5828,14 @@ If this is a native custom element, make sure to exclude it from component resol
5652
5828
  }
5653
5829
  }
5654
5830
 
5655
- function toHandlers(obj, preserveCaseIfNecessary) {
5831
+ function toHandlers(obj, preserveCaseIfNecessary, needWrap) {
5656
5832
  const ret = {};
5657
5833
  if (!isObject(obj)) {
5658
5834
  warn$1(`v-on with no argument expects an object value.`);
5659
5835
  return ret;
5660
5836
  }
5661
5837
  for (const key in obj) {
5662
- ret[preserveCaseIfNecessary && /[A-Z]/.test(key) ? `on:${key}` : toHandlerKey(key)] = obj[key];
5838
+ ret[preserveCaseIfNecessary && /[A-Z]/.test(key) ? `on:${key}` : toHandlerKey(key)] = needWrap ? () => obj[key] : obj[key];
5663
5839
  }
5664
5840
  return ret;
5665
5841
  }
@@ -6628,174 +6804,6 @@ If you want to remount the same app, move your app creation logic into a factory
6628
6804
  }
6629
6805
  let currentApp = null;
6630
6806
 
6631
- function provide(key, value) {
6632
- {
6633
- if (!currentInstance || currentInstance.isMounted) {
6634
- warn$1(`provide() can only be used inside setup().`);
6635
- }
6636
- }
6637
- if (currentInstance) {
6638
- let provides = currentInstance.provides;
6639
- const parentProvides = currentInstance.parent && currentInstance.parent.provides;
6640
- if (parentProvides === provides) {
6641
- provides = currentInstance.provides = Object.create(parentProvides);
6642
- }
6643
- provides[key] = value;
6644
- }
6645
- }
6646
- function inject(key, defaultValue, treatDefaultAsFactory = false) {
6647
- const instance = getCurrentGenericInstance();
6648
- if (instance || currentApp) {
6649
- let provides = currentApp ? currentApp._context.provides : instance ? instance.parent == null || instance.ce ? instance.appContext && instance.appContext.provides : instance.parent.provides : void 0;
6650
- if (provides && key in provides) {
6651
- return provides[key];
6652
- } else if (arguments.length > 1) {
6653
- return treatDefaultAsFactory && isFunction(defaultValue) ? defaultValue.call(instance && instance.proxy) : defaultValue;
6654
- } else {
6655
- warn$1(`injection "${String(key)}" not found.`);
6656
- }
6657
- } else {
6658
- warn$1(`inject() can only be used inside setup() or functional components.`);
6659
- }
6660
- }
6661
- function hasInjectionContext() {
6662
- return !!(getCurrentGenericInstance() || currentApp);
6663
- }
6664
-
6665
- const ssrContextKey = Symbol.for("v-scx");
6666
- const useSSRContext = () => {
6667
- {
6668
- warn$1(`useSSRContext() is not supported in the global build.`);
6669
- }
6670
- };
6671
-
6672
- function watchEffect(effect, options) {
6673
- return doWatch(effect, null, options);
6674
- }
6675
- function watchPostEffect(effect, options) {
6676
- return doWatch(
6677
- effect,
6678
- null,
6679
- extend({}, options, { flush: "post" })
6680
- );
6681
- }
6682
- function watchSyncEffect(effect, options) {
6683
- return doWatch(
6684
- effect,
6685
- null,
6686
- extend({}, options, { flush: "sync" })
6687
- );
6688
- }
6689
- function watch(source, cb, options) {
6690
- if (!isFunction(cb)) {
6691
- warn$1(
6692
- `\`watch(fn, options?)\` signature has been moved to a separate API. Use \`watchEffect(fn, options?)\` instead. \`watch\` now only supports \`watch(source, cb, options?) signature.`
6693
- );
6694
- }
6695
- return doWatch(source, cb, options);
6696
- }
6697
- class RenderWatcherEffect extends WatcherEffect {
6698
- constructor(instance, source, cb, options, flush) {
6699
- super(source, cb, options);
6700
- this.flush = flush;
6701
- const job = () => {
6702
- if (this.dirty) {
6703
- this.run();
6704
- }
6705
- };
6706
- if (cb) {
6707
- this.flags |= 128;
6708
- job.flags |= 2;
6709
- }
6710
- if (instance) {
6711
- job.i = instance;
6712
- }
6713
- this.job = job;
6714
- }
6715
- notify() {
6716
- const flags = this.flags;
6717
- if (!(flags & 256)) {
6718
- const flush = this.flush;
6719
- const job = this.job;
6720
- if (flush === "post") {
6721
- queuePostRenderEffect(job, void 0, job.i ? job.i.suspense : null);
6722
- } else if (flush === "pre") {
6723
- queueJob(job, job.i ? job.i.uid : void 0, true);
6724
- } else {
6725
- job();
6726
- }
6727
- }
6728
- }
6729
- }
6730
- function doWatch(source, cb, options = EMPTY_OBJ) {
6731
- const { immediate, deep, flush = "pre", once } = options;
6732
- if (!cb) {
6733
- if (immediate !== void 0) {
6734
- warn$1(
6735
- `watch() "immediate" option is only respected when using the watch(source, callback, options?) signature.`
6736
- );
6737
- }
6738
- if (deep !== void 0) {
6739
- warn$1(
6740
- `watch() "deep" option is only respected when using the watch(source, callback, options?) signature.`
6741
- );
6742
- }
6743
- if (once !== void 0) {
6744
- warn$1(
6745
- `watch() "once" option is only respected when using the watch(source, callback, options?) signature.`
6746
- );
6747
- }
6748
- }
6749
- const baseWatchOptions = extend({}, options);
6750
- baseWatchOptions.onWarn = warn$1;
6751
- const instance = currentInstance;
6752
- baseWatchOptions.call = (fn, type, args) => callWithAsyncErrorHandling(fn, instance, type, args);
6753
- const effect = new RenderWatcherEffect(
6754
- instance,
6755
- source,
6756
- cb,
6757
- baseWatchOptions,
6758
- flush
6759
- );
6760
- if (cb) {
6761
- effect.run(true);
6762
- } else if (flush === "post") {
6763
- queuePostRenderEffect(effect.job, void 0, instance && instance.suspense);
6764
- } else {
6765
- effect.run(true);
6766
- }
6767
- const stop = effect.stop.bind(effect);
6768
- stop.pause = effect.pause.bind(effect);
6769
- stop.resume = effect.resume.bind(effect);
6770
- stop.stop = stop;
6771
- return stop;
6772
- }
6773
- function instanceWatch(source, value, options) {
6774
- const publicThis = this.proxy;
6775
- const getter = isString(source) ? source.includes(".") ? createPathGetter(publicThis, source) : () => publicThis[source] : source.bind(publicThis, publicThis);
6776
- let cb;
6777
- if (isFunction(value)) {
6778
- cb = value;
6779
- } else {
6780
- cb = value.handler;
6781
- options = value;
6782
- }
6783
- const prev = setCurrentInstance(this);
6784
- const res = doWatch(getter, cb.bind(publicThis), options);
6785
- setCurrentInstance(...prev);
6786
- return res;
6787
- }
6788
- function createPathGetter(ctx, path) {
6789
- const segments = path.split(".");
6790
- return () => {
6791
- let cur = ctx;
6792
- for (let i = 0; i < segments.length && cur; i++) {
6793
- cur = cur[segments[i]];
6794
- }
6795
- return cur;
6796
- };
6797
- }
6798
-
6799
6807
  function useModel(props, name, options = EMPTY_OBJ) {
6800
6808
  const i = getCurrentGenericInstance();
6801
6809
  if (!i) {
@@ -7880,6 +7888,14 @@ If you want to remount the same app, move your app creation logic into a factory
7880
7888
  return supported;
7881
7889
  }
7882
7890
 
7891
+ const MoveType = {
7892
+ "ENTER": 0,
7893
+ "0": "ENTER",
7894
+ "LEAVE": 1,
7895
+ "1": "LEAVE",
7896
+ "REORDER": 2,
7897
+ "2": "REORDER"
7898
+ };
7883
7899
  const queuePostRenderEffect = queueEffectWithSuspense ;
7884
7900
  function createRenderer(options) {
7885
7901
  return baseCreateRenderer(options);
@@ -8028,7 +8044,15 @@ If you want to remount the same app, move your app creation logic into a factory
8028
8044
  } else {
8029
8045
  const el = n2.el = n1.el;
8030
8046
  if (n2.children !== n1.children) {
8031
- hostSetText(el, n2.children);
8047
+ if (isHmrUpdating && n2.patchFlag === -1 && "__elIndex" in n1) {
8048
+ const childNodes = container.childNodes;
8049
+ const newChild = hostCreateText(n2.children);
8050
+ const oldChild = childNodes[n2.__elIndex = n1.__elIndex];
8051
+ hostInsert(newChild, container, oldChild);
8052
+ hostRemove(oldChild);
8053
+ } else {
8054
+ hostSetText(el, n2.children);
8055
+ }
8032
8056
  }
8033
8057
  }
8034
8058
  };
@@ -8414,7 +8438,7 @@ If you want to remount the same app, move your app creation logic into a factory
8414
8438
  } else {
8415
8439
  if (patchFlag > 0 && patchFlag & 64 && dynamicChildren && // #2715 the previous fragment could've been a BAILed one as a result
8416
8440
  // of renderSlot() with no valid children
8417
- n1.dynamicChildren) {
8441
+ n1.dynamicChildren && n1.dynamicChildren.length === dynamicChildren.length) {
8418
8442
  patchBlockChildren(
8419
8443
  n1.dynamicChildren,
8420
8444
  dynamicChildren,
@@ -9102,8 +9126,8 @@ If you want to remount the same app, move your app creation logic into a factory
9102
9126
  const nextChild = c2[nextIndex];
9103
9127
  const anchorVNode = c2[nextIndex + 1];
9104
9128
  const anchor = nextIndex + 1 < l2 ? (
9105
- // #13559, fallback to el placeholder for unresolved async component
9106
- anchorVNode.el || anchorVNode.placeholder
9129
+ // #13559, #14173 fallback to el placeholder for unresolved async component
9130
+ anchorVNode.el || resolveAsyncComponentPlaceholder(anchorVNode)
9107
9131
  ) : parentAnchor;
9108
9132
  if (newIndexToOldIndexMap[i] === 0) {
9109
9133
  patch(
@@ -9408,9 +9432,11 @@ If you want to remount the same app, move your app creation logic into a factory
9408
9432
  return teleportEnd ? hostNextSibling(teleportEnd) : el;
9409
9433
  };
9410
9434
  const render = (vnode, container, namespace) => {
9435
+ let instance;
9411
9436
  if (vnode == null) {
9412
9437
  if (container._vnode) {
9413
9438
  unmount(container._vnode, null, null, true);
9439
+ instance = container._vnode.component;
9414
9440
  }
9415
9441
  } else {
9416
9442
  patch(
@@ -9424,7 +9450,7 @@ If you want to remount the same app, move your app creation logic into a factory
9424
9450
  );
9425
9451
  }
9426
9452
  container._vnode = vnode;
9427
- flushOnAppMount();
9453
+ flushOnAppMount(instance);
9428
9454
  };
9429
9455
  const internals = {
9430
9456
  p: patch,
@@ -9514,9 +9540,13 @@ If you want to remount the same app, move your app creation logic into a factory
9514
9540
  if (!shallow && c2.patchFlag !== -2)
9515
9541
  traverseStaticChildren(c1, c2);
9516
9542
  }
9517
- if (c2.type === Text && // avoid cached text nodes retaining detached dom nodes
9518
- c2.patchFlag !== -1) {
9519
- c2.el = c1.el;
9543
+ if (c2.type === Text) {
9544
+ if (c2.patchFlag !== -1) {
9545
+ c2.el = c1.el;
9546
+ } else {
9547
+ c2.__elIndex = i + // take fragment start anchor into account
9548
+ (n1.type === Fragment ? 1 : 0);
9549
+ }
9520
9550
  }
9521
9551
  if (c2.type === Comment && !c2.el) {
9522
9552
  c2.el = c1.el;
@@ -9552,16 +9582,24 @@ If you want to remount the same app, move your app creation logic into a factory
9552
9582
  insert();
9553
9583
  }
9554
9584
  }
9555
- function performTransitionLeave(el, transition, remove, isElement = true) {
9585
+ function performTransitionLeave(el, transition, remove, isElement = true, force = false) {
9556
9586
  const performRemove = () => {
9557
9587
  remove();
9558
9588
  if (transition && !transition.persisted && transition.afterLeave) {
9559
9589
  transition.afterLeave();
9560
9590
  }
9561
9591
  };
9562
- if (isElement && transition && !transition.persisted) {
9592
+ if (force || isElement && transition && !transition.persisted) {
9563
9593
  const { leave, delayLeave } = transition;
9564
- const performLeave = () => leave(el, performRemove);
9594
+ const performLeave = () => {
9595
+ if (el._isLeaving && force) {
9596
+ el[leaveCbKey](
9597
+ true
9598
+ /* cancelled */
9599
+ );
9600
+ }
9601
+ leave(el, performRemove);
9602
+ };
9565
9603
  if (delayLeave) {
9566
9604
  delayLeave(el, performRemove, performLeave);
9567
9605
  } else {
@@ -9617,6 +9655,16 @@ app.use(vaporInteropPlugin)
9617
9655
  }
9618
9656
  return inheritedScopeIds;
9619
9657
  }
9658
+ function resolveAsyncComponentPlaceholder(anchorVnode) {
9659
+ if (anchorVnode.placeholder) {
9660
+ return anchorVnode.placeholder;
9661
+ }
9662
+ const instance = anchorVnode.component;
9663
+ if (instance) {
9664
+ return resolveAsyncComponentPlaceholder(instance.subTree);
9665
+ }
9666
+ return null;
9667
+ }
9620
9668
 
9621
9669
  const isSuspense = (type) => type.__isSuspense;
9622
9670
  let suspenseId = 0;
@@ -10111,7 +10159,7 @@ app.use(vaporInteropPlugin)
10111
10159
  parentSuspense,
10112
10160
  parentComponent,
10113
10161
  node.parentNode,
10114
- // eslint-disable-next-line no-restricted-globals
10162
+ // oxlint-disable-next-line no-restricted-globals
10115
10163
  document.createElement("div"),
10116
10164
  null,
10117
10165
  namespace,
@@ -10199,11 +10247,11 @@ app.use(vaporInteropPlugin)
10199
10247
  return suspensible != null && suspensible !== false;
10200
10248
  }
10201
10249
 
10202
- const Fragment = Symbol.for("v-fgt");
10203
- const Text = Symbol.for("v-txt");
10204
- const Comment = Symbol.for("v-cmt");
10205
- const Static = Symbol.for("v-stc");
10206
- const VaporSlot = Symbol.for("v-vps");
10250
+ const Fragment = /* @__PURE__ */ Symbol.for("v-fgt");
10251
+ const Text = /* @__PURE__ */ Symbol.for("v-txt");
10252
+ const Comment = /* @__PURE__ */ Symbol.for("v-cmt");
10253
+ const Static = /* @__PURE__ */ Symbol.for("v-stc");
10254
+ const VaporSlot = /* @__PURE__ */ Symbol.for("v-vps");
10207
10255
  const blockStack = [];
10208
10256
  let currentBlock = null;
10209
10257
  function openBlock(disableTracking = false) {
@@ -10595,7 +10643,7 @@ Component that was made reactive: `,
10595
10643
  simpleSetCurrentInstance(instance);
10596
10644
  }
10597
10645
  };
10598
- const internalOptions = ["ce", "type"];
10646
+ const internalOptions = ["ce", "type", "uid"];
10599
10647
  const useInstanceOption = (key, silent = false) => {
10600
10648
  const instance = getCurrentGenericInstance();
10601
10649
  if (!instance) {
@@ -10615,7 +10663,7 @@ Component that was made reactive: `,
10615
10663
  return { hasInstance: true, value: instance[key] };
10616
10664
  };
10617
10665
 
10618
- const emptyAppContext = createAppContext();
10666
+ const emptyAppContext = /* @__PURE__ */ createAppContext();
10619
10667
  let uid = 0;
10620
10668
  function createComponentInstance(vnode, parent, suspense) {
10621
10669
  const type = vnode.type;
@@ -11245,7 +11293,7 @@ Component that was made reactive: `,
11245
11293
  return true;
11246
11294
  }
11247
11295
 
11248
- const version = "3.6.0-alpha.7";
11296
+ const version = "3.6.0-beta.2";
11249
11297
  const warn = warn$1 ;
11250
11298
  const ErrorTypeStrings = ErrorTypeStrings$1 ;
11251
11299
  const devtools = devtools$1 ;
@@ -11338,7 +11386,7 @@ Component that was made reactive: `,
11338
11386
 
11339
11387
  const TRANSITION = "transition";
11340
11388
  const ANIMATION = "animation";
11341
- const vtcKey = Symbol("_vtc");
11389
+ const vtcKey = /* @__PURE__ */ Symbol("_vtc");
11342
11390
  const DOMTransitionPropsValidators = {
11343
11391
  name: String,
11344
11392
  type: String,
@@ -11631,8 +11679,8 @@ Component that was made reactive: `,
11631
11679
  }
11632
11680
  }
11633
11681
 
11634
- const vShowOriginalDisplay = Symbol("_vod");
11635
- const vShowHidden = Symbol("_vsh");
11682
+ const vShowOriginalDisplay = /* @__PURE__ */ Symbol("_vod");
11683
+ const vShowHidden = /* @__PURE__ */ Symbol("_vsh");
11636
11684
  const vShow = {
11637
11685
  // used for prop mismatch check during hydration
11638
11686
  name: "show",
@@ -11674,7 +11722,7 @@ Component that was made reactive: `,
11674
11722
  el[vShowHidden] = !value;
11675
11723
  }
11676
11724
 
11677
- const CSS_VAR_TEXT = Symbol("CSS_VAR_TEXT" );
11725
+ const CSS_VAR_TEXT = /* @__PURE__ */ Symbol("CSS_VAR_TEXT" );
11678
11726
  function useCssVars(getter) {
11679
11727
  const instance = getCurrentInstance();
11680
11728
  const getVars = () => getter(instance.proxy);
@@ -11935,7 +11983,7 @@ Component that was made reactive: `,
11935
11983
  function removeEventListener(el, event, handler, options) {
11936
11984
  el.removeEventListener(event, handler, options);
11937
11985
  }
11938
- const veiKey = Symbol("_vei");
11986
+ const veiKey = /* @__PURE__ */ Symbol("_vei");
11939
11987
  function patchEvent(el, rawName, prevValue, nextValue, instance = null) {
11940
11988
  const invokers = el[veiKey] || (el[veiKey] = {});
11941
11989
  const existingInvoker = invokers[rawName];
@@ -12585,8 +12633,8 @@ Expected function or array of functions, received type ${typeof value}.`
12585
12633
 
12586
12634
  const positionMap = /* @__PURE__ */ new WeakMap();
12587
12635
  const newPositionMap = /* @__PURE__ */ new WeakMap();
12588
- const moveCbKey = Symbol("_moveCb");
12589
- const enterCbKey = Symbol("_enterCb");
12636
+ const moveCbKey = /* @__PURE__ */ Symbol("_moveCb");
12637
+ const enterCbKey = /* @__PURE__ */ Symbol("_enterCb");
12590
12638
  const decorate = (t) => {
12591
12639
  delete t.props.mode;
12592
12640
  return t;
@@ -12749,7 +12797,7 @@ Expected function or array of functions, received type ${typeof value}.`
12749
12797
  target.dispatchEvent(new Event("input"));
12750
12798
  }
12751
12799
  }
12752
- const assignKey = Symbol("_assign");
12800
+ const assignKey = /* @__PURE__ */ Symbol("_assign");
12753
12801
  const vModelText = {
12754
12802
  created(el, { modifiers: { lazy, trim, number } }, vnode) {
12755
12803
  el[assignKey] = getModelAssigner(vnode);
@@ -13194,6 +13242,7 @@ Expected function or array of functions, received type ${typeof value}.`
13194
13242
  exports.ErrorTypeStrings = ErrorTypeStrings;
13195
13243
  exports.Fragment = Fragment;
13196
13244
  exports.KeepAlive = KeepAlive;
13245
+ exports.MoveType = MoveType;
13197
13246
  exports.ReactiveEffect = ReactiveEffect;
13198
13247
  exports.Static = Static;
13199
13248
  exports.Suspense = Suspense;