diff --git a/components/cart/CartSidebarView/CartSidebarView.tsx b/components/cart/CartSidebarView/CartSidebarView.tsx
index 5b28fde27..3ceda44fe 100644
--- a/components/cart/CartSidebarView/CartSidebarView.tsx
+++ b/components/cart/CartSidebarView/CartSidebarView.tsx
@@ -9,7 +9,7 @@ import usePrice from '@framework/product/use-price'
import CartItem from '../CartItem'
import s from './CartSidebarView.module.css'
-const CartSidebarView: FC<{ wishlist?: boolean }> = ({ wishlist }) => {
+const CartSidebarView: FC = () => {
const { closeSidebar } = useUI()
const { data, isLoading, isEmpty } = useCart()
@@ -48,7 +48,7 @@ const CartSidebarView: FC<{ wishlist?: boolean }> = ({ wishlist }) => {
-
+
diff --git a/components/common/HomeAllProductsGrid/HomeAllProductsGrid.tsx b/components/common/HomeAllProductsGrid/HomeAllProductsGrid.tsx
index 4b838e1a4..423048f75 100644
--- a/components/common/HomeAllProductsGrid/HomeAllProductsGrid.tsx
+++ b/components/common/HomeAllProductsGrid/HomeAllProductsGrid.tsx
@@ -5,20 +5,17 @@ import { Grid } from '@components/ui'
import { ProductCard } from '@components/product'
import s from './HomeAllProductsGrid.module.css'
import { getCategoryPath, getDesignerPath } from '@lib/search'
-import wishlist from '@framework/api/wishlist'
interface Props {
categories?: any
brands?: any
products?: Product[]
- wishlist?: boolean
}
const HomeAllProductsGrid: FC = ({
categories,
brands,
products = [],
- wishlist = false,
}) => {
return (
@@ -65,7 +62,6 @@ const HomeAllProductsGrid: FC
= ({
width: 480,
height: 480,
}}
- wishlist={wishlist}
/>
))}
diff --git a/components/common/Layout/Layout.tsx b/components/common/Layout/Layout.tsx
index 82e045474..54749c46b 100644
--- a/components/common/Layout/Layout.tsx
+++ b/components/common/Layout/Layout.tsx
@@ -61,7 +61,7 @@ const Layout: FC = ({
return (
-
+
{children}
@@ -72,7 +72,7 @@ const Layout: FC
= ({
-
+
= ({ wishlist }) => (
+const Navbar: FC = () => (
@@ -33,7 +33,7 @@ const Navbar: FC<{ wishlist?: boolean }> = ({ wishlist }) => (
-
+
diff --git a/components/common/UserNav/UserNav.tsx b/components/common/UserNav/UserNav.tsx
index 5d9d58fff..d2dfc11dd 100644
--- a/components/common/UserNav/UserNav.tsx
+++ b/components/common/UserNav/UserNav.tsx
@@ -12,12 +12,11 @@ import { Avatar } from '@components/common'
interface Props {
className?: string
- wishlist?: boolean
}
const countItem = (count: number, item: LineItem) => count + item.quantity
-const UserNav: FC = ({ className, wishlist = false }) => {
+const UserNav: FC = ({ className }) => {
const { data } = useCart()
const { data: customer } = useCustomer()
const { toggleSidebar, closeSidebarIfPresent, openModal } = useUI()
@@ -31,7 +30,7 @@ const UserNav: FC = ({ className, wishlist = false }) => {
{itemsCount > 0 && {itemsCount}}
- {wishlist && (
+ {process.env.WISHLIST_ENABLED && (