Implement structure for code changes tracking

This commit is contained in:
QLHazyCoder
2026-04-17 09:43:39 +08:00
parent a54474a3ee
commit be3172df63
6 changed files with 453 additions and 147 deletions
+18 -6
View File
@@ -537,15 +537,27 @@ async function step3_fillEmailPassword(payload) {
// Report complete BEFORE submit, because submit causes page navigation
// which kills the content script connection
const signupVerificationRequestedAt = submitBtn ? Date.now() : null;
reportComplete(3, { email, signupVerificationRequestedAt });
const completionPayload = {
email,
signupVerificationRequestedAt,
deferredSubmit: Boolean(submitBtn),
};
reportComplete(3, completionPayload);
// Submit the form (page will navigate away after this)
await sleep(500);
if (submitBtn) {
await humanPause(500, 1300);
simulateClick(submitBtn);
log('步骤 3:表单已提交');
window.setTimeout(async () => {
try {
await sleep(500);
await humanPause(500, 1300);
simulateClick(submitBtn);
log('步骤 3:表单已提交');
} catch (error) {
console.error('[MultiPage:signup-page] deferred step 3 submit failed:', error?.message || error);
}
}, 120);
}
return completionPayload;
}
// ============================================================