fix: logo satker navbar

This commit is contained in:
Sabda Yagra 2025-06-05 19:37:53 +07:00
parent f51469942e
commit 8741b08787
2 changed files with 4 additions and 4 deletions

View File

@ -8,7 +8,7 @@ import { usePathname } from "next/navigation";
import Image from "next/image";
const regions = [
{ name: "ITWASUM POLRI", slug: "itwasum", logo: "/logo/satker/itwasum.png" },
{ name: "ITWASUM POLRI", slug: "itwasum", logo: "/logo/satker/ITWASUM.png" },
{ name: "BAINTELKAM POLRI", slug: "baintelkam", logo: "/logo/satker/BAINTELKAM.png" },
{ name: "BAHARKAM POLRI", slug: "baharkam", logo: "/logo/satker/BAHARKAM.png" },
{ name: "BARESKRIM POLRI", slug: "bareskrim", logo: "/logo/satker/BARESKRIM.png" },

View File

@ -6,12 +6,12 @@ import { usePathname } from "next/navigation";
export const DynamicLogoSatker = () => {
const pathname = usePathname();
const satker = pathname?.split("/")[3];
console.log("satker", satker)
console.log("satker", satker?.toUpperCase())
return <div className="p-2">
{pathname?.includes("/satker") && (
<img
src={`/logo/satker/${satker}.png`}
<Image
src={`/logo/satker/${satker?.toUpperCase()}.png`}
alt="Logo"
width={1920}
height={1080}