UNPKG

@mescius/dspdfviewer

Version:
46 lines (45 loc) 1.64 kB
//@ts-ignore import React, { Component } from 'react'; import { WidgetAnnotation, ButtonWidget } from "../Annotations/AnnotationTypes"; import { FormFillerProps, FormFillerModel, FieldMappingStub } from './types'; import { FormFieldMapping } from '../ViewerOptions'; export declare class FormFiller extends Component<FormFillerProps, FormFillerModel> { private _mounted; private _outerElement; private _pendingInvalidFocus; private _autofocusFieldId?; private _pendingAutofocus; constructor(props: FormFillerProps, state: any); componentDidMount(): void; componentWillUnmount(): void; componentDidUpdate(): void; showValidationMessages(): void; //@ts-ignore //@ts-ignore render(): React.JSX.Element; readInitialFieldsState(): FormFillerModel; createFieldStub(fieldName: string, mapping: FormFieldMapping): FieldMappingStub; reset(): void; get isMounted(): boolean; raiseOnInitialize(): void; /** * Get field by its name. * @param fieldName */ getFieldByName(fieldName: string): (WidgetAnnotation | FieldMappingStub) | undefined; /** * This method need to be called when field is changed. * @param changedField */ onFieldChanged(changedField: WidgetAnnotation): void; onBeforeRadioButtonChange(radioButton: ButtonWidget, changedFields: WidgetAnnotation[]): boolean; /** * Validate form fields. * Returns true on success. * */ validateFields(): boolean; autoFocus(): void; private _autoFocus; private _focusInvalid; private _focusFieldControl; }