@vue/compat 3.5.11 → 3.5.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.cjs.js +204 -235
- package/dist/vue.cjs.prod.js +180 -221
- package/dist/vue.esm-browser.js +203 -234
- package/dist/vue.esm-browser.prod.js +6 -6
- package/dist/vue.esm-bundler.js +203 -234
- package/dist/vue.global.js +194 -230
- package/dist/vue.global.prod.js +6 -6
- package/dist/vue.runtime.esm-browser.js +199 -233
- package/dist/vue.runtime.esm-browser.prod.js +2 -2
- package/dist/vue.runtime.esm-bundler.js +199 -233
- package/dist/vue.runtime.global.js +190 -229
- package/dist/vue.runtime.global.prod.js +2 -2
- package/package.json +2 -2
package/dist/vue.esm-browser.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @vue/compat v3.5.
|
|
2
|
+
* @vue/compat v3.5.12
|
|
3
3
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
4
4
|
* @license MIT
|
|
5
5
|
**/
|
|
@@ -763,16 +763,16 @@ function removeSub(link, soft = false) {
|
|
|
763
763
|
nextSub.prevSub = prevSub;
|
|
764
764
|
link.nextSub = void 0;
|
|
765
765
|
}
|
|
766
|
-
if (dep.subs === link) {
|
|
767
|
-
dep.subs = prevSub;
|
|
768
|
-
}
|
|
769
766
|
if (dep.subsHead === link) {
|
|
770
767
|
dep.subsHead = nextSub;
|
|
771
768
|
}
|
|
772
|
-
if (
|
|
773
|
-
dep.
|
|
774
|
-
|
|
775
|
-
|
|
769
|
+
if (dep.subs === link) {
|
|
770
|
+
dep.subs = prevSub;
|
|
771
|
+
if (!prevSub && dep.computed) {
|
|
772
|
+
dep.computed.flags &= ~4;
|
|
773
|
+
for (let l = dep.computed.deps; l; l = l.nextDep) {
|
|
774
|
+
removeSub(l, true);
|
|
775
|
+
}
|
|
776
776
|
}
|
|
777
777
|
}
|
|
778
778
|
if (!soft && !--dep.sc && dep.map) {
|
|
@@ -1032,7 +1032,7 @@ function trigger(target, type, key, newValue, oldValue, oldTarget) {
|
|
|
1032
1032
|
}
|
|
1033
1033
|
});
|
|
1034
1034
|
} else {
|
|
1035
|
-
if (key !== void 0) {
|
|
1035
|
+
if (key !== void 0 || depsMap.has(void 0)) {
|
|
1036
1036
|
run(depsMap.get(key));
|
|
1037
1037
|
}
|
|
1038
1038
|
if (isArrayIndex) {
|
|
@@ -1407,117 +1407,6 @@ const shallowReadonlyHandlers = /* @__PURE__ */ new ReadonlyReactiveHandler(true
|
|
|
1407
1407
|
|
|
1408
1408
|
const toShallow = (value) => value;
|
|
1409
1409
|
const getProto = (v) => Reflect.getPrototypeOf(v);
|
|
1410
|
-
function get(target, key, isReadonly2 = false, isShallow2 = false) {
|
|
1411
|
-
target = target["__v_raw"];
|
|
1412
|
-
const rawTarget = toRaw(target);
|
|
1413
|
-
const rawKey = toRaw(key);
|
|
1414
|
-
if (!isReadonly2) {
|
|
1415
|
-
if (hasChanged(key, rawKey)) {
|
|
1416
|
-
track(rawTarget, "get", key);
|
|
1417
|
-
}
|
|
1418
|
-
track(rawTarget, "get", rawKey);
|
|
1419
|
-
}
|
|
1420
|
-
const { has: has2 } = getProto(rawTarget);
|
|
1421
|
-
const wrap = isShallow2 ? toShallow : isReadonly2 ? toReadonly : toReactive;
|
|
1422
|
-
if (has2.call(rawTarget, key)) {
|
|
1423
|
-
return wrap(target.get(key));
|
|
1424
|
-
} else if (has2.call(rawTarget, rawKey)) {
|
|
1425
|
-
return wrap(target.get(rawKey));
|
|
1426
|
-
} else if (target !== rawTarget) {
|
|
1427
|
-
target.get(key);
|
|
1428
|
-
}
|
|
1429
|
-
}
|
|
1430
|
-
function has(key, isReadonly2 = false) {
|
|
1431
|
-
const target = this["__v_raw"];
|
|
1432
|
-
const rawTarget = toRaw(target);
|
|
1433
|
-
const rawKey = toRaw(key);
|
|
1434
|
-
if (!isReadonly2) {
|
|
1435
|
-
if (hasChanged(key, rawKey)) {
|
|
1436
|
-
track(rawTarget, "has", key);
|
|
1437
|
-
}
|
|
1438
|
-
track(rawTarget, "has", rawKey);
|
|
1439
|
-
}
|
|
1440
|
-
return key === rawKey ? target.has(key) : target.has(key) || target.has(rawKey);
|
|
1441
|
-
}
|
|
1442
|
-
function size(target, isReadonly2 = false) {
|
|
1443
|
-
target = target["__v_raw"];
|
|
1444
|
-
!isReadonly2 && track(toRaw(target), "iterate", ITERATE_KEY);
|
|
1445
|
-
return Reflect.get(target, "size", target);
|
|
1446
|
-
}
|
|
1447
|
-
function add(value, _isShallow = false) {
|
|
1448
|
-
if (!_isShallow && !isShallow(value) && !isReadonly(value)) {
|
|
1449
|
-
value = toRaw(value);
|
|
1450
|
-
}
|
|
1451
|
-
const target = toRaw(this);
|
|
1452
|
-
const proto = getProto(target);
|
|
1453
|
-
const hadKey = proto.has.call(target, value);
|
|
1454
|
-
if (!hadKey) {
|
|
1455
|
-
target.add(value);
|
|
1456
|
-
trigger(target, "add", value, value);
|
|
1457
|
-
}
|
|
1458
|
-
return this;
|
|
1459
|
-
}
|
|
1460
|
-
function set(key, value, _isShallow = false) {
|
|
1461
|
-
if (!_isShallow && !isShallow(value) && !isReadonly(value)) {
|
|
1462
|
-
value = toRaw(value);
|
|
1463
|
-
}
|
|
1464
|
-
const target = toRaw(this);
|
|
1465
|
-
const { has: has2, get: get2 } = getProto(target);
|
|
1466
|
-
let hadKey = has2.call(target, key);
|
|
1467
|
-
if (!hadKey) {
|
|
1468
|
-
key = toRaw(key);
|
|
1469
|
-
hadKey = has2.call(target, key);
|
|
1470
|
-
} else {
|
|
1471
|
-
checkIdentityKeys(target, has2, key);
|
|
1472
|
-
}
|
|
1473
|
-
const oldValue = get2.call(target, key);
|
|
1474
|
-
target.set(key, value);
|
|
1475
|
-
if (!hadKey) {
|
|
1476
|
-
trigger(target, "add", key, value);
|
|
1477
|
-
} else if (hasChanged(value, oldValue)) {
|
|
1478
|
-
trigger(target, "set", key, value, oldValue);
|
|
1479
|
-
}
|
|
1480
|
-
return this;
|
|
1481
|
-
}
|
|
1482
|
-
function deleteEntry(key) {
|
|
1483
|
-
const target = toRaw(this);
|
|
1484
|
-
const { has: has2, get: get2 } = getProto(target);
|
|
1485
|
-
let hadKey = has2.call(target, key);
|
|
1486
|
-
if (!hadKey) {
|
|
1487
|
-
key = toRaw(key);
|
|
1488
|
-
hadKey = has2.call(target, key);
|
|
1489
|
-
} else {
|
|
1490
|
-
checkIdentityKeys(target, has2, key);
|
|
1491
|
-
}
|
|
1492
|
-
const oldValue = get2 ? get2.call(target, key) : void 0;
|
|
1493
|
-
const result = target.delete(key);
|
|
1494
|
-
if (hadKey) {
|
|
1495
|
-
trigger(target, "delete", key, void 0, oldValue);
|
|
1496
|
-
}
|
|
1497
|
-
return result;
|
|
1498
|
-
}
|
|
1499
|
-
function clear() {
|
|
1500
|
-
const target = toRaw(this);
|
|
1501
|
-
const hadItems = target.size !== 0;
|
|
1502
|
-
const oldTarget = isMap(target) ? new Map(target) : new Set(target) ;
|
|
1503
|
-
const result = target.clear();
|
|
1504
|
-
if (hadItems) {
|
|
1505
|
-
trigger(target, "clear", void 0, void 0, oldTarget);
|
|
1506
|
-
}
|
|
1507
|
-
return result;
|
|
1508
|
-
}
|
|
1509
|
-
function createForEach(isReadonly2, isShallow2) {
|
|
1510
|
-
return function forEach(callback, thisArg) {
|
|
1511
|
-
const observed = this;
|
|
1512
|
-
const target = observed["__v_raw"];
|
|
1513
|
-
const rawTarget = toRaw(target);
|
|
1514
|
-
const wrap = isShallow2 ? toShallow : isReadonly2 ? toReadonly : toReactive;
|
|
1515
|
-
!isReadonly2 && track(rawTarget, "iterate", ITERATE_KEY);
|
|
1516
|
-
return target.forEach((value, key) => {
|
|
1517
|
-
return callback.call(thisArg, wrap(value), wrap(key), observed);
|
|
1518
|
-
});
|
|
1519
|
-
};
|
|
1520
|
-
}
|
|
1521
1410
|
function createIterableMethod(method, isReadonly2, isShallow2) {
|
|
1522
1411
|
return function(...args) {
|
|
1523
1412
|
const target = this["__v_raw"];
|
|
@@ -1560,71 +1449,134 @@ function createReadonlyMethod(type) {
|
|
|
1560
1449
|
return type === "delete" ? false : type === "clear" ? void 0 : this;
|
|
1561
1450
|
};
|
|
1562
1451
|
}
|
|
1563
|
-
function createInstrumentations() {
|
|
1564
|
-
const
|
|
1565
|
-
get(key) {
|
|
1566
|
-
return get(this, key);
|
|
1567
|
-
},
|
|
1568
|
-
get size() {
|
|
1569
|
-
return size(this);
|
|
1570
|
-
},
|
|
1571
|
-
has,
|
|
1572
|
-
add,
|
|
1573
|
-
set,
|
|
1574
|
-
delete: deleteEntry,
|
|
1575
|
-
clear,
|
|
1576
|
-
forEach: createForEach(false, false)
|
|
1577
|
-
};
|
|
1578
|
-
const shallowInstrumentations2 = {
|
|
1579
|
-
get(key) {
|
|
1580
|
-
return get(this, key, false, true);
|
|
1581
|
-
},
|
|
1582
|
-
get size() {
|
|
1583
|
-
return size(this);
|
|
1584
|
-
},
|
|
1585
|
-
has,
|
|
1586
|
-
add(value) {
|
|
1587
|
-
return add.call(this, value, true);
|
|
1588
|
-
},
|
|
1589
|
-
set(key, value) {
|
|
1590
|
-
return set.call(this, key, value, true);
|
|
1591
|
-
},
|
|
1592
|
-
delete: deleteEntry,
|
|
1593
|
-
clear,
|
|
1594
|
-
forEach: createForEach(false, true)
|
|
1595
|
-
};
|
|
1596
|
-
const readonlyInstrumentations2 = {
|
|
1597
|
-
get(key) {
|
|
1598
|
-
return get(this, key, true);
|
|
1599
|
-
},
|
|
1600
|
-
get size() {
|
|
1601
|
-
return size(this, true);
|
|
1602
|
-
},
|
|
1603
|
-
has(key) {
|
|
1604
|
-
return has.call(this, key, true);
|
|
1605
|
-
},
|
|
1606
|
-
add: createReadonlyMethod("add"),
|
|
1607
|
-
set: createReadonlyMethod("set"),
|
|
1608
|
-
delete: createReadonlyMethod("delete"),
|
|
1609
|
-
clear: createReadonlyMethod("clear"),
|
|
1610
|
-
forEach: createForEach(true, false)
|
|
1611
|
-
};
|
|
1612
|
-
const shallowReadonlyInstrumentations2 = {
|
|
1452
|
+
function createInstrumentations(readonly, shallow) {
|
|
1453
|
+
const instrumentations = {
|
|
1613
1454
|
get(key) {
|
|
1614
|
-
|
|
1455
|
+
const target = this["__v_raw"];
|
|
1456
|
+
const rawTarget = toRaw(target);
|
|
1457
|
+
const rawKey = toRaw(key);
|
|
1458
|
+
if (!readonly) {
|
|
1459
|
+
if (hasChanged(key, rawKey)) {
|
|
1460
|
+
track(rawTarget, "get", key);
|
|
1461
|
+
}
|
|
1462
|
+
track(rawTarget, "get", rawKey);
|
|
1463
|
+
}
|
|
1464
|
+
const { has } = getProto(rawTarget);
|
|
1465
|
+
const wrap = shallow ? toShallow : readonly ? toReadonly : toReactive;
|
|
1466
|
+
if (has.call(rawTarget, key)) {
|
|
1467
|
+
return wrap(target.get(key));
|
|
1468
|
+
} else if (has.call(rawTarget, rawKey)) {
|
|
1469
|
+
return wrap(target.get(rawKey));
|
|
1470
|
+
} else if (target !== rawTarget) {
|
|
1471
|
+
target.get(key);
|
|
1472
|
+
}
|
|
1615
1473
|
},
|
|
1616
1474
|
get size() {
|
|
1617
|
-
|
|
1475
|
+
const target = this["__v_raw"];
|
|
1476
|
+
!readonly && track(toRaw(target), "iterate", ITERATE_KEY);
|
|
1477
|
+
return Reflect.get(target, "size", target);
|
|
1618
1478
|
},
|
|
1619
1479
|
has(key) {
|
|
1620
|
-
|
|
1480
|
+
const target = this["__v_raw"];
|
|
1481
|
+
const rawTarget = toRaw(target);
|
|
1482
|
+
const rawKey = toRaw(key);
|
|
1483
|
+
if (!readonly) {
|
|
1484
|
+
if (hasChanged(key, rawKey)) {
|
|
1485
|
+
track(rawTarget, "has", key);
|
|
1486
|
+
}
|
|
1487
|
+
track(rawTarget, "has", rawKey);
|
|
1488
|
+
}
|
|
1489
|
+
return key === rawKey ? target.has(key) : target.has(key) || target.has(rawKey);
|
|
1621
1490
|
},
|
|
1622
|
-
|
|
1623
|
-
|
|
1624
|
-
|
|
1625
|
-
|
|
1626
|
-
|
|
1491
|
+
forEach(callback, thisArg) {
|
|
1492
|
+
const observed = this;
|
|
1493
|
+
const target = observed["__v_raw"];
|
|
1494
|
+
const rawTarget = toRaw(target);
|
|
1495
|
+
const wrap = shallow ? toShallow : readonly ? toReadonly : toReactive;
|
|
1496
|
+
!readonly && track(rawTarget, "iterate", ITERATE_KEY);
|
|
1497
|
+
return target.forEach((value, key) => {
|
|
1498
|
+
return callback.call(thisArg, wrap(value), wrap(key), observed);
|
|
1499
|
+
});
|
|
1500
|
+
}
|
|
1627
1501
|
};
|
|
1502
|
+
extend(
|
|
1503
|
+
instrumentations,
|
|
1504
|
+
readonly ? {
|
|
1505
|
+
add: createReadonlyMethod("add"),
|
|
1506
|
+
set: createReadonlyMethod("set"),
|
|
1507
|
+
delete: createReadonlyMethod("delete"),
|
|
1508
|
+
clear: createReadonlyMethod("clear")
|
|
1509
|
+
} : {
|
|
1510
|
+
add(value) {
|
|
1511
|
+
if (!shallow && !isShallow(value) && !isReadonly(value)) {
|
|
1512
|
+
value = toRaw(value);
|
|
1513
|
+
}
|
|
1514
|
+
const target = toRaw(this);
|
|
1515
|
+
const proto = getProto(target);
|
|
1516
|
+
const hadKey = proto.has.call(target, value);
|
|
1517
|
+
if (!hadKey) {
|
|
1518
|
+
target.add(value);
|
|
1519
|
+
trigger(target, "add", value, value);
|
|
1520
|
+
}
|
|
1521
|
+
return this;
|
|
1522
|
+
},
|
|
1523
|
+
set(key, value) {
|
|
1524
|
+
if (!shallow && !isShallow(value) && !isReadonly(value)) {
|
|
1525
|
+
value = toRaw(value);
|
|
1526
|
+
}
|
|
1527
|
+
const target = toRaw(this);
|
|
1528
|
+
const { has, get } = getProto(target);
|
|
1529
|
+
let hadKey = has.call(target, key);
|
|
1530
|
+
if (!hadKey) {
|
|
1531
|
+
key = toRaw(key);
|
|
1532
|
+
hadKey = has.call(target, key);
|
|
1533
|
+
} else {
|
|
1534
|
+
checkIdentityKeys(target, has, key);
|
|
1535
|
+
}
|
|
1536
|
+
const oldValue = get.call(target, key);
|
|
1537
|
+
target.set(key, value);
|
|
1538
|
+
if (!hadKey) {
|
|
1539
|
+
trigger(target, "add", key, value);
|
|
1540
|
+
} else if (hasChanged(value, oldValue)) {
|
|
1541
|
+
trigger(target, "set", key, value, oldValue);
|
|
1542
|
+
}
|
|
1543
|
+
return this;
|
|
1544
|
+
},
|
|
1545
|
+
delete(key) {
|
|
1546
|
+
const target = toRaw(this);
|
|
1547
|
+
const { has, get } = getProto(target);
|
|
1548
|
+
let hadKey = has.call(target, key);
|
|
1549
|
+
if (!hadKey) {
|
|
1550
|
+
key = toRaw(key);
|
|
1551
|
+
hadKey = has.call(target, key);
|
|
1552
|
+
} else {
|
|
1553
|
+
checkIdentityKeys(target, has, key);
|
|
1554
|
+
}
|
|
1555
|
+
const oldValue = get ? get.call(target, key) : void 0;
|
|
1556
|
+
const result = target.delete(key);
|
|
1557
|
+
if (hadKey) {
|
|
1558
|
+
trigger(target, "delete", key, void 0, oldValue);
|
|
1559
|
+
}
|
|
1560
|
+
return result;
|
|
1561
|
+
},
|
|
1562
|
+
clear() {
|
|
1563
|
+
const target = toRaw(this);
|
|
1564
|
+
const hadItems = target.size !== 0;
|
|
1565
|
+
const oldTarget = isMap(target) ? new Map(target) : new Set(target) ;
|
|
1566
|
+
const result = target.clear();
|
|
1567
|
+
if (hadItems) {
|
|
1568
|
+
trigger(
|
|
1569
|
+
target,
|
|
1570
|
+
"clear",
|
|
1571
|
+
void 0,
|
|
1572
|
+
void 0,
|
|
1573
|
+
oldTarget
|
|
1574
|
+
);
|
|
1575
|
+
}
|
|
1576
|
+
return result;
|
|
1577
|
+
}
|
|
1578
|
+
}
|
|
1579
|
+
);
|
|
1628
1580
|
const iteratorMethods = [
|
|
1629
1581
|
"keys",
|
|
1630
1582
|
"values",
|
|
@@ -1632,30 +1584,12 @@ function createInstrumentations() {
|
|
|
1632
1584
|
Symbol.iterator
|
|
1633
1585
|
];
|
|
1634
1586
|
iteratorMethods.forEach((method) => {
|
|
1635
|
-
|
|
1636
|
-
readonlyInstrumentations2[method] = createIterableMethod(method, true, false);
|
|
1637
|
-
shallowInstrumentations2[method] = createIterableMethod(method, false, true);
|
|
1638
|
-
shallowReadonlyInstrumentations2[method] = createIterableMethod(
|
|
1639
|
-
method,
|
|
1640
|
-
true,
|
|
1641
|
-
true
|
|
1642
|
-
);
|
|
1587
|
+
instrumentations[method] = createIterableMethod(method, readonly, shallow);
|
|
1643
1588
|
});
|
|
1644
|
-
return
|
|
1645
|
-
mutableInstrumentations2,
|
|
1646
|
-
readonlyInstrumentations2,
|
|
1647
|
-
shallowInstrumentations2,
|
|
1648
|
-
shallowReadonlyInstrumentations2
|
|
1649
|
-
];
|
|
1589
|
+
return instrumentations;
|
|
1650
1590
|
}
|
|
1651
|
-
const [
|
|
1652
|
-
mutableInstrumentations,
|
|
1653
|
-
readonlyInstrumentations,
|
|
1654
|
-
shallowInstrumentations,
|
|
1655
|
-
shallowReadonlyInstrumentations
|
|
1656
|
-
] = /* @__PURE__ */ createInstrumentations();
|
|
1657
1591
|
function createInstrumentationGetter(isReadonly2, shallow) {
|
|
1658
|
-
const instrumentations =
|
|
1592
|
+
const instrumentations = createInstrumentations(isReadonly2, shallow);
|
|
1659
1593
|
return (target, key, receiver) => {
|
|
1660
1594
|
if (key === "__v_isReactive") {
|
|
1661
1595
|
return !isReadonly2;
|
|
@@ -1683,9 +1617,9 @@ const readonlyCollectionHandlers = {
|
|
|
1683
1617
|
const shallowReadonlyCollectionHandlers = {
|
|
1684
1618
|
get: /* @__PURE__ */ createInstrumentationGetter(true, true)
|
|
1685
1619
|
};
|
|
1686
|
-
function checkIdentityKeys(target,
|
|
1620
|
+
function checkIdentityKeys(target, has, key) {
|
|
1687
1621
|
const rawKey = toRaw(key);
|
|
1688
|
-
if (rawKey !== key &&
|
|
1622
|
+
if (rawKey !== key && has.call(target, rawKey)) {
|
|
1689
1623
|
const type = toRawType(target);
|
|
1690
1624
|
warn$2(
|
|
1691
1625
|
`Reactive ${type} contains both the raw and reactive versions of the same object${type === `Map` ? ` as keys` : ``}, which can lead to inconsistencies. Avoid differentiating between the raw and reactive versions of an object and only use the reactive version if possible.`
|
|
@@ -3639,7 +3573,7 @@ const TeleportImpl = {
|
|
|
3639
3573
|
}
|
|
3640
3574
|
if (!disabled) {
|
|
3641
3575
|
mount(target, targetAnchor);
|
|
3642
|
-
updateCssVars(n2);
|
|
3576
|
+
updateCssVars(n2, false);
|
|
3643
3577
|
}
|
|
3644
3578
|
} else if (!disabled) {
|
|
3645
3579
|
warn$1(
|
|
@@ -3651,7 +3585,7 @@ const TeleportImpl = {
|
|
|
3651
3585
|
};
|
|
3652
3586
|
if (disabled) {
|
|
3653
3587
|
mount(container, mainAnchor);
|
|
3654
|
-
updateCssVars(n2);
|
|
3588
|
+
updateCssVars(n2, true);
|
|
3655
3589
|
}
|
|
3656
3590
|
if (isTeleportDeferred(n2.props)) {
|
|
3657
3591
|
queuePostRenderEffect(mountToTarget, parentSuspense);
|
|
@@ -3741,7 +3675,7 @@ const TeleportImpl = {
|
|
|
3741
3675
|
);
|
|
3742
3676
|
}
|
|
3743
3677
|
}
|
|
3744
|
-
updateCssVars(n2);
|
|
3678
|
+
updateCssVars(n2, disabled);
|
|
3745
3679
|
}
|
|
3746
3680
|
},
|
|
3747
3681
|
remove(vnode, parentComponent, parentSuspense, { um: unmount, o: { remove: hostRemove } }, doRemove) {
|
|
@@ -3809,9 +3743,10 @@ function hydrateTeleport(node, vnode, parentComponent, parentSuspense, slotScope
|
|
|
3809
3743
|
querySelector
|
|
3810
3744
|
);
|
|
3811
3745
|
if (target) {
|
|
3746
|
+
const disabled = isTeleportDisabled(vnode.props);
|
|
3812
3747
|
const targetNode = target._lpa || target.firstChild;
|
|
3813
3748
|
if (vnode.shapeFlag & 16) {
|
|
3814
|
-
if (
|
|
3749
|
+
if (disabled) {
|
|
3815
3750
|
vnode.anchor = hydrateChildren(
|
|
3816
3751
|
nextSibling(node),
|
|
3817
3752
|
vnode,
|
|
@@ -3852,16 +3787,23 @@ function hydrateTeleport(node, vnode, parentComponent, parentSuspense, slotScope
|
|
|
3852
3787
|
);
|
|
3853
3788
|
}
|
|
3854
3789
|
}
|
|
3855
|
-
updateCssVars(vnode);
|
|
3790
|
+
updateCssVars(vnode, disabled);
|
|
3856
3791
|
}
|
|
3857
3792
|
return vnode.anchor && nextSibling(vnode.anchor);
|
|
3858
3793
|
}
|
|
3859
3794
|
const Teleport = TeleportImpl;
|
|
3860
|
-
function updateCssVars(vnode) {
|
|
3795
|
+
function updateCssVars(vnode, isDisabled) {
|
|
3861
3796
|
const ctx = vnode.ctx;
|
|
3862
3797
|
if (ctx && ctx.ut) {
|
|
3863
|
-
let node
|
|
3864
|
-
|
|
3798
|
+
let node, anchor;
|
|
3799
|
+
if (isDisabled) {
|
|
3800
|
+
node = vnode.el;
|
|
3801
|
+
anchor = vnode.anchor;
|
|
3802
|
+
} else {
|
|
3803
|
+
node = vnode.targetStart;
|
|
3804
|
+
anchor = vnode.targetAnchor;
|
|
3805
|
+
}
|
|
3806
|
+
while (node && node !== anchor) {
|
|
3865
3807
|
if (node.nodeType === 1) node.setAttribute("data-v-owner", ctx.uid);
|
|
3866
3808
|
node = node.nextSibling;
|
|
3867
3809
|
}
|
|
@@ -4314,8 +4256,15 @@ function setRef(rawRef, oldRawRef, parentSuspense, vnode, isUnmount = false) {
|
|
|
4314
4256
|
const setupState = owner.setupState;
|
|
4315
4257
|
const rawSetupState = toRaw(setupState);
|
|
4316
4258
|
const canSetSetupRef = setupState === EMPTY_OBJ ? () => false : (key) => {
|
|
4317
|
-
|
|
4318
|
-
|
|
4259
|
+
{
|
|
4260
|
+
if (hasOwn(rawSetupState, key) && !isRef(rawSetupState[key])) {
|
|
4261
|
+
warn$1(
|
|
4262
|
+
`Template ref "${key}" used on a non-ref value. It will not work in the production build.`
|
|
4263
|
+
);
|
|
4264
|
+
}
|
|
4265
|
+
if (knownTemplateRefs.has(rawSetupState[key])) {
|
|
4266
|
+
return false;
|
|
4267
|
+
}
|
|
4319
4268
|
}
|
|
4320
4269
|
return hasOwn(rawSetupState, key);
|
|
4321
4270
|
};
|
|
@@ -4612,7 +4561,11 @@ function createHydrationFunctions(rendererInternals) {
|
|
|
4612
4561
|
}
|
|
4613
4562
|
let needCallTransitionHooks = false;
|
|
4614
4563
|
if (isTemplateNode(el)) {
|
|
4615
|
-
needCallTransitionHooks = needTransition(
|
|
4564
|
+
needCallTransitionHooks = needTransition(
|
|
4565
|
+
null,
|
|
4566
|
+
// no need check parentSuspense in hydration
|
|
4567
|
+
transition
|
|
4568
|
+
) && parentComponent && parentComponent.vnode.props && parentComponent.vnode.props.appear;
|
|
4616
4569
|
const content = el.content.firstChild;
|
|
4617
4570
|
if (needCallTransitionHooks) {
|
|
4618
4571
|
transition.beforeEnter(content);
|
|
@@ -5005,6 +4958,8 @@ function isMismatchAllowed(el, allowedType) {
|
|
|
5005
4958
|
}
|
|
5006
4959
|
}
|
|
5007
4960
|
|
|
4961
|
+
const requestIdleCallback = getGlobalThis().requestIdleCallback || ((cb) => setTimeout(cb, 1));
|
|
4962
|
+
const cancelIdleCallback = getGlobalThis().cancelIdleCallback || ((id) => clearTimeout(id));
|
|
5008
4963
|
const hydrateOnIdle = (timeout = 1e4) => (hydrate) => {
|
|
5009
4964
|
const id = requestIdleCallback(hydrate, { timeout });
|
|
5010
4965
|
return () => cancelIdleCallback(id);
|
|
@@ -5998,12 +5953,13 @@ function renderSlot(slots, name, props = {}, fallback, noSlotted) {
|
|
|
5998
5953
|
}
|
|
5999
5954
|
openBlock();
|
|
6000
5955
|
const validSlotContent = slot && ensureValidVNode(slot(props));
|
|
5956
|
+
const slotKey = props.key || // slot content array of a dynamic conditional slot may have a branch
|
|
5957
|
+
// key attached in the `createSlots` helper, respect that
|
|
5958
|
+
validSlotContent && validSlotContent.key;
|
|
6001
5959
|
const rendered = createBlock(
|
|
6002
5960
|
Fragment,
|
|
6003
5961
|
{
|
|
6004
|
-
key: (
|
|
6005
|
-
// key attached in the `createSlots` helper, respect that
|
|
6006
|
-
validSlotContent && validSlotContent.key || `_${name}`) + // #7256 force differentiate fallback content from actual content
|
|
5962
|
+
key: (slotKey && !isSymbol(slotKey) ? slotKey : `_${name}`) + // #7256 force differentiate fallback content from actual content
|
|
6007
5963
|
(!validSlotContent && fallback ? "_fb" : "")
|
|
6008
5964
|
},
|
|
6009
5965
|
validSlotContent || (fallback ? fallback() : []),
|
|
@@ -7172,7 +7128,7 @@ function createCompatVue$1(createApp, createSingletonApp) {
|
|
|
7172
7128
|
return vm;
|
|
7173
7129
|
}
|
|
7174
7130
|
}
|
|
7175
|
-
Vue.version = `2.6.14-compat:${"3.5.
|
|
7131
|
+
Vue.version = `2.6.14-compat:${"3.5.12"}`;
|
|
7176
7132
|
Vue.config = singletonApp.config;
|
|
7177
7133
|
Vue.use = (plugin, ...options) => {
|
|
7178
7134
|
if (plugin && isFunction(plugin.install)) {
|
|
@@ -8160,6 +8116,7 @@ function getType(ctor) {
|
|
|
8160
8116
|
function validateProps(rawProps, props, instance) {
|
|
8161
8117
|
const resolvedValues = toRaw(props);
|
|
8162
8118
|
const options = instance.propsOptions[0];
|
|
8119
|
+
const camelizePropsKey = Object.keys(rawProps).map((key) => camelize(key));
|
|
8163
8120
|
for (const key in options) {
|
|
8164
8121
|
let opt = options[key];
|
|
8165
8122
|
if (opt == null) continue;
|
|
@@ -8168,7 +8125,7 @@ function validateProps(rawProps, props, instance) {
|
|
|
8168
8125
|
resolvedValues[key],
|
|
8169
8126
|
opt,
|
|
8170
8127
|
shallowReadonly(resolvedValues) ,
|
|
8171
|
-
!
|
|
8128
|
+
!camelizePropsKey.includes(key)
|
|
8172
8129
|
);
|
|
8173
8130
|
}
|
|
8174
8131
|
}
|
|
@@ -9982,14 +9939,13 @@ function doWatch(source, cb, options = EMPTY_OBJ) {
|
|
|
9982
9939
|
}
|
|
9983
9940
|
const baseWatchOptions = extend({}, options);
|
|
9984
9941
|
baseWatchOptions.onWarn = warn$1;
|
|
9942
|
+
const runsImmediately = cb && immediate || !cb && flush !== "post";
|
|
9985
9943
|
let ssrCleanup;
|
|
9986
9944
|
if (isInSSRComponentSetup) {
|
|
9987
9945
|
if (flush === "sync") {
|
|
9988
9946
|
const ctx = useSSRContext();
|
|
9989
9947
|
ssrCleanup = ctx.__watcherHandles || (ctx.__watcherHandles = []);
|
|
9990
|
-
} else if (!
|
|
9991
|
-
baseWatchOptions.once = true;
|
|
9992
|
-
} else {
|
|
9948
|
+
} else if (!runsImmediately) {
|
|
9993
9949
|
const watchStopHandle = () => {
|
|
9994
9950
|
};
|
|
9995
9951
|
watchStopHandle.stop = NOOP;
|
|
@@ -10028,7 +9984,13 @@ function doWatch(source, cb, options = EMPTY_OBJ) {
|
|
|
10028
9984
|
}
|
|
10029
9985
|
};
|
|
10030
9986
|
const watchHandle = watch$1(source, cb, baseWatchOptions);
|
|
10031
|
-
if (
|
|
9987
|
+
if (isInSSRComponentSetup) {
|
|
9988
|
+
if (ssrCleanup) {
|
|
9989
|
+
ssrCleanup.push(watchHandle);
|
|
9990
|
+
} else if (runsImmediately) {
|
|
9991
|
+
watchHandle();
|
|
9992
|
+
}
|
|
9993
|
+
}
|
|
10032
9994
|
return watchHandle;
|
|
10033
9995
|
}
|
|
10034
9996
|
function instanceWatch(source, value, options) {
|
|
@@ -10063,19 +10025,19 @@ function useModel(props, name, options = EMPTY_OBJ) {
|
|
|
10063
10025
|
warn$1(`useModel() called without active instance.`);
|
|
10064
10026
|
return ref();
|
|
10065
10027
|
}
|
|
10066
|
-
|
|
10028
|
+
const camelizedName = camelize(name);
|
|
10029
|
+
if (!i.propsOptions[0][camelizedName]) {
|
|
10067
10030
|
warn$1(`useModel() called with prop "${name}" which is not declared.`);
|
|
10068
10031
|
return ref();
|
|
10069
10032
|
}
|
|
10070
|
-
const camelizedName = camelize(name);
|
|
10071
10033
|
const hyphenatedName = hyphenate(name);
|
|
10072
|
-
const modifiers = getModelModifiers(props,
|
|
10034
|
+
const modifiers = getModelModifiers(props, camelizedName);
|
|
10073
10035
|
const res = customRef((track, trigger) => {
|
|
10074
10036
|
let localValue;
|
|
10075
10037
|
let prevSetValue = EMPTY_OBJ;
|
|
10076
10038
|
let prevEmittedValue;
|
|
10077
10039
|
watchSyncEffect(() => {
|
|
10078
|
-
const propValue = props[
|
|
10040
|
+
const propValue = props[camelizedName];
|
|
10079
10041
|
if (hasChanged(localValue, propValue)) {
|
|
10080
10042
|
localValue = propValue;
|
|
10081
10043
|
trigger();
|
|
@@ -11797,9 +11759,9 @@ function setupStatefulComponent(instance, isSSR) {
|
|
|
11797
11759
|
}
|
|
11798
11760
|
const { setup } = Component;
|
|
11799
11761
|
if (setup) {
|
|
11762
|
+
pauseTracking();
|
|
11800
11763
|
const setupContext = instance.setupContext = setup.length > 1 ? createSetupContext(instance) : null;
|
|
11801
11764
|
const reset = setCurrentInstance(instance);
|
|
11802
|
-
pauseTracking();
|
|
11803
11765
|
const setupResult = callWithErrorHandling(
|
|
11804
11766
|
setup,
|
|
11805
11767
|
instance,
|
|
@@ -11809,10 +11771,13 @@ function setupStatefulComponent(instance, isSSR) {
|
|
|
11809
11771
|
setupContext
|
|
11810
11772
|
]
|
|
11811
11773
|
);
|
|
11774
|
+
const isAsyncSetup = isPromise(setupResult);
|
|
11812
11775
|
resetTracking();
|
|
11813
11776
|
reset();
|
|
11814
|
-
if (
|
|
11815
|
-
|
|
11777
|
+
if ((isAsyncSetup || instance.sp) && !isAsyncWrapper(instance)) {
|
|
11778
|
+
markAsyncBoundary(instance);
|
|
11779
|
+
}
|
|
11780
|
+
if (isAsyncSetup) {
|
|
11816
11781
|
setupResult.then(unsetCurrentInstance, unsetCurrentInstance);
|
|
11817
11782
|
if (isSSR) {
|
|
11818
11783
|
return setupResult.then((resolvedResult) => {
|
|
@@ -12287,7 +12252,7 @@ function isMemoSame(cached, memo) {
|
|
|
12287
12252
|
return true;
|
|
12288
12253
|
}
|
|
12289
12254
|
|
|
12290
|
-
const version = "3.5.
|
|
12255
|
+
const version = "3.5.12";
|
|
12291
12256
|
const warn = warn$1 ;
|
|
12292
12257
|
const ErrorTypeStrings = ErrorTypeStrings$1 ;
|
|
12293
12258
|
const devtools = devtools$1 ;
|
|
@@ -12992,7 +12957,7 @@ function compatCoerceAttr(el, key, value, instance = null) {
|
|
|
12992
12957
|
return false;
|
|
12993
12958
|
}
|
|
12994
12959
|
|
|
12995
|
-
function patchDOMProp(el, key, value, parentComponent) {
|
|
12960
|
+
function patchDOMProp(el, key, value, parentComponent, attrName) {
|
|
12996
12961
|
if (key === "innerHTML" || key === "textContent") {
|
|
12997
12962
|
if (value != null) {
|
|
12998
12963
|
el[key] = key === "innerHTML" ? unsafeToTrustedHTML(value) : value;
|
|
@@ -13056,7 +13021,7 @@ function patchDOMProp(el, key, value, parentComponent) {
|
|
|
13056
13021
|
);
|
|
13057
13022
|
}
|
|
13058
13023
|
}
|
|
13059
|
-
needRemove && el.removeAttribute(key);
|
|
13024
|
+
needRemove && el.removeAttribute(attrName || key);
|
|
13060
13025
|
}
|
|
13061
13026
|
|
|
13062
13027
|
function addEventListener(el, event, handler, options) {
|
|
@@ -13166,7 +13131,7 @@ const patchProp = (el, key, prevValue, nextValue, namespace, parentComponent) =>
|
|
|
13166
13131
|
// #11081 force set props for possible async custom element
|
|
13167
13132
|
el._isVueCE && (/[A-Z]/.test(key) || !isString(nextValue))
|
|
13168
13133
|
) {
|
|
13169
|
-
patchDOMProp(el, camelize(key), nextValue, parentComponent);
|
|
13134
|
+
patchDOMProp(el, camelize(key), nextValue, parentComponent, key);
|
|
13170
13135
|
} else {
|
|
13171
13136
|
if (key === "true-value") {
|
|
13172
13137
|
el._trueValue = nextValue;
|
|
@@ -13893,7 +13858,7 @@ const vModelCheckbox = {
|
|
|
13893
13858
|
setChecked(el, binding, vnode);
|
|
13894
13859
|
}
|
|
13895
13860
|
};
|
|
13896
|
-
function setChecked(el, { value }, vnode) {
|
|
13861
|
+
function setChecked(el, { value, oldValue }, vnode) {
|
|
13897
13862
|
el._modelValue = value;
|
|
13898
13863
|
let checked;
|
|
13899
13864
|
if (isArray(value)) {
|
|
@@ -13901,6 +13866,7 @@ function setChecked(el, { value }, vnode) {
|
|
|
13901
13866
|
} else if (isSet(value)) {
|
|
13902
13867
|
checked = value.has(vnode.props.value);
|
|
13903
13868
|
} else {
|
|
13869
|
+
if (value === oldValue) return;
|
|
13904
13870
|
checked = looseEqual(value, getCheckboxValue(el, true));
|
|
13905
13871
|
}
|
|
13906
13872
|
if (el.checked !== checked) {
|
|
@@ -16610,6 +16576,9 @@ function getLoc(start, end) {
|
|
|
16610
16576
|
source: end == null ? end : getSlice(start, end)
|
|
16611
16577
|
};
|
|
16612
16578
|
}
|
|
16579
|
+
function cloneLoc(loc) {
|
|
16580
|
+
return getLoc(loc.start.offset, loc.end.offset);
|
|
16581
|
+
}
|
|
16613
16582
|
function setLocEnd(loc, end) {
|
|
16614
16583
|
loc.end = tokenizer.getPos(end);
|
|
16615
16584
|
loc.source = getSlice(loc.start.offset, end);
|
|
@@ -17968,7 +17937,7 @@ function processIf(node, dir, context, processCodegen) {
|
|
|
17968
17937
|
const branch = createIfBranch(node, dir);
|
|
17969
17938
|
const ifNode = {
|
|
17970
17939
|
type: 9,
|
|
17971
|
-
loc: node.loc,
|
|
17940
|
+
loc: cloneLoc(node.loc),
|
|
17972
17941
|
branches: [branch]
|
|
17973
17942
|
};
|
|
17974
17943
|
context.replaceNode(ifNode);
|