diff --git a/server/controllers/student.ts b/server/controllers/student.ts index 364aa3e09..f5579dcef 100644 --- a/server/controllers/student.ts +++ b/server/controllers/student.ts @@ -1,7 +1,6 @@ import type { JSONSchemaType } from 'ajv'; import type { NextFunction, Request, Response } from 'express'; -import { Classroom } from '../entities/classroom'; import { Student } from '../entities/student'; import { User, UserType } from '../entities/user'; import { UserToStudent } from '../entities/userToStudent'; diff --git a/src/components/Avatar.tsx b/src/components/Avatar.tsx index d7ba42c74..487f2449e 100644 --- a/src/components/Avatar.tsx +++ b/src/components/Avatar.tsx @@ -1,8 +1,9 @@ -import PersonIcon from '@mui/icons-material/Person'; -import { Avatar, Tooltip } from '@mui/material'; import Link from 'next/link'; import React from 'react'; +import PersonIcon from '@mui/icons-material/Person'; +import { Avatar, Tooltip } from '@mui/material'; + import { bgPage } from 'src/styles/variables.const'; import PelicoSouriant from 'src/svg/pelico/pelico-souriant.svg'; import { getGravatarUrl } from 'src/utils'; diff --git a/src/components/FinalStep/ImageStepContainer.tsx b/src/components/FinalStep/ImageStepContainer.tsx index bbcf54270..3c081ec95 100644 --- a/src/components/FinalStep/ImageStepContainer.tsx +++ b/src/components/FinalStep/ImageStepContainer.tsx @@ -1,9 +1,10 @@ -import { Grid, ButtonBase } from '@mui/material'; import classNames from 'classnames'; import Image from 'next/image'; import router from 'next/router'; import React from 'react'; +import { Grid, ButtonBase } from '@mui/material'; + import { KeepRatio } from '../KeepRatio'; import { EditButton } from '../buttons/EditButton'; import { bgPage, primaryColor, warningColor } from 'src/styles/variables.const'; diff --git a/src/components/H5p.tsx b/src/components/H5p.tsx index e6535dec2..9df527d6b 100644 --- a/src/components/H5p.tsx +++ b/src/components/H5p.tsx @@ -1,6 +1,7 @@ -import CircularProgress from '@mui/material/CircularProgress'; import React from 'react'; +import CircularProgress from '@mui/material/CircularProgress'; + import { bgPage } from 'src/styles/variables.const'; interface H5pProps { diff --git a/src/components/Header.tsx b/src/components/Header.tsx index b2646c5f8..06ac0b8f2 100644 --- a/src/components/Header.tsx +++ b/src/components/Header.tsx @@ -1,14 +1,15 @@ // import SearchIcon from '@mui/icons-material/Search'; +import Link from 'next/link'; +import { useRouter } from 'next/router'; +import React from 'react'; + import SettingsIcon from '@mui/icons-material/Settings'; import { Button } from '@mui/material'; import IconButton from '@mui/material/IconButton'; // import InputBase from '@mui/material/InputBase'; import Menu from '@mui/material/Menu'; import MenuItem from '@mui/material/MenuItem'; -import Link from 'next/link'; -import { useRouter } from 'next/router'; -import React from 'react'; import AccessControl from './AccessControl'; //import { getClassroomOfStudent } from 'src/api/student/student.get'; diff --git a/src/components/LanguageFilter.tsx b/src/components/LanguageFilter.tsx index a0095edc2..726e4f912 100644 --- a/src/components/LanguageFilter.tsx +++ b/src/components/LanguageFilter.tsx @@ -1,6 +1,7 @@ +import React from 'react'; + import type { SxProps, Theme } from '@mui/material'; import { Autocomplete, TextField } from '@mui/material'; -import React from 'react'; import type { Language } from 'types/language.type'; diff --git a/src/components/Map/Map.tsx b/src/components/Map/Map.tsx index 5dd977f17..b99e5aead 100644 --- a/src/components/Map/Map.tsx +++ b/src/components/Map/Map.tsx @@ -5,6 +5,7 @@ import {} from 'leaflet.fullscreen'; import maplibregl from 'maplibre-gl'; import { useRouter } from 'next/router'; import React from 'react'; + // eslint-disable-next-line import/order import { Tooltip } from '@mui/material'; diff --git a/src/components/Navigation.tsx b/src/components/Navigation.tsx index 41e2ae7ca..984d654e9 100644 --- a/src/components/Navigation.tsx +++ b/src/components/Navigation.tsx @@ -1,9 +1,10 @@ -import { Button } from '@mui/material'; -import Switch from '@mui/material/Switch'; import Link from 'next/link'; import { useRouter } from 'next/router'; import * as React from 'react'; +import { Button } from '@mui/material'; +import Switch from '@mui/material/Switch'; + import { AvatarImg } from './Avatar'; import { Flag } from 'src/components/Flag'; import { Modal } from 'src/components/Modal'; diff --git a/src/components/Steps.tsx b/src/components/Steps.tsx index 87281a207..f5748364b 100644 --- a/src/components/Steps.tsx +++ b/src/components/Steps.tsx @@ -1,11 +1,12 @@ +import { useRouter } from 'next/router'; +import React from 'react'; + import CheckIcon from '@mui/icons-material/Check'; import Step from '@mui/material/Step'; import StepConnector from '@mui/material/StepConnector'; import type { StepIconProps } from '@mui/material/StepIcon'; import StepLabel from '@mui/material/StepLabel'; import Stepper from '@mui/material/Stepper'; -import { useRouter } from 'next/router'; -import React from 'react'; import { ActivityContext } from 'src/contexts/activityContext'; import { primaryColor, primaryColorLight2, successColor, warningColor } from 'src/styles/variables.const'; diff --git a/src/components/StepsButtons.tsx b/src/components/StepsButtons.tsx index af3708696..3f88dd730 100644 --- a/src/components/StepsButtons.tsx +++ b/src/components/StepsButtons.tsx @@ -1,8 +1,9 @@ +import Link from 'next/link'; +import React from 'react'; + import ChevronLeftIcon from '@mui/icons-material/ChevronLeft'; import ChevronRightIcon from '@mui/icons-material/ChevronRight'; import { Button } from '@mui/material'; -import Link from 'next/link'; -import React from 'react'; export interface StepsButtonProps { prev?: string | (() => void); diff --git a/src/components/SuggestionCarousel/SuggestionCarousel.tsx b/src/components/SuggestionCarousel/SuggestionCarousel.tsx index 519ea0542..1c3fe00e1 100644 --- a/src/components/SuggestionCarousel/SuggestionCarousel.tsx +++ b/src/components/SuggestionCarousel/SuggestionCarousel.tsx @@ -1,10 +1,11 @@ +import Image from 'next/image'; +import Link from 'next/link'; +import React from 'react'; + import { Button } from '@mui/material'; import Card from '@mui/material/Card'; import Tab from '@mui/material/Tab'; import Tabs from '@mui/material/Tabs'; -import Image from 'next/image'; -import Link from 'next/link'; -import React from 'react'; import { KeepRatio } from 'src/components/KeepRatio'; import { useResizeObserver } from 'src/hooks/useResizeObserver'; diff --git a/src/components/WelcomeModal/FirstPhase.tsx b/src/components/WelcomeModal/FirstPhase.tsx index 2682e9e48..cb520e86e 100644 --- a/src/components/WelcomeModal/FirstPhase.tsx +++ b/src/components/WelcomeModal/FirstPhase.tsx @@ -1,10 +1,11 @@ +import { useSnackbar } from 'notistack'; +import React from 'react'; + import KeyboardArrowLeft from '@mui/icons-material/KeyboardArrowLeft'; import KeyboardArrowRight from '@mui/icons-material/KeyboardArrowRight'; import { Checkbox } from '@mui/material'; import Button from '@mui/material/Button'; import MobileStepper from '@mui/material/MobileStepper'; -import { useSnackbar } from 'notistack'; -import React from 'react'; import { CGU } from 'src/components/CGU'; import { Flag } from 'src/components/Flag'; diff --git a/src/components/WelcomeModal/SecondPhase.tsx b/src/components/WelcomeModal/SecondPhase.tsx index 7314a7299..03ba31fcc 100644 --- a/src/components/WelcomeModal/SecondPhase.tsx +++ b/src/components/WelcomeModal/SecondPhase.tsx @@ -1,7 +1,8 @@ -import Button from '@mui/material/Button'; import { useSnackbar } from 'notistack'; import React from 'react'; +import Button from '@mui/material/Button'; + import { Modal } from 'src/components/Modal'; import { UserContext } from 'src/contexts/userContext'; import { VillageContext } from 'src/contexts/villageContext'; diff --git a/src/components/WelcomeModal/ThirdPhase.tsx b/src/components/WelcomeModal/ThirdPhase.tsx index 62b3fead9..23eb4fc8a 100644 --- a/src/components/WelcomeModal/ThirdPhase.tsx +++ b/src/components/WelcomeModal/ThirdPhase.tsx @@ -1,7 +1,8 @@ -import Button from '@mui/material/Button'; import { useSnackbar } from 'notistack'; import React from 'react'; +import Button from '@mui/material/Button'; + import { Modal } from 'src/components/Modal'; import { UserContext } from 'src/contexts/userContext'; import { VillageContext } from 'src/contexts/villageContext'; diff --git a/src/components/WorldMap/Popover.tsx b/src/components/WorldMap/Popover.tsx index ad063987f..74cdfe97d 100644 --- a/src/components/WorldMap/Popover.tsx +++ b/src/components/WorldMap/Popover.tsx @@ -1,6 +1,7 @@ -import Card from '@mui/material/Card'; import * as React from 'react'; +import Card from '@mui/material/Card'; + import { UserPopover } from './UserPopover'; import type { User } from 'types/user.type'; diff --git a/src/components/WorldMap/use-full-screen.tsx b/src/components/WorldMap/use-full-screen.tsx index fd7be966b..c2ba4bd93 100644 --- a/src/components/WorldMap/use-full-screen.tsx +++ b/src/components/WorldMap/use-full-screen.tsx @@ -1,8 +1,9 @@ +import * as React from 'react'; + import FullscreenIcon from '@mui/icons-material/Fullscreen'; import FullscreenExitIcon from '@mui/icons-material/FullscreenExit'; import Button from '@mui/material/Button'; import Tooltip from '@mui/material/Tooltip'; -import * as React from 'react'; export const useFullScreen = () => { const containerRef = React.useRef(null); diff --git a/src/components/accueil/Accueil.tsx b/src/components/accueil/Accueil.tsx index 04d60bf7e..6bb3c5a54 100644 --- a/src/components/accueil/Accueil.tsx +++ b/src/components/accueil/Accueil.tsx @@ -1,6 +1,7 @@ -import { Button } from '@mui/material'; import React from 'react'; +import { Button } from '@mui/material'; + import { filterActivitiesByTerm, filterActivitiesWithLastMimicGame } from './Filters/FilterActivities'; import { LinkChild } from './LinkChild'; import { getUserVisibilityFamilyParams } from 'src/api/user/user.get'; diff --git a/src/components/accueil/Filters/FilterSelect.tsx b/src/components/accueil/Filters/FilterSelect.tsx index c8e93c294..34657c174 100644 --- a/src/components/accueil/Filters/FilterSelect.tsx +++ b/src/components/accueil/Filters/FilterSelect.tsx @@ -1,10 +1,11 @@ +import React from 'react'; + import ExpandLessIcon from '@mui/icons-material/ExpandLess'; import ExpandMoreIcon from '@mui/icons-material/ExpandMore'; import Checkbox from '@mui/material/Checkbox'; import ClickAwayListener from '@mui/material/ClickAwayListener'; import FormControlLabel from '@mui/material/FormControlLabel'; import FormGroup from '@mui/material/FormGroup'; -import React from 'react'; import { primaryColor } from 'src/styles/variables.const'; diff --git a/src/components/accueil/Filters/Filters.tsx b/src/components/accueil/Filters/Filters.tsx index f3fab061d..5856da636 100644 --- a/src/components/accueil/Filters/Filters.tsx +++ b/src/components/accueil/Filters/Filters.tsx @@ -1,6 +1,7 @@ -import Checkbox from '@mui/material/Checkbox'; import React from 'react'; +import Checkbox from '@mui/material/Checkbox'; + import { FilterSelect } from './FilterSelect'; import { Flag } from 'src/components/Flag'; import { primaryColor } from 'src/styles/variables.const'; diff --git a/src/components/accueil/LinkChild.tsx b/src/components/accueil/LinkChild.tsx index 76f92c3d3..58a8fab51 100644 --- a/src/components/accueil/LinkChild.tsx +++ b/src/components/accueil/LinkChild.tsx @@ -1,8 +1,9 @@ -import { Button, TextField } from '@mui/material'; import { useRouter } from 'next/router'; import { useSnackbar } from 'notistack'; import React from 'react'; +import { Button, TextField } from '@mui/material'; + import { DeleteButton } from '../buttons/DeleteButton'; // import { ClassroomContext } from 'src/contexts/classroomContext'; import { UserContext } from 'src/contexts/userContext'; diff --git a/src/components/accueil/NewHome.tsx b/src/components/accueil/NewHome.tsx index 137b7548a..a68f3fd46 100644 --- a/src/components/accueil/NewHome.tsx +++ b/src/components/accueil/NewHome.tsx @@ -1,7 +1,8 @@ -import { Button } from '@mui/material'; import { useRouter } from 'next/router'; import React from 'react'; +import { Button } from '@mui/material'; + import { KeepRatio } from '../KeepRatio'; import Home from 'src/svg/home.svg'; import Logo from 'src/svg/logo_1village.svg'; diff --git a/src/components/accueil/PelicoProfilNavigation.tsx b/src/components/accueil/PelicoProfilNavigation.tsx index 6a96035f7..20f35f2a3 100644 --- a/src/components/accueil/PelicoProfilNavigation.tsx +++ b/src/components/accueil/PelicoProfilNavigation.tsx @@ -1,6 +1,7 @@ -import { Avatar, Button } from '@mui/material'; import React from 'react'; +import { Avatar, Button } from '@mui/material'; + import { CommentIcon } from '../activities/ActivityCard/CommentIcon'; import { icons, DESC } from 'src/components/activities/utils'; import { useActivities } from 'src/services/useActivities'; diff --git a/src/components/accueil/RightNavigation.tsx b/src/components/accueil/RightNavigation.tsx index 9ffa2aba1..bebecb813 100644 --- a/src/components/accueil/RightNavigation.tsx +++ b/src/components/accueil/RightNavigation.tsx @@ -1,8 +1,9 @@ -import { Button, Link, Tooltip } from '@mui/material'; import Image from 'next/image'; import { useRouter } from 'next/router'; import React from 'react'; +import { Button, Link, Tooltip } from '@mui/material'; + import { AvatarImg } from '../Avatar'; import { Flag } from '../Flag'; import { CommentIcon } from '../activities/ActivityCard/CommentIcon'; diff --git a/src/components/accueil/VideoPresentation.tsx b/src/components/accueil/VideoPresentation.tsx index 3012122c4..d9ff2f953 100644 --- a/src/components/accueil/VideoPresentation.tsx +++ b/src/components/accueil/VideoPresentation.tsx @@ -1,8 +1,9 @@ // import { Button, Link as RegisterLink, NoSsr, Box, TextField, Grid } from '@mui/material'; -import { Button, Link as RegisterLink, NoSsr } from '@mui/material'; import Link from 'next/link'; import React from 'react'; +import { Button, Link as RegisterLink, NoSsr } from '@mui/material'; + import { KeepRatio } from 'src/components/KeepRatio'; import Logo from 'src/svg/logo.svg'; // import PelicoReflechit from 'src/svg/pelico/pelico_reflechit.svg'; diff --git a/src/components/accueil/VillageComponent.tsx b/src/components/accueil/VillageComponent.tsx index 08e3bd5c6..edbca546e 100644 --- a/src/components/accueil/VillageComponent.tsx +++ b/src/components/accueil/VillageComponent.tsx @@ -1,6 +1,7 @@ +import React from 'react'; + import Card from '@mui/material/Card'; import CardActionArea from '@mui/material/CardActionArea'; -import React from 'react'; import { KeepRatio } from 'src/components/KeepRatio'; import Acti1 from 'src/svg/activities/acti1.svg'; diff --git a/src/components/activities/ActivityCard/AnthemCard.tsx b/src/components/activities/ActivityCard/AnthemCard.tsx index dec8586df..ea94c2358 100644 --- a/src/components/activities/ActivityCard/AnthemCard.tsx +++ b/src/components/activities/ActivityCard/AnthemCard.tsx @@ -1,7 +1,8 @@ -import { Button } from '@mui/material'; import Link from 'next/link'; import React from 'react'; +import { Button } from '@mui/material'; + import { CommentIcon } from './CommentIcon'; import type { ActivityCardProps } from './activity-card.types'; import type { AnthemActivity } from 'src/activity-types/anthem.types'; diff --git a/src/components/activities/ActivityCard/DefiCard.tsx b/src/components/activities/ActivityCard/DefiCard.tsx index 2d76c8e66..3f5a8c416 100644 --- a/src/components/activities/ActivityCard/DefiCard.tsx +++ b/src/components/activities/ActivityCard/DefiCard.tsx @@ -1,9 +1,10 @@ -import { Button } from '@mui/material'; import Image from 'next/image'; import Link from 'next/link'; import { useRouter } from 'next/router'; import React from 'react'; +import { Button } from '@mui/material'; + import { CommentIcon } from './CommentIcon'; import type { ActivityCardProps } from './activity-card.types'; import { ECO_ACTIONS, getDefi, getLanguageTheme, isCooking, isEco, isLanguage } from 'src/activity-types/defi.constants'; diff --git a/src/components/activities/ActivityCard/EnigmeCard.tsx b/src/components/activities/ActivityCard/EnigmeCard.tsx index 60a9cf945..2741cc246 100644 --- a/src/components/activities/ActivityCard/EnigmeCard.tsx +++ b/src/components/activities/ActivityCard/EnigmeCard.tsx @@ -1,9 +1,10 @@ -import { Button } from '@mui/material'; import Image from 'next/image'; import Link from 'next/link'; import router from 'next/router'; import React from 'react'; +import { Button } from '@mui/material'; + import { CommentIcon } from './CommentIcon'; import type { ActivityCardProps } from './activity-card.types'; import { ENIGME_TYPES } from 'src/activity-types/enigme.constants'; diff --git a/src/components/activities/ActivityCard/FreeContentCard.tsx b/src/components/activities/ActivityCard/FreeContentCard.tsx index 31420ad80..9a08dd2f5 100644 --- a/src/components/activities/ActivityCard/FreeContentCard.tsx +++ b/src/components/activities/ActivityCard/FreeContentCard.tsx @@ -1,9 +1,10 @@ -import { Button } from '@mui/material'; import Image from 'next/image'; import Link from 'next/link'; import router from 'next/router'; import React from 'react'; +import { Button } from '@mui/material'; + import { CommentIcon } from './CommentIcon'; import type { ActivityCardProps } from './activity-card.types'; import { getImage } from 'src/activity-types/freeContent.constants'; diff --git a/src/components/activities/ActivityCard/IndiceCard.tsx b/src/components/activities/ActivityCard/IndiceCard.tsx index 12c49200d..590d6819e 100644 --- a/src/components/activities/ActivityCard/IndiceCard.tsx +++ b/src/components/activities/ActivityCard/IndiceCard.tsx @@ -1,9 +1,10 @@ -import { Button } from '@mui/material'; import Image from 'next/image'; import Link from 'next/link'; import router from 'next/router'; import React from 'react'; +import { Button } from '@mui/material'; + import { CommentIcon } from './CommentIcon'; import type { ActivityCardProps } from './activity-card.types'; import { getIndice } from 'src/activity-types/indice.constants'; diff --git a/src/components/activities/ActivityCard/MascotteCard.tsx b/src/components/activities/ActivityCard/MascotteCard.tsx index 10d8b3247..89e64cd77 100644 --- a/src/components/activities/ActivityCard/MascotteCard.tsx +++ b/src/components/activities/ActivityCard/MascotteCard.tsx @@ -1,7 +1,8 @@ -import { Button } from '@mui/material'; import Link from 'next/link'; import React from 'react'; +import { Button } from '@mui/material'; + import { CommentIcon } from './CommentIcon'; import type { ActivityCardProps } from './activity-card.types'; import type { MascotteActivity } from 'src/activity-types/mascotte.types'; diff --git a/src/components/activities/ActivityCard/MimicCard.tsx b/src/components/activities/ActivityCard/MimicCard.tsx index 2e9b21b84..f739d6bff 100644 --- a/src/components/activities/ActivityCard/MimicCard.tsx +++ b/src/components/activities/ActivityCard/MimicCard.tsx @@ -1,9 +1,10 @@ -import { Button } from '@mui/material'; import Link from 'next/link'; import router from 'next/router'; import React from 'react'; import ReactPlayer from 'react-player'; +import { Button } from '@mui/material'; + import { CommentIcon } from './CommentIcon'; import type { ActivityCardProps } from './activity-card.types'; import { RedButton } from 'src/components/buttons/RedButton'; diff --git a/src/components/activities/ActivityCard/PresentationCard.tsx b/src/components/activities/ActivityCard/PresentationCard.tsx index 753dc8119..8bfda0c43 100644 --- a/src/components/activities/ActivityCard/PresentationCard.tsx +++ b/src/components/activities/ActivityCard/PresentationCard.tsx @@ -1,9 +1,10 @@ -import { Button } from '@mui/material'; import Image from 'next/image'; import Link from 'next/link'; import router from 'next/router'; import React from 'react'; +import { Button } from '@mui/material'; + import { CommentIcon } from './CommentIcon'; import type { ActivityCardProps } from './activity-card.types'; import { PRESENTATION_THEMATIQUE } from 'src/activity-types/presentation.constants'; diff --git a/src/components/activities/ActivityCard/QuestionCard.tsx b/src/components/activities/ActivityCard/QuestionCard.tsx index 9e1540945..2e8141a19 100644 --- a/src/components/activities/ActivityCard/QuestionCard.tsx +++ b/src/components/activities/ActivityCard/QuestionCard.tsx @@ -1,7 +1,8 @@ -import { Button } from '@mui/material'; import Link from 'next/link'; import React from 'react'; +import { Button } from '@mui/material'; + import { CommentIcon } from './CommentIcon'; import type { ActivityCardProps } from './activity-card.types'; import type { QuestionActivity } from 'src/activity-types/question.types'; diff --git a/src/components/activities/ActivityCard/ReactionCard.tsx b/src/components/activities/ActivityCard/ReactionCard.tsx index 43c39b1cb..e677c5a97 100644 --- a/src/components/activities/ActivityCard/ReactionCard.tsx +++ b/src/components/activities/ActivityCard/ReactionCard.tsx @@ -1,8 +1,9 @@ -import { Button } from '@mui/material'; import Image from 'next/image'; import Link from 'next/link'; import React from 'react'; +import { Button } from '@mui/material'; + import { CommentIcon } from './CommentIcon'; import type { ActivityCardProps } from './activity-card.types'; import type { ReactionActivity } from 'src/activity-types/reaction.types'; diff --git a/src/components/activities/ActivityCard/ReportageCard.tsx b/src/components/activities/ActivityCard/ReportageCard.tsx index b4e9d6376..0c828022a 100644 --- a/src/components/activities/ActivityCard/ReportageCard.tsx +++ b/src/components/activities/ActivityCard/ReportageCard.tsx @@ -1,10 +1,11 @@ -import { Button } from '@mui/material'; import Image from 'next/image'; import Link from 'next/link'; import router from 'next/router'; import React from 'react'; import ReactPlayer from 'react-player'; +import { Button } from '@mui/material'; + import { CommentIcon } from './CommentIcon'; import type { ActivityCardProps } from './activity-card.types'; import { getReportage } from 'src/activity-types/reportage.constants'; diff --git a/src/components/activities/ActivityCard/StoryCard.tsx b/src/components/activities/ActivityCard/StoryCard.tsx index d1270a0c7..f9a1bd2c2 100644 --- a/src/components/activities/ActivityCard/StoryCard.tsx +++ b/src/components/activities/ActivityCard/StoryCard.tsx @@ -1,9 +1,10 @@ -import { Button } from '@mui/material'; import Image from 'next/image'; import Link from 'next/link'; import router from 'next/router'; import React from 'react'; +import { Button } from '@mui/material'; + import { CommentIcon } from './CommentIcon'; import type { ActivityCardProps } from './activity-card.types'; import { RedButton } from 'src/components/buttons/RedButton'; diff --git a/src/components/activities/ActivityCard/SymbolCard.tsx b/src/components/activities/ActivityCard/SymbolCard.tsx index 75339cf36..28f9af326 100644 --- a/src/components/activities/ActivityCard/SymbolCard.tsx +++ b/src/components/activities/ActivityCard/SymbolCard.tsx @@ -1,9 +1,10 @@ -import { Button } from '@mui/material'; import Image from 'next/image'; import Link from 'next/link'; import router from 'next/router'; import React from 'react'; +import { Button } from '@mui/material'; + import { CommentIcon } from './CommentIcon'; import type { ActivityCardProps } from './activity-card.types'; import { getSymbol } from 'src/activity-types/symbol.constants'; diff --git a/src/components/activities/ActivityCard/VerseRecordCard.tsx b/src/components/activities/ActivityCard/VerseRecordCard.tsx index ff7325a3e..919d36766 100644 --- a/src/components/activities/ActivityCard/VerseRecordCard.tsx +++ b/src/components/activities/ActivityCard/VerseRecordCard.tsx @@ -1,7 +1,8 @@ -import { Button } from '@mui/material'; import Link from 'next/link'; import React from 'react'; +import { Button } from '@mui/material'; + import { CommentIcon } from './CommentIcon'; import type { ActivityCardProps } from './activity-card.types'; import type { VerseRecordActivity } from 'src/activity-types/verseRecord.types'; diff --git a/src/components/activities/ActivityChoice/ActivityChoiceButton.tsx b/src/components/activities/ActivityChoice/ActivityChoiceButton.tsx index b19cee055..3f0756e94 100644 --- a/src/components/activities/ActivityChoice/ActivityChoiceButton.tsx +++ b/src/components/activities/ActivityChoice/ActivityChoiceButton.tsx @@ -1,7 +1,8 @@ -import ButtonBase from '@mui/material/ButtonBase'; import Link from 'next/link'; import React from 'react'; +import ButtonBase from '@mui/material/ButtonBase'; + import { KeepRatio } from 'src/components/KeepRatio'; interface ActivityChoiceButtonProps { diff --git a/src/components/activities/ActivityChoice/index.tsx b/src/components/activities/ActivityChoice/index.tsx index 23a7d4b76..0d809d542 100644 --- a/src/components/activities/ActivityChoice/index.tsx +++ b/src/components/activities/ActivityChoice/index.tsx @@ -1,6 +1,7 @@ -import { Tooltip } from '@mui/material'; import React from 'react'; +import { Tooltip } from '@mui/material'; + import { ActivityChoiceButton } from './ActivityChoiceButton'; interface ActivityChoiceProps { diff --git a/src/components/activities/ActivityComments/AddComment.tsx b/src/components/activities/ActivityComments/AddComment.tsx index fbe91e031..7c4d4975d 100644 --- a/src/components/activities/ActivityComments/AddComment.tsx +++ b/src/components/activities/ActivityComments/AddComment.tsx @@ -1,8 +1,9 @@ -import { Button, CircularProgress, Tooltip } from '@mui/material'; import dynamic from 'next/dynamic'; import Link from 'next/link'; import React from 'react'; +import { Button, CircularProgress, Tooltip } from '@mui/material'; + import { AvatarImg } from 'src/components/Avatar'; import { UserContext } from 'src/contexts/userContext'; import { useCommentRequests } from 'src/services/useComments'; diff --git a/src/components/activities/ActivityComments/CommentCard.tsx b/src/components/activities/ActivityComments/CommentCard.tsx index ba082bd1b..b029b7360 100644 --- a/src/components/activities/ActivityComments/CommentCard.tsx +++ b/src/components/activities/ActivityComments/CommentCard.tsx @@ -1,7 +1,8 @@ -import { Button, CircularProgress, Paper } from '@mui/material'; import dynamic from 'next/dynamic'; import React from 'react'; +import { Button, CircularProgress, Paper } from '@mui/material'; + import { AvatarImg } from 'src/components/Avatar'; import { Flag } from 'src/components/Flag'; import { UserDisplayName } from 'src/components/UserDisplayName'; diff --git a/src/components/activities/ActivitySelect.tsx b/src/components/activities/ActivitySelect.tsx index fe79fc494..20dfb7efc 100644 --- a/src/components/activities/ActivitySelect.tsx +++ b/src/components/activities/ActivitySelect.tsx @@ -1,6 +1,7 @@ +import React from 'react'; + import ChevronRightIcon from '@mui/icons-material/ChevronRight'; import { Button, CircularProgress } from '@mui/material'; -import React from 'react'; import { Activities } from './List'; import { ThemeChoiceButton } from 'src/components/buttons/ThemeChoiceButton'; diff --git a/src/components/activities/ActivityView/DefiActivityView.tsx b/src/components/activities/ActivityView/DefiActivityView.tsx index f9bf77b02..971207e61 100644 --- a/src/components/activities/ActivityView/DefiActivityView.tsx +++ b/src/components/activities/ActivityView/DefiActivityView.tsx @@ -1,7 +1,8 @@ -import { Grid } from '@mui/material'; import Image from 'next/image'; import React from 'react'; +import { Grid } from '@mui/material'; + import type { ActivityViewProps } from './activity-view.types'; import { ECO_ACTIONS, getDefi, isCooking, isEco, isLanguage, getLanguageTheme } from 'src/activity-types/defi.constants'; import type { DefiActivity } from 'src/activity-types/defi.types'; diff --git a/src/components/activities/ActivityView/EnigmeActivityView.tsx b/src/components/activities/ActivityView/EnigmeActivityView.tsx index 98a08b1fa..acbaab900 100644 --- a/src/components/activities/ActivityView/EnigmeActivityView.tsx +++ b/src/components/activities/ActivityView/EnigmeActivityView.tsx @@ -1,7 +1,8 @@ -import { Button, Card } from '@mui/material'; import Link from 'next/link'; import React from 'react'; +import { Button, Card } from '@mui/material'; + import type { ActivityViewProps } from './activity-view.types'; import { ENIGME_TYPES, getEnigmeTimeLeft } from 'src/activity-types/enigme.constants'; import type { EnigmeActivity, EnigmeData } from 'src/activity-types/enigme.types'; diff --git a/src/components/activities/ActivityView/MascotteActivityView.tsx b/src/components/activities/ActivityView/MascotteActivityView.tsx index 35f7cb1c3..2bc0d8253 100644 --- a/src/components/activities/ActivityView/MascotteActivityView.tsx +++ b/src/components/activities/ActivityView/MascotteActivityView.tsx @@ -1,6 +1,7 @@ -import { Grid, Box } from '@mui/material'; import React from 'react'; +import { Grid, Box } from '@mui/material'; + import { ImageView } from '../content/views/ImageView'; import type { ActivityViewProps } from './activity-view.types'; import type { MascotteActivity } from 'src/activity-types/mascotte.types'; diff --git a/src/components/activities/ActivityView/StoriesDataCardView.tsx b/src/components/activities/ActivityView/StoriesDataCardView.tsx index 611f5a56d..219e4d2ad 100644 --- a/src/components/activities/ActivityView/StoriesDataCardView.tsx +++ b/src/components/activities/ActivityView/StoriesDataCardView.tsx @@ -1,6 +1,7 @@ -import { Grid } from '@mui/material'; import React from 'react'; +import { Grid } from '@mui/material'; + import { ActivityCard } from '../ActivityCard'; import { useImageStories } from 'src/services/useImagesStory'; import { useVillageUsers } from 'src/services/useVillageUsers'; diff --git a/src/components/activities/ActivityView/StoryActivityView.tsx b/src/components/activities/ActivityView/StoryActivityView.tsx index 44c370a48..5abbe058d 100644 --- a/src/components/activities/ActivityView/StoryActivityView.tsx +++ b/src/components/activities/ActivityView/StoryActivityView.tsx @@ -1,11 +1,12 @@ +import Image from 'next/image'; +import React from 'react'; + import { Container } from '@mui/material'; import Card from '@mui/material/Card'; import CardMedia from '@mui/material/CardMedia'; import Grid from '@mui/material/Grid'; import Typography from '@mui/material/Typography'; import { Box } from '@mui/system'; -import Image from 'next/image'; -import React from 'react'; import StoriesDataCardView from './StoriesDataCardView'; import type { ActivityViewProps } from './activity-view.types'; diff --git a/src/components/activities/List.tsx b/src/components/activities/List.tsx index 94ae49c93..9c2d0a224 100644 --- a/src/components/activities/List.tsx +++ b/src/components/activities/List.tsx @@ -1,6 +1,7 @@ -import { Button } from '@mui/material'; import React from 'react'; +import { Button } from '@mui/material'; + import { ActivityCard } from './ActivityCard'; import { isAnthem } from 'src/activity-types/anyActivity'; import { UserContext } from 'src/contexts/userContext'; diff --git a/src/components/activities/MimicStats.tsx b/src/components/activities/MimicStats.tsx index 9a91a1f69..4340484bc 100644 --- a/src/components/activities/MimicStats.tsx +++ b/src/components/activities/MimicStats.tsx @@ -1,7 +1,8 @@ +import React from 'react'; + import type { LinearProgressProps } from '@mui/material'; import { LinearProgress, Typography, Grid } from '@mui/material'; import { Box } from '@mui/system'; -import React from 'react'; import { Flag } from '../Flag'; import type { GameResponse } from 'types/gameResponse.type'; diff --git a/src/components/activities/content/AddContentCard.tsx b/src/components/activities/content/AddContentCard.tsx index 68936f5a1..1b5edec1c 100644 --- a/src/components/activities/content/AddContentCard.tsx +++ b/src/components/activities/content/AddContentCard.tsx @@ -1,6 +1,7 @@ +import React from 'react'; + import AppsIcon from '@mui/icons-material/Apps'; import { ButtonBase, Card } from '@mui/material'; -import React from 'react'; import { UserContext } from 'src/contexts/userContext'; import ImageIcon from 'src/svg/editor/image_icon.svg'; diff --git a/src/components/activities/content/MascotteTemplate.tsx b/src/components/activities/content/MascotteTemplate.tsx index e452d0ad2..fd6259639 100644 --- a/src/components/activities/content/MascotteTemplate.tsx +++ b/src/components/activities/content/MascotteTemplate.tsx @@ -1,8 +1,9 @@ -import { Button } from '@mui/material'; -import Paper from '@mui/material/Paper'; import Link from 'next/link'; import React from 'react'; +import { Button } from '@mui/material'; +import Paper from '@mui/material/Paper'; + import { AvatarImg } from 'src/components/Avatar'; import { UserDisplayName } from 'src/components/UserDisplayName'; import { primaryColor } from 'src/styles/variables.const'; diff --git a/src/components/activities/content/editors/AnthemEditor.tsx b/src/components/activities/content/editors/AnthemEditor.tsx index eeb16d26b..a945a4054 100644 --- a/src/components/activities/content/editors/AnthemEditor.tsx +++ b/src/components/activities/content/editors/AnthemEditor.tsx @@ -1,8 +1,9 @@ +import { useSnackbar } from 'notistack'; +import React from 'react'; + import CloudUploadIcon from '@mui/icons-material/CloudUpload'; import { Button, Divider, TextField } from '@mui/material'; import Alert from '@mui/material/Alert'; -import { useSnackbar } from 'notistack'; -import React from 'react'; import { Modal } from 'src/components/Modal'; import { DeleteButton } from 'src/components/buttons/DeleteButton'; diff --git a/src/components/activities/content/editors/EditorContainer.tsx b/src/components/activities/content/editors/EditorContainer.tsx index d7ea91556..7cbfe99ac 100644 --- a/src/components/activities/content/editors/EditorContainer.tsx +++ b/src/components/activities/content/editors/EditorContainer.tsx @@ -1,7 +1,8 @@ -import DragIndicatorIcon from '@mui/icons-material/DragIndicator'; import classnames from 'classnames'; import React from 'react'; +import DragIndicatorIcon from '@mui/icons-material/DragIndicator'; + import { DeleteButton } from 'src/components/buttons/DeleteButton'; interface EditorContainerProps { diff --git a/src/components/activities/content/editors/H5pEditor.tsx b/src/components/activities/content/editors/H5pEditor.tsx index 5049d982d..69111aaf1 100644 --- a/src/components/activities/content/editors/H5pEditor.tsx +++ b/src/components/activities/content/editors/H5pEditor.tsx @@ -1,6 +1,7 @@ +import React from 'react'; + import { Button } from '@mui/material'; import TextField from '@mui/material/TextField'; -import React from 'react'; import type { EditorProps } from '../content.types'; import { EditorContainer } from './EditorContainer'; diff --git a/src/components/activities/content/editors/ImageEditor/AvatarEditor.tsx b/src/components/activities/content/editors/ImageEditor/AvatarEditor.tsx index 3ff3156f9..a76a50560 100644 --- a/src/components/activities/content/editors/ImageEditor/AvatarEditor.tsx +++ b/src/components/activities/content/editors/ImageEditor/AvatarEditor.tsx @@ -1,6 +1,7 @@ +import React from 'react'; + import AddIcon from '@mui/icons-material/Add'; import { ButtonBase } from '@mui/material'; -import React from 'react'; import type { EditorProps } from '../../content.types'; import { ImageModal } from './ImageModal'; diff --git a/src/components/activities/content/editors/ImageEditor/ImageEditor.tsx b/src/components/activities/content/editors/ImageEditor/ImageEditor.tsx index a31a2260c..19db2fdbc 100644 --- a/src/components/activities/content/editors/ImageEditor/ImageEditor.tsx +++ b/src/components/activities/content/editors/ImageEditor/ImageEditor.tsx @@ -1,7 +1,8 @@ -import { Button } from '@mui/material'; import Image from 'next/image'; import React from 'react'; +import { Button } from '@mui/material'; + import type { EditorProps } from '../../content.types'; import { EditorContainer } from '../EditorContainer'; import { ImageModal } from './ImageModal'; diff --git a/src/components/activities/content/editors/ImageEditor/ImageModal.tsx b/src/components/activities/content/editors/ImageEditor/ImageModal.tsx index 8308d3739..0d1b49c1e 100644 --- a/src/components/activities/content/editors/ImageEditor/ImageModal.tsx +++ b/src/components/activities/content/editors/ImageEditor/ImageModal.tsx @@ -1,10 +1,11 @@ -import CloudUploadIcon from '@mui/icons-material/CloudUpload'; -import { Button, Divider, TextField } from '@mui/material'; -import Alert from '@mui/material/Alert'; import Image from 'next/image'; import { useSnackbar } from 'notistack'; import React from 'react'; +import CloudUploadIcon from '@mui/icons-material/CloudUpload'; +import { Button, Divider, TextField } from '@mui/material'; +import Alert from '@mui/material/Alert'; + import type { ImgCroppieRef } from 'src/components/ImgCroppie'; import { ImgCroppie } from 'src/components/ImgCroppie'; import { KeepRatio } from 'src/components/KeepRatio'; diff --git a/src/components/activities/content/editors/SoundEditor.tsx b/src/components/activities/content/editors/SoundEditor.tsx index c49918953..ec8d3d064 100644 --- a/src/components/activities/content/editors/SoundEditor.tsx +++ b/src/components/activities/content/editors/SoundEditor.tsx @@ -1,8 +1,9 @@ +import { useSnackbar } from 'notistack'; +import React from 'react'; + import CloudUploadIcon from '@mui/icons-material/CloudUpload'; import { Button, Divider, TextField } from '@mui/material'; import Alert from '@mui/material/Alert'; -import { useSnackbar } from 'notistack'; -import React from 'react'; import type { EditorProps } from '../content.types'; import { EditorContainer } from './EditorContainer'; diff --git a/src/components/activities/content/editors/SyllableEditor.tsx b/src/components/activities/content/editors/SyllableEditor.tsx index 927060b88..0d4446ed0 100644 --- a/src/components/activities/content/editors/SyllableEditor.tsx +++ b/src/components/activities/content/editors/SyllableEditor.tsx @@ -1,6 +1,7 @@ -import { Box, InputBase } from '@mui/material'; import React from 'react'; +import { Box, InputBase } from '@mui/material'; + import type { Syllable } from 'src/activity-types/anthem.types'; import { primaryColor } from 'src/styles/variables.const'; import BacklineIcon from 'src/svg/anthem/backline.svg'; diff --git a/src/components/activities/content/editors/TextEditor/SimpleTextEditor.tsx b/src/components/activities/content/editors/TextEditor/SimpleTextEditor.tsx index 931354056..ff616945a 100644 --- a/src/components/activities/content/editors/TextEditor/SimpleTextEditor.tsx +++ b/src/components/activities/content/editors/TextEditor/SimpleTextEditor.tsx @@ -1,5 +1,3 @@ -import { Divider } from '@mui/material'; -import Paper from '@mui/material/Paper'; import classnames from 'classnames'; import type { DraftHandleValue, DraftEditorCommand, ContentBlock } from 'draft-js'; import { Editor, RichUtils, CompositeDecorator, ContentState, convertToRaw, EditorState, Modifier } from 'draft-js'; @@ -19,6 +17,9 @@ import { import htmlToDraft from 'html-to-draftjs'; import React from 'react'; +import { Divider } from '@mui/material'; +import Paper from '@mui/material/Paper'; + import { ColorPicker } from './toolbar/ColorPicker'; import { EmojiPicker } from './toolbar/EmojiPicker'; import { InlineButtons } from './toolbar/InlineButtons'; diff --git a/src/components/activities/content/editors/TextEditor/toolbar/ColorPicker.tsx b/src/components/activities/content/editors/TextEditor/toolbar/ColorPicker.tsx index 0bf7f817c..46f001d83 100644 --- a/src/components/activities/content/editors/TextEditor/toolbar/ColorPicker.tsx +++ b/src/components/activities/content/editors/TextEditor/toolbar/ColorPicker.tsx @@ -1,9 +1,10 @@ +import React from 'react'; + import FormatColorTextIcon from '@mui/icons-material/FormatColorText'; import ClickAwayListener from '@mui/material/ClickAwayListener'; import Paper from '@mui/material/Paper'; import ToggleButton from '@mui/material/ToggleButton'; import ToggleButtonGroup from '@mui/material/ToggleButtonGroup'; -import React from 'react'; const colors = [ 'rgb(46, 52, 59)', diff --git a/src/components/activities/content/editors/TextEditor/toolbar/EmojiPicker.tsx b/src/components/activities/content/editors/TextEditor/toolbar/EmojiPicker.tsx index 15772ae82..a2a2dbcff 100644 --- a/src/components/activities/content/editors/TextEditor/toolbar/EmojiPicker.tsx +++ b/src/components/activities/content/editors/TextEditor/toolbar/EmojiPicker.tsx @@ -1,9 +1,10 @@ +import React from 'react'; + import InsertEmoticonIcon from '@mui/icons-material/InsertEmoticon'; import ClickAwayListener from '@mui/material/ClickAwayListener'; import Paper from '@mui/material/Paper'; import ToggleButton from '@mui/material/ToggleButton'; import ToggleButtonGroup from '@mui/material/ToggleButtonGroup'; -import React from 'react'; const emojis = [ '😀', diff --git a/src/components/activities/content/editors/TextEditor/toolbar/InlineButtons.tsx b/src/components/activities/content/editors/TextEditor/toolbar/InlineButtons.tsx index 0df18ae62..f8fc5ba9d 100644 --- a/src/components/activities/content/editors/TextEditor/toolbar/InlineButtons.tsx +++ b/src/components/activities/content/editors/TextEditor/toolbar/InlineButtons.tsx @@ -1,9 +1,10 @@ +import React from 'react'; + import FormatBoldIcon from '@mui/icons-material/FormatBold'; import FormatItalicIcon from '@mui/icons-material/FormatItalic'; import FormatUnderlinedIcon from '@mui/icons-material/FormatUnderlined'; import ToggleButton from '@mui/material/ToggleButton'; import ToggleButtonGroup from '@mui/material/ToggleButtonGroup'; -import React from 'react'; type InlineProps = { value: { diff --git a/src/components/activities/content/editors/TextEditor/toolbar/Link.tsx b/src/components/activities/content/editors/TextEditor/toolbar/Link.tsx index 51929c093..3c18b4691 100644 --- a/src/components/activities/content/editors/TextEditor/toolbar/Link.tsx +++ b/src/components/activities/content/editors/TextEditor/toolbar/Link.tsx @@ -1,12 +1,13 @@ +import type { ContentBlock, ContentState } from 'draft-js'; +import { RichUtils, EditorState, Modifier } from 'draft-js'; +import { getEntityRange, getSelectionEntity } from 'draftjs-utils'; +import React from 'react'; + import { TextField, Button } from '@mui/material'; import ClickAwayListener from '@mui/material/ClickAwayListener'; import Paper from '@mui/material/Paper'; import ToggleButton from '@mui/material/ToggleButton'; import ToggleButtonGroup from '@mui/material/ToggleButtonGroup'; -import type { ContentBlock, ContentState } from 'draft-js'; -import { RichUtils, EditorState, Modifier } from 'draft-js'; -import { getEntityRange, getSelectionEntity } from 'draftjs-utils'; -import React from 'react'; import { primaryColor } from 'src/styles/variables.const'; diff --git a/src/components/activities/content/editors/TextEditor/toolbar/TextAlignButtons.tsx b/src/components/activities/content/editors/TextEditor/toolbar/TextAlignButtons.tsx index e21e22970..ceeef7e75 100644 --- a/src/components/activities/content/editors/TextEditor/toolbar/TextAlignButtons.tsx +++ b/src/components/activities/content/editors/TextEditor/toolbar/TextAlignButtons.tsx @@ -1,9 +1,10 @@ +import React from 'react'; + import FormatAlignCenterIcon from '@mui/icons-material/FormatAlignCenter'; import FormatAlignLeftIcon from '@mui/icons-material/FormatAlignLeft'; import FormatAlignRightIcon from '@mui/icons-material/FormatAlignRight'; import ToggleButton from '@mui/material/ToggleButton'; import ToggleButtonGroup from '@mui/material/ToggleButtonGroup'; -import React from 'react'; type InlineProps = { value: 'left' | 'center' | 'right'; diff --git a/src/components/activities/content/editors/TextEditor/toolbar/TitleChoice.tsx b/src/components/activities/content/editors/TextEditor/toolbar/TitleChoice.tsx index 48c457b94..f012bc875 100644 --- a/src/components/activities/content/editors/TextEditor/toolbar/TitleChoice.tsx +++ b/src/components/activities/content/editors/TextEditor/toolbar/TitleChoice.tsx @@ -1,6 +1,7 @@ +import React from 'react'; + import ToggleButton from '@mui/material/ToggleButton'; import ToggleButtonGroup from '@mui/material/ToggleButtonGroup'; -import React from 'react'; type TitleChoiceProps = { value: 'unstyle' | 'header-one' | 'header-two'; diff --git a/src/components/activities/content/editors/VideoEditor/VideoEditor.tsx b/src/components/activities/content/editors/VideoEditor/VideoEditor.tsx index d4e348cbc..7fe3913a3 100644 --- a/src/components/activities/content/editors/VideoEditor/VideoEditor.tsx +++ b/src/components/activities/content/editors/VideoEditor/VideoEditor.tsx @@ -1,7 +1,8 @@ -import { Button } from '@mui/material'; import React from 'react'; import ReactPlayer from 'react-player'; +import { Button } from '@mui/material'; + import type { EditorProps } from '../../content.types'; import { EditorContainer } from '../EditorContainer'; import { VideoModals } from './VideoModals'; diff --git a/src/components/activities/content/editors/VideoEditor/VideoModals.tsx b/src/components/activities/content/editors/VideoEditor/VideoModals.tsx index f85d394b2..d7adff012 100644 --- a/src/components/activities/content/editors/VideoEditor/VideoModals.tsx +++ b/src/components/activities/content/editors/VideoEditor/VideoModals.tsx @@ -1,14 +1,15 @@ -import ArrowRightAltIcon from '@mui/icons-material/ArrowRightAlt'; -import CloudUploadIcon from '@mui/icons-material/CloudUpload'; -import SettingsIcon from '@mui/icons-material/Settings'; -import { Button, Divider, TextField } from '@mui/material'; -import Alert from '@mui/material/Alert'; import Link from 'next/link'; import { useSnackbar } from 'notistack'; import React from 'react'; import ReactPlayer from 'react-player'; import { useQueryClient } from 'react-query'; +import ArrowRightAltIcon from '@mui/icons-material/ArrowRightAlt'; +import CloudUploadIcon from '@mui/icons-material/CloudUpload'; +import SettingsIcon from '@mui/icons-material/Settings'; +import { Button, Divider, TextField } from '@mui/material'; +import Alert from '@mui/material/Alert'; + import { Modal } from 'src/components/Modal'; import { useCopy } from 'src/hooks/useCopy'; import { defaultTextButtonStyle, fontDetailColor, bgPage } from 'src/styles/variables.const'; diff --git a/src/components/activities/content/views/SoundView.tsx b/src/components/activities/content/views/SoundView.tsx index e5cd007ed..5912faf3e 100644 --- a/src/components/activities/content/views/SoundView.tsx +++ b/src/components/activities/content/views/SoundView.tsx @@ -1,6 +1,7 @@ -import Alert from '@mui/material/Alert'; import React from 'react'; +import Alert from '@mui/material/Alert'; + import type { ViewProps } from '../content.types'; export const SoundView = ({ value }: ViewProps) => { diff --git a/src/components/activities/content/views/VideoView/VideoView.tsx b/src/components/activities/content/views/VideoView/VideoView.tsx index be075aea2..02ca521bc 100644 --- a/src/components/activities/content/views/VideoView/VideoView.tsx +++ b/src/components/activities/content/views/VideoView/VideoView.tsx @@ -1,8 +1,9 @@ -import { Button, CircularProgress } from '@mui/material'; import { useSnackbar } from 'notistack'; import React from 'react'; import ReactPlayer from 'react-player'; +import { Button, CircularProgress } from '@mui/material'; + import type { ViewProps } from '../../content.types'; import { KeepRatio } from 'src/components/KeepRatio'; import { serializeToQueryUrl } from 'src/utils'; diff --git a/src/components/admin/AdminHeader.tsx b/src/components/admin/AdminHeader.tsx index 0a966665b..2c41d1918 100644 --- a/src/components/admin/AdminHeader.tsx +++ b/src/components/admin/AdminHeader.tsx @@ -1,10 +1,11 @@ +import Link from 'next/link'; +import React from 'react'; + import { Button } from '@mui/material'; import AppBar from '@mui/material/AppBar'; import Toolbar from '@mui/material/Toolbar'; import Typography from '@mui/material/Typography'; import useScrollTrigger from '@mui/material/useScrollTrigger'; -import Link from 'next/link'; -import React from 'react'; import { defaultContainedButtonStyle } from 'src/styles/variables.const'; diff --git a/src/components/admin/AdminNavigation.tsx b/src/components/admin/AdminNavigation.tsx index 1bf9000c4..53b82fd95 100644 --- a/src/components/admin/AdminNavigation.tsx +++ b/src/components/admin/AdminNavigation.tsx @@ -1,3 +1,6 @@ +import { useRouter } from 'next/router'; +import React from 'react'; + import GroupIcon from '@mui/icons-material/Group'; import InsertChartOutlinedOutlinedIcon from '@mui/icons-material/InsertChartOutlinedOutlined'; import LanguageIcon from '@mui/icons-material/Language'; @@ -10,8 +13,6 @@ import ListItem from '@mui/material/ListItem'; import ListItemIcon from '@mui/material/ListItemIcon'; import ListItemText from '@mui/material/ListItemText'; import Toolbar from '@mui/material/Toolbar'; -import { useRouter } from 'next/router'; -import React from 'react'; const DRAWER_WIDTH = 220; const TABS = ['villages', 'users', 'featureFlag', 'stats', 'analytics']; diff --git a/src/components/admin/AdminTable.tsx b/src/components/admin/AdminTable.tsx index 62677ed1f..26e0d773d 100644 --- a/src/components/admin/AdminTable.tsx +++ b/src/components/admin/AdminTable.tsx @@ -1,3 +1,5 @@ +import React from 'react'; + import NoSsr from '@mui/material/NoSsr'; import Table from '@mui/material/Table'; import TableBody from '@mui/material/TableBody'; @@ -6,7 +8,6 @@ import TableHead from '@mui/material/TableHead'; import TablePagination from '@mui/material/TablePagination'; import TableRow from '@mui/material/TableRow'; import TableSortLabel from '@mui/material/TableSortLabel'; -import React from 'react'; function paginate(array: T[], pageSize: number, pageNumber: number): T[] { // human-readable page numbers usually start with 1, so we reduce 1 in the first argument diff --git a/src/components/admin/AdminTile.tsx b/src/components/admin/AdminTile.tsx index 4a512b983..3c670f269 100644 --- a/src/components/admin/AdminTile.tsx +++ b/src/components/admin/AdminTile.tsx @@ -1,7 +1,8 @@ +import React from 'react'; + import Paper from '@mui/material/Paper'; import Toolbar from '@mui/material/Toolbar'; import Typography from '@mui/material/Typography'; -import React from 'react'; interface AdminTileProps { title: string; diff --git a/src/components/admin/analytics/BarWidget.tsx b/src/components/admin/analytics/BarWidget.tsx index 6de392313..d9bbb704d 100644 --- a/src/components/admin/analytics/BarWidget.tsx +++ b/src/components/admin/analytics/BarWidget.tsx @@ -1,6 +1,7 @@ -import { Tab, Tabs, Paper } from '@mui/material'; import React from 'react'; +import { Tab, Tabs, Paper } from '@mui/material'; + import { primaryColorLight } from 'src/styles/variables.const'; interface BarWidgetProps { diff --git a/src/components/admin/analytics/TimePicker.tsx b/src/components/admin/analytics/TimePicker.tsx index a04860b52..552137fd9 100644 --- a/src/components/admin/analytics/TimePicker.tsx +++ b/src/components/admin/analytics/TimePicker.tsx @@ -1,8 +1,9 @@ +import React from 'react'; + import ChevronLeftIcon from '@mui/icons-material/ChevronLeft'; import ChevronRightIcon from '@mui/icons-material/ChevronRight'; import KeyboardArrowDownIcon from '@mui/icons-material/KeyboardArrowDown'; import { ButtonGroup, Button, Menu, MenuItem, Divider } from '@mui/material'; -import React from 'react'; import { defaultOutlinedButtonStyle } from 'src/styles/variables.const'; import { capitalize } from 'src/utils'; diff --git a/src/components/audio/Mixer.tsx b/src/components/audio/Mixer.tsx index ad7338a24..62e502d66 100644 --- a/src/components/audio/Mixer.tsx +++ b/src/components/audio/Mixer.tsx @@ -1,8 +1,9 @@ +import React from 'react'; + import InfoOutlinedIcon from '@mui/icons-material/InfoOutlined'; import { Button } from '@mui/material'; import Slider from '@mui/material/Slider'; import Tooltip from '@mui/material/Tooltip'; -import React from 'react'; import type { Sample } from 'src/activity-types/anthem.types'; import { primaryColor } from 'src/styles/variables.const'; diff --git a/src/components/buttons/CustomRadio.tsx b/src/components/buttons/CustomRadio.tsx index a5c7af1bf..3e8af37ce 100644 --- a/src/components/buttons/CustomRadio.tsx +++ b/src/components/buttons/CustomRadio.tsx @@ -1,6 +1,7 @@ +import * as React from 'react'; + import FiberManualRecordIcon from '@mui/icons-material/FiberManualRecord'; import { Radio } from '@mui/material'; -import * as React from 'react'; import { errorColor, successColor } from 'src/styles/variables.const'; diff --git a/src/components/buttons/DeleteButton.tsx b/src/components/buttons/DeleteButton.tsx index 82a09af8b..5b0b57845 100644 --- a/src/components/buttons/DeleteButton.tsx +++ b/src/components/buttons/DeleteButton.tsx @@ -1,7 +1,8 @@ +import React from 'react'; + import DeleteIcon from '@mui/icons-material/Delete'; import IconButton from '@mui/material/IconButton'; import type { Theme } from '@mui/material/styles'; -import React from 'react'; import { Modal } from 'src/components/Modal'; diff --git a/src/components/buttons/EditButton.tsx b/src/components/buttons/EditButton.tsx index 10ede9c4d..01a4bc10b 100644 --- a/src/components/buttons/EditButton.tsx +++ b/src/components/buttons/EditButton.tsx @@ -1,9 +1,10 @@ +import React from 'react'; + import EditIcon from '@mui/icons-material/Edit'; import type { ButtonProps } from '@mui/material'; import IconButton from '@mui/material/IconButton'; import Tooltip from '@mui/material/Tooltip'; import type { Theme } from '@mui/material/styles'; -import React from 'react'; import { successColor, errorColor, warningColor } from 'src/styles/variables.const'; diff --git a/src/components/buttons/HelpButton.tsx b/src/components/buttons/HelpButton.tsx index 28c622d89..e62c49967 100644 --- a/src/components/buttons/HelpButton.tsx +++ b/src/components/buttons/HelpButton.tsx @@ -1,6 +1,7 @@ +import React from 'react'; + import type { ButtonProps } from '@mui/material'; import Button from '@mui/material/Button'; -import React from 'react'; import { helpColor, helpColorDarker } from 'src/styles/variables.const'; import PelicoSearch from 'src/svg/pelico/pelico-search.svg'; diff --git a/src/components/buttons/QuestionButton.tsx b/src/components/buttons/QuestionButton.tsx index e8bf0bb0e..260e23556 100644 --- a/src/components/buttons/QuestionButton.tsx +++ b/src/components/buttons/QuestionButton.tsx @@ -1,6 +1,7 @@ +import React from 'react'; + import HelpIcon from '@mui/icons-material/Help'; import Popover from '@mui/material/Popover'; -import React from 'react'; interface QuestionButtonProps { helpMessage: string | React.ReactNode | React.ReactNodeArray; diff --git a/src/components/buttons/RedButton.tsx b/src/components/buttons/RedButton.tsx index 8ebaed67a..00c629a12 100644 --- a/src/components/buttons/RedButton.tsx +++ b/src/components/buttons/RedButton.tsx @@ -1,6 +1,7 @@ +import * as React from 'react'; + import type { ButtonProps } from '@mui/material/Button'; import Button from '@mui/material/Button'; -import * as React from 'react'; import { errorColor, errorColorDarker } from 'src/styles/variables.const'; diff --git a/src/components/buttons/ThemeChoiceButton.tsx b/src/components/buttons/ThemeChoiceButton.tsx index 29c3684e5..057265326 100644 --- a/src/components/buttons/ThemeChoiceButton.tsx +++ b/src/components/buttons/ThemeChoiceButton.tsx @@ -1,6 +1,7 @@ -import { ButtonBase } from '@mui/material'; import React from 'react'; +import { ButtonBase } from '@mui/material'; + import ArrowRight from 'src/svg/arrow-right.svg'; interface ThemeChoiceButtonProps { diff --git a/src/components/mon-compte/PanelInput.tsx b/src/components/mon-compte/PanelInput.tsx index 6453e8714..e9be8eaa6 100644 --- a/src/components/mon-compte/PanelInput.tsx +++ b/src/components/mon-compte/PanelInput.tsx @@ -1,7 +1,8 @@ -import TextField from '@mui/material/TextField'; import type { CSSProperties } from 'react'; import React from 'react'; +import TextField from '@mui/material/TextField'; + interface PanelInputProps { value: string | undefined; defaultValue?: string; diff --git a/src/components/selectors/CountrySelector.tsx b/src/components/selectors/CountrySelector.tsx index 832a7ba61..c8072bc73 100644 --- a/src/components/selectors/CountrySelector.tsx +++ b/src/components/selectors/CountrySelector.tsx @@ -1,7 +1,8 @@ +import React from 'react'; + import { Box } from '@mui/material'; import Autocomplete from '@mui/material/Autocomplete'; import TextField from '@mui/material/TextField'; -import React from 'react'; import { useCountries } from 'src/services/useCountries'; import { countryToFlag } from 'src/utils'; diff --git a/src/components/selectors/LanguageSelector.tsx b/src/components/selectors/LanguageSelector.tsx index b09e49ead..173a5b8fc 100644 --- a/src/components/selectors/LanguageSelector.tsx +++ b/src/components/selectors/LanguageSelector.tsx @@ -1,7 +1,8 @@ +import React from 'react'; + import { Box } from '@mui/material'; import Autocomplete from '@mui/material/Autocomplete'; import TextField from '@mui/material/TextField'; -import React from 'react'; import { useLanguages } from 'src/services/useLanguages'; import type { Language } from 'types/language.type'; diff --git a/src/components/selectors/MimicSelector.tsx b/src/components/selectors/MimicSelector.tsx index 5d82112f5..9b2ca0128 100644 --- a/src/components/selectors/MimicSelector.tsx +++ b/src/components/selectors/MimicSelector.tsx @@ -1,8 +1,9 @@ -import { TextField, Grid, Button } from '@mui/material'; import type { ChangeEventHandler } from 'react'; import React from 'react'; import ReactPlayer from 'react-player'; +import { TextField, Grid, Button } from '@mui/material'; + import { Base } from 'src/components/Base'; import { StepsButton } from 'src/components/StepsButtons'; import { VideoModals } from 'src/components/activities/content/editors/VideoEditor/VideoModals'; diff --git a/src/components/selectors/MultipleCountrySelector.tsx b/src/components/selectors/MultipleCountrySelector.tsx index fcf9991c9..a95920ab1 100644 --- a/src/components/selectors/MultipleCountrySelector.tsx +++ b/src/components/selectors/MultipleCountrySelector.tsx @@ -1,6 +1,7 @@ +import React from 'react'; + import Autocomplete from '@mui/material/Autocomplete'; import TextField from '@mui/material/TextField'; -import React from 'react'; import { useCountries } from 'src/services/useCountries'; import type { Country } from 'types/country.type'; diff --git a/src/components/selectors/MultipleCurrencySelector.tsx b/src/components/selectors/MultipleCurrencySelector.tsx index 84f3b1d16..4069a41dc 100644 --- a/src/components/selectors/MultipleCurrencySelector.tsx +++ b/src/components/selectors/MultipleCurrencySelector.tsx @@ -1,6 +1,7 @@ +import React from 'react'; + import Autocomplete from '@mui/material/Autocomplete'; import TextField from '@mui/material/TextField'; -import React from 'react'; import { useCurrencies } from 'src/services/useCurrencies'; import type { Currency } from 'types/currency.type'; diff --git a/src/components/selectors/MultipleLanguageSelector.tsx b/src/components/selectors/MultipleLanguageSelector.tsx index b02b395df..aef40877f 100644 --- a/src/components/selectors/MultipleLanguageSelector.tsx +++ b/src/components/selectors/MultipleLanguageSelector.tsx @@ -1,6 +1,7 @@ +import React from 'react'; + import Autocomplete from '@mui/material/Autocomplete'; import TextField from '@mui/material/TextField'; -import React from 'react'; import { useLanguages } from 'src/services/useLanguages'; import type { Language } from 'types/language.type'; diff --git a/src/components/storyPictureWheel/storyPictureWheel.tsx b/src/components/storyPictureWheel/storyPictureWheel.tsx index 897a887a0..0cc3ef157 100644 --- a/src/components/storyPictureWheel/storyPictureWheel.tsx +++ b/src/components/storyPictureWheel/storyPictureWheel.tsx @@ -1,8 +1,9 @@ +import classNames from 'classnames'; +import React from 'react'; + import { Grid, Typography, CardMedia, Tooltip } from '@mui/material'; import Box from '@mui/material/Box'; import Paper from '@mui/material/Paper'; -import classNames from 'classnames'; -import React from 'react'; import { useImageStories } from 'src/services/useImagesStory'; import SlotMachineHandle from 'src/svg/story-activity/slot-machine-handle.svg'; diff --git a/src/components/table/CollapsibleTable.tsx b/src/components/table/CollapsibleTable.tsx index 145658348..1bfbd5762 100644 --- a/src/components/table/CollapsibleTable.tsx +++ b/src/components/table/CollapsibleTable.tsx @@ -1,5 +1,8 @@ // import KeyboardArrowDownIcon from '@mui/icons-material/KeyboardArrowDown'; // import KeyboardArrowUpIcon from '@mui/icons-material/KeyboardArrowUp'; +import { useContext, useEffect, useState } from 'react'; +import * as React from 'react'; + import { Button, Checkbox } from '@mui/material'; import Box from '@mui/material/Box'; // import Collapse from '@mui/material/Collapse'; @@ -11,8 +14,6 @@ import TableCell from '@mui/material/TableCell'; import TableContainer from '@mui/material/TableContainer'; import TableHead from '@mui/material/TableHead'; import TableRow from '@mui/material/TableRow'; -import { useContext, useEffect, useState } from 'react'; -import * as React from 'react'; // import { DeleteButton } from '../buttons/DeleteButton'; // import { deleteUserStudentRelation } from 'src/api/student/student.delete'; diff --git a/src/contexts/activityContext.tsx b/src/contexts/activityContext.tsx index 4e6efcb18..2e4e354a1 100644 --- a/src/contexts/activityContext.tsx +++ b/src/contexts/activityContext.tsx @@ -1,8 +1,9 @@ -import { Card, CircularProgress } from '@mui/material'; import { useRouter } from 'next/router'; import React from 'react'; import { useQueryClient } from 'react-query'; +import { Card, CircularProgress } from '@mui/material'; + import { UserContext } from './userContext'; import { VillageContext } from './villageContext'; import { Modal } from 'src/components/Modal'; diff --git a/src/contexts/classroomContext.tsx b/src/contexts/classroomContext.tsx index 900204dbd..c3e7ccf47 100644 --- a/src/contexts/classroomContext.tsx +++ b/src/contexts/classroomContext.tsx @@ -1,4 +1,4 @@ -import React, { useEffect } from 'react'; +import React from 'react'; import { UserContext } from './userContext'; import { VillageContext } from './villageContext'; @@ -284,8 +284,6 @@ export const ClassroomContextProvider = ({ children }: ClassroomContextProviderP // eslint-disable-next-line react-hooks/exhaustive-deps }, [createClassroom, fetchClassroom, getStudents, user]); - useEffect(() => {}, [classroom]); - const value = React.useMemo( () => ({ classroom, diff --git a/src/pages/404.tsx b/src/pages/404.tsx index 03e9d09ff..3c36e1016 100644 --- a/src/pages/404.tsx +++ b/src/pages/404.tsx @@ -1,7 +1,8 @@ -import Button from '@mui/material/Button'; import Link from 'next/link'; import React from 'react'; +import Button from '@mui/material/Button'; + import { KeepRatio } from 'src/components/KeepRatio'; import PelicoSearch from 'src/svg/pelico/pelico-search.svg'; diff --git a/src/pages/_error.tsx b/src/pages/_error.tsx index 335aa18f1..ab2decd51 100644 --- a/src/pages/_error.tsx +++ b/src/pages/_error.tsx @@ -1,8 +1,9 @@ -import { Button } from '@mui/material'; import type { NextPageContext } from 'next'; import Link from 'next/link'; import React from 'react'; +import { Button } from '@mui/material'; + import { Base } from 'src/components/Base'; const ErrorPage = () => { diff --git a/src/pages/activite/[id].tsx b/src/pages/activite/[id].tsx index 71c8475bf..df70efa7f 100644 --- a/src/pages/activite/[id].tsx +++ b/src/pages/activite/[id].tsx @@ -1,8 +1,9 @@ -import ChevronRightIcon from '@mui/icons-material/ChevronRight'; import Link from 'next/link'; import { useRouter } from 'next/router'; import React from 'react'; +import ChevronRightIcon from '@mui/icons-material/ChevronRight'; + import { isEnigme } from 'src/activity-types/anyActivity'; import { Base } from 'src/components/Base'; import { RightNavigation } from 'src/components/accueil/RightNavigation'; diff --git a/src/pages/admin/analytics.tsx b/src/pages/admin/analytics.tsx index 6c50888dc..e411246d6 100644 --- a/src/pages/admin/analytics.tsx +++ b/src/pages/admin/analytics.tsx @@ -1,9 +1,10 @@ -import { Paper, Grid } from '@mui/material'; -import MaterialLink from '@mui/material/Link'; import Image from 'next/image'; import Link from 'next/link'; import React from 'react'; +import { Paper, Grid } from '@mui/material'; +import MaterialLink from '@mui/material/Link'; + import { BarWidget } from 'src/components/admin/analytics/BarWidget'; import { TimePicker, getToday } from 'src/components/admin/analytics/TimePicker'; import { TimeserieWidget } from 'src/components/admin/analytics/TimeserieWidget'; diff --git a/src/pages/admin/stats.tsx b/src/pages/admin/stats.tsx index bb410edc3..bed135e8f 100644 --- a/src/pages/admin/stats.tsx +++ b/src/pages/admin/stats.tsx @@ -1,7 +1,8 @@ -import MaterialLink from '@mui/material/Link'; import Link from 'next/link'; import React from 'react'; +import MaterialLink from '@mui/material/Link'; + const Stats = () => { return (
diff --git a/src/pages/admin/users/edit/[id].tsx b/src/pages/admin/users/edit/[id].tsx index 719edcf6e..e365604fd 100644 --- a/src/pages/admin/users/edit/[id].tsx +++ b/src/pages/admin/users/edit/[id].tsx @@ -1,3 +1,8 @@ +import Link from 'next/link'; +import { useRouter } from 'next/router'; +import { useSnackbar } from 'notistack'; +import React from 'react'; + import NavigateNextIcon from '@mui/icons-material/NavigateNext'; import Breadcrumbs from '@mui/material/Breadcrumbs'; import Button from '@mui/material/Button'; @@ -7,10 +12,6 @@ import MaterialLink from '@mui/material/Link'; import MenuItem from '@mui/material/MenuItem'; import Select from '@mui/material/Select'; import TextField from '@mui/material/TextField'; -import Link from 'next/link'; -import { useRouter } from 'next/router'; -import { useSnackbar } from 'notistack'; -import React from 'react'; import { AdminTile } from 'src/components/admin/AdminTile'; import { CountrySelector } from 'src/components/selectors/CountrySelector'; diff --git a/src/pages/admin/users/index.tsx b/src/pages/admin/users/index.tsx index 84e53d01d..74736b6a3 100644 --- a/src/pages/admin/users/index.tsx +++ b/src/pages/admin/users/index.tsx @@ -1,3 +1,7 @@ +import Link from 'next/link'; +import { useRouter } from 'next/router'; +import React, { useCallback, useMemo, useState } from 'react'; + import AddCircleIcon from '@mui/icons-material/AddCircle'; import DeleteIcon from '@mui/icons-material/Delete'; import DownloadIcon from '@mui/icons-material/Download'; @@ -10,9 +14,6 @@ import IconButton from '@mui/material/IconButton'; import MaterialLink from '@mui/material/Link'; import NoSsr from '@mui/material/NoSsr'; import Tooltip from '@mui/material/Tooltip'; -import Link from 'next/link'; -import { useRouter } from 'next/router'; -import React, { useCallback, useMemo, useState } from 'react'; import { Modal } from 'src/components/Modal'; import { AdminTable } from 'src/components/admin/AdminTable'; diff --git a/src/pages/admin/users/new.tsx b/src/pages/admin/users/new.tsx index 8bfd8b88a..ba22bd668 100644 --- a/src/pages/admin/users/new.tsx +++ b/src/pages/admin/users/new.tsx @@ -1,3 +1,8 @@ +import Link from 'next/link'; +import { useRouter } from 'next/router'; +import { useSnackbar } from 'notistack'; +import React from 'react'; + import NavigateNextIcon from '@mui/icons-material/NavigateNext'; import Breadcrumbs from '@mui/material/Breadcrumbs'; import Button from '@mui/material/Button'; @@ -7,10 +12,6 @@ import MaterialLink from '@mui/material/Link'; import MenuItem from '@mui/material/MenuItem'; import Select from '@mui/material/Select'; import TextField from '@mui/material/TextField'; -import Link from 'next/link'; -import { useRouter } from 'next/router'; -import { useSnackbar } from 'notistack'; -import React from 'react'; import { AdminTile } from 'src/components/admin/AdminTile'; import { CountrySelector } from 'src/components/selectors/CountrySelector'; diff --git a/src/pages/admin/villages/edit/[id].tsx b/src/pages/admin/villages/edit/[id].tsx index 8250c1017..8f7bb6544 100644 --- a/src/pages/admin/villages/edit/[id].tsx +++ b/src/pages/admin/villages/edit/[id].tsx @@ -1,10 +1,11 @@ +import Link from 'next/link'; +import { useRouter } from 'next/router'; +import React from 'react'; + import NavigateNextIcon from '@mui/icons-material/NavigateNext'; import { Button, TextField } from '@mui/material'; import Breadcrumbs from '@mui/material/Breadcrumbs'; import MaterialLink from '@mui/material/Link'; -import Link from 'next/link'; -import { useRouter } from 'next/router'; -import React from 'react'; import { AdminTile } from 'src/components/admin/AdminTile'; import { CountrySelector } from 'src/components/selectors/CountrySelector'; diff --git a/src/pages/admin/villages/index.tsx b/src/pages/admin/villages/index.tsx index bee1097fe..9d61a1412 100644 --- a/src/pages/admin/villages/index.tsx +++ b/src/pages/admin/villages/index.tsx @@ -1,3 +1,7 @@ +import Link from 'next/link'; +import { useRouter } from 'next/router'; +import React, { useCallback, useMemo, useState } from 'react'; + import AddCircleIcon from '@mui/icons-material/AddCircle'; import DeleteIcon from '@mui/icons-material/Delete'; import EditIcon from '@mui/icons-material/Edit'; @@ -8,9 +12,6 @@ import CircularProgress from '@mui/material/CircularProgress'; import IconButton from '@mui/material/IconButton'; import MaterialLink from '@mui/material/Link'; import Tooltip from '@mui/material/Tooltip'; -import Link from 'next/link'; -import { useRouter } from 'next/router'; -import React, { useCallback, useMemo, useState } from 'react'; import { Modal } from 'src/components/Modal'; import { AdminTable } from 'src/components/admin/AdminTable'; diff --git a/src/pages/admin/villages/new.tsx b/src/pages/admin/villages/new.tsx index 2ca7ab37c..a8feb2d87 100644 --- a/src/pages/admin/villages/new.tsx +++ b/src/pages/admin/villages/new.tsx @@ -1,10 +1,11 @@ +import Link from 'next/link'; +import { useRouter } from 'next/router'; +import React from 'react'; + import NavigateNextIcon from '@mui/icons-material/NavigateNext'; import { Button, TextField } from '@mui/material'; import Breadcrumbs from '@mui/material/Breadcrumbs'; import MaterialLink from '@mui/material/Link'; -import Link from 'next/link'; -import { useRouter } from 'next/router'; -import React from 'react'; import { AdminTile } from 'src/components/admin/AdminTile'; import { CountrySelector } from 'src/components/selectors/CountrySelector'; diff --git a/src/pages/chanter-un-couplet/1.tsx b/src/pages/chanter-un-couplet/1.tsx index 63abe1d80..f27bbd59c 100644 --- a/src/pages/chanter-un-couplet/1.tsx +++ b/src/pages/chanter-un-couplet/1.tsx @@ -1,8 +1,9 @@ -import Backdrop from '@mui/material/Backdrop'; -import CircularProgress from '@mui/material/CircularProgress'; import { useRouter } from 'next/router'; import React from 'react'; +import Backdrop from '@mui/material/Backdrop'; +import CircularProgress from '@mui/material/CircularProgress'; + import type { VerseRecordData } from 'src/activity-types/verseRecord.types'; import { Base } from 'src/components/Base'; import { Steps } from 'src/components/Steps'; diff --git a/src/pages/chanter-un-couplet/4.tsx b/src/pages/chanter-un-couplet/4.tsx index 7bdf72bba..0b8984673 100644 --- a/src/pages/chanter-un-couplet/4.tsx +++ b/src/pages/chanter-un-couplet/4.tsx @@ -1,8 +1,9 @@ +import { useRouter } from 'next/router'; +import React from 'react'; + import Backdrop from '@mui/material/Backdrop'; import Button from '@mui/material/Button'; import CircularProgress from '@mui/material/CircularProgress'; -import { useRouter } from 'next/router'; -import React from 'react'; import type { VerseRecordData } from 'src/activity-types/verseRecord.types'; import { Base } from 'src/components/Base'; diff --git a/src/pages/chanter-un-couplet/5.tsx b/src/pages/chanter-un-couplet/5.tsx index 48a98a3e2..504bd013f 100644 --- a/src/pages/chanter-un-couplet/5.tsx +++ b/src/pages/chanter-un-couplet/5.tsx @@ -1,11 +1,12 @@ -import Backdrop from '@mui/material/Backdrop'; -import Button from '@mui/material/Button'; -import CircularProgress from '@mui/material/CircularProgress'; import classNames from 'classnames'; import Link from 'next/link'; import { useRouter } from 'next/router'; import React from 'react'; +import Backdrop from '@mui/material/Backdrop'; +import Button from '@mui/material/Button'; +import CircularProgress from '@mui/material/CircularProgress'; + import type { VerseRecordData } from 'src/activity-types/verseRecord.types'; import { Base } from 'src/components/Base'; import { Steps } from 'src/components/Steps'; diff --git a/src/pages/chanter-un-couplet/success.tsx b/src/pages/chanter-un-couplet/success.tsx index 59d98ea5d..e5dc6effa 100644 --- a/src/pages/chanter-un-couplet/success.tsx +++ b/src/pages/chanter-un-couplet/success.tsx @@ -1,7 +1,8 @@ -import { Button } from '@mui/material'; import Link from 'next/link'; import React from 'react'; +import { Button } from '@mui/material'; + import { Base } from 'src/components/Base'; import { bgPage } from 'src/styles/variables.const'; import PelicoSouriant from 'src/svg/pelico/pelico-souriant.svg'; diff --git a/src/pages/contenu-libre/2.tsx b/src/pages/contenu-libre/2.tsx index cebfb2e7f..c6995aae3 100644 --- a/src/pages/contenu-libre/2.tsx +++ b/src/pages/contenu-libre/2.tsx @@ -1,8 +1,9 @@ -import { TextField, Switch, Button } from '@mui/material'; import Image from 'next/image'; import { useRouter } from 'next/router'; import React from 'react'; +import { TextField, Switch, Button } from '@mui/material'; + import { isFreeContent } from 'src/activity-types/anyActivity'; import { getImage } from 'src/activity-types/freeContent.constants'; import type { FreeContentData } from 'src/activity-types/freeContent.types'; diff --git a/src/pages/contenu-libre/3.tsx b/src/pages/contenu-libre/3.tsx index a67e92ebb..460f3cadd 100644 --- a/src/pages/contenu-libre/3.tsx +++ b/src/pages/contenu-libre/3.tsx @@ -1,11 +1,12 @@ -import Backdrop from '@mui/material/Backdrop'; -import Button from '@mui/material/Button'; -import CircularProgress from '@mui/material/CircularProgress'; import classNames from 'classnames'; import Link from 'next/link'; import { useRouter } from 'next/router'; import React from 'react'; +import Backdrop from '@mui/material/Backdrop'; +import Button from '@mui/material/Button'; +import CircularProgress from '@mui/material/CircularProgress'; + import { isFreeContent } from 'src/activity-types/anyActivity'; import type { FreeContentData } from 'src/activity-types/freeContent.types'; import { Base } from 'src/components/Base'; diff --git a/src/pages/contenu-libre/success.tsx b/src/pages/contenu-libre/success.tsx index 1f04b3cdc..3d4678224 100644 --- a/src/pages/contenu-libre/success.tsx +++ b/src/pages/contenu-libre/success.tsx @@ -1,7 +1,8 @@ -import { Button } from '@mui/material'; import Link from 'next/link'; import React from 'react'; +import { Button } from '@mui/material'; + import { Base } from 'src/components/Base'; import { bgPage } from 'src/styles/variables.const'; import PelicoSouriant from 'src/svg/pelico/pelico-souriant.svg'; diff --git a/src/pages/creer-un-jeu/mimique/4.tsx b/src/pages/creer-un-jeu/mimique/4.tsx index d92eaf747..d7deabc4c 100644 --- a/src/pages/creer-un-jeu/mimique/4.tsx +++ b/src/pages/creer-un-jeu/mimique/4.tsx @@ -1,10 +1,11 @@ -import { Grid, Button, Radio, RadioGroup, FormControlLabel, Backdrop, CircularProgress, Tooltip } from '@mui/material'; import classNames from 'classnames'; import { useRouter } from 'next/router'; import React from 'react'; import ReactPlayer from 'react-player'; import type { SourceProps } from 'react-player/base'; +import { Grid, Button, Radio, RadioGroup, FormControlLabel, Backdrop, CircularProgress, Tooltip } from '@mui/material'; + import { isGame } from 'src/activity-types/anyActivity'; import { isMimic, isMimicValid } from 'src/activity-types/game.constants'; import { Base } from 'src/components/Base'; diff --git a/src/pages/creer-un-jeu/mimique/index.tsx b/src/pages/creer-un-jeu/mimique/index.tsx index 5379b9778..75458e161 100644 --- a/src/pages/creer-un-jeu/mimique/index.tsx +++ b/src/pages/creer-un-jeu/mimique/index.tsx @@ -1,8 +1,9 @@ -import Button from '@mui/material/Button'; import Link from 'next/link'; import { useRouter } from 'next/router'; import React from 'react'; +import Button from '@mui/material/Button'; + import { Base } from 'src/components/Base'; import { useGameRequests } from 'src/services/useGames'; import { GameType } from 'types/game.type'; diff --git a/src/pages/creer-un-jeu/mimique/jouer.tsx b/src/pages/creer-un-jeu/mimique/jouer.tsx index 1c0e1c86e..9250f3e2f 100644 --- a/src/pages/creer-un-jeu/mimique/jouer.tsx +++ b/src/pages/creer-un-jeu/mimique/jouer.tsx @@ -1,8 +1,9 @@ -import { Box, Button, FormControlLabel, Grid, Radio, RadioGroup } from '@mui/material'; import Link from 'next/link'; import { useRouter } from 'next/router'; import React from 'react'; +import { Box, Button, FormControlLabel, Grid, Radio, RadioGroup } from '@mui/material'; + import { AvatarImg } from 'src/components/Avatar'; import { Base } from 'src/components/Base'; import { Flag } from 'src/components/Flag'; diff --git a/src/pages/creer-un-jeu/success.tsx b/src/pages/creer-un-jeu/success.tsx index 0aef8b876..d629ffa5b 100644 --- a/src/pages/creer-un-jeu/success.tsx +++ b/src/pages/creer-un-jeu/success.tsx @@ -1,8 +1,9 @@ -import Button from '@mui/material/Button'; import Link from 'next/link'; import { useRouter } from 'next/router'; import React from 'react'; +import Button from '@mui/material/Button'; + import { isGame } from 'src/activity-types/anyActivity'; import { Base } from 'src/components/Base'; import { ActivityContext } from 'src/contexts/activityContext'; diff --git a/src/pages/creer-une-enigme/1.tsx b/src/pages/creer-une-enigme/1.tsx index c0e2cd4d7..fb6959f44 100644 --- a/src/pages/creer-une-enigme/1.tsx +++ b/src/pages/creer-une-enigme/1.tsx @@ -1,7 +1,8 @@ -import { Button, TextField } from '@mui/material'; import { useRouter } from 'next/router'; import React from 'react'; +import { Button, TextField } from '@mui/material'; + import { isEnigme } from 'src/activity-types/anyActivity'; import { ENIGME_TYPES, getCategoryName } from 'src/activity-types/enigme.constants'; import type { EnigmeData } from 'src/activity-types/enigme.types'; diff --git a/src/pages/creer-une-enigme/4.tsx b/src/pages/creer-une-enigme/4.tsx index 87ff3c2ec..e24bc711b 100644 --- a/src/pages/creer-une-enigme/4.tsx +++ b/src/pages/creer-une-enigme/4.tsx @@ -1,12 +1,13 @@ -import { Tooltip } from '@mui/material'; -import Backdrop from '@mui/material/Backdrop'; -import Button from '@mui/material/Button'; -import CircularProgress from '@mui/material/CircularProgress'; import classNames from 'classnames'; import Link from 'next/link'; import { useRouter } from 'next/router'; import React from 'react'; +import { Tooltip } from '@mui/material'; +import Backdrop from '@mui/material/Backdrop'; +import Button from '@mui/material/Button'; +import CircularProgress from '@mui/material/CircularProgress'; + import { isEnigme } from 'src/activity-types/anyActivity'; import { ENIGME_TYPES, getCategoryName, getSubcategoryName } from 'src/activity-types/enigme.constants'; import type { EnigmeData } from 'src/activity-types/enigme.types'; diff --git a/src/pages/creer-une-enigme/success.tsx b/src/pages/creer-une-enigme/success.tsx index 8d0bfcc41..688ce8e98 100644 --- a/src/pages/creer-une-enigme/success.tsx +++ b/src/pages/creer-une-enigme/success.tsx @@ -1,7 +1,8 @@ -import { Button } from '@mui/material'; import Link from 'next/link'; import React from 'react'; +import { Button } from '@mui/material'; + import { Base } from 'src/components/Base'; import { bgPage } from 'src/styles/variables.const'; import PelicoSouriant from 'src/svg/pelico/pelico-souriant.svg'; diff --git a/src/pages/creer-une-histoire/1.tsx b/src/pages/creer-une-histoire/1.tsx index 8a9d7bb97..d90da9376 100644 --- a/src/pages/creer-une-histoire/1.tsx +++ b/src/pages/creer-une-histoire/1.tsx @@ -1,9 +1,10 @@ -import AddIcon from '@mui/icons-material/Add'; -import { Grid, ButtonBase, FormControl, FormHelperText, InputLabel, MenuItem, Select } from '@mui/material'; import Image from 'next/image'; import { useRouter } from 'next/router'; import React from 'react'; +import AddIcon from '@mui/icons-material/Add'; +import { Grid, ButtonBase, FormControl, FormHelperText, InputLabel, MenuItem, Select } from '@mui/material'; + import { isStory } from 'src/activity-types/anyActivity'; import { DEFAULT_STORY_DATA, ODD_CHOICE } from 'src/activity-types/story.constants'; import { Base } from 'src/components/Base'; diff --git a/src/pages/creer-une-histoire/2.tsx b/src/pages/creer-une-histoire/2.tsx index 6a80de334..a1c6ece68 100644 --- a/src/pages/creer-une-histoire/2.tsx +++ b/src/pages/creer-une-histoire/2.tsx @@ -1,9 +1,10 @@ -import AddIcon from '@mui/icons-material/Add'; -import { TextField, Grid, ButtonBase } from '@mui/material'; import Image from 'next/image'; import { useRouter } from 'next/router'; import React from 'react'; +import AddIcon from '@mui/icons-material/Add'; +import { TextField, Grid, ButtonBase } from '@mui/material'; + import { isStory } from 'src/activity-types/anyActivity'; import { Base } from 'src/components/Base'; import { KeepRatio } from 'src/components/KeepRatio'; diff --git a/src/pages/creer-une-histoire/3.tsx b/src/pages/creer-une-histoire/3.tsx index 453c9de9b..dff02cb9f 100644 --- a/src/pages/creer-une-histoire/3.tsx +++ b/src/pages/creer-une-histoire/3.tsx @@ -1,9 +1,10 @@ -import AddIcon from '@mui/icons-material/Add'; -import { TextField, Grid, ButtonBase } from '@mui/material'; import Image from 'next/image'; import { useRouter } from 'next/router'; import React from 'react'; +import AddIcon from '@mui/icons-material/Add'; +import { TextField, Grid, ButtonBase } from '@mui/material'; + import { isStory } from 'src/activity-types/anyActivity'; import { Base } from 'src/components/Base'; import { KeepRatio } from 'src/components/KeepRatio'; diff --git a/src/pages/creer-une-histoire/4.tsx b/src/pages/creer-une-histoire/4.tsx index af9aef24c..38acac17f 100644 --- a/src/pages/creer-une-histoire/4.tsx +++ b/src/pages/creer-une-histoire/4.tsx @@ -1,9 +1,10 @@ -import AddIcon from '@mui/icons-material/Add'; -import { TextField, Grid, ButtonBase } from '@mui/material'; import Image from 'next/image'; import { useRouter } from 'next/router'; import React from 'react'; +import AddIcon from '@mui/icons-material/Add'; +import { TextField, Grid, ButtonBase } from '@mui/material'; + import { isStory } from 'src/activity-types/anyActivity'; import { Base } from 'src/components/Base'; import { KeepRatio } from 'src/components/KeepRatio'; diff --git a/src/pages/creer-une-histoire/5.tsx b/src/pages/creer-une-histoire/5.tsx index 817d5dbb8..7dc8d84e7 100644 --- a/src/pages/creer-une-histoire/5.tsx +++ b/src/pages/creer-une-histoire/5.tsx @@ -1,8 +1,9 @@ -import { Tooltip, Button, Backdrop, CircularProgress } from '@mui/material'; import Link from 'next/link'; import { useRouter } from 'next/router'; import React from 'react'; +import { Tooltip, Button, Backdrop, CircularProgress } from '@mui/material'; + import { isStory } from 'src/activity-types/anyActivity'; import { Base } from 'src/components/Base'; import { ImageStepContainer } from 'src/components/FinalStep/ImageStepContainer'; diff --git a/src/pages/creer-une-histoire/index.tsx b/src/pages/creer-une-histoire/index.tsx index bac5fa91e..c8b7ad1e6 100644 --- a/src/pages/creer-une-histoire/index.tsx +++ b/src/pages/creer-une-histoire/index.tsx @@ -1,7 +1,8 @@ -import { Button } from '@mui/material'; import Link from 'next/link'; import React from 'react'; +import { Button } from '@mui/material'; + import { Base } from 'src/components/Base'; const Story = () => { diff --git a/src/pages/creer-une-histoire/success.tsx b/src/pages/creer-une-histoire/success.tsx index a314d0753..280071c07 100644 --- a/src/pages/creer-une-histoire/success.tsx +++ b/src/pages/creer-une-histoire/success.tsx @@ -1,7 +1,8 @@ -import { Button } from '@mui/material'; import Link from 'next/link'; import React from 'react'; +import { Button } from '@mui/material'; + import { Base } from 'src/components/Base'; import { bgPage } from 'src/styles/variables.const'; import PelicoSouriant from 'src/svg/pelico/pelico-souriant.svg'; diff --git a/src/pages/familles/1.tsx b/src/pages/familles/1.tsx index b1e4cefaa..897fc5141 100644 --- a/src/pages/familles/1.tsx +++ b/src/pages/familles/1.tsx @@ -1,7 +1,8 @@ -import { Button, CircularProgress, FormControl, FormControlLabel, Radio, RadioGroup } from '@mui/material'; import { useRouter } from 'next/router'; import React, { useContext, useEffect, useReducer } from 'react'; +import { Button, CircularProgress, FormControl, FormControlLabel, Radio, RadioGroup } from '@mui/material'; + import AccessControl from 'src/components/AccessControl'; import { Base } from 'src/components/Base'; import OverflowContainer from 'src/components/OverflowContainer'; diff --git a/src/pages/familles/2.tsx b/src/pages/familles/2.tsx index 4e944c3a6..842a1e206 100644 --- a/src/pages/familles/2.tsx +++ b/src/pages/familles/2.tsx @@ -1,11 +1,12 @@ // eslint-disable-next-line @typescript-eslint/ban-ts-comment // @ts-nocheck +import { useRouter } from 'next/router'; +import React, { useState, useEffect } from 'react'; + import ModeEditOutlineRoundedIcon from '@mui/icons-material/ModeEditOutlineRounded'; import { TextField } from '@mui/material'; import Button from '@mui/material/Button'; -import { useRouter } from 'next/router'; -import React, { useState, useEffect } from 'react'; import { editStudent } from 'src/api/classroom/student.put'; import AccessControl from 'src/components/AccessControl'; diff --git a/src/pages/familles/3.tsx b/src/pages/familles/3.tsx index 2eec5d52f..bf53d0081 100644 --- a/src/pages/familles/3.tsx +++ b/src/pages/familles/3.tsx @@ -1,8 +1,9 @@ -import { Box, Button } from '@mui/material'; import dynamic from 'next/dynamic'; import { useRouter } from 'next/router'; import React, { useEffect, useState } from 'react'; +import { Box, Button } from '@mui/material'; + import AccessControl from 'src/components/AccessControl'; import { Base } from 'src/components/Base'; import { Modal } from 'src/components/Modal'; diff --git a/src/pages/indice-culturel/1.tsx b/src/pages/indice-culturel/1.tsx index 42215b807..3d9af3cb4 100644 --- a/src/pages/indice-culturel/1.tsx +++ b/src/pages/indice-culturel/1.tsx @@ -1,7 +1,8 @@ -import { TextField } from '@mui/material'; import { useRouter } from 'next/router'; import React from 'react'; +import { TextField } from '@mui/material'; + import { getIndice } from 'src/activity-types/indice.constants'; import type { IndiceData } from 'src/activity-types/indice.types'; import { Base } from 'src/components/Base'; diff --git a/src/pages/indice-culturel/3.tsx b/src/pages/indice-culturel/3.tsx index 3d5fa2f9d..61732a942 100644 --- a/src/pages/indice-culturel/3.tsx +++ b/src/pages/indice-culturel/3.tsx @@ -1,12 +1,13 @@ -import { Tooltip } from '@mui/material'; -import Backdrop from '@mui/material/Backdrop'; -import Button from '@mui/material/Button'; -import CircularProgress from '@mui/material/CircularProgress'; import classNames from 'classnames'; import Link from 'next/link'; import { useRouter } from 'next/router'; import React from 'react'; +import { Tooltip } from '@mui/material'; +import Backdrop from '@mui/material/Backdrop'; +import Button from '@mui/material/Button'; +import CircularProgress from '@mui/material/CircularProgress'; + import { isIndice } from 'src/activity-types/anyActivity'; import { getIndice } from 'src/activity-types/indice.constants'; import type { IndiceData } from 'src/activity-types/indice.types'; diff --git a/src/pages/indice-culturel/success.tsx b/src/pages/indice-culturel/success.tsx index 452e5c878..69ae93074 100644 --- a/src/pages/indice-culturel/success.tsx +++ b/src/pages/indice-culturel/success.tsx @@ -1,7 +1,8 @@ -import { Button } from '@mui/material'; import Link from 'next/link'; import React from 'react'; +import { Button } from '@mui/material'; + import { Base } from 'src/components/Base'; import { bgPage } from 'src/styles/variables.const'; import PelicoSouriant from 'src/svg/pelico/pelico-souriant.svg'; diff --git a/src/pages/inscription.tsx b/src/pages/inscription.tsx index 144f65ac3..b27796b57 100644 --- a/src/pages/inscription.tsx +++ b/src/pages/inscription.tsx @@ -1,8 +1,9 @@ +import { useRouter } from 'next/router'; +import React, { useEffect, useRef, useState } from 'react'; + import Visibility from '@mui/icons-material/Visibility'; import VisibilityOff from '@mui/icons-material/VisibilityOff'; import { Box, Button, Checkbox, IconButton, InputAdornment, Link, TextField } from '@mui/material'; -import { useRouter } from 'next/router'; -import React, { useEffect, useRef, useState } from 'react'; import { KeepRatio } from '../components/KeepRatio'; import LanguageFilter from 'src/components/LanguageFilter'; diff --git a/src/pages/lancer-un-defi/1.tsx b/src/pages/lancer-un-defi/1.tsx index 9eae2cf62..f278a0fa2 100644 --- a/src/pages/lancer-un-defi/1.tsx +++ b/src/pages/lancer-un-defi/1.tsx @@ -1,7 +1,8 @@ -import { TextField } from '@mui/material'; import { useRouter } from 'next/router'; import React from 'react'; +import { TextField } from '@mui/material'; + import { isDefi } from 'src/activity-types/anyActivity'; import { DEFI, isFree } from 'src/activity-types/defi.constants'; import type { FreeDefiData } from 'src/activity-types/defi.types'; diff --git a/src/pages/lancer-un-defi/3.tsx b/src/pages/lancer-un-defi/3.tsx index 7f93063ba..50251decc 100644 --- a/src/pages/lancer-un-defi/3.tsx +++ b/src/pages/lancer-un-defi/3.tsx @@ -1,7 +1,8 @@ -import { TextField, Button } from '@mui/material'; import { useRouter } from 'next/router'; import React from 'react'; +import { TextField, Button } from '@mui/material'; + import { isDefi } from 'src/activity-types/anyActivity'; import { FREE_DEFIS, isFree } from 'src/activity-types/defi.constants'; import type { FreeDefiData } from 'src/activity-types/defi.types'; diff --git a/src/pages/lancer-un-defi/4.tsx b/src/pages/lancer-un-defi/4.tsx index 298ec0391..89e5c0fc1 100644 --- a/src/pages/lancer-un-defi/4.tsx +++ b/src/pages/lancer-un-defi/4.tsx @@ -1,12 +1,13 @@ -import { Tooltip } from '@mui/material'; -import Backdrop from '@mui/material/Backdrop'; -import Button from '@mui/material/Button'; -import CircularProgress from '@mui/material/CircularProgress'; import classNames from 'classnames'; import Link from 'next/link'; import { useRouter } from 'next/router'; import React from 'react'; +import { Tooltip } from '@mui/material'; +import Backdrop from '@mui/material/Backdrop'; +import Button from '@mui/material/Button'; +import CircularProgress from '@mui/material/CircularProgress'; + import { isDefi } from 'src/activity-types/anyActivity'; import { isFree, getDefi, DEFI } from 'src/activity-types/defi.constants'; import type { FreeDefiData } from 'src/activity-types/defi.types'; diff --git a/src/pages/lancer-un-defi/culinaire/1.tsx b/src/pages/lancer-un-defi/culinaire/1.tsx index f2ad6a93a..9bc5b3aa7 100644 --- a/src/pages/lancer-un-defi/culinaire/1.tsx +++ b/src/pages/lancer-un-defi/culinaire/1.tsx @@ -1,9 +1,10 @@ -import AddIcon from '@mui/icons-material/Add'; -import { ButtonBase, Grid, TextField } from '@mui/material'; import Image from 'next/image'; import { useRouter } from 'next/router'; import React from 'react'; +import AddIcon from '@mui/icons-material/Add'; +import { ButtonBase, Grid, TextField } from '@mui/material'; + import { isDefi } from 'src/activity-types/anyActivity'; import { DEFI, isCooking } from 'src/activity-types/defi.constants'; import type { CookingDefiData } from 'src/activity-types/defi.types'; diff --git a/src/pages/lancer-un-defi/culinaire/3.tsx b/src/pages/lancer-un-defi/culinaire/3.tsx index b8e79934c..96c515382 100644 --- a/src/pages/lancer-un-defi/culinaire/3.tsx +++ b/src/pages/lancer-un-defi/culinaire/3.tsx @@ -1,7 +1,8 @@ -import { TextField, Button } from '@mui/material'; import { useRouter } from 'next/router'; import React from 'react'; +import { TextField, Button } from '@mui/material'; + import { isDefi } from 'src/activity-types/anyActivity'; import { isCooking, COOKING_DEFIS } from 'src/activity-types/defi.constants'; import type { CookingDefiData } from 'src/activity-types/defi.types'; diff --git a/src/pages/lancer-un-defi/culinaire/4.tsx b/src/pages/lancer-un-defi/culinaire/4.tsx index 5ab223e31..5b88fcade 100644 --- a/src/pages/lancer-un-defi/culinaire/4.tsx +++ b/src/pages/lancer-un-defi/culinaire/4.tsx @@ -1,14 +1,15 @@ -import { Tooltip } from '@mui/material'; -import Backdrop from '@mui/material/Backdrop'; -import Button from '@mui/material/Button'; -import CircularProgress from '@mui/material/CircularProgress'; -import Grid from '@mui/material/Grid'; import classNames from 'classnames'; import Image from 'next/image'; import Link from 'next/link'; import { useRouter } from 'next/router'; import React from 'react'; +import { Tooltip } from '@mui/material'; +import Backdrop from '@mui/material/Backdrop'; +import Button from '@mui/material/Button'; +import CircularProgress from '@mui/material/CircularProgress'; +import Grid from '@mui/material/Grid'; + import { isDefi } from 'src/activity-types/anyActivity'; import { isCooking, getDefi, DEFI } from 'src/activity-types/defi.constants'; import type { CookingDefiData } from 'src/activity-types/defi.types'; diff --git a/src/pages/lancer-un-defi/ecologique/3.tsx b/src/pages/lancer-un-defi/ecologique/3.tsx index b0647e7fb..614b13c6c 100644 --- a/src/pages/lancer-un-defi/ecologique/3.tsx +++ b/src/pages/lancer-un-defi/ecologique/3.tsx @@ -1,7 +1,8 @@ -import { TextField, Button } from '@mui/material'; import { useRouter } from 'next/router'; import React from 'react'; +import { TextField, Button } from '@mui/material'; + import { isDefi } from 'src/activity-types/anyActivity'; import { isEco, ECO_DEFIS } from 'src/activity-types/defi.constants'; import type { EcoDefiData } from 'src/activity-types/defi.types'; diff --git a/src/pages/lancer-un-defi/ecologique/4.tsx b/src/pages/lancer-un-defi/ecologique/4.tsx index cf1a694a1..898acf422 100644 --- a/src/pages/lancer-un-defi/ecologique/4.tsx +++ b/src/pages/lancer-un-defi/ecologique/4.tsx @@ -1,12 +1,13 @@ -import { Tooltip } from '@mui/material'; -import Backdrop from '@mui/material/Backdrop'; -import Button from '@mui/material/Button'; -import CircularProgress from '@mui/material/CircularProgress'; import classNames from 'classnames'; import Link from 'next/link'; import { useRouter } from 'next/router'; import React from 'react'; +import { Tooltip } from '@mui/material'; +import Backdrop from '@mui/material/Backdrop'; +import Button from '@mui/material/Button'; +import CircularProgress from '@mui/material/CircularProgress'; + import { isDefi } from 'src/activity-types/anyActivity'; import { isEco, getDefi, ECO_ACTIONS, DEFI } from 'src/activity-types/defi.constants'; import type { EcoDefiData } from 'src/activity-types/defi.types'; diff --git a/src/pages/lancer-un-defi/linguistique/1.tsx b/src/pages/lancer-un-defi/linguistique/1.tsx index 6fc90eab5..8c1ced25e 100644 --- a/src/pages/lancer-un-defi/linguistique/1.tsx +++ b/src/pages/lancer-un-defi/linguistique/1.tsx @@ -1,8 +1,9 @@ -import { TextField, Autocomplete, FormControlLabel, Grid, Radio, RadioGroup, FormControl } from '@mui/material'; import { useRouter } from 'next/router'; import type { SyntheticEvent } from 'react'; import React from 'react'; +import { TextField, Autocomplete, FormControlLabel, Grid, Radio, RadioGroup, FormControl } from '@mui/material'; + import { isDefi } from 'src/activity-types/anyActivity'; import { DEFI, isLanguage, LANGUAGE_SCHOOL } from 'src/activity-types/defi.constants'; import type { LanguageDefiData } from 'src/activity-types/defi.types'; diff --git a/src/pages/lancer-un-defi/linguistique/2.tsx b/src/pages/lancer-un-defi/linguistique/2.tsx index ccca4aeba..01b8fd36d 100644 --- a/src/pages/lancer-un-defi/linguistique/2.tsx +++ b/src/pages/lancer-un-defi/linguistique/2.tsx @@ -1,7 +1,8 @@ -import { TextField, Button } from '@mui/material'; import { useRouter } from 'next/router'; import React from 'react'; +import { TextField, Button } from '@mui/material'; + import { isDefi } from 'src/activity-types/anyActivity'; import { isLanguage, LANGUAGE_THEMES } from 'src/activity-types/defi.constants'; import type { LanguageDefiData } from 'src/activity-types/defi.types'; diff --git a/src/pages/lancer-un-defi/linguistique/4.tsx b/src/pages/lancer-un-defi/linguistique/4.tsx index a23220305..a88749b87 100644 --- a/src/pages/lancer-un-defi/linguistique/4.tsx +++ b/src/pages/lancer-un-defi/linguistique/4.tsx @@ -1,7 +1,8 @@ -import { TextField, Button } from '@mui/material'; import { useRouter } from 'next/router'; import React from 'react'; +import { TextField, Button } from '@mui/material'; + import { isDefi } from 'src/activity-types/anyActivity'; import { isLanguage, LANGUAGE_DEFIS, LANGUAGE_THEMES } from 'src/activity-types/defi.constants'; import type { LanguageDefiData } from 'src/activity-types/defi.types'; diff --git a/src/pages/lancer-un-defi/linguistique/5.tsx b/src/pages/lancer-un-defi/linguistique/5.tsx index be421603c..6cbeb10a9 100644 --- a/src/pages/lancer-un-defi/linguistique/5.tsx +++ b/src/pages/lancer-un-defi/linguistique/5.tsx @@ -1,12 +1,13 @@ -import { Tooltip } from '@mui/material'; -import Backdrop from '@mui/material/Backdrop'; -import Button from '@mui/material/Button'; -import CircularProgress from '@mui/material/CircularProgress'; import classNames from 'classnames'; import Link from 'next/link'; import { useRouter } from 'next/router'; import React from 'react'; +import { Tooltip } from '@mui/material'; +import Backdrop from '@mui/material/Backdrop'; +import Button from '@mui/material/Button'; +import CircularProgress from '@mui/material/CircularProgress'; + import { isDefi } from 'src/activity-types/anyActivity'; import { isLanguage, getDefi, getLanguageTheme, DEFI, LANGUAGE_THEMES } from 'src/activity-types/defi.constants'; import type { LanguageDefiData } from 'src/activity-types/defi.types'; diff --git a/src/pages/lancer-un-defi/success.tsx b/src/pages/lancer-un-defi/success.tsx index f8f358f12..be76904b7 100644 --- a/src/pages/lancer-un-defi/success.tsx +++ b/src/pages/lancer-un-defi/success.tsx @@ -1,7 +1,8 @@ -import { Button } from '@mui/material'; import Link from 'next/link'; import React from 'react'; +import { Button } from '@mui/material'; + import { Base } from 'src/components/Base'; import { bgPage } from 'src/styles/variables.const'; import PelicoSouriant from 'src/svg/pelico/pelico-souriant.svg'; diff --git a/src/pages/mascotte/1.tsx b/src/pages/mascotte/1.tsx index 39a83c521..635786f78 100644 --- a/src/pages/mascotte/1.tsx +++ b/src/pages/mascotte/1.tsx @@ -1,7 +1,8 @@ -import { TextField, Box } from '@mui/material'; import { useRouter } from 'next/router'; import React from 'react'; +import { TextField, Box } from '@mui/material'; + import { isMascotte } from 'src/activity-types/anyActivity'; import { DEFAULT_MASCOTTE_DATA } from 'src/activity-types/mascotte.constants'; import type { MascotteData } from 'src/activity-types/mascotte.types'; diff --git a/src/pages/mascotte/2.tsx b/src/pages/mascotte/2.tsx index f29504803..7404ea702 100644 --- a/src/pages/mascotte/2.tsx +++ b/src/pages/mascotte/2.tsx @@ -1,7 +1,8 @@ -import { TextField, Grid, Box } from '@mui/material'; import { useRouter } from 'next/router'; import React from 'react'; +import { TextField, Grid, Box } from '@mui/material'; + import { isMascotte } from 'src/activity-types/anyActivity'; import type { MascotteData } from 'src/activity-types/mascotte.types'; import { Base } from 'src/components/Base'; diff --git a/src/pages/mascotte/3.tsx b/src/pages/mascotte/3.tsx index 8c6727f3f..f37a4014b 100644 --- a/src/pages/mascotte/3.tsx +++ b/src/pages/mascotte/3.tsx @@ -1,7 +1,8 @@ -import { Grid } from '@mui/material'; import { useRouter } from 'next/router'; import React from 'react'; +import { Grid } from '@mui/material'; + import { isMascotte } from 'src/activity-types/anyActivity'; import type { MascotteData } from 'src/activity-types/mascotte.types'; import { Base } from 'src/components/Base'; diff --git a/src/pages/mascotte/4.tsx b/src/pages/mascotte/4.tsx index b50601ec3..796d3c726 100644 --- a/src/pages/mascotte/4.tsx +++ b/src/pages/mascotte/4.tsx @@ -1,6 +1,7 @@ -import { Checkbox } from '@mui/material'; import React from 'react'; +import { Checkbox } from '@mui/material'; + import type { MascotteData } from 'src/activity-types/mascotte.types'; import { Base } from 'src/components/Base'; import { Steps } from 'src/components/Steps'; diff --git a/src/pages/mascotte/5.tsx b/src/pages/mascotte/5.tsx index 33b84633e..70c183b22 100644 --- a/src/pages/mascotte/5.tsx +++ b/src/pages/mascotte/5.tsx @@ -1,10 +1,11 @@ -import { Button, Grid, Backdrop, Box, Tooltip } from '@mui/material'; -import CircularProgress from '@mui/material/CircularProgress'; import classNames from 'classnames'; import { useRouter } from 'next/router'; import React from 'react'; import { useQueryClient } from 'react-query'; +import { Button, Grid, Backdrop, Box, Tooltip } from '@mui/material'; +import CircularProgress from '@mui/material/CircularProgress'; + import { isMascotte } from 'src/activity-types/anyActivity'; import { getMascotteContent } from 'src/activity-types/mascotte.constants'; import type { MascotteData } from 'src/activity-types/mascotte.types'; diff --git a/src/pages/mes-videos.tsx b/src/pages/mes-videos.tsx index cdc5b75df..2fc0e3e3a 100644 --- a/src/pages/mes-videos.tsx +++ b/src/pages/mes-videos.tsx @@ -1,3 +1,7 @@ +import { useSnackbar } from 'notistack'; +import React from 'react'; +import { useQueryClient } from 'react-query'; + import VisibilityIcon from '@mui/icons-material/Visibility'; import IconButton from '@mui/material/IconButton'; import Table from '@mui/material/Table'; @@ -6,9 +10,6 @@ import TableCell from '@mui/material/TableCell'; import TableHead from '@mui/material/TableHead'; import TableRow from '@mui/material/TableRow'; import Tooltip from '@mui/material/Tooltip'; -import { useSnackbar } from 'notistack'; -import React from 'react'; -import { useQueryClient } from 'react-query'; import { Base } from 'src/components/Base'; import { Modal } from 'src/components/Modal'; diff --git a/src/pages/mon-compte.tsx b/src/pages/mon-compte.tsx index 70a1e9507..36d742c0b 100644 --- a/src/pages/mon-compte.tsx +++ b/src/pages/mon-compte.tsx @@ -1,10 +1,11 @@ +import { useSnackbar } from 'notistack'; +import React from 'react'; + import { Alert, AlertTitle, Checkbox, Grid, TextField } from '@mui/material'; import Backdrop from '@mui/material/Backdrop'; import Button from '@mui/material/Button'; import CircularProgress from '@mui/material/CircularProgress'; import NoSsr from '@mui/material/NoSsr'; -import { useSnackbar } from 'notistack'; -import React from 'react'; import { AvatarImg } from 'src/components/Avatar'; import { Base } from 'src/components/Base'; diff --git a/src/pages/parametrer-hymne/1.tsx b/src/pages/parametrer-hymne/1.tsx index adadfcbfc..f1aaded22 100644 --- a/src/pages/parametrer-hymne/1.tsx +++ b/src/pages/parametrer-hymne/1.tsx @@ -1,8 +1,9 @@ +import { useRouter } from 'next/router'; +import React from 'react'; + import Backdrop from '@mui/material/Backdrop'; import Button from '@mui/material/Button'; import CircularProgress from '@mui/material/CircularProgress'; -import { useRouter } from 'next/router'; -import React from 'react'; import { DEFAULT_ANTHEM_DATA } from 'src/activity-types/anthem.constants'; import type { AnthemData } from 'src/activity-types/anthem.types'; diff --git a/src/pages/parametrer-hymne/2.tsx b/src/pages/parametrer-hymne/2.tsx index f31ab8c0c..fe1db5978 100644 --- a/src/pages/parametrer-hymne/2.tsx +++ b/src/pages/parametrer-hymne/2.tsx @@ -1,8 +1,9 @@ +import { useRouter } from 'next/router'; +import React from 'react'; + import Backdrop from '@mui/material/Backdrop'; import Button from '@mui/material/Button'; import CircularProgress from '@mui/material/CircularProgress'; -import { useRouter } from 'next/router'; -import React from 'react'; import type { AnthemData } from 'src/activity-types/anthem.types'; import { Base } from 'src/components/Base'; diff --git a/src/pages/parametrer-hymne/3.tsx b/src/pages/parametrer-hymne/3.tsx index 6c93ba8f3..93643b7d7 100644 --- a/src/pages/parametrer-hymne/3.tsx +++ b/src/pages/parametrer-hymne/3.tsx @@ -1,7 +1,8 @@ -import { ButtonBase, Card } from '@mui/material'; import { useRouter } from 'next/router'; import React from 'react'; +import { ButtonBase, Card } from '@mui/material'; + import type { AnthemData } from 'src/activity-types/anthem.types'; import { isAnthem } from 'src/activity-types/anyActivity'; import { Base } from 'src/components/Base'; diff --git a/src/pages/parametrer-hymne/4.tsx b/src/pages/parametrer-hymne/4.tsx index 7bcb645d7..c7a1d4a49 100644 --- a/src/pages/parametrer-hymne/4.tsx +++ b/src/pages/parametrer-hymne/4.tsx @@ -1,7 +1,8 @@ -import { ButtonBase, Card } from '@mui/material'; import { useRouter } from 'next/router'; import React from 'react'; +import { ButtonBase, Card } from '@mui/material'; + import type { AnthemData, Syllable } from 'src/activity-types/anthem.types'; import { isAnthem } from 'src/activity-types/anyActivity'; import { Base } from 'src/components/Base'; diff --git a/src/pages/parametrer-hymne/5.tsx b/src/pages/parametrer-hymne/5.tsx index a97bd38a8..6935f9bdd 100644 --- a/src/pages/parametrer-hymne/5.tsx +++ b/src/pages/parametrer-hymne/5.tsx @@ -1,11 +1,12 @@ -import Backdrop from '@mui/material/Backdrop'; -import Button from '@mui/material/Button'; -import CircularProgress from '@mui/material/CircularProgress'; import classNames from 'classnames'; import Link from 'next/link'; import { useRouter } from 'next/router'; import React from 'react'; +import Backdrop from '@mui/material/Backdrop'; +import Button from '@mui/material/Button'; +import CircularProgress from '@mui/material/CircularProgress'; + import type { AnthemData } from 'src/activity-types/anthem.types'; import { isAnthem } from 'src/activity-types/anyActivity'; import { Base } from 'src/components/Base'; diff --git a/src/pages/parametrer-hymne/success.tsx b/src/pages/parametrer-hymne/success.tsx index f82c5b64b..55656ed89 100644 --- a/src/pages/parametrer-hymne/success.tsx +++ b/src/pages/parametrer-hymne/success.tsx @@ -1,7 +1,8 @@ -import { Button } from '@mui/material'; import Link from 'next/link'; import React from 'react'; +import { Button } from '@mui/material'; + import { Base } from 'src/components/Base'; import { bgPage } from 'src/styles/variables.const'; import PelicoSouriant from 'src/svg/pelico/pelico-souriant.svg'; diff --git a/src/pages/pelico-profil.tsx b/src/pages/pelico-profil.tsx index f46a2505f..1f55d25de 100644 --- a/src/pages/pelico-profil.tsx +++ b/src/pages/pelico-profil.tsx @@ -1,6 +1,7 @@ -import { Box } from '@mui/material'; import React from 'react'; +import { Box } from '@mui/material'; + import { Base } from 'src/components/Base'; import { PelicoProfilNavigation } from 'src/components/accueil/PelicoProfilNavigation'; import { UserContext } from 'src/contexts/userContext'; diff --git a/src/pages/poser-une-question/1.tsx b/src/pages/poser-une-question/1.tsx index 8da254445..0acad5115 100644 --- a/src/pages/poser-une-question/1.tsx +++ b/src/pages/poser-une-question/1.tsx @@ -1,7 +1,8 @@ -import { Button } from '@mui/material'; import { useRouter } from 'next/router'; import React from 'react'; +import { Button } from '@mui/material'; + import { isQuestion } from 'src/activity-types/anyActivity'; import { AvatarImg } from 'src/components/Avatar'; import { Base } from 'src/components/Base'; diff --git a/src/pages/poser-une-question/2.tsx b/src/pages/poser-une-question/2.tsx index 483ab9f7f..410dc6b45 100644 --- a/src/pages/poser-une-question/2.tsx +++ b/src/pages/poser-une-question/2.tsx @@ -1,8 +1,9 @@ -import AddIcon from '@mui/icons-material/Add'; -import { ButtonBase, TextField, Card } from '@mui/material'; import { useRouter } from 'next/router'; import React from 'react'; +import AddIcon from '@mui/icons-material/Add'; +import { ButtonBase, TextField, Card } from '@mui/material'; + import { isQuestion } from 'src/activity-types/anyActivity'; import { Base } from 'src/components/Base'; import { Steps } from 'src/components/Steps'; diff --git a/src/pages/poser-une-question/3.tsx b/src/pages/poser-une-question/3.tsx index 66fb06106..4df746587 100644 --- a/src/pages/poser-une-question/3.tsx +++ b/src/pages/poser-une-question/3.tsx @@ -1,13 +1,14 @@ -import { Tooltip } from '@mui/material'; -import Backdrop from '@mui/material/Backdrop'; -import Button from '@mui/material/Button'; -import CircularProgress from '@mui/material/CircularProgress'; import classNames from 'classnames'; import Link from 'next/link'; import { useRouter } from 'next/router'; import React from 'react'; import { useQueryClient } from 'react-query'; +import { Tooltip } from '@mui/material'; +import Backdrop from '@mui/material/Backdrop'; +import Button from '@mui/material/Button'; +import CircularProgress from '@mui/material/CircularProgress'; + import { isQuestion } from 'src/activity-types/anyActivity'; import type { QuestionActivity } from 'src/activity-types/question.types'; import { Base } from 'src/components/Base'; diff --git a/src/pages/poser-une-question/success.tsx b/src/pages/poser-une-question/success.tsx index 71f40cff7..7c829876d 100644 --- a/src/pages/poser-une-question/success.tsx +++ b/src/pages/poser-une-question/success.tsx @@ -1,8 +1,9 @@ -import { Button } from '@mui/material'; import Link from 'next/link'; import { useRouter } from 'next/router'; import React from 'react'; +import { Button } from '@mui/material'; + import { Base } from 'src/components/Base'; import { ActivityContext } from 'src/contexts/activityContext'; import { bgPage } from 'src/styles/variables.const'; diff --git a/src/pages/re-inventer-une-histoire/1.tsx b/src/pages/re-inventer-une-histoire/1.tsx index c5ba4fc08..5518ddbb5 100644 --- a/src/pages/re-inventer-une-histoire/1.tsx +++ b/src/pages/re-inventer-une-histoire/1.tsx @@ -1,9 +1,10 @@ -import AddIcon from '@mui/icons-material/Add'; -import { Grid, ButtonBase, FormControl, FormHelperText, InputLabel, MenuItem, Select } from '@mui/material'; import Image from 'next/image'; import { useRouter } from 'next/router'; import React from 'react'; +import AddIcon from '@mui/icons-material/Add'; +import { Grid, ButtonBase, FormControl, FormHelperText, InputLabel, MenuItem, Select } from '@mui/material'; + import { isStory } from 'src/activity-types/anyActivity'; import { ODD_CHOICE } from 'src/activity-types/story.constants'; import { Base } from 'src/components/Base'; diff --git a/src/pages/re-inventer-une-histoire/2.tsx b/src/pages/re-inventer-une-histoire/2.tsx index d6e799369..7f51d15cc 100644 --- a/src/pages/re-inventer-une-histoire/2.tsx +++ b/src/pages/re-inventer-une-histoire/2.tsx @@ -1,9 +1,10 @@ -import AddIcon from '@mui/icons-material/Add'; -import { TextField, Grid, ButtonBase } from '@mui/material'; import Image from 'next/image'; import { useRouter } from 'next/router'; import React from 'react'; +import AddIcon from '@mui/icons-material/Add'; +import { TextField, Grid, ButtonBase } from '@mui/material'; + import { isStory } from 'src/activity-types/anyActivity'; import { Base } from 'src/components/Base'; import { KeepRatio } from 'src/components/KeepRatio'; diff --git a/src/pages/re-inventer-une-histoire/3.tsx b/src/pages/re-inventer-une-histoire/3.tsx index 7a6ca7b36..931adc0e2 100644 --- a/src/pages/re-inventer-une-histoire/3.tsx +++ b/src/pages/re-inventer-une-histoire/3.tsx @@ -1,9 +1,10 @@ -import AddIcon from '@mui/icons-material/Add'; -import { TextField, Grid, ButtonBase } from '@mui/material'; import Image from 'next/image'; import { useRouter } from 'next/router'; import React from 'react'; +import AddIcon from '@mui/icons-material/Add'; +import { TextField, Grid, ButtonBase } from '@mui/material'; + import { isStory } from 'src/activity-types/anyActivity'; import { Base } from 'src/components/Base'; import { KeepRatio } from 'src/components/KeepRatio'; diff --git a/src/pages/re-inventer-une-histoire/4.tsx b/src/pages/re-inventer-une-histoire/4.tsx index dbf0213b9..9cf08fe2a 100644 --- a/src/pages/re-inventer-une-histoire/4.tsx +++ b/src/pages/re-inventer-une-histoire/4.tsx @@ -1,9 +1,10 @@ -import AddIcon from '@mui/icons-material/Add'; -import { TextField, Grid, ButtonBase } from '@mui/material'; import Image from 'next/image'; import { useRouter } from 'next/router'; import React from 'react'; +import AddIcon from '@mui/icons-material/Add'; +import { TextField, Grid, ButtonBase } from '@mui/material'; + import { isStory } from 'src/activity-types/anyActivity'; import { Base } from 'src/components/Base'; import { KeepRatio } from 'src/components/KeepRatio'; diff --git a/src/pages/re-inventer-une-histoire/5.tsx b/src/pages/re-inventer-une-histoire/5.tsx index 39d778bf9..e69121268 100644 --- a/src/pages/re-inventer-une-histoire/5.tsx +++ b/src/pages/re-inventer-une-histoire/5.tsx @@ -1,8 +1,9 @@ -import { Tooltip, Button, Backdrop, CircularProgress } from '@mui/material'; import Link from 'next/link'; import { useRouter } from 'next/router'; import React from 'react'; +import { Tooltip, Button, Backdrop, CircularProgress } from '@mui/material'; + import { isStory } from 'src/activity-types/anyActivity'; import { Base } from 'src/components/Base'; import { ImageStepContainer } from 'src/components/FinalStep/ImageStepContainer'; diff --git a/src/pages/re-inventer-une-histoire/success.tsx b/src/pages/re-inventer-une-histoire/success.tsx index f742fe488..b602c3cf8 100644 --- a/src/pages/re-inventer-une-histoire/success.tsx +++ b/src/pages/re-inventer-une-histoire/success.tsx @@ -1,7 +1,8 @@ -import { Button } from '@mui/material'; import Link from 'next/link'; import React from 'react'; +import { Button } from '@mui/material'; + import { Base } from 'src/components/Base'; import { bgPage } from 'src/styles/variables.const'; import PelicoSouriant from 'src/svg/pelico/pelico-souriant.svg'; diff --git a/src/pages/reagir-a-une-activite/3.tsx b/src/pages/reagir-a-une-activite/3.tsx index 0e0f762c6..aba75f391 100644 --- a/src/pages/reagir-a-une-activite/3.tsx +++ b/src/pages/reagir-a-une-activite/3.tsx @@ -1,12 +1,13 @@ -import { Tooltip } from '@mui/material'; -import Backdrop from '@mui/material/Backdrop'; -import Button from '@mui/material/Button'; -import CircularProgress from '@mui/material/CircularProgress'; import classNames from 'classnames'; import Link from 'next/link'; import { useRouter } from 'next/router'; import React from 'react'; +import { Tooltip } from '@mui/material'; +import Backdrop from '@mui/material/Backdrop'; +import Button from '@mui/material/Button'; +import CircularProgress from '@mui/material/CircularProgress'; + import { isReaction } from 'src/activity-types/anyActivity'; import { Base } from 'src/components/Base'; import { Steps } from 'src/components/Steps'; diff --git a/src/pages/reagir-a-une-activite/success.tsx b/src/pages/reagir-a-une-activite/success.tsx index 90021cb32..b7aee8c2c 100644 --- a/src/pages/reagir-a-une-activite/success.tsx +++ b/src/pages/reagir-a-une-activite/success.tsx @@ -1,7 +1,8 @@ -import { Button } from '@mui/material'; import Link from 'next/link'; import React from 'react'; +import { Button } from '@mui/material'; + import { Base } from 'src/components/Base'; import { bgPage } from 'src/styles/variables.const'; import PelicoSouriant from 'src/svg/pelico/pelico-souriant.svg'; diff --git a/src/pages/realiser-un-reportage/1.tsx b/src/pages/realiser-un-reportage/1.tsx index bfa698bcc..9e5263624 100644 --- a/src/pages/realiser-un-reportage/1.tsx +++ b/src/pages/realiser-un-reportage/1.tsx @@ -1,7 +1,8 @@ -import { TextField } from '@mui/material'; import { useRouter } from 'next/router'; import React from 'react'; +import { TextField } from '@mui/material'; + import { getReportage } from 'src/activity-types/reportage.constants'; import type { ReportageData } from 'src/activity-types/reportage.types'; import { Base } from 'src/components/Base'; diff --git a/src/pages/realiser-un-reportage/3.tsx b/src/pages/realiser-un-reportage/3.tsx index 12ce08a3f..1346a8b6d 100644 --- a/src/pages/realiser-un-reportage/3.tsx +++ b/src/pages/realiser-un-reportage/3.tsx @@ -1,12 +1,13 @@ -import { Tooltip } from '@mui/material'; -import Backdrop from '@mui/material/Backdrop'; -import Button from '@mui/material/Button'; -import CircularProgress from '@mui/material/CircularProgress'; import classNames from 'classnames'; import Link from 'next/link'; import { useRouter } from 'next/router'; import React from 'react'; +import { Tooltip } from '@mui/material'; +import Backdrop from '@mui/material/Backdrop'; +import Button from '@mui/material/Button'; +import CircularProgress from '@mui/material/CircularProgress'; + import { isReportage } from 'src/activity-types/anyActivity'; import { getReportage } from 'src/activity-types/reportage.constants'; import type { ReportageData } from 'src/activity-types/reportage.types'; diff --git a/src/pages/realiser-un-reportage/success.tsx b/src/pages/realiser-un-reportage/success.tsx index 8946c4cb2..1a9855c2f 100644 --- a/src/pages/realiser-un-reportage/success.tsx +++ b/src/pages/realiser-un-reportage/success.tsx @@ -1,7 +1,8 @@ -import { Button } from '@mui/material'; import Link from 'next/link'; import React from 'react'; +import { Button } from '@mui/material'; + import { Base } from 'src/components/Base'; import { bgPage } from 'src/styles/variables.const'; import PelicoSouriant from 'src/svg/pelico/pelico-souriant.svg'; diff --git a/src/pages/reset-password.tsx b/src/pages/reset-password.tsx index 67426704f..f42807df7 100644 --- a/src/pages/reset-password.tsx +++ b/src/pages/reset-password.tsx @@ -1,7 +1,8 @@ -import { Button, Link, TextField, Typography, Backdrop, CircularProgress } from '@mui/material'; import { useRouter } from 'next/router'; import React from 'react'; +import { Button, Link, TextField, Typography, Backdrop, CircularProgress } from '@mui/material'; + import { KeepRatio } from 'src/components/KeepRatio'; import ArrowBack from 'src/svg/arrow_back.svg'; import Logo from 'src/svg/logo_1village_famille.svg'; diff --git a/src/pages/se-presenter/success.tsx b/src/pages/se-presenter/success.tsx index 26e650fd4..d26963992 100644 --- a/src/pages/se-presenter/success.tsx +++ b/src/pages/se-presenter/success.tsx @@ -1,7 +1,8 @@ -import { Button } from '@mui/material'; import Link from 'next/link'; import React from 'react'; +import { Button } from '@mui/material'; + import { isMascotte } from 'src/activity-types/anyActivity'; import { Base } from 'src/components/Base'; import { ActivityContext } from 'src/contexts/activityContext'; diff --git a/src/pages/se-presenter/thematique/4.tsx b/src/pages/se-presenter/thematique/4.tsx index 1efd1dad9..8c2e7e1e5 100644 --- a/src/pages/se-presenter/thematique/4.tsx +++ b/src/pages/se-presenter/thematique/4.tsx @@ -1,10 +1,11 @@ +import Link from 'next/link'; +import { useRouter } from 'next/router'; +import React from 'react'; + import { Tooltip } from '@mui/material'; import Backdrop from '@mui/material/Backdrop'; import Button from '@mui/material/Button'; import CircularProgress from '@mui/material/CircularProgress'; -import Link from 'next/link'; -import { useRouter } from 'next/router'; -import React from 'react'; import { isPresentation } from 'src/activity-types/anyActivity'; import { PRESENTATION_THEMATIQUE } from 'src/activity-types/presentation.constants'; diff --git a/src/pages/symbole/1.tsx b/src/pages/symbole/1.tsx index 83b387609..c3250d441 100644 --- a/src/pages/symbole/1.tsx +++ b/src/pages/symbole/1.tsx @@ -1,7 +1,8 @@ -import { TextField } from '@mui/material'; import { useRouter } from 'next/router'; import React from 'react'; +import { TextField } from '@mui/material'; + import { getSymbol } from 'src/activity-types/symbol.constants'; import type { SymbolData } from 'src/activity-types/symbol.types'; import { Base } from 'src/components/Base'; diff --git a/src/pages/symbole/3.tsx b/src/pages/symbole/3.tsx index c7e77f8fd..4d7835b32 100644 --- a/src/pages/symbole/3.tsx +++ b/src/pages/symbole/3.tsx @@ -1,12 +1,13 @@ -import { Tooltip } from '@mui/material'; -import Backdrop from '@mui/material/Backdrop'; -import Button from '@mui/material/Button'; -import CircularProgress from '@mui/material/CircularProgress'; import classNames from 'classnames'; import Link from 'next/link'; import { useRouter } from 'next/router'; import React from 'react'; +import { Tooltip } from '@mui/material'; +import Backdrop from '@mui/material/Backdrop'; +import Button from '@mui/material/Button'; +import CircularProgress from '@mui/material/CircularProgress'; + import { isSymbol } from 'src/activity-types/anyActivity'; import { getSymbol } from 'src/activity-types/symbol.constants'; import type { SymbolData } from 'src/activity-types/symbol.types'; diff --git a/src/pages/symbole/success.tsx b/src/pages/symbole/success.tsx index baa3245a4..abff8617b 100644 --- a/src/pages/symbole/success.tsx +++ b/src/pages/symbole/success.tsx @@ -1,7 +1,8 @@ -import { Button } from '@mui/material'; import Link from 'next/link'; import React from 'react'; +import { Button } from '@mui/material'; + import { Base } from 'src/components/Base'; import { bgPage } from 'src/styles/variables.const'; import PelicoSouriant from 'src/svg/pelico/pelico-souriant.svg'; diff --git a/src/pages/update-password.tsx b/src/pages/update-password.tsx index 27ef0e542..ac0e04d32 100644 --- a/src/pages/update-password.tsx +++ b/src/pages/update-password.tsx @@ -1,8 +1,9 @@ +import { useRouter } from 'next/router'; +import React, { useEffect, useRef, useState } from 'react'; + import Visibility from '@mui/icons-material/Visibility'; import VisibilityOff from '@mui/icons-material/VisibilityOff'; import { Button, IconButton, InputAdornment, Link, TextField } from '@mui/material'; -import { useRouter } from 'next/router'; -import React, { useEffect, useRef, useState } from 'react'; import { KeepRatio } from '../components/KeepRatio'; import { useUserRequests } from 'src/services/useUsers'; diff --git a/src/pages/user-verified.tsx b/src/pages/user-verified.tsx index 64533b41f..50fb56c43 100644 --- a/src/pages/user-verified.tsx +++ b/src/pages/user-verified.tsx @@ -1,7 +1,8 @@ -import { Link } from '@mui/material'; import { useRouter } from 'next/router'; import React, { useContext, useEffect, useRef } from 'react'; +import { Link } from '@mui/material'; + import { KeepRatio } from 'src/components/KeepRatio'; import { UserContext } from 'src/contexts/userContext'; import { useUserRequests } from 'src/services/useUsers'; diff --git a/src/services/useActivities.ts b/src/services/useActivities.ts index 23a60176d..e1f8ed19f 100644 --- a/src/services/useActivities.ts +++ b/src/services/useActivities.ts @@ -36,20 +36,14 @@ export const useActivities = ({ pelico, countries = [], userId, type, ...args }: const userClassroomData = (await getUserVisibilityFamilyParams(user)) as [Classroom]; - // console.log('userClassroomData ===', userClassroomData); - // console.log('userClassroomDataUserId===', userClassroomData[0].user?.id); - // console.log('userClassroomDataDelayedDats ===', userClassroomData[0].delayedDays); - const isFamily = user.type === UserType.FAMILY; - // console.log('family conditions', isFamily); - const query: { [key: string]: string | number | boolean | undefined; } = { ...args, type: Array.isArray(type) ? type.join(',') : type, - villageId: villageId !== null ? (user.villageId !== null ? user.villageId : undefined) : undefined, + villageId: user.villageId !== null ? user.villageId : villageId !== null ? villageId : undefined, countries: countries.join(','), pelico: pelico ? 'true' : 'false', delayedDays: isFamily ? userClassroomData[0]?.delayedDays : undefined,