# Photo gallery

https://docs.kleaver.ie/modules/gallery/

The owner's photos: {{gallery.items}} draws a .gallery grid from client.json gallery (a list of image and an optional caption). A photo is never a file the owner hands the site: the portal resizes it in their browser to 480, 800 and 1200 px wide (a phone photo of 5 MB becomes about 300 KB), the server checks every file by its bytes (a JPEG, PNG or WebP of a sensible size, not animated), cuts out all hidden data such as the location, and keeps each size once. Every photo needs a description (alt, at least 5 characters). The build fetches only the photos the content names, writes them to assets/uploads/ with srcset, sizes, width, height and loading="lazy", and stops (leaving the live site alone) if one is missing. Each account keeps up to 40 photos by default; staff raise it in the account settings (more storage can be bought).

| Field | What it is for | Required | Limits |
| --- | --- | --- | --- |
| Photo |  | Yes | a photo, with a description of at least 5 characters |
| Caption (optional) |  | No | up to 80 characters |
