@aarsteinmedia/dotlottie-player 6.3.12 → 6.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -7,11 +7,25 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
7
7
 
8
8
  Changelog was only added since [3.2.3], so it's not exhaustive. [Please report any missing noteable changes to us](https://github.com/aarsteinmedia/dotlottie-player/issues), and we'll add them promptly.
9
9
 
10
+ ## [6.4.0] - 06-08-2026
11
+
12
+ ### Changed
13
+
14
+ - Major change in how critical load error are handled – from being relegated to console logs while staying quiet on the front end, to rendering graphic error screen. This behavior can be changed by using the boolean `quiet` attribute.
15
+
16
+ ## [6.3.13] - 05-08-2026
17
+
18
+ ### Changed
19
+
20
+ - Fixed error causing beziers to be dropped from keyframes.
21
+ - Minor bugrixes.
22
+
10
23
  ## [6.3.11] - 20-07-2026
11
24
 
12
25
  ### Changed
13
26
 
14
- - Minor bugfixes, including fixing nullish coalescing not covered in brackets. Thanks to [@koloml](https://github.com/koloml)!
27
+ - Fix by [@koloml](https://github.com/koloml) on nullish coalescing not covered correctly in brackets.
28
+ - Minor bugfixes
15
29
 
16
30
  ## [6.3.6] - 09-06-2026
17
31
 
package/README.md CHANGED
@@ -301,29 +301,30 @@ export default defineNuxtPlugin(({ vueApp }) => {
301
301
 
302
302
  | Property / Attribute | Description | Type | Default |
303
303
  | ------------------------- | ----------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------- | ----------------- |
304
- | `animateOnScroll` | Animate by scrolling | `boolean` | `false` |
305
- | `autoplay` | Play animation on load | `boolean` | `false` |
306
- | `background` | Background color | `string` | `undefined` |
307
- | `controls` | Show controls | `boolean` | `false` |
308
- | `count` | Number of times to loop animation | `number` | `undefined` |
309
- | `delay` | Delay playback on playOnVisible, in miliseconds | `number` | `0` |
310
- | `description` | Description for screen readers | `string` | `undefined` |
311
- | `direction` | Direction of animation | `1` \| `-1` | `1` |
312
- | `dontFreezeOnBlur` | Whether to freeze playback on window blur. This is default behavior, but can be disabled | `boolean` | `1` |
313
- | `hover` | Whether to play on mouse hover | `boolean` | `false` |
314
- | `intermission` | Pause between loop intrations, in miliseconds | `number` | `0` |
315
- | `loop` | Whether to loop animation | `boolean` | `false` |
316
- | `mode` | Play mode | `normal` \| `bounce` | `normal` |
317
- | `mouseout` | Action on mouseout | `void` \| `stop` \| `pause` \| `reverse` | `stop` |
318
- | `objectfit` | Resizing of animation in container | `contain` \| `cover` \| `fill` \| `none` | `contain` |
319
- | `once` | Whether, if playOnVisible is true, to play once or anytime animation is in view | `boolean` | `false` |
320
- | `playOnClick` | Whether to toggle play on click | `boolean` | `false` |
321
- | `playOnVisible` | Play when visible | `boolean` | `false` |
322
- | `renderer` | Renderer to use | `svg` \| `canvas` \| `html` | `svg` |
323
- | `selector` | Play on clicked element by id attribute | `string` | `undefined` |
324
- | `speed` | Animation speed | `number` | `1` |
325
- | `src` _(required)_ | URL to LottieJSON or dotLottie | `string` | `undefined` |
326
- | `subframe` | When enabled this can help to reduce flicker on some animations, especially on Safari and iOS devices. | `boolean` | `false` |
304
+ | `animateOnScroll` | Animate by scrolling. | `boolean` | `false` |
305
+ | `autoplay` | Play animation on load. | `boolean` | `false` |
306
+ | `background` | Background color. | `string` | `undefined` |
307
+ | `controls` | Show controls. | `boolean` | `false` |
308
+ | `count` | Number of times to loop animation. | `number` | `undefined` |
309
+ | `delay` | Delay playback on playOnVisible, in miliseconds. | `number` | `0` |
310
+ | `description` | Description for screen readers. | `string` | `undefined` |
311
+ | `direction` | Direction of animation. | `1` \| `-1` | `1` |
312
+ | `dontFreezeOnBlur` | Whether to freeze playback on window blur. This is default behavior, but can be disabled. | `boolean` | `1` |
313
+ | `hover` | Whether to play on mouse hover. | `boolean` | `false` |
314
+ | `intermission` | Pause between loop intrations, in miliseconds. | `number` | `0` |
315
+ | `loop` | Whether to loop animation. | `boolean` | `false` |
316
+ | `mode` | Play mode. | `normal` \| `bounce` | `normal` |
317
+ | `mouseout` | Action on mouseout. | `void` \| `stop` \| `pause` \| `reverse` | `stop` |
318
+ | `objectfit` | Resizing of animation in container. | `contain` \| `cover` \| `fill` \| `none` | `contain` |
319
+ | `once` | Whether, if playOnVisible is true, to play once or anytime animation is in view. | `boolean` | `false` |
320
+ | `playOnClick` | Whether to toggle play on click. | `boolean` | `false` |
321
+ | `playOnVisible` | Play when visible. | `boolean` | `false` |
322
+ | `quiet` | Whether to display graphic error screen on critical load errors. | `boolean` | `false` |
323
+ | `renderer` | Renderer to use. | `svg` \| `canvas` \| `html` | `svg` |
324
+ | `selector` | Play on clicked element by id attribute. | `string` | `undefined` |
325
+ | `speed` | Animation speed. | `number` | `1` |
326
+ | `src` _(required)_ | URL to LottieJSON or dotLottie. | `string` | `undefined` |
327
+ | `subframe` | When enabled this can help to reduce flicker on some animations, especially on Safari and iOS devices. | `boolean` | `false` |
327
328
 
328
329
  ## Methods
329
330
 
@@ -50,7 +50,7 @@
50
50
  ],
51
51
  "superclass": {
52
52
  "name": "DotLottiePlayerBase",
53
- "module": "/dist/chunks/DotLottiePlayerBase-ClCZP878.js"
53
+ "module": "/dist/chunks/DotLottiePlayerBase-DZEPP1-j.js"
54
54
  },
55
55
  "tagName": "tagName",
56
56
  "customElement": true
@@ -86,7 +86,7 @@
86
86
  "name": "MouseOut",
87
87
  "declaration": {
88
88
  "name": "M",
89
- "module": "./chunks/DotLottiePlayerBase-ClCZP878.js"
89
+ "module": "./chunks/DotLottiePlayerBase-DZEPP1-j.js"
90
90
  }
91
91
  },
92
92
  {
@@ -94,7 +94,7 @@
94
94
  "name": "PlayerState",
95
95
  "declaration": {
96
96
  "name": "P",
97
- "module": "./chunks/DotLottiePlayerBase-ClCZP878.js"
97
+ "module": "./chunks/DotLottiePlayerBase-DZEPP1-j.js"
98
98
  }
99
99
  },
100
100
  {
package/dist/canvas.d.ts CHANGED
@@ -2,8 +2,8 @@ import { RendererType, PreserveAspectRatio } from '@aarsteinmedia/lottie-web/uti
2
2
  export { PlayMode, PlayerEvent, RendererType } from '@aarsteinmedia/lottie-web/utils';
3
3
  import * as _aarsteinmedia_lottie_web from '@aarsteinmedia/lottie-web';
4
4
  import { AnimationConfiguration, Vector2 } from '@aarsteinmedia/lottie-web';
5
- import { D as DotLottiePlayerBase } from './chunks/DotLottiePlayerBase.d-DaXI0b6M.js';
6
- export { M as MouseOut, P as PlayerState, t as tagName } from './chunks/DotLottiePlayerBase.d-DaXI0b6M.js';
5
+ import { D as DotLottiePlayerBase } from './chunks/DotLottiePlayerBase.d-avku0LBw.js';
6
+ export { M as MouseOut, P as PlayerState, t as tagName } from './chunks/DotLottiePlayerBase.d-avku0LBw.js';
7
7
 
8
8
  declare class DotLottiePlayerCanvas extends DotLottiePlayerBase {
9
9
  get renderer(): RendererType;
package/dist/canvas.js CHANGED
@@ -1,8 +1,8 @@
1
1
  import { RendererType, isServer } from '@aarsteinmedia/lottie-web/utils';
2
2
  export { PlayMode, PlayerEvent, RendererType } from '@aarsteinmedia/lottie-web/utils';
3
3
  import Lottie from '@aarsteinmedia/lottie-web/canvas';
4
- import { D as DotLottiePlayerBase, t as tagName } from './chunks/DotLottiePlayerBase-ClCZP878.js';
5
- export { M as MouseOut, P as PlayerState } from './chunks/DotLottiePlayerBase-ClCZP878.js';
4
+ import { D as DotLottiePlayerBase, t as tagName } from './chunks/DotLottiePlayerBase-DZEPP1-j.js';
5
+ export { M as MouseOut, P as PlayerState } from './chunks/DotLottiePlayerBase-DZEPP1-j.js';
6
6
  import '@aarsteinmedia/lottie-web/dotlottie';
7
7
 
8
8
  /**
@@ -626,6 +626,15 @@ const notImplemented = 'Method is not implemented', getStyles = async ()=>{
626
626
  return null;
627
627
  }
628
628
  /**
629
+ * Whether to display error screen on load error.
630
+ */ set quiet(value) {
631
+ this.setAttribute('quiet', Boolean(value).toString());
632
+ }
633
+ get quiet() {
634
+ const val = this.getAttribute('quiet');
635
+ return parseHTMLBooleans(val);
636
+ }
637
+ /**
629
638
  * Renderer to use: svg, canvas or html.
630
639
  */ set renderer(value) {
631
640
  this.setAttribute('renderer', value);
@@ -905,8 +914,7 @@ const notImplemented = 'Method is not implemented', getStyles = async ()=>{
905
914
  this.dispatchEvent(new CustomEvent(PlayerEvent.Rendered));
906
915
  })();
907
916
  } catch (error) {
908
- console.error(error);
909
- this.dispatchEvent(new CustomEvent(PlayerEvent.Error));
917
+ void this._handleError(error);
910
918
  }
911
919
  }
912
920
  convert(_params) {
@@ -1009,7 +1017,7 @@ const notImplemented = 'Method is not implemented', getStyles = async ()=>{
1009
1017
  ]
1010
1018
  };
1011
1019
  // Clear previous animation, if any
1012
- this._lottieInstance?.destroy();
1020
+ this._clearPrevious();
1013
1021
  this.playerState = PlayerState.Stopped;
1014
1022
  if (!this.animateOnScroll && // !this.playOnVisible &&
1015
1023
  (this.autoplay || this._multiAnimationSettings[this._currentAnimation]?.autoplay || this.playOnVisible)) {
@@ -1032,10 +1040,7 @@ const notImplemented = 'Method is not implemented', getStyles = async ()=>{
1032
1040
  }
1033
1041
  await this._renderControls();
1034
1042
  } catch (error) {
1035
- console.error(error);
1036
- this._errorMessage = handleErrors(error).message;
1037
- this.playerState = PlayerState.Error;
1038
- this.dispatchEvent(new CustomEvent(PlayerEvent.Error));
1043
+ await this._handleError(error);
1039
1044
  }
1040
1045
  }
1041
1046
  loadAnimation(_config) {
@@ -1361,7 +1366,12 @@ const notImplemented = 'Method is not implemented', getStyles = async ()=>{
1361
1366
  if (this.playerState !== PlayerState.Error) {
1362
1367
  return;
1363
1368
  }
1364
- const figure = this.shadow?.querySelector('.animation');
1369
+ const figure = this.shadow?.querySelector('.animation'), /**
1370
+ * Hide controls if visible.
1371
+ */ controlSlot = this.shadow?.querySelector('slot[name=controls]');
1372
+ if (controlSlot) {
1373
+ controlSlot.innerHTML = '';
1374
+ }
1365
1375
  if (!(figure instanceof HTMLElement)) {
1366
1376
  return;
1367
1377
  }
@@ -1430,6 +1440,13 @@ const notImplemented = 'Method is not implemented', getStyles = async ()=>{
1430
1440
  });
1431
1441
  this._intersectionObserver.observe(this._container);
1432
1442
  }
1443
+ _clearPrevious() {
1444
+ this._lottieInstance?.destroy();
1445
+ const figure = this.shadow?.querySelector('.animation');
1446
+ if (figure) {
1447
+ figure.innerHTML = '';
1448
+ }
1449
+ }
1433
1450
  _complete() {
1434
1451
  if (!this._lottieInstance) {
1435
1452
  return;
@@ -1525,6 +1542,15 @@ const notImplemented = 'Method is not implemented', getStyles = async ()=>{
1525
1542
  rendererType: this.renderer
1526
1543
  });
1527
1544
  }
1545
+ async _handleError(error) {
1546
+ this.playerState = PlayerState.Error;
1547
+ if (!this.quiet) {
1548
+ this._errorMessage = handleErrors(error).message;
1549
+ await this._showError();
1550
+ }
1551
+ this.dispatchEvent(new CustomEvent(PlayerEvent.Error));
1552
+ console.error(error);
1553
+ }
1528
1554
  /**
1529
1555
  * Handle scroll.
1530
1556
  */ _handleScroll() {
@@ -77,6 +77,8 @@ declare abstract class DotLottiePlayerBase extends PropertyCallbackElement {
77
77
  get playOnVisible(): HTMLBooleanAttribute;
78
78
  set preserveAspectRatio(value: PreserveAspectRatio | null);
79
79
  get preserveAspectRatio(): PreserveAspectRatio | null;
80
+ set quiet(value: HTMLBooleanAttribute);
81
+ get quiet(): HTMLBooleanAttribute;
80
82
  set renderer(value: RendererType);
81
83
  get renderer(): RendererType;
82
84
  set selector(value: string | null);
@@ -164,12 +166,14 @@ declare abstract class DotLottiePlayerBase extends PropertyCallbackElement {
164
166
  }): AnimationConfiguration;
165
167
  private _addEventListeners;
166
168
  private _addIntersectionObserver;
169
+ private _clearPrevious;
167
170
  private _complete;
168
171
  private _dataFailed;
169
172
  private _dataReady;
170
173
  private _DOMLoaded;
171
174
  private _enterFrame;
172
175
  private _getOptions;
176
+ private _handleError;
173
177
  private _handleScroll;
174
178
  private _handleWindowBlur;
175
179
  private _intersectionObserverFallback;
package/dist/full.d.ts CHANGED
@@ -2,8 +2,8 @@ import { RendererType, PreserveAspectRatio } from '@aarsteinmedia/lottie-web/uti
2
2
  export { PlayMode, PlayerEvent, RendererType } from '@aarsteinmedia/lottie-web/utils';
3
3
  import * as _aarsteinmedia_lottie_web from '@aarsteinmedia/lottie-web';
4
4
  import { AddAnimationParams, ConvertParams, AnimationConfiguration, Vector2 } from '@aarsteinmedia/lottie-web';
5
- import { D as DotLottiePlayerBase } from './chunks/DotLottiePlayerBase.d-DaXI0b6M.js';
6
- export { M as MouseOut, P as PlayerState, t as tagName } from './chunks/DotLottiePlayerBase.d-DaXI0b6M.js';
5
+ import { D as DotLottiePlayerBase } from './chunks/DotLottiePlayerBase.d-avku0LBw.js';
6
+ export { M as MouseOut, P as PlayerState, t as tagName } from './chunks/DotLottiePlayerBase.d-avku0LBw.js';
7
7
 
8
8
  declare class DotLottiePlayer extends DotLottiePlayerBase {
9
9
  addAnimation(params: AddAnimationParams): Promise<_aarsteinmedia_lottie_web.Result>;
package/dist/full.js CHANGED
@@ -1,8 +1,8 @@
1
1
  import { RendererType, isServer } from '@aarsteinmedia/lottie-web/utils';
2
2
  export { PlayMode, PlayerEvent, RendererType } from '@aarsteinmedia/lottie-web/utils';
3
3
  import { loadAnimation } from '@aarsteinmedia/lottie-web';
4
- import { D as DotLottiePlayerBase, l as loadDotLottieTools, t as tagName } from './chunks/DotLottiePlayerBase-ClCZP878.js';
5
- export { M as MouseOut, P as PlayerState } from './chunks/DotLottiePlayerBase-ClCZP878.js';
4
+ import { D as DotLottiePlayerBase, l as loadDotLottieTools, t as tagName } from './chunks/DotLottiePlayerBase-DZEPP1-j.js';
5
+ export { M as MouseOut, P as PlayerState } from './chunks/DotLottiePlayerBase-DZEPP1-j.js';
6
6
  import '@aarsteinmedia/lottie-web/dotlottie';
7
7
 
8
8
  /**
package/dist/light.d.ts CHANGED
@@ -2,8 +2,8 @@ import { RendererType, PreserveAspectRatio } from '@aarsteinmedia/lottie-web/uti
2
2
  export { PlayMode, PlayerEvent, RendererType } from '@aarsteinmedia/lottie-web/utils';
3
3
  import * as _aarsteinmedia_lottie_web from '@aarsteinmedia/lottie-web';
4
4
  import { AnimationConfiguration, Vector2 } from '@aarsteinmedia/lottie-web';
5
- import { D as DotLottiePlayerBase } from './chunks/DotLottiePlayerBase.d-DaXI0b6M.js';
6
- export { M as MouseOut, P as PlayerState, t as tagName } from './chunks/DotLottiePlayerBase.d-DaXI0b6M.js';
5
+ import { D as DotLottiePlayerBase } from './chunks/DotLottiePlayerBase.d-avku0LBw.js';
6
+ export { M as MouseOut, P as PlayerState, t as tagName } from './chunks/DotLottiePlayerBase.d-avku0LBw.js';
7
7
 
8
8
  declare class DotLottiePlayerLight extends DotLottiePlayerBase {
9
9
  get renderer(): RendererType;
package/dist/light.js CHANGED
@@ -1,8 +1,8 @@
1
1
  import { RendererType, isServer } from '@aarsteinmedia/lottie-web/utils';
2
2
  export { PlayMode, PlayerEvent, RendererType } from '@aarsteinmedia/lottie-web/utils';
3
3
  import { loadAnimation } from '@aarsteinmedia/lottie-web/light';
4
- import { D as DotLottiePlayerBase, t as tagName } from './chunks/DotLottiePlayerBase-ClCZP878.js';
5
- export { M as MouseOut, P as PlayerState } from './chunks/DotLottiePlayerBase-ClCZP878.js';
4
+ import { D as DotLottiePlayerBase, t as tagName } from './chunks/DotLottiePlayerBase-DZEPP1-j.js';
5
+ export { M as MouseOut, P as PlayerState } from './chunks/DotLottiePlayerBase-DZEPP1-j.js';
6
6
  import '@aarsteinmedia/lottie-web/dotlottie';
7
7
 
8
8
  /**
package/dist/svg.d.ts CHANGED
@@ -2,8 +2,8 @@ import { RendererType, PreserveAspectRatio } from '@aarsteinmedia/lottie-web/uti
2
2
  export { PlayMode, PlayerEvent, RendererType } from '@aarsteinmedia/lottie-web/utils';
3
3
  import * as _aarsteinmedia_lottie_web from '@aarsteinmedia/lottie-web';
4
4
  import { AnimationConfiguration, Vector2 } from '@aarsteinmedia/lottie-web';
5
- import { D as DotLottiePlayerBase } from './chunks/DotLottiePlayerBase.d-DaXI0b6M.js';
6
- export { M as MouseOut, P as PlayerState, t as tagName } from './chunks/DotLottiePlayerBase.d-DaXI0b6M.js';
5
+ import { D as DotLottiePlayerBase } from './chunks/DotLottiePlayerBase.d-avku0LBw.js';
6
+ export { M as MouseOut, P as PlayerState, t as tagName } from './chunks/DotLottiePlayerBase.d-avku0LBw.js';
7
7
 
8
8
  declare class DotLottiePlayerSVG extends DotLottiePlayerBase {
9
9
  get renderer(): RendererType;
package/dist/svg.js CHANGED
@@ -1,8 +1,8 @@
1
1
  import { RendererType, isServer } from '@aarsteinmedia/lottie-web/utils';
2
2
  export { PlayMode, PlayerEvent, RendererType } from '@aarsteinmedia/lottie-web/utils';
3
3
  import { loadAnimation } from '@aarsteinmedia/lottie-web/svg';
4
- import { D as DotLottiePlayerBase, t as tagName } from './chunks/DotLottiePlayerBase-ClCZP878.js';
5
- export { M as MouseOut, P as PlayerState } from './chunks/DotLottiePlayerBase-ClCZP878.js';
4
+ import { D as DotLottiePlayerBase, t as tagName } from './chunks/DotLottiePlayerBase-DZEPP1-j.js';
5
+ export { M as MouseOut, P as PlayerState } from './chunks/DotLottiePlayerBase-DZEPP1-j.js';
6
6
  import '@aarsteinmedia/lottie-web/dotlottie';
7
7
 
8
8
  /**