diff --git a/src/components/CreateSection.jsx b/src/components/CreateSection.jsx index 32aff4f..7a48250 100644 --- a/src/components/CreateSection.jsx +++ b/src/components/CreateSection.jsx @@ -21,7 +21,6 @@ function CreateSection() { return; } setStep(step + 1); - } const prevStep = () => { setStep(step - 1); diff --git a/src/components/create/Step1.jsx b/src/components/create/Step1.jsx index 2f05808..75c85fc 100644 --- a/src/components/create/Step1.jsx +++ b/src/components/create/Step1.jsx @@ -23,6 +23,7 @@ const props = { }, }; + function Step1({nextStep, topic, setTopic, message}) { return (
@@ -36,7 +37,7 @@ function Step1({nextStep, topic, setTopic, message}) {
{'ERROR: ' + message}
- setTopic(e.target.value)} placeholder= 'Type or paste (Ctrl+V) your text here or upload a document.'/> + setTopic(e.target.value)} placeholder='Type or paste (Ctrl+V) your text here or upload a document'/>
Words Per Slide
setWordsPerSlide(e.target.value)} /> + +
+ + + + {isFetchLoading &&
diff --git a/src/pages/editor/index.jsx b/src/pages/editor/index.jsx index 035e1c5..735c66c 100644 --- a/src/pages/editor/index.jsx +++ b/src/pages/editor/index.jsx @@ -19,6 +19,7 @@ export default function EditorPage() { }; const deletePage = (pageId) => { + if(canvasPages.length === 1) return; const updatedPages = canvasPages.filter((pId) => (pId != pageId)); EditorRefs.current = EditorRefs.current.filter((ref) => (ref != null)); setCanvasPages(updatedPages); @@ -62,7 +63,7 @@ export default function EditorPage() { <>
-
+
{canvasPages.map((pageId, index) => (