website with slop placeholders

This commit is contained in:
udo
2026-04-22 13:31:51 +00:00
parent 14ebf10a22
commit 223cf4c6e1
336 changed files with 66009 additions and 116 deletions
+24
View File
@@ -0,0 +1,24 @@
COMPONENT(Request& context)
{
<>
<section style="border:1px solid #ccc;padding:1em;margin:1em 0;">
<? component_render(":TITLE", context.call, context); ?>
<? component_render(":BODY", context.call, context); ?>
</section>
</>
}
COMPONENT:TITLE(Request& context)
{
<>
<h3><?= first(context.call["title"].to_string(), "Component Title") ?></h3>
</>
}
COMPONENT:BODY(Request& context)
{
<>
<p><?= first(context.call["body"].to_string(), "Component Body") ?></p>
</>
}
@@ -0,0 +1,10 @@
COMPONENT(Request& context)
{
String lang = first(context.call["lang"].to_string(), "plain");
<>
<section>
<p><strong>Code block:</strong> <?= lang ?></p>
<div><?: context.call["default_html"].to_string() ?></div>
</section>
</>
}
+15
View File
@@ -0,0 +1,15 @@
COMPONENT(Request& context)
{
String title = first(
context.call["node"]["attrs"]["title"].to_string(),
context.call["argument"].to_string(),
"Notice"
);
<>
<aside>
<p><strong><?= title ?></strong></p>
<div><?: context.call["children_html"].to_string() ?></div>
</aside>
</>
}