From 5da3bbe6478ca081baef5eed4caa43bdf1c0e21c Mon Sep 17 00:00:00 2001 From: Joel Jeremy Marquez Date: Thu, 4 Jan 2024 11:52:42 -0800 Subject: [PATCH] ESLint no default exports 9 - components folder 2 --- .../src/components/FinancesApp.tsx | 4 ++-- .../src/components/ManageRules.tsx | 6 +++--- .../desktop-client/src/components/Titlebar.tsx | 2 +- .../src/components/accounts/Account.jsx | 2 +- .../src/components/accounts/Balance.jsx | 6 +++--- .../accounts/MobileAccountDetails.jsx | 4 ++-- .../src/components/accounts/MobileAccounts.jsx | 4 ++-- .../src/components/accounts/Reconcile.jsx | 4 ++-- .../components/budget/BalanceWithCarryover.tsx | 4 ++-- .../components/budget/MobileBudgetTable.jsx | 10 +++++----- .../src/components/budget/RenderMonths.tsx | 2 +- .../budget/report/BalanceTooltip.tsx | 2 +- .../budget/report/ReportComponents.tsx | 4 ++-- .../report/budgetsummary/BudgetSummary.tsx | 2 +- .../report/budgetsummary/BudgetTotal.tsx | 2 +- .../report/budgetsummary/ExpenseProgress.tsx | 4 ++-- .../report/budgetsummary/IncomeProgress.tsx | 4 ++-- .../budget/report/budgetsummary/Saved.tsx | 4 ++-- .../budget/rollover/BalanceTooltip.tsx | 2 +- .../components/budget/rollover/HoldTooltip.tsx | 2 +- .../budget/rollover/RolloverComponents.tsx | 4 ++-- .../budget/rollover/TransferTooltip.tsx | 2 +- .../rollover/budgetsummary/BudgetSummary.tsx | 2 +- .../budget/rollover/budgetsummary/ToBudget.tsx | 6 +++--- .../rollover/budgetsummary/TotalsList.tsx | 4 ++-- .../src/components/filters/FiltersMenu.jsx | 4 ++-- .../src/components/filters/SavedFilters.jsx | 2 +- .../src/components/modals/EditField.jsx | 2 +- .../src/components/modals/EditRule.jsx | 6 +++--- .../components/modals/ReportBudgetSummary.tsx | 2 +- .../modals/RolloverBudgetSummary.tsx | 2 +- .../components/responsive/PullToRefresh.tsx | 2 +- .../src/components/rules/ActionExpression.tsx | 9 +++------ .../components/rules/ConditionExpression.tsx | 4 ++-- .../src/components/rules/RuleRow.tsx | 8 +++----- .../src/components/rules/RulesHeader.tsx | 2 +- .../src/components/rules/RulesList.tsx | 4 ++-- .../src/components/rules/ScheduleValue.tsx | 4 ++-- .../src/components/rules/SimpleTable.tsx | 2 +- .../src/components/rules/Value.tsx | 2 +- .../components/schedules/DiscoverSchedules.tsx | 2 +- .../schedules/PostsOfflineNotification.jsx | 2 +- .../components/schedules/ScheduleDetails.jsx | 8 ++++---- .../components/schedules/SchedulesTable.tsx | 2 +- .../src/components/select/DateSelect.tsx | 2 +- .../select/RecurringSchedulePicker.jsx | 4 ++-- .../src/components/settings/Encryption.tsx | 2 +- .../src/components/settings/Experimental.tsx | 2 +- .../src/components/settings/Export.tsx | 2 +- .../src/components/settings/FixSplits.tsx | 2 +- .../src/components/settings/Format.tsx | 2 +- .../src/components/settings/Global.tsx | 2 +- .../src/components/settings/Themes.tsx | 2 +- .../src/components/settings/index.tsx | 18 +++++++++--------- .../src/components/sidebar/Account.tsx | 6 ++---- .../src/components/sidebar/Accounts.tsx | 8 +++----- .../src/components/sidebar/Item.tsx | 6 ++---- .../src/components/sidebar/ItemContent.tsx | 4 +--- .../src/components/sidebar/SecondaryItem.tsx | 6 ++---- .../src/components/sidebar/Sidebar.tsx | 12 +++++------- .../src/components/sidebar/SidebarWithData.tsx | 6 ++---- .../src/components/sidebar/ToggleButton.tsx | 8 +++++--- .../src/components/sidebar/Tools.tsx | 8 +++----- .../src/components/sidebar/index.tsx | 11 ++++------- .../src/components/spreadsheet/CellValue.tsx | 10 ++++------ .../components/spreadsheet/NamespaceContext.ts | 2 +- .../src/components/spreadsheet/useFormat.ts | 2 +- .../src/components/spreadsheet/useSheetName.ts | 4 ++-- .../components/spreadsheet/useSheetValue.ts | 7 ++----- .../desktop-client/src/components/table.tsx | 4 ++-- .../transactions/SimpleTransactionsTable.jsx | 4 ++-- .../transactions/TransactionList.jsx | 2 +- .../transactions/TransactionsTable.jsx | 2 +- .../src/components/util/AmountInput.tsx | 2 +- .../src/components/util/DisplayId.tsx | 2 +- .../src/components/util/GenericInput.jsx | 6 +++--- 76 files changed, 147 insertions(+), 174 deletions(-) diff --git a/packages/desktop-client/src/components/FinancesApp.tsx b/packages/desktop-client/src/components/FinancesApp.tsx index 8479911dd32..04581c111c9 100644 --- a/packages/desktop-client/src/components/FinancesApp.tsx +++ b/packages/desktop-client/src/components/FinancesApp.tsx @@ -37,8 +37,8 @@ import { ManagePayeesPage } from './payees/ManagePayeesPage'; import { Reports } from './reports'; import { NarrowAlternate, WideComponent } from './responsive'; import { ScrollProvider } from './ScrollProvider'; -import Settings from './settings'; -import FloatableSidebar, { SidebarProvider } from './sidebar'; +import { Settings } from './settings'; +import { FloatableSidebar, SidebarProvider } from './sidebar'; import { Titlebar, TitlebarProvider } from './Titlebar'; import { TransactionEdit } from './transactions/MobileTransaction'; diff --git a/packages/desktop-client/src/components/ManageRules.tsx b/packages/desktop-client/src/components/ManageRules.tsx index 80db5083348..c9a1178f7a8 100644 --- a/packages/desktop-client/src/components/ManageRules.tsx +++ b/packages/desktop-client/src/components/ManageRules.tsx @@ -26,10 +26,10 @@ import { Search } from './common/Search'; import { Stack } from './common/Stack'; import { Text } from './common/Text'; import { View } from './common/View'; -import RulesHeader from './rules/RulesHeader'; -import RulesList from './rules/RulesList'; +import { RulesHeader } from './rules/RulesHeader'; +import { RulesList } from './rules/RulesList'; import { SchedulesQuery } from './rules/SchedulesQuery'; -import SimpleTable from './rules/SimpleTable'; +import { SimpleTable } from './rules/SimpleTable'; function mapValue(field, value, { payees, categories, accounts }) { if (!value) return ''; diff --git a/packages/desktop-client/src/components/Titlebar.tsx b/packages/desktop-client/src/components/Titlebar.tsx index 331bbc65e8a..22f79b2a937 100644 --- a/packages/desktop-client/src/components/Titlebar.tsx +++ b/packages/desktop-client/src/components/Titlebar.tsx @@ -38,7 +38,7 @@ import { KeyHandlers } from './KeyHandlers'; import { LoggedInUser } from './LoggedInUser'; import { useServerURL } from './ServerContext'; import { useSidebar } from './sidebar'; -import useSheetValue from './spreadsheet/useSheetValue'; +import { useSheetValue } from './spreadsheet/useSheetValue'; import { ThemeSelector } from './ThemeSelector'; import { Tooltip } from './tooltips'; diff --git a/packages/desktop-client/src/components/accounts/Account.jsx b/packages/desktop-client/src/components/accounts/Account.jsx index 1c3689ac39b..b438feb6119 100644 --- a/packages/desktop-client/src/components/accounts/Account.jsx +++ b/packages/desktop-client/src/components/accounts/Account.jsx @@ -32,7 +32,7 @@ import { styles, theme } from '../../style'; import { Button } from '../common/Button'; import { Text } from '../common/Text'; import { View } from '../common/View'; -import TransactionList from '../transactions/TransactionList'; +import { TransactionList } from '../transactions/TransactionList'; import { SplitsExpandedProvider, useSplitsExpanded, diff --git a/packages/desktop-client/src/components/accounts/Balance.jsx b/packages/desktop-client/src/components/accounts/Balance.jsx index ed9c7fd793c..95fcbe5c92f 100644 --- a/packages/desktop-client/src/components/accounts/Balance.jsx +++ b/packages/desktop-client/src/components/accounts/Balance.jsx @@ -11,9 +11,9 @@ import { Button } from '../common/Button'; import { Text } from '../common/Text'; import { View } from '../common/View'; import { PrivacyFilter } from '../PrivacyFilter'; -import CellValue from '../spreadsheet/CellValue'; -import useFormat from '../spreadsheet/useFormat'; -import useSheetValue from '../spreadsheet/useSheetValue'; +import { CellValue } from '../spreadsheet/CellValue'; +import { useFormat } from '../spreadsheet/useFormat'; +import { useSheetValue } from '../spreadsheet/useSheetValue'; import { isPreviewId } from '../transactions/TransactionsTable'; function DetailedBalance({ name, balance, isExactBalance = true }) { diff --git a/packages/desktop-client/src/components/accounts/MobileAccountDetails.jsx b/packages/desktop-client/src/components/accounts/MobileAccountDetails.jsx index 0a5c329632b..e414fa2b11a 100644 --- a/packages/desktop-client/src/components/accounts/MobileAccountDetails.jsx +++ b/packages/desktop-client/src/components/accounts/MobileAccountDetails.jsx @@ -10,8 +10,8 @@ import { Label } from '../common/Label'; import { View } from '../common/View'; import { MobileBackButton } from '../MobileBackButton'; import { Page } from '../Page'; -import PullToRefresh from '../responsive/PullToRefresh'; -import CellValue from '../spreadsheet/CellValue'; +import { PullToRefresh } from '../responsive/PullToRefresh'; +import { CellValue } from '../spreadsheet/CellValue'; import { TransactionList } from '../transactions/MobileTransaction'; function TransactionSearchInput({ accountName, onSearch }) { diff --git a/packages/desktop-client/src/components/accounts/MobileAccounts.jsx b/packages/desktop-client/src/components/accounts/MobileAccounts.jsx index 1f3edd629c9..f6b63b4b217 100644 --- a/packages/desktop-client/src/components/accounts/MobileAccounts.jsx +++ b/packages/desktop-client/src/components/accounts/MobileAccounts.jsx @@ -14,8 +14,8 @@ import { Text } from '../common/Text'; import { TextOneLine } from '../common/TextOneLine'; import { View } from '../common/View'; import { Page } from '../Page'; -import PullToRefresh from '../responsive/PullToRefresh'; -import CellValue from '../spreadsheet/CellValue'; +import { PullToRefresh } from '../responsive/PullToRefresh'; +import { CellValue } from '../spreadsheet/CellValue'; function AccountHeader({ name, amount, style = {} }) { return ( diff --git a/packages/desktop-client/src/components/accounts/Reconcile.jsx b/packages/desktop-client/src/components/accounts/Reconcile.jsx index 9d9ee97a454..966989f38c8 100644 --- a/packages/desktop-client/src/components/accounts/Reconcile.jsx +++ b/packages/desktop-client/src/components/accounts/Reconcile.jsx @@ -10,8 +10,8 @@ import { InitialFocus } from '../common/InitialFocus'; import { Input } from '../common/Input'; import { Text } from '../common/Text'; import { View } from '../common/View'; -import useFormat from '../spreadsheet/useFormat'; -import useSheetValue from '../spreadsheet/useSheetValue'; +import { useFormat } from '../spreadsheet/useFormat'; +import { useSheetValue } from '../spreadsheet/useSheetValue'; import { Tooltip } from '../tooltips'; export function ReconcilingMessage({ diff --git a/packages/desktop-client/src/components/budget/BalanceWithCarryover.tsx b/packages/desktop-client/src/components/budget/BalanceWithCarryover.tsx index efe06864148..81258220b40 100644 --- a/packages/desktop-client/src/components/budget/BalanceWithCarryover.tsx +++ b/packages/desktop-client/src/components/budget/BalanceWithCarryover.tsx @@ -4,8 +4,8 @@ import useFeatureFlag from '../../hooks/useFeatureFlag'; import ArrowThinRight from '../../icons/v1/ArrowThinRight'; import { type CSSProperties } from '../../style'; import { View } from '../common/View'; -import CellValue from '../spreadsheet/CellValue'; -import useSheetValue from '../spreadsheet/useSheetValue'; +import { CellValue } from '../spreadsheet/CellValue'; +import { useSheetValue } from '../spreadsheet/useSheetValue'; import { makeAmountStyle } from './util'; diff --git a/packages/desktop-client/src/components/budget/MobileBudgetTable.jsx b/packages/desktop-client/src/components/budget/MobileBudgetTable.jsx index 78831029ecd..ace5c719c7a 100644 --- a/packages/desktop-client/src/components/budget/MobileBudgetTable.jsx +++ b/packages/desktop-client/src/components/budget/MobileBudgetTable.jsx @@ -19,11 +19,11 @@ import { Menu } from '../common/Menu'; import { Text } from '../common/Text'; import { View } from '../common/View'; import { Page } from '../Page'; -import PullToRefresh from '../responsive/PullToRefresh'; -import CellValue from '../spreadsheet/CellValue'; -import NamespaceContext from '../spreadsheet/NamespaceContext'; -import useFormat from '../spreadsheet/useFormat'; -import useSheetValue from '../spreadsheet/useSheetValue'; +import { PullToRefresh } from '../responsive/PullToRefresh'; +import { CellValue } from '../spreadsheet/CellValue'; +import { NamespaceContext } from '../spreadsheet/NamespaceContext'; +import { useFormat } from '../spreadsheet/useFormat'; +import { useSheetValue } from '../spreadsheet/useSheetValue'; import { Tooltip, useTooltip } from '../tooltips'; import { AmountInput } from '../util/AmountInput'; // import { diff --git a/packages/desktop-client/src/components/budget/RenderMonths.tsx b/packages/desktop-client/src/components/budget/RenderMonths.tsx index c172f066127..1960f7ccb0b 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/src/shared/months'; import { theme } from '../../style'; import { View } from '../common/View'; -import NamespaceContext from '../spreadsheet/NamespaceContext'; +import { NamespaceContext } from '../spreadsheet/NamespaceContext'; import { MonthsContext } from './MonthsContext'; diff --git a/packages/desktop-client/src/components/budget/report/BalanceTooltip.tsx b/packages/desktop-client/src/components/budget/report/BalanceTooltip.tsx index 0f950441a93..76eddb31928 100644 --- a/packages/desktop-client/src/components/budget/report/BalanceTooltip.tsx +++ b/packages/desktop-client/src/components/budget/report/BalanceTooltip.tsx @@ -3,7 +3,7 @@ import React from 'react'; import { reportBudget } from 'loot-core/src/client/queries'; import { Menu } from '../../common/Menu'; -import useSheetValue from '../../spreadsheet/useSheetValue'; +import { useSheetValue } from '../../spreadsheet/useSheetValue'; import { Tooltip } from '../../tooltips'; type BalanceTooltipProps = { diff --git a/packages/desktop-client/src/components/budget/report/ReportComponents.tsx b/packages/desktop-client/src/components/budget/report/ReportComponents.tsx index a6cbe390ecb..ba6a2276673 100644 --- a/packages/desktop-client/src/components/budget/report/ReportComponents.tsx +++ b/packages/desktop-client/src/components/budget/report/ReportComponents.tsx @@ -11,8 +11,8 @@ import { Button } from '../../common/Button'; import { Menu } from '../../common/Menu'; import { Text } from '../../common/Text'; import { View } from '../../common/View'; -import CellValue from '../../spreadsheet/CellValue'; -import useFormat from '../../spreadsheet/useFormat'; +import { CellValue } from '../../spreadsheet/CellValue'; +import { useFormat } from '../../spreadsheet/useFormat'; import { Field, SheetCell } from '../../table'; import { Tooltip, useTooltip } from '../../tooltips'; import { BalanceWithCarryover } from '../BalanceWithCarryover'; diff --git a/packages/desktop-client/src/components/budget/report/budgetsummary/BudgetSummary.tsx b/packages/desktop-client/src/components/budget/report/budgetsummary/BudgetSummary.tsx index d17f15deb40..32a95641335 100644 --- a/packages/desktop-client/src/components/budget/report/budgetsummary/BudgetSummary.tsx +++ b/packages/desktop-client/src/components/budget/report/budgetsummary/BudgetSummary.tsx @@ -14,7 +14,7 @@ import { Menu } from '../../../common/Menu'; import { Stack } from '../../../common/Stack'; import { View } from '../../../common/View'; import { NotesButton } from '../../../NotesButton'; -import NamespaceContext from '../../../spreadsheet/NamespaceContext'; +import { NamespaceContext } from '../../../spreadsheet/NamespaceContext'; import { Tooltip } from '../../../tooltips'; import { useReport } from '../ReportContext'; diff --git a/packages/desktop-client/src/components/budget/report/budgetsummary/BudgetTotal.tsx b/packages/desktop-client/src/components/budget/report/budgetsummary/BudgetTotal.tsx index 7adc3781b39..8d6429e5e02 100644 --- a/packages/desktop-client/src/components/budget/report/budgetsummary/BudgetTotal.tsx +++ b/packages/desktop-client/src/components/budget/report/budgetsummary/BudgetTotal.tsx @@ -8,7 +8,7 @@ import React, { import { theme, styles } from '../../../../style'; import { Text } from '../../../common/Text'; import { View } from '../../../common/View'; -import CellValue from '../../../spreadsheet/CellValue'; +import { CellValue } from '../../../spreadsheet/CellValue'; type BudgetTotalProps = { title: ReactNode; diff --git a/packages/desktop-client/src/components/budget/report/budgetsummary/ExpenseProgress.tsx b/packages/desktop-client/src/components/budget/report/budgetsummary/ExpenseProgress.tsx index afa4cf12ced..8e0b7c6cb46 100644 --- a/packages/desktop-client/src/components/budget/report/budgetsummary/ExpenseProgress.tsx +++ b/packages/desktop-client/src/components/budget/report/budgetsummary/ExpenseProgress.tsx @@ -1,8 +1,8 @@ import React, { type ComponentProps } from 'react'; import { theme } from '../../../../style'; -import type CellValue from '../../../spreadsheet/CellValue'; -import useSheetValue from '../../../spreadsheet/useSheetValue'; +import { type CellValue } from '../../../spreadsheet/CellValue'; +import { useSheetValue } from '../../../spreadsheet/useSheetValue'; import { fraction } from './fraction'; import { PieProgress } from './PieProgress'; diff --git a/packages/desktop-client/src/components/budget/report/budgetsummary/IncomeProgress.tsx b/packages/desktop-client/src/components/budget/report/budgetsummary/IncomeProgress.tsx index 756496e1c93..66b64abd50c 100644 --- a/packages/desktop-client/src/components/budget/report/budgetsummary/IncomeProgress.tsx +++ b/packages/desktop-client/src/components/budget/report/budgetsummary/IncomeProgress.tsx @@ -1,8 +1,8 @@ import React, { type ComponentProps } from 'react'; import { theme } from '../../../../style'; -import type CellValue from '../../../spreadsheet/CellValue'; -import useSheetValue from '../../../spreadsheet/useSheetValue'; +import { type CellValue } from '../../../spreadsheet/CellValue'; +import { useSheetValue } from '../../../spreadsheet/useSheetValue'; import { fraction } from './fraction'; import { PieProgress } from './PieProgress'; diff --git a/packages/desktop-client/src/components/budget/report/budgetsummary/Saved.tsx b/packages/desktop-client/src/components/budget/report/budgetsummary/Saved.tsx index c1e3a475cfb..3575bd63f07 100644 --- a/packages/desktop-client/src/components/budget/report/budgetsummary/Saved.tsx +++ b/packages/desktop-client/src/components/budget/report/budgetsummary/Saved.tsx @@ -10,8 +10,8 @@ import { HoverTarget } from '../../../common/HoverTarget'; import { Text } from '../../../common/Text'; import { View } from '../../../common/View'; import { PrivacyFilter } from '../../../PrivacyFilter'; -import useFormat from '../../../spreadsheet/useFormat'; -import useSheetValue from '../../../spreadsheet/useSheetValue'; +import { useFormat } from '../../../spreadsheet/useFormat'; +import { useSheetValue } from '../../../spreadsheet/useSheetValue'; import { Tooltip } from '../../../tooltips'; import { makeAmountFullStyle } from '../../util'; diff --git a/packages/desktop-client/src/components/budget/rollover/BalanceTooltip.tsx b/packages/desktop-client/src/components/budget/rollover/BalanceTooltip.tsx index d8f53712fdf..eb7a1a5432b 100644 --- a/packages/desktop-client/src/components/budget/rollover/BalanceTooltip.tsx +++ b/packages/desktop-client/src/components/budget/rollover/BalanceTooltip.tsx @@ -3,7 +3,7 @@ import React, { useState } from 'react'; import { rolloverBudget } from 'loot-core/src/client/queries'; import { Menu } from '../../common/Menu'; -import useSheetValue from '../../spreadsheet/useSheetValue'; +import { useSheetValue } from '../../spreadsheet/useSheetValue'; import { Tooltip } from '../../tooltips'; import { CoverTooltip } from './CoverTooltip'; diff --git a/packages/desktop-client/src/components/budget/rollover/HoldTooltip.tsx b/packages/desktop-client/src/components/budget/rollover/HoldTooltip.tsx index a2bbf282d45..be1ed2438de 100644 --- a/packages/desktop-client/src/components/budget/rollover/HoldTooltip.tsx +++ b/packages/desktop-client/src/components/budget/rollover/HoldTooltip.tsx @@ -14,7 +14,7 @@ import { Button } from '../../common/Button'; import { InitialFocus } from '../../common/InitialFocus'; import { Input } from '../../common/Input'; import { View } from '../../common/View'; -import NamespaceContext from '../../spreadsheet/NamespaceContext'; +import { NamespaceContext } from '../../spreadsheet/NamespaceContext'; import { Tooltip } from '../../tooltips'; type HoldTooltipProps = ComponentPropsWithoutRef & { diff --git a/packages/desktop-client/src/components/budget/rollover/RolloverComponents.tsx b/packages/desktop-client/src/components/budget/rollover/RolloverComponents.tsx index 4515ccd3a23..544159d7e80 100644 --- a/packages/desktop-client/src/components/budget/rollover/RolloverComponents.tsx +++ b/packages/desktop-client/src/components/budget/rollover/RolloverComponents.tsx @@ -11,8 +11,8 @@ import { Button } from '../../common/Button'; import { Menu } from '../../common/Menu'; import { Text } from '../../common/Text'; import { View } from '../../common/View'; -import CellValue from '../../spreadsheet/CellValue'; -import useFormat from '../../spreadsheet/useFormat'; +import { CellValue } from '../../spreadsheet/CellValue'; +import { useFormat } from '../../spreadsheet/useFormat'; import { Row, Field, SheetCell } from '../../table'; import { Tooltip, useTooltip } from '../../tooltips'; import { BalanceWithCarryover } from '../BalanceWithCarryover'; diff --git a/packages/desktop-client/src/components/budget/rollover/TransferTooltip.tsx b/packages/desktop-client/src/components/budget/rollover/TransferTooltip.tsx index 8e34a1abb7f..d76137afa6d 100644 --- a/packages/desktop-client/src/components/budget/rollover/TransferTooltip.tsx +++ b/packages/desktop-client/src/components/budget/rollover/TransferTooltip.tsx @@ -15,7 +15,7 @@ import { Button } from '../../common/Button'; import { InitialFocus } from '../../common/InitialFocus'; import { Input } from '../../common/Input'; import { View } from '../../common/View'; -import NamespaceContext from '../../spreadsheet/NamespaceContext'; +import { NamespaceContext } from '../../spreadsheet/NamespaceContext'; import { Tooltip } from '../../tooltips'; import { addToBeBudgetedGroup } from '../util'; diff --git a/packages/desktop-client/src/components/budget/rollover/budgetsummary/BudgetSummary.tsx b/packages/desktop-client/src/components/budget/rollover/budgetsummary/BudgetSummary.tsx index 084f99ef0c5..2a9b1682694 100644 --- a/packages/desktop-client/src/components/budget/rollover/budgetsummary/BudgetSummary.tsx +++ b/packages/desktop-client/src/components/budget/rollover/budgetsummary/BudgetSummary.tsx @@ -12,7 +12,7 @@ import { Button } from '../../../common/Button'; import { Menu } from '../../../common/Menu'; import { View } from '../../../common/View'; import { NotesButton } from '../../../NotesButton'; -import NamespaceContext from '../../../spreadsheet/NamespaceContext'; +import { NamespaceContext } from '../../../spreadsheet/NamespaceContext'; import { Tooltip } from '../../../tooltips'; import { useRollover } from '../RolloverContext'; diff --git a/packages/desktop-client/src/components/budget/rollover/budgetsummary/ToBudget.tsx b/packages/desktop-client/src/components/budget/rollover/budgetsummary/ToBudget.tsx index 6f9adc1b006..7364996619a 100644 --- a/packages/desktop-client/src/components/budget/rollover/budgetsummary/ToBudget.tsx +++ b/packages/desktop-client/src/components/budget/rollover/budgetsummary/ToBudget.tsx @@ -10,9 +10,9 @@ import { HoverTarget } from '../../../common/HoverTarget'; import { Menu } from '../../../common/Menu'; import { View } from '../../../common/View'; import { PrivacyFilter } from '../../../PrivacyFilter'; -import useFormat from '../../../spreadsheet/useFormat'; -import useSheetName from '../../../spreadsheet/useSheetName'; -import useSheetValue from '../../../spreadsheet/useSheetValue'; +import { useFormat } from '../../../spreadsheet/useFormat'; +import { useSheetName } from '../../../spreadsheet/useSheetName'; +import { useSheetValue } from '../../../spreadsheet/useSheetValue'; import { Tooltip } from '../../../tooltips'; import { HoldTooltip } from '../HoldTooltip'; import { TransferTooltip } from '../TransferTooltip'; diff --git a/packages/desktop-client/src/components/budget/rollover/budgetsummary/TotalsList.tsx b/packages/desktop-client/src/components/budget/rollover/budgetsummary/TotalsList.tsx index 7383e71967b..3c906d58082 100644 --- a/packages/desktop-client/src/components/budget/rollover/budgetsummary/TotalsList.tsx +++ b/packages/desktop-client/src/components/budget/rollover/budgetsummary/TotalsList.tsx @@ -7,8 +7,8 @@ import { AlignedText } from '../../../common/AlignedText'; import { Block } from '../../../common/Block'; import { HoverTarget } from '../../../common/HoverTarget'; import { View } from '../../../common/View'; -import CellValue from '../../../spreadsheet/CellValue'; -import useFormat from '../../../spreadsheet/useFormat'; +import { CellValue } from '../../../spreadsheet/CellValue'; +import { useFormat } from '../../../spreadsheet/useFormat'; import { Tooltip } from '../../../tooltips'; type TotalsListProps = { diff --git a/packages/desktop-client/src/components/filters/FiltersMenu.jsx b/packages/desktop-client/src/components/filters/FiltersMenu.jsx index c1cad8f3668..e73d15abaa1 100644 --- a/packages/desktop-client/src/components/filters/FiltersMenu.jsx +++ b/packages/desktop-client/src/components/filters/FiltersMenu.jsx @@ -32,9 +32,9 @@ import { Select } from '../common/Select'; import { Stack } from '../common/Stack'; import { Text } from '../common/Text'; import { View } from '../common/View'; -import Value from '../rules/Value'; +import { Value } from '../rules/Value'; import { Tooltip } from '../tooltips'; -import GenericInput from '../util/GenericInput'; +import { GenericInput } from '../util/GenericInput'; import { CompactFiltersButton } from './CompactFiltersButton'; import { FiltersButton } from './FiltersButton'; diff --git a/packages/desktop-client/src/components/filters/SavedFilters.jsx b/packages/desktop-client/src/components/filters/SavedFilters.jsx index 61cd5ff16c9..a677e7a539e 100644 --- a/packages/desktop-client/src/components/filters/SavedFilters.jsx +++ b/packages/desktop-client/src/components/filters/SavedFilters.jsx @@ -12,7 +12,7 @@ import { Text } from '../common/Text'; import { View } from '../common/View'; import { FormField, FormLabel } from '../forms'; import { FieldSelect } from '../modals/EditRule'; -import GenericInput from '../util/GenericInput'; +import { GenericInput } from '../util/GenericInput'; import { AppliedFilters } from './FiltersMenu'; diff --git a/packages/desktop-client/src/components/modals/EditField.jsx b/packages/desktop-client/src/components/modals/EditField.jsx index f98fd7b6fd7..b35c34c1027 100644 --- a/packages/desktop-client/src/components/modals/EditField.jsx +++ b/packages/desktop-client/src/components/modals/EditField.jsx @@ -31,7 +31,7 @@ import { Input } from '../common/Input'; import { Modal } from '../common/Modal'; import { View } from '../common/View'; import { SectionLabel } from '../forms'; -import DateSelect from '../select/DateSelect'; +import { DateSelect } from '../select/DateSelect'; function CreatePayeeIcon(props) { return ; diff --git a/packages/desktop-client/src/components/modals/EditRule.jsx b/packages/desktop-client/src/components/modals/EditRule.jsx index 789f4b3430e..c516c89197b 100644 --- a/packages/desktop-client/src/components/modals/EditRule.jsx +++ b/packages/desktop-client/src/components/modals/EditRule.jsx @@ -38,10 +38,10 @@ import { Text } from '../common/Text'; import { View } from '../common/View'; import { StatusBadge } from '../schedules/StatusBadge'; import { Tooltip } from '../tooltips'; -import SimpleTransactionsTable from '../transactions/SimpleTransactionsTable'; +import { SimpleTransactionsTable } from '../transactions/SimpleTransactionsTable'; import { BetweenAmountInput } from '../util/AmountInput'; -import DisplayId from '../util/DisplayId'; -import GenericInput from '../util/GenericInput'; +import { DisplayId } from '../util/DisplayId'; +import { GenericInput } from '../util/GenericInput'; function updateValue(array, value, update) { return array.map(v => (v === value ? update() : v)); diff --git a/packages/desktop-client/src/components/modals/ReportBudgetSummary.tsx b/packages/desktop-client/src/components/modals/ReportBudgetSummary.tsx index 6e2c93c8643..c03ecd5c2a1 100644 --- a/packages/desktop-client/src/components/modals/ReportBudgetSummary.tsx +++ b/packages/desktop-client/src/components/modals/ReportBudgetSummary.tsx @@ -10,7 +10,7 @@ import { IncomeTotal } from '../budget/report/budgetsummary/IncomeTotal'; import { Saved } from '../budget/report/budgetsummary/Saved'; import { Modal } from '../common/Modal'; import { Stack } from '../common/Stack'; -import NamespaceContext from '../spreadsheet/NamespaceContext'; +import { NamespaceContext } from '../spreadsheet/NamespaceContext'; type ReportBudgetSummaryProps = { modalProps: CommonModalProps; diff --git a/packages/desktop-client/src/components/modals/RolloverBudgetSummary.tsx b/packages/desktop-client/src/components/modals/RolloverBudgetSummary.tsx index 07f1b351c78..2c8bcd0b589 100644 --- a/packages/desktop-client/src/components/modals/RolloverBudgetSummary.tsx +++ b/packages/desktop-client/src/components/modals/RolloverBudgetSummary.tsx @@ -7,7 +7,7 @@ import { type CommonModalProps } from '../../types/modals'; import { ToBudget } from '../budget/rollover/budgetsummary/ToBudget'; import { TotalsList } from '../budget/rollover/budgetsummary/TotalsList'; import { Modal } from '../common/Modal'; -import NamespaceContext from '../spreadsheet/NamespaceContext'; +import { NamespaceContext } from '../spreadsheet/NamespaceContext'; type RolloverBudgetSummaryProps = { modalProps: CommonModalProps; diff --git a/packages/desktop-client/src/components/responsive/PullToRefresh.tsx b/packages/desktop-client/src/components/responsive/PullToRefresh.tsx index 5dba845680d..20f4df91a65 100644 --- a/packages/desktop-client/src/components/responsive/PullToRefresh.tsx +++ b/packages/desktop-client/src/components/responsive/PullToRefresh.tsx @@ -5,7 +5,7 @@ import { css } from 'glamor'; type PullToRefreshProps = ComponentProps; -export default function PullToRefresh(props: PullToRefreshProps) { +export function PullToRefresh(props: PullToRefreshProps) { return (
void; }; -const RuleRow = memo( +export const RuleRow = memo( ({ rule, hovered, selected, onHover, onEditRule }: RuleRowProps) => { const dispatchSelected = useSelectedDispatch(); const borderColor = selected ? theme.tableBorderSelected : 'none'; @@ -123,5 +123,3 @@ const RuleRow = memo( ); }, ); - -export default RuleRow; diff --git a/packages/desktop-client/src/components/rules/RulesHeader.tsx b/packages/desktop-client/src/components/rules/RulesHeader.tsx index a576c997ac3..c4dbfacf790 100644 --- a/packages/desktop-client/src/components/rules/RulesHeader.tsx +++ b/packages/desktop-client/src/components/rules/RulesHeader.tsx @@ -3,7 +3,7 @@ import React from 'react'; import { useSelectedItems, useSelectedDispatch } from '../../hooks/useSelected'; import { SelectCell, Cell, TableHeader } from '../table'; -export default function RulesHeader() { +export function RulesHeader() { const selectedItems = useSelectedItems(); const dispatchSelected = useSelectedDispatch(); diff --git a/packages/desktop-client/src/components/rules/RulesList.tsx b/packages/desktop-client/src/components/rules/RulesList.tsx index e6c4548df01..2fab1d2fba7 100644 --- a/packages/desktop-client/src/components/rules/RulesList.tsx +++ b/packages/desktop-client/src/components/rules/RulesList.tsx @@ -4,7 +4,7 @@ import { type RuleEntity } from 'loot-core/src/types/models'; import { View } from '../common/View'; -import RuleRow from './RuleRow'; +import { RuleRow } from './RuleRow'; type RulesListProps = { rules: RuleEntity[]; @@ -14,7 +14,7 @@ type RulesListProps = { onEditRule?: (rule: RuleEntity) => void; }; -export default function RulesList({ +export function RulesList({ rules, selectedItems, hoveredRule, diff --git a/packages/desktop-client/src/components/rules/ScheduleValue.tsx b/packages/desktop-client/src/components/rules/ScheduleValue.tsx index dd256a563d2..b547adad834 100644 --- a/packages/desktop-client/src/components/rules/ScheduleValue.tsx +++ b/packages/desktop-client/src/components/rules/ScheduleValue.tsx @@ -6,13 +6,13 @@ import { describeSchedule } from 'loot-core/src/shared/schedules'; import { type ScheduleEntity } from 'loot-core/src/types/models'; import { SchedulesQuery } from './SchedulesQuery'; -import Value from './Value'; +import { Value } from './Value'; type ScheduleValueProps = { value: ScheduleEntity; }; -export default function ScheduleValue({ value }: ScheduleValueProps) { +export function ScheduleValue({ value }: ScheduleValueProps) { const payees = useSelector(state => state.queries.payees); const byId = getPayeesById(payees); const { data: schedules } = SchedulesQuery.useQuery(); diff --git a/packages/desktop-client/src/components/rules/SimpleTable.tsx b/packages/desktop-client/src/components/rules/SimpleTable.tsx index ec7a6a5b430..688afeec118 100644 --- a/packages/desktop-client/src/components/rules/SimpleTable.tsx +++ b/packages/desktop-client/src/components/rules/SimpleTable.tsx @@ -10,7 +10,7 @@ type SimpleTableProps = { children: ReactNode; }; -export default function SimpleTable({ +export function SimpleTable({ loadMore, style, onHoverLeave, diff --git a/packages/desktop-client/src/components/rules/Value.tsx b/packages/desktop-client/src/components/rules/Value.tsx index 2152d08f374..a5fc4b38c5e 100644 --- a/packages/desktop-client/src/components/rules/Value.tsx +++ b/packages/desktop-client/src/components/rules/Value.tsx @@ -22,7 +22,7 @@ type ValueProps = { style?: CSSProperties; }; -export default function Value({ +export function Value({ value, field, valueIsRaw, diff --git a/packages/desktop-client/src/components/schedules/DiscoverSchedules.tsx b/packages/desktop-client/src/components/schedules/DiscoverSchedules.tsx index abdbcda75af..71740185e6a 100644 --- a/packages/desktop-client/src/components/schedules/DiscoverSchedules.tsx +++ b/packages/desktop-client/src/components/schedules/DiscoverSchedules.tsx @@ -21,7 +21,7 @@ import { Paragraph } from '../common/Paragraph'; import { Stack } from '../common/Stack'; import { View } from '../common/View'; import { Table, TableHeader, Row, Field, SelectCell } from '../table'; -import DisplayId from '../util/DisplayId'; +import { DisplayId } from '../util/DisplayId'; import { ScheduleAmountCell } from './SchedulesTable'; diff --git a/packages/desktop-client/src/components/schedules/PostsOfflineNotification.jsx b/packages/desktop-client/src/components/schedules/PostsOfflineNotification.jsx index 8ab41ab7045..e4114113d06 100644 --- a/packages/desktop-client/src/components/schedules/PostsOfflineNotification.jsx +++ b/packages/desktop-client/src/components/schedules/PostsOfflineNotification.jsx @@ -9,7 +9,7 @@ import { Modal } from '../common/Modal'; import { Paragraph } from '../common/Paragraph'; import { Stack } from '../common/Stack'; import { Text } from '../common/Text'; -import DisplayId from '../util/DisplayId'; +import { DisplayId } from '../util/DisplayId'; export function PostsOfflineNotification({ modalProps, actions }) { const location = useLocation(); diff --git a/packages/desktop-client/src/components/schedules/ScheduleDetails.jsx b/packages/desktop-client/src/components/schedules/ScheduleDetails.jsx index 005131a1626..a29fa9bc436 100644 --- a/packages/desktop-client/src/components/schedules/ScheduleDetails.jsx +++ b/packages/desktop-client/src/components/schedules/ScheduleDetails.jsx @@ -19,12 +19,12 @@ import { Text } from '../common/Text'; import { View } from '../common/View'; import { FormField, FormLabel, Checkbox } from '../forms'; import { OpSelect } from '../modals/EditRule'; -import DateSelect from '../select/DateSelect'; -import RecurringSchedulePicker from '../select/RecurringSchedulePicker'; +import { DateSelect } from '../select/DateSelect'; +import { RecurringSchedulePicker } from '../select/RecurringSchedulePicker'; import { SelectedItemsButton } from '../table'; -import SimpleTransactionsTable from '../transactions/SimpleTransactionsTable'; +import { SimpleTransactionsTable } from '../transactions/SimpleTransactionsTable'; import { AmountInput, BetweenAmountInput } from '../util/AmountInput'; -import GenericInput from '../util/GenericInput'; +import { GenericInput } from '../util/GenericInput'; function updateScheduleConditions(schedule, fields) { const conds = extractScheduleConds(schedule._conditions); diff --git a/packages/desktop-client/src/components/schedules/SchedulesTable.tsx b/packages/desktop-client/src/components/schedules/SchedulesTable.tsx index 4b57e1ee044..2f54eea18fe 100644 --- a/packages/desktop-client/src/components/schedules/SchedulesTable.tsx +++ b/packages/desktop-client/src/components/schedules/SchedulesTable.tsx @@ -22,7 +22,7 @@ import { View } from '../common/View'; import { PrivacyFilter } from '../PrivacyFilter'; import { Table, TableHeader, Row, Field, Cell } from '../table'; import { Tooltip } from '../tooltips'; -import DisplayId from '../util/DisplayId'; +import { DisplayId } from '../util/DisplayId'; import { StatusBadge } from './StatusBadge'; diff --git a/packages/desktop-client/src/components/select/DateSelect.tsx b/packages/desktop-client/src/components/select/DateSelect.tsx index b4ae0a66c59..d1438bf09c0 100644 --- a/packages/desktop-client/src/components/select/DateSelect.tsx +++ b/packages/desktop-client/src/components/select/DateSelect.tsx @@ -184,7 +184,7 @@ type DateSelectProps = { onSelect: (selectedDate: string) => void; }; -export default function DateSelect({ +export function DateSelect({ containerProps, inputProps, tooltipStyle, diff --git a/packages/desktop-client/src/components/select/RecurringSchedulePicker.jsx b/packages/desktop-client/src/components/select/RecurringSchedulePicker.jsx index d1052b9b6b1..e667f9864ab 100644 --- a/packages/desktop-client/src/components/select/RecurringSchedulePicker.jsx +++ b/packages/desktop-client/src/components/select/RecurringSchedulePicker.jsx @@ -17,7 +17,7 @@ import { View } from '../common/View'; import { Checkbox } from '../forms'; import { useTooltip, Tooltip } from '../tooltips'; -import DateSelect from './DateSelect'; +import { DateSelect } from './DateSelect'; // ex: There is no 6th Friday of the Month const MAX_DAY_OF_WEEK_INTERVAL = 5; @@ -479,7 +479,7 @@ function RecurringScheduleTooltip({ config: currentConfig, onClose, onSave }) { ); } -export default function RecurringSchedulePicker({ +export function RecurringSchedulePicker({ value, buttonStyle, onChange, diff --git a/packages/desktop-client/src/components/settings/Encryption.tsx b/packages/desktop-client/src/components/settings/Encryption.tsx index 00983266a6c..4ed788ede6c 100644 --- a/packages/desktop-client/src/components/settings/Encryption.tsx +++ b/packages/desktop-client/src/components/settings/Encryption.tsx @@ -10,7 +10,7 @@ import { useServerURL } from '../ServerContext'; import { Setting } from './UI'; -export default function EncryptionSettings() { +export function EncryptionSettings() { const { pushModal } = useActions(); const serverURL = useServerURL(); const encryptKeyId = useSelector(state => state.prefs.local.encryptKeyId); diff --git a/packages/desktop-client/src/components/settings/Experimental.tsx b/packages/desktop-client/src/components/settings/Experimental.tsx index 257956cab01..ede622a26c5 100644 --- a/packages/desktop-client/src/components/settings/Experimental.tsx +++ b/packages/desktop-client/src/components/settings/Experimental.tsx @@ -75,7 +75,7 @@ function ReportBudgetFeature() { ); } -export default function ExperimentalFeatures() { +export function ExperimentalFeatures() { const [expanded, setExpanded] = useState(false); return ( diff --git a/packages/desktop-client/src/components/settings/Export.tsx b/packages/desktop-client/src/components/settings/Export.tsx index b68d8251a9d..c3e46493b7a 100644 --- a/packages/desktop-client/src/components/settings/Export.tsx +++ b/packages/desktop-client/src/components/settings/Export.tsx @@ -12,7 +12,7 @@ import { Text } from '../common/Text'; import { Setting } from './UI'; -export default function ExportBudget() { +export function ExportBudget() { const [isLoading, setIsLoading] = useState(false); const [error, setError] = useState(null); const budgetId = useSelector(state => state.prefs.local.id); diff --git a/packages/desktop-client/src/components/settings/FixSplits.tsx b/packages/desktop-client/src/components/settings/FixSplits.tsx index 09e6b91f99c..3352f0c5d9a 100644 --- a/packages/desktop-client/src/components/settings/FixSplits.tsx +++ b/packages/desktop-client/src/components/settings/FixSplits.tsx @@ -51,7 +51,7 @@ function renderResults(results: Results) { ); } -export default function FixSplitsTool() { +export function FixSplits() { const [loading, setLoading] = useState(false); const [results, setResults] = useState(null); diff --git a/packages/desktop-client/src/components/settings/Format.tsx b/packages/desktop-client/src/components/settings/Format.tsx index 4f3cbe20ac0..43ea10cfc6e 100644 --- a/packages/desktop-client/src/components/settings/Format.tsx +++ b/packages/desktop-client/src/components/settings/Format.tsx @@ -52,7 +52,7 @@ function Column({ title, children }: { title: string; children: ReactNode }) { ); } -export default function FormatSettings() { +export function FormatSettings() { const { savePrefs } = useActions(); const sidebar = useSidebar(); diff --git a/packages/desktop-client/src/components/settings/Global.tsx b/packages/desktop-client/src/components/settings/Global.tsx index d0901f6d896..96a8c4090bc 100644 --- a/packages/desktop-client/src/components/settings/Global.tsx +++ b/packages/desktop-client/src/components/settings/Global.tsx @@ -10,7 +10,7 @@ import { View } from '../common/View'; import { Setting } from './UI'; -export default function GlobalSettings() { +export function GlobalSettings() { const documentDir = useSelector(state => state.prefs.global.documentDir); const { saveGlobalPrefs } = useActions(); diff --git a/packages/desktop-client/src/components/settings/Themes.tsx b/packages/desktop-client/src/components/settings/Themes.tsx index 954dd70396c..775ef525340 100644 --- a/packages/desktop-client/src/components/settings/Themes.tsx +++ b/packages/desktop-client/src/components/settings/Themes.tsx @@ -8,7 +8,7 @@ import { Text } from '../common/Text'; import { Setting } from './UI'; -export default function ThemeSettings() { +export function ThemeSettings() { const theme = useTheme(); const { saveGlobalPrefs } = useActions(); diff --git a/packages/desktop-client/src/components/settings/index.tsx b/packages/desktop-client/src/components/settings/index.tsx index 44554972c06..dd6eb214e6e 100644 --- a/packages/desktop-client/src/components/settings/index.tsx +++ b/packages/desktop-client/src/components/settings/index.tsx @@ -21,14 +21,14 @@ import { FormField, FormLabel } from '../forms'; import { Page } from '../Page'; import { useServerVersion } from '../ServerContext'; -import EncryptionSettings from './Encryption'; -import ExperimentalFeatures from './Experimental'; -import ExportBudget from './Export'; -import FixSplitsTool from './FixSplits'; -import FormatSettings from './Format'; -import GlobalSettings from './Global'; +import { EncryptionSettings } from './Encryption'; +import { ExperimentalFeatures } from './Experimental'; +import { ExportBudget } from './Export'; +import { FixSplits } from './FixSplits'; +import { FormatSettings } from './Format'; +import { GlobalSettings } from './Global'; import { ResetCache, ResetSync } from './Reset'; -import ThemeSettings from './Themes'; +import { ThemeSettings } from './Themes'; import { AdvancedToggle, Setting } from './UI'; function About() { @@ -116,7 +116,7 @@ function AdvancedAbout() { ); } -export default function Settings() { +export function Settings() { const floatingSidebar = useSelector( state => state.prefs.global.floatingSidebar, ); @@ -175,7 +175,7 @@ export default function Settings() { - + diff --git a/packages/desktop-client/src/components/sidebar/Account.tsx b/packages/desktop-client/src/components/sidebar/Account.tsx index b6f677c0f56..d079d6d6287 100644 --- a/packages/desktop-client/src/components/sidebar/Account.tsx +++ b/packages/desktop-client/src/components/sidebar/Account.tsx @@ -16,7 +16,7 @@ import { type OnDropCallback, } from '../sort'; import { type Binding } from '../spreadsheet'; -import CellValue from '../spreadsheet/CellValue'; +import { CellValue } from '../spreadsheet/CellValue'; export const accountNameStyle: CSSProperties = { marginTop: -2, @@ -45,7 +45,7 @@ type AccountProps = { onDrop?: OnDropCallback; }; -function Account({ +export function Account({ name, account, connected, @@ -144,5 +144,3 @@ function Account({ ); } - -export default Account; diff --git a/packages/desktop-client/src/components/sidebar/Accounts.tsx b/packages/desktop-client/src/components/sidebar/Accounts.tsx index 488b3a12950..2fd79d5d17a 100644 --- a/packages/desktop-client/src/components/sidebar/Accounts.tsx +++ b/packages/desktop-client/src/components/sidebar/Accounts.tsx @@ -7,8 +7,8 @@ import { View } from '../common/View'; import { type OnDropCallback } from '../sort'; import { type Binding } from '../spreadsheet'; -import Account from './Account'; -import SecondaryItem from './SecondaryItem'; +import { Account } from './Account'; +import { SecondaryItem } from './SecondaryItem'; const fontWeight = 600; @@ -36,7 +36,7 @@ type AccountsProps = { onReorder: OnDropCallback; }; -function Accounts({ +export function Accounts({ accounts, failedAccounts, updatedAccounts, @@ -180,5 +180,3 @@ function Accounts({ ); } - -export default Accounts; diff --git a/packages/desktop-client/src/components/sidebar/Item.tsx b/packages/desktop-client/src/components/sidebar/Item.tsx index ffc0d61b30e..3c6a1c4f0f6 100644 --- a/packages/desktop-client/src/components/sidebar/Item.tsx +++ b/packages/desktop-client/src/components/sidebar/Item.tsx @@ -9,7 +9,7 @@ import { styles, theme, type CSSProperties } from '../../style'; import { Block } from '../common/Block'; import { View } from '../common/View'; -import ItemContent from './ItemContent'; +import { ItemContent } from './ItemContent'; type ItemProps = { title: string; @@ -25,7 +25,7 @@ type ItemProps = { forceActive?: boolean; }; -function Item({ +export function Item({ children, Icon, title, @@ -83,5 +83,3 @@ function Item({ ); } - -export default Item; diff --git a/packages/desktop-client/src/components/sidebar/ItemContent.tsx b/packages/desktop-client/src/components/sidebar/ItemContent.tsx index 09c4f966b81..6a4a50423bc 100644 --- a/packages/desktop-client/src/components/sidebar/ItemContent.tsx +++ b/packages/desktop-client/src/components/sidebar/ItemContent.tsx @@ -13,7 +13,7 @@ type ItemContentProps = { forceActive?: boolean; }; -function ItemContent({ +export function ItemContent({ style, to, onClick, @@ -43,5 +43,3 @@ function ItemContent({ ); } - -export default ItemContent; diff --git a/packages/desktop-client/src/components/sidebar/SecondaryItem.tsx b/packages/desktop-client/src/components/sidebar/SecondaryItem.tsx index 2af833f740c..0203532e68f 100644 --- a/packages/desktop-client/src/components/sidebar/SecondaryItem.tsx +++ b/packages/desktop-client/src/components/sidebar/SecondaryItem.tsx @@ -9,7 +9,7 @@ import { Block } from '../common/Block'; import { View } from '../common/View'; import { accountNameStyle } from './Account'; -import ItemContent from './ItemContent'; +import { ItemContent } from './ItemContent'; const fontWeight = 600; @@ -25,7 +25,7 @@ type SecondaryItemProps = { indent?: number; }; -function SecondaryItem({ +export function SecondaryItem({ Icon, title, style, @@ -73,5 +73,3 @@ function SecondaryItem({ ); } - -export default SecondaryItem; diff --git a/packages/desktop-client/src/components/sidebar/Sidebar.tsx b/packages/desktop-client/src/components/sidebar/Sidebar.tsx index 00633188b61..84c8b8036b2 100644 --- a/packages/desktop-client/src/components/sidebar/Sidebar.tsx +++ b/packages/desktop-client/src/components/sidebar/Sidebar.tsx @@ -11,10 +11,10 @@ import { View } from '../common/View'; import { type OnDropCallback } from '../sort'; import { type Binding } from '../spreadsheet'; -import Accounts from './Accounts'; -import Item from './Item'; -import ToggleButton from './ToggleButton'; -import Tools from './Tools'; +import { Accounts } from './Accounts'; +import { Item } from './Item'; +import { ToggleButton } from './ToggleButton'; +import { Tools } from './Tools'; import { useSidebar } from '.'; @@ -44,7 +44,7 @@ type SidebarProps = { onReorder: OnDropCallback; }; -function Sidebar({ +export function Sidebar({ style, budgetName, accounts, @@ -144,5 +144,3 @@ function Sidebar({ ); } - -export default Sidebar; diff --git a/packages/desktop-client/src/components/sidebar/SidebarWithData.tsx b/packages/desktop-client/src/components/sidebar/SidebarWithData.tsx index d775645653c..1e4b8b35cfc 100644 --- a/packages/desktop-client/src/components/sidebar/SidebarWithData.tsx +++ b/packages/desktop-client/src/components/sidebar/SidebarWithData.tsx @@ -18,7 +18,7 @@ import { Menu } from '../common/Menu'; import { Text } from '../common/Text'; import { Tooltip } from '../tooltips'; -import Sidebar from './Sidebar'; +import { Sidebar } from './Sidebar'; type EditableBudgetNameProps = { prefs: LocalPrefs; @@ -113,7 +113,7 @@ function EditableBudgetName({ prefs, savePrefs }: EditableBudgetNameProps) { } } -function SidebarWithData() { +export function SidebarWithData() { const accounts = useSelector(state => state.queries.accounts); const failedAccounts = useSelector(state => state.account.failedAccounts); const updatedAccounts = useSelector(state => state.queries.updatedAccounts); @@ -164,5 +164,3 @@ function SidebarWithData() { /> ); } - -export default SidebarWithData; diff --git a/packages/desktop-client/src/components/sidebar/ToggleButton.tsx b/packages/desktop-client/src/components/sidebar/ToggleButton.tsx index cd0f4bd3397..8d473dcb64c 100644 --- a/packages/desktop-client/src/components/sidebar/ToggleButton.tsx +++ b/packages/desktop-client/src/components/sidebar/ToggleButton.tsx @@ -12,7 +12,11 @@ type ToggleButtonProps = { style?: CSSProperties; }; -function ToggleButton({ style, isFloating, onFloat }: ToggleButtonProps) { +export function ToggleButton({ + style, + isFloating, + onFloat, +}: ToggleButtonProps) { return (