UNPKG

@alfresco/adf-core

Version:
45 lines (44 loc) 2.31 kB
/*! * @license * Copyright © 2005-2025 Hyland Software, Inc. and its affiliates. All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ import { OnInit } from '@angular/core'; import { UnsavedChangesDialogData } from './unsaved-changes-dialog.model'; import { MatCheckboxChange } from '@angular/material/checkbox'; import { UserPreferencesService } from '../../common'; import * as i0 from "@angular/core"; /** * Dialog which informs about unsaved changes. Allows discard them and proceed or close dialog and stop proceeding. * Can be customized with data object - UnsavedChangesDialogData. * If data.checkboxText is provided, checkbox will be displayed with the checkbox description. * If data.confirmButtonText is provided, it will be displayed on the confirm button. * If data.headerText is provided, it will be displayed as the header. * If data.descriptionText is provided, it will be displayed as dialog content. */ export declare class UnsavedChangesDialogComponent implements OnInit { data: UnsavedChangesDialogData; private userPreferencesService; dialogData: UnsavedChangesDialogData; constructor(data: UnsavedChangesDialogData, userPreferencesService: UserPreferencesService); ngOnInit(): void; /** * Sets 'unsaved_changes__modal_visible' checked state (true or false string) as new item in local storage. * * @param savePreferences - MatCheckboxChange object with information about checkbox state. */ onToggleCheckboxPreferences(savePreferences: MatCheckboxChange): void; static ɵfac: i0.ɵɵFactoryDeclaration<UnsavedChangesDialogComponent, never>; static ɵcmp: i0.ɵɵComponentDeclaration<UnsavedChangesDialogComponent, "adf-unsaved-changes-dialog", never, {}, {}, never, never, true, never>; }