Records unit 3 of the Contact page as generated
Functional design, code generation plan and summary of the contact page, the updated LAYOUT.md diagram and the extended link requirement. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,34 @@
|
||||
# Code Summary — Unit 3: Contact page
|
||||
|
||||
## Created
|
||||
- `web/src/routes/contact.tsx` — replaces the placeholder: page head, the narrow card, the form column (visually hidden h2 + `ContactPanel load="eager"`), `ContactAside` with the wide card; `?pakket=` validation and clean-up; head with `ContactPage` JSON-LD
|
||||
- `web/src/components/contact/ContactAside/ContactAside.tsx` (+ test) — `picture` with a `(min-width: 64em)` source and a transparent `data:` fallback, priority, intrinsic size; card slot over the bottom of the photo
|
||||
- `web/src/content/contactContent.ts` — head texts (intro with `{reactietermijn}`), headings, photo and portrait
|
||||
- `web/src/lib/withReplyTime.ts` (+ test) — fills in the reply time
|
||||
- `web/src/assets/contact/contact.jpg` (840×1050, 80 KB), `contact-portret.jpg` (144×144, 5 KB), `web/public/og-contact.jpg` (1200×630, 60 KB) — crops of the original live photo (1600×1067), approved by the owner (portrait zoomed out, variant B)
|
||||
|
||||
## Modified
|
||||
- `web/src/content/types.ts` — `ContactPageContent`
|
||||
- `web/src/seo.ts` (+ test) — `contactPage()`
|
||||
- `web/src/sitePages.ts` — `/contact`: title, description, `indexed: true`, `ogImage`
|
||||
- `web/lighthouserc.cjs` — `/contact` indexed (standard 0.9 mobile budget, owner's choice)
|
||||
- `web/src/sitemap.test.ts` — expects `/contact`
|
||||
- `web/src/content/aboutContent.ts`, `web/src/app.test.tsx`, `web/src/components/about/AboutIntro/AboutIntro.test.tsx` — Over mij links to `/contact`; contact route tests
|
||||
- `web/src/components/ContactDetails/ContactDetails.tsx` — filled mail icon, matching the filled platform icons
|
||||
- `web/src/theme.ts`, `web/src/recipes/linkButton.ts` — accent button on `accent.deep` (white ≈ 5.7:1), hover on new `accent.deeper` (#475042)
|
||||
- `LAYOUT.md` — Contact: Intro; Contact form beside Photo + contact details
|
||||
- `web/src/lib/shootLinks.ts` (+ test), `web/src/content/shootTypesPageContent.ts`, `web/src/components/shoots/ShootBlock/ShootBlock.test.tsx` — Soorten fotoshoots: "Stuur een berichtje" → `/contact?pakket=<id>` (or `/contact`), "Boek je shoot" → `/contact` (FR-CP-09 extension, owner's request)
|
||||
|
||||
## Findings fixed during verification
|
||||
- `chakra.img` treated `width`/`height` as CSS props, so the intrinsic size was missing; now Chakra `Image` with `htmlWidth`/`htmlHeight`.
|
||||
- A property test of `withReplyTime` passed by chance: half placeholders around a real one could form a new one; generator restricted to brace-free text.
|
||||
- **Accent button contrast** (site-wide, pre-existing): white on `#7f8b76` = 3.58:1. Lighthouse only caught it here because the button is in the first screen; elsewhere `Reveal` keeps it at opacity 0 during the measurement, and jsdom computes no colours. Fixed in the recipe (owner's choice: darker green).
|
||||
|
||||
## Verification
|
||||
- `pnpm test`: 71 files, 367 tests passed (seed 1926155072; after the Soorten link change again 367/367, seed 1607463937); lint, format, build clean. Lighthouse not re-run for the link change (href-only change, no effect on performance or accessibility).
|
||||
- Production build in Chrome: no request for `contact.jpg` up to 1023 px (LCP = intro text); one request with priority **High** from 1024 px (LCP = the photo). Screenshots at 390 and 1280 px match mockup 1a.
|
||||
- Lighthouse desktop: all pass; `/contact` 0.99 / 1 / 1 / 1.
|
||||
- Lighthouse mobile: accessibility, best practices and SEO pass everywhere. **Performance fails on two pages:**
|
||||
- `/` 0.78–0.80 vs 0.8 — pre-existing: identical on the unit 2 build (3 runs each); owner chose to handle it separately (recorded as an open follow-up).
|
||||
- `/contact` 0.88 / 0.90 / 0.88 vs 0.9 — same client-rendering cause as the photo pages (text appears after the JavaScript); owner chose to keep 0.9.
|
||||
- In CI, performance is report-only (D6), so these do not block a merge; locally `pnpm check` fails on them.
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 128 KiB |
Reference in New Issue
Block a user