Internationalize more strings (#2440)

Co-authored-by: Ansh <anshnanda10@gmail.com>
This commit is contained in:
Stanislas Signoud
2024-01-09 23:37:15 +01:00
committed by GitHub
parent aeeacd10d3
commit 008893b911
108 changed files with 925 additions and 558 deletions
+8 -7
View File
@@ -160,7 +160,7 @@ export function SavedFeeds({}: Props) {
type="sm"
style={pal.link}
href="https://github.com/bluesky-social/feed-generator"
text="See this guide"
text={_(msg`See this guide`)}
/>{' '}
for more information.
</Trans>
@@ -188,6 +188,7 @@ function ListItem({
>['reset']
}) {
const pal = usePalette('default')
const {_} = useLingui()
const {isPending: isPinPending, mutateAsync: pinFeed} = usePinFeedMutation()
const {isPending: isUnpinPending, mutateAsync: unpinFeed} =
useUnpinFeedMutation()
@@ -205,10 +206,10 @@ function ListItem({
await pinFeed({uri: feedUri})
}
} catch (e) {
Toast.show('There was an issue contacting the server')
Toast.show(_(msg`There was an issue contacting the server`))
logger.error('Failed to toggle pinned feed', {error: e})
}
}, [feedUri, isPinned, pinFeed, unpinFeed, resetSaveFeedsMutationState])
}, [feedUri, isPinned, pinFeed, unpinFeed, resetSaveFeedsMutationState, _])
const onPressUp = React.useCallback(async () => {
if (!isPinned) return
@@ -227,10 +228,10 @@ function ListItem({
index: pinned.indexOf(feedUri),
})
} catch (e) {
Toast.show('There was an issue contacting the server')
Toast.show(_(msg`There was an issue contacting the server`))
logger.error('Failed to set pinned feed order', {error: e})
}
}, [feedUri, isPinned, setSavedFeeds, currentFeeds])
}, [feedUri, isPinned, setSavedFeeds, currentFeeds, _])
const onPressDown = React.useCallback(async () => {
if (!isPinned) return
@@ -248,10 +249,10 @@ function ListItem({
index: pinned.indexOf(feedUri),
})
} catch (e) {
Toast.show('There was an issue contacting the server')
Toast.show(_(msg`There was an issue contacting the server`))
logger.error('Failed to set pinned feed order', {error: e})
}
}, [feedUri, isPinned, setSavedFeeds, currentFeeds])
}, [feedUri, isPinned, setSavedFeeds, currentFeeds, _])
return (
<Pressable