@easyv/charts 1.10.5 → 1.10.7
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.
|
@@ -606,9 +606,9 @@ var Chart = /*#__PURE__*/(0, _react.memo)(function (_ref) {
|
|
|
606
606
|
id: "chart-clip-".concat(id)
|
|
607
607
|
}, /*#__PURE__*/_react["default"].createElement("rect", {
|
|
608
608
|
x: clipX,
|
|
609
|
-
y:
|
|
609
|
+
y: -marginTop,
|
|
610
610
|
width: xLineRange,
|
|
611
|
-
height: yLineRange,
|
|
611
|
+
height: yLineRange + marginTop,
|
|
612
612
|
fill: "transparent"
|
|
613
613
|
}))), /*#__PURE__*/_react["default"].createElement("g", {
|
|
614
614
|
clipPath: "url(#chart-clip-".concat(id, ")")
|
|
@@ -691,8 +691,8 @@ var Chart = /*#__PURE__*/(0, _react.memo)(function (_ref) {
|
|
|
691
691
|
marginTop: marginTop,
|
|
692
692
|
tickName: ctlXName,
|
|
693
693
|
series: series,
|
|
694
|
-
width:
|
|
695
|
-
height:
|
|
694
|
+
width: bodyWidth,
|
|
695
|
+
height: bodyHeight,
|
|
696
696
|
auto: auto,
|
|
697
697
|
manual: manual
|
|
698
698
|
}))), baseLineData && baseLineData.length > 0 && baseLineData.map(function (item, index) {
|
package/package.json
CHANGED
|
@@ -608,9 +608,9 @@ const Chart = memo(
|
|
|
608
608
|
<clipPath id={`chart-clip-${id}`}>
|
|
609
609
|
<rect
|
|
610
610
|
x={clipX}
|
|
611
|
-
y=
|
|
611
|
+
y={-marginTop}
|
|
612
612
|
width={xLineRange}
|
|
613
|
-
height={yLineRange}
|
|
613
|
+
height={yLineRange + marginTop}
|
|
614
614
|
fill="transparent"
|
|
615
615
|
/>
|
|
616
616
|
</clipPath>
|
|
@@ -732,8 +732,8 @@ const Chart = memo(
|
|
|
732
732
|
marginTop={marginTop}
|
|
733
733
|
tickName={ctlXName}
|
|
734
734
|
series={series}
|
|
735
|
-
width={
|
|
736
|
-
height={
|
|
735
|
+
width={bodyWidth}
|
|
736
|
+
height={bodyHeight}
|
|
737
737
|
auto={auto}
|
|
738
738
|
manual={manual}
|
|
739
739
|
/>
|
package/src/components/Chart.js
CHANGED
|
@@ -48,7 +48,7 @@ const Chart = memo(
|
|
|
48
48
|
const isIOS = useRef(
|
|
49
49
|
/iPad|iPhone|iPod|iOS/i.test(navigator.userAgent) ||
|
|
50
50
|
(/Mac OS X/i.test(navigator.userAgent) &&
|
|
51
|
-
!/Chrome/i.test(navigator.userAgent))
|
|
51
|
+
!/Chrome/i.test(navigator.userAgent)),
|
|
52
52
|
);
|
|
53
53
|
const svg = createRef();
|
|
54
54
|
const chartWidth = width - marginLeft - marginRight;
|
|
@@ -81,12 +81,12 @@ const Chart = memo(
|
|
|
81
81
|
});
|
|
82
82
|
}
|
|
83
83
|
},
|
|
84
|
-
[JSON.stringify(interaction)]
|
|
84
|
+
[JSON.stringify(interaction)],
|
|
85
85
|
);
|
|
86
86
|
|
|
87
87
|
const onEmit = useCallback(
|
|
88
88
|
(type = "click", data) => emit && emit(type, data),
|
|
89
|
-
[emit]
|
|
89
|
+
[emit],
|
|
90
90
|
);
|
|
91
91
|
|
|
92
92
|
const context = useMemo(
|
|
@@ -101,7 +101,7 @@ const Chart = memo(
|
|
|
101
101
|
svg,
|
|
102
102
|
onEmit,
|
|
103
103
|
}),
|
|
104
|
-
[id, chartWidth, chartHeight, triggerOnRelative, svg, onEmit]
|
|
104
|
+
[id, chartWidth, chartHeight, triggerOnRelative, svg, onEmit],
|
|
105
105
|
);
|
|
106
106
|
|
|
107
107
|
useEffect(() => {
|
|
@@ -185,7 +185,7 @@ const Chart = memo(
|
|
|
185
185
|
} catch (e) {}
|
|
186
186
|
return [];
|
|
187
187
|
}
|
|
188
|
-
}
|
|
188
|
+
},
|
|
189
189
|
);
|
|
190
190
|
|
|
191
191
|
export default Chart;
|