part 3 of on click bar to filters: add sort plus some normalizations (#16075)

This commit is contained in:
nitin
2025-11-26 19:48:48 +05:30
committed by GitHub
parent dc2c2c413c
commit 6fcb05d9b3
25 changed files with 942 additions and 80 deletions
@@ -9,9 +9,16 @@ export const isMinMaxRangeValid = (
newValue: number,
configuration: ChartConfiguration,
): boolean => {
const isBarOrLineChart =
configuration.__typename === 'BarChartConfiguration' ||
configuration.__typename === 'LineChartConfiguration';
if (!isBarOrLineChart) {
return true;
}
if (settingId === CHART_CONFIGURATION_SETTING_IDS.MIN_RANGE) {
if (
'rangeMax' in configuration &&
isDefined(configuration.rangeMax) &&
newValue > configuration.rangeMax
) {
@@ -21,7 +28,6 @@ export const isMinMaxRangeValid = (
if (settingId === CHART_CONFIGURATION_SETTING_IDS.MAX_RANGE) {
if (
'rangeMin' in configuration &&
isDefined(configuration.rangeMin) &&
newValue < configuration.rangeMin
) {