feat: 第一次上传代码
This commit is contained in:
23
node_modules/lottie-web/player/js/elements/SolidElement.js
generated
vendored
Normal file
23
node_modules/lottie-web/player/js/elements/SolidElement.js
generated
vendored
Normal file
@@ -0,0 +1,23 @@
|
||||
import {
|
||||
extendPrototype,
|
||||
} from '../utils/functionExtensions';
|
||||
import createNS from '../utils/helpers/svg_elements';
|
||||
import IImageElement from './ImageElement';
|
||||
|
||||
function ISolidElement(data, globalData, comp) {
|
||||
this.initElement(data, globalData, comp);
|
||||
}
|
||||
extendPrototype([IImageElement], ISolidElement);
|
||||
|
||||
ISolidElement.prototype.createContent = function () {
|
||||
var rect = createNS('rect');
|
||||
/// /rect.style.width = this.data.sw;
|
||||
/// /rect.style.height = this.data.sh;
|
||||
/// /rect.style.fill = this.data.sc;
|
||||
rect.setAttribute('width', this.data.sw);
|
||||
rect.setAttribute('height', this.data.sh);
|
||||
rect.setAttribute('fill', this.data.sc);
|
||||
this.layerElement.appendChild(rect);
|
||||
};
|
||||
|
||||
export default ISolidElement;
|
||||
Reference in New Issue
Block a user