Skip to content
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

V5 form validations #30170

Closed
wants to merge 6 commits into from
Closed

V5 form validations #30170

wants to merge 6 commits into from

Conversation

ysds
Copy link
Member

@ysds ysds commented Feb 13, 2020

Drop feedback messages by sibling selector for V5.

There is no way to solve the #25110 and #29439 maintaining the current specification. If you are using a modern JavaScript framework, this removal of sibling selectors is not a problem, because feedback messages are almost always controlled by if directives (e.g. ng-if). Control styling with the .is-valid/.is-invalid has the same feature as v4.

Also this close #28414 and #30438.

image

Preview: https://deploy-preview-30170--twbs-bootstrap.netlify.app/docs/5.0/forms/validation/

PR for v4 is #30180

@ysds ysds requested a review from a team as a code owner February 13, 2020 16:39
@ysds ysds added this to Inbox in v5 via automation Feb 13, 2020
@mdo
Copy link
Member

mdo commented Feb 15, 2020

So with this change, there is no built-in and functional form validation in Bootstrap? Because everything would need to be controlled by another JS library or framework?

@ysds
Copy link
Member Author

ysds commented Feb 15, 2020

Does not deny the creation of new built-in JavaScript plugins. We can consider it after the alpha release.

At least, the current control by sibling selectors should be abolished.

@XhmikosR
Copy link
Member

Just keep in mind there's one snippet using inline JS to handle validation. If it's supposed just to be an example we should make it so, because currently it applies to the code.

@ysds ysds moved this from Inbox to Review in v5 Feb 19, 2020
@ysds ysds force-pushed the master-ysds-form-validations branch 2 times, most recently from bc9da6c to 54f1214 Compare March 17, 2020 15:09
@ysds
Copy link
Member Author

ysds commented Mar 17, 2020

I rebased into the master and updated the first custom JS example.

@mdo
Copy link
Member

mdo commented Jun 12, 2020

Any chance this could be rebased @ysds?

@mdo mdo force-pushed the master-ysds-form-validations branch from 54f1214 to 754362e Compare June 15, 2020 08:02
@ysds ysds requested a review from a team as a code owner June 15, 2020 08:02
@XhmikosR
Copy link
Member

I don't want to hurry this @mdo. The tooltip example doesn't look right, the feeback is always shown.

@mdo mdo added this to Inbox in v5.0.0-alpha2 via automation Jun 15, 2020
@mdo mdo removed this from Review in v5 Jun 15, 2020
@mdo mdo changed the base branch from master to main June 16, 2020 20:12
@ysds
Copy link
Member Author

ysds commented Jun 23, 2020

Sorry for being away for a while.

The tooltip example doesn't look right, the feeback is always shown.

It's intentional that the feedback tooltip examples are always visible, but what do you think it should be?

@XhmikosR
Copy link
Member

It's intentional that the feedback tooltip examples are always visible, but what do you think it should be?

I thought it was a mistake since previously they didn't show up nor in v4. If it's intentional then all good :)

@ysds
Copy link
Member Author

ysds commented Jun 23, 2020

👍 As commented on #30170 (comment), additional JS is required to toggle the display of feedback messages. I think the static sample is enough for now.

@mdo
Copy link
Member

mdo commented Aug 5, 2020

@ysds Can you confirm something here before I attempt to resolve conflicts and merge this? Are we removing all feedback elements from the examples under the ## Server side heading? Your earlier commit does that, and I may have screwed that up in my later commits.

@mdo mdo removed this from Inbox in v5.0.0-alpha2 Sep 16, 2020
@mdo
Copy link
Member

mdo commented Sep 16, 2020

Hoping this can be replaced by #31666.

@mdo mdo mentioned this pull request Sep 17, 2020
@XhmikosR
Copy link
Member

@mdo is this still valid? #31666 was closed in favor of #31953

@mdo
Copy link
Member

mdo commented Apr 5, 2021

Closing as out of date—miss you @ysds! <3

@mdo mdo closed this Apr 5, 2021
@mdo mdo deleted the master-ysds-form-validations branch April 5, 2021 03:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Validation feedback/tooltips lack association with their form control
3 participants