From f089ba2435eb4a54ab4e6b2c20d91d0c9f872a2d Mon Sep 17 00:00:00 2001 From: SayaAndy Date: Mon, 18 Aug 2025 17:01:53 +0700 Subject: refactor: more line height in gallery captions feat: fixate gallery divs to viewport measures feat: make thumbnails square feat: remove recreating gallery on window resize --- internal/lightgallery/html_renderer.go | 20 +++++--------------- 1 file changed, 5 insertions(+), 15 deletions(-) (limited to 'internal') diff --git a/internal/lightgallery/html_renderer.go b/internal/lightgallery/html_renderer.go index 7ecad44..849759e 100644 --- a/internal/lightgallery/html_renderer.go +++ b/internal/lightgallery/html_renderer.go @@ -83,15 +83,15 @@ func (r *LightGalleryHTMLRenderer) renderLightGallery(w util.BufWriter, source [ thumb: "https://f003.backblazeb2.com/file/sayana-photos/webp-320p/%s.webp", subHtml: `+"`"+``+"`"+` }`, img.URL, img.URL, util.EscapeHTML(captionHTML), imageUrlWithoutExt, imageUrlWithoutExt, imageUrlWithoutExt, imageUrlWithoutExt, imageUrlWithoutExt, imageUrlWithoutExt, captionHTML, dayDate.Format("2006-01-02 15:04:05 -07:00"))) } w.WriteString(fmt.Sprintf(` `, galleryID, galleryID, strings.Join(dynamicElements, ","), galleryID, galleryID, galleryID, galleryID, galleryID, galleryID)) +document.addEventListener('DOMContentLoaded', createLightGallery%s); +`, galleryID, galleryID, strings.Join(dynamicElements, ","), galleryID)) } return ast.WalkContinue, nil -- cgit v1.3.1+13