wibbitz-lottie-web
Advanced tools
Comparing version 5.6.1-8 to 5.6.1-9
{ | ||
"name": "wibbitz-lottie-web", | ||
"version": "5.6.1-8", | ||
"version": "5.6.1-9", | ||
"description": "After Effects plugin for exporting animations to SVG + JavaScript or canvas + JavaScript", | ||
@@ -5,0 +5,0 @@ "main": "./build/player/lottie.js", |
@@ -5,2 +5,3 @@ function SVGTextElement(data,globalData,comp){ | ||
this.initElement(data,globalData,comp); | ||
this._readOnly = readOnlyLayers.includes(data.nm); | ||
} | ||
@@ -33,7 +34,11 @@ | ||
SVGTextElement.prototype.buildNewText = function(){ | ||
var isReadOnly = this.data.nm === '.calculatedData'; | ||
SVGTextElement.prototype.buildNewText = function(isReadOnly){ | ||
var i, len; | ||
var documentData = this.textProperty.currentData; | ||
if(isReadOnly) { | ||
this.layerElement.setAttribute('ready-only-data', documentData.t); | ||
return; | ||
} | ||
this.renderedLetters = createSizedArray(documentData ? documentData.l.length : 0); | ||
@@ -70,5 +75,2 @@ if(documentData.fc) { | ||
var trackingOffset = documentData.tr/1000*documentData.finalSize; | ||
if (isReadOnly) return; | ||
if(singleShape && !usesGlyphs && !documentData.sz) { | ||
@@ -75,0 +77,0 @@ var tElement = this.textContainer; |
@@ -8,3 +8,3 @@ function ITextElement(){ | ||
this.initBaseData(data, globalData, comp); | ||
this.textProperty = new TextProperty(this, data.t, data.nm === '.calculatedData'); // calculatedData is a layer used for DF to take data from lottie calculations | ||
this.textProperty = new TextProperty(this, data.t, this.dynamicProperties); | ||
this.textAnimator = new TextAnimatorProperty(data.t, this.renderType, this); | ||
@@ -27,3 +27,3 @@ this.initTransform(data, globalData, comp); | ||
if(this.textProperty._mdf || this.textProperty._isFirstFrame) { | ||
this.buildNewText(); | ||
this.buildNewText(this._readOnly); | ||
this.textProperty._isFirstFrame = false; | ||
@@ -30,0 +30,0 @@ this.textProperty._mdf = false; |
@@ -6,1 +6,3 @@ var svgNS = "http://www.w3.org/2000/svg"; | ||
var initialDefaultFrame = -999999; | ||
var readOnlyLayers = ['.calculatedData', 'inAnimCustomBezier', 'outAnimCustomBezier']; |
@@ -1,3 +0,4 @@ | ||
function TextProperty(elem, data, isReadOnly){ | ||
function TextProperty(elem, data){ | ||
this._frameId = initialDefaultFrame; | ||
this._readOnly = readOnlyLayers.includes(elem.data.nm); | ||
this.pv = ''; | ||
@@ -22,3 +23,2 @@ this.v = ''; | ||
fc: '', | ||
isReadOnly: isReadOnly, | ||
j: '', | ||
@@ -47,8 +47,7 @@ justifyOffset: '', | ||
}; | ||
}; | ||
this.copyData(this.currentData, this.data.d.k[0].s); | ||
if(!this.searchProperty()) { | ||
this.completeTextData(this.currentData); | ||
this.completeTextData(this.currentData, this._readOnly); | ||
} | ||
@@ -70,3 +69,3 @@ } | ||
if(!data.__complete) { | ||
this.completeTextData(data); | ||
this.completeTextData(data, this._readOnly); | ||
} | ||
@@ -171,5 +170,5 @@ this.currentData = data; | ||
TextProperty.prototype.completeTextData = function(documentData) { | ||
if (documentData.isReadOnly) return; | ||
TextProperty.prototype.completeTextData = function(documentData, autoComplete) { | ||
documentData.__complete = true; | ||
if (autoComplete) return; | ||
var fontManager = this.elem.globalData.fontManager; | ||
@@ -176,0 +175,0 @@ var data = this.data; |
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 too big to display
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 too big to display
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 too big to display
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 too big to display
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 too big to display
Sorry, the diff of this file is too big to display
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
29504570
123334