chore: production readiness audit

- Move plans/ to dev-docs/, delete unused scaffold SVGs
- Create .dockerignore, rename container to immich-folio
- Extract BackLink component and toPhotoItems() helper in page.tsx
- Add keyboard accessibility (role=button, tabIndex, onKeyDown) to PhotoGrid
- Add aria-label to Lightbox EXIF toggle
- Fix React lint: replace setState-in-effect with useState initializer
- Add rate limiting to /api/auth (brute-force protection, 10 RPM)
- Add HSTS and X-DNS-Prefetch-Control security headers
- Add Secure flag to auth cookie in production
- New unit tests: rate-limit.test.ts (5), auth.test.ts (12)
- All 47 tests pass, 0 lint errors, build clean
This commit is contained in:
ralksta
2026-02-15 11:23:51 +01:00
parent 3d71e9ffb7
commit a0ee0ff433
26 changed files with 314 additions and 786 deletions

View File

@@ -279,10 +279,12 @@
flex-direction: column;
justify-content: flex-end;
padding: 24px;
background: linear-gradient(to top,
rgba(0, 0, 0, 0.8) 0%,
rgba(0, 0, 0, 0.3) 40%,
transparent 100%);
background: linear-gradient(
to top,
rgba(0, 0, 0, 0.8) 0%,
rgba(0, 0, 0, 0.3) 40%,
transparent 100%
);
opacity: 0;
transition: opacity var(--transition-normal);
}
@@ -412,10 +414,12 @@
/* ── Loading States ───────────────────────────────── */
.skeleton {
background: linear-gradient(90deg,
var(--bg-card) 0%,
var(--bg-card-hover) 50%,
var(--bg-card) 100%);
background: linear-gradient(
90deg,
var(--bg-card) 0%,
var(--bg-card-hover) 50%,
var(--bg-card) 100%
);
background-size: 200% 100%;
animation: skeleton-shimmer 1.5s infinite;
border-radius: var(--radius-sm);
@@ -434,7 +438,9 @@
/* ── Fade-In Animations ────────────────────────────── */
.fade-in {
opacity: 0;
transition: opacity 0.6s ease, transform 0.6s ease;
transition:
opacity 0.6s ease,
transform 0.6s ease;
}
.fade-in--up {
@@ -724,7 +730,9 @@
font-weight: 400;
padding: 6px 0;
border-bottom: 1px solid transparent;
transition: border-color var(--transition-fast), color var(--transition-fast);
transition:
border-color var(--transition-fast),
color var(--transition-fast);
}
.hero__nav-link:hover {
@@ -841,4 +849,4 @@
.photo-grid__item {
padding: 6px 6px 18px;
}
}
}