Skip to content

Dottie 0.9.0

Choose a tag to compare

@sam-phinizy sam-phinizy released this 07 Nov 20:56

dottie.js: big drawings play without holding up the page

  • Long, busy animations no longer freeze the page while they load. Before showing an animation without a
    camera, <dottie-player> works out the view of every frame. For a big one that now happens in a worker, and the
    drawing appears when it's done, looking exactly as it would have. setFile() returns at once and load fires once
    the drawing is showing. Small drawings, stills and camera animations show straight away as before. Where a worker
    can't start, such as under a worker-src policy, the player works it out in place.
  • If you host the module player yourself, serve dottie-player.min.js beside dottie-player.js: the worker loads
    it from there. The classic script, compiled drawings and the HTML export need nothing extra.
  • Faster everywhere. On a 400-shape drawing with about 1,100 hopping connectors and traffic flows, getting
    ready to play is about nine times faster and each frame about fourteen times faster. Routing traffic, connector
    hops, notes, buttons' over and down looks, and labels with very long unbroken words all got quicker; a
    5,000-character word used to take minutes to wrap. Everything draws exactly as before.

dottie.js fixes

  • A compiled drawing whose text contains DOTTIE_OPTIONS or DOTTIE_FONTS no longer comes out broken.
  • setFile() while a src is still loading: the file you gave stays, instead of being replaced when the load
    finishes.
  • When a drawing fails to load, the one that was showing stops, and its controls go away.
  • currentTime on a still (at="5") reports the moment it shows, not 0.