export const MACHINE_CATEGORIES = [ 'Engines', 'Gearboxes & Drives', 'Pumps & Fluid Systems', 'Mechanisms', 'Structural / Other' ] as const; export type MachineCategory = (typeof MACHINE_CATEGORIES)[number]; export const DIFFICULTIES = ['Beginner', 'Intermediate', 'Advanced'] as const; export type Difficulty = (typeof DIFFICULTIES)[number]; export const RELEASE_PHASES = ['core', 'stretch'] as const; export type ReleasePhase = (typeof RELEASE_PHASES)[number]; export const SORT_OPTIONS = [ { value: 'name', label: 'Name A–Z', description: 'Alphabetical by machine title' }, { value: 'newest', label: 'Newest', description: 'Most recently added to the reference catalogue' }, { value: 'complexity', label: 'Complexity', description: 'Highest engineering complexity first' } ] as const; export type SortKey = (typeof SORT_OPTIONS)[number]['value']; export const CATALOGUE_VIEW_MODES = ['comfortable', 'compact'] as const; export type CatalogueViewMode = (typeof CATALOGUE_VIEW_MODES)[number]; export type ThumbnailVariant = | 'inline-engine' | 'vee-engine' | 'rotary' | 'turbine' | 'geartrain' | 'pump' | 'mechanism' | 'bearing' | 'brake' | 'electric' | 'fluid'; export interface ThumbnailConfig { readonly variant: ThumbnailVariant; readonly accent: string; readonly secondary?: string; readonly background?: string; } export interface MachineFact { readonly label: string; readonly value: string; readonly unit?: string; readonly tone?: 'neutral' | 'accent' | 'warm' | 'success' | 'warning'; } export interface MachinePart { readonly id: string; readonly name: string; readonly description: string; readonly material?: string; readonly function?: string; readonly defaultVisible?: boolean; readonly defaultOpacity?: number; readonly specs?: readonly MachineFact[]; } export interface MachineRegistryItem { readonly id: string; readonly slug: string; readonly title: string; readonly subtitle: string; readonly shortDescription: string; readonly description: string; readonly category: MachineCategory; readonly difficulty: Difficulty; readonly releasePhase: ReleasePhase; readonly publishedAt: string; readonly complexity: number; readonly estimatedPartCount: number; readonly tags: readonly string[]; readonly keywords: readonly string[]; readonly thumbnail: ThumbnailConfig; readonly facts: readonly MachineFact[]; readonly parts: readonly MachinePart[]; readonly applications: readonly string[]; readonly learningObjectives: readonly string[]; readonly relatedSlugs: readonly string[]; } export interface CatalogueFilters { readonly query: string; readonly categories: readonly MachineCategory[]; readonly difficulties: readonly Difficulty[]; readonly phases: readonly ReleasePhase[]; readonly sort: SortKey; readonly favouritesOnly: boolean; }