refactor: rename DTree to DValue
This commit is contained in:
@@ -2,12 +2,12 @@
|
||||
|
||||
COMPONENT(Request& context)
|
||||
{
|
||||
DTree asset_props;
|
||||
DValue asset_props;
|
||||
asset_props["css"]["0"] = "views/marketing.css";
|
||||
print(component("../components/theme/assets", asset_props, context));
|
||||
context.call["app"]["page_title"] = "Home";
|
||||
|
||||
DTree props;
|
||||
DValue props;
|
||||
|
||||
props["title"] = "Stunning Apps";
|
||||
props["subtitle"] = "Experience the power of super bloated PHP development with our gigantic and truly unwieldy component-based framework. Seriously though, this page only serves as an example repository of different styles and blocks.";
|
||||
@@ -17,7 +17,7 @@ COMPONENT(Request& context)
|
||||
print(component("../components/example/marketing_blocks:FEATURES_GRID", context));
|
||||
|
||||
props.clear();
|
||||
DTree stat;
|
||||
DValue stat;
|
||||
stat["number"] = "10K+"; stat["label"] = "Happy Vibe Coders"; props["stats"].push(stat); stat.clear();
|
||||
stat["number"] = "<1s"; stat["label"] = "Page Load Time"; props["stats"].push(stat); stat.clear();
|
||||
stat["number"] = "99.9%"; stat["label"] = "Uptime"; props["stats"].push(stat); stat.clear();
|
||||
@@ -72,7 +72,7 @@ COMPONENT(Request& context)
|
||||
<h2>Theme Families</h2>
|
||||
<p>Compare the starter’s built-in theme families and jump to the live gallery.</p>
|
||||
<div class="theme-grid">
|
||||
<? context.cfg.get_by_path("theme/options").each([&](DTree theme, String key) {
|
||||
<? context.cfg.get_by_path("theme/options").each([&](DValue theme, String key) {
|
||||
if(key != "portal-light" && key != "portal-dark" && key != "localfirst")
|
||||
return;
|
||||
StringMap theme_params;
|
||||
@@ -99,7 +99,7 @@ COMPONENT(Request& context)
|
||||
props["secondary_text"] = "View GitHub";
|
||||
print(component("../components/example/marketing_blocks:CTA_SECTION", props, context));
|
||||
|
||||
DTree island_props;
|
||||
DValue island_props;
|
||||
island_props["name"] = "StarterGuidelines";
|
||||
island_props["id"] = "starter-guidelines-island";
|
||||
island_props["props"]["route"] = context.call["route"]["l_path"].to_string();
|
||||
@@ -120,7 +120,7 @@ COMPONENT(Request& context)
|
||||
</>
|
||||
|
||||
props.clear();
|
||||
DTree row;
|
||||
DValue row;
|
||||
row["name"] = "John Doe"; row["age"] = "25"; row["gender"] = "male"; row["department"] = "Engineering"; row["salary"] = "75000"; row["active"] = "true"; props["items"].push(row); row.clear();
|
||||
row["name"] = "Jane Smith"; row["age"] = "30"; row["gender"] = "female"; row["department"] = "Design"; row["salary"] = "82000"; row["active"] = "true"; props["items"].push(row); row.clear();
|
||||
row["name"] = "Bob Johnson"; row["age"] = "35"; row["gender"] = "male"; row["department"] = "Marketing"; row["salary"] = "68000"; row["active"] = "false"; props["items"].push(row); row.clear();
|
||||
|
||||
Reference in New Issue
Block a user