import type Color from "../../Color.js";

/**
 * Describes a theme that pairs well with the given basemaps.
 * See the table below for more details of the properties in this object.
 */
export interface Theme {
  /** The Esri basemaps that pair well with the given theme. */
  basemaps: string[];
  /** Text describing the theme in the UI. */
  description: string;
  /** The label identifying the theme in UI elements. */
  label: string;
  /** The name of the theme. */
  name: string;
}

export interface SchemeOutline {
  /** The outline color of the symbol. */
  color: Color;
  /** The width of the symbol in pixels or points. */
  width: string | number;
}

/** Properties defining the symbology scheme used to visualize point features with attribute data-driven color. */
export interface ColorSchemeForPoint {
  /** The continuous color ramp that will be applied to the visualization. */
  colors: Color[];
  /** Predefined classed color schemes to use for the visualization. */
  colorsForClassBreaks: ColorsForClassBreak[];
  /**
   * The unique id of the color scheme to use in the visualization. The id is
   * assigned based on the following template: `<themeName>/<basemapName>/<schemeName>`.
   */
  id: string;
  /** The unique name of the scheme. */
  name: string;
  /**
   * The color of the symbol used to indicate
   * features with no data and features that are out of range.
   */
  noDataColor: Color;
  /** The opacity of the symbol. */
  opacity: number;
  /** Properties for defining the outline of the symbol. */
  outline: SchemeOutline;
  /** The default size of the symbol in pixels or points. */
  size: string | number;
  /** Tags associated with the scheme. */
  tags: string[];
  /**
   * Indicates which values will be emphasized in the continuous ramp and the map.
   * Possible values are listed below.
   * | Value | Description | Example |
   * | ----- | ----------- | ------- |
   * | high-to-low | High values are emphasized with strong colors. | ![high-to-low](https://developers.arcgis.com/javascript/latest/assets/img/apiref/renderers/sm-high-to-low.png) |
   * | above-and-below | Values centered around a given point (e.g. the average) are visualized with weak colors while other values are emphasized with strong colors. | ![above-and-below](https://developers.arcgis.com/javascript/latest/assets/img/apiref/renderers/sm-above-and-below.png) |
   * | centered-on | Values centered around a given point (e.g. the average) are emphasized with strong colors while other values are visualized with weak colors. | ![centered-on](https://developers.arcgis.com/javascript/latest/assets/img/apiref/renderers/sm-centered-on.png) |
   * | extremes | High and low values are emphasized with strong colors. All others are visualized with weak colors. | ![extremes](https://developers.arcgis.com/javascript/latest/assets/img/apiref/renderers/sm-extremes.png) |
   */
  theme: string;
}

/** Properties defining the symbology scheme used to visualize polyline features with attribute data-driven color. */
export interface ColorSchemeForPolyline {
  /** The continuous color ramp that will be applied to the visualization. */
  colors: Color[];
  /** Predefined classed color schemes to use for the visualization. */
  colorsForClassBreaks: ColorsForClassBreak[];
  /**
   * The unique id of the color scheme to use in the visualization. The id is
   * assigned based on the following template: `<themeName>/<basemapName>/<schemeName>`.
   */
  id: string;
  /** The unique name of the scheme. */
  name: string;
  /**
   * The color of the symbol used to indicate
   * features with no data and features that are out of range.
   */
  noDataColor: Color;
  /** The opacity of the symbol. */
  opacity: number;
  /** Tags associated with the scheme. */
  tags: string[];
  /**
   * Indicates which values will be emphasized in the continuous ramp and the map.
   * Possible values are listed below.
   * | Value | Description | Example |
   * | ----- | ----------- | ------- |
   * | high-to-low | High values are emphasized with strong colors. | ![high-to-low](https://developers.arcgis.com/javascript/latest/assets/img/apiref/renderers/sm-high-to-low.png) |
   * | above-and-below | Values centered around a given point (e.g. the average) are visualized with weak colors while other values are emphasized with strong colors. | ![above-and-below](https://developers.arcgis.com/javascript/latest/assets/img/apiref/renderers/sm-above-and-below.png) |
   * | centered-on | Values centered around a given point (e.g. the average) are emphasized with strong colors while other values are visualized with weak colors. | ![centered-on](https://developers.arcgis.com/javascript/latest/assets/img/apiref/renderers/sm-centered-on.png) |
   * | extremes | High and low values are emphasized with strong colors. All others are visualized with weak colors. | ![extremes](https://developers.arcgis.com/javascript/latest/assets/img/apiref/renderers/sm-extremes.png) |
   */
  theme: string;
  /** The default width of the symbol in pixels or points. */
  width: string | number;
}

/** Properties defining the symbology scheme used to visualize polygon features with attribute data-driven color. */
export interface ColorSchemeForPolygon {
  /** The continuous color ramp that will be applied to the visualization. */
  colors: Color[];
  /** Predefined classed color schemes to use for the visualization. */
  colorsForClassBreaks: ColorsForClassBreak[];
  /**
   * The unique id of the color scheme to use in the visualization. The id is
   * assigned based on the following template: `<themeName>/<basemapName>/<schemeName>`.
   */
  id: string;
  /** The unique name of the scheme. */
  name: string;
  /**
   * The color of the symbol used to indicate
   * features with no data and features that are out of range.
   */
  noDataColor: Color;
  /** The opacity of the symbol. */
  opacity: number;
  /** Properties for defining the outline of the symbol. */
  outline: SchemeOutline;
  /** Tags associated with the scheme. */
  tags: string[];
  /**
   * Indicates which values will be emphasized in the continuous ramp and the map.
   * Possible values are listed below.
   * | Value | Description | Example |
   * | ----- | ----------- | ------- |
   * | high-to-low | High values are emphasized with strong colors. | ![high-to-low](https://developers.arcgis.com/javascript/latest/assets/img/apiref/renderers/sm-high-to-low.png) |
   * | above-and-below | Values centered around a given point (e.g. the average) are visualized with weak colors while other values are emphasized with strong colors. | ![above-and-below](https://developers.arcgis.com/javascript/latest/assets/img/apiref/renderers/sm-above-and-below.png) |
   * | centered-on | Values centered around a given point (e.g. the average) are emphasized with strong colors while other values are visualized with weak colors. | ![centered-on](https://developers.arcgis.com/javascript/latest/assets/img/apiref/renderers/sm-centered-on.png) |
   * | extremes | High and low values are emphasized with strong colors. All others are visualized with weak colors. | ![extremes](https://developers.arcgis.com/javascript/latest/assets/img/apiref/renderers/sm-extremes.png) |
   */
  theme: string;
}

/** Properties defining the symbology scheme used to visualize mesh features with attribute data-driven color. */
export interface ColorSchemeForMesh {
  /** The continuous color ramp that will be applied to the visualization. */
  colors: Color[];
  /** Predefined classed color schemes to use for the visualization. */
  colorsForClassBreaks: ColorsForClassBreak[];
  /**
   * The unique id of the color scheme to use in the visualization. The id is
   * assigned based on the following template: `<themeName>/<basemapName>/<schemeName>`.
   */
  id: string;
  /** The unique name of the scheme. */
  name: string;
  /**
   * The color of the symbol used to indicate
   * features with no data and features that are out of range.
   */
  noDataColor: Color;
  /** The opacity of the symbol. */
  opacity: number;
  /** Tags associated with the scheme. */
  tags: string[];
  /**
   * Indicates which values will be emphasized in the continuous ramp and the map.
   * Possible values are listed below.
   * | Value | Description | Example |
   * | ----- | ----------- | ------- |
   * | high-to-low | High values are emphasized with strong colors. | ![high-to-low](https://developers.arcgis.com/javascript/latest/assets/img/apiref/renderers/sm-high-to-low.png) |
   * | above-and-below | Values centered around a given point (e.g. the average) are visualized with weak colors while other values are emphasized with strong colors. | ![above-and-below](https://developers.arcgis.com/javascript/latest/assets/img/apiref/renderers/sm-above-and-below.png) |
   * | centered-on | Values centered around a given point (e.g. the average) are emphasized with strong colors while other values are visualized with weak colors. | ![centered-on](https://developers.arcgis.com/javascript/latest/assets/img/apiref/renderers/sm-centered-on.png) |
   * | extremes | High and low values are emphasized with strong colors. All others are visualized with weak colors. | ![extremes](https://developers.arcgis.com/javascript/latest/assets/img/apiref/renderers/sm-extremes.png) |
   */
  theme: string;
}

/** Properties defining the symbology scheme used to visualize features with attribute data-driven color. */
export type ColorScheme = ColorSchemeForPoint | ColorSchemeForPolyline | ColorSchemeForPolygon | ColorSchemeForMesh;

export interface ColorsForClassBreak {
  /**
   * An array of hex color strings. Each color is
   * assigned to a specific break in classed color visualizations.
   */
  colors: Color[];
  /** The number of classes or colors used in the ramp of discrete colors. */
  numClasses: number;
}

/** The return object of the [getSchemes()](https://developers.arcgis.com/javascript/latest/api-reference/esri-smartMapping-symbology-color.html#getSchemes) method. */
export interface ColorSchemes {
  /** The ID of the basemap associated with the given schemes. */
  basemapId?: string | null;
  /** Indicates whether the average basemap color is `light` or `dark`. */
  basemapTheme?: BasemapTheme | null;
  /** The color scheme best suited for the given basemap and geometry type. */
  primaryScheme: ColorScheme;
  /** Additional color schemes that may be used to visualize data of the given geometry type overlaid on the given basemap. */
  secondarySchemes: ColorScheme[];
}

/** Properties defining the symbology scheme used to visualize point features driven by attribute data. */
export interface SizeSchemeForPoint {
  /** The fill color of the marker symbol. */
  color: Color;
  /**
   * The maximum size of a marker symbol in pixels or points representing features
   * with high data values.
   */
  maxSize: string | number;
  /**
   * The minimum size of a marker symbol in pixels or points representing features
   * with low data values.
   */
  minSize: string | number;
  /**
   * The color of the marker symbol used to indicate
   * features with no data and features that are out of range.
   */
  noDataColor: Color;
  /**
   * The size of the marker symbol (in pixels or points) used to indicate
   * features with no data and features that are out of range.
   */
  noDataSize: string | number;
  /** The opacity of the marker symbol. */
  opacity?: number;
  /** Properties for defining the outline of the marker symbol. */
  outline: SchemeOutline;
  /** The default size of the marker symbol in pixels or points. */
  size: string | number;
}

/** Properties defining the symbology scheme used to visualize polyline features driven by attribute data. */
export interface SizeSchemeForPolyline {
  /** The color of the line symbol. */
  color: Color;
  /**
   * The maximum width of a line symbol in pixels or points representing features
   * with high data values.
   */
  maxWidth: string | number;
  /**
   * The minimum width of a line symbol in pixels or points representing features
   * with low data values.
   */
  minWidth: string | number;
  /**
   * The color of the line symbol used to indicate
   * features with no data and features that are out of range.
   */
  noDataColor: Color;
  /**
   * The width of the line symbol in pixels or points used to indicate
   * features with no data and features that are out of range.
   */
  noDataWidth: string | number;
  /** The opacity of the line symbol. */
  opacity?: number;
  /** The default width of the line symbol in pixels or points. */
  width: string | number;
}

/**
 * Properties defining the symbology scheme used to visualize polygon features driven by attribute data.
 * When visualized by size, polygons are represented with marker symbols.
 */
export interface SizeSchemeForPolygon {
  /** The schema defining the backgound symbol of the feature. This is a fill symbol. */
  background: SizeSchemeForPolygonBackground;
  /** The scheme defining the symbology of the marker symbol used to represent polygon features by size. */
  marker: SizeSchemeForPoint;
  /** The opacity of the symbol. */
  opacity?: number;
}

export interface SizeSchemeForPolygonBackground {
  /** The color of the fill symbol representing the polygon. */
  color: Color;
  /** Properties for defining the outline of the background fill symbol. */
  outline: SchemeOutline;
}

/** Properties defining the symbology scheme used to visualize features with attribute data-driven size. */
export type SizeScheme = SizeSchemeForPoint | SizeSchemeForPolyline | SizeSchemeForPolygon;

/** The return object of the [getSchemes()](https://developers.arcgis.com/javascript/latest/api-reference/esri-smartMapping-symbology-size.html#getSchemes) method. */
export interface SizeSchemes {
  /** The ID of the basemap associated with the given schemes. */
  basemapId?: string | null;
  /** Indicates whether the average basemap color is `light` or `dark`. */
  basemapTheme?: BasemapTheme | null;
  /** The size scheme best suited for the given basemap and geometry type. */
  primaryScheme: SizeScheme;
  /** Additional size schemes that may be used to visualize data of the given geometry type overlaid on the given basemap. */
  secondarySchemes: SizeScheme[];
}

/** Properties defining the location-only symbology scheme used to visualize point features. */
export interface LocationSchemeForPoint {
  /** The fill color of the marker symbol. */
  color: Color;
  /** The opacity of the marker symbol. */
  opacity: number;
  /** Properties for defining the outline of the marker symbol. */
  outline: SchemeOutline;
  /** The size of the marker symbol in pixels or points. */
  size: string | number;
}

/** Properties defining the location-only symbology scheme used to visualize polyline features. */
export interface LocationSchemeForPolyline {
  /** The color of the line symbol. */
  color: Color;
  /** The opacity of the line symbol. */
  opacity: number;
  /** The width of the line symbol in pixels or points. */
  width: string | number;
}

/** Properties defining the location-only symbology scheme used to visualize polygon features. */
export interface LocationSchemeForPolygon {
  /** The color of the fill symbol. */
  color: Color;
  /** The opacity of the fill symbol. */
  opacity: number;
  /** Properties for defining the outline of the fill symbol. */
  outline: SchemeOutline;
}

/** Properties defining the location-only symbology scheme used to visualize mesh features. */
export interface LocationSchemeForMesh {
  /** The color of the fill symbol. */
  color: Color;
  /** The opacity of the fill symbol. */
  opacity: number;
}

/** Defines the symbology scheme used to visualize default location-based symbols depending on the layer's geometry type. */
export type LocationScheme = LocationSchemeForPoint | LocationSchemeForPolyline | LocationSchemeForPolygon | LocationSchemeForMesh;

/** The return object of the [getSchemes()](https://developers.arcgis.com/javascript/latest/api-reference/esri-smartMapping-symbology-location.html#getSchemes) method. */
export interface LocationSchemes {
  /** The ID of the basemap associated with the given schemes. */
  basemapId?: string | null;
  /** Indicates whether the average basemap color is `light` or `dark`. */
  basemapTheme?: BasemapTheme | null;
  /** The location scheme best suited for the given basemap and geometry type. */
  primaryScheme: LocationScheme;
  /** Additional location schemes that may be used to visualize data of the given geometry type overlaid on the given basemap. */
  secondarySchemes: LocationScheme[];
}

/** Properties defining the symbology scheme used to visualize point features driven by type-based attribute data. */
export interface TypeSchemeForPoint {
  /** The fill colors of the point symbols comprising the theme. */
  colors: Color[];
  /** The unique name of the scheme. */
  name: string;
  /**
   * The color of the point symbol used to indicate
   * features with no data.
   */
  noDataColor: Color;
  /** The opacity of the point symbol. */
  opacity: number;
  /** Properties for defining the outline of the marker symbol. */
  outline: SchemeOutline;
  /** The default size of the point symbol in pixels, points, or real-world units. */
  size: string | number;
  /** Tags associated with the scheme. */
  tags: string[];
  /** The theme. */
  theme: string;
}

/** Properties defining the symbology scheme used to visualize polyline features driven by type-based attribute data. */
export interface TypeSchemeForPolyline {
  /** The colors of the line symbols comprising the theme. */
  colors: Color[];
  /** The unique name of the scheme. */
  name: string;
  /**
   * The color of the line symbol used to indicate
   * features with no data and features that are out of range.
   */
  noDataColor: Color;
  /** The opacity of the line symbol (0 - 1). */
  opacity: number;
  /** Tags associated with the scheme. */
  tags: string[];
  /** The theme. */
  theme: string;
  /** The default width of the line symbol in pixels or points. */
  width: string | number;
}

/** Properties defining the symbology scheme used to visualize polygon features driven by type-based attribute data. */
export interface TypeSchemeForPolygon {
  /** The fill colors of the symbols comprising the theme. */
  colors: Color[];
  /** The unique name of the scheme. */
  name: string;
  /**
   * The color of the fill symbol used to indicate
   * features with no data.
   */
  noDataColor: Color;
  /** The opacity of the symbol (0 - 1). */
  opacity: number;
  /** Properties for defining the outline of the fill symbol. */
  outline: SchemeOutline;
  /** Tags associated with the scheme. */
  tags: string[];
  /** The theme. */
  theme: string;
}

/** Properties defining the symbology scheme used to visualize mesh features driven by type-based attribute data. */
export interface TypeSchemeForMesh {
  /** The fill colors of the symbols comprising the theme. */
  colors: Color[];
  /** The unique name of the scheme. */
  name: string;
  /**
   * The color of the fill symbol used to indicate
   * features with no data.
   */
  noDataColor: Color;
  /** The opacity of the symbol (0 - 1). */
  opacity: number;
  /** Tags associated with the scheme. */
  tags: string[];
  /** The theme. */
  theme: string;
}

/** Properties defining the symbology scheme used to visualize point clouds. */
export interface PointCloudClassScheme {
  /** The fill colors of the point symbols comprising the theme. */
  colors: Color[];
  /** The unique name of the scheme. */
  name: string;
  /** Tags associated with the scheme. */
  tags: string[];
  /** The theme. */
  theme: string;
}

export type TypeSchemeForGeometry = TypeSchemeForPoint | TypeSchemeForPolyline | TypeSchemeForPolygon | TypeSchemeForMesh;

/** Properties defining the symbology scheme used to visualize features with attribute data-driven types. */
export type TypeScheme = TypeSchemeForGeometry | PointCloudClassScheme;

/** The return object of the [getSchemes()](https://developers.arcgis.com/javascript/latest/api-reference/esri-smartMapping-symbology-type.html#getSchemes) method. */
export interface TypeSchemes {
  /** The ID of the basemap associated with the given schemes. */
  basemapId?: string | null;
  /** Indicates whether the average basemap color is `light` or `dark`. */
  basemapTheme?: BasemapTheme | null;
  /** The type scheme best suited for the given basemap and geometry type. */
  primaryScheme: TypeScheme;
  /** Additional type schemes that may be used to visualize data of the given geometry type overlaid on the given basemap. */
  secondarySchemes: TypeScheme[];
}

/** Properties defining the symbology scheme used to visualize point features as a heatmap. */
export interface HeatmapScheme {
  /** A continuous color ramp used to construct a heatmap. */
  colors: Color[];
  /**
   * The unique id of the color scheme to usee in the visualization. The id is
   *   assigned based on the following template: `<themeName>/<basemapName>/<schemeName>`.
   */
  id: string;
  /** The unique name of the scheme. */
  name: string;
  /** The opacity of the heatmap. */
  opacity: number;
  /** Tags associated with the scheme. */
  tags: string[];
}

/** The return object of the [getSchemes()](https://developers.arcgis.com/javascript/latest/api-reference/esri-smartMapping-symbology-heatmap.html#getSchemes) method. */
export interface HeatmapSchemes {
  /** The ID of the basemap associated with the given schemes. */
  basemapId?: string | null;
  /** Indicates whether the average basemap color is `light` or `dark`. */
  basemapTheme?: BasemapTheme | null;
  /** The heatmap color scheme best suited for the given basemap and geometry type. */
  primaryScheme: HeatmapScheme;
  /** Additional heatmap color schemes that may be used to visualize data overlaid on the given basemap. */
  secondarySchemes: HeatmapScheme[];
}

/** Properties defining the symbology scheme used to visualize predominance for point features. */
export interface PredominanceSchemeForPoint {
  /** The fill colors of the point symbols used for each category. */
  colors: Color[];
  /** The unique name of the scheme. */
  name: string;
  /**
   * The color of the point symbol used to indicate
   *   features with no data.
   */
  noDataColor: Color;
  /** The opacity of the point symbol (0 - 1). */
  opacity: number;
  /** Properties for defining the outline of the marker symbol. */
  outline: SchemeOutline;
  /** The scheme defining the size visual variable if included in a predominance visualization. */
  sizeScheme: SizeSchemeForPoint;
  /** Tags associated with the scheme. */
  tags: string[];
}

/** Properties defining the symbology scheme used to visualize predominance for polyline features. */
export interface PredominanceSchemeForPolyline {
  /** The colors of the line symbols used for each category. */
  colors: Color[];
  /** The unique name of the scheme. */
  name: string;
  /**
   * The color of the line symbol used to indicate
   *   features with no data and features that are out of range.
   */
  noDataColor: Color;
  /** The opacity of the line symbol (0 - 1). */
  opacity: number;
  /** The scheme defining the size visual variable if included in a predominance visualization. */
  sizeScheme: SizeSchemeForPolyline;
  /** Tags associated with the scheme. */
  tags: string[];
  /** The default width of the line symbol in pixels or points. */
  width: string | number;
}

/** Properties defining the symbology scheme used to visualize predominance for polygon features. */
export interface PredominanceSchemeForPolygon {
  /** The fill colors of the polygon symbols used for each category. */
  colors: Color[];
  /** The unique name of the scheme. */
  name: string;
  /**
   * The color of the fill symbol used to indicate
   *   features with no data.
   */
  noDataColor: Color;
  /** The opacity of the symbol (0 - 1). */
  opacity: number;
  /** Properties for defining the outline of the fill symbol. */
  outline: SchemeOutline;
  /** The scheme defining the size visual variable if included in a predominance visualization. */
  sizeScheme: SizeSchemeForPolygon;
  /** Tags associated with the scheme. */
  tags: string[];
}

/** Properties defining the symbology scheme used to visualize predominance for mesh features. */
export interface PredominanceSchemeForMesh {
  /** The fill colors of the mesh symbols used for each category. */
  colors: Color[];
  /** The unique name of the scheme. */
  name: string;
  /**
   * The color of the fill symbol used to indicate
   *   features with no data.
   */
  noDataColor: Color;
  /** The opacity of the symbol (0 - 1). */
  opacity: number;
  /** Tags associated with the scheme. */
  tags: string[];
}

/** Defines the symbology scheme used to visualize predominance based on the layer's geometry type. */
export type PredominanceScheme = PredominanceSchemeForPoint | PredominanceSchemeForPolyline | PredominanceSchemeForPolygon | PredominanceSchemeForMesh;

/** The return object of the [getSchemes()](https://developers.arcgis.com/javascript/latest/api-reference/esri-smartMapping-symbology-predominance.html#getSchemes) method. */
export interface PredominanceSchemes {
  /** The ID of the basemap associated with the given schemes. */
  basemapId?: string | null;
  /** Indicates whether the average basemap color is `light` or `dark`. */
  basemapTheme?: BasemapTheme | null;
  /** The predominance scheme best suited for the given basemap and geometry type. */
  primaryScheme: PredominanceScheme;
  /** Additional predominance schemes that may be used to visualize data of the given geometry type overlaid on the given basemap. */
  secondarySchemes: PredominanceScheme[];
}

/** Properties defining the symbology scheme used to visualize relationship renderers (bivariate color) for point features. */
export interface RelationshipSchemeForPoint {
  /** Defines the colors to use in each bin of the relationship visualization. */
  colorsForClassBreaks: RelationshipColorsForClassBreak[];
  /** The ID uniquely identifying the color scheme. */
  id: string;
  /** The unique name of the scheme. */
  name: string;
  /**
   * The color of the point symbol used to indicate
   *   features with no data.
   */
  noDataColor: Color;
  /** The opacity of the point symbol (0 - 1). */
  opacity: number;
  /** Properties for defining the outline of the marker symbol. */
  outline: SchemeOutline;
  /** The size of the point symbol in points. */
  size: string | number;
  /** Tags associated with the scheme. */
  tags: string[];
}

/** Properties defining the symbology scheme used to visualize relationship renderers (bivariate color) for polyline features. */
export interface RelationshipSchemeForPolyline {
  /** Defines the colors to use in each bin of the relationship visualization. */
  colorsForClassBreaks: RelationshipColorsForClassBreak[];
  /** The ID uniquely identifying the color scheme. */
  id: string;
  /** The unique name of the scheme. */
  name: string;
  /**
   * The color of the line symbol used to indicate
   *   features with no data.
   */
  noDataColor: Color;
  /** The opacity of the line symbol (0 - 1). */
  opacity: number;
  /** Tags associated with the scheme. */
  tags: string[];
  /** The width of the line symbol in points. */
  width: string | number;
}

/** Properties defining the symbology scheme used to visualize relationship renderers (bivariate color) for polygon features. */
export interface RelationshipSchemeForPolygon {
  /** Defines the colors to use in each bin of the relationship visualization. */
  colorsForClassBreaks: RelationshipColorsForClassBreak[];
  /** The ID uniquely identifying the color scheme. */
  id: string;
  /** The unique name of the scheme. */
  name: string;
  /**
   * The color of the fill symbol used to indicate
   *   features with no data.
   */
  noDataColor: Color;
  /** The opacity of the fill symbol (0 - 1). */
  opacity: number;
  /** Properties for defining the outline of the fill symbol. */
  outline: SchemeOutline;
  /** Tags associated with the scheme. */
  tags: string[];
}

/** Properties defining the symbology scheme used to visualize relationship renderers (bivariate color) for mesh features. */
export interface RelationshipSchemeForMesh {
  /** Defines the colors to use in each bin of the relationship visualization. */
  colorsForClassBreaks: RelationshipColorsForClassBreak[];
  /** The ID uniquely identifying the color scheme. */
  id: string;
  /** The unique name of the scheme. */
  name: string;
  /**
   * The color of the fill symbol used to indicate
   *   features with no data.
   */
  noDataColor: Color;
  /** The opacity of the fill symbol (0 - 1). */
  opacity: number;
  /** Tags associated with the scheme. */
  tags: string[];
}

/** Defines the symbology scheme used to visualize relationship renderers (bivariate color) based on the layer's geometry type. */
export type RelationshipScheme = RelationshipSchemeForPoint | RelationshipSchemeForPolyline | RelationshipSchemeForPolygon | RelationshipSchemeForMesh;

export interface RelationshipColorsForClassBreak {
  /** The fill colors of the symbols used for each bin in the relationship visualization. */
  colors: Color[][];
  /** The number of breaks (rows/columns) for each variable in the relationship visualization. */
  numClasses: number;
}

/** The return object of the [getSchemes()](https://developers.arcgis.com/javascript/latest/api-reference/esri-smartMapping-symbology-relationship.html#getSchemes) method. */
export interface RelationshipSchemes {
  /** The ID of the basemap associated with the given schemes. */
  basemapId?: string | null;
  /** Indicates whether the average basemap color is `light` or `dark`. */
  basemapTheme?: BasemapTheme | null;
  /** The relationship scheme best suited for the given basemap and geometry type. */
  primaryScheme: RelationshipScheme;
  /** Additional relationship schemes that may be used to visualize data of the given geometry type overlaid on the given basemap. */
  secondarySchemes: RelationshipScheme[];
}

/** Properties defining the symbology scheme used to visualize predominance for polygon features. */
export interface DotDensityScheme {
  /** The dot color for each attribute. */
  colors: Color[];
  /** The unique name of the scheme. */
  name: string;
  /** The opacity of the symbol (0 - 1). */
  opacity: number;
  /** Properties for defining the outline of the symbol. */
  outline: SchemeOutline;
  /** Tags associated with the scheme. */
  tags: string[];
}

/** The return object of the [getSchemes()](https://developers.arcgis.com/javascript/latest/api-reference/esri-smartMapping-symbology-dotDensity.html#getSchemes) method. */
export interface DotDensitySchemes {
  /** The ID of the basemap associated with the given schemes. */
  basemapId?: string | null;
  /** Indicates whether the average basemap color is `light` or `dark`. */
  basemapTheme?: BasemapTheme | null;
  /** The dot density scheme best suited for the given basemap and geometry type. */
  primaryScheme: DotDensityScheme;
  /** Additional dot density schemes that may be used to visualize data of the given geometry type overlaid on the given basemap. */
  secondarySchemes: DotDensityScheme[];
}

/** Properties defining the colors and schemes used to visualize pie charts. */
export interface PieChartScheme {
  /** The color of the "others" category. */
  colorForOthersCategory: Color;
  /** The colors used to visualize pie slices in the chart. */
  colors: Color[];
  /** The unique name of the color scheme. */
  name: string;
  /** Properties for defining the outline of the pie chart. */
  outline: SchemeOutline;
  /** The default size of the pie charts in points or pixels. */
  size: string | number;
  /** The scheme defining the size visual variable used to vary chart size per feature. */
  sizeScheme?: SizeScheme | null;
  /** Tags associated with the color scheme. */
  tags: string[];
}

/** The return object of the [getSchemes()](https://developers.arcgis.com/javascript/latest/api-reference/esri-smartMapping-symbology-pieChart.html#getSchemes) method. */
export interface PieChartSchemes {
  /** The ID of the basemap associated with the given schemes. */
  basemapId?: string | null;
  /** Indicates whether the average basemap color is `light` or `dark`. */
  basemapTheme?: BasemapTheme | null;
  /** The suggest default chart scheme based on the given basemap. */
  primaryScheme: PieChartScheme;
  /** Additional chart schemes that may be used to visualize data overlaid on the given basemap. */
  secondarySchemes: PieChartScheme[];
}

/** Suggested property values for defining the scheme used to visualize flow lines. */
export interface FlowScheme {
  /** The suggested color of the flow lines if a color visual variable is not desired. */
  color: Color;
  /**
   * The suggested colors to use if a
   *   [ColorVariable](https://developers.arcgis.com/javascript/latest/api-reference/esri-renderers-visualVariables-ColorVariable.html) is set on the flow renderer.
   */
  colors: Color[];
  /** The suggested [FlowRenderer#density](https://developers.arcgis.com/javascript/latest/api-reference/esri-renderers-FlowRenderer.html#density) of the streamlines. */
  density: number;
  /** The suggested [FlowRenderer#flowSpeed](https://developers.arcgis.com/javascript/latest/api-reference/esri-renderers-FlowRenderer.html#flowSpeed) of the streamlines. */
  flowSpeed: number;
  /**
   * The unique id of the color scheme to use in the visualization. The id is
   * assigned based on the following template: `<themeName>/<basemapName>/<schemeName>`.
   */
  id: string;
  /**
   * The suggested [ImageryTileLayer#effect](https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-ImageryTileLayer.html#effect) to apply to the input layer.
   *
   * > [!WARNING]
   * >
   * > **Known Limitations**
   * >
   * > The layer effects are not supported in 3D [SceneView](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-SceneView.html).
   */
  layerEffect: string;
  /**
   * The suggested opacity to apply to large magnitude values if an
   *   [OpacityVariable](https://developers.arcgis.com/javascript/latest/api-reference/esri-renderers-visualVariables-OpacityVariable.html) is set on the flow renderer.
   */
  maxOpacity: number;
  /**
   * The suggested size to apply to large magnitude values if a
   *   [SizeVariable](https://developers.arcgis.com/javascript/latest/api-reference/esri-renderers-visualVariables-SizeVariable.html) is set on the flow renderer.
   */
  maxSize: number;
  /**
   * The suggested opacity to apply to small magnitude values if an
   *   [OpacityVariable](https://developers.arcgis.com/javascript/latest/api-reference/esri-renderers-visualVariables-OpacityVariable.html) is set on the flow renderer.
   */
  minOpacity: number;
  /**
   * The suggested size to apply to small magnitude values if a
   *   [SizeVariable](https://developers.arcgis.com/javascript/latest/api-reference/esri-renderers-visualVariables-SizeVariable.html) is set on the flow renderer.
   */
  minSize: number;
  /** The unique name of the scheme. */
  name: string;
  /** Tags associated with the scheme. */
  tags: string[];
  /**
   * Determines how flow lines will render.
   *   Possible values are listed below.
   * | Value | Description | Example |
   * | ----- | ----------- | ------- |
   * | flow-line | Renders the uv and magnitude data as animated flow lines. This is ideal for representing wind and other atmospheric data. | ![flow-line](https://developers.arcgis.com/javascript/latest/assets/img/apiref/renderers/animated-flow/sm-flow-line-2.gif) |
   * | wave-front | Renders UV and magnitude data in a wave-like animation. This theme works well for ocean data. | ![above](https://developers.arcgis.com/javascript/latest/assets/img/apiref/renderers/animated-flow/sm-wave-front-2.gif) |
   *
   * > [!WARNING]
   * >
   * > **Known Limitations**
   * >
   * > The `wave-front` flow theme is not supported in 3D [SceneView](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-SceneView.html).
   */
  theme: "flow-line" | "wave-front";
  /**
   * The suggested [cap style](https://developers.arcgis.com/javascript/latest/api-reference/esri-renderers-FlowRenderer.html#trailCap) of the streamlines.
   *
   * > [!WARNING]
   * >
   * > **Known Limitations**
   * >
   * > The `round` trail cap is not supported in 3D [SceneView](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-SceneView.html).
   */
  trailCap: "butt" | "round";
  /** The suggested [length](https://developers.arcgis.com/javascript/latest/api-reference/esri-renderers-FlowRenderer.html#trailLength) of the streamlines. */
  trailLength: number;
  /** The suggested [width](https://developers.arcgis.com/javascript/latest/api-reference/esri-renderers-FlowRenderer.html#trailWidth) of the streamlines. */
  trailWidth: number;
}

/** The return object of the [getSchemes()](https://developers.arcgis.com/javascript/latest/api-reference/esri-smartMapping-symbology-flow.html#getSchemes) method. */
export interface FlowSchemes {
  /** The ID of the basemap associated with the given schemes. */
  basemapId?: string | null;
  /** Indicates whether the average basemap color is `light` or `dark`. */
  basemapTheme?: BasemapTheme | null;
  /** The flow scheme best suited for the given basemap. */
  primaryScheme: FlowScheme;
  /** Additional flow schemes that may be used to visualize streamlines overlaid on the given basemap or basemap theme. */
  secondarySchemes: FlowScheme[];
}

export type BasemapTheme = "light" | "dark";

/** Defines a ramp of colors to use for visualizing data in a chart, [Renderer](https://developers.arcgis.com/javascript/latest/api-reference/esri-renderers-Renderer.html), or [ColorVariable](https://developers.arcgis.com/javascript/latest/api-reference/esri-renderers-visualVariables-ColorVariable.html). */
export interface ColorRamp {
  /** An array of five colors intended for displaying a continuous color ramp. */
  colors: Color[];
  /**
   * Contains an array of ramps ranging in size from 1 color to 10 colors. All ramps are part of the same color
   *   scheme, but provide a different number of colors depending on the requirements of the ramp needed for the visualization.
   */
  colorsForClassBreaks: ColorsForClassBreak[];
  /** The unique name of the color ramp. */
  name: string;
  /** Tags associated with the color ramp. */
  tags: string[];
}