@dotlottie/dotlottie-js
Advanced tools
Comparing version 0.4.0-beta.8 to 0.4.0-beta.9
@@ -140,4 +140,3 @@ import { ZipOptions } from 'fflate'; | ||
interface StateOptions { | ||
id: string; | ||
state?: DotLottieState; | ||
state: DotLottieState; | ||
zipOptions?: ZipOptions; | ||
@@ -144,0 +143,0 @@ } |
@@ -114,4 +114,3 @@ import { ZipOptions } from 'fflate'; | ||
interface StateOptions { | ||
id: string; | ||
state?: DotLottieState; | ||
state: DotLottieState; | ||
zipOptions?: ZipOptions; | ||
@@ -118,0 +117,0 @@ } |
@@ -14,3 +14,3 @@ import { strToU8, zip, unzip, strFromU8 } from 'fflate'; | ||
name: "@dotlottie/dotlottie-js", | ||
version: "0.4.0-beta.8", | ||
version: "0.4.0-beta.9", | ||
type: "module", | ||
@@ -140,7 +140,7 @@ description: "This library helps in creating and modifying .lottie files.", | ||
__publicField(this, "_state"); | ||
this._requireValidId(options.id); | ||
this._id = options.id; | ||
this._requireValidId(options.state.descriptor.id); | ||
if (options.state.descriptor.id) | ||
this._id = options.state.descriptor.id; | ||
this._zipOptions = options.zipOptions ?? {}; | ||
if (options.state) | ||
this._state = options.state; | ||
this._state = options.state; | ||
} | ||
@@ -648,3 +648,3 @@ get zipOptions() { | ||
const newState = new DotLottieStateCommon(state); | ||
this._stateMap.set(state.id, newState); | ||
this._stateMap.set(state.state.descriptor.id, newState); | ||
return this; | ||
@@ -1509,3 +1509,2 @@ } | ||
dotlottie.addState({ | ||
id: state, | ||
state: JSON.parse(decodedStr) | ||
@@ -1512,0 +1511,0 @@ }); |
{ | ||
"name": "@dotlottie/dotlottie-js", | ||
"version": "0.4.0-beta.8", | ||
"version": "0.4.0-beta.9", | ||
"type": "module", | ||
@@ -5,0 +5,0 @@ "description": "This library helps in creating and modifying .lottie files.", |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
476967
7127