import { OptionFactory } from '../echart'; import { TimeseriesEChartsOption, TimeseriesOptionFactoryInput, TimeseriesOptionsInput } from './types'; /** * Builds the **structural** ECharts option for a timeseries widget — * time x-axis, value y-axis, themed tooltip, themed legend, CARTO color * palette. Mirrors {@link import('../bar/options').barOptions} so all * four ECharts widgets share v1 look-and-feel. * * Intentional deviations from bar (timeseries-specific): * - **X-axis is `type: 'time'`** (not 'category'). ECharts handles * uneven sample spacing and zoom-level-aware label formatting. * `labelFormatter` is wrapped so the consumer sees a `Date`, not * a numeric timestamp. * - **Tooltip body reads `{ name, value }` rows**, same as bar, but * the `name` may arrive as `Date | number | string`. The * `labelFormatter` receives a `Date` regardless. * * Intentionally data-agnostic: no series, no dataset, no `legend.show` * (those depend on data and are added by the option factory's merge * phase via {@link createTimeseriesOptionFactory}). */ export declare function timeseriesOptions({ theme, formatter, labelFormatter, }: TimeseriesOptionsInput): TimeseriesEChartsOption; /** * Returns the timeseries widget's {@link OptionFactory} — one closure * that owns BOTH phases of option construction: * * - **Structural phase** (`option == null`) — builds the theme-aware * structural option via {@link timeseriesOptions}, optionally merging * the consumer-supplied `optionsOverride`. Called once by Provider to * seed `rawOptions` in the store. * - **Merge phase** (`option != null`) — fuses post-pipeline `state.data` * (`TimeseriesWidgetData`) into the option via the dataset API: one * dataset per series, each series referencing its dataset by index, * encoded by `name` (x — time) and `value` (y). Mirrors {@link import('../bar/options').createBarOptionFactory}: * series-template merge for `addStack`, reactive formatters from * `ctx`, `niceNum`-rounded y-axis bounds at fusion time, and * `positionDataZoomForLegend` layout for ZoomToggle sliders. */ export declare function createTimeseriesOptionFactory(options: TimeseriesOptionFactoryInput): OptionFactory;