GH Issue 1186: Show validation indicator whenever validation disables the submit buttons#1166
Open
labkey-martyp wants to merge 1 commit into
Open
GH Issue 1186: Show validation indicator whenever validation disables the submit buttons#1166labkey-martyp wants to merge 1 commit into
labkey-martyp wants to merge 1 commit into
Conversation
… the submit buttons The Validating... indicator added with the submit-button disabling relied solely on the 'validationstart' event, which only fires when the in-flight validation request count transitions from 0 to 1. That transition can happen during initial form load, where the indicator is deliberately suppressed, and it does not fire again for validations queued behind those requests — leaving the buttons disabled with no indicator. Show the indicator from 'beforevalidation' (the same event that disables the buttons) so the two stay in sync. Also clear the indicator whenever the buttons are recalculated with no requests in flight, since a validate cycle that produces no commands sends no requests and never fires 'validationcomplete'.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Rationale
GH Issue 1186. The Validating... indicator added in the original submit-button work relied solely on the 'validationstart' event, which only fires when the in-flight validation request count transitions from 0 to 1. That transition can happen during initial form load, where the indicator is deliberately suppressed, and it does not fire again for validations queued behind those still-pending requests — leaving the submit buttons disabled with no indicator.
Related Pull Requests
Changes