diff --git a/agenta-web/src/components/pages/evaluations/NewEvaluation/SelectEvaluatorSection.tsx b/agenta-web/src/components/pages/evaluations/NewEvaluation/SelectEvaluatorSection.tsx index 56ee8c9920..af14b05d79 100644 --- a/agenta-web/src/components/pages/evaluations/NewEvaluation/SelectEvaluatorSection.tsx +++ b/agenta-web/src/components/pages/evaluations/NewEvaluation/SelectEvaluatorSection.tsx @@ -175,7 +175,7 @@ const SelectEvaluatorSection = ({ onCancel={() => setIsEvaluatorsModalOpen(false)} current={current} setCurrent={setCurrent} - fromNewEvaluationModalFlag={true} + openedFromNewEvaluation={true} /> ) diff --git a/agenta-web/src/components/pages/evaluations/autoEvaluation/EvaluatorsModal/EvaluatorsModal.tsx b/agenta-web/src/components/pages/evaluations/autoEvaluation/EvaluatorsModal/EvaluatorsModal.tsx index a70cc93559..c1404b6114 100644 --- a/agenta-web/src/components/pages/evaluations/autoEvaluation/EvaluatorsModal/EvaluatorsModal.tsx +++ b/agenta-web/src/components/pages/evaluations/autoEvaluation/EvaluatorsModal/EvaluatorsModal.tsx @@ -16,7 +16,7 @@ import {useLocalStorage} from "usehooks-ts" type EvaluatorsModalProps = { current: number setCurrent: React.Dispatch> - fromNewEvaluationModalFlag?: boolean + openedFromNewEvaluation?: boolean } & React.ComponentProps const useStyles = createUseStyles(() => ({ @@ -43,7 +43,7 @@ const useStyles = createUseStyles(() => ({ const EvaluatorsModal = ({ current, setCurrent, - fromNewEvaluationModalFlag = false, + openedFromNewEvaluation = false, ...props }: EvaluatorsModalProps) => { const appId = useAppId() @@ -152,7 +152,7 @@ const EvaluatorsModal = ({ onSuccess={() => { evalConfigFetcher() setEditMode(false) - if (fromNewEvaluationModalFlag) { + if (openedFromNewEvaluation) { props.onCancel?.({} as any) } else { setCurrent(0)