reke-ui 0.5.2 → 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 +764 -3
- 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/components/reke-dialog/reke-dialog.d.ts +19 -0
- package/dist/components/reke-dialog/reke-dialog.d.ts.map +1 -1
- package/dist/components/reke-dialog/reke-dialog.js +40 -15
- package/dist/components/reke-dialog/reke-dialog.styles.d.ts.map +1 -1
- package/dist/components/reke-dialog/reke-dialog.styles.js +110 -0
- package/dist/components/reke-pie-chart/reke-pie-chart.d.ts +52 -1
- package/dist/components/reke-pie-chart/reke-pie-chart.d.ts.map +1 -1
- package/dist/components/reke-pie-chart/reke-pie-chart.js +181 -42
- package/dist/components/reke-pie-chart/reke-pie-chart.styles.d.ts.map +1 -1
- package/dist/components/reke-pie-chart/reke-pie-chart.styles.js +47 -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 +10 -0
- package/dist/react.d.ts.map +1 -1
- package/dist/react.js +85 -73
- package/dist/shared/tailwind.js +1 -1
- package/dist/tokens/reke-tokens.css +1 -0
- package/package.json +5 -1
|
@@ -1,19 +1,22 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { assert as e, each as t, keys as n, retrieve as r, retrieve3 as i } from "../../../../zrender/lib/core/util.js";
|
|
2
|
+
import { SINGLE_REFERRING as a } from "../../util/model.js";
|
|
3
|
+
import { isIntervalOrLogScale as o } from "../../scale/helper.js";
|
|
4
|
+
import s from "../../component/axis/AxisBuilder.js";
|
|
2
5
|
//#region node_modules/echarts/lib/coord/cartesian/cartesianAxisHelper.js
|
|
3
|
-
function
|
|
4
|
-
|
|
5
|
-
var i =
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
6
|
+
function c(e, t, n) {
|
|
7
|
+
n ||= {};
|
|
8
|
+
var i = t.axis, a = {}, o = i.getAxesOnZeroOf()[0], s = i.position, c = o ? "onZero" : s, l = i.dim, u = [
|
|
9
|
+
e.x,
|
|
10
|
+
e.x + e.width,
|
|
11
|
+
e.y,
|
|
12
|
+
e.y + e.height
|
|
10
13
|
], d = {
|
|
11
14
|
left: 0,
|
|
12
15
|
right: 1,
|
|
13
16
|
top: 0,
|
|
14
17
|
bottom: 1,
|
|
15
18
|
onZero: 2
|
|
16
|
-
}, f =
|
|
19
|
+
}, f = t.get("offset") || 0, p = l === "x" ? [u[2] - f, u[3] + f] : [u[0] - f, u[1] + f];
|
|
17
20
|
if (o) {
|
|
18
21
|
var m = o.toGlobalCoord(o.dataToCoord(0));
|
|
19
22
|
p[d.onZero] = Math.max(Math.min(m, p[1]), p[0]);
|
|
@@ -23,9 +26,37 @@ function t(t, n, r) {
|
|
|
23
26
|
bottom: 1,
|
|
24
27
|
left: -1,
|
|
25
28
|
right: 1
|
|
26
|
-
}[s], a.labelOffset = o ? p[d[s]] - p[d.onZero] : 0,
|
|
27
|
-
var h =
|
|
29
|
+
}[s], a.labelOffset = o ? p[d[s]] - p[d.onZero] : 0, t.get(["axisTick", "inside"]) && (a.tickDirection = -a.tickDirection), r(n.labelInside, t.get(["axisLabel", "inside"])) && (a.labelDirection = -a.labelDirection);
|
|
30
|
+
var h = t.get(["axisLabel", "rotate"]);
|
|
28
31
|
return a.labelRotate = c === "top" ? -h : h, a.z2 = 1, a;
|
|
29
32
|
}
|
|
33
|
+
function l(e) {
|
|
34
|
+
return e.coordinateSystem && e.coordinateSystem.type === "cartesian2d";
|
|
35
|
+
}
|
|
36
|
+
function u(e) {
|
|
37
|
+
var n = {
|
|
38
|
+
xAxisModel: null,
|
|
39
|
+
yAxisModel: null
|
|
40
|
+
};
|
|
41
|
+
return t(n, function(t, r) {
|
|
42
|
+
var o = r.replace(/Model$/, ""), s = e.getReferringComponents(o, a).models[0];
|
|
43
|
+
if (process.env.NODE_ENV !== "production" && !s) throw Error(o + " \"" + i(e.get(o + "Index"), e.get(o + "Id"), 0) + "\" not found");
|
|
44
|
+
n[r] = s;
|
|
45
|
+
}), n;
|
|
46
|
+
}
|
|
47
|
+
function d(e, t, n, r, i, a) {
|
|
48
|
+
for (var l = c(e, n), u = !1, d = !1, f = 0; f < t.length; f++) o(t[f].getOtherAxis(n.axis).scale) && (u = d = !0, n.axis.type === "category" && n.axis.onBand && (d = !1));
|
|
49
|
+
return l.axisLineAutoShow = u, l.axisTickAutoShow = d, l.defaultNameMoveOverlap = a, new s(n, r, l, i);
|
|
50
|
+
}
|
|
51
|
+
function f(r, i, a) {
|
|
52
|
+
var o = c(i, a);
|
|
53
|
+
if (process.env.NODE_ENV !== "production") {
|
|
54
|
+
var s = r.__getRawCfg();
|
|
55
|
+
t(n(o), function(t) {
|
|
56
|
+
t !== "position" && t !== "labelOffset" && e(o[t] === s[t]);
|
|
57
|
+
});
|
|
58
|
+
}
|
|
59
|
+
r.updateCfg(o);
|
|
60
|
+
}
|
|
30
61
|
//#endregion
|
|
31
|
-
export {
|
|
62
|
+
export { d as createCartesianAxisViewCommonPartBuilder, u as findAxisModels, l as isCartesian2DInjectedAsDataCoordSys, c as layout, f as updateCartesianAxisViewCommonPartBuilder };
|
|
@@ -0,0 +1,175 @@
|
|
|
1
|
+
import { assert as e, createHashMap as t, each as n, eqNaN as r, isArray as i, isFunction as a } from "../../../zrender/lib/core/util.js";
|
|
2
|
+
import { parsePercent as o } from "../../../zrender/lib/contain/text.js";
|
|
3
|
+
import { isNullableNumberFinite as s, mathMax as c, mathMin as l } from "../util/number.js";
|
|
4
|
+
import { error as u } from "../util/log.js";
|
|
5
|
+
import { ensureExtentAscSimply as d, extentHasValue as f, initExtentForUnion as p, isValidNumberForExtent as m, makeInner as h, unionExtentEndFromNumber as g, unionExtentFromExtent as _, unionExtentFromNumber as v, unionExtentStartFromNumber as y } from "../util/model.js";
|
|
6
|
+
import { getCoordForCoordSysUsageKindBox as b } from "../core/CoordinateSystem.js";
|
|
7
|
+
import { isIntervalScale as x, isLogScale as S, isOrdinalScale as C, isTimeScale as w } from "../scale/helper.js";
|
|
8
|
+
import { discourageOnAxisZero as T, getDataDimensionsOnAxis as E, isAxisOnBand as D } from "./axisHelper.js";
|
|
9
|
+
import { eachKeyOnAxis as O, eachSeriesOnAxis as k } from "./axisStatistics.js";
|
|
10
|
+
//#region node_modules/echarts/lib/coord/scaleRawExtentInfo.js
|
|
11
|
+
var A = h(), j = 3, M = function() {
|
|
12
|
+
function e(e, t, n, i, o) {
|
|
13
|
+
var c = C(e), l = c ? t.getCategories().length : null, u;
|
|
14
|
+
if (c) {
|
|
15
|
+
var d = t.getCategories(!0);
|
|
16
|
+
u = d && !d.length;
|
|
17
|
+
}
|
|
18
|
+
var p = n.slice();
|
|
19
|
+
(x(e) || S(e) || w(e)) && (y(p, P(e, t.get("dataMin", !0))), g(p, P(e, t.get("dataMax", !0)))), f(p) || (p[0] = p[1] = NaN);
|
|
20
|
+
var h = [], _ = [!1, !1], v = t.get("min", !0);
|
|
21
|
+
v === "dataMin" ? (h[0] = p[0], _[0] = !0) : (h[0] = P(e, a(v) ? v({
|
|
22
|
+
min: p[0],
|
|
23
|
+
max: p[1]
|
|
24
|
+
}) : v), _[0] = h[0] != null);
|
|
25
|
+
var b = t.get("max", !0);
|
|
26
|
+
b === "dataMax" ? (h[1] = p[1], _[1] = !0) : (h[1] = P(e, a(b) ? b({
|
|
27
|
+
min: p[0],
|
|
28
|
+
max: p[1]
|
|
29
|
+
}) : b), _[1] = h[1] != null);
|
|
30
|
+
var T = F(e, t), E = c ? null : p[1] - p[0] || Math.abs(p[0]);
|
|
31
|
+
h[0] ??= c ? u ? p[0] : l ? 0 : NaN : p[0] - T[0] * E, h[1] ??= c ? u ? p[1] : l ? l - 1 : NaN : p[1] + T[1] * E, !m(h[0]) && (h[0] = NaN), !m(h[1]) && (h[1] = NaN);
|
|
32
|
+
var D = u || r(h[0]) || r(h[1]) || c && !l, O = x(e), k = O && t.needIncludeZero && t.needIncludeZero();
|
|
33
|
+
k && (h[0] > 0 && h[1] > 0 && !_[0] && (h[0] = 0), h[0] < 0 && h[1] < 0 && !_[1] && (h[1] = 0));
|
|
34
|
+
var A = !1;
|
|
35
|
+
h[0] > h[1] && (h.reverse(), A = !0);
|
|
36
|
+
var j = P(e, t.get("startValue", !0)), M = j != null;
|
|
37
|
+
!s(j) && i && (j = e.getDefaultStartValue ? e.getDefaultStartValue() : 0), s(j) && (M || !O || k) && (j < h[0] && !_[0] ? (h[0] = j, _[0] = !0) : j > h[1] && !_[1] && (h[1] = j, _[1] = !0)), N(this._i = {
|
|
38
|
+
scale: e,
|
|
39
|
+
dataMM: p,
|
|
40
|
+
noZoomEffMM: h,
|
|
41
|
+
zoomMM: [],
|
|
42
|
+
fixMM: _,
|
|
43
|
+
zoomFixMM: [!1, !1],
|
|
44
|
+
startValue: j,
|
|
45
|
+
isBlank: D,
|
|
46
|
+
incl0: k,
|
|
47
|
+
tggAxInv: A,
|
|
48
|
+
ctnShp: o
|
|
49
|
+
}, h);
|
|
50
|
+
}
|
|
51
|
+
return e.prototype.makeNoZoom = function() {
|
|
52
|
+
return this._i.noZoomEffMM.slice();
|
|
53
|
+
}, e.prototype.makeFinal = function() {
|
|
54
|
+
var e = this._i, t = e.zoomMM, n = e.noZoomEffMM, r = e.zoomFixMM, i = e.fixMM, a = {
|
|
55
|
+
fixMM: i,
|
|
56
|
+
zoomFixMM: r,
|
|
57
|
+
isBlank: e.isBlank,
|
|
58
|
+
incl0: e.incl0,
|
|
59
|
+
tggAxInv: e.tggAxInv,
|
|
60
|
+
ctnShp: e.ctnShp,
|
|
61
|
+
effMM: n.slice()
|
|
62
|
+
}, o = a.effMM;
|
|
63
|
+
return t[0] != null && (o[0] = t[0], i[0] = r[0] = !0), t[1] != null && (o[1] = t[1], i[1] = r[1] = !0), N(e, o), a;
|
|
64
|
+
}, e.prototype.makeRenderInfo = function() {
|
|
65
|
+
return { startValue: this._i.startValue };
|
|
66
|
+
}, e.prototype.setZoomMM = function(e, t) {
|
|
67
|
+
this._i.zoomMM[e] = t;
|
|
68
|
+
}, e;
|
|
69
|
+
}();
|
|
70
|
+
function N(e, t) {
|
|
71
|
+
var n = e.scale, r = e.dataMM;
|
|
72
|
+
n.sanitize && (t[0] = n.sanitize(t[0], r), t[1] = n.sanitize(t[1], r), d(t));
|
|
73
|
+
}
|
|
74
|
+
function P(e, t) {
|
|
75
|
+
return t == null ? null : r(t) ? NaN : e.parse(t);
|
|
76
|
+
}
|
|
77
|
+
function F(e, t) {
|
|
78
|
+
var n;
|
|
79
|
+
if (C(e)) n = [0, 0];
|
|
80
|
+
else {
|
|
81
|
+
var r = t.get("boundaryGap");
|
|
82
|
+
typeof r == "boolean" && (process.env.NODE_ENV !== "production" && r === !0 && console.warn("Boolean type for boundaryGap is only allowed for ordinal axis. Please use string in percentage instead, e.g., \"20%\". Currently, boundaryGap is set to 0."), r = null), n = i(r) ? r : [r, r];
|
|
83
|
+
}
|
|
84
|
+
return [I(n[0]), I(n[1])];
|
|
85
|
+
}
|
|
86
|
+
function I(e) {
|
|
87
|
+
return o(typeof e == "boolean" ? 0 : e, 1) || 0;
|
|
88
|
+
}
|
|
89
|
+
function L(e) {
|
|
90
|
+
var t = A(e.scale);
|
|
91
|
+
return t.extent ||= p(), t;
|
|
92
|
+
}
|
|
93
|
+
function R(e, t) {
|
|
94
|
+
L(e).dimIdxInCoord = t.get(e.dim);
|
|
95
|
+
}
|
|
96
|
+
function z(t, n) {
|
|
97
|
+
var r = t.scale, i = t.model, a = t.dim;
|
|
98
|
+
if (process.env.NODE_ENV !== "production" && e(r && i && a), r.rawExtentInfo) {
|
|
99
|
+
process.env.NODE_ENV !== "production" && e(r.rawExtentInfo.from !== n || n === 2);
|
|
100
|
+
return;
|
|
101
|
+
}
|
|
102
|
+
B(r, t, a, i, n);
|
|
103
|
+
}
|
|
104
|
+
function B(e, t, r, a, o) {
|
|
105
|
+
var s = L(t), c = s.extent, l = !1;
|
|
106
|
+
k(t, function(a) {
|
|
107
|
+
if (a.boxCoordinateSystem) {
|
|
108
|
+
var o = b(a).coord, d = s.dimIdxInCoord;
|
|
109
|
+
if (!(d >= 0)) process.env.NODE_ENV !== "production" && u("Property \"series.coord\" is not supported on axis " + a.boxCoordinateSystem.type + ".");
|
|
110
|
+
else if (i(o)) {
|
|
111
|
+
var f = o[d];
|
|
112
|
+
f != null && !i(f) && v(c, e.parse(f));
|
|
113
|
+
}
|
|
114
|
+
} else if (a.coordinateSystem) {
|
|
115
|
+
var p = a.getData();
|
|
116
|
+
if (p) {
|
|
117
|
+
var m = e.getFilter ? e.getFilter() : null;
|
|
118
|
+
n(E(p, r), function(e) {
|
|
119
|
+
_(c, p.getApproximateExtent(e, m));
|
|
120
|
+
});
|
|
121
|
+
}
|
|
122
|
+
a.__requireStartValue && a.__requireStartValue(t) && (l = !0);
|
|
123
|
+
}
|
|
124
|
+
});
|
|
125
|
+
var d = K(e, t, a);
|
|
126
|
+
H(e, new M(e, a, c, l, d), o), s.extent = null;
|
|
127
|
+
}
|
|
128
|
+
function V(t, n) {
|
|
129
|
+
var r = t.scale;
|
|
130
|
+
process.env.NODE_ENV !== "production" && e(!r.rawExtentInfo), H(r, new M(r, t.model, n, !1, !1), j);
|
|
131
|
+
}
|
|
132
|
+
function H(e, t, n) {
|
|
133
|
+
e.rawExtentInfo = t, t.from = n;
|
|
134
|
+
}
|
|
135
|
+
function U(t, n) {
|
|
136
|
+
process.env.NODE_ENV !== "production" && e(!W.get(t)), W.set(t, n);
|
|
137
|
+
}
|
|
138
|
+
var W = t();
|
|
139
|
+
function G(t, n, r, i, a) {
|
|
140
|
+
process.env.NODE_ENV !== "production" && e(!a || !t.rawExtentInfo), t.rawExtentInfo || V({
|
|
141
|
+
scale: t,
|
|
142
|
+
model: n
|
|
143
|
+
}, a || p());
|
|
144
|
+
var o = t.rawExtentInfo.makeFinal(), s = o.effMM;
|
|
145
|
+
return t.setExtent(s[0], s[1]), t.setBlank(o.isBlank), i && o.tggAxInv && r && !r.get("legacyMinMaxDontInverseAxis") && (i.inverse = !i.inverse), o;
|
|
146
|
+
}
|
|
147
|
+
function K(e, t, n) {
|
|
148
|
+
var r = D(e, n), i = n.get("containShape", !0);
|
|
149
|
+
if (i == null && !r && (i = !0), !i) return !1;
|
|
150
|
+
var a = !1;
|
|
151
|
+
return O(t, function(e) {
|
|
152
|
+
a = !!W.get(e) || a;
|
|
153
|
+
}), a;
|
|
154
|
+
}
|
|
155
|
+
function q(e, t, n, r) {
|
|
156
|
+
if (n.ctnShp) {
|
|
157
|
+
var i;
|
|
158
|
+
if (O(e, function(t) {
|
|
159
|
+
var n = W.get(t);
|
|
160
|
+
if (n) {
|
|
161
|
+
var a = n(e, r);
|
|
162
|
+
a && (i ||= [0, 0], y(i, a[0]), g(i, a[1]), T(e));
|
|
163
|
+
}
|
|
164
|
+
}), i) {
|
|
165
|
+
var a = t.getExtent();
|
|
166
|
+
if (C(t)) e.onBand || t.setExtent2(1, l(a[0], a[0] + i[0]), c(a[1], a[1] + i[1]));
|
|
167
|
+
else {
|
|
168
|
+
var o = a.slice();
|
|
169
|
+
n.zoomFixMM[0] || (o[0] = l(o[0], t.transformOut(t.transformIn(o[0], null) + i[0], null))), n.zoomFixMM[1] || (o[1] = c(o[1], t.transformOut(t.transformIn(o[1], null) + i[1], null))), (o[0] < a[0] || o[1] > a[1]) && t.setExtent2(1, o[0], o[1]);
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
}
|
|
173
|
+
}
|
|
174
|
+
//#endregion
|
|
175
|
+
export { q as adoptScaleExtentKindMapping, G as adoptScaleRawExtentInfoAndPrepare, U as registerAxisContainShapeHandler, z as scaleRawExtentInfoCreate, R as scaleRawExtentInfoEnableBoxCoordSysUsage };
|
|
@@ -1,16 +1,17 @@
|
|
|
1
1
|
import { assert as e, createHashMap as t, each as n } from "../../../zrender/lib/core/util.js";
|
|
2
|
+
import { error as r } from "../util/log.js";
|
|
2
3
|
//#region node_modules/echarts/lib/core/CoordinateSystem.js
|
|
3
|
-
var
|
|
4
|
+
var i = {}, a = {}, o = function() {
|
|
4
5
|
function t() {
|
|
5
6
|
this._normalMasterList = [], this._nonSeriesBoxMasterList = [];
|
|
6
7
|
}
|
|
7
|
-
return t.prototype.create = function(t,
|
|
8
|
-
this._nonSeriesBoxMasterList = o(
|
|
9
|
-
function o(
|
|
8
|
+
return t.prototype.create = function(t, r) {
|
|
9
|
+
this._nonSeriesBoxMasterList = o(i, !0), this._normalMasterList = o(a, !1);
|
|
10
|
+
function o(i, a) {
|
|
10
11
|
var o = [];
|
|
11
|
-
return n(
|
|
12
|
-
var c =
|
|
13
|
-
o = o.concat(c || []), process.env.NODE_ENV !== "production" &&
|
|
12
|
+
return n(i, function(i, s) {
|
|
13
|
+
var c = i.create(t, r);
|
|
14
|
+
o = o.concat(c || []), process.env.NODE_ENV !== "production" && a && n(c, function(t) {
|
|
14
15
|
return e(!t.update);
|
|
15
16
|
});
|
|
16
17
|
}), o;
|
|
@@ -23,22 +24,25 @@ var r = {}, i = {}, a = function() {
|
|
|
23
24
|
return this._normalMasterList.concat(this._nonSeriesBoxMasterList);
|
|
24
25
|
}, t.register = function(e, t) {
|
|
25
26
|
if (e === "matrix" || e === "calendar") {
|
|
26
|
-
|
|
27
|
+
i[e] = t;
|
|
27
28
|
return;
|
|
28
29
|
}
|
|
29
|
-
|
|
30
|
+
a[e] = t;
|
|
30
31
|
}, t.get = function(e) {
|
|
31
|
-
return
|
|
32
|
+
return a[e] || i[e];
|
|
32
33
|
}, t;
|
|
33
34
|
}();
|
|
34
|
-
function
|
|
35
|
-
|
|
35
|
+
function s(e) {
|
|
36
|
+
return !!i[e];
|
|
36
37
|
}
|
|
37
|
-
|
|
38
|
-
|
|
38
|
+
function c(t) {
|
|
39
|
+
process.env.NODE_ENV !== "production" && e(!l.get(t.fullType)), l.set(t.fullType, { getCoord2: void 0 }).getCoord2 = t.getCoord2;
|
|
40
|
+
}
|
|
41
|
+
var l = t();
|
|
42
|
+
function u(e) {
|
|
39
43
|
var t = e.getShallow("coord", !0), n = 1;
|
|
40
44
|
if (t == null) {
|
|
41
|
-
var r =
|
|
45
|
+
var r = l.get(e.type);
|
|
42
46
|
r && r.getCoord2 && (n = 2, t = r.getCoord2(e));
|
|
43
47
|
}
|
|
44
48
|
return {
|
|
@@ -46,5 +50,24 @@ function c(e) {
|
|
|
46
50
|
from: n
|
|
47
51
|
};
|
|
48
52
|
}
|
|
53
|
+
function d(e, t) {
|
|
54
|
+
var n = e.getShallow("coordinateSystem"), i = e.getShallow("coordinateSystemUsage", !0), a = i != null, o = 0;
|
|
55
|
+
if (n) {
|
|
56
|
+
var c = e.mainType === "series";
|
|
57
|
+
i ??= c ? "data" : "box", i === "data" ? (o = 1, c || (process.env.NODE_ENV !== "production" && a && t && r("coordinateSystemUsage \"data\" is not supported in non-series components."), o = 0)) : i === "box" && (o = 2, !c && !s(n) && (process.env.NODE_ENV !== "production" && a && t && r("coordinateSystem \"" + n + "\" cannot be used" + (" as coordinateSystemUsage \"box\" for \"" + e.type + "\" yet.")), o = 0));
|
|
58
|
+
}
|
|
59
|
+
return {
|
|
60
|
+
coordSysType: n,
|
|
61
|
+
kind: o
|
|
62
|
+
};
|
|
63
|
+
}
|
|
64
|
+
function f(t) {
|
|
65
|
+
var n = t.targetModel, i = t.coordSysType, a = t.coordSysProvider, o = t.isDefaultDataCoordSys, s = t.allowNotFound;
|
|
66
|
+
process.env.NODE_ENV !== "production" && e(!!i);
|
|
67
|
+
var c = d(n, !0), l = c.kind, u = c.coordSysType;
|
|
68
|
+
if (o && l !== 1 && (l = 1, u = i), l === 0 || u !== i) return 0;
|
|
69
|
+
var f = a(i, n);
|
|
70
|
+
return f ? (l === 1 ? (process.env.NODE_ENV !== "production" && e(n.mainType === "series"), n.coordinateSystem = f) : n.boxCoordinateSystem = f, l) : (process.env.NODE_ENV !== "production" && (s || r(i + " cannot be found for" + (" " + n.type + " (index: " + n.componentIndex + ")."))), 0);
|
|
71
|
+
}
|
|
49
72
|
//#endregion
|
|
50
|
-
export {
|
|
73
|
+
export { o as default, u as getCoordForCoordSysUsageKindBox, f as injectCoordSysByOption, c as registerLayOutOnCoordSysUsage };
|