Referencing in-page SVG in Chrome

前端 未结 2 1246
忘掉有多难
忘掉有多难 2021-01-27 20:56

Interesting question for someone. I\'m trying to apply an SVG filter to an image loaded in the page using the following markup:




        
2条回答
  •  北海茫月
    2021-01-27 21:43

    Nevermind, turns out the filter: url() syntax isn't webkit-friendly, despite what I'd read elsewhere.

    Instead, for this particular scenario you need to use the CSS rule:

    -webkit-filter: grayscale(100%);

提交回复
热议问题