ripple 0.3.72 → 0.3.76
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 +116 -0
- package/package.json +3 -3
- package/src/jsx-runtime.d.ts +4 -10
- package/src/runtime/dynamic-client.js +33 -0
- package/src/runtime/dynamic-server.js +80 -0
- package/src/runtime/index-client.js +5 -13
- package/src/runtime/index-server.js +2 -0
- package/src/runtime/internal/client/blocks.js +6 -27
- package/src/runtime/internal/client/composite.js +11 -6
- package/src/runtime/internal/client/for.js +80 -5
- package/src/runtime/internal/client/index.js +0 -2
- package/src/runtime/internal/client/render.js +5 -2
- package/src/runtime/internal/client/types.d.ts +0 -10
- package/src/runtime/internal/server/index.js +8 -1
- package/tests/client/__snapshots__/computed-properties.test.tsrx.snap +8 -0
- package/tests/client/__snapshots__/for.test.tsrx.snap +22 -0
- package/tests/client/__snapshots__/html.test.tsrx.snap +4 -0
- package/tests/client/array/array.copy-within.test.tsrx +19 -19
- package/tests/client/array/array.derived.test.tsrx +97 -109
- package/tests/client/array/array.iteration.test.tsrx +28 -28
- package/tests/client/array/array.mutations.test.tsrx +68 -68
- package/tests/client/array/array.static.test.tsrx +82 -92
- package/tests/client/array/array.to-methods.test.tsrx +15 -15
- package/tests/client/async-suspend.test.tsrx +180 -179
- package/tests/client/basic/__snapshots__/basic.attributes.test.tsrx.snap +2 -0
- package/tests/client/basic/__snapshots__/basic.rendering.test.tsrx.snap +4 -0
- package/tests/client/basic/basic.attributes.test.tsrx +273 -317
- package/tests/client/basic/basic.collections.test.tsrx +55 -61
- package/tests/client/basic/basic.components.test.tsrx +198 -220
- package/tests/client/basic/basic.errors.test.tsrx +70 -76
- package/tests/client/basic/basic.events.test.tsrx +80 -85
- package/tests/client/basic/basic.get-set.test.tsrx +54 -64
- package/tests/client/basic/basic.hmr.test.tsrx +15 -19
- package/tests/client/basic/basic.reactivity.test.tsrx +121 -135
- package/tests/client/basic/basic.rendering.test.tsrx +273 -178
- package/tests/client/basic/basic.styling.test.tsrx +16 -14
- package/tests/client/basic/basic.utilities.test.tsrx +8 -10
- package/tests/client/boundaries.test.tsrx +18 -18
- package/tests/client/compiler/compiler.assignments.test.tsrx +77 -76
- package/tests/client/compiler/compiler.attributes.test.tsrx +18 -14
- package/tests/client/compiler/compiler.basic.test.tsrx +357 -288
- package/tests/client/compiler/compiler.regex.test.tsrx +40 -44
- package/tests/client/compiler/compiler.tracked-access.test.tsrx +57 -38
- package/tests/client/compiler/compiler.try-in-function.test.tsrx +16 -16
- package/tests/client/compiler/compiler.typescript.test.tsrx +4 -3
- package/tests/client/composite/composite.dynamic-components.test.tsrx +62 -47
- package/tests/client/composite/composite.generics.test.tsrx +165 -167
- package/tests/client/composite/composite.props.test.tsrx +66 -74
- package/tests/client/composite/composite.reactivity.test.tsrx +132 -166
- package/tests/client/composite/composite.render.test.tsrx +92 -101
- package/tests/client/computed-properties.test.tsrx +14 -18
- package/tests/client/context.test.tsrx +14 -18
- package/tests/client/css/global-additional-cases.test.tsrx +493 -439
- package/tests/client/css/global-advanced-selectors.test.tsrx +169 -153
- package/tests/client/css/global-at-rules.test.tsrx +71 -66
- package/tests/client/css/global-basic.test.tsrx +105 -98
- package/tests/client/css/global-classes-ids.test.tsrx +128 -114
- package/tests/client/css/global-combinators.test.tsrx +83 -78
- package/tests/client/css/global-complex-nesting.test.tsrx +134 -120
- package/tests/client/css/global-edge-cases.test.tsrx +138 -120
- package/tests/client/css/global-keyframes.test.tsrx +108 -96
- package/tests/client/css/global-nested.test.tsrx +88 -78
- package/tests/client/css/global-pseudo.test.tsrx +104 -98
- package/tests/client/css/global-scoping.test.tsrx +145 -125
- package/tests/client/css/style-identifier.test.tsrx +65 -72
- package/tests/client/date.test.tsrx +83 -83
- package/tests/client/dynamic-elements.test.tsrx +318 -299
- package/tests/client/events.test.tsrx +252 -266
- package/tests/client/for.test.tsrx +120 -127
- package/tests/client/head.test.tsrx +74 -48
- package/tests/client/html.test.tsrx +37 -49
- package/tests/client/input-value.test.tsrx +1125 -1354
- package/tests/client/lazy-array.test.tsrx +10 -16
- package/tests/client/lazy-destructuring.test.tsrx +169 -221
- package/tests/client/map.test.tsrx +39 -41
- package/tests/client/media-query.test.tsrx +15 -19
- package/tests/client/object.test.tsrx +46 -56
- package/tests/client/portal.test.tsrx +31 -37
- package/tests/client/ref.test.tsrx +173 -193
- package/tests/client/return.test.tsrx +62 -37
- package/tests/client/set.test.tsrx +33 -33
- package/tests/client/svg.test.tsrx +197 -216
- package/tests/client/switch.test.tsrx +201 -191
- package/tests/client/track-async-hydration.test.tsrx +14 -18
- package/tests/client/tracked-index-access.test.tsrx +18 -28
- package/tests/client/try.test.tsrx +494 -619
- package/tests/client/tsx.test.tsrx +286 -292
- package/tests/client/typescript-generics.test.tsrx +121 -129
- package/tests/client/url/url.derived.test.tsrx +21 -25
- package/tests/client/url/url.parsing.test.tsrx +35 -35
- package/tests/client/url/url.partial-removal.test.tsrx +32 -32
- package/tests/client/url/url.reactivity.test.tsrx +68 -72
- package/tests/client/url/url.serialization.test.tsrx +8 -8
- package/tests/client/url-search-params/url-search-params.derived.test.tsrx +21 -27
- package/tests/client/url-search-params/url-search-params.initialization.test.tsrx +16 -16
- package/tests/client/url-search-params/url-search-params.iteration.test.tsrx +37 -37
- package/tests/client/url-search-params/url-search-params.mutation.test.tsrx +56 -60
- package/tests/client/url-search-params/url-search-params.retrieval.test.tsrx +32 -34
- package/tests/client/url-search-params/url-search-params.serialization.test.tsrx +9 -9
- package/tests/client/url-search-params/url-search-params.tracked-url.test.tsrx +10 -10
- package/tests/hydration/compiled/client/basic.js +390 -319
- package/tests/hydration/compiled/client/composite.js +52 -44
- package/tests/hydration/compiled/client/for.js +734 -604
- package/tests/hydration/compiled/client/head.js +183 -103
- package/tests/hydration/compiled/client/html.js +93 -86
- package/tests/hydration/compiled/client/if-children.js +95 -71
- package/tests/hydration/compiled/client/if.js +113 -89
- package/tests/hydration/compiled/client/mixed-control-flow.js +225 -209
- package/tests/hydration/compiled/client/nested-control-flow.js +94 -98
- package/tests/hydration/compiled/client/reactivity.js +26 -24
- package/tests/hydration/compiled/client/return.js +8 -42
- package/tests/hydration/compiled/client/switch.js +208 -173
- package/tests/hydration/compiled/client/track-async-serialization.js +176 -128
- package/tests/hydration/compiled/client/try.js +29 -21
- package/tests/hydration/compiled/server/basic.js +210 -221
- package/tests/hydration/compiled/server/composite.js +13 -14
- package/tests/hydration/compiled/server/for.js +427 -444
- package/tests/hydration/compiled/server/head.js +199 -189
- package/tests/hydration/compiled/server/html.js +33 -41
- package/tests/hydration/compiled/server/if-children.js +114 -117
- package/tests/hydration/compiled/server/if.js +77 -83
- package/tests/hydration/compiled/server/mixed-control-flow.js +145 -150
- package/tests/hydration/compiled/server/nested-control-flow.js +10 -0
- package/tests/hydration/compiled/server/reactivity.js +24 -22
- package/tests/hydration/compiled/server/return.js +6 -18
- package/tests/hydration/compiled/server/switch.js +179 -176
- package/tests/hydration/compiled/server/track-async-serialization.js +88 -70
- package/tests/hydration/compiled/server/try.js +31 -35
- package/tests/hydration/components/basic.tsrx +216 -258
- package/tests/hydration/components/composite.tsrx +32 -42
- package/tests/hydration/components/events.tsrx +81 -101
- package/tests/hydration/components/for.tsrx +270 -336
- package/tests/hydration/components/head.tsrx +43 -39
- package/tests/hydration/components/hmr.tsrx +16 -22
- package/tests/hydration/components/html-in-template.tsrx +15 -21
- package/tests/hydration/components/html.tsrx +442 -526
- package/tests/hydration/components/if-children.tsrx +107 -125
- package/tests/hydration/components/if.tsrx +68 -90
- package/tests/hydration/components/mixed-control-flow.tsrx +65 -72
- package/tests/hydration/components/nested-control-flow.tsrx +202 -216
- package/tests/hydration/components/portal.tsrx +33 -41
- package/tests/hydration/components/reactivity.tsrx +26 -34
- package/tests/hydration/components/return.tsrx +4 -6
- package/tests/hydration/components/switch.tsrx +73 -78
- package/tests/hydration/components/track-async-serialization.tsrx +83 -93
- package/tests/hydration/components/try.tsrx +37 -51
- package/tests/hydration/switch.test.js +8 -8
- package/tests/server/await.test.tsrx +3 -3
- package/tests/server/basic.attributes.test.tsrx +117 -162
- package/tests/server/basic.components.test.tsrx +164 -194
- package/tests/server/basic.test.tsrx +299 -199
- package/tests/server/compiler.test.tsrx +142 -72
- package/tests/server/composite.props.test.tsrx +54 -58
- package/tests/server/composite.test.tsrx +165 -167
- package/tests/server/context.test.tsrx +13 -17
- package/tests/server/dynamic-elements.test.tsrx +147 -148
- package/tests/server/for.test.tsrx +115 -84
- package/tests/server/head.test.tsrx +54 -31
- package/tests/server/html-nesting-validation.test.tsrx +16 -8
- package/tests/server/if.test.tsrx +49 -59
- package/tests/server/lazy-destructuring.test.tsrx +288 -366
- package/tests/server/return.test.tsrx +58 -36
- package/tests/server/streaming-ssr.test.tsrx +4 -4
- package/tests/server/style-identifier.test.tsrx +61 -69
- package/tests/server/switch.test.tsrx +89 -97
- package/tests/server/track-async-serialization.test.tsrx +85 -103
- package/tests/server/try.test.tsrx +275 -360
- package/tests/utils/ref-types.test.js +72 -0
- package/tests/utils/vite-plugin-config.test.js +41 -74
- package/types/index.d.ts +29 -4
- package/src/runtime/internal/client/compat.js +0 -40
- package/tests/utils/compiler-compat-config.test.js +0 -38
|
@@ -105,39 +105,38 @@ export function ReactiveForLoopAdd() {
|
|
|
105
105
|
let lazy = _$_.track(['A', 'B'], 'e145678a');
|
|
106
106
|
|
|
107
107
|
_$_.regular_block(() => {
|
|
108
|
-
_$_.output_push('<button');
|
|
109
|
-
_$_.output_push(' class="add"');
|
|
110
|
-
_$_.output_push('>');
|
|
111
|
-
|
|
112
108
|
{
|
|
113
|
-
_$_.output_push('
|
|
114
|
-
|
|
109
|
+
_$_.output_push('<button');
|
|
110
|
+
_$_.output_push(' class="add"');
|
|
111
|
+
_$_.output_push('>');
|
|
115
112
|
|
|
116
|
-
|
|
117
|
-
|
|
113
|
+
{
|
|
114
|
+
_$_.output_push('Add');
|
|
115
|
+
}
|
|
118
116
|
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
117
|
+
_$_.output_push('</button>');
|
|
118
|
+
_$_.output_push('<ul');
|
|
119
|
+
_$_.output_push('>');
|
|
122
120
|
|
|
123
|
-
|
|
124
|
-
|
|
121
|
+
{
|
|
122
|
+
_$_.output_push('<!--[-->');
|
|
125
123
|
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
124
|
+
for (const item of lazy.value) {
|
|
125
|
+
_$_.output_push('<li');
|
|
126
|
+
_$_.output_push('>');
|
|
129
127
|
|
|
130
|
-
|
|
131
|
-
|
|
128
|
+
{
|
|
129
|
+
_$_.output_push(_$_.escape(item));
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
_$_.output_push('</li>');
|
|
132
133
|
}
|
|
133
134
|
|
|
134
|
-
_$_.output_push('
|
|
135
|
+
_$_.output_push('<!--]-->');
|
|
135
136
|
}
|
|
136
137
|
|
|
137
|
-
_$_.output_push('
|
|
138
|
+
_$_.output_push('</ul>');
|
|
138
139
|
}
|
|
139
|
-
|
|
140
|
-
_$_.output_push('</ul>');
|
|
141
140
|
});
|
|
142
141
|
});
|
|
143
142
|
}
|
|
@@ -147,39 +146,38 @@ export function ReactiveForLoopRemove() {
|
|
|
147
146
|
let lazy_1 = _$_.track(['A', 'B', 'C'], 'b4e9bd54');
|
|
148
147
|
|
|
149
148
|
_$_.regular_block(() => {
|
|
150
|
-
_$_.output_push('<button');
|
|
151
|
-
_$_.output_push(' class="remove"');
|
|
152
|
-
_$_.output_push('>');
|
|
153
|
-
|
|
154
149
|
{
|
|
155
|
-
_$_.output_push('
|
|
156
|
-
|
|
150
|
+
_$_.output_push('<button');
|
|
151
|
+
_$_.output_push(' class="remove"');
|
|
152
|
+
_$_.output_push('>');
|
|
157
153
|
|
|
158
|
-
|
|
159
|
-
|
|
154
|
+
{
|
|
155
|
+
_$_.output_push('Remove');
|
|
156
|
+
}
|
|
160
157
|
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
158
|
+
_$_.output_push('</button>');
|
|
159
|
+
_$_.output_push('<ul');
|
|
160
|
+
_$_.output_push('>');
|
|
164
161
|
|
|
165
|
-
|
|
166
|
-
|
|
162
|
+
{
|
|
163
|
+
_$_.output_push('<!--[-->');
|
|
167
164
|
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
165
|
+
for (const item of lazy_1.value) {
|
|
166
|
+
_$_.output_push('<li');
|
|
167
|
+
_$_.output_push('>');
|
|
171
168
|
|
|
172
|
-
|
|
173
|
-
|
|
169
|
+
{
|
|
170
|
+
_$_.output_push(_$_.escape(item));
|
|
171
|
+
}
|
|
172
|
+
|
|
173
|
+
_$_.output_push('</li>');
|
|
174
174
|
}
|
|
175
175
|
|
|
176
|
-
_$_.output_push('
|
|
176
|
+
_$_.output_push('<!--]-->');
|
|
177
177
|
}
|
|
178
178
|
|
|
179
|
-
_$_.output_push('
|
|
179
|
+
_$_.output_push('</ul>');
|
|
180
180
|
}
|
|
181
|
-
|
|
182
|
-
_$_.output_push('</ul>');
|
|
183
181
|
});
|
|
184
182
|
});
|
|
185
183
|
}
|
|
@@ -381,40 +379,39 @@ export function KeyedForLoopReorder() {
|
|
|
381
379
|
);
|
|
382
380
|
|
|
383
381
|
_$_.regular_block(() => {
|
|
384
|
-
_$_.output_push('<button');
|
|
385
|
-
_$_.output_push(' class="reorder"');
|
|
386
|
-
_$_.output_push('>');
|
|
387
|
-
|
|
388
382
|
{
|
|
389
|
-
_$_.output_push('
|
|
390
|
-
|
|
383
|
+
_$_.output_push('<button');
|
|
384
|
+
_$_.output_push(' class="reorder"');
|
|
385
|
+
_$_.output_push('>');
|
|
391
386
|
|
|
392
|
-
|
|
393
|
-
|
|
387
|
+
{
|
|
388
|
+
_$_.output_push('Reorder');
|
|
389
|
+
}
|
|
394
390
|
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
391
|
+
_$_.output_push('</button>');
|
|
392
|
+
_$_.output_push('<ul');
|
|
393
|
+
_$_.output_push('>');
|
|
398
394
|
|
|
399
|
-
|
|
400
|
-
|
|
395
|
+
{
|
|
396
|
+
_$_.output_push('<!--[-->');
|
|
401
397
|
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
398
|
+
for (const item of lazy_3.value) {
|
|
399
|
+
_$_.output_push('<li');
|
|
400
|
+
_$_.output_push(_$_.attr('class', `item-${item.id}`));
|
|
401
|
+
_$_.output_push('>');
|
|
406
402
|
|
|
407
|
-
|
|
408
|
-
|
|
403
|
+
{
|
|
404
|
+
_$_.output_push(_$_.escape(item.name));
|
|
405
|
+
}
|
|
406
|
+
|
|
407
|
+
_$_.output_push('</li>');
|
|
409
408
|
}
|
|
410
409
|
|
|
411
|
-
_$_.output_push('
|
|
410
|
+
_$_.output_push('<!--]-->');
|
|
412
411
|
}
|
|
413
412
|
|
|
414
|
-
_$_.output_push('
|
|
413
|
+
_$_.output_push('</ul>');
|
|
415
414
|
}
|
|
416
|
-
|
|
417
|
-
_$_.output_push('</ul>');
|
|
418
415
|
});
|
|
419
416
|
});
|
|
420
417
|
}
|
|
@@ -424,40 +421,39 @@ export function KeyedForLoopUpdate() {
|
|
|
424
421
|
let lazy_4 = _$_.track([{ id: 1, name: 'Item 1' }, { id: 2, name: 'Item 2' }], '7a2c2ada');
|
|
425
422
|
|
|
426
423
|
_$_.regular_block(() => {
|
|
427
|
-
_$_.output_push('<button');
|
|
428
|
-
_$_.output_push(' class="update"');
|
|
429
|
-
_$_.output_push('>');
|
|
430
|
-
|
|
431
424
|
{
|
|
432
|
-
_$_.output_push('
|
|
433
|
-
|
|
425
|
+
_$_.output_push('<button');
|
|
426
|
+
_$_.output_push(' class="update"');
|
|
427
|
+
_$_.output_push('>');
|
|
434
428
|
|
|
435
|
-
|
|
436
|
-
|
|
429
|
+
{
|
|
430
|
+
_$_.output_push('Update');
|
|
431
|
+
}
|
|
437
432
|
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
433
|
+
_$_.output_push('</button>');
|
|
434
|
+
_$_.output_push('<ul');
|
|
435
|
+
_$_.output_push('>');
|
|
441
436
|
|
|
442
|
-
|
|
443
|
-
|
|
437
|
+
{
|
|
438
|
+
_$_.output_push('<!--[-->');
|
|
444
439
|
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
440
|
+
for (const item of lazy_4.value) {
|
|
441
|
+
_$_.output_push('<li');
|
|
442
|
+
_$_.output_push(_$_.attr('class', `item-${item.id}`));
|
|
443
|
+
_$_.output_push('>');
|
|
449
444
|
|
|
450
|
-
|
|
451
|
-
|
|
445
|
+
{
|
|
446
|
+
_$_.output_push(_$_.escape(item.name));
|
|
447
|
+
}
|
|
448
|
+
|
|
449
|
+
_$_.output_push('</li>');
|
|
452
450
|
}
|
|
453
451
|
|
|
454
|
-
_$_.output_push('
|
|
452
|
+
_$_.output_push('<!--]-->');
|
|
455
453
|
}
|
|
456
454
|
|
|
457
|
-
_$_.output_push('
|
|
455
|
+
_$_.output_push('</ul>');
|
|
458
456
|
}
|
|
459
|
-
|
|
460
|
-
_$_.output_push('</ul>');
|
|
461
457
|
});
|
|
462
458
|
});
|
|
463
459
|
}
|
|
@@ -467,40 +463,39 @@ export function ForLoopMixedOperations() {
|
|
|
467
463
|
let lazy_5 = _$_.track(['A', 'B', 'C', 'D'], '3dd7c7b6');
|
|
468
464
|
|
|
469
465
|
_$_.regular_block(() => {
|
|
470
|
-
_$_.output_push('<button');
|
|
471
|
-
_$_.output_push(' class="shuffle"');
|
|
472
|
-
_$_.output_push('>');
|
|
473
|
-
|
|
474
466
|
{
|
|
475
|
-
_$_.output_push('
|
|
476
|
-
|
|
467
|
+
_$_.output_push('<button');
|
|
468
|
+
_$_.output_push(' class="shuffle"');
|
|
469
|
+
_$_.output_push('>');
|
|
477
470
|
|
|
478
|
-
|
|
479
|
-
|
|
471
|
+
{
|
|
472
|
+
_$_.output_push('Shuffle');
|
|
473
|
+
}
|
|
480
474
|
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
475
|
+
_$_.output_push('</button>');
|
|
476
|
+
_$_.output_push('<ul');
|
|
477
|
+
_$_.output_push('>');
|
|
484
478
|
|
|
485
|
-
|
|
486
|
-
|
|
479
|
+
{
|
|
480
|
+
_$_.output_push('<!--[-->');
|
|
487
481
|
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
482
|
+
for (const item of lazy_5.value) {
|
|
483
|
+
_$_.output_push('<li');
|
|
484
|
+
_$_.output_push(_$_.attr('class', `item-${item}`));
|
|
485
|
+
_$_.output_push('>');
|
|
492
486
|
|
|
493
|
-
|
|
494
|
-
|
|
487
|
+
{
|
|
488
|
+
_$_.output_push(_$_.escape(item));
|
|
489
|
+
}
|
|
490
|
+
|
|
491
|
+
_$_.output_push('</li>');
|
|
495
492
|
}
|
|
496
493
|
|
|
497
|
-
_$_.output_push('
|
|
494
|
+
_$_.output_push('<!--]-->');
|
|
498
495
|
}
|
|
499
496
|
|
|
500
|
-
_$_.output_push('
|
|
497
|
+
_$_.output_push('</ul>');
|
|
501
498
|
}
|
|
502
|
-
|
|
503
|
-
_$_.output_push('</ul>');
|
|
504
499
|
});
|
|
505
500
|
});
|
|
506
501
|
}
|
|
@@ -511,33 +506,73 @@ export function ForLoopInsideIf() {
|
|
|
511
506
|
let lazy_7 = _$_.track(['X', 'Y', 'Z'], 'bf375103');
|
|
512
507
|
|
|
513
508
|
_$_.regular_block(() => {
|
|
514
|
-
_$_.output_push('<button');
|
|
515
|
-
_$_.output_push(' class="toggle"');
|
|
516
|
-
_$_.output_push('>');
|
|
517
|
-
|
|
518
509
|
{
|
|
519
|
-
_$_.output_push('
|
|
520
|
-
|
|
510
|
+
_$_.output_push('<button');
|
|
511
|
+
_$_.output_push(' class="toggle"');
|
|
512
|
+
_$_.output_push('>');
|
|
521
513
|
|
|
522
|
-
|
|
523
|
-
|
|
514
|
+
{
|
|
515
|
+
_$_.output_push('Toggle List');
|
|
516
|
+
}
|
|
524
517
|
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
518
|
+
_$_.output_push('</button>');
|
|
519
|
+
_$_.output_push('<button');
|
|
520
|
+
_$_.output_push(' class="add"');
|
|
521
|
+
_$_.output_push('>');
|
|
529
522
|
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
523
|
+
{
|
|
524
|
+
_$_.output_push('Add Item');
|
|
525
|
+
}
|
|
526
|
+
|
|
527
|
+
_$_.output_push('</button>');
|
|
528
|
+
_$_.output_push('<!--[-->');
|
|
529
|
+
|
|
530
|
+
if (lazy_6.value) {
|
|
531
|
+
_$_.output_push('<ul');
|
|
532
|
+
_$_.output_push(' class="list"');
|
|
533
|
+
_$_.output_push('>');
|
|
534
|
+
|
|
535
|
+
{
|
|
536
|
+
_$_.output_push('<!--[-->');
|
|
537
|
+
|
|
538
|
+
for (const item of lazy_7.value) {
|
|
539
|
+
_$_.output_push('<li');
|
|
540
|
+
_$_.output_push('>');
|
|
541
|
+
|
|
542
|
+
{
|
|
543
|
+
_$_.output_push(_$_.escape(item));
|
|
544
|
+
}
|
|
545
|
+
|
|
546
|
+
_$_.output_push('</li>');
|
|
547
|
+
}
|
|
548
|
+
|
|
549
|
+
_$_.output_push('<!--]-->');
|
|
550
|
+
}
|
|
551
|
+
|
|
552
|
+
_$_.output_push('</ul>');
|
|
553
|
+
}
|
|
533
554
|
|
|
534
|
-
|
|
555
|
+
_$_.output_push('<!--]-->');
|
|
556
|
+
}
|
|
535
557
|
});
|
|
558
|
+
});
|
|
559
|
+
}
|
|
560
|
+
|
|
561
|
+
export function ForLoopEmptyToPopulated() {
|
|
562
|
+
return _$_.tsrx_element(() => {
|
|
563
|
+
let lazy_8 = _$_.track([], '525c5dbc');
|
|
536
564
|
|
|
537
565
|
_$_.regular_block(() => {
|
|
538
|
-
|
|
566
|
+
{
|
|
567
|
+
_$_.output_push('<button');
|
|
568
|
+
_$_.output_push(' class="populate"');
|
|
569
|
+
_$_.output_push('>');
|
|
570
|
+
|
|
571
|
+
{
|
|
572
|
+
_$_.output_push('Populate');
|
|
573
|
+
}
|
|
539
574
|
|
|
540
|
-
|
|
575
|
+
_$_.output_push('</button>');
|
|
541
576
|
_$_.output_push('<ul');
|
|
542
577
|
_$_.output_push(' class="list"');
|
|
543
578
|
_$_.output_push('>');
|
|
@@ -545,7 +580,7 @@ export function ForLoopInsideIf() {
|
|
|
545
580
|
{
|
|
546
581
|
_$_.output_push('<!--[-->');
|
|
547
582
|
|
|
548
|
-
for (const item of
|
|
583
|
+
for (const item of lazy_8.value) {
|
|
549
584
|
_$_.output_push('<li');
|
|
550
585
|
_$_.output_push('>');
|
|
551
586
|
|
|
@@ -561,167 +596,123 @@ export function ForLoopInsideIf() {
|
|
|
561
596
|
|
|
562
597
|
_$_.output_push('</ul>');
|
|
563
598
|
}
|
|
564
|
-
|
|
565
|
-
_$_.output_push('<!--]-->');
|
|
566
599
|
});
|
|
567
600
|
});
|
|
568
601
|
}
|
|
569
602
|
|
|
570
|
-
export function
|
|
603
|
+
export function ForLoopPopulatedToEmpty() {
|
|
571
604
|
return _$_.tsrx_element(() => {
|
|
572
|
-
let
|
|
605
|
+
let lazy_9 = _$_.track(['One', 'Two', 'Three'], 'ee47f078');
|
|
573
606
|
|
|
574
607
|
_$_.regular_block(() => {
|
|
575
|
-
_$_.output_push('<button');
|
|
576
|
-
_$_.output_push(' class="populate"');
|
|
577
|
-
_$_.output_push('>');
|
|
578
|
-
|
|
579
608
|
{
|
|
580
|
-
_$_.output_push('
|
|
581
|
-
|
|
609
|
+
_$_.output_push('<button');
|
|
610
|
+
_$_.output_push(' class="clear"');
|
|
611
|
+
_$_.output_push('>');
|
|
582
612
|
|
|
583
|
-
|
|
584
|
-
|
|
613
|
+
{
|
|
614
|
+
_$_.output_push('Clear');
|
|
615
|
+
}
|
|
585
616
|
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
617
|
+
_$_.output_push('</button>');
|
|
618
|
+
_$_.output_push('<ul');
|
|
619
|
+
_$_.output_push(' class="list"');
|
|
620
|
+
_$_.output_push('>');
|
|
590
621
|
|
|
591
|
-
|
|
592
|
-
|
|
622
|
+
{
|
|
623
|
+
_$_.output_push('<!--[-->');
|
|
593
624
|
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
625
|
+
for (const item of lazy_9.value) {
|
|
626
|
+
_$_.output_push('<li');
|
|
627
|
+
_$_.output_push('>');
|
|
597
628
|
|
|
598
|
-
|
|
599
|
-
|
|
629
|
+
{
|
|
630
|
+
_$_.output_push(_$_.escape(item));
|
|
631
|
+
}
|
|
632
|
+
|
|
633
|
+
_$_.output_push('</li>');
|
|
600
634
|
}
|
|
601
635
|
|
|
602
|
-
_$_.output_push('
|
|
636
|
+
_$_.output_push('<!--]-->');
|
|
603
637
|
}
|
|
604
638
|
|
|
605
|
-
_$_.output_push('
|
|
639
|
+
_$_.output_push('</ul>');
|
|
606
640
|
}
|
|
607
|
-
|
|
608
|
-
_$_.output_push('</ul>');
|
|
609
641
|
});
|
|
610
642
|
});
|
|
611
643
|
}
|
|
612
644
|
|
|
613
|
-
export function
|
|
645
|
+
export function NestedForLoopReactive() {
|
|
614
646
|
return _$_.tsrx_element(() => {
|
|
615
|
-
let
|
|
647
|
+
let lazy_10 = _$_.track([[1, 2], [3, 4]], 'a2f41fb3');
|
|
616
648
|
|
|
617
649
|
_$_.regular_block(() => {
|
|
618
|
-
_$_.output_push('<
|
|
619
|
-
_$_.output_push(' class="
|
|
650
|
+
_$_.output_push('<div');
|
|
651
|
+
_$_.output_push(' class="nested-for-reactive"');
|
|
620
652
|
_$_.output_push('>');
|
|
621
653
|
|
|
622
654
|
{
|
|
623
|
-
_$_.output_push('
|
|
624
|
-
|
|
655
|
+
_$_.output_push('<button');
|
|
656
|
+
_$_.output_push(' class="add-row"');
|
|
657
|
+
_$_.output_push('>');
|
|
625
658
|
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
_$_.regular_block(() => {
|
|
630
|
-
_$_.output_push('<ul');
|
|
631
|
-
_$_.output_push(' class="list"');
|
|
632
|
-
_$_.output_push('>');
|
|
633
|
-
|
|
634
|
-
{
|
|
635
|
-
_$_.output_push('<!--[-->');
|
|
636
|
-
|
|
637
|
-
for (const item of lazy_9.value) {
|
|
638
|
-
_$_.output_push('<li');
|
|
639
|
-
_$_.output_push('>');
|
|
640
|
-
|
|
641
|
-
{
|
|
642
|
-
_$_.output_push(_$_.escape(item));
|
|
643
|
-
}
|
|
644
|
-
|
|
645
|
-
_$_.output_push('</li>');
|
|
659
|
+
{
|
|
660
|
+
_$_.output_push('Add Row');
|
|
646
661
|
}
|
|
647
662
|
|
|
648
|
-
_$_.output_push('
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
});
|
|
653
|
-
});
|
|
654
|
-
}
|
|
655
|
-
|
|
656
|
-
export function NestedForLoopReactive() {
|
|
657
|
-
return _$_.tsrx_element(() => {
|
|
658
|
-
let lazy_10 = _$_.track([[1, 2], [3, 4]], 'a2f41fb3');
|
|
659
|
-
|
|
660
|
-
_$_.regular_block(() => {
|
|
661
|
-
_$_.output_push('<button');
|
|
662
|
-
_$_.output_push(' class="add-row"');
|
|
663
|
-
_$_.output_push('>');
|
|
664
|
-
|
|
665
|
-
{
|
|
666
|
-
_$_.output_push('Add Row');
|
|
667
|
-
}
|
|
668
|
-
|
|
669
|
-
_$_.output_push('</button>');
|
|
670
|
-
});
|
|
671
|
-
|
|
672
|
-
_$_.regular_block(() => {
|
|
673
|
-
_$_.output_push('<button');
|
|
674
|
-
_$_.output_push(' class="update-cell"');
|
|
675
|
-
_$_.output_push('>');
|
|
663
|
+
_$_.output_push('</button>');
|
|
664
|
+
_$_.output_push('<button');
|
|
665
|
+
_$_.output_push(' class="update-cell"');
|
|
666
|
+
_$_.output_push('>');
|
|
676
667
|
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
|
|
668
|
+
{
|
|
669
|
+
_$_.output_push('Update Cell');
|
|
670
|
+
}
|
|
680
671
|
|
|
681
|
-
|
|
682
|
-
|
|
672
|
+
_$_.output_push('</button>');
|
|
673
|
+
_$_.output_push('<div');
|
|
674
|
+
_$_.output_push(' class="grid"');
|
|
675
|
+
_$_.output_push('>');
|
|
683
676
|
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
_$_.output_push(' class="grid"');
|
|
687
|
-
_$_.output_push('>');
|
|
677
|
+
{
|
|
678
|
+
_$_.output_push('<!--[-->');
|
|
688
679
|
|
|
689
|
-
|
|
690
|
-
_$_.output_push('<!--[-->');
|
|
680
|
+
var rowIndex = 0;
|
|
691
681
|
|
|
692
|
-
|
|
682
|
+
for (const row of lazy_10.value) {
|
|
683
|
+
_$_.output_push('<div');
|
|
684
|
+
_$_.output_push(_$_.attr('class', `row-${rowIndex}`));
|
|
685
|
+
_$_.output_push('>');
|
|
693
686
|
|
|
694
|
-
|
|
695
|
-
|
|
696
|
-
_$_.output_push(_$_.attr('class', `row-${rowIndex}`));
|
|
697
|
-
_$_.output_push('>');
|
|
687
|
+
{
|
|
688
|
+
_$_.output_push('<!--[-->');
|
|
698
689
|
|
|
699
|
-
|
|
700
|
-
_$_.output_push('<!--[-->');
|
|
690
|
+
var colIndex = 0;
|
|
701
691
|
|
|
702
|
-
|
|
692
|
+
for (const cell of row) {
|
|
693
|
+
_$_.output_push('<span');
|
|
694
|
+
_$_.output_push(_$_.attr('class', `cell-${rowIndex}-${colIndex}`));
|
|
695
|
+
_$_.output_push('>');
|
|
703
696
|
|
|
704
|
-
|
|
705
|
-
|
|
706
|
-
|
|
707
|
-
_$_.output_push('>');
|
|
697
|
+
{
|
|
698
|
+
_$_.output_push(_$_.escape(cell));
|
|
699
|
+
}
|
|
708
700
|
|
|
709
|
-
|
|
710
|
-
|
|
701
|
+
_$_.output_push('</span>');
|
|
702
|
+
colIndex++;
|
|
711
703
|
}
|
|
712
704
|
|
|
713
|
-
_$_.output_push('
|
|
714
|
-
colIndex++;
|
|
705
|
+
_$_.output_push('<!--]-->');
|
|
715
706
|
}
|
|
716
707
|
|
|
717
|
-
_$_.output_push('
|
|
708
|
+
_$_.output_push('</div>');
|
|
709
|
+
rowIndex++;
|
|
718
710
|
}
|
|
719
711
|
|
|
720
|
-
_$_.output_push('
|
|
721
|
-
rowIndex++;
|
|
712
|
+
_$_.output_push('<!--]-->');
|
|
722
713
|
}
|
|
723
714
|
|
|
724
|
-
_$_.output_push('
|
|
715
|
+
_$_.output_push('</div>');
|
|
725
716
|
}
|
|
726
717
|
|
|
727
718
|
_$_.output_push('</div>');
|
|
@@ -834,43 +825,42 @@ export function ForLoopIndexUpdate() {
|
|
|
834
825
|
let lazy_11 = _$_.track(['First', 'Second', 'Third'], 'f61e31e6');
|
|
835
826
|
|
|
836
827
|
_$_.regular_block(() => {
|
|
837
|
-
_$_.output_push('<button');
|
|
838
|
-
_$_.output_push(' class="prepend"');
|
|
839
|
-
_$_.output_push('>');
|
|
840
|
-
|
|
841
828
|
{
|
|
842
|
-
_$_.output_push('
|
|
843
|
-
|
|
829
|
+
_$_.output_push('<button');
|
|
830
|
+
_$_.output_push(' class="prepend"');
|
|
831
|
+
_$_.output_push('>');
|
|
844
832
|
|
|
845
|
-
|
|
846
|
-
|
|
833
|
+
{
|
|
834
|
+
_$_.output_push('Prepend');
|
|
835
|
+
}
|
|
847
836
|
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
|
|
837
|
+
_$_.output_push('</button>');
|
|
838
|
+
_$_.output_push('<ul');
|
|
839
|
+
_$_.output_push('>');
|
|
851
840
|
|
|
852
|
-
|
|
853
|
-
|
|
841
|
+
{
|
|
842
|
+
_$_.output_push('<!--[-->');
|
|
854
843
|
|
|
855
|
-
|
|
844
|
+
var i = 0;
|
|
856
845
|
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
|
|
860
|
-
|
|
846
|
+
for (const item of lazy_11.value) {
|
|
847
|
+
_$_.output_push('<li');
|
|
848
|
+
_$_.output_push(_$_.attr('class', `item-${i}`));
|
|
849
|
+
_$_.output_push('>');
|
|
861
850
|
|
|
862
|
-
|
|
863
|
-
|
|
851
|
+
{
|
|
852
|
+
_$_.output_push(_$_.escape(`[${i}] ${item}`));
|
|
853
|
+
}
|
|
854
|
+
|
|
855
|
+
_$_.output_push('</li>');
|
|
856
|
+
i++;
|
|
864
857
|
}
|
|
865
858
|
|
|
866
|
-
_$_.output_push('
|
|
867
|
-
i++;
|
|
859
|
+
_$_.output_push('<!--]-->');
|
|
868
860
|
}
|
|
869
861
|
|
|
870
|
-
_$_.output_push('
|
|
862
|
+
_$_.output_push('</ul>');
|
|
871
863
|
}
|
|
872
|
-
|
|
873
|
-
_$_.output_push('</ul>');
|
|
874
864
|
});
|
|
875
865
|
});
|
|
876
866
|
}
|
|
@@ -887,44 +877,43 @@ export function KeyedForLoopWithIndex() {
|
|
|
887
877
|
);
|
|
888
878
|
|
|
889
879
|
_$_.regular_block(() => {
|
|
890
|
-
_$_.output_push('<button');
|
|
891
|
-
_$_.output_push(' class="reorder"');
|
|
892
|
-
_$_.output_push('>');
|
|
893
|
-
|
|
894
880
|
{
|
|
895
|
-
_$_.output_push('
|
|
896
|
-
|
|
881
|
+
_$_.output_push('<button');
|
|
882
|
+
_$_.output_push(' class="reorder"');
|
|
883
|
+
_$_.output_push('>');
|
|
897
884
|
|
|
898
|
-
|
|
899
|
-
|
|
885
|
+
{
|
|
886
|
+
_$_.output_push('Rotate');
|
|
887
|
+
}
|
|
900
888
|
|
|
901
|
-
|
|
902
|
-
|
|
903
|
-
|
|
889
|
+
_$_.output_push('</button>');
|
|
890
|
+
_$_.output_push('<ul');
|
|
891
|
+
_$_.output_push('>');
|
|
904
892
|
|
|
905
|
-
|
|
906
|
-
|
|
893
|
+
{
|
|
894
|
+
_$_.output_push('<!--[-->');
|
|
907
895
|
|
|
908
|
-
|
|
896
|
+
var i = 0;
|
|
909
897
|
|
|
910
|
-
|
|
911
|
-
|
|
912
|
-
|
|
913
|
-
|
|
914
|
-
|
|
898
|
+
for (const item of lazy_12.value) {
|
|
899
|
+
_$_.output_push('<li');
|
|
900
|
+
_$_.output_push(_$_.attr('data-index', i, false));
|
|
901
|
+
_$_.output_push(_$_.attr('class', `item-${item.id}`));
|
|
902
|
+
_$_.output_push('>');
|
|
915
903
|
|
|
916
|
-
|
|
917
|
-
|
|
904
|
+
{
|
|
905
|
+
_$_.output_push(_$_.escape(`[${i}] ${item.id}: ${item.value}`));
|
|
906
|
+
}
|
|
907
|
+
|
|
908
|
+
_$_.output_push('</li>');
|
|
909
|
+
i++;
|
|
918
910
|
}
|
|
919
911
|
|
|
920
|
-
_$_.output_push('
|
|
921
|
-
i++;
|
|
912
|
+
_$_.output_push('<!--]-->');
|
|
922
913
|
}
|
|
923
914
|
|
|
924
|
-
_$_.output_push('
|
|
915
|
+
_$_.output_push('</ul>');
|
|
925
916
|
}
|
|
926
|
-
|
|
927
|
-
_$_.output_push('</ul>');
|
|
928
917
|
});
|
|
929
918
|
});
|
|
930
919
|
}
|
|
@@ -934,59 +923,58 @@ export function ForLoopWithSiblings() {
|
|
|
934
923
|
let lazy_13 = _$_.track(['A', 'B'], '3c7e8152');
|
|
935
924
|
|
|
936
925
|
_$_.regular_block(() => {
|
|
937
|
-
_$_.output_push('<div');
|
|
938
|
-
_$_.output_push(' class="wrapper"');
|
|
939
|
-
_$_.output_push('>');
|
|
940
|
-
|
|
941
926
|
{
|
|
942
|
-
_$_.output_push('<
|
|
943
|
-
_$_.output_push(' class="
|
|
927
|
+
_$_.output_push('<div');
|
|
928
|
+
_$_.output_push(' class="wrapper"');
|
|
944
929
|
_$_.output_push('>');
|
|
945
930
|
|
|
946
931
|
{
|
|
947
|
-
_$_.output_push('
|
|
948
|
-
|
|
932
|
+
_$_.output_push('<header');
|
|
933
|
+
_$_.output_push(' class="before"');
|
|
934
|
+
_$_.output_push('>');
|
|
949
935
|
|
|
950
|
-
|
|
951
|
-
|
|
936
|
+
{
|
|
937
|
+
_$_.output_push('Before');
|
|
938
|
+
}
|
|
952
939
|
|
|
953
|
-
|
|
954
|
-
_$_.output_push('
|
|
955
|
-
|
|
940
|
+
_$_.output_push('</header>');
|
|
941
|
+
_$_.output_push('<!--[-->');
|
|
942
|
+
|
|
943
|
+
for (const item of lazy_13.value) {
|
|
944
|
+
_$_.output_push('<div');
|
|
945
|
+
_$_.output_push(_$_.attr('class', `item-${item}`));
|
|
946
|
+
_$_.output_push('>');
|
|
947
|
+
|
|
948
|
+
{
|
|
949
|
+
_$_.output_push(_$_.escape(item));
|
|
950
|
+
}
|
|
951
|
+
|
|
952
|
+
_$_.output_push('</div>');
|
|
953
|
+
}
|
|
954
|
+
|
|
955
|
+
_$_.output_push('<!--]-->');
|
|
956
|
+
_$_.output_push('<footer');
|
|
957
|
+
_$_.output_push(' class="after"');
|
|
956
958
|
_$_.output_push('>');
|
|
957
959
|
|
|
958
960
|
{
|
|
959
|
-
_$_.output_push(
|
|
961
|
+
_$_.output_push('After');
|
|
960
962
|
}
|
|
961
963
|
|
|
962
|
-
_$_.output_push('</
|
|
964
|
+
_$_.output_push('</footer>');
|
|
963
965
|
}
|
|
964
966
|
|
|
965
|
-
_$_.output_push('
|
|
966
|
-
_$_.output_push('<
|
|
967
|
-
_$_.output_push(' class="
|
|
967
|
+
_$_.output_push('</div>');
|
|
968
|
+
_$_.output_push('<button');
|
|
969
|
+
_$_.output_push(' class="add"');
|
|
968
970
|
_$_.output_push('>');
|
|
969
971
|
|
|
970
972
|
{
|
|
971
|
-
_$_.output_push('
|
|
973
|
+
_$_.output_push('Add');
|
|
972
974
|
}
|
|
973
975
|
|
|
974
|
-
_$_.output_push('</
|
|
975
|
-
}
|
|
976
|
-
|
|
977
|
-
_$_.output_push('</div>');
|
|
978
|
-
});
|
|
979
|
-
|
|
980
|
-
_$_.regular_block(() => {
|
|
981
|
-
_$_.output_push('<button');
|
|
982
|
-
_$_.output_push(' class="add"');
|
|
983
|
-
_$_.output_push('>');
|
|
984
|
-
|
|
985
|
-
{
|
|
986
|
-
_$_.output_push('Add');
|
|
976
|
+
_$_.output_push('</button>');
|
|
987
977
|
}
|
|
988
|
-
|
|
989
|
-
_$_.output_push('</button>');
|
|
990
978
|
});
|
|
991
979
|
});
|
|
992
980
|
}
|
|
@@ -1090,40 +1078,39 @@ export function ForLoopAddAtBeginning() {
|
|
|
1090
1078
|
let lazy_15 = _$_.track(['B', 'C'], '1561403a');
|
|
1091
1079
|
|
|
1092
1080
|
_$_.regular_block(() => {
|
|
1093
|
-
_$_.output_push('<button');
|
|
1094
|
-
_$_.output_push(' class="prepend"');
|
|
1095
|
-
_$_.output_push('>');
|
|
1096
|
-
|
|
1097
1081
|
{
|
|
1098
|
-
_$_.output_push('
|
|
1099
|
-
|
|
1082
|
+
_$_.output_push('<button');
|
|
1083
|
+
_$_.output_push(' class="prepend"');
|
|
1084
|
+
_$_.output_push('>');
|
|
1100
1085
|
|
|
1101
|
-
|
|
1102
|
-
|
|
1086
|
+
{
|
|
1087
|
+
_$_.output_push('Prepend A');
|
|
1088
|
+
}
|
|
1103
1089
|
|
|
1104
|
-
|
|
1105
|
-
|
|
1106
|
-
|
|
1090
|
+
_$_.output_push('</button>');
|
|
1091
|
+
_$_.output_push('<ul');
|
|
1092
|
+
_$_.output_push('>');
|
|
1107
1093
|
|
|
1108
|
-
|
|
1109
|
-
|
|
1094
|
+
{
|
|
1095
|
+
_$_.output_push('<!--[-->');
|
|
1110
1096
|
|
|
1111
|
-
|
|
1112
|
-
|
|
1113
|
-
|
|
1114
|
-
|
|
1097
|
+
for (const item of lazy_15.value) {
|
|
1098
|
+
_$_.output_push('<li');
|
|
1099
|
+
_$_.output_push(_$_.attr('class', `item-${item}`));
|
|
1100
|
+
_$_.output_push('>');
|
|
1115
1101
|
|
|
1116
|
-
|
|
1117
|
-
|
|
1102
|
+
{
|
|
1103
|
+
_$_.output_push(_$_.escape(item));
|
|
1104
|
+
}
|
|
1105
|
+
|
|
1106
|
+
_$_.output_push('</li>');
|
|
1118
1107
|
}
|
|
1119
1108
|
|
|
1120
|
-
_$_.output_push('
|
|
1109
|
+
_$_.output_push('<!--]-->');
|
|
1121
1110
|
}
|
|
1122
1111
|
|
|
1123
|
-
_$_.output_push('
|
|
1112
|
+
_$_.output_push('</ul>');
|
|
1124
1113
|
}
|
|
1125
|
-
|
|
1126
|
-
_$_.output_push('</ul>');
|
|
1127
1114
|
});
|
|
1128
1115
|
});
|
|
1129
1116
|
}
|
|
@@ -1133,40 +1120,39 @@ export function ForLoopAddInMiddle() {
|
|
|
1133
1120
|
let lazy_16 = _$_.track(['A', 'C'], '1bc60b46');
|
|
1134
1121
|
|
|
1135
1122
|
_$_.regular_block(() => {
|
|
1136
|
-
_$_.output_push('<button');
|
|
1137
|
-
_$_.output_push(' class="insert"');
|
|
1138
|
-
_$_.output_push('>');
|
|
1139
|
-
|
|
1140
1123
|
{
|
|
1141
|
-
_$_.output_push('
|
|
1142
|
-
|
|
1124
|
+
_$_.output_push('<button');
|
|
1125
|
+
_$_.output_push(' class="insert"');
|
|
1126
|
+
_$_.output_push('>');
|
|
1143
1127
|
|
|
1144
|
-
|
|
1145
|
-
|
|
1128
|
+
{
|
|
1129
|
+
_$_.output_push('Insert B');
|
|
1130
|
+
}
|
|
1146
1131
|
|
|
1147
|
-
|
|
1148
|
-
|
|
1149
|
-
|
|
1132
|
+
_$_.output_push('</button>');
|
|
1133
|
+
_$_.output_push('<ul');
|
|
1134
|
+
_$_.output_push('>');
|
|
1150
1135
|
|
|
1151
|
-
|
|
1152
|
-
|
|
1136
|
+
{
|
|
1137
|
+
_$_.output_push('<!--[-->');
|
|
1153
1138
|
|
|
1154
|
-
|
|
1155
|
-
|
|
1156
|
-
|
|
1157
|
-
|
|
1139
|
+
for (const item of lazy_16.value) {
|
|
1140
|
+
_$_.output_push('<li');
|
|
1141
|
+
_$_.output_push(_$_.attr('class', `item-${item}`));
|
|
1142
|
+
_$_.output_push('>');
|
|
1158
1143
|
|
|
1159
|
-
|
|
1160
|
-
|
|
1144
|
+
{
|
|
1145
|
+
_$_.output_push(_$_.escape(item));
|
|
1146
|
+
}
|
|
1147
|
+
|
|
1148
|
+
_$_.output_push('</li>');
|
|
1161
1149
|
}
|
|
1162
1150
|
|
|
1163
|
-
_$_.output_push('
|
|
1151
|
+
_$_.output_push('<!--]-->');
|
|
1164
1152
|
}
|
|
1165
1153
|
|
|
1166
|
-
_$_.output_push('
|
|
1154
|
+
_$_.output_push('</ul>');
|
|
1167
1155
|
}
|
|
1168
|
-
|
|
1169
|
-
_$_.output_push('</ul>');
|
|
1170
1156
|
});
|
|
1171
1157
|
});
|
|
1172
1158
|
}
|
|
@@ -1176,40 +1162,39 @@ export function ForLoopRemoveFromMiddle() {
|
|
|
1176
1162
|
let lazy_17 = _$_.track(['A', 'B', 'C'], '1c87f95f');
|
|
1177
1163
|
|
|
1178
1164
|
_$_.regular_block(() => {
|
|
1179
|
-
_$_.output_push('<button');
|
|
1180
|
-
_$_.output_push(' class="remove-middle"');
|
|
1181
|
-
_$_.output_push('>');
|
|
1182
|
-
|
|
1183
1165
|
{
|
|
1184
|
-
_$_.output_push('
|
|
1185
|
-
|
|
1166
|
+
_$_.output_push('<button');
|
|
1167
|
+
_$_.output_push(' class="remove-middle"');
|
|
1168
|
+
_$_.output_push('>');
|
|
1186
1169
|
|
|
1187
|
-
|
|
1188
|
-
|
|
1170
|
+
{
|
|
1171
|
+
_$_.output_push('Remove B');
|
|
1172
|
+
}
|
|
1189
1173
|
|
|
1190
|
-
|
|
1191
|
-
|
|
1192
|
-
|
|
1174
|
+
_$_.output_push('</button>');
|
|
1175
|
+
_$_.output_push('<ul');
|
|
1176
|
+
_$_.output_push('>');
|
|
1193
1177
|
|
|
1194
|
-
|
|
1195
|
-
|
|
1178
|
+
{
|
|
1179
|
+
_$_.output_push('<!--[-->');
|
|
1196
1180
|
|
|
1197
|
-
|
|
1198
|
-
|
|
1199
|
-
|
|
1200
|
-
|
|
1181
|
+
for (const item of lazy_17.value) {
|
|
1182
|
+
_$_.output_push('<li');
|
|
1183
|
+
_$_.output_push(_$_.attr('class', `item-${item}`));
|
|
1184
|
+
_$_.output_push('>');
|
|
1201
1185
|
|
|
1202
|
-
|
|
1203
|
-
|
|
1186
|
+
{
|
|
1187
|
+
_$_.output_push(_$_.escape(item));
|
|
1188
|
+
}
|
|
1189
|
+
|
|
1190
|
+
_$_.output_push('</li>');
|
|
1204
1191
|
}
|
|
1205
1192
|
|
|
1206
|
-
_$_.output_push('
|
|
1193
|
+
_$_.output_push('<!--]-->');
|
|
1207
1194
|
}
|
|
1208
1195
|
|
|
1209
|
-
_$_.output_push('
|
|
1196
|
+
_$_.output_push('</ul>');
|
|
1210
1197
|
}
|
|
1211
|
-
|
|
1212
|
-
_$_.output_push('</ul>');
|
|
1213
1198
|
});
|
|
1214
1199
|
});
|
|
1215
1200
|
}
|
|
@@ -1254,40 +1239,39 @@ export function ForLoopSwap() {
|
|
|
1254
1239
|
let lazy_18 = _$_.track(['A', 'B', 'C', 'D'], '5f8d152f');
|
|
1255
1240
|
|
|
1256
1241
|
_$_.regular_block(() => {
|
|
1257
|
-
_$_.output_push('<button');
|
|
1258
|
-
_$_.output_push(' class="swap"');
|
|
1259
|
-
_$_.output_push('>');
|
|
1260
|
-
|
|
1261
1242
|
{
|
|
1262
|
-
_$_.output_push('
|
|
1263
|
-
|
|
1243
|
+
_$_.output_push('<button');
|
|
1244
|
+
_$_.output_push(' class="swap"');
|
|
1245
|
+
_$_.output_push('>');
|
|
1264
1246
|
|
|
1265
|
-
|
|
1266
|
-
|
|
1247
|
+
{
|
|
1248
|
+
_$_.output_push('Swap First and Last');
|
|
1249
|
+
}
|
|
1267
1250
|
|
|
1268
|
-
|
|
1269
|
-
|
|
1270
|
-
|
|
1251
|
+
_$_.output_push('</button>');
|
|
1252
|
+
_$_.output_push('<ul');
|
|
1253
|
+
_$_.output_push('>');
|
|
1271
1254
|
|
|
1272
|
-
|
|
1273
|
-
|
|
1255
|
+
{
|
|
1256
|
+
_$_.output_push('<!--[-->');
|
|
1274
1257
|
|
|
1275
|
-
|
|
1276
|
-
|
|
1277
|
-
|
|
1278
|
-
|
|
1258
|
+
for (const item of lazy_18.value) {
|
|
1259
|
+
_$_.output_push('<li');
|
|
1260
|
+
_$_.output_push(_$_.attr('class', `item-${item}`));
|
|
1261
|
+
_$_.output_push('>');
|
|
1279
1262
|
|
|
1280
|
-
|
|
1281
|
-
|
|
1263
|
+
{
|
|
1264
|
+
_$_.output_push(_$_.escape(item));
|
|
1265
|
+
}
|
|
1266
|
+
|
|
1267
|
+
_$_.output_push('</li>');
|
|
1282
1268
|
}
|
|
1283
1269
|
|
|
1284
|
-
_$_.output_push('
|
|
1270
|
+
_$_.output_push('<!--]-->');
|
|
1285
1271
|
}
|
|
1286
1272
|
|
|
1287
|
-
_$_.output_push('
|
|
1273
|
+
_$_.output_push('</ul>');
|
|
1288
1274
|
}
|
|
1289
|
-
|
|
1290
|
-
_$_.output_push('</ul>');
|
|
1291
1275
|
});
|
|
1292
1276
|
});
|
|
1293
1277
|
}
|
|
@@ -1297,40 +1281,39 @@ export function ForLoopReverse() {
|
|
|
1297
1281
|
let lazy_19 = _$_.track(['A', 'B', 'C', 'D'], '24602e64');
|
|
1298
1282
|
|
|
1299
1283
|
_$_.regular_block(() => {
|
|
1300
|
-
_$_.output_push('<button');
|
|
1301
|
-
_$_.output_push(' class="reverse"');
|
|
1302
|
-
_$_.output_push('>');
|
|
1303
|
-
|
|
1304
1284
|
{
|
|
1305
|
-
_$_.output_push('
|
|
1306
|
-
|
|
1285
|
+
_$_.output_push('<button');
|
|
1286
|
+
_$_.output_push(' class="reverse"');
|
|
1287
|
+
_$_.output_push('>');
|
|
1307
1288
|
|
|
1308
|
-
|
|
1309
|
-
|
|
1289
|
+
{
|
|
1290
|
+
_$_.output_push('Reverse');
|
|
1291
|
+
}
|
|
1310
1292
|
|
|
1311
|
-
|
|
1312
|
-
|
|
1313
|
-
|
|
1293
|
+
_$_.output_push('</button>');
|
|
1294
|
+
_$_.output_push('<ul');
|
|
1295
|
+
_$_.output_push('>');
|
|
1314
1296
|
|
|
1315
|
-
|
|
1316
|
-
|
|
1297
|
+
{
|
|
1298
|
+
_$_.output_push('<!--[-->');
|
|
1317
1299
|
|
|
1318
|
-
|
|
1319
|
-
|
|
1320
|
-
|
|
1321
|
-
|
|
1300
|
+
for (const item of lazy_19.value) {
|
|
1301
|
+
_$_.output_push('<li');
|
|
1302
|
+
_$_.output_push(_$_.attr('class', `item-${item}`));
|
|
1303
|
+
_$_.output_push('>');
|
|
1322
1304
|
|
|
1323
|
-
|
|
1324
|
-
|
|
1305
|
+
{
|
|
1306
|
+
_$_.output_push(_$_.escape(item));
|
|
1307
|
+
}
|
|
1308
|
+
|
|
1309
|
+
_$_.output_push('</li>');
|
|
1325
1310
|
}
|
|
1326
1311
|
|
|
1327
|
-
_$_.output_push('
|
|
1312
|
+
_$_.output_push('<!--]-->');
|
|
1328
1313
|
}
|
|
1329
1314
|
|
|
1330
|
-
_$_.output_push('
|
|
1315
|
+
_$_.output_push('</ul>');
|
|
1331
1316
|
}
|
|
1332
|
-
|
|
1333
|
-
_$_.output_push('</ul>');
|
|
1334
1317
|
});
|
|
1335
1318
|
});
|
|
1336
1319
|
}
|