Skip to content

Loadgo v3.1.1

Choose a tag to compare

@franverona franverona released this 26 Mar 08:49
· 33 commits to main since this release
0a2fe60

Bug fixes

  • Using loop() with the filter option active would crash immediately — the overlay doesn't exist in filter mode, but the code tried to update it anyway (jQuery).
  • After calling stop(), you could never start a new loop() on the same element — the stale interval ID was left behind and mistaken for an active loop (vanilla).
  • Images without an id attribute would conflict with each other — all of them shared the same empty-string key, so initialising a second one would silently corrupt the first (vanilla).
  • The overlay width was set to a bare number instead of a pixel value, so it never actually resized in modern browsers (vanilla).
  • Calling init() a second time on the same element would nest a new container inside the existing one, breaking the DOM structure and leaving a ghost overlay behind. It now cleans up properly before reinitialising (jQuery and vanilla).
  • Calling destroy() while a loop() was running would leave the interval alive forever, quietly burning CPU in the background (jQuery and vanilla).
  • After destroy(), the image was moved to the end of its parent instead of back to where it originally was, silently reordering the page (vanilla).
  • Overlay positioning ignored any margin or padding set through a stylesheet — only inline styles were read. It now uses computed styles, so CSS-applied spacing is respected (vanilla).
  • Calling options() to update settings after init() had no effect — it returned the existing options immediately and discarded any changes. Updates are now applied correctly (vanilla).
  • The overlay transition animated every CSS property instead of just the ones that actually change. Aligned with the jQuery behaviour to only transition width, height, and top (vanilla).