@pyreon/charts 0.6.0 → 0.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,4074 +0,0 @@
1
- import { A as ZRImage, An as isArray$1, C as ZRText, Dn as hasOwn, E as Rect$1, Gn as mergeAll, In as isNumber, Kn as mixin, Ln as isObject, Mn as isDom, Nn as isFunction, On as indexOf, Qt as BoundingRect, Rn as isString, S as Group$2, Sn as each$9, Tn as filter, Un as map, V as Displayable, Vn as keys, Wn as merge, Xn as retrieve, Yt as getBoundingRect, Zn as retrieve2, Zt as parsePercent, _ as stop, _t as stringify, b as transformLocalCoordClear, bn as defaults, cn as rotate, en as Point, g as normalizeEvent, gn as clone$1, hn as bind$1, ht as parse, m as addEventListener, pn as env, pt as modifyAlpha, qn as noop, rn as create, sr as __extends, tr as trim$1, un as translate, v as encodeHTML, vn as createHashMap, wn as extend, y as transformLocalCoord, yn as curry$1 } from "./graphic.js";
2
- import { $n as setLabelStyle, $r as enableHoverEmphasis, $t as convertToColorString, Ai as queryReferringComponents, An as parseDataValue, At as getPaddingFromTooltipModel, Bn as SERIES_LAYOUT_BY_COLUMN, Ci as makeInner, Cn as simpleCoordSysInjectionProvider, Cr as retrieveZInfo, Ct as normalizeSymbolSize, D as AxisModelCommonMixin, Di as parseFinder$1, Dr as transformDirection, Dt as TooltipMarkupStyleCreator, Ei as normalizeToArray, Fr as updateProps$1, Ft as DataFormatMixin, Gi as parseDate, Gn as Model, Gr as Ring, Hr as Line, Ht as copyLayoutParams, Ii as getPixelPrecision, It as normalizeTooltipFormatResult, Jr as Circle, Jt as mergeLayoutParam, Ki as parsePercent$1, Kr as Sector, Kt as getLayoutParams, Li as getPrecision, Lt as getDecalFromPalette, Mt as tokens, Ni as asc$2, Nt as SourceManager, O as use, Oi as preParseFinder, Ot as buildTooltipMarkup, Pt as disableTransformOptionMerge, Rt as ComponentModel, S as OrdinalScale, Si as isNameSpecified, St as normalizeSymbolOffset, Ti as mappingToExists, Ur as Polyline, Ut as createBoxLayoutReference, V as registerAction, Vi as linearMap$2, Vt as box, Wn as DataDiffer, Wr as Polygon, Xn as getFont, Xt as sizeCalculable, Yn as createTextStyle, Yt as positionElement, Zi as reformIntervals, Zn as getLabelStatesModels, _i as defaultEmphasis, _n as isDimensionStacked, _r as linePolygonIntersect, a as Axis, ai as leaveEmphasis, an as toCamelCase, at as findEventDispatcher, b as TimeScale, br as mergePath, c as createScaleByModel$1, cn as format, ct as setItemVisualFromData, di as getECData, dn as getLocaleModel, fr as getShapeClass, ft as clear$1, gi as convertOptionIdName, gn as getStackedDimension, hi as compressBatches, hr as groupTransition, i as contain, ii as leaveBlur, in as normalizeCssArray, it as createOrUpdatePatternFromDecal, ji as throwError, ki as queryDataIndex, kr as traverseUpdateZ, kt as createTooltipMarkup, l as getAxisRawValue, li as setStatesStylesFromModel, lr as expandOrShrinkRect, lt as ComponentView, m as niceScaleExtent, mi as SINGLE_REFERRING, mn as inheritDefaultOption, mr as graphic_exports, ni as enterEmphasis, nn as formatTplSimple, oi as setAsHighDownDispatcher, on as windowOpen, or as createIcon, ot as getItemVisualFromData, pi as MULTIPLE_REFERRING, pn as getUID, pr as getTransform, pt as createOrUpdate, qt as getLayoutRect, rr as applyTransform, st as getVisualFromData, ti as enterBlur, tn as formatTpl, u as getDataDimensionsOnAxis, ui as toggleHoverEmphasis, ut as registerInternalOptionCreator, v as unionAxisExtentFromData, vi as getDataItemValue, wi as makeInternalComponentId, wn as SeriesData, wr as setTooltipConfig, wt as symbolBuildProxies, x as IntervalScale, xn as injectCoordSysByOption, xt as createSymbol, y as ensureScaleRawExtentInfo, yi as getTooltipRenderMode, zr as LinearGradient, zt as LOCATION_PARAMS } from "./parseGeoJson.js";
3
- import { A as AxisView, B as SymbolDraw, D as RoamController, F as AxisBuilder, I as axisModelCreator, M as getAxisInfo$1, N as makeKey, O as install$13, P as layout, a as isTransitionAll, d as makeRectIsTargetByCursor, f as makeRectPanelClipPath, h as LineDraw, i as applyUpdateTransition, j as collect, k as install$27, l as isEC4CompatibleStyle, m as sliderMove, n as stopPreviousKeyframeAnimationAndRestore, o as updateLeaveTo, p as BrushController, r as applyLeaveTransition, s as convertFromEC4CompatibleStyle, t as applyKeyframeAnimation, u as makeLinearBrushOtherExtent, v as VisualMapping, y as install$5, z as isCoordinateSystemType } from "./customGraphicKeyframeAnimation.js";
4
- import { t as install$28 } from "./charts.js";
5
-
6
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/axisPointer/BaseAxisPointer.js
7
- /**
8
- * AUTO-GENERATED FILE. DO NOT MODIFY.
9
- */
10
-
11
- function updateProps(animationModel, moveAnimation, el, props) {
12
- if (!propsEqual(inner$11(el).lastProp, props)) {
13
- inner$11(el).lastProp = props;
14
- moveAnimation ? updateProps$1(el, props, animationModel) : (el.stopAnimation(), el.attr(props));
15
- }
16
- }
17
- function propsEqual(lastProps, newProps) {
18
- if (isObject(lastProps) && isObject(newProps)) {
19
- var equals_1 = true;
20
- each$9(newProps, function (item, key) {
21
- equals_1 = equals_1 && propsEqual(lastProps[key], item);
22
- });
23
- return !!equals_1;
24
- } else return lastProps === newProps;
25
- }
26
- function updateLabelShowHide(labelEl, axisPointerModel) {
27
- labelEl[axisPointerModel.get(["label", "show"]) ? "show" : "hide"]();
28
- }
29
- function getHandleTransProps(trans) {
30
- return {
31
- x: trans.x || 0,
32
- y: trans.y || 0,
33
- rotation: trans.rotation || 0
34
- };
35
- }
36
- function updateMandatoryProps(group, axisPointerModel, silent) {
37
- var z = axisPointerModel.get("z");
38
- var zlevel = axisPointerModel.get("zlevel");
39
- group && group.traverse(function (el) {
40
- if (el.type !== "group") {
41
- z != null && (el.z = z);
42
- zlevel != null && (el.zlevel = zlevel);
43
- el.silent = silent;
44
- }
45
- });
46
- }
47
-
48
- //#endregion
49
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/axisPointer/viewHelper.js
50
- /**
51
- * AUTO-GENERATED FILE. DO NOT MODIFY.
52
- */
53
- function buildElStyle(axisPointerModel) {
54
- var axisPointerType = axisPointerModel.get("type");
55
- var styleModel = axisPointerModel.getModel(axisPointerType + "Style");
56
- var style;
57
- if (axisPointerType === "line") {
58
- style = styleModel.getLineStyle();
59
- style.fill = null;
60
- } else if (axisPointerType === "shadow") {
61
- style = styleModel.getAreaStyle();
62
- style.stroke = null;
63
- }
64
- return style;
65
- }
66
- /**
67
- * @param {Function} labelPos {align, verticalAlign, position}
68
- */
69
- function buildLabelElOption(elOption, axisModel, axisPointerModel, api, labelPos) {
70
- var text = getValueLabel(axisPointerModel.get("value"), axisModel.axis, axisModel.ecModel, axisPointerModel.get("seriesDataIndices"), {
71
- precision: axisPointerModel.get(["label", "precision"]),
72
- formatter: axisPointerModel.get(["label", "formatter"])
73
- });
74
- var labelModel = axisPointerModel.getModel("label");
75
- var paddings = normalizeCssArray(labelModel.get("padding") || 0);
76
- var font = labelModel.getFont();
77
- var textRect = getBoundingRect(text, font);
78
- var position = labelPos.position;
79
- var width = textRect.width + paddings[1] + paddings[3];
80
- var height = textRect.height + paddings[0] + paddings[2];
81
- var align = labelPos.align;
82
- align === "right" && (position[0] -= width);
83
- align === "center" && (position[0] -= width / 2);
84
- var verticalAlign = labelPos.verticalAlign;
85
- verticalAlign === "bottom" && (position[1] -= height);
86
- verticalAlign === "middle" && (position[1] -= height / 2);
87
- confineInContainer(position, width, height, api);
88
- var bgColor = labelModel.get("backgroundColor");
89
- if (!bgColor || bgColor === "auto") bgColor = axisModel.get(["axisLine", "lineStyle", "color"]);
90
- elOption.label = {
91
- x: position[0],
92
- y: position[1],
93
- style: createTextStyle(labelModel, {
94
- text,
95
- font,
96
- fill: labelModel.getTextColor(),
97
- padding: paddings,
98
- backgroundColor: bgColor
99
- }),
100
- z2: 10
101
- };
102
- }
103
- function confineInContainer(position, width, height, api) {
104
- var viewWidth = api.getWidth();
105
- var viewHeight = api.getHeight();
106
- position[0] = Math.min(position[0] + width, viewWidth) - width;
107
- position[1] = Math.min(position[1] + height, viewHeight) - height;
108
- position[0] = Math.max(position[0], 0);
109
- position[1] = Math.max(position[1], 0);
110
- }
111
- function getValueLabel(value, axis, ecModel, seriesDataIndices, opt) {
112
- value = axis.scale.parse(value);
113
- var text = axis.scale.getLabel({
114
- value
115
- }, {
116
- precision: opt.precision
117
- });
118
- var formatter = opt.formatter;
119
- if (formatter) {
120
- var params_1 = {
121
- value: getAxisRawValue(axis, {
122
- value
123
- }),
124
- axisDimension: axis.dim,
125
- axisIndex: axis.index,
126
- seriesData: []
127
- };
128
- each$9(seriesDataIndices, function (idxItem) {
129
- var series = ecModel.getSeriesByIndex(idxItem.seriesIndex);
130
- var dataIndex = idxItem.dataIndexInside;
131
- var dataParams = series && series.getDataParams(dataIndex);
132
- dataParams && params_1.seriesData.push(dataParams);
133
- });
134
- if (isString(formatter)) text = formatter.replace("{value}", text);else if (isFunction(formatter)) text = formatter(params_1);
135
- }
136
- return text;
137
- }
138
- function getTransformedPosition(axis, value, layoutInfo) {
139
- var transform = create();
140
- rotate(transform, transform, layoutInfo.rotation);
141
- translate(transform, transform, layoutInfo.position);
142
- return applyTransform([axis.dataToCoord(value), (layoutInfo.labelOffset || 0) + (layoutInfo.labelDirection || 1) * (layoutInfo.labelMargin || 0)], transform);
143
- }
144
- function buildCartesianSingleLabelElOption(value, elOption, layoutInfo, axisModel, axisPointerModel, api) {
145
- var textLayout = AxisBuilder.innerTextLayout(layoutInfo.rotation, 0, layoutInfo.labelDirection);
146
- layoutInfo.labelMargin = axisPointerModel.get(["label", "margin"]);
147
- buildLabelElOption(elOption, axisModel, axisPointerModel, api, {
148
- position: getTransformedPosition(axisModel.axis, value, layoutInfo),
149
- align: textLayout.textAlign,
150
- verticalAlign: textLayout.textVerticalAlign
151
- });
152
- }
153
- function makeLineShape(p1, p2, xDimIndex) {
154
- xDimIndex = xDimIndex || 0;
155
- return {
156
- x1: p1[xDimIndex],
157
- y1: p1[1 - xDimIndex],
158
- x2: p2[xDimIndex],
159
- y2: p2[1 - xDimIndex]
160
- };
161
- }
162
- function makeRectShape(xy, wh, xDimIndex) {
163
- xDimIndex = xDimIndex || 0;
164
- return {
165
- x: xy[xDimIndex],
166
- y: xy[1 - xDimIndex],
167
- width: wh[xDimIndex],
168
- height: wh[1 - xDimIndex]
169
- };
170
- }
171
- function makeSectorShape(cx, cy, r0, r, startAngle, endAngle) {
172
- return {
173
- cx,
174
- cy,
175
- r0,
176
- r,
177
- startAngle,
178
- endAngle,
179
- clockwise: true
180
- };
181
- }
182
-
183
- //#endregion
184
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/axisPointer/CartesianAxisPointer.js
185
- /**
186
- * AUTO-GENERATED FILE. DO NOT MODIFY.
187
- */
188
-
189
- function getCartesian(grid, axis) {
190
- var opt = {};
191
- opt[axis.dim + "AxisIndex"] = axis.index;
192
- return grid.getCartesian(opt);
193
- }
194
- function getAxisDimIndex(axis) {
195
- return axis.dim === "x" ? 0 : 1;
196
- }
197
-
198
- //#endregion
199
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/axisPointer/AxisPointerModel.js
200
- /**
201
- * AUTO-GENERATED FILE. DO NOT MODIFY.
202
- */
203
-
204
- /**
205
- * @param {string} key
206
- * @param {module:echarts/ExtensionAPI} api
207
- * @param {Function} handler
208
- * param: {string} currTrigger
209
- * param: {Array.<number>} point
210
- */
211
- function register(key, api, handler) {
212
- if (env.node) return;
213
- var zr = api.getZr();
214
- inner$10(zr).records || (inner$10(zr).records = {});
215
- initGlobalListeners(zr, api);
216
- var record = inner$10(zr).records[key] || (inner$10(zr).records[key] = {});
217
- record.handler = handler;
218
- }
219
- function initGlobalListeners(zr, api) {
220
- if (inner$10(zr).initialized) return;
221
- inner$10(zr).initialized = true;
222
- useHandler("click", curry$1(doEnter, "click"));
223
- useHandler("mousemove", curry$1(doEnter, "mousemove"));
224
- useHandler("globalout", onLeave);
225
- function useHandler(eventType, cb) {
226
- zr.on(eventType, function (e) {
227
- var dis = makeDispatchAction$1(api);
228
- each$8(inner$10(zr).records, function (record) {
229
- record && cb(record, e, dis.dispatchAction);
230
- });
231
- dispatchTooltipFinally(dis.pendings, api);
232
- });
233
- }
234
- }
235
- function dispatchTooltipFinally(pendings, api) {
236
- var showLen = pendings.showTip.length;
237
- var hideLen = pendings.hideTip.length;
238
- var actuallyPayload;
239
- if (showLen) actuallyPayload = pendings.showTip[showLen - 1];else if (hideLen) actuallyPayload = pendings.hideTip[hideLen - 1];
240
- if (actuallyPayload) {
241
- actuallyPayload.dispatchAction = null;
242
- api.dispatchAction(actuallyPayload);
243
- }
244
- }
245
- function onLeave(record, e, dispatchAction) {
246
- record.handler("leave", null, dispatchAction);
247
- }
248
- function doEnter(currTrigger, record, e, dispatchAction) {
249
- record.handler(currTrigger, e, dispatchAction);
250
- }
251
- function makeDispatchAction$1(api) {
252
- var pendings = {
253
- showTip: [],
254
- hideTip: []
255
- };
256
- var dispatchAction = function (payload) {
257
- var pendingList = pendings[payload.type];
258
- if (pendingList) pendingList.push(payload);else {
259
- payload.dispatchAction = dispatchAction;
260
- api.dispatchAction(payload);
261
- }
262
- };
263
- return {
264
- dispatchAction,
265
- pendings
266
- };
267
- }
268
- function unregister(key, api) {
269
- if (env.node) return;
270
- var zr = api.getZr();
271
- if ((inner$10(zr).records || {})[key]) inner$10(zr).records[key] = null;
272
- }
273
-
274
- //#endregion
275
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/axisPointer/AxisPointerView.js
276
- /**
277
- * AUTO-GENERATED FILE. DO NOT MODIFY.
278
- */
279
-
280
- //#endregion
281
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/axisPointer/findPointFromSeries.js
282
- /**
283
- * AUTO-GENERATED FILE. DO NOT MODIFY.
284
- */
285
- /**
286
- * @param finder contains {seriesIndex, dataIndex, dataIndexInside}
287
- * @param ecModel
288
- * @return {point: [x, y], el: ...} point Will not be null.
289
- */
290
- function findPointFromSeries(finder, ecModel) {
291
- var point = [];
292
- var seriesIndex = finder.seriesIndex;
293
- var seriesModel;
294
- if (seriesIndex == null || !(seriesModel = ecModel.getSeriesByIndex(seriesIndex))) return {
295
- point: []
296
- };
297
- var data = seriesModel.getData();
298
- var dataIndex = queryDataIndex(data, finder);
299
- if (dataIndex == null || dataIndex < 0 || isArray$1(dataIndex)) return {
300
- point: []
301
- };
302
- var el = data.getItemGraphicEl(dataIndex);
303
- var coordSys = seriesModel.coordinateSystem;
304
- if (seriesModel.getTooltipPosition) point = seriesModel.getTooltipPosition(dataIndex) || [];else if (coordSys && coordSys.dataToPoint) {
305
- if (finder.isStacked) {
306
- var baseAxis = coordSys.getBaseAxis();
307
- var valueAxisDim = coordSys.getOtherAxis(baseAxis).dim;
308
- var baseAxisDim = baseAxis.dim;
309
- var baseDataOffset = valueAxisDim === "x" || valueAxisDim === "radius" ? 1 : 0;
310
- var baseDim = data.mapDimension(baseAxisDim);
311
- var stackedData = [];
312
- stackedData[baseDataOffset] = data.get(baseDim, dataIndex);
313
- stackedData[1 - baseDataOffset] = data.get(data.getCalculationInfo("stackResultDimension"), dataIndex);
314
- point = coordSys.dataToPoint(stackedData) || [];
315
- } else point = coordSys.dataToPoint(data.getValues(map(coordSys.dimensions, function (dim) {
316
- return data.mapDimension(dim);
317
- }), dataIndex)) || [];
318
- } else if (el) {
319
- var rect = el.getBoundingRect().clone();
320
- rect.applyTransform(el.transform);
321
- point = [rect.x + rect.width / 2, rect.y + rect.height / 2];
322
- }
323
- return {
324
- point,
325
- el
326
- };
327
- }
328
-
329
- //#endregion
330
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/axisPointer/axisTrigger.js
331
- /**
332
- * AUTO-GENERATED FILE. DO NOT MODIFY.
333
- */
334
-
335
- /**
336
- * Basic logic: check all axis, if they do not demand show/highlight,
337
- * then hide/downplay them.
338
- *
339
- * @return content of event obj for echarts.connect.
340
- */
341
- function axisTrigger(payload, ecModel, api) {
342
- var currTrigger = payload.currTrigger;
343
- var point = [payload.x, payload.y];
344
- var finder = payload;
345
- var dispatchAction = payload.dispatchAction || bind$1(api.dispatchAction, api);
346
- var coordSysAxesInfo = ecModel.getComponent("axisPointer").coordSysAxesInfo;
347
- if (!coordSysAxesInfo) return;
348
- if (illegalPoint(point)) point = findPointFromSeries({
349
- seriesIndex: finder.seriesIndex,
350
- dataIndex: finder.dataIndex
351
- }, ecModel).point;
352
- var isIllegalPoint = illegalPoint(point);
353
- var inputAxesInfo = finder.axesInfo;
354
- var axesInfo = coordSysAxesInfo.axesInfo;
355
- var shouldHide = currTrigger === "leave" || illegalPoint(point);
356
- var outputPayload = {};
357
- var showValueMap = {};
358
- var dataByCoordSys = {
359
- list: [],
360
- map: {}
361
- };
362
- var updaters = {
363
- showPointer: curry$1(showPointer, showValueMap),
364
- showTooltip: curry$1(showTooltip, dataByCoordSys)
365
- };
366
- each$9(coordSysAxesInfo.coordSysMap, function (coordSys, coordSysKey) {
367
- var coordSysContainsPoint = isIllegalPoint || coordSys.containPoint(point);
368
- each$9(coordSysAxesInfo.coordSysAxesInfo[coordSysKey], function (axisInfo, key) {
369
- var axis = axisInfo.axis;
370
- var inputAxisInfo = findInputAxisInfo(inputAxesInfo, axisInfo);
371
- if (!shouldHide && coordSysContainsPoint && (!inputAxesInfo || inputAxisInfo)) {
372
- var val = inputAxisInfo && inputAxisInfo.value;
373
- if (val == null && !isIllegalPoint) val = axis.pointToData(point);
374
- val != null && processOnAxis(axisInfo, val, updaters, false, outputPayload);
375
- }
376
- });
377
- });
378
- var linkTriggers = {};
379
- each$9(axesInfo, function (tarAxisInfo, tarKey) {
380
- var linkGroup = tarAxisInfo.linkGroup;
381
- if (linkGroup && !showValueMap[tarKey]) each$9(linkGroup.axesInfo, function (srcAxisInfo, srcKey) {
382
- var srcValItem = showValueMap[srcKey];
383
- if (srcAxisInfo !== tarAxisInfo && srcValItem) {
384
- var val = srcValItem.value;
385
- linkGroup.mapper && (val = tarAxisInfo.axis.scale.parse(linkGroup.mapper(val, makeMapperParam(srcAxisInfo), makeMapperParam(tarAxisInfo))));
386
- linkTriggers[tarAxisInfo.key] = val;
387
- }
388
- });
389
- });
390
- each$9(linkTriggers, function (val, tarKey) {
391
- processOnAxis(axesInfo[tarKey], val, updaters, true, outputPayload);
392
- });
393
- updateModelActually(showValueMap, axesInfo, outputPayload);
394
- dispatchTooltipActually(dataByCoordSys, point, payload, dispatchAction);
395
- dispatchHighDownActually(axesInfo, dispatchAction, api);
396
- return outputPayload;
397
- }
398
- function processOnAxis(axisInfo, newValue, updaters, noSnap, outputFinder) {
399
- var axis = axisInfo.axis;
400
- if (axis.scale.isBlank() || !axis.containData(newValue)) return;
401
- if (!axisInfo.involveSeries) {
402
- updaters.showPointer(axisInfo, newValue);
403
- return;
404
- }
405
- var payloadInfo = buildPayloadsBySeries(newValue, axisInfo);
406
- var payloadBatch = payloadInfo.payloadBatch;
407
- var snapToValue = payloadInfo.snapToValue;
408
- if (payloadBatch[0] && outputFinder.seriesIndex == null) extend(outputFinder, payloadBatch[0]);
409
- if (!noSnap && axisInfo.snap) {
410
- if (axis.containData(snapToValue) && snapToValue != null) newValue = snapToValue;
411
- }
412
- updaters.showPointer(axisInfo, newValue, payloadBatch);
413
- updaters.showTooltip(axisInfo, payloadInfo, snapToValue);
414
- }
415
- function buildPayloadsBySeries(value, axisInfo) {
416
- var axis = axisInfo.axis;
417
- var dim = axis.dim;
418
- var snapToValue = value;
419
- var payloadBatch = [];
420
- var minDist = Number.MAX_VALUE;
421
- var minDiff = -1;
422
- each$9(axisInfo.seriesModels, function (series, idx) {
423
- var dataDim = series.getData().mapDimensionsAll(dim);
424
- var seriesNestestValue;
425
- var dataIndices;
426
- if (series.getAxisTooltipData) {
427
- var result = series.getAxisTooltipData(dataDim, value, axis);
428
- dataIndices = result.dataIndices;
429
- seriesNestestValue = result.nestestValue;
430
- } else {
431
- dataIndices = series.indicesOfNearest(dim, dataDim[0], value, axis.type === "category" ? .5 : null);
432
- if (!dataIndices.length) return;
433
- seriesNestestValue = series.getData().get(dataDim[0], dataIndices[0]);
434
- }
435
- if (seriesNestestValue == null || !isFinite(seriesNestestValue)) return;
436
- var diff = value - seriesNestestValue;
437
- var dist = Math.abs(diff);
438
- if (dist <= minDist) {
439
- if (dist < minDist || diff >= 0 && minDiff < 0) {
440
- minDist = dist;
441
- minDiff = diff;
442
- snapToValue = seriesNestestValue;
443
- payloadBatch.length = 0;
444
- }
445
- each$9(dataIndices, function (dataIndex) {
446
- payloadBatch.push({
447
- seriesIndex: series.seriesIndex,
448
- dataIndexInside: dataIndex,
449
- dataIndex: series.getData().getRawIndex(dataIndex)
450
- });
451
- });
452
- }
453
- });
454
- return {
455
- payloadBatch,
456
- snapToValue
457
- };
458
- }
459
- function showPointer(showValueMap, axisInfo, value, payloadBatch) {
460
- showValueMap[axisInfo.key] = {
461
- value,
462
- payloadBatch
463
- };
464
- }
465
- function showTooltip(dataByCoordSys, axisInfo, payloadInfo, value) {
466
- var payloadBatch = payloadInfo.payloadBatch;
467
- var axis = axisInfo.axis;
468
- var axisModel = axis.model;
469
- var axisPointerModel = axisInfo.axisPointerModel;
470
- if (!axisInfo.triggerTooltip || !payloadBatch.length) return;
471
- var coordSysModel = axisInfo.coordSys.model;
472
- var coordSysKey = makeKey(coordSysModel);
473
- var coordSysItem = dataByCoordSys.map[coordSysKey];
474
- if (!coordSysItem) {
475
- coordSysItem = dataByCoordSys.map[coordSysKey] = {
476
- coordSysId: coordSysModel.id,
477
- coordSysIndex: coordSysModel.componentIndex,
478
- coordSysType: coordSysModel.type,
479
- coordSysMainType: coordSysModel.mainType,
480
- dataByAxis: []
481
- };
482
- dataByCoordSys.list.push(coordSysItem);
483
- }
484
- coordSysItem.dataByAxis.push({
485
- axisDim: axis.dim,
486
- axisIndex: axisModel.componentIndex,
487
- axisType: axisModel.type,
488
- axisId: axisModel.id,
489
- value,
490
- valueLabelOpt: {
491
- precision: axisPointerModel.get(["label", "precision"]),
492
- formatter: axisPointerModel.get(["label", "formatter"])
493
- },
494
- seriesDataIndices: payloadBatch.slice()
495
- });
496
- }
497
- function updateModelActually(showValueMap, axesInfo, outputPayload) {
498
- var outputAxesInfo = outputPayload.axesInfo = [];
499
- each$9(axesInfo, function (axisInfo, key) {
500
- var option = axisInfo.axisPointerModel.option;
501
- var valItem = showValueMap[key];
502
- if (valItem) {
503
- !axisInfo.useHandle && (option.status = "show");
504
- option.value = valItem.value;
505
- option.seriesDataIndices = (valItem.payloadBatch || []).slice();
506
- } else !axisInfo.useHandle && (option.status = "hide");
507
- option.status === "show" && outputAxesInfo.push({
508
- axisDim: axisInfo.axis.dim,
509
- axisIndex: axisInfo.axis.model.componentIndex,
510
- value: option.value
511
- });
512
- });
513
- }
514
- function dispatchTooltipActually(dataByCoordSys, point, payload, dispatchAction) {
515
- if (illegalPoint(point) || !dataByCoordSys.list.length) {
516
- dispatchAction({
517
- type: "hideTip"
518
- });
519
- return;
520
- }
521
- var sampleItem = ((dataByCoordSys.list[0].dataByAxis[0] || {}).seriesDataIndices || [])[0] || {};
522
- dispatchAction({
523
- type: "showTip",
524
- escapeConnect: true,
525
- x: point[0],
526
- y: point[1],
527
- tooltipOption: payload.tooltipOption,
528
- position: payload.position,
529
- dataIndexInside: sampleItem.dataIndexInside,
530
- dataIndex: sampleItem.dataIndex,
531
- seriesIndex: sampleItem.seriesIndex,
532
- dataByCoordSys: dataByCoordSys.list
533
- });
534
- }
535
- function dispatchHighDownActually(axesInfo, dispatchAction, api) {
536
- var zr = api.getZr();
537
- var highDownKey = "axisPointerLastHighlights";
538
- var lastHighlights = inner$9(zr)[highDownKey] || {};
539
- var newHighlights = inner$9(zr)[highDownKey] = {};
540
- each$9(axesInfo, function (axisInfo, key) {
541
- var option = axisInfo.axisPointerModel.option;
542
- option.status === "show" && axisInfo.triggerEmphasis && each$9(option.seriesDataIndices, function (batchItem) {
543
- var key = batchItem.seriesIndex + " | " + batchItem.dataIndex;
544
- newHighlights[key] = batchItem;
545
- });
546
- });
547
- var toHighlight = [];
548
- var toDownplay = [];
549
- each$9(lastHighlights, function (batchItem, key) {
550
- !newHighlights[key] && toDownplay.push(batchItem);
551
- });
552
- each$9(newHighlights, function (batchItem, key) {
553
- !lastHighlights[key] && toHighlight.push(batchItem);
554
- });
555
- toDownplay.length && api.dispatchAction({
556
- type: "downplay",
557
- escapeConnect: true,
558
- notBlur: true,
559
- batch: toDownplay
560
- });
561
- toHighlight.length && api.dispatchAction({
562
- type: "highlight",
563
- escapeConnect: true,
564
- notBlur: true,
565
- batch: toHighlight
566
- });
567
- }
568
- function findInputAxisInfo(inputAxesInfo, axisInfo) {
569
- for (var i = 0; i < (inputAxesInfo || []).length; i++) {
570
- var inputAxisInfo = inputAxesInfo[i];
571
- if (axisInfo.axis.dim === inputAxisInfo.axisDim && axisInfo.axis.model.componentIndex === inputAxisInfo.axisIndex) return inputAxisInfo;
572
- }
573
- }
574
- function makeMapperParam(axisInfo) {
575
- var axisModel = axisInfo.axis.model;
576
- var item = {};
577
- var dim = item.axisDim = axisInfo.axis.dim;
578
- item.axisIndex = item[dim + "AxisIndex"] = axisModel.componentIndex;
579
- item.axisName = item[dim + "AxisName"] = axisModel.name;
580
- item.axisId = item[dim + "AxisId"] = axisModel.id;
581
- return item;
582
- }
583
- function illegalPoint(point) {
584
- return !point || point[0] == null || isNaN(point[0]) || point[1] == null || isNaN(point[1]);
585
- }
586
-
587
- //#endregion
588
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/axisPointer/install.js
589
- /**
590
- * AUTO-GENERATED FILE. DO NOT MODIFY.
591
- */
592
- function install$26(registers) {
593
- AxisView.registerAxisPointerClass("CartesianAxisPointer", CartesianAxisPointer);
594
- registers.registerComponentModel(AxisPointerModel);
595
- registers.registerComponentView(AxisPointerView);
596
- registers.registerPreprocessor(function (option) {
597
- if (option) {
598
- (!option.axisPointer || option.axisPointer.length === 0) && (option.axisPointer = {});
599
- var link = option.axisPointer.link;
600
- if (link && !isArray$1(link)) option.axisPointer.link = [link];
601
- }
602
- });
603
- registers.registerProcessor(registers.PRIORITY.PROCESSOR.STATISTIC, function (ecModel, api) {
604
- ecModel.getComponent("axisPointer").coordSysAxesInfo = collect(ecModel, api);
605
- });
606
- registers.registerAction({
607
- type: "updateAxisPointer",
608
- event: "updateAxisPointer",
609
- update: ":updateAxisPointer"
610
- }, axisTrigger);
611
- }
612
-
613
- //#endregion
614
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/grid/install.js
615
- /**
616
- * AUTO-GENERATED FILE. DO NOT MODIFY.
617
- */
618
- function install$7(registers) {
619
- use(install$27);
620
- use(install$26);
621
- }
622
-
623
- //#endregion
624
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/axisPointer/PolarAxisPointer.js
625
- /**
626
- * AUTO-GENERATED FILE. DO NOT MODIFY.
627
- */
628
-
629
- function getLabelPosition(value, axisModel, axisPointerModel, polar, labelMargin) {
630
- var axis = axisModel.axis;
631
- var coord = axis.dataToCoord(value);
632
- var axisAngle = polar.getAngleAxis().getExtent()[0];
633
- axisAngle = axisAngle / 180 * Math.PI;
634
- var radiusExtent = polar.getRadiusAxis().getExtent();
635
- var position;
636
- var align;
637
- var verticalAlign;
638
- if (axis.dim === "radius") {
639
- var transform = create();
640
- rotate(transform, transform, axisAngle);
641
- translate(transform, transform, [polar.cx, polar.cy]);
642
- position = applyTransform([coord, -labelMargin], transform);
643
- var labelRotation = axisModel.getModel("axisLabel").get("rotate") || 0;
644
- var labelLayout = AxisBuilder.innerTextLayout(axisAngle, labelRotation * Math.PI / 180, -1);
645
- align = labelLayout.textAlign;
646
- verticalAlign = labelLayout.textVerticalAlign;
647
- } else {
648
- var r = radiusExtent[1];
649
- position = polar.coordToPoint([r + labelMargin, coord]);
650
- var cx = polar.cx;
651
- var cy = polar.cy;
652
- align = Math.abs(position[0] - cx) / r < .3 ? "center" : position[0] > cx ? "left" : "right";
653
- verticalAlign = Math.abs(position[1] - cy) / r < .3 ? "middle" : position[1] > cy ? "top" : "bottom";
654
- }
655
- return {
656
- position,
657
- align,
658
- verticalAlign
659
- };
660
- }
661
- function getCoordSys$1(finder) {
662
- var seriesModel = finder.seriesModel;
663
- var polarModel = finder.polarModel;
664
- return polarModel && polarModel.coordinateSystem || seriesModel && seriesModel.coordinateSystem;
665
- }
666
-
667
- //#endregion
668
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/coord/polar/polarCreator.js
669
- /**
670
- * AUTO-GENERATED FILE. DO NOT MODIFY.
671
- */
672
- /**
673
- * Resize method bound to the polar
674
- */
675
- function resizePolar(polar, polarModel, api) {
676
- var center = polarModel.get("center");
677
- var refContainer = createBoxLayoutReference(polarModel, api).refContainer;
678
- polar.cx = parsePercent$1(center[0], refContainer.width) + refContainer.x;
679
- polar.cy = parsePercent$1(center[1], refContainer.height) + refContainer.y;
680
- var radiusAxis = polar.getRadiusAxis();
681
- var size = Math.min(refContainer.width, refContainer.height) / 2;
682
- var radius = polarModel.get("radius");
683
- if (radius == null) radius = [0, "100%"];else if (!isArray$1(radius)) radius = [0, radius];
684
- var parsedRadius = [parsePercent$1(radius[0], size), parsePercent$1(radius[1], size)];
685
- radiusAxis.inverse ? radiusAxis.setExtent(parsedRadius[1], parsedRadius[0]) : radiusAxis.setExtent(parsedRadius[0], parsedRadius[1]);
686
- }
687
- /**
688
- * Update polar
689
- */
690
- function updatePolarScale(ecModel, api) {
691
- var polar = this;
692
- var angleAxis = polar.getAngleAxis();
693
- var radiusAxis = polar.getRadiusAxis();
694
- angleAxis.scale.setExtent(Infinity, -Infinity);
695
- radiusAxis.scale.setExtent(Infinity, -Infinity);
696
- ecModel.eachSeries(function (seriesModel) {
697
- if (seriesModel.coordinateSystem === polar) {
698
- var data_1 = seriesModel.getData();
699
- each$9(getDataDimensionsOnAxis(data_1, "radius"), function (dim) {
700
- radiusAxis.scale.unionExtentFromData(data_1, dim);
701
- });
702
- each$9(getDataDimensionsOnAxis(data_1, "angle"), function (dim) {
703
- angleAxis.scale.unionExtentFromData(data_1, dim);
704
- });
705
- }
706
- });
707
- niceScaleExtent(angleAxis.scale, angleAxis.model);
708
- niceScaleExtent(radiusAxis.scale, radiusAxis.model);
709
- if (angleAxis.type === "category" && !angleAxis.onBand) {
710
- var extent = angleAxis.getExtent();
711
- var diff = 360 / angleAxis.scale.count();
712
- angleAxis.inverse ? extent[1] += diff : extent[1] -= diff;
713
- angleAxis.setExtent(extent[0], extent[1]);
714
- }
715
- }
716
- function isAngleAxisModel(axisModel) {
717
- return axisModel.mainType === "angleAxis";
718
- }
719
- /**
720
- * Set common axis properties
721
- */
722
- function setAxis(axis, axisModel) {
723
- var _a;
724
- axis.type = axisModel.get("type");
725
- axis.scale = createScaleByModel$1(axisModel);
726
- axis.onBand = axisModel.get("boundaryGap") && axis.type === "category";
727
- axis.inverse = axisModel.get("inverse");
728
- if (isAngleAxisModel(axisModel)) {
729
- axis.inverse = axis.inverse !== axisModel.get("clockwise");
730
- var startAngle = axisModel.get("startAngle");
731
- var endAngle = (_a = axisModel.get("endAngle")) !== null && _a !== void 0 ? _a : startAngle + (axis.inverse ? -360 : 360);
732
- axis.setExtent(startAngle, endAngle);
733
- }
734
- axisModel.axis = axis;
735
- axis.model = axisModel;
736
- }
737
- function getAxisLineShape(polar, rExtent, angle) {
738
- rExtent[1] > rExtent[0] && (rExtent = rExtent.slice().reverse());
739
- var start = polar.coordToPoint([rExtent[0], angle]);
740
- var end = polar.coordToPoint([rExtent[1], angle]);
741
- return {
742
- x1: start[0],
743
- y1: start[1],
744
- x2: end[0],
745
- y2: end[1]
746
- };
747
- }
748
- function getRadiusIdx(polar) {
749
- return polar.getRadiusAxis().inverse ? 0 : 1;
750
- }
751
- function fixAngleOverlap(list) {
752
- var firstItem = list[0];
753
- var lastItem = list[list.length - 1];
754
- if (firstItem && lastItem && Math.abs(Math.abs(firstItem.coord - lastItem.coord) - 360) < 1e-4) list.pop();
755
- }
756
- /**
757
- * @inner
758
- */
759
- function layoutAxis(polar, radiusAxisModel, axisAngle) {
760
- return {
761
- position: [polar.cx, polar.cy],
762
- rotation: axisAngle / 180 * Math.PI,
763
- labelDirection: -1,
764
- tickDirection: -1,
765
- nameDirection: 1,
766
- labelRotate: radiusAxisModel.getModel("axisLabel").get("rotate"),
767
- z2: 1
768
- };
769
- }
770
-
771
- //#endregion
772
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/layout/barPolar.js
773
- /**
774
- * AUTO-GENERATED FILE. DO NOT MODIFY.
775
- */
776
- function getSeriesStackId(seriesModel) {
777
- return seriesModel.get("stack") || "__ec_stack_" + seriesModel.seriesIndex;
778
- }
779
- function getAxisKey(polar, axis) {
780
- return axis.dim + polar.model.componentIndex;
781
- }
782
- function barLayoutPolar(seriesType, ecModel, api) {
783
- var lastStackCoords = {};
784
- var barWidthAndOffset = calRadialBar(filter(ecModel.getSeriesByType(seriesType), function (seriesModel) {
785
- return !ecModel.isSeriesFiltered(seriesModel) && seriesModel.coordinateSystem && seriesModel.coordinateSystem.type === "polar";
786
- }));
787
- ecModel.eachSeriesByType(seriesType, function (seriesModel) {
788
- if (seriesModel.coordinateSystem.type !== "polar") return;
789
- var data = seriesModel.getData();
790
- var polar = seriesModel.coordinateSystem;
791
- var baseAxis = polar.getBaseAxis();
792
- var axisKey = getAxisKey(polar, baseAxis);
793
- var stackId = getSeriesStackId(seriesModel);
794
- var columnLayoutInfo = barWidthAndOffset[axisKey][stackId];
795
- var columnOffset = columnLayoutInfo.offset;
796
- var columnWidth = columnLayoutInfo.width;
797
- var valueAxis = polar.getOtherAxis(baseAxis);
798
- var cx = seriesModel.coordinateSystem.cx;
799
- var cy = seriesModel.coordinateSystem.cy;
800
- var barMinHeight = seriesModel.get("barMinHeight") || 0;
801
- var barMinAngle = seriesModel.get("barMinAngle") || 0;
802
- lastStackCoords[stackId] = lastStackCoords[stackId] || [];
803
- var valueDim = data.mapDimension(valueAxis.dim);
804
- var baseDim = data.mapDimension(baseAxis.dim);
805
- var stacked = isDimensionStacked(data, valueDim);
806
- var clampLayout = baseAxis.dim !== "radius" || !seriesModel.get("roundCap", true);
807
- var startValue = valueAxis.model.get("startValue");
808
- var valueAxisStart = valueAxis.dataToCoord(startValue || 0);
809
- for (var idx = 0, len = data.count(); idx < len; idx++) {
810
- var value = data.get(valueDim, idx);
811
- var baseValue = data.get(baseDim, idx);
812
- var sign = value >= 0 ? "p" : "n";
813
- var baseCoord = valueAxisStart;
814
- if (stacked) {
815
- if (!lastStackCoords[stackId][baseValue]) lastStackCoords[stackId][baseValue] = {
816
- p: valueAxisStart,
817
- n: valueAxisStart
818
- };
819
- baseCoord = lastStackCoords[stackId][baseValue][sign];
820
- }
821
- var r0 = void 0;
822
- var r = void 0;
823
- var startAngle = void 0;
824
- var endAngle = void 0;
825
- if (valueAxis.dim === "radius") {
826
- var radiusSpan = valueAxis.dataToCoord(value) - valueAxisStart;
827
- var angle = baseAxis.dataToCoord(baseValue);
828
- if (Math.abs(radiusSpan) < barMinHeight) radiusSpan = (radiusSpan < 0 ? -1 : 1) * barMinHeight;
829
- r0 = baseCoord;
830
- r = baseCoord + radiusSpan;
831
- startAngle = angle - columnOffset;
832
- endAngle = startAngle - columnWidth;
833
- stacked && (lastStackCoords[stackId][baseValue][sign] = r);
834
- } else {
835
- var angleSpan = valueAxis.dataToCoord(value, clampLayout) - valueAxisStart;
836
- var radius = baseAxis.dataToCoord(baseValue);
837
- if (Math.abs(angleSpan) < barMinAngle) angleSpan = (angleSpan < 0 ? -1 : 1) * barMinAngle;
838
- r0 = radius + columnOffset;
839
- r = r0 + columnWidth;
840
- startAngle = baseCoord;
841
- endAngle = baseCoord + angleSpan;
842
- stacked && (lastStackCoords[stackId][baseValue][sign] = endAngle);
843
- }
844
- data.setItemLayout(idx, {
845
- cx,
846
- cy,
847
- r0,
848
- r,
849
- startAngle: -startAngle * Math.PI / 180,
850
- endAngle: -endAngle * Math.PI / 180,
851
- clockwise: startAngle >= endAngle
852
- });
853
- }
854
- });
855
- }
856
- /**
857
- * Calculate bar width and offset for radial bar charts
858
- */
859
- function calRadialBar(barSeries) {
860
- var columnsMap = {};
861
- each$9(barSeries, function (seriesModel, idx) {
862
- var data = seriesModel.getData();
863
- var polar = seriesModel.coordinateSystem;
864
- var baseAxis = polar.getBaseAxis();
865
- var axisKey = getAxisKey(polar, baseAxis);
866
- var axisExtent = baseAxis.getExtent();
867
- var bandWidth = baseAxis.type === "category" ? baseAxis.getBandWidth() : Math.abs(axisExtent[1] - axisExtent[0]) / data.count();
868
- var columnsOnAxis = columnsMap[axisKey] || {
869
- bandWidth,
870
- remainedWidth: bandWidth,
871
- autoWidthCount: 0,
872
- categoryGap: "20%",
873
- gap: "30%",
874
- stacks: {}
875
- };
876
- var stacks = columnsOnAxis.stacks;
877
- columnsMap[axisKey] = columnsOnAxis;
878
- var stackId = getSeriesStackId(seriesModel);
879
- if (!stacks[stackId]) columnsOnAxis.autoWidthCount++;
880
- stacks[stackId] = stacks[stackId] || {
881
- width: 0,
882
- maxWidth: 0
883
- };
884
- var barWidth = parsePercent$1(seriesModel.get("barWidth"), bandWidth);
885
- var barMaxWidth = parsePercent$1(seriesModel.get("barMaxWidth"), bandWidth);
886
- var barGap = seriesModel.get("barGap");
887
- var barCategoryGap = seriesModel.get("barCategoryGap");
888
- if (barWidth && !stacks[stackId].width) {
889
- barWidth = Math.min(columnsOnAxis.remainedWidth, barWidth);
890
- stacks[stackId].width = barWidth;
891
- columnsOnAxis.remainedWidth -= barWidth;
892
- }
893
- barMaxWidth && (stacks[stackId].maxWidth = barMaxWidth);
894
- barGap != null && (columnsOnAxis.gap = barGap);
895
- barCategoryGap != null && (columnsOnAxis.categoryGap = barCategoryGap);
896
- });
897
- var result = {};
898
- each$9(columnsMap, function (columnsOnAxis, coordSysName) {
899
- result[coordSysName] = {};
900
- var stacks = columnsOnAxis.stacks;
901
- var bandWidth = columnsOnAxis.bandWidth;
902
- var categoryGap = parsePercent$1(columnsOnAxis.categoryGap, bandWidth);
903
- var barGapPercent = parsePercent$1(columnsOnAxis.gap, 1);
904
- var remainedWidth = columnsOnAxis.remainedWidth;
905
- var autoWidthCount = columnsOnAxis.autoWidthCount;
906
- var autoWidth = (remainedWidth - categoryGap) / (autoWidthCount + (autoWidthCount - 1) * barGapPercent);
907
- autoWidth = Math.max(autoWidth, 0);
908
- each$9(stacks, function (column, stack) {
909
- var maxWidth = column.maxWidth;
910
- if (maxWidth && maxWidth < autoWidth) {
911
- maxWidth = Math.min(maxWidth, remainedWidth);
912
- if (column.width) maxWidth = Math.min(maxWidth, column.width);
913
- remainedWidth -= maxWidth;
914
- column.width = maxWidth;
915
- autoWidthCount--;
916
- }
917
- });
918
- autoWidth = (remainedWidth - categoryGap) / (autoWidthCount + (autoWidthCount - 1) * barGapPercent);
919
- autoWidth = Math.max(autoWidth, 0);
920
- var widthSum = 0;
921
- var lastColumn;
922
- each$9(stacks, function (column, idx) {
923
- if (!column.width) column.width = autoWidth;
924
- lastColumn = column;
925
- widthSum += column.width * (1 + barGapPercent);
926
- });
927
- if (lastColumn) widthSum -= lastColumn.width * barGapPercent;
928
- var offset = -widthSum / 2;
929
- each$9(stacks, function (column, stackId) {
930
- result[coordSysName][stackId] = result[coordSysName][stackId] || {
931
- offset,
932
- width: column.width
933
- };
934
- offset += column.width * (1 + barGapPercent);
935
- });
936
- });
937
- return result;
938
- }
939
-
940
- //#endregion
941
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/polar/install.js
942
- /**
943
- * AUTO-GENERATED FILE. DO NOT MODIFY.
944
- */
945
-
946
- function install$12(registers) {
947
- use(install$26);
948
- AxisView.registerAxisPointerClass("PolarAxisPointer", PolarAxisPointer);
949
- registers.registerCoordinateSystem("polar", polarCreator);
950
- registers.registerComponentModel(PolarModel);
951
- registers.registerComponentView(PolarView);
952
- axisModelCreator(registers, "angle", AngleAxisModel, angleAxisExtraOption);
953
- axisModelCreator(registers, "radius", RadiusAxisModel, radiusAxisExtraOption);
954
- registers.registerComponentView(AngleAxisView);
955
- registers.registerComponentView(RadiusAxisView);
956
- registers.registerLayout(curry$1(barLayoutPolar, "bar"));
957
- }
958
-
959
- //#endregion
960
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/coord/calendar/CalendarModel.js
961
- /**
962
- * AUTO-GENERATED FILE. DO NOT MODIFY.
963
- */
964
-
965
- function mergeAndNormalizeLayoutParams$1(target, raw) {
966
- var cellSize = target.cellSize;
967
- var cellSizeArr;
968
- if (!isArray$1(cellSize)) cellSizeArr = target.cellSize = [cellSize, cellSize];else cellSizeArr = cellSize;
969
- if (cellSizeArr.length === 1) cellSizeArr[1] = cellSizeArr[0];
970
- mergeLayoutParam(target, raw, {
971
- type: "box",
972
- ignoreSize: map([0, 1], function (hvIdx) {
973
- if (sizeCalculable(raw, hvIdx)) cellSizeArr[hvIdx] = "auto";
974
- return cellSizeArr[hvIdx] != null && cellSizeArr[hvIdx] !== "auto";
975
- })
976
- });
977
- }
978
-
979
- //#endregion
980
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/calendar/CalendarView.js
981
- /**
982
- * AUTO-GENERATED FILE. DO NOT MODIFY.
983
- */
984
-
985
- function getCoordSys(finder) {
986
- var calendarModel = finder.calendarModel;
987
- var seriesModel = finder.seriesModel;
988
- return calendarModel ? calendarModel.coordinateSystem : seriesModel ? seriesModel.coordinateSystem : null;
989
- }
990
-
991
- //#endregion
992
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/calendar/install.js
993
- /**
994
- * AUTO-GENERATED FILE. DO NOT MODIFY.
995
- */
996
- function install$2(registers) {
997
- registers.registerComponentModel(CalendarModel);
998
- registers.registerComponentView(CalendarView);
999
- registers.registerCoordinateSystem("calendar", Calendar);
1000
- }
1001
-
1002
- //#endregion
1003
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/graphic/GraphicModel.js
1004
- /**
1005
- * AUTO-GENERATED FILE. DO NOT MODIFY.
1006
- */
1007
- function setKeyInfoToNewElOption(resultItem, newElOption) {
1008
- var existElOption = resultItem.existing;
1009
- newElOption.id = resultItem.keyInfo.id;
1010
- !newElOption.type && existElOption && (newElOption.type = existElOption.type);
1011
- if (newElOption.parentId == null) {
1012
- var newElParentOption = newElOption.parentOption;
1013
- if (newElParentOption) newElOption.parentId = newElParentOption.id;else if (existElOption) newElOption.parentId = existElOption.parentId;
1014
- }
1015
- newElOption.parentOption = null;
1016
- }
1017
- function isSetLoc(obj, props) {
1018
- var isSet;
1019
- each$9(props, function (prop) {
1020
- obj[prop] != null && obj[prop] !== "auto" && (isSet = true);
1021
- });
1022
- return isSet;
1023
- }
1024
- function mergeNewElOptionToExist(existList, index, newElOption) {
1025
- var newElOptCopy = extend({}, newElOption);
1026
- var existElOption = existList[index];
1027
- var $action = newElOption.$action || "merge";
1028
- if ($action === "merge") {
1029
- if (existElOption) {
1030
- merge(existElOption, newElOptCopy, true);
1031
- mergeLayoutParam(existElOption, newElOptCopy, {
1032
- ignoreSize: true
1033
- });
1034
- copyLayoutParams(newElOption, existElOption);
1035
- copyTransitionInfo(newElOption, existElOption);
1036
- copyTransitionInfo(newElOption, existElOption, "shape");
1037
- copyTransitionInfo(newElOption, existElOption, "style");
1038
- copyTransitionInfo(newElOption, existElOption, "extra");
1039
- newElOption.clipPath = existElOption.clipPath;
1040
- } else existList[index] = newElOptCopy;
1041
- } else if ($action === "replace") existList[index] = newElOptCopy;else if ($action === "remove") existElOption && (existList[index] = null);
1042
- }
1043
- function copyTransitionInfo(target, source, targetProp) {
1044
- if (targetProp) {
1045
- if (!target[targetProp] && source[targetProp]) target[targetProp] = {};
1046
- target = target[targetProp];
1047
- source = source[targetProp];
1048
- }
1049
- if (!target || !source) return;
1050
- var props = targetProp ? TRANSITION_PROPS_TO_COPY : ROOT_TRANSITION_PROPS_TO_COPY;
1051
- for (var i = 0; i < props.length; i++) {
1052
- var prop = props[i];
1053
- if (target[prop] == null && source[prop] != null) target[prop] = source[prop];
1054
- }
1055
- }
1056
- function setLayoutInfoToExist(existItem, newElOption) {
1057
- if (!existItem) return;
1058
- existItem.hv = newElOption.hv = [isSetLoc(newElOption, ["left", "right"]), isSetLoc(newElOption, ["top", "bottom"])];
1059
- if (existItem.type === "group") {
1060
- var existingGroupOpt = existItem;
1061
- var newGroupOpt = newElOption;
1062
- existingGroupOpt.width ??= newGroupOpt.width = 0;
1063
- existingGroupOpt.height ??= newGroupOpt.height = 0;
1064
- }
1065
- }
1066
- function newEl(graphicType) {
1067
- var el = new (hasOwn(nonShapeGraphicElements, graphicType) ? nonShapeGraphicElements[graphicType] : getShapeClass(graphicType))({});
1068
- inner$7(el).type = graphicType;
1069
- return el;
1070
- }
1071
- function createEl(id, targetElParent, graphicType, elMap) {
1072
- var el = newEl(graphicType);
1073
- targetElParent.add(el);
1074
- elMap.set(id, el);
1075
- inner$7(el).id = id;
1076
- inner$7(el).isNew = true;
1077
- return el;
1078
- }
1079
- function removeEl(elExisting, elOption, elMap, graphicModel) {
1080
- if (elExisting && elExisting.parent) {
1081
- elExisting.type === "group" && elExisting.traverse(function (el) {
1082
- removeEl(el, elOption, elMap, graphicModel);
1083
- });
1084
- applyLeaveTransition(elExisting, elOption, graphicModel);
1085
- elMap.removeKey(inner$7(elExisting).id);
1086
- }
1087
- }
1088
- function updateCommonAttrs(el, elOption, defaultZ, defaultZlevel) {
1089
- if (!el.isGroup) each$9([["cursor", Displayable.prototype.cursor], ["zlevel", defaultZlevel || 0], ["z", defaultZ || 0], ["z2", 0]], function (item) {
1090
- var prop = item[0];
1091
- if (hasOwn(elOption, prop)) el[prop] = retrieve2(elOption[prop], item[1]);else if (el[prop] == null) el[prop] = item[1];
1092
- });
1093
- each$9(keys(elOption), function (key) {
1094
- if (key.indexOf("on") === 0) {
1095
- var val = elOption[key];
1096
- el[key] = isFunction(val) ? val : null;
1097
- }
1098
- });
1099
- if (hasOwn(elOption, "draggable")) el.draggable = elOption.draggable;
1100
- elOption.name != null && (el.name = elOption.name);
1101
- elOption.id != null && (el.id = elOption.id);
1102
- }
1103
- function getCleanedElOption(elOption) {
1104
- elOption = extend({}, elOption);
1105
- each$9(["id", "parentId", "$action", "hv", "bounding", "textContent", "clipPath"].concat(LOCATION_PARAMS), function (name) {
1106
- delete elOption[name];
1107
- });
1108
- return elOption;
1109
- }
1110
- function setEventData(el, graphicModel, elOption) {
1111
- var eventData = getECData(el).eventData;
1112
- if (!el.silent && !el.ignore && !eventData) eventData = getECData(el).eventData = {
1113
- componentType: "graphic",
1114
- componentIndex: graphicModel.componentIndex,
1115
- name: el.name
1116
- };
1117
- if (eventData) eventData.info = elOption.info;
1118
- }
1119
-
1120
- //#endregion
1121
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/graphic/install.js
1122
- /**
1123
- * AUTO-GENERATED FILE. DO NOT MODIFY.
1124
- */
1125
- function install$6(registers) {
1126
- registers.registerComponentModel(GraphicComponentModel);
1127
- registers.registerComponentView(GraphicComponentView);
1128
- registers.registerPreprocessor(function (option) {
1129
- var graphicOption = option.graphic;
1130
- if (isArray$1(graphicOption)) {
1131
- if (!graphicOption[0] || !graphicOption[0].elements) option.graphic = [{
1132
- elements: graphicOption
1133
- }];else option.graphic = [option.graphic[0]];
1134
- } else if (graphicOption && !graphicOption.elements) option.graphic = [{
1135
- elements: [graphicOption]
1136
- }];
1137
- });
1138
- }
1139
-
1140
- //#endregion
1141
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/dataZoom/helper.js
1142
- /**
1143
- * AUTO-GENERATED FILE. DO NOT MODIFY.
1144
- */
1145
-
1146
- function isCoordSupported(seriesModel) {
1147
- return indexOf(SERIES_COORDS, seriesModel.get("coordinateSystem")) >= 0;
1148
- }
1149
- function getAxisMainType(axisDim) {
1150
- return axisDim + "Axis";
1151
- }
1152
- /**
1153
- * If two dataZoomModels has the same axis controlled, we say that they are 'linked'.
1154
- * This function finds all linked dataZoomModels start from the given payload.
1155
- */
1156
- function findEffectedDataZooms(ecModel, payload) {
1157
- var axisRecords = createHashMap();
1158
- var effectedModels = [];
1159
- var effectedModelMap = createHashMap();
1160
- ecModel.eachComponent({
1161
- mainType: "dataZoom",
1162
- query: payload
1163
- }, function (dataZoomModel) {
1164
- if (!effectedModelMap.get(dataZoomModel.uid)) addToEffected(dataZoomModel);
1165
- });
1166
- var foundNewLink;
1167
- do {
1168
- foundNewLink = false;
1169
- ecModel.eachComponent("dataZoom", processSingle);
1170
- } while (foundNewLink);
1171
- function processSingle(dataZoomModel) {
1172
- if (!effectedModelMap.get(dataZoomModel.uid) && isLinked(dataZoomModel)) {
1173
- addToEffected(dataZoomModel);
1174
- foundNewLink = true;
1175
- }
1176
- }
1177
- function addToEffected(dataZoom) {
1178
- effectedModelMap.set(dataZoom.uid, true);
1179
- effectedModels.push(dataZoom);
1180
- markAxisControlled(dataZoom);
1181
- }
1182
- function isLinked(dataZoomModel) {
1183
- var isLink = false;
1184
- dataZoomModel.eachTargetAxis(function (axisDim, axisIndex) {
1185
- var axisIdxArr = axisRecords.get(axisDim);
1186
- if (axisIdxArr && axisIdxArr[axisIndex]) isLink = true;
1187
- });
1188
- return isLink;
1189
- }
1190
- function markAxisControlled(dataZoomModel) {
1191
- dataZoomModel.eachTargetAxis(function (axisDim, axisIndex) {
1192
- (axisRecords.get(axisDim) || axisRecords.set(axisDim, []))[axisIndex] = true;
1193
- });
1194
- }
1195
- return effectedModels;
1196
- }
1197
- /**
1198
- * Find the first target coordinate system.
1199
- * Available after model built.
1200
- *
1201
- * @return Like {
1202
- * grid: [
1203
- * {model: coord0, axisModels: [axis1, axis3], coordIndex: 1},
1204
- * {model: coord1, axisModels: [axis0, axis2], coordIndex: 0},
1205
- * ...
1206
- * ], // cartesians must not be null/undefined.
1207
- * polar: [
1208
- * {model: coord0, axisModels: [axis4], coordIndex: 0},
1209
- * ...
1210
- * ], // polars must not be null/undefined.
1211
- * singleAxis: [
1212
- * {model: coord0, axisModels: [], coordIndex: 0}
1213
- * ]
1214
- * }
1215
- */
1216
- function collectReferCoordSysModelInfo(dataZoomModel) {
1217
- var ecModel = dataZoomModel.ecModel;
1218
- var coordSysInfoWrap = {
1219
- infoList: [],
1220
- infoMap: createHashMap()
1221
- };
1222
- dataZoomModel.eachTargetAxis(function (axisDim, axisIndex) {
1223
- var axisModel = ecModel.getComponent(getAxisMainType(axisDim), axisIndex);
1224
- if (!axisModel) return;
1225
- var coordSysModel = axisModel.getCoordSysModel();
1226
- if (!coordSysModel) return;
1227
- var coordSysUid = coordSysModel.uid;
1228
- var coordSysInfo = coordSysInfoWrap.infoMap.get(coordSysUid);
1229
- if (!coordSysInfo) {
1230
- coordSysInfo = {
1231
- model: coordSysModel,
1232
- axisModels: []
1233
- };
1234
- coordSysInfoWrap.infoList.push(coordSysInfo);
1235
- coordSysInfoWrap.infoMap.set(coordSysUid, coordSysInfo);
1236
- }
1237
- coordSysInfo.axisModels.push(axisModel);
1238
- });
1239
- return coordSysInfoWrap;
1240
- }
1241
-
1242
- //#endregion
1243
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/dataZoom/DataZoomModel.js
1244
- /**
1245
- * AUTO-GENERATED FILE. DO NOT MODIFY.
1246
- */
1247
-
1248
- /**
1249
- * Retrieve those raw params from option, which will be cached separately,
1250
- * because they will be overwritten by normalized/calculated values in the main
1251
- * process.
1252
- */
1253
- function retrieveRawOption(option) {
1254
- var ret = {};
1255
- each$9(["start", "end", "startValue", "endValue", "throttle"], function (name) {
1256
- option.hasOwnProperty(name) && (ret[name] = option[name]);
1257
- });
1258
- return ret;
1259
- }
1260
-
1261
- //#endregion
1262
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/dataZoom/SelectZoomModel.js
1263
- /**
1264
- * AUTO-GENERATED FILE. DO NOT MODIFY.
1265
- */
1266
-
1267
- function calculateDataExtent(axisProxy, axisDim, seriesModels) {
1268
- var dataExtent = [Infinity, -Infinity];
1269
- each$7(seriesModels, function (seriesModel) {
1270
- unionAxisExtentFromData(dataExtent, seriesModel.getData(), axisDim);
1271
- });
1272
- var axisModel = axisProxy.getAxisModel();
1273
- var rawExtentResult = ensureScaleRawExtentInfo(axisModel.axis.scale, axisModel, dataExtent).calculate();
1274
- return [rawExtentResult.min, rawExtentResult.max];
1275
- }
1276
-
1277
- //#endregion
1278
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/dataZoom/dataZoomProcessor.js
1279
- /**
1280
- * AUTO-GENERATED FILE. DO NOT MODIFY.
1281
- */
1282
-
1283
- //#endregion
1284
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/dataZoom/dataZoomAction.js
1285
- /**
1286
- * AUTO-GENERATED FILE. DO NOT MODIFY.
1287
- */
1288
- function installDataZoomAction(registers) {
1289
- registers.registerAction("dataZoom", function (payload, ecModel) {
1290
- each$9(findEffectedDataZooms(ecModel, payload), function (dataZoomModel) {
1291
- dataZoomModel.setRawRange({
1292
- start: payload.start,
1293
- end: payload.end,
1294
- startValue: payload.startValue,
1295
- endValue: payload.endValue
1296
- });
1297
- });
1298
- });
1299
- }
1300
-
1301
- //#endregion
1302
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/dataZoom/installCommon.js
1303
- /**
1304
- * AUTO-GENERATED FILE. DO NOT MODIFY.
1305
- */
1306
-
1307
- function installCommon$1(registers) {
1308
- if (installed$1) return;
1309
- installed$1 = true;
1310
- registers.registerProcessor(registers.PRIORITY.PROCESSOR.FILTER, dataZoomProcessor);
1311
- installDataZoomAction(registers);
1312
- registers.registerSubTypeDefaulter("dataZoom", function () {
1313
- return "slider";
1314
- });
1315
- }
1316
-
1317
- //#endregion
1318
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/dataZoom/installDataZoomSelect.js
1319
- /**
1320
- * AUTO-GENERATED FILE. DO NOT MODIFY.
1321
- */
1322
- function install$25(registers) {
1323
- registers.registerComponentModel(SelectDataZoomModel);
1324
- registers.registerComponentView(SelectDataZoomView);
1325
- installCommon$1(registers);
1326
- }
1327
-
1328
- //#endregion
1329
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/toolbox/featureManager.js
1330
- /**
1331
- * AUTO-GENERATED FILE. DO NOT MODIFY.
1332
- */
1333
-
1334
- function registerFeature(name, ctor) {
1335
- features[name] = ctor;
1336
- }
1337
- function getFeature(name) {
1338
- return features[name];
1339
- }
1340
-
1341
- //#endregion
1342
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/toolbox/ToolboxModel.js
1343
- /**
1344
- * AUTO-GENERATED FILE. DO NOT MODIFY.
1345
- */
1346
-
1347
- //#endregion
1348
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/helper/listComponent.js
1349
- /**
1350
- * AUTO-GENERATED FILE. DO NOT MODIFY.
1351
- */
1352
- function makeBackground(rect, componentModel) {
1353
- var padding = normalizeCssArray(componentModel.get("padding"));
1354
- var style = componentModel.getItemStyle(["color", "opacity"]);
1355
- style.fill = componentModel.get("backgroundColor");
1356
- return new Rect$1({
1357
- shape: {
1358
- x: rect.x - padding[3],
1359
- y: rect.y - padding[0],
1360
- width: rect.width + padding[1] + padding[3],
1361
- height: rect.height + padding[0] + padding[2],
1362
- r: componentModel.get("borderRadius")
1363
- },
1364
- style,
1365
- silent: true,
1366
- z2: -1
1367
- });
1368
- }
1369
-
1370
- //#endregion
1371
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/toolbox/ToolboxView.js
1372
- /**
1373
- * AUTO-GENERATED FILE. DO NOT MODIFY.
1374
- */
1375
-
1376
- function isUserFeatureName(featureName) {
1377
- return featureName.indexOf("my") === 0;
1378
- }
1379
-
1380
- //#endregion
1381
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/toolbox/feature/SaveAsImage.js
1382
- /**
1383
- * AUTO-GENERATED FILE. DO NOT MODIFY.
1384
- */
1385
-
1386
- /**
1387
- * Group series into two types
1388
- * 1. on category axis, like line, bar
1389
- * 2. others, like scatter, pie
1390
- */
1391
- function groupSeries(ecModel) {
1392
- var seriesGroupByCategoryAxis = {};
1393
- var otherSeries = [];
1394
- var meta = [];
1395
- ecModel.eachRawSeries(function (seriesModel) {
1396
- var coordSys = seriesModel.coordinateSystem;
1397
- if (coordSys && (coordSys.type === "cartesian2d" || coordSys.type === "polar")) {
1398
- var baseAxis = coordSys.getBaseAxis();
1399
- if (baseAxis.type === "category") {
1400
- var key = baseAxis.dim + "_" + baseAxis.index;
1401
- if (!seriesGroupByCategoryAxis[key]) {
1402
- seriesGroupByCategoryAxis[key] = {
1403
- categoryAxis: baseAxis,
1404
- valueAxis: coordSys.getOtherAxis(baseAxis),
1405
- series: []
1406
- };
1407
- meta.push({
1408
- axisDim: baseAxis.dim,
1409
- axisIndex: baseAxis.index
1410
- });
1411
- }
1412
- seriesGroupByCategoryAxis[key].series.push(seriesModel);
1413
- } else otherSeries.push(seriesModel);
1414
- } else otherSeries.push(seriesModel);
1415
- });
1416
- return {
1417
- seriesGroupByCategoryAxis,
1418
- other: otherSeries,
1419
- meta
1420
- };
1421
- }
1422
- /**
1423
- * Assemble content of series on cateogory axis
1424
- * @inner
1425
- */
1426
- function assembleSeriesWithCategoryAxis(groups) {
1427
- var tables = [];
1428
- each$9(groups, function (group, key) {
1429
- var categoryAxis = group.categoryAxis;
1430
- var valueAxisDim = group.valueAxis.dim;
1431
- var headers = [" "].concat(map(group.series, function (series) {
1432
- return series.name;
1433
- }));
1434
- var columns = [categoryAxis.model.getCategories()];
1435
- each$9(group.series, function (series) {
1436
- var rawData = series.getRawData();
1437
- columns.push(series.getRawData().mapArray(rawData.mapDimension(valueAxisDim), function (val) {
1438
- return val;
1439
- }));
1440
- });
1441
- var lines = [headers.join(ITEM_SPLITER)];
1442
- for (var i = 0; i < columns[0].length; i++) {
1443
- var items = [];
1444
- for (var j = 0; j < columns.length; j++) items.push(columns[j][i]);
1445
- lines.push(items.join(ITEM_SPLITER));
1446
- }
1447
- tables.push(lines.join("\n"));
1448
- });
1449
- return tables.join("\n\n" + BLOCK_SPLITER + "\n\n");
1450
- }
1451
- /**
1452
- * Assemble content of other series
1453
- */
1454
- function assembleOtherSeries(series) {
1455
- return map(series, function (series) {
1456
- var data = series.getRawData();
1457
- var lines = [series.name];
1458
- var vals = [];
1459
- data.each(data.dimensions, function () {
1460
- var argLen = arguments.length;
1461
- var dataIndex = arguments[argLen - 1];
1462
- var name = data.getName(dataIndex);
1463
- for (var i = 0; i < argLen - 1; i++) vals[i] = arguments[i];
1464
- lines.push((name ? name + ITEM_SPLITER : "") + vals.join(ITEM_SPLITER));
1465
- });
1466
- return lines.join("\n");
1467
- }).join("\n\n" + BLOCK_SPLITER + "\n\n");
1468
- }
1469
- function getContentFromModel(ecModel) {
1470
- var result = groupSeries(ecModel);
1471
- return {
1472
- value: filter([assembleSeriesWithCategoryAxis(result.seriesGroupByCategoryAxis), assembleOtherSeries(result.other)], function (str) {
1473
- return !!str.replace(/[\n\t\s]/g, "");
1474
- }).join("\n\n" + BLOCK_SPLITER + "\n\n"),
1475
- meta: result.meta
1476
- };
1477
- }
1478
- function trim(str) {
1479
- return str.replace(/^\s\s*/, "").replace(/\s\s*$/, "");
1480
- }
1481
- /**
1482
- * If a block is tsv format
1483
- */
1484
- function isTSVFormat(block) {
1485
- if (block.slice(0, block.indexOf("\n")).indexOf(ITEM_SPLITER) >= 0) return true;
1486
- }
1487
- /**
1488
- * @param {string} tsv
1489
- * @return {Object}
1490
- */
1491
- function parseTSVContents(tsv) {
1492
- var tsvLines = tsv.split(/\n+/g);
1493
- var headers = trim(tsvLines.shift()).split(itemSplitRegex);
1494
- var categories = [];
1495
- var series = map(headers, function (header) {
1496
- return {
1497
- name: header,
1498
- data: []
1499
- };
1500
- });
1501
- for (var i = 0; i < tsvLines.length; i++) {
1502
- var items = trim(tsvLines[i]).split(itemSplitRegex);
1503
- categories.push(items.shift());
1504
- for (var j = 0; j < items.length; j++) series[j] && (series[j].data[i] = items[j]);
1505
- }
1506
- return {
1507
- series,
1508
- categories
1509
- };
1510
- }
1511
- function parseListContents(str) {
1512
- var lines = str.split(/\n+/g);
1513
- var seriesName = trim(lines.shift());
1514
- var data = [];
1515
- for (var i = 0; i < lines.length; i++) {
1516
- var line = trim(lines[i]);
1517
- if (!line) continue;
1518
- var items = line.split(itemSplitRegex);
1519
- var name_1 = "";
1520
- var value = void 0;
1521
- var hasName = false;
1522
- if (isNaN(items[0])) {
1523
- hasName = true;
1524
- name_1 = items[0];
1525
- items = items.slice(1);
1526
- data[i] = {
1527
- name: name_1,
1528
- value: []
1529
- };
1530
- value = data[i].value;
1531
- } else value = data[i] = [];
1532
- for (var j = 0; j < items.length; j++) value.push(+items[j]);
1533
- if (value.length === 1) hasName ? data[i].value = value[0] : data[i] = value[0];
1534
- }
1535
- return {
1536
- name: seriesName,
1537
- data
1538
- };
1539
- }
1540
- function parseContents(str, blockMetaList) {
1541
- var blocks = str.split(new RegExp("\n*" + BLOCK_SPLITER + "\n*", "g"));
1542
- var newOption = {
1543
- series: []
1544
- };
1545
- each$9(blocks, function (block, idx) {
1546
- if (isTSVFormat(block)) {
1547
- var result = parseTSVContents(block);
1548
- var blockMeta = blockMetaList[idx];
1549
- var axisKey = blockMeta.axisDim + "Axis";
1550
- if (blockMeta) {
1551
- newOption[axisKey] = newOption[axisKey] || [];
1552
- newOption[axisKey][blockMeta.axisIndex] = {
1553
- data: result.categories
1554
- };
1555
- newOption.series = newOption.series.concat(result.series);
1556
- }
1557
- } else {
1558
- var result = parseListContents(block);
1559
- newOption.series.push(result);
1560
- }
1561
- });
1562
- return newOption;
1563
- }
1564
- /**
1565
- * @inner
1566
- */
1567
- function tryMergeDataOption(newData, originalData) {
1568
- return map(newData, function (newVal, idx) {
1569
- var original = originalData && originalData[idx];
1570
- if (isObject(original) && !isArray$1(original)) {
1571
- if (!(isObject(newVal) && !isArray$1(newVal))) newVal = {
1572
- value: newVal
1573
- };
1574
- var shouldDeleteName = original.name != null && newVal.name == null;
1575
- newVal = defaults(newVal, original);
1576
- shouldDeleteName && delete newVal.name;
1577
- return newVal;
1578
- } else return newVal;
1579
- });
1580
- }
1581
- /**
1582
- * @param ecModel
1583
- * @param newSnapshot key is dataZoomId
1584
- */
1585
- function push(ecModel, newSnapshot) {
1586
- var storedSnapshots = getStoreSnapshots(ecModel);
1587
- each$6(newSnapshot, function (batchItem, dataZoomId) {
1588
- var i = storedSnapshots.length - 1;
1589
- for (; i >= 0; i--) if (storedSnapshots[i][dataZoomId]) break;
1590
- if (i < 0) {
1591
- var dataZoomModel = ecModel.queryComponents({
1592
- mainType: "dataZoom",
1593
- subType: "select",
1594
- id: dataZoomId
1595
- })[0];
1596
- if (dataZoomModel) {
1597
- var percentRange = dataZoomModel.getPercentRange();
1598
- storedSnapshots[0][dataZoomId] = {
1599
- dataZoomId,
1600
- start: percentRange[0],
1601
- end: percentRange[1]
1602
- };
1603
- }
1604
- }
1605
- });
1606
- storedSnapshots.push(newSnapshot);
1607
- }
1608
- function pop(ecModel) {
1609
- var storedSnapshots = getStoreSnapshots(ecModel);
1610
- var head = storedSnapshots[storedSnapshots.length - 1];
1611
- storedSnapshots.length > 1 && storedSnapshots.pop();
1612
- var snapshot = {};
1613
- each$6(head, function (batchItem, dataZoomId) {
1614
- for (var i = storedSnapshots.length - 1; i >= 0; i--) {
1615
- batchItem = storedSnapshots[i][dataZoomId];
1616
- if (batchItem) {
1617
- snapshot[dataZoomId] = batchItem;
1618
- break;
1619
- }
1620
- }
1621
- });
1622
- return snapshot;
1623
- }
1624
- function clear(ecModel) {
1625
- inner$6(ecModel).snapshots = null;
1626
- }
1627
- function count(ecModel) {
1628
- return getStoreSnapshots(ecModel).length;
1629
- }
1630
- /**
1631
- * History length of each dataZoom may be different.
1632
- * this._history[0] is used to store origin range.
1633
- */
1634
- function getStoreSnapshots(ecModel) {
1635
- var store = inner$6(ecModel);
1636
- if (!store.snapshots) store.snapshots = [{}];
1637
- return store.snapshots;
1638
- }
1639
-
1640
- //#endregion
1641
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/toolbox/feature/Restore.js
1642
- /**
1643
- * AUTO-GENERATED FILE. DO NOT MODIFY.
1644
- */
1645
-
1646
- function formatMinMax(minMax) {
1647
- minMax[0] > minMax[1] && minMax.reverse();
1648
- return minMax;
1649
- }
1650
- function parseFinder(ecModel, finder) {
1651
- return parseFinder$1(ecModel, finder, {
1652
- includeMainTypes: INCLUDE_FINDER_MAIN_TYPES
1653
- });
1654
- }
1655
- function axisConvert(axisNameIndex, to, coordSys, rangeOrCoordRange) {
1656
- var axis = coordSys.getAxis(["x", "y"][axisNameIndex]);
1657
- var values = formatMinMax(map([0, 1], function (i) {
1658
- return to ? axis.coordToData(axis.toLocalCoord(rangeOrCoordRange[i]), true) : axis.toGlobalCoord(axis.dataToCoord(rangeOrCoordRange[i]));
1659
- }));
1660
- var xyMinMax = [];
1661
- xyMinMax[axisNameIndex] = values;
1662
- xyMinMax[1 - axisNameIndex] = [NaN, NaN];
1663
- return {
1664
- values,
1665
- xyMinMax
1666
- };
1667
- }
1668
- function axisDiffProcessor(axisNameIndex, values, refer, scales) {
1669
- return [values[0] - scales[axisNameIndex] * refer[0], values[1] - scales[axisNameIndex] * refer[1]];
1670
- }
1671
- function getScales(xyMinMaxCurr, xyMinMaxOrigin) {
1672
- var sizeCurr = getSize(xyMinMaxCurr);
1673
- var sizeOrigin = getSize(xyMinMaxOrigin);
1674
- var scales = [sizeCurr[0] / sizeOrigin[0], sizeCurr[1] / sizeOrigin[1]];
1675
- isNaN(scales[0]) && (scales[0] = 1);
1676
- isNaN(scales[1]) && (scales[1] = 1);
1677
- return scales;
1678
- }
1679
- function getSize(xyMinMax) {
1680
- return xyMinMax ? [xyMinMax[0][1] - xyMinMax[0][0], xyMinMax[1][1] - xyMinMax[1][0]] : [NaN, NaN];
1681
- }
1682
-
1683
- //#endregion
1684
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/toolbox/feature/DataZoom.js
1685
- /**
1686
- * AUTO-GENERATED FILE. DO NOT MODIFY.
1687
- */
1688
-
1689
- function makeAxisFinder(dzFeatureModel) {
1690
- var setting = {
1691
- xAxisIndex: dzFeatureModel.get("xAxisIndex", true),
1692
- yAxisIndex: dzFeatureModel.get("yAxisIndex", true),
1693
- xAxisId: dzFeatureModel.get("xAxisId", true),
1694
- yAxisId: dzFeatureModel.get("yAxisId", true)
1695
- };
1696
- if (setting.xAxisIndex == null && setting.xAxisId == null) setting.xAxisIndex = "all";
1697
- if (setting.yAxisIndex == null && setting.yAxisId == null) setting.yAxisIndex = "all";
1698
- return setting;
1699
- }
1700
- function updateBackBtnStatus(featureModel, ecModel) {
1701
- featureModel.setIconStatus("back", count(ecModel) > 1 ? "emphasis" : "normal");
1702
- }
1703
- function updateZoomBtnStatus(featureModel, ecModel, view, payload, api) {
1704
- var zoomActive = view._isZoomActive;
1705
- if (payload && payload.type === "takeGlobalCursor") zoomActive = payload.key === "dataZoomSelect" ? payload.dataZoomSelectActive : false;
1706
- view._isZoomActive = zoomActive;
1707
- featureModel.setIconStatus("zoom", zoomActive ? "emphasis" : "normal");
1708
- var panels = new BrushTargetManager(makeAxisFinder(featureModel), ecModel, {
1709
- include: ["grid"]
1710
- }).makePanelOpts(api, function (targetInfo) {
1711
- return targetInfo.xAxisDeclared && !targetInfo.yAxisDeclared ? "lineX" : !targetInfo.xAxisDeclared && targetInfo.yAxisDeclared ? "lineY" : "rect";
1712
- });
1713
- view._brushController.setPanels(panels).enableBrush(zoomActive && panels.length ? {
1714
- brushType: "auto",
1715
- brushStyle: featureModel.getModel("brushStyle").getItemStyle()
1716
- } : false);
1717
- }
1718
- //#endregion
1719
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/toolbox/install.js
1720
- /**
1721
- * AUTO-GENERATED FILE. DO NOT MODIFY.
1722
- */
1723
- function install$16(registers) {
1724
- registers.registerComponentModel(ToolboxModel);
1725
- registers.registerComponentView(ToolboxView);
1726
- registerFeature("saveAsImage", SaveAsImage);
1727
- registerFeature("magicType", MagicType);
1728
- registerFeature("dataView", DataView);
1729
- registerFeature("dataZoom", DataZoomFeature);
1730
- registerFeature("restore", RestoreOption);
1731
- use(install$25);
1732
- }
1733
-
1734
- //#endregion
1735
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/tooltip/TooltipModel.js
1736
- /**
1737
- * AUTO-GENERATED FILE. DO NOT MODIFY.
1738
- */
1739
-
1740
- //#endregion
1741
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/tooltip/helper.js
1742
- /**
1743
- * AUTO-GENERATED FILE. DO NOT MODIFY.
1744
- */
1745
- function shouldTooltipConfine(tooltipModel) {
1746
- var confineOption = tooltipModel.get("confine");
1747
- return confineOption != null ? !!confineOption : tooltipModel.get("renderMode") === "richText";
1748
- }
1749
- function testStyle(styleProps) {
1750
- if (!env.domSupported) return;
1751
- var style = document.documentElement.style;
1752
- for (var i = 0, len = styleProps.length; i < len; i++) if (styleProps[i] in style) return styleProps[i];
1753
- }
1754
- function toCSSVendorPrefix(styleVendor, styleProp) {
1755
- if (!styleVendor) return styleProp;
1756
- styleProp = toCamelCase(styleProp, true);
1757
- var idx = styleVendor.indexOf(styleProp);
1758
- styleVendor = idx === -1 ? styleProp : "-" + styleVendor.slice(0, idx) + "-" + styleProp;
1759
- return styleVendor.toLowerCase();
1760
- }
1761
- function getComputedStyle(el, style) {
1762
- var stl = el.currentStyle || document.defaultView && document.defaultView.getComputedStyle(el);
1763
- return stl ? style ? stl[style] : stl : null;
1764
- }
1765
-
1766
- //#endregion
1767
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/tooltip/TooltipHTMLContent.js
1768
- /**
1769
- * AUTO-GENERATED FILE. DO NOT MODIFY.
1770
- */
1771
-
1772
- function mirrorPos(pos) {
1773
- pos = pos === "left" ? "right" : pos === "right" ? "left" : pos === "top" ? "bottom" : "top";
1774
- return pos;
1775
- }
1776
- function assembleArrow(tooltipModel, borderColor, arrowPosition) {
1777
- if (!isString(arrowPosition) || arrowPosition === "inside") return "";
1778
- var backgroundColor = tooltipModel.get("backgroundColor");
1779
- var borderWidth = tooltipModel.get("borderWidth");
1780
- borderColor = convertToColorString(borderColor);
1781
- var arrowPos = mirrorPos(arrowPosition);
1782
- var arrowSize = Math.max(Math.round(borderWidth) * 1.5, 6);
1783
- var positionStyle = "";
1784
- var transformStyle = CSS_TRANSFORM_VENDOR + ":";
1785
- var rotateDeg;
1786
- if (indexOf(["left", "right"], arrowPos) > -1) {
1787
- positionStyle += "top:50%";
1788
- transformStyle += "translateY(-50%) rotate(" + (rotateDeg = arrowPos === "left" ? -225 : -45) + "deg)";
1789
- } else {
1790
- positionStyle += "left:50%";
1791
- transformStyle += "translateX(-50%) rotate(" + (rotateDeg = arrowPos === "top" ? 225 : 45) + "deg)";
1792
- }
1793
- var rotateRadian = rotateDeg * Math.PI / 180;
1794
- var arrowWH = arrowSize + borderWidth;
1795
- var rotatedWH = arrowWH * Math.abs(Math.cos(rotateRadian)) + arrowWH * Math.abs(Math.sin(rotateRadian));
1796
- var arrowOffset = Math.round(((rotatedWH - Math.SQRT2 * borderWidth) / 2 + Math.SQRT2 * borderWidth - (rotatedWH - arrowWH) / 2) * 100) / 100;
1797
- positionStyle += ";" + arrowPos + ":-" + arrowOffset + "px";
1798
- var borderStyle = borderColor + " solid " + borderWidth + "px;";
1799
- return "<div style=\"" + ["position:absolute;width:" + arrowSize + "px;height:" + arrowSize + "px;z-index:-1;", positionStyle + ";" + transformStyle + ";", "border-bottom:" + borderStyle, "border-right:" + borderStyle, "background-color:" + backgroundColor + ";"].join("") + "\"></div>";
1800
- }
1801
- function assembleTransition(duration, onlyFadeTransition, enableDisplayTransition) {
1802
- var transitionCurve = "cubic-bezier(0.23,1,0.32,1)";
1803
- var transitionOption = "";
1804
- var transitionText = "";
1805
- if (enableDisplayTransition) {
1806
- transitionOption = " " + duration / 2 + "s " + transitionCurve;
1807
- transitionText = "opacity" + transitionOption + ",visibility" + transitionOption;
1808
- }
1809
- if (!onlyFadeTransition) {
1810
- transitionOption = " " + duration + "s " + transitionCurve;
1811
- transitionText += (transitionText.length ? "," : "") + (env.transformSupported ? "" + CSS_TRANSFORM_VENDOR + transitionOption : ",left" + transitionOption + ",top" + transitionOption);
1812
- }
1813
- return CSS_TRANSITION_VENDOR + ":" + transitionText;
1814
- }
1815
- function assembleTransform(x, y, toString) {
1816
- var x0 = x.toFixed(0) + "px";
1817
- var y0 = y.toFixed(0) + "px";
1818
- if (!env.transformSupported) return toString ? "top:" + y0 + ";left:" + x0 + ";" : [["top", y0], ["left", x0]];
1819
- var is3d = env.transform3dSupported;
1820
- var translate = "translate" + (is3d ? "3d" : "") + "(" + x0 + "," + y0 + (is3d ? ",0" : "") + ")";
1821
- return toString ? "top:0;left:0;" + CSS_TRANSFORM_VENDOR + ":" + translate + ";" : [["top", 0], ["left", 0], [TRANSFORM_VENDOR, translate]];
1822
- }
1823
- /**
1824
- * @param {Object} textStyle
1825
- * @return {string}
1826
- * @inner
1827
- */
1828
- function assembleFont(textStyleModel) {
1829
- var cssText = [];
1830
- var fontSize = textStyleModel.get("fontSize");
1831
- var color = textStyleModel.getTextColor();
1832
- color && cssText.push("color:" + color);
1833
- cssText.push("font:" + textStyleModel.getFont());
1834
- var lineHeight = retrieve2(textStyleModel.get("lineHeight"), Math.round(fontSize * 3 / 2));
1835
- fontSize && cssText.push("line-height:" + lineHeight + "px");
1836
- var shadowColor = textStyleModel.get("textShadowColor");
1837
- var shadowBlur = textStyleModel.get("textShadowBlur") || 0;
1838
- var shadowOffsetX = textStyleModel.get("textShadowOffsetX") || 0;
1839
- var shadowOffsetY = textStyleModel.get("textShadowOffsetY") || 0;
1840
- shadowColor && shadowBlur && cssText.push("text-shadow:" + shadowOffsetX + "px " + shadowOffsetY + "px " + shadowBlur + "px " + shadowColor);
1841
- each$9(["decoration", "align"], function (name) {
1842
- var val = textStyleModel.get(name);
1843
- val && cssText.push("text-" + name + ":" + val);
1844
- });
1845
- return cssText.join(";");
1846
- }
1847
- function assembleCssText(tooltipModel, enableTransition, onlyFadeTransition, enableDisplayTransition) {
1848
- var cssText = [];
1849
- var transitionDuration = tooltipModel.get("transitionDuration");
1850
- var backgroundColor = tooltipModel.get("backgroundColor");
1851
- var shadowBlur = tooltipModel.get("shadowBlur");
1852
- var shadowColor = tooltipModel.get("shadowColor");
1853
- var shadowOffsetX = tooltipModel.get("shadowOffsetX");
1854
- var shadowOffsetY = tooltipModel.get("shadowOffsetY");
1855
- var textStyleModel = tooltipModel.getModel("textStyle");
1856
- var padding = getPaddingFromTooltipModel(tooltipModel, "html");
1857
- var boxShadow = shadowOffsetX + "px " + shadowOffsetY + "px " + shadowBlur + "px " + shadowColor;
1858
- cssText.push("box-shadow:" + boxShadow);
1859
- enableTransition && transitionDuration > 0 && cssText.push(assembleTransition(transitionDuration, onlyFadeTransition, enableDisplayTransition));
1860
- if (backgroundColor) cssText.push("background-color:" + backgroundColor);
1861
- each$9(["width", "color", "radius"], function (name) {
1862
- var borderName = "border-" + name;
1863
- var camelCase = toCamelCase(borderName);
1864
- var val = tooltipModel.get(camelCase);
1865
- val != null && cssText.push(borderName + ":" + val + (name === "color" ? "" : "px"));
1866
- });
1867
- cssText.push(assembleFont(textStyleModel));
1868
- if (padding != null) cssText.push("padding:" + normalizeCssArray(padding).join("px ") + "px");
1869
- return cssText.join(";") + ";";
1870
- }
1871
- function makeStyleCoord$1(out, zr, container, zrX, zrY) {
1872
- var zrPainter = zr && zr.painter;
1873
- if (container) {
1874
- var zrViewportRoot = zrPainter && zrPainter.getViewportRoot();
1875
- if (zrViewportRoot) transformLocalCoord(out, zrViewportRoot, container, zrX, zrY);
1876
- } else {
1877
- out[0] = zrX;
1878
- out[1] = zrY;
1879
- var viewportRootOffset = zrPainter && zrPainter.getViewportRootOffset();
1880
- if (viewportRootOffset) {
1881
- out[0] += viewportRootOffset.offsetLeft;
1882
- out[1] += viewportRootOffset.offsetTop;
1883
- }
1884
- }
1885
- out[2] = out[0] / zr.getWidth();
1886
- out[3] = out[1] / zr.getHeight();
1887
- }
1888
- function mathMaxWith0(val) {
1889
- return Math.max(0, val);
1890
- }
1891
- function calcShadowOuterSize(style) {
1892
- var shadowBlur = mathMaxWith0(style.shadowBlur || 0);
1893
- var shadowOffsetX = mathMaxWith0(style.shadowOffsetX || 0);
1894
- var shadowOffsetY = mathMaxWith0(style.shadowOffsetY || 0);
1895
- return {
1896
- left: mathMaxWith0(shadowBlur - shadowOffsetX),
1897
- right: mathMaxWith0(shadowBlur + shadowOffsetX),
1898
- top: mathMaxWith0(shadowBlur - shadowOffsetY),
1899
- bottom: mathMaxWith0(shadowBlur + shadowOffsetY)
1900
- };
1901
- }
1902
- function makeStyleCoord(out, zr, zrX, zrY) {
1903
- out[0] = zrX;
1904
- out[1] = zrY;
1905
- out[2] = out[0] / zr.getWidth();
1906
- out[3] = out[1] / zr.getHeight();
1907
- }
1908
-
1909
- //#endregion
1910
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/tooltip/TooltipView.js
1911
- /**
1912
- * AUTO-GENERATED FILE. DO NOT MODIFY.
1913
- */
1914
-
1915
- /**
1916
- * From top to bottom. (the last one should be globalTooltipModel);
1917
- */
1918
- function buildTooltipModel(modelCascade, globalTooltipModel, defaultTooltipOption) {
1919
- var ecModel = globalTooltipModel.ecModel;
1920
- var resultModel;
1921
- if (defaultTooltipOption) {
1922
- resultModel = new Model(defaultTooltipOption, ecModel, ecModel);
1923
- resultModel = new Model(globalTooltipModel.option, resultModel, ecModel);
1924
- } else resultModel = globalTooltipModel;
1925
- for (var i = modelCascade.length - 1; i >= 0; i--) {
1926
- var tooltipOpt = modelCascade[i];
1927
- if (tooltipOpt) {
1928
- if (tooltipOpt instanceof Model) tooltipOpt = tooltipOpt.get("tooltip", true);
1929
- if (isString(tooltipOpt)) tooltipOpt = {
1930
- formatter: tooltipOpt
1931
- };
1932
- if (tooltipOpt) resultModel = new Model(tooltipOpt, resultModel, ecModel);
1933
- }
1934
- }
1935
- return resultModel;
1936
- }
1937
- function makeDispatchAction(payload, api) {
1938
- return payload.dispatchAction || bind$1(api.dispatchAction, api);
1939
- }
1940
- function refixTooltipPosition(x, y, content, viewWidth, viewHeight, gapH, gapV) {
1941
- var size = content.getSize();
1942
- var width = size[0];
1943
- var height = size[1];
1944
- if (gapH != null) if (x + width + gapH + 2 > viewWidth) x -= width + gapH;else x += gapH;
1945
- if (gapV != null) if (y + height + gapV > viewHeight) y -= height + gapV;else y += gapV;
1946
- return [x, y];
1947
- }
1948
- function confineTooltipPosition(x, y, content, viewWidth, viewHeight) {
1949
- var size = content.getSize();
1950
- var width = size[0];
1951
- var height = size[1];
1952
- x = Math.min(x + width, viewWidth) - width;
1953
- y = Math.min(y + height, viewHeight) - height;
1954
- x = Math.max(x, 0);
1955
- y = Math.max(y, 0);
1956
- return [x, y];
1957
- }
1958
- function calcTooltipPosition(position, rect, contentSize, borderWidth) {
1959
- var domWidth = contentSize[0];
1960
- var domHeight = contentSize[1];
1961
- var offset = Math.ceil(Math.SQRT2 * borderWidth) + 8;
1962
- var x = 0;
1963
- var y = 0;
1964
- var rectWidth = rect.width;
1965
- var rectHeight = rect.height;
1966
- switch (position) {
1967
- case "inside":
1968
- x = rect.x + rectWidth / 2 - domWidth / 2;
1969
- y = rect.y + rectHeight / 2 - domHeight / 2;
1970
- break;
1971
- case "top":
1972
- x = rect.x + rectWidth / 2 - domWidth / 2;
1973
- y = rect.y - domHeight - offset;
1974
- break;
1975
- case "bottom":
1976
- x = rect.x + rectWidth / 2 - domWidth / 2;
1977
- y = rect.y + rectHeight + offset;
1978
- break;
1979
- case "left":
1980
- x = rect.x - domWidth - offset;
1981
- y = rect.y + rectHeight / 2 - domHeight / 2;
1982
- break;
1983
- case "right":
1984
- x = rect.x + rectWidth + offset;
1985
- y = rect.y + rectHeight / 2 - domHeight / 2;
1986
- }
1987
- return [x, y];
1988
- }
1989
- function isCenterAlign(align) {
1990
- return align === "center" || align === "middle";
1991
- }
1992
- /**
1993
- * Find target component by payload like:
1994
- * ```js
1995
- * { legendId: 'some_id', name: 'xxx' }
1996
- * { toolboxIndex: 1, name: 'xxx' }
1997
- * { geoName: 'some_name', name: 'xxx' }
1998
- * ```
1999
- * PENDING: at present only
2000
- *
2001
- * If not found, return null/undefined.
2002
- */
2003
- function findComponentReference(payload, ecModel, api) {
2004
- var queryOptionMap = preParseFinder(payload).queryOptionMap;
2005
- var componentMainType = queryOptionMap.keys()[0];
2006
- if (!componentMainType || componentMainType === "series") return;
2007
- var model = queryReferringComponents(ecModel, componentMainType, queryOptionMap.get(componentMainType), {
2008
- useDefault: false,
2009
- enableAll: false,
2010
- enableNone: false
2011
- }).models[0];
2012
- if (!model) return;
2013
- var view = api.getViewOfComponentModel(model);
2014
- var el;
2015
- view.group.traverse(function (subEl) {
2016
- var tooltipConfig = getECData(subEl).tooltipConfig;
2017
- if (tooltipConfig && tooltipConfig.name === payload.name) {
2018
- el = subEl;
2019
- return true;
2020
- }
2021
- });
2022
- if (el) return {
2023
- componentMainType,
2024
- componentIndex: model.componentIndex,
2025
- el
2026
- };
2027
- }
2028
-
2029
- //#endregion
2030
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/tooltip/install.js
2031
- /**
2032
- * AUTO-GENERATED FILE. DO NOT MODIFY.
2033
- */
2034
- function install$17(registers) {
2035
- use(install$26);
2036
- registers.registerComponentModel(TooltipModel);
2037
- registers.registerComponentView(TooltipView);
2038
- /**
2039
- * @action
2040
- * @property {string} type
2041
- * @property {number} seriesIndex
2042
- * @property {number} dataIndex
2043
- * @property {number} [x]
2044
- * @property {number} [y]
2045
- */
2046
- registers.registerAction({
2047
- type: "showTip",
2048
- event: "showTip",
2049
- update: "tooltip:manuallyShowTip"
2050
- }, noop);
2051
- registers.registerAction({
2052
- type: "hideTip",
2053
- event: "hideTip",
2054
- update: "tooltip:manuallyHideTip"
2055
- }, noop);
2056
- }
2057
-
2058
- //#endregion
2059
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/brush/preprocessor.js
2060
- /**
2061
- * AUTO-GENERATED FILE. DO NOT MODIFY.
2062
- */
2063
-
2064
- function brushPreprocessor(option, isNew) {
2065
- var brushComponents = normalizeToArray(option ? option.brush : []);
2066
- if (!brushComponents.length) return;
2067
- var brushComponentSpecifiedBtns = [];
2068
- each$9(brushComponents, function (brushOpt) {
2069
- var tbs = brushOpt.hasOwnProperty("toolbox") ? brushOpt.toolbox : [];
2070
- if (tbs instanceof Array) brushComponentSpecifiedBtns = brushComponentSpecifiedBtns.concat(tbs);
2071
- });
2072
- var toolbox = option && option.toolbox;
2073
- if (isArray$1(toolbox)) toolbox = toolbox[0];
2074
- if (!toolbox) {
2075
- toolbox = {
2076
- feature: {}
2077
- };
2078
- option.toolbox = [toolbox];
2079
- }
2080
- var toolboxFeature = toolbox.feature || (toolbox.feature = {});
2081
- var toolboxBrush = toolboxFeature.brush || (toolboxFeature.brush = {});
2082
- var brushTypes = toolboxBrush.type || (toolboxBrush.type = []);
2083
- brushTypes.push.apply(brushTypes, brushComponentSpecifiedBtns);
2084
- removeDuplicate(brushTypes);
2085
- if (isNew && !brushTypes.length) brushTypes.push.apply(brushTypes, DEFAULT_TOOLBOX_BTNS);
2086
- }
2087
- function removeDuplicate(arr) {
2088
- var map = {};
2089
- each$9(arr, function (val) {
2090
- map[val] = 1;
2091
- });
2092
- arr.length = 0;
2093
- each$9(map, function (flag, val) {
2094
- arr.push(val);
2095
- });
2096
- }
2097
-
2098
- //#endregion
2099
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/visual/visualSolution.js
2100
- /**
2101
- * AUTO-GENERATED FILE. DO NOT MODIFY.
2102
- */
2103
- /**
2104
- * @file Visual solution, for consistent option specification.
2105
- */
2106
-
2107
- function hasKeys(obj) {
2108
- if (obj) {
2109
- for (var name_1 in obj) if (obj.hasOwnProperty(name_1)) return true;
2110
- }
2111
- }
2112
- function createVisualMappings(option, stateList, supplementVisualOption) {
2113
- var visualMappings = {};
2114
- each$4(stateList, function (state) {
2115
- var mappings = visualMappings[state] = createMappings();
2116
- each$4(option[state], function (visualData, visualType) {
2117
- if (!VisualMapping.isValidType(visualType)) return;
2118
- var mappingOption = {
2119
- type: visualType,
2120
- visual: visualData
2121
- };
2122
- supplementVisualOption && supplementVisualOption(mappingOption, state);
2123
- mappings[visualType] = new VisualMapping(mappingOption);
2124
- if (visualType === "opacity") {
2125
- mappingOption = clone$1(mappingOption);
2126
- mappingOption.type = "colorAlpha";
2127
- mappings.__hidden.__alphaForOpacity = new VisualMapping(mappingOption);
2128
- }
2129
- });
2130
- });
2131
- return visualMappings;
2132
- function createMappings() {
2133
- var Creater = function () {};
2134
- Creater.prototype.__hidden = Creater.prototype;
2135
- return new Creater();
2136
- }
2137
- }
2138
- function replaceVisualOption(thisOption, newOption, keys) {
2139
- var has;
2140
- each$9(keys, function (key) {
2141
- if (newOption.hasOwnProperty(key) && hasKeys(newOption[key])) has = true;
2142
- });
2143
- has && each$9(keys, function (key) {
2144
- if (newOption.hasOwnProperty(key) && hasKeys(newOption[key])) thisOption[key] = clone$1(newOption[key]);else delete thisOption[key];
2145
- });
2146
- }
2147
- /**
2148
- * @param stateList
2149
- * @param visualMappings
2150
- * @param list
2151
- * @param getValueState param: valueOrIndex, return: state.
2152
- * @param scope Scope for getValueState
2153
- * @param dimension Concrete dimension, if used.
2154
- */
2155
- function applyVisual(stateList, visualMappings, data, getValueState, scope, dimension) {
2156
- var visualTypesMap = {};
2157
- each$9(stateList, function (state) {
2158
- visualTypesMap[state] = VisualMapping.prepareVisualTypes(visualMappings[state]);
2159
- });
2160
- var dataIndex;
2161
- function getVisual(key) {
2162
- return getItemVisualFromData(data, dataIndex, key);
2163
- }
2164
- function setVisual(key, value) {
2165
- setItemVisualFromData(data, dataIndex, key, value);
2166
- }
2167
- if (dimension == null) data.each(eachItem);else data.each([dimension], eachItem);
2168
- function eachItem(valueOrIndex, index) {
2169
- dataIndex = dimension == null ? valueOrIndex : index;
2170
- var rawDataItem = data.getRawDataItem(dataIndex);
2171
- if (rawDataItem && rawDataItem.visualMap === false) return;
2172
- var valueState = getValueState.call(scope, valueOrIndex);
2173
- var mappings = visualMappings[valueState];
2174
- var visualTypes = visualTypesMap[valueState];
2175
- for (var i = 0, len = visualTypes.length; i < len; i++) {
2176
- var type = visualTypes[i];
2177
- mappings[type] && mappings[type].applyVisual(valueOrIndex, getVisual, setVisual);
2178
- }
2179
- }
2180
- }
2181
- /**
2182
- * @param data
2183
- * @param stateList
2184
- * @param visualMappings <state, Object.<visualType, module:echarts/visual/VisualMapping>>
2185
- * @param getValueState param: valueOrIndex, return: state.
2186
- * @param dim dimension or dimension index.
2187
- */
2188
- function incrementalApplyVisual(stateList, visualMappings, getValueState, dim) {
2189
- var visualTypesMap = {};
2190
- each$9(stateList, function (state) {
2191
- visualTypesMap[state] = VisualMapping.prepareVisualTypes(visualMappings[state]);
2192
- });
2193
- return {
2194
- progress: function progress(params, data) {
2195
- var dimIndex;
2196
- if (dim != null) dimIndex = data.getDimensionIndex(dim);
2197
- function getVisual(key) {
2198
- return getItemVisualFromData(data, dataIndex, key);
2199
- }
2200
- function setVisual(key, value) {
2201
- setItemVisualFromData(data, dataIndex, key, value);
2202
- }
2203
- var dataIndex;
2204
- var store = data.getStore();
2205
- while ((dataIndex = params.next()) != null) {
2206
- var rawDataItem = data.getRawDataItem(dataIndex);
2207
- if (rawDataItem && rawDataItem.visualMap === false) continue;
2208
- var value = dim != null ? store.get(dimIndex, dataIndex) : dataIndex;
2209
- var valueState = getValueState(value);
2210
- var mappings = visualMappings[valueState];
2211
- var visualTypes = visualTypesMap[valueState];
2212
- for (var i = 0, len = visualTypes.length; i < len; i++) {
2213
- var type = visualTypes[i];
2214
- mappings[type] && mappings[type].applyVisual(value, getVisual, setVisual);
2215
- }
2216
- }
2217
- }
2218
- };
2219
- }
2220
-
2221
- //#endregion
2222
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/brush/selector.js
2223
- /**
2224
- * AUTO-GENERATED FILE. DO NOT MODIFY.
2225
- */
2226
- function makeBrushCommonSelectorForSeries(area) {
2227
- var brushType = area.brushType;
2228
- var selectors = {
2229
- point: function (itemLayout) {
2230
- return selector[brushType].point(itemLayout, selectors, area);
2231
- },
2232
- rect: function (itemLayout) {
2233
- return selector[brushType].rect(itemLayout, selectors, area);
2234
- }
2235
- };
2236
- return selectors;
2237
- }
2238
- function getLineSelectors(xyIndex) {
2239
- var xy = ["x", "y"];
2240
- var wh = ["width", "height"];
2241
- return {
2242
- point: function (itemLayout, selectors, area) {
2243
- if (itemLayout) {
2244
- var range = area.range;
2245
- var p = itemLayout[xyIndex];
2246
- return inLineRange(p, range);
2247
- }
2248
- },
2249
- rect: function (itemLayout, selectors, area) {
2250
- if (itemLayout) {
2251
- var range = area.range;
2252
- var layoutRange = [itemLayout[xy[xyIndex]], itemLayout[xy[xyIndex]] + itemLayout[wh[xyIndex]]];
2253
- layoutRange[1] < layoutRange[0] && layoutRange.reverse();
2254
- return inLineRange(layoutRange[0], range) || inLineRange(layoutRange[1], range) || inLineRange(range[0], layoutRange) || inLineRange(range[1], layoutRange);
2255
- }
2256
- }
2257
- };
2258
- }
2259
- function inLineRange(p, range) {
2260
- return range[0] <= p && p <= range[1];
2261
- }
2262
-
2263
- //#endregion
2264
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/brush/visualEncoding.js
2265
- /**
2266
- * AUTO-GENERATED FILE. DO NOT MODIFY.
2267
- */
2268
-
2269
- function layoutCovers(ecModel) {
2270
- ecModel.eachComponent({
2271
- mainType: "brush"
2272
- }, function (brushModel) {
2273
- (brushModel.brushTargetManager = new BrushTargetManager(brushModel.option, ecModel)).setInputRanges(brushModel.areas, ecModel);
2274
- });
2275
- }
2276
- /**
2277
- * Register the visual encoding if this modules required.
2278
- */
2279
- function brushVisual(ecModel, api, payload) {
2280
- var brushSelected = [];
2281
- var throttleType;
2282
- var throttleDelay;
2283
- ecModel.eachComponent({
2284
- mainType: "brush"
2285
- }, function (brushModel) {
2286
- payload && payload.type === "takeGlobalCursor" && brushModel.setBrushOption(payload.key === "brush" ? payload.brushOption : {
2287
- brushType: false
2288
- });
2289
- });
2290
- layoutCovers(ecModel);
2291
- ecModel.eachComponent({
2292
- mainType: "brush"
2293
- }, function (brushModel, brushIndex) {
2294
- var thisBrushSelected = {
2295
- brushId: brushModel.id,
2296
- brushIndex,
2297
- brushName: brushModel.name,
2298
- areas: clone$1(brushModel.areas),
2299
- selected: []
2300
- };
2301
- brushSelected.push(thisBrushSelected);
2302
- var brushOption = brushModel.option;
2303
- var brushLink = brushOption.brushLink;
2304
- var linkedSeriesMap = [];
2305
- var selectedDataIndexForLink = [];
2306
- var rangeInfoBySeries = [];
2307
- var hasBrushExists = false;
2308
- if (!brushIndex) {
2309
- throttleType = brushOption.throttleType;
2310
- throttleDelay = brushOption.throttleDelay;
2311
- }
2312
- var areas = map(brushModel.areas, function (area) {
2313
- var builder = boundingRectBuilders[area.brushType];
2314
- var selectableArea = defaults({
2315
- boundingRect: builder ? builder(area) : void 0
2316
- }, area);
2317
- selectableArea.selectors = makeBrushCommonSelectorForSeries(selectableArea);
2318
- return selectableArea;
2319
- });
2320
- var visualMappings = createVisualMappings(brushModel.option, STATE_LIST, function (mappingOption) {
2321
- mappingOption.mappingMethod = "fixed";
2322
- });
2323
- isArray$1(brushLink) && each$9(brushLink, function (seriesIndex) {
2324
- linkedSeriesMap[seriesIndex] = 1;
2325
- });
2326
- function linkOthers(seriesIndex) {
2327
- return brushLink === "all" || !!linkedSeriesMap[seriesIndex];
2328
- }
2329
- function brushed(rangeInfoList) {
2330
- return !!rangeInfoList.length;
2331
- }
2332
- /**
2333
- * Logic for each series: (If the logic has to be modified one day, do it carefully!)
2334
- *
2335
- * ( brushed ┬ && ┬hasBrushExist ┬ && linkOthers ) => StepA: ┬record, ┬ StepB: ┬visualByRecord.
2336
- * !brushed┘ ├hasBrushExist ┤ └nothing,┘ ├visualByRecord.
2337
- * └!hasBrushExist┘ └nothing.
2338
- * ( !brushed && ┬hasBrushExist ┬ && linkOthers ) => StepA: nothing, StepB: ┬visualByRecord.
2339
- * └!hasBrushExist┘ └nothing.
2340
- * ( brushed ┬ && !linkOthers ) => StepA: nothing, StepB: ┬visualByCheck.
2341
- * !brushed┘ └nothing.
2342
- * ( !brushed && !linkOthers ) => StepA: nothing, StepB: nothing.
2343
- */
2344
- ecModel.eachSeries(function (seriesModel, seriesIndex) {
2345
- var rangeInfoList = rangeInfoBySeries[seriesIndex] = [];
2346
- seriesModel.subType === "parallel" ? stepAParallel(seriesModel, seriesIndex) : stepAOthers(seriesModel, seriesIndex, rangeInfoList);
2347
- });
2348
- function stepAParallel(seriesModel, seriesIndex) {
2349
- var coordSys = seriesModel.coordinateSystem;
2350
- hasBrushExists = hasBrushExists || coordSys.hasAxisBrushed();
2351
- linkOthers(seriesIndex) && coordSys.eachActiveState(seriesModel.getData(), function (activeState, dataIndex) {
2352
- activeState === "active" && (selectedDataIndexForLink[dataIndex] = 1);
2353
- });
2354
- }
2355
- function stepAOthers(seriesModel, seriesIndex, rangeInfoList) {
2356
- if (!seriesModel.brushSelector || brushModelNotControll(brushModel, seriesIndex)) return;
2357
- each$9(areas, function (area) {
2358
- if (brushModel.brushTargetManager.controlSeries(area, seriesModel, ecModel)) rangeInfoList.push(area);
2359
- hasBrushExists = hasBrushExists || brushed(rangeInfoList);
2360
- });
2361
- if (linkOthers(seriesIndex) && brushed(rangeInfoList)) {
2362
- var data_1 = seriesModel.getData();
2363
- data_1.each(function (dataIndex) {
2364
- if (checkInRange(seriesModel, rangeInfoList, data_1, dataIndex)) selectedDataIndexForLink[dataIndex] = 1;
2365
- });
2366
- }
2367
- }
2368
- ecModel.eachSeries(function (seriesModel, seriesIndex) {
2369
- var seriesBrushSelected = {
2370
- seriesId: seriesModel.id,
2371
- seriesIndex,
2372
- seriesName: seriesModel.name,
2373
- dataIndex: []
2374
- };
2375
- thisBrushSelected.selected.push(seriesBrushSelected);
2376
- var rangeInfoList = rangeInfoBySeries[seriesIndex];
2377
- var data = seriesModel.getData();
2378
- var getValueState = linkOthers(seriesIndex) ? function (dataIndex) {
2379
- return selectedDataIndexForLink[dataIndex] ? (seriesBrushSelected.dataIndex.push(data.getRawIndex(dataIndex)), "inBrush") : "outOfBrush";
2380
- } : function (dataIndex) {
2381
- return checkInRange(seriesModel, rangeInfoList, data, dataIndex) ? (seriesBrushSelected.dataIndex.push(data.getRawIndex(dataIndex)), "inBrush") : "outOfBrush";
2382
- };
2383
- (linkOthers(seriesIndex) ? hasBrushExists : brushed(rangeInfoList)) && applyVisual(STATE_LIST, visualMappings, data, getValueState);
2384
- });
2385
- });
2386
- dispatchAction$1(api, throttleType, throttleDelay, brushSelected, payload);
2387
- }
2388
- function dispatchAction$1(api, throttleType, throttleDelay, brushSelected, payload) {
2389
- if (!payload) return;
2390
- var zr = api.getZr();
2391
- if (zr[DISPATCH_FLAG]) return;
2392
- if (!zr[DISPATCH_METHOD]) zr[DISPATCH_METHOD] = doDispatch;
2393
- createOrUpdate(zr, DISPATCH_METHOD, throttleDelay, throttleType)(api, brushSelected);
2394
- }
2395
- function doDispatch(api, brushSelected) {
2396
- if (!api.isDisposed()) {
2397
- var zr = api.getZr();
2398
- zr[DISPATCH_FLAG] = true;
2399
- api.dispatchAction({
2400
- type: "brushSelect",
2401
- batch: brushSelected
2402
- });
2403
- zr[DISPATCH_FLAG] = false;
2404
- }
2405
- }
2406
- function checkInRange(seriesModel, rangeInfoList, data, dataIndex) {
2407
- for (var i = 0, len = rangeInfoList.length; i < len; i++) {
2408
- var area = rangeInfoList[i];
2409
- if (seriesModel.brushSelector(dataIndex, data, area.selectors, area)) return true;
2410
- }
2411
- }
2412
- function brushModelNotControll(brushModel, seriesIndex) {
2413
- var seriesIndices = brushModel.option.seriesIndex;
2414
- return seriesIndices != null && seriesIndices !== "all" && (isArray$1(seriesIndices) ? indexOf(seriesIndices, seriesIndex) < 0 : seriesIndex !== seriesIndices);
2415
- }
2416
- function getBoundingRectFromMinMax(minMax) {
2417
- return new BoundingRect(minMax[0][0], minMax[1][0], minMax[0][1] - minMax[0][0], minMax[1][1] - minMax[1][0]);
2418
- }
2419
-
2420
- //#endregion
2421
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/brush/BrushView.js
2422
- /**
2423
- * AUTO-GENERATED FILE. DO NOT MODIFY.
2424
- */
2425
-
2426
- function generateBrushOption(option, brushOption) {
2427
- return merge({
2428
- brushType: option.brushType,
2429
- brushMode: option.brushMode,
2430
- transformable: option.transformable,
2431
- brushStyle: new Model(option.brushStyle).getItemStyle(),
2432
- removeOnClick: option.removeOnClick,
2433
- z: option.z
2434
- }, brushOption, true);
2435
- }
2436
-
2437
- //#endregion
2438
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/toolbox/feature/Brush.js
2439
- /**
2440
- * AUTO-GENERATED FILE. DO NOT MODIFY.
2441
- */
2442
-
2443
- //#endregion
2444
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/brush/install.js
2445
- /**
2446
- * AUTO-GENERATED FILE. DO NOT MODIFY.
2447
- */
2448
- function install$1(registers) {
2449
- registers.registerComponentView(BrushView);
2450
- registers.registerComponentModel(BrushModel);
2451
- registers.registerPreprocessor(brushPreprocessor);
2452
- registers.registerVisual(registers.PRIORITY.VISUAL.BRUSH, brushVisual);
2453
- registers.registerAction({
2454
- type: "brush",
2455
- event: "brush",
2456
- update: "updateVisual"
2457
- }, function (payload, ecModel) {
2458
- ecModel.eachComponent({
2459
- mainType: "brush",
2460
- query: payload
2461
- }, function (brushModel) {
2462
- brushModel.setAreas(payload.areas);
2463
- });
2464
- });
2465
- /**
2466
- * payload: {
2467
- * brushComponents: [
2468
- * {
2469
- * brushId,
2470
- * brushIndex,
2471
- * brushName,
2472
- * series: [
2473
- * {
2474
- * seriesId,
2475
- * seriesIndex,
2476
- * seriesName,
2477
- * rawIndices: [21, 34, ...]
2478
- * },
2479
- * ...
2480
- * ]
2481
- * },
2482
- * ...
2483
- * ]
2484
- * }
2485
- */
2486
- registers.registerAction({
2487
- type: "brushSelect",
2488
- event: "brushSelected",
2489
- update: "none"
2490
- }, noop);
2491
- registers.registerAction({
2492
- type: "brushEnd",
2493
- event: "brushEnd",
2494
- update: "none"
2495
- }, noop);
2496
- registerFeature("brush", BrushFeature);
2497
- }
2498
-
2499
- //#endregion
2500
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/title/install.js
2501
- /**
2502
- * AUTO-GENERATED FILE. DO NOT MODIFY.
2503
- */
2504
-
2505
- function install$15(registers) {
2506
- registers.registerComponentModel(TitleModel);
2507
- registers.registerComponentView(TitleView);
2508
- }
2509
-
2510
- //#endregion
2511
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/timeline/TimelineModel.js
2512
- /**
2513
- * AUTO-GENERATED FILE. DO NOT MODIFY.
2514
- */
2515
-
2516
- function createScaleByModel(model, axisType) {
2517
- axisType = axisType || model.get("type");
2518
- if (axisType) switch (axisType) {
2519
- case "category":
2520
- return new OrdinalScale({
2521
- ordinalMeta: model.getCategories(),
2522
- extent: [Infinity, -Infinity]
2523
- });
2524
- case "time":
2525
- return new TimeScale({
2526
- locale: model.ecModel.getLocaleModel(),
2527
- useUTC: model.ecModel.get("useUTC")
2528
- });
2529
- default:
2530
- return new IntervalScale();
2531
- }
2532
- }
2533
- function getViewRect(model, api) {
2534
- return getLayoutRect(model.getBoxLayoutParams(), createBoxLayoutReference(model, api).refContainer, model.get("padding"));
2535
- }
2536
- function makeControlIcon(timelineModel, objPath, rect, opts) {
2537
- var style = opts.style;
2538
- var icon = createIcon(timelineModel.get(["controlStyle", objPath]), opts || {}, new BoundingRect(rect[0], rect[1], rect[2], rect[3]));
2539
- if (style) icon.setStyle(style);
2540
- return icon;
2541
- }
2542
- /**
2543
- * Create symbol or update symbol
2544
- * opt: basic position and event handlers
2545
- */
2546
- function giveSymbol(hostModel, itemStyleModel, group, opt, symbol, callback) {
2547
- var color = itemStyleModel.get("color");
2548
- if (!symbol) {
2549
- symbol = createSymbol(hostModel.get("symbol"), -1, -1, 2, 2, color);
2550
- symbol.setStyle("strokeNoScale", true);
2551
- group.add(symbol);
2552
- callback && callback.onCreate(symbol);
2553
- } else {
2554
- symbol.setColor(color);
2555
- group.add(symbol);
2556
- callback && callback.onUpdate(symbol);
2557
- }
2558
- var itemStyle = itemStyleModel.getItemStyle(["color"]);
2559
- symbol.setStyle(itemStyle);
2560
- opt = merge({
2561
- rectHover: true,
2562
- z2: 100
2563
- }, opt, true);
2564
- var symbolSize = normalizeSymbolSize(hostModel.get("symbolSize"));
2565
- opt.scaleX = symbolSize[0] / 2;
2566
- opt.scaleY = symbolSize[1] / 2;
2567
- var symbolOffset = normalizeSymbolOffset(hostModel.get("symbolOffset"), symbolSize);
2568
- if (symbolOffset) {
2569
- opt.x = (opt.x || 0) + symbolOffset[0];
2570
- opt.y = (opt.y || 0) + symbolOffset[1];
2571
- }
2572
- var symbolRotate = hostModel.get("symbolRotate");
2573
- opt.rotation = (symbolRotate || 0) * Math.PI / 180 || 0;
2574
- symbol.attr(opt);
2575
- symbol.updateTransform();
2576
- return symbol;
2577
- }
2578
- function pointerMoveTo(pointer, progressLine, dataIndex, axis, timelineModel, noAnimation) {
2579
- if (pointer.dragging) return;
2580
- var pointerModel = timelineModel.getModel("checkpointStyle");
2581
- var toCoord = axis.dataToCoord(timelineModel.getData().get("value", dataIndex));
2582
- if (noAnimation || !pointerModel.get("animation", true)) {
2583
- pointer.attr({
2584
- x: toCoord,
2585
- y: 0
2586
- });
2587
- progressLine && progressLine.attr({
2588
- shape: {
2589
- x2: toCoord
2590
- }
2591
- });
2592
- } else {
2593
- var animationCfg = {
2594
- duration: pointerModel.get("animationDuration", true),
2595
- easing: pointerModel.get("animationEasing", true)
2596
- };
2597
- pointer.stopAnimation(null, true);
2598
- pointer.animateTo({
2599
- x: toCoord,
2600
- y: 0
2601
- }, animationCfg);
2602
- progressLine && progressLine.animateTo({
2603
- shape: {
2604
- x2: toCoord
2605
- }
2606
- }, animationCfg);
2607
- }
2608
- }
2609
-
2610
- //#endregion
2611
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/timeline/timelineAction.js
2612
- /**
2613
- * AUTO-GENERATED FILE. DO NOT MODIFY.
2614
- */
2615
- function installTimelineAction(registers) {
2616
- registers.registerAction({
2617
- type: "timelineChange",
2618
- event: "timelineChanged",
2619
- update: "prepareAndUpdate"
2620
- }, function (payload, ecModel, api) {
2621
- var timelineModel = ecModel.getComponent("timeline");
2622
- if (timelineModel && payload.currentIndex != null) {
2623
- timelineModel.setCurrentIndex(payload.currentIndex);
2624
- if (!timelineModel.get("loop", true) && timelineModel.isIndexMax() && timelineModel.getPlayState()) {
2625
- timelineModel.setPlayState(false);
2626
- api.dispatchAction({
2627
- type: "timelinePlayChange",
2628
- playState: false,
2629
- from: payload.from
2630
- });
2631
- }
2632
- }
2633
- ecModel.resetOption("timeline", {
2634
- replaceMerge: timelineModel.get("replaceMerge", true)
2635
- });
2636
- return defaults({
2637
- currentIndex: timelineModel.option.currentIndex
2638
- }, payload);
2639
- });
2640
- registers.registerAction({
2641
- type: "timelinePlayChange",
2642
- event: "timelinePlayChanged",
2643
- update: "update"
2644
- }, function (payload, ecModel) {
2645
- var timelineModel = ecModel.getComponent("timeline");
2646
- if (timelineModel && payload.playState != null) timelineModel.setPlayState(payload.playState);
2647
- });
2648
- }
2649
-
2650
- //#endregion
2651
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/timeline/preprocessor.js
2652
- /**
2653
- * AUTO-GENERATED FILE. DO NOT MODIFY.
2654
- */
2655
- function timelinePreprocessor(option) {
2656
- var timelineOpt = option && option.timeline;
2657
- if (!isArray$1(timelineOpt)) timelineOpt = timelineOpt ? [timelineOpt] : [];
2658
- each$9(timelineOpt, function (opt) {
2659
- if (!opt) return;
2660
- compatibleEC2(opt);
2661
- });
2662
- }
2663
- function compatibleEC2(opt) {
2664
- var type = opt.type;
2665
- var ec2Types = {
2666
- "number": "value",
2667
- "time": "time"
2668
- };
2669
- if (ec2Types[type]) {
2670
- opt.axisType = ec2Types[type];
2671
- delete opt.type;
2672
- }
2673
- transferItem(opt);
2674
- if (has$1(opt, "controlPosition")) {
2675
- var controlStyle = opt.controlStyle || (opt.controlStyle = {});
2676
- if (!has$1(controlStyle, "position")) controlStyle.position = opt.controlPosition;
2677
- if (controlStyle.position === "none" && !has$1(controlStyle, "show")) {
2678
- controlStyle.show = false;
2679
- delete controlStyle.position;
2680
- }
2681
- delete opt.controlPosition;
2682
- }
2683
- each$9(opt.data || [], function (dataItem) {
2684
- if (isObject(dataItem) && !isArray$1(dataItem)) {
2685
- if (!has$1(dataItem, "value") && has$1(dataItem, "name")) dataItem.value = dataItem.name;
2686
- transferItem(dataItem);
2687
- }
2688
- });
2689
- }
2690
- function transferItem(opt) {
2691
- var itemStyle = opt.itemStyle || (opt.itemStyle = {});
2692
- var itemStyleEmphasis = itemStyle.emphasis || (itemStyle.emphasis = {});
2693
- var label = opt.label || opt.label || {};
2694
- var labelNormal = label.normal || (label.normal = {});
2695
- var excludeLabelAttr = {
2696
- normal: 1,
2697
- emphasis: 1
2698
- };
2699
- each$9(label, function (value, name) {
2700
- if (!excludeLabelAttr[name] && !has$1(labelNormal, name)) labelNormal[name] = value;
2701
- });
2702
- if (itemStyleEmphasis.label && !has$1(label, "emphasis")) {
2703
- label.emphasis = itemStyleEmphasis.label;
2704
- delete itemStyleEmphasis.label;
2705
- }
2706
- }
2707
- function has$1(obj, attr) {
2708
- return obj.hasOwnProperty(attr);
2709
- }
2710
-
2711
- //#endregion
2712
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/timeline/install.js
2713
- /**
2714
- * AUTO-GENERATED FILE. DO NOT MODIFY.
2715
- */
2716
- function install$14(registers) {
2717
- registers.registerComponentModel(SliderTimelineModel);
2718
- registers.registerComponentView(SliderTimelineView);
2719
- registers.registerSubTypeDefaulter("timeline", function () {
2720
- return "slider";
2721
- });
2722
- installTimelineAction(registers);
2723
- registers.registerPreprocessor(timelinePreprocessor);
2724
- }
2725
-
2726
- //#endregion
2727
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/marker/checkMarkerInSeries.js
2728
- /**
2729
- * AUTO-GENERATED FILE. DO NOT MODIFY.
2730
- */
2731
- function checkMarkerInSeries(seriesOpts, markerType) {
2732
- if (!seriesOpts) return false;
2733
- var seriesOptArr = isArray$1(seriesOpts) ? seriesOpts : [seriesOpts];
2734
- for (var idx = 0; idx < seriesOptArr.length; idx++) if (seriesOptArr[idx] && seriesOptArr[idx][markerType]) return true;
2735
- return false;
2736
- }
2737
-
2738
- //#endregion
2739
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/marker/MarkerModel.js
2740
- /**
2741
- * AUTO-GENERATED FILE. DO NOT MODIFY.
2742
- */
2743
- function fillLabel(opt) {
2744
- defaultEmphasis(opt, "label", ["show"]);
2745
- }
2746
- //#endregion
2747
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/marker/markerHelper.js
2748
- /**
2749
- * AUTO-GENERATED FILE. DO NOT MODIFY.
2750
- */
2751
- function hasXOrY(item) {
2752
- return !(isNaN(parseFloat(item.x)) && isNaN(parseFloat(item.y)));
2753
- }
2754
- function hasXAndY(item) {
2755
- return !isNaN(parseFloat(item.x)) && !isNaN(parseFloat(item.y));
2756
- }
2757
- function markerTypeCalculatorWithExtent(markerType, data, axisDim, otherDataDim, targetDataDim, otherCoordIndex, targetCoordIndex) {
2758
- var coordArr = [];
2759
- var calcDataDim = isDimensionStacked(data, targetDataDim) ? data.getCalculationInfo("stackResultDimension") : targetDataDim;
2760
- var value = numCalculate(data, calcDataDim, markerType);
2761
- var dataIndex = data.hostModel.indicesOfNearest(axisDim, calcDataDim, value)[0];
2762
- coordArr[otherCoordIndex] = data.get(otherDataDim, dataIndex);
2763
- coordArr[targetCoordIndex] = data.get(calcDataDim, dataIndex);
2764
- var coordArrValue = data.get(targetDataDim, dataIndex);
2765
- var precision = getPrecision(data.get(targetDataDim, dataIndex));
2766
- precision = Math.min(precision, 20);
2767
- if (precision >= 0) coordArr[targetCoordIndex] = +coordArr[targetCoordIndex].toFixed(precision);
2768
- return [coordArr, coordArrValue];
2769
- }
2770
- /**
2771
- * Transform markPoint data item to format used in List by do the following
2772
- * 1. Calculate statistic like `max`, `min`, `average`
2773
- * 2. Convert `item.xAxis`, `item.yAxis` to `item.coord` array
2774
- */
2775
- function dataTransform(seriesModel, item) {
2776
- if (!item) return;
2777
- var data = seriesModel.getData();
2778
- var coordSys = seriesModel.coordinateSystem;
2779
- var dims = coordSys && coordSys.dimensions;
2780
- if (!hasXAndY(item) && !isArray$1(item.coord) && isArray$1(dims)) {
2781
- var axisInfo = getAxisInfo(item, data, coordSys, seriesModel);
2782
- item = clone$1(item);
2783
- if (item.type && markerTypeCalculator[item.type] && axisInfo.baseAxis && axisInfo.valueAxis) {
2784
- var otherCoordIndex = indexOf(dims, axisInfo.baseAxis.dim);
2785
- var targetCoordIndex = indexOf(dims, axisInfo.valueAxis.dim);
2786
- var coordInfo = markerTypeCalculator[item.type](data, axisInfo.valueAxis.dim, axisInfo.baseDataDim, axisInfo.valueDataDim, otherCoordIndex, targetCoordIndex);
2787
- item.coord = coordInfo[0];
2788
- item.value = coordInfo[1];
2789
- } else item.coord = [item.xAxis != null ? item.xAxis : item.radiusAxis, item.yAxis != null ? item.yAxis : item.angleAxis];
2790
- }
2791
- if (item.coord == null || !isArray$1(dims)) {
2792
- item.coord = [];
2793
- var baseAxis = seriesModel.getBaseAxis();
2794
- if (baseAxis && item.type && markerTypeCalculator[item.type]) {
2795
- var otherAxis = coordSys.getOtherAxis(baseAxis);
2796
- if (otherAxis) item.value = numCalculate(data, data.mapDimension(otherAxis.dim), item.type);
2797
- }
2798
- } else {
2799
- var coord = item.coord;
2800
- for (var i = 0; i < 2; i++) if (markerTypeCalculator[coord[i]]) coord[i] = numCalculate(data, data.mapDimension(dims[i]), coord[i]);
2801
- }
2802
- return item;
2803
- }
2804
- function getAxisInfo(item, data, coordSys, seriesModel) {
2805
- var ret = {};
2806
- if (item.valueIndex != null || item.valueDim != null) {
2807
- ret.valueDataDim = item.valueIndex != null ? data.getDimension(item.valueIndex) : item.valueDim;
2808
- ret.valueAxis = coordSys.getAxis(dataDimToCoordDim(seriesModel, ret.valueDataDim));
2809
- ret.baseAxis = coordSys.getOtherAxis(ret.valueAxis);
2810
- ret.baseDataDim = data.mapDimension(ret.baseAxis.dim);
2811
- } else {
2812
- ret.baseAxis = seriesModel.getBaseAxis();
2813
- ret.valueAxis = coordSys.getOtherAxis(ret.baseAxis);
2814
- ret.baseDataDim = data.mapDimension(ret.baseAxis.dim);
2815
- ret.valueDataDim = data.mapDimension(ret.valueAxis.dim);
2816
- }
2817
- return ret;
2818
- }
2819
- function dataDimToCoordDim(seriesModel, dataDim) {
2820
- var dimItem = seriesModel.getData().getDimensionInfo(dataDim);
2821
- return dimItem && dimItem.coordDim;
2822
- }
2823
- /**
2824
- * Filter data which is out of coordinateSystem range
2825
- * [dataFilter description]
2826
- */
2827
- function dataFilter(coordSys, item) {
2828
- return coordSys && coordSys.containData && item.coord && !hasXOrY(item) ? coordSys.containData(item.coord) : true;
2829
- }
2830
- function zoneFilter(coordSys, item1, item2) {
2831
- return coordSys && coordSys.containZone && item1.coord && item2.coord && !hasXOrY(item1) && !hasXOrY(item2) ? coordSys.containZone(item1.coord, item2.coord) : true;
2832
- }
2833
- function createMarkerDimValueGetter(inCoordSys, dims) {
2834
- return inCoordSys ? function (item, dimName, dataIndex, dimIndex) {
2835
- return parseDataValue(dimIndex < 2 ? item.coord && item.coord[dimIndex] : item.value, dims[dimIndex]);
2836
- } : function (item, dimName, dataIndex, dimIndex) {
2837
- return parseDataValue(item.value, dims[dimIndex]);
2838
- };
2839
- }
2840
- function numCalculate(data, valueDataDim, type) {
2841
- if (type === "average") {
2842
- var sum_1 = 0;
2843
- var count_1 = 0;
2844
- data.each(valueDataDim, function (val, idx) {
2845
- if (!isNaN(val)) {
2846
- sum_1 += val;
2847
- count_1++;
2848
- }
2849
- });
2850
- return sum_1 / count_1;
2851
- } else if (type === "median") return data.getMedian(valueDataDim);else return data.getDataExtent(valueDataDim)[type === "max" ? 1 : 0];
2852
- }
2853
-
2854
- //#endregion
2855
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/marker/MarkerView.js
2856
- /**
2857
- * AUTO-GENERATED FILE. DO NOT MODIFY.
2858
- */
2859
-
2860
- function updateZ(ecModel, markerGroupMap, type) {
2861
- ecModel.eachSeries(function (seriesModel) {
2862
- var markerModel = MarkerModel.getMarkerModelFromSeries(seriesModel, type);
2863
- var markerDraw = markerGroupMap.get(seriesModel.id);
2864
- if (markerModel && markerDraw && markerDraw.group) {
2865
- var _a = retrieveZInfo(markerModel),
2866
- z = _a.z,
2867
- zlevel = _a.zlevel;
2868
- traverseUpdateZ(markerDraw.group, z, zlevel);
2869
- }
2870
- });
2871
- }
2872
-
2873
- //#endregion
2874
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/marker/MarkPointView.js
2875
- /**
2876
- * AUTO-GENERATED FILE. DO NOT MODIFY.
2877
- */
2878
- function updateMarkerLayout(mpData, seriesModel, api) {
2879
- var coordSys = seriesModel.coordinateSystem;
2880
- var apiWidth = api.getWidth();
2881
- var apiHeight = api.getHeight();
2882
- var coordRect = coordSys && coordSys.getArea && coordSys.getArea();
2883
- mpData.each(function (idx) {
2884
- var itemModel = mpData.getItemModel(idx);
2885
- var isRelativeToCoordinate = itemModel.get("relativeTo") === "coordinate";
2886
- var width = isRelativeToCoordinate ? coordRect ? coordRect.width : 0 : apiWidth;
2887
- var height = isRelativeToCoordinate ? coordRect ? coordRect.height : 0 : apiHeight;
2888
- var left = isRelativeToCoordinate && coordRect ? coordRect.x : 0;
2889
- var top = isRelativeToCoordinate && coordRect ? coordRect.y : 0;
2890
- var point;
2891
- var xPx = parsePercent$1(itemModel.get("x"), width) + left;
2892
- var yPx = parsePercent$1(itemModel.get("y"), height) + top;
2893
- if (!isNaN(xPx) && !isNaN(yPx)) point = [xPx, yPx];else if (seriesModel.getMarkerPosition) point = seriesModel.getMarkerPosition(mpData.getValues(mpData.dimensions, idx));else if (coordSys) {
2894
- var x = mpData.get(coordSys.dimensions[0], idx);
2895
- var y = mpData.get(coordSys.dimensions[1], idx);
2896
- point = coordSys.dataToPoint([x, y]);
2897
- }
2898
- if (!isNaN(xPx)) point[0] = xPx;
2899
- if (!isNaN(yPx)) point[1] = yPx;
2900
- mpData.setItemLayout(idx, point);
2901
- });
2902
- }
2903
- function createData(coordSys, seriesModel, mpModel) {
2904
- var coordDimsInfos;
2905
- if (coordSys) coordDimsInfos = map(coordSys && coordSys.dimensions, function (coordDim) {
2906
- return extend(extend({}, seriesModel.getData().getDimensionInfo(seriesModel.getData().mapDimension(coordDim)) || {}), {
2907
- name: coordDim,
2908
- ordinalMeta: null
2909
- });
2910
- });else coordDimsInfos = [{
2911
- name: "value",
2912
- type: "float"
2913
- }];
2914
- var mpData = new SeriesData(coordDimsInfos, mpModel);
2915
- var dataOpt = map(mpModel.get("data"), curry$1(dataTransform, seriesModel));
2916
- if (coordSys) dataOpt = filter(dataOpt, curry$1(dataFilter, coordSys));
2917
- var dimValueGetter = createMarkerDimValueGetter(!!coordSys, coordDimsInfos);
2918
- mpData.initData(dataOpt, null, dimValueGetter);
2919
- return mpData;
2920
- }
2921
-
2922
- //#endregion
2923
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/marker/installMarkPoint.js
2924
- /**
2925
- * AUTO-GENERATED FILE. DO NOT MODIFY.
2926
- */
2927
- function install$11(registers) {
2928
- registers.registerComponentModel(MarkPointModel);
2929
- registers.registerComponentView(MarkPointView);
2930
- registers.registerPreprocessor(function (opt) {
2931
- if (checkMarkerInSeries(opt.series, "markPoint")) opt.markPoint = opt.markPoint || {};
2932
- });
2933
- }
2934
-
2935
- //#endregion
2936
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/marker/MarkLineModel.js
2937
- /**
2938
- * AUTO-GENERATED FILE. DO NOT MODIFY.
2939
- */
2940
-
2941
- function isInfinity$1(val) {
2942
- return !isNaN(val) && !isFinite(val);
2943
- }
2944
- function ifMarkLineHasOnlyDim(dimIndex, fromCoord, toCoord, coordSys) {
2945
- var otherDimIndex = 1 - dimIndex;
2946
- var dimName = coordSys.dimensions[dimIndex];
2947
- return isInfinity$1(fromCoord[otherDimIndex]) && isInfinity$1(toCoord[otherDimIndex]) && fromCoord[dimIndex] === toCoord[dimIndex] && coordSys.getAxis(dimName).containData(fromCoord[dimIndex]);
2948
- }
2949
- function markLineFilter(coordSys, item) {
2950
- if (coordSys.type === "cartesian2d") {
2951
- var fromCoord = item[0].coord;
2952
- var toCoord = item[1].coord;
2953
- if (fromCoord && toCoord && (ifMarkLineHasOnlyDim(1, fromCoord, toCoord, coordSys) || ifMarkLineHasOnlyDim(0, fromCoord, toCoord, coordSys))) return true;
2954
- }
2955
- return dataFilter(coordSys, item[0]) && dataFilter(coordSys, item[1]);
2956
- }
2957
- function updateSingleMarkerEndLayout(data, idx, isFrom, seriesModel, api) {
2958
- var coordSys = seriesModel.coordinateSystem;
2959
- var itemModel = data.getItemModel(idx);
2960
- var point;
2961
- var xPx = parsePercent$1(itemModel.get("x"), api.getWidth());
2962
- var yPx = parsePercent$1(itemModel.get("y"), api.getHeight());
2963
- if (!isNaN(xPx) && !isNaN(yPx)) point = [xPx, yPx];else {
2964
- if (seriesModel.getMarkerPosition) point = seriesModel.getMarkerPosition(data.getValues(data.dimensions, idx));else {
2965
- var dims = coordSys.dimensions;
2966
- var x = data.get(dims[0], idx);
2967
- var y = data.get(dims[1], idx);
2968
- point = coordSys.dataToPoint([x, y]);
2969
- }
2970
- if (isCoordinateSystemType(coordSys, "cartesian2d")) {
2971
- var xAxis = coordSys.getAxis("x");
2972
- var yAxis = coordSys.getAxis("y");
2973
- var dims = coordSys.dimensions;
2974
- if (isInfinity$1(data.get(dims[0], idx))) point[0] = xAxis.toGlobalCoord(xAxis.getExtent()[isFrom ? 0 : 1]);else if (isInfinity$1(data.get(dims[1], idx))) point[1] = yAxis.toGlobalCoord(yAxis.getExtent()[isFrom ? 0 : 1]);
2975
- }
2976
- if (!isNaN(xPx)) point[0] = xPx;
2977
- if (!isNaN(yPx)) point[1] = yPx;
2978
- }
2979
- data.setItemLayout(idx, point);
2980
- }
2981
- function createList$1(coordSys, seriesModel, mlModel) {
2982
- var coordDimsInfos;
2983
- if (coordSys) coordDimsInfos = map(coordSys && coordSys.dimensions, function (coordDim) {
2984
- return extend(extend({}, seriesModel.getData().getDimensionInfo(seriesModel.getData().mapDimension(coordDim)) || {}), {
2985
- name: coordDim,
2986
- ordinalMeta: null
2987
- });
2988
- });else coordDimsInfos = [{
2989
- name: "value",
2990
- type: "float"
2991
- }];
2992
- var fromData = new SeriesData(coordDimsInfos, mlModel);
2993
- var toData = new SeriesData(coordDimsInfos, mlModel);
2994
- var lineData = new SeriesData([], mlModel);
2995
- var optData = map(mlModel.get("data"), curry$1(markLineTransform, seriesModel, coordSys, mlModel));
2996
- if (coordSys) optData = filter(optData, curry$1(markLineFilter, coordSys));
2997
- var dimValueGetter = createMarkerDimValueGetter(!!coordSys, coordDimsInfos);
2998
- fromData.initData(map(optData, function (item) {
2999
- return item[0];
3000
- }), null, dimValueGetter);
3001
- toData.initData(map(optData, function (item) {
3002
- return item[1];
3003
- }), null, dimValueGetter);
3004
- lineData.initData(map(optData, function (item) {
3005
- return item[2];
3006
- }));
3007
- lineData.hasItemOption = true;
3008
- return {
3009
- from: fromData,
3010
- to: toData,
3011
- line: lineData
3012
- };
3013
- }
3014
-
3015
- //#endregion
3016
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/marker/installMarkLine.js
3017
- /**
3018
- * AUTO-GENERATED FILE. DO NOT MODIFY.
3019
- */
3020
- function install$10(registers) {
3021
- registers.registerComponentModel(MarkLineModel);
3022
- registers.registerComponentView(MarkLineView);
3023
- registers.registerPreprocessor(function (opt) {
3024
- if (checkMarkerInSeries(opt.series, "markLine")) opt.markLine = opt.markLine || {};
3025
- });
3026
- }
3027
-
3028
- //#endregion
3029
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/marker/MarkAreaModel.js
3030
- /**
3031
- * AUTO-GENERATED FILE. DO NOT MODIFY.
3032
- */
3033
-
3034
- function isInfinity(val) {
3035
- return !isNaN(val) && !isFinite(val);
3036
- }
3037
- function ifMarkAreaHasOnlyDim(dimIndex, fromCoord, toCoord, coordSys) {
3038
- var otherDimIndex = 1 - dimIndex;
3039
- return isInfinity(fromCoord[otherDimIndex]) && isInfinity(toCoord[otherDimIndex]);
3040
- }
3041
- function markAreaFilter(coordSys, item) {
3042
- var fromCoord = item.coord[0];
3043
- var toCoord = item.coord[1];
3044
- var item0 = {
3045
- coord: fromCoord,
3046
- x: item.x0,
3047
- y: item.y0
3048
- };
3049
- var item1 = {
3050
- coord: toCoord,
3051
- x: item.x1,
3052
- y: item.y1
3053
- };
3054
- if (isCoordinateSystemType(coordSys, "cartesian2d")) {
3055
- if (fromCoord && toCoord && (ifMarkAreaHasOnlyDim(1, fromCoord, toCoord, coordSys) || ifMarkAreaHasOnlyDim(0, fromCoord, toCoord, coordSys))) return true;
3056
- return zoneFilter(coordSys, item0, item1);
3057
- }
3058
- return dataFilter(coordSys, item0) || dataFilter(coordSys, item1);
3059
- }
3060
- function getSingleMarkerEndPoint(data, idx, dims, seriesModel, api) {
3061
- var coordSys = seriesModel.coordinateSystem;
3062
- var itemModel = data.getItemModel(idx);
3063
- var point;
3064
- var xPx = parsePercent$1(itemModel.get(dims[0]), api.getWidth());
3065
- var yPx = parsePercent$1(itemModel.get(dims[1]), api.getHeight());
3066
- if (!isNaN(xPx) && !isNaN(yPx)) point = [xPx, yPx];else {
3067
- if (seriesModel.getMarkerPosition) {
3068
- var pointValue0 = data.getValues(["x0", "y0"], idx);
3069
- var pointValue1 = data.getValues(["x1", "y1"], idx);
3070
- var clampPointValue0 = coordSys.clampData(pointValue0);
3071
- var clampPointValue1 = coordSys.clampData(pointValue1);
3072
- var pointValue = [];
3073
- if (dims[0] === "x0") pointValue[0] = clampPointValue0[0] > clampPointValue1[0] ? pointValue1[0] : pointValue0[0];else pointValue[0] = clampPointValue0[0] > clampPointValue1[0] ? pointValue0[0] : pointValue1[0];
3074
- if (dims[1] === "y0") pointValue[1] = clampPointValue0[1] > clampPointValue1[1] ? pointValue1[1] : pointValue0[1];else pointValue[1] = clampPointValue0[1] > clampPointValue1[1] ? pointValue0[1] : pointValue1[1];
3075
- point = seriesModel.getMarkerPosition(pointValue, dims, true);
3076
- } else {
3077
- var x = data.get(dims[0], idx);
3078
- var y = data.get(dims[1], idx);
3079
- var pt = [x, y];
3080
- coordSys.clampData && coordSys.clampData(pt, pt);
3081
- point = coordSys.dataToPoint(pt, true);
3082
- }
3083
- if (isCoordinateSystemType(coordSys, "cartesian2d")) {
3084
- var xAxis = coordSys.getAxis("x");
3085
- var yAxis = coordSys.getAxis("y");
3086
- var x = data.get(dims[0], idx);
3087
- var y = data.get(dims[1], idx);
3088
- if (isInfinity(x)) point[0] = xAxis.toGlobalCoord(xAxis.getExtent()[dims[0] === "x0" ? 0 : 1]);else if (isInfinity(y)) point[1] = yAxis.toGlobalCoord(yAxis.getExtent()[dims[1] === "y0" ? 0 : 1]);
3089
- }
3090
- if (!isNaN(xPx)) point[0] = xPx;
3091
- if (!isNaN(yPx)) point[1] = yPx;
3092
- }
3093
- return point;
3094
- }
3095
- function createList(coordSys, seriesModel, maModel) {
3096
- var areaData;
3097
- var dataDims;
3098
- var dims = ["x0", "y0", "x1", "y1"];
3099
- if (coordSys) {
3100
- var coordDimsInfos_1 = map(coordSys && coordSys.dimensions, function (coordDim) {
3101
- var data = seriesModel.getData();
3102
- return extend(extend({}, data.getDimensionInfo(data.mapDimension(coordDim)) || {}), {
3103
- name: coordDim,
3104
- ordinalMeta: null
3105
- });
3106
- });
3107
- dataDims = map(dims, function (dim, idx) {
3108
- return {
3109
- name: dim,
3110
- type: coordDimsInfos_1[idx % 2].type
3111
- };
3112
- });
3113
- areaData = new SeriesData(dataDims, maModel);
3114
- } else {
3115
- dataDims = [{
3116
- name: "value",
3117
- type: "float"
3118
- }];
3119
- areaData = new SeriesData(dataDims, maModel);
3120
- }
3121
- var optData = map(maModel.get("data"), curry$1(markAreaTransform, seriesModel, coordSys, maModel));
3122
- if (coordSys) optData = filter(optData, curry$1(markAreaFilter, coordSys));
3123
- var dimValueGetter = coordSys ? function (item, dimName, dataIndex, dimIndex) {
3124
- var rawVal = item.coord[Math.floor(dimIndex / 2)][dimIndex % 2];
3125
- return parseDataValue(rawVal, dataDims[dimIndex]);
3126
- } : function (item, dimName, dataIndex, dimIndex) {
3127
- return parseDataValue(item.value, dataDims[dimIndex]);
3128
- };
3129
- areaData.initData(optData, null, dimValueGetter);
3130
- areaData.hasItemOption = true;
3131
- return areaData;
3132
- }
3133
-
3134
- //#endregion
3135
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/marker/installMarkArea.js
3136
- /**
3137
- * AUTO-GENERATED FILE. DO NOT MODIFY.
3138
- */
3139
- function install$9(registers) {
3140
- registers.registerComponentModel(MarkAreaModel);
3141
- registers.registerComponentView(MarkAreaView);
3142
- registers.registerPreprocessor(function (opt) {
3143
- if (checkMarkerInSeries(opt.series, "markArea")) opt.markArea = opt.markArea || {};
3144
- });
3145
- }
3146
-
3147
- //#endregion
3148
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/legend/LegendModel.js
3149
- /**
3150
- * AUTO-GENERATED FILE. DO NOT MODIFY.
3151
- */
3152
-
3153
- function getLegendStyle(iconType, legendItemModel, lineVisualStyle, itemVisualStyle, drawType, isSelected, api) {
3154
- /**
3155
- * Use series style if is inherit;
3156
- * elsewise, use legend style
3157
- */
3158
- function handleCommonProps(style, visualStyle) {
3159
- if (style.lineWidth === "auto") style.lineWidth = visualStyle.lineWidth > 0 ? 2 : 0;
3160
- each$3(style, function (propVal, propName) {
3161
- style[propName] === "inherit" && (style[propName] = visualStyle[propName]);
3162
- });
3163
- }
3164
- var itemStyleModel = legendItemModel.getModel("itemStyle");
3165
- var itemStyle = itemStyleModel.getItemStyle();
3166
- var iconBrushType = iconType.lastIndexOf("empty", 0) === 0 ? "fill" : "stroke";
3167
- var decalStyle = itemStyleModel.getShallow("decal");
3168
- itemStyle.decal = !decalStyle || decalStyle === "inherit" ? itemVisualStyle.decal : createOrUpdatePatternFromDecal(decalStyle, api);
3169
- if (itemStyle.fill === "inherit")
3170
- /**
3171
- * Series with visualDrawType as 'stroke' should have
3172
- * series stroke as legend fill
3173
- */
3174
- itemStyle.fill = itemVisualStyle[drawType];
3175
- if (itemStyle.stroke === "inherit")
3176
- /**
3177
- * icon type with "emptyXXX" should use fill color
3178
- * in visual style
3179
- */
3180
- itemStyle.stroke = itemVisualStyle[iconBrushType];
3181
- if (itemStyle.opacity === "inherit")
3182
- /**
3183
- * Use lineStyle.opacity if drawType is stroke
3184
- */
3185
- itemStyle.opacity = (drawType === "fill" ? itemVisualStyle : lineVisualStyle).opacity;
3186
- handleCommonProps(itemStyle, itemVisualStyle);
3187
- var legendLineModel = legendItemModel.getModel("lineStyle");
3188
- var lineStyle = legendLineModel.getLineStyle();
3189
- handleCommonProps(lineStyle, lineVisualStyle);
3190
- itemStyle.fill === "auto" && (itemStyle.fill = itemVisualStyle.fill);
3191
- itemStyle.stroke === "auto" && (itemStyle.stroke = itemVisualStyle.fill);
3192
- lineStyle.stroke === "auto" && (lineStyle.stroke = itemVisualStyle.fill);
3193
- if (!isSelected) {
3194
- var borderWidth = legendItemModel.get("inactiveBorderWidth");
3195
- /**
3196
- * Since stroke is set to be inactiveBorderColor, it may occur that
3197
- * there is no border in series but border in legend, so we need to
3198
- * use border only when series has border if is set to be auto
3199
- */
3200
- var visualHasBorder = itemStyle[iconBrushType];
3201
- itemStyle.lineWidth = borderWidth === "auto" ? itemVisualStyle.lineWidth > 0 && visualHasBorder ? 2 : 0 : itemStyle.lineWidth;
3202
- itemStyle.fill = legendItemModel.get("inactiveColor");
3203
- itemStyle.stroke = legendItemModel.get("inactiveBorderColor");
3204
- lineStyle.stroke = legendLineModel.get("inactiveColor");
3205
- lineStyle.lineWidth = legendLineModel.get("inactiveWidth");
3206
- }
3207
- return {
3208
- itemStyle,
3209
- lineStyle
3210
- };
3211
- }
3212
- function getDefaultLegendIcon(opt) {
3213
- var symboType = opt.icon || "roundRect";
3214
- var icon = createSymbol(symboType, 0, 0, opt.itemWidth, opt.itemHeight, opt.itemStyle.fill, opt.symbolKeepAspect);
3215
- icon.setStyle(opt.itemStyle);
3216
- icon.rotation = (opt.iconRotate || 0) * Math.PI / 180;
3217
- icon.setOrigin([opt.itemWidth / 2, opt.itemHeight / 2]);
3218
- if (symboType.indexOf("empty") > -1) {
3219
- icon.style.stroke = icon.style.fill;
3220
- icon.style.fill = tokens.color.neutral00;
3221
- icon.style.lineWidth = 2;
3222
- }
3223
- return icon;
3224
- }
3225
- function dispatchSelectAction(seriesName, dataName, api, excludeSeriesId) {
3226
- dispatchDownplayAction(seriesName, dataName, api, excludeSeriesId);
3227
- api.dispatchAction({
3228
- type: "legendToggleSelect",
3229
- name: seriesName != null ? seriesName : dataName
3230
- });
3231
- dispatchHighlightAction(seriesName, dataName, api, excludeSeriesId);
3232
- }
3233
- function isUseHoverLayer(api) {
3234
- var list = api.getZr().storage.getDisplayList();
3235
- var emphasisState;
3236
- var i = 0;
3237
- var len = list.length;
3238
- while (i < len && !(emphasisState = list[i].states.emphasis)) i++;
3239
- return emphasisState && emphasisState.hoverLayer;
3240
- }
3241
- function dispatchHighlightAction(seriesName, dataName, api, excludeSeriesId) {
3242
- if (!isUseHoverLayer(api)) api.dispatchAction({
3243
- type: "highlight",
3244
- seriesName,
3245
- name: dataName,
3246
- excludeSeriesId
3247
- });
3248
- }
3249
- function dispatchDownplayAction(seriesName, dataName, api, excludeSeriesId) {
3250
- if (!isUseHoverLayer(api)) api.dispatchAction({
3251
- type: "downplay",
3252
- seriesName,
3253
- name: dataName,
3254
- excludeSeriesId
3255
- });
3256
- }
3257
-
3258
- //#endregion
3259
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/legend/legendFilter.js
3260
- /**
3261
- * AUTO-GENERATED FILE. DO NOT MODIFY.
3262
- */
3263
- function legendFilter(ecModel) {
3264
- var legendModels = ecModel.findComponents({
3265
- mainType: "legend"
3266
- });
3267
- if (legendModels && legendModels.length) ecModel.filterSeries(function (series) {
3268
- for (var i = 0; i < legendModels.length; i++) if (!legendModels[i].isSelected(series.name)) return false;
3269
- return true;
3270
- });
3271
- }
3272
-
3273
- //#endregion
3274
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/legend/legendAction.js
3275
- /**
3276
- * AUTO-GENERATED FILE. DO NOT MODIFY.
3277
- */
3278
- function legendSelectActionHandler(methodName, payload, ecModel) {
3279
- var isAllSelect = methodName === "allSelect" || methodName === "inverseSelect";
3280
- var selectedMap = {};
3281
- var actionLegendIndices = [];
3282
- ecModel.eachComponent({
3283
- mainType: "legend",
3284
- query: payload
3285
- }, function (legendModel) {
3286
- if (isAllSelect) legendModel[methodName]();else legendModel[methodName](payload.name);
3287
- makeSelectedMap(legendModel, selectedMap);
3288
- actionLegendIndices.push(legendModel.componentIndex);
3289
- });
3290
- var allSelectedMap = {};
3291
- ecModel.eachComponent("legend", function (legendModel) {
3292
- each$9(selectedMap, function (isSelected, name) {
3293
- legendModel[isSelected ? "select" : "unSelect"](name);
3294
- });
3295
- makeSelectedMap(legendModel, allSelectedMap);
3296
- });
3297
- return isAllSelect ? {
3298
- selected: allSelectedMap,
3299
- legendIndex: actionLegendIndices
3300
- } : {
3301
- name: payload.name,
3302
- selected: allSelectedMap
3303
- };
3304
- }
3305
- function makeSelectedMap(legendModel, out) {
3306
- var selectedMap = out || {};
3307
- each$9(legendModel.getData(), function (model) {
3308
- var name = model.get("name");
3309
- if (name === "\n" || name === "") return;
3310
- var isItemSelected = legendModel.isSelected(name);
3311
- if (hasOwn(selectedMap, name)) selectedMap[name] = selectedMap[name] && isItemSelected;else selectedMap[name] = isItemSelected;
3312
- });
3313
- return selectedMap;
3314
- }
3315
- function installLegendAction(registers) {
3316
- /**
3317
- * @event legendToggleSelect
3318
- * @type {Object}
3319
- * @property {string} type 'legendToggleSelect'
3320
- * @property {string} [from]
3321
- * @property {string} name Series name or data item name
3322
- */
3323
- registers.registerAction("legendToggleSelect", "legendselectchanged", curry$1(legendSelectActionHandler, "toggleSelected"));
3324
- registers.registerAction("legendAllSelect", "legendselectall", curry$1(legendSelectActionHandler, "allSelect"));
3325
- registers.registerAction("legendInverseSelect", "legendinverseselect", curry$1(legendSelectActionHandler, "inverseSelect"));
3326
- /**
3327
- * @event legendSelect
3328
- * @type {Object}
3329
- * @property {string} type 'legendSelect'
3330
- * @property {string} name Series name or data item name
3331
- */
3332
- registers.registerAction("legendSelect", "legendselected", curry$1(legendSelectActionHandler, "select"));
3333
- /**
3334
- * @event legendUnSelect
3335
- * @type {Object}
3336
- * @property {string} type 'legendUnSelect'
3337
- * @property {string} name Series name or data item name
3338
- */
3339
- registers.registerAction("legendUnSelect", "legendunselected", curry$1(legendSelectActionHandler, "unSelect"));
3340
- }
3341
-
3342
- //#endregion
3343
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/legend/installLegendPlain.js
3344
- /**
3345
- * AUTO-GENERATED FILE. DO NOT MODIFY.
3346
- */
3347
- function install$24(registers) {
3348
- registers.registerComponentModel(LegendModel);
3349
- registers.registerComponentView(LegendView);
3350
- registers.registerProcessor(registers.PRIORITY.PROCESSOR.SERIES_FILTER, legendFilter);
3351
- registers.registerSubTypeDefaulter("legend", function () {
3352
- return "plain";
3353
- });
3354
- installLegendAction(registers);
3355
- }
3356
-
3357
- //#endregion
3358
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/legend/ScrollableLegendModel.js
3359
- /**
3360
- * AUTO-GENERATED FILE. DO NOT MODIFY.
3361
- */
3362
-
3363
- function mergeAndNormalizeLayoutParams(legendModel, target, raw) {
3364
- var orient = legendModel.getOrient();
3365
- var ignoreSize = [1, 1];
3366
- ignoreSize[orient.index] = 0;
3367
- mergeLayoutParam(target, raw, {
3368
- type: "box",
3369
- ignoreSize: !!ignoreSize
3370
- });
3371
- }
3372
-
3373
- //#endregion
3374
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/legend/ScrollableLegendView.js
3375
- /**
3376
- * AUTO-GENERATED FILE. DO NOT MODIFY.
3377
- */
3378
- /**
3379
- * Separate legend and scrollable legend to reduce package size.
3380
- */
3381
-
3382
- //#endregion
3383
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/legend/scrollableLegendAction.js
3384
- /**
3385
- * AUTO-GENERATED FILE. DO NOT MODIFY.
3386
- */
3387
- function installScrollableLegendAction(registers) {
3388
- /**
3389
- * @event legendScroll
3390
- * @type {Object}
3391
- * @property {string} type 'legendScroll'
3392
- * @property {string} scrollDataIndex
3393
- */
3394
- registers.registerAction("legendScroll", "legendscroll", function (payload, ecModel) {
3395
- var scrollDataIndex = payload.scrollDataIndex;
3396
- scrollDataIndex != null && ecModel.eachComponent({
3397
- mainType: "legend",
3398
- subType: "scroll",
3399
- query: payload
3400
- }, function (legendModel) {
3401
- legendModel.setScrollDataIndex(scrollDataIndex);
3402
- });
3403
- });
3404
- }
3405
-
3406
- //#endregion
3407
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/legend/installLegendScroll.js
3408
- /**
3409
- * AUTO-GENERATED FILE. DO NOT MODIFY.
3410
- */
3411
- function install$23(registers) {
3412
- use(install$24);
3413
- registers.registerComponentModel(ScrollableLegendModel);
3414
- registers.registerComponentView(ScrollableLegendView);
3415
- installScrollableLegendAction(registers);
3416
- }
3417
-
3418
- //#endregion
3419
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/legend/install.js
3420
- /**
3421
- * AUTO-GENERATED FILE. DO NOT MODIFY.
3422
- */
3423
- function install$8(registers) {
3424
- use(install$24);
3425
- use(install$23);
3426
- }
3427
-
3428
- //#endregion
3429
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/dataZoom/InsideZoomModel.js
3430
- /**
3431
- * AUTO-GENERATED FILE. DO NOT MODIFY.
3432
- */
3433
-
3434
- function setViewInfoToCoordSysRecord(api, dataZoomModel, getRange) {
3435
- inner$1(api).coordSysRecordMap.each(function (coordSysRecord) {
3436
- var dzInfo = coordSysRecord.dataZoomInfoMap.get(dataZoomModel.uid);
3437
- if (dzInfo) dzInfo.getRange = getRange;
3438
- });
3439
- }
3440
- function disposeCoordSysRecordIfNeeded(api, dataZoomModel) {
3441
- var coordSysRecordMap = inner$1(api).coordSysRecordMap;
3442
- var coordSysKeyArr = coordSysRecordMap.keys();
3443
- for (var i = 0; i < coordSysKeyArr.length; i++) {
3444
- var coordSysKey = coordSysKeyArr[i];
3445
- var coordSysRecord = coordSysRecordMap.get(coordSysKey);
3446
- var dataZoomInfoMap = coordSysRecord.dataZoomInfoMap;
3447
- if (dataZoomInfoMap) {
3448
- var dzUid = dataZoomModel.uid;
3449
- if (dataZoomInfoMap.get(dzUid)) {
3450
- dataZoomInfoMap.removeKey(dzUid);
3451
- if (!dataZoomInfoMap.keys().length) disposeCoordSysRecord(coordSysRecordMap, coordSysRecord);
3452
- }
3453
- }
3454
- }
3455
- }
3456
- function disposeCoordSysRecord(coordSysRecordMap, coordSysRecord) {
3457
- if (coordSysRecord) {
3458
- coordSysRecordMap.removeKey(coordSysRecord.model.uid);
3459
- var controller = coordSysRecord.controller;
3460
- controller && controller.dispose();
3461
- }
3462
- }
3463
- function createCoordSysRecord(api, coordSysModel) {
3464
- var coordSysRecord = {
3465
- model: coordSysModel,
3466
- containsPoint: curry$1(containsPoint, coordSysModel),
3467
- dispatchAction: curry$1(dispatchAction, api),
3468
- dataZoomInfoMap: null,
3469
- controller: null
3470
- };
3471
- var controller = coordSysRecord.controller = new RoamController(api.getZr());
3472
- each$9(["pan", "zoom", "scrollMove"], function (eventName) {
3473
- controller.on(eventName, function (event) {
3474
- var batch = [];
3475
- coordSysRecord.dataZoomInfoMap.each(function (dzInfo) {
3476
- if (!event.isAvailableBehavior(dzInfo.model.option)) return;
3477
- var method = (dzInfo.getRange || {})[eventName];
3478
- var range = method && method(dzInfo.dzReferCoordSysInfo, coordSysRecord.model.mainType, coordSysRecord.controller, event);
3479
- !dzInfo.model.get("disabled", true) && range && batch.push({
3480
- dataZoomId: dzInfo.model.id,
3481
- start: range[0],
3482
- end: range[1]
3483
- });
3484
- });
3485
- batch.length && coordSysRecord.dispatchAction(batch);
3486
- });
3487
- });
3488
- return coordSysRecord;
3489
- }
3490
- /**
3491
- * This action will be throttled.
3492
- */
3493
- function dispatchAction(api, batch) {
3494
- if (!api.isDisposed()) api.dispatchAction({
3495
- type: "dataZoom",
3496
- animation: {
3497
- easing: "cubicOut",
3498
- duration: 100
3499
- },
3500
- batch
3501
- });
3502
- }
3503
- function containsPoint(coordSysModel, e, x, y) {
3504
- return coordSysModel.coordinateSystem.containPoint([x, y]);
3505
- }
3506
- /**
3507
- * Merge roamController settings when multiple dataZooms share one roamController.
3508
- */
3509
- function mergeControllerParams(dataZoomInfoMap, coordSysRecord, api) {
3510
- var controlType;
3511
- var prefix = "type_";
3512
- var typePriority = {
3513
- "type_true": 2,
3514
- "type_move": 1,
3515
- "type_false": 0,
3516
- "type_undefined": -1
3517
- };
3518
- var preventDefaultMouseMove = true;
3519
- dataZoomInfoMap.each(function (dataZoomInfo) {
3520
- var dataZoomModel = dataZoomInfo.model;
3521
- var oneType = dataZoomModel.get("disabled", true) ? false : dataZoomModel.get("zoomLock", true) ? "move" : true;
3522
- if (typePriority[prefix + oneType] > typePriority[prefix + controlType]) controlType = oneType;
3523
- preventDefaultMouseMove = preventDefaultMouseMove && dataZoomModel.get("preventDefaultMouseMove", true);
3524
- });
3525
- return {
3526
- controlType,
3527
- opt: {
3528
- zoomOnMouseWheel: true,
3529
- moveOnMouseMove: true,
3530
- moveOnMouseWheel: true,
3531
- preventDefaultMouseMove: !!preventDefaultMouseMove,
3532
- api,
3533
- zInfo: {
3534
- component: coordSysRecord.model
3535
- },
3536
- triggerInfo: {
3537
- roamTrigger: null,
3538
- isInSelf: coordSysRecord.containsPoint
3539
- }
3540
- }
3541
- };
3542
- }
3543
- function installDataZoomRoamProcessor(registers) {
3544
- registers.registerProcessor(registers.PRIORITY.PROCESSOR.FILTER, function (ecModel, api) {
3545
- var apiInner = inner$1(api);
3546
- var coordSysRecordMap = apiInner.coordSysRecordMap || (apiInner.coordSysRecordMap = createHashMap());
3547
- coordSysRecordMap.each(function (coordSysRecord) {
3548
- coordSysRecord.dataZoomInfoMap = null;
3549
- });
3550
- ecModel.eachComponent({
3551
- mainType: "dataZoom",
3552
- subType: "inside"
3553
- }, function (dataZoomModel) {
3554
- each$9(collectReferCoordSysModelInfo(dataZoomModel).infoList, function (dzCoordSysInfo) {
3555
- var coordSysUid = dzCoordSysInfo.model.uid;
3556
- var coordSysRecord = coordSysRecordMap.get(coordSysUid) || coordSysRecordMap.set(coordSysUid, createCoordSysRecord(api, dzCoordSysInfo.model));
3557
- (coordSysRecord.dataZoomInfoMap || (coordSysRecord.dataZoomInfoMap = createHashMap())).set(dataZoomModel.uid, {
3558
- dzReferCoordSysInfo: dzCoordSysInfo,
3559
- model: dataZoomModel,
3560
- getRange: null
3561
- });
3562
- });
3563
- });
3564
- coordSysRecordMap.each(function (coordSysRecord) {
3565
- var controller = coordSysRecord.controller;
3566
- var firstDzInfo;
3567
- var dataZoomInfoMap = coordSysRecord.dataZoomInfoMap;
3568
- if (dataZoomInfoMap) {
3569
- var firstDzKey = dataZoomInfoMap.keys()[0];
3570
- if (firstDzKey != null) firstDzInfo = dataZoomInfoMap.get(firstDzKey);
3571
- }
3572
- if (!firstDzInfo) {
3573
- disposeCoordSysRecord(coordSysRecordMap, coordSysRecord);
3574
- return;
3575
- }
3576
- var controllerParams = mergeControllerParams(dataZoomInfoMap, coordSysRecord, api);
3577
- controller.enable(controllerParams.controlType, controllerParams.opt);
3578
- createOrUpdate(coordSysRecord, "dispatchAction", firstDzInfo.model.get("throttle", true), "fixRate");
3579
- });
3580
- });
3581
- }
3582
-
3583
- //#endregion
3584
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/dataZoom/InsideZoomView.js
3585
- /**
3586
- * AUTO-GENERATED FILE. DO NOT MODIFY.
3587
- */
3588
-
3589
- function makeMover(getPercentDelta) {
3590
- return function (coordSysInfo, coordSysMainType, controller, e) {
3591
- var lastRange = this.range;
3592
- var range = lastRange.slice();
3593
- var axisModel = coordSysInfo.axisModels[0];
3594
- if (!axisModel) return;
3595
- sliderMove(getPercentDelta(range, axisModel, coordSysInfo, coordSysMainType, controller, e), range, [0, 100], "all");
3596
- this.range = range;
3597
- if (lastRange[0] !== range[0] || lastRange[1] !== range[1]) return range;
3598
- };
3599
- }
3600
- //#endregion
3601
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/dataZoom/installDataZoomInside.js
3602
- /**
3603
- * AUTO-GENERATED FILE. DO NOT MODIFY.
3604
- */
3605
- function install$22(registers) {
3606
- installCommon$1(registers);
3607
- registers.registerComponentModel(InsideZoomModel);
3608
- registers.registerComponentView(InsideZoomView);
3609
- installDataZoomRoamProcessor(registers);
3610
- }
3611
-
3612
- //#endregion
3613
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/dataZoom/SliderZoomModel.js
3614
- /**
3615
- * AUTO-GENERATED FILE. DO NOT MODIFY.
3616
- */
3617
-
3618
- function getOtherDim(thisDim) {
3619
- return {
3620
- x: "y",
3621
- y: "x",
3622
- radius: "angle",
3623
- angle: "radius"
3624
- }[thisDim];
3625
- }
3626
- function getCursor$1(orient) {
3627
- return orient === "vertical" ? "ns-resize" : "ew-resize";
3628
- }
3629
-
3630
- //#endregion
3631
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/dataZoom/installDataZoomSlider.js
3632
- /**
3633
- * AUTO-GENERATED FILE. DO NOT MODIFY.
3634
- */
3635
- function install$21(registers) {
3636
- registers.registerComponentModel(SliderZoomModel);
3637
- registers.registerComponentView(SliderZoomView);
3638
- installCommon$1(registers);
3639
- }
3640
-
3641
- //#endregion
3642
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/dataZoom/install.js
3643
- /**
3644
- * AUTO-GENERATED FILE. DO NOT MODIFY.
3645
- */
3646
- function install$3(registers) {
3647
- use(install$22);
3648
- use(install$21);
3649
- }
3650
-
3651
- //#endregion
3652
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/visual/visualDefault.js
3653
- /**
3654
- * AUTO-GENERATED FILE. DO NOT MODIFY.
3655
- */
3656
- /**
3657
- * @file Visual mapping.
3658
- */
3659
-
3660
- function getColorStopValues(visualMapModel, valueState, dataExtent) {
3661
- if (dataExtent[0] === dataExtent[1]) return dataExtent.slice();
3662
- var count = 200;
3663
- var step = (dataExtent[1] - dataExtent[0]) / count;
3664
- var value = dataExtent[0];
3665
- var stopValues = [];
3666
- for (var i = 0; i <= count && value < dataExtent[1]; i++) {
3667
- stopValues.push(value);
3668
- value += step;
3669
- }
3670
- stopValues.push(dataExtent[1]);
3671
- return stopValues;
3672
- }
3673
-
3674
- //#endregion
3675
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/visualMap/VisualMapView.js
3676
- /**
3677
- * AUTO-GENERATED FILE. DO NOT MODIFY.
3678
- */
3679
-
3680
- /**
3681
- * @param visualMapModel
3682
- * @param api
3683
- * @param itemSize always [short, long]
3684
- * @return {string} 'left' or 'right' or 'top' or 'bottom'
3685
- */
3686
- function getItemAlign(visualMapModel, api, itemSize) {
3687
- var modelOption = visualMapModel.option;
3688
- var itemAlign = modelOption.align;
3689
- if (itemAlign != null && itemAlign !== "auto") return itemAlign;
3690
- var ecSize = {
3691
- width: api.getWidth(),
3692
- height: api.getHeight()
3693
- };
3694
- var realIndex = modelOption.orient === "horizontal" ? 1 : 0;
3695
- var reals = paramsSet[realIndex];
3696
- var fakeValue = [0, null, 10];
3697
- var layoutInput = {};
3698
- for (var i = 0; i < 3; i++) {
3699
- layoutInput[paramsSet[1 - realIndex][i]] = fakeValue[i];
3700
- layoutInput[reals[i]] = i === 2 ? itemSize[0] : modelOption[reals[i]];
3701
- }
3702
- var rParam = [["x", "width", 3], ["y", "height", 0]][realIndex];
3703
- var rect = getLayoutRect(layoutInput, ecSize, modelOption.padding);
3704
- return reals[(rect.margin[rParam[2]] || 0) + rect[rParam[0]] + rect[rParam[1]] * .5 < ecSize[rParam[1]] * .5 ? 0 : 1];
3705
- }
3706
- /**
3707
- * Prepare dataIndex for outside usage, where dataIndex means rawIndex, and
3708
- * dataIndexInside means filtered index.
3709
- */
3710
- function makeHighDownBatch(batch, visualMapModel) {
3711
- each$9(batch || [], function (batchItem) {
3712
- if (batchItem.dataIndex != null) {
3713
- batchItem.dataIndexInside = batchItem.dataIndex;
3714
- batchItem.dataIndex = null;
3715
- }
3716
- batchItem.highlightKey = "visualMap" + (visualMapModel ? visualMapModel.componentIndex : "");
3717
- });
3718
- return batch;
3719
- }
3720
-
3721
- //#endregion
3722
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/visualMap/ContinuousView.js
3723
- /**
3724
- * AUTO-GENERATED FILE. DO NOT MODIFY.
3725
- */
3726
-
3727
- function createPolygon(points, cursor, onDrift, onDragEnd) {
3728
- return new Polygon({
3729
- shape: {
3730
- points
3731
- },
3732
- draggable: !!onDrift,
3733
- cursor,
3734
- drift: onDrift,
3735
- onmousemove: function (e) {
3736
- stop(e.event);
3737
- },
3738
- ondragend: onDragEnd
3739
- });
3740
- }
3741
- function getHalfHoverLinkSize(visualMapModel, dataExtent, sizeExtent) {
3742
- var halfHoverLinkSize = HOVER_LINK_SIZE / 2;
3743
- var hoverLinkDataSize = visualMapModel.get("hoverLinkDataSize");
3744
- if (hoverLinkDataSize) halfHoverLinkSize = linearMap(hoverLinkDataSize, dataExtent, sizeExtent, true) / 2;
3745
- return halfHoverLinkSize;
3746
- }
3747
- function useHoverLinkOnHandle(visualMapModel) {
3748
- var hoverLinkOnHandle = visualMapModel.get("hoverLinkOnHandle");
3749
- return !!(hoverLinkOnHandle == null ? visualMapModel.get("realtime") : hoverLinkOnHandle);
3750
- }
3751
- function getCursor(orient) {
3752
- return orient === "vertical" ? "ns-resize" : "ew-resize";
3753
- }
3754
-
3755
- //#endregion
3756
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/visualMap/visualMapAction.js
3757
- /**
3758
- * AUTO-GENERATED FILE. DO NOT MODIFY.
3759
- */
3760
-
3761
- function getColorVisual(seriesModel, visualMapModel, value, valueState) {
3762
- var mappings = visualMapModel.targetVisuals[valueState];
3763
- var visualTypes = VisualMapping.prepareVisualTypes(mappings);
3764
- var resultVisual = {
3765
- color: getVisualFromData(seriesModel.getData(), "color")
3766
- };
3767
- for (var i = 0, len = visualTypes.length; i < len; i++) {
3768
- var type = visualTypes[i];
3769
- var mapping = mappings[type === "opacity" ? "__alphaForOpacity" : type];
3770
- mapping && mapping.applyVisual(value, getVisual, setVisual);
3771
- }
3772
- return resultVisual.color;
3773
- function getVisual(key) {
3774
- return resultVisual[key];
3775
- }
3776
- function setVisual(key, value) {
3777
- resultVisual[key] = value;
3778
- }
3779
- }
3780
-
3781
- //#endregion
3782
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/visualMap/preprocessor.js
3783
- /**
3784
- * AUTO-GENERATED FILE. DO NOT MODIFY.
3785
- */
3786
-
3787
- function visualMapPreprocessor(option) {
3788
- var visualMap = option && option.visualMap;
3789
- if (!isArray$1(visualMap)) visualMap = visualMap ? [visualMap] : [];
3790
- each(visualMap, function (opt) {
3791
- if (!opt) return;
3792
- if (has(opt, "splitList") && !has(opt, "pieces")) {
3793
- opt.pieces = opt.splitList;
3794
- delete opt.splitList;
3795
- }
3796
- var pieces = opt.pieces;
3797
- if (pieces && isArray$1(pieces)) each(pieces, function (piece) {
3798
- if (isObject(piece)) {
3799
- if (has(piece, "start") && !has(piece, "min")) piece.min = piece.start;
3800
- if (has(piece, "end") && !has(piece, "max")) piece.max = piece.end;
3801
- }
3802
- });
3803
- });
3804
- }
3805
- function has(obj, name) {
3806
- return obj && obj.hasOwnProperty && obj.hasOwnProperty(name);
3807
- }
3808
-
3809
- //#endregion
3810
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/visualMap/installCommon.js
3811
- /**
3812
- * AUTO-GENERATED FILE. DO NOT MODIFY.
3813
- */
3814
-
3815
- function installCommon(registers) {
3816
- if (installed) return;
3817
- installed = true;
3818
- registers.registerSubTypeDefaulter("visualMap", function (option) {
3819
- return !option.categories && (!(option.pieces ? option.pieces.length > 0 : option.splitNumber > 0) || option.calculable) ? "continuous" : "piecewise";
3820
- });
3821
- registers.registerAction(visualMapActionInfo, visualMapActionHander);
3822
- each$9(visualMapEncodingHandlers, function (handler) {
3823
- registers.registerVisual(registers.PRIORITY.VISUAL.COMPONENT, handler);
3824
- });
3825
- registers.registerPreprocessor(visualMapPreprocessor);
3826
- }
3827
-
3828
- //#endregion
3829
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/visualMap/installVisualMapContinuous.js
3830
- /**
3831
- * AUTO-GENERATED FILE. DO NOT MODIFY.
3832
- */
3833
- function install$20(registers) {
3834
- registers.registerComponentModel(ContinuousModel);
3835
- registers.registerComponentView(ContinuousView);
3836
- installCommon(registers);
3837
- }
3838
-
3839
- //#endregion
3840
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/visualMap/PiecewiseModel.js
3841
- /**
3842
- * AUTO-GENERATED FILE. DO NOT MODIFY.
3843
- */
3844
-
3845
- function normalizeReverse(thisOption, pieceList) {
3846
- var inverse = thisOption.inverse;
3847
- if (thisOption.orient === "vertical" ? !inverse : inverse) pieceList.reverse();
3848
- }
3849
-
3850
- //#endregion
3851
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/visualMap/PiecewiseView.js
3852
- /**
3853
- * AUTO-GENERATED FILE. DO NOT MODIFY.
3854
- */
3855
-
3856
- //#endregion
3857
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/visualMap/installVisualMapPiecewise.js
3858
- /**
3859
- * AUTO-GENERATED FILE. DO NOT MODIFY.
3860
- */
3861
- function install$19(registers) {
3862
- registers.registerComponentModel(PiecewiseModel);
3863
- registers.registerComponentView(PiecewiseVisualMapView);
3864
- installCommon(registers);
3865
- }
3866
-
3867
- //#endregion
3868
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/visualMap/install.js
3869
- /**
3870
- * AUTO-GENERATED FILE. DO NOT MODIFY.
3871
- */
3872
- function install$18(registers) {
3873
- use(install$20);
3874
- use(install$19);
3875
- }
3876
-
3877
- //#endregion
3878
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/visual/aria.js
3879
- /**
3880
- * AUTO-GENERATED FILE. DO NOT MODIFY.
3881
- */
3882
-
3883
- function ariaVisual(ecModel, api) {
3884
- var ariaModel = ecModel.getModel("aria");
3885
- if (!ariaModel.get("enabled")) return;
3886
- var defaultOption = clone$1(DEFAULT_OPTION);
3887
- merge(defaultOption.label, ecModel.getLocaleModel().get("aria"), false);
3888
- merge(ariaModel.option, defaultOption, false);
3889
- setDecal();
3890
- setLabel();
3891
- function setDecal() {
3892
- if (ariaModel.getModel("decal").get("show")) {
3893
- var paletteScopeGroupByType_1 = createHashMap();
3894
- ecModel.eachSeries(function (seriesModel) {
3895
- if (seriesModel.isColorBySeries()) return;
3896
- var decalScope = paletteScopeGroupByType_1.get(seriesModel.type);
3897
- if (!decalScope) {
3898
- decalScope = {};
3899
- paletteScopeGroupByType_1.set(seriesModel.type, decalScope);
3900
- }
3901
- inner(seriesModel).scope = decalScope;
3902
- });
3903
- ecModel.eachRawSeries(function (seriesModel) {
3904
- if (ecModel.isSeriesFiltered(seriesModel)) return;
3905
- if (isFunction(seriesModel.enableAriaDecal)) {
3906
- seriesModel.enableAriaDecal();
3907
- return;
3908
- }
3909
- var data = seriesModel.getData();
3910
- if (!seriesModel.isColorBySeries()) {
3911
- var dataAll_1 = seriesModel.getRawData();
3912
- var idxMap_1 = {};
3913
- var decalScope_1 = inner(seriesModel).scope;
3914
- data.each(function (idx) {
3915
- var rawIdx = data.getRawIndex(idx);
3916
- idxMap_1[rawIdx] = idx;
3917
- });
3918
- var dataCount_1 = dataAll_1.count();
3919
- dataAll_1.each(function (rawIdx) {
3920
- var idx = idxMap_1[rawIdx];
3921
- var name = dataAll_1.getName(rawIdx) || rawIdx + "";
3922
- var paletteDecal = getDecalFromPalette(seriesModel.ecModel, name, decalScope_1, dataCount_1);
3923
- var specifiedDecal = data.getItemVisual(idx, "decal");
3924
- data.setItemVisual(idx, "decal", mergeDecal(specifiedDecal, paletteDecal));
3925
- });
3926
- } else {
3927
- var paletteDecal = getDecalFromPalette(seriesModel.ecModel, seriesModel.name, decalPaletteScope, ecModel.getSeriesCount());
3928
- var specifiedDecal = data.getVisual("decal");
3929
- data.setVisual("decal", mergeDecal(specifiedDecal, paletteDecal));
3930
- }
3931
- function mergeDecal(specifiedDecal, paletteDecal) {
3932
- var resultDecal = specifiedDecal ? extend(extend({}, paletteDecal), specifiedDecal) : paletteDecal;
3933
- resultDecal.dirty = true;
3934
- return resultDecal;
3935
- }
3936
- });
3937
- }
3938
- }
3939
- function setLabel() {
3940
- var dom = api.getZr().dom;
3941
- if (!dom) return;
3942
- var labelLocale = ecModel.getLocaleModel().get("aria");
3943
- var labelModel = ariaModel.getModel("label");
3944
- labelModel.option = defaults(labelModel.option, labelLocale);
3945
- if (!labelModel.get("enabled")) return;
3946
- dom.setAttribute("role", "img");
3947
- if (labelModel.get("description")) {
3948
- dom.setAttribute("aria-label", labelModel.get("description"));
3949
- return;
3950
- }
3951
- var seriesCnt = ecModel.getSeriesCount();
3952
- var maxDataCnt = labelModel.get(["data", "maxCount"]) || 10;
3953
- var maxSeriesCnt = labelModel.get(["series", "maxCount"]) || 10;
3954
- var displaySeriesCnt = Math.min(seriesCnt, maxSeriesCnt);
3955
- var ariaLabel;
3956
- if (seriesCnt < 1) return;else {
3957
- var title = getTitle();
3958
- if (title) ariaLabel = replace(labelModel.get(["general", "withTitle"]), {
3959
- title
3960
- });else ariaLabel = labelModel.get(["general", "withoutTitle"]);
3961
- var seriesLabels_1 = [];
3962
- var prefix = seriesCnt > 1 ? labelModel.get(["series", "multiple", "prefix"]) : labelModel.get(["series", "single", "prefix"]);
3963
- ariaLabel += replace(prefix, {
3964
- seriesCount: seriesCnt
3965
- });
3966
- ecModel.eachSeries(function (seriesModel, idx) {
3967
- if (idx < displaySeriesCnt) {
3968
- var seriesLabel = void 0;
3969
- var withName = seriesModel.get("name") ? "withName" : "withoutName";
3970
- seriesLabel = seriesCnt > 1 ? labelModel.get(["series", "multiple", withName]) : labelModel.get(["series", "single", withName]);
3971
- seriesLabel = replace(seriesLabel, {
3972
- seriesId: seriesModel.seriesIndex,
3973
- seriesName: seriesModel.get("name"),
3974
- seriesType: getSeriesTypeName(seriesModel.subType)
3975
- });
3976
- var data = seriesModel.getData();
3977
- if (data.count() > maxDataCnt) {
3978
- var partialLabel = labelModel.get(["data", "partialData"]);
3979
- seriesLabel += replace(partialLabel, {
3980
- displayCnt: maxDataCnt
3981
- });
3982
- } else seriesLabel += labelModel.get(["data", "allData"]);
3983
- var middleSeparator_1 = labelModel.get(["data", "separator", "middle"]);
3984
- var endSeparator_1 = labelModel.get(["data", "separator", "end"]);
3985
- var excludeDimensionId_1 = labelModel.get(["data", "excludeDimensionId"]);
3986
- var dataLabels = [];
3987
- for (var i = 0; i < data.count(); i++) if (i < maxDataCnt) {
3988
- var name_1 = data.getName(i);
3989
- var value = !excludeDimensionId_1 ? data.getValues(i) : filter(data.getValues(i), function (v, j) {
3990
- return indexOf(excludeDimensionId_1, j) === -1;
3991
- });
3992
- var dataLabel = labelModel.get(["data", name_1 ? "withName" : "withoutName"]);
3993
- dataLabels.push(replace(dataLabel, {
3994
- name: name_1,
3995
- value: value.join(middleSeparator_1)
3996
- }));
3997
- }
3998
- seriesLabel += dataLabels.join(middleSeparator_1) + endSeparator_1;
3999
- seriesLabels_1.push(seriesLabel);
4000
- }
4001
- });
4002
- var separatorModel = labelModel.getModel(["series", "multiple", "separator"]);
4003
- var middleSeparator = separatorModel.get("middle");
4004
- var endSeparator = separatorModel.get("end");
4005
- ariaLabel += seriesLabels_1.join(middleSeparator) + endSeparator;
4006
- dom.setAttribute("aria-label", ariaLabel);
4007
- }
4008
- }
4009
- function replace(str, keyValues) {
4010
- if (!isString(str)) return str;
4011
- var result = str;
4012
- each$9(keyValues, function (value, key) {
4013
- result = result.replace(new RegExp("\\{\\s*" + key + "\\s*\\}", "g"), value);
4014
- });
4015
- return result;
4016
- }
4017
- function getTitle() {
4018
- var title = ecModel.get("title");
4019
- if (title && title.length) title = title[0];
4020
- return title && title.text;
4021
- }
4022
- function getSeriesTypeName(type) {
4023
- var typeNames = ecModel.getLocaleModel().get(["series", "typeNames"]);
4024
- return typeNames[type] || typeNames.chart;
4025
- }
4026
- }
4027
-
4028
- //#endregion
4029
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/aria/preprocessor.js
4030
- /**
4031
- * AUTO-GENERATED FILE. DO NOT MODIFY.
4032
- */
4033
- function ariaPreprocessor(option) {
4034
- if (!option || !option.aria) return;
4035
- var aria = option.aria;
4036
- if (aria.show != null) aria.enabled = aria.show;
4037
- aria.label = aria.label || {};
4038
- each$9(["description", "general", "series", "data"], function (name) {
4039
- if (aria[name] != null) aria.label[name] = aria[name];
4040
- });
4041
- }
4042
-
4043
- //#endregion
4044
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/aria/install.js
4045
- /**
4046
- * AUTO-GENERATED FILE. DO NOT MODIFY.
4047
- */
4048
- function install(registers) {
4049
- registers.registerPreprocessor(ariaPreprocessor);
4050
- registers.registerVisual(registers.PRIORITY.VISUAL.ARIA, ariaVisual);
4051
- }
4052
-
4053
- //#endregion
4054
- //#region ../../node_modules/.bun/echarts@6.0.0/node_modules/echarts/lib/component/dataset/install.js
4055
- /**
4056
- * AUTO-GENERATED FILE. DO NOT MODIFY.
4057
- */
4058
- /**
4059
- * This module is imported by echarts directly.
4060
- *
4061
- * Notice:
4062
- * Always keep this file exists for backward compatibility.
4063
- * Because before 4.1.0, dataset is an optional component,
4064
- * some users may import this module manually.
4065
- */
4066
-
4067
- function install$4(registers) {
4068
- registers.registerComponentModel(DatasetModel);
4069
- registers.registerComponentView(DatasetView);
4070
- }
4071
-
4072
- //#endregion
4073
- export { install as AriaComponent, install$1 as BrushComponent, install$2 as CalendarComponent, install$3 as DataZoomComponent, install$4 as DatasetComponent, install$5 as GeoComponent, install$6 as GraphicComponent, install$7 as GridComponent, install$8 as LegendComponent, install$9 as MarkAreaComponent, install$10 as MarkLineComponent, install$11 as MarkPointComponent, install$12 as PolarComponent, install$13 as RadarComponent, install$14 as TimelineComponent, install$15 as TitleComponent, install$16 as ToolboxComponent, install$17 as TooltipComponent, install$18 as VisualMapComponent };
4074
- //# sourceMappingURL=components.d.ts.map