mirror of https://github.com/tooot-app/app
Squashed commit of the following:
commit af3560afebf5f4482e037c1f7c46ca16bd1975a2 Author: Zhiyuan Zheng <me@xmflsct.com> Date: Sun Feb 6 22:52:43 2022 +0100 Hotfix v3.1.2 commit c8a16c9aa61de80b5e485cf09f5f539ab15b4449 Author: Zhiyuan Zheng <me@xmflsct.com> Date: Sun Feb 6 18:09:11 2022 +0100 Try to fix weird crash commit c9f7cb664c8ba34acd1700e8443bddb2bb039fcd Author: Zhiyuan Zheng <me@xmflsct.com> Date: Sun Feb 6 22:47:30 2022 +0100 Fix iOS 12 crashes on media selection https://github.com/expo/expo/issues/14903#issuecomment-966161497
This commit is contained in:
parent
10994988b2
commit
f1e7e05a1d
|
@ -3,8 +3,8 @@
|
||||||
"versions": {
|
"versions": {
|
||||||
"native": "220204",
|
"native": "220204",
|
||||||
"major": 3,
|
"major": 3,
|
||||||
"minor": 3,
|
"minor": 1,
|
||||||
"patch": 1,
|
"patch": 2,
|
||||||
"expo": "44.0.0"
|
"expo": "44.0.0"
|
||||||
},
|
},
|
||||||
"description": "tooot app for Mastodon",
|
"description": "tooot app for Mastodon",
|
||||||
|
|
|
@ -4,7 +4,7 @@ import * as ImageManipulator from 'expo-image-manipulator'
|
||||||
import * as ImagePicker from 'expo-image-picker'
|
import * as ImagePicker from 'expo-image-picker'
|
||||||
import { ImageInfo } from 'expo-image-picker/build/ImagePicker.types'
|
import { ImageInfo } from 'expo-image-picker/build/ImagePicker.types'
|
||||||
import i18next from 'i18next'
|
import i18next from 'i18next'
|
||||||
import { Alert, Linking } from 'react-native'
|
import { Alert, Linking, Platform } from 'react-native'
|
||||||
|
|
||||||
export interface Props {
|
export interface Props {
|
||||||
mediaTypes?: ImagePicker.MediaTypeOptions
|
mediaTypes?: ImagePicker.MediaTypeOptions
|
||||||
|
@ -91,7 +91,11 @@ const mediaSelector = async ({
|
||||||
} else {
|
} else {
|
||||||
const result = await ImagePicker.launchImageLibraryAsync({
|
const result = await ImagePicker.launchImageLibraryAsync({
|
||||||
mediaTypes,
|
mediaTypes,
|
||||||
exif: false
|
exif: false,
|
||||||
|
presentationStyle:
|
||||||
|
Platform.OS === 'ios' && parseInt(Platform.Version) < 13
|
||||||
|
? 0
|
||||||
|
: -2
|
||||||
})
|
})
|
||||||
|
|
||||||
if (!result.cancelled) {
|
if (!result.cancelled) {
|
||||||
|
|
|
@ -169,10 +169,11 @@ const instancesSlice = createSlice({
|
||||||
action: PayloadAction<Instance['timelinesLookback']>
|
action: PayloadAction<Instance['timelinesLookback']>
|
||||||
) => {
|
) => {
|
||||||
const activeIndex = findInstanceActive(instances)
|
const activeIndex = findInstanceActive(instances)
|
||||||
instances[activeIndex].timelinesLookback = {
|
instances[activeIndex] &&
|
||||||
|
(instances[activeIndex].timelinesLookback = {
|
||||||
...instances[activeIndex].timelinesLookback,
|
...instances[activeIndex].timelinesLookback,
|
||||||
...action.payload
|
...action.payload
|
||||||
}
|
})
|
||||||
},
|
},
|
||||||
updateInstanceMePage: (
|
updateInstanceMePage: (
|
||||||
{ instances },
|
{ instances },
|
||||||
|
|
Loading…
Reference in New Issue