Adds the AI-DLC documents of the testimonials redesign
Requirements, execution plan, functional design, code summaries, build and test results and the audit log; the reverse-engineering notes and the feature registry are updated. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -70,6 +70,7 @@ None. There is no back-end yet (`api/` is empty). The static design README antic
|
||||
- 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`)
|
||||
- Shoot pages (unit 1): `shootPagePath(id)`, `shootIdFromSlug(slug)`, `shootIdFromPath(pathname)` (`lib/shootPages.ts`); `shootPackage(shoot, packages)` (`lib/shootPackage.ts`); `fillPlaceholders(text, values)`, `fillRichText(rich, values)` (`lib/fillPlaceholders.ts`); `richTextToPlain(text)` (`lib/richTextToPlain.ts`); `shootPageView(id, page, sources)` (`lib/shootPageView.ts`)
|
||||
- Shoot pages (unit 2): `headingId(prefix, id)` (`lib/headingId.ts`), `readMoreLabel(shoot)` (`lib/readMoreLabel.ts`), `mosaicLayout(count): MosaicTile[]` (`lib/mosaicLayout.ts`), `storyLayout(stories): StoryLayout[]` (`lib/storyLayout.ts`), `shootPageBands(view): SectionBand[]` (`lib/shootPageBands.ts`; the section order of `ShootPage`), `isShootSectionPath(pathname)` (`lib/isShootSectionPath.ts`, FR-ST-14, used by `NotFound`)
|
||||
- Testimonials (testimonials-redesign): `slideCounter(index, count): string` (`lib/slideCounter.ts`; the visible "X / Y", safe for odd input), `normalizeImagePosition(value: unknown): string` (`lib/normalizeImagePosition.ts`; `"X% Y%"` or the centre `"50% 50%"`, never throws)
|
||||
- Navigation (unit 3): `shootNavItems(shoots): NavItem[]` (`lib/shootNavItems.ts`); `isItemCurrent(item, pathname)`, `isSectionCurrent(item, pathname)` (`lib/navCurrent.ts`); `navMenuReducer(state, event)` with `NavMenuState`, `NavMenuEvent`, `initialNavMenuState`, `FocusRequest` (`lib/navMenuState.ts`)
|
||||
|
||||
### Monitoring
|
||||
@@ -93,7 +94,7 @@ None. There is no back-end yet (`api/` is empty). The static design README antic
|
||||
### AboutPageContent
|
||||
- **Fields**: `head`, `intro` (eyebrow, title, `paragraphs: RichText[]`, image), `background`, `photos`, `personal`, `booking` (label + LinkTarget), `person` (name, jobTitle, knowsAbout)
|
||||
### PricingPackage / Testimonial
|
||||
- **Fields**: `id`, `name`, `price`, `features[]` / `id`, `shoot`, `quote`, `author`, `image`
|
||||
- **Fields**: `id`, `name`, `price`, `features[]` / `id`, `shoot`, `quote`, `author`, `image`, `imagePosition?` (optional crop position of the landscape photo, two percentages such as `'50% 42%'`; normalised by `normalizeImagePosition`, never decides whether the review is shown; testimonials-redesign)
|
||||
### SocialLink
|
||||
- **Fields**: `platform: SocialPlatform` (`facebook` | `instagram`), `href: string`
|
||||
- **Validation**: shown only if `href` is a valid https URL
|
||||
|
||||
@@ -77,12 +77,12 @@ Text alternative: client.tsx starts Sentry and hydrates the prerendered page (pr
|
||||
|
||||
### components/home/ (homepage sections)
|
||||
- **Purpose**: The six homepage blocks below the hero, in LAYOUT.md order
|
||||
- **Responsibilities**: `IntroGallery` (four photos, swipeable row on phones), `AboutBlock` (framed photo of Andrea + intro + link to `/over-mij`), `Pricing` + `PriceCard` (packages with "Boek" links → `/?pakket=…#contact`), `Testimonials` (+ `TestimonialCarousel`, `TestimonialSlide`), `ContactSection` (lazy `ContactForm` behind `ContactFormGate`, mailto fallback); the Instagram block is the shared `components/InstagramGrid` (fixed tiles linking to the profile, content from `instagramContent.ts`), also used on the portfolio
|
||||
- **Responsibilities**: `IntroGallery` (four photos, swipeable row on phones), `AboutBlock` (framed photo of Andrea + intro + link to `/over-mij`), `Pricing` + `PriceCard` (packages with "Boek" links → `/?pakket=…#contact`), `Testimonials` (+ `TestimonialCarousel`, `TestimonialSlide`: a landscape photo over a card with a "X / Y" counter and arrows, no dots and no autoplay, slides on change and on swipe), `ContactSection` (lazy `ContactForm` behind `ContactFormGate`, mailto fallback); the Instagram block is the shared `components/InstagramGrid` (fixed tiles linking to the profile, content from `instagramContent.ts`), also used on the portfolio
|
||||
- **Type**: Application
|
||||
|
||||
### Shared section building blocks
|
||||
- **Purpose**: Reusable pieces extracted during homepage-sections; `HomeSection` was renamed to `PageSection` and `MediaText`/`Eyebrow` were extracted in over-mij-page
|
||||
- **Responsibilities**: `PageSection` (section frame: `aria-labelledby`, tone `paper`/`alt`, width `default`/`narrow`/`full`, spacing `default`/`tight`/`flushTop`, anchor offset), `MediaText` (framed photo next to a text column, design `.about`), `Eyebrow` (accent label, optionally a heading), `SectionHeading` (eyebrow + h2 + lead, align start/center, compact spacing), `FramedImage` (photo with a coloured offset block, sand by default, design `.about__media`), `CallToAction` (closing block: h2, lead, action; added in soorten-fotoshoots-page), `RichParagraph` (paragraph with inline links), `DeferredImage` (loads after page load and near the viewport, reserves space), `Reveal` (fade-in on scroll, content always in the DOM, reduced motion respected); gallery blocks from portfolio-page: `PortfolioGrid` (CSS-only masonry in reading order, first 3 photos eager), `Lightbox` (Chakra `Dialog`, wrap-around browsing, keys, swipe, preloading, load-error note), `FilterBar` (toggle buttons, `filterControl` recipe)
|
||||
- **Responsibilities**: `PageSection` (section frame: `aria-labelledby`, tone `paper`/`alt`, width `default`/`narrow`/`full`, spacing `default`/`tight`/`flushTop`, anchor offset), `MediaText` (framed photo next to a text column, design `.about`), `Eyebrow` (accent label, optionally a heading), `SectionHeading` (eyebrow + h2 + lead, align start/center, compact spacing; the h2 in letter-spaced capitals via the `sectionHeading` text style, testimonials-redesign), `FramedImage` (photo with a coloured offset block, sand by default, design `.about__media`), `CallToAction` (closing block: h2, lead, action; added in soorten-fotoshoots-page), `RichParagraph` (paragraph with inline links), `DeferredImage` (loads after page load and near the viewport, reserves space), `Reveal` (fade-in on scroll, content always in the DOM, reduced motion respected); gallery blocks from portfolio-page: `PortfolioGrid` (CSS-only masonry in reading order, first 3 photos eager), `Lightbox` (Chakra `Dialog`, wrap-around browsing, keys, swipe, preloading, load-error note), `FilterBar` (toggle buttons, `filterControl` recipe)
|
||||
- **Type**: Application (shared UI)
|
||||
|
||||
### components/PageIntro/, StatusPage/
|
||||
@@ -103,7 +103,7 @@ Text alternative: client.tsx starts Sentry and hydrates the prerendered page (pr
|
||||
|
||||
### lib/
|
||||
- **Purpose**: Pure, fully tested helpers
|
||||
- **Responsibilities**: `emailAddress`, `visibleSocials`, `copyrightLine`, `slidesToLoad`, `backToTopThreshold`, `slideLabel`, `formatPrice`, `bookLabel`, `visiblePackages`, `visibleTestimonials`, `packageFromSearch`, `shootOptions`, `mailLink`, `validateContact`, `isLikelySpam`, `toContactPayload`, `contactFormReducer`
|
||||
- **Responsibilities**: `emailAddress`, `visibleSocials`, `copyrightLine`, `slidesToLoad`, `backToTopThreshold`, `slideLabel`, `slideCounter`, `normalizeImagePosition`, `formatPrice`, `bookLabel`, `visiblePackages`, `visibleTestimonials`, `packageFromSearch`, `shootOptions`, `mailLink`, `validateContact`, `isLikelySpam`, `toContactPayload`, `contactFormReducer`
|
||||
- **Type**: Application (utility, 100% coverage threshold)
|
||||
|
||||
### hooks/
|
||||
|
||||
@@ -27,7 +27,7 @@ Text alternative: visitors and crawlers use the website, which links out to soci
|
||||
## Business Description
|
||||
- **Business Description**: Portfolio and marketing website for Andrea Slop Fotografie, a lifestyle photographer in Huizen (NL). It presents her work (loveshoots, family, pregnancy and newborn shoots), tells who she is, lists shoot types and prices, and gets prospective clients to make contact. It will replace the existing WordPress (Solene theme) site at andreaslop.nl; a test build runs at test.andreaslop.nl.
|
||||
- **Business Transactions** (current state — front-end only, no back-end):
|
||||
- **Browse the homepage** — hero slider with featured photos (autoplay, arrows, swipe, pause button, screen reader announcements), call-to-action to "Over mij"; below it Lifestyle fotografie (photo gallery), Over mij (intro + "Lees mijn verhaal" → `/over-mij`), Prijzen (packages), Lieve woorden (testimonials carousel), Contact and Instagram
|
||||
- **Browse the homepage** — hero slider with featured photos (autoplay, arrows, swipe, pause button, screen reader announcements), call-to-action to "Over mij"; below it Lifestyle fotografie (photo gallery), Over mij (intro + "Lees mijn verhaal" → `/over-mij`), Prijzen (packages), Lieve woorden (testimonials carousel: arrows, a "X / Y" counter and swipe, no autoplay), Contact and Instagram
|
||||
- **Choose a package** — "Boek" on a price card scrolls to Contact with that shoot preselected (`?pakket=`)
|
||||
- **Contact the photographer** — contact form (validation, anti-spam) shown dimmed under a "coming soon" notice until the API exists; mailto fallback with a subject
|
||||
- **Navigate between pages** — header navigation (desktop), full-screen menu (mobile), footer menu, skip link, back-to-top button
|
||||
|
||||
Reference in New Issue
Block a user