@pipsend/charts 2.3.17 → 2.3.19

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.
package/dist/typings.d.ts CHANGED
@@ -185,6 +185,11 @@ export declare class BrushTool extends DrawingToolBase {
185
185
  startDrawingMode(): void;
186
186
  stopDrawingMode(): void;
187
187
  isDrawingModeActive(): boolean;
188
+ /**
189
+ * A brush armed for its next stroke is not a drawing yet: it stays out of the
190
+ * undo history, where restoring it would re-arm a brush the app does not hold.
191
+ */
192
+ isComplete(): boolean;
188
193
  private _onPointerDown;
189
194
  private _onPointerMove;
190
195
  private _onPointerUp;
@@ -2474,6 +2479,7 @@ export declare function createTextTool(context: DrawingContext, options: TextToo
2474
2479
  * ```
2475
2480
  */
2476
2481
  export declare function createTextWatermark<T>(pane: IPaneApi<T>, options: DeepPartial<TextWatermarkOptions>): ITextWatermarkPluginApi<T>;
2482
+ export declare function createTimeLabels<HorzScaleItem>(series: ISeriesApi<SeriesType, HorzScaleItem>, labels?: readonly TimeLabel<HorzScaleItem>[], options?: DeepPartial<TimeLabelsOptions>): ITimeLabelsPluginApi<HorzScaleItem>;
2477
2483
  /**
2478
2484
  * Create a flexible trading line with presets for common trading scenarios
2479
2485
  * @param series - Series to attach the line to
@@ -5296,6 +5302,12 @@ export interface ISeriesUpDownMarkerPluginApi<HorzScaleItem, TData extends Serie
5296
5302
  */
5297
5303
  clearMarkers: () => void;
5298
5304
  }
5305
+ export interface ITimeLabelsPluginApi<HorzScaleItem> extends ISeriesPrimitiveWrapper<HorzScaleItem, TimeLabelsOptions> {
5306
+ setLabels: (labels: readonly TimeLabel<HorzScaleItem>[]) => void;
5307
+ labels: () => readonly TimeLabel<HorzScaleItem>[];
5308
+ applyOptions: (options: DeepPartial<TimeLabelsOptions>) => void;
5309
+ detach: () => void;
5310
+ }
5299
5311
  /** Interface to chart time scale */
5300
5312
  export interface ITimeScaleApi<HorzScaleItem> {
5301
5313
  /**
@@ -7397,6 +7409,19 @@ export interface TimeChartOptions extends ChartOptionsImpl<Time> {
7397
7409
  */
7398
7410
  timeScale: TimeScaleOptions;
7399
7411
  }
7412
+ export interface TimeLabel<HorzScaleItem> {
7413
+ time: HorzScaleItem;
7414
+ text: string;
7415
+ color?: string;
7416
+ size?: number;
7417
+ }
7418
+ export interface TimeLabelsOptions {
7419
+ position: "bottom" | "top";
7420
+ offset: number;
7421
+ fontSize: number;
7422
+ fontFamily: string;
7423
+ color: string;
7424
+ }
7400
7425
  /**
7401
7426
  * Represents a tick mark on the horizontal (time) scale.
7402
7427
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "private": false,
3
- "version": "2.3.17",
3
+ "version": "2.3.19",
4
4
  "name": "@pipsend/charts",
5
5
  "author": "Pipsend",
6
6
  "license": "SEE LICENSE IN LICENSE",