ripple 0.3.65 → 0.3.66
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/CHANGELOG.md +37 -0
- package/package.json +3 -3
- package/src/jsx-runtime.d.ts +17 -3
- package/src/runtime/index-client.js +47 -8
- package/src/runtime/index-server.js +0 -2
- package/src/runtime/internal/client/index.js +5 -0
- package/src/runtime/internal/client/runtime.js +111 -11
- package/src/runtime/internal/client/types.d.ts +5 -0
- package/src/runtime/internal/server/blocks.js +1 -0
- package/src/runtime/internal/server/index.js +175 -20
- package/src/utils/errors.js +13 -0
- package/tests/client/async-suspend.test.tsrx +2 -2
- package/tests/client/basic/basic.get-set.test.tsrx +26 -26
- package/tests/client/compiler/__snapshots__/compiler.assignments.test.rsrx.snap +1 -1
- package/tests/client/compiler/__snapshots__/compiler.assignments.test.tsrx.snap +1 -1
- package/tests/client/compiler/compiler.assignments.test.tsrx +80 -0
- package/tests/client/compiler/compiler.tracked-access.test.tsrx +52 -8
- package/tests/client/compiler/compiler.typescript.test.tsrx +23 -0
- package/tests/client/lazy-array.test.tsrx +34 -0
- package/tests/client/lazy-destructuring.test.tsrx +79 -8
- package/tests/client/tracked-index-access.test.tsrx +113 -0
- package/tests/hydration/compiled/client/basic.js +2 -2
- package/tests/hydration/compiled/client/events.js +9 -9
- package/tests/hydration/compiled/client/for.js +50 -54
- package/tests/hydration/compiled/client/head.js +9 -9
- package/tests/hydration/compiled/client/hmr.js +1 -1
- package/tests/hydration/compiled/client/html.js +2 -2
- package/tests/hydration/compiled/client/if-children.js +14 -14
- package/tests/hydration/compiled/client/if.js +10 -10
- package/tests/hydration/compiled/client/mixed-control-flow.js +7 -7
- package/tests/hydration/compiled/client/portal.js +2 -2
- package/tests/hydration/compiled/client/reactivity.js +7 -7
- package/tests/hydration/compiled/client/return.js +37 -37
- package/tests/hydration/compiled/client/switch.js +8 -8
- package/tests/hydration/compiled/client/track-async-serialization.js +12 -12
- package/tests/hydration/compiled/client/try.js +116 -33
- package/tests/hydration/compiled/server/basic.js +2 -2
- package/tests/hydration/compiled/server/events.js +8 -8
- package/tests/hydration/compiled/server/for.js +21 -21
- package/tests/hydration/compiled/server/head.js +10 -10
- package/tests/hydration/compiled/server/hmr.js +1 -1
- package/tests/hydration/compiled/server/html.js +1 -1
- package/tests/hydration/compiled/server/if-children.js +9 -9
- package/tests/hydration/compiled/server/if.js +6 -6
- package/tests/hydration/compiled/server/mixed-control-flow.js +4 -4
- package/tests/hydration/compiled/server/portal.js +1 -1
- package/tests/hydration/compiled/server/reactivity.js +7 -7
- package/tests/hydration/compiled/server/return.js +14 -14
- package/tests/hydration/compiled/server/switch.js +4 -4
- package/tests/hydration/compiled/server/track-async-serialization.js +12 -12
- package/tests/hydration/compiled/server/try.js +116 -4
- package/tests/hydration/components/try.tsrx +26 -0
- package/tests/hydration/try.test.js +100 -1
- package/tests/server/await.test.tsrx +1 -1
- package/tests/server/compiler.test.tsrx +109 -0
- package/tests/server/lazy-destructuring.test.tsrx +62 -0
- package/tests/server/tracked-index-access.test.tsrx +76 -0
- package/tests/setup-hydration.js +31 -0
- package/types/index.d.ts +11 -9
- package/types/server.d.ts +2 -1
|
@@ -107,7 +107,7 @@ export function ReactiveIf(__anchor, _, __block) {
|
|
|
107
107
|
var button_1 = _$_.first_child_frag(fragment_3);
|
|
108
108
|
|
|
109
109
|
button_1.__click = () => {
|
|
110
|
-
_$_.set(lazy, !
|
|
110
|
+
_$_.set(lazy, !lazy.value);
|
|
111
111
|
};
|
|
112
112
|
|
|
113
113
|
var node_3 = _$_.sibling(button_1);
|
|
@@ -120,7 +120,7 @@ export function ReactiveIf(__anchor, _, __block) {
|
|
|
120
120
|
};
|
|
121
121
|
|
|
122
122
|
_$_.if(node_3, (__render) => {
|
|
123
|
-
if (
|
|
123
|
+
if (lazy.value) __render(consequent_3);
|
|
124
124
|
});
|
|
125
125
|
}
|
|
126
126
|
|
|
@@ -136,7 +136,7 @@ export function ReactiveIfElse(__anchor, _, __block) {
|
|
|
136
136
|
var button_2 = _$_.first_child_frag(fragment_4);
|
|
137
137
|
|
|
138
138
|
button_2.__click = () => {
|
|
139
|
-
_$_.set(lazy_1, !
|
|
139
|
+
_$_.set(lazy_1, !lazy_1.value);
|
|
140
140
|
};
|
|
141
141
|
|
|
142
142
|
var node_4 = _$_.sibling(button_2);
|
|
@@ -155,7 +155,7 @@ export function ReactiveIfElse(__anchor, _, __block) {
|
|
|
155
155
|
};
|
|
156
156
|
|
|
157
157
|
_$_.if(node_4, (__render) => {
|
|
158
|
-
if (
|
|
158
|
+
if (lazy_1.value) __render(consequent_4); else __render(alternate_1, false);
|
|
159
159
|
});
|
|
160
160
|
}
|
|
161
161
|
|
|
@@ -172,13 +172,13 @@ export function NestedIf(__anchor, _, __block) {
|
|
|
172
172
|
var button_3 = _$_.first_child_frag(fragment_5);
|
|
173
173
|
|
|
174
174
|
button_3.__click = () => {
|
|
175
|
-
_$_.set(lazy_2, !
|
|
175
|
+
_$_.set(lazy_2, !lazy_2.value);
|
|
176
176
|
};
|
|
177
177
|
|
|
178
178
|
var button_4 = _$_.sibling(button_3);
|
|
179
179
|
|
|
180
180
|
button_4.__click = () => {
|
|
181
|
-
_$_.set(lazy_3, !
|
|
181
|
+
_$_.set(lazy_3, !lazy_3.value);
|
|
182
182
|
};
|
|
183
183
|
|
|
184
184
|
var node_5 = _$_.sibling(button_4);
|
|
@@ -199,7 +199,7 @@ export function NestedIf(__anchor, _, __block) {
|
|
|
199
199
|
};
|
|
200
200
|
|
|
201
201
|
_$_.if(node_6, (__render) => {
|
|
202
|
-
if (
|
|
202
|
+
if (lazy_3.value) __render(consequent_5);
|
|
203
203
|
});
|
|
204
204
|
}
|
|
205
205
|
|
|
@@ -210,7 +210,7 @@ export function NestedIf(__anchor, _, __block) {
|
|
|
210
210
|
};
|
|
211
211
|
|
|
212
212
|
_$_.if(node_5, (__render) => {
|
|
213
|
-
if (
|
|
213
|
+
if (lazy_2.value) __render(consequent_6);
|
|
214
214
|
});
|
|
215
215
|
}
|
|
216
216
|
|
|
@@ -270,7 +270,7 @@ export function IfElseIfChain(__anchor, _, __block) {
|
|
|
270
270
|
};
|
|
271
271
|
|
|
272
272
|
_$_.if(node_8, (__render) => {
|
|
273
|
-
if (
|
|
273
|
+
if (lazy_4.value === 'success') __render(consequent_8); else __render(alternate_2, false);
|
|
274
274
|
});
|
|
275
275
|
}
|
|
276
276
|
|
|
@@ -278,7 +278,7 @@ export function IfElseIfChain(__anchor, _, __block) {
|
|
|
278
278
|
};
|
|
279
279
|
|
|
280
280
|
_$_.if(node_7, (__render) => {
|
|
281
|
-
if (
|
|
281
|
+
if (lazy_4.value === 'loading') __render(consequent_7); else __render(alternate_3, false);
|
|
282
282
|
});
|
|
283
283
|
}
|
|
284
284
|
|
|
@@ -175,19 +175,19 @@ export function MixedControlFlowReactive(__anchor, _, __block) {
|
|
|
175
175
|
var button_1 = _$_.first_child_frag(fragment_4);
|
|
176
176
|
|
|
177
177
|
button_1.__click = () => {
|
|
178
|
-
_$_.set(lazy, !
|
|
178
|
+
_$_.set(lazy, !lazy.value);
|
|
179
179
|
};
|
|
180
180
|
|
|
181
181
|
var button_2 = _$_.sibling(button_1);
|
|
182
182
|
|
|
183
183
|
button_2.__click = () => {
|
|
184
|
-
_$_.set(lazy_1,
|
|
184
|
+
_$_.set(lazy_1, lazy_1.value === 'a' ? 'b' : 'a');
|
|
185
185
|
};
|
|
186
186
|
|
|
187
187
|
var button_3 = _$_.sibling(button_2);
|
|
188
188
|
|
|
189
189
|
button_3.__click = () => {
|
|
190
|
-
_$_.set(lazy_2, [...
|
|
190
|
+
_$_.set(lazy_2, [...lazy_2.value, { id: 3, label: 'Three' }]);
|
|
191
191
|
};
|
|
192
192
|
|
|
193
193
|
var node_4 = _$_.sibling(button_3);
|
|
@@ -199,7 +199,7 @@ export function MixedControlFlowReactive(__anchor, _, __block) {
|
|
|
199
199
|
{
|
|
200
200
|
_$_.for_keyed(
|
|
201
201
|
div_5,
|
|
202
|
-
() =>
|
|
202
|
+
() => lazy_2.value,
|
|
203
203
|
(__anchor, pattern_1) => {
|
|
204
204
|
var fragment_5 = root_11();
|
|
205
205
|
var node_5 = _$_.first_child_frag(fragment_5);
|
|
@@ -274,7 +274,7 @@ export function MixedControlFlowReactive(__anchor, _, __block) {
|
|
|
274
274
|
_$_.switch(node_5, () => {
|
|
275
275
|
var result = [];
|
|
276
276
|
|
|
277
|
-
switch (
|
|
277
|
+
switch (lazy_1.value) {
|
|
278
278
|
case 'a':
|
|
279
279
|
result.push(switch_case_0_1);
|
|
280
280
|
return result;
|
|
@@ -299,7 +299,7 @@ export function MixedControlFlowReactive(__anchor, _, __block) {
|
|
|
299
299
|
};
|
|
300
300
|
|
|
301
301
|
_$_.if(node_4, (__render) => {
|
|
302
|
-
if (
|
|
302
|
+
if (lazy.value) __render(consequent_1);
|
|
303
303
|
});
|
|
304
304
|
}
|
|
305
305
|
|
|
@@ -409,7 +409,7 @@ function AsyncRow(__anchor, { label }, __block) {
|
|
|
409
409
|
{
|
|
410
410
|
var expression_5 = _$_.child(div_9);
|
|
411
411
|
|
|
412
|
-
_$_.expression(expression_5, () =>
|
|
412
|
+
_$_.expression(expression_5, () => lazy_3.value);
|
|
413
413
|
_$_.pop(div_9);
|
|
414
414
|
}
|
|
415
415
|
|
|
@@ -54,7 +54,7 @@ export function ConditionalPortal(__anchor, _, __block) {
|
|
|
54
54
|
{
|
|
55
55
|
var button_1 = _$_.child(div_3);
|
|
56
56
|
|
|
57
|
-
button_1.__click = () => _$_.set(lazy, !
|
|
57
|
+
button_1.__click = () => _$_.set(lazy, !lazy.value);
|
|
58
58
|
|
|
59
59
|
var node_1 = _$_.sibling(button_1);
|
|
60
60
|
|
|
@@ -83,7 +83,7 @@ export function ConditionalPortal(__anchor, _, __block) {
|
|
|
83
83
|
};
|
|
84
84
|
|
|
85
85
|
_$_.if(node_1, (__render) => {
|
|
86
|
-
if (
|
|
86
|
+
if (lazy.value) __render(consequent);
|
|
87
87
|
});
|
|
88
88
|
}
|
|
89
89
|
|
|
@@ -19,7 +19,7 @@ export function TrackedState(__anchor, _, __block) {
|
|
|
19
19
|
{
|
|
20
20
|
var expression = _$_.child(div_1);
|
|
21
21
|
|
|
22
|
-
_$_.expression(expression, () =>
|
|
22
|
+
_$_.expression(expression, () => lazy.value);
|
|
23
23
|
_$_.pop(div_1);
|
|
24
24
|
}
|
|
25
25
|
|
|
@@ -39,7 +39,7 @@ export function CounterWithInitial(__anchor, props, __block) {
|
|
|
39
39
|
{
|
|
40
40
|
var expression_1 = _$_.child(span_1);
|
|
41
41
|
|
|
42
|
-
_$_.expression(expression_1, () =>
|
|
42
|
+
_$_.expression(expression_1, () => lazy_1.value);
|
|
43
43
|
_$_.pop(span_1);
|
|
44
44
|
}
|
|
45
45
|
}
|
|
@@ -64,7 +64,7 @@ export function ComputedValues(__anchor, _, __block) {
|
|
|
64
64
|
|
|
65
65
|
let lazy_2 = _$_.track(2, __block, 'b78281db');
|
|
66
66
|
let lazy_3 = _$_.track(3, __block, 'a0cf6c6d');
|
|
67
|
-
const sum = () =>
|
|
67
|
+
const sum = () => lazy_2.value + lazy_3.value;
|
|
68
68
|
var div_3 = root_3();
|
|
69
69
|
|
|
70
70
|
{
|
|
@@ -90,7 +90,7 @@ export function MultipleTracked(__anchor, _, __block) {
|
|
|
90
90
|
{
|
|
91
91
|
var expression_3 = _$_.child(div_4);
|
|
92
92
|
|
|
93
|
-
_$_.expression(expression_3, () =>
|
|
93
|
+
_$_.expression(expression_3, () => lazy_4.value);
|
|
94
94
|
_$_.pop(div_4);
|
|
95
95
|
}
|
|
96
96
|
|
|
@@ -99,7 +99,7 @@ export function MultipleTracked(__anchor, _, __block) {
|
|
|
99
99
|
{
|
|
100
100
|
var expression_4 = _$_.child(div_5);
|
|
101
101
|
|
|
102
|
-
_$_.expression(expression_4, () =>
|
|
102
|
+
_$_.expression(expression_4, () => lazy_5.value);
|
|
103
103
|
_$_.pop(div_5);
|
|
104
104
|
}
|
|
105
105
|
|
|
@@ -108,7 +108,7 @@ export function MultipleTracked(__anchor, _, __block) {
|
|
|
108
108
|
{
|
|
109
109
|
var expression_5 = _$_.child(div_6);
|
|
110
110
|
|
|
111
|
-
_$_.expression(expression_5, () =>
|
|
111
|
+
_$_.expression(expression_5, () => lazy_6.value);
|
|
112
112
|
_$_.pop(div_6);
|
|
113
113
|
}
|
|
114
114
|
|
|
@@ -122,7 +122,7 @@ export function DerivedState(__anchor, _, __block) {
|
|
|
122
122
|
|
|
123
123
|
let lazy_7 = _$_.track('John', __block, '6015eeca');
|
|
124
124
|
let lazy_8 = _$_.track('Doe', __block, '4fa9a20e');
|
|
125
|
-
const fullName = () => `${
|
|
125
|
+
const fullName = () => `${lazy_7.value} ${lazy_8.value}`;
|
|
126
126
|
var div_7 = root_5();
|
|
127
127
|
|
|
128
128
|
{
|
|
@@ -1175,7 +1175,7 @@ export function ReactiveReturnTrueToFalse(__anchor, _, __block) {
|
|
|
1175
1175
|
var button_1 = _$_.first_child_frag(fragment_59);
|
|
1176
1176
|
|
|
1177
1177
|
button_1.__click = () => {
|
|
1178
|
-
_$_.set(lazy, !
|
|
1178
|
+
_$_.set(lazy, !lazy.value);
|
|
1179
1179
|
};
|
|
1180
1180
|
|
|
1181
1181
|
var node_51 = _$_.sibling(button_1);
|
|
@@ -1191,7 +1191,7 @@ export function ReactiveReturnTrueToFalse(__anchor, _, __block) {
|
|
|
1191
1191
|
_$_.if(node_51, (__render) => {
|
|
1192
1192
|
_$_.set(__r_28, false);
|
|
1193
1193
|
|
|
1194
|
-
if (
|
|
1194
|
+
if (lazy.value) __render(consequent_30);
|
|
1195
1195
|
});
|
|
1196
1196
|
}
|
|
1197
1197
|
|
|
@@ -1204,7 +1204,7 @@ export function ReactiveReturnTrueToFalse(__anchor, _, __block) {
|
|
|
1204
1204
|
};
|
|
1205
1205
|
|
|
1206
1206
|
_$_.if(node_52, (__render) => {
|
|
1207
|
-
if (!
|
|
1207
|
+
if (!__r_28.value) __render(content_21);
|
|
1208
1208
|
});
|
|
1209
1209
|
|
|
1210
1210
|
_$_.append(__anchor, fragment_59);
|
|
@@ -1220,7 +1220,7 @@ export function ReactiveReturnFalseToTrue(__anchor, _, __block) {
|
|
|
1220
1220
|
var button_2 = _$_.first_child_frag(fragment_61);
|
|
1221
1221
|
|
|
1222
1222
|
button_2.__click = () => {
|
|
1223
|
-
_$_.set(lazy_1, !
|
|
1223
|
+
_$_.set(lazy_1, !lazy_1.value);
|
|
1224
1224
|
};
|
|
1225
1225
|
|
|
1226
1226
|
var node_53 = _$_.sibling(button_2);
|
|
@@ -1236,7 +1236,7 @@ export function ReactiveReturnFalseToTrue(__anchor, _, __block) {
|
|
|
1236
1236
|
_$_.if(node_53, (__render) => {
|
|
1237
1237
|
_$_.set(__r_29, false);
|
|
1238
1238
|
|
|
1239
|
-
if (
|
|
1239
|
+
if (lazy_1.value) __render(consequent_31);
|
|
1240
1240
|
});
|
|
1241
1241
|
}
|
|
1242
1242
|
|
|
@@ -1249,7 +1249,7 @@ export function ReactiveReturnFalseToTrue(__anchor, _, __block) {
|
|
|
1249
1249
|
};
|
|
1250
1250
|
|
|
1251
1251
|
_$_.if(node_54, (__render) => {
|
|
1252
|
-
if (!
|
|
1252
|
+
if (!__r_29.value) __render(content_22);
|
|
1253
1253
|
});
|
|
1254
1254
|
|
|
1255
1255
|
_$_.append(__anchor, fragment_61);
|
|
@@ -1266,7 +1266,7 @@ export function ReactiveNestedReturn(__anchor, _, __block) {
|
|
|
1266
1266
|
var button_3 = _$_.first_child_frag(fragment_63);
|
|
1267
1267
|
|
|
1268
1268
|
button_3.__click = () => {
|
|
1269
|
-
_$_.set(lazy_2, !
|
|
1269
|
+
_$_.set(lazy_2, !lazy_2.value);
|
|
1270
1270
|
};
|
|
1271
1271
|
|
|
1272
1272
|
var node_55 = _$_.sibling(button_3);
|
|
@@ -1288,7 +1288,7 @@ export function ReactiveNestedReturn(__anchor, _, __block) {
|
|
|
1288
1288
|
_$_.if(node_56, (__render) => {
|
|
1289
1289
|
_$_.set(__r_30, false);
|
|
1290
1290
|
|
|
1291
|
-
if (
|
|
1291
|
+
if (lazy_2.value) __render(consequent_32);
|
|
1292
1292
|
});
|
|
1293
1293
|
}
|
|
1294
1294
|
|
|
@@ -1311,7 +1311,7 @@ export function ReactiveNestedReturn(__anchor, _, __block) {
|
|
|
1311
1311
|
};
|
|
1312
1312
|
|
|
1313
1313
|
_$_.if(node_57, (__render) => {
|
|
1314
|
-
if (!
|
|
1314
|
+
if (!__r_30.value) __render(content_23);
|
|
1315
1315
|
});
|
|
1316
1316
|
|
|
1317
1317
|
_$_.append(__anchor, fragment_63);
|
|
@@ -1581,9 +1581,9 @@ export function ReactiveSiblingReturns(__anchor, _, __block) {
|
|
|
1581
1581
|
var button_4 = _$_.first_child_frag(fragment_82);
|
|
1582
1582
|
|
|
1583
1583
|
button_4.__click = () => {
|
|
1584
|
-
if (
|
|
1584
|
+
if (lazy_3.value === 'first') {
|
|
1585
1585
|
_$_.set(lazy_3, 'second');
|
|
1586
|
-
} else if (
|
|
1586
|
+
} else if (lazy_3.value === 'second') {
|
|
1587
1587
|
_$_.set(lazy_3, 'none');
|
|
1588
1588
|
} else {
|
|
1589
1589
|
_$_.set(lazy_3, 'first');
|
|
@@ -1603,7 +1603,7 @@ export function ReactiveSiblingReturns(__anchor, _, __block) {
|
|
|
1603
1603
|
_$_.if(node_71, (__render) => {
|
|
1604
1604
|
_$_.set(__r_38, false);
|
|
1605
1605
|
|
|
1606
|
-
if (
|
|
1606
|
+
if (lazy_3.value === 'first') __render(consequent_41);
|
|
1607
1607
|
});
|
|
1608
1608
|
}
|
|
1609
1609
|
|
|
@@ -1624,7 +1624,7 @@ export function ReactiveSiblingReturns(__anchor, _, __block) {
|
|
|
1624
1624
|
_$_.if(node_73, (__render) => {
|
|
1625
1625
|
_$_.set(__r_39, false);
|
|
1626
1626
|
|
|
1627
|
-
if (
|
|
1627
|
+
if (lazy_3.value === 'second') __render(consequent_42);
|
|
1628
1628
|
});
|
|
1629
1629
|
}
|
|
1630
1630
|
|
|
@@ -1632,7 +1632,7 @@ export function ReactiveSiblingReturns(__anchor, _, __block) {
|
|
|
1632
1632
|
};
|
|
1633
1633
|
|
|
1634
1634
|
_$_.if(node_72, (__render) => {
|
|
1635
|
-
if (!
|
|
1635
|
+
if (!__r_38.value) __render(content_30);
|
|
1636
1636
|
});
|
|
1637
1637
|
|
|
1638
1638
|
var node_74 = _$_.sibling(node_72);
|
|
@@ -1644,7 +1644,7 @@ export function ReactiveSiblingReturns(__anchor, _, __block) {
|
|
|
1644
1644
|
};
|
|
1645
1645
|
|
|
1646
1646
|
_$_.if(node_74, (__render) => {
|
|
1647
|
-
if (!
|
|
1647
|
+
if (!__r_38.value && !__r_39.value) __render(content_31);
|
|
1648
1648
|
});
|
|
1649
1649
|
|
|
1650
1650
|
_$_.append(__anchor, fragment_82);
|
|
@@ -1661,13 +1661,13 @@ export function ReactiveOuterInnerReturns(__anchor, _, __block) {
|
|
|
1661
1661
|
var button_5 = _$_.first_child_frag(fragment_86);
|
|
1662
1662
|
|
|
1663
1663
|
button_5.__click = () => {
|
|
1664
|
-
_$_.set(lazy_4, !
|
|
1664
|
+
_$_.set(lazy_4, !lazy_4.value);
|
|
1665
1665
|
};
|
|
1666
1666
|
|
|
1667
1667
|
var button_6 = _$_.sibling(button_5);
|
|
1668
1668
|
|
|
1669
1669
|
button_6.__click = () => {
|
|
1670
|
-
_$_.set(lazy_5, !
|
|
1670
|
+
_$_.set(lazy_5, !lazy_5.value);
|
|
1671
1671
|
};
|
|
1672
1672
|
|
|
1673
1673
|
var node_75 = _$_.sibling(button_6);
|
|
@@ -1689,7 +1689,7 @@ export function ReactiveOuterInnerReturns(__anchor, _, __block) {
|
|
|
1689
1689
|
_$_.if(node_76, (__render) => {
|
|
1690
1690
|
_$_.set(__r_40, false);
|
|
1691
1691
|
|
|
1692
|
-
if (
|
|
1692
|
+
if (lazy_5.value) __render(consequent_43);
|
|
1693
1693
|
});
|
|
1694
1694
|
}
|
|
1695
1695
|
|
|
@@ -1699,7 +1699,7 @@ export function ReactiveOuterInnerReturns(__anchor, _, __block) {
|
|
|
1699
1699
|
_$_.if(node_75, (__render) => {
|
|
1700
1700
|
_$_.set(__r_40, false);
|
|
1701
1701
|
|
|
1702
|
-
if (
|
|
1702
|
+
if (lazy_4.value) __render(consequent_44);
|
|
1703
1703
|
});
|
|
1704
1704
|
}
|
|
1705
1705
|
|
|
@@ -1711,7 +1711,7 @@ export function ReactiveOuterInnerReturns(__anchor, _, __block) {
|
|
|
1711
1711
|
{
|
|
1712
1712
|
var expression = _$_.child(div_39);
|
|
1713
1713
|
|
|
1714
|
-
_$_.expression(expression, () =>
|
|
1714
|
+
_$_.expression(expression, () => lazy_4.value ? 'a-on rest' : 'a-off rest');
|
|
1715
1715
|
_$_.pop(div_39);
|
|
1716
1716
|
}
|
|
1717
1717
|
|
|
@@ -1719,7 +1719,7 @@ export function ReactiveOuterInnerReturns(__anchor, _, __block) {
|
|
|
1719
1719
|
};
|
|
1720
1720
|
|
|
1721
1721
|
_$_.if(node_77, (__render) => {
|
|
1722
|
-
if (!
|
|
1722
|
+
if (!__r_40.value) __render(content_32);
|
|
1723
1723
|
});
|
|
1724
1724
|
|
|
1725
1725
|
_$_.append(__anchor, fragment_86);
|
|
@@ -1736,7 +1736,7 @@ export function ReactiveElseIfReturns(__anchor, _, __block) {
|
|
|
1736
1736
|
var button_7 = _$_.first_child_frag(fragment_89);
|
|
1737
1737
|
|
|
1738
1738
|
button_7.__click = () => {
|
|
1739
|
-
_$_.set(lazy_6, (
|
|
1739
|
+
_$_.set(lazy_6, (lazy_6.value + 1) % 3);
|
|
1740
1740
|
};
|
|
1741
1741
|
|
|
1742
1742
|
var node_78 = _$_.sibling(button_7);
|
|
@@ -1764,7 +1764,7 @@ export function ReactiveElseIfReturns(__anchor, _, __block) {
|
|
|
1764
1764
|
_$_.if(node_79, (__render) => {
|
|
1765
1765
|
_$_.set(__r_42, false);
|
|
1766
1766
|
|
|
1767
|
-
if (
|
|
1767
|
+
if (lazy_6.value === 1) __render(consequent_46);
|
|
1768
1768
|
});
|
|
1769
1769
|
}
|
|
1770
1770
|
|
|
@@ -1777,7 +1777,7 @@ export function ReactiveElseIfReturns(__anchor, _, __block) {
|
|
|
1777
1777
|
_$_.set(__r_41, false);
|
|
1778
1778
|
_$_.set(__r_42, false);
|
|
1779
1779
|
|
|
1780
|
-
if (
|
|
1780
|
+
if (lazy_6.value === 0) __render(consequent_45); else __render(alternate_8, false);
|
|
1781
1781
|
});
|
|
1782
1782
|
}
|
|
1783
1783
|
|
|
@@ -1791,7 +1791,7 @@ export function ReactiveElseIfReturns(__anchor, _, __block) {
|
|
|
1791
1791
|
};
|
|
1792
1792
|
|
|
1793
1793
|
_$_.if(node_80, (__render) => {
|
|
1794
|
-
if (!
|
|
1794
|
+
if (!__r_41.value && !__r_42.value) __render(content_33);
|
|
1795
1795
|
});
|
|
1796
1796
|
|
|
1797
1797
|
_$_.append(__anchor, fragment_89);
|
|
@@ -1813,25 +1813,25 @@ export function ReactiveDeepNestedIndependentReturns(__anchor, _, __block) {
|
|
|
1813
1813
|
var button_8 = _$_.first_child_frag(fragment_94);
|
|
1814
1814
|
|
|
1815
1815
|
button_8.__click = () => {
|
|
1816
|
-
_$_.set(lazy_7, !
|
|
1816
|
+
_$_.set(lazy_7, !lazy_7.value);
|
|
1817
1817
|
};
|
|
1818
1818
|
|
|
1819
1819
|
var button_9 = _$_.sibling(button_8);
|
|
1820
1820
|
|
|
1821
1821
|
button_9.__click = () => {
|
|
1822
|
-
_$_.set(lazy_8, !
|
|
1822
|
+
_$_.set(lazy_8, !lazy_8.value);
|
|
1823
1823
|
};
|
|
1824
1824
|
|
|
1825
1825
|
var button_10 = _$_.sibling(button_9);
|
|
1826
1826
|
|
|
1827
1827
|
button_10.__click = () => {
|
|
1828
|
-
_$_.set(lazy_9, !
|
|
1828
|
+
_$_.set(lazy_9, !lazy_9.value);
|
|
1829
1829
|
};
|
|
1830
1830
|
|
|
1831
1831
|
var button_11 = _$_.sibling(button_10);
|
|
1832
1832
|
|
|
1833
1833
|
button_11.__click = () => {
|
|
1834
|
-
_$_.set(lazy_10, !
|
|
1834
|
+
_$_.set(lazy_10, !lazy_10.value);
|
|
1835
1835
|
};
|
|
1836
1836
|
|
|
1837
1837
|
var div_40 = _$_.sibling(button_11);
|
|
@@ -1848,7 +1848,7 @@ export function ReactiveDeepNestedIndependentReturns(__anchor, _, __block) {
|
|
|
1848
1848
|
_$_.if(node_81, (__render) => {
|
|
1849
1849
|
_$_.set(__r_43, false);
|
|
1850
1850
|
|
|
1851
|
-
if (
|
|
1851
|
+
if (lazy_7.value) __render(consequent_47);
|
|
1852
1852
|
});
|
|
1853
1853
|
}
|
|
1854
1854
|
|
|
@@ -1874,7 +1874,7 @@ export function ReactiveDeepNestedIndependentReturns(__anchor, _, __block) {
|
|
|
1874
1874
|
_$_.if(node_83, (__render) => {
|
|
1875
1875
|
_$_.set(__r_44, false);
|
|
1876
1876
|
|
|
1877
|
-
if (
|
|
1877
|
+
if (lazy_8.value) __render(consequent_48);
|
|
1878
1878
|
});
|
|
1879
1879
|
}
|
|
1880
1880
|
|
|
@@ -1900,7 +1900,7 @@ export function ReactiveDeepNestedIndependentReturns(__anchor, _, __block) {
|
|
|
1900
1900
|
_$_.if(node_85, (__render) => {
|
|
1901
1901
|
_$_.set(__r_45, false);
|
|
1902
1902
|
|
|
1903
|
-
if (
|
|
1903
|
+
if (lazy_9.value) __render(consequent_49);
|
|
1904
1904
|
});
|
|
1905
1905
|
}
|
|
1906
1906
|
|
|
@@ -1922,7 +1922,7 @@ export function ReactiveDeepNestedIndependentReturns(__anchor, _, __block) {
|
|
|
1922
1922
|
_$_.if(node_87, (__render) => {
|
|
1923
1923
|
_$_.set(__r_46, false);
|
|
1924
1924
|
|
|
1925
|
-
if (
|
|
1925
|
+
if (lazy_10.value) __render(consequent_50);
|
|
1926
1926
|
});
|
|
1927
1927
|
}
|
|
1928
1928
|
|
|
@@ -1930,7 +1930,7 @@ export function ReactiveDeepNestedIndependentReturns(__anchor, _, __block) {
|
|
|
1930
1930
|
};
|
|
1931
1931
|
|
|
1932
1932
|
_$_.if(node_86, (__render) => {
|
|
1933
|
-
if (!
|
|
1933
|
+
if (!__r_45.value) __render(content_34);
|
|
1934
1934
|
});
|
|
1935
1935
|
|
|
1936
1936
|
_$_.pop(section_2);
|
|
@@ -1940,7 +1940,7 @@ export function ReactiveDeepNestedIndependentReturns(__anchor, _, __block) {
|
|
|
1940
1940
|
};
|
|
1941
1941
|
|
|
1942
1942
|
_$_.if(node_84, (__render) => {
|
|
1943
|
-
if (!
|
|
1943
|
+
if (!__r_44.value) __render(content_35);
|
|
1944
1944
|
});
|
|
1945
1945
|
|
|
1946
1946
|
_$_.pop(section_1);
|
|
@@ -1951,7 +1951,7 @@ export function ReactiveDeepNestedIndependentReturns(__anchor, _, __block) {
|
|
|
1951
1951
|
};
|
|
1952
1952
|
|
|
1953
1953
|
_$_.if(node_82, (__render) => {
|
|
1954
|
-
if (!
|
|
1954
|
+
if (!__r_43.value) __render(content_36);
|
|
1955
1955
|
});
|
|
1956
1956
|
|
|
1957
1957
|
var node_88 = _$_.sibling(node_82);
|
|
@@ -1964,7 +1964,7 @@ export function ReactiveDeepNestedIndependentReturns(__anchor, _, __block) {
|
|
|
1964
1964
|
};
|
|
1965
1965
|
|
|
1966
1966
|
_$_.if(node_88, (__render) => {
|
|
1967
|
-
if (!
|
|
1967
|
+
if (!__r_43.value && !__r_44.value && !__r_45.value && !__r_46.value) __render(content_37);
|
|
1968
1968
|
});
|
|
1969
1969
|
|
|
1970
1970
|
_$_.append(__anchor, fragment_94);
|
|
@@ -84,7 +84,7 @@ export function SwitchReactive(__anchor, _, __block) {
|
|
|
84
84
|
var button_1 = _$_.first_child_frag(fragment_3);
|
|
85
85
|
|
|
86
86
|
button_1.__click = () => {
|
|
87
|
-
if (
|
|
87
|
+
if (lazy.value === 'a') _$_.set(lazy, 'b'); else if (lazy.value === 'b') _$_.set(lazy, 'c'); else _$_.set(lazy, 'a');
|
|
88
88
|
};
|
|
89
89
|
|
|
90
90
|
var node_1 = _$_.sibling(button_1);
|
|
@@ -111,7 +111,7 @@ export function SwitchReactive(__anchor, _, __block) {
|
|
|
111
111
|
_$_.switch(node_1, () => {
|
|
112
112
|
var result = [];
|
|
113
113
|
|
|
114
|
-
switch (
|
|
114
|
+
switch (lazy.value) {
|
|
115
115
|
case 'a':
|
|
116
116
|
result.push(switch_case_0_1);
|
|
117
117
|
return result;
|
|
@@ -180,7 +180,7 @@ export function SwitchNumericLevels(__anchor, _, __block) {
|
|
|
180
180
|
var button_2 = _$_.first_child_frag(fragment_8);
|
|
181
181
|
|
|
182
182
|
button_2.__click = () => {
|
|
183
|
-
if (
|
|
183
|
+
if (lazy_1.value === 1) _$_.set(lazy_1, 2); else if (lazy_1.value === 2) _$_.set(lazy_1, 3); else _$_.set(lazy_1, 1);
|
|
184
184
|
};
|
|
185
185
|
|
|
186
186
|
var node_3 = _$_.sibling(button_2);
|
|
@@ -207,7 +207,7 @@ export function SwitchNumericLevels(__anchor, _, __block) {
|
|
|
207
207
|
_$_.switch(node_3, () => {
|
|
208
208
|
var result = [];
|
|
209
209
|
|
|
210
|
-
switch (
|
|
210
|
+
switch (lazy_1.value) {
|
|
211
211
|
case 1:
|
|
212
212
|
result.push(switch_case_0_3);
|
|
213
213
|
return result;
|
|
@@ -235,7 +235,7 @@ export function SwitchBlockScoped(__anchor, _, __block) {
|
|
|
235
235
|
var button_3 = _$_.first_child_frag(fragment_12);
|
|
236
236
|
|
|
237
237
|
button_3.__click = () => {
|
|
238
|
-
if (
|
|
238
|
+
if (lazy_2.value === 1) _$_.set(lazy_2, 2); else if (lazy_2.value === 2) _$_.set(lazy_2, 3); else _$_.set(lazy_2, 1);
|
|
239
239
|
};
|
|
240
240
|
|
|
241
241
|
var node_4 = _$_.sibling(button_3);
|
|
@@ -262,7 +262,7 @@ export function SwitchBlockScoped(__anchor, _, __block) {
|
|
|
262
262
|
_$_.switch(node_4, () => {
|
|
263
263
|
var result = [];
|
|
264
264
|
|
|
265
|
-
switch (
|
|
265
|
+
switch (lazy_2.value) {
|
|
266
266
|
case 1:
|
|
267
267
|
result.push(switch_case_0_4);
|
|
268
268
|
return result;
|
|
@@ -290,7 +290,7 @@ export function SwitchNoBreak(__anchor, _, __block) {
|
|
|
290
290
|
var button_4 = _$_.first_child_frag(fragment_16);
|
|
291
291
|
|
|
292
292
|
button_4.__click = () => {
|
|
293
|
-
if (
|
|
293
|
+
if (lazy_3.value === 1) _$_.set(lazy_3, 2); else if (lazy_3.value === 2) _$_.set(lazy_3, 3); else _$_.set(lazy_3, 1);
|
|
294
294
|
};
|
|
295
295
|
|
|
296
296
|
var node_5 = _$_.sibling(button_4);
|
|
@@ -317,7 +317,7 @@ export function SwitchNoBreak(__anchor, _, __block) {
|
|
|
317
317
|
_$_.switch(node_5, () => {
|
|
318
318
|
var result = [];
|
|
319
319
|
|
|
320
|
-
switch (
|
|
320
|
+
switch (lazy_3.value) {
|
|
321
321
|
case 1:
|
|
322
322
|
result.push(switch_case_0_5);
|
|
323
323
|
|