import React from 'react'
import Drawer from 'react-modern-drawer'
import 'react-modern-drawer/dist/index.css'
import CartDetails from './CartDetails'

const Cartbar = ({status, onSetSidebarOpen}) => {

  return (
    <div>
      <Drawer
        open={status}
        onClose={onSetSidebarOpen}
        direction='right'
        zIndex={99999}
        size={350}
        style={{
          overflowY: 'scroll',
          overflowX: 'hidden'
        }}
      >
        <CartDetails />
      </Drawer>
    </div>
  )
}

export default Cartbar