"use client"; import Image from "next/image"; import React, { useEffect, useState } from "react"; import { callUsItems } from "@/constants"; import { getSingleWebContents } from "@/utils/commonApi"; import { cn } from "@/lib/utils"; const Map = dynamic(() => import("./Map"), { ssr: false, }); import dynamic from "next/dynamic"; import { useQuery } from "@tanstack/react-query"; export default function CallUs(props: any) { const { position, zoom } = props; // const [title, setTitle] = useState("CullUs"); // const { data, isLoading, isError, refetch } = useQuery({ // queryKey: ["WebContents", title], // queryFn: () => getSingleWebContents(title), // refetchOnWindowFocus: false, // }); // console.log(data); // useEffect(() => { // refetch(); // }, [title, refetch]); // if (isLoading) { // return

Loading...

; // } // if (isError) { // return

Error fetching content.

; // } // const fetchedContent = data?.content || ""; // Assuming your API response has a 'content' property return (
{/*
*/} {/* */} {/* Display fetched content */} {/*
*/} {/*
*/}
{callUsItems.map((item) => { return (
{item.icon}

{item.title}

{item.description}

{item.description2}

); })}
); }