change css background-image svg paint behavior on hover?
问题 I am using an svg as a background image for a button. The button needs different hover states, which are just changes to the svg fill values. Is there a clever way to make these changes to the svg which is effectively just being used as an image, or do I need to create a different svg file with a different fill color? 回答1: An another method with background-position. HTML <div class="locate"> <a href="#">lorem ipsum</a> </div> CSS .locate a { padding-left: 20px; position: relative; text