import { EventEmitter, OnDestroy, ComponentRef, AfterViewInit, NgZone, ChangeDetectorRef } from '@angular/core';
import { MatSelectChange } from '@angular/material/select';
import { Observable } from 'rxjs';
import { LfFieldMetadataConnectorService } from '../lf-field-metadata-connector.service';
import { LfFieldContainerDirective } from '../lf-field-container.directive';
import { LfFieldTemplateContainerService } from './lf-field-template-container.service';
import { LfFieldTemplateProviders } from './lf-field-template-container-types';
import { LfFieldInfo, TemplateFieldInfo, TemplateInfo, TemplateValue } from '../field-components/utils/lf-field-types';
import { LfFieldComponent } from '../field-components/lf-field/lf-field.component';
import { LfFieldMultivalueComponent } from '../field-components/lf-field-multivalue/lf-field-multivalue.component';
import { AppLocalizationService } from '@laserfiche/lf-ui-components/internal-shared';
import { DropDownState, TemplateState } from './lf-field-template-container-states';
import * as i0 from "@angular/core";
export declare class LfFieldTemplateContainerComponent extends LfFieldContainerDirective implements AfterViewInit, OnDestroy {
    /** @internal */
    metadataConnectorService: LfFieldMetadataConnectorService;
    /** @internal */
    private zone;
    /** @internal */
    private localizationService;
    /** @internal */
    private ref;
    templateSelectedChange: EventEmitter<number>;
    /** @internal */
    hideTemplate: boolean;
    /** @internal */
    availableTemplates: TemplateInfo[];
    /** @internal */
    loadedTemplates: boolean;
    /** @internal */
    templateFieldContainerService: LfFieldTemplateContainerService;
    /** @internal */
    templateErrorMessage: Observable<string> | undefined;
    /** @internal */
    readonly emptyTemplateName: Observable<string>;
    /** @internal */
    templateSelected: TemplateInfo | undefined;
    /** @internal */
    dynamicOptions: Map<number, string[][]>;
    /** @internal */
    private adhocFieldsSub;
    /** @internal */
    private adhocDialogOpenedSub;
    /** @internal */
    readonly AN_ERROR_OCCURED: Observable<string>;
    /** @internal */
    dropdownState: DropDownState;
    /** @internal */
    templateState: TemplateState;
    /** @internal */
    private readonly TEMPLATE_HAS_FAILED_TO_LOAD;
    /** @internal */
    constructor(
    /** @internal */
    metadataConnectorService: LfFieldMetadataConnectorService, 
    /** @internal */
    zone: NgZone, 
    /** @internal */
    localizationService: AppLocalizationService, 
    /** @internal */
    ref: ChangeDetectorRef);
    /** @internal */
    ngAfterViewInit(): void;
    /** @internal */
    ngOnDestroy(): void;
    initAsync: (providers: LfFieldTemplateProviders, templateIdentifier?: number | string) => Promise<void>;
    clearAsync: () => Promise<void>;
    getTemplateValue: () => TemplateValue | undefined;
    /** @internal */
    get isDropdownError(): boolean;
    /** @internal */
    get isDropdownLoading(): boolean;
    /** @internal */
    get isDropdownDefault(): boolean;
    /** @internal */
    get isTemplateLoading(): boolean;
    /** @internal */
    get isTemplateError(): boolean;
    /** @internal */
    get isTemplateDisplay(): boolean;
    /** @internal */
    private resetComponentValues;
    /** @internal */
    renderFieldsAsync(fieldInfos: (TemplateFieldInfo | LfFieldInfo)[]): Promise<void>;
    /** @internal */
    private initializeFieldGroupAsync;
    /** @internal */
    private addDefinitionToExistingGroup;
    /** @internal */
    private createAndAddNewGroupRef;
    /** @internal */
    private initializeFieldGroupComponentAsync;
    /** @internal */
    fieldComponentInitAsync(fieldComponentRef: ComponentRef<LfFieldComponent>, fieldInfo: LfFieldInfo, value: string): Promise<void>;
    /** @internal */
    multivalueComponentInitAsync(multivalueFieldComponentRef: ComponentRef<LfFieldMultivalueComponent>, fieldInfo: LfFieldInfo, values: string[]): Promise<void>;
    /** @internal */
    compareTemplateInfoFunc(object1: TemplateInfo, object2: TemplateInfo): boolean;
    /** @internal */
    onToggleDropdownAsync(open: boolean): Promise<void>;
    /** @internal */
    onTemplateChangedAsync(event: MatSelectChange): Promise<void>;
    /** @internal */
    private selectTemplateAsync;
    /** @internal */
    private updateTemplateFieldsAsync;
    /** @internal */
    private updateTemplateFieldInfoAsync;
    /** @internal */
    private getValueIfSingleOption;
    /** @internal */
    private updateAllFieldInfosFromServiceAsync;
    /** @internal */
    private getOrCreateDynamicOptions;
    /** @internal */
    onFieldValueChangedAsync(fieldValues: string[], lfFieldInfo: TemplateFieldInfo, indicesChanged?: number[]): Promise<void>;
    /** @internal */
    private addFieldOptionsForIndexAsync;
    /** @internal */
    private showLoader;
    /** @internal */
    private updateDynamicFieldsAsync;
    /** @internal */
    private getUpdatedChildValue;
    /** @internal */
    private getDynamicFieldValueOptionsAsync;
    /** @internal */
    private getRelevantValuesForIndex;
    /** @internal */
    private getDynamicFieldChildren;
    /** @internal */
    private getDynamicFieldValues;
    static ɵfac: i0.ɵɵFactoryDeclaration<LfFieldTemplateContainerComponent, never>;
    static ɵcmp: i0.ɵɵComponentDeclaration<LfFieldTemplateContainerComponent, "lf-field-template-container-component", never, { "initAsync": { "alias": "initAsync"; "required": false; }; "clearAsync": { "alias": "clearAsync"; "required": false; }; "getTemplateValue": { "alias": "getTemplateValue"; "required": false; }; }, { "templateSelectedChange": "templateSelectedChange"; }, never, never, false, never>;
}
