? ? Pending

User tests: Successful: Unsuccessful:

avatar tarot-ray
tarot-ray
25 Feb 2019

For A11Y reasons, this should be a button tag, not a styled anchor tag.

Pull Request for Issue # .

Summary of Changes

'Cancel' button is changed to a button tag from an anchor tag, to improved A11Y

Testing Instructions

Check that the 'Cancel' button is seen correctly by a screenreader.

Expected result

Improved A11Y.

Actual result

Documentation Changes Required

avatar tarot-ray tarot-ray - open - 25 Feb 2019
avatar tarot-ray tarot-ray - change - 25 Feb 2019
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 25 Feb 2019
Category Front End com_users
avatar SharkyKZ
SharkyKZ - comment - 25 Feb 2019

This doesn't work. Button with type="button" needs some JS code to do anything. href is not a valid attribute for element button. If this really needs to be a button it should submit the form with cancel task.

avatar infograf768 infograf768 - change - 25 Feb 2019
Title
[4.0][a11y] 'Cancel' button changes from an anchor tag to a button tag
[4.0][a11y] 'Cancel' button changes from an anchor tag to a button tag (profile edit)
avatar infograf768 infograf768 - edited - 25 Feb 2019
avatar wilsonge wilsonge - test_item - 27 Feb 2019 - Tested unsuccessfully
avatar wilsonge
wilsonge - comment - 27 Feb 2019

I have tested this item ? unsuccessfully on 9ce88b6


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/24007.

avatar tarot-ray tarot-ray - change - 27 Feb 2019
Labels Added: ?
avatar wilsonge
wilsonge - comment - 27 Feb 2019

You still need to address the comments from @SharkyKZ

avatar wilsonge wilsonge - test_item - 27 Feb 2019 - Tested successfully
avatar wilsonge
wilsonge - comment - 27 Feb 2019

I have tested this item successfully on 0b3c29f


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/24007.

avatar wilsonge
wilsonge - comment - 27 Feb 2019

@tarot-ray almost there - in the latest commit you've accidentally removed the classes again :)

avatar zwiastunsw
zwiastunsw - comment - 27 Feb 2019

@tarot-ray: Add: class="btn btn-danger"

avatar tarot-ray
tarot-ray - comment - 27 Feb 2019

So, further changes have been made to the PR to make the line absolutely correct and perfectly A11Y compatible. Please, review.

avatar zwiastunsw zwiastunsw - test_item - 27 Feb 2019 - Tested successfully
avatar zwiastunsw
zwiastunsw - comment - 27 Feb 2019

I have tested this item successfully on 74c891e


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/24007.

avatar zwiastunsw
zwiastunsw - comment - 27 Feb 2019

I have tested this item successfully on 74c891e


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/24007.

avatar wilsonge
wilsonge - comment - 27 Feb 2019

LGTM!

avatar wilsonge wilsonge - test_item - 27 Feb 2019 - Tested successfully
avatar wilsonge
wilsonge - comment - 27 Feb 2019

I have tested this item successfully on 30dd62a


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/24007.

avatar wilsonge wilsonge - change - 27 Feb 2019
Status Pending Ready to Commit
avatar wilsonge
wilsonge - comment - 27 Feb 2019

Just whitespace changes between the last two tests so RTC


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/24007.

avatar wilsonge wilsonge - alter_testresult - 27 Feb 2019 - zwiastunsw: Tested successfully
avatar SharkyKZ
SharkyKZ - comment - 27 Feb 2019

What exactly is the point of changing anchor to a button that does exactly the same but with JS dependency?

avatar wilsonge
wilsonge - comment - 27 Feb 2019

@zwiastunsw Actually in this specific case thinking about it - I think a link was the correct choice because this is a redirect to another page. From http://web-accessibility.carnegiemuseums.org/content/buttons/

Navigation: If you want a user to navigate to a new page or to a different target on the same page, use an anchor element <a>.

Basically buttons should be used if you're doing stuff on the same page and links for moving to another page

avatar zwiastunsw
zwiastunsw - comment - 27 Feb 2019

@SharkyKZ , @wilsonge :
It's a bit more complicated. In this case, Cancel will actually redirect to another page. But the essence of this control is to cancel the action and not to move user to another page.
In this and other similar cases, Cancel cancels actions you have performed.
The command also speaks: Cancel, not Go to.
This is not just a tag problem. If you use a tag, make it look like a link and not like a button. Because it's confusing for keyboard users. I run the link with the Enter key, the button I run with the Enter or Space keys. If you activating link with the spacebar causes the page to scroll and not running the link.

avatar infograf768 infograf768 - change - 28 Feb 2019
Labels Added: ?
avatar SharkyKZ
SharkyKZ - comment - 4 Mar 2019

See #24088 for potential alternative please.

avatar franz-wohlkoenig
franz-wohlkoenig - comment - 5 Mar 2019

@wilsonge can this PR be closed?

avatar wilsonge
wilsonge - comment - 21 Mar 2019

I've merged #24088 so closing this

avatar wilsonge wilsonge - change - 21 Mar 2019
Status Ready to Commit Closed
Closed_Date 0000-00-00 00:00:00 2019-03-21 13:01:07
Closed_By wilsonge
avatar wilsonge wilsonge - close - 21 Mar 2019

Add a Comment

Login with GitHub to post a comment