diff --git a/components/landing/CategorySatker.tsx b/components/landing/CategorySatker.tsx index 5d3d25a..b9b2316 100644 --- a/components/landing/CategorySatker.tsx +++ b/components/landing/CategorySatker.tsx @@ -322,9 +322,9 @@ export default function CategorySatker() { }; return ( -
+
-

+

{" "} {t("kategoriSatker")}

diff --git a/components/landing/Footer.tsx b/components/landing/Footer.tsx index 6425f89..24d8c84 100644 --- a/components/landing/Footer.tsx +++ b/components/landing/Footer.tsx @@ -133,7 +133,7 @@ export default function Footer() {
- @@ -255,7 +255,7 @@ export default function Footer() {
- diff --git a/components/landing/HeaderNews.tsx b/components/landing/HeaderNews.tsx index 135e943..ea686c9 100644 --- a/components/landing/HeaderNews.tsx +++ b/components/landing/HeaderNews.tsx @@ -27,16 +27,37 @@ export default function HeaderNews() { const [article, setArticle] = useState([]); const t = useTranslations("Landing"); const [selectedTab, setSelectedTab] = useState("media"); + const [hotNews, setHotNews] = useState([]); + + // useEffect(() => { + + // }, []); useEffect(() => { - async function getArticle() { - const req = { page: 1, search: "", limit: "10" }; - const response = await getListArticle(req); - setArticle(response?.data?.data); - } getArticle(); + + getHotNews(); }, []); + async function getArticle() { + const req = { page: 1, search: "", limit: "10", sort: "desc" }; + const response = await getListArticle(req); + setArticle(response?.data?.data); + } + + async function getHotNews() { + const req = { + page: 1, + search: "", + limit: "10", + sortBy: "view_count", + sort: "desc", + }; + const response = await getListArticle(req); + setHotNews(response?.data?.data); + console.log("sadadasdasd", response?.data?.data); + } + return (
@@ -113,7 +134,7 @@ export default function HeaderNews() { {t("berita")}

- {article?.map((data: any, index: number) => ( + {hotNews?.map((data: any, index: number) => (
) : ( -
- +
+ + IKLAN LAYANAN MASYARAKAT DIVHUMAS POLRI - POLRI PRESISI UNTUK + INDONESIA + + + ILM DIVHUMAS POLRI - POLRI PRESISI MENGAWAL PROSES VAKSINASI UNTUK + MENGATASI PANDEMI COVID 19 + + + IKLAN LAYANAN MASYARAKAT DIVHUMAS POLRI - INDONESIA MENOLAK + RADIKALISME + + + IKLAN LAYANAN MASYARAKAT DIVHUMAS POLRI - BHABINKAMTIBMAS SAHABAT + MASYARAKAT +
)}
diff --git a/components/landing/MedolUpdate.tsx b/components/landing/MedolUpdate.tsx index 4b7a280..37f28d8 100644 --- a/components/landing/MedolUpdate.tsx +++ b/components/landing/MedolUpdate.tsx @@ -85,11 +85,15 @@ export default function MedolUpdate() {
- - - - - - {t("tentang")} Humas POLRI - - - - - - {t("profilPimpinan")} - - - - - - {t("strukturOrganisasi")} - - - - - - {t("visi")} & {t("misi")} - - - - - - {t("tugas")} & {t("fungsi")} - - - - - - Logo - - - - - - setIsOpen(state)} > @@ -579,6 +495,84 @@ export default function NavbarHumas(props: { size: string }) { + */} + setIsOpen(state)} + > + + + + + + + + + Informasi Berkala + + + + + + Informasi Serta Merta + + + + + + Informasi Setiap Saat + + + + + + Informasi Dikecualikan + + + + + + UU & Peraturan + + + +