diff --git a/front/API.ts b/front/API.ts index 5dcf445..5254500 100644 --- a/front/API.ts +++ b/front/API.ts @@ -66,9 +66,7 @@ export class ValidationError extends Error { export default class API { public static readonly baseUrl = - process.env.NODE_ENV != 'development' && Platform.OS === 'web' - ? '/api' - : 'https://nightly.chroma.octohub.app/api'; + Platform.OS === 'web' ? '/api' : process.env.EXPO_PUBLIC_API_URL!; public static async fetch( params: FetchParams, handle: Pick, 'raw'> diff --git a/front/components/GtkUI/RawElement.tsx b/front/components/GtkUI/RawElement.tsx index 8c3bd33..633cc27 100644 --- a/front/components/GtkUI/RawElement.tsx +++ b/front/components/GtkUI/RawElement.tsx @@ -31,7 +31,7 @@ export const RawElement = ({ element }: RawElementProps) => { const isSmallScreen = screenSize === 'small'; const { width: screenWidth } = useWindowDimensions(); const { colors } = useTheme(); - const IconElement = icon as IconSax; + const IconElement = icon; return ( = ({ }); const typeToStyleAnimator = { filled: styleButton, outlined: styleButton, menu: styleMenu }; - const MyIcon: Icon = icon as Icon; + const MyIcon = icon; return ( = ({ onPress={async () => { if (onPress && !isDisabled) { setLoading(true); - await onPress(); - setLoading(false); + try { + await onPress(); + } catch (error) { + console.error(error); + } finally { + setLoading(false); + } } }} isDisabled={isDisabled} @@ -124,7 +129,7 @@ const ButtonBase: React.FC = ({ type === 'menu' ? { justifyContent: 'flex-start' } : {}, ]} > - {icon && ( + {MyIcon && ( ; - onPress?: () => Promise; - isDisabled?: boolean; - icon?: Icon; - iconVariant?: 'Bold' | 'Outline'; - iconImage?: string; - type?: ButtonType; -} - -const ButtonBase: React.FC = ({ - title, - style, - onPress, - isDisabled, - icon, - iconImage, - type = 'filled', - iconVariant = 'Outline', -}) => { - const { colors } = useTheme(); - const [loading, setLoading] = useState(false); - const colorScheme = useColorScheme(); - - const styleButton = StyleSheet.create({ - Default: { - scale: 1, - shadowOpacity: 0.3, - shadowRadius: 4.65, - elevation: 8, - backgroundColor: colors.primary[400], - }, - onHover: { - scale: 1.02, - shadowOpacity: 0.37, - shadowRadius: 7.49, - elevation: 12, - backgroundColor: colors.primary[500], - }, - onPressed: { - scale: 0.98, - shadowOpacity: 0.23, - shadowRadius: 2.62, - elevation: 4, - backgroundColor: colors.primary[600], - }, - Disabled: { - scale: 1, - shadowOpacity: 0.3, - shadowRadius: 4.65, - elevation: 8, - backgroundColor: colors.primary[400], - }, - }); - - const styleMenu = StyleSheet.create({ - Default: { - scale: 1, - shadowOpacity: 0, - shadowRadius: 0, - elevation: 0, - backgroundColor: 'transparent', - }, - onHover: { - scale: 1.01, - shadowOpacity: 0.37, - shadowRadius: 7.49, - elevation: 12, - backgroundColor: colors.coolGray[400], - }, - onPressed: { - scale: 0.99, - shadowOpacity: 0.23, - shadowRadius: 2.62, - elevation: 4, - backgroundColor: colors.coolGray[600], - }, - Disabled: { - scale: 1, - shadowOpacity: 0.3, - shadowRadius: 4.65, - elevation: 8, - backgroundColor: colors.coolGray[500], - }, - }); - - const typeToStyleAnimator = { filled: styleButton, outlined: styleButton, menu: styleMenu }; - const MyIcon: Icon = icon as Icon; - - return ( - { - if (onPress && !isDisabled) { - setLoading(true); - await onPress(); - setLoading(false); - } - }} - isDisabled={isDisabled} - isOutlined={type === 'outlined'} - > - {loading ? ( - - ) : ( - - {icon && ( - - )} - {iconImage && } - {title && ( - - {title} - - )} - - )} - - ); -}; - -const styles = StyleSheet.create({ - container: { - borderRadius: 8, - }, - content: { - padding: 10, - justifyContent: 'center', - flexDirection: 'row', - alignItems: 'center', - }, - icon: { - width: 18, - height: 18, - }, - text: { - marginHorizontal: 8, - }, -}); - -export default ButtonBase; diff --git a/front/components/UI/Glassmorphism.tsx b/front/components/UI/Glassmorphism.tsx index b98d50c..33d03f5 100644 --- a/front/components/UI/Glassmorphism.tsx +++ b/front/components/UI/Glassmorphism.tsx @@ -11,13 +11,12 @@ type GlassmorphismCCProps = { const GlassmorphismCC = ({ children, style }: GlassmorphismCCProps) => { const colorScheme = useColorScheme(); - console.log(colorScheme); return ( {children} diff --git a/front/components/UI/MusicItem.tsx b/front/components/UI/MusicItem.tsx index adb8cda..8ff0287 100644 --- a/front/components/UI/MusicItem.tsx +++ b/front/components/UI/MusicItem.tsx @@ -39,7 +39,7 @@ export interface MusicItemType { onLike: () => void; /** Callback function triggered when the song is played. */ - onPlay?: () => void; + onPlay: () => void; } // Custom hook to handle the number formatting based on the current user's language. diff --git a/front/components/UI/MusicList.tsx b/front/components/UI/MusicList.tsx index ff48b80..0cc1813 100644 --- a/front/components/UI/MusicList.tsx +++ b/front/components/UI/MusicList.tsx @@ -4,6 +4,7 @@ import { ActivityIndicator, StyleSheet } from 'react-native'; import MusicItem, { MusicItemType } from './MusicItem'; import ButtonBase from './ButtonBase'; import { ArrowDown2, Chart2, ArrowRotateLeft, Cup, Icon } from 'iconsax-react-native'; +import { translate } from '../../i18n/i18n'; // Props type definition for MusicItemTitle. interface MusicItemTitleProps { @@ -108,7 +109,6 @@ function MusicListComponent({ // 'currentPage': current page in pagination. // 'loading': indicates if more items are being loaded. // 'hasMoreMusics': flag for more items availability. - console.log('initialMusics', initialMusics.length); const [musicListState, setMusicListState] = useState({ allMusics: initialMusics, displayedMusics: initialMusics.slice(0, musicsPerPage), @@ -119,7 +119,6 @@ function MusicListComponent({ const { colors } = useTheme(); const screenSize = useBreakpointValue({ base: 'small', md: 'md', xl: 'xl' }); const isBigScreen = screenSize === 'xl'; - console.log('coucou', initialMusics.length); // Loads additional music items. // Uses useCallback to avoid unnecessary redefinitions on re-renders. @@ -174,12 +173,12 @@ function MusicListComponent({ paddingRight: 60, }} > - Song + { translate('musicListTitleSong') } {[ - { text: 'level', icon: Chart2 }, - { text: 'lastScore', icon: ArrowRotateLeft }, - { text: 'BastScore', icon: Cup }, + { text: translate('musicListTitleLevel'), icon: Chart2 }, + { text: translate('musicListTitleLastScore'), icon: ArrowRotateLeft }, + { text: translate('musicListTitleBestScore'), icon: Cup }, ].map((value) => ( { - const navigation = useNavigation(); - const userQuery = useQuery(API.getUserInfo); - const dispatch = useDispatch(); - - if (!userQuery.data || userQuery.isLoading) { - return ; - } - const user = userQuery.data; - const layout = useWindowDimensions(); - const colorScheme = useColorScheme(); - const logo = - colorScheme == 'light' - ? require('../../assets/icon_light.png') - : require('../../assets/icon_dark.png'); - const playHistoryQuery = useQuery(API.getUserPlayHistory); - const songHistory = useQueries( - playHistoryQuery.data?.map(({ songID }) => API.getSong(songID)) ?? [] - ); - - return ( - - - - - - - {layout.width > 650 && ( - - Chromacase - - )} - - - - {menu.map((value) => ( - - - navigation.navigate(value.link as never) - } - /> - - - ))} - - - - - - - Recently played - - {songHistory.length === 0 && ( - - No songs played yet - - )} - {songHistory - .map((h) => h.data) - .filter((data): data is Song => data !== undefined) - .filter( - (song, i, array) => - array.map((s) => s.id).findIndex((id) => id == song.id) == i - ) - .slice(0, 4) - .map((histoItem, index) => ( - - {histoItem.name} - - ))} - - - - - - navigation.navigate('Settings', {})} - /> - - {!user.isGuest && ( - { - dispatch(unsetAccessToken()); - }} - /> - )} - - {user.isGuest && ( - ( - - {translate('signOutBtn')} - - )} - > - - - - - {translate('Attention')} - - - {translate( - 'YouAreCurrentlyConnectedWithAGuestAccountWarning' - )} - - - - - - - - - )} - - - - - {props.children} - - - - - - ); -}; - -export default ScaffoldCC; diff --git a/front/components/UI/ScaffoldAuth.tsx b/front/components/UI/ScaffoldAuth.tsx index 649bd54..77b3b70 100644 --- a/front/components/UI/ScaffoldAuth.tsx +++ b/front/components/UI/ScaffoldAuth.tsx @@ -74,7 +74,7 @@ const ScaffoldAuth: FunctionComponent = ({ /> {layout.width > 650 && ( - Chromacase + ChromaCase )} diff --git a/front/components/UI/ScaffoldCC.tsx b/front/components/UI/ScaffoldCC.tsx index 69bf107..a591d48 100644 --- a/front/components/UI/ScaffoldCC.tsx +++ b/front/components/UI/ScaffoldCC.tsx @@ -8,19 +8,14 @@ import { LoadingView } from '../Loading'; import ScaffoldDesktopCC from './ScaffoldDesktopCC'; import ScaffoldMobileCC from './ScaffoldMobileCC'; -const menu: { - type: 'main' | 'sub'; - title: string; - icon: Icon; - link: string; -}[] = [ +const menu = [ { type: 'main', title: 'menuDiscovery', icon: Discover, link: 'HomeNew' }, { type: 'main', title: 'menuProfile', icon: User, link: 'User' }, { type: 'main', title: 'menuMusic', icon: Music, link: 'Music' }, { type: 'main', title: 'menuSearch', icon: SearchNormal1, link: 'Search' }, { type: 'main', title: 'menuLeaderBoard', icon: Cup, link: 'Score' }, { type: 'sub', title: 'menuSettings', icon: Setting2, link: 'Settings' }, -]; +] as const; type ScaffoldCCProps = { children?: React.ReactNode; diff --git a/front/components/UI/ScaffoldDesktopCC.tsx b/front/components/UI/ScaffoldDesktopCC.tsx index 647c63b..ae06013 100644 --- a/front/components/UI/ScaffoldDesktopCC.tsx +++ b/front/components/UI/ScaffoldDesktopCC.tsx @@ -1,5 +1,5 @@ /* eslint-disable no-mixed-spaces-and-tabs */ -import { View, Image } from 'react-native'; +import { View, Image, TouchableOpacity } from 'react-native'; import { Divider, Text, ScrollView, Row, useMediaQuery, useTheme } from 'native-base'; import { useQuery, useQueries } from '../../Queries'; import API from '../../API'; @@ -7,7 +7,7 @@ import Song from '../../models/Song'; import ButtonBase from './ButtonBase'; import { Icon } from 'iconsax-react-native'; import { LoadingView } from '../Loading'; -import { translate } from '../../i18n/i18n'; +import { TranslationKey, translate } from '../../i18n/i18n'; import { useNavigation } from '../../Navigation'; import Spacer from './Spacer'; import User from '../../models/User'; @@ -20,48 +20,58 @@ type ScaffoldDesktopCCProps = { user: User; logo: string; routeName: string; - menu: { + menu: readonly{ type: 'main' | 'sub'; - title: string; + title: TranslationKey; icon: Icon; link: string; }[]; }; +// TODO a tester avec un historique de plus de 3 musics différente mdr !! const SongHistory = (props: { quantity: number }) => { const playHistoryQuery = useQuery(API.getUserPlayHistory); const songHistory = useQueries( playHistoryQuery.data?.map(({ songID }) => API.getSong(songID)) ?? [] ); + const navigation = useNavigation(); - if (!playHistoryQuery.data || playHistoryQuery.isLoading) { + const musics = + songHistory + .map((h) => h.data) + .filter((data): data is Song => data !== undefined) + .filter( + (song, i, array) => + array.map((s) => s.id).findIndex((id) => id == song.id) == i + ) + ?.slice(0, props.quantity) + .map((song: Song) => ( + + navigation.navigate('Song', { songId: song.id })} + > + {song.name} + + + )) + + if (!playHistoryQuery.data || playHistoryQuery.isLoading || !songHistory) { return ; } return ( - {songHistory.length === 0 ? ( + {musics.length === 0 ? ( {translate('menuNoSongsPlayedYet')} ) : ( - songHistory - .map((h) => h.data) - .filter((data): data is Song => data !== undefined) - .filter( - (song, i, array) => - array.map((s) => s.id).findIndex((id) => id == song.id) == i - ) - .slice(0, props.quantity + 1) - .map((histoItem, index) => ( - - {histoItem.name} - - )) + musics )} ); @@ -148,7 +158,7 @@ const ScaffoldDesktopCC = (props: ScaffoldDesktopCCProps) => { {!isSmallScreen && ( - + { const [isSmallScreen] = useMediaQuery({ maxWidth: 400 }); const { colors } = useTheme(); - console.log(isSmallScreen); - return ( Promise; } +// TODO not use !! const LoginForm = ({ onSubmit }: SigninFormProps) => { const [formData, setFormData] = React.useState({ username: { @@ -47,7 +48,7 @@ const LoginForm = ({ onSubmit }: SigninFormProps) => { { @@ -68,6 +69,7 @@ const LoginForm = ({ onSubmit }: SigninFormProps) => { { isRequired icon={User} error={formData.username.error} - placeholder="Username" + placeholder={translate('formPlaceholderUsername')} autoComplete="username-new" value={formData.username.value} onChangeText={(t) => { @@ -75,7 +75,7 @@ const SignUpForm = ({ onSubmit }: SignupFormProps) => { isRequired icon={Sms} error={formData.email.error} - placeholder="Email" + placeholder={translate('formPlaceholderEmail')} autoComplete="email" value={formData.email.value} onChangeText={(t) => { @@ -93,7 +93,7 @@ const SignUpForm = ({ onSubmit }: SignupFormProps) => { isSecret icon={Lock1} error={formData.password.error} - placeholder="Password" + placeholder={translate('formPlaceholderPassword')} autoComplete="password-new" value={formData.password.value} onChangeText={(t) => { @@ -111,7 +111,7 @@ const SignUpForm = ({ onSubmit }: SignupFormProps) => { isSecret error={formData.repeatPassword.error} icon={Lock1} - placeholder="Repeat password" + placeholder={translate('formPlaceholderRepeatPassword')} autoComplete="password-new" value={formData.repeatPassword.value} onChangeText={(t) => { diff --git a/front/i18n/Translations.ts b/front/i18n/Translations.ts index a336d94..ac1f8f3 100644 --- a/front/i18n/Translations.ts +++ b/front/i18n/Translations.ts @@ -38,6 +38,17 @@ export const en = { levelProgress: 'good notes', score: 'Score', + // Form + formPlaceholderUsername: 'Username', + formPlaceholderEmail: "Email", + formPlaceholderPassword: 'Password', + formPlaceholderRepeatPassword: 'Repeat password', + + // MusicListTitle + musicListTitleSong : "Song", + musicListTitleLevel: 'Level', + musicListTitleLastScore: 'Last Score', + musicListTitleBestScore: 'Best Score', // Menu menuDiscovery: 'Discovery', menuProfile: 'Profile', @@ -58,7 +69,7 @@ export const en = { //signin signinPageTitle: 'Welcome !', signinPageParagraph: 'Continue with Google or enter your details.', - signinLinkLabel: "You don't have an account? ", + signinLinkLabel: "You don't have an account?", signinLinkText: 'Sign up for free.', //music @@ -305,8 +316,8 @@ export const fr: typeof en = { songPageBtn: 'Aller sur la page de la chanson', level: 'Niveau', chapters: 'Chapitres', - bestScore: 'Meilleur Score', - lastScore: 'Dernier Score', + bestScore: 'Meilleur', + lastScore: 'Dernier', bestStreak: 'Meilleure série', precision: 'Précision', @@ -330,6 +341,16 @@ export const fr: typeof en = { longestCombo: 'Combo le plus long : ', favoriteGenre: 'Genre favori : ', + // Form + formPlaceholderUsername : "Nom d'utilisateur", + formPlaceholderEmail : "Email", + formPlaceholderPassword : 'Mot de passe', + formPlaceholderRepeatPassword : 'Répéter le mot de passe', + // MusicListTitle + musicListTitleSong : "Musique", + musicListTitleLevel : "Niveau", + musicListTitleLastScore : "Dernier", + musicListTitleBestScore : "Meilleur", // Menu menuDiscovery: 'Découverte', menuProfile: 'Profil', @@ -350,7 +371,7 @@ export const fr: typeof en = { //signin signinPageTitle: 'Bienvenue !', signinPageParagraph: 'Continuez avec Google ou entrez vos coordonnées.', - signinLinkLabel: "Vous n'avez pas de compte ? ", + signinLinkLabel: "Vous n'avez pas de compte ?", signinLinkText: 'Inscrivez-vous gratuitement', //music @@ -635,6 +656,17 @@ export const sp: typeof en = { longestCombo: 'combo más largo : ', favoriteGenre: 'genero favorito : ', + // Form + formPlaceholderUsername: 'NombreUsuario', + formPlaceholderEmail: "Email", + formPlaceholderPassword: 'Contraseña', + formPlaceholderRepeatPassword: 'Repetir contraseña', + + // MusicListTitle + musicListTitleSong : "Canción", + musicListTitleLevel: 'Nivel', + musicListTitleLastScore: 'Última', + musicListTitleBestScore: 'Mejor', // Menu menuDiscovery: 'Descubrimiento', menuProfile: 'Perfil', @@ -655,7 +687,7 @@ export const sp: typeof en = { //signin signinPageTitle: 'Bienvenido !', signinPageParagraph: 'Continúa con Google o introduce tus datos.', - signinLinkLabel: '¿No tienes una cuenta? ', + signinLinkLabel: '¿No tienes una cuenta?', signinLinkText: 'Regístrate gratis.', //music diff --git a/front/i18n/i18n.ts b/front/i18n/i18n.ts index 0cafbf5..ce60ea3 100644 --- a/front/i18n/i18n.ts +++ b/front/i18n/i18n.ts @@ -39,4 +39,6 @@ export const translate = (key: keyof typeof en, language?: AvailableLanguages) = }); }; +export type TranslationKey = keyof typeof en; + export { Translate }; diff --git a/front/package.json b/front/package.json index 1792c36..12148a7 100644 --- a/front/package.json +++ b/front/package.json @@ -24,7 +24,7 @@ "@react-navigation/native": "^6.1.8", "@react-navigation/native-stack": "^6.9.14", "@reduxjs/toolkit": "^1.9.6", - "expo": "^49.0.16", + "expo": "~49.0.13", "expo-blur": "~12.4.1", "expo-image-picker": "~14.3.2", "expo-linear-gradient": "~12.3.0", diff --git a/front/views/MusicView.tsx b/front/views/MusicView.tsx index ebd3b78..6b2c054 100644 --- a/front/views/MusicView.tsx +++ b/front/views/MusicView.tsx @@ -11,8 +11,8 @@ import { } from 'react-native-tab-view'; import { Heart, Clock, StatusUp, FolderCross } from 'iconsax-react-native'; import { Scene } from 'react-native-tab-view/lib/typescript/src/types'; -import { RouteProps } from '../Navigation'; -import { translate } from '../i18n/i18n'; +import { RouteProps, useNavigation } from '../Navigation'; +import { TranslationKey, translate } from '../i18n/i18n'; import ScaffoldCC from '../components/UI/ScaffoldCC'; import MusicList from '../components/UI/MusicList'; import { useQueries, useQuery } from '../Queries'; @@ -22,1147 +22,8 @@ import { LoadingView } from '../components/Loading'; import InteractiveCC from '../components/UI/InteractiveCC'; import ButtonBase from '../components/UI/ButtonBase'; -// Fichier de données fictives, par exemple MusicData.ts -export const fakeMusicData = [ - { - id: '1', - image: 'https://placekitten.com/200/200', - liked: true, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 1'), - level: 3, - lastScore: 100000, - bestScore: 200000, - artist: 'Johann Sebastian Bach', - song: 'Toccata and Fugue in D minor', - }, - { - id: '2', - image: 'https://placekitten.com/200/201', - liked: false, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 2'), - level: 2, - lastScore: 150000, - bestScore: 250000, - artist: 'Wolfgang Amadeus Mozart', - song: 'Eine kleine Nachtmusik', - }, - { - id: '3', - image: 'https://placekitten.com/200/202', - liked: true, - onLike: () => console.log('Liked track 3'), - onPlay: () => console.log('Play track 3'), - level: 5, - lastScore: 200000, - bestScore: 300000, - artist: 'Ludwig van Beethoven', - song: 'Symphony No.5 in C Minor', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 2'), - level: 4, - lastScore: -6041866, - bestScore: 1792627, - artist: 'Cassey Cavnor', - song: 'Dirty Ho (Lan tou He)', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 3'), - onPlay: () => console.log('Play track 3'), - level: 3, - lastScore: -2372092, - bestScore: -967983, - artist: 'Addi Rieger', - song: 'Company Men, The', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 3'), - level: 0, - lastScore: -5935902, - bestScore: -6940127, - artist: 'Sarge Croom', - song: 'Newsies', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 3'), - onPlay: () => console.log('Play track 2'), - level: 5, - lastScore: -3980235, - bestScore: -7895014, - artist: 'Brigg Welsby', - song: 'Bobby', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 1'), - level: 3, - lastScore: 1621097, - bestScore: -6233674, - artist: 'Tammy Frear', - song: 'Footprints of a Spirit, The (Huellas de un espíritu)', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 2'), - level: 2, - lastScore: -4299184, - bestScore: -495720, - artist: 'Davide Broschek', - song: 'Simon Says', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 2'), - level: 1, - lastScore: 767838, - bestScore: -8154546, - artist: 'Steffane Tooker', - song: 'Deadfall', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 3'), - level: 1, - lastScore: 4664756, - bestScore: 370710, - artist: 'Sisile Merriott', - song: 'Crow, The: Wicked Prayer', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 2'), - level: 3, - lastScore: 6121666, - bestScore: -7111438, - artist: "Sherri O'Griffin", - song: 'Japanese Story', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 1'), - level: 2, - lastScore: -1200469, - bestScore: 7753495, - artist: 'Libbi Feige', - song: 'Climax, The', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 3'), - onPlay: () => console.log('Play track 1'), - level: 5, - lastScore: 1809908, - bestScore: -2296480, - artist: 'Merola Helliker', - song: 'Lady Eve, The', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 2'), - level: 1, - lastScore: -4816854, - bestScore: -3423779, - artist: 'Carmela Beacom', - song: 'Jungle Book, The', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 3'), - level: 4, - lastScore: -6011431, - bestScore: -6967162, - artist: 'Kelsi Simko', - song: 'Mulholland Drive', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 1'), - level: 1, - lastScore: -8223754, - bestScore: -121676, - artist: 'Xenia Meak', - song: 'Gendarme Gets Married, The (Le gendarme se marie)', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 1'), - level: 4, - lastScore: -1237859, - bestScore: 5566342, - artist: 'Rosalyn Markie', - song: 'Beyond the Fear', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 2'), - level: 3, - lastScore: -8627463, - bestScore: 840132, - artist: 'Regan Rewcassell', - song: 'Eden', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 2'), - level: 2, - lastScore: 2253750, - bestScore: 7447445, - artist: 'Fidela Lippi', - song: '66 Scenes From America', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 1'), - level: 1, - lastScore: -7525532, - bestScore: 5961571, - artist: 'Isac Leftley', - song: 'Life of Emile Zola, The', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 2'), - level: 3, - lastScore: -4681154, - bestScore: 6039966, - artist: 'Issi McKmurrie', - song: 'Gremlins 2: The New Batch', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 1'), - level: 3, - lastScore: -8736434, - bestScore: 171899, - artist: 'Mathian Iskowicz', - song: 'Alive Inside', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 1'), - level: 3, - lastScore: 5783443, - bestScore: 4508317, - artist: 'Garek Hadcock', - song: 'Street Mobster (a.k.a. Modern Yakuza: Outlaw Killer) (Gendai yakuza: hito-kiri yota)', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 1'), - level: 4, - lastScore: 4521728, - bestScore: -1549426, - artist: 'Spence Loveguard', - song: 'Bastards, The (Los bastardos)', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 3'), - onPlay: () => console.log('Play track 2'), - level: 5, - lastScore: -1773795, - bestScore: 8285865, - artist: 'Shirley Espinola', - song: 'Raise Your Voice', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 1'), - level: 1, - lastScore: 7256121, - bestScore: 5562922, - artist: 'Mikael Yirrell', - song: 'Nitro Circus: The Movie', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 3'), - onPlay: () => console.log('Play track 2'), - level: 0, - lastScore: 7528625, - bestScore: 523891, - artist: 'Giovanna Burchfield', - song: 'Onion Field, The', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 3'), - onPlay: () => console.log('Play track 3'), - level: 4, - lastScore: 8610671, - bestScore: -7816079, - artist: 'Eugenius Leftbridge', - song: 'Compulsion', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 2'), - level: 3, - lastScore: 2886144, - bestScore: 6020383, - artist: 'Garvin Marcus', - song: 'RocketMan (a.k.a. Rocket Man)', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 2'), - level: 1, - lastScore: 3240248, - bestScore: -4724599, - artist: 'Nell Denzey', - song: 'Chasing Amy', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 3'), - onPlay: () => console.log('Play track 1'), - level: 3, - lastScore: -5463629, - bestScore: 4232635, - artist: 'Blancha Oxterby', - song: 'Savages, The', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 2'), - level: 4, - lastScore: -4482142, - bestScore: 8332541, - artist: 'Rosetta Figgess', - song: "Daffy Duck's Movie: Fantastic Island", - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 1'), - level: 1, - lastScore: -683631, - bestScore: 5027029, - artist: 'Marys Scriver', - song: 'Haunted Honeymoon', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 1'), - level: 4, - lastScore: 7290002, - bestScore: -7268634, - artist: 'Adiana Swinfen', - song: "Midsummer Night's Sex Comedy, A", - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 2'), - level: 3, - lastScore: 8539120, - bestScore: 2520490, - artist: 'Lenci Tellesson', - song: 'Quid Pro Quo', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 3'), - level: 1, - lastScore: 2769849, - bestScore: -3077625, - artist: 'Marylee Sabben', - song: 'Dancing Hawk, The (Tanczacy jastrzab)', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 3'), - onPlay: () => console.log('Play track 3'), - level: 3, - lastScore: 647609, - bestScore: -6815, - artist: 'Conney Ewart', - song: 'Old Acquaintance', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 2'), - level: 5, - lastScore: 722223, - bestScore: 3398209, - artist: 'Brendon Hearfield', - song: 'Human Scale, The', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 3'), - level: 0, - lastScore: 1029859, - bestScore: 2277604, - artist: 'Donovan Patifield', - song: 'Return with Honor', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 1'), - level: 5, - lastScore: -1361157, - bestScore: 836139, - artist: 'Laureen Yushankin', - song: 'Manon of the Spring', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 3'), - onPlay: () => console.log('Play track 3'), - level: 1, - lastScore: 4509348, - bestScore: 7566343, - artist: 'Dot Cordobes', - song: 'The Big Shave', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 1'), - level: 2, - lastScore: -8836036, - bestScore: 7757707, - artist: 'Maddie Blackman', - song: "When You're Strange", - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 2'), - level: 4, - lastScore: -8045782, - bestScore: -3214261, - artist: 'Wiatt Durram', - song: 'Death of a President', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 2'), - level: 2, - lastScore: -4518414, - bestScore: -2394538, - artist: 'Karalee Snyder', - song: 'China 9, Liberty 37 (Amore, piombo e furore)', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 3'), - onPlay: () => console.log('Play track 3'), - level: 2, - lastScore: 6371585, - bestScore: -8197321, - artist: 'Calida Elden', - song: "Watch Out, We're Mad (...Altrimenti ci arrabbiamo!)", - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 3'), - level: 4, - lastScore: 4665295, - bestScore: 4323344, - artist: 'Travis Yearron', - song: 'Lassie Come Home', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 2'), - level: 0, - lastScore: -2743930, - bestScore: -2506969, - artist: 'Claudie Batchelour', - song: 'Wirey Spindell', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 1'), - level: 0, - lastScore: 8157276, - bestScore: -6396929, - artist: 'Kenon Gerdes', - song: 'I Am Michael', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 3'), - level: 0, - lastScore: 8420043, - bestScore: -90627, - artist: 'Prudi Rankin', - song: 'Emmanuelle', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 2'), - level: 3, - lastScore: 459678, - bestScore: -1323457, - artist: 'Sylvester Sillito', - song: 'GasLand', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 1'), - level: 5, - lastScore: -3983927, - bestScore: -8776721, - artist: 'Ellene Novak', - song: 'Mask', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 1'), - level: 1, - lastScore: -3558603, - bestScore: 5680103, - artist: 'Craig Lupton', - song: 'Copycat', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 2'), - level: 2, - lastScore: 4235362, - bestScore: 5238299, - artist: 'Rancell Tremathack', - song: 'Any Which Way You Can', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 3'), - onPlay: () => console.log('Play track 2'), - level: 4, - lastScore: -1377412, - bestScore: 7148545, - artist: 'Alyosha Deddum', - song: 'Mumia Abu-Jamal: A Case for Reasonable Doubt?', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 3'), - onPlay: () => console.log('Play track 1'), - level: 5, - lastScore: -945041, - bestScore: -1113097, - artist: 'Jamison Zumbusch', - song: 'Meet the Applegates', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 3'), - onPlay: () => console.log('Play track 2'), - level: 2, - lastScore: 5994306, - bestScore: 2836966, - artist: 'Samantha Dows', - song: 'Chess Players, The (Shatranj Ke Khilari)', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 2'), - level: 0, - lastScore: 719570, - bestScore: 8677726, - artist: 'Anthe Veart', - song: 'The Tattooist', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 3'), - level: 0, - lastScore: -8777884, - bestScore: 1475585, - artist: 'Carlo Levison', - song: 'Balzac and the Little Chinese Seamstress (Xiao cai feng)', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 1'), - level: 3, - lastScore: -1079544, - bestScore: 2185825, - artist: 'Erda Danilewicz', - song: 'Dark Prince: The True Story of Dracula', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 1'), - level: 4, - lastScore: -4053732, - bestScore: -8159546, - artist: 'Fidelio Maken', - song: "Ditchdigger's Daughters, The", - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 1'), - level: 5, - lastScore: 612834, - bestScore: 6754339, - artist: 'Dallas Hollebon', - song: 'Thunderbolt (Pik lik feng)', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 3'), - onPlay: () => console.log('Play track 2'), - level: 1, - lastScore: 4928099, - bestScore: 2211588, - artist: 'Georg MacDermott', - song: 'Then I Sentenced Them All to Death (Atunci i-am condamnat pe toti la moarte)', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 2'), - level: 5, - lastScore: -3219354, - bestScore: -3414767, - artist: 'Terri Middlemist', - song: 'Children of a Lesser God', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 3'), - level: 1, - lastScore: 6968532, - bestScore: 262053, - artist: 'Cherin White', - song: 'Out of Mind: The Stories of H.P. Lovecraft', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 1'), - level: 4, - lastScore: -4346254, - bestScore: 8249393, - artist: 'Brandise Bradder', - song: 'Wave, The (Welle, Die)', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 1'), - level: 2, - lastScore: 3454077, - bestScore: 5370105, - artist: 'Dorry Hawick', - song: 'Green Slime, The', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 3'), - level: 3, - lastScore: -7848176, - bestScore: 8346330, - artist: 'Darwin Lynthal', - song: 'Killers, The', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 1'), - level: 5, - lastScore: -4389779, - bestScore: -7612241, - artist: 'Stanford Predohl', - song: 'Evita', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 3'), - onPlay: () => console.log('Play track 2'), - level: 0, - lastScore: 5728505, - bestScore: -1650662, - artist: 'Leola Spykings', - song: 'Airport 1975', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 1'), - level: 2, - lastScore: -1029430, - bestScore: -6090027, - artist: 'Laurence Brownlie', - song: 'Oyster Farmer', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 1'), - level: 5, - lastScore: -4348919, - bestScore: 4228044, - artist: 'Wilbert Herkess', - song: 'War and Peace (Jang Aur Aman)', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 2'), - level: 2, - lastScore: 537257, - bestScore: 1139697, - artist: 'Briney Pochon', - song: 'Mail Order Bride', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 3'), - onPlay: () => console.log('Play track 1'), - level: 5, - lastScore: 4545229, - bestScore: 6500951, - artist: 'Amabel von Grollmann', - song: 'Page Miss Glory', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 1'), - level: 2, - lastScore: 4882659, - bestScore: 2907561, - artist: 'Minne Stirtle', - song: 'Crossing the Bridge', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 3'), - level: 0, - lastScore: -6504654, - bestScore: -3350072, - artist: 'Forster Hallgalley', - song: 'Mr. Bug Goes to Town (a.k.a. Hoppity Goes to Town)', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 1'), - level: 3, - lastScore: -4904050, - bestScore: 6249989, - artist: 'Ashlin Druitt', - song: 'Salvage', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 1'), - level: 2, - lastScore: 8595971, - bestScore: -910946, - artist: 'Dee Whiteford', - song: 'Christopher Strong', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 2'), - level: 2, - lastScore: -4189479, - bestScore: -6601395, - artist: 'Elizabeth Bartali', - song: 'Lara Croft Tomb Raider: The Cradle of Life', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 2'), - level: 3, - lastScore: -2491521, - bestScore: -4016927, - artist: 'Vlad Gedge', - song: 'Hairspray', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 1'), - level: 2, - lastScore: 4290319, - bestScore: -6000100, - artist: 'Calli Lulham', - song: 'Winds of the Wasteland', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 1'), - level: 1, - lastScore: -8426202, - bestScore: 8732106, - artist: 'Ashly Sanders', - song: 'Outside Providence', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 1'), - level: 1, - lastScore: -2735365, - bestScore: -5074941, - artist: 'Lew Bate', - song: 'Ethan Mao', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 2'), - level: 3, - lastScore: 2226383, - bestScore: -5940922, - artist: 'Elie MacAnespie', - song: 'Saving Private Ryan', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 3'), - level: 2, - lastScore: -1785471, - bestScore: 1882854, - artist: 'Eberto Abdy', - song: 'Scooby-Doo! Abracadabra-Doo', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 3'), - onPlay: () => console.log('Play track 3'), - level: 4, - lastScore: 8210072, - bestScore: 7416746, - artist: 'Roxie Bouzek', - song: 'Private Parts', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 3'), - onPlay: () => console.log('Play track 2'), - level: 1, - lastScore: -757068, - bestScore: -2086735, - artist: 'Nestor Tuckwell', - song: 'Pusher II: With Blood on My Hands', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 3'), - onPlay: () => console.log('Play track 2'), - level: 4, - lastScore: 7667818, - bestScore: -4544823, - artist: 'Ingemar Castiblanco', - song: 'Rocky IV', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 2'), - level: 2, - lastScore: -7948742, - bestScore: -7564800, - artist: 'Eddy Saines', - song: 'Babe', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 3'), - onPlay: () => console.log('Play track 2'), - level: 3, - lastScore: -6119057, - bestScore: 3464164, - artist: 'Gav Jakubovski', - song: '42nd Street', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 3'), - level: 1, - lastScore: 8453682, - bestScore: -4429348, - artist: 'Pavia Libri', - song: 'Fat Man and Little Boy', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 3'), - level: 1, - lastScore: 7781547, - bestScore: -6619210, - artist: 'Dar Stait', - song: 'Pretty Maids All in a Row', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 3'), - onPlay: () => console.log('Play track 2'), - level: 5, - lastScore: -362262, - bestScore: -457249, - artist: 'Annabella Pavek', - song: 'Are You Here', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 3'), - level: 2, - lastScore: -6314972, - bestScore: 2860891, - artist: 'Hillier Richardson', - song: 'Cry, The (Grido, Il)', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 1'), - onPlay: () => console.log('Play track 1'), - level: 4, - lastScore: 561681, - bestScore: 395500, - artist: 'Doe Wyche', - song: 'Loved Ones, The', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 1'), - level: 4, - lastScore: 4655690, - bestScore: -3864620, - artist: 'Ronnica Kirkness', - song: 'Libeled Lady', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 1'), - level: 2, - lastScore: -3237102, - bestScore: 7279015, - artist: 'Ennis Kalkofer', - song: 'Elf', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 3'), - level: 5, - lastScore: -4883463, - bestScore: 3856202, - artist: 'Margaret McNamee', - song: 'Direct Action', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 3'), - level: 2, - lastScore: 7130068, - bestScore: -7335491, - artist: 'Burg Stubbs', - song: 'Game Over', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 3'), - onPlay: () => console.log('Play track 1'), - level: 0, - lastScore: -5413799, - bestScore: 1522901, - artist: 'Guido Bearsmore', - song: 'Apple Dumpling Gang, The', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 3'), - level: 4, - lastScore: -75885, - bestScore: 4456222, - artist: 'Lemmie Belhomme', - song: 'Guy Named Joe, A', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: false, - onLike: () => console.log('Liked track 2'), - onPlay: () => console.log('Play track 3'), - level: 5, - lastScore: 7982212, - bestScore: -5700652, - artist: 'Mable Feitosa', - song: 'Who Are you Polly Maggoo (Qui êtes-vous, Polly Maggoo?)', - }, - { - image: 'https://static.vecteezy.com/system/resources/previews/016/552/335/non_2x/luffy-kawai-chibi-cute-onepiece-anime-design-and-doodle-art-for-icon-logo-collection-and-others-free-vector.jpg', - liked: true, - onLike: () => console.log('Liked track 3'), - onPlay: () => console.log('Play track 1'), - level: 3, - lastScore: 633755, - bestScore: 1462680, - artist: 'Amalle Lillo', - song: 'Your Friends and Neighbors', - }, -]; - export const FavoritesMusic = () => { + const navigation = useNavigation(); const playHistoryQuery = useQuery(API.getUserPlayHistory); const nextStepQuery = useQuery(API.getSongSuggestions); const songHistory = useQueries( @@ -1184,10 +45,10 @@ export const FavoritesMusic = () => { const musics = nextStepQuery.data - ?.filter((song) => + ?.filter((song: Song) => artistsQueries.find((artistQuery) => artistQuery.data?.id === song.artistId) ) - .map((song) => ({ + .map((song: Song) => ({ artist: artistsQueries.find( (artistQuery) => artistQuery.data?.id === song.artistId )!.data!.name, @@ -1200,9 +61,7 @@ export const FavoritesMusic = () => { onLike: () => { console.log('onLike'); }, - onPlay: () => { - console.log('onPlay'); - }, + onPlay: () => navigation.navigate('Song', { songId: song.id }), })) ?? []; const { colors } = useTheme(); @@ -1212,7 +71,7 @@ export const FavoritesMusic = () => { } return ( <> - + {/* { style={{ width: 'fit-content', marginTop: 20 }} type={'filled'} /> - + */} ) => { const { colors } = useTheme(); const screenSize = useBreakpointValue({ base: 'small', md: 'big' }); const isSmallScreen = screenSize === 'small'; - const [routes] = React.useState([ + const routes = [ { key: 'favorites', title: 'musicTabFavorites' }, { key: 'recentlyPlayed', title: 'musicTabRecentlyPlayed' }, { key: 'stepUp', title: 'musicTabStepUp' }, - ]); + ]; const renderTabBar = ( props: SceneRendererProps & { navigationState: NavigationState } ) => ( @@ -1344,10 +203,7 @@ const MusicTab = (props: RouteProps) => { layout.width > 800 && ( {translate( - route.title as - | 'musicTabFavorites' - | 'musicTabRecentlyPlayed' - | 'musicTabStepUp' + route.title as TranslationKey )} ) diff --git a/front/views/SigninView.tsx b/front/views/SigninView.tsx index d276ead..a068501 100644 --- a/front/views/SigninView.tsx +++ b/front/views/SigninView.tsx @@ -69,7 +69,7 @@ const SigninView = () => { key={'signin-form-1'} error={formData.username.error} icon={User} - placeholder="Username" + placeholder={translate('formPlaceholderUsername')} autoComplete="username" value={formData.username.value} onChangeText={(t) => { @@ -87,7 +87,7 @@ const SigninView = () => { key={'signin-form-2'} error={formData.password.error} icon={Lock1} - placeholder="Password" + placeholder={translate('formPlaceholderPassword')} autoComplete="password" value={formData.password.value} onChangeText={(t) => { @@ -136,7 +136,7 @@ const SigninView = () => { /> } link={{ - label: translate('signinLinkLabel'), + label: translate('signinLinkLabel') + ' ', text: translate('signinLinkText'), onPress: () => navigation.navigate('Signup'), }} diff --git a/front/views/SignupView.tsx b/front/views/SignupView.tsx index f84ccf5..7401d66 100644 --- a/front/views/SignupView.tsx +++ b/front/views/SignupView.tsx @@ -83,7 +83,7 @@ const SignupView = () => { key={'signup-form-1'} error={formData.username.error} icon={User} - placeholder="Username" + placeholder={translate('formPlaceholderUsername')} autoComplete="username" value={formData.username.value} onChangeText={(t) => { @@ -101,7 +101,7 @@ const SignupView = () => { key={'signup-form-2'} error={formData.email.error} icon={Sms} - placeholder="Email" + placeholder={translate('formPlaceholderEmail')} autoComplete="email" value={formData.email.value} onChangeText={(t) => { @@ -121,7 +121,7 @@ const SignupView = () => { isSecret error={formData.password.error} icon={Lock1} - placeholder="Password" + placeholder={translate('formPlaceholderPassword')} autoComplete="password-new" value={formData.password.value} onChangeText={(t) => { @@ -140,7 +140,7 @@ const SignupView = () => { isSecret error={formData.repeatPassword.error} icon={Lock1} - placeholder="Repeat password" + placeholder={translate('formPlaceholderRepeatPassword')} autoComplete="password-new" value={formData.repeatPassword.value} onChangeText={(t) => { diff --git a/front/views/settings/SettingsView.tsx b/front/views/settings/SettingsView.tsx index 3a3eec0..62f7de9 100644 --- a/front/views/settings/SettingsView.tsx +++ b/front/views/settings/SettingsView.tsx @@ -27,6 +27,7 @@ import PremiumSettings from './SettingsPremium'; import { RouteProps } from '../../Navigation'; import ScaffoldCC from '../../components/UI/ScaffoldCC'; import { translate } from '../../i18n/i18n'; +import { useLanguage } from '../../state/LanguageSlice'; export const PianoSettings = () => { return ( @@ -69,7 +70,7 @@ const SettingsTab = (props: RouteProps<{}>) => { const layout = useWindowDimensions(); const [index, setIndex] = React.useState(0); const { colors } = useTheme(); - const [routes] = React.useState([ + const routes = ([ { key: 'profile', title: 'settingsTabProfile' }, { key: 'premium', title: 'settingsTabPremium' }, { key: 'preferences', title: 'settingsTabPreferences' },