-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CSS clip-path only works properly on first element in Safari 10 #27
Comments
Hi @ryanlabar! I've seen this bug in various forms before, and basically, Safari/WebKit has some general trouble mapping the coordinate system between the SVG and the HTML element the effect is applied to. Luckily, there’s a fix: applying any property that forces the affected element to render in its own compositor layer seems to make Safari snap back into getting the coordinates right, thus fixing the bug. In your example, adding e.g. |
Still relevant on Android Chrome when used on div which have background images and contains a child svg with same path as the clip-path. |
Still helps in 2022, in Ionic apps using the embedded Safari. Thanks! |
@viking2917 Glad to hear that this repo is still of use! 🙂 |
Just came here to express my appreciation for the solution ! |
Using CSS clip-path on multiple elements using the same path only displays on first element and renders strange on, or doesn't display, the proceeding elements in Safari 10.0.
See CodePen for example: http://codepen.io/ryan_labar/pen/KgLNyx
The text was updated successfully, but these errors were encountered: