/** Copy + route segment for Exxat One school-side primary-nav hubs (empty-state shells). */ export interface OneSchoolsHubMeta { title: string /** Meta line under the title (count, record ID, freshness). Omit it unless * the hub has a fact to show; never a blurb that restates the title. */ description?: string } /** * Titles only. The retired version of this file carried a sentence under every * one of these ("Browse published availability and submit slot applications to * partner sites."), which is the decorative description the copy rule bans. */ export const ONE_SCHOOLS_HUB_META: Record = { "explore-availability": { title: "Explore & apply", }, "wishlist-responses": { title: "Wishlist Responses", }, "activities-dashboard": { title: "Dashboard", }, "activities-requests": { title: "Requests", }, "activities-schedules": { title: "Schedules", }, reports: { title: "Reports", }, } export function oneSchoolsHubMetaForSegment(segment: string): OneSchoolsHubMeta { return ( ONE_SCHOOLS_HUB_META[segment] ?? { title: sentenceCaseSegment(segment), } ) } /** Slug to sentence case: `wishlist-responses` becomes `Wishlist responses`. */ function sentenceCaseSegment(segment: string): string { const words = segment.split("-").filter(Boolean) if (!words.length) return segment const [first, ...rest] = words return [first.charAt(0).toUpperCase() + first.slice(1), ...rest].join(" ") }