diff --git a/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-import-csv-file-twice-1-chromium-linux.png b/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-import-csv-file-twice-1-chromium-linux.png index b0b41c6da83..3839417cd61 100644 Binary files a/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-import-csv-file-twice-1-chromium-linux.png and b/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-import-csv-file-twice-1-chromium-linux.png differ diff --git a/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-import-csv-file-twice-2-chromium-linux.png b/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-import-csv-file-twice-2-chromium-linux.png index 212fc2772e6..901dcfdcaf7 100644 Binary files a/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-import-csv-file-twice-2-chromium-linux.png and b/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-import-csv-file-twice-2-chromium-linux.png differ diff --git a/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-import-csv-file-twice-3-chromium-linux.png b/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-import-csv-file-twice-3-chromium-linux.png index 5768c3caae2..26a250f526c 100644 Binary files a/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-import-csv-file-twice-3-chromium-linux.png and b/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-import-csv-file-twice-3-chromium-linux.png differ diff --git a/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-imports-transactions-from-a-CSV-file-1-chromium-linux.png b/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-imports-transactions-from-a-CSV-file-1-chromium-linux.png index f44ea97dd8b..e7a013dbc19 100644 Binary files a/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-imports-transactions-from-a-CSV-file-1-chromium-linux.png and b/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-imports-transactions-from-a-CSV-file-1-chromium-linux.png differ diff --git a/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-imports-transactions-from-a-CSV-file-2-chromium-linux.png b/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-imports-transactions-from-a-CSV-file-2-chromium-linux.png index 696614b2d6f..38b7a93c49a 100644 Binary files a/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-imports-transactions-from-a-CSV-file-2-chromium-linux.png and b/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-imports-transactions-from-a-CSV-file-2-chromium-linux.png differ diff --git a/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-imports-transactions-from-a-CSV-file-3-chromium-linux.png b/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-imports-transactions-from-a-CSV-file-3-chromium-linux.png index 39de13be31c..f12ba262c8e 100644 Binary files a/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-imports-transactions-from-a-CSV-file-3-chromium-linux.png and b/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-imports-transactions-from-a-CSV-file-3-chromium-linux.png differ diff --git a/packages/desktop-client/globals.d.ts b/packages/desktop-client/globals.d.ts index ce1ae7b7547..d05b3b39970 100644 --- a/packages/desktop-client/globals.d.ts +++ b/packages/desktop-client/globals.d.ts @@ -1,2 +1,9 @@ +import { type CSSObject } from '@emotion/css/dist/declarations/src/create-instance'; + // Allow images to be imported declare module '*.png'; + +declare module 'react' { + // eslint-disable-next-line @typescript-eslint/consistent-type-definitions, @typescript-eslint/no-empty-object-type + interface CSSProperties extends CSSObject {} +} diff --git a/packages/desktop-client/package.json b/packages/desktop-client/package.json index 0c487c4c95c..bc81bc77bad 100644 --- a/packages/desktop-client/package.json +++ b/packages/desktop-client/package.json @@ -6,6 +6,7 @@ "build" ], "devDependencies": { + "@emotion/css": "^11.13.4", "@fontsource/redacted-script": "^5.0.21", "@juggle/resize-observer": "^3.4.0", "@playwright/test": "1.41.1", @@ -36,7 +37,6 @@ "debounce": "^1.2.1", "downshift": "7.6.2", "focus-visible": "^4.1.5", - "glamor": "^2.20.40", "i18next": "^23.11.5", "i18next-parser": "^9.0.0", "i18next-resources-to-backend": "^1.2.1", diff --git a/packages/desktop-client/src/components/AnimatedRefresh.tsx b/packages/desktop-client/src/components/AnimatedRefresh.tsx index e94e3a319b1..b9273bf9556 100644 --- a/packages/desktop-client/src/components/AnimatedRefresh.tsx +++ b/packages/desktop-client/src/components/AnimatedRefresh.tsx @@ -1,10 +1,9 @@ // @ts-strict-ignore -import React from 'react'; +import React, { type CSSProperties } from 'react'; -import { keyframes } from 'glamor'; +import { keyframes } from '@emotion/css'; import { SvgRefresh } from '../icons/v1'; -import { type CSSProperties } from '../style'; import { View } from './common/View'; diff --git a/packages/desktop-client/src/components/AppBackground.tsx b/packages/desktop-client/src/components/AppBackground.tsx index 0a1bfc0ac3a..9d57bafdde8 100644 --- a/packages/desktop-client/src/components/AppBackground.tsx +++ b/packages/desktop-client/src/components/AppBackground.tsx @@ -2,7 +2,7 @@ import React from 'react'; import { useSelector } from 'react-redux'; import { useTransition, animated } from 'react-spring'; -import { css } from 'glamor'; +import { css } from '@emotion/css'; import { AnimatedLoading } from '../icons/AnimatedLoading'; import { theme } from '../style'; @@ -33,7 +33,7 @@ export function AppBackground({ isLoading }: AppBackgroundProps) { transitions((style, item) => ( {loadingText} diff --git a/packages/desktop-client/src/components/FixedSizeList.tsx b/packages/desktop-client/src/components/FixedSizeList.tsx index b2257a0a099..0baf528d125 100644 --- a/packages/desktop-client/src/components/FixedSizeList.tsx +++ b/packages/desktop-client/src/components/FixedSizeList.tsx @@ -6,12 +6,11 @@ import { type Ref, type MutableRefObject, type UIEvent, + type CSSProperties, } from 'react'; import memoizeOne from 'memoize-one'; -import { type CSSProperties } from '../style'; - import { View } from './common/View'; const IS_SCROLLING_DEBOUNCE_INTERVAL = 150; diff --git a/packages/desktop-client/src/components/LoggedInUser.tsx b/packages/desktop-client/src/components/LoggedInUser.tsx index 0bc04078e6d..ec7df311bbf 100644 --- a/packages/desktop-client/src/components/LoggedInUser.tsx +++ b/packages/desktop-client/src/components/LoggedInUser.tsx @@ -1,12 +1,12 @@ // @ts-strict-ignore -import React, { useState, useEffect, useRef } from 'react'; +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 { useActions } from '../hooks/useActions'; -import { theme, styles, type CSSProperties } from '../style'; +import { theme, styles } from '../style'; import { Button } from './common/Button2'; import { Menu } from './common/Menu'; diff --git a/packages/desktop-client/src/components/ManageRules.tsx b/packages/desktop-client/src/components/ManageRules.tsx index e561fa700fe..f3eb583005a 100644 --- a/packages/desktop-client/src/components/ManageRules.tsx +++ b/packages/desktop-client/src/components/ManageRules.tsx @@ -117,17 +117,14 @@ export function ManageRules({ const { list: categories } = useCategories(); const payees = usePayees(); const accounts = useAccounts(); - const state = { - payees, - accounts, - schedules, - }; const filterData = useMemo( () => ({ - ...state, + payees, + accounts, + schedules, categories, }), - [state, categories], + [payees, accounts, schedules, categories], ); const filteredRules = useMemo( diff --git a/packages/desktop-client/src/components/Notes.tsx b/packages/desktop-client/src/components/Notes.tsx index 06dd4c5ff31..332b2c68064 100644 --- a/packages/desktop-client/src/components/Notes.tsx +++ b/packages/desktop-client/src/components/Notes.tsx @@ -1,12 +1,12 @@ // @ts-strict-ignore -import React, { useEffect, useRef } from 'react'; +import React, { useEffect, useRef, type CSSProperties } from 'react'; import ReactMarkdown from 'react-markdown'; -import { css } from 'glamor'; +import { css } from '@emotion/css'; import remarkGfm from 'remark-gfm'; import { useResponsive } from '../ResponsiveProvider'; -import { type CSSProperties, theme } from '../style'; +import { theme } from '../style'; import { remarkBreaks, sequentialNewlinesPlugin } from '../util/markdown'; import { Text } from './common/Text'; @@ -110,7 +110,7 @@ export function Notes({ return editable ? (