summaryrefslogtreecommitdiff
path: root/src/lib/home/components/PromotionProgram.jsx
diff options
context:
space:
mode:
authorit-fixcomart <it@fixcomart.co.id>2024-08-31 09:25:53 +0700
committerit-fixcomart <it@fixcomart.co.id>2024-08-31 09:25:53 +0700
commit6a0c477de3df773f2a818b904029624c212f083f (patch)
treee1f7a09eb83509de594fe7dbb015a71dd18cec26 /src/lib/home/components/PromotionProgram.jsx
parent3de1a412bba31b19b8b443dd91df8aff8d6eda07 (diff)
parentc6e970598c6c23f0606d1bc19036f0decd57cc05 (diff)
Merge branch 'release' into Feature/new-cart-popup
Diffstat (limited to 'src/lib/home/components/PromotionProgram.jsx')
-rw-r--r--src/lib/home/components/PromotionProgram.jsx5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/lib/home/components/PromotionProgram.jsx b/src/lib/home/components/PromotionProgram.jsx
index 99258d94..c2f76069 100644
--- a/src/lib/home/components/PromotionProgram.jsx
+++ b/src/lib/home/components/PromotionProgram.jsx
@@ -3,11 +3,16 @@ import Image from 'next/image'
import { bannerApi } from '@/api/bannerApi';
import useDevice from '@/core/hooks/useDevice'
import { Swiper, SwiperSlide } from 'swiper/react';
+import BannerPromoSkeleton from '../components/Skeleton/BannerPromoSkeleton';
const { useQuery } = require('react-query')
const BannerSection = () => {
const promotionProgram = useQuery('promotionProgram', bannerApi({ type: 'banner-promotion' }));
const { isMobile, isDesktop } = useDevice()
+ if (promotionProgram.isLoading) {
+ return <BannerPromoSkeleton />;
+ }
+
return (
<div className='px-4 sm:px-0'>
<div className='flex justify-between items-center mb-4 '>