diff --git a/src/app.css b/src/app.css
index 4980f7f..936a9b8 100644
--- a/src/app.css
+++ b/src/app.css
@@ -9,6 +9,7 @@
--color-ecsess-600: #3B6A3A;
--color-ecsess-800: #0A3D2A;
--color-ecsess-black: #1F1F1F;
+ --color-ecsess-black-hover:#2c2c2c;
}
* {
diff --git a/src/components/FAQAccordion.svelte b/src/components/FAQAccordion.svelte
index e69de29..34ed63a 100644
--- a/src/components/FAQAccordion.svelte
+++ b/src/components/FAQAccordion.svelte
@@ -0,0 +1,114 @@
+
+
+
+ {#snippet iconClosed()}
+
+ {/snippet}
+ {#snippet iconOpen()}
+
+ {/snippet}
+
+ {#each entries as entry, index}
+
+
+ {#snippet lead()}
+ {entry.question}
+ {/snippet}
+ {#snippet control()}{/snippet}
+
+
+ {#snippet panel()}{entry.answer}{/snippet}
+
+ {/each}
+
+
+
+
+
diff --git a/src/routes/+page.server.js b/src/routes/+page.server.js
index 23207c0..97378eb 100644
--- a/src/routes/+page.server.js
+++ b/src/routes/+page.server.js
@@ -2,7 +2,8 @@ import { getFromCMS } from 'utils/utils.js';
const homepageQuery = `*[_type == "homepage"]{
"description": description[],
- "councilPhoto": councilPhoto.asset->url
+ "councilPhoto": councilPhoto.asset->url,
+ "faqs": faqs[]{ question, answer },
}[0]`;
const ohQuery = `*[_type=="oh"].schedule[]{
@@ -13,12 +14,26 @@ const ohQuery = `*[_type=="oh"].schedule[]{
}`;
export const load = async () => {
+ /**
+ * @description Response data type based on the `homepageQuery` above.
+ * Note that `description` is a rich/portable text type
+ *
+ * @type {{
+ * description: import('@portabletext/svelte').InputValue,
+ * councilPhoto: string,
+ * faqs: [{
+ * question: string,
+ * answer: string
+ * }],
+ * }}
+ *
+ */
let CMSresponse = await getFromCMS(homepageQuery);
return {
description: CMSresponse.description,
- councilPhoto: CMSresponse.councilPhoto
+ councilPhoto: CMSresponse.councilPhoto,
+ faqs: CMSresponse.faqs
// ohs: await getFromCMS(ohQuery),
- // FAQs: "",
};
};
diff --git a/src/routes/+page.svelte b/src/routes/+page.svelte
index a5ef384..e2c54cf 100644
--- a/src/routes/+page.svelte
+++ b/src/routes/+page.svelte
@@ -1,6 +1,8 @@
@@ -19,20 +21,17 @@
- Our student council
-
-
-

-
+
+
Our Student Council
+
-
-
-
-
FAQ
-
Under development
+
+
+
+
Office Hours
Under development