/*! * @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 { HttpClient } from '@angular/common/http'; import { Observable, ReplaySubject } from 'rxjs'; import { ExtensionConfig, ExtensionService } from '@alfresco/adf-extensions'; import { OpenidConfiguration } from '../auth/interfaces/openid-configuration.interface'; import { OauthConfigModel } from '../auth/models/oauth-config.model'; import * as i0 from "@angular/core"; export declare const AppConfigValues: { readonly APP_CONFIG_LANGUAGES_KEY: "languages"; readonly PROVIDERS: "providers"; readonly OAUTHCONFIG: "oauth2"; readonly ECMHOST: "ecmHost"; readonly BASESHAREURL: "baseShareUrl"; readonly OOI_CONNECTOR_URL: "ooiServiceUrl"; readonly BPMHOST: "bpmHost"; readonly IDENTITY_HOST: "identityHost"; readonly AUTHTYPE: "authType"; readonly CONTEXTROOTECM: "contextRootEcm"; readonly CONTEXTROOTBPM: "contextRootBpm"; readonly ALFRESCO_REPOSITORY_NAME: "alfrescoRepositoryName"; readonly LOG_LEVEL: "logLevel"; readonly LOGIN_ROUTE: "loginRoute"; readonly DISABLECSRF: "disableCSRF"; readonly AUTH_WITH_CREDENTIALS: "auth.withCredentials"; readonly APPLICATION: "application"; readonly STORAGE_PREFIX: "application.storagePrefix"; readonly NOTIFY_DURATION: "notificationDefaultDuration"; readonly CONTENT_TICKET_STORAGE_LABEL: "ticket-ECM"; readonly PROCESS_TICKET_STORAGE_LABEL: "ticket-BPM"; readonly UNSAVED_CHANGES_MODAL_HIDDEN: "unsaved_changes__modal_hidden"; }; export type AppConfigValues = (typeof AppConfigValues)[keyof typeof AppConfigValues]; export declare const Status: { readonly INIT: "init"; readonly LOADING: "loading"; readonly LOADED: "loaded"; }; export type Status = (typeof Status)[keyof typeof Status]; export declare class AppConfigService { protected http: HttpClient; protected extensionService: ExtensionService; config: any; status: Status; protected onLoadSubject: ReplaySubject; onLoad: Observable; get isLoaded(): boolean; constructor(); /** * Requests notification of a property value when it is loaded. * * @param property The desired property value * @returns Property value, when loaded */ select(property: string): Observable; /** * Gets the value of a named property. * * @param key Name of the property * @param defaultValue Value to return if the key is not found * @returns Value of the property */ get(key: string, defaultValue?: T): T; /** * Gets the location.protocol value. * * @returns The location.protocol string */ getLocationProtocol(): string; /** * Gets the location.hostname property. * * @returns Value of the property */ getLocationHostname(): string; /** * Gets the location.port property. * * @param prefix Text added before port value * @returns Port with prefix */ getLocationPort(prefix?: string): string; protected onLoaded(): void; protected onDataLoaded(): void; protected onExtensionsLoaded(config: ExtensionConfig): void; /** * Loads the config file. * * @param callback an optional callback to execute when configuration is loaded * @returns Notification when loading is complete */ load(callback?: (...args: any[]) => any): Promise; /** * Call the discovery API to fetch configuration * * @param hostIdp host address * @returns Discovery configuration */ loadWellKnown(hostIdp: string): Promise; /** * OAuth2 configuration * * @returns auth config model */ get oauth2(): OauthConfigModel; private formatString; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵprov: i0.ɵɵInjectableDeclaration; }