From 4e8ff1ccceb050cd3e5bb5b65385141db43982ca Mon Sep 17 00:00:00 2001 From: Bastien Dumont <bdumont@grandlyon.com> Date: Mon, 20 Mar 2023 17:32:12 +0100 Subject: [PATCH] chore: fix typo previoust --- .../EcogestureForm/EcogestureFormSingleChoice.spec.tsx | 10 +++++----- .../EcogestureForm/EcogestureFormSingleChoice.tsx | 8 ++++---- src/components/EcogestureForm/EcogestureFormView.tsx | 2 +- .../EcogestureFormSingleChoice.spec.tsx.snap | 2 +- .../__snapshots__/EcogestureFormView.spec.tsx.snap | 2 +- 5 files changed, 12 insertions(+), 12 deletions(-) diff --git a/src/components/EcogestureForm/EcogestureFormSingleChoice.spec.tsx b/src/components/EcogestureForm/EcogestureFormSingleChoice.spec.tsx index 161e0d8ba..08b6e351d 100644 --- a/src/components/EcogestureForm/EcogestureFormSingleChoice.spec.tsx +++ b/src/components/EcogestureForm/EcogestureFormSingleChoice.spec.tsx @@ -47,7 +47,7 @@ describe('EcogestureFormSingleChoice component', () => { step={0} viewedStep={-1} setNextStep={mockHandleNextStep} - setPrevioustStep={mockHandlePreviousStep} + setPreviousStep={mockHandlePreviousStep} profileEcogesture={mockProfileEcogesture} answerType={mockEcogestureAnswer} /> @@ -63,7 +63,7 @@ describe('EcogestureFormSingleChoice component', () => { step={0} viewedStep={-1} setNextStep={mockHandleNextStep} - setPrevioustStep={mockHandlePreviousStep} + setPreviousStep={mockHandlePreviousStep} profileEcogesture={mockProfileEcogesture} answerType={mockEcogestureAnswer} /> @@ -81,7 +81,7 @@ describe('EcogestureFormSingleChoice component', () => { step={0} viewedStep={-1} setNextStep={mockHandleNextStep} - setPrevioustStep={mockHandlePreviousStep} + setPreviousStep={mockHandlePreviousStep} profileEcogesture={mockProfileEcogesture} answerType={mockEcogestureAnswer} /> @@ -101,7 +101,7 @@ describe('EcogestureFormSingleChoice component', () => { step={1} viewedStep={0} setNextStep={mockHandleNextStep} - setPrevioustStep={mockHandlePreviousStep} + setPreviousStep={mockHandlePreviousStep} profileEcogesture={mockProfileEcogesture} answerType={mockEcogestureAnswer} /> @@ -118,7 +118,7 @@ describe('EcogestureFormSingleChoice component', () => { step={0} viewedStep={1} setNextStep={mockHandleNextStep} - setPrevioustStep={mockHandlePreviousStep} + setPreviousStep={mockHandlePreviousStep} profileEcogesture={mockProfileEcogesture} answerType={mockEcogestureAnswer} /> diff --git a/src/components/EcogestureForm/EcogestureFormSingleChoice.tsx b/src/components/EcogestureForm/EcogestureFormSingleChoice.tsx index 8fa20fd7c..dbf9b2fe1 100644 --- a/src/components/EcogestureForm/EcogestureFormSingleChoice.tsx +++ b/src/components/EcogestureForm/EcogestureFormSingleChoice.tsx @@ -18,7 +18,7 @@ interface EcogestureFormSingleChoiceProps { profileEcogesture: ProfileEcogesture answerType: ProfileEcogestureAnswer setNextStep: Function - setPrevioustStep: Function + setPreviousStep: Function } const EcogestureFormSingleChoice: React.FC<EcogestureFormSingleChoiceProps> = ({ @@ -27,7 +27,7 @@ const EcogestureFormSingleChoice: React.FC<EcogestureFormSingleChoiceProps> = ({ profileEcogesture, answerType, setNextStep, - setPrevioustStep, + setPreviousStep, }: EcogestureFormSingleChoiceProps) => { const { t } = useI18n() const { isProfileEcogestureCompleted } = useSelector( @@ -38,8 +38,8 @@ const EcogestureFormSingleChoice: React.FC<EcogestureFormSingleChoiceProps> = ({ ) const handlePrevious = useCallback(() => { - setPrevioustStep(profileEcogesture) - }, [profileEcogesture, setPrevioustStep]) + setPreviousStep(profileEcogesture) + }, [profileEcogesture, setPreviousStep]) const handleAnswer = useCallback((value: ProfileEcogestureAnswerChoices) => { setAnswer(value) diff --git a/src/components/EcogestureForm/EcogestureFormView.tsx b/src/components/EcogestureForm/EcogestureFormView.tsx index 22bfb91ab..b2fbe1779 100644 --- a/src/components/EcogestureForm/EcogestureFormView.tsx +++ b/src/components/EcogestureForm/EcogestureFormView.tsx @@ -117,7 +117,7 @@ const EcogestureFormView: React.FC = () => { profileEcogesture={profileEcogesture} answerType={answerType} setNextStep={setNextStep} - setPrevioustStep={setPreviousStep} + setPreviousStep={setPreviousStep} /> )} </> diff --git a/src/components/EcogestureForm/__snapshots__/EcogestureFormSingleChoice.spec.tsx.snap b/src/components/EcogestureForm/__snapshots__/EcogestureFormSingleChoice.spec.tsx.snap index 93eafddb3..78708be12 100644 --- a/src/components/EcogestureForm/__snapshots__/EcogestureFormSingleChoice.spec.tsx.snap +++ b/src/components/EcogestureForm/__snapshots__/EcogestureFormSingleChoice.spec.tsx.snap @@ -33,7 +33,7 @@ exports[`EcogestureFormSingleChoice component should be rendered correctly 1`] = } } setNextStep={[MockFunction]} - setPrevioustStep={[MockFunction]} + setPreviousStep={[MockFunction]} step={0} viewedStep={-1} > diff --git a/src/components/EcogestureForm/__snapshots__/EcogestureFormView.spec.tsx.snap b/src/components/EcogestureForm/__snapshots__/EcogestureFormView.spec.tsx.snap index 70dd31dc9..05718102d 100644 --- a/src/components/EcogestureForm/__snapshots__/EcogestureFormView.spec.tsx.snap +++ b/src/components/EcogestureForm/__snapshots__/EcogestureFormView.spec.tsx.snap @@ -44,7 +44,7 @@ exports[`EcogestureFormView component should be rendered correctly 1`] = ` } } setNextStep={[Function]} - setPrevioustStep={[Function]} + setPreviousStep={[Function]} step={0} viewedStep={-1} > -- GitLab