feat(ui): add topic, subject screen

fix(api): fix api endpoint logic for pretest screen
This commit is contained in:
shafin-r
2025-08-21 14:19:55 +06:00
parent be5c723bff
commit 6f4f2a8668
8 changed files with 369 additions and 105 deletions

View File

@ -77,67 +77,67 @@ const HomePage = () => {
<ChevronRight size={24} color="#113768" />
</button>
</div>
<div className={styles.categoriesContainer}>
<div className={styles.categoryRow}>
<button
onClick={() => router.push("/topics")}
className={`${styles.categoryButton} `}
>
<Image
src="/images/icons/topic-test.png"
alt="Topic Test"
width={85}
height={85}
/>
<span className={styles.categoryButtonText}>
Topic Test
</span>
</button>
<button
onClick={() => router.push("/mocks")}
className={styles.categoryButton}
>
<Image
src="/images/icons/mock-test.png"
alt="Mock Test"
width={85}
height={85}
/>
<span className={styles.categoryButtonText}>
Mock Test
</span>
</button>
</div>
<div className={styles.categoryRow}>
<button
disabled
className={`${styles.categoryButton} ${styles.disabled}`}
>
<Image
src="/images/icons/past-paper.png"
alt="Past Papers"
width={68}
height={68}
/>
<span className={styles.categoryButtonText}>
Past Papers
</span>
</button>
<button
onClick={() => router.push("/subjects")}
className={`${styles.categoryButton}`}
>
<Image
src="/images/icons/subject-test.png"
alt="Subject Test"
width={80}
height={80}
/>
<span className={styles.categoryButtonText}>
Subject Test
</span>
</button>
</div>
<div className="grid grid-cols-2 gap-4 pt-6 ">
<button
onClick={() => router.push("/categories/topics")}
className="flex flex-col justify-center items-center border-[1px] border-blue-200 aspect-square rounded-3xl gap-2 bg-white"
>
<Image
src="/images/icons/topic-test.png"
alt="Topic Test"
width={85}
height={85}
/>
<span className="font-medium text-[#113768]">
Topic Test
</span>
</button>
<button
onClick={() => router.push("/categories/mocks")}
className="flex flex-col justify-center items-center border-[1px] border-blue-200 aspect-square rounded-3xl gap-2 bg-white"
>
<Image
src="/images/icons/mock-test.png"
alt="Mock Test"
width={85}
height={85}
/>
<span className="font-medium text-[#113768]">
Mock Test
</span>
</button>
<button
disabled
className="flex flex-col justify-center items-center border-[1px] border-blue-200 aspect-square rounded-3xl gap-2 bg-white"
>
<Image
src="/images/icons/past-paper.png"
alt="Past Papers"
width={68}
height={68}
className="opacity-50"
/>
<span className="font-medium text-[#113768]/50">
Past Papers
</span>
</button>
<button
onClick={() => router.push("/categories/subjects")}
className="flex flex-col justify-center items-center border-[1px] border-blue-200 aspect-square rounded-3xl gap-2 bg-white"
>
<Image
src="/images/icons/subject-test.png"
alt="Subject Test"
width={80}
height={80}
/>
<span className="font-medium text-[#113768]">
Subject Test
</span>
</button>
</div>
</div>