From 9915f05f731cb31f6282b27db11c99fc18b6ce13 Mon Sep 17 00:00:00 2001 From: Athou Date: Fri, 29 Nov 2024 14:05:10 +0100 Subject: [PATCH] remove lingui warnings --- commafeed-client/package-lock.json | 28 +------------------ commafeed-client/package.json | 2 +- commafeed-client/src/app/constants.ts | 2 +- commafeed-client/src/app/user/slice.ts | 2 +- commafeed-client/src/components/Alert.tsx | 2 +- .../src/components/AnnouncementDialog.tsx | 2 +- .../src/components/KeyboardShortcutsHelp.tsx | 2 +- .../src/components/RelativeDate.tsx | 2 +- .../src/components/admin/UserEdit.tsx | 2 +- .../src/components/content/FeedEntries.tsx | 2 +- .../content/FeedEntryContextMenu.tsx | 2 +- .../components/content/FeedEntryFooter.tsx | 2 +- .../src/components/content/ShareButtons.tsx | 2 +- .../components/content/add/AddCategory.tsx | 3 +- .../components/content/add/CategorySelect.tsx | 2 +- .../src/components/content/add/ImportOpml.tsx | 3 +- .../src/components/content/add/Subscribe.tsx | 2 +- .../content/header/OpenExternalLink.tsx | 2 +- .../src/components/content/header/Star.tsx | 2 +- .../src/components/header/Header.tsx | 2 +- .../components/header/MarkAllAsReadButton.tsx | 3 +- .../src/components/header/ProfileMenu.tsx | 2 +- .../settings/CustomCodeSettings.tsx | 2 +- .../components/settings/DisplaySettings.tsx | 3 +- .../components/settings/ProfileSettings.tsx | 3 +- .../src/components/sidebar/Tree.tsx | 2 +- .../src/components/sidebar/TreeSearch.tsx | 3 +- commafeed-client/src/hooks/useAppLoading.ts | 2 +- commafeed-client/src/pages/ErrorPage.tsx | 2 +- commafeed-client/src/pages/WelcomePage.tsx | 2 +- .../src/pages/admin/AdminUsersPage.tsx | 2 +- commafeed-client/src/pages/app/AboutPage.tsx | 3 +- commafeed-client/src/pages/app/AddPage.tsx | 2 +- .../src/pages/app/CategoryDetailsPage.tsx | 2 +- commafeed-client/src/pages/app/DonatePage.tsx | 2 +- .../src/pages/app/FeedDetailsPage.tsx | 2 +- .../src/pages/app/FeedEntriesPage.tsx | 2 +- commafeed-client/src/pages/app/Layout.tsx | 2 +- .../src/pages/app/SettingsPage.tsx | 2 +- .../src/pages/app/TagDetailsPage.tsx | 2 +- commafeed-client/src/pages/auth/LoginPage.tsx | 3 +- .../src/pages/auth/PasswordRecoveryPage.tsx | 3 +- .../src/pages/auth/RegistrationPage.tsx | 3 +- commafeed-client/vite.config.ts | 3 +- 44 files changed, 54 insertions(+), 71 deletions(-) diff --git a/commafeed-client/package-lock.json b/commafeed-client/package-lock.json index a52c9764..16880324 100644 --- a/commafeed-client/package-lock.json +++ b/commafeed-client/package-lock.json @@ -11,7 +11,6 @@ "@emotion/react": "^11.13.5", "@fontsource/open-sans": "^5.1.0", "@lingui/core": "^5.0.0", - "@lingui/macro": "^5.0.0", "@lingui/react": "^5.0.0", "@mantine/core": "^7.14.3", "@mantine/form": "^7.14.3", @@ -49,6 +48,7 @@ }, "devDependencies": { "@biomejs/biome": "^1.9.4", + "@lingui/babel-plugin-lingui-macro": "^5.0.0", "@lingui/cli": "^5.0.0", "@lingui/vite-plugin": "^5.0.0", "@types/mousetrap": "^1.6.15", @@ -1351,7 +1351,6 @@ "resolved": "https://registry.npmjs.org/@lingui/babel-plugin-lingui-macro/-/babel-plugin-lingui-macro-5.0.0.tgz", "integrity": "sha512-zpyugLESyV5h2nbBLw/Ugz0IdsgcQyRmQrVkPMzl3Ngl8EmEkr3nhRyIDM695Isbf32ogm7w9nldKSxB+WZPdQ==", "devOptional": true, - "license": "MIT", "dependencies": { "@babel/core": "^7.20.12", "@babel/runtime": "^7.20.13", @@ -1526,31 +1525,6 @@ "node": ">=20.0.0" } }, - "node_modules/@lingui/macro": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/@lingui/macro/-/macro-5.0.0.tgz", - "integrity": "sha512-FIK8pvtLLFlvV2+sbPrbUO57+sRWEKhsAcdXNZlthhze3daZfYi1dbSE4WpVd0KpTi0raInv7bCjjFSDeHyaRg==", - "license": "MIT", - "dependencies": { - "@lingui/core": "5.0.0", - "@lingui/react": "5.0.0" - }, - "engines": { - "node": ">=20.0.0" - }, - "peerDependencies": { - "@lingui/babel-plugin-lingui-macro": "4.11.2", - "babel-plugin-macros": "2 || 3" - }, - "peerDependenciesMeta": { - "@lingui/babel-plugin-lingui-macro": { - "optional": true - }, - "babel-plugin-macros": { - "optional": true - } - } - }, "node_modules/@lingui/message-utils": { "version": "5.0.0", "resolved": "https://registry.npmjs.org/@lingui/message-utils/-/message-utils-5.0.0.tgz", diff --git a/commafeed-client/package.json b/commafeed-client/package.json index ea1b48c3..80b8e6cc 100644 --- a/commafeed-client/package.json +++ b/commafeed-client/package.json @@ -18,7 +18,6 @@ "@emotion/react": "^11.13.5", "@fontsource/open-sans": "^5.1.0", "@lingui/core": "^5.0.0", - "@lingui/macro": "^5.0.0", "@lingui/react": "^5.0.0", "@mantine/core": "^7.14.3", "@mantine/form": "^7.14.3", @@ -56,6 +55,7 @@ }, "devDependencies": { "@biomejs/biome": "^1.9.4", + "@lingui/babel-plugin-lingui-macro": "^5.0.0", "@lingui/cli": "^5.0.0", "@lingui/vite-plugin": "^5.0.0", "@types/mousetrap": "^1.6.15", diff --git a/commafeed-client/src/app/constants.ts b/commafeed-client/src/app/constants.ts index e43bbc59..49fce56e 100644 --- a/commafeed-client/src/app/constants.ts +++ b/commafeed-client/src/app/constants.ts @@ -1,4 +1,4 @@ -import { t } from "@lingui/macro" +import { t } from "@lingui/core/macro" import type { IconType } from "react-icons" import { FaAt } from "react-icons/fa" import { SiBuffer, SiFacebook, SiGmail, SiInstapaper, SiPocket, SiTumblr, SiX } from "react-icons/si" diff --git a/commafeed-client/src/app/user/slice.ts b/commafeed-client/src/app/user/slice.ts index 207060d6..062412d2 100644 --- a/commafeed-client/src/app/user/slice.ts +++ b/commafeed-client/src/app/user/slice.ts @@ -1,4 +1,4 @@ -import { t } from "@lingui/macro" +import { t } from "@lingui/core/macro" import { showNotification } from "@mantine/notifications" import { type PayloadAction, createSlice, isAnyOf } from "@reduxjs/toolkit" import type { LocalSettings, Settings, UserModel, ViewMode } from "app/types" diff --git a/commafeed-client/src/components/Alert.tsx b/commafeed-client/src/components/Alert.tsx index 015b59ea..6dba6b83 100644 --- a/commafeed-client/src/components/Alert.tsx +++ b/commafeed-client/src/components/Alert.tsx @@ -1,4 +1,4 @@ -import { Trans } from "@lingui/macro" +import { Trans } from "@lingui/react/macro" import { Box, Alert as MantineAlert } from "@mantine/core" import { Fragment } from "react" import { TbAlertCircle, TbAlertTriangle, TbCircleCheck } from "react-icons/tb" diff --git a/commafeed-client/src/components/AnnouncementDialog.tsx b/commafeed-client/src/components/AnnouncementDialog.tsx index bb7ba486..0458b578 100644 --- a/commafeed-client/src/components/AnnouncementDialog.tsx +++ b/commafeed-client/src/components/AnnouncementDialog.tsx @@ -1,4 +1,4 @@ -import { Trans } from "@lingui/macro" +import { Trans } from "@lingui/react/macro" import { Box, Dialog, Text } from "@mantine/core" import { useAppDispatch, useAppSelector } from "app/store" import { setAnnouncementHash } from "app/user/slice" diff --git a/commafeed-client/src/components/KeyboardShortcutsHelp.tsx b/commafeed-client/src/components/KeyboardShortcutsHelp.tsx index 368328d6..be8ecc95 100644 --- a/commafeed-client/src/components/KeyboardShortcutsHelp.tsx +++ b/commafeed-client/src/components/KeyboardShortcutsHelp.tsx @@ -1,4 +1,4 @@ -import { Trans } from "@lingui/macro" +import { Trans } from "@lingui/react/macro" import { Anchor, Box, Kbd, Stack, Table } from "@mantine/core" import { useOs } from "@mantine/hooks" import { Constants } from "app/constants" diff --git a/commafeed-client/src/components/RelativeDate.tsx b/commafeed-client/src/components/RelativeDate.tsx index a08236e0..6fefcf24 100644 --- a/commafeed-client/src/components/RelativeDate.tsx +++ b/commafeed-client/src/components/RelativeDate.tsx @@ -1,4 +1,4 @@ -import { Trans } from "@lingui/macro" +import { Trans } from "@lingui/react/macro" import { Tooltip } from "@mantine/core" import { Constants } from "app/constants" import dayjs from "dayjs" diff --git a/commafeed-client/src/components/admin/UserEdit.tsx b/commafeed-client/src/components/admin/UserEdit.tsx index f10014f2..d1489d45 100644 --- a/commafeed-client/src/components/admin/UserEdit.tsx +++ b/commafeed-client/src/components/admin/UserEdit.tsx @@ -1,4 +1,4 @@ -import { Trans } from "@lingui/macro" +import { Trans } from "@lingui/react/macro" import { Box, Button, Checkbox, Group, PasswordInput, Stack, TextInput } from "@mantine/core" import { useForm } from "@mantine/form" import { client, errorToStrings } from "app/client" diff --git a/commafeed-client/src/components/content/FeedEntries.tsx b/commafeed-client/src/components/content/FeedEntries.tsx index 76bb909b..e572a9d4 100644 --- a/commafeed-client/src/components/content/FeedEntries.tsx +++ b/commafeed-client/src/components/content/FeedEntries.tsx @@ -1,4 +1,4 @@ -import { Trans } from "@lingui/macro" +import { Trans } from "@lingui/react/macro" import { Box } from "@mantine/core" import { openModal } from "@mantine/modals" import { Constants } from "app/constants" diff --git a/commafeed-client/src/components/content/FeedEntryContextMenu.tsx b/commafeed-client/src/components/content/FeedEntryContextMenu.tsx index 0e9be997..73b9f921 100644 --- a/commafeed-client/src/components/content/FeedEntryContextMenu.tsx +++ b/commafeed-client/src/components/content/FeedEntryContextMenu.tsx @@ -1,4 +1,4 @@ -import { Trans } from "@lingui/macro" +import { Trans } from "@lingui/react/macro" import { Group } from "@mantine/core" import { Constants } from "app/constants" import { markEntriesUpToEntry, markEntry, starEntry } from "app/entries/thunks" diff --git a/commafeed-client/src/components/content/FeedEntryFooter.tsx b/commafeed-client/src/components/content/FeedEntryFooter.tsx index b330f211..ad11883b 100644 --- a/commafeed-client/src/components/content/FeedEntryFooter.tsx +++ b/commafeed-client/src/components/content/FeedEntryFooter.tsx @@ -1,4 +1,4 @@ -import { msg } from "@lingui/macro" +import { msg } from "@lingui/core/macro" import { useLingui } from "@lingui/react" import { Group, Indicator, Popover, TagsInput } from "@mantine/core" import { markEntriesUpToEntry, markEntry, starEntry, tagEntry } from "app/entries/thunks" diff --git a/commafeed-client/src/components/content/ShareButtons.tsx b/commafeed-client/src/components/content/ShareButtons.tsx index aa933e85..752836af 100644 --- a/commafeed-client/src/components/content/ShareButtons.tsx +++ b/commafeed-client/src/components/content/ShareButtons.tsx @@ -1,4 +1,4 @@ -import { Trans } from "@lingui/macro" +import { Trans } from "@lingui/react/macro" import { ActionIcon, Box, CopyButton, Divider, SimpleGrid } from "@mantine/core" import { Constants } from "app/constants" import { useAppSelector } from "app/store" diff --git a/commafeed-client/src/components/content/add/AddCategory.tsx b/commafeed-client/src/components/content/add/AddCategory.tsx index 0588ffd8..f5afb853 100644 --- a/commafeed-client/src/components/content/add/AddCategory.tsx +++ b/commafeed-client/src/components/content/add/AddCategory.tsx @@ -1,5 +1,6 @@ -import { Trans, msg } from "@lingui/macro" +import { msg } from "@lingui/core/macro" import { useLingui } from "@lingui/react" +import { Trans } from "@lingui/react/macro" import { Box, Button, Group, Stack, TextInput } from "@mantine/core" import { useForm } from "@mantine/form" import { client, errorToStrings } from "app/client" diff --git a/commafeed-client/src/components/content/add/CategorySelect.tsx b/commafeed-client/src/components/content/add/CategorySelect.tsx index a6a653a2..62ee6bd0 100644 --- a/commafeed-client/src/components/content/add/CategorySelect.tsx +++ b/commafeed-client/src/components/content/add/CategorySelect.tsx @@ -1,4 +1,4 @@ -import { msg } from "@lingui/macro" +import { msg } from "@lingui/core/macro" import { useLingui } from "@lingui/react" import { Select, type SelectProps } from "@mantine/core" import type { ComboboxItem } from "@mantine/core/lib/components/Combobox/Combobox.types" diff --git a/commafeed-client/src/components/content/add/ImportOpml.tsx b/commafeed-client/src/components/content/add/ImportOpml.tsx index 4f416e4e..57bc06dc 100644 --- a/commafeed-client/src/components/content/add/ImportOpml.tsx +++ b/commafeed-client/src/components/content/add/ImportOpml.tsx @@ -1,5 +1,6 @@ -import { Trans, msg } from "@lingui/macro" +import { msg } from "@lingui/core/macro" import { useLingui } from "@lingui/react" +import { Trans } from "@lingui/react/macro" import { Box, Button, FileInput, Group, Stack } from "@mantine/core" import { isNotEmpty, useForm } from "@mantine/form" import { client, errorToStrings } from "app/client" diff --git a/commafeed-client/src/components/content/add/Subscribe.tsx b/commafeed-client/src/components/content/add/Subscribe.tsx index cff1c0be..0c854b0a 100644 --- a/commafeed-client/src/components/content/add/Subscribe.tsx +++ b/commafeed-client/src/components/content/add/Subscribe.tsx @@ -1,4 +1,4 @@ -import { Trans } from "@lingui/macro" +import { Trans } from "@lingui/react/macro" import { Box, Button, Group, Stack, Stepper, TextInput } from "@mantine/core" import { useForm } from "@mantine/form" import { client, errorToStrings } from "app/client" diff --git a/commafeed-client/src/components/content/header/OpenExternalLink.tsx b/commafeed-client/src/components/content/header/OpenExternalLink.tsx index c1c006b9..506ed1eb 100644 --- a/commafeed-client/src/components/content/header/OpenExternalLink.tsx +++ b/commafeed-client/src/components/content/header/OpenExternalLink.tsx @@ -1,4 +1,4 @@ -import { Trans } from "@lingui/macro" +import { Trans } from "@lingui/react/macro" import { ActionIcon, Anchor, Tooltip } from "@mantine/core" import { Constants } from "app/constants" import { markEntry } from "app/entries/thunks" diff --git a/commafeed-client/src/components/content/header/Star.tsx b/commafeed-client/src/components/content/header/Star.tsx index 247ed3ba..b63aea0d 100644 --- a/commafeed-client/src/components/content/header/Star.tsx +++ b/commafeed-client/src/components/content/header/Star.tsx @@ -1,4 +1,4 @@ -import { Trans } from "@lingui/macro" +import { Trans } from "@lingui/react/macro" import { ActionIcon, Tooltip } from "@mantine/core" import { Constants } from "app/constants" import { starEntry } from "app/entries/thunks" diff --git a/commafeed-client/src/components/header/Header.tsx b/commafeed-client/src/components/header/Header.tsx index 150b52e2..26e1f8aa 100644 --- a/commafeed-client/src/components/header/Header.tsx +++ b/commafeed-client/src/components/header/Header.tsx @@ -1,4 +1,4 @@ -import { msg } from "@lingui/macro" +import { msg } from "@lingui/core/macro" import { useLingui } from "@lingui/react" import { Box, Center, CloseButton, Divider, Group, Indicator, Popover, TextInput } from "@mantine/core" import { useForm } from "@mantine/form" diff --git a/commafeed-client/src/components/header/MarkAllAsReadButton.tsx b/commafeed-client/src/components/header/MarkAllAsReadButton.tsx index fd234b4f..65ad43fb 100644 --- a/commafeed-client/src/components/header/MarkAllAsReadButton.tsx +++ b/commafeed-client/src/components/header/MarkAllAsReadButton.tsx @@ -1,4 +1,5 @@ -import { Trans, msg } from "@lingui/macro" +import { msg } from "@lingui/core/macro" +import { Trans } from "@lingui/react/macro" import { Button, Code, Group, Modal, Slider, Stack, Text } from "@mantine/core" import { markAllEntries } from "app/entries/thunks" diff --git a/commafeed-client/src/components/header/ProfileMenu.tsx b/commafeed-client/src/components/header/ProfileMenu.tsx index c55e3752..563319c6 100644 --- a/commafeed-client/src/components/header/ProfileMenu.tsx +++ b/commafeed-client/src/components/header/ProfileMenu.tsx @@ -1,4 +1,4 @@ -import { Trans } from "@lingui/macro" +import { Trans } from "@lingui/react/macro" import { Box, Divider, diff --git a/commafeed-client/src/components/settings/CustomCodeSettings.tsx b/commafeed-client/src/components/settings/CustomCodeSettings.tsx index a802494e..434bdc6a 100644 --- a/commafeed-client/src/components/settings/CustomCodeSettings.tsx +++ b/commafeed-client/src/components/settings/CustomCodeSettings.tsx @@ -1,4 +1,4 @@ -import { Trans } from "@lingui/macro" +import { Trans } from "@lingui/react/macro" import { Box, Button, Group, Stack } from "@mantine/core" import { useForm } from "@mantine/form" import { client, errorToStrings } from "app/client" diff --git a/commafeed-client/src/components/settings/DisplaySettings.tsx b/commafeed-client/src/components/settings/DisplaySettings.tsx index 31ee4133..75df4be7 100644 --- a/commafeed-client/src/components/settings/DisplaySettings.tsx +++ b/commafeed-client/src/components/settings/DisplaySettings.tsx @@ -1,5 +1,6 @@ -import { Trans, msg } from "@lingui/macro" +import { msg } from "@lingui/core/macro" import { useLingui } from "@lingui/react" +import { Trans } from "@lingui/react/macro" import { Divider, Group, NumberInput, Radio, Select, SimpleGrid, Stack, Switch } from "@mantine/core" import type { ComboboxData } from "@mantine/core/lib/components/Combobox/Combobox.types" import { Constants } from "app/constants" diff --git a/commafeed-client/src/components/settings/ProfileSettings.tsx b/commafeed-client/src/components/settings/ProfileSettings.tsx index 64d12555..fd2ec64b 100644 --- a/commafeed-client/src/components/settings/ProfileSettings.tsx +++ b/commafeed-client/src/components/settings/ProfileSettings.tsx @@ -1,5 +1,6 @@ -import { Trans, msg } from "@lingui/macro" +import { msg } from "@lingui/core/macro" import { useLingui } from "@lingui/react" +import { Trans } from "@lingui/react/macro" import { Anchor, Box, Button, Checkbox, Divider, Group, Input, PasswordInput, Stack, Text, TextInput } from "@mantine/core" import { useForm } from "@mantine/form" import { openConfirmModal } from "@mantine/modals" diff --git a/commafeed-client/src/components/sidebar/Tree.tsx b/commafeed-client/src/components/sidebar/Tree.tsx index 0959401d..ffebfd96 100644 --- a/commafeed-client/src/components/sidebar/Tree.tsx +++ b/commafeed-client/src/components/sidebar/Tree.tsx @@ -1,4 +1,4 @@ -import { Trans } from "@lingui/macro" +import { Trans } from "@lingui/react/macro" import { Box, Stack } from "@mantine/core" import { Constants } from "app/constants" import { diff --git a/commafeed-client/src/components/sidebar/TreeSearch.tsx b/commafeed-client/src/components/sidebar/TreeSearch.tsx index 139db547..4a9818bf 100644 --- a/commafeed-client/src/components/sidebar/TreeSearch.tsx +++ b/commafeed-client/src/components/sidebar/TreeSearch.tsx @@ -1,5 +1,6 @@ -import { Trans, msg } from "@lingui/macro" +import { msg } from "@lingui/core/macro" import { useLingui } from "@lingui/react" +import { Trans } from "@lingui/react/macro" import { TextInput } from "@mantine/core" import { Spotlight, type SpotlightActionData, spotlight } from "@mantine/spotlight" import { redirectToFeed } from "app/redirect/thunks" diff --git a/commafeed-client/src/hooks/useAppLoading.ts b/commafeed-client/src/hooks/useAppLoading.ts index 71db1536..19cbf1b4 100644 --- a/commafeed-client/src/hooks/useAppLoading.ts +++ b/commafeed-client/src/hooks/useAppLoading.ts @@ -1,4 +1,4 @@ -import { msg } from "@lingui/macro" +import { msg } from "@lingui/core/macro" import { useLingui } from "@lingui/react" import { useAppSelector } from "app/store" diff --git a/commafeed-client/src/pages/ErrorPage.tsx b/commafeed-client/src/pages/ErrorPage.tsx index d143ed96..830ac526 100644 --- a/commafeed-client/src/pages/ErrorPage.tsx +++ b/commafeed-client/src/pages/ErrorPage.tsx @@ -1,4 +1,4 @@ -import { Trans } from "@lingui/macro" +import { Trans } from "@lingui/react/macro" import { Box, Button, Container, Group, Text, Title } from "@mantine/core" import { TbRefresh } from "react-icons/tb" import { tss } from "tss" diff --git a/commafeed-client/src/pages/WelcomePage.tsx b/commafeed-client/src/pages/WelcomePage.tsx index 99f7c58d..8b3c560a 100644 --- a/commafeed-client/src/pages/WelcomePage.tsx +++ b/commafeed-client/src/pages/WelcomePage.tsx @@ -1,4 +1,4 @@ -import { msg } from "@lingui/macro" +import { msg } from "@lingui/core/macro" import { Anchor, Box, Center, Container, Divider, Group, Image, Space, Title, useMantineColorScheme } from "@mantine/core" import { client } from "app/client" import { redirectToApiDocumentation, redirectToLogin, redirectToRegistration, redirectToRootCategory } from "app/redirect/thunks" diff --git a/commafeed-client/src/pages/admin/AdminUsersPage.tsx b/commafeed-client/src/pages/admin/AdminUsersPage.tsx index 59206196..a832c7a6 100644 --- a/commafeed-client/src/pages/admin/AdminUsersPage.tsx +++ b/commafeed-client/src/pages/admin/AdminUsersPage.tsx @@ -1,4 +1,4 @@ -import { Trans } from "@lingui/macro" +import { Trans } from "@lingui/react/macro" import { ActionIcon, Box, Code, Container, Group, Table, Text, Title, useMantineTheme } from "@mantine/core" import { closeAllModals, openConfirmModal, openModal } from "@mantine/modals" import { client, errorToStrings } from "app/client" diff --git a/commafeed-client/src/pages/app/AboutPage.tsx b/commafeed-client/src/pages/app/AboutPage.tsx index bd73a63c..374b433c 100644 --- a/commafeed-client/src/pages/app/AboutPage.tsx +++ b/commafeed-client/src/pages/app/AboutPage.tsx @@ -1,5 +1,6 @@ -import { Trans, msg } from "@lingui/macro" +import { msg } from "@lingui/core/macro" import { useLingui } from "@lingui/react" +import { Trans } from "@lingui/react/macro" import { Anchor, Box, Container, List, NativeSelect, SimpleGrid, Title } from "@mantine/core" import { Constants } from "app/constants" import { redirectToApiDocumentation } from "app/redirect/thunks" diff --git a/commafeed-client/src/pages/app/AddPage.tsx b/commafeed-client/src/pages/app/AddPage.tsx index e734f4e6..8cf55d77 100644 --- a/commafeed-client/src/pages/app/AddPage.tsx +++ b/commafeed-client/src/pages/app/AddPage.tsx @@ -1,4 +1,4 @@ -import { Trans } from "@lingui/macro" +import { Trans } from "@lingui/react/macro" import { Container, Tabs } from "@mantine/core" import { AddCategory } from "components/content/add/AddCategory" import { ImportOpml } from "components/content/add/ImportOpml" diff --git a/commafeed-client/src/pages/app/CategoryDetailsPage.tsx b/commafeed-client/src/pages/app/CategoryDetailsPage.tsx index 51c34b34..18517197 100644 --- a/commafeed-client/src/pages/app/CategoryDetailsPage.tsx +++ b/commafeed-client/src/pages/app/CategoryDetailsPage.tsx @@ -1,4 +1,4 @@ -import { Trans } from "@lingui/macro" +import { Trans } from "@lingui/react/macro" import { Anchor, Box, Button, Code, Container, Divider, Group, Input, NumberInput, Stack, Text, TextInput, Title } from "@mantine/core" import { useForm } from "@mantine/form" import { openConfirmModal } from "@mantine/modals" diff --git a/commafeed-client/src/pages/app/DonatePage.tsx b/commafeed-client/src/pages/app/DonatePage.tsx index 20a99caa..3841056d 100644 --- a/commafeed-client/src/pages/app/DonatePage.tsx +++ b/commafeed-client/src/pages/app/DonatePage.tsx @@ -1,4 +1,4 @@ -import { Trans } from "@lingui/macro" +import { Trans } from "@lingui/react/macro" import { Anchor, Box, Code, Container, Group, List, Title } from "@mantine/core" import { Constants } from "app/constants" import React from "react" diff --git a/commafeed-client/src/pages/app/FeedDetailsPage.tsx b/commafeed-client/src/pages/app/FeedDetailsPage.tsx index 82038eee..82f4b0e9 100644 --- a/commafeed-client/src/pages/app/FeedDetailsPage.tsx +++ b/commafeed-client/src/pages/app/FeedDetailsPage.tsx @@ -1,4 +1,4 @@ -import { Trans } from "@lingui/macro" +import { Trans } from "@lingui/react/macro" import { Anchor, Box, Button, Code, Container, Divider, Group, Input, NumberInput, Stack, Text, TextInput, Title } from "@mantine/core" import { useForm } from "@mantine/form" import { openConfirmModal } from "@mantine/modals" diff --git a/commafeed-client/src/pages/app/FeedEntriesPage.tsx b/commafeed-client/src/pages/app/FeedEntriesPage.tsx index 392896eb..60d45fcf 100644 --- a/commafeed-client/src/pages/app/FeedEntriesPage.tsx +++ b/commafeed-client/src/pages/app/FeedEntriesPage.tsx @@ -1,4 +1,4 @@ -import { Trans } from "@lingui/macro" +import { Trans } from "@lingui/react/macro" import { ActionIcon, Box, Center, Divider, Group, Title, useMantineTheme } from "@mantine/core" import { useViewportSize } from "@mantine/hooks" import { Constants } from "app/constants" diff --git a/commafeed-client/src/pages/app/Layout.tsx b/commafeed-client/src/pages/app/Layout.tsx index 0b673216..bfdceef9 100644 --- a/commafeed-client/src/pages/app/Layout.tsx +++ b/commafeed-client/src/pages/app/Layout.tsx @@ -1,4 +1,4 @@ -import { msg } from "@lingui/macro" +import { msg } from "@lingui/core/macro" import { ActionIcon, AppShell, Box, Center, Group, ScrollArea, Title, useMantineTheme } from "@mantine/core" import { Constants } from "app/constants" import { redirectToAdd, redirectToRootCategory } from "app/redirect/thunks" diff --git a/commafeed-client/src/pages/app/SettingsPage.tsx b/commafeed-client/src/pages/app/SettingsPage.tsx index baba8a17..930fb712 100644 --- a/commafeed-client/src/pages/app/SettingsPage.tsx +++ b/commafeed-client/src/pages/app/SettingsPage.tsx @@ -1,4 +1,4 @@ -import { Trans } from "@lingui/macro" +import { Trans } from "@lingui/react/macro" import { Container, Tabs } from "@mantine/core" import { CustomCodeSettings } from "components/settings/CustomCodeSettings" import { DisplaySettings } from "components/settings/DisplaySettings" diff --git a/commafeed-client/src/pages/app/TagDetailsPage.tsx b/commafeed-client/src/pages/app/TagDetailsPage.tsx index 200518a5..cbe61a8a 100644 --- a/commafeed-client/src/pages/app/TagDetailsPage.tsx +++ b/commafeed-client/src/pages/app/TagDetailsPage.tsx @@ -1,4 +1,4 @@ -import { Trans } from "@lingui/macro" +import { Trans } from "@lingui/react/macro" import { Anchor, Box, Button, Container, Group, Input, Stack, Title } from "@mantine/core" import { Constants } from "app/constants" diff --git a/commafeed-client/src/pages/auth/LoginPage.tsx b/commafeed-client/src/pages/auth/LoginPage.tsx index 96812c9c..f03d5170 100644 --- a/commafeed-client/src/pages/auth/LoginPage.tsx +++ b/commafeed-client/src/pages/auth/LoginPage.tsx @@ -1,5 +1,6 @@ -import { Trans, msg } from "@lingui/macro" +import { msg } from "@lingui/core/macro" import { useLingui } from "@lingui/react" +import { Trans } from "@lingui/react/macro" import { Anchor, Box, Button, Center, Container, Group, Paper, PasswordInput, Stack, TextInput, Title } from "@mantine/core" import { useForm } from "@mantine/form" import { client, errorToStrings } from "app/client" diff --git a/commafeed-client/src/pages/auth/PasswordRecoveryPage.tsx b/commafeed-client/src/pages/auth/PasswordRecoveryPage.tsx index 25806a49..b3fdf6ff 100644 --- a/commafeed-client/src/pages/auth/PasswordRecoveryPage.tsx +++ b/commafeed-client/src/pages/auth/PasswordRecoveryPage.tsx @@ -1,5 +1,6 @@ -import { Trans, msg } from "@lingui/macro" +import { msg } from "@lingui/core/macro" import { useLingui } from "@lingui/react" +import { Trans } from "@lingui/react/macro" import { Anchor, Box, Button, Center, Container, Group, Paper, Stack, TextInput, Title } from "@mantine/core" import { useForm } from "@mantine/form" import { client, errorToStrings } from "app/client" diff --git a/commafeed-client/src/pages/auth/RegistrationPage.tsx b/commafeed-client/src/pages/auth/RegistrationPage.tsx index 23dd8fc0..ffc447d6 100644 --- a/commafeed-client/src/pages/auth/RegistrationPage.tsx +++ b/commafeed-client/src/pages/auth/RegistrationPage.tsx @@ -1,5 +1,6 @@ -import { Trans, msg } from "@lingui/macro" +import { msg } from "@lingui/core/macro" import { useLingui } from "@lingui/react" +import { Trans } from "@lingui/react/macro" import { Anchor, Box, Button, Center, Container, Group, Paper, PasswordInput, Stack, TextInput, Title } from "@mantine/core" import { useForm } from "@mantine/form" import { client, errorToStrings } from "app/client" diff --git a/commafeed-client/vite.config.ts b/commafeed-client/vite.config.ts index 8fed4082..a52a5a80 100644 --- a/commafeed-client/vite.config.ts +++ b/commafeed-client/vite.config.ts @@ -10,8 +10,7 @@ export default defineConfig(() => ({ plugins: [ react({ babel: { - // babel-macro is needed for lingui - plugins: ["macros"], + plugins: ["@lingui/babel-plugin-lingui-macro"], }, }), lingui(),