UNPKG

@vertigis/viewer-spec

Version:

VertiGIS Viewer Specification

59 lines (58 loc) 2.96 kB
import type Highcharts from "highcharts"; import type { ComponentModelProperties } from "./ComponentModelProperties.js"; import type { FeatureSetProperties } from "./FeatureSetProperties.js"; /** * Modules that enable additional functionality in HighCharts. */ export type HighChartsModule = "highcharts-3d" | "highcharts-more" | "accessibility" | "annotations" | "annotations-advanced" | "arrow-symbols" | "boost" | "boost-canvas" | "broken-axis" | "bullet" | "coloraxis" | "current-date-indicator" | "cylinder" | "data" | "datagrouping" | "debugger" | "dependency-wheel" | "dotplot" | "draggable-points" | "drag-panes" | "drilldown" | "dumbbell" | "export-data" | "exporting" | "full-screen" | "funnel" | "funnel3d" | "gantt" | "grid-axis" | "heatmap" | "histogram-bellcurve" | "item-series" | "lollipop" | "map" | "marker-clusters" | "networkgraph" | "no-data-to-display" | "offline-exporting" | "oldie" | "oldie-polyfills" | "organization" | "overlapping-datalabels" | "parallel-coordinates" | "pathfinder" | "pattern-fill" | "price-indicator" | "pyramid3d" | "sankey" | "series-label" | "solid-gauge" | "sonification" | "static-scale" | "stock" | "stock-tools" | "streamgraph" | "sunburst" | "tilemap" | "timeline" | "treegrid" | "treemap" | "variable-pie" | "variwide" | "vector" | "venn" | "windbarb" | "wordcloud" | "xrange"; /** * Configuration for a chart component. */ export interface ChartModelProperties extends ComponentModelProperties { /** * The chart template. This is based on Highcharts config defined at * https://api.highcharts.com/highcharts/ * with support for arcade expressions in the following syntax: * ```. * { * "$script": "arcade expression" * "$source": "item://layer-extension/id" * } * ```. * * The Arcade script supports basic arcade functionality as well as operations * that target Arcade feature sets. The charts features from the specified source * will be available to the arcade script as a $features global variable. * * The source specified can be any configured app item that can produce features * ex: * ```. * Item://layer-extension/id * item://table-extension/id * item://workflow/id * ```. * * Our config also supports callbacks with the following syntax * ex: * ``` * { * ..., * events: { * click: {@link Action} * } * } * ``` * The action will be executed with the event argument provided by Highcharts. */ template: Highcharts.Options; /** * An optional list of highcharts modules that will be utilized by your * charts configuration. */ highchartsModules?: HighChartsModule[]; /** * The set of features contained by the chart model. This property is only * serialized into saved projects. Web only. */ results?: FeatureSetProperties; }