Created
May 31, 2017 12:35
-
-
Save kizu/79a424d82f4a5b93b0241e4bc81ad80d to your computer and use it in GitHub Desktop.
This should work when you have the button in focus and press space on keyboard
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* This should work when you have the button in focus and press space on keyboard */ | |
/* See https://html.spec.whatwg.org/multipage/scripting.html#selector-active */ | |
/* Firefox currently won't behave properly there! */ | |
button:active { | |
background: lime; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<button type="button">Press me using keyboard in Fx</button> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// alert('Hello world!'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{"view":"split","fontsize":"100","seethrough":"","prefixfree":"1","page":"html"} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment