import { EventEmitter, NgZone, OnDestroy, OnInit } from '@angular/core'; import { Observable } from 'rxjs'; import { Ref } from '../ref'; import { NgtComponentStore } from '../stores/component-store'; import { NgtStore } from '../stores/store'; import type { AttachFunction, BooleanInput, NgtInstanceInternal, NgtUnknownInstance, UnknownRecord } from '../types'; import * as i0 from "@angular/core"; export interface NgtInstanceState { instance: Ref; instanceArgs: unknown[]; attach: string[] | AttachFunction; attachExplicit?: boolean; noAttach: boolean; noAttachExplicit?: boolean; skipParent: boolean; skipParentExplicit?: boolean; [option: string]: any; } export declare abstract class NgtInstance = NgtInstanceState> extends NgtComponentStore implements OnInit, OnDestroy { private skipSelfStore; set ref(ref: Ref); set skipParent(skipParent: BooleanInput); get skipParent(): BooleanInput; ready: EventEmitter; protected hasEmittedAlready: boolean; update: EventEmitter; set noAttach(noAttach: BooleanInput); get noAttach(): BooleanInput; set attach(value: string | string[] | AttachFunction | undefined); get attach(): string | string[] | AttachFunction | undefined; readonly instance$: Observable; get instance(): Ref; get instanceValue(): TInstance; get __ngt__(): NgtInstanceInternal; get parent(): Ref; protected readonly instanceArgs$: Observable; set instanceArgs(v: unknown | unknown[]); get instanceArgs(): unknown | unknown[]; protected zone: NgZone; protected store: NgtStore; protected document: Document; protected parentRef: import("../types").AnyFunction>; protected parentHostRef: import("../types").AnyFunction>; constructor(skipSelfStore?: boolean); ngOnInit(): void; /** * Sub-classes can use this function to run pre-init logic * @protected */ protected preInit(): void; /** * Sub-classes can choose to run additional logic after init * @protected */ protected postInit(): void; protected emitReady(): void; protected isPrimitive: boolean; protected isWrapper: boolean; protected isRaw: boolean; prepareInstance(instance: TInstance, uuid?: string): NgtUnknownInstance; /** * Sub-classes can use this to modify the constructor parameters * before calling this.prepareInstance */ protected adjustCtorParams(instanceArgs: unknown[]): unknown[]; /** * Sub-classes, if adjust CtorParams, can also use ctorParams$ to ensure ctor is re-invoked */ protected get ctorParams$(): Observable<{}>; protected destroy(): void; /** * Can be used by sub-classes to run additional logic after prepare * @protected */ protected postPrepare(_: TInstance): void; protected get optionFields(): Record; ngOnDestroy(): void; private readonly instanceReady; /** * Can be used by sub-classes to run additional logic after options are set * @protected */ protected postSetOptions(_: TInstance): void; /** * Sub-classes can customize this to run setOptions on custom trigger * @protected */ protected get setOptionsTrigger$(): Observable<{}>; private readonly setOptions; private attachToParent; static ɵfac: i0.ɵɵFactoryDeclaration, [{ optional: true; }]>; static ɵdir: i0.ɵɵDirectiveDeclaration, never, never, { "ref": "ref"; "skipParent": "skipParent"; "noAttach": "noAttach"; "attach": "attach"; }, { "ready": "ready"; "update": "update"; }, never, never, false>; } export declare const provideNgtInstance: (sub: import("../types").AnyCtor) => any[];