Marquee data
A band of repeated words that scrolls sideways forever without a seam.
Props#
| Prop | Type | Default | Notes |
|---|---|---|---|
| text* | string | ||
| size | number (34 to 500) | 150 | |
| speed | number (-2000 to 2000) | 240 | pixels per second; negative runs the other way |
| color | color | "ink" | |
| copies | number (2 to 20) | 6 | |
| gap | number (0 to 600) | 90 |
* 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": "Marquee", "text": "one take", "speed": 300}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": 1080,
"clip": true,
"align": "start",
"children": [
{
"el": "box",
"dir": "row",
"w": "max-content",
"motion": [{"do": "drive", "pose": {"x": "=-mod(t*speed, selfW/copies)"}}],
"children": [
{
"$each": "$copies",
"node": {
"el": "box",
"pad": [0, "=gap/2"],
"children": [
{
"el": "text",
"text": "$text",
"size": "$size",
"weight": 800,
"color": "$color",
"upper": true
}
]
}
}
]
}
]
}