mirror of
https://github.com/tooot-app/app
synced 2025-02-11 01:10:47 +01:00
commit
2211de5eb3
@ -4,7 +4,7 @@
|
|||||||
"native": "220102",
|
"native": "220102",
|
||||||
"major": 3,
|
"major": 3,
|
||||||
"minor": 2,
|
"minor": 2,
|
||||||
"patch": 1,
|
"patch": 2,
|
||||||
"expo": "44.0.0"
|
"expo": "44.0.0"
|
||||||
},
|
},
|
||||||
"description": "tooot app for Mastodon",
|
"description": "tooot app for Mastodon",
|
||||||
|
@ -33,7 +33,7 @@ dev()
|
|||||||
sentry()
|
sentry()
|
||||||
audio()
|
audio()
|
||||||
push()
|
push()
|
||||||
enableFreeze()
|
enableFreeze(true)
|
||||||
|
|
||||||
const App: React.FC = () => {
|
const App: React.FC = () => {
|
||||||
log('log', 'App', 'rendering App')
|
log('log', 'App', 'rendering App')
|
||||||
|
@ -190,16 +190,7 @@ const ComposePoll: React.FC = () => {
|
|||||||
title={t('content.root.footer.poll.expiration.heading')}
|
title={t('content.root.footer.poll.expiration.heading')}
|
||||||
content={t(`content.root.footer.poll.expiration.options.${expire}`)}
|
content={t(`content.root.footer.poll.expiration.options.${expire}`)}
|
||||||
onPress={() => {
|
onPress={() => {
|
||||||
// @ts-ignore
|
const expirations = [
|
||||||
const expirations: [
|
|
||||||
'300',
|
|
||||||
'1800',
|
|
||||||
'3600',
|
|
||||||
'21600',
|
|
||||||
'86400',
|
|
||||||
'259200',
|
|
||||||
'604800'
|
|
||||||
] = [
|
|
||||||
'300',
|
'300',
|
||||||
'1800',
|
'1800',
|
||||||
'3600',
|
'3600',
|
||||||
@ -220,16 +211,17 @@ const ComposePoll: React.FC = () => {
|
|||||||
),
|
),
|
||||||
t('content.root.footer.poll.expiration.options.cancel')
|
t('content.root.footer.poll.expiration.options.cancel')
|
||||||
],
|
],
|
||||||
cancelButtonIndex: 7
|
cancelButtonIndex: expirations.length
|
||||||
},
|
},
|
||||||
index => {
|
index => {
|
||||||
if (index && expirations.length < 7) {
|
if (index && index < expirations.length) {
|
||||||
analytics('compose_poll_expiration_press', {
|
analytics('compose_poll_expiration_press', {
|
||||||
current: expire,
|
current: expire,
|
||||||
new: expirations[index]
|
new: expirations[index]
|
||||||
})
|
})
|
||||||
composeDispatch({
|
composeDispatch({
|
||||||
type: 'poll',
|
type: 'poll',
|
||||||
|
// @ts-ignore
|
||||||
payload: { expire: expirations[index] }
|
payload: { expire: expirations[index] }
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
@ -102,6 +102,19 @@ const ScreenTabs = React.memo(
|
|||||||
)
|
)
|
||||||
const composeComponent = useCallback(() => null, [])
|
const composeComponent = useCallback(() => null, [])
|
||||||
|
|
||||||
|
const meListeners = useMemo(
|
||||||
|
() => ({
|
||||||
|
tabLongPress: () => {
|
||||||
|
haptics('Light')
|
||||||
|
//@ts-ignore
|
||||||
|
navigation.navigate('Tab-Me', { screen: 'Tab-Me-Root' })
|
||||||
|
//@ts-ignore
|
||||||
|
navigation.navigate('Tab-Me', { screen: 'Tab-Me-Switch' })
|
||||||
|
}
|
||||||
|
}),
|
||||||
|
[]
|
||||||
|
)
|
||||||
|
|
||||||
const previousTab = useSelector(getPreviousTab, () => true)
|
const previousTab = useSelector(getPreviousTab, () => true)
|
||||||
|
|
||||||
const versionUpdate = useSelector(getVersionUpdate)
|
const versionUpdate = useSelector(getVersionUpdate)
|
||||||
@ -128,7 +141,12 @@ const ScreenTabs = React.memo(
|
|||||||
listeners={composeListeners}
|
listeners={composeListeners}
|
||||||
/>
|
/>
|
||||||
<Tab.Screen name='Tab-Notifications' component={TabNotifications} />
|
<Tab.Screen name='Tab-Notifications' component={TabNotifications} />
|
||||||
<Tab.Screen name='Tab-Me' component={TabMe} options={tabMeOptions} />
|
<Tab.Screen
|
||||||
|
name='Tab-Me'
|
||||||
|
component={TabMe}
|
||||||
|
options={tabMeOptions}
|
||||||
|
listeners={meListeners}
|
||||||
|
/>
|
||||||
</Tab.Navigator>
|
</Tab.Navigator>
|
||||||
)
|
)
|
||||||
},
|
},
|
||||||
|
Loading…
x
Reference in New Issue
Block a user