/** * Shared models for the reusable Home Group Selection dialog (SP3M-18). * * The dialog is generic and feature-agnostic: all display text is supplied by * the calling feature library (e.g. attendance, attendees) via MAT_DIALOG_DATA, * so this presentation-layer component never depends on any feature's constants. */ /** * A single selectable Working Group in the home-group selection dialog. * Mirrors the backend HomeGroupOption ({ groupId, groupName }). */ export interface QualifyingGroup { groupId: string; groupName: string; } /** * The homeGroupSelectionPrompt object returned by the attendance log-in APIs * when the user qualifies for reciprocal credit in more than one home group. * Mirrors HomeGroupSelectionPromptResponse from the attendee-api. */ export interface HomeGroupSelectionPrompt { eventId: string; qualifyingGroups: QualifyingGroup[]; } /** * Data passed to the HomeGroupSelectionComponent via MAT_DIALOG_DATA. * All text is provided by the caller so the component stays generic. */ export interface HomeGroupSelectionData { /** Qualifying home groups the user must choose between. */ qualifyingGroups: QualifyingGroup[]; /** Dialog title. */ title: string; /** First instruction paragraph (context). */ messageLine1: string; /** Second instruction paragraph (the "please select" prompt). */ messageLine2: string; /** Informational note shown in the footer banner. */ infoText: string; /** Submit button label. */ submitLabel: string; /** Cancel button label. */ cancelLabel: string; /** Accessibility label for the radio group. */ groupOptionAriaLabel: string; } /** * Result returned by HomeGroupSelectionComponent when the user clicks Submit. * `null` is returned when the user cancels. */ export interface HomeGroupSelectionResult { homeGroupId: string; }