修复编译问题 & 将人机验证组件动态化

This commit is contained in:
2025-12-20 18:05:46 +08:00
parent c979765a77
commit adc8195d53
8 changed files with 13 additions and 73 deletions

View File

@@ -10,7 +10,7 @@ import * as z from 'zod'
import {toast} from 'sonner'
import {useRouter} from 'next/navigation'
import {updatePassword} from '@/actions/user'
import SendMsg from '@/components/send-msg'
import dynamic from 'next/dynamic'
// 表单验证规则
const schema = z.object({
@@ -158,3 +158,5 @@ function SendMsgByPhone() {
const phone = useWatch({control, name: 'phone'})
return <SendMsg phone={phone}/>
}
const SendMsg = dynamic(() => import('@/components/send-msg'), {ssr: false})