additional context menu actuation

fix maestro
This commit is contained in:
Violet Caulfield
2025-08-15 22:27:57 -05:00
parent f184335f63
commit cb4f1c6acd
4 changed files with 16 additions and 2 deletions

View File

@@ -8,6 +8,7 @@ import Animated, { useAnimatedScrollHandler } from 'react-native-reanimated'
import { ActivityIndicator } from 'react-native'
import { useSafeAreaFrame } from 'react-native-safe-area-context'
import { getToken } from 'tamagui'
import navigationRef from '../../../navigation'
export default function Albums({
route,
navigation,
@@ -77,6 +78,12 @@ export default function Albums({
album,
})
}}
onLongPress={() => {
navigationRef.navigate('Context', {
item: album,
navigation,
})
}}
/>
)}
onScroll={scrollHandler}

View File

@@ -6,6 +6,7 @@ import { Text } from '../Global/helpers/text'
import { useArtistContext } from '../../providers/Artist'
import Animated, { useAnimatedScrollHandler } from 'react-native-reanimated'
import { ActivityIndicator } from 'react-native'
import navigationRef from '../../../navigation'
export default function SimilarArtists(): React.JSX.Element {
const navigation = useNavigation<NativeStackNavigationProp<BaseStackParamList>>()
@@ -35,6 +36,12 @@ export default function SimilarArtists(): React.JSX.Element {
artist,
})
}}
onLongPress={() => {
navigationRef.navigate('Context', {
item: artist,
navigation,
})
}}
/>
)}
ListEmptyComponent={

View File

@@ -49,7 +49,6 @@ export default function LibraryStack({ route, navigation }: LibraryTabProps): Re
name='Album'
component={AlbumScreen}
options={({ route }) => ({
headerShown: false,
title: route.params.album.Name ?? 'Untitled Album',
headerTitleStyle: {
color: theme.background.val,
@@ -61,7 +60,6 @@ export default function LibraryStack({ route, navigation }: LibraryTabProps): Re
name='Playlist'
component={PlaylistScreen}
options={({ route }) => ({
headerShown: false,
title: route.params.playlist.Name ?? 'Untitled Playlist',
headerTitleStyle: {
color: theme.background.val,

View File

@@ -12,6 +12,7 @@ import LibraryStack from '../Library'
import InternetConnectionWatcher from '../../components/Network/internetConnectionWatcher'
import TabParamList from './types'
import { TabProps } from '../types'
import { Platform } from 'react-native'
const Tab = createBottomTabNavigator<TabParamList>()
@@ -21,6 +22,7 @@ export default function Tabs({ route, navigation }: TabProps): React.JSX.Element
return (
<Tab.Navigator
detachInactiveScreens={Platform.OS !== 'ios'} // Temp fix for iOS where screens are detaching
initialRouteName={route.params?.screen ?? 'HomeTab'}
screenOptions={{
animation: 'shift',