From 30142ab6c6f37fb381264efd0dc94aa997b1a278 Mon Sep 17 00:00:00 2001
From: it-fixcomart <it@fixcomart.co.id>
Date: Wed, 17 Jul 2024 15:14:43 +0700
Subject: <iman> update dynamic description

---
 src-migrate/modules/promo/components/Hero.tsx | 33 ++++++++++++++-------------
 1 file changed, 17 insertions(+), 16 deletions(-)

(limited to 'src-migrate/modules/promo/components/Hero.tsx')

diff --git a/src-migrate/modules/promo/components/Hero.tsx b/src-migrate/modules/promo/components/Hero.tsx
index 7eb84270..b91288dd 100644
--- a/src-migrate/modules/promo/components/Hero.tsx
+++ b/src-migrate/modules/promo/components/Hero.tsx
@@ -13,6 +13,8 @@ import DesktopView from '@/core/components/views/DesktopView';
 import {bannerApi} from '../../../../src/api/bannerApi'
 
 interface IPromotionProgram {
+  headline_banner: string;
+  description_banner: string;
   image: string ;
   name: string;
 }
@@ -58,27 +60,26 @@ const Hero = () => {
     <>
       <DesktopView>
         <div className={style['wrapper']}>
-          <div className={style['desc-section']}>
-            <div className={style['title']}>Pasti Hemat & Untung Selama Belanja di Indoteknik.com!</div>
-            <div className='h-4' />
-            <div className={style['subtitle']}>Cari paket yang kami sediakan dengan penawaran harga & Nikmati kemudahan dalam setiap transaksi dengan fitur lengkap Pembayaran hingga barang sampai! </div>
-          </div>
-
-          <div className={style['banner-section']}>
             <Swiper {...swiperBanner}>
               {banners.map((banner, index) => (
-                <SwiperSlide key={index}>
-                  <Image
-                    src={banner.image}
-                    alt={banner.name}
-                    width={666}
-                    height={450}
-                    quality={100}
-                    className='w-full h-full object-fit object-center rounded-2xl' />
+                <SwiperSlide key={index} className='flex flex-row'>
+                  <div className={style['desc-section']}>
+                    <div className={style['title']}>{banner.headline_banner? banner.headline_banner : "Pasti Hemat & Untung Selama Belanja di Indoteknik.com!"}</div>
+                    <div className='h-4' />
+                    <div className={style['subtitle']}>{banner.description_banner? banner.description_banner : "Cari paket yang kami sediakan dengan penawaran harga & Nikmati kemudahan dalam setiap transaksi dengan fitur lengkap Pembayaran hingga barang sampai!"}</div>
+                  </div>
+                  <div className={style['banner-section']}>
+                    <Image
+                      src={banner.image}
+                      alt={banner.name}
+                      width={666}
+                      height={450}
+                      quality={100}
+                      className='w-full h-full object-fit object-center rounded-2xl' />
+                  </div>
                 </SwiperSlide>
               ))}
             </Swiper>
-          </div>
         </div>
       </DesktopView>
       <MobileView>
-- 
cgit v1.2.3

