import type Input from "./Input.js";

/** @since 5.1 */
export interface DocumentInputProperties extends Partial<Pick<DocumentInput, "maxFileSize">> {}

/**
 * The `DocumentInput` class defines a user interface for an input to which document files can be attached. This [AttachmentElement.input](https://developers.arcgis.com/javascript/latest/references/core/form/elements/AttachmentElement/#input) is used in [attachment elements](https://developers.arcgis.com/javascript/latest/references/core/form/elements/AttachmentElement/) that are set on the [Editor's `layerInfo.formTemplate`](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-editor/#layerInfos/) or a [feature layer's `formTemplate`](https://developers.arcgis.com/javascript/latest/references/core/layers/FeatureLayer/#formTemplate) and displayed within the [Editor](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-editor/).
 *
 * @since 5.1
 * @see [DocumentInput](https://developers.arcgis.com/javascript/latest/references/core/form/elements/inputs/attachments/DocumentInput/)
 * @example
 * // Creates a new DocumentInput for an attachment element within a form
 * const documentInput = new DocumentInput({
 *   maxFileSize: 500
 * });
 */
export default class DocumentInput extends Input {
  /** @since 5.1 */
  constructor(properties?: DocumentInputProperties);
  /**
   * Defines the maximum length of an attachment for this element in megabytes. If not specified, there is no maximum file size.
   *
   * @since 5.1
   */
  accessor maxFileSize: number | null | undefined;
  /**
   * The input type identifier.
   *
   * @since 5.1
   */
  get type(): "document";
}