Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
name: 'value',
type: 'float'
}];
}
var fromData = new List(coordDimsInfos, mlModel);
var toData = new List(coordDimsInfos, mlModel);
// No dimensions
var lineData = new List([], mlModel);
var optData = zrUtil.map(mlModel.get('data'), zrUtil.curry(
markLineTransform, seriesModel, coordSys, mlModel
));
if (coordSys) {
optData = zrUtil.filter(
optData, zrUtil.curry(markLineFilter, coordSys)
);
}
var dimValueGetter = coordSys ? markerHelper.dimValueGetter : function (item) {
return item.value;
};
fromData.initData(
zrUtil.map(optData, function (item) { return item[0]; }),
null, dimValueGetter
);
toData.initData(
zrUtil.map(optData, function (item) { return item[1]; }),
null, dimValueGetter
);
lineData.initData(
zrUtil.map(optData, function (item) { return item[2]; })
);
var info = seriesModel.getData().getDimensionInfo(
seriesModel.coordDimToDataDim(coordDim)[0]
) || {}; // In map series data don't have lng and lat dimension. Fallback to same with coordSys
info.name = coordDim;
return info;
});
}
else {
coordDimsInfos =[{
name: 'value',
type: 'float'
}];
}
var mpData = new List(coordDimsInfos, mpModel);
var dataOpt = zrUtil.map(mpModel.get('data'), zrUtil.curry(
markerHelper.dataTransform, seriesModel
));
if (coordSys) {
dataOpt = zrUtil.filter(
dataOpt, zrUtil.curry(markerHelper.dataFilter, coordSys)
);
}
mpData.initData(dataOpt, null,
coordSys ? markerHelper.dimValueGetter : function (item) {
return item.value;
}
);
return mpData;
}
return;
}
var itemSize = +toolboxModel.get('itemSize');
var featureOpts = toolboxModel.get('feature') || {};
var features = this._features || (this._features = {});
var featureNames = [];
zrUtil.each(featureOpts, function (opt, name) {
featureNames.push(name);
});
(new DataDiffer(this._featureNames || [], featureNames))
.add(process)
.update(process)
.remove(zrUtil.curry(process, null))
.execute();
// Keep for diff.
this._featureNames = featureNames;
function process(newIndex, oldIndex) {
var featureName = featureNames[newIndex];
var oldName = featureNames[oldIndex];
var featureOpt = featureOpts[featureName];
var featureModel = new Model(featureOpt, toolboxModel, toolboxModel.ecModel);
var feature;
if (featureName && !oldName) { // Create
if (isUserFeatureName(featureName)) {
feature = {
model: featureModel,
define(function (require) {
var zrUtil = require('zrender/core/util');
require('../coord/cartesian/Grid');
require('./bar/BarSeries');
require('./bar/BarView');
var barLayoutGrid = require('../layout/barGrid');
var echarts = require('../echarts');
echarts.registerLayout(zrUtil.curry(barLayoutGrid, 'bar'));
// Visual coding for legend
echarts.registerVisualCoding('chart', function (ecModel) {
ecModel.eachSeriesByType('bar', function (seriesModel) {
var data = seriesModel.getData();
data.setVisual('legendSymbol', 'roundRect');
});
});
// In case developer forget to include grid component
require('../component/grid');
});
});
}
else {
coordDimsInfos =[{
name: 'value',
type: 'float'
}];
}
var mpData = new List(coordDimsInfos, mpModel);
var dataOpt = zrUtil.map(mpModel.get('data'), zrUtil.curry(
markerHelper.dataTransform, seriesModel
));
if (coordSys) {
dataOpt = zrUtil.filter(
dataOpt, zrUtil.curry(markerHelper.dataFilter, coordSys)
);
}
mpData.initData(dataOpt, null,
coordSys ? markerHelper.dimValueGetter : function (item) {
return item.value;
}
);
return mpData;
}
define(function (require) {
var zrUtil = require('zrender/core/util');
var echarts = require('../echarts');
require('./radar/RadarSeries');
require('./radar/RadarView');
echarts.registerVisualCoding('chart', zrUtil.curry(
require('../visual/symbol'), 'radar', 'circle', null
));
echarts.registerLayout(zrUtil.curry(
require('../layout/points'), 'radar'
));
echarts.registerPreprocessor(require('./radar/backwardCompat'));
});
},
defaultOption: zrUtil.mergeAll(
[
{},
axisDefault[axisType + 'Axis'],
extraDefaultOption
],
true
)
});
});
ComponentModel.registerSubTypeDefaulter(
axisName + 'Axis',
zrUtil.curry(axisTypeDefaulter, axisName)
);
};
});
define(function (require) {
var echarts = require('../echarts');
var zrUtil = require('zrender/core/util');
require('./themeRiver/ThemeRiverSeries');
require('./themeRiver/ThemeRiverView');
echarts.registerLayout(require('./themeRiver/themeRiverLayout'));
echarts.registerVisualCoding('chart', require('./themeRiver/themeRiverVisual'));
echarts.registerProcessor(
'filter', zrUtil.curry(require('../processor/dataFilter'), 'themeRiver')
);
});
define(function (require) {
require('./chord/ChordSeries');
require('./chord/ChordView');
var echarts = require('../echarts');
var zrUtil = require('zrender/core/util');
echarts.registerLayout(require('./chord/chordCircularLayout'));
echarts.registerVisualCoding(
'chart', zrUtil.curry(require('../visual/dataColor'), 'chord')
);
echarts.registerProcessor(
'filter', zrUtil.curry(require('../processor/dataFilter'), 'pie')
);
});
define(function (require) {
require('./lines/LinesSeries');
require('./lines/LinesView');
var zrUtil = require('zrender/core/util');
var echarts = require('../echarts');
echarts.registerLayout(
require('./lines/linesLayout')
);
echarts.registerVisual(
zrUtil.curry(require('../visual/seriesColor'), 'lines', 'lineStyle')
);
});