import type Color from "../../Color.js";
import type { JSONSupport, JSONSupportMixinProperties } from "../../core/JSONSupport.js";
import type { ColorLike } from "../../Color.js";

export interface ColorBackgroundProperties extends JSONSupportMixinProperties {
  /**
   * The color of the background.
   * This can be autocast with an array of rgb(a) values, named string, hex string or an hsl(a) string,
   * an object with `r`, `g`, `b`, and `a` properties, or a [Color](https://developers.arcgis.com/javascript/latest/api-reference/esri-Color.html) object.
   *
   * @default "black"
   */
  color?: ColorLike;
}

/**
 * Represents the background color of the [WebMap](https://developers.arcgis.com/javascript/latest/api-reference/esri-WebMap.html)
 * when displayed in a [MapView](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-MapView.html).
 *
 * @since 4.11
 */
export default class ColorBackground extends JSONSupport {
  constructor(properties?: ColorBackgroundProperties);
  /**
   * The color of the background.
   * This can be autocast with an array of rgb(a) values, named string, hex string or an hsl(a) string,
   * an object with `r`, `g`, `b`, and `a` properties, or a [Color](https://developers.arcgis.com/javascript/latest/api-reference/esri-Color.html) object.
   *
   * @default "black"
   */
  get color(): Color;
  set color(value: ColorLike);
  /**
   * Creates a deep clone of the object.
   *
   * @returns A deep clone of the object that
   *   invoked this method.
   */
  clone(): ColorBackground;
}