mirror of
https://github.com/actualbudget/actual.git
synced 2026-03-24 23:32:32 -05:00
Compare commits
2 Commits
claude/bro
...
loot-core-
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
1ad10bd41d | ||
|
|
2edc6800ce |
1
TODO.txt
Normal file
1
TODO.txt
Normal file
@@ -0,0 +1 @@
|
||||
Figure out why loot-core-server is not detecting loot-core-shared files.
|
||||
@@ -4,7 +4,8 @@ ROOT=`dirname $0`
|
||||
|
||||
cd "$ROOT/.."
|
||||
|
||||
yarn workspace loot-core build:browser
|
||||
yarn workspace loot-core-server build:browser
|
||||
# yarn workspace loot-core build:browser
|
||||
yarn workspace @actual-app/web build:browser
|
||||
|
||||
echo "packages/desktop-client/build"
|
||||
|
||||
@@ -34,7 +34,8 @@ if [ "$OSTYPE" == "msys" ]; then
|
||||
fi
|
||||
fi
|
||||
|
||||
yarn workspace loot-core build:node
|
||||
yarn workspace loot-core-server build:node
|
||||
# yarn workspace loot-core build:node
|
||||
|
||||
yarn workspace @actual-app/web build --mode=desktop # electron specific build
|
||||
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
import { test, expect } from '@playwright/test';
|
||||
|
||||
import * as monthUtils from 'loot-core/src/shared/months';
|
||||
import * as monthUtils from 'loot-core-shared/months';
|
||||
|
||||
import { ConfigurationPage } from './page-models/configuration-page';
|
||||
import { MobileNavigation } from './page-models/mobile-navigation';
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { initBackend as initSQLBackend } from 'absurd-sql/dist/indexeddb-main-thread';
|
||||
import { registerSW } from 'virtual:pwa-register';
|
||||
|
||||
import * as Platform from 'loot-core/src/client/platform';
|
||||
import * as Platform from 'loot-core/client/platform';
|
||||
|
||||
import packageJson from '../package.json';
|
||||
|
||||
|
||||
@@ -19,12 +19,9 @@ import {
|
||||
setAppState,
|
||||
sync,
|
||||
} from 'loot-core/client/actions';
|
||||
import * as Platform from 'loot-core/client/platform';
|
||||
import { SpreadsheetProvider } from 'loot-core/client/SpreadsheetProvider';
|
||||
import * as Platform from 'loot-core/src/client/platform';
|
||||
import {
|
||||
init as initConnection,
|
||||
send,
|
||||
} from 'loot-core/src/platform/client/fetch';
|
||||
import { init as initConnection, send } from 'loot-core/platform/client/fetch';
|
||||
|
||||
import { useMetadataPref } from '../hooks/useMetadataPref';
|
||||
import { installPolyfills } from '../polyfills';
|
||||
|
||||
@@ -3,7 +3,7 @@ import { Trans } from 'react-i18next';
|
||||
import { useSelector } from 'react-redux';
|
||||
import { useTransition, animated } from 'react-spring';
|
||||
|
||||
import { type State } from 'loot-core/src/client/state-types';
|
||||
import { type State } from 'loot-core/client/state-types';
|
||||
|
||||
import { theme, styles } from '../style';
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import React, { useState, type ReactNode } from 'react';
|
||||
import { useTranslation, Trans } from 'react-i18next';
|
||||
|
||||
import { LazyLoadFailedError } from 'loot-core/src/shared/errors';
|
||||
import { LazyLoadFailedError } from 'loot-core-shared/errors';
|
||||
|
||||
import { Block } from './common/Block';
|
||||
import { Button } from './common/Button2';
|
||||
|
||||
@@ -11,8 +11,8 @@ import {
|
||||
} from 'react-router-dom';
|
||||
|
||||
import { addNotification, sync } from 'loot-core/client/actions';
|
||||
import { type State } from 'loot-core/src/client/state-types';
|
||||
import * as undo from 'loot-core/src/platform/client/undo';
|
||||
import { type State } from 'loot-core/client/state-types';
|
||||
import * as undo from 'loot-core/platform/client/undo';
|
||||
|
||||
import { useAccounts } from '../hooks/useAccounts';
|
||||
import { useLocalPref } from '../hooks/useLocalPref';
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { useEffect } from 'react';
|
||||
|
||||
import * as Platform from 'loot-core/src/client/platform';
|
||||
import * as Platform from 'loot-core/client/platform';
|
||||
|
||||
import { useNavigate } from '../hooks/useNavigate';
|
||||
|
||||
|
||||
@@ -3,7 +3,7 @@ import React, { useState, useEffect, useRef, type CSSProperties } from 'react';
|
||||
import { Trans, useTranslation } from 'react-i18next';
|
||||
import { useSelector } from 'react-redux';
|
||||
|
||||
import { type State } from 'loot-core/src/client/state-types';
|
||||
import { type State } from 'loot-core/client/state-types';
|
||||
|
||||
import { useActions } from '../hooks/useActions';
|
||||
import { theme, styles } from '../style';
|
||||
|
||||
@@ -10,16 +10,17 @@ import React, {
|
||||
import { useTranslation } from 'react-i18next';
|
||||
import { useDispatch } from 'react-redux';
|
||||
|
||||
import { getNormalisedString } from 'loot-core-shared/normalisation';
|
||||
import { q } from 'loot-core-shared/query';
|
||||
import { mapField, friendlyOp } from 'loot-core-shared/rules';
|
||||
import { describeSchedule } from 'loot-core-shared/schedules';
|
||||
import { type NewRuleEntity } from 'loot-core-shared/types/models';
|
||||
|
||||
import { pushModal } from 'loot-core/client/actions/modals';
|
||||
import { initiallyLoadPayees } from 'loot-core/client/actions/queries';
|
||||
import { useSchedules } from 'loot-core/client/data-hooks/schedules';
|
||||
import { q } from 'loot-core/shared/query';
|
||||
import { pushModal } from 'loot-core/src/client/actions/modals';
|
||||
import { initiallyLoadPayees } from 'loot-core/src/client/actions/queries';
|
||||
import { send } from 'loot-core/src/platform/client/fetch';
|
||||
import * as undo from 'loot-core/src/platform/client/undo';
|
||||
import { getNormalisedString } from 'loot-core/src/shared/normalisation';
|
||||
import { mapField, friendlyOp } from 'loot-core/src/shared/rules';
|
||||
import { describeSchedule } from 'loot-core/src/shared/schedules';
|
||||
import { type NewRuleEntity } from 'loot-core/src/types/models';
|
||||
import { send } from 'loot-core/platform/client/fetch';
|
||||
import * as undo from 'loot-core/platform/client/undo';
|
||||
|
||||
import { useAccounts } from '../hooks/useAccounts';
|
||||
import { useCategories } from '../hooks/useCategories';
|
||||
|
||||
@@ -4,9 +4,10 @@ import { useTranslation } from 'react-i18next';
|
||||
import { useDispatch } from 'react-redux';
|
||||
import { useLocation } from 'react-router-dom';
|
||||
|
||||
import * as monthUtils from 'loot-core-shared/months';
|
||||
|
||||
import { closeModal } from 'loot-core/client/actions';
|
||||
import { send } from 'loot-core/src/platform/client/fetch';
|
||||
import * as monthUtils from 'loot-core/src/shared/months';
|
||||
import { send } from 'loot-core/platform/client/fetch';
|
||||
|
||||
import { useMetadataPref } from '../hooks/useMetadataPref';
|
||||
import { useModalState } from '../hooks/useModalState';
|
||||
|
||||
@@ -8,7 +8,7 @@ import React, {
|
||||
|
||||
import { t } from 'i18next';
|
||||
|
||||
import { send } from 'loot-core/src/platform/client/fetch';
|
||||
import { send } from 'loot-core/platform/client/fetch';
|
||||
|
||||
import { useNotes } from '../hooks/useNotes';
|
||||
import { SvgCustomNotesPaper } from '../icons/v2';
|
||||
|
||||
@@ -12,8 +12,8 @@ import { css } from '@emotion/css';
|
||||
import { t } from 'i18next';
|
||||
|
||||
import { removeNotification } from 'loot-core/client/actions';
|
||||
import { type State } from 'loot-core/src/client/state-types';
|
||||
import type { NotificationWithId } from 'loot-core/src/client/state-types/notifications';
|
||||
import { type State } from 'loot-core/client/state-types';
|
||||
import type { NotificationWithId } from 'loot-core/client/state-types/notifications';
|
||||
|
||||
import { AnimatedLoading } from '../icons/AnimatedLoading';
|
||||
import { SvgDelete } from '../icons/v0';
|
||||
|
||||
@@ -8,7 +8,7 @@ import React, {
|
||||
type ReactNode,
|
||||
} from 'react';
|
||||
|
||||
import { send } from 'loot-core/src/platform/client/fetch';
|
||||
import { send } from 'loot-core/platform/client/fetch';
|
||||
|
||||
type ServerContextValue = {
|
||||
url: string | null;
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
import React, { useRef, useState, type CSSProperties } from 'react';
|
||||
|
||||
import { t } from 'i18next';
|
||||
|
||||
import type { Theme } from 'loot-core/src/types/prefs';
|
||||
import type { Theme } from 'loot-core-shared/types/prefs';
|
||||
|
||||
import { SvgMoonStars, SvgSun, SvgSystem } from '../icons/v2';
|
||||
import { themeOptions, useTheme } from '../style';
|
||||
|
||||
@@ -4,14 +4,14 @@ import { Routes, Route, useLocation } from 'react-router-dom';
|
||||
|
||||
import { css } from '@emotion/css';
|
||||
import { t } from 'i18next';
|
||||
|
||||
import * as Platform from 'loot-core/src/client/platform';
|
||||
import * as queries from 'loot-core/src/client/queries';
|
||||
import { listen } from 'loot-core/src/platform/client/fetch';
|
||||
import {
|
||||
isDevelopmentEnvironment,
|
||||
isElectron,
|
||||
} from 'loot-core/src/shared/environment';
|
||||
} from 'loot-core-shared/environment';
|
||||
|
||||
import * as Platform from 'loot-core/client/platform';
|
||||
import * as queries from 'loot-core/client/queries';
|
||||
import { listen } from 'loot-core/platform/client/fetch';
|
||||
|
||||
import { useActions } from '../hooks/useActions';
|
||||
import { useGlobalPref } from '../hooks/useGlobalPref';
|
||||
|
||||
@@ -2,7 +2,7 @@ import React from 'react';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
import { useSelector } from 'react-redux';
|
||||
|
||||
import { type State } from 'loot-core/src/client/state-types';
|
||||
import { type State } from 'loot-core/client/state-types';
|
||||
|
||||
import { useActions } from '../hooks/useActions';
|
||||
import { SvgClose } from '../icons/v1';
|
||||
|
||||
@@ -13,24 +13,9 @@ import { Navigate, useParams, useLocation } from 'react-router-dom';
|
||||
|
||||
import { debounce } from 'debounce';
|
||||
import { t } from 'i18next';
|
||||
import { v4 as uuidv4 } from 'uuid';
|
||||
|
||||
import { validForTransfer } from 'loot-core/client/transfer';
|
||||
import { type UndoState } from 'loot-core/server/undo';
|
||||
import { useFilters } from 'loot-core/src/client/data-hooks/filters';
|
||||
import {
|
||||
SchedulesProvider,
|
||||
accountSchedulesQuery,
|
||||
} from 'loot-core/src/client/data-hooks/schedules';
|
||||
import * as queries from 'loot-core/src/client/queries';
|
||||
import {
|
||||
runQuery,
|
||||
pagedQuery,
|
||||
type PagedQuery,
|
||||
} from 'loot-core/src/client/query-helpers';
|
||||
import { send, listen } from 'loot-core/src/platform/client/fetch';
|
||||
import { currentDay } from 'loot-core/src/shared/months';
|
||||
import { q, type Query } from 'loot-core/src/shared/query';
|
||||
import { type UndoState } from 'loot-core-server/undo';
|
||||
import { currentDay } from 'loot-core-shared/months';
|
||||
import { q, type Query } from 'loot-core-shared/query';
|
||||
import {
|
||||
updateTransaction,
|
||||
realizeTempTransactions,
|
||||
@@ -38,8 +23,7 @@ import {
|
||||
ungroupTransactions,
|
||||
makeChild,
|
||||
makeAsNonChildTransactions,
|
||||
} from 'loot-core/src/shared/transactions';
|
||||
import { applyChanges, groupById } from 'loot-core/src/shared/util';
|
||||
} from 'loot-core-shared/transactions';
|
||||
import {
|
||||
type NewRuleEntity,
|
||||
type RuleActionEntity,
|
||||
@@ -48,7 +32,23 @@ import {
|
||||
type RuleConditionEntity,
|
||||
type TransactionEntity,
|
||||
type TransactionFilterEntity,
|
||||
} from 'loot-core/src/types/models';
|
||||
} from 'loot-core-shared/types/models';
|
||||
import { applyChanges, groupById } from 'loot-core-shared/util';
|
||||
import { v4 as uuidv4 } from 'uuid';
|
||||
|
||||
import { useFilters } from 'loot-core/client/data-hooks/filters';
|
||||
import {
|
||||
SchedulesProvider,
|
||||
accountSchedulesQuery,
|
||||
} from 'loot-core/client/data-hooks/schedules';
|
||||
import * as queries from 'loot-core/client/queries';
|
||||
import {
|
||||
runQuery,
|
||||
pagedQuery,
|
||||
type PagedQuery,
|
||||
} from 'loot-core/client/query-helpers';
|
||||
import { validForTransfer } from 'loot-core/client/transfer';
|
||||
import { send, listen } from 'loot-core/platform/client/fetch';
|
||||
|
||||
import { useAccountPreviewTransactions } from '../../hooks/useAccountPreviewTransactions';
|
||||
import { useAccounts } from '../../hooks/useAccounts';
|
||||
|
||||
@@ -4,9 +4,9 @@ import { useDispatch, useSelector } from 'react-redux';
|
||||
import { useParams } from 'react-router-dom';
|
||||
|
||||
import { t } from 'i18next';
|
||||
import { type AccountEntity } from 'loot-core-shared/types/models';
|
||||
|
||||
import { unlinkAccount } from 'loot-core/client/actions';
|
||||
import { type AccountEntity } from 'loot-core/types/models';
|
||||
|
||||
import { authorizeBank } from '../../gocardless';
|
||||
import { useAccounts } from '../../hooks/useAccounts';
|
||||
|
||||
@@ -1,12 +1,12 @@
|
||||
import React, { useRef } from 'react';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
|
||||
import { q } from 'loot-core-shared/query';
|
||||
import { getScheduledAmount } from 'loot-core-shared/schedules';
|
||||
import { isPreviewId } from 'loot-core-shared/transactions';
|
||||
import { useHover } from 'usehooks-ts';
|
||||
|
||||
import { isPreviewId } from 'loot-core/shared/transactions';
|
||||
import { useCachedSchedules } from 'loot-core/src/client/data-hooks/schedules';
|
||||
import { q } from 'loot-core/src/shared/query';
|
||||
import { getScheduledAmount } from 'loot-core/src/shared/schedules';
|
||||
import { useCachedSchedules } from 'loot-core/client/data-hooks/schedules';
|
||||
|
||||
import { useSelectedItems } from '../../hooks/useSelected';
|
||||
import { SvgArrowButtonRight1 } from '../../icons/v2';
|
||||
|
||||
@@ -13,7 +13,7 @@ import {
|
||||
type RuleConditionEntity,
|
||||
type TransactionEntity,
|
||||
type TransactionFilterEntity,
|
||||
} from 'loot-core/types/models';
|
||||
} from 'loot-core-shared/types/models';
|
||||
|
||||
import { useLocalPref } from '../../hooks/useLocalPref';
|
||||
import { useSplitsExpanded } from '../../hooks/useSplitsExpanded';
|
||||
|
||||
@@ -1,10 +1,11 @@
|
||||
import React, { useState } from 'react';
|
||||
import { Trans } from 'react-i18next';
|
||||
|
||||
import * as queries from 'loot-core/src/client/queries';
|
||||
import { type Query } from 'loot-core/src/shared/query';
|
||||
import { currencyToInteger } from 'loot-core/src/shared/util';
|
||||
import { type AccountEntity } from 'loot-core/types/models';
|
||||
import { type Query } from 'loot-core-shared/query';
|
||||
import { type AccountEntity } from 'loot-core-shared/types/models';
|
||||
import { currencyToInteger } from 'loot-core-shared/util';
|
||||
|
||||
import * as queries from 'loot-core/client/queries';
|
||||
|
||||
import { SvgCheckCircle1 } from '../../icons/v2';
|
||||
import { styles, theme } from '../../style';
|
||||
|
||||
@@ -9,8 +9,7 @@ import React, {
|
||||
import { useTranslation } from 'react-i18next';
|
||||
|
||||
import { css, cx } from '@emotion/css';
|
||||
|
||||
import { type AccountEntity } from 'loot-core/src/types/models';
|
||||
import { type AccountEntity } from 'loot-core-shared/types/models';
|
||||
|
||||
import { useAccounts } from '../../hooks/useAccounts';
|
||||
import { theme, styles } from '../../style';
|
||||
|
||||
@@ -13,8 +13,7 @@ import React, {
|
||||
|
||||
import { css, cx } from '@emotion/css';
|
||||
import Downshift, { type StateChangeTypes } from 'downshift';
|
||||
|
||||
import { getNormalisedString } from 'loot-core/src/shared/normalisation';
|
||||
import { getNormalisedString } from 'loot-core-shared/normalisation';
|
||||
|
||||
import { SvgRemove } from '../../icons/v2';
|
||||
import { theme, styles } from '../../style';
|
||||
|
||||
@@ -13,14 +13,14 @@ import React, {
|
||||
import { Trans, useTranslation } from 'react-i18next';
|
||||
|
||||
import { css, cx } from '@emotion/css';
|
||||
|
||||
import { trackingBudget, envelopeBudget } from 'loot-core/client/queries';
|
||||
import { integerToCurrency } from 'loot-core/shared/util';
|
||||
import { getNormalisedString } from 'loot-core/src/shared/normalisation';
|
||||
import { getNormalisedString } from 'loot-core-shared/normalisation';
|
||||
import {
|
||||
type CategoryEntity,
|
||||
type CategoryGroupEntity,
|
||||
} from 'loot-core/src/types/models';
|
||||
} from 'loot-core-shared/types/models';
|
||||
import { integerToCurrency } from 'loot-core-shared/util';
|
||||
|
||||
import { trackingBudget, envelopeBudget } from 'loot-core/client/queries';
|
||||
|
||||
import { useCategories } from '../../hooks/useCategories';
|
||||
import { useSyncedPref } from '../../hooks/useSyncedPref';
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
import React, { type ComponentProps } from 'react';
|
||||
|
||||
import { useFilters } from 'loot-core/src/client/data-hooks/filters';
|
||||
import { type TransactionFilterEntity } from 'loot-core/types/models/transaction-filter';
|
||||
import { type TransactionFilterEntity } from 'loot-core-shared/types/models/transaction-filter';
|
||||
|
||||
import { useFilters } from 'loot-core/client/data-hooks/filters';
|
||||
|
||||
import { Autocomplete } from './Autocomplete';
|
||||
import { FilterList } from './FilterList';
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
import { render, type Screen, screen } from '@testing-library/react';
|
||||
import userEvent from '@testing-library/user-event';
|
||||
import type { AccountEntity, PayeeEntity } from 'loot-core-shared/types/models';
|
||||
import { vi } from 'vitest';
|
||||
|
||||
import { generateAccount } from 'loot-core/src/mocks';
|
||||
import { TestProvider } from 'loot-core/src/mocks/redux';
|
||||
import type { AccountEntity, PayeeEntity } from 'loot-core/types/models';
|
||||
|
||||
import { useCommonPayees } from '../../hooks/usePayees';
|
||||
import { ResponsiveProvider } from '../responsive/ResponsiveProvider';
|
||||
|
||||
@@ -15,14 +15,14 @@ import { Trans, useTranslation } from 'react-i18next';
|
||||
import { useDispatch } from 'react-redux';
|
||||
|
||||
import { css, cx } from '@emotion/css';
|
||||
|
||||
import { createPayee } from 'loot-core/src/client/actions/queries';
|
||||
import { getActivePayees } from 'loot-core/src/client/reducers/queries';
|
||||
import { getNormalisedString } from 'loot-core/src/shared/normalisation';
|
||||
import { getNormalisedString } from 'loot-core-shared/normalisation';
|
||||
import {
|
||||
type AccountEntity,
|
||||
type PayeeEntity,
|
||||
} from 'loot-core/src/types/models';
|
||||
} from 'loot-core-shared/types/models';
|
||||
|
||||
import { createPayee } from 'loot-core/client/actions/queries';
|
||||
import { getActivePayees } from 'loot-core/client/reducers/queries';
|
||||
|
||||
import { useAccounts } from '../../hooks/useAccounts';
|
||||
import { useCommonPayees, usePayees } from '../../hooks/usePayees';
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
import React, { type ComponentProps } from 'react';
|
||||
|
||||
import { type CustomReportEntity } from 'loot-core-shared/types/models/reports';
|
||||
|
||||
import { useReports } from 'loot-core/client/data-hooks/reports';
|
||||
import { type CustomReportEntity } from 'loot-core/src/types/models/reports';
|
||||
|
||||
import { Autocomplete } from './Autocomplete';
|
||||
import { ReportList } from './ReportList';
|
||||
|
||||
@@ -8,8 +8,7 @@ import React, {
|
||||
import { useSpring, animated } from 'react-spring';
|
||||
|
||||
import { css } from '@emotion/css';
|
||||
|
||||
import { addMonths, subMonths } from 'loot-core/src/shared/months';
|
||||
import { addMonths, subMonths } from 'loot-core-shared/months';
|
||||
|
||||
import { useResizeObserver } from '../../hooks/useResizeObserver';
|
||||
import { View } from '../common/View';
|
||||
|
||||
@@ -3,7 +3,7 @@ import React, { useEffect, type ComponentProps } from 'react';
|
||||
import { useHotkeys } from 'react-hotkeys-hook';
|
||||
import AutoSizer from 'react-virtualized-auto-sizer';
|
||||
|
||||
import * as monthUtils from 'loot-core/src/shared/months';
|
||||
import * as monthUtils from 'loot-core-shared/months';
|
||||
|
||||
import { View } from '../common/View';
|
||||
|
||||
|
||||
@@ -4,7 +4,7 @@ import React, { type ComponentProps } from 'react';
|
||||
import {
|
||||
type CategoryGroupEntity,
|
||||
type CategoryEntity,
|
||||
} from 'loot-core/src/types/models';
|
||||
} from 'loot-core-shared/types/models';
|
||||
|
||||
import { theme } from '../../style';
|
||||
import { View } from '../common/View';
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
// @ts-strict-ignore
|
||||
import React, { type ComponentProps } from 'react';
|
||||
|
||||
import { type CategoryEntity } from 'loot-core/src/types/models';
|
||||
import { type CategoryEntity } from 'loot-core-shared/types/models';
|
||||
|
||||
import {
|
||||
useDraggable,
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
// @ts-strict-ignore
|
||||
import { type CSSProperties, useState } from 'react';
|
||||
|
||||
import * as monthUtils from 'loot-core/src/shared/months';
|
||||
import * as monthUtils from 'loot-core-shared/months';
|
||||
|
||||
import { useResizeObserver } from '../../hooks/useResizeObserver';
|
||||
import { styles, theme } from '../../style';
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
// @ts-strict-ignore
|
||||
import React, { createContext, type ReactNode } from 'react';
|
||||
|
||||
import * as monthUtils from 'loot-core/src/shared/months';
|
||||
import * as monthUtils from 'loot-core-shared/months';
|
||||
|
||||
export type BoundsProps = {
|
||||
start: string;
|
||||
|
||||
@@ -5,7 +5,7 @@ import React, {
|
||||
type ComponentType,
|
||||
} from 'react';
|
||||
|
||||
import * as monthUtils from 'loot-core/src/shared/months';
|
||||
import * as monthUtils from 'loot-core-shared/months';
|
||||
|
||||
import { theme } from '../../style';
|
||||
import { View } from '../common/View';
|
||||
|
||||
@@ -5,7 +5,7 @@ import { useTranslation } from 'react-i18next';
|
||||
import {
|
||||
type CategoryGroupEntity,
|
||||
type CategoryEntity,
|
||||
} from 'loot-core/src/types/models';
|
||||
} from 'loot-core-shared/types/models';
|
||||
|
||||
import { useFeatureFlag } from '../../hooks/useFeatureFlag';
|
||||
import { SvgCheveronDown } from '../../icons/v1';
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import React, { type ComponentPropsWithoutRef } from 'react';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
|
||||
import { envelopeBudget } from 'loot-core/src/client/queries';
|
||||
import { envelopeBudget } from 'loot-core/client/queries';
|
||||
|
||||
import { Menu } from '../../common/Menu';
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import React, { useCallback, useRef, useState } from 'react';
|
||||
|
||||
import { envelopeBudget } from 'loot-core/src/client/queries';
|
||||
import { envelopeBudget } from 'loot-core/client/queries';
|
||||
|
||||
import { BalanceMenu } from './BalanceMenu';
|
||||
import { CoverMenu } from './CoverMenu';
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import React, { useMemo, useState } from 'react';
|
||||
import { Trans, useTranslation } from 'react-i18next';
|
||||
|
||||
import { type CategoryEntity } from 'loot-core/src/types/models';
|
||||
import { type CategoryEntity } from 'loot-core-shared/types/models';
|
||||
|
||||
import { useCategories } from '../../../hooks/useCategories';
|
||||
import { CategoryAutocomplete } from '../../autocomplete/CategoryAutocomplete';
|
||||
|
||||
@@ -8,11 +8,11 @@ import React, {
|
||||
import { useTranslation, Trans } from 'react-i18next';
|
||||
|
||||
import { css } from '@emotion/css';
|
||||
import { evalArithmetic } from 'loot-core-shared/arithmetic';
|
||||
import * as monthUtils from 'loot-core-shared/months';
|
||||
import { integerToCurrency, amountToInteger } from 'loot-core-shared/util';
|
||||
|
||||
import { envelopeBudget } from 'loot-core/src/client/queries';
|
||||
import { evalArithmetic } from 'loot-core/src/shared/arithmetic';
|
||||
import * as monthUtils from 'loot-core/src/shared/months';
|
||||
import { integerToCurrency, amountToInteger } from 'loot-core/src/shared/util';
|
||||
import { envelopeBudget } from 'loot-core/client/queries';
|
||||
|
||||
import { useFeatureFlag } from '../../../hooks/useFeatureFlag';
|
||||
import { useUndo } from '../../../hooks/useUndo';
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import React, { type ReactNode, createContext, useContext } from 'react';
|
||||
|
||||
import * as monthUtils from 'loot-core/src/shared/months';
|
||||
import * as monthUtils from 'loot-core-shared/months';
|
||||
|
||||
type EnvelopeBudgetContextDefinition = {
|
||||
summaryCollapsed: boolean;
|
||||
|
||||
@@ -6,9 +6,10 @@ import React, {
|
||||
} from 'react';
|
||||
import { Trans } from 'react-i18next';
|
||||
|
||||
import { useSpreadsheet } from 'loot-core/src/client/SpreadsheetProvider';
|
||||
import { evalArithmetic } from 'loot-core/src/shared/arithmetic';
|
||||
import { integerToCurrency, amountToInteger } from 'loot-core/src/shared/util';
|
||||
import { evalArithmetic } from 'loot-core-shared/arithmetic';
|
||||
import { integerToCurrency, amountToInteger } from 'loot-core-shared/util';
|
||||
|
||||
import { useSpreadsheet } from 'loot-core/client/SpreadsheetProvider';
|
||||
|
||||
import { Button } from '../../common/Button2';
|
||||
import { InitialFocus } from '../../common/InitialFocus';
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
import React, { useMemo, useState } from 'react';
|
||||
import { Trans } from 'react-i18next';
|
||||
|
||||
import { evalArithmetic } from 'loot-core/src/shared/arithmetic';
|
||||
import { integerToCurrency, amountToInteger } from 'loot-core/src/shared/util';
|
||||
import { type CategoryEntity } from 'loot-core/types/models';
|
||||
import { evalArithmetic } from 'loot-core-shared/arithmetic';
|
||||
import { type CategoryEntity } from 'loot-core-shared/types/models';
|
||||
import { integerToCurrency, amountToInteger } from 'loot-core-shared/util';
|
||||
|
||||
import { useCategories } from '../../../hooks/useCategories';
|
||||
import { CategoryAutocomplete } from '../../autocomplete/CategoryAutocomplete';
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
import React, { useRef, useState } from 'react';
|
||||
|
||||
import { css } from '@emotion/css';
|
||||
|
||||
import * as monthUtils from 'loot-core/src/shared/months';
|
||||
import * as monthUtils from 'loot-core-shared/months';
|
||||
|
||||
import { SvgDotsHorizontalTriple } from '../../../../icons/v1';
|
||||
import { SvgArrowButtonDown1, SvgArrowButtonUp1 } from '../../../../icons/v2';
|
||||
|
||||
@@ -5,7 +5,7 @@ import React, {
|
||||
useCallback,
|
||||
} from 'react';
|
||||
|
||||
import { envelopeBudget } from 'loot-core/src/client/queries';
|
||||
import { envelopeBudget } from 'loot-core/client/queries';
|
||||
|
||||
import { useFeatureFlag } from '../../../../hooks/useFeatureFlag';
|
||||
import { Popover } from '../../../common/Popover';
|
||||
|
||||
@@ -2,7 +2,7 @@ import React, { type CSSProperties, type MouseEventHandler } from 'react';
|
||||
|
||||
import { css } from '@emotion/css';
|
||||
|
||||
import { envelopeBudget } from 'loot-core/src/client/queries';
|
||||
import { envelopeBudget } from 'loot-core/client/queries';
|
||||
|
||||
import { theme, styles } from '../../../../style';
|
||||
import { Block } from '../../../common/Block';
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import React, { type CSSProperties } from 'react';
|
||||
|
||||
import { envelopeBudget } from 'loot-core/src/client/queries';
|
||||
import { envelopeBudget } from 'loot-core/client/queries';
|
||||
|
||||
import { styles } from '../../../../style';
|
||||
import { AlignedText } from '../../../common/AlignedText';
|
||||
|
||||
@@ -3,6 +3,8 @@ import React, { memo, useMemo, useState, useEffect } from 'react';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
import { useDispatch } from 'react-redux';
|
||||
|
||||
import * as monthUtils from 'loot-core-shared/months';
|
||||
|
||||
import {
|
||||
addNotification,
|
||||
applyBudgetAction,
|
||||
@@ -16,10 +18,9 @@ import {
|
||||
pushModal,
|
||||
updateCategory,
|
||||
updateGroup,
|
||||
} from 'loot-core/src/client/actions';
|
||||
import { useSpreadsheet } from 'loot-core/src/client/SpreadsheetProvider';
|
||||
import { send, listen } from 'loot-core/src/platform/client/fetch';
|
||||
import * as monthUtils from 'loot-core/src/shared/months';
|
||||
} from 'loot-core/client/actions';
|
||||
import { useSpreadsheet } from 'loot-core/client/SpreadsheetProvider';
|
||||
import { send, listen } from 'loot-core/platform/client/fetch';
|
||||
|
||||
import { useCategories } from '../../hooks/useCategories';
|
||||
import { useGlobalPref } from '../../hooks/useGlobalPref';
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import React, { type ComponentPropsWithoutRef } from 'react';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
|
||||
import { trackingBudget } from 'loot-core/src/client/queries';
|
||||
import { trackingBudget } from 'loot-core/client/queries';
|
||||
|
||||
import { Menu } from '../../common/Menu';
|
||||
|
||||
|
||||
@@ -9,11 +9,11 @@ import React, {
|
||||
import { Trans } from 'react-i18next';
|
||||
|
||||
import { css } from '@emotion/css';
|
||||
import { evalArithmetic } from 'loot-core-shared/arithmetic';
|
||||
import * as monthUtils from 'loot-core-shared/months';
|
||||
import { integerToCurrency, amountToInteger } from 'loot-core-shared/util';
|
||||
|
||||
import { trackingBudget } from 'loot-core/src/client/queries';
|
||||
import { evalArithmetic } from 'loot-core/src/shared/arithmetic';
|
||||
import * as monthUtils from 'loot-core/src/shared/months';
|
||||
import { integerToCurrency, amountToInteger } from 'loot-core/src/shared/util';
|
||||
import { trackingBudget } from 'loot-core/client/queries';
|
||||
|
||||
import { useUndo } from '../../../hooks/useUndo';
|
||||
import { SvgCheveronDown } from '../../../icons/v1';
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
// @ts-strict-ignore
|
||||
import React, { type ReactNode, createContext, useContext } from 'react';
|
||||
|
||||
import * as monthUtils from 'loot-core/src/shared/months';
|
||||
import * as monthUtils from 'loot-core-shared/months';
|
||||
|
||||
const Context = createContext(null);
|
||||
|
||||
|
||||
@@ -3,8 +3,7 @@ import React, { useRef, useState } from 'react';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
|
||||
import { css } from '@emotion/css';
|
||||
|
||||
import * as monthUtils from 'loot-core/src/shared/months';
|
||||
import * as monthUtils from 'loot-core-shared/months';
|
||||
|
||||
import { SvgDotsHorizontalTriple } from '../../../../icons/v1';
|
||||
import { SvgArrowButtonDown1, SvgArrowButtonUp1 } from '../../../../icons/v2';
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import React, { type CSSProperties } from 'react';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
|
||||
import { trackingBudget } from 'loot-core/src/client/queries';
|
||||
import { trackingBudget } from 'loot-core/client/queries';
|
||||
|
||||
import { BudgetTotal } from './BudgetTotal';
|
||||
import { ExpenseProgress } from './ExpenseProgress';
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import React, { type CSSProperties } from 'react';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
|
||||
import { trackingBudget } from 'loot-core/src/client/queries';
|
||||
import { trackingBudget } from 'loot-core/client/queries';
|
||||
|
||||
import { BudgetTotal } from './BudgetTotal';
|
||||
import { IncomeProgress } from './IncomeProgress';
|
||||
|
||||
@@ -3,7 +3,7 @@ import { Trans, useTranslation } from 'react-i18next';
|
||||
|
||||
import { css } from '@emotion/css';
|
||||
|
||||
import { trackingBudget } from 'loot-core/src/client/queries';
|
||||
import { trackingBudget } from 'loot-core/client/queries';
|
||||
|
||||
import { theme, styles } from '../../../../style';
|
||||
import { AlignedText } from '../../../common/AlignedText';
|
||||
|
||||
@@ -2,16 +2,16 @@
|
||||
import { type CSSProperties } from 'react';
|
||||
|
||||
import { t } from 'i18next';
|
||||
|
||||
import { type useSpreadsheet } from 'loot-core/src/client/SpreadsheetProvider';
|
||||
import { send } from 'loot-core/src/platform/client/fetch';
|
||||
import * as monthUtils from 'loot-core/src/shared/months';
|
||||
import { type Handlers } from 'loot-core/src/types/handlers';
|
||||
import { type Handlers } from 'loot-core-server/types/handlers';
|
||||
import * as monthUtils from 'loot-core-shared/months';
|
||||
import {
|
||||
type CategoryEntity,
|
||||
type CategoryGroupEntity,
|
||||
} from 'loot-core/src/types/models';
|
||||
import { type SyncedPrefs } from 'loot-core/src/types/prefs';
|
||||
} from 'loot-core-shared/types/models';
|
||||
import { type SyncedPrefs } from 'loot-core-shared/types/prefs';
|
||||
|
||||
import { type useSpreadsheet } from 'loot-core/client/SpreadsheetProvider';
|
||||
import { send } from 'loot-core/platform/client/fetch';
|
||||
|
||||
import { styles, theme } from '../../style';
|
||||
import { type DropPosition } from '../sort';
|
||||
|
||||
@@ -7,8 +7,7 @@ import React, {
|
||||
import { NavLink, useMatch } from 'react-router-dom';
|
||||
|
||||
import { css } from '@emotion/css';
|
||||
|
||||
import { type CustomReportEntity } from 'loot-core/types/models/reports';
|
||||
import { type CustomReportEntity } from 'loot-core-shared/types/models/reports';
|
||||
|
||||
import { useNavigate } from '../../hooks/useNavigate';
|
||||
import { styles } from '../../style';
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import React from 'react';
|
||||
|
||||
import { type RuleConditionEntity } from 'loot-core/src/types/models';
|
||||
import { type RuleConditionEntity } from 'loot-core-shared/types/models';
|
||||
|
||||
import { View } from '../common/View';
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import React from 'react';
|
||||
|
||||
import { type RuleConditionEntity } from 'loot-core/types/models';
|
||||
import { type RuleConditionEntity } from 'loot-core-shared/types/models';
|
||||
|
||||
import { theme } from '../../style';
|
||||
import { Text } from '../common/Text';
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
import React, { useRef, useState, type CSSProperties } from 'react';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
|
||||
import { mapField, friendlyOp } from 'loot-core/src/shared/rules';
|
||||
import { integerToCurrency } from 'loot-core/src/shared/util';
|
||||
import { type RuleConditionEntity } from 'loot-core/src/types/models';
|
||||
import { mapField, friendlyOp } from 'loot-core-shared/rules';
|
||||
import { type RuleConditionEntity } from 'loot-core-shared/types/models';
|
||||
import { integerToCurrency } from 'loot-core-shared/util';
|
||||
|
||||
import { SvgDelete } from '../../icons/v0';
|
||||
import { theme } from '../../style';
|
||||
|
||||
@@ -9,10 +9,7 @@ import {
|
||||
format as formatDate,
|
||||
isValid as isDateValid,
|
||||
} from 'date-fns';
|
||||
|
||||
import { useFilters } from 'loot-core/src/client/data-hooks/filters';
|
||||
import { send } from 'loot-core/src/platform/client/fetch';
|
||||
import { getMonthYearFormat } from 'loot-core/src/shared/months';
|
||||
import { getMonthYearFormat } from 'loot-core-shared/months';
|
||||
import {
|
||||
mapField,
|
||||
deserializeField,
|
||||
@@ -20,8 +17,11 @@ import {
|
||||
unparse,
|
||||
FIELD_TYPES,
|
||||
getValidOps,
|
||||
} from 'loot-core/src/shared/rules';
|
||||
import { titleFirst } from 'loot-core/src/shared/util';
|
||||
} from 'loot-core-shared/rules';
|
||||
import { titleFirst } from 'loot-core-shared/util';
|
||||
|
||||
import { useFilters } from 'loot-core/client/data-hooks/filters';
|
||||
import { send } from 'loot-core/platform/client/fetch';
|
||||
|
||||
import { useDateFormat } from '../../hooks/useDateFormat';
|
||||
import { styles, theme } from '../../style';
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import React from 'react';
|
||||
|
||||
import { type TransactionFilterEntity } from 'loot-core/types/models';
|
||||
import { type RuleConditionEntity } from 'loot-core/types/models/rule';
|
||||
import { type TransactionFilterEntity } from 'loot-core-shared/types/models';
|
||||
import { type RuleConditionEntity } from 'loot-core-shared/types/models/rule';
|
||||
|
||||
import { Stack } from '../common/Stack';
|
||||
import { View } from '../common/View';
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
import React, { type CSSProperties } from 'react';
|
||||
|
||||
import { css } from '@emotion/css';
|
||||
|
||||
import { friendlyOp } from 'loot-core/src/shared/rules';
|
||||
import { friendlyOp } from 'loot-core-shared/rules';
|
||||
|
||||
import { theme } from '../../style';
|
||||
import { Button } from '../common/Button2';
|
||||
|
||||
@@ -1,9 +1,10 @@
|
||||
import React, { useRef, useState } from 'react';
|
||||
import { Trans, useTranslation } from 'react-i18next';
|
||||
|
||||
import { send, sendCatch } from 'loot-core/src/platform/client/fetch';
|
||||
import { type TransactionFilterEntity } from 'loot-core/types/models';
|
||||
import { type RuleConditionEntity } from 'loot-core/types/models/rule';
|
||||
import { type TransactionFilterEntity } from 'loot-core-shared/types/models';
|
||||
import { type RuleConditionEntity } from 'loot-core-shared/types/models/rule';
|
||||
|
||||
import { send, sendCatch } from 'loot-core/platform/client/fetch';
|
||||
|
||||
import { SvgExpandArrow } from '../../icons/v0';
|
||||
import { Button } from '../common/Button2';
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { type RuleConditionEntity } from 'loot-core/src/types/models';
|
||||
import { type RuleConditionEntity } from 'loot-core-shared/types/models';
|
||||
|
||||
export function subfieldFromFilter({
|
||||
field,
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { type RuleConditionEntity } from 'loot-core/src/types/models';
|
||||
import { type RuleConditionEntity } from 'loot-core-shared/types/models';
|
||||
|
||||
export function subfieldToOptions(field: string, subfield: string) {
|
||||
let setOptions: RuleConditionEntity['options'];
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { makeValue, FIELD_TYPES } from 'loot-core/src/shared/rules';
|
||||
import { type RuleConditionEntity } from 'loot-core/src/types/models';
|
||||
import { makeValue, FIELD_TYPES } from 'loot-core-shared/rules';
|
||||
import { type RuleConditionEntity } from 'loot-core-shared/types/models';
|
||||
|
||||
export function updateFilterReducer(
|
||||
state: Pick<RuleConditionEntity, 'op' | 'field' | 'value'>,
|
||||
|
||||
@@ -2,6 +2,11 @@ import React, { useState, useRef, type CSSProperties } from 'react';
|
||||
import { Trans, useTranslation } from 'react-i18next';
|
||||
import { useDispatch, useSelector } from 'react-redux';
|
||||
|
||||
import {
|
||||
isElectron,
|
||||
isNonProductionEnvironment,
|
||||
} from 'loot-core-shared/environment';
|
||||
|
||||
import {
|
||||
closeAndDownloadBudget,
|
||||
closeAndLoadBudget,
|
||||
@@ -12,10 +17,6 @@ import {
|
||||
loadBudget,
|
||||
pushModal,
|
||||
} from 'loot-core/client/actions';
|
||||
import {
|
||||
isElectron,
|
||||
isNonProductionEnvironment,
|
||||
} from 'loot-core/src/shared/environment';
|
||||
import {
|
||||
type File,
|
||||
type LocalFile,
|
||||
|
||||
@@ -5,7 +5,7 @@ import { Trans, useTranslation } from 'react-i18next';
|
||||
import {
|
||||
isNonProductionEnvironment,
|
||||
isElectron,
|
||||
} from 'loot-core/src/shared/environment';
|
||||
} from 'loot-core-shared/environment';
|
||||
|
||||
import { useActions } from '../../hooks/useActions';
|
||||
import { useGlobalPref } from '../../hooks/useGlobalPref';
|
||||
|
||||
@@ -3,9 +3,9 @@ import React, { useState } from 'react';
|
||||
import { Trans, useTranslation } from 'react-i18next';
|
||||
import { useDispatch } from 'react-redux';
|
||||
|
||||
import { createBudget } from 'loot-core/src/client/actions/budgets';
|
||||
import { loggedIn } from 'loot-core/src/client/actions/user';
|
||||
import { send } from 'loot-core/src/platform/client/fetch';
|
||||
import { createBudget } from 'loot-core/client/actions/budgets';
|
||||
import { loggedIn } from 'loot-core/client/actions/user';
|
||||
import { send } from 'loot-core/platform/client/fetch';
|
||||
|
||||
import { theme } from '../../../style';
|
||||
import { Button } from '../../common/Button2';
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
import React, { useState } from 'react';
|
||||
import { Trans, useTranslation } from 'react-i18next';
|
||||
|
||||
import { send } from 'loot-core/src/platform/client/fetch';
|
||||
import { send } from 'loot-core/platform/client/fetch';
|
||||
|
||||
import { useNavigate } from '../../../hooks/useNavigate';
|
||||
import { theme } from '../../../style';
|
||||
|
||||
@@ -4,9 +4,9 @@ import { Trans, useTranslation } from 'react-i18next';
|
||||
import { useDispatch } from 'react-redux';
|
||||
import { useParams, useSearchParams } from 'react-router-dom';
|
||||
|
||||
import { createBudget } from 'loot-core/src/client/actions/budgets';
|
||||
import { loggedIn } from 'loot-core/src/client/actions/user';
|
||||
import { send } from 'loot-core/src/platform/client/fetch';
|
||||
import { createBudget } from 'loot-core/client/actions/budgets';
|
||||
import { loggedIn } from 'loot-core/client/actions/user';
|
||||
import { send } from 'loot-core/platform/client/fetch';
|
||||
|
||||
import { AnimatedLoading } from '../../../icons/AnimatedLoading';
|
||||
import { theme } from '../../../style';
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
import React, { useEffect, useState } from 'react';
|
||||
import { useLocation } from 'react-router-dom';
|
||||
|
||||
import { send } from 'loot-core/src/platform/client/fetch';
|
||||
import { send } from 'loot-core/platform/client/fetch';
|
||||
|
||||
import { useNavigate } from '../../../hooks/useNavigate';
|
||||
import { theme } from '../../../style';
|
||||
|
||||
@@ -7,6 +7,13 @@ import React, {
|
||||
} from 'react';
|
||||
import { useDispatch, useSelector } from 'react-redux';
|
||||
|
||||
import { type Query } from 'loot-core-shared/query';
|
||||
import { isPreviewId } from 'loot-core-shared/transactions';
|
||||
import {
|
||||
type AccountEntity,
|
||||
type TransactionEntity,
|
||||
} from 'loot-core-shared/types/models';
|
||||
|
||||
import {
|
||||
collapseModals,
|
||||
getPayees,
|
||||
@@ -27,12 +34,6 @@ import {
|
||||
} from 'loot-core/client/data-hooks/transactions';
|
||||
import * as queries from 'loot-core/client/queries';
|
||||
import { listen, send } from 'loot-core/platform/client/fetch';
|
||||
import { type Query } from 'loot-core/shared/query';
|
||||
import { isPreviewId } from 'loot-core/shared/transactions';
|
||||
import {
|
||||
type AccountEntity,
|
||||
type TransactionEntity,
|
||||
} from 'loot-core/types/models';
|
||||
|
||||
import { useAccountPreviewTransactions } from '../../../hooks/useAccountPreviewTransactions';
|
||||
import { useDateFormat } from '../../../hooks/useDateFormat';
|
||||
|
||||
@@ -2,10 +2,10 @@ import React, { type CSSProperties, useCallback } from 'react';
|
||||
import { useDispatch, useSelector } from 'react-redux';
|
||||
|
||||
import { t } from 'i18next';
|
||||
import { type AccountEntity } from 'loot-core-shared/types/models';
|
||||
|
||||
import { replaceModal, syncAndDownload } from 'loot-core/src/client/actions';
|
||||
import * as queries from 'loot-core/src/client/queries';
|
||||
import { type AccountEntity } from 'loot-core/types/models';
|
||||
import { replaceModal, syncAndDownload } from 'loot-core/client/actions';
|
||||
import * as queries from 'loot-core/client/queries';
|
||||
|
||||
import { useAccounts } from '../../../hooks/useAccounts';
|
||||
import { useFailedAccounts } from '../../../hooks/useFailedAccounts';
|
||||
|
||||
@@ -4,16 +4,16 @@ import { useDispatch } from 'react-redux';
|
||||
import { css } from '@emotion/css';
|
||||
import { AutoTextSize } from 'auto-text-size';
|
||||
import { t } from 'i18next';
|
||||
import * as monthUtils from 'loot-core-shared/months';
|
||||
import { groupById, integerToCurrency } from 'loot-core-shared/util';
|
||||
import memoizeOne from 'memoize-one';
|
||||
|
||||
import { collapseModals, pushModal } from 'loot-core/client/actions';
|
||||
import { groupById, integerToCurrency } from 'loot-core/shared/util';
|
||||
import {
|
||||
envelopeBudget,
|
||||
trackingBudget,
|
||||
uncategorizedCount,
|
||||
} from 'loot-core/src/client/queries';
|
||||
import * as monthUtils from 'loot-core/src/shared/months';
|
||||
} from 'loot-core/client/queries';
|
||||
|
||||
import { useCategories } from '../../../hooks/useCategories';
|
||||
import { useFeatureFlag } from '../../../hooks/useFeatureFlag';
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import React from 'react';
|
||||
import { useParams, useSearchParams } from 'react-router-dom';
|
||||
|
||||
import * as monthUtils from 'loot-core/src/shared/months';
|
||||
import * as monthUtils from 'loot-core-shared/months';
|
||||
|
||||
import { useCategories } from '../../../hooks/useCategories';
|
||||
import { useSyncedPref } from '../../../hooks/useSyncedPref';
|
||||
|
||||
@@ -1,6 +1,10 @@
|
||||
import React, { useCallback, useEffect, useState } from 'react';
|
||||
import { useDispatch } from 'react-redux';
|
||||
|
||||
import * as monthUtils from 'loot-core-shared/months';
|
||||
import { q } from 'loot-core-shared/query';
|
||||
import { isPreviewId } from 'loot-core-shared/transactions';
|
||||
|
||||
import { getPayees } from 'loot-core/client/actions';
|
||||
import {
|
||||
useTransactions,
|
||||
@@ -8,9 +12,6 @@ import {
|
||||
} from 'loot-core/client/data-hooks/transactions';
|
||||
import * as queries from 'loot-core/client/queries';
|
||||
import { listen } from 'loot-core/platform/client/fetch';
|
||||
import * as monthUtils from 'loot-core/shared/months';
|
||||
import { q } from 'loot-core/shared/query';
|
||||
import { isPreviewId } from 'loot-core/shared/transactions';
|
||||
|
||||
import { useDateFormat } from '../../../hooks/useDateFormat';
|
||||
import { useNavigate } from '../../../hooks/useNavigate';
|
||||
|
||||
@@ -2,6 +2,8 @@
|
||||
import React, { useCallback, useEffect, useState } from 'react';
|
||||
import { useDispatch } from 'react-redux';
|
||||
|
||||
import * as monthUtils from 'loot-core-shared/months';
|
||||
|
||||
import {
|
||||
applyBudgetAction,
|
||||
collapseModals,
|
||||
@@ -17,9 +19,8 @@ import {
|
||||
updateGroup,
|
||||
sync,
|
||||
} from 'loot-core/client/actions';
|
||||
import { useSpreadsheet } from 'loot-core/src/client/SpreadsheetProvider';
|
||||
import { send, listen } from 'loot-core/src/platform/client/fetch';
|
||||
import * as monthUtils from 'loot-core/src/shared/months';
|
||||
import { useSpreadsheet } from 'loot-core/client/SpreadsheetProvider';
|
||||
import { send, listen } from 'loot-core/platform/client/fetch';
|
||||
|
||||
import { useCategories } from '../../../hooks/useCategories';
|
||||
import { useLocalPref } from '../../../hooks/useLocalPref';
|
||||
|
||||
@@ -10,12 +10,11 @@ import React, {
|
||||
} from 'react';
|
||||
|
||||
import { css } from '@emotion/css';
|
||||
|
||||
import {
|
||||
amountToCurrency,
|
||||
appendDecimals,
|
||||
currencyToAmount,
|
||||
} from 'loot-core/src/shared/util';
|
||||
} from 'loot-core-shared/util';
|
||||
|
||||
import { useMergedRefs } from '../../../hooks/useMergedRefs';
|
||||
import { useSyncedPref } from '../../../hooks/useSyncedPref';
|
||||
|
||||
@@ -17,12 +17,8 @@ import {
|
||||
isValid as isValidDate,
|
||||
} from 'date-fns';
|
||||
import { t } from 'i18next';
|
||||
|
||||
import { pushModal, setLastTransaction } from 'loot-core/client/actions';
|
||||
import { runQuery } from 'loot-core/src/client/query-helpers';
|
||||
import { send } from 'loot-core/src/platform/client/fetch';
|
||||
import * as monthUtils from 'loot-core/src/shared/months';
|
||||
import { q } from 'loot-core/src/shared/query';
|
||||
import * as monthUtils from 'loot-core-shared/months';
|
||||
import { q } from 'loot-core-shared/query';
|
||||
import {
|
||||
ungroupTransactions,
|
||||
updateTransaction,
|
||||
@@ -31,7 +27,7 @@ import {
|
||||
addSplitTransaction,
|
||||
deleteTransaction,
|
||||
makeChild,
|
||||
} from 'loot-core/src/shared/transactions';
|
||||
} from 'loot-core-shared/transactions';
|
||||
import {
|
||||
titleFirst,
|
||||
integerToCurrency,
|
||||
@@ -40,7 +36,11 @@ import {
|
||||
getChangedValues,
|
||||
diffItems,
|
||||
groupById,
|
||||
} from 'loot-core/src/shared/util';
|
||||
} from 'loot-core-shared/util';
|
||||
|
||||
import { pushModal, setLastTransaction } from 'loot-core/client/actions';
|
||||
import { runQuery } from 'loot-core/client/query-helpers';
|
||||
import { send } from 'loot-core/platform/client/fetch';
|
||||
|
||||
import { useAccounts } from '../../../hooks/useAccounts';
|
||||
import { useCategories } from '../../../hooks/useCategories';
|
||||
|
||||
@@ -9,11 +9,11 @@ import { ListBox, Section, Header, Collection } from 'react-aria-components';
|
||||
import { useDispatch } from 'react-redux';
|
||||
|
||||
import { t } from 'i18next';
|
||||
import * as monthUtils from 'loot-core-shared/months';
|
||||
import { isPreviewId } from 'loot-core-shared/transactions';
|
||||
import { groupById, integerToCurrency } from 'loot-core-shared/util';
|
||||
|
||||
import { setNotificationInset } from 'loot-core/client/actions';
|
||||
import { groupById, integerToCurrency } from 'loot-core/shared/util';
|
||||
import * as monthUtils from 'loot-core/src/shared/months';
|
||||
import { isPreviewId } from 'loot-core/src/shared/transactions';
|
||||
|
||||
import { useAccounts } from '../../../hooks/useAccounts';
|
||||
import { useCategories } from '../../../hooks/useCategories';
|
||||
|
||||
@@ -11,10 +11,9 @@ import {
|
||||
usePress,
|
||||
useLongPress,
|
||||
} from '@react-aria/interactions';
|
||||
|
||||
import { isPreviewId } from 'loot-core/src/shared/transactions';
|
||||
import { integerToCurrency } from 'loot-core/src/shared/util';
|
||||
import { type TransactionEntity } from 'loot-core/types/models';
|
||||
import { isPreviewId } from 'loot-core-shared/transactions';
|
||||
import { type TransactionEntity } from 'loot-core-shared/types/models';
|
||||
import { integerToCurrency } from 'loot-core-shared/util';
|
||||
|
||||
import { useAccount } from '../../../hooks/useAccount';
|
||||
import { useCategories } from '../../../hooks/useCategories';
|
||||
|
||||
@@ -2,7 +2,7 @@ import {
|
||||
type AccountEntity,
|
||||
type PayeeEntity,
|
||||
type TransactionEntity,
|
||||
} from 'loot-core/types/models';
|
||||
} from 'loot-core-shared/types/models';
|
||||
|
||||
type GetPrettyPayeeProps = {
|
||||
transaction?: TransactionEntity;
|
||||
|
||||
@@ -7,7 +7,7 @@ import {
|
||||
} from 'react';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
|
||||
import { type AccountEntity } from 'loot-core/types/models';
|
||||
import { type AccountEntity } from 'loot-core-shared/types/models';
|
||||
|
||||
import { useAccount } from '../../hooks/useAccount';
|
||||
import { useAccounts } from '../../hooks/useAccounts';
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
import React, { type ComponentPropsWithoutRef } from 'react';
|
||||
|
||||
import { t } from 'i18next';
|
||||
|
||||
import * as monthUtils from 'loot-core/src/shared/months';
|
||||
import * as monthUtils from 'loot-core-shared/months';
|
||||
|
||||
import { theme } from '../../style';
|
||||
import { CategoryAutocomplete } from '../autocomplete/CategoryAutocomplete';
|
||||
|
||||
@@ -7,8 +7,7 @@ import React, {
|
||||
} from 'react';
|
||||
|
||||
import { t } from 'i18next';
|
||||
|
||||
import { type CategoryGroupEntity } from 'loot-core/src/types/models';
|
||||
import { type CategoryGroupEntity } from 'loot-core-shared/types/models';
|
||||
|
||||
import { useCategories } from '../../hooks/useCategories';
|
||||
import { useNotes } from '../../hooks/useNotes';
|
||||
|
||||
@@ -2,8 +2,7 @@
|
||||
import React, { useRef, useState, type CSSProperties } from 'react';
|
||||
|
||||
import { t } from 'i18next';
|
||||
|
||||
import { type CategoryEntity } from 'loot-core/src/types/models';
|
||||
import { type CategoryEntity } from 'loot-core-shared/types/models';
|
||||
|
||||
import { useCategory } from '../../hooks/useCategory';
|
||||
import { useCategoryGroup } from '../../hooks/useCategoryGroup';
|
||||
|
||||
@@ -4,13 +4,14 @@ import { Form } from 'react-aria-components';
|
||||
import { useTranslation } from 'react-i18next'; // Import useTranslation
|
||||
import { useDispatch } from 'react-redux';
|
||||
|
||||
import { type AccountEntity } from 'loot-core-shared/types/models';
|
||||
import { integerToCurrency } from 'loot-core-shared/util';
|
||||
|
||||
import {
|
||||
closeAccount,
|
||||
forceCloseAccount,
|
||||
pushModal,
|
||||
} from 'loot-core/client/actions';
|
||||
import { integerToCurrency } from 'loot-core/src/shared/util';
|
||||
import { type AccountEntity } from 'loot-core/src/types/models';
|
||||
|
||||
import { useAccounts } from '../../hooks/useAccounts';
|
||||
import { useCategories } from '../../hooks/useCategories';
|
||||
|
||||
@@ -2,8 +2,9 @@ import React, { useCallback, useMemo, useState } from 'react';
|
||||
import { Trans, useTranslation } from 'react-i18next';
|
||||
import { useDispatch } from 'react-redux';
|
||||
|
||||
import { type CategoryEntity } from 'loot-core-shared/types/models';
|
||||
|
||||
import { pushModal } from 'loot-core/client/actions';
|
||||
import { type CategoryEntity } from 'loot-core/src/types/models';
|
||||
|
||||
import { useCategories } from '../../hooks/useCategories';
|
||||
import { styles } from '../../style';
|
||||
|
||||
@@ -4,7 +4,7 @@ import { useTranslation } from 'react-i18next';
|
||||
import { useDispatch } from 'react-redux';
|
||||
|
||||
import { pushModal } from 'loot-core/client/actions';
|
||||
import { send } from 'loot-core/src/platform/client/fetch';
|
||||
import { send } from 'loot-core/platform/client/fetch';
|
||||
|
||||
import { authorizeBank } from '../../gocardless';
|
||||
import { useGoCardlessStatus } from '../../hooks/useGoCardlessStatus';
|
||||
|
||||
@@ -5,10 +5,10 @@ import { useDispatch } from 'react-redux';
|
||||
|
||||
import { css } from '@emotion/css';
|
||||
import { t } from 'i18next';
|
||||
import { getCreateKeyError } from 'loot-core-shared/errors';
|
||||
|
||||
import { loadAllFiles, loadGlobalPrefs, sync } from 'loot-core/client/actions';
|
||||
import { send } from 'loot-core/src/platform/client/fetch';
|
||||
import { getCreateKeyError } from 'loot-core/src/shared/errors';
|
||||
import { send } from 'loot-core/platform/client/fetch';
|
||||
|
||||
import { styles, theme } from '../../style';
|
||||
import { ButtonWithLoading } from '../common/Button2';
|
||||
|
||||
@@ -4,9 +4,9 @@ import { Form } from 'react-aria-components';
|
||||
import { useDispatch } from 'react-redux';
|
||||
|
||||
import { t } from 'i18next';
|
||||
import { toRelaxedNumber } from 'loot-core-shared/util';
|
||||
|
||||
import { closeModal, createAccount } from 'loot-core/client/actions';
|
||||
import { toRelaxedNumber } from 'loot-core/src/shared/util';
|
||||
|
||||
import * as useAccounts from '../../hooks/useAccounts';
|
||||
import { useNavigate } from '../../hooks/useNavigate';
|
||||
|
||||
@@ -7,9 +7,8 @@ import React, {
|
||||
|
||||
import { parseISO, format as formatDate, parse as parseDate } from 'date-fns';
|
||||
import { t } from 'i18next';
|
||||
|
||||
import { currentDay, dayFromDate } from 'loot-core/src/shared/months';
|
||||
import { amountToInteger } from 'loot-core/src/shared/util';
|
||||
import { currentDay, dayFromDate } from 'loot-core-shared/months';
|
||||
import { amountToInteger } from 'loot-core-shared/util';
|
||||
|
||||
import { useDateFormat } from '../../hooks/useDateFormat';
|
||||
import { theme } from '../../style';
|
||||
|
||||
@@ -3,17 +3,8 @@ import { useDispatch } from 'react-redux';
|
||||
|
||||
import { css } from '@emotion/css';
|
||||
import { t } from 'i18next';
|
||||
import { v4 as uuid } from 'uuid';
|
||||
|
||||
import {
|
||||
initiallyLoadPayees,
|
||||
setUndoEnabled,
|
||||
} from 'loot-core/src/client/actions/queries';
|
||||
import { useSchedules } from 'loot-core/src/client/data-hooks/schedules';
|
||||
import { runQuery } from 'loot-core/src/client/query-helpers';
|
||||
import { send } from 'loot-core/src/platform/client/fetch';
|
||||
import * as monthUtils from 'loot-core/src/shared/months';
|
||||
import { q } from 'loot-core/src/shared/query';
|
||||
import * as monthUtils from 'loot-core-shared/months';
|
||||
import { q } from 'loot-core-shared/query';
|
||||
import {
|
||||
mapField,
|
||||
friendlyOp,
|
||||
@@ -25,12 +16,21 @@ import {
|
||||
ALLOCATION_METHODS,
|
||||
isValidOp,
|
||||
getValidOps,
|
||||
} from 'loot-core/src/shared/rules';
|
||||
} from 'loot-core-shared/rules';
|
||||
import {
|
||||
integerToCurrency,
|
||||
integerToAmount,
|
||||
amountToInteger,
|
||||
} from 'loot-core/src/shared/util';
|
||||
} from 'loot-core-shared/util';
|
||||
import { v4 as uuid } from 'uuid';
|
||||
|
||||
import {
|
||||
initiallyLoadPayees,
|
||||
setUndoEnabled,
|
||||
} from 'loot-core/client/actions/queries';
|
||||
import { useSchedules } from 'loot-core/client/data-hooks/schedules';
|
||||
import { runQuery } from 'loot-core/client/query-helpers';
|
||||
import { send } from 'loot-core/platform/client/fetch';
|
||||
|
||||
import { useDateFormat } from '../../hooks/useDateFormat';
|
||||
import { useFeatureFlag } from '../../hooks/useFeatureFlag';
|
||||
|
||||
@@ -6,9 +6,9 @@ import React, {
|
||||
} from 'react';
|
||||
|
||||
import { t } from 'i18next';
|
||||
import { amountToInteger, integerToAmount } from 'loot-core-shared/util';
|
||||
|
||||
import { envelopeBudget } from 'loot-core/client/queries';
|
||||
import { amountToInteger, integerToAmount } from 'loot-core/shared/util';
|
||||
|
||||
import { useCategory } from '../../hooks/useCategory';
|
||||
import { theme, styles } from '../../style';
|
||||
|
||||
@@ -3,8 +3,7 @@ import React, { useState, type CSSProperties } from 'react';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
|
||||
import { css } from '@emotion/css';
|
||||
|
||||
import * as monthUtils from 'loot-core/src/shared/months';
|
||||
import * as monthUtils from 'loot-core-shared/months';
|
||||
|
||||
import { useNotes } from '../../hooks/useNotes';
|
||||
import { useUndo } from '../../hooks/useUndo';
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user