@aarsteinmedia/dotlottie-player 6.0.5 → 6.1.1
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 +12 -0
- package/README.md +8 -0
- package/dist/canvas.d.ts +16 -2
- package/dist/canvas.js +332 -94
- package/dist/full.d.ts +16 -2
- package/dist/full.js +332 -94
- package/dist/light.d.ts +16 -2
- package/dist/light.js +332 -94
- package/dist/svg.d.ts +16 -2
- package/dist/svg.js +332 -94
- package/dist/unpkg-canvas.js +9 -9
- package/dist/unpkg-full.js +8 -8
- package/dist/unpkg-light.js +5 -5
- package/dist/unpkg-svg.js +8 -8
- package/package.json +16 -15
package/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,18 @@ 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.1.1] - 13-10-2025
|
|
11
|
+
|
|
12
|
+
### Changed
|
|
13
|
+
|
|
14
|
+
- Added attributes:
|
|
15
|
+
- `delay` – Delay playback on playOnVisible, in miliseconds
|
|
16
|
+
- `mouseout` – Action on mouseout
|
|
17
|
+
- `once` – Whether, if playOnVisible is true, to play once or anytime animation is in view
|
|
18
|
+
- `playOnClick` – Whether to toggle play on click
|
|
19
|
+
- `playOnVisible` – Play when visible
|
|
20
|
+
- `selector` – Play on clicked element by id attribute
|
|
21
|
+
|
|
10
22
|
## [6.0.5] - 12-09-2025
|
|
11
23
|
|
|
12
24
|
### Changed
|
package/README.md
CHANGED
|
@@ -306,13 +306,21 @@ export default defineNuxtPlugin(({ vueApp }) => {
|
|
|
306
306
|
| `background` | Background color | `string` | `undefined` |
|
|
307
307
|
| `controls` | Show controls | `boolean` | `false` |
|
|
308
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` |
|
|
309
311
|
| `direction` | Direction of animation | `1` \| `-1` | `1` |
|
|
310
312
|
| `dontFreezeOnBlur` | Whether to freeze playback on window blur. This is default behavior, but can be disabled | `boolean` | `1` |
|
|
311
313
|
| `hover` | Whether to play on mouse hover | `boolean` | `false` |
|
|
314
|
+
| `intermission` | Pause between loop intrations, in miliseconds | `number` | `0` |
|
|
312
315
|
| `loop` | Whether to loop animation | `boolean` | `false` |
|
|
313
316
|
| `mode` | Play mode | `normal` \| `bounce` | `normal` |
|
|
317
|
+
| `mouseout` | Action on mouseout | `void` \| `stop` \| `pause` \| `reverse` | `stop` |
|
|
314
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` |
|
|
315
322
|
| `renderer` | Renderer to use | `svg` \| `canvas` \| `html` | `svg` |
|
|
323
|
+
| `selector` | Play on clicked element by id attribute | `string` | `undefined` |
|
|
316
324
|
| `speed` | Animation speed | `number` | `1` |
|
|
317
325
|
| `src` _(required)_ | URL to LottieJSON or dotLottie | `string` | `undefined` |
|
|
318
326
|
| `subframe` | When enabled this can help to reduce flicker on some animations, especially on Safari and iOS devices. | `boolean` | `false` |
|
package/dist/canvas.d.ts
CHANGED
|
@@ -111,7 +111,7 @@ declare function renderControls(this: DotLottiePlayerBase): void;
|
|
|
111
111
|
declare function renderPlayer(this: DotLottiePlayerBase): Promise<void>;
|
|
112
112
|
|
|
113
113
|
declare abstract class DotLottiePlayerBase extends PropertyCallbackElement {
|
|
114
|
-
static get observedAttributes():
|
|
114
|
+
static get observedAttributes(): readonly ["animateOnScroll", "autoplay", "controls", "direction", "hover", "loop", "mode", "playOnClick", "playOnVisible", "selector", "speed", "src", "subframe"];
|
|
115
115
|
static get observedProperties(): string[];
|
|
116
116
|
static get styles(): () => Promise<CSSStyleSheet>;
|
|
117
117
|
isLight: boolean;
|
|
@@ -131,6 +131,8 @@ declare abstract class DotLottiePlayerBase extends PropertyCallbackElement {
|
|
|
131
131
|
set count(value: number);
|
|
132
132
|
get count(): number;
|
|
133
133
|
get currentAnimation(): number;
|
|
134
|
+
set delay(value: number);
|
|
135
|
+
get delay(): number;
|
|
134
136
|
set description(value: string | null);
|
|
135
137
|
get description(): string | null;
|
|
136
138
|
set direction(value: AnimationDirection);
|
|
@@ -146,12 +148,22 @@ declare abstract class DotLottiePlayerBase extends PropertyCallbackElement {
|
|
|
146
148
|
get loop(): Loop;
|
|
147
149
|
set mode(value: PlayMode);
|
|
148
150
|
get mode(): PlayMode;
|
|
151
|
+
set mouseout(value: 'void' | 'stop' | 'pause' | 'reverse');
|
|
152
|
+
get mouseout(): "void" | "stop" | "pause" | "reverse";
|
|
149
153
|
set objectfit(value: 'contain' | 'cover' | 'fill' | 'none' | 'scale-down');
|
|
150
154
|
get objectfit(): "contain" | "cover" | "fill" | "none" | "scale-down";
|
|
155
|
+
set once(value: boolean);
|
|
156
|
+
get once(): boolean;
|
|
157
|
+
set playOnClick(value: boolean);
|
|
158
|
+
get playOnClick(): boolean;
|
|
159
|
+
set playOnVisible(value: boolean);
|
|
160
|
+
get playOnVisible(): boolean;
|
|
151
161
|
set preserveAspectRatio(value: PreserveAspectRatio | null);
|
|
152
162
|
get preserveAspectRatio(): PreserveAspectRatio | null;
|
|
153
163
|
set renderer(value: RendererType);
|
|
154
164
|
get renderer(): RendererType;
|
|
165
|
+
set selector(value: string | null);
|
|
166
|
+
get selector(): string | null;
|
|
155
167
|
set simple(value: boolean);
|
|
156
168
|
get simple(): boolean;
|
|
157
169
|
set speed(value: number);
|
|
@@ -186,7 +198,7 @@ declare abstract class DotLottiePlayerBase extends PropertyCallbackElement {
|
|
|
186
198
|
private _segment?;
|
|
187
199
|
constructor();
|
|
188
200
|
addAnimation(_params: AddAnimationParams): Promise<Result>;
|
|
189
|
-
attributeChangedCallback(name:
|
|
201
|
+
attributeChangedCallback(name: typeof DotLottiePlayerBase.observedAttributes[number], _oldValue: unknown, value: string): Promise<void>;
|
|
190
202
|
connectedCallback(): void;
|
|
191
203
|
convert(_params: ConvertParams): Promise<Result>;
|
|
192
204
|
destroy(): void;
|
|
@@ -218,6 +230,7 @@ declare abstract class DotLottiePlayerBase extends PropertyCallbackElement {
|
|
|
218
230
|
togglePlay(): void;
|
|
219
231
|
protected _freeze(): void;
|
|
220
232
|
protected _handleBlur(): void;
|
|
233
|
+
protected _handleClick(): void;
|
|
221
234
|
protected _handleSeekChange({ target }: Event): void;
|
|
222
235
|
protected _handleSettingsClick({ target }: Event): void;
|
|
223
236
|
protected setOptions(_options: {
|
|
@@ -238,6 +251,7 @@ declare abstract class DotLottiePlayerBase extends PropertyCallbackElement {
|
|
|
238
251
|
private _getOptions;
|
|
239
252
|
private _handleScroll;
|
|
240
253
|
private _handleWindowBlur;
|
|
254
|
+
private _intersectionObserverFallback;
|
|
241
255
|
private _loopComplete;
|
|
242
256
|
private _mouseEnter;
|
|
243
257
|
private _mouseLeave;
|