diff --git a/components/Global/helpers/slider.tsx b/components/Global/helpers/slider.tsx index c41dcc7c..8272ba8f 100644 --- a/components/Global/helpers/slider.tsx +++ b/components/Global/helpers/slider.tsx @@ -11,11 +11,11 @@ interface SliderProps { const JellifySliderThumb = styled(Slider.Thumb, { backgroundColor: Colors.Primary, - borderColor: Colors.Background + borderColor: Colors.Background, }) const JellifySliderTrack = styled(Slider.Track, { - backgroundColor: Colors.Secondary + backgroundColor: Colors.Borders }); const JellifyActiveSliderTrack = styled(Slider.TrackActive, { diff --git a/components/Item/component.tsx b/components/Item/component.tsx deleted file mode 100644 index e69de29b..00000000 diff --git a/components/ItemDetail/component.tsx b/components/ItemDetail/component.tsx new file mode 100644 index 00000000..c7ef0c15 --- /dev/null +++ b/components/ItemDetail/component.tsx @@ -0,0 +1,50 @@ +import { BaseItemDto } from "@jellyfin/sdk/lib/generated-client/models"; +import { NativeStackNavigationProp } from "@react-navigation/native-stack"; +import { SafeAreaView } from "react-native-safe-area-context"; +import { StackParamList } from "../types"; +import TrackOptions from "./helpers/TrackOptions"; +import { View } from "tamagui"; + +export default function ItemDetail({ + item, + navigation +} : { + item: BaseItemDto, + navigation: NativeStackNavigationProp +}) : React.JSX.Element { + + let options: React.JSX.Element | undefined = undefined; + + switch (item.Type) { + case "Audio": { + options = TrackOptions({ item, navigation }); + break; + } + + case "MusicAlbum" : { + + break; + } + + case "MusicArtist" : { + + break; + } + + case "Playlist" : { + + break; + } + + default : { + break; + } + } + + return ( + + + { options ?? } + + ) +} \ No newline at end of file diff --git a/components/ItemDetail/helpers/TrackOptions.tsx b/components/ItemDetail/helpers/TrackOptions.tsx new file mode 100644 index 00000000..2b54674a --- /dev/null +++ b/components/ItemDetail/helpers/TrackOptions.tsx @@ -0,0 +1,19 @@ +import { StackParamList } from "@/components/types"; +import { BaseItemDto } from "@jellyfin/sdk/lib/generated-client/models"; +import { NativeStackNavigationProp } from "@react-navigation/native-stack"; +import { View } from "tamagui"; + +export default function TrackOptions({ + item, + navigation +} : { + item: BaseItemDto, + navigation: NativeStackNavigationProp +}) : React.JSX.Element { + + return ( + + + + ) +} \ No newline at end of file diff --git a/components/Player/component.tsx b/components/Player/component.tsx index a7f904e9..ee65ff34 100644 --- a/components/Player/component.tsx +++ b/components/Player/component.tsx @@ -3,6 +3,7 @@ import { createNativeStackNavigator, NativeStackNavigationProp } from "@react-na import { StackParamList } from "../types"; import PlayerScreen from "./screens"; import Queue from "./screens/queue"; +import DetailsScreen from "./screens/details"; export const PlayerStack = createNativeStackNavigator(); @@ -30,6 +31,14 @@ export default function Player({ navigation }: { navigation: NativeStackNavigati }} /> + + ); } diff --git a/components/Player/screens/details.tsx b/components/Player/screens/details.tsx new file mode 100644 index 00000000..f52cac0e --- /dev/null +++ b/components/Player/screens/details.tsx @@ -0,0 +1,20 @@ +import ItemDetail from "@/components/ItemDetail/component"; +import { StackParamList } from "@/components/types"; +import { RouteProp } from "@react-navigation/native"; +import { NativeStackNavigationProp } from "@react-navigation/native-stack"; +import React from "react"; + +export default function DetailsScreen({ + route, + navigation +} : { + route: RouteProp, + navigation: NativeStackNavigationProp +}) : React.JSX.Element { + return ( + + ) +} \ No newline at end of file diff --git a/components/Player/screens/index.tsx b/components/Player/screens/index.tsx index 4cb344cd..722a373b 100644 --- a/components/Player/screens/index.tsx +++ b/components/Player/screens/index.tsx @@ -132,6 +132,17 @@ export default function PlayerScreen({ navigation }: { navigation: NativeStackNa flex={1} > {/* Buttons for favorites, song menu go here */} + + { + navigation.navigate("Details", { + item: nowPlaying!.item + }); + }} + /> + setNowPlayingIsFavorite(!nowPlayingIsFavorite)} diff --git a/components/theme.ts b/components/theme.ts index 1f0cd57d..4bd4d90e 100644 --- a/components/theme.ts +++ b/components/theme.ts @@ -5,7 +5,7 @@ export const JellifyDarkTheme = { colors: { ...DarkTheme.colors, card: Colors.Background, - border: Colors.Secondary, + border: Colors.Borders, background: Colors.Background, primary: Colors.Primary, }, diff --git a/enums/colors.ts b/enums/colors.ts index c0232fd1..1c5367c9 100644 --- a/enums/colors.ts +++ b/enums/colors.ts @@ -1,7 +1,9 @@ export enum Colors { - White = "#ffffff", - Primary = "#cc2f71", - Secondary = "#100538", - Black = "#000000", - Background = "#070217" + Primary = "#cc2f71", // Telemagenta + Secondary = "#514C63", // English Violet + Borders = "#100538", // Russian Violet + Background = "#070217", // Rich Black + + White = "#ffffff", // Uh-huh + Black = "#000000", // Yep } \ No newline at end of file