-
Notifications
You must be signed in to change notification settings - Fork 240
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(appointments): Disable the booking button while loading #5244
Conversation
Codecov ReportPatch coverage has no change and project coverage change:
Additional details and impacted files@@ Coverage Diff @@
## main #5244 +/- ##
============================================
- Coverage 22.43% 22.35% -0.09%
Complexity 373 373
============================================
Files 238 238
Lines 11589 11635 +46
Branches 2176 2261 +85
============================================
+ Hits 2600 2601 +1
- Misses 8989 9034 +45
Flags with carried forward coverage won't be shown. Click here to find out more.
☔ View full report in Codecov by Sentry. |
ea72cc9
to
8c45ea1
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's also disable the inputs and textarea above while loading
Done :) I also disabled closing of the modal whilst the submit form is loading. Finally, I would really like to display a loading spinner in the button - I've added an attempt at that here, but I would appreciate feedback. |
Here's what the spinner looks like: Screen.Recording.2023-05-27.at.08.38.41.mov |
@tcitworld @ChristophWurst anything further I can do on this PR to get it merged? Thanks! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code looks good
ideally: Also add a loading icon to the button/modal that shows the page is loading Signed-off-by: Patrick Robertson <[email protected]>
Co-authored-by: Thomas Citharel <[email protected]> Signed-off-by: Patrick Robertson <[email protected]>
Signed-off-by: Patrick Robertson <[email protected]>
Signed-off-by: Patrick Robertson <[email protected]>
Signed-off-by: Patrick Robertson <[email protected]>
Signed-off-by: Patrick Robertson <[email protected]>
@ChristophWurst - sorry to keep bugging you on this. Who should I request to review the PR (that's blocking the merge)? Thanks! |
🎉 Thanks Christoph! I hope to try and work on a few more bugs soon as well :-) |
Awesome! |
The server can take a bit of time to response after clicking the 'Book the appointment button' (see below video - might be my server/email server is slow, hence why it taskes 8+ seconds!). To improve UX and to avoid the user clicking the button multiple times, we should disable the button while loading and/or add a loading icon.
loading.mov.sm.mp4
Ideally, the code would also either replace the 'Book the appointment' text with a loading spinner, or grey out the entire popup window and add a loading icon, but that's beyond my ability 😿