import * as nt from 'noodl-types'; import type { LiteralUnion } from 'type-fest'; import type { OrArray } from '@jsmanifest/typefest'; import type NDOM from './noodl-ui-dom'; import type NDOMPage from './Page'; import * as t from '../types'; export default class NDOMResolver { createStyleEditor(component: t.NuiComponent.Instance): (styles: Record | undefined, { remove }?: { remove?: string | string[] | false; }) => void; getOptions = t.NDOMElement>(args: t.Resolve.BaseOptions & { on?: t.ResolveComponentOptions['on']; ndom: NDOM; }): { cache: { actions: import("..").ActionsCache & Record<"anonymous" | "goto" | "toast" | "evalObject" | "openCamera" | "openPhotoLibrary" | "openDocumentManager" | "pageJump" | "popUp" | "popUpDismiss" | "refresh" | "removeSignature" | "saveObject" | "saveSignature" | "getLocationAddress" | "updateGlobal" | "scanCamera" | "updateObject", t.Store.ActionObject<"anonymous" | "goto" | "toast" | "evalObject" | "openCamera" | "openPhotoLibrary" | "openDocumentManager" | "pageJump" | "popUp" | "popUpDismiss" | "refresh" | "removeSignature" | "saveObject" | "saveSignature" | "getLocationAddress" | "updateGlobal" | "scanCamera" | "updateObject", string>[]> & { builtIn: Map; emit: Map, t.Store.ActionObject[]>; register: Record; }; component: import("..").ComponentCache; page: import("..").PageCache; plugin: import("..").PluginCache; register: import("..").RegisterCache; transactions: import("..").TransactionsCache; timer: import("../cache/TimerCache").default; }; component: t.NuiComponent.Instance; createPage: NDOM["createPage"]; draw: NDOM["draw"]; editStyle: (styles: Record | undefined, { remove }?: { remove?: string | string[] | false; }) => void; findPage: NDOM["findPage"]; global: import("./Global").NDOMGlobal; on: any; node: N; nui: { _experimental: { readonly register: { (name: string, fn: t.Register.Object["fn"] | Partial, options?: Partial): t.Register.Object; (registerComponent: nt.RegisterComponentObject, options?: Partial | t.Register.Object["fn"]): t.Register.Object; }; }; readonly cache: { actions: import("..").ActionsCache & Record<"anonymous" | "goto" | "toast" | "evalObject" | "openCamera" | "openPhotoLibrary" | "openDocumentManager" | "pageJump" | "popUp" | "popUpDismiss" | "refresh" | "removeSignature" | "saveObject" | "saveSignature" | "getLocationAddress" | "updateGlobal" | "scanCamera" | "updateObject", t.Store.ActionObject<"anonymous" | "goto" | "toast" | "evalObject" | "openCamera" | "openPhotoLibrary" | "openDocumentManager" | "pageJump" | "popUp" | "popUpDismiss" | "refresh" | "removeSignature" | "saveObject" | "saveSignature" | "getLocationAddress" | "updateGlobal" | "scanCamera" | "updateObject", string>[]> & { builtIn: Map; emit: Map, t.Store.ActionObject[]>; register: Record; }; component: import("..").ComponentCache; page: import("..").PageCache; plugin: import("..").PluginCache; register: import("..").RegisterCache; transactions: import("..").TransactionsCache; timer: import("../cache/TimerCache").default; }; readonly clean: (page: import("..").Page, onClean?: (stats?: { componentsRemoved: number; }) => void) => void; readonly createGetter: (page?: import("..").Page) => (key?: string, { dataObject, iteratorVar, page: priorityPage, pageObject, }?: { dataObject?: any; iteratorVar?: string; page?: import("..").Page; pageObject?: nt.PageObject; }) => any; readonly createGoto: (fn: t.GotoFn) => (args: Parameters[0]) => any[]; readonly createComponent: (componentObject: t.NuiComponentType | t.NuiComponent.Instance | nt.ComponentObject | null | undefined, page: import("..").Page) => t.NuiComponent.Instance; createPage(args?: string | import("..").Page | t.NuiComponent.Instance | { name?: string; component?: t.NuiComponent.Instance; id?: string; onChange?: { id?: string; fn: (prev: string, next: string) => void; }; viewport?: import("..").Viewport | { width?: number; height?: number; }; }): import("..").Page; createPlugin(location?: t.Plugin.Location | t.Plugin.ComponentObject | t.NuiComponent.Instance, obj?: t.NuiComponent.Instance | t.Plugin.ComponentObject): t.Plugin.Object; createActionChain(trigger: t.NUITrigger, actions: OrArray, opts?: import("noodl-action-chain").ActionChainObserver & { component?: t.NuiComponent.Instance; context?: Record; on?: t.ResolveComponentOptions["on"]; loadQueue?: boolean; id?: string; page?: import("..").Page; }, id?: string): t.NUIActionChain; readonly createSrc: { (args: { key: string; value: nt.Path; component: t.NuiComponent.Instance; page: import("..").Page; }): Promise; (path: nt.Path, opts?: { component: t.NuiComponent.Instance; context?: Record; }): Promise; (path: nt.IfObject, opts?: { component?: t.NuiComponent.Instance; page?: import("..").Page; }): Promise; (path: string): Promise; }; readonly emit: { (opts?: t.NUIEmit.EmitRegister): Promise; (obj?: t.NUIEmit.EmitTransaction): Promise[0]>; }; getAssetsUrl: () => string; getActions: { (): import("..").ActionsCache; (actionType: "emit"): Map[]>; (actionType: "builtIn"): Map; (actionType: AType): t.Store.ActionObject[]; }; getBuiltIns: () => Map[]>; getBaseUrl: () => string; getBaseStyles(component: t.NuiComponent.Instance | Record, originalComponent?: t.NuiComponent.Instance | Record): any; getConsumerOptions({ callback, component, on, page, context, ...rest }: { callback?(component: t.NuiComponent.Instance): t.NuiComponent.Instance | undefined; component?: t.NuiComponent.Instance; on?: t.ResolveComponentOptions["on"]; page: import("..").Page; context?: Record; } & { [key: string]: any; }): { callback: ((component: t.NuiComponent.Instance) => t.NuiComponent.Instance | undefined) | undefined; cache: { actions: import("..").ActionsCache & Record<"anonymous" | "goto" | "toast" | "evalObject" | "openCamera" | "openPhotoLibrary" | "openDocumentManager" | "pageJump" | "popUp" | "popUpDismiss" | "refresh" | "removeSignature" | "saveObject" | "saveSignature" | "getLocationAddress" | "updateGlobal" | "scanCamera" | "updateObject", t.Store.ActionObject<"anonymous" | "goto" | "toast" | "evalObject" | "openCamera" | "openPhotoLibrary" | "openDocumentManager" | "pageJump" | "popUp" | "popUpDismiss" | "refresh" | "removeSignature" | "saveObject" | "saveSignature" | "getLocationAddress" | "updateGlobal" | "scanCamera" | "updateObject", string>[]> & { builtIn: Map; emit: Map, t.Store.ActionObject[]>; register: Record; }; component: import("..").ComponentCache; page: import("..").PageCache; plugin: import("..").PluginCache; register: import("..").RegisterCache; transactions: import("..").TransactionsCache; timer: import("../cache/TimerCache").default; }; component: t.NuiComponent.Instance | undefined; context: Record | undefined; createPage: (args?: string | import("..").Page | t.NuiComponent.Instance | { name?: string; component?: t.NuiComponent.Instance; id?: string; onChange?: { id?: string; fn: (prev: string, next: string) => void; }; viewport?: import("..").Viewport | { width?: number; height?: number; }; }) => import("..").Page; createActionChain(trigger: t.NUITrigger, actions: t.NUIActionObject | t.NUIActionObject[], { context: contextProp, loadQueue, }?: { context?: Record; loadQueue?: boolean; }, id?: string): t.NUIActionChain; createSrc(key: string, value: string | nt.IfObject | nt.EmitObjectFold): Promise; emit: { (opts?: t.NUIEmit.EmitRegister): Promise; (obj?: t.NUIEmit.EmitTransaction): Promise[0]>; }; getBaseStyles: any; getQueryObjects: (opts?: { component?: t.NuiComponent.Instance; page?: import("..").Page; queries?: () => Record | (() => Record)[]; listDataObject?: any; }) => any[]; on: t.On | undefined; page: any; resolveComponents: { , Context extends Record = Record>(opts: t.ResolveComponentOptions): Promise; , Context extends Record = Record>(component: C, page?: import("..").Page): Promise; , Context extends Record = Record>(component: C, options?: Omit, "component">): Promise; }; viewport: any; _experimental: { readonly register: { (name: string, fn: t.Register.Object["fn"] | Partial, options?: Partial): t.Register.Object; (registerComponent: nt.RegisterComponentObject, options?: Partial | t.Register.Object["fn"]): t.Register.Object; }; }; clean: (page: import("..").Page, onClean?: (stats?: { componentsRemoved: number; }) => void) => void; createGetter: (page?: import("..").Page) => (key?: string, { dataObject, iteratorVar, page: priorityPage, pageObject, }?: { dataObject?: any; iteratorVar?: string; page?: import("..").Page; pageObject?: nt.PageObject; }) => any; createGoto: (fn: t.GotoFn) => (args: Parameters[0]) => any[]; createComponent: (componentObject: t.NuiComponentType | t.NuiComponent.Instance | nt.ComponentObject | null | undefined, page: import("..").Page) => t.NuiComponent.Instance; createPlugin(location?: t.Plugin.Location | t.Plugin.ComponentObject | t.NuiComponent.Instance, obj?: t.NuiComponent.Instance | t.Plugin.ComponentObject): t.Plugin.Object; getAssetsUrl: () => string; getActions: { (): import("..").ActionsCache; (actionType: "emit"): Map[]>; (actionType: "builtIn"): Map; (actionType: AType): t.Store.ActionObject[]; }; getBuiltIns: () => Map[]>; getBaseUrl: () => string; getConsumerOptions({ callback, component, on, page, context, ...rest }: { callback?(component: t.NuiComponent.Instance): t.NuiComponent.Instance | undefined; component?: t.NuiComponent.Instance; on?: t.ResolveComponentOptions["on"]; page: import("..").Page; context?: Record; } & { [key: string]: any; }): any; getPlugins(location?: t.Plugin.Location): Map; getPages(): string[]; getPreloadPages(): string[]; getRoot(): Record; getRootPage(): import("..").Page; reset(): void; setLogLevel: (level: keyof import("loglevel").LogLevel) => void; use(args: t.UseArg): any; getSize(size: string, type: "height" | "width"): string; }; getPlugins(location?: t.Plugin.Location): Map; getPages(): string[]; getPreloadPages(): string[]; getRoot(): Record; getRootPage(): import("..").Page; readonly resolveComponents: { , Context extends Record = Record>(opts: t.ResolveComponentOptions): Promise; , Context extends Record = Record>(component: C, page?: import("..").Page): Promise; , Context extends Record = Record>(component: C, options?: Omit, "component">): Promise; }; reset(): void; setLogLevel: (level: keyof import("loglevel").LogLevel) => void; use(args: t.UseArg): any; getSize(size: string, type: "height" | "width"): string; }; readonly page: NDOMPage; redraw: NDOM["redraw"]; renderPage: NDOM["render"]; /** * REMINDER: This intentionally does not include componentsResolver due to * circular references/infinite loops */ readonly renderState: NDOM["renderState"]; resolvers: t.Resolve.Config[]; elementType: string; componentType: string; setAttr: (k: LiteralUnion, v: any) => void; setDataAttr: (dataAttr: LiteralUnion, v: string) => string; setStyleAttr: (k: K, v: any) => any; transact: NDOM["transact"]; }; run = t.NDOMElement>({ on, ndom, node, component, page, resolvers, }: Pick, 'node' | 'component'> & { on?: t.ResolveComponentOptions['on']; ndom: NDOM; page?: NDOMPage; resolvers: OrArray>; }): Promise; runOnly = t.NDOMElement>({ on, ndom, node, component, page, resolvers, resolveName, }: Pick, 'node' | 'component'> & { on?: t.ResolveComponentOptions['on']; ndom: NDOM; page?: NDOMPage; resolvers: OrArray>; resolveName: string; }): Promise; resolve = t.NDOMElement>(config: t.Resolve.Config, options: ReturnType): Promise; resolveCond(cond: t.Resolve.Config['cond'], options: ReturnType, callback: (options: ReturnType) => void): Promise; }