From 6e47246dbbc97821b97aa9c45352abc9c2a9aa4a Mon Sep 17 00:00:00 2001 From: Paul Buetow Date: Mon, 15 Jun 2026 13:26:28 +0300 Subject: Stats/camera pages: blurred background, album-like camera thumbs, spacing Three refinements to the stats site: - Stats and per-camera pages now get a random blurred background image (same seeded pick the album preview pages use) instead of a plain black page. Adds _stats_random_background + STATS_BLURS_DIR; falls back to black when no photos exist (e.g. isolated unit tests). - Per-camera thumbnails now behave like the main album: they link to each photo's album view page (navigation, details, EXIF tooltip) and carry the same seeded animation class, instead of linking to the raw image. render_album_pages records a photo -> "-" map (ALBUM_VIEW_PAGE_BY_PHOTO) that the camera pages read; photos with no recorded view page fall back to the image. - Spacing: the camera leaderboard rows get padding + a separator line so the long wrapping camera names are distinguishable, and the stats sections, headings, bar rows, back-link, and camera grid get moderate extra spacing so nothing looks cramped. Tests updated for the new camera-thumbnail markup and extended to assert the stats background and the album view-page links; camera.tmpl comment corrected. Co-Authored-By: Claude Opus 4.8 --- share/templates/default/camera.tmpl | 9 +++++---- share/templates/default/header.tmpl | 36 +++++++++++++++++++++++++++++++----- 2 files changed, 36 insertions(+), 9 deletions(-) (limited to 'share/templates/default') diff --git a/share/templates/default/camera.tmpl b/share/templates/default/camera.tmpl index 39ca273..2e08461 100644 --- a/share/templates/default/camera.tmpl +++ b/share/templates/default/camera.tmpl @@ -7,10 +7,11 @@ # // and footer come from the header/footer templates, which # render_camera_pages emits around this one (same pattern as stats/view/details). # -# Thumbnails link to the full-size image under photos/ rather than to a per-photo -# view page: a camera page is built outside the album's pagination loop and so -# cannot know which -.html a given photo landed on. Linking to the -# original image is the sensible derivable target (see render_camera_pages). +# Thumbnails link to each photo's album view page (navigation, details, EXIF +# tooltip) so a camera page behaves exactly like the main album. +# render_camera_pages resolves the -.html target from the map the +# album build records; a photo with no recorded view page falls back to the +# full-size image under photos/ (see render_camera_pages). cat <

${render_title_html} — ${render_camera_name_html}

diff --git a/share/templates/default/header.tmpl b/share/templates/default/header.tmpl index 6a163f9..411d106 100644 --- a/share/templates/default/header.tmpl +++ b/share/templates/default/header.tmpl @@ -98,23 +98,31 @@ cat <