@vue/runtime-core 3.3.7 → 3.3.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/runtime-core.cjs.js +67 -68
- package/dist/runtime-core.cjs.prod.js +57 -58
- package/dist/runtime-core.d.ts +1 -1
- package/dist/runtime-core.esm-bundler.js +68 -69
- package/package.json +3 -3
package/dist/runtime-core.cjs.js
CHANGED
|
@@ -1050,6 +1050,61 @@ function updateHOCHostEl({ vnode, parent }, el) {
|
|
|
1050
1050
|
}
|
|
1051
1051
|
}
|
|
1052
1052
|
|
|
1053
|
+
const COMPONENTS = "components";
|
|
1054
|
+
const DIRECTIVES = "directives";
|
|
1055
|
+
function resolveComponent(name, maybeSelfReference) {
|
|
1056
|
+
return resolveAsset(COMPONENTS, name, true, maybeSelfReference) || name;
|
|
1057
|
+
}
|
|
1058
|
+
const NULL_DYNAMIC_COMPONENT = Symbol.for("v-ndc");
|
|
1059
|
+
function resolveDynamicComponent(component) {
|
|
1060
|
+
if (shared.isString(component)) {
|
|
1061
|
+
return resolveAsset(COMPONENTS, component, false) || component;
|
|
1062
|
+
} else {
|
|
1063
|
+
return component || NULL_DYNAMIC_COMPONENT;
|
|
1064
|
+
}
|
|
1065
|
+
}
|
|
1066
|
+
function resolveDirective(name) {
|
|
1067
|
+
return resolveAsset(DIRECTIVES, name);
|
|
1068
|
+
}
|
|
1069
|
+
function resolveAsset(type, name, warnMissing = true, maybeSelfReference = false) {
|
|
1070
|
+
const instance = currentRenderingInstance || currentInstance;
|
|
1071
|
+
if (instance) {
|
|
1072
|
+
const Component = instance.type;
|
|
1073
|
+
if (type === COMPONENTS) {
|
|
1074
|
+
const selfName = getComponentName(
|
|
1075
|
+
Component,
|
|
1076
|
+
false
|
|
1077
|
+
/* do not include inferred name to avoid breaking existing code */
|
|
1078
|
+
);
|
|
1079
|
+
if (selfName && (selfName === name || selfName === shared.camelize(name) || selfName === shared.capitalize(shared.camelize(name)))) {
|
|
1080
|
+
return Component;
|
|
1081
|
+
}
|
|
1082
|
+
}
|
|
1083
|
+
const res = (
|
|
1084
|
+
// local registration
|
|
1085
|
+
// check instance[type] first which is resolved for options API
|
|
1086
|
+
resolve(instance[type] || Component[type], name) || // global registration
|
|
1087
|
+
resolve(instance.appContext[type], name)
|
|
1088
|
+
);
|
|
1089
|
+
if (!res && maybeSelfReference) {
|
|
1090
|
+
return Component;
|
|
1091
|
+
}
|
|
1092
|
+
if (warnMissing && !res) {
|
|
1093
|
+
const extra = type === COMPONENTS ? `
|
|
1094
|
+
If this is a native custom element, make sure to exclude it from component resolution via compilerOptions.isCustomElement.` : ``;
|
|
1095
|
+
warn(`Failed to resolve ${type.slice(0, -1)}: ${name}${extra}`);
|
|
1096
|
+
}
|
|
1097
|
+
return res;
|
|
1098
|
+
} else {
|
|
1099
|
+
warn(
|
|
1100
|
+
`resolve${shared.capitalize(type.slice(0, -1))} can only be used in render() or setup().`
|
|
1101
|
+
);
|
|
1102
|
+
}
|
|
1103
|
+
}
|
|
1104
|
+
function resolve(registry, name) {
|
|
1105
|
+
return registry && (registry[name] || registry[shared.camelize(name)] || registry[shared.capitalize(shared.camelize(name))]);
|
|
1106
|
+
}
|
|
1107
|
+
|
|
1053
1108
|
const isSuspense = (type) => type.__isSuspense;
|
|
1054
1109
|
const SuspenseImpl = {
|
|
1055
1110
|
name: "Suspense",
|
|
@@ -1584,7 +1639,7 @@ function normalizeSuspenseSlot(s) {
|
|
|
1584
1639
|
}
|
|
1585
1640
|
if (shared.isArray(s)) {
|
|
1586
1641
|
const singleChild = filterSingleRoot(s);
|
|
1587
|
-
if (!singleChild) {
|
|
1642
|
+
if (!singleChild && s.filter((child) => child !== NULL_DYNAMIC_COMPONENT).length > 0) {
|
|
1588
1643
|
warn(`<Suspense> slots expect a single root node.`);
|
|
1589
1644
|
}
|
|
1590
1645
|
s = singleChild;
|
|
@@ -2696,61 +2751,6 @@ function onErrorCaptured(hook, target = currentInstance) {
|
|
|
2696
2751
|
injectHook("ec", hook, target);
|
|
2697
2752
|
}
|
|
2698
2753
|
|
|
2699
|
-
const COMPONENTS = "components";
|
|
2700
|
-
const DIRECTIVES = "directives";
|
|
2701
|
-
function resolveComponent(name, maybeSelfReference) {
|
|
2702
|
-
return resolveAsset(COMPONENTS, name, true, maybeSelfReference) || name;
|
|
2703
|
-
}
|
|
2704
|
-
const NULL_DYNAMIC_COMPONENT = Symbol.for("v-ndc");
|
|
2705
|
-
function resolveDynamicComponent(component) {
|
|
2706
|
-
if (shared.isString(component)) {
|
|
2707
|
-
return resolveAsset(COMPONENTS, component, false) || component;
|
|
2708
|
-
} else {
|
|
2709
|
-
return component || NULL_DYNAMIC_COMPONENT;
|
|
2710
|
-
}
|
|
2711
|
-
}
|
|
2712
|
-
function resolveDirective(name) {
|
|
2713
|
-
return resolveAsset(DIRECTIVES, name);
|
|
2714
|
-
}
|
|
2715
|
-
function resolveAsset(type, name, warnMissing = true, maybeSelfReference = false) {
|
|
2716
|
-
const instance = currentRenderingInstance || currentInstance;
|
|
2717
|
-
if (instance) {
|
|
2718
|
-
const Component = instance.type;
|
|
2719
|
-
if (type === COMPONENTS) {
|
|
2720
|
-
const selfName = getComponentName(
|
|
2721
|
-
Component,
|
|
2722
|
-
false
|
|
2723
|
-
/* do not include inferred name to avoid breaking existing code */
|
|
2724
|
-
);
|
|
2725
|
-
if (selfName && (selfName === name || selfName === shared.camelize(name) || selfName === shared.capitalize(shared.camelize(name)))) {
|
|
2726
|
-
return Component;
|
|
2727
|
-
}
|
|
2728
|
-
}
|
|
2729
|
-
const res = (
|
|
2730
|
-
// local registration
|
|
2731
|
-
// check instance[type] first which is resolved for options API
|
|
2732
|
-
resolve(instance[type] || Component[type], name) || // global registration
|
|
2733
|
-
resolve(instance.appContext[type], name)
|
|
2734
|
-
);
|
|
2735
|
-
if (!res && maybeSelfReference) {
|
|
2736
|
-
return Component;
|
|
2737
|
-
}
|
|
2738
|
-
if (warnMissing && !res) {
|
|
2739
|
-
const extra = type === COMPONENTS ? `
|
|
2740
|
-
If this is a native custom element, make sure to exclude it from component resolution via compilerOptions.isCustomElement.` : ``;
|
|
2741
|
-
warn(`Failed to resolve ${type.slice(0, -1)}: ${name}${extra}`);
|
|
2742
|
-
}
|
|
2743
|
-
return res;
|
|
2744
|
-
} else {
|
|
2745
|
-
warn(
|
|
2746
|
-
`resolve${shared.capitalize(type.slice(0, -1))} can only be used in render() or setup().`
|
|
2747
|
-
);
|
|
2748
|
-
}
|
|
2749
|
-
}
|
|
2750
|
-
function resolve(registry, name) {
|
|
2751
|
-
return registry && (registry[name] || registry[shared.camelize(name)] || registry[shared.capitalize(shared.camelize(name))]);
|
|
2752
|
-
}
|
|
2753
|
-
|
|
2754
2754
|
function renderList(source, renderItem, cache, index) {
|
|
2755
2755
|
let ret;
|
|
2756
2756
|
const cached = cache && cache[index];
|
|
@@ -4566,15 +4566,15 @@ function createHydrationFunctions(rendererInternals) {
|
|
|
4566
4566
|
}
|
|
4567
4567
|
break;
|
|
4568
4568
|
case Comment:
|
|
4569
|
-
if (
|
|
4570
|
-
|
|
4571
|
-
|
|
4572
|
-
|
|
4573
|
-
|
|
4574
|
-
|
|
4575
|
-
|
|
4576
|
-
|
|
4577
|
-
|
|
4569
|
+
if (isTemplateNode(node)) {
|
|
4570
|
+
nextNode = nextSibling(node);
|
|
4571
|
+
replaceNode(
|
|
4572
|
+
vnode.el = node.content.firstChild,
|
|
4573
|
+
node,
|
|
4574
|
+
parentComponent
|
|
4575
|
+
);
|
|
4576
|
+
} else if (domType !== 8 /* COMMENT */ || isFragmentStart) {
|
|
4577
|
+
nextNode = onMismatch();
|
|
4578
4578
|
} else {
|
|
4579
4579
|
nextNode = nextSibling(node);
|
|
4580
4580
|
}
|
|
@@ -4918,8 +4918,7 @@ function createHydrationFunctions(rendererInternals) {
|
|
|
4918
4918
|
let parent = parentComponent;
|
|
4919
4919
|
while (parent) {
|
|
4920
4920
|
if (parent.vnode.el === oldNode) {
|
|
4921
|
-
parent.vnode.el = newNode;
|
|
4922
|
-
parent.subTree.el = newNode;
|
|
4921
|
+
parent.vnode.el = parent.subTree.el = newNode;
|
|
4923
4922
|
}
|
|
4924
4923
|
parent = parent.parent;
|
|
4925
4924
|
}
|
|
@@ -7721,7 +7720,7 @@ function isMemoSame(cached, memo) {
|
|
|
7721
7720
|
return true;
|
|
7722
7721
|
}
|
|
7723
7722
|
|
|
7724
|
-
const version = "3.3.
|
|
7723
|
+
const version = "3.3.8";
|
|
7725
7724
|
const _ssrUtils = {
|
|
7726
7725
|
createComponentInstance,
|
|
7727
7726
|
setupComponent,
|
|
@@ -568,6 +568,52 @@ function updateHOCHostEl({ vnode, parent }, el) {
|
|
|
568
568
|
}
|
|
569
569
|
}
|
|
570
570
|
|
|
571
|
+
const COMPONENTS = "components";
|
|
572
|
+
const DIRECTIVES = "directives";
|
|
573
|
+
function resolveComponent(name, maybeSelfReference) {
|
|
574
|
+
return resolveAsset(COMPONENTS, name, true, maybeSelfReference) || name;
|
|
575
|
+
}
|
|
576
|
+
const NULL_DYNAMIC_COMPONENT = Symbol.for("v-ndc");
|
|
577
|
+
function resolveDynamicComponent(component) {
|
|
578
|
+
if (shared.isString(component)) {
|
|
579
|
+
return resolveAsset(COMPONENTS, component, false) || component;
|
|
580
|
+
} else {
|
|
581
|
+
return component || NULL_DYNAMIC_COMPONENT;
|
|
582
|
+
}
|
|
583
|
+
}
|
|
584
|
+
function resolveDirective(name) {
|
|
585
|
+
return resolveAsset(DIRECTIVES, name);
|
|
586
|
+
}
|
|
587
|
+
function resolveAsset(type, name, warnMissing = true, maybeSelfReference = false) {
|
|
588
|
+
const instance = currentRenderingInstance || currentInstance;
|
|
589
|
+
if (instance) {
|
|
590
|
+
const Component = instance.type;
|
|
591
|
+
if (type === COMPONENTS) {
|
|
592
|
+
const selfName = getComponentName(
|
|
593
|
+
Component,
|
|
594
|
+
false
|
|
595
|
+
/* do not include inferred name to avoid breaking existing code */
|
|
596
|
+
);
|
|
597
|
+
if (selfName && (selfName === name || selfName === shared.camelize(name) || selfName === shared.capitalize(shared.camelize(name)))) {
|
|
598
|
+
return Component;
|
|
599
|
+
}
|
|
600
|
+
}
|
|
601
|
+
const res = (
|
|
602
|
+
// local registration
|
|
603
|
+
// check instance[type] first which is resolved for options API
|
|
604
|
+
resolve(instance[type] || Component[type], name) || // global registration
|
|
605
|
+
resolve(instance.appContext[type], name)
|
|
606
|
+
);
|
|
607
|
+
if (!res && maybeSelfReference) {
|
|
608
|
+
return Component;
|
|
609
|
+
}
|
|
610
|
+
return res;
|
|
611
|
+
}
|
|
612
|
+
}
|
|
613
|
+
function resolve(registry, name) {
|
|
614
|
+
return registry && (registry[name] || registry[shared.camelize(name)] || registry[shared.capitalize(shared.camelize(name))]);
|
|
615
|
+
}
|
|
616
|
+
|
|
571
617
|
const isSuspense = (type) => type.__isSuspense;
|
|
572
618
|
const SuspenseImpl = {
|
|
573
619
|
name: "Suspense",
|
|
@@ -2111,52 +2157,6 @@ function onErrorCaptured(hook, target = currentInstance) {
|
|
|
2111
2157
|
injectHook("ec", hook, target);
|
|
2112
2158
|
}
|
|
2113
2159
|
|
|
2114
|
-
const COMPONENTS = "components";
|
|
2115
|
-
const DIRECTIVES = "directives";
|
|
2116
|
-
function resolveComponent(name, maybeSelfReference) {
|
|
2117
|
-
return resolveAsset(COMPONENTS, name, true, maybeSelfReference) || name;
|
|
2118
|
-
}
|
|
2119
|
-
const NULL_DYNAMIC_COMPONENT = Symbol.for("v-ndc");
|
|
2120
|
-
function resolveDynamicComponent(component) {
|
|
2121
|
-
if (shared.isString(component)) {
|
|
2122
|
-
return resolveAsset(COMPONENTS, component, false) || component;
|
|
2123
|
-
} else {
|
|
2124
|
-
return component || NULL_DYNAMIC_COMPONENT;
|
|
2125
|
-
}
|
|
2126
|
-
}
|
|
2127
|
-
function resolveDirective(name) {
|
|
2128
|
-
return resolveAsset(DIRECTIVES, name);
|
|
2129
|
-
}
|
|
2130
|
-
function resolveAsset(type, name, warnMissing = true, maybeSelfReference = false) {
|
|
2131
|
-
const instance = currentRenderingInstance || currentInstance;
|
|
2132
|
-
if (instance) {
|
|
2133
|
-
const Component = instance.type;
|
|
2134
|
-
if (type === COMPONENTS) {
|
|
2135
|
-
const selfName = getComponentName(
|
|
2136
|
-
Component,
|
|
2137
|
-
false
|
|
2138
|
-
/* do not include inferred name to avoid breaking existing code */
|
|
2139
|
-
);
|
|
2140
|
-
if (selfName && (selfName === name || selfName === shared.camelize(name) || selfName === shared.capitalize(shared.camelize(name)))) {
|
|
2141
|
-
return Component;
|
|
2142
|
-
}
|
|
2143
|
-
}
|
|
2144
|
-
const res = (
|
|
2145
|
-
// local registration
|
|
2146
|
-
// check instance[type] first which is resolved for options API
|
|
2147
|
-
resolve(instance[type] || Component[type], name) || // global registration
|
|
2148
|
-
resolve(instance.appContext[type], name)
|
|
2149
|
-
);
|
|
2150
|
-
if (!res && maybeSelfReference) {
|
|
2151
|
-
return Component;
|
|
2152
|
-
}
|
|
2153
|
-
return res;
|
|
2154
|
-
}
|
|
2155
|
-
}
|
|
2156
|
-
function resolve(registry, name) {
|
|
2157
|
-
return registry && (registry[name] || registry[shared.camelize(name)] || registry[shared.capitalize(shared.camelize(name))]);
|
|
2158
|
-
}
|
|
2159
|
-
|
|
2160
2160
|
function renderList(source, renderItem, cache, index) {
|
|
2161
2161
|
let ret;
|
|
2162
2162
|
const cached = cache && cache[index];
|
|
@@ -3498,15 +3498,15 @@ function createHydrationFunctions(rendererInternals) {
|
|
|
3498
3498
|
}
|
|
3499
3499
|
break;
|
|
3500
3500
|
case Comment:
|
|
3501
|
-
if (
|
|
3502
|
-
|
|
3503
|
-
|
|
3504
|
-
|
|
3505
|
-
|
|
3506
|
-
|
|
3507
|
-
|
|
3508
|
-
|
|
3509
|
-
|
|
3501
|
+
if (isTemplateNode(node)) {
|
|
3502
|
+
nextNode = nextSibling(node);
|
|
3503
|
+
replaceNode(
|
|
3504
|
+
vnode.el = node.content.firstChild,
|
|
3505
|
+
node,
|
|
3506
|
+
parentComponent
|
|
3507
|
+
);
|
|
3508
|
+
} else if (domType !== 8 /* COMMENT */ || isFragmentStart) {
|
|
3509
|
+
nextNode = onMismatch();
|
|
3510
3510
|
} else {
|
|
3511
3511
|
nextNode = nextSibling(node);
|
|
3512
3512
|
}
|
|
@@ -3820,8 +3820,7 @@ function createHydrationFunctions(rendererInternals) {
|
|
|
3820
3820
|
let parent = parentComponent;
|
|
3821
3821
|
while (parent) {
|
|
3822
3822
|
if (parent.vnode.el === oldNode) {
|
|
3823
|
-
parent.vnode.el = newNode;
|
|
3824
|
-
parent.subTree.el = newNode;
|
|
3823
|
+
parent.vnode.el = parent.subTree.el = newNode;
|
|
3825
3824
|
}
|
|
3826
3825
|
parent = parent.parent;
|
|
3827
3826
|
}
|
|
@@ -6070,7 +6069,7 @@ function isMemoSame(cached, memo) {
|
|
|
6070
6069
|
return true;
|
|
6071
6070
|
}
|
|
6072
6071
|
|
|
6073
|
-
const version = "3.3.
|
|
6072
|
+
const version = "3.3.8";
|
|
6074
6073
|
const _ssrUtils = {
|
|
6075
6074
|
createComponentInstance,
|
|
6076
6075
|
setupComponent,
|
package/dist/runtime-core.d.ts
CHANGED
|
@@ -883,7 +883,7 @@ export type VNodeProps = {
|
|
|
883
883
|
onVnodeBeforeUnmount?: VNodeMountHook | VNodeMountHook[];
|
|
884
884
|
onVnodeUnmounted?: VNodeMountHook | VNodeMountHook[];
|
|
885
885
|
};
|
|
886
|
-
type VNodeChildAtom = VNode | string | number | boolean | null | undefined | void;
|
|
886
|
+
type VNodeChildAtom = VNode | typeof NULL_DYNAMIC_COMPONENT | string | number | boolean | null | undefined | void;
|
|
887
887
|
export type VNodeArrayChildren = Array<VNodeArrayChildren | VNodeChildAtom>;
|
|
888
888
|
export type VNodeChild = VNodeChildAtom | VNodeArrayChildren;
|
|
889
889
|
export type VNodeNormalizedChildren = string | VNodeArrayChildren | RawSlots | null;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { pauseTracking, resetTracking, isRef, toRaw, getCurrentScope, isShallow as isShallow$1, isReactive, ReactiveEffect, ref, shallowReadonly, track, reactive, shallowReactive, trigger, isProxy, proxyRefs, markRaw, EffectScope, computed as computed$1, isReadonly } from '@vue/reactivity';
|
|
2
2
|
export { EffectScope, ReactiveEffect, 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';
|
|
3
|
-
import { isString, isFunction, isPromise, isArray, NOOP, getGlobalThis, extend, EMPTY_OBJ, toHandlerKey, looseToNumber, hyphenate, camelize, isObject, isOn, hasOwn, isModelListener, toNumber, hasChanged, remove, isSet, isMap, isPlainObject, isBuiltInDirective, invokeArrayFns, isRegExp,
|
|
3
|
+
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, def, isReservedProp, EMPTY_ARR, toRawType, makeMap, normalizeClass, normalizeStyle } from '@vue/shared';
|
|
4
4
|
export { camelize, capitalize, normalizeClass, normalizeProps, normalizeStyle, toDisplayString, toHandlerKey } from '@vue/shared';
|
|
5
5
|
|
|
6
6
|
const stack = [];
|
|
@@ -1054,6 +1054,61 @@ function updateHOCHostEl({ vnode, parent }, el) {
|
|
|
1054
1054
|
}
|
|
1055
1055
|
}
|
|
1056
1056
|
|
|
1057
|
+
const COMPONENTS = "components";
|
|
1058
|
+
const DIRECTIVES = "directives";
|
|
1059
|
+
function resolveComponent(name, maybeSelfReference) {
|
|
1060
|
+
return resolveAsset(COMPONENTS, name, true, maybeSelfReference) || name;
|
|
1061
|
+
}
|
|
1062
|
+
const NULL_DYNAMIC_COMPONENT = Symbol.for("v-ndc");
|
|
1063
|
+
function resolveDynamicComponent(component) {
|
|
1064
|
+
if (isString(component)) {
|
|
1065
|
+
return resolveAsset(COMPONENTS, component, false) || component;
|
|
1066
|
+
} else {
|
|
1067
|
+
return component || NULL_DYNAMIC_COMPONENT;
|
|
1068
|
+
}
|
|
1069
|
+
}
|
|
1070
|
+
function resolveDirective(name) {
|
|
1071
|
+
return resolveAsset(DIRECTIVES, name);
|
|
1072
|
+
}
|
|
1073
|
+
function resolveAsset(type, name, warnMissing = true, maybeSelfReference = false) {
|
|
1074
|
+
const instance = currentRenderingInstance || currentInstance;
|
|
1075
|
+
if (instance) {
|
|
1076
|
+
const Component = instance.type;
|
|
1077
|
+
if (type === COMPONENTS) {
|
|
1078
|
+
const selfName = getComponentName(
|
|
1079
|
+
Component,
|
|
1080
|
+
false
|
|
1081
|
+
/* do not include inferred name to avoid breaking existing code */
|
|
1082
|
+
);
|
|
1083
|
+
if (selfName && (selfName === name || selfName === camelize(name) || selfName === capitalize(camelize(name)))) {
|
|
1084
|
+
return Component;
|
|
1085
|
+
}
|
|
1086
|
+
}
|
|
1087
|
+
const res = (
|
|
1088
|
+
// local registration
|
|
1089
|
+
// check instance[type] first which is resolved for options API
|
|
1090
|
+
resolve(instance[type] || Component[type], name) || // global registration
|
|
1091
|
+
resolve(instance.appContext[type], name)
|
|
1092
|
+
);
|
|
1093
|
+
if (!res && maybeSelfReference) {
|
|
1094
|
+
return Component;
|
|
1095
|
+
}
|
|
1096
|
+
if (!!(process.env.NODE_ENV !== "production") && warnMissing && !res) {
|
|
1097
|
+
const extra = type === COMPONENTS ? `
|
|
1098
|
+
If this is a native custom element, make sure to exclude it from component resolution via compilerOptions.isCustomElement.` : ``;
|
|
1099
|
+
warn(`Failed to resolve ${type.slice(0, -1)}: ${name}${extra}`);
|
|
1100
|
+
}
|
|
1101
|
+
return res;
|
|
1102
|
+
} else if (!!(process.env.NODE_ENV !== "production")) {
|
|
1103
|
+
warn(
|
|
1104
|
+
`resolve${capitalize(type.slice(0, -1))} can only be used in render() or setup().`
|
|
1105
|
+
);
|
|
1106
|
+
}
|
|
1107
|
+
}
|
|
1108
|
+
function resolve(registry, name) {
|
|
1109
|
+
return registry && (registry[name] || registry[camelize(name)] || registry[capitalize(camelize(name))]);
|
|
1110
|
+
}
|
|
1111
|
+
|
|
1057
1112
|
const isSuspense = (type) => type.__isSuspense;
|
|
1058
1113
|
const SuspenseImpl = {
|
|
1059
1114
|
name: "Suspense",
|
|
@@ -1588,7 +1643,7 @@ function normalizeSuspenseSlot(s) {
|
|
|
1588
1643
|
}
|
|
1589
1644
|
if (isArray(s)) {
|
|
1590
1645
|
const singleChild = filterSingleRoot(s);
|
|
1591
|
-
if (!!(process.env.NODE_ENV !== "production") && !singleChild) {
|
|
1646
|
+
if (!!(process.env.NODE_ENV !== "production") && !singleChild && s.filter((child) => child !== NULL_DYNAMIC_COMPONENT).length > 0) {
|
|
1592
1647
|
warn(`<Suspense> slots expect a single root node.`);
|
|
1593
1648
|
}
|
|
1594
1649
|
s = singleChild;
|
|
@@ -2702,61 +2757,6 @@ function onErrorCaptured(hook, target = currentInstance) {
|
|
|
2702
2757
|
injectHook("ec", hook, target);
|
|
2703
2758
|
}
|
|
2704
2759
|
|
|
2705
|
-
const COMPONENTS = "components";
|
|
2706
|
-
const DIRECTIVES = "directives";
|
|
2707
|
-
function resolveComponent(name, maybeSelfReference) {
|
|
2708
|
-
return resolveAsset(COMPONENTS, name, true, maybeSelfReference) || name;
|
|
2709
|
-
}
|
|
2710
|
-
const NULL_DYNAMIC_COMPONENT = Symbol.for("v-ndc");
|
|
2711
|
-
function resolveDynamicComponent(component) {
|
|
2712
|
-
if (isString(component)) {
|
|
2713
|
-
return resolveAsset(COMPONENTS, component, false) || component;
|
|
2714
|
-
} else {
|
|
2715
|
-
return component || NULL_DYNAMIC_COMPONENT;
|
|
2716
|
-
}
|
|
2717
|
-
}
|
|
2718
|
-
function resolveDirective(name) {
|
|
2719
|
-
return resolveAsset(DIRECTIVES, name);
|
|
2720
|
-
}
|
|
2721
|
-
function resolveAsset(type, name, warnMissing = true, maybeSelfReference = false) {
|
|
2722
|
-
const instance = currentRenderingInstance || currentInstance;
|
|
2723
|
-
if (instance) {
|
|
2724
|
-
const Component = instance.type;
|
|
2725
|
-
if (type === COMPONENTS) {
|
|
2726
|
-
const selfName = getComponentName(
|
|
2727
|
-
Component,
|
|
2728
|
-
false
|
|
2729
|
-
/* do not include inferred name to avoid breaking existing code */
|
|
2730
|
-
);
|
|
2731
|
-
if (selfName && (selfName === name || selfName === camelize(name) || selfName === capitalize(camelize(name)))) {
|
|
2732
|
-
return Component;
|
|
2733
|
-
}
|
|
2734
|
-
}
|
|
2735
|
-
const res = (
|
|
2736
|
-
// local registration
|
|
2737
|
-
// check instance[type] first which is resolved for options API
|
|
2738
|
-
resolve(instance[type] || Component[type], name) || // global registration
|
|
2739
|
-
resolve(instance.appContext[type], name)
|
|
2740
|
-
);
|
|
2741
|
-
if (!res && maybeSelfReference) {
|
|
2742
|
-
return Component;
|
|
2743
|
-
}
|
|
2744
|
-
if (!!(process.env.NODE_ENV !== "production") && warnMissing && !res) {
|
|
2745
|
-
const extra = type === COMPONENTS ? `
|
|
2746
|
-
If this is a native custom element, make sure to exclude it from component resolution via compilerOptions.isCustomElement.` : ``;
|
|
2747
|
-
warn(`Failed to resolve ${type.slice(0, -1)}: ${name}${extra}`);
|
|
2748
|
-
}
|
|
2749
|
-
return res;
|
|
2750
|
-
} else if (!!(process.env.NODE_ENV !== "production")) {
|
|
2751
|
-
warn(
|
|
2752
|
-
`resolve${capitalize(type.slice(0, -1))} can only be used in render() or setup().`
|
|
2753
|
-
);
|
|
2754
|
-
}
|
|
2755
|
-
}
|
|
2756
|
-
function resolve(registry, name) {
|
|
2757
|
-
return registry && (registry[name] || registry[camelize(name)] || registry[capitalize(camelize(name))]);
|
|
2758
|
-
}
|
|
2759
|
-
|
|
2760
2760
|
function renderList(source, renderItem, cache, index) {
|
|
2761
2761
|
let ret;
|
|
2762
2762
|
const cached = cache && cache[index];
|
|
@@ -4576,15 +4576,15 @@ function createHydrationFunctions(rendererInternals) {
|
|
|
4576
4576
|
}
|
|
4577
4577
|
break;
|
|
4578
4578
|
case Comment:
|
|
4579
|
-
if (
|
|
4580
|
-
|
|
4581
|
-
|
|
4582
|
-
|
|
4583
|
-
|
|
4584
|
-
|
|
4585
|
-
|
|
4586
|
-
|
|
4587
|
-
|
|
4579
|
+
if (isTemplateNode(node)) {
|
|
4580
|
+
nextNode = nextSibling(node);
|
|
4581
|
+
replaceNode(
|
|
4582
|
+
vnode.el = node.content.firstChild,
|
|
4583
|
+
node,
|
|
4584
|
+
parentComponent
|
|
4585
|
+
);
|
|
4586
|
+
} else if (domType !== 8 /* COMMENT */ || isFragmentStart) {
|
|
4587
|
+
nextNode = onMismatch();
|
|
4588
4588
|
} else {
|
|
4589
4589
|
nextNode = nextSibling(node);
|
|
4590
4590
|
}
|
|
@@ -4928,8 +4928,7 @@ function createHydrationFunctions(rendererInternals) {
|
|
|
4928
4928
|
let parent = parentComponent;
|
|
4929
4929
|
while (parent) {
|
|
4930
4930
|
if (parent.vnode.el === oldNode) {
|
|
4931
|
-
parent.vnode.el = newNode;
|
|
4932
|
-
parent.subTree.el = newNode;
|
|
4931
|
+
parent.vnode.el = parent.subTree.el = newNode;
|
|
4933
4932
|
}
|
|
4934
4933
|
parent = parent.parent;
|
|
4935
4934
|
}
|
|
@@ -7781,7 +7780,7 @@ function isMemoSame(cached, memo) {
|
|
|
7781
7780
|
return true;
|
|
7782
7781
|
}
|
|
7783
7782
|
|
|
7784
|
-
const version = "3.3.
|
|
7783
|
+
const version = "3.3.8";
|
|
7785
7784
|
const _ssrUtils = {
|
|
7786
7785
|
createComponentInstance,
|
|
7787
7786
|
setupComponent,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vue/runtime-core",
|
|
3
|
-
"version": "3.3.
|
|
3
|
+
"version": "3.3.8",
|
|
4
4
|
"description": "@vue/runtime-core",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"module": "dist/runtime-core.esm-bundler.js",
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
},
|
|
33
33
|
"homepage": "https://github.com/vuejs/core/tree/main/packages/runtime-core#readme",
|
|
34
34
|
"dependencies": {
|
|
35
|
-
"@vue/shared": "3.3.
|
|
36
|
-
"@vue/reactivity": "3.3.
|
|
35
|
+
"@vue/shared": "3.3.8",
|
|
36
|
+
"@vue/reactivity": "3.3.8"
|
|
37
37
|
}
|
|
38
38
|
}
|