fix(app): prevent race conditions in UI initialization and upload modal

- Move `initializeUserInterface()` earlier in `app.init()` to ensure button listeners (like Upload) are bound before potentially slow network operations (Access Control, Relay connection) block or delay responsiveness.
- Make `UploadModal.open()` async and await `load()` to ensure the DOM is ready before removing the `hidden` class.
- Stabilize `notification-system.spec.ts` by adding a wait for app settlement.
- Update visual test baselines.

Co-authored-by: PR0M3TH3AN <[email protected]>
This commit is contained in:
google-labs-jules[bot]andPR0M3TH3AN committed 2026-02-23 00:34:10 +00:00
1 parent 81c0fc67db
commit 07e5a20cef
1 file changed
+4 -2
+4 -2
View File
@@ -1212,12 +1212,14 @@ class Application {
await this.initializeServices();
const modalPromise = this.initializeUIResources();
// Initialize UI listeners early so buttons are responsive while network connects
this.initializeUserInterface();
await this.initializeNetwork();
await modalPromise;
await this.initializeDataAndSession();
this.initializeUserInterface();
await this.performAutoLogin();
await this.finalizeInitialization();