Adds the portfolio page

The ten live photos in a filterable masonry grid with an accessible
lightbox, filters per shoot type kept in the URL (?shoot=), the shared
Instagram block, and an indexed page with image gallery structured data
and its own preview image. Soorten fotoshoots now only links to the
portfolio for shoot types that have photos there.

The filter bar stays on one row, so the web font loading no longer
shifts the photos below it, and no photo loads before the page has: the
grid fades in, so loading its photos early only delayed the fonts and the
intro text.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-10-27 19:05:13 +01:00
co-authored by Claude Opus 5.5
parent 18bf0311ef
commit 9efa7fc596
58 changed files with 1492 additions and 48 deletions
@@ -13,7 +13,7 @@ None. There is no back-end yet (`api/` is empty). The static design README antic
| (root) | `routes/__root.tsx` | `siteHead(siteContent)` | `AppShell` | — |
| `/` | `routes/index.tsx` | `pageHead('/')` | `Hero` + six home sections; search `?pakket=` | yes |
| `/over-mij` | `routes/over-mij.tsx` | `pageHead('/over-mij')` + `AboutPage` JSON-LD | `PageIntro`, `AboutIntro`, `StorySection` ×2, `PhotoDuo`, `LinkButton` | yes |
| `/portfolio` | `routes/portfolio.tsx` | `pageHead(...)` | `PageIntro` placeholder | no |
| `/portfolio` | `routes/portfolio.tsx` | `pageHead('/portfolio')` + `ImageGallery` JSON-LD; search `?shoot=` (`ShootTypeId`) | `PageIntro`, `PortfolioGallery`, `InstagramGrid` | yes |
| `/soorten-fotoshoots` | `routes/soorten-fotoshoots.tsx` | `pageHead('/soorten-fotoshoots')` + `WebPage` JSON-LD (`webPage()` + `shootServices()`) | `PageIntro`, `shoots/ShootList` (5× `ShootBlock`), `CallToAction`, `RichParagraph`, `LinkButton` | yes |
| `/contact` | `routes/contact.tsx` | `pageHead(...)` | `PageIntro` placeholder | no |
| `/privacyverklaring` | `routes/privacyverklaring.tsx` | `pageHead(...)` | `PageIntro` placeholder | no |
@@ -43,7 +43,7 @@ None. There is no back-end yet (`api/` is empty). The static design README antic
- `ContactForm(...)`, `ContactFormGate({ enabled, email, ... })`
- `PhotoDuo({ photos: [ContentImage, ContentImage], label, 'data-testid'? })`
- `PortfolioGrid({ items: GalleryItem[], eagerCount = 3, onOpen(index), onIntent?(), 'data-testid'? })`, `Lightbox({ items, index: number | null, onIndexChange, onClose, label?, finalFocusEl? })` (default export, lazy-loadable), `FilterBar({ options: FilterOption[], value, onChange, label })`
- `about/AboutIntro({ content })`, `about/StorySection({ content, titleId, tone?, spacing?, children? })`, `shoots/ShootList({ shoots, packages, portfolioLive })`, `shoots/ShootBlock({ shoot, packages, reverse, priority, portfolioLive })`
- `about/AboutIntro({ content })`, `about/StorySection({ content, titleId, tone?, spacing?, children? })`, `shoots/ShootList({ shoots, packages, portfolioShoots })` (types that link to the portfolio), `shoots/ShootBlock({ shoot, packages, reverse, priority, portfolioLink })`, `portfolio/PortfolioGallery({ photos, shootTypes, shoot, onShootChange })`
- `StatusPage({ title, children, actions? })`, `ErrorPage({ error, reset })`
- `LinkButton(RouterLink props & { variant?: 'outline' | 'accent' | 'light' })`
- `UmamiAnalytics({ hostname? })`
@@ -62,6 +62,7 @@ None. There is no back-end yet (`api/` is empty). The static design README antic
- `slidesToLoad(active, count): number[]`
- `backToTopThreshold(viewportHeight): number`
- `slideLabel`, `formatPrice`, `bookLabel`, `visiblePackages`, `visibleTestimonials`, `packageFromSearch`, `shootOptions`, `mailSubject`/`mailtoLink`, `validateField`/`validateContact`, `isLikelySpam`, `toContactPayload`, `contactFormReducer`
- Portfolio (`lib/portfolioFilters.ts`): `isShootTypeId`, `shootTypesWithPhotos(shootTypes, photos)`, `shootFromSearch(value, available)`, `filterPhotos(photos, shoot)`, `filterOptions(shootTypes, allLabel)`, `toGalleryItems(photos, shootTypes)`, `photoCountLabel(n)`; `seo.ts`: `galleryImages(photos)`
- Gallery (portfolio-page): `wrapIndex(index, count)`, `swipeDirection(start, end, threshold = 50)`, `masonryRowSpan({ width, height }, K = 40, gapRows = 2)`, `neighbourIndexes(index, count, radius = 2)`, `lightboxReducer(state, event)` (+ `LightboxState`, `LightboxEvent`)
### Monitoring
@@ -78,6 +79,10 @@ None. There is no back-end yet (`api/` is empty). The static design README antic
- **Fields**: `title`, `handle`, `photos: ContentImage[]` (the intro photos followed by the review photos, `instagramContent.ts`)
### LinkTarget / InlineLink / RichText
- **Fields**: `{ to: RoutePath; hash? }`; `InlineLink` adds `text`; `RichText = (string | InlineLink)[]`
### PortfolioContent / PortfolioPhoto
- **Fields**: `intro` (eyebrow, title, text), `photos: PortfolioPhoto[]` — `{ id, shootType: ShootTypeId, thumb: ContentImage (800 px wide), full: ImageSource (1600 px long side) }`
### GalleryItem / FilterOption
- **Fields**: `{ id, thumb, full, caption? }` / `{ id, label }` (generic, for the gallery blocks)
### AboutPageContent
- **Fields**: `head`, `intro` (eyebrow, title, `paragraphs: RichText[]`, image), `background`, `photos`, `personal`, `booking` (label + LinkTarget), `person` (name, jobTitle, knowsAbout)
### PricingPackage / Testimonial
@@ -17,7 +17,8 @@ graph TD
Shell --> Umami["UmamiAnalytics"]
Outlet --> Home["routes/index.tsx: Hero + six sections"]
Outlet --> About["routes/over-mij.tsx: about page"]
Outlet --> Placeholders["portfolio, contact, privacyverklaring: PageIntro"]
Outlet --> Portfolio["routes/portfolio.tsx: PortfolioGallery + InstagramGrid"]
Outlet --> Placeholders["contact, privacyverklaring: PageIntro"]
Home --> Hero["Hero (HeroArrows, HeroPauseButton, HeroSocials, useHeroSlider)"]
Home --> Sections["components/home/: IntroGallery, AboutBlock, Pricing, Testimonials, ContactSection; shared InstagramGrid"]
Sections --> Blocks["Shared blocks: PageSection, MediaText, CallToAction, RichParagraph, Eyebrow, SectionHeading, FramedImage, DeferredImage, Reveal; gallery: PortfolioGrid, Lightbox, FilterBar"]
@@ -35,7 +36,7 @@ graph TD
classDef support fill:#e2e8f0,stroke:#4a5568,stroke-width:1px,color:#000;
class Main,Root entry;
class Shell,Skip,Nav,Footer,ToTop,Umami,Outlet shell;
class Home,About,Placeholders,Hero,Sections,Form page;
class Home,About,Portfolio,Placeholders,Hero,Sections,Form page;
class Content,NavData,Seo,Theme,Blocks support;
```
@@ -37,8 +37,9 @@ Text alternative: visitors and crawlers use the website, which links out to soci
- **Recover from errors** — 404 page inside the shell, error page with retry
- **Read about the photographer** — Over mij page: introduction with portrait, how it started, two photos, life outside photography, links to the portfolio and contact, "Boek je shoot"
- *Soorten fotoshoots* (`/soorten-fotoshoots`, indexed): the five shoot types (Newborn, Zwangerschap, Gezin, Loveshoot, Portretten) with photo, text, a contact link (package preselected where one exists) and, once the portfolio is live, a filtered portfolio link; closing call to action to the prices
- *Placeholder pages (noindex)*: Portfolio, Contact, Privacyverklaring
- *Planned (static design only)*: portfolio with lightbox, shoot types and pricing page, contact page
- **Browse the portfolio** (`/portfolio`, indexed) — ten photos in a masonry grid, filters per shoot type (Alles, Newborn, Zwangerschap, Gezin; `?shoot=` in the URL), lightbox with captions, Instagram block; linked from Soorten fotoshoots per shoot type that has photos
- *Placeholder pages (noindex)*: Contact, Privacyverklaring
- *Planned (static design only)*: shoot types and pricing page, contact page
- **Business Dictionary**:
- **Shell** — the Header / page content / Footer frame shared by every page (see LAYOUT.md)
- **Hero** — full-screen photo slider at the top of the homepage
@@ -65,7 +65,8 @@ Candidates for modification are marked with ★ for the over-mij-page feature.
- `web/src/components/PhotoDuo/PhotoDuo.tsx` — two photos side by side
- `web/src/content/aboutContent.ts` — about page content; `web/src/assets/about/*` — portrait and duo photos; `web/public/og-over-mij.jpg` — preview image
- `web/src/routes/soorten-fotoshoots.tsx` — the shoot types page
- `web/src/routes/{portfolio,contact,privacyverklaring}.tsx` — placeholders with `PageIntro`
- `web/src/routes/portfolio.tsx` — the portfolio (indexed; `?shoot=` filter; `ImageGallery` JSON-LD); `web/src/components/portfolio/PortfolioGallery/`, `web/src/content/portfolioContent.ts`, `web/src/lib/portfolioFilters.ts`, `web/src/assets/portfolio/*` (10 photos × 2 sizes), `web/public/og-portfolio.jpg`
- `web/src/routes/{contact,privacyverklaring}.tsx` — placeholders with `PageIntro`
- `web/src/components/AppShell.tsx` — shell
- `web/src/components/NavigationBar/*` — header, NavLink, MobileNav
- `web/src/components/Footer/*` — footer, FooterColumn, FooterLink
@@ -5,7 +5,7 @@
- **Feature Slug**: portfolio-page
- **Project Type**: Brownfield
- **Start Date**: 2026-10-24T19:30:00Z
- **Current Stage**: CONSTRUCTION - Code Generation (Unit 2 Gallery building blocks, generated, awaiting approval)
- **Current Stage**: CONSTRUCTION - Code Generation (Unit 3 Portfolio page, generated, awaiting approval)
- **Branch**: feature/portfolio-page (rebased onto master 1bf28cb after contact-page PR #10)
- **Worktree**: K:\Development\SlpSoftware\Projects\AndreaSlopFotografie-portfolio
@@ -79,11 +79,11 @@ Parallel features, each in its own worktree (originally stacked on feature/over-
- [ ] Units Generation - SKIP
### 🟢 CONSTRUCTION PHASE
- [~] Functional Design - EXECUTE (units 2 and 3) / SKIP (unit 1) — Unit 2 ✅
- [~] Functional Design - EXECUTE (units 2 and 3) / SKIP (unit 1) — Unit 2 ✅; Unit 3 ✅
- [ ] NFR Requirements - SKIP
- [ ] NFR Design - SKIP
- [ ] Infrastructure Design - SKIP
- [~] Code Generation - EXECUTE (per unit) — Unit 1 Shared Instagram block ✅ (e013f14 after rebases); Unit 2 Gallery building blocks: generated, awaiting approval
- [~] Code Generation - EXECUTE (per unit) — Unit 1 Shared Instagram block ✅ (e013f14 after rebases); Unit 2 Gallery building blocks ✅ (18bf031); Unit 3 Portfolio page: generated, awaiting approval
- [ ] Build and Test - EXECUTE
### 🟡 OPERATIONS PHASE
@@ -268,3 +268,51 @@ Feature "portfolio-page" may affect components also touched by active feature "o
**Context**: CONSTRUCTION - Code Generation Unit 2 (generated, awaiting approval)
---
## Code Generation — Unit 2 — Approval; SSH agent; Functional Design Unit 3 start
**Timestamp**: 2026-10-27T08:00:00Z
**User Input**: "start de ssh agent, want de pc is tussendoor uit geweest. Dan kan je pushen zodra ik wil dta je dta doet. Ga daarna verder naar de volgende stage"
**AI Response**: "Unit 2 approved (18bf031). No agent was running; started one without -t (ssh-agent -s > ~/.ssh/agent.env, PID 1170); it has no identities yet — asked the user to run ssh-add themselves (passphrase). Push only on the user's request. Started Functional Design for unit 3: downloaded the 10 live portfolio photos into a scratch folder (sizes 1067×1600 / 1600×1067, one 2560×1707), viewed them, and created construction/plans/portfolio-page-functional-design-plan.md and portfolio-page-fd-questions.md with a proposal of shoot type and alt text per photo (Newborn 6, Zwangerschap 2, Gezin 2; no Loveshoot or Portret) and 4 questions (approve proposal, photos 2/4 newborn or gezin, OG photo, Soorten links follow-up)."
**Context**: CONSTRUCTION - Functional Design Unit 3 (awaiting answers)
---
## Functional Design — Unit 3 — Answers and Artifacts
**Timestamp**: 2026-10-27T08:30:00Z
**User Input**: "ik heb de vragen beantwoord"
**AI Response**: "Answers: Q1 A (shoot types and alt texts as proposed), Q2 A (photos 2 and 4 stay Newborn), Q3 A (preview image from photo 7), Q4 A (wire the 'types with photos' helper into Soorten fotoshoots in this unit; 3 links instead of 5). No ambiguities. Generated construction/portfolio-page/functional-design/{domain-entities, business-rules, business-logic-model, frontend-components}.md: the 10 photos with ids, types, sizes and alt texts; filter, ?shoot=, caption, SEO (ImageGallery with ImageObjects, og-portfolio.jpg, /portfolio indexed but not in photoPagePaths unless measured below 0.9 and the user agrees) and Soorten link rules; new pure helpers with properties; PortfolioGallery and the route; ShootList/ShootBlock prop portfolioLive → portfolioShoots."
**Context**: CONSTRUCTION - Functional Design Unit 3 (awaiting approval)
---
## Functional Design — Unit 3 — Approval
**Timestamp**: 2026-10-27T08:45:00Z
**User Input**: "approved, ga door. ssh key is ook geladen"
**AI Response**: "Functional design of unit 3 approved. Verified the ED25519 key is loaded in the agent (push still only on request). Created construction/plans/portfolio-page-code-generation-plan.md (15 steps: photo processing with a one-off System.Drawing script, content and types, portfolioFilters helpers with PBT, galleryImages, PortfolioGallery, route, sitePages/lighthouserc/sitemap, app tests, Soorten links prop change, LAYOUT.md, RE lines, pnpm check with a stop-and-ask if /portfolio mobile < 0.9, visual check offered via deploy_test on request, summary, commit)."
**Context**: CONSTRUCTION - Code Generation Unit 3 (plan awaiting approval)
---
## Code Generation — Unit 3 — Plan Approval, Generation and Loading Decision
**Timestamp**: 2026-10-27T18:10:00Z
**User Input**: "Approve plan" — later "Ga verder waar je gebleven was" — and, asked in chat (AskUserQuestion) how the first portfolio photos load: "Geen foto direct laden (Recommended)"
**AI Response**: "Executed portfolio-page-code-generation-plan.md. Photos processed with a one-off System.Drawing script (first run failed: in PowerShell argument mode `[long]80` was passed as a string; fixed with `EncoderParameter]::new`). Content, portfolioFilters with PBT, galleryImages, PortfolioGallery (closes the lightbox on any filter change, detected during render), route, sitePages/lighthouserc/sitemap, app tests, Soorten links prop change, LAYOUT.md, RE lines. First pnpm check: /portfolio mobile 0.77. Diagnosed with dedicated Lighthouse runs: LCP was the intro text at 4.5 s because the 3 eager (but Reveal-hidden) photos competed with the fonts; CLS 0.119 came from the filter bar re-wrapping when the web font loaded (measured: without the bar CLS 0). Fixed the filter bar at the cause (single non-wrapping row; CLS 0.001) and asked the user about eager loading (0.80 with vs 0.91 without, two runs each); user chose no eager photos; requirements FR-PF-07 and BR-LD-01 updated. Final pnpm check: tests 82/460 green, /portfolio passes; remaining mobile failures (/, /soorten-fotoshoots, /contact) measured equally on master (pre-existing). Desktop green after one transient connection-refused rerun. Committed locally (no push)."
**Context**: CONSTRUCTION - Code Generation Unit 3 (generated, awaiting approval)
---
@@ -0,0 +1,48 @@
# Code Generation Plan — Unit 3: Portfolio page
Single source of truth for code generation of this unit. Workspace root: `K:\Development\SlpSoftware\Projects\AndreaSlopFotografie-portfolio` (worktree); all code in `web/src/` unless stated. Branch `feature/portfolio-page` (on master 1bf28cb, which already contains `webPage()` and `shootTypes.ts`).
## Unit Context
- **Requirements**: FR-PF-01, 02, 04, 08 (on this page), 09; SEO-PF-01..05; NFR-PF-01, 03..06
- **Design**: [functional design](../portfolio-page/functional-design/) (photos table, rules BR-PH/FL/SP/CP/SEO/SL/LY, helpers and properties, components)
- **Dependencies**: units 1 (`InstagramGrid`) and 2 (`PortfolioGrid`, `Lightbox`, `FilterBar`, `lightboxReducer`); master's `shootTypes.ts`, `webPage()`, `lib/shootLinks.ts` (`isPortfolioLive`)
- **Touches code of the finished Soorten fotoshoots feature**: `ShootList`, `ShootBlock`, `routes/soorten-fotoshoots.tsx`, `app.test.tsx` (agreed follow-up, Q4 = A)
## Steps
### Photos
- [x] **Step 1** — One-off PowerShell script in the scratchpad (.NET `System.Drawing`, high-quality bicubic, JPEG quality ~80, same approach as earlier features; not part of the project): from the 10 downloaded originals create `web/src/assets/portfolio/{id}.jpg` (800 px wide) and `{id}-groot.jpg` (1600 px long side), and `web/public/og-portfolio.jpg` (1200 × 630 centre crop of photo 7). Record the resulting sizes.
### Content and helpers
- [x] **Step 2** — `content/types.ts`: `PortfolioPhoto`, `PortfolioContent`. `content/portfolioContent.ts`: intro + 10 photos (domain-entities.md), images imported from `assets/portfolio/`.
- [x] **Step 3** — `lib/portfolioFilters.ts` (+ test): `isShootTypeId`, `shootTypesWithPhotos`, `shootFromSearch`, `filterPhotos`, `filterOptions` (`ALL_FILTER = 'alles'`), `toGalleryItems`, `photoCountLabel` — example tests and the properties in business-logic-model.md. `test/arbitraries.ts`: `portfolioPhoto` / `portfolioPhotos` generator.
- [x] **Step 4** — `seo.ts`: `galleryImages(photos, base = siteUrl)` (+ tests in `seo.test.ts`: one `ImageObject` per photo, absolute https URLs, description = alt, creator/copyrightHolder ids, no e-mail).
### Page
- [x] **Step 5** — `components/portfolio/PortfolioGallery/PortfolioGallery.tsx` (+ test): section with hidden h2 "Foto's", `FilterBar`, count live region, `PortfolioGrid`, lazy `Lightbox` (requested on intent or open), `lightboxReducer` state, close on filter change, focus return to the tile of the last shown photo. Tests: options, filtering and count announcement, `onShootChange` values (incl. "Alles" → `undefined`), invalid/unavailable shoot → Alles, open lightbox within the filtered list with caption, filter change closes it, axe.
- [x] **Step 6** — `routes/portfolio.tsx`: `validateSearch` (`{ shoot?: ShootTypeId }`), head (`pageHead` + `ImageGallery` JSON-LD), `PageIntro` (eyebrow, h1, intro), `PortfolioGallery` with replace navigation without scroll, `InstagramGrid` (valid Instagram link only).
- [x] **Step 7** — `sitePages.ts`: `/portfolio` `indexed: true` + `ogImage`; `lighthouserc.cjs`: `/portfolio` from `noindexPaths` to `indexedPaths` (not in `photoPagePaths`); `sitemap.test.ts` and other tests that list indexed pages updated.
- [x] **Step 8** — `app.test.tsx`: `/portfolio` renders the h1, filters, grid, Instagram; `?shoot=gezin` starts filtered; `?shoot=onzin` and `?shoot=loveshoot` show Alles; head has no `noindex`, canonical without parameters, `og:image`, the `ImageGallery` script.
### Soorten fotoshoots links (Q4 = A)
- [x] **Step 9** — `ShootList`/`ShootBlock`: prop `portfolioLive: boolean` → `portfolioShoots: readonly ShootTypeId[]`; `routes/soorten-fotoshoots.tsx` passes `shootTypesWithPhotos(...)` ids when `/portfolio` is live; tests updated (`app.test.tsx`: 3 links — newborn, zwangerschap, gezin).
### Docs and verification
- [x] **Step 10** — `LAYOUT.md`: Portfolio diagram Intro → Portfolio → Instagram (per `.ai/layout-conventions.md`).
- [x] **Step 11** — Reverse engineering: own lines about `/portfolio` (indexed, route, content, `PortfolioGallery`, helpers, `galleryImages`) and the Soorten links prop.
- [x] **Step 12** — `tsc`, ESLint, Prettier; ListAgents + "claim 4173"; `pnpm check`. Mobile Lighthouse for `/portfolio`: if below 0.9, stop and ask the user (0.85 photo-page budget or not) before touching `photoPagePaths`. Failures on `/` and `/contact` are compared with master as in unit 2.
- [x] **Step 13** — Visual check: no browser in this session. Offer a `deploy_test` (after "claim test") so the user can check the page on test, desktop and phone; do it only when the user asks. *Outcome: offered in the completion message.*
- [x] **Step 14** — Code summary `aidlc-docs/features/portfolio-page/construction/portfolio-page/code/code-summary.md`.
- [x] **Step 15** — Commit on `feature/portfolio-page` ("Adds the portfolio page"), with the unit 3 design docs. Push only when the user asks.
## Extension Compliance (unit 3)
| Rule | Status | Rationale |
|---|---|---|
| SECURITY-04 | Compliant | No CSP change; images self-hosted |
| SECURITY-05 | Compliant | `?shoot=` allowlisted (`isShootTypeId`), then checked against types with photos; never rendered |
| SECURITY-10 | Compliant | No new dependency; image processing is a one-off local script |
| SECURITY-11 | Compliant | Misuse case (crafted `?shoot=`) tested |
| SECURITY-13 | Compliant | No external resources; JSON-LD through `jsonLdScript` |
| Other SECURITY rules | N/A | No data stores, auth, server or infrastructure |
| PBT-01..07, 10 | Planned | Steps 3–4 (properties from business-logic-model.md, `portfolioPhoto` generator, example tests alongside) |
| PBT-08 / 09 | Compliant | Existing seed logging and fast-check |
@@ -0,0 +1,70 @@
# Functional Design-vragen — Unit 3: Portfoliopagina
Al vastgelegd (geen vraag nodig):
- **Volgorde**: zoals op de live site (1–10 hieronder).
- **Formaten**: raster 800 px breed; groot 1600 px aan de lange kant (foto 8 is nu 2560 px en wordt ook 1600). Hele foto, niet bijgesneden. Opgeslagen in `web/src/assets/portfolio/`.
- **Bijschrift in de lightbox** = de volledige naam van het shoottype uit `shootTypes.ts`: "Newbornshoot", "Zwangerschapsshoot", "Gezinsshoot". **Filterlabels** = de korte naam: "Newborn", "Zwangerschap", "Gezin".
- **Filters**: met deze 10 foto's zijn dat Alles, Newborn, Zwangerschap en Gezin. Loveshoot en Portret hebben geen foto en krijgen geen filter (verduidelijking 7). `?shoot=loveshoot` toont dus "Alles".
- **Kop boven het raster**: een h2 "Foto's" die alleen screenreaders horen (het ontwerp toont geen kop); de sectie is daarmee een benoemd landmark.
- **Titel en beschrijving**: blijven zoals ze zijn (vraag 11).
Vul per vraag de letter in na `[Answer]:`. Past geen enkele optie, kies dan de laatste (Anders) en licht toe.
---
## Voorstel: shoottype en alt-tekst per foto
| # | Bestand (live) | Wat er te zien is | Shoottype | Alt-tekst (voorstel) |
| --- | -------------- | ----------------------------------------------------------------------- | ------------ | ---------------------------------------------------------------------------------------- |
| 1 | F41A1916 | Baby in wit pakje ligt op de onderarm van een ouder, kijkt in de camera | Newborn | Pasgeboren baby in een wit pakje ligt op de onderarm van een ouder en kijkt in de camera |
| 2 | F41A1922 | Vader kust zijn baby op het hoofd | Newborn | Vader kust zijn pasgeboren baby op het hoofd |
| 3 | F41A7883 | Man omarmt zijn zwangere partner van achteren, zandvlakte bij avondzon | Zwangerschap | Aanstaande vader omarmt zijn zwangere partner op een zandvlakte in de avondzon |
| 4 | F41A7176 | Moeder drukt haar gezicht tegen het hoofdje van haar baby | Newborn | Moeder drukt haar gezicht tegen het hoofdje van haar pasgeboren baby |
| 5 | F41A8700 | Close-up van een slapende baby in een gestreept pakje | Newborn | Slapende pasgeboren baby in een bruin-wit gestreept pakje |
| 6 | F41A8206 | Zwangere buik in zwarte kleding, twee handen eromheen | Zwangerschap | Zwangere buik in een zwarte jurk, omarmd door twee handen |
| 7 | F41A1579 | Grote broer kust de baby op bed | Gezin | Grote broer kust zijn pasgeboren broertje of zusje op een wit bed |
| 8 | 5-F41A4650 | Babyvuistje tussen gebreide deken en geruite doek | Newborn | Babyvuistje tussen een gebreide deken en een geruite doek |
| 9 | F41A7138 | Vader en moeder kijken naar hun slapende baby | Gezin | Jonge ouders kijken samen naar hun slapende pasgeboren baby |
| 10 | F41A7284 | Blote voetjes in een gestreept gebreid broekje | Newborn | Blote babyvoetjes in een gestreept gebreid broekje |
Telling: Newborn 6, Zwangerschap 2, Gezin 2.
## Vraag 1: Klopt het voorstel hierboven?
- A) Ja, alle shoottypes en alt-teksten zoals voorgesteld (Andrea kan de alt-teksten later nog nalezen) (aanbevolen)
- B) Ja, maar met aanpassingen (beschrijf per nummer hieronder)
- X) Anders (beschrijf hieronder na de [Answer]:-tag)
[Answer]: A
## Vraag 2: Foto 2 en 4 (ouder met baby): Newborn of Gezin?
Op beide staat één ouder met een pasgeboren baby, binnen, in de stijl van de newbornshoots.
- A) **Newborn** (zoals voorgesteld): het zijn foto's uit een newbornshoot; Gezin houdt de foto's met meer gezinsleden (aanbevolen)
- B) **Gezin**: dan worden het 4 newborn- en 4 gezinsfoto's
- X) Anders (beschrijf hieronder na de [Answer]:-tag)
[Answer]: A
## Vraag 3: Preview-afbeelding bij delen (1200×630)
Liggende foto's passen het best in het brede formaat.
- A) **Foto 7** (grote broer kust de baby): warm, vertelt een verhaal, past bij "lifestyle" (aanbevolen)
- B) **Foto 5** (slapende baby, close-up)
- C) **Foto 6** (zwangere buik)
- X) Anders (beschrijf hieronder na de [Answer]:-tag)
[Answer]: A
## Vraag 4: Links "Bekijk meer …foto's" op Soorten fotoshoots
Die pagina toont straks bij elk shoottype een link naar het portfolio, ook bij Loveshoot en Portret. Daar zijn geen portfoliofoto's van, dus die links tonen "Alles". De sessie van Soorten fotoshoots is gestopt; het aansluiten van de helper ligt bij deze feature.
- A) **In deze unit**: de helper `shootTypesWithPhotos` in `ShootList`/`ShootBlock` aansluiten, zodat alleen Newborn, Zwangerschap en Gezin een link krijgen; de routetest gaat van 5 naar 3 links (aanbevolen)
- B) **Later, apart**: nu niets aan Soorten fotoshoots veranderen; tot die tijd linken Loveshoot en Portret naar "Alles"
- X) Anders (beschrijf hieronder na de [Answer]:-tag)
[Answer]: A
@@ -0,0 +1,10 @@
# Functional Design Plan — Unit 3: Portfolio page
Depth: standard. Scope from the execution plan: the photo data (shoot type and alt text per photo, approved by the user — clarification 4), the preview image, the `?shoot=` rules, the filter/caption mapping onto the unit 2 blocks, the `ImageGallery` structured data, the follow-up for the Soorten fotoshoots links, and the testable properties of the new helpers (PBT-01). Questions: [portfolio-page-fd-questions.md](portfolio-page-fd-questions.md).
- [x] Collect and analyse the answers in `portfolio-page-fd-questions.md`
- [x] `domain-entities.md` — `PortfolioPhoto`, `PortfolioContent`, the 10 photos with shoot type, alt text, sizes; relation to `ShootType`, `GalleryItem`, `ImageObject`
- [x] `business-rules.md` — photo and image rules (sizes, order), filter rules (options, `?shoot=` parsing and fallback, canonical), caption, lightbox scope, SEO (indexed, title/description unchanged, `ogImage`, `ImageGallery`), Soorten links rule, LAYOUT.md
- [x] `business-logic-model.md` — route → gallery → grid/lightbox flow; pure helpers and their properties (PBT-01)
- [x] `frontend-components.md` — `PortfolioGallery` and the route: hierarchy, props, state, accessibility, test ids
- [x] Validate against requirements.md, application-design.md, unit 2 design and the extension rules
@@ -0,0 +1,39 @@
# Code Summary — Unit 3: Portfolio page
Plan: [portfolio-page-code-generation-plan.md](../../plans/portfolio-page-code-generation-plan.md) · Design: [functional-design/](../functional-design/)
## Created
| File | What |
|---|---|
| `web/src/assets/portfolio/*.jpg` | 10 photos × 2: grid 800 px wide (35–143 kB), large 1600 px long side (104–292 kB); one-off `System.Drawing` script, JPEG quality 80 |
| `web/public/og-portfolio.jpg` | 1200 × 630 centre crop of photo 7 (68 kB) |
| `web/src/content/portfolioContent.ts` | Intro + the 10 approved photos (id, shoot type, sizes, alt) |
| `web/src/lib/portfolioFilters.ts` (+ test) | `isShootTypeId`, `shootTypesWithPhotos`, `shootFromSearch`, `filterPhotos`, `filterOptions`, `toGalleryItems`, `photoCountLabel`; example + property-based tests (oracle, idempotence, round-trip, invariants) |
| `web/src/components/portfolio/PortfolioGallery/` (+ test) | Section with hidden h2 "Foto's", `FilterBar`, count announcement, `PortfolioGrid` (`eagerCount={0}`), lazy `Lightbox` (requested on intent or open), `lightboxReducer`, closes on any filter change, focus return to the last shown tile |
## Modified
| File | Change |
|---|---|
| `web/src/routes/portfolio.tsx` | Real page: typed `validateSearch` (`{ shoot?: ShootTypeId }`), head with `ImageGallery` JSON-LD, `PageIntro`, `PortfolioGallery` (replace navigation, no scroll), `InstagramGrid` |
| `web/src/content/types.ts` | `PortfolioPhoto`, `PortfolioContent` |
| `web/src/seo.ts` (+ tests) | `galleryImages(photos)` (`ImageObject`s, absolute URLs, creator/copyrightHolder ids) |
| `web/src/sitePages.ts` | `/portfolio` indexed, `ogImage` |
| `web/lighthouserc.cjs` | `/portfolio` in `indexedPaths` (default budget 0.9, not a photo page) |
| `web/src/test/arbitraries.ts` | `portfolioPhoto`, `portfolioPhotos` |
| `web/src/components/shoots/ShootList`, `ShootBlock`, `routes/soorten-fotoshoots.tsx` (+ tests) | `portfolioLive` → `portfolioShoots` / `portfolioLink`: "Bekijk meer …foto's" only for newborn, zwangerschap, gezin |
| `web/src/components/FilterBar/FilterBar.tsx`, `recipes/filterControl.ts` | One row that never wraps (`nowrap`, horizontal scroll if too narrow, `safe center`): fixes a layout shift (CLS 0.119 → 0.001) when the web font replaced the fallback |
| `web/src/app.test.tsx`, `seo.test.ts`, `sitemap.test.ts` | Portfolio route tests (outline, filters, `?shoot=` incl. invalid values, canonical, og:image, JSON-LD, replace navigation); placeholder examples moved to `/privacyverklaring`; Soorten expects 3 portfolio links |
| `LAYOUT.md` | Portfolio: Intro → Portfolio → Instagram |
| `aidlc-docs/_shared/reverse-engineering/*` | Own lines about `/portfolio`, the gallery, helpers and the Soorten links prop |
| `requirements.md` FR-PF-07, `business-rules.md` BR-LD-01 | No eager grid photos (user decision, see below) |
## Decisions during generation
- **Eager loading** (user decision 2026-10-27): the grid fades in (`Reveal`), so its photos are never the largest paint; the 3 eager photos only competed with the fonts and delayed the intro text (LCP 4.5 s → 2.9 s without). Measured twice each: 0.80 with, 0.91 without.
- **Filter bar layout shift**: diagnosed by measuring without the bar (CLS 0) and fixed at the cause (single non-wrapping row), not by reserving extra space.
## Verification
- `tsc`, ESLint, Prettier: clean.
- Tests: ✅ 82 files, 460 tests.
- Lighthouse desktop: ✅ all 7 URLs (one earlier run had a transient `ERR_CONNECTION_REFUSED` on port 4173 caused by the measuring runs just before; the rerun passed).
- Lighthouse mobile: ✅ `/portfolio` (≥ 0.9; 0.91 in the dedicated runs). ❌ pre-existing, same on master: `/` 0.77 (budget 0.8), `/soorten-fotoshoots` 0.84 (budget 0.85; master 0.84, this branch 0.86 in dedicated runs), `/contact` 0.87 (budget 0.9). Open item in the memory note "Open follow-ups".
- Visual check: no browser in this session; offered to the user via `deploy_test` (after "claim test").
@@ -0,0 +1,49 @@
# Business Logic Model — Unit 3: Portfolio page
## Flow — opening the page with a filter, changing it, opening a photo
```mermaid
sequenceDiagram
box rgba(246,224,94,0.4) Visitor
participant V as Visitor
end
box rgba(99,179,237,0.4) Page
participant R as Route
participant G as PortfolioGallery
participant B as Grid and Lightbox
end
V->>R: open /portfolio?shoot=gezin
R->>R: validateSearch keeps a ShootTypeId
R->>G: shoot, photos, shoot types
G->>G: shootFromSearch, filterOptions, filterPhotos, toGalleryItems
G->>B: two gezin photos
V->>G: choose Newborn
G->>R: onShootChange newborn
R->>R: navigate with replace, no scroll
G->>V: announce 6 foto's
V->>B: click photo 2
B->>G: onOpen 1
G->>B: lightbox at index 1 of the newborn list
```
Text alternative: the route validates ?shoot= and passes it with the content to PortfolioGallery, which derives the options, the filtered list and the gallery items with pure helpers; choosing a filter updates the URL without a history entry and announces the count; clicking a photo opens the lightbox within the filtered list.
## Pure Helpers and Properties (PBT-01)
New in `web/src/lib/` (100% coverage, example + property-based tests, generators: `shootTypeId`, `uniqueShootTypes` (existing), plus a new `portfolioPhoto` generator).
| Helper | Purpose | Properties |
|---|---|---|
| `shootTypesWithPhotos(shootTypes, photos)` | Shoot types that have at least one photo, in list order | Subset of `shootTypes` in the same order (invariant); a type is in the result iff some photo has it (oracle); adding a photo of a listed type does not change the result (invariant); idempotent when the photos are re-filtered by the result (idempotence) |
| `shootFromSearch(value, available)` | `?shoot=` → `ShootTypeId \| undefined` | Every available id round-trips, also in other letter case or with spaces (round-trip); result is always `undefined` or in `available` (invariant); non-strings → `undefined` |
| `filterPhotos(photos, shoot)` | Photos of one type, or all | Result ⊆ input, order kept (invariant); all of type `shoot` (invariant); `filterPhotos(filterPhotos(p, s), s) = filterPhotos(p, s)` (idempotence); `undefined` → identity (invariant); the union over all types = all photos (oracle) |
| `filterOptions(shootTypes, allLabel)` | "Alles" + one option per type | First is `{ id: 'alles', label: allLabel }`; length = types + 1; labels = `name` (invariant) |
| `toGalleryItems(photos, shootTypes)` | Photos → `GalleryItem`s with caption | Same length and order, ids kept (invariant); caption = `shootLabel` of the photo's type (oracle) |
| `photoCountLabel(n)` | "1 foto" / "n foto's" | Singular only for 1 (example-based; no further property) |
| `galleryImages(photos, base?)` in `seo.ts` | `ImageObject[]` | One per photo, same order (invariant); every URL starts with `https://` and the site URL (invariant); `description` = alt (oracle); serialised JSON contains no `@` e-mail pattern (invariant) |
The route's `validateSearch` uses `isShootTypeId` (a type guard derived from `shootTypes.ts`), covered through `shootFromSearch`.
## State
- **URL**: the active filter (validated).
- **PortfolioGallery**: `openIndex: number | null` via `lightboxReducer` from unit 2 (`listChanged` on filter change), the count announcement text, a `lightboxRequested` flag that starts the lazy import.
@@ -0,0 +1,57 @@
# Business Rules — Unit 3: Portfolio page
Requirements FR-PF-01..09, SEO-PF-01..05, NFR-PF-04/06; unit 2 rules BR-GR/LB/FB apply unchanged.
## Photos
- **BR-PH-01**: the 10 photos in the order of domain-entities.md; every photo has a valid `ShootTypeId`, a unique id and positive intrinsic sizes.
- **BR-PH-02**: grid image 800 px wide, large image 1600 px on the long side, same aspect ratio, compressed once by hand (no build step); stored in `web/src/assets/portfolio/`.
## Loading
- **BR-LD-01**: the page passes `eagerCount={0}` to `PortfolioGrid`: no grid photo loads before the page has (decision 2026-10-27, see requirements FR-PF-07).
## Filters
- **BR-FL-01 Options**: "Alles" (id `alles`) first, then one option per shoot type that has at least one photo, in `shootTypes.ts` order, labelled with `name`. For these photos: Alles, Newborn, Zwangerschap, Gezin.
- **BR-FL-02 Group name**: "Filter op soort shoot".
- **BR-FL-03 Filtered list**: "Alles" → all photos; a shoot type → only its photos, original relative order.
- **BR-FL-04 Announcement**: after a filter change, a polite live region says "{n} foto's" ("1 foto" for one).
- **BR-FL-05 Lightbox**: a filter change closes an open lightbox; the lightbox only browses the filtered list (C6).
## `?shoot=` parameter
- **BR-SP-01 Route validation**: `validateSearch` keeps `shoot` only when it is a `ShootTypeId` (exact, after trim + lower case); anything else (missing, unknown, non-string, array) becomes `{}`. Type: `{ shoot?: ShootTypeId }`.
- **BR-SP-02 Photos check**: the page uses the shoot only when that type has photos; otherwise it shows "Alles" (no message). `shootFromSearch(value, available)` implements both checks for the page; the value from the URL is never rendered.
- **BR-SP-03 Changing**: choosing "Alles" removes the parameter; choosing a type sets it; navigation with `replace: true` and without scrolling (Q4 of application design).
- **BR-SP-04 Canonical**: always `https://andreaslop.nl/portfolio`; the sitemap lists `/portfolio` only.
## Caption
- **BR-CP-01**: lightbox caption = the photo's shoot type `shootLabel` ("Newbornshoot", "Zwangerschapsshoot", "Gezinsshoot").
## SEO
- **BR-SEO-01**: `sitePages['/portfolio']`: `indexed: true`, title and description unchanged, `ogImage` `/og-portfolio.jpg` (1200 × 630, alt as in domain-entities.md).
- **BR-SEO-02**: `lighthouserc.cjs`: `/portfolio` moves from `noindexPaths` to `indexedPaths`. It is **not** added to `photoPagePaths` unless the measured mobile performance stays below 0.9 and the user agrees to 0.85 (open decision in aidlc-state.md).
- **BR-SEO-03**: structured data = `webPage('ImageGallery', '/portfolio', { associatedMedia: galleryImages(all 10 photos) })` through `structuredDataScript`; independent of the active filter; no e-mail; every URL absolute https.
- **BR-SEO-04**: one h1 (PageIntro "Portfolio"); grid section named by a visually hidden h2 "Foto's"; Instagram section h2 "Instagram".
## Soorten fotoshoots links (Q4 = A)
- **BR-SL-01**: on `/soorten-fotoshoots`, "Bekijk meer {photosLabel}" → `/portfolio?shoot={id}` shows only while `/portfolio` is indexed **and** only for shoot types that have portfolio photos (`shootTypesWithPhotos`). Now: newborn, zwangerschap, gezin (3 links instead of 5).
## LAYOUT.md
- **BR-LY-01**: the Portfolio diagram becomes Intro → Portfolio → Instagram (FR-PF-09).
## Decision Flow — the active filter
```mermaid
graph TD
Url["?shoot= in the URL"] --> Valid{"A ShootTypeId?"}
Valid -->|"no"| All["Alles"]
Valid -->|"yes"| Has{"Type has photos?"}
Has -->|"no"| All
Has -->|"yes"| Type["That shoot type"]
All --> Show["Show the filtered list"]
Type --> Show
classDef decision fill:#FF9800,stroke:#e65100,color:#000;
classDef state fill:#2196F3,stroke:#0d47a1,color:#000;
class Valid,Has decision;
class Url,All,Type,Show state;
```
Text alternative: a ?shoot= value that is not a known shoot type, or names a type without photos, falls back to Alles; otherwise that type is the active filter; either way the page shows the filtered list.
@@ -0,0 +1,71 @@
# Domain Entities — Unit 3: Portfolio page
Decisions: [portfolio-page-fd-questions.md](../../plans/portfolio-page-fd-questions.md) (all A).
## Relationships
```mermaid
graph TD
Content["PortfolioContent"] -->|"intro"| Intro["eyebrow, title, text"]
Content -->|"photos (10, in order)"| Photo["PortfolioPhoto"]
Photo -->|"shootType"| Shoot["ShootType (shootTypes.ts)"]
Photo -->|"thumb + full"| Images["ContentImage + ImageSource"]
Photo -->|"toGalleryItems"| Item["GalleryItem (unit 2)"]
Shoot -->|"shootLabel as caption"| Item
Shoot -->|"name as label"| Option["FilterOption (unit 2)"]
Photo -->|"galleryImages"| ImageObject["schema.org ImageObject"]
classDef entity fill:#2196F3,stroke:#0d47a1,color:#000;
classDef shared fill:#4CAF50,stroke:#2e7d32,color:#000;
classDef value fill:#e2e8f0,stroke:#4a5568,color:#000;
class Content,Photo entity;
class Shoot,Item,Option,ImageObject shared;
class Intro,Images value;
```
Text alternative: PortfolioContent holds the intro and ten PortfolioPhotos in order; each photo references a ShootType and has a grid and a large image; photos become generic GalleryItems with the shoot type's full label as caption, shoot types become FilterOptions with their short name, and photos become schema.org ImageObjects for the structured data.
## PortfolioContent (`content/portfolioContent.ts`)
| Field | Value |
|---|---|
| `intro.eyebrow` | "Werk" |
| `intro.title` | "Portfolio" |
| `intro.text` | "Een selectie uit mijn werk. Klik of tik op een foto om hem groot te bekijken." |
| `photos` | the 10 photos below, in this order |
## PortfolioPhoto
| Field | Type | Rule |
|---|---|---|
| `id` | `string` | Stable slug from the original file (e.g. `f41a1916`); unique |
| `shootType` | `ShootTypeId` | One of the ids in `shootTypes.ts` |
| `thumb` | `ContentImage` | 800 px wide, own aspect ratio, alt text below |
| `full` | `ImageSource` | 1600 px on the long side, same aspect ratio |
## The 10 photos (approved 2026-10-27)
| # | id | Shoot type | Orientation | Alt text |
|---|---|---|---|---|
| 1 | `f41a1916` | newborn | portrait | Pasgeboren baby in een wit pakje ligt op de onderarm van een ouder en kijkt in de camera |
| 2 | `f41a1922` | newborn | portrait | Vader kust zijn pasgeboren baby op het hoofd |
| 3 | `f41a7883` | zwangerschap | portrait | Aanstaande vader omarmt zijn zwangere partner op een zandvlakte in de avondzon |
| 4 | `f41a7176` | newborn | portrait | Moeder drukt haar gezicht tegen het hoofdje van haar pasgeboren baby |
| 5 | `f41a8700` | newborn | landscape | Slapende pasgeboren baby in een bruin-wit gestreept pakje |
| 6 | `f41a8206` | zwangerschap | landscape | Zwangere buik in een zwarte jurk, omarmd door twee handen |
| 7 | `f41a1579` | gezin | landscape | Grote broer kust zijn pasgeboren broertje of zusje op een wit bed |
| 8 | `f41a4650` | newborn | landscape | Babyvuistje tussen een gebreide deken en een geruite doek |
| 9 | `f41a7138` | gezin | portrait | Jonge ouders kijken samen naar hun slapende pasgeboren baby |
| 10 | `f41a7284` | newborn | portrait | Blote babyvoetjes in een gestreept gebreid broekje |
Portrait: thumb 800 × 1200, full 1067 × 1600. Landscape: thumb 800 × 533, full 1600 × 1067 (photo 8 scaled down from 2560 × 1707).
## Preview image
`web/public/og-portfolio.jpg`, 1200 × 630, cropped from photo 7; alt "Grote broer kust zijn pasgeboren broertje of zusje op een wit bed".
## ImageObject (structured data)
| Field | Value |
|---|---|
| `@type` | `ImageObject` |
| `contentUrl` | absolute https URL of `full.src` |
| `thumbnailUrl` | absolute https URL of `thumb.src` |
| `description` | the alt text |
| `width` / `height` | of the full image |
| `creator` | `{ '@id': personId }` |
| `copyrightHolder` | `{ '@id': businessId }` |
@@ -0,0 +1,42 @@
# Frontend Components — Unit 3: Portfolio page
## Hierarchy
```mermaid
graph TD
Route["routes/portfolio.tsx"] --> Intro["PageIntro (h1 Portfolio)"]
Route --> Gallery["portfolio/PortfolioGallery"]
Route --> Insta["InstagramGrid (shared)"]
Gallery --> Section["PageSection (h2 Foto's, hidden)"]
Section --> Filter["FilterBar"]
Section --> Count["live region: n foto's"]
Section --> Grid["PortfolioGrid"]
Section --> Lazy["Suspense + lazy Lightbox"]
Soorten["routes/soorten-fotoshoots.tsx"] --> List["shoots/ShootList + ShootBlock"]
classDef root fill:#4CAF50,stroke:#2e7d32,color:#000;
classDef ui fill:#2196F3,stroke:#0d47a1,color:#000;
classDef changed fill:#FF9800,stroke:#e65100,color:#000;
class Route root;
class Intro,Gallery,Insta,Section,Filter,Count,Grid,Lazy ui;
class Soorten,List changed;
```
Text alternative: the portfolio route renders PageIntro, the new PortfolioGallery and the shared InstagramGrid; the gallery renders a PageSection with a hidden h2, the FilterBar, a count live region, the PortfolioGrid and the lazily loaded Lightbox; the Soorten fotoshoots route and its ShootList/ShootBlock change to link only shoot types with photos.
## Route `routes/portfolio.tsx`
- `validateSearch: (search) => ({ shoot?: ShootTypeId })` via `isShootTypeId`
- `head`: `pageHead('/portfolio')` + `structuredDataScript(webPage('ImageGallery', '/portfolio', { associatedMedia: galleryImages(portfolioContent.photos) }))`
- component: `PageIntro eyebrow title` with intro text → `PortfolioGallery` → `InstagramGrid` (only with a valid Instagram link, as on the homepage)
- `onShootChange(shoot)` → `navigate({ search: shoot ? { shoot } : {}, replace: true, resetScroll: false })`
## PortfolioGallery (`components/portfolio/PortfolioGallery/`)
- **Props**: `photos`, `shootTypes`, `shoot: string | undefined` (raw from the route), `onShootChange(shoot: ShootTypeId | undefined)`
- **Derived**: available types, active shoot (`shootFromSearch`), options, filtered photos, gallery items
- **State**: `lightbox` (`lightboxReducer`), `announcement`, `lightboxRequested`
- **Markup**: `PageSection labelledBy="portfolio-title" spacing="flushTop"` with `VisuallyHidden as h2 id="portfolio-title"` "Foto's"; `FilterBar label="Filter op soort shoot"` (value `alles` when no shoot); `chakra.p srOnly aria-live="polite"` (`data-testid="portfolio-count"`); `PortfolioGrid` (`onOpen` → open, `onIntent` → request lightbox); `Suspense fallback={null}` → lazy `Lightbox` rendered once requested, with `finalFocusEl` returning the tile of the last shown item (`[data-testid="portfolio-tile-{n}"]`)
- **Test ids**: `portfolio-gallery`, plus those of the unit 2 blocks
## Soorten fotoshoots (changed)
- `ShootList` / `ShootBlock`: prop `portfolioLive: boolean` → `portfolioShoots: readonly ShootTypeId[]` (types that get a link); the block shows the link when its id is in the list
- `routes/soorten-fotoshoots.tsx`: `portfolioShoots = isPortfolioLive(sitePages) ? shootTypesWithPhotos(shootTypes, portfolioContent.photos).map(t => t.id) : []`
- `app.test.tsx`: expects 3 links (newborn, zwangerschap, gezin) when `/portfolio` is indexed
@@ -77,7 +77,7 @@ Shell header → **Intro** (page head, h1) → **Portfolio** (filter bar + mason
- Opening and switching respect `prefers-reduced-motion` (no fade/slide).
### FR-PF-07 Image loading
- **Grid**: the first 3 photos in order (one per column on desktop) load immediately with high priority; the others use the existing `DeferredImage` (after the load event, near the viewport). All grid images carry intrinsic width/height (no layout shift). *Source: Q7 = A, clarification 2 = A*
- **Grid**: all photos use the existing `DeferredImage` (after the load event, near the viewport); none load eagerly. All grid images carry intrinsic width/height (no layout shift). *Source: Q7 = A, clarification 2 = A; changed at Code Generation unit 3 (2026-10-27): the grid fades in (`Reveal`), so its photos are never the largest paint, and the 3 eager photos only delayed the fonts and the intro text — mobile Lighthouse 0.80 with, 0.91 without*
- **Lightbox**: the large image loads only when the lightbox opens; the next and previous large images (within the active set) are preloaded while it is open. While a large image loads, the grid image (already cached) or a neutral placeholder is shown — no empty flash, no layout jump. *Source: Q6 = A*
### FR-PF-08 Instagram block, shared