import type { JSONSupport } from "../../../../core/JSONSupport.js";

export interface OtherChoiceProperties extends Partial<Pick<OtherChoice, "fieldName" | "hint" | "label">> {}

/**
 * Defines the configuration for the `other` choice in a [MultipleChoiceInput](https://developers.arcgis.com/javascript/latest/references/core/form/elements/inputs/MultipleChoiceInput/).
 *
 * @since 5.1
 */
export default class OtherChoice extends JSONSupport {
  constructor(properties?: OtherChoiceProperties);
  /**
   * The name of the field used to store the `other` choice value.
   *
   * @default ""
   */
  accessor fieldName: string;
  /** A string representing placeholder text when 'Other' choice is selected. */
  accessor hint: string | null | undefined;
  /** The label used for the `other` choice. */
  accessor label: string | null | undefined;
  /**
   * Creates a deep clone of the `OtherChoice` class.
   *
   * @returns A deep clone of the `OtherChoice` instance.
   */
  clone(): OtherChoice;
}