marko 6.0.0-next.3.37 → 6.0.0-next.3.38
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 +48 -54
- package/dist/debug/dom.mjs +48 -54
- package/dist/dom/compat.d.ts +2 -2
- package/dist/dom/control-flow.d.ts +4 -5
- package/dist/dom/signals.d.ts +1 -2
- package/dist/dom.d.ts +1 -1
- package/dist/dom.js +67 -67
- package/dist/dom.mjs +67 -67
- package/dist/translator/core/for.d.ts +0 -9
- package/dist/translator/core/if.d.ts +0 -8
- package/dist/translator/index.js +549 -549
- package/dist/translator/util/is-only-child-in-parent.d.ts +14 -0
- package/package.json +1 -1
package/dist/debug/dom.js
CHANGED
@@ -29,7 +29,6 @@ __export(dom_exports, {
|
|
29
29
|
compat: () => compat,
|
30
30
|
conditional: () => conditional,
|
31
31
|
conditionalClosure: () => conditionalClosure,
|
32
|
-
conditionalOnlyChild: () => conditionalOnlyChild,
|
33
32
|
controllable_detailsOrDialog_open: () => controllable_detailsOrDialog_open,
|
34
33
|
controllable_detailsOrDialog_open_effect: () => controllable_detailsOrDialog_open_effect,
|
35
34
|
controllable_input_checked: () => controllable_input_checked,
|
@@ -47,6 +46,7 @@ __export(dom_exports, {
|
|
47
46
|
createTemplate: () => createTemplate,
|
48
47
|
data: () => data,
|
49
48
|
dynamicClosure: () => dynamicClosure,
|
49
|
+
dynamicTag: () => dynamicTag,
|
50
50
|
dynamicTagAttrs: () => dynamicTagAttrs,
|
51
51
|
effect: () => effect,
|
52
52
|
forIn: () => forIn,
|
@@ -1415,7 +1415,12 @@ function dynamicTagAttrs(nodeAccessor, getContent, inputIsArgs) {
|
|
1415
1415
|
"A dynamic tag rendering a `<textarea>` cannot have `content` and must use the `value` attribute instead."
|
1416
1416
|
);
|
1417
1417
|
}
|
1418
|
-
setConditionalRendererOnlyChild(
|
1418
|
+
setConditionalRendererOnlyChild(
|
1419
|
+
childScope,
|
1420
|
+
nodeAccessor2,
|
1421
|
+
content,
|
1422
|
+
createBranchScopeWithTagNameOrRenderer
|
1423
|
+
);
|
1419
1424
|
attrs(childScope, nodeAccessor2, attrsOrOp());
|
1420
1425
|
} else if (renderer.___args) {
|
1421
1426
|
const attributes = attrsOrOp();
|
@@ -1467,11 +1472,23 @@ function createCloneableHTML(html2, ns) {
|
|
1467
1472
|
}
|
1468
1473
|
|
1469
1474
|
// src/dom/control-flow.ts
|
1470
|
-
function
|
1471
|
-
|
1472
|
-
|
1475
|
+
function conditional(nodeAccessor, ...branches) {
|
1476
|
+
const branchAccessor = nodeAccessor + "(" /* ConditionalRenderer */;
|
1477
|
+
return (scope, newBranchIndexOrOp) => {
|
1478
|
+
if (newBranchIndexOrOp !== scope[branchAccessor] && newBranchIndexOrOp !== DIRTY && newBranchIndexOrOp !== MARK && newBranchIndexOrOp !== CLEAN) {
|
1479
|
+
(scope[nodeAccessor].nodeType > 1 /* Element */ ? setConditionalRenderer : setConditionalRendererOnlyChild)(
|
1480
|
+
scope,
|
1481
|
+
nodeAccessor,
|
1482
|
+
branches[scope[branchAccessor] = newBranchIndexOrOp],
|
1483
|
+
createBranchScopeWithRenderer
|
1484
|
+
);
|
1485
|
+
}
|
1486
|
+
};
|
1487
|
+
}
|
1488
|
+
function patchDynamicTag(fn) {
|
1489
|
+
dynamicTag = fn(dynamicTag);
|
1473
1490
|
}
|
1474
|
-
var
|
1491
|
+
var dynamicTag = function dynamicTag2(nodeAccessor, fn, getIntersection) {
|
1475
1492
|
const rendererAccessor = nodeAccessor + "(" /* ConditionalRenderer */;
|
1476
1493
|
let intersection2 = getIntersection && ((scope, op) => (intersection2 = getIntersection())(scope, op));
|
1477
1494
|
return (scope, newRendererOrOp) => {
|
@@ -1482,7 +1499,12 @@ var conditional = function conditional2(nodeAccessor, fn, getIntersection) {
|
|
1482
1499
|
const normalizedRenderer = normalizeDynamicRenderer(newRendererOrOp);
|
1483
1500
|
if (isDifferentRenderer(normalizedRenderer, currentRenderer)) {
|
1484
1501
|
scope[rendererAccessor] = normalizedRenderer;
|
1485
|
-
setConditionalRenderer(
|
1502
|
+
setConditionalRenderer(
|
1503
|
+
scope,
|
1504
|
+
nodeAccessor,
|
1505
|
+
normalizedRenderer,
|
1506
|
+
createBranchScopeWithTagNameOrRenderer
|
1507
|
+
);
|
1486
1508
|
fn && fn(scope);
|
1487
1509
|
op = DIRTY;
|
1488
1510
|
} else {
|
@@ -1492,56 +1514,28 @@ var conditional = function conditional2(nodeAccessor, fn, getIntersection) {
|
|
1492
1514
|
intersection2?.(scope, op);
|
1493
1515
|
};
|
1494
1516
|
};
|
1495
|
-
function setConditionalRenderer(scope, nodeAccessor, newRenderer) {
|
1517
|
+
function setConditionalRenderer(scope, nodeAccessor, newRenderer, createBranch2) {
|
1496
1518
|
const prevBranch = scope[nodeAccessor + "!" /* ConditionalScope */] || getEmptyBranch(scope[nodeAccessor]);
|
1497
|
-
const newBranch = newRenderer ?
|
1519
|
+
const newBranch = newRenderer ? createBranch2(
|
1498
1520
|
newRenderer,
|
1499
1521
|
scope.$global,
|
1500
1522
|
scope,
|
1501
1523
|
prevBranch.___endNode.parentNode
|
1502
1524
|
) : getEmptyBranch(scope[nodeAccessor]);
|
1503
|
-
|
1504
|
-
|
1505
|
-
|
1506
|
-
|
1507
|
-
|
1508
|
-
|
1509
|
-
|
1525
|
+
if (prevBranch !== newBranch) {
|
1526
|
+
insertBranchBefore(
|
1527
|
+
newBranch,
|
1528
|
+
prevBranch.___endNode.parentNode,
|
1529
|
+
prevBranch.___endNode.nextSibling
|
1530
|
+
);
|
1531
|
+
removeAndDestroyBranch(prevBranch);
|
1532
|
+
scope[nodeAccessor + "!" /* ConditionalScope */] = newRenderer && newBranch;
|
1533
|
+
}
|
1510
1534
|
}
|
1511
|
-
|
1512
|
-
const rendererAccessor = nodeAccessor + "(" /* ConditionalRenderer */;
|
1513
|
-
let intersection2 = getIntersection && ((scope, op) => (intersection2 = getIntersection())(scope, op));
|
1514
|
-
return (scope, newRendererOrOp) => {
|
1515
|
-
if (newRendererOrOp === DIRTY) return;
|
1516
|
-
let currentRenderer = scope[rendererAccessor];
|
1517
|
-
let op = newRendererOrOp;
|
1518
|
-
if (newRendererOrOp !== MARK && newRendererOrOp !== CLEAN) {
|
1519
|
-
const normalizedRenderer = normalizeDynamicRenderer(newRendererOrOp);
|
1520
|
-
if (isDifferentRenderer(normalizedRenderer, currentRenderer)) {
|
1521
|
-
currentRenderer = scope[rendererAccessor] = normalizedRenderer;
|
1522
|
-
setConditionalRendererOnlyChild(
|
1523
|
-
scope,
|
1524
|
-
nodeAccessor,
|
1525
|
-
normalizedRenderer
|
1526
|
-
);
|
1527
|
-
fn && fn(scope);
|
1528
|
-
op = DIRTY;
|
1529
|
-
} else {
|
1530
|
-
op = CLEAN;
|
1531
|
-
}
|
1532
|
-
}
|
1533
|
-
intersection2?.(scope, op);
|
1534
|
-
};
|
1535
|
-
};
|
1536
|
-
function setConditionalRendererOnlyChild(scope, nodeAccessor, newRenderer) {
|
1535
|
+
function setConditionalRendererOnlyChild(scope, nodeAccessor, newRenderer, createBranch2) {
|
1537
1536
|
const prevBranch = scope[nodeAccessor + "!" /* ConditionalScope */];
|
1538
1537
|
const referenceNode = scope[nodeAccessor];
|
1539
|
-
const newBranch = newRenderer &&
|
1540
|
-
newRenderer,
|
1541
|
-
scope.$global,
|
1542
|
-
scope,
|
1543
|
-
referenceNode
|
1544
|
-
);
|
1538
|
+
const newBranch = newRenderer && createBranch2(newRenderer, scope.$global, scope, referenceNode);
|
1545
1539
|
referenceNode.textContent = "";
|
1546
1540
|
if (newBranch) {
|
1547
1541
|
insertBranchBefore(newBranch, referenceNode, null);
|
@@ -1771,14 +1765,14 @@ function loopClosure(ownerLoopNodeAccessor, fn, getIntersection) {
|
|
1771
1765
|
helperSignal._ = signal;
|
1772
1766
|
return helperSignal;
|
1773
1767
|
}
|
1774
|
-
function conditionalClosure(ownerConditionalNodeAccessor,
|
1768
|
+
function conditionalClosure(ownerConditionalNodeAccessor, branch, fn, getIntersection) {
|
1775
1769
|
const signal = closure(fn, getIntersection);
|
1776
1770
|
const scopeAccessor = ownerConditionalNodeAccessor + "!" /* ConditionalScope */;
|
1777
|
-
const
|
1771
|
+
const branchAccessor = ownerConditionalNodeAccessor + "(" /* ConditionalRenderer */;
|
1778
1772
|
const helperSignal = (scope, value2) => {
|
1779
|
-
const
|
1780
|
-
if (
|
1781
|
-
queueSource(
|
1773
|
+
const ifScope = scope[scopeAccessor];
|
1774
|
+
if (ifScope && !ifScope.___pending && scope[branchAccessor] === branch) {
|
1775
|
+
queueSource(ifScope, signal, value2);
|
1782
1776
|
}
|
1783
1777
|
};
|
1784
1778
|
helperSignal._ = signal;
|
@@ -1980,7 +1974,7 @@ var RENDER_BODY_ID = prefix + (true ? "renderBody" : "b");
|
|
1980
1974
|
// src/dom/compat.ts
|
1981
1975
|
var classIdToBranch = /* @__PURE__ */ new Map();
|
1982
1976
|
var compat = {
|
1983
|
-
patchConditionals,
|
1977
|
+
patchConditionals: patchDynamicTag,
|
1984
1978
|
queueEffect,
|
1985
1979
|
init(warp10Noop) {
|
1986
1980
|
register(SET_SCOPE_REGISTER_ID, (branch) => {
|
package/dist/debug/dom.mjs
CHANGED
@@ -1329,7 +1329,12 @@ function dynamicTagAttrs(nodeAccessor, getContent, inputIsArgs) {
|
|
1329
1329
|
"A dynamic tag rendering a `<textarea>` cannot have `content` and must use the `value` attribute instead."
|
1330
1330
|
);
|
1331
1331
|
}
|
1332
|
-
setConditionalRendererOnlyChild(
|
1332
|
+
setConditionalRendererOnlyChild(
|
1333
|
+
childScope,
|
1334
|
+
nodeAccessor2,
|
1335
|
+
content,
|
1336
|
+
createBranchScopeWithTagNameOrRenderer
|
1337
|
+
);
|
1333
1338
|
attrs(childScope, nodeAccessor2, attrsOrOp());
|
1334
1339
|
} else if (renderer.___args) {
|
1335
1340
|
const attributes = attrsOrOp();
|
@@ -1381,11 +1386,23 @@ function createCloneableHTML(html2, ns) {
|
|
1381
1386
|
}
|
1382
1387
|
|
1383
1388
|
// src/dom/control-flow.ts
|
1384
|
-
function
|
1385
|
-
|
1386
|
-
|
1389
|
+
function conditional(nodeAccessor, ...branches) {
|
1390
|
+
const branchAccessor = nodeAccessor + "(" /* ConditionalRenderer */;
|
1391
|
+
return (scope, newBranchIndexOrOp) => {
|
1392
|
+
if (newBranchIndexOrOp !== scope[branchAccessor] && newBranchIndexOrOp !== DIRTY && newBranchIndexOrOp !== MARK && newBranchIndexOrOp !== CLEAN) {
|
1393
|
+
(scope[nodeAccessor].nodeType > 1 /* Element */ ? setConditionalRenderer : setConditionalRendererOnlyChild)(
|
1394
|
+
scope,
|
1395
|
+
nodeAccessor,
|
1396
|
+
branches[scope[branchAccessor] = newBranchIndexOrOp],
|
1397
|
+
createBranchScopeWithRenderer
|
1398
|
+
);
|
1399
|
+
}
|
1400
|
+
};
|
1401
|
+
}
|
1402
|
+
function patchDynamicTag(fn) {
|
1403
|
+
dynamicTag = fn(dynamicTag);
|
1387
1404
|
}
|
1388
|
-
var
|
1405
|
+
var dynamicTag = function dynamicTag2(nodeAccessor, fn, getIntersection) {
|
1389
1406
|
const rendererAccessor = nodeAccessor + "(" /* ConditionalRenderer */;
|
1390
1407
|
let intersection2 = getIntersection && ((scope, op) => (intersection2 = getIntersection())(scope, op));
|
1391
1408
|
return (scope, newRendererOrOp) => {
|
@@ -1396,7 +1413,12 @@ var conditional = function conditional2(nodeAccessor, fn, getIntersection) {
|
|
1396
1413
|
const normalizedRenderer = normalizeDynamicRenderer(newRendererOrOp);
|
1397
1414
|
if (isDifferentRenderer(normalizedRenderer, currentRenderer)) {
|
1398
1415
|
scope[rendererAccessor] = normalizedRenderer;
|
1399
|
-
setConditionalRenderer(
|
1416
|
+
setConditionalRenderer(
|
1417
|
+
scope,
|
1418
|
+
nodeAccessor,
|
1419
|
+
normalizedRenderer,
|
1420
|
+
createBranchScopeWithTagNameOrRenderer
|
1421
|
+
);
|
1400
1422
|
fn && fn(scope);
|
1401
1423
|
op = DIRTY;
|
1402
1424
|
} else {
|
@@ -1406,56 +1428,28 @@ var conditional = function conditional2(nodeAccessor, fn, getIntersection) {
|
|
1406
1428
|
intersection2?.(scope, op);
|
1407
1429
|
};
|
1408
1430
|
};
|
1409
|
-
function setConditionalRenderer(scope, nodeAccessor, newRenderer) {
|
1431
|
+
function setConditionalRenderer(scope, nodeAccessor, newRenderer, createBranch2) {
|
1410
1432
|
const prevBranch = scope[nodeAccessor + "!" /* ConditionalScope */] || getEmptyBranch(scope[nodeAccessor]);
|
1411
|
-
const newBranch = newRenderer ?
|
1433
|
+
const newBranch = newRenderer ? createBranch2(
|
1412
1434
|
newRenderer,
|
1413
1435
|
scope.$global,
|
1414
1436
|
scope,
|
1415
1437
|
prevBranch.___endNode.parentNode
|
1416
1438
|
) : getEmptyBranch(scope[nodeAccessor]);
|
1417
|
-
|
1418
|
-
|
1419
|
-
|
1420
|
-
|
1421
|
-
|
1422
|
-
|
1423
|
-
|
1439
|
+
if (prevBranch !== newBranch) {
|
1440
|
+
insertBranchBefore(
|
1441
|
+
newBranch,
|
1442
|
+
prevBranch.___endNode.parentNode,
|
1443
|
+
prevBranch.___endNode.nextSibling
|
1444
|
+
);
|
1445
|
+
removeAndDestroyBranch(prevBranch);
|
1446
|
+
scope[nodeAccessor + "!" /* ConditionalScope */] = newRenderer && newBranch;
|
1447
|
+
}
|
1424
1448
|
}
|
1425
|
-
|
1426
|
-
const rendererAccessor = nodeAccessor + "(" /* ConditionalRenderer */;
|
1427
|
-
let intersection2 = getIntersection && ((scope, op) => (intersection2 = getIntersection())(scope, op));
|
1428
|
-
return (scope, newRendererOrOp) => {
|
1429
|
-
if (newRendererOrOp === DIRTY) return;
|
1430
|
-
let currentRenderer = scope[rendererAccessor];
|
1431
|
-
let op = newRendererOrOp;
|
1432
|
-
if (newRendererOrOp !== MARK && newRendererOrOp !== CLEAN) {
|
1433
|
-
const normalizedRenderer = normalizeDynamicRenderer(newRendererOrOp);
|
1434
|
-
if (isDifferentRenderer(normalizedRenderer, currentRenderer)) {
|
1435
|
-
currentRenderer = scope[rendererAccessor] = normalizedRenderer;
|
1436
|
-
setConditionalRendererOnlyChild(
|
1437
|
-
scope,
|
1438
|
-
nodeAccessor,
|
1439
|
-
normalizedRenderer
|
1440
|
-
);
|
1441
|
-
fn && fn(scope);
|
1442
|
-
op = DIRTY;
|
1443
|
-
} else {
|
1444
|
-
op = CLEAN;
|
1445
|
-
}
|
1446
|
-
}
|
1447
|
-
intersection2?.(scope, op);
|
1448
|
-
};
|
1449
|
-
};
|
1450
|
-
function setConditionalRendererOnlyChild(scope, nodeAccessor, newRenderer) {
|
1449
|
+
function setConditionalRendererOnlyChild(scope, nodeAccessor, newRenderer, createBranch2) {
|
1451
1450
|
const prevBranch = scope[nodeAccessor + "!" /* ConditionalScope */];
|
1452
1451
|
const referenceNode = scope[nodeAccessor];
|
1453
|
-
const newBranch = newRenderer &&
|
1454
|
-
newRenderer,
|
1455
|
-
scope.$global,
|
1456
|
-
scope,
|
1457
|
-
referenceNode
|
1458
|
-
);
|
1452
|
+
const newBranch = newRenderer && createBranch2(newRenderer, scope.$global, scope, referenceNode);
|
1459
1453
|
referenceNode.textContent = "";
|
1460
1454
|
if (newBranch) {
|
1461
1455
|
insertBranchBefore(newBranch, referenceNode, null);
|
@@ -1685,14 +1679,14 @@ function loopClosure(ownerLoopNodeAccessor, fn, getIntersection) {
|
|
1685
1679
|
helperSignal._ = signal;
|
1686
1680
|
return helperSignal;
|
1687
1681
|
}
|
1688
|
-
function conditionalClosure(ownerConditionalNodeAccessor,
|
1682
|
+
function conditionalClosure(ownerConditionalNodeAccessor, branch, fn, getIntersection) {
|
1689
1683
|
const signal = closure(fn, getIntersection);
|
1690
1684
|
const scopeAccessor = ownerConditionalNodeAccessor + "!" /* ConditionalScope */;
|
1691
|
-
const
|
1685
|
+
const branchAccessor = ownerConditionalNodeAccessor + "(" /* ConditionalRenderer */;
|
1692
1686
|
const helperSignal = (scope, value2) => {
|
1693
|
-
const
|
1694
|
-
if (
|
1695
|
-
queueSource(
|
1687
|
+
const ifScope = scope[scopeAccessor];
|
1688
|
+
if (ifScope && !ifScope.___pending && scope[branchAccessor] === branch) {
|
1689
|
+
queueSource(ifScope, signal, value2);
|
1696
1690
|
}
|
1697
1691
|
};
|
1698
1692
|
helperSignal._ = signal;
|
@@ -1894,7 +1888,7 @@ var RENDER_BODY_ID = prefix + (true ? "renderBody" : "b");
|
|
1894
1888
|
// src/dom/compat.ts
|
1895
1889
|
var classIdToBranch = /* @__PURE__ */ new Map();
|
1896
1890
|
var compat = {
|
1897
|
-
patchConditionals,
|
1891
|
+
patchConditionals: patchDynamicTag,
|
1898
1892
|
queueEffect,
|
1899
1893
|
init(warp10Noop) {
|
1900
1894
|
register(SET_SCOPE_REGISTER_ID, (branch) => {
|
@@ -2064,7 +2058,6 @@ export {
|
|
2064
2058
|
compat,
|
2065
2059
|
conditional,
|
2066
2060
|
conditionalClosure,
|
2067
|
-
conditionalOnlyChild,
|
2068
2061
|
controllable_detailsOrDialog_open,
|
2069
2062
|
controllable_detailsOrDialog_open_effect,
|
2070
2063
|
controllable_input_checked,
|
@@ -2082,6 +2075,7 @@ export {
|
|
2082
2075
|
createTemplate,
|
2083
2076
|
data,
|
2084
2077
|
dynamicClosure,
|
2078
|
+
dynamicTag,
|
2085
2079
|
dynamicTagAttrs,
|
2086
2080
|
effect,
|
2087
2081
|
forIn,
|
package/dist/dom/compat.d.ts
CHANGED
@@ -1,8 +1,8 @@
|
|
1
|
-
import {
|
1
|
+
import { patchDynamicTag } from "./control-flow";
|
2
2
|
import { queueEffect } from "./queue";
|
3
3
|
import { type Renderer } from "./renderer";
|
4
4
|
export declare const compat: {
|
5
|
-
patchConditionals: typeof
|
5
|
+
patchConditionals: typeof patchDynamicTag;
|
6
6
|
queueEffect: typeof queueEffect;
|
7
7
|
init(warp10Noop: any): void;
|
8
8
|
registerRenderer(fn: any): void;
|
@@ -1,11 +1,10 @@
|
|
1
1
|
import { type Accessor, type BranchScope, type Scope } from "../common/types";
|
2
2
|
import { type Renderer } from "./renderer";
|
3
3
|
import { type Signal, type SignalOp } from "./signals";
|
4
|
-
export declare function
|
5
|
-
export declare
|
6
|
-
export declare
|
7
|
-
export declare
|
8
|
-
export declare function setConditionalRendererOnlyChild(scope: Scope, nodeAccessor: Accessor, newRenderer: Renderer | string | undefined): void;
|
4
|
+
export declare function conditional(nodeAccessor: Accessor, ...branches: Renderer[]): Signal<number>;
|
5
|
+
export declare function patchDynamicTag(fn: <T extends typeof dynamicTag>(cond: T) => T): void;
|
6
|
+
export declare let dynamicTag: (nodeAccessor: Accessor, fn?: ((scope: Scope) => void) | 0, getIntersection?: () => Signal<never>) => Signal<Renderer | string | undefined>;
|
7
|
+
export declare function setConditionalRendererOnlyChild<T>(scope: Scope, nodeAccessor: Accessor, newRenderer: T, createBranch: (renderer: NonNullable<T>, $global: Scope["$global"], parentScope: Scope, parentNode: ParentNode) => BranchScope): void;
|
9
8
|
export declare const emptyMarkerArray: BranchScope[];
|
10
9
|
export declare function loopOf(nodeAccessor: Accessor, renderer: Renderer): (scope: Scope, valueOrOp: SignalOp | [all: unknown[], by?: ((item: unknown, index: number) => unknown) | undefined]) => void;
|
11
10
|
export declare function loopIn(nodeAccessor: Accessor, renderer: Renderer): (scope: Scope, valueOrOp: SignalOp | [obj: {}, by?: ((key: string, v: unknown) => unknown) | undefined]) => void;
|
package/dist/dom/signals.d.ts
CHANGED
@@ -1,5 +1,4 @@
|
|
1
1
|
import { type Accessor, type Scope } from "../common/types";
|
2
|
-
import type { Renderer } from "./renderer";
|
3
2
|
export declare const MARK: unique symbol;
|
4
3
|
export declare const CLEAN: unique symbol;
|
5
4
|
export declare const DIRTY: unique symbol;
|
@@ -13,7 +12,7 @@ export declare function value<T>(valueAccessor: Accessor, fn: SignalFn<T> | 0, g
|
|
13
12
|
export declare function intersection(count: number, fn: SignalFn<never>, getIntersection?: () => Signal<never>): Signal<never>;
|
14
13
|
export declare function closure<T>(fn: SignalFn<T> | 0, getIntersection?: () => Signal<never>): Signal<T>;
|
15
14
|
export declare function loopClosure<T>(ownerLoopNodeAccessor: Accessor, fn: SignalFn<T> | 0, getIntersection?: () => Signal<never>): SignalFn<T>;
|
16
|
-
export declare function conditionalClosure<T>(ownerConditionalNodeAccessor: Accessor,
|
15
|
+
export declare function conditionalClosure<T>(ownerConditionalNodeAccessor: Accessor, branch: number, fn: SignalFn<T> | 0, getIntersection?: () => Signal<never>): SignalFn<T>;
|
17
16
|
export declare function dynamicClosure<T>(fn: Signal<T> | 0, getOwnerScope?: (scope: Scope) => Scope, getIntersection?: () => Signal<never>): SignalFn<T>;
|
18
17
|
export declare function setTagVar(scope: Scope, childAccessor: Accessor, tagVarSignal: Signal<unknown>): void;
|
19
18
|
export declare const tagVarSignal: (scope: Scope, valueOrOp: unknown | SignalOp) => any;
|
package/dist/dom.d.ts
CHANGED
@@ -2,7 +2,7 @@ export { attrTag, attrTags } from "./common/attr-tag";
|
|
2
2
|
export { forIn, forOf, forTo } from "./common/for";
|
3
3
|
export { getAbortSignal, resetAbortSignal } from "./dom/abort-signal";
|
4
4
|
export { compat } from "./dom/compat";
|
5
|
-
export { conditional,
|
5
|
+
export { conditional, dynamicTag, loopIn, loopOf, loopTo, } from "./dom/control-flow";
|
6
6
|
export { controllable_detailsOrDialog_open, controllable_detailsOrDialog_open_effect, controllable_input_checked, controllable_input_checked_effect, controllable_input_checkedValue, controllable_input_checkedValue_effect, controllable_input_value, controllable_input_value_effect, controllable_select_value, controllable_select_value_effect, controllable_textarea_value, controllable_textarea_value_effect, } from "./dom/controllable";
|
7
7
|
export { attr, attrs, attrsEvents, classAttr, data, html, lifecycle, partialAttrs, props, styleAttr, textContent, } from "./dom/dom";
|
8
8
|
export { on } from "./dom/event";
|