Skip to main content

Module build

Module build 

Source
Expand description

Scene construction helpers.

Re-exports the sim-value builders and adds a few common scene node shapes plus a reserved-key guard. The guard turns the kind footgun into an immediate, clear failure: kind is the scene-node tag, so a plain data map must not carry a kind key (use a different field name). data_map debug-asserts that.

Constants§

RESERVED_DATA_KEYS
Keys reserved for scene-node structure; plain data maps must not use them.

Functions§

badge
A scene/badge node. Status carries a text token, never color alone.
box_
A scene/box node with a role and children.
data_map
Build a plain data map, asserting (in debug) that it carries no reserved scene-node key.
float
An f64-domain number value with a canonical literal.
int
An i64-domain number value.
list
A list value.
map
A map value from string-keyed entries (keys become unqualified symbols).
stack
A scene/stack node with a direction and children.
sym
An unqualified symbol value: Expr::Symbol(Symbol::new(name)).
text
A string value.
text_node
A scene/text node.
vector
A vector value.