@luxalgo/vela 0.6.10 → 0.6.12

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.
Files changed (42) hide show
  1. package/README.md +110 -46
  2. package/dist/{DataProvider-CWmp31dA.d.ts → DataProvider-DhzstpQb.d.ts} +1 -1
  3. package/dist/{DataProvider-l_eLMly_.d.cts → DataProvider-DlMtrwqM.d.cts} +1 -1
  4. package/dist/{chunk-4KZVZ7QQ.js → chunk-F4M24ANM.js} +130 -1
  5. package/dist/{chunk-NMTQXNT4.js → chunk-IZV3CW5N.js} +245 -43
  6. package/dist/{chunk-FFOP37FQ.js → chunk-KV7FDWSL.js} +748 -70
  7. package/dist/{contributions-BCz6Dr6a.d.ts → contributions-37nni40G.d.ts} +20 -4
  8. package/dist/{contributions-D9vTzm5p.d.cts → contributions-lPojhTxI.d.cts} +20 -4
  9. package/dist/index.cjs +866 -58
  10. package/dist/index.d.cts +12 -6
  11. package/dist/index.d.ts +12 -6
  12. package/dist/index.js +3 -3
  13. package/dist/{options-DSqHsQyN.d.cts → options-CYS5Wmlx.d.cts} +78 -2
  14. package/dist/{options-DSqHsQyN.d.ts → options-CYS5Wmlx.d.ts} +78 -2
  15. package/dist/{plugin-Bt8hLR8Z.d.cts → plugin-Cwikpz1m.d.cts} +10 -3
  16. package/dist/{plugin-CH7pfMrE.d.ts → plugin-DHyaoMjW.d.ts} +10 -3
  17. package/dist/plugin.cjs +119 -0
  18. package/dist/plugin.d.cts +4 -4
  19. package/dist/plugin.d.ts +4 -4
  20. package/dist/plugin.js +2 -2
  21. package/dist/providers/binance.d.cts +2 -2
  22. package/dist/providers/binance.d.ts +2 -2
  23. package/dist/providers/coinbase.d.cts +2 -2
  24. package/dist/providers/coinbase.d.ts +2 -2
  25. package/dist/providers/hyperliquid.d.cts +2 -2
  26. package/dist/providers/hyperliquid.d.ts +2 -2
  27. package/dist/{statusline-5K7y4Ya2.d.ts → statusline-model-CiJm-riV.d.cts} +17 -87
  28. package/dist/{statusline-TYLQmoeh.d.cts → statusline-model-D-q_OOx9.d.ts} +17 -87
  29. package/dist/ui.d.cts +1 -1
  30. package/dist/ui.d.ts +1 -1
  31. package/dist/vela.global.js +866 -58
  32. package/dist/vela.global.min.js +52 -52
  33. package/dist/widget.cjs +1109 -100
  34. package/dist/widget.d.cts +118 -7
  35. package/dist/widget.d.ts +118 -7
  36. package/dist/widget.js +4 -4
  37. package/dist/workspace.cjs +1109 -100
  38. package/dist/workspace.d.cts +20 -11
  39. package/dist/workspace.d.ts +20 -11
  40. package/dist/workspace.js +3 -3
  41. package/package.json +1 -1
  42. /package/dist/{chunk-AOGZBKUE.js → chunk-H26BEHF4.js} +0 -0
@@ -1,5 +1,5 @@
1
- import { u as Millis, af as InputSchema, ad as IndicatorMeta, P as PriceStyle, O as OHLCV, m as InputValue, k as IndicatorModel, j as MoveTarget, ar as PaneAxis, aE as SeriesSpec, ab as Fill, B as Background, aw as PriceLine, a1 as DrawingLine, Z as DrawingBox, a0 as DrawingLabel, a5 as DrawingPolyline, a2 as DrawingLinefill, a7 as DrawingTable, g as IndicatorStatus, a as VisibleRange, c as VelaTheme, S as SerializedDrawing, w as DrawingTypeKey, v as SnapMode, a3 as DrawingMode, I as IChartRenderer, R as RendererCapabilities, o as LegendActionView, p as LegendCalloutView, U as Unsubscribe, C as CrosshairEvent, A as AxisLongPressEvent, s as DataWindowReadout, n as SymbolPickerFn, aS as PaneInfo, aa as DrawingsOption, D as Drawing, b as VelaOptions, y as AddIndicatorOptions, aq as MarketSwitch, ap as MarketSnapshot, V as VisibleRangePreset, T as ThemeName } from './options-DSqHsQyN.js';
2
- import { S as SymbolInfo, B as BarRange, M as MarketDataFeed, D as DataProvider, P as ProviderInfo, a as SymbolDescriptor, b as ProviderCapabilities } from './DataProvider-CWmp31dA.js';
1
+ import { u as Millis, ai as InputSchema, ag as IndicatorMeta, P as PriceStyle, O as OHLCV, I as InputValue, l as IndicatorModel, k as MoveTarget, au as PaneAxis, aH as SeriesSpec, ae as Fill, B as Background, az as PriceLine, a1 as DrawingLine, Z as DrawingBox, a0 as DrawingLabel, a5 as DrawingPolyline, a2 as DrawingLinefill, aa as DrawingTable, h as IndicatorStatus, a as VisibleRange, c as VelaTheme, S as SerializedDrawing, w as DrawingTypeKey, v as SnapMode, a3 as DrawingMode, e as IChartRenderer, R as RendererCapabilities, o as LegendActionView, p as LegendCalloutView, U as Unsubscribe, C as CrosshairEvent, A as AxisLongPressEvent, s as DataWindowReadout, n as SymbolPickerFn, aW as PaneInfo, ad as DrawingsOption, a7 as DrawingSeriesGateway, D as Drawing, b as VelaOptions, y as AddIndicatorOptions, at as MarketSwitch, as as MarketSnapshot, V as VisibleRangePreset, T as ThemeName } from './options-CYS5Wmlx.js';
2
+ import { S as SymbolInfo, B as BarRange, M as MarketDataFeed, D as DataProvider, P as ProviderInfo, a as SymbolDescriptor, b as ProviderCapabilities } from './DataProvider-DhzstpQb.js';
3
3
 
4
4
  /**
5
5
  * A strategy's broker state at ONE bar — the flat summary a host reads while a script
@@ -294,6 +294,12 @@ interface IndicatorHandle {
294
294
  readonly props: readonly InputSchema[];
295
295
  /** Whether the indicator is currently shown (vs hidden). Hidden indicators stop computing. */
296
296
  readonly visible: boolean;
297
+ /** The CURRENT stored input values (declaration defaults merged with every edit so
298
+ * far) — what state persistence diffs against the schema's `defval`s. */
299
+ inputValues(): Record<string, InputValue>;
300
+ /** The CURRENT stored declaration-prop values (overrides only — props keep no
301
+ * merged defaults; absent keys mean the declaration value). */
302
+ propValues(): Record<string, InputValue>;
297
303
  setInput(key: string, value: InputValue): void;
298
304
  setInputs(values: Record<string, InputValue>): void;
299
305
  /** Override one declaration prop and re-run (a prop change replays the whole script). */
@@ -661,6 +667,10 @@ interface VelaEventMap extends Record<string, unknown> {
661
667
  "indicator:removed": {
662
668
  id: string;
663
669
  };
670
+ /** An indicator's stored input/prop VALUES changed (settings dialog, `setInputs`) — what state persistence listens to. */
671
+ "indicator:inputs": {
672
+ id: string;
673
+ };
664
674
  "indicator:error": {
665
675
  id: string;
666
676
  error: Error;
@@ -1093,7 +1103,7 @@ declare class DrawingController {
1093
1103
  private clipboard;
1094
1104
  private readonly lastStyle;
1095
1105
  private readonly subs;
1096
- constructor(renderer: IChartRenderer, events: TypedEventBus<VelaEventMap>, option: DrawingsOption | undefined);
1106
+ constructor(renderer: IChartRenderer, events: TypedEventBus<VelaEventMap>, option: DrawingsOption | undefined, seriesGateway?: DrawingSeriesGateway);
1097
1107
  /** Whether the active renderer supports interactive drawings. */
1098
1108
  get supported(): boolean;
1099
1109
  setTool(type: DrawingTypeKey | null): void;
@@ -1143,7 +1153,9 @@ declare class DrawingController {
1143
1153
  * (falling back to just under the pane's top series where there is no price — a study
1144
1154
  * pane). Half a key down never ties a series; drawings tying each other paint in insertion
1145
1155
  * order, so consecutive new drawings still stack newest-in-front. Undefined without a
1146
- * shared z space — the store then places it over the other drawings, its own layer's top. */
1156
+ * shared z space — the store then places it over the other drawings, its own layer's top.
1157
+ * A type that COVERS the series (an opaque inset, `coversSeries`) instead starts just
1158
+ * above the whole stack — under the candles its content would be buried. */
1147
1159
  private startZ;
1148
1160
  /** Programmatically select drawings (host UI → chart): shows the on-chart handles + toolbar.
1149
1161
  * `additive` toggles membership (matching shift-click) instead of replacing. */
@@ -1516,6 +1528,10 @@ interface ExternalIndicatorEntry {
1516
1528
  script: string;
1517
1529
  /** Engine language (default: the chart's default engine). */
1518
1530
  language?: string;
1531
+ /** Input-value overrides applied at add time (what a persistence handler restores). */
1532
+ inputs?: Record<string, InputValue>;
1533
+ /** Declaration-prop overrides applied at add time. */
1534
+ props?: Record<string, InputValue>;
1519
1535
  }
1520
1536
  /** Where an action is projected. */
1521
1537
  type WidgetActionTarget = 'topbar' | 'context:body' | 'context:price-axis' | 'context:time-axis';
@@ -1,5 +1,5 @@
1
- import { u as Millis, af as InputSchema, ad as IndicatorMeta, P as PriceStyle, O as OHLCV, m as InputValue, k as IndicatorModel, j as MoveTarget, ar as PaneAxis, aE as SeriesSpec, ab as Fill, B as Background, aw as PriceLine, a1 as DrawingLine, Z as DrawingBox, a0 as DrawingLabel, a5 as DrawingPolyline, a2 as DrawingLinefill, a7 as DrawingTable, g as IndicatorStatus, a as VisibleRange, c as VelaTheme, S as SerializedDrawing, w as DrawingTypeKey, v as SnapMode, a3 as DrawingMode, I as IChartRenderer, R as RendererCapabilities, o as LegendActionView, p as LegendCalloutView, U as Unsubscribe, C as CrosshairEvent, A as AxisLongPressEvent, s as DataWindowReadout, n as SymbolPickerFn, aS as PaneInfo, aa as DrawingsOption, D as Drawing, b as VelaOptions, y as AddIndicatorOptions, aq as MarketSwitch, ap as MarketSnapshot, V as VisibleRangePreset, T as ThemeName } from './options-DSqHsQyN.cjs';
2
- import { S as SymbolInfo, B as BarRange, M as MarketDataFeed, D as DataProvider, P as ProviderInfo, a as SymbolDescriptor, b as ProviderCapabilities } from './DataProvider-l_eLMly_.cjs';
1
+ import { u as Millis, ai as InputSchema, ag as IndicatorMeta, P as PriceStyle, O as OHLCV, I as InputValue, l as IndicatorModel, k as MoveTarget, au as PaneAxis, aH as SeriesSpec, ae as Fill, B as Background, az as PriceLine, a1 as DrawingLine, Z as DrawingBox, a0 as DrawingLabel, a5 as DrawingPolyline, a2 as DrawingLinefill, aa as DrawingTable, h as IndicatorStatus, a as VisibleRange, c as VelaTheme, S as SerializedDrawing, w as DrawingTypeKey, v as SnapMode, a3 as DrawingMode, e as IChartRenderer, R as RendererCapabilities, o as LegendActionView, p as LegendCalloutView, U as Unsubscribe, C as CrosshairEvent, A as AxisLongPressEvent, s as DataWindowReadout, n as SymbolPickerFn, aW as PaneInfo, ad as DrawingsOption, a7 as DrawingSeriesGateway, D as Drawing, b as VelaOptions, y as AddIndicatorOptions, at as MarketSwitch, as as MarketSnapshot, V as VisibleRangePreset, T as ThemeName } from './options-CYS5Wmlx.cjs';
2
+ import { S as SymbolInfo, B as BarRange, M as MarketDataFeed, D as DataProvider, P as ProviderInfo, a as SymbolDescriptor, b as ProviderCapabilities } from './DataProvider-DlMtrwqM.cjs';
3
3
 
4
4
  /**
5
5
  * A strategy's broker state at ONE bar — the flat summary a host reads while a script
@@ -294,6 +294,12 @@ interface IndicatorHandle {
294
294
  readonly props: readonly InputSchema[];
295
295
  /** Whether the indicator is currently shown (vs hidden). Hidden indicators stop computing. */
296
296
  readonly visible: boolean;
297
+ /** The CURRENT stored input values (declaration defaults merged with every edit so
298
+ * far) — what state persistence diffs against the schema's `defval`s. */
299
+ inputValues(): Record<string, InputValue>;
300
+ /** The CURRENT stored declaration-prop values (overrides only — props keep no
301
+ * merged defaults; absent keys mean the declaration value). */
302
+ propValues(): Record<string, InputValue>;
297
303
  setInput(key: string, value: InputValue): void;
298
304
  setInputs(values: Record<string, InputValue>): void;
299
305
  /** Override one declaration prop and re-run (a prop change replays the whole script). */
@@ -661,6 +667,10 @@ interface VelaEventMap extends Record<string, unknown> {
661
667
  "indicator:removed": {
662
668
  id: string;
663
669
  };
670
+ /** An indicator's stored input/prop VALUES changed (settings dialog, `setInputs`) — what state persistence listens to. */
671
+ "indicator:inputs": {
672
+ id: string;
673
+ };
664
674
  "indicator:error": {
665
675
  id: string;
666
676
  error: Error;
@@ -1093,7 +1103,7 @@ declare class DrawingController {
1093
1103
  private clipboard;
1094
1104
  private readonly lastStyle;
1095
1105
  private readonly subs;
1096
- constructor(renderer: IChartRenderer, events: TypedEventBus<VelaEventMap>, option: DrawingsOption | undefined);
1106
+ constructor(renderer: IChartRenderer, events: TypedEventBus<VelaEventMap>, option: DrawingsOption | undefined, seriesGateway?: DrawingSeriesGateway);
1097
1107
  /** Whether the active renderer supports interactive drawings. */
1098
1108
  get supported(): boolean;
1099
1109
  setTool(type: DrawingTypeKey | null): void;
@@ -1143,7 +1153,9 @@ declare class DrawingController {
1143
1153
  * (falling back to just under the pane's top series where there is no price — a study
1144
1154
  * pane). Half a key down never ties a series; drawings tying each other paint in insertion
1145
1155
  * order, so consecutive new drawings still stack newest-in-front. Undefined without a
1146
- * shared z space — the store then places it over the other drawings, its own layer's top. */
1156
+ * shared z space — the store then places it over the other drawings, its own layer's top.
1157
+ * A type that COVERS the series (an opaque inset, `coversSeries`) instead starts just
1158
+ * above the whole stack — under the candles its content would be buried. */
1147
1159
  private startZ;
1148
1160
  /** Programmatically select drawings (host UI → chart): shows the on-chart handles + toolbar.
1149
1161
  * `additive` toggles membership (matching shift-click) instead of replacing. */
@@ -1516,6 +1528,10 @@ interface ExternalIndicatorEntry {
1516
1528
  script: string;
1517
1529
  /** Engine language (default: the chart's default engine). */
1518
1530
  language?: string;
1531
+ /** Input-value overrides applied at add time (what a persistence handler restores). */
1532
+ inputs?: Record<string, InputValue>;
1533
+ /** Declaration-prop overrides applied at add time. */
1534
+ props?: Record<string, InputValue>;
1519
1535
  }
1520
1536
  /** Where an action is projected. */
1521
1537
  type WidgetActionTarget = 'topbar' | 'context:body' | 'context:price-axis' | 'context:time-axis';