@reside-ic/skadi-chart 1.1.14 → 1.1.16

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -6,6 +6,7 @@ declare module "d3" {
6
6
  export { create, type BaseType, type Selection, type ClientPointEvent, pointer } from "d3-selection";
7
7
  export { brush, type D3BrushEvent } from "d3-brush";
8
8
  export { scaleBand, scaleLinear, scaleLog, type NumberValue, type ScaleBand, type ScaleContinuousNumeric } from "d3-scale";
9
+ export { format } from "d3-format";
9
10
  }
10
11
  declare module "types" {
11
12
  import { ChartOptions } from "Chart";
@@ -205,7 +206,7 @@ declare module "layers/AxesLayer" {
205
206
  }
206
207
  declare module "layers/ZoomLayer" {
207
208
  import { LayerType, OptionalLayer } from "layers/Layer";
208
- import { D3Selection, LayerArgs } from "types";
209
+ import { D3Selection, LayerArgs, ZoomProperties } from "types";
209
210
  export type ZoomOptions = {
210
211
  lockAxis: "x" | "y" | null;
211
212
  };
@@ -215,9 +216,9 @@ declare module "layers/ZoomLayer" {
215
216
  zooming: boolean;
216
217
  selectionMask: D3Selection<SVGRectElement> | null;
217
218
  overlay: D3Selection<SVGRectElement> | null;
219
+ handleZoom: (zoomProperties: ZoomProperties) => Promise<void>;
218
220
  constructor(options: ZoomOptions);
219
221
  private processSelection;
220
- private handleZoom;
221
222
  private handleBrushEnd;
222
223
  private handleBrushMove;
223
224
  draw: (layerArgs: LayerArgs) => void;
@@ -284,7 +285,7 @@ declare module "Chart" {
284
285
  import { TracesOptions } from "layers/TracesLayer";
285
286
  import { ZoomOptions } from "layers/ZoomLayer";
286
287
  import { TooltipHtmlCallback } from "layers/TooltipsLayer";
287
- import { AllOptionalLayers, Bounds, LayerArgs, Lines, PartialScales, Scales, ScatterPoints, XY, ClipPathBounds, TickConfig } from "types";
288
+ import { AllOptionalLayers, Bounds, LayerArgs, Lines, PartialScales, Scales, ScatterPoints, XY, ClipPathBounds, TickConfig, ZoomProperties } from "types";
288
289
  import { LifecycleHooks, OptionalLayer } from "layers/Layer";
289
290
  import { GridOptions } from "layers/GridLayer";
290
291
  export type ChartOptions = {
@@ -300,6 +301,7 @@ declare module "Chart" {
300
301
  categorical?: Partial<XY<Partial<TickConfig<string>>>>;
301
302
  };
302
303
  };
304
+ export const defaultFormatter: (val: number) => string;
303
305
  export class Chart<Metadata = any> {
304
306
  id: string;
305
307
  optionalLayers: AllOptionalLayers[];
@@ -317,6 +319,7 @@ declare module "Chart" {
317
319
  exportToPng: ((name?: string) => void) | null;
318
320
  options: ChartOptions;
319
321
  autoscaledMaxExtents: Scales;
322
+ handleZoom: (zoomProperties: ZoomProperties) => Promise<void>;
320
323
  constructor(options?: PartialChartOptions);
321
324
  addAxes: (labels?: Partial<XY<string>>, labelPositions?: Partial<XY<number>>, includeZeroLine?: Partial<XY<boolean>>) => this;
322
325
  addGridLines: (options?: Partial<XY<Partial<GridOptions>>>) => this;