From 750920010b3660144184ccc6b1dcc40eb85fac18 Mon Sep 17 00:00:00 2001 From: Joshua Higgins Date: Fri, 20 Nov 2026 00:53:13 -0500 Subject: [PATCH 1/2] Revert "fix(mobile): put the profile button inline with the iOS screen title (#135)" This reverts commit 3c221330c2ff371bc6eb91cc6d22b5eec4d0c8ac. --- apps/mobile/app/(app)/(tabs)/home/_layout.tsx | 17 +++++--- apps/mobile/app/(app)/(tabs)/home/index.tsx | 12 +----- .../app/(app)/(tabs)/library/_layout.tsx | 17 +++++--- .../mobile/app/(app)/(tabs)/library/index.tsx | 3 -- .../app/(app)/(tabs)/search/_layout.tsx | 17 +++++--- apps/mobile/components/media-cards.tsx | 6 +-- apps/mobile/components/screen-title.tsx | 41 +++++++------------ apps/mobile/components/search-results.tsx | 14 +------ apps/mobile/components/skeletons.tsx | 31 +++----------- apps/mobile/components/tablet-media-grid.tsx | 4 -- apps/mobile/lib/navigation.ts | 5 --- 11 files changed, 60 insertions(+), 107 deletions(-) diff --git a/apps/mobile/app/(app)/(tabs)/home/_layout.tsx b/apps/mobile/app/(app)/(tabs)/home/_layout.tsx index db744ab..7d17397 100644 --- a/apps/mobile/app/(app)/(tabs)/home/_layout.tsx +++ b/apps/mobile/app/(app)/(tabs)/home/_layout.tsx @@ -4,7 +4,6 @@ import { Stack } from "expo-router" import { ProfileHeaderButton } from "@/components/profile-header-button" import { inlineTitleOptions, - showHeaderProfile, tabStackScreenTitles, useStackScreenOptions, } from "@/lib/navigation" @@ -23,10 +22,18 @@ export default function HomeLayout() { ...baseOptions, ...inlineTitleOptions, title: tabStackScreenTitles[route.name] ?? "Home", - // iOS shows the profile button inline with the screen title instead. - headerRight: showHeaderProfile(route.name) - ? () => - : undefined, + headerRight: + route.name === "index" ? () => : undefined, + unstable_headerRightItems: + route.name === "index" + ? () => [ + { + type: "custom", + element: , + hidesSharedBackground: true, + }, + ] + : undefined, })} /> ) diff --git a/apps/mobile/app/(app)/(tabs)/home/index.tsx b/apps/mobile/app/(app)/(tabs)/home/index.tsx index 3513bc4..12c5354 100644 --- a/apps/mobile/app/(app)/(tabs)/home/index.tsx +++ b/apps/mobile/app/(app)/(tabs)/home/index.tsx @@ -5,7 +5,6 @@ import Animated from "react-native-reanimated" import { ContentCarousel } from "@/components/media-cards" import { HomeSkeleton } from "@/components/skeletons" import { ScreenTitle, useScreenTitleScroll } from "@/components/screen-title" -import { ProfileHeaderButton } from "@/components/profile-header-button" import { tabContentBottomInset } from "@/components/player" import { useCachedPaginatedQuery } from "@/hooks/use-cached-query" import { api } from "@otunes/convex/_generated/api" @@ -57,9 +56,7 @@ export default function HomeScreen() { (result) => result.status === "LoadingFirstPage" && !result.isCached ) if (isLoading) { - return ( - } /> - ) + return } const added = recentlyAdded.results.slice(0, CAROUSEL_ITEM_LIMIT) @@ -76,12 +73,7 @@ export default function HomeScreen() { ]} contentInsetAdjustmentBehavior="automatic" > - } - style={styles.title} - /> + ) diff --git a/apps/mobile/app/(app)/(tabs)/library/_layout.tsx b/apps/mobile/app/(app)/(tabs)/library/_layout.tsx index b4a0aad..b669a38 100644 --- a/apps/mobile/app/(app)/(tabs)/library/_layout.tsx +++ b/apps/mobile/app/(app)/(tabs)/library/_layout.tsx @@ -5,7 +5,6 @@ import { Stack } from "expo-router" import { ProfileHeaderButton } from "@/components/profile-header-button" import { inlineTitleOptions, - showHeaderProfile, tabStackScreenTitles, useStackScreenOptions, } from "@/lib/navigation" @@ -27,10 +26,18 @@ export default function LibraryLayout() { title: tabStackScreenTitles[route.name] ?? (tabletLayout ? "Recently Added" : "Library"), - // iOS shows the profile button inline with the screen title instead. - headerRight: showHeaderProfile(route.name) - ? () => - : undefined, + headerRight: + route.name === "index" ? () => : undefined, + unstable_headerRightItems: + route.name === "index" + ? () => [ + { + type: "custom", + element: , + hidesSharedBackground: true, + }, + ] + : undefined, })} /> ) diff --git a/apps/mobile/app/(app)/(tabs)/library/index.tsx b/apps/mobile/app/(app)/(tabs)/library/index.tsx index 120b6dd..ac52002 100644 --- a/apps/mobile/app/(app)/(tabs)/library/index.tsx +++ b/apps/mobile/app/(app)/(tabs)/library/index.tsx @@ -8,7 +8,6 @@ import { Ionicons } from "@expo/vector-icons" import { MediaGridList } from "@/components/media-cards" import { tabContentBottomInset } from "@/components/player" import { MediaGridSkeleton } from "@/components/skeletons" -import { ProfileHeaderButton } from "@/components/profile-header-button" import { useCachedPaginatedQuery } from "@/hooks/use-cached-query" import { useAppNavigation } from "@/lib/app-navigation" import { api } from "@otunes/convex/_generated/api" @@ -129,7 +128,6 @@ export default function LibraryScreen() { return ( } contentInset={false} header={listHeader} /> @@ -139,7 +137,6 @@ export default function LibraryScreen() { return ( } content={results} paddingBottom={tabContentBottomInset} contentInset={false} diff --git a/apps/mobile/app/(app)/(tabs)/search/_layout.tsx b/apps/mobile/app/(app)/(tabs)/search/_layout.tsx index 79f8928..688b642 100644 --- a/apps/mobile/app/(app)/(tabs)/search/_layout.tsx +++ b/apps/mobile/app/(app)/(tabs)/search/_layout.tsx @@ -4,7 +4,6 @@ import { Stack } from "expo-router" import { ProfileHeaderButton } from "@/components/profile-header-button" import { inlineTitleOptions, - showHeaderProfile, tabStackScreenTitles, useStackScreenOptions, } from "@/lib/navigation" @@ -23,10 +22,18 @@ export default function SearchLayout() { ...baseOptions, ...inlineTitleOptions, title: tabStackScreenTitles[route.name] ?? "Search", - // iOS shows the profile button inline with the screen title instead. - headerRight: showHeaderProfile(route.name) - ? () => - : undefined, + headerRight: + route.name === "index" ? () => : undefined, + unstable_headerRightItems: + route.name === "index" + ? () => [ + { + type: "custom", + element: , + hidesSharedBackground: true, + }, + ] + : undefined, })} /> ) diff --git a/apps/mobile/components/media-cards.tsx b/apps/mobile/components/media-cards.tsx index 1d7a999..418a6f9 100644 --- a/apps/mobile/components/media-cards.tsx +++ b/apps/mobile/components/media-cards.tsx @@ -7,7 +7,7 @@ import { MusicEntityView } from "@/components/music-entity-view" import { ScreenTitle, useScreenTitleScroll } from "@/components/screen-title" import { Link } from "expo-router" import { Ionicons } from "@expo/vector-icons" -import { memo, useCallback, type ReactElement, type ReactNode } from "react" +import { memo, useCallback, type ReactElement } from "react" import { FlatList, Platform, @@ -302,7 +302,6 @@ export function MediaGridList({ ListHeaderComponent, contentInset = true, title, - titleAccessory, }: { content: MediaItem[] paddingBottom: number @@ -311,7 +310,6 @@ export function MediaGridList({ contentInset?: boolean /** iOS `ScreenTitle` shown above the grid; it replaces the top inset. */ title?: string - titleAccessory?: ReactNode }) { const tabletLayout = useTabletLayout() const { columns, cardWidth, onLayout, horizontalPadding, gap } = @@ -336,7 +334,6 @@ export function MediaGridList({ ListHeaderComponent={ListHeaderComponent} contentInset={contentInset} title={title} - titleAccessory={titleAccessory} renderCard={renderTabletCard} /> ) @@ -347,7 +344,6 @@ export function MediaGridList({ diff --git a/apps/mobile/components/screen-title.tsx b/apps/mobile/components/screen-title.tsx index b98d17e..99d814e 100644 --- a/apps/mobile/components/screen-title.tsx +++ b/apps/mobile/components/screen-title.tsx @@ -1,12 +1,11 @@ import { useHeaderHeight } from "expo-router/react-navigation" -import type { Component, ReactNode } from "react" +import type { Component } from "react" import { Platform, StyleSheet, - Text, type ScrollViewInstance, type StyleProp, - type ViewStyle, + type TextStyle, } from "react-native" import Animated, { useAnimatedRef, @@ -34,20 +33,17 @@ export function useScreenTitleScroll< * iOS screen title rendered as the first item of a screen's scroll content, * in place of the native large title (Apple Music style): it scrolls away * with the content, never collapses into the bar, and stays put on - * pull-down. `accessory` (e.g. the profile button) sits on the same row and - * scrolls with it. Android keeps its native header, so this renders nothing. + * pull-down. Android keeps its native header title, so this renders nothing. */ export function ScreenTitle({ title, scrollY, - accessory, style, }: { title: string /** From `useScreenTitleScroll`; omit for screens that never scroll. */ scrollY?: SharedValue - accessory?: ReactNode - style?: StyleProp + style?: StyleProp }) { const colors = useThemeColors() // At rest the scroll offset is minus the automatic header inset, so any @@ -64,34 +60,25 @@ export function ScreenTitle({ if (Platform.OS !== "ios") return null return ( - - - {title} - - {accessory} - + + {title} + ) } // Matches UIKit's large title metrics: 34pt bold in a 52pt tall area. const styles = StyleSheet.create({ - row: { - flexDirection: "row", - alignItems: "center", - gap: spacing.md, - paddingHorizontal: spacing.lg, - paddingTop: 3, - paddingBottom: 8, - }, title: { - flex: 1, fontSize: 34, lineHeight: 41, fontWeight: "700", letterSpacing: 0.37, + paddingHorizontal: spacing.lg, + paddingTop: 3, + paddingBottom: 8, }, }) diff --git a/apps/mobile/components/search-results.tsx b/apps/mobile/components/search-results.tsx index 6a53665..d81d92e 100644 --- a/apps/mobile/components/search-results.tsx +++ b/apps/mobile/components/search-results.tsx @@ -9,7 +9,6 @@ import { import Animated from "react-native-reanimated" import { ContentCarousel } from "@/components/media-cards" -import { ProfileHeaderButton } from "@/components/profile-header-button" import { ScreenTitle, useScreenTitleScroll } from "@/components/screen-title" import type { MediaAction } from "@/components/media-context-menu" import { tabContentBottomInset, SongListRow } from "@/components/player" @@ -87,12 +86,7 @@ function SearchResultsBody({ ) if (isSearching) { - return ( - } - /> - ) + return } return ( @@ -107,11 +101,7 @@ function SearchResultsBody({ keyboardShouldPersistTaps="handled" ListHeaderComponent={ <> - } - /> + {hasQuery && !hasResults ? ( - {title ? : null} + {title ? : null} ) @@ -245,7 +243,6 @@ export function MediaGridSkeleton({ contentInset = true, header, title, - titleAccessory, }: { items?: number contentInset?: boolean @@ -253,7 +250,6 @@ export function MediaGridSkeleton({ header?: ReactNode /** The loaded list's `ScreenTitle`, which replaces its top inset. */ title?: string - titleAccessory?: ReactNode }) { return ( @@ -263,7 +259,7 @@ export function MediaGridSkeleton({ header={ title ? ( <> - + {header} ) : ( @@ -275,18 +271,11 @@ export function MediaGridSkeleton({ ) } -function MediaGridTitle({ - title, - accessory, -}: { - title: string - accessory?: ReactNode -}) { +function MediaGridTitle({ title }: { title: string }) { const { horizontalPadding } = useMediaGridLayout() return ( ) @@ -305,21 +294,11 @@ export function CarouselSkeleton() { ) } -export function HomeSkeleton({ - title, - titleAccessory, -}: { - title: string - titleAccessory?: ReactNode -}) { +export function HomeSkeleton({ title }: { title: string }) { return ( - + diff --git a/apps/mobile/components/tablet-media-grid.tsx b/apps/mobile/components/tablet-media-grid.tsx index f4182ca..e4be1f8 100644 --- a/apps/mobile/components/tablet-media-grid.tsx +++ b/apps/mobile/components/tablet-media-grid.tsx @@ -4,7 +4,6 @@ import { useRef, useState, type ReactElement, - type ReactNode, } from "react" import { type ScrollViewInstance, @@ -32,7 +31,6 @@ type GridProps = { contentInset?: boolean /** iOS `ScreenTitle` shown above the grid; it replaces the top inset. */ title?: string - titleAccessory?: ReactNode renderCard: (item: MediaItem, width: number) => ReactElement } @@ -47,7 +45,6 @@ export function TabletMediaGrid({ ListHeaderComponent, contentInset = true, title, - titleAccessory, renderCard, }: GridProps) { const colors = useThemeColors() @@ -129,7 +126,6 @@ export function TabletMediaGrid({ ) : null} diff --git a/apps/mobile/lib/navigation.ts b/apps/mobile/lib/navigation.ts index 111e442..bf29cec 100644 --- a/apps/mobile/lib/navigation.ts +++ b/apps/mobile/lib/navigation.ts @@ -24,11 +24,6 @@ export const tabStackScreenTitles: Record = { export const inlineTitleOptions: StackScreenOptions = Platform.OS === "ios" ? { headerTitleStyle: { color: "transparent" } } : {} -/** Tab roots show the profile button in the header, except on iOS where `ScreenTitle` holds it. */ -export function showHeaderProfile(routeName: string) { - return routeName === "index" && Platform.OS !== "ios" -} - export function useStackScreenOptions( overrides?: StackScreenOptions ): StackScreenOptions { -- 2.54.1 From 92ba14f4ffa344bc2b4b318c68206c249921619d Mon Sep 17 00:00:00 2001 From: Joshua Higgins Date: Fri, 20 Nov 2026 00:53:13 -0500 Subject: [PATCH 2/2] Revert "feat(mobile): scroll-away inline screen titles on iOS (#129)" This reverts commit 249def86a09f0624a02e197e320de0d520f1cdcc. --- .../_layout.tsx | 7 +- apps/mobile/app/(app)/(tabs)/home/_layout.tsx | 7 +- .../app/(app)/(tabs)/home/browse/albums.tsx | 3 +- .../app/(app)/(tabs)/home/browse/artists.tsx | 12 +-- .../(app)/(tabs)/home/browse/playlists.tsx | 12 ++- .../app/(app)/(tabs)/home/browse/songs.tsx | 16 +--- .../app/(app)/(tabs)/home/downloads/index.tsx | 20 +---- .../app/(app)/(tabs)/home/downloads/other.tsx | 58 ++++++------- apps/mobile/app/(app)/(tabs)/home/index.tsx | 20 +---- .../app/(app)/(tabs)/home/recently-added.tsx | 3 +- .../app/(app)/(tabs)/home/recently-played.tsx | 3 +- .../app/(app)/(tabs)/library/_layout.tsx | 7 +- .../mobile/app/(app)/(tabs)/library/index.tsx | 10 +-- .../app/(app)/(tabs)/search/_layout.tsx | 7 +- apps/mobile/app/(app)/(tabs)/search/index.tsx | 2 +- apps/mobile/components/media-cards.tsx | 27 +----- apps/mobile/components/screen-title.tsx | 84 ------------------- apps/mobile/components/search-results.tsx | 35 +++----- apps/mobile/components/skeletons.tsx | 54 ++---------- apps/mobile/components/tablet-media-grid.tsx | 25 ++---- apps/mobile/lib/navigation.ts | 9 +- 21 files changed, 78 insertions(+), 343 deletions(-) delete mode 100644 apps/mobile/components/screen-title.tsx diff --git a/apps/mobile/app/(app)/(tabs)/(albums,artists,songs,playlists,favorites,recent,downloads)/_layout.tsx b/apps/mobile/app/(app)/(tabs)/(albums,artists,songs,playlists,favorites,recent,downloads)/_layout.tsx index 917c410..9453ea3 100644 --- a/apps/mobile/app/(app)/(tabs)/(albums,artists,songs,playlists,favorites,recent,downloads)/_layout.tsx +++ b/apps/mobile/app/(app)/(tabs)/(albums,artists,songs,playlists,favorites,recent,downloads)/_layout.tsx @@ -1,11 +1,7 @@ import { Stack } from "expo-router" import { renderTabScreenContent } from "@/components/tab-screen-content" -import { - inlineTitleOptions, - tabStackScreenTitles, - useStackScreenOptions, -} from "@/lib/navigation" +import { useStackScreenOptions, tabStackScreenTitles } from "@/lib/navigation" import { tabletSections, TabletSectionContext } from "@/lib/tablet-navigation" export default function TabletSectionLayout({ segment }: { segment: string }) { @@ -18,7 +14,6 @@ export default function TabletSectionLayout({ segment }: { segment: string }) { screenLayout={renderTabScreenContent} screenOptions={({ route }) => ({ ...options, - ...inlineTitleOptions, title: route.name === "index" ? section?.title diff --git a/apps/mobile/app/(app)/(tabs)/home/_layout.tsx b/apps/mobile/app/(app)/(tabs)/home/_layout.tsx index 7d17397..75da6ca 100644 --- a/apps/mobile/app/(app)/(tabs)/home/_layout.tsx +++ b/apps/mobile/app/(app)/(tabs)/home/_layout.tsx @@ -2,11 +2,7 @@ import { renderTabScreenContent } from "@/components/tab-screen-content" import { Stack } from "expo-router" import { ProfileHeaderButton } from "@/components/profile-header-button" -import { - inlineTitleOptions, - tabStackScreenTitles, - useStackScreenOptions, -} from "@/lib/navigation" +import { tabStackScreenTitles, useStackScreenOptions } from "@/lib/navigation" export const unstable_settings = { anchor: "index", @@ -20,7 +16,6 @@ export default function HomeLayout() { screenLayout={renderTabScreenContent} screenOptions={({ route }) => ({ ...baseOptions, - ...inlineTitleOptions, title: tabStackScreenTitles[route.name] ?? "Home", headerRight: route.name === "index" ? () => : undefined, diff --git a/apps/mobile/app/(app)/(tabs)/home/browse/albums.tsx b/apps/mobile/app/(app)/(tabs)/home/browse/albums.tsx index b1cae32..21da78d 100644 --- a/apps/mobile/app/(app)/(tabs)/home/browse/albums.tsx +++ b/apps/mobile/app/(app)/(tabs)/home/browse/albums.tsx @@ -53,7 +53,7 @@ export default function AlbumsScreen() { return ( <> {searchBar} - + ) } @@ -63,7 +63,6 @@ export default function AlbumsScreen() { {searchBar} { diff --git a/apps/mobile/app/(app)/(tabs)/home/browse/artists.tsx b/apps/mobile/app/(app)/(tabs)/home/browse/artists.tsx index ae5b13d..b83ea1f 100644 --- a/apps/mobile/app/(app)/(tabs)/home/browse/artists.tsx +++ b/apps/mobile/app/(app)/(tabs)/home/browse/artists.tsx @@ -2,13 +2,12 @@ import { Ionicons } from "@expo/vector-icons" import { Stack } from "expo-router" import { memo, useCallback } from "react" import { - type FlatList, + FlatList, Pressable, StyleSheet, Text, type ListRenderItemInfo, } from "react-native" -import Animated from "react-native-reanimated" import { MediaContextMenu, @@ -16,7 +15,6 @@ import { } from "@/components/media-context-menu" import { CoverImage } from "@/components/cover-image" import { ArtistListSkeleton } from "@/components/skeletons" -import { ScreenTitle, useScreenTitleScroll } from "@/components/screen-title" import { contentBottomInset } from "@/components/player" import { useServerConfig } from "@/contexts/server-config" import { @@ -35,7 +33,6 @@ import { spacing, useThemeColors } from "@/lib/theme" const PAGE_SIZE = 50 export default function ArtistsScreen() { - const { ref, scrollY } = useScreenTitleScroll>() const { push } = useAppNavigation() const colors = useThemeColors() const { config } = useServerConfig() @@ -97,7 +94,7 @@ export default function ArtistsScreen() { return ( <> {searchBar} - + ) } @@ -106,11 +103,8 @@ export default function ArtistsScreen() { <> {searchBar} - } data={artists} keyExtractor={artistKey} renderItem={renderItem} diff --git a/apps/mobile/app/(app)/(tabs)/home/browse/playlists.tsx b/apps/mobile/app/(app)/(tabs)/home/browse/playlists.tsx index ca36163..d8f2aab 100644 --- a/apps/mobile/app/(app)/(tabs)/home/browse/playlists.tsx +++ b/apps/mobile/app/(app)/(tabs)/home/browse/playlists.tsx @@ -1,4 +1,3 @@ -import { useContext } from "react" import { Pressable } from "react-native" import { MediaGridList } from "@/components/media-cards" @@ -11,20 +10,19 @@ import { Ionicons } from "@expo/vector-icons" import { Stack } from "expo-router" import { SymbolView } from "expo-symbols" import { useAddToPlaylist } from "@/contexts/add-to-playlist" -import { TabletSectionContext } from "@/lib/tablet-navigation" export default function PlaylistsTabScreen() { const colors = useThemeColors() const playlists = useCachedQuery(api.playlists.listAllPlaylists) const { openCreatePlaylist } = useAddToPlaylist() - const title = useContext(TabletSectionContext)?.title ?? "Playlists" if (playlists === undefined) { return ( <> ( - + ) } @@ -49,7 +47,8 @@ export default function PlaylistsTabScreen() { <> ( diff --git a/apps/mobile/app/(app)/(tabs)/home/browse/songs.tsx b/apps/mobile/app/(app)/(tabs)/home/browse/songs.tsx index 15065ca..204c67a 100644 --- a/apps/mobile/app/(app)/(tabs)/home/browse/songs.tsx +++ b/apps/mobile/app/(app)/(tabs)/home/browse/songs.tsx @@ -1,16 +1,10 @@ import { Stack } from "expo-router" import { useCallback, useState } from "react" -import { - type FlatList, - StyleSheet, - type ListRenderItemInfo, -} from "react-native" -import Animated from "react-native-reanimated" +import { FlatList, StyleSheet, type ListRenderItemInfo } from "react-native" import type { MediaAction } from "@/components/media-context-menu" import { contentBottomInset, SongListRow } from "@/components/player" import { SongListSkeleton } from "@/components/skeletons" -import { ScreenTitle, useScreenTitleScroll } from "@/components/screen-title" import { useFavorites } from "@/contexts/favorites" import { usePlaybackActions } from "@/contexts/playback" import { @@ -26,7 +20,6 @@ import { longListProps } from "@/lib/list" const PAGE_SIZE = 50 export default function SongsScreen() { - const { ref, scrollY } = useScreenTitleScroll>() const { playFromLibrarySong } = usePlaybackActions() const { isSongFavorite } = useFavorites() const { handleSongAction } = useMediaMenuActions() @@ -94,7 +87,7 @@ export default function SongsScreen() { return ( <> {searchBar} - + ) } @@ -103,11 +96,8 @@ export default function SongsScreen() { <> {searchBar} - } data={songs} keyExtractor={songKey} renderItem={renderItem} diff --git a/apps/mobile/app/(app)/(tabs)/home/downloads/index.tsx b/apps/mobile/app/(app)/(tabs)/home/downloads/index.tsx index f19f8f7..5880bdc 100644 --- a/apps/mobile/app/(app)/(tabs)/home/downloads/index.tsx +++ b/apps/mobile/app/(app)/(tabs)/home/downloads/index.tsx @@ -1,6 +1,6 @@ import { useMemo } from "react" import { - type FlatList, + FlatList, Pressable, StyleSheet, Text, @@ -8,10 +8,8 @@ import { type ListRenderItemInfo, } from "react-native" import { Stack } from "expo-router" -import Animated from "react-native-reanimated" import { CoverImage } from "@/components/cover-image" -import { ScreenTitle, useScreenTitleScroll } from "@/components/screen-title" import { tabContentBottomInset } from "@/components/player" import { FAVORITES_DOWNLOAD_ID, @@ -55,7 +53,6 @@ export default function DownloadsScreen() { const { push } = useAppNavigation() const { columns, cardWidth, onLayout, horizontalPadding, gap } = useMediaGridLayout() - const { ref, scrollY } = useScreenTitleScroll>() const cards = useMemo(() => { if (!queue) return [] @@ -138,10 +135,8 @@ export default function DownloadsScreen() { return ( <> - - + 1 ? { gap } : undefined} contentInsetAdjustmentBehavior="automatic" - ListHeaderComponent={ - - } ListEmptyComponent={ diff --git a/apps/mobile/app/(app)/(tabs)/home/downloads/other.tsx b/apps/mobile/app/(app)/(tabs)/home/downloads/other.tsx index 1713185..80599f2 100644 --- a/apps/mobile/app/(app)/(tabs)/home/downloads/other.tsx +++ b/apps/mobile/app/(app)/(tabs)/home/downloads/other.tsx @@ -1,17 +1,15 @@ import { useCallback, useMemo } from "react" import { - type FlatList, + FlatList, Pressable, StyleSheet, Text, View, type ListRenderItemInfo, } from "react-native" -import Animated from "react-native-reanimated" import { Ionicons } from "@expo/vector-icons" import { Stack } from "expo-router" -import { ScreenTitle, useScreenTitleScroll } from "@/components/screen-title" import { useSwipeRowGroup } from "@/components/ios-swipe-to-remove-row" import type { MediaAction } from "@/components/media-context-menu" import { contentBottomInset, SongListRow } from "@/components/player" @@ -54,7 +52,6 @@ export default function OtherDownloadsScreen() { const { isSongFavorite } = useFavorites() const { handleSongAction } = useMediaMenuActions() const swipeGroup = useSwipeRowGroup() - const { ref, scrollY } = useScreenTitleScroll>() const handlePlaySong = useCallback( (song: BrowseSong) => void playFromSong(song.id, playableIds, PLAY_ORIGIN), @@ -93,11 +90,11 @@ export default function OtherDownloadsScreen() { return ( <> - - + song.id} renderItem={renderItem} @@ -106,32 +103,25 @@ export default function OtherDownloadsScreen() { contentInsetAdjustmentBehavior="automatic" onScrollBeginDrag={swipeGroup.closeOpenRow} ListHeaderComponent={ - <> - - {songs.length > 0 ? ( - -