Y
Hacker News
new
|
ask
|
show
|
jobs
by
KwanEsq
3155 days ago
You'd need [required] instead of [minlength] for :valid to work. The other option is :placeholder-shown, to style no-input normally, but it's newer and not as supported.
1 comments
vilmosi
3155 days ago
I wonder if the good old input[value=""] would work. Probably not if you have jQuery.
link
bzbarsky
3155 days ago
No, because that matches on the HTML attribute (aka the defaultValue property in JS), not on the current value of the input.
link