reke-ui 0.5.3 → 0.5.4
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.
- package/custom-elements.json +465 -0
- package/dist/components/reke-bar-chart/reke-bar-chart.d.ts +99 -0
- package/dist/components/reke-bar-chart/reke-bar-chart.d.ts.map +1 -0
- package/dist/components/reke-bar-chart/reke-bar-chart.js +319 -0
- package/dist/components/reke-bar-chart/reke-bar-chart.styles.d.ts +2 -0
- package/dist/components/reke-bar-chart/reke-bar-chart.styles.d.ts.map +1 -0
- package/dist/components/reke-bar-chart/reke-bar-chart.styles.js +36 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +21 -20
- package/dist/node_modules/echarts/lib/chart/bar/BarSeries.js +50 -0
- package/dist/node_modules/echarts/lib/chart/bar/BarView.js +431 -0
- package/dist/node_modules/echarts/lib/chart/bar/BaseBarSeries.js +65 -0
- package/dist/node_modules/echarts/lib/chart/bar/install.js +22 -0
- package/dist/node_modules/echarts/lib/chart/helper/Symbol.js +142 -0
- package/dist/node_modules/echarts/lib/chart/helper/SymbolDraw.js +99 -0
- package/dist/node_modules/echarts/lib/chart/helper/axisSnippets.js +19 -0
- package/dist/node_modules/echarts/lib/chart/helper/createClipPathFromCoordSys.js +50 -0
- package/dist/node_modules/echarts/lib/chart/helper/createSeriesData.js +55 -0
- package/dist/node_modules/echarts/lib/chart/helper/createSeriesDataSimply.js +3 -3
- package/dist/node_modules/echarts/lib/chart/helper/labelHelper.js +24 -0
- package/dist/node_modules/echarts/lib/chart/line/LineSeries.js +60 -0
- package/dist/node_modules/echarts/lib/chart/line/LineView.js +471 -0
- package/dist/node_modules/echarts/lib/chart/line/helper.js +34 -0
- package/dist/node_modules/echarts/lib/chart/line/install.js +16 -0
- package/dist/node_modules/echarts/lib/chart/line/lineAnimationDiff.js +59 -0
- package/dist/node_modules/echarts/lib/chart/line/poly.js +135 -0
- package/dist/node_modules/echarts/lib/chart/pie/PieSeries.js +32 -32
- package/dist/node_modules/echarts/lib/chart/pie/PieView.js +69 -69
- package/dist/node_modules/echarts/lib/chart/pie/labelLayout.js +25 -25
- package/dist/node_modules/echarts/lib/chart/pie/pieLayout.js +16 -16
- package/dist/node_modules/echarts/lib/component/axis/AxisBuilder.js +153 -153
- package/dist/node_modules/echarts/lib/component/axis/AxisView.js +13 -13
- package/dist/node_modules/echarts/lib/component/axis/CartesianAxisView.js +106 -0
- package/dist/node_modules/echarts/lib/component/axis/axisSplitHelper.js +50 -0
- package/dist/node_modules/echarts/lib/component/axisPointer/BaseAxisPointer.js +20 -20
- package/dist/node_modules/echarts/lib/component/axisPointer/CartesianAxisPointer.js +30 -30
- package/dist/node_modules/echarts/lib/component/axisPointer/viewHelper.js +13 -13
- package/dist/node_modules/echarts/lib/component/dataZoom/AxisProxy.js +114 -0
- package/dist/node_modules/echarts/lib/component/dataZoom/DataZoomModel.js +189 -0
- package/dist/node_modules/echarts/lib/component/dataZoom/DataZoomView.js +15 -0
- package/dist/node_modules/echarts/lib/component/dataZoom/InsideZoomModel.js +21 -0
- package/dist/node_modules/echarts/lib/component/dataZoom/InsideZoomView.js +67 -0
- package/dist/node_modules/echarts/lib/component/dataZoom/SliderZoomModel.js +75 -0
- package/dist/node_modules/echarts/lib/component/dataZoom/SliderZoomView.js +465 -0
- package/dist/node_modules/echarts/lib/component/dataZoom/dataZoomAction.js +17 -0
- package/dist/node_modules/echarts/lib/component/dataZoom/dataZoomProcessor.js +55 -0
- package/dist/node_modules/echarts/lib/component/dataZoom/helper.js +88 -0
- package/dist/node_modules/echarts/lib/component/dataZoom/installCommon.js +14 -0
- package/dist/node_modules/echarts/lib/component/dataZoom/installDataZoomInside.js +10 -0
- package/dist/node_modules/echarts/lib/component/dataZoom/installDataZoomSlider.js +9 -0
- package/dist/node_modules/echarts/lib/component/dataZoom/roams.js +132 -0
- package/dist/node_modules/echarts/lib/component/grid/install.js +9 -0
- package/dist/node_modules/echarts/lib/component/grid/installSimple.js +32 -0
- package/dist/node_modules/echarts/lib/component/helper/RoamController.js +172 -0
- package/dist/node_modules/echarts/lib/component/helper/cursorHelper.js +17 -0
- package/dist/node_modules/echarts/lib/component/helper/interactionMutex.js +15 -0
- package/dist/node_modules/echarts/lib/component/helper/sliderMove.js +29 -0
- package/dist/node_modules/echarts/lib/component/legend/LegendModel.js +31 -31
- package/dist/node_modules/echarts/lib/component/legend/LegendView.js +61 -61
- package/dist/node_modules/echarts/lib/component/legend/ScrollableLegendView.js +29 -29
- package/dist/node_modules/echarts/lib/component/tooltip/TooltipRichContent.js +4 -4
- package/dist/node_modules/echarts/lib/component/tooltip/TooltipView.js +105 -105
- package/dist/node_modules/echarts/lib/coord/Axis.js +92 -0
- package/dist/node_modules/echarts/lib/coord/CoordinateSystem.js +6 -0
- package/dist/node_modules/echarts/lib/coord/axisAlignTicks.js +76 -0
- package/dist/node_modules/echarts/lib/coord/axisCommonTypes.js +9 -0
- package/dist/node_modules/echarts/lib/coord/axisDefault.js +124 -0
- package/dist/node_modules/echarts/lib/coord/axisHelper.js +123 -14
- package/dist/node_modules/echarts/lib/coord/axisModelCommonMixin.js +9 -0
- package/dist/node_modules/echarts/lib/coord/axisModelCreator.js +39 -0
- package/dist/node_modules/echarts/lib/coord/axisNiceTicks.js +64 -0
- package/dist/node_modules/echarts/lib/coord/axisStatistics.js +101 -22
- package/dist/node_modules/echarts/lib/coord/axisStatisticsMetricsImpl.js +43 -0
- package/dist/node_modules/echarts/lib/coord/axisTickLabelBuilder.js +151 -5
- package/dist/node_modules/echarts/lib/coord/cartesian/Axis2D.js +24 -0
- package/dist/node_modules/echarts/lib/coord/cartesian/AxisModel.js +18 -0
- package/dist/node_modules/echarts/lib/coord/cartesian/Cartesian.js +23 -0
- package/dist/node_modules/echarts/lib/coord/cartesian/Cartesian2D.js +69 -0
- package/dist/node_modules/echarts/lib/coord/cartesian/Grid.js +314 -0
- package/dist/node_modules/echarts/lib/coord/cartesian/GridModel.js +40 -0
- package/dist/node_modules/echarts/lib/coord/cartesian/cartesianAxisHelper.js +43 -12
- package/dist/node_modules/echarts/lib/coord/scaleRawExtentInfo.js +175 -0
- package/dist/node_modules/echarts/lib/core/CoordinateSystem.js +39 -16
- package/dist/node_modules/echarts/lib/core/echarts.js +421 -421
- package/dist/node_modules/echarts/lib/data/OrdinalMeta.js +30 -0
- package/dist/node_modules/echarts/lib/data/SeriesData.js +18 -18
- package/dist/node_modules/echarts/lib/data/helper/createDimensions.js +6 -6
- package/dist/node_modules/echarts/lib/data/helper/dataStackHelper.js +59 -0
- package/dist/node_modules/echarts/lib/data/helper/dataValueHelper.js +13 -13
- package/dist/node_modules/echarts/lib/data/helper/dimensionHelper.js +7 -4
- package/dist/node_modules/echarts/lib/data/helper/sourceHelper.js +40 -8
- package/dist/node_modules/echarts/lib/data/helper/sourceManager.js +3 -3
- package/dist/node_modules/echarts/lib/data/helper/transform.js +8 -8
- package/dist/node_modules/echarts/lib/extension.js +10 -10
- package/dist/node_modules/echarts/lib/label/labelGuideHelper.js +10 -10
- package/dist/node_modules/echarts/lib/label/labelStyle.js +34 -25
- package/dist/node_modules/echarts/lib/label/sectorLabel.js +83 -0
- package/dist/node_modules/echarts/lib/layout/barCommon.js +19 -0
- package/dist/node_modules/echarts/lib/layout/barGrid.js +165 -0
- package/dist/node_modules/echarts/lib/layout/points.js +37 -0
- package/dist/node_modules/echarts/lib/loading/default.js +6 -6
- package/dist/node_modules/echarts/lib/model/Component.js +39 -39
- package/dist/node_modules/echarts/lib/model/Global.js +122 -122
- package/dist/node_modules/echarts/lib/model/Series.js +78 -78
- package/dist/node_modules/echarts/lib/model/referHelper.js +58 -0
- package/dist/node_modules/echarts/lib/processor/dataSample.js +43 -0
- package/dist/node_modules/echarts/lib/scale/Interval.js +68 -0
- package/dist/node_modules/echarts/lib/scale/Log.js +100 -0
- package/dist/node_modules/echarts/lib/scale/Ordinal.js +92 -0
- package/dist/node_modules/echarts/lib/scale/Scale.js +13 -0
- package/dist/node_modules/echarts/lib/scale/Time.js +242 -0
- package/dist/node_modules/echarts/lib/scale/break.js +10 -2
- package/dist/node_modules/echarts/lib/scale/helper.js +61 -3
- package/dist/node_modules/echarts/lib/scale/minorTicks.js +22 -0
- package/dist/node_modules/echarts/lib/scale/scaleMapper.js +89 -7
- package/dist/node_modules/echarts/lib/util/clazz.js +35 -35
- package/dist/node_modules/echarts/lib/util/component.js +16 -16
- package/dist/node_modules/echarts/lib/util/cycleCache.js +4 -1
- package/dist/node_modules/echarts/lib/util/decal.js +11 -11
- package/dist/node_modules/echarts/lib/util/format.js +1 -1
- package/dist/node_modules/echarts/lib/util/graphic.js +170 -170
- package/dist/node_modules/echarts/lib/util/layout.js +23 -23
- package/dist/node_modules/echarts/lib/util/model.js +128 -68
- package/dist/node_modules/echarts/lib/util/number.js +55 -37
- package/dist/node_modules/echarts/lib/util/shape/sausage.js +25 -0
- package/dist/node_modules/echarts/lib/util/states.js +96 -82
- package/dist/node_modules/echarts/lib/util/styleCompat.js +10 -0
- package/dist/node_modules/echarts/lib/util/symbol.js +24 -21
- package/dist/node_modules/echarts/lib/util/time.js +154 -18
- package/dist/node_modules/echarts/lib/util/vendor.js +26 -0
- package/dist/node_modules/echarts/lib/view/Chart.js +19 -19
- package/dist/node_modules/echarts/lib/view/Component.js +7 -7
- package/dist/node_modules/echarts/lib/visual/style.js +5 -5
- package/dist/node_modules/zrender/lib/Element.js +35 -35
- package/dist/node_modules/zrender/lib/canvas/graphic.js +36 -36
- package/dist/node_modules/zrender/lib/core/PathProxy.js +25 -25
- package/dist/node_modules/zrender/lib/core/event.js +4 -1
- package/dist/node_modules/zrender/lib/core/util.js +69 -64
- package/dist/node_modules/zrender/lib/graphic/TSpan.js +7 -7
- package/dist/node_modules/zrender/lib/graphic/Text.js +37 -37
- package/dist/node_modules/zrender/lib/graphic/helper/parseText.js +59 -59
- package/dist/node_modules/zrender/lib/tool/color.js +60 -41
- package/dist/react.d.ts +5 -0
- package/dist/react.d.ts.map +1 -1
- package/dist/react.js +83 -77
- package/package.json +5 -1
|
@@ -0,0 +1,132 @@
|
|
|
1
|
+
import { createHashMap as e, curry as t, each as n, retrieve2 as r } from "../../../../zrender/lib/core/util.js";
|
|
2
|
+
import { makeInner as i } from "../../util/model.js";
|
|
3
|
+
import { createOrUpdate as a } from "../../util/throttle.js";
|
|
4
|
+
import { collectReferCoordSysModelInfo as o } from "./helper.js";
|
|
5
|
+
import s from "../helper/RoamController.js";
|
|
6
|
+
//#region node_modules/echarts/lib/component/dataZoom/roams.js
|
|
7
|
+
var c = i();
|
|
8
|
+
function l(e, t, n) {
|
|
9
|
+
c(e).coordSysRecordMap.each(function(e) {
|
|
10
|
+
var r = e.dataZoomInfoMap.get(t.uid);
|
|
11
|
+
r && (r.getRange = n);
|
|
12
|
+
});
|
|
13
|
+
}
|
|
14
|
+
function u(e, t) {
|
|
15
|
+
for (var n = c(e).coordSysRecordMap, r = n.keys(), i = 0; i < r.length; i++) {
|
|
16
|
+
var a = r[i], o = n.get(a), s = o.dataZoomInfoMap;
|
|
17
|
+
if (s) {
|
|
18
|
+
var l = t.uid;
|
|
19
|
+
s.get(l) && (s.removeKey(l), s.keys().length || d(n, o));
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
function d(e, t) {
|
|
24
|
+
if (t) {
|
|
25
|
+
e.removeKey(t.model.uid);
|
|
26
|
+
var n = t.controller;
|
|
27
|
+
n && n.dispose();
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
function f(e, r) {
|
|
31
|
+
var i = {
|
|
32
|
+
model: r,
|
|
33
|
+
containsPoint: t(m, r),
|
|
34
|
+
dispatchAction: t(p, e),
|
|
35
|
+
dataZoomInfoMap: null,
|
|
36
|
+
controller: null
|
|
37
|
+
}, a = i.controller = new s(e.getZr());
|
|
38
|
+
return n([
|
|
39
|
+
"pan",
|
|
40
|
+
"zoom",
|
|
41
|
+
"scrollMove"
|
|
42
|
+
], function(e) {
|
|
43
|
+
a.on(e, function(t) {
|
|
44
|
+
var n = [];
|
|
45
|
+
i.dataZoomInfoMap.each(function(r) {
|
|
46
|
+
if (t.isAvailableBehavior(r.model.option)) {
|
|
47
|
+
var a = (r.getRange || {})[e], o = a && a(r.dzReferCoordSysInfo, i.model.mainType, i.controller, t);
|
|
48
|
+
!r.model.get("disabled", !0) && o && n.push({
|
|
49
|
+
dataZoomId: r.model.id,
|
|
50
|
+
start: o[0],
|
|
51
|
+
end: o[1]
|
|
52
|
+
});
|
|
53
|
+
}
|
|
54
|
+
}), n.length && i.dispatchAction(n);
|
|
55
|
+
});
|
|
56
|
+
}), i;
|
|
57
|
+
}
|
|
58
|
+
function p(e, t) {
|
|
59
|
+
e.isDisposed() || e.dispatchAction({
|
|
60
|
+
type: "dataZoom",
|
|
61
|
+
animation: {
|
|
62
|
+
easing: "cubicOut",
|
|
63
|
+
duration: 100
|
|
64
|
+
},
|
|
65
|
+
batch: t
|
|
66
|
+
});
|
|
67
|
+
}
|
|
68
|
+
function m(e, t, n, r) {
|
|
69
|
+
return e.coordinateSystem.containPoint([n, r]);
|
|
70
|
+
}
|
|
71
|
+
function h(e, t, n) {
|
|
72
|
+
var i, a = "type_", o = {
|
|
73
|
+
type_true: 2,
|
|
74
|
+
type_move: 1,
|
|
75
|
+
type_false: 0,
|
|
76
|
+
type_undefined: -1
|
|
77
|
+
}, s = !0, c, l;
|
|
78
|
+
return e.each(function(e) {
|
|
79
|
+
var t = e.model, n = t.get("disabled", !0) ? !1 : t.get("zoomLock", !0) ? "move" : !0;
|
|
80
|
+
o[a + n] > o[a + i] && (i = n), s &&= t.get("preventDefaultMouseMove", !0), c = r(t.get("cursorGrab", !0), c), l = r(t.get("cursorGrabbing", !0), l);
|
|
81
|
+
}), {
|
|
82
|
+
controlType: i,
|
|
83
|
+
opt: {
|
|
84
|
+
zoomOnMouseWheel: !0,
|
|
85
|
+
moveOnMouseMove: !0,
|
|
86
|
+
moveOnMouseWheel: !0,
|
|
87
|
+
preventDefaultMouseMove: !!s,
|
|
88
|
+
api: n,
|
|
89
|
+
zInfo: { component: t.model },
|
|
90
|
+
triggerInfo: {
|
|
91
|
+
roamTrigger: null,
|
|
92
|
+
isInSelf: t.containsPoint
|
|
93
|
+
},
|
|
94
|
+
cursorGrab: c,
|
|
95
|
+
cursorGrabbing: l
|
|
96
|
+
}
|
|
97
|
+
};
|
|
98
|
+
}
|
|
99
|
+
function g(t) {
|
|
100
|
+
t.registerUpdateLifecycle("coordsys:aftercreate", function(t, r) {
|
|
101
|
+
var i = c(r), s = i.coordSysRecordMap ||= e();
|
|
102
|
+
s.each(function(e) {
|
|
103
|
+
e.dataZoomInfoMap = null;
|
|
104
|
+
}), t.eachComponent({
|
|
105
|
+
mainType: "dataZoom",
|
|
106
|
+
subType: "inside"
|
|
107
|
+
}, function(t) {
|
|
108
|
+
n(o(t).infoList, function(n) {
|
|
109
|
+
var i = n.model.uid, a = s.get(i) || s.set(i, f(r, n.model));
|
|
110
|
+
(a.dataZoomInfoMap ||= e()).set(t.uid, {
|
|
111
|
+
dzReferCoordSysInfo: n,
|
|
112
|
+
model: t,
|
|
113
|
+
getRange: null
|
|
114
|
+
});
|
|
115
|
+
});
|
|
116
|
+
}), s.each(function(e) {
|
|
117
|
+
var t = e.controller, n, i = e.dataZoomInfoMap;
|
|
118
|
+
if (i) {
|
|
119
|
+
var o = i.keys()[0];
|
|
120
|
+
o != null && (n = i.get(o));
|
|
121
|
+
}
|
|
122
|
+
if (!n) {
|
|
123
|
+
d(s, e);
|
|
124
|
+
return;
|
|
125
|
+
}
|
|
126
|
+
var c = h(i, e, r);
|
|
127
|
+
t.enable(c.controlType, c.opt), a(e, "dispatchAction", n.model.get("throttle", !0), "fixRate");
|
|
128
|
+
});
|
|
129
|
+
});
|
|
130
|
+
}
|
|
131
|
+
//#endregion
|
|
132
|
+
export { u as disposeCoordSysRecordIfNeeded, g as installDataZoomRoamProcessor, l as setViewInfoToCoordSysRecord };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { install as e } from "./installSimple.js";
|
|
2
|
+
import { install as t } from "../axisPointer/install.js";
|
|
3
|
+
import { use as n } from "../../extension.js";
|
|
4
|
+
//#region node_modules/echarts/lib/component/grid/install.js
|
|
5
|
+
function r(r) {
|
|
6
|
+
n(e), n(t);
|
|
7
|
+
}
|
|
8
|
+
//#endregion
|
|
9
|
+
export { r as install };
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { __extends as e } from "../../../node_modules/tslib/tslib.es6.js";
|
|
2
|
+
import { defaults as t } from "../../../../zrender/lib/core/util.js";
|
|
3
|
+
import n from "../../../../zrender/lib/graphic/shape/Rect.js";
|
|
4
|
+
import r from "../../coord/cartesian/GridModel.js";
|
|
5
|
+
import i from "../../view/Component.js";
|
|
6
|
+
import a from "../../coord/cartesian/AxisModel.js";
|
|
7
|
+
import o from "../../coord/axisModelCreator.js";
|
|
8
|
+
import s from "../../coord/cartesian/Grid.js";
|
|
9
|
+
import { CartesianXAxisView as c, CartesianYAxisView as l } from "../axis/CartesianAxisView.js";
|
|
10
|
+
//#region node_modules/echarts/lib/component/grid/installSimple.js
|
|
11
|
+
var u = function(r) {
|
|
12
|
+
e(i, r);
|
|
13
|
+
function i() {
|
|
14
|
+
var e = r !== null && r.apply(this, arguments) || this;
|
|
15
|
+
return e.type = "grid", e;
|
|
16
|
+
}
|
|
17
|
+
return i.prototype.render = function(e, r) {
|
|
18
|
+
this.group.removeAll(), e.get("show") && this.group.add(new n({
|
|
19
|
+
shape: e.coordinateSystem.getRect(),
|
|
20
|
+
style: t({ fill: e.get("backgroundColor") }, e.getItemStyle()),
|
|
21
|
+
silent: !0,
|
|
22
|
+
z2: -1
|
|
23
|
+
}));
|
|
24
|
+
}, i.type = "grid", i;
|
|
25
|
+
}(i), d = { offset: 0 };
|
|
26
|
+
function f(e) {
|
|
27
|
+
e.registerComponentView(u), e.registerComponentModel(r), e.registerCoordinateSystem("cartesian2d", s), o(e, "x", a, d), o(e, "y", a, d), e.registerComponentView(c), e.registerComponentView(l), e.registerPreprocessor(function(e) {
|
|
28
|
+
e.xAxis && e.yAxis && !e.grid && (e.grid = {});
|
|
29
|
+
});
|
|
30
|
+
}
|
|
31
|
+
//#endregion
|
|
32
|
+
export { f as install };
|
|
@@ -0,0 +1,172 @@
|
|
|
1
|
+
import { __extends as e } from "../../../node_modules/tslib/tslib.es6.js";
|
|
2
|
+
import { bind as t, defaults as n, extend as r, isString as i, retrieve2 as a } from "../../../../zrender/lib/core/util.js";
|
|
3
|
+
import o from "../../../../zrender/lib/core/Eventful.js";
|
|
4
|
+
import { makeInner as s } from "../../util/model.js";
|
|
5
|
+
import { retrieveZInfo as c } from "../../util/graphic.js";
|
|
6
|
+
import { isMiddleOrRightButtonOnMouseUpDown as l, stop as u } from "../../../../zrender/lib/core/event.js";
|
|
7
|
+
import { isTaken as d } from "./interactionMutex.js";
|
|
8
|
+
import { onIrrelevantElement as f } from "./cursorHelper.js";
|
|
9
|
+
//#region node_modules/echarts/lib/component/helper/RoamController.js
|
|
10
|
+
var p = function(i) {
|
|
11
|
+
e(o, i);
|
|
12
|
+
function o(e) {
|
|
13
|
+
var o = i.call(this) || this;
|
|
14
|
+
o._zr = e;
|
|
15
|
+
var s = t(o._mousedownHandler, o), l = t(o._mousemoveHandler, o), u = t(o._mouseupHandler, o), d = t(o._mousewheelHandler, o), f = t(o._pinchHandler, o);
|
|
16
|
+
return o.enable = function(t, i) {
|
|
17
|
+
var o = i.zInfo, p = c(o.component), m = p.z, h = p.zlevel, g = {
|
|
18
|
+
component: o.component,
|
|
19
|
+
z: m,
|
|
20
|
+
zlevel: h,
|
|
21
|
+
z2: a(o.z2, -Infinity)
|
|
22
|
+
}, v = r({}, i.triggerInfo);
|
|
23
|
+
this._opt = n(r({}, i), {
|
|
24
|
+
zoomOnMouseWheel: !0,
|
|
25
|
+
moveOnMouseMove: !0,
|
|
26
|
+
moveOnMouseWheel: !1,
|
|
27
|
+
preventDefaultMouseMove: !0,
|
|
28
|
+
zInfoParsed: g,
|
|
29
|
+
triggerInfo: v,
|
|
30
|
+
cursorGrab: "grab",
|
|
31
|
+
cursorGrabbing: "grabbing"
|
|
32
|
+
}), t ??= !0, (!this._enabled || this._controlType !== t) && (this.disable(), this._enabled = !0, (t === !0 || t === "move" || t === "pan") && (_(e, "mousedown", s, g), _(e, "mousemove", l, g), _(e, "mouseup", u, g)), (t === !0 || t === "scale" || t === "zoom") && (_(e, "mousewheel", d, g), _(e, "pinch", f, g)));
|
|
33
|
+
}, o.disable = function() {
|
|
34
|
+
this._enabled && (this._enabled = !1, v(e, "mousedown", s), v(e, "mousemove", l), v(e, "mouseup", u), v(e, "mousewheel", d), v(e, "pinch", f));
|
|
35
|
+
}, o;
|
|
36
|
+
}
|
|
37
|
+
return o.prototype.isDragging = function() {
|
|
38
|
+
return this._dragging;
|
|
39
|
+
}, o.prototype.isPinching = function() {
|
|
40
|
+
return this._pinching;
|
|
41
|
+
}, o.prototype._checkPointer = function(e, t, n) {
|
|
42
|
+
var r = this._opt, i = r.zInfoParsed;
|
|
43
|
+
if (f(e, r.api, i.component)) return !1;
|
|
44
|
+
var a = r.triggerInfo, o = a.roamTrigger, s = !1;
|
|
45
|
+
return o === "global" && (s = !0), s ||= a.isInSelf(e, t, n), s && a.isInClip && !a.isInClip(e, t, n) && (s = !1), s;
|
|
46
|
+
}, o.prototype._decideCursorStyle = function(e, t, n, r) {
|
|
47
|
+
var i = e.target;
|
|
48
|
+
if (!i && this._checkPointer(e, t, n)) return this._opt.cursorGrab;
|
|
49
|
+
if (r) return i && i.cursor || "default";
|
|
50
|
+
}, o.prototype.dispose = function() {
|
|
51
|
+
this.disable();
|
|
52
|
+
}, o.prototype._mousedownHandler = function(e) {
|
|
53
|
+
if (!(l(e) || m(e))) {
|
|
54
|
+
for (var t = e.target; t;) {
|
|
55
|
+
if (t.draggable) return;
|
|
56
|
+
t = t.__hostTarget || t.parent;
|
|
57
|
+
}
|
|
58
|
+
var n = e.offsetX, r = e.offsetY;
|
|
59
|
+
this._checkPointer(e, n, r) && (this._x = n, this._y = r, this._dragging = !0);
|
|
60
|
+
}
|
|
61
|
+
}, o.prototype._mousemoveHandler = function(e) {
|
|
62
|
+
var t = this._zr;
|
|
63
|
+
if (!(e.gestureEvent === "pinch" || d(t, "globalPan") || m(e))) {
|
|
64
|
+
var n = e.offsetX, r = e.offsetY;
|
|
65
|
+
if (!this._dragging || !S("moveOnMouseMove", e, this._opt)) {
|
|
66
|
+
var i = this._decideCursorStyle(e, n, r, !1);
|
|
67
|
+
i && t.setCursorStyle(i);
|
|
68
|
+
return;
|
|
69
|
+
}
|
|
70
|
+
t.setCursorStyle(this._opt.cursorGrabbing);
|
|
71
|
+
var a = this._x, o = this._y, s = n - a, c = r - o;
|
|
72
|
+
this._x = n, this._y = r, this._opt.preventDefaultMouseMove && u(e.event), e.__ecRoamConsumed = !0, x(this, "pan", "moveOnMouseMove", e, {
|
|
73
|
+
dx: s,
|
|
74
|
+
dy: c,
|
|
75
|
+
oldX: a,
|
|
76
|
+
oldY: o,
|
|
77
|
+
newX: n,
|
|
78
|
+
newY: r,
|
|
79
|
+
isAvailableBehavior: null
|
|
80
|
+
});
|
|
81
|
+
}
|
|
82
|
+
}, o.prototype._mouseupHandler = function(e) {
|
|
83
|
+
if (!m(e)) {
|
|
84
|
+
var t = this._zr;
|
|
85
|
+
if (!l(e)) {
|
|
86
|
+
this._dragging = !1;
|
|
87
|
+
var n = this._decideCursorStyle(e, e.offsetX, e.offsetY, !0);
|
|
88
|
+
n && t.setCursorStyle(n);
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
}, o.prototype._mousewheelHandler = function(e) {
|
|
92
|
+
if (!m(e)) {
|
|
93
|
+
var t = S("zoomOnMouseWheel", e, this._opt), n = S("moveOnMouseWheel", e, this._opt), r = e.wheelDelta, i = Math.abs(r), a = e.offsetX, o = e.offsetY;
|
|
94
|
+
if (!(r === 0 || !t && !n)) {
|
|
95
|
+
if (t) {
|
|
96
|
+
var s = i > 3 ? 1.4 : i > 1 ? 1.2 : 1.1, c = r > 0 ? s : 1 / s;
|
|
97
|
+
this._checkTriggerMoveZoom(this, "zoom", "zoomOnMouseWheel", e, {
|
|
98
|
+
scale: c,
|
|
99
|
+
originX: a,
|
|
100
|
+
originY: o,
|
|
101
|
+
isAvailableBehavior: null
|
|
102
|
+
});
|
|
103
|
+
}
|
|
104
|
+
if (n) {
|
|
105
|
+
var l = Math.abs(r), u = (r > 0 ? 1 : -1) * (l > 3 ? .4 : l > 1 ? .15 : .05);
|
|
106
|
+
this._checkTriggerMoveZoom(this, "scrollMove", "moveOnMouseWheel", e, {
|
|
107
|
+
scrollDelta: u,
|
|
108
|
+
originX: a,
|
|
109
|
+
originY: o,
|
|
110
|
+
isAvailableBehavior: null
|
|
111
|
+
});
|
|
112
|
+
}
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
}, o.prototype._pinchHandler = function(e) {
|
|
116
|
+
if (!(d(this._zr, "globalPan") || m(e))) {
|
|
117
|
+
var t = e.pinchScale > 1 ? 1.1 : 1 / 1.1;
|
|
118
|
+
this._checkTriggerMoveZoom(this, "zoom", null, e, {
|
|
119
|
+
scale: t,
|
|
120
|
+
originX: e.pinchX,
|
|
121
|
+
originY: e.pinchY,
|
|
122
|
+
isAvailableBehavior: null
|
|
123
|
+
});
|
|
124
|
+
}
|
|
125
|
+
}, o.prototype._checkTriggerMoveZoom = function(e, t, n, r, i) {
|
|
126
|
+
e._checkPointer(r, i.originX, i.originY) && (u(r.event), r.__ecRoamConsumed = !0, x(e, t, n, r, i));
|
|
127
|
+
}, o;
|
|
128
|
+
}(o);
|
|
129
|
+
function m(e) {
|
|
130
|
+
return e.__ecRoamConsumed;
|
|
131
|
+
}
|
|
132
|
+
var h = s();
|
|
133
|
+
function g(e) {
|
|
134
|
+
var t = h(e);
|
|
135
|
+
return t.roam = t.roam || {}, t.uniform = t.uniform || {}, t;
|
|
136
|
+
}
|
|
137
|
+
function _(e, t, n, r) {
|
|
138
|
+
for (var i = g(e).roam, a = i[t] = i[t] || [], o = 0; o < a.length; o++) {
|
|
139
|
+
var s = a[o].zInfoParsed;
|
|
140
|
+
if ((s.zlevel - r.zlevel || s.z - r.z || s.z2 - r.z2) <= 0) break;
|
|
141
|
+
}
|
|
142
|
+
a.splice(o, 0, {
|
|
143
|
+
listener: n,
|
|
144
|
+
zInfoParsed: r
|
|
145
|
+
}), y(e, t);
|
|
146
|
+
}
|
|
147
|
+
function v(e, t, n) {
|
|
148
|
+
for (var r = g(e).roam[t] || [], i = 0; i < r.length; i++) if (r[i].listener === n) {
|
|
149
|
+
r.splice(i, 1), r.length || b(e, t);
|
|
150
|
+
return;
|
|
151
|
+
}
|
|
152
|
+
}
|
|
153
|
+
function y(e, t) {
|
|
154
|
+
var n = g(e);
|
|
155
|
+
n.uniform[t] || e.on(t, n.uniform[t] = function(e) {
|
|
156
|
+
var r = n.roam[t];
|
|
157
|
+
if (r) for (var i = 0; i < r.length; i++) r[i].listener(e);
|
|
158
|
+
});
|
|
159
|
+
}
|
|
160
|
+
function b(e, t) {
|
|
161
|
+
var n = g(e).uniform;
|
|
162
|
+
n[t] && (e.off(t, n[t]), n[t] = null);
|
|
163
|
+
}
|
|
164
|
+
function x(e, n, r, i, a) {
|
|
165
|
+
a.isAvailableBehavior = t(S, null, r, i), e.trigger(n, a);
|
|
166
|
+
}
|
|
167
|
+
function S(e, t, n) {
|
|
168
|
+
var r = n[e];
|
|
169
|
+
return !e || r && (!i(r) || t.event[r + "Key"]);
|
|
170
|
+
}
|
|
171
|
+
//#endregion
|
|
172
|
+
export { p as default };
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { retrieveZInfo as e } from "../../util/graphic.js";
|
|
2
|
+
//#region node_modules/echarts/lib/component/helper/cursorHelper.js
|
|
3
|
+
var t = {
|
|
4
|
+
axisPointer: 1,
|
|
5
|
+
tooltip: 1,
|
|
6
|
+
brush: 1
|
|
7
|
+
};
|
|
8
|
+
function n(n, r, i) {
|
|
9
|
+
var a = r.getComponentByElement(n.topTarget);
|
|
10
|
+
if (!a || a === i || t.hasOwnProperty(a.mainType)) return !1;
|
|
11
|
+
var o = a.coordinateSystem;
|
|
12
|
+
if (!o || o.model === i) return !1;
|
|
13
|
+
var s = e(a), c = e(i);
|
|
14
|
+
return !((s.zlevel - c.zlevel || s.z - c.z) <= 0);
|
|
15
|
+
}
|
|
16
|
+
//#endregion
|
|
17
|
+
export { n as onIrrelevantElement };
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { noop as e } from "../../../../zrender/lib/core/util.js";
|
|
2
|
+
import { makeInner as t } from "../../util/model.js";
|
|
3
|
+
import { registerAction as n } from "../../core/echarts.js";
|
|
4
|
+
//#region node_modules/echarts/lib/component/helper/interactionMutex.js
|
|
5
|
+
var r = t();
|
|
6
|
+
function i(e, t) {
|
|
7
|
+
return !!r(e)[t];
|
|
8
|
+
}
|
|
9
|
+
n({
|
|
10
|
+
type: "takeGlobalCursor",
|
|
11
|
+
event: "globalCursorTaken",
|
|
12
|
+
update: "update"
|
|
13
|
+
}, e);
|
|
14
|
+
//#endregion
|
|
15
|
+
export { i as isTaken };
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { addSafe as e } from "../../util/number.js";
|
|
2
|
+
//#region node_modules/echarts/lib/component/helper/sliderMove.js
|
|
3
|
+
function t(t, i, a, o, s, c) {
|
|
4
|
+
t ||= 0;
|
|
5
|
+
var l = e(a[1], -a[0]);
|
|
6
|
+
if (s != null && (s = r(s, [0, l])), c != null && (c = Math.max(c, s ?? 0)), o === "all") {
|
|
7
|
+
var u = Math.abs(e(i[1], -i[0]));
|
|
8
|
+
u = r(u, [0, l]), s = c = r(u, [s, c]), o = 0;
|
|
9
|
+
}
|
|
10
|
+
i[0] = r(i[0], a), i[1] = r(i[1], a);
|
|
11
|
+
var d = n(i, o);
|
|
12
|
+
i[o] += t;
|
|
13
|
+
var f = s || 0, p = a.slice();
|
|
14
|
+
d.sign < 0 ? p[0] = e(p[0], f) : p[1] = e(p[1], -f), i[o] = r(i[o], p);
|
|
15
|
+
var m = n(i, o);
|
|
16
|
+
return s != null && (m.sign !== d.sign || m.span < s) && (i[1 - o] = e(i[o], d.sign * s)), m = n(i, o), c != null && m.span > c && (i[1 - o] = e(i[o], m.sign * c)), i;
|
|
17
|
+
}
|
|
18
|
+
function n(e, t) {
|
|
19
|
+
var n = e[t] - e[1 - t];
|
|
20
|
+
return {
|
|
21
|
+
span: Math.abs(n),
|
|
22
|
+
sign: n > 0 ? -1 : n < 0 ? 1 : t ? -1 : 1
|
|
23
|
+
};
|
|
24
|
+
}
|
|
25
|
+
function r(e, t) {
|
|
26
|
+
return Math.min(t[1] == null ? Infinity : t[1], Math.max(t[0] == null ? -Infinity : t[0], e));
|
|
27
|
+
}
|
|
28
|
+
//#endregion
|
|
29
|
+
export { t as default };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
1
|
+
import { __extends as e } from "../../../node_modules/tslib/tslib.es6.js";
|
|
2
|
+
import { createHashMap as t, each as n, filter as r, indexOf as i, isArray as a, isNumber as o, isString as s, map as c, merge as l } from "../../../../zrender/lib/core/util.js";
|
|
3
|
+
import { isNameSpecified as u } from "../../util/model.js";
|
|
4
4
|
import d from "../../model/Model.js";
|
|
5
5
|
import f from "../../model/Component.js";
|
|
6
6
|
import p from "../../visual/tokens.js";
|
|
@@ -23,7 +23,7 @@ var m = function(e, t) {
|
|
|
23
23
|
])
|
|
24
24
|
};
|
|
25
25
|
}, h = function(f) {
|
|
26
|
-
|
|
26
|
+
e(h, f);
|
|
27
27
|
function h() {
|
|
28
28
|
var e = f !== null && f.apply(this, arguments) || this;
|
|
29
29
|
return e.type = h.type, e.layoutMode = {
|
|
@@ -36,9 +36,9 @@ var m = function(e, t) {
|
|
|
36
36
|
}, h.prototype.mergeOption = function(e, t) {
|
|
37
37
|
f.prototype.mergeOption.call(this, e, t), this._updateSelector(e);
|
|
38
38
|
}, h.prototype._updateSelector = function(e) {
|
|
39
|
-
var
|
|
40
|
-
|
|
41
|
-
|
|
39
|
+
var t = e.selector, r = this.ecModel;
|
|
40
|
+
t === !0 && (t = e.selector = ["all", "inverse"]), a(t) && n(t, function(e, n) {
|
|
41
|
+
s(e) && (e = { type: e }), t[n] = l(e, m(r, e.type));
|
|
42
42
|
});
|
|
43
43
|
}, h.prototype.optionUpdated = function() {
|
|
44
44
|
this._updateData(this.ecModel);
|
|
@@ -53,54 +53,54 @@ var m = function(e, t) {
|
|
|
53
53
|
}
|
|
54
54
|
!t && this.select(e[0].get("name"));
|
|
55
55
|
}
|
|
56
|
-
}, h.prototype._updateData = function(
|
|
57
|
-
var
|
|
58
|
-
|
|
59
|
-
var
|
|
60
|
-
i.push(
|
|
56
|
+
}, h.prototype._updateData = function(e) {
|
|
57
|
+
var n = [], i = [];
|
|
58
|
+
e.eachRawSeries(function(t) {
|
|
59
|
+
var r = t.name;
|
|
60
|
+
i.push(r);
|
|
61
61
|
var a;
|
|
62
|
-
if (
|
|
63
|
-
var o =
|
|
64
|
-
|
|
62
|
+
if (t.legendVisualProvider) {
|
|
63
|
+
var o = t.legendVisualProvider.getAllNames();
|
|
64
|
+
e.isSeriesFiltered(t) || (i = i.concat(o)), o.length ? n = n.concat(o) : a = !0;
|
|
65
65
|
} else a = !0;
|
|
66
|
-
a &&
|
|
66
|
+
a && u(t) && n.push(t.name);
|
|
67
67
|
}), this._availableNames = i;
|
|
68
|
-
var
|
|
69
|
-
return (
|
|
68
|
+
var a = this.get("data") || n, l = t(), f = c(a, function(e) {
|
|
69
|
+
return (s(e) || o(e)) && (e = { name: e }), l.get(e.name) ? null : (l.set(e.name, !0), new d(e, this, this.ecModel));
|
|
70
70
|
}, this);
|
|
71
|
-
this._data =
|
|
71
|
+
this._data = r(f, function(e) {
|
|
72
72
|
return !!e;
|
|
73
73
|
});
|
|
74
74
|
}, h.prototype.getData = function() {
|
|
75
75
|
return this._data;
|
|
76
76
|
}, h.prototype.select = function(e) {
|
|
77
|
-
var
|
|
77
|
+
var t = this.option.selected;
|
|
78
78
|
if (this.get("selectedMode") === "single") {
|
|
79
79
|
var r = this._data;
|
|
80
|
-
|
|
81
|
-
|
|
80
|
+
n(r, function(e) {
|
|
81
|
+
t[e.get("name")] = !1;
|
|
82
82
|
});
|
|
83
83
|
}
|
|
84
|
-
|
|
84
|
+
t[e] = !0;
|
|
85
85
|
}, h.prototype.unSelect = function(e) {
|
|
86
86
|
this.get("selectedMode") !== "single" && (this.option.selected[e] = !1);
|
|
87
87
|
}, h.prototype.toggleSelected = function(e) {
|
|
88
88
|
var t = this.option.selected;
|
|
89
89
|
t.hasOwnProperty(e) || (t[e] = !0), this[t[e] ? "unSelect" : "select"](e);
|
|
90
90
|
}, h.prototype.allSelect = function() {
|
|
91
|
-
var e = this._data,
|
|
92
|
-
|
|
93
|
-
|
|
91
|
+
var e = this._data, t = this.option.selected;
|
|
92
|
+
n(e, function(e) {
|
|
93
|
+
t[e.get("name", !0)] = !0;
|
|
94
94
|
});
|
|
95
95
|
}, h.prototype.inverseSelect = function() {
|
|
96
|
-
var e = this._data,
|
|
97
|
-
|
|
98
|
-
var
|
|
99
|
-
|
|
96
|
+
var e = this._data, t = this.option.selected;
|
|
97
|
+
n(e, function(e) {
|
|
98
|
+
var n = e.get("name", !0);
|
|
99
|
+
t.hasOwnProperty(n) || (t[n] = !0), t[n] = !t[n];
|
|
100
100
|
});
|
|
101
101
|
}, h.prototype.isSelected = function(e) {
|
|
102
102
|
var t = this.option.selected;
|
|
103
|
-
return !(t.hasOwnProperty(e) && !t[e]) &&
|
|
103
|
+
return !(t.hasOwnProperty(e) && !t[e]) && i(this._availableNames, e) >= 0;
|
|
104
104
|
}, h.prototype.getOrient = function() {
|
|
105
105
|
return this.get("orient") === "vertical" ? {
|
|
106
106
|
index: 1,
|