@vue/runtime-core 3.6.0-rc.4 → 3.6.0-rc.6

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-core v3.6.0-rc.4
2
+ * @vue/runtime-core v3.6.0-rc.6
3
3
  * (c) 2018-present Yuxi (Evan) You and Vue contributors
4
4
  * @license MIT
5
5
  **/
@@ -256,7 +256,7 @@ let currentFlushPromise = null;
256
256
  let jobsLength = 0;
257
257
  let flushIndex = 0;
258
258
  let postFlushIndex = 0;
259
- const resolvedPromise = /* @__PURE__ */ Promise.resolve();
259
+ const resolvedPromise = /*@__PURE__*/ Promise.resolve();
260
260
  const RECURSION_LIMIT = 100;
261
261
  function nextTick(fn) {
262
262
  const p = currentFlushPromise || resolvedPromise;
@@ -295,6 +295,7 @@ const doFlushJobs = () => {
295
295
  flushJobs();
296
296
  } catch (e) {
297
297
  currentFlushPromise = null;
298
+ if (jobsLength || postJobs.length) queueFlush();
298
299
  throw e;
299
300
  }
300
301
  };
@@ -302,9 +303,10 @@ function queueFlush() {
302
303
  if (!currentFlushPromise) currentFlushPromise = resolvedPromise.then(doFlushJobs);
303
304
  }
304
305
  function queuePostFlushCb(jobs, id = Infinity) {
305
- if (!(0, _vue_shared.isArray)(jobs)) if (activePostJobs && id === -1) activePostJobs.splice(postFlushIndex, 0, jobs);
306
- else queueJobWorker(jobs, id, postJobs, postJobs.length, 0);
307
- else for (let i = 0; i < jobs.length; i++) queueJobWorker(jobs[i], id, postJobs, postJobs.length, 0);
306
+ if (!(0, _vue_shared.isArray)(jobs)) {
307
+ if (activePostJobs && id === -1) activePostJobs.splice(postFlushIndex, 0, jobs);
308
+ else queueJobWorker(jobs, id, postJobs, postJobs.length, 0);
309
+ } else for (let i = 0; i < jobs.length; i++) queueJobWorker(jobs[i], id, postJobs, postJobs.length, 0);
308
310
  queueFlush();
309
311
  }
310
312
  function flushPreFlushCbs(instance, seen) {
@@ -318,8 +320,11 @@ function flushPreFlushCbs(instance, seen) {
318
320
  i--;
319
321
  jobsLength--;
320
322
  if (cb.flags & 2) cb.flags &= -2;
321
- cb();
322
- if (!(cb.flags & 2)) cb.flags &= -2;
323
+ try {
324
+ cb();
325
+ } finally {
326
+ if (!(cb.flags & 2)) cb.flags &= -2;
327
+ }
323
328
  }
324
329
  }
325
330
  function flushPostFlushCbs(seen) {
@@ -332,18 +337,22 @@ function flushPostFlushCbs(seen) {
332
337
  activePostJobs = postJobs;
333
338
  postJobs = [];
334
339
  seen = seen || /* @__PURE__ */ new Map();
335
- while (postFlushIndex < activePostJobs.length) {
336
- const cb = activePostJobs[postFlushIndex++];
337
- if (checkRecursiveUpdates(seen, cb)) continue;
338
- if (cb.flags & 2) cb.flags &= -2;
339
- if (!(cb.flags & 4)) try {
340
- cb();
341
- } finally {
342
- cb.flags &= -2;
340
+ try {
341
+ while (postFlushIndex < activePostJobs.length) {
342
+ const cb = activePostJobs[postFlushIndex++];
343
+ if (checkRecursiveUpdates(seen, cb)) continue;
344
+ if (cb.flags & 2) cb.flags &= -2;
345
+ if (!(cb.flags & 4)) try {
346
+ cb();
347
+ } finally {
348
+ if (!(cb.flags & 2)) cb.flags &= -2;
349
+ }
343
350
  }
351
+ } finally {
352
+ while (postFlushIndex < activePostJobs.length) activePostJobs[postFlushIndex++].flags &= -2;
353
+ activePostJobs = null;
354
+ postFlushIndex = 0;
344
355
  }
345
- activePostJobs = null;
346
- postFlushIndex = 0;
347
356
  }
348
357
  }
349
358
  let isFlushing = false;
@@ -353,9 +362,12 @@ let isFlushing = false;
353
362
  function flushOnAppMount(instance) {
354
363
  if (!isFlushing) {
355
364
  isFlushing = true;
356
- flushPreFlushCbs(instance);
357
- flushPostFlushCbs();
358
- isFlushing = false;
365
+ try {
366
+ flushPreFlushCbs(instance);
367
+ flushPostFlushCbs();
368
+ } finally {
369
+ isFlushing = false;
370
+ }
359
371
  }
360
372
  }
361
373
  function flushJobs(seen) {
@@ -385,8 +397,8 @@ function flushJobs(seen) {
385
397
  jobsLength = 0;
386
398
  jobs.length = 0;
387
399
  flushPostFlushCbs(seen);
388
- currentFlushPromise = null;
389
400
  if (jobsLength || postJobs.length) flushJobs(seen);
401
+ else currentFlushPromise = null;
390
402
  }
391
403
  }
392
404
  function checkRecursiveUpdates(seen, fn) {
@@ -417,6 +429,19 @@ const hmrDirtyComponentsMode = /* @__PURE__ */ new Map();
417
429
  rerender: tryWrap(rerender),
418
430
  reload: tryWrap(reload)
419
431
  };
432
+ function runWithHmrUpdating(fn) {
433
+ isHmrUpdating = true;
434
+ let done = false;
435
+ try {
436
+ fn();
437
+ done = true;
438
+ } finally {
439
+ if (done) nextTick(() => {
440
+ isHmrUpdating = false;
441
+ });
442
+ else isHmrUpdating = false;
443
+ }
444
+ }
420
445
  const map = /* @__PURE__ */ new Map();
421
446
  function registerHMR(instance) {
422
447
  const id = instance.type.__hmrId;
@@ -458,18 +483,16 @@ function rerender(id, newRender) {
458
483
  instance.render = newRender;
459
484
  normalizeClassComponent(instance.type).render = newRender;
460
485
  }
461
- isHmrUpdating = true;
462
- if (instance.vapor) {
463
- if (!instance.isUnmounted) instance.hmrRerender();
464
- } else {
465
- const i = instance;
466
- if (!(i.effect.flags & 1024)) {
467
- i.renderCache = [];
468
- i.effect.run();
486
+ runWithHmrUpdating(() => {
487
+ if (instance.vapor) {
488
+ if (!instance.isUnmounted) instance.hmrRerender();
489
+ } else {
490
+ const i = instance;
491
+ if (!(i.effect.flags & 1024)) {
492
+ i.renderCache = [];
493
+ i.effect.run();
494
+ }
469
495
  }
470
- }
471
- nextTick(() => {
472
- isHmrUpdating = false;
473
496
  });
474
497
  });
475
498
  }
@@ -484,15 +507,17 @@ function reload(id, newComp) {
484
507
  for (const instance of instances) if (instance.root && instance.root.ce && instance !== instance.root) instance.root.ce._removeChildStyle(instance.type);
485
508
  const dirtyInstances = new Set(instances);
486
509
  const rerenderedParents = /* @__PURE__ */ new Set();
487
- for (const instance of instances) {
488
- const parent = instance.parent;
489
- if (parent) {
490
- if (!hasDirtyAncestor(instance, dirtyInstances) && !rerenderedParents.has(parent)) {
491
- rerenderedParents.add(parent);
492
- parent.hmrRerender();
493
- }
494
- } else instance.hmrReload(newComp);
495
- }
510
+ runWithHmrUpdating(() => {
511
+ for (const instance of instances) {
512
+ const parent = instance.parent;
513
+ if (parent) {
514
+ if (!hasDirtyAncestor(instance, dirtyInstances) && !rerenderedParents.has(parent)) {
515
+ rerenderedParents.add(parent);
516
+ parent.hmrRerender();
517
+ }
518
+ } else instance.hmrReload(newComp);
519
+ }
520
+ });
496
521
  } else {
497
522
  const parentUpdates = /* @__PURE__ */ new Map();
498
523
  const dirtyInstanceSet = new Set(instances);
@@ -526,21 +551,22 @@ function reload(id, newComp) {
526
551
  }
527
552
  parentUpdates.forEach((updates, parent) => {
528
553
  queueJob(() => {
529
- isHmrUpdating = true;
530
- if (parent.vapor) parent.hmrRerender();
531
- else {
532
- const i = parent;
533
- if (!(i.effect.flags & 1024)) {
534
- i.renderCache = [];
535
- i.effect.run();
536
- }
554
+ try {
555
+ runWithHmrUpdating(() => {
556
+ if (parent.vapor) parent.hmrRerender();
557
+ else {
558
+ const i = parent;
559
+ if (!(i.effect.flags & 1024)) {
560
+ i.renderCache = [];
561
+ i.effect.run();
562
+ }
563
+ }
564
+ });
565
+ } finally {
566
+ updates.forEach(([instance, dirtyInstances]) => {
567
+ dirtyInstances.delete(instance);
568
+ });
537
569
  }
538
- nextTick(() => {
539
- isHmrUpdating = false;
540
- });
541
- updates.forEach(([instance, dirtyInstances]) => {
542
- dirtyInstances.delete(instance);
543
- });
544
570
  });
545
571
  });
546
572
  }
@@ -609,20 +635,20 @@ function devtoolsInitApp(app, version) {
609
635
  function devtoolsUnmountApp(app) {
610
636
  emit$1("app:unmount", app);
611
637
  }
612
- const devtoolsComponentAdded = /* @__PURE__ */ createDevtoolsComponentHook("component:added");
613
- const devtoolsComponentUpdated = /* @__PURE__ */ createDevtoolsComponentHook("component:updated");
614
- const _devtoolsComponentRemoved = /* @__PURE__ */ createDevtoolsComponentHook("component:removed");
638
+ const devtoolsComponentAdded = /*@__PURE__*/ createDevtoolsComponentHook("component:added");
639
+ const devtoolsComponentUpdated = /*@__PURE__*/ createDevtoolsComponentHook("component:updated");
640
+ const _devtoolsComponentRemoved = /*@__PURE__*/ createDevtoolsComponentHook("component:removed");
615
641
  const devtoolsComponentRemoved = (component) => {
616
642
  if (devtools$1 && typeof devtools$1.cleanupBuffer === "function" && !devtools$1.cleanupBuffer(component)) _devtoolsComponentRemoved(component);
617
643
  };
618
- /* @__NO_SIDE_EFFECTS__ */
644
+ /*@__NO_SIDE_EFFECTS__*/
619
645
  function createDevtoolsComponentHook(hook) {
620
646
  return (component) => {
621
647
  emit$1(hook, component.appContext.app, component.uid, component.parent ? component.parent.uid : void 0, component);
622
648
  };
623
649
  }
624
- const devtoolsPerfStart = /* @__PURE__ */ createDevtoolsPerformanceHook("perf:start");
625
- const devtoolsPerfEnd = /* @__PURE__ */ createDevtoolsPerformanceHook("perf:end");
650
+ const devtoolsPerfStart = /*@__PURE__*/ createDevtoolsPerformanceHook("perf:start");
651
+ const devtoolsPerfEnd = /*@__PURE__*/ createDevtoolsPerformanceHook("perf:end");
626
652
  function createDevtoolsPerformanceHook(hook) {
627
653
  return (component, type, time) => {
628
654
  emit$1(hook, component.appContext.app, component.uid, component, type, time);
@@ -905,15 +931,16 @@ const isTargetSVG = (target) => typeof SVGElement !== "undefined" && target inst
905
931
  const isTargetMathML = (target) => typeof MathMLElement === "function" && target instanceof MathMLElement;
906
932
  const resolveTarget = (props, select) => {
907
933
  const targetSelector = props && props.to;
908
- if ((0, _vue_shared.isString)(targetSelector)) if (!select) {
909
- warn$1("Current renderer does not support string target for Teleports. (missing querySelector renderer option)");
910
- return null;
934
+ if ((0, _vue_shared.isString)(targetSelector)) {
935
+ if (!select) {
936
+ warn$1("Current renderer does not support string target for Teleports. (missing querySelector renderer option)");
937
+ return null;
938
+ } else {
939
+ const target = select(targetSelector);
940
+ if (!target && !isTeleportDisabled(props)) warn$1(`Failed to locate Teleport target with selector "${targetSelector}". Note the target element must exist before the component is mounted - i.e. the target cannot be rendered by the component itself, and ideally should be outside of the entire Vue component tree.`);
941
+ return target;
942
+ }
911
943
  } else {
912
- const target = select(targetSelector);
913
- if (!target && !isTeleportDisabled(props)) warn$1(`Failed to locate Teleport target with selector "${targetSelector}". Note the target element must exist before the component is mounted - i.e. the target cannot be rendered by the component itself, and ideally should be outside of the entire Vue component tree.`);
914
- return target;
915
- }
916
- else {
917
944
  if (!targetSelector && !isTeleportDisabled(props)) warn$1(`Invalid Teleport target: ${targetSelector}`);
918
945
  return targetSelector;
919
946
  }
@@ -951,7 +978,8 @@ const TeleportImpl = {
951
978
  if (pendingMounts.get(vnode) !== mountJob) return;
952
979
  pendingMounts.delete(vnode);
953
980
  if (isTeleportDisabled(vnode.props)) {
954
- mount(vnode, parentNode(vnode.el) || container, vnode.anchor);
981
+ const mountContainer = parentNode(vnode.el) || container;
982
+ mount(vnode, mountContainer, vnode.anchor);
955
983
  updateCssVars(vnode, true);
956
984
  }
957
985
  mountToTarget(vnode);
@@ -1060,15 +1088,17 @@ function hydrateTeleport(node, vnode, parentComponent, parentSuspense, slotScope
1060
1088
  const disabled = isTeleportDisabled(vnode.props);
1061
1089
  if (target) {
1062
1090
  const targetNode = target._lpa || target.firstChild;
1063
- if (vnode.shapeFlag & 16) if (disabled) {
1064
- hydrateDisabledTeleport(node, vnode);
1065
- hydrateAnchor(target, targetNode);
1066
- if (!vnode.targetAnchor) prepareAnchor(target, vnode, createText, insert, parentNode(node) === target ? node : null);
1067
- } else {
1068
- vnode.anchor = nextSibling(node);
1069
- hydrateAnchor(target, targetNode);
1070
- if (!vnode.targetAnchor) prepareAnchor(target, vnode, createText, insert);
1071
- hydrateChildren(targetNode && nextSibling(targetNode), vnode, target, parentComponent, parentSuspense, slotScopeIds, optimized);
1091
+ if (vnode.shapeFlag & 16) {
1092
+ if (disabled) {
1093
+ hydrateDisabledTeleport(node, vnode);
1094
+ hydrateAnchor(target, targetNode);
1095
+ if (!vnode.targetAnchor) prepareAnchor(target, vnode, createText, insert, parentNode(node) === target ? node : null);
1096
+ } else {
1097
+ vnode.anchor = nextSibling(node);
1098
+ hydrateAnchor(target, targetNode);
1099
+ if (!vnode.targetAnchor) prepareAnchor(target, vnode, createText, insert);
1100
+ hydrateChildren(targetNode && nextSibling(targetNode), vnode, target, parentComponent, parentSuspense, slotScopeIds, optimized);
1101
+ }
1072
1102
  }
1073
1103
  updateCssVars(vnode, disabled);
1074
1104
  } else if (disabled) {
@@ -1234,8 +1264,10 @@ function baseResolveTransitionHooks(context, props, state, instance) {
1234
1264
  persisted,
1235
1265
  beforeEnter(el) {
1236
1266
  let hook = onBeforeEnter;
1237
- if (!state.isMounted) if (appear) hook = onBeforeAppear || onBeforeEnter;
1238
- else return;
1267
+ if (!state.isMounted) {
1268
+ if (appear) hook = onBeforeAppear || onBeforeEnter;
1269
+ else return;
1270
+ }
1239
1271
  if (el[leaveCbKey]) el[leaveCbKey](true);
1240
1272
  earlyRemove();
1241
1273
  callHook(hook, [el]);
@@ -1245,11 +1277,13 @@ function baseResolveTransitionHooks(context, props, state, instance) {
1245
1277
  let hook = onEnter;
1246
1278
  let afterHook = onAfterEnter;
1247
1279
  let cancelHook = onEnterCancelled;
1248
- if (!state.isMounted) if (appear) {
1249
- hook = onAppear || onEnter;
1250
- afterHook = onAfterAppear || onAfterEnter;
1251
- cancelHook = onAppearCancelled || onEnterCancelled;
1252
- } else return;
1280
+ if (!state.isMounted) {
1281
+ if (appear) {
1282
+ hook = onAppear || onEnter;
1283
+ afterHook = onAfterAppear || onAfterEnter;
1284
+ cancelHook = onAppearCancelled || onEnterCancelled;
1285
+ } else return;
1286
+ }
1253
1287
  let called = false;
1254
1288
  el[enterCbKey] = (cancelled) => {
1255
1289
  if (called) return;
@@ -1415,9 +1449,9 @@ function checkTransitionMode(mode) {
1415
1449
  }
1416
1450
  //#endregion
1417
1451
  //#region packages/runtime-core/src/apiDefineComponent.ts
1418
- /* @__NO_SIDE_EFFECTS__ */
1452
+ /*@__NO_SIDE_EFFECTS__*/
1419
1453
  function defineComponent(options, extraOptions) {
1420
- return (0, _vue_shared.isFunction)(options) ? (0, _vue_shared.extend)({ name: options.name }, extraOptions, { setup: options }) : options;
1454
+ return (0, _vue_shared.isFunction)(options) ? /*@__PURE__*/ (() => (0, _vue_shared.extend)({ name: options.name }, extraOptions, { setup: options }))() : options;
1421
1455
  }
1422
1456
  //#endregion
1423
1457
  //#region packages/runtime-core/src/helpers/useId.ts
@@ -1514,15 +1548,16 @@ function setRef(rawRef, oldRawRef, parentSuspense, vnode, isUnmount = false) {
1514
1548
  if (rawRef.f) {
1515
1549
  const existing = _isString ? canSetSetupRef(ref) ? setupState[ref] : refs[ref] : canSetRef(ref) || !rawRef.k ? ref.value : refs[rawRef.k];
1516
1550
  if (isUnmount) (0, _vue_shared.isArray)(existing) && (0, _vue_shared.remove)(existing, refValue);
1517
- else if (!(0, _vue_shared.isArray)(existing)) if (_isString) {
1518
- refs[ref] = [refValue];
1519
- if (canSetSetupRef(ref)) setupState[ref] = refs[ref];
1520
- } else {
1521
- const newVal = [refValue];
1522
- if (canSetRef(ref, rawRef.k)) ref.value = newVal;
1523
- if (rawRef.k) refs[rawRef.k] = newVal;
1524
- }
1525
- else if (!existing.includes(refValue)) existing.push(refValue);
1551
+ else if (!(0, _vue_shared.isArray)(existing)) {
1552
+ if (_isString) {
1553
+ refs[ref] = [refValue];
1554
+ if (canSetSetupRef(ref)) setupState[ref] = refs[ref];
1555
+ } else {
1556
+ const newVal = [refValue];
1557
+ if (canSetRef(ref, rawRef.k)) ref.value = newVal;
1558
+ if (rawRef.k) refs[rawRef.k] = newVal;
1559
+ }
1560
+ } else if (!existing.includes(refValue)) existing.push(refValue);
1526
1561
  } else if (_isString) {
1527
1562
  refs[ref] = value;
1528
1563
  if (canSetSetupRef(ref)) setupState[ref] = value;
@@ -1574,7 +1609,18 @@ const logMismatchError = () => {
1574
1609
  hasLoggedMismatchError = true;
1575
1610
  };
1576
1611
  const isSVGContainer = (container) => container.namespaceURI.includes("svg") && container.tagName !== "foreignObject";
1577
- const isMathMLContainer = (container) => container.namespaceURI.includes("MathML");
1612
+ const isMathMLContainer = (container) => {
1613
+ if (!container.namespaceURI.includes("MathML")) return false;
1614
+ if (container.tagName !== "annotation-xml") return true;
1615
+ const encoding = container.getAttribute("encoding");
1616
+ return !encoding || !encoding.includes("html");
1617
+ };
1618
+ /**
1619
+ * Resolve the element namespace a container's children should be created in.
1620
+ * The live DOM is the source of truth, so this also covers containers that are
1621
+ * only known at runtime (interop boundaries, teleport targets).
1622
+ * @internal
1623
+ */
1578
1624
  const getContainerType = (container) => {
1579
1625
  if (container.nodeType !== 1) return void 0;
1580
1626
  if (isSVGContainer(container)) return "svg";
@@ -1612,11 +1658,12 @@ function createHydrationFunctions(rendererInternals) {
1612
1658
  let nextNode = null;
1613
1659
  switch (type) {
1614
1660
  case Text:
1615
- if (domType !== 3) if (vnode.children === "") {
1616
- insert(vnode.el = createText(""), parentNode(node), node);
1617
- nextNode = node;
1618
- } else nextNode = onMismatch();
1619
- else {
1661
+ if (domType !== 3) {
1662
+ if (vnode.children === "") {
1663
+ insert(vnode.el = createText(""), parentNode(node), node);
1664
+ nextNode = node;
1665
+ } else nextNode = onMismatch();
1666
+ } else {
1620
1667
  if (node.data !== vnode.children) {
1621
1668
  warn$1(`Hydration text mismatch in`, node.parentNode, `\n - rendered on server: ${JSON.stringify(node.data)}\n - expected on client: ${JSON.stringify(vnode.children)}`);
1622
1669
  logMismatchError();
@@ -1653,11 +1700,12 @@ function createHydrationFunctions(rendererInternals) {
1653
1700
  else nextNode = hydrateFragment(node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized);
1654
1701
  break;
1655
1702
  case VaporSlot:
1656
- nextNode = getVaporInterface(parentComponent, vnode).hydrateSlot(vnode, node, parentComponent, parentSuspense);
1703
+ nextNode = getVaporInterface(parentComponent, vnode).hydrateSlot(vnode, node, parentComponent, parentSuspense, slotScopeIds);
1657
1704
  break;
1658
- default: if (shapeFlag & 1) if ((domType !== 1 || vnode.type.toLowerCase() !== node.tagName.toLowerCase()) && !isTemplateNode(node)) nextNode = onMismatch();
1659
- else nextNode = hydrateElement(node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized);
1660
- else if (shapeFlag & 6) {
1705
+ default: if (shapeFlag & 1) {
1706
+ if ((domType !== 1 || vnode.type.toLowerCase() !== node.tagName.toLowerCase()) && !isTemplateNode(node)) nextNode = onMismatch();
1707
+ else nextNode = hydrateElement(node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized);
1708
+ } else if (shapeFlag & 6) {
1661
1709
  vnode.slotScopeIds = slotScopeIds;
1662
1710
  const container = parentNode(node);
1663
1711
  if (isFragmentStart) nextNode = locateClosingAnchor(node);
@@ -1679,19 +1727,20 @@ function createHydrationFunctions(rendererInternals) {
1679
1727
  } else {
1680
1728
  mountComponent(vnode, container, null, parentComponent, parentSuspense, getContainerType(container), optimized);
1681
1729
  const component = vnode.component;
1682
- if (isAsyncWrapper(vnode) && !vnode.type.__asyncResolved || component.asyncDep && !component.asyncResolved) {
1730
+ if (!component.subTree && (isAsyncWrapper(vnode) || component.asyncDep && !component.asyncResolved)) {
1683
1731
  let subTree;
1684
1732
  if (isFragmentStart) {
1685
- subTree = createVNode(Fragment);
1733
+ subTree = createVNode(Static);
1686
1734
  subTree.anchor = nextNode ? nextNode.previousSibling : container.lastChild;
1687
1735
  } else subTree = node.nodeType === 3 ? createTextVNode("") : createVNode("div");
1688
1736
  subTree.el = node;
1689
1737
  component.subTree = subTree;
1690
1738
  }
1691
1739
  }
1692
- } else if (shapeFlag & 64) if (domType !== 8) nextNode = onMismatch();
1693
- else nextNode = vnode.type.hydrate(node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized, rendererInternals, hydrateChildren);
1694
- else if (shapeFlag & 128) nextNode = vnode.type.hydrate(node, vnode, parentComponent, parentSuspense, getContainerType(parentNode(node)), slotScopeIds, optimized, rendererInternals, hydrateNode);
1740
+ } else if (shapeFlag & 64) {
1741
+ if (domType !== 8) nextNode = onMismatch();
1742
+ else nextNode = vnode.type.hydrate(node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized, rendererInternals, hydrateChildren);
1743
+ } else if (shapeFlag & 128) nextNode = vnode.type.hydrate(node, vnode, parentComponent, parentSuspense, getContainerType(parentNode(node)), slotScopeIds, optimized, rendererInternals, hydrateNode);
1695
1744
  else warn$1("Invalid HostVNode type:", type, `(${typeof type})`);
1696
1745
  }
1697
1746
  if (ref != null) setRef(ref, null, parentSuspense, vnode);
@@ -1820,7 +1869,7 @@ function createHydrationFunctions(rendererInternals) {
1820
1869
  const container = parentNode(node);
1821
1870
  remove(node);
1822
1871
  patch(null, vnode, container, next, parentComponent, parentSuspense, getContainerType(container), slotScopeIds);
1823
- if (parentComponent) {
1872
+ if (parentComponent && parentComponent.vnode) {
1824
1873
  parentComponent.vnode.el = vnode.el;
1825
1874
  updateHOCHostEl(parentComponent, vnode.el);
1826
1875
  }
@@ -1832,8 +1881,10 @@ function createHydrationFunctions(rendererInternals) {
1832
1881
  node = nextSibling(node);
1833
1882
  if (node && isComment(node)) {
1834
1883
  if (node.data === open) match++;
1835
- if (node.data === close) if (match === 0) return nextSibling(node);
1836
- else match--;
1884
+ if (node.data === close) {
1885
+ if (match === 0) return nextSibling(node);
1886
+ else match--;
1887
+ }
1837
1888
  }
1838
1889
  }
1839
1890
  return node;
@@ -1843,7 +1894,7 @@ function createHydrationFunctions(rendererInternals) {
1843
1894
  if (parentNode) parentNode.replaceChild(newNode, oldNode);
1844
1895
  let parent = parentComponent;
1845
1896
  while (parent) {
1846
- if (parent.vnode.el === oldNode) parent.vnode.el = parent.subTree.el = newNode;
1897
+ if (parent.vnode && parent.vnode.el === oldNode) parent.vnode.el = parent.subTree.el = newNode;
1847
1898
  parent = parent.parent;
1848
1899
  }
1849
1900
  };
@@ -1855,7 +1906,7 @@ const isTemplateNode = (node) => {
1855
1906
  /**
1856
1907
  * Dev only
1857
1908
  */
1858
- const resourceProps = /* @__PURE__ */ new Set([
1909
+ const resourceProps = /*@__PURE__*/ new Set([
1859
1910
  "src",
1860
1911
  "srcset",
1861
1912
  "href",
@@ -2097,7 +2148,7 @@ function forEachElement(node, cb) {
2097
2148
  //#endregion
2098
2149
  //#region packages/runtime-core/src/apiAsyncComponent.ts
2099
2150
  const isAsyncWrapper = (i) => !!i.type.__asyncLoader;
2100
- /* @__NO_SIDE_EFFECTS__ */
2151
+ /*@__NO_SIDE_EFFECTS__*/
2101
2152
  function defineAsyncComponent(source) {
2102
2153
  const { load, getResolvedComp, setPendingRequest, source: { loadingComponent, errorComponent, delay, hydrate: hydrateStrategy, timeout, suspensible = true } } = createAsyncComponentContext(source);
2103
2154
  return /* @__PURE__ */ defineComponent({
@@ -2316,10 +2367,13 @@ const KeepAlive = {
2316
2367
  });
2317
2368
  let pendingCacheKey = null;
2318
2369
  const cacheSubtree = () => {
2319
- if (pendingCacheKey != null) if (isSuspense(keepAliveInstance.subTree.type)) queuePostRenderEffect(() => {
2320
- cache.set(pendingCacheKey, getInnerChild(keepAliveInstance.subTree));
2321
- }, void 0, keepAliveInstance.subTree.suspense);
2322
- else cache.set(pendingCacheKey, getInnerChild(keepAliveInstance.subTree));
2370
+ if (pendingCacheKey != null) {
2371
+ if (isSuspense(keepAliveInstance.subTree.type)) queuePostRenderEffect(() => {
2372
+ const vnode = getInnerChild(keepAliveInstance.subTree);
2373
+ if (vnode.component) cache.set(pendingCacheKey, vnode);
2374
+ }, void 0, keepAliveInstance.subTree.suspense);
2375
+ else cache.set(pendingCacheKey, getInnerChild(keepAliveInstance.subTree));
2376
+ }
2323
2377
  };
2324
2378
  onMounted(cacheSubtree);
2325
2379
  onUpdated(cacheSubtree);
@@ -2561,23 +2615,25 @@ function renderList(source, renderItem, cache, index) {
2561
2615
  }
2562
2616
  ret = new Array(source.length);
2563
2617
  for (let i = 0, l = source.length; i < l; i++) ret[i] = renderItem(needsWrap ? isReadonlySource ? (0, _vue_reactivity.toReadonly)((0, _vue_reactivity.toReactive)(source[i])) : (0, _vue_reactivity.toReactive)(source[i]) : source[i], i, void 0, cached && cached[i]);
2564
- } else if (typeof source === "number") if (!Number.isInteger(source) || source < 0) {
2565
- warn$1(`The v-for range expects a positive integer value but got ${source}.`);
2566
- ret = [];
2567
- } else {
2568
- ret = new Array(source);
2569
- for (let i = 0; i < source; i++) ret[i] = renderItem(i + 1, i, void 0, cached && cached[i]);
2570
- }
2571
- else if ((0, _vue_shared.isObject)(source)) if (source[Symbol.iterator]) ret = Array.from(source, (item, i) => renderItem(item, i, void 0, cached && cached[i]));
2572
- else {
2573
- const keys = Object.keys(source);
2574
- ret = new Array(keys.length);
2575
- for (let i = 0, l = keys.length; i < l; i++) {
2576
- const key = keys[i];
2577
- ret[i] = renderItem(source[key], key, i, cached && cached[i]);
2618
+ } else if (typeof source === "number") {
2619
+ if (!Number.isInteger(source) || source < 0) {
2620
+ warn$1(`The v-for range expects a positive integer value but got ${source}.`);
2621
+ ret = [];
2622
+ } else {
2623
+ ret = new Array(source);
2624
+ for (let i = 0; i < source; i++) ret[i] = renderItem(i + 1, i, void 0, cached && cached[i]);
2578
2625
  }
2579
- }
2580
- else ret = [];
2626
+ } else if ((0, _vue_shared.isObject)(source)) {
2627
+ if (source[Symbol.iterator]) ret = Array.from(source, (item, i) => renderItem(item, i, void 0, cached && cached[i]));
2628
+ else {
2629
+ const keys = Object.keys(source);
2630
+ ret = new Array(keys.length);
2631
+ for (let i = 0, l = keys.length; i < l; i++) {
2632
+ const key = keys[i];
2633
+ ret[i] = renderItem(source[key], key, i, cached && cached[i]);
2634
+ }
2635
+ }
2636
+ } else ret = [];
2581
2637
  if (cache) cache[index] = ret;
2582
2638
  return ret;
2583
2639
  }
@@ -2602,14 +2658,27 @@ function createSlots(slots, dynamicSlots) {
2602
2658
  //#endregion
2603
2659
  //#region packages/runtime-core/src/helpers/renderSlot.ts
2604
2660
  /**
2661
+ * Links a slot function to its raw vapor slot: a raw vapor slot carries
2662
+ * itself, and the wrapper the interop slots proxy hands out carries the raw
2663
+ * slot it wraps — one lookup answers both "is this a vapor slot" and
2664
+ * "which one". Internal to vapor interop.
2665
+ */
2666
+ const rawVaporSlotKey = Symbol(`rawVaporSlot`);
2667
+ /**
2668
+ * Marks a compiler-generated slot fallback as VDOM-rendered so the vapor
2669
+ * interop fallback chain renders it through the VDOM renderer. Internal to
2670
+ * vapor interop.
2671
+ */
2672
+ const vdomSlotFallbackKey = Symbol(`vdomSlotFallback`);
2673
+ /**
2605
2674
  * Compiler runtime helper for rendering `<slot/>`
2606
2675
  * @private
2607
2676
  */
2608
2677
  function renderSlot(slots, name, props, fallback, noSlotted, branchKey) {
2609
2678
  if (props == null) props = {};
2610
2679
  let slot = slots[name];
2611
- if (fallback) fallback.__vdom = true;
2612
- const vaporSlot = slot && (slot.__vs || (slot.__vapor ? slot : null));
2680
+ if (fallback) fallback[vdomSlotFallbackKey] = true;
2681
+ const vaporSlot = slot && slot[rawVaporSlotKey];
2613
2682
  if (vaporSlot) {
2614
2683
  const ret = (openBlock(), createBlock(VaporSlot, props));
2615
2684
  ret.vs = {
@@ -2686,11 +2755,38 @@ const getPublicInstance = (i) => {
2686
2755
  if (isStatefulComponent(i)) return getComponentPublicInstance(i);
2687
2756
  return getPublicInstance(i.parent);
2688
2757
  };
2758
+ const resolveDevRootEl = (vnode) => {
2759
+ let found = false;
2760
+ while (true) {
2761
+ if (vnode.patchFlag > 0 && vnode.patchFlag & 2048) {
2762
+ const root = filterSingleRoot(vnode.children);
2763
+ if (!root) return;
2764
+ vnode = root;
2765
+ found = true;
2766
+ continue;
2767
+ }
2768
+ const component = vnode.component;
2769
+ if (component && component.subTree) {
2770
+ vnode = component.subTree;
2771
+ continue;
2772
+ }
2773
+ const suspense = vnode.suspense;
2774
+ if (suspense && suspense.activeBranch) {
2775
+ vnode = suspense.activeBranch;
2776
+ continue;
2777
+ }
2778
+ return found ? vnode.el : void 0;
2779
+ }
2780
+ };
2781
+ const getDevRootFragmentEl = (i) => {
2782
+ const el = i.subTree && resolveDevRootEl(i.subTree);
2783
+ return el === void 0 ? i.vnode.el : el;
2784
+ };
2689
2785
  let publicPropertiesMap;
2690
2786
  const getPublicPropertiesMap = () => {
2691
2787
  if (!publicPropertiesMap) publicPropertiesMap = (0, _vue_shared.extend)(Object.create(null), {
2692
2788
  $: (i) => i,
2693
- $el: (i) => i.vnode.el,
2789
+ $el: (i) => getDevRootFragmentEl(i),
2694
2790
  $data: (i) => i.data,
2695
2791
  $props: (i) => (0, _vue_reactivity.shallowReadonly)(i.props),
2696
2792
  $attrs: (i) => (0, _vue_reactivity.shallowReadonly)(i.attrs),
@@ -2796,7 +2892,7 @@ PublicInstanceProxyHandlers.ownKeys = (target) => {
2796
2892
  warn$1("Avoid app logic that relies on enumerating keys on a component instance. The keys will be empty in production mode to avoid performance overhead.");
2797
2893
  return Reflect.ownKeys(target);
2798
2894
  };
2799
- const RuntimeCompiledPublicInstanceProxyHandlers = /* @__PURE__ */ (0, _vue_shared.extend)({}, PublicInstanceProxyHandlers, {
2895
+ const RuntimeCompiledPublicInstanceProxyHandlers = /*@__PURE__*/ (0, _vue_shared.extend)({}, PublicInstanceProxyHandlers, {
2800
2896
  get(target, key) {
2801
2897
  if (key === Symbol.unscopables) return;
2802
2898
  return PublicInstanceProxyHandlers.get(target, key, target);
@@ -2968,12 +3064,13 @@ function mergeDefaults(raw, defaults) {
2968
3064
  for (const key in defaults) {
2969
3065
  if (key.startsWith("__skip")) continue;
2970
3066
  let opt = props[key];
2971
- if (opt) if ((0, _vue_shared.isArray)(opt) || (0, _vue_shared.isFunction)(opt)) opt = props[key] = {
2972
- type: opt,
2973
- default: defaults[key]
2974
- };
2975
- else opt.default = defaults[key];
2976
- else if (opt === null) opt = props[key] = { default: defaults[key] };
3067
+ if (opt) {
3068
+ if ((0, _vue_shared.isArray)(opt) || (0, _vue_shared.isFunction)(opt)) opt = props[key] = {
3069
+ type: opt,
3070
+ default: defaults[key]
3071
+ };
3072
+ else opt.default = defaults[key];
3073
+ } else if (opt === null) opt = props[key] = { default: defaults[key] };
2977
3074
  else warn$1(`props default key "${key}" has no corresponding declaration.`);
2978
3075
  if (opt && defaults[`__skip_${key}`]) opt.skipFactory = true;
2979
3076
  }
@@ -3116,11 +3213,12 @@ function applyOptions(instance) {
3116
3213
  const opt = computedOptions[key];
3117
3214
  const get = (0, _vue_shared.isFunction)(opt) ? opt.bind(publicThis, publicThis) : (0, _vue_shared.isFunction)(opt.get) ? opt.get.bind(publicThis, publicThis) : _vue_shared.NOOP;
3118
3215
  if (get === _vue_shared.NOOP) warn$1(`Computed property "${key}" has no getter.`);
3216
+ const set = !(0, _vue_shared.isFunction)(opt) && (0, _vue_shared.isFunction)(opt.set) ? opt.set.bind(publicThis) : () => {
3217
+ warn$1(`Write operation failed: computed property "${key}" is readonly.`);
3218
+ };
3119
3219
  const c = computed({
3120
3220
  get,
3121
- set: !(0, _vue_shared.isFunction)(opt) && (0, _vue_shared.isFunction)(opt.set) ? opt.set.bind(publicThis) : () => {
3122
- warn$1(`Write operation failed: computed property "${key}" is readonly.`);
3123
- }
3221
+ set
3124
3222
  });
3125
3223
  Object.defineProperty(ctx, key, {
3126
3224
  enumerable: true,
@@ -3177,9 +3275,10 @@ function resolveInjections(injectOptions, ctx, checkDuplicateProperties = _vue_s
3177
3275
  for (const key in injectOptions) {
3178
3276
  const opt = injectOptions[key];
3179
3277
  let injected;
3180
- if ((0, _vue_shared.isObject)(opt)) if ("default" in opt) injected = inject(opt.from || key, opt.default, true);
3181
- else injected = inject(opt.from || key);
3182
- else injected = inject(opt);
3278
+ if ((0, _vue_shared.isObject)(opt)) {
3279
+ if ("default" in opt) injected = inject(opt.from || key, opt.default, true);
3280
+ else injected = inject(opt.from || key);
3281
+ } else injected = inject(opt);
3183
3282
  if ((0, _vue_reactivity.isRef)(injected)) Object.defineProperty(ctx, key, {
3184
3283
  enumerable: true,
3185
3284
  configurable: true,
@@ -3200,13 +3299,14 @@ function createWatcher(raw, ctx, publicThis, key) {
3200
3299
  if ((0, _vue_shared.isFunction)(handler)) watch(getter, handler);
3201
3300
  else warn$1(`Invalid watch handler specified by key "${raw}"`, handler);
3202
3301
  } else if ((0, _vue_shared.isFunction)(raw)) watch(getter, raw.bind(publicThis));
3203
- else if ((0, _vue_shared.isObject)(raw)) if ((0, _vue_shared.isArray)(raw)) raw.forEach((r) => createWatcher(r, ctx, publicThis, key));
3204
- else {
3205
- const handler = (0, _vue_shared.isFunction)(raw.handler) ? raw.handler.bind(publicThis) : ctx[raw.handler];
3206
- if ((0, _vue_shared.isFunction)(handler)) watch(getter, handler, raw);
3207
- else warn$1(`Invalid watch handler specified by key "${raw.handler}"`, handler);
3208
- }
3209
- else warn$1(`Invalid watch option: "${key}"`, raw);
3302
+ else if ((0, _vue_shared.isObject)(raw)) {
3303
+ if ((0, _vue_shared.isArray)(raw)) raw.forEach((r) => createWatcher(r, ctx, publicThis, key));
3304
+ else {
3305
+ const handler = (0, _vue_shared.isFunction)(raw.handler) ? raw.handler.bind(publicThis) : ctx[raw.handler];
3306
+ if ((0, _vue_shared.isFunction)(handler)) watch(getter, handler, raw);
3307
+ else warn$1(`Invalid watch handler specified by key "${raw.handler}"`, handler);
3308
+ }
3309
+ } else warn$1(`Invalid watch option: "${key}"`, raw);
3210
3310
  }
3211
3311
  /**
3212
3312
  * Resolve merged options and cache it on the component.
@@ -3292,7 +3392,7 @@ function mergeObjectOptions(to, from) {
3292
3392
  }
3293
3393
  function mergeEmitsOrPropsOptions(to, from) {
3294
3394
  if (to) {
3295
- if ((0, _vue_shared.isArray)(to) && (0, _vue_shared.isArray)(from)) return [...new Set([...to, ...from])];
3395
+ if ((0, _vue_shared.isArray)(to) && (0, _vue_shared.isArray)(from)) return [.../* @__PURE__ */ new Set([...to, ...from])];
3296
3396
  return (0, _vue_shared.extend)(Object.create(null), normalizePropsOrEmits(to), normalizePropsOrEmits(from !== null && from !== void 0 ? from : {}));
3297
3397
  } else return from;
3298
3398
  }
@@ -3411,8 +3511,10 @@ function createAppAPI(mount, unmount, getPublicInstance, render) {
3411
3511
  } else warn$1(`Cannot unmount an app that is not mounted.`);
3412
3512
  },
3413
3513
  provide(key, value) {
3414
- if (key in context.provides) if ((0, _vue_shared.hasOwn)(context.provides, key)) warn$1(`App already provides property with key "${String(key)}". It will be overwritten with the new value.`);
3415
- else warn$1(`App already provides property with key "${String(key)}" inherited from its parent element. It will be overwritten with the new value.`);
3514
+ if (key in context.provides) {
3515
+ if ((0, _vue_shared.hasOwn)(context.provides, key)) warn$1(`App already provides property with key "${String(key)}". It will be overwritten with the new value.`);
3516
+ else warn$1(`App already provides property with key "${String(key)}" inherited from its parent element. It will be overwritten with the new value.`);
3517
+ }
3416
3518
  context.provides[key] = value;
3417
3519
  return app;
3418
3520
  },
@@ -3519,12 +3621,14 @@ function baseEmit(instance, props, getter, event, ...rawArgs) {
3519
3621
  if (instance.isUnmounted) return;
3520
3622
  {
3521
3623
  const { emitsOptions, propsOptions } = instance;
3522
- if (emitsOptions) if (!(event in emitsOptions) && true) {
3523
- if (!propsOptions || !propsOptions[0] || !((0, _vue_shared.toHandlerKey)((0, _vue_shared.camelize)(event)) in propsOptions[0])) warn$1(`Component emitted event "${event}" but it is neither declared in the emits option nor as an "${(0, _vue_shared.toHandlerKey)((0, _vue_shared.camelize)(event))}" prop.`);
3524
- } else {
3525
- const validator = emitsOptions[event];
3526
- if ((0, _vue_shared.isFunction)(validator)) {
3527
- if (!validator(...rawArgs)) warn$1(`Invalid event arguments: event validation failed for event "${event}".`);
3624
+ if (emitsOptions) {
3625
+ if (!(event in emitsOptions) && true) {
3626
+ if (!propsOptions || !propsOptions[0] || !((0, _vue_shared.toHandlerKey)((0, _vue_shared.camelize)(event)) in propsOptions[0])) warn$1(`Component emitted event "${event}" but it is neither declared in the emits option nor as an "${(0, _vue_shared.toHandlerKey)((0, _vue_shared.camelize)(event))}" prop.`);
3627
+ } else {
3628
+ const validator = emitsOptions[event];
3629
+ if ((0, _vue_shared.isFunction)(validator)) {
3630
+ if (!validator(...rawArgs)) warn$1(`Invalid event arguments: event validation failed for event "${event}".`);
3631
+ }
3528
3632
  }
3529
3633
  }
3530
3634
  }
@@ -3533,7 +3637,7 @@ function baseEmit(instance, props, getter, event, ...rawArgs) {
3533
3637
  const modifiers = isModelListener && getModelModifiers(props, event.slice(7), getter);
3534
3638
  if (modifiers) {
3535
3639
  if (modifiers.trim) args = rawArgs.map((a) => (0, _vue_shared.isString)(a) ? a.trim() : a);
3536
- if (modifiers.number) args = rawArgs.map(_vue_shared.looseToNumber);
3640
+ if (modifiers.number) args = args.map(_vue_shared.looseToNumber);
3537
3641
  }
3538
3642
  devtoolsComponentEmit(instance, event, args);
3539
3643
  {
@@ -3713,10 +3817,12 @@ function filterSingleRoot(children, recurse = true) {
3713
3817
  for (let i = 0; i < children.length; i++) {
3714
3818
  const child = children[i];
3715
3819
  if (isVNode(child)) {
3716
- if (child.type !== Comment || child.children === "v-if") if (singleRoot) return;
3717
- else {
3718
- singleRoot = child;
3719
- if (recurse && singleRoot.patchFlag > 0 && singleRoot.patchFlag & 2048) return filterSingleRoot(singleRoot.children);
3820
+ if (child.type !== Comment || child.children === "v-if") {
3821
+ if (singleRoot) return;
3822
+ else {
3823
+ singleRoot = child;
3824
+ if (recurse && singleRoot.patchFlag > 0 && singleRoot.patchFlag & 2048) return filterSingleRoot(singleRoot.children);
3825
+ }
3720
3826
  }
3721
3827
  } else return;
3722
3828
  }
@@ -3837,16 +3943,17 @@ function updateProps(instance, rawProps, rawPrevProps, optimized) {
3837
3943
  let key = propsToUpdate[i];
3838
3944
  if (isEmitListener(instance.emitsOptions, key)) continue;
3839
3945
  const value = rawProps[key];
3840
- if (options) if ((0, _vue_shared.hasOwn)(attrs, key)) {
3841
- if (value !== attrs[key]) {
3842
- attrs[key] = value;
3843
- hasAttrsChanged = true;
3946
+ if (options) {
3947
+ if ((0, _vue_shared.hasOwn)(attrs, key)) {
3948
+ if (value !== attrs[key]) {
3949
+ attrs[key] = value;
3950
+ hasAttrsChanged = true;
3951
+ }
3952
+ } else {
3953
+ const camelizedKey = (0, _vue_shared.camelize)(key);
3954
+ props[camelizedKey] = resolvePropValue(options, camelizedKey, value, instance, baseResolveDefault);
3844
3955
  }
3845
- } else {
3846
- const camelizedKey = (0, _vue_shared.camelize)(key);
3847
- props[camelizedKey] = resolvePropValue(options, camelizedKey, value, instance, baseResolveDefault);
3848
- }
3849
- else if (value !== attrs[key]) {
3956
+ } else if (value !== attrs[key]) {
3850
3957
  attrs[key] = value;
3851
3958
  hasAttrsChanged = true;
3852
3959
  }
@@ -3855,9 +3962,11 @@ function updateProps(instance, rawProps, rawPrevProps, optimized) {
3855
3962
  } else {
3856
3963
  if (setFullProps(instance, rawProps, props, attrs)) hasAttrsChanged = true;
3857
3964
  let kebabKey;
3858
- for (const key in rawCurrentProps) if (!rawProps || !(0, _vue_shared.hasOwn)(rawProps, key) && ((kebabKey = (0, _vue_shared.hyphenate)(key)) === key || !(0, _vue_shared.hasOwn)(rawProps, kebabKey))) if (options) {
3859
- if (rawPrevProps && (rawPrevProps[key] !== void 0 || rawPrevProps[kebabKey] !== void 0)) props[key] = resolvePropValue(options, key, void 0, instance, baseResolveDefault, true);
3860
- } else delete props[key];
3965
+ for (const key in rawCurrentProps) if (!rawProps || !(0, _vue_shared.hasOwn)(rawProps, key) && ((kebabKey = (0, _vue_shared.hyphenate)(key)) === key || !(0, _vue_shared.hasOwn)(rawProps, kebabKey))) {
3966
+ if (options) {
3967
+ if (rawPrevProps && (rawPrevProps[key] !== void 0 || rawPrevProps[kebabKey] !== void 0)) props[key] = resolvePropValue(options, key, void 0, instance, baseResolveDefault, true);
3968
+ } else delete props[key];
3969
+ }
3861
3970
  if (attrs !== rawCurrentProps) {
3862
3971
  for (const key in attrs) if (!rawProps || !(0, _vue_shared.hasOwn)(rawProps, key) && true) {
3863
3972
  delete attrs[key];
@@ -3876,9 +3985,10 @@ function setFullProps(instance, rawProps, props, attrs) {
3876
3985
  if ((0, _vue_shared.isReservedProp)(key)) continue;
3877
3986
  const value = rawProps[key];
3878
3987
  let camelKey;
3879
- if (options && (0, _vue_shared.hasOwn)(options, camelKey = (0, _vue_shared.camelize)(key))) if (!needCastKeys || !needCastKeys.includes(camelKey)) props[camelKey] = value;
3880
- else (rawCastValues || (rawCastValues = {}))[camelKey] = value;
3881
- else if (!isEmitListener(instance.emitsOptions, key)) {
3988
+ if (options && (0, _vue_shared.hasOwn)(options, camelKey = (0, _vue_shared.camelize)(key))) {
3989
+ if (!needCastKeys || !needCastKeys.includes(camelKey)) props[camelKey] = value;
3990
+ else (rawCastValues || (rawCastValues = {}))[camelKey] = value;
3991
+ } else if (!isEmitListener(instance.emitsOptions, key)) {
3882
3992
  if (!(key in attrs) || value !== attrs[key]) {
3883
3993
  attrs[key] = value;
3884
3994
  hasAttrsChanged = true;
@@ -4041,7 +4151,7 @@ function validateProp(key, value, propOptions, resolvedProps, isAbsent) {
4041
4151
  }
4042
4152
  if (validator && !validator(value, (0, _vue_reactivity.shallowReadonly)(resolvedProps))) warn$1("Invalid prop: custom validator check failed for prop \"" + key + "\".");
4043
4153
  }
4044
- const isSimpleType = /* @__PURE__ */ (0, _vue_shared.makeMap)("String,Number,Boolean,Function,Symbol,BigInt");
4154
+ const isSimpleType = /*@__PURE__*/ (0, _vue_shared.makeMap)("String,Number,Boolean,Function,Symbol,BigInt");
4045
4155
  /**
4046
4156
  * dev only
4047
4157
  */
@@ -4154,12 +4264,13 @@ const updateSlots = (instance, children, optimized) => {
4154
4264
  let deletionComparisonTarget = _vue_shared.EMPTY_OBJ;
4155
4265
  if (vnode.shapeFlag & 32) {
4156
4266
  const type = children._;
4157
- if (type) if (isHmrUpdating) {
4158
- assignSlots(slots, children, optimized);
4159
- (0, _vue_reactivity.trigger)(instance, "set", "$slots");
4160
- } else if (optimized && type === 1) needDeletionCheck = false;
4161
- else assignSlots(slots, children, optimized);
4162
- else {
4267
+ if (type) {
4268
+ if (isHmrUpdating) {
4269
+ assignSlots(slots, children, optimized);
4270
+ (0, _vue_reactivity.trigger)(instance, "set", "$slots");
4271
+ } else if (optimized && type === 1) needDeletionCheck = false;
4272
+ else assignSlots(slots, children, optimized);
4273
+ } else {
4163
4274
  needDeletionCheck = !children.$stable;
4164
4275
  normalizeObjectSlots(children, slots, instance);
4165
4276
  }
@@ -4177,7 +4288,7 @@ const updateSlots = (instance, children, optimized) => {
4177
4288
  let supported;
4178
4289
  let perf;
4179
4290
  let cachedNow = 0;
4180
- const p = /* @__PURE__ */ Promise.resolve();
4291
+ const p = /*@__PURE__*/ Promise.resolve();
4181
4292
  const getNow = () => cachedNow || (p.then(() => cachedNow = 0), cachedNow = isSupported() ? perf.now() : Date.now());
4182
4293
  /**
4183
4294
  * @internal
@@ -4274,7 +4385,7 @@ function baseCreateRenderer(options, createHydrationFns) {
4274
4385
  processFragment(n1, n2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized);
4275
4386
  break;
4276
4387
  case VaporSlot:
4277
- getVaporInterface(parentComponent, n2).slot(n1, n2, container, anchor, parentComponent, parentSuspense);
4388
+ getVaporInterface(parentComponent, n2).slot(n1, n2, container, anchor, parentComponent, parentSuspense, slotScopeIds);
4278
4389
  break;
4279
4390
  default: if (shapeFlag & 1) processElement(n1, n2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized);
4280
4391
  else if (shapeFlag & 6) processComponent(n1, n2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized);
@@ -4393,7 +4504,10 @@ function baseCreateRenderer(options, createHydrationFns) {
4393
4504
  for (let i = 0; i < inheritedScopeIds.length; i++) hostSetScopeId(el, inheritedScopeIds[i]);
4394
4505
  };
4395
4506
  const mountChildren = (children, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized, start = 0) => {
4396
- for (let i = start; i < children.length; i++) patch(null, children[i] = optimized ? cloneIfMounted(children[i]) : normalizeVNode(children[i]), container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized);
4507
+ for (let i = start; i < children.length; i++) {
4508
+ const child = children[i] = optimized ? cloneIfMounted(children[i]) : normalizeVNode(children[i]);
4509
+ patch(null, child, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized);
4510
+ }
4397
4511
  };
4398
4512
  const patchElement = (n1, n2, parentComponent, parentSuspense, namespace, slotScopeIds, optimized) => {
4399
4513
  const el = n2.el = n1.el;
@@ -4405,6 +4519,7 @@ function baseCreateRenderer(options, createHydrationFns) {
4405
4519
  let vnodeHook;
4406
4520
  parentComponent && toggleRecurse(parentComponent, false);
4407
4521
  if (vnodeHook = newProps.onVnodeBeforeUpdate) invokeVNodeHook(vnodeHook, parentComponent, n2, n1);
4522
+ if (n2.ibu) n2.ibu();
4408
4523
  if (dirs) invokeDirectiveHook(n2, n1, parentComponent, "beforeUpdate");
4409
4524
  parentComponent && toggleRecurse(parentComponent, true);
4410
4525
  if (isHmrUpdating || dynamicChildren && (!n1.dynamicChildren || n1.dynamicChildren.length !== dynamicChildren.length)) {
@@ -4438,8 +4553,9 @@ function baseCreateRenderer(options, createHydrationFns) {
4438
4553
  if (n1.children !== n2.children) hostSetElementText(el, n2.children);
4439
4554
  }
4440
4555
  } else if (!optimized && dynamicChildren == null) patchProps(el, oldProps, newProps, parentComponent, namespace);
4441
- if ((vnodeHook = newProps.onVnodeUpdated) || dirs) queuePostRenderEffect(() => {
4556
+ if ((vnodeHook = newProps.onVnodeUpdated) || dirs || n2.iu) queuePostRenderEffect(() => {
4442
4557
  vnodeHook && invokeVNodeHook(vnodeHook, parentComponent, n2, n1);
4558
+ n2.iu && n2.iu();
4443
4559
  dirs && invokeDirectiveHook(n2, n1, parentComponent, "updated");
4444
4560
  }, void 0, parentSuspense);
4445
4561
  };
@@ -4447,7 +4563,8 @@ function baseCreateRenderer(options, createHydrationFns) {
4447
4563
  for (let i = 0; i < newChildren.length; i++) {
4448
4564
  const oldVNode = oldChildren[i];
4449
4565
  const newVNode = newChildren[i];
4450
- patch(oldVNode, newVNode, oldVNode.el && (oldVNode.type === Fragment || !isSameVNodeType(oldVNode, newVNode) || oldVNode.shapeFlag & 198) ? hostParentNode(oldVNode.el) : fallbackContainer, null, parentComponent, parentSuspense, namespace, slotScopeIds, true);
4566
+ const container = oldVNode.el && (oldVNode.type === Fragment || !isSameVNodeType(oldVNode, newVNode) || oldVNode.shapeFlag & 198) ? hostParentNode(oldVNode.el) : fallbackContainer;
4567
+ patch(oldVNode, newVNode, container, null, parentComponent, parentSuspense, namespace, slotScopeIds, true);
4451
4568
  }
4452
4569
  };
4453
4570
  const patchProps = (el, oldProps, newProps, parentComponent, namespace) => {
@@ -4485,41 +4602,46 @@ function baseCreateRenderer(options, createHydrationFns) {
4485
4602
  };
4486
4603
  const processComponent = (n1, n2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized) => {
4487
4604
  n2.slotScopeIds = slotScopeIds;
4488
- if (n2.type.__vapor) if (n1 == null) if (n2.shapeFlag & 512) getVaporInterface(parentComponent, n2).activate(n2, container, anchor, parentComponent, parentSuspense);
4489
- else {
4490
- const vnodeBeforeMountHook = !isAsyncWrapper(n2) && n2.props && n2.props.onVnodeBeforeMount;
4491
- getVaporInterface(parentComponent, n2).mount(n2, container, anchor, parentComponent, parentSuspense, () => {
4492
- if (n2.dirs) {
4493
- invokeDirectiveHook(n2, null, parentComponent, "created");
4494
- invokeDirectiveHook(n2, null, parentComponent, "beforeMount");
4605
+ if (n2.type.__vapor) {
4606
+ if (n1 == null) {
4607
+ if (n2.shapeFlag & 512) getVaporInterface(parentComponent, n2).activate(n2, container, anchor, parentComponent, parentSuspense);
4608
+ else {
4609
+ const vnodeBeforeMountHook = !isAsyncWrapper(n2) && n2.props && n2.props.onVnodeBeforeMount;
4610
+ getVaporInterface(parentComponent, n2).mount(n2, container, anchor, parentComponent, parentSuspense, () => {
4611
+ if (n2.dirs) {
4612
+ invokeDirectiveHook(n2, null, parentComponent, "created");
4613
+ invokeDirectiveHook(n2, null, parentComponent, "beforeMount");
4614
+ }
4615
+ }, () => {
4616
+ if (vnodeBeforeMountHook) invokeVNodeHook(vnodeBeforeMountHook, parentComponent, n2);
4617
+ });
4618
+ if (n2.dirs) queuePostRenderEffect(() => invokeDirectiveHook(n2, null, parentComponent, "mounted"), void 0, parentSuspense);
4619
+ const vnodeMountedHook = !isAsyncWrapper(n2) && n2.props && n2.props.onVnodeMounted;
4620
+ if (vnodeMountedHook) {
4621
+ const scopedVNode = n2;
4622
+ queuePostRenderEffect(() => invokeVNodeHook(vnodeMountedHook, parentComponent, scopedVNode), void 0, parentSuspense);
4623
+ }
4495
4624
  }
4496
- }, () => {
4497
- if (vnodeBeforeMountHook) invokeVNodeHook(vnodeBeforeMountHook, parentComponent, n2);
4498
- });
4499
- if (n2.dirs) queuePostRenderEffect(() => invokeDirectiveHook(n2, null, parentComponent, "mounted"), void 0, parentSuspense);
4500
- const vnodeMountedHook = !isAsyncWrapper(n2) && n2.props && n2.props.onVnodeMounted;
4501
- if (vnodeMountedHook) {
4502
- const scopedVNode = n2;
4503
- queuePostRenderEffect(() => invokeVNodeHook(vnodeMountedHook, parentComponent, scopedVNode), void 0, parentSuspense);
4625
+ } else {
4626
+ const shouldUpdate = shouldUpdateComponent(n1, n2, optimized);
4627
+ getVaporInterface(parentComponent, n2).update(n1, n2, shouldUpdate, () => {
4628
+ if (n2.dirs) invokeDirectiveHook(n2, n1, parentComponent, "beforeUpdate");
4629
+ }, () => {
4630
+ const vnodeBeforeUpdateHook = n2.props && n2.props.onVnodeBeforeUpdate;
4631
+ if (vnodeBeforeUpdateHook) invokeVNodeHook(vnodeBeforeUpdateHook, parentComponent, n2, n1);
4632
+ if (n2.ibu) n2.ibu();
4633
+ });
4634
+ const vnodeUpdatedHook = n2.props && n2.props.onVnodeUpdated;
4635
+ if (shouldUpdate && (vnodeUpdatedHook || n2.dirs || n2.iu)) queuePostRenderEffect(() => {
4636
+ n2.dirs && invokeDirectiveHook(n2, n1, parentComponent, "updated");
4637
+ vnodeUpdatedHook && invokeVNodeHook(vnodeUpdatedHook, parentComponent, n2, n1);
4638
+ n2.iu && n2.iu();
4639
+ }, void 0, parentSuspense);
4504
4640
  }
4505
- }
4506
- else {
4507
- const shouldUpdate = shouldUpdateComponent(n1, n2, optimized);
4508
- getVaporInterface(parentComponent, n2).update(n1, n2, shouldUpdate, () => {
4509
- if (n2.dirs) invokeDirectiveHook(n2, n1, parentComponent, "beforeUpdate");
4510
- }, () => {
4511
- const vnodeBeforeUpdateHook = n2.props && n2.props.onVnodeBeforeUpdate;
4512
- if (vnodeBeforeUpdateHook) invokeVNodeHook(vnodeBeforeUpdateHook, parentComponent, n2, n1);
4513
- });
4514
- const vnodeUpdatedHook = n2.props && n2.props.onVnodeUpdated;
4515
- if (shouldUpdate && (vnodeUpdatedHook || n2.dirs)) queuePostRenderEffect(() => {
4516
- n2.dirs && invokeDirectiveHook(n2, n1, parentComponent, "updated");
4517
- vnodeUpdatedHook && invokeVNodeHook(vnodeUpdatedHook, parentComponent, n2, n1);
4518
- }, void 0, parentSuspense);
4519
- }
4520
- else if (n1 == null) if (n2.shapeFlag & 512) parentComponent.ctx.activate(n2, container, anchor, namespace, optimized);
4521
- else mountComponent(n2, container, anchor, parentComponent, parentSuspense, namespace, optimized);
4522
- else updateComponent(n1, n2, optimized);
4641
+ } else if (n1 == null) {
4642
+ if (n2.shapeFlag & 512) parentComponent.ctx.activate(n2, container, anchor, namespace, optimized);
4643
+ else mountComponent(n2, container, anchor, parentComponent, parentSuspense, namespace, optimized);
4644
+ } else updateComponent(n1, n2, optimized);
4523
4645
  };
4524
4646
  const mountComponent = (initialVNode, container, anchor, parentComponent, parentSuspense, namespace, optimized) => {
4525
4647
  const instance = initialVNode.component = createComponentInstance(initialVNode, parentComponent, parentSuspense);
@@ -4560,16 +4682,17 @@ function baseCreateRenderer(options, createHydrationFns) {
4560
4682
  };
4561
4683
  const updateComponent = (n1, n2, optimized) => {
4562
4684
  const instance = n2.component = n1.component;
4563
- if (shouldUpdateComponent(n1, n2, optimized)) if (instance.asyncDep && !instance.asyncResolved) {
4564
- pushWarningContext(n2);
4565
- updateComponentPreRender(instance, n2, optimized);
4566
- popWarningContext();
4567
- return;
4685
+ if (shouldUpdateComponent(n1, n2, optimized)) {
4686
+ if (instance.asyncDep && !instance.asyncResolved) {
4687
+ pushWarningContext(n2);
4688
+ updateComponentPreRender(instance, n2, optimized);
4689
+ popWarningContext();
4690
+ return;
4691
+ } else {
4692
+ instance.next = n2;
4693
+ instance.effect.run();
4694
+ }
4568
4695
  } else {
4569
- instance.next = n2;
4570
- instance.effect.run();
4571
- }
4572
- else {
4573
4696
  n2.el = n1.el;
4574
4697
  instance.vnode = n2;
4575
4698
  }
@@ -4667,6 +4790,7 @@ function baseCreateRenderer(options, createHydrationFns) {
4667
4790
  } else next = vnode;
4668
4791
  if (bu) (0, _vue_shared.invokeArrayFns)(bu);
4669
4792
  if (vnodeHook = next.props && next.props.onVnodeBeforeUpdate) invokeVNodeHook(vnodeHook, parent, next, vnode);
4793
+ if (next.ibu) next.ibu();
4670
4794
  toggleRecurse(instance, true);
4671
4795
  startMeasure(instance, `render`);
4672
4796
  const nextTree = renderComponentRoot(instance);
@@ -4679,7 +4803,10 @@ function baseCreateRenderer(options, createHydrationFns) {
4679
4803
  next.el = nextTree.el;
4680
4804
  if (originNext === null) updateHOCHostEl(instance, nextTree.el);
4681
4805
  if (u) queuePostRenderEffect(u, void 0, parentSuspense);
4682
- if (vnodeHook = next.props && next.props.onVnodeUpdated) queuePostRenderEffect(() => invokeVNodeHook(vnodeHook, parent, next, vnode), void 0, parentSuspense);
4806
+ if ((vnodeHook = next.props && next.props.onVnodeUpdated) || next.iu) queuePostRenderEffect(() => {
4807
+ vnodeHook && invokeVNodeHook(vnodeHook, parent, next, vnode);
4808
+ next.iu && next.iu();
4809
+ }, void 0, parentSuspense);
4683
4810
  devtoolsComponentUpdated(instance);
4684
4811
  popWarningContext();
4685
4812
  }
@@ -4719,9 +4846,10 @@ function baseCreateRenderer(options, createHydrationFns) {
4719
4846
  if (shapeFlag & 8) {
4720
4847
  if (prevShapeFlag & 16) unmountChildren(c1, parentComponent, parentSuspense);
4721
4848
  if (c2 !== c1) hostSetElementText(container, c2);
4722
- } else if (prevShapeFlag & 16) if (shapeFlag & 16) patchKeyedChildren(c1, c2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized);
4723
- else unmountChildren(c1, parentComponent, parentSuspense, true);
4724
- else {
4849
+ } else if (prevShapeFlag & 16) {
4850
+ if (shapeFlag & 16) patchKeyedChildren(c1, c2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized);
4851
+ else unmountChildren(c1, parentComponent, parentSuspense, true);
4852
+ } else {
4725
4853
  if (prevShapeFlag & 8) hostSetElementText(container, "");
4726
4854
  if (shapeFlag & 16) mountChildren(c2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized);
4727
4855
  }
@@ -4820,8 +4948,10 @@ function baseCreateRenderer(options, createHydrationFns) {
4820
4948
  const anchorVNode = c2[nextIndex + 1];
4821
4949
  const anchor = nextIndex + 1 < l2 ? anchorVNode.el || resolveAsyncComponentPlaceholder(anchorVNode) : parentAnchor;
4822
4950
  if (newIndexToOldIndexMap[i] === 0) patch(null, nextChild, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized);
4823
- else if (moved) if (j < 0 || i !== increasingNewIndexSequence[j]) move(nextChild, container, anchor, 2, parentComponent);
4824
- else j--;
4951
+ else if (moved) {
4952
+ if (j < 0 || i !== increasingNewIndexSequence[j]) move(nextChild, container, anchor, 2, parentComponent);
4953
+ else j--;
4954
+ }
4825
4955
  }
4826
4956
  }
4827
4957
  };
@@ -4853,26 +4983,27 @@ function baseCreateRenderer(options, createHydrationFns) {
4853
4983
  moveStaticNode(vnode, container, anchor);
4854
4984
  return;
4855
4985
  }
4856
- if (moveType !== 2 && shapeFlag & 1 && transition) if (moveType === 0) performTransitionEnter(el, transition, () => hostInsert(el, container, anchor), parentSuspense, true);
4857
- else {
4858
- const { leave, delayLeave, afterLeave } = transition;
4859
- const remove = () => {
4860
- if (vnode.ctx.isUnmounted) hostRemove(el);
4861
- else hostInsert(el, container, anchor);
4862
- };
4863
- const performLeave = () => {
4864
- const wasLeaving = el._isLeaving || !!el[leaveCbKey];
4865
- if (el._isLeaving) el[leaveCbKey](true);
4866
- if (transition.persisted && !wasLeaving) remove();
4867
- else leave(el, () => {
4868
- remove();
4869
- afterLeave && afterLeave();
4870
- });
4871
- };
4872
- if (delayLeave) delayLeave(el, remove, performLeave);
4873
- else performLeave();
4874
- }
4875
- else hostInsert(el, container, anchor);
4986
+ if (moveType !== 2 && shapeFlag & 1 && transition) {
4987
+ if (moveType === 0) performTransitionEnter(el, transition, () => hostInsert(el, container, anchor), parentSuspense, true);
4988
+ else {
4989
+ const { leave, delayLeave, afterLeave } = transition;
4990
+ const remove = () => {
4991
+ if (vnode.ctx.isUnmounted) hostRemove(el);
4992
+ else hostInsert(el, container, anchor);
4993
+ };
4994
+ const performLeave = () => {
4995
+ const wasLeaving = el._isLeaving || !!el[leaveCbKey];
4996
+ if (el._isLeaving) el[leaveCbKey](true);
4997
+ if (transition.persisted && !wasLeaving) remove();
4998
+ else leave(el, () => {
4999
+ remove();
5000
+ afterLeave && afterLeave();
5001
+ });
5002
+ };
5003
+ if (delayLeave) delayLeave(el, remove, performLeave);
5004
+ else performLeave();
5005
+ }
5006
+ } else hostInsert(el, container, anchor);
4876
5007
  };
4877
5008
  const unmount = (vnode, parentComponent, parentSuspense, doRemove = false, optimized = false) => {
4878
5009
  const { type, props, ref, children, dynamicChildren, shapeFlag, patchFlag, dirs, cacheIndex, memo } = vnode;
@@ -4892,16 +5023,17 @@ function baseCreateRenderer(options, createHydrationFns) {
4892
5023
  const shouldInvokeVnodeHook = !isAsyncWrapper(vnode);
4893
5024
  let vnodeHook;
4894
5025
  if (shouldInvokeVnodeHook && (vnodeHook = props && props.onVnodeBeforeUnmount)) invokeVNodeHook(vnodeHook, parentComponent, vnode);
4895
- if (shapeFlag & 6) if (isVaporComponent(type)) {
4896
- if (dirs) invokeDirectiveHook(vnode, null, parentComponent, "beforeUnmount");
4897
- getVaporInterface(parentComponent, vnode).unmount(vnode, doRemove, parentSuspense);
4898
- if (shouldInvokeVnodeHook && (vnodeHook = props && props.onVnodeUnmounted) || dirs) queuePostRenderEffect(() => {
4899
- dirs && invokeDirectiveHook(vnode, null, parentComponent, "unmounted");
4900
- vnodeHook && invokeVNodeHook(vnodeHook, parentComponent, vnode);
4901
- }, void 0, parentSuspense);
4902
- return;
4903
- } else unmountComponent(vnode.component, parentSuspense, doRemove);
4904
- else {
5026
+ if (shapeFlag & 6) {
5027
+ if (isVaporComponent(type)) {
5028
+ if (dirs) invokeDirectiveHook(vnode, null, parentComponent, "beforeUnmount");
5029
+ getVaporInterface(parentComponent, vnode).unmount(vnode, doRemove, parentSuspense);
5030
+ if (shouldInvokeVnodeHook && (vnodeHook = props && props.onVnodeUnmounted) || dirs) queuePostRenderEffect(() => {
5031
+ dirs && invokeDirectiveHook(vnode, null, parentComponent, "unmounted");
5032
+ vnodeHook && invokeVNodeHook(vnodeHook, parentComponent, vnode);
5033
+ }, void 0, parentSuspense);
5034
+ return;
5035
+ } else unmountComponent(vnode.component, parentSuspense, doRemove);
5036
+ } else {
4905
5037
  if (shapeFlag & 128) {
4906
5038
  vnode.suspense.unmount(parentSuspense, doRemove);
4907
5039
  return;
@@ -5033,12 +5165,14 @@ function resolveChildrenNamespace({ type, props }, currentNamespace) {
5033
5165
  return currentNamespace === "svg" && type === "foreignObject" || currentNamespace === "mathml" && type === "annotation-xml" && props && props.encoding && props.encoding.includes("html") ? void 0 : currentNamespace;
5034
5166
  }
5035
5167
  function toggleRecurse({ effect, job, vapor }, allowed) {
5036
- if (!vapor) if (allowed) {
5037
- effect.flags |= 128;
5038
- job.flags |= 2;
5039
- } else {
5040
- effect.flags &= -129;
5041
- job.flags &= -3;
5168
+ if (!vapor) {
5169
+ if (allowed) {
5170
+ effect.flags |= 128;
5171
+ job.flags |= 2;
5172
+ } else {
5173
+ effect.flags &= -129;
5174
+ job.flags &= -3;
5175
+ }
5042
5176
  }
5043
5177
  }
5044
5178
  function needTransition(parentSuspense, transition) {
@@ -5078,8 +5212,10 @@ function traverseStaticChildren(n1, n2, shallow = false) {
5078
5212
  }
5079
5213
  function locateNonHydratedAsyncRoot(instance) {
5080
5214
  const subComponent = instance.subTree && instance.subTree.component;
5081
- if (subComponent) if (subComponent.asyncDep && !subComponent.asyncResolved) return subComponent;
5082
- else return locateNonHydratedAsyncRoot(subComponent);
5215
+ if (subComponent) {
5216
+ if (subComponent.asyncDep && !subComponent.asyncResolved) return subComponent;
5217
+ else return locateNonHydratedAsyncRoot(subComponent);
5218
+ }
5083
5219
  }
5084
5220
  function invalidateMount(hooks) {
5085
5221
  if (hooks) for (let i = 0; i < hooks.length; i++) hooks[i].flags |= 4;
@@ -5123,7 +5259,7 @@ function isVaporComponent(type) {
5123
5259
  /**
5124
5260
  * shared between vdom and vapor
5125
5261
  */
5126
- function getInheritedScopeIds(vnode, parentComponent) {
5262
+ function getInheritedScopeIds(vnode, parentComponent, includeVaporRootIds = true) {
5127
5263
  const inheritedScopeIds = [];
5128
5264
  let currentParent = parentComponent;
5129
5265
  let currentVNode = vnode;
@@ -5139,6 +5275,8 @@ function getInheritedScopeIds(vnode, parentComponent) {
5139
5275
  currentParent = currentParent.parent;
5140
5276
  } else break;
5141
5277
  }
5278
+ const vaporScopeIds = includeVaporRootIds && currentVNode.vaporScopeIds;
5279
+ if (vaporScopeIds) inheritedScopeIds.push(...vaporScopeIds);
5142
5280
  return inheritedScopeIds;
5143
5281
  }
5144
5282
  function resolveAsyncComponentPlaceholder(anchorVnode) {
@@ -5198,7 +5336,7 @@ function patchSuspense(n1, n2, container, anchor, parentComponent, namespace, sl
5198
5336
  patch(pendingBranch, newBranch, suspense.hiddenContainer, null, parentComponent, suspense, namespace, slotScopeIds, optimized);
5199
5337
  if (suspense.deps <= 0) suspense.resolve();
5200
5338
  else if (isInFallback) {
5201
- if (!isHydrating) {
5339
+ if (!isHydrating && !suspense.isFallbackMountPending) {
5202
5340
  patch(activeBranch, newFallback, container, anchor, parentComponent, null, namespace, slotScopeIds, optimized);
5203
5341
  setActiveBranch(suspense, newFallback);
5204
5342
  }
@@ -5219,7 +5357,7 @@ function patchSuspense(n1, n2, container, anchor, parentComponent, namespace, sl
5219
5357
  if (isInFallback) {
5220
5358
  patch(null, newBranch, suspense.hiddenContainer, null, parentComponent, suspense, namespace, slotScopeIds, optimized);
5221
5359
  if (suspense.deps <= 0) suspense.resolve();
5222
- else {
5360
+ else if (!suspense.isFallbackMountPending) {
5223
5361
  patch(activeBranch, newFallback, container, anchor, parentComponent, null, namespace, slotScopeIds, optimized);
5224
5362
  setActiveBranch(suspense, newFallback);
5225
5363
  }
@@ -5345,8 +5483,9 @@ function createSuspenseBoundary(vnode, parentSuspense, parentComponent, containe
5345
5483
  const mountFallback = () => {
5346
5484
  suspense.isFallbackMountPending = false;
5347
5485
  if (!suspense.isInFallback) return;
5348
- patch(null, fallbackVNode, container, anchor, parentComponent, null, namespace, slotScopeIds, optimized);
5349
- setActiveBranch(suspense, fallbackVNode);
5486
+ const latestFallback = suspense.vnode.ssFallback;
5487
+ patch(null, latestFallback, container, anchor, parentComponent, null, namespace, slotScopeIds, optimized);
5488
+ setActiveBranch(suspense, latestFallback);
5350
5489
  };
5351
5490
  const delayEnter = fallbackVNode.transition && fallbackVNode.transition.mode === "out-in";
5352
5491
  if (delayEnter) {
@@ -5422,9 +5561,10 @@ function normalizeSuspenseSlot(s) {
5422
5561
  return s;
5423
5562
  }
5424
5563
  function queueEffectWithSuspense(fn, id, suspense) {
5425
- if (suspense && suspense.pendingBranch) if ((0, _vue_shared.isArray)(fn)) suspense.effects.push(...fn);
5426
- else suspense.effects.push(fn);
5427
- else queuePostFlushCb(fn, id);
5564
+ if (suspense && suspense.pendingBranch) {
5565
+ if ((0, _vue_shared.isArray)(fn)) suspense.effects.push(...fn);
5566
+ else suspense.effects.push(fn);
5567
+ } else queuePostFlushCb(fn, id);
5428
5568
  }
5429
5569
  function setActiveBranch(suspense, branch) {
5430
5570
  suspense.activeBranch = branch;
@@ -5618,8 +5758,10 @@ function _createVNode(type, props = null, children = null, patchFlag = 0, dynami
5618
5758
  if (isVNode(type)) {
5619
5759
  const cloned = cloneVNode(type, props, true);
5620
5760
  if (children) normalizeChildren(cloned, children);
5621
- if (isBlockTreeEnabled > 0 && !isBlockNode && currentBlock) if (cloned.shapeFlag & 6) currentBlock[currentBlock.indexOf(type)] = cloned;
5622
- else currentBlock.push(cloned);
5761
+ if (isBlockTreeEnabled > 0 && !isBlockNode && currentBlock) {
5762
+ if (cloned.shapeFlag & 6) currentBlock[currentBlock.indexOf(type)] = cloned;
5763
+ else currentBlock.push(cloned);
5764
+ }
5623
5765
  cloned.patchFlag = -2;
5624
5766
  return cloned;
5625
5767
  }
@@ -5679,7 +5821,9 @@ function cloneVNode(vnode, extraProps, mergeRef = false, cloneTransition = false
5679
5821
  ce: vnode.ce,
5680
5822
  vi: vnode.vi,
5681
5823
  vs: cloneVaporSlotMeta(vnode),
5682
- vb: vnode.vb
5824
+ vb: vnode.vb,
5825
+ ibu: vnode.ibu,
5826
+ iu: vnode.iu
5683
5827
  };
5684
5828
  if (transition && cloneTransition) setTransitionHooks(cloned, transition.clone(cloned));
5685
5829
  return cloned;
@@ -5742,25 +5886,28 @@ function normalizeChildren(vnode, children) {
5742
5886
  const { shapeFlag } = vnode;
5743
5887
  if (children == null) children = null;
5744
5888
  else if ((0, _vue_shared.isArray)(children)) type = 16;
5745
- else if (typeof children === "object") if (shapeFlag & 65) {
5746
- const slot = children.default;
5747
- if (slot) {
5748
- slot._c && (slot._d = false);
5749
- normalizeChildren(vnode, slot());
5750
- slot._c && (slot._d = true);
5751
- }
5752
- return;
5753
- } else {
5754
- type = 32;
5755
- const slotFlag = children._;
5756
- if (!slotFlag && !isInternalObject(children)) children._ctx = currentRenderingInstance;
5757
- else if (slotFlag === 3 && currentRenderingInstance) if (currentRenderingInstance.slots._ === 1) children._ = 1;
5758
- else {
5759
- children._ = 2;
5760
- vnode.patchFlag |= 1024;
5889
+ else if (typeof children === "object") {
5890
+ if (shapeFlag & 65) {
5891
+ const slot = children.default;
5892
+ if (slot) {
5893
+ slot._c && (slot._d = false);
5894
+ normalizeChildren(vnode, slot());
5895
+ slot._c && (slot._d = true);
5896
+ }
5897
+ return;
5898
+ } else {
5899
+ type = 32;
5900
+ const slotFlag = children._;
5901
+ if (!slotFlag && !isInternalObject(children)) children._ctx = currentRenderingInstance;
5902
+ else if (slotFlag === 3 && currentRenderingInstance) {
5903
+ if (currentRenderingInstance.slots._ === 1) children._ = 1;
5904
+ else {
5905
+ children._ = 2;
5906
+ vnode.patchFlag |= 1024;
5907
+ }
5908
+ }
5761
5909
  }
5762
- }
5763
- else if ((0, _vue_shared.isFunction)(children)) {
5910
+ } else if ((0, _vue_shared.isFunction)(children)) {
5764
5911
  if (shapeFlag & 65) {
5765
5912
  normalizeChildren(vnode, { default: children });
5766
5913
  return;
@@ -5878,7 +6025,7 @@ const useInstanceOption = (key, silent = false) => {
5878
6025
  };
5879
6026
  //#endregion
5880
6027
  //#region packages/runtime-core/src/component.ts
5881
- const emptyAppContext = /* @__PURE__ */ createAppContext();
6028
+ const emptyAppContext = /*@__PURE__*/ createAppContext();
5882
6029
  let uid = 0;
5883
6030
  function createComponentInstance(vnode, parent, suspense) {
5884
6031
  const type = vnode.type;
@@ -6023,9 +6170,10 @@ function setupStatefulComponent(instance, isSSR) {
6023
6170
  } else finishComponentSetup(instance, isSSR);
6024
6171
  }
6025
6172
  function handleSetupResult(instance, setupResult, isSSR) {
6026
- if ((0, _vue_shared.isFunction)(setupResult)) if (instance.type.__ssrInlineRender) instance.ssrRender = setupResult;
6027
- else instance.render = setupResult;
6028
- else if ((0, _vue_shared.isObject)(setupResult)) {
6173
+ if ((0, _vue_shared.isFunction)(setupResult)) {
6174
+ if (instance.type.__ssrInlineRender) instance.ssrRender = setupResult;
6175
+ else instance.render = setupResult;
6176
+ } else if ((0, _vue_shared.isObject)(setupResult)) {
6029
6177
  if (isVNode(setupResult)) warn$1("setup() should not return VNodes directly - return a render function instead.");
6030
6178
  instance.devtoolsRawSetupState = setupResult;
6031
6179
  instance.setupState = (0, _vue_reactivity.proxyRefs)(setupResult);
@@ -6076,10 +6224,12 @@ function finishComponentSetup(instance, isSSR, skipOptions) {
6076
6224
  restoreCurrentInstance(prevInstance);
6077
6225
  }
6078
6226
  }
6079
- if (!Component.render && instance.render === _vue_shared.NOOP && !isSSR) if (!compile && Component.template)
6227
+ if (!Component.render && instance.render === _vue_shared.NOOP && !isSSR) {
6228
+ if (!compile && Component.template)
6080
6229
  /* v8 ignore start */
6081
- warn$1("Component provided template option but runtime compilation is not supported in this build of Vue.");
6082
- else warn$1(`Component is missing template or render function: `, Component);
6230
+ warn$1("Component provided template option but runtime compilation is not supported in this build of Vue.");
6231
+ else warn$1(`Component is missing template or render function: `, Component);
6232
+ }
6083
6233
  }
6084
6234
  const attrsProxyHandlers = {
6085
6235
  get(target, key) {
@@ -6187,11 +6337,12 @@ function h(type, propsOrChildren, children) {
6187
6337
  try {
6188
6338
  setBlockTracking(-1);
6189
6339
  const l = arguments.length;
6190
- if (l === 2) if ((0, _vue_shared.isObject)(propsOrChildren) && !(0, _vue_shared.isArray)(propsOrChildren)) {
6191
- if (isVNode(propsOrChildren)) return createVNode(type, null, [propsOrChildren]);
6192
- return createVNode(type, propsOrChildren);
6193
- } else return createVNode(type, null, propsOrChildren);
6194
- else {
6340
+ if (l === 2) {
6341
+ if ((0, _vue_shared.isObject)(propsOrChildren) && !(0, _vue_shared.isArray)(propsOrChildren)) {
6342
+ if (isVNode(propsOrChildren)) return createVNode(type, null, [propsOrChildren]);
6343
+ return createVNode(type, propsOrChildren);
6344
+ } else return createVNode(type, null, propsOrChildren);
6345
+ } else {
6195
6346
  if (l > 3) children = Array.prototype.slice.call(arguments, 2);
6196
6347
  else if (l === 3 && isVNode(children)) children = [children];
6197
6348
  return createVNode(type, propsOrChildren, children);
@@ -6383,7 +6534,7 @@ function isMemoSame(cached, memo) {
6383
6534
  }
6384
6535
  //#endregion
6385
6536
  //#region packages/runtime-core/src/index.ts
6386
- const version = "3.6.0-rc.4";
6537
+ const version = "3.6.0-rc.6";
6387
6538
  const warn = warn$1;
6388
6539
  /**
6389
6540
  * Runtime error messages. Only exposed in dev or esm builds.