[wp-trac] [WordPress Trac] #26504: Semantic elements for non-link links
WordPress Trac
noreply at wordpress.org
Sat Jan 31 16:07:27 UTC 2015
#26504: Semantic elements for non-link links
----------------------------+--------------------------------
Reporter: GaryJ | Owner:
Type: defect (bug) | Status: closed
Priority: normal | Milestone:
Component: Administration | Version: 3.8
Severity: normal | Resolution: invalid
Keywords: close | Focuses: ui, accessibility
----------------------------+--------------------------------
Changes (by afercia):
* focuses: accessibility => ui, accessibility
Comment:
Divs, spans that behave like buttons should be buttons for sure but
thinking about links, as I see it we have two different cases:
- links that should be buttons and already look like buttons
- links that should be buttons but current design choices want to look
like links
Ideally, we should ''serve all users the same content'' and just change
them in buttons, for example:
[[Image(https://cldup.com/Aqe453FDmO.png)]]
Or, to keep the current visual, add to the second ones an ARIA
`role="button"`. Visually, they will look like links but their semantics
would be "button". Worth nothing screen readers won't list them as links
and they will announce them as (based on the example below):
> Cancel button
[[Image(https://cldup.com/Lkjd26iIXD.png)]]
BTW this would work just for screen reader users. We would end up serving
content with different semantics to different users. Not sure this is a
good thing, fair way to say I'm pretty convinced it would be bad.
A third way could be trying to "fake" buttons with CSS to make them look
like links, trying to rebuild hover/focus states. I'm not a big fan of
this and not even sure it can be done.
Any thoughts and feedback more than welcome, especially from UI and design
people. The functional part is clear, we need UI feedback :)
--
Ticket URL: <https://core.trac.wordpress.org/ticket/26504#comment:11>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list