import { EventEmitter, ChangeDetectorRef, ViewContainerRef, OnDestroy, AfterViewInit } from '@angular/core'; import { MJDashboardPartTypeEntity } from '@memberjunction/core-entities'; import { PanelConfig, DashboardPanel } from '../../models/dashboard-types'; import { ConfigPanelResult } from '../../config-panels/base-config-panel'; import * as i0 from "@angular/core"; /** * Result from the edit part dialog */ export interface EditPartDialogResult { /** The updated panel configuration */ Config: PanelConfig; /** Updated title */ Title: string; /** Updated icon (optional) */ Icon?: string; } /** * Generic dialog for editing dashboard part configuration. * * This dialog dynamically loads the appropriate config panel based on the * DashboardPartType.ConfigDialogClass field, using MJGlobal.ClassFactory. * * This allows new part types to be added without modifying this dialog - * just create a config panel, register it, and set the ConfigDialogClass. */ export declare class EditPartDialogComponent implements OnDestroy, AfterViewInit { private cdr; /** * Whether the dialog is visible */ set Visible(value: boolean); get Visible(): boolean; private _visible; /** * The part type being configured */ PartType: MJDashboardPartTypeEntity | null; /** * The panel being edited */ Panel: DashboardPanel | null; /** * The current configuration */ Config: PanelConfig | null; /** * Emitted when configuration is saved */ Saved: EventEmitter; /** * Emitted when dialog is cancelled */ Cancelled: EventEmitter; /** * Container for dynamically loaded config panel */ configPanelContainer: ViewContainerRef; /** * Reference to the dynamically created config panel component */ private configPanelRef; /** * Track validity from the embedded panel */ IsValid: boolean; /** * Store the latest result from the panel */ private latestResult; /** * Error message if panel failed to load */ LoadError: string | null; /** * Whether the panel is loading */ IsLoading: boolean; private viewInitialized; constructor(cdr: ChangeDetectorRef); ngAfterViewInit(): void; ngOnDestroy(): void; /** * Called when dialog opens */ private onDialogOpened; /** * Called when dialog closes */ private onDialogClosed; /** * Dynamically load the config panel component */ private loadConfigPanel; /** * Destroy the dynamically created config panel */ private destroyConfigPanel; /** * Handle configuration changes from the embedded panel */ onConfigChanged(result: ConfigPanelResult): void; /** * Get the dialog title based on part type */ getDialogTitle(): string; /** * Get the part type icon */ getIcon(): string; /** * Save the configuration */ save(): void; /** * Cancel and close the dialog */ cancel(): void; /** * Get save button text */ getSaveButtonText(): string; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; } //# sourceMappingURL=edit-part-dialog.component.d.ts.map