fixes
This commit is contained in:
@@ -6,6 +6,7 @@ import React, {
|
||||
useState,
|
||||
} from "react";
|
||||
import { Alert, Platform, StyleSheet, View } from "react-native";
|
||||
import useMinuit from "react-native-minuit/src/hooks/useMinuit.js";
|
||||
import { background } from "../../assets";
|
||||
import BorderGradientButton from "../../components/BorderGradientButton";
|
||||
import FeatureCarousel from "../../components/FeatureCarousel/FeatureCarousel";
|
||||
@@ -13,10 +14,10 @@ import GradientButton from "../../components/GradientButton";
|
||||
import MoreMenu from "../../components/MoreMenu";
|
||||
import ProjectDropDown from "../../components/ProjectDropDown/ProjectDropDown";
|
||||
import ShareBtn from "../../components/ShareBtn/ShareBtn";
|
||||
import { projectsRef } from "../../config/firebase";
|
||||
import { isWeb } from "../../hooks/useLayoutType.js";
|
||||
import Page from "../../layouts/Page";
|
||||
import { navigate } from "../../navigation/NavigationService";
|
||||
import { projectsRef } from "../../config/firebase";
|
||||
import { useUser } from "../../providers/UserDataProvider";
|
||||
import { gutters, Palette } from "../../styles";
|
||||
import {
|
||||
@@ -24,7 +25,6 @@ import {
|
||||
getCreationStageStates,
|
||||
getStageAction,
|
||||
} from "../../utils/projectStages";
|
||||
import useMinuit from "react-native-minuit/src/hooks/useMinuit.js";
|
||||
|
||||
const Home = () => {
|
||||
const {
|
||||
@@ -38,7 +38,7 @@ const Home = () => {
|
||||
|
||||
const projects = useMemo(
|
||||
() => (Array.isArray(userProjects) ? userProjects : []),
|
||||
[userProjects],
|
||||
[userProjects]
|
||||
);
|
||||
|
||||
const currentProject = useMemo(() => {
|
||||
@@ -71,7 +71,7 @@ const Home = () => {
|
||||
|
||||
const stageStates = useMemo(
|
||||
() => getCreationStageStates(currentProject),
|
||||
[currentProject],
|
||||
[currentProject]
|
||||
);
|
||||
|
||||
const firstUnlockedIndex = useMemo(() => {
|
||||
@@ -105,7 +105,7 @@ const Home = () => {
|
||||
selectProject(project.id);
|
||||
setActiveStageIndex(findFirstUnlockedStageIndex(project));
|
||||
},
|
||||
[selectProject],
|
||||
[selectProject]
|
||||
);
|
||||
|
||||
const handleCloseMenu = useCallback(() => {
|
||||
@@ -173,7 +173,7 @@ const Home = () => {
|
||||
},
|
||||
},
|
||||
],
|
||||
{ cancelable: true },
|
||||
{ cancelable: true }
|
||||
),
|
||||
},
|
||||
];
|
||||
@@ -219,7 +219,7 @@ const Home = () => {
|
||||
|
||||
const songwriterAction = useMemo(
|
||||
() => getStageAction("songwriter", null),
|
||||
[],
|
||||
[]
|
||||
);
|
||||
|
||||
const handleStartNew = useCallback(() => {
|
||||
@@ -229,7 +229,7 @@ const Home = () => {
|
||||
console.log(
|
||||
"navigating to",
|
||||
songwriterAction.route,
|
||||
songwriterAction.params,
|
||||
songwriterAction.params
|
||||
);
|
||||
navigate(songwriterAction.route, songwriterAction.params);
|
||||
}
|
||||
@@ -303,6 +303,12 @@ const Home = () => {
|
||||
onPress={handleStageAction}
|
||||
disabled={continueDisabled}
|
||||
/>
|
||||
{/* <BorderGradientButton
|
||||
containerStyle={{ width: Platform.OS === "web" ? 250 : "100%" }}
|
||||
title={"Continuer la création"}
|
||||
onPress={() => navigate(Routes.SongReady)}
|
||||
disabled={continueDisabled}
|
||||
/> */}
|
||||
</View>
|
||||
</View>
|
||||
</Page>
|
||||
|
||||
Reference in New Issue
Block a user