@@ -2,7 +2,6 @@ import React from 'react';
|
||||
import { StyleSheet } from 'react-native';
|
||||
import { createStackNavigator } from '@react-navigation/stack';
|
||||
import { GestureHandlerRootView } from 'react-native-gesture-handler';
|
||||
import { THEME_COLOR } from '@/CONSTANTS';
|
||||
import { t } from '@/localisation';
|
||||
import useDefaultStyles, { ColoredBlurView } from '@/components/Colors';
|
||||
import { StackParams } from '@/screens/types';
|
||||
@@ -24,7 +23,7 @@ function MusicStack() {
|
||||
return (
|
||||
<GestureHandlerRootView style={{ flex: 1 }}>
|
||||
<Stack.Navigator initialRouteName="RecentAlbums" screenOptions={{
|
||||
headerTintColor: THEME_COLOR,
|
||||
headerTintColor: defaultStyles.themeColor.color,
|
||||
headerTitleStyle: defaultStyles.stackHeader,
|
||||
cardStyle: defaultStyles.view,
|
||||
headerTransparent: true,
|
||||
|
||||
@@ -14,7 +14,6 @@ import { Text } from '@/components/Typography';
|
||||
import useDefaultStyles, { ColoredBlurView } from '@/components/Colors';
|
||||
import { useNavigation } from '@react-navigation/native';
|
||||
import { calculateProgressTranslation } from '@/components/Progresstrack';
|
||||
import { THEME_COLOR } from '@/CONSTANTS';
|
||||
import { NavigationProp } from '@/screens/types';
|
||||
import { ShadowWrapper } from '@/components/Shadow';
|
||||
import { useBottomTabBarHeight } from '@react-navigation/bottom-tabs';
|
||||
@@ -48,7 +47,6 @@ const ProgressTrack = styled(Animated.View)<{ stroke?: number; opacity?: number}
|
||||
left: 0;
|
||||
right: 0;
|
||||
height: ${(props) => props.stroke ? props.stroke + 'px' : '100%'};
|
||||
background-color: ${THEME_COLOR};
|
||||
opacity: ${(props) => props.opacity || 1};
|
||||
border-radius: 99px;
|
||||
`;
|
||||
@@ -191,12 +189,18 @@ function NowPlaying({ offset = 0 }: { offset?: number }) {
|
||||
<SelectActionButton />
|
||||
</ActionButton>
|
||||
<ProgressTrack
|
||||
style={{ transform: [{ translateX: bufferAnimation.current }]}}
|
||||
style={[
|
||||
{ transform: [{ translateX: bufferAnimation.current }]},
|
||||
defaultStyles.themeBackground,
|
||||
]}
|
||||
opacity={0.15}
|
||||
stroke={4}
|
||||
/>
|
||||
<ProgressTrack
|
||||
style={{ transform: [{ translateX: progressAnimation.current }]}}
|
||||
style={[
|
||||
{ transform: [{ translateX: progressAnimation.current }]},
|
||||
defaultStyles.themeBackground,
|
||||
]}
|
||||
stroke={4}
|
||||
/>
|
||||
</InnerContainer>
|
||||
|
||||
@@ -5,7 +5,7 @@ import { useNavigation } from '@react-navigation/native';
|
||||
import { differenceInDays } from 'date-fns';
|
||||
import { useAppDispatch, useTypedSelector } from '@/store';
|
||||
import { fetchAllAlbums } from '@/store/music/actions';
|
||||
import { ALBUM_CACHE_AMOUNT_OF_DAYS, THEME_COLOR } from '@/CONSTANTS';
|
||||
import { ALBUM_CACHE_AMOUNT_OF_DAYS } from '@/CONSTANTS';
|
||||
import AlbumImage from './components/AlbumImage';
|
||||
import { SectionArtistItem, SectionedArtist, selectArtists } from '@/store/music/selectors';
|
||||
import AlphabetScroller from '@/components/AlphabetScroller';
|
||||
@@ -92,7 +92,7 @@ const GeneratedArtistItem = React.memo(function GeneratedArtistItem(props: Gener
|
||||
numberOfLines={1}
|
||||
style={[
|
||||
defaultStyles.text,
|
||||
pressed && { color: THEME_COLOR },
|
||||
pressed && defaultStyles.themeColor,
|
||||
{ flexShrink: 1 }
|
||||
]}
|
||||
|
||||
@@ -201,7 +201,7 @@ const Artists: React.FC = () => {
|
||||
onRefresh={retrieveData}
|
||||
getItemLayout={(_, i) => {
|
||||
if (!(i in itemLayouts)) {
|
||||
console.log('COuLD NOT FIND LAYOUT ITEM', i, _);
|
||||
// console.log('COuLD NOT FIND LAYOUT ITEM', i, _);
|
||||
}
|
||||
return itemLayouts[i] ?? { length: 0, offset: 0, index: i };
|
||||
}}
|
||||
|
||||
@@ -4,7 +4,6 @@ import { useGetImage } from '@/utility/JellyfinApi';
|
||||
import styled, { css } from 'styled-components/native';
|
||||
import { useNavigation } from '@react-navigation/native';
|
||||
import { useAppDispatch, useTypedSelector } from '@/store';
|
||||
import { THEME_COLOR } from '@/CONSTANTS';
|
||||
import TouchableHandler from '@/components/TouchableHandler';
|
||||
import useCurrentTrack from '@/utility/useCurrentTrack';
|
||||
import TrackPlayer from 'react-native-track-player';
|
||||
@@ -32,7 +31,6 @@ const styles = StyleSheet.create({
|
||||
marginRight: 12
|
||||
},
|
||||
activeText: {
|
||||
color: THEME_COLOR,
|
||||
fontWeight: '500',
|
||||
},
|
||||
});
|
||||
@@ -153,13 +151,17 @@ const TrackListView: React.FC<TrackListViewProps> = ({
|
||||
>
|
||||
<TrackContainer
|
||||
isPlaying={currentTrack?.backendId === trackId || false}
|
||||
style={[defaultStyles.border, currentTrack?.backendId === trackId || false ? defaultStyles.activeBackground : null ]}
|
||||
style={[
|
||||
defaultStyles.border,
|
||||
currentTrack?.backendId === trackId ? defaultStyles.activeBackground : null
|
||||
]}
|
||||
>
|
||||
<Text
|
||||
style={[
|
||||
styles.index,
|
||||
{ opacity: 0.25 },
|
||||
currentTrack?.backendId === trackId && styles.activeText
|
||||
defaultStyles.textQuarterOpacity,
|
||||
currentTrack?.backendId === trackId && styles.activeText,
|
||||
currentTrack?.backendId === trackId && defaultStyles.themeColorQuarterOpacity,
|
||||
]}
|
||||
numberOfLines={1}
|
||||
>
|
||||
@@ -169,23 +171,29 @@ const TrackListView: React.FC<TrackListViewProps> = ({
|
||||
</Text>
|
||||
<View style={{ flexShrink: 1 }}>
|
||||
<Text
|
||||
style={{
|
||||
...currentTrack?.backendId === trackId && styles.activeText,
|
||||
flexShrink: 1,
|
||||
marginRight: 4,
|
||||
}}
|
||||
style={[
|
||||
currentTrack?.backendId === trackId && styles.activeText,
|
||||
currentTrack?.backendId === trackId && defaultStyles.themeColor,
|
||||
{
|
||||
flexShrink: 1,
|
||||
marginRight: 4,
|
||||
}
|
||||
]}
|
||||
numberOfLines={1}
|
||||
>
|
||||
{tracks[trackId]?.Name}
|
||||
</Text>
|
||||
{itemDisplayStyle === 'playlist' && (
|
||||
<Text
|
||||
style={{
|
||||
...currentTrack?.backendId === trackId && styles.activeText,
|
||||
flexShrink: 1,
|
||||
marginRight: 4,
|
||||
opacity:currentTrack?.backendId === trackId ? 0.5 : 0.25,
|
||||
}}
|
||||
style={[
|
||||
currentTrack?.backendId === trackId && styles.activeText,
|
||||
currentTrack?.backendId === trackId && defaultStyles.themeColor,
|
||||
{
|
||||
flexShrink: 1,
|
||||
marginRight: 4,
|
||||
opacity: currentTrack?.backendId === trackId ? 0.5 : 0.25,
|
||||
}
|
||||
]}
|
||||
numberOfLines={1}
|
||||
>
|
||||
{tracks[trackId]?.Artists.join(', ')}
|
||||
@@ -195,19 +203,26 @@ const TrackListView: React.FC<TrackListViewProps> = ({
|
||||
<View style={{ marginLeft: 'auto', flexDirection: 'row' }}>
|
||||
<Text
|
||||
style={[
|
||||
{ marginRight: 12, opacity: 0.25 },
|
||||
currentTrack?.backendId === trackId && styles.activeText
|
||||
{ marginRight: 12 },
|
||||
defaultStyles.textQuarterOpacity,
|
||||
currentTrack?.backendId === trackId && styles.activeText,
|
||||
currentTrack?.backendId === trackId && defaultStyles.themeColorQuarterOpacity,
|
||||
]}
|
||||
numberOfLines={1}
|
||||
>
|
||||
{ticksToDuration(tracks[trackId]?.RunTimeTicks || 0)}
|
||||
</Text>
|
||||
<DownloadIcon trackId={trackId} fill={currentTrack?.backendId === trackId ? `${THEME_COLOR}44` : undefined} />
|
||||
<DownloadIcon
|
||||
trackId={trackId}
|
||||
fill={currentTrack?.backendId === trackId ? defaultStyles.themeColorQuarterOpacity.color : undefined}
|
||||
/>
|
||||
</View>
|
||||
</TrackContainer>
|
||||
</TouchableHandler>
|
||||
)}
|
||||
<Text style={{ paddingTop: 24, paddingBottom: 12, textAlign: 'center', opacity: 0.5 }}>{t('total-duration')}{': '}{ticksToDuration(totalDuration)}</Text>
|
||||
<Text style={{ paddingTop: 24, paddingBottom: 12, textAlign: 'center', opacity: 0.5 }}>
|
||||
{t('total-duration')}{': '}{ticksToDuration(totalDuration)}
|
||||
</Text>
|
||||
<WrappableButtonRow style={{ marginTop: 24 }}>
|
||||
<WrappableButton
|
||||
icon={CloudDownArrow}
|
||||
|
||||
Reference in New Issue
Block a user