Skip to content

v0.7.0

Choose a tag to compare

@ioquatix ioquatix released this 14 Apr 07:57
· 94 commits to main since this release
08cddc5
  • Rework build effects to use direct CSS class animation rather than view-transition-class. build-fade, build-fly-up, etc. are now regular @keyframes classes applied to the revealed element, rather than view transition pseudo-element selectors. This decouples in-slide sequential animation from slide-level morph transitions.
  • Rename SlideElements#build to SlideElements#show for clarity — boxes.show(0) / boxes.show(3) more clearly describes the outcome from the audience's perspective.
  • Add SlideElements#builder(options) — returns a SlideBuilder with default options (group, effect) and a cached position, so callers can use next() instead of tracking the step count manually.
  • Add SlideBuilder#show(count, overrides) — set visibility state to an arbitrary position. Returns a Promise that resolves when the reveal animation completes (or immediately when no effect is given).
  • Add SlideBuilder#next(overrides) — reveal the next element with the builder's default effect, optionally overridden per call. O(1): only touches the single newly revealed element. Returns a Promise.
  • Add SlideBuilder#play(interval, callback) — reveals all remaining elements in sequence with interval milliseconds between each. An optional callback is invoked after each reveal; return false to stop playback early. Requires the builder to be created via slide.find(...).builder() so timeouts are tracked and cancelled on slide change.
  • Add SlideBuilder#finished getter — returns true when all elements have been revealed.
  • Add Slide#after(delay, callback) — schedules a callback after a delay in milliseconds and returns a SlideChain. Subsequent .after(delay, callback) calls on the chain fire relative to the previous step, making sequential reveal timing easy to read and adjust.
  • Add Slide#setTimeout(callback, delay) — a tracked replacement for the global setTimeout. All timeouts registered this way are automatically cancelled when the slide changes, preventing stale callbacks from firing after navigation. The global setTimeout in slide scripts is shadowed by this method automatically.
  • Add Slide#cancelTimeouts() — cancels all pending timeouts registered by the slide's script. Called automatically by the presentation engine on every slide change.