Phuedx has uploaded a new change for review. https://gerrit.wikimedia.org/r/117174
Change subject: Focus the primary button when the CTA is shown ...................................................................... Focus the primary button when the CTA is shown Give the primary and secondary buttons a tab index of 0 so that they enter into the DOM tab flow [0]. Additionally, give the buttons an ARIA role of "button". Finally, focus the primary button when the CTA is shown, now that the buttons are programmatically focusable. [0] http://snook.ca/archives/accessibility_and_usability/elements_focusable_with_tabindex Bug: 62256 Change-Id: I323c5958b512ab59107cfd56204d1fc5a7d57f7c --- M resources/ext.gettingstarted.return.js 1 file changed, 4 insertions(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/GettingStarted refs/changes/74/117174/1 diff --git a/resources/ext.gettingstarted.return.js b/resources/ext.gettingstarted.return.js index 6392e30..0a4df06 100644 --- a/resources/ext.gettingstarted.return.js +++ b/resources/ext.gettingstarted.return.js @@ -109,7 +109,9 @@ $btn = $( '<div> ').attr( { id: spec.id, - 'class': klass + 'class': klass, + 'aria-role': 'button', + tabIndex: 0 } ).click( function ( evt ) { evt.stopPropagation(); closeDialog(); @@ -321,6 +323,7 @@ function showDialog() { var $body = $( document.body ); $body.append( $overlay ); + $dialog.find( '.mw-ui-button.mw-ui-primary' ).focus(); } function removeDialog() { -- To view, visit https://gerrit.wikimedia.org/r/117174 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I323c5958b512ab59107cfd56204d1fc5a7d57f7c Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/GettingStarted Gerrit-Branch: master Gerrit-Owner: Phuedx <g...@samsmith.io> _______________________________________________ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits