diff --git a/.babelrc b/.babelrc deleted file mode 100644 index 782ae74..0000000 --- a/.babelrc +++ /dev/null @@ -1,8 +0,0 @@ -{ - "presets": ["next/babel"], - "env": { - "development": { - "plugins": ["./src/plugins/add-data-locator.js"] - } - } -} diff --git a/AGENTS.md b/AGENTS.md index faaeb18..8bd0e39 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -2,4 +2,4 @@ # This is NOT the Next.js you know This version has breaking changes — APIs, conventions, and file structure may all differ from your training data. Read the relevant guide in `node_modules/next/dist/docs/` before writing any code. Heed deprecation notices. - \ No newline at end of file + diff --git a/public/assets/images/Group 1.svg b/public/assets/images/Group 1.svg deleted file mode 100644 index 6840505..0000000 --- a/public/assets/images/Group 1.svg +++ /dev/null @@ -1,5 +0,0 @@ - - - - - diff --git a/public/assets/images/Intro-Quran.png b/public/assets/images/Intro-Quran.png deleted file mode 100644 index 5558222..0000000 Binary files a/public/assets/images/Intro-Quran.png and /dev/null differ diff --git a/public/assets/images/Intro-location.png b/public/assets/images/Intro-location.png deleted file mode 100644 index fcbc3a5..0000000 Binary files a/public/assets/images/Intro-location.png and /dev/null differ diff --git a/public/assets/images/Rectangle 3077.png b/public/assets/images/Rectangle 3077.png deleted file mode 100644 index 67fac5b..0000000 Binary files a/public/assets/images/Rectangle 3077.png and /dev/null differ diff --git a/src/app/details/[section]/detail-section-client.tsx b/src/app/details/[section]/detail-section-client.tsx deleted file mode 100644 index 24b9a05..0000000 --- a/src/app/details/[section]/detail-section-client.tsx +++ /dev/null @@ -1,197 +0,0 @@ -"use client"; - -import Link from "next/link"; -import { useEffect, useMemo, useState } from "react"; -import { - BackIcon, - FabricCard, - FabricIconLink, - FabricPill, - FabricProgress, - FabricScreen, - FabricStatusBar, - fabricInputClass, - fabricMutedPanelClass, - fabricSecondaryButtonClass, - fabricTextareaClass, -} from "@/components/ui/fabric-mobile"; -import { - countCompletedDetailedAnswers, - type DetailedSection, - getDetailedSectionProgress, - getDetailedSectionStorageKey, -} from "@/lib/detailed-questions"; - -export default function DetailSectionClient({ - section, -}: { - section: DetailedSection; -}) { - const [answers, setAnswers] = useState>({}); - const [isHydrated, setIsHydrated] = useState(false); - - useEffect(() => { - const savedAnswers = window.localStorage.getItem( - getDetailedSectionStorageKey(section.id), - ); - - setAnswers( - savedAnswers ? (JSON.parse(savedAnswers) as Record) : {}, - ); - setIsHydrated(true); - }, [section.id]); - - useEffect(() => { - if (!isHydrated) { - return; - } - - window.localStorage.setItem( - getDetailedSectionStorageKey(section.id), - JSON.stringify(answers), - ); - }, [answers, isHydrated, section.id]); - - const completedCount = useMemo( - () => countCompletedDetailedAnswers(section, answers), - [answers, section], - ); - const progress = useMemo( - () => getDetailedSectionProgress(section, answers), - [answers, section], - ); - - const handleChange = (questionId: string, value: string) => { - setAnswers((currentAnswers) => ({ - ...currentAnswers, - [questionId]: value, - })); - }; - - return ( - - - -
- - - - -
-

Section details

-

- {section.title} -

-
- - - {progress}% - -
- - -

Section progress

-

- {section.title} -

-

- {section.description} -

- - - -

- {completedCount} of {section.questions.length} questions answered -

-
- -
-

- Answers are saved automatically while you type, so you can return to - the section list at any time. -

-
- -
- {section.questions.map((question, index) => { - const value = answers[question.id] ?? ""; - - return ( - -
-
-

Prompt {index + 1}

-

- {question.label} -

-
- - {value.trim().length > 0 ? "Done" : "Open"} - -
- -

- {question.description} -

- -
- {question.type === "textarea" ? ( -