From e2c7c02a9c115fa8ae5aec9c31cfa28dd06b26a4 Mon Sep 17 00:00:00 2001 From: Eamonn de Leastar Date: Thu, 28 Nov 2024 12:43:01 +0000 Subject: [PATCH] animation effect --- src/routes/(home)/CourseList.svelte | 13 +++++++------ src/routes/(home)/CourseVisitCard.svelte | 5 ++++- 2 files changed, 11 insertions(+), 7 deletions(-) diff --git a/src/routes/(home)/CourseList.svelte b/src/routes/(home)/CourseList.svelte index 2e7c064c..830e3a59 100644 --- a/src/routes/(home)/CourseList.svelte +++ b/src/routes/(home)/CourseList.svelte @@ -30,18 +30,19 @@

Favourites

- {#each courseVisits as courseVisit} - {#if courseVisit.favourite} + {#each courseVisits.filter((cv) => cv.favourite) as courseVisit (courseVisit.id)} +
- {/if} +
{/each}
+

Recently accessed

- {#each courseVisits as courseVisit} - {#if !courseVisit.favourite} + {#each courseVisits.filter((cv) => !cv.favourite) as courseVisit (courseVisit.id)} +
- {/if} +
{/each}
diff --git a/src/routes/(home)/CourseVisitCard.svelte b/src/routes/(home)/CourseVisitCard.svelte index 5f44aea1..d099d5a8 100644 --- a/src/routes/(home)/CourseVisitCard.svelte +++ b/src/routes/(home)/CourseVisitCard.svelte @@ -1,10 +1,13 @@