feat: update popup data
This commit is contained in:
parent
1e4d324963
commit
65d1aaf3fe
|
|
@ -55,6 +55,7 @@ type HeroModalProps = {
|
|||
group: string;
|
||||
poldaName?: string;
|
||||
satkerName?: string;
|
||||
dataContent?: any;
|
||||
};
|
||||
|
||||
const HeroModal = ({
|
||||
|
|
@ -62,6 +63,7 @@ const HeroModal = ({
|
|||
group,
|
||||
poldaName,
|
||||
satkerName,
|
||||
dataContent,
|
||||
}: HeroModalProps) => {
|
||||
const [heroData, setHeroData] = useState<any[]>([]);
|
||||
const params = useParams();
|
||||
|
|
@ -138,7 +140,7 @@ const HeroModal = ({
|
|||
ref={modalRef}
|
||||
className="relative dark:bg-gray-900 rounded-lg w-[90%] md:w-[600px] p-4 shadow-none"
|
||||
>
|
||||
{heroData?.length > 0 && (
|
||||
{dataContent?.length > 0 && (
|
||||
<>
|
||||
<button
|
||||
className="absolute left-3 top-1/2 z-10 -translate-y-1/2 text-white text-3xl"
|
||||
|
|
@ -161,7 +163,7 @@ const HeroModal = ({
|
|||
autoplay={{ delay: 3000 }}
|
||||
className="mySwiper w-full"
|
||||
>
|
||||
{heroData.map((list: any) => (
|
||||
{dataContent.map((list: any) => (
|
||||
<SwiperSlide key={list?.id}>
|
||||
<div className="relative h-[310px] lg:h-[420px]">
|
||||
<button
|
||||
|
|
@ -458,6 +460,7 @@ const HeroNew = (props: { group?: string }) => {
|
|||
group={props.group || "mabes"}
|
||||
poldaName={poldaName as string}
|
||||
satkerName={satkerName as string}
|
||||
dataContent={content}
|
||||
/>
|
||||
)}
|
||||
</div>
|
||||
|
|
|
|||
Loading…
Reference in New Issue