impl starring everywhere

This commit is contained in:
austinried
2021-08-10 09:42:20 +09:00
parent 0a3d542156
commit 075286e939
6 changed files with 121 additions and 62 deletions

View File

@@ -9,12 +9,12 @@ import { useNavigation } from '@react-navigation/native'
import React, { useCallback } from 'react'
import { StyleSheet, Text, View } from 'react-native'
import FastImage from 'react-native-fast-image'
import IconFA from 'react-native-vector-icons/FontAwesome'
import IconFA5 from 'react-native-vector-icons/FontAwesome5'
import IconMat from 'react-native-vector-icons/MaterialIcons'
import { AlbumContextPressable, ArtistContextPressable, SongContextPressable } from './ContextMenu'
import CoverArt from './CoverArt'
import PressableOpacity from './PressableOpacity'
import Star from './Star'
const TitleTextSong = React.memo<{
id: string
@@ -171,11 +171,7 @@ const ListItem: React.FC<{
<View style={styles.controls}>
{showStar ? (
<PressableOpacity onPress={toggleStarred} style={styles.controlItem}>
{starred ? (
<IconFA name="star" size={26} color={colors.accent} />
) : (
<IconFA name="star-o" size={26} color={colors.text.secondary} />
)}
<Star size={26} starred={starred} />
</PressableOpacity>
) : (
<></>