Extension login infinite loading #198

Merged
enes merged 13 commits from 196-ext-login-infinite-loading into staging 2024-09-16 12:27:44 +00:00
Member

The user was unable to log in with an older/unsupported nostr extension which caused the infinite loading.

This PR's intent is to add a fallback and a timeout for such cases where extensions are not responding within a certain timeframe.

To that end, we:

  • introduced the EXTENSION_LOGIN_DELAY_SECONDS (the delay after initial login press after which we assume extension is taking longer than usual) and EXTENSION_LOGIN_TIMEOUT_SECONDS (the actual timeout) which interrupts login attempt and gives back control to the user.
  • expanded LoadingSpinner, it can optionally include child component, i.e Button to manually interrupt the loading
  • custom TimeoutError which we can type check against and log the error

Additionally, we updated the isOnline detection to self-ping (localhost will cause false positives). The online detection will be updated with the new offline flow features.

Closes #196

The user was unable to log in with an older/unsupported nostr extension which caused the infinite loading. This PR's intent is to add a fallback and a timeout for such cases where extensions are not responding within a certain timeframe. To that end, we: - introduced the `EXTENSION_LOGIN_DELAY_SECONDS` (the delay after initial login press after which we assume extension is taking longer than usual) and `EXTENSION_LOGIN_TIMEOUT_SECONDS` (the actual timeout) which interrupts login attempt and gives back control to the user. - expanded `LoadingSpinner`, it can optionally include child component, i.e `Button` to manually interrupt the loading - custom `TimeoutError` which we can type check against and log the error Additionally, we updated the `isOnline` detection to self-ping (`localhost` will cause false positives). The online detection will be updated with the new offline flow features. Closes #196
enes added 4 commits 2024-09-12 07:58:23 +00:00
enes added 2 commits 2024-09-12 11:24:19 +00:00
enes requested review from eugene 2024-09-12 11:24:49 +00:00
enes added 1 commit 2024-09-12 11:31:06 +00:00
refactor: move publish button to the bottom
All checks were successful
Open PR on Staging / audit_and_check (pull_request) Successful in 33s
2e58b58a6a
enes added 2 commits 2024-09-13 09:14:17 +00:00
refactor: log timeout error only, no toast
All checks were successful
Open PR on Staging / audit_and_check (pull_request) Successful in 34s
ba24e7417d
enes added 1 commit 2024-09-13 15:48:12 +00:00
fix: url
All checks were successful
Open PR on Staging / audit_and_check (pull_request) Successful in 34s
79ef9eb8d6
enes added 1 commit 2024-09-16 09:00:26 +00:00
fix(online-detection): use relative url
All checks were successful
Open PR on Staging / audit_and_check (pull_request) Successful in 35s
8b4f1a8973
b added 1 commit 2024-09-16 11:45:23 +00:00
Merge branch 'staging' into 196-ext-login-infinite-loading
All checks were successful
Open PR on Staging / audit_and_check (pull_request) Successful in 33s
5a2a0ad9c4
enes added 1 commit 2024-09-16 12:19:10 +00:00
Merge branch 'staging' into 196-ext-login-infinite-loading
All checks were successful
Open PR on Staging / audit_and_check (pull_request) Successful in 35s
a53914b59d
eugene approved these changes 2024-09-16 12:26:26 +00:00
enes merged commit 84c374bb2c into staging 2024-09-16 12:27:44 +00:00
enes deleted branch 196-ext-login-infinite-loading 2024-09-16 12:27:44 +00:00
Sign in to join this conversation.
No reviewers
No Milestone
No project
No Assignees
3 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: sigit/sigit.io#198
No description provided.