WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
118122
Web Inspector: AX: VoiceOver speaks all inspector search fields as 'required'
https://bugs.webkit.org/show_bug.cgi?id=118122
Summary
Web Inspector: AX: VoiceOver speaks all inspector search fields as 'required'
James Craig
Reported
2013-06-27 01:50:55 PDT
I believe this is just an oversight. These fields aren't actually required for anything and there appears to be no validation checking that relies on this property, so we could comment or remove "*.required = true;" in all occurrences to make this work better for VoiceOver. Searching 400 files for ".required" (case sensitive) /Users/jc/svnroot/WebKit/Source/WebInspectorUI/UserInterface/FilterBar.js: 32 this._inputField = document.createElement("input"); 33 this._inputField.type = "search"; 34: this._inputField.required = true; 35 this._inputField.spellcheck = false; 36 this._inputField.incremental = true; /Users/jc/svnroot/WebKit/Source/WebInspectorUI/UserInterface/ResourceSidebarPanel.js: 33 this._inputElement = document.createElement("input"); 34 this._inputElement.type = "search"; 35: this._inputElement.required = true; 36 this._inputElement.spellcheck = false; 37 this._inputElement.addEventListener("search", this._searchFieldChanged.bind(this)); /Users/jc/svnroot/WebKit/Source/WebInspectorUI/UserInterface/SearchBar.js: 36 this._searchInput = this._element.appendChild(document.createElement("input")); 37 this._searchInput.type = "search"; 38: this._searchInput.required = true; 39 this._searchInput.spellcheck = false; 40 this._searchInput.incremental = true; 3 matches across 3 files
Attachments
patch
(4.74 KB, patch)
2013-06-27 18:33 PDT
,
James Craig
no flags
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Radar WebKit Bug Importer
Comment 1
2013-06-27 01:51:10 PDT
<
rdar://problem/14287209
>
Timothy Hatcher
Comment 2
2013-06-27 03:05:03 PDT
They are marked required to allow us to style them with a white background when there is content typed into them. Otherwise they have a semi transparent background. Can we hide that from VoiceOver since this is a purely visual reason?
James Craig
Comment 3
2013-06-27 17:45:32 PDT
(In reply to
comment #2
)
> They are marked required to allow us to style them with a white background when there is content typed into them. Otherwise they have a semi transparent background.
Oh, I see the :valid pseudo-class selectors now. I think we can manage the same thing with a :not([value=""]) selector, right? I'll try it out.
> Can we hide that from VoiceOver since this is a purely visual reason?
No, for attrs with identical semantics like @required and @aria-required, the host language attribute wins if there is a conflict, so <input required aria-required="false"> is still required.
James Craig
Comment 4
2013-06-27 18:05:59 PDT
The :not([value=""]) selector doesn't work as I had hoped. Even if I set an initial empty value via el.value=""; or el.setAttribute("value","");, the attribute does not stay in sync. I thought value was a reflected attribute, but it appears the DOM attribute is just to set the default value of the WebIDL attribute.
http://www.whatwg.org/specs/web-apps/current-work/multipage/the-input-element.html#attr-input-value
James Craig
Comment 5
2013-06-27 18:20:44 PDT
The CSS4 selector :not(:placeholder-shown) is the right one to use, but WebKit does not recognize it yet (I filed
bug 118162
). I think it looks okay with the change (currently only white when focused), and it should should match the previous style (white when focused or non-empty) once WebKit supports the new selector. I'll upload a diff for review.
James Craig
Comment 6
2013-06-27 18:33:35 PDT
Created
attachment 205654
[details]
patch
WebKit Commit Bot
Comment 7
2013-06-28 18:26:20 PDT
Comment on
attachment 205654
[details]
patch Clearing flags on attachment: 205654 Committed
r152199
: <
http://trac.webkit.org/changeset/152199
>
WebKit Commit Bot
Comment 8
2013-06-28 18:26:22 PDT
All reviewed patches have been landed. Closing bug.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug