welpo / tabi

A modern Zola theme with search, multilingual support, optional JavaScript, a perfect Lighthouse score, and a focus on accessibility.
https://welpo.github.io/tabi/
MIT License
110 stars 34 forks source link

Galleria shortcode support #373

Open soumendrak opened 2 weeks ago

soumendrak commented 2 weeks ago

Feature Request

Summary

Galleria is a framework that simplifies creating beautiful image galleries for the web and mobile devices.

Motivation

Additional Context

welpo commented 2 weeks ago

Hey!

If you take a look at the shortcode, it does very little:

<div class="galleria mb-6" style="height: 450px">{{body | safe}}</div>

It creates a div with two classes and just puts whatever you put inside the shortcode within the div.

Setting galleria.enabled on the config loads some CSS and three JS files.

The heavy lifting is being done by the configuration setting, rather than the shortcode (you could skip the shortcode and just create a div with a galleria class).

I try to avoid JavaScript unless strictly necessary. It seems pure HTML+CSS galleries are possible: https://freefrontend.com/css-gallery/ and https://lubna.dev/articles/create-css-only-image-gallery/, for example.

Would any of the HTML+CSS options work for you? Is there something that Galleria has that the other options are missing?

soumendrak commented 2 weeks ago

@welpo Thanks for the links. If you have to implement one for Tabi, which one will you go with?

soumendrak commented 2 weeks ago

I went with a type of vanilla Zola based gallery support.

welpo commented 1 week ago

Nice! That looks pretty good.

I'll keep the issue open, as I'd like to add some sort of gallery feature to tabi. I won't have time to look into it for a while, though.