From b4c81974ab3c417c281b5f6e422261331216e618 Mon Sep 17 00:00:00 2001 From: Matiss Janis Aboltins Date: Thu, 12 Mar 2026 21:47:55 +0000 Subject: [PATCH] [AI] Move desktop-client to subpath imports --- .oxfmtrc.json | 2 +- packages/desktop-client/package.json | 8 ++ .../src/accounts/accountsSlice.ts | 2 +- .../desktop-client/src/accounts/mutations.ts | 14 ++-- packages/desktop-client/src/app/appSlice.ts | 8 +- .../desktop-client/src/auth/AuthProvider.tsx | 4 +- .../src/auth/ProtectedRoute.tsx | 4 +- .../desktop-client/src/budget/mutations.ts | 8 +- .../src/budgetfiles/budgetfilesSlice.ts | 10 +-- .../desktop-client/src/components/App.tsx | 33 ++++---- .../src/components/AppBackground.tsx | 2 +- .../src/components/BankSyncStatus.tsx | 2 +- .../src/components/CommandBar.tsx | 20 ++--- .../src/components/FatalError.tsx | 2 +- .../src/components/FinancesApp.tsx | 24 +++--- .../src/components/GlobalKeys.ts | 2 +- .../src/components/HelpMenu.tsx | 6 +- .../src/components/LoggedInUser.tsx | 14 ++-- .../src/components/ManageRules.tsx | 17 ++-- .../desktop-client/src/components/Modals.tsx | 10 +-- .../desktop-client/src/components/Notes.tsx | 2 +- .../src/components/NotesButton.tsx | 2 +- .../src/components/Notifications.tsx | 6 +- .../src/components/PrivacyFilter.tsx | 2 +- .../src/components/ServerContext.tsx | 6 +- .../src/components/ThemeSelector.tsx | 2 +- .../src/components/Titlebar.tsx | 18 ++--- .../src/components/UpdateNotification.tsx | 4 +- .../src/components/accounts/Account.tsx | 62 +++++++------- .../components/accounts/AccountSyncCheck.tsx | 12 +-- .../src/components/accounts/Balance.tsx | 19 ++--- .../accounts/BalanceHistoryGraph.tsx | 12 +-- .../src/components/accounts/Header.tsx | 26 +++--- .../components/accounts/Reconcile.test.tsx | 6 +- .../src/components/accounts/Reconcile.tsx | 10 +-- .../admin/UserAccess/UserAccess.tsx | 14 ++-- .../admin/UserAccess/UserAccessHeader.tsx | 2 +- .../admin/UserAccess/UserAccessPage.tsx | 2 +- .../admin/UserAccess/UserAccessRow.tsx | 12 +-- .../admin/UserDirectory/UserDirectory.tsx | 19 ++--- .../UserDirectory/UserDirectoryHeader.tsx | 11 +-- .../admin/UserDirectory/UserDirectoryPage.tsx | 4 +- .../admin/UserDirectory/UserDirectoryRow.tsx | 6 +- .../autocomplete/AccountAutocomplete.tsx | 2 +- .../components/autocomplete/Autocomplete.tsx | 2 +- .../autocomplete/CategoryAutocomplete.tsx | 17 ++-- .../CategoryGroupAutocomplete.tsx | 2 +- .../autocomplete/FilterAutocomplete.tsx | 2 +- .../autocomplete/PayeeAutocomplete.test.tsx | 10 +-- .../autocomplete/PayeeAutocomplete.tsx | 10 +-- .../autocomplete/ReportAutocomplete.tsx | 2 +- .../src/components/banksync/AccountRow.tsx | 2 +- .../components/banksync/AccountsHeader.tsx | 2 +- .../src/components/banksync/AccountsList.tsx | 2 +- .../banksync/BankSyncCheckboxOptions.tsx | 4 +- .../components/banksync/EditSyncAccount.tsx | 12 +-- .../src/components/banksync/FieldMapping.tsx | 2 +- .../src/components/banksync/index.tsx | 12 +-- .../banksync/useBankSyncAccountSettings.ts | 4 +- .../budget/BalanceWithCarryover.tsx | 13 ++- .../components/budget/BudgetCategories.tsx | 11 +-- .../components/budget/BudgetPageHeader.tsx | 2 +- .../src/components/budget/BudgetSummaries.tsx | 2 +- .../src/components/budget/BudgetTable.tsx | 10 +-- .../src/components/budget/BudgetTotals.tsx | 2 +- .../components/budget/DynamicBudgetTable.tsx | 2 +- .../src/components/budget/ExpenseCategory.tsx | 12 +-- .../src/components/budget/ExpenseGroup.tsx | 12 +-- .../src/components/budget/IncomeCategory.tsx | 15 +--- .../src/components/budget/IncomeGroup.tsx | 2 +- .../src/components/budget/IncomeHeader.tsx | 2 +- .../src/components/budget/MonthPicker.tsx | 6 +- .../src/components/budget/RenderMonths.tsx | 2 +- .../src/components/budget/SidebarCategory.tsx | 6 +- .../budget/SidebarCategoryButtons.tsx | 6 +- .../src/components/budget/SidebarGroup.tsx | 10 +-- .../budget/envelope/BalanceMenu.tsx | 2 +- .../budget/envelope/BalanceMovementMenu.tsx | 4 +- .../components/budget/envelope/BudgetMenu.tsx | 2 +- .../components/budget/envelope/CoverMenu.tsx | 6 +- .../envelope/EnvelopeBudgetComponents.tsx | 31 ++++--- .../components/budget/envelope/HoldMenu.tsx | 4 +- .../components/budget/envelope/IncomeMenu.tsx | 2 +- .../budget/envelope/TransferMenu.tsx | 8 +- .../budgetsummary/BudgetMonthMenu.tsx | 2 +- .../envelope/budgetsummary/BudgetSummary.tsx | 10 +-- .../envelope/budgetsummary/ToBudget.tsx | 14 ++-- .../envelope/budgetsummary/ToBudgetAmount.tsx | 10 +-- .../envelope/budgetsummary/ToBudgetMenu.tsx | 4 +- .../envelope/budgetsummary/TotalsList.tsx | 10 +-- .../budget/goals/BudgetAutomation.tsx | 2 +- .../budget/goals/BudgetAutomationEditor.tsx | 6 +- .../budget/goals/CategoryAutomationButton.tsx | 6 +- .../goals/editor/HistoricalAutomation.tsx | 8 +- .../budget/goals/editor/LimitAutomation.tsx | 12 +-- .../goals/editor/LimitAutomationReadOnly.tsx | 2 +- .../goals/editor/PercentageAutomation.tsx | 10 +-- .../budget/goals/editor/RefillAutomation.tsx | 2 +- .../goals/editor/ScheduleAutomation.tsx | 8 +- .../budget/goals/editor/WeekAutomation.tsx | 8 +- .../goals/editor/WeekAutomationReadOnly.tsx | 4 +- .../goals/useBudgetAutomationCategories.ts | 2 +- .../src/components/budget/index.tsx | 16 ++-- .../budget/tracking/BalanceMenu.tsx | 2 +- .../components/budget/tracking/BudgetMenu.tsx | 2 +- .../tracking/TrackingBudgetComponents.tsx | 27 +++---- .../budgetsummary/BudgetMonthMenu.tsx | 2 +- .../tracking/budgetsummary/BudgetSummary.tsx | 10 +-- .../tracking/budgetsummary/BudgetTotal.tsx | 4 +- .../budgetsummary/ExpenseProgress.tsx | 4 +- .../tracking/budgetsummary/ExpenseTotal.tsx | 2 +- .../tracking/budgetsummary/IncomeProgress.tsx | 4 +- .../tracking/budgetsummary/IncomeTotal.tsx | 2 +- .../budget/tracking/budgetsummary/Saved.tsx | 12 +-- .../src/components/budget/util.ts | 4 +- .../src/components/common/Link.tsx | 2 +- .../src/components/common/Modal.tsx | 2 +- .../components/filters/ConditionsOpMenu.tsx | 2 +- .../components/filters/FilterExpression.tsx | 2 +- .../src/components/filters/FiltersMenu.tsx | 8 +- .../src/components/filters/NameFilter.tsx | 2 +- .../src/components/filters/PayeeFilter.tsx | 2 +- .../src/components/formula/FormulaEditor.tsx | 4 +- .../src/components/formula/QueryManager.tsx | 20 ++--- .../components/gocardless/GoCardlessLink.tsx | 2 +- .../manager/BudgetFileSelection.tsx | 16 ++-- .../src/components/manager/ConfigServer.tsx | 19 ++--- .../src/components/manager/ManagementApp.tsx | 22 ++--- .../src/components/manager/ServerURL.tsx | 4 +- .../src/components/manager/WelcomeScreen.tsx | 8 +- .../manager/subscribe/Bootstrap.tsx | 10 +-- .../manager/subscribe/ChangePassword.tsx | 2 +- .../components/manager/subscribe/Error.tsx | 2 +- .../components/manager/subscribe/Login.tsx | 10 +-- .../manager/subscribe/OpenIdCallback.ts | 4 +- .../manager/subscribe/OpenIdForm.tsx | 6 +- .../components/manager/subscribe/common.tsx | 4 +- .../components/mobile/MobileBackButton.tsx | 2 +- .../src/components/mobile/MobileNavTabs.tsx | 6 +- .../mobile/accounts/AccountPage.tsx | 21 +++-- .../mobile/accounts/AccountTransactions.tsx | 32 ++++---- .../mobile/accounts/AccountsPage.tsx | 36 ++++----- .../accounts/AllAccountTransactions.tsx | 24 +++--- .../accounts/OffBudgetAccountTransactions.tsx | 26 +++--- .../accounts/OnBudgetAccountTransactions.tsx | 26 +++--- .../mobile/banksync/BankSyncAccountsList.tsx | 2 +- .../banksync/BankSyncAccountsListItem.tsx | 2 +- .../MobileBankSyncAccountEditPage.tsx | 20 ++--- .../mobile/banksync/MobileBankSyncPage.tsx | 12 +-- .../components/mobile/budget/BalanceCell.tsx | 15 ++-- .../components/mobile/budget/BudgetCell.tsx | 20 ++--- .../components/mobile/budget/BudgetPage.tsx | 46 +++++------ .../components/mobile/budget/BudgetTable.tsx | 25 +++--- .../mobile/budget/CategoryGroupActionMenu.tsx | 2 +- .../components/mobile/budget/CategoryPage.tsx | 12 +-- .../mobile/budget/CategoryTransactions.tsx | 16 ++-- .../mobile/budget/ExpenseCategoryList.tsx | 2 +- .../mobile/budget/ExpenseCategoryListItem.tsx | 21 +++-- .../mobile/budget/ExpenseGroupList.tsx | 2 +- .../mobile/budget/ExpenseGroupListItem.tsx | 13 ++- .../mobile/budget/IncomeCategoryList.tsx | 2 +- .../mobile/budget/IncomeCategoryListItem.tsx | 13 ++- .../components/mobile/budget/IncomeGroup.tsx | 13 ++- .../components/mobile/budget/SpentCell.tsx | 12 +-- .../budget/UncategorizedTransactions.tsx | 16 ++-- .../mobile/payees/MobilePayeeEditPage.tsx | 16 ++-- .../mobile/payees/MobilePayeesPage.test.tsx | 8 +- .../mobile/payees/MobilePayeesPage.tsx | 16 ++-- .../components/mobile/payees/PayeesList.tsx | 2 +- .../mobile/payees/PayeesListItem.tsx | 4 +- .../components/mobile/rules/AddRuleButton.tsx | 2 +- .../mobile/rules/MobileRuleEditPage.tsx | 18 ++--- .../mobile/rules/MobileRulesPage.tsx | 24 +++--- .../src/components/mobile/rules/RulesList.tsx | 2 +- .../components/mobile/rules/RulesListItem.tsx | 8 +- .../mobile/schedules/AddScheduleButton.tsx | 2 +- .../schedules/MobileScheduleEditPage.tsx | 18 ++--- .../mobile/schedules/MobileSchedulesPage.tsx | 22 ++--- .../mobile/schedules/SchedulesList.tsx | 4 +- .../mobile/schedules/SchedulesListItem.tsx | 10 +-- .../transactions/AddTransactionButton.tsx | 2 +- .../transactions/FocusableAmountInput.tsx | 6 +- .../mobile/transactions/TransactionEdit.tsx | 48 +++++------ .../mobile/transactions/TransactionList.tsx | 27 +++---- .../transactions/TransactionListItem.tsx | 16 ++-- .../TransactionListWithBalances.tsx | 24 ++---- .../modals/AccountAutocompleteModal.tsx | 8 +- .../components/modals/AccountMenuModal.tsx | 16 ++-- .../modals/BudgetAutomationsModal.tsx | 30 +++---- .../components/modals/BudgetPageMenuModal.tsx | 10 +-- .../modals/CategoryAutocompleteModal.tsx | 10 +-- .../modals/CategoryGroupAutocompleteModal.tsx | 10 +-- .../modals/CategoryGroupMenuModal.tsx | 16 ++-- .../components/modals/CategoryMenuModal.tsx | 12 +-- .../components/modals/CloseAccountModal.tsx | 24 +++--- .../modals/ConfirmCategoryDeleteModal.tsx | 12 +-- .../components/modals/ConfirmDeleteModal.tsx | 8 +- .../modals/ConfirmTransactionEditModal.tsx | 8 +- .../modals/ConfirmUnlinkAccountModal.tsx | 8 +- .../modals/ConvertToScheduleModal.tsx | 8 +- .../modals/CopyWidgetToDashboardModal.tsx | 10 +-- .../src/components/modals/CoverModal.tsx | 27 +++---- .../components/modals/CreateAccountModal.tsx | 34 ++++---- .../modals/CreateEncryptionKeyModal.tsx | 14 ++-- .../modals/CreateLocalAccountModal.tsx | 18 ++--- .../src/components/modals/EditAccess.tsx | 18 ++--- .../src/components/modals/EditFieldModal.tsx | 16 ++-- .../src/components/modals/EditRuleModal.tsx | 8 +- .../src/components/modals/EditUser.tsx | 22 ++--- .../modals/EnvelopeBalanceMenuModal.tsx | 14 ++-- .../modals/EnvelopeBudgetMenuModal.tsx | 14 ++-- .../modals/EnvelopeBudgetMonthMenuModal.tsx | 18 ++--- .../modals/EnvelopeBudgetSummaryModal.tsx | 30 +++---- .../modals/EnvelopeIncomeBalanceMenuModal.tsx | 14 ++-- .../modals/EnvelopeToBudgetMenuModal.tsx | 10 +-- .../modals/FixEncryptionKeyModal.tsx | 6 +- .../GoCardlessExternalMsgModal.test.tsx | 6 +- .../modals/GoCardlessExternalMsgModal.tsx | 28 +++---- .../modals/GoCardlessInitialiseModal.tsx | 10 +-- .../components/modals/GoalTemplateModal.tsx | 10 +-- .../src/components/modals/HoldBufferModal.tsx | 18 ++--- .../DateFormatSelect.tsx | 2 +- .../ImportTransactionsModal/FieldMappings.tsx | 2 +- .../ImportTransactionsModal.tsx | 25 +++--- .../ImportTransactionsModal/InOutOption.tsx | 2 +- .../MultiplierOption.tsx | 2 +- .../ImportTransactionsModal/Transaction.tsx | 4 +- .../modals/KeyboardShortcutModal.tsx | 8 +- .../src/components/modals/LoadBackupModal.tsx | 19 ++--- .../components/modals/ManageRulesModal.tsx | 10 +-- .../modals/MergeUnusedPayeesModal.tsx | 12 +-- .../modals/NewCategoryGroupModal.tsx | 7 +- .../components/modals/NewCategoryModal.tsx | 7 +- .../src/components/modals/NotesModal.tsx | 12 +-- .../components/modals/OpenIDEnableModal.tsx | 20 ++--- .../modals/OutOfSyncMigrationsModal.tsx | 12 +-- .../components/modals/PasswordEnableModal.tsx | 22 +++-- .../modals/PayeeAutocompleteModal.tsx | 12 +-- .../modals/PluggyAiInitialiseModal.tsx | 10 +-- .../modals/ScheduledTransactionMenuModal.tsx | 8 +- .../modals/SelectLinkedAccountsModal.tsx | 40 ++++------ .../modals/SimpleFinInitialiseModal.tsx | 10 +-- .../components/modals/SingleInputModal.tsx | 9 +-- .../modals/TrackingBalanceMenuModal.tsx | 14 ++-- .../modals/TrackingBudgetMenuModal.tsx | 14 ++-- .../modals/TrackingBudgetMonthMenuModal.tsx | 18 ++--- .../modals/TrackingBudgetSummaryModal.tsx | 16 ++-- .../src/components/modals/TransferModal.tsx | 25 +++--- .../components/modals/TransferOwnership.tsx | 20 ++--- .../UnmigrateBudgetAutomationsModal.tsx | 14 ++-- .../manager/ConfirmChangeDocumentDir.tsx | 16 ++-- .../modals/manager/DeleteFileModal.tsx | 14 ++-- .../modals/manager/DuplicateFileModal.tsx | 10 +-- .../modals/manager/FilesSettingsModal.tsx | 14 ++-- .../modals/manager/ImportActualModal.tsx | 12 +-- .../components/modals/manager/ImportModal.tsx | 10 +-- .../modals/manager/ImportYNAB4Modal.tsx | 12 +-- .../modals/manager/ImportYNAB5Modal.tsx | 14 ++-- .../components/payees/CategoryLearning.tsx | 10 +-- .../src/components/payees/ManagePayees.tsx | 14 ++-- .../components/payees/ManagePayeesPage.tsx | 2 +- .../payees/ManagePayeesWithData.tsx | 12 +-- .../src/components/payees/PayeeMenu.tsx | 2 +- .../src/components/payees/PayeeTable.tsx | 4 +- .../src/components/payees/PayeeTableRow.tsx | 11 +-- .../components/reports/AccountSelector.tsx | 2 +- .../components/reports/CategorySelector.tsx | 2 +- .../src/components/reports/Change.test.tsx | 2 +- .../src/components/reports/Change.tsx | 4 +- .../components/reports/DashboardHeader.tsx | 2 +- .../components/reports/DashboardSelector.tsx | 4 +- .../src/components/reports/DateRange.tsx | 2 +- .../src/components/reports/FormulaResult.tsx | 8 +- .../src/components/reports/Header.tsx | 6 +- .../src/components/reports/Overview.tsx | 26 +++--- .../src/components/reports/ReportCard.tsx | 6 +- .../src/components/reports/ReportRouter.tsx | 2 +- .../src/components/reports/ReportSidebar.tsx | 4 +- .../src/components/reports/ReportSummary.tsx | 8 +- .../src/components/reports/ReportTopbar.tsx | 2 +- .../reports/ReportsDashboardRouter.tsx | 4 +- .../src/components/reports/SaveReport.tsx | 8 +- .../components/reports/SaveReportChoose.tsx | 2 +- .../src/components/reports/SaveReportName.tsx | 2 +- .../src/components/reports/SummaryNumber.tsx | 10 +-- .../src/components/reports/chart-theme.ts | 2 +- .../components/reports/graphs/AreaGraph.tsx | 12 +-- .../components/reports/graphs/BarGraph.tsx | 22 ++--- .../reports/graphs/BarLineGraph.tsx | 10 +-- .../reports/graphs/BudgetAnalysisGraph.tsx | 12 +-- .../reports/graphs/CalendarGraph.tsx | 8 +- .../reports/graphs/CashFlowGraph.tsx | 14 ++-- .../reports/graphs/CrossoverGraph.tsx | 10 +-- .../components/reports/graphs/DonutGraph.tsx | 16 ++-- .../components/reports/graphs/LineGraph.tsx | 22 ++--- .../reports/graphs/NetWorthGraph.tsx | 14 ++-- .../reports/graphs/SpendingGraph.tsx | 14 ++-- .../reports/graphs/StackedBarGraph.tsx | 22 ++--- .../reports/graphs/renderCustomLabel.tsx | 4 +- .../components/reports/graphs/showActivity.ts | 2 +- .../graphs/tableGraph/ReportTableHeader.tsx | 4 +- .../graphs/tableGraph/ReportTableList.tsx | 2 +- .../graphs/tableGraph/ReportTableRow.tsx | 14 ++-- .../src/components/reports/index.tsx | 2 +- .../reports/reports/BudgetAnalysis.tsx | 48 +++++------ .../reports/reports/BudgetAnalysisCard.tsx | 24 +++--- .../components/reports/reports/Calendar.tsx | 80 +++++++++---------- .../reports/reports/CalendarCard.tsx | 34 ++++---- .../components/reports/reports/CashFlow.tsx | 46 +++++------ .../reports/reports/CashFlowCard.tsx | 28 +++---- .../components/reports/reports/Crossover.tsx | 56 ++++++------- .../reports/reports/CrossoverCard.tsx | 24 +++--- .../reports/reports/CustomReport.tsx | 71 ++++++++-------- .../reports/reports/CustomReportListCards.tsx | 24 +++--- .../components/reports/reports/Formula.tsx | 30 +++---- .../reports/reports/FormulaCard.tsx | 12 +-- .../reports/reports/GetCardData.tsx | 14 ++-- .../reports/reports/MarkdownCard.tsx | 8 +- .../reports/reports/MissingReportCard.tsx | 2 +- .../components/reports/reports/NetWorth.tsx | 52 ++++++------ .../reports/reports/NetWorthCard.tsx | 30 +++---- .../components/reports/reports/Spending.tsx | 48 +++++------ .../reports/reports/SpendingCard.tsx | 24 +++--- .../components/reports/reports/Summary.tsx | 52 ++++++------ .../reports/reports/SummaryCard.tsx | 20 ++--- .../budget-analysis-spreadsheet.ts | 2 +- .../reports/spreadsheets/calculateLegend.ts | 2 +- .../spreadsheets/calendar-spreadsheet.ts | 4 +- .../spreadsheets/cash-flow-spreadsheet.tsx | 8 +- .../spreadsheets/crossover-spreadsheet.ts | 4 +- .../spreadsheets/custom-spreadsheet.ts | 8 +- .../reports/spreadsheets/filterHiddenItems.ts | 2 +- .../spreadsheets/grouped-spreadsheet.ts | 8 +- .../reports/spreadsheets/makeQuery.ts | 2 +- .../spreadsheets/net-worth-spreadsheet.ts | 8 +- .../reports/spreadsheets/recalculate.ts | 2 +- .../spreadsheets/spending-spreadsheet.ts | 4 +- .../spreadsheets/summary-spreadsheet.ts | 4 +- .../reports/useDashboardWidgetCopyMenu.ts | 4 +- .../src/components/reports/useReport.ts | 2 +- .../src/components/reports/util.ts | 2 +- .../src/components/responsive/index.tsx | 2 +- .../components/rules/FormulaActionEditor.tsx | 2 +- .../src/components/rules/RuleEditor.tsx | 33 ++++---- .../src/components/rules/RuleRow.tsx | 8 +- .../src/components/rules/RulesHeader.tsx | 11 +-- .../src/components/rules/ScheduleValue.tsx | 4 +- .../src/components/rules/Value.tsx | 16 ++-- .../schedules/DiscoverSchedules.tsx | 26 ++---- .../schedules/PostsOfflineNotification.tsx | 14 ++-- .../components/schedules/ScheduleEditForm.tsx | 31 +++---- .../schedules/ScheduleEditModal.tsx | 20 ++--- .../src/components/schedules/ScheduleLink.tsx | 16 ++-- .../components/schedules/SchedulesTable.tsx | 24 +++--- .../components/schedules/UpcomingLength.tsx | 8 +- .../src/components/schedules/index.tsx | 10 +-- .../src/components/select/DateSelect.tsx | 8 +- .../select/RecurringSchedulePicker.tsx | 8 +- .../components/settings/AuthSettings.test.tsx | 13 ++- .../src/components/settings/AuthSettings.tsx | 11 +-- .../settings/BudgetTypeSettings.tsx | 4 +- .../src/components/settings/Currency.tsx | 4 +- .../src/components/settings/Encryption.tsx | 10 +-- .../src/components/settings/Experimental.tsx | 21 +++-- .../src/components/settings/Export.tsx | 2 +- .../src/components/settings/Format.tsx | 10 +-- .../components/settings/LanguageSettings.tsx | 6 +- .../src/components/settings/Reset.tsx | 6 +- .../settings/ThemeInstaller.test.tsx | 10 +-- .../components/settings/ThemeInstaller.tsx | 13 ++- .../src/components/settings/Themes.tsx | 12 +-- .../src/components/settings/UI.tsx | 2 +- .../src/components/settings/index.tsx | 30 +++---- .../src/components/sidebar/Account.tsx | 40 ++++------ .../src/components/sidebar/Accounts.tsx | 20 ++--- .../src/components/sidebar/BudgetName.tsx | 12 +-- .../src/components/sidebar/ItemContent.tsx | 2 +- .../src/components/sidebar/PrimaryButtons.tsx | 4 +- .../src/components/sidebar/Sidebar.tsx | 10 +-- .../components/sidebar/SidebarProvider.tsx | 2 +- .../src/components/sidebar/index.tsx | 2 +- .../desktop-client/src/components/sort.tsx | 4 +- .../src/components/spreadsheet/CellValue.tsx | 14 ++-- .../desktop-client/src/components/table.tsx | 14 ++-- .../src/components/tags/ManageTags.tsx | 14 +--- .../src/components/tags/ManageTagsPage.tsx | 2 +- .../src/components/tags/TagCreationRow.tsx | 14 ++-- .../src/components/tags/TagEditor.tsx | 4 +- .../src/components/tags/TagRow.tsx | 15 ++-- .../src/components/tags/TagsHeader.tsx | 11 +-- .../src/components/tags/TagsList.tsx | 2 +- .../SelectedTransactionsButton.tsx | 10 +-- .../transactions/SimpleTransactionsTable.tsx | 27 +++---- .../transactions/TransactionList.tsx | 12 +-- .../transactions/TransactionMenu.tsx | 8 +- .../transactions/TransactionsTable.test.tsx | 14 ++-- .../transactions/TransactionsTable.tsx | 56 ++++++------- .../src/components/util/AmountInput.tsx | 4 +- .../src/components/util/DisplayId.tsx | 4 +- .../src/components/util/FinancialInput.tsx | 2 +- .../src/components/util/GenericInput.tsx | 28 +++---- .../src/components/util/PercentInput.tsx | 4 +- .../desktop-client/src/hooks/useAccount.ts | 2 +- .../hooks/useAccountPreviewTransactions.ts | 2 +- .../desktop-client/src/hooks/useAccounts.ts | 2 +- .../desktop-client/src/hooks/useCategories.ts | 2 +- .../desktop-client/src/hooks/useCategory.ts | 2 +- .../src/hooks/useCategoryGroup.ts | 2 +- .../hooks/useCategoryPreviewTransactions.ts | 2 +- .../src/hooks/useClosedAccounts.ts | 2 +- .../src/hooks/useCommonPayees.ts | 2 +- .../src/hooks/useDashboardPages.ts | 2 +- .../src/hooks/useDashboardWidget.ts | 2 +- .../src/hooks/useFailedAccounts.ts | 2 +- .../src/hooks/useFormulaExecution.ts | 2 +- .../desktop-client/src/hooks/useGlobalPref.ts | 4 +- .../src/hooks/useLocationPermission.ts | 2 +- .../src/hooks/useMetaThemeColor.test.ts | 4 +- .../src/hooks/useMetaThemeColor.ts | 2 +- .../src/hooks/useMetadataPref.ts | 4 +- .../desktop-client/src/hooks/useModalState.ts | 6 +- .../src/hooks/useNearbyPayees.ts | 2 +- .../src/hooks/useOffBudgetAccounts.ts | 2 +- .../src/hooks/useOnBudgetAccounts.ts | 2 +- .../src/hooks/useOrphanedPayees.ts | 2 +- .../src/hooks/useOverspentCategories.ts | 5 +- packages/desktop-client/src/hooks/usePayee.ts | 2 +- .../src/hooks/usePayeeRuleCounts.ts | 2 +- .../desktop-client/src/hooks/usePayees.ts | 2 +- packages/desktop-client/src/hooks/useQuery.ts | 4 +- .../desktop-client/src/hooks/useReport.ts | 2 +- .../desktop-client/src/hooks/useReports.ts | 2 +- .../src/hooks/useScheduleEdit.ts | 8 +- .../desktop-client/src/hooks/useSchedules.ts | 6 +- .../desktop-client/src/hooks/useServerPref.ts | 4 +- .../desktop-client/src/hooks/useSheetName.tsx | 6 +- .../desktop-client/src/hooks/useSheetValue.ts | 2 +- .../src/hooks/useSyncServerStatus.ts | 4 +- .../desktop-client/src/hooks/useSyncedPref.ts | 4 +- .../src/hooks/useSyncedPrefs.ts | 4 +- .../desktop-client/src/hooks/useTagCSS.ts | 2 +- packages/desktop-client/src/hooks/useTags.ts | 2 +- .../src/hooks/useThemeCatalog.ts | 2 +- .../src/hooks/useTransactionBatchActions.ts | 8 +- .../src/hooks/useTransactions.ts | 2 +- .../src/hooks/useTransactionsSearch.ts | 2 +- packages/desktop-client/src/hooks/useUndo.ts | 8 +- .../src/hooks/useUpdatedAccounts.ts | 2 +- .../desktop-client/src/modals/modalsSlice.ts | 10 +-- .../src/notes/DesktopLinkedNotes.tsx | 6 +- .../src/notes/DesktopTaggedNotes.tsx | 2 +- .../src/notes/MobileLinkedNotes.tsx | 4 +- .../src/notes/MobileTaggedNotes.tsx | 2 +- .../src/notifications/notificationsSlice.ts | 2 +- .../desktop-client/src/payees/mutations.ts | 6 +- packages/desktop-client/src/payees/queries.ts | 2 +- .../desktop-client/src/prefs/prefsSlice.ts | 10 +-- packages/desktop-client/src/redux/store.ts | 16 ++-- .../desktop-client/src/reports/mutations.ts | 6 +- .../desktop-client/src/reports/queries.ts | 2 +- .../src/spreadsheet/bindings.ts | 2 +- packages/desktop-client/src/style/theme.tsx | 4 +- .../desktop-client/src/style/themes/dark.ts | 2 +- .../src/style/themes/development.ts | 2 +- .../desktop-client/src/style/themes/light.ts | 2 +- .../src/style/themes/midnight.ts | 2 +- packages/desktop-client/src/tags/mutations.ts | 6 +- .../src/transactions/queries.ts | 2 +- .../src/transactions/transactionsSlice.ts | 2 +- .../desktop-client/src/users/usersSlice.ts | 11 +-- .../desktop-client/src/util/router-tools.ts | 2 +- upcoming-release-notes/7182.md | 6 ++ 472 files changed, 2250 insertions(+), 2709 deletions(-) create mode 100644 upcoming-release-notes/7182.md diff --git a/.oxfmtrc.json b/.oxfmtrc.json index 63617a3085..b180eeb6cb 100644 --- a/.oxfmtrc.json +++ b/.oxfmtrc.json @@ -26,7 +26,7 @@ }, { "groupName": "desktop-client", - "elementNamePattern": ["@desktop-client/**"] + "elementNamePattern": ["@desktop-client/**", "#**", "#**/**"] } ], "newlinesBetween": true diff --git a/packages/desktop-client/package.json b/packages/desktop-client/package.json index 039f4fe66f..2f8879ff11 100644 --- a/packages/desktop-client/package.json +++ b/packages/desktop-client/package.json @@ -5,6 +5,14 @@ "files": [ "build" ], + "imports": { + "#*": [ + "./src/*.ts", + "./src/*.tsx", + "./src/*/index.ts", + "./src/*/index.tsx" + ] + }, "scripts": { "start": "cross-env PORT=3001 vite", "start:browser": "cross-env ./bin/watch-browser", diff --git a/packages/desktop-client/src/accounts/accountsSlice.ts b/packages/desktop-client/src/accounts/accountsSlice.ts index 0db058a65b..ff7d00ca62 100644 --- a/packages/desktop-client/src/accounts/accountsSlice.ts +++ b/packages/desktop-client/src/accounts/accountsSlice.ts @@ -5,7 +5,7 @@ import memoizeOne from 'memoize-one'; import { groupById } from 'loot-core/shared/util'; import type { AccountEntity } from 'loot-core/types/models'; -import { resetApp } from '@desktop-client/app/appSlice'; +import { resetApp } from '#app/appSlice'; const sliceName = 'account'; diff --git a/packages/desktop-client/src/accounts/mutations.ts b/packages/desktop-client/src/accounts/mutations.ts index d15aa24376..684f824a10 100644 --- a/packages/desktop-client/src/accounts/mutations.ts +++ b/packages/desktop-client/src/accounts/mutations.ts @@ -23,13 +23,13 @@ import { } from './accountsSlice'; import { accountQueries } from './queries'; -import { sync } from '@desktop-client/app/appSlice'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { payeeQueries } from '@desktop-client/payees'; -import { useDispatch, useStore } from '@desktop-client/redux'; -import type { AppDispatch } from '@desktop-client/redux/store'; -import { setNewTransactions } from '@desktop-client/transactions/transactionsSlice'; +import { sync } from '#app/appSlice'; +import { useAccounts } from '#hooks/useAccounts'; +import { addNotification } from '#notifications/notificationsSlice'; +import { payeeQueries } from '#payees'; +import { useDispatch, useStore } from '#redux'; +import type { AppDispatch } from '#redux/store'; +import { setNewTransactions } from '#transactions/transactionsSlice'; const invalidateQueries = (queryClient: QueryClient, queryKey?: QueryKey) => { void queryClient.invalidateQueries({ diff --git a/packages/desktop-client/src/app/appSlice.ts b/packages/desktop-client/src/app/appSlice.ts index fd0273ee00..bc3b7a7be2 100644 --- a/packages/desktop-client/src/app/appSlice.ts +++ b/packages/desktop-client/src/app/appSlice.ts @@ -5,10 +5,10 @@ import { send } from 'loot-core/platform/client/connection'; import { getUploadError } from 'loot-core/shared/errors'; import type { AtLeastOne } from 'loot-core/types/util'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import { loadPrefs } from '@desktop-client/prefs/prefsSlice'; -import { createAppAsyncThunk } from '@desktop-client/redux'; -import { getIsOutdated, getLatestVersion } from '@desktop-client/util/versions'; +import { pushModal } from '#modals/modalsSlice'; +import { loadPrefs } from '#prefs/prefsSlice'; +import { createAppAsyncThunk } from '#redux'; +import { getIsOutdated, getLatestVersion } from '#util/versions'; const sliceName = 'app'; diff --git a/packages/desktop-client/src/auth/AuthProvider.tsx b/packages/desktop-client/src/auth/AuthProvider.tsx index b823c05cba..4d3f353e5e 100644 --- a/packages/desktop-client/src/auth/AuthProvider.tsx +++ b/packages/desktop-client/src/auth/AuthProvider.tsx @@ -3,8 +3,8 @@ import type { ReactNode } from 'react'; import type { Permissions } from './types'; -import { useServerURL } from '@desktop-client/components/ServerContext'; -import { useSelector } from '@desktop-client/redux'; +import { useServerURL } from '#components/ServerContext'; +import { useSelector } from '#redux'; type AuthContextType = { hasPermission: (permission?: Permissions) => boolean; diff --git a/packages/desktop-client/src/auth/ProtectedRoute.tsx b/packages/desktop-client/src/auth/ProtectedRoute.tsx index caddc14929..d44117b3ba 100644 --- a/packages/desktop-client/src/auth/ProtectedRoute.tsx +++ b/packages/desktop-client/src/auth/ProtectedRoute.tsx @@ -9,8 +9,8 @@ import type { RemoteFile, SyncedLocalFile } from 'loot-core/types/file'; import { useAuth } from './AuthProvider'; import type { Permissions } from './types'; -import { useMetadataPref } from '@desktop-client/hooks/useMetadataPref'; -import { useSelector } from '@desktop-client/redux'; +import { useMetadataPref } from '#hooks/useMetadataPref'; +import { useSelector } from '#redux'; type ProtectedRouteProps = { permission: Permissions; diff --git a/packages/desktop-client/src/budget/mutations.ts b/packages/desktop-client/src/budget/mutations.ts index 3c7b87d3f0..dfb4df7a1e 100644 --- a/packages/desktop-client/src/budget/mutations.ts +++ b/packages/desktop-client/src/budget/mutations.ts @@ -14,10 +14,10 @@ import type { import { categoryQueries } from './queries'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; -import type { AppDispatch } from '@desktop-client/redux/store'; +import { pushModal } from '#modals/modalsSlice'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; +import type { AppDispatch } from '#redux/store'; function invalidateQueries(queryClient: QueryClient, queryKey?: QueryKey) { void queryClient.invalidateQueries({ diff --git a/packages/desktop-client/src/budgetfiles/budgetfilesSlice.ts b/packages/desktop-client/src/budgetfiles/budgetfilesSlice.ts index b42b5d9a08..19900fc5ff 100644 --- a/packages/desktop-client/src/budgetfiles/budgetfilesSlice.ts +++ b/packages/desktop-client/src/budgetfiles/budgetfilesSlice.ts @@ -9,11 +9,11 @@ import type { Budget } from 'loot-core/types/budget'; import type { File } from 'loot-core/types/file'; import type { Handlers } from 'loot-core/types/handlers'; -import { resetApp, setAppState } from '@desktop-client/app/appSlice'; -import { closeModal, pushModal } from '@desktop-client/modals/modalsSlice'; -import { loadGlobalPrefs, loadPrefs } from '@desktop-client/prefs/prefsSlice'; -import { createAppAsyncThunk } from '@desktop-client/redux'; -import { signOut } from '@desktop-client/users/usersSlice'; +import { resetApp, setAppState } from '#app/appSlice'; +import { closeModal, pushModal } from '#modals/modalsSlice'; +import { loadGlobalPrefs, loadPrefs } from '#prefs/prefsSlice'; +import { createAppAsyncThunk } from '#redux'; +import { signOut } from '#users/usersSlice'; const sliceName = 'budgetfiles'; diff --git a/packages/desktop-client/src/components/App.tsx b/packages/desktop-client/src/components/App.tsx index c9a312f7c3..ddbf79f446 100644 --- a/packages/desktop-client/src/components/App.tsx +++ b/packages/desktop-client/src/components/App.tsx @@ -26,29 +26,26 @@ import { Modals } from './Modals'; import { SidebarProvider } from './sidebar/SidebarProvider'; import { UpdateNotification } from './UpdateNotification'; -import { setAppState, sync } from '@desktop-client/app/appSlice'; -import { - closeBudget, - loadBudget, -} from '@desktop-client/budgetfiles/budgetfilesSlice'; -import { handleGlobalEvents } from '@desktop-client/global-events'; -import { useIsTestEnv } from '@desktop-client/hooks/useIsTestEnv'; -import { useMetadataPref } from '@desktop-client/hooks/useMetadataPref'; -import { useOnVisible } from '@desktop-client/hooks/useOnVisible'; -import { SpreadsheetProvider } from '@desktop-client/hooks/useSpreadsheet'; -import { setI18NextLanguage } from '@desktop-client/i18n'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { installPolyfills } from '@desktop-client/polyfills'; -import { loadGlobalPrefs } from '@desktop-client/prefs/prefsSlice'; -import { useDispatch, useSelector, useStore } from '@desktop-client/redux'; +import { setAppState, sync } from '#app/appSlice'; +import { closeBudget, loadBudget } from '#budgetfiles/budgetfilesSlice'; +import { handleGlobalEvents } from '#global-events'; +import { useIsTestEnv } from '#hooks/useIsTestEnv'; +import { useMetadataPref } from '#hooks/useMetadataPref'; +import { useOnVisible } from '#hooks/useOnVisible'; +import { SpreadsheetProvider } from '#hooks/useSpreadsheet'; +import { setI18NextLanguage } from '#i18n'; +import { addNotification } from '#notifications/notificationsSlice'; +import { installPolyfills } from '#polyfills'; +import { loadGlobalPrefs } from '#prefs/prefsSlice'; +import { useDispatch, useSelector, useStore } from '#redux'; import { CustomThemeStyle, hasHiddenScrollbars, ThemeStyle, useTheme, -} from '@desktop-client/style'; -import { signOut } from '@desktop-client/users/usersSlice'; -import { ExposeNavigate } from '@desktop-client/util/router-tools'; +} from '#style'; +import { signOut } from '#users/usersSlice'; +import { ExposeNavigate } from '#util/router-tools'; function AppInner() { const [budgetId] = useMetadataPref('id'); diff --git a/packages/desktop-client/src/components/AppBackground.tsx b/packages/desktop-client/src/components/AppBackground.tsx index 0e4ec7be62..5d2e33f12f 100644 --- a/packages/desktop-client/src/components/AppBackground.tsx +++ b/packages/desktop-client/src/components/AppBackground.tsx @@ -9,7 +9,7 @@ import { css } from '@emotion/css'; import { Background } from './Background'; -import { useSelector } from '@desktop-client/redux'; +import { useSelector } from '#redux'; type AppBackgroundProps = { isLoading?: boolean; diff --git a/packages/desktop-client/src/components/BankSyncStatus.tsx b/packages/desktop-client/src/components/BankSyncStatus.tsx index ee6e8fa349..fda31ac03f 100644 --- a/packages/desktop-client/src/components/BankSyncStatus.tsx +++ b/packages/desktop-client/src/components/BankSyncStatus.tsx @@ -9,7 +9,7 @@ import { View } from '@actual-app/components/view'; import { AnimatedRefresh } from './AnimatedRefresh'; -import { useSelector } from '@desktop-client/redux'; +import { useSelector } from '#redux'; export function BankSyncStatus() { const accountsSyncing = useSelector(state => state.account.accountsSyncing); diff --git a/packages/desktop-client/src/components/CommandBar.tsx b/packages/desktop-client/src/components/CommandBar.tsx index 477c97142c..0096b62588 100644 --- a/packages/desktop-client/src/components/CommandBar.tsx +++ b/packages/desktop-client/src/components/CommandBar.tsx @@ -24,23 +24,19 @@ import { Command } from 'cmdk'; import { CellValue, CellValueText } from './spreadsheet/CellValue'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; -import { useDashboardPages } from '@desktop-client/hooks/useDashboardPages'; -import { useMetadataPref } from '@desktop-client/hooks/useMetadataPref'; -import { useModalState } from '@desktop-client/hooks/useModalState'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { useReports } from '@desktop-client/hooks/useReports'; -import type { - Binding, - SheetFields, - SheetNames, -} from '@desktop-client/spreadsheet'; +import { useAccounts } from '#hooks/useAccounts'; +import { useDashboardPages } from '#hooks/useDashboardPages'; +import { useMetadataPref } from '#hooks/useMetadataPref'; +import { useModalState } from '#hooks/useModalState'; +import { useNavigate } from '#hooks/useNavigate'; +import { useReports } from '#hooks/useReports'; +import type { Binding, SheetFields, SheetNames } from '#spreadsheet'; import { accountBalance, allAccountBalance, offBudgetAccountBalance, onBudgetAccountBalance, -} from '@desktop-client/spreadsheet/bindings'; +} from '#spreadsheet/bindings'; type SearchableItem = { id: string; diff --git a/packages/desktop-client/src/components/FatalError.tsx b/packages/desktop-client/src/components/FatalError.tsx index 96698bf584..c8a5f2784d 100644 --- a/packages/desktop-client/src/components/FatalError.tsx +++ b/packages/desktop-client/src/components/FatalError.tsx @@ -15,7 +15,7 @@ import { Link } from './common/Link'; import { Modal, ModalHeader } from './common/Modal'; import { Checkbox } from './forms'; -import { useModalState } from '@desktop-client/hooks/useModalState'; +import { useModalState } from '#hooks/useModalState'; type AppError = Error & { type?: string; diff --git a/packages/desktop-client/src/components/FinancesApp.tsx b/packages/desktop-client/src/components/FinancesApp.tsx index fea973690d..220a5e96eb 100644 --- a/packages/desktop-client/src/components/FinancesApp.tsx +++ b/packages/desktop-client/src/components/FinancesApp.tsx @@ -28,18 +28,18 @@ import { FloatableSidebar } from './sidebar'; import { ManageTagsPage } from './tags/ManageTagsPage'; import { Titlebar } from './Titlebar'; -import { accountQueries } from '@desktop-client/accounts'; -import { getLatestAppVersion, sync } from '@desktop-client/app/appSlice'; -import { ProtectedRoute } from '@desktop-client/auth/ProtectedRoute'; -import { Permissions } from '@desktop-client/auth/types'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; -import { useGlobalPref } from '@desktop-client/hooks/useGlobalPref'; -import { useLocalPref } from '@desktop-client/hooks/useLocalPref'; -import { useMetaThemeColor } from '@desktop-client/hooks/useMetaThemeColor'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { ScrollProvider } from '@desktop-client/hooks/useScrollListener'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch, useSelector } from '@desktop-client/redux'; +import { accountQueries } from '#accounts'; +import { getLatestAppVersion, sync } from '#app/appSlice'; +import { ProtectedRoute } from '#auth/ProtectedRoute'; +import { Permissions } from '#auth/types'; +import { useAccounts } from '#hooks/useAccounts'; +import { useGlobalPref } from '#hooks/useGlobalPref'; +import { useLocalPref } from '#hooks/useLocalPref'; +import { useMetaThemeColor } from '#hooks/useMetaThemeColor'; +import { useNavigate } from '#hooks/useNavigate'; +import { ScrollProvider } from '#hooks/useScrollListener'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch, useSelector } from '#redux'; function NarrowNotSupported({ redirectTo = '/budget', diff --git a/packages/desktop-client/src/components/GlobalKeys.ts b/packages/desktop-client/src/components/GlobalKeys.ts index 0877ea8a3b..f13169f913 100644 --- a/packages/desktop-client/src/components/GlobalKeys.ts +++ b/packages/desktop-client/src/components/GlobalKeys.ts @@ -2,7 +2,7 @@ import { useEffect } from 'react'; import * as Platform from 'loot-core/shared/platform'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; +import { useNavigate } from '#hooks/useNavigate'; export function GlobalKeys() { const navigate = useNavigate(); diff --git a/packages/desktop-client/src/components/HelpMenu.tsx b/packages/desktop-client/src/components/HelpMenu.tsx index b14d00a2df..6aaa51450f 100644 --- a/packages/desktop-client/src/components/HelpMenu.tsx +++ b/packages/desktop-client/src/components/HelpMenu.tsx @@ -10,9 +10,9 @@ import { Popover } from '@actual-app/components/popover'; import { SpaceBetween } from '@actual-app/components/space-between'; import { useToggle } from 'usehooks-ts'; -import { useFeatureFlag } from '@desktop-client/hooks/useFeatureFlag'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { useFeatureFlag } from '#hooks/useFeatureFlag'; +import { pushModal } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; const getPageDocs = (page: string) => { switch (page) { diff --git a/packages/desktop-client/src/components/LoggedInUser.tsx b/packages/desktop-client/src/components/LoggedInUser.tsx index 5dc4a411c3..feac02b6ed 100644 --- a/packages/desktop-client/src/components/LoggedInUser.tsx +++ b/packages/desktop-client/src/components/LoggedInUser.tsx @@ -18,13 +18,13 @@ import type { TransObjectLiteral } from 'loot-core/types/util'; import { PrivacyFilter } from './PrivacyFilter'; import { useMultiuserEnabled, useServerURL } from './ServerContext'; -import { useAuth } from '@desktop-client/auth/AuthProvider'; -import { Permissions } from '@desktop-client/auth/types'; -import { closeBudget } from '@desktop-client/budgetfiles/budgetfilesSlice'; -import { useMetadataPref } from '@desktop-client/hooks/useMetadataPref'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { useDispatch, useSelector } from '@desktop-client/redux'; -import { getUserData, signOut } from '@desktop-client/users/usersSlice'; +import { useAuth } from '#auth/AuthProvider'; +import { Permissions } from '#auth/types'; +import { closeBudget } from '#budgetfiles/budgetfilesSlice'; +import { useMetadataPref } from '#hooks/useMetadataPref'; +import { useNavigate } from '#hooks/useNavigate'; +import { useDispatch, useSelector } from '#redux'; +import { getUserData, signOut } from '#users/usersSlice'; type LoggedInUserProps = { hideIfNoServer?: boolean; diff --git a/packages/desktop-client/src/components/ManageRules.tsx b/packages/desktop-client/src/components/ManageRules.tsx index 482379419e..83cb887725 100644 --- a/packages/desktop-client/src/components/ManageRules.tsx +++ b/packages/desktop-client/src/components/ManageRules.tsx @@ -28,16 +28,13 @@ import { Search } from './common/Search'; import { RulesHeader } from './rules/RulesHeader'; import { RulesList } from './rules/RulesList'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; -import { useCategories } from '@desktop-client/hooks/useCategories'; -import { usePayees } from '@desktop-client/hooks/usePayees'; -import { useSchedules } from '@desktop-client/hooks/useSchedules'; -import { - SelectedProvider, - useSelected, -} from '@desktop-client/hooks/useSelected'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { useAccounts } from '#hooks/useAccounts'; +import { useCategories } from '#hooks/useCategories'; +import { usePayees } from '#hooks/usePayees'; +import { useSchedules } from '#hooks/useSchedules'; +import { SelectedProvider, useSelected } from '#hooks/useSelected'; +import { pushModal } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; export type FilterData = { payees?: Array<{ id: string; name: string }>; diff --git a/packages/desktop-client/src/components/Modals.tsx b/packages/desktop-client/src/components/Modals.tsx index 69448ba472..fedca08e32 100644 --- a/packages/desktop-client/src/components/Modals.tsx +++ b/packages/desktop-client/src/components/Modals.tsx @@ -78,11 +78,11 @@ import { ScheduleEditModal } from './schedules/ScheduleEditModal'; import { ScheduleLink } from './schedules/ScheduleLink'; import { UpcomingLength } from './schedules/UpcomingLength'; -import { useMetadataPref } from '@desktop-client/hooks/useMetadataPref'; -import { useModalState } from '@desktop-client/hooks/useModalState'; -import { SheetNameProvider } from '@desktop-client/hooks/useSheetName'; -import { closeModal } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { useMetadataPref } from '#hooks/useMetadataPref'; +import { useModalState } from '#hooks/useModalState'; +import { SheetNameProvider } from '#hooks/useSheetName'; +import { closeModal } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; export function Modals() { const location = useLocation(); diff --git a/packages/desktop-client/src/components/Notes.tsx b/packages/desktop-client/src/components/Notes.tsx index 58b7bf9498..13a68aff26 100644 --- a/packages/desktop-client/src/components/Notes.tsx +++ b/packages/desktop-client/src/components/Notes.tsx @@ -14,7 +14,7 @@ import { markdownBaseStyles, remarkBreaks, sequentialNewlinesPlugin, -} from '@desktop-client/util/markdown'; +} from '#util/markdown'; const remarkPlugins = [sequentialNewlinesPlugin, remarkGfm, remarkBreaks]; diff --git a/packages/desktop-client/src/components/NotesButton.tsx b/packages/desktop-client/src/components/NotesButton.tsx index 907756e011..064037ea0b 100644 --- a/packages/desktop-client/src/components/NotesButton.tsx +++ b/packages/desktop-client/src/components/NotesButton.tsx @@ -14,7 +14,7 @@ import { send } from 'loot-core/platform/client/connection'; import { Notes } from './Notes'; -import { useNotes } from '@desktop-client/hooks/useNotes'; +import { useNotes } from '#hooks/useNotes'; type NotesButtonProps = { id: string; diff --git a/packages/desktop-client/src/components/Notifications.tsx b/packages/desktop-client/src/components/Notifications.tsx index 01c240ec01..a10a091bb2 100644 --- a/packages/desktop-client/src/components/Notifications.tsx +++ b/packages/desktop-client/src/components/Notifications.tsx @@ -18,9 +18,9 @@ import { css } from '@emotion/css'; import { Link } from './common/Link'; import { MODAL_Z_INDEX } from './common/Modal'; -import { removeNotification } from '@desktop-client/notifications/notificationsSlice'; -import type { NotificationWithId } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch, useSelector } from '@desktop-client/redux'; +import { removeNotification } from '#notifications/notificationsSlice'; +import type { NotificationWithId } from '#notifications/notificationsSlice'; +import { useDispatch, useSelector } from '#redux'; // Notification stacking configuration const MAX_VISIBLE_NOTIFICATIONS = 3; // Maximum number of notifications visible in the stack diff --git a/packages/desktop-client/src/components/PrivacyFilter.tsx b/packages/desktop-client/src/components/PrivacyFilter.tsx index c525d47fff..50b7eded64 100644 --- a/packages/desktop-client/src/components/PrivacyFilter.tsx +++ b/packages/desktop-client/src/components/PrivacyFilter.tsx @@ -6,7 +6,7 @@ import { useResponsive } from '@actual-app/components/hooks/useResponsive'; import { View } from '@actual-app/components/view'; import { css } from '@emotion/css'; -import { usePrivacyMode } from '@desktop-client/hooks/usePrivacyMode'; +import { usePrivacyMode } from '#hooks/usePrivacyMode'; type ConditionalPrivacyFilterProps = { children: ReactNode; diff --git a/packages/desktop-client/src/components/ServerContext.tsx b/packages/desktop-client/src/components/ServerContext.tsx index 057917331c..68d3d098b3 100644 --- a/packages/desktop-client/src/components/ServerContext.tsx +++ b/packages/desktop-client/src/components/ServerContext.tsx @@ -12,9 +12,9 @@ import { t } from 'i18next'; import { send } from 'loot-core/platform/client/connection'; import type { Handlers } from 'loot-core/types/handlers'; -import { useOnVisible } from '@desktop-client/hooks/useOnVisible'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { useOnVisible } from '#hooks/useOnVisible'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; type LoginMethod = { method: string; diff --git a/packages/desktop-client/src/components/ThemeSelector.tsx b/packages/desktop-client/src/components/ThemeSelector.tsx index 9afeaf9215..9e36dc2249 100644 --- a/packages/desktop-client/src/components/ThemeSelector.tsx +++ b/packages/desktop-client/src/components/ThemeSelector.tsx @@ -14,7 +14,7 @@ import { Popover } from '@actual-app/components/popover'; import type { Theme } from 'loot-core/types/prefs'; -import { themeOptions, useTheme } from '@desktop-client/style'; +import { themeOptions, useTheme } from '#style'; type ThemeSelectorProps = { style?: CSSProperties; diff --git a/packages/desktop-client/src/components/Titlebar.tsx b/packages/desktop-client/src/components/Titlebar.tsx index 31db5883c6..17dee6e6eb 100644 --- a/packages/desktop-client/src/components/Titlebar.tsx +++ b/packages/desktop-client/src/components/Titlebar.tsx @@ -34,15 +34,15 @@ import { useServerURL } from './ServerContext'; import { useSidebar } from './sidebar/SidebarProvider'; import { ThemeSelector } from './ThemeSelector'; -import { sync } from '@desktop-client/app/appSlice'; -import { useGlobalPref } from '@desktop-client/hooks/useGlobalPref'; -import { useIsTestEnv } from '@desktop-client/hooks/useIsTestEnv'; -import { useMetadataPref } from '@desktop-client/hooks/useMetadataPref'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { useSheetValue } from '@desktop-client/hooks/useSheetValue'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; -import { useDispatch } from '@desktop-client/redux'; -import * as bindings from '@desktop-client/spreadsheet/bindings'; +import { sync } from '#app/appSlice'; +import { useGlobalPref } from '#hooks/useGlobalPref'; +import { useIsTestEnv } from '#hooks/useIsTestEnv'; +import { useMetadataPref } from '#hooks/useMetadataPref'; +import { useNavigate } from '#hooks/useNavigate'; +import { useSheetValue } from '#hooks/useSheetValue'; +import { useSyncedPref } from '#hooks/useSyncedPref'; +import { useDispatch } from '#redux'; +import * as bindings from '#spreadsheet/bindings'; function UncategorizedButton() { const count: number | null = useSheetValue(bindings.uncategorizedCount()); diff --git a/packages/desktop-client/src/components/UpdateNotification.tsx b/packages/desktop-client/src/components/UpdateNotification.tsx index deb60c8c5b..0f7b823035 100644 --- a/packages/desktop-client/src/components/UpdateNotification.tsx +++ b/packages/desktop-client/src/components/UpdateNotification.tsx @@ -9,8 +9,8 @@ import { View } from '@actual-app/components/view'; import { Link } from './common/Link'; -import { setAppState, updateApp } from '@desktop-client/app/appSlice'; -import { useDispatch, useSelector } from '@desktop-client/redux'; +import { setAppState, updateApp } from '#app/appSlice'; +import { useDispatch, useSelector } from '#redux'; export function UpdateNotification() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/accounts/Account.tsx b/packages/desktop-client/src/components/accounts/Account.tsx index 9a175663b8..91585dbe86 100644 --- a/packages/desktop-client/src/components/accounts/Account.tsx +++ b/packages/desktop-client/src/components/accounts/Account.tsx @@ -46,44 +46,44 @@ import { useSyncAndDownloadMutation, useUnlinkAccountMutation, useUpdateAccountMutation, -} from '@desktop-client/accounts'; -import { markAccountRead } from '@desktop-client/accounts/accountsSlice'; -import type { SavedFilter } from '@desktop-client/components/filters/SavedFilterMenuButton'; -import { TransactionList } from '@desktop-client/components/transactions/TransactionList'; -import { validateAccountName } from '@desktop-client/components/util/accountValidation'; -import { useAccountPreviewTransactions } from '@desktop-client/hooks/useAccountPreviewTransactions'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; -import { SchedulesProvider } from '@desktop-client/hooks/useCachedSchedules'; -import { useCategories } from '@desktop-client/hooks/useCategories'; -import { useDateFormat } from '@desktop-client/hooks/useDateFormat'; -import { useFailedAccounts } from '@desktop-client/hooks/useFailedAccounts'; -import { useLocalPref } from '@desktop-client/hooks/useLocalPref'; -import { usePayees } from '@desktop-client/hooks/usePayees'; -import { getSchedulesQuery } from '@desktop-client/hooks/useSchedules'; -import { SelectedProviderWithItems } from '@desktop-client/hooks/useSelected'; -import type { Actions } from '@desktop-client/hooks/useSelected'; +} from '#accounts'; +import { markAccountRead } from '#accounts/accountsSlice'; +import type { SavedFilter } from '#components/filters/SavedFilterMenuButton'; +import { TransactionList } from '#components/transactions/TransactionList'; +import { validateAccountName } from '#components/util/accountValidation'; +import { useAccountPreviewTransactions } from '#hooks/useAccountPreviewTransactions'; +import { useAccounts } from '#hooks/useAccounts'; +import { SchedulesProvider } from '#hooks/useCachedSchedules'; +import { useCategories } from '#hooks/useCategories'; +import { useDateFormat } from '#hooks/useDateFormat'; +import { useFailedAccounts } from '#hooks/useFailedAccounts'; +import { useLocalPref } from '#hooks/useLocalPref'; +import { usePayees } from '#hooks/usePayees'; +import { getSchedulesQuery } from '#hooks/useSchedules'; +import { SelectedProviderWithItems } from '#hooks/useSelected'; +import type { Actions } from '#hooks/useSelected'; import { SplitsExpandedProvider, useSplitsExpanded, -} from '@desktop-client/hooks/useSplitsExpanded'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; -import { useTransactionBatchActions } from '@desktop-client/hooks/useTransactionBatchActions'; -import { useTransactionFilters } from '@desktop-client/hooks/useTransactionFilters'; -import { calculateRunningBalancesBottomUp } from '@desktop-client/hooks/useTransactions'; +} from '#hooks/useSplitsExpanded'; +import { useSyncedPref } from '#hooks/useSyncedPref'; +import { useTransactionBatchActions } from '#hooks/useTransactionBatchActions'; +import { useTransactionFilters } from '#hooks/useTransactionFilters'; +import { calculateRunningBalancesBottomUp } from '#hooks/useTransactions'; import { openAccountCloseModal, pushModal, replaceModal, -} from '@desktop-client/modals/modalsSlice'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useCreatePayeeMutation } from '@desktop-client/payees'; -import * as queries from '@desktop-client/queries'; -import { aqlQuery } from '@desktop-client/queries/aqlQuery'; -import { pagedQuery } from '@desktop-client/queries/pagedQuery'; -import type { PagedQuery } from '@desktop-client/queries/pagedQuery'; -import { useDispatch, useSelector } from '@desktop-client/redux'; -import type { AppDispatch } from '@desktop-client/redux/store'; -import { updateNewTransactions } from '@desktop-client/transactions/transactionsSlice'; +} from '#modals/modalsSlice'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useCreatePayeeMutation } from '#payees'; +import * as queries from '#queries'; +import { aqlQuery } from '#queries/aqlQuery'; +import { pagedQuery } from '#queries/pagedQuery'; +import type { PagedQuery } from '#queries/pagedQuery'; +import { useDispatch, useSelector } from '#redux'; +import type { AppDispatch } from '#redux/store'; +import { updateNewTransactions } from '#transactions/transactionsSlice'; type ConditionEntity = Partial | TransactionFilterEntity; diff --git a/packages/desktop-client/src/components/accounts/AccountSyncCheck.tsx b/packages/desktop-client/src/components/accounts/AccountSyncCheck.tsx index ca0d7786bf..8bafbc52d5 100644 --- a/packages/desktop-client/src/components/accounts/AccountSyncCheck.tsx +++ b/packages/desktop-client/src/components/accounts/AccountSyncCheck.tsx @@ -10,12 +10,12 @@ import { View } from '@actual-app/components/view'; import type { AccountEntity } from 'loot-core/types/models'; -import { useUnlinkAccountMutation } from '@desktop-client/accounts'; -import { Link } from '@desktop-client/components/common/Link'; -import { authorizeBank } from '@desktop-client/gocardless'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; -import { useFailedAccounts } from '@desktop-client/hooks/useFailedAccounts'; -import { useDispatch } from '@desktop-client/redux'; +import { useUnlinkAccountMutation } from '#accounts'; +import { Link } from '#components/common/Link'; +import { authorizeBank } from '#gocardless'; +import { useAccounts } from '#hooks/useAccounts'; +import { useFailedAccounts } from '#hooks/useFailedAccounts'; +import { useDispatch } from '#redux'; function useErrorMessage() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/accounts/Balance.tsx b/packages/desktop-client/src/components/accounts/Balance.tsx index b48caf4d52..571b301f36 100644 --- a/packages/desktop-client/src/components/accounts/Balance.tsx +++ b/packages/desktop-client/src/components/accounts/Balance.tsx @@ -15,17 +15,14 @@ import { getScheduledAmount } from 'loot-core/shared/schedules'; import { isPreviewId } from 'loot-core/shared/transactions'; import type { AccountEntity } from 'loot-core/types/models'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { - CellValue, - CellValueText, -} from '@desktop-client/components/spreadsheet/CellValue'; -import { useCachedSchedules } from '@desktop-client/hooks/useCachedSchedules'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useSelectedItems } from '@desktop-client/hooks/useSelected'; -import { useSheetValue } from '@desktop-client/hooks/useSheetValue'; -import type { Binding } from '@desktop-client/spreadsheet'; +import { FinancialText } from '#components/FinancialText'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { CellValue, CellValueText } from '#components/spreadsheet/CellValue'; +import { useCachedSchedules } from '#hooks/useCachedSchedules'; +import { useFormat } from '#hooks/useFormat'; +import { useSelectedItems } from '#hooks/useSelected'; +import { useSheetValue } from '#hooks/useSheetValue'; +import type { Binding } from '#spreadsheet'; type DetailedBalanceProps = { name: string; diff --git a/packages/desktop-client/src/components/accounts/BalanceHistoryGraph.tsx b/packages/desktop-client/src/components/accounts/BalanceHistoryGraph.tsx index c43396f4f1..3bd0dccc42 100644 --- a/packages/desktop-client/src/components/accounts/BalanceHistoryGraph.tsx +++ b/packages/desktop-client/src/components/accounts/BalanceHistoryGraph.tsx @@ -13,12 +13,12 @@ import { Area, AreaChart, Tooltip as RechartsTooltip, YAxis } from 'recharts'; import * as monthUtils from 'loot-core/shared/months'; import { integerToCurrency } from 'loot-core/shared/util'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { useRechartsAnimation } from '@desktop-client/components/reports/chart-theme'; -import { LoadingIndicator } from '@desktop-client/components/reports/LoadingIndicator'; -import { useLocale } from '@desktop-client/hooks/useLocale'; -import * as query from '@desktop-client/queries'; -import { liveQuery } from '@desktop-client/queries/liveQuery'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { useRechartsAnimation } from '#components/reports/chart-theme'; +import { LoadingIndicator } from '#components/reports/LoadingIndicator'; +import { useLocale } from '#hooks/useLocale'; +import * as query from '#queries'; +import { liveQuery } from '#queries/liveQuery'; const LABEL_WIDTH = 70; diff --git a/packages/desktop-client/src/components/accounts/Header.tsx b/packages/desktop-client/src/components/accounts/Header.tsx index 09a8aee498..e1bb3be768 100644 --- a/packages/desktop-client/src/components/accounts/Header.tsx +++ b/packages/desktop-client/src/components/accounts/Header.tsx @@ -41,19 +41,19 @@ import { Balances } from './Balance'; import { BalanceHistoryGraph } from './BalanceHistoryGraph'; import { ReconcileMenu, ReconcilingMessage } from './Reconcile'; -import { AnimatedRefresh } from '@desktop-client/components/AnimatedRefresh'; -import { Search } from '@desktop-client/components/common/Search'; -import { FilterButton } from '@desktop-client/components/filters/FiltersMenu'; -import { FiltersStack } from '@desktop-client/components/filters/FiltersStack'; -import type { SavedFilter } from '@desktop-client/components/filters/SavedFilterMenuButton'; -import { NotesButton } from '@desktop-client/components/NotesButton'; -import { SelectedTransactionsButton } from '@desktop-client/components/transactions/SelectedTransactionsButton'; -import { useDateFormat } from '@desktop-client/hooks/useDateFormat'; -import { useLocale } from '@desktop-client/hooks/useLocale'; -import { useLocalPref } from '@desktop-client/hooks/useLocalPref'; -import { useSplitsExpanded } from '@desktop-client/hooks/useSplitsExpanded'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; -import { useSyncServerStatus } from '@desktop-client/hooks/useSyncServerStatus'; +import { AnimatedRefresh } from '#components/AnimatedRefresh'; +import { Search } from '#components/common/Search'; +import { FilterButton } from '#components/filters/FiltersMenu'; +import { FiltersStack } from '#components/filters/FiltersStack'; +import type { SavedFilter } from '#components/filters/SavedFilterMenuButton'; +import { NotesButton } from '#components/NotesButton'; +import { SelectedTransactionsButton } from '#components/transactions/SelectedTransactionsButton'; +import { useDateFormat } from '#hooks/useDateFormat'; +import { useLocale } from '#hooks/useLocale'; +import { useLocalPref } from '#hooks/useLocalPref'; +import { useSplitsExpanded } from '#hooks/useSplitsExpanded'; +import { useSyncedPref } from '#hooks/useSyncedPref'; +import { useSyncServerStatus } from '#hooks/useSyncServerStatus'; type AccountHeaderProps = { tableRef: TableRef; diff --git a/packages/desktop-client/src/components/accounts/Reconcile.test.tsx b/packages/desktop-client/src/components/accounts/Reconcile.test.tsx index 96a9c2272f..ea0dba5a2f 100644 --- a/packages/desktop-client/src/components/accounts/Reconcile.test.tsx +++ b/packages/desktop-client/src/components/accounts/Reconcile.test.tsx @@ -9,10 +9,10 @@ import type { AccountEntity } from 'loot-core/types/models'; import { ReconcileMenu, ReconcilingMessage } from './Reconcile'; -import { useSheetValue } from '@desktop-client/hooks/useSheetValue'; -import { TestProviders } from '@desktop-client/mocks'; +import { useSheetValue } from '#hooks/useSheetValue'; +import { TestProviders } from '#mocks'; -vi.mock('@desktop-client/hooks/useSheetValue', () => ({ +vi.mock('#hooks/useSheetValue', () => ({ useSheetValue: vi.fn(), })); diff --git a/packages/desktop-client/src/components/accounts/Reconcile.tsx b/packages/desktop-client/src/components/accounts/Reconcile.tsx index 87205be82f..ec9be76aa5 100644 --- a/packages/desktop-client/src/components/accounts/Reconcile.tsx +++ b/packages/desktop-client/src/components/accounts/Reconcile.tsx @@ -19,11 +19,11 @@ import { tsToRelativeTime } from 'loot-core/shared/util'; import type { AccountEntity } from 'loot-core/types/models'; import type { TransObjectLiteral } from 'loot-core/types/util'; -import { useDateFormat } from '@desktop-client/hooks/useDateFormat'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useLocale } from '@desktop-client/hooks/useLocale'; -import { useSheetValue } from '@desktop-client/hooks/useSheetValue'; -import * as bindings from '@desktop-client/spreadsheet/bindings'; +import { useDateFormat } from '#hooks/useDateFormat'; +import { useFormat } from '#hooks/useFormat'; +import { useLocale } from '#hooks/useLocale'; +import { useSheetValue } from '#hooks/useSheetValue'; +import * as bindings from '#spreadsheet/bindings'; type ReconcilingMessageProps = { balanceQuery: { name: `balance-query-${string}`; query: Query }; diff --git a/packages/desktop-client/src/components/admin/UserAccess/UserAccess.tsx b/packages/desktop-client/src/components/admin/UserAccess/UserAccess.tsx index 97edc76918..44a5c2c229 100644 --- a/packages/desktop-client/src/components/admin/UserAccess/UserAccess.tsx +++ b/packages/desktop-client/src/components/admin/UserAccess/UserAccess.tsx @@ -19,13 +19,13 @@ import type { UserAccessEntity, UserAvailable } from 'loot-core/types/models'; import { UserAccessHeader } from './UserAccessHeader'; import { UserAccessRow } from './UserAccessRow'; -import { InfiniteScrollWrapper } from '@desktop-client/components/common/InfiniteScrollWrapper'; -import { Link } from '@desktop-client/components/common/Link'; -import { Search } from '@desktop-client/components/common/Search'; -import { useMetadataPref } from '@desktop-client/hooks/useMetadataPref'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { InfiniteScrollWrapper } from '#components/common/InfiniteScrollWrapper'; +import { Link } from '#components/common/Link'; +import { Search } from '#components/common/Search'; +import { useMetadataPref } from '#hooks/useMetadataPref'; +import { pushModal } from '#modals/modalsSlice'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; type ManageUserAccessContentProps = { isModal: boolean; diff --git a/packages/desktop-client/src/components/admin/UserAccess/UserAccessHeader.tsx b/packages/desktop-client/src/components/admin/UserAccess/UserAccessHeader.tsx index a0b0292482..f3cab8a36f 100644 --- a/packages/desktop-client/src/components/admin/UserAccess/UserAccessHeader.tsx +++ b/packages/desktop-client/src/components/admin/UserAccess/UserAccessHeader.tsx @@ -1,7 +1,7 @@ import React from 'react'; import { useTranslation } from 'react-i18next'; -import { Cell, TableHeader } from '@desktop-client/components/table'; +import { Cell, TableHeader } from '#components/table'; export function UserAccessHeader() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/admin/UserAccess/UserAccessPage.tsx b/packages/desktop-client/src/components/admin/UserAccess/UserAccessPage.tsx index 9073002a45..05affdb632 100644 --- a/packages/desktop-client/src/components/admin/UserAccess/UserAccessPage.tsx +++ b/packages/desktop-client/src/components/admin/UserAccess/UserAccessPage.tsx @@ -3,7 +3,7 @@ import { useTranslation } from 'react-i18next'; import { UserAccess } from './UserAccess'; -import { Page } from '@desktop-client/components/Page'; +import { Page } from '#components/Page'; export function UserAccessPage() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/admin/UserAccess/UserAccessRow.tsx b/packages/desktop-client/src/components/admin/UserAccess/UserAccessRow.tsx index 478c7302b0..5fca519b8f 100644 --- a/packages/desktop-client/src/components/admin/UserAccess/UserAccessRow.tsx +++ b/packages/desktop-client/src/components/admin/UserAccess/UserAccessRow.tsx @@ -9,12 +9,12 @@ import { send } from 'loot-core/platform/client/connection'; import { getUserAccessErrors } from 'loot-core/shared/errors'; import type { UserAvailable } from 'loot-core/types/models'; -import { Checkbox } from '@desktop-client/components/forms'; -import { Cell, Row } from '@desktop-client/components/table'; -import { useMetadataPref } from '@desktop-client/hooks/useMetadataPref'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; -import { signOut } from '@desktop-client/users/usersSlice'; +import { Checkbox } from '#components/forms'; +import { Cell, Row } from '#components/table'; +import { useMetadataPref } from '#hooks/useMetadataPref'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; +import { signOut } from '#users/usersSlice'; type UserAccessProps = { access: UserAvailable; diff --git a/packages/desktop-client/src/components/admin/UserDirectory/UserDirectory.tsx b/packages/desktop-client/src/components/admin/UserDirectory/UserDirectory.tsx index 864636020d..6849041756 100644 --- a/packages/desktop-client/src/components/admin/UserDirectory/UserDirectory.tsx +++ b/packages/desktop-client/src/components/admin/UserDirectory/UserDirectory.tsx @@ -17,17 +17,14 @@ import type { NewUserEntity, UserEntity } from 'loot-core/types/models'; import { UserDirectoryHeader } from './UserDirectoryHeader'; import { UserDirectoryRow } from './UserDirectoryRow'; -import { InfiniteScrollWrapper } from '@desktop-client/components/common/InfiniteScrollWrapper'; -import { Link } from '@desktop-client/components/common/Link'; -import { Search } from '@desktop-client/components/common/Search'; -import { - SelectedProvider, - useSelected, -} from '@desktop-client/hooks/useSelected'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; -import { signOut } from '@desktop-client/users/usersSlice'; +import { InfiniteScrollWrapper } from '#components/common/InfiniteScrollWrapper'; +import { Link } from '#components/common/Link'; +import { Search } from '#components/common/Search'; +import { SelectedProvider, useSelected } from '#hooks/useSelected'; +import { pushModal } from '#modals/modalsSlice'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; +import { signOut } from '#users/usersSlice'; type ManageUserDirectoryContentProps = { isModal: boolean; diff --git a/packages/desktop-client/src/components/admin/UserDirectory/UserDirectoryHeader.tsx b/packages/desktop-client/src/components/admin/UserDirectory/UserDirectoryHeader.tsx index d5e452e93d..f0a45ac40a 100644 --- a/packages/desktop-client/src/components/admin/UserDirectory/UserDirectoryHeader.tsx +++ b/packages/desktop-client/src/components/admin/UserDirectory/UserDirectoryHeader.tsx @@ -1,15 +1,8 @@ import React from 'react'; import { useTranslation } from 'react-i18next'; -import { - Cell, - SelectCell, - TableHeader, -} from '@desktop-client/components/table'; -import { - useSelectedDispatch, - useSelectedItems, -} from '@desktop-client/hooks/useSelected'; +import { Cell, SelectCell, TableHeader } from '#components/table'; +import { useSelectedDispatch, useSelectedItems } from '#hooks/useSelected'; export function UserDirectoryHeader() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/admin/UserDirectory/UserDirectoryPage.tsx b/packages/desktop-client/src/components/admin/UserDirectory/UserDirectoryPage.tsx index d54d77ab4c..dcfb554831 100644 --- a/packages/desktop-client/src/components/admin/UserDirectory/UserDirectoryPage.tsx +++ b/packages/desktop-client/src/components/admin/UserDirectory/UserDirectoryPage.tsx @@ -7,8 +7,8 @@ import { View } from '@actual-app/components/view'; import { UserDirectory } from './UserDirectory'; -import { Page } from '@desktop-client/components/Page'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; +import { Page } from '#components/Page'; +import { useNavigate } from '#hooks/useNavigate'; export function UserDirectoryPage({ bottomContent, diff --git a/packages/desktop-client/src/components/admin/UserDirectory/UserDirectoryRow.tsx b/packages/desktop-client/src/components/admin/UserDirectory/UserDirectoryRow.tsx index 7b1fc0b636..08cec635b1 100644 --- a/packages/desktop-client/src/components/admin/UserDirectory/UserDirectoryRow.tsx +++ b/packages/desktop-client/src/components/admin/UserDirectory/UserDirectoryRow.tsx @@ -9,9 +9,9 @@ import { View } from '@actual-app/components/view'; import { PossibleRoles } from 'loot-core/shared/user'; import type { UserEntity } from 'loot-core/types/models'; -import { Checkbox } from '@desktop-client/components/forms'; -import { Cell, Row, SelectCell } from '@desktop-client/components/table'; -import { useSelectedDispatch } from '@desktop-client/hooks/useSelected'; +import { Checkbox } from '#components/forms'; +import { Cell, Row, SelectCell } from '#components/table'; +import { useSelectedDispatch } from '#hooks/useSelected'; type UserDirectoryProps = { user: UserEntity; diff --git a/packages/desktop-client/src/components/autocomplete/AccountAutocomplete.tsx b/packages/desktop-client/src/components/autocomplete/AccountAutocomplete.tsx index 85e80bea04..08ab163260 100644 --- a/packages/desktop-client/src/components/autocomplete/AccountAutocomplete.tsx +++ b/packages/desktop-client/src/components/autocomplete/AccountAutocomplete.tsx @@ -20,7 +20,7 @@ import type { AccountEntity } from 'loot-core/types/models'; import { Autocomplete } from './Autocomplete'; import { ItemHeader } from './ItemHeader'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; +import { useAccounts } from '#hooks/useAccounts'; type AccountAutocompleteItem = AccountEntity; diff --git a/packages/desktop-client/src/components/autocomplete/Autocomplete.tsx b/packages/desktop-client/src/components/autocomplete/Autocomplete.tsx index 89a8f331e1..7188535cd7 100644 --- a/packages/desktop-client/src/components/autocomplete/Autocomplete.tsx +++ b/packages/desktop-client/src/components/autocomplete/Autocomplete.tsx @@ -21,7 +21,7 @@ import type { StateChangeTypes } from 'downshift'; import { getNormalisedString } from 'loot-core/shared/normalisation'; -import { useProperFocus } from '@desktop-client/hooks/useProperFocus'; +import { useProperFocus } from '#hooks/useProperFocus'; type CommonAutocompleteProps = { focused?: boolean; diff --git a/packages/desktop-client/src/components/autocomplete/CategoryAutocomplete.tsx b/packages/desktop-client/src/components/autocomplete/CategoryAutocomplete.tsx index 19d3f40437..178b6d05b3 100644 --- a/packages/desktop-client/src/components/autocomplete/CategoryAutocomplete.tsx +++ b/packages/desktop-client/src/components/autocomplete/CategoryAutocomplete.tsx @@ -29,16 +29,13 @@ import type { import { Autocomplete, defaultFilterSuggestion } from './Autocomplete'; import { ItemHeader } from './ItemHeader'; -import { useEnvelopeSheetValue } from '@desktop-client/components/budget/envelope/EnvelopeBudgetComponents'; -import { makeAmountFullStyle } from '@desktop-client/components/budget/util'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { useCategories } from '@desktop-client/hooks/useCategories'; -import { useSheetValue } from '@desktop-client/hooks/useSheetValue'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; -import { - envelopeBudget, - trackingBudget, -} from '@desktop-client/spreadsheet/bindings'; +import { useEnvelopeSheetValue } from '#components/budget/envelope/EnvelopeBudgetComponents'; +import { makeAmountFullStyle } from '#components/budget/util'; +import { FinancialText } from '#components/FinancialText'; +import { useCategories } from '#hooks/useCategories'; +import { useSheetValue } from '#hooks/useSheetValue'; +import { useSyncedPref } from '#hooks/useSyncedPref'; +import { envelopeBudget, trackingBudget } from '#spreadsheet/bindings'; type CategoryAutocompleteItem = Omit & { group?: CategoryGroupEntity; diff --git a/packages/desktop-client/src/components/autocomplete/CategoryGroupAutocomplete.tsx b/packages/desktop-client/src/components/autocomplete/CategoryGroupAutocomplete.tsx index 44354a8190..5891306873 100644 --- a/packages/desktop-client/src/components/autocomplete/CategoryGroupAutocomplete.tsx +++ b/packages/desktop-client/src/components/autocomplete/CategoryGroupAutocomplete.tsx @@ -19,7 +19,7 @@ import type { CategoryGroupEntity } from 'loot-core/types/models'; import { Autocomplete } from './Autocomplete'; -import { useCategories } from '@desktop-client/hooks/useCategories'; +import { useCategories } from '#hooks/useCategories'; type CategoryGroupAutocompleteItem = CategoryGroupEntity; diff --git a/packages/desktop-client/src/components/autocomplete/FilterAutocomplete.tsx b/packages/desktop-client/src/components/autocomplete/FilterAutocomplete.tsx index 244a0f7c46..ac0f3626b5 100644 --- a/packages/desktop-client/src/components/autocomplete/FilterAutocomplete.tsx +++ b/packages/desktop-client/src/components/autocomplete/FilterAutocomplete.tsx @@ -6,7 +6,7 @@ import type { TransactionFilterEntity } from 'loot-core/types/models'; import { Autocomplete } from './Autocomplete'; import { FilterList } from './FilterList'; -import { useTransactionFilters } from '@desktop-client/hooks/useTransactionFilters'; +import { useTransactionFilters } from '#hooks/useTransactionFilters'; export function FilterAutocomplete({ embedded, diff --git a/packages/desktop-client/src/components/autocomplete/PayeeAutocomplete.test.tsx b/packages/desktop-client/src/components/autocomplete/PayeeAutocomplete.test.tsx index 965026137d..e6db7b202d 100644 --- a/packages/desktop-client/src/components/autocomplete/PayeeAutocomplete.test.tsx +++ b/packages/desktop-client/src/components/autocomplete/PayeeAutocomplete.test.tsx @@ -14,10 +14,10 @@ import type { import { PayeeAutocomplete } from './PayeeAutocomplete'; import type { PayeeAutocompleteProps } from './PayeeAutocomplete'; -import { AuthProvider } from '@desktop-client/auth/AuthProvider'; -import { useNearbyPayees } from '@desktop-client/hooks/useNearbyPayees'; -import { createTestQueryClient, TestProviders } from '@desktop-client/mocks'; -import { payeeQueries } from '@desktop-client/payees'; +import { AuthProvider } from '#auth/AuthProvider'; +import { useNearbyPayees } from '#hooks/useNearbyPayees'; +import { createTestQueryClient, TestProviders } from '#mocks'; +import { payeeQueries } from '#payees'; const PAYEE_SELECTOR = '[data-testid][role=option]'; const PAYEE_SECTION_SELECTOR = '[data-testid$="-item-group"]'; @@ -108,7 +108,7 @@ async function clickAutocomplete(autocomplete: HTMLElement) { await waitForAutocomplete(); } -vi.mock('@desktop-client/hooks/useNearbyPayees', () => ({ +vi.mock('#hooks/useNearbyPayees', () => ({ useNearbyPayees: vi.fn(), })); diff --git a/packages/desktop-client/src/components/autocomplete/PayeeAutocomplete.tsx b/packages/desktop-client/src/components/autocomplete/PayeeAutocomplete.tsx index 24461c0479..0d8ae428c7 100644 --- a/packages/desktop-client/src/components/autocomplete/PayeeAutocomplete.tsx +++ b/packages/desktop-client/src/components/autocomplete/PayeeAutocomplete.tsx @@ -39,15 +39,15 @@ import { } from './Autocomplete'; import { ItemHeader } from './ItemHeader'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; -import { useCommonPayees } from '@desktop-client/hooks/useCommonPayees'; -import { useNearbyPayees } from '@desktop-client/hooks/useNearbyPayees'; -import { usePayees } from '@desktop-client/hooks/usePayees'; +import { useAccounts } from '#hooks/useAccounts'; +import { useCommonPayees } from '#hooks/useCommonPayees'; +import { useNearbyPayees } from '#hooks/useNearbyPayees'; +import { usePayees } from '#hooks/usePayees'; import { getActivePayees, useCreatePayeeMutation, useDeletePayeeLocationMutation, -} from '@desktop-client/payees'; +} from '#payees'; type PayeeAutocompleteItem = PayeeEntity & PayeeItemType & { diff --git a/packages/desktop-client/src/components/autocomplete/ReportAutocomplete.tsx b/packages/desktop-client/src/components/autocomplete/ReportAutocomplete.tsx index d3d011a47f..1acbb34516 100644 --- a/packages/desktop-client/src/components/autocomplete/ReportAutocomplete.tsx +++ b/packages/desktop-client/src/components/autocomplete/ReportAutocomplete.tsx @@ -6,7 +6,7 @@ import type { CustomReportEntity } from 'loot-core/types/models'; import { Autocomplete } from './Autocomplete'; import { ReportList } from './ReportList'; -import { useReports } from '@desktop-client/hooks/useReports'; +import { useReports } from '#hooks/useReports'; type ReportAutocompleteProps = { embedded?: boolean; diff --git a/packages/desktop-client/src/components/banksync/AccountRow.tsx b/packages/desktop-client/src/components/banksync/AccountRow.tsx index 426d8e36e4..010b505f8d 100644 --- a/packages/desktop-client/src/components/banksync/AccountRow.tsx +++ b/packages/desktop-client/src/components/banksync/AccountRow.tsx @@ -11,7 +11,7 @@ import type { Locale } from 'date-fns'; import { tsToRelativeTime } from 'loot-core/shared/util'; import type { AccountEntity } from 'loot-core/types/models'; -import { Cell, Row } from '@desktop-client/components/table'; +import { Cell, Row } from '#components/table'; type AccountRowProps = { account: AccountEntity; diff --git a/packages/desktop-client/src/components/banksync/AccountsHeader.tsx b/packages/desktop-client/src/components/banksync/AccountsHeader.tsx index 0b1aa2358e..bd66173b71 100644 --- a/packages/desktop-client/src/components/banksync/AccountsHeader.tsx +++ b/packages/desktop-client/src/components/banksync/AccountsHeader.tsx @@ -1,7 +1,7 @@ import React from 'react'; import { useTranslation } from 'react-i18next'; -import { Cell, TableHeader } from '@desktop-client/components/table'; +import { Cell, TableHeader } from '#components/table'; type AccountsHeaderProps = { unlinked: boolean; diff --git a/packages/desktop-client/src/components/banksync/AccountsList.tsx b/packages/desktop-client/src/components/banksync/AccountsList.tsx index ab342d47fa..672f723d12 100644 --- a/packages/desktop-client/src/components/banksync/AccountsList.tsx +++ b/packages/desktop-client/src/components/banksync/AccountsList.tsx @@ -6,7 +6,7 @@ import type { AccountEntity } from 'loot-core/types/models'; import { AccountRow } from './AccountRow'; -import { useLocale } from '@desktop-client/hooks/useLocale'; +import { useLocale } from '#hooks/useLocale'; type AccountsListProps = { accounts: AccountEntity[]; diff --git a/packages/desktop-client/src/components/banksync/BankSyncCheckboxOptions.tsx b/packages/desktop-client/src/components/banksync/BankSyncCheckboxOptions.tsx index fbd5d1de14..2eec76ba5b 100644 --- a/packages/desktop-client/src/components/banksync/BankSyncCheckboxOptions.tsx +++ b/packages/desktop-client/src/components/banksync/BankSyncCheckboxOptions.tsx @@ -9,8 +9,8 @@ import { Text } from '@actual-app/components/text'; import { theme } from '@actual-app/components/theme'; import { Tooltip } from '@actual-app/components/tooltip'; -import { LabeledCheckbox } from '@desktop-client/components/forms/LabeledCheckbox'; -import { ToggleField } from '@desktop-client/components/mobile/MobileForms'; +import { LabeledCheckbox } from '#components/forms/LabeledCheckbox'; +import { ToggleField } from '#components/mobile/MobileForms'; type CheckboxOptionProps = { id: string; diff --git a/packages/desktop-client/src/components/banksync/EditSyncAccount.tsx b/packages/desktop-client/src/components/banksync/EditSyncAccount.tsx index 30a49cb770..58e464e44a 100644 --- a/packages/desktop-client/src/components/banksync/EditSyncAccount.tsx +++ b/packages/desktop-client/src/components/banksync/EditSyncAccount.tsx @@ -13,14 +13,10 @@ import { BankSyncCheckboxOptions } from './BankSyncCheckboxOptions'; import { FieldMapping } from './FieldMapping'; import { useBankSyncAccountSettings } from './useBankSyncAccountSettings'; -import { useUnlinkAccountMutation } from '@desktop-client/accounts'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { useUnlinkAccountMutation } from '#accounts'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { pushModal } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; export type TransactionDirection = 'payment' | 'deposit'; diff --git a/packages/desktop-client/src/components/banksync/FieldMapping.tsx b/packages/desktop-client/src/components/banksync/FieldMapping.tsx index b48d25087d..2eba7bfecb 100644 --- a/packages/desktop-client/src/components/banksync/FieldMapping.tsx +++ b/packages/desktop-client/src/components/banksync/FieldMapping.tsx @@ -14,7 +14,7 @@ import type { TransactionDirection, } from './EditSyncAccount'; -import { Cell, Row, TableHeader } from '@desktop-client/components/table'; +import { Cell, Row, TableHeader } from '#components/table'; const useTransactionDirectionOptions = () => { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/banksync/index.tsx b/packages/desktop-client/src/components/banksync/index.tsx index 44321c65e5..bb792ceeee 100644 --- a/packages/desktop-client/src/components/banksync/index.tsx +++ b/packages/desktop-client/src/components/banksync/index.tsx @@ -11,12 +11,12 @@ import type { AccountEntity, BankSyncProviders } from 'loot-core/types/models'; import { AccountsHeader } from './AccountsHeader'; import { AccountsList } from './AccountsList'; -import { MOBILE_NAV_HEIGHT } from '@desktop-client/components/mobile/MobileNavTabs'; -import { Page } from '@desktop-client/components/Page'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; -import { useGlobalPref } from '@desktop-client/hooks/useGlobalPref'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { MOBILE_NAV_HEIGHT } from '#components/mobile/MobileNavTabs'; +import { Page } from '#components/Page'; +import { useAccounts } from '#hooks/useAccounts'; +import { useGlobalPref } from '#hooks/useGlobalPref'; +import { pushModal } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; type SyncProviders = BankSyncProviders | 'unlinked'; diff --git a/packages/desktop-client/src/components/banksync/useBankSyncAccountSettings.ts b/packages/desktop-client/src/components/banksync/useBankSyncAccountSettings.ts index cb1bb87181..52607637c7 100644 --- a/packages/desktop-client/src/components/banksync/useBankSyncAccountSettings.ts +++ b/packages/desktop-client/src/components/banksync/useBankSyncAccountSettings.ts @@ -14,8 +14,8 @@ import type { TransactionDirection, } from './EditSyncAccount'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; -import { useTransactions } from '@desktop-client/hooks/useTransactions'; +import { useSyncedPref } from '#hooks/useSyncedPref'; +import { useTransactions } from '#hooks/useTransactions'; export function useBankSyncAccountSettings(accountId: string) { const [savedMappings = mappingsToString(defaultMappings), setSavedMappings] = diff --git a/packages/desktop-client/src/components/budget/BalanceWithCarryover.tsx b/packages/desktop-client/src/components/budget/BalanceWithCarryover.tsx index 37efa00397..3974ebb04c 100644 --- a/packages/desktop-client/src/components/budget/BalanceWithCarryover.tsx +++ b/packages/desktop-client/src/components/budget/BalanceWithCarryover.tsx @@ -19,14 +19,11 @@ import type { TransObjectLiteral } from 'loot-core/types/util'; import { makeBalanceAmountStyle } from './util'; -import { - CellValue, - CellValueText, -} from '@desktop-client/components/spreadsheet/CellValue'; -import { useFeatureFlag } from '@desktop-client/hooks/useFeatureFlag'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useSheetValue } from '@desktop-client/hooks/useSheetValue'; -import type { Binding } from '@desktop-client/spreadsheet'; +import { CellValue, CellValueText } from '#components/spreadsheet/CellValue'; +import { useFeatureFlag } from '#hooks/useFeatureFlag'; +import { useFormat } from '#hooks/useFormat'; +import { useSheetValue } from '#hooks/useSheetValue'; +import type { Binding } from '#spreadsheet'; type CarryoverIndicatorProps = { style?: CSSProperties; diff --git a/packages/desktop-client/src/components/budget/BudgetCategories.tsx b/packages/desktop-client/src/components/budget/BudgetCategories.tsx index fd21888cd9..0228be17d7 100644 --- a/packages/desktop-client/src/components/budget/BudgetCategories.tsx +++ b/packages/desktop-client/src/components/budget/BudgetCategories.tsx @@ -18,13 +18,10 @@ import { SidebarCategory } from './SidebarCategory'; import { SidebarGroup } from './SidebarGroup'; import { separateGroups } from './util'; -import { DropHighlightPosContext } from '@desktop-client/components/sort'; -import type { - DragState, - OnDropCallback, -} from '@desktop-client/components/sort'; -import { Row } from '@desktop-client/components/table'; -import { useLocalPref } from '@desktop-client/hooks/useLocalPref'; +import { DropHighlightPosContext } from '#components/sort'; +import type { DragState, OnDropCallback } from '#components/sort'; +import { Row } from '#components/table'; +import { useLocalPref } from '#hooks/useLocalPref'; type BudgetItem = | { type: 'new-group' } diff --git a/packages/desktop-client/src/components/budget/BudgetPageHeader.tsx b/packages/desktop-client/src/components/budget/BudgetPageHeader.tsx index a42d4922aa..61dc7d3f03 100644 --- a/packages/desktop-client/src/components/budget/BudgetPageHeader.tsx +++ b/packages/desktop-client/src/components/budget/BudgetPageHeader.tsx @@ -7,7 +7,7 @@ import { View } from '@actual-app/components/view'; import { MonthPicker } from './MonthPicker'; import { getScrollbarWidth } from './util'; -import { useGlobalPref } from '@desktop-client/hooks/useGlobalPref'; +import { useGlobalPref } from '#hooks/useGlobalPref'; type BudgetPageHeaderProps = { startMonth: string; diff --git a/packages/desktop-client/src/components/budget/BudgetSummaries.tsx b/packages/desktop-client/src/components/budget/BudgetSummaries.tsx index c9778f6088..6769c40bc6 100644 --- a/packages/desktop-client/src/components/budget/BudgetSummaries.tsx +++ b/packages/desktop-client/src/components/budget/BudgetSummaries.tsx @@ -17,7 +17,7 @@ import { MonthsContext } from './MonthsContext'; import { useBudgetComponents } from '.'; -import { useResizeObserver } from '@desktop-client/hooks/useResizeObserver'; +import { useResizeObserver } from '#hooks/useResizeObserver'; export function BudgetSummaries() { const { months } = useContext(MonthsContext); diff --git a/packages/desktop-client/src/components/budget/BudgetTable.tsx b/packages/desktop-client/src/components/budget/BudgetTable.tsx index 8c727035aa..062c455dce 100644 --- a/packages/desktop-client/src/components/budget/BudgetTable.tsx +++ b/packages/desktop-client/src/components/budget/BudgetTable.tsx @@ -23,11 +23,11 @@ import { separateGroups, } from './util'; -import type { DropPosition } from '@desktop-client/components/sort'; -import { SchedulesProvider } from '@desktop-client/hooks/useCachedSchedules'; -import { useCategories } from '@desktop-client/hooks/useCategories'; -import { useGlobalPref } from '@desktop-client/hooks/useGlobalPref'; -import { useLocalPref } from '@desktop-client/hooks/useLocalPref'; +import type { DropPosition } from '#components/sort'; +import { SchedulesProvider } from '#hooks/useCachedSchedules'; +import { useCategories } from '#hooks/useCategories'; +import { useGlobalPref } from '#hooks/useGlobalPref'; +import { useLocalPref } from '#hooks/useLocalPref'; type BudgetTableProps = { type: string; diff --git a/packages/desktop-client/src/components/budget/BudgetTotals.tsx b/packages/desktop-client/src/components/budget/BudgetTotals.tsx index 647e11a8f1..e86e82ec21 100644 --- a/packages/desktop-client/src/components/budget/BudgetTotals.tsx +++ b/packages/desktop-client/src/components/budget/BudgetTotals.tsx @@ -19,7 +19,7 @@ import { getScrollbarWidth } from './util'; import { useBudgetComponents } from '.'; -import { useGlobalPref } from '@desktop-client/hooks/useGlobalPref'; +import { useGlobalPref } from '#hooks/useGlobalPref'; type BudgetTotalsProps = { toggleHiddenCategories: () => void; diff --git a/packages/desktop-client/src/components/budget/DynamicBudgetTable.tsx b/packages/desktop-client/src/components/budget/DynamicBudgetTable.tsx index bb1b5a7136..9cc52611b1 100644 --- a/packages/desktop-client/src/components/budget/DynamicBudgetTable.tsx +++ b/packages/desktop-client/src/components/budget/DynamicBudgetTable.tsx @@ -12,7 +12,7 @@ import { useBudgetMonthCount } from './BudgetMonthCountContext'; import { BudgetPageHeader } from './BudgetPageHeader'; import { BudgetTable } from './BudgetTable'; -import { useGlobalPref } from '@desktop-client/hooks/useGlobalPref'; +import { useGlobalPref } from '#hooks/useGlobalPref'; function getNumPossibleMonths(width: number, categoryWidth: number) { const estimatedTableWidth = width - categoryWidth; diff --git a/packages/desktop-client/src/components/budget/ExpenseCategory.tsx b/packages/desktop-client/src/components/budget/ExpenseCategory.tsx index 0afc324e40..f6d5d6a94f 100644 --- a/packages/desktop-client/src/components/budget/ExpenseCategory.tsx +++ b/packages/desktop-client/src/components/budget/ExpenseCategory.tsx @@ -15,18 +15,14 @@ import { SidebarCategory } from './SidebarCategory'; import { useBudgetComponents } from '.'; -import { - DropHighlight, - useDraggable, - useDroppable, -} from '@desktop-client/components/sort'; +import { DropHighlight, useDraggable, useDroppable } from '#components/sort'; import type { DragState, OnDragChangeCallback, OnDropCallback, -} from '@desktop-client/components/sort'; -import { Row } from '@desktop-client/components/table'; -import { useDragRef } from '@desktop-client/hooks/useDragRef'; +} from '#components/sort'; +import { Row } from '#components/table'; +import { useDragRef } from '#hooks/useDragRef'; type ExpenseCategoryProps = { cat: CategoryEntity; diff --git a/packages/desktop-client/src/components/budget/ExpenseGroup.tsx b/packages/desktop-client/src/components/budget/ExpenseGroup.tsx index 492f0abd50..57f8d8a2d3 100644 --- a/packages/desktop-client/src/components/budget/ExpenseGroup.tsx +++ b/packages/desktop-client/src/components/budget/ExpenseGroup.tsx @@ -15,18 +15,14 @@ import { SidebarGroup } from './SidebarGroup'; import { useBudgetComponents } from '.'; -import { - DropHighlight, - useDraggable, - useDroppable, -} from '@desktop-client/components/sort'; +import { DropHighlight, useDraggable, useDroppable } from '#components/sort'; import type { DragState, OnDragChangeCallback, OnDropCallback, -} from '@desktop-client/components/sort'; -import { Row, ROW_HEIGHT } from '@desktop-client/components/table'; -import { useDragRef } from '@desktop-client/hooks/useDragRef'; +} from '#components/sort'; +import { Row, ROW_HEIGHT } from '#components/table'; +import { useDragRef } from '#hooks/useDragRef'; type ExpenseGroupProps = { group: ComponentProps['group']; diff --git a/packages/desktop-client/src/components/budget/IncomeCategory.tsx b/packages/desktop-client/src/components/budget/IncomeCategory.tsx index ac8b8cd1f8..59009a6d30 100644 --- a/packages/desktop-client/src/components/budget/IncomeCategory.tsx +++ b/packages/desktop-client/src/components/budget/IncomeCategory.tsx @@ -9,17 +9,10 @@ import { SidebarCategory } from './SidebarCategory'; import { useBudgetComponents } from '.'; -import { - DropHighlight, - useDraggable, - useDroppable, -} from '@desktop-client/components/sort'; -import type { - OnDragChangeCallback, - OnDropCallback, -} from '@desktop-client/components/sort'; -import { Row } from '@desktop-client/components/table'; -import { useDragRef } from '@desktop-client/hooks/useDragRef'; +import { DropHighlight, useDraggable, useDroppable } from '#components/sort'; +import type { OnDragChangeCallback, OnDropCallback } from '#components/sort'; +import { Row } from '#components/table'; +import { useDragRef } from '#hooks/useDragRef'; type IncomeCategoryProps = { cat: CategoryEntity; diff --git a/packages/desktop-client/src/components/budget/IncomeGroup.tsx b/packages/desktop-client/src/components/budget/IncomeGroup.tsx index b43fad4da1..ce7e7cc08d 100644 --- a/packages/desktop-client/src/components/budget/IncomeGroup.tsx +++ b/packages/desktop-client/src/components/budget/IncomeGroup.tsx @@ -10,7 +10,7 @@ import { SidebarGroup } from './SidebarGroup'; import { useBudgetComponents } from '.'; -import { Row } from '@desktop-client/components/table'; +import { Row } from '#components/table'; type IncomeGroupProps = { group: CategoryGroupEntity; diff --git a/packages/desktop-client/src/components/budget/IncomeHeader.tsx b/packages/desktop-client/src/components/budget/IncomeHeader.tsx index f181fb023b..f4e1bc4fa9 100644 --- a/packages/desktop-client/src/components/budget/IncomeHeader.tsx +++ b/packages/desktop-client/src/components/budget/IncomeHeader.tsx @@ -8,7 +8,7 @@ import { RenderMonths } from './RenderMonths'; import { useBudgetComponents } from '.'; -import { useGlobalPref } from '@desktop-client/hooks/useGlobalPref'; +import { useGlobalPref } from '#hooks/useGlobalPref'; type IncomeHeaderProps = { onShowNewGroup: () => void; diff --git a/packages/desktop-client/src/components/budget/MonthPicker.tsx b/packages/desktop-client/src/components/budget/MonthPicker.tsx index 52ccd238cc..e3d2416e63 100644 --- a/packages/desktop-client/src/components/budget/MonthPicker.tsx +++ b/packages/desktop-client/src/components/budget/MonthPicker.tsx @@ -16,9 +16,9 @@ import * as monthUtils from 'loot-core/shared/months'; import type { MonthBounds } from './MonthsContext'; -import { Link } from '@desktop-client/components/common/Link'; -import { useLocale } from '@desktop-client/hooks/useLocale'; -import { useResizeObserver } from '@desktop-client/hooks/useResizeObserver'; +import { Link } from '#components/common/Link'; +import { useLocale } from '#hooks/useLocale'; +import { useResizeObserver } from '#hooks/useResizeObserver'; type MonthPickerProps = { startMonth: string; diff --git a/packages/desktop-client/src/components/budget/RenderMonths.tsx b/packages/desktop-client/src/components/budget/RenderMonths.tsx index c9cc2c1edf..4203363cf3 100644 --- a/packages/desktop-client/src/components/budget/RenderMonths.tsx +++ b/packages/desktop-client/src/components/budget/RenderMonths.tsx @@ -8,7 +8,7 @@ import * as monthUtils from 'loot-core/shared/months'; import { MonthsContext } from './MonthsContext'; -import { SheetNameProvider } from '@desktop-client/hooks/useSheetName'; +import { SheetNameProvider } from '#hooks/useSheetName'; type RenderMonthsProps = { children: ReactNode | (({ month }: { month: string }) => ReactNode); diff --git a/packages/desktop-client/src/components/budget/SidebarCategory.tsx b/packages/desktop-client/src/components/budget/SidebarCategory.tsx index c6b4cae875..6a7720ce68 100644 --- a/packages/desktop-client/src/components/budget/SidebarCategory.tsx +++ b/packages/desktop-client/src/components/budget/SidebarCategory.tsx @@ -18,9 +18,9 @@ import type { import { SidebarCategoryButtons } from './SidebarCategoryButtons'; -import { InputCell } from '@desktop-client/components/table'; -import { useContextMenu } from '@desktop-client/hooks/useContextMenu'; -import { useGlobalPref } from '@desktop-client/hooks/useGlobalPref'; +import { InputCell } from '#components/table'; +import { useContextMenu } from '#hooks/useContextMenu'; +import { useGlobalPref } from '#hooks/useGlobalPref'; type SidebarCategoryProps = { innerRef: Ref; diff --git a/packages/desktop-client/src/components/budget/SidebarCategoryButtons.tsx b/packages/desktop-client/src/components/budget/SidebarCategoryButtons.tsx index 1e9a2e91d7..5e173c59ed 100644 --- a/packages/desktop-client/src/components/budget/SidebarCategoryButtons.tsx +++ b/packages/desktop-client/src/components/budget/SidebarCategoryButtons.tsx @@ -5,9 +5,9 @@ import type { CategoryEntity } from 'loot-core/types/models/category'; import { CategoryAutomationButton } from './goals/CategoryAutomationButton'; -import { NotesButton } from '@desktop-client/components/NotesButton'; -import { useFeatureFlag } from '@desktop-client/hooks/useFeatureFlag'; -import { useNotes } from '@desktop-client/hooks/useNotes'; +import { NotesButton } from '#components/NotesButton'; +import { useFeatureFlag } from '#hooks/useFeatureFlag'; +import { useNotes } from '#hooks/useNotes'; type SidebarCategoryButtonsProps = { category: CategoryEntity; diff --git a/packages/desktop-client/src/components/budget/SidebarGroup.tsx b/packages/desktop-client/src/components/budget/SidebarGroup.tsx index c80d0d9aa1..ef710eb7d4 100644 --- a/packages/desktop-client/src/components/budget/SidebarGroup.tsx +++ b/packages/desktop-client/src/components/budget/SidebarGroup.tsx @@ -19,11 +19,11 @@ import type { CategoryGroupEntity, } from 'loot-core/types/models'; -import { NotesButton } from '@desktop-client/components/NotesButton'; -import { InputCell } from '@desktop-client/components/table'; -import { useContextMenu } from '@desktop-client/hooks/useContextMenu'; -import { useFeatureFlag } from '@desktop-client/hooks/useFeatureFlag'; -import { useGlobalPref } from '@desktop-client/hooks/useGlobalPref'; +import { NotesButton } from '#components/NotesButton'; +import { InputCell } from '#components/table'; +import { useContextMenu } from '#hooks/useContextMenu'; +import { useFeatureFlag } from '#hooks/useFeatureFlag'; +import { useGlobalPref } from '#hooks/useGlobalPref'; type SidebarGroupProps = { group: CategoryGroupEntity; diff --git a/packages/desktop-client/src/components/budget/envelope/BalanceMenu.tsx b/packages/desktop-client/src/components/budget/envelope/BalanceMenu.tsx index a845156f71..e98c7f9075 100644 --- a/packages/desktop-client/src/components/budget/envelope/BalanceMenu.tsx +++ b/packages/desktop-client/src/components/budget/envelope/BalanceMenu.tsx @@ -6,7 +6,7 @@ import { Menu } from '@actual-app/components/menu'; import { useEnvelopeSheetValue } from './EnvelopeBudgetComponents'; -import { envelopeBudget } from '@desktop-client/spreadsheet/bindings'; +import { envelopeBudget } from '#spreadsheet/bindings'; type BalanceMenuProps = Omit< ComponentPropsWithoutRef, diff --git a/packages/desktop-client/src/components/budget/envelope/BalanceMovementMenu.tsx b/packages/desktop-client/src/components/budget/envelope/BalanceMovementMenu.tsx index 4ed717cc2b..c33080ddba 100644 --- a/packages/desktop-client/src/components/budget/envelope/BalanceMovementMenu.tsx +++ b/packages/desktop-client/src/components/budget/envelope/BalanceMovementMenu.tsx @@ -5,8 +5,8 @@ import { CoverMenu } from './CoverMenu'; import { useEnvelopeSheetValue } from './EnvelopeBudgetComponents'; import { TransferMenu } from './TransferMenu'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { envelopeBudget } from '@desktop-client/spreadsheet/bindings'; +import { useFormat } from '#hooks/useFormat'; +import { envelopeBudget } from '#spreadsheet/bindings'; type BalanceMovementMenuProps = { categoryId: string; diff --git a/packages/desktop-client/src/components/budget/envelope/BudgetMenu.tsx b/packages/desktop-client/src/components/budget/envelope/BudgetMenu.tsx index 3416bde64c..87571ab4cd 100644 --- a/packages/desktop-client/src/components/budget/envelope/BudgetMenu.tsx +++ b/packages/desktop-client/src/components/budget/envelope/BudgetMenu.tsx @@ -4,7 +4,7 @@ import { useTranslation } from 'react-i18next'; import { Menu } from '@actual-app/components/menu'; -import { useFeatureFlag } from '@desktop-client/hooks/useFeatureFlag'; +import { useFeatureFlag } from '#hooks/useFeatureFlag'; type BudgetMenuProps = Omit< ComponentPropsWithoutRef, diff --git a/packages/desktop-client/src/components/budget/envelope/CoverMenu.tsx b/packages/desktop-client/src/components/budget/envelope/CoverMenu.tsx index d365647376..d02c5b8bae 100644 --- a/packages/desktop-client/src/components/budget/envelope/CoverMenu.tsx +++ b/packages/desktop-client/src/components/budget/envelope/CoverMenu.tsx @@ -12,12 +12,12 @@ import { amountToInteger, integerToCurrency } from 'loot-core/shared/util'; import type { IntegerAmount } from 'loot-core/shared/util'; import type { CategoryEntity } from 'loot-core/types/models'; -import { CategoryAutocomplete } from '@desktop-client/components/autocomplete/CategoryAutocomplete'; +import { CategoryAutocomplete } from '#components/autocomplete/CategoryAutocomplete'; import { addToBeBudgetedGroup, removeCategoriesFromGroups, -} from '@desktop-client/components/budget/util'; -import { useCategories } from '@desktop-client/hooks/useCategories'; +} from '#components/budget/util'; +import { useCategories } from '#hooks/useCategories'; type CoverMenuProps = { showToBeBudgeted?: boolean; diff --git a/packages/desktop-client/src/components/budget/envelope/EnvelopeBudgetComponents.tsx b/packages/desktop-client/src/components/budget/envelope/EnvelopeBudgetComponents.tsx index 17e9d11e52..1ddcd3c90a 100644 --- a/packages/desktop-client/src/components/budget/envelope/EnvelopeBudgetComponents.tsx +++ b/packages/desktop-client/src/components/budget/envelope/EnvelopeBudgetComponents.tsx @@ -23,23 +23,20 @@ import { BalanceMovementMenu } from './BalanceMovementMenu'; import { BudgetMenu } from './BudgetMenu'; import { IncomeMenu } from './IncomeMenu'; -import { BalanceWithCarryover } from '@desktop-client/components/budget/BalanceWithCarryover'; -import { makeAmountGrey } from '@desktop-client/components/budget/util'; -import { - CellValue, - CellValueText, -} from '@desktop-client/components/spreadsheet/CellValue'; -import { Field, Row, SheetCell } from '@desktop-client/components/table'; -import type { SheetCellProps } from '@desktop-client/components/table'; -import { useCategoryScheduleGoalTemplateIndicator } from '@desktop-client/hooks/useCategoryScheduleGoalTemplateIndicator'; -import { useContextMenu } from '@desktop-client/hooks/useContextMenu'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { useSheetName } from '@desktop-client/hooks/useSheetName'; -import { useSheetValue } from '@desktop-client/hooks/useSheetValue'; -import { useUndo } from '@desktop-client/hooks/useUndo'; -import type { Binding, SheetFields } from '@desktop-client/spreadsheet'; -import { envelopeBudget } from '@desktop-client/spreadsheet/bindings'; +import { BalanceWithCarryover } from '#components/budget/BalanceWithCarryover'; +import { makeAmountGrey } from '#components/budget/util'; +import { CellValue, CellValueText } from '#components/spreadsheet/CellValue'; +import { Field, Row, SheetCell } from '#components/table'; +import type { SheetCellProps } from '#components/table'; +import { useCategoryScheduleGoalTemplateIndicator } from '#hooks/useCategoryScheduleGoalTemplateIndicator'; +import { useContextMenu } from '#hooks/useContextMenu'; +import { useFormat } from '#hooks/useFormat'; +import { useNavigate } from '#hooks/useNavigate'; +import { useSheetName } from '#hooks/useSheetName'; +import { useSheetValue } from '#hooks/useSheetValue'; +import { useUndo } from '#hooks/useUndo'; +import type { Binding, SheetFields } from '#spreadsheet'; +import { envelopeBudget } from '#spreadsheet/bindings'; export function useEnvelopeSheetName< FieldName extends SheetFields<'envelope-budget'>, diff --git a/packages/desktop-client/src/components/budget/envelope/HoldMenu.tsx b/packages/desktop-client/src/components/budget/envelope/HoldMenu.tsx index f6a040b40e..ebdac8dc52 100644 --- a/packages/desktop-client/src/components/budget/envelope/HoldMenu.tsx +++ b/packages/desktop-client/src/components/budget/envelope/HoldMenu.tsx @@ -8,8 +8,8 @@ import { View } from '@actual-app/components/view'; import type { IntegerAmount } from 'loot-core/shared/util'; -import { FinancialInput } from '@desktop-client/components/util/FinancialInput'; -import { useSheetValue } from '@desktop-client/hooks/useSheetValue'; +import { FinancialInput } from '#components/util/FinancialInput'; +import { useSheetValue } from '#hooks/useSheetValue'; type HoldMenuProps = { onSubmit: (amount: number) => void; diff --git a/packages/desktop-client/src/components/budget/envelope/IncomeMenu.tsx b/packages/desktop-client/src/components/budget/envelope/IncomeMenu.tsx index ac1377043e..6f8940c681 100644 --- a/packages/desktop-client/src/components/budget/envelope/IncomeMenu.tsx +++ b/packages/desktop-client/src/components/budget/envelope/IncomeMenu.tsx @@ -6,7 +6,7 @@ import type { CategoryEntity } from 'loot-core/types/models'; import { useEnvelopeSheetValue } from './EnvelopeBudgetComponents'; -import { envelopeBudget } from '@desktop-client/spreadsheet/bindings'; +import { envelopeBudget } from '#spreadsheet/bindings'; type IncomeMenuProps = { categoryId: string; diff --git a/packages/desktop-client/src/components/budget/envelope/TransferMenu.tsx b/packages/desktop-client/src/components/budget/envelope/TransferMenu.tsx index f7272e1904..a2fb8acef9 100644 --- a/packages/desktop-client/src/components/budget/envelope/TransferMenu.tsx +++ b/packages/desktop-client/src/components/budget/envelope/TransferMenu.tsx @@ -9,13 +9,13 @@ import { View } from '@actual-app/components/view'; import type { IntegerAmount } from 'loot-core/shared/util'; import type { CategoryEntity } from 'loot-core/types/models'; -import { CategoryAutocomplete } from '@desktop-client/components/autocomplete/CategoryAutocomplete'; +import { CategoryAutocomplete } from '#components/autocomplete/CategoryAutocomplete'; import { addToBeBudgetedGroup, removeCategoriesFromGroups, -} from '@desktop-client/components/budget/util'; -import { FinancialInput } from '@desktop-client/components/util/FinancialInput'; -import { useCategories } from '@desktop-client/hooks/useCategories'; +} from '#components/budget/util'; +import { FinancialInput } from '#components/util/FinancialInput'; +import { useCategories } from '#hooks/useCategories'; type TransferMenuProps = { categoryId?: CategoryEntity['id']; diff --git a/packages/desktop-client/src/components/budget/envelope/budgetsummary/BudgetMonthMenu.tsx b/packages/desktop-client/src/components/budget/envelope/budgetsummary/BudgetMonthMenu.tsx index 9cbea4c3e4..5ee1983ac2 100644 --- a/packages/desktop-client/src/components/budget/envelope/budgetsummary/BudgetMonthMenu.tsx +++ b/packages/desktop-client/src/components/budget/envelope/budgetsummary/BudgetMonthMenu.tsx @@ -4,7 +4,7 @@ import { useTranslation } from 'react-i18next'; import { Menu } from '@actual-app/components/menu'; -import { useFeatureFlag } from '@desktop-client/hooks/useFeatureFlag'; +import { useFeatureFlag } from '#hooks/useFeatureFlag'; type BudgetMonthMenuProps = Omit< ComponentPropsWithoutRef, diff --git a/packages/desktop-client/src/components/budget/envelope/budgetsummary/BudgetSummary.tsx b/packages/desktop-client/src/components/budget/envelope/budgetsummary/BudgetSummary.tsx index 7e63a0153b..8d491437cb 100644 --- a/packages/desktop-client/src/components/budget/envelope/budgetsummary/BudgetSummary.tsx +++ b/packages/desktop-client/src/components/budget/envelope/budgetsummary/BudgetSummary.tsx @@ -19,11 +19,11 @@ import { BudgetMonthMenu } from './BudgetMonthMenu'; import { ToBudget } from './ToBudget'; import { TotalsList } from './TotalsList'; -import { useEnvelopeBudget } from '@desktop-client/components/budget/envelope/EnvelopeBudgetContext'; -import { NotesButton } from '@desktop-client/components/NotesButton'; -import { useLocale } from '@desktop-client/hooks/useLocale'; -import { SheetNameProvider } from '@desktop-client/hooks/useSheetName'; -import { useUndo } from '@desktop-client/hooks/useUndo'; +import { useEnvelopeBudget } from '#components/budget/envelope/EnvelopeBudgetContext'; +import { NotesButton } from '#components/NotesButton'; +import { useLocale } from '#hooks/useLocale'; +import { SheetNameProvider } from '#hooks/useSheetName'; +import { useUndo } from '#hooks/useUndo'; type BudgetSummaryProps = { month: string; diff --git a/packages/desktop-client/src/components/budget/envelope/budgetsummary/ToBudget.tsx b/packages/desktop-client/src/components/budget/envelope/budgetsummary/ToBudget.tsx index 0993a5ed2e..a8b6504237 100644 --- a/packages/desktop-client/src/components/budget/envelope/budgetsummary/ToBudget.tsx +++ b/packages/desktop-client/src/components/budget/envelope/budgetsummary/ToBudget.tsx @@ -7,13 +7,13 @@ import { View } from '@actual-app/components/view'; import { ToBudgetAmount } from './ToBudgetAmount'; import { ToBudgetMenu } from './ToBudgetMenu'; -import { CoverMenu } from '@desktop-client/components/budget/envelope/CoverMenu'; -import { useEnvelopeSheetValue } from '@desktop-client/components/budget/envelope/EnvelopeBudgetComponents'; -import { HoldMenu } from '@desktop-client/components/budget/envelope/HoldMenu'; -import { TransferMenu } from '@desktop-client/components/budget/envelope/TransferMenu'; -import { useContextMenu } from '@desktop-client/hooks/useContextMenu'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { envelopeBudget } from '@desktop-client/spreadsheet/bindings'; +import { CoverMenu } from '#components/budget/envelope/CoverMenu'; +import { useEnvelopeSheetValue } from '#components/budget/envelope/EnvelopeBudgetComponents'; +import { HoldMenu } from '#components/budget/envelope/HoldMenu'; +import { TransferMenu } from '#components/budget/envelope/TransferMenu'; +import { useContextMenu } from '#hooks/useContextMenu'; +import { useFormat } from '#hooks/useFormat'; +import { envelopeBudget } from '#spreadsheet/bindings'; type ToBudgetProps = { month: string; diff --git a/packages/desktop-client/src/components/budget/envelope/budgetsummary/ToBudgetAmount.tsx b/packages/desktop-client/src/components/budget/envelope/budgetsummary/ToBudgetAmount.tsx index a8d3dc0fe1..6ff5c9a5f6 100644 --- a/packages/desktop-client/src/components/budget/envelope/budgetsummary/ToBudgetAmount.tsx +++ b/packages/desktop-client/src/components/budget/envelope/budgetsummary/ToBudgetAmount.tsx @@ -14,11 +14,11 @@ import { TotalsList } from './TotalsList'; import { useEnvelopeSheetName, useEnvelopeSheetValue, -} from '@desktop-client/components/budget/envelope/EnvelopeBudgetComponents'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { envelopeBudget } from '@desktop-client/spreadsheet/bindings'; +} from '#components/budget/envelope/EnvelopeBudgetComponents'; +import { FinancialText } from '#components/FinancialText'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { useFormat } from '#hooks/useFormat'; +import { envelopeBudget } from '#spreadsheet/bindings'; type ToBudgetAmountProps = { prevMonthName: string; diff --git a/packages/desktop-client/src/components/budget/envelope/budgetsummary/ToBudgetMenu.tsx b/packages/desktop-client/src/components/budget/envelope/budgetsummary/ToBudgetMenu.tsx index fb2305b59b..831548cc10 100644 --- a/packages/desktop-client/src/components/budget/envelope/budgetsummary/ToBudgetMenu.tsx +++ b/packages/desktop-client/src/components/budget/envelope/budgetsummary/ToBudgetMenu.tsx @@ -4,8 +4,8 @@ import { useTranslation } from 'react-i18next'; import { Menu } from '@actual-app/components/menu'; -import { useEnvelopeSheetValue } from '@desktop-client/components/budget/envelope/EnvelopeBudgetComponents'; -import { envelopeBudget } from '@desktop-client/spreadsheet/bindings'; +import { useEnvelopeSheetValue } from '#components/budget/envelope/EnvelopeBudgetComponents'; +import { envelopeBudget } from '#spreadsheet/bindings'; type ToBudgetMenuProps = Omit< ComponentPropsWithoutRef, diff --git a/packages/desktop-client/src/components/budget/envelope/budgetsummary/TotalsList.tsx b/packages/desktop-client/src/components/budget/envelope/budgetsummary/TotalsList.tsx index d4fdcf16f7..c324a267c1 100644 --- a/packages/desktop-client/src/components/budget/envelope/budgetsummary/TotalsList.tsx +++ b/packages/desktop-client/src/components/budget/envelope/budgetsummary/TotalsList.tsx @@ -8,11 +8,11 @@ import { styles } from '@actual-app/components/styles'; import { Tooltip } from '@actual-app/components/tooltip'; import { View } from '@actual-app/components/view'; -import { EnvelopeCellValue } from '@desktop-client/components/budget/envelope/EnvelopeBudgetComponents'; -import { CellValueText } from '@desktop-client/components/spreadsheet/CellValue'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import type { FormatType } from '@desktop-client/hooks/useFormat'; -import { envelopeBudget } from '@desktop-client/spreadsheet/bindings'; +import { EnvelopeCellValue } from '#components/budget/envelope/EnvelopeBudgetComponents'; +import { CellValueText } from '#components/spreadsheet/CellValue'; +import { useFormat } from '#hooks/useFormat'; +import type { FormatType } from '#hooks/useFormat'; +import { envelopeBudget } from '#spreadsheet/bindings'; /** * Creates a formatter that displays values with explicit +/- signs. diff --git a/packages/desktop-client/src/components/budget/goals/BudgetAutomation.tsx b/packages/desktop-client/src/components/budget/goals/BudgetAutomation.tsx index 584dcce077..fa75be20a8 100644 --- a/packages/desktop-client/src/components/budget/goals/BudgetAutomation.tsx +++ b/packages/desktop-client/src/components/budget/goals/BudgetAutomation.tsx @@ -15,7 +15,7 @@ import { BudgetAutomationReadOnly } from './BudgetAutomationReadOnly'; import type { DisplayTemplateType } from './constants'; import { DEFAULT_PRIORITY, getInitialState, templateReducer } from './reducer'; -import { useEffectAfterMount } from '@desktop-client/hooks/useEffectAfterMount'; +import { useEffectAfterMount } from '#hooks/useEffectAfterMount'; type BudgetAutomationProps = { categories: CategoryGroupEntity[]; diff --git a/packages/desktop-client/src/components/budget/goals/BudgetAutomationEditor.tsx b/packages/desktop-client/src/components/budget/goals/BudgetAutomationEditor.tsx index d54e774725..1040cb0c98 100644 --- a/packages/desktop-client/src/components/budget/goals/BudgetAutomationEditor.tsx +++ b/packages/desktop-client/src/components/budget/goals/BudgetAutomationEditor.tsx @@ -24,11 +24,7 @@ import { RefillAutomation } from './editor/RefillAutomation'; import { ScheduleAutomation } from './editor/ScheduleAutomation'; import { WeekAutomation } from './editor/WeekAutomation'; -import { - FormField, - FormLabel, - FormTextLabel, -} from '@desktop-client/components/forms'; +import { FormField, FormLabel, FormTextLabel } from '#components/forms'; type BudgetAutomationEditorProps = { inline: boolean; diff --git a/packages/desktop-client/src/components/budget/goals/CategoryAutomationButton.tsx b/packages/desktop-client/src/components/budget/goals/CategoryAutomationButton.tsx index f56e73e1cf..ae511c82ec 100644 --- a/packages/desktop-client/src/components/budget/goals/CategoryAutomationButton.tsx +++ b/packages/desktop-client/src/components/budget/goals/CategoryAutomationButton.tsx @@ -9,9 +9,9 @@ import { css, cx } from '@emotion/css'; import type { CategoryEntity } from 'loot-core/types/models'; -import { useFeatureFlag } from '@desktop-client/hooks/useFeatureFlag'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { useFeatureFlag } from '#hooks/useFeatureFlag'; +import { pushModal } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; type CategoryAutomationButtonProps = { category: CategoryEntity; diff --git a/packages/desktop-client/src/components/budget/goals/editor/HistoricalAutomation.tsx b/packages/desktop-client/src/components/budget/goals/editor/HistoricalAutomation.tsx index 44604d7311..cce5d61f4a 100644 --- a/packages/desktop-client/src/components/budget/goals/editor/HistoricalAutomation.tsx +++ b/packages/desktop-client/src/components/budget/goals/editor/HistoricalAutomation.tsx @@ -8,10 +8,10 @@ import type { CopyTemplate, } from 'loot-core/types/models/templates'; -import { updateTemplate } from '@desktop-client/components/budget/goals/actions'; -import type { Action } from '@desktop-client/components/budget/goals/actions'; -import { FormField, FormLabel } from '@desktop-client/components/forms'; -import { GenericInput } from '@desktop-client/components/util/GenericInput'; +import { updateTemplate } from '#components/budget/goals/actions'; +import type { Action } from '#components/budget/goals/actions'; +import { FormField, FormLabel } from '#components/forms'; +import { GenericInput } from '#components/util/GenericInput'; type HistoricalAutomationProps = { template: CopyTemplate | AverageTemplate; diff --git a/packages/desktop-client/src/components/budget/goals/editor/LimitAutomation.tsx b/packages/desktop-client/src/components/budget/goals/editor/LimitAutomation.tsx index 0155e23d53..bf3403df30 100644 --- a/packages/desktop-client/src/components/budget/goals/editor/LimitAutomation.tsx +++ b/packages/desktop-client/src/components/budget/goals/editor/LimitAutomation.tsx @@ -12,12 +12,12 @@ import { currentDate, dayFromDate, parseDate } from 'loot-core/shared/months'; import { amountToInteger, integerToAmount } from 'loot-core/shared/util'; import type { LimitTemplate } from 'loot-core/types/models/templates'; -import { updateTemplate } from '@desktop-client/components/budget/goals/actions'; -import type { Action } from '@desktop-client/components/budget/goals/actions'; -import { FormField, FormLabel } from '@desktop-client/components/forms'; -import { AmountInput } from '@desktop-client/components/util/AmountInput'; -import { useDaysOfWeek } from '@desktop-client/hooks/useDaysOfWeek'; -import { useFormat } from '@desktop-client/hooks/useFormat'; +import { updateTemplate } from '#components/budget/goals/actions'; +import type { Action } from '#components/budget/goals/actions'; +import { FormField, FormLabel } from '#components/forms'; +import { AmountInput } from '#components/util/AmountInput'; +import { useDaysOfWeek } from '#hooks/useDaysOfWeek'; +import { useFormat } from '#hooks/useFormat'; type LimitAutomationProps = { template: LimitTemplate; diff --git a/packages/desktop-client/src/components/budget/goals/editor/LimitAutomationReadOnly.tsx b/packages/desktop-client/src/components/budget/goals/editor/LimitAutomationReadOnly.tsx index 0db99fa656..e2dba78227 100644 --- a/packages/desktop-client/src/components/budget/goals/editor/LimitAutomationReadOnly.tsx +++ b/packages/desktop-client/src/components/budget/goals/editor/LimitAutomationReadOnly.tsx @@ -3,7 +3,7 @@ import { Trans } from 'react-i18next'; import { amountToInteger } from 'loot-core/shared/util'; import type { LimitTemplate } from 'loot-core/types/models/templates'; -import { useFormat } from '@desktop-client/hooks/useFormat'; +import { useFormat } from '#hooks/useFormat'; type LimitAutomationReadOnlyProps = { template: LimitTemplate; diff --git a/packages/desktop-client/src/components/budget/goals/editor/PercentageAutomation.tsx b/packages/desktop-client/src/components/budget/goals/editor/PercentageAutomation.tsx index 1180104264..db045f3424 100644 --- a/packages/desktop-client/src/components/budget/goals/editor/PercentageAutomation.tsx +++ b/packages/desktop-client/src/components/budget/goals/editor/PercentageAutomation.tsx @@ -10,11 +10,11 @@ import type { } from 'loot-core/types/models'; import type { PercentageTemplate } from 'loot-core/types/models/templates'; -import { CategoryAutocomplete } from '@desktop-client/components/autocomplete/CategoryAutocomplete'; -import { updateTemplate } from '@desktop-client/components/budget/goals/actions'; -import type { Action } from '@desktop-client/components/budget/goals/actions'; -import { FormField, FormLabel } from '@desktop-client/components/forms'; -import { PercentInput } from '@desktop-client/components/util/PercentInput'; +import { CategoryAutocomplete } from '#components/autocomplete/CategoryAutocomplete'; +import { updateTemplate } from '#components/budget/goals/actions'; +import type { Action } from '#components/budget/goals/actions'; +import { FormField, FormLabel } from '#components/forms'; +import { PercentInput } from '#components/util/PercentInput'; type PercentageAutomationProps = { dispatch: (action: Action) => void; diff --git a/packages/desktop-client/src/components/budget/goals/editor/RefillAutomation.tsx b/packages/desktop-client/src/components/budget/goals/editor/RefillAutomation.tsx index 483493efd8..80e5d94345 100644 --- a/packages/desktop-client/src/components/budget/goals/editor/RefillAutomation.tsx +++ b/packages/desktop-client/src/components/budget/goals/editor/RefillAutomation.tsx @@ -4,7 +4,7 @@ import { Button } from '@actual-app/components/button'; import { SpaceBetween } from '@actual-app/components/space-between'; import { View } from '@actual-app/components/view'; -import { Warning } from '@desktop-client/components/alerts'; +import { Warning } from '#components/alerts'; type RefillAutomationProps = { hasLimitAutomation: boolean; diff --git a/packages/desktop-client/src/components/budget/goals/editor/ScheduleAutomation.tsx b/packages/desktop-client/src/components/budget/goals/editor/ScheduleAutomation.tsx index 56f8830b3d..2efdf02563 100644 --- a/packages/desktop-client/src/components/budget/goals/editor/ScheduleAutomation.tsx +++ b/packages/desktop-client/src/components/budget/goals/editor/ScheduleAutomation.tsx @@ -7,10 +7,10 @@ import { Text } from '@actual-app/components/text'; import type { ScheduleEntity } from 'loot-core/types/models'; import type { ScheduleTemplate } from 'loot-core/types/models/templates'; -import { updateTemplate } from '@desktop-client/components/budget/goals/actions'; -import type { Action } from '@desktop-client/components/budget/goals/actions'; -import { Link } from '@desktop-client/components/common/Link'; -import { FormField, FormLabel } from '@desktop-client/components/forms'; +import { updateTemplate } from '#components/budget/goals/actions'; +import type { Action } from '#components/budget/goals/actions'; +import { Link } from '#components/common/Link'; +import { FormField, FormLabel } from '#components/forms'; type ScheduleAutomationProps = { schedules: readonly ScheduleEntity[]; diff --git a/packages/desktop-client/src/components/budget/goals/editor/WeekAutomation.tsx b/packages/desktop-client/src/components/budget/goals/editor/WeekAutomation.tsx index 704bf8d7bc..92b34ca834 100644 --- a/packages/desktop-client/src/components/budget/goals/editor/WeekAutomation.tsx +++ b/packages/desktop-client/src/components/budget/goals/editor/WeekAutomation.tsx @@ -2,10 +2,10 @@ import { useTranslation } from 'react-i18next'; import type { PeriodicTemplate } from 'loot-core/types/models/templates'; -import { updateTemplate } from '@desktop-client/components/budget/goals/actions'; -import type { Action } from '@desktop-client/components/budget/goals/actions'; -import { FormField, FormLabel } from '@desktop-client/components/forms'; -import { AmountInput } from '@desktop-client/components/util/AmountInput'; +import { updateTemplate } from '#components/budget/goals/actions'; +import type { Action } from '#components/budget/goals/actions'; +import { FormField, FormLabel } from '#components/forms'; +import { AmountInput } from '#components/util/AmountInput'; type WeekAutomationProps = { template: PeriodicTemplate; diff --git a/packages/desktop-client/src/components/budget/goals/editor/WeekAutomationReadOnly.tsx b/packages/desktop-client/src/components/budget/goals/editor/WeekAutomationReadOnly.tsx index 5285930fbf..411df9b22b 100644 --- a/packages/desktop-client/src/components/budget/goals/editor/WeekAutomationReadOnly.tsx +++ b/packages/desktop-client/src/components/budget/goals/editor/WeekAutomationReadOnly.tsx @@ -3,8 +3,8 @@ import { Trans } from 'react-i18next'; import type { PeriodicTemplate } from 'loot-core/types/models/templates'; import type { TransObjectLiteral } from 'loot-core/types/util'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { useFormat } from '@desktop-client/hooks/useFormat'; +import { FinancialText } from '#components/FinancialText'; +import { useFormat } from '#hooks/useFormat'; type WeekAutomationReadOnlyProps = { template: PeriodicTemplate; diff --git a/packages/desktop-client/src/components/budget/goals/useBudgetAutomationCategories.ts b/packages/desktop-client/src/components/budget/goals/useBudgetAutomationCategories.ts index 1b59513974..f72e6cde26 100644 --- a/packages/desktop-client/src/components/budget/goals/useBudgetAutomationCategories.ts +++ b/packages/desktop-client/src/components/budget/goals/useBudgetAutomationCategories.ts @@ -1,7 +1,7 @@ import { useMemo } from 'react'; import { useTranslation } from 'react-i18next'; -import { useCategories } from '@desktop-client/hooks/useCategories'; +import { useCategories } from '#hooks/useCategories'; export function useBudgetAutomationCategories() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/budget/index.tsx b/packages/desktop-client/src/components/budget/index.tsx index 7fc984a0c0..381d081dbe 100644 --- a/packages/desktop-client/src/components/budget/index.tsx +++ b/packages/desktop-client/src/components/budget/index.tsx @@ -27,14 +27,14 @@ import { useReorderCategoryMutation, useSaveCategoryGroupMutation, useSaveCategoryMutation, -} from '@desktop-client/budget'; -import { useCategories } from '@desktop-client/hooks/useCategories'; -import { useGlobalPref } from '@desktop-client/hooks/useGlobalPref'; -import { useLocalPref } from '@desktop-client/hooks/useLocalPref'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { SheetNameProvider } from '@desktop-client/hooks/useSheetName'; -import { useSpreadsheet } from '@desktop-client/hooks/useSpreadsheet'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; +} from '#budget'; +import { useCategories } from '#hooks/useCategories'; +import { useGlobalPref } from '#hooks/useGlobalPref'; +import { useLocalPref } from '#hooks/useLocalPref'; +import { useNavigate } from '#hooks/useNavigate'; +import { SheetNameProvider } from '#hooks/useSheetName'; +import { useSpreadsheet } from '#hooks/useSpreadsheet'; +import { useSyncedPref } from '#hooks/useSyncedPref'; export function Budget() { const currentMonth = monthUtils.currentMonth(); diff --git a/packages/desktop-client/src/components/budget/tracking/BalanceMenu.tsx b/packages/desktop-client/src/components/budget/tracking/BalanceMenu.tsx index 9903296ef7..99a23855ca 100644 --- a/packages/desktop-client/src/components/budget/tracking/BalanceMenu.tsx +++ b/packages/desktop-client/src/components/budget/tracking/BalanceMenu.tsx @@ -6,7 +6,7 @@ import { Menu } from '@actual-app/components/menu'; import { useTrackingSheetValue } from './TrackingBudgetComponents'; -import { trackingBudget } from '@desktop-client/spreadsheet/bindings'; +import { trackingBudget } from '#spreadsheet/bindings'; type BalanceMenuProps = Omit< ComponentPropsWithoutRef, diff --git a/packages/desktop-client/src/components/budget/tracking/BudgetMenu.tsx b/packages/desktop-client/src/components/budget/tracking/BudgetMenu.tsx index 88ed173025..68e6ba87f8 100644 --- a/packages/desktop-client/src/components/budget/tracking/BudgetMenu.tsx +++ b/packages/desktop-client/src/components/budget/tracking/BudgetMenu.tsx @@ -4,7 +4,7 @@ import { useTranslation } from 'react-i18next'; import { Menu } from '@actual-app/components/menu'; -import { useFeatureFlag } from '@desktop-client/hooks/useFeatureFlag'; +import { useFeatureFlag } from '#hooks/useFeatureFlag'; type BudgetMenuProps = Omit< ComponentPropsWithoutRef, diff --git a/packages/desktop-client/src/components/budget/tracking/TrackingBudgetComponents.tsx b/packages/desktop-client/src/components/budget/tracking/TrackingBudgetComponents.tsx index 916be13810..b050219630 100644 --- a/packages/desktop-client/src/components/budget/tracking/TrackingBudgetComponents.tsx +++ b/packages/desktop-client/src/components/budget/tracking/TrackingBudgetComponents.tsx @@ -23,21 +23,18 @@ import type { CategoryGroupMonthProps, CategoryMonthProps } from '..'; import { BalanceMenu } from './BalanceMenu'; import { BudgetMenu } from './BudgetMenu'; -import { BalanceWithCarryover } from '@desktop-client/components/budget/BalanceWithCarryover'; -import { makeAmountGrey } from '@desktop-client/components/budget/util'; -import { - CellValue, - CellValueText, -} from '@desktop-client/components/spreadsheet/CellValue'; -import { Field, SheetCell } from '@desktop-client/components/table'; -import type { SheetCellProps } from '@desktop-client/components/table'; -import { useCategoryScheduleGoalTemplateIndicator } from '@desktop-client/hooks/useCategoryScheduleGoalTemplateIndicator'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { useSheetValue } from '@desktop-client/hooks/useSheetValue'; -import { useUndo } from '@desktop-client/hooks/useUndo'; -import type { Binding, SheetFields } from '@desktop-client/spreadsheet'; -import { trackingBudget } from '@desktop-client/spreadsheet/bindings'; +import { BalanceWithCarryover } from '#components/budget/BalanceWithCarryover'; +import { makeAmountGrey } from '#components/budget/util'; +import { CellValue, CellValueText } from '#components/spreadsheet/CellValue'; +import { Field, SheetCell } from '#components/table'; +import type { SheetCellProps } from '#components/table'; +import { useCategoryScheduleGoalTemplateIndicator } from '#hooks/useCategoryScheduleGoalTemplateIndicator'; +import { useFormat } from '#hooks/useFormat'; +import { useNavigate } from '#hooks/useNavigate'; +import { useSheetValue } from '#hooks/useSheetValue'; +import { useUndo } from '#hooks/useUndo'; +import type { Binding, SheetFields } from '#spreadsheet'; +import { trackingBudget } from '#spreadsheet/bindings'; export const useTrackingSheetValue = < FieldName extends SheetFields<'tracking-budget'>, diff --git a/packages/desktop-client/src/components/budget/tracking/budgetsummary/BudgetMonthMenu.tsx b/packages/desktop-client/src/components/budget/tracking/budgetsummary/BudgetMonthMenu.tsx index cc9386fbd6..2cfa8d0af9 100644 --- a/packages/desktop-client/src/components/budget/tracking/budgetsummary/BudgetMonthMenu.tsx +++ b/packages/desktop-client/src/components/budget/tracking/budgetsummary/BudgetMonthMenu.tsx @@ -4,7 +4,7 @@ import { useTranslation } from 'react-i18next'; import { Menu } from '@actual-app/components/menu'; -import { useFeatureFlag } from '@desktop-client/hooks/useFeatureFlag'; +import { useFeatureFlag } from '#hooks/useFeatureFlag'; type BudgetMonthMenuProps = Omit< ComponentPropsWithoutRef, diff --git a/packages/desktop-client/src/components/budget/tracking/budgetsummary/BudgetSummary.tsx b/packages/desktop-client/src/components/budget/tracking/budgetsummary/BudgetSummary.tsx index 84ff6ae31d..92307130ad 100644 --- a/packages/desktop-client/src/components/budget/tracking/budgetsummary/BudgetSummary.tsx +++ b/packages/desktop-client/src/components/budget/tracking/budgetsummary/BudgetSummary.tsx @@ -22,11 +22,11 @@ import { ExpenseTotal } from './ExpenseTotal'; import { IncomeTotal } from './IncomeTotal'; import { Saved } from './Saved'; -import { useTrackingBudget } from '@desktop-client/components/budget/tracking/TrackingBudgetContext'; -import { NotesButton } from '@desktop-client/components/NotesButton'; -import { useLocale } from '@desktop-client/hooks/useLocale'; -import { SheetNameProvider } from '@desktop-client/hooks/useSheetName'; -import { useUndo } from '@desktop-client/hooks/useUndo'; +import { useTrackingBudget } from '#components/budget/tracking/TrackingBudgetContext'; +import { NotesButton } from '#components/NotesButton'; +import { useLocale } from '#hooks/useLocale'; +import { SheetNameProvider } from '#hooks/useSheetName'; +import { useUndo } from '#hooks/useUndo'; type BudgetSummaryProps = { month: string; diff --git a/packages/desktop-client/src/components/budget/tracking/budgetsummary/BudgetTotal.tsx b/packages/desktop-client/src/components/budget/tracking/budgetsummary/BudgetTotal.tsx index 0d69d281b7..2b9c6f0028 100644 --- a/packages/desktop-client/src/components/budget/tracking/budgetsummary/BudgetTotal.tsx +++ b/packages/desktop-client/src/components/budget/tracking/budgetsummary/BudgetTotal.tsx @@ -8,8 +8,8 @@ import { Text } from '@actual-app/components/text'; import { theme } from '@actual-app/components/theme'; import { View } from '@actual-app/components/view'; -import { CellValue } from '@desktop-client/components/spreadsheet/CellValue'; -import type { Binding, SheetFields } from '@desktop-client/spreadsheet'; +import { CellValue } from '#components/spreadsheet/CellValue'; +import type { Binding, SheetFields } from '#spreadsheet'; type BudgetTotalProps< CurrentField extends SheetFields<'tracking-budget'>, diff --git a/packages/desktop-client/src/components/budget/tracking/budgetsummary/ExpenseProgress.tsx b/packages/desktop-client/src/components/budget/tracking/budgetsummary/ExpenseProgress.tsx index a668e6deae..4a30021a77 100644 --- a/packages/desktop-client/src/components/budget/tracking/budgetsummary/ExpenseProgress.tsx +++ b/packages/desktop-client/src/components/budget/tracking/budgetsummary/ExpenseProgress.tsx @@ -5,8 +5,8 @@ import { theme } from '@actual-app/components/theme'; import { fraction } from './fraction'; import { PieProgress } from './PieProgress'; -import { useTrackingSheetValue } from '@desktop-client/components/budget/tracking/TrackingBudgetComponents'; -import type { Binding } from '@desktop-client/spreadsheet'; +import { useTrackingSheetValue } from '#components/budget/tracking/TrackingBudgetComponents'; +import type { Binding } from '#spreadsheet'; type ExpenseProgressProps = { current: Binding<'tracking-budget', 'total-spent'>; diff --git a/packages/desktop-client/src/components/budget/tracking/budgetsummary/ExpenseTotal.tsx b/packages/desktop-client/src/components/budget/tracking/budgetsummary/ExpenseTotal.tsx index e4338866e4..ccc77329d5 100644 --- a/packages/desktop-client/src/components/budget/tracking/budgetsummary/ExpenseTotal.tsx +++ b/packages/desktop-client/src/components/budget/tracking/budgetsummary/ExpenseTotal.tsx @@ -5,7 +5,7 @@ import { useTranslation } from 'react-i18next'; import { BudgetTotal } from './BudgetTotal'; import { ExpenseProgress } from './ExpenseProgress'; -import { trackingBudget } from '@desktop-client/spreadsheet/bindings'; +import { trackingBudget } from '#spreadsheet/bindings'; type ExpenseTotalProps = { style?: CSSProperties; diff --git a/packages/desktop-client/src/components/budget/tracking/budgetsummary/IncomeProgress.tsx b/packages/desktop-client/src/components/budget/tracking/budgetsummary/IncomeProgress.tsx index dd8a7e6e64..4fb73969b7 100644 --- a/packages/desktop-client/src/components/budget/tracking/budgetsummary/IncomeProgress.tsx +++ b/packages/desktop-client/src/components/budget/tracking/budgetsummary/IncomeProgress.tsx @@ -6,8 +6,8 @@ import { theme } from '@actual-app/components/theme'; import { fraction } from './fraction'; import { PieProgress } from './PieProgress'; -import type { CellValue } from '@desktop-client/components/spreadsheet/CellValue'; -import { useSheetValue } from '@desktop-client/hooks/useSheetValue'; +import type { CellValue } from '#components/spreadsheet/CellValue'; +import { useSheetValue } from '#hooks/useSheetValue'; type IncomeProgressProps = { current: ComponentProps['binding']; diff --git a/packages/desktop-client/src/components/budget/tracking/budgetsummary/IncomeTotal.tsx b/packages/desktop-client/src/components/budget/tracking/budgetsummary/IncomeTotal.tsx index d21282a4b2..9380f300ff 100644 --- a/packages/desktop-client/src/components/budget/tracking/budgetsummary/IncomeTotal.tsx +++ b/packages/desktop-client/src/components/budget/tracking/budgetsummary/IncomeTotal.tsx @@ -5,7 +5,7 @@ import { useTranslation } from 'react-i18next'; import { BudgetTotal } from './BudgetTotal'; import { IncomeProgress } from './IncomeProgress'; -import { trackingBudget } from '@desktop-client/spreadsheet/bindings'; +import { trackingBudget } from '#spreadsheet/bindings'; type IncomeTotalProps = { style?: CSSProperties; diff --git a/packages/desktop-client/src/components/budget/tracking/budgetsummary/Saved.tsx b/packages/desktop-client/src/components/budget/tracking/budgetsummary/Saved.tsx index 53bb8006b9..0b82a46b8a 100644 --- a/packages/desktop-client/src/components/budget/tracking/budgetsummary/Saved.tsx +++ b/packages/desktop-client/src/components/budget/tracking/budgetsummary/Saved.tsx @@ -10,12 +10,12 @@ import { Tooltip } from '@actual-app/components/tooltip'; import { View } from '@actual-app/components/view'; import { css } from '@emotion/css'; -import { useTrackingSheetValue } from '@desktop-client/components/budget/tracking/TrackingBudgetComponents'; -import { makeAmountFullStyle } from '@desktop-client/components/budget/util'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { trackingBudget } from '@desktop-client/spreadsheet/bindings'; +import { useTrackingSheetValue } from '#components/budget/tracking/TrackingBudgetComponents'; +import { makeAmountFullStyle } from '#components/budget/util'; +import { FinancialText } from '#components/FinancialText'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { useFormat } from '#hooks/useFormat'; +import { trackingBudget } from '#spreadsheet/bindings'; type SavedProps = { projected: boolean; diff --git a/packages/desktop-client/src/components/budget/util.ts b/packages/desktop-client/src/components/budget/util.ts index d4a16b940e..34ef2b52b7 100644 --- a/packages/desktop-client/src/components/budget/util.ts +++ b/packages/desktop-client/src/components/budget/util.ts @@ -17,8 +17,8 @@ import type { SyncedPrefs } from 'loot-core/types/prefs'; import { getValidMonthBounds } from './MonthsContext'; -import type { DropPosition } from '@desktop-client/components/sort'; -import type { useSpreadsheet } from '@desktop-client/hooks/useSpreadsheet'; +import type { DropPosition } from '#components/sort'; +import type { useSpreadsheet } from '#hooks/useSpreadsheet'; export function addToBeBudgetedGroup(groups: CategoryGroupEntity[]) { return [ diff --git a/packages/desktop-client/src/components/common/Link.tsx b/packages/desktop-client/src/components/common/Link.tsx index 6844aef780..535513389b 100644 --- a/packages/desktop-client/src/components/common/Link.tsx +++ b/packages/desktop-client/src/components/common/Link.tsx @@ -9,7 +9,7 @@ import { Text } from '@actual-app/components/text'; import { theme } from '@actual-app/components/theme'; import { css } from '@emotion/css'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; +import { useNavigate } from '#hooks/useNavigate'; type TextLinkProps = { style?: CSSProperties; diff --git a/packages/desktop-client/src/components/common/Modal.tsx b/packages/desktop-client/src/components/common/Modal.tsx index 2b8922cdb4..9491abda14 100644 --- a/packages/desktop-client/src/components/common/Modal.tsx +++ b/packages/desktop-client/src/components/common/Modal.tsx @@ -28,7 +28,7 @@ import { View } from '@actual-app/components/view'; import { css } from '@emotion/css'; import { AutoTextSize } from 'auto-text-size'; -import { useModalState } from '@desktop-client/hooks/useModalState'; +import { useModalState } from '#hooks/useModalState'; export const MODAL_Z_INDEX = 3000; diff --git a/packages/desktop-client/src/components/filters/ConditionsOpMenu.tsx b/packages/desktop-client/src/components/filters/ConditionsOpMenu.tsx index 19a60beff9..45faddd84f 100644 --- a/packages/desktop-client/src/components/filters/ConditionsOpMenu.tsx +++ b/packages/desktop-client/src/components/filters/ConditionsOpMenu.tsx @@ -6,7 +6,7 @@ import { View } from '@actual-app/components/view'; import type { RuleConditionEntity } from 'loot-core/types/models'; -import { FieldSelect } from '@desktop-client/components/rules/RuleEditor'; +import { FieldSelect } from '#components/rules/RuleEditor'; export function ConditionsOpMenu({ conditionsOp, diff --git a/packages/desktop-client/src/components/filters/FilterExpression.tsx b/packages/desktop-client/src/components/filters/FilterExpression.tsx index f791020ae9..0909ed68dd 100644 --- a/packages/desktop-client/src/components/filters/FilterExpression.tsx +++ b/packages/desktop-client/src/components/filters/FilterExpression.tsx @@ -15,7 +15,7 @@ import type { RuleConditionEntity } from 'loot-core/types/models'; import { FilterEditor } from './FiltersMenu'; import { subfieldFromFilter } from './subfieldFromFilter'; -import { Value } from '@desktop-client/components/rules/Value'; +import { Value } from '#components/rules/Value'; let isDatepickerClick = false; diff --git a/packages/desktop-client/src/components/filters/FiltersMenu.tsx b/packages/desktop-client/src/components/filters/FiltersMenu.tsx index d3afeec7ce..0a0bdad2e7 100644 --- a/packages/desktop-client/src/components/filters/FiltersMenu.tsx +++ b/packages/desktop-client/src/components/filters/FiltersMenu.tsx @@ -42,10 +42,10 @@ import { subfieldFromFilter } from './subfieldFromFilter'; import { subfieldToOptions } from './subfieldToOptions'; import { updateFilterReducer } from './updateFilterReducer'; -import { GenericInput } from '@desktop-client/components/util/GenericInput'; -import { useDateFormat } from '@desktop-client/hooks/useDateFormat'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useTransactionFilters } from '@desktop-client/hooks/useTransactionFilters'; +import { GenericInput } from '#components/util/GenericInput'; +import { useDateFormat } from '#hooks/useDateFormat'; +import { useFormat } from '#hooks/useFormat'; +import { useTransactionFilters } from '#hooks/useTransactionFilters'; type FilterReducerState = Pick< T, diff --git a/packages/desktop-client/src/components/filters/NameFilter.tsx b/packages/desktop-client/src/components/filters/NameFilter.tsx index c09f440a37..a810d1a4c4 100644 --- a/packages/desktop-client/src/components/filters/NameFilter.tsx +++ b/packages/desktop-client/src/components/filters/NameFilter.tsx @@ -8,7 +8,7 @@ import { SpaceBetween } from '@actual-app/components/space-between'; import { Text } from '@actual-app/components/text'; import { theme } from '@actual-app/components/theme'; -import { FormField, FormLabel } from '@desktop-client/components/forms'; +import { FormField, FormLabel } from '#components/forms'; export function NameFilter({ menuItem, diff --git a/packages/desktop-client/src/components/filters/PayeeFilter.tsx b/packages/desktop-client/src/components/filters/PayeeFilter.tsx index 4dff583cbc..01330c6c71 100644 --- a/packages/desktop-client/src/components/filters/PayeeFilter.tsx +++ b/packages/desktop-client/src/components/filters/PayeeFilter.tsx @@ -3,7 +3,7 @@ import { useTranslation } from 'react-i18next'; import type { PayeeEntity } from 'loot-core/types/models'; -import { PayeeAutocomplete } from '@desktop-client/components/autocomplete/PayeeAutocomplete'; +import { PayeeAutocomplete } from '#components/autocomplete/PayeeAutocomplete'; type PayeeFilterValue = PayeeEntity['id'] | PayeeEntity['id'][]; diff --git a/packages/desktop-client/src/components/formula/FormulaEditor.tsx b/packages/desktop-client/src/components/formula/FormulaEditor.tsx index c421a0c79f..e0f5defe1d 100644 --- a/packages/desktop-client/src/components/formula/FormulaEditor.tsx +++ b/packages/desktop-client/src/components/formula/FormulaEditor.tsx @@ -6,8 +6,8 @@ import type { ReactCodeMirrorProps } from '@uiw/react-codemirror'; import { excelFormulaExtension } from './codeMirror-excelLanguage'; -import { autocompleteTabAcceptHighest } from '@desktop-client/components/codemirror/autocompleteTabAccept'; -import { useTheme } from '@desktop-client/style/theme'; +import { autocompleteTabAcceptHighest } from '#components/codemirror/autocompleteTabAccept'; +import { useTheme } from '#style/theme'; type FormulaMode = 'transaction' | 'query'; diff --git a/packages/desktop-client/src/components/formula/QueryManager.tsx b/packages/desktop-client/src/components/formula/QueryManager.tsx index 47748277a8..7e64f92185 100644 --- a/packages/desktop-client/src/components/formula/QueryManager.tsx +++ b/packages/desktop-client/src/components/formula/QueryManager.tsx @@ -23,21 +23,21 @@ import { normalizeQueryTimeFrameStart, } from './queryTimeFrame'; -import { AppliedFilters } from '@desktop-client/components/filters/AppliedFilters'; -import { FilterButton } from '@desktop-client/components/filters/FiltersMenu'; -import { getLiveRange } from '@desktop-client/components/reports/getLiveRange'; +import { AppliedFilters } from '#components/filters/AppliedFilters'; +import { FilterButton } from '#components/filters/FiltersMenu'; +import { getLiveRange } from '#components/reports/getLiveRange'; import { calculateTimeRange, getLatestRange, validateEnd, validateStart, -} from '@desktop-client/components/reports/reportRanges'; -import { fromDateRepr } from '@desktop-client/components/reports/util'; -import { useLocale } from '@desktop-client/hooks/useLocale'; -import { useRuleConditionFilters } from '@desktop-client/hooks/useRuleConditionFilters'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; -import type { AppDispatch } from '@desktop-client/redux/store'; +} from '#components/reports/reportRanges'; +import { fromDateRepr } from '#components/reports/util'; +import { useLocale } from '#hooks/useLocale'; +import { useRuleConditionFilters } from '#hooks/useRuleConditionFilters'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; +import type { AppDispatch } from '#redux/store'; type QueryConfig = { conditions?: RuleConditionEntity[]; diff --git a/packages/desktop-client/src/components/gocardless/GoCardlessLink.tsx b/packages/desktop-client/src/components/gocardless/GoCardlessLink.tsx index 6395a5ab98..6aca7ddddf 100644 --- a/packages/desktop-client/src/components/gocardless/GoCardlessLink.tsx +++ b/packages/desktop-client/src/components/gocardless/GoCardlessLink.tsx @@ -4,7 +4,7 @@ import { Trans, useTranslation } from 'react-i18next'; import { Paragraph } from '@actual-app/components/paragraph'; import { View } from '@actual-app/components/view'; -import { Modal, ModalHeader } from '@desktop-client/components/common/Modal'; +import { Modal, ModalHeader } from '#components/common/Modal'; export function GoCardlessLink() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/manager/BudgetFileSelection.tsx b/packages/desktop-client/src/components/manager/BudgetFileSelection.tsx index f886790e35..b0150baa62 100644 --- a/packages/desktop-client/src/components/manager/BudgetFileSelection.tsx +++ b/packages/desktop-client/src/components/manager/BudgetFileSelection.tsx @@ -49,14 +49,14 @@ import { downloadBudget, loadAllFiles, loadBudget, -} from '@desktop-client/budgetfiles/budgetfilesSlice'; -import { useMultiuserEnabled } from '@desktop-client/components/ServerContext'; -import { useInitialMount } from '@desktop-client/hooks/useInitialMount'; -import { useMetadataPref } from '@desktop-client/hooks/useMetadataPref'; -import { useSyncServerStatus } from '@desktop-client/hooks/useSyncServerStatus'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import { useDispatch, useSelector } from '@desktop-client/redux'; -import { getUserData } from '@desktop-client/users/usersSlice'; +} from '#budgetfiles/budgetfilesSlice'; +import { useMultiuserEnabled } from '#components/ServerContext'; +import { useInitialMount } from '#hooks/useInitialMount'; +import { useMetadataPref } from '#hooks/useMetadataPref'; +import { useSyncServerStatus } from '#hooks/useSyncServerStatus'; +import { pushModal } from '#modals/modalsSlice'; +import { useDispatch, useSelector } from '#redux'; +import { getUserData } from '#users/usersSlice'; function getFileDescription(file: File, t: (key: string) => string) { if (file.state === 'unknown') { diff --git a/packages/desktop-client/src/components/manager/ConfigServer.tsx b/packages/desktop-client/src/components/manager/ConfigServer.tsx index f4cc0cf675..c8299d4686 100644 --- a/packages/desktop-client/src/components/manager/ConfigServer.tsx +++ b/packages/desktop-client/src/components/manager/ConfigServer.tsx @@ -17,17 +17,14 @@ import { import { Title } from './subscribe/common'; -import { createBudget } from '@desktop-client/budgetfiles/budgetfilesSlice'; -import { Link } from '@desktop-client/components/common/Link'; -import { - useServerURL, - useSetServerURL, -} from '@desktop-client/components/ServerContext'; -import { useGlobalPref } from '@desktop-client/hooks/useGlobalPref'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { saveGlobalPrefs } from '@desktop-client/prefs/prefsSlice'; -import { useDispatch } from '@desktop-client/redux'; -import { loggedIn, signOut } from '@desktop-client/users/usersSlice'; +import { createBudget } from '#budgetfiles/budgetfilesSlice'; +import { Link } from '#components/common/Link'; +import { useServerURL, useSetServerURL } from '#components/ServerContext'; +import { useGlobalPref } from '#hooks/useGlobalPref'; +import { useNavigate } from '#hooks/useNavigate'; +import { saveGlobalPrefs } from '#prefs/prefsSlice'; +import { useDispatch } from '#redux'; +import { loggedIn, signOut } from '#users/usersSlice'; export function ElectronServerConfig({ onDoNotUseServer, diff --git a/packages/desktop-client/src/components/manager/ManagementApp.tsx b/packages/desktop-client/src/components/manager/ManagementApp.tsx index 3480830251..06274aecd9 100644 --- a/packages/desktop-client/src/components/manager/ManagementApp.tsx +++ b/packages/desktop-client/src/components/manager/ManagementApp.tsx @@ -18,23 +18,23 @@ import { Login } from './subscribe/Login'; import { OpenIdCallback } from './subscribe/OpenIdCallback'; import { WelcomeScreen } from './WelcomeScreen'; -import { setAppState } from '@desktop-client/app/appSlice'; -import { ProtectedRoute } from '@desktop-client/auth/ProtectedRoute'; -import { Permissions } from '@desktop-client/auth/types'; +import { setAppState } from '#app/appSlice'; +import { ProtectedRoute } from '#auth/ProtectedRoute'; +import { Permissions } from '#auth/types'; import { BackToFileListButton, UserDirectoryPage, -} from '@desktop-client/components/admin/UserDirectory/UserDirectoryPage'; -import { AppBackground } from '@desktop-client/components/AppBackground'; -import { LoggedInUser } from '@desktop-client/components/LoggedInUser'; -import { Notifications } from '@desktop-client/components/Notifications'; +} from '#components/admin/UserDirectory/UserDirectoryPage'; +import { AppBackground } from '#components/AppBackground'; +import { LoggedInUser } from '#components/LoggedInUser'; +import { Notifications } from '#components/Notifications'; import { useMultiuserEnabled, useServerVersion, -} from '@desktop-client/components/ServerContext'; -import { useMetaThemeColor } from '@desktop-client/hooks/useMetaThemeColor'; -import { useDispatch, useSelector } from '@desktop-client/redux'; -import { loggedIn } from '@desktop-client/users/usersSlice'; +} from '#components/ServerContext'; +import { useMetaThemeColor } from '#hooks/useMetaThemeColor'; +import { useDispatch, useSelector } from '#redux'; +import { loggedIn } from '#users/usersSlice'; function Version() { const version = useServerVersion(); diff --git a/packages/desktop-client/src/components/manager/ServerURL.tsx b/packages/desktop-client/src/components/manager/ServerURL.tsx index e25ac69a47..acfe38ed9d 100644 --- a/packages/desktop-client/src/components/manager/ServerURL.tsx +++ b/packages/desktop-client/src/components/manager/ServerURL.tsx @@ -4,8 +4,8 @@ import { Trans } from 'react-i18next'; import { Text } from '@actual-app/components/text'; import { View } from '@actual-app/components/view'; -import { Link } from '@desktop-client/components/common/Link'; -import { useServerURL } from '@desktop-client/components/ServerContext'; +import { Link } from '#components/common/Link'; +import { useServerURL } from '#components/ServerContext'; export function ServerURL() { const url = useServerURL(); diff --git a/packages/desktop-client/src/components/manager/WelcomeScreen.tsx b/packages/desktop-client/src/components/manager/WelcomeScreen.tsx index 859dca6e67..91797c7394 100644 --- a/packages/desktop-client/src/components/manager/WelcomeScreen.tsx +++ b/packages/desktop-client/src/components/manager/WelcomeScreen.tsx @@ -8,10 +8,10 @@ import { Text } from '@actual-app/components/text'; import { theme } from '@actual-app/components/theme'; import { View } from '@actual-app/components/view'; -import { createBudget } from '@desktop-client/budgetfiles/budgetfilesSlice'; -import { Link } from '@desktop-client/components/common/Link'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { createBudget } from '#budgetfiles/budgetfilesSlice'; +import { Link } from '#components/common/Link'; +import { pushModal } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; export function WelcomeScreen() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/manager/subscribe/Bootstrap.tsx b/packages/desktop-client/src/components/manager/subscribe/Bootstrap.tsx index cdf875120b..4b3391776e 100644 --- a/packages/desktop-client/src/components/manager/subscribe/Bootstrap.tsx +++ b/packages/desktop-client/src/components/manager/subscribe/Bootstrap.tsx @@ -13,11 +13,11 @@ import { send } from 'loot-core/platform/client/connection'; import { Title, useBootstrapped } from './common'; import { ConfirmPasswordForm } from './ConfirmPasswordForm'; -import { createBudget } from '@desktop-client/budgetfiles/budgetfilesSlice'; -import { Link } from '@desktop-client/components/common/Link'; -import { useRefreshLoginMethods } from '@desktop-client/components/ServerContext'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { useDispatch } from '@desktop-client/redux'; +import { createBudget } from '#budgetfiles/budgetfilesSlice'; +import { Link } from '#components/common/Link'; +import { useRefreshLoginMethods } from '#components/ServerContext'; +import { useNavigate } from '#hooks/useNavigate'; +import { useDispatch } from '#redux'; export function Bootstrap() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/manager/subscribe/ChangePassword.tsx b/packages/desktop-client/src/components/manager/subscribe/ChangePassword.tsx index fd5c674088..2f2994c2f7 100644 --- a/packages/desktop-client/src/components/manager/subscribe/ChangePassword.tsx +++ b/packages/desktop-client/src/components/manager/subscribe/ChangePassword.tsx @@ -12,7 +12,7 @@ import { send } from 'loot-core/platform/client/connection'; import { Title } from './common'; import { ConfirmPasswordForm } from './ConfirmPasswordForm'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; +import { useNavigate } from '#hooks/useNavigate'; export function ChangePassword() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/manager/subscribe/Error.tsx b/packages/desktop-client/src/components/manager/subscribe/Error.tsx index 4b2541524c..407c2f0310 100644 --- a/packages/desktop-client/src/components/manager/subscribe/Error.tsx +++ b/packages/desktop-client/src/components/manager/subscribe/Error.tsx @@ -8,7 +8,7 @@ import { Text } from '@actual-app/components/text'; import { theme } from '@actual-app/components/theme'; import { View } from '@actual-app/components/view'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; +import { useNavigate } from '#hooks/useNavigate'; function getErrorMessage(reason) { switch (reason) { diff --git a/packages/desktop-client/src/components/manager/subscribe/Login.tsx b/packages/desktop-client/src/components/manager/subscribe/Login.tsx index bd63070c53..36f8802759 100644 --- a/packages/desktop-client/src/components/manager/subscribe/Login.tsx +++ b/packages/desktop-client/src/components/manager/subscribe/Login.tsx @@ -22,14 +22,14 @@ import type { OpenIdConfig } from 'loot-core/types/models'; import { Title, useBootstrapped } from './common'; import { OpenIdForm } from './OpenIdForm'; -import { Link } from '@desktop-client/components/common/Link'; +import { Link } from '#components/common/Link'; import { useAvailableLoginMethods, useLoginMethod, -} from '@desktop-client/components/ServerContext'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { useDispatch } from '@desktop-client/redux'; -import { loggedIn } from '@desktop-client/users/usersSlice'; +} from '#components/ServerContext'; +import { useNavigate } from '#hooks/useNavigate'; +import { useDispatch } from '#redux'; +import { loggedIn } from '#users/usersSlice'; function PasswordLogin({ setError, dispatch }) { const [password, setPassword] = useState(''); diff --git a/packages/desktop-client/src/components/manager/subscribe/OpenIdCallback.ts b/packages/desktop-client/src/components/manager/subscribe/OpenIdCallback.ts index d5059955a0..a2770db8b4 100644 --- a/packages/desktop-client/src/components/manager/subscribe/OpenIdCallback.ts +++ b/packages/desktop-client/src/components/manager/subscribe/OpenIdCallback.ts @@ -2,8 +2,8 @@ import { useEffect } from 'react'; import { send } from 'loot-core/platform/client/connection'; -import { useDispatch } from '@desktop-client/redux'; -import { loggedIn } from '@desktop-client/users/usersSlice'; +import { useDispatch } from '#redux'; +import { loggedIn } from '#users/usersSlice'; export function OpenIdCallback() { const dispatch = useDispatch(); diff --git a/packages/desktop-client/src/components/manager/subscribe/OpenIdForm.tsx b/packages/desktop-client/src/components/manager/subscribe/OpenIdForm.tsx index 4b881fa95c..82107e0d10 100644 --- a/packages/desktop-client/src/components/manager/subscribe/OpenIdForm.tsx +++ b/packages/desktop-client/src/components/manager/subscribe/OpenIdForm.tsx @@ -17,9 +17,9 @@ import { View } from '@actual-app/components/view'; import type { OpenIdConfig } from 'loot-core/types/models'; -import { Link } from '@desktop-client/components/common/Link'; -import { FormField, FormLabel } from '@desktop-client/components/forms'; -import { useServerURL } from '@desktop-client/components/ServerContext'; +import { Link } from '#components/common/Link'; +import { FormField, FormLabel } from '#components/forms'; +import { useServerURL } from '#components/ServerContext'; type OpenIdCallback = (config: OpenIdConfig) => Promise; diff --git a/packages/desktop-client/src/components/manager/subscribe/common.tsx b/packages/desktop-client/src/components/manager/subscribe/common.tsx index ee3ecae997..5333d607c1 100644 --- a/packages/desktop-client/src/components/manager/subscribe/common.tsx +++ b/packages/desktop-client/src/components/manager/subscribe/common.tsx @@ -11,8 +11,8 @@ import { useSetLoginMethods, useSetMultiuserEnabled, useSetServerURL, -} from '@desktop-client/components/ServerContext'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; +} from '#components/ServerContext'; +import { useNavigate } from '#hooks/useNavigate'; // There are two URLs that dance with each other: `/login` and // `/bootstrap`. Both of these URLs check the state of the the server diff --git a/packages/desktop-client/src/components/mobile/MobileBackButton.tsx b/packages/desktop-client/src/components/mobile/MobileBackButton.tsx index 0724267922..f543149fec 100644 --- a/packages/desktop-client/src/components/mobile/MobileBackButton.tsx +++ b/packages/desktop-client/src/components/mobile/MobileBackButton.tsx @@ -7,7 +7,7 @@ import { SvgCheveronLeft } from '@actual-app/components/icons/v1'; import { styles } from '@actual-app/components/styles'; import { Text } from '@actual-app/components/text'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; +import { useNavigate } from '#hooks/useNavigate'; type MobileBackButtonProps = ComponentPropsWithoutRef; diff --git a/packages/desktop-client/src/components/mobile/MobileNavTabs.tsx b/packages/desktop-client/src/components/mobile/MobileNavTabs.tsx index 9af026bf15..5c1f667fe2 100644 --- a/packages/desktop-client/src/components/mobile/MobileNavTabs.tsx +++ b/packages/desktop-client/src/components/mobile/MobileNavTabs.tsx @@ -21,9 +21,9 @@ import { theme } from '@actual-app/components/theme'; import { View } from '@actual-app/components/view'; import { useDrag } from '@use-gesture/react'; -import { useIsTestEnv } from '@desktop-client/hooks/useIsTestEnv'; -import { useScrollListener } from '@desktop-client/hooks/useScrollListener'; -import { useSyncServerStatus } from '@desktop-client/hooks/useSyncServerStatus'; +import { useIsTestEnv } from '#hooks/useIsTestEnv'; +import { useScrollListener } from '#hooks/useScrollListener'; +import { useSyncServerStatus } from '#hooks/useSyncServerStatus'; const COLUMN_COUNT = 3; const PILL_HEIGHT = 15; diff --git a/packages/desktop-client/src/components/mobile/accounts/AccountPage.tsx b/packages/desktop-client/src/components/mobile/accounts/AccountPage.tsx index a520901be3..eb2f20df90 100644 --- a/packages/desktop-client/src/components/mobile/accounts/AccountPage.tsx +++ b/packages/desktop-client/src/components/mobile/accounts/AccountPage.tsx @@ -17,22 +17,19 @@ import { AllAccountTransactions } from './AllAccountTransactions'; import { OffBudgetAccountTransactions } from './OffBudgetAccountTransactions'; import { OnBudgetAccountTransactions } from './OnBudgetAccountTransactions'; -import { - useReopenAccountMutation, - useUpdateAccountMutation, -} from '@desktop-client/accounts'; -import { MobileBackButton } from '@desktop-client/components/mobile/MobileBackButton'; -import { AddTransactionButton } from '@desktop-client/components/mobile/transactions/AddTransactionButton'; -import { MobilePageHeader, Page } from '@desktop-client/components/Page'; -import { useAccount } from '@desktop-client/hooks/useAccount'; -import { useFailedAccounts } from '@desktop-client/hooks/useFailedAccounts'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; +import { useReopenAccountMutation, useUpdateAccountMutation } from '#accounts'; +import { MobileBackButton } from '#components/mobile/MobileBackButton'; +import { AddTransactionButton } from '#components/mobile/transactions/AddTransactionButton'; +import { MobilePageHeader, Page } from '#components/Page'; +import { useAccount } from '#hooks/useAccount'; +import { useFailedAccounts } from '#hooks/useFailedAccounts'; +import { useSyncedPref } from '#hooks/useSyncedPref'; import { collapseModals, openAccountCloseModal, pushModal, -} from '@desktop-client/modals/modalsSlice'; -import { useDispatch, useSelector } from '@desktop-client/redux'; +} from '#modals/modalsSlice'; +import { useDispatch, useSelector } from '#redux'; export function AccountPage() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/mobile/accounts/AccountTransactions.tsx b/packages/desktop-client/src/components/mobile/accounts/AccountTransactions.tsx index 2095130a6e..baaecfd64c 100644 --- a/packages/desktop-client/src/components/mobile/accounts/AccountTransactions.tsx +++ b/packages/desktop-client/src/components/mobile/accounts/AccountTransactions.tsx @@ -7,25 +7,25 @@ import { isPreviewId } from 'loot-core/shared/transactions'; import type { IntegerAmount } from 'loot-core/shared/util'; import type { AccountEntity, TransactionEntity } from 'loot-core/types/models'; -import { useSyncAndDownloadMutation } from '@desktop-client/accounts'; -import { markAccountRead } from '@desktop-client/accounts/accountsSlice'; -import { TransactionListWithBalances } from '@desktop-client/components/mobile/transactions/TransactionListWithBalances'; -import { useAccountPreviewTransactions } from '@desktop-client/hooks/useAccountPreviewTransactions'; -import { SchedulesProvider } from '@desktop-client/hooks/useCachedSchedules'; -import { useDateFormat } from '@desktop-client/hooks/useDateFormat'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { getSchedulesQuery } from '@desktop-client/hooks/useSchedules'; -import { useSheetValue } from '@desktop-client/hooks/useSheetValue'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; +import { useSyncAndDownloadMutation } from '#accounts'; +import { markAccountRead } from '#accounts/accountsSlice'; +import { TransactionListWithBalances } from '#components/mobile/transactions/TransactionListWithBalances'; +import { useAccountPreviewTransactions } from '#hooks/useAccountPreviewTransactions'; +import { SchedulesProvider } from '#hooks/useCachedSchedules'; +import { useDateFormat } from '#hooks/useDateFormat'; +import { useNavigate } from '#hooks/useNavigate'; +import { getSchedulesQuery } from '#hooks/useSchedules'; +import { useSheetValue } from '#hooks/useSheetValue'; +import { useSyncedPref } from '#hooks/useSyncedPref'; import { calculateRunningBalancesTopDown, useTransactions, -} from '@desktop-client/hooks/useTransactions'; -import { useTransactionsSearch } from '@desktop-client/hooks/useTransactionsSearch'; -import { collapseModals, pushModal } from '@desktop-client/modals/modalsSlice'; -import * as queries from '@desktop-client/queries'; -import { useDispatch } from '@desktop-client/redux'; -import * as bindings from '@desktop-client/spreadsheet/bindings'; +} from '#hooks/useTransactions'; +import { useTransactionsSearch } from '#hooks/useTransactionsSearch'; +import { collapseModals, pushModal } from '#modals/modalsSlice'; +import * as queries from '#queries'; +import { useDispatch } from '#redux'; +import * as bindings from '#spreadsheet/bindings'; export function AccountTransactions({ account, diff --git a/packages/desktop-client/src/components/mobile/accounts/AccountsPage.tsx b/packages/desktop-client/src/components/mobile/accounts/AccountsPage.tsx index 0da3b60a85..37ef1d2833 100644 --- a/packages/desktop-client/src/components/mobile/accounts/AccountsPage.tsx +++ b/packages/desktop-client/src/components/mobile/accounts/AccountsPage.tsx @@ -24,27 +24,21 @@ import { css } from '@emotion/css'; import type { AccountEntity } from 'loot-core/types/models'; -import { - useMoveAccountMutation, - useSyncAndDownloadMutation, -} from '@desktop-client/accounts'; -import { makeAmountFullStyle } from '@desktop-client/components/budget/util'; -import { MOBILE_NAV_HEIGHT } from '@desktop-client/components/mobile/MobileNavTabs'; -import { PullToRefresh } from '@desktop-client/components/mobile/PullToRefresh'; -import { MobilePageHeader, Page } from '@desktop-client/components/Page'; -import { - CellValue, - CellValueText, -} from '@desktop-client/components/spreadsheet/CellValue'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; -import { useFailedAccounts } from '@desktop-client/hooks/useFailedAccounts'; -import { useLocalPref } from '@desktop-client/hooks/useLocalPref'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; -import { replaceModal } from '@desktop-client/modals/modalsSlice'; -import { useDispatch, useSelector } from '@desktop-client/redux'; -import type { Binding, SheetFields } from '@desktop-client/spreadsheet'; -import * as bindings from '@desktop-client/spreadsheet/bindings'; +import { useMoveAccountMutation, useSyncAndDownloadMutation } from '#accounts'; +import { makeAmountFullStyle } from '#components/budget/util'; +import { MOBILE_NAV_HEIGHT } from '#components/mobile/MobileNavTabs'; +import { PullToRefresh } from '#components/mobile/PullToRefresh'; +import { MobilePageHeader, Page } from '#components/Page'; +import { CellValue, CellValueText } from '#components/spreadsheet/CellValue'; +import { useAccounts } from '#hooks/useAccounts'; +import { useFailedAccounts } from '#hooks/useFailedAccounts'; +import { useLocalPref } from '#hooks/useLocalPref'; +import { useNavigate } from '#hooks/useNavigate'; +import { useSyncedPref } from '#hooks/useSyncedPref'; +import { replaceModal } from '#modals/modalsSlice'; +import { useDispatch, useSelector } from '#redux'; +import type { Binding, SheetFields } from '#spreadsheet'; +import * as bindings from '#spreadsheet/bindings'; const ROW_HEIGHT = 60; diff --git a/packages/desktop-client/src/components/mobile/accounts/AllAccountTransactions.tsx b/packages/desktop-client/src/components/mobile/accounts/AllAccountTransactions.tsx index d21cb6c131..01a20b4ca7 100644 --- a/packages/desktop-client/src/components/mobile/accounts/AllAccountTransactions.tsx +++ b/packages/desktop-client/src/components/mobile/accounts/AllAccountTransactions.tsx @@ -6,18 +6,18 @@ import type { Query } from 'loot-core/shared/query'; import { isPreviewId } from 'loot-core/shared/transactions'; import type { TransactionEntity } from 'loot-core/types/models'; -import { TransactionListWithBalances } from '@desktop-client/components/mobile/transactions/TransactionListWithBalances'; -import { SchedulesProvider } from '@desktop-client/hooks/useCachedSchedules'; -import { useDateFormat } from '@desktop-client/hooks/useDateFormat'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { usePreviewTransactions } from '@desktop-client/hooks/usePreviewTransactions'; -import { getSchedulesQuery } from '@desktop-client/hooks/useSchedules'; -import { useTransactions } from '@desktop-client/hooks/useTransactions'; -import { useTransactionsSearch } from '@desktop-client/hooks/useTransactionsSearch'; -import { collapseModals, pushModal } from '@desktop-client/modals/modalsSlice'; -import * as queries from '@desktop-client/queries'; -import { useDispatch } from '@desktop-client/redux'; -import * as bindings from '@desktop-client/spreadsheet/bindings'; +import { TransactionListWithBalances } from '#components/mobile/transactions/TransactionListWithBalances'; +import { SchedulesProvider } from '#hooks/useCachedSchedules'; +import { useDateFormat } from '#hooks/useDateFormat'; +import { useNavigate } from '#hooks/useNavigate'; +import { usePreviewTransactions } from '#hooks/usePreviewTransactions'; +import { getSchedulesQuery } from '#hooks/useSchedules'; +import { useTransactions } from '#hooks/useTransactions'; +import { useTransactionsSearch } from '#hooks/useTransactionsSearch'; +import { collapseModals, pushModal } from '#modals/modalsSlice'; +import * as queries from '#queries'; +import { useDispatch } from '#redux'; +import * as bindings from '#spreadsheet/bindings'; export function AllAccountTransactions() { const schedulesQuery = useMemo(() => getSchedulesQuery(), []); diff --git a/packages/desktop-client/src/components/mobile/accounts/OffBudgetAccountTransactions.tsx b/packages/desktop-client/src/components/mobile/accounts/OffBudgetAccountTransactions.tsx index 95f2afee1f..bfa58b8027 100644 --- a/packages/desktop-client/src/components/mobile/accounts/OffBudgetAccountTransactions.tsx +++ b/packages/desktop-client/src/components/mobile/accounts/OffBudgetAccountTransactions.tsx @@ -6,19 +6,19 @@ import type { Query } from 'loot-core/shared/query'; import { isPreviewId } from 'loot-core/shared/transactions'; import type { ScheduleEntity, TransactionEntity } from 'loot-core/types/models'; -import { TransactionListWithBalances } from '@desktop-client/components/mobile/transactions/TransactionListWithBalances'; -import { SchedulesProvider } from '@desktop-client/hooks/useCachedSchedules'; -import { useDateFormat } from '@desktop-client/hooks/useDateFormat'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { useOffBudgetAccounts } from '@desktop-client/hooks/useOffBudgetAccounts'; -import { usePreviewTransactions } from '@desktop-client/hooks/usePreviewTransactions'; -import { getSchedulesQuery } from '@desktop-client/hooks/useSchedules'; -import { useTransactions } from '@desktop-client/hooks/useTransactions'; -import { useTransactionsSearch } from '@desktop-client/hooks/useTransactionsSearch'; -import { collapseModals, pushModal } from '@desktop-client/modals/modalsSlice'; -import * as queries from '@desktop-client/queries'; -import { useDispatch } from '@desktop-client/redux'; -import * as bindings from '@desktop-client/spreadsheet/bindings'; +import { TransactionListWithBalances } from '#components/mobile/transactions/TransactionListWithBalances'; +import { SchedulesProvider } from '#hooks/useCachedSchedules'; +import { useDateFormat } from '#hooks/useDateFormat'; +import { useNavigate } from '#hooks/useNavigate'; +import { useOffBudgetAccounts } from '#hooks/useOffBudgetAccounts'; +import { usePreviewTransactions } from '#hooks/usePreviewTransactions'; +import { getSchedulesQuery } from '#hooks/useSchedules'; +import { useTransactions } from '#hooks/useTransactions'; +import { useTransactionsSearch } from '#hooks/useTransactionsSearch'; +import { collapseModals, pushModal } from '#modals/modalsSlice'; +import * as queries from '#queries'; +import { useDispatch } from '#redux'; +import * as bindings from '#spreadsheet/bindings'; export function OffBudgetAccountTransactions() { const schedulesQuery = useMemo(() => getSchedulesQuery('offbudget'), []); diff --git a/packages/desktop-client/src/components/mobile/accounts/OnBudgetAccountTransactions.tsx b/packages/desktop-client/src/components/mobile/accounts/OnBudgetAccountTransactions.tsx index 3c2fc2fa87..202edf5fcc 100644 --- a/packages/desktop-client/src/components/mobile/accounts/OnBudgetAccountTransactions.tsx +++ b/packages/desktop-client/src/components/mobile/accounts/OnBudgetAccountTransactions.tsx @@ -6,19 +6,19 @@ import type { Query } from 'loot-core/shared/query'; import { isPreviewId } from 'loot-core/shared/transactions'; import type { ScheduleEntity, TransactionEntity } from 'loot-core/types/models'; -import { TransactionListWithBalances } from '@desktop-client/components/mobile/transactions/TransactionListWithBalances'; -import { SchedulesProvider } from '@desktop-client/hooks/useCachedSchedules'; -import { useDateFormat } from '@desktop-client/hooks/useDateFormat'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { useOnBudgetAccounts } from '@desktop-client/hooks/useOnBudgetAccounts'; -import { usePreviewTransactions } from '@desktop-client/hooks/usePreviewTransactions'; -import { getSchedulesQuery } from '@desktop-client/hooks/useSchedules'; -import { useTransactions } from '@desktop-client/hooks/useTransactions'; -import { useTransactionsSearch } from '@desktop-client/hooks/useTransactionsSearch'; -import { collapseModals, pushModal } from '@desktop-client/modals/modalsSlice'; -import * as queries from '@desktop-client/queries'; -import { useDispatch } from '@desktop-client/redux'; -import * as bindings from '@desktop-client/spreadsheet/bindings'; +import { TransactionListWithBalances } from '#components/mobile/transactions/TransactionListWithBalances'; +import { SchedulesProvider } from '#hooks/useCachedSchedules'; +import { useDateFormat } from '#hooks/useDateFormat'; +import { useNavigate } from '#hooks/useNavigate'; +import { useOnBudgetAccounts } from '#hooks/useOnBudgetAccounts'; +import { usePreviewTransactions } from '#hooks/usePreviewTransactions'; +import { getSchedulesQuery } from '#hooks/useSchedules'; +import { useTransactions } from '#hooks/useTransactions'; +import { useTransactionsSearch } from '#hooks/useTransactionsSearch'; +import { collapseModals, pushModal } from '#modals/modalsSlice'; +import * as queries from '#queries'; +import { useDispatch } from '#redux'; +import * as bindings from '#spreadsheet/bindings'; export function OnBudgetAccountTransactions() { const schedulesQuery = useMemo(() => getSchedulesQuery('onbudget'), []); diff --git a/packages/desktop-client/src/components/mobile/banksync/BankSyncAccountsList.tsx b/packages/desktop-client/src/components/mobile/banksync/BankSyncAccountsList.tsx index 3c897522c8..a0a0cf73b0 100644 --- a/packages/desktop-client/src/components/mobile/banksync/BankSyncAccountsList.tsx +++ b/packages/desktop-client/src/components/mobile/banksync/BankSyncAccountsList.tsx @@ -8,7 +8,7 @@ import type { AccountEntity } from 'loot-core/types/models'; import { BankSyncAccountsListItem } from './BankSyncAccountsListItem'; -import { MOBILE_NAV_HEIGHT } from '@desktop-client/components/mobile/MobileNavTabs'; +import { MOBILE_NAV_HEIGHT } from '#components/mobile/MobileNavTabs'; type SyncProviders = 'goCardless' | 'simpleFin' | 'pluggyai' | 'unlinked'; diff --git a/packages/desktop-client/src/components/mobile/banksync/BankSyncAccountsListItem.tsx b/packages/desktop-client/src/components/mobile/banksync/BankSyncAccountsListItem.tsx index 46cf7d1ca5..2a336ced62 100644 --- a/packages/desktop-client/src/components/mobile/banksync/BankSyncAccountsListItem.tsx +++ b/packages/desktop-client/src/components/mobile/banksync/BankSyncAccountsListItem.tsx @@ -8,7 +8,7 @@ import { View } from '@actual-app/components/view'; import { tsToRelativeTime } from 'loot-core/shared/util'; import type { AccountEntity } from 'loot-core/types/models'; -import { useLocale } from '@desktop-client/hooks/useLocale'; +import { useLocale } from '#hooks/useLocale'; type BankSyncAccountsListItemProps = { account: AccountEntity; diff --git a/packages/desktop-client/src/components/mobile/banksync/MobileBankSyncAccountEditPage.tsx b/packages/desktop-client/src/components/mobile/banksync/MobileBankSyncAccountEditPage.tsx index 074a2b9e35..07ca6c2173 100644 --- a/packages/desktop-client/src/components/mobile/banksync/MobileBankSyncAccountEditPage.tsx +++ b/packages/desktop-client/src/components/mobile/banksync/MobileBankSyncAccountEditPage.tsx @@ -8,16 +8,16 @@ import { Text } from '@actual-app/components/text'; import { theme } from '@actual-app/components/theme'; import { View } from '@actual-app/components/view'; -import { useUnlinkAccountMutation } from '@desktop-client/accounts'; -import { BankSyncCheckboxOptions } from '@desktop-client/components/banksync/BankSyncCheckboxOptions'; -import { FieldMapping } from '@desktop-client/components/banksync/FieldMapping'; -import { useBankSyncAccountSettings } from '@desktop-client/components/banksync/useBankSyncAccountSettings'; -import { MobileBackButton } from '@desktop-client/components/mobile/MobileBackButton'; -import { MobilePageHeader, Page } from '@desktop-client/components/Page'; -import { useAccount } from '@desktop-client/hooks/useAccount'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { useUnlinkAccountMutation } from '#accounts'; +import { BankSyncCheckboxOptions } from '#components/banksync/BankSyncCheckboxOptions'; +import { FieldMapping } from '#components/banksync/FieldMapping'; +import { useBankSyncAccountSettings } from '#components/banksync/useBankSyncAccountSettings'; +import { MobileBackButton } from '#components/mobile/MobileBackButton'; +import { MobilePageHeader, Page } from '#components/Page'; +import { useAccount } from '#hooks/useAccount'; +import { useNavigate } from '#hooks/useNavigate'; +import { pushModal } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; export function MobileBankSyncAccountEditPage() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/mobile/banksync/MobileBankSyncPage.tsx b/packages/desktop-client/src/components/mobile/banksync/MobileBankSyncPage.tsx index 748f4464aa..a3cfd70047 100644 --- a/packages/desktop-client/src/components/mobile/banksync/MobileBankSyncPage.tsx +++ b/packages/desktop-client/src/components/mobile/banksync/MobileBankSyncPage.tsx @@ -10,12 +10,12 @@ import type { AccountEntity, BankSyncProviders } from 'loot-core/types/models'; import { BankSyncAccountsList } from './BankSyncAccountsList'; -import { Search } from '@desktop-client/components/common/Search'; -import { MobilePageHeader, Page } from '@desktop-client/components/Page'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { Search } from '#components/common/Search'; +import { MobilePageHeader, Page } from '#components/Page'; +import { useAccounts } from '#hooks/useAccounts'; +import { useNavigate } from '#hooks/useNavigate'; +import { pushModal } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; type SyncProviders = BankSyncProviders | 'unlinked'; diff --git a/packages/desktop-client/src/components/mobile/budget/BalanceCell.tsx b/packages/desktop-client/src/components/mobile/budget/BalanceCell.tsx index c65660d42a..aa8969d8d5 100644 --- a/packages/desktop-client/src/components/mobile/budget/BalanceCell.tsx +++ b/packages/desktop-client/src/components/mobile/budget/BalanceCell.tsx @@ -14,15 +14,12 @@ import type { CategoryEntity } from 'loot-core/types/models'; import { getColumnWidth, PILL_STYLE } from './BudgetTable'; -import { BalanceWithCarryover } from '@desktop-client/components/budget/BalanceWithCarryover'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; -import type { Binding } from '@desktop-client/spreadsheet'; -import { - envelopeBudget, - trackingBudget, -} from '@desktop-client/spreadsheet/bindings'; +import { BalanceWithCarryover } from '#components/budget/BalanceWithCarryover'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { useFormat } from '#hooks/useFormat'; +import { useSyncedPref } from '#hooks/useSyncedPref'; +import type { Binding } from '#spreadsheet'; +import { envelopeBudget, trackingBudget } from '#spreadsheet/bindings'; type BalanceCellProps = { binding: Binding< diff --git a/packages/desktop-client/src/components/mobile/budget/BudgetCell.tsx b/packages/desktop-client/src/components/mobile/budget/BudgetCell.tsx index c447dba690..a60a47a5e8 100644 --- a/packages/desktop-client/src/components/mobile/budget/BudgetCell.tsx +++ b/packages/desktop-client/src/components/mobile/budget/BudgetCell.tsx @@ -11,16 +11,16 @@ import type { CategoryEntity } from 'loot-core/types/models'; import { getColumnWidth, PILL_STYLE } from './BudgetTable'; -import { makeAmountGrey } from '@desktop-client/components/budget/util'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { CellValue } from '@desktop-client/components/spreadsheet/CellValue'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useNotes } from '@desktop-client/hooks/useNotes'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; -import { useUndo } from '@desktop-client/hooks/useUndo'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; -import type { SheetFields } from '@desktop-client/spreadsheet'; +import { makeAmountGrey } from '#components/budget/util'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { CellValue } from '#components/spreadsheet/CellValue'; +import { useFormat } from '#hooks/useFormat'; +import { useNotes } from '#hooks/useNotes'; +import { useSyncedPref } from '#hooks/useSyncedPref'; +import { useUndo } from '#hooks/useUndo'; +import { pushModal } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; +import type { SheetFields } from '#spreadsheet'; type BudgetCellProps< SheetFieldName extends SheetFields<'envelope-budget' | 'tracking-budget'>, diff --git a/packages/desktop-client/src/components/mobile/budget/BudgetPage.tsx b/packages/desktop-client/src/components/mobile/budget/BudgetPage.tsx index d6578653fa..1a5c610fc4 100644 --- a/packages/desktop-client/src/components/mobile/budget/BudgetPage.tsx +++ b/packages/desktop-client/src/components/mobile/budget/BudgetPage.tsx @@ -34,7 +34,7 @@ import type { TransObjectLiteral } from 'loot-core/types/util'; import { BudgetTable, PILL_STYLE } from './BudgetTable'; -import { sync } from '@desktop-client/app/appSlice'; +import { sync } from '#app/appSlice'; import { useBudgetActions, useCreateCategoryGroupMutation, @@ -43,28 +43,28 @@ import { useDeleteCategoryMutation, useSaveCategoryGroupMutation, useSaveCategoryMutation, -} from '@desktop-client/budget'; -import { closeBudget } from '@desktop-client/budgetfiles/budgetfilesSlice'; -import { prewarmMonth } from '@desktop-client/components/budget/util'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { MobilePageHeader, Page } from '@desktop-client/components/Page'; -import { SyncRefresh } from '@desktop-client/components/SyncRefresh'; -import { useCategories } from '@desktop-client/hooks/useCategories'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useLocale } from '@desktop-client/hooks/useLocale'; -import { useLocalPref } from '@desktop-client/hooks/useLocalPref'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { useOverspentCategories } from '@desktop-client/hooks/useOverspentCategories'; -import { SheetNameProvider } from '@desktop-client/hooks/useSheetName'; -import { useSheetValue } from '@desktop-client/hooks/useSheetValue'; -import { useSpreadsheet } from '@desktop-client/hooks/useSpreadsheet'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; -import { useTransactions } from '@desktop-client/hooks/useTransactions'; -import { useUndo } from '@desktop-client/hooks/useUndo'; -import { collapseModals, pushModal } from '@desktop-client/modals/modalsSlice'; -import { uncategorizedTransactions } from '@desktop-client/queries'; -import { useDispatch } from '@desktop-client/redux'; -import { envelopeBudget } from '@desktop-client/spreadsheet/bindings'; +} from '#budget'; +import { closeBudget } from '#budgetfiles/budgetfilesSlice'; +import { prewarmMonth } from '#components/budget/util'; +import { FinancialText } from '#components/FinancialText'; +import { MobilePageHeader, Page } from '#components/Page'; +import { SyncRefresh } from '#components/SyncRefresh'; +import { useCategories } from '#hooks/useCategories'; +import { useFormat } from '#hooks/useFormat'; +import { useLocale } from '#hooks/useLocale'; +import { useLocalPref } from '#hooks/useLocalPref'; +import { useNavigate } from '#hooks/useNavigate'; +import { useOverspentCategories } from '#hooks/useOverspentCategories'; +import { SheetNameProvider } from '#hooks/useSheetName'; +import { useSheetValue } from '#hooks/useSheetValue'; +import { useSpreadsheet } from '#hooks/useSpreadsheet'; +import { useSyncedPref } from '#hooks/useSyncedPref'; +import { useTransactions } from '#hooks/useTransactions'; +import { useUndo } from '#hooks/useUndo'; +import { collapseModals, pushModal } from '#modals/modalsSlice'; +import { uncategorizedTransactions } from '#queries'; +import { useDispatch } from '#redux'; +import { envelopeBudget } from '#spreadsheet/bindings'; function isBudgetType(input?: string): input is 'envelope' | 'tracking' { return ['envelope', 'tracking'].includes(input); diff --git a/packages/desktop-client/src/components/mobile/budget/BudgetTable.tsx b/packages/desktop-client/src/components/mobile/budget/BudgetTable.tsx index 79b740e755..f66f1ead3e 100644 --- a/packages/desktop-client/src/components/mobile/budget/BudgetTable.tsx +++ b/packages/desktop-client/src/components/mobile/budget/BudgetTable.tsx @@ -23,20 +23,17 @@ import type { import { ExpenseGroupList } from './ExpenseGroupList'; import { IncomeGroup } from './IncomeGroup'; -import { MOBILE_NAV_HEIGHT } from '@desktop-client/components/mobile/MobileNavTabs'; -import { PullToRefresh } from '@desktop-client/components/mobile/PullToRefresh'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { CellValue } from '@desktop-client/components/spreadsheet/CellValue'; -import { SchedulesProvider } from '@desktop-client/hooks/useCachedSchedules'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useLocalPref } from '@desktop-client/hooks/useLocalPref'; -import { useSheetValue } from '@desktop-client/hooks/useSheetValue'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; -import type { Binding } from '@desktop-client/spreadsheet'; -import { - envelopeBudget, - trackingBudget, -} from '@desktop-client/spreadsheet/bindings'; +import { MOBILE_NAV_HEIGHT } from '#components/mobile/MobileNavTabs'; +import { PullToRefresh } from '#components/mobile/PullToRefresh'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { CellValue } from '#components/spreadsheet/CellValue'; +import { SchedulesProvider } from '#hooks/useCachedSchedules'; +import { useFormat } from '#hooks/useFormat'; +import { useLocalPref } from '#hooks/useLocalPref'; +import { useSheetValue } from '#hooks/useSheetValue'; +import { useSyncedPref } from '#hooks/useSyncedPref'; +import type { Binding } from '#spreadsheet'; +import { envelopeBudget, trackingBudget } from '#spreadsheet/bindings'; export const ROW_HEIGHT = 50; diff --git a/packages/desktop-client/src/components/mobile/budget/CategoryGroupActionMenu.tsx b/packages/desktop-client/src/components/mobile/budget/CategoryGroupActionMenu.tsx index b74e963e90..82bb893cdd 100644 --- a/packages/desktop-client/src/components/mobile/budget/CategoryGroupActionMenu.tsx +++ b/packages/desktop-client/src/components/mobile/budget/CategoryGroupActionMenu.tsx @@ -4,7 +4,7 @@ import { useTranslation } from 'react-i18next'; import { Menu } from '@actual-app/components/menu'; -import { useFeatureFlag } from '@desktop-client/hooks/useFeatureFlag'; +import { useFeatureFlag } from '#hooks/useFeatureFlag'; type CategoryGroupActionMenuProps = Omit< ComponentPropsWithoutRef, diff --git a/packages/desktop-client/src/components/mobile/budget/CategoryPage.tsx b/packages/desktop-client/src/components/mobile/budget/CategoryPage.tsx index ee099386ad..9f35846945 100644 --- a/packages/desktop-client/src/components/mobile/budget/CategoryPage.tsx +++ b/packages/desktop-client/src/components/mobile/budget/CategoryPage.tsx @@ -10,12 +10,12 @@ import * as monthUtils from 'loot-core/shared/months'; import { CategoryTransactions } from './CategoryTransactions'; import { UncategorizedTransactions } from './UncategorizedTransactions'; -import { MobileBackButton } from '@desktop-client/components/mobile/MobileBackButton'; -import { AddTransactionButton } from '@desktop-client/components/mobile/transactions/AddTransactionButton'; -import { MobilePageHeader, Page } from '@desktop-client/components/Page'; -import { useCategory } from '@desktop-client/hooks/useCategory'; -import { useLocale } from '@desktop-client/hooks/useLocale'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; +import { MobileBackButton } from '#components/mobile/MobileBackButton'; +import { AddTransactionButton } from '#components/mobile/transactions/AddTransactionButton'; +import { MobilePageHeader, Page } from '#components/Page'; +import { useCategory } from '#hooks/useCategory'; +import { useLocale } from '#hooks/useLocale'; +import { useSyncedPref } from '#hooks/useSyncedPref'; export function CategoryPage() { const locale = useLocale(); diff --git a/packages/desktop-client/src/components/mobile/budget/CategoryTransactions.tsx b/packages/desktop-client/src/components/mobile/budget/CategoryTransactions.tsx index 14d77c68f7..80f011fa0e 100644 --- a/packages/desktop-client/src/components/mobile/budget/CategoryTransactions.tsx +++ b/packages/desktop-client/src/components/mobile/budget/CategoryTransactions.tsx @@ -4,14 +4,14 @@ import { q } from 'loot-core/shared/query'; import { isPreviewId } from 'loot-core/shared/transactions'; import type { CategoryEntity, TransactionEntity } from 'loot-core/types/models'; -import { TransactionListWithBalances } from '@desktop-client/components/mobile/transactions/TransactionListWithBalances'; -import { SchedulesProvider } from '@desktop-client/hooks/useCachedSchedules'; -import { useCategoryPreviewTransactions } from '@desktop-client/hooks/useCategoryPreviewTransactions'; -import { useDateFormat } from '@desktop-client/hooks/useDateFormat'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { useTransactions } from '@desktop-client/hooks/useTransactions'; -import { useTransactionsSearch } from '@desktop-client/hooks/useTransactionsSearch'; -import * as bindings from '@desktop-client/spreadsheet/bindings'; +import { TransactionListWithBalances } from '#components/mobile/transactions/TransactionListWithBalances'; +import { SchedulesProvider } from '#hooks/useCachedSchedules'; +import { useCategoryPreviewTransactions } from '#hooks/useCategoryPreviewTransactions'; +import { useDateFormat } from '#hooks/useDateFormat'; +import { useNavigate } from '#hooks/useNavigate'; +import { useTransactions } from '#hooks/useTransactions'; +import { useTransactionsSearch } from '#hooks/useTransactionsSearch'; +import * as bindings from '#spreadsheet/bindings'; type CategoryTransactionsProps = { category: CategoryEntity; diff --git a/packages/desktop-client/src/components/mobile/budget/ExpenseCategoryList.tsx b/packages/desktop-client/src/components/mobile/budget/ExpenseCategoryList.tsx index 1ec7c1dd81..c158bd57d2 100644 --- a/packages/desktop-client/src/components/mobile/budget/ExpenseCategoryList.tsx +++ b/packages/desktop-client/src/components/mobile/budget/ExpenseCategoryList.tsx @@ -12,7 +12,7 @@ import type { import { ExpenseCategoryListItem } from './ExpenseCategoryListItem'; -import { useMoveCategoryMutation } from '@desktop-client/budget'; +import { useMoveCategoryMutation } from '#budget'; type ExpenseCategoryListProps = { categoryGroup: CategoryGroupEntity; diff --git a/packages/desktop-client/src/components/mobile/budget/ExpenseCategoryListItem.tsx b/packages/desktop-client/src/components/mobile/budget/ExpenseCategoryListItem.tsx index f9fffc87f1..9bda9679d2 100644 --- a/packages/desktop-client/src/components/mobile/budget/ExpenseCategoryListItem.tsx +++ b/packages/desktop-client/src/components/mobile/budget/ExpenseCategoryListItem.tsx @@ -20,18 +20,15 @@ import { BudgetCell } from './BudgetCell'; import { getColumnWidth, ROW_HEIGHT } from './BudgetTable'; import { SpentCell } from './SpentCell'; -import { useCategoriesById } from '@desktop-client/hooks/useCategories'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { useSheetValue } from '@desktop-client/hooks/useSheetValue'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; -import { useUndo } from '@desktop-client/hooks/useUndo'; -import { collapseModals, pushModal } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; -import { - envelopeBudget, - trackingBudget, -} from '@desktop-client/spreadsheet/bindings'; +import { useCategoriesById } from '#hooks/useCategories'; +import { useFormat } from '#hooks/useFormat'; +import { useNavigate } from '#hooks/useNavigate'; +import { useSheetValue } from '#hooks/useSheetValue'; +import { useSyncedPref } from '#hooks/useSyncedPref'; +import { useUndo } from '#hooks/useUndo'; +import { collapseModals, pushModal } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; +import { envelopeBudget, trackingBudget } from '#spreadsheet/bindings'; type ExpenseCategoryNameProps = { category: CategoryEntity; diff --git a/packages/desktop-client/src/components/mobile/budget/ExpenseGroupList.tsx b/packages/desktop-client/src/components/mobile/budget/ExpenseGroupList.tsx index 94eb8ceccd..0803bc66e2 100644 --- a/packages/desktop-client/src/components/mobile/budget/ExpenseGroupList.tsx +++ b/packages/desktop-client/src/components/mobile/budget/ExpenseGroupList.tsx @@ -15,7 +15,7 @@ import { ExpenseGroupListItem, } from './ExpenseGroupListItem'; -import { useMoveCategoryGroupMutation } from '@desktop-client/budget'; +import { useMoveCategoryGroupMutation } from '#budget'; type ExpenseGroupListProps = { categoryGroups: CategoryGroupEntity[]; diff --git a/packages/desktop-client/src/components/mobile/budget/ExpenseGroupListItem.tsx b/packages/desktop-client/src/components/mobile/budget/ExpenseGroupListItem.tsx index 74f275dc5d..e1f51102b1 100644 --- a/packages/desktop-client/src/components/mobile/budget/ExpenseGroupListItem.tsx +++ b/packages/desktop-client/src/components/mobile/budget/ExpenseGroupListItem.tsx @@ -23,14 +23,11 @@ import type { import { getColumnWidth, ROW_HEIGHT } from './BudgetTable'; import { ExpenseCategoryList } from './ExpenseCategoryList'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { CellValue } from '@desktop-client/components/spreadsheet/CellValue'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; -import { - envelopeBudget, - trackingBudget, -} from '@desktop-client/spreadsheet/bindings'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { CellValue } from '#components/spreadsheet/CellValue'; +import { useFormat } from '#hooks/useFormat'; +import { useSyncedPref } from '#hooks/useSyncedPref'; +import { envelopeBudget, trackingBudget } from '#spreadsheet/bindings'; type ExpenseGroupListItemProps = ComponentPropsWithoutRef< typeof GridListItem diff --git a/packages/desktop-client/src/components/mobile/budget/IncomeCategoryList.tsx b/packages/desktop-client/src/components/mobile/budget/IncomeCategoryList.tsx index 4143a1f678..67ee5eb67e 100644 --- a/packages/desktop-client/src/components/mobile/budget/IncomeCategoryList.tsx +++ b/packages/desktop-client/src/components/mobile/budget/IncomeCategoryList.tsx @@ -9,7 +9,7 @@ import type { CategoryEntity } from 'loot-core/types/models'; import { IncomeCategoryListItem } from './IncomeCategoryListItem'; -import { useMoveCategoryMutation } from '@desktop-client/budget'; +import { useMoveCategoryMutation } from '#budget'; type IncomeCategoryListProps = { categories: CategoryEntity[]; diff --git a/packages/desktop-client/src/components/mobile/budget/IncomeCategoryListItem.tsx b/packages/desktop-client/src/components/mobile/budget/IncomeCategoryListItem.tsx index b328495924..9716f80b1d 100644 --- a/packages/desktop-client/src/components/mobile/budget/IncomeCategoryListItem.tsx +++ b/packages/desktop-client/src/components/mobile/budget/IncomeCategoryListItem.tsx @@ -17,14 +17,11 @@ import { BalanceCell } from './BalanceCell'; import { BudgetCell } from './BudgetCell'; import { getColumnWidth, ROW_HEIGHT } from './BudgetTable'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; -import { collapseModals, pushModal } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; -import { - envelopeBudget, - trackingBudget, -} from '@desktop-client/spreadsheet/bindings'; +import { useNavigate } from '#hooks/useNavigate'; +import { useSyncedPref } from '#hooks/useSyncedPref'; +import { collapseModals, pushModal } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; +import { envelopeBudget, trackingBudget } from '#spreadsheet/bindings'; type IncomeCategoryNameProps = { category: CategoryEntity; diff --git a/packages/desktop-client/src/components/mobile/budget/IncomeGroup.tsx b/packages/desktop-client/src/components/mobile/budget/IncomeGroup.tsx index b46ce395f6..47a1daffbc 100644 --- a/packages/desktop-client/src/components/mobile/budget/IncomeGroup.tsx +++ b/packages/desktop-client/src/components/mobile/budget/IncomeGroup.tsx @@ -20,14 +20,11 @@ import type { CategoryGroupEntity } from 'loot-core/types/models'; import { getColumnWidth, ROW_HEIGHT } from './BudgetTable'; import { IncomeCategoryList } from './IncomeCategoryList'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { CellValue } from '@desktop-client/components/spreadsheet/CellValue'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; -import { - envelopeBudget, - trackingBudget, -} from '@desktop-client/spreadsheet/bindings'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { CellValue } from '#components/spreadsheet/CellValue'; +import { useFormat } from '#hooks/useFormat'; +import { useSyncedPref } from '#hooks/useSyncedPref'; +import { envelopeBudget, trackingBudget } from '#spreadsheet/bindings'; type IncomeGroupProps = { categoryGroup: CategoryGroupEntity; diff --git a/packages/desktop-client/src/components/mobile/budget/SpentCell.tsx b/packages/desktop-client/src/components/mobile/budget/SpentCell.tsx index 1cd8005638..0734d8b5a8 100644 --- a/packages/desktop-client/src/components/mobile/budget/SpentCell.tsx +++ b/packages/desktop-client/src/components/mobile/budget/SpentCell.tsx @@ -15,12 +15,12 @@ import type { CategoryEntity } from 'loot-core/types/models'; import { getColumnWidth, PILL_STYLE } from './BudgetTable'; -import { makeAmountGrey } from '@desktop-client/components/budget/util'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { CellValue } from '@desktop-client/components/spreadsheet/CellValue'; -import { useCategoryScheduleGoalTemplateIndicator } from '@desktop-client/hooks/useCategoryScheduleGoalTemplateIndicator'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import type { Binding } from '@desktop-client/spreadsheet'; +import { makeAmountGrey } from '#components/budget/util'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { CellValue } from '#components/spreadsheet/CellValue'; +import { useCategoryScheduleGoalTemplateIndicator } from '#hooks/useCategoryScheduleGoalTemplateIndicator'; +import { useFormat } from '#hooks/useFormat'; +import type { Binding } from '#spreadsheet'; type SpentCellProps = { binding: Binding<'envelope-budget' | 'tracking-budget', 'sum-amount'>; diff --git a/packages/desktop-client/src/components/mobile/budget/UncategorizedTransactions.tsx b/packages/desktop-client/src/components/mobile/budget/UncategorizedTransactions.tsx index c628ab5c7e..73a7179353 100644 --- a/packages/desktop-client/src/components/mobile/budget/UncategorizedTransactions.tsx +++ b/packages/desktop-client/src/components/mobile/budget/UncategorizedTransactions.tsx @@ -3,14 +3,14 @@ import React, { useCallback, useState } from 'react'; import { isPreviewId } from 'loot-core/shared/transactions'; import type { TransactionEntity } from 'loot-core/types/models'; -import { TransactionListWithBalances } from '@desktop-client/components/mobile/transactions/TransactionListWithBalances'; -import { SchedulesProvider } from '@desktop-client/hooks/useCachedSchedules'; -import { useDateFormat } from '@desktop-client/hooks/useDateFormat'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { useTransactions } from '@desktop-client/hooks/useTransactions'; -import { useTransactionsSearch } from '@desktop-client/hooks/useTransactionsSearch'; -import { uncategorizedTransactions } from '@desktop-client/queries'; -import * as bindings from '@desktop-client/spreadsheet/bindings'; +import { TransactionListWithBalances } from '#components/mobile/transactions/TransactionListWithBalances'; +import { SchedulesProvider } from '#hooks/useCachedSchedules'; +import { useDateFormat } from '#hooks/useDateFormat'; +import { useNavigate } from '#hooks/useNavigate'; +import { useTransactions } from '#hooks/useTransactions'; +import { useTransactionsSearch } from '#hooks/useTransactionsSearch'; +import { uncategorizedTransactions } from '#queries'; +import * as bindings from '#spreadsheet/bindings'; export function UncategorizedTransactions() { const navigate = useNavigate(); diff --git a/packages/desktop-client/src/components/mobile/payees/MobilePayeeEditPage.tsx b/packages/desktop-client/src/components/mobile/payees/MobilePayeeEditPage.tsx index 9c83e38240..d82ece6223 100644 --- a/packages/desktop-client/src/components/mobile/payees/MobilePayeeEditPage.tsx +++ b/packages/desktop-client/src/components/mobile/payees/MobilePayeeEditPage.tsx @@ -11,14 +11,14 @@ import { View } from '@actual-app/components/view'; import { send } from 'loot-core/platform/client/connection'; import type { PayeeEntity } from 'loot-core/types/models'; -import { MobileBackButton } from '@desktop-client/components/mobile/MobileBackButton'; -import { InputField } from '@desktop-client/components/mobile/MobileForms'; -import { MobilePageHeader, Page } from '@desktop-client/components/Page'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { usePayees } from '@desktop-client/hooks/usePayees'; -import { useUndo } from '@desktop-client/hooks/useUndo'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { MobileBackButton } from '#components/mobile/MobileBackButton'; +import { InputField } from '#components/mobile/MobileForms'; +import { MobilePageHeader, Page } from '#components/Page'; +import { useNavigate } from '#hooks/useNavigate'; +import { usePayees } from '#hooks/usePayees'; +import { useUndo } from '#hooks/useUndo'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; export function MobilePayeeEditPage() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/mobile/payees/MobilePayeesPage.test.tsx b/packages/desktop-client/src/components/mobile/payees/MobilePayeesPage.test.tsx index bb81036dc1..f26579e0ca 100644 --- a/packages/desktop-client/src/components/mobile/payees/MobilePayeesPage.test.tsx +++ b/packages/desktop-client/src/components/mobile/payees/MobilePayeesPage.test.tsx @@ -7,14 +7,14 @@ import type { PayeeEntity } from 'loot-core/types/models'; import { MobilePayeesPage } from './MobilePayeesPage'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { createTestQueryClient, TestProviders } from '@desktop-client/mocks'; -import { payeeQueries } from '@desktop-client/payees'; +import { useNavigate } from '#hooks/useNavigate'; +import { createTestQueryClient, TestProviders } from '#mocks'; +import { payeeQueries } from '#payees'; vi.mock('@use-gesture/react', () => ({ useDrag: vi.fn().mockReturnValue(() => ({})), })); -vi.mock('@desktop-client/hooks/useNavigate'); +vi.mock('#hooks/useNavigate'); const mockPayees: PayeeEntity[] = [ { diff --git a/packages/desktop-client/src/components/mobile/payees/MobilePayeesPage.tsx b/packages/desktop-client/src/components/mobile/payees/MobilePayeesPage.tsx index f9c575bc6b..91f920a0d1 100644 --- a/packages/desktop-client/src/components/mobile/payees/MobilePayeesPage.tsx +++ b/packages/desktop-client/src/components/mobile/payees/MobilePayeesPage.tsx @@ -11,14 +11,14 @@ import type { PayeeEntity, RuleEntity } from 'loot-core/types/models'; import { PayeesList } from './PayeesList'; -import { Search } from '@desktop-client/components/common/Search'; -import { MobilePageHeader, Page } from '@desktop-client/components/Page'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { usePayeeRuleCounts } from '@desktop-client/hooks/usePayeeRuleCounts'; -import { usePayees } from '@desktop-client/hooks/usePayees'; -import { useUndo } from '@desktop-client/hooks/useUndo'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { Search } from '#components/common/Search'; +import { MobilePageHeader, Page } from '#components/Page'; +import { useNavigate } from '#hooks/useNavigate'; +import { usePayeeRuleCounts } from '#hooks/usePayeeRuleCounts'; +import { usePayees } from '#hooks/usePayees'; +import { useUndo } from '#hooks/useUndo'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; export function MobilePayeesPage() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/mobile/payees/PayeesList.tsx b/packages/desktop-client/src/components/mobile/payees/PayeesList.tsx index 3d758d164a..342e49a990 100644 --- a/packages/desktop-client/src/components/mobile/payees/PayeesList.tsx +++ b/packages/desktop-client/src/components/mobile/payees/PayeesList.tsx @@ -10,7 +10,7 @@ import type { PayeeEntity } from 'loot-core/types/models'; import { PayeesListItem } from './PayeesListItem'; -import { MOBILE_NAV_HEIGHT } from '@desktop-client/components/mobile/MobileNavTabs'; +import { MOBILE_NAV_HEIGHT } from '#components/mobile/MobileNavTabs'; type PayeesListProps = { payees: PayeeEntity[]; diff --git a/packages/desktop-client/src/components/mobile/payees/PayeesListItem.tsx b/packages/desktop-client/src/components/mobile/payees/PayeesListItem.tsx index 7a4668c338..019f5883c6 100644 --- a/packages/desktop-client/src/components/mobile/payees/PayeesListItem.tsx +++ b/packages/desktop-client/src/components/mobile/payees/PayeesListItem.tsx @@ -11,8 +11,8 @@ import { View } from '@actual-app/components/view'; import type { PayeeEntity } from 'loot-core/types/models'; import type { WithRequired } from 'loot-core/types/util'; -import { ActionableGridListItem } from '@desktop-client/components/mobile/ActionableGridListItem'; -import { PayeeRuleCountLabel } from '@desktop-client/components/payees/PayeeRuleCountLabel'; +import { ActionableGridListItem } from '#components/mobile/ActionableGridListItem'; +import { PayeeRuleCountLabel } from '#components/payees/PayeeRuleCountLabel'; type PayeesListItemProps = { ruleCount: number; diff --git a/packages/desktop-client/src/components/mobile/rules/AddRuleButton.tsx b/packages/desktop-client/src/components/mobile/rules/AddRuleButton.tsx index fbab6199ae..0d21181d53 100644 --- a/packages/desktop-client/src/components/mobile/rules/AddRuleButton.tsx +++ b/packages/desktop-client/src/components/mobile/rules/AddRuleButton.tsx @@ -4,7 +4,7 @@ import { useTranslation } from 'react-i18next'; import { Button } from '@actual-app/components/button'; import { SvgAdd } from '@actual-app/components/icons/v1'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; +import { useNavigate } from '#hooks/useNavigate'; export function AddRuleButton() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/mobile/rules/MobileRuleEditPage.tsx b/packages/desktop-client/src/components/mobile/rules/MobileRuleEditPage.tsx index 2e2aaa51df..9f0098fdc6 100644 --- a/packages/desktop-client/src/components/mobile/rules/MobileRuleEditPage.tsx +++ b/packages/desktop-client/src/components/mobile/rules/MobileRuleEditPage.tsx @@ -10,15 +10,15 @@ import { send } from 'loot-core/platform/client/connection'; import { q } from 'loot-core/shared/query'; import type { NewRuleEntity, RuleEntity } from 'loot-core/types/models'; -import { MobileBackButton } from '@desktop-client/components/mobile/MobileBackButton'; -import { MobilePageHeader, Page } from '@desktop-client/components/Page'; -import { RuleEditor } from '@desktop-client/components/rules/RuleEditor'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { useSchedules } from '@desktop-client/hooks/useSchedules'; -import { useUndo } from '@desktop-client/hooks/useUndo'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { MobileBackButton } from '#components/mobile/MobileBackButton'; +import { MobilePageHeader, Page } from '#components/Page'; +import { RuleEditor } from '#components/rules/RuleEditor'; +import { useNavigate } from '#hooks/useNavigate'; +import { useSchedules } from '#hooks/useSchedules'; +import { useUndo } from '#hooks/useUndo'; +import { pushModal } from '#modals/modalsSlice'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; export function MobileRuleEditPage() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/mobile/rules/MobileRulesPage.tsx b/packages/desktop-client/src/components/mobile/rules/MobileRulesPage.tsx index 58ed7322d2..3b2f2add7a 100644 --- a/packages/desktop-client/src/components/mobile/rules/MobileRulesPage.tsx +++ b/packages/desktop-client/src/components/mobile/rules/MobileRulesPage.tsx @@ -14,18 +14,18 @@ import type { RuleEntity } from 'loot-core/types/models'; import { AddRuleButton } from './AddRuleButton'; import { RulesList } from './RulesList'; -import { Search } from '@desktop-client/components/common/Search'; -import { ruleToString } from '@desktop-client/components/ManageRules'; -import { MobilePageHeader, Page } from '@desktop-client/components/Page'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; -import { useCategories } from '@desktop-client/hooks/useCategories'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { usePayees } from '@desktop-client/hooks/usePayees'; -import { useSchedules } from '@desktop-client/hooks/useSchedules'; -import { useUndo } from '@desktop-client/hooks/useUndo'; -import { useUrlParam } from '@desktop-client/hooks/useUrlParam'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { Search } from '#components/common/Search'; +import { ruleToString } from '#components/ManageRules'; +import { MobilePageHeader, Page } from '#components/Page'; +import { useAccounts } from '#hooks/useAccounts'; +import { useCategories } from '#hooks/useCategories'; +import { useNavigate } from '#hooks/useNavigate'; +import { usePayees } from '#hooks/usePayees'; +import { useSchedules } from '#hooks/useSchedules'; +import { useUndo } from '#hooks/useUndo'; +import { useUrlParam } from '#hooks/useUrlParam'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; export function MobileRulesPage() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/mobile/rules/RulesList.tsx b/packages/desktop-client/src/components/mobile/rules/RulesList.tsx index 90918fb241..1f796b4da6 100644 --- a/packages/desktop-client/src/components/mobile/rules/RulesList.tsx +++ b/packages/desktop-client/src/components/mobile/rules/RulesList.tsx @@ -10,7 +10,7 @@ import type { RuleEntity } from 'loot-core/types/models'; import { RulesListItem } from './RulesListItem'; -import { MOBILE_NAV_HEIGHT } from '@desktop-client/components/mobile/MobileNavTabs'; +import { MOBILE_NAV_HEIGHT } from '#components/mobile/MobileNavTabs'; type RulesListProps = { rules: RuleEntity[]; diff --git a/packages/desktop-client/src/components/mobile/rules/RulesListItem.tsx b/packages/desktop-client/src/components/mobile/rules/RulesListItem.tsx index 541018e213..cca6b0e169 100644 --- a/packages/desktop-client/src/components/mobile/rules/RulesListItem.tsx +++ b/packages/desktop-client/src/components/mobile/rules/RulesListItem.tsx @@ -11,10 +11,10 @@ import { View } from '@actual-app/components/view'; import type { RuleEntity } from 'loot-core/types/models'; import type { WithRequired } from 'loot-core/types/util'; -import { ActionableGridListItem } from '@desktop-client/components/mobile/ActionableGridListItem'; -import { ActionExpression } from '@desktop-client/components/rules/ActionExpression'; -import { ConditionExpression } from '@desktop-client/components/rules/ConditionExpression'; -import { groupActionsBySplitIndex } from '@desktop-client/util/ruleUtils'; +import { ActionableGridListItem } from '#components/mobile/ActionableGridListItem'; +import { ActionExpression } from '#components/rules/ActionExpression'; +import { ConditionExpression } from '#components/rules/ConditionExpression'; +import { groupActionsBySplitIndex } from '#util/ruleUtils'; type RulesListItemProps = { onDelete: () => void; diff --git a/packages/desktop-client/src/components/mobile/schedules/AddScheduleButton.tsx b/packages/desktop-client/src/components/mobile/schedules/AddScheduleButton.tsx index c1961b45aa..eb9b574493 100644 --- a/packages/desktop-client/src/components/mobile/schedules/AddScheduleButton.tsx +++ b/packages/desktop-client/src/components/mobile/schedules/AddScheduleButton.tsx @@ -4,7 +4,7 @@ import { useTranslation } from 'react-i18next'; import { Button } from '@actual-app/components/button'; import { SvgAdd } from '@actual-app/components/icons/v1'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; +import { useNavigate } from '#hooks/useNavigate'; export function AddScheduleButton() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/mobile/schedules/MobileScheduleEditPage.tsx b/packages/desktop-client/src/components/mobile/schedules/MobileScheduleEditPage.tsx index 0acc89ea11..c6db987b8a 100644 --- a/packages/desktop-client/src/components/mobile/schedules/MobileScheduleEditPage.tsx +++ b/packages/desktop-client/src/components/mobile/schedules/MobileScheduleEditPage.tsx @@ -14,15 +14,15 @@ import * as monthUtils from 'loot-core/shared/months'; import { q } from 'loot-core/shared/query'; import type { RecurConfig, ScheduleEntity } from 'loot-core/types/models'; -import { MobileBackButton } from '@desktop-client/components/mobile/MobileBackButton'; -import { MobilePageHeader, Page } from '@desktop-client/components/Page'; -import { updateScheduleConditions } from '@desktop-client/components/schedules/schedule-edit-utils'; -import { ScheduleEditForm } from '@desktop-client/components/schedules/ScheduleEditForm'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { useScheduleEdit } from '@desktop-client/hooks/useScheduleEdit'; -import { useSelected } from '@desktop-client/hooks/useSelected'; -import { useUndo } from '@desktop-client/hooks/useUndo'; -import { aqlQuery } from '@desktop-client/queries/aqlQuery'; +import { MobileBackButton } from '#components/mobile/MobileBackButton'; +import { MobilePageHeader, Page } from '#components/Page'; +import { updateScheduleConditions } from '#components/schedules/schedule-edit-utils'; +import { ScheduleEditForm } from '#components/schedules/ScheduleEditForm'; +import { useNavigate } from '#hooks/useNavigate'; +import { useScheduleEdit } from '#hooks/useScheduleEdit'; +import { useSelected } from '#hooks/useSelected'; +import { useUndo } from '#hooks/useUndo'; +import { aqlQuery } from '#queries/aqlQuery'; export function MobileScheduleEditPage() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/mobile/schedules/MobileSchedulesPage.tsx b/packages/desktop-client/src/components/mobile/schedules/MobileSchedulesPage.tsx index d442c17fe8..85d1c45b14 100644 --- a/packages/desktop-client/src/components/mobile/schedules/MobileSchedulesPage.tsx +++ b/packages/desktop-client/src/components/mobile/schedules/MobileSchedulesPage.tsx @@ -16,17 +16,17 @@ import type { ScheduleEntity } from 'loot-core/types/models'; import { AddScheduleButton } from './AddScheduleButton'; import { SchedulesList } from './SchedulesList'; -import { Search } from '@desktop-client/components/common/Search'; -import { MobilePageHeader, Page } from '@desktop-client/components/Page'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; -import { useDateFormat } from '@desktop-client/hooks/useDateFormat'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { usePayees } from '@desktop-client/hooks/usePayees'; -import { useSchedules } from '@desktop-client/hooks/useSchedules'; -import { useUndo } from '@desktop-client/hooks/useUndo'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { Search } from '#components/common/Search'; +import { MobilePageHeader, Page } from '#components/Page'; +import { useAccounts } from '#hooks/useAccounts'; +import { useDateFormat } from '#hooks/useDateFormat'; +import { useFormat } from '#hooks/useFormat'; +import { useNavigate } from '#hooks/useNavigate'; +import { usePayees } from '#hooks/usePayees'; +import { useSchedules } from '#hooks/useSchedules'; +import { useUndo } from '#hooks/useUndo'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; export function MobileSchedulesPage() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/mobile/schedules/SchedulesList.tsx b/packages/desktop-client/src/components/mobile/schedules/SchedulesList.tsx index ac4db34afe..78bfaafe57 100644 --- a/packages/desktop-client/src/components/mobile/schedules/SchedulesList.tsx +++ b/packages/desktop-client/src/components/mobile/schedules/SchedulesList.tsx @@ -11,8 +11,8 @@ import type { ScheduleEntity } from 'loot-core/types/models'; import { SchedulesListItem } from './SchedulesListItem'; -import { ActionableGridListItem } from '@desktop-client/components/mobile/ActionableGridListItem'; -import { MOBILE_NAV_HEIGHT } from '@desktop-client/components/mobile/MobileNavTabs'; +import { ActionableGridListItem } from '#components/mobile/ActionableGridListItem'; +import { MOBILE_NAV_HEIGHT } from '#components/mobile/MobileNavTabs'; type CompletedSchedulesItem = { id: 'show-completed' }; type SchedulesListEntry = ScheduleEntity | CompletedSchedulesItem; diff --git a/packages/desktop-client/src/components/mobile/schedules/SchedulesListItem.tsx b/packages/desktop-client/src/components/mobile/schedules/SchedulesListItem.tsx index 176c755dc1..1e6b219a42 100644 --- a/packages/desktop-client/src/components/mobile/schedules/SchedulesListItem.tsx +++ b/packages/desktop-client/src/components/mobile/schedules/SchedulesListItem.tsx @@ -15,11 +15,11 @@ import { getScheduledAmount } from 'loot-core/shared/schedules'; import type { ScheduleEntity } from 'loot-core/types/models'; import type { WithRequired } from 'loot-core/types/util'; -import { ActionableGridListItem } from '@desktop-client/components/mobile/ActionableGridListItem'; -import { StatusBadge } from '@desktop-client/components/schedules/StatusBadge'; -import { DisplayId } from '@desktop-client/components/util/DisplayId'; -import { useDateFormat } from '@desktop-client/hooks/useDateFormat'; -import { useFormat } from '@desktop-client/hooks/useFormat'; +import { ActionableGridListItem } from '#components/mobile/ActionableGridListItem'; +import { StatusBadge } from '#components/schedules/StatusBadge'; +import { DisplayId } from '#components/util/DisplayId'; +import { useDateFormat } from '#hooks/useDateFormat'; +import { useFormat } from '#hooks/useFormat'; type SchedulesListItemProps = { onDelete: () => void; diff --git a/packages/desktop-client/src/components/mobile/transactions/AddTransactionButton.tsx b/packages/desktop-client/src/components/mobile/transactions/AddTransactionButton.tsx index cc6bfc01d7..9b56af8cd3 100644 --- a/packages/desktop-client/src/components/mobile/transactions/AddTransactionButton.tsx +++ b/packages/desktop-client/src/components/mobile/transactions/AddTransactionButton.tsx @@ -4,7 +4,7 @@ import { useTranslation } from 'react-i18next'; import { Button } from '@actual-app/components/button'; import { SvgAdd } from '@actual-app/components/icons/v1'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; +import { useNavigate } from '#hooks/useNavigate'; type AddTransactionButtonProps = { to?: string; diff --git a/packages/desktop-client/src/components/mobile/transactions/FocusableAmountInput.tsx b/packages/desktop-client/src/components/mobile/transactions/FocusableAmountInput.tsx index 266621bb40..d4c9f9dc31 100644 --- a/packages/desktop-client/src/components/mobile/transactions/FocusableAmountInput.tsx +++ b/packages/desktop-client/src/components/mobile/transactions/FocusableAmountInput.tsx @@ -19,9 +19,9 @@ import { reapplyThousandSeparators, } from 'loot-core/shared/util'; -import { makeAmountFullStyle } from '@desktop-client/components/budget/util'; -import { useMergedRefs } from '@desktop-client/hooks/useMergedRefs'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; +import { makeAmountFullStyle } from '#components/budget/util'; +import { useMergedRefs } from '#hooks/useMergedRefs'; +import { useSyncedPref } from '#hooks/useSyncedPref'; type AmountInputProps = { value: number; diff --git a/packages/desktop-client/src/components/mobile/transactions/TransactionEdit.tsx b/packages/desktop-client/src/components/mobile/transactions/TransactionEdit.tsx index 52c72e9e1d..5bbbb6838b 100644 --- a/packages/desktop-client/src/components/mobile/transactions/TransactionEdit.tsx +++ b/packages/desktop-client/src/components/mobile/transactions/TransactionEdit.tsx @@ -66,38 +66,38 @@ import type { import { FocusableAmountInput } from './FocusableAmountInput'; -import { MobileBackButton } from '@desktop-client/components/mobile/MobileBackButton'; +import { MobileBackButton } from '#components/mobile/MobileBackButton'; import { FieldLabel, InputField, TapField, ToggleField, -} from '@desktop-client/components/mobile/MobileForms'; -import { getPrettyPayee } from '@desktop-client/components/mobile/utils'; -import { MobilePageHeader, Page } from '@desktop-client/components/Page'; -import { createSingleTimeScheduleFromTransaction } from '@desktop-client/components/transactions/TransactionList'; -import { AmountInput } from '@desktop-client/components/util/AmountInput'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; -import { useCategories } from '@desktop-client/hooks/useCategories'; -import { useDateFormat } from '@desktop-client/hooks/useDateFormat'; -import { useInitialMount } from '@desktop-client/hooks/useInitialMount'; -import { useLocalPref } from '@desktop-client/hooks/useLocalPref'; -import { useLocationPermission } from '@desktop-client/hooks/useLocationPermission'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { useNearbyPayees } from '@desktop-client/hooks/useNearbyPayees'; -import { usePayees } from '@desktop-client/hooks/usePayees'; +} from '#components/mobile/MobileForms'; +import { getPrettyPayee } from '#components/mobile/utils'; +import { MobilePageHeader, Page } from '#components/Page'; +import { createSingleTimeScheduleFromTransaction } from '#components/transactions/TransactionList'; +import { AmountInput } from '#components/util/AmountInput'; +import { useAccounts } from '#hooks/useAccounts'; +import { useCategories } from '#hooks/useCategories'; +import { useDateFormat } from '#hooks/useDateFormat'; +import { useInitialMount } from '#hooks/useInitialMount'; +import { useLocalPref } from '#hooks/useLocalPref'; +import { useLocationPermission } from '#hooks/useLocationPermission'; +import { useNavigate } from '#hooks/useNavigate'; +import { useNearbyPayees } from '#hooks/useNearbyPayees'; +import { usePayees } from '#hooks/usePayees'; import { SingleActiveEditFormProvider, useSingleActiveEditForm, -} from '@desktop-client/hooks/useSingleActiveEditForm'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useSavePayeeLocationMutation } from '@desktop-client/payees'; -import { locationService } from '@desktop-client/payees/location'; -import { aqlQuery } from '@desktop-client/queries/aqlQuery'; -import { useDispatch, useSelector } from '@desktop-client/redux'; -import { setLastTransaction } from '@desktop-client/transactions/transactionsSlice'; +} from '#hooks/useSingleActiveEditForm'; +import { useSyncedPref } from '#hooks/useSyncedPref'; +import { pushModal } from '#modals/modalsSlice'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useSavePayeeLocationMutation } from '#payees'; +import { locationService } from '#payees/location'; +import { aqlQuery } from '#queries/aqlQuery'; +import { useDispatch, useSelector } from '#redux'; +import { setLastTransaction } from '#transactions/transactionsSlice'; function getFieldName(transactionId: TransactionEntity['id'], field: string) { return `${field}-${transactionId}`; diff --git a/packages/desktop-client/src/components/mobile/transactions/TransactionList.tsx b/packages/desktop-client/src/components/mobile/transactions/TransactionList.tsx index e1f8d32c05..3997b11dce 100644 --- a/packages/desktop-client/src/components/mobile/transactions/TransactionList.tsx +++ b/packages/desktop-client/src/components/mobile/transactions/TransactionList.tsx @@ -38,21 +38,18 @@ import type { CategoryEntity, TransactionEntity } from 'loot-core/types/models'; import { ROW_HEIGHT, TransactionListItem } from './TransactionListItem'; -import { FloatingActionBar } from '@desktop-client/components/mobile/FloatingActionBar'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; -import { useCategoriesById } from '@desktop-client/hooks/useCategories'; -import { useLocale } from '@desktop-client/hooks/useLocale'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { usePayees } from '@desktop-client/hooks/usePayees'; -import { useScrollListener } from '@desktop-client/hooks/useScrollListener'; -import { - useSelectedDispatch, - useSelectedItems, -} from '@desktop-client/hooks/useSelected'; -import { useTransactionBatchActions } from '@desktop-client/hooks/useTransactionBatchActions'; -import { useUndo } from '@desktop-client/hooks/useUndo'; -import { setNotificationInset } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { FloatingActionBar } from '#components/mobile/FloatingActionBar'; +import { useAccounts } from '#hooks/useAccounts'; +import { useCategoriesById } from '#hooks/useCategories'; +import { useLocale } from '#hooks/useLocale'; +import { useNavigate } from '#hooks/useNavigate'; +import { usePayees } from '#hooks/usePayees'; +import { useScrollListener } from '#hooks/useScrollListener'; +import { useSelectedDispatch, useSelectedItems } from '#hooks/useSelected'; +import { useTransactionBatchActions } from '#hooks/useTransactionBatchActions'; +import { useUndo } from '#hooks/useUndo'; +import { setNotificationInset } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; const NOTIFICATION_BOTTOM_INSET = 75; diff --git a/packages/desktop-client/src/components/mobile/transactions/TransactionListItem.tsx b/packages/desktop-client/src/components/mobile/transactions/TransactionListItem.tsx index 7b83c9db38..4d4e5cefd0 100644 --- a/packages/desktop-client/src/components/mobile/transactions/TransactionListItem.tsx +++ b/packages/desktop-client/src/components/mobile/transactions/TransactionListItem.tsx @@ -34,14 +34,14 @@ import type { AccountEntity, TransactionEntity } from 'loot-core/types/models'; import { lookupName, Status } from './TransactionEdit'; -import { makeAmountFullStyle } from '@desktop-client/components/budget/util'; -import { useAccount } from '@desktop-client/hooks/useAccount'; -import { useCachedSchedules } from '@desktop-client/hooks/useCachedSchedules'; -import { useCategories } from '@desktop-client/hooks/useCategories'; -import { useDisplayPayee } from '@desktop-client/hooks/useDisplayPayee'; -import { usePayee } from '@desktop-client/hooks/usePayee'; -import { NotesTagFormatter } from '@desktop-client/notes/NotesTagFormatter'; -import { useSelector } from '@desktop-client/redux'; +import { makeAmountFullStyle } from '#components/budget/util'; +import { useAccount } from '#hooks/useAccount'; +import { useCachedSchedules } from '#hooks/useCachedSchedules'; +import { useCategories } from '#hooks/useCategories'; +import { useDisplayPayee } from '#hooks/useDisplayPayee'; +import { usePayee } from '#hooks/usePayee'; +import { NotesTagFormatter } from '#notes/NotesTagFormatter'; +import { useSelector } from '#redux'; export const ROW_HEIGHT = 60; diff --git a/packages/desktop-client/src/components/mobile/transactions/TransactionListWithBalances.tsx b/packages/desktop-client/src/components/mobile/transactions/TransactionListWithBalances.tsx index c849995f1b..5058bee86e 100644 --- a/packages/desktop-client/src/components/mobile/transactions/TransactionListWithBalances.tsx +++ b/packages/desktop-client/src/components/mobile/transactions/TransactionListWithBalances.tsx @@ -12,23 +12,13 @@ import type { TransactionEntity } from 'loot-core/types/models'; import { TransactionList } from './TransactionList'; -import { Search } from '@desktop-client/components/common/Search'; -import { PullToRefresh } from '@desktop-client/components/mobile/PullToRefresh'; -import { - CellValue, - CellValueText, -} from '@desktop-client/components/spreadsheet/CellValue'; -import { DisplayPayeeProvider } from '@desktop-client/hooks/useDisplayPayee'; -import { - SelectedProvider, - useSelected, -} from '@desktop-client/hooks/useSelected'; -import { useSheetValue } from '@desktop-client/hooks/useSheetValue'; -import type { - Binding, - SheetFields, - SheetNames, -} from '@desktop-client/spreadsheet'; +import { Search } from '#components/common/Search'; +import { PullToRefresh } from '#components/mobile/PullToRefresh'; +import { CellValue, CellValueText } from '#components/spreadsheet/CellValue'; +import { DisplayPayeeProvider } from '#hooks/useDisplayPayee'; +import { SelectedProvider, useSelected } from '#hooks/useSelected'; +import { useSheetValue } from '#hooks/useSheetValue'; +import type { Binding, SheetFields, SheetNames } from '#spreadsheet'; type TransactionSearchInputProps = { placeholder: string; diff --git a/packages/desktop-client/src/components/modals/AccountAutocompleteModal.tsx b/packages/desktop-client/src/components/modals/AccountAutocompleteModal.tsx index 8700434fdb..9afccb643c 100644 --- a/packages/desktop-client/src/components/modals/AccountAutocompleteModal.tsx +++ b/packages/desktop-client/src/components/modals/AccountAutocompleteModal.tsx @@ -5,15 +5,15 @@ import { useResponsive } from '@actual-app/components/hooks/useResponsive'; import { theme } from '@actual-app/components/theme'; import { View } from '@actual-app/components/view'; -import { AccountAutocomplete } from '@desktop-client/components/autocomplete/AccountAutocomplete'; +import { AccountAutocomplete } from '#components/autocomplete/AccountAutocomplete'; import { Modal, ModalCloseButton, ModalHeader, ModalTitle, -} from '@desktop-client/components/common/Modal'; -import { SectionLabel } from '@desktop-client/components/forms'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; +} from '#components/common/Modal'; +import { SectionLabel } from '#components/forms'; +import type { Modal as ModalType } from '#modals/modalsSlice'; type AccountAutocompleteModalProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/AccountMenuModal.tsx b/packages/desktop-client/src/components/modals/AccountMenuModal.tsx index 4540160085..0f239804ee 100644 --- a/packages/desktop-client/src/components/modals/AccountMenuModal.tsx +++ b/packages/desktop-client/src/components/modals/AccountMenuModal.tsx @@ -22,14 +22,14 @@ import { ModalCloseButton, ModalHeader, ModalTitle, -} from '@desktop-client/components/common/Modal'; -import { Notes } from '@desktop-client/components/Notes'; -import { validateAccountName } from '@desktop-client/components/util/accountValidation'; -import { useAccount } from '@desktop-client/hooks/useAccount'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; -import { useNotes } from '@desktop-client/hooks/useNotes'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; +} from '#components/common/Modal'; +import { Notes } from '#components/Notes'; +import { validateAccountName } from '#components/util/accountValidation'; +import { useAccount } from '#hooks/useAccount'; +import { useAccounts } from '#hooks/useAccounts'; +import { useNotes } from '#hooks/useNotes'; +import { useSyncedPref } from '#hooks/useSyncedPref'; +import type { Modal as ModalType } from '#modals/modalsSlice'; type AccountMenuModalProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/BudgetAutomationsModal.tsx b/packages/desktop-client/src/components/modals/BudgetAutomationsModal.tsx index fed14a7a7b..d2eeee8361 100644 --- a/packages/desktop-client/src/components/modals/BudgetAutomationsModal.tsx +++ b/packages/desktop-client/src/components/modals/BudgetAutomationsModal.tsx @@ -18,23 +18,19 @@ import type { } from 'loot-core/types/models'; import type { Template } from 'loot-core/types/models/templates'; -import { Warning } from '@desktop-client/components/alerts'; -import { BudgetAutomation } from '@desktop-client/components/budget/goals/BudgetAutomation'; -import type { DisplayTemplateType } from '@desktop-client/components/budget/goals/constants'; -import { DEFAULT_PRIORITY } from '@desktop-client/components/budget/goals/reducer'; -import { useBudgetAutomationCategories } from '@desktop-client/components/budget/goals/useBudgetAutomationCategories'; -import { Link } from '@desktop-client/components/common/Link'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { useBudgetAutomations } from '@desktop-client/hooks/useBudgetAutomations'; -import { useCategory } from '@desktop-client/hooks/useCategory'; -import { useNotes } from '@desktop-client/hooks/useNotes'; -import { useSchedules } from '@desktop-client/hooks/useSchedules'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { Warning } from '#components/alerts'; +import { BudgetAutomation } from '#components/budget/goals/BudgetAutomation'; +import type { DisplayTemplateType } from '#components/budget/goals/constants'; +import { DEFAULT_PRIORITY } from '#components/budget/goals/reducer'; +import { useBudgetAutomationCategories } from '#components/budget/goals/useBudgetAutomationCategories'; +import { Link } from '#components/common/Link'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { useBudgetAutomations } from '#hooks/useBudgetAutomations'; +import { useCategory } from '#hooks/useCategory'; +import { useNotes } from '#hooks/useNotes'; +import { useSchedules } from '#hooks/useSchedules'; +import { pushModal } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; type AutomationEntry = { id: string; diff --git a/packages/desktop-client/src/components/modals/BudgetPageMenuModal.tsx b/packages/desktop-client/src/components/modals/BudgetPageMenuModal.tsx index a9685bf823..bb61419ecf 100644 --- a/packages/desktop-client/src/components/modals/BudgetPageMenuModal.tsx +++ b/packages/desktop-client/src/components/modals/BudgetPageMenuModal.tsx @@ -6,13 +6,9 @@ import { Menu } from '@actual-app/components/menu'; import { styles } from '@actual-app/components/styles'; import { theme } from '@actual-app/components/theme'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { useLocalPref } from '@desktop-client/hooks/useLocalPref'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { useLocalPref } from '#hooks/useLocalPref'; +import type { Modal as ModalType } from '#modals/modalsSlice'; type BudgetPageMenuModalProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/CategoryAutocompleteModal.tsx b/packages/desktop-client/src/components/modals/CategoryAutocompleteModal.tsx index 43327fc33d..31d02a8559 100644 --- a/packages/desktop-client/src/components/modals/CategoryAutocompleteModal.tsx +++ b/packages/desktop-client/src/components/modals/CategoryAutocompleteModal.tsx @@ -7,16 +7,16 @@ import { View } from '@actual-app/components/view'; import * as monthUtils from 'loot-core/shared/months'; -import { CategoryAutocomplete } from '@desktop-client/components/autocomplete/CategoryAutocomplete'; +import { CategoryAutocomplete } from '#components/autocomplete/CategoryAutocomplete'; import { Modal, ModalCloseButton, ModalHeader, ModalTitle, -} from '@desktop-client/components/common/Modal'; -import { SectionLabel } from '@desktop-client/components/forms'; -import { SheetNameProvider } from '@desktop-client/hooks/useSheetName'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; +} from '#components/common/Modal'; +import { SectionLabel } from '#components/forms'; +import { SheetNameProvider } from '#hooks/useSheetName'; +import type { Modal as ModalType } from '#modals/modalsSlice'; type CategoryAutocompleteModalProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/CategoryGroupAutocompleteModal.tsx b/packages/desktop-client/src/components/modals/CategoryGroupAutocompleteModal.tsx index f6bc72bd78..5a792ff2c1 100644 --- a/packages/desktop-client/src/components/modals/CategoryGroupAutocompleteModal.tsx +++ b/packages/desktop-client/src/components/modals/CategoryGroupAutocompleteModal.tsx @@ -7,16 +7,16 @@ import { View } from '@actual-app/components/view'; import * as monthUtils from 'loot-core/shared/months'; -import { CategoryGroupAutocomplete } from '@desktop-client/components/autocomplete/CategoryGroupAutocomplete'; +import { CategoryGroupAutocomplete } from '#components/autocomplete/CategoryGroupAutocomplete'; import { Modal, ModalCloseButton, ModalHeader, ModalTitle, -} from '@desktop-client/components/common/Modal'; -import { SectionLabel } from '@desktop-client/components/forms'; -import { SheetNameProvider } from '@desktop-client/hooks/useSheetName'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; +} from '#components/common/Modal'; +import { SectionLabel } from '#components/forms'; +import { SheetNameProvider } from '#hooks/useSheetName'; +import type { Modal as ModalType } from '#modals/modalsSlice'; type CategoryGroupAutocompleteModalProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/CategoryGroupMenuModal.tsx b/packages/desktop-client/src/components/modals/CategoryGroupMenuModal.tsx index 718e956fa6..effc23d736 100644 --- a/packages/desktop-client/src/components/modals/CategoryGroupMenuModal.tsx +++ b/packages/desktop-client/src/components/modals/CategoryGroupMenuModal.tsx @@ -29,14 +29,14 @@ import { ModalCloseButton, ModalHeader, ModalTitle, -} from '@desktop-client/components/common/Modal'; -import { CategoryGroupActionMenu } from '@desktop-client/components/mobile/budget/CategoryGroupActionMenu'; -import { Notes } from '@desktop-client/components/Notes'; -import { useCategories } from '@desktop-client/hooks/useCategories'; -import { useFeatureFlag } from '@desktop-client/hooks/useFeatureFlag'; -import { useNotes } from '@desktop-client/hooks/useNotes'; -import { useUndo } from '@desktop-client/hooks/useUndo'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; +} from '#components/common/Modal'; +import { CategoryGroupActionMenu } from '#components/mobile/budget/CategoryGroupActionMenu'; +import { Notes } from '#components/Notes'; +import { useCategories } from '#hooks/useCategories'; +import { useFeatureFlag } from '#hooks/useFeatureFlag'; +import { useNotes } from '#hooks/useNotes'; +import { useUndo } from '#hooks/useUndo'; +import type { Modal as ModalType } from '#modals/modalsSlice'; type CategoryGroupMenuModalProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/CategoryMenuModal.tsx b/packages/desktop-client/src/components/modals/CategoryMenuModal.tsx index d255f3efb3..5c401892bc 100644 --- a/packages/desktop-client/src/components/modals/CategoryMenuModal.tsx +++ b/packages/desktop-client/src/components/modals/CategoryMenuModal.tsx @@ -24,12 +24,12 @@ import { ModalCloseButton, ModalHeader, ModalTitle, -} from '@desktop-client/components/common/Modal'; -import { Notes } from '@desktop-client/components/Notes'; -import { useCategory } from '@desktop-client/hooks/useCategory'; -import { useCategoryGroup } from '@desktop-client/hooks/useCategoryGroup'; -import { useNotes } from '@desktop-client/hooks/useNotes'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; +} from '#components/common/Modal'; +import { Notes } from '#components/Notes'; +import { useCategory } from '#hooks/useCategory'; +import { useCategoryGroup } from '#hooks/useCategoryGroup'; +import { useNotes } from '#hooks/useNotes'; +import type { Modal as ModalType } from '#modals/modalsSlice'; type CategoryMenuModalProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/CloseAccountModal.tsx b/packages/desktop-client/src/components/modals/CloseAccountModal.tsx index 3bfeebb92f..1e610782a3 100644 --- a/packages/desktop-client/src/components/modals/CloseAccountModal.tsx +++ b/packages/desktop-client/src/components/modals/CloseAccountModal.tsx @@ -17,20 +17,16 @@ import { integerToCurrency } from 'loot-core/shared/util'; import type { AccountEntity } from 'loot-core/types/models'; import type { TransObjectLiteral } from 'loot-core/types/util'; -import { useCloseAccountMutation } from '@desktop-client/accounts'; -import { AccountAutocomplete } from '@desktop-client/components/autocomplete/AccountAutocomplete'; -import { CategoryAutocomplete } from '@desktop-client/components/autocomplete/CategoryAutocomplete'; -import { Link } from '@desktop-client/components/common/Link'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; -import { useCategories } from '@desktop-client/hooks/useCategories'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { useCloseAccountMutation } from '#accounts'; +import { AccountAutocomplete } from '#components/autocomplete/AccountAutocomplete'; +import { CategoryAutocomplete } from '#components/autocomplete/CategoryAutocomplete'; +import { Link } from '#components/common/Link'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { useAccounts } from '#hooks/useAccounts'; +import { useCategories } from '#hooks/useCategories'; +import { pushModal } from '#modals/modalsSlice'; +import type { Modal as ModalType } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; function needsCategory( account: AccountEntity, diff --git a/packages/desktop-client/src/components/modals/ConfirmCategoryDeleteModal.tsx b/packages/desktop-client/src/components/modals/ConfirmCategoryDeleteModal.tsx index edeb2d2ab6..fde275b189 100644 --- a/packages/desktop-client/src/components/modals/ConfirmCategoryDeleteModal.tsx +++ b/packages/desktop-client/src/components/modals/ConfirmCategoryDeleteModal.tsx @@ -10,14 +10,10 @@ import { View } from '@actual-app/components/view'; import type { TransObjectLiteral } from 'loot-core/types/util'; -import { CategoryAutocomplete } from '@desktop-client/components/autocomplete/CategoryAutocomplete'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { useCategories } from '@desktop-client/hooks/useCategories'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; +import { CategoryAutocomplete } from '#components/autocomplete/CategoryAutocomplete'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { useCategories } from '#hooks/useCategories'; +import type { Modal as ModalType } from '#modals/modalsSlice'; type ConfirmCategoryDeleteModalProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/ConfirmDeleteModal.tsx b/packages/desktop-client/src/components/modals/ConfirmDeleteModal.tsx index 41b0355d00..91aa73d610 100644 --- a/packages/desktop-client/src/components/modals/ConfirmDeleteModal.tsx +++ b/packages/desktop-client/src/components/modals/ConfirmDeleteModal.tsx @@ -8,12 +8,8 @@ import { Paragraph } from '@actual-app/components/paragraph'; import { styles } from '@actual-app/components/styles'; import { View } from '@actual-app/components/view'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import type { Modal as ModalType } from '#modals/modalsSlice'; type ConfirmDeleteModalProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/ConfirmTransactionEditModal.tsx b/packages/desktop-client/src/components/modals/ConfirmTransactionEditModal.tsx index a78b1141d1..2b55af6cb0 100644 --- a/packages/desktop-client/src/components/modals/ConfirmTransactionEditModal.tsx +++ b/packages/desktop-client/src/components/modals/ConfirmTransactionEditModal.tsx @@ -9,12 +9,8 @@ import { InitialFocus } from '@actual-app/components/initial-focus'; import { styles } from '@actual-app/components/styles'; import { View } from '@actual-app/components/view'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import type { Modal as ModalType } from '#modals/modalsSlice'; type ConfirmTransactionEditModalProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/ConfirmUnlinkAccountModal.tsx b/packages/desktop-client/src/components/modals/ConfirmUnlinkAccountModal.tsx index bb90da1d53..32ecdb5b3c 100644 --- a/packages/desktop-client/src/components/modals/ConfirmUnlinkAccountModal.tsx +++ b/packages/desktop-client/src/components/modals/ConfirmUnlinkAccountModal.tsx @@ -6,12 +6,8 @@ import { InitialFocus } from '@actual-app/components/initial-focus'; import { Paragraph } from '@actual-app/components/paragraph'; import { View } from '@actual-app/components/view'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import type { Modal as ModalType } from '#modals/modalsSlice'; type ConfirmUnlinkAccountModalProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/ConvertToScheduleModal.tsx b/packages/desktop-client/src/components/modals/ConvertToScheduleModal.tsx index 6c8b5e9ba4..110f757953 100644 --- a/packages/desktop-client/src/components/modals/ConvertToScheduleModal.tsx +++ b/packages/desktop-client/src/components/modals/ConvertToScheduleModal.tsx @@ -9,12 +9,8 @@ import { styles } from '@actual-app/components/styles'; import { theme } from '@actual-app/components/theme'; import { View } from '@actual-app/components/view'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import type { Modal as ModalType } from '#modals/modalsSlice'; type ConvertToScheduleModalProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/CopyWidgetToDashboardModal.tsx b/packages/desktop-client/src/components/modals/CopyWidgetToDashboardModal.tsx index 0135b5c08c..292162fedf 100644 --- a/packages/desktop-client/src/components/modals/CopyWidgetToDashboardModal.tsx +++ b/packages/desktop-client/src/components/modals/CopyWidgetToDashboardModal.tsx @@ -6,13 +6,9 @@ import { Button } from '@actual-app/components/button'; import { Menu } from '@actual-app/components/menu'; import { View } from '@actual-app/components/view'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { useDashboardPages } from '@desktop-client/hooks/useDashboardPages'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { useDashboardPages } from '#hooks/useDashboardPages'; +import type { Modal as ModalType } from '#modals/modalsSlice'; type CopyWidgetToDashboardModalProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/CoverModal.tsx b/packages/desktop-client/src/components/modals/CoverModal.tsx index 7d3300256e..921bf700d2 100644 --- a/packages/desktop-client/src/components/modals/CoverModal.tsx +++ b/packages/desktop-client/src/components/modals/CoverModal.tsx @@ -11,23 +11,16 @@ import type { IntegerAmount } from 'loot-core/shared/util'; import { addToBeBudgetedGroup, removeCategoriesFromGroups, -} from '@desktop-client/components/budget/util'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { - FieldLabel, - TapField, -} from '@desktop-client/components/mobile/MobileForms'; -import { AmountInput } from '@desktop-client/components/util/AmountInput'; -import { useCategories } from '@desktop-client/hooks/useCategories'; -import { useInitialMount } from '@desktop-client/hooks/useInitialMount'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; +} from '#components/budget/util'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { FieldLabel, TapField } from '#components/mobile/MobileForms'; +import { AmountInput } from '#components/util/AmountInput'; +import { useCategories } from '#hooks/useCategories'; +import { useInitialMount } from '#hooks/useInitialMount'; +import { useSyncedPref } from '#hooks/useSyncedPref'; +import { pushModal } from '#modals/modalsSlice'; +import type { Modal as ModalType } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; type CoverModalProps = Extract['options']; diff --git a/packages/desktop-client/src/components/modals/CreateAccountModal.tsx b/packages/desktop-client/src/components/modals/CreateAccountModal.tsx index aeef079729..0be7706873 100644 --- a/packages/desktop-client/src/components/modals/CreateAccountModal.tsx +++ b/packages/desktop-client/src/components/modals/CreateAccountModal.tsx @@ -14,25 +14,21 @@ import { View } from '@actual-app/components/view'; import { send } from 'loot-core/platform/client/connection'; -import { useAuth } from '@desktop-client/auth/AuthProvider'; -import { Permissions } from '@desktop-client/auth/types'; -import { Warning } from '@desktop-client/components/alerts'; -import { Link } from '@desktop-client/components/common/Link'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { useMultiuserEnabled } from '@desktop-client/components/ServerContext'; -import { authorizeBank } from '@desktop-client/gocardless'; -import { useGoCardlessStatus } from '@desktop-client/hooks/useGoCardlessStatus'; -import { usePluggyAiStatus } from '@desktop-client/hooks/usePluggyAiStatus'; -import { useSimpleFinStatus } from '@desktop-client/hooks/useSimpleFinStatus'; -import { useSyncServerStatus } from '@desktop-client/hooks/useSyncServerStatus'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { useAuth } from '#auth/AuthProvider'; +import { Permissions } from '#auth/types'; +import { Warning } from '#components/alerts'; +import { Link } from '#components/common/Link'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { useMultiuserEnabled } from '#components/ServerContext'; +import { authorizeBank } from '#gocardless'; +import { useGoCardlessStatus } from '#hooks/useGoCardlessStatus'; +import { usePluggyAiStatus } from '#hooks/usePluggyAiStatus'; +import { useSimpleFinStatus } from '#hooks/useSimpleFinStatus'; +import { useSyncServerStatus } from '#hooks/useSyncServerStatus'; +import { pushModal } from '#modals/modalsSlice'; +import type { Modal as ModalType } from '#modals/modalsSlice'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; type CreateAccountModalProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/CreateEncryptionKeyModal.tsx b/packages/desktop-client/src/components/modals/CreateEncryptionKeyModal.tsx index 10d315595a..a55b155579 100644 --- a/packages/desktop-client/src/components/modals/CreateEncryptionKeyModal.tsx +++ b/packages/desktop-client/src/components/modals/CreateEncryptionKeyModal.tsx @@ -17,18 +17,18 @@ import { css } from '@emotion/css'; import { send } from 'loot-core/platform/client/connection'; import { getCreateKeyError } from 'loot-core/shared/errors'; -import { sync } from '@desktop-client/app/appSlice'; -import { loadAllFiles } from '@desktop-client/budgetfiles/budgetfilesSlice'; -import { Link } from '@desktop-client/components/common/Link'; +import { sync } from '#app/appSlice'; +import { loadAllFiles } from '#budgetfiles/budgetfilesSlice'; +import { Link } from '#components/common/Link'; import { Modal, ModalButtons, ModalCloseButton, ModalHeader, -} from '@desktop-client/components/common/Modal'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; -import { loadGlobalPrefs } from '@desktop-client/prefs/prefsSlice'; -import { useDispatch } from '@desktop-client/redux'; +} from '#components/common/Modal'; +import type { Modal as ModalType } from '#modals/modalsSlice'; +import { loadGlobalPrefs } from '#prefs/prefsSlice'; +import { useDispatch } from '#redux'; type CreateEncryptionKeyModalProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/CreateLocalAccountModal.tsx b/packages/desktop-client/src/components/modals/CreateLocalAccountModal.tsx index cfab6d88d7..bdcb3eb25b 100644 --- a/packages/desktop-client/src/components/modals/CreateLocalAccountModal.tsx +++ b/packages/desktop-client/src/components/modals/CreateLocalAccountModal.tsx @@ -15,21 +15,21 @@ import { View } from '@actual-app/components/view'; import { toRelaxedNumber } from 'loot-core/shared/util'; -import { useCreateAccountMutation } from '@desktop-client/accounts'; -import { Link } from '@desktop-client/components/common/Link'; +import { useCreateAccountMutation } from '#accounts'; +import { Link } from '#components/common/Link'; import { Modal, ModalButtons, ModalCloseButton, ModalHeader, ModalTitle, -} from '@desktop-client/components/common/Modal'; -import { Checkbox } from '@desktop-client/components/forms'; -import { validateAccountName } from '@desktop-client/components/util/accountValidation'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { closeModal } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; +} from '#components/common/Modal'; +import { Checkbox } from '#components/forms'; +import { validateAccountName } from '#components/util/accountValidation'; +import { useAccounts } from '#hooks/useAccounts'; +import { useNavigate } from '#hooks/useNavigate'; +import { closeModal } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; export function CreateLocalAccountModal() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/modals/EditAccess.tsx b/packages/desktop-client/src/components/modals/EditAccess.tsx index 06dada014b..3f2388a56c 100644 --- a/packages/desktop-client/src/components/modals/EditAccess.tsx +++ b/packages/desktop-client/src/components/modals/EditAccess.tsx @@ -12,17 +12,13 @@ import { View } from '@actual-app/components/view'; import { send } from 'loot-core/platform/client/connection'; import { getUserAccessErrors } from 'loot-core/shared/errors'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { FormField, FormLabel } from '@desktop-client/components/forms'; -import { popModal } from '@desktop-client/modals/modalsSlice'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; -import { signOut } from '@desktop-client/users/usersSlice'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { FormField, FormLabel } from '#components/forms'; +import { popModal } from '#modals/modalsSlice'; +import type { Modal as ModalType } from '#modals/modalsSlice'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; +import { signOut } from '#users/usersSlice'; type EditUserAccessProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/EditFieldModal.tsx b/packages/desktop-client/src/components/modals/EditFieldModal.tsx index fa788105da..b6643f006b 100644 --- a/packages/desktop-client/src/components/modals/EditFieldModal.tsx +++ b/packages/desktop-client/src/components/modals/EditFieldModal.tsx @@ -12,16 +12,12 @@ import { format as formatDate, parse as parseDate, parseISO } from 'date-fns'; import { currentDay, dayFromDate } from 'loot-core/shared/months'; import { amountToInteger, currencyToInteger } from 'loot-core/shared/util'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { SectionLabel } from '@desktop-client/components/forms'; -import { LabeledCheckbox } from '@desktop-client/components/forms/LabeledCheckbox'; -import { DateSelect } from '@desktop-client/components/select/DateSelect'; -import { useDateFormat } from '@desktop-client/hooks/useDateFormat'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { SectionLabel } from '#components/forms'; +import { LabeledCheckbox } from '#components/forms/LabeledCheckbox'; +import { DateSelect } from '#components/select/DateSelect'; +import { useDateFormat } from '#hooks/useDateFormat'; +import type { Modal as ModalType } from '#modals/modalsSlice'; const itemStyle: CSSProperties = { fontSize: 17, diff --git a/packages/desktop-client/src/components/modals/EditRuleModal.tsx b/packages/desktop-client/src/components/modals/EditRuleModal.tsx index e8faaae850..4b90a97162 100644 --- a/packages/desktop-client/src/components/modals/EditRuleModal.tsx +++ b/packages/desktop-client/src/components/modals/EditRuleModal.tsx @@ -5,12 +5,8 @@ import { theme } from '@actual-app/components/theme'; import type { NewRuleEntity, RuleEntity } from 'loot-core/types/models'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { RuleEditor } from '@desktop-client/components/rules/RuleEditor'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { RuleEditor } from '#components/rules/RuleEditor'; type EditRuleModalProps = { rule: RuleEntity | NewRuleEntity; diff --git a/packages/desktop-client/src/components/modals/EditUser.tsx b/packages/desktop-client/src/components/modals/EditUser.tsx index db59f62b15..80fb518f58 100644 --- a/packages/desktop-client/src/components/modals/EditUser.tsx +++ b/packages/desktop-client/src/components/modals/EditUser.tsx @@ -14,21 +14,13 @@ import { send } from 'loot-core/platform/client/connection'; import { PossibleRoles } from 'loot-core/shared/user'; import type { NewUserEntity, UserEntity } from 'loot-core/types/models'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { - Checkbox, - FormField, - FormLabel, -} from '@desktop-client/components/forms'; -import { popModal } from '@desktop-client/modals/modalsSlice'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; -import { signOut } from '@desktop-client/users/usersSlice'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { Checkbox, FormField, FormLabel } from '#components/forms'; +import { popModal } from '#modals/modalsSlice'; +import type { Modal as ModalType } from '#modals/modalsSlice'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; +import { signOut } from '#users/usersSlice'; type User = UserEntity; type NewUser = NewUserEntity; diff --git a/packages/desktop-client/src/components/modals/EnvelopeBalanceMenuModal.tsx b/packages/desktop-client/src/components/modals/EnvelopeBalanceMenuModal.tsx index c195d17844..7b8427ec87 100644 --- a/packages/desktop-client/src/components/modals/EnvelopeBalanceMenuModal.tsx +++ b/packages/desktop-client/src/components/modals/EnvelopeBalanceMenuModal.tsx @@ -10,18 +10,18 @@ import { View } from '@actual-app/components/view'; import { BalanceWithCarryover, CarryoverIndicator, -} from '@desktop-client/components/budget/BalanceWithCarryover'; -import { BalanceMenu } from '@desktop-client/components/budget/envelope/BalanceMenu'; +} from '#components/budget/BalanceWithCarryover'; +import { BalanceMenu } from '#components/budget/envelope/BalanceMenu'; import { Modal, ModalCloseButton, ModalHeader, ModalTitle, -} from '@desktop-client/components/common/Modal'; -import { CellValueText } from '@desktop-client/components/spreadsheet/CellValue'; -import { useCategory } from '@desktop-client/hooks/useCategory'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; -import { envelopeBudget } from '@desktop-client/spreadsheet/bindings'; +} from '#components/common/Modal'; +import { CellValueText } from '#components/spreadsheet/CellValue'; +import { useCategory } from '#hooks/useCategory'; +import type { Modal as ModalType } from '#modals/modalsSlice'; +import { envelopeBudget } from '#spreadsheet/bindings'; type EnvelopeBalanceMenuModalProps = Omit< Extract['options'], diff --git a/packages/desktop-client/src/components/modals/EnvelopeBudgetMenuModal.tsx b/packages/desktop-client/src/components/modals/EnvelopeBudgetMenuModal.tsx index 789d3c13dc..9b84b3ec31 100644 --- a/packages/desktop-client/src/components/modals/EnvelopeBudgetMenuModal.tsx +++ b/packages/desktop-client/src/components/modals/EnvelopeBudgetMenuModal.tsx @@ -10,18 +10,18 @@ import { View } from '@actual-app/components/view'; import * as Platform from 'loot-core/shared/platform'; import { amountToInteger, integerToAmount } from 'loot-core/shared/util'; -import { BudgetMenu } from '@desktop-client/components/budget/envelope/BudgetMenu'; -import { useEnvelopeSheetValue } from '@desktop-client/components/budget/envelope/EnvelopeBudgetComponents'; +import { BudgetMenu } from '#components/budget/envelope/BudgetMenu'; +import { useEnvelopeSheetValue } from '#components/budget/envelope/EnvelopeBudgetComponents'; import { Modal, ModalCloseButton, ModalHeader, ModalTitle, -} from '@desktop-client/components/common/Modal'; -import { FocusableAmountInput } from '@desktop-client/components/mobile/transactions/FocusableAmountInput'; -import { useCategory } from '@desktop-client/hooks/useCategory'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; -import { envelopeBudget } from '@desktop-client/spreadsheet/bindings'; +} from '#components/common/Modal'; +import { FocusableAmountInput } from '#components/mobile/transactions/FocusableAmountInput'; +import { useCategory } from '#hooks/useCategory'; +import type { Modal as ModalType } from '#modals/modalsSlice'; +import { envelopeBudget } from '#spreadsheet/bindings'; type EnvelopeBudgetMenuModalProps = Omit< Extract['options'], diff --git a/packages/desktop-client/src/components/modals/EnvelopeBudgetMonthMenuModal.tsx b/packages/desktop-client/src/components/modals/EnvelopeBudgetMonthMenuModal.tsx index d6ef82f623..4de64ce8f9 100644 --- a/packages/desktop-client/src/components/modals/EnvelopeBudgetMonthMenuModal.tsx +++ b/packages/desktop-client/src/components/modals/EnvelopeBudgetMonthMenuModal.tsx @@ -16,17 +16,13 @@ import { css } from '@emotion/css'; import * as monthUtils from 'loot-core/shared/months'; -import { BudgetMonthMenu } from '@desktop-client/components/budget/envelope/budgetsummary/BudgetMonthMenu'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { Notes } from '@desktop-client/components/Notes'; -import { useLocale } from '@desktop-client/hooks/useLocale'; -import { useNotes } from '@desktop-client/hooks/useNotes'; -import { useUndo } from '@desktop-client/hooks/useUndo'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; +import { BudgetMonthMenu } from '#components/budget/envelope/budgetsummary/BudgetMonthMenu'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { Notes } from '#components/Notes'; +import { useLocale } from '#hooks/useLocale'; +import { useNotes } from '#hooks/useNotes'; +import { useUndo } from '#hooks/useUndo'; +import type { Modal as ModalType } from '#modals/modalsSlice'; type EnvelopeBudgetMonthMenuModalProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/EnvelopeBudgetSummaryModal.tsx b/packages/desktop-client/src/components/modals/EnvelopeBudgetSummaryModal.tsx index 7084de45c2..4cc0806f3a 100644 --- a/packages/desktop-client/src/components/modals/EnvelopeBudgetSummaryModal.tsx +++ b/packages/desktop-client/src/components/modals/EnvelopeBudgetSummaryModal.tsx @@ -10,23 +10,19 @@ import { } from 'loot-core/shared/months'; import type { CategoryEntity } from 'loot-core/types/models/category'; -import { ToBudgetAmount } from '@desktop-client/components/budget/envelope/budgetsummary/ToBudgetAmount'; -import { TotalsList } from '@desktop-client/components/budget/envelope/budgetsummary/TotalsList'; -import { useEnvelopeSheetValue } from '@desktop-client/components/budget/envelope/EnvelopeBudgetComponents'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { useCategoriesById } from '@desktop-client/hooks/useCategories'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useLocale } from '@desktop-client/hooks/useLocale'; -import { SheetNameProvider } from '@desktop-client/hooks/useSheetName'; -import { useUndo } from '@desktop-client/hooks/useUndo'; -import { collapseModals, pushModal } from '@desktop-client/modals/modalsSlice'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; -import { envelopeBudget } from '@desktop-client/spreadsheet/bindings'; +import { ToBudgetAmount } from '#components/budget/envelope/budgetsummary/ToBudgetAmount'; +import { TotalsList } from '#components/budget/envelope/budgetsummary/TotalsList'; +import { useEnvelopeSheetValue } from '#components/budget/envelope/EnvelopeBudgetComponents'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { useCategoriesById } from '#hooks/useCategories'; +import { useFormat } from '#hooks/useFormat'; +import { useLocale } from '#hooks/useLocale'; +import { SheetNameProvider } from '#hooks/useSheetName'; +import { useUndo } from '#hooks/useUndo'; +import { collapseModals, pushModal } from '#modals/modalsSlice'; +import type { Modal as ModalType } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; +import { envelopeBudget } from '#spreadsheet/bindings'; type EnvelopeBudgetSummaryModalProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/EnvelopeIncomeBalanceMenuModal.tsx b/packages/desktop-client/src/components/modals/EnvelopeIncomeBalanceMenuModal.tsx index e64ba9c233..368b96d6f8 100644 --- a/packages/desktop-client/src/components/modals/EnvelopeIncomeBalanceMenuModal.tsx +++ b/packages/desktop-client/src/components/modals/EnvelopeIncomeBalanceMenuModal.tsx @@ -11,18 +11,18 @@ import { View } from '@actual-app/components/view'; import { BalanceWithCarryover, CarryoverIndicator, -} from '@desktop-client/components/budget/BalanceWithCarryover'; -import { useEnvelopeSheetValue } from '@desktop-client/components/budget/envelope/EnvelopeBudgetComponents'; +} from '#components/budget/BalanceWithCarryover'; +import { useEnvelopeSheetValue } from '#components/budget/envelope/EnvelopeBudgetComponents'; import { Modal, ModalCloseButton, ModalHeader, ModalTitle, -} from '@desktop-client/components/common/Modal'; -import { CellValueText } from '@desktop-client/components/spreadsheet/CellValue'; -import { useCategory } from '@desktop-client/hooks/useCategory'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; -import { envelopeBudget } from '@desktop-client/spreadsheet/bindings'; +} from '#components/common/Modal'; +import { CellValueText } from '#components/spreadsheet/CellValue'; +import { useCategory } from '#hooks/useCategory'; +import type { Modal as ModalType } from '#modals/modalsSlice'; +import { envelopeBudget } from '#spreadsheet/bindings'; type EnvelopeIncomeBalanceMenuModalProps = Omit< Extract['options'], diff --git a/packages/desktop-client/src/components/modals/EnvelopeToBudgetMenuModal.tsx b/packages/desktop-client/src/components/modals/EnvelopeToBudgetMenuModal.tsx index 885f76f616..63fbe35e32 100644 --- a/packages/desktop-client/src/components/modals/EnvelopeToBudgetMenuModal.tsx +++ b/packages/desktop-client/src/components/modals/EnvelopeToBudgetMenuModal.tsx @@ -4,13 +4,9 @@ import type { CSSProperties } from 'react'; import { styles } from '@actual-app/components/styles'; import { theme } from '@actual-app/components/theme'; -import { ToBudgetMenu } from '@desktop-client/components/budget/envelope/budgetsummary/ToBudgetMenu'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; +import { ToBudgetMenu } from '#components/budget/envelope/budgetsummary/ToBudgetMenu'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import type { Modal as ModalType } from '#modals/modalsSlice'; type EnvelopeToBudgetMenuModalProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/FixEncryptionKeyModal.tsx b/packages/desktop-client/src/components/modals/FixEncryptionKeyModal.tsx index 2ece7dc07e..2e477d0a4c 100644 --- a/packages/desktop-client/src/components/modals/FixEncryptionKeyModal.tsx +++ b/packages/desktop-client/src/components/modals/FixEncryptionKeyModal.tsx @@ -16,14 +16,14 @@ import { View } from '@actual-app/components/view'; import { send } from 'loot-core/platform/client/connection'; import { getTestKeyError } from 'loot-core/shared/errors'; -import { Link } from '@desktop-client/components/common/Link'; +import { Link } from '#components/common/Link'; import { Modal, ModalButtons, ModalCloseButton, ModalHeader, -} from '@desktop-client/components/common/Modal'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; +} from '#components/common/Modal'; +import type { Modal as ModalType } from '#modals/modalsSlice'; type FixEncryptionKeyModalProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/GoCardlessExternalMsgModal.test.tsx b/packages/desktop-client/src/components/modals/GoCardlessExternalMsgModal.test.tsx index c8fcb40a4a..b1bea0b00b 100644 --- a/packages/desktop-client/src/components/modals/GoCardlessExternalMsgModal.test.tsx +++ b/packages/desktop-client/src/components/modals/GoCardlessExternalMsgModal.test.tsx @@ -3,13 +3,13 @@ import { vi } from 'vitest'; import { GoCardlessExternalMsgModal } from './GoCardlessExternalMsgModal'; -import { TestProviders } from '@desktop-client/mocks'; +import { TestProviders } from '#mocks'; -vi.mock('@desktop-client/hooks/useGlobalPref', () => ({ +vi.mock('#hooks/useGlobalPref', () => ({ useGlobalPref: () => [null], })); -vi.mock('@desktop-client/hooks/useGoCardlessStatus', () => ({ +vi.mock('#hooks/useGoCardlessStatus', () => ({ useGoCardlessStatus: () => ({ configuredGoCardless: true, isLoading: false, diff --git a/packages/desktop-client/src/components/modals/GoCardlessExternalMsgModal.tsx b/packages/desktop-client/src/components/modals/GoCardlessExternalMsgModal.tsx index 8e2779d56b..47d56c5042 100644 --- a/packages/desktop-client/src/components/modals/GoCardlessExternalMsgModal.tsx +++ b/packages/desktop-client/src/components/modals/GoCardlessExternalMsgModal.tsx @@ -14,22 +14,18 @@ import type { GoCardlessToken, } from 'loot-core/types/models'; -import { Error, Warning } from '@desktop-client/components/alerts'; -import { Autocomplete } from '@desktop-client/components/autocomplete/Autocomplete'; -import { Link } from '@desktop-client/components/common/Link'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { FormField, FormLabel } from '@desktop-client/components/forms'; -import { COUNTRY_OPTIONS } from '@desktop-client/components/util/countries'; -import { getCountryFromBrowser } from '@desktop-client/components/util/localeToCountry'; -import { useGlobalPref } from '@desktop-client/hooks/useGlobalPref'; -import { useGoCardlessStatus } from '@desktop-client/hooks/useGoCardlessStatus'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { Error, Warning } from '#components/alerts'; +import { Autocomplete } from '#components/autocomplete/Autocomplete'; +import { Link } from '#components/common/Link'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { FormField, FormLabel } from '#components/forms'; +import { COUNTRY_OPTIONS } from '#components/util/countries'; +import { getCountryFromBrowser } from '#components/util/localeToCountry'; +import { useGlobalPref } from '#hooks/useGlobalPref'; +import { useGoCardlessStatus } from '#hooks/useGoCardlessStatus'; +import { pushModal } from '#modals/modalsSlice'; +import type { Modal as ModalType } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; function useAvailableBanks(country: string) { const [banks, setBanks] = useState([]); diff --git a/packages/desktop-client/src/components/modals/GoCardlessInitialiseModal.tsx b/packages/desktop-client/src/components/modals/GoCardlessInitialiseModal.tsx index 5bdbbec615..3e0ff780e4 100644 --- a/packages/desktop-client/src/components/modals/GoCardlessInitialiseModal.tsx +++ b/packages/desktop-client/src/components/modals/GoCardlessInitialiseModal.tsx @@ -11,16 +11,16 @@ import { View } from '@actual-app/components/view'; import { send } from 'loot-core/platform/client/connection'; import { getSecretsError } from 'loot-core/shared/errors'; -import { Error } from '@desktop-client/components/alerts'; -import { Link } from '@desktop-client/components/common/Link'; +import { Error } from '#components/alerts'; +import { Link } from '#components/common/Link'; import { Modal, ModalButtons, ModalCloseButton, ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { FormField, FormLabel } from '@desktop-client/components/forms'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; +} from '#components/common/Modal'; +import { FormField, FormLabel } from '#components/forms'; +import type { Modal as ModalType } from '#modals/modalsSlice'; type GoCardlessInitialiseModalProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/GoalTemplateModal.tsx b/packages/desktop-client/src/components/modals/GoalTemplateModal.tsx index b85d80fc04..254681cb8f 100644 --- a/packages/desktop-client/src/components/modals/GoalTemplateModal.tsx +++ b/packages/desktop-client/src/components/modals/GoalTemplateModal.tsx @@ -4,13 +4,9 @@ import { Text } from '@actual-app/components/text'; import { theme } from '@actual-app/components/theme'; import { View } from '@actual-app/components/view'; -import { Link } from '@desktop-client/components/common/Link'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { Field, Row, TableHeader } from '@desktop-client/components/table'; +import { Link } from '#components/common/Link'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { Field, Row, TableHeader } from '#components/table'; export function GoalTemplateModal() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/modals/HoldBufferModal.tsx b/packages/desktop-client/src/components/modals/HoldBufferModal.tsx index 2beb6a6408..815388b801 100644 --- a/packages/desktop-client/src/components/modals/HoldBufferModal.tsx +++ b/packages/desktop-client/src/components/modals/HoldBufferModal.tsx @@ -6,17 +6,13 @@ import { InitialFocus } from '@actual-app/components/initial-focus'; import { styles } from '@actual-app/components/styles'; import { View } from '@actual-app/components/view'; -import { useEnvelopeSheetValue } from '@desktop-client/components/budget/envelope/EnvelopeBudgetComponents'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { FieldLabel } from '@desktop-client/components/mobile/MobileForms'; -import { AmountInput } from '@desktop-client/components/util/AmountInput'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; -import { envelopeBudget } from '@desktop-client/spreadsheet/bindings'; +import { useEnvelopeSheetValue } from '#components/budget/envelope/EnvelopeBudgetComponents'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { FieldLabel } from '#components/mobile/MobileForms'; +import { AmountInput } from '#components/util/AmountInput'; +import { useSyncedPref } from '#hooks/useSyncedPref'; +import type { Modal as ModalType } from '#modals/modalsSlice'; +import { envelopeBudget } from '#spreadsheet/bindings'; type HoldBufferModalProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/ImportTransactionsModal/DateFormatSelect.tsx b/packages/desktop-client/src/components/modals/ImportTransactionsModal/DateFormatSelect.tsx index 03e640c336..1fb920908b 100644 --- a/packages/desktop-client/src/components/modals/ImportTransactionsModal/DateFormatSelect.tsx +++ b/packages/desktop-client/src/components/modals/ImportTransactionsModal/DateFormatSelect.tsx @@ -7,7 +7,7 @@ import { View } from '@actual-app/components/view'; import { dateFormats } from './utils'; import type { DateFormat, FieldMapping, ImportTransaction } from './utils'; -import { SectionLabel } from '@desktop-client/components/forms'; +import { SectionLabel } from '#components/forms'; type DateFormatSelectProps = { transactions: ImportTransaction[]; diff --git a/packages/desktop-client/src/components/modals/ImportTransactionsModal/FieldMappings.tsx b/packages/desktop-client/src/components/modals/ImportTransactionsModal/FieldMappings.tsx index f117616431..699c22b2d8 100644 --- a/packages/desktop-client/src/components/modals/ImportTransactionsModal/FieldMappings.tsx +++ b/packages/desktop-client/src/components/modals/ImportTransactionsModal/FieldMappings.tsx @@ -9,7 +9,7 @@ import { SubLabel } from './SubLabel'; import { stripCsvImportTransaction } from './utils'; import type { FieldMapping, ImportTransaction } from './utils'; -import { SectionLabel } from '@desktop-client/components/forms'; +import { SectionLabel } from '#components/forms'; type FieldMappingsProps = { transactions: ImportTransaction[]; diff --git a/packages/desktop-client/src/components/modals/ImportTransactionsModal/ImportTransactionsModal.tsx b/packages/desktop-client/src/components/modals/ImportTransactionsModal/ImportTransactionsModal.tsx index ecb67993d8..87af1aceca 100644 --- a/packages/desktop-client/src/components/modals/ImportTransactionsModal/ImportTransactionsModal.tsx +++ b/packages/desktop-client/src/components/modals/ImportTransactionsModal/ImportTransactionsModal.tsx @@ -41,22 +41,15 @@ import type { DateFormat, FieldMapping, ImportTransaction } from './utils'; import { useImportPreviewTransactionsMutation, useImportTransactionsMutation, -} from '@desktop-client/accounts'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { SectionLabel } from '@desktop-client/components/forms'; -import { LabeledCheckbox } from '@desktop-client/components/forms/LabeledCheckbox'; -import { - TableHeader, - TableWithNavigator, -} from '@desktop-client/components/table'; -import { useCategories } from '@desktop-client/hooks/useCategories'; -import { useDateFormat } from '@desktop-client/hooks/useDateFormat'; -import { useSyncedPrefs } from '@desktop-client/hooks/useSyncedPrefs'; -import { payeeQueries } from '@desktop-client/payees'; +} from '#accounts'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { SectionLabel } from '#components/forms'; +import { LabeledCheckbox } from '#components/forms/LabeledCheckbox'; +import { TableHeader, TableWithNavigator } from '#components/table'; +import { useCategories } from '#hooks/useCategories'; +import { useDateFormat } from '#hooks/useDateFormat'; +import { useSyncedPrefs } from '#hooks/useSyncedPrefs'; +import { payeeQueries } from '#payees'; function CheckboxToggle({ id, diff --git a/packages/desktop-client/src/components/modals/ImportTransactionsModal/InOutOption.tsx b/packages/desktop-client/src/components/modals/ImportTransactionsModal/InOutOption.tsx index 8948e738f0..e527da7517 100644 --- a/packages/desktop-client/src/components/modals/ImportTransactionsModal/InOutOption.tsx +++ b/packages/desktop-client/src/components/modals/ImportTransactionsModal/InOutOption.tsx @@ -4,7 +4,7 @@ import { useTranslation } from 'react-i18next'; import { Input } from '@actual-app/components/input'; import { View } from '@actual-app/components/view'; -import { LabeledCheckbox } from '@desktop-client/components/forms/LabeledCheckbox'; +import { LabeledCheckbox } from '#components/forms/LabeledCheckbox'; type InOutOptionProps = { inOutMode: boolean; diff --git a/packages/desktop-client/src/components/modals/ImportTransactionsModal/MultiplierOption.tsx b/packages/desktop-client/src/components/modals/ImportTransactionsModal/MultiplierOption.tsx index 1a7861efa9..b978afe2b9 100644 --- a/packages/desktop-client/src/components/modals/ImportTransactionsModal/MultiplierOption.tsx +++ b/packages/desktop-client/src/components/modals/ImportTransactionsModal/MultiplierOption.tsx @@ -5,7 +5,7 @@ import { Trans, useTranslation } from 'react-i18next'; import { Input } from '@actual-app/components/input'; import { View } from '@actual-app/components/view'; -import { LabeledCheckbox } from '@desktop-client/components/forms/LabeledCheckbox'; +import { LabeledCheckbox } from '#components/forms/LabeledCheckbox'; type MultiplierOptionProps = { multiplierEnabled: boolean; diff --git a/packages/desktop-client/src/components/modals/ImportTransactionsModal/Transaction.tsx b/packages/desktop-client/src/components/modals/ImportTransactionsModal/Transaction.tsx index e32094a15b..63ddacaeef 100644 --- a/packages/desktop-client/src/components/modals/ImportTransactionsModal/Transaction.tsx +++ b/packages/desktop-client/src/components/modals/ImportTransactionsModal/Transaction.tsx @@ -16,8 +16,8 @@ import { ParsedDate } from './ParsedDate'; import { applyFieldMappings, formatDate, parseAmountFields } from './utils'; import type { FieldMapping, ImportTransaction } from './utils'; -import { Checkbox } from '@desktop-client/components/forms'; -import { Field, Row } from '@desktop-client/components/table'; +import { Checkbox } from '#components/forms'; +import { Field, Row } from '#components/table'; type TransactionProps = { transaction: ImportTransaction; diff --git a/packages/desktop-client/src/components/modals/KeyboardShortcutModal.tsx b/packages/desktop-client/src/components/modals/KeyboardShortcutModal.tsx index 02298b066e..bd88cf73b2 100644 --- a/packages/desktop-client/src/components/modals/KeyboardShortcutModal.tsx +++ b/packages/desktop-client/src/components/modals/KeyboardShortcutModal.tsx @@ -12,12 +12,8 @@ import { View } from '@actual-app/components/view'; import * as Platform from 'loot-core/shared/platform'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { Search } from '@desktop-client/components/common/Search'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { Search } from '#components/common/Search'; type KeyIconProps = { shortcut: string; diff --git a/packages/desktop-client/src/components/modals/LoadBackupModal.tsx b/packages/desktop-client/src/components/modals/LoadBackupModal.tsx index 0c4d998ebd..b22a7bccf6 100644 --- a/packages/desktop-client/src/components/modals/LoadBackupModal.tsx +++ b/packages/desktop-client/src/components/modals/LoadBackupModal.tsx @@ -10,19 +10,12 @@ import { View } from '@actual-app/components/view'; import { listen, send } from 'loot-core/platform/client/connection'; import type { Backup } from 'loot-core/server/budgetfiles/backups'; -import { - loadBackup, - makeBackup, -} from '@desktop-client/budgetfiles/budgetfilesSlice'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { Cell, Row } from '@desktop-client/components/table'; -import { useMetadataPref } from '@desktop-client/hooks/useMetadataPref'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { loadBackup, makeBackup } from '#budgetfiles/budgetfilesSlice'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { Cell, Row } from '#components/table'; +import { useMetadataPref } from '#hooks/useMetadataPref'; +import type { Modal as ModalType } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; type BackupTableProps = { backups: Backup[]; diff --git a/packages/desktop-client/src/components/modals/ManageRulesModal.tsx b/packages/desktop-client/src/components/modals/ManageRulesModal.tsx index 9a0de68d7c..23a5837383 100644 --- a/packages/desktop-client/src/components/modals/ManageRulesModal.tsx +++ b/packages/desktop-client/src/components/modals/ManageRulesModal.tsx @@ -2,13 +2,9 @@ import React, { useState } from 'react'; import { useTranslation } from 'react-i18next'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { ManageRules } from '@desktop-client/components/ManageRules'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { ManageRules } from '#components/ManageRules'; +import type { Modal as ModalType } from '#modals/modalsSlice'; type ManageRulesModalProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/MergeUnusedPayeesModal.tsx b/packages/desktop-client/src/components/modals/MergeUnusedPayeesModal.tsx index 2960e35618..52f7abf9fe 100644 --- a/packages/desktop-client/src/components/modals/MergeUnusedPayeesModal.tsx +++ b/packages/desktop-client/src/components/modals/MergeUnusedPayeesModal.tsx @@ -11,12 +11,12 @@ import { send } from 'loot-core/platform/client/connection'; import type { PayeeEntity } from 'loot-core/types/models'; import type { TransObjectLiteral } from 'loot-core/types/util'; -import { Information } from '@desktop-client/components/alerts'; -import { Modal, ModalButtons } from '@desktop-client/components/common/Modal'; -import { usePayees } from '@desktop-client/hooks/usePayees'; -import { replaceModal } from '@desktop-client/modals/modalsSlice'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; -import { useDispatch, useSelector } from '@desktop-client/redux'; +import { Information } from '#components/alerts'; +import { Modal, ModalButtons } from '#components/common/Modal'; +import { usePayees } from '#hooks/usePayees'; +import { replaceModal } from '#modals/modalsSlice'; +import type { Modal as ModalType } from '#modals/modalsSlice'; +import { useDispatch, useSelector } from '#redux'; const highlightStyle = { color: theme.pageTextPositive }; diff --git a/packages/desktop-client/src/components/modals/NewCategoryGroupModal.tsx b/packages/desktop-client/src/components/modals/NewCategoryGroupModal.tsx index 5b98010a59..bd2d57632b 100644 --- a/packages/desktop-client/src/components/modals/NewCategoryGroupModal.tsx +++ b/packages/desktop-client/src/components/modals/NewCategoryGroupModal.tsx @@ -2,11 +2,8 @@ import { useTranslation } from 'react-i18next'; import { SingleInputModal } from './SingleInputModal'; -import { - ModalHeader, - ModalTitle, -} from '@desktop-client/components/common/Modal'; -import type { Modal } from '@desktop-client/modals/modalsSlice'; +import { ModalHeader, ModalTitle } from '#components/common/Modal'; +import type { Modal } from '#modals/modalsSlice'; type NewCategoryGroupModalProps = Extract< Modal, diff --git a/packages/desktop-client/src/components/modals/NewCategoryModal.tsx b/packages/desktop-client/src/components/modals/NewCategoryModal.tsx index 996ab6a59f..0298e06ef9 100644 --- a/packages/desktop-client/src/components/modals/NewCategoryModal.tsx +++ b/packages/desktop-client/src/components/modals/NewCategoryModal.tsx @@ -2,11 +2,8 @@ import { useTranslation } from 'react-i18next'; import { SingleInputModal } from './SingleInputModal'; -import { - ModalHeader, - ModalTitle, -} from '@desktop-client/components/common/Modal'; -import type { Modal } from '@desktop-client/modals/modalsSlice'; +import { ModalHeader, ModalTitle } from '#components/common/Modal'; +import type { Modal } from '#modals/modalsSlice'; type NewCategoryModalProps = Extract< Modal, diff --git a/packages/desktop-client/src/components/modals/NotesModal.tsx b/packages/desktop-client/src/components/modals/NotesModal.tsx index acdd45779c..99fc18783f 100644 --- a/packages/desktop-client/src/components/modals/NotesModal.tsx +++ b/packages/desktop-client/src/components/modals/NotesModal.tsx @@ -6,14 +6,10 @@ import { Button } from '@actual-app/components/button'; import { SvgCheck } from '@actual-app/components/icons/v2'; import { View } from '@actual-app/components/view'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { Notes } from '@desktop-client/components/Notes'; -import { useNotes } from '@desktop-client/hooks/useNotes'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { Notes } from '#components/Notes'; +import { useNotes } from '#hooks/useNotes'; +import type { Modal as ModalType } from '#modals/modalsSlice'; type NotesModalProps = Extract['options']; diff --git a/packages/desktop-client/src/components/modals/OpenIDEnableModal.tsx b/packages/desktop-client/src/components/modals/OpenIDEnableModal.tsx index 42c3d32765..e45d971464 100644 --- a/packages/desktop-client/src/components/modals/OpenIDEnableModal.tsx +++ b/packages/desktop-client/src/components/modals/OpenIDEnableModal.tsx @@ -12,18 +12,14 @@ import * as asyncStorage from 'loot-core/platform/server/asyncStorage'; import { getOpenIdErrors } from 'loot-core/shared/errors'; import type { OpenIdConfig } from 'loot-core/types/models'; -import { closeBudget } from '@desktop-client/budgetfiles/budgetfilesSlice'; -import { Error } from '@desktop-client/components/alerts'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { OpenIdForm } from '@desktop-client/components/manager/subscribe/OpenIdForm'; -import { useRefreshLoginMethods } from '@desktop-client/components/ServerContext'; -import { popModal } from '@desktop-client/modals/modalsSlice'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { closeBudget } from '#budgetfiles/budgetfilesSlice'; +import { Error } from '#components/alerts'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { OpenIdForm } from '#components/manager/subscribe/OpenIdForm'; +import { useRefreshLoginMethods } from '#components/ServerContext'; +import { popModal } from '#modals/modalsSlice'; +import type { Modal as ModalType } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; type OpenIDEnableModalProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/OutOfSyncMigrationsModal.tsx b/packages/desktop-client/src/components/modals/OutOfSyncMigrationsModal.tsx index 60e63c7be9..7efad7a07e 100644 --- a/packages/desktop-client/src/components/modals/OutOfSyncMigrationsModal.tsx +++ b/packages/desktop-client/src/components/modals/OutOfSyncMigrationsModal.tsx @@ -6,14 +6,10 @@ import { Paragraph } from '@actual-app/components/paragraph'; import { Text } from '@actual-app/components/text'; import { View } from '@actual-app/components/view'; -import { closeBudget } from '@desktop-client/budgetfiles/budgetfilesSlice'; -import { Link } from '@desktop-client/components/common/Link'; -import { - Modal, - ModalHeader, - ModalTitle, -} from '@desktop-client/components/common/Modal'; -import { useDispatch } from '@desktop-client/redux'; +import { closeBudget } from '#budgetfiles/budgetfilesSlice'; +import { Link } from '#components/common/Link'; +import { Modal, ModalHeader, ModalTitle } from '#components/common/Modal'; +import { useDispatch } from '#redux'; export function OutOfSyncMigrationsModal() { const dispatch = useDispatch(); diff --git a/packages/desktop-client/src/components/modals/PasswordEnableModal.tsx b/packages/desktop-client/src/components/modals/PasswordEnableModal.tsx index 0a331db6af..db8de50fd2 100644 --- a/packages/desktop-client/src/components/modals/PasswordEnableModal.tsx +++ b/packages/desktop-client/src/components/modals/PasswordEnableModal.tsx @@ -10,26 +10,22 @@ import { View } from '@actual-app/components/view'; import { send } from 'loot-core/platform/client/connection'; import * as asyncStorage from 'loot-core/platform/server/asyncStorage'; -import { closeBudget } from '@desktop-client/budgetfiles/budgetfilesSlice'; -import { Error as ErrorAlert } from '@desktop-client/components/alerts'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { FormField } from '@desktop-client/components/forms'; +import { closeBudget } from '#budgetfiles/budgetfilesSlice'; +import { Error as ErrorAlert } from '#components/alerts'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { FormField } from '#components/forms'; import { ConfirmOldPasswordForm, ConfirmPasswordForm, -} from '@desktop-client/components/manager/subscribe/ConfirmPasswordForm'; +} from '#components/manager/subscribe/ConfirmPasswordForm'; import { useAvailableLoginMethods, useMultiuserEnabled, useRefreshLoginMethods, -} from '@desktop-client/components/ServerContext'; -import { popModal } from '@desktop-client/modals/modalsSlice'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; +} from '#components/ServerContext'; +import { popModal } from '#modals/modalsSlice'; +import type { Modal as ModalType } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; type PasswordEnableModalProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/PayeeAutocompleteModal.tsx b/packages/desktop-client/src/components/modals/PayeeAutocompleteModal.tsx index 0d59cad6f0..0f3301390b 100644 --- a/packages/desktop-client/src/components/modals/PayeeAutocompleteModal.tsx +++ b/packages/desktop-client/src/components/modals/PayeeAutocompleteModal.tsx @@ -4,17 +4,17 @@ import { useTranslation } from 'react-i18next'; import { useResponsive } from '@actual-app/components/hooks/useResponsive'; import { theme } from '@actual-app/components/theme'; -import { PayeeAutocomplete } from '@desktop-client/components/autocomplete/PayeeAutocomplete'; +import { PayeeAutocomplete } from '#components/autocomplete/PayeeAutocomplete'; import { Modal, ModalCloseButton, ModalHeader, ModalTitle, -} from '@desktop-client/components/common/Modal'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { usePayees } from '@desktop-client/hooks/usePayees'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; +} from '#components/common/Modal'; +import { useAccounts } from '#hooks/useAccounts'; +import { useNavigate } from '#hooks/useNavigate'; +import { usePayees } from '#hooks/usePayees'; +import type { Modal as ModalType } from '#modals/modalsSlice'; type PayeeAutocompleteModalProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/PluggyAiInitialiseModal.tsx b/packages/desktop-client/src/components/modals/PluggyAiInitialiseModal.tsx index ff2c01b381..8d18b22782 100644 --- a/packages/desktop-client/src/components/modals/PluggyAiInitialiseModal.tsx +++ b/packages/desktop-client/src/components/modals/PluggyAiInitialiseModal.tsx @@ -11,16 +11,16 @@ import { View } from '@actual-app/components/view'; import { send } from 'loot-core/platform/client/connection'; import { getSecretsError } from 'loot-core/shared/errors'; -import { Error } from '@desktop-client/components/alerts'; -import { Link } from '@desktop-client/components/common/Link'; +import { Error } from '#components/alerts'; +import { Link } from '#components/common/Link'; import { Modal, ModalButtons, ModalCloseButton, ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { FormField, FormLabel } from '@desktop-client/components/forms'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; +} from '#components/common/Modal'; +import { FormField, FormLabel } from '#components/forms'; +import type { Modal as ModalType } from '#modals/modalsSlice'; type PluggyAiInitialiseProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/ScheduledTransactionMenuModal.tsx b/packages/desktop-client/src/components/modals/ScheduledTransactionMenuModal.tsx index 14aff3a5ff..b582e6b9c7 100644 --- a/packages/desktop-client/src/components/modals/ScheduledTransactionMenuModal.tsx +++ b/packages/desktop-client/src/components/modals/ScheduledTransactionMenuModal.tsx @@ -20,10 +20,10 @@ import { ModalCloseButton, ModalHeader, ModalTitle, -} from '@desktop-client/components/common/Modal'; -import { useLocale } from '@desktop-client/hooks/useLocale'; -import { useSchedules } from '@desktop-client/hooks/useSchedules'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; +} from '#components/common/Modal'; +import { useLocale } from '#hooks/useLocale'; +import { useSchedules } from '#hooks/useSchedules'; +import type { Modal as ModalType } from '#modals/modalsSlice'; type ScheduledTransactionMenuModalProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/SelectLinkedAccountsModal.tsx b/packages/desktop-client/src/components/modals/SelectLinkedAccountsModal.tsx index 36c9d97833..1d1c96e293 100644 --- a/packages/desktop-client/src/components/modals/SelectLinkedAccountsModal.tsx +++ b/packages/desktop-client/src/components/modals/SelectLinkedAccountsModal.tsx @@ -25,31 +25,21 @@ import { useLinkAccountPluggyAiMutation, useLinkAccountSimpleFinMutation, useUnlinkAccountMutation, -} from '@desktop-client/accounts'; -import { Autocomplete } from '@desktop-client/components/autocomplete/Autocomplete'; -import type { AutocompleteItem } from '@desktop-client/components/autocomplete/Autocomplete'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { - Cell, - Field, - Row, - Table, - TableHeader, -} from '@desktop-client/components/table'; -import { AmountInput } from '@desktop-client/components/util/AmountInput'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; -import { useDateFormat } from '@desktop-client/hooks/useDateFormat'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { closeModal } from '@desktop-client/modals/modalsSlice'; -import { transactions } from '@desktop-client/queries'; -import { liveQuery } from '@desktop-client/queries/liveQuery'; -import { useDispatch } from '@desktop-client/redux'; +} from '#accounts'; +import { Autocomplete } from '#components/autocomplete/Autocomplete'; +import type { AutocompleteItem } from '#components/autocomplete/Autocomplete'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { FinancialText } from '#components/FinancialText'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { Cell, Field, Row, Table, TableHeader } from '#components/table'; +import { AmountInput } from '#components/util/AmountInput'; +import { useAccounts } from '#hooks/useAccounts'; +import { useDateFormat } from '#hooks/useDateFormat'; +import { useFormat } from '#hooks/useFormat'; +import { closeModal } from '#modals/modalsSlice'; +import { transactions } from '#queries'; +import { liveQuery } from '#queries/liveQuery'; +import { useDispatch } from '#redux'; function useAddBudgetAccountOptions() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/modals/SimpleFinInitialiseModal.tsx b/packages/desktop-client/src/components/modals/SimpleFinInitialiseModal.tsx index 8d7f5a4feb..6de6777c62 100644 --- a/packages/desktop-client/src/components/modals/SimpleFinInitialiseModal.tsx +++ b/packages/desktop-client/src/components/modals/SimpleFinInitialiseModal.tsx @@ -10,16 +10,16 @@ import { View } from '@actual-app/components/view'; import { send } from 'loot-core/platform/client/connection'; import { getSecretsError } from 'loot-core/shared/errors'; -import { Error } from '@desktop-client/components/alerts'; -import { Link } from '@desktop-client/components/common/Link'; +import { Error } from '#components/alerts'; +import { Link } from '#components/common/Link'; import { Modal, ModalButtons, ModalCloseButton, ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { FormField, FormLabel } from '@desktop-client/components/forms'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; +} from '#components/common/Modal'; +import { FormField, FormLabel } from '#components/forms'; +import type { Modal as ModalType } from '#modals/modalsSlice'; type SimpleFinInitialiseModalProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/SingleInputModal.tsx b/packages/desktop-client/src/components/modals/SingleInputModal.tsx index 050a570402..2bc699757b 100644 --- a/packages/desktop-client/src/components/modals/SingleInputModal.tsx +++ b/packages/desktop-client/src/components/modals/SingleInputModal.tsx @@ -9,12 +9,9 @@ import { InitialFocus } from '@actual-app/components/initial-focus'; import { styles } from '@actual-app/components/styles'; import { View } from '@actual-app/components/view'; -import { - Modal, - ModalCloseButton, -} from '@desktop-client/components/common/Modal'; -import type { ModalHeader } from '@desktop-client/components/common/Modal'; -import { InputField } from '@desktop-client/components/mobile/MobileForms'; +import { Modal, ModalCloseButton } from '#components/common/Modal'; +import type { ModalHeader } from '#components/common/Modal'; +import { InputField } from '#components/mobile/MobileForms'; type SingleInputModalProps = { name: string; diff --git a/packages/desktop-client/src/components/modals/TrackingBalanceMenuModal.tsx b/packages/desktop-client/src/components/modals/TrackingBalanceMenuModal.tsx index 9fd7ae7d69..d147b6a399 100644 --- a/packages/desktop-client/src/components/modals/TrackingBalanceMenuModal.tsx +++ b/packages/desktop-client/src/components/modals/TrackingBalanceMenuModal.tsx @@ -10,18 +10,18 @@ import { View } from '@actual-app/components/view'; import { BalanceWithCarryover, CarryoverIndicator, -} from '@desktop-client/components/budget/BalanceWithCarryover'; -import { BalanceMenu } from '@desktop-client/components/budget/tracking/BalanceMenu'; +} from '#components/budget/BalanceWithCarryover'; +import { BalanceMenu } from '#components/budget/tracking/BalanceMenu'; import { Modal, ModalCloseButton, ModalHeader, ModalTitle, -} from '@desktop-client/components/common/Modal'; -import { CellValueText } from '@desktop-client/components/spreadsheet/CellValue'; -import { useCategory } from '@desktop-client/hooks/useCategory'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; -import { trackingBudget } from '@desktop-client/spreadsheet/bindings'; +} from '#components/common/Modal'; +import { CellValueText } from '#components/spreadsheet/CellValue'; +import { useCategory } from '#hooks/useCategory'; +import type { Modal as ModalType } from '#modals/modalsSlice'; +import { trackingBudget } from '#spreadsheet/bindings'; type TrackingBalanceMenuModalProps = Omit< Extract['options'], diff --git a/packages/desktop-client/src/components/modals/TrackingBudgetMenuModal.tsx b/packages/desktop-client/src/components/modals/TrackingBudgetMenuModal.tsx index 9538b76c05..c057114940 100644 --- a/packages/desktop-client/src/components/modals/TrackingBudgetMenuModal.tsx +++ b/packages/desktop-client/src/components/modals/TrackingBudgetMenuModal.tsx @@ -10,18 +10,18 @@ import { View } from '@actual-app/components/view'; import * as Platform from 'loot-core/shared/platform'; import { amountToInteger, integerToAmount } from 'loot-core/shared/util'; -import { BudgetMenu } from '@desktop-client/components/budget/tracking/BudgetMenu'; -import { useTrackingSheetValue } from '@desktop-client/components/budget/tracking/TrackingBudgetComponents'; +import { BudgetMenu } from '#components/budget/tracking/BudgetMenu'; +import { useTrackingSheetValue } from '#components/budget/tracking/TrackingBudgetComponents'; import { Modal, ModalCloseButton, ModalHeader, ModalTitle, -} from '@desktop-client/components/common/Modal'; -import { FocusableAmountInput } from '@desktop-client/components/mobile/transactions/FocusableAmountInput'; -import { useCategory } from '@desktop-client/hooks/useCategory'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; -import { trackingBudget } from '@desktop-client/spreadsheet/bindings'; +} from '#components/common/Modal'; +import { FocusableAmountInput } from '#components/mobile/transactions/FocusableAmountInput'; +import { useCategory } from '#hooks/useCategory'; +import type { Modal as ModalType } from '#modals/modalsSlice'; +import { trackingBudget } from '#spreadsheet/bindings'; type TrackingBudgetMenuModalProps = Omit< Extract['options'], diff --git a/packages/desktop-client/src/components/modals/TrackingBudgetMonthMenuModal.tsx b/packages/desktop-client/src/components/modals/TrackingBudgetMonthMenuModal.tsx index 52e810cf5f..ec8706a6ba 100644 --- a/packages/desktop-client/src/components/modals/TrackingBudgetMonthMenuModal.tsx +++ b/packages/desktop-client/src/components/modals/TrackingBudgetMonthMenuModal.tsx @@ -16,17 +16,13 @@ import { css } from '@emotion/css'; import * as monthUtils from 'loot-core/shared/months'; -import { BudgetMonthMenu } from '@desktop-client/components/budget/tracking/budgetsummary/BudgetMonthMenu'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { Notes } from '@desktop-client/components/Notes'; -import { useLocale } from '@desktop-client/hooks/useLocale'; -import { useNotes } from '@desktop-client/hooks/useNotes'; -import { useUndo } from '@desktop-client/hooks/useUndo'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; +import { BudgetMonthMenu } from '#components/budget/tracking/budgetsummary/BudgetMonthMenu'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { Notes } from '#components/Notes'; +import { useLocale } from '#hooks/useLocale'; +import { useNotes } from '#hooks/useNotes'; +import { useUndo } from '#hooks/useUndo'; +import type { Modal as ModalType } from '#modals/modalsSlice'; type TrackingBudgetMonthMenuModalProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/TrackingBudgetSummaryModal.tsx b/packages/desktop-client/src/components/modals/TrackingBudgetSummaryModal.tsx index 543782b094..238d01955c 100644 --- a/packages/desktop-client/src/components/modals/TrackingBudgetSummaryModal.tsx +++ b/packages/desktop-client/src/components/modals/TrackingBudgetSummaryModal.tsx @@ -7,16 +7,12 @@ import { styles } from '@actual-app/components/styles'; import { sheetForMonth } from 'loot-core/shared/months'; import * as monthUtils from 'loot-core/shared/months'; -import { ExpenseTotal } from '@desktop-client/components/budget/tracking/budgetsummary/ExpenseTotal'; -import { IncomeTotal } from '@desktop-client/components/budget/tracking/budgetsummary/IncomeTotal'; -import { Saved } from '@desktop-client/components/budget/tracking/budgetsummary/Saved'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { SheetNameProvider } from '@desktop-client/hooks/useSheetName'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; +import { ExpenseTotal } from '#components/budget/tracking/budgetsummary/ExpenseTotal'; +import { IncomeTotal } from '#components/budget/tracking/budgetsummary/IncomeTotal'; +import { Saved } from '#components/budget/tracking/budgetsummary/Saved'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { SheetNameProvider } from '#hooks/useSheetName'; +import type { Modal as ModalType } from '#modals/modalsSlice'; type TrackingBudgetSummaryModalProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/TransferModal.tsx b/packages/desktop-client/src/components/modals/TransferModal.tsx index 25420ccfcc..a7592843b9 100644 --- a/packages/desktop-client/src/components/modals/TransferModal.tsx +++ b/packages/desktop-client/src/components/modals/TransferModal.tsx @@ -11,22 +11,15 @@ import type { IntegerAmount } from 'loot-core/shared/util'; import { addToBeBudgetedGroup, removeCategoriesFromGroups, -} from '@desktop-client/components/budget/util'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { - FieldLabel, - TapField, -} from '@desktop-client/components/mobile/MobileForms'; -import { AmountInput } from '@desktop-client/components/util/AmountInput'; -import { useCategories } from '@desktop-client/hooks/useCategories'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; +} from '#components/budget/util'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { FieldLabel, TapField } from '#components/mobile/MobileForms'; +import { AmountInput } from '#components/util/AmountInput'; +import { useCategories } from '#hooks/useCategories'; +import { useSyncedPref } from '#hooks/useSyncedPref'; +import { pushModal } from '#modals/modalsSlice'; +import type { Modal as ModalType } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; type TransferModalProps = Extract['options']; diff --git a/packages/desktop-client/src/components/modals/TransferOwnership.tsx b/packages/desktop-client/src/components/modals/TransferOwnership.tsx index 070e8ee3d5..4ec02ff60f 100644 --- a/packages/desktop-client/src/components/modals/TransferOwnership.tsx +++ b/packages/desktop-client/src/components/modals/TransferOwnership.tsx @@ -15,18 +15,14 @@ import type { Budget } from 'loot-core/types/budget'; import type { RemoteFile, SyncedLocalFile } from 'loot-core/types/file'; import type { Handlers } from 'loot-core/types/handlers'; -import { closeAndLoadBudget } from '@desktop-client/budgetfiles/budgetfilesSlice'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { FormField, FormLabel } from '@desktop-client/components/forms'; -import { useMetadataPref } from '@desktop-client/hooks/useMetadataPref'; -import { popModal } from '@desktop-client/modals/modalsSlice'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch, useSelector } from '@desktop-client/redux'; +import { closeAndLoadBudget } from '#budgetfiles/budgetfilesSlice'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { FormField, FormLabel } from '#components/forms'; +import { useMetadataPref } from '#hooks/useMetadataPref'; +import { popModal } from '#modals/modalsSlice'; +import type { Modal as ModalType } from '#modals/modalsSlice'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch, useSelector } from '#redux'; type TransferOwnershipProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/UnmigrateBudgetAutomationsModal.tsx b/packages/desktop-client/src/components/modals/UnmigrateBudgetAutomationsModal.tsx index 012937e481..aa145cc1fa 100644 --- a/packages/desktop-client/src/components/modals/UnmigrateBudgetAutomationsModal.tsx +++ b/packages/desktop-client/src/components/modals/UnmigrateBudgetAutomationsModal.tsx @@ -9,15 +9,11 @@ import { View } from '@actual-app/components/view'; import { send } from 'loot-core/platform/client/connection'; import type { Template } from 'loot-core/types/models/templates'; -import { Link } from '@desktop-client/components/common/Link'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { Notes } from '@desktop-client/components/Notes'; -import { useCategory } from '@desktop-client/hooks/useCategory'; -import { useNotes } from '@desktop-client/hooks/useNotes'; +import { Link } from '#components/common/Link'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { Notes } from '#components/Notes'; +import { useCategory } from '#hooks/useCategory'; +import { useNotes } from '#hooks/useNotes'; export function UnmigrateBudgetAutomationsModal({ categoryId, diff --git a/packages/desktop-client/src/components/modals/manager/ConfirmChangeDocumentDir.tsx b/packages/desktop-client/src/components/modals/manager/ConfirmChangeDocumentDir.tsx index 7a682819b4..a4a7d6f488 100644 --- a/packages/desktop-client/src/components/modals/manager/ConfirmChangeDocumentDir.tsx +++ b/packages/desktop-client/src/components/modals/manager/ConfirmChangeDocumentDir.tsx @@ -7,16 +7,12 @@ import { Text } from '@actual-app/components/text'; import { theme } from '@actual-app/components/theme'; import { View } from '@actual-app/components/view'; -import { Information } from '@desktop-client/components/alerts'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { Checkbox } from '@desktop-client/components/forms'; -import { useGlobalPref } from '@desktop-client/hooks/useGlobalPref'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { Information } from '#components/alerts'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { Checkbox } from '#components/forms'; +import { useGlobalPref } from '#hooks/useGlobalPref'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; function DirectoryDisplay({ directory }: { directory: string }) { return ( diff --git a/packages/desktop-client/src/components/modals/manager/DeleteFileModal.tsx b/packages/desktop-client/src/components/modals/manager/DeleteFileModal.tsx index 1891485d82..c516e17dad 100644 --- a/packages/desktop-client/src/components/modals/manager/DeleteFileModal.tsx +++ b/packages/desktop-client/src/components/modals/manager/DeleteFileModal.tsx @@ -6,15 +6,11 @@ import { Text } from '@actual-app/components/text'; import { theme } from '@actual-app/components/theme'; import { View } from '@actual-app/components/view'; -import { deleteBudget } from '@desktop-client/budgetfiles/budgetfilesSlice'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { useSyncServerStatus } from '@desktop-client/hooks/useSyncServerStatus'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; -import { useDispatch, useSelector } from '@desktop-client/redux'; +import { deleteBudget } from '#budgetfiles/budgetfilesSlice'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { useSyncServerStatus } from '#hooks/useSyncServerStatus'; +import type { Modal as ModalType } from '#modals/modalsSlice'; +import { useDispatch, useSelector } from '#redux'; type DeleteFileModalProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/manager/DuplicateFileModal.tsx b/packages/desktop-client/src/components/modals/manager/DuplicateFileModal.tsx index 9c957d6270..5df6afe2cb 100644 --- a/packages/desktop-client/src/components/modals/manager/DuplicateFileModal.tsx +++ b/packages/desktop-client/src/components/modals/manager/DuplicateFileModal.tsx @@ -12,16 +12,16 @@ import { View } from '@actual-app/components/view'; import { send } from 'loot-core/platform/client/connection'; -import { duplicateBudget } from '@desktop-client/budgetfiles/budgetfilesSlice'; +import { duplicateBudget } from '#budgetfiles/budgetfilesSlice'; import { Modal, ModalButtons, ModalCloseButton, ModalHeader, -} from '@desktop-client/components/common/Modal'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; +} from '#components/common/Modal'; +import type { Modal as ModalType } from '#modals/modalsSlice'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; type DuplicateFileModalProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/modals/manager/FilesSettingsModal.tsx b/packages/desktop-client/src/components/modals/manager/FilesSettingsModal.tsx index e338a0487a..d7b7e9a316 100644 --- a/packages/desktop-client/src/components/modals/manager/FilesSettingsModal.tsx +++ b/packages/desktop-client/src/components/modals/manager/FilesSettingsModal.tsx @@ -8,15 +8,11 @@ import { Text } from '@actual-app/components/text'; import { theme } from '@actual-app/components/theme'; import { View } from '@actual-app/components/view'; -import { loadAllFiles } from '@desktop-client/budgetfiles/budgetfilesSlice'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { useGlobalPref } from '@desktop-client/hooks/useGlobalPref'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { loadAllFiles } from '#budgetfiles/budgetfilesSlice'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { useGlobalPref } from '#hooks/useGlobalPref'; +import { pushModal } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; function FileLocationSettings() { const [documentDir, _setDocumentDirPref] = useGlobalPref('documentDir'); diff --git a/packages/desktop-client/src/components/modals/manager/ImportActualModal.tsx b/packages/desktop-client/src/components/modals/manager/ImportActualModal.tsx index 6f0df26063..d838738a80 100644 --- a/packages/desktop-client/src/components/modals/manager/ImportActualModal.tsx +++ b/packages/desktop-client/src/components/modals/manager/ImportActualModal.tsx @@ -9,14 +9,10 @@ import { styles } from '@actual-app/components/styles'; import { theme } from '@actual-app/components/theme'; import { View } from '@actual-app/components/view'; -import { importBudget } from '@desktop-client/budgetfiles/budgetfilesSlice'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { useDispatch } from '@desktop-client/redux'; +import { importBudget } from '#budgetfiles/budgetfilesSlice'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { useNavigate } from '#hooks/useNavigate'; +import { useDispatch } from '#redux'; export function ImportActualModal() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/modals/manager/ImportModal.tsx b/packages/desktop-client/src/components/modals/manager/ImportModal.tsx index ed44955fe2..3424b587c7 100644 --- a/packages/desktop-client/src/components/modals/manager/ImportModal.tsx +++ b/packages/desktop-client/src/components/modals/manager/ImportModal.tsx @@ -8,13 +8,9 @@ import { Text } from '@actual-app/components/text'; import { theme } from '@actual-app/components/theme'; import { View } from '@actual-app/components/view'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { pushModal } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; export function ImportModal() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/modals/manager/ImportYNAB4Modal.tsx b/packages/desktop-client/src/components/modals/manager/ImportYNAB4Modal.tsx index 4df148241d..c794df3565 100644 --- a/packages/desktop-client/src/components/modals/manager/ImportYNAB4Modal.tsx +++ b/packages/desktop-client/src/components/modals/manager/ImportYNAB4Modal.tsx @@ -9,14 +9,10 @@ import { styles } from '@actual-app/components/styles'; import { theme } from '@actual-app/components/theme'; import { View } from '@actual-app/components/view'; -import { importBudget } from '@desktop-client/budgetfiles/budgetfilesSlice'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { useDispatch } from '@desktop-client/redux'; +import { importBudget } from '#budgetfiles/budgetfilesSlice'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { useNavigate } from '#hooks/useNavigate'; +import { useDispatch } from '#redux'; function getErrorMessage(error: string): string { switch (error) { diff --git a/packages/desktop-client/src/components/modals/manager/ImportYNAB5Modal.tsx b/packages/desktop-client/src/components/modals/manager/ImportYNAB5Modal.tsx index 6f7dfa8069..87a43da7db 100644 --- a/packages/desktop-client/src/components/modals/manager/ImportYNAB5Modal.tsx +++ b/packages/desktop-client/src/components/modals/manager/ImportYNAB5Modal.tsx @@ -9,15 +9,11 @@ import { styles } from '@actual-app/components/styles'; import { theme } from '@actual-app/components/theme'; import { View } from '@actual-app/components/view'; -import { importBudget } from '@desktop-client/budgetfiles/budgetfilesSlice'; -import { Link } from '@desktop-client/components/common/Link'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { useDispatch } from '@desktop-client/redux'; +import { importBudget } from '#budgetfiles/budgetfilesSlice'; +import { Link } from '#components/common/Link'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { useNavigate } from '#hooks/useNavigate'; +import { useDispatch } from '#redux'; export function ImportYNAB5Modal() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/payees/CategoryLearning.tsx b/packages/desktop-client/src/components/payees/CategoryLearning.tsx index 4a9608d6a0..f1d36d29ce 100644 --- a/packages/desktop-client/src/components/payees/CategoryLearning.tsx +++ b/packages/desktop-client/src/components/payees/CategoryLearning.tsx @@ -4,13 +4,9 @@ import { Trans, useTranslation } from 'react-i18next'; import { Button } from '@actual-app/components/button'; import { Paragraph } from '@actual-app/components/paragraph'; -import { Link } from '@desktop-client/components/common/Link'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; +import { Link } from '#components/common/Link'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { useSyncedPref } from '#hooks/useSyncedPref'; export function CategoryLearning() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/payees/ManagePayees.tsx b/packages/desktop-client/src/components/payees/ManagePayees.tsx index 40bf490983..090465881a 100644 --- a/packages/desktop-client/src/components/payees/ManagePayees.tsx +++ b/packages/desktop-client/src/components/payees/ManagePayees.tsx @@ -18,20 +18,16 @@ import type { PayeeEntity } from 'loot-core/types/models'; import { PayeeMenu } from './PayeeMenu'; import { PayeeTable } from './PayeeTable'; -import { Search } from '@desktop-client/components/common/Search'; -import { - Cell, - SelectCell, - TableHeader, -} from '@desktop-client/components/table'; +import { Search } from '#components/common/Search'; +import { Cell, SelectCell, TableHeader } from '#components/table'; import { SelectedProvider, useSelected, useSelectedDispatch, useSelectedItems, -} from '@desktop-client/hooks/useSelected'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; +} from '#hooks/useSelected'; +import { pushModal } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; const getPayeesById = memoizeOne((payees: PayeeEntity[]) => groupById(payees)); diff --git a/packages/desktop-client/src/components/payees/ManagePayeesPage.tsx b/packages/desktop-client/src/components/payees/ManagePayeesPage.tsx index a6d94165b6..d7a88ceab0 100644 --- a/packages/desktop-client/src/components/payees/ManagePayeesPage.tsx +++ b/packages/desktop-client/src/components/payees/ManagePayeesPage.tsx @@ -6,7 +6,7 @@ import type { PayeeEntity } from 'loot-core/types/models'; import { ManagePayeesWithData } from './ManagePayeesWithData'; -import { Page } from '@desktop-client/components/Page'; +import { Page } from '#components/Page'; export function ManagePayeesPage() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/payees/ManagePayeesWithData.tsx b/packages/desktop-client/src/components/payees/ManagePayeesWithData.tsx index de7186622b..bc8dfe530d 100644 --- a/packages/desktop-client/src/components/payees/ManagePayeesWithData.tsx +++ b/packages/desktop-client/src/components/payees/ManagePayeesWithData.tsx @@ -11,12 +11,12 @@ import type { NewRuleEntity, PayeeEntity } from 'loot-core/types/models'; import { ManagePayees } from './ManagePayees'; -import { useOrphanedPayees } from '@desktop-client/hooks/useOrphanedPayees'; -import { usePayeeRuleCounts } from '@desktop-client/hooks/usePayeeRuleCounts'; -import { usePayees } from '@desktop-client/hooks/usePayees'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import { payeeQueries } from '@desktop-client/payees'; -import { useDispatch } from '@desktop-client/redux'; +import { useOrphanedPayees } from '#hooks/useOrphanedPayees'; +import { usePayeeRuleCounts } from '#hooks/usePayeeRuleCounts'; +import { usePayees } from '#hooks/usePayees'; +import { pushModal } from '#modals/modalsSlice'; +import { payeeQueries } from '#payees'; +import { useDispatch } from '#redux'; type ManagePayeesWithDataProps = { initialSelectedIds: string[]; diff --git a/packages/desktop-client/src/components/payees/PayeeMenu.tsx b/packages/desktop-client/src/components/payees/PayeeMenu.tsx index 1b8a88b500..20fb0f72bf 100644 --- a/packages/desktop-client/src/components/payees/PayeeMenu.tsx +++ b/packages/desktop-client/src/components/payees/PayeeMenu.tsx @@ -9,7 +9,7 @@ import { View } from '@actual-app/components/view'; import type { PayeeEntity } from 'loot-core/types/models'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; +import { useSyncedPref } from '#hooks/useSyncedPref'; type PayeeMenuProps = { payeesById: Record; diff --git a/packages/desktop-client/src/components/payees/PayeeTable.tsx b/packages/desktop-client/src/components/payees/PayeeTable.tsx index 084dbb26fd..eeb2b1409d 100644 --- a/packages/desktop-client/src/components/payees/PayeeTable.tsx +++ b/packages/desktop-client/src/components/payees/PayeeTable.tsx @@ -15,8 +15,8 @@ import type { PayeeEntity } from 'loot-core/types/models'; import { PayeeTableRow } from './PayeeTableRow'; -import { Table, useTableNavigator } from '@desktop-client/components/table'; -import { useSelectedItems } from '@desktop-client/hooks/useSelected'; +import { Table, useTableNavigator } from '#components/table'; +import { useSelectedItems } from '#hooks/useSelected'; // Table items require an ID to work, it's optional in the loot-core // model so would need to verify accuracy of that before changing there diff --git a/packages/desktop-client/src/components/payees/PayeeTableRow.tsx b/packages/desktop-client/src/components/payees/PayeeTableRow.tsx index 28c3efe680..386d098f78 100644 --- a/packages/desktop-client/src/components/payees/PayeeTableRow.tsx +++ b/packages/desktop-client/src/components/payees/PayeeTableRow.tsx @@ -24,13 +24,10 @@ import { InputCell, Row, SelectCell, -} from '@desktop-client/components/table'; -import { useContextMenu } from '@desktop-client/hooks/useContextMenu'; -import { - useSelectedDispatch, - useSelectedItems, -} from '@desktop-client/hooks/useSelected'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; +} from '#components/table'; +import { useContextMenu } from '#hooks/useContextMenu'; +import { useSelectedDispatch, useSelectedItems } from '#hooks/useSelected'; +import { useSyncedPref } from '#hooks/useSyncedPref'; type RuleButtonProps = { ruleCount: number; diff --git a/packages/desktop-client/src/components/reports/AccountSelector.tsx b/packages/desktop-client/src/components/reports/AccountSelector.tsx index f1a05b0a90..6d7abfaf46 100644 --- a/packages/desktop-client/src/components/reports/AccountSelector.tsx +++ b/packages/desktop-client/src/components/reports/AccountSelector.tsx @@ -15,7 +15,7 @@ import type { AccountEntity } from 'loot-core/types/models'; import { GraphButton } from './GraphButton'; -import { Checkbox } from '@desktop-client/components/forms'; +import { Checkbox } from '#components/forms'; type AccountSelectorProps = { accounts: AccountEntity[]; diff --git a/packages/desktop-client/src/components/reports/CategorySelector.tsx b/packages/desktop-client/src/components/reports/CategorySelector.tsx index 9656399cf9..0027f55910 100644 --- a/packages/desktop-client/src/components/reports/CategorySelector.tsx +++ b/packages/desktop-client/src/components/reports/CategorySelector.tsx @@ -19,7 +19,7 @@ import type { import { GraphButton } from './GraphButton'; -import { Checkbox } from '@desktop-client/components/forms'; +import { Checkbox } from '#components/forms'; type CategorySelectorProps = { categoryGroups: Array; diff --git a/packages/desktop-client/src/components/reports/Change.test.tsx b/packages/desktop-client/src/components/reports/Change.test.tsx index 2311c9e881..324519c444 100644 --- a/packages/desktop-client/src/components/reports/Change.test.tsx +++ b/packages/desktop-client/src/components/reports/Change.test.tsx @@ -5,7 +5,7 @@ import { render, screen } from '@testing-library/react'; import { Change } from './Change'; -import { TestProviders } from '@desktop-client/mocks'; +import { TestProviders } from '#mocks'; describe('Change', () => { it('renders a positive amount with a plus sign and positive color', () => { diff --git a/packages/desktop-client/src/components/reports/Change.tsx b/packages/desktop-client/src/components/reports/Change.tsx index 9374443ed3..65b21d8347 100644 --- a/packages/desktop-client/src/components/reports/Change.tsx +++ b/packages/desktop-client/src/components/reports/Change.tsx @@ -5,8 +5,8 @@ import { Block } from '@actual-app/components/block'; import { styles } from '@actual-app/components/styles'; import { theme } from '@actual-app/components/theme'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { useFormat } from '@desktop-client/hooks/useFormat'; +import { FinancialText } from '#components/FinancialText'; +import { useFormat } from '#hooks/useFormat'; export function Change({ amount, diff --git a/packages/desktop-client/src/components/reports/DashboardHeader.tsx b/packages/desktop-client/src/components/reports/DashboardHeader.tsx index 612c4739b5..c41959d724 100644 --- a/packages/desktop-client/src/components/reports/DashboardHeader.tsx +++ b/packages/desktop-client/src/components/reports/DashboardHeader.tsx @@ -10,7 +10,7 @@ import { View } from '@actual-app/components/view'; import type { DashboardPageEntity } from 'loot-core/types/models'; -import { useRenameDashboardPageMutation } from '@desktop-client/reports/mutations'; +import { useRenameDashboardPageMutation } from '#reports/mutations'; type DashboardHeaderProps = { dashboard: DashboardPageEntity; diff --git a/packages/desktop-client/src/components/reports/DashboardSelector.tsx b/packages/desktop-client/src/components/reports/DashboardSelector.tsx index dd4d293be0..deee1c7087 100644 --- a/packages/desktop-client/src/components/reports/DashboardSelector.tsx +++ b/packages/desktop-client/src/components/reports/DashboardSelector.tsx @@ -10,8 +10,8 @@ import { View } from '@actual-app/components/view'; import type { DashboardPageEntity } from 'loot-core/types/models'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { useCreateDashboardPageMutation } from '@desktop-client/reports/mutations'; +import { useNavigate } from '#hooks/useNavigate'; +import { useCreateDashboardPageMutation } from '#reports/mutations'; type DashboardSelectorProps = { dashboards: readonly DashboardPageEntity[]; diff --git a/packages/desktop-client/src/components/reports/DateRange.tsx b/packages/desktop-client/src/components/reports/DateRange.tsx index c30149c6b5..72bf263ead 100644 --- a/packages/desktop-client/src/components/reports/DateRange.tsx +++ b/packages/desktop-client/src/components/reports/DateRange.tsx @@ -10,7 +10,7 @@ import * as d from 'date-fns'; import * as monthUtils from 'loot-core/shared/months'; -import { useLocale } from '@desktop-client/hooks/useLocale'; +import { useLocale } from '#hooks/useLocale'; type DateRangeProps = { start: string; diff --git a/packages/desktop-client/src/components/reports/FormulaResult.tsx b/packages/desktop-client/src/components/reports/FormulaResult.tsx index b3ce1295f5..f4dc4a9cdb 100644 --- a/packages/desktop-client/src/components/reports/FormulaResult.tsx +++ b/packages/desktop-client/src/components/reports/FormulaResult.tsx @@ -15,10 +15,10 @@ import { amountToInteger } from 'loot-core/shared/util'; import { LoadingIndicator } from './LoadingIndicator'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useMergedRefs } from '@desktop-client/hooks/useMergedRefs'; -import { useResizeObserver } from '@desktop-client/hooks/useResizeObserver'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { useFormat } from '#hooks/useFormat'; +import { useMergedRefs } from '#hooks/useMergedRefs'; +import { useResizeObserver } from '#hooks/useResizeObserver'; const FONT_SIZE_SCALE_FACTOR = 1.6; const CONTAINER_MARGIN = 8; diff --git a/packages/desktop-client/src/components/reports/Header.tsx b/packages/desktop-client/src/components/reports/Header.tsx index 52c8e29251..540a2b352f 100644 --- a/packages/desktop-client/src/components/reports/Header.tsx +++ b/packages/desktop-client/src/components/reports/Header.tsx @@ -20,9 +20,9 @@ import { validateStart, } from './reportRanges'; -import { AppliedFilters } from '@desktop-client/components/filters/AppliedFilters'; -import { FilterButton } from '@desktop-client/components/filters/FiltersMenu'; -import { useLocale } from '@desktop-client/hooks/useLocale'; +import { AppliedFilters } from '#components/filters/AppliedFilters'; +import { FilterButton } from '#components/filters/FiltersMenu'; +import { useLocale } from '#hooks/useLocale'; type HeaderProps = { start: TimeFrame['start']; diff --git a/packages/desktop-client/src/components/reports/Overview.tsx b/packages/desktop-client/src/components/reports/Overview.tsx index c907049fa1..6c22ad2063 100644 --- a/packages/desktop-client/src/components/reports/Overview.tsx +++ b/packages/desktop-client/src/components/reports/Overview.tsx @@ -38,24 +38,24 @@ import { SpendingCard } from './reports/SpendingCard'; import './overview.scss'; import { SummaryCard } from './reports/SummaryCard'; -import { MOBILE_NAV_HEIGHT } from '@desktop-client/components/mobile/MobileNavTabs'; -import { MobilePageHeader, Page } from '@desktop-client/components/Page'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; +import { MOBILE_NAV_HEIGHT } from '#components/mobile/MobileNavTabs'; +import { MobilePageHeader, Page } from '#components/Page'; +import { useAccounts } from '#hooks/useAccounts'; import { useDashboardPages, useDashboardPageWidgets, -} from '@desktop-client/hooks/useDashboardPages'; -import { useFeatureFlag } from '@desktop-client/hooks/useFeatureFlag'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { useReports } from '@desktop-client/hooks/useReports'; -import { useResizeObserver } from '@desktop-client/hooks/useResizeObserver'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; -import { useUndo } from '@desktop-client/hooks/useUndo'; +} from '#hooks/useDashboardPages'; +import { useFeatureFlag } from '#hooks/useFeatureFlag'; +import { useNavigate } from '#hooks/useNavigate'; +import { useReports } from '#hooks/useReports'; +import { useResizeObserver } from '#hooks/useResizeObserver'; +import { useSyncedPref } from '#hooks/useSyncedPref'; +import { useUndo } from '#hooks/useUndo'; import { addNotification, removeNotification, -} from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; +} from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; import { useAddDashboardWidgetMutation, useCopyDashboardWidgetMutation, @@ -65,7 +65,7 @@ import { useResetDashboardPageMutation, useUpdateDashboardWidgetMutation, useUpdateDashboardWidgetsMutation, -} from '@desktop-client/reports/mutations'; +} from '#reports/mutations'; function isCustomReportWidget( widget: DashboardWidgetEntity, diff --git a/packages/desktop-client/src/components/reports/ReportCard.tsx b/packages/desktop-client/src/components/reports/ReportCard.tsx index 64ebeb6784..420acf0028 100644 --- a/packages/desktop-client/src/components/reports/ReportCard.tsx +++ b/packages/desktop-client/src/components/reports/ReportCard.tsx @@ -12,9 +12,9 @@ import { View } from '@actual-app/components/view'; import { NON_DRAGGABLE_AREA_CLASS_NAME } from './constants'; -import { useContextMenu } from '@desktop-client/hooks/useContextMenu'; -import { useIsInViewport } from '@desktop-client/hooks/useIsInViewport'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; +import { useContextMenu } from '#hooks/useContextMenu'; +import { useIsInViewport } from '#hooks/useIsInViewport'; +import { useNavigate } from '#hooks/useNavigate'; type ReportCardProps = { isEditing?: boolean; diff --git a/packages/desktop-client/src/components/reports/ReportRouter.tsx b/packages/desktop-client/src/components/reports/ReportRouter.tsx index 4942737adb..98178b8be6 100644 --- a/packages/desktop-client/src/components/reports/ReportRouter.tsx +++ b/packages/desktop-client/src/components/reports/ReportRouter.tsx @@ -12,7 +12,7 @@ import { Spending } from './reports/Spending'; import { Summary } from './reports/Summary'; import { ReportsDashboardRouter } from './ReportsDashboardRouter'; -import { useFeatureFlag } from '@desktop-client/hooks/useFeatureFlag'; +import { useFeatureFlag } from '#hooks/useFeatureFlag'; export function ReportRouter() { const crossoverReportEnabled = useFeatureFlag('crossoverReport'); diff --git a/packages/desktop-client/src/components/reports/ReportSidebar.tsx b/packages/desktop-client/src/components/reports/ReportSidebar.tsx index 424addc13e..48b6587bbb 100644 --- a/packages/desktop-client/src/components/reports/ReportSidebar.tsx +++ b/packages/desktop-client/src/components/reports/ReportSidebar.tsx @@ -33,8 +33,8 @@ import type { dateRangeProps } from './ReportOptions'; import { validateEnd, validateStart } from './reportRanges'; import { setSessionReport } from './setSessionReport'; -import { Information } from '@desktop-client/components/alerts'; -import { useLocale } from '@desktop-client/hooks/useLocale'; +import { Information } from '#components/alerts'; +import { useLocale } from '#hooks/useLocale'; type ReportSidebarProps = { customReportItems: CustomReportEntity; diff --git a/packages/desktop-client/src/components/reports/ReportSummary.tsx b/packages/desktop-client/src/components/reports/ReportSummary.tsx index 73fdc9387d..162f36ad12 100644 --- a/packages/desktop-client/src/components/reports/ReportSummary.tsx +++ b/packages/desktop-client/src/components/reports/ReportSummary.tsx @@ -11,10 +11,10 @@ import type { balanceTypeOpType, DataEntity } from 'loot-core/types/models'; import { ReportOptions } from './ReportOptions'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useLocale } from '@desktop-client/hooks/useLocale'; +import { FinancialText } from '#components/FinancialText'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { useFormat } from '#hooks/useFormat'; +import { useLocale } from '#hooks/useLocale'; type ReportSummaryProps = { startDate: string; diff --git a/packages/desktop-client/src/components/reports/ReportTopbar.tsx b/packages/desktop-client/src/components/reports/ReportTopbar.tsx index 0f376f23af..d5b170e189 100644 --- a/packages/desktop-client/src/components/reports/ReportTopbar.tsx +++ b/packages/desktop-client/src/components/reports/ReportTopbar.tsx @@ -30,7 +30,7 @@ import type { SavedStatus } from './SaveReportMenu'; import { setSessionReport } from './setSessionReport'; import { SnapshotButton } from './SnapshotButton'; -import { FilterButton } from '@desktop-client/components/filters/FiltersMenu'; +import { FilterButton } from '#components/filters/FiltersMenu'; type ReportTopbarProps = { customReportItems: CustomReportEntity; diff --git a/packages/desktop-client/src/components/reports/ReportsDashboardRouter.tsx b/packages/desktop-client/src/components/reports/ReportsDashboardRouter.tsx index 15bcb48c0b..77655d46ba 100644 --- a/packages/desktop-client/src/components/reports/ReportsDashboardRouter.tsx +++ b/packages/desktop-client/src/components/reports/ReportsDashboardRouter.tsx @@ -8,8 +8,8 @@ import { View } from '@actual-app/components/view'; import { LoadingIndicator } from './LoadingIndicator'; import { Overview } from './Overview'; -import { useDashboardPages } from '@desktop-client/hooks/useDashboardPages'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; +import { useDashboardPages } from '#hooks/useDashboardPages'; +import { useNavigate } from '#hooks/useNavigate'; export function ReportsDashboardRouter() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/reports/SaveReport.tsx b/packages/desktop-client/src/components/reports/SaveReport.tsx index 5904f2d4b3..f5ae473388 100644 --- a/packages/desktop-client/src/components/reports/SaveReport.tsx +++ b/packages/desktop-client/src/components/reports/SaveReport.tsx @@ -21,15 +21,15 @@ import { SaveReportMenu } from './SaveReportMenu'; import type { SavedStatus } from './SaveReportMenu'; import { SaveReportName } from './SaveReportName'; -import { FormField, FormLabel } from '@desktop-client/components/forms'; -import { useDashboardPages } from '@desktop-client/hooks/useDashboardPages'; -import { useReports } from '@desktop-client/hooks/useReports'; +import { FormField, FormLabel } from '#components/forms'; +import { useDashboardPages } from '#hooks/useDashboardPages'; +import { useReports } from '#hooks/useReports'; import { useAddDashboardWidgetMutation, useCreateReportMutation, useDeleteReportMutation, useUpdateReportMutation, -} from '@desktop-client/reports/mutations'; +} from '#reports/mutations'; type SaveReportProps = { customReportItems: T; diff --git a/packages/desktop-client/src/components/reports/SaveReportChoose.tsx b/packages/desktop-client/src/components/reports/SaveReportChoose.tsx index ddbe9857bc..a8c7d19274 100644 --- a/packages/desktop-client/src/components/reports/SaveReportChoose.tsx +++ b/packages/desktop-client/src/components/reports/SaveReportChoose.tsx @@ -7,7 +7,7 @@ import { Text } from '@actual-app/components/text'; import { theme } from '@actual-app/components/theme'; import { View } from '@actual-app/components/view'; -import { GenericInput } from '@desktop-client/components/util/GenericInput'; +import { GenericInput } from '#components/util/GenericInput'; type SaveReportChooseProps = { onApply: (cond: string) => void; diff --git a/packages/desktop-client/src/components/reports/SaveReportName.tsx b/packages/desktop-client/src/components/reports/SaveReportName.tsx index 804548c4d3..299cddc78c 100644 --- a/packages/desktop-client/src/components/reports/SaveReportName.tsx +++ b/packages/desktop-client/src/components/reports/SaveReportName.tsx @@ -12,7 +12,7 @@ import { View } from '@actual-app/components/view'; import type { CustomReportEntity } from 'loot-core/types/models'; -import { FormField, FormLabel } from '@desktop-client/components/forms'; +import { FormField, FormLabel } from '#components/forms'; type SaveReportNameProps = { menuItem: string; diff --git a/packages/desktop-client/src/components/reports/SummaryNumber.tsx b/packages/desktop-client/src/components/reports/SummaryNumber.tsx index 92ecdcd197..86b1e41bc4 100644 --- a/packages/desktop-client/src/components/reports/SummaryNumber.tsx +++ b/packages/desktop-client/src/components/reports/SummaryNumber.tsx @@ -8,11 +8,11 @@ import debounce from 'lodash/debounce'; import { LoadingIndicator } from './LoadingIndicator'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useMergedRefs } from '@desktop-client/hooks/useMergedRefs'; -import { useResizeObserver } from '@desktop-client/hooks/useResizeObserver'; +import { FinancialText } from '#components/FinancialText'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { useFormat } from '#hooks/useFormat'; +import { useMergedRefs } from '#hooks/useMergedRefs'; +import { useResizeObserver } from '#hooks/useResizeObserver'; const FONT_SIZE_SCALE_FACTOR = 1.6; const CONTAINER_MARGIN = 8; diff --git a/packages/desktop-client/src/components/reports/chart-theme.ts b/packages/desktop-client/src/components/reports/chart-theme.ts index 4e264562b8..054a7d40ac 100644 --- a/packages/desktop-client/src/components/reports/chart-theme.ts +++ b/packages/desktop-client/src/components/reports/chart-theme.ts @@ -1,4 +1,4 @@ -import { useIsTestEnv } from '@desktop-client/hooks/useIsTestEnv'; +import { useIsTestEnv } from '#hooks/useIsTestEnv'; export function getColorScale(name: string): string[] { const scales: Record = { diff --git a/packages/desktop-client/src/components/reports/graphs/AreaGraph.tsx b/packages/desktop-client/src/components/reports/graphs/AreaGraph.tsx index 6e9f9e8148..19dff38b5a 100644 --- a/packages/desktop-client/src/components/reports/graphs/AreaGraph.tsx +++ b/packages/desktop-client/src/components/reports/graphs/AreaGraph.tsx @@ -21,12 +21,12 @@ import type { balanceTypeOpType, DataEntity } from 'loot-core/types/models'; import { adjustTextSize } from './adjustTextSize'; import { renderCustomLabel } from './renderCustomLabel'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { useRechartsAnimation } from '@desktop-client/components/reports/chart-theme'; -import { Container } from '@desktop-client/components/reports/Container'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import type { FormatType } from '@desktop-client/hooks/useFormat'; -import { usePrivacyMode } from '@desktop-client/hooks/usePrivacyMode'; +import { FinancialText } from '#components/FinancialText'; +import { useRechartsAnimation } from '#components/reports/chart-theme'; +import { Container } from '#components/reports/Container'; +import { useFormat } from '#hooks/useFormat'; +import type { FormatType } from '#hooks/useFormat'; +import { usePrivacyMode } from '#hooks/usePrivacyMode'; type PayloadItem = { payload: { diff --git a/packages/desktop-client/src/components/reports/graphs/BarGraph.tsx b/packages/desktop-client/src/components/reports/graphs/BarGraph.tsx index 922bd0516c..f28746cb9d 100644 --- a/packages/desktop-client/src/components/reports/graphs/BarGraph.tsx +++ b/packages/desktop-client/src/components/reports/graphs/BarGraph.tsx @@ -29,17 +29,17 @@ import { adjustTextSize } from './adjustTextSize'; import { renderCustomLabel } from './renderCustomLabel'; import { showActivity } from './showActivity'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { useRechartsAnimation } from '@desktop-client/components/reports/chart-theme'; -import { Container } from '@desktop-client/components/reports/Container'; -import { getCustomTick } from '@desktop-client/components/reports/getCustomTick'; -import { numberFormatterTooltip } from '@desktop-client/components/reports/numberFormatter'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; -import { useCategories } from '@desktop-client/hooks/useCategories'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import type { FormatType } from '@desktop-client/hooks/useFormat'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { usePrivacyMode } from '@desktop-client/hooks/usePrivacyMode'; +import { FinancialText } from '#components/FinancialText'; +import { useRechartsAnimation } from '#components/reports/chart-theme'; +import { Container } from '#components/reports/Container'; +import { getCustomTick } from '#components/reports/getCustomTick'; +import { numberFormatterTooltip } from '#components/reports/numberFormatter'; +import { useAccounts } from '#hooks/useAccounts'; +import { useCategories } from '#hooks/useCategories'; +import { useFormat } from '#hooks/useFormat'; +import type { FormatType } from '#hooks/useFormat'; +import { useNavigate } from '#hooks/useNavigate'; +import { usePrivacyMode } from '#hooks/usePrivacyMode'; type PayloadChild = { props: { diff --git a/packages/desktop-client/src/components/reports/graphs/BarLineGraph.tsx b/packages/desktop-client/src/components/reports/graphs/BarLineGraph.tsx index 1601a63d71..79de224c8d 100644 --- a/packages/desktop-client/src/components/reports/graphs/BarLineGraph.tsx +++ b/packages/desktop-client/src/components/reports/graphs/BarLineGraph.tsx @@ -16,11 +16,11 @@ import { YAxis, } from 'recharts'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { useRechartsAnimation } from '@desktop-client/components/reports/chart-theme'; -import { Container } from '@desktop-client/components/reports/Container'; -import { numberFormatterTooltip } from '@desktop-client/components/reports/numberFormatter'; -import { useFormat } from '@desktop-client/hooks/useFormat'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { useRechartsAnimation } from '#components/reports/chart-theme'; +import { Container } from '#components/reports/Container'; +import { numberFormatterTooltip } from '#components/reports/numberFormatter'; +import { useFormat } from '#hooks/useFormat'; type PayloadItem = { payload: { diff --git a/packages/desktop-client/src/components/reports/graphs/BudgetAnalysisGraph.tsx b/packages/desktop-client/src/components/reports/graphs/BudgetAnalysisGraph.tsx index a59f794bb8..b2d3c1b442 100644 --- a/packages/desktop-client/src/components/reports/graphs/BudgetAnalysisGraph.tsx +++ b/packages/desktop-client/src/components/reports/graphs/BudgetAnalysisGraph.tsx @@ -20,12 +20,12 @@ import * as monthUtils from 'loot-core/shared/months'; import { computePadding } from './util/computePadding'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { Container } from '@desktop-client/components/reports/Container'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import type { FormatType } from '@desktop-client/hooks/useFormat'; -import { useLocale } from '@desktop-client/hooks/useLocale'; -import { usePrivacyMode } from '@desktop-client/hooks/usePrivacyMode'; +import { FinancialText } from '#components/FinancialText'; +import { Container } from '#components/reports/Container'; +import { useFormat } from '#hooks/useFormat'; +import type { FormatType } from '#hooks/useFormat'; +import { useLocale } from '#hooks/useLocale'; +import { usePrivacyMode } from '#hooks/usePrivacyMode'; /** * Interval data for the Budget Analysis graph. diff --git a/packages/desktop-client/src/components/reports/graphs/CalendarGraph.tsx b/packages/desktop-client/src/components/reports/graphs/CalendarGraph.tsx index e62ed94253..40027c4f81 100644 --- a/packages/desktop-client/src/components/reports/graphs/CalendarGraph.tsx +++ b/packages/desktop-client/src/components/reports/graphs/CalendarGraph.tsx @@ -18,10 +18,10 @@ import { import type { SyncedPrefs } from 'loot-core/types/prefs'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useResizeObserver } from '@desktop-client/hooks/useResizeObserver'; +import { FinancialText } from '#components/FinancialText'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { useFormat } from '#hooks/useFormat'; +import { useResizeObserver } from '#hooks/useResizeObserver'; type CalendarGraphProps = { data: { diff --git a/packages/desktop-client/src/components/reports/graphs/CashFlowGraph.tsx b/packages/desktop-client/src/components/reports/graphs/CashFlowGraph.tsx index 23fcfc6df8..09509140f8 100644 --- a/packages/desktop-client/src/components/reports/graphs/CashFlowGraph.tsx +++ b/packages/desktop-client/src/components/reports/graphs/CashFlowGraph.tsx @@ -17,13 +17,13 @@ import { YAxis, } from 'recharts'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { useRechartsAnimation } from '@desktop-client/components/reports/chart-theme'; -import { Container } from '@desktop-client/components/reports/Container'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import type { FormatType } from '@desktop-client/hooks/useFormat'; -import { useLocale } from '@desktop-client/hooks/useLocale'; -import { usePrivacyMode } from '@desktop-client/hooks/usePrivacyMode'; +import { FinancialText } from '#components/FinancialText'; +import { useRechartsAnimation } from '#components/reports/chart-theme'; +import { Container } from '#components/reports/Container'; +import { useFormat } from '#hooks/useFormat'; +import type { FormatType } from '#hooks/useFormat'; +import { useLocale } from '#hooks/useLocale'; +import { usePrivacyMode } from '#hooks/usePrivacyMode'; const MAX_BAR_SIZE = 50; const ANIMATION_DURATION = 1000; // in ms diff --git a/packages/desktop-client/src/components/reports/graphs/CrossoverGraph.tsx b/packages/desktop-client/src/components/reports/graphs/CrossoverGraph.tsx index f55fc9a0f3..700bca34b1 100644 --- a/packages/desktop-client/src/components/reports/graphs/CrossoverGraph.tsx +++ b/packages/desktop-client/src/components/reports/graphs/CrossoverGraph.tsx @@ -14,11 +14,11 @@ import { YAxis, } from 'recharts'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { useRechartsAnimation } from '@desktop-client/components/reports/chart-theme'; -import { Container } from '@desktop-client/components/reports/Container'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { usePrivacyMode } from '@desktop-client/hooks/usePrivacyMode'; +import { FinancialText } from '#components/FinancialText'; +import { useRechartsAnimation } from '#components/reports/chart-theme'; +import { Container } from '#components/reports/Container'; +import { useFormat } from '#hooks/useFormat'; +import { usePrivacyMode } from '#hooks/usePrivacyMode'; type PayloadItem = { payload: { diff --git a/packages/desktop-client/src/components/reports/graphs/DonutGraph.tsx b/packages/desktop-client/src/components/reports/graphs/DonutGraph.tsx index 2a7170d29a..e7bdf2c8a9 100644 --- a/packages/desktop-client/src/components/reports/graphs/DonutGraph.tsx +++ b/packages/desktop-client/src/components/reports/graphs/DonutGraph.tsx @@ -18,14 +18,14 @@ import { adjustTextSize } from './adjustTextSize'; import { renderCustomLabel } from './renderCustomLabel'; import { showActivity } from './showActivity'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { useRechartsAnimation } from '@desktop-client/components/reports/chart-theme'; -import { Container } from '@desktop-client/components/reports/Container'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; -import { useCategories } from '@desktop-client/hooks/useCategories'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; +import { FinancialText } from '#components/FinancialText'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { useRechartsAnimation } from '#components/reports/chart-theme'; +import { Container } from '#components/reports/Container'; +import { useAccounts } from '#hooks/useAccounts'; +import { useCategories } from '#hooks/useCategories'; +import { useFormat } from '#hooks/useFormat'; +import { useNavigate } from '#hooks/useNavigate'; const RADIAN = Math.PI / 180; diff --git a/packages/desktop-client/src/components/reports/graphs/LineGraph.tsx b/packages/desktop-client/src/components/reports/graphs/LineGraph.tsx index ee46a3c4a7..2c4eddc300 100644 --- a/packages/desktop-client/src/components/reports/graphs/LineGraph.tsx +++ b/packages/desktop-client/src/components/reports/graphs/LineGraph.tsx @@ -24,17 +24,17 @@ import type { import { showActivity } from './showActivity'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { useRechartsAnimation } from '@desktop-client/components/reports/chart-theme'; -import { Container } from '@desktop-client/components/reports/Container'; -import { getCustomTick } from '@desktop-client/components/reports/getCustomTick'; -import { numberFormatterTooltip } from '@desktop-client/components/reports/numberFormatter'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; -import { useCategories } from '@desktop-client/hooks/useCategories'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import type { FormatType } from '@desktop-client/hooks/useFormat'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { usePrivacyMode } from '@desktop-client/hooks/usePrivacyMode'; +import { FinancialText } from '#components/FinancialText'; +import { useRechartsAnimation } from '#components/reports/chart-theme'; +import { Container } from '#components/reports/Container'; +import { getCustomTick } from '#components/reports/getCustomTick'; +import { numberFormatterTooltip } from '#components/reports/numberFormatter'; +import { useAccounts } from '#hooks/useAccounts'; +import { useCategories } from '#hooks/useCategories'; +import { useFormat } from '#hooks/useFormat'; +import type { FormatType } from '#hooks/useFormat'; +import { useNavigate } from '#hooks/useNavigate'; +import { usePrivacyMode } from '#hooks/usePrivacyMode'; type PayloadItem = { dataKey: string; diff --git a/packages/desktop-client/src/components/reports/graphs/NetWorthGraph.tsx b/packages/desktop-client/src/components/reports/graphs/NetWorthGraph.tsx index 589e5b32f5..0c38aea3bb 100644 --- a/packages/desktop-client/src/components/reports/graphs/NetWorthGraph.tsx +++ b/packages/desktop-client/src/components/reports/graphs/NetWorthGraph.tsx @@ -20,16 +20,16 @@ import type { TooltipContentProps } from 'recharts'; import { computePadding } from './util/computePadding'; -import { FinancialText } from '@desktop-client/components/FinancialText'; +import { FinancialText } from '#components/FinancialText'; import { getColorScale, useRechartsAnimation, -} from '@desktop-client/components/reports/chart-theme'; -import { Container } from '@desktop-client/components/reports/Container'; -import { numberFormatterTooltip } from '@desktop-client/components/reports/numberFormatter'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import type { UseFormatResult } from '@desktop-client/hooks/useFormat'; -import { usePrivacyMode } from '@desktop-client/hooks/usePrivacyMode'; +} from '#components/reports/chart-theme'; +import { Container } from '#components/reports/Container'; +import { numberFormatterTooltip } from '#components/reports/numberFormatter'; +import { useFormat } from '#hooks/useFormat'; +import type { UseFormatResult } from '#hooks/useFormat'; +import { usePrivacyMode } from '#hooks/usePrivacyMode'; type NetWorthDataPoint = { x: string; diff --git a/packages/desktop-client/src/components/reports/graphs/SpendingGraph.tsx b/packages/desktop-client/src/components/reports/graphs/SpendingGraph.tsx index d271d7b780..3dddd679d9 100644 --- a/packages/desktop-client/src/components/reports/graphs/SpendingGraph.tsx +++ b/packages/desktop-client/src/components/reports/graphs/SpendingGraph.tsx @@ -19,13 +19,13 @@ import type { SpendingEntity } from 'loot-core/types/models'; import { computePadding } from './util/computePadding'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { useRechartsAnimation } from '@desktop-client/components/reports/chart-theme'; -import { Container } from '@desktop-client/components/reports/Container'; -import { numberFormatterTooltip } from '@desktop-client/components/reports/numberFormatter'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import type { FormatType } from '@desktop-client/hooks/useFormat'; -import { usePrivacyMode } from '@desktop-client/hooks/usePrivacyMode'; +import { FinancialText } from '#components/FinancialText'; +import { useRechartsAnimation } from '#components/reports/chart-theme'; +import { Container } from '#components/reports/Container'; +import { numberFormatterTooltip } from '#components/reports/numberFormatter'; +import { useFormat } from '#hooks/useFormat'; +import type { FormatType } from '#hooks/useFormat'; +import { usePrivacyMode } from '#hooks/usePrivacyMode'; type PayloadItem = { value: number; diff --git a/packages/desktop-client/src/components/reports/graphs/StackedBarGraph.tsx b/packages/desktop-client/src/components/reports/graphs/StackedBarGraph.tsx index 80a87cb820..666a092944 100644 --- a/packages/desktop-client/src/components/reports/graphs/StackedBarGraph.tsx +++ b/packages/desktop-client/src/components/reports/graphs/StackedBarGraph.tsx @@ -26,17 +26,17 @@ import type { import { renderCustomLabel } from './renderCustomLabel'; import { showActivity } from './showActivity'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { useRechartsAnimation } from '@desktop-client/components/reports/chart-theme'; -import { Container } from '@desktop-client/components/reports/Container'; -import { getCustomTick } from '@desktop-client/components/reports/getCustomTick'; -import { numberFormatterTooltip } from '@desktop-client/components/reports/numberFormatter'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; -import { useCategories } from '@desktop-client/hooks/useCategories'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import type { FormatType } from '@desktop-client/hooks/useFormat'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { usePrivacyMode } from '@desktop-client/hooks/usePrivacyMode'; +import { FinancialText } from '#components/FinancialText'; +import { useRechartsAnimation } from '#components/reports/chart-theme'; +import { Container } from '#components/reports/Container'; +import { getCustomTick } from '#components/reports/getCustomTick'; +import { numberFormatterTooltip } from '#components/reports/numberFormatter'; +import { useAccounts } from '#hooks/useAccounts'; +import { useCategories } from '#hooks/useCategories'; +import { useFormat } from '#hooks/useFormat'; +import type { FormatType } from '#hooks/useFormat'; +import { useNavigate } from '#hooks/useNavigate'; +import { usePrivacyMode } from '#hooks/usePrivacyMode'; type PayloadItem = { name: string; diff --git a/packages/desktop-client/src/components/reports/graphs/renderCustomLabel.tsx b/packages/desktop-client/src/components/reports/graphs/renderCustomLabel.tsx index 35287e2a32..8e1274f2a2 100644 --- a/packages/desktop-client/src/components/reports/graphs/renderCustomLabel.tsx +++ b/packages/desktop-client/src/components/reports/graphs/renderCustomLabel.tsx @@ -4,8 +4,8 @@ import type { SVGAttributes } from 'react'; import { theme } from '@actual-app/components/theme'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; +import { FinancialText } from '#components/FinancialText'; +import { PrivacyFilter } from '#components/PrivacyFilter'; export const renderCustomLabel = ( calcX: SVGAttributes['x'], diff --git a/packages/desktop-client/src/components/reports/graphs/showActivity.ts b/packages/desktop-client/src/components/reports/graphs/showActivity.ts index c6ef291e75..556221c98a 100644 --- a/packages/desktop-client/src/components/reports/graphs/showActivity.ts +++ b/packages/desktop-client/src/components/reports/graphs/showActivity.ts @@ -9,7 +9,7 @@ import type { RuleConditionEntity, } from 'loot-core/types/models'; -import { ReportOptions } from '@desktop-client/components/reports/ReportOptions'; +import { ReportOptions } from '#components/reports/ReportOptions'; type showActivityProps = { navigate: NavigateFunction; diff --git a/packages/desktop-client/src/components/reports/graphs/tableGraph/ReportTableHeader.tsx b/packages/desktop-client/src/components/reports/graphs/tableGraph/ReportTableHeader.tsx index 54854747ed..fd6ed8a4ae 100644 --- a/packages/desktop-client/src/components/reports/graphs/tableGraph/ReportTableHeader.tsx +++ b/packages/desktop-client/src/components/reports/graphs/tableGraph/ReportTableHeader.tsx @@ -7,8 +7,8 @@ import { View } from '@actual-app/components/view'; import type { balanceTypeOpType, IntervalEntity } from 'loot-core/types/models'; -import { ReportOptions } from '@desktop-client/components/reports/ReportOptions'; -import { Cell, Row } from '@desktop-client/components/table'; +import { ReportOptions } from '#components/reports/ReportOptions'; +import { Cell, Row } from '#components/table'; type ReportTableHeaderProps = { groupBy: string; diff --git a/packages/desktop-client/src/components/reports/graphs/tableGraph/ReportTableList.tsx b/packages/desktop-client/src/components/reports/graphs/tableGraph/ReportTableList.tsx index 4cc6ff2f08..d35e9eefe2 100644 --- a/packages/desktop-client/src/components/reports/graphs/tableGraph/ReportTableList.tsx +++ b/packages/desktop-client/src/components/reports/graphs/tableGraph/ReportTableList.tsx @@ -9,7 +9,7 @@ import type { DataEntity, GroupedEntity } from 'loot-core/types/models'; import { RenderTableRow } from './RenderTableRow'; import type { renderRowProps } from './ReportTable'; -import { Row } from '@desktop-client/components/table'; +import { Row } from '#components/table'; type ReportTableListProps = { data: DataEntity; diff --git a/packages/desktop-client/src/components/reports/graphs/tableGraph/ReportTableRow.tsx b/packages/desktop-client/src/components/reports/graphs/tableGraph/ReportTableRow.tsx index 1b8b7d4f26..3460e34bbb 100644 --- a/packages/desktop-client/src/components/reports/graphs/tableGraph/ReportTableRow.tsx +++ b/packages/desktop-client/src/components/reports/graphs/tableGraph/ReportTableRow.tsx @@ -11,13 +11,13 @@ import type { RuleConditionEntity, } from 'loot-core/types/models'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { showActivity } from '@desktop-client/components/reports/graphs/showActivity'; -import { Cell, Row } from '@desktop-client/components/table'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; -import { useCategories } from '@desktop-client/hooks/useCategories'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; +import { FinancialText } from '#components/FinancialText'; +import { showActivity } from '#components/reports/graphs/showActivity'; +import { Cell, Row } from '#components/table'; +import { useAccounts } from '#hooks/useAccounts'; +import { useCategories } from '#hooks/useCategories'; +import { useFormat } from '#hooks/useFormat'; +import { useNavigate } from '#hooks/useNavigate'; type ReportTableRowProps = { item: GroupedEntity; diff --git a/packages/desktop-client/src/components/reports/index.tsx b/packages/desktop-client/src/components/reports/index.tsx index 678fbefb07..8ad47b257b 100644 --- a/packages/desktop-client/src/components/reports/index.tsx +++ b/packages/desktop-client/src/components/reports/index.tsx @@ -2,7 +2,7 @@ import { useTranslation } from 'react-i18next'; import { View } from '@actual-app/components/view'; -import { LoadComponent } from '@desktop-client/components/util/LoadComponent'; +import { LoadComponent } from '#components/util/LoadComponent'; export function Reports() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/reports/reports/BudgetAnalysis.tsx b/packages/desktop-client/src/components/reports/reports/BudgetAnalysis.tsx index 2d37668f81..34f97eb995 100644 --- a/packages/desktop-client/src/components/reports/reports/BudgetAnalysis.tsx +++ b/packages/desktop-client/src/components/reports/reports/BudgetAnalysis.tsx @@ -21,32 +21,28 @@ import type { TimeFrame, } from 'loot-core/types/models'; -import { EditablePageHeaderTitle } from '@desktop-client/components/EditablePageHeaderTitle'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { MobileBackButton } from '@desktop-client/components/mobile/MobileBackButton'; -import { - MobilePageHeader, - Page, - PageHeader, -} from '@desktop-client/components/Page'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { Change } from '@desktop-client/components/reports/Change'; -import { BudgetAnalysisGraph } from '@desktop-client/components/reports/graphs/BudgetAnalysisGraph'; -import { Header } from '@desktop-client/components/reports/Header'; -import { LoadingIndicator } from '@desktop-client/components/reports/LoadingIndicator'; -import { calculateTimeRange } from '@desktop-client/components/reports/reportRanges'; -import { createBudgetAnalysisSpreadsheet } from '@desktop-client/components/reports/spreadsheets/budget-analysis-spreadsheet'; -import { useReport } from '@desktop-client/components/reports/useReport'; -import { fromDateRepr } from '@desktop-client/components/reports/util'; -import { useDashboardWidget } from '@desktop-client/hooks/useDashboardWidget'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useLocale } from '@desktop-client/hooks/useLocale'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { useRuleConditionFilters } from '@desktop-client/hooks/useRuleConditionFilters'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; -import { useUpdateDashboardWidgetMutation } from '@desktop-client/reports/mutations'; +import { EditablePageHeaderTitle } from '#components/EditablePageHeaderTitle'; +import { FinancialText } from '#components/FinancialText'; +import { MobileBackButton } from '#components/mobile/MobileBackButton'; +import { MobilePageHeader, Page, PageHeader } from '#components/Page'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { Change } from '#components/reports/Change'; +import { BudgetAnalysisGraph } from '#components/reports/graphs/BudgetAnalysisGraph'; +import { Header } from '#components/reports/Header'; +import { LoadingIndicator } from '#components/reports/LoadingIndicator'; +import { calculateTimeRange } from '#components/reports/reportRanges'; +import { createBudgetAnalysisSpreadsheet } from '#components/reports/spreadsheets/budget-analysis-spreadsheet'; +import { useReport } from '#components/reports/useReport'; +import { fromDateRepr } from '#components/reports/util'; +import { useDashboardWidget } from '#hooks/useDashboardWidget'; +import { useFormat } from '#hooks/useFormat'; +import { useLocale } from '#hooks/useLocale'; +import { useNavigate } from '#hooks/useNavigate'; +import { useRuleConditionFilters } from '#hooks/useRuleConditionFilters'; +import { useSyncedPref } from '#hooks/useSyncedPref'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; +import { useUpdateDashboardWidgetMutation } from '#reports/mutations'; export function BudgetAnalysis() { const params = useParams(); diff --git a/packages/desktop-client/src/components/reports/reports/BudgetAnalysisCard.tsx b/packages/desktop-client/src/components/reports/reports/BudgetAnalysisCard.tsx index a5e8fa5c28..e18b125d3a 100644 --- a/packages/desktop-client/src/components/reports/reports/BudgetAnalysisCard.tsx +++ b/packages/desktop-client/src/components/reports/reports/BudgetAnalysisCard.tsx @@ -9,18 +9,18 @@ import { View } from '@actual-app/components/view'; import * as monthUtils from 'loot-core/shared/months'; import type { BudgetAnalysisWidget } from 'loot-core/types/models'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { DateRange } from '@desktop-client/components/reports/DateRange'; -import { BudgetAnalysisGraph } from '@desktop-client/components/reports/graphs/BudgetAnalysisGraph'; -import { LoadingIndicator } from '@desktop-client/components/reports/LoadingIndicator'; -import { ReportCard } from '@desktop-client/components/reports/ReportCard'; -import { ReportCardName } from '@desktop-client/components/reports/ReportCardName'; -import { calculateTimeRange } from '@desktop-client/components/reports/reportRanges'; -import { createBudgetAnalysisSpreadsheet } from '@desktop-client/components/reports/spreadsheets/budget-analysis-spreadsheet'; -import { useDashboardWidgetCopyMenu } from '@desktop-client/components/reports/useDashboardWidgetCopyMenu'; -import { useReport } from '@desktop-client/components/reports/useReport'; -import { useFormat } from '@desktop-client/hooks/useFormat'; +import { FinancialText } from '#components/FinancialText'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { DateRange } from '#components/reports/DateRange'; +import { BudgetAnalysisGraph } from '#components/reports/graphs/BudgetAnalysisGraph'; +import { LoadingIndicator } from '#components/reports/LoadingIndicator'; +import { ReportCard } from '#components/reports/ReportCard'; +import { ReportCardName } from '#components/reports/ReportCardName'; +import { calculateTimeRange } from '#components/reports/reportRanges'; +import { createBudgetAnalysisSpreadsheet } from '#components/reports/spreadsheets/budget-analysis-spreadsheet'; +import { useDashboardWidgetCopyMenu } from '#components/reports/useDashboardWidgetCopyMenu'; +import { useReport } from '#components/reports/useReport'; +import { useFormat } from '#hooks/useFormat'; type BudgetAnalysisCardProps = { widgetId: string; diff --git a/packages/desktop-client/src/components/reports/reports/Calendar.tsx b/packages/desktop-client/src/components/reports/reports/Calendar.tsx index c5c7f91405..75c6175c98 100644 --- a/packages/desktop-client/src/components/reports/reports/Calendar.tsx +++ b/packages/desktop-client/src/components/reports/reports/Calendar.tsx @@ -31,48 +31,44 @@ import type { TransactionEntity, } from 'loot-core/types/models'; -import { EditablePageHeaderTitle } from '@desktop-client/components/EditablePageHeaderTitle'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { MobileBackButton } from '@desktop-client/components/mobile/MobileBackButton'; -import { TransactionList as TransactionListMobile } from '@desktop-client/components/mobile/transactions/TransactionList'; -import { - MobilePageHeader, - Page, - PageHeader, -} from '@desktop-client/components/Page'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { DateRange } from '@desktop-client/components/reports/DateRange'; -import { CalendarGraph } from '@desktop-client/components/reports/graphs/CalendarGraph'; -import { Header } from '@desktop-client/components/reports/Header'; -import { LoadingIndicator } from '@desktop-client/components/reports/LoadingIndicator'; -import { calculateTimeRange } from '@desktop-client/components/reports/reportRanges'; -import { calendarSpreadsheet } from '@desktop-client/components/reports/spreadsheets/calendar-spreadsheet'; -import type { CalendarDataType } from '@desktop-client/components/reports/spreadsheets/calendar-spreadsheet'; -import { useReport } from '@desktop-client/components/reports/useReport'; -import { fromDateRepr } from '@desktop-client/components/reports/util'; -import type { TableHandleRef } from '@desktop-client/components/table'; -import { TransactionList } from '@desktop-client/components/transactions/TransactionList'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; -import { SchedulesProvider } from '@desktop-client/hooks/useCachedSchedules'; -import { useCategories } from '@desktop-client/hooks/useCategories'; -import { useDashboardWidget } from '@desktop-client/hooks/useDashboardWidget'; -import { useDateFormat } from '@desktop-client/hooks/useDateFormat'; -import { DisplayPayeeProvider } from '@desktop-client/hooks/useDisplayPayee'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import type { FormatType } from '@desktop-client/hooks/useFormat'; -import { useLocale } from '@desktop-client/hooks/useLocale'; -import { useMergedRefs } from '@desktop-client/hooks/useMergedRefs'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { usePayees } from '@desktop-client/hooks/usePayees'; -import { useResizeObserver } from '@desktop-client/hooks/useResizeObserver'; -import { useRuleConditionFilters } from '@desktop-client/hooks/useRuleConditionFilters'; -import { SelectedProviderWithItems } from '@desktop-client/hooks/useSelected'; -import { SplitsExpandedProvider } from '@desktop-client/hooks/useSplitsExpanded'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; -import { useTransactions } from '@desktop-client/hooks/useTransactions'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; -import { useUpdateDashboardWidgetMutation } from '@desktop-client/reports/mutations'; +import { EditablePageHeaderTitle } from '#components/EditablePageHeaderTitle'; +import { FinancialText } from '#components/FinancialText'; +import { MobileBackButton } from '#components/mobile/MobileBackButton'; +import { TransactionList as TransactionListMobile } from '#components/mobile/transactions/TransactionList'; +import { MobilePageHeader, Page, PageHeader } from '#components/Page'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { DateRange } from '#components/reports/DateRange'; +import { CalendarGraph } from '#components/reports/graphs/CalendarGraph'; +import { Header } from '#components/reports/Header'; +import { LoadingIndicator } from '#components/reports/LoadingIndicator'; +import { calculateTimeRange } from '#components/reports/reportRanges'; +import { calendarSpreadsheet } from '#components/reports/spreadsheets/calendar-spreadsheet'; +import type { CalendarDataType } from '#components/reports/spreadsheets/calendar-spreadsheet'; +import { useReport } from '#components/reports/useReport'; +import { fromDateRepr } from '#components/reports/util'; +import type { TableHandleRef } from '#components/table'; +import { TransactionList } from '#components/transactions/TransactionList'; +import { useAccounts } from '#hooks/useAccounts'; +import { SchedulesProvider } from '#hooks/useCachedSchedules'; +import { useCategories } from '#hooks/useCategories'; +import { useDashboardWidget } from '#hooks/useDashboardWidget'; +import { useDateFormat } from '#hooks/useDateFormat'; +import { DisplayPayeeProvider } from '#hooks/useDisplayPayee'; +import { useFormat } from '#hooks/useFormat'; +import type { FormatType } from '#hooks/useFormat'; +import { useLocale } from '#hooks/useLocale'; +import { useMergedRefs } from '#hooks/useMergedRefs'; +import { useNavigate } from '#hooks/useNavigate'; +import { usePayees } from '#hooks/usePayees'; +import { useResizeObserver } from '#hooks/useResizeObserver'; +import { useRuleConditionFilters } from '#hooks/useRuleConditionFilters'; +import { SelectedProviderWithItems } from '#hooks/useSelected'; +import { SplitsExpandedProvider } from '#hooks/useSplitsExpanded'; +import { useSyncedPref } from '#hooks/useSyncedPref'; +import { useTransactions } from '#hooks/useTransactions'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; +import { useUpdateDashboardWidgetMutation } from '#reports/mutations'; const CHEVRON_HEIGHT = 42; const SUMMARY_HEIGHT = 140; diff --git a/packages/desktop-client/src/components/reports/reports/CalendarCard.tsx b/packages/desktop-client/src/components/reports/reports/CalendarCard.tsx index b2f834ba59..f4a1545fe3 100644 --- a/packages/desktop-client/src/components/reports/reports/CalendarCard.tsx +++ b/packages/desktop-client/src/components/reports/reports/CalendarCard.tsx @@ -27,23 +27,23 @@ import * as monthUtils from 'loot-core/shared/months'; import type { CalendarWidget } from 'loot-core/types/models'; import type { SyncedPrefs } from 'loot-core/types/prefs'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { DateRange } from '@desktop-client/components/reports/DateRange'; -import { CalendarGraph } from '@desktop-client/components/reports/graphs/CalendarGraph'; -import { LoadingIndicator } from '@desktop-client/components/reports/LoadingIndicator'; -import { ReportCard } from '@desktop-client/components/reports/ReportCard'; -import { ReportCardName } from '@desktop-client/components/reports/ReportCardName'; -import { calculateTimeRange } from '@desktop-client/components/reports/reportRanges'; -import { calendarSpreadsheet } from '@desktop-client/components/reports/spreadsheets/calendar-spreadsheet'; -import type { CalendarDataType } from '@desktop-client/components/reports/spreadsheets/calendar-spreadsheet'; -import { useDashboardWidgetCopyMenu } from '@desktop-client/components/reports/useDashboardWidgetCopyMenu'; -import { useReport } from '@desktop-client/components/reports/useReport'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import type { FormatType } from '@desktop-client/hooks/useFormat'; -import { useMergedRefs } from '@desktop-client/hooks/useMergedRefs'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { useResizeObserver } from '@desktop-client/hooks/useResizeObserver'; +import { FinancialText } from '#components/FinancialText'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { DateRange } from '#components/reports/DateRange'; +import { CalendarGraph } from '#components/reports/graphs/CalendarGraph'; +import { LoadingIndicator } from '#components/reports/LoadingIndicator'; +import { ReportCard } from '#components/reports/ReportCard'; +import { ReportCardName } from '#components/reports/ReportCardName'; +import { calculateTimeRange } from '#components/reports/reportRanges'; +import { calendarSpreadsheet } from '#components/reports/spreadsheets/calendar-spreadsheet'; +import type { CalendarDataType } from '#components/reports/spreadsheets/calendar-spreadsheet'; +import { useDashboardWidgetCopyMenu } from '#components/reports/useDashboardWidgetCopyMenu'; +import { useReport } from '#components/reports/useReport'; +import { useFormat } from '#hooks/useFormat'; +import type { FormatType } from '#hooks/useFormat'; +import { useMergedRefs } from '#hooks/useMergedRefs'; +import { useNavigate } from '#hooks/useNavigate'; +import { useResizeObserver } from '#hooks/useResizeObserver'; type CalendarCardProps = { widgetId: string; diff --git a/packages/desktop-client/src/components/reports/reports/CashFlow.tsx b/packages/desktop-client/src/components/reports/reports/CashFlow.tsx index df3bf3893e..6efbf72be3 100644 --- a/packages/desktop-client/src/components/reports/reports/CashFlow.tsx +++ b/packages/desktop-client/src/components/reports/reports/CashFlow.tsx @@ -20,31 +20,27 @@ import type { TimeFrame, } from 'loot-core/types/models'; -import { EditablePageHeaderTitle } from '@desktop-client/components/EditablePageHeaderTitle'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { MobileBackButton } from '@desktop-client/components/mobile/MobileBackButton'; -import { - MobilePageHeader, - Page, - PageHeader, -} from '@desktop-client/components/Page'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { Change } from '@desktop-client/components/reports/Change'; -import { CashFlowGraph } from '@desktop-client/components/reports/graphs/CashFlowGraph'; -import { Header } from '@desktop-client/components/reports/Header'; -import { LoadingIndicator } from '@desktop-client/components/reports/LoadingIndicator'; -import { calculateTimeRange } from '@desktop-client/components/reports/reportRanges'; -import { cashFlowByDate } from '@desktop-client/components/reports/spreadsheets/cash-flow-spreadsheet'; -import { useReport } from '@desktop-client/components/reports/useReport'; -import { useDashboardWidget } from '@desktop-client/hooks/useDashboardWidget'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useLocale } from '@desktop-client/hooks/useLocale'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { useRuleConditionFilters } from '@desktop-client/hooks/useRuleConditionFilters'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; -import { useUpdateDashboardWidgetMutation } from '@desktop-client/reports/mutations'; +import { EditablePageHeaderTitle } from '#components/EditablePageHeaderTitle'; +import { FinancialText } from '#components/FinancialText'; +import { MobileBackButton } from '#components/mobile/MobileBackButton'; +import { MobilePageHeader, Page, PageHeader } from '#components/Page'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { Change } from '#components/reports/Change'; +import { CashFlowGraph } from '#components/reports/graphs/CashFlowGraph'; +import { Header } from '#components/reports/Header'; +import { LoadingIndicator } from '#components/reports/LoadingIndicator'; +import { calculateTimeRange } from '#components/reports/reportRanges'; +import { cashFlowByDate } from '#components/reports/spreadsheets/cash-flow-spreadsheet'; +import { useReport } from '#components/reports/useReport'; +import { useDashboardWidget } from '#hooks/useDashboardWidget'; +import { useFormat } from '#hooks/useFormat'; +import { useLocale } from '#hooks/useLocale'; +import { useNavigate } from '#hooks/useNavigate'; +import { useRuleConditionFilters } from '#hooks/useRuleConditionFilters'; +import { useSyncedPref } from '#hooks/useSyncedPref'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; +import { useUpdateDashboardWidgetMutation } from '#reports/mutations'; export const defaultTimeFrame = { start: monthUtils.dayFromDate(monthUtils.currentMonth()), diff --git a/packages/desktop-client/src/components/reports/reports/CashFlowCard.tsx b/packages/desktop-client/src/components/reports/reports/CashFlowCard.tsx index b55c6d580a..410025e58d 100644 --- a/packages/desktop-client/src/components/reports/reports/CashFlowCard.tsx +++ b/packages/desktop-client/src/components/reports/reports/CashFlowCard.tsx @@ -12,20 +12,20 @@ import type { CashFlowWidget } from 'loot-core/types/models'; import { defaultTimeFrame } from './CashFlow'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { Change } from '@desktop-client/components/reports/Change'; -import { useRechartsAnimation } from '@desktop-client/components/reports/chart-theme'; -import { Container } from '@desktop-client/components/reports/Container'; -import { DateRange } from '@desktop-client/components/reports/DateRange'; -import { LoadingIndicator } from '@desktop-client/components/reports/LoadingIndicator'; -import { ReportCard } from '@desktop-client/components/reports/ReportCard'; -import { ReportCardName } from '@desktop-client/components/reports/ReportCardName'; -import { calculateTimeRange } from '@desktop-client/components/reports/reportRanges'; -import { simpleCashFlow } from '@desktop-client/components/reports/spreadsheets/cash-flow-spreadsheet'; -import { useDashboardWidgetCopyMenu } from '@desktop-client/components/reports/useDashboardWidgetCopyMenu'; -import { useReport } from '@desktop-client/components/reports/useReport'; -import { useFormat } from '@desktop-client/hooks/useFormat'; +import { FinancialText } from '#components/FinancialText'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { Change } from '#components/reports/Change'; +import { useRechartsAnimation } from '#components/reports/chart-theme'; +import { Container } from '#components/reports/Container'; +import { DateRange } from '#components/reports/DateRange'; +import { LoadingIndicator } from '#components/reports/LoadingIndicator'; +import { ReportCard } from '#components/reports/ReportCard'; +import { ReportCardName } from '#components/reports/ReportCardName'; +import { calculateTimeRange } from '#components/reports/reportRanges'; +import { simpleCashFlow } from '#components/reports/spreadsheets/cash-flow-spreadsheet'; +import { useDashboardWidgetCopyMenu } from '#components/reports/useDashboardWidgetCopyMenu'; +import { useReport } from '#components/reports/useReport'; +import { useFormat } from '#hooks/useFormat'; type CustomLabelProps = { value?: number; diff --git a/packages/desktop-client/src/components/reports/reports/Crossover.tsx b/packages/desktop-client/src/components/reports/reports/Crossover.tsx index b883e419eb..0fe773c411 100644 --- a/packages/desktop-client/src/components/reports/reports/Crossover.tsx +++ b/packages/desktop-client/src/components/reports/reports/Crossover.tsx @@ -23,36 +23,32 @@ import type { TimeFrame, } from 'loot-core/types/models'; -import { Link } from '@desktop-client/components/common/Link'; -import { EditablePageHeaderTitle } from '@desktop-client/components/EditablePageHeaderTitle'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { Checkbox } from '@desktop-client/components/forms'; -import { MobileBackButton } from '@desktop-client/components/mobile/MobileBackButton'; -import { - MobilePageHeader, - Page, - PageHeader, -} from '@desktop-client/components/Page'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { AccountSelector } from '@desktop-client/components/reports/AccountSelector'; -import { CategorySelector } from '@desktop-client/components/reports/CategorySelector'; -import { CrossoverGraph } from '@desktop-client/components/reports/graphs/CrossoverGraph'; -import { Header } from '@desktop-client/components/reports/Header'; -import { LoadingIndicator } from '@desktop-client/components/reports/LoadingIndicator'; -import { calculateTimeRange } from '@desktop-client/components/reports/reportRanges'; -import { createCrossoverSpreadsheet } from '@desktop-client/components/reports/spreadsheets/crossover-spreadsheet'; -import type { CrossoverData } from '@desktop-client/components/reports/spreadsheets/crossover-spreadsheet'; -import { useReport } from '@desktop-client/components/reports/useReport'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; -import { useCategories } from '@desktop-client/hooks/useCategories'; -import { useDashboardWidget } from '@desktop-client/hooks/useDashboardWidget'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useLocale } from '@desktop-client/hooks/useLocale'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import type { useSpreadsheet } from '@desktop-client/hooks/useSpreadsheet'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; -import { useUpdateDashboardWidgetMutation } from '@desktop-client/reports/mutations'; +import { Link } from '#components/common/Link'; +import { EditablePageHeaderTitle } from '#components/EditablePageHeaderTitle'; +import { FinancialText } from '#components/FinancialText'; +import { Checkbox } from '#components/forms'; +import { MobileBackButton } from '#components/mobile/MobileBackButton'; +import { MobilePageHeader, Page, PageHeader } from '#components/Page'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { AccountSelector } from '#components/reports/AccountSelector'; +import { CategorySelector } from '#components/reports/CategorySelector'; +import { CrossoverGraph } from '#components/reports/graphs/CrossoverGraph'; +import { Header } from '#components/reports/Header'; +import { LoadingIndicator } from '#components/reports/LoadingIndicator'; +import { calculateTimeRange } from '#components/reports/reportRanges'; +import { createCrossoverSpreadsheet } from '#components/reports/spreadsheets/crossover-spreadsheet'; +import type { CrossoverData } from '#components/reports/spreadsheets/crossover-spreadsheet'; +import { useReport } from '#components/reports/useReport'; +import { useAccounts } from '#hooks/useAccounts'; +import { useCategories } from '#hooks/useCategories'; +import { useDashboardWidget } from '#hooks/useDashboardWidget'; +import { useFormat } from '#hooks/useFormat'; +import { useLocale } from '#hooks/useLocale'; +import { useNavigate } from '#hooks/useNavigate'; +import type { useSpreadsheet } from '#hooks/useSpreadsheet'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; +import { useUpdateDashboardWidgetMutation } from '#reports/mutations'; export const defaultTimeFrame = { start: monthUtils.subMonths(monthUtils.currentMonth(), 120), diff --git a/packages/desktop-client/src/components/reports/reports/CrossoverCard.tsx b/packages/desktop-client/src/components/reports/reports/CrossoverCard.tsx index f0d824c155..0286541791 100644 --- a/packages/desktop-client/src/components/reports/reports/CrossoverCard.tsx +++ b/packages/desktop-client/src/components/reports/reports/CrossoverCard.tsx @@ -11,18 +11,18 @@ import { send } from 'loot-core/platform/client/connection'; import * as monthUtils from 'loot-core/shared/months'; import type { AccountEntity, CrossoverWidget } from 'loot-core/types/models'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { CrossoverGraph } from '@desktop-client/components/reports/graphs/CrossoverGraph'; -import { LoadingIndicator } from '@desktop-client/components/reports/LoadingIndicator'; -import { ReportCard } from '@desktop-client/components/reports/ReportCard'; -import { ReportCardName } from '@desktop-client/components/reports/ReportCardName'; -import { calculateTimeRange } from '@desktop-client/components/reports/reportRanges'; -import { createCrossoverSpreadsheet } from '@desktop-client/components/reports/spreadsheets/crossover-spreadsheet'; -import type { CrossoverData } from '@desktop-client/components/reports/spreadsheets/crossover-spreadsheet'; -import { useDashboardWidgetCopyMenu } from '@desktop-client/components/reports/useDashboardWidgetCopyMenu'; -import { useReport } from '@desktop-client/components/reports/useReport'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useLocale } from '@desktop-client/hooks/useLocale'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { CrossoverGraph } from '#components/reports/graphs/CrossoverGraph'; +import { LoadingIndicator } from '#components/reports/LoadingIndicator'; +import { ReportCard } from '#components/reports/ReportCard'; +import { ReportCardName } from '#components/reports/ReportCardName'; +import { calculateTimeRange } from '#components/reports/reportRanges'; +import { createCrossoverSpreadsheet } from '#components/reports/spreadsheets/crossover-spreadsheet'; +import type { CrossoverData } from '#components/reports/spreadsheets/crossover-spreadsheet'; +import { useDashboardWidgetCopyMenu } from '#components/reports/useDashboardWidgetCopyMenu'; +import { useReport } from '#components/reports/useReport'; +import { useFormat } from '#hooks/useFormat'; +import { useLocale } from '#hooks/useLocale'; type CrossoverCardProps = { widgetId: string; diff --git a/packages/desktop-client/src/components/reports/reports/CustomReport.tsx b/packages/desktop-client/src/components/reports/reports/CustomReport.tsx index a1191e6fe3..b6be5a74ae 100644 --- a/packages/desktop-client/src/components/reports/reports/CustomReport.tsx +++ b/packages/desktop-client/src/components/reports/reports/CustomReport.tsx @@ -24,54 +24,47 @@ import type { } from 'loot-core/types/models'; import type { TransObjectLiteral } from 'loot-core/types/util'; -import { Warning } from '@desktop-client/components/alerts'; -import { AppliedFilters } from '@desktop-client/components/filters/AppliedFilters'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { MobileBackButton } from '@desktop-client/components/mobile/MobileBackButton'; -import { - MobilePageHeader, - Page, - PageHeader, -} from '@desktop-client/components/Page'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { ChooseGraph } from '@desktop-client/components/reports/ChooseGraph'; +import { Warning } from '#components/alerts'; +import { AppliedFilters } from '#components/filters/AppliedFilters'; +import { FinancialText } from '#components/FinancialText'; +import { MobileBackButton } from '#components/mobile/MobileBackButton'; +import { MobilePageHeader, Page, PageHeader } from '#components/Page'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { ChooseGraph } from '#components/reports/ChooseGraph'; import { defaultsGraphList, defaultsList, disabledGraphList, disabledLegendLabel, disabledList, -} from '@desktop-client/components/reports/disabledList'; -import { getLiveRange } from '@desktop-client/components/reports/getLiveRange'; -import { LoadingIndicator } from '@desktop-client/components/reports/LoadingIndicator'; -import { ReportLegend } from '@desktop-client/components/reports/ReportLegend'; +} from '#components/reports/disabledList'; +import { getLiveRange } from '#components/reports/getLiveRange'; +import { LoadingIndicator } from '#components/reports/LoadingIndicator'; +import { ReportLegend } from '#components/reports/ReportLegend'; import { defaultReport, ReportOptions, -} from '@desktop-client/components/reports/ReportOptions'; -import type { dateRangeProps } from '@desktop-client/components/reports/ReportOptions'; -import { ReportSidebar } from '@desktop-client/components/reports/ReportSidebar'; -import { ReportSummary } from '@desktop-client/components/reports/ReportSummary'; -import { ReportTopbar } from '@desktop-client/components/reports/ReportTopbar'; -import type { SavedStatus } from '@desktop-client/components/reports/SaveReportMenu'; -import { setSessionReport } from '@desktop-client/components/reports/setSessionReport'; -import { createCustomSpreadsheet } from '@desktop-client/components/reports/spreadsheets/custom-spreadsheet'; -import { createGroupedSpreadsheet } from '@desktop-client/components/reports/spreadsheets/grouped-spreadsheet'; -import { useReport } from '@desktop-client/components/reports/useReport'; -import { - calculateHasWarning, - fromDateRepr, -} from '@desktop-client/components/reports/util'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; -import { useCategories } from '@desktop-client/hooks/useCategories'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useLocale } from '@desktop-client/hooks/useLocale'; -import { useLocalPref } from '@desktop-client/hooks/useLocalPref'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { usePayees } from '@desktop-client/hooks/usePayees'; -import { useReport as useCustomReport } from '@desktop-client/hooks/useReport'; -import { useRuleConditionFilters } from '@desktop-client/hooks/useRuleConditionFilters'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; +} from '#components/reports/ReportOptions'; +import type { dateRangeProps } from '#components/reports/ReportOptions'; +import { ReportSidebar } from '#components/reports/ReportSidebar'; +import { ReportSummary } from '#components/reports/ReportSummary'; +import { ReportTopbar } from '#components/reports/ReportTopbar'; +import type { SavedStatus } from '#components/reports/SaveReportMenu'; +import { setSessionReport } from '#components/reports/setSessionReport'; +import { createCustomSpreadsheet } from '#components/reports/spreadsheets/custom-spreadsheet'; +import { createGroupedSpreadsheet } from '#components/reports/spreadsheets/grouped-spreadsheet'; +import { useReport } from '#components/reports/useReport'; +import { calculateHasWarning, fromDateRepr } from '#components/reports/util'; +import { useAccounts } from '#hooks/useAccounts'; +import { useCategories } from '#hooks/useCategories'; +import { useFormat } from '#hooks/useFormat'; +import { useLocale } from '#hooks/useLocale'; +import { useLocalPref } from '#hooks/useLocalPref'; +import { useNavigate } from '#hooks/useNavigate'; +import { usePayees } from '#hooks/usePayees'; +import { useReport as useCustomReport } from '#hooks/useReport'; +import { useRuleConditionFilters } from '#hooks/useRuleConditionFilters'; +import { useSyncedPref } from '#hooks/useSyncedPref'; /** * Transform `selectedCategories` into `conditions`. diff --git a/packages/desktop-client/src/components/reports/reports/CustomReportListCards.tsx b/packages/desktop-client/src/components/reports/reports/CustomReportListCards.tsx index 98e7138448..6d15700c7d 100644 --- a/packages/desktop-client/src/components/reports/reports/CustomReportListCards.tsx +++ b/packages/desktop-client/src/components/reports/reports/CustomReportListCards.tsx @@ -15,18 +15,18 @@ import type { CustomReportEntity } from 'loot-core/types/models'; import { GetCardData } from './GetCardData'; import { MissingReportCard } from './MissingReportCard'; -import { DateRange } from '@desktop-client/components/reports/DateRange'; -import { ReportCard } from '@desktop-client/components/reports/ReportCard'; -import { ReportCardName } from '@desktop-client/components/reports/ReportCardName'; -import { useDashboardWidgetCopyMenu } from '@desktop-client/components/reports/useDashboardWidgetCopyMenu'; -import { calculateHasWarning } from '@desktop-client/components/reports/util'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; -import { useCategories } from '@desktop-client/hooks/useCategories'; -import { usePayees } from '@desktop-client/hooks/usePayees'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; -import { useUpdateReportMutation } from '@desktop-client/reports/mutations'; +import { DateRange } from '#components/reports/DateRange'; +import { ReportCard } from '#components/reports/ReportCard'; +import { ReportCardName } from '#components/reports/ReportCardName'; +import { useDashboardWidgetCopyMenu } from '#components/reports/useDashboardWidgetCopyMenu'; +import { calculateHasWarning } from '#components/reports/util'; +import { useAccounts } from '#hooks/useAccounts'; +import { useCategories } from '#hooks/useCategories'; +import { usePayees } from '#hooks/usePayees'; +import { useSyncedPref } from '#hooks/useSyncedPref'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; +import { useUpdateReportMutation } from '#reports/mutations'; type CustomReportListCardsProps = { isEditing?: boolean; diff --git a/packages/desktop-client/src/components/reports/reports/Formula.tsx b/packages/desktop-client/src/components/reports/reports/Formula.tsx index 8b0b825a3d..e029e410ea 100644 --- a/packages/desktop-client/src/components/reports/reports/Formula.tsx +++ b/packages/desktop-client/src/components/reports/reports/Formula.tsx @@ -13,23 +13,19 @@ import { View } from '@actual-app/components/view'; import type { FormulaWidget } from 'loot-core/types/models'; -import { EditablePageHeaderTitle } from '@desktop-client/components/EditablePageHeaderTitle'; -import { QueryManager } from '@desktop-client/components/formula/QueryManager'; -import { MobileBackButton } from '@desktop-client/components/mobile/MobileBackButton'; -import { - MobilePageHeader, - Page, - PageHeader, -} from '@desktop-client/components/Page'; -import { FormulaResult } from '@desktop-client/components/reports/FormulaResult'; -import { LoadingIndicator } from '@desktop-client/components/reports/LoadingIndicator'; -import { useDashboardWidget } from '@desktop-client/hooks/useDashboardWidget'; -import { useFormulaExecution } from '@desktop-client/hooks/useFormulaExecution'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { useThemeColors } from '@desktop-client/hooks/useThemeColors'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; -import { useUpdateDashboardWidgetMutation } from '@desktop-client/reports/mutations'; +import { EditablePageHeaderTitle } from '#components/EditablePageHeaderTitle'; +import { QueryManager } from '#components/formula/QueryManager'; +import { MobileBackButton } from '#components/mobile/MobileBackButton'; +import { MobilePageHeader, Page, PageHeader } from '#components/Page'; +import { FormulaResult } from '#components/reports/FormulaResult'; +import { LoadingIndicator } from '#components/reports/LoadingIndicator'; +import { useDashboardWidget } from '#hooks/useDashboardWidget'; +import { useFormulaExecution } from '#hooks/useFormulaExecution'; +import { useNavigate } from '#hooks/useNavigate'; +import { useThemeColors } from '#hooks/useThemeColors'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; +import { useUpdateDashboardWidgetMutation } from '#reports/mutations'; const FormulaEditor = lazy(() => import('../../formula/FormulaEditor').then(module => ({ diff --git a/packages/desktop-client/src/components/reports/reports/FormulaCard.tsx b/packages/desktop-client/src/components/reports/reports/FormulaCard.tsx index 46c80c5c9a..348f0e7994 100644 --- a/packages/desktop-client/src/components/reports/reports/FormulaCard.tsx +++ b/packages/desktop-client/src/components/reports/reports/FormulaCard.tsx @@ -5,12 +5,12 @@ import { View } from '@actual-app/components/view'; import type { FormulaWidget } from 'loot-core/types/models'; -import { FormulaResult } from '@desktop-client/components/reports/FormulaResult'; -import { ReportCard } from '@desktop-client/components/reports/ReportCard'; -import { ReportCardName } from '@desktop-client/components/reports/ReportCardName'; -import { useDashboardWidgetCopyMenu } from '@desktop-client/components/reports/useDashboardWidgetCopyMenu'; -import { useFormulaExecution } from '@desktop-client/hooks/useFormulaExecution'; -import { useThemeColors } from '@desktop-client/hooks/useThemeColors'; +import { FormulaResult } from '#components/reports/FormulaResult'; +import { ReportCard } from '#components/reports/ReportCard'; +import { ReportCardName } from '#components/reports/ReportCardName'; +import { useDashboardWidgetCopyMenu } from '#components/reports/useDashboardWidgetCopyMenu'; +import { useFormulaExecution } from '#hooks/useFormulaExecution'; +import { useThemeColors } from '#hooks/useThemeColors'; type FormulaCardProps = { widgetId: string; diff --git a/packages/desktop-client/src/components/reports/reports/GetCardData.tsx b/packages/desktop-client/src/components/reports/reports/GetCardData.tsx index 23c48f5a81..540c1cc688 100644 --- a/packages/desktop-client/src/components/reports/reports/GetCardData.tsx +++ b/packages/desktop-client/src/components/reports/reports/GetCardData.tsx @@ -17,13 +17,13 @@ import type { } from 'loot-core/types/models'; import type { SyncedPrefs } from 'loot-core/types/prefs'; -import { ChooseGraph } from '@desktop-client/components/reports/ChooseGraph'; -import { getLiveRange } from '@desktop-client/components/reports/getLiveRange'; -import { LoadingIndicator } from '@desktop-client/components/reports/LoadingIndicator'; -import { ReportOptions } from '@desktop-client/components/reports/ReportOptions'; -import { createCustomSpreadsheet } from '@desktop-client/components/reports/spreadsheets/custom-spreadsheet'; -import { createGroupedSpreadsheet } from '@desktop-client/components/reports/spreadsheets/grouped-spreadsheet'; -import { useReport } from '@desktop-client/components/reports/useReport'; +import { ChooseGraph } from '#components/reports/ChooseGraph'; +import { getLiveRange } from '#components/reports/getLiveRange'; +import { LoadingIndicator } from '#components/reports/LoadingIndicator'; +import { ReportOptions } from '#components/reports/ReportOptions'; +import { createCustomSpreadsheet } from '#components/reports/spreadsheets/custom-spreadsheet'; +import { createGroupedSpreadsheet } from '#components/reports/spreadsheets/grouped-spreadsheet'; +import { useReport } from '#components/reports/useReport'; function ErrorFallback() { return ( diff --git a/packages/desktop-client/src/components/reports/reports/MarkdownCard.tsx b/packages/desktop-client/src/components/reports/reports/MarkdownCard.tsx index f8596bda38..0e089ad847 100644 --- a/packages/desktop-client/src/components/reports/reports/MarkdownCard.tsx +++ b/packages/desktop-client/src/components/reports/reports/MarkdownCard.tsx @@ -13,14 +13,14 @@ import remarkGfm from 'remark-gfm'; import type { MarkdownWidget } from 'loot-core/types/models'; -import { NON_DRAGGABLE_AREA_CLASS_NAME } from '@desktop-client/components/reports/constants'; -import { ReportCard } from '@desktop-client/components/reports/ReportCard'; -import { useDashboardWidgetCopyMenu } from '@desktop-client/components/reports/useDashboardWidgetCopyMenu'; +import { NON_DRAGGABLE_AREA_CLASS_NAME } from '#components/reports/constants'; +import { ReportCard } from '#components/reports/ReportCard'; +import { useDashboardWidgetCopyMenu } from '#components/reports/useDashboardWidgetCopyMenu'; import { markdownBaseStyles, remarkBreaks, sequentialNewlinesPlugin, -} from '@desktop-client/util/markdown'; +} from '#util/markdown'; const remarkPlugins = [sequentialNewlinesPlugin, remarkGfm, remarkBreaks]; diff --git a/packages/desktop-client/src/components/reports/reports/MissingReportCard.tsx b/packages/desktop-client/src/components/reports/reports/MissingReportCard.tsx index 9d70066d6c..01cc48f19e 100644 --- a/packages/desktop-client/src/components/reports/reports/MissingReportCard.tsx +++ b/packages/desktop-client/src/components/reports/reports/MissingReportCard.tsx @@ -4,7 +4,7 @@ import { useTranslation } from 'react-i18next'; import { View } from '@actual-app/components/view'; -import { ReportCard } from '@desktop-client/components/reports/ReportCard'; +import { ReportCard } from '#components/reports/ReportCard'; type MissingReportCardProps = { isEditing?: boolean; diff --git a/packages/desktop-client/src/components/reports/reports/NetWorth.tsx b/packages/desktop-client/src/components/reports/reports/NetWorth.tsx index 6a0bb6ff4b..ae98b3a2e9 100644 --- a/packages/desktop-client/src/components/reports/reports/NetWorth.tsx +++ b/packages/desktop-client/src/components/reports/reports/NetWorth.tsx @@ -23,34 +23,30 @@ import { send } from 'loot-core/platform/client/connection'; import * as monthUtils from 'loot-core/shared/months'; import type { NetWorthWidget, TimeFrame } from 'loot-core/types/models'; -import { EditablePageHeaderTitle } from '@desktop-client/components/EditablePageHeaderTitle'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { MobileBackButton } from '@desktop-client/components/mobile/MobileBackButton'; -import { - MobilePageHeader, - Page, - PageHeader, -} from '@desktop-client/components/Page'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { Change } from '@desktop-client/components/reports/Change'; -import { NetWorthGraph } from '@desktop-client/components/reports/graphs/NetWorthGraph'; -import { Header } from '@desktop-client/components/reports/Header'; -import { LoadingIndicator } from '@desktop-client/components/reports/LoadingIndicator'; -import { ReportOptions } from '@desktop-client/components/reports/ReportOptions'; -import { calculateTimeRange } from '@desktop-client/components/reports/reportRanges'; -import { createSpreadsheet as netWorthSpreadsheet } from '@desktop-client/components/reports/spreadsheets/net-worth-spreadsheet'; -import { useReport } from '@desktop-client/components/reports/useReport'; -import { fromDateRepr } from '@desktop-client/components/reports/util'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; -import { useDashboardWidget } from '@desktop-client/hooks/useDashboardWidget'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useLocale } from '@desktop-client/hooks/useLocale'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { useRuleConditionFilters } from '@desktop-client/hooks/useRuleConditionFilters'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; -import { useUpdateDashboardWidgetMutation } from '@desktop-client/reports/mutations'; +import { EditablePageHeaderTitle } from '#components/EditablePageHeaderTitle'; +import { FinancialText } from '#components/FinancialText'; +import { MobileBackButton } from '#components/mobile/MobileBackButton'; +import { MobilePageHeader, Page, PageHeader } from '#components/Page'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { Change } from '#components/reports/Change'; +import { NetWorthGraph } from '#components/reports/graphs/NetWorthGraph'; +import { Header } from '#components/reports/Header'; +import { LoadingIndicator } from '#components/reports/LoadingIndicator'; +import { ReportOptions } from '#components/reports/ReportOptions'; +import { calculateTimeRange } from '#components/reports/reportRanges'; +import { createSpreadsheet as netWorthSpreadsheet } from '#components/reports/spreadsheets/net-worth-spreadsheet'; +import { useReport } from '#components/reports/useReport'; +import { fromDateRepr } from '#components/reports/util'; +import { useAccounts } from '#hooks/useAccounts'; +import { useDashboardWidget } from '#hooks/useDashboardWidget'; +import { useFormat } from '#hooks/useFormat'; +import { useLocale } from '#hooks/useLocale'; +import { useNavigate } from '#hooks/useNavigate'; +import { useRuleConditionFilters } from '#hooks/useRuleConditionFilters'; +import { useSyncedPref } from '#hooks/useSyncedPref'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; +import { useUpdateDashboardWidgetMutation } from '#reports/mutations'; export function NetWorth() { const params = useParams(); diff --git a/packages/desktop-client/src/components/reports/reports/NetWorthCard.tsx b/packages/desktop-client/src/components/reports/reports/NetWorthCard.tsx index 8198328003..d3843611fd 100644 --- a/packages/desktop-client/src/components/reports/reports/NetWorthCard.tsx +++ b/packages/desktop-client/src/components/reports/reports/NetWorthCard.tsx @@ -10,21 +10,21 @@ import { send } from 'loot-core/platform/client/connection'; import * as monthUtils from 'loot-core/shared/months'; import type { AccountEntity, NetWorthWidget } from 'loot-core/types/models'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { Change } from '@desktop-client/components/reports/Change'; -import { DateRange } from '@desktop-client/components/reports/DateRange'; -import { NetWorthGraph } from '@desktop-client/components/reports/graphs/NetWorthGraph'; -import { LoadingIndicator } from '@desktop-client/components/reports/LoadingIndicator'; -import { ReportCard } from '@desktop-client/components/reports/ReportCard'; -import { ReportCardName } from '@desktop-client/components/reports/ReportCardName'; -import { calculateTimeRange } from '@desktop-client/components/reports/reportRanges'; -import { createSpreadsheet as netWorthSpreadsheet } from '@desktop-client/components/reports/spreadsheets/net-worth-spreadsheet'; -import { useDashboardWidgetCopyMenu } from '@desktop-client/components/reports/useDashboardWidgetCopyMenu'; -import { useReport } from '@desktop-client/components/reports/useReport'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useLocale } from '@desktop-client/hooks/useLocale'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; +import { FinancialText } from '#components/FinancialText'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { Change } from '#components/reports/Change'; +import { DateRange } from '#components/reports/DateRange'; +import { NetWorthGraph } from '#components/reports/graphs/NetWorthGraph'; +import { LoadingIndicator } from '#components/reports/LoadingIndicator'; +import { ReportCard } from '#components/reports/ReportCard'; +import { ReportCardName } from '#components/reports/ReportCardName'; +import { calculateTimeRange } from '#components/reports/reportRanges'; +import { createSpreadsheet as netWorthSpreadsheet } from '#components/reports/spreadsheets/net-worth-spreadsheet'; +import { useDashboardWidgetCopyMenu } from '#components/reports/useDashboardWidgetCopyMenu'; +import { useReport } from '#components/reports/useReport'; +import { useFormat } from '#hooks/useFormat'; +import { useLocale } from '#hooks/useLocale'; +import { useSyncedPref } from '#hooks/useSyncedPref'; type NetWorthCardProps = { widgetId: string; diff --git a/packages/desktop-client/src/components/reports/reports/Spending.tsx b/packages/desktop-client/src/components/reports/reports/Spending.tsx index a4acea58c7..ca378c7648 100644 --- a/packages/desktop-client/src/components/reports/reports/Spending.tsx +++ b/packages/desktop-client/src/components/reports/reports/Spending.tsx @@ -23,32 +23,28 @@ import type { SpendingWidget, } from 'loot-core/types/models'; -import { EditablePageHeaderTitle } from '@desktop-client/components/EditablePageHeaderTitle'; -import { AppliedFilters } from '@desktop-client/components/filters/AppliedFilters'; -import { FilterButton } from '@desktop-client/components/filters/FiltersMenu'; -import { MobileBackButton } from '@desktop-client/components/mobile/MobileBackButton'; -import { - MobilePageHeader, - Page, - PageHeader, -} from '@desktop-client/components/Page'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { SpendingGraph } from '@desktop-client/components/reports/graphs/SpendingGraph'; -import { LegendItem } from '@desktop-client/components/reports/LegendItem'; -import { LoadingIndicator } from '@desktop-client/components/reports/LoadingIndicator'; -import { ModeButton } from '@desktop-client/components/reports/ModeButton'; -import { calculateSpendingReportTimeRange } from '@desktop-client/components/reports/reportRanges'; -import { createSpendingSpreadsheet } from '@desktop-client/components/reports/spreadsheets/spending-spreadsheet'; -import { useReport } from '@desktop-client/components/reports/useReport'; -import { fromDateRepr } from '@desktop-client/components/reports/util'; -import { useDashboardWidget } from '@desktop-client/hooks/useDashboardWidget'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useLocale } from '@desktop-client/hooks/useLocale'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { useRuleConditionFilters } from '@desktop-client/hooks/useRuleConditionFilters'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; -import { useUpdateDashboardWidgetMutation } from '@desktop-client/reports/mutations'; +import { EditablePageHeaderTitle } from '#components/EditablePageHeaderTitle'; +import { AppliedFilters } from '#components/filters/AppliedFilters'; +import { FilterButton } from '#components/filters/FiltersMenu'; +import { MobileBackButton } from '#components/mobile/MobileBackButton'; +import { MobilePageHeader, Page, PageHeader } from '#components/Page'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { SpendingGraph } from '#components/reports/graphs/SpendingGraph'; +import { LegendItem } from '#components/reports/LegendItem'; +import { LoadingIndicator } from '#components/reports/LoadingIndicator'; +import { ModeButton } from '#components/reports/ModeButton'; +import { calculateSpendingReportTimeRange } from '#components/reports/reportRanges'; +import { createSpendingSpreadsheet } from '#components/reports/spreadsheets/spending-spreadsheet'; +import { useReport } from '#components/reports/useReport'; +import { fromDateRepr } from '#components/reports/util'; +import { useDashboardWidget } from '#hooks/useDashboardWidget'; +import { useFormat } from '#hooks/useFormat'; +import { useLocale } from '#hooks/useLocale'; +import { useNavigate } from '#hooks/useNavigate'; +import { useRuleConditionFilters } from '#hooks/useRuleConditionFilters'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; +import { useUpdateDashboardWidgetMutation } from '#reports/mutations'; export function Spending() { const params = useParams(); diff --git a/packages/desktop-client/src/components/reports/reports/SpendingCard.tsx b/packages/desktop-client/src/components/reports/reports/SpendingCard.tsx index 0c30150f60..d51b42d6be 100644 --- a/packages/desktop-client/src/components/reports/reports/SpendingCard.tsx +++ b/packages/desktop-client/src/components/reports/reports/SpendingCard.tsx @@ -9,18 +9,18 @@ import { View } from '@actual-app/components/view'; import * as monthUtils from 'loot-core/shared/months'; import type { SpendingWidget } from 'loot-core/types/models'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { DateRange } from '@desktop-client/components/reports/DateRange'; -import { SpendingGraph } from '@desktop-client/components/reports/graphs/SpendingGraph'; -import { LoadingIndicator } from '@desktop-client/components/reports/LoadingIndicator'; -import { ReportCard } from '@desktop-client/components/reports/ReportCard'; -import { ReportCardName } from '@desktop-client/components/reports/ReportCardName'; -import { calculateSpendingReportTimeRange } from '@desktop-client/components/reports/reportRanges'; -import { createSpendingSpreadsheet } from '@desktop-client/components/reports/spreadsheets/spending-spreadsheet'; -import { useDashboardWidgetCopyMenu } from '@desktop-client/components/reports/useDashboardWidgetCopyMenu'; -import { useReport } from '@desktop-client/components/reports/useReport'; -import { useFormat } from '@desktop-client/hooks/useFormat'; +import { FinancialText } from '#components/FinancialText'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { DateRange } from '#components/reports/DateRange'; +import { SpendingGraph } from '#components/reports/graphs/SpendingGraph'; +import { LoadingIndicator } from '#components/reports/LoadingIndicator'; +import { ReportCard } from '#components/reports/ReportCard'; +import { ReportCardName } from '#components/reports/ReportCardName'; +import { calculateSpendingReportTimeRange } from '#components/reports/reportRanges'; +import { createSpendingSpreadsheet } from '#components/reports/spreadsheets/spending-spreadsheet'; +import { useDashboardWidgetCopyMenu } from '#components/reports/useDashboardWidgetCopyMenu'; +import { useReport } from '#components/reports/useReport'; +import { useFormat } from '#hooks/useFormat'; type SpendingCardProps = { widgetId: string; diff --git a/packages/desktop-client/src/components/reports/reports/Summary.tsx b/packages/desktop-client/src/components/reports/reports/Summary.tsx index 1534aafd4d..74dbfd89a0 100644 --- a/packages/desktop-client/src/components/reports/reports/Summary.tsx +++ b/packages/desktop-client/src/components/reports/reports/Summary.tsx @@ -24,34 +24,30 @@ import type { TimeFrame, } from 'loot-core/types/models'; -import { EditablePageHeaderTitle } from '@desktop-client/components/EditablePageHeaderTitle'; -import { AppliedFilters } from '@desktop-client/components/filters/AppliedFilters'; -import { FilterButton } from '@desktop-client/components/filters/FiltersMenu'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { Checkbox } from '@desktop-client/components/forms'; -import { MobileBackButton } from '@desktop-client/components/mobile/MobileBackButton'; -import { - MobilePageHeader, - Page, - PageHeader, -} from '@desktop-client/components/Page'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { Header } from '@desktop-client/components/reports/Header'; -import { LoadingIndicator } from '@desktop-client/components/reports/LoadingIndicator'; -import { calculateTimeRange } from '@desktop-client/components/reports/reportRanges'; -import { summarySpreadsheet } from '@desktop-client/components/reports/spreadsheets/summary-spreadsheet'; -import { useReport } from '@desktop-client/components/reports/useReport'; -import { fromDateRepr } from '@desktop-client/components/reports/util'; -import { FieldSelect } from '@desktop-client/components/rules/RuleEditor'; -import { useDashboardWidget } from '@desktop-client/hooks/useDashboardWidget'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useLocale } from '@desktop-client/hooks/useLocale'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { useRuleConditionFilters } from '@desktop-client/hooks/useRuleConditionFilters'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; -import { useUpdateDashboardWidgetMutation } from '@desktop-client/reports/mutations'; +import { EditablePageHeaderTitle } from '#components/EditablePageHeaderTitle'; +import { AppliedFilters } from '#components/filters/AppliedFilters'; +import { FilterButton } from '#components/filters/FiltersMenu'; +import { FinancialText } from '#components/FinancialText'; +import { Checkbox } from '#components/forms'; +import { MobileBackButton } from '#components/mobile/MobileBackButton'; +import { MobilePageHeader, Page, PageHeader } from '#components/Page'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { Header } from '#components/reports/Header'; +import { LoadingIndicator } from '#components/reports/LoadingIndicator'; +import { calculateTimeRange } from '#components/reports/reportRanges'; +import { summarySpreadsheet } from '#components/reports/spreadsheets/summary-spreadsheet'; +import { useReport } from '#components/reports/useReport'; +import { fromDateRepr } from '#components/reports/util'; +import { FieldSelect } from '#components/rules/RuleEditor'; +import { useDashboardWidget } from '#hooks/useDashboardWidget'; +import { useFormat } from '#hooks/useFormat'; +import { useLocale } from '#hooks/useLocale'; +import { useNavigate } from '#hooks/useNavigate'; +import { useRuleConditionFilters } from '#hooks/useRuleConditionFilters'; +import { useSyncedPref } from '#hooks/useSyncedPref'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; +import { useUpdateDashboardWidgetMutation } from '#reports/mutations'; export function Summary() { const params = useParams(); diff --git a/packages/desktop-client/src/components/reports/reports/SummaryCard.tsx b/packages/desktop-client/src/components/reports/reports/SummaryCard.tsx index 70d995f4a6..fbc8044da7 100644 --- a/packages/desktop-client/src/components/reports/reports/SummaryCard.tsx +++ b/packages/desktop-client/src/components/reports/reports/SummaryCard.tsx @@ -7,16 +7,16 @@ import { send } from 'loot-core/platform/client/connection'; import * as monthUtils from 'loot-core/shared/months'; import type { SummaryContent, SummaryWidget } from 'loot-core/types/models'; -import { DateRange } from '@desktop-client/components/reports/DateRange'; -import { LoadingIndicator } from '@desktop-client/components/reports/LoadingIndicator'; -import { ReportCard } from '@desktop-client/components/reports/ReportCard'; -import { ReportCardName } from '@desktop-client/components/reports/ReportCardName'; -import { calculateTimeRange } from '@desktop-client/components/reports/reportRanges'; -import { summarySpreadsheet } from '@desktop-client/components/reports/spreadsheets/summary-spreadsheet'; -import { SummaryNumber } from '@desktop-client/components/reports/SummaryNumber'; -import { useDashboardWidgetCopyMenu } from '@desktop-client/components/reports/useDashboardWidgetCopyMenu'; -import { useReport } from '@desktop-client/components/reports/useReport'; -import { useLocale } from '@desktop-client/hooks/useLocale'; +import { DateRange } from '#components/reports/DateRange'; +import { LoadingIndicator } from '#components/reports/LoadingIndicator'; +import { ReportCard } from '#components/reports/ReportCard'; +import { ReportCardName } from '#components/reports/ReportCardName'; +import { calculateTimeRange } from '#components/reports/reportRanges'; +import { summarySpreadsheet } from '#components/reports/spreadsheets/summary-spreadsheet'; +import { SummaryNumber } from '#components/reports/SummaryNumber'; +import { useDashboardWidgetCopyMenu } from '#components/reports/useDashboardWidgetCopyMenu'; +import { useReport } from '#components/reports/useReport'; +import { useLocale } from '#hooks/useLocale'; type SummaryCardProps = { widgetId: string; diff --git a/packages/desktop-client/src/components/reports/spreadsheets/budget-analysis-spreadsheet.ts b/packages/desktop-client/src/components/reports/spreadsheets/budget-analysis-spreadsheet.ts index c253c02f81..72953898d8 100644 --- a/packages/desktop-client/src/components/reports/spreadsheets/budget-analysis-spreadsheet.ts +++ b/packages/desktop-client/src/components/reports/spreadsheets/budget-analysis-spreadsheet.ts @@ -6,7 +6,7 @@ import type { RuleConditionEntity, } from 'loot-core/types/models'; -import type { useSpreadsheet } from '@desktop-client/hooks/useSpreadsheet'; +import type { useSpreadsheet } from '#hooks/useSpreadsheet'; type BudgetAnalysisIntervalData = { date: string; diff --git a/packages/desktop-client/src/components/reports/spreadsheets/calculateLegend.ts b/packages/desktop-client/src/components/reports/spreadsheets/calculateLegend.ts index cfae8a9a9c..c7f8f4b12d 100644 --- a/packages/desktop-client/src/components/reports/spreadsheets/calculateLegend.ts +++ b/packages/desktop-client/src/components/reports/spreadsheets/calculateLegend.ts @@ -7,7 +7,7 @@ import type { LegendEntity, } from 'loot-core/types/models'; -import { getColorScale } from '@desktop-client/components/reports/chart-theme'; +import { getColorScale } from '#components/reports/chart-theme'; export function calculateLegend( intervalData: IntervalEntity[], diff --git a/packages/desktop-client/src/components/reports/spreadsheets/calendar-spreadsheet.ts b/packages/desktop-client/src/components/reports/spreadsheets/calendar-spreadsheet.ts index 7a8c33fabf..1cca691d66 100644 --- a/packages/desktop-client/src/components/reports/spreadsheets/calendar-spreadsheet.ts +++ b/packages/desktop-client/src/components/reports/spreadsheets/calendar-spreadsheet.ts @@ -6,8 +6,8 @@ import { q } from 'loot-core/shared/query'; import type { RuleConditionEntity } from 'loot-core/types/models'; import type { SyncedPrefs } from 'loot-core/types/prefs'; -import type { useSpreadsheet } from '@desktop-client/hooks/useSpreadsheet'; -import { aqlQuery } from '@desktop-client/queries/aqlQuery'; +import type { useSpreadsheet } from '#hooks/useSpreadsheet'; +import { aqlQuery } from '#queries/aqlQuery'; export type CalendarDataType = { date: Date; diff --git a/packages/desktop-client/src/components/reports/spreadsheets/cash-flow-spreadsheet.tsx b/packages/desktop-client/src/components/reports/spreadsheets/cash-flow-spreadsheet.tsx index d97e490823..a43f809d7c 100644 --- a/packages/desktop-client/src/components/reports/spreadsheets/cash-flow-spreadsheet.tsx +++ b/packages/desktop-client/src/components/reports/spreadsheets/cash-flow-spreadsheet.tsx @@ -11,10 +11,10 @@ import * as monthUtils from 'loot-core/shared/months'; import { q } from 'loot-core/shared/query'; import type { RuleConditionEntity } from 'loot-core/types/models'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { indexCashFlow, runAll } from '@desktop-client/components/reports/util'; -import type { FormatType } from '@desktop-client/hooks/useFormat'; -import type { useSpreadsheet } from '@desktop-client/hooks/useSpreadsheet'; +import { FinancialText } from '#components/FinancialText'; +import { indexCashFlow, runAll } from '#components/reports/util'; +import type { FormatType } from '#hooks/useFormat'; +import type { useSpreadsheet } from '#hooks/useSpreadsheet'; export function simpleCashFlow( startMonth: string, diff --git a/packages/desktop-client/src/components/reports/spreadsheets/crossover-spreadsheet.ts b/packages/desktop-client/src/components/reports/spreadsheets/crossover-spreadsheet.ts index 9186889eda..35076a4e19 100644 --- a/packages/desktop-client/src/components/reports/spreadsheets/crossover-spreadsheet.ts +++ b/packages/desktop-client/src/components/reports/spreadsheets/crossover-spreadsheet.ts @@ -4,8 +4,8 @@ import * as monthUtils from 'loot-core/shared/months'; import { q } from 'loot-core/shared/query'; import type { AccountEntity } from 'loot-core/types/models'; -import type { useSpreadsheet } from '@desktop-client/hooks/useSpreadsheet'; -import { aqlQuery } from '@desktop-client/queries/aqlQuery'; +import type { useSpreadsheet } from '#hooks/useSpreadsheet'; +import { aqlQuery } from '#queries/aqlQuery'; type MonthlyAgg = { date: string; amount: number }; diff --git a/packages/desktop-client/src/components/reports/spreadsheets/custom-spreadsheet.ts b/packages/desktop-client/src/components/reports/spreadsheets/custom-spreadsheet.ts index e12711e73f..d25bf64e8d 100644 --- a/packages/desktop-client/src/components/reports/spreadsheets/custom-spreadsheet.ts +++ b/packages/desktop-client/src/components/reports/spreadsheets/custom-spreadsheet.ts @@ -32,13 +32,13 @@ import { categoryLists, groupBySelections, ReportOptions, -} from '@desktop-client/components/reports/ReportOptions'; +} from '#components/reports/ReportOptions'; import type { QueryDataEntity, UncategorizedEntity, -} from '@desktop-client/components/reports/ReportOptions'; -import type { useSpreadsheet } from '@desktop-client/hooks/useSpreadsheet'; -import { aqlQuery } from '@desktop-client/queries/aqlQuery'; +} from '#components/reports/ReportOptions'; +import type { useSpreadsheet } from '#hooks/useSpreadsheet'; +import { aqlQuery } from '#queries/aqlQuery'; export type createCustomSpreadsheetProps = { startDate: string; diff --git a/packages/desktop-client/src/components/reports/spreadsheets/filterHiddenItems.ts b/packages/desktop-client/src/components/reports/spreadsheets/filterHiddenItems.ts index 1f59bea546..09069bf7a5 100644 --- a/packages/desktop-client/src/components/reports/spreadsheets/filterHiddenItems.ts +++ b/packages/desktop-client/src/components/reports/spreadsheets/filterHiddenItems.ts @@ -1,7 +1,7 @@ import type { QueryDataEntity, UncategorizedEntity, -} from '@desktop-client/components/reports/ReportOptions'; +} from '#components/reports/ReportOptions'; export function filterHiddenItems( item: UncategorizedEntity, diff --git a/packages/desktop-client/src/components/reports/spreadsheets/grouped-spreadsheet.ts b/packages/desktop-client/src/components/reports/spreadsheets/grouped-spreadsheet.ts index 051c07d811..7980fdfbd3 100644 --- a/packages/desktop-client/src/components/reports/spreadsheets/grouped-spreadsheet.ts +++ b/packages/desktop-client/src/components/reports/spreadsheets/grouped-spreadsheet.ts @@ -15,10 +15,10 @@ import { import { categoryLists, ReportOptions, -} from '@desktop-client/components/reports/ReportOptions'; -import type { QueryDataEntity } from '@desktop-client/components/reports/ReportOptions'; -import type { useSpreadsheet } from '@desktop-client/hooks/useSpreadsheet'; -import { aqlQuery } from '@desktop-client/queries/aqlQuery'; +} from '#components/reports/ReportOptions'; +import type { QueryDataEntity } from '#components/reports/ReportOptions'; +import type { useSpreadsheet } from '#hooks/useSpreadsheet'; +import { aqlQuery } from '#queries/aqlQuery'; export function createGroupedSpreadsheet({ startDate, diff --git a/packages/desktop-client/src/components/reports/spreadsheets/makeQuery.ts b/packages/desktop-client/src/components/reports/spreadsheets/makeQuery.ts index 9c82bf57ab..e1891cf099 100644 --- a/packages/desktop-client/src/components/reports/spreadsheets/makeQuery.ts +++ b/packages/desktop-client/src/components/reports/spreadsheets/makeQuery.ts @@ -1,6 +1,6 @@ import { q } from 'loot-core/shared/query'; -import { ReportOptions } from '@desktop-client/components/reports/ReportOptions'; +import { ReportOptions } from '#components/reports/ReportOptions'; export function makeQuery( name: string, diff --git a/packages/desktop-client/src/components/reports/spreadsheets/net-worth-spreadsheet.ts b/packages/desktop-client/src/components/reports/spreadsheets/net-worth-spreadsheet.ts index fd5aceab38..5fb98e8628 100644 --- a/packages/desktop-client/src/components/reports/spreadsheets/net-worth-spreadsheet.ts +++ b/packages/desktop-client/src/components/reports/spreadsheets/net-worth-spreadsheet.ts @@ -10,10 +10,10 @@ import type { RuleConditionEntity, } from 'loot-core/types/models'; -import { ReportOptions } from '@desktop-client/components/reports/ReportOptions'; -import type { FormatType } from '@desktop-client/hooks/useFormat'; -import type { useSpreadsheet } from '@desktop-client/hooks/useSpreadsheet'; -import { aqlQuery } from '@desktop-client/queries/aqlQuery'; +import { ReportOptions } from '#components/reports/ReportOptions'; +import type { FormatType } from '#hooks/useFormat'; +import type { useSpreadsheet } from '#hooks/useSpreadsheet'; +import { aqlQuery } from '#queries/aqlQuery'; type Balance = { date: string; diff --git a/packages/desktop-client/src/components/reports/spreadsheets/recalculate.ts b/packages/desktop-client/src/components/reports/spreadsheets/recalculate.ts index 0be73a5d52..4624d42764 100644 --- a/packages/desktop-client/src/components/reports/spreadsheets/recalculate.ts +++ b/packages/desktop-client/src/components/reports/spreadsheets/recalculate.ts @@ -6,7 +6,7 @@ import { filterHiddenItems } from './filterHiddenItems'; import type { QueryDataEntity, UncategorizedEntity, -} from '@desktop-client/components/reports/ReportOptions'; +} from '#components/reports/ReportOptions'; type recalculateProps = { item: UncategorizedEntity; diff --git a/packages/desktop-client/src/components/reports/spreadsheets/spending-spreadsheet.ts b/packages/desktop-client/src/components/reports/spreadsheets/spending-spreadsheet.ts index 1e0a05eac1..6c7f606b4b 100644 --- a/packages/desktop-client/src/components/reports/spreadsheets/spending-spreadsheet.ts +++ b/packages/desktop-client/src/components/reports/spreadsheets/spending-spreadsheet.ts @@ -12,8 +12,8 @@ import type { import { makeQuery } from './makeQuery'; -import type { useSpreadsheet } from '@desktop-client/hooks/useSpreadsheet'; -import { aqlQuery } from '@desktop-client/queries/aqlQuery'; +import type { useSpreadsheet } from '#hooks/useSpreadsheet'; +import { aqlQuery } from '#queries/aqlQuery'; type createSpendingSpreadsheetProps = { conditions?: RuleConditionEntity[]; diff --git a/packages/desktop-client/src/components/reports/spreadsheets/summary-spreadsheet.ts b/packages/desktop-client/src/components/reports/spreadsheets/summary-spreadsheet.ts index 530b93add7..f5c9636fd6 100644 --- a/packages/desktop-client/src/components/reports/spreadsheets/summary-spreadsheet.ts +++ b/packages/desktop-client/src/components/reports/spreadsheets/summary-spreadsheet.ts @@ -9,8 +9,8 @@ import type { SummaryContent, } from 'loot-core/types/models'; -import type { useSpreadsheet } from '@desktop-client/hooks/useSpreadsheet'; -import { aqlQuery } from '@desktop-client/queries/aqlQuery'; +import type { useSpreadsheet } from '#hooks/useSpreadsheet'; +import { aqlQuery } from '#queries/aqlQuery'; export function summarySpreadsheet( start: string, diff --git a/packages/desktop-client/src/components/reports/useDashboardWidgetCopyMenu.ts b/packages/desktop-client/src/components/reports/useDashboardWidgetCopyMenu.ts index 4426f67711..5d7489c50d 100644 --- a/packages/desktop-client/src/components/reports/useDashboardWidgetCopyMenu.ts +++ b/packages/desktop-client/src/components/reports/useDashboardWidgetCopyMenu.ts @@ -3,8 +3,8 @@ import { useTranslation } from 'react-i18next'; import type { Menu } from '@actual-app/components/menu'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { pushModal } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; type DashboardWidgetCopyMenuResult = { /** Menu items to add to the card's menu */ diff --git a/packages/desktop-client/src/components/reports/useReport.ts b/packages/desktop-client/src/components/reports/useReport.ts index 6e78f0fda7..ef51b70e1d 100644 --- a/packages/desktop-client/src/components/reports/useReport.ts +++ b/packages/desktop-client/src/components/reports/useReport.ts @@ -1,6 +1,6 @@ import { useEffect, useState } from 'react'; -import { useSpreadsheet } from '@desktop-client/hooks/useSpreadsheet'; +import { useSpreadsheet } from '#hooks/useSpreadsheet'; export function useReport( sheetName: string, diff --git a/packages/desktop-client/src/components/reports/util.ts b/packages/desktop-client/src/components/reports/util.ts index 596931e4ff..7836801394 100644 --- a/packages/desktop-client/src/components/reports/util.ts +++ b/packages/desktop-client/src/components/reports/util.ts @@ -7,7 +7,7 @@ import type { RuleConditionEntity, } from 'loot-core/types/models'; -import { aqlQuery } from '@desktop-client/queries/aqlQuery'; +import { aqlQuery } from '#queries/aqlQuery'; export function fromDateRepr(date: string): string { return date.slice(0, 7); diff --git a/packages/desktop-client/src/components/responsive/index.tsx b/packages/desktop-client/src/components/responsive/index.tsx index 214ebad6a0..7649002b98 100644 --- a/packages/desktop-client/src/components/responsive/index.tsx +++ b/packages/desktop-client/src/components/responsive/index.tsx @@ -3,7 +3,7 @@ import { useResponsive } from '@actual-app/components/hooks/useResponsive'; import type * as NarrowComponents from './narrow'; import type * as WideComponents from './wide'; -import { LoadComponent } from '@desktop-client/components/util/LoadComponent'; +import { LoadComponent } from '#components/util/LoadComponent'; const loadNarrow = () => import(/* webpackChunkName: "narrow-components" */ './narrow'); diff --git a/packages/desktop-client/src/components/rules/FormulaActionEditor.tsx b/packages/desktop-client/src/components/rules/FormulaActionEditor.tsx index e8a4e61a26..1f468699e9 100644 --- a/packages/desktop-client/src/components/rules/FormulaActionEditor.tsx +++ b/packages/desktop-client/src/components/rules/FormulaActionEditor.tsx @@ -4,7 +4,7 @@ import { theme } from '@actual-app/components/theme'; import { View } from '@actual-app/components/view'; const FormulaEditor = lazy(() => - import('@desktop-client/components/formula/FormulaEditor').then(module => ({ + import('#components/formula/FormulaEditor').then(module => ({ default: module.FormulaEditor, })), ); diff --git a/packages/desktop-client/src/components/rules/RuleEditor.tsx b/packages/desktop-client/src/components/rules/RuleEditor.tsx index c8b37e479a..ad0868a486 100644 --- a/packages/desktop-client/src/components/rules/RuleEditor.tsx +++ b/packages/desktop-client/src/components/rules/RuleEditor.tsx @@ -49,24 +49,21 @@ import type { import { FormulaActionEditor } from './FormulaActionEditor'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { StatusBadge } from '@desktop-client/components/schedules/StatusBadge'; -import { SimpleTransactionsTable } from '@desktop-client/components/transactions/SimpleTransactionsTable'; -import { BetweenAmountInput } from '@desktop-client/components/util/AmountInput'; -import { DisplayId } from '@desktop-client/components/util/DisplayId'; -import { GenericInput } from '@desktop-client/components/util/GenericInput'; -import { useDateFormat } from '@desktop-client/hooks/useDateFormat'; -import { useFeatureFlag } from '@desktop-client/hooks/useFeatureFlag'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useSchedules } from '@desktop-client/hooks/useSchedules'; -import { - SelectedProvider, - useSelected, -} from '@desktop-client/hooks/useSelected'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { aqlQuery } from '@desktop-client/queries/aqlQuery'; -import { useDispatch } from '@desktop-client/redux'; -import { disableUndo, enableUndo } from '@desktop-client/undo'; +import { FinancialText } from '#components/FinancialText'; +import { StatusBadge } from '#components/schedules/StatusBadge'; +import { SimpleTransactionsTable } from '#components/transactions/SimpleTransactionsTable'; +import { BetweenAmountInput } from '#components/util/AmountInput'; +import { DisplayId } from '#components/util/DisplayId'; +import { GenericInput } from '#components/util/GenericInput'; +import { useDateFormat } from '#hooks/useDateFormat'; +import { useFeatureFlag } from '#hooks/useFeatureFlag'; +import { useFormat } from '#hooks/useFormat'; +import { useSchedules } from '#hooks/useSchedules'; +import { SelectedProvider, useSelected } from '#hooks/useSelected'; +import { addNotification } from '#notifications/notificationsSlice'; +import { aqlQuery } from '#queries/aqlQuery'; +import { useDispatch } from '#redux'; +import { disableUndo, enableUndo } from '#undo'; function updateValue(array, value, update) { return array.map(v => (v === value ? update() : v)); diff --git a/packages/desktop-client/src/components/rules/RuleRow.tsx b/packages/desktop-client/src/components/rules/RuleRow.tsx index 1cb76dd5a8..bec097c2d0 100644 --- a/packages/desktop-client/src/components/rules/RuleRow.tsx +++ b/packages/desktop-client/src/components/rules/RuleRow.tsx @@ -18,10 +18,10 @@ import type { RuleEntity } from 'loot-core/types/models'; import { ActionExpression } from './ActionExpression'; import { ConditionExpression } from './ConditionExpression'; -import { Cell, Field, Row, SelectCell } from '@desktop-client/components/table'; -import { useContextMenu } from '@desktop-client/hooks/useContextMenu'; -import { useSelectedDispatch } from '@desktop-client/hooks/useSelected'; -import { groupActionsBySplitIndex } from '@desktop-client/util/ruleUtils'; +import { Cell, Field, Row, SelectCell } from '#components/table'; +import { useContextMenu } from '#hooks/useContextMenu'; +import { useSelectedDispatch } from '#hooks/useSelected'; +import { groupActionsBySplitIndex } from '#util/ruleUtils'; type RuleRowProps = { rule: RuleEntity; diff --git a/packages/desktop-client/src/components/rules/RulesHeader.tsx b/packages/desktop-client/src/components/rules/RulesHeader.tsx index fb0c8dfe72..4ffd804467 100644 --- a/packages/desktop-client/src/components/rules/RulesHeader.tsx +++ b/packages/desktop-client/src/components/rules/RulesHeader.tsx @@ -1,15 +1,8 @@ import React from 'react'; import { useTranslation } from 'react-i18next'; -import { - Cell, - SelectCell, - TableHeader, -} from '@desktop-client/components/table'; -import { - useSelectedDispatch, - useSelectedItems, -} from '@desktop-client/hooks/useSelected'; +import { Cell, SelectCell, TableHeader } from '#components/table'; +import { useSelectedDispatch, useSelectedItems } from '#hooks/useSelected'; export function RulesHeader() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/rules/ScheduleValue.tsx b/packages/desktop-client/src/components/rules/ScheduleValue.tsx index 828c966cdb..04d5c5dbe7 100644 --- a/packages/desktop-client/src/components/rules/ScheduleValue.tsx +++ b/packages/desktop-client/src/components/rules/ScheduleValue.tsx @@ -10,8 +10,8 @@ import type { ScheduleEntity } from 'loot-core/types/models'; import { Value } from './Value'; -import { usePayeesById } from '@desktop-client/hooks/usePayees'; -import { useSchedules } from '@desktop-client/hooks/useSchedules'; +import { usePayeesById } from '#hooks/usePayees'; +import { useSchedules } from '#hooks/useSchedules'; type ScheduleValueProps = { value: ScheduleEntity; diff --git a/packages/desktop-client/src/components/rules/Value.tsx b/packages/desktop-client/src/components/rules/Value.tsx index 26f0f053ab..cf7f5b0129 100644 --- a/packages/desktop-client/src/components/rules/Value.tsx +++ b/packages/desktop-client/src/components/rules/Value.tsx @@ -10,14 +10,14 @@ import { format as formatDate, parseISO } from 'date-fns'; import { getMonthYearFormat } from 'loot-core/shared/months'; import { getRecurringDescription } from 'loot-core/shared/schedules'; -import { Link } from '@desktop-client/components/common/Link'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; -import { useCategories } from '@desktop-client/hooks/useCategories'; -import { useDateFormat } from '@desktop-client/hooks/useDateFormat'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useLocale } from '@desktop-client/hooks/useLocale'; -import { usePayees } from '@desktop-client/hooks/usePayees'; +import { Link } from '#components/common/Link'; +import { FinancialText } from '#components/FinancialText'; +import { useAccounts } from '#hooks/useAccounts'; +import { useCategories } from '#hooks/useCategories'; +import { useDateFormat } from '#hooks/useDateFormat'; +import { useFormat } from '#hooks/useFormat'; +import { useLocale } from '#hooks/useLocale'; +import { usePayees } from '#hooks/usePayees'; type ValueProps = { value: T; diff --git a/packages/desktop-client/src/components/schedules/DiscoverSchedules.tsx b/packages/desktop-client/src/components/schedules/DiscoverSchedules.tsx index 7e477dfc84..674f611e1f 100644 --- a/packages/desktop-client/src/components/schedules/DiscoverSchedules.tsx +++ b/packages/desktop-client/src/components/schedules/DiscoverSchedules.tsx @@ -16,29 +16,19 @@ import type { DiscoverScheduleEntity } from 'loot-core/types/models'; import { ScheduleAmountCell } from './SchedulesTable'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { - Field, - Row, - SelectCell, - Table, - TableHeader, -} from '@desktop-client/components/table'; -import { DisplayId } from '@desktop-client/components/util/DisplayId'; -import { useDateFormat } from '@desktop-client/hooks/useDateFormat'; -import { useLocale } from '@desktop-client/hooks/useLocale'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { Field, Row, SelectCell, Table, TableHeader } from '#components/table'; +import { DisplayId } from '#components/util/DisplayId'; +import { useDateFormat } from '#hooks/useDateFormat'; +import { useLocale } from '#hooks/useLocale'; import { SelectedProvider, useSelected, useSelectedDispatch, useSelectedItems, -} from '@desktop-client/hooks/useSelected'; -import { useSendPlatformRequest } from '@desktop-client/hooks/useSendPlatformRequest'; -import { aqlQuery } from '@desktop-client/queries/aqlQuery'; +} from '#hooks/useSelected'; +import { useSendPlatformRequest } from '#hooks/useSendPlatformRequest'; +import { aqlQuery } from '#queries/aqlQuery'; const ROW_HEIGHT = 43; diff --git a/packages/desktop-client/src/components/schedules/PostsOfflineNotification.tsx b/packages/desktop-client/src/components/schedules/PostsOfflineNotification.tsx index 6264cad050..fdf68d0991 100644 --- a/packages/desktop-client/src/components/schedules/PostsOfflineNotification.tsx +++ b/packages/desktop-client/src/components/schedules/PostsOfflineNotification.tsx @@ -11,15 +11,11 @@ import { theme } from '@actual-app/components/theme'; import { send } from 'loot-core/platform/client/connection'; import type { PayeeEntity } from 'loot-core/types/models'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { DisplayId } from '@desktop-client/components/util/DisplayId'; -import { useFormatList } from '@desktop-client/hooks/useFormatList'; -import { popModal } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { DisplayId } from '#components/util/DisplayId'; +import { useFormatList } from '#hooks/useFormatList'; +import { popModal } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; export function PostsOfflineNotification() { const { t, i18n } = useTranslation(); diff --git a/packages/desktop-client/src/components/schedules/ScheduleEditForm.tsx b/packages/desktop-client/src/components/schedules/ScheduleEditForm.tsx index 3788c15db5..182b0cc523 100644 --- a/packages/desktop-client/src/components/schedules/ScheduleEditForm.tsx +++ b/packages/desktop-client/src/components/schedules/ScheduleEditForm.tsx @@ -19,25 +19,18 @@ import type { TransactionEntity, } from 'loot-core/types/models'; -import { - Checkbox, - FormField, - FormLabel, -} from '@desktop-client/components/forms'; -import { OpSelect } from '@desktop-client/components/rules/RuleEditor'; -import { DateSelect } from '@desktop-client/components/select/DateSelect'; -import { RecurringSchedulePicker } from '@desktop-client/components/select/RecurringSchedulePicker'; -import { SelectedItemsButton } from '@desktop-client/components/table'; -import { SimpleTransactionsTable } from '@desktop-client/components/transactions/SimpleTransactionsTable'; -import { - AmountInput, - BetweenAmountInput, -} from '@desktop-client/components/util/AmountInput'; -import { GenericInput } from '@desktop-client/components/util/GenericInput'; -import { useDateFormat } from '@desktop-client/hooks/useDateFormat'; -import { useLocale } from '@desktop-client/hooks/useLocale'; -import { SelectedProvider } from '@desktop-client/hooks/useSelected'; -import type { Actions } from '@desktop-client/hooks/useSelected'; +import { Checkbox, FormField, FormLabel } from '#components/forms'; +import { OpSelect } from '#components/rules/RuleEditor'; +import { DateSelect } from '#components/select/DateSelect'; +import { RecurringSchedulePicker } from '#components/select/RecurringSchedulePicker'; +import { SelectedItemsButton } from '#components/table'; +import { SimpleTransactionsTable } from '#components/transactions/SimpleTransactionsTable'; +import { AmountInput, BetweenAmountInput } from '#components/util/AmountInput'; +import { GenericInput } from '#components/util/GenericInput'; +import { useDateFormat } from '#hooks/useDateFormat'; +import { useLocale } from '#hooks/useLocale'; +import { SelectedProvider } from '#hooks/useSelected'; +import type { Actions } from '#hooks/useSelected'; export type ScheduleFormFields = { payee: null | string; diff --git a/packages/desktop-client/src/components/schedules/ScheduleEditModal.tsx b/packages/desktop-client/src/components/schedules/ScheduleEditModal.tsx index c22c37d9b5..dc87cc5de1 100644 --- a/packages/desktop-client/src/components/schedules/ScheduleEditModal.tsx +++ b/packages/desktop-client/src/components/schedules/ScheduleEditModal.tsx @@ -13,18 +13,14 @@ import type { RecurConfig, ScheduleEntity } from 'loot-core/types/models'; import { updateScheduleConditions } from './schedule-edit-utils'; import { ScheduleEditForm } from './ScheduleEditForm'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { usePayeesById } from '@desktop-client/hooks/usePayees'; -import { useScheduleEdit } from '@desktop-client/hooks/useScheduleEdit'; -import { useSelected } from '@desktop-client/hooks/useSelected'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; -import { aqlQuery } from '@desktop-client/queries/aqlQuery'; -import { useDispatch } from '@desktop-client/redux'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { usePayeesById } from '#hooks/usePayees'; +import { useScheduleEdit } from '#hooks/useScheduleEdit'; +import { useSelected } from '#hooks/useSelected'; +import { pushModal } from '#modals/modalsSlice'; +import type { Modal as ModalType } from '#modals/modalsSlice'; +import { aqlQuery } from '#queries/aqlQuery'; +import { useDispatch } from '#redux'; type ScheduleEditModalProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/schedules/ScheduleLink.tsx b/packages/desktop-client/src/components/schedules/ScheduleLink.tsx index 1582d302d3..aff81a2637 100644 --- a/packages/desktop-client/src/components/schedules/ScheduleLink.tsx +++ b/packages/desktop-client/src/components/schedules/ScheduleLink.tsx @@ -13,16 +13,12 @@ import { q } from 'loot-core/shared/query'; import { ROW_HEIGHT, SchedulesTable } from './SchedulesTable'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { Search } from '@desktop-client/components/common/Search'; -import { useSchedules } from '@desktop-client/hooks/useSchedules'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { Search } from '#components/common/Search'; +import { useSchedules } from '#hooks/useSchedules'; +import { pushModal } from '#modals/modalsSlice'; +import type { Modal as ModalType } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; type ScheduleLinkProps = Extract< ModalType, diff --git a/packages/desktop-client/src/components/schedules/SchedulesTable.tsx b/packages/desktop-client/src/components/schedules/SchedulesTable.tsx index ebe33b3d28..2ff41c62c6 100644 --- a/packages/desktop-client/src/components/schedules/SchedulesTable.tsx +++ b/packages/desktop-client/src/components/schedules/SchedulesTable.tsx @@ -24,21 +24,15 @@ import type { ScheduleEntity } from 'loot-core/types/models'; import { StatusBadge } from './StatusBadge'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { - Cell, - Field, - Row, - Table, - TableHeader, -} from '@desktop-client/components/table'; -import { DisplayId } from '@desktop-client/components/util/DisplayId'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; -import { useContextMenu } from '@desktop-client/hooks/useContextMenu'; -import { useDateFormat } from '@desktop-client/hooks/useDateFormat'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { usePayees } from '@desktop-client/hooks/usePayees'; +import { FinancialText } from '#components/FinancialText'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { Cell, Field, Row, Table, TableHeader } from '#components/table'; +import { DisplayId } from '#components/util/DisplayId'; +import { useAccounts } from '#hooks/useAccounts'; +import { useContextMenu } from '#hooks/useContextMenu'; +import { useDateFormat } from '#hooks/useDateFormat'; +import { useFormat } from '#hooks/useFormat'; +import { usePayees } from '#hooks/usePayees'; type SchedulesTableProps = { isLoading?: boolean; schedules: readonly ScheduleEntity[]; diff --git a/packages/desktop-client/src/components/schedules/UpcomingLength.tsx b/packages/desktop-client/src/components/schedules/UpcomingLength.tsx index 111f55109a..f11318b469 100644 --- a/packages/desktop-client/src/components/schedules/UpcomingLength.tsx +++ b/packages/desktop-client/src/components/schedules/UpcomingLength.tsx @@ -10,12 +10,8 @@ import type { SyncedPrefs } from 'loot-core/types/prefs'; import { CustomUpcomingLength } from './CustomUpcomingLength'; -import { - Modal, - ModalCloseButton, - ModalHeader, -} from '@desktop-client/components/common/Modal'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; +import { Modal, ModalCloseButton, ModalHeader } from '#components/common/Modal'; +import { useSyncedPref } from '#hooks/useSyncedPref'; function useUpcomingLengthOptions() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/schedules/index.tsx b/packages/desktop-client/src/components/schedules/index.tsx index 16331e6795..133c3911e3 100644 --- a/packages/desktop-client/src/components/schedules/index.tsx +++ b/packages/desktop-client/src/components/schedules/index.tsx @@ -12,11 +12,11 @@ import type { ScheduleEntity } from 'loot-core/types/models'; import { SchedulesTable } from './SchedulesTable'; import type { ScheduleItemAction } from './SchedulesTable'; -import { Search } from '@desktop-client/components/common/Search'; -import { Page } from '@desktop-client/components/Page'; -import { useSchedules } from '@desktop-client/hooks/useSchedules'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { Search } from '#components/common/Search'; +import { Page } from '#components/Page'; +import { useSchedules } from '#hooks/useSchedules'; +import { pushModal } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; export function Schedules() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/select/DateSelect.tsx b/packages/desktop-client/src/components/select/DateSelect.tsx index 7120b05ed7..f5e28146be 100644 --- a/packages/desktop-client/src/components/select/DateSelect.tsx +++ b/packages/desktop-client/src/components/select/DateSelect.tsx @@ -40,10 +40,10 @@ import 'pikaday/css/pikaday.css'; import DateSelectLeft from './DateSelect.left.png'; import DateSelectRight from './DateSelect.right.png'; -import { InputField } from '@desktop-client/components/mobile/MobileForms'; -import { useLocale } from '@desktop-client/hooks/useLocale'; -import { useMergedRefs } from '@desktop-client/hooks/useMergedRefs'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; +import { InputField } from '#components/mobile/MobileForms'; +import { useLocale } from '#hooks/useLocale'; +import { useMergedRefs } from '#hooks/useMergedRefs'; +import { useSyncedPref } from '#hooks/useSyncedPref'; const pickerStyles: CSSProperties = { '& .pika-single.actual-date-picker': { diff --git a/packages/desktop-client/src/components/select/RecurringSchedulePicker.tsx b/packages/desktop-client/src/components/select/RecurringSchedulePicker.tsx index 12754aee16..ce7dc43dbd 100644 --- a/packages/desktop-client/src/components/select/RecurringSchedulePicker.tsx +++ b/packages/desktop-client/src/components/select/RecurringSchedulePicker.tsx @@ -23,10 +23,10 @@ import type { TransObjectLiteral, WithRequired } from 'loot-core/types/util'; import { DateSelect } from './DateSelect'; -import { Modal } from '@desktop-client/components/common/Modal'; -import { Checkbox } from '@desktop-client/components/forms'; -import { useDateFormat } from '@desktop-client/hooks/useDateFormat'; -import { useLocale } from '@desktop-client/hooks/useLocale'; +import { Modal } from '#components/common/Modal'; +import { Checkbox } from '#components/forms'; +import { useDateFormat } from '#hooks/useDateFormat'; +import { useLocale } from '#hooks/useLocale'; // ex: There is no 6th Friday of the Month const MAX_DAY_OF_WEEK_INTERVAL = 5; diff --git a/packages/desktop-client/src/components/settings/AuthSettings.test.tsx b/packages/desktop-client/src/components/settings/AuthSettings.test.tsx index 5039dcfdc8..a16704f75f 100644 --- a/packages/desktop-client/src/components/settings/AuthSettings.test.tsx +++ b/packages/desktop-client/src/components/settings/AuthSettings.test.tsx @@ -3,17 +3,14 @@ import { vi } from 'vitest'; import { AuthSettings } from './AuthSettings'; -import { - useLoginMethod, - useMultiuserEnabled, -} from '@desktop-client/components/ServerContext'; -import { useSyncServerStatus } from '@desktop-client/hooks/useSyncServerStatus'; -import { TestProviders } from '@desktop-client/mocks'; +import { useLoginMethod, useMultiuserEnabled } from '#components/ServerContext'; +import { useSyncServerStatus } from '#hooks/useSyncServerStatus'; +import { TestProviders } from '#mocks'; -vi.mock('@desktop-client/hooks/useSyncServerStatus', () => ({ +vi.mock('#hooks/useSyncServerStatus', () => ({ useSyncServerStatus: vi.fn(), })); -vi.mock('@desktop-client/components/ServerContext', () => ({ +vi.mock('#components/ServerContext', () => ({ useMultiuserEnabled: vi.fn(), useLoginMethod: vi.fn(), })); diff --git a/packages/desktop-client/src/components/settings/AuthSettings.tsx b/packages/desktop-client/src/components/settings/AuthSettings.tsx index cbf4eb8f60..3a76e99a9f 100644 --- a/packages/desktop-client/src/components/settings/AuthSettings.tsx +++ b/packages/desktop-client/src/components/settings/AuthSettings.tsx @@ -9,13 +9,10 @@ import { View } from '@actual-app/components/view'; import { Setting } from './UI'; -import { - useLoginMethod, - useMultiuserEnabled, -} from '@desktop-client/components/ServerContext'; -import { useSyncServerStatus } from '@desktop-client/hooks/useSyncServerStatus'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { useLoginMethod, useMultiuserEnabled } from '#components/ServerContext'; +import { useSyncServerStatus } from '#hooks/useSyncServerStatus'; +import { pushModal } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; export function AuthSettings() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/settings/BudgetTypeSettings.tsx b/packages/desktop-client/src/components/settings/BudgetTypeSettings.tsx index 632c541054..3ee3ce4608 100644 --- a/packages/desktop-client/src/components/settings/BudgetTypeSettings.tsx +++ b/packages/desktop-client/src/components/settings/BudgetTypeSettings.tsx @@ -8,8 +8,8 @@ import { send } from 'loot-core/platform/client/connection'; import { Setting } from './UI'; -import { Link } from '@desktop-client/components/common/Link'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; +import { Link } from '#components/common/Link'; +import { useSyncedPref } from '#hooks/useSyncedPref'; export function BudgetTypeSettings() { const [budgetType = 'envelope', setBudgetType] = useSyncedPref('budgetType'); diff --git a/packages/desktop-client/src/components/settings/Currency.tsx b/packages/desktop-client/src/components/settings/Currency.tsx index 08e05e82fa..a3dd773ca1 100644 --- a/packages/desktop-client/src/components/settings/Currency.tsx +++ b/packages/desktop-client/src/components/settings/Currency.tsx @@ -11,8 +11,8 @@ import { currencies, getCurrency } from 'loot-core/shared/currencies'; import { Column, Setting } from './UI'; -import { Checkbox } from '@desktop-client/components/forms'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; +import { Checkbox } from '#components/forms'; +import { useSyncedPref } from '#hooks/useSyncedPref'; export function CurrencySettings() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/settings/Encryption.tsx b/packages/desktop-client/src/components/settings/Encryption.tsx index 1cf5320b57..0b0de14994 100644 --- a/packages/desktop-client/src/components/settings/Encryption.tsx +++ b/packages/desktop-client/src/components/settings/Encryption.tsx @@ -7,11 +7,11 @@ import { theme } from '@actual-app/components/theme'; import { Setting } from './UI'; -import { Link } from '@desktop-client/components/common/Link'; -import { useServerURL } from '@desktop-client/components/ServerContext'; -import { useMetadataPref } from '@desktop-client/hooks/useMetadataPref'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { Link } from '#components/common/Link'; +import { useServerURL } from '#components/ServerContext'; +import { useMetadataPref } from '#hooks/useMetadataPref'; +import { pushModal } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; export function EncryptionSettings() { const dispatch = useDispatch(); diff --git a/packages/desktop-client/src/components/settings/Experimental.tsx b/packages/desktop-client/src/components/settings/Experimental.tsx index 5d5709e53c..78dc412138 100644 --- a/packages/desktop-client/src/components/settings/Experimental.tsx +++ b/packages/desktop-client/src/components/settings/Experimental.tsx @@ -10,18 +10,15 @@ import type { FeatureFlag, ServerPrefs } from 'loot-core/types/prefs'; import { Setting } from './UI'; -import { useAuth } from '@desktop-client/auth/AuthProvider'; -import { Permissions } from '@desktop-client/auth/types'; -import { Link } from '@desktop-client/components/common/Link'; -import { Checkbox } from '@desktop-client/components/forms'; -import { - useLoginMethod, - useMultiuserEnabled, -} from '@desktop-client/components/ServerContext'; -import { useFeatureFlag } from '@desktop-client/hooks/useFeatureFlag'; -import { useServerPref } from '@desktop-client/hooks/useServerPref'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; -import { useSyncServerStatus } from '@desktop-client/hooks/useSyncServerStatus'; +import { useAuth } from '#auth/AuthProvider'; +import { Permissions } from '#auth/types'; +import { Link } from '#components/common/Link'; +import { Checkbox } from '#components/forms'; +import { useLoginMethod, useMultiuserEnabled } from '#components/ServerContext'; +import { useFeatureFlag } from '#hooks/useFeatureFlag'; +import { useServerPref } from '#hooks/useServerPref'; +import { useSyncedPref } from '#hooks/useSyncedPref'; +import { useSyncServerStatus } from '#hooks/useSyncServerStatus'; type FeatureToggleProps = { flag: FeatureFlag; diff --git a/packages/desktop-client/src/components/settings/Export.tsx b/packages/desktop-client/src/components/settings/Export.tsx index 790d44e8a9..a3325fc3a5 100644 --- a/packages/desktop-client/src/components/settings/Export.tsx +++ b/packages/desktop-client/src/components/settings/Export.tsx @@ -11,7 +11,7 @@ import { send } from 'loot-core/platform/client/connection'; import { Setting } from './UI'; -import { useMetadataPref } from '@desktop-client/hooks/useMetadataPref'; +import { useMetadataPref } from '#hooks/useMetadataPref'; export function ExportBudget() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/settings/Format.tsx b/packages/desktop-client/src/components/settings/Format.tsx index 2464044e05..f792a7bd11 100644 --- a/packages/desktop-client/src/components/settings/Format.tsx +++ b/packages/desktop-client/src/components/settings/Format.tsx @@ -14,11 +14,11 @@ import type { SyncedPrefs } from 'loot-core/types/prefs'; import { Column, Setting } from './UI'; -import { Checkbox } from '@desktop-client/components/forms'; -import { useSidebar } from '@desktop-client/components/sidebar/SidebarProvider'; -import { useDateFormat } from '@desktop-client/hooks/useDateFormat'; -import { useDaysOfWeek } from '@desktop-client/hooks/useDaysOfWeek'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; +import { Checkbox } from '#components/forms'; +import { useSidebar } from '#components/sidebar/SidebarProvider'; +import { useDateFormat } from '#hooks/useDateFormat'; +import { useDaysOfWeek } from '#hooks/useDaysOfWeek'; +import { useSyncedPref } from '#hooks/useSyncedPref'; const dateFormats: { value: SyncedPrefs['dateFormat']; label: string }[] = [ { value: 'MM/dd/yyyy', label: 'MM/DD/YYYY' }, diff --git a/packages/desktop-client/src/components/settings/LanguageSettings.tsx b/packages/desktop-client/src/components/settings/LanguageSettings.tsx index 5c2f1f765c..058dda982d 100644 --- a/packages/desktop-client/src/components/settings/LanguageSettings.tsx +++ b/packages/desktop-client/src/components/settings/LanguageSettings.tsx @@ -9,9 +9,9 @@ import type { TFunction } from 'i18next'; import { Setting } from './UI'; -import { Link } from '@desktop-client/components/common/Link'; -import { useGlobalPref } from '@desktop-client/hooks/useGlobalPref'; -import { availableLanguages, setI18NextLanguage } from '@desktop-client/i18n'; +import { Link } from '#components/common/Link'; +import { useGlobalPref } from '#hooks/useGlobalPref'; +import { availableLanguages, setI18NextLanguage } from '#i18n'; const languageDisplayNameOverride: { [key: string]: string } = { 'pt-BR': 'Português (Brasil)', diff --git a/packages/desktop-client/src/components/settings/Reset.tsx b/packages/desktop-client/src/components/settings/Reset.tsx index 740382f266..b98a9e3ee0 100644 --- a/packages/desktop-client/src/components/settings/Reset.tsx +++ b/packages/desktop-client/src/components/settings/Reset.tsx @@ -8,9 +8,9 @@ import { send } from 'loot-core/platform/client/connection'; import { Setting } from './UI'; -import { resetSync } from '@desktop-client/app/appSlice'; -import { useMetadataPref } from '@desktop-client/hooks/useMetadataPref'; -import { useDispatch } from '@desktop-client/redux'; +import { resetSync } from '#app/appSlice'; +import { useMetadataPref } from '#hooks/useMetadataPref'; +import { useDispatch } from '#redux'; export function ResetCache() { const [resetting, setResetting] = useState(false); diff --git a/packages/desktop-client/src/components/settings/ThemeInstaller.test.tsx b/packages/desktop-client/src/components/settings/ThemeInstaller.test.tsx index 1af0bb02d9..158a36a337 100644 --- a/packages/desktop-client/src/components/settings/ThemeInstaller.test.tsx +++ b/packages/desktop-client/src/components/settings/ThemeInstaller.test.tsx @@ -4,15 +4,15 @@ import { beforeEach, describe, expect, it, vi } from 'vitest'; import { ThemeInstaller } from './ThemeInstaller'; -import { useThemeCatalog } from '@desktop-client/hooks/useThemeCatalog'; +import { useThemeCatalog } from '#hooks/useThemeCatalog'; import { fetchThemeCss, generateThemeId, validateThemeCss, -} from '@desktop-client/style/customThemes'; +} from '#style/customThemes'; -vi.mock('@desktop-client/style/customThemes', async () => { - const actual = await vi.importActual('@desktop-client/style/customThemes'); +vi.mock('#style/customThemes', async () => { + const actual = await vi.importActual('#style/customThemes'); return { ...actual, fetchThemeCss: vi.fn(), @@ -30,7 +30,7 @@ vi.mock('@desktop-client/style/customThemes', async () => { }; }); -vi.mock('@desktop-client/hooks/useThemeCatalog', () => ({ +vi.mock('#hooks/useThemeCatalog', () => ({ useThemeCatalog: vi.fn(), })); diff --git a/packages/desktop-client/src/components/settings/ThemeInstaller.tsx b/packages/desktop-client/src/components/settings/ThemeInstaller.tsx index 3943459377..8c67399b23 100644 --- a/packages/desktop-client/src/components/settings/ThemeInstaller.tsx +++ b/packages/desktop-client/src/components/settings/ThemeInstaller.tsx @@ -13,20 +13,17 @@ import { View } from '@actual-app/components/view'; import { ColorPalette } from './ColorPalette'; -import { Link } from '@desktop-client/components/common/Link'; -import { FixedSizeList } from '@desktop-client/components/FixedSizeList'; -import { useThemeCatalog } from '@desktop-client/hooks/useThemeCatalog'; +import { Link } from '#components/common/Link'; +import { FixedSizeList } from '#components/FixedSizeList'; +import { useThemeCatalog } from '#hooks/useThemeCatalog'; import { extractRepoOwner, fetchThemeCss, generateThemeId, normalizeGitHubRepo, validateThemeCss, -} from '@desktop-client/style/customThemes'; -import type { - CatalogTheme, - InstalledTheme, -} from '@desktop-client/style/customThemes'; +} from '#style/customThemes'; +import type { CatalogTheme, InstalledTheme } from '#style/customThemes'; // Theme item fixed dimensions const THEME_ITEM_HEIGHT = 140; diff --git a/packages/desktop-client/src/components/settings/Themes.tsx b/packages/desktop-client/src/components/settings/Themes.tsx index a3c283368b..55a39bc614 100644 --- a/packages/desktop-client/src/components/settings/Themes.tsx +++ b/packages/desktop-client/src/components/settings/Themes.tsx @@ -14,20 +14,20 @@ import type { DarkTheme, Theme } from 'loot-core/types/prefs'; import { ThemeInstaller } from './ThemeInstaller'; import { Column, Setting } from './UI'; -import { useSidebar } from '@desktop-client/components/sidebar/SidebarProvider'; -import { useFeatureFlag } from '@desktop-client/hooks/useFeatureFlag'; -import { useGlobalPref } from '@desktop-client/hooks/useGlobalPref'; +import { useSidebar } from '#components/sidebar/SidebarProvider'; +import { useFeatureFlag } from '#hooks/useFeatureFlag'; +import { useGlobalPref } from '#hooks/useGlobalPref'; import { darkThemeOptions, themeOptions, usePreferredDarkTheme, useTheme, -} from '@desktop-client/style'; +} from '#style'; import { parseInstalledTheme, serializeInstalledTheme, -} from '@desktop-client/style/customThemes'; -import type { InstalledTheme } from '@desktop-client/style/customThemes'; +} from '#style/customThemes'; +import type { InstalledTheme } from '#style/customThemes'; const INSTALL_NEW_VALUE = '__install_new__'; const INSTALL_CUSTOM_LIGHT = '__install_custom_light__'; diff --git a/packages/desktop-client/src/components/settings/UI.tsx b/packages/desktop-client/src/components/settings/UI.tsx index c0154733be..f8af89e26b 100644 --- a/packages/desktop-client/src/components/settings/UI.tsx +++ b/packages/desktop-client/src/components/settings/UI.tsx @@ -10,7 +10,7 @@ import { tokens } from '@actual-app/components/tokens'; import { View } from '@actual-app/components/view'; import { css } from '@emotion/css'; -import { Link } from '@desktop-client/components/common/Link'; +import { Link } from '#components/common/Link'; type SettingProps = { primaryAction?: ReactNode; diff --git a/packages/desktop-client/src/components/settings/index.tsx b/packages/desktop-client/src/components/settings/index.tsx index ffb5b3cd4c..7647dfad1b 100644 --- a/packages/desktop-client/src/components/settings/index.tsx +++ b/packages/desktop-client/src/components/settings/index.tsx @@ -28,23 +28,19 @@ import { ResetCache, ResetSync } from './Reset'; import { ThemeSettings } from './Themes'; import { AdvancedToggle, Setting } from './UI'; -import { getLatestAppVersion } from '@desktop-client/app/appSlice'; -import { closeBudget } from '@desktop-client/budgetfiles/budgetfilesSlice'; -import { Link } from '@desktop-client/components/common/Link'; -import { - Checkbox, - FormField, - FormLabel, -} from '@desktop-client/components/forms'; -import { MOBILE_NAV_HEIGHT } from '@desktop-client/components/mobile/MobileNavTabs'; -import { Page } from '@desktop-client/components/Page'; -import { useServerVersion } from '@desktop-client/components/ServerContext'; -import { useFeatureFlag } from '@desktop-client/hooks/useFeatureFlag'; -import { useGlobalPref } from '@desktop-client/hooks/useGlobalPref'; -import { useMetadataPref } from '@desktop-client/hooks/useMetadataPref'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; -import { loadPrefs } from '@desktop-client/prefs/prefsSlice'; -import { useDispatch, useSelector } from '@desktop-client/redux'; +import { getLatestAppVersion } from '#app/appSlice'; +import { closeBudget } from '#budgetfiles/budgetfilesSlice'; +import { Link } from '#components/common/Link'; +import { Checkbox, FormField, FormLabel } from '#components/forms'; +import { MOBILE_NAV_HEIGHT } from '#components/mobile/MobileNavTabs'; +import { Page } from '#components/Page'; +import { useServerVersion } from '#components/ServerContext'; +import { useFeatureFlag } from '#hooks/useFeatureFlag'; +import { useGlobalPref } from '#hooks/useGlobalPref'; +import { useMetadataPref } from '#hooks/useMetadataPref'; +import { useSyncedPref } from '#hooks/useSyncedPref'; +import { loadPrefs } from '#prefs/prefsSlice'; +import { useDispatch, useSelector } from '#redux'; function About() { const version = useServerVersion(); diff --git a/packages/desktop-client/src/components/sidebar/Account.tsx b/packages/desktop-client/src/components/sidebar/Account.tsx index 85d8b18466..c192f7f6f6 100644 --- a/packages/desktop-client/src/components/sidebar/Account.tsx +++ b/packages/desktop-client/src/components/sidebar/Account.tsx @@ -23,31 +23,21 @@ import { css, cx } from '@emotion/css'; import type { AccountEntity } from 'loot-core/types/models'; -import { - useReopenAccountMutation, - useUpdateAccountMutation, -} from '@desktop-client/accounts'; -import { BalanceHistoryGraph } from '@desktop-client/components/accounts/BalanceHistoryGraph'; -import { Link } from '@desktop-client/components/common/Link'; -import { Notes } from '@desktop-client/components/Notes'; -import { - DropHighlight, - useDraggable, - useDroppable, -} from '@desktop-client/components/sort'; -import type { - OnDragChangeCallback, - OnDropCallback, -} from '@desktop-client/components/sort'; -import { CellValue } from '@desktop-client/components/spreadsheet/CellValue'; -import { useContextMenu } from '@desktop-client/hooks/useContextMenu'; -import { useDragRef } from '@desktop-client/hooks/useDragRef'; -import { useIsTestEnv } from '@desktop-client/hooks/useIsTestEnv'; -import { useNotes } from '@desktop-client/hooks/useNotes'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; -import { openAccountCloseModal } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; -import type { Binding, SheetFields } from '@desktop-client/spreadsheet'; +import { useReopenAccountMutation, useUpdateAccountMutation } from '#accounts'; +import { BalanceHistoryGraph } from '#components/accounts/BalanceHistoryGraph'; +import { Link } from '#components/common/Link'; +import { Notes } from '#components/Notes'; +import { DropHighlight, useDraggable, useDroppable } from '#components/sort'; +import type { OnDragChangeCallback, OnDropCallback } from '#components/sort'; +import { CellValue } from '#components/spreadsheet/CellValue'; +import { useContextMenu } from '#hooks/useContextMenu'; +import { useDragRef } from '#hooks/useDragRef'; +import { useIsTestEnv } from '#hooks/useIsTestEnv'; +import { useNotes } from '#hooks/useNotes'; +import { useSyncedPref } from '#hooks/useSyncedPref'; +import { openAccountCloseModal } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; +import type { Binding, SheetFields } from '#spreadsheet'; export const accountNameStyle: CSSProperties = { marginTop: -2, diff --git a/packages/desktop-client/src/components/sidebar/Accounts.tsx b/packages/desktop-client/src/components/sidebar/Accounts.tsx index 87729a1d05..8840f35517 100644 --- a/packages/desktop-client/src/components/sidebar/Accounts.tsx +++ b/packages/desktop-client/src/components/sidebar/Accounts.tsx @@ -9,16 +9,16 @@ import type { AccountEntity } from 'loot-core/types/models'; import { Account } from './Account'; import { SecondaryItem } from './SecondaryItem'; -import { useMoveAccountMutation } from '@desktop-client/accounts'; -import { useAccounts } from '@desktop-client/hooks/useAccounts'; -import { useClosedAccounts } from '@desktop-client/hooks/useClosedAccounts'; -import { useFailedAccounts } from '@desktop-client/hooks/useFailedAccounts'; -import { useLocalPref } from '@desktop-client/hooks/useLocalPref'; -import { useOffBudgetAccounts } from '@desktop-client/hooks/useOffBudgetAccounts'; -import { useOnBudgetAccounts } from '@desktop-client/hooks/useOnBudgetAccounts'; -import { useUpdatedAccounts } from '@desktop-client/hooks/useUpdatedAccounts'; -import { useSelector } from '@desktop-client/redux'; -import * as bindings from '@desktop-client/spreadsheet/bindings'; +import { useMoveAccountMutation } from '#accounts'; +import { useAccounts } from '#hooks/useAccounts'; +import { useClosedAccounts } from '#hooks/useClosedAccounts'; +import { useFailedAccounts } from '#hooks/useFailedAccounts'; +import { useLocalPref } from '#hooks/useLocalPref'; +import { useOffBudgetAccounts } from '#hooks/useOffBudgetAccounts'; +import { useOnBudgetAccounts } from '#hooks/useOnBudgetAccounts'; +import { useUpdatedAccounts } from '#hooks/useUpdatedAccounts'; +import { useSelector } from '#redux'; +import * as bindings from '#spreadsheet/bindings'; const fontWeight = 600; diff --git a/packages/desktop-client/src/components/sidebar/BudgetName.tsx b/packages/desktop-client/src/components/sidebar/BudgetName.tsx index 6d3f87715f..86623c0f11 100644 --- a/packages/desktop-client/src/components/sidebar/BudgetName.tsx +++ b/packages/desktop-client/src/components/sidebar/BudgetName.tsx @@ -15,12 +15,12 @@ import { View } from '@actual-app/components/view'; import { isElectron } from 'loot-core/shared/environment'; import * as Platform from 'loot-core/shared/platform'; -import { closeBudget } from '@desktop-client/budgetfiles/budgetfilesSlice'; -import { useContextMenu } from '@desktop-client/hooks/useContextMenu'; -import { useMetadataPref } from '@desktop-client/hooks/useMetadataPref'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { closeBudget } from '#budgetfiles/budgetfilesSlice'; +import { useContextMenu } from '#hooks/useContextMenu'; +import { useMetadataPref } from '#hooks/useMetadataPref'; +import { useNavigate } from '#hooks/useNavigate'; +import { pushModal } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; type BudgetNameProps = { children?: ReactNode; diff --git a/packages/desktop-client/src/components/sidebar/ItemContent.tsx b/packages/desktop-client/src/components/sidebar/ItemContent.tsx index e42bf10064..844d5a1442 100644 --- a/packages/desktop-client/src/components/sidebar/ItemContent.tsx +++ b/packages/desktop-client/src/components/sidebar/ItemContent.tsx @@ -5,7 +5,7 @@ import { Button } from '@actual-app/components/button'; import type { CSSProperties } from '@actual-app/components/styles'; import type { View } from '@actual-app/components/view'; -import { Link } from '@desktop-client/components/common/Link'; +import { Link } from '#components/common/Link'; type ItemContentProps = { style: ComponentProps['style']; diff --git a/packages/desktop-client/src/components/sidebar/PrimaryButtons.tsx b/packages/desktop-client/src/components/sidebar/PrimaryButtons.tsx index 01cff8ec38..a15de988fe 100644 --- a/packages/desktop-client/src/components/sidebar/PrimaryButtons.tsx +++ b/packages/desktop-client/src/components/sidebar/PrimaryButtons.tsx @@ -19,8 +19,8 @@ import { View } from '@actual-app/components/view'; import { Item } from './Item'; import { SecondaryItem } from './SecondaryItem'; -import { useIsTestEnv } from '@desktop-client/hooks/useIsTestEnv'; -import { useSyncServerStatus } from '@desktop-client/hooks/useSyncServerStatus'; +import { useIsTestEnv } from '#hooks/useIsTestEnv'; +import { useSyncServerStatus } from '#hooks/useSyncServerStatus'; export function PrimaryButtons() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/sidebar/Sidebar.tsx b/packages/desktop-client/src/components/sidebar/Sidebar.tsx index c3d6228bc6..1495675038 100644 --- a/packages/desktop-client/src/components/sidebar/Sidebar.tsx +++ b/packages/desktop-client/src/components/sidebar/Sidebar.tsx @@ -19,11 +19,11 @@ import { SecondaryButtons } from './SecondaryButtons'; import { useSidebar } from './SidebarProvider'; import { ToggleButton } from './ToggleButton'; -import { useGlobalPref } from '@desktop-client/hooks/useGlobalPref'; -import { useLocalPref } from '@desktop-client/hooks/useLocalPref'; -import { useResizeObserver } from '@desktop-client/hooks/useResizeObserver'; -import { replaceModal } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { useGlobalPref } from '#hooks/useGlobalPref'; +import { useLocalPref } from '#hooks/useLocalPref'; +import { useResizeObserver } from '#hooks/useResizeObserver'; +import { replaceModal } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; export function Sidebar() { const hasWindowButtons = !Platform.isBrowser && Platform.OS === 'mac'; diff --git a/packages/desktop-client/src/components/sidebar/SidebarProvider.tsx b/packages/desktop-client/src/components/sidebar/SidebarProvider.tsx index 1fe0aae41c..32d458c514 100644 --- a/packages/desktop-client/src/components/sidebar/SidebarProvider.tsx +++ b/packages/desktop-client/src/components/sidebar/SidebarProvider.tsx @@ -4,7 +4,7 @@ import type { Dispatch, ReactNode, SetStateAction } from 'react'; import { useResponsive } from '@actual-app/components/hooks/useResponsive'; -import { useGlobalPref } from '@desktop-client/hooks/useGlobalPref'; +import { useGlobalPref } from '#hooks/useGlobalPref'; type SidebarContextValue = { hidden: boolean; diff --git a/packages/desktop-client/src/components/sidebar/index.tsx b/packages/desktop-client/src/components/sidebar/index.tsx index e9fbdc0e05..b1dbcd6daa 100644 --- a/packages/desktop-client/src/components/sidebar/index.tsx +++ b/packages/desktop-client/src/components/sidebar/index.tsx @@ -7,7 +7,7 @@ import { useDebounceCallback } from 'usehooks-ts'; import { Sidebar } from './Sidebar'; import { useSidebar } from './SidebarProvider'; -import { useGlobalPref } from '@desktop-client/hooks/useGlobalPref'; +import { useGlobalPref } from '#hooks/useGlobalPref'; export function FloatableSidebar() { const [floatingSidebar] = useGlobalPref('floatingSidebar'); diff --git a/packages/desktop-client/src/components/sort.tsx b/packages/desktop-client/src/components/sort.tsx index 517f317036..90612ab59a 100644 --- a/packages/desktop-client/src/components/sort.tsx +++ b/packages/desktop-client/src/components/sort.tsx @@ -11,8 +11,8 @@ import { useDrag, useDrop } from 'react-dnd'; import { theme } from '@actual-app/components/theme'; import { View } from '@actual-app/components/view'; -import { useDragRef } from '@desktop-client/hooks/useDragRef'; -import { useMergedRefs } from '@desktop-client/hooks/useMergedRefs'; +import { useDragRef } from '#hooks/useDragRef'; +import { useMergedRefs } from '#hooks/useMergedRefs'; export type DragState = { state: 'start-preview' | 'start' | 'end'; diff --git a/packages/desktop-client/src/components/spreadsheet/CellValue.tsx b/packages/desktop-client/src/components/spreadsheet/CellValue.tsx index f11b146c6c..7b07bb9514 100644 --- a/packages/desktop-client/src/components/spreadsheet/CellValue.tsx +++ b/packages/desktop-client/src/components/spreadsheet/CellValue.tsx @@ -4,18 +4,18 @@ import type { ComponentPropsWithoutRef, CSSProperties, ReactNode } from 'react'; import { Text } from '@actual-app/components/text'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { PrivacyFilter } from '@desktop-client/components/PrivacyFilter'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import type { FormatType } from '@desktop-client/hooks/useFormat'; -import { useSheetName } from '@desktop-client/hooks/useSheetName'; -import { useSheetValue } from '@desktop-client/hooks/useSheetValue'; +import { FinancialText } from '#components/FinancialText'; +import { PrivacyFilter } from '#components/PrivacyFilter'; +import { useFormat } from '#hooks/useFormat'; +import type { FormatType } from '#hooks/useFormat'; +import { useSheetName } from '#hooks/useSheetName'; +import { useSheetValue } from '#hooks/useSheetValue'; import type { Binding, SheetFields, SheetNames, Spreadsheets, -} from '@desktop-client/spreadsheet'; +} from '#spreadsheet'; type CellValueProps< SheetName extends SheetNames, diff --git a/packages/desktop-client/src/components/table.tsx b/packages/desktop-client/src/components/table.tsx index e37627d5b5..f52bb1de96 100644 --- a/packages/desktop-client/src/components/table.tsx +++ b/packages/desktop-client/src/components/table.tsx @@ -41,21 +41,21 @@ import { mergeConditionalPrivacyFilterProps, } from './PrivacyFilter'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import type { FormatType } from '@desktop-client/hooks/useFormat'; -import { useModalState } from '@desktop-client/hooks/useModalState'; +import { useFormat } from '#hooks/useFormat'; +import type { FormatType } from '#hooks/useFormat'; +import { useModalState } from '#hooks/useModalState'; import { AvoidRefocusScrollProvider, useProperFocus, -} from '@desktop-client/hooks/useProperFocus'; -import { useSelectedItems } from '@desktop-client/hooks/useSelected'; -import { useSheetValue } from '@desktop-client/hooks/useSheetValue'; +} from '#hooks/useProperFocus'; +import { useSelectedItems } from '#hooks/useSelected'; +import { useSheetValue } from '#hooks/useSheetValue'; import type { Binding, SheetFields, SheetNames, Spreadsheets, -} from '@desktop-client/spreadsheet'; +} from '#spreadsheet'; export const ROW_HEIGHT = 32; diff --git a/packages/desktop-client/src/components/tags/ManageTags.tsx b/packages/desktop-client/src/components/tags/ManageTags.tsx index 36a941e76b..13c485316a 100644 --- a/packages/desktop-client/src/components/tags/ManageTags.tsx +++ b/packages/desktop-client/src/components/tags/ManageTags.tsx @@ -16,16 +16,10 @@ import { TagCreationRow } from './TagCreationRow'; import { TagsHeader } from './TagsHeader'; import { TagsList } from './TagsList'; -import { Search } from '@desktop-client/components/common/Search'; -import { - SelectedProvider, - useSelected, -} from '@desktop-client/hooks/useSelected'; -import { useTags } from '@desktop-client/hooks/useTags'; -import { - useDeleteTagsMutation, - useDiscoverTagsMutation, -} from '@desktop-client/tags'; +import { Search } from '#components/common/Search'; +import { SelectedProvider, useSelected } from '#hooks/useSelected'; +import { useTags } from '#hooks/useTags'; +import { useDeleteTagsMutation, useDiscoverTagsMutation } from '#tags'; export function ManageTags() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/tags/ManageTagsPage.tsx b/packages/desktop-client/src/components/tags/ManageTagsPage.tsx index 486261e270..f66bce1930 100644 --- a/packages/desktop-client/src/components/tags/ManageTagsPage.tsx +++ b/packages/desktop-client/src/components/tags/ManageTagsPage.tsx @@ -3,7 +3,7 @@ import { useTranslation } from 'react-i18next'; import { ManageTags } from './ManageTags'; -import { Page } from '@desktop-client/components/Page'; +import { Page } from '#components/Page'; export const ManageTagsPage = () => { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/tags/TagCreationRow.tsx b/packages/desktop-client/src/components/tags/TagCreationRow.tsx index 4823ee0a14..ba3a1cb461 100644 --- a/packages/desktop-client/src/components/tags/TagCreationRow.tsx +++ b/packages/desktop-client/src/components/tags/TagCreationRow.tsx @@ -10,15 +10,11 @@ import { View } from '@actual-app/components/view'; import type { TagEntity } from 'loot-core/types/models'; -import { - InputCell, - Row, - useTableNavigator, -} from '@desktop-client/components/table'; -import { useInitialMount } from '@desktop-client/hooks/useInitialMount'; -import { useProperFocus } from '@desktop-client/hooks/useProperFocus'; -import { useTagCSS } from '@desktop-client/hooks/useTagCSS'; -import { useCreateTagMutation } from '@desktop-client/tags'; +import { InputCell, Row, useTableNavigator } from '#components/table'; +import { useInitialMount } from '#hooks/useInitialMount'; +import { useProperFocus } from '#hooks/useProperFocus'; +import { useTagCSS } from '#hooks/useTagCSS'; +import { useCreateTagMutation } from '#tags'; type TagCreationRowProps = { tags: TagEntity[]; diff --git a/packages/desktop-client/src/components/tags/TagEditor.tsx b/packages/desktop-client/src/components/tags/TagEditor.tsx index 4ed6605ff6..eee83e74fa 100644 --- a/packages/desktop-client/src/components/tags/TagEditor.tsx +++ b/packages/desktop-client/src/components/tags/TagEditor.tsx @@ -5,8 +5,8 @@ import { ColorPicker } from '@actual-app/components/color-picker'; import type { TagEntity } from 'loot-core/types/models'; -import { useTagCSS } from '@desktop-client/hooks/useTagCSS'; -import { useUpdateTagMutation } from '@desktop-client/tags'; +import { useTagCSS } from '#hooks/useTagCSS'; +import { useUpdateTagMutation } from '#tags'; type TagEditorProps = { tag: TagEntity; diff --git a/packages/desktop-client/src/components/tags/TagRow.tsx b/packages/desktop-client/src/components/tags/TagRow.tsx index ef1b0181c4..84856868f1 100644 --- a/packages/desktop-client/src/components/tags/TagRow.tsx +++ b/packages/desktop-client/src/components/tags/TagRow.tsx @@ -17,15 +17,12 @@ import { InputCell, Row, SelectCell, -} from '@desktop-client/components/table'; -import { useContextMenu } from '@desktop-client/hooks/useContextMenu'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { useProperFocus } from '@desktop-client/hooks/useProperFocus'; -import { useSelectedDispatch } from '@desktop-client/hooks/useSelected'; -import { - useDeleteTagMutation, - useUpdateTagMutation, -} from '@desktop-client/tags'; +} from '#components/table'; +import { useContextMenu } from '#hooks/useContextMenu'; +import { useNavigate } from '#hooks/useNavigate'; +import { useProperFocus } from '#hooks/useProperFocus'; +import { useSelectedDispatch } from '#hooks/useSelected'; +import { useDeleteTagMutation, useUpdateTagMutation } from '#tags'; type TagRowProps = { tag: TagEntity; diff --git a/packages/desktop-client/src/components/tags/TagsHeader.tsx b/packages/desktop-client/src/components/tags/TagsHeader.tsx index 1922096a7c..b12e2c93c2 100644 --- a/packages/desktop-client/src/components/tags/TagsHeader.tsx +++ b/packages/desktop-client/src/components/tags/TagsHeader.tsx @@ -1,15 +1,8 @@ import React from 'react'; import { useTranslation } from 'react-i18next'; -import { - Cell, - SelectCell, - TableHeader, -} from '@desktop-client/components/table'; -import { - useSelectedDispatch, - useSelectedItems, -} from '@desktop-client/hooks/useSelected'; +import { Cell, SelectCell, TableHeader } from '#components/table'; +import { useSelectedDispatch, useSelectedItems } from '#hooks/useSelected'; export function TagsHeader() { const { t } = useTranslation(); diff --git a/packages/desktop-client/src/components/tags/TagsList.tsx b/packages/desktop-client/src/components/tags/TagsList.tsx index 05d3dc7553..c135089cfa 100644 --- a/packages/desktop-client/src/components/tags/TagsList.tsx +++ b/packages/desktop-client/src/components/tags/TagsList.tsx @@ -6,7 +6,7 @@ import type { TagEntity } from 'loot-core/types/models'; import { TagRow } from './TagRow'; -import { Table, useTableNavigator } from '@desktop-client/components/table'; +import { Table, useTableNavigator } from '#components/table'; type TagsListProps = { tags: TagEntity[]; diff --git a/packages/desktop-client/src/components/transactions/SelectedTransactionsButton.tsx b/packages/desktop-client/src/components/transactions/SelectedTransactionsButton.tsx index 3d3ef2d3bf..579507b59d 100644 --- a/packages/desktop-client/src/components/transactions/SelectedTransactionsButton.tsx +++ b/packages/desktop-client/src/components/transactions/SelectedTransactionsButton.tsx @@ -13,11 +13,11 @@ import { isPreviewId } from 'loot-core/shared/transactions'; import { validForTransfer } from 'loot-core/shared/transfer'; import type { TransactionEntity } from 'loot-core/types/models'; -import { SelectedItemsButton } from '@desktop-client/components/table'; -import { useSchedules } from '@desktop-client/hooks/useSchedules'; -import { useSelectedItems } from '@desktop-client/hooks/useSelected'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { SelectedItemsButton } from '#components/table'; +import { useSchedules } from '#hooks/useSchedules'; +import { useSelectedItems } from '#hooks/useSelected'; +import { pushModal } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; type SelectedTransactionsButtonProps = { getTransaction: (id: string) => TransactionEntity | undefined; diff --git a/packages/desktop-client/src/components/transactions/SimpleTransactionsTable.tsx b/packages/desktop-client/src/components/transactions/SimpleTransactionsTable.tsx index ad4e8e4089..4dd584ccf2 100644 --- a/packages/desktop-client/src/components/transactions/SimpleTransactionsTable.tsx +++ b/packages/desktop-client/src/components/transactions/SimpleTransactionsTable.tsx @@ -13,24 +13,15 @@ import { import * as monthUtils from 'loot-core/shared/months'; import type { TransactionEntity } from 'loot-core/types/models'; -import { FinancialText } from '@desktop-client/components/FinancialText'; -import { - Cell, - Field, - Row, - SelectCell, - Table, -} from '@desktop-client/components/table'; -import { DisplayId } from '@desktop-client/components/util/DisplayId'; -import { useAccount } from '@desktop-client/hooks/useAccount'; -import { useCategory } from '@desktop-client/hooks/useCategory'; -import { useDateFormat } from '@desktop-client/hooks/useDateFormat'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import type { FormatType } from '@desktop-client/hooks/useFormat'; -import { - useSelectedDispatch, - useSelectedItems, -} from '@desktop-client/hooks/useSelected'; +import { FinancialText } from '#components/FinancialText'; +import { Cell, Field, Row, SelectCell, Table } from '#components/table'; +import { DisplayId } from '#components/util/DisplayId'; +import { useAccount } from '#hooks/useAccount'; +import { useCategory } from '#hooks/useCategory'; +import { useDateFormat } from '#hooks/useDateFormat'; +import { useFormat } from '#hooks/useFormat'; +import type { FormatType } from '#hooks/useFormat'; +import { useSelectedDispatch, useSelectedItems } from '#hooks/useSelected'; function serializeTransaction( transaction: TransactionEntity, diff --git a/packages/desktop-client/src/components/transactions/TransactionList.tsx b/packages/desktop-client/src/components/transactions/TransactionList.tsx index cbb3db6b12..160fe2e047 100644 --- a/packages/desktop-client/src/components/transactions/TransactionList.tsx +++ b/packages/desktop-client/src/components/transactions/TransactionList.tsx @@ -32,12 +32,12 @@ import type { import { TransactionTable } from './TransactionsTable'; import type { TransactionTableProps } from './TransactionsTable'; -import type { TableHandleRef } from '@desktop-client/components/table'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; -import { useSyncedPref } from '@desktop-client/hooks/useSyncedPref'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import type { TableHandleRef } from '#components/table'; +import { useNavigate } from '#hooks/useNavigate'; +import { useSyncedPref } from '#hooks/useSyncedPref'; +import { pushModal } from '#modals/modalsSlice'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; // When data changes, there are two ways to update the UI: // diff --git a/packages/desktop-client/src/components/transactions/TransactionMenu.tsx b/packages/desktop-client/src/components/transactions/TransactionMenu.tsx index 60fdcd575a..bd83c2f816 100644 --- a/packages/desktop-client/src/components/transactions/TransactionMenu.tsx +++ b/packages/desktop-client/src/components/transactions/TransactionMenu.tsx @@ -12,10 +12,10 @@ import { import { isPreviewId } from 'loot-core/shared/transactions'; import type { TransactionEntity } from 'loot-core/types/models'; -import { useSchedules } from '@desktop-client/hooks/useSchedules'; -import { useSelectedItems } from '@desktop-client/hooks/useSelected'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { useSchedules } from '#hooks/useSchedules'; +import { useSelectedItems } from '#hooks/useSelected'; +import { pushModal } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; type BalanceMenuProps = Omit< ComponentPropsWithoutRef, diff --git a/packages/desktop-client/src/components/transactions/TransactionsTable.test.tsx b/packages/desktop-client/src/components/transactions/TransactionsTable.test.tsx index 66d08d2549..f1cf52aa91 100644 --- a/packages/desktop-client/src/components/transactions/TransactionsTable.test.tsx +++ b/packages/desktop-client/src/components/transactions/TransactionsTable.test.tsx @@ -28,13 +28,13 @@ import type { import { TransactionTable } from './TransactionsTable'; -import { AuthProvider } from '@desktop-client/auth/AuthProvider'; -import { SchedulesProvider } from '@desktop-client/hooks/useCachedSchedules'; -import { SelectedProviderWithItems } from '@desktop-client/hooks/useSelected'; -import { SplitsExpandedProvider } from '@desktop-client/hooks/useSplitsExpanded'; -import { SpreadsheetProvider } from '@desktop-client/hooks/useSpreadsheet'; -import { createTestQueryClient, TestProviders } from '@desktop-client/mocks'; -import { payeeQueries } from '@desktop-client/payees'; +import { AuthProvider } from '#auth/AuthProvider'; +import { SchedulesProvider } from '#hooks/useCachedSchedules'; +import { SelectedProviderWithItems } from '#hooks/useSelected'; +import { SplitsExpandedProvider } from '#hooks/useSplitsExpanded'; +import { SpreadsheetProvider } from '#hooks/useSpreadsheet'; +import { createTestQueryClient, TestProviders } from '#mocks'; +import { payeeQueries } from '#payees'; const queryClient = createTestQueryClient(); diff --git a/packages/desktop-client/src/components/transactions/TransactionsTable.tsx b/packages/desktop-client/src/components/transactions/TransactionsTable.tsx index 87dccf062e..b95dfe78eb 100644 --- a/packages/desktop-client/src/components/transactions/TransactionsTable.tsx +++ b/packages/desktop-client/src/components/transactions/TransactionsTable.tsx @@ -90,13 +90,13 @@ import type { } from './table/utils'; import { TransactionMenu } from './TransactionMenu'; -import { getAccountsById } from '@desktop-client/accounts/accountsSlice'; -import { AccountAutocomplete } from '@desktop-client/components/autocomplete/AccountAutocomplete'; -import { CategoryAutocomplete } from '@desktop-client/components/autocomplete/CategoryAutocomplete'; -import { PayeeAutocomplete } from '@desktop-client/components/autocomplete/PayeeAutocomplete'; -import { getStatusProps } from '@desktop-client/components/schedules/StatusBadge'; -import type { StatusTypes } from '@desktop-client/components/schedules/StatusBadge'; -import { DateSelect } from '@desktop-client/components/select/DateSelect'; +import { getAccountsById } from '#accounts/accountsSlice'; +import { AccountAutocomplete } from '#components/autocomplete/AccountAutocomplete'; +import { CategoryAutocomplete } from '#components/autocomplete/CategoryAutocomplete'; +import { PayeeAutocomplete } from '#components/autocomplete/PayeeAutocomplete'; +import { getStatusProps } from '#components/schedules/StatusBadge'; +import type { StatusTypes } from '#components/schedules/StatusBadge'; +import { DateSelect } from '#components/select/DateSelect'; import { Cell, CellButton, @@ -109,37 +109,31 @@ import { Table, UnexposedCellContent, useTableNavigator, -} from '@desktop-client/components/table'; +} from '#components/table'; import type { TableHandleRef, TableNavigator, TableProps, -} from '@desktop-client/components/table'; +} from '#components/table'; import { SchedulesProvider, useCachedSchedules, -} from '@desktop-client/hooks/useCachedSchedules'; -import { useContextMenu } from '@desktop-client/hooks/useContextMenu'; -import { - DisplayPayeeProvider, - useDisplayPayee, -} from '@desktop-client/hooks/useDisplayPayee'; -import { useLocalPref } from '@desktop-client/hooks/useLocalPref'; -import { useMergedRefs } from '@desktop-client/hooks/useMergedRefs'; -import { usePrevious } from '@desktop-client/hooks/usePrevious'; -import { useProperFocus } from '@desktop-client/hooks/useProperFocus'; -import { - useSelectedDispatch, - useSelectedItems, -} from '@desktop-client/hooks/useSelected'; -import { SheetNameProvider } from '@desktop-client/hooks/useSheetName'; -import { useSplitsExpanded } from '@desktop-client/hooks/useSplitsExpanded'; -import type { SplitsExpandedContextValue } from '@desktop-client/hooks/useSplitsExpanded'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import { NotesTagFormatter } from '@desktop-client/notes/NotesTagFormatter'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { getPayeesById } from '@desktop-client/payees'; -import { useDispatch } from '@desktop-client/redux'; +} from '#hooks/useCachedSchedules'; +import { useContextMenu } from '#hooks/useContextMenu'; +import { DisplayPayeeProvider, useDisplayPayee } from '#hooks/useDisplayPayee'; +import { useLocalPref } from '#hooks/useLocalPref'; +import { useMergedRefs } from '#hooks/useMergedRefs'; +import { usePrevious } from '#hooks/usePrevious'; +import { useProperFocus } from '#hooks/useProperFocus'; +import { useSelectedDispatch, useSelectedItems } from '#hooks/useSelected'; +import { SheetNameProvider } from '#hooks/useSheetName'; +import { useSplitsExpanded } from '#hooks/useSplitsExpanded'; +import type { SplitsExpandedContextValue } from '#hooks/useSplitsExpanded'; +import { pushModal } from '#modals/modalsSlice'; +import { NotesTagFormatter } from '#notes/NotesTagFormatter'; +import { addNotification } from '#notifications/notificationsSlice'; +import { getPayeesById } from '#payees'; +import { useDispatch } from '#redux'; type TransactionHeaderProps = { hasSelected: boolean; diff --git a/packages/desktop-client/src/components/util/AmountInput.tsx b/packages/desktop-client/src/components/util/AmountInput.tsx index f0dad1bf78..3c01d3e206 100644 --- a/packages/desktop-client/src/components/util/AmountInput.tsx +++ b/packages/desktop-client/src/components/util/AmountInput.tsx @@ -18,8 +18,8 @@ import { css, cx } from '@emotion/css'; import type { IntegerAmount } from 'loot-core/shared/util'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useMergedRefs } from '@desktop-client/hooks/useMergedRefs'; +import { useFormat } from '#hooks/useFormat'; +import { useMergedRefs } from '#hooks/useMergedRefs'; type AmountInputProps = { id?: string; diff --git a/packages/desktop-client/src/components/util/DisplayId.tsx b/packages/desktop-client/src/components/util/DisplayId.tsx index a494fec983..3924a793a7 100644 --- a/packages/desktop-client/src/components/util/DisplayId.tsx +++ b/packages/desktop-client/src/components/util/DisplayId.tsx @@ -6,8 +6,8 @@ import { Text } from '@actual-app/components/text'; import { TextOneLine } from '@actual-app/components/text-one-line'; import { theme } from '@actual-app/components/theme'; -import { useAccount } from '@desktop-client/hooks/useAccount'; -import { usePayee } from '@desktop-client/hooks/usePayee'; +import { useAccount } from '#hooks/useAccount'; +import { usePayee } from '#hooks/usePayee'; type DisplayIdProps = { type: 'accounts' | 'payees'; diff --git a/packages/desktop-client/src/components/util/FinancialInput.tsx b/packages/desktop-client/src/components/util/FinancialInput.tsx index 4d33530410..2dd7f8d0ab 100644 --- a/packages/desktop-client/src/components/util/FinancialInput.tsx +++ b/packages/desktop-client/src/components/util/FinancialInput.tsx @@ -7,7 +7,7 @@ import { styles } from '@actual-app/components/styles'; import type { IntegerAmount } from 'loot-core/shared/util'; -import { useFormat } from '@desktop-client/hooks/useFormat'; +import { useFormat } from '#hooks/useFormat'; type FinancialInputProps = Omit< InputProps, diff --git a/packages/desktop-client/src/components/util/GenericInput.tsx b/packages/desktop-client/src/components/util/GenericInput.tsx index 6cf0dd31f2..6fd8311b13 100644 --- a/packages/desktop-client/src/components/util/GenericInput.tsx +++ b/packages/desktop-client/src/components/util/GenericInput.tsx @@ -12,20 +12,20 @@ import type { RecurConfig, RuleConditionOp } from 'loot-core/types/models'; import { AmountInput } from './AmountInput'; import { PercentInput } from './PercentInput'; -import { AccountAutocomplete } from '@desktop-client/components/autocomplete/AccountAutocomplete'; -import { Autocomplete } from '@desktop-client/components/autocomplete/Autocomplete'; -import { CategoryAutocomplete } from '@desktop-client/components/autocomplete/CategoryAutocomplete'; -import { CategoryGroupAutocomplete } from '@desktop-client/components/autocomplete/CategoryGroupAutocomplete'; -import { FilterAutocomplete } from '@desktop-client/components/autocomplete/FilterAutocomplete'; -import { PayeeAutocomplete } from '@desktop-client/components/autocomplete/PayeeAutocomplete'; -import { ReportAutocomplete } from '@desktop-client/components/autocomplete/ReportAutocomplete'; -import { Checkbox } from '@desktop-client/components/forms'; -import { DateSelect } from '@desktop-client/components/select/DateSelect'; -import { RecurringSchedulePicker } from '@desktop-client/components/select/RecurringSchedulePicker'; -import { useCategories } from '@desktop-client/hooks/useCategories'; -import { useDateFormat } from '@desktop-client/hooks/useDateFormat'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { AccountAutocomplete } from '#components/autocomplete/AccountAutocomplete'; +import { Autocomplete } from '#components/autocomplete/Autocomplete'; +import { CategoryAutocomplete } from '#components/autocomplete/CategoryAutocomplete'; +import { CategoryGroupAutocomplete } from '#components/autocomplete/CategoryGroupAutocomplete'; +import { FilterAutocomplete } from '#components/autocomplete/FilterAutocomplete'; +import { PayeeAutocomplete } from '#components/autocomplete/PayeeAutocomplete'; +import { ReportAutocomplete } from '#components/autocomplete/ReportAutocomplete'; +import { Checkbox } from '#components/forms'; +import { DateSelect } from '#components/select/DateSelect'; +import { RecurringSchedulePicker } from '#components/select/RecurringSchedulePicker'; +import { useCategories } from '#hooks/useCategories'; +import { useDateFormat } from '#hooks/useDateFormat'; +import { pushModal } from '#modals/modalsSlice'; +import { useDispatch } from '#redux'; type GenericInputProps = { ref?: Ref; diff --git a/packages/desktop-client/src/components/util/PercentInput.tsx b/packages/desktop-client/src/components/util/PercentInput.tsx index f0ff706326..f51830db87 100644 --- a/packages/desktop-client/src/components/util/PercentInput.tsx +++ b/packages/desktop-client/src/components/util/PercentInput.tsx @@ -5,8 +5,8 @@ import { Input } from '@actual-app/components/input'; import { evalArithmetic } from 'loot-core/shared/arithmetic'; -import { useFormat } from '@desktop-client/hooks/useFormat'; -import { useMergedRefs } from '@desktop-client/hooks/useMergedRefs'; +import { useFormat } from '#hooks/useFormat'; +import { useMergedRefs } from '#hooks/useMergedRefs'; type PercentInputProps = { id?: string; diff --git a/packages/desktop-client/src/hooks/useAccount.ts b/packages/desktop-client/src/hooks/useAccount.ts index cb7bdb8f9a..bd9b7669c9 100644 --- a/packages/desktop-client/src/hooks/useAccount.ts +++ b/packages/desktop-client/src/hooks/useAccount.ts @@ -1,6 +1,6 @@ import { useQuery } from '@tanstack/react-query'; -import { accountQueries } from '@desktop-client/accounts'; +import { accountQueries } from '#accounts'; export function useAccount(id: string) { const query = useQuery({ diff --git a/packages/desktop-client/src/hooks/useAccountPreviewTransactions.ts b/packages/desktop-client/src/hooks/useAccountPreviewTransactions.ts index cf8e0dd233..225ef3c627 100644 --- a/packages/desktop-client/src/hooks/useAccountPreviewTransactions.ts +++ b/packages/desktop-client/src/hooks/useAccountPreviewTransactions.ts @@ -16,7 +16,7 @@ import { useSheetValue } from './useSheetValue'; import { useSyncedPref } from './useSyncedPref'; import { calculateRunningBalancesBottomUp } from './useTransactions'; -import * as bindings from '@desktop-client/spreadsheet/bindings'; +import * as bindings from '#spreadsheet/bindings'; type UseAccountPreviewTransactionsProps = { accountId?: AccountEntity['id'] | undefined; diff --git a/packages/desktop-client/src/hooks/useAccounts.ts b/packages/desktop-client/src/hooks/useAccounts.ts index 2ef67e75ee..bcfdb1afb8 100644 --- a/packages/desktop-client/src/hooks/useAccounts.ts +++ b/packages/desktop-client/src/hooks/useAccounts.ts @@ -1,6 +1,6 @@ import { useQuery } from '@tanstack/react-query'; -import { accountQueries } from '@desktop-client/accounts'; +import { accountQueries } from '#accounts'; export function useAccounts() { return useQuery(accountQueries.list()); diff --git a/packages/desktop-client/src/hooks/useCategories.ts b/packages/desktop-client/src/hooks/useCategories.ts index 340446e547..e706863b1a 100644 --- a/packages/desktop-client/src/hooks/useCategories.ts +++ b/packages/desktop-client/src/hooks/useCategories.ts @@ -2,7 +2,7 @@ import { useQuery } from '@tanstack/react-query'; import { groupById } from 'loot-core/shared/util'; -import { categoryQueries } from '@desktop-client/budget'; +import { categoryQueries } from '#budget'; export function useCategories() { return useQuery(categoryQueries.list()); diff --git a/packages/desktop-client/src/hooks/useCategory.ts b/packages/desktop-client/src/hooks/useCategory.ts index 10e7dc3caa..3ee77f9b85 100644 --- a/packages/desktop-client/src/hooks/useCategory.ts +++ b/packages/desktop-client/src/hooks/useCategory.ts @@ -1,6 +1,6 @@ import { useQuery } from '@tanstack/react-query'; -import { categoryQueries } from '@desktop-client/budget'; +import { categoryQueries } from '#budget'; export function useCategory(id?: string | null) { return useQuery({ diff --git a/packages/desktop-client/src/hooks/useCategoryGroup.ts b/packages/desktop-client/src/hooks/useCategoryGroup.ts index 6ea6cc7bea..f53c7bdea5 100644 --- a/packages/desktop-client/src/hooks/useCategoryGroup.ts +++ b/packages/desktop-client/src/hooks/useCategoryGroup.ts @@ -1,6 +1,6 @@ import { useQuery } from '@tanstack/react-query'; -import { categoryQueries } from '@desktop-client/budget'; +import { categoryQueries } from '#budget'; export function useCategoryGroup(id?: string | null) { return useQuery({ diff --git a/packages/desktop-client/src/hooks/useCategoryPreviewTransactions.ts b/packages/desktop-client/src/hooks/useCategoryPreviewTransactions.ts index 5b41e541c7..6068fe7473 100644 --- a/packages/desktop-client/src/hooks/useCategoryPreviewTransactions.ts +++ b/packages/desktop-client/src/hooks/useCategoryPreviewTransactions.ts @@ -8,7 +8,7 @@ import { useCategoryScheduleGoalTemplates } from './useCategoryScheduleGoalTempl import { usePreviewTransactions } from './usePreviewTransactions'; import { useSheetValue } from './useSheetValue'; -import { categoryBalance } from '@desktop-client/spreadsheet/bindings'; +import { categoryBalance } from '#spreadsheet/bindings'; type UseCategoryPreviewTransactionsProps = { categoryId: CategoryEntity['id']; diff --git a/packages/desktop-client/src/hooks/useClosedAccounts.ts b/packages/desktop-client/src/hooks/useClosedAccounts.ts index 051c933428..35a5988f74 100644 --- a/packages/desktop-client/src/hooks/useClosedAccounts.ts +++ b/packages/desktop-client/src/hooks/useClosedAccounts.ts @@ -1,6 +1,6 @@ import { useQuery } from '@tanstack/react-query'; -import { accountQueries } from '@desktop-client/accounts'; +import { accountQueries } from '#accounts'; export function useClosedAccounts() { return useQuery(accountQueries.listClosed()); diff --git a/packages/desktop-client/src/hooks/useCommonPayees.ts b/packages/desktop-client/src/hooks/useCommonPayees.ts index 8148b4d1d8..5b4a38d551 100644 --- a/packages/desktop-client/src/hooks/useCommonPayees.ts +++ b/packages/desktop-client/src/hooks/useCommonPayees.ts @@ -1,6 +1,6 @@ import { useQuery } from '@tanstack/react-query'; -import { payeeQueries } from '@desktop-client/payees'; +import { payeeQueries } from '#payees'; export function useCommonPayees() { return useQuery(payeeQueries.listCommon()); diff --git a/packages/desktop-client/src/hooks/useDashboardPages.ts b/packages/desktop-client/src/hooks/useDashboardPages.ts index 5af92f8004..e1c561c47b 100644 --- a/packages/desktop-client/src/hooks/useDashboardPages.ts +++ b/packages/desktop-client/src/hooks/useDashboardPages.ts @@ -5,7 +5,7 @@ import type { DashboardWidgetEntity, } from 'loot-core/types/models'; -import { dashboardQueries } from '@desktop-client/reports'; +import { dashboardQueries } from '#reports'; export function useDashboardPages() { return useQuery(dashboardQueries.listDashboardPages()); diff --git a/packages/desktop-client/src/hooks/useDashboardWidget.ts b/packages/desktop-client/src/hooks/useDashboardWidget.ts index db7e6b356b..6773360565 100644 --- a/packages/desktop-client/src/hooks/useDashboardWidget.ts +++ b/packages/desktop-client/src/hooks/useDashboardWidget.ts @@ -2,7 +2,7 @@ import { useQuery } from '@tanstack/react-query'; import type { DashboardWidgetEntity } from 'loot-core/types/models'; -import { dashboardQueries } from '@desktop-client/reports'; +import { dashboardQueries } from '#reports'; type UseDashboardWidgetProps = Partial< Pick diff --git a/packages/desktop-client/src/hooks/useFailedAccounts.ts b/packages/desktop-client/src/hooks/useFailedAccounts.ts index d6a0ff02f5..8a8585a5a1 100644 --- a/packages/desktop-client/src/hooks/useFailedAccounts.ts +++ b/packages/desktop-client/src/hooks/useFailedAccounts.ts @@ -1,6 +1,6 @@ import { useMemo } from 'react'; -import { useSelector } from '@desktop-client/redux'; +import { useSelector } from '#redux'; export function useFailedAccounts() { const failedAccounts = useSelector(state => state.account.failedAccounts); diff --git a/packages/desktop-client/src/hooks/useFormulaExecution.ts b/packages/desktop-client/src/hooks/useFormulaExecution.ts index da8186cf4d..377605967f 100644 --- a/packages/desktop-client/src/hooks/useFormulaExecution.ts +++ b/packages/desktop-client/src/hooks/useFormulaExecution.ts @@ -11,7 +11,7 @@ import type { RuleConditionEntity, TimeFrame } from 'loot-core/types/models'; import { useLocale } from './useLocale'; -import { getLiveRange } from '@desktop-client/components/reports/getLiveRange'; +import { getLiveRange } from '#components/reports/getLiveRange'; type QueryConfig = { conditions?: RuleConditionEntity[]; diff --git a/packages/desktop-client/src/hooks/useGlobalPref.ts b/packages/desktop-client/src/hooks/useGlobalPref.ts index e2ea61c013..08e931d31c 100644 --- a/packages/desktop-client/src/hooks/useGlobalPref.ts +++ b/packages/desktop-client/src/hooks/useGlobalPref.ts @@ -2,8 +2,8 @@ import { useCallback } from 'react'; import type { GlobalPrefs } from 'loot-core/types/prefs'; -import { saveGlobalPrefs } from '@desktop-client/prefs/prefsSlice'; -import { useDispatch, useSelector } from '@desktop-client/redux'; +import { saveGlobalPrefs } from '#prefs/prefsSlice'; +import { useDispatch, useSelector } from '#redux'; type SetGlobalPrefAction = ( value: GlobalPrefs[K], diff --git a/packages/desktop-client/src/hooks/useLocationPermission.ts b/packages/desktop-client/src/hooks/useLocationPermission.ts index 5f968fae44..90a4e13403 100644 --- a/packages/desktop-client/src/hooks/useLocationPermission.ts +++ b/packages/desktop-client/src/hooks/useLocationPermission.ts @@ -4,7 +4,7 @@ import { useResponsive } from '@actual-app/components/hooks/useResponsive'; import { useFeatureFlag } from './useFeatureFlag'; -import { locationService } from '@desktop-client/payees/location'; +import { locationService } from '#payees/location'; /** * Custom hook to manage geolocation permission status diff --git a/packages/desktop-client/src/hooks/useMetaThemeColor.test.ts b/packages/desktop-client/src/hooks/useMetaThemeColor.test.ts index 6f578862e9..3a18f2a4c8 100644 --- a/packages/desktop-client/src/hooks/useMetaThemeColor.test.ts +++ b/packages/desktop-client/src/hooks/useMetaThemeColor.test.ts @@ -3,11 +3,11 @@ import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest'; import { useMetaThemeColor } from './useMetaThemeColor'; -import { usePreferredDarkTheme, useTheme } from '@desktop-client/style/theme'; +import { usePreferredDarkTheme, useTheme } from '#style/theme'; const DEFAULT_THEME_COLOR = '#5c3dbb'; -vi.mock('@desktop-client/style/theme', () => ({ +vi.mock('#style/theme', () => ({ useTheme: vi.fn(), usePreferredDarkTheme: vi.fn(), })); diff --git a/packages/desktop-client/src/hooks/useMetaThemeColor.ts b/packages/desktop-client/src/hooks/useMetaThemeColor.ts index 1bf57e13ad..991095725e 100644 --- a/packages/desktop-client/src/hooks/useMetaThemeColor.ts +++ b/packages/desktop-client/src/hooks/useMetaThemeColor.ts @@ -1,6 +1,6 @@ import { useEffect } from 'react'; -import { usePreferredDarkTheme, useTheme } from '@desktop-client/style/theme'; +import { usePreferredDarkTheme, useTheme } from '#style/theme'; const VAR_STRING_REGEX = /^var\((--.*)\)$/; const DEFAULT_THEME_COLOR = '#5c3dbb'; diff --git a/packages/desktop-client/src/hooks/useMetadataPref.ts b/packages/desktop-client/src/hooks/useMetadataPref.ts index a5253fb0ad..0f107d48fa 100644 --- a/packages/desktop-client/src/hooks/useMetadataPref.ts +++ b/packages/desktop-client/src/hooks/useMetadataPref.ts @@ -2,8 +2,8 @@ import { useCallback } from 'react'; import type { MetadataPrefs } from 'loot-core/types/prefs'; -import { savePrefs } from '@desktop-client/prefs/prefsSlice'; -import { useDispatch, useSelector } from '@desktop-client/redux'; +import { savePrefs } from '#prefs/prefsSlice'; +import { useDispatch, useSelector } from '#redux'; type SetMetadataPrefAction = ( value: MetadataPrefs[K], diff --git a/packages/desktop-client/src/hooks/useModalState.ts b/packages/desktop-client/src/hooks/useModalState.ts index 0912ae2c68..87b9bf46d9 100644 --- a/packages/desktop-client/src/hooks/useModalState.ts +++ b/packages/desktop-client/src/hooks/useModalState.ts @@ -1,8 +1,8 @@ import { useCallback } from 'react'; -import { popModal } from '@desktop-client/modals/modalsSlice'; -import type { Modal } from '@desktop-client/modals/modalsSlice'; -import { useDispatch, useSelector } from '@desktop-client/redux'; +import { popModal } from '#modals/modalsSlice'; +import type { Modal } from '#modals/modalsSlice'; +import { useDispatch, useSelector } from '#redux'; type ModalState = { onClose: () => void; diff --git a/packages/desktop-client/src/hooks/useNearbyPayees.ts b/packages/desktop-client/src/hooks/useNearbyPayees.ts index 3b5148ebd4..7dcae58342 100644 --- a/packages/desktop-client/src/hooks/useNearbyPayees.ts +++ b/packages/desktop-client/src/hooks/useNearbyPayees.ts @@ -2,7 +2,7 @@ import { useQuery } from '@tanstack/react-query'; import { useLocationPermission } from './useLocationPermission'; -import { payeeQueries } from '@desktop-client/payees'; +import { payeeQueries } from '#payees'; export function useNearbyPayees() { const locationAccess = useLocationPermission(); diff --git a/packages/desktop-client/src/hooks/useOffBudgetAccounts.ts b/packages/desktop-client/src/hooks/useOffBudgetAccounts.ts index d6dde0bfaa..e7d7ddb1ec 100644 --- a/packages/desktop-client/src/hooks/useOffBudgetAccounts.ts +++ b/packages/desktop-client/src/hooks/useOffBudgetAccounts.ts @@ -1,6 +1,6 @@ import { useQuery } from '@tanstack/react-query'; -import { accountQueries } from '@desktop-client/accounts'; +import { accountQueries } from '#accounts'; export function useOffBudgetAccounts() { return useQuery(accountQueries.listOffBudget()); diff --git a/packages/desktop-client/src/hooks/useOnBudgetAccounts.ts b/packages/desktop-client/src/hooks/useOnBudgetAccounts.ts index 8e59e197cb..c2d4dbb69b 100644 --- a/packages/desktop-client/src/hooks/useOnBudgetAccounts.ts +++ b/packages/desktop-client/src/hooks/useOnBudgetAccounts.ts @@ -1,6 +1,6 @@ import { useQuery } from '@tanstack/react-query'; -import { accountQueries } from '@desktop-client/accounts'; +import { accountQueries } from '#accounts'; export function useOnBudgetAccounts() { return useQuery(accountQueries.listOnBudget()); diff --git a/packages/desktop-client/src/hooks/useOrphanedPayees.ts b/packages/desktop-client/src/hooks/useOrphanedPayees.ts index a65639ad9e..1945894d24 100644 --- a/packages/desktop-client/src/hooks/useOrphanedPayees.ts +++ b/packages/desktop-client/src/hooks/useOrphanedPayees.ts @@ -1,6 +1,6 @@ import { useQuery } from '@tanstack/react-query'; -import { payeeQueries } from '@desktop-client/payees/queries'; +import { payeeQueries } from '#payees/queries'; export function useOrphanedPayees() { return useQuery(payeeQueries.listOrphaned()); diff --git a/packages/desktop-client/src/hooks/useOverspentCategories.ts b/packages/desktop-client/src/hooks/useOverspentCategories.ts index f5f6e3c7f6..8995792ed8 100644 --- a/packages/desktop-client/src/hooks/useOverspentCategories.ts +++ b/packages/desktop-client/src/hooks/useOverspentCategories.ts @@ -9,10 +9,7 @@ import { useCategories } from './useCategories'; import { useSpreadsheet } from './useSpreadsheet'; import { useSyncedPref } from './useSyncedPref'; -import { - envelopeBudget, - trackingBudget, -} from '@desktop-client/spreadsheet/bindings'; +import { envelopeBudget, trackingBudget } from '#spreadsheet/bindings'; type UseOverspentCategoriesProps = { month: string; diff --git a/packages/desktop-client/src/hooks/usePayee.ts b/packages/desktop-client/src/hooks/usePayee.ts index 12a92a3d0b..454b66ca28 100644 --- a/packages/desktop-client/src/hooks/usePayee.ts +++ b/packages/desktop-client/src/hooks/usePayee.ts @@ -1,6 +1,6 @@ import { useQuery } from '@tanstack/react-query'; -import { payeeQueries } from '@desktop-client/payees'; +import { payeeQueries } from '#payees'; export function usePayee(id?: string | null) { return useQuery({ diff --git a/packages/desktop-client/src/hooks/usePayeeRuleCounts.ts b/packages/desktop-client/src/hooks/usePayeeRuleCounts.ts index a278a128f9..e8266e9ab3 100644 --- a/packages/desktop-client/src/hooks/usePayeeRuleCounts.ts +++ b/packages/desktop-client/src/hooks/usePayeeRuleCounts.ts @@ -1,6 +1,6 @@ import { useQuery } from '@tanstack/react-query'; -import { payeeQueries } from '@desktop-client/payees'; +import { payeeQueries } from '#payees'; export function usePayeeRuleCounts() { return useQuery(payeeQueries.ruleCounts()); diff --git a/packages/desktop-client/src/hooks/usePayees.ts b/packages/desktop-client/src/hooks/usePayees.ts index 8ad5393ceb..e315146f43 100644 --- a/packages/desktop-client/src/hooks/usePayees.ts +++ b/packages/desktop-client/src/hooks/usePayees.ts @@ -1,6 +1,6 @@ import { useQuery } from '@tanstack/react-query'; -import { getPayeesById, payeeQueries } from '@desktop-client/payees'; +import { getPayeesById, payeeQueries } from '#payees'; export function usePayees() { return useQuery(payeeQueries.list()); diff --git a/packages/desktop-client/src/hooks/useQuery.ts b/packages/desktop-client/src/hooks/useQuery.ts index 48ee1476f8..90dbd62841 100644 --- a/packages/desktop-client/src/hooks/useQuery.ts +++ b/packages/desktop-client/src/hooks/useQuery.ts @@ -3,8 +3,8 @@ import type { DependencyList } from 'react'; import type { Query } from 'loot-core/shared/query'; -import { liveQuery } from '@desktop-client/queries/liveQuery'; -import type { LiveQuery } from '@desktop-client/queries/liveQuery'; +import { liveQuery } from '#queries/liveQuery'; +import type { LiveQuery } from '#queries/liveQuery'; type UseQueryResult = { data: null | ReadonlyArray; diff --git a/packages/desktop-client/src/hooks/useReport.ts b/packages/desktop-client/src/hooks/useReport.ts index 0ab34c717c..be77844326 100644 --- a/packages/desktop-client/src/hooks/useReport.ts +++ b/packages/desktop-client/src/hooks/useReport.ts @@ -1,6 +1,6 @@ import { useQuery } from '@tanstack/react-query'; -import { reportQueries } from '@desktop-client/reports'; +import { reportQueries } from '#reports'; export function useReport(id?: string | null) { return useQuery({ diff --git a/packages/desktop-client/src/hooks/useReports.ts b/packages/desktop-client/src/hooks/useReports.ts index ba208c5271..c9f1b2c029 100644 --- a/packages/desktop-client/src/hooks/useReports.ts +++ b/packages/desktop-client/src/hooks/useReports.ts @@ -1,6 +1,6 @@ import { useQuery } from '@tanstack/react-query'; -import { reportQueries } from '@desktop-client/reports'; +import { reportQueries } from '#reports'; export function useReports() { return useQuery(reportQueries.list()); diff --git a/packages/desktop-client/src/hooks/useScheduleEdit.ts b/packages/desktop-client/src/hooks/useScheduleEdit.ts index 436775e39b..ad6458402d 100644 --- a/packages/desktop-client/src/hooks/useScheduleEdit.ts +++ b/packages/desktop-client/src/hooks/useScheduleEdit.ts @@ -14,10 +14,10 @@ import type { TransactionEntity, } from 'loot-core/types/models'; -import { updateScheduleConditions } from '@desktop-client/components/schedules/schedule-edit-utils'; -import type { ScheduleFormFields } from '@desktop-client/components/schedules/ScheduleEditForm'; -import { aqlQuery } from '@desktop-client/queries/aqlQuery'; -import { liveQuery } from '@desktop-client/queries/liveQuery'; +import { updateScheduleConditions } from '#components/schedules/schedule-edit-utils'; +import type { ScheduleFormFields } from '#components/schedules/ScheduleEditForm'; +import { aqlQuery } from '#queries/aqlQuery'; +import { liveQuery } from '#queries/liveQuery'; export type ScheduleEditState = { isCustom?: boolean; diff --git a/packages/desktop-client/src/hooks/useSchedules.ts b/packages/desktop-client/src/hooks/useSchedules.ts index 5f5d0005cd..a26615b5f5 100644 --- a/packages/desktop-client/src/hooks/useSchedules.ts +++ b/packages/desktop-client/src/hooks/useSchedules.ts @@ -16,9 +16,9 @@ import type { import { useSyncedPref } from './useSyncedPref'; -import { accountFilter } from '@desktop-client/queries'; -import { liveQuery } from '@desktop-client/queries/liveQuery'; -import type { LiveQuery } from '@desktop-client/queries/liveQuery'; +import { accountFilter } from '#queries'; +import { liveQuery } from '#queries/liveQuery'; +import type { LiveQuery } from '#queries/liveQuery'; export type ScheduleStatusLabelType = ReturnType; export type ScheduleStatusLabels = Map< diff --git a/packages/desktop-client/src/hooks/useServerPref.ts b/packages/desktop-client/src/hooks/useServerPref.ts index 2002d54e8e..056d89bfc0 100644 --- a/packages/desktop-client/src/hooks/useServerPref.ts +++ b/packages/desktop-client/src/hooks/useServerPref.ts @@ -2,8 +2,8 @@ import { useCallback } from 'react'; import type { ServerPrefs } from 'loot-core/types/prefs'; -import { saveServerPrefs } from '@desktop-client/prefs/prefsSlice'; -import { useDispatch, useSelector } from '@desktop-client/redux'; +import { saveServerPrefs } from '#prefs/prefsSlice'; +import { useDispatch, useSelector } from '#redux'; type SetServerPrefAction = ( value: ServerPrefs[K], diff --git a/packages/desktop-client/src/hooks/useSheetName.tsx b/packages/desktop-client/src/hooks/useSheetName.tsx index ad63f5f5c6..d0df68c416 100644 --- a/packages/desktop-client/src/hooks/useSheetName.tsx +++ b/packages/desktop-client/src/hooks/useSheetName.tsx @@ -2,11 +2,7 @@ import { createContext, useContext } from 'react'; import type { PropsWithChildren } from 'react'; -import type { - Binding, - SheetFields, - SheetNames, -} from '@desktop-client/spreadsheet'; +import type { Binding, SheetFields, SheetNames } from '#spreadsheet'; function unresolveName(name) { const idx = name.indexOf('!'); diff --git a/packages/desktop-client/src/hooks/useSheetValue.ts b/packages/desktop-client/src/hooks/useSheetValue.ts index f87643f198..dac6ef8495 100644 --- a/packages/desktop-client/src/hooks/useSheetValue.ts +++ b/packages/desktop-client/src/hooks/useSheetValue.ts @@ -9,7 +9,7 @@ import type { SheetFields, SheetNames, Spreadsheets, -} from '@desktop-client/spreadsheet'; +} from '#spreadsheet'; type SheetValueResult< SheetName extends SheetNames, diff --git a/packages/desktop-client/src/hooks/useSyncServerStatus.ts b/packages/desktop-client/src/hooks/useSyncServerStatus.ts index 797d6ba570..8743be6609 100644 --- a/packages/desktop-client/src/hooks/useSyncServerStatus.ts +++ b/packages/desktop-client/src/hooks/useSyncServerStatus.ts @@ -1,5 +1,5 @@ -import { useServerURL } from '@desktop-client/components/ServerContext'; -import { useSelector } from '@desktop-client/redux'; +import { useServerURL } from '#components/ServerContext'; +import { useSelector } from '#redux'; type SyncServerStatus = 'offline' | 'no-server' | 'online'; diff --git a/packages/desktop-client/src/hooks/useSyncedPref.ts b/packages/desktop-client/src/hooks/useSyncedPref.ts index 2d18e458ce..8c09b0b96a 100644 --- a/packages/desktop-client/src/hooks/useSyncedPref.ts +++ b/packages/desktop-client/src/hooks/useSyncedPref.ts @@ -2,8 +2,8 @@ import { useCallback } from 'react'; import type { SyncedPrefs } from 'loot-core/types/prefs'; -import { saveSyncedPrefs } from '@desktop-client/prefs/prefsSlice'; -import { useDispatch, useSelector } from '@desktop-client/redux'; +import { saveSyncedPrefs } from '#prefs/prefsSlice'; +import { useDispatch, useSelector } from '#redux'; type SetSyncedPrefAction = ( value: SyncedPrefs[K], diff --git a/packages/desktop-client/src/hooks/useSyncedPrefs.ts b/packages/desktop-client/src/hooks/useSyncedPrefs.ts index 8f8bf2c72e..316977c5bc 100644 --- a/packages/desktop-client/src/hooks/useSyncedPrefs.ts +++ b/packages/desktop-client/src/hooks/useSyncedPrefs.ts @@ -2,8 +2,8 @@ import { useCallback } from 'react'; import type { SyncedPrefs } from 'loot-core/types/prefs'; -import { saveSyncedPrefs } from '@desktop-client/prefs/prefsSlice'; -import { useDispatch, useSelector } from '@desktop-client/redux'; +import { saveSyncedPrefs } from '#prefs/prefsSlice'; +import { useDispatch, useSelector } from '#redux'; type SetSyncedPrefsAction = (value: Partial) => void; diff --git a/packages/desktop-client/src/hooks/useTagCSS.ts b/packages/desktop-client/src/hooks/useTagCSS.ts index 25efdaba68..080b7fc650 100644 --- a/packages/desktop-client/src/hooks/useTagCSS.ts +++ b/packages/desktop-client/src/hooks/useTagCSS.ts @@ -7,7 +7,7 @@ import type { Theme } from 'loot-core/types/prefs'; import { useTags } from './useTags'; -import { useTheme } from '@desktop-client/style'; +import { useTheme } from '#style'; export function useTagCSS() { const { data: tags = [] } = useTags(); diff --git a/packages/desktop-client/src/hooks/useTags.ts b/packages/desktop-client/src/hooks/useTags.ts index 7856084c92..e6a9fcb183 100644 --- a/packages/desktop-client/src/hooks/useTags.ts +++ b/packages/desktop-client/src/hooks/useTags.ts @@ -1,6 +1,6 @@ import { useQuery } from '@tanstack/react-query'; -import { tagQueries } from '@desktop-client/tags/queries'; +import { tagQueries } from '#tags/queries'; export function useTags() { return useQuery(tagQueries.list()); diff --git a/packages/desktop-client/src/hooks/useThemeCatalog.ts b/packages/desktop-client/src/hooks/useThemeCatalog.ts index 31946ea3ff..db92ede285 100644 --- a/packages/desktop-client/src/hooks/useThemeCatalog.ts +++ b/packages/desktop-client/src/hooks/useThemeCatalog.ts @@ -1,6 +1,6 @@ import { useEffect, useState } from 'react'; -import type { CatalogTheme } from '@desktop-client/style/customThemes'; +import type { CatalogTheme } from '#style/customThemes'; const CATALOG_URL = `https://raw.githubusercontent.com/actualbudget/actual/${process.env.REACT_APP_BRANCH || 'master'}/packages/desktop-client/src/data/customThemeCatalog.json`; diff --git a/packages/desktop-client/src/hooks/useTransactionBatchActions.ts b/packages/desktop-client/src/hooks/useTransactionBatchActions.ts index d13f9295ef..e3fde53646 100644 --- a/packages/desktop-client/src/hooks/useTransactionBatchActions.ts +++ b/packages/desktop-client/src/hooks/useTransactionBatchActions.ts @@ -20,10 +20,10 @@ import type { TransactionEntity, } from 'loot-core/types/models'; -import { pushModal } from '@desktop-client/modals/modalsSlice'; -import type { Modal as ModalType } from '@desktop-client/modals/modalsSlice'; -import { aqlQuery } from '@desktop-client/queries/aqlQuery'; -import { useDispatch } from '@desktop-client/redux'; +import { pushModal } from '#modals/modalsSlice'; +import type { Modal as ModalType } from '#modals/modalsSlice'; +import { aqlQuery } from '#queries/aqlQuery'; +import { useDispatch } from '#redux'; type BatchEditProps = { name: keyof TransactionEntity; diff --git a/packages/desktop-client/src/hooks/useTransactions.ts b/packages/desktop-client/src/hooks/useTransactions.ts index 5ea7fd10bd..f581707edf 100644 --- a/packages/desktop-client/src/hooks/useTransactions.ts +++ b/packages/desktop-client/src/hooks/useTransactions.ts @@ -12,7 +12,7 @@ import type { IntegerAmount } from 'loot-core/shared/util'; import type { TransactionEntity } from 'loot-core/types/models'; import type { ServerEvents } from 'loot-core/types/server-events'; -import { transactionQueries } from '@desktop-client/transactions'; +import { transactionQueries } from '#transactions'; // Mirrors the `splits` AQL option from the server type TransactionSplitsOption = 'all' | 'inline' | 'grouped' | 'none'; diff --git a/packages/desktop-client/src/hooks/useTransactionsSearch.ts b/packages/desktop-client/src/hooks/useTransactionsSearch.ts index 5d99cf6dea..de8756a7d6 100644 --- a/packages/desktop-client/src/hooks/useTransactionsSearch.ts +++ b/packages/desktop-client/src/hooks/useTransactionsSearch.ts @@ -4,7 +4,7 @@ import debounce from 'lodash/debounce'; import type { Query } from 'loot-core/shared/query'; -import * as queries from '@desktop-client/queries'; +import * as queries from '#queries'; type UseTransactionsSearchProps = { updateQuery: (updateFn: (searchQuery: Query) => Query) => void; diff --git a/packages/desktop-client/src/hooks/useUndo.ts b/packages/desktop-client/src/hooks/useUndo.ts index febe8f0aa6..38fc4c3055 100644 --- a/packages/desktop-client/src/hooks/useUndo.ts +++ b/packages/desktop-client/src/hooks/useUndo.ts @@ -3,10 +3,10 @@ import { useTranslation } from 'react-i18next'; import { useResponsive } from '@actual-app/components/hooks/useResponsive'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import type { Notification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; -import { redo, undo } from '@desktop-client/undo'; +import { addNotification } from '#notifications/notificationsSlice'; +import type { Notification } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; +import { redo, undo } from '#undo'; type UndoActions = { undo: () => void; diff --git a/packages/desktop-client/src/hooks/useUpdatedAccounts.ts b/packages/desktop-client/src/hooks/useUpdatedAccounts.ts index b0e29dcb69..89fd1ff264 100644 --- a/packages/desktop-client/src/hooks/useUpdatedAccounts.ts +++ b/packages/desktop-client/src/hooks/useUpdatedAccounts.ts @@ -1,4 +1,4 @@ -import { useSelector } from '@desktop-client/redux'; +import { useSelector } from '#redux'; export function useUpdatedAccounts() { return useSelector(state => state.account.updatedAccounts); diff --git a/packages/desktop-client/src/modals/modalsSlice.ts b/packages/desktop-client/src/modals/modalsSlice.ts index a204f88c8b..5b20a356e5 100644 --- a/packages/desktop-client/src/modals/modalsSlice.ts +++ b/packages/desktop-client/src/modals/modalsSlice.ts @@ -20,11 +20,11 @@ import type { } from 'loot-core/types/models'; import type { Template } from 'loot-core/types/models/templates'; -import { accountQueries } from '@desktop-client/accounts'; -import { resetApp, setAppState } from '@desktop-client/app/appSlice'; -import type { SelectLinkedAccountsModalProps } from '@desktop-client/components/modals/SelectLinkedAccountsModal'; -import { createAppAsyncThunk } from '@desktop-client/redux'; -import { signOut } from '@desktop-client/users/usersSlice'; +import { accountQueries } from '#accounts'; +import { resetApp, setAppState } from '#app/appSlice'; +import type { SelectLinkedAccountsModalProps } from '#components/modals/SelectLinkedAccountsModal'; +import { createAppAsyncThunk } from '#redux'; +import { signOut } from '#users/usersSlice'; const sliceName = 'modals'; diff --git a/packages/desktop-client/src/notes/DesktopLinkedNotes.tsx b/packages/desktop-client/src/notes/DesktopLinkedNotes.tsx index 6463100770..dca58b81e5 100644 --- a/packages/desktop-client/src/notes/DesktopLinkedNotes.tsx +++ b/packages/desktop-client/src/notes/DesktopLinkedNotes.tsx @@ -7,9 +7,9 @@ import { isElectron } from 'loot-core/shared/environment'; import { normalizeUrl } from './linkParser'; -import { Link } from '@desktop-client/components/common/Link'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { Link } from '#components/common/Link'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; type DesktopLinkedNotesProps = { displayText: string; diff --git a/packages/desktop-client/src/notes/DesktopTaggedNotes.tsx b/packages/desktop-client/src/notes/DesktopTaggedNotes.tsx index 55f98af8f3..38a06096b4 100644 --- a/packages/desktop-client/src/notes/DesktopTaggedNotes.tsx +++ b/packages/desktop-client/src/notes/DesktopTaggedNotes.tsx @@ -3,7 +3,7 @@ import React from 'react'; import { Button } from '@actual-app/components/button'; import { View } from '@actual-app/components/view'; -import { useTagCSS } from '@desktop-client/hooks/useTagCSS'; +import { useTagCSS } from '#hooks/useTagCSS'; type DesktopTaggedNotesProps = { content: string; diff --git a/packages/desktop-client/src/notes/MobileLinkedNotes.tsx b/packages/desktop-client/src/notes/MobileLinkedNotes.tsx index e66fc9a494..65845cdfad 100644 --- a/packages/desktop-client/src/notes/MobileLinkedNotes.tsx +++ b/packages/desktop-client/src/notes/MobileLinkedNotes.tsx @@ -9,8 +9,8 @@ import { isElectron } from 'loot-core/shared/environment'; import { normalizeUrl } from './linkParser'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; type MobileLinkedNotesProps = { displayText: string; diff --git a/packages/desktop-client/src/notes/MobileTaggedNotes.tsx b/packages/desktop-client/src/notes/MobileTaggedNotes.tsx index 38601dd959..ad40654e74 100644 --- a/packages/desktop-client/src/notes/MobileTaggedNotes.tsx +++ b/packages/desktop-client/src/notes/MobileTaggedNotes.tsx @@ -2,7 +2,7 @@ import React from 'react'; import { Text } from '@actual-app/components/text'; -import { useTagCSS } from '@desktop-client/hooks/useTagCSS'; +import { useTagCSS } from '#hooks/useTagCSS'; type MobileTaggedNotesProps = { content: string; diff --git a/packages/desktop-client/src/notifications/notificationsSlice.ts b/packages/desktop-client/src/notifications/notificationsSlice.ts index 9a5a6994b6..17de482dce 100644 --- a/packages/desktop-client/src/notifications/notificationsSlice.ts +++ b/packages/desktop-client/src/notifications/notificationsSlice.ts @@ -3,7 +3,7 @@ import type { PayloadAction } from '@reduxjs/toolkit'; import { t } from 'i18next'; import { v4 as uuidv4 } from 'uuid'; -import { resetApp } from '@desktop-client/app/appSlice'; +import { resetApp } from '#app/appSlice'; const sliceName = 'notifications'; diff --git a/packages/desktop-client/src/payees/mutations.ts b/packages/desktop-client/src/payees/mutations.ts index 23ddca1ad3..2ad116449a 100644 --- a/packages/desktop-client/src/payees/mutations.ts +++ b/packages/desktop-client/src/payees/mutations.ts @@ -10,9 +10,9 @@ import type { PayeeEntity } from 'loot-core/types/models'; import { locationService } from './location'; import { payeeQueries } from './queries'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; -import type { AppDispatch } from '@desktop-client/redux/store'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; +import type { AppDispatch } from '#redux/store'; function invalidateQueries(queryClient: QueryClient, queryKey?: QueryKey) { void queryClient.invalidateQueries({ diff --git a/packages/desktop-client/src/payees/queries.ts b/packages/desktop-client/src/payees/queries.ts index eeef259bd4..5fbc678dde 100644 --- a/packages/desktop-client/src/payees/queries.ts +++ b/packages/desktop-client/src/payees/queries.ts @@ -12,7 +12,7 @@ import type { import { locationService } from './location'; -import { getAccountsById } from '@desktop-client/accounts/accountsSlice'; +import { getAccountsById } from '#accounts/accountsSlice'; export const payeeQueries = { all: () => ['payees'], diff --git a/packages/desktop-client/src/prefs/prefsSlice.ts b/packages/desktop-client/src/prefs/prefsSlice.ts index 48b52a8a95..238315571c 100644 --- a/packages/desktop-client/src/prefs/prefsSlice.ts +++ b/packages/desktop-client/src/prefs/prefsSlice.ts @@ -10,11 +10,11 @@ import type { SyncedPrefs, } from 'loot-core/types/prefs'; -import { resetApp } from '@desktop-client/app/appSlice'; -import { setI18NextLanguage } from '@desktop-client/i18n'; -import { closeModal } from '@desktop-client/modals/modalsSlice'; -import { createAppAsyncThunk } from '@desktop-client/redux'; -import { getUserData } from '@desktop-client/users/usersSlice'; +import { resetApp } from '#app/appSlice'; +import { setI18NextLanguage } from '#i18n'; +import { closeModal } from '#modals/modalsSlice'; +import { createAppAsyncThunk } from '#redux'; +import { getUserData } from '#users/usersSlice'; const sliceName = 'prefs'; diff --git a/packages/desktop-client/src/redux/store.ts b/packages/desktop-client/src/redux/store.ts index fd601d8c3d..4885d63b68 100644 --- a/packages/desktop-client/src/redux/store.ts +++ b/packages/desktop-client/src/redux/store.ts @@ -9,36 +9,36 @@ import type { QueryClient } from '@tanstack/react-query'; import { name as accountsSliceName, reducer as accountsSliceReducer, -} from '@desktop-client/accounts/accountsSlice'; +} from '#accounts/accountsSlice'; import { name as appSliceName, reducer as appSliceReducer, -} from '@desktop-client/app/appSlice'; +} from '#app/appSlice'; import { name as budgetfilesSliceName, reducer as budgetfilesSliceReducer, -} from '@desktop-client/budgetfiles/budgetfilesSlice'; +} from '#budgetfiles/budgetfilesSlice'; import { name as modalsSliceName, reducer as modalsSliceReducer, -} from '@desktop-client/modals/modalsSlice'; +} from '#modals/modalsSlice'; import { addNotification, name as notificationsSliceName, reducer as notificationsSliceReducer, -} from '@desktop-client/notifications/notificationsSlice'; +} from '#notifications/notificationsSlice'; import { name as prefsSliceName, reducer as prefsSliceReducer, -} from '@desktop-client/prefs/prefsSlice'; +} from '#prefs/prefsSlice'; import { name as transactionsSliceName, reducer as transactionsSliceReducer, -} from '@desktop-client/transactions/transactionsSlice'; +} from '#transactions/transactionsSlice'; import { name as usersSliceName, reducer as usersSliceReducer, -} from '@desktop-client/users/usersSlice'; +} from '#users/usersSlice'; const rootReducer = combineReducers({ [accountsSliceName]: accountsSliceReducer, diff --git a/packages/desktop-client/src/reports/mutations.ts b/packages/desktop-client/src/reports/mutations.ts index f8126f192a..b9003741ce 100644 --- a/packages/desktop-client/src/reports/mutations.ts +++ b/packages/desktop-client/src/reports/mutations.ts @@ -18,9 +18,9 @@ import type { import { dashboardQueries, reportQueries } from './queries'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; -import type { AppDispatch } from '@desktop-client/redux/store'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; +import type { AppDispatch } from '#redux/store'; const sendThrow: typeof send = async (name, args) => { const { error, data } = await sendCatch(name, args); diff --git a/packages/desktop-client/src/reports/queries.ts b/packages/desktop-client/src/reports/queries.ts index a4e73d2137..031bddc01f 100644 --- a/packages/desktop-client/src/reports/queries.ts +++ b/packages/desktop-client/src/reports/queries.ts @@ -8,7 +8,7 @@ import type { DashboardWidgetEntity, } from 'loot-core/types/models'; -import { aqlQuery } from '@desktop-client/queries/aqlQuery'; +import { aqlQuery } from '#queries/aqlQuery'; export const reportQueries = { all: () => ['reports'], diff --git a/packages/desktop-client/src/spreadsheet/bindings.ts b/packages/desktop-client/src/spreadsheet/bindings.ts index 853079905c..1de825a6db 100644 --- a/packages/desktop-client/src/spreadsheet/bindings.ts +++ b/packages/desktop-client/src/spreadsheet/bindings.ts @@ -4,7 +4,7 @@ import type { AccountEntity, CategoryEntity } from 'loot-core/types/models'; import { parametrizedField } from '.'; import type { Binding, SheetFields, SheetNames } from '.'; -import { uncategorizedTransactions } from '@desktop-client/queries'; +import { uncategorizedTransactions } from '#queries'; type BudgetType = Record< string, diff --git a/packages/desktop-client/src/style/theme.tsx b/packages/desktop-client/src/style/theme.tsx index a62e1fab6a..b6a0a3e8f0 100644 --- a/packages/desktop-client/src/style/theme.tsx +++ b/packages/desktop-client/src/style/theme.tsx @@ -9,8 +9,8 @@ import * as developmentTheme from './themes/development'; import * as lightTheme from './themes/light'; import * as midnightTheme from './themes/midnight'; -import { useFeatureFlag } from '@desktop-client/hooks/useFeatureFlag'; -import { useGlobalPref } from '@desktop-client/hooks/useGlobalPref'; +import { useFeatureFlag } from '#hooks/useFeatureFlag'; +import { useGlobalPref } from '#hooks/useGlobalPref'; const themes = { light: { name: 'Light', colors: lightTheme }, diff --git a/packages/desktop-client/src/style/themes/dark.ts b/packages/desktop-client/src/style/themes/dark.ts index b20cf74052..a1cd10a441 100644 --- a/packages/desktop-client/src/style/themes/dark.ts +++ b/packages/desktop-client/src/style/themes/dark.ts @@ -1,4 +1,4 @@ -import * as colorPalette from '@desktop-client/style/palette'; +import * as colorPalette from '#style/palette'; export const pageBackground = colorPalette.gray900; export const pageBackgroundModalActive = colorPalette.gray800; diff --git a/packages/desktop-client/src/style/themes/development.ts b/packages/desktop-client/src/style/themes/development.ts index a303b74157..1b183dd98c 100644 --- a/packages/desktop-client/src/style/themes/development.ts +++ b/packages/desktop-client/src/style/themes/development.ts @@ -1,4 +1,4 @@ -import * as colorPalette from '@desktop-client/style/palette'; +import * as colorPalette from '#style/palette'; export const pageBackground = colorPalette.navy100; export const pageBackgroundModalActive = colorPalette.navy200; diff --git a/packages/desktop-client/src/style/themes/light.ts b/packages/desktop-client/src/style/themes/light.ts index ce09f466d0..80c4e5b147 100644 --- a/packages/desktop-client/src/style/themes/light.ts +++ b/packages/desktop-client/src/style/themes/light.ts @@ -1,4 +1,4 @@ -import * as colorPalette from '@desktop-client/style/palette'; +import * as colorPalette from '#style/palette'; export const pageBackground = colorPalette.navy100; export const pageBackgroundModalActive = colorPalette.navy200; diff --git a/packages/desktop-client/src/style/themes/midnight.ts b/packages/desktop-client/src/style/themes/midnight.ts index 1b925bb677..2fe2edaeba 100644 --- a/packages/desktop-client/src/style/themes/midnight.ts +++ b/packages/desktop-client/src/style/themes/midnight.ts @@ -1,4 +1,4 @@ -import * as colorPalette from '@desktop-client/style/palette'; +import * as colorPalette from '#style/palette'; export const pageBackground = colorPalette.gray600; export const pageBackgroundModalActive = colorPalette.gray700; diff --git a/packages/desktop-client/src/tags/mutations.ts b/packages/desktop-client/src/tags/mutations.ts index bc44aac9aa..842b5cd520 100644 --- a/packages/desktop-client/src/tags/mutations.ts +++ b/packages/desktop-client/src/tags/mutations.ts @@ -9,9 +9,9 @@ import type { TagEntity } from 'loot-core/types/models'; import { tagQueries } from './queries'; -import { addNotification } from '@desktop-client/notifications/notificationsSlice'; -import { useDispatch } from '@desktop-client/redux'; -import type { AppDispatch } from '@desktop-client/redux/store'; +import { addNotification } from '#notifications/notificationsSlice'; +import { useDispatch } from '#redux'; +import type { AppDispatch } from '#redux/store'; function invalidateQueries(queryClient: QueryClient, queryKey?: QueryKey) { void queryClient.invalidateQueries({ diff --git a/packages/desktop-client/src/transactions/queries.ts b/packages/desktop-client/src/transactions/queries.ts index 3d29b8e2ed..d74daedf44 100644 --- a/packages/desktop-client/src/transactions/queries.ts +++ b/packages/desktop-client/src/transactions/queries.ts @@ -3,7 +3,7 @@ import { infiniteQueryOptions, keepPreviousData } from '@tanstack/react-query'; import type { Query } from 'loot-core/shared/query'; import type { TransactionEntity } from 'loot-core/types/models'; -import { aqlQuery } from '@desktop-client/queries/aqlQuery'; +import { aqlQuery } from '#queries/aqlQuery'; export const transactionQueries = { all: () => ['transactions'], diff --git a/packages/desktop-client/src/transactions/transactionsSlice.ts b/packages/desktop-client/src/transactions/transactionsSlice.ts index 54986246d1..7f069af6bb 100644 --- a/packages/desktop-client/src/transactions/transactionsSlice.ts +++ b/packages/desktop-client/src/transactions/transactionsSlice.ts @@ -3,7 +3,7 @@ import type { PayloadAction } from '@reduxjs/toolkit'; import type { TransactionEntity } from 'loot-core/types/models'; -import { resetApp } from '@desktop-client/app/appSlice'; +import { resetApp } from '#app/appSlice'; const sliceName = 'transactions'; diff --git a/packages/desktop-client/src/users/usersSlice.ts b/packages/desktop-client/src/users/usersSlice.ts index 6a426d2d2f..fb64b4b082 100644 --- a/packages/desktop-client/src/users/usersSlice.ts +++ b/packages/desktop-client/src/users/usersSlice.ts @@ -4,13 +4,10 @@ import type { PayloadAction } from '@reduxjs/toolkit'; import { send } from 'loot-core/platform/client/connection'; import type { Handlers } from 'loot-core/types/handlers'; -import { resetApp } from '@desktop-client/app/appSlice'; -import { - closeBudget, - loadAllFiles, -} from '@desktop-client/budgetfiles/budgetfilesSlice'; -import { loadGlobalPrefs } from '@desktop-client/prefs/prefsSlice'; -import { createAppAsyncThunk } from '@desktop-client/redux'; +import { resetApp } from '#app/appSlice'; +import { closeBudget, loadAllFiles } from '#budgetfiles/budgetfilesSlice'; +import { loadGlobalPrefs } from '#prefs/prefsSlice'; +import { createAppAsyncThunk } from '#redux'; const sliceName = 'user'; diff --git a/packages/desktop-client/src/util/router-tools.ts b/packages/desktop-client/src/util/router-tools.ts index 8b0515a6c2..592acbe90b 100644 --- a/packages/desktop-client/src/util/router-tools.ts +++ b/packages/desktop-client/src/util/router-tools.ts @@ -1,6 +1,6 @@ import { useLayoutEffect } from 'react'; -import { useNavigate } from '@desktop-client/hooks/useNavigate'; +import { useNavigate } from '#hooks/useNavigate'; export function ExposeNavigate() { const navigate = useNavigate(); diff --git a/upcoming-release-notes/7182.md b/upcoming-release-notes/7182.md new file mode 100644 index 0000000000..ac20cdfbc9 --- /dev/null +++ b/upcoming-release-notes/7182.md @@ -0,0 +1,6 @@ +--- +category: Maintenance +authors: [MatissJanis] +--- + +Moving desktop-client to subpath imports