I'm using a SVG spritesheet for icons. I'd like to do a color-change on :hover/:active. The only way (I've found) to change an SVG's color is if the SVG data is inline. There's a nice script to convert an external .svg into inline SVG code:
How to change color of SVG image using CSS (jQuery SVG image replacement)?
but I don't think it will work with a spritesheet, because every sprite on the page would be injected with the paths for the entire spritesheet, rather than just the 1 that particular sprite needs to display.
Is there a way to extract a specific part (sprite) of the spritesheet's xml to put into the HTML markup, based on a class (or something else)? My only thought is to manually break up the spritesheet, put each sprite path-string into an array/object, and use js (maybe Raphael) to write the inline markup and set up the hover colors; but I'm not sure what kind of overhead that would add, or if it's a really convoluted way of doing something that shouldn't be.