expose placeholder object attribute for HTML placeholder
Categories
(Core :: Disability Access APIs, defect, P3)
Tracking
()
Tracking | Status | |
---|---|---|
firefox67 | --- | fixed |
People
(Reporter: surkov, Assigned: MarcoZ)
References
(Blocks 1 open bug)
Details
(Keywords: good-first-bug)
Attachments
(1 file)
Comment 1•8 years ago
|
||
Reporter | ||
Comment 2•8 years ago
|
||
Comment 3•8 years ago
|
||
Comment 4•8 years ago
|
||
Comment 5•7 years ago
|
||
Reporter | ||
Updated•7 years ago
|
Reporter | ||
Comment 6•7 years ago
|
||
Comment 7•7 years ago
|
||
Reporter | ||
Updated•7 years ago
|
Comment 9•6 years ago
•
|
||
Noted that in Firefox no iA2 placeholder attribute is exposed for elements with a placeholder HTML attribute, but is exposed for aria-placeholder. This means that unless the developer doubles up placeholder and aria-placeholder then the HTML placeholder text is not announced by SR's. Also note it is (HTML placeholder) exposed correctly in chrome and thus works as expected.
test case: https://s.codepen.io/stevef/debug/exjvgW
Suggest this needs fixing pronto :-)
Also note that in chrome's implementation HTML placeholder overrides aria-placeholder value,when both are present, which I think is correct?
Assignee | ||
Comment 10•6 years ago
|
||
Taking this bug.
Joanie, I don't see anywhere in our code where we explicitly mark placeholder-text somewhere. Is there some magic I am missing?
I will be following Chrome's path here:
- If both a label and placeholder are used, and they are different from one another, the placeholder attribute will be exposed.
- if they are identical, it will not.
- Same if no other labeling is present: The placeholder will become the acc name, and no placeholder attribute will be exposed.
Comment 11•6 years ago
|
||
(In reply to Marco Zehe (:MarcoZ) from comment #10)
Joanie, I don't see anywhere in our code where we explicitly mark placeholder-text somewhere. Is there some magic I am missing?
I'm not sure what you're asking, so I'll try to address all possibilities. :)
If you mean the ARIA attribute, anything prefixed with "aria-" (e.g. aria-foo="bar"), Gecko turns that into an object attribute (name: "foo", value: "bar"). It does this unconditionally, but I forget where in the Gecko code this occurs.
"placeholder-text" instead of "placeholder" will of course be a slight twist on things. It's not being done for the ARIA property at the moment -- in Gecko anyway. It would be nice (and compatible with what's in Core-AAM, and consistent with WebKitGtk, and also with Gtk+) to have this special-cased at least on my platform. Then, having done so, please also expose HTML's placeholder attribute in the same fashion.
I hope I addressed your question.
Regarding:
I will be following Chrome's path here:
- If both a label and placeholder are used, and they are different from one another, the placeholder attribute will be exposed.
- if they are identical, it will not.
- Same if no other labeling is present: The placeholder will become the acc name, and no placeholder attribute will be exposed.
If that's what is dictated by AccName + HTML-AAM, great. (I'm still waking up and haven't looked yet. But if it's not, then please do what is dictated by AccName + HTML-AAM.
Steve: Could you please save me the time and tell me if what Marco proposes is what your spec dictates regarding placeholder exposure through a name?
Comment 12•6 years ago
|
||
If that's what is dictated by AccName + HTML-AAM, great. (I'm still waking up and haven't looked yet. But if it's not, then please do what is dictated by AccName + HTML-AAM.
its not currently, but it was, as it was decided that placeholder would not contribute to accessible name calculation, but at the time some implementers disagreed with removing as would leave some inputs in wild without accessible name. I tend to agree and think we should add back in the HTML-AAM.
Comment 13•6 years ago
|
||
Thanks Steve. I also think we want interoperability between ARIA's placeholder and HTML's placeholder. Therefore, could you please file an issue against the AccName spec so that the ARIA Working Group can discuss this issue?
Assignee | ||
Comment 14•6 years ago
|
||
FWIW, Jamie and I also think that it should be put back in, since it makes sure that more inputs in the wild get a name. FWIW, in Firefox, placeholder is the absolutely last resort for the name calc right now, after really everything else failed.
Assignee | ||
Comment 15•6 years ago
|
||
(In reply to Joanmarie Diggs from comment #11)
"placeholder-text" instead of "placeholder" will of course be a slight twist on things. It's not being done for the ARIA property at the moment -- in Gecko anyway. It would be nice (and compatible with what's in Core-AAM, and consistent with WebKitGtk, and also with Gtk+) to have this special-cased at least on my platform. Then, having done so, please also expose HTML's placeholder attribute in the same fashion.
I just put a hack into the two places where property sets get converted to arrays to rewrite placeholder as placeholder-text for ATK. Thanks for the clarification!
Assignee | ||
Comment 16•6 years ago
|
||
The appropriate case is when placeholder is not used as the absolutely last fallback for the accessible name, and the input is not labeled by the same text as in the placeholder attribute itself. So a label and the placeholder text must be different for the object attribute to be exposed.
In addition, for ATK, placeholder is being renamed to placeholder-text to comply with the platform specification.
Comment 17•6 years ago
|
||
Comment 18•6 years ago
|
||
bugherder |
Description
•