Timeline for Can I have an onclick effect in CSS?
Current License: CC BY-SA 4.0
6 events
| when toggle format | what | by | license | comment | |
|---|---|---|---|---|---|
| May 4, 2023 at 7:40 | comment | added | Rakis Friski | this is works for me, I tried using :active and :hover for custom dropdown and while using @TylerH answer can help, but if you doesn't want to add any html you can use this solution instead | |
| Apr 29, 2022 at 15:09 | history | edited | Blake Plumb | CC BY-SA 4.0 |
jsfiddle no longer works. Not needed anymore with latest edit.
|
| Apr 29, 2022 at 11:54 | history | edited | Barremian | CC BY-SA 4.0 |
Replace markdown with code snippet, replace obsolete image source, replace jsfiddle link
|
| Feb 28, 2018 at 10:33 | comment | added | Stefan Paul Noack |
this works reasonably well! when you use tabindex=-1 the item is still focusable, but only by mouse, not keyboard, which is better in this case. you can also use an outline:0 style to remove the blue border when focused
|
|
| Jun 6, 2014 at 12:30 | review | Suggested edits | |||
| Jun 6, 2014 at 12:31 | |||||
| Jan 18, 2014 at 6:20 | history | answered | Blake Plumb | CC BY-SA 3.0 |