From 5216fe419f15bab38add61084e46d052ad117aa2 Mon Sep 17 00:00:00 2001 From: SayaAndy Date: Sat, 18 Oct 2025 22:15:04 +0700 Subject: fix: disable horizontal order for masonry feat: raise width levels for columns count in gallery feat: raise width levels for thumbnails resolution --- internal/glightbox/html_renderer.go | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) (limited to 'internal') diff --git a/internal/glightbox/html_renderer.go b/internal/glightbox/html_renderer.go index 44fbd4c..9077cc4 100644 --- a/internal/glightbox/html_renderer.go +++ b/internal/glightbox/html_renderer.go @@ -113,12 +113,12 @@ func (r *GLightboxHTMLRenderer) renderGLightbox(w util.BufWriter, source []byte, - - - - - - + + + + + +

%s

%d @@ -152,8 +152,7 @@ func (r *GLightboxHTMLRenderer) renderGLightbox(w util.BufWriter, source []byte, var msnry_%s = new Masonry('.masonry-grid-%s', { itemSelector: '.grid-item-%s', columnWidth: '.grid-sizer-%s', - percentPosition: true, - horizontalOrder: true + percentPosition: true }); var imgLoad_%s_timer; -- cgit v1.3.1+13 From 7a65150afeb67ab83ac2eb34194601033e3d647d Mon Sep 17 00:00:00 2001 From: SayaAndy Date: Sat, 18 Oct 2025 22:44:19 +0700 Subject: feat: uninterruptable lightbox fix: image description taking up all the height in glightbox --- internal/glightbox/html_renderer.go | 13 ++++--------- static/input.css | 3 ++- views/pages/blog-page.html | 5 +++++ 3 files changed, 11 insertions(+), 10 deletions(-) (limited to 'internal') diff --git a/internal/glightbox/html_renderer.go b/internal/glightbox/html_renderer.go index 9077cc4..aad7984 100644 --- a/internal/glightbox/html_renderer.go +++ b/internal/glightbox/html_renderer.go @@ -110,8 +110,8 @@ func (r *GLightboxHTMLRenderer) renderGLightbox(w util.BufWriter, source []byte, anchorlessCaptionHTML := r.anchorMatchRe.ReplaceAll(captionHTML, []byte("$4")) elements = append(elements, fmt.Sprintf(` -
+ @@ -122,7 +122,7 @@ func (r *GLightboxHTMLRenderer) renderGLightbox(w util.BufWriter, source []byte,

%s

%d -
`, img.URL, galleryID, strings.Join(tagClassList, " "), galleryID, galleryID, dayDate.Format("2006-01-02 15:04:05 -07:00"), dataDescriptionAttribute, imageUrlWithoutExt, imageUrlWithoutExt, imageUrlWithoutExt, imageUrlWithoutExt, imageUrlWithoutExt, imageUrlWithoutExt, anchorlessCaptionHTML, i+1)) + `, img.URL, strings.Join(tagClassList, " "), galleryID, dayDate.Format("2006-01-02 15:04:05 -07:00"), dataDescriptionAttribute, imageUrlWithoutExt, imageUrlWithoutExt, imageUrlWithoutExt, imageUrlWithoutExt, imageUrlWithoutExt, imageUrlWithoutExt, anchorlessCaptionHTML, i+1)) if glightboxDescId != "" { elements = append(elements, fmt.Sprintf(` @@ -144,11 +144,6 @@ func (r *GLightboxHTMLRenderer) renderGLightbox(w util.BufWriter, source []byte, w.WriteString(fmt.Sprintf(` `, galleryID, galleryID, galleryID, galleryID, galleryID, galleryID, galleryID, galleryID, galleryID, galleryID, galleryID, galleryID, galleryID, galleryID, galleryID, galleryID, galleryID, galleryID, galleryID)) +`, galleryID, galleryID, galleryID, galleryID, galleryID, galleryID, galleryID, galleryID, galleryID, galleryID, galleryID, galleryID, galleryID, galleryID, galleryID, galleryID, galleryID)) } return ast.WalkContinue, nil diff --git a/static/input.css b/static/input.css index 49a5890..c308796 100644 --- a/static/input.css +++ b/static/input.css @@ -377,7 +377,7 @@ a:hover, .linklike:hover { margin-top: 0.25rem; border-radius: 0.5rem; position: absolute; - z-index: 801; + z-index: 1001; } .grid-tooltip:hover .grid-tooltip-text { @@ -495,6 +495,7 @@ a:hover, .linklike:hover { .gslide-description { flex-grow: 0; flex-shrink: 1; + flex-basis: 0; } .map-container .leaflet-container { diff --git a/views/pages/blog-page.html b/views/pages/blog-page.html index c9c9e91..77164fa 100644 --- a/views/pages/blog-page.html +++ b/views/pages/blog-page.html @@ -46,6 +46,11 @@ {{ .MapLocationY }}, {{ .MapLocationAreaMeters }} ), 1000); + + var lightbox = GLightbox({ + selector: '.glightbox', + moreLength: 0 + }); {{- end }} -- cgit v1.3.1+13