Description
See the following thread in www-svg: https://lists.w3.org/Archives/Public/www-svg/2016Aug/0000.html
I asked there why groups were not allowed in <clipPath>
elements.
Currently browser behaviour is mixed (see test https://jsfiddle.net/g9p82y7c/):
Chrome: clip path succeeds but any groups are ignored
Edge: clip path succeeds but any groups are ignored
Safari (7.1): clip path succeeds but any groups are ignored
IE 11: clip path works including groups
Firefox: clip path fails
Firefox originally allowed groups, but that was "fixed" to bring it in line with the spec.
There are useful use cases for allowing groups:
- Allow existing content to easily be converted to a clipPath without having to be rearranged
- Easily convert a userSpaceOnUse clippath to an objectBoundingBox one.
The original reason for the restriction is unclear, but if there are no strong technical reasons to prevent it, it would be desirable to ease this restriction.
I offer no opinion on whether <svg>
etc should be also be allowed.