theNewDynamic / gohugo-theme-ananke

Ananke: A theme for Hugo Sites
https://ananke-theme.netlify.app
MIT License
1.16k stars 1.16k forks source link

Make background image responsive #362

Open peter-jerry-ye opened 4 years ago

peter-jerry-ye commented 4 years ago

There's only one url for each image in css. Is it possible to add media query for responsive images? Does it require a standalone css file? Thanks.

bennoOoOOooOoOoo commented 3 years ago

Need this :) me too, me too :D

JonathanDoughty commented 2 years ago

I would really like to see this too, any more recent thoughts?

I hacked together support for media queries for the background/cover image as well as in summary-with-images in an earlier version of ananke. I used an image shortcode as a replacement for hugo's figure too. Now I am struggling to work off a couple years technical debt from not having kept up with ananke/hugo changes in the meantime. That debt has me marooned in hugo 92 and an ananke from around 2.6.7.

Some built-in ananke support for these would go a long way to making ananke truly 'responsive', show off some of hugo's great image processing, and maybe get this hacker out of the business of fumbling his way through go/hugo when I am sure there are more knowledgeable ways of doing these.

nedjo commented 2 years ago

A PR is ready for review at https://github.com/theNewDynamic/gohugo-theme-ananke/pull/540.