import type ActionBase from "./ActionBase.js";
import type { ActionBaseProperties } from "./ActionBase.js";

export interface ActionToggleProperties extends ActionBaseProperties, Partial<Pick<ActionToggle, "value">> {}

/**
 * A customizable toggle used in the [LayerList](https://developers.arcgis.com/javascript/latest/references/core/widgets/LayerList/) widget
 * that performs a specific action(s) which can be toggled
 * on/off.
 *
 * @since 4.8
 * @see [Sample - LayerList widget with actions](https://developers.arcgis.com/javascript/latest/sample-code/widgets-layerlist-actions/)
 */
export default class ActionToggle extends ActionBase {
  constructor(properties?: ActionToggleProperties);
  /**
   * Specifies the type of action.
   *
   * @default "toggle"
   */
  get type(): "toggle";
  /**
   * Indicates the value of whether the action is toggled on/off.
   *
   * @default false
   */
  accessor value: boolean;
  /**
   * Creates a deep clone of this object.
   *
   * @returns A clone of the new [ActionToggle](https://developers.arcgis.com/javascript/latest/references/core/support/actions/ActionToggle/) instance.
   */
  clone(): this;
}