mirror of
https://github.com/vercel/commerce.git
synced 2025-07-22 20:26:49 +00:00
🐛 bug: remove message item when hide
:%s
This commit is contained in:
@@ -40,7 +40,7 @@ const MessageItem = memo(
|
|||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
if (isHide && !isMouseOver && onRemove) {
|
if (isHide && !isMouseOver && onRemove) {
|
||||||
// onRemove(id || 0)
|
onRemove(id || 0)
|
||||||
}
|
}
|
||||||
}, [isHide, isMouseOver, onRemove, id])
|
}, [isHide, isMouseOver, onRemove, id])
|
||||||
|
|
||||||
|
@@ -32,7 +32,7 @@ const ModalAuthenticate = ({ visible, mode, closeModal }: Props) => {
|
|||||||
closeModal()
|
closeModal()
|
||||||
router.push(ROUTE.ACCOUNT)
|
router.push(ROUTE.ACCOUNT)
|
||||||
}
|
}
|
||||||
}, [customer, visible])
|
}, [customer, visible, closeModal, router])
|
||||||
|
|
||||||
const onSwitch = () => {
|
const onSwitch = () => {
|
||||||
setIsLogin(!isLogin)
|
setIsLogin(!isLogin)
|
||||||
|
@@ -1,7 +1,7 @@
|
|||||||
import { Form, Formik } from 'formik'
|
import { Form, Formik } from 'formik'
|
||||||
import Link from 'next/link'
|
import Link from 'next/link'
|
||||||
import React, { useEffect, useRef, useState } from 'react'
|
import React, { useEffect, useRef } from 'react'
|
||||||
import { ButtonCommon, Inputcommon, InputFiledInForm, InputPassword, InputPasswordFiledInForm } from 'src/components/common'
|
import { ButtonCommon, InputFiledInForm, InputPasswordFiledInForm } from 'src/components/common'
|
||||||
import { useMessage } from 'src/components/contexts'
|
import { useMessage } from 'src/components/contexts'
|
||||||
import useLogin from 'src/components/hooks/useLogin'
|
import useLogin from 'src/components/hooks/useLogin'
|
||||||
import { ROUTE } from 'src/utils/constanst.utils'
|
import { ROUTE } from 'src/utils/constanst.utils'
|
||||||
|
Reference in New Issue
Block a user