To detect what element is fired, when my user clicks on an anchor or submits a form, I use that selector :
'form input[type=submit]:focus,' +
'form button[type=submit]:focus,' +
'form button:not([type]):focus,' +
'a:focus,' +
'form input[type=submit],' +
'form button[type=submit],' +
'form button:not([type])'
But it doesn't work on touch devices, how to solve it please ?
Found the solution: try to get the element by the pseudo-selector :hover
, in place of :focus