-
Notifications
You must be signed in to change notification settings - Fork 835
Forms: Fix loading state to prevent empty state flash #45379
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
base: trunk
Are you sure you want to change the base?
Conversation
Prevents empty state flash by showing loading spinner when data hasn't resolved yet. Related: #45339
Thank you for your PR! When contributing to Jetpack, we have a few suggestions that can help us test and review your patch:
This comment will be updated as you work on your PR and make changes. If you think that some of those checks are not needed for your PR, please explain why you think so. Thanks for cooperation 🤖 🔴 Action required: Please include detailed testing steps, explaining how to test your change, like so:
🔴 Action required: We would recommend that you add a section to the PR description to specify whether this PR includes any changes to data or privacy, like so:
Follow this PR Review Process:
If you have questions about anything, reach out in #jetpack-developers for guidance! |
Are you an Automattician? Please test your changes on all WordPress.com environments to help mitigate accidental explosions.
Interested in more tips and information?
|
Code Coverage SummaryCannot generate coverage summary while tests are failing. 🤐 Please fix the tests, or re-run the Code coverage job if it was something being flaky. |
records, | ||
isLoadingData: | ||
isLoadingRecordsData || isLoadingInboxData || isLoadingSpamData || isLoadingTrashData, | ||
isLoadingData, |
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.
Is there anything I need to do to see/duplicate the 'flash' issue? I'd like to confirm the issue before testing the fix, but I don't typically see a flash when the form responses page loads.
Summary
Improves loading state logic to show spinner immediately when data hasn't resolved yet, preventing empty state flash before data loads.
Changes
isResolving
to!rawRecords?.length && !hasResolved
UX Impact
Related
Main PR: #45339