marko 6.0.0-next.3.80 → 6.0.0-next.3.82
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/debug/dom.js +25 -25
- package/dist/debug/dom.mjs +25 -25
- package/dist/dom/scope.d.ts +1 -1
- package/dist/dom.js +21 -25
- package/dist/dom.mjs +21 -25
- package/dist/translator/index.js +9 -8
- package/package.json +1 -1
package/dist/debug/dom.js
CHANGED
@@ -1030,13 +1030,10 @@ function insertBranchBefore(branch, parentNode, nextSibling) {
|
|
1030
1030
|
branch.___endNode
|
1031
1031
|
);
|
1032
1032
|
}
|
1033
|
-
function
|
1034
|
-
|
1035
|
-
|
1036
|
-
|
1037
|
-
branch.___startNode,
|
1038
|
-
branch.___endNode
|
1039
|
-
);
|
1033
|
+
function tempDetachBranch(branch) {
|
1034
|
+
const fragment = new DocumentFragment();
|
1035
|
+
fragment.namespaceURI = branch.___startNode.parentNode.namespaceURI;
|
1036
|
+
insertChildNodes(fragment, null, branch.___startNode, branch.___endNode);
|
1040
1037
|
}
|
1041
1038
|
|
1042
1039
|
// src/dom/reconcile.ts
|
@@ -1619,12 +1616,11 @@ function awaitTag(nodeAccessor, renderer) {
|
|
1619
1616
|
const promiseAccessor = "Promise:" /* Promise */ + nodeAccessor;
|
1620
1617
|
const branchAccessor = "ConditionalScope:" /* ConditionalScope */ + nodeAccessor;
|
1621
1618
|
return (scope, promise) => {
|
1619
|
+
const referenceNode = scope[nodeAccessor];
|
1622
1620
|
const tryWithPlaceholder = findBranchWithKey(
|
1623
1621
|
scope,
|
1624
1622
|
"#PlaceholderContent" /* PlaceholderContent */
|
1625
1623
|
);
|
1626
|
-
const referenceNode = scope[nodeAccessor];
|
1627
|
-
const originalParentNode = referenceNode.parentNode;
|
1628
1624
|
let awaitBranch = scope[branchAccessor];
|
1629
1625
|
if (tryWithPlaceholder) {
|
1630
1626
|
placeholderShown.add(pendingEffects);
|
@@ -1635,18 +1631,17 @@ function awaitTag(nodeAccessor, renderer) {
|
|
1635
1631
|
() => queueRender(
|
1636
1632
|
tryWithPlaceholder,
|
1637
1633
|
() => {
|
1638
|
-
const placeholderBranch = tryWithPlaceholder["#PlaceholderBranch" /* PlaceholderBranch */] = createAndSetupBranch(
|
1639
|
-
scope.$global,
|
1640
|
-
tryWithPlaceholder["#PlaceholderContent" /* PlaceholderContent */],
|
1641
|
-
tryWithPlaceholder._,
|
1642
|
-
tryWithPlaceholder.___startNode.parentNode
|
1643
|
-
);
|
1644
1634
|
insertBranchBefore(
|
1645
|
-
|
1635
|
+
tryWithPlaceholder["#PlaceholderBranch" /* PlaceholderBranch */] = createAndSetupBranch(
|
1636
|
+
scope.$global,
|
1637
|
+
tryWithPlaceholder["#PlaceholderContent" /* PlaceholderContent */],
|
1638
|
+
tryWithPlaceholder._,
|
1639
|
+
tryWithPlaceholder.___startNode.parentNode
|
1640
|
+
),
|
1646
1641
|
tryWithPlaceholder.___startNode.parentNode,
|
1647
1642
|
tryWithPlaceholder.___startNode
|
1648
1643
|
);
|
1649
|
-
|
1644
|
+
tempDetachBranch(tryWithPlaceholder);
|
1650
1645
|
},
|
1651
1646
|
-1
|
1652
1647
|
)
|
@@ -1654,12 +1649,12 @@ function awaitTag(nodeAccessor, renderer) {
|
|
1654
1649
|
)
|
1655
1650
|
);
|
1656
1651
|
}
|
1657
|
-
} else if (awaitBranch) {
|
1652
|
+
} else if (awaitBranch && !scope[promiseAccessor]) {
|
1658
1653
|
awaitBranch.___startNode.parentNode.insertBefore(
|
1659
1654
|
referenceNode,
|
1660
1655
|
awaitBranch.___startNode
|
1661
1656
|
);
|
1662
|
-
|
1657
|
+
tempDetachBranch(awaitBranch);
|
1663
1658
|
}
|
1664
1659
|
const thisPromise = scope[promiseAccessor] = promise.then(
|
1665
1660
|
(data2) => {
|
@@ -1669,13 +1664,19 @@ function awaitTag(nodeAccessor, renderer) {
|
|
1669
1664
|
queueRender(
|
1670
1665
|
scope,
|
1671
1666
|
() => {
|
1672
|
-
if (
|
1667
|
+
if (awaitBranch) {
|
1668
|
+
if (!tryWithPlaceholder) {
|
1669
|
+
referenceNode.replaceWith(
|
1670
|
+
awaitBranch.___startNode.parentNode
|
1671
|
+
);
|
1672
|
+
}
|
1673
|
+
} else {
|
1673
1674
|
insertBranchBefore(
|
1674
|
-
awaitBranch
|
1675
|
+
awaitBranch = scope[branchAccessor] = createAndSetupBranch(
|
1675
1676
|
scope.$global,
|
1676
1677
|
renderer,
|
1677
1678
|
scope,
|
1678
|
-
|
1679
|
+
referenceNode.parentNode
|
1679
1680
|
),
|
1680
1681
|
referenceNode.parentNode,
|
1681
1682
|
referenceNode
|
@@ -1689,9 +1690,8 @@ function awaitTag(nodeAccessor, renderer) {
|
|
1689
1690
|
const placeholderBranch = tryWithPlaceholder["#PlaceholderBranch" /* PlaceholderBranch */];
|
1690
1691
|
tryWithPlaceholder["#PlaceholderBranch" /* PlaceholderBranch */] = 0;
|
1691
1692
|
if (placeholderBranch) {
|
1692
|
-
|
1693
|
-
tryWithPlaceholder,
|
1694
|
-
placeholderBranch.___startNode.parentNode,
|
1693
|
+
placeholderBranch.___startNode.parentNode.insertBefore(
|
1694
|
+
tryWithPlaceholder.___startNode.parentNode,
|
1695
1695
|
placeholderBranch.___startNode
|
1696
1696
|
);
|
1697
1697
|
removeAndDestroyBranch(placeholderBranch);
|
package/dist/debug/dom.mjs
CHANGED
@@ -942,13 +942,10 @@ function insertBranchBefore(branch, parentNode, nextSibling) {
|
|
942
942
|
branch.___endNode
|
943
943
|
);
|
944
944
|
}
|
945
|
-
function
|
946
|
-
|
947
|
-
|
948
|
-
|
949
|
-
branch.___startNode,
|
950
|
-
branch.___endNode
|
951
|
-
);
|
945
|
+
function tempDetachBranch(branch) {
|
946
|
+
const fragment = new DocumentFragment();
|
947
|
+
fragment.namespaceURI = branch.___startNode.parentNode.namespaceURI;
|
948
|
+
insertChildNodes(fragment, null, branch.___startNode, branch.___endNode);
|
952
949
|
}
|
953
950
|
|
954
951
|
// src/dom/reconcile.ts
|
@@ -1531,12 +1528,11 @@ function awaitTag(nodeAccessor, renderer) {
|
|
1531
1528
|
const promiseAccessor = "Promise:" /* Promise */ + nodeAccessor;
|
1532
1529
|
const branchAccessor = "ConditionalScope:" /* ConditionalScope */ + nodeAccessor;
|
1533
1530
|
return (scope, promise) => {
|
1531
|
+
const referenceNode = scope[nodeAccessor];
|
1534
1532
|
const tryWithPlaceholder = findBranchWithKey(
|
1535
1533
|
scope,
|
1536
1534
|
"#PlaceholderContent" /* PlaceholderContent */
|
1537
1535
|
);
|
1538
|
-
const referenceNode = scope[nodeAccessor];
|
1539
|
-
const originalParentNode = referenceNode.parentNode;
|
1540
1536
|
let awaitBranch = scope[branchAccessor];
|
1541
1537
|
if (tryWithPlaceholder) {
|
1542
1538
|
placeholderShown.add(pendingEffects);
|
@@ -1547,18 +1543,17 @@ function awaitTag(nodeAccessor, renderer) {
|
|
1547
1543
|
() => queueRender(
|
1548
1544
|
tryWithPlaceholder,
|
1549
1545
|
() => {
|
1550
|
-
const placeholderBranch = tryWithPlaceholder["#PlaceholderBranch" /* PlaceholderBranch */] = createAndSetupBranch(
|
1551
|
-
scope.$global,
|
1552
|
-
tryWithPlaceholder["#PlaceholderContent" /* PlaceholderContent */],
|
1553
|
-
tryWithPlaceholder._,
|
1554
|
-
tryWithPlaceholder.___startNode.parentNode
|
1555
|
-
);
|
1556
1546
|
insertBranchBefore(
|
1557
|
-
|
1547
|
+
tryWithPlaceholder["#PlaceholderBranch" /* PlaceholderBranch */] = createAndSetupBranch(
|
1548
|
+
scope.$global,
|
1549
|
+
tryWithPlaceholder["#PlaceholderContent" /* PlaceholderContent */],
|
1550
|
+
tryWithPlaceholder._,
|
1551
|
+
tryWithPlaceholder.___startNode.parentNode
|
1552
|
+
),
|
1558
1553
|
tryWithPlaceholder.___startNode.parentNode,
|
1559
1554
|
tryWithPlaceholder.___startNode
|
1560
1555
|
);
|
1561
|
-
|
1556
|
+
tempDetachBranch(tryWithPlaceholder);
|
1562
1557
|
},
|
1563
1558
|
-1
|
1564
1559
|
)
|
@@ -1566,12 +1561,12 @@ function awaitTag(nodeAccessor, renderer) {
|
|
1566
1561
|
)
|
1567
1562
|
);
|
1568
1563
|
}
|
1569
|
-
} else if (awaitBranch) {
|
1564
|
+
} else if (awaitBranch && !scope[promiseAccessor]) {
|
1570
1565
|
awaitBranch.___startNode.parentNode.insertBefore(
|
1571
1566
|
referenceNode,
|
1572
1567
|
awaitBranch.___startNode
|
1573
1568
|
);
|
1574
|
-
|
1569
|
+
tempDetachBranch(awaitBranch);
|
1575
1570
|
}
|
1576
1571
|
const thisPromise = scope[promiseAccessor] = promise.then(
|
1577
1572
|
(data2) => {
|
@@ -1581,13 +1576,19 @@ function awaitTag(nodeAccessor, renderer) {
|
|
1581
1576
|
queueRender(
|
1582
1577
|
scope,
|
1583
1578
|
() => {
|
1584
|
-
if (
|
1579
|
+
if (awaitBranch) {
|
1580
|
+
if (!tryWithPlaceholder) {
|
1581
|
+
referenceNode.replaceWith(
|
1582
|
+
awaitBranch.___startNode.parentNode
|
1583
|
+
);
|
1584
|
+
}
|
1585
|
+
} else {
|
1585
1586
|
insertBranchBefore(
|
1586
|
-
awaitBranch
|
1587
|
+
awaitBranch = scope[branchAccessor] = createAndSetupBranch(
|
1587
1588
|
scope.$global,
|
1588
1589
|
renderer,
|
1589
1590
|
scope,
|
1590
|
-
|
1591
|
+
referenceNode.parentNode
|
1591
1592
|
),
|
1592
1593
|
referenceNode.parentNode,
|
1593
1594
|
referenceNode
|
@@ -1601,9 +1602,8 @@ function awaitTag(nodeAccessor, renderer) {
|
|
1601
1602
|
const placeholderBranch = tryWithPlaceholder["#PlaceholderBranch" /* PlaceholderBranch */];
|
1602
1603
|
tryWithPlaceholder["#PlaceholderBranch" /* PlaceholderBranch */] = 0;
|
1603
1604
|
if (placeholderBranch) {
|
1604
|
-
|
1605
|
-
tryWithPlaceholder,
|
1606
|
-
placeholderBranch.___startNode.parentNode,
|
1605
|
+
placeholderBranch.___startNode.parentNode.insertBefore(
|
1606
|
+
tryWithPlaceholder.___startNode.parentNode,
|
1607
1607
|
placeholderBranch.___startNode
|
1608
1608
|
);
|
1609
1609
|
removeAndDestroyBranch(placeholderBranch);
|
package/dist/dom/scope.d.ts
CHANGED
@@ -6,4 +6,4 @@ export declare function findBranchWithKey(scope: Scope, key: string): BranchScop
|
|
6
6
|
export declare function destroyBranch(branch: BranchScope): void;
|
7
7
|
export declare function removeAndDestroyBranch(branch: BranchScope): void;
|
8
8
|
export declare function insertBranchBefore(branch: BranchScope, parentNode: ParentNode, nextSibling: Node | null): void;
|
9
|
-
export declare function
|
9
|
+
export declare function tempDetachBranch(branch: BranchScope): void;
|
package/dist/dom.js
CHANGED
@@ -752,13 +752,9 @@ function insertBranchBefore(branch, parentNode, nextSibling) {
|
|
752
752
|
branch.j
|
753
753
|
);
|
754
754
|
}
|
755
|
-
function
|
756
|
-
|
757
|
-
|
758
|
-
null,
|
759
|
-
branch.h,
|
760
|
-
branch.j
|
761
|
-
);
|
755
|
+
function tempDetachBranch(branch) {
|
756
|
+
let fragment = new DocumentFragment();
|
757
|
+
fragment.namespaceURI = branch.h.parentNode.namespaceURI, insertChildNodes(fragment, null, branch.h, branch.j);
|
762
758
|
}
|
763
759
|
|
764
760
|
// src/dom/reconcile.ts
|
@@ -1090,55 +1086,55 @@ function hoist(...path) {
|
|
1090
1086
|
function awaitTag(nodeAccessor, renderer) {
|
1091
1087
|
let promiseAccessor = "n" /* Promise */ + nodeAccessor, branchAccessor = "d" /* ConditionalScope */ + nodeAccessor;
|
1092
1088
|
return (scope, promise) => {
|
1093
|
-
let tryWithPlaceholder = findBranchWithKey(
|
1089
|
+
let referenceNode = scope[nodeAccessor], tryWithPlaceholder = findBranchWithKey(
|
1094
1090
|
scope,
|
1095
1091
|
"d" /* PlaceholderContent */
|
1096
|
-
),
|
1092
|
+
), awaitBranch = scope[branchAccessor];
|
1097
1093
|
tryWithPlaceholder ? (placeholderShown.add(pendingEffects), !scope[promiseAccessor] && (tryWithPlaceholder.n = (tryWithPlaceholder.n || 0) + 1) === 1 && requestAnimationFrame(
|
1098
1094
|
() => tryWithPlaceholder.n && runEffects(
|
1099
1095
|
prepareEffects(
|
1100
1096
|
() => queueRender(
|
1101
1097
|
tryWithPlaceholder,
|
1102
1098
|
() => {
|
1103
|
-
let placeholderBranch = tryWithPlaceholder.c = createAndSetupBranch(
|
1104
|
-
scope.$global,
|
1105
|
-
tryWithPlaceholder.d,
|
1106
|
-
tryWithPlaceholder._,
|
1107
|
-
tryWithPlaceholder.h.parentNode
|
1108
|
-
);
|
1109
1099
|
insertBranchBefore(
|
1110
|
-
|
1100
|
+
tryWithPlaceholder.c = createAndSetupBranch(
|
1101
|
+
scope.$global,
|
1102
|
+
tryWithPlaceholder.d,
|
1103
|
+
tryWithPlaceholder._,
|
1104
|
+
tryWithPlaceholder.h.parentNode
|
1105
|
+
),
|
1111
1106
|
tryWithPlaceholder.h.parentNode,
|
1112
1107
|
tryWithPlaceholder.h
|
1113
|
-
),
|
1108
|
+
), tempDetachBranch(tryWithPlaceholder);
|
1114
1109
|
},
|
1115
1110
|
-1
|
1116
1111
|
)
|
1117
1112
|
)
|
1118
1113
|
)
|
1119
|
-
)) : awaitBranch && (awaitBranch.h.parentNode.insertBefore(
|
1114
|
+
)) : awaitBranch && !scope[promiseAccessor] && (awaitBranch.h.parentNode.insertBefore(
|
1120
1115
|
referenceNode,
|
1121
1116
|
awaitBranch.h
|
1122
|
-
),
|
1117
|
+
), tempDetachBranch(awaitBranch));
|
1123
1118
|
let thisPromise = scope[promiseAccessor] = promise.then(
|
1124
1119
|
(data2) => {
|
1125
1120
|
thisPromise === scope[promiseAccessor] && (scope[promiseAccessor] = 0, schedule(), queueRender(
|
1126
1121
|
scope,
|
1127
1122
|
() => {
|
1128
|
-
if (
|
1129
|
-
awaitBranch
|
1123
|
+
if (awaitBranch ? tryWithPlaceholder || referenceNode.replaceWith(
|
1124
|
+
awaitBranch.h.parentNode
|
1125
|
+
) : (insertBranchBefore(
|
1126
|
+
awaitBranch = scope[branchAccessor] = createAndSetupBranch(
|
1130
1127
|
scope.$global,
|
1131
1128
|
renderer,
|
1132
1129
|
scope,
|
1133
|
-
|
1130
|
+
referenceNode.parentNode
|
1134
1131
|
),
|
1135
1132
|
referenceNode.parentNode,
|
1136
1133
|
referenceNode
|
1137
1134
|
), referenceNode.remove()), renderer.l?.(awaitBranch, [data2]), tryWithPlaceholder && (placeholderShown.add(pendingEffects), !--tryWithPlaceholder.n)) {
|
1138
1135
|
let placeholderBranch = tryWithPlaceholder.c;
|
1139
|
-
tryWithPlaceholder.c = 0, placeholderBranch && (
|
1140
|
-
tryWithPlaceholder,
|
1141
|
-
placeholderBranch.h.parentNode,
|
1136
|
+
tryWithPlaceholder.c = 0, placeholderBranch && (placeholderBranch.h.parentNode.insertBefore(
|
1137
|
+
tryWithPlaceholder.h.parentNode,
|
1142
1138
|
placeholderBranch.h
|
1143
1139
|
), removeAndDestroyBranch(placeholderBranch)), tryWithPlaceholder.H && runEffects(tryWithPlaceholder.H, !0);
|
1144
1140
|
}
|
package/dist/dom.mjs
CHANGED
@@ -667,13 +667,9 @@ function insertBranchBefore(branch, parentNode, nextSibling) {
|
|
667
667
|
branch.j
|
668
668
|
);
|
669
669
|
}
|
670
|
-
function
|
671
|
-
|
672
|
-
|
673
|
-
null,
|
674
|
-
branch.h,
|
675
|
-
branch.j
|
676
|
-
);
|
670
|
+
function tempDetachBranch(branch) {
|
671
|
+
let fragment = new DocumentFragment();
|
672
|
+
fragment.namespaceURI = branch.h.parentNode.namespaceURI, insertChildNodes(fragment, null, branch.h, branch.j);
|
677
673
|
}
|
678
674
|
|
679
675
|
// src/dom/reconcile.ts
|
@@ -1005,55 +1001,55 @@ function hoist(...path) {
|
|
1005
1001
|
function awaitTag(nodeAccessor, renderer) {
|
1006
1002
|
let promiseAccessor = "n" /* Promise */ + nodeAccessor, branchAccessor = "d" /* ConditionalScope */ + nodeAccessor;
|
1007
1003
|
return (scope, promise) => {
|
1008
|
-
let tryWithPlaceholder = findBranchWithKey(
|
1004
|
+
let referenceNode = scope[nodeAccessor], tryWithPlaceholder = findBranchWithKey(
|
1009
1005
|
scope,
|
1010
1006
|
"d" /* PlaceholderContent */
|
1011
|
-
),
|
1007
|
+
), awaitBranch = scope[branchAccessor];
|
1012
1008
|
tryWithPlaceholder ? (placeholderShown.add(pendingEffects), !scope[promiseAccessor] && (tryWithPlaceholder.n = (tryWithPlaceholder.n || 0) + 1) === 1 && requestAnimationFrame(
|
1013
1009
|
() => tryWithPlaceholder.n && runEffects(
|
1014
1010
|
prepareEffects(
|
1015
1011
|
() => queueRender(
|
1016
1012
|
tryWithPlaceholder,
|
1017
1013
|
() => {
|
1018
|
-
let placeholderBranch = tryWithPlaceholder.c = createAndSetupBranch(
|
1019
|
-
scope.$global,
|
1020
|
-
tryWithPlaceholder.d,
|
1021
|
-
tryWithPlaceholder._,
|
1022
|
-
tryWithPlaceholder.h.parentNode
|
1023
|
-
);
|
1024
1014
|
insertBranchBefore(
|
1025
|
-
|
1015
|
+
tryWithPlaceholder.c = createAndSetupBranch(
|
1016
|
+
scope.$global,
|
1017
|
+
tryWithPlaceholder.d,
|
1018
|
+
tryWithPlaceholder._,
|
1019
|
+
tryWithPlaceholder.h.parentNode
|
1020
|
+
),
|
1026
1021
|
tryWithPlaceholder.h.parentNode,
|
1027
1022
|
tryWithPlaceholder.h
|
1028
|
-
),
|
1023
|
+
), tempDetachBranch(tryWithPlaceholder);
|
1029
1024
|
},
|
1030
1025
|
-1
|
1031
1026
|
)
|
1032
1027
|
)
|
1033
1028
|
)
|
1034
|
-
)) : awaitBranch && (awaitBranch.h.parentNode.insertBefore(
|
1029
|
+
)) : awaitBranch && !scope[promiseAccessor] && (awaitBranch.h.parentNode.insertBefore(
|
1035
1030
|
referenceNode,
|
1036
1031
|
awaitBranch.h
|
1037
|
-
),
|
1032
|
+
), tempDetachBranch(awaitBranch));
|
1038
1033
|
let thisPromise = scope[promiseAccessor] = promise.then(
|
1039
1034
|
(data2) => {
|
1040
1035
|
thisPromise === scope[promiseAccessor] && (scope[promiseAccessor] = 0, schedule(), queueRender(
|
1041
1036
|
scope,
|
1042
1037
|
() => {
|
1043
|
-
if (
|
1044
|
-
awaitBranch
|
1038
|
+
if (awaitBranch ? tryWithPlaceholder || referenceNode.replaceWith(
|
1039
|
+
awaitBranch.h.parentNode
|
1040
|
+
) : (insertBranchBefore(
|
1041
|
+
awaitBranch = scope[branchAccessor] = createAndSetupBranch(
|
1045
1042
|
scope.$global,
|
1046
1043
|
renderer,
|
1047
1044
|
scope,
|
1048
|
-
|
1045
|
+
referenceNode.parentNode
|
1049
1046
|
),
|
1050
1047
|
referenceNode.parentNode,
|
1051
1048
|
referenceNode
|
1052
1049
|
), referenceNode.remove()), renderer.l?.(awaitBranch, [data2]), tryWithPlaceholder && (placeholderShown.add(pendingEffects), !--tryWithPlaceholder.n)) {
|
1053
1050
|
let placeholderBranch = tryWithPlaceholder.c;
|
1054
|
-
tryWithPlaceholder.c = 0, placeholderBranch && (
|
1055
|
-
tryWithPlaceholder,
|
1056
|
-
placeholderBranch.h.parentNode,
|
1051
|
+
tryWithPlaceholder.c = 0, placeholderBranch && (placeholderBranch.h.parentNode.insertBefore(
|
1052
|
+
tryWithPlaceholder.h.parentNode,
|
1057
1053
|
placeholderBranch.h
|
1058
1054
|
), removeAndDestroyBranch(placeholderBranch)), tryWithPlaceholder.H && runEffects(tryWithPlaceholder.H, !0);
|
1059
1055
|
}
|
package/dist/translator/index.js
CHANGED
@@ -829,6 +829,9 @@ function getContentInfo(path5) {
|
|
829
829
|
const endType = getNodeContentType(body[endIndex], "endType", contentInfo);
|
830
830
|
if (endType !== null) {
|
831
831
|
contentInfo.endType = endType;
|
832
|
+
if (endType === 1 /* Dynamic */) {
|
833
|
+
contentInfo.singleChild = false;
|
834
|
+
}
|
832
835
|
for (let startIndex = 0; startIndex < endIndex; startIndex++) {
|
833
836
|
const startType = getNodeContentType(body[startIndex], "startType");
|
834
837
|
if (startType !== null) {
|
@@ -9796,14 +9799,12 @@ var dynamic_tag_default = {
|
|
9796
9799
|
isClassAPI ? "renderBody" : "content"
|
9797
9800
|
);
|
9798
9801
|
const args = [];
|
9799
|
-
let
|
9800
|
-
if (node.arguments
|
9802
|
+
let hasTagArgs = false;
|
9803
|
+
if (node.arguments) {
|
9804
|
+
hasTagArgs = true;
|
9801
9805
|
args.push(...node.arguments);
|
9802
9806
|
if (properties.length) {
|
9803
|
-
hasMultipleArgs = true;
|
9804
9807
|
args.push(propsToExpression(properties));
|
9805
|
-
} else {
|
9806
|
-
hasMultipleArgs = node.arguments.length > 1 || import_compiler57.types.isSpreadElement(node.arguments[0]);
|
9807
9808
|
}
|
9808
9809
|
} else {
|
9809
9810
|
const contentProp = getTranslatedBodyContentProperty(properties);
|
@@ -9818,7 +9819,7 @@ var dynamic_tag_default = {
|
|
9818
9819
|
flushInto(tag);
|
9819
9820
|
writeHTMLResumeStatements(tag.get("body"));
|
9820
9821
|
const serializeReason = isClassAPI || !!node.var || getDynamicSourcesForExtra(tagExtra);
|
9821
|
-
const dynamicTagExpr =
|
9822
|
+
const dynamicTagExpr = hasTagArgs ? callRuntime(
|
9822
9823
|
"dynamicTag",
|
9823
9824
|
getScopeIdIdentifier(section),
|
9824
9825
|
getScopeAccessorLiteral(nodeRef2),
|
@@ -9906,11 +9907,11 @@ var dynamic_tag_default = {
|
|
9906
9907
|
getScopeAccessorLiteral(nodeRef2),
|
9907
9908
|
bodySection && import_compiler57.types.identifier(bodySection.name),
|
9908
9909
|
tagVarSignal ? import_compiler57.types.arrowFunctionExpression([], tagVarSignal.identifier) : void 0,
|
9909
|
-
|
9910
|
+
hasTagArgs && import_compiler57.types.numericLiteral(1)
|
9910
9911
|
);
|
9911
9912
|
};
|
9912
9913
|
if (args.length) {
|
9913
|
-
const argsOrInput =
|
9914
|
+
const argsOrInput = hasTagArgs ? import_compiler57.types.arrayExpression(args) : args[0];
|
9914
9915
|
if (!import_compiler57.types.isObjectExpression(argsOrInput) || argsOrInput.properties.length) {
|
9915
9916
|
signal.extraArgs = [
|
9916
9917
|
import_compiler57.types.arrowFunctionExpression(
|