feat: photo/video capture-date pipeline + premium UI/UX overhaul

Backend — Photos timeline now groups by real capture date instead of upload time. New MediaMetadataService (FileLifecycleHook) extracts EXIF DateTimeOriginal from images and container creation_time from videos (mov/mp4/mkv) via nom-exif, timezone-correct (OffsetTimeOriginal), persisting captured_at so the existing media_sort_date trigger takes over. Adds POST /admin/photos/metadata/reextract to backfill existing media. Falls back to upload date when no embedded date exists.

Frontend — premium grid cards: combined metadata line (relative date · size, owner avatar when shared), custom selection checkbox with a clear checked state, uniform full-width 4:3 thumbnail tiles independent of filename length, centered file-type icons, and a hit-test fix so checkbox/star/kebab clicks reach the controls (the decorative thumbnail no longer captures pointer events). Notification messages internationalised across all 16 locales. Broader polish: design tokens, a11y/focus-visible states, brand + PWA assets.

Chore — bump semver-compatible dependencies (cargo upgrade); add nom-exif 3.6.1.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
DioCrafts
2026-06-15 00:17:17 +02:00
parent dac299fea6
commit 81a93a489b
129 changed files with 8194 additions and 2473 deletions
+58 -36
View File
@@ -7,33 +7,44 @@
body {
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
background: var(--color-bg-hover);
/* Shared brand backdrop (centralised in --brand-ambient). */
background: var(--brand-ambient);
color: var(--color-text-heading);
display: flex;
justify-content: center;
align-items: safe center;
height: auto;
min-height: 100vh;
min-height: 100dvh;
overflow: auto;
padding: 1rem;
}
.share-card {
background: var(--color-bg-surface);
border-radius: var(--radius, 12px);
box-shadow: 0 4px 24px var(--color-shadow-sm);
border-radius: var(--radius-3xl);
box-shadow: var(--shadow-xl);
padding: 2.5rem;
max-width: 480px;
width: 100%;
text-align: center;
}
.share-trust {
margin-top: 1.5rem;
display: flex;
align-items: center;
justify-content: center;
gap: var(--space-1-5);
font-size: var(--text-xs);
color: var(--color-text-faint);
}
.share-logo {
margin-bottom: 1.5rem;
}
.share-logo h1 {
font-size: 1.5rem;
font-weight: 700;
font-size: var(--text-2xl);
font-weight: var(--weight-bold);
}
.share-logo span {
color: var(--color-primary);
@@ -64,18 +75,29 @@ p.subtitle {
margin: 0 auto 1rem;
animation: spin 0.7s linear infinite;
}
@keyframes spin {
to {
transform: rotate(360deg);
}
}
/* @keyframes spin → base/animations.css (canonical, loaded via main.css). */
/* Icons */
.share-icon {
font-size: 3rem;
font-size: var(--text-6xl);
margin-bottom: 0.75rem;
}
/* Inline SVG state icons (replaced the per-OS emoji). Colour comes from the
container via stroke: currentColor. */
.share-icon svg {
width: 56px;
height: 56px;
}
#share-expired .share-icon {
color: var(--color-error-text);
}
#share-file .share-icon {
color: var(--color-accent-text);
}
/* Password form */
#password-form {
text-align: left;
@@ -83,9 +105,9 @@ p.subtitle {
#password-input {
width: 100%;
padding: 0.75rem 1rem;
font-size: 1rem;
font-size: var(--text-md);
border: 2px solid var(--color-border);
border-radius: 8px;
border-radius: var(--radius-lg);
outline: none;
background: var(--color-bg-surface);
color: var(--color-text-heading);
@@ -112,9 +134,9 @@ FIXME: use components/buttons.css ?
background: var(--color-primary);
color: var(--color-bg-surface);
border: none;
border-radius: 8px;
border-radius: var(--radius-lg);
font-size: 0.95rem;
font-weight: 600;
font-weight: var(--weight-semibold);
cursor: pointer;
text-decoration: none;
text-align: center;
@@ -193,8 +215,8 @@ body.gallery-mode .share-logo {
}
.gallery-title {
flex: 1 1 200px;
font-size: 1.25rem;
font-weight: 600;
font-size: var(--text-xl);
font-weight: var(--weight-semibold);
margin: 0;
word-break: break-word;
color: var(--color-text-heading);
@@ -213,7 +235,7 @@ body.gallery-mode .share-logo {
color: var(--color-text-heading);
font-size: 0.85rem;
padding: 0.4rem 0.85rem;
border-radius: 999px;
border-radius: var(--radius-full);
background: var(--color-bg-hover);
border: 1px solid var(--color-border);
transition: background 0.15s;
@@ -226,7 +248,7 @@ body.gallery-mode .share-logo {
display: inline-flex;
background: var(--color-bg-hover);
border: 1px solid var(--color-border);
border-radius: 999px;
border-radius: var(--radius-full);
padding: 3px;
}
.gallery-view-toggle button {
@@ -234,7 +256,7 @@ body.gallery-mode .share-logo {
border: none;
color: var(--color-text-gray);
padding: 0.35rem 0.75rem;
border-radius: 999px;
border-radius: var(--radius-full);
cursor: pointer;
font-size: 0.85rem;
display: inline-flex;
@@ -252,14 +274,14 @@ body.gallery-mode .share-logo {
align-items: center;
gap: 0.45rem;
padding: 0.55rem 1rem;
border-radius: 999px;
border-radius: var(--radius-full);
width: auto;
font-size: 0.85rem;
}
.gallery-section-title {
font-size: 0.75rem;
font-weight: 600;
font-size: var(--text-xs);
font-weight: var(--weight-semibold);
text-transform: uppercase;
letter-spacing: 0.5px;
color: var(--color-text-gray);
@@ -278,7 +300,7 @@ body.gallery-mode .share-logo {
padding: 0.75rem 0.85rem;
background: var(--color-bg-hover);
border: 1px solid var(--color-border);
border-radius: 12px;
border-radius: var(--radius-2xl);
color: var(--color-text-heading);
text-decoration: none;
transition:
@@ -296,13 +318,13 @@ body.gallery-mode .share-logo {
}
.folder-card .card-name {
font-size: 0.9rem;
font-weight: 500;
font-weight: var(--weight-medium);
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.folder-card .card-meta {
font-size: 0.75rem;
font-size: var(--text-xs);
color: var(--color-text-gray);
}
@@ -315,7 +337,7 @@ body.gallery-mode .share-logo {
display: block;
background: var(--color-bg-hover);
border: 1px solid var(--color-border);
border-radius: 12px;
border-radius: var(--radius-2xl);
color: var(--color-text-heading);
text-decoration: none;
overflow: hidden;
@@ -367,7 +389,7 @@ body.gallery-mode .share-logo {
.file-thumb .video-marker::before {
content: "▶";
color: var(--color-on-overlay);
font-size: 28px;
font-size: var(--text-3xl);
text-shadow: 0 2px 8px var(--color-overlay-shadow);
}
.file-card .card-body {
@@ -376,15 +398,15 @@ body.gallery-mode .share-logo {
}
.file-card .card-name {
font-size: 0.85rem;
font-weight: 500;
font-weight: var(--weight-medium);
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.file-card .card-meta {
font-size: 0.75rem;
font-size: var(--text-xs);
color: var(--color-text-gray);
margin-top: 2px;
margin-top: var(--space-0-5);
}
/* ── List view ───────────────────────────────────────────────── */
@@ -397,7 +419,7 @@ body[data-share-view="list"] .file-card {
gap: 0.75rem;
padding: 0.5rem 0.75rem;
margin-bottom: 0.35rem;
border-radius: 10px;
border-radius: var(--radius-xl);
}
body[data-share-view="list"] .file-card:hover {
transform: none;
@@ -407,14 +429,14 @@ body[data-share-view="list"] .file-thumb {
height: 44px;
aspect-ratio: 1 / 1;
flex: none;
border-radius: 8px;
border-radius: var(--radius-lg);
}
body[data-share-view="list"] .file-thumb .file-type-icon {
width: 24px;
height: 24px;
}
body[data-share-view="list"] .file-thumb .video-marker::before {
font-size: 14px;
font-size: var(--text-base);
}
body[data-share-view="list"] .file-card .card-body {
padding: 0;
@@ -462,7 +484,7 @@ body[data-share-view="list"] .file-card .card-body {
background: var(--color-overlay-button);
color: var(--color-on-overlay);
border: none;
border-radius: 999px;
border-radius: var(--radius-full);
padding: 0.5rem 0.85rem;
font-size: 0.85rem;
text-decoration: none;