From fcb91e71f5cc087100449accc5bc2b407f36f71d Mon Sep 17 00:00:00 2001 From: Anthony Le Courric Date: Mon, 17 Jul 2023 12:38:20 +0200 Subject: [PATCH] =?UTF-8?q?=F0=9F=9A=A8(eslint)=20sort=20module=20names?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit We were sorting the import path but not the module names. We added a new rule to sort the module names as well. It is a automatic fixable rule. --- src/frontend/apps/lti_site/.eslintrc.js | 6 ---- .../src/api/useConfig/index.ts | 2 +- .../src/api/useOrganizations/index.ts | 4 +-- .../src/components/Layout/MainLayout.spec.tsx | 2 +- .../src/components/Spinner/ContentSpinner.tsx | 2 +- .../src/features/App/AppConfig.spec.tsx | 2 +- .../Authentication/api/basicLogin/index.ts | 4 +-- .../Authentication/api/getUserData/index.ts | 2 +- .../api/usePasswordReset/index.ts | 2 +- .../api/usePasswordResetConfirm/index.ts | 2 +- .../api/validateChallenge/index.ts | 2 +- .../validateClassroomInviteToken/index.tsx | 2 +- .../components/BaseAuthenticationPage.tsx | 2 +- .../Authentication/components/LoginForm.tsx | 2 +- .../components/PasswordResetConfirmForm.tsx | 2 +- .../components/PasswordResetForm.tsx | 2 +- .../components/RenaterAuthenticator.tsx | 8 ++--- .../ContentsFilter/ContentsFilter.tsx | 2 +- .../ManageAPIState/ManageAPIState.tsx | 2 +- .../components/Update/ClassRoomUpdate.tsx | 2 +- .../Contents/features/ClassRoom/routes.tsx | 2 +- .../features/Live/components/Read/Lives.tsx | 2 +- .../Contents/features/Live/routes.tsx | 2 +- .../features/Video/components/Read/Videos.tsx | 2 +- .../Contents/features/Video/routes.tsx | 2 +- .../Contents/features/featureLoader.tsx | 6 ++-- .../Contents/hooks/useContentRoutes.tsx | 2 +- .../src/features/Footer/components/Footer.tsx | 2 +- .../HomePage/components/HomePage.spec.tsx | 2 +- .../features/HomePage/components/HomePage.tsx | 2 +- .../Menu/components/Burger/Burger.spec.tsx | 2 +- .../src/features/PagesApi/api/usePageApi.ts | 4 +-- .../src/features/PagesApi/api/usePagesApi.ts | 2 +- .../Playlist/api/useCreatePlaylist/index.ts | 4 +-- .../Playlist/api/useDeletePlaylist/index.ts | 4 +-- .../Playlist/api/usePlaylists/index.ts | 4 +-- .../Playlist/components/PlaylistPage.tsx | 2 +- .../api/useCreatePlaylistAccess/index.ts | 4 +-- .../api/useDeletePlaylistAccess/index.ts | 2 +- .../UpdatePlaylist/api/usePlaylist/index.ts | 4 +-- .../api/usePlaylistAccess/index.ts | 4 +-- .../api/useSearchUsers/index.ts | 4 +-- .../api/useUpdatePlaylist/index.ts | 4 +-- .../api/useUpdatePlaylistAccess/index.ts | 2 +- .../components/AddUserAccessForm.tsx | 2 +- .../UpdatePlaylist/components/UserListRow.tsx | 2 +- .../components/UserRoleOptions.spec.tsx | 2 +- .../components/UserRoleOptions.tsx | 2 +- .../api/useLtiUserAssociations.ts | 2 +- .../api/usePortabilityRequests.ts | 8 ++--- .../components/PortabilityRequests.spec.tsx | 2 +- .../components/PortabilityRequests.tsx | 2 +- .../standalone_site/src/routes/routes.tsx | 2 +- .../packages/eslint-config-marsha/index.js | 6 ++++ .../ClassroomWidgetProvider/index.tsx | 2 +- .../widgets/Description/index.tsx | 2 +- .../widgets/Recordings/Recording/index.tsx | 2 +- .../widgets/Scheduling/index.tsx | 2 +- .../UploadDocuments/DocumentRow/index.tsx | 8 ++--- .../UploadDocuments/index.spec.tsx | 6 ++-- .../SupportSharing/UploadDocuments/index.tsx | 8 ++--- .../components/DashboardClassroom/index.tsx | 14 ++++---- .../DashboardClassroomAskUsername/index.tsx | 2 +- .../DashboardClassroomError/index.tsx | 2 +- .../DashboardClassroomInfos/index.tsx | 2 +- .../index.spec.tsx | 2 +- .../DashboardClassroomInstructor/index.tsx | 4 +-- .../DashboardClassroomLayout/index.tsx | 2 +- .../src/data/queries/index.spec.tsx | 10 +++--- .../lib_classroom/src/data/queries/index.tsx | 34 +++++++++---------- .../createClassroomDocument/index.ts | 4 +-- .../src/data/sideEffects/createVOD/index.ts | 2 +- .../src/types/ClassroomAppData.ts | 2 +- .../src/utils/tests/factories.ts | 4 +-- .../lib_common/src/BreadCrumbsProvider.tsx | 2 +- .../src/common/Button/index.spec.tsx | 2 +- .../src/common/Card/ClosingCard/index.tsx | 2 +- .../src/common/Card/ContentCard/index.tsx | 10 +++--- .../BoundaryScreenError/index.tsx | 4 +-- .../lib_components/src/common/Form/index.tsx | 2 +- .../lib_components/src/common/Modal/Modal.tsx | 2 +- .../common/ObjectStatusPicker/index.spec.tsx | 2 +- .../src/common/ObjectStatusPicker/index.tsx | 4 +-- .../UploadField/DropzonePlaceholder.tsx | 2 +- .../src/common/UploadManager/index.spec.tsx | 2 +- .../WidgetsContainer/InfoModal/index.tsx | 2 +- .../common/WidgetsContainer/index.spec.tsx | 2 +- .../src/common/queries/fetchOne.tsx | 2 +- .../src/common/queries/metadata.tsx | 2 +- .../src/data/stores/useAppConfig/index.tsx | 2 +- .../src/data/stores/useMarkdownImage/index.ts | 2 +- .../src/data/stores/useSentry/index.spec.ts | 2 +- .../src/data/stores/useSentry/index.ts | 2 +- .../src/data/stores/useVideo/index.tsx | 2 +- .../src/hooks/useResponsive/index.spec.tsx | 2 +- .../src/types/apps/classroom/models.ts | 2 +- .../lib_components/src/types/stores.ts | 4 +-- .../src/utils/XAPI/index.spec.ts | 2 +- .../useServiceWorkerRefreshToken/index.tsx | 2 +- .../src/utils/tests/factories.ts | 6 ++-- .../src/components/CodeMirrorEditor/index.tsx | 10 +++--- .../components/MarkdownEditor/index.spec.tsx | 6 ++-- .../components/MarkdownViewer/index.spec.tsx | 2 +- .../src/components/MdxRenderer/index.tsx | 4 +-- .../MdxRenderer/remarkLatexPlugin.tsx | 2 +- .../remarkLocallyHostedImagePlugin.tsx | 2 +- .../useImageUploadManager/index.spec.tsx | 4 +-- .../useImageUploadManager/index.tsx | 2 +- .../lib_markdown/src/data/queries/index.tsx | 10 +++--- .../sideEffects/createMarkdownImage/index.ts | 4 +-- .../lib_markdown/src/utils/tests/factories.ts | 4 +-- .../packages/lib_tests/src/imageSnapshot.tsx | 2 +- .../packages/lib_tests/src/render.tsx | 8 ++--- .../packages/lib_tests/src/wrapper.tsx | 2 +- .../src/api/createLiveSession/index.ts | 4 +-- .../src/api/createSharedLiveMedia/index.ts | 4 +-- .../src/api/createThumbnail/index.ts | 6 ++-- .../api/createTimedTextTrack/index.spec.ts | 2 +- .../src/api/createTimedTextTrack/index.ts | 8 ++--- .../src/api/harvestLive/index.spec.tsx | 2 +- .../lib_video/src/api/harvestLive/index.tsx | 2 +- .../src/api/initiateLive/index.spec.ts | 4 +-- .../lib_video/src/api/initiateLive/index.ts | 4 +-- .../src/api/navigateSharingDoc/index.ts | 2 +- .../src/api/publishLiveToVod/index.ts | 2 +- .../src/api/pushAttendance/index.spec.ts | 2 +- .../lib_video/src/api/pushAttendance/index.ts | 4 +-- .../setLiveSessionDisplayName/index.spec.ts | 2 +- .../api/setLiveSessionDisplayName/index.ts | 4 +-- .../lib_video/src/api/stopLive/index.spec.ts | 2 +- .../lib_video/src/api/stopLive/index.tsx | 2 +- .../api/updateLiveParticipants/index.spec.tsx | 2 +- .../src/api/updateLiveParticipants/index.tsx | 4 +-- .../src/api/updateLiveSession/index.spec.ts | 2 +- .../src/api/updateLiveSession/index.ts | 4 +-- .../src/api/useCreateVideo/index.tsx | 8 ++--- .../src/api/useDeleteSharedLiveMedia/index.ts | 4 +-- .../src/api/useDeleteThumbnail/index.ts | 4 +-- .../src/api/useDeleteTimedTextTrack/index.ts | 4 +-- .../src/api/useDeleteVideo/index.spec.tsx | 2 +- .../lib_video/src/api/useDeleteVideo/index.ts | 4 +-- .../src/api/useDeleteVideos/index.spec.tsx | 2 +- .../src/api/useDeleteVideos/index.tsx | 2 +- .../src/api/useLiveAttendances/index.ts | 4 +-- .../src/api/useLiveSessions/index.ts | 4 +-- .../src/api/usePairingVideo/index.ts | 2 +- .../src/api/useStartLiveRecording/index.ts | 2 +- .../src/api/useStartSharingMedia/index.ts | 4 +-- .../src/api/useStopLiveRecording/index.ts | 2 +- .../src/api/useStopSharingMedia/index.ts | 4 +-- .../src/api/useThumbnailMetadata/index.ts | 2 +- .../src/api/useTimedTextMetadata/index.ts | 2 +- .../api/useTranscriptReaderRequest/index.ts | 2 +- .../src/api/useUpdateSharedLiveMedia/index.ts | 2 +- .../lib_video/src/api/useUpdateVideo/index.ts | 4 +-- .../src/api/useVideoMetadata/index.ts | 2 +- .../lib_video/src/api/useVideos/index.tsx | 6 ++-- .../DashboardLiveTabAttendance/index.spec.tsx | 4 +-- .../DashboardControlPane/index.spec.tsx | 4 +-- .../common/DashboardControlPane/index.tsx | 2 +- .../DashboardVideoWrapper/index.spec.tsx | 2 +- .../common/DashboardVideoWrapper/index.tsx | 2 +- .../common/PictureInPictureLayer/index.tsx | 2 +- .../usePIPDragger/index.tsx | 2 +- .../common/Player/createPlayer.spec.ts | 2 +- .../components/common/Player/createPlayer.ts | 2 +- .../Player/createVideojsPlayer.spec.tsx | 10 +++--- .../common/Player/createVideojsPlayer.ts | 14 ++++---- .../videojs/qualitySelectorPlugin/index.ts | 2 +- .../common/VideoInfoBar/index.spec.tsx | 2 +- .../components/common/VideoInfoBar/index.tsx | 2 +- .../DisplayNameForm/index.spec.tsx | 2 +- .../components/common/VideoLayout/index.tsx | 2 +- .../common/VideoPlayer/index.spec.tsx | 10 +++--- .../VideoWebSocketInitializer/index.tsx | 4 +-- .../TimedTextTrackItem/index.tsx | 4 +-- .../common/VideoWidgetProvider/index.tsx | 2 +- .../widgets/DescriptionWidget/index.tsx | 6 ++-- .../widgets/DownloadVideo/index.tsx | 6 ++-- .../widgets/LiveJoinMode/index.tsx | 2 +- .../LivePairingButton/index.spec.tsx | 4 +-- .../LivePairing/LivePairingButton/index.tsx | 4 +-- .../SchedulingAndDescription/index.tsx | 8 ++--- .../SharedLiveMediaItem/index.tsx | 6 ++-- .../widgets/SharedLiveMedia/index.tsx | 8 ++--- .../widgets/ToolsAndApplications/index.tsx | 2 +- .../TranscriptReader/index.spec.tsx | 2 +- .../Transcripts/TranscriptReader/index.tsx | 2 +- .../widgets/Transcripts/index.tsx | 6 ++-- .../widgets/UploadClosedCaptions/index.tsx | 2 +- .../widgets/UploadSubtitles/index.tsx | 2 +- .../widgets/UploadTranscripts/index.tsx | 2 +- .../widgets/UploadVideo/index.tsx | 8 ++--- .../widgets/VODCreation/PublishVOD/index.tsx | 2 +- .../widgets/VODCreation/index.spec.tsx | 4 +-- .../widgets/VODCreation/index.tsx | 2 +- .../widgets/VODCreation/utils.spec.ts | 2 +- .../widgets/VODCreation/utils.ts | 2 +- .../VisibilityAndInteraction/index.tsx | 4 +-- .../ThumbnailManager/index.spec.tsx | 2 +- .../ThumbnailManager/index.tsx | 2 +- .../ThumbnailManager/utils/utils.spec.tsx | 2 +- .../ThumbnailManager/utils/utils.ts | 2 +- .../ThumbnailRemoveButton/index.tsx | 6 ++-- .../widgets/WidgetThumbnail/index.tsx | 16 ++++----- .../SharedLiveMediaModalWrapper/index.tsx | 2 +- .../wrappers/TimedTrackModalWrapper/index.tsx | 2 +- .../ConfigureLiveButton/index.spec.tsx | 4 +-- .../VideoWizard/ConfigureLiveButton/index.tsx | 2 +- .../UploadVideoRetry/index.tsx | 2 +- .../CreateVOD/UploadVideoForm/index.tsx | 2 +- .../common/VideoWizard/CreateVOD/index.tsx | 10 +++--- .../StudentLiveDescription/index.tsx | 2 +- .../RegistrationForm/index.tsx | 6 ++-- .../StudentLiveRegistration/index.tsx | 2 +- .../StudentLiveAdvertising/index.spec.tsx | 10 +++--- .../StudentLiveAdvertising/index.tsx | 6 ++-- .../StudentLiveWaitingRoom/index.tsx | 2 +- .../StudentJoinDiscussionButton/index.tsx | 2 +- .../StudentLiveControlBar/index.spec.tsx | 4 +-- .../index.spec.tsx | 4 +-- .../TeacherLiveControlBar/index.spec.tsx | 2 +- .../index.spec.tsx | 2 +- .../index.spec.tsx | 2 +- .../TeacherLiveContent/index.spec.tsx | 2 +- .../MainContent/TeacherLiveContent/index.tsx | 2 +- .../Wrapper/OnStageRequestToast/index.tsx | 2 +- .../TeacherLiveTypeSwitch/index.spec.tsx | 2 +- .../Wrapper/TeacherLiveTypeSwitch/index.tsx | 4 +-- .../components/live/Teacher/Wrapper/index.tsx | 8 ++--- .../common/Chat/ChatMessage/index.spec.tsx | 2 +- .../live/common/Chat/index.spec.tsx | 4 +-- .../common/ConverseInitializer/index.spec.tsx | 4 +-- .../live/common/ConverseInitializer/index.tsx | 2 +- .../common/DashboardLiveJitsi/index.spec.tsx | 4 +-- .../live/common/DashboardLiveJitsi/index.tsx | 2 +- .../common/DashboardLiveJitsi/utils.spec.ts | 4 +-- .../common/DashboardLiveRaw/index.spec.tsx | 2 +- .../live/common/DashboardLiveRaw/index.tsx | 4 +-- .../StudentHideAppsButton/index.spec.tsx | 2 +- .../StudentShowAppsButton/index.spec.tsx | 2 +- .../StudentHideChatButton/index.spec.tsx | 2 +- .../StudentShowChatButton/index.spec.tsx | 2 +- .../StudentHideViewersButton/index.spec.tsx | 2 +- .../StudentShowViewersButton/index.spec.tsx | 2 +- .../ViewersWrapper/index.spec.tsx | 2 +- .../LiveVideoTabPanel/index.tsx | 4 +-- .../live/common/LiveVideoPanel/index.spec.tsx | 2 +- .../live/common/LiveVideoPanel/index.tsx | 6 ++-- .../live/common/ViewersList/utils.spec.ts | 2 +- .../live/common/ViewersList/utils.ts | 2 +- .../components/vod/Student/Dashboard.spec.tsx | 16 ++++----- .../src/components/vod/Student/Dashboard.tsx | 2 +- .../VideoFromLiveDashboard/index.spec.tsx | 2 +- .../src/components/vod/Teacher/Dashboard.tsx | 8 ++--- .../src/hooks/useChatItemsStore/index.spec.ts | 2 +- .../useDeleteSharedLiveMediaModal/index.ts | 2 +- .../index.ts | 2 +- .../lib_video/src/hooks/useJitsiApi/index.ts | 2 +- .../src/hooks/useSetVideoState/index.spec.tsx | 12 +++---- .../src/hooks/useVideoStats/index.tsx | 4 +-- .../lib_video/src/types/VideoPlayer.ts | 2 +- .../handler.spec.ts | 8 ++--- .../marshaJoinDiscussionPlugin/handler.ts | 2 +- .../marshaJoinDiscussionPlugin/index.ts | 6 ++-- .../src/utils/conversejs/converse.spec.ts | 2 +- .../lib_video/src/utils/localstorage.ts | 2 +- .../src/utils/onStageRequestMessage.ts | 2 +- .../src/utils/onStageRequestMessages.spec.ts | 2 +- .../packages/lib_video/src/utils/websocket.ts | 2 +- 270 files changed, 479 insertions(+), 479 deletions(-) diff --git a/src/frontend/apps/lti_site/.eslintrc.js b/src/frontend/apps/lti_site/.eslintrc.js index 0c7efe25b5..ce249cce89 100644 --- a/src/frontend/apps/lti_site/.eslintrc.js +++ b/src/frontend/apps/lti_site/.eslintrc.js @@ -9,12 +9,6 @@ module.exports = { { files: ['*.ts', '*.tsx'], rules: { - 'sort-imports': [ - 'error', - { - ignoreDeclarationSort: true, - }, - ], 'import/order': [ 'error', { diff --git a/src/frontend/apps/standalone_site/src/api/useConfig/index.ts b/src/frontend/apps/standalone_site/src/api/useConfig/index.ts index 428f8f1382..5df6319778 100644 --- a/src/frontend/apps/standalone_site/src/api/useConfig/index.ts +++ b/src/frontend/apps/standalone_site/src/api/useConfig/index.ts @@ -4,7 +4,7 @@ import { fetchResponseHandler, fetchWrapper, } from 'lib-components'; -import { useQuery, UseQueryOptions } from 'react-query'; +import { UseQueryOptions, useQuery } from 'react-query'; export interface ConfigResponse { p2p: { diff --git a/src/frontend/apps/standalone_site/src/api/useOrganizations/index.ts b/src/frontend/apps/standalone_site/src/api/useOrganizations/index.ts index 09706f95e8..bad666881f 100644 --- a/src/frontend/apps/standalone_site/src/api/useOrganizations/index.ts +++ b/src/frontend/apps/standalone_site/src/api/useOrganizations/index.ts @@ -1,10 +1,10 @@ import { APIList, - fetchList, FetchListQueryKey, Organization, + fetchList, } from 'lib-components'; -import { useQuery, UseQueryOptions } from 'react-query'; +import { UseQueryOptions, useQuery } from 'react-query'; type OrganizationsResponse = APIList; type UseOrganizationsParams = { diff --git a/src/frontend/apps/standalone_site/src/components/Layout/MainLayout.spec.tsx b/src/frontend/apps/standalone_site/src/components/Layout/MainLayout.spec.tsx index 38352472ed..ba46ad7261 100644 --- a/src/frontend/apps/standalone_site/src/components/Layout/MainLayout.spec.tsx +++ b/src/frontend/apps/standalone_site/src/components/Layout/MainLayout.spec.tsx @@ -1,6 +1,6 @@ import { render, screen } from '@testing-library/react'; import { Nullable } from 'lib-common'; -import { forwardRef, Fragment } from 'react'; +import { Fragment, forwardRef } from 'react'; import MainLayout from './MainLayout'; diff --git a/src/frontend/apps/standalone_site/src/components/Spinner/ContentSpinner.tsx b/src/frontend/apps/standalone_site/src/components/Spinner/ContentSpinner.tsx index d1c8600293..cee5cf1df1 100644 --- a/src/frontend/apps/standalone_site/src/components/Spinner/ContentSpinner.tsx +++ b/src/frontend/apps/standalone_site/src/components/Spinner/ContentSpinner.tsx @@ -1,4 +1,4 @@ -import { Box, Spinner, BoxProps, SpinnerProps } from 'grommet'; +import { Box, BoxProps, Spinner, SpinnerProps } from 'grommet'; export const ContentSpinner = ({ boxProps, diff --git a/src/frontend/apps/standalone_site/src/features/App/AppConfig.spec.tsx b/src/frontend/apps/standalone_site/src/features/App/AppConfig.spec.tsx index d937e392ce..7a92dc76e2 100644 --- a/src/frontend/apps/standalone_site/src/features/App/AppConfig.spec.tsx +++ b/src/frontend/apps/standalone_site/src/features/App/AppConfig.spec.tsx @@ -1,4 +1,4 @@ -import { waitFor, screen, act } from '@testing-library/react'; +import { act, screen, waitFor } from '@testing-library/react'; import fetchMock from 'fetch-mock'; import { useP2PConfig, useSentry } from 'lib-components'; import { Deferred, render } from 'lib-tests'; diff --git a/src/frontend/apps/standalone_site/src/features/Authentication/api/basicLogin/index.ts b/src/frontend/apps/standalone_site/src/features/Authentication/api/basicLogin/index.ts index 3a87602bd7..1f64dc8218 100644 --- a/src/frontend/apps/standalone_site/src/features/Authentication/api/basicLogin/index.ts +++ b/src/frontend/apps/standalone_site/src/features/Authentication/api/basicLogin/index.ts @@ -1,5 +1,5 @@ -import { fetchWrapper, useJwt, TokenResponse } from 'lib-components'; -import { useMutation, UseMutationOptions } from 'react-query'; +import { TokenResponse, fetchWrapper, useJwt } from 'lib-components'; +import { UseMutationOptions, useMutation } from 'react-query'; type UseBasicLoginData = { username: string; diff --git a/src/frontend/apps/standalone_site/src/features/Authentication/api/getUserData/index.ts b/src/frontend/apps/standalone_site/src/features/Authentication/api/getUserData/index.ts index 98022cbdfa..110ca9bbe3 100644 --- a/src/frontend/apps/standalone_site/src/features/Authentication/api/getUserData/index.ts +++ b/src/frontend/apps/standalone_site/src/features/Authentication/api/getUserData/index.ts @@ -1,4 +1,4 @@ -import { AnonymousUser, fetchWrapper, User } from 'lib-components'; +import { AnonymousUser, User, fetchWrapper } from 'lib-components'; const isPresentWithType = (value: unknown, type: 'string' | 'boolean') => { return value !== null && value !== undefined && typeof value === type; diff --git a/src/frontend/apps/standalone_site/src/features/Authentication/api/usePasswordReset/index.ts b/src/frontend/apps/standalone_site/src/features/Authentication/api/usePasswordReset/index.ts index 35a55d4518..b8ddece43e 100644 --- a/src/frontend/apps/standalone_site/src/features/Authentication/api/usePasswordReset/index.ts +++ b/src/frontend/apps/standalone_site/src/features/Authentication/api/usePasswordReset/index.ts @@ -1,5 +1,5 @@ import { fetchWrapper } from 'lib-components'; -import { useMutation, UseMutationOptions } from 'react-query'; +import { UseMutationOptions, useMutation } from 'react-query'; type UsePasswordResetData = { email: string; diff --git a/src/frontend/apps/standalone_site/src/features/Authentication/api/usePasswordResetConfirm/index.ts b/src/frontend/apps/standalone_site/src/features/Authentication/api/usePasswordResetConfirm/index.ts index c327adfc66..66b2086097 100644 --- a/src/frontend/apps/standalone_site/src/features/Authentication/api/usePasswordResetConfirm/index.ts +++ b/src/frontend/apps/standalone_site/src/features/Authentication/api/usePasswordResetConfirm/index.ts @@ -1,5 +1,5 @@ import { fetchWrapper } from 'lib-components'; -import { useMutation, UseMutationOptions } from 'react-query'; +import { UseMutationOptions, useMutation } from 'react-query'; type UsePasswordResetConfirmData = { uid: string; diff --git a/src/frontend/apps/standalone_site/src/features/Authentication/api/validateChallenge/index.ts b/src/frontend/apps/standalone_site/src/features/Authentication/api/validateChallenge/index.ts index a949e886bb..ea2c0b7fd1 100644 --- a/src/frontend/apps/standalone_site/src/features/Authentication/api/validateChallenge/index.ts +++ b/src/frontend/apps/standalone_site/src/features/Authentication/api/validateChallenge/index.ts @@ -1,7 +1,7 @@ import { + TokenResponse, fetchResponseHandler, fetchWrapper, - TokenResponse, } from 'lib-components'; const isValidateChallenge = (response: unknown): response is TokenResponse => { diff --git a/src/frontend/apps/standalone_site/src/features/Authentication/api/validateClassroomInviteToken/index.tsx b/src/frontend/apps/standalone_site/src/features/Authentication/api/validateClassroomInviteToken/index.tsx index 60286df43d..bc76cd7066 100644 --- a/src/frontend/apps/standalone_site/src/features/Authentication/api/validateClassroomInviteToken/index.tsx +++ b/src/frontend/apps/standalone_site/src/features/Authentication/api/validateClassroomInviteToken/index.tsx @@ -1,7 +1,7 @@ import { + TokenResponse, fetchResponseHandler, fetchWrapper, - TokenResponse, } from 'lib-components'; export interface IValidateClassroomInvite { diff --git a/src/frontend/apps/standalone_site/src/features/Authentication/components/BaseAuthenticationPage.tsx b/src/frontend/apps/standalone_site/src/features/Authentication/components/BaseAuthenticationPage.tsx index 4f8692fa2f..b8ad4e0ab1 100644 --- a/src/frontend/apps/standalone_site/src/features/Authentication/components/BaseAuthenticationPage.tsx +++ b/src/frontend/apps/standalone_site/src/features/Authentication/components/BaseAuthenticationPage.tsx @@ -1,7 +1,7 @@ import { Box } from 'grommet'; import { useResponsive } from 'lib-components'; import React, { Fragment, PropsWithChildren, useEffect, useState } from 'react'; -import { useIntl, defineMessages } from 'react-intl'; +import { defineMessages, useIntl } from 'react-intl'; import imageLeft from 'assets/img/telescope.png'; import { ReactComponent as LogoIcon } from 'assets/svg/logo_marsha.svg'; diff --git a/src/frontend/apps/standalone_site/src/features/Authentication/components/LoginForm.tsx b/src/frontend/apps/standalone_site/src/features/Authentication/components/LoginForm.tsx index 3c3f9e5cca..37f33bb645 100644 --- a/src/frontend/apps/standalone_site/src/features/Authentication/components/LoginForm.tsx +++ b/src/frontend/apps/standalone_site/src/features/Authentication/components/LoginForm.tsx @@ -8,7 +8,7 @@ import { Link, useLocation, useNavigate } from 'react-router-dom'; import { routes } from 'routes/routes'; import { getLocalStorage } from 'utils/browser'; -import { useBasicLogin, UseBasicLoginError } from '../api/basicLogin'; +import { UseBasicLoginError, useBasicLogin } from '../api/basicLogin'; const messages = defineMessages({ labelSubmit: { diff --git a/src/frontend/apps/standalone_site/src/features/Authentication/components/PasswordResetConfirmForm.tsx b/src/frontend/apps/standalone_site/src/features/Authentication/components/PasswordResetConfirmForm.tsx index f6be116831..7fbd050838 100644 --- a/src/frontend/apps/standalone_site/src/features/Authentication/components/PasswordResetConfirmForm.tsx +++ b/src/frontend/apps/standalone_site/src/features/Authentication/components/PasswordResetConfirmForm.tsx @@ -6,8 +6,8 @@ import { defineMessages, useIntl } from 'react-intl'; import { useNavigate } from 'react-router-dom'; import { - usePasswordResetConfirm, UsePasswordResetConfirmError, + usePasswordResetConfirm, } from '../api/usePasswordResetConfirm'; const messages = defineMessages({ diff --git a/src/frontend/apps/standalone_site/src/features/Authentication/components/PasswordResetForm.tsx b/src/frontend/apps/standalone_site/src/features/Authentication/components/PasswordResetForm.tsx index 32432232d9..553eca17d7 100644 --- a/src/frontend/apps/standalone_site/src/features/Authentication/components/PasswordResetForm.tsx +++ b/src/frontend/apps/standalone_site/src/features/Authentication/components/PasswordResetForm.tsx @@ -8,8 +8,8 @@ import { useNavigate } from 'react-router-dom'; import { routes } from 'routes'; import { - usePasswordReset, UsePasswordResetError, + usePasswordReset, } from '../api/usePasswordReset'; const messages = defineMessages({ diff --git a/src/frontend/apps/standalone_site/src/features/Authentication/components/RenaterAuthenticator.tsx b/src/frontend/apps/standalone_site/src/features/Authentication/components/RenaterAuthenticator.tsx index 83b9f4cbd1..c10952b54e 100644 --- a/src/frontend/apps/standalone_site/src/features/Authentication/components/RenaterAuthenticator.tsx +++ b/src/frontend/apps/standalone_site/src/features/Authentication/components/RenaterAuthenticator.tsx @@ -1,12 +1,12 @@ import { Box, FormField, Image, Text, ThemeContext } from 'grommet'; -import { useResponsive, Select, ClosingCard } from 'lib-components'; -import { Fragment, useEffect, useState, useMemo } from 'react'; -import { useIntl, defineMessages } from 'react-intl'; +import { ClosingCard, Select, useResponsive } from 'lib-components'; +import { Fragment, useEffect, useMemo, useState } from 'react'; +import { defineMessages, useIntl } from 'react-intl'; import { useLocation } from 'react-router-dom'; import { - getRenaterFerIdpList, RenaterSamlFerIdp, + getRenaterFerIdpList, } from '../api/getRenaterFerIdpList'; const messages = defineMessages({ diff --git a/src/frontend/apps/standalone_site/src/features/Contents/components/ContentsFilter/ContentsFilter.tsx b/src/frontend/apps/standalone_site/src/features/Contents/components/ContentsFilter/ContentsFilter.tsx index 8ffa4c8609..839131fd8f 100644 --- a/src/frontend/apps/standalone_site/src/features/Contents/components/ContentsFilter/ContentsFilter.tsx +++ b/src/frontend/apps/standalone_site/src/features/Contents/components/ContentsFilter/ContentsFilter.tsx @@ -1,4 +1,4 @@ -import { Text, Button, Box } from 'grommet'; +import { Box, Button, Text } from 'grommet'; import { Filter } from 'grommet-icons'; import { Breakpoints } from 'lib-common'; import { Playlist, useResponsive } from 'lib-components'; diff --git a/src/frontend/apps/standalone_site/src/features/Contents/components/ManageAPIState/ManageAPIState.tsx b/src/frontend/apps/standalone_site/src/features/Contents/components/ManageAPIState/ManageAPIState.tsx index 0900519a38..3c827d6efd 100644 --- a/src/frontend/apps/standalone_site/src/features/Contents/components/ManageAPIState/ManageAPIState.tsx +++ b/src/frontend/apps/standalone_site/src/features/Contents/components/ManageAPIState/ManageAPIState.tsx @@ -1,4 +1,4 @@ -import { Text, Box } from 'grommet'; +import { Box, Text } from 'grommet'; import { Alert } from 'grommet-icons'; import { Fragment, PropsWithChildren, ReactElement } from 'react'; import { defineMessages, useIntl } from 'react-intl'; diff --git a/src/frontend/apps/standalone_site/src/features/Contents/features/ClassRoom/components/Update/ClassRoomUpdate.tsx b/src/frontend/apps/standalone_site/src/features/Contents/features/ClassRoom/components/Update/ClassRoomUpdate.tsx index c303a058b6..b4146e257c 100644 --- a/src/frontend/apps/standalone_site/src/features/Contents/features/ClassRoom/components/Update/ClassRoomUpdate.tsx +++ b/src/frontend/apps/standalone_site/src/features/Contents/features/ClassRoom/components/Update/ClassRoomUpdate.tsx @@ -4,9 +4,9 @@ import { AppConfig, AppConfigProvider, CurrentResourceContextProvider, + ResourceContext, isDecodedJwtLTI, isDecodedJwtWeb, - ResourceContext, useCurrentResourceContext, useJwt, useResponsive, diff --git a/src/frontend/apps/standalone_site/src/features/Contents/features/ClassRoom/routes.tsx b/src/frontend/apps/standalone_site/src/features/Contents/features/ClassRoom/routes.tsx index 5a747123ff..b0eac75eae 100644 --- a/src/frontend/apps/standalone_site/src/features/Contents/features/ClassRoom/routes.tsx +++ b/src/frontend/apps/standalone_site/src/features/Contents/features/ClassRoom/routes.tsx @@ -1,4 +1,4 @@ -import { defineMessages, FormattedMessage } from 'react-intl'; +import { FormattedMessage, defineMessages } from 'react-intl'; import { ReactComponent as ClassroomsIcon } from 'assets/svg/iko_webinairesvg.svg'; import { LoadSVG } from 'components/Assets'; diff --git a/src/frontend/apps/standalone_site/src/features/Contents/features/Live/components/Read/Lives.tsx b/src/frontend/apps/standalone_site/src/features/Contents/features/Live/components/Read/Lives.tsx index 05d3b519ff..30caa944db 100644 --- a/src/frontend/apps/standalone_site/src/features/Contents/features/Live/components/Read/Lives.tsx +++ b/src/frontend/apps/standalone_site/src/features/Contents/features/Live/components/Read/Lives.tsx @@ -1,4 +1,4 @@ -import { useVideos, VideosOrderType } from 'lib-video'; +import { VideosOrderType, useVideos } from 'lib-video'; import { useState } from 'react'; import { defineMessages, useIntl } from 'react-intl'; diff --git a/src/frontend/apps/standalone_site/src/features/Contents/features/Live/routes.tsx b/src/frontend/apps/standalone_site/src/features/Contents/features/Live/routes.tsx index 7593c689d9..cabbf57949 100644 --- a/src/frontend/apps/standalone_site/src/features/Contents/features/Live/routes.tsx +++ b/src/frontend/apps/standalone_site/src/features/Contents/features/Live/routes.tsx @@ -1,4 +1,4 @@ -import { defineMessages, FormattedMessage } from 'react-intl'; +import { FormattedMessage, defineMessages } from 'react-intl'; import { ReactComponent as LiveIcon } from 'assets/svg/iko_live.svg'; import { LoadSVG } from 'components/Assets'; diff --git a/src/frontend/apps/standalone_site/src/features/Contents/features/Video/components/Read/Videos.tsx b/src/frontend/apps/standalone_site/src/features/Contents/features/Video/components/Read/Videos.tsx index e0ec1ef882..3b490ce3e4 100644 --- a/src/frontend/apps/standalone_site/src/features/Contents/features/Video/components/Read/Videos.tsx +++ b/src/frontend/apps/standalone_site/src/features/Contents/features/Video/components/Read/Videos.tsx @@ -1,4 +1,4 @@ -import { useVideos, VideosOrderType } from 'lib-video'; +import { VideosOrderType, useVideos } from 'lib-video'; import { useState } from 'react'; import { defineMessages, useIntl } from 'react-intl'; diff --git a/src/frontend/apps/standalone_site/src/features/Contents/features/Video/routes.tsx b/src/frontend/apps/standalone_site/src/features/Contents/features/Video/routes.tsx index aaea4aa7b6..909ad6bc62 100644 --- a/src/frontend/apps/standalone_site/src/features/Contents/features/Video/routes.tsx +++ b/src/frontend/apps/standalone_site/src/features/Contents/features/Video/routes.tsx @@ -1,4 +1,4 @@ -import { defineMessages, FormattedMessage } from 'react-intl'; +import { FormattedMessage, defineMessages } from 'react-intl'; import { ReactComponent as VideoIcon } from 'assets/svg/iko_next.svg'; import { LoadSVG } from 'components/Assets'; diff --git a/src/frontend/apps/standalone_site/src/features/Contents/features/featureLoader.tsx b/src/frontend/apps/standalone_site/src/features/Contents/features/featureLoader.tsx index 8ed215eaf2..f0471d7f0f 100644 --- a/src/frontend/apps/standalone_site/src/features/Contents/features/featureLoader.tsx +++ b/src/frontend/apps/standalone_site/src/features/Contents/features/featureLoader.tsx @@ -11,13 +11,13 @@ import { Fragment } from 'react'; import { FeatureSample, useContentFeatures } from '../store/contentsStore'; import { - classRoomContents, ClassRoomRouter, ClassRoomShuffle, + classRoomContents, routesClassRoom, } from './ClassRoom'; -import { liveContents, LiveRouter, routesLive } from './Live'; -import { videoContents, VideoRouter, routesVideo } from './Video'; +import { LiveRouter, liveContents, routesLive } from './Live'; +import { VideoRouter, routesVideo, videoContents } from './Video'; enum RESOURCES_CHOICES { VIDEO = 'video', diff --git a/src/frontend/apps/standalone_site/src/features/Contents/hooks/useContentRoutes.tsx b/src/frontend/apps/standalone_site/src/features/Contents/hooks/useContentRoutes.tsx index 9e8644c971..6893402288 100644 --- a/src/frontend/apps/standalone_site/src/features/Contents/hooks/useContentRoutes.tsx +++ b/src/frontend/apps/standalone_site/src/features/Contents/hooks/useContentRoutes.tsx @@ -1,4 +1,4 @@ -import { defineMessages, FormattedMessage } from 'react-intl'; +import { FormattedMessage, defineMessages } from 'react-intl'; import { ReactComponent as VueListIcon } from 'assets/svg/iko_vuelistesvg.svg'; import { LoadSVG } from 'components/Assets'; diff --git a/src/frontend/apps/standalone_site/src/features/Footer/components/Footer.tsx b/src/frontend/apps/standalone_site/src/features/Footer/components/Footer.tsx index b1fffe5c0e..e8b4879e38 100644 --- a/src/frontend/apps/standalone_site/src/features/Footer/components/Footer.tsx +++ b/src/frontend/apps/standalone_site/src/features/Footer/components/Footer.tsx @@ -1,5 +1,5 @@ import { Box, Text } from 'grommet'; -import { Twitter, Facebook, Mail, Linkedin, Github } from 'grommet-icons'; +import { Facebook, Github, Linkedin, Mail, Twitter } from 'grommet-icons'; import { Breakpoints } from 'lib-common'; import { StyledLink, useResponsive } from 'lib-components'; diff --git a/src/frontend/apps/standalone_site/src/features/HomePage/components/HomePage.spec.tsx b/src/frontend/apps/standalone_site/src/features/HomePage/components/HomePage.spec.tsx index 6e7a54bcfe..7e92daee21 100644 --- a/src/frontend/apps/standalone_site/src/features/HomePage/components/HomePage.spec.tsx +++ b/src/frontend/apps/standalone_site/src/features/HomePage/components/HomePage.spec.tsx @@ -1,4 +1,4 @@ -import { screen, act } from '@testing-library/react'; +import { act, screen } from '@testing-library/react'; import { render } from 'lib-tests'; import React from 'react'; import ReactTestUtils from 'react-dom/test-utils'; diff --git a/src/frontend/apps/standalone_site/src/features/HomePage/components/HomePage.tsx b/src/frontend/apps/standalone_site/src/features/HomePage/components/HomePage.tsx index cf07192fa5..b871517683 100644 --- a/src/frontend/apps/standalone_site/src/features/HomePage/components/HomePage.tsx +++ b/src/frontend/apps/standalone_site/src/features/HomePage/components/HomePage.tsx @@ -1,4 +1,4 @@ -import { Image, Box, Text, Heading } from 'grommet'; +import { Box, Heading, Image, Text } from 'grommet'; import { StyledLink, useResponsive } from 'lib-components'; import React, { useState } from 'react'; import { defineMessages, useIntl } from 'react-intl'; diff --git a/src/frontend/apps/standalone_site/src/features/Menu/components/Burger/Burger.spec.tsx b/src/frontend/apps/standalone_site/src/features/Menu/components/Burger/Burger.spec.tsx index 387f3fc470..92564e6e96 100644 --- a/src/frontend/apps/standalone_site/src/features/Menu/components/Burger/Burger.spec.tsx +++ b/src/frontend/apps/standalone_site/src/features/Menu/components/Burger/Burger.spec.tsx @@ -1,4 +1,4 @@ -import { render, fireEvent, screen } from '@testing-library/react'; +import { fireEvent, render, screen } from '@testing-library/react'; import React from 'react'; import Burger from './Burger'; diff --git a/src/frontend/apps/standalone_site/src/features/PagesApi/api/usePageApi.ts b/src/frontend/apps/standalone_site/src/features/PagesApi/api/usePageApi.ts index 291d541b12..fa0ca7bc47 100644 --- a/src/frontend/apps/standalone_site/src/features/PagesApi/api/usePageApi.ts +++ b/src/frontend/apps/standalone_site/src/features/PagesApi/api/usePageApi.ts @@ -1,5 +1,5 @@ -import { fetchOne, FetchResponseError } from 'lib-components'; -import { useQuery, UseQueryOptions } from 'react-query'; +import { FetchResponseError, fetchOne } from 'lib-components'; +import { UseQueryOptions, useQuery } from 'react-query'; export interface PageResponse { slug: string; diff --git a/src/frontend/apps/standalone_site/src/features/PagesApi/api/usePagesApi.ts b/src/frontend/apps/standalone_site/src/features/PagesApi/api/usePagesApi.ts index 802e2e87ff..72424a6798 100644 --- a/src/frontend/apps/standalone_site/src/features/PagesApi/api/usePagesApi.ts +++ b/src/frontend/apps/standalone_site/src/features/PagesApi/api/usePagesApi.ts @@ -4,7 +4,7 @@ import { FetchResponseError, fetchResponseHandler, } from 'lib-components'; -import { useQuery, UseQueryOptions } from 'react-query'; +import { UseQueryOptions, useQuery } from 'react-query'; export interface PagesApi { slug: string; diff --git a/src/frontend/apps/standalone_site/src/features/Playlist/api/useCreatePlaylist/index.ts b/src/frontend/apps/standalone_site/src/features/Playlist/api/useCreatePlaylist/index.ts index 4c6bb836b0..eb90456590 100644 --- a/src/frontend/apps/standalone_site/src/features/Playlist/api/useCreatePlaylist/index.ts +++ b/src/frontend/apps/standalone_site/src/features/Playlist/api/useCreatePlaylist/index.ts @@ -1,5 +1,5 @@ -import { createOne, Playlist } from 'lib-components'; -import { useMutation, UseMutationOptions, useQueryClient } from 'react-query'; +import { Playlist, createOne } from 'lib-components'; +import { UseMutationOptions, useMutation, useQueryClient } from 'react-query'; type UseCreatePlaylistData = { organization: string; diff --git a/src/frontend/apps/standalone_site/src/features/Playlist/api/useDeletePlaylist/index.ts b/src/frontend/apps/standalone_site/src/features/Playlist/api/useDeletePlaylist/index.ts index 4aad798353..e1d6447d77 100644 --- a/src/frontend/apps/standalone_site/src/features/Playlist/api/useDeletePlaylist/index.ts +++ b/src/frontend/apps/standalone_site/src/features/Playlist/api/useDeletePlaylist/index.ts @@ -1,6 +1,6 @@ import { Maybe } from 'lib-common'; -import { deleteOne, FetchResponseError, Playlist } from 'lib-components'; -import { useMutation, UseMutationOptions, useQueryClient } from 'react-query'; +import { FetchResponseError, Playlist, deleteOne } from 'lib-components'; +import { UseMutationOptions, useMutation, useQueryClient } from 'react-query'; type UseDeletePlaylistData = string; type UseDeletePlaylistError = FetchResponseError; diff --git a/src/frontend/apps/standalone_site/src/features/Playlist/api/usePlaylists/index.ts b/src/frontend/apps/standalone_site/src/features/Playlist/api/usePlaylists/index.ts index 2fc3ec9644..4a1561c12d 100644 --- a/src/frontend/apps/standalone_site/src/features/Playlist/api/usePlaylists/index.ts +++ b/src/frontend/apps/standalone_site/src/features/Playlist/api/usePlaylists/index.ts @@ -1,11 +1,11 @@ import { APIList, - fetchList, FetchListQueryKey, FetchResponseError, Playlist, + fetchList, } from 'lib-components'; -import { useQuery, UseQueryOptions } from 'react-query'; +import { UseQueryOptions, useQuery } from 'react-query'; export enum PlaylistOrderType { BY_CREATED_ON = 'created_on', diff --git a/src/frontend/apps/standalone_site/src/features/Playlist/components/PlaylistPage.tsx b/src/frontend/apps/standalone_site/src/features/Playlist/components/PlaylistPage.tsx index c6780439bd..475d3f3b31 100644 --- a/src/frontend/apps/standalone_site/src/features/Playlist/components/PlaylistPage.tsx +++ b/src/frontend/apps/standalone_site/src/features/Playlist/components/PlaylistPage.tsx @@ -6,7 +6,7 @@ import { Route, Routes, useNavigate } from 'react-router-dom'; import { ReactComponent as CheckListIcon } from 'assets/svg/iko_checklistsvg.svg'; import { WhiteCard } from 'components/Cards'; -import { commonSortMessages, SortableTable } from 'components/SortableTable'; +import { SortableTable, commonSortMessages } from 'components/SortableTable'; import { ITEM_PER_PAGE } from 'conf/global'; import { routes } from 'routes'; diff --git a/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/api/useCreatePlaylistAccess/index.ts b/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/api/useCreatePlaylistAccess/index.ts index 69b27b2772..608b76cd23 100644 --- a/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/api/useCreatePlaylistAccess/index.ts +++ b/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/api/useCreatePlaylistAccess/index.ts @@ -1,5 +1,5 @@ -import { createOne, FetchResponseError } from 'lib-components'; -import { useMutation, UseMutationOptions, useQueryClient } from 'react-query'; +import { FetchResponseError, createOne } from 'lib-components'; +import { UseMutationOptions, useMutation, useQueryClient } from 'react-query'; import { PlaylistAccess, PlaylistRole } from '../../types/playlistAccess'; diff --git a/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/api/useDeletePlaylistAccess/index.ts b/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/api/useDeletePlaylistAccess/index.ts index b24dba24ca..e3f91922fe 100644 --- a/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/api/useDeletePlaylistAccess/index.ts +++ b/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/api/useDeletePlaylistAccess/index.ts @@ -1,5 +1,5 @@ import { deleteOne } from 'lib-components'; -import { useMutation, UseMutationOptions, useQueryClient } from 'react-query'; +import { UseMutationOptions, useMutation, useQueryClient } from 'react-query'; type UseDeletePlaylistAccessData = string; type UseDeletePlaylistAccessError = { code: 'exception' }; diff --git a/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/api/usePlaylist/index.ts b/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/api/usePlaylist/index.ts index 325c786072..80341be33a 100644 --- a/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/api/usePlaylist/index.ts +++ b/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/api/usePlaylist/index.ts @@ -1,5 +1,5 @@ -import { fetchOne, Playlist } from 'lib-components'; -import { useQuery, UseQueryOptions } from 'react-query'; +import { Playlist, fetchOne } from 'lib-components'; +import { UseQueryOptions, useQuery } from 'react-query'; export const usePlaylist = ( id: string, diff --git a/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/api/usePlaylistAccess/index.ts b/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/api/usePlaylistAccess/index.ts index adfa3e0f48..b680aa2a5a 100644 --- a/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/api/usePlaylistAccess/index.ts +++ b/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/api/usePlaylistAccess/index.ts @@ -1,5 +1,5 @@ -import { APIList, fetchList, FetchListQueryKey } from 'lib-components'; -import { useQuery, UseQueryOptions } from 'react-query'; +import { APIList, FetchListQueryKey, fetchList } from 'lib-components'; +import { UseQueryOptions, useQuery } from 'react-query'; import { PlaylistAccess } from '../../types/playlistAccess'; diff --git a/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/api/useSearchUsers/index.ts b/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/api/useSearchUsers/index.ts index 46dd620fed..536ed382b3 100644 --- a/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/api/useSearchUsers/index.ts +++ b/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/api/useSearchUsers/index.ts @@ -1,10 +1,10 @@ import { APIList, - fetchList, FetchListQueryKey, FetchResponseError, + fetchList, } from 'lib-components'; -import { useQuery, UseQueryOptions } from 'react-query'; +import { UseQueryOptions, useQuery } from 'react-query'; export interface UserLite { email: string; diff --git a/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/api/useUpdatePlaylist/index.ts b/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/api/useUpdatePlaylist/index.ts index cd2f47c800..da68756b4a 100644 --- a/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/api/useUpdatePlaylist/index.ts +++ b/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/api/useUpdatePlaylist/index.ts @@ -1,5 +1,5 @@ -import { updateOne, Playlist } from 'lib-components'; -import { useMutation, UseMutationOptions, useQueryClient } from 'react-query'; +import { Playlist, updateOne } from 'lib-components'; +import { UseMutationOptions, useMutation, useQueryClient } from 'react-query'; type UseUpdatePlaylistData = { organization: string; diff --git a/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/api/useUpdatePlaylistAccess/index.ts b/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/api/useUpdatePlaylistAccess/index.ts index 1f0df44169..0f799740b8 100644 --- a/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/api/useUpdatePlaylistAccess/index.ts +++ b/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/api/useUpdatePlaylistAccess/index.ts @@ -1,5 +1,5 @@ import { updateOne } from 'lib-components'; -import { useMutation, UseMutationOptions, useQueryClient } from 'react-query'; +import { UseMutationOptions, useMutation, useQueryClient } from 'react-query'; import { PlaylistAccess, PlaylistRole } from '../../types/playlistAccess'; diff --git a/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/components/AddUserAccessForm.tsx b/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/components/AddUserAccessForm.tsx index ae7056ea94..96c7202c88 100644 --- a/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/components/AddUserAccessForm.tsx +++ b/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/components/AddUserAccessForm.tsx @@ -1,6 +1,6 @@ import { Box, Heading, Paragraph, Select } from 'grommet'; import { Nullable } from 'lib-common'; -import { TextInput, ModalButton } from 'lib-components'; +import { ModalButton, TextInput } from 'lib-components'; import { debounce } from 'lodash'; import { Fragment, useEffect, useMemo, useRef, useState } from 'react'; import { defineMessages, useIntl } from 'react-intl'; diff --git a/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/components/UserListRow.tsx b/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/components/UserListRow.tsx index ac8d57b20d..d43e450a4a 100644 --- a/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/components/UserListRow.tsx +++ b/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/components/UserListRow.tsx @@ -3,10 +3,10 @@ import { AnonymousUser, BinSVG, ButtonLoaderStyle, - useCurrentUser, Modal, ModalButton, ModalControlMethods, + useCurrentUser, } from 'lib-components'; import { Fragment, useRef, useState } from 'react'; import { toast } from 'react-hot-toast'; diff --git a/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/components/UserRoleOptions.spec.tsx b/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/components/UserRoleOptions.spec.tsx index 7199c38a59..e1d5281d0f 100644 --- a/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/components/UserRoleOptions.spec.tsx +++ b/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/components/UserRoleOptions.spec.tsx @@ -1,4 +1,4 @@ -import { createIntl, IntlShape } from 'react-intl'; +import { IntlShape, createIntl } from 'react-intl'; import { userRoleOptions } from './UserRoleOptions'; diff --git a/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/components/UserRoleOptions.tsx b/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/components/UserRoleOptions.tsx index 1692482c1e..675ac84288 100644 --- a/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/components/UserRoleOptions.tsx +++ b/src/frontend/apps/standalone_site/src/features/Playlist/features/UpdatePlaylist/components/UserRoleOptions.tsx @@ -1,4 +1,4 @@ -import { defineMessages, IntlShape } from 'react-intl'; +import { IntlShape, defineMessages } from 'react-intl'; import { PlaylistRole } from '../types/playlistAccess'; diff --git a/src/frontend/apps/standalone_site/src/features/PortabilityRequests/api/useLtiUserAssociations.ts b/src/frontend/apps/standalone_site/src/features/PortabilityRequests/api/useLtiUserAssociations.ts index fc5181ef6e..1f932767de 100644 --- a/src/frontend/apps/standalone_site/src/features/PortabilityRequests/api/useLtiUserAssociations.ts +++ b/src/frontend/apps/standalone_site/src/features/PortabilityRequests/api/useLtiUserAssociations.ts @@ -1,5 +1,5 @@ import { createOne } from 'lib-components'; -import { useMutation, UseMutationOptions, useQueryClient } from 'react-query'; +import { UseMutationOptions, useMutation, useQueryClient } from 'react-query'; type UseCreateLtiUserAssociationData = { association_jwt: string; diff --git a/src/frontend/apps/standalone_site/src/features/PortabilityRequests/api/usePortabilityRequests.ts b/src/frontend/apps/standalone_site/src/features/PortabilityRequests/api/usePortabilityRequests.ts index 05264233ba..317f74bc0f 100644 --- a/src/frontend/apps/standalone_site/src/features/PortabilityRequests/api/usePortabilityRequests.ts +++ b/src/frontend/apps/standalone_site/src/features/PortabilityRequests/api/usePortabilityRequests.ts @@ -1,16 +1,16 @@ import { - actionOne, APIList, - fetchList, FetchListQueryKey, PortabilityRequest, + actionOne, + fetchList, } from 'lib-components'; import { - useMutation, UseMutationOptions, + UseQueryOptions, + useMutation, useQuery, useQueryClient, - UseQueryOptions, } from 'react-query'; type UsePortabilityRequestsParams = { diff --git a/src/frontend/apps/standalone_site/src/features/PortabilityRequests/components/PortabilityRequests.spec.tsx b/src/frontend/apps/standalone_site/src/features/PortabilityRequests/components/PortabilityRequests.spec.tsx index 0ed387a0d5..eb704e50cc 100644 --- a/src/frontend/apps/standalone_site/src/features/PortabilityRequests/components/PortabilityRequests.spec.tsx +++ b/src/frontend/apps/standalone_site/src/features/PortabilityRequests/components/PortabilityRequests.spec.tsx @@ -2,8 +2,8 @@ import { act, screen } from '@testing-library/react'; import userEvent from '@testing-library/user-event'; import fetchMock from 'fetch-mock'; import { - playlistMockFactory, PortabilityRequest, + playlistMockFactory, portabilityRequestMockFactory, } from 'lib-components'; import { Deferred, render } from 'lib-tests'; diff --git a/src/frontend/apps/standalone_site/src/features/PortabilityRequests/components/PortabilityRequests.tsx b/src/frontend/apps/standalone_site/src/features/PortabilityRequests/components/PortabilityRequests.tsx index efae2a8873..cfe74c6a63 100644 --- a/src/frontend/apps/standalone_site/src/features/PortabilityRequests/components/PortabilityRequests.tsx +++ b/src/frontend/apps/standalone_site/src/features/PortabilityRequests/components/PortabilityRequests.tsx @@ -5,7 +5,7 @@ import { defineMessages, useIntl } from 'react-intl'; import { ReactComponent as CheckListIcon } from 'assets/svg/iko_checklistsvg.svg'; import { WhiteCard } from 'components/Cards'; -import { commonSortMessages, SortableTable } from 'components/SortableTable'; +import { SortableTable, commonSortMessages } from 'components/SortableTable'; import { ITEM_PER_PAGE } from 'conf/global'; import { usePortabilityRequests } from '../api/usePortabilityRequests'; diff --git a/src/frontend/apps/standalone_site/src/routes/routes.tsx b/src/frontend/apps/standalone_site/src/routes/routes.tsx index 9c8124d1ff..f56c323c77 100644 --- a/src/frontend/apps/standalone_site/src/routes/routes.tsx +++ b/src/frontend/apps/standalone_site/src/routes/routes.tsx @@ -1,4 +1,4 @@ -import { defineMessages, FormattedMessage } from 'react-intl'; +import { FormattedMessage, defineMessages } from 'react-intl'; import { ReactComponent as AvatarIcon } from 'assets/svg/iko_avatarsvg.svg'; import { ReactComponent as HomeIcon } from 'assets/svg/iko_homesvg.svg'; diff --git a/src/frontend/packages/eslint-config-marsha/index.js b/src/frontend/packages/eslint-config-marsha/index.js index f1f7a8969c..21cb991645 100644 --- a/src/frontend/packages/eslint-config-marsha/index.js +++ b/src/frontend/packages/eslint-config-marsha/index.js @@ -64,6 +64,12 @@ module.exports = { 'error', { varsIgnorePattern: '^_', argsIgnorePattern: '^_' }, ], + 'sort-imports': [ + 'error', + { + ignoreDeclarationSort: true, + }, + ], }, }, { diff --git a/src/frontend/packages/lib_classroom/src/components/ClassroomWidgetProvider/index.tsx b/src/frontend/packages/lib_classroom/src/components/ClassroomWidgetProvider/index.tsx index 7bf5c04650..b14505cdcc 100644 --- a/src/frontend/packages/lib_classroom/src/components/ClassroomWidgetProvider/index.tsx +++ b/src/frontend/packages/lib_classroom/src/components/ClassroomWidgetProvider/index.tsx @@ -2,8 +2,8 @@ import { InfoWidgetModalProvider, UploadManager, WidgetProps, - WidgetsContainer, WidgetSize, + WidgetsContainer, } from 'lib-components'; import React from 'react'; diff --git a/src/frontend/packages/lib_classroom/src/components/ClassroomWidgetProvider/widgets/Description/index.tsx b/src/frontend/packages/lib_classroom/src/components/ClassroomWidgetProvider/widgets/Description/index.tsx index 1e34f458da..51dc2a9e84 100644 --- a/src/frontend/packages/lib_classroom/src/components/ClassroomWidgetProvider/widgets/Description/index.tsx +++ b/src/frontend/packages/lib_classroom/src/components/ClassroomWidgetProvider/widgets/Description/index.tsx @@ -1,6 +1,6 @@ import { Form, FormField, TextArea } from 'grommet'; import { Maybe } from 'lib-common'; -import { Classroom, debounce, FoldableItem } from 'lib-components'; +import { Classroom, FoldableItem, debounce } from 'lib-components'; import React, { useEffect, useRef, useState } from 'react'; import toast from 'react-hot-toast'; import { defineMessages, useIntl } from 'react-intl'; diff --git a/src/frontend/packages/lib_classroom/src/components/ClassroomWidgetProvider/widgets/Recordings/Recording/index.tsx b/src/frontend/packages/lib_classroom/src/components/ClassroomWidgetProvider/widgets/Recordings/Recording/index.tsx index b339e0a77f..41e3900542 100644 --- a/src/frontend/packages/lib_classroom/src/components/ClassroomWidgetProvider/widgets/Recordings/Recording/index.tsx +++ b/src/frontend/packages/lib_classroom/src/components/ClassroomWidgetProvider/widgets/Recordings/Recording/index.tsx @@ -8,7 +8,7 @@ import { } from 'lib-components'; import React, { useCallback } from 'react'; import { toast } from 'react-hot-toast'; -import { defineMessages, IntlShape, useIntl } from 'react-intl'; +import { IntlShape, defineMessages, useIntl } from 'react-intl'; import { NavLink } from 'react-router-dom'; import styled from 'styled-components'; diff --git a/src/frontend/packages/lib_classroom/src/components/ClassroomWidgetProvider/widgets/Scheduling/index.tsx b/src/frontend/packages/lib_classroom/src/components/ClassroomWidgetProvider/widgets/Scheduling/index.tsx index 8e97c9a543..08b5925ce0 100644 --- a/src/frontend/packages/lib_classroom/src/components/ClassroomWidgetProvider/widgets/Scheduling/index.tsx +++ b/src/frontend/packages/lib_classroom/src/components/ClassroomWidgetProvider/widgets/Scheduling/index.tsx @@ -2,9 +2,9 @@ import { Form } from 'grommet'; import { Maybe } from 'lib-common'; import { Classroom, - debounce, FoldableItem, SchedulingFields, + debounce, } from 'lib-components'; import React, { useEffect, useRef, useState } from 'react'; import toast from 'react-hot-toast'; diff --git a/src/frontend/packages/lib_classroom/src/components/ClassroomWidgetProvider/widgets/SupportSharing/UploadDocuments/DocumentRow/index.tsx b/src/frontend/packages/lib_classroom/src/components/ClassroomWidgetProvider/widgets/SupportSharing/UploadDocuments/DocumentRow/index.tsx index 75eec98c5f..7f41164871 100644 --- a/src/frontend/packages/lib_classroom/src/components/ClassroomWidgetProvider/widgets/SupportSharing/UploadDocuments/DocumentRow/index.tsx +++ b/src/frontend/packages/lib_classroom/src/components/ClassroomWidgetProvider/widgets/SupportSharing/UploadDocuments/DocumentRow/index.tsx @@ -1,12 +1,12 @@ import { Anchor, Box, Button, Text } from 'grommet'; import { - UploadingObject, - uploadState, - ObjectStatusPicker, - RetryUploadButton, BinSVG, ClassroomDocument, + ObjectStatusPicker, + RetryUploadButton, + UploadingObject, ValidSVG, + uploadState, } from 'lib-components'; import React, { useCallback, useEffect, useState } from 'react'; import { defineMessages, useIntl } from 'react-intl'; diff --git a/src/frontend/packages/lib_classroom/src/components/ClassroomWidgetProvider/widgets/SupportSharing/UploadDocuments/index.spec.tsx b/src/frontend/packages/lib_classroom/src/components/ClassroomWidgetProvider/widgets/SupportSharing/UploadDocuments/index.spec.tsx index 3b6b0c1c4c..0ebcc94300 100644 --- a/src/frontend/packages/lib_classroom/src/components/ClassroomWidgetProvider/widgets/SupportSharing/UploadDocuments/index.spec.tsx +++ b/src/frontend/packages/lib_classroom/src/components/ClassroomWidgetProvider/widgets/SupportSharing/UploadDocuments/index.spec.tsx @@ -2,13 +2,13 @@ import { act, fireEvent, screen, waitFor } from '@testing-library/react'; import userEvent from '@testing-library/user-event'; import fetchMock from 'fetch-mock'; import { - useUploadManager, - uploadState, ClassroomDocument, ClassroomModelName as modelName, report, + uploadState, + useUploadManager, } from 'lib-components'; -import { render, Deferred } from 'lib-tests'; +import { Deferred, render } from 'lib-tests'; import React, { PropsWithChildren } from 'react'; import { createClassroomDocument } from '@lib-classroom/data/sideEffects/createClassroomDocument'; diff --git a/src/frontend/packages/lib_classroom/src/components/ClassroomWidgetProvider/widgets/SupportSharing/UploadDocuments/index.tsx b/src/frontend/packages/lib_classroom/src/components/ClassroomWidgetProvider/widgets/SupportSharing/UploadDocuments/index.tsx index c138d01fa9..0d523b9479 100644 --- a/src/frontend/packages/lib_classroom/src/components/ClassroomWidgetProvider/widgets/SupportSharing/UploadDocuments/index.tsx +++ b/src/frontend/packages/lib_classroom/src/components/ClassroomWidgetProvider/widgets/SupportSharing/UploadDocuments/index.tsx @@ -1,13 +1,13 @@ import { Box, Button, Paragraph, Text } from 'grommet'; import { Nullable } from 'lib-common'; import { + Classroom, PlusSVG, UploadManagerStatus, - useUploadManager, - ClassroomModelName as modelName, - Classroom, formatSizeErrorScale, + ClassroomModelName as modelName, report, + useUploadManager, } from 'lib-components'; import React, { useCallback, useEffect, useRef, useState } from 'react'; import Dropzone from 'react-dropzone'; @@ -15,8 +15,8 @@ import { toast } from 'react-hot-toast'; import { defineMessages, useIntl } from 'react-intl'; import { - useClassroomDocuments, useClassroomDocumentMetadata, + useClassroomDocuments, } from '@lib-classroom/data/queries'; import { createClassroomDocument } from '@lib-classroom/data/sideEffects/createClassroomDocument'; diff --git a/src/frontend/packages/lib_classroom/src/components/DashboardClassroom/index.tsx b/src/frontend/packages/lib_classroom/src/components/DashboardClassroom/index.tsx index e80be2e984..ea6852212e 100644 --- a/src/frontend/packages/lib_classroom/src/components/DashboardClassroom/index.tsx +++ b/src/frontend/packages/lib_classroom/src/components/DashboardClassroom/index.tsx @@ -1,30 +1,30 @@ import { Box } from 'grommet'; import { AnonymousUser, - useCurrentResourceContext, - useCurrentUser, Classroom, Spinner, + useCurrentResourceContext, + useCurrentUser, } from 'lib-components'; import React, { - useState, Suspense, - useRef, - useEffect, lazy, useCallback, + useEffect, + useRef, + useState, } from 'react'; import { toast } from 'react-hot-toast'; import { defineMessages, useIntl } from 'react-intl'; import { - useJoinClassroomAction, useClassroom, + useJoinClassroomAction, } from '@lib-classroom/data/queries'; import { - DashboardClassroomAskUsernameStudent, DashboardClassroomAskUsername, + DashboardClassroomAskUsernameStudent, } from '../DashboardClassroomAskUsername'; import { DashboardClassroomError } from '../DashboardClassroomError'; diff --git a/src/frontend/packages/lib_classroom/src/components/DashboardClassroomAskUsername/index.tsx b/src/frontend/packages/lib_classroom/src/components/DashboardClassroomAskUsername/index.tsx index 09eaa05b96..f83f43a2fe 100644 --- a/src/frontend/packages/lib_classroom/src/components/DashboardClassroomAskUsername/index.tsx +++ b/src/frontend/packages/lib_classroom/src/components/DashboardClassroomAskUsername/index.tsx @@ -1,4 +1,4 @@ -import { Box, CheckBox, FormField, TextInput, Text } from 'grommet'; +import { Box, CheckBox, FormField, Text, TextInput } from 'grommet'; import { Classroom, DashboardButton } from 'lib-components'; import React, { useState } from 'react'; import { defineMessages, useIntl } from 'react-intl'; diff --git a/src/frontend/packages/lib_classroom/src/components/DashboardClassroomError/index.tsx b/src/frontend/packages/lib_classroom/src/components/DashboardClassroomError/index.tsx index d445130a07..e450bedeea 100644 --- a/src/frontend/packages/lib_classroom/src/components/DashboardClassroomError/index.tsx +++ b/src/frontend/packages/lib_classroom/src/components/DashboardClassroomError/index.tsx @@ -1,6 +1,6 @@ import { Box, Text } from 'grommet'; import React from 'react'; -import { defineMessages, FormattedMessage, useIntl } from 'react-intl'; +import { FormattedMessage, defineMessages, useIntl } from 'react-intl'; import { DashboardClassroomLayout, diff --git a/src/frontend/packages/lib_classroom/src/components/DashboardClassroomInfos/index.tsx b/src/frontend/packages/lib_classroom/src/components/DashboardClassroomInfos/index.tsx index d8f942d1a6..b08c896c2f 100644 --- a/src/frontend/packages/lib_classroom/src/components/DashboardClassroomInfos/index.tsx +++ b/src/frontend/packages/lib_classroom/src/components/DashboardClassroomInfos/index.tsx @@ -2,7 +2,7 @@ import { Box, Grid, Text } from 'grommet'; import { Nullable } from 'lib-common'; import { ClassroomInfos } from 'lib-components'; import React, { Fragment } from 'react'; -import { defineMessages, FormattedMessage } from 'react-intl'; +import { FormattedMessage, defineMessages } from 'react-intl'; import DashboardCopyClipboard from '@lib-classroom/components/DashboardCopyClipboard'; diff --git a/src/frontend/packages/lib_classroom/src/components/DashboardClassroomInstructor/index.spec.tsx b/src/frontend/packages/lib_classroom/src/components/DashboardClassroomInstructor/index.spec.tsx index da62858867..8bc0681cf9 100644 --- a/src/frontend/packages/lib_classroom/src/components/DashboardClassroomInstructor/index.spec.tsx +++ b/src/frontend/packages/lib_classroom/src/components/DashboardClassroomInstructor/index.spec.tsx @@ -1,6 +1,6 @@ import { fireEvent, screen } from '@testing-library/react'; import fetchMock from 'fetch-mock'; -import { render, Deferred } from 'lib-tests'; +import { Deferred, render } from 'lib-tests'; import React from 'react'; import { classroomMockFactory } from '@lib-classroom/utils/tests/factories'; diff --git a/src/frontend/packages/lib_classroom/src/components/DashboardClassroomInstructor/index.tsx b/src/frontend/packages/lib_classroom/src/components/DashboardClassroomInstructor/index.tsx index b5bee17741..7c4173838f 100644 --- a/src/frontend/packages/lib_classroom/src/components/DashboardClassroomInstructor/index.tsx +++ b/src/frontend/packages/lib_classroom/src/components/DashboardClassroomInstructor/index.tsx @@ -1,7 +1,7 @@ import { Box, Button, Grid } from 'grommet'; import { Breakpoints, Nullable } from 'lib-common'; -import { Classroom, useResponsive, Spinner } from 'lib-components'; -import React, { lazy, Suspense } from 'react'; +import { Classroom, Spinner, useResponsive } from 'lib-components'; +import React, { Suspense, lazy } from 'react'; import { toast } from 'react-hot-toast'; import { defineMessages, useIntl } from 'react-intl'; diff --git a/src/frontend/packages/lib_classroom/src/components/DashboardClassroomLayout/index.tsx b/src/frontend/packages/lib_classroom/src/components/DashboardClassroomLayout/index.tsx index 7521127404..2f04a2b961 100644 --- a/src/frontend/packages/lib_classroom/src/components/DashboardClassroomLayout/index.tsx +++ b/src/frontend/packages/lib_classroom/src/components/DashboardClassroomLayout/index.tsx @@ -1,5 +1,5 @@ import { Box, Grid, Text } from 'grommet'; -import { Nullable, Breakpoints } from 'lib-common'; +import { Breakpoints, Nullable } from 'lib-common'; import { useAppConfig, useResponsive } from 'lib-components'; import React from 'react'; diff --git a/src/frontend/packages/lib_classroom/src/data/queries/index.spec.tsx b/src/frontend/packages/lib_classroom/src/data/queries/index.spec.tsx index 54faa8fbce..e2f76735e2 100644 --- a/src/frontend/packages/lib_classroom/src/data/queries/index.spec.tsx +++ b/src/frontend/packages/lib_classroom/src/data/queries/index.spec.tsx @@ -4,21 +4,21 @@ import { useJwt } from 'lib-components'; import { WrapperReactQuery } from 'lib-tests'; import { - classroomMockFactory, classroomDocumentMockFactory, + classroomMockFactory, } from '@lib-classroom/utils/tests/factories'; import { useClassroom, + useClassroomDocuments, useClassrooms, useCreateClassroom, - useUpdateClassroom, useCreateClassroomAction, - useJoinClassroomAction, - useClassroomDocuments, - useUpdateClassroomDocument, useDeleteClassroom, useDeleteClassrooms, + useJoinClassroomAction, + useUpdateClassroom, + useUpdateClassroomDocument, } from '.'; jest.mock('lib-components', () => ({ diff --git a/src/frontend/packages/lib_classroom/src/data/queries/index.tsx b/src/frontend/packages/lib_classroom/src/data/queries/index.tsx index 83971a3395..ca8dfd2f2b 100644 --- a/src/frontend/packages/lib_classroom/src/data/queries/index.tsx +++ b/src/frontend/packages/lib_classroom/src/data/queries/index.tsx @@ -1,34 +1,34 @@ import { Maybe } from 'lib-common'; import { APIList, - actionOne, - createOne, - fetchList, - FetchListQueryKey, - fetchOne, - updateOne, - EndClassroomActionRequest, - EndClassroomActionResponse, - JoinClassroomActionRequest, - JoinClassroomActionResponse, Classroom, + ClassroomDocument, ClassroomLite, + ClassroomModelName, + ClassroomRecording, CreateClassroomActionRequest, CreateClassroomActionResponse, - ClassroomDocument, - ClassroomModelName, - metadata, + EndClassroomActionRequest, + EndClassroomActionResponse, + FetchListQueryKey, FetchResponseError, - deleteOne, + JoinClassroomActionRequest, + JoinClassroomActionResponse, + actionOne, bulkDelete, - ClassroomRecording, + createOne, + deleteOne, + fetchList, + fetchOne, + metadata, + updateOne, } from 'lib-components'; import { - useMutation, UseMutationOptions, + UseQueryOptions, + useMutation, useQuery, useQueryClient, - UseQueryOptions, } from 'react-query'; import { ClassroomDocumentMetadata } from '@lib-classroom/types/ClassroomAppData'; diff --git a/src/frontend/packages/lib_classroom/src/data/sideEffects/createClassroomDocument/index.ts b/src/frontend/packages/lib_classroom/src/data/sideEffects/createClassroomDocument/index.ts index 1aab9a0af7..a0881ee09d 100644 --- a/src/frontend/packages/lib_classroom/src/data/sideEffects/createClassroomDocument/index.ts +++ b/src/frontend/packages/lib_classroom/src/data/sideEffects/createClassroomDocument/index.ts @@ -1,10 +1,10 @@ import { - useJwt, API_ENDPOINT, + Classroom, ClassroomDocument, ClassroomModelName, - Classroom, fetchWrapper, + useJwt, } from 'lib-components'; export const createClassroomDocument = async (file: { diff --git a/src/frontend/packages/lib_classroom/src/data/sideEffects/createVOD/index.ts b/src/frontend/packages/lib_classroom/src/data/sideEffects/createVOD/index.ts index 007b80ce33..07273ed17f 100644 --- a/src/frontend/packages/lib_classroom/src/data/sideEffects/createVOD/index.ts +++ b/src/frontend/packages/lib_classroom/src/data/sideEffects/createVOD/index.ts @@ -2,10 +2,10 @@ import { API_ENDPOINT, ClassroomModelName, ClassroomRecording, + Video, fetchResponseHandler, fetchWrapper, useJwt, - Video, } from 'lib-components'; export const createVOD = async ( diff --git a/src/frontend/packages/lib_classroom/src/types/ClassroomAppData.ts b/src/frontend/packages/lib_classroom/src/types/ClassroomAppData.ts index 4281bee76b..488137e5ed 100644 --- a/src/frontend/packages/lib_classroom/src/types/ClassroomAppData.ts +++ b/src/frontend/packages/lib_classroom/src/types/ClassroomAppData.ts @@ -1,9 +1,9 @@ import { Nullable } from 'lib-common'; import { AppData, - ClassroomModelName, Classroom, ClassroomDocument, + ClassroomModelName, ResourceMetadata, } from 'lib-components'; diff --git a/src/frontend/packages/lib_classroom/src/utils/tests/factories.ts b/src/frontend/packages/lib_classroom/src/utils/tests/factories.ts index 57303deb7f..7c2abe7c8a 100644 --- a/src/frontend/packages/lib_classroom/src/utils/tests/factories.ts +++ b/src/frontend/packages/lib_classroom/src/utils/tests/factories.ts @@ -1,12 +1,12 @@ import * as faker from 'faker'; import { - playlistMockFactory, - uploadState, Classroom, ClassroomDocument, ClassroomInfos, ClassroomRecording, ClassroomRecordingVod, + playlistMockFactory, + uploadState, } from 'lib-components'; const { READY } = uploadState; diff --git a/src/frontend/packages/lib_common/src/BreadCrumbsProvider.tsx b/src/frontend/packages/lib_common/src/BreadCrumbsProvider.tsx index c5b7c52e78..93df6a8a5c 100644 --- a/src/frontend/packages/lib_common/src/BreadCrumbsProvider.tsx +++ b/src/frontend/packages/lib_common/src/BreadCrumbsProvider.tsx @@ -1,4 +1,4 @@ -import React, { createContext, useState, PropsWithChildren } from 'react'; +import React, { PropsWithChildren, createContext, useState } from 'react'; export interface Crumb { key: string; diff --git a/src/frontend/packages/lib_components/src/common/Button/index.spec.tsx b/src/frontend/packages/lib_components/src/common/Button/index.spec.tsx index e51c5835e5..f85fb8c651 100644 --- a/src/frontend/packages/lib_components/src/common/Button/index.spec.tsx +++ b/src/frontend/packages/lib_components/src/common/Button/index.spec.tsx @@ -1,4 +1,4 @@ -import { screen, fireEvent } from '@testing-library/react'; +import { fireEvent, screen } from '@testing-library/react'; import { render } from 'lib-tests'; import React from 'react'; diff --git a/src/frontend/packages/lib_components/src/common/Card/ClosingCard/index.tsx b/src/frontend/packages/lib_components/src/common/Card/ClosingCard/index.tsx index e415b505ba..096db17eb1 100644 --- a/src/frontend/packages/lib_components/src/common/Card/ClosingCard/index.tsx +++ b/src/frontend/packages/lib_components/src/common/Card/ClosingCard/index.tsx @@ -1,4 +1,4 @@ -import { Box, Card as GrommetCard, CardBody, BoxTypes, Button } from 'grommet'; +import { Box, BoxTypes, Button, CardBody, Card as GrommetCard } from 'grommet'; import { FormClose } from 'grommet-icons'; import { PropsWithChildren, ReactNode, useState } from 'react'; import styled from 'styled-components'; diff --git a/src/frontend/packages/lib_components/src/common/Card/ContentCard/index.tsx b/src/frontend/packages/lib_components/src/common/Card/ContentCard/index.tsx index e63900dfc9..44f174d9bc 100644 --- a/src/frontend/packages/lib_components/src/common/Card/ContentCard/index.tsx +++ b/src/frontend/packages/lib_components/src/common/Card/ContentCard/index.tsx @@ -1,12 +1,12 @@ import { Box, - Text, - Card as GrommetCard, - CardHeader, - CardBody, - CardFooter, BoxExtendedProps, BoxTypes, + CardBody, + CardFooter, + CardHeader, + Card as GrommetCard, + Text, } from 'grommet'; import React, { PropsWithChildren, useEffect, useState } from 'react'; import styled from 'styled-components'; diff --git a/src/frontend/packages/lib_components/src/common/ErrorComponents/BoundaryScreenError/index.tsx b/src/frontend/packages/lib_components/src/common/ErrorComponents/BoundaryScreenError/index.tsx index 4825ee4abf..728f55ceed 100644 --- a/src/frontend/packages/lib_components/src/common/ErrorComponents/BoundaryScreenError/index.tsx +++ b/src/frontend/packages/lib_components/src/common/ErrorComponents/BoundaryScreenError/index.tsx @@ -1,8 +1,8 @@ -import { Box, Paragraph, Image, Text, Stack, Heading } from 'grommet'; +import { Box, Heading, Image, Paragraph, Stack, Text } from 'grommet'; import { normalizeColor } from 'grommet/utils'; import { theme } from 'lib-common'; import React from 'react'; -import { useIntl, FormattedMessage } from 'react-intl'; +import { FormattedMessage, useIntl } from 'react-intl'; import styled from 'styled-components'; import { useAppConfig } from '@lib-components/data/stores/useAppConfig'; diff --git a/src/frontend/packages/lib_components/src/common/Form/index.tsx b/src/frontend/packages/lib_components/src/common/Form/index.tsx index dcf127cafe..34a053a331 100644 --- a/src/frontend/packages/lib_components/src/common/Form/index.tsx +++ b/src/frontend/packages/lib_components/src/common/Form/index.tsx @@ -11,8 +11,8 @@ import { } from 'grommet'; import { Maybe } from 'lib-common'; import React, { - createContext, PropsWithChildren, + createContext, useContext, useRef, useState, diff --git a/src/frontend/packages/lib_components/src/common/Modal/Modal.tsx b/src/frontend/packages/lib_components/src/common/Modal/Modal.tsx index 8db6aed24e..a4dadb9536 100644 --- a/src/frontend/packages/lib_components/src/common/Modal/Modal.tsx +++ b/src/frontend/packages/lib_components/src/common/Modal/Modal.tsx @@ -3,9 +3,9 @@ import { normalizeColor } from 'grommet/utils'; import { FormClose } from 'grommet-icons'; import { Nullable, theme } from 'lib-common'; import { - forwardRef, MutableRefObject, PropsWithChildren, + forwardRef, useCallback, useEffect, useState, diff --git a/src/frontend/packages/lib_components/src/common/ObjectStatusPicker/index.spec.tsx b/src/frontend/packages/lib_components/src/common/ObjectStatusPicker/index.spec.tsx index 011e2a86d3..b306d95c6c 100644 --- a/src/frontend/packages/lib_components/src/common/ObjectStatusPicker/index.spec.tsx +++ b/src/frontend/packages/lib_components/src/common/ObjectStatusPicker/index.spec.tsx @@ -5,8 +5,8 @@ import { v4 as uuidv4 } from 'uuid'; import { UploadManagerStatus } from '@lib-components/common/UploadManager'; import { - liveState, UploadableObject, + liveState, uploadState, } from '@lib-components/types/tracks'; diff --git a/src/frontend/packages/lib_components/src/common/ObjectStatusPicker/index.tsx b/src/frontend/packages/lib_components/src/common/ObjectStatusPicker/index.tsx index 7a6178aeb0..eb53149968 100644 --- a/src/frontend/packages/lib_components/src/common/ObjectStatusPicker/index.tsx +++ b/src/frontend/packages/lib_components/src/common/ObjectStatusPicker/index.tsx @@ -5,10 +5,10 @@ import { defineMessages, useIntl } from 'react-intl'; import { Spinner } from '@lib-components/common/Loader'; import { UploadManagerStatus } from '@lib-components/common/UploadManager'; import { - liveState, UploadableObject, - uploadState, Video, + liveState, + uploadState, } from '@lib-components/types/tracks'; const { DELETED, ERROR, PENDING, PROCESSING } = uploadState; diff --git a/src/frontend/packages/lib_components/src/common/UploadField/DropzonePlaceholder.tsx b/src/frontend/packages/lib_components/src/common/UploadField/DropzonePlaceholder.tsx index a3fc6f596f..4c1ddfed06 100644 --- a/src/frontend/packages/lib_components/src/common/UploadField/DropzonePlaceholder.tsx +++ b/src/frontend/packages/lib_components/src/common/UploadField/DropzonePlaceholder.tsx @@ -2,7 +2,7 @@ import { Box, Button } from 'grommet'; import { normalizeColor } from 'grommet/utils'; import { theme } from 'lib-common'; import * as React from 'react'; -import { defineMessages, FormattedMessage } from 'react-intl'; +import { FormattedMessage, defineMessages } from 'react-intl'; import styled from 'styled-components'; import { DropzoneIcon } from './DropzoneIcon'; diff --git a/src/frontend/packages/lib_components/src/common/UploadManager/index.spec.tsx b/src/frontend/packages/lib_components/src/common/UploadManager/index.spec.tsx index 58daeec507..9d0c97ff5d 100644 --- a/src/frontend/packages/lib_components/src/common/UploadManager/index.spec.tsx +++ b/src/frontend/packages/lib_components/src/common/UploadManager/index.spec.tsx @@ -1,6 +1,6 @@ import { act } from '@testing-library/react'; import fetchMock from 'fetch-mock'; -import { render, Deferred } from 'lib-tests'; +import { Deferred, render } from 'lib-tests'; import React from 'react'; import { v4 as uuidv4 } from 'uuid'; import xhrMock, { MockResponse } from 'xhr-mock'; diff --git a/src/frontend/packages/lib_components/src/common/WidgetsContainer/InfoModal/index.tsx b/src/frontend/packages/lib_components/src/common/WidgetsContainer/InfoModal/index.tsx index df53de4af4..467746f518 100644 --- a/src/frontend/packages/lib_components/src/common/WidgetsContainer/InfoModal/index.tsx +++ b/src/frontend/packages/lib_components/src/common/WidgetsContainer/InfoModal/index.tsx @@ -1,6 +1,6 @@ import { Box, Button, Layer, Text } from 'grommet'; import { normalizeColor } from 'grommet/utils'; -import { theme, isFirefox, isIframe } from 'lib-common'; +import { isFirefox, isIframe, theme } from 'lib-common'; import React, { useCallback, useEffect } from 'react'; import styled from 'styled-components'; diff --git a/src/frontend/packages/lib_components/src/common/WidgetsContainer/index.spec.tsx b/src/frontend/packages/lib_components/src/common/WidgetsContainer/index.spec.tsx index 2bc2bb5cf9..9eccd3ee55 100644 --- a/src/frontend/packages/lib_components/src/common/WidgetsContainer/index.spec.tsx +++ b/src/frontend/packages/lib_components/src/common/WidgetsContainer/index.spec.tsx @@ -4,7 +4,7 @@ import React from 'react'; import { InfoWidgetModalProvider } from '@lib-components/hooks/stores/useInfoWidgetModal'; -import { WidgetsContainer, WidgetSize } from '.'; +import { WidgetSize, WidgetsContainer } from '.'; const GenericComponent1 = () =>

Generic component 1

; const GenericComponent2 = () =>

Generic component 2

; diff --git a/src/frontend/packages/lib_components/src/common/queries/fetchOne.tsx b/src/frontend/packages/lib_components/src/common/queries/fetchOne.tsx index 301b1fadc5..6374c01fa9 100644 --- a/src/frontend/packages/lib_components/src/common/queries/fetchOne.tsx +++ b/src/frontend/packages/lib_components/src/common/queries/fetchOne.tsx @@ -1,4 +1,4 @@ -import { QueryKey, QueryFunctionContext } from 'react-query'; +import { QueryFunctionContext, QueryKey } from 'react-query'; import { useJwt } from '@lib-components/hooks/stores/useJwt'; diff --git a/src/frontend/packages/lib_components/src/common/queries/metadata.tsx b/src/frontend/packages/lib_components/src/common/queries/metadata.tsx index 452198bbba..4d33971fc5 100644 --- a/src/frontend/packages/lib_components/src/common/queries/metadata.tsx +++ b/src/frontend/packages/lib_components/src/common/queries/metadata.tsx @@ -1,4 +1,4 @@ -import { QueryKey, QueryFunctionContext } from 'react-query'; +import { QueryFunctionContext, QueryKey } from 'react-query'; import { useJwt } from '@lib-components/hooks/stores/useJwt'; diff --git a/src/frontend/packages/lib_components/src/data/stores/useAppConfig/index.tsx b/src/frontend/packages/lib_components/src/data/stores/useAppConfig/index.tsx index 503c238e99..b0fef1f893 100644 --- a/src/frontend/packages/lib_components/src/data/stores/useAppConfig/index.tsx +++ b/src/frontend/packages/lib_components/src/data/stores/useAppConfig/index.tsx @@ -1,5 +1,5 @@ import { Nullable } from 'lib-common'; -import React, { createContext, PropsWithChildren, useContext } from 'react'; +import React, { PropsWithChildren, createContext, useContext } from 'react'; import { AppConfig } from '@lib-components/types/AppData'; diff --git a/src/frontend/packages/lib_components/src/data/stores/useMarkdownImage/index.ts b/src/frontend/packages/lib_components/src/data/stores/useMarkdownImage/index.ts index a5a45035ae..0d77bfe06c 100644 --- a/src/frontend/packages/lib_components/src/data/stores/useMarkdownImage/index.ts +++ b/src/frontend/packages/lib_components/src/data/stores/useMarkdownImage/index.ts @@ -7,8 +7,8 @@ import { removeResource, } from '@lib-components/data/stores/actions'; import { - MarkdownImage, MarkdownDocumentModelName, + MarkdownImage, } from '@lib-components/types/apps/markdown/models'; import { StoreState } from '@lib-components/types/stores'; diff --git a/src/frontend/packages/lib_components/src/data/stores/useSentry/index.spec.ts b/src/frontend/packages/lib_components/src/data/stores/useSentry/index.spec.ts index d38cb3cf26..ee2065bdaf 100644 --- a/src/frontend/packages/lib_components/src/data/stores/useSentry/index.spec.ts +++ b/src/frontend/packages/lib_components/src/data/stores/useSentry/index.spec.ts @@ -1,4 +1,4 @@ -import { init, configureScope } from '@sentry/browser'; +import { configureScope, init } from '@sentry/browser'; import { useSentry } from '.'; diff --git a/src/frontend/packages/lib_components/src/data/stores/useSentry/index.ts b/src/frontend/packages/lib_components/src/data/stores/useSentry/index.ts index 8a52edb41e..d9ae96db9c 100644 --- a/src/frontend/packages/lib_components/src/data/stores/useSentry/index.ts +++ b/src/frontend/packages/lib_components/src/data/stores/useSentry/index.ts @@ -1,4 +1,4 @@ -import { init, configureScope } from '@sentry/browser'; +import { configureScope, init } from '@sentry/browser'; import { create } from 'zustand'; interface SentryStore { diff --git a/src/frontend/packages/lib_components/src/data/stores/useVideo/index.tsx b/src/frontend/packages/lib_components/src/data/stores/useVideo/index.tsx index 69a49424fe..7fdc39e258 100644 --- a/src/frontend/packages/lib_components/src/data/stores/useVideo/index.tsx +++ b/src/frontend/packages/lib_components/src/data/stores/useVideo/index.tsx @@ -8,7 +8,7 @@ import { } from '@lib-components/data/stores/actions'; import { modelName } from '@lib-components/types/models'; import { StoreState } from '@lib-components/types/stores'; -import { Video, Id3VideoType } from '@lib-components/types/tracks'; +import { Id3VideoType, Video } from '@lib-components/types/tracks'; type VideoStateResource = { [modelName.VIDEOS]: { diff --git a/src/frontend/packages/lib_components/src/hooks/useResponsive/index.spec.tsx b/src/frontend/packages/lib_components/src/hooks/useResponsive/index.spec.tsx index 10588088e9..beb58fd97e 100644 --- a/src/frontend/packages/lib_components/src/hooks/useResponsive/index.spec.tsx +++ b/src/frontend/packages/lib_components/src/hooks/useResponsive/index.spec.tsx @@ -1,4 +1,4 @@ -import { screen, renderHook } from '@testing-library/react'; +import { renderHook, screen } from '@testing-library/react'; import { ResponsiveContext } from 'grommet'; import { theme } from 'lib-common'; import { render, wrapperUtils } from 'lib-tests'; diff --git a/src/frontend/packages/lib_components/src/types/apps/classroom/models.ts b/src/frontend/packages/lib_components/src/types/apps/classroom/models.ts index 3608b71563..b1e8970236 100644 --- a/src/frontend/packages/lib_components/src/types/apps/classroom/models.ts +++ b/src/frontend/packages/lib_components/src/types/apps/classroom/models.ts @@ -3,8 +3,8 @@ import { Nullable } from 'lib-common'; import { Playlist, Resource, - uploadState, Video, + uploadState, } from '@lib-components/types/tracks'; export interface Classroom extends Resource { diff --git a/src/frontend/packages/lib_components/src/types/stores.ts b/src/frontend/packages/lib_components/src/types/stores.ts index c16ed04658..dd73fa2c82 100644 --- a/src/frontend/packages/lib_components/src/types/stores.ts +++ b/src/frontend/packages/lib_components/src/types/stores.ts @@ -7,18 +7,18 @@ import { FileDepositoryModelName, } from '@lib-components/types/apps/deposit/models'; import { - MarkdownImage, MarkdownDocumentModelName, + MarkdownImage, } from '@lib-components/types/apps/markdown/models'; import { Document } from './file'; import { modelName } from './models'; import { Resource, + SharedLiveMedia, Thumbnail, TimedText, Video, - SharedLiveMedia, } from './tracks'; export type StoreState = { diff --git a/src/frontend/packages/lib_components/src/utils/XAPI/index.spec.ts b/src/frontend/packages/lib_components/src/utils/XAPI/index.spec.ts index de99cac4cf..fcd50d4d1e 100644 --- a/src/frontend/packages/lib_components/src/utils/XAPI/index.spec.ts +++ b/src/frontend/packages/lib_components/src/utils/XAPI/index.spec.ts @@ -1,4 +1,4 @@ -import { videoMockFactory, liveState } from 'lib-components'; +import { liveState, videoMockFactory } from 'lib-components'; import { LiveXAPIStatement } from './LiveXapiStatement'; import { VideoXAPIStatement } from './VideoXAPIStatement'; diff --git a/src/frontend/packages/lib_components/src/utils/serviceWorker/serviceWorkerRefreshToken/useServiceWorkerRefreshToken/index.tsx b/src/frontend/packages/lib_components/src/utils/serviceWorker/serviceWorkerRefreshToken/useServiceWorkerRefreshToken/index.tsx index 3d966d01f5..1abc37fdc0 100644 --- a/src/frontend/packages/lib_components/src/utils/serviceWorker/serviceWorkerRefreshToken/useServiceWorkerRefreshToken/index.tsx +++ b/src/frontend/packages/lib_components/src/utils/serviceWorker/serviceWorkerRefreshToken/useServiceWorkerRefreshToken/index.tsx @@ -2,8 +2,8 @@ import { useEffect } from 'react'; import { useJwt } from '@lib-components/hooks/stores/useJwt'; import { - ServiceworkerAuthMessage, EServiceworkerAuthAction, + ServiceworkerAuthMessage, } from '@lib-components/types/serviceWorker'; /** diff --git a/src/frontend/packages/lib_components/src/utils/tests/factories.ts b/src/frontend/packages/lib_components/src/utils/tests/factories.ts index 359a411cf0..f2e71e6798 100644 --- a/src/frontend/packages/lib_components/src/utils/tests/factories.ts +++ b/src/frontend/packages/lib_components/src/utils/tests/factories.ts @@ -13,18 +13,18 @@ import { DecodedJwtLTI, DecodedJwtUser } from '@lib-components/types/jwt'; import { JoinMode, Live, - LiveModeType, LiveAttendance, + LiveModeType, LiveSession, - liveState, Playlist, PlaylistLite, SharedLiveMedia, Thumbnail, TimedText, + Video, + liveState, timedTextMode, uploadState, - Video, } from '@lib-components/types/tracks'; import { User } from '../../types'; diff --git a/src/frontend/packages/lib_markdown/src/components/CodeMirrorEditor/index.tsx b/src/frontend/packages/lib_markdown/src/components/CodeMirrorEditor/index.tsx index bb746427ee..eca2a5e91f 100644 --- a/src/frontend/packages/lib_markdown/src/components/CodeMirrorEditor/index.tsx +++ b/src/frontend/packages/lib_markdown/src/components/CodeMirrorEditor/index.tsx @@ -21,21 +21,21 @@ import { import { languages } from '@codemirror/language-data'; import { lintKeymap } from '@codemirror/lint'; import { - highlightSelectionMatches, RegExpCursor, + highlightSelectionMatches, searchKeymap, } from '@codemirror/search'; import { EditorState, Text } from '@codemirror/state'; import { EditorView, - keymap, ViewUpdate, - highlightSpecialChars, + crosshairCursor, drawSelection, dropCursor, - rectangularSelection, - crosshairCursor, highlightActiveLine, + highlightSpecialChars, + keymap, + rectangularSelection, } from '@codemirror/view'; import { Nullable } from 'lib-common'; import React, { useCallback, useEffect, useRef } from 'react'; diff --git a/src/frontend/packages/lib_markdown/src/components/MarkdownEditor/index.spec.tsx b/src/frontend/packages/lib_markdown/src/components/MarkdownEditor/index.spec.tsx index 9ab512db4d..976f93697a 100644 --- a/src/frontend/packages/lib_markdown/src/components/MarkdownEditor/index.spec.tsx +++ b/src/frontend/packages/lib_markdown/src/components/MarkdownEditor/index.spec.tsx @@ -1,16 +1,16 @@ /* eslint-disable testing-library/no-container */ /* eslint-disable testing-library/no-node-access */ import { - within, act, fireEvent, screen, waitFor, + within, } from '@testing-library/react'; import userEvent from '@testing-library/user-event'; import fetchMock from 'fetch-mock'; -import { useJwt, uploadState, UploadManager } from 'lib-components'; -import { createDtWithFiles, createFile, Deferred, render } from 'lib-tests'; +import { UploadManager, uploadState, useJwt } from 'lib-components'; +import { Deferred, createDtWithFiles, createFile, render } from 'lib-tests'; import React from 'react'; import xhrMock, { MockResponse } from 'xhr-mock'; diff --git a/src/frontend/packages/lib_markdown/src/components/MarkdownViewer/index.spec.tsx b/src/frontend/packages/lib_markdown/src/components/MarkdownViewer/index.spec.tsx index 00ab542686..7505f31c67 100644 --- a/src/frontend/packages/lib_markdown/src/components/MarkdownViewer/index.spec.tsx +++ b/src/frontend/packages/lib_markdown/src/components/MarkdownViewer/index.spec.tsx @@ -2,8 +2,8 @@ import { screen } from '@testing-library/react'; import userEvent from '@testing-library/user-event'; import { markdownDocumentMockFactory, - markdownTranslationMockFactory, markdownImageMockFactory, + markdownTranslationMockFactory, } from 'index'; import { useJwt } from 'lib-components'; import { render } from 'lib-tests'; diff --git a/src/frontend/packages/lib_markdown/src/components/MdxRenderer/index.tsx b/src/frontend/packages/lib_markdown/src/components/MdxRenderer/index.tsx index dee558fd47..b4aa71d05a 100644 --- a/src/frontend/packages/lib_markdown/src/components/MdxRenderer/index.tsx +++ b/src/frontend/packages/lib_markdown/src/components/MdxRenderer/index.tsx @@ -9,9 +9,9 @@ import DOMPurify from 'dompurify'; import langLatex from 'highlight.js/lib/languages/latex'; // Support LaTeX code highlighting. import { Nullable } from 'lib-common'; import { - Spinner, - MarkdownImage, MarkdownDocumentRenderingOptions, + MarkdownImage, + Spinner, } from 'lib-components'; import { debounce } from 'lodash'; import React from 'react'; diff --git a/src/frontend/packages/lib_markdown/src/components/MdxRenderer/remarkLatexPlugin.tsx b/src/frontend/packages/lib_markdown/src/components/MdxRenderer/remarkLatexPlugin.tsx index d5476eab96..b20e8a12cd 100644 --- a/src/frontend/packages/lib_markdown/src/components/MdxRenderer/remarkLatexPlugin.tsx +++ b/src/frontend/packages/lib_markdown/src/components/MdxRenderer/remarkLatexPlugin.tsx @@ -8,7 +8,7 @@ import { fromParse5 } from 'hast-util-from-parse5'; import { Code, Parent } from 'mdast'; import { parseFragment } from 'parse5'; -import { visit, Test } from 'unist-util-visit'; +import { Test, visit } from 'unist-util-visit'; import { markdownRenderLatex } from '@lib-markdown/data/queries'; diff --git a/src/frontend/packages/lib_markdown/src/components/MdxRenderer/remarkLocallyHostedImagePlugin.tsx b/src/frontend/packages/lib_markdown/src/components/MdxRenderer/remarkLocallyHostedImagePlugin.tsx index 049c927eb4..03ea4a3ea9 100644 --- a/src/frontend/packages/lib_markdown/src/components/MdxRenderer/remarkLocallyHostedImagePlugin.tsx +++ b/src/frontend/packages/lib_markdown/src/components/MdxRenderer/remarkLocallyHostedImagePlugin.tsx @@ -4,7 +4,7 @@ /* eslint-disable @typescript-eslint/no-unsafe-member-access */ /* eslint-disable @typescript-eslint/no-unsafe-return */ import { Image } from 'mdast'; -import { visit, Test } from 'unist-util-visit'; +import { Test, visit } from 'unist-util-visit'; import { fetchOneMarkdownImage } from '@lib-markdown/data/queries'; diff --git a/src/frontend/packages/lib_markdown/src/components/useImageUploadManager/index.spec.tsx b/src/frontend/packages/lib_markdown/src/components/useImageUploadManager/index.spec.tsx index d723f21503..bb90e94e99 100644 --- a/src/frontend/packages/lib_markdown/src/components/useImageUploadManager/index.spec.tsx +++ b/src/frontend/packages/lib_markdown/src/components/useImageUploadManager/index.spec.tsx @@ -4,11 +4,11 @@ import { markdownImageMockFactory } from 'index'; import { UploadManager, UploadManagerStatus, - useUploadManager, MarkdownDocumentModelName as modelName, uploadState, + useUploadManager, } from 'lib-components'; -import { render, Deferred } from 'lib-tests'; +import { Deferred, render } from 'lib-tests'; import React from 'react'; import { v4 as uuidv4 } from 'uuid'; import xhrMock, { MockResponse } from 'xhr-mock'; diff --git a/src/frontend/packages/lib_markdown/src/components/useImageUploadManager/index.tsx b/src/frontend/packages/lib_markdown/src/components/useImageUploadManager/index.tsx index 1a2bf635bc..8a1f04d203 100644 --- a/src/frontend/packages/lib_markdown/src/components/useImageUploadManager/index.tsx +++ b/src/frontend/packages/lib_markdown/src/components/useImageUploadManager/index.tsx @@ -1,7 +1,7 @@ import { UploadManagerStatus, - useUploadManager, MarkdownDocumentModelName as modelName, + useUploadManager, } from 'lib-components'; import React, { useCallback, useEffect } from 'react'; import toast from 'react-hot-toast'; diff --git a/src/frontend/packages/lib_markdown/src/data/queries/index.tsx b/src/frontend/packages/lib_markdown/src/data/queries/index.tsx index 7d361c0bea..42f2b002f6 100644 --- a/src/frontend/packages/lib_markdown/src/data/queries/index.tsx +++ b/src/frontend/packages/lib_markdown/src/data/queries/index.tsx @@ -1,19 +1,19 @@ /* eslint-disable @typescript-eslint/no-explicit-any */ import { + MarkdownDocument, + MarkdownSaveTranslationsRequest, + MarkdownSaveTranslationsResponse, actionOne, createOne, fetchOne, updateOne, - MarkdownDocument, - MarkdownSaveTranslationsRequest, - MarkdownSaveTranslationsResponse, } from 'lib-components'; import { - useMutation, UseMutationOptions, + UseQueryOptions, + useMutation, useQuery, useQueryClient, - UseQueryOptions, } from 'react-query'; interface MarkdownDocumentsSelectResponse { diff --git a/src/frontend/packages/lib_markdown/src/data/sideEffects/createMarkdownImage/index.ts b/src/frontend/packages/lib_markdown/src/data/sideEffects/createMarkdownImage/index.ts index 4697d5a72e..7d19d3ae7f 100644 --- a/src/frontend/packages/lib_markdown/src/data/sideEffects/createMarkdownImage/index.ts +++ b/src/frontend/packages/lib_markdown/src/data/sideEffects/createMarkdownImage/index.ts @@ -1,11 +1,11 @@ /* eslint-disable @typescript-eslint/restrict-template-expressions */ /* eslint-disable @typescript-eslint/no-unsafe-assignment */ import { - useJwt, API_ENDPOINT, MarkdownImage, - MarkdownDocumentModelName as modelName, fetchWrapper, + MarkdownDocumentModelName as modelName, + useJwt, } from 'lib-components'; export const createMarkdownImage = async () => { diff --git a/src/frontend/packages/lib_markdown/src/utils/tests/factories.ts b/src/frontend/packages/lib_markdown/src/utils/tests/factories.ts index d597186cb4..a3be53aa70 100644 --- a/src/frontend/packages/lib_markdown/src/utils/tests/factories.ts +++ b/src/frontend/packages/lib_markdown/src/utils/tests/factories.ts @@ -1,10 +1,10 @@ import * as faker from 'faker'; import { - playlistMockFactory, - uploadState, MarkdownDocument, MarkdownDocumentTranslation, MarkdownImage, + playlistMockFactory, + uploadState, } from 'lib-components'; export const markdownDocumentMockFactory = ( diff --git a/src/frontend/packages/lib_tests/src/imageSnapshot.tsx b/src/frontend/packages/lib_tests/src/imageSnapshot.tsx index 53de6de843..e480722b4f 100644 --- a/src/frontend/packages/lib_tests/src/imageSnapshot.tsx +++ b/src/frontend/packages/lib_tests/src/imageSnapshot.tsx @@ -2,7 +2,7 @@ import path from 'path'; import { cleanup, render } from '@testing-library/react'; import { Grommet } from 'grommet'; -import { generateImage, GenerateImageOptions } from 'jsdom-screenshot'; +import { GenerateImageOptions, generateImage } from 'jsdom-screenshot'; import { GlobalStyles, theme } from 'lib-common'; import React from 'react'; diff --git a/src/frontend/packages/lib_tests/src/render.tsx b/src/frontend/packages/lib_tests/src/render.tsx index e2c2083465..b4a79393bf 100644 --- a/src/frontend/packages/lib_tests/src/render.tsx +++ b/src/frontend/packages/lib_tests/src/render.tsx @@ -1,13 +1,13 @@ import { - act, - render as testingLibraryRender, - RenderOptions as TestingLibraryRenderOptions, RenderResult, + RenderOptions as TestingLibraryRenderOptions, + act, screen, + render as testingLibraryRender, } from '@testing-library/react'; import { Grommet, ResponsiveContext, ThemeType } from 'grommet'; import MatchMediaMock from 'jest-matchmedia-mock'; -import { BreadCrumbsProvider, GlobalStyles, theme, Nullable } from 'lib-common'; +import { BreadCrumbsProvider, GlobalStyles, Nullable, theme } from 'lib-common'; import React, { CSSProperties, ReactElement } from 'react'; import toast, { Toast, Toaster, useToaster } from 'react-hot-toast'; import { QueryClient, QueryClientProvider } from 'react-query'; diff --git a/src/frontend/packages/lib_tests/src/wrapper.tsx b/src/frontend/packages/lib_tests/src/wrapper.tsx index 7cd9f15496..9cb68a09f5 100644 --- a/src/frontend/packages/lib_tests/src/wrapper.tsx +++ b/src/frontend/packages/lib_tests/src/wrapper.tsx @@ -1,7 +1,7 @@ import { Fragment, PropsWithChildren } from 'react'; import { QueryClient, QueryClientProvider } from 'react-query'; -import { appendUtilsElement, RenderOptions } from './render'; +import { RenderOptions, appendUtilsElement } from './render'; export const WrapperReactQuery = ({ children }: PropsWithChildren) => { const queryClient = new QueryClient({ diff --git a/src/frontend/packages/lib_video/src/api/createLiveSession/index.ts b/src/frontend/packages/lib_video/src/api/createLiveSession/index.ts index 45e08b8c50..d9561fc83e 100644 --- a/src/frontend/packages/lib_video/src/api/createLiveSession/index.ts +++ b/src/frontend/packages/lib_video/src/api/createLiveSession/index.ts @@ -1,8 +1,8 @@ import { - fetchWrapper, - useJwt, API_ENDPOINT, LiveSession, + fetchWrapper, + useJwt, } from 'lib-components'; /** diff --git a/src/frontend/packages/lib_video/src/api/createSharedLiveMedia/index.ts b/src/frontend/packages/lib_video/src/api/createSharedLiveMedia/index.ts index 7b7ba10375..3d2e3fbf82 100644 --- a/src/frontend/packages/lib_video/src/api/createSharedLiveMedia/index.ts +++ b/src/frontend/packages/lib_video/src/api/createSharedLiveMedia/index.ts @@ -1,9 +1,9 @@ import { - fetchWrapper, - useJwt, API_ENDPOINT, SharedLiveMedia, fetchResponseHandler, + fetchWrapper, + useJwt, } from 'lib-components'; interface createSharedLiveMediaBody { diff --git a/src/frontend/packages/lib_video/src/api/createThumbnail/index.ts b/src/frontend/packages/lib_video/src/api/createThumbnail/index.ts index 53706a30a5..1dfbf39217 100644 --- a/src/frontend/packages/lib_video/src/api/createThumbnail/index.ts +++ b/src/frontend/packages/lib_video/src/api/createThumbnail/index.ts @@ -1,10 +1,10 @@ import { - fetchWrapper, - useJwt, API_ENDPOINT, - modelName, Thumbnail, fetchResponseHandler, + fetchWrapper, + modelName, + useJwt, } from 'lib-components'; interface createThumbnailBody { diff --git a/src/frontend/packages/lib_video/src/api/createTimedTextTrack/index.spec.ts b/src/frontend/packages/lib_video/src/api/createTimedTextTrack/index.spec.ts index 0ab573b412..c60b70b4ee 100644 --- a/src/frontend/packages/lib_video/src/api/createTimedTextTrack/index.spec.ts +++ b/src/frontend/packages/lib_video/src/api/createTimedTextTrack/index.spec.ts @@ -1,5 +1,5 @@ import fetchMock from 'fetch-mock'; -import { useJwt, timedTextMode } from 'lib-components'; +import { timedTextMode, useJwt } from 'lib-components'; import { createTimedTextTrack } from '.'; diff --git a/src/frontend/packages/lib_video/src/api/createTimedTextTrack/index.ts b/src/frontend/packages/lib_video/src/api/createTimedTextTrack/index.ts index f2e97448a0..3dcd8d8a85 100644 --- a/src/frontend/packages/lib_video/src/api/createTimedTextTrack/index.ts +++ b/src/frontend/packages/lib_video/src/api/createTimedTextTrack/index.ts @@ -1,11 +1,11 @@ import { - fetchWrapper, - useJwt, API_ENDPOINT, - modelName, TimedText, - timedTextMode, fetchResponseHandler, + fetchWrapper, + modelName, + timedTextMode, + useJwt, } from 'lib-components'; interface createTimedTextTrackBody { diff --git a/src/frontend/packages/lib_video/src/api/harvestLive/index.spec.tsx b/src/frontend/packages/lib_video/src/api/harvestLive/index.spec.tsx index 1aeab5e1da..56ca444e7d 100644 --- a/src/frontend/packages/lib_video/src/api/harvestLive/index.spec.tsx +++ b/src/frontend/packages/lib_video/src/api/harvestLive/index.spec.tsx @@ -1,5 +1,5 @@ import fetchMock from 'fetch-mock'; -import { useJwt, videoMockFactory, liveState } from 'lib-components'; +import { liveState, useJwt, videoMockFactory } from 'lib-components'; import { harvestLive } from '.'; diff --git a/src/frontend/packages/lib_video/src/api/harvestLive/index.tsx b/src/frontend/packages/lib_video/src/api/harvestLive/index.tsx index 0e973a2c68..2246ac22ef 100644 --- a/src/frontend/packages/lib_video/src/api/harvestLive/index.tsx +++ b/src/frontend/packages/lib_video/src/api/harvestLive/index.tsx @@ -1,4 +1,4 @@ -import { fetchWrapper, useJwt, Video, API_ENDPOINT } from 'lib-components'; +import { API_ENDPOINT, Video, fetchWrapper, useJwt } from 'lib-components'; export const harvestLive = async (video: Video) => { const response = await fetchWrapper( diff --git a/src/frontend/packages/lib_video/src/api/initiateLive/index.spec.ts b/src/frontend/packages/lib_video/src/api/initiateLive/index.spec.ts index b11a816727..fe68bf14bb 100644 --- a/src/frontend/packages/lib_video/src/api/initiateLive/index.spec.ts +++ b/src/frontend/packages/lib_video/src/api/initiateLive/index.spec.ts @@ -1,10 +1,10 @@ import fetchMock from 'fetch-mock'; import { - useJwt, - videoMockFactory, LiveModeType, liveState, uploadState, + useJwt, + videoMockFactory, } from 'lib-components'; import { initiateLive } from '.'; diff --git a/src/frontend/packages/lib_video/src/api/initiateLive/index.ts b/src/frontend/packages/lib_video/src/api/initiateLive/index.ts index a9913771ac..ae30562c64 100644 --- a/src/frontend/packages/lib_video/src/api/initiateLive/index.ts +++ b/src/frontend/packages/lib_video/src/api/initiateLive/index.ts @@ -1,10 +1,10 @@ import { - fetchWrapper, - useJwt, API_ENDPOINT, LiveModeType, Video, fetchResponseHandler, + fetchWrapper, + useJwt, } from 'lib-components'; /** diff --git a/src/frontend/packages/lib_video/src/api/navigateSharingDoc/index.ts b/src/frontend/packages/lib_video/src/api/navigateSharingDoc/index.ts index 540e554054..eed5792f7e 100644 --- a/src/frontend/packages/lib_video/src/api/navigateSharingDoc/index.ts +++ b/src/frontend/packages/lib_video/src/api/navigateSharingDoc/index.ts @@ -1,4 +1,4 @@ -import { fetchWrapper, useJwt, API_ENDPOINT, Video } from 'lib-components'; +import { API_ENDPOINT, Video, fetchWrapper, useJwt } from 'lib-components'; export const navigateSharingDoc = async ( video: Video, diff --git a/src/frontend/packages/lib_video/src/api/publishLiveToVod/index.ts b/src/frontend/packages/lib_video/src/api/publishLiveToVod/index.ts index 655f809816..630f989a34 100644 --- a/src/frontend/packages/lib_video/src/api/publishLiveToVod/index.ts +++ b/src/frontend/packages/lib_video/src/api/publishLiveToVod/index.ts @@ -1,4 +1,4 @@ -import { fetchWrapper, useJwt, API_ENDPOINT, Video } from 'lib-components'; +import { API_ENDPOINT, Video, fetchWrapper, useJwt } from 'lib-components'; export const publishLiveToVod = async (video: Video) => { const response = await fetchWrapper( diff --git a/src/frontend/packages/lib_video/src/api/pushAttendance/index.spec.ts b/src/frontend/packages/lib_video/src/api/pushAttendance/index.spec.ts index 054ac11ec6..4525aa8cc6 100644 --- a/src/frontend/packages/lib_video/src/api/pushAttendance/index.spec.ts +++ b/src/frontend/packages/lib_video/src/api/pushAttendance/index.spec.ts @@ -1,5 +1,5 @@ import fetchMock from 'fetch-mock'; -import { useJwt, liveSessionFactory } from 'lib-components'; +import { liveSessionFactory, useJwt } from 'lib-components'; import { v4 as uuidv4 } from 'uuid'; import { pushAttendance } from '.'; diff --git a/src/frontend/packages/lib_video/src/api/pushAttendance/index.ts b/src/frontend/packages/lib_video/src/api/pushAttendance/index.ts index 1ff53e815d..d900cad7a7 100644 --- a/src/frontend/packages/lib_video/src/api/pushAttendance/index.ts +++ b/src/frontend/packages/lib_video/src/api/pushAttendance/index.ts @@ -1,8 +1,8 @@ import { - fetchWrapper, - useJwt, API_ENDPOINT, LiveSession, + fetchWrapper, + useJwt, } from 'lib-components'; export const pushAttendance = async ( diff --git a/src/frontend/packages/lib_video/src/api/setLiveSessionDisplayName/index.spec.ts b/src/frontend/packages/lib_video/src/api/setLiveSessionDisplayName/index.spec.ts index 607c5258f7..dcb185b5a7 100644 --- a/src/frontend/packages/lib_video/src/api/setLiveSessionDisplayName/index.spec.ts +++ b/src/frontend/packages/lib_video/src/api/setLiveSessionDisplayName/index.spec.ts @@ -1,6 +1,6 @@ import * as faker from 'faker'; import fetchMock from 'fetch-mock'; -import { useJwt, liveSessionFactory } from 'lib-components'; +import { liveSessionFactory, useJwt } from 'lib-components'; import { v4 as uuidv4 } from 'uuid'; import { setLiveSessionDisplayName } from '.'; diff --git a/src/frontend/packages/lib_video/src/api/setLiveSessionDisplayName/index.ts b/src/frontend/packages/lib_video/src/api/setLiveSessionDisplayName/index.ts index c3130cbe55..0d84f64f49 100644 --- a/src/frontend/packages/lib_video/src/api/setLiveSessionDisplayName/index.ts +++ b/src/frontend/packages/lib_video/src/api/setLiveSessionDisplayName/index.ts @@ -1,8 +1,8 @@ import { - fetchWrapper, - useJwt, API_ENDPOINT, LiveSession, + fetchWrapper, + useJwt, } from 'lib-components'; export const setLiveSessionDisplayName = async ( diff --git a/src/frontend/packages/lib_video/src/api/stopLive/index.spec.ts b/src/frontend/packages/lib_video/src/api/stopLive/index.spec.ts index 10eb625a2f..8070724ff5 100644 --- a/src/frontend/packages/lib_video/src/api/stopLive/index.spec.ts +++ b/src/frontend/packages/lib_video/src/api/stopLive/index.spec.ts @@ -1,5 +1,5 @@ import fetchMock from 'fetch-mock'; -import { useJwt, videoMockFactory, liveState } from 'lib-components'; +import { liveState, useJwt, videoMockFactory } from 'lib-components'; import { stopLive } from '.'; diff --git a/src/frontend/packages/lib_video/src/api/stopLive/index.tsx b/src/frontend/packages/lib_video/src/api/stopLive/index.tsx index 54aae3a09d..f73544f4f8 100644 --- a/src/frontend/packages/lib_video/src/api/stopLive/index.tsx +++ b/src/frontend/packages/lib_video/src/api/stopLive/index.tsx @@ -1,4 +1,4 @@ -import { fetchWrapper, useJwt, API_ENDPOINT, Video } from 'lib-components'; +import { API_ENDPOINT, Video, fetchWrapper, useJwt } from 'lib-components'; /** * Post to an action endpoint to stop a live streaming. diff --git a/src/frontend/packages/lib_video/src/api/updateLiveParticipants/index.spec.tsx b/src/frontend/packages/lib_video/src/api/updateLiveParticipants/index.spec.tsx index 69456c3b8e..f17d08f1ca 100644 --- a/src/frontend/packages/lib_video/src/api/updateLiveParticipants/index.spec.tsx +++ b/src/frontend/packages/lib_video/src/api/updateLiveParticipants/index.spec.tsx @@ -1,7 +1,7 @@ import fetchMock from 'fetch-mock'; import { - useJwt, participantMockFactory, + useJwt, videoMockFactory, } from 'lib-components'; diff --git a/src/frontend/packages/lib_video/src/api/updateLiveParticipants/index.tsx b/src/frontend/packages/lib_video/src/api/updateLiveParticipants/index.tsx index 07ad11e2af..36734c78c4 100644 --- a/src/frontend/packages/lib_video/src/api/updateLiveParticipants/index.tsx +++ b/src/frontend/packages/lib_video/src/api/updateLiveParticipants/index.tsx @@ -1,9 +1,9 @@ import { - fetchWrapper, - useJwt, API_ENDPOINT, Participant, Video, + fetchWrapper, + useJwt, } from 'lib-components'; const updateLiveParticipants = async ( diff --git a/src/frontend/packages/lib_video/src/api/updateLiveSession/index.spec.ts b/src/frontend/packages/lib_video/src/api/updateLiveSession/index.spec.ts index a0535fa9e0..972f9e0c3a 100644 --- a/src/frontend/packages/lib_video/src/api/updateLiveSession/index.spec.ts +++ b/src/frontend/packages/lib_video/src/api/updateLiveSession/index.spec.ts @@ -1,5 +1,5 @@ import fetchMock from 'fetch-mock'; -import { useJwt, liveSessionFactory } from 'lib-components'; +import { liveSessionFactory, useJwt } from 'lib-components'; import { v4 as uuidv4 } from 'uuid'; import { updateLiveSession } from '.'; diff --git a/src/frontend/packages/lib_video/src/api/updateLiveSession/index.ts b/src/frontend/packages/lib_video/src/api/updateLiveSession/index.ts index 384293dfd1..72c41cc636 100644 --- a/src/frontend/packages/lib_video/src/api/updateLiveSession/index.ts +++ b/src/frontend/packages/lib_video/src/api/updateLiveSession/index.ts @@ -1,8 +1,8 @@ import { - fetchWrapper, - useJwt, API_ENDPOINT, LiveSession, + fetchWrapper, + useJwt, } from 'lib-components'; export const updateLiveSession = async ( diff --git a/src/frontend/packages/lib_video/src/api/useCreateVideo/index.tsx b/src/frontend/packages/lib_video/src/api/useCreateVideo/index.tsx index 5fa172fd53..f2edcb111c 100644 --- a/src/frontend/packages/lib_video/src/api/useCreateVideo/index.tsx +++ b/src/frontend/packages/lib_video/src/api/useCreateVideo/index.tsx @@ -1,12 +1,12 @@ import { Nullable } from 'lib-common'; import { + FetchResponseError, LiveModeType, - uploadState, - createOne, Video, - FetchResponseError, + createOne, + uploadState, } from 'lib-components'; -import { UseMutationOptions, useQueryClient, useMutation } from 'react-query'; +import { UseMutationOptions, useMutation, useQueryClient } from 'react-query'; export type UseCreateVideoData = { playlist: string; diff --git a/src/frontend/packages/lib_video/src/api/useDeleteSharedLiveMedia/index.ts b/src/frontend/packages/lib_video/src/api/useDeleteSharedLiveMedia/index.ts index 0ac450bba4..cc839f2310 100644 --- a/src/frontend/packages/lib_video/src/api/useDeleteSharedLiveMedia/index.ts +++ b/src/frontend/packages/lib_video/src/api/useDeleteSharedLiveMedia/index.ts @@ -1,6 +1,6 @@ import { Maybe } from 'lib-common'; -import { deleteOne, FetchResponseError, SharedLiveMedia } from 'lib-components'; -import { useMutation, UseMutationOptions, useQueryClient } from 'react-query'; +import { FetchResponseError, SharedLiveMedia, deleteOne } from 'lib-components'; +import { UseMutationOptions, useMutation, useQueryClient } from 'react-query'; type UseDeleteSharedLiveMediaData = { videoId: string; diff --git a/src/frontend/packages/lib_video/src/api/useDeleteThumbnail/index.ts b/src/frontend/packages/lib_video/src/api/useDeleteThumbnail/index.ts index 193410501e..60437a1c8c 100644 --- a/src/frontend/packages/lib_video/src/api/useDeleteThumbnail/index.ts +++ b/src/frontend/packages/lib_video/src/api/useDeleteThumbnail/index.ts @@ -1,6 +1,6 @@ import { Maybe } from 'lib-common'; -import { deleteOne, FetchResponseError, Thumbnail } from 'lib-components'; -import { useMutation, UseMutationOptions, useQueryClient } from 'react-query'; +import { FetchResponseError, Thumbnail, deleteOne } from 'lib-components'; +import { UseMutationOptions, useMutation, useQueryClient } from 'react-query'; type UseDeleteThumbnailData = { videoId: string; diff --git a/src/frontend/packages/lib_video/src/api/useDeleteTimedTextTrack/index.ts b/src/frontend/packages/lib_video/src/api/useDeleteTimedTextTrack/index.ts index a21c1a2aff..5018fc4af2 100644 --- a/src/frontend/packages/lib_video/src/api/useDeleteTimedTextTrack/index.ts +++ b/src/frontend/packages/lib_video/src/api/useDeleteTimedTextTrack/index.ts @@ -1,6 +1,6 @@ import { Maybe } from 'lib-common'; -import { deleteOne, FetchResponseError, TimedText } from 'lib-components'; -import { useMutation, UseMutationOptions, useQueryClient } from 'react-query'; +import { FetchResponseError, TimedText, deleteOne } from 'lib-components'; +import { UseMutationOptions, useMutation, useQueryClient } from 'react-query'; type UseDeleteTimedTextTrackData = { videoId: string; diff --git a/src/frontend/packages/lib_video/src/api/useDeleteVideo/index.spec.tsx b/src/frontend/packages/lib_video/src/api/useDeleteVideo/index.spec.tsx index 26add46eea..0cec8a57c8 100644 --- a/src/frontend/packages/lib_video/src/api/useDeleteVideo/index.spec.tsx +++ b/src/frontend/packages/lib_video/src/api/useDeleteVideo/index.spec.tsx @@ -1,4 +1,4 @@ -import { waitFor, renderHook } from '@testing-library/react'; +import { renderHook, waitFor } from '@testing-library/react'; import fetchMock from 'fetch-mock'; import { useJwt, videoMockFactory } from 'lib-components'; import { WrapperReactQuery } from 'lib-tests'; diff --git a/src/frontend/packages/lib_video/src/api/useDeleteVideo/index.ts b/src/frontend/packages/lib_video/src/api/useDeleteVideo/index.ts index 08aefe9cd7..2b10eba77f 100644 --- a/src/frontend/packages/lib_video/src/api/useDeleteVideo/index.ts +++ b/src/frontend/packages/lib_video/src/api/useDeleteVideo/index.ts @@ -1,6 +1,6 @@ import { Maybe } from 'lib-common'; -import { deleteOne, FetchResponseError, Video } from 'lib-components'; -import { useMutation, UseMutationOptions, useQueryClient } from 'react-query'; +import { FetchResponseError, Video, deleteOne } from 'lib-components'; +import { UseMutationOptions, useMutation, useQueryClient } from 'react-query'; type UseDeleteVideoData = string; type UseDeleteVideoError = FetchResponseError; diff --git a/src/frontend/packages/lib_video/src/api/useDeleteVideos/index.spec.tsx b/src/frontend/packages/lib_video/src/api/useDeleteVideos/index.spec.tsx index 19e889ae14..d0f69a9ebb 100644 --- a/src/frontend/packages/lib_video/src/api/useDeleteVideos/index.spec.tsx +++ b/src/frontend/packages/lib_video/src/api/useDeleteVideos/index.spec.tsx @@ -1,4 +1,4 @@ -import { waitFor, renderHook } from '@testing-library/react'; +import { renderHook, waitFor } from '@testing-library/react'; import fetchMock from 'fetch-mock'; import { useJwt, videoMockFactory } from 'lib-components'; import { WrapperReactQuery } from 'lib-tests'; diff --git a/src/frontend/packages/lib_video/src/api/useDeleteVideos/index.tsx b/src/frontend/packages/lib_video/src/api/useDeleteVideos/index.tsx index 0d5ad71674..7a05df27a1 100644 --- a/src/frontend/packages/lib_video/src/api/useDeleteVideos/index.tsx +++ b/src/frontend/packages/lib_video/src/api/useDeleteVideos/index.tsx @@ -1,5 +1,5 @@ import { FetchResponseError, bulkDelete } from 'lib-components'; -import { useMutation, UseMutationOptions, useQueryClient } from 'react-query'; +import { UseMutationOptions, useMutation, useQueryClient } from 'react-query'; type UseDeleteVideosData = { ids: string[] }; type UseDeleteVideosError = FetchResponseError; diff --git a/src/frontend/packages/lib_video/src/api/useLiveAttendances/index.ts b/src/frontend/packages/lib_video/src/api/useLiveAttendances/index.ts index 0ee5498beb..d2ed71d8a9 100644 --- a/src/frontend/packages/lib_video/src/api/useLiveAttendances/index.ts +++ b/src/frontend/packages/lib_video/src/api/useLiveAttendances/index.ts @@ -1,10 +1,10 @@ import { APIList, - fetchList, FetchListQueryKey, LiveAttendance, + fetchList, } from 'lib-components'; -import { useQuery, UseQueryOptions } from 'react-query'; +import { UseQueryOptions, useQuery } from 'react-query'; export type LiveAttendancesResponse = APIList; export const useLiveAttendances = ( diff --git a/src/frontend/packages/lib_video/src/api/useLiveSessions/index.ts b/src/frontend/packages/lib_video/src/api/useLiveSessions/index.ts index 936c90601c..dd5936b12d 100644 --- a/src/frontend/packages/lib_video/src/api/useLiveSessions/index.ts +++ b/src/frontend/packages/lib_video/src/api/useLiveSessions/index.ts @@ -1,10 +1,10 @@ import { APIList, - fetchList, FetchListQueryKey, LiveSession, + fetchList, } from 'lib-components'; -import { useQuery, UseQueryOptions } from 'react-query'; +import { UseQueryOptions, useQuery } from 'react-query'; type LiveSessionsResponse = APIList; type UseLiveSessionsParams = { anonymous_id?: string }; diff --git a/src/frontend/packages/lib_video/src/api/usePairingVideo/index.ts b/src/frontend/packages/lib_video/src/api/usePairingVideo/index.ts index e4ce0b44eb..e748caa932 100644 --- a/src/frontend/packages/lib_video/src/api/usePairingVideo/index.ts +++ b/src/frontend/packages/lib_video/src/api/usePairingVideo/index.ts @@ -1,5 +1,5 @@ import { actionOne } from 'lib-components'; -import { useMutation, UseMutationOptions, useQueryClient } from 'react-query'; +import { UseMutationOptions, useMutation, useQueryClient } from 'react-query'; type usePairingVideoError = { code: 'exception' }; type usePairingVideoResponse = { diff --git a/src/frontend/packages/lib_video/src/api/useStartLiveRecording/index.ts b/src/frontend/packages/lib_video/src/api/useStartLiveRecording/index.ts index 6ce49ea298..cb364f57ec 100644 --- a/src/frontend/packages/lib_video/src/api/useStartLiveRecording/index.ts +++ b/src/frontend/packages/lib_video/src/api/useStartLiveRecording/index.ts @@ -1,4 +1,4 @@ -import { actionOne, useVideo, Video } from 'lib-components'; +import { Video, actionOne, useVideo } from 'lib-components'; import { useMutation, useQueryClient } from 'react-query'; export const useStartLiveRecording = (id: string, onError: () => void) => { diff --git a/src/frontend/packages/lib_video/src/api/useStartSharingMedia/index.ts b/src/frontend/packages/lib_video/src/api/useStartSharingMedia/index.ts index 626cb701a7..a4f19082e7 100644 --- a/src/frontend/packages/lib_video/src/api/useStartSharingMedia/index.ts +++ b/src/frontend/packages/lib_video/src/api/useStartSharingMedia/index.ts @@ -1,5 +1,5 @@ -import { actionOne, SharedLiveMedia } from 'lib-components'; -import { useMutation, UseMutationOptions, useQueryClient } from 'react-query'; +import { SharedLiveMedia, actionOne } from 'lib-components'; +import { UseMutationOptions, useMutation, useQueryClient } from 'react-query'; type UseStartSharingData = { sharedlivemedia: string }; type UseStartSharingError = diff --git a/src/frontend/packages/lib_video/src/api/useStopLiveRecording/index.ts b/src/frontend/packages/lib_video/src/api/useStopLiveRecording/index.ts index 548b5fb67c..e491459872 100644 --- a/src/frontend/packages/lib_video/src/api/useStopLiveRecording/index.ts +++ b/src/frontend/packages/lib_video/src/api/useStopLiveRecording/index.ts @@ -1,4 +1,4 @@ -import { actionOne, useVideo, Video } from 'lib-components'; +import { Video, actionOne, useVideo } from 'lib-components'; import { useMutation, useQueryClient } from 'react-query'; export const useStopLiveRecording = (id: string, onError: () => void) => { diff --git a/src/frontend/packages/lib_video/src/api/useStopSharingMedia/index.ts b/src/frontend/packages/lib_video/src/api/useStopSharingMedia/index.ts index 88f635daef..5664fe7098 100644 --- a/src/frontend/packages/lib_video/src/api/useStopSharingMedia/index.ts +++ b/src/frontend/packages/lib_video/src/api/useStopSharingMedia/index.ts @@ -1,5 +1,5 @@ -import { actionOne, SharedLiveMedia } from 'lib-components'; -import { useMutation, UseMutationOptions, useQueryClient } from 'react-query'; +import { SharedLiveMedia, actionOne } from 'lib-components'; +import { UseMutationOptions, useMutation, useQueryClient } from 'react-query'; type UseStopSharingData = { sharedlivemedia: string }; type UseStopSharingError = diff --git a/src/frontend/packages/lib_video/src/api/useThumbnailMetadata/index.ts b/src/frontend/packages/lib_video/src/api/useThumbnailMetadata/index.ts index d008afd1e8..bd6ac43297 100644 --- a/src/frontend/packages/lib_video/src/api/useThumbnailMetadata/index.ts +++ b/src/frontend/packages/lib_video/src/api/useThumbnailMetadata/index.ts @@ -1,5 +1,5 @@ import { FetchResponseError, metadata } from 'lib-components'; -import { useQuery, UseQueryOptions } from 'react-query'; +import { UseQueryOptions, useQuery } from 'react-query'; import { ThumbnailMetadata } from '@lib-video/types/metadata'; diff --git a/src/frontend/packages/lib_video/src/api/useTimedTextMetadata/index.ts b/src/frontend/packages/lib_video/src/api/useTimedTextMetadata/index.ts index 211041cc59..dd36c1f06f 100644 --- a/src/frontend/packages/lib_video/src/api/useTimedTextMetadata/index.ts +++ b/src/frontend/packages/lib_video/src/api/useTimedTextMetadata/index.ts @@ -1,5 +1,5 @@ import { FetchResponseError, metadata } from 'lib-components'; -import { useQuery, UseQueryOptions } from 'react-query'; +import { UseQueryOptions, useQuery } from 'react-query'; import { TimedTextMetadata } from '@lib-video/types/metadata'; diff --git a/src/frontend/packages/lib_video/src/api/useTranscriptReaderRequest/index.ts b/src/frontend/packages/lib_video/src/api/useTranscriptReaderRequest/index.ts index e8aa7a422a..a0fd4ed609 100644 --- a/src/frontend/packages/lib_video/src/api/useTranscriptReaderRequest/index.ts +++ b/src/frontend/packages/lib_video/src/api/useTranscriptReaderRequest/index.ts @@ -1,5 +1,5 @@ import { fetchWrapper } from 'lib-components'; -import { useQuery, UseQueryOptions } from 'react-query'; +import { UseQueryOptions, useQuery } from 'react-query'; export const useTranscriptReaderRequest = ( id: string, diff --git a/src/frontend/packages/lib_video/src/api/useUpdateSharedLiveMedia/index.ts b/src/frontend/packages/lib_video/src/api/useUpdateSharedLiveMedia/index.ts index 1966f162bf..8481ae61c0 100644 --- a/src/frontend/packages/lib_video/src/api/useUpdateSharedLiveMedia/index.ts +++ b/src/frontend/packages/lib_video/src/api/useUpdateSharedLiveMedia/index.ts @@ -1,5 +1,5 @@ import { SharedLiveMedia, updateOne } from 'lib-components'; -import { useMutation, UseMutationOptions, useQueryClient } from 'react-query'; +import { UseMutationOptions, useMutation, useQueryClient } from 'react-query'; type UseUpdateSharedLiveMediaData = Partial; type UseUpdateSharedLiveMediaError = diff --git a/src/frontend/packages/lib_video/src/api/useUpdateVideo/index.ts b/src/frontend/packages/lib_video/src/api/useUpdateVideo/index.ts index 8df2a471d9..ddb5ce3dd7 100644 --- a/src/frontend/packages/lib_video/src/api/useUpdateVideo/index.ts +++ b/src/frontend/packages/lib_video/src/api/useUpdateVideo/index.ts @@ -1,5 +1,5 @@ -import { updateOne, Video } from 'lib-components'; -import { useMutation, UseMutationOptions, useQueryClient } from 'react-query'; +import { Video, updateOne } from 'lib-components'; +import { UseMutationOptions, useMutation, useQueryClient } from 'react-query'; type UseUpdateVideoData = Partial