@vue/compat 3.3.0-alpha.7 → 3.3.0-alpha.9
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/vue.cjs.js +1261 -1199
- package/dist/vue.cjs.prod.js +996 -945
- package/dist/vue.esm-browser.js +1262 -1200
- package/dist/vue.esm-browser.prod.js +1 -1
- package/dist/vue.esm-bundler.js +1276 -1214
- package/dist/vue.global.js +1261 -1199
- package/dist/vue.global.prod.js +1 -1
- package/dist/vue.runtime.esm-browser.js +1261 -1199
- package/dist/vue.runtime.esm-browser.prod.js +1 -1
- package/dist/vue.runtime.esm-bundler.js +1275 -1213
- package/dist/vue.runtime.global.js +1260 -1198
- package/dist/vue.runtime.global.prod.js +1 -1
- package/package.json +2 -2
package/dist/vue.cjs.prod.js
CHANGED
|
@@ -2674,25 +2674,41 @@ function setActiveBranch(suspense, branch) {
|
|
|
2674
2674
|
}
|
|
2675
2675
|
}
|
|
2676
2676
|
|
|
2677
|
-
|
|
2678
|
-
|
|
2679
|
-
|
|
2680
|
-
|
|
2681
|
-
|
|
2682
|
-
|
|
2677
|
+
const legacyDirectiveHookMap = {
|
|
2678
|
+
beforeMount: "bind",
|
|
2679
|
+
mounted: "inserted",
|
|
2680
|
+
updated: ["update", "componentUpdated"],
|
|
2681
|
+
unmounted: "unbind"
|
|
2682
|
+
};
|
|
2683
|
+
function mapCompatDirectiveHook(name, dir, instance) {
|
|
2684
|
+
const mappedName = legacyDirectiveHookMap[name];
|
|
2685
|
+
if (mappedName) {
|
|
2686
|
+
if (isArray(mappedName)) {
|
|
2687
|
+
const hook = [];
|
|
2688
|
+
mappedName.forEach((mapped) => {
|
|
2689
|
+
const mappedHook = dir[mapped];
|
|
2690
|
+
if (mappedHook) {
|
|
2691
|
+
softAssertCompatEnabled(
|
|
2692
|
+
"CUSTOM_DIR",
|
|
2693
|
+
instance,
|
|
2694
|
+
mapped,
|
|
2695
|
+
name
|
|
2696
|
+
);
|
|
2697
|
+
hook.push(mappedHook);
|
|
2698
|
+
}
|
|
2699
|
+
});
|
|
2700
|
+
return hook.length ? hook : void 0;
|
|
2701
|
+
} else {
|
|
2702
|
+
if (dir[mappedName]) {
|
|
2703
|
+
softAssertCompatEnabled(
|
|
2704
|
+
"CUSTOM_DIR",
|
|
2705
|
+
instance,
|
|
2706
|
+
mappedName,
|
|
2707
|
+
name
|
|
2708
|
+
);
|
|
2709
|
+
}
|
|
2710
|
+
return dir[mappedName];
|
|
2683
2711
|
}
|
|
2684
|
-
provides[key] = value;
|
|
2685
|
-
}
|
|
2686
|
-
}
|
|
2687
|
-
function inject(key, defaultValue, treatDefaultAsFactory = false) {
|
|
2688
|
-
const instance = currentInstance || currentRenderingInstance;
|
|
2689
|
-
if (instance) {
|
|
2690
|
-
const provides = instance.parent == null ? instance.vnode.appContext && instance.vnode.appContext.provides : instance.parent.provides;
|
|
2691
|
-
if (provides && key in provides) {
|
|
2692
|
-
return provides[key];
|
|
2693
|
-
} else if (arguments.length > 1) {
|
|
2694
|
-
return treatDefaultAsFactory && isFunction(defaultValue) ? defaultValue.call(instance.proxy) : defaultValue;
|
|
2695
|
-
} else ;
|
|
2696
2712
|
}
|
|
2697
2713
|
}
|
|
2698
2714
|
|
|
@@ -2921,6 +2937,62 @@ function traverse(value, seen) {
|
|
|
2921
2937
|
return value;
|
|
2922
2938
|
}
|
|
2923
2939
|
|
|
2940
|
+
function withDirectives(vnode, directives) {
|
|
2941
|
+
const internalInstance = currentRenderingInstance;
|
|
2942
|
+
if (internalInstance === null) {
|
|
2943
|
+
return vnode;
|
|
2944
|
+
}
|
|
2945
|
+
const instance = getExposeProxy(internalInstance) || internalInstance.proxy;
|
|
2946
|
+
const bindings = vnode.dirs || (vnode.dirs = []);
|
|
2947
|
+
for (let i = 0; i < directives.length; i++) {
|
|
2948
|
+
let [dir, value, arg, modifiers = EMPTY_OBJ] = directives[i];
|
|
2949
|
+
if (dir) {
|
|
2950
|
+
if (isFunction(dir)) {
|
|
2951
|
+
dir = {
|
|
2952
|
+
mounted: dir,
|
|
2953
|
+
updated: dir
|
|
2954
|
+
};
|
|
2955
|
+
}
|
|
2956
|
+
if (dir.deep) {
|
|
2957
|
+
traverse(value);
|
|
2958
|
+
}
|
|
2959
|
+
bindings.push({
|
|
2960
|
+
dir,
|
|
2961
|
+
instance,
|
|
2962
|
+
value,
|
|
2963
|
+
oldValue: void 0,
|
|
2964
|
+
arg,
|
|
2965
|
+
modifiers
|
|
2966
|
+
});
|
|
2967
|
+
}
|
|
2968
|
+
}
|
|
2969
|
+
return vnode;
|
|
2970
|
+
}
|
|
2971
|
+
function invokeDirectiveHook(vnode, prevVNode, instance, name) {
|
|
2972
|
+
const bindings = vnode.dirs;
|
|
2973
|
+
const oldBindings = prevVNode && prevVNode.dirs;
|
|
2974
|
+
for (let i = 0; i < bindings.length; i++) {
|
|
2975
|
+
const binding = bindings[i];
|
|
2976
|
+
if (oldBindings) {
|
|
2977
|
+
binding.oldValue = oldBindings[i].value;
|
|
2978
|
+
}
|
|
2979
|
+
let hook = binding.dir[name];
|
|
2980
|
+
if (!hook) {
|
|
2981
|
+
hook = mapCompatDirectiveHook(name, binding.dir, instance);
|
|
2982
|
+
}
|
|
2983
|
+
if (hook) {
|
|
2984
|
+
pauseTracking();
|
|
2985
|
+
callWithAsyncErrorHandling(hook, instance, 8, [
|
|
2986
|
+
vnode.el,
|
|
2987
|
+
binding,
|
|
2988
|
+
vnode,
|
|
2989
|
+
prevVNode
|
|
2990
|
+
]);
|
|
2991
|
+
resetTracking();
|
|
2992
|
+
}
|
|
2993
|
+
}
|
|
2994
|
+
}
|
|
2995
|
+
|
|
2924
2996
|
function useTransitionState() {
|
|
2925
2997
|
const state = {
|
|
2926
2998
|
isMounted: false,
|
|
@@ -3690,100 +3762,6 @@ function getCompatListeners(instance) {
|
|
|
3690
3762
|
return listeners;
|
|
3691
3763
|
}
|
|
3692
3764
|
|
|
3693
|
-
const legacyDirectiveHookMap = {
|
|
3694
|
-
beforeMount: "bind",
|
|
3695
|
-
mounted: "inserted",
|
|
3696
|
-
updated: ["update", "componentUpdated"],
|
|
3697
|
-
unmounted: "unbind"
|
|
3698
|
-
};
|
|
3699
|
-
function mapCompatDirectiveHook(name, dir, instance) {
|
|
3700
|
-
const mappedName = legacyDirectiveHookMap[name];
|
|
3701
|
-
if (mappedName) {
|
|
3702
|
-
if (isArray(mappedName)) {
|
|
3703
|
-
const hook = [];
|
|
3704
|
-
mappedName.forEach((mapped) => {
|
|
3705
|
-
const mappedHook = dir[mapped];
|
|
3706
|
-
if (mappedHook) {
|
|
3707
|
-
softAssertCompatEnabled(
|
|
3708
|
-
"CUSTOM_DIR",
|
|
3709
|
-
instance,
|
|
3710
|
-
mapped,
|
|
3711
|
-
name
|
|
3712
|
-
);
|
|
3713
|
-
hook.push(mappedHook);
|
|
3714
|
-
}
|
|
3715
|
-
});
|
|
3716
|
-
return hook.length ? hook : void 0;
|
|
3717
|
-
} else {
|
|
3718
|
-
if (dir[mappedName]) {
|
|
3719
|
-
softAssertCompatEnabled(
|
|
3720
|
-
"CUSTOM_DIR",
|
|
3721
|
-
instance,
|
|
3722
|
-
mappedName,
|
|
3723
|
-
name
|
|
3724
|
-
);
|
|
3725
|
-
}
|
|
3726
|
-
return dir[mappedName];
|
|
3727
|
-
}
|
|
3728
|
-
}
|
|
3729
|
-
}
|
|
3730
|
-
|
|
3731
|
-
function withDirectives(vnode, directives) {
|
|
3732
|
-
const internalInstance = currentRenderingInstance;
|
|
3733
|
-
if (internalInstance === null) {
|
|
3734
|
-
return vnode;
|
|
3735
|
-
}
|
|
3736
|
-
const instance = getExposeProxy(internalInstance) || internalInstance.proxy;
|
|
3737
|
-
const bindings = vnode.dirs || (vnode.dirs = []);
|
|
3738
|
-
for (let i = 0; i < directives.length; i++) {
|
|
3739
|
-
let [dir, value, arg, modifiers = EMPTY_OBJ] = directives[i];
|
|
3740
|
-
if (dir) {
|
|
3741
|
-
if (isFunction(dir)) {
|
|
3742
|
-
dir = {
|
|
3743
|
-
mounted: dir,
|
|
3744
|
-
updated: dir
|
|
3745
|
-
};
|
|
3746
|
-
}
|
|
3747
|
-
if (dir.deep) {
|
|
3748
|
-
traverse(value);
|
|
3749
|
-
}
|
|
3750
|
-
bindings.push({
|
|
3751
|
-
dir,
|
|
3752
|
-
instance,
|
|
3753
|
-
value,
|
|
3754
|
-
oldValue: void 0,
|
|
3755
|
-
arg,
|
|
3756
|
-
modifiers
|
|
3757
|
-
});
|
|
3758
|
-
}
|
|
3759
|
-
}
|
|
3760
|
-
return vnode;
|
|
3761
|
-
}
|
|
3762
|
-
function invokeDirectiveHook(vnode, prevVNode, instance, name) {
|
|
3763
|
-
const bindings = vnode.dirs;
|
|
3764
|
-
const oldBindings = prevVNode && prevVNode.dirs;
|
|
3765
|
-
for (let i = 0; i < bindings.length; i++) {
|
|
3766
|
-
const binding = bindings[i];
|
|
3767
|
-
if (oldBindings) {
|
|
3768
|
-
binding.oldValue = oldBindings[i].value;
|
|
3769
|
-
}
|
|
3770
|
-
let hook = binding.dir[name];
|
|
3771
|
-
if (!hook) {
|
|
3772
|
-
hook = mapCompatDirectiveHook(name, binding.dir, instance);
|
|
3773
|
-
}
|
|
3774
|
-
if (hook) {
|
|
3775
|
-
pauseTracking();
|
|
3776
|
-
callWithAsyncErrorHandling(hook, instance, 8, [
|
|
3777
|
-
vnode.el,
|
|
3778
|
-
binding,
|
|
3779
|
-
vnode,
|
|
3780
|
-
prevVNode
|
|
3781
|
-
]);
|
|
3782
|
-
resetTracking();
|
|
3783
|
-
}
|
|
3784
|
-
}
|
|
3785
|
-
}
|
|
3786
|
-
|
|
3787
3765
|
const COMPONENTS = "components";
|
|
3788
3766
|
const DIRECTIVES = "directives";
|
|
3789
3767
|
const FILTERS = "filters";
|
|
@@ -4915,918 +4893,949 @@ function mergeWatchOptions(to, from) {
|
|
|
4915
4893
|
return merged;
|
|
4916
4894
|
}
|
|
4917
4895
|
|
|
4918
|
-
function
|
|
4919
|
-
|
|
4920
|
-
{
|
|
4921
|
-
|
|
4922
|
-
|
|
4923
|
-
|
|
4924
|
-
|
|
4925
|
-
|
|
4926
|
-
|
|
4927
|
-
|
|
4928
|
-
|
|
4929
|
-
const injections = instance.type.inject;
|
|
4930
|
-
if (injections) {
|
|
4931
|
-
if (isArray(injections)) {
|
|
4932
|
-
if (injections.includes(key)) {
|
|
4933
|
-
return inject(key);
|
|
4934
|
-
}
|
|
4935
|
-
} else if (key in injections) {
|
|
4936
|
-
return inject(key);
|
|
4937
|
-
}
|
|
4938
|
-
}
|
|
4896
|
+
function installLegacyOptionMergeStrats(config) {
|
|
4897
|
+
config.optionMergeStrategies = new Proxy({}, {
|
|
4898
|
+
get(target, key) {
|
|
4899
|
+
if (key in target) {
|
|
4900
|
+
return target[key];
|
|
4901
|
+
}
|
|
4902
|
+
if (key in internalOptionMergeStrats && softAssertCompatEnabled(
|
|
4903
|
+
"CONFIG_OPTION_MERGE_STRATS",
|
|
4904
|
+
null
|
|
4905
|
+
)) {
|
|
4906
|
+
return internalOptionMergeStrats[key];
|
|
4939
4907
|
}
|
|
4940
4908
|
}
|
|
4941
|
-
);
|
|
4942
|
-
}
|
|
4943
|
-
|
|
4944
|
-
function shouldSkipAttr(key, instance) {
|
|
4945
|
-
if (key === "is") {
|
|
4946
|
-
return true;
|
|
4947
|
-
}
|
|
4948
|
-
if ((key === "class" || key === "style") && isCompatEnabled$1("INSTANCE_ATTRS_CLASS_STYLE", instance)) {
|
|
4949
|
-
return true;
|
|
4950
|
-
}
|
|
4951
|
-
if (isOn(key) && isCompatEnabled$1("INSTANCE_LISTENERS", instance)) {
|
|
4952
|
-
return true;
|
|
4953
|
-
}
|
|
4954
|
-
if (key.startsWith("routerView") || key === "registerRouteInstance") {
|
|
4955
|
-
return true;
|
|
4956
|
-
}
|
|
4957
|
-
return false;
|
|
4909
|
+
});
|
|
4958
4910
|
}
|
|
4959
4911
|
|
|
4960
|
-
|
|
4961
|
-
|
|
4962
|
-
|
|
4963
|
-
|
|
4964
|
-
|
|
4965
|
-
|
|
4966
|
-
|
|
4967
|
-
|
|
4968
|
-
|
|
4912
|
+
let singletonApp;
|
|
4913
|
+
let singletonCtor;
|
|
4914
|
+
function createCompatVue$1(createApp, createSingletonApp) {
|
|
4915
|
+
singletonApp = createSingletonApp({});
|
|
4916
|
+
const Vue = singletonCtor = function Vue2(options = {}) {
|
|
4917
|
+
return createCompatApp(options, Vue2);
|
|
4918
|
+
};
|
|
4919
|
+
function createCompatApp(options = {}, Ctor) {
|
|
4920
|
+
assertCompatEnabled("GLOBAL_MOUNT", null);
|
|
4921
|
+
const { data } = options;
|
|
4922
|
+
if (data && !isFunction(data) && softAssertCompatEnabled("OPTIONS_DATA_FN", null)) {
|
|
4923
|
+
options.data = () => data;
|
|
4969
4924
|
}
|
|
4970
|
-
|
|
4971
|
-
|
|
4972
|
-
|
|
4973
|
-
|
|
4974
|
-
|
|
4975
|
-
|
|
4925
|
+
const app = createApp(options);
|
|
4926
|
+
if (Ctor !== Vue) {
|
|
4927
|
+
applySingletonPrototype(app, Ctor);
|
|
4928
|
+
}
|
|
4929
|
+
const vm = app._createRoot(options);
|
|
4930
|
+
if (options.el) {
|
|
4931
|
+
return vm.$mount(options.el);
|
|
4976
4932
|
} else {
|
|
4977
|
-
|
|
4933
|
+
return vm;
|
|
4978
4934
|
}
|
|
4979
4935
|
}
|
|
4980
|
-
|
|
4981
|
-
|
|
4982
|
-
|
|
4983
|
-
|
|
4984
|
-
|
|
4985
|
-
|
|
4986
|
-
|
|
4987
|
-
} = instance;
|
|
4988
|
-
const rawCurrentProps = toRaw(props);
|
|
4989
|
-
const [options] = instance.propsOptions;
|
|
4990
|
-
let hasAttrsChanged = false;
|
|
4991
|
-
if (
|
|
4992
|
-
// always force full diff in dev
|
|
4993
|
-
// - #1942 if hmr is enabled with sfc component
|
|
4994
|
-
// - vite#872 non-sfc component used by sfc component
|
|
4995
|
-
(optimized || patchFlag > 0) && !(patchFlag & 16)
|
|
4996
|
-
) {
|
|
4997
|
-
if (patchFlag & 8) {
|
|
4998
|
-
const propsToUpdate = instance.vnode.dynamicProps;
|
|
4999
|
-
for (let i = 0; i < propsToUpdate.length; i++) {
|
|
5000
|
-
let key = propsToUpdate[i];
|
|
5001
|
-
if (isEmitListener(instance.emitsOptions, key)) {
|
|
5002
|
-
continue;
|
|
5003
|
-
}
|
|
5004
|
-
const value = rawProps[key];
|
|
5005
|
-
if (options) {
|
|
5006
|
-
if (hasOwn(attrs, key)) {
|
|
5007
|
-
if (value !== attrs[key]) {
|
|
5008
|
-
attrs[key] = value;
|
|
5009
|
-
hasAttrsChanged = true;
|
|
5010
|
-
}
|
|
5011
|
-
} else {
|
|
5012
|
-
const camelizedKey = camelize(key);
|
|
5013
|
-
props[camelizedKey] = resolvePropValue(
|
|
5014
|
-
options,
|
|
5015
|
-
rawCurrentProps,
|
|
5016
|
-
camelizedKey,
|
|
5017
|
-
value,
|
|
5018
|
-
instance,
|
|
5019
|
-
false
|
|
5020
|
-
/* isAbsent */
|
|
5021
|
-
);
|
|
5022
|
-
}
|
|
5023
|
-
} else {
|
|
5024
|
-
{
|
|
5025
|
-
if (isOn(key) && key.endsWith("Native")) {
|
|
5026
|
-
key = key.slice(0, -6);
|
|
5027
|
-
} else if (shouldSkipAttr(key, instance)) {
|
|
5028
|
-
continue;
|
|
5029
|
-
}
|
|
5030
|
-
}
|
|
5031
|
-
if (value !== attrs[key]) {
|
|
5032
|
-
attrs[key] = value;
|
|
5033
|
-
hasAttrsChanged = true;
|
|
5034
|
-
}
|
|
5035
|
-
}
|
|
5036
|
-
}
|
|
5037
|
-
}
|
|
5038
|
-
} else {
|
|
5039
|
-
if (setFullProps(instance, rawProps, props, attrs)) {
|
|
5040
|
-
hasAttrsChanged = true;
|
|
4936
|
+
Vue.version = `2.6.14-compat:${"3.3.0-alpha.9"}`;
|
|
4937
|
+
Vue.config = singletonApp.config;
|
|
4938
|
+
Vue.use = (p, ...options) => {
|
|
4939
|
+
if (p && isFunction(p.install)) {
|
|
4940
|
+
p.install(Vue, ...options);
|
|
4941
|
+
} else if (isFunction(p)) {
|
|
4942
|
+
p(Vue, ...options);
|
|
5041
4943
|
}
|
|
5042
|
-
|
|
5043
|
-
|
|
5044
|
-
|
|
5045
|
-
|
|
5046
|
-
|
|
5047
|
-
|
|
5048
|
-
|
|
5049
|
-
|
|
5050
|
-
|
|
5051
|
-
|
|
5052
|
-
|
|
5053
|
-
|
|
5054
|
-
rawCurrentProps,
|
|
5055
|
-
key,
|
|
5056
|
-
void 0,
|
|
5057
|
-
instance,
|
|
5058
|
-
true
|
|
5059
|
-
/* isAbsent */
|
|
5060
|
-
);
|
|
5061
|
-
}
|
|
5062
|
-
} else {
|
|
5063
|
-
delete props[key];
|
|
5064
|
-
}
|
|
5065
|
-
}
|
|
4944
|
+
return Vue;
|
|
4945
|
+
};
|
|
4946
|
+
Vue.mixin = (m) => {
|
|
4947
|
+
singletonApp.mixin(m);
|
|
4948
|
+
return Vue;
|
|
4949
|
+
};
|
|
4950
|
+
Vue.component = (name, comp) => {
|
|
4951
|
+
if (comp) {
|
|
4952
|
+
singletonApp.component(name, comp);
|
|
4953
|
+
return Vue;
|
|
4954
|
+
} else {
|
|
4955
|
+
return singletonApp.component(name);
|
|
5066
4956
|
}
|
|
5067
|
-
|
|
5068
|
-
|
|
5069
|
-
|
|
5070
|
-
|
|
5071
|
-
|
|
5072
|
-
|
|
5073
|
-
|
|
4957
|
+
};
|
|
4958
|
+
Vue.directive = (name, dir) => {
|
|
4959
|
+
if (dir) {
|
|
4960
|
+
singletonApp.directive(name, dir);
|
|
4961
|
+
return Vue;
|
|
4962
|
+
} else {
|
|
4963
|
+
return singletonApp.directive(name);
|
|
5074
4964
|
}
|
|
5075
|
-
}
|
|
5076
|
-
|
|
5077
|
-
|
|
5078
|
-
|
|
5079
|
-
|
|
5080
|
-
|
|
5081
|
-
|
|
5082
|
-
|
|
5083
|
-
|
|
5084
|
-
|
|
5085
|
-
for (let key in rawProps) {
|
|
5086
|
-
if (isReservedProp(key)) {
|
|
5087
|
-
continue;
|
|
5088
|
-
}
|
|
5089
|
-
{
|
|
5090
|
-
if (key.startsWith("onHook:")) {
|
|
5091
|
-
softAssertCompatEnabled(
|
|
5092
|
-
"INSTANCE_EVENT_HOOKS",
|
|
5093
|
-
instance,
|
|
5094
|
-
key.slice(2).toLowerCase()
|
|
5095
|
-
);
|
|
5096
|
-
}
|
|
5097
|
-
if (key === "inline-template") {
|
|
5098
|
-
continue;
|
|
5099
|
-
}
|
|
5100
|
-
}
|
|
5101
|
-
const value = rawProps[key];
|
|
5102
|
-
let camelKey;
|
|
5103
|
-
if (options && hasOwn(options, camelKey = camelize(key))) {
|
|
5104
|
-
if (!needCastKeys || !needCastKeys.includes(camelKey)) {
|
|
5105
|
-
props[camelKey] = value;
|
|
5106
|
-
} else {
|
|
5107
|
-
(rawCastValues || (rawCastValues = {}))[camelKey] = value;
|
|
5108
|
-
}
|
|
5109
|
-
} else if (!isEmitListener(instance.emitsOptions, key)) {
|
|
5110
|
-
{
|
|
5111
|
-
if (isOn(key) && key.endsWith("Native")) {
|
|
5112
|
-
key = key.slice(0, -6);
|
|
5113
|
-
} else if (shouldSkipAttr(key, instance)) {
|
|
5114
|
-
continue;
|
|
5115
|
-
}
|
|
5116
|
-
}
|
|
5117
|
-
if (!(key in attrs) || value !== attrs[key]) {
|
|
5118
|
-
attrs[key] = value;
|
|
5119
|
-
hasAttrsChanged = true;
|
|
5120
|
-
}
|
|
5121
|
-
}
|
|
4965
|
+
};
|
|
4966
|
+
Vue.options = { _base: Vue };
|
|
4967
|
+
let cid = 1;
|
|
4968
|
+
Vue.cid = cid;
|
|
4969
|
+
Vue.nextTick = nextTick;
|
|
4970
|
+
const extendCache = /* @__PURE__ */ new WeakMap();
|
|
4971
|
+
function extendCtor(extendOptions = {}) {
|
|
4972
|
+
assertCompatEnabled("GLOBAL_EXTEND", null);
|
|
4973
|
+
if (isFunction(extendOptions)) {
|
|
4974
|
+
extendOptions = extendOptions.options;
|
|
5122
4975
|
}
|
|
5123
|
-
|
|
5124
|
-
|
|
5125
|
-
const rawCurrentProps = toRaw(props);
|
|
5126
|
-
const castValues = rawCastValues || EMPTY_OBJ;
|
|
5127
|
-
for (let i = 0; i < needCastKeys.length; i++) {
|
|
5128
|
-
const key = needCastKeys[i];
|
|
5129
|
-
props[key] = resolvePropValue(
|
|
5130
|
-
options,
|
|
5131
|
-
rawCurrentProps,
|
|
5132
|
-
key,
|
|
5133
|
-
castValues[key],
|
|
5134
|
-
instance,
|
|
5135
|
-
!hasOwn(castValues, key)
|
|
5136
|
-
);
|
|
4976
|
+
if (extendCache.has(extendOptions)) {
|
|
4977
|
+
return extendCache.get(extendOptions);
|
|
5137
4978
|
}
|
|
5138
|
-
|
|
5139
|
-
|
|
5140
|
-
|
|
5141
|
-
|
|
5142
|
-
const opt = options[key];
|
|
5143
|
-
if (opt != null) {
|
|
5144
|
-
const hasDefault = hasOwn(opt, "default");
|
|
5145
|
-
if (hasDefault && value === void 0) {
|
|
5146
|
-
const defaultValue = opt.default;
|
|
5147
|
-
if (opt.type !== Function && !opt.skipFactory && isFunction(defaultValue)) {
|
|
5148
|
-
const { propsDefaults } = instance;
|
|
5149
|
-
if (key in propsDefaults) {
|
|
5150
|
-
value = propsDefaults[key];
|
|
5151
|
-
} else {
|
|
5152
|
-
setCurrentInstance(instance);
|
|
5153
|
-
value = propsDefaults[key] = defaultValue.call(
|
|
5154
|
-
isCompatEnabled$1("PROPS_DEFAULT_THIS", instance) ? createPropsDefaultThis(instance, props) : null,
|
|
5155
|
-
props
|
|
5156
|
-
);
|
|
5157
|
-
unsetCurrentInstance();
|
|
5158
|
-
}
|
|
4979
|
+
const Super = this;
|
|
4980
|
+
function SubVue(inlineOptions) {
|
|
4981
|
+
if (!inlineOptions) {
|
|
4982
|
+
return createCompatApp(SubVue.options, SubVue);
|
|
5159
4983
|
} else {
|
|
5160
|
-
|
|
4984
|
+
return createCompatApp(
|
|
4985
|
+
mergeOptions(
|
|
4986
|
+
extend({}, SubVue.options),
|
|
4987
|
+
inlineOptions,
|
|
4988
|
+
internalOptionMergeStrats
|
|
4989
|
+
),
|
|
4990
|
+
SubVue
|
|
4991
|
+
);
|
|
5161
4992
|
}
|
|
5162
4993
|
}
|
|
5163
|
-
|
|
5164
|
-
|
|
5165
|
-
|
|
5166
|
-
|
|
5167
|
-
|
|
5168
|
-
|
|
4994
|
+
SubVue.super = Super;
|
|
4995
|
+
SubVue.prototype = Object.create(Vue.prototype);
|
|
4996
|
+
SubVue.prototype.constructor = SubVue;
|
|
4997
|
+
const mergeBase = {};
|
|
4998
|
+
for (const key in Super.options) {
|
|
4999
|
+
const superValue = Super.options[key];
|
|
5000
|
+
mergeBase[key] = isArray(superValue) ? superValue.slice() : isObject(superValue) ? extend(/* @__PURE__ */ Object.create(null), superValue) : superValue;
|
|
5169
5001
|
}
|
|
5002
|
+
SubVue.options = mergeOptions(
|
|
5003
|
+
mergeBase,
|
|
5004
|
+
extendOptions,
|
|
5005
|
+
internalOptionMergeStrats
|
|
5006
|
+
);
|
|
5007
|
+
SubVue.options._base = SubVue;
|
|
5008
|
+
SubVue.extend = extendCtor.bind(SubVue);
|
|
5009
|
+
SubVue.mixin = Super.mixin;
|
|
5010
|
+
SubVue.use = Super.use;
|
|
5011
|
+
SubVue.cid = ++cid;
|
|
5012
|
+
extendCache.set(extendOptions, SubVue);
|
|
5013
|
+
return SubVue;
|
|
5170
5014
|
}
|
|
5171
|
-
|
|
5172
|
-
|
|
5173
|
-
|
|
5174
|
-
|
|
5175
|
-
|
|
5176
|
-
|
|
5177
|
-
|
|
5178
|
-
|
|
5179
|
-
|
|
5180
|
-
|
|
5181
|
-
|
|
5182
|
-
|
|
5183
|
-
|
|
5184
|
-
|
|
5185
|
-
|
|
5186
|
-
|
|
5187
|
-
|
|
5188
|
-
|
|
5189
|
-
|
|
5190
|
-
extend(normalized, props);
|
|
5191
|
-
if (keys)
|
|
5192
|
-
needCastKeys.push(...keys);
|
|
5193
|
-
};
|
|
5194
|
-
if (!asMixin && appContext.mixins.length) {
|
|
5195
|
-
appContext.mixins.forEach(extendProps);
|
|
5196
|
-
}
|
|
5197
|
-
if (comp.extends) {
|
|
5198
|
-
extendProps(comp.extends);
|
|
5015
|
+
Vue.extend = extendCtor.bind(Vue);
|
|
5016
|
+
Vue.set = (target, key, value) => {
|
|
5017
|
+
assertCompatEnabled("GLOBAL_SET", null);
|
|
5018
|
+
target[key] = value;
|
|
5019
|
+
};
|
|
5020
|
+
Vue.delete = (target, key) => {
|
|
5021
|
+
assertCompatEnabled("GLOBAL_DELETE", null);
|
|
5022
|
+
delete target[key];
|
|
5023
|
+
};
|
|
5024
|
+
Vue.observable = (target) => {
|
|
5025
|
+
assertCompatEnabled("GLOBAL_OBSERVABLE", null);
|
|
5026
|
+
return reactive(target);
|
|
5027
|
+
};
|
|
5028
|
+
Vue.filter = (name, filter) => {
|
|
5029
|
+
if (filter) {
|
|
5030
|
+
singletonApp.filter(name, filter);
|
|
5031
|
+
return Vue;
|
|
5032
|
+
} else {
|
|
5033
|
+
return singletonApp.filter(name);
|
|
5199
5034
|
}
|
|
5200
|
-
|
|
5201
|
-
|
|
5035
|
+
};
|
|
5036
|
+
const util = {
|
|
5037
|
+
warn: NOOP,
|
|
5038
|
+
extend,
|
|
5039
|
+
mergeOptions: (parent, child, vm) => mergeOptions(
|
|
5040
|
+
parent,
|
|
5041
|
+
child,
|
|
5042
|
+
vm ? void 0 : internalOptionMergeStrats
|
|
5043
|
+
),
|
|
5044
|
+
defineReactive
|
|
5045
|
+
};
|
|
5046
|
+
Object.defineProperty(Vue, "util", {
|
|
5047
|
+
get() {
|
|
5048
|
+
assertCompatEnabled("GLOBAL_PRIVATE_UTIL", null);
|
|
5049
|
+
return util;
|
|
5202
5050
|
}
|
|
5051
|
+
});
|
|
5052
|
+
Vue.configureCompat = configureCompat;
|
|
5053
|
+
return Vue;
|
|
5054
|
+
}
|
|
5055
|
+
function installAppCompatProperties(app, context, render) {
|
|
5056
|
+
installFilterMethod(app, context);
|
|
5057
|
+
installLegacyOptionMergeStrats(app.config);
|
|
5058
|
+
if (!singletonApp) {
|
|
5059
|
+
return;
|
|
5203
5060
|
}
|
|
5204
|
-
|
|
5205
|
-
|
|
5206
|
-
|
|
5061
|
+
installCompatMount(app, context, render);
|
|
5062
|
+
installLegacyAPIs(app);
|
|
5063
|
+
applySingletonAppMutations(app);
|
|
5064
|
+
}
|
|
5065
|
+
function installFilterMethod(app, context) {
|
|
5066
|
+
context.filters = {};
|
|
5067
|
+
app.filter = (name, filter) => {
|
|
5068
|
+
assertCompatEnabled("FILTERS", null);
|
|
5069
|
+
if (!filter) {
|
|
5070
|
+
return context.filters[name];
|
|
5207
5071
|
}
|
|
5208
|
-
|
|
5209
|
-
|
|
5210
|
-
|
|
5211
|
-
|
|
5212
|
-
|
|
5213
|
-
|
|
5214
|
-
|
|
5072
|
+
context.filters[name] = filter;
|
|
5073
|
+
return app;
|
|
5074
|
+
};
|
|
5075
|
+
}
|
|
5076
|
+
function installLegacyAPIs(app) {
|
|
5077
|
+
Object.defineProperties(app, {
|
|
5078
|
+
// so that app.use() can work with legacy plugins that extend prototypes
|
|
5079
|
+
prototype: {
|
|
5080
|
+
get() {
|
|
5081
|
+
return app.config.globalProperties;
|
|
5215
5082
|
}
|
|
5216
|
-
}
|
|
5217
|
-
|
|
5218
|
-
|
|
5219
|
-
|
|
5220
|
-
|
|
5221
|
-
|
|
5222
|
-
|
|
5223
|
-
|
|
5224
|
-
|
|
5225
|
-
const stringIndex = getTypeIndex(String, prop.type);
|
|
5226
|
-
prop[0 /* shouldCast */] = booleanIndex > -1;
|
|
5227
|
-
prop[1 /* shouldCastTrue */] = stringIndex < 0 || booleanIndex < stringIndex;
|
|
5228
|
-
if (booleanIndex > -1 || hasOwn(prop, "default")) {
|
|
5229
|
-
needCastKeys.push(normalizedKey);
|
|
5230
|
-
}
|
|
5231
|
-
}
|
|
5083
|
+
},
|
|
5084
|
+
nextTick: { value: nextTick },
|
|
5085
|
+
extend: { value: singletonCtor.extend },
|
|
5086
|
+
set: { value: singletonCtor.set },
|
|
5087
|
+
delete: { value: singletonCtor.delete },
|
|
5088
|
+
observable: { value: singletonCtor.observable },
|
|
5089
|
+
util: {
|
|
5090
|
+
get() {
|
|
5091
|
+
return singletonCtor.util;
|
|
5232
5092
|
}
|
|
5233
5093
|
}
|
|
5234
|
-
}
|
|
5235
|
-
const res = [normalized, needCastKeys];
|
|
5236
|
-
if (isObject(comp)) {
|
|
5237
|
-
cache.set(comp, res);
|
|
5238
|
-
}
|
|
5239
|
-
return res;
|
|
5240
|
-
}
|
|
5241
|
-
function validatePropName(key) {
|
|
5242
|
-
if (key[0] !== "$") {
|
|
5243
|
-
return true;
|
|
5244
|
-
}
|
|
5245
|
-
return false;
|
|
5246
|
-
}
|
|
5247
|
-
function getType(ctor) {
|
|
5248
|
-
const match = ctor && ctor.toString().match(/^\s*(function|class) (\w+)/);
|
|
5249
|
-
return match ? match[2] : ctor === null ? "null" : "";
|
|
5250
|
-
}
|
|
5251
|
-
function isSameType(a, b) {
|
|
5252
|
-
return getType(a) === getType(b);
|
|
5253
|
-
}
|
|
5254
|
-
function getTypeIndex(type, expectedTypes) {
|
|
5255
|
-
if (isArray(expectedTypes)) {
|
|
5256
|
-
return expectedTypes.findIndex((t) => isSameType(t, type));
|
|
5257
|
-
} else if (isFunction(expectedTypes)) {
|
|
5258
|
-
return isSameType(expectedTypes, type) ? 0 : -1;
|
|
5259
|
-
}
|
|
5260
|
-
return -1;
|
|
5094
|
+
});
|
|
5261
5095
|
}
|
|
5262
|
-
|
|
5263
|
-
|
|
5264
|
-
|
|
5265
|
-
|
|
5266
|
-
|
|
5267
|
-
|
|
5268
|
-
|
|
5269
|
-
|
|
5270
|
-
if (
|
|
5271
|
-
return normalizeSlotValue(rawSlot(...args));
|
|
5272
|
-
}, ctx);
|
|
5273
|
-
normalized._c = false;
|
|
5274
|
-
return normalized;
|
|
5275
|
-
};
|
|
5276
|
-
const normalizeObjectSlots = (rawSlots, slots, instance) => {
|
|
5277
|
-
const ctx = rawSlots._ctx;
|
|
5278
|
-
for (const key in rawSlots) {
|
|
5279
|
-
if (isInternalKey(key))
|
|
5096
|
+
function applySingletonAppMutations(app) {
|
|
5097
|
+
app._context.mixins = [...singletonApp._context.mixins];
|
|
5098
|
+
["components", "directives", "filters"].forEach((key) => {
|
|
5099
|
+
app._context[key] = Object.create(singletonApp._context[key]);
|
|
5100
|
+
});
|
|
5101
|
+
for (const key in singletonApp.config) {
|
|
5102
|
+
if (key === "isNativeTag")
|
|
5103
|
+
continue;
|
|
5104
|
+
if (isRuntimeOnly() && (key === "isCustomElement" || key === "compilerOptions")) {
|
|
5280
5105
|
continue;
|
|
5281
|
-
const value = rawSlots[key];
|
|
5282
|
-
if (isFunction(value)) {
|
|
5283
|
-
slots[key] = normalizeSlot(key, value, ctx);
|
|
5284
|
-
} else if (value != null) {
|
|
5285
|
-
const normalized = normalizeSlotValue(value);
|
|
5286
|
-
slots[key] = () => normalized;
|
|
5287
5106
|
}
|
|
5288
|
-
|
|
5289
|
-
|
|
5290
|
-
|
|
5291
|
-
|
|
5292
|
-
|
|
5293
|
-
};
|
|
5294
|
-
const initSlots = (instance, children) => {
|
|
5295
|
-
if (instance.vnode.shapeFlag & 32) {
|
|
5296
|
-
const type = children._;
|
|
5297
|
-
if (type) {
|
|
5298
|
-
instance.slots = toRaw(children);
|
|
5299
|
-
def(children, "_", type);
|
|
5300
|
-
} else {
|
|
5301
|
-
normalizeObjectSlots(
|
|
5302
|
-
children,
|
|
5303
|
-
instance.slots = {});
|
|
5107
|
+
const val = singletonApp.config[key];
|
|
5108
|
+
app.config[key] = isObject(val) ? Object.create(val) : val;
|
|
5109
|
+
if (key === "ignoredElements" && isCompatEnabled$1("CONFIG_IGNORED_ELEMENTS", null) && !isRuntimeOnly() && isArray(val)) {
|
|
5110
|
+
app.config.compilerOptions.isCustomElement = (tag) => {
|
|
5111
|
+
return val.some((v) => isString(v) ? v === tag : v.test(tag));
|
|
5112
|
+
};
|
|
5304
5113
|
}
|
|
5305
|
-
}
|
|
5306
|
-
|
|
5307
|
-
|
|
5308
|
-
|
|
5114
|
+
}
|
|
5115
|
+
applySingletonPrototype(app, singletonCtor);
|
|
5116
|
+
}
|
|
5117
|
+
function applySingletonPrototype(app, Ctor) {
|
|
5118
|
+
const enabled = isCompatEnabled$1("GLOBAL_PROTOTYPE", null);
|
|
5119
|
+
if (enabled) {
|
|
5120
|
+
app.config.globalProperties = Object.create(Ctor.prototype);
|
|
5121
|
+
}
|
|
5122
|
+
const descriptors = Object.getOwnPropertyDescriptors(Ctor.prototype);
|
|
5123
|
+
for (const key in descriptors) {
|
|
5124
|
+
if (key !== "constructor") {
|
|
5125
|
+
if (enabled) {
|
|
5126
|
+
Object.defineProperty(
|
|
5127
|
+
app.config.globalProperties,
|
|
5128
|
+
key,
|
|
5129
|
+
descriptors[key]
|
|
5130
|
+
);
|
|
5131
|
+
}
|
|
5309
5132
|
}
|
|
5310
5133
|
}
|
|
5311
|
-
|
|
5312
|
-
|
|
5313
|
-
|
|
5314
|
-
|
|
5315
|
-
|
|
5316
|
-
|
|
5317
|
-
|
|
5318
|
-
const
|
|
5319
|
-
|
|
5320
|
-
|
|
5321
|
-
|
|
5134
|
+
}
|
|
5135
|
+
function installCompatMount(app, context, render) {
|
|
5136
|
+
let isMounted = false;
|
|
5137
|
+
app._createRoot = (options) => {
|
|
5138
|
+
const component = app._component;
|
|
5139
|
+
const vnode = createVNode(component, options.propsData || null);
|
|
5140
|
+
vnode.appContext = context;
|
|
5141
|
+
const hasNoRender = !isFunction(component) && !component.render && !component.template;
|
|
5142
|
+
const emptyRender = () => {
|
|
5143
|
+
};
|
|
5144
|
+
const instance = createComponentInstance(vnode, null, null);
|
|
5145
|
+
if (hasNoRender) {
|
|
5146
|
+
instance.render = emptyRender;
|
|
5147
|
+
}
|
|
5148
|
+
setupComponent(instance);
|
|
5149
|
+
vnode.component = instance;
|
|
5150
|
+
vnode.isCompatRoot = true;
|
|
5151
|
+
instance.ctx._compat_mount = (selectorOrEl) => {
|
|
5152
|
+
if (isMounted) {
|
|
5153
|
+
return;
|
|
5154
|
+
}
|
|
5155
|
+
let container;
|
|
5156
|
+
if (typeof selectorOrEl === "string") {
|
|
5157
|
+
const result = document.querySelector(selectorOrEl);
|
|
5158
|
+
if (!result) {
|
|
5159
|
+
return;
|
|
5160
|
+
}
|
|
5161
|
+
container = result;
|
|
5322
5162
|
} else {
|
|
5323
|
-
|
|
5324
|
-
|
|
5325
|
-
|
|
5163
|
+
container = selectorOrEl || document.createElement("div");
|
|
5164
|
+
}
|
|
5165
|
+
const isSVG = container instanceof SVGElement;
|
|
5166
|
+
if (hasNoRender && instance.render === emptyRender) {
|
|
5167
|
+
instance.render = null;
|
|
5168
|
+
component.template = container.innerHTML;
|
|
5169
|
+
finishComponentSetup(
|
|
5170
|
+
instance,
|
|
5171
|
+
false,
|
|
5172
|
+
true
|
|
5173
|
+
/* skip options */
|
|
5174
|
+
);
|
|
5175
|
+
}
|
|
5176
|
+
container.innerHTML = "";
|
|
5177
|
+
render(vnode, container, isSVG);
|
|
5178
|
+
if (container instanceof Element) {
|
|
5179
|
+
container.removeAttribute("v-cloak");
|
|
5180
|
+
container.setAttribute("data-v-app", "");
|
|
5181
|
+
}
|
|
5182
|
+
isMounted = true;
|
|
5183
|
+
app._container = container;
|
|
5184
|
+
container.__vue_app__ = app;
|
|
5185
|
+
return instance.proxy;
|
|
5186
|
+
};
|
|
5187
|
+
instance.ctx._compat_destroy = () => {
|
|
5188
|
+
if (isMounted) {
|
|
5189
|
+
render(null, app._container);
|
|
5190
|
+
delete app._container.__vue_app__;
|
|
5191
|
+
} else {
|
|
5192
|
+
const { bum, scope, um } = instance;
|
|
5193
|
+
if (bum) {
|
|
5194
|
+
invokeArrayFns(bum);
|
|
5195
|
+
}
|
|
5196
|
+
if (isCompatEnabled$1("INSTANCE_EVENT_HOOKS", instance)) {
|
|
5197
|
+
instance.emit("hook:beforeDestroy");
|
|
5198
|
+
}
|
|
5199
|
+
if (scope) {
|
|
5200
|
+
scope.stop();
|
|
5201
|
+
}
|
|
5202
|
+
if (um) {
|
|
5203
|
+
invokeArrayFns(um);
|
|
5204
|
+
}
|
|
5205
|
+
if (isCompatEnabled$1("INSTANCE_EVENT_HOOKS", instance)) {
|
|
5206
|
+
instance.emit("hook:destroyed");
|
|
5326
5207
|
}
|
|
5327
5208
|
}
|
|
5209
|
+
};
|
|
5210
|
+
return instance.proxy;
|
|
5211
|
+
};
|
|
5212
|
+
}
|
|
5213
|
+
const methodsToPatch = [
|
|
5214
|
+
"push",
|
|
5215
|
+
"pop",
|
|
5216
|
+
"shift",
|
|
5217
|
+
"unshift",
|
|
5218
|
+
"splice",
|
|
5219
|
+
"sort",
|
|
5220
|
+
"reverse"
|
|
5221
|
+
];
|
|
5222
|
+
const patched = /* @__PURE__ */ new WeakSet();
|
|
5223
|
+
function defineReactive(obj, key, val) {
|
|
5224
|
+
if (isObject(val) && !isReactive(val) && !patched.has(val)) {
|
|
5225
|
+
const reactiveVal = reactive(val);
|
|
5226
|
+
if (isArray(val)) {
|
|
5227
|
+
methodsToPatch.forEach((m) => {
|
|
5228
|
+
val[m] = (...args) => {
|
|
5229
|
+
Array.prototype[m].call(reactiveVal, ...args);
|
|
5230
|
+
};
|
|
5231
|
+
});
|
|
5328
5232
|
} else {
|
|
5329
|
-
|
|
5330
|
-
|
|
5233
|
+
Object.keys(val).forEach((key2) => {
|
|
5234
|
+
try {
|
|
5235
|
+
defineReactiveSimple(val, key2, val[key2]);
|
|
5236
|
+
} catch (e) {
|
|
5237
|
+
}
|
|
5238
|
+
});
|
|
5331
5239
|
}
|
|
5332
|
-
deletionComparisonTarget = children;
|
|
5333
|
-
} else if (children) {
|
|
5334
|
-
normalizeVNodeSlots(instance, children);
|
|
5335
|
-
deletionComparisonTarget = { default: 1 };
|
|
5336
5240
|
}
|
|
5337
|
-
|
|
5338
|
-
|
|
5339
|
-
|
|
5340
|
-
|
|
5341
|
-
|
|
5342
|
-
|
|
5241
|
+
const i = obj.$;
|
|
5242
|
+
if (i && obj === i.proxy) {
|
|
5243
|
+
defineReactiveSimple(i.ctx, key, val);
|
|
5244
|
+
i.accessCache = /* @__PURE__ */ Object.create(null);
|
|
5245
|
+
} else if (isReactive(obj)) {
|
|
5246
|
+
obj[key] = val;
|
|
5247
|
+
} else {
|
|
5248
|
+
defineReactiveSimple(obj, key, val);
|
|
5343
5249
|
}
|
|
5344
|
-
}
|
|
5345
|
-
|
|
5346
|
-
|
|
5347
|
-
|
|
5348
|
-
|
|
5349
|
-
|
|
5350
|
-
|
|
5351
|
-
|
|
5352
|
-
|
|
5353
|
-
|
|
5354
|
-
|
|
5355
|
-
))
|
|
5356
|
-
|
|
5357
|
-
}
|
|
5250
|
+
}
|
|
5251
|
+
function defineReactiveSimple(obj, key, val) {
|
|
5252
|
+
val = isObject(val) ? reactive(val) : val;
|
|
5253
|
+
Object.defineProperty(obj, key, {
|
|
5254
|
+
enumerable: true,
|
|
5255
|
+
configurable: true,
|
|
5256
|
+
get() {
|
|
5257
|
+
track(obj, "get", key);
|
|
5258
|
+
return val;
|
|
5259
|
+
},
|
|
5260
|
+
set(newVal) {
|
|
5261
|
+
val = isObject(newVal) ? reactive(newVal) : newVal;
|
|
5262
|
+
trigger(obj, "set", key, newVal);
|
|
5358
5263
|
}
|
|
5359
5264
|
});
|
|
5360
5265
|
}
|
|
5361
5266
|
|
|
5362
|
-
|
|
5363
|
-
|
|
5364
|
-
|
|
5365
|
-
|
|
5366
|
-
|
|
5367
|
-
|
|
5368
|
-
|
|
5369
|
-
|
|
5370
|
-
|
|
5371
|
-
|
|
5372
|
-
|
|
5373
|
-
|
|
5374
|
-
|
|
5375
|
-
|
|
5376
|
-
|
|
5377
|
-
|
|
5378
|
-
|
|
5379
|
-
|
|
5380
|
-
|
|
5381
|
-
return vm.$mount(options.el);
|
|
5382
|
-
} else {
|
|
5383
|
-
return vm;
|
|
5384
|
-
}
|
|
5385
|
-
}
|
|
5386
|
-
Vue.version = `2.6.14-compat:${"3.3.0-alpha.7"}`;
|
|
5387
|
-
Vue.config = singletonApp.config;
|
|
5388
|
-
Vue.use = (p, ...options) => {
|
|
5389
|
-
if (p && isFunction(p.install)) {
|
|
5390
|
-
p.install(Vue, ...options);
|
|
5391
|
-
} else if (isFunction(p)) {
|
|
5392
|
-
p(Vue, ...options);
|
|
5393
|
-
}
|
|
5394
|
-
return Vue;
|
|
5395
|
-
};
|
|
5396
|
-
Vue.mixin = (m) => {
|
|
5397
|
-
singletonApp.mixin(m);
|
|
5398
|
-
return Vue;
|
|
5399
|
-
};
|
|
5400
|
-
Vue.component = (name, comp) => {
|
|
5401
|
-
if (comp) {
|
|
5402
|
-
singletonApp.component(name, comp);
|
|
5403
|
-
return Vue;
|
|
5404
|
-
} else {
|
|
5405
|
-
return singletonApp.component(name);
|
|
5406
|
-
}
|
|
5407
|
-
};
|
|
5408
|
-
Vue.directive = (name, dir) => {
|
|
5409
|
-
if (dir) {
|
|
5410
|
-
singletonApp.directive(name, dir);
|
|
5411
|
-
return Vue;
|
|
5412
|
-
} else {
|
|
5413
|
-
return singletonApp.directive(name);
|
|
5414
|
-
}
|
|
5267
|
+
function createAppContext() {
|
|
5268
|
+
return {
|
|
5269
|
+
app: null,
|
|
5270
|
+
config: {
|
|
5271
|
+
isNativeTag: NO,
|
|
5272
|
+
performance: false,
|
|
5273
|
+
globalProperties: {},
|
|
5274
|
+
optionMergeStrategies: {},
|
|
5275
|
+
errorHandler: void 0,
|
|
5276
|
+
warnHandler: void 0,
|
|
5277
|
+
compilerOptions: {}
|
|
5278
|
+
},
|
|
5279
|
+
mixins: [],
|
|
5280
|
+
components: {},
|
|
5281
|
+
directives: {},
|
|
5282
|
+
provides: /* @__PURE__ */ Object.create(null),
|
|
5283
|
+
optionsCache: /* @__PURE__ */ new WeakMap(),
|
|
5284
|
+
propsCache: /* @__PURE__ */ new WeakMap(),
|
|
5285
|
+
emitsCache: /* @__PURE__ */ new WeakMap()
|
|
5415
5286
|
};
|
|
5416
|
-
|
|
5417
|
-
|
|
5418
|
-
|
|
5419
|
-
|
|
5420
|
-
|
|
5421
|
-
|
|
5422
|
-
assertCompatEnabled("GLOBAL_EXTEND", null);
|
|
5423
|
-
if (isFunction(extendOptions)) {
|
|
5424
|
-
extendOptions = extendOptions.options;
|
|
5287
|
+
}
|
|
5288
|
+
let uid$1 = 0;
|
|
5289
|
+
function createAppAPI(render, hydrate) {
|
|
5290
|
+
return function createApp(rootComponent, rootProps = null) {
|
|
5291
|
+
if (!isFunction(rootComponent)) {
|
|
5292
|
+
rootComponent = extend({}, rootComponent);
|
|
5425
5293
|
}
|
|
5426
|
-
if (
|
|
5427
|
-
|
|
5294
|
+
if (rootProps != null && !isObject(rootProps)) {
|
|
5295
|
+
rootProps = null;
|
|
5428
5296
|
}
|
|
5429
|
-
const
|
|
5430
|
-
|
|
5431
|
-
|
|
5432
|
-
|
|
5433
|
-
|
|
5434
|
-
|
|
5435
|
-
|
|
5436
|
-
|
|
5437
|
-
|
|
5438
|
-
|
|
5439
|
-
|
|
5440
|
-
|
|
5441
|
-
|
|
5297
|
+
const context = createAppContext();
|
|
5298
|
+
const installedPlugins = /* @__PURE__ */ new Set();
|
|
5299
|
+
let isMounted = false;
|
|
5300
|
+
const app = context.app = {
|
|
5301
|
+
_uid: uid$1++,
|
|
5302
|
+
_component: rootComponent,
|
|
5303
|
+
_props: rootProps,
|
|
5304
|
+
_container: null,
|
|
5305
|
+
_context: context,
|
|
5306
|
+
_instance: null,
|
|
5307
|
+
version,
|
|
5308
|
+
get config() {
|
|
5309
|
+
return context.config;
|
|
5310
|
+
},
|
|
5311
|
+
set config(v) {
|
|
5312
|
+
},
|
|
5313
|
+
use(plugin, ...options) {
|
|
5314
|
+
if (installedPlugins.has(plugin)) ; else if (plugin && isFunction(plugin.install)) {
|
|
5315
|
+
installedPlugins.add(plugin);
|
|
5316
|
+
plugin.install(app, ...options);
|
|
5317
|
+
} else if (isFunction(plugin)) {
|
|
5318
|
+
installedPlugins.add(plugin);
|
|
5319
|
+
plugin(app, ...options);
|
|
5320
|
+
} else ;
|
|
5321
|
+
return app;
|
|
5322
|
+
},
|
|
5323
|
+
mixin(mixin) {
|
|
5324
|
+
{
|
|
5325
|
+
if (!context.mixins.includes(mixin)) {
|
|
5326
|
+
context.mixins.push(mixin);
|
|
5327
|
+
}
|
|
5328
|
+
}
|
|
5329
|
+
return app;
|
|
5330
|
+
},
|
|
5331
|
+
component(name, component) {
|
|
5332
|
+
if (!component) {
|
|
5333
|
+
return context.components[name];
|
|
5334
|
+
}
|
|
5335
|
+
context.components[name] = component;
|
|
5336
|
+
return app;
|
|
5337
|
+
},
|
|
5338
|
+
directive(name, directive) {
|
|
5339
|
+
if (!directive) {
|
|
5340
|
+
return context.directives[name];
|
|
5341
|
+
}
|
|
5342
|
+
context.directives[name] = directive;
|
|
5343
|
+
return app;
|
|
5344
|
+
},
|
|
5345
|
+
mount(rootContainer, isHydrate, isSVG) {
|
|
5346
|
+
if (!isMounted) {
|
|
5347
|
+
const vnode = createVNode(
|
|
5348
|
+
rootComponent,
|
|
5349
|
+
rootProps
|
|
5350
|
+
);
|
|
5351
|
+
vnode.appContext = context;
|
|
5352
|
+
if (isHydrate && hydrate) {
|
|
5353
|
+
hydrate(vnode, rootContainer);
|
|
5354
|
+
} else {
|
|
5355
|
+
render(vnode, rootContainer, isSVG);
|
|
5356
|
+
}
|
|
5357
|
+
isMounted = true;
|
|
5358
|
+
app._container = rootContainer;
|
|
5359
|
+
rootContainer.__vue_app__ = app;
|
|
5360
|
+
return getExposeProxy(vnode.component) || vnode.component.proxy;
|
|
5361
|
+
}
|
|
5362
|
+
},
|
|
5363
|
+
unmount() {
|
|
5364
|
+
if (isMounted) {
|
|
5365
|
+
render(null, app._container);
|
|
5366
|
+
delete app._container.__vue_app__;
|
|
5367
|
+
}
|
|
5368
|
+
},
|
|
5369
|
+
provide(key, value) {
|
|
5370
|
+
context.provides[key] = value;
|
|
5371
|
+
return app;
|
|
5372
|
+
},
|
|
5373
|
+
runWithContext(fn) {
|
|
5374
|
+
currentApp = app;
|
|
5375
|
+
try {
|
|
5376
|
+
return fn();
|
|
5377
|
+
} finally {
|
|
5378
|
+
currentApp = null;
|
|
5379
|
+
}
|
|
5442
5380
|
}
|
|
5381
|
+
};
|
|
5382
|
+
{
|
|
5383
|
+
installAppCompatProperties(app, context, render);
|
|
5443
5384
|
}
|
|
5444
|
-
|
|
5445
|
-
SubVue.prototype = Object.create(Vue.prototype);
|
|
5446
|
-
SubVue.prototype.constructor = SubVue;
|
|
5447
|
-
const mergeBase = {};
|
|
5448
|
-
for (const key in Super.options) {
|
|
5449
|
-
const superValue = Super.options[key];
|
|
5450
|
-
mergeBase[key] = isArray(superValue) ? superValue.slice() : isObject(superValue) ? extend(/* @__PURE__ */ Object.create(null), superValue) : superValue;
|
|
5451
|
-
}
|
|
5452
|
-
SubVue.options = mergeOptions(
|
|
5453
|
-
mergeBase,
|
|
5454
|
-
extendOptions,
|
|
5455
|
-
internalOptionMergeStrats
|
|
5456
|
-
);
|
|
5457
|
-
SubVue.options._base = SubVue;
|
|
5458
|
-
SubVue.extend = extendCtor.bind(SubVue);
|
|
5459
|
-
SubVue.mixin = Super.mixin;
|
|
5460
|
-
SubVue.use = Super.use;
|
|
5461
|
-
SubVue.cid = ++cid;
|
|
5462
|
-
extendCache.set(extendOptions, SubVue);
|
|
5463
|
-
return SubVue;
|
|
5464
|
-
}
|
|
5465
|
-
Vue.extend = extendCtor.bind(Vue);
|
|
5466
|
-
Vue.set = (target, key, value) => {
|
|
5467
|
-
assertCompatEnabled("GLOBAL_SET", null);
|
|
5468
|
-
target[key] = value;
|
|
5469
|
-
};
|
|
5470
|
-
Vue.delete = (target, key) => {
|
|
5471
|
-
assertCompatEnabled("GLOBAL_DELETE", null);
|
|
5472
|
-
delete target[key];
|
|
5473
|
-
};
|
|
5474
|
-
Vue.observable = (target) => {
|
|
5475
|
-
assertCompatEnabled("GLOBAL_OBSERVABLE", null);
|
|
5476
|
-
return reactive(target);
|
|
5385
|
+
return app;
|
|
5477
5386
|
};
|
|
5478
|
-
|
|
5479
|
-
|
|
5480
|
-
|
|
5481
|
-
|
|
5482
|
-
|
|
5483
|
-
|
|
5387
|
+
}
|
|
5388
|
+
let currentApp = null;
|
|
5389
|
+
|
|
5390
|
+
function provide(key, value) {
|
|
5391
|
+
if (!currentInstance) ; else {
|
|
5392
|
+
let provides = currentInstance.provides;
|
|
5393
|
+
const parentProvides = currentInstance.parent && currentInstance.parent.provides;
|
|
5394
|
+
if (parentProvides === provides) {
|
|
5395
|
+
provides = currentInstance.provides = Object.create(parentProvides);
|
|
5484
5396
|
}
|
|
5485
|
-
|
|
5486
|
-
|
|
5487
|
-
|
|
5488
|
-
|
|
5489
|
-
|
|
5490
|
-
|
|
5491
|
-
|
|
5492
|
-
|
|
5493
|
-
|
|
5494
|
-
|
|
5495
|
-
|
|
5496
|
-
|
|
5497
|
-
|
|
5498
|
-
|
|
5499
|
-
|
|
5397
|
+
provides[key] = value;
|
|
5398
|
+
}
|
|
5399
|
+
}
|
|
5400
|
+
function inject(key, defaultValue, treatDefaultAsFactory = false) {
|
|
5401
|
+
const instance = currentInstance || currentRenderingInstance;
|
|
5402
|
+
if (instance || currentApp) {
|
|
5403
|
+
const provides = instance ? instance.parent == null ? instance.vnode.appContext && instance.vnode.appContext.provides : instance.parent.provides : currentApp._context.provides;
|
|
5404
|
+
if (provides && key in provides) {
|
|
5405
|
+
return provides[key];
|
|
5406
|
+
} else if (arguments.length > 1) {
|
|
5407
|
+
return treatDefaultAsFactory && isFunction(defaultValue) ? defaultValue.call(instance && instance.proxy) : defaultValue;
|
|
5408
|
+
} else ;
|
|
5409
|
+
}
|
|
5410
|
+
}
|
|
5411
|
+
|
|
5412
|
+
function createPropsDefaultThis(instance, rawProps, propKey) {
|
|
5413
|
+
return new Proxy(
|
|
5414
|
+
{},
|
|
5415
|
+
{
|
|
5416
|
+
get(_, key) {
|
|
5417
|
+
if (key === "$options") {
|
|
5418
|
+
return resolveMergedOptions(instance);
|
|
5419
|
+
}
|
|
5420
|
+
if (key in rawProps) {
|
|
5421
|
+
return rawProps[key];
|
|
5422
|
+
}
|
|
5423
|
+
const injections = instance.type.inject;
|
|
5424
|
+
if (injections) {
|
|
5425
|
+
if (isArray(injections)) {
|
|
5426
|
+
if (injections.includes(key)) {
|
|
5427
|
+
return inject(key);
|
|
5428
|
+
}
|
|
5429
|
+
} else if (key in injections) {
|
|
5430
|
+
return inject(key);
|
|
5431
|
+
}
|
|
5432
|
+
}
|
|
5433
|
+
}
|
|
5500
5434
|
}
|
|
5501
|
-
|
|
5502
|
-
Vue.configureCompat = configureCompat;
|
|
5503
|
-
return Vue;
|
|
5435
|
+
);
|
|
5504
5436
|
}
|
|
5505
|
-
|
|
5506
|
-
|
|
5507
|
-
|
|
5508
|
-
|
|
5509
|
-
return;
|
|
5437
|
+
|
|
5438
|
+
function shouldSkipAttr(key, instance) {
|
|
5439
|
+
if (key === "is") {
|
|
5440
|
+
return true;
|
|
5510
5441
|
}
|
|
5511
|
-
|
|
5512
|
-
|
|
5513
|
-
|
|
5442
|
+
if ((key === "class" || key === "style") && isCompatEnabled$1("INSTANCE_ATTRS_CLASS_STYLE", instance)) {
|
|
5443
|
+
return true;
|
|
5444
|
+
}
|
|
5445
|
+
if (isOn(key) && isCompatEnabled$1("INSTANCE_LISTENERS", instance)) {
|
|
5446
|
+
return true;
|
|
5447
|
+
}
|
|
5448
|
+
if (key.startsWith("routerView") || key === "registerRouteInstance") {
|
|
5449
|
+
return true;
|
|
5450
|
+
}
|
|
5451
|
+
return false;
|
|
5514
5452
|
}
|
|
5515
|
-
|
|
5516
|
-
|
|
5517
|
-
|
|
5518
|
-
|
|
5519
|
-
|
|
5520
|
-
|
|
5453
|
+
|
|
5454
|
+
function initProps(instance, rawProps, isStateful, isSSR = false) {
|
|
5455
|
+
const props = {};
|
|
5456
|
+
const attrs = {};
|
|
5457
|
+
def(attrs, InternalObjectKey, 1);
|
|
5458
|
+
instance.propsDefaults = /* @__PURE__ */ Object.create(null);
|
|
5459
|
+
setFullProps(instance, rawProps, props, attrs);
|
|
5460
|
+
for (const key in instance.propsOptions[0]) {
|
|
5461
|
+
if (!(key in props)) {
|
|
5462
|
+
props[key] = void 0;
|
|
5521
5463
|
}
|
|
5522
|
-
|
|
5523
|
-
|
|
5524
|
-
|
|
5464
|
+
}
|
|
5465
|
+
if (isStateful) {
|
|
5466
|
+
instance.props = isSSR ? props : shallowReactive(props);
|
|
5467
|
+
} else {
|
|
5468
|
+
if (!instance.type.props) {
|
|
5469
|
+
instance.props = attrs;
|
|
5470
|
+
} else {
|
|
5471
|
+
instance.props = props;
|
|
5472
|
+
}
|
|
5473
|
+
}
|
|
5474
|
+
instance.attrs = attrs;
|
|
5525
5475
|
}
|
|
5526
|
-
function
|
|
5527
|
-
|
|
5528
|
-
|
|
5529
|
-
|
|
5530
|
-
|
|
5531
|
-
|
|
5532
|
-
|
|
5533
|
-
|
|
5534
|
-
|
|
5535
|
-
|
|
5536
|
-
|
|
5537
|
-
|
|
5538
|
-
|
|
5539
|
-
|
|
5540
|
-
|
|
5541
|
-
|
|
5476
|
+
function updateProps(instance, rawProps, rawPrevProps, optimized) {
|
|
5477
|
+
const {
|
|
5478
|
+
props,
|
|
5479
|
+
attrs,
|
|
5480
|
+
vnode: { patchFlag }
|
|
5481
|
+
} = instance;
|
|
5482
|
+
const rawCurrentProps = toRaw(props);
|
|
5483
|
+
const [options] = instance.propsOptions;
|
|
5484
|
+
let hasAttrsChanged = false;
|
|
5485
|
+
if (
|
|
5486
|
+
// always force full diff in dev
|
|
5487
|
+
// - #1942 if hmr is enabled with sfc component
|
|
5488
|
+
// - vite#872 non-sfc component used by sfc component
|
|
5489
|
+
(optimized || patchFlag > 0) && !(patchFlag & 16)
|
|
5490
|
+
) {
|
|
5491
|
+
if (patchFlag & 8) {
|
|
5492
|
+
const propsToUpdate = instance.vnode.dynamicProps;
|
|
5493
|
+
for (let i = 0; i < propsToUpdate.length; i++) {
|
|
5494
|
+
let key = propsToUpdate[i];
|
|
5495
|
+
if (isEmitListener(instance.emitsOptions, key)) {
|
|
5496
|
+
continue;
|
|
5497
|
+
}
|
|
5498
|
+
const value = rawProps[key];
|
|
5499
|
+
if (options) {
|
|
5500
|
+
if (hasOwn(attrs, key)) {
|
|
5501
|
+
if (value !== attrs[key]) {
|
|
5502
|
+
attrs[key] = value;
|
|
5503
|
+
hasAttrsChanged = true;
|
|
5504
|
+
}
|
|
5505
|
+
} else {
|
|
5506
|
+
const camelizedKey = camelize(key);
|
|
5507
|
+
props[camelizedKey] = resolvePropValue(
|
|
5508
|
+
options,
|
|
5509
|
+
rawCurrentProps,
|
|
5510
|
+
camelizedKey,
|
|
5511
|
+
value,
|
|
5512
|
+
instance,
|
|
5513
|
+
false
|
|
5514
|
+
/* isAbsent */
|
|
5515
|
+
);
|
|
5516
|
+
}
|
|
5517
|
+
} else {
|
|
5518
|
+
{
|
|
5519
|
+
if (isOn(key) && key.endsWith("Native")) {
|
|
5520
|
+
key = key.slice(0, -6);
|
|
5521
|
+
} else if (shouldSkipAttr(key, instance)) {
|
|
5522
|
+
continue;
|
|
5523
|
+
}
|
|
5524
|
+
}
|
|
5525
|
+
if (value !== attrs[key]) {
|
|
5526
|
+
attrs[key] = value;
|
|
5527
|
+
hasAttrsChanged = true;
|
|
5528
|
+
}
|
|
5529
|
+
}
|
|
5542
5530
|
}
|
|
5543
5531
|
}
|
|
5544
|
-
}
|
|
5545
|
-
|
|
5546
|
-
|
|
5547
|
-
app._context.mixins = [...singletonApp._context.mixins];
|
|
5548
|
-
["components", "directives", "filters"].forEach((key) => {
|
|
5549
|
-
app._context[key] = Object.create(singletonApp._context[key]);
|
|
5550
|
-
});
|
|
5551
|
-
for (const key in singletonApp.config) {
|
|
5552
|
-
if (key === "isNativeTag")
|
|
5553
|
-
continue;
|
|
5554
|
-
if (isRuntimeOnly() && (key === "isCustomElement" || key === "compilerOptions")) {
|
|
5555
|
-
continue;
|
|
5532
|
+
} else {
|
|
5533
|
+
if (setFullProps(instance, rawProps, props, attrs)) {
|
|
5534
|
+
hasAttrsChanged = true;
|
|
5556
5535
|
}
|
|
5557
|
-
|
|
5558
|
-
|
|
5559
|
-
|
|
5560
|
-
|
|
5561
|
-
|
|
5562
|
-
|
|
5536
|
+
let kebabKey;
|
|
5537
|
+
for (const key in rawCurrentProps) {
|
|
5538
|
+
if (!rawProps || // for camelCase
|
|
5539
|
+
!hasOwn(rawProps, key) && // it's possible the original props was passed in as kebab-case
|
|
5540
|
+
// and converted to camelCase (#955)
|
|
5541
|
+
((kebabKey = hyphenate(key)) === key || !hasOwn(rawProps, kebabKey))) {
|
|
5542
|
+
if (options) {
|
|
5543
|
+
if (rawPrevProps && // for camelCase
|
|
5544
|
+
(rawPrevProps[key] !== void 0 || // for kebab-case
|
|
5545
|
+
rawPrevProps[kebabKey] !== void 0)) {
|
|
5546
|
+
props[key] = resolvePropValue(
|
|
5547
|
+
options,
|
|
5548
|
+
rawCurrentProps,
|
|
5549
|
+
key,
|
|
5550
|
+
void 0,
|
|
5551
|
+
instance,
|
|
5552
|
+
true
|
|
5553
|
+
/* isAbsent */
|
|
5554
|
+
);
|
|
5555
|
+
}
|
|
5556
|
+
} else {
|
|
5557
|
+
delete props[key];
|
|
5558
|
+
}
|
|
5559
|
+
}
|
|
5560
|
+
}
|
|
5561
|
+
if (attrs !== rawCurrentProps) {
|
|
5562
|
+
for (const key in attrs) {
|
|
5563
|
+
if (!rawProps || !hasOwn(rawProps, key) && !hasOwn(rawProps, key + "Native")) {
|
|
5564
|
+
delete attrs[key];
|
|
5565
|
+
hasAttrsChanged = true;
|
|
5566
|
+
}
|
|
5567
|
+
}
|
|
5563
5568
|
}
|
|
5564
5569
|
}
|
|
5565
|
-
|
|
5566
|
-
|
|
5567
|
-
function applySingletonPrototype(app, Ctor) {
|
|
5568
|
-
const enabled = isCompatEnabled$1("GLOBAL_PROTOTYPE", null);
|
|
5569
|
-
if (enabled) {
|
|
5570
|
-
app.config.globalProperties = Object.create(Ctor.prototype);
|
|
5570
|
+
if (hasAttrsChanged) {
|
|
5571
|
+
trigger(instance, "set", "$attrs");
|
|
5571
5572
|
}
|
|
5572
|
-
|
|
5573
|
-
|
|
5574
|
-
|
|
5575
|
-
|
|
5576
|
-
|
|
5577
|
-
|
|
5578
|
-
|
|
5579
|
-
|
|
5580
|
-
|
|
5573
|
+
}
|
|
5574
|
+
function setFullProps(instance, rawProps, props, attrs) {
|
|
5575
|
+
const [options, needCastKeys] = instance.propsOptions;
|
|
5576
|
+
let hasAttrsChanged = false;
|
|
5577
|
+
let rawCastValues;
|
|
5578
|
+
if (rawProps) {
|
|
5579
|
+
for (let key in rawProps) {
|
|
5580
|
+
if (isReservedProp(key)) {
|
|
5581
|
+
continue;
|
|
5582
|
+
}
|
|
5583
|
+
{
|
|
5584
|
+
if (key.startsWith("onHook:")) {
|
|
5585
|
+
softAssertCompatEnabled(
|
|
5586
|
+
"INSTANCE_EVENT_HOOKS",
|
|
5587
|
+
instance,
|
|
5588
|
+
key.slice(2).toLowerCase()
|
|
5589
|
+
);
|
|
5590
|
+
}
|
|
5591
|
+
if (key === "inline-template") {
|
|
5592
|
+
continue;
|
|
5593
|
+
}
|
|
5594
|
+
}
|
|
5595
|
+
const value = rawProps[key];
|
|
5596
|
+
let camelKey;
|
|
5597
|
+
if (options && hasOwn(options, camelKey = camelize(key))) {
|
|
5598
|
+
if (!needCastKeys || !needCastKeys.includes(camelKey)) {
|
|
5599
|
+
props[camelKey] = value;
|
|
5600
|
+
} else {
|
|
5601
|
+
(rawCastValues || (rawCastValues = {}))[camelKey] = value;
|
|
5602
|
+
}
|
|
5603
|
+
} else if (!isEmitListener(instance.emitsOptions, key)) {
|
|
5604
|
+
{
|
|
5605
|
+
if (isOn(key) && key.endsWith("Native")) {
|
|
5606
|
+
key = key.slice(0, -6);
|
|
5607
|
+
} else if (shouldSkipAttr(key, instance)) {
|
|
5608
|
+
continue;
|
|
5609
|
+
}
|
|
5610
|
+
}
|
|
5611
|
+
if (!(key in attrs) || value !== attrs[key]) {
|
|
5612
|
+
attrs[key] = value;
|
|
5613
|
+
hasAttrsChanged = true;
|
|
5614
|
+
}
|
|
5581
5615
|
}
|
|
5582
5616
|
}
|
|
5583
5617
|
}
|
|
5584
|
-
|
|
5585
|
-
|
|
5586
|
-
|
|
5587
|
-
|
|
5588
|
-
|
|
5589
|
-
|
|
5590
|
-
|
|
5591
|
-
|
|
5592
|
-
|
|
5593
|
-
|
|
5594
|
-
|
|
5595
|
-
|
|
5596
|
-
|
|
5618
|
+
if (needCastKeys) {
|
|
5619
|
+
const rawCurrentProps = toRaw(props);
|
|
5620
|
+
const castValues = rawCastValues || EMPTY_OBJ;
|
|
5621
|
+
for (let i = 0; i < needCastKeys.length; i++) {
|
|
5622
|
+
const key = needCastKeys[i];
|
|
5623
|
+
props[key] = resolvePropValue(
|
|
5624
|
+
options,
|
|
5625
|
+
rawCurrentProps,
|
|
5626
|
+
key,
|
|
5627
|
+
castValues[key],
|
|
5628
|
+
instance,
|
|
5629
|
+
!hasOwn(castValues, key)
|
|
5630
|
+
);
|
|
5597
5631
|
}
|
|
5598
|
-
|
|
5599
|
-
|
|
5600
|
-
|
|
5601
|
-
|
|
5602
|
-
|
|
5603
|
-
|
|
5604
|
-
|
|
5605
|
-
|
|
5606
|
-
|
|
5607
|
-
|
|
5608
|
-
|
|
5609
|
-
|
|
5632
|
+
}
|
|
5633
|
+
return hasAttrsChanged;
|
|
5634
|
+
}
|
|
5635
|
+
function resolvePropValue(options, props, key, value, instance, isAbsent) {
|
|
5636
|
+
const opt = options[key];
|
|
5637
|
+
if (opt != null) {
|
|
5638
|
+
const hasDefault = hasOwn(opt, "default");
|
|
5639
|
+
if (hasDefault && value === void 0) {
|
|
5640
|
+
const defaultValue = opt.default;
|
|
5641
|
+
if (opt.type !== Function && !opt.skipFactory && isFunction(defaultValue)) {
|
|
5642
|
+
const { propsDefaults } = instance;
|
|
5643
|
+
if (key in propsDefaults) {
|
|
5644
|
+
value = propsDefaults[key];
|
|
5645
|
+
} else {
|
|
5646
|
+
setCurrentInstance(instance);
|
|
5647
|
+
value = propsDefaults[key] = defaultValue.call(
|
|
5648
|
+
isCompatEnabled$1("PROPS_DEFAULT_THIS", instance) ? createPropsDefaultThis(instance, props) : null,
|
|
5649
|
+
props
|
|
5650
|
+
);
|
|
5651
|
+
unsetCurrentInstance();
|
|
5610
5652
|
}
|
|
5611
|
-
container = result;
|
|
5612
5653
|
} else {
|
|
5613
|
-
|
|
5654
|
+
value = defaultValue;
|
|
5614
5655
|
}
|
|
5615
|
-
|
|
5616
|
-
|
|
5617
|
-
|
|
5618
|
-
|
|
5619
|
-
|
|
5620
|
-
|
|
5621
|
-
false,
|
|
5622
|
-
true
|
|
5623
|
-
/* skip options */
|
|
5624
|
-
);
|
|
5656
|
+
}
|
|
5657
|
+
if (opt[0 /* shouldCast */]) {
|
|
5658
|
+
if (isAbsent && !hasDefault) {
|
|
5659
|
+
value = false;
|
|
5660
|
+
} else if (opt[1 /* shouldCastTrue */] && (value === "" || value === hyphenate(key))) {
|
|
5661
|
+
value = true;
|
|
5625
5662
|
}
|
|
5626
|
-
|
|
5627
|
-
|
|
5628
|
-
|
|
5629
|
-
|
|
5630
|
-
|
|
5663
|
+
}
|
|
5664
|
+
}
|
|
5665
|
+
return value;
|
|
5666
|
+
}
|
|
5667
|
+
function normalizePropsOptions(comp, appContext, asMixin = false) {
|
|
5668
|
+
const cache = appContext.propsCache;
|
|
5669
|
+
const cached = cache.get(comp);
|
|
5670
|
+
if (cached) {
|
|
5671
|
+
return cached;
|
|
5672
|
+
}
|
|
5673
|
+
const raw = comp.props;
|
|
5674
|
+
const normalized = {};
|
|
5675
|
+
const needCastKeys = [];
|
|
5676
|
+
let hasExtends = false;
|
|
5677
|
+
if (!isFunction(comp)) {
|
|
5678
|
+
const extendProps = (raw2) => {
|
|
5679
|
+
if (isFunction(raw2)) {
|
|
5680
|
+
raw2 = raw2.options;
|
|
5631
5681
|
}
|
|
5632
|
-
|
|
5633
|
-
|
|
5634
|
-
|
|
5635
|
-
|
|
5682
|
+
hasExtends = true;
|
|
5683
|
+
const [props, keys] = normalizePropsOptions(raw2, appContext, true);
|
|
5684
|
+
extend(normalized, props);
|
|
5685
|
+
if (keys)
|
|
5686
|
+
needCastKeys.push(...keys);
|
|
5636
5687
|
};
|
|
5637
|
-
|
|
5638
|
-
|
|
5639
|
-
|
|
5640
|
-
|
|
5641
|
-
|
|
5642
|
-
|
|
5643
|
-
|
|
5644
|
-
|
|
5645
|
-
|
|
5646
|
-
|
|
5647
|
-
|
|
5648
|
-
|
|
5649
|
-
|
|
5650
|
-
|
|
5651
|
-
|
|
5652
|
-
|
|
5653
|
-
|
|
5654
|
-
|
|
5655
|
-
|
|
5656
|
-
|
|
5657
|
-
|
|
5688
|
+
if (!asMixin && appContext.mixins.length) {
|
|
5689
|
+
appContext.mixins.forEach(extendProps);
|
|
5690
|
+
}
|
|
5691
|
+
if (comp.extends) {
|
|
5692
|
+
extendProps(comp.extends);
|
|
5693
|
+
}
|
|
5694
|
+
if (comp.mixins) {
|
|
5695
|
+
comp.mixins.forEach(extendProps);
|
|
5696
|
+
}
|
|
5697
|
+
}
|
|
5698
|
+
if (!raw && !hasExtends) {
|
|
5699
|
+
if (isObject(comp)) {
|
|
5700
|
+
cache.set(comp, EMPTY_ARR);
|
|
5701
|
+
}
|
|
5702
|
+
return EMPTY_ARR;
|
|
5703
|
+
}
|
|
5704
|
+
if (isArray(raw)) {
|
|
5705
|
+
for (let i = 0; i < raw.length; i++) {
|
|
5706
|
+
const normalizedKey = camelize(raw[i]);
|
|
5707
|
+
if (validatePropName(normalizedKey)) {
|
|
5708
|
+
normalized[normalizedKey] = EMPTY_OBJ;
|
|
5658
5709
|
}
|
|
5659
|
-
}
|
|
5660
|
-
|
|
5661
|
-
|
|
5662
|
-
|
|
5663
|
-
|
|
5664
|
-
|
|
5665
|
-
|
|
5666
|
-
|
|
5667
|
-
|
|
5668
|
-
|
|
5669
|
-
|
|
5670
|
-
|
|
5671
|
-
|
|
5672
|
-
|
|
5673
|
-
|
|
5674
|
-
if (isObject(val) && !isReactive(val) && !patched.has(val)) {
|
|
5675
|
-
const reactiveVal = reactive(val);
|
|
5676
|
-
if (isArray(val)) {
|
|
5677
|
-
methodsToPatch.forEach((m) => {
|
|
5678
|
-
val[m] = (...args) => {
|
|
5679
|
-
Array.prototype[m].call(reactiveVal, ...args);
|
|
5680
|
-
};
|
|
5681
|
-
});
|
|
5682
|
-
} else {
|
|
5683
|
-
Object.keys(val).forEach((key2) => {
|
|
5684
|
-
try {
|
|
5685
|
-
defineReactiveSimple(val, key2, val[key2]);
|
|
5686
|
-
} catch (e) {
|
|
5710
|
+
}
|
|
5711
|
+
} else if (raw) {
|
|
5712
|
+
for (const key in raw) {
|
|
5713
|
+
const normalizedKey = camelize(key);
|
|
5714
|
+
if (validatePropName(normalizedKey)) {
|
|
5715
|
+
const opt = raw[key];
|
|
5716
|
+
const prop = normalized[normalizedKey] = isArray(opt) || isFunction(opt) ? { type: opt } : extend({}, opt);
|
|
5717
|
+
if (prop) {
|
|
5718
|
+
const booleanIndex = getTypeIndex(Boolean, prop.type);
|
|
5719
|
+
const stringIndex = getTypeIndex(String, prop.type);
|
|
5720
|
+
prop[0 /* shouldCast */] = booleanIndex > -1;
|
|
5721
|
+
prop[1 /* shouldCastTrue */] = stringIndex < 0 || booleanIndex < stringIndex;
|
|
5722
|
+
if (booleanIndex > -1 || hasOwn(prop, "default")) {
|
|
5723
|
+
needCastKeys.push(normalizedKey);
|
|
5724
|
+
}
|
|
5687
5725
|
}
|
|
5688
|
-
}
|
|
5726
|
+
}
|
|
5689
5727
|
}
|
|
5690
5728
|
}
|
|
5691
|
-
const
|
|
5692
|
-
if (
|
|
5693
|
-
|
|
5694
|
-
i.accessCache = /* @__PURE__ */ Object.create(null);
|
|
5695
|
-
} else if (isReactive(obj)) {
|
|
5696
|
-
obj[key] = val;
|
|
5697
|
-
} else {
|
|
5698
|
-
defineReactiveSimple(obj, key, val);
|
|
5729
|
+
const res = [normalized, needCastKeys];
|
|
5730
|
+
if (isObject(comp)) {
|
|
5731
|
+
cache.set(comp, res);
|
|
5699
5732
|
}
|
|
5733
|
+
return res;
|
|
5700
5734
|
}
|
|
5701
|
-
function
|
|
5702
|
-
|
|
5703
|
-
|
|
5704
|
-
|
|
5705
|
-
|
|
5706
|
-
get() {
|
|
5707
|
-
track(obj, "get", key);
|
|
5708
|
-
return val;
|
|
5709
|
-
},
|
|
5710
|
-
set(newVal) {
|
|
5711
|
-
val = isObject(newVal) ? reactive(newVal) : newVal;
|
|
5712
|
-
trigger(obj, "set", key, newVal);
|
|
5713
|
-
}
|
|
5714
|
-
});
|
|
5735
|
+
function validatePropName(key) {
|
|
5736
|
+
if (key[0] !== "$") {
|
|
5737
|
+
return true;
|
|
5738
|
+
}
|
|
5739
|
+
return false;
|
|
5715
5740
|
}
|
|
5716
|
-
|
|
5717
|
-
function
|
|
5718
|
-
return
|
|
5719
|
-
app: null,
|
|
5720
|
-
config: {
|
|
5721
|
-
isNativeTag: NO,
|
|
5722
|
-
performance: false,
|
|
5723
|
-
globalProperties: {},
|
|
5724
|
-
optionMergeStrategies: {},
|
|
5725
|
-
errorHandler: void 0,
|
|
5726
|
-
warnHandler: void 0,
|
|
5727
|
-
compilerOptions: {}
|
|
5728
|
-
},
|
|
5729
|
-
mixins: [],
|
|
5730
|
-
components: {},
|
|
5731
|
-
directives: {},
|
|
5732
|
-
provides: /* @__PURE__ */ Object.create(null),
|
|
5733
|
-
optionsCache: /* @__PURE__ */ new WeakMap(),
|
|
5734
|
-
propsCache: /* @__PURE__ */ new WeakMap(),
|
|
5735
|
-
emitsCache: /* @__PURE__ */ new WeakMap()
|
|
5736
|
-
};
|
|
5741
|
+
function getType(ctor) {
|
|
5742
|
+
const match = ctor && ctor.toString().match(/^\s*(function|class) (\w+)/);
|
|
5743
|
+
return match ? match[2] : ctor === null ? "null" : "";
|
|
5737
5744
|
}
|
|
5738
|
-
|
|
5739
|
-
|
|
5740
|
-
|
|
5741
|
-
|
|
5742
|
-
|
|
5745
|
+
function isSameType(a, b) {
|
|
5746
|
+
return getType(a) === getType(b);
|
|
5747
|
+
}
|
|
5748
|
+
function getTypeIndex(type, expectedTypes) {
|
|
5749
|
+
if (isArray(expectedTypes)) {
|
|
5750
|
+
return expectedTypes.findIndex((t) => isSameType(t, type));
|
|
5751
|
+
} else if (isFunction(expectedTypes)) {
|
|
5752
|
+
return isSameType(expectedTypes, type) ? 0 : -1;
|
|
5753
|
+
}
|
|
5754
|
+
return -1;
|
|
5755
|
+
}
|
|
5756
|
+
|
|
5757
|
+
const isInternalKey = (key) => key[0] === "_" || key === "$stable";
|
|
5758
|
+
const normalizeSlotValue = (value) => isArray(value) ? value.map(normalizeVNode) : [normalizeVNode(value)];
|
|
5759
|
+
const normalizeSlot = (key, rawSlot, ctx) => {
|
|
5760
|
+
if (rawSlot._n) {
|
|
5761
|
+
return rawSlot;
|
|
5762
|
+
}
|
|
5763
|
+
const normalized = withCtx((...args) => {
|
|
5764
|
+
if (false) ;
|
|
5765
|
+
return normalizeSlotValue(rawSlot(...args));
|
|
5766
|
+
}, ctx);
|
|
5767
|
+
normalized._c = false;
|
|
5768
|
+
return normalized;
|
|
5769
|
+
};
|
|
5770
|
+
const normalizeObjectSlots = (rawSlots, slots, instance) => {
|
|
5771
|
+
const ctx = rawSlots._ctx;
|
|
5772
|
+
for (const key in rawSlots) {
|
|
5773
|
+
if (isInternalKey(key))
|
|
5774
|
+
continue;
|
|
5775
|
+
const value = rawSlots[key];
|
|
5776
|
+
if (isFunction(value)) {
|
|
5777
|
+
slots[key] = normalizeSlot(key, value, ctx);
|
|
5778
|
+
} else if (value != null) {
|
|
5779
|
+
const normalized = normalizeSlotValue(value);
|
|
5780
|
+
slots[key] = () => normalized;
|
|
5743
5781
|
}
|
|
5744
|
-
|
|
5745
|
-
|
|
5782
|
+
}
|
|
5783
|
+
};
|
|
5784
|
+
const normalizeVNodeSlots = (instance, children) => {
|
|
5785
|
+
const normalized = normalizeSlotValue(children);
|
|
5786
|
+
instance.slots.default = () => normalized;
|
|
5787
|
+
};
|
|
5788
|
+
const initSlots = (instance, children) => {
|
|
5789
|
+
if (instance.vnode.shapeFlag & 32) {
|
|
5790
|
+
const type = children._;
|
|
5791
|
+
if (type) {
|
|
5792
|
+
instance.slots = toRaw(children);
|
|
5793
|
+
def(children, "_", type);
|
|
5794
|
+
} else {
|
|
5795
|
+
normalizeObjectSlots(
|
|
5796
|
+
children,
|
|
5797
|
+
instance.slots = {});
|
|
5746
5798
|
}
|
|
5747
|
-
|
|
5748
|
-
|
|
5749
|
-
|
|
5750
|
-
|
|
5751
|
-
|
|
5752
|
-
|
|
5753
|
-
|
|
5754
|
-
|
|
5755
|
-
|
|
5756
|
-
|
|
5757
|
-
|
|
5758
|
-
|
|
5759
|
-
|
|
5760
|
-
|
|
5761
|
-
|
|
5762
|
-
|
|
5763
|
-
|
|
5764
|
-
|
|
5765
|
-
|
|
5766
|
-
|
|
5767
|
-
|
|
5768
|
-
installedPlugins.add(plugin);
|
|
5769
|
-
plugin(app, ...options);
|
|
5770
|
-
} else ;
|
|
5771
|
-
return app;
|
|
5772
|
-
},
|
|
5773
|
-
mixin(mixin) {
|
|
5774
|
-
{
|
|
5775
|
-
if (!context.mixins.includes(mixin)) {
|
|
5776
|
-
context.mixins.push(mixin);
|
|
5777
|
-
}
|
|
5778
|
-
}
|
|
5779
|
-
return app;
|
|
5780
|
-
},
|
|
5781
|
-
component(name, component) {
|
|
5782
|
-
if (!component) {
|
|
5783
|
-
return context.components[name];
|
|
5784
|
-
}
|
|
5785
|
-
context.components[name] = component;
|
|
5786
|
-
return app;
|
|
5787
|
-
},
|
|
5788
|
-
directive(name, directive) {
|
|
5789
|
-
if (!directive) {
|
|
5790
|
-
return context.directives[name];
|
|
5791
|
-
}
|
|
5792
|
-
context.directives[name] = directive;
|
|
5793
|
-
return app;
|
|
5794
|
-
},
|
|
5795
|
-
mount(rootContainer, isHydrate, isSVG) {
|
|
5796
|
-
if (!isMounted) {
|
|
5797
|
-
const vnode = createVNode(
|
|
5798
|
-
rootComponent,
|
|
5799
|
-
rootProps
|
|
5800
|
-
);
|
|
5801
|
-
vnode.appContext = context;
|
|
5802
|
-
if (isHydrate && hydrate) {
|
|
5803
|
-
hydrate(vnode, rootContainer);
|
|
5804
|
-
} else {
|
|
5805
|
-
render(vnode, rootContainer, isSVG);
|
|
5806
|
-
}
|
|
5807
|
-
isMounted = true;
|
|
5808
|
-
app._container = rootContainer;
|
|
5809
|
-
rootContainer.__vue_app__ = app;
|
|
5810
|
-
return getExposeProxy(vnode.component) || vnode.component.proxy;
|
|
5811
|
-
}
|
|
5812
|
-
},
|
|
5813
|
-
unmount() {
|
|
5814
|
-
if (isMounted) {
|
|
5815
|
-
render(null, app._container);
|
|
5816
|
-
delete app._container.__vue_app__;
|
|
5799
|
+
} else {
|
|
5800
|
+
instance.slots = {};
|
|
5801
|
+
if (children) {
|
|
5802
|
+
normalizeVNodeSlots(instance, children);
|
|
5803
|
+
}
|
|
5804
|
+
}
|
|
5805
|
+
def(instance.slots, InternalObjectKey, 1);
|
|
5806
|
+
};
|
|
5807
|
+
const updateSlots = (instance, children, optimized) => {
|
|
5808
|
+
const { vnode, slots } = instance;
|
|
5809
|
+
let needDeletionCheck = true;
|
|
5810
|
+
let deletionComparisonTarget = EMPTY_OBJ;
|
|
5811
|
+
if (vnode.shapeFlag & 32) {
|
|
5812
|
+
const type = children._;
|
|
5813
|
+
if (type) {
|
|
5814
|
+
if (optimized && type === 1) {
|
|
5815
|
+
needDeletionCheck = false;
|
|
5816
|
+
} else {
|
|
5817
|
+
extend(slots, children);
|
|
5818
|
+
if (!optimized && type === 1) {
|
|
5819
|
+
delete slots._;
|
|
5817
5820
|
}
|
|
5818
|
-
},
|
|
5819
|
-
provide(key, value) {
|
|
5820
|
-
context.provides[key] = value;
|
|
5821
|
-
return app;
|
|
5822
5821
|
}
|
|
5823
|
-
}
|
|
5824
|
-
|
|
5825
|
-
|
|
5822
|
+
} else {
|
|
5823
|
+
needDeletionCheck = !children.$stable;
|
|
5824
|
+
normalizeObjectSlots(children, slots);
|
|
5826
5825
|
}
|
|
5827
|
-
|
|
5828
|
-
}
|
|
5829
|
-
|
|
5826
|
+
deletionComparisonTarget = children;
|
|
5827
|
+
} else if (children) {
|
|
5828
|
+
normalizeVNodeSlots(instance, children);
|
|
5829
|
+
deletionComparisonTarget = { default: 1 };
|
|
5830
|
+
}
|
|
5831
|
+
if (needDeletionCheck) {
|
|
5832
|
+
for (const key in slots) {
|
|
5833
|
+
if (!isInternalKey(key) && !(key in deletionComparisonTarget)) {
|
|
5834
|
+
delete slots[key];
|
|
5835
|
+
}
|
|
5836
|
+
}
|
|
5837
|
+
}
|
|
5838
|
+
};
|
|
5830
5839
|
|
|
5831
5840
|
function setRef(rawRef, oldRawRef, parentSuspense, vnode, isUnmount = false) {
|
|
5832
5841
|
if (isArray(rawRef)) {
|
|
@@ -8552,6 +8561,9 @@ function defineExpose(exposed) {
|
|
|
8552
8561
|
function defineOptions(options) {
|
|
8553
8562
|
}
|
|
8554
8563
|
function defineSlots() {
|
|
8564
|
+
return null;
|
|
8565
|
+
}
|
|
8566
|
+
function defineModel() {
|
|
8555
8567
|
}
|
|
8556
8568
|
function withDefaults(props, defaults) {
|
|
8557
8569
|
return null;
|
|
@@ -8562,15 +8574,44 @@ function useSlots() {
|
|
|
8562
8574
|
function useAttrs() {
|
|
8563
8575
|
return getContext().attrs;
|
|
8564
8576
|
}
|
|
8577
|
+
function useModel(props, name, options) {
|
|
8578
|
+
const i = getCurrentInstance();
|
|
8579
|
+
if (options && options.local) {
|
|
8580
|
+
const proxy = ref(props[name]);
|
|
8581
|
+
watch(
|
|
8582
|
+
() => props[name],
|
|
8583
|
+
(v) => proxy.value = v
|
|
8584
|
+
);
|
|
8585
|
+
watch(proxy, (value) => {
|
|
8586
|
+
if (value !== props[name]) {
|
|
8587
|
+
i.emit(`update:${name}`, value);
|
|
8588
|
+
}
|
|
8589
|
+
});
|
|
8590
|
+
return proxy;
|
|
8591
|
+
} else {
|
|
8592
|
+
return {
|
|
8593
|
+
__v_isRef: true,
|
|
8594
|
+
get value() {
|
|
8595
|
+
return props[name];
|
|
8596
|
+
},
|
|
8597
|
+
set value(value) {
|
|
8598
|
+
i.emit(`update:${name}`, value);
|
|
8599
|
+
}
|
|
8600
|
+
};
|
|
8601
|
+
}
|
|
8602
|
+
}
|
|
8565
8603
|
function getContext() {
|
|
8566
8604
|
const i = getCurrentInstance();
|
|
8567
8605
|
return i.setupContext || (i.setupContext = createSetupContext(i));
|
|
8568
8606
|
}
|
|
8569
|
-
function
|
|
8570
|
-
|
|
8607
|
+
function normalizePropsOrEmits(props) {
|
|
8608
|
+
return isArray(props) ? props.reduce(
|
|
8571
8609
|
(normalized, p) => (normalized[p] = {}, normalized),
|
|
8572
8610
|
{}
|
|
8573
|
-
) :
|
|
8611
|
+
) : props;
|
|
8612
|
+
}
|
|
8613
|
+
function mergeDefaults(raw, defaults) {
|
|
8614
|
+
const props = normalizePropsOrEmits(raw);
|
|
8574
8615
|
for (const key in defaults) {
|
|
8575
8616
|
if (key.startsWith("__skip"))
|
|
8576
8617
|
continue;
|
|
@@ -8590,6 +8631,13 @@ function mergeDefaults(raw, defaults) {
|
|
|
8590
8631
|
}
|
|
8591
8632
|
return props;
|
|
8592
8633
|
}
|
|
8634
|
+
function mergeModels(a, b) {
|
|
8635
|
+
if (!a || !b)
|
|
8636
|
+
return a || b;
|
|
8637
|
+
if (isArray(a) && isArray(b))
|
|
8638
|
+
return a.concat(b);
|
|
8639
|
+
return extend({}, normalizePropsOrEmits(a), normalizePropsOrEmits(b));
|
|
8640
|
+
}
|
|
8593
8641
|
function createPropsRestProxy(props, excludedKeys) {
|
|
8594
8642
|
const ret = {};
|
|
8595
8643
|
for (const key in props) {
|
|
@@ -8675,7 +8723,7 @@ function isMemoSame(cached, memo) {
|
|
|
8675
8723
|
return true;
|
|
8676
8724
|
}
|
|
8677
8725
|
|
|
8678
|
-
const version = "3.3.0-alpha.
|
|
8726
|
+
const version = "3.3.0-alpha.9";
|
|
8679
8727
|
const _ssrUtils = {
|
|
8680
8728
|
createComponentInstance,
|
|
8681
8729
|
setupComponent,
|
|
@@ -10212,6 +10260,7 @@ var runtimeDom = /*#__PURE__*/Object.freeze({
|
|
|
10212
10260
|
defineCustomElement: defineCustomElement,
|
|
10213
10261
|
defineEmits: defineEmits,
|
|
10214
10262
|
defineExpose: defineExpose,
|
|
10263
|
+
defineModel: defineModel,
|
|
10215
10264
|
defineOptions: defineOptions,
|
|
10216
10265
|
defineProps: defineProps,
|
|
10217
10266
|
defineSSRCustomElement: defineSSRCustomElement,
|
|
@@ -10239,6 +10288,7 @@ var runtimeDom = /*#__PURE__*/Object.freeze({
|
|
|
10239
10288
|
isVNode: isVNode,
|
|
10240
10289
|
markRaw: markRaw,
|
|
10241
10290
|
mergeDefaults: mergeDefaults,
|
|
10291
|
+
mergeModels: mergeModels,
|
|
10242
10292
|
mergeProps: mergeProps,
|
|
10243
10293
|
nextTick: nextTick,
|
|
10244
10294
|
normalizeClass: normalizeClass,
|
|
@@ -10297,6 +10347,7 @@ var runtimeDom = /*#__PURE__*/Object.freeze({
|
|
|
10297
10347
|
useAttrs: useAttrs,
|
|
10298
10348
|
useCssModule: useCssModule,
|
|
10299
10349
|
useCssVars: useCssVars,
|
|
10350
|
+
useModel: useModel,
|
|
10300
10351
|
useSSRContext: useSSRContext,
|
|
10301
10352
|
useSlots: useSlots,
|
|
10302
10353
|
useTransitionState: useTransitionState,
|
|
@@ -15044,7 +15095,7 @@ const transformText = (node, context) => {
|
|
|
15044
15095
|
const seen$1 = /* @__PURE__ */ new WeakSet();
|
|
15045
15096
|
const transformOnce = (node, context) => {
|
|
15046
15097
|
if (node.type === 1 && findDir(node, "once", true)) {
|
|
15047
|
-
if (seen$1.has(node) || context.inVOnce) {
|
|
15098
|
+
if (seen$1.has(node) || context.inVOnce || context.inSSR) {
|
|
15048
15099
|
return;
|
|
15049
15100
|
}
|
|
15050
15101
|
seen$1.add(node);
|