lepu-test-platform-web/node_modules/zrender/lib/graphic/Gradient.js

18 lines
352 B
JavaScript
Raw Normal View History

/**
* @param {Array.<Object>} colorStops
*/
var Gradient = function (colorStops) {
this.colorStops = colorStops || [];
};
Gradient.prototype = {
constructor: Gradient,
addColorStop: function (offset, color) {
this.colorStops.push({
offset: offset,
color: color
});
}
};
var _default = Gradient;
module.exports = _default;