Skip to content

Commit 590f8c6

Browse files
committed
saving dataMin and dataMax in symologyState in Singleband Pseudocolor
1 parent 0a4a19f commit 590f8c6

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

packages/base/src/dialogs/symbology/components/color_ramp/ColorRampControls.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,8 @@ export type ColorRampControlsOptions = {
6262
maxValue: number;
6363
criticalValue?: number;
6464
reverseRamp: boolean;
65+
dataMin?: number;
66+
dataMax?: number;
6567
};
6668

6769
const isValidNumberOfShades = (value: number) => !isNaN(value) && value > 0;

packages/base/src/dialogs/symbology/tiff_layer/types/SingleBandPseudoColor.tsx

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -281,6 +281,8 @@ const SingleBandPseudoColor: React.FC<ISymbologyDialogProps> = ({
281281
mode: colorRampOptionsRef.current?.selectedMode,
282282
min: colorRampOptionsRef.current?.minValue,
283283
max: colorRampOptionsRef.current?.maxValue,
284+
dataMin: colorRampOptionsRef.current?.dataMin,
285+
dataMax: colorRampOptionsRef.current?.dataMax,
284286
};
285287

286288
layer.parameters.symbologyState = symbologyState;
@@ -325,6 +327,8 @@ const SingleBandPseudoColor: React.FC<ISymbologyDialogProps> = ({
325327
selectedMode,
326328
minValue,
327329
maxValue,
330+
dataMin,
331+
dataMax,
328332
});
329333

330334
let stops: number[] = [];

0 commit comments

Comments
 (0)