From 105c87c64de27871aa0816516ddba2f0370c18d1 Mon Sep 17 00:00:00 2001 From: mkljczk Date: Thu, 5 Dec 2024 10:28:33 +0100 Subject: [PATCH] pl-fe: move stuff around Signed-off-by: mkljczk --- packages/pl-fe/src/actions/notifications.ts | 2 +- packages/pl-fe/src/components/birthday-panel.tsx | 2 +- packages/pl-fe/src/components/sidebar-menu.tsx | 2 +- packages/pl-fe/src/components/sidebar-navigation.tsx | 2 +- .../features/compose-event/tabs/manage-pending-participants.tsx | 2 +- packages/pl-fe/src/features/directory/index.tsx | 2 +- .../features/follow-requests/components/account-authorize.tsx | 2 +- packages/pl-fe/src/features/follow-requests/index.tsx | 2 +- packages/pl-fe/src/features/ui/components/action-button.tsx | 2 +- .../pl-fe/src/features/ui/components/modals/birthdays-modal.tsx | 2 +- .../pl-fe/src/features/ui/components/modals/dislikes-modal.tsx | 2 +- .../features/ui/components/modals/event-participants-modal.tsx | 2 +- .../features/ui/components/modals/familiar-followers-modal.tsx | 2 +- .../src/features/ui/components/modals/favourites-modal.tsx | 2 +- .../pl-fe/src/features/ui/components/modals/reactions-modal.tsx | 2 +- .../pl-fe/src/features/ui/components/modals/reblogs-modal.tsx | 2 +- .../src/features/ui/components/panels/pinned-accounts-panel.tsx | 2 +- .../src/features/ui/components/profile-familiar-followers.tsx | 2 +- packages/pl-fe/src/features/ui/index.tsx | 2 +- .../{account-lists => accounts}/use-birthday-reminders.ts | 0 .../src/queries/{account-lists => accounts}/use-directory.ts | 0 .../{account-lists => accounts}/use-endorsed-accounts.ts | 0 .../{account-lists => accounts}/use-familiar-followers.ts | 0 .../queries/{account-lists => accounts}/use-follow-requests.ts | 0 .../use-event-participation-requests.ts | 0 .../{account-lists => events}/use-event-participations.ts | 0 .../{account-lists => statuses}/use-status-interactions.ts | 0 27 files changed, 19 insertions(+), 19 deletions(-) rename packages/pl-fe/src/queries/{account-lists => accounts}/use-birthday-reminders.ts (100%) rename packages/pl-fe/src/queries/{account-lists => accounts}/use-directory.ts (100%) rename packages/pl-fe/src/queries/{account-lists => accounts}/use-endorsed-accounts.ts (100%) rename packages/pl-fe/src/queries/{account-lists => accounts}/use-familiar-followers.ts (100%) rename packages/pl-fe/src/queries/{account-lists => accounts}/use-follow-requests.ts (100%) rename packages/pl-fe/src/queries/{account-lists => events}/use-event-participation-requests.ts (100%) rename packages/pl-fe/src/queries/{account-lists => events}/use-event-participations.ts (100%) rename packages/pl-fe/src/queries/{account-lists => statuses}/use-status-interactions.ts (100%) diff --git a/packages/pl-fe/src/actions/notifications.ts b/packages/pl-fe/src/actions/notifications.ts index f8c5df481..c856e2d5d 100644 --- a/packages/pl-fe/src/actions/notifications.ts +++ b/packages/pl-fe/src/actions/notifications.ts @@ -5,7 +5,7 @@ import { defineMessages } from 'react-intl'; import { getClient } from 'pl-fe/api'; import { getNotificationStatus } from 'pl-fe/features/notifications/components/notification'; import { normalizeNotification } from 'pl-fe/normalizers/notification'; -import { appendFollowRequest } from 'pl-fe/queries/account-lists/use-follow-requests'; +import { appendFollowRequest } from 'pl-fe/queries/accounts/use-follow-requests'; import { getFilters, regexFromFilters } from 'pl-fe/selectors'; import { useSettingsStore } from 'pl-fe/stores/settings'; import { isLoggedIn } from 'pl-fe/utils/auth'; diff --git a/packages/pl-fe/src/components/birthday-panel.tsx b/packages/pl-fe/src/components/birthday-panel.tsx index 8205351fd..33f7d6f7a 100644 --- a/packages/pl-fe/src/components/birthday-panel.tsx +++ b/packages/pl-fe/src/components/birthday-panel.tsx @@ -3,7 +3,7 @@ import { FormattedMessage } from 'react-intl'; import Widget from 'pl-fe/components/ui/widget'; import AccountContainer from 'pl-fe/containers/account-container'; -import { useBirthdayReminders } from 'pl-fe/queries/account-lists/use-birthday-reminders'; +import { useBirthdayReminders } from 'pl-fe/queries/accounts/use-birthday-reminders'; const timeToMidnight = () => { const now = new Date(); diff --git a/packages/pl-fe/src/components/sidebar-menu.tsx b/packages/pl-fe/src/components/sidebar-menu.tsx index d1d9669d5..e94ec5ef7 100644 --- a/packages/pl-fe/src/components/sidebar-menu.tsx +++ b/packages/pl-fe/src/components/sidebar-menu.tsx @@ -18,7 +18,7 @@ import { useAppSelector } from 'pl-fe/hooks/use-app-selector'; import { useFeatures } from 'pl-fe/hooks/use-features'; import { useInstance } from 'pl-fe/hooks/use-instance'; import { useRegistrationStatus } from 'pl-fe/hooks/use-registration-status'; -import { useFollowRequestsCount } from 'pl-fe/queries/account-lists/use-follow-requests'; +import { useFollowRequestsCount } from 'pl-fe/queries/accounts/use-follow-requests'; import { useInteractionRequestsCount } from 'pl-fe/queries/statuses/use-interaction-requests'; import { makeGetOtherAccounts } from 'pl-fe/selectors'; import { useSettingsStore } from 'pl-fe/stores/settings'; diff --git a/packages/pl-fe/src/components/sidebar-navigation.tsx b/packages/pl-fe/src/components/sidebar-navigation.tsx index ad3313a61..4d4608467 100644 --- a/packages/pl-fe/src/components/sidebar-navigation.tsx +++ b/packages/pl-fe/src/components/sidebar-navigation.tsx @@ -13,7 +13,7 @@ import { useLogo } from 'pl-fe/hooks/use-logo'; import { useOwnAccount } from 'pl-fe/hooks/use-own-account'; import { useRegistrationStatus } from 'pl-fe/hooks/use-registration-status'; import { useSettings } from 'pl-fe/hooks/use-settings'; -import { useFollowRequestsCount } from 'pl-fe/queries/account-lists/use-follow-requests'; +import { useFollowRequestsCount } from 'pl-fe/queries/accounts/use-follow-requests'; import { useInteractionRequestsCount } from 'pl-fe/queries/statuses/use-interaction-requests'; import Account from './account'; diff --git a/packages/pl-fe/src/features/compose-event/tabs/manage-pending-participants.tsx b/packages/pl-fe/src/features/compose-event/tabs/manage-pending-participants.tsx index ff38989ca..85837349f 100644 --- a/packages/pl-fe/src/features/compose-event/tabs/manage-pending-participants.tsx +++ b/packages/pl-fe/src/features/compose-event/tabs/manage-pending-participants.tsx @@ -7,7 +7,7 @@ import HStack from 'pl-fe/components/ui/hstack'; import Spinner from 'pl-fe/components/ui/spinner'; import Stack from 'pl-fe/components/ui/stack'; import AccountContainer from 'pl-fe/containers/account-container'; -import { useAcceptEventParticipationRequestMutation, useEventParticipationRequests } from 'pl-fe/queries/account-lists/use-event-participation-requests'; +import { useAcceptEventParticipationRequestMutation, useEventParticipationRequests } from 'pl-fe/queries/events/use-event-participation-requests'; const messages = defineMessages({ authorize: { id: 'compose_event.participation_requests.authorize', defaultMessage: 'Authorize' }, diff --git a/packages/pl-fe/src/features/directory/index.tsx b/packages/pl-fe/src/features/directory/index.tsx index a50812eaf..656061982 100644 --- a/packages/pl-fe/src/features/directory/index.tsx +++ b/packages/pl-fe/src/features/directory/index.tsx @@ -10,7 +10,7 @@ import Column from 'pl-fe/components/ui/column'; import Stack from 'pl-fe/components/ui/stack'; import { useFeatures } from 'pl-fe/hooks/use-features'; import { useInstance } from 'pl-fe/hooks/use-instance'; -import { useDirectory } from 'pl-fe/queries/account-lists/use-directory'; +import { useDirectory } from 'pl-fe/queries/accounts/use-directory'; import AccountCard from './components/account-card'; diff --git a/packages/pl-fe/src/features/follow-requests/components/account-authorize.tsx b/packages/pl-fe/src/features/follow-requests/components/account-authorize.tsx index ea3b04f5f..691821f02 100644 --- a/packages/pl-fe/src/features/follow-requests/components/account-authorize.tsx +++ b/packages/pl-fe/src/features/follow-requests/components/account-authorize.tsx @@ -3,7 +3,7 @@ import React from 'react'; import { useAccount } from 'pl-fe/api/hooks/accounts/use-account'; import Account from 'pl-fe/components/account'; import { AuthorizeRejectButtons } from 'pl-fe/components/authorize-reject-buttons'; -import { useAcceptFollowRequestMutation, useRejectFollowRequestMutation } from 'pl-fe/queries/account-lists/use-follow-requests'; +import { useAcceptFollowRequestMutation, useRejectFollowRequestMutation } from 'pl-fe/queries/accounts/use-follow-requests'; interface IAccountAuthorize { id: string; diff --git a/packages/pl-fe/src/features/follow-requests/index.tsx b/packages/pl-fe/src/features/follow-requests/index.tsx index 635c4f292..27c9b64dd 100644 --- a/packages/pl-fe/src/features/follow-requests/index.tsx +++ b/packages/pl-fe/src/features/follow-requests/index.tsx @@ -4,7 +4,7 @@ import { defineMessages, useIntl, FormattedMessage } from 'react-intl'; import ScrollableList from 'pl-fe/components/scrollable-list'; import Column from 'pl-fe/components/ui/column'; import Spinner from 'pl-fe/components/ui/spinner'; -import { useFollowRequests } from 'pl-fe/queries/account-lists/use-follow-requests'; +import { useFollowRequests } from 'pl-fe/queries/accounts/use-follow-requests'; import AccountAuthorize from './components/account-authorize'; diff --git a/packages/pl-fe/src/features/ui/components/action-button.tsx b/packages/pl-fe/src/features/ui/components/action-button.tsx index 43ee8da84..5c386c41f 100644 --- a/packages/pl-fe/src/features/ui/components/action-button.tsx +++ b/packages/pl-fe/src/features/ui/components/action-button.tsx @@ -14,7 +14,7 @@ import HStack from 'pl-fe/components/ui/hstack'; import { useAppDispatch } from 'pl-fe/hooks/use-app-dispatch'; import { useFeatures } from 'pl-fe/hooks/use-features'; import { useLoggedIn } from 'pl-fe/hooks/use-logged-in'; -import { useAcceptFollowRequestMutation, useRejectFollowRequestMutation } from 'pl-fe/queries/account-lists/use-follow-requests'; +import { useAcceptFollowRequestMutation, useRejectFollowRequestMutation } from 'pl-fe/queries/accounts/use-follow-requests'; import { useModalsStore } from 'pl-fe/stores/modals'; import toast from 'pl-fe/toast'; diff --git a/packages/pl-fe/src/features/ui/components/modals/birthdays-modal.tsx b/packages/pl-fe/src/features/ui/components/modals/birthdays-modal.tsx index d70e950d6..ef0c1c2f1 100644 --- a/packages/pl-fe/src/features/ui/components/modals/birthdays-modal.tsx +++ b/packages/pl-fe/src/features/ui/components/modals/birthdays-modal.tsx @@ -6,7 +6,7 @@ import ScrollableList from 'pl-fe/components/scrollable-list'; import Modal from 'pl-fe/components/ui/modal'; import Spinner from 'pl-fe/components/ui/spinner'; import Account from 'pl-fe/features/birthdays/account'; -import { useBirthdayReminders } from 'pl-fe/queries/account-lists/use-birthday-reminders'; +import { useBirthdayReminders } from 'pl-fe/queries/accounts/use-birthday-reminders'; import type { BaseModalProps } from '../modal-root'; diff --git a/packages/pl-fe/src/features/ui/components/modals/dislikes-modal.tsx b/packages/pl-fe/src/features/ui/components/modals/dislikes-modal.tsx index 9ce92c06a..cf58f788d 100644 --- a/packages/pl-fe/src/features/ui/components/modals/dislikes-modal.tsx +++ b/packages/pl-fe/src/features/ui/components/modals/dislikes-modal.tsx @@ -5,7 +5,7 @@ import ScrollableList from 'pl-fe/components/scrollable-list'; import Modal from 'pl-fe/components/ui/modal'; import Spinner from 'pl-fe/components/ui/spinner'; import AccountContainer from 'pl-fe/containers/account-container'; -import { useStatusDislikes } from 'pl-fe/queries/account-lists/use-status-interactions'; +import { useStatusDislikes } from 'pl-fe/queries/statuses/use-status-interactions'; import type { BaseModalProps } from '../modal-root'; diff --git a/packages/pl-fe/src/features/ui/components/modals/event-participants-modal.tsx b/packages/pl-fe/src/features/ui/components/modals/event-participants-modal.tsx index e1d696753..5cf2657b4 100644 --- a/packages/pl-fe/src/features/ui/components/modals/event-participants-modal.tsx +++ b/packages/pl-fe/src/features/ui/components/modals/event-participants-modal.tsx @@ -5,7 +5,7 @@ import ScrollableList from 'pl-fe/components/scrollable-list'; import Modal from 'pl-fe/components/ui/modal'; import Spinner from 'pl-fe/components/ui/spinner'; import AccountContainer from 'pl-fe/containers/account-container'; -import { useEventParticipations } from 'pl-fe/queries/account-lists/use-event-participations'; +import { useEventParticipations } from 'pl-fe/queries/events/use-event-participations'; import type { BaseModalProps } from '../modal-root'; diff --git a/packages/pl-fe/src/features/ui/components/modals/familiar-followers-modal.tsx b/packages/pl-fe/src/features/ui/components/modals/familiar-followers-modal.tsx index 51ea74352..136e15f8a 100644 --- a/packages/pl-fe/src/features/ui/components/modals/familiar-followers-modal.tsx +++ b/packages/pl-fe/src/features/ui/components/modals/familiar-followers-modal.tsx @@ -7,7 +7,7 @@ import Spinner from 'pl-fe/components/ui/spinner'; import AccountContainer from 'pl-fe/containers/account-container'; import Emojify from 'pl-fe/features/emoji/emojify'; import { useAppSelector } from 'pl-fe/hooks/use-app-selector'; -import { useFamiliarFollowers } from 'pl-fe/queries/account-lists/use-familiar-followers'; +import { useFamiliarFollowers } from 'pl-fe/queries/accounts/use-familiar-followers'; import { makeGetAccount } from 'pl-fe/selectors'; import type { BaseModalProps } from '../modal-root'; diff --git a/packages/pl-fe/src/features/ui/components/modals/favourites-modal.tsx b/packages/pl-fe/src/features/ui/components/modals/favourites-modal.tsx index bc4fad0bd..0cbffdc6a 100644 --- a/packages/pl-fe/src/features/ui/components/modals/favourites-modal.tsx +++ b/packages/pl-fe/src/features/ui/components/modals/favourites-modal.tsx @@ -5,7 +5,7 @@ import ScrollableList from 'pl-fe/components/scrollable-list'; import Modal from 'pl-fe/components/ui/modal'; import Spinner from 'pl-fe/components/ui/spinner'; import AccountContainer from 'pl-fe/containers/account-container'; -import { useStatusFavourites } from 'pl-fe/queries/account-lists/use-status-interactions'; +import { useStatusFavourites } from 'pl-fe/queries/statuses/use-status-interactions'; import type { BaseModalProps } from '../modal-root'; diff --git a/packages/pl-fe/src/features/ui/components/modals/reactions-modal.tsx b/packages/pl-fe/src/features/ui/components/modals/reactions-modal.tsx index 779778ec9..72e574e2c 100644 --- a/packages/pl-fe/src/features/ui/components/modals/reactions-modal.tsx +++ b/packages/pl-fe/src/features/ui/components/modals/reactions-modal.tsx @@ -8,7 +8,7 @@ import Modal from 'pl-fe/components/ui/modal'; import Spinner from 'pl-fe/components/ui/spinner'; import Tabs from 'pl-fe/components/ui/tabs'; import AccountContainer from 'pl-fe/containers/account-container'; -import { useStatusReactions } from 'pl-fe/queries/account-lists/use-status-interactions'; +import { useStatusReactions } from 'pl-fe/queries/statuses/use-status-interactions'; import type { BaseModalProps } from '../modal-root'; import type { Item } from 'pl-fe/components/ui/tabs'; diff --git a/packages/pl-fe/src/features/ui/components/modals/reblogs-modal.tsx b/packages/pl-fe/src/features/ui/components/modals/reblogs-modal.tsx index e011ec2de..45d968930 100644 --- a/packages/pl-fe/src/features/ui/components/modals/reblogs-modal.tsx +++ b/packages/pl-fe/src/features/ui/components/modals/reblogs-modal.tsx @@ -5,7 +5,7 @@ import ScrollableList from 'pl-fe/components/scrollable-list'; import Modal from 'pl-fe/components/ui/modal'; import Spinner from 'pl-fe/components/ui/spinner'; import AccountContainer from 'pl-fe/containers/account-container'; -import { useStatusReblogs } from 'pl-fe/queries/account-lists/use-status-interactions'; +import { useStatusReblogs } from 'pl-fe/queries/statuses/use-status-interactions'; import type { BaseModalProps } from '../modal-root'; diff --git a/packages/pl-fe/src/features/ui/components/panels/pinned-accounts-panel.tsx b/packages/pl-fe/src/features/ui/components/panels/pinned-accounts-panel.tsx index a08e1b89a..122756e4c 100644 --- a/packages/pl-fe/src/features/ui/components/panels/pinned-accounts-panel.tsx +++ b/packages/pl-fe/src/features/ui/components/panels/pinned-accounts-panel.tsx @@ -5,7 +5,7 @@ import Widget from 'pl-fe/components/ui/widget'; import AccountContainer from 'pl-fe/containers/account-container'; import Emojify from 'pl-fe/features/emoji/emojify'; import { WhoToFollowPanel } from 'pl-fe/features/ui/util/async-components'; -import { useEndorsedAccounts } from 'pl-fe/queries/account-lists/use-endorsed-accounts'; +import { useEndorsedAccounts } from 'pl-fe/queries/accounts/use-endorsed-accounts'; import type { Account } from 'pl-fe/normalizers/account'; diff --git a/packages/pl-fe/src/features/ui/components/profile-familiar-followers.tsx b/packages/pl-fe/src/features/ui/components/profile-familiar-followers.tsx index d7088e5ab..21acbb366 100644 --- a/packages/pl-fe/src/features/ui/components/profile-familiar-followers.tsx +++ b/packages/pl-fe/src/features/ui/components/profile-familiar-followers.tsx @@ -9,7 +9,7 @@ import Text from 'pl-fe/components/ui/text'; import VerificationBadge from 'pl-fe/components/verification-badge'; import Emojify from 'pl-fe/features/emoji/emojify'; import { useAppSelector } from 'pl-fe/hooks/use-app-selector'; -import { useFamiliarFollowers } from 'pl-fe/queries/account-lists/use-familiar-followers'; +import { useFamiliarFollowers } from 'pl-fe/queries/accounts/use-familiar-followers'; import { makeGetAccount } from 'pl-fe/selectors'; import { useModalsStore } from 'pl-fe/stores/modals'; diff --git a/packages/pl-fe/src/features/ui/index.tsx b/packages/pl-fe/src/features/ui/index.tsx index 59a60c3c5..4963019f8 100644 --- a/packages/pl-fe/src/features/ui/index.tsx +++ b/packages/pl-fe/src/features/ui/index.tsx @@ -40,7 +40,7 @@ import ProfileLayout from 'pl-fe/layouts/profile-layout'; import RemoteInstanceLayout from 'pl-fe/layouts/remote-instance-layout'; import SearchLayout from 'pl-fe/layouts/search-layout'; import StatusLayout from 'pl-fe/layouts/status-layout'; -import { prefetchFollowRequests } from 'pl-fe/queries/account-lists/use-follow-requests'; +import { prefetchFollowRequests } from 'pl-fe/queries/accounts/use-follow-requests'; import { useUiStore } from 'pl-fe/stores/ui'; import { getVapidKey } from 'pl-fe/utils/auth'; import { isStandalone } from 'pl-fe/utils/state'; diff --git a/packages/pl-fe/src/queries/account-lists/use-birthday-reminders.ts b/packages/pl-fe/src/queries/accounts/use-birthday-reminders.ts similarity index 100% rename from packages/pl-fe/src/queries/account-lists/use-birthday-reminders.ts rename to packages/pl-fe/src/queries/accounts/use-birthday-reminders.ts diff --git a/packages/pl-fe/src/queries/account-lists/use-directory.ts b/packages/pl-fe/src/queries/accounts/use-directory.ts similarity index 100% rename from packages/pl-fe/src/queries/account-lists/use-directory.ts rename to packages/pl-fe/src/queries/accounts/use-directory.ts diff --git a/packages/pl-fe/src/queries/account-lists/use-endorsed-accounts.ts b/packages/pl-fe/src/queries/accounts/use-endorsed-accounts.ts similarity index 100% rename from packages/pl-fe/src/queries/account-lists/use-endorsed-accounts.ts rename to packages/pl-fe/src/queries/accounts/use-endorsed-accounts.ts diff --git a/packages/pl-fe/src/queries/account-lists/use-familiar-followers.ts b/packages/pl-fe/src/queries/accounts/use-familiar-followers.ts similarity index 100% rename from packages/pl-fe/src/queries/account-lists/use-familiar-followers.ts rename to packages/pl-fe/src/queries/accounts/use-familiar-followers.ts diff --git a/packages/pl-fe/src/queries/account-lists/use-follow-requests.ts b/packages/pl-fe/src/queries/accounts/use-follow-requests.ts similarity index 100% rename from packages/pl-fe/src/queries/account-lists/use-follow-requests.ts rename to packages/pl-fe/src/queries/accounts/use-follow-requests.ts diff --git a/packages/pl-fe/src/queries/account-lists/use-event-participation-requests.ts b/packages/pl-fe/src/queries/events/use-event-participation-requests.ts similarity index 100% rename from packages/pl-fe/src/queries/account-lists/use-event-participation-requests.ts rename to packages/pl-fe/src/queries/events/use-event-participation-requests.ts diff --git a/packages/pl-fe/src/queries/account-lists/use-event-participations.ts b/packages/pl-fe/src/queries/events/use-event-participations.ts similarity index 100% rename from packages/pl-fe/src/queries/account-lists/use-event-participations.ts rename to packages/pl-fe/src/queries/events/use-event-participations.ts diff --git a/packages/pl-fe/src/queries/account-lists/use-status-interactions.ts b/packages/pl-fe/src/queries/statuses/use-status-interactions.ts similarity index 100% rename from packages/pl-fe/src/queries/account-lists/use-status-interactions.ts rename to packages/pl-fe/src/queries/statuses/use-status-interactions.ts