import { FormRenderer } from "./FormRenderer"; import type { defs } from "./FormRenderer"; import type { IActivityHandler, IActivityContext } from "../../IActivityHandler"; /** Defines the inputs for a display form activity. */ export interface DisplayFormInputs { /** Indicates a name of the form (local to the running workflow). */ name: string; /** Indicates the form resource to load if not yet loaded. */ form: defs.Form; /** Indicates the form template to load if not yet loaded. */ template?: defs.Form; container?: "default" | "modal" | string; /** Indicates what region to use when activating the form's container. */ region?: string; /** Indicates that the form should be reset. */ reset?: boolean; } /** * Defines the outputs for a display form activity. * @public */ export interface DisplayFormOutputs { /** @description The result of the form. */ result?: string; /** @description The state of the form. Use this to update or access the values of form elements. */ state: Record; } export declare class DisplayForm implements IActivityHandler { static readonly action = "gcx:wf:forms:form:DisplayForm"; static renderers: Record; static readonly suite = "gcx:wf:builtin"; /** * Creates a form renderer if it does not exist. * @param inputs The inputs to create the renderer. * @param context The context to use to create the renderer. * @param FormRendererType The type of FormRenderer (subclass) to create. */ static createRenderer(inputs: DisplayFormInputs, context: IActivityContext, FormRendererType: typeof FormRenderer): FormRenderer; /** * Updates the references in the `ElementMap` for all of the elements * contained in `displayFormOutputs`. * @param displayFormOutputs The outputs of the `DisplayForm` activity. */ private static updateElementMap; /** Performs the operation on behalf of the engine. */ execute(inputs: DisplayFormInputs, context: IActivityContext, type: typeof FormRenderer): Promise; }