Window data
An app window around whatever it wraps: a title bar with three dots, then the content.
Props#
| Prop | Type | Default | Notes |
|---|---|---|---|
| title | string | "" | |
| w | number (300 to 1060) | 920 | |
| fill | color | "paper" | |
| pad | number (0 to 120) | 40 | |
| gap | number (0 to 200) | 30 |
* required. Every node also takes the common props: id, motion, start, place, scale, rotate, opacity, w, h. A colour is a palette name, never a value.
Parts#
Named parts can be restyled from outside without making a new component: "parts": { "root": { … } }.
| Part | Is a |
|---|---|
| root | box |
| title | text |
| body | box |
Content it wraps#
It wraps whatever is written in its children.
Example#
{"el": "Window", "title": "This week", "children": []}How it is made#
This component is plain data. Its whole definition is the tree below: copy it into a scene's components list under a new name to make your own version. See Custom components.
{
"el": "box",
"w": "$w",
"radius": 36,
"fill": "$fill",
"clip": true,
"shadow": 3,
"children": [
{
"el": "box",
"dir": "row",
"h": 88,
"pad": [0, 32],
"gap": 14,
"align": "center",
"fill": "rgba(128,128,140,.14)",
"children": [
{"el": "shape", "kind": "circle", "w": 20, "fill": "bad"},
{"el": "shape", "kind": "circle", "w": 20, "fill": "accent2"},
{"el": "shape", "kind": "circle", "w": 20, "fill": "good"},
{
"el": "text",
"id": "title",
"text": "$title",
"size": 34,
"weight": 600,
"color": "muted",
"font": "body"
}
]
},
{"el": "box", "id": "body", "pad": "$pad", "gap": "$gap", "children": ["$children"]}
]
}