import type InputBase from "./InputBase.js";
import type { InputBaseProperties } from "./InputBase.js";
import type { GroupableInput } from "./types.js";

export interface GroupInputProperties extends InputBaseProperties, Partial<Pick<GroupInput, "open">> {}

/**
 * This is a support class that represents a group of batch attribute form inputs.
 *
 * @since 4.33
 * @see [BatchAttributeForm](https://developers.arcgis.com/javascript/latest/api-reference/esri-widgets-BatchAttributeForm.html)
 * @see [BatchAttributeFormViewModel](https://developers.arcgis.com/javascript/latest/api-reference/esri-widgets-BatchAttributeForm-BatchAttributeFormViewModel.html)
 * @see [FieldInput](https://developers.arcgis.com/javascript/latest/api-reference/esri-widgets-BatchAttributeForm-inputs-FieldInput.html)
 * @see [TextElementInput](https://developers.arcgis.com/javascript/latest/api-reference/esri-widgets-BatchAttributeForm-inputs-TextElementInput.html)
 */
export default abstract class GroupInput extends InputBase<any> {
  /** An array of [field inputs](https://developers.arcgis.com/javascript/latest/api-reference/esri-widgets-BatchAttributeForm-inputs-FieldInput.html) and [text element inputs](https://developers.arcgis.com/javascript/latest/api-reference/esri-widgets-BatchAttributeForm-inputs-TextElementInput.html) contained within the group. */
  get inputs(): ReadonlyArray<GroupableInput>;
  /**
   * Indicates whether the group should be expanded or collapsed.
   *
   * @default true
   */
  accessor open: boolean;
  /**
   * The type of input.
   *
   * @default "group"
   */
  get type(): "group";
  /**
   * Indicates whether the GroupInput is visible. For this property to be true,
   * the group, itself, must be visible _and_ contain at least one child input
   * that is visible.
   */
  get visible(): boolean;
}