@oliasoft-open-source/charts-library 3.5.3-beta-2 → 3.5.3-beta-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/dist/index.js +8 -9
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -22275,6 +22275,8 @@ const initialState = ({ options, persistenceId }) => {
|
|
|
22275
22275
|
} = options;
|
|
22276
22276
|
const getStateAxesByType = (axisType, customAxesRange2) => {
|
|
22277
22277
|
var _a2, _b2, _c2, _d2, _e2;
|
|
22278
|
+
console.log("axisType", axisType);
|
|
22279
|
+
console.log("axes", axes);
|
|
22278
22280
|
if (!axes[axisType]) {
|
|
22279
22281
|
return [];
|
|
22280
22282
|
}
|
|
@@ -23711,9 +23713,9 @@ const useChartFunctions = ({
|
|
|
23711
23713
|
const onResetAxes = useCallback(() => {
|
|
23712
23714
|
dispatch({ type: RESET_AXES_RANGES });
|
|
23713
23715
|
}, []);
|
|
23714
|
-
const onUpdateAxes =
|
|
23716
|
+
const onUpdateAxes = ({ axes: axes2 }) => {
|
|
23715
23717
|
dispatch({ type: UPDATE_AXES_RANGES, payload: { axes: axes2 } });
|
|
23716
|
-
}
|
|
23718
|
+
};
|
|
23717
23719
|
return {
|
|
23718
23720
|
legendClick,
|
|
23719
23721
|
resetZoom: resetZoom2,
|
|
@@ -25429,7 +25431,7 @@ const useUpdateAxesRanges = (range, dispatch) => {
|
|
|
25429
25431
|
min: min ?? 0,
|
|
25430
25432
|
max: max ?? 0
|
|
25431
25433
|
})) : null;
|
|
25432
|
-
if (!isEqual(axes, prevAxes.current)) {
|
|
25434
|
+
if (!isEqual(axes, prevAxes.current) && axes !== null) {
|
|
25433
25435
|
dispatch({
|
|
25434
25436
|
type: UPDATE_AXES_RANGES,
|
|
25435
25437
|
payload: { axes }
|
|
@@ -25698,12 +25700,9 @@ const LineChart = (props) => {
|
|
|
25698
25700
|
},
|
|
25699
25701
|
initialState
|
|
25700
25702
|
);
|
|
25701
|
-
const generatedDatasets =
|
|
25702
|
-
datasets,
|
|
25703
|
-
|
|
25704
|
-
options,
|
|
25705
|
-
translations
|
|
25706
|
-
);
|
|
25703
|
+
const generatedDatasets = useMemo(() => {
|
|
25704
|
+
return generateLineChartDatasets(datasets, state, options, translations);
|
|
25705
|
+
}, [state.lineEnabled, state.pointsEnabled, axes, annotations, graph]);
|
|
25707
25706
|
useChartState({
|
|
25708
25707
|
chartRef,
|
|
25709
25708
|
options,
|