import type { PricingPackage, ShootType } from '../content/types.ts'; import type { RoutePath } from '../navigation.ts'; import type { PageMeta } from '../sitePages.ts'; import { shootPackage } from './shootPackage.ts'; // Where "Stuur een berichtje" goes: the contact page, with the shoot's // package preselected when that package is shown (BR-SF-01..03, FR-CP-09) export function shootContactLink( shoot: ShootType, packages: readonly PricingPackage[], ) { const pkg = shootPackage(shoot, packages); return pkg !== undefined ? { to: '/contact' as const, search: { pakket: pkg.id } } : { to: '/contact' as const }; } // "Bekijk meer …foto's": the portfolio filtered on this shoot type export function shootPortfolioLink(shoot: ShootType) { return { to: '/portfolio' as const, search: { shoot: shoot.id } }; } // The portfolio links only show once the portfolio page is live, so no // visitor lands on the placeholder (BR-SF-04) export function isPortfolioLive(pages: Record): boolean { return pages['/portfolio'].indexed; }