Skip to content

Commit

Permalink
catch more changes for colormap updates
Browse files Browse the repository at this point in the history
  • Loading branch information
lstillwe committed Oct 11, 2024
1 parent b95c339 commit a77cf96
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/components/trays/settings/colormaps/style-edit.js
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ export const StyleEditor = () => {
// and now has been changed to ramp
// in that case we have modify the last colormap entry
else {
if ((value.type === "ramp") && (value.colorMapEntries[value.colorMapEntries.length-1].label.includes(">="))) {
if (value.colorMapEntries[value.colorMapEntries.length-1].label.includes(">=")) {
const last = value.colorMapEntries.length-1;
value.colorMapEntries[last].quantity = parseFloat(value.colorMapEntries[last].label.match(/[+-]?\d+(\.\d+)?/g)).toFixed(2);
const labelParts = value.colorMapEntries[last].label.split(" ");
Expand Down

0 comments on commit a77cf96

Please sign in to comment.