SVGs have additional pointer-events properties (#tilPost)

Today I came across this example about certain things you can do with pointer-events in CSS.
.foo {
pointer-events: visiblePainted;
}

visiblePainted is something I haven’t seen before and it turns out that SVGs several ot…


This content originally appeared on Stefan Judis Web Development and was authored by Stefan Judis

Today I came across this example about certain things you can do with pointer-events in CSS.

.foo {
  pointer-events: visiblePainted;        
}

visiblePainted is something I haven't seen before and it turns out that SVGs several other values for the pointer-events property:

  • visiblePainted
  • visibleFill
  • visibleStroke
  • visible
  • painted
  • fill
  • stroke
  • all

You can control very granular how elements in an SVG should behave and it's not bound to the typical "web development boxes". If you want to read more MDN has you covered. :)


Reply to Stefan


This content originally appeared on Stefan Judis Web Development and was authored by Stefan Judis


Print Share Comment Cite Upload Translate
APA
Stefan Judis | Sciencx (2023-01-27T01:30:02+00:00) » SVGs have additional pointer-events properties (#tilPost). Retrieved from https://www.scien.cx/2018/08/01/svgs-have-additional-pointer-events-properties-tilpost/.
MLA
" » SVGs have additional pointer-events properties (#tilPost)." Stefan Judis | Sciencx - Wednesday August 1, 2018, https://www.scien.cx/2018/08/01/svgs-have-additional-pointer-events-properties-tilpost/
HARVARD
Stefan Judis | Sciencx Wednesday August 1, 2018 » SVGs have additional pointer-events properties (#tilPost)., viewed 2023-01-27T01:30:02+00:00,<https://www.scien.cx/2018/08/01/svgs-have-additional-pointer-events-properties-tilpost/>
VANCOUVER
Stefan Judis | Sciencx - » SVGs have additional pointer-events properties (#tilPost). [Internet]. [Accessed 2023-01-27T01:30:02+00:00]. Available from: https://www.scien.cx/2018/08/01/svgs-have-additional-pointer-events-properties-tilpost/
CHICAGO
" » SVGs have additional pointer-events properties (#tilPost)." Stefan Judis | Sciencx - Accessed 2023-01-27T01:30:02+00:00. https://www.scien.cx/2018/08/01/svgs-have-additional-pointer-events-properties-tilpost/
IEEE
" » SVGs have additional pointer-events properties (#tilPost)." Stefan Judis | Sciencx [Online]. Available: https://www.scien.cx/2018/08/01/svgs-have-additional-pointer-events-properties-tilpost/. [Accessed: 2023-01-27T01:30:02+00:00]
rf:citation
» SVGs have additional pointer-events properties (#tilPost) | Stefan Judis | Sciencx | https://www.scien.cx/2018/08/01/svgs-have-additional-pointer-events-properties-tilpost/ | 2023-01-27T01:30:02+00:00
https://github.com/addpipe/simple-recorderjs-demo