You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Apr 12, 2024. It is now read-only.
Current behavior:
When using input[type="datetime-local"] directive without required attribute then clearing input with clear button (blue cross icon) sets $valid property to true only the first time the button is clicked. Subsequent clicks do not set the property to true value anymore.
Expected / new behavior:
Clicking clear button of a control for non-required input[type="datetime-local"] directive should always set $valid property to true.
Closing as duplicate of #14740. It is partly a Chrome issue/idiosyncracy. We could work around it inside AngularJS, but you can work around it in your app too (see #14740 discussion and specific suggestions).
If anyone wants to work on a PR, they are more than welcome 😃
I'm submitting a ...
Current behavior:
When using
input[type="datetime-local"]
directive withoutrequired
attribute then clearing input with clear button (blue cross icon) sets$valid
property totrue
only the first time the button is clicked. Subsequent clicks do not set the property totrue
value anymore.Expected / new behavior:
Clicking clear button of a control for non-required
input[type="datetime-local"]
directive should always set$valid
property totrue
.Minimal reproduction of the problem with instructions:
https://plnkr.co/edit/eFypeLyTVuBi394KhKwR?p=preview
This is version of plunkr from the docs https://docs.angularjs.org/api/ng/input/input%5Bdatetime-local%5D with two modifications: initial Date object is null and attribute
required
is removed frominput[type="datetime-local"]
.myForm.input.$valid == false
myForm.input.$valid == true
myForm.input.$valid == false
myForm.input.$valid == false
<- should betrue
insteadAngularJS version: v1.6.10-build.25885+sha.c68b31c (current snapshot)
Browser: Chrome 65.0.3325.162
OS: Fedora 28
The text was updated successfully, but these errors were encountered: