@depup/lottie-react 2.4.1-depup.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/LICENSE ADDED
@@ -0,0 +1,46 @@
1
+ The MIT License
2
+
3
+ Copyright David Gamote and other contributors.
4
+
5
+ This software consists of voluntary contributions made by many
6
+ individuals. For exact contribution history, see the revision history
7
+ available on GitHub.
8
+
9
+ The following license applies to all parts of this software except as
10
+ documented below:
11
+
12
+ ====
13
+
14
+ Permission is hereby granted, free of charge, to any person obtaining
15
+ a copy of this software and associated documentation files (the
16
+ "Software"), to deal in the Software without restriction, including
17
+ without limitation the rights to use, copy, modify, merge, publish,
18
+ distribute, sublicense, and/or sell copies of the Software, and to
19
+ permit persons to whom the Software is furnished to do so, subject to
20
+ the following conditions:
21
+
22
+ The above copyright notice and this permission notice shall be
23
+ included in all copies or substantial portions of the Software.
24
+
25
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
26
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
27
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
28
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
29
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
30
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
31
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
32
+
33
+ ====
34
+
35
+ Copyright and related rights for sample code are waived via CC0. Sample
36
+ code is defined as all source code displayed within the prose of the
37
+ documentation.
38
+
39
+ CC0: http://creativecommons.org/publicdomain/zero/1.0/
40
+
41
+ ====
42
+
43
+ Files located in the node_modules and vendor directories are externally
44
+ maintained libraries used by this software which have their own
45
+ licenses; we recommend you read them, as their terms may differ from the
46
+ terms above.
package/README.md ADDED
@@ -0,0 +1,31 @@
1
+ # @depup/lottie-react
2
+
3
+ > Dependency-bumped version of [lottie-react](https://www.npmjs.com/package/lottie-react)
4
+
5
+ Generated by [DepUp](https://github.com/depup/npm) -- all production
6
+ dependencies bumped to latest versions.
7
+
8
+ ## Installation
9
+
10
+ ```bash
11
+ npm install @depup/lottie-react
12
+ ```
13
+
14
+ | Field | Value |
15
+ |-------|-------|
16
+ | Original | [lottie-react](https://www.npmjs.com/package/lottie-react) @ 2.4.1 |
17
+ | Processed | 2026-03-18 |
18
+ | Smoke test | failed |
19
+ | Deps updated | 1 |
20
+
21
+ ## Dependency Changes
22
+
23
+ | Dependency | From | To |
24
+ |------------|------|-----|
25
+ | lottie-web | ^5.10.2 | ^5.13.0 |
26
+
27
+ ---
28
+
29
+ Source: https://github.com/depup/npm | Original: https://www.npmjs.com/package/lottie-react
30
+
31
+ License inherited from the original package.
@@ -0,0 +1,80 @@
1
+ /// <reference types="react" />
2
+ import { AnimationDirection, AnimationSegment, AnimationItem, RendererType, AnimationConfigWithData, AnimationEventCallback, AnimationEvents, AnimationEventName } from 'lottie-web';
3
+ export { default as LottiePlayer } from 'lottie-web';
4
+ import * as react from 'react';
5
+ import react__default, { RefObject, MutableRefObject, ReactElement, CSSProperties } from 'react';
6
+
7
+ type LottieRefCurrentProps = {
8
+ play: () => void;
9
+ stop: () => void;
10
+ pause: () => void;
11
+ setSpeed: (speed: number) => void;
12
+ goToAndStop: (value: number, isFrame?: boolean) => void;
13
+ goToAndPlay: (value: number, isFrame?: boolean) => void;
14
+ setDirection: (direction: AnimationDirection) => void;
15
+ playSegments: (segments: AnimationSegment | AnimationSegment[], forceFlag?: boolean) => void;
16
+ setSubframe: (useSubFrames: boolean) => void;
17
+ getDuration: (inFrames?: boolean) => number | undefined;
18
+ destroy: () => void;
19
+ animationContainerRef: RefObject<HTMLDivElement>;
20
+ animationLoaded: boolean;
21
+ animationItem: AnimationItem | undefined;
22
+ };
23
+ type LottieRef = MutableRefObject<LottieRefCurrentProps | null>;
24
+ type LottieOptions<T extends RendererType = "svg"> = Omit<AnimationConfigWithData<T>, "container" | "animationData"> & {
25
+ animationData: unknown;
26
+ lottieRef?: LottieRef;
27
+ onComplete?: AnimationEventCallback<AnimationEvents[AnimationEventName]> | null;
28
+ onLoopComplete?: AnimationEventCallback<AnimationEvents[AnimationEventName]> | null;
29
+ onEnterFrame?: AnimationEventCallback<AnimationEvents[AnimationEventName]> | null;
30
+ onSegmentStart?: AnimationEventCallback<AnimationEvents[AnimationEventName]> | null;
31
+ onConfigReady?: AnimationEventCallback<AnimationEvents[AnimationEventName]> | null;
32
+ onDataReady?: AnimationEventCallback<AnimationEvents[AnimationEventName]> | null;
33
+ onDataFailed?: AnimationEventCallback<AnimationEvents[AnimationEventName]> | null;
34
+ onLoadedImages?: AnimationEventCallback<AnimationEvents[AnimationEventName]> | null;
35
+ onDOMLoaded?: AnimationEventCallback<AnimationEvents[AnimationEventName]> | null;
36
+ onDestroy?: AnimationEventCallback<AnimationEvents[AnimationEventName]> | null;
37
+ } & Omit<react__default.HTMLProps<HTMLDivElement>, "loop">;
38
+ type PartialLottieOptions = Omit<LottieOptions, "animationData"> & {
39
+ animationData?: LottieOptions["animationData"];
40
+ };
41
+ type Axis = "x" | "y";
42
+ type Position = {
43
+ [key in Axis]: number | [number, number];
44
+ };
45
+ type Action = {
46
+ type: "seek" | "play" | "stop" | "loop";
47
+ frames: [number] | [number, number];
48
+ visibility?: [number, number];
49
+ position?: Position;
50
+ };
51
+ type InteractivityProps = {
52
+ lottieObj: {
53
+ View: ReactElement;
54
+ } & LottieRefCurrentProps;
55
+ actions: Action[];
56
+ mode: "scroll" | "cursor";
57
+ };
58
+ type LottieComponentProps = LottieOptions & {
59
+ interactivity?: Omit<InteractivityProps, "lottieObj">;
60
+ };
61
+ type PartialLottieComponentProps = Omit<LottieComponentProps, "animationData"> & {
62
+ animationData?: LottieOptions["animationData"];
63
+ };
64
+ type Listener = {
65
+ name: AnimationEventName;
66
+ handler: AnimationEventCallback<AnimationEvents[AnimationEventName]>;
67
+ };
68
+ type PartialListener = Omit<Listener, "handler"> & {
69
+ handler?: Listener["handler"] | null;
70
+ };
71
+
72
+ declare const Lottie: (props: LottieComponentProps) => react.ReactElement<any, string | react.JSXElementConstructor<any>>;
73
+
74
+ declare const useLottie: <T extends RendererType = "svg">(props: LottieOptions<T>, style?: CSSProperties) => {
75
+ View: ReactElement;
76
+ } & LottieRefCurrentProps;
77
+
78
+ declare const useLottieInteractivity: ({ actions, mode, lottieObj, }: InteractivityProps) => ReactElement;
79
+
80
+ export { Action, Axis, InteractivityProps, Listener, LottieComponentProps, LottieOptions, LottieRef, LottieRefCurrentProps, PartialListener, PartialLottieComponentProps, PartialLottieOptions, Position, Lottie as default, useLottie, useLottieInteractivity };