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

/** The return object of the [getTemplates()](https://developers.arcgis.com/javascript/latest/api-reference/esri-smartMapping-popup-templates.html#getTemplates) method. */
export interface Templates {
  /** Includes the primary PopupTemplate suggested for the input layer. */
  primaryTemplate: Template;
  /** Includes secondary PopupTemplates that may be applied to the input layer. */
  secondaryTemplates: Template[];
}

/**
 * Defines a suggested PopupTemplate with a given name and title describing the content
 * and purpose of the PopupTemplate.
 */
export interface Template {
  /**
   * The name of the auto-generated PopupTemplate.
   *   This can be used in the UI of web map authoring apps.
   */
  name: string;
  /** The title of the PopupTemplate. */
  title: string;
  /** The suggested PopupTemplate. */
  value: PopupTemplate;
}