EVERSE-ResearchSoftware / EVERSE-ResearchSoftware.github.io

EVERSE Webiste
https://everse.software/
1 stars 5 forks source link

Image optimisation with SVG images exempt #12

Open graeme-a-stewart opened 3 months ago

graeme-a-stewart commented 3 months ago

We had to disable the image optimisation (disableImageOptimization: true) because SVG images cannot be rescaled.

Image handling needs to be fixed so that it doesn't try to optimise SVG image (which involves resizing and doesn't work).

graeme-a-stewart commented 3 months ago

I have had some partial success here. In figure.html change L27 from

          {{ if $disableImageOptimization }}

to

           {{ if or $disableImageOptimization (eq .MediaType.SubType "svg") }}

However, also the Blowfish layouts/_default/_markup/render-image.html needs to be fixed. But doing this and moving the fragment into our own layouts area isn't working - somehow the snippet is always loading from the theme. Very annoying...