Replies: 2 comments 4 replies
-
|
Lightbox is a JavaScript library which has some features. Did you search for image gallery in the discussions? There are several examples/approaches to make galleries using custom listings. |
Beta Was this translation helpful? Give feedback.
-
|
Important Accessibility: To improve accessibility, please add alternative text to your screenshots. This helps all users, including those using screen readers, to understand the context of the images. A brief description can make a big difference! See Good Alt Text, Bad Alt Text — Making Your Content Perceivable. Important Accessibility: For better accessibility, please ensure link text is descriptive and meaningful rather than using generic terms such as "here". This helps all users understand the link's destination. See Writing meaningful link text (WCAG). |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Description
I would like to make an image gallery with sortable (with date, rating, etc) and filterable (with tags) images using the inbuilt Lightbox Figures.
Right now, I have a basic image gallery as described at the wiki and I used this as a reference too. Doing this, the lightbox image is clickable to expand and the lightbox preview can include a caption (which I want to use).
What I'd like is to be able to at the top of the page add a "sort" button, to sort by some metadata I can personally define about the image - this may be a date, or a rating out of 10 for example. I'd also like to have some "category"/"tag" buttons and I can include images in multiple categories, so that I can select and deselect which images are displayed by clicking a category to show/hide it.
I was able to find this post by Matt Crump describing an implementation of an image gallery of categories by making each image in a listing with its own qmd file which can include categories explicitly. But, if I click an image on their website, it will take me to the html page corresponding to that individual image as opposed to a lightbox preview on the gallery page (which is what I'd want). Also, using this approach I can only view images in a single "category" at a time. For example, I might have images with tags "Red, Green, Blue, 2k, 4k" and I'd want to be able to select only green images that were 2k.
I think, it's probably possible to do this by writing a lot of custom javascript myself, but I was wondering if there'd be a simpler way to approach this, like using an existing library, or extending quarto listings. Here's a basic mockup of what I'd like to do:
Beta Was this translation helpful? Give feedback.
All reactions