fix patch social-app ios
This commit is contained in:
@@ -1,8 +1,6 @@
|
||||
diff --git a/src/screens/Settings/AboutSettings.tsx b/src/screens/Settings/AboutSettings.tsx
|
||||
index 9ba067a2f..e34b9f9b0 100644
|
||||
--- a/src/screens/Settings/AboutSettings.tsx
|
||||
+++ b/src/screens/Settings/AboutSettings.tsx
|
||||
@@ -78,7 +78,7 @@ export function AboutSettingsScreen({}: Props) {
|
||||
@@ -79,7 +79,7 @@
|
||||
<Layout.Content>
|
||||
<SettingsList.Container>
|
||||
<SettingsList.LinkItem
|
||||
@@ -11,7 +9,7 @@ index 9ba067a2f..e34b9f9b0 100644
|
||||
label={_(msg`Terms of Service`)}>
|
||||
<SettingsList.ItemIcon icon={NewspaperIcon} />
|
||||
<SettingsList.ItemText>
|
||||
@@ -86,7 +86,7 @@ export function AboutSettingsScreen({}: Props) {
|
||||
@@ -87,7 +87,7 @@
|
||||
</SettingsList.ItemText>
|
||||
</SettingsList.LinkItem>
|
||||
<SettingsList.LinkItem
|
||||
@@ -20,11 +18,9 @@ index 9ba067a2f..e34b9f9b0 100644
|
||||
label={_(msg`Privacy Policy`)}>
|
||||
<SettingsList.ItemIcon icon={NewspaperIcon} />
|
||||
<SettingsList.ItemText>
|
||||
diff --git a/src/screens/Takendown.tsx b/src/screens/Takendown.tsx
|
||||
index 660aecf1a..f19a62c0f 100644
|
||||
--- a/src/screens/Takendown.tsx
|
||||
+++ b/src/screens/Takendown.tsx
|
||||
@@ -212,10 +212,10 @@ export function Takendown() {
|
||||
@@ -210,10 +210,10 @@
|
||||
<Trans>
|
||||
Your account was found to be in violation of the{' '}
|
||||
<SimpleInlineLinkText
|
||||
@@ -38,15 +34,14 @@ index 660aecf1a..f19a62c0f 100644
|
||||
</SimpleInlineLinkText>
|
||||
. You have been sent an email outlining the specific violation
|
||||
and suspension period, if applicable. You can appeal this
|
||||
diff --git a/src/view/screens/PrivacyPolicy.tsx b/src/view/screens/PrivacyPolicy.tsx
|
||||
index a89eaadc4..71ce7c81f 100644
|
||||
--- a/src/view/screens/PrivacyPolicy.tsx
|
||||
+++ b/src/view/screens/PrivacyPolicy.tsx
|
||||
@@ -1,51 +1,49 @@
|
||||
@@ -1,52 +1,49 @@
|
||||
import React from 'react'
|
||||
-import {View} from 'react-native'
|
||||
-import {msg, Trans} from '@lingui/macro'
|
||||
-import {msg} from '@lingui/core/macro'
|
||||
-import {useLingui} from '@lingui/react'
|
||||
-import {Trans} from '@lingui/react/macro'
|
||||
-import {useFocusEffect} from '@react-navigation/native'
|
||||
-
|
||||
-import {usePalette} from '#/lib/hooks/usePalette'
|
||||
@@ -62,26 +57,25 @@ index a89eaadc4..71ce7c81f 100644
|
||||
+import {ScrollView} from 'react-native'
|
||||
import * as Layout from '#/components/Layout'
|
||||
-import {ViewHeader} from '../com/util/ViewHeader'
|
||||
-
|
||||
+import {useSetTitle} from '#/lib/hooks/useSetTitle'
|
||||
+import {atoms as a, useTheme} from '#/alf'
|
||||
+import {Text} from '#/components/Typography'
|
||||
|
||||
-type Props = NativeStackScreenProps<CommonNavigatorParams, 'PrivacyPolicy'>
|
||||
-export const PrivacyPolicyScreen = (_props: Props) => {
|
||||
- const pal = usePalette('default')
|
||||
- const {_} = useLingui()
|
||||
- const setMinimalShellMode = useSetMinimalShellMode()
|
||||
-
|
||||
+export function PrivacyPolicyScreen() {
|
||||
+ useSetTitle('Privacy Policy')
|
||||
+ const t = useTheme()
|
||||
|
||||
- useFocusEffect(
|
||||
- React.useCallback(() => {
|
||||
- setMinimalShellMode(false)
|
||||
- }, [setMinimalShellMode]),
|
||||
- )
|
||||
+import {useSetTitle} from '#/lib/hooks/useSetTitle'
|
||||
+import {atoms as a, useTheme} from '#/alf'
|
||||
+import {Text} from '#/components/Typography'
|
||||
+
|
||||
+export function PrivacyPolicyScreen() {
|
||||
+ useSetTitle('Privacy Policy')
|
||||
+ const t = useTheme()
|
||||
|
||||
-
|
||||
return (
|
||||
<Layout.Screen>
|
||||
- <ViewHeader title={_(msg`Privacy Policy`)} />
|
||||
@@ -135,15 +129,14 @@ index a89eaadc4..71ce7c81f 100644
|
||||
</ScrollView>
|
||||
</Layout.Screen>
|
||||
)
|
||||
diff --git a/src/view/screens/TermsOfService.tsx b/src/view/screens/TermsOfService.tsx
|
||||
index d843c713c..c6a36268b 100644
|
||||
--- a/src/view/screens/TermsOfService.tsx
|
||||
+++ b/src/view/screens/TermsOfService.tsx
|
||||
@@ -1,49 +1,49 @@
|
||||
@@ -1,50 +1,49 @@
|
||||
import React from 'react'
|
||||
-import {View} from 'react-native'
|
||||
-import {msg, Trans} from '@lingui/macro'
|
||||
-import {msg} from '@lingui/core/macro'
|
||||
-import {useLingui} from '@lingui/react'
|
||||
-import {Trans} from '@lingui/react/macro'
|
||||
-import {useFocusEffect} from '@react-navigation/native'
|
||||
-
|
||||
-import {usePalette} from '#/lib/hooks/usePalette'
|
||||
@@ -159,26 +152,25 @@ index d843c713c..c6a36268b 100644
|
||||
+import {ScrollView} from 'react-native'
|
||||
import * as Layout from '#/components/Layout'
|
||||
-import {ViewHeader} from '../com/util/ViewHeader'
|
||||
-
|
||||
+import {useSetTitle} from '#/lib/hooks/useSetTitle'
|
||||
+import {atoms as a, useTheme} from '#/alf'
|
||||
+import {Text} from '#/components/Typography'
|
||||
|
||||
-type Props = NativeStackScreenProps<CommonNavigatorParams, 'TermsOfService'>
|
||||
-export const TermsOfServiceScreen = (_props: Props) => {
|
||||
- const pal = usePalette('default')
|
||||
- const setMinimalShellMode = useSetMinimalShellMode()
|
||||
- const {_} = useLingui()
|
||||
-
|
||||
+export function TermsOfServiceScreen() {
|
||||
+ useSetTitle('Terms of Service')
|
||||
+ const t = useTheme()
|
||||
|
||||
- useFocusEffect(
|
||||
- React.useCallback(() => {
|
||||
- setMinimalShellMode(false)
|
||||
- }, [setMinimalShellMode]),
|
||||
- )
|
||||
+import {useSetTitle} from '#/lib/hooks/useSetTitle'
|
||||
+import {atoms as a, useTheme} from '#/alf'
|
||||
+import {Text} from '#/components/Typography'
|
||||
+
|
||||
+export function TermsOfServiceScreen() {
|
||||
+ useSetTitle('Terms of Service')
|
||||
+ const t = useTheme()
|
||||
|
||||
-
|
||||
return (
|
||||
<Layout.Screen>
|
||||
- <ViewHeader title={_(msg`Terms of Service`)} />
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
diff --git a/src/view/com/posts/DiscoverFallbackHeader.tsx b/src/view/com/posts/DiscoverFallbackHeader.tsx
|
||||
index e35a33aaf..a36f84ae0 100644
|
||||
--- a/src/view/com/posts/DiscoverFallbackHeader.tsx
|
||||
+++ b/src/view/com/posts/DiscoverFallbackHeader.tsx
|
||||
@@ -7,37 +7,5 @@ import {TextLink} from '../util/Link'
|
||||
@@ -7,37 +7,5 @@
|
||||
import {Text} from '../util/text/Text'
|
||||
|
||||
export function DiscoverFallbackHeader() {
|
||||
@@ -41,18 +39,16 @@ index e35a33aaf..a36f84ae0 100644
|
||||
- )
|
||||
+ return null
|
||||
}
|
||||
diff --git a/src/view/com/posts/FollowingEmptyState.tsx b/src/view/com/posts/FollowingEmptyState.tsx
|
||||
index 352cc1dc0..f477521af 100644
|
||||
--- a/src/view/com/posts/FollowingEmptyState.tsx
|
||||
+++ b/src/view/com/posts/FollowingEmptyState.tsx
|
||||
@@ -1,37 +1,14 @@
|
||||
@@ -1,38 +1,15 @@
|
||||
import React from 'react'
|
||||
import {StyleSheet, View} from 'react-native'
|
||||
-import {
|
||||
- FontAwesomeIcon,
|
||||
- type FontAwesomeIconStyle,
|
||||
-} from '@fortawesome/react-native-fontawesome'
|
||||
import {Trans} from '@lingui/macro'
|
||||
import {Trans} from '@lingui/react/macro'
|
||||
-import {useNavigation} from '@react-navigation/native'
|
||||
|
||||
import {usePalette} from '#/lib/hooks/usePalette'
|
||||
@@ -67,7 +63,7 @@ index 352cc1dc0..f477521af 100644
|
||||
const pal = usePalette('default')
|
||||
- const palInverted = usePalette('inverted')
|
||||
- const navigation = useNavigation<NavigationProp>()
|
||||
-
|
||||
|
||||
- const onPressFindAccounts = React.useCallback(() => {
|
||||
- if (IS_WEB) {
|
||||
- navigation.navigate('Search', {})
|
||||
@@ -80,10 +76,11 @@ index 352cc1dc0..f477521af 100644
|
||||
- const onPressDiscoverFeeds = React.useCallback(() => {
|
||||
- navigation.navigate('Feeds')
|
||||
- }, [navigation])
|
||||
|
||||
-
|
||||
return (
|
||||
<View style={styles.container}>
|
||||
@@ -45,36 +22,6 @@ export function FollowingEmptyState() {
|
||||
<View style={styles.inner}>
|
||||
@@ -45,36 +22,6 @@
|
||||
happening.
|
||||
</Trans>
|
||||
</Text>
|
||||
@@ -120,7 +117,7 @@ index 352cc1dc0..f477521af 100644
|
||||
</View>
|
||||
</View>
|
||||
)
|
||||
@@ -98,13 +45,4 @@ const styles = StyleSheet.create({
|
||||
@@ -98,13 +45,4 @@
|
||||
marginLeft: 'auto',
|
||||
marginRight: 'auto',
|
||||
},
|
||||
@@ -134,18 +131,16 @@ index 352cc1dc0..f477521af 100644
|
||||
- borderRadius: 30,
|
||||
- },
|
||||
})
|
||||
diff --git a/src/view/com/posts/FollowingEndOfFeed.tsx b/src/view/com/posts/FollowingEndOfFeed.tsx
|
||||
index e3c84d782..efb55d406 100644
|
||||
--- a/src/view/com/posts/FollowingEndOfFeed.tsx
|
||||
+++ b/src/view/com/posts/FollowingEndOfFeed.tsx
|
||||
@@ -1,36 +1,13 @@
|
||||
@@ -1,37 +1,14 @@
|
||||
import React from 'react'
|
||||
import {Dimensions, StyleSheet, View} from 'react-native'
|
||||
-import {
|
||||
- FontAwesomeIcon,
|
||||
- type FontAwesomeIconStyle,
|
||||
-} from '@fortawesome/react-native-fontawesome'
|
||||
import {Trans} from '@lingui/macro'
|
||||
import {Trans} from '@lingui/react/macro'
|
||||
-import {useNavigation} from '@react-navigation/native'
|
||||
|
||||
import {usePalette} from '#/lib/hooks/usePalette'
|
||||
@@ -159,7 +154,7 @@ index e3c84d782..efb55d406 100644
|
||||
const pal = usePalette('default')
|
||||
- const palInverted = usePalette('inverted')
|
||||
- const navigation = useNavigation<NavigationProp>()
|
||||
-
|
||||
|
||||
- const onPressFindAccounts = React.useCallback(() => {
|
||||
- if (IS_WEB) {
|
||||
- navigation.navigate('Search', {})
|
||||
@@ -172,10 +167,11 @@ index e3c84d782..efb55d406 100644
|
||||
- const onPressDiscoverFeeds = React.useCallback(() => {
|
||||
- navigation.navigate('Feeds')
|
||||
- }, [navigation])
|
||||
|
||||
-
|
||||
return (
|
||||
<View
|
||||
@@ -41,41 +18,8 @@ export function FollowingEndOfFeed() {
|
||||
style={[
|
||||
@@ -41,41 +18,8 @@
|
||||
]}>
|
||||
<View style={styles.inner}>
|
||||
<Text type="xl-medium" style={[s.textCenter, pal.text]}>
|
||||
@@ -183,7 +179,8 @@ index e3c84d782..efb55d406 100644
|
||||
- You've reached the end of your feed! Find some more accounts to
|
||||
- follow.
|
||||
- </Trans>
|
||||
- </Text>
|
||||
+ <Trans>You've reached the end of your feed!</Trans>
|
||||
</Text>
|
||||
- <Button
|
||||
- type="inverted"
|
||||
- style={styles.emptyBtn}
|
||||
@@ -200,8 +197,7 @@ index e3c84d782..efb55d406 100644
|
||||
-
|
||||
- <Text type="xl-medium" style={[s.textCenter, pal.text, s.mt20]}>
|
||||
- <Trans>You can also discover new Custom Feeds to follow.</Trans>
|
||||
+ <Trans>You've reached the end of your feed!</Trans>
|
||||
</Text>
|
||||
- </Text>
|
||||
- <Button
|
||||
- type="inverted"
|
||||
- style={[styles.emptyBtn, s.mt10]}
|
||||
@@ -218,7 +214,7 @@ index e3c84d782..efb55d406 100644
|
||||
</View>
|
||||
</View>
|
||||
)
|
||||
@@ -93,13 +37,4 @@ const styles = StyleSheet.create({
|
||||
@@ -93,13 +37,4 @@
|
||||
width: '100%',
|
||||
maxWidth: 460,
|
||||
},
|
||||
@@ -232,11 +228,9 @@ index e3c84d782..efb55d406 100644
|
||||
- borderRadius: 30,
|
||||
- },
|
||||
})
|
||||
diff --git a/src/view/com/posts/PostFeed.tsx b/src/view/com/posts/PostFeed.tsx
|
||||
index 4f25468c9..a72a10b80 100644
|
||||
--- a/src/view/com/posts/PostFeed.tsx
|
||||
+++ b/src/view/com/posts/PostFeed.tsx
|
||||
@@ -766,7 +766,7 @@ let PostFeed = ({
|
||||
@@ -765,7 +765,7 @@
|
||||
} else if (row.type === 'feedShutdownMsg') {
|
||||
return <FeedShutdownMsg feedUri={feedUriOrActorDid} />
|
||||
} else if (row.type === 'interstitialFollows') {
|
||||
|
||||
@@ -7,22 +7,21 @@
|
||||
import {
|
||||
type AppBskyActorDefs,
|
||||
moderateProfile,
|
||||
@@ -9,8 +9,10 @@
|
||||
} from '@atproto/api'
|
||||
import {msg, Trans} from '@lingui/macro'
|
||||
@@ -11,7 +11,10 @@
|
||||
import {useLingui} from '@lingui/react'
|
||||
+import {useQuery} from '@tanstack/react-query'
|
||||
import {Trans} from '@lingui/react/macro'
|
||||
|
||||
+import {useQuery} from '@tanstack/react-query'
|
||||
+
|
||||
import {useHaptics} from '#/lib/haptics'
|
||||
+import {useOpenLink} from '#/lib/hooks/useOpenLink'
|
||||
import {sanitizeDisplayName} from '#/lib/strings/display-names'
|
||||
import {sanitizeHandle} from '#/lib/strings/handles'
|
||||
import {logger} from '#/logger'
|
||||
@@ -45,6 +47,103 @@
|
||||
import {ProfileHeaderMetrics} from './Metrics'
|
||||
@@ -47,6 +50,103 @@
|
||||
import {ProfileHeaderShell} from './Shell'
|
||||
import {ProfileHeaderSuggestedFollows} from './SuggestedFollows'
|
||||
+
|
||||
|
||||
+const SERVICE_FAVICONS: Record<string, any> = {
|
||||
+ 'syui.ai': require('../../../../assets/favicons/syui.ai.png'),
|
||||
+ 'bsky.app': require('../../../../assets/favicons/bsky.app.png'),
|
||||
@@ -119,10 +118,11 @@
|
||||
+ </View>
|
||||
+ )
|
||||
+}
|
||||
|
||||
+
|
||||
interface Props {
|
||||
profile: AppBskyActorDefs.ProfileViewDetailed
|
||||
@@ -151,6 +250,7 @@
|
||||
descriptionRT: RichTextAPI | null
|
||||
@@ -152,6 +252,7 @@
|
||||
{!isPlaceholderProfile && !isBlockedUser && (
|
||||
<View style={a.gap_md}>
|
||||
<ProfileHeaderMetrics profile={profile} />
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
--- a/src/screens/Profile/Header/ProfileHeaderStandard.tsx
|
||||
+++ b/src/screens/Profile/Header/ProfileHeaderStandard.tsx
|
||||
@@ -46,6 +46,7 @@
|
||||
@@ -48,6 +48,7 @@
|
||||
import {ProfileHeaderHandle} from './Handle'
|
||||
import {ProfileHeaderMetrics} from './Metrics'
|
||||
import {ProfileHeaderShell} from './Shell'
|
||||
@@ -8,7 +8,7 @@
|
||||
import {ProfileHeaderSuggestedFollows} from './SuggestedFollows'
|
||||
|
||||
const SERVICE_FAVICONS: Record<string, any> = {
|
||||
@@ -251,6 +252,7 @@
|
||||
@@ -253,6 +254,7 @@
|
||||
<View style={a.gap_md}>
|
||||
<ProfileHeaderMetrics profile={profile} />
|
||||
<ProfileServiceLinks profile={profile} />
|
||||
|
||||
@@ -5,10 +5,10 @@
|
||||
import Animated, {FadeIn, FadeOut} from 'react-native-reanimated'
|
||||
import {Image} from 'expo-image'
|
||||
+import {useVideoPlayer, VideoView} from 'expo-video'
|
||||
import {msg, Trans} from '@lingui/macro'
|
||||
import {msg} from '@lingui/core/macro'
|
||||
import {useLingui} from '@lingui/react'
|
||||
|
||||
@@ -14,10 +15,13 @@
|
||||
import {Trans} from '@lingui/react/macro'
|
||||
@@ -15,10 +16,13 @@
|
||||
import splashImagePointer from '../../../../assets/splash/illustration-mobile.png'
|
||||
// @ts-ignore
|
||||
import darkSplashImagePointer from '../../../../assets/splash/illustration-mobile-dark.png'
|
||||
@@ -22,7 +22,7 @@
|
||||
|
||||
export const SplashScreen = ({
|
||||
onPressSignin,
|
||||
@@ -52,13 +56,30 @@
|
||||
@@ -53,13 +57,30 @@
|
||||
}
|
||||
}, [t, isDarkMode])
|
||||
|
||||
|
||||
40
ios/patching/045-social-app-ios-composer-cancel.patch
Normal file
40
ios/patching/045-social-app-ios-composer-cancel.patch
Normal file
@@ -0,0 +1,40 @@
|
||||
--- a/src/view/com/composer/Composer.tsx
|
||||
+++ b/src/view/com/composer/Composer.tsx
|
||||
@@ -717,16 +717,7 @@
|
||||
post.shortenedGraphemeLength > 0 || post.embed.media || post.embed.link,
|
||||
)
|
||||
|
||||
- // Show discard prompt if there's content AND either:
|
||||
- // - No draft is loaded (new composition)
|
||||
- // - Draft is loaded but has been modified
|
||||
- if (hasContent && (!composerState.draftId || composerState.isDirty)) {
|
||||
- closeAllDialogs()
|
||||
- Keyboard.dismiss()
|
||||
- discardPromptControl.open()
|
||||
- } else {
|
||||
- onClose()
|
||||
- }
|
||||
+ onClose()
|
||||
}, [
|
||||
thread,
|
||||
composerState.draftId,
|
||||
@@ -1551,18 +1542,7 @@
|
||||
</>
|
||||
) : (
|
||||
<>
|
||||
- {!isReply && (
|
||||
- <DraftsButton
|
||||
- onSelectDraft={onSelectDraft}
|
||||
- onSaveDraft={onSaveDraft}
|
||||
- onDiscard={onDiscard}
|
||||
- isEmpty={isEmpty}
|
||||
- isDirty={isDirty}
|
||||
- isEditingDraft={isEditingDraft}
|
||||
- canSaveDraft={canSaveDraft}
|
||||
- textLength={textLength}
|
||||
- />
|
||||
- )}
|
||||
+ {/* DraftsButton removed */}
|
||||
<Button
|
||||
testID="composerPublishBtn"
|
||||
label={
|
||||
@@ -52,6 +52,7 @@ PATCH_FILES_IOS=(
|
||||
"042-social-app-ios-at-links.patch"
|
||||
"043-social-app-ios-rightnav-links.patch"
|
||||
"044-social-app-ios-splash-video.patch"
|
||||
"045-social-app-ios-composer-cancel.patch"
|
||||
)
|
||||
|
||||
function ios-env() {
|
||||
|
||||
Reference in New Issue
Block a user