@vue/compat 3.6.0-rc.11 → 3.6.0-rc.12
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-compat.d.ts +4 -1
- package/dist/vue.cjs.js +259 -83
- package/dist/vue.cjs.prod.js +291 -80
- package/dist/vue.esm-browser.js +253 -79
- package/dist/vue.esm-browser.prod.js +7 -7
- package/dist/vue.esm-bundler.js +272 -85
- package/dist/vue.global.js +253 -79
- package/dist/vue.global.prod.js +7 -7
- package/dist/vue.runtime.esm-browser.js +253 -79
- package/dist/vue.runtime.esm-browser.prod.js +7 -7
- package/dist/vue.runtime.esm-bundler.js +272 -85
- package/dist/vue.runtime.global.js +253 -79
- package/dist/vue.runtime.global.prod.js +7 -7
- package/package.json +4 -4
package/dist/vue.global.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @vue/compat v3.6.0-rc.
|
|
2
|
+
* @vue/compat v3.6.0-rc.12
|
|
3
3
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
4
4
|
* @license MIT
|
|
5
5
|
**/
|
|
@@ -312,9 +312,10 @@ var Vue = (function() {
|
|
|
312
312
|
* - ismap -> isMap
|
|
313
313
|
* - nomodule -> noModule
|
|
314
314
|
* - novalidate -> noValidate
|
|
315
|
+
* - playsinline -> playsInline
|
|
315
316
|
* - readonly -> readOnly
|
|
316
317
|
*/
|
|
317
|
-
const specialBooleanAttrs = `itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly`;
|
|
318
|
+
const specialBooleanAttrs = `itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,playsinline,readonly`;
|
|
318
319
|
const isSpecialBooleanAttr = /*@__PURE__*/ makeMap(specialBooleanAttrs);
|
|
319
320
|
/**
|
|
320
321
|
* The full list is needed during SSR to produce the correct initial markup.
|
|
@@ -1005,17 +1006,33 @@ var Vue = (function() {
|
|
|
1005
1006
|
};
|
|
1006
1007
|
function iterator(self, method, wrapValue) {
|
|
1007
1008
|
const arr = shallowReadArray(self);
|
|
1008
|
-
const
|
|
1009
|
+
const methodFn = arr[method];
|
|
1010
|
+
const iter = methodFn.call(arr);
|
|
1009
1011
|
if (arr !== self && !/* @__PURE__ */ isShallow(self)) {
|
|
1012
|
+
if (iter[Symbol.toStringTag] === "Array Iterator") {
|
|
1013
|
+
const wrapped = Object.create(Object.getPrototypeOf(iter));
|
|
1014
|
+
wrapped.next = () => wrapResult(iter.next(), wrapValue);
|
|
1015
|
+
if (methodFn !== arrayProto[method]) Object.defineProperties(wrapped, {
|
|
1016
|
+
return: { get() {
|
|
1017
|
+
const fn = iter.return;
|
|
1018
|
+
return typeof fn === "function" ? fn.bind(iter) : fn;
|
|
1019
|
+
} },
|
|
1020
|
+
throw: { get() {
|
|
1021
|
+
const fn = iter.throw;
|
|
1022
|
+
return typeof fn === "function" ? fn.bind(iter) : fn;
|
|
1023
|
+
} }
|
|
1024
|
+
});
|
|
1025
|
+
return wrapped;
|
|
1026
|
+
}
|
|
1010
1027
|
iter._next = iter.next;
|
|
1011
|
-
iter.next = () =>
|
|
1012
|
-
const result = iter._next();
|
|
1013
|
-
if (!result.done) result.value = wrapValue(result.value);
|
|
1014
|
-
return result;
|
|
1015
|
-
};
|
|
1028
|
+
iter.next = () => wrapResult(iter._next(), wrapValue);
|
|
1016
1029
|
}
|
|
1017
1030
|
return iter;
|
|
1018
1031
|
}
|
|
1032
|
+
function wrapResult(result, wrapValue) {
|
|
1033
|
+
if (!result.done) result.value = wrapValue(result.value);
|
|
1034
|
+
return result;
|
|
1035
|
+
}
|
|
1019
1036
|
const arrayProto = Array.prototype;
|
|
1020
1037
|
function apply(self, method, fn, thisArg, wrappedRetFn, args) {
|
|
1021
1038
|
const arr = shallowReadArray(self);
|
|
@@ -1333,6 +1350,7 @@ var Vue = (function() {
|
|
|
1333
1350
|
return (target, key, receiver) => {
|
|
1334
1351
|
if (key === "__v_isReactive") return !isReadonly;
|
|
1335
1352
|
else if (key === "__v_isReadonly") return isReadonly;
|
|
1353
|
+
else if (key === "__v_isShallow") return shallow;
|
|
1336
1354
|
else if (key === "__v_raw") return target;
|
|
1337
1355
|
return Reflect.get(hasOwn(instrumentations, key) && key in target ? instrumentations : target, key, receiver);
|
|
1338
1356
|
};
|
|
@@ -2242,8 +2260,9 @@ var Vue = (function() {
|
|
|
2242
2260
|
function onWatcherCleanup(cleanupFn, failSilently = false, owner = activeWatcher) {
|
|
2243
2261
|
if (owner) {
|
|
2244
2262
|
const { call } = owner.options;
|
|
2245
|
-
|
|
2246
|
-
|
|
2263
|
+
const cleanup = call ? () => call(cleanupFn, 4) : cleanupFn;
|
|
2264
|
+
if (owner.cb) (owner.cbCleanups || (owner.cbCleanups = [])).push(cleanup);
|
|
2265
|
+
else owner.cleanups[owner.cleanupsLength++] = cleanup;
|
|
2247
2266
|
} else if (!failSilently) warn$2("onWatcherCleanup() was called when there was no active watcher to associate with.");
|
|
2248
2267
|
}
|
|
2249
2268
|
var WatcherEffect = class extends ReactiveEffect {
|
|
@@ -2304,9 +2323,11 @@ var Vue = (function() {
|
|
|
2304
2323
|
if (once && cb) {
|
|
2305
2324
|
const _cb = cb;
|
|
2306
2325
|
cb = (...args) => {
|
|
2307
|
-
|
|
2308
|
-
|
|
2309
|
-
|
|
2326
|
+
try {
|
|
2327
|
+
return _cb(...args);
|
|
2328
|
+
} finally {
|
|
2329
|
+
this.stop();
|
|
2330
|
+
}
|
|
2310
2331
|
};
|
|
2311
2332
|
}
|
|
2312
2333
|
this.cb = cb;
|
|
@@ -2314,6 +2335,19 @@ var Vue = (function() {
|
|
|
2314
2335
|
this.onTrack = options.onTrack;
|
|
2315
2336
|
this.onTrigger = options.onTrigger;
|
|
2316
2337
|
}
|
|
2338
|
+
cleanupCallback() {
|
|
2339
|
+
const cleanups = this.cbCleanups;
|
|
2340
|
+
if (cleanups) {
|
|
2341
|
+
this.cbCleanups = void 0;
|
|
2342
|
+
for (let i = 0, l = cleanups.length; i < l; i++) cleanups[i]();
|
|
2343
|
+
}
|
|
2344
|
+
}
|
|
2345
|
+
stop() {
|
|
2346
|
+
if (this.active) {
|
|
2347
|
+
super.stop();
|
|
2348
|
+
this.cleanupCallback();
|
|
2349
|
+
}
|
|
2350
|
+
}
|
|
2317
2351
|
run(initialRun = false) {
|
|
2318
2352
|
const oldValue = this.oldValue;
|
|
2319
2353
|
const newValue = this.oldValue = super.run();
|
|
@@ -2321,10 +2355,11 @@ var Vue = (function() {
|
|
|
2321
2355
|
const { immediate, deep, call } = this.options;
|
|
2322
2356
|
if (initialRun && !immediate) return;
|
|
2323
2357
|
if (initialRun || deep || this.forceTrigger || (this.isMultiSource ? newValue.some((v, i) => hasChanged(v, oldValue[i])) : hasChanged(newValue, oldValue))) {
|
|
2324
|
-
cleanup(this);
|
|
2325
2358
|
const currentWatcher = activeWatcher;
|
|
2326
|
-
|
|
2359
|
+
const prevSub = setActiveSub();
|
|
2327
2360
|
try {
|
|
2361
|
+
this.cleanupCallback();
|
|
2362
|
+
activeWatcher = this;
|
|
2328
2363
|
const args = [
|
|
2329
2364
|
newValue,
|
|
2330
2365
|
oldValue === INITIAL_WATCHER_VALUE ? void 0 : this.isMultiSource && oldValue[0] === INITIAL_WATCHER_VALUE ? [] : oldValue,
|
|
@@ -2333,6 +2368,7 @@ var Vue = (function() {
|
|
|
2333
2368
|
call ? call(this.cb, 3, args) : this.cb(...args);
|
|
2334
2369
|
} finally {
|
|
2335
2370
|
activeWatcher = currentWatcher;
|
|
2371
|
+
setActiveSub(prevSub);
|
|
2336
2372
|
}
|
|
2337
2373
|
}
|
|
2338
2374
|
}
|
|
@@ -2663,15 +2699,15 @@ var Vue = (function() {
|
|
|
2663
2699
|
} else for (let i = 0; i < jobs.length; i++) queueJobWorker(jobs[i], id, postJobs, postJobs.length, 0);
|
|
2664
2700
|
queueFlush();
|
|
2665
2701
|
}
|
|
2666
|
-
function flushPreFlushCbs(instance, seen) {
|
|
2702
|
+
function flushPreFlushCbs(instance, minUid, seen) {
|
|
2667
2703
|
seen = seen || /* @__PURE__ */ new Map();
|
|
2668
2704
|
for (let i = flushIndex; i < jobsLength; i++) {
|
|
2669
2705
|
const cb = jobs[i];
|
|
2670
2706
|
if (cb.order & 1 || cb.order === Infinity) continue;
|
|
2671
|
-
if (instance && cb.order !== instance.uid * 2) continue;
|
|
2707
|
+
if (instance && cb.order !== instance.uid * 2 || minUid !== void 0 && !(cb.order >= minUid * 2)) continue;
|
|
2672
2708
|
if (checkRecursiveUpdates(seen, cb)) continue;
|
|
2673
2709
|
jobs.splice(i, 1);
|
|
2674
|
-
i
|
|
2710
|
+
i = instance ? i - 1 : flushIndex - 1;
|
|
2675
2711
|
jobsLength--;
|
|
2676
2712
|
if (cb.flags & 2) cb.flags &= -2;
|
|
2677
2713
|
try {
|
|
@@ -2681,15 +2717,24 @@ var Vue = (function() {
|
|
|
2681
2717
|
}
|
|
2682
2718
|
}
|
|
2683
2719
|
}
|
|
2684
|
-
function flushPostFlushCbs(seen) {
|
|
2720
|
+
function flushPostFlushCbs(seen, skip, minUid = 0) {
|
|
2685
2721
|
if (postJobs.length) {
|
|
2722
|
+
let cbs = postJobs;
|
|
2723
|
+
if (skip) {
|
|
2724
|
+
cbs = [];
|
|
2725
|
+
let kept = 0;
|
|
2726
|
+
for (let i = 0; i < postJobs.length; i++) {
|
|
2727
|
+
const cb = postJobs[i];
|
|
2728
|
+
if (cb.i !== void 0 ? !cb.i || cb.i.uid < minUid : skip.has(cb)) postJobs[kept++] = cb;
|
|
2729
|
+
else cbs.push(cb);
|
|
2730
|
+
}
|
|
2731
|
+
postJobs.length = kept;
|
|
2732
|
+
} else postJobs = [];
|
|
2686
2733
|
if (activePostJobs) {
|
|
2687
|
-
for (let i = 0; i <
|
|
2688
|
-
postJobs.length = 0;
|
|
2734
|
+
for (let i = 0; i < cbs.length; i++) activePostJobs.push(cbs[i]);
|
|
2689
2735
|
return;
|
|
2690
2736
|
}
|
|
2691
|
-
activePostJobs =
|
|
2692
|
-
postJobs = [];
|
|
2737
|
+
activePostJobs = cbs;
|
|
2693
2738
|
seen = seen || /* @__PURE__ */ new Map();
|
|
2694
2739
|
try {
|
|
2695
2740
|
while (postFlushIndex < activePostJobs.length) {
|
|
@@ -2711,17 +2756,28 @@ var Vue = (function() {
|
|
|
2711
2756
|
}
|
|
2712
2757
|
let isFlushing = false;
|
|
2713
2758
|
/**
|
|
2759
|
+
* Run a root render, then flush the jobs it is responsible for. A mount or
|
|
2760
|
+
* unmount (`minUid` given) only flushes the jobs of the components it created
|
|
2761
|
+
* and the post cbs it queued, so pre watchers triggered in setup run before
|
|
2762
|
+
* mounted (#5721) while the jobs of other components stay in the queue and
|
|
2763
|
+
* keep their order (#6728). A root update keeps flushing all pending pre jobs
|
|
2764
|
+
* and post cbs, as the jobs of the components it re-renders may predate it.
|
|
2765
|
+
*
|
|
2714
2766
|
* @internal
|
|
2715
2767
|
*/
|
|
2716
|
-
function flushOnAppMount(
|
|
2717
|
-
if (
|
|
2718
|
-
|
|
2719
|
-
|
|
2720
|
-
|
|
2721
|
-
|
|
2722
|
-
|
|
2723
|
-
|
|
2724
|
-
|
|
2768
|
+
function flushOnAppMount(fn, minUid) {
|
|
2769
|
+
if (isFlushing) {
|
|
2770
|
+
fn();
|
|
2771
|
+
return;
|
|
2772
|
+
}
|
|
2773
|
+
const queued = minUid === void 0 ? void 0 : new Set(postJobs);
|
|
2774
|
+
fn();
|
|
2775
|
+
isFlushing = true;
|
|
2776
|
+
try {
|
|
2777
|
+
flushPreFlushCbs(void 0, minUid);
|
|
2778
|
+
flushPostFlushCbs(void 0, queued, minUid);
|
|
2779
|
+
} finally {
|
|
2780
|
+
isFlushing = false;
|
|
2725
2781
|
}
|
|
2726
2782
|
}
|
|
2727
2783
|
function flushJobs(seen) {
|
|
@@ -3538,7 +3594,7 @@ var Vue = (function() {
|
|
|
3538
3594
|
this.flags |= 128;
|
|
3539
3595
|
job.flags |= 2;
|
|
3540
3596
|
}
|
|
3541
|
-
|
|
3597
|
+
job.i = instance;
|
|
3542
3598
|
this.job = job;
|
|
3543
3599
|
}
|
|
3544
3600
|
notify() {
|
|
@@ -3731,7 +3787,11 @@ var Vue = (function() {
|
|
|
3731
3787
|
hydrate: hydrateTeleport
|
|
3732
3788
|
};
|
|
3733
3789
|
function moveTeleport(vnode, container, parentAnchor, { o: { insert }, m: move }, parentComponent, moveType = 2) {
|
|
3734
|
-
if (moveType === 0)
|
|
3790
|
+
if (moveType === 0) {
|
|
3791
|
+
if (vnode.targetStart) insert(vnode.targetStart, container, parentAnchor);
|
|
3792
|
+
insert(vnode.targetAnchor, container, parentAnchor);
|
|
3793
|
+
parentAnchor = vnode.targetAnchor;
|
|
3794
|
+
}
|
|
3735
3795
|
const { el, anchor, shapeFlag, children, props } = vnode;
|
|
3736
3796
|
const isReorder = moveType === 2;
|
|
3737
3797
|
if (isReorder) insert(el, container, parentAnchor);
|
|
@@ -3852,6 +3912,10 @@ var Vue = (function() {
|
|
|
3852
3912
|
};
|
|
3853
3913
|
function isEmptyTransitionChild(vnode, instance) {
|
|
3854
3914
|
if (vnode.type === Comment) return true;
|
|
3915
|
+
if (vnode.type === Fragment) {
|
|
3916
|
+
const child = isArray(vnode.children) && filterSingleRoot(vnode.children, false);
|
|
3917
|
+
return !child || isEmptyTransitionChild(child, instance);
|
|
3918
|
+
}
|
|
3855
3919
|
if (vnode.type === VaporSlot || isVaporComponent(vnode.type)) return !getVaporInterface(instance, vnode).hasTransitionChild(vnode);
|
|
3856
3920
|
return !!vnode.component && isEmptyTransitionChild(vnode.component.subTree, instance);
|
|
3857
3921
|
}
|
|
@@ -3913,7 +3977,14 @@ var Vue = (function() {
|
|
|
3913
3977
|
},
|
|
3914
3978
|
earlyRemove: () => {
|
|
3915
3979
|
const leavingVNode = leavingVNodesCache[key];
|
|
3916
|
-
if (leavingVNode && isSameVNodeType(vnode, leavingVNode)
|
|
3980
|
+
if (leavingVNode && isSameVNodeType(vnode, leavingVNode)) {
|
|
3981
|
+
let leavingCb = leavingVNode.el[leaveCbKey];
|
|
3982
|
+
if (!leavingCb) {
|
|
3983
|
+
const leavingRoot = getTransitionRoot(leavingVNode);
|
|
3984
|
+
leavingCb = leavingRoot && leavingRoot.el[leaveCbKey];
|
|
3985
|
+
}
|
|
3986
|
+
if (leavingCb) leavingCb();
|
|
3987
|
+
}
|
|
3917
3988
|
},
|
|
3918
3989
|
cloneHooks: (vnode) => {
|
|
3919
3990
|
const hooks = resolveTransitionHooks(vnode, props, state, instance, postClone);
|
|
@@ -4107,7 +4178,13 @@ var Vue = (function() {
|
|
|
4107
4178
|
const contentHooks = vnode.ssContent.transition = hooks.clone(vnode.ssContent);
|
|
4108
4179
|
const fallbackHooks = vnode.ssFallback.transition = hooks.clone(vnode.ssFallback);
|
|
4109
4180
|
return vnode.suspense && vnode.suspense.activeBranch === vnode.ssFallback ? fallbackHooks : contentHooks;
|
|
4110
|
-
} else
|
|
4181
|
+
} else {
|
|
4182
|
+
vnode.transition = hooks;
|
|
4183
|
+
if (vnode.type === Fragment && isArray(vnode.children)) {
|
|
4184
|
+
const child = filterSingleRoot(vnode.children, false);
|
|
4185
|
+
if (child) setTransitionHooks(child, hooks);
|
|
4186
|
+
}
|
|
4187
|
+
}
|
|
4111
4188
|
return hooks;
|
|
4112
4189
|
}
|
|
4113
4190
|
function getTransitionRawChildren(children, keepComment = false, parentKey) {
|
|
@@ -4130,6 +4207,14 @@ var Vue = (function() {
|
|
|
4130
4207
|
function checkTransitionMode(mode) {
|
|
4131
4208
|
if (mode && mode !== "in-out" && mode !== "out-in" && mode !== "default") warn$1(`invalid <transition> mode: ${mode}`);
|
|
4132
4209
|
}
|
|
4210
|
+
function getTransitionRoot(vnode) {
|
|
4211
|
+
if (vnode.component && !isVaporComponent(vnode.type)) return getTransitionRoot(vnode.component.subTree);
|
|
4212
|
+
if (vnode.type === Fragment) {
|
|
4213
|
+
const child = isArray(vnode.children) && filterSingleRoot(vnode.children, false);
|
|
4214
|
+
return child ? getTransitionRoot(child) : void 0;
|
|
4215
|
+
}
|
|
4216
|
+
if (vnode.type !== Comment) return vnode;
|
|
4217
|
+
}
|
|
4133
4218
|
//#endregion
|
|
4134
4219
|
//#region packages/runtime-core/src/apiDefineComponent.ts
|
|
4135
4220
|
/*@__NO_SIDE_EFFECTS__*/
|
|
@@ -4759,14 +4844,20 @@ var Vue = (function() {
|
|
|
4759
4844
|
break;
|
|
4760
4845
|
}
|
|
4761
4846
|
}, opts);
|
|
4762
|
-
|
|
4763
|
-
if (!(el instanceof Element)) return;
|
|
4847
|
+
const observe = (el) => {
|
|
4764
4848
|
if (elementIsVisibleInViewport(el)) {
|
|
4765
4849
|
hydrate();
|
|
4766
4850
|
ob.disconnect();
|
|
4767
4851
|
return false;
|
|
4768
4852
|
}
|
|
4853
|
+
if (getComputedStyle(el).display === "contents") {
|
|
4854
|
+
for (let i = 0; i < el.children.length; i++) if (observe(el.children[i]) === false) return false;
|
|
4855
|
+
}
|
|
4769
4856
|
ob.observe(el);
|
|
4857
|
+
};
|
|
4858
|
+
forEach((el) => {
|
|
4859
|
+
if (!(el instanceof Element)) return;
|
|
4860
|
+
return observe(el);
|
|
4770
4861
|
});
|
|
4771
4862
|
return () => ob.disconnect();
|
|
4772
4863
|
};
|
|
@@ -5024,7 +5115,10 @@ var Vue = (function() {
|
|
|
5024
5115
|
function pruneCacheEntry(key) {
|
|
5025
5116
|
const cached = cache.get(key);
|
|
5026
5117
|
if (cached && (!current || !isSameVNodeType(cached, current))) unmount(cached);
|
|
5027
|
-
else if (current)
|
|
5118
|
+
else if (current) {
|
|
5119
|
+
resetShapeFlag(current);
|
|
5120
|
+
if (cached) resetShapeFlag(cached);
|
|
5121
|
+
}
|
|
5028
5122
|
cache.delete(key);
|
|
5029
5123
|
keys.delete(key);
|
|
5030
5124
|
}
|
|
@@ -5570,6 +5664,11 @@ var Vue = (function() {
|
|
|
5570
5664
|
owner: currentRenderingInstance
|
|
5571
5665
|
}] : void 0
|
|
5572
5666
|
};
|
|
5667
|
+
if (branchKey != null && props.key == null) {
|
|
5668
|
+
ret.vs.props = ret.props;
|
|
5669
|
+
ret.props = extend({}, ret.props, { key: branchKey });
|
|
5670
|
+
ret.key = branchKey;
|
|
5671
|
+
}
|
|
5573
5672
|
if (!noSlotted && ret.scopeId) ret.slotScopeIds = [ret.scopeId + "-s"];
|
|
5574
5673
|
return ret;
|
|
5575
5674
|
}
|
|
@@ -5773,6 +5872,7 @@ var Vue = (function() {
|
|
|
5773
5872
|
const privateAPIs = {
|
|
5774
5873
|
$vnode: (i) => i.vnode,
|
|
5775
5874
|
_self: (i) => i.proxy,
|
|
5875
|
+
_setupProxy: (i) => i.setupState,
|
|
5776
5876
|
_uid: (i) => i.uid,
|
|
5777
5877
|
_data: (i) => i.data,
|
|
5778
5878
|
_isMounted: (i) => i.isMounted,
|
|
@@ -6548,7 +6648,7 @@ var Vue = (function() {
|
|
|
6548
6648
|
if (options.el) return vm.$mount(options.el);
|
|
6549
6649
|
else return vm;
|
|
6550
6650
|
}
|
|
6551
|
-
Vue.version = `2.6.14-compat:3.6.0-rc.
|
|
6651
|
+
Vue.version = `2.6.14-compat:3.6.0-rc.12`;
|
|
6552
6652
|
Vue.config = singletonApp.config;
|
|
6553
6653
|
Vue.use = (plugin, ...options) => {
|
|
6554
6654
|
if (plugin && isFunction(plugin.install)) plugin.install(Vue, ...options);
|
|
@@ -7366,7 +7466,7 @@ var Vue = (function() {
|
|
|
7366
7466
|
if (nextKeys.length !== Object.keys(prevProps).length) return true;
|
|
7367
7467
|
for (let i = 0; i < nextKeys.length; i++) {
|
|
7368
7468
|
const key = nextKeys[i];
|
|
7369
|
-
if (hasPropValueChanged(nextProps, prevProps, key) && !isEmitListener(emitsOptions, key)) return true;
|
|
7469
|
+
if (!hasOwn(prevProps, key) || hasPropValueChanged(nextProps, prevProps, key) && !isEmitListener(emitsOptions, key)) return true;
|
|
7370
7470
|
}
|
|
7371
7471
|
return false;
|
|
7372
7472
|
}
|
|
@@ -8090,7 +8190,8 @@ var Vue = (function() {
|
|
|
8090
8190
|
for (let i = 0; i < newChildren.length; i++) {
|
|
8091
8191
|
const oldVNode = oldChildren[i];
|
|
8092
8192
|
const newVNode = newChildren[i];
|
|
8093
|
-
const
|
|
8193
|
+
const oldEl = oldVNode.el || resolveAsyncComponentPlaceholder(oldVNode);
|
|
8194
|
+
const container = oldEl && (oldVNode.type === Fragment || !isSameVNodeType(oldVNode, newVNode) || oldVNode.shapeFlag & 198) ? hostParentNode(oldEl) : fallbackContainer;
|
|
8094
8195
|
patch(oldVNode, newVNode, container, null, parentComponent, parentSuspense, namespace, slotScopeIds, true);
|
|
8095
8196
|
}
|
|
8096
8197
|
};
|
|
@@ -8185,6 +8286,7 @@ var Vue = (function() {
|
|
|
8185
8286
|
if (instance.asyncDep && !instance.asyncResolved) {
|
|
8186
8287
|
pushWarningContext(n2);
|
|
8187
8288
|
n2.el = n1.el;
|
|
8289
|
+
n2.placeholder = n1.placeholder;
|
|
8188
8290
|
updateComponentPreRender(instance, n2, optimized);
|
|
8189
8291
|
popWarningContext();
|
|
8190
8292
|
return;
|
|
@@ -8194,6 +8296,7 @@ var Vue = (function() {
|
|
|
8194
8296
|
}
|
|
8195
8297
|
} else {
|
|
8196
8298
|
n2.el = n1.el;
|
|
8299
|
+
n2.placeholder = n1.placeholder;
|
|
8197
8300
|
instance.vnode = n2;
|
|
8198
8301
|
}
|
|
8199
8302
|
};
|
|
@@ -8545,12 +8648,9 @@ var Vue = (function() {
|
|
|
8545
8648
|
};
|
|
8546
8649
|
const remove = (vnode) => {
|
|
8547
8650
|
const { type, el, anchor, transition } = vnode;
|
|
8548
|
-
|
|
8549
|
-
|
|
8550
|
-
|
|
8551
|
-
else remove(child);
|
|
8552
|
-
});
|
|
8553
|
-
else removeFragment(el, anchor);
|
|
8651
|
+
const isFragment = type === Fragment;
|
|
8652
|
+
if (isFragment && !transition) {
|
|
8653
|
+
removeFragment(el, anchor);
|
|
8554
8654
|
return;
|
|
8555
8655
|
}
|
|
8556
8656
|
if (type === Static) {
|
|
@@ -8558,8 +8658,21 @@ var Vue = (function() {
|
|
|
8558
8658
|
if (transition && !transition.persisted && transition.afterLeave) transition.afterLeave();
|
|
8559
8659
|
return;
|
|
8560
8660
|
}
|
|
8561
|
-
|
|
8562
|
-
|
|
8661
|
+
const leavingNode = isFragment ? getTransitionRoot(vnode) : vnode;
|
|
8662
|
+
const performRemove = () => {
|
|
8663
|
+
if (isFragment) {
|
|
8664
|
+
if (hostParentNode(el)) removeFragment(el, anchor);
|
|
8665
|
+
} else hostRemove(el);
|
|
8666
|
+
};
|
|
8667
|
+
if (transition) {
|
|
8668
|
+
let leavingEl = leavingNode && leavingNode.el;
|
|
8669
|
+
let isElement = !!(leavingNode && leavingNode.shapeFlag & 1);
|
|
8670
|
+
if (isFragment && leavingNode && isVaporComponent(leavingNode.type)) {
|
|
8671
|
+
leavingEl = getVaporInterface(leavingNode.component, leavingNode).getTransitionElement(leavingNode);
|
|
8672
|
+
isElement = !!leavingEl;
|
|
8673
|
+
}
|
|
8674
|
+
performTransitionLeave(leavingEl || el, transition, performRemove, isElement);
|
|
8675
|
+
} else performRemove();
|
|
8563
8676
|
};
|
|
8564
8677
|
const removeFragment = (cur, end) => {
|
|
8565
8678
|
let next;
|
|
@@ -8604,15 +8717,12 @@ var Vue = (function() {
|
|
|
8604
8717
|
return teleportEnd ? hostNextSibling(teleportEnd) : el;
|
|
8605
8718
|
};
|
|
8606
8719
|
const render = (vnode, container, namespace) => {
|
|
8607
|
-
|
|
8608
|
-
|
|
8609
|
-
|
|
8610
|
-
|
|
8611
|
-
|
|
8612
|
-
|
|
8613
|
-
} else patch(container._vnode || null, vnode, container, null, null, null, namespace);
|
|
8614
|
-
container._vnode = vnode;
|
|
8615
|
-
flushOnAppMount(instance);
|
|
8720
|
+
flushOnAppMount(() => {
|
|
8721
|
+
if (vnode == null) {
|
|
8722
|
+
if (container._vnode) unmount(container._vnode, null, null, true);
|
|
8723
|
+
} else patch(container._vnode || null, vnode, container, null, null, null, namespace);
|
|
8724
|
+
container._vnode = vnode;
|
|
8725
|
+
}, vnode && container._vnode ? void 0 : vnode && vnode.component ? vnode.component.uid : getNextUid());
|
|
8616
8726
|
};
|
|
8617
8727
|
const internals = {
|
|
8618
8728
|
p: patch,
|
|
@@ -9005,13 +9115,12 @@ var Vue = (function() {
|
|
|
9005
9115
|
registerDep(instance, onResolve) {
|
|
9006
9116
|
const isInPendingSuspense = !!suspense.pendingBranch;
|
|
9007
9117
|
if (isInPendingSuspense) suspense.deps++;
|
|
9008
|
-
const hydratedEl = instance.vnode && instance.vnode.el;
|
|
9009
9118
|
instance.asyncDep.catch((err) => {
|
|
9010
9119
|
handleError(err, instance, 0);
|
|
9011
9120
|
}).then((asyncSetupResult) => {
|
|
9012
9121
|
if (instance.isUnmounted || suspense.isUnmounted || suspense.pendingId !== instance.suspenseId) return;
|
|
9013
9122
|
setCurrentInstance(null, void 0);
|
|
9014
|
-
if (
|
|
9123
|
+
if (!instance.scope.active) {
|
|
9015
9124
|
if (isInPendingSuspense && --suspense.deps === 0) suspense.resolve();
|
|
9016
9125
|
return;
|
|
9017
9126
|
}
|
|
@@ -9367,7 +9476,7 @@ var Vue = (function() {
|
|
|
9367
9476
|
ctx: vnode.ctx,
|
|
9368
9477
|
ce: vnode.ce,
|
|
9369
9478
|
vi: vnode.vi,
|
|
9370
|
-
vs: cloneVaporSlotMeta(vnode),
|
|
9479
|
+
vs: cloneVaporSlotMeta(vnode, extraProps),
|
|
9371
9480
|
vb: vnode.vb,
|
|
9372
9481
|
ibu: vnode.ibu,
|
|
9373
9482
|
iu: vnode.iu,
|
|
@@ -9377,13 +9486,22 @@ var Vue = (function() {
|
|
|
9377
9486
|
defineLegacyVNodeProperties(cloned);
|
|
9378
9487
|
return cloned;
|
|
9379
9488
|
}
|
|
9380
|
-
function cloneVaporSlotMeta(vnode) {
|
|
9489
|
+
function cloneVaporSlotMeta(vnode, extraProps) {
|
|
9381
9490
|
const vaporSlot = vnode.vs;
|
|
9382
9491
|
if (!vaporSlot) return vaporSlot;
|
|
9383
9492
|
const cloned = {
|
|
9384
9493
|
slot: vaporSlot.slot,
|
|
9385
|
-
outlets: vaporSlot.outlets
|
|
9494
|
+
outlets: vaporSlot.outlets,
|
|
9495
|
+
props: vaporSlot.props
|
|
9386
9496
|
};
|
|
9497
|
+
if (vaporSlot.props && extraProps) {
|
|
9498
|
+
let extraSlotProps;
|
|
9499
|
+
for (const key in extraProps) if (key !== "key") {
|
|
9500
|
+
if (!extraSlotProps) extraSlotProps = {};
|
|
9501
|
+
extraSlotProps[key] = extraProps[key];
|
|
9502
|
+
}
|
|
9503
|
+
if (extraSlotProps) cloned.props = mergeProps(vaporSlot.props, extraSlotProps);
|
|
9504
|
+
}
|
|
9387
9505
|
if (vnode.el) {
|
|
9388
9506
|
cloned.state = vaporSlot.state;
|
|
9389
9507
|
cloned.ref = vaporSlot.ref;
|
|
@@ -9566,6 +9684,9 @@ var Vue = (function() {
|
|
|
9566
9684
|
//#region packages/runtime-core/src/component.ts
|
|
9567
9685
|
const emptyAppContext = /*@__PURE__*/ createAppContext();
|
|
9568
9686
|
let uid = 0;
|
|
9687
|
+
function getNextUid() {
|
|
9688
|
+
return uid;
|
|
9689
|
+
}
|
|
9569
9690
|
function createComponentInstance(vnode, parent, suspense) {
|
|
9570
9691
|
const type = vnode.type;
|
|
9571
9692
|
const appContext = (parent ? parent.appContext : vnode.appContext) || emptyAppContext;
|
|
@@ -10074,7 +10195,7 @@ var Vue = (function() {
|
|
|
10074
10195
|
}
|
|
10075
10196
|
//#endregion
|
|
10076
10197
|
//#region packages/runtime-core/src/index.ts
|
|
10077
|
-
const version = "3.6.0-rc.
|
|
10198
|
+
const version = "3.6.0-rc.12";
|
|
10078
10199
|
const warn = warn$1;
|
|
10079
10200
|
/**
|
|
10080
10201
|
* Runtime error messages. Only exposed in dev or esm builds.
|
|
@@ -10577,7 +10698,7 @@ var Vue = (function() {
|
|
|
10577
10698
|
else el.removeAttribute("style");
|
|
10578
10699
|
}
|
|
10579
10700
|
if (vShowOriginalDisplay in el) {
|
|
10580
|
-
el[vShowOriginalDisplay] = hasControlledDisplay ? style.display : "";
|
|
10701
|
+
if (!isCssString || prev !== next) el[vShowOriginalDisplay] = hasControlledDisplay ? style.display : "";
|
|
10581
10702
|
if (el[vShowHidden]) style.display = "none";
|
|
10582
10703
|
}
|
|
10583
10704
|
}
|
|
@@ -10907,7 +11028,7 @@ var Vue = (function() {
|
|
|
10907
11028
|
this._resolveProps(def);
|
|
10908
11029
|
if (this.shadowRoot) this._applyStyles(styles);
|
|
10909
11030
|
else if (styles) warn("Custom element style injection is not supported when using shadowRoot: false");
|
|
10910
|
-
this._mountComponent(def);
|
|
11031
|
+
if (this._connected) this._mountComponent(def);
|
|
10911
11032
|
};
|
|
10912
11033
|
const asyncDef = this._def.__asyncLoader;
|
|
10913
11034
|
if (asyncDef) {
|
|
@@ -11209,6 +11330,7 @@ var Vue = (function() {
|
|
|
11209
11330
|
const newPositionMap = /* @__PURE__ */ new WeakMap();
|
|
11210
11331
|
const moveCbKey = Symbol("_moveCb");
|
|
11211
11332
|
const enterCbKey = Symbol("_enterCb");
|
|
11333
|
+
const pendingGroups = /* @__PURE__ */ new WeakMap();
|
|
11212
11334
|
/**
|
|
11213
11335
|
* Wrap logic that modifies TransitionGroup properties in a function
|
|
11214
11336
|
* so that it can be annotated as pure
|
|
@@ -11229,15 +11351,24 @@ var Vue = (function() {
|
|
|
11229
11351
|
const state = useTransitionState();
|
|
11230
11352
|
let prevChildren;
|
|
11231
11353
|
let children;
|
|
11354
|
+
let origins;
|
|
11355
|
+
let moves;
|
|
11356
|
+
const willMove = () => {
|
|
11357
|
+
if (moves === void 0) moves = prevChildren.length > 0 && hasCSSTransform(prevChildren[0].el, instance.vnode.el, resolveMoveClass(props));
|
|
11358
|
+
return moves;
|
|
11359
|
+
};
|
|
11232
11360
|
onUpdated(() => {
|
|
11233
|
-
|
|
11234
|
-
|
|
11235
|
-
if (!hasCSSTransform(prevChildren[0].el, instance.vnode.el, moveClass)) {
|
|
11361
|
+
pendingGroups.delete(instance);
|
|
11362
|
+
if (!willMove()) {
|
|
11236
11363
|
prevChildren = [];
|
|
11364
|
+
origins = void 0;
|
|
11237
11365
|
return;
|
|
11238
11366
|
}
|
|
11367
|
+
const moveClass = resolveMoveClass(props);
|
|
11239
11368
|
prevChildren.forEach((vnode) => callPendingCbs(vnode.el));
|
|
11240
|
-
|
|
11369
|
+
const shift = origins && getOriginShift(origins, instance.vnode.el);
|
|
11370
|
+
origins = void 0;
|
|
11371
|
+
prevChildren.forEach((c) => recordPosition(c, shift));
|
|
11241
11372
|
const movedChildren = prevChildren.filter(applyTranslation);
|
|
11242
11373
|
forceReflow(instance.vnode.el);
|
|
11243
11374
|
movedChildren.forEach((c) => {
|
|
@@ -11252,6 +11383,7 @@ var Vue = (function() {
|
|
|
11252
11383
|
let tag = rawProps.tag || Fragment;
|
|
11253
11384
|
if (!rawProps.tag && compatUtils.checkCompatEnabled("TRANSITION_GROUP_ROOT", instance.parent)) tag = "span";
|
|
11254
11385
|
prevChildren = [];
|
|
11386
|
+
moves = void 0;
|
|
11255
11387
|
if (children) for (let i = 0; i < children.length; i++) {
|
|
11256
11388
|
const child = children[i];
|
|
11257
11389
|
if (child.el && child.el instanceof Element && !child.el[vShowHidden]) {
|
|
@@ -11266,6 +11398,14 @@ var Vue = (function() {
|
|
|
11266
11398
|
if (child.key != null) setTransitionHooks(child, resolveTransitionHooks(child, cssTransitionProps, state, instance));
|
|
11267
11399
|
else if (child.type !== Text) warn(`<TransitionGroup> children must be keyed.`);
|
|
11268
11400
|
}
|
|
11401
|
+
if (prevChildren.length) {
|
|
11402
|
+
const root = instance.vnode.el;
|
|
11403
|
+
origins = getOrigins(instance, root);
|
|
11404
|
+
pendingGroups.set(instance, {
|
|
11405
|
+
root,
|
|
11406
|
+
willMove
|
|
11407
|
+
});
|
|
11408
|
+
}
|
|
11269
11409
|
return createVNode(tag, null, children);
|
|
11270
11410
|
};
|
|
11271
11411
|
}
|
|
@@ -11274,8 +11414,11 @@ var Vue = (function() {
|
|
|
11274
11414
|
if (el[moveCbKey]) el[moveCbKey]();
|
|
11275
11415
|
if (el[enterCbKey]) el[enterCbKey]();
|
|
11276
11416
|
}
|
|
11277
|
-
function
|
|
11278
|
-
|
|
11417
|
+
function resolveMoveClass(props) {
|
|
11418
|
+
return props.moveClass || `${props.name || "v"}-move`;
|
|
11419
|
+
}
|
|
11420
|
+
function recordPosition(c, shift) {
|
|
11421
|
+
newPositionMap.set(c, getPosition(c.el, shift));
|
|
11279
11422
|
}
|
|
11280
11423
|
function applyTranslation(c) {
|
|
11281
11424
|
if (baseApplyTranslation(positionMap.get(c), newPositionMap.get(c), c.el)) return c;
|
|
@@ -11300,13 +11443,36 @@ var Vue = (function() {
|
|
|
11300
11443
|
}
|
|
11301
11444
|
return false;
|
|
11302
11445
|
}
|
|
11303
|
-
function getPosition(el) {
|
|
11446
|
+
function getPosition(el, shift) {
|
|
11304
11447
|
const rect = el.getBoundingClientRect();
|
|
11305
11448
|
return {
|
|
11306
|
-
left: rect.left,
|
|
11307
|
-
top: rect.top
|
|
11449
|
+
left: rect.left - (shift ? shift.left : 0),
|
|
11450
|
+
top: rect.top - (shift ? shift.top : 0)
|
|
11308
11451
|
};
|
|
11309
11452
|
}
|
|
11453
|
+
function getOrigins(instance, root) {
|
|
11454
|
+
let origins;
|
|
11455
|
+
for (let group = instance.parent; group; group = group.parent) {
|
|
11456
|
+
const pending = pendingGroups.get(group);
|
|
11457
|
+
if (pending) {
|
|
11458
|
+
const item = findItem(pending.root, root);
|
|
11459
|
+
if (item) (origins || (origins = [])).push(extend(getPosition(item), {
|
|
11460
|
+
item,
|
|
11461
|
+
willMove: pending.willMove
|
|
11462
|
+
}));
|
|
11463
|
+
}
|
|
11464
|
+
}
|
|
11465
|
+
return origins;
|
|
11466
|
+
}
|
|
11467
|
+
function findItem(root, node) {
|
|
11468
|
+
const container = root.nodeType === 1 ? root : root.parentNode;
|
|
11469
|
+
while (node && node.parentNode !== container) node = node.parentNode;
|
|
11470
|
+
if (node && node.nodeType === 1) return node;
|
|
11471
|
+
}
|
|
11472
|
+
function getOriginShift(origins, root) {
|
|
11473
|
+
const origin = origins.find((o) => o.willMove() && o.item.contains(root));
|
|
11474
|
+
return origin && getPosition(origin.item, origin);
|
|
11475
|
+
}
|
|
11310
11476
|
function hasCSSTransform(el, root, moveClass) {
|
|
11311
11477
|
const clone = el.cloneNode();
|
|
11312
11478
|
const _vtc = el[vtcKey];
|
|
@@ -13058,7 +13224,7 @@ var Vue = (function() {
|
|
|
13058
13224
|
[41]: `v-model is missing expression.`,
|
|
13059
13225
|
[42]: `v-model value must be a valid JavaScript member expression.`,
|
|
13060
13226
|
[43]: `v-model cannot be used on v-for or v-slot scope variables because they are not writable.`,
|
|
13061
|
-
[44]: `v-model cannot be used on a prop, because local prop bindings are not writable.\nUse a v-bind binding combined with a v-on listener that emits update:x event instead.`,
|
|
13227
|
+
[44]: `v-model cannot be used on a prop, because local prop bindings are not writable.\nUse a v-bind binding combined with a v-on listener that emits update:x event instead.\nFor props declared with defineModel(), assign the returned ref to a variable and use v-model on that variable.`,
|
|
13062
13228
|
[45]: `v-model cannot be used on a const binding because it is not writable.`,
|
|
13063
13229
|
[46]: `Error parsing JavaScript expression: `,
|
|
13064
13230
|
[47]: `<KeepAlive> expects exactly one child component.`,
|
|
@@ -14881,7 +15047,11 @@ var Vue = (function() {
|
|
|
14881
15047
|
]),
|
|
14882
15048
|
createCompoundExpression([
|
|
14883
15049
|
`if (_cached && _cached.el`,
|
|
14884
|
-
...keyExp ? [
|
|
15050
|
+
...keyExp ? [
|
|
15051
|
+
` && _cached.key === (`,
|
|
15052
|
+
keyExp,
|
|
15053
|
+
`)`
|
|
15054
|
+
] : [],
|
|
14885
15055
|
` && ${context.helperString(IS_MEMO_SAME)}(_cached, _memo)) return _cached`
|
|
14886
15056
|
]),
|
|
14887
15057
|
createCompoundExpression([`const _item = `, childBlock]),
|
|
@@ -16303,7 +16473,11 @@ var Vue = (function() {
|
|
|
16303
16473
|
};
|
|
16304
16474
|
//#endregion
|
|
16305
16475
|
//#region packages/compiler-dom/src/index.ts
|
|
16306
|
-
const DOMNodeTransforms = [
|
|
16476
|
+
const DOMNodeTransforms = [
|
|
16477
|
+
transformStyle,
|
|
16478
|
+
transformTransition,
|
|
16479
|
+
...[validateHtmlNesting]
|
|
16480
|
+
];
|
|
16307
16481
|
const DOMDirectiveTransforms = {
|
|
16308
16482
|
cloak: noopDirectiveTransform,
|
|
16309
16483
|
html: transformVHtml,
|