freelawproject / courtlistener

A fully-searchable and accessible archive of court data including growing repositories of opinions, oral arguments, judges, judicial financial records, and federal filings.
https://www.courtlistener.com
Other
550 stars 151 forks source link

Add a spinner to create an alert modal #4640

Open mlissner opened 3 weeks ago

mlissner commented 3 weeks ago

When you create a search alert by clicking the little bell, it pops up a modal, but before the modal loads, we do an API call to figure out how many results the alert would have per 100 days.

This works fine except when the search engine is busy, in which case the modal half pops up and then you have to wait a while until the count come back and it pops up completely.

This should be tweaked so that the experience is better. The modal should pop up entirely, and there should be a spinner showing the user that something is happening.

Then, if we can make the alert (it's not too many results), we should show the form, or if not, we should show the error.