Fix DOT intake: wait for DOMContentLoaded before showing sections

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
justin 2026-05-30 15:27:39 -05:00
parent 897554fa4e
commit 7fe3311921

View file

@ -300,8 +300,12 @@
}
}
// Show sections immediately and on step-shown
showRelevantSections();
// Show sections on DOM ready and on step-shown
if (document.readyState === "loading") {
document.addEventListener("DOMContentLoaded", showRelevantSections);
} else {
showRelevantSections();
}
window.addEventListener("pw:step-shown", (evt: any) => {
if (evt.detail.step !== "dot-intake") return;
showRelevantSections();