/// <reference path="../../index.d.ts" />
import type Layer from "@arcgis/core/layers/Layer.js";
import type Sublayer from "@arcgis/core/layers/support/Sublayer.js";
import type { PublicLitElement as LitElement } from "@arcgis/lumina";
import type { ArcgisReferenceElement, IconName } from "../types.js";
import type { MapViewOrSceneView } from "@arcgis/core/views/MapViewOrSceneView.js";
import type { Icon } from "@esri/calcite-components/components/calcite-icon";
import type { SupportedRegion } from "@arcgis/core/widgets/ScaleRangeSlider/types.js";
import type { ScaleRangeSliderViewModelState } from "@arcgis/core/widgets/ScaleRangeSlider/ScaleRangeSliderViewModel.js";

/**
 * The Scale Range Slider component allows the user to set a minimum and maximum scale based on named scale ranges.
 *
 * > [!WARNING]
 * > This component is a wrapped version of the [ScaleRangeSlider](https://developers.arcgis.com/javascript/latest/api-reference/esri-widgets-ScaleRangeSlider.html) widget.
 * > We recommend using the [arcgis-slider-scale-range](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-slider-scale-range/) component instead, which provides a native implementation with improved features and accessibility.
 *
 * @deprecated since 5.1. Use [arcgis-slider-scale-range](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-slider-scale-range/) instead.
 * @since 4.28
 */
export abstract class ArcgisScaleRangeSlider extends LitElement {
  /**
   * If true, the component will not be destroyed automatically when it is
   * disconnected from the document. This is useful when you want to move the
   * component to a different place on the page, or temporarily hide it. If this
   * is set, make sure to call the [destroy()](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-scale-range-slider/#destroy) method when you are done to
   * prevent memory leaks.
   *
   * @default false
   */
  accessor autoDestroyDisabled: boolean;
  /**
   * When true, the component is visually withdrawn and cannot receive user interaction.
   *
   * @default false
   */
  accessor disabled: boolean;
  /**
   * Indicates whether the preview thumbnail of the scale is visible.
   * Default value is `true`.
   *
   * @default false
   */
  accessor hidePreview: boolean | undefined;
  /**
   * Indicates whether the maximum scale dropdown menu is visible. Default value is `true`.
   *
   * @default false
   */
  accessor hideScaleMenusMaxScaleMenu: boolean | undefined;
  /**
   * Indicates whether the minimum scale dropdown menu is visible. Default value is `true`.
   *
   * @default false
   */
  accessor hideScaleMenusMinScaleMenu: boolean | undefined;
  /**
   * Icon which represents the component.
   * Typically used when the component is controlled by another component (e.g. by the Expand component).
   *
   * @default "actual-size"
   * @since 4.27
   * @see [Calcite Icons](https://developers.arcgis.com/calcite-design-system/icons/)
   */
  get icon(): Icon["icon"];
  set icon(value: IconName);
  /**
   * The component's default label.
   *
   * @since 4.11
   */
  accessor label: string;
  /**
   * When provided, the initial [minScale](https://developers.arcgis.com/javascript/latest/references/core/widgets/ScaleRangeSlider/#minScale) and [maxScale](https://developers.arcgis.com/javascript/latest/references/core/widgets/ScaleRangeSlider/#maxScale) values will match the layer's.
   *
   * When a tiled layer is used, the slider will be restricted from moving the slider thumbs past the `lods` of the layer's tiling scheme.
   * Since version 4.28, when a [MapImageLayer](https://developers.arcgis.com/javascript/latest/references/core/layers/MapImageLayer/) is used, the slider will be restricted from moving past the min/max scale defined on the map service.
   * The unavailable range will be designated with a dashed line.
   */
  accessor layer: Layer | Sublayer | null | undefined;
  /**
   * The maximum scale of the active scale range. When the maxScale
   * reaches the [maxScaleLimit](https://developers.arcgis.com/javascript/latest/references/core/widgets/ScaleRangeSlider/#maxScaleLimit), the maxScale
   * value becomes 0 and there is no maximum scale set.
   */
  accessor maxScale: number;
  /** The lowest possible maximum scale value on the slider. */
  accessor maxScaleLimit: number;
  /**
   * The minimum scale of the active scale range. When the minScale
   * reaches the [minScaleLimit](https://developers.arcgis.com/javascript/latest/references/core/widgets/ScaleRangeSlider/#minScaleLimit), the minScale
   * value becomes 0 and there is no minimum scale.
   */
  accessor minScale: number;
  /** The highest possible minimum scale value on the slider. */
  accessor minScaleLimit: number;
  /**
   * The mode of the component, indicating which slider thumbs can be adjusted.
   *
   * @default "range"
   * @since 4.29
   */
  accessor mode: "range" | "max-scale-only" | "min-scale-only";
  /**
   * By assigning the `id` attribute of the Map or Scene component to this property, you can position a child component anywhere in the DOM while still maintaining a connection to the Map or Scene.
   *
   * @see [Associate components with a Map or Scene component](https://developers.arcgis.com/javascript/latest/programming-patterns/#associate-components-with-a-map-or-scene-component)
   */
  accessor referenceElement: ArcgisReferenceElement | string | undefined;
  /**
   * The region that the scale thumbnails will focus on.
   * Each region comes from the [ISO 3166-1 alpha-2 code](https://en.wikipedia.org/wiki/List_of_ISO_3166_country_codes).
   * See [SupportedRegion](https://developers.arcgis.com/javascript/latest/references/core/widgets/ScaleRangeSlider/types/#SupportedRegion) for the list of regions that are currently supported.
   *
   * @default "US"
   */
  accessor region: SupportedRegion;
  /**
   * Indicates whether the world scale value is shown in the scale menu.
   *
   * @default false
   * @since 4.34
   */
  accessor showWorldValue: boolean;
  /**
   * The current state of the component.
   *
   * @default "disabled"
   */
  get state(): ScaleRangeSliderViewModelState;
  /**
   * The view associated with the component. 
   *   > **Note:** The recommended approach is to fully migrate applications to use map and scene components and avoid using MapView and SceneView directly. However, if you are migrating a large application from widgets to components, you might prefer a more gradual transition. To support this use case, the SDK includes this `view` property which connects a component to a MapView or SceneView. Ultimately, once migration is complete, the arcgis-scale-range-slider component will be associated with a map or scene component rather than using the `view` property.
   */
  accessor view: MapViewOrSceneView | null | undefined;
  /** Permanently destroy the component. */
  destroy(): Promise<void>;
  "@setterTypes": {
    icon?: IconName;
  };
  /** Emitted when the value of a property is changed. Use this to listen to changes to properties. */
  readonly arcgisPropertyChange: import("@arcgis/lumina").TargetedEvent<this, { name: "state" | "minScale" | "maxScale"; }>;
  /** Emitted when the component associated with a map or scene view is ready to be interacted with. */
  readonly arcgisReady: import("@arcgis/lumina").TargetedEvent<this, void>;
  readonly "@eventTypes": {
    arcgisPropertyChange: ArcgisScaleRangeSlider["arcgisPropertyChange"]["detail"];
    arcgisReady: ArcgisScaleRangeSlider["arcgisReady"]["detail"];
  };
}