fix PR II
This commit is contained in:
@@ -59,4 +59,4 @@ const ArtistDetailsView = ({ artistId }: RouteProps<ArtistDetailsViewProps>) =>
|
|||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
export default ArtistDetailsView;
|
export default ArtistDetailsView;
|
||||||
@@ -5,8 +5,8 @@ import { RouteProps, useNavigation } from '../Navigation';
|
|||||||
import API from '../API';
|
import API from '../API';
|
||||||
import CardGridCustom from '../components/CardGridCustom';
|
import CardGridCustom from '../components/CardGridCustom';
|
||||||
import SongCard from '../components/SongCard';
|
import SongCard from '../components/SongCard';
|
||||||
|
import { ImageBackground } from 'react-native';
|
||||||
const colorRange = ['#364fc7', '#5c940d', '#c92a2a', '#d6336c', '#20c997'];
|
import { LinearGradient } from 'expo-linear-gradient';
|
||||||
|
|
||||||
type GenreDetailsViewProps = {
|
type GenreDetailsViewProps = {
|
||||||
genreId: number;
|
genreId: number;
|
||||||
@@ -37,17 +37,13 @@ const GenreDetailsView = ({ genreId }: RouteProps<GenreDetailsViewProps>) => {
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<ScrollView>
|
<ScrollView>
|
||||||
<Box
|
<ImageBackground
|
||||||
size={'100%'}
|
style={{width : '100%', height: isMobileView ? 200 : 300}}
|
||||||
height={isMobileView ? 200 : 300}
|
source={{uri : API.getGenreIllustration(genreQuery.data.id)}}>
|
||||||
width={'100%'}
|
<LinearGradient
|
||||||
bg={{
|
colors={['#00000000', fadeColor]}
|
||||||
linearGradient: {
|
style={{height : '100%', width : '100%'}}/>
|
||||||
colors: [colorRange[Math.floor(Math.random() * 5)] ?? '#364fc7', fadeColor],
|
</ImageBackground>
|
||||||
start: [0, 0],
|
|
||||||
end: [0, 1],
|
|
||||||
},}}
|
|
||||||
/>
|
|
||||||
<Heading ml={3} fontSize={50}>{genreQuery.data.name}</Heading>
|
<Heading ml={3} fontSize={50}>{genreQuery.data.name}</Heading>
|
||||||
<Flex
|
<Flex
|
||||||
flexWrap="wrap"
|
flexWrap="wrap"
|
||||||
|
|||||||
Reference in New Issue
Block a user