Correct some errors 🐛
continuous-integration/drone/push Build is failing Details

master
root 2 years ago
parent 1985877ff6
commit 87069f5fe4

@ -16,7 +16,7 @@ const store = configureStore({
reducer: reducer, reducer: reducer,
middleware: (getDefaultMiddleware) => getDefaultMiddleware({ middleware: (getDefaultMiddleware) => getDefaultMiddleware({
serializableCheck: { serializableCheck: {
ignoredActions: [spotTypes.FETCH_SPOT, spotifyTypes.GET_USER_CURRENT_MUSIC, favoritesTypes.ADD_FAVORITE_MUSICS, favoritesTypes.REMOVE_FAVORITE_MUSICS, spotTypes.REMOVE_SPOT ], ignoredActions: [spotTypes.FETCH_SPOT, spotifyTypes.GET_USER_CURRENT_MUSIC, favoritesTypes.ADD_FAVORITE_MUSICS, favoritesTypes.REMOVE_FAVORITE_MUSICS, spotTypes.REMOVE_SPOT, userTypes.LOGIN, userTypes.SIGNUP ],
ignoredActionPaths: ['appReducer'], ignoredActionPaths: ['appReducer'],
ignoredPaths: ['appReducer', 'userReducer'] ignoredPaths: ['appReducer', 'userReducer']
} }

@ -10,6 +10,8 @@ import { useDispatch, useSelector } from 'react-redux';
import { Audio } from 'expo-av'; import { Audio } from 'expo-av';
import { CredentialsRegister } from '../redux/actions/userActions'; import { CredentialsRegister } from '../redux/actions/userActions';
import * as WebBrowser from 'expo-web-browser'; import * as WebBrowser from 'expo-web-browser';
import { spotArray2 } from '../data/data';
import { setSpotList } from '../redux/actions/spotActions';
// @ts-ignore // @ts-ignore
const DismissKeyboard = ({ children }) => ( const DismissKeyboard = ({ children }) => (
@ -48,18 +50,37 @@ export default function InscriptionPage() {
const dispatch = useDispatch(); const dispatch = useDispatch();
function addMockSpots() {
dispatch(setSpotList(spotArray2))
}
const submitForm = () => { const submitForm = () => {
const credentials: CredentialsRegister = { const credentials: CredentialsRegister = {
email: email, email: email,
password: password, password: password,
idSpotify: spotifyToken, idSpotify: spotifyToken,
name: username, name: username,
idFlad: "9835698" idFlad: generateRandomString()
}; };
//@ts-ignore //@ts-ignore
dispatch(registerUser(credentials)) dispatch(registerUser(credentials))
addMockSpots()
playSound() playSound()
} }
function generateRandomString(): string {
const alphabet = 'abcdefghijklmnopqrstuvwxyz';
let randomString = '';
for (let i = 0; i < 8; i++) {
const randomIndex = Math.floor(Math.random() * alphabet.length);
const randomChar = alphabet[randomIndex];
randomString += randomChar;
}
return randomString;
}
const getTokens2 = async () => { const getTokens2 = async () => {
try { try {
const redirectUri = AuthSession.makeRedirectUri(); const redirectUri = AuthSession.makeRedirectUri();

@ -320,6 +320,8 @@ export default function Setting() {
</View> </View>
</View> </View>
</View> </View>
{currentMusic ? (
<>
<View style={styles.titleMusic}> <View style={styles.titleMusic}>
<Svg width="32" height="23" viewBox="0 0 28 21"> <Svg width="32" height="23" viewBox="0 0 28 21">
<Path d="M5.84463 0.36924C5.37582 -0.0995746 4.59968 -0.13966 4.10723 0.35111C1.57056 2.8792 0 6.37809 0 10.243C0 14.2583 1.69511 17.8783 4.40753 20.4254C4.90303 20.8906 5.65829 20.8413 6.11707 20.3826C6.65205 19.8476 6.58697 18.9969 6.07118 18.5038C3.89425 16.4228 2.53916 13.4914 2.53916 10.243C2.53916 7.11727 3.79368 4.28541 5.82764 2.22202C6.3189 1.72366 6.36867 0.893273 5.84463 0.36924Z" fill={style.Text} /> <Path d="M5.84463 0.36924C5.37582 -0.0995746 4.59968 -0.13966 4.10723 0.35111C1.57056 2.8792 0 6.37809 0 10.243C0 14.2583 1.69511 17.8783 4.40753 20.4254C4.90303 20.8906 5.65829 20.8413 6.11707 20.3826C6.65205 19.8476 6.58697 18.9969 6.07118 18.5038C3.89425 16.4228 2.53916 13.4914 2.53916 10.243C2.53916 7.11727 3.79368 4.28541 5.82764 2.22202C6.3189 1.72366 6.36867 0.893273 5.84463 0.36924Z" fill={style.Text} />
@ -335,6 +337,8 @@ export default function Setting() {
<CardMusic image={currentMusic.image} title={currentMusic.title} description={currentMusic.bio} id='1' /> <CardMusic image={currentMusic.image} title={currentMusic.title} description={currentMusic.bio} id='1' />
<Image source={require("../assets/images/FladyShadow.png")} style={styles.mascot} /> <Image source={require("../assets/images/FladyShadow.png")} style={styles.mascot} />
</View> </View>
</>
) : <></>}
<View style={styles.deconnectedOption}> <View style={styles.deconnectedOption}>
<View style={styles.buttonDeconectedOption}> <View style={styles.buttonDeconectedOption}>

@ -159,7 +159,7 @@ export default function SpotPage() {
<FladLoading /> <FladLoading />
</View> </View>
<Text style={{ color: "grey", fontWeight: "400", textAlign: "center", top: 100 }}>Vous avez explorer toutes les spot autour de vous. <Text style={{ color: "grey", fontWeight: "400", textAlign: "center", top: 100 }}>Vous avez explorer toutes les spot autour de vous.
{"\n"}Continuer dans discoverie pour découvrir de nouvelles music basées dur vos gouts musicaux.</Text> {"\n"}Continuer dans discoverie pour découvrir de nouvelles music basées sur vos gouts musicaux.</Text>
</View>) </View>)
} }
</View> </View>

Loading…
Cancel
Save