diff --git a/src/api/project/project-featured.js b/src/api/project/project-featured.js
new file mode 100644
index 0000000..ecce4fa
--- /dev/null
+++ b/src/api/project/project-featured.js
@@ -0,0 +1,19 @@
+export default async function ProjectFeatured() {
+ try {
+ const res = await fetch(process.env.NEXT_PUBLIC_HOST + "/" + process.env.NEXT_PUBLIC_VERSION + "/project/featured/project", {
+ method: 'GET',
+ headers: {
+ 'Accept': '*/*',
+ 'Content-Type': 'application/json',
+ },
+ }).then((res) => res.json());
+
+ if (res.status === 200) {
+ return {status: "200", data: res.data};
+ } else {
+ return {status: "err"};
+ }
+ } catch {
+ return {status: "err"};
+ }
+};
\ No newline at end of file
diff --git a/src/app/Credits.js b/src/app/Credits.js
index 9e1a4ce..a896496 100644
--- a/src/app/Credits.js
+++ b/src/app/Credits.js
@@ -9,7 +9,7 @@ export default function Credits() {
Meet the masterminds
-
+
diff --git a/src/app/Faqs.js b/src/app/Faqs.js
index ce87642..c1c1e7e 100644
--- a/src/app/Faqs.js
+++ b/src/app/Faqs.js
@@ -39,8 +39,8 @@ export default function Faqs() {
]
return (
-
-
FAQS
+
+
FAQS
{content.map((item, index) => (
@@ -51,9 +51,14 @@ export default function Faqs() {
{activeIndices.includes(index) && (
-
- {item.desc}
-
+ <>
+
+ {item.desc}
+
+
+ {item.desc}
+
+ >
)}
diff --git a/src/app/Featured.js b/src/app/Featured.js
index ef5984c..2bd11e1 100644
--- a/src/app/Featured.js
+++ b/src/app/Featured.js
@@ -1,27 +1,50 @@
+"use client";
+
+import Link from 'next/link';
import Image from 'next/image';
+import { useEffect, useState } from 'react';
import { featured } from './dummy';
+import ProjectFeatured from '@/api/project/project-featured';
+
export default function Featured({ styles }) {
+
+ const [featuredData, setFeaturedData] = useState([]);
+
+ const getFeaturedProject = async () => {
+ const res = await ProjectFeatured();
+
+ if (res.status === "200") {
+ setFeaturedData(res.data);
+ }
+ }
+
+ useEffect(() => {
+ getFeaturedProject();
+ }, []);
+
return (
-
+
{
- featured.map((element, index) => (
+ (featuredData.length !== 0) && featuredData.map((element, index) => (
-
-
-
+
{
- index != featured.length - 1 ? (
-
+ index != featuredData.length - 1 ? (
+
) : (
<>>
)
diff --git a/src/app/Header.js b/src/app/Header.js
index 832fff8..2ca7f64 100644
--- a/src/app/Header.js
+++ b/src/app/Header.js
@@ -14,22 +14,27 @@ export default function Header() {
}
return (
-
+
scrollToSection("main")}>
-
+
-
-