this approach does not work with SVG images as I wrote in the conversation