Fix WebUI login page stuck when navigating via token URL (#1835)
* Initial plan * Fix: set isPasskeyLoading=false when token is in URL to prevent permanently disabled input on login failure Agent-Logs-Url: https://github.com/NapNeko/NapCatQQ/sessions/fa88593a-3466-40e5-80ff-82c47e1c56e6 Co-authored-by: sj817 <74231782+sj817@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: sj817 <74231782+sj817@users.noreply.github.com>
This commit is contained in:
1 parent
8996b35dd1
commit
b253fd82c4
1 file changed
+2
@@ -142,6 +142,8 @@ export default function WebLoginPage () {
|
|||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
// 如果URL中有token,直接登录
|
// 如果URL中有token,直接登录
|
||||||
if (token) {
|
if (token) {
|
||||||
|
// 不需要检查passkey,立即清除loading状态,避免登录失败后输入框被永久禁用
|
||||||
|
setIsPasskeyLoading(false);
|
||||||
onSubmit();
|
onSubmit();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in new issue
Block a user