Skip to content

Commit

Permalink
ISSUE #5173 - fix: vertical range validation fails if either value is…
Browse files Browse the repository at this point in the history
… "0"
  • Loading branch information
Amantini1997 committed Sep 27, 2024
1 parent 92ae050 commit f0c4b7c
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ import { ContainersHooksSelectors, FederationsHooksSelectors } from '@/v5/servic
import { useContext } from 'react';
import { CalibrationContext } from '../calibrationContext';
import { ViewerParams } from '@/v5/ui/routes/routes.constants';
import { isNumber } from 'lodash';

const STEPS = [
formatMessage({ defaultMessage: '3D Alignment', id: 'calibration.step.3dCalibration' }),
Expand All @@ -43,7 +44,7 @@ export const CalibrationHeader = () => {
const getIsStepValid = () => {
if (step === 0) return !!(vector3D[0] && vector3D[1]);
if (step === 1) return !!(vector2D[0] && vector2D[1]);
if (step === 2) return !!(verticalPlanes[0] && verticalPlanes[1]);
if (step === 2) return verticalPlanes.every(isNumber);
return false;
};

Expand Down

0 comments on commit f0c4b7c

Please sign in to comment.