DuoCaption data
A two-size caption: a small plain lead-in and one big glowing word under it.
Props#
| Prop | Type | Default | Notes |
|---|---|---|---|
| small | string | "" | |
| big* | string | ||
| color | color | "white" | |
| hot | color | "accent2" | |
| size | number (40 to 600) | 170 |
* 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 |
| small | text |
| big | text |
Example#
{"el": "DuoCaption", "small": "if your", "big": "Content"}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",
"gap": 0,
"align": "center",
"children": [
{
"el": "text",
"id": "small",
"text": "$small",
"size": "=size*0.34",
"weight": 600,
"color": "$color",
"motion": [{"do": "enter", "from": {"y": 20, "opacity": 0}, "curve": "snap"}]
},
{
"el": "text",
"id": "big",
"text": "$big",
"size": "$size",
"weight": 800,
"color": "$hot",
"glow": "$hot",
"tracking": -0.05,
"leading": 0.95,
"motion": [
{
"do": "enter",
"from": {"scale": 0.7, "opacity": 0, "blur": 10},
"delay": 0.08,
"curve": "punchy"
}
]
}
]
}