Timegroup Modes
Every ef-timegroup has a mode that determines how its duration is calculated and how children are arranged in time.
Fixed
Explicit duration. The base case — you set the length directly.
3 Second Scene
Use fixed when you know the exact duration: title cards, countdowns, static scenes.
Sequence
Children play one after another. Duration is the sum of all children minus any overlap.
Scene 1 (2s)
Scene 2 (3s)
Scene 3 (1s)
Use sequence for cut-based editing, slideshows, multi-scene videos. See sequencing.md.
Contain
Children play simultaneously. Duration is the longest child.
Layer A (5s)
Layer B (8s) — sets total to 8s
Use contain for layered compositions: video with overlays, picture-in-picture, parallel tracks.
Fit
Inherits duration from parent. No duration of its own.
Content (4s)
Fit background — spans full 4s
Use fit for backgrounds, watermarks, or any element that should span its parent's full duration.
Decision Guide
| Scenario | Mode | Why |
|---|---|---|
| Title card with known length | fixed | Explicit control |
| Multi-scene video | sequence | Sequential playback |
| Video with text overlay | contain | Parallel layers |
| Background music/watermark | fit | Span parent duration |
| Scenes with transitions | sequence + overlap | Shared time for crossfades |
Note: Modes compose — a contain parent with a sequence child and a fit background is a common pattern for videos with a background track spanning the full timeline.
See Also
- timegroup.md — attribute reference
- time-model.md — how time propagates through modes
- sequencing.md — sequence patterns