diff --git a/src/view/com/pager/TabBar.tsx b/src/view/com/pager/TabBar.tsx index e895eb73b8..16138e384c 100644 --- a/src/view/com/pager/TabBar.tsx +++ b/src/view/com/pager/TabBar.tsx @@ -2,7 +2,6 @@ import React, {useCallback, useEffect, useMemo, useRef, useState} from 'react' import {LayoutChangeEvent, ScrollView, StyleSheet, View} from 'react-native' import {usePalette} from '#/lib/hooks/usePalette' -import {useWebMediaQueries} from '#/lib/hooks/useWebMediaQueries' import {PressableWithHover} from '../util/PressableWithHover' import {Text} from '../util/text/Text' import {DraggableScrollView} from './DraggableScrollView' @@ -35,8 +34,6 @@ export function TabBar({ () => ({borderBottomColor: indicatorColor || pal.colors.link}), [indicatorColor, pal], ) - const {isDesktop, isTablet} = useWebMediaQueries() - const styles = isDesktop || isTablet ? desktopStyles : mobileStyles useEffect(() => { // On native, the primary interaction is swiping. @@ -45,7 +42,7 @@ export function TabBar({ let x = itemXs[selectedPage] || 0 x = Math.max(0, x - OFFSCREEN_ITEM_WIDTH) scrollElRef.current?.scrollTo({x}) - }, [scrollElRef, itemXs, selectedPage, styles]) + }, [scrollElRef, itemXs, selectedPage]) const onPressItem = useCallback( (index: number) => { @@ -95,7 +92,7 @@ export function TabBar({