Jieiku / abridge

Fast & Lightweight Zola Theme
https://abridge.pages.dev/
MIT License
158 stars 44 forks source link

Aligining images #180

Closed gtheys closed 1 month ago

gtheys commented 1 month ago

What is the best way to align pictures in your post? For example, center them. Or even float the left or right from your text?

Jieiku commented 1 month ago

Abridge has an img shortcode which accepts a class argument: https://abridge.pages.dev/overview-images/

You could specify a class when using the img shortcode, and you could add any manner of classes to the scss extra file:

https://github.com/Jieiku/abridge/blob/master/COPY-TO-ROOT-SASS/_extra.scss

This question or request has not come up before but I think it is common use for enough people that it should probably be added to abridge directly and update the example content to showcase it.

I would probably end up adding the extra classes to the modifiers section:

https://github.com/Jieiku/abridge/blob/c36fd6cca1070a671084ea0701ee783b3a97df2b/sass/abridge.scss#L1401

Once I get a little free time I will add the additional classes.

Jieiku commented 1 month ago

This is completed: https://github.com/Jieiku/abridge/commit/4dab5b9538f76cd56f53e6a68f34f505234e30ed

Hopefully that covers all the use cases you were after but if not then let me know.

gtheys commented 1 month ago

I see you even added the left and right float. I'm a backend developer I'm just llm'ing myself through this frontend stuff :)

Jieiku commented 1 month ago

yes, and the one to center images, the class is ci (short for center image)