ripple 0.3.9 → 0.3.11
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 +43 -0
- package/package.json +2 -2
- package/src/compiler/errors.js +1 -1
- package/src/compiler/index.d.ts +3 -1
- package/src/compiler/phases/1-parse/index.js +195 -23
- package/src/compiler/phases/2-analyze/index.js +266 -108
- package/src/compiler/phases/2-analyze/prune.js +13 -5
- package/src/compiler/phases/3-transform/client/index.js +304 -80
- package/src/compiler/phases/3-transform/server/index.js +108 -43
- package/src/compiler/types/index.d.ts +28 -3
- package/src/compiler/types/parse.d.ts +3 -1
- package/src/compiler/utils.js +275 -1
- package/src/runtime/element.js +39 -0
- package/src/runtime/index-client.js +14 -4
- package/src/runtime/internal/client/composite.js +10 -6
- package/src/runtime/internal/client/expression.js +280 -0
- package/src/runtime/internal/client/index.js +4 -0
- package/src/runtime/internal/client/portal.js +12 -6
- package/src/runtime/internal/server/index.js +26 -1
- package/src/utils/builders.js +30 -0
- package/tests/client/basic/__snapshots__/basic.rendering.test.ripple.snap +1 -0
- package/tests/client/basic/basic.components.test.ripple +85 -87
- package/tests/client/basic/basic.errors.test.ripple +4 -8
- package/tests/client/basic/basic.rendering.test.ripple +27 -10
- package/tests/client/capture-error.js +12 -0
- package/tests/client/compiler/compiler.basic.test.ripple +76 -6
- package/tests/client/composite/composite.props.test.ripple +1 -3
- package/tests/client/composite/composite.render.test.ripple +91 -13
- package/tests/client/css/global-additional-cases.test.ripple +3 -3
- package/tests/client/return.test.ripple +101 -0
- package/tests/client/svg.test.ripple +4 -4
- package/tests/client/tsx.test.ripple +486 -0
- package/tests/hydration/basic.test.js +23 -0
- package/tests/hydration/compiled/client/basic.js +111 -75
- package/tests/hydration/compiled/client/composite.js +81 -46
- package/tests/hydration/compiled/client/events.js +18 -63
- package/tests/hydration/compiled/client/for.js +90 -183
- package/tests/hydration/compiled/client/head.js +10 -25
- package/tests/hydration/compiled/client/hmr.js +10 -13
- package/tests/hydration/compiled/client/html.js +251 -380
- package/tests/hydration/compiled/client/if-children.js +35 -45
- package/tests/hydration/compiled/client/if.js +2 -2
- package/tests/hydration/compiled/client/mixed-control-flow.js +24 -72
- package/tests/hydration/compiled/client/nested-control-flow.js +115 -391
- package/tests/hydration/compiled/client/portal.js +8 -20
- package/tests/hydration/compiled/client/reactivity.js +14 -47
- package/tests/hydration/compiled/client/return.js +2 -5
- package/tests/hydration/compiled/client/try.js +4 -4
- package/tests/hydration/compiled/server/basic.js +64 -31
- package/tests/hydration/compiled/server/composite.js +62 -29
- package/tests/hydration/compiled/server/hmr.js +24 -37
- package/tests/hydration/compiled/server/html.js +472 -611
- package/tests/hydration/compiled/server/if-children.js +77 -103
- package/tests/hydration/compiled/server/portal.js +8 -8
- package/tests/hydration/components/basic.ripple +15 -5
- package/tests/hydration/components/composite.ripple +13 -1
- package/tests/hydration/components/hmr.ripple +1 -3
- package/tests/hydration/components/html.ripple +13 -35
- package/tests/hydration/components/if-children.ripple +4 -8
- package/tests/hydration/composite.test.js +11 -0
- package/tests/server/basic.attributes.test.ripple +50 -0
- package/tests/server/basic.components.test.ripple +22 -28
- package/tests/server/basic.test.ripple +12 -0
- package/tests/server/compiler.test.ripple +25 -8
- package/tests/server/composite.props.test.ripple +1 -3
- package/tests/server/style-identifier.test.ripple +2 -4
- package/tests/utils/compiler-compat-config.test.js +38 -0
- package/tests/utils/vite-plugin-config.test.js +113 -0
- package/tsconfig.typecheck.json +2 -1
- package/types/index.d.ts +8 -11
|
@@ -13,19 +13,23 @@ var root_8 = _$_.template(`<!><!>`, 1, 2);
|
|
|
13
13
|
var root_9 = _$_.template(`<div> </div>`, 0);
|
|
14
14
|
var root_10 = _$_.template(`<!>`, 1, 1);
|
|
15
15
|
var root_11 = _$_.template(`<div> </div><span> </span>`, 1, 2);
|
|
16
|
-
var root_12 = _$_.template(`<
|
|
17
|
-
var root_13 = _$_.template(`<!><
|
|
18
|
-
var root_14 = _$_.template(`<h1 class="sr-only">
|
|
19
|
-
var
|
|
20
|
-
var
|
|
21
|
-
var
|
|
22
|
-
var
|
|
23
|
-
var
|
|
24
|
-
var
|
|
25
|
-
var
|
|
26
|
-
var
|
|
27
|
-
var root_23 = _$_.template(`<
|
|
28
|
-
var root_24 = _$_.template(`<
|
|
16
|
+
var root_12 = _$_.template(`<div class="text-prop"><!></div>`, 0);
|
|
17
|
+
var root_13 = _$_.template(`<!><button class="show-text">Show</button>`, 1, 2);
|
|
18
|
+
var root_14 = _$_.template(`<h1 class="sr-only">heading</h1><p class="subtitle">first paragraph</p><p class="subtitle">second paragraph</p>`, 1, 3);
|
|
19
|
+
var root_15 = _$_.template(`<!><span class="sibling1"> </span><span class="sibling2"> </span>`, 1, 3);
|
|
20
|
+
var root_16 = _$_.template(`<h1 class="sr-only">Ripple</h1><img src="/images/logo.png" alt="Logo" class="logo"><p class="subtitle">the elegant TypeScript UI framework</p>`, 1, 3);
|
|
21
|
+
var root_18 = _$_.template(`<a href="/playground" class="playground-link">Playground</a>`, 0);
|
|
22
|
+
var root_17 = _$_.template(`<div class="social-links"><a href="https://github.com" class="github-link">GitHub</a><a href="https://discord.com" class="discord-link">Discord</a><!></div>`, 0);
|
|
23
|
+
var root_19 = _$_.template(`<main><div class="container"><!></div></main>`, 0);
|
|
24
|
+
var root_20 = _$_.template(`<div class="content"><p>Some content here</p></div>`, 0);
|
|
25
|
+
var root_22 = _$_.template(`<!><!><!><!>`, 1, 4);
|
|
26
|
+
var root_21 = _$_.template(`<!>`, 1, 1);
|
|
27
|
+
var root_23 = _$_.template(`<footer class="last-child">I am the last child</footer>`, 0);
|
|
28
|
+
var root_24 = _$_.template(`<div class="wrapper"><h1>Header</h1><p>Some content</p><!></div>`, 0);
|
|
29
|
+
var root_25 = _$_.template(`<div class="inner"><span>Inner text</span><!></div>`, 0);
|
|
30
|
+
var root_26 = _$_.template(`<section class="outer"><h2>Section title</h2><!></section>`, 0);
|
|
31
|
+
|
|
32
|
+
import { track } from 'ripple';
|
|
29
33
|
|
|
30
34
|
export function StaticText(__anchor, _, __block) {
|
|
31
35
|
_$_.push_component();
|
|
@@ -129,15 +133,12 @@ export function Greeting(__anchor, props, __block) {
|
|
|
129
133
|
var div_6 = root_9();
|
|
130
134
|
|
|
131
135
|
{
|
|
132
|
-
var
|
|
136
|
+
var expression = _$_.child(div_6, true);
|
|
133
137
|
|
|
138
|
+
_$_.expression(expression, () => 'Hello ' + _$_.with_scope(__block, () => String(props.name)));
|
|
134
139
|
_$_.pop(div_6);
|
|
135
140
|
}
|
|
136
141
|
|
|
137
|
-
_$_.render(() => {
|
|
138
|
-
_$_.set_text(text_1, 'Hello ' + _$_.with_scope(__block, () => String(props.name)));
|
|
139
|
-
});
|
|
140
|
-
|
|
141
142
|
_$_.append(__anchor, div_6);
|
|
142
143
|
_$_.pop_component();
|
|
143
144
|
}
|
|
@@ -157,42 +158,78 @@ export function ExpressionContent(__anchor, _, __block) {
|
|
|
157
158
|
_$_.push_component();
|
|
158
159
|
|
|
159
160
|
const value = 42;
|
|
160
|
-
const
|
|
161
|
+
const label = 'computed';
|
|
161
162
|
var fragment_4 = root_11();
|
|
162
163
|
var div_7 = _$_.first_child_frag(fragment_4);
|
|
163
164
|
|
|
164
165
|
{
|
|
165
|
-
var
|
|
166
|
+
var expression_1 = _$_.child(div_7, true);
|
|
166
167
|
|
|
167
|
-
|
|
168
|
+
_$_.expression(expression_1, () => value);
|
|
168
169
|
_$_.pop(div_7);
|
|
169
170
|
}
|
|
170
171
|
|
|
171
172
|
var span_2 = _$_.sibling(div_7);
|
|
172
173
|
|
|
173
174
|
{
|
|
174
|
-
var
|
|
175
|
+
var expression_2 = _$_.child(span_2, true);
|
|
175
176
|
|
|
177
|
+
_$_.expression(expression_2, () => _$_.with_scope(__block, () => label.toUpperCase()));
|
|
176
178
|
_$_.pop(span_2);
|
|
177
179
|
}
|
|
178
180
|
|
|
179
181
|
_$_.next();
|
|
182
|
+
_$_.append(__anchor, fragment_4, true);
|
|
183
|
+
_$_.pop_component();
|
|
184
|
+
}
|
|
180
185
|
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
});
|
|
186
|
+
function TextProp(__anchor, __props, __block) {
|
|
187
|
+
_$_.push_component();
|
|
184
188
|
|
|
185
|
-
|
|
189
|
+
var div_8 = root_12();
|
|
190
|
+
|
|
191
|
+
{
|
|
192
|
+
var expression_3 = _$_.child(div_8);
|
|
193
|
+
|
|
194
|
+
_$_.expression(expression_3, () => __props.children);
|
|
195
|
+
_$_.pop(div_8);
|
|
196
|
+
}
|
|
197
|
+
|
|
198
|
+
_$_.append(__anchor, div_8);
|
|
199
|
+
_$_.pop_component();
|
|
200
|
+
}
|
|
201
|
+
|
|
202
|
+
export function TextPropWithToggle(__anchor, _, __block) {
|
|
203
|
+
_$_.push_component();
|
|
204
|
+
|
|
205
|
+
let lazy = _$_.track(false, void 0, void 0, __block);
|
|
206
|
+
var fragment_5 = root_13();
|
|
207
|
+
var node_4 = _$_.first_child_frag(fragment_5);
|
|
208
|
+
|
|
209
|
+
TextProp(
|
|
210
|
+
node_4,
|
|
211
|
+
{
|
|
212
|
+
get children() {
|
|
213
|
+
return _$_.normalize_children(_$_.get(lazy) ? 'hello' : '');
|
|
214
|
+
}
|
|
215
|
+
},
|
|
216
|
+
_$_.active_block
|
|
217
|
+
);
|
|
218
|
+
|
|
219
|
+
var button_1 = _$_.sibling(node_4);
|
|
220
|
+
|
|
221
|
+
button_1.__click = () => _$_.set(lazy, true);
|
|
222
|
+
_$_.append(__anchor, fragment_5);
|
|
186
223
|
_$_.pop_component();
|
|
187
224
|
}
|
|
188
225
|
|
|
189
226
|
function StaticHeader(__anchor, _, __block) {
|
|
190
227
|
_$_.push_component();
|
|
191
228
|
|
|
192
|
-
var
|
|
229
|
+
var fragment_6 = root_14();
|
|
193
230
|
|
|
194
231
|
_$_.next(2);
|
|
195
|
-
_$_.append(__anchor,
|
|
232
|
+
_$_.append(__anchor, fragment_6, true);
|
|
196
233
|
_$_.pop_component();
|
|
197
234
|
}
|
|
198
235
|
|
|
@@ -200,86 +237,86 @@ export function StaticChildWithSiblings(__anchor, _, __block) {
|
|
|
200
237
|
_$_.push_component();
|
|
201
238
|
|
|
202
239
|
const foo = 'bar';
|
|
203
|
-
var
|
|
204
|
-
var
|
|
240
|
+
var fragment_7 = root_15();
|
|
241
|
+
var node_5 = _$_.first_child_frag(fragment_7);
|
|
205
242
|
|
|
206
|
-
StaticHeader(
|
|
243
|
+
StaticHeader(node_5, {}, _$_.active_block);
|
|
207
244
|
|
|
208
|
-
var span_3 = _$_.sibling(
|
|
245
|
+
var span_3 = _$_.sibling(node_5);
|
|
209
246
|
|
|
210
247
|
{
|
|
211
|
-
var
|
|
248
|
+
var expression_4 = _$_.child(span_3, true);
|
|
212
249
|
|
|
213
|
-
|
|
250
|
+
_$_.expression(expression_4, () => foo);
|
|
214
251
|
_$_.pop(span_3);
|
|
215
252
|
}
|
|
216
253
|
|
|
217
254
|
var span_4 = _$_.sibling(span_3);
|
|
218
255
|
|
|
219
256
|
{
|
|
220
|
-
var
|
|
257
|
+
var expression_5 = _$_.child(span_4, true);
|
|
221
258
|
|
|
222
|
-
|
|
259
|
+
_$_.expression(expression_5, () => foo);
|
|
223
260
|
_$_.pop(span_4);
|
|
224
261
|
}
|
|
225
262
|
|
|
226
263
|
_$_.next();
|
|
227
|
-
_$_.append(__anchor,
|
|
264
|
+
_$_.append(__anchor, fragment_7, true);
|
|
228
265
|
_$_.pop_component();
|
|
229
266
|
}
|
|
230
267
|
|
|
231
268
|
function Header(__anchor, _, __block) {
|
|
232
269
|
_$_.push_component();
|
|
233
270
|
|
|
234
|
-
var
|
|
271
|
+
var fragment_8 = root_16();
|
|
235
272
|
|
|
236
273
|
_$_.next(2);
|
|
237
|
-
_$_.append(__anchor,
|
|
274
|
+
_$_.append(__anchor, fragment_8, true);
|
|
238
275
|
_$_.pop_component();
|
|
239
276
|
}
|
|
240
277
|
|
|
241
278
|
function Actions(__anchor, { playgroundVisible = false }, __block) {
|
|
242
279
|
_$_.push_component();
|
|
243
280
|
|
|
244
|
-
var
|
|
281
|
+
var div_9 = root_17();
|
|
245
282
|
|
|
246
283
|
{
|
|
247
|
-
var a_2 = _$_.child(
|
|
284
|
+
var a_2 = _$_.child(div_9);
|
|
248
285
|
var a_1 = _$_.sibling(a_2);
|
|
249
|
-
var
|
|
286
|
+
var node_6 = _$_.sibling(a_1);
|
|
250
287
|
|
|
251
288
|
{
|
|
252
289
|
var consequent = (__anchor) => {
|
|
253
|
-
var a_3 =
|
|
290
|
+
var a_3 = root_18();
|
|
254
291
|
|
|
255
292
|
_$_.append(__anchor, a_3);
|
|
256
293
|
};
|
|
257
294
|
|
|
258
|
-
_$_.if(
|
|
295
|
+
_$_.if(node_6, (__render) => {
|
|
259
296
|
if (playgroundVisible) __render(consequent);
|
|
260
297
|
});
|
|
261
298
|
}
|
|
262
299
|
|
|
263
|
-
_$_.pop(
|
|
300
|
+
_$_.pop(div_9);
|
|
264
301
|
}
|
|
265
302
|
|
|
266
|
-
_$_.append(__anchor,
|
|
303
|
+
_$_.append(__anchor, div_9);
|
|
267
304
|
_$_.pop_component();
|
|
268
305
|
}
|
|
269
306
|
|
|
270
307
|
function Layout(__anchor, { children }, __block) {
|
|
271
308
|
_$_.push_component();
|
|
272
309
|
|
|
273
|
-
var main_1 =
|
|
310
|
+
var main_1 = root_19();
|
|
274
311
|
|
|
275
312
|
{
|
|
276
|
-
var
|
|
313
|
+
var div_10 = _$_.child(main_1);
|
|
277
314
|
|
|
278
315
|
{
|
|
279
|
-
var
|
|
316
|
+
var expression_6 = _$_.child(div_10);
|
|
280
317
|
|
|
281
|
-
|
|
282
|
-
_$_.pop(
|
|
318
|
+
_$_.expression(expression_6, () => children);
|
|
319
|
+
_$_.pop(div_10);
|
|
283
320
|
}
|
|
284
321
|
}
|
|
285
322
|
|
|
@@ -290,26 +327,24 @@ function Layout(__anchor, { children }, __block) {
|
|
|
290
327
|
function Content(__anchor, _, __block) {
|
|
291
328
|
_$_.push_component();
|
|
292
329
|
|
|
293
|
-
var
|
|
330
|
+
var div_11 = root_20();
|
|
294
331
|
|
|
295
|
-
_$_.append(__anchor,
|
|
332
|
+
_$_.append(__anchor, div_11);
|
|
296
333
|
_$_.pop_component();
|
|
297
334
|
}
|
|
298
335
|
|
|
299
336
|
export function WebsiteIndex(__anchor, _, __block) {
|
|
300
337
|
_$_.push_component();
|
|
301
338
|
|
|
302
|
-
var
|
|
303
|
-
var node_7 = _$_.first_child_frag(
|
|
339
|
+
var fragment_9 = root_21();
|
|
340
|
+
var node_7 = _$_.first_child_frag(fragment_9);
|
|
304
341
|
|
|
305
342
|
Layout(
|
|
306
343
|
node_7,
|
|
307
344
|
{
|
|
308
|
-
children(__anchor,
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
var fragment_9 = root_20();
|
|
312
|
-
var node_8 = _$_.first_child_frag(fragment_9);
|
|
345
|
+
children: _$_.ripple_element(function render_children(__anchor, __block) {
|
|
346
|
+
var fragment_10 = root_22();
|
|
347
|
+
var node_8 = _$_.first_child_frag(fragment_10);
|
|
313
348
|
|
|
314
349
|
Header(node_8, {}, _$_.active_block);
|
|
315
350
|
|
|
@@ -324,21 +359,20 @@ export function WebsiteIndex(__anchor, _, __block) {
|
|
|
324
359
|
var node_11 = _$_.sibling(node_10);
|
|
325
360
|
|
|
326
361
|
Actions(node_11, { playgroundVisible: false }, _$_.active_block);
|
|
327
|
-
_$_.append(__anchor,
|
|
328
|
-
|
|
329
|
-
}
|
|
362
|
+
_$_.append(__anchor, fragment_10);
|
|
363
|
+
})
|
|
330
364
|
},
|
|
331
365
|
_$_.active_block
|
|
332
366
|
);
|
|
333
367
|
|
|
334
|
-
_$_.append(__anchor,
|
|
368
|
+
_$_.append(__anchor, fragment_9);
|
|
335
369
|
_$_.pop_component();
|
|
336
370
|
}
|
|
337
371
|
|
|
338
372
|
function LastChild(__anchor, _, __block) {
|
|
339
373
|
_$_.push_component();
|
|
340
374
|
|
|
341
|
-
var footer_1 =
|
|
375
|
+
var footer_1 = root_23();
|
|
342
376
|
|
|
343
377
|
_$_.append(__anchor, footer_1);
|
|
344
378
|
_$_.pop_component();
|
|
@@ -347,42 +381,42 @@ function LastChild(__anchor, _, __block) {
|
|
|
347
381
|
export function ComponentAsLastSibling(__anchor, _, __block) {
|
|
348
382
|
_$_.push_component();
|
|
349
383
|
|
|
350
|
-
var
|
|
384
|
+
var div_12 = root_24();
|
|
351
385
|
|
|
352
386
|
{
|
|
353
|
-
var h1_1 = _$_.child(
|
|
387
|
+
var h1_1 = _$_.child(div_12);
|
|
354
388
|
var p_1 = _$_.sibling(h1_1);
|
|
355
389
|
var node_12 = _$_.sibling(p_1);
|
|
356
390
|
|
|
357
391
|
LastChild(node_12, {}, _$_.active_block);
|
|
358
|
-
_$_.pop(
|
|
392
|
+
_$_.pop(div_12);
|
|
359
393
|
}
|
|
360
394
|
|
|
361
|
-
_$_.append(__anchor,
|
|
395
|
+
_$_.append(__anchor, div_12);
|
|
362
396
|
_$_.pop_component();
|
|
363
397
|
}
|
|
364
398
|
|
|
365
399
|
function InnerContent(__anchor, _, __block) {
|
|
366
400
|
_$_.push_component();
|
|
367
401
|
|
|
368
|
-
var
|
|
402
|
+
var div_13 = root_25();
|
|
369
403
|
|
|
370
404
|
{
|
|
371
|
-
var span_5 = _$_.child(
|
|
405
|
+
var span_5 = _$_.child(div_13);
|
|
372
406
|
var node_13 = _$_.sibling(span_5);
|
|
373
407
|
|
|
374
408
|
LastChild(node_13, {}, _$_.active_block);
|
|
375
|
-
_$_.pop(
|
|
409
|
+
_$_.pop(div_13);
|
|
376
410
|
}
|
|
377
411
|
|
|
378
|
-
_$_.append(__anchor,
|
|
412
|
+
_$_.append(__anchor, div_13);
|
|
379
413
|
_$_.pop_component();
|
|
380
414
|
}
|
|
381
415
|
|
|
382
416
|
export function NestedComponentAsLastSibling(__anchor, _, __block) {
|
|
383
417
|
_$_.push_component();
|
|
384
418
|
|
|
385
|
-
var section_1 =
|
|
419
|
+
var section_1 = root_26();
|
|
386
420
|
|
|
387
421
|
{
|
|
388
422
|
var h2_1 = _$_.child(section_1);
|
|
@@ -394,4 +428,6 @@ export function NestedComponentAsLastSibling(__anchor, _, __block) {
|
|
|
394
428
|
|
|
395
429
|
_$_.append(__anchor, section_1);
|
|
396
430
|
_$_.pop_component();
|
|
397
|
-
}
|
|
431
|
+
}
|
|
432
|
+
|
|
433
|
+
_$_.delegate(['click']);
|
|
@@ -2,15 +2,18 @@
|
|
|
2
2
|
import * as _$_ from 'ripple/internal/client';
|
|
3
3
|
|
|
4
4
|
var root = _$_.template(`<div class="layout"><!></div>`, 0);
|
|
5
|
-
var root_1 = _$_.template(`<div class="
|
|
6
|
-
var root_2 = _$_.template(`<
|
|
7
|
-
var root_3 = _$_.template(
|
|
8
|
-
var root_5 = _$_.template(`<!>`, 1, 1);
|
|
5
|
+
var root_1 = _$_.template(`<div class="layout">before<!>after</div>`, 0);
|
|
6
|
+
var root_2 = _$_.template(`<div class="single">single</div>`, 0);
|
|
7
|
+
var root_3 = _$_.template(`<h1>title</h1><p>description</p>`, 1, 2);
|
|
9
8
|
var root_4 = _$_.template(`<!>`, 1, 1);
|
|
10
|
-
var root_7 = _$_.template(`<!><div class="extra">extra</div>`, 1, 2);
|
|
11
9
|
var root_6 = _$_.template(`<!>`, 1, 1);
|
|
10
|
+
var root_5 = _$_.template(`<!>`, 1, 1);
|
|
11
|
+
var root_8 = _$_.template(`<!><div class="extra">extra</div>`, 1, 2);
|
|
12
|
+
var root_7 = _$_.template(`<!>`, 1, 1);
|
|
13
|
+
var root_10 = _$_.template(`<!>`, 1, 1);
|
|
12
14
|
var root_9 = _$_.template(`<!>`, 1, 1);
|
|
13
|
-
var
|
|
15
|
+
var root_12 = _$_.template(`<!>`, 1, 1);
|
|
16
|
+
var root_11 = _$_.template(`<!>`, 1, 1);
|
|
14
17
|
|
|
15
18
|
export function Layout(__anchor, __props, __block) {
|
|
16
19
|
_$_.push_component();
|
|
@@ -18,9 +21,9 @@ export function Layout(__anchor, __props, __block) {
|
|
|
18
21
|
var div_1 = root();
|
|
19
22
|
|
|
20
23
|
{
|
|
21
|
-
var
|
|
24
|
+
var expression = _$_.child(div_1);
|
|
22
25
|
|
|
23
|
-
_$_.
|
|
26
|
+
_$_.expression(expression, () => __props.children);
|
|
24
27
|
_$_.pop(div_1);
|
|
25
28
|
}
|
|
26
29
|
|
|
@@ -28,19 +31,36 @@ export function Layout(__anchor, __props, __block) {
|
|
|
28
31
|
_$_.pop_component();
|
|
29
32
|
}
|
|
30
33
|
|
|
31
|
-
export function
|
|
34
|
+
export function TextWrappedLayout(__anchor, __props, __block) {
|
|
32
35
|
_$_.push_component();
|
|
33
36
|
|
|
34
37
|
var div_2 = root_1();
|
|
35
38
|
|
|
39
|
+
{
|
|
40
|
+
var text = _$_.child(div_2);
|
|
41
|
+
var expression_1 = _$_.sibling(text);
|
|
42
|
+
|
|
43
|
+
_$_.expression(expression_1, () => __props.children);
|
|
44
|
+
_$_.pop(div_2);
|
|
45
|
+
}
|
|
46
|
+
|
|
36
47
|
_$_.append(__anchor, div_2);
|
|
37
48
|
_$_.pop_component();
|
|
38
49
|
}
|
|
39
50
|
|
|
51
|
+
export function SingleChild(__anchor, _, __block) {
|
|
52
|
+
_$_.push_component();
|
|
53
|
+
|
|
54
|
+
var div_3 = root_2();
|
|
55
|
+
|
|
56
|
+
_$_.append(__anchor, div_3);
|
|
57
|
+
_$_.pop_component();
|
|
58
|
+
}
|
|
59
|
+
|
|
40
60
|
export function MultiRootChild(__anchor, _, __block) {
|
|
41
61
|
_$_.push_component();
|
|
42
62
|
|
|
43
|
-
var fragment =
|
|
63
|
+
var fragment = root_3();
|
|
44
64
|
|
|
45
65
|
_$_.next();
|
|
46
66
|
_$_.append(__anchor, fragment, true);
|
|
@@ -50,10 +70,10 @@ export function MultiRootChild(__anchor, _, __block) {
|
|
|
50
70
|
export function EmptyLayout(__anchor, _, __block) {
|
|
51
71
|
_$_.push_component();
|
|
52
72
|
|
|
53
|
-
var fragment_1 =
|
|
54
|
-
var
|
|
73
|
+
var fragment_1 = root_4();
|
|
74
|
+
var node = _$_.first_child_frag(fragment_1);
|
|
55
75
|
|
|
56
|
-
Layout(
|
|
76
|
+
Layout(node, {}, _$_.active_block);
|
|
57
77
|
_$_.append(__anchor, fragment_1);
|
|
58
78
|
_$_.pop_component();
|
|
59
79
|
}
|
|
@@ -61,22 +81,19 @@ export function EmptyLayout(__anchor, _, __block) {
|
|
|
61
81
|
export function LayoutWithSingleChild(__anchor, _, __block) {
|
|
62
82
|
_$_.push_component();
|
|
63
83
|
|
|
64
|
-
var fragment_2 =
|
|
65
|
-
var
|
|
84
|
+
var fragment_2 = root_5();
|
|
85
|
+
var node_1 = _$_.first_child_frag(fragment_2);
|
|
66
86
|
|
|
67
87
|
Layout(
|
|
68
|
-
|
|
88
|
+
node_1,
|
|
69
89
|
{
|
|
70
|
-
children(__anchor,
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
var fragment_3 = root_5();
|
|
74
|
-
var node_3 = _$_.first_child_frag(fragment_3);
|
|
90
|
+
children: _$_.ripple_element(function render_children(__anchor, __block) {
|
|
91
|
+
var fragment_3 = root_6();
|
|
92
|
+
var node_2 = _$_.first_child_frag(fragment_3);
|
|
75
93
|
|
|
76
|
-
SingleChild(
|
|
94
|
+
SingleChild(node_2, {}, _$_.active_block);
|
|
77
95
|
_$_.append(__anchor, fragment_3);
|
|
78
|
-
|
|
79
|
-
}
|
|
96
|
+
})
|
|
80
97
|
},
|
|
81
98
|
_$_.active_block
|
|
82
99
|
);
|
|
@@ -88,22 +105,19 @@ export function LayoutWithSingleChild(__anchor, _, __block) {
|
|
|
88
105
|
export function LayoutWithMultipleChildren(__anchor, _, __block) {
|
|
89
106
|
_$_.push_component();
|
|
90
107
|
|
|
91
|
-
var fragment_4 =
|
|
92
|
-
var
|
|
108
|
+
var fragment_4 = root_7();
|
|
109
|
+
var node_3 = _$_.first_child_frag(fragment_4);
|
|
93
110
|
|
|
94
111
|
Layout(
|
|
95
|
-
|
|
112
|
+
node_3,
|
|
96
113
|
{
|
|
97
|
-
children(__anchor,
|
|
98
|
-
|
|
114
|
+
children: _$_.ripple_element(function render_children(__anchor, __block) {
|
|
115
|
+
var fragment_5 = root_8();
|
|
116
|
+
var node_4 = _$_.first_child_frag(fragment_5);
|
|
99
117
|
|
|
100
|
-
|
|
101
|
-
var node_5 = _$_.first_child_frag(fragment_5);
|
|
102
|
-
|
|
103
|
-
SingleChild(node_5, {}, _$_.active_block);
|
|
118
|
+
SingleChild(node_4, {}, _$_.active_block);
|
|
104
119
|
_$_.append(__anchor, fragment_5);
|
|
105
|
-
|
|
106
|
-
}
|
|
120
|
+
})
|
|
107
121
|
},
|
|
108
122
|
_$_.active_block
|
|
109
123
|
);
|
|
@@ -115,26 +129,47 @@ export function LayoutWithMultipleChildren(__anchor, _, __block) {
|
|
|
115
129
|
export function LayoutWithMultiRootChild(__anchor, _, __block) {
|
|
116
130
|
_$_.push_component();
|
|
117
131
|
|
|
118
|
-
var fragment_6 =
|
|
119
|
-
var
|
|
132
|
+
var fragment_6 = root_9();
|
|
133
|
+
var node_5 = _$_.first_child_frag(fragment_6);
|
|
120
134
|
|
|
121
135
|
Layout(
|
|
122
|
-
|
|
136
|
+
node_5,
|
|
123
137
|
{
|
|
124
|
-
children(__anchor,
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
var fragment_7 = root_9();
|
|
128
|
-
var node_7 = _$_.first_child_frag(fragment_7);
|
|
138
|
+
children: _$_.ripple_element(function render_children(__anchor, __block) {
|
|
139
|
+
var fragment_7 = root_10();
|
|
140
|
+
var node_6 = _$_.first_child_frag(fragment_7);
|
|
129
141
|
|
|
130
|
-
MultiRootChild(
|
|
142
|
+
MultiRootChild(node_6, {}, _$_.active_block);
|
|
131
143
|
_$_.append(__anchor, fragment_7);
|
|
132
|
-
|
|
133
|
-
}
|
|
144
|
+
})
|
|
134
145
|
},
|
|
135
146
|
_$_.active_block
|
|
136
147
|
);
|
|
137
148
|
|
|
138
149
|
_$_.append(__anchor, fragment_6);
|
|
139
150
|
_$_.pop_component();
|
|
151
|
+
}
|
|
152
|
+
|
|
153
|
+
export function LayoutWithTextAroundChildren(__anchor, _, __block) {
|
|
154
|
+
_$_.push_component();
|
|
155
|
+
|
|
156
|
+
var fragment_8 = root_11();
|
|
157
|
+
var node_7 = _$_.first_child_frag(fragment_8);
|
|
158
|
+
|
|
159
|
+
TextWrappedLayout(
|
|
160
|
+
node_7,
|
|
161
|
+
{
|
|
162
|
+
children: _$_.ripple_element(function render_children(__anchor, __block) {
|
|
163
|
+
var fragment_9 = root_12();
|
|
164
|
+
var node_8 = _$_.first_child_frag(fragment_9);
|
|
165
|
+
|
|
166
|
+
SingleChild(node_8, {}, _$_.active_block);
|
|
167
|
+
_$_.append(__anchor, fragment_9);
|
|
168
|
+
})
|
|
169
|
+
},
|
|
170
|
+
_$_.active_block
|
|
171
|
+
);
|
|
172
|
+
|
|
173
|
+
_$_.append(__anchor, fragment_8);
|
|
174
|
+
_$_.pop_component();
|
|
140
175
|
}
|