Skip to content
HomePagesHomePages template kit

PoiPhotoFixture

A POI's photo as a fixture states it: a dev media pack asset id plus the metadata a real row persists.

A POI’s photo as a fixture states it: a dev media pack asset id plus the metadata a real row persists.

Import from @homepages/template-kit/fixtures.

export type PoiPhotoFixture = {
photo_id: LibraryAssetId;
width: number;
height: number;
attribution: string;
};
  • photo_id is the dev-only half. In production a POI photo’s URL is signed from the row’s place_id at render time and the row carries no asset id at all; here the pack stands in for that, and the dev media resolver swaps photo_id for the url/responsive pair a resolved row carries — so a renderer sees the same shape either way. width/height are restated from the named asset and re-read from it at resolve time, so a wrong number here cannot reach a render.