import { BasicType, Variable, ObjectData, InstructionType, Tag, Scope, Instruction } from '@cyklang/core'; import { ComponentModel } from './cykLang'; import { Ref, WritableComputedRef } from 'vue'; import { WindowManager } from './WindowManager'; declare class VarListener { variable: Variable; initialValue: BasicType; initialVariable: Variable; label: string; constructor(variable: Variable, label: string); } /** * */ type DirtyListener = () => void; /** * */ export declare class DirtyManager { isNewRecord: boolean; formData: ObjectData; varDirty: Variable; varListeners: VarListener[]; dirtyRefs: Ref[]; dirtyListeners: DirtyListener[]; constructor(formData: ObjectData, isNewRecord?: boolean); registerVariable(variable: Variable, label: string): void; variableChanged(variable?: Variable): void; registerDirtyRef(dirtyRef: Ref): void; unregisterDirtyRef(dirtyRef: Ref): void; resetDirty(): void; addDirtyListener(dirtyListener: DirtyListener): void; removeDirtyListener(dirtyListener: DirtyListener): void; isDirty(): boolean; } export declare class VariableReact { namedComponents: NamedComponents; constructor(); addNamedComponent(namedComponent: NamedComponent): void; removeNamedComponent(namedComponent: NamedComponent): void; sendEvent(componentName: string, event: string): void; } export declare class NamedComponent { name: string; sendEvent: (event: string) => void; constructor(name: string, sendEvent: (event: string) => void); } declare class NamedComponents { stack: NamedComponent[]; constructor(); hasNamedComponent(name: string): boolean; addNamedComponent(namedComponent: NamedComponent): void; removeNamedComponent(namedComponent: NamedComponent): void; sendEvent(componentName: string, event: string): void; } /** * * @param dataType * @param componentArg * @param defaultValue */ export declare function componentModelParameter(componentArg: ComponentModel | undefined, name: string, defaultValue: type): WritableComputedRef; /** * */ export declare class ComponentModelParameter { model: Ref; private variable; private variableListener; constructor(componentArg: ComponentModel | undefined, name: string, defaultValue: type); /** * */ destroy(): void; } /** * */ export declare class ComponentParameter { model: Ref; private variable; private variableListener; constructor(variable: Variable, defaultValue: type); /** * */ destroy(): void; } /** * */ export declare class NotifyChangeInstructionType extends InstructionType { windowManager: WindowManager; constructor(windowManager: WindowManager); parseInstruction(tag: Tag, scope: Scope): Promise; } export {};