mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-08-16 20:49:00 -04:00
Style cancel link and make it keyboard navigable
So that it looks and behaves like a normal link.
This commit is contained in:
@@ -43,7 +43,9 @@
|
||||
this.addCancelButton = function(state) {
|
||||
let $cancel = $('<a></a>')
|
||||
.html('Cancel')
|
||||
.click((event) => {
|
||||
.attr('class', 'page-footer-js-cancel')
|
||||
.attr('tabindex', '0')
|
||||
.on('click keydown', (event) => {
|
||||
event.preventDefault();
|
||||
// clear existing data
|
||||
state.$el.find('input:radio').prop('checked', false);
|
||||
|
||||
@@ -86,3 +86,21 @@
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
.page-footer-js-cancel {
|
||||
|
||||
text-decoration: underline;
|
||||
color: $govuk-blue;
|
||||
cursor: pointer;
|
||||
|
||||
&:hover {
|
||||
color: $link-hover-colour;
|
||||
}
|
||||
|
||||
&:focus,
|
||||
&:active, {
|
||||
background: $yellow;
|
||||
color: $govuk-blue;
|
||||
outline: 3px solid $yellow;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user