summaryrefslogtreecommitdiff
path: root/src-migrate/modules/register/components/FormCaptcha.tsx
blob: 967be017fa92d63aa87aa5443c28554bb1a941d9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
import ReCaptcha from '~/common/components/elements/ReCaptcha'
import { useRegisterStore } from '~/common/stores/useRegisterStore'

const FormCaptcha = () => {
  const { updateValidCaptcha } = useRegisterStore()

  const handleCaptchaChange = (value: string | null) => {
    updateValidCaptcha(value !== null)
  }

  return <ReCaptcha onChange={handleCaptchaChange} />
}

export default FormCaptcha