Skip to content

Commit

Permalink
ref: refactor some classes
Browse files Browse the repository at this point in the history
  • Loading branch information
ddecrulle committed Jul 9, 2024
1 parent 34c60fe commit 039478d
Showing 1 changed file with 6 additions and 7 deletions.
13 changes: 6 additions & 7 deletions src/shared/components/Orchestrator/SurveyContainer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ import Button from '@codegouvfr/react-dsfr/Button'
import { declareComponentKeys, useTranslation } from 'i18n'
import type { InternalPageType } from 'model/Page'
import { useState, type PropsWithChildren, type ReactNode } from 'react'
import { useStyles } from 'tss-react'
import type { OrchestratorProps } from './Orchestrator'
import { SequenceHeader } from './SequenceHeader'
import type { LunaticOverview } from './utils/lunaticType'
Expand Down Expand Up @@ -36,8 +35,6 @@ export function SurveyContainer(
bottomContent,
} = props

const { cx } = useStyles()

const { t } = useTranslation({ SurveyContainer })

const isPreviousButtonDisplayed = ['welcomePage', 'endPage'].includes(
Expand Down Expand Up @@ -73,10 +70,12 @@ export function SurveyContainer(
<div className={fr.cx('fr-container')}>
<div className={fr.cx('fr-grid-row', 'fr-grid-row--center')}>
<div
className={cx(
fr.cx('fr-col-12', 'fr-mb-10v'),
!(isLayoutExpanded && currentPage === 'lunaticPage') &&
fr.cx('fr-col-md-9', 'fr-col-lg-8')
className={fr.cx(
'fr-col-12',
'fr-mb-10v',
...(!(isLayoutExpanded && currentPage === 'lunaticPage')
? (['fr-col-md-9', 'fr-col-lg-8'] as const)
: [])
)}
>
{pagination === 'sequence' && currentPage === 'lunaticPage' && (
Expand Down

0 comments on commit 039478d

Please sign in to comment.