fix: 修复 UserCaptcha 组件 sendState 实时更新问题

This commit is contained in:
2026-05-14 10:28:51 +08:00
parent 38e123dfc4
commit 233a10399d
1 changed files with 29 additions and 0 deletions

View File

@ -356,6 +356,35 @@ const updateSendState = () => {
sendState.value = { isCounting: t.isCounting.value, countdown: t.countdown.value };
};
// editField sendState
watch(
() => editField.value,
() => {
nextTick(() => {
updateSendState();
});
}
);
// sendState
watch(
() => phoneCaptchaState.countdown.value,
() => {
if (editField.value === 'mobile') {
updateSendState();
}
}
);
watch(
() => emailCaptchaState.countdown.value,
() => {
if (editField.value === 'email') {
updateSendState();
}
}
);
//
const handleLanguageChange = async (val: number) => {
try {