@vue/runtime-core 3.4.23 → 3.4.25

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.4.23
2
+ * @vue/runtime-core v3.4.25
3
3
  * (c) 2018-present Yuxi (Evan) You and Vue contributors
4
4
  * @license MIT
5
5
  **/
@@ -850,21 +850,21 @@ function renderComponentRoot(instance) {
850
850
  vnode,
851
851
  proxy,
852
852
  withProxy,
853
- props,
854
853
  propsOptions: [propsOptions],
855
854
  slots,
856
855
  attrs,
857
856
  emit,
858
857
  render,
859
858
  renderCache,
859
+ props,
860
860
  data,
861
861
  setupState,
862
862
  ctx,
863
863
  inheritAttrs
864
864
  } = instance;
865
+ const prev = setCurrentRenderingInstance(instance);
865
866
  let result;
866
867
  let fallthroughAttrs;
867
- const prev = setCurrentRenderingInstance(instance);
868
868
  {
869
869
  accessedAttrs = false;
870
870
  }
@@ -886,7 +886,7 @@ function renderComponentRoot(instance) {
886
886
  thisProxy,
887
887
  proxyToUse,
888
888
  renderCache,
889
- props,
889
+ true ? reactivity.shallowReadonly(props) : props,
890
890
  setupState,
891
891
  data,
892
892
  ctx
@@ -900,7 +900,7 @@ function renderComponentRoot(instance) {
900
900
  }
901
901
  result = normalizeVNode(
902
902
  render2.length > 1 ? render2(
903
- props,
903
+ true ? reactivity.shallowReadonly(props) : props,
904
904
  true ? {
905
905
  get attrs() {
906
906
  markAttrsAccessed();
@@ -910,9 +910,8 @@ function renderComponentRoot(instance) {
910
910
  emit
911
911
  } : { attrs, slots, emit }
912
912
  ) : render2(
913
- props,
913
+ true ? reactivity.shallowReadonly(props) : props,
914
914
  null
915
- /* we know it doesn't need it */
916
915
  )
917
916
  );
918
917
  fallthroughAttrs = Component.props ? attrs : getFunctionalFallthrough(attrs);
@@ -2400,11 +2399,21 @@ function emptyPlaceholder(vnode) {
2400
2399
  }
2401
2400
  }
2402
2401
  function getKeepAliveChild(vnode) {
2403
- return isKeepAlive(vnode) ? (
2404
- // #7121 ensure get the child component subtree in case
2405
- // it's been replaced during HMR
2406
- vnode.component ? vnode.component.subTree : vnode.children ? vnode.children[0] : void 0
2407
- ) : vnode;
2402
+ if (!isKeepAlive(vnode)) {
2403
+ return vnode;
2404
+ }
2405
+ if (vnode.component) {
2406
+ return vnode.component.subTree;
2407
+ }
2408
+ const { shapeFlag, children } = vnode;
2409
+ if (children) {
2410
+ if (shapeFlag & 16) {
2411
+ return children[0];
2412
+ }
2413
+ if (shapeFlag & 32 && shared.isFunction(children.default)) {
2414
+ return children.default();
2415
+ }
2416
+ }
2408
2417
  }
2409
2418
  function setTransitionHooks(vnode, hooks) {
2410
2419
  if (vnode.shapeFlag & 6 && vnode.component) {
@@ -4009,7 +4018,7 @@ function hasInjectionContext() {
4009
4018
  return !!(currentInstance || currentRenderingInstance || currentApp);
4010
4019
  }
4011
4020
 
4012
- const internalObjectProto = /* @__PURE__ */ Object.create(null);
4021
+ const internalObjectProto = {};
4013
4022
  const createInternalObject = () => Object.create(internalObjectProto);
4014
4023
  const isInternalObject = (obj) => Object.getPrototypeOf(obj) === internalObjectProto;
4015
4024
 
@@ -4462,21 +4471,17 @@ const normalizeVNodeSlots = (instance, children) => {
4462
4471
  instance.slots.default = () => normalized;
4463
4472
  };
4464
4473
  const initSlots = (instance, children) => {
4474
+ const slots = instance.slots = createInternalObject();
4465
4475
  if (instance.vnode.shapeFlag & 32) {
4466
4476
  const type = children._;
4467
4477
  if (type) {
4468
- instance.slots = reactivity.toRaw(children);
4469
- shared.def(instance.slots, "_", type);
4478
+ shared.extend(slots, children);
4479
+ shared.def(slots, "_", type);
4470
4480
  } else {
4471
- normalizeObjectSlots(
4472
- children,
4473
- instance.slots = createInternalObject());
4474
- }
4475
- } else {
4476
- instance.slots = createInternalObject();
4477
- if (children) {
4478
- normalizeVNodeSlots(instance, children);
4481
+ normalizeObjectSlots(children, slots);
4479
4482
  }
4483
+ } else if (children) {
4484
+ normalizeVNodeSlots(instance, children);
4480
4485
  }
4481
4486
  };
4482
4487
  const updateSlots = (instance, children, optimized) => {
@@ -8087,7 +8092,7 @@ function isMemoSame(cached, memo) {
8087
8092
  return true;
8088
8093
  }
8089
8094
 
8090
- const version = "3.4.23";
8095
+ const version = "3.4.25";
8091
8096
  const warn = warn$1 ;
8092
8097
  const ErrorTypeStrings = ErrorTypeStrings$1 ;
8093
8098
  const devtools = devtools$1 ;
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @vue/runtime-core v3.4.23
2
+ * @vue/runtime-core v3.4.25
3
3
  * (c) 2018-present Yuxi (Evan) You and Vue contributors
4
4
  * @license MIT
5
5
  **/
@@ -421,21 +421,21 @@ function renderComponentRoot(instance) {
421
421
  vnode,
422
422
  proxy,
423
423
  withProxy,
424
- props,
425
424
  propsOptions: [propsOptions],
426
425
  slots,
427
426
  attrs,
428
427
  emit,
429
428
  render,
430
429
  renderCache,
430
+ props,
431
431
  data,
432
432
  setupState,
433
433
  ctx,
434
434
  inheritAttrs
435
435
  } = instance;
436
+ const prev = setCurrentRenderingInstance(instance);
436
437
  let result;
437
438
  let fallthroughAttrs;
438
- const prev = setCurrentRenderingInstance(instance);
439
439
  try {
440
440
  if (vnode.shapeFlag & 4) {
441
441
  const proxyToUse = withProxy || proxy;
@@ -454,7 +454,7 @@ function renderComponentRoot(instance) {
454
454
  thisProxy,
455
455
  proxyToUse,
456
456
  renderCache,
457
- props,
457
+ false ? shallowReadonly(props) : props,
458
458
  setupState,
459
459
  data,
460
460
  ctx
@@ -466,7 +466,7 @@ function renderComponentRoot(instance) {
466
466
  if (false) ;
467
467
  result = normalizeVNode(
468
468
  render2.length > 1 ? render2(
469
- props,
469
+ false ? shallowReadonly(props) : props,
470
470
  false ? {
471
471
  get attrs() {
472
472
  markAttrsAccessed();
@@ -476,9 +476,8 @@ function renderComponentRoot(instance) {
476
476
  emit
477
477
  } : { attrs, slots, emit }
478
478
  ) : render2(
479
- props,
479
+ false ? shallowReadonly(props) : props,
480
480
  null
481
- /* we know it doesn't need it */
482
481
  )
483
482
  );
484
483
  fallthroughAttrs = Component.props ? attrs : getFunctionalFallthrough(attrs);
@@ -1792,11 +1791,18 @@ function emptyPlaceholder(vnode) {
1792
1791
  }
1793
1792
  }
1794
1793
  function getKeepAliveChild(vnode) {
1795
- return isKeepAlive(vnode) ? (
1796
- // #7121 ensure get the child component subtree in case
1797
- // it's been replaced during HMR
1798
- vnode.children ? vnode.children[0] : void 0
1799
- ) : vnode;
1794
+ if (!isKeepAlive(vnode)) {
1795
+ return vnode;
1796
+ }
1797
+ const { shapeFlag, children } = vnode;
1798
+ if (children) {
1799
+ if (shapeFlag & 16) {
1800
+ return children[0];
1801
+ }
1802
+ if (shapeFlag & 32 && shared.isFunction(children.default)) {
1803
+ return children.default();
1804
+ }
1805
+ }
1800
1806
  }
1801
1807
  function setTransitionHooks(vnode, hooks) {
1802
1808
  if (vnode.shapeFlag & 6 && vnode.component) {
@@ -3075,7 +3081,7 @@ function hasInjectionContext() {
3075
3081
  return !!(currentInstance || currentRenderingInstance || currentApp);
3076
3082
  }
3077
3083
 
3078
- const internalObjectProto = /* @__PURE__ */ Object.create(null);
3084
+ const internalObjectProto = {};
3079
3085
  const createInternalObject = () => Object.create(internalObjectProto);
3080
3086
  const isInternalObject = (obj) => Object.getPrototypeOf(obj) === internalObjectProto;
3081
3087
 
@@ -3390,21 +3396,17 @@ const normalizeVNodeSlots = (instance, children) => {
3390
3396
  instance.slots.default = () => normalized;
3391
3397
  };
3392
3398
  const initSlots = (instance, children) => {
3399
+ const slots = instance.slots = createInternalObject();
3393
3400
  if (instance.vnode.shapeFlag & 32) {
3394
3401
  const type = children._;
3395
3402
  if (type) {
3396
- instance.slots = reactivity.toRaw(children);
3397
- shared.def(instance.slots, "_", type);
3403
+ shared.extend(slots, children);
3404
+ shared.def(slots, "_", type);
3398
3405
  } else {
3399
- normalizeObjectSlots(
3400
- children,
3401
- instance.slots = createInternalObject());
3402
- }
3403
- } else {
3404
- instance.slots = createInternalObject();
3405
- if (children) {
3406
- normalizeVNodeSlots(instance, children);
3406
+ normalizeObjectSlots(children, slots);
3407
3407
  }
3408
+ } else if (children) {
3409
+ normalizeVNodeSlots(instance, children);
3408
3410
  }
3409
3411
  };
3410
3412
  const updateSlots = (instance, children, optimized) => {
@@ -6278,7 +6280,7 @@ function isMemoSame(cached, memo) {
6278
6280
  return true;
6279
6281
  }
6280
6282
 
6281
- const version = "3.4.23";
6283
+ const version = "3.4.25";
6282
6284
  const warn$1 = shared.NOOP;
6283
6285
  const ErrorTypeStrings = ErrorTypeStrings$1 ;
6284
6286
  const devtools = void 0;
@@ -1,9 +1,9 @@
1
1
  /**
2
- * @vue/runtime-core v3.4.23
2
+ * @vue/runtime-core v3.4.25
3
3
  * (c) 2018-present Yuxi (Evan) You and Vue contributors
4
4
  * @license MIT
5
5
  **/
6
- import { pauseTracking, resetTracking, isRef, toRaw, isShallow, isReactive, ReactiveEffect, getCurrentScope, ref, shallowReadonly, track, reactive, shallowReactive, trigger, isProxy, proxyRefs, markRaw, EffectScope, computed as computed$1, customRef, isReadonly } from '@vue/reactivity';
6
+ import { pauseTracking, resetTracking, isRef, toRaw, shallowReadonly, isShallow, isReactive, ReactiveEffect, getCurrentScope, ref, track, reactive, shallowReactive, trigger, isProxy, proxyRefs, markRaw, EffectScope, computed as computed$1, customRef, isReadonly } from '@vue/reactivity';
7
7
  export { EffectScope, ReactiveEffect, TrackOpTypes, TriggerOpTypes, customRef, effect, effectScope, getCurrentScope, isProxy, isReactive, isReadonly, isRef, isShallow, markRaw, onScopeDispose, proxyRefs, reactive, readonly, ref, shallowReactive, shallowReadonly, shallowRef, stop, toRaw, toRef, toRefs, toValue, triggerRef, unref } from '@vue/reactivity';
8
8
  import { isString, isFunction, isPromise, isArray, NOOP, getGlobalThis, extend, EMPTY_OBJ, toHandlerKey, looseToNumber, hyphenate, camelize, isObject, isOn, hasOwn, isModelListener, capitalize, toNumber, hasChanged, remove, isSet, isMap, isPlainObject, isBuiltInDirective, invokeArrayFns, isRegExp, isGloballyAllowed, NO, isReservedProp, EMPTY_ARR, toRawType, makeMap, def, normalizeClass, stringifyStyle, normalizeStyle, isKnownSvgAttr, isBooleanAttr, isKnownHtmlAttr, includeBooleanAttr, isRenderableAttrValue } from '@vue/shared';
9
9
  export { camelize, capitalize, normalizeClass, normalizeProps, normalizeStyle, toDisplayString, toHandlerKey } from '@vue/shared';
@@ -852,21 +852,21 @@ function renderComponentRoot(instance) {
852
852
  vnode,
853
853
  proxy,
854
854
  withProxy,
855
- props,
856
855
  propsOptions: [propsOptions],
857
856
  slots,
858
857
  attrs,
859
858
  emit,
860
859
  render,
861
860
  renderCache,
861
+ props,
862
862
  data,
863
863
  setupState,
864
864
  ctx,
865
865
  inheritAttrs
866
866
  } = instance;
867
+ const prev = setCurrentRenderingInstance(instance);
867
868
  let result;
868
869
  let fallthroughAttrs;
869
- const prev = setCurrentRenderingInstance(instance);
870
870
  if (!!(process.env.NODE_ENV !== "production")) {
871
871
  accessedAttrs = false;
872
872
  }
@@ -888,7 +888,7 @@ function renderComponentRoot(instance) {
888
888
  thisProxy,
889
889
  proxyToUse,
890
890
  renderCache,
891
- props,
891
+ !!(process.env.NODE_ENV !== "production") ? shallowReadonly(props) : props,
892
892
  setupState,
893
893
  data,
894
894
  ctx
@@ -902,7 +902,7 @@ function renderComponentRoot(instance) {
902
902
  }
903
903
  result = normalizeVNode(
904
904
  render2.length > 1 ? render2(
905
- props,
905
+ !!(process.env.NODE_ENV !== "production") ? shallowReadonly(props) : props,
906
906
  !!(process.env.NODE_ENV !== "production") ? {
907
907
  get attrs() {
908
908
  markAttrsAccessed();
@@ -912,9 +912,8 @@ function renderComponentRoot(instance) {
912
912
  emit
913
913
  } : { attrs, slots, emit }
914
914
  ) : render2(
915
- props,
915
+ !!(process.env.NODE_ENV !== "production") ? shallowReadonly(props) : props,
916
916
  null
917
- /* we know it doesn't need it */
918
917
  )
919
918
  );
920
919
  fallthroughAttrs = Component.props ? attrs : getFunctionalFallthrough(attrs);
@@ -2404,11 +2403,21 @@ function emptyPlaceholder(vnode) {
2404
2403
  }
2405
2404
  }
2406
2405
  function getKeepAliveChild(vnode) {
2407
- return isKeepAlive(vnode) ? (
2408
- // #7121 ensure get the child component subtree in case
2409
- // it's been replaced during HMR
2410
- !!(process.env.NODE_ENV !== "production") && vnode.component ? vnode.component.subTree : vnode.children ? vnode.children[0] : void 0
2411
- ) : vnode;
2406
+ if (!isKeepAlive(vnode)) {
2407
+ return vnode;
2408
+ }
2409
+ if (!!(process.env.NODE_ENV !== "production") && vnode.component) {
2410
+ return vnode.component.subTree;
2411
+ }
2412
+ const { shapeFlag, children } = vnode;
2413
+ if (children) {
2414
+ if (shapeFlag & 16) {
2415
+ return children[0];
2416
+ }
2417
+ if (shapeFlag & 32 && isFunction(children.default)) {
2418
+ return children.default();
2419
+ }
2420
+ }
2412
2421
  }
2413
2422
  function setTransitionHooks(vnode, hooks) {
2414
2423
  if (vnode.shapeFlag & 6 && vnode.component) {
@@ -4017,7 +4026,7 @@ function hasInjectionContext() {
4017
4026
  return !!(currentInstance || currentRenderingInstance || currentApp);
4018
4027
  }
4019
4028
 
4020
- const internalObjectProto = /* @__PURE__ */ Object.create(null);
4029
+ const internalObjectProto = {};
4021
4030
  const createInternalObject = () => Object.create(internalObjectProto);
4022
4031
  const isInternalObject = (obj) => Object.getPrototypeOf(obj) === internalObjectProto;
4023
4032
 
@@ -4470,21 +4479,17 @@ const normalizeVNodeSlots = (instance, children) => {
4470
4479
  instance.slots.default = () => normalized;
4471
4480
  };
4472
4481
  const initSlots = (instance, children) => {
4482
+ const slots = instance.slots = createInternalObject();
4473
4483
  if (instance.vnode.shapeFlag & 32) {
4474
4484
  const type = children._;
4475
4485
  if (type) {
4476
- instance.slots = toRaw(children);
4477
- def(instance.slots, "_", type);
4486
+ extend(slots, children);
4487
+ def(slots, "_", type);
4478
4488
  } else {
4479
- normalizeObjectSlots(
4480
- children,
4481
- instance.slots = createInternalObject());
4482
- }
4483
- } else {
4484
- instance.slots = createInternalObject();
4485
- if (children) {
4486
- normalizeVNodeSlots(instance, children);
4489
+ normalizeObjectSlots(children, slots);
4487
4490
  }
4491
+ } else if (children) {
4492
+ normalizeVNodeSlots(instance, children);
4488
4493
  }
4489
4494
  };
4490
4495
  const updateSlots = (instance, children, optimized) => {
@@ -8157,7 +8162,7 @@ function isMemoSame(cached, memo) {
8157
8162
  return true;
8158
8163
  }
8159
8164
 
8160
- const version = "3.4.23";
8165
+ const version = "3.4.25";
8161
8166
  const warn = !!(process.env.NODE_ENV !== "production") ? warn$1 : NOOP;
8162
8167
  const ErrorTypeStrings = ErrorTypeStrings$1 ;
8163
8168
  const devtools = !!(process.env.NODE_ENV !== "production") || true ? devtools$1 : void 0;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vue/runtime-core",
3
- "version": "3.4.23",
3
+ "version": "3.4.25",
4
4
  "description": "@vue/runtime-core",
5
5
  "main": "index.js",
6
6
  "module": "dist/runtime-core.esm-bundler.js",
@@ -46,7 +46,7 @@
46
46
  },
47
47
  "homepage": "https://github.com/vuejs/core/tree/main/packages/runtime-core#readme",
48
48
  "dependencies": {
49
- "@vue/shared": "3.4.23",
50
- "@vue/reactivity": "3.4.23"
49
+ "@vue/shared": "3.4.25",
50
+ "@vue/reactivity": "3.4.25"
51
51
  }
52
52
  }