mirror of
https://codeup.aliyun.com/67c68d4e484ca2f0a13ac3c1/ydc/jsowell-charger-web.git
synced 2026-04-25 21:45:08 +08:00
# Conflicts: # jsowell-ui/.env.development # jsowell-ui/.env.staging # jsowell-ui/bin/build-sit.bat # jsowell-ui/bin/build.bat # jsowell-ui/src/api/adapayMember/adapayMember.js # jsowell-ui/src/api/pile/merchant.js # jsowell-ui/src/router/index.js # jsowell-ui/src/views/financial/financeDetail.vue # jsowell-ui/src/views/financial/merchant.vue # jsowell-ui/src/views/homeIndex/homeIndex.vue # jsowell-ui/src/views/login.vue # jsowell-ui/src/views/pile/basic/detail.vue # jsowell-ui/src/views/pile/station/components/SiteInfo.vue # jsowell-ui/src/views/pile/station/detail.vue # jsowell-ui/src/views/pile/station/orderReport.vue
32 lines
935 B
JavaScript
32 lines
935 B
JavaScript
var zrUtil = require("../core/util");
|
|
|
|
var Gradient = require("./Gradient");
|
|
|
|
/**
|
|
* x, y, r are all percent from 0 to 1
|
|
* @param {number} [x=0.5]
|
|
* @param {number} [y=0.5]
|
|
* @param {number} [r=0.5]
|
|
* @param {Array.<Object>} [colorStops]
|
|
* @param {boolean} [globalCoord=false]
|
|
*/
|
|
var RadialGradient = function (x, y, r, colorStops, globalCoord) {
|
|
// Should do nothing more in this constructor. Because gradient can be
|
|
// declard by `color: {type: 'radial', colorStops: ...}`, where
|
|
// this constructor will not be called.
|
|
this.x = x == null ? 0.5 : x;
|
|
this.y = y == null ? 0.5 : y;
|
|
this.r = r == null ? 0.5 : r; // Can be cloned
|
|
|
|
this.type = 'radial'; // If use global coord
|
|
|
|
this.global = globalCoord || false;
|
|
Gradient.call(this, colorStops);
|
|
};
|
|
|
|
RadialGradient.prototype = {
|
|
constructor: RadialGradient
|
|
};
|
|
zrUtil.inherits(RadialGradient, Gradient);
|
|
var _default = RadialGradient;
|
|
module.exports = _default; |