some cleanup

This commit is contained in:
udo
2026-04-28 12:10:07 +00:00
parent 223cf4c6e1
commit cd445f3c9b
224 changed files with 1558 additions and 38907 deletions
@@ -1,4 +1,4 @@
COMPONENT(Request& context)
{
<><pre class="tests-code-block"><?: first(context.call["default_html"].to_string(), context.call["children_html"].to_string()) ?></pre></>
<><pre class="tests-code-block"><?: first(context.props["default_html"].to_string(), context.props["children_html"].to_string()) ?></pre></>
}
+1 -1
View File
@@ -1,4 +1,4 @@
COMPONENT(Request& context)
{
<><div class="tests-warning"><?= first(context.call["children_html"].to_string(), context.call["default_html"].to_string()) ?></div></>
<><div class="tests-warning"><?= first(context.props["children_html"].to_string(), context.props["default_html"].to_string()) ?></div></>
}
+6 -6
View File
@@ -1,23 +1,23 @@
COMPONENT(Request& context)
{
<><section class="tests-component">
<? component_render(":HEADER", context.call, context); ?>
<? component_render(":BODY", context.call, context); ?>
<? component_render(":FOOTER", context.call, context); ?>
<? component_render(":HEADER", context.props, context); ?>
<? component_render(":BODY", context.props, context); ?>
<? component_render(":FOOTER", context.props, context); ?>
</section></>
}
COMPONENT:HEADER(Request& context)
{
<><h3 class="accent"><?= first(context.call["title"].to_string(), "Missing Title") ?></h3></>
<><h3 class="accent"><?= first(context.props["title"].to_string(), "Missing Title") ?></h3></>
}
COMPONENT:BODY(Request& context)
{
<><p><?= first(context.call["body"].to_string(), "Missing Body") ?></p></>
<><p><?= first(context.props["body"].to_string(), "Missing Body") ?></p></>
}
COMPONENT:FOOTER(Request& context)
{
<><small><?= first(context.call["footer"].to_string(), "Missing Footer") ?></small></>
<><small><?= first(context.props["footer"].to_string(), "Missing Footer") ?></small></>
}
+10
View File
@@ -0,0 +1,10 @@
COMPONENT(Request& props)
{
String title = props.props["title"].to_string();
String body = props.props["body"].to_string();
<><div class="panel panel-alias-check">
<strong>alias=<?= title ?></strong>
<p>body=<?= body ?></p>
</div></>
}