@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
|
@@ -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
|
**/
|
|
@@ -693,16 +693,16 @@ var Vue = (function () {
|
|
|
693
693
|
nextSub.prevSub = prevSub;
|
|
694
694
|
link.nextSub = void 0;
|
|
695
695
|
}
|
|
696
|
-
if (dep.subs === link) {
|
|
697
|
-
dep.subs = prevSub;
|
|
698
|
-
}
|
|
699
696
|
if (dep.subsHead === link) {
|
|
700
697
|
dep.subsHead = nextSub;
|
|
701
698
|
}
|
|
702
|
-
if (
|
|
703
|
-
dep.
|
|
704
|
-
|
|
705
|
-
|
|
699
|
+
if (dep.subs === link) {
|
|
700
|
+
dep.subs = prevSub;
|
|
701
|
+
if (!prevSub && dep.computed) {
|
|
702
|
+
dep.computed.flags &= ~4;
|
|
703
|
+
for (let l = dep.computed.deps; l; l = l.nextDep) {
|
|
704
|
+
removeSub(l, true);
|
|
705
|
+
}
|
|
706
706
|
}
|
|
707
707
|
}
|
|
708
708
|
if (!soft && !--dep.sc && dep.map) {
|
|
@@ -962,7 +962,7 @@ var Vue = (function () {
|
|
|
962
962
|
}
|
|
963
963
|
});
|
|
964
964
|
} else {
|
|
965
|
-
if (key !== void 0) {
|
|
965
|
+
if (key !== void 0 || depsMap.has(void 0)) {
|
|
966
966
|
run(depsMap.get(key));
|
|
967
967
|
}
|
|
968
968
|
if (isArrayIndex) {
|
|
@@ -1337,117 +1337,6 @@ var Vue = (function () {
|
|
|
1337
1337
|
|
|
1338
1338
|
const toShallow = (value) => value;
|
|
1339
1339
|
const getProto = (v) => Reflect.getPrototypeOf(v);
|
|
1340
|
-
function get(target, key, isReadonly2 = false, isShallow2 = false) {
|
|
1341
|
-
target = target["__v_raw"];
|
|
1342
|
-
const rawTarget = toRaw(target);
|
|
1343
|
-
const rawKey = toRaw(key);
|
|
1344
|
-
if (!isReadonly2) {
|
|
1345
|
-
if (hasChanged(key, rawKey)) {
|
|
1346
|
-
track(rawTarget, "get", key);
|
|
1347
|
-
}
|
|
1348
|
-
track(rawTarget, "get", rawKey);
|
|
1349
|
-
}
|
|
1350
|
-
const { has: has2 } = getProto(rawTarget);
|
|
1351
|
-
const wrap = isShallow2 ? toShallow : isReadonly2 ? toReadonly : toReactive;
|
|
1352
|
-
if (has2.call(rawTarget, key)) {
|
|
1353
|
-
return wrap(target.get(key));
|
|
1354
|
-
} else if (has2.call(rawTarget, rawKey)) {
|
|
1355
|
-
return wrap(target.get(rawKey));
|
|
1356
|
-
} else if (target !== rawTarget) {
|
|
1357
|
-
target.get(key);
|
|
1358
|
-
}
|
|
1359
|
-
}
|
|
1360
|
-
function has(key, isReadonly2 = false) {
|
|
1361
|
-
const target = this["__v_raw"];
|
|
1362
|
-
const rawTarget = toRaw(target);
|
|
1363
|
-
const rawKey = toRaw(key);
|
|
1364
|
-
if (!isReadonly2) {
|
|
1365
|
-
if (hasChanged(key, rawKey)) {
|
|
1366
|
-
track(rawTarget, "has", key);
|
|
1367
|
-
}
|
|
1368
|
-
track(rawTarget, "has", rawKey);
|
|
1369
|
-
}
|
|
1370
|
-
return key === rawKey ? target.has(key) : target.has(key) || target.has(rawKey);
|
|
1371
|
-
}
|
|
1372
|
-
function size(target, isReadonly2 = false) {
|
|
1373
|
-
target = target["__v_raw"];
|
|
1374
|
-
!isReadonly2 && track(toRaw(target), "iterate", ITERATE_KEY);
|
|
1375
|
-
return Reflect.get(target, "size", target);
|
|
1376
|
-
}
|
|
1377
|
-
function add(value, _isShallow = false) {
|
|
1378
|
-
if (!_isShallow && !isShallow(value) && !isReadonly(value)) {
|
|
1379
|
-
value = toRaw(value);
|
|
1380
|
-
}
|
|
1381
|
-
const target = toRaw(this);
|
|
1382
|
-
const proto = getProto(target);
|
|
1383
|
-
const hadKey = proto.has.call(target, value);
|
|
1384
|
-
if (!hadKey) {
|
|
1385
|
-
target.add(value);
|
|
1386
|
-
trigger(target, "add", value, value);
|
|
1387
|
-
}
|
|
1388
|
-
return this;
|
|
1389
|
-
}
|
|
1390
|
-
function set(key, value, _isShallow = false) {
|
|
1391
|
-
if (!_isShallow && !isShallow(value) && !isReadonly(value)) {
|
|
1392
|
-
value = toRaw(value);
|
|
1393
|
-
}
|
|
1394
|
-
const target = toRaw(this);
|
|
1395
|
-
const { has: has2, get: get2 } = getProto(target);
|
|
1396
|
-
let hadKey = has2.call(target, key);
|
|
1397
|
-
if (!hadKey) {
|
|
1398
|
-
key = toRaw(key);
|
|
1399
|
-
hadKey = has2.call(target, key);
|
|
1400
|
-
} else {
|
|
1401
|
-
checkIdentityKeys(target, has2, key);
|
|
1402
|
-
}
|
|
1403
|
-
const oldValue = get2.call(target, key);
|
|
1404
|
-
target.set(key, value);
|
|
1405
|
-
if (!hadKey) {
|
|
1406
|
-
trigger(target, "add", key, value);
|
|
1407
|
-
} else if (hasChanged(value, oldValue)) {
|
|
1408
|
-
trigger(target, "set", key, value, oldValue);
|
|
1409
|
-
}
|
|
1410
|
-
return this;
|
|
1411
|
-
}
|
|
1412
|
-
function deleteEntry(key) {
|
|
1413
|
-
const target = toRaw(this);
|
|
1414
|
-
const { has: has2, get: get2 } = getProto(target);
|
|
1415
|
-
let hadKey = has2.call(target, key);
|
|
1416
|
-
if (!hadKey) {
|
|
1417
|
-
key = toRaw(key);
|
|
1418
|
-
hadKey = has2.call(target, key);
|
|
1419
|
-
} else {
|
|
1420
|
-
checkIdentityKeys(target, has2, key);
|
|
1421
|
-
}
|
|
1422
|
-
const oldValue = get2 ? get2.call(target, key) : void 0;
|
|
1423
|
-
const result = target.delete(key);
|
|
1424
|
-
if (hadKey) {
|
|
1425
|
-
trigger(target, "delete", key, void 0, oldValue);
|
|
1426
|
-
}
|
|
1427
|
-
return result;
|
|
1428
|
-
}
|
|
1429
|
-
function clear() {
|
|
1430
|
-
const target = toRaw(this);
|
|
1431
|
-
const hadItems = target.size !== 0;
|
|
1432
|
-
const oldTarget = isMap(target) ? new Map(target) : new Set(target) ;
|
|
1433
|
-
const result = target.clear();
|
|
1434
|
-
if (hadItems) {
|
|
1435
|
-
trigger(target, "clear", void 0, void 0, oldTarget);
|
|
1436
|
-
}
|
|
1437
|
-
return result;
|
|
1438
|
-
}
|
|
1439
|
-
function createForEach(isReadonly2, isShallow2) {
|
|
1440
|
-
return function forEach(callback, thisArg) {
|
|
1441
|
-
const observed = this;
|
|
1442
|
-
const target = observed["__v_raw"];
|
|
1443
|
-
const rawTarget = toRaw(target);
|
|
1444
|
-
const wrap = isShallow2 ? toShallow : isReadonly2 ? toReadonly : toReactive;
|
|
1445
|
-
!isReadonly2 && track(rawTarget, "iterate", ITERATE_KEY);
|
|
1446
|
-
return target.forEach((value, key) => {
|
|
1447
|
-
return callback.call(thisArg, wrap(value), wrap(key), observed);
|
|
1448
|
-
});
|
|
1449
|
-
};
|
|
1450
|
-
}
|
|
1451
1340
|
function createIterableMethod(method, isReadonly2, isShallow2) {
|
|
1452
1341
|
return function(...args) {
|
|
1453
1342
|
const target = this["__v_raw"];
|
|
@@ -1490,71 +1379,134 @@ var Vue = (function () {
|
|
|
1490
1379
|
return type === "delete" ? false : type === "clear" ? void 0 : this;
|
|
1491
1380
|
};
|
|
1492
1381
|
}
|
|
1493
|
-
function createInstrumentations() {
|
|
1494
|
-
const
|
|
1495
|
-
get(key) {
|
|
1496
|
-
return get(this, key);
|
|
1497
|
-
},
|
|
1498
|
-
get size() {
|
|
1499
|
-
return size(this);
|
|
1500
|
-
},
|
|
1501
|
-
has,
|
|
1502
|
-
add,
|
|
1503
|
-
set,
|
|
1504
|
-
delete: deleteEntry,
|
|
1505
|
-
clear,
|
|
1506
|
-
forEach: createForEach(false, false)
|
|
1507
|
-
};
|
|
1508
|
-
const shallowInstrumentations2 = {
|
|
1509
|
-
get(key) {
|
|
1510
|
-
return get(this, key, false, true);
|
|
1511
|
-
},
|
|
1512
|
-
get size() {
|
|
1513
|
-
return size(this);
|
|
1514
|
-
},
|
|
1515
|
-
has,
|
|
1516
|
-
add(value) {
|
|
1517
|
-
return add.call(this, value, true);
|
|
1518
|
-
},
|
|
1519
|
-
set(key, value) {
|
|
1520
|
-
return set.call(this, key, value, true);
|
|
1521
|
-
},
|
|
1522
|
-
delete: deleteEntry,
|
|
1523
|
-
clear,
|
|
1524
|
-
forEach: createForEach(false, true)
|
|
1525
|
-
};
|
|
1526
|
-
const readonlyInstrumentations2 = {
|
|
1527
|
-
get(key) {
|
|
1528
|
-
return get(this, key, true);
|
|
1529
|
-
},
|
|
1530
|
-
get size() {
|
|
1531
|
-
return size(this, true);
|
|
1532
|
-
},
|
|
1533
|
-
has(key) {
|
|
1534
|
-
return has.call(this, key, true);
|
|
1535
|
-
},
|
|
1536
|
-
add: createReadonlyMethod("add"),
|
|
1537
|
-
set: createReadonlyMethod("set"),
|
|
1538
|
-
delete: createReadonlyMethod("delete"),
|
|
1539
|
-
clear: createReadonlyMethod("clear"),
|
|
1540
|
-
forEach: createForEach(true, false)
|
|
1541
|
-
};
|
|
1542
|
-
const shallowReadonlyInstrumentations2 = {
|
|
1382
|
+
function createInstrumentations(readonly, shallow) {
|
|
1383
|
+
const instrumentations = {
|
|
1543
1384
|
get(key) {
|
|
1544
|
-
|
|
1385
|
+
const target = this["__v_raw"];
|
|
1386
|
+
const rawTarget = toRaw(target);
|
|
1387
|
+
const rawKey = toRaw(key);
|
|
1388
|
+
if (!readonly) {
|
|
1389
|
+
if (hasChanged(key, rawKey)) {
|
|
1390
|
+
track(rawTarget, "get", key);
|
|
1391
|
+
}
|
|
1392
|
+
track(rawTarget, "get", rawKey);
|
|
1393
|
+
}
|
|
1394
|
+
const { has } = getProto(rawTarget);
|
|
1395
|
+
const wrap = shallow ? toShallow : readonly ? toReadonly : toReactive;
|
|
1396
|
+
if (has.call(rawTarget, key)) {
|
|
1397
|
+
return wrap(target.get(key));
|
|
1398
|
+
} else if (has.call(rawTarget, rawKey)) {
|
|
1399
|
+
return wrap(target.get(rawKey));
|
|
1400
|
+
} else if (target !== rawTarget) {
|
|
1401
|
+
target.get(key);
|
|
1402
|
+
}
|
|
1545
1403
|
},
|
|
1546
1404
|
get size() {
|
|
1547
|
-
|
|
1405
|
+
const target = this["__v_raw"];
|
|
1406
|
+
!readonly && track(toRaw(target), "iterate", ITERATE_KEY);
|
|
1407
|
+
return Reflect.get(target, "size", target);
|
|
1548
1408
|
},
|
|
1549
1409
|
has(key) {
|
|
1550
|
-
|
|
1410
|
+
const target = this["__v_raw"];
|
|
1411
|
+
const rawTarget = toRaw(target);
|
|
1412
|
+
const rawKey = toRaw(key);
|
|
1413
|
+
if (!readonly) {
|
|
1414
|
+
if (hasChanged(key, rawKey)) {
|
|
1415
|
+
track(rawTarget, "has", key);
|
|
1416
|
+
}
|
|
1417
|
+
track(rawTarget, "has", rawKey);
|
|
1418
|
+
}
|
|
1419
|
+
return key === rawKey ? target.has(key) : target.has(key) || target.has(rawKey);
|
|
1551
1420
|
},
|
|
1552
|
-
|
|
1553
|
-
|
|
1554
|
-
|
|
1555
|
-
|
|
1556
|
-
|
|
1421
|
+
forEach(callback, thisArg) {
|
|
1422
|
+
const observed = this;
|
|
1423
|
+
const target = observed["__v_raw"];
|
|
1424
|
+
const rawTarget = toRaw(target);
|
|
1425
|
+
const wrap = shallow ? toShallow : readonly ? toReadonly : toReactive;
|
|
1426
|
+
!readonly && track(rawTarget, "iterate", ITERATE_KEY);
|
|
1427
|
+
return target.forEach((value, key) => {
|
|
1428
|
+
return callback.call(thisArg, wrap(value), wrap(key), observed);
|
|
1429
|
+
});
|
|
1430
|
+
}
|
|
1557
1431
|
};
|
|
1432
|
+
extend(
|
|
1433
|
+
instrumentations,
|
|
1434
|
+
readonly ? {
|
|
1435
|
+
add: createReadonlyMethod("add"),
|
|
1436
|
+
set: createReadonlyMethod("set"),
|
|
1437
|
+
delete: createReadonlyMethod("delete"),
|
|
1438
|
+
clear: createReadonlyMethod("clear")
|
|
1439
|
+
} : {
|
|
1440
|
+
add(value) {
|
|
1441
|
+
if (!shallow && !isShallow(value) && !isReadonly(value)) {
|
|
1442
|
+
value = toRaw(value);
|
|
1443
|
+
}
|
|
1444
|
+
const target = toRaw(this);
|
|
1445
|
+
const proto = getProto(target);
|
|
1446
|
+
const hadKey = proto.has.call(target, value);
|
|
1447
|
+
if (!hadKey) {
|
|
1448
|
+
target.add(value);
|
|
1449
|
+
trigger(target, "add", value, value);
|
|
1450
|
+
}
|
|
1451
|
+
return this;
|
|
1452
|
+
},
|
|
1453
|
+
set(key, value) {
|
|
1454
|
+
if (!shallow && !isShallow(value) && !isReadonly(value)) {
|
|
1455
|
+
value = toRaw(value);
|
|
1456
|
+
}
|
|
1457
|
+
const target = toRaw(this);
|
|
1458
|
+
const { has, get } = getProto(target);
|
|
1459
|
+
let hadKey = has.call(target, key);
|
|
1460
|
+
if (!hadKey) {
|
|
1461
|
+
key = toRaw(key);
|
|
1462
|
+
hadKey = has.call(target, key);
|
|
1463
|
+
} else {
|
|
1464
|
+
checkIdentityKeys(target, has, key);
|
|
1465
|
+
}
|
|
1466
|
+
const oldValue = get.call(target, key);
|
|
1467
|
+
target.set(key, value);
|
|
1468
|
+
if (!hadKey) {
|
|
1469
|
+
trigger(target, "add", key, value);
|
|
1470
|
+
} else if (hasChanged(value, oldValue)) {
|
|
1471
|
+
trigger(target, "set", key, value, oldValue);
|
|
1472
|
+
}
|
|
1473
|
+
return this;
|
|
1474
|
+
},
|
|
1475
|
+
delete(key) {
|
|
1476
|
+
const target = toRaw(this);
|
|
1477
|
+
const { has, get } = getProto(target);
|
|
1478
|
+
let hadKey = has.call(target, key);
|
|
1479
|
+
if (!hadKey) {
|
|
1480
|
+
key = toRaw(key);
|
|
1481
|
+
hadKey = has.call(target, key);
|
|
1482
|
+
} else {
|
|
1483
|
+
checkIdentityKeys(target, has, key);
|
|
1484
|
+
}
|
|
1485
|
+
const oldValue = get ? get.call(target, key) : void 0;
|
|
1486
|
+
const result = target.delete(key);
|
|
1487
|
+
if (hadKey) {
|
|
1488
|
+
trigger(target, "delete", key, void 0, oldValue);
|
|
1489
|
+
}
|
|
1490
|
+
return result;
|
|
1491
|
+
},
|
|
1492
|
+
clear() {
|
|
1493
|
+
const target = toRaw(this);
|
|
1494
|
+
const hadItems = target.size !== 0;
|
|
1495
|
+
const oldTarget = isMap(target) ? new Map(target) : new Set(target) ;
|
|
1496
|
+
const result = target.clear();
|
|
1497
|
+
if (hadItems) {
|
|
1498
|
+
trigger(
|
|
1499
|
+
target,
|
|
1500
|
+
"clear",
|
|
1501
|
+
void 0,
|
|
1502
|
+
void 0,
|
|
1503
|
+
oldTarget
|
|
1504
|
+
);
|
|
1505
|
+
}
|
|
1506
|
+
return result;
|
|
1507
|
+
}
|
|
1508
|
+
}
|
|
1509
|
+
);
|
|
1558
1510
|
const iteratorMethods = [
|
|
1559
1511
|
"keys",
|
|
1560
1512
|
"values",
|
|
@@ -1562,30 +1514,12 @@ var Vue = (function () {
|
|
|
1562
1514
|
Symbol.iterator
|
|
1563
1515
|
];
|
|
1564
1516
|
iteratorMethods.forEach((method) => {
|
|
1565
|
-
|
|
1566
|
-
readonlyInstrumentations2[method] = createIterableMethod(method, true, false);
|
|
1567
|
-
shallowInstrumentations2[method] = createIterableMethod(method, false, true);
|
|
1568
|
-
shallowReadonlyInstrumentations2[method] = createIterableMethod(
|
|
1569
|
-
method,
|
|
1570
|
-
true,
|
|
1571
|
-
true
|
|
1572
|
-
);
|
|
1517
|
+
instrumentations[method] = createIterableMethod(method, readonly, shallow);
|
|
1573
1518
|
});
|
|
1574
|
-
return
|
|
1575
|
-
mutableInstrumentations2,
|
|
1576
|
-
readonlyInstrumentations2,
|
|
1577
|
-
shallowInstrumentations2,
|
|
1578
|
-
shallowReadonlyInstrumentations2
|
|
1579
|
-
];
|
|
1519
|
+
return instrumentations;
|
|
1580
1520
|
}
|
|
1581
|
-
const [
|
|
1582
|
-
mutableInstrumentations,
|
|
1583
|
-
readonlyInstrumentations,
|
|
1584
|
-
shallowInstrumentations,
|
|
1585
|
-
shallowReadonlyInstrumentations
|
|
1586
|
-
] = /* @__PURE__ */ createInstrumentations();
|
|
1587
1521
|
function createInstrumentationGetter(isReadonly2, shallow) {
|
|
1588
|
-
const instrumentations =
|
|
1522
|
+
const instrumentations = createInstrumentations(isReadonly2, shallow);
|
|
1589
1523
|
return (target, key, receiver) => {
|
|
1590
1524
|
if (key === "__v_isReactive") {
|
|
1591
1525
|
return !isReadonly2;
|
|
@@ -1613,9 +1547,9 @@ var Vue = (function () {
|
|
|
1613
1547
|
const shallowReadonlyCollectionHandlers = {
|
|
1614
1548
|
get: /* @__PURE__ */ createInstrumentationGetter(true, true)
|
|
1615
1549
|
};
|
|
1616
|
-
function checkIdentityKeys(target,
|
|
1550
|
+
function checkIdentityKeys(target, has, key) {
|
|
1617
1551
|
const rawKey = toRaw(key);
|
|
1618
|
-
if (rawKey !== key &&
|
|
1552
|
+
if (rawKey !== key && has.call(target, rawKey)) {
|
|
1619
1553
|
const type = toRawType(target);
|
|
1620
1554
|
warn$2(
|
|
1621
1555
|
`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.`
|
|
@@ -3569,7 +3503,7 @@ Details: https://v3-migration.vuejs.org/breaking-changes/migration-build.html`
|
|
|
3569
3503
|
}
|
|
3570
3504
|
if (!disabled) {
|
|
3571
3505
|
mount(target, targetAnchor);
|
|
3572
|
-
updateCssVars(n2);
|
|
3506
|
+
updateCssVars(n2, false);
|
|
3573
3507
|
}
|
|
3574
3508
|
} else if (!disabled) {
|
|
3575
3509
|
warn$1(
|
|
@@ -3581,7 +3515,7 @@ Details: https://v3-migration.vuejs.org/breaking-changes/migration-build.html`
|
|
|
3581
3515
|
};
|
|
3582
3516
|
if (disabled) {
|
|
3583
3517
|
mount(container, mainAnchor);
|
|
3584
|
-
updateCssVars(n2);
|
|
3518
|
+
updateCssVars(n2, true);
|
|
3585
3519
|
}
|
|
3586
3520
|
if (isTeleportDeferred(n2.props)) {
|
|
3587
3521
|
queuePostRenderEffect(mountToTarget, parentSuspense);
|
|
@@ -3671,7 +3605,7 @@ Details: https://v3-migration.vuejs.org/breaking-changes/migration-build.html`
|
|
|
3671
3605
|
);
|
|
3672
3606
|
}
|
|
3673
3607
|
}
|
|
3674
|
-
updateCssVars(n2);
|
|
3608
|
+
updateCssVars(n2, disabled);
|
|
3675
3609
|
}
|
|
3676
3610
|
},
|
|
3677
3611
|
remove(vnode, parentComponent, parentSuspense, { um: unmount, o: { remove: hostRemove } }, doRemove) {
|
|
@@ -3739,9 +3673,10 @@ Details: https://v3-migration.vuejs.org/breaking-changes/migration-build.html`
|
|
|
3739
3673
|
querySelector
|
|
3740
3674
|
);
|
|
3741
3675
|
if (target) {
|
|
3676
|
+
const disabled = isTeleportDisabled(vnode.props);
|
|
3742
3677
|
const targetNode = target._lpa || target.firstChild;
|
|
3743
3678
|
if (vnode.shapeFlag & 16) {
|
|
3744
|
-
if (
|
|
3679
|
+
if (disabled) {
|
|
3745
3680
|
vnode.anchor = hydrateChildren(
|
|
3746
3681
|
nextSibling(node),
|
|
3747
3682
|
vnode,
|
|
@@ -3782,16 +3717,23 @@ Details: https://v3-migration.vuejs.org/breaking-changes/migration-build.html`
|
|
|
3782
3717
|
);
|
|
3783
3718
|
}
|
|
3784
3719
|
}
|
|
3785
|
-
updateCssVars(vnode);
|
|
3720
|
+
updateCssVars(vnode, disabled);
|
|
3786
3721
|
}
|
|
3787
3722
|
return vnode.anchor && nextSibling(vnode.anchor);
|
|
3788
3723
|
}
|
|
3789
3724
|
const Teleport = TeleportImpl;
|
|
3790
|
-
function updateCssVars(vnode) {
|
|
3725
|
+
function updateCssVars(vnode, isDisabled) {
|
|
3791
3726
|
const ctx = vnode.ctx;
|
|
3792
3727
|
if (ctx && ctx.ut) {
|
|
3793
|
-
let node
|
|
3794
|
-
|
|
3728
|
+
let node, anchor;
|
|
3729
|
+
if (isDisabled) {
|
|
3730
|
+
node = vnode.el;
|
|
3731
|
+
anchor = vnode.anchor;
|
|
3732
|
+
} else {
|
|
3733
|
+
node = vnode.targetStart;
|
|
3734
|
+
anchor = vnode.targetAnchor;
|
|
3735
|
+
}
|
|
3736
|
+
while (node && node !== anchor) {
|
|
3795
3737
|
if (node.nodeType === 1) node.setAttribute("data-v-owner", ctx.uid);
|
|
3796
3738
|
node = node.nextSibling;
|
|
3797
3739
|
}
|
|
@@ -4244,8 +4186,15 @@ Details: https://v3-migration.vuejs.org/breaking-changes/migration-build.html`
|
|
|
4244
4186
|
const setupState = owner.setupState;
|
|
4245
4187
|
const rawSetupState = toRaw(setupState);
|
|
4246
4188
|
const canSetSetupRef = setupState === EMPTY_OBJ ? () => false : (key) => {
|
|
4247
|
-
|
|
4248
|
-
|
|
4189
|
+
{
|
|
4190
|
+
if (hasOwn(rawSetupState, key) && !isRef(rawSetupState[key])) {
|
|
4191
|
+
warn$1(
|
|
4192
|
+
`Template ref "${key}" used on a non-ref value. It will not work in the production build.`
|
|
4193
|
+
);
|
|
4194
|
+
}
|
|
4195
|
+
if (knownTemplateRefs.has(rawSetupState[key])) {
|
|
4196
|
+
return false;
|
|
4197
|
+
}
|
|
4249
4198
|
}
|
|
4250
4199
|
return hasOwn(rawSetupState, key);
|
|
4251
4200
|
};
|
|
@@ -4542,7 +4491,11 @@ Details: https://v3-migration.vuejs.org/breaking-changes/migration-build.html`
|
|
|
4542
4491
|
}
|
|
4543
4492
|
let needCallTransitionHooks = false;
|
|
4544
4493
|
if (isTemplateNode(el)) {
|
|
4545
|
-
needCallTransitionHooks = needTransition(
|
|
4494
|
+
needCallTransitionHooks = needTransition(
|
|
4495
|
+
null,
|
|
4496
|
+
// no need check parentSuspense in hydration
|
|
4497
|
+
transition
|
|
4498
|
+
) && parentComponent && parentComponent.vnode.props && parentComponent.vnode.props.appear;
|
|
4546
4499
|
const content = el.content.firstChild;
|
|
4547
4500
|
if (needCallTransitionHooks) {
|
|
4548
4501
|
transition.beforeEnter(content);
|
|
@@ -4935,6 +4888,8 @@ Server rendered element contains fewer child nodes than client vdom.`
|
|
|
4935
4888
|
}
|
|
4936
4889
|
}
|
|
4937
4890
|
|
|
4891
|
+
const requestIdleCallback = getGlobalThis().requestIdleCallback || ((cb) => setTimeout(cb, 1));
|
|
4892
|
+
const cancelIdleCallback = getGlobalThis().cancelIdleCallback || ((id) => clearTimeout(id));
|
|
4938
4893
|
const hydrateOnIdle = (timeout = 1e4) => (hydrate) => {
|
|
4939
4894
|
const id = requestIdleCallback(hydrate, { timeout });
|
|
4940
4895
|
return () => cancelIdleCallback(id);
|
|
@@ -5922,12 +5877,13 @@ If this is a native custom element, make sure to exclude it from component resol
|
|
|
5922
5877
|
}
|
|
5923
5878
|
openBlock();
|
|
5924
5879
|
const validSlotContent = slot && ensureValidVNode(slot(props));
|
|
5880
|
+
const slotKey = props.key || // slot content array of a dynamic conditional slot may have a branch
|
|
5881
|
+
// key attached in the `createSlots` helper, respect that
|
|
5882
|
+
validSlotContent && validSlotContent.key;
|
|
5925
5883
|
const rendered = createBlock(
|
|
5926
5884
|
Fragment,
|
|
5927
5885
|
{
|
|
5928
|
-
key: (
|
|
5929
|
-
// key attached in the `createSlots` helper, respect that
|
|
5930
|
-
validSlotContent && validSlotContent.key || `_${name}`) + // #7256 force differentiate fallback content from actual content
|
|
5886
|
+
key: (slotKey && !isSymbol(slotKey) ? slotKey : `_${name}`) + // #7256 force differentiate fallback content from actual content
|
|
5931
5887
|
(!validSlotContent && fallback ? "_fb" : "")
|
|
5932
5888
|
},
|
|
5933
5889
|
validSlotContent || (fallback ? fallback() : []),
|
|
@@ -7093,7 +7049,7 @@ If this is a native custom element, make sure to exclude it from component resol
|
|
|
7093
7049
|
return vm;
|
|
7094
7050
|
}
|
|
7095
7051
|
}
|
|
7096
|
-
Vue.version = `2.6.14-compat:${"3.5.
|
|
7052
|
+
Vue.version = `2.6.14-compat:${"3.5.12"}`;
|
|
7097
7053
|
Vue.config = singletonApp.config;
|
|
7098
7054
|
Vue.use = (plugin, ...options) => {
|
|
7099
7055
|
if (plugin && isFunction(plugin.install)) {
|
|
@@ -8081,6 +8037,7 @@ If you want to remount the same app, move your app creation logic into a factory
|
|
|
8081
8037
|
function validateProps(rawProps, props, instance) {
|
|
8082
8038
|
const resolvedValues = toRaw(props);
|
|
8083
8039
|
const options = instance.propsOptions[0];
|
|
8040
|
+
const camelizePropsKey = Object.keys(rawProps).map((key) => camelize(key));
|
|
8084
8041
|
for (const key in options) {
|
|
8085
8042
|
let opt = options[key];
|
|
8086
8043
|
if (opt == null) continue;
|
|
@@ -8089,7 +8046,7 @@ If you want to remount the same app, move your app creation logic into a factory
|
|
|
8089
8046
|
resolvedValues[key],
|
|
8090
8047
|
opt,
|
|
8091
8048
|
shallowReadonly(resolvedValues) ,
|
|
8092
|
-
!
|
|
8049
|
+
!camelizePropsKey.includes(key)
|
|
8093
8050
|
);
|
|
8094
8051
|
}
|
|
8095
8052
|
}
|
|
@@ -9961,19 +9918,19 @@ If you want to remount the same app, move your app creation logic into a factory
|
|
|
9961
9918
|
warn$1(`useModel() called without active instance.`);
|
|
9962
9919
|
return ref();
|
|
9963
9920
|
}
|
|
9964
|
-
|
|
9921
|
+
const camelizedName = camelize(name);
|
|
9922
|
+
if (!i.propsOptions[0][camelizedName]) {
|
|
9965
9923
|
warn$1(`useModel() called with prop "${name}" which is not declared.`);
|
|
9966
9924
|
return ref();
|
|
9967
9925
|
}
|
|
9968
|
-
const camelizedName = camelize(name);
|
|
9969
9926
|
const hyphenatedName = hyphenate(name);
|
|
9970
|
-
const modifiers = getModelModifiers(props,
|
|
9927
|
+
const modifiers = getModelModifiers(props, camelizedName);
|
|
9971
9928
|
const res = customRef((track, trigger) => {
|
|
9972
9929
|
let localValue;
|
|
9973
9930
|
let prevSetValue = EMPTY_OBJ;
|
|
9974
9931
|
let prevEmittedValue;
|
|
9975
9932
|
watchSyncEffect(() => {
|
|
9976
|
-
const propValue = props[
|
|
9933
|
+
const propValue = props[camelizedName];
|
|
9977
9934
|
if (hasChanged(localValue, propValue)) {
|
|
9978
9935
|
localValue = propValue;
|
|
9979
9936
|
trigger();
|
|
@@ -11683,9 +11640,9 @@ Component that was made reactive: `,
|
|
|
11683
11640
|
}
|
|
11684
11641
|
const { setup } = Component;
|
|
11685
11642
|
if (setup) {
|
|
11643
|
+
pauseTracking();
|
|
11686
11644
|
const setupContext = instance.setupContext = setup.length > 1 ? createSetupContext(instance) : null;
|
|
11687
11645
|
const reset = setCurrentInstance(instance);
|
|
11688
|
-
pauseTracking();
|
|
11689
11646
|
const setupResult = callWithErrorHandling(
|
|
11690
11647
|
setup,
|
|
11691
11648
|
instance,
|
|
@@ -11695,10 +11652,13 @@ Component that was made reactive: `,
|
|
|
11695
11652
|
setupContext
|
|
11696
11653
|
]
|
|
11697
11654
|
);
|
|
11655
|
+
const isAsyncSetup = isPromise(setupResult);
|
|
11698
11656
|
resetTracking();
|
|
11699
11657
|
reset();
|
|
11700
|
-
if (
|
|
11701
|
-
|
|
11658
|
+
if ((isAsyncSetup || instance.sp) && !isAsyncWrapper(instance)) {
|
|
11659
|
+
markAsyncBoundary(instance);
|
|
11660
|
+
}
|
|
11661
|
+
if (isAsyncSetup) {
|
|
11702
11662
|
setupResult.then(unsetCurrentInstance, unsetCurrentInstance);
|
|
11703
11663
|
if (isSSR) {
|
|
11704
11664
|
return setupResult.then((resolvedResult) => {
|
|
@@ -12171,7 +12131,7 @@ Component that was made reactive: `,
|
|
|
12171
12131
|
return true;
|
|
12172
12132
|
}
|
|
12173
12133
|
|
|
12174
|
-
const version = "3.5.
|
|
12134
|
+
const version = "3.5.12";
|
|
12175
12135
|
const warn = warn$1 ;
|
|
12176
12136
|
const ErrorTypeStrings = ErrorTypeStrings$1 ;
|
|
12177
12137
|
const devtools = devtools$1 ;
|
|
@@ -12857,7 +12817,7 @@ Component that was made reactive: `,
|
|
|
12857
12817
|
return false;
|
|
12858
12818
|
}
|
|
12859
12819
|
|
|
12860
|
-
function patchDOMProp(el, key, value, parentComponent) {
|
|
12820
|
+
function patchDOMProp(el, key, value, parentComponent, attrName) {
|
|
12861
12821
|
if (key === "innerHTML" || key === "textContent") {
|
|
12862
12822
|
if (value != null) {
|
|
12863
12823
|
el[key] = key === "innerHTML" ? unsafeToTrustedHTML(value) : value;
|
|
@@ -12921,7 +12881,7 @@ Component that was made reactive: `,
|
|
|
12921
12881
|
);
|
|
12922
12882
|
}
|
|
12923
12883
|
}
|
|
12924
|
-
needRemove && el.removeAttribute(key);
|
|
12884
|
+
needRemove && el.removeAttribute(attrName || key);
|
|
12925
12885
|
}
|
|
12926
12886
|
|
|
12927
12887
|
function addEventListener(el, event, handler, options) {
|
|
@@ -13031,7 +12991,7 @@ Expected function or array of functions, received type ${typeof value}.`
|
|
|
13031
12991
|
// #11081 force set props for possible async custom element
|
|
13032
12992
|
el._isVueCE && (/[A-Z]/.test(key) || !isString(nextValue))
|
|
13033
12993
|
) {
|
|
13034
|
-
patchDOMProp(el, camelize(key), nextValue, parentComponent);
|
|
12994
|
+
patchDOMProp(el, camelize(key), nextValue, parentComponent, key);
|
|
13035
12995
|
} else {
|
|
13036
12996
|
if (key === "true-value") {
|
|
13037
12997
|
el._trueValue = nextValue;
|
|
@@ -13746,7 +13706,7 @@ Expected function or array of functions, received type ${typeof value}.`
|
|
|
13746
13706
|
setChecked(el, binding, vnode);
|
|
13747
13707
|
}
|
|
13748
13708
|
};
|
|
13749
|
-
function setChecked(el, { value }, vnode) {
|
|
13709
|
+
function setChecked(el, { value, oldValue }, vnode) {
|
|
13750
13710
|
el._modelValue = value;
|
|
13751
13711
|
let checked;
|
|
13752
13712
|
if (isArray(value)) {
|
|
@@ -13754,6 +13714,7 @@ Expected function or array of functions, received type ${typeof value}.`
|
|
|
13754
13714
|
} else if (isSet(value)) {
|
|
13755
13715
|
checked = value.has(vnode.props.value);
|
|
13756
13716
|
} else {
|
|
13717
|
+
if (value === oldValue) return;
|
|
13757
13718
|
checked = looseEqual(value, getCheckboxValue(el, true));
|
|
13758
13719
|
}
|
|
13759
13720
|
if (el.checked !== checked) {
|