'use client'

import { usePopupController } from '@/store/popupController'

import MemberInfomationPopup from '../popup/MemberInformationPopup'
import ZipCodePopup from '../popup/ZipCodePopup'
import Alert from './common/Alert'
import DoubleBtnAlert from './common/DoubleBtnAlert'
import SuitableDetailPopup from '../popup/SuitableDetailPopup'

export default function PopupController() {
  const popupController = usePopupController()

  return (
    <>
      {popupController.memberInfomationPopup && <MemberInfomationPopup />}
      {popupController.zipCodePopup && <ZipCodePopup />}
      {popupController.alert && <Alert />}
      {popupController.alert2 && <DoubleBtnAlert />}
      {popupController.suitableDetailPopup && <SuitableDetailPopup />}
    </>
  )
}
