# Code Summary — Unit 1: Shared blocks Plan: [shared-blocks-code-generation-plan.md](../../plans/shared-blocks-code-generation-plan.md). Requirements: FR-OM-09, FR-OM-10, NFR-OM-02, NFR-OM-03. ## Created - `web/src/components/Eyebrow/Eyebrow.tsx` — accent label (`textStyle="eyebrow"`, `accent.deep`, `mb={4}`), `as` prop for `p`/`span`/`h2`–`h4`, other `TextProps` pass through - `web/src/components/Eyebrow/Eyebrow.test.tsx` — paragraph by default; as h3 a heading that names a region; props pass through; axe - `web/src/components/MediaText/MediaText.tsx` — framed photo next to a text column (`children`), stacked below `lg`, both columns in `Reveal` - `web/src/components/MediaText/MediaText.test.tsx` — photo and text shown, photo first in DOM order; axe ## Renamed and modified - `web/src/components/HomeSection/HomeSection.tsx` → `web/src/components/PageSection/PageSection.tsx` — renamed component/props; new `spacing="flushTop"` (no top padding, bottom padding as default) - `HomeSection.test.tsx` → `PageSection.test.tsx` — renamed; new case for `flushTop` ## Modified - `components/SectionHeading/SectionHeading.tsx`, `components/PageIntro/PageIntro.tsx`, `components/ContactForm/ContactFormGate.tsx`, `components/home/Testimonials/TestimonialSlide.tsx` — inline label replaced by `Eyebrow` (contrast comment now lives in `Eyebrow`) - `components/home/AboutBlock/AboutBlock.tsx` — uses `PageSection` + `MediaText` - `components/home/{ContactSection,InstagramGrid,IntroGallery,Pricing/Pricing,Testimonials/Testimonials}.tsx` — import `PageSection` - `aidlc-docs/_shared/reverse-engineering/*.md` — names updated (`PageSection`, `MediaText`, `Eyebrow`); `HomeSection` debt item removed ## Verification - **Leftovers**: no `HomeSection` in `web/` source, tests or comments - **`pnpm check`**: lint, format, typecheck/build, 55 test files / 250 tests, coverage thresholds, audits — passed. Lighthouse failed in the first run (mobile performance `/` 0.71, `/over-mij` 0.87) because a second production build was running at the same time on the same machine; rerun alone: passed — mobile `/` 0.82 (budget 0.8), other pages 0.94–0.95; desktop 0.99–1; accessibility 1 everywhere - **Homepage unchanged**: master and branch production builds compared in headless Chrome at 1440, 768 and 390 px (reduced motion, after scrolling through the page): tag, ids, `aria-labelledby`, alt, text, position, size and 21 computed styles of every element in `
` — 233/233 elements identical on `/`, identical on `/over-mij` and `/contact` (placeholders with `PageIntro`). The same comparison of master against itself is also identical, so the method is stable. (Byte-for-byte screenshots were not usable: they already differ between two runs of master, through image loading and timing.) ## Extension Compliance | Rule | Status | Rationale | |---|---|---| | SECURITY-10 | Compliant | No new dependencies | | Other SECURITY rules | N/A | Presentational refactor only | | PBT-01..10 | N/A | No pure functions or business logic in this unit |