Adds the Lifestyle fotografie section to the homepage
Adds the first block below the hero: heading, intro and a staggered gallery of four live photos. Brings in the shared section building blocks (HomeSection, SectionHeading, Reveal) and DeferredImage, which holds back below-the-fold photos until the page has loaded so they do not compete with the hero for bandwidth. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -121,6 +121,29 @@ describe('app', () => {
|
||||
});
|
||||
});
|
||||
|
||||
describe('homepage', () => {
|
||||
it('shows the sections below the hero in page order', async () => {
|
||||
const { container } = await renderApp('/');
|
||||
const hero = await screen.findByRole('region', {
|
||||
name: 'Uitgelicht werk',
|
||||
});
|
||||
const sections = [
|
||||
screen.getByRole('region', { name: 'Lifestyle fotografie' }),
|
||||
];
|
||||
|
||||
let previous: Element = hero;
|
||||
for (const section of sections) {
|
||||
expect(
|
||||
previous.compareDocumentPosition(section) &
|
||||
Node.DOCUMENT_POSITION_FOLLOWING,
|
||||
).toBeTruthy();
|
||||
previous = section;
|
||||
}
|
||||
expect(screen.getAllByRole('heading', { level: 1 })).toHaveLength(1);
|
||||
expect(await axeResults(container)).toHaveNoViolations();
|
||||
});
|
||||
});
|
||||
|
||||
describe('pagina-register', () => {
|
||||
it('bevat precies de routes van de route tree', async () => {
|
||||
const { router } = await renderApp('/');
|
||||
|
||||
Reference in New Issue
Block a user