diff options
| author | HATEC\SPVDEV001 <tri.susilo@altama.co.id> | 2024-01-30 09:05:07 +0700 |
|---|---|---|
| committer | HATEC\SPVDEV001 <tri.susilo@altama.co.id> | 2024-01-30 09:05:07 +0700 |
| commit | 76e3eec8db414307cea6b11e3ebb461aed8e1e26 (patch) | |
| tree | 4676144e36d87c51ad2da428ad97a9aebd3b98c1 /src/core/components/elements/Navbar/NavbarDesktop.jsx | |
| parent | f7701abcbe05510c3672c4768df03fee535956e3 (diff) | |
| parent | e35595250f9e0408e23d1da3ac30ac1179e2a376 (diff) | |
Merge branch 'release' of https://bitbucket.org/altafixco/next-indoteknik into release
Diffstat (limited to 'src/core/components/elements/Navbar/NavbarDesktop.jsx')
| -rw-r--r-- | src/core/components/elements/Navbar/NavbarDesktop.jsx | 33 |
1 files changed, 17 insertions, 16 deletions
diff --git a/src/core/components/elements/Navbar/NavbarDesktop.jsx b/src/core/components/elements/Navbar/NavbarDesktop.jsx index 9bcd4df2..d1ff2d58 100644 --- a/src/core/components/elements/Navbar/NavbarDesktop.jsx +++ b/src/core/components/elements/Navbar/NavbarDesktop.jsx @@ -1,29 +1,30 @@ +import { useProductContext } from '@/contexts/ProductContext'; +import useAuth from '@/core/hooks/useAuth'; +import { getCountCart } from '@/core/utils/cart'; +import { createSlug } from '@/core/utils/slug'; +import whatsappUrl from '@/core/utils/whatsappUrl'; +import IndoteknikLogo from '@/images/logo.png'; +import Cardheader from '@/lib/cart/components/Cartheader'; +import Category from '@/lib/category/components/Category'; import { ChevronDownIcon, - HeartIcon, - ShoppingCartIcon, DocumentCheckIcon, + HeartIcon, } from '@heroicons/react/24/outline'; -import Link from '../Link/Link'; +import dynamic from 'next/dynamic'; import Image from 'next/image'; +import { useRouter } from 'next/router'; +import { useEffect, useState } from 'react'; import DesktopView from '../../views/DesktopView'; -import dynamic from 'next/dynamic'; -import IndoteknikLogo from '@/images/logo.png'; -import Category from '@/lib/category/components/Category'; -import { useCallback, useContext, useEffect, useState } from 'react'; -import useAuth from '@/core/hooks/useAuth'; +import Link from '../Link/Link'; import NavbarUserDropdown from './NavbarUserDropdown'; -import { getCartApi, getCountCart } from '@/core/utils/cart'; -import whatsappUrl from '@/core/utils/whatsappUrl'; -import { useRouter } from 'next/router'; -import { getAuth, setAuth } from '@/core/utils/auth'; -import { createSlug, getIdFromSlug } from '@/core/utils/slug'; import { TopBannerSkeleton } from '../Skeleton/TopBannerSkeleton'; -import { useProductContext } from '@/contexts/ProductContext'; -import Cardheader from '@/lib/cart/components/Cartheader'; const Search = dynamic(() => import('./Search'), { ssr: false }); -const TopBanner = dynamic(() => import('./TopBanner'), { ssr: false }); +const TopBanner = dynamic(() => import('./TopBanner'), { + ssr: false, + loading: () => <TopBannerSkeleton />, +}); const NavbarDesktop = () => { const [isOpenCategory, setIsOpenCategory] = useState(false); |
