Completely remove the other image gallery themes. I now have: image galleries, with lightboxes, and captions, with links in them (and to Hugo pages), with full images lazy-loaded, with all thumbnails auto-generated, and the ability to do this on both individual images *and* with globbing, from page resources, from this page or any specified one. See cavelab_notes.txt. It also has the ability to use Exif data of the photo - if I preprocess it into a JSON file. Known issues: - The theme header/footer are now being overridden. I am working to fix this first. - I am missing some kind of fonts/images needed for the lightbox to show up properly.
9 lines
409 B
HTML
9 lines
409 B
HTML
<!-- From https://blog.cavelab.dev/2021/04/photo-gallery-posts/ -->
|
|
|
|
{{- if and (eq .Type "photos") (eq .Kind "page") -}}
|
|
<script src="{{ (resources.Get "assets/lightgallery.min.js" | fingerprint).Permalink }}"></script>
|
|
<script>lightGallery(document.getElementById('lightgallery'), {selector: '.photo-item'});</script>
|
|
{{- end -}}
|
|
|
|
<!-- lightgallery is: https://github.com/sachinchoolur/lightGallery -->
|