This would work at server level, so it is a yes/no thing.
We would need to repeat this code for each icon we want to change, but the good side is that it will work no matter what icon set is chosen. They are always replaced.
For each icon, we need the name of the file. Then, to replace the file for documents, we use:
For folders, it would be img[src*="folder_on"]
and so on.