feat: add polda/kaltara

This commit is contained in:
Sabda Yagra 2025-03-25 00:22:16 +07:00
parent 71d755863e
commit 225313a5bd
20 changed files with 1348 additions and 288 deletions

View File

@ -1,3 +1,5 @@
"use client";
import LayoutProvider from "@/providers/layout.provider";
import LayoutContentProvider from "@/providers/content.provider";
import DashCodeSidebar from "@/components/partials/sidebar";
@ -8,9 +10,15 @@ import DashCodeHeader from "@/components/partials/header";
import { redirect } from "@/components/navigation";
import Footer from "@/components/landing-page/footer";
import Navbar from "@/components/landing-page/navbar";
import NavbarKaltara from "@/components/landing-page/landing-polda-kaltara/navbar-polda-kaltara";
import { useParams } from "next/navigation";
const layout = async ({ children }: { children: React.ReactNode }) => {
return (
const layout = ({ children }: { children: React.ReactNode }) => {
const params = useParams();
const poldaName: any = params?.polda_name;
return poldaName === "kaltara" ? (
children
) : (
<>
<Navbar />
{children}

View File

@ -5,9 +5,29 @@ import HeaderBanner from "@/components/landing-page/header-banner";
import NewContent from "@/components/landing-page/new-content";
import WelcomePolda from "@/components/landing-page/welcome-polda";
import React from "react";
import { useParams } from "next/navigation";
import NavbarKaltara from "@/components/landing-page/landing-polda-kaltara/navbar-polda-kaltara";
import HeaderBannerKaltara from "@/components/landing-page/landing-polda-kaltara/header-banner-kaltara";
import SearchSectionKaltara from "@/components/landing-page/landing-polda-kaltara/search-section-kaltara";
import LatestContentKaltara from "@/components/landing-page/landing-polda-kaltara/latest-content-kaltara";
import ContactUsKaltara from "@/components/landing-page/landing-polda-kaltara/contact-us-kaltara";
import NewsTickerKaltara from "../../tbnews/[polda_name]/components/news-tickers-kaltara";
const page = () => {
return (
const params = useParams();
const poldaName: any = params?.polda_name;
return poldaName === "kaltara" ? (
<div>
<NavbarKaltara />
<HeaderBannerKaltara />
<SearchSectionKaltara />
<LatestContentKaltara group="polda" type="latest" />
<LatestContentKaltara group="polda" type="popular" />
<ContentCategory group="polda" />
<ContactUsKaltara />
<NewsTickerKaltara />
</div>
) : (
<div>
<HeaderBanner />
<WelcomePolda />

View File

@ -114,7 +114,7 @@ const HeroKaltara = () => {
return (
<>
<Reveal>
<div className="flex flex-col lg:flex-row items-start justify-center gap-8 px-4 lg:px-20 py-4 mt-36">
<div className="flex flex-col lg:flex-row items-start justify-center gap-8 px-4 lg:px-20 w-full py-4 mt-36">
{isBannerLoading ? (
<div className="flex flex-col space-y-3 mx-auto w-full lg:w-2/3">
<Skeleton className="h-[310px] lg:h-[420px] rounded-xl" />
@ -126,19 +126,19 @@ const HeroKaltara = () => {
) : (
<div className="w-full lg:h-full">
{content?.map((row: any, index: number) => (
<div className="flex flex-col gap-3" key={index}>
<div className="flex flex-col gap-[10px]" key={index}>
<Link href={prefixPath + `/video/detail/${row.slug}`}>
<Image src={row?.thumbnailLink} alt="gambar-utama" width={1920} height={1080} className="w-full h-[310px] lg:h-[520px] rounded-sm object-cover" />
<Image src={row?.thumbnailLink} alt="gambar-utama" width={1920} height={1080} className="w-full h-[200px] lg:h-[500px] rounded-sm object-cover" />
</Link>
<h1 className="font-bold text-xl">{row.title}</h1>
<h1 className="font-bold font-sans text-[30px]">{row.title}</h1>
<div className="flex flex-row gap-3">
<p className="text-[#c03724] text-sm">{row?.categoryName}</p>
<p className="text-xs flex flex-row items-center text-slate-500 dark:text-white gap-1">
{getPublicLocaleTimestamp(new Date(row?.createdAt))}
<p className="text-[#c03724] font-sans text-[16px]">{row?.categoryName}</p>
<p className="text-[16px] font-sans flex flex-row items-center text-slate-500 dark:text-white gap-1">
{getPublicLocaleTimestamp(new Date(row?.createdAt))}
{/* {row?.createdAt} */}
</p>
</div>
<p className="text-light text-justify" dangerouslySetInnerHTML={{ __html: row?.description }} />
<p className="text-[16px] font-sans text-justify" dangerouslySetInnerHTML={{ __html: row?.description }} />
</div>
))}
</div>
@ -183,17 +183,17 @@ const HeroKaltara = () => {
</div>
</div>
) : (
<div className="py-4 lg:py-0 flex flex-col gap-4 flex-nowrap w-[95vw] lg:w-[30%] overflow-x-auto">
<div className="py-4 lg:py-0 flex flex-col flex-nowrap w-[95vw] lg:w-[30%] overflow-x-auto gap-[20px]">
{newContent?.slice(1).map((item: any, index: number) => (
<div className="flex gap-3 flex-col lg:w-full" key={index}>
<div className="flex gap-[6px] flex-col lg:w-full" key={index}>
<div className="flex-shrink-0 rounded-lg">
<Image width={720} height={480} src={item?.thumbnailLink} alt="" className="w-full h-[105px] object-cover rounded-sm" />
<Image width={720} height={480} src={item?.thumbnailLink} alt="" className="w-full h-[120px] object-cover rounded-sm" />
</div>
<div className="w-[280px] lg:w-auto flex flex-col">
<h3 className="font-bold text-lg">{item?.title}</h3>
<div className="w-[280px] lg:w-auto flex flex-col gap-[6px]">
<h3 className="font-bold text-[14px] font-sans">{item?.title}</h3>
<div className="flex flex-row gap-5">
<p className="text-[#c03724] text-sm">{item?.categoryName}</p>
<p className="text-xs flex flex-row items-center text-slate-500 dark:text-white gap-1">
<p className="text-[#c03724] text-[12px] font-sans">{item?.categoryName}</p>
<p className="text-[12px] font-sans flex flex-row items-center text-slate-500 dark:text-white gap-1">
{/* {formatDateToIndonesian(new Date(item?.createdAt))} {item?.timezone ? item?.timezone : "WIB"} */}
{item?.createdAt}
</p>

View File

@ -151,16 +151,16 @@ const LatestNews = (props: { type: string }) => {
) : (
<div className="w-full lg:w-2/3 lg:h-full">
{newContent?.slice(0, 1).map((row: any) => (
<div className="flex flex-col gap-3" key={row?.id}>
<Image src={row?.thumbnailLink} alt="gambar-utama" width={1920} height={1080} className="w-full h-[310px] lg:h-[420px] rounded-sm object-cover" /> <h1 className="font-bold text-xl">{row?.title}</h1>
<div className="flex flex-row gap-3">
<p className="text-[#c03724] text-xs">{row?.categoryName}</p>
<p className="text-xs flex flex-row items-center text-slate-500 dark:text-white gap-1">
<div className="flex flex-col gap-[10px]" key={row?.id}>
<Image src={row?.thumbnailLink} alt="gambar-utama" width={1920} height={1080} className="w-full h-[200px] lg:h-[300px] rounded-sm object-cover" /> <h1 className="font-bold text-[16px] font-sans">{row?.title}</h1>
<div className="flex flex-row gap-[10px]">
<p className="text-[#c03724] text-[12px] font-sans">{row?.categoryName}</p>
<p className="text-[12px] font-sans flex flex-row items-center text-slate-500 dark:text-white">
{/* {formatDateToIndonesian(new Date(row?.createdAt))} {row?.timezone ? row?.timezone : "WIB"}|{" "} */}
{row?.createdAt}
</p>
</div>
<p className="text-light text-justify">{row?.description}</p>
<p className="text-[14px] font-sans text-justify">{row?.description}</p>
</div>
))}
</div>
@ -205,17 +205,17 @@ const LatestNews = (props: { type: string }) => {
</div>
</div>
) : (
<div className="py-4 lg:py-0 flex flex-col gap-4 flex-nowrap w-[95vw] lg:w-[30%] overflow-x-auto">
<div className="py-4 lg:py-0 flex flex-col gap-[20px] flex-nowrap w-[95vw] lg:w-[30%] overflow-x-auto">
{newContent?.slice(1).map((item: any) => (
<div className="flex gap-3 flex-col lg:w-full">
{/* <div className="flex-shrink-0 rounded-lg">
<Image width={720} height={480} src={item?.thumbnailLink} alt="" className="w-full h-[105px] object-cover rounded-sm" />
</div> */}
<div className="w-[280px] lg:w-auto flex flex-col gap-5">
<h3 className="font-bold text-lg">{item?.title}</h3>
<div className="w-[280px] lg:w-auto flex flex-col gap-[10px]">
<h3 className="font-bold text-[16px] font-sans">{item?.title}</h3>
<div className="flex flex-row gap-5">
<p className="text-[#c03724] text-sm">{item?.categoryName}</p>
<p className="text-xs flex flex-row items-center text-slate-500 dark:text-white gap-1">
<p className="text-[#c03724] text-[12px] font-sans">{item?.categoryName}</p>
<p className="text-[12px] font-sans flex flex-row items-center text-slate-500 dark:text-white">
{/* {formatDateToIndonesian(new Date(item?.createdAt))} {item?.timezone ? item?.timezone : "WIB"}|{" "} */}
{item?.createdAt}
</p>

View File

@ -148,16 +148,16 @@ const NationalNews = () => {
) : (
<div className="w-full lg:w-2/3 lg:h-full">
{newContent?.slice(0, 1).map((row: any) => (
<div className="flex flex-col gap-3">
<Image src={row?.thumbnailLink} alt="gambar-utama" width={1920} height={1080} className="w-full h-[310px] lg:h-[420px] rounded-sm object-cover" /> <h1 className="font-bold text-xl">{row?.title}</h1>
<div className="flex flex-row gap-3">
<p className="text-[#c03724] text-xs">{row?.categoryName}</p>
<p className="text-xs flex flex-row items-center text-slate-500 dark:text-white gap-1">
<div className="flex flex-col gap-[10px]">
<Image src={row?.thumbnailLink} alt="gambar-utama" width={1920} height={1080} className="w-full h-[200px] lg:h-[300px] rounded-sm object-cover" /> <h1 className="font-bold text-[16px] font-sans">{row?.title}</h1>
<div className="flex flex-row gap-[10px]">
<p className="text-[#c03724] text-[12px] font-sans">{row?.categoryName}</p>
<p className="text-[12px] font-sans flex flex-row items-center text-slate-500 dark:text-white">
{/* {formatDateToIndonesian(new Date(row?.createdAt))} {row?.timezone ? row?.timezone : "WIB"}|{" "} */}
{row?.createdAt}
</p>
</div>
<p className="text-light text-justify">{row?.description}</p>
<p className="text-[14px] font-sans text-justify">{row?.description}</p>
</div>
))}
</div>
@ -202,17 +202,17 @@ const NationalNews = () => {
</div>
</div>
) : (
<div className="py-4 lg:py-0 flex flex-col gap-4 flex-nowrap w-[95vw] lg:w-[30%] overflow-x-auto">
<div className="py-4 lg:py-0 flex flex-col gap-[20px] flex-nowrap w-[95vw] lg:w-[30%] overflow-x-auto">
{newContent?.slice(1).map((item: any) => (
<div className="flex gap-3 flex-col lg:w-full">
{/* <div className="flex-shrink-0 rounded-lg">
<Image width={720} height={480} src={item?.thumbnailLink} alt="" className="w-full h-[105px] object-cover rounded-sm" />
</div> */}
<div className="w-[280px] lg:w-auto flex flex-col gap-5">
<h3 className="font-bold text-lg">{item?.title}</h3>
<div className="w-[280px] lg:w-auto flex flex-col gap-[10px]">
<h3 className="font-bold text-[16px] font-sans">{item?.title}</h3>
<div className="flex flex-row gap-5">
<p className="text-[#c03724] text-sm">{item?.categoryName}</p>
<p className="text-xs flex flex-row items-center text-slate-500 dark:text-white gap-1">
<p className="text-[#c03724] text-[12px] font-sans">{item?.categoryName}</p>
<p className="text-[12px] font-sans flex flex-row items-center text-slate-500 dark:text-white">
{/* {formatDateToIndonesian(new Date(item?.createdAt))} {item?.timezone ? item?.timezone : "WIB"}|{" "} */}
{item?.createdAt}
</p>

View File

@ -53,7 +53,7 @@ const NavbarKaltara = () => {
return (
<div className="bg-[#c03724] w-full py-3 px-4 lg:px-20 items-center fixed top-0 z-50">
<div className="flex flex-row justify-between items-center">
<Link href="/">
<Link href="/tbnews/polda-kaltara">
<Image width={2560} height={1440} src="/assets/img/logo-new-tbnews.png" alt="image" className="h-28 w-72" />
</Link>
<div className="flex flex-row">

View File

@ -1,10 +1,11 @@
"use client";
import { Link } from "@/i18n/routing";
import { getHeroData, listCarousel } from "@/service/landing/landing";
import { getHeroData, listCarousel, listData } from "@/service/landing/landing";
import { formatDateToIndonesian, textEllipsis } from "@/utils/globals";
import { useEffect, useState } from "react";
import { useTranslations } from "next-intl";
import { Icon } from "@/components/ui/icon";
import { useParams } from "next/navigation";
export default function NewsTickerKaltara() {
const [article, setArticle] = useState<any>([]);
@ -12,6 +13,11 @@ export default function NewsTickerKaltara() {
const [animate, setAnimate] = useState(false);
const [tanggal, setTanggal] = useState("");
const t = useTranslations("LandingPage");
const [content, setContent] = useState<any>([]);
const [isBannerLoading, setIsBannerLoading] = useState(true);
const [centerPadding, setCenterPadding] = useState<any>();
const params = useParams();
const poldaName: any = params?.polda_name;
useEffect(() => {
const options: Intl.DateTimeFormatOptions = {
@ -25,12 +31,63 @@ export default function NewsTickerKaltara() {
}, []);
useEffect(() => {
async function getArticle() {
const response = await getHeroData();
setArticle(response?.data?.data?.content);
// async function initState() {
// const res = await listCarousel();
// setContent(res?.data?.data);
// setCenterPadding(`${Math.trunc(Number(window.innerWidth) / 10 + 40)}px`);
// }
async function fetchData() {
const res = await listData("1", "", "", 5, 0, "createdAt", "", "", poldaName);
let data = res?.data?.data?.content;
setContent(data);
setCenterPadding(`${Math.trunc(Number(window.innerWidth) / 10 + 40)}px`);
setIsBannerLoading(false);
console.log("Done");
}
getArticle();
}, []);
fetchData();
}, [params?.page]);
const settings = {
className: "center",
// centerMode: true,
infinite: true,
centerPadding,
slidesToShow: 2,
autoplay: true,
speed: 1500,
autoplaySpeed: 15_000,
focusOnSelect: true,
responsive: [
{
breakpoint: 768,
settings: {
arrows: false,
centerMode: true,
centerPadding: "60px",
slidesToShow: 1,
},
},
{
breakpoint: 480,
settings: {
arrows: false,
centerMode: true,
centerPadding: "20px",
slidesToShow: 1,
},
},
],
};
// useEffect(() => {
// async function getArticle() {
// const response = await getHeroData();
// setArticle(response?.data?.data?.content);
// }
// getArticle();
// }, []);
const triggerAnimation = (newIndex: number) => {
setAnimate(true);
@ -41,22 +98,22 @@ export default function NewsTickerKaltara() {
};
const handlePrev = () => {
const newIndex = (currentNewsIndex - 1 + article.length) % article.length;
const newIndex = (currentNewsIndex - 1 + content.length) % content.length;
triggerAnimation(newIndex);
};
const handleNext = () => {
const newIndex = (currentNewsIndex + 1) % article.length;
const newIndex = (currentNewsIndex + 1) % content.length;
triggerAnimation(newIndex);
};
useEffect(() => {
const interval = setInterval(() => {
triggerAnimation((currentNewsIndex + 1) % article.length);
triggerAnimation((currentNewsIndex + 1) % content.length);
}, 7000);
return () => clearInterval(interval);
}, [article?.length]);
}, [content?.length]);
return (
<div className="fixed bottom-0 z-50 flex flex-row h-[60px] gap-3 w-full justify-between dark:bg-stone-800 bg-[#bb3523]">
@ -66,13 +123,13 @@ export default function NewsTickerKaltara() {
</div>
<div className="text-[13px] lg:text-base w-full lg:w-[200px] text-white font-semibold ml-2 lg:ml-5 flex items-center">{t("breakingNews")} :</div>
<div className={`w-full px-2 lg:px-5 py-1 flex flex-col lg:flex-row items-center gap-1 transition-transform duration-300 ${animate ? "opacity-0 translate-y-5" : "opacity-100 translate-y-0"}`}>
<Link href={`news/detail/${article[currentNewsIndex]?.id}`} className="hidden lg:block">
<p className="text-[11px] text-white lg:text-base">{article[currentNewsIndex]?.title}</p>
<Link href={`news/detail/${content[currentNewsIndex]?.id}`} className="hidden lg:block">
<p className="text-[11px] text-white lg:text-base">{content[currentNewsIndex]?.title}</p>
</Link>
<Link href={`news/detail/${article[currentNewsIndex]?.id}`} className="lg:hidden">
<p className="text-[11px] text-white lg:text-base">{textEllipsis(article[currentNewsIndex]?.title, 28)}</p>
<Link href={`news/detail/${content[currentNewsIndex]?.id}`} className="lg:hidden">
<p className="text-[11px] text-white lg:text-base">{textEllipsis(content[currentNewsIndex]?.title, 28)}</p>
</Link>
<p className="text-[8px] lg:text-xs text-white">{formatDateToIndonesian(article[currentNewsIndex]?.createdAt)}</p>
<p className="text-[8px] lg:text-xs text-white">{formatDateToIndonesian(content[currentNewsIndex]?.createdAt)}</p>
</div>
<div className="flex flex-row text-white h-full gap-[1px]">
<a className="bg-[#bb3523] h-full flex items-center cursor-pointer" onClick={() => handlePrev()}>

View File

@ -141,16 +141,16 @@ const RegionalNews = () => {
) : (
<div className="w-full lg:w-2/3 lg:h-full">
{newContent?.slice(0, 1).map((row: any) => (
<div className="flex flex-col gap-3">
<Image src={row?.thumbnailLink} alt="gambar-utama" width={1920} height={1080} className="w-full h-[310px] lg:h-[420px] rounded-sm object-cover" /> <h1 className="font-bold text-xl">{row?.title}</h1>
<div className="flex flex-col gap-[10px]">
<Image src={row?.thumbnailLink} alt="gambar-utama" width={1920} height={1080} className="w-full h-[200px] lg:h-[300px] rounded-sm object-cover" /> <h1 className="font-bold text-[16px] font-sans">{row?.title}</h1>
<div className="flex flex-row gap-3">
<p className="text-[#c03724] text-xs">{row?.categoryName}</p>
<p className="text-xs flex flex-row items-center text-slate-500 dark:text-white gap-1">
<p className="text-[#c03724] text-[12px] font-sans">{row?.categoryName}</p>
<p className="text-[12px] font-sans flex flex-row items-center text-slate-500 dark:text-white">
{/* {formatDateToIndonesian(new Date(row?.createdAt))} {row?.timezone ? row?.timezone : "WIB"}|{" "} */}
{row?.createdAt}
</p>
</div>
<p className="text-light text-justify">{row?.description}</p>
<p className="text-[14px] font-sans text-justify">{row?.description}</p>
</div>
))}
</div>
@ -201,11 +201,11 @@ const RegionalNews = () => {
{/* <div className="flex-shrink-0 rounded-lg">
<Image width={720} height={480} src={item?.thumbnailLink} alt="" className="w-full h-[105px] object-cover rounded-sm" />
</div> */}
<div className="w-[280px] lg:w-auto flex flex-col gap-5">
<h3 className="font-bold text-lg">{item?.title}</h3>
<div className="w-[280px] lg:w-auto flex flex-col gap-[10px]">
<h3 className="font-bold text-[16px] font-sans">{item?.title}</h3>
<div className="flex flex-row gap-5">
<p className="text-[#c03724] text-sm">{item?.categoryName}</p>
<p className="text-xs flex flex-row items-center text-slate-500 dark:text-white gap-1">
<p className="text-[#c03724] text-[12px] font-sans">{item?.categoryName}</p>
<p className="text-[12px] font-sans flex flex-row items-center text-slate-500 dark:text-white">
{/* {formatDateToIndonesian(new Date(item?.createdAt))} {item?.timezone ? item?.timezone : "WIB"}|{" "} */}
{item?.createdAt}
</p>

View File

@ -22,28 +22,28 @@ const SocialMedia = () => {
>
X{" "}
</TabsTrigger>
<div className="text-[#bb3523] text-lg hidden md:inline-block">|</div>
<div className="text-[#c03724] text-lg hidden md:inline-block">|</div>
<TabsTrigger
value="instagram"
className="relative text-xs md:text-xl font-bold text-black dark:text-white dark:bg-transparent before:absolute before:top-full before:left-0 before:h-px before:w-full data-[state=active]:before:bg-primary"
>
Instagram
</TabsTrigger>
<div className="text-[#bb3523] text-lg hidden md:inline-block">|</div>
<div className="text-[#c03724] text-lg hidden md:inline-block">|</div>
<TabsTrigger
value="facebook"
className="relative text-xs md:text-xl font-bold text-black dark:text-white dark:bg-transparent before:absolute before:top-full before:left-0 before:h-px before:w-full data-[state=active]:before:bg-primary"
>
Facebook
</TabsTrigger>
<div className="text-[#bb3523] text-lg hidden md:inline-block">|</div>
<div className="text-[#c03724] text-lg hidden md:inline-block">|</div>
<TabsTrigger
value="tiktok"
className="relative text-xs md:text-xl font-bold text-black dark:text-white dark:bg-transparent before:absolute before:top-full before:left-0 before:h-px before:w-full data-[state=active]:before:bg-primary"
>
Tiktok
</TabsTrigger>
<div className="text-[#bb3523] text-lg hidden md:inline-block">|</div>
<div className="text-[#c03724] text-lg hidden md:inline-block">|</div>
<TabsTrigger
value="youtube"
className="relative text-xs md:text-xl font-bold text-black dark:text-white dark:bg-transparent before:absolute before:top-full before:left-0 before:h-px before:w-full data-[state=active]:before:bg-primary"
@ -53,10 +53,10 @@ const SocialMedia = () => {
</TabsList>
</Tabs>
</div>
<div className="flex flex-col lg:flex-row ">
<div className="flex flex-col lg:flex-row">
{selectedTab == "x" ? (
<div className="flex flex-row justify-between gap-20">
<div className="border border-slate-300 rounded-lg mt-4 w-[350px] h-[450px]">
<div className="flex flex-row justify-between gap-5 w-[90%] mx-auto">
<div className="border border-slate-300 rounded-lg mt-4 w-[350px] h-[500px]">
<div className="mt-2 flex flex-row gap-2 mx-1">
<div className="h-full">
{" "}
@ -79,14 +79,13 @@ const SocialMedia = () => {
<div className="my-3">
<p className="text-sm text-justify">
Lorem ipsum dolor sit, amet consectetur adipisicing elit. Maxime quo fugiat soluta. Possimus est inventore, quidem eligendi fugit repudiandae dicta saepe perspiciatis corrupti quae sapiente accusantium cumque et
dolor ut ullam tempora deserunt dolore consequatur! Lorem ipsum dolor sit amet, consectetur adipisicing elit. Obcaecati sint et sunt quis, eius fuga aliquid, officia possimus quidem adipisci repudiandae voluptate
deserunt dolores dolor minima, earum similique eligendi quaerat.
dolor ut ullam tempora deserunt dolore consequatur! Lorem ipsum dolor sit amet, consectetur adipisicing elit. Obcaecati sint et sunt quis, eius fuga aliquid
</p>
<Image alt="" src="/assets/img/gbr-contoh.png" width={1920} height={1080} className="h-32 w-full mt-3 rounded-md" />{" "}
<Image alt="" src="/assets/img/gbr-contoh.png" width={1920} height={1080} className="h-full w-full mt-3 rounded-md" />{" "}
</div>
</div>
</div>
<div className="border border-slate-300 rounded-lg mt-4 w-[350px]">
<div className="border border-slate-300 rounded-lg mt-4 w-[350px] h-[500px]">
<div className="mt-2 flex flex-row gap-2 mx-1">
<div className="h-full">
{" "}
@ -94,215 +93,220 @@ const SocialMedia = () => {
</div>
<div className="flex flex-col">
<div className="flex flex-row gap-2">
<p className="font-bold">Humas_PoldaKaltara</p>
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 256 256">
<path
fill="#53b0ff"
d="M225.86 102.82c-3.77-3.94-7.67-8-9.14-11.57c-1.36-3.27-1.44-8.69-1.52-13.94c-.15-9.76-.31-20.82-8-28.51s-18.75-7.85-28.51-8c-5.25-.08-10.67-.16-13.94-1.52c-3.56-1.47-7.63-5.37-11.57-9.14C146.28 23.51 138.44 16 128 16s-18.27 7.51-25.18 14.14c-3.94 3.77-8 7.67-11.57 9.14c-3.25 1.36-8.69 1.44-13.94 1.52c-9.76.15-20.82.31-28.51 8s-7.8 18.75-8 28.51c-.08 5.25-.16 10.67-1.52 13.94c-1.47 3.56-5.37 7.63-9.14 11.57C23.51 109.72 16 117.56 16 128s7.51 18.27 14.14 25.18c3.77 3.94 7.67 8 9.14 11.57c1.36 3.27 1.44 8.69 1.52 13.94c.15 9.76.31 20.82 8 28.51s18.75 7.85 28.51 8c5.25.08 10.67.16 13.94 1.52c3.56 1.47 7.63 5.37 11.57 9.14c6.9 6.63 14.74 14.14 25.18 14.14s18.27-7.51 25.18-14.14c3.94-3.77 8-7.67 11.57-9.14c3.27-1.36 8.69-1.44 13.94-1.52c9.76-.15 20.82-.31 28.51-8s7.85-18.75 8-28.51c.08-5.25.16-10.67 1.52-13.94c1.47-3.56 5.37-7.63 9.14-11.57c6.63-6.9 14.14-14.74 14.14-25.18s-7.51-18.27-14.14-25.18m-52.2 6.84l-56 56a8 8 0 0 1-11.32 0l-24-24a8 8 0 0 1 11.32-11.32L112 148.69l50.34-50.35a8 8 0 0 1 11.32 11.32"
/>
</svg>
<p className="font-bold">Humas_PoldaKaltara</p>
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 256 256">
<path
fill="#53b0ff"
d="M225.86 102.82c-3.77-3.94-7.67-8-9.14-11.57c-1.36-3.27-1.44-8.69-1.52-13.94c-.15-9.76-.31-20.82-8-28.51s-18.75-7.85-28.51-8c-5.25-.08-10.67-.16-13.94-1.52c-3.56-1.47-7.63-5.37-11.57-9.14C146.28 23.51 138.44 16 128 16s-18.27 7.51-25.18 14.14c-3.94 3.77-8 7.67-11.57 9.14c-3.25 1.36-8.69 1.44-13.94 1.52c-9.76.15-20.82.31-28.51 8s-7.8 18.75-8 28.51c-.08 5.25-.16 10.67-1.52 13.94c-1.47 3.56-5.37 7.63-9.14 11.57C23.51 109.72 16 117.56 16 128s7.51 18.27 14.14 25.18c3.77 3.94 7.67 8 9.14 11.57c1.36 3.27 1.44 8.69 1.52 13.94c.15 9.76.31 20.82 8 28.51s18.75 7.85 28.51 8c5.25.08 10.67.16 13.94 1.52c3.56 1.47 7.63 5.37 11.57 9.14c6.9 6.63 14.74 14.14 25.18 14.14s18.27-7.51 25.18-14.14c3.94-3.77 8-7.67 11.57-9.14c3.27-1.36 8.69-1.44 13.94-1.52c9.76-.15 20.82-.31 28.51-8s7.85-18.75 8-28.51c.08-5.25.16-10.67 1.52-13.94c1.47-3.56 5.37-7.63 9.14-11.57c6.63-6.9 14.14-14.74 14.14-25.18s-7.51-18.27-14.14-25.18m-52.2 6.84l-56 56a8 8 0 0 1-11.32 0l-24-24a8 8 0 0 1 11.32-11.32L112 148.69l50.34-50.35a8 8 0 0 1 11.32 11.32"
/>
</svg>
</div>
<p className="text-slate-500 text-sm">@HumasKaltara</p>
</div>
<p className="text-slate-500 text-sm">@HumasKaltara</p>
</div>
</div>
<div className="flex flex-col w-full px-3">
<div className="my-3">
<p className="text-sm text-justify">
Lorem ipsum dolor sit, amet consectetur adipisicing elit. Maxime quo fugiat soluta. Possimus est inventore, quidem eligendi fugit repudiandae dicta saepe perspiciatis corrupti quae sapiente accusantium cumque et
dolor ut ullam tempora deserunt dolore consequatur! Lorem ipsum dolor sit amet consectetur, adipisicing elit. Minima repellat corrupti ipsa cumque obcaecati sed ipsum libero, excepturi officia amet, sequi ullam
dolores accusantium vero suscipit aut vel temporibus fugit.
</p>
<Image alt="" src="/assets/tbnews/medsos1.png" width={1920} height={1080} className="h-32 w-full mt-3 rounded-md" />{" "}
</div>
</div>
</div>
<div className="border border-slate-300 rounded-lg mt-4 w-[350px]">
<div className="mt-2 flex flex-row gap-2 mx-1">
<div className="h-full">
{" "}
<Image alt="" src="/assets/img/logo-humas.jpg" width={1920} height={1080} className="h-12 w-12" />
</div>
<div className="flex flex-col">
<div className="flex flex-row gap-2">
<p className="font-bold">Humas_PoldaKaltara</p>
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 256 256">
<path
fill="#53b0ff"
d="M225.86 102.82c-3.77-3.94-7.67-8-9.14-11.57c-1.36-3.27-1.44-8.69-1.52-13.94c-.15-9.76-.31-20.82-8-28.51s-18.75-7.85-28.51-8c-5.25-.08-10.67-.16-13.94-1.52c-3.56-1.47-7.63-5.37-11.57-9.14C146.28 23.51 138.44 16 128 16s-18.27 7.51-25.18 14.14c-3.94 3.77-8 7.67-11.57 9.14c-3.25 1.36-8.69 1.44-13.94 1.52c-9.76.15-20.82.31-28.51 8s-7.8 18.75-8 28.51c-.08 5.25-.16 10.67-1.52 13.94c-1.47 3.56-5.37 7.63-9.14 11.57C23.51 109.72 16 117.56 16 128s7.51 18.27 14.14 25.18c3.77 3.94 7.67 8 9.14 11.57c1.36 3.27 1.44 8.69 1.52 13.94c.15 9.76.31 20.82 8 28.51s18.75 7.85 28.51 8c5.25.08 10.67.16 13.94 1.52c3.56 1.47 7.63 5.37 11.57 9.14c6.9 6.63 14.74 14.14 25.18 14.14s18.27-7.51 25.18-14.14c3.94-3.77 8-7.67 11.57-9.14c3.27-1.36 8.69-1.44 13.94-1.52c9.76-.15 20.82-.31 28.51-8s7.85-18.75 8-28.51c.08-5.25.16-10.67 1.52-13.94c1.47-3.56 5.37-7.63 9.14-11.57c6.63-6.9 14.14-14.74 14.14-25.18s-7.51-18.27-14.14-25.18m-52.2 6.84l-56 56a8 8 0 0 1-11.32 0l-24-24a8 8 0 0 1 11.32-11.32L112 148.69l50.34-50.35a8 8 0 0 1 11.32 11.32"
/>
</svg>
<div className="flex flex-col w-full px-3">
<div className="my-3">
<p className="text-sm text-justify">
Lorem ipsum dolor sit, amet consectetur adipisicing elit. Maxime quo fugiat soluta. Possimus est inventore, quidem eligendi fugit repudiandae dicta saepe perspiciatis corrupti quae sapiente accusantium cumque et
dolor ut ullam tempora deserunt dolore consequatur! Lorem ipsum dolor sit amet consectetur, adipisicing elit. Minima repellat corrupti ipsa cumque obcaecati sed ipsum libero
</p>
<Image alt="" src="/assets/tbnews/medsos1.png" width={1920} height={1080} className="h-full w-full mt-3 rounded-md" />{" "}
</div>
<p className="text-slate-500 text-sm">@HumasKaltara</p>
</div>
</div>
<div className="flex flex-col w-full px-3">
<div className="my-3">
<p className="text-sm text-justify">
Lorem ipsum dolor sit, amet consectetur adipisicing elit. Maxime quo fugiat soluta. Possimus est inventore, quidem eligendi fugit repudiandae dicta saepe perspiciatis corrupti quae sapiente accusantium cumque et
dolor ut ullam tempora deserunt dolore consequatur! Lorem ipsum dolor sit, amet consectetur adipisicing elit. Autem, eveniet sint modi, cupiditate pariatur quod voluptas minus commodi molestiae, natus dolores
asperiores debitis provident error odio eaque id? Iste, enim?
</p>
<Image alt="" src="/assets/tbnews/medsos3.png" width={1920} height={1080} className="h-32 w-full mt-3 rounded-md" />{" "}
</div>
</div>
</div>
<div className="border border-slate-300 rounded-lg mt-4 w-[350px]">
<div className="mt-2 flex flex-row gap-2 mx-1">
<div className="h-full">
{" "}
<Image alt="" src="/assets/img/logo-humas.jpg" width={1920} height={1080} className="h-12 w-12" />
</div>
<div className="flex flex-col">
<div className="flex flex-row gap-2">
<p className="font-bold">Humas_PoldaKaltara</p>
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 256 256">
<path
fill="#53b0ff"
d="M225.86 102.82c-3.77-3.94-7.67-8-9.14-11.57c-1.36-3.27-1.44-8.69-1.52-13.94c-.15-9.76-.31-20.82-8-28.51s-18.75-7.85-28.51-8c-5.25-.08-10.67-.16-13.94-1.52c-3.56-1.47-7.63-5.37-11.57-9.14C146.28 23.51 138.44 16 128 16s-18.27 7.51-25.18 14.14c-3.94 3.77-8 7.67-11.57 9.14c-3.25 1.36-8.69 1.44-13.94 1.52c-9.76.15-20.82.31-28.51 8s-7.8 18.75-8 28.51c-.08 5.25-.16 10.67-1.52 13.94c-1.47 3.56-5.37 7.63-9.14 11.57C23.51 109.72 16 117.56 16 128s7.51 18.27 14.14 25.18c3.77 3.94 7.67 8 9.14 11.57c1.36 3.27 1.44 8.69 1.52 13.94c.15 9.76.31 20.82 8 28.51s18.75 7.85 28.51 8c5.25.08 10.67.16 13.94 1.52c3.56 1.47 7.63 5.37 11.57 9.14c6.9 6.63 14.74 14.14 25.18 14.14s18.27-7.51 25.18-14.14c3.94-3.77 8-7.67 11.57-9.14c3.27-1.36 8.69-1.44 13.94-1.52c9.76-.15 20.82-.31 28.51-8s7.85-18.75 8-28.51c.08-5.25.16-10.67 1.52-13.94c1.47-3.56 5.37-7.63 9.14-11.57c6.63-6.9 14.14-14.74 14.14-25.18s-7.51-18.27-14.14-25.18m-52.2 6.84l-56 56a8 8 0 0 1-11.32 0l-24-24a8 8 0 0 1 11.32-11.32L112 148.69l50.34-50.35a8 8 0 0 1 11.32 11.32"
/>
</svg>
<div className="border border-slate-300 rounded-lg mt-4 w-[350px] h-[500px]">
<div className="mt-2 flex flex-row gap-2 mx-1">
<div className="h-full">
{" "}
<Image alt="" src="/assets/img/logo-humas.jpg" width={1920} height={1080} className="h-12 w-12" />
</div>
<div className="flex flex-col">
<div className="flex flex-row gap-2">
<p className="font-bold">Humas_PoldaKaltara</p>
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 256 256">
<path
fill="#53b0ff"
d="M225.86 102.82c-3.77-3.94-7.67-8-9.14-11.57c-1.36-3.27-1.44-8.69-1.52-13.94c-.15-9.76-.31-20.82-8-28.51s-18.75-7.85-28.51-8c-5.25-.08-10.67-.16-13.94-1.52c-3.56-1.47-7.63-5.37-11.57-9.14C146.28 23.51 138.44 16 128 16s-18.27 7.51-25.18 14.14c-3.94 3.77-8 7.67-11.57 9.14c-3.25 1.36-8.69 1.44-13.94 1.52c-9.76.15-20.82.31-28.51 8s-7.8 18.75-8 28.51c-.08 5.25-.16 10.67-1.52 13.94c-1.47 3.56-5.37 7.63-9.14 11.57C23.51 109.72 16 117.56 16 128s7.51 18.27 14.14 25.18c3.77 3.94 7.67 8 9.14 11.57c1.36 3.27 1.44 8.69 1.52 13.94c.15 9.76.31 20.82 8 28.51s18.75 7.85 28.51 8c5.25.08 10.67.16 13.94 1.52c3.56 1.47 7.63 5.37 11.57 9.14c6.9 6.63 14.74 14.14 25.18 14.14s18.27-7.51 25.18-14.14c3.94-3.77 8-7.67 11.57-9.14c3.27-1.36 8.69-1.44 13.94-1.52c9.76-.15 20.82-.31 28.51-8s7.85-18.75 8-28.51c.08-5.25.16-10.67 1.52-13.94c1.47-3.56 5.37-7.63 9.14-11.57c6.63-6.9 14.14-14.74 14.14-25.18s-7.51-18.27-14.14-25.18m-52.2 6.84l-56 56a8 8 0 0 1-11.32 0l-24-24a8 8 0 0 1 11.32-11.32L112 148.69l50.34-50.35a8 8 0 0 1 11.32 11.32"
/>
</svg>
</div>
<p className="text-slate-500 text-sm">@HumasKaltara</p>
</div>
</div>
<div className="flex flex-col w-full px-3">
<div className="my-3">
<p className="text-sm text-justify">
Lorem ipsum dolor sit, amet consectetur adipisicing elit. Maxime quo fugiat soluta. Possimus est inventore, quidem eligendi fugit repudiandae dicta saepe perspiciatis corrupti quae sapiente accusantium cumque et
dolor ut ullam tempora deserunt dolore consequatur! Lorem ipsum dolor sit, amet consectetur adipisicing elit. Autem, eveniet sint modi, cupiditate pariatur quod voluptas minus
</p>
<Image alt="" src="/assets/tbnews/medsos3.png" width={1920} height={1080} className="h-full w-full mt-3 rounded-md" />{" "}
</div>
<p className="text-slate-500 text-sm">@HumasKaltara</p>
</div>
</div>
<div className="flex flex-col w-full px-3">
<div className="my-3">
<p className="text-sm text-justify">
Lorem ipsum dolor sit, amet consectetur adipisicing elit. Maxime quo fugiat soluta. Possimus est inventore, quidem eligendi fugit repudiandae dicta saepe perspiciatis corrupti quae sapiente accusantium cumque et
dolor ut ullam tempora deserunt dolore consequatur! Lorem ipsum dolor, sit amet consectetur adipisicing elit. Inventore quibusdam doloribus magni nisi consectetur reiciendis cumque eius exercitationem. Adipisci ipsam
dolor accusamus quibusdam.
</p>
<Image alt="" src="/assets/tbnews/medsos2.png" width={1920} height={1080} className="h-32 w-full mt-3 rounded-md" />{" "}
<div className="border border-slate-300 rounded-lg mt-4 w-[350px] h-[500px]">
<div className="mt-2 flex flex-row gap-2 mx-1">
<div className="h-full">
{" "}
<Image alt="" src="/assets/img/logo-humas.jpg" width={1920} height={1080} className="h-12 w-12" />
</div>
<div className="flex flex-col">
<div className="flex flex-row gap-2">
<p className="font-bold">Humas_PoldaKaltara</p>
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 256 256">
<path
fill="#53b0ff"
d="M225.86 102.82c-3.77-3.94-7.67-8-9.14-11.57c-1.36-3.27-1.44-8.69-1.52-13.94c-.15-9.76-.31-20.82-8-28.51s-18.75-7.85-28.51-8c-5.25-.08-10.67-.16-13.94-1.52c-3.56-1.47-7.63-5.37-11.57-9.14C146.28 23.51 138.44 16 128 16s-18.27 7.51-25.18 14.14c-3.94 3.77-8 7.67-11.57 9.14c-3.25 1.36-8.69 1.44-13.94 1.52c-9.76.15-20.82.31-28.51 8s-7.8 18.75-8 28.51c-.08 5.25-.16 10.67-1.52 13.94c-1.47 3.56-5.37 7.63-9.14 11.57C23.51 109.72 16 117.56 16 128s7.51 18.27 14.14 25.18c3.77 3.94 7.67 8 9.14 11.57c1.36 3.27 1.44 8.69 1.52 13.94c.15 9.76.31 20.82 8 28.51s18.75 7.85 28.51 8c5.25.08 10.67.16 13.94 1.52c3.56 1.47 7.63 5.37 11.57 9.14c6.9 6.63 14.74 14.14 25.18 14.14s18.27-7.51 25.18-14.14c3.94-3.77 8-7.67 11.57-9.14c3.27-1.36 8.69-1.44 13.94-1.52c9.76-.15 20.82-.31 28.51-8s7.85-18.75 8-28.51c.08-5.25.16-10.67 1.52-13.94c1.47-3.56 5.37-7.63 9.14-11.57c6.63-6.9 14.14-14.74 14.14-25.18s-7.51-18.27-14.14-25.18m-52.2 6.84l-56 56a8 8 0 0 1-11.32 0l-24-24a8 8 0 0 1 11.32-11.32L112 148.69l50.34-50.35a8 8 0 0 1 11.32 11.32"
/>
</svg>
</div>
<p className="text-slate-500 text-sm">@HumasKaltara</p>
</div>
</div>
<div className="flex flex-col w-full px-3">
<div className="my-3">
<p className="text-sm text-justify">
Lorem ipsum dolor sit, amet consectetur adipisicing elit. Maxime quo fugiat soluta. Possimus est inventore, quidem eligendi fugit repudiandae dicta saepe perspiciatis corrupti quae sapiente accusantium cumque et
dolor ut ullam tempora deserunt dolore consequatur! Lorem ipsum dolor, sit amet consectetur adipisicing elit. Inventore quibusdam doloribus magni nisi
</p>
<Image alt="" src="/assets/tbnews/medsos2.png" width={1920} height={1080} className="h-full w-full mt-3 rounded-md" />{" "}
</div>
</div>
</div>
</div>
</div>
) : selectedTab == "instagram" ? (
<div className="border border-slate-300 rounded-lg mt-4 w-[330px]">
<div className="mt-2 flex flex-row gap-2 mx-1">
<div className="h-full">
{" "}
<Image alt="" src="/assets/img/logo-humas.jpg" width={1920} height={1080} className="h-12 w-12" />
</div>
<div className="flex flex-col">
<div className="flex flex-row gap-2">
<p className="font-bold">TBNews Mabes Polri</p>
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 256 256">
<path
fill="#53b0ff"
d="M225.86 102.82c-3.77-3.94-7.67-8-9.14-11.57c-1.36-3.27-1.44-8.69-1.52-13.94c-.15-9.76-.31-20.82-8-28.51s-18.75-7.85-28.51-8c-5.25-.08-10.67-.16-13.94-1.52c-3.56-1.47-7.63-5.37-11.57-9.14C146.28 23.51 138.44 16 128 16s-18.27 7.51-25.18 14.14c-3.94 3.77-8 7.67-11.57 9.14c-3.25 1.36-8.69 1.44-13.94 1.52c-9.76.15-20.82.31-28.51 8s-7.8 18.75-8 28.51c-.08 5.25-.16 10.67-1.52 13.94c-1.47 3.56-5.37 7.63-9.14 11.57C23.51 109.72 16 117.56 16 128s7.51 18.27 14.14 25.18c3.77 3.94 7.67 8 9.14 11.57c1.36 3.27 1.44 8.69 1.52 13.94c.15 9.76.31 20.82 8 28.51s18.75 7.85 28.51 8c5.25.08 10.67.16 13.94 1.52c3.56 1.47 7.63 5.37 11.57 9.14c6.9 6.63 14.74 14.14 25.18 14.14s18.27-7.51 25.18-14.14c3.94-3.77 8-7.67 11.57-9.14c3.27-1.36 8.69-1.44 13.94-1.52c9.76-.15 20.82-.31 28.51-8s7.85-18.75 8-28.51c.08-5.25.16-10.67 1.52-13.94c1.47-3.56 5.37-7.63 9.14-11.57c6.63-6.9 14.14-14.74 14.14-25.18s-7.51-18.27-14.14-25.18m-52.2 6.84l-56 56a8 8 0 0 1-11.32 0l-24-24a8 8 0 0 1 11.32-11.32L112 148.69l50.34-50.35a8 8 0 0 1 11.32 11.32"
/>
</svg>
) : selectedTab == "instagram" ? (
<div className="flex flex-row justify-between gap-5 w-[90%] mx-auto">
<div className="border border-slate-300 rounded-lg mt-4 w-[330px]">
<div className="mt-2 flex flex-row gap-2 mx-1">
<div className="h-full">
{" "}
<Image alt="" src="/assets/img/logo-humas.jpg" width={1920} height={1080} className="h-12 w-12" />
</div>
<div className="flex flex-col">
<div className="flex flex-row gap-2">
<p className="font-bold">TBNews Mabes Polri</p>
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 256 256">
<path
fill="#53b0ff"
d="M225.86 102.82c-3.77-3.94-7.67-8-9.14-11.57c-1.36-3.27-1.44-8.69-1.52-13.94c-.15-9.76-.31-20.82-8-28.51s-18.75-7.85-28.51-8c-5.25-.08-10.67-.16-13.94-1.52c-3.56-1.47-7.63-5.37-11.57-9.14C146.28 23.51 138.44 16 128 16s-18.27 7.51-25.18 14.14c-3.94 3.77-8 7.67-11.57 9.14c-3.25 1.36-8.69 1.44-13.94 1.52c-9.76.15-20.82.31-28.51 8s-7.8 18.75-8 28.51c-.08 5.25-.16 10.67-1.52 13.94c-1.47 3.56-5.37 7.63-9.14 11.57C23.51 109.72 16 117.56 16 128s7.51 18.27 14.14 25.18c3.77 3.94 7.67 8 9.14 11.57c1.36 3.27 1.44 8.69 1.52 13.94c.15 9.76.31 20.82 8 28.51s18.75 7.85 28.51 8c5.25.08 10.67.16 13.94 1.52c3.56 1.47 7.63 5.37 11.57 9.14c6.9 6.63 14.74 14.14 25.18 14.14s18.27-7.51 25.18-14.14c3.94-3.77 8-7.67 11.57-9.14c3.27-1.36 8.69-1.44 13.94-1.52c9.76-.15 20.82-.31 28.51-8s7.85-18.75 8-28.51c.08-5.25.16-10.67 1.52-13.94c1.47-3.56 5.37-7.63 9.14-11.57c6.63-6.9 14.14-14.74 14.14-25.18s-7.51-18.27-14.14-25.18m-52.2 6.84l-56 56a8 8 0 0 1-11.32 0l-24-24a8 8 0 0 1 11.32-11.32L112 148.69l50.34-50.35a8 8 0 0 1 11.32 11.32"
/>
</svg>
</div>
<p className="text-slate-500 text-sm">@TBNewsMabes</p>
</div>
</div>
<p className="text-slate-500 text-sm">@TBNewsMabes</p>
</div>
</div>
<div className="flex flex-col w-full px-3">
<div className="my-3">
<p className="text-sm text-justify">
Lorem ipsum dolor sit, amet consectetur adipisicing elit. Maxime quo fugiat soluta. Possimus est inventore, quidem eligendi fugit repudiandae dicta saepe perspiciatis corrupti quae sapiente accusantium cumque et dolor
ut ullam tempora deserunt dolore consequatur!
</p>
<Image alt="" src="/assets/img/gbr-contoh.png" width={1920} height={1080} className="h-32 w-full mt-3 rounded-md" />{" "}
</div>
</div>
</div>
) : selectedTab == "facebook" ? (
<div className="border border-slate-300 rounded-lg mt-4 w-[330px]">
<div className="mt-2 flex flex-row gap-2 mx-1">
<div className="h-full">
{" "}
<Image alt="" src="/assets/img/logo-humas.jpg" width={1920} height={1080} className="h-12 w-12" />
</div>
<div className="flex flex-col">
<div className="flex flex-row gap-2">
<p className="font-bold">TBNews Mabes Polri</p>
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 256 256">
<path
fill="#53b0ff"
d="M225.86 102.82c-3.77-3.94-7.67-8-9.14-11.57c-1.36-3.27-1.44-8.69-1.52-13.94c-.15-9.76-.31-20.82-8-28.51s-18.75-7.85-28.51-8c-5.25-.08-10.67-.16-13.94-1.52c-3.56-1.47-7.63-5.37-11.57-9.14C146.28 23.51 138.44 16 128 16s-18.27 7.51-25.18 14.14c-3.94 3.77-8 7.67-11.57 9.14c-3.25 1.36-8.69 1.44-13.94 1.52c-9.76.15-20.82.31-28.51 8s-7.8 18.75-8 28.51c-.08 5.25-.16 10.67-1.52 13.94c-1.47 3.56-5.37 7.63-9.14 11.57C23.51 109.72 16 117.56 16 128s7.51 18.27 14.14 25.18c3.77 3.94 7.67 8 9.14 11.57c1.36 3.27 1.44 8.69 1.52 13.94c.15 9.76.31 20.82 8 28.51s18.75 7.85 28.51 8c5.25.08 10.67.16 13.94 1.52c3.56 1.47 7.63 5.37 11.57 9.14c6.9 6.63 14.74 14.14 25.18 14.14s18.27-7.51 25.18-14.14c3.94-3.77 8-7.67 11.57-9.14c3.27-1.36 8.69-1.44 13.94-1.52c9.76-.15 20.82-.31 28.51-8s7.85-18.75 8-28.51c.08-5.25.16-10.67 1.52-13.94c1.47-3.56 5.37-7.63 9.14-11.57c6.63-6.9 14.14-14.74 14.14-25.18s-7.51-18.27-14.14-25.18m-52.2 6.84l-56 56a8 8 0 0 1-11.32 0l-24-24a8 8 0 0 1 11.32-11.32L112 148.69l50.34-50.35a8 8 0 0 1 11.32 11.32"
/>
</svg>
<div className="flex flex-col w-full px-3">
<div className="my-3">
<p className="text-sm text-justify">
Lorem ipsum dolor sit, amet consectetur adipisicing elit. Maxime quo fugiat soluta. Possimus est inventore, quidem eligendi fugit repudiandae dicta saepe perspiciatis corrupti quae sapiente accusantium cumque et
dolor ut ullam tempora deserunt dolore consequatur!
</p>
<Image alt="" src="/assets/img/gbr-contoh.png" width={1920} height={1080} className="h-32 w-full mt-3 rounded-md" />{" "}
</div>
</div>
<p className="text-slate-500 text-sm">@TBNewsMabes</p>
</div>
</div>
<div className="flex flex-col w-full px-3">
<div className="my-3">
<p className="text-sm text-justify">
Lorem ipsum dolor sit, amet consectetur adipisicing elit. Maxime quo fugiat soluta. Possimus est inventore, quidem eligendi fugit repudiandae dicta saepe perspiciatis corrupti quae sapiente accusantium cumque et dolor
ut ullam tempora deserunt dolore consequatur!
</p>
<Image alt="" src="/assets/img/gbr-contoh.png" width={1920} height={1080} className="h-32 w-full mt-3 rounded-md" />{" "}
</div>
</div>
</div>
) : selectedTab == "tiktok" ? (
<div className="border border-slate-300 rounded-lg mt-4 w-[330px]">
<div className="mt-2 flex flex-row gap-2 mx-1">
<div className="h-full">
{" "}
<Image alt="" src="/assets/img/logo-humas.jpg" width={1920} height={1080} className="h-12 w-12" />
</div>
<div className="flex flex-col">
<div className="flex flex-row gap-2">
<p className="font-bold">TBNews Mabes Polri</p>
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 256 256">
<path
fill="#53b0ff"
d="M225.86 102.82c-3.77-3.94-7.67-8-9.14-11.57c-1.36-3.27-1.44-8.69-1.52-13.94c-.15-9.76-.31-20.82-8-28.51s-18.75-7.85-28.51-8c-5.25-.08-10.67-.16-13.94-1.52c-3.56-1.47-7.63-5.37-11.57-9.14C146.28 23.51 138.44 16 128 16s-18.27 7.51-25.18 14.14c-3.94 3.77-8 7.67-11.57 9.14c-3.25 1.36-8.69 1.44-13.94 1.52c-9.76.15-20.82.31-28.51 8s-7.8 18.75-8 28.51c-.08 5.25-.16 10.67-1.52 13.94c-1.47 3.56-5.37 7.63-9.14 11.57C23.51 109.72 16 117.56 16 128s7.51 18.27 14.14 25.18c3.77 3.94 7.67 8 9.14 11.57c1.36 3.27 1.44 8.69 1.52 13.94c.15 9.76.31 20.82 8 28.51s18.75 7.85 28.51 8c5.25.08 10.67.16 13.94 1.52c3.56 1.47 7.63 5.37 11.57 9.14c6.9 6.63 14.74 14.14 25.18 14.14s18.27-7.51 25.18-14.14c3.94-3.77 8-7.67 11.57-9.14c3.27-1.36 8.69-1.44 13.94-1.52c9.76-.15 20.82-.31 28.51-8s7.85-18.75 8-28.51c.08-5.25.16-10.67 1.52-13.94c1.47-3.56 5.37-7.63 9.14-11.57c6.63-6.9 14.14-14.74 14.14-25.18s-7.51-18.27-14.14-25.18m-52.2 6.84l-56 56a8 8 0 0 1-11.32 0l-24-24a8 8 0 0 1 11.32-11.32L112 148.69l50.34-50.35a8 8 0 0 1 11.32 11.32"
/>
</svg>
) : selectedTab == "facebook" ? (
<div className="flex flex-row justify-between gap-5 w-[90%] mx-auto">
<div className="border border-slate-300 rounded-lg mt-4 w-[330px]">
<div className="mt-2 flex flex-row gap-2 mx-1">
<div className="h-full">
{" "}
<Image alt="" src="/assets/img/logo-humas.jpg" width={1920} height={1080} className="h-12 w-12" />
</div>
<div className="flex flex-col">
<div className="flex flex-row gap-2">
<p className="font-bold">TBNews Mabes Polri</p>
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 256 256">
<path
fill="#53b0ff"
d="M225.86 102.82c-3.77-3.94-7.67-8-9.14-11.57c-1.36-3.27-1.44-8.69-1.52-13.94c-.15-9.76-.31-20.82-8-28.51s-18.75-7.85-28.51-8c-5.25-.08-10.67-.16-13.94-1.52c-3.56-1.47-7.63-5.37-11.57-9.14C146.28 23.51 138.44 16 128 16s-18.27 7.51-25.18 14.14c-3.94 3.77-8 7.67-11.57 9.14c-3.25 1.36-8.69 1.44-13.94 1.52c-9.76.15-20.82.31-28.51 8s-7.8 18.75-8 28.51c-.08 5.25-.16 10.67-1.52 13.94c-1.47 3.56-5.37 7.63-9.14 11.57C23.51 109.72 16 117.56 16 128s7.51 18.27 14.14 25.18c3.77 3.94 7.67 8 9.14 11.57c1.36 3.27 1.44 8.69 1.52 13.94c.15 9.76.31 20.82 8 28.51s18.75 7.85 28.51 8c5.25.08 10.67.16 13.94 1.52c3.56 1.47 7.63 5.37 11.57 9.14c6.9 6.63 14.74 14.14 25.18 14.14s18.27-7.51 25.18-14.14c3.94-3.77 8-7.67 11.57-9.14c3.27-1.36 8.69-1.44 13.94-1.52c9.76-.15 20.82-.31 28.51-8s7.85-18.75 8-28.51c.08-5.25.16-10.67 1.52-13.94c1.47-3.56 5.37-7.63 9.14-11.57c6.63-6.9 14.14-14.74 14.14-25.18s-7.51-18.27-14.14-25.18m-52.2 6.84l-56 56a8 8 0 0 1-11.32 0l-24-24a8 8 0 0 1 11.32-11.32L112 148.69l50.34-50.35a8 8 0 0 1 11.32 11.32"
/>
</svg>
</div>
<p className="text-slate-500 text-sm">@TBNewsMabes</p>
</div>
</div>
<p className="text-slate-500 text-sm">@TBNewsMabes</p>
</div>
</div>
<div className="flex flex-col w-full px-3">
<div className="my-3">
<p className="text-sm text-justify">
Lorem ipsum dolor sit, amet consectetur adipisicing elit. Maxime quo fugiat soluta. Possimus est inventore, quidem eligendi fugit repudiandae dicta saepe perspiciatis corrupti quae sapiente accusantium cumque et dolor
ut ullam tempora deserunt dolore consequatur!
</p>
<Image alt="" src="/assets/img/gbr-contoh.png" width={1920} height={1080} className="h-32 w-full mt-3 rounded-md" />{" "}
</div>
</div>
</div>
) : selectedTab == "youtube" ? (
<div className="border border-slate-300 rounded-lg mt-4 w-[330px]">
<div className="mt-2 flex flex-row gap-2 mx-1">
<div className="h-full">
{" "}
<Image alt="" src="/assets/img/logo-humas.jpg" width={1920} height={1080} className="h-12 w-12" />
</div>
<div className="flex flex-col">
<div className="flex flex-row gap-2">
<p className="font-bold">TBNews Mabes Polri</p>
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 256 256">
<path
fill="#53b0ff"
d="M225.86 102.82c-3.77-3.94-7.67-8-9.14-11.57c-1.36-3.27-1.44-8.69-1.52-13.94c-.15-9.76-.31-20.82-8-28.51s-18.75-7.85-28.51-8c-5.25-.08-10.67-.16-13.94-1.52c-3.56-1.47-7.63-5.37-11.57-9.14C146.28 23.51 138.44 16 128 16s-18.27 7.51-25.18 14.14c-3.94 3.77-8 7.67-11.57 9.14c-3.25 1.36-8.69 1.44-13.94 1.52c-9.76.15-20.82.31-28.51 8s-7.8 18.75-8 28.51c-.08 5.25-.16 10.67-1.52 13.94c-1.47 3.56-5.37 7.63-9.14 11.57C23.51 109.72 16 117.56 16 128s7.51 18.27 14.14 25.18c3.77 3.94 7.67 8 9.14 11.57c1.36 3.27 1.44 8.69 1.52 13.94c.15 9.76.31 20.82 8 28.51s18.75 7.85 28.51 8c5.25.08 10.67.16 13.94 1.52c3.56 1.47 7.63 5.37 11.57 9.14c6.9 6.63 14.74 14.14 25.18 14.14s18.27-7.51 25.18-14.14c3.94-3.77 8-7.67 11.57-9.14c3.27-1.36 8.69-1.44 13.94-1.52c9.76-.15 20.82-.31 28.51-8s7.85-18.75 8-28.51c.08-5.25.16-10.67 1.52-13.94c1.47-3.56 5.37-7.63 9.14-11.57c6.63-6.9 14.14-14.74 14.14-25.18s-7.51-18.27-14.14-25.18m-52.2 6.84l-56 56a8 8 0 0 1-11.32 0l-24-24a8 8 0 0 1 11.32-11.32L112 148.69l50.34-50.35a8 8 0 0 1 11.32 11.32"
/>
</svg>
<div className="flex flex-col w-full px-3">
<div className="my-3">
<p className="text-sm text-justify">
Lorem ipsum dolor sit, amet consectetur adipisicing elit. Maxime quo fugiat soluta. Possimus est inventore, quidem eligendi fugit repudiandae dicta saepe perspiciatis corrupti quae sapiente accusantium cumque et
dolor ut ullam tempora deserunt dolore consequatur!
</p>
<Image alt="" src="/assets/img/gbr-contoh.png" width={1920} height={1080} className="h-32 w-full mt-3 rounded-md" />{" "}
</div>
</div>
<p className="text-slate-500 text-sm">@TBNewsMabes</p>
</div>
</div>
<div className="flex flex-col w-full px-3">
<div className="my-3">
<p className="text-sm text-justify">
Lorem ipsum dolor sit, amet consectetur adipisicing elit. Maxime quo fugiat soluta. Possimus est inventore, quidem eligendi fugit repudiandae dicta saepe perspiciatis corrupti quae sapiente accusantium cumque et dolor
ut ullam tempora deserunt dolore consequatur!
</p>
<Image alt="" src="/assets/img/gbr-contoh.png" width={1920} height={1080} className="h-32 w-full mt-3 rounded-md" />{" "}
) : selectedTab == "tiktok" ? (
<div className="flex flex-row justify-between gap-5 w-[90%] mx-auto">
<div className="border border-slate-300 rounded-lg mt-4 w-[330px]">
<div className="mt-2 flex flex-row gap-2 mx-1">
<div className="h-full">
{" "}
<Image alt="" src="/assets/img/logo-humas.jpg" width={1920} height={1080} className="h-12 w-12" />
</div>
<div className="flex flex-col">
<div className="flex flex-row gap-2">
<p className="font-bold">TBNews Mabes Polri</p>
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 256 256">
<path
fill="#53b0ff"
d="M225.86 102.82c-3.77-3.94-7.67-8-9.14-11.57c-1.36-3.27-1.44-8.69-1.52-13.94c-.15-9.76-.31-20.82-8-28.51s-18.75-7.85-28.51-8c-5.25-.08-10.67-.16-13.94-1.52c-3.56-1.47-7.63-5.37-11.57-9.14C146.28 23.51 138.44 16 128 16s-18.27 7.51-25.18 14.14c-3.94 3.77-8 7.67-11.57 9.14c-3.25 1.36-8.69 1.44-13.94 1.52c-9.76.15-20.82.31-28.51 8s-7.8 18.75-8 28.51c-.08 5.25-.16 10.67-1.52 13.94c-1.47 3.56-5.37 7.63-9.14 11.57C23.51 109.72 16 117.56 16 128s7.51 18.27 14.14 25.18c3.77 3.94 7.67 8 9.14 11.57c1.36 3.27 1.44 8.69 1.52 13.94c.15 9.76.31 20.82 8 28.51s18.75 7.85 28.51 8c5.25.08 10.67.16 13.94 1.52c3.56 1.47 7.63 5.37 11.57 9.14c6.9 6.63 14.74 14.14 25.18 14.14s18.27-7.51 25.18-14.14c3.94-3.77 8-7.67 11.57-9.14c3.27-1.36 8.69-1.44 13.94-1.52c9.76-.15 20.82-.31 28.51-8s7.85-18.75 8-28.51c.08-5.25.16-10.67 1.52-13.94c1.47-3.56 5.37-7.63 9.14-11.57c6.63-6.9 14.14-14.74 14.14-25.18s-7.51-18.27-14.14-25.18m-52.2 6.84l-56 56a8 8 0 0 1-11.32 0l-24-24a8 8 0 0 1 11.32-11.32L112 148.69l50.34-50.35a8 8 0 0 1 11.32 11.32"
/>
</svg>
</div>
<p className="text-slate-500 text-sm">@TBNewsMabes</p>
</div>
</div>
<div className="flex flex-col w-full px-3">
<div className="my-3">
<p className="text-sm text-justify">
Lorem ipsum dolor sit, amet consectetur adipisicing elit. Maxime quo fugiat soluta. Possimus est inventore, quidem eligendi fugit repudiandae dicta saepe perspiciatis corrupti quae sapiente accusantium cumque et
dolor ut ullam tempora deserunt dolore consequatur!
</p>
<Image alt="" src="/assets/img/gbr-contoh.png" width={1920} height={1080} className="h-32 w-full mt-3 rounded-md" />{" "}
</div>
</div>
</div>
</div>
</div>
) : (
<p className="flex items-center justify-center">
<Image width={1920} height={1080} src="/assets/empty-data.png" alt="empty" className="h-52 w-52 my-4" />
</p>
)}
</div>
) : selectedTab == "youtube" ? (
<div className="flex flex-row justify-between gap-5 w-[90%] mx-auto">
<div className="border border-slate-300 rounded-lg mt-4 w-[330px]">
<div className="mt-2 flex flex-row gap-2 mx-1">
<div className="h-full">
{" "}
<Image alt="" src="/assets/img/logo-humas.jpg" width={1920} height={1080} className="h-12 w-12" />
</div>
<div className="flex flex-col">
<div className="flex flex-row gap-2">
<p className="font-bold">TBNews Mabes Polri</p>
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 256 256">
<path
fill="#53b0ff"
d="M225.86 102.82c-3.77-3.94-7.67-8-9.14-11.57c-1.36-3.27-1.44-8.69-1.52-13.94c-.15-9.76-.31-20.82-8-28.51s-18.75-7.85-28.51-8c-5.25-.08-10.67-.16-13.94-1.52c-3.56-1.47-7.63-5.37-11.57-9.14C146.28 23.51 138.44 16 128 16s-18.27 7.51-25.18 14.14c-3.94 3.77-8 7.67-11.57 9.14c-3.25 1.36-8.69 1.44-13.94 1.52c-9.76.15-20.82.31-28.51 8s-7.8 18.75-8 28.51c-.08 5.25-.16 10.67-1.52 13.94c-1.47 3.56-5.37 7.63-9.14 11.57C23.51 109.72 16 117.56 16 128s7.51 18.27 14.14 25.18c3.77 3.94 7.67 8 9.14 11.57c1.36 3.27 1.44 8.69 1.52 13.94c.15 9.76.31 20.82 8 28.51s18.75 7.85 28.51 8c5.25.08 10.67.16 13.94 1.52c3.56 1.47 7.63 5.37 11.57 9.14c6.9 6.63 14.74 14.14 25.18 14.14s18.27-7.51 25.18-14.14c3.94-3.77 8-7.67 11.57-9.14c3.27-1.36 8.69-1.44 13.94-1.52c9.76-.15 20.82-.31 28.51-8s7.85-18.75 8-28.51c.08-5.25.16-10.67 1.52-13.94c1.47-3.56 5.37-7.63 9.14-11.57c6.63-6.9 14.14-14.74 14.14-25.18s-7.51-18.27-14.14-25.18m-52.2 6.84l-56 56a8 8 0 0 1-11.32 0l-24-24a8 8 0 0 1 11.32-11.32L112 148.69l50.34-50.35a8 8 0 0 1 11.32 11.32"
/>
</svg>
</div>
<p className="text-slate-500 text-sm">@TBNewsMabes</p>
</div>
</div>
<div className="flex flex-col w-full px-3">
<div className="my-3">
<p className="text-sm text-justify">
Lorem ipsum dolor sit, amet consectetur adipisicing elit. Maxime quo fugiat soluta. Possimus est inventore, quidem eligendi fugit repudiandae dicta saepe perspiciatis corrupti quae sapiente accusantium cumque et
dolor ut ullam tempora deserunt dolore consequatur!
</p>
<Image alt="" src="/assets/img/gbr-contoh.png" width={1920} height={1080} className="h-32 w-full mt-3 rounded-md" />{" "}
</div>
</div>
</div>
</div>
) : (
<p className="flex items-center justify-center">
<Image width={1920} height={1080} src="/assets/empty-data.png" alt="empty" className="h-52 w-52 my-4" />
</p>
)}
</div>
<div className="flex items-center flex-row justify-center mt-4">
<Link href="#" className="border text-[#bb3523] rounded-lg text-sm lg:text-md px-4 py-1 border-[#bb3523]">
Lihat Semua

View File

@ -30,13 +30,16 @@ export default async function RootLayout({
const direction = getLangDir(locale);
return (
<html lang={locale} dir={direction}>
<head>
<link rel="preconnect" href="https://fonts.googleapis.com" />
<link rel="preconnect" href="https://fonts.gstatic.com" crossOrigin="anonymous" />
<link href="https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,100..1000;1,9..40,100..1000&display=swap" rel="stylesheet" />
</head>
<body className={`${inter.className} dashcode-app`}>
<NextIntlClientProvider messages={messages} locale={locale}>
<AuthProvider>
<ThemeProvider attribute="class" defaultTheme="light">
<DirectionProvider direction={direction}>
{children}
</DirectionProvider>
<DirectionProvider direction={direction}>{children}</DirectionProvider>
<Toaster />
<SonnerToaster />
</ThemeProvider>

View File

@ -0,0 +1,133 @@
import { Link } from "@/i18n/routing";
import { Icon } from "@iconify/react/dist/iconify.js";
import Image from "next/image";
import React from "react";
const ContactUsKaltara = () => {
return (
<div className="bg-[#E7E7E7] h-[150px] lg:h-[300px] text-black px-4 lg:px-20 mb-10 mt-10">
<div className="container mx-auto py-8">
<div className="flex flex-col md:flex-row justify-between items-start gap-4">
{/* Logo */}
<div className="flex flex-col items-center space-x-4">
<Image src="/assets/polda/logo-kontak.png" alt="" width={400} height={300} className="" />
<p className="text-[#bb3523] font-bold">Copyright @TribrataNews Kaltara</p>
</div>
{/* Contact Us */}
<div className="mt-8 md:mt-0 w-full lg:w-[500px]">
<h2 className="text-[#bb3523] text-lg font-bold">Kontak Kami</h2>
<hr className="border-t-2 border-dotted border-[#bb3523] my-2" />
<div className="gap-[20px]">
<p className="flex items-center text-sm gap-2 font-sans">
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
<path fill="#000" d="M12 11.5A2.5 2.5 0 0 1 9.5 9A2.5 2.5 0 0 1 12 6.5A2.5 2.5 0 0 1 14.5 9a2.5 2.5 0 0 1-2.5 2.5M12 2a7 7 0 0 0-7 7c0 5.25 7 13 7 13s7-7.75 7-13a7 7 0 0 0-7-7" />
</svg>
Jalan Komjen Dr. H.M. Jasin No.86, Bumi Rahayu, Kec. Tj. Selor, Kabupaten Bulungan, Kalimantan Utara 77212
</p>
<p className="flex items-center text-sm font-sans mt-2 gap-2">
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24">
<g fill="none">
<path d="m12.593 23.258l-.011.002l-.071.035l-.02.004l-.014-.004l-.071-.035q-.016-.005-.024.005l-.004.01l-.017.428l.005.02l.01.013l.104.074l.015.004l.012-.004l.104-.074l.012-.016l.004-.017l-.017-.427q-.004-.016-.017-.018m.265-.113l-.013.002l-.185.093l-.01.01l-.003.011l.018.43l.005.012l.008.007l.201.093q.019.005.029-.008l.004-.014l-.034-.614q-.005-.018-.02-.022m-.715.002a.02.02 0 0 0-.027.006l-.006.014l-.034.614q.001.018.017.024l.015-.002l.201-.093l.01-.008l.004-.011l.017-.43l-.003-.012l-.01-.01z" />
<path
fill="#000"
d="M6.857 2.445C8 3.278 8.89 4.415 9.65 5.503l.442.644l.417.615a1.504 1.504 0 0 1-.256 1.986l-1.951 1.449a.48.48 0 0 0-.142.616c.442.803 1.228 1.999 2.128 2.899s2.153 1.738 3.012 2.23a.483.483 0 0 0 .644-.162l1.27-1.933a1.503 1.503 0 0 1 2.056-.332l.663.459c1.239.86 2.57 1.837 3.588 3.14a1.47 1.47 0 0 1 .189 1.484c-.837 1.953-2.955 3.616-5.158 3.535l-.3-.017l-.233-.02l-.258-.03l-.281-.038l-.305-.05l-.16-.03l-.336-.072l-.176-.04l-.366-.094l-.385-.11l-.402-.13c-1.846-.626-4.189-1.856-6.593-4.26s-3.633-4.746-4.259-6.592l-.13-.402l-.11-.385l-.094-.366l-.078-.346a12 12 0 0 1-.063-.326l-.05-.305l-.04-.281l-.029-.258l-.02-.233l-.016-.3c-.081-2.196 1.6-4.329 3.544-5.162a1.47 1.47 0 0 1 1.445.159m8.135 3.595l.116.013a3.5 3.5 0 0 1 2.858 2.96a1 1 0 0 1-1.958.393l-.023-.115a1.5 1.5 0 0 0-1.07-1.233l-.155-.035a1 1 0 0 1 .232-1.983M15 3a6 6 0 0 1 6 6a1 1 0 0 1-1.993.117L19 9a4 4 0 0 0-3.738-3.991L15 5a1 1 0 1 1 0-2"
/>
</g>
</svg>
Hotline Divisi HumasPolri (021) 72120599
</p>
<p className="flex items-center text-sm font-sans mt-2 gap-2">
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24">
<g fill="none">
<path d="m12.593 23.258l-.011.002l-.071.035l-.02.004l-.014-.004l-.071-.035q-.016-.005-.024.005l-.004.01l-.017.428l.005.02l.01.013l.104.074l.015.004l.012-.004l.104-.074l.012-.016l.004-.017l-.017-.427q-.004-.016-.017-.018m.265-.113l-.013.002l-.185.093l-.01.01l-.003.011l.018.43l.005.012l.008.007l.201.093q.019.005.029-.008l.004-.014l-.034-.614q-.005-.018-.02-.022m-.715.002a.02.02 0 0 0-.027.006l-.006.014l-.034.614q.001.018.017.024l.015-.002l.201-.093l.01-.008l.004-.011l.017-.43l-.003-.012l-.01-.01z" />
<path
fill="#000"
d="M6.857 2.445C8 3.278 8.89 4.415 9.65 5.503l.442.644l.417.615a1.504 1.504 0 0 1-.256 1.986l-1.951 1.449a.48.48 0 0 0-.142.616c.442.803 1.228 1.999 2.128 2.899s2.153 1.738 3.012 2.23a.483.483 0 0 0 .644-.162l1.27-1.933a1.503 1.503 0 0 1 2.056-.332l.663.459c1.239.86 2.57 1.837 3.588 3.14a1.47 1.47 0 0 1 .189 1.484c-.837 1.953-2.955 3.616-5.158 3.535l-.3-.017l-.233-.02l-.258-.03l-.281-.038l-.305-.05l-.16-.03l-.336-.072l-.176-.04l-.366-.094l-.385-.11l-.402-.13c-1.846-.626-4.189-1.856-6.593-4.26s-3.633-4.746-4.259-6.592l-.13-.402l-.11-.385l-.094-.366l-.078-.346a12 12 0 0 1-.063-.326l-.05-.305l-.04-.281l-.029-.258l-.02-.233l-.016-.3c-.081-2.196 1.6-4.329 3.544-5.162a1.47 1.47 0 0 1 1.445.159m8.135 3.595l.116.013a3.5 3.5 0 0 1 2.858 2.96a1 1 0 0 1-1.958.393l-.023-.115a1.5 1.5 0 0 0-1.07-1.233l-.155-.035a1 1 0 0 1 .232-1.983M15 3a6 6 0 0 1 6 6a1 1 0 0 1-1.993.117L19 9a4 4 0 0 0-3.738-3.991L15 5a1 1 0 1 1 0-2"
/>
</g>
</svg>{" "}
Call Center 110
</p>
<p className="flex items-center text-sm font-sans mt-2 gap-2">
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24">
<path fill="#000" d="M4 20q-.825 0-1.412-.587T2 18V6q0-.825.588-1.412T4 4h16q.825 0 1.413.588T22 6v12q0 .825-.587 1.413T20 20zm8-7l8-5V6l-8 5l-8-5v2z" />
</svg>
ppid@polri.go.id
</p>
</div>
</div>
{/* Links */}
<div className="mt-8 md:mt-0">
<h2 className="text-xl font-bold text-[#bb3523]">Tautan</h2>
<hr className="border-t-2 border-dotted border-[#bb3523] my-2" />
<div className="flex flex-col">
<Link href="https://polri.go.id/" className="flex items-center gap-2 text-sm font-sans">
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 32 32">
<path
fill="#000"
d="M11 16c0-1.393.078-2.734.222-4h9.556c.144 1.266.222 2.607.222 4s-.078 2.734-.222 4h-9.556A36 36 0 0 1 11 16m-1.79 4A38 38 0 0 1 9 16c0-1.379.073-2.72.21-4H2.58A14 14 0 0 0 2 16c0 1.39.203 2.733.58 4zm-5.863 2h6.138c.314 1.86.771 3.547 1.344 4.978c.369.922.793 1.758 1.272 2.472A14.04 14.04 0 0 1 3.347 22m8.168 0h8.97c-.29 1.6-.69 3.032-1.17 4.235c-.516 1.288-1.104 2.262-1.706 2.9c-.6.634-1.144.865-1.609.865s-1.009-.231-1.609-.866c-.602-.637-1.19-1.611-1.705-2.899c-.481-1.203-.881-2.636-1.171-4.235m11 0c-.314 1.86-.771 3.547-1.344 4.978c-.369.922-.793 1.758-1.272 2.472A14.04 14.04 0 0 0 28.653 22zm6.905-2c.377-1.267.58-2.61.58-4s-.203-2.733-.58-4h-6.63c.137 1.28.21 2.621.21 4s-.073 2.72-.21 4zM19.314 5.765c.481 1.203.881 2.636 1.171 4.235h-8.97c.29-1.6.69-3.032 1.17-4.235c.516-1.288 1.104-2.263 1.706-2.9c.598-.631 1.14-.863 1.604-.865h.008c.464 0 1.007.233 1.606.866c.602.636 1.19 1.611 1.705 2.899M22.515 10h6.138a14.04 14.04 0 0 0-8.754-7.45c.479.714.903 1.55 1.272 2.472c.573 1.431 1.03 3.118 1.344 4.978M3.347 10h6.138c.314-1.86.771-3.547 1.344-4.978c.369-.922.793-1.758 1.272-2.472A14.04 14.04 0 0 0 3.347 10"
/>
</svg>
Tentang Kami{" "}
</Link>
<Link href="https://tribratanews.polri.go.id/" className="flex items-center mt-2 text-sm gap-2 font-sans">
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 32 32">
<path
fill="#000"
d="M11 16c0-1.393.078-2.734.222-4h9.556c.144 1.266.222 2.607.222 4s-.078 2.734-.222 4h-9.556A36 36 0 0 1 11 16m-1.79 4A38 38 0 0 1 9 16c0-1.379.073-2.72.21-4H2.58A14 14 0 0 0 2 16c0 1.39.203 2.733.58 4zm-5.863 2h6.138c.314 1.86.771 3.547 1.344 4.978c.369.922.793 1.758 1.272 2.472A14.04 14.04 0 0 1 3.347 22m8.168 0h8.97c-.29 1.6-.69 3.032-1.17 4.235c-.516 1.288-1.104 2.262-1.706 2.9c-.6.634-1.144.865-1.609.865s-1.009-.231-1.609-.866c-.602-.637-1.19-1.611-1.705-2.899c-.481-1.203-.881-2.636-1.171-4.235m11 0c-.314 1.86-.771 3.547-1.344 4.978c-.369.922-.793 1.758-1.272 2.472A14.04 14.04 0 0 0 28.653 22zm6.905-2c.377-1.267.58-2.61.58-4s-.203-2.733-.58-4h-6.63c.137 1.28.21 2.621.21 4s-.073 2.72-.21 4zM19.314 5.765c.481 1.203.881 2.636 1.171 4.235h-8.97c.29-1.6.69-3.032 1.17-4.235c.516-1.288 1.104-2.263 1.706-2.9c.598-.631 1.14-.863 1.604-.865h.008c.464 0 1.007.233 1.606.866c.602.636 1.19 1.611 1.705 2.899M22.515 10h6.138a14.04 14.04 0 0 0-8.754-7.45c.479.714.903 1.55 1.272 2.472c.573 1.431 1.03 3.118 1.344 4.978M3.347 10h6.138c.314-1.86.771-3.547 1.344-4.978c.369-.922.793-1.758 1.272-2.472A14.04 14.04 0 0 0 3.347 10"
/>
</svg>
Redaksi
</Link>
<Link href="https://www.humas.polri.go.id/" className="flex items-center mt-2 text-sm gap-2 font-sans">
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 32 32">
<path
fill="#000"
d="M11 16c0-1.393.078-2.734.222-4h9.556c.144 1.266.222 2.607.222 4s-.078 2.734-.222 4h-9.556A36 36 0 0 1 11 16m-1.79 4A38 38 0 0 1 9 16c0-1.379.073-2.72.21-4H2.58A14 14 0 0 0 2 16c0 1.39.203 2.733.58 4zm-5.863 2h6.138c.314 1.86.771 3.547 1.344 4.978c.369.922.793 1.758 1.272 2.472A14.04 14.04 0 0 1 3.347 22m8.168 0h8.97c-.29 1.6-.69 3.032-1.17 4.235c-.516 1.288-1.104 2.262-1.706 2.9c-.6.634-1.144.865-1.609.865s-1.009-.231-1.609-.866c-.602-.637-1.19-1.611-1.705-2.899c-.481-1.203-.881-2.636-1.171-4.235m11 0c-.314 1.86-.771 3.547-1.344 4.978c-.369.922-.793 1.758-1.272 2.472A14.04 14.04 0 0 0 28.653 22zm6.905-2c.377-1.267.58-2.61.58-4s-.203-2.733-.58-4h-6.63c.137 1.28.21 2.621.21 4s-.073 2.72-.21 4zM19.314 5.765c.481 1.203.881 2.636 1.171 4.235h-8.97c.29-1.6.69-3.032 1.17-4.235c.516-1.288 1.104-2.263 1.706-2.9c.598-.631 1.14-.863 1.604-.865h.008c.464 0 1.007.233 1.606.866c.602.636 1.19 1.611 1.705 2.899M22.515 10h6.138a14.04 14.04 0 0 0-8.754-7.45c.479.714.903 1.55 1.272 2.472c.573 1.431 1.03 3.118 1.344 4.978M3.347 10h6.138c.314-1.86.771-3.547 1.344-4.978c.369-.922.793-1.758 1.272-2.472A14.04 14.04 0 0 0 3.347 10"
/>
</svg>
Pedoman Media Siber
</Link>
<Link href="https://new.netidhub.com/" className="flex items-center mt-2 text-sm gap-2 font-sans">
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 32 32">
<path
fill="#000"
d="M11 16c0-1.393.078-2.734.222-4h9.556c.144 1.266.222 2.607.222 4s-.078 2.734-.222 4h-9.556A36 36 0 0 1 11 16m-1.79 4A38 38 0 0 1 9 16c0-1.379.073-2.72.21-4H2.58A14 14 0 0 0 2 16c0 1.39.203 2.733.58 4zm-5.863 2h6.138c.314 1.86.771 3.547 1.344 4.978c.369.922.793 1.758 1.272 2.472A14.04 14.04 0 0 1 3.347 22m8.168 0h8.97c-.29 1.6-.69 3.032-1.17 4.235c-.516 1.288-1.104 2.262-1.706 2.9c-.6.634-1.144.865-1.609.865s-1.009-.231-1.609-.866c-.602-.637-1.19-1.611-1.705-2.899c-.481-1.203-.881-2.636-1.171-4.235m11 0c-.314 1.86-.771 3.547-1.344 4.978c-.369.922-.793 1.758-1.272 2.472A14.04 14.04 0 0 0 28.653 22zm6.905-2c.377-1.267.58-2.61.58-4s-.203-2.733-.58-4h-6.63c.137 1.28.21 2.621.21 4s-.073 2.72-.21 4zM19.314 5.765c.481 1.203.881 2.636 1.171 4.235h-8.97c.29-1.6.69-3.032 1.17-4.235c.516-1.288 1.104-2.263 1.706-2.9c.598-.631 1.14-.863 1.604-.865h.008c.464 0 1.007.233 1.606.866c.602.636 1.19 1.611 1.705 2.899M22.515 10h6.138a14.04 14.04 0 0 0-8.754-7.45c.479.714.903 1.55 1.272 2.472c.573 1.431 1.03 3.118 1.344 4.978M3.347 10h6.138c.314-1.86.771-3.547 1.344-4.978c.369-.922.793-1.758 1.272-2.472A14.04 14.04 0 0 0 3.347 10"
/>
</svg>
Index
</Link>
</div>
</div>
{/* Social Media */}
{/* <div className="mt-8 md:mt-0">
<h2 className="text-lg font-bold">Sosial Media Humas</h2>
<hr className="border-t-2 border-dotted border-black my-2" />
<div className="flex gap-4">
<a href="#">
<Icon icon="fa6-brands:square-x-twitter" className="w-6 h-6" />
</a>
<a href="#">
<Icon icon="skill-icons:instagram" className="w-6 h-6" />
</a>
<a href="#">
<Icon icon="devicon:facebook" className="w-6 h-6" />
</a>
<a href="#">
<Icon icon="hugeicons:tiktok" className="w-6 h-6" />
</a>
<a href="#">
<Icon icon="fa-brands:youtube-square" className="w-6 h-6" />
</a>
</div>
</div> */}
</div>
</div>
</div>
);
};
export default ContactUsKaltara;

View File

@ -0,0 +1,116 @@
import { getCategoryData, getPublicCategoryData } from "@/service/landing/landing";
import Link from "next/link";
import React, { useEffect, useState } from "react";
import { useTranslations } from "next-intl";
import { usePathname } from "next/navigation";
import { useParams } from "next/navigation";
import Image from "next/image";
import { Reveal } from "../Reveal";
import { Button } from "@/components/ui/button";
const ContentCategory = (props: { group?: string }) => {
const [categories, setCategories] = useState<any>();
const t = useTranslations("LandingPage");
const params = useParams();
const locale = params?.locale;
const poldaName = params?.polda_name;
const satkerName = params?.satker_name;
const [searchTerm, setSearchTerm] = useState("");
const [seeAllValue, setSeeAllValue] = useState(false);
const pathname = usePathname();
useEffect(() => {
initFetch();
}, []);
const initFetch = async () => {
const response = await getPublicCategoryData(
props.group == "mabes" ? "" : props.group == "polda" && poldaName && String(poldaName)?.length > 1 ? poldaName : props.group == "satker" && satkerName && String(satkerName)?.length > 1 ? "satker-" + satkerName : "",
"",
locale == "en" ? true : false
);
console.log("category", response);
setCategories(response?.data?.data?.content);
};
const shimmer = (w: number, h: number) => `
<svg width="${w}" height="${h}" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<defs>
<linearGradient id="g">
<stop stop-color="#bcbcbd" offset="20%" />
<stop stop-color="#f9fafb" offset="50%" />
<stop stop-color="#bcbcbd" offset="70%" />
</linearGradient>
</defs>
<rect width="${w}" height="${h}" fill="#bcbcbd" />
<rect id="r" width="${w}" height="${h}" fill="url(#g)" />
<animate xlink:href="#r" attributeName="x" from="-${w}" to="${w}" dur="1s" repeatCount="indefinite" />
</svg>`;
const toBase64 = (str: string) => (typeof window === "undefined" ? Buffer.from(str).toString("base64") : window.btoa(str));
return (
<div className="mx-auto px-4 lg:px-24 py-10 max-w-screen-2xl ">
<Reveal>
<h2 className="text-center text-xl lg:text-2xl font-bold text-[#bb3523] mb-4">
{pathname?.split("/")[1] == "in" ? (
<>
<span className="text-black dark:text-white">{t("category")}&nbsp;</span>
{t("content")}
</>
) : (
<>
<span className="text-black dark:text-white">{t("content")}&nbsp;</span>
{t("category")}
</>
)}
</h2>
<div className="h-1 w-48 bg-[#bb3523] mx-auto mb-6 rounded"></div>
<div className="grid my-3 grid-cols-2 lg:grid-cols-4 gap-4">
{categories?.map((category: any, index: number) =>
!seeAllValue ? (
index < 4 ? (
<Link key={category?.id} href={`all/filter?category=${category?.id}`} className="relative group rounded-md overflow-hidden shadow-md hover:shadow-lg">
<Image
placeholder={`data:image/svg+xml;base64,${toBase64(shimmer(700, 475))}`}
alt="category"
width={2560}
height={1440}
src={category?.thumbnailLink}
className="w-full h-48 sm:h-40 object-cover group-hover:scale-110 transition-transform duration-300"
/>
<div className="absolute bottom-0 rounded-lg left-0 right-0 bg-gray-400 border-l-4 mb-4 border-[#bb3523] text-white p-2">
<h3 className="text-sm font-semibold truncate">{category?.name}</h3>
</div>
</Link>
) : (
""
)
) : (
<Link key={category?.id} href={`all/filter?category=${category?.id}`} className="relative group rounded-md overflow-hidden shadow-md hover:shadow-lg">
<Image
placeholder={`data:image/svg+xml;base64,${toBase64(shimmer(700, 475))}`}
alt="category"
width={2560}
height={1440}
src={category?.thumbnailLink}
className="w-full h-48 sm:h-40 object-cover group-hover:scale-110 transition-transform duration-300"
/>
<div className="absolute bottom-0 left-0 right-0 bg-gray-400 border-l-4 mb-4 border-[#bb3523] rounded-lg text-white p-2">
<h3 className="text-sm font-semibold truncate">{category?.name}</h3>
</div>
</Link>
)
)}
</div>
<div className="flex items-center flex-row justify-center">
<Button onClick={() => setSeeAllValue(!seeAllValue)} className="bg-white hover:bg-[#bb3523] text-[#bb3523] hover:text-white border-2 border-[#bb3523]">
{seeAllValue ? t("seeLess") : t("seeMore")}
</Button>
</div>
</Reveal>
</div>
);
};
export default ContentCategory;

View File

@ -0,0 +1,187 @@
"use client";
import { listData } from "@/service/landing/landing";
import { useParams } from "next/navigation";
import React, { useEffect, useState } from "react";
import Skeleton, { SkeletonTheme } from "react-loading-skeleton";
import { formatDateToIndonesian, getPublicLocaleTimestamp, textEllipsis } from "@/utils/globals";
import { Icon } from "@iconify/react/dist/iconify.js";
import { Carousel, CarouselContent, CarouselItem, CarouselNext, CarouselPrevious } from "@/components/ui/carousel";
import Image from "next/image";
import { useRouter } from "@/i18n/routing";
import { Reveal } from "../Reveal";
const HeaderBannerKaltara = () => {
const router = useRouter();
const params = useParams();
const poldaName: any = params?.polda_name;
const [content, setContent] = useState([]);
const [isBannerLoading, setIsBannerLoading] = useState(true);
const [centerPadding, setCenterPadding] = useState<any>();
const satkerName = params?.satker_name;
let prefixPath = poldaName ? `/polda/${poldaName}` : satkerName ? `/satker/${satkerName}` : "/";
useEffect(() => {
// async function initState() {
// const res = await listCarousel();
// setContent(res?.data?.data);
// setCenterPadding(`${Math.trunc(Number(window.innerWidth) / 10 + 40)}px`);
// }
async function fetchData() {
const res = await listData("1", "", "", 5, 0, "createdAt", "", "", poldaName);
let data = res?.data?.data?.content;
setContent(data);
setCenterPadding(`${Math.trunc(Number(window.innerWidth) / 10 + 40)}px`);
setIsBannerLoading(false);
console.log("Done");
}
fetchData();
}, [params?.page]);
const settings = {
className: "center",
// centerMode: true,
infinite: true,
centerPadding,
slidesToShow: 2,
autoplay: true,
speed: 1500,
autoplaySpeed: 15_000,
focusOnSelect: true,
responsive: [
{
breakpoint: 768,
settings: {
arrows: false,
centerMode: true,
centerPadding: "60px",
slidesToShow: 1,
},
},
{
breakpoint: 480,
settings: {
arrows: false,
centerMode: true,
centerPadding: "20px",
slidesToShow: 1,
},
},
],
};
return (
<>
<Reveal>
{/* Header Left */}
<div className="flex flex-col lg:flex-row items-start justify-center gap-[25px] px-4 lg:px-0 py-4 w-auto mt-6">
{isBannerLoading ? (
<div className="flex flex-col space-y-3 mx-auto w-full lg:w-2/3">
<Skeleton className="h-[310px] lg:h-[420px] rounded-xl" />
<div className="space-y-2">
<Skeleton className="h-4 w-[250px]" />
<Skeleton className="h-4 w-[200px]" />
</div>
</div>
) : (
<Carousel className="lg:w-2/3 lg:h-full ">
<CarouselContent>
{content?.map((row: any) => (
<CarouselItem key={row?.id}>
<div className="relative h-[310px] lg:h-[580px]">
<Image src={row?.thumbnailLink} alt="" width={1920} height={1080} className="w-full h-[540px] lg:h-full rounded-lg object-cover" />
<div className="absolute bottom-5 left-5 right-5 bg-black bg-opacity-50 text-white p-4 rounded-r-lg border-l-2 border-[#bb3523]">
<span className="text-[#bb3523] font-sans bg-[#b0b0af] border border-[#bb3523] rounded-md w-full h-full font-semibold uppercase text-[14px] px-[10px] py-[5px]">{row?.categoryName}</span>
<div onClick={() => router.push(prefixPath + `/image/detail/${row?.slug}`)} className="cursor-pointer">
<h3 className="text-[42px] font-sans text-white">{row.title}</h3>
</div>
<p className="text-[12px] font-sans flex flex-row items-center gap-1 mt-1 text-white">
{getPublicLocaleTimestamp(new Date(row?.createdAt))} WIB {" | "}
<Icon icon="formkit:eye" width="15" height="15" /> {row?.clickCount}
</p>
</div>
</div>
</CarouselItem>
))}
</CarouselContent>
<CarouselPrevious />
<CarouselNext />
</Carousel>
)}
{/* Header Right */}
<div>
{isBannerLoading ? (
<>
<div className="flex items-center gap-4 max-w-sm mx-auto mb-3">
<Skeleton className="h-[73px] w-16 rounded-md" />
<div className="space-y-2">
<Skeleton className="h-4 w-[250px]" />
<Skeleton className="h-4 w-[200px]" />
</div>
</div>
<div className="items-center hidden md:block gap-4 max-w-sm mx-auto mb-3 lg:flex">
<Skeleton className="h-[73px] w-16 rounded-md" />
<div className="space-y-2">
<Skeleton className="h-4 w-[250px]" />
<Skeleton className="h-4 w-[200px]" />
</div>
</div>
<div className="hidden md:block items-center gap-4 max-w-sm mx-auto mb-3 lg:flex">
<Skeleton className="h-[73px] w-16 rounded-md" />
<div className="space-y-2">
<Skeleton className="h-4 w-[250px]" />
<Skeleton className="h-4 w-[200px]" />
</div>
</div>
<div className="hidden md:block items-center gap-4 max-w-sm mx-auto mb-3 lg:flex">
<Skeleton className="h-[73px] w-16 rounded-md" />
<div className="space-y-2">
<Skeleton className="h-4 w-[250px]" />
<Skeleton className="h-4 w-[200px]" />
</div>
</div>
<div className="hidden md:block items-center gap-4 max-w-sm mx-auto lg:flex">
<Skeleton className="h-[73px] w-16 rounded-md" />
<div className="space-y-2">
<Skeleton className="h-4 w-[250px]" />
<Skeleton className="h-4 w-[200px]" />
</div>
</div>
</>
) : (
<ul className="py-4 lg:py-0 flex flex-row lg:flex-col gap-[20px] flex-nowrap w-[95vw] lg:w-auto overflow-x-auto">
{content?.map((item: any) => (
<li key={item?.id} className="flex gap-4 flex-row lg:w-full bg-[#f8f8f8] p-[10px] rounded-lg">
<div className="flex-shrink-0 w-24 rounded-lg">
<Image width={720} height={480} src={item?.thumbnailLink} alt={item?.title} className="w-full h-[80px] object-cover rounded-lg" />
</div>
<div className="w-[280px] lg:w-auto">
<span className="text-[#bb3523] border border-[#bb3523] bg-white px-4 py-1 rounded-lg flex text-[8px] font-sans font-semibold uppercase w-fit">{item?.categoryName}</span>
<div onClick={() => router.push(prefixPath + `/image/detail/${item?.slug}`)} className="cursor-pointer">
<h3 className="text-base font-sans font-bold mt-2">{textEllipsis(item?.title, 30)}</h3>
</div>
<p className="text-[10px] flex flex-row items-center font-sans gap-1 text-gray-500 mt-1">
{formatDateToIndonesian(new Date(item?.createdAt))} {item?.timezone ? item?.timezone : "WIB"} |{" "}
<svg xmlns="http://www.w3.org/2000/svg" width="1.2em" height="1.2em" viewBox="0 0 24 24">
<path
fill="currentColor"
d="M11.5 18c4 0 7.46-2.22 9.24-5.5C18.96 9.22 15.5 7 11.5 7s-7.46 2.22-9.24 5.5C4.04 15.78 7.5 18 11.5 18m0-12c4.56 0 8.5 2.65 10.36 6.5C20 16.35 16.06 19 11.5 19S3 16.35 1.14 12.5C3 8.65 6.94 6 11.5 6m0 2C14 8 16 10 16 12.5S14 17 11.5 17S7 15 7 12.5S9 8 11.5 8m0 1A3.5 3.5 0 0 0 8 12.5a3.5 3.5 0 0 0 3.5 3.5a3.5 3.5 0 0 0 3.5-3.5A3.5 3.5 0 0 0 11.5 9"
/>
</svg>{" "}
{item?.clickCount}
</p>
</div>
</li>
))}
</ul>
)}
</div>
</div>
</Reveal>
</>
);
};
export default HeaderBannerKaltara;

View File

@ -0,0 +1,311 @@
"use client";
import React, { useEffect, useState } from "react";
import { Tabs, TabsList, TabsTrigger } from "@/components/ui/tabs";
import { Carousel, CarouselContent, CarouselItem, CarouselNext, CarouselPrevious } from "@/components/ui/carousel";
import Image from "next/image";
import { Skeleton } from "@/components/ui/skeleton";
import { formatDateToIndonesian, secondToTimes } from "@/utils/globals";
import { useParams } from "next/navigation";
import { listData } from "@/service/landing/landing";
import { useRouter } from "@/i18n/routing";
import { Icon } from "@iconify/react/dist/iconify.js";
import { useTranslations } from "next-intl";
import { Reveal } from "../Reveal";
const LatestContentKaltara = (props: { group: string; type: string }) => {
const [selectedTab, setSelectedTab] = useState("video");
const [isLoading, setIsLoading] = useState<any>(true);
const params = useParams();
const poldaName: any = params?.polda_name;
const satkerName = params?.satker_name;
const [content, setContent] = useState([]);
const [isBannerLoading, setIsBannerLoading] = useState(true);
const [centerPadding, setCenterPadding] = useState<any>();
const router = useRouter();
const t = useTranslations("LandingPage");
let prefixPath = poldaName ? `/polda/${poldaName}` : satkerName ? `/satker/${satkerName}` : "/";
useEffect(() => {
// async function initState() {
// const res = await listCarousel();
// setContent(res?.data?.data);
// setCenterPadding(`${Math.trunc(Number(window.innerWidth) / 10 + 40)}px`);
// }
async function fetchData() {
const res = await listData("1", "", "", 5, 0, "createdAt", "", "", poldaName);
let data = res?.data?.data?.content;
setContent(data);
setCenterPadding(`${Math.trunc(Number(window.innerWidth) / 10 + 40)}px`);
setIsBannerLoading(false);
console.log("Done");
}
fetchData();
}, [params?.page]);
useEffect(() => {
const timer = setTimeout(() => {
setIsLoading(false);
}, 3000);
return () => clearTimeout(timer);
}, []);
const shimmer = (w: number, h: number) => `
<svg width="${w}" height="${h}" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<defs>
<linearGradient id="g">
<stop stop-color="#bcbcbd" offset="20%" />
<stop stop-color="#f9fafb" offset="50%" />
<stop stop-color="#bcbcbd" offset="70%" />
</linearGradient>
</defs>
<rect width="${w}" height="${h}" fill="#bcbcbd" />
<rect id="r" width="${w}" height="${h}" fill="url(#g)" />
<animate xlink:href="#r" attributeName="x" from="-${w}" to="${w}" dur="1s" repeatCount="indefinite" />
</svg>`;
const toBase64 = (str: string) => (typeof window === "undefined" ? Buffer.from(str).toString("base64") : window.btoa(str));
return (
<>
<Reveal>
<div className="px-4 lg:px-20 my-10">
<div className="bg-[#c03724] rounded-md p-3 w-fit text-white">Berita {props.type == "popular" ? "Terpopuler" : props.type == "latest" ? t("new") : "Serupa"}</div>
<div className="mx-auto w-full max-w-7xl justify-center flex px-5 flex-col lg:flex-row gap-5 mb-4">
<Tabs value={selectedTab} onValueChange={setSelectedTab}>
<TabsList className="grid grid-cols-2 lg:flex lg:flex-row">
<TabsTrigger
value="video"
className="relative text-[10px] font-sans md:text-[16px] font-bold text-black dark:text-white dark:bg-transparent
before:absolute before:top-full before:left-0 before:h-px before:w-full data-[state=active]:before:bg-primary
data-[state=active]:text-[#bb3523]"
>
Audio Visual
</TabsTrigger>
<div className="text-[#bb3523] text-lg hidden md:inline-block">|</div>
<TabsTrigger
value="audio"
className="relative text-[10px] font-sans md:text-[16px] font-bold text-black dark:text-white dark:bg-transparent
before:absolute before:top-full before:left-0 before:h-px before:w-full data-[state=active]:before:bg-primary
data-[state=active]:text-[#bb3523]"
>
Audio
</TabsTrigger>
<div className="text-[#bb3523] text-lg hidden md:inline-block">|</div>
<TabsTrigger
value="image"
className="relative text-[10px] font-sans md:text-[16px] font-bold text-black dark:text-white dark:bg-transparent
before:absolute before:top-full before:left-0 before:h-px before:w-full data-[state=active]:before:bg-primary
data-[state=active]:text-[#bb3523]"
>
Foto
</TabsTrigger>
<div className="text-[#bb3523] text-lg hidden md:inline-block">|</div>
<TabsTrigger
value="text"
className="relative text-[10px] font-sans md:text-[16px] font-bold text-black dark:text-white dark:bg-transparent
before:absolute before:top-full before:left-0 before:h-px before:w-full data-[state=active]:before:bg-primary
data-[state=active]:text-[#bb3523]"
>
Teks
</TabsTrigger>
</TabsList>
</Tabs>
</div>
{isLoading ? (
<div className="flex flex-row space-y-3 w-full justify-center items-center gap-10">
<Skeleton className="h-[200px] w-[400px] rounded-xl" />
<Skeleton className="h-[200px] w-[400px] rounded-xl hidden md:block" />
<Skeleton className="h-[200px] w-[400px] rounded-xl hidden md:block" />
</div>
) : (
<div className="">
{selectedTab == "image" ? (
content?.length > 0 ? (
<Carousel className="w-[90%] mx-auto">
<CarouselContent>
{content?.map((video: any) => (
<CarouselItem key={video?.id} className="basis-1/2 md:basis-1/3 lg:basis-1/4">
<div onClick={() => router.push(prefixPath + `/video/detail/${video?.slug}`)} className="cursor-pointer relative group rounded-md overflow-hidden">
{/* Gambar */}
<Image
placeholder={`data:image/svg+xml;base64,${toBase64(shimmer(700, 475))}`}
alt="video"
width={2560}
height={1440}
src={video?.thumbnailLink}
className="w-full lg:w-[390px] h-48 md:h-56 lg:h-[490px] object-cover rounded-md"
/>
{/* Kategori - Sekarang Berada di Atas */}
<span className="absolute top-2 left-2 z-10 text-xs md:text-sm font-sans font-semibold uppercase px-2 py-1 bg-white bg-opacity-20 border border-[#c03724] text-[#c03724] rounded-md">{video?.categoryName}</span>
{/* Overlay Konten (Informasi di Bawah) */}
<div className="absolute bottom-0 left-0 right-0 p-4 bg-transparent rounded-md">
{/* Judul */}
<p className="text-white text-sm md:text-[20px] font-sans font-semibold mb-2">{video?.title}</p>
{/* Info Tambahan */}
{/* <p className="flex items-center text-xs md:text-sm text-white mt-1 gap-2">
{formatDateToIndonesian(new Date(video?.createdAt))} {video?.timezone ? video?.timezone : "WIB"} | <Icon icon="formkit:eye" width="15" height="15" /> {video?.clickCount}
</p> */}
</div>
</div>
</CarouselItem>
))}
</CarouselContent>
<CarouselPrevious className="hover:bg-black" />
<CarouselNext className="hover:bg-black -mr-6" />
</Carousel>
) : (
<p className="flex items-center justify-center">
<Image width={1920} height={1080} src="/assets/empty-data.png" alt="empty" className="h-52 w-52 my-4" />
</p>
)
) : selectedTab == "audio" ? (
content?.length > 0 ? (
<Carousel className="w-full max-w-7xl mx-auto">
<CarouselContent>
{content?.map((audio: any) => (
<CarouselItem key={audio?.id} className="md:basis-1/2 lg:basis-1/3">
<div className="flex flex-row gap-6">
<div onClick={() => router.push(prefixPath + `/audio/detail/${audio?.slug}`)} className="cursor-pointer flex flex-col sm:flex-row items-center bg-white dark:bg-gray-800 shadow-md rounded-lg p-4 gap-4 w-full">
<div className="flex items-center justify-center bg-red-500 text-white rounded-lg w-24 h-8 lg:h-16">
<svg width="32" height="34" viewBox="0 0 32 34" fill="null" xmlns="http://www.w3.org/2000/svg">
<path
d="M23.404 0.452014C23.7033 0.35857 24.0204 0.336816 24.3297 0.388509C24.639 0.440203 24.9318 0.563895 25.1845 0.749599C25.4371 0.935304 25.6426 1.17782 25.7843 1.45756C25.9259 1.73731 25.9998 2.04644 26 2.36001V14.414C25.3462 14.2296 24.6766 14.1064 24 14.046V8.36001L10 12.736V27C10 28.1264 9.6197 29.2197 8.92071 30.1029C8.22172 30.9861 7.24499 31.6075 6.14877 31.8663C5.05255 32.125 3.90107 32.0061 2.88089 31.5287C1.86071 31.0514 1.03159 30.2435 0.52787 29.2361C0.024152 28.2286 -0.124656 27.0806 0.105556 25.9781C0.335768 24.8755 0.931513 23.883 1.79627 23.1613C2.66102 22.4396 3.74413 22.031 4.87009 22.0017C5.99606 21.9724 7.09893 22.3242 8.00001 23V6.73601C7.99982 6.30956 8.13596 5.8942 8.38854 5.55059C8.64112 5.20698 8.99692 4.9531 9.40401 4.82601L23.404 0.452014ZM10 10.64L24 6.26601V2.36001L10 6.73601V10.64ZM5.00001 24C4.20436 24 3.44129 24.3161 2.87869 24.8787C2.31608 25.4413 2.00001 26.2044 2.00001 27C2.00001 27.7957 2.31608 28.5587 2.87869 29.1213C3.44129 29.6839 4.20436 30 5.00001 30C5.79566 30 6.55872 29.6839 7.12133 29.1213C7.68394 28.5587 8.00001 27.7957 8.00001 27C8.00001 26.2044 7.68394 25.4413 7.12133 24.8787C6.55872 24.3161 5.79566 24 5.00001 24ZM32 25C32 27.387 31.0518 29.6761 29.364 31.364C27.6761 33.0518 25.387 34 23 34C20.6131 34 18.3239 33.0518 16.636 31.364C14.9482 29.6761 14 27.387 14 25C14 22.6131 14.9482 20.3239 16.636 18.6361C18.3239 16.9482 20.6131 16 23 16C25.387 16 27.6761 16.9482 29.364 18.6361C31.0518 20.3239 32 22.6131 32 25ZM27.47 24.128L21.482 20.828C21.3298 20.7443 21.1583 20.7016 20.9846 20.7043C20.8108 20.707 20.6408 20.7549 20.4912 20.8433C20.3416 20.9317 20.2176 21.0576 20.1315 21.2086C20.0453 21.3595 20 21.5302 20 21.704V28.304C20 28.4778 20.0453 28.6486 20.1315 28.7995C20.2176 28.9504 20.3416 29.0763 20.4912 29.1647C20.6408 29.2531 20.8108 29.301 20.9846 29.3037C21.1583 29.3064 21.3298 29.2638 21.482 29.18L27.47 25.88C27.6268 25.7937 27.7575 25.6669 27.8486 25.5128C27.9397 25.3587 27.9877 25.183 27.9877 25.004C27.9877 24.825 27.9397 24.6493 27.8486 24.4952C27.7575 24.3412 27.6268 24.2143 27.47 24.128Z"
fill="white"
/>
</svg>
</div>
<div className="flex flex-col flex-1">
<div className="text-gray-500 dark:text-gray-400 flex flex-row text-sm text-center items-center">
{formatDateToIndonesian(new Date(audio?.createdAt))} {audio?.timezone ? audio?.timezone : "WIB"} |&nbsp; <Icon icon="formkit:eye" width="15" height="15" />
&nbsp; {audio?.clickCount}{" "}
</div>
<div className="font-semibold text-gray-900 dark:text-white mt-1 text-sm h-5 hover:h-auto truncate hover:whitespace-normal hover:overflow-visible">{audio?.title}</div>
<p className="text-sm"> {audio?.duration ? secondToTimes(Number(audio?.duration)) : "00:00:00"}</p>
</div>
</div>
</div>
</CarouselItem>
))}
</CarouselContent>
<CarouselPrevious />
<CarouselNext />
</Carousel>
) : (
<p className="flex items-center justify-center">
<Image width={1920} height={1080} src="/assets/empty-data.png" alt="empty" className="h-52 w-52 my-4" />
</p>
)
) : selectedTab == "video" ? (
content?.length > 0 ? (
<Carousel className="w-[90%] mx-auto">
<CarouselContent>
{content?.map((video: any) => (
<CarouselItem key={video?.id} className="basis-1/2 md:basis-1/3 lg:basis-1/4">
<div onClick={() => router.push(prefixPath + `/video/detail/${video?.slug}`)} className="cursor-pointer relative group rounded-lg overflow-hidden">
{/* Gambar */}
<Image
placeholder={`data:image/svg+xml;base64,${toBase64(shimmer(700, 475))}`}
alt="video"
width={2560}
height={1440}
src={video?.thumbnailLink}
className="w-full lg:w-[315px] h-48 md:h-56 lg:h-[490px] object-cover rounded-lg transition-transform duration-300"
/>
{/* Kategori - Sekarang Berada di Atas */}
<span className="absolute top-2 left-2 z-10 text-xs md:text-sm font-sans font-semibold uppercase px-2 py-1 bg-white bg-opacity-20 border border-[#c03724] text-[#c03724] rounded-md">{video?.categoryName}</span>
{/* Overlay Konten (Informasi di Bawah) */}
<div className="absolute bottom-0 left-0 right-0 p-4 bg-transparent rounded-lg">
{/* Judul */}
<p className="text-white text-sm md:text-[20px] font-sans font-semibold mb-2">{video?.title}</p>
{/* Info Tambahan */}
{/* <p className="flex items-center text-xs md:text-sm text-white mt-1 gap-2">
{formatDateToIndonesian(new Date(video?.createdAt))} {video?.timezone ? video?.timezone : "WIB"} | <Icon icon="formkit:eye" width="15" height="15" /> {video?.clickCount}
</p> */}
</div>
</div>
</CarouselItem>
))}
</CarouselContent>
<CarouselPrevious className="hover:bg-black" />
<CarouselNext className="hover:bg-black -mr-6" />
</Carousel>
) : (
<p className="flex items-center justify-center">
<Image width={1920} height={1080} src="/assets/empty-data.png" alt="empty" className="h-52 w-52 my-4" />
</p>
)
) : content.length > 0 ? (
<Carousel className="w-full max-w-7xl mx-auto">
<CarouselContent>
{content?.map((text: any) => (
<CarouselItem key={text?.id} className="md:basis-1/2 lg:basis-1/3">
<div className="md:basis-1/2 lg:basis-1/3">
<div onClick={() => router.push(prefixPath + `/document/detail/${text?.slug}`)} className="flex flex-col bg-yellow-500 sm:flex-row items-center dark:bg-gray-800 cursor-pointer shadow-md rounded-lg p-4 gap-4">
<div className="flex items-center justify-center rounded-lg w-16 h-2 lg:h-16">
<svg width="28" height="34" viewBox="0 0 28 34" fill="none" xmlns="http://www.w3.org/2000/svg">
<path
d="M5.6665 17.4167C5.6665 17.0851 5.7982 16.7672 6.03262 16.5328C6.26704 16.2984 6.58498 16.1667 6.9165 16.1667C7.24802 16.1667 7.56597 16.2984 7.80039 16.5328C8.03481 16.7672 8.1665 17.0851 8.1665 17.4167C8.1665 17.7482 8.03481 18.0661 7.80039 18.3005C7.56597 18.535 7.24802 18.6667 6.9165 18.6667C6.58498 18.6667 6.26704 18.535 6.03262 18.3005C5.7982 18.0661 5.6665 17.7482 5.6665 17.4167ZM6.9165 21.1667C6.58498 21.1667 6.26704 21.2984 6.03262 21.5328C5.7982 21.7672 5.6665 22.0851 5.6665 22.4167C5.6665 22.7482 5.7982 23.0661 6.03262 23.3005C6.26704 23.535 6.58498 23.6667 6.9165 23.6667C7.24802 23.6667 7.56597 23.535 7.80039 23.3005C8.03481 23.0661 8.1665 22.7482 8.1665 22.4167C8.1665 22.0851 8.03481 21.7672 7.80039 21.5328C7.56597 21.2984 7.24802 21.1667 6.9165 21.1667ZM5.6665 27.4167C5.6665 27.0851 5.7982 26.7672 6.03262 26.5328C6.26704 26.2984 6.58498 26.1667 6.9165 26.1667C7.24802 26.1667 7.56597 26.2984 7.80039 26.5328C8.03481 26.7672 8.1665 27.0851 8.1665 27.4167C8.1665 27.7482 8.03481 28.0661 7.80039 28.3005C7.56597 28.535 7.24802 28.6667 6.9165 28.6667C6.58498 28.6667 6.26704 28.535 6.03262 28.3005C5.7982 28.0661 5.6665 27.7482 5.6665 27.4167ZM11.9165 16.1667C11.585 16.1667 11.267 16.2984 11.0326 16.5328C10.7982 16.7672 10.6665 17.0851 10.6665 17.4167C10.6665 17.7482 10.7982 18.0661 11.0326 18.3005C11.267 18.535 11.585 18.6667 11.9165 18.6667H21.0832C21.4147 18.6667 21.7326 18.535 21.9671 18.3005C22.2015 18.0661 22.3332 17.7482 22.3332 17.4167C22.3332 17.0851 22.2015 16.7672 21.9671 16.5328C21.7326 16.2984 21.4147 16.1667 21.0832 16.1667H11.9165ZM10.6665 22.4167C10.6665 22.0851 10.7982 21.7672 11.0326 21.5328C11.267 21.2984 11.585 21.1667 11.9165 21.1667H21.0832C21.4147 21.1667 21.7326 21.2984 21.9671 21.5328C22.2015 21.7672 22.3332 22.0851 22.3332 22.4167C22.3332 22.7482 22.2015 23.0661 21.9671 23.3005C21.7326 23.535 21.4147 23.6667 21.0832 23.6667H11.9165C11.585 23.6667 11.267 23.535 11.0326 23.3005C10.7982 23.0661 10.6665 22.7482 10.6665 22.4167ZM11.9165 26.1667C11.585 26.1667 11.267 26.2984 11.0326 26.5328C10.7982 26.7672 10.6665 27.0851 10.6665 27.4167C10.6665 27.7482 10.7982 28.0661 11.0326 28.3005C11.267 28.535 11.585 28.6667 11.9165 28.6667H21.0832C21.4147 28.6667 21.7326 28.535 21.9671 28.3005C22.2015 28.0661 22.3332 27.7482 22.3332 27.4167C22.3332 27.0851 22.2015 26.7672 21.9671 26.5328C21.7326 26.2984 21.4147 26.1667 21.0832 26.1667H11.9165ZM26.3565 11.0233L16.6415 1.31C16.6157 1.28605 16.5885 1.26378 16.5598 1.24333C16.5392 1.22742 16.5192 1.21074 16.4998 1.19333C16.3852 1.08512 16.2632 0.984882 16.1348 0.893332C16.0922 0.865802 16.0476 0.841298 16.0015 0.819999L15.9215 0.779999L15.8382 0.731666C15.7482 0.679999 15.6565 0.626665 15.5615 0.586665C15.2296 0.454104 14.8783 0.376423 14.5215 0.356665C14.4885 0.354519 14.4557 0.350625 14.4232 0.344999C14.3779 0.338012 14.3323 0.334114 14.2865 0.333332H3.99984C3.11578 0.333332 2.26794 0.684521 1.64281 1.30964C1.01769 1.93476 0.666504 2.78261 0.666504 3.66667V30.3333C0.666504 31.2174 1.01769 32.0652 1.64281 32.6904C2.26794 33.3155 3.11578 33.6667 3.99984 33.6667H23.9998C24.8839 33.6667 25.7317 33.3155 26.3569 32.6904C26.982 32.0652 27.3332 31.2174 27.3332 30.3333V13.38C27.333 12.496 26.9817 11.6483 26.3565 11.0233ZM24.8332 30.3333C24.8332 30.5543 24.7454 30.7663 24.5891 30.9226C24.4328 31.0789 24.2208 31.1667 23.9998 31.1667H3.99984C3.77882 31.1667 3.56686 31.0789 3.41058 30.9226C3.2543 30.7663 3.1665 30.5543 3.1665 30.3333V3.66667C3.1665 3.44565 3.2543 3.23369 3.41058 3.07741C3.56686 2.92113 3.77882 2.83333 3.99984 2.83333H13.9998V10.3333C13.9998 11.2174 14.351 12.0652 14.9761 12.6904C15.6013 13.3155 16.4491 13.6667 17.3332 13.6667H24.8332V30.3333ZM16.4998 4.70166L22.9632 11.1667H17.3332C17.1122 11.1667 16.9002 11.0789 16.7439 10.9226C16.5876 10.7663 16.4998 10.5543 16.4998 10.3333V4.70166Z"
fill="black"
/>
</svg>
</div>
<div className="flex w-full pr-10 flex-col flex-1">
<div className="text-gray-500 dark:text-gray-400 flex flex-row items-center text-xs gap-0 lg:gap-1 mt-1 lg:text-sm">
{formatDateToIndonesian(new Date(text?.createdAt))}
{text?.timezone ? text?.timezone : "WIB"}|
<Icon icon="formkit:eye" width="15" height="15" />
{text?.clickCount}
</div>
<div className="font-semibold text-gray-900 dark:text-white mt-1 text-sm h-5 hover:h-auto truncate hover:whitespace-normal hover:overflow-visible ">{text?.title}</div>
<div className="flex gap-2 items-center text-sm text-red-500 dark:text-red-500">
<svg xmlns="http://www.w3.org/2000/svg" width="1em" height="1em" viewBox="0 0 512 512">
<path fill="#f00" d="M224 30v256h-64l96 128l96-128h-64V30zM32 434v48h448v-48z" />
</svg>
Download {t("document")}
</div>
</div>
</div>
</div>
</CarouselItem>
))}
</CarouselContent>
<CarouselPrevious />
<CarouselNext />
</Carousel>
) : (
<p className="flex items-center justify-center">
<Image width={1920} height={1080} src="/assets/empty-data.png" alt="empty" className="h-52 w-52 my-4" />
</p>
)}
</div>
)}
<div className="flex items-center flex-row justify-center mt-7">
<div onClick={() => router.push(prefixPath + `/${selectedTab}/filter?sortBy=${props.type}`)} className="cursor-pointer border text-[#bb3523] rounded-lg text-sm lg:text-md px-4 py-1 border-[#bb3523]">
{t("seeAll")}
</div>
</div>
</div>
</Reveal>
</>
);
};
export default LatestContentKaltara;

View File

@ -0,0 +1,191 @@
"use client";
import { Link, useRouter } from "@/i18n/routing";
import Image from "next/image";
import { useParams, usePathname } from "next/navigation";
import React, { useState } from "react";
import { NavigationMenu, NavigationMenuContent, NavigationMenuItem, NavigationMenuLink, NavigationMenuList, NavigationMenuTrigger, navigationMenuTriggerStyle } from "@/components/ui/navigation-menu";
import { FiFile, FiImage, FiMusic, FiYoutube } from "react-icons/fi";
import { useTranslations } from "next-intl";
import LocalSwitcher from "@/components/partials/header/locale-switcher";
import ThemeSwitcher from "@/components/partials/header/theme-switcher";
import { Button } from "@/components/ui/button";
import { Icon } from "@iconify/react/dist/iconify.js";
const NavbarKaltara = () => {
const params = useParams();
const router = useRouter();
const pathname = usePathname();
const [menuOpen, setMenuOpen] = useState(false);
const [onSearch, setOnSearch] = useState("");
const locale = params?.locale;
const poldaName = params?.polda_name;
const satkerName = params?.satker_name;
const t = useTranslations("LandingPage");
let prefixPath = poldaName ? `/polda/${poldaName}` : satkerName ? `/satker/${satkerName}` : "/";
return (
<div className="bg-[#c03724] shadow-md sticky top-0 z-50">
<div className="flex items-center justify-between px-4 lg:px-20 py-4 gap-2">
<div className="flex flex-row gap-8">
<Link href={prefixPath} className="flex items-center">
<Image src="/assets/mediahub-logo.gif" alt="Media Hub Logo" width={200} height={300} className="object-contain" />
</Link>
<div className="hidden lg:flex items-center ml-2 gap-5">
<NavigationMenu>
<NavigationMenuList className="gap-10">
<NavigationMenuItem>
<NavigationMenuTrigger className="bg-[#c03724] text-white hover:bg-[#c03724] hover:text-white">
{/* <a className="text-white flex flex-row justify-center items-center cursor-pointer"> */}
{/* <svg className="mx-2 dark:" width="25" height="24" viewBox="0 0 25 24" fill="none" xmlns="http://www.w3.org/2000/svg">
<path
d="M20 7.5H5C4.6023 7.5004 4.221 7.65856 3.93978 7.93978C3.65856 8.221 3.5004 8.6023 3.5 9V19.5C3.5004 19.8977 3.65856 20.279 3.93978 20.5602C4.221 20.8414 4.6023 20.9996 5 21H20C20.3977 20.9996 20.779 20.8414 21.0602 20.5602C21.3414 20.279 21.4996 19.8977 21.5 19.5V9C21.4996 8.6023 21.3414 8.221 21.0602 7.93978C20.779 7.65856 20.3977 7.5004 20 7.5ZM10.25 17.25V11.25L15.5 14.25L10.25 17.25ZM5 4.5H20V6H5V4.5ZM6.5 1.5H18.5V3H6.5V1.5Z"
fill="currentColor"
/>
</svg> */}
{t("content")}
{/* </a> */}
</NavigationMenuTrigger>
<NavigationMenuContent className="flex flex-col place-content-start rounded-md overflow-hidden">
<NavigationMenuLink onClick={() => router.push(prefixPath + "/image/filter")} className="flex place-items-start gap-1.5 p-2 w-36">
<p className="text-slate-600 dark:text-white hover:text-[#bb3523] flex flex-row items-center py-2 cursor-pointer">
<FiImage className="mr-2" />
{t("image")}
</p>
</NavigationMenuLink>
<NavigationMenuLink onClick={() => router.push(prefixPath + "/video/filter")} className="flex items-start gap-1.5 p-2 ">
{pathname?.split("/")[1] == "in" ? (
<>
<p className="text-slate-600 text-left dark:text-white hover:text-[#bb3523] flex flex-row justify-center items-center py-2 cursor-pointer">
<FiYoutube className="mr-2" />
{t("video")}
</p>
</>
) : (
<>
<p className="text-slate-600 text-left dark:text-white hover:text-[#bb3523] flex flex-row justify-center items-center py-2 cursor-pointer">
<FiYoutube className="mr-2" />
{t("video")}
</p>
</>
)}
</NavigationMenuLink>
<NavigationMenuLink onClick={() => router.push(prefixPath + "/document/filter")} className="flex place-items-start gap-1.5 p-2">
<p className="text-slate-600 text-left dark:text-white hover:text-[#bb3523] flex flex-row justify-center items-center py-2 cursor-pointer">
<FiFile className="mr-2" />
{t("text")}
</p>
</NavigationMenuLink>
<NavigationMenuLink onClick={() => router.push(prefixPath + "/audio/filter")} className="flex place-items-start gap-1.5 p-2 ">
<p className="text-slate-600 text-left dark:text-white hover:text-[#bb3523] flex flex-row justify-center items-center py-2 cursor-pointer">
<FiMusic className="mr-2" />
{t("audio")}{" "}
</p>
</NavigationMenuLink>
</NavigationMenuContent>
</NavigationMenuItem>
<NavigationMenuItem>
<Link href={prefixPath + "/schedule"} legacyBehavior passHref>
<NavigationMenuLink className="bg-[#c03724] text-white">
{/* <span>
<svg className="mr-2" width="25" height="24" viewBox="0 0 25 24" fill="none" xmlns="http://www.w3.org/2000/svg">
<path
d="M19.5 4H18.5V3C18.5 2.4 18.1 2 17.5 2C16.9 2 16.5 2.4 16.5 3V4H8.5V3C8.5 2.4 8.1 2 7.5 2C6.9 2 6.5 2.4 6.5 3V4H5.5C3.8 4 2.5 5.3 2.5 7V8H22.5V7C22.5 5.3 21.2 4 19.5 4ZM2.5 19C2.5 20.7 3.8 22 5.5 22H19.5C21.2 22 22.5 20.7 22.5 19V10H2.5V19ZM17.5 12C18.1 12 18.5 12.4 18.5 13C18.5 13.6 18.1 14 17.5 14C16.9 14 16.5 13.6 16.5 13C16.5 12.4 16.9 12 17.5 12ZM17.5 16C18.1 16 18.5 16.4 18.5 17C18.5 17.6 18.1 18 17.5 18C16.9 18 16.5 17.6 16.5 17C16.5 16.4 16.9 16 17.5 16ZM12.5 12C13.1 12 13.5 12.4 13.5 13C13.5 13.6 13.1 14 12.5 14C11.9 14 11.5 13.6 11.5 13C11.5 12.4 11.9 12 12.5 12ZM12.5 16C13.1 16 13.5 16.4 13.5 17C13.5 17.6 13.1 18 12.5 18C11.9 18 11.5 17.6 11.5 17C11.5 16.4 11.9 16 12.5 16ZM7.5 12C8.1 12 8.5 12.4 8.5 13C8.5 13.6 8.1 14 7.5 14C6.9 14 6.5 13.6 6.5 13C6.5 12.4 6.9 12 7.5 12ZM7.5 16C8.1 16 8.5 16.4 8.5 17C8.5 17.6 8.1 18 7.5 18C6.9 18 6.5 17.6 6.5 17C6.5 16.4 6.9 16 7.5 16Z"
fill="currentColor"
/>
</svg>
</span> */}
{t("schedule")}
</NavigationMenuLink>
</Link>
</NavigationMenuItem>
<NavigationMenuItem>
<Link href={prefixPath + "/indeks"} legacyBehavior passHref>
<NavigationMenuLink className="bg-[#c03724] text-white">
{/* <span>
<svg className="mr-2" width="25" height="24" viewBox="0 0 25 24" fill="none" xmlns="http://www.w3.org/2000/svg">
<path
fill-rule="evenodd"
clip-rule="evenodd"
d="M2.5 6C2.5 5.20435 2.81607 4.44129 3.37868 3.87868C3.94129 3.31607 4.70435 3 5.5 3H19.5C20.2956 3 21.0587 3.31607 21.6213 3.87868C22.1839 4.44129 22.5 5.20435 22.5 6V18C22.5 18.7956 22.1839 19.5587 21.6213 20.1213C21.0587 20.6839 20.2956 21 19.5 21H5.5C4.70435 21 3.94129 20.6839 3.37868 20.1213C2.81607 19.5587 2.5 18.7956 2.5 18V6ZM7.5 7C7.23478 7 6.98043 7.10536 6.79289 7.29289C6.60536 7.48043 6.5 7.73478 6.5 8V12C6.5 12.2652 6.60536 12.5196 6.79289 12.7071C6.98043 12.8946 7.23478 13 7.5 13H11.5C11.7652 13 12.0196 12.8946 12.2071 12.7071C12.3946 12.5196 12.5 12.2652 12.5 12V8C12.5 7.73478 12.3946 7.48043 12.2071 7.29289C12.0196 7.10536 11.7652 7 11.5 7H7.5ZM8.5 11V9H10.5V11H8.5ZM15.5 7C15.2348 7 14.9804 7.10536 14.7929 7.29289C14.6054 7.48043 14.5 7.73478 14.5 8C14.5 8.26522 14.6054 8.51957 14.7929 8.70711C14.9804 8.89464 15.2348 9 15.5 9H17.5C17.7652 9 18.0196 8.89464 18.2071 8.70711C18.3946 8.51957 18.5 8.26522 18.5 8C18.5 7.73478 18.3946 7.48043 18.2071 7.29289C18.0196 7.10536 17.7652 7 17.5 7H15.5ZM15.5 11C15.2348 11 14.9804 11.1054 14.7929 11.2929C14.6054 11.4804 14.5 11.7348 14.5 12C14.5 12.2652 14.6054 12.5196 14.7929 12.7071C14.9804 12.8946 15.2348 13 15.5 13H17.5C17.7652 13 18.0196 12.8946 18.2071 12.7071C18.3946 12.5196 18.5 12.2652 18.5 12C18.5 11.7348 18.3946 11.4804 18.2071 11.2929C18.0196 11.1054 17.7652 11 17.5 11H15.5ZM7.5 15C7.23478 15 6.98043 15.1054 6.79289 15.2929C6.60536 15.4804 6.5 15.7348 6.5 16C6.5 16.2652 6.60536 16.5196 6.79289 16.7071C6.98043 16.8946 7.23478 17 7.5 17H17.5C17.7652 17 18.0196 16.8946 18.2071 16.7071C18.3946 16.5196 18.5 16.2652 18.5 16C18.5 15.7348 18.3946 15.4804 18.2071 15.2929C18.0196 15.1054 17.7652 15 17.5 15H7.5Z"
fill="currentColor"
/>
</svg>
</span> */}
{t("index")}
</NavigationMenuLink>
</Link>
</NavigationMenuItem>
</NavigationMenuList>
</NavigationMenu>
</div>
</div>
{/* Mobile Menu Toggle */}
<button className="text-black dark:text-white right-0 size-20 h-10 w-10 lg:hidden" onClick={() => setMenuOpen(!menuOpen)}>
{menuOpen ? (
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
<path fill="currentColor" d="m13.41 12l4.3-4.29a1 1 0 1 0-1.42-1.42L12 10.59l-4.29-4.3a1 1 0 0 0-1.42 1.42l4.3 4.29l-4.3 4.29a1 1 0 0 0 0 1.42a1 1 0 0 0 1.42 0l4.29-4.3l4.29 4.3a1 1 0 0 0 1.42 0a1 1 0 0 0 0-1.42Z" />
</svg>
) : (
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
<path fill="currentColor" d="M4 6a1 1 0 0 1 1-1h14a1 1 0 1 1 0 2H5a1 1 0 0 1-1-1m0 6a1 1 0 0 1 1-1h14a1 1 0 1 1 0 2H5a1 1 0 0 1-1-1m1 5a1 1 0 1 0 0 2h14a1 1 0 1 0 0-2z" />
</svg>
)}
</button>
<div className="flex flex-row items-center gap-3">
<Link href="/tbnews/polda-kaltara" className="text-white">
TBNews
</Link>
<div className="flex items-center">
<a href="https://tvradio.polri.go.id/">
<Image src="/assets/polriTv.png" width={100} height={120} alt="polritv" className="object-contain flex-auto " />
</a>
</div>
{/* Languange */}
<div className="relative inline-block text-left">
<LocalSwitcher />
</div>
<div className="relative text-gray-600 dark:text-white">
<input
value={onSearch}
onChange={(e) => setOnSearch(e.target.value)}
onKeyPress={() => router.push(`/all/filter?title=${onSearch}`)}
type="text"
placeholder={t("search")}
className="pl-8 pr-4 py-1 w-28 text-[13px] border rounded-full focus:outline-none dark:text-white"
/>
<span className="absolute left-4 top-1/2 transform -translate-y-1/2">
<svg xmlns="http://www.w3.org/2000/svg" width="13" height="13" viewBox="0 0 24 24">
<path
fill="currentColor"
fill-rule="evenodd"
d="M14.385 15.446a6.751 6.751 0 1 1 1.06-1.06l5.156 5.155a.75.75 0 1 1-1.06 1.06zM6.46 13.884a5.25 5.25 0 1 1 7.43-.005l-.005.005l-.005.004a5.25 5.25 0 0 1-7.42-.004"
clip-rule="evenodd"
/>
</svg>
</span>
</div>
{/* Dark Mode */}
<ThemeSwitcher />
{/* login */}
<Link href="/auth">
<Button className="hidden lg:flex justify-center items-center bg-white rounded-full gap-3 p-2 w-fit h-fit">
<Icon icon="material-symbols:lock" className="text-[#c03724]" />
<p className="text-[#c03724]">Login</p>
</Button>
</Link>
</div>
</div>
</div>
);
};
export default NavbarKaltara;

View File

@ -0,0 +1,34 @@
import { Input } from "@/components/ui/input";
import { useRouter } from "@/i18n/routing";
import { useTranslations } from "next-intl";
import React, { useState } from "react";
import { Reveal } from "../Reveal";
const SearchSectionKaltara = () => {
const [search, setSearch] = useState("");
const router = useRouter();
const t = useTranslations("LandingPage");
return (
<>
<Reveal>
<div className="flex flex-col items-center text-center py-12 px-4 md:py-16">
{/* Heading */}
<h2 className="text-[32px] font-sans md:text-3xl font-bold text-black">Liputan apa yang sedang anda cari?</h2>
<p className="text-gray-600 mt-2 max-w-lg text-[16px] font-sans md:text-base">Liputan terkini yang bersumber langsung dari kegiatan Polri di Mabes, Polda dan Polres di seluruh Indonesia</p>
{/* Subjudul */}
<h3 className="text-sm md:text-[20px] font-sans font-semibold mt-6">Temukan Liputan Anda</h3>
{/* Search Bar */}
<div className="relative mt-4 w-full max-w-sm md:max-w-md">
<Input type="text" placeholder="Cari liputan disini..." className="w-full border border-gray-300 rounded-lg px-4 py-3 text-sm md:text-base text-gray-700 focus:ring-2 focus:ring-blue-500 focus:border-blue-500 font-sans" />
<button className="absolute right-4 top-1/2 transform -translate-y-1/2 text-gray-500">🔍</button>
</div>
</div>
</Reveal>
</>
);
};
export default SearchSectionKaltara;

Binary file not shown.

After

Width:  |  Height:  |  Size: 450 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 30 KiB

2
style/global.css Normal file
View File

@ -0,0 +1,2 @@
/* @import url("https://fonts.googleapis.com/css2?family=Bytesized&family=Roboto:ital,wght@0,100;0,300;0,400;0,500;0,700;0,900;1,100;1,300;1,400;1,500;1,700;1,900&display=swap"); */
@import url("https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,100..1000;1,9..40,100..1000&display=swap");

View File

@ -1,14 +1,8 @@
import type { Config } from "tailwindcss"
import type { Config } from "tailwindcss";
const config = {
darkMode: ["class"],
content: [
'./pages/**/*.{ts,tsx}',
'./components/**/*.{js,ts,tsx}',
'./providers/**/*.{ts,tsx}',
'./app/**/*.{ts,tsx}',
'./src/**/*.{ts,tsx}',
],
content: ["./pages/**/*.{ts,tsx}", "./components/**/*.{js,ts,tsx}", "./providers/**/*.{ts,tsx}", "./app/**/*.{ts,tsx}", "./src/**/*.{ts,tsx}"],
prefix: "",
theme: {
container: {
@ -19,11 +13,14 @@ const config = {
},
},
extend: {
colors: {
fontFamily: {
sans: ["DM Sans", "sans-serif"],
},
colors: {
border: "hsl(var(--border))",
'menu-arrow': "hsl(var(--menu-arrow))",
'menu-arrow-active': "hsl(var(--menu-arrow-active))",
'menu-menu-foreground': "hsl(var(--menu-foreground))",
"menu-arrow": "hsl(var(--menu-arrow))",
"menu-arrow-active": "hsl(var(--menu-arrow-active))",
"menu-menu-foreground": "hsl(var(--menu-foreground))",
default: {
50: "hsl(var(--default-50) / <alpha-value>)",
100: "hsl(var(--default-100) / <alpha-value>)",
@ -65,11 +62,9 @@ const config = {
},
sidebar: {
DEFAULT: "hsl(var(--sidebar))",
},
header: {
DEFAULT: "hsl(var(--header))",
},
destructive: {
DEFAULT: "hsl(var(--destructive))",
@ -106,7 +101,7 @@ const config = {
foreground: "hsl(var(--card-foreground))",
},
},
borderRadius: {
lg: "var(--radius)",
md: "calc(var(--radius) - 2px)",
@ -121,7 +116,7 @@ const config = {
from: { height: "var(--radix-accordion-content-height)" },
to: { height: "0" },
},
zoom: {
zoom: {
"0%, 100%": { transform: "scale(0.5)" },
"50%": { transform: "scale(1)" },
},
@ -141,8 +136,7 @@ const config = {
},
boxShadow: {
base: "0px 0px 1px rgba(40, 41, 61, 0.08), 0px 0.5px 2px rgba(96, 97, 112, 0.16)",
base2:
"0px 2px 4px rgba(40, 41, 61, 0.04), 0px 8px 16px rgba(96, 97, 112, 0.16)",
base2: "0px 2px 4px rgba(40, 41, 61, 0.04), 0px 8px 16px rgba(96, 97, 112, 0.16)",
base3: "16px 10px 40px rgba(15, 23, 42, 0.22)",
deep: "-2px 0px 8px rgba(0, 0, 0, 0.16)",
dropdown: "0px 4px 8px rgba(0, 0, 0, 0.08)",
@ -154,11 +148,11 @@ const config = {
"accordion-down": "accordion-down 0.2s ease-out",
"accordion-up": "accordion-up 0.2s ease-out",
zoom: "zoom 1s ease-in-out infinite",
tada: "tada 1.5s ease-in-out infinite",
tada: "tada 1.5s ease-in-out infinite",
},
},
},
plugins: [require("tailwindcss-animate")],
} satisfies Config
} satisfies Config;
export default config
export default config;