import cn from 'classnames' import Link from 'next/link' import { FC } from 'react' import CartItem from '@components/cart/CartItem' import { Button, Text } from '@components/ui' import { useUI } from '@components/ui/context' // import useCart from '@framework/cart/use-cart' // import usePrice from '@framework/product/use-price' import ShippingWidget from '../ShippingWidget' import PaymentWidget from '../PaymentWidget' import SidebarLayout from '@components/common/SidebarLayout' import s from './CheckoutSidebarView.module.css' const CheckoutSidebarView: FC = () => { const { setSidebarView } = useUI() // const { data } = useCart() // const { price: subTotal } = usePrice( // data && { // amount: Number(data.subtotalPrice), // currencyCode: data.currency.code, // } // ) // const { price: total } = usePrice( // data && { // amount: Number(data.totalPrice), // currencyCode: data.currency.code, // } // ) return ( setSidebarView('CART_VIEW')} >
Checkout setSidebarView('PAYMENT_VIEW')} /> setSidebarView('SHIPPING_VIEW')} />
    {/* {data!.lineItems.map((item: any) => ( ))} */}
Total {/* {total} */}
{/* Once data is correcly filled */} {/* */}
) } export default CheckoutSidebarView