Merge branch 'main' of github.com:bluesky-social/social-app into main
This commit is contained in:
commit
e13777c191
4 changed files with 21 additions and 12 deletions
|
@ -119,7 +119,7 @@ export function StepAlgoFeeds() {
|
||||||
<FeedCard config={PRIMARY_FEEDS[0]} />
|
<FeedCard config={PRIMARY_FEEDS[0]} />
|
||||||
<Text
|
<Text
|
||||||
style={[a.text_md, a.pt_4xl, a.pb_lg, t.atoms.text_contrast_700]}>
|
style={[a.text_md, a.pt_4xl, a.pb_lg, t.atoms.text_contrast_700]}>
|
||||||
<Trans>Or you can try our "Discover" algorithm:</Trans>
|
<Trans>You can also try our "Discover" algorithm:</Trans>
|
||||||
</Text>
|
</Text>
|
||||||
<FeedCard config={PRIMARY_FEEDS[1]} />
|
<FeedCard config={PRIMARY_FEEDS[1]} />
|
||||||
</Toggle.Group>
|
</Toggle.Group>
|
||||||
|
|
|
@ -129,13 +129,13 @@ export function StepSuggestedAccounts() {
|
||||||
<IconCircle icon={At} style={[a.mb_2xl]} />
|
<IconCircle icon={At} style={[a.mb_2xl]} />
|
||||||
|
|
||||||
<Title>
|
<Title>
|
||||||
<Trans>Here are some accounts for your to follow</Trans>
|
<Trans>Here are some accounts for you to follow</Trans>
|
||||||
</Title>
|
</Title>
|
||||||
<Description>
|
<Description>
|
||||||
{state.interestsStepResults.selectedInterests.length ? (
|
{state.interestsStepResults.selectedInterests.length ? (
|
||||||
<Trans>Based on your interest in {interestsText}</Trans>
|
<Trans>Based on your interest in {interestsText}</Trans>
|
||||||
) : (
|
) : (
|
||||||
<Trans>These are popular accounts you might like.</Trans>
|
<Trans>These are popular accounts you might like:</Trans>
|
||||||
)}
|
)}
|
||||||
</Description>
|
</Description>
|
||||||
|
|
||||||
|
@ -171,7 +171,7 @@ export function StepSuggestedAccounts() {
|
||||||
color="gradient_sky"
|
color="gradient_sky"
|
||||||
size="large"
|
size="large"
|
||||||
label={_(
|
label={_(
|
||||||
msg`Follow selected accounts and continue to then next step`,
|
msg`Follow selected accounts and continue to the next step`,
|
||||||
)}
|
)}
|
||||||
onPress={handleContinue}>
|
onPress={handleContinue}>
|
||||||
<ButtonText>
|
<ButtonText>
|
||||||
|
|
|
@ -40,6 +40,7 @@ import {useLingui} from '@lingui/react'
|
||||||
import {useLanguagePrefs} from '#/state/preferences'
|
import {useLanguagePrefs} from '#/state/preferences'
|
||||||
import {useComposerControls} from '#/state/shell/composer'
|
import {useComposerControls} from '#/state/shell/composer'
|
||||||
import {useModerationOpts} from '#/state/queries/preferences'
|
import {useModerationOpts} from '#/state/queries/preferences'
|
||||||
|
import {useOpenLink} from '#/state/preferences/in-app-browser'
|
||||||
import {Shadow, usePostShadow, POST_TOMBSTONE} from '#/state/cache/post-shadow'
|
import {Shadow, usePostShadow, POST_TOMBSTONE} from '#/state/cache/post-shadow'
|
||||||
import {ThreadPost} from '#/state/queries/post-thread'
|
import {ThreadPost} from '#/state/queries/post-thread'
|
||||||
import {useSession} from '#/state/session'
|
import {useSession} from '#/state/session'
|
||||||
|
@ -701,17 +702,23 @@ function ExpandedPostDetails({
|
||||||
}) {
|
}) {
|
||||||
const pal = usePalette('default')
|
const pal = usePalette('default')
|
||||||
const {_} = useLingui()
|
const {_} = useLingui()
|
||||||
|
const openLink = useOpenLink()
|
||||||
|
const onTranslatePress = React.useCallback(
|
||||||
|
() => openLink(translatorUrl),
|
||||||
|
[openLink, translatorUrl],
|
||||||
|
)
|
||||||
return (
|
return (
|
||||||
<View style={[s.flexRow, s.mt2, s.mb10]}>
|
<View style={[s.flexRow, s.mt2, s.mb10]}>
|
||||||
<Text style={pal.textLight}>{niceDate(post.indexedAt)}</Text>
|
<Text style={pal.textLight}>{niceDate(post.indexedAt)}</Text>
|
||||||
{needsTranslation && (
|
{needsTranslation && (
|
||||||
<>
|
<>
|
||||||
<Text style={pal.textLight}> · </Text>
|
<Text style={pal.textLight}> · </Text>
|
||||||
<Link href={translatorUrl} title={_(msg`Translate`)}>
|
<Text
|
||||||
<Text style={pal.link}>
|
style={pal.link}
|
||||||
|
title={_(msg`Translate`)}
|
||||||
|
onPress={onTranslatePress}>
|
||||||
<Trans>Translate</Trans>
|
<Trans>Translate</Trans>
|
||||||
</Text>
|
</Text>
|
||||||
</Link>
|
|
||||||
</>
|
</>
|
||||||
)}
|
)}
|
||||||
</View>
|
</View>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
import React, {memo} from 'react'
|
import React, {memo} from 'react'
|
||||||
import {Linking, StyleProp, View, ViewStyle} from 'react-native'
|
import {StyleProp, View, ViewStyle} from 'react-native'
|
||||||
import Clipboard from '@react-native-clipboard/clipboard'
|
import Clipboard from '@react-native-clipboard/clipboard'
|
||||||
import {FontAwesomeIcon} from '@fortawesome/react-native-fontawesome'
|
import {FontAwesomeIcon} from '@fortawesome/react-native-fontawesome'
|
||||||
import {
|
import {
|
||||||
|
@ -24,6 +24,7 @@ import {usePostDeleteMutation} from '#/state/queries/post'
|
||||||
import {useMutedThreads, useToggleThreadMute} from '#/state/muted-threads'
|
import {useMutedThreads, useToggleThreadMute} from '#/state/muted-threads'
|
||||||
import {useLanguagePrefs} from '#/state/preferences'
|
import {useLanguagePrefs} from '#/state/preferences'
|
||||||
import {useHiddenPosts, useHiddenPostsApi} from '#/state/preferences'
|
import {useHiddenPosts, useHiddenPostsApi} from '#/state/preferences'
|
||||||
|
import {useOpenLink} from '#/state/preferences/in-app-browser'
|
||||||
import {logger} from '#/logger'
|
import {logger} from '#/logger'
|
||||||
import {msg} from '@lingui/macro'
|
import {msg} from '@lingui/macro'
|
||||||
import {useLingui} from '@lingui/react'
|
import {useLingui} from '@lingui/react'
|
||||||
|
@ -61,6 +62,7 @@ let PostDropdownBtn = ({
|
||||||
const postDeleteMutation = usePostDeleteMutation()
|
const postDeleteMutation = usePostDeleteMutation()
|
||||||
const hiddenPosts = useHiddenPosts()
|
const hiddenPosts = useHiddenPosts()
|
||||||
const {hidePost} = useHiddenPostsApi()
|
const {hidePost} = useHiddenPostsApi()
|
||||||
|
const openLink = useOpenLink()
|
||||||
|
|
||||||
const rootUri = record.reply?.root?.uri || postUri
|
const rootUri = record.reply?.root?.uri || postUri
|
||||||
const isThreadMuted = mutedThreads.includes(rootUri)
|
const isThreadMuted = mutedThreads.includes(rootUri)
|
||||||
|
@ -111,8 +113,8 @@ let PostDropdownBtn = ({
|
||||||
}, [_, richText])
|
}, [_, richText])
|
||||||
|
|
||||||
const onOpenTranslate = React.useCallback(() => {
|
const onOpenTranslate = React.useCallback(() => {
|
||||||
Linking.openURL(translatorUrl)
|
openLink(translatorUrl)
|
||||||
}, [translatorUrl])
|
}, [openLink, translatorUrl])
|
||||||
|
|
||||||
const onHidePost = React.useCallback(() => {
|
const onHidePost = React.useCallback(() => {
|
||||||
hidePost({uri: postUri})
|
hidePost({uri: postUri})
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue