Burst data
A ring of dots thrown outward from a point: a small celebration to put behind a number or a tick.
Props#
| Prop | Type | Default | Notes |
|---|---|---|---|
| count | number (3 to 40) | 12 | |
| radius | number (40 to 900) | 280 | |
| size | number (4 to 80) | 22 | |
| color | color | "accent2" | |
| at | time |
* 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 |
Example#
{"el": "Burst", "at": 1.2, "count": 14}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",
"dir": "stack",
"w": 10,
"h": 10,
"children": [
{
"$each": "$count",
"node": {
"el": "shape",
"kind": "circle",
"w": "$size",
"fill": "$color",
"motion": [
{"do": "enter", "from": "shrink", "at": "$at", "curve": "snap"},
{
"do": "to",
"pose": {"x": "=cos(index/count*2*pi)*radius", "y": "=sin(index/count*2*pi)*radius"},
"at": "$at",
"curve": {"ease": "outExpo", "duration": 0.95}
},
{
"do": "exit",
"to": "shrink",
"at": "$at",
"delay": 0.5,
"curve": {"ease": "in", "duration": 0.45}
}
]
}
}
]
}