import { IconValue, HintValue, FormFieldContent, FormFieldControl } from '../form-field.control'; /** * An enum that represents the operation action. */ export declare enum OperationAction { back = "back", cancel = "cancel", reset = "reset", delete = "delete", submit = "submit" } /** * Returns true if the control is disabled; otherwise, false. * This function returns false by definition, that is, the control is enabled. * @param sender Control that wants to know its disabled state. */ export declare function isDisabledDefault(sender: any): boolean; /** * This function does nothing by definition. * @param sender Control that was clicked. */ export declare function clickDefault(sender: any): void; /** * A base interface that represents the content of an `ActionControl`. */ export interface ActionContent extends FormFieldContent { /** * Returns the control's icon. * By default, its value is `undefined`. */ icon?: IconValue; /** * Returns the control's tooltip. * By default, its value is `undefined`. */ tooltip?: HintValue; /** * Returns the function that is executed for knowing if the control is or is not disabled. * By default, its value is `isDisabledDefault`. */ isDisabled?: (sender: any) => boolean; /** * Returns the function that is executed when the user clicks the control. * By default, its value is `clickDefault`. */ click?: (sender: any) => void; } /** * Represents the base abstract class for a control that executes actions. */ export declare abstract class ActionControl extends FormFieldControl { /** * Input field that contains the content of this class. */ content: ActionContent; /** * Constructs a new instance of this class. */ constructor(); /** * Initializes the `content` input property. * @param label The default label to use. It is used if the `content.label` is not specified. * @param placeholder It is NOT used here. Fix that. * @param alwaysHint If it is true then there is always a hint start-aligned. */ protected init(label: string, placeholder?: string, alwaysHint?: boolean): void; /** * Initializes the control's value. It uses the `content.value` and it is already different of `undefined`. * It also checks if the specified `content.value` is correct. For internal use only. */ protected initValue(): void; /** * Returns this instance. */ readonly getInstance: ActionControl; }