import { OnInit } from '@angular/core'; import { MatDialogRef } from '@angular/material/dialog'; import { CreditSelectionData, CreditSelectionTimeslotOption } from '../../models/credit-selection.model'; import * as i0 from "@angular/core"; /** * CreditSelectionComponent is a generic, reusable dialog shown when the * attendance log-in APIs (Pass 1) return a non-null creditSelectionPrompt. * * For each timeslot the user must choose which meeting receives attendance * credit — the prior (credit-holding) meeting or the target meeting being * attended. The prior meeting is pre-selected per timeslot. Save is enabled * only when every timeslot has a selection (the backend rejects partial * submissions). * * Footer (SP3M-677 — no Cancel button; the dialog is non-dismissable and a * valid meeting is always pre-selected, so credit is resolved via Save): * - Save → closes with { creditSelections: [{ timeslotId, creditedMeetingId }] } * * This component is feature-agnostic — all display text is supplied by the * caller via MAT_DIALOG_DATA (CreditSelectionData). It performs no API calls; * it collects selections and returns them so the caller can re-submit Pass 2. * @export * @class CreditSelectionComponent * @implements {OnInit} */ export declare class CreditSelectionComponent implements OnInit { data: CreditSelectionData; private dialogRef; /** Timeslots the user must resolve, each with prior/target meeting options. */ timeslotOptions: CreditSelectionTimeslotOption[]; /** Map of timeslotId → selected creditedMeetingId. */ selections: Record; constructor(data: CreditSelectionData, dialogRef: MatDialogRef); ngOnInit(): void; /** * trackBy for the timeslot list. * @param {number} _index * @param {CreditSelectionTimeslotOption} timeslot * @return {string} * @memberof CreditSelectionComponent */ trackByTimeslotId(_index: number, timeslot: CreditSelectionTimeslotOption): string; /** * Whether Save should be enabled — true once every timeslot has a selection. * @return {boolean} * @memberof CreditSelectionComponent */ get canSave(): boolean; /** * Save handler — builds one entry per timeslot and closes with the result. * No-ops if any timeslot is unselected (backend rejects partial submissions). * @memberof CreditSelectionComponent */ onSave(): void; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; }