velo-plot 1.19.0 → 2.20.0

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 (86) hide show
  1. package/dist/{ChartCore-DQ691eXH.js → ChartCore-ivzLqxVb.js} +1376 -1153
  2. package/dist/ChartCore-ivzLqxVb.js.map +1 -0
  3. package/dist/SciPlot-CEU4ApgD.js +463 -0
  4. package/dist/SciPlot-CEU4ApgD.js.map +1 -0
  5. package/dist/axisFormat-CzumxpCL.js +200 -0
  6. package/dist/axisFormat-CzumxpCL.js.map +1 -0
  7. package/dist/core/InteractionManager.d.ts +1 -0
  8. package/dist/core/OverlayRenderer.d.ts +11 -0
  9. package/dist/core/chart/ChartAxisManager.d.ts +2 -0
  10. package/dist/core/chart/ChartCore.d.ts +20 -0
  11. package/dist/core/chart/ChartPluginBridge.d.ts +1 -0
  12. package/dist/core/chart/ChartRenderLoop.d.ts +7 -0
  13. package/dist/core/chart/ChartRenderer.d.ts +5 -0
  14. package/dist/core/chart/ChartStateManager.d.ts +2 -0
  15. package/dist/core/chart/positionLines.d.ts +12 -0
  16. package/dist/core/chart/types.d.ts +7 -0
  17. package/dist/core/format/axisFormat.d.ts +2 -1
  18. package/dist/core/indicator/addIndicator.d.ts +1 -1
  19. package/dist/core/indicator/indicatorPresets.d.ts +10 -2
  20. package/dist/core/sync/index.d.ts +0 -1
  21. package/dist/core/time/TimeScale.d.ts +2 -2
  22. package/dist/core/time/applyTimeScale.d.ts +10 -0
  23. package/dist/createStackedChart-DxNW0VkF.js +705 -0
  24. package/dist/createStackedChart-DxNW0VkF.js.map +1 -0
  25. package/dist/{index-D7dTq6VB.js → index-BBpJwOct.js} +17 -19
  26. package/dist/index-BBpJwOct.js.map +1 -0
  27. package/dist/{index-CUGS98p4.js → index-CaXWSOTk.js} +3 -6
  28. package/dist/index-CaXWSOTk.js.map +1 -0
  29. package/dist/{index-DjeWClO9.js → index-qunX30Xu.js} +2 -2
  30. package/dist/{index-DjeWClO9.js.map → index-qunX30Xu.js.map} +1 -1
  31. package/dist/{index.core-BtGFYMOu.js → index.core-COREBDNq.js} +25 -24
  32. package/dist/{index.core-BtGFYMOu.js.map → index.core-COREBDNq.js.map} +1 -1
  33. package/dist/index.d.ts +6 -1
  34. package/dist/mockDatafeed-927foCM4.js +511 -0
  35. package/dist/mockDatafeed-927foCM4.js.map +1 -0
  36. package/dist/plugins/analysis/contours.d.ts +31 -0
  37. package/dist/plugins/analysis.js +494 -407
  38. package/dist/plugins/analysis.js.map +1 -1
  39. package/dist/plugins/broken-axis.js +170 -181
  40. package/dist/plugins/broken-axis.js.map +1 -1
  41. package/dist/plugins/drawing-tools/index.d.ts +14 -1
  42. package/dist/plugins/drawing-tools/measure.d.ts +21 -0
  43. package/dist/plugins/drawing-tools/snapToCandle.d.ts +21 -0
  44. package/dist/plugins/forecasting/algorithms.d.ts +7 -2
  45. package/dist/plugins/forecasting/types.d.ts +13 -3
  46. package/dist/plugins/forecasting.js +355 -175
  47. package/dist/plugins/forecasting.js.map +1 -1
  48. package/dist/plugins/latex/symbols.d.ts +50 -0
  49. package/dist/plugins/latex/types.d.ts +13 -1
  50. package/dist/plugins/latex.js +351 -331
  51. package/dist/plugins/latex.js.map +1 -1
  52. package/dist/plugins/ml-integration/native-algorithms.d.ts +24 -4
  53. package/dist/plugins/ml-integration/types.d.ts +19 -0
  54. package/dist/plugins/ml-integration.js +191 -140
  55. package/dist/plugins/ml-integration.js.map +1 -1
  56. package/dist/plugins/pattern-recognition/types.d.ts +28 -1
  57. package/dist/plugins/pattern-recognition.js +416 -343
  58. package/dist/plugins/pattern-recognition.js.map +1 -1
  59. package/dist/plugins/snapshot.js +36 -36
  60. package/dist/plugins/snapshot.js.map +1 -1
  61. package/dist/plugins/sync.js +1 -1
  62. package/dist/plugins/tools.js +1 -1
  63. package/dist/plugins/virtualization.js +1 -1
  64. package/dist/react.js +5 -5
  65. package/dist/symbols-DT0eLlpW.js +568 -0
  66. package/dist/symbols-DT0eLlpW.js.map +1 -0
  67. package/dist/trading/datafeed.d.ts +48 -0
  68. package/dist/trading/index.d.ts +29 -0
  69. package/dist/trading/mockDatafeed.d.ts +9 -0
  70. package/dist/trading/ohlcvGenerator.d.ts +25 -0
  71. package/dist/trading.d.ts +1 -0
  72. package/dist/trading.js +95 -0
  73. package/dist/trading.js.map +1 -0
  74. package/dist/types.d.ts +1 -1
  75. package/dist/velo-plot.full.js +835 -1054
  76. package/dist/velo-plot.full.js.map +1 -1
  77. package/dist/velo-plot.js +13 -13
  78. package/dist/workers/indicatorsAsync.d.ts +24 -0
  79. package/package.json +13 -1
  80. package/dist/ChartCore-DQ691eXH.js.map +0 -1
  81. package/dist/axisFormat-B7o_uIEA.js +0 -127
  82. package/dist/axisFormat-B7o_uIEA.js.map +0 -1
  83. package/dist/createStackedChart-BPooTQ9z.js +0 -1164
  84. package/dist/createStackedChart-BPooTQ9z.js.map +0 -1
  85. package/dist/index-CUGS98p4.js.map +0 -1
  86. package/dist/index-D7dTq6VB.js.map +0 -1
package/dist/velo-plot.js CHANGED
@@ -1,32 +1,32 @@
1
- import { A as r, D as s, h as t, x as n, u as i, L as g, n as o, N as c, a3 as l, S as E, c as m, N as u, a2 as T, o as A, y as N, f, j as L, z as P, t as d } from "./ChartCore-DQ691eXH.js";
2
- import { E as S } from "./axisFormat-B7o_uIEA.js";
3
- import { h as x, f as C, c as I, d as M, g as R, r as _ } from "./index.core-BtGFYMOu.js";
1
+ import { A as r, D as s, l as t, f as n, L as i, j as g, u as l, N as o, a5 as c, S as E, c as m, N as u, a4 as T, v as A, B as N, k as f, o as L, F as P, y as d } from "./ChartCore-ivzLqxVb.js";
2
+ import { E as h } from "./axisFormat-CzumxpCL.js";
3
+ import { h as C, f as I, c as M, d as R, g as _, r as v } from "./index.core-COREBDNq.js";
4
4
  export {
5
5
  r as AnimationEngine,
6
6
  s as DARK_THEME,
7
7
  t as DEFAULT_ANIMATION_CONFIG,
8
8
  n as DEFAULT_THEME,
9
- S as EventEmitter,
9
+ h as EventEmitter,
10
10
  i as LIGHT_THEME,
11
11
  g as LinearScale,
12
- o as LogScale,
13
- c as NativeWebGLRenderer,
14
- l as PluginManagerImpl,
12
+ l as LogScale,
13
+ o as NativeWebGLRenderer,
14
+ c as PluginManagerImpl,
15
15
  E as Series,
16
16
  m as createChart,
17
- x as createConfigurablePlugin,
17
+ C as createConfigurablePlugin,
18
18
  u as createNativeRenderer,
19
- C as createPlugin,
19
+ I as createPlugin,
20
20
  T as createPluginContext,
21
- I as createRenderer,
21
+ M as createRenderer,
22
22
  A as createScale,
23
23
  N as createTheme,
24
- M as definePlugin,
24
+ R as definePlugin,
25
25
  f as easings,
26
- R as getPluginRegistry,
26
+ _ as getPluginRegistry,
27
27
  L as getSharedAnimationEngine,
28
28
  P as getThemeByName,
29
29
  d as parseColor,
30
- _ as registerPlugin
30
+ v as registerPlugin
31
31
  };
32
32
  //# sourceMappingURL=velo-plot.js.map
@@ -1,5 +1,28 @@
1
1
  import { IndicatorResult } from '../plugins/analysis/indicators';
2
2
 
3
+ type IndicatorName = "rsi" | "macd" | "bollingerBands" | "sma" | "ema";
4
+ interface IndicatorTaskPayload {
5
+ id: string;
6
+ type: "indicator";
7
+ indicator: IndicatorName;
8
+ data: Float32Array | Float64Array;
9
+ period?: number;
10
+ fastPeriod?: number;
11
+ slowPeriod?: number;
12
+ signalPeriod?: number;
13
+ stdDev?: number;
14
+ }
15
+ interface IndicatorTaskResult extends IndicatorResult {
16
+ id: string;
17
+ type: "indicator-result";
18
+ indicator: string;
19
+ duration: number;
20
+ }
21
+ /**
22
+ * Synchronous indicator computation shared by the sync fallback path.
23
+ * Exported so the parameter defaults and dispatch can be unit-tested directly.
24
+ */
25
+ export declare function computeIndicatorSync(task: IndicatorTaskPayload): IndicatorTaskResult;
3
26
  /** Async RSI — non-blocking for large datasets */
4
27
  export declare function rsiAsync(data: Float32Array | Float64Array | number[], period?: number): Promise<IndicatorResult & {
5
28
  duration: number;
@@ -24,3 +47,4 @@ export declare function bollingerBandsAsync(data: Float32Array | Float64Array |
24
47
  export declare function destroyIndicatorPool(): void;
25
48
  /** Exposed for tests */
26
49
  export declare function getIndicatorPoolSize(): number;
50
+ export {};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "velo-plot",
3
- "version": "1.19.0",
3
+ "version": "2.20.0",
4
4
  "author": "jigonzalez930209",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -34,6 +34,10 @@
34
34
  "types": "./dist/index.d.ts",
35
35
  "import": "./dist/velo-plot.full.js"
36
36
  },
37
+ "./trading": {
38
+ "types": "./dist/trading/index.d.ts",
39
+ "import": "./dist/trading.js"
40
+ },
37
41
  "./react": {
38
42
  "types": "./dist/react/index.d.ts",
39
43
  "import": "./dist/react.js"
@@ -196,8 +200,16 @@
196
200
  "test:watch": "vitest",
197
201
  "test:dom": "vitest run .dom.test.ts",
198
202
  "test:e2e": "playwright test",
203
+ "test:e2e:artifacts": "E2E_FULL_ARTIFACTS=1 playwright test",
204
+ "test:e2e:report": "playwright show-report test-results/e2e/report",
205
+ "test:e2e:install": "node scripts/playwright-install.mjs",
206
+ "test:e2e:install:deps": "PLAYWRIGHT_INSTALL_DEPS=1 node scripts/playwright-install.mjs",
207
+ "test:e2e:setup": "pnpm build && pnpm test:e2e:install",
199
208
  "test:e2e:ui": "playwright test --ui",
200
209
  "test:e2e:headed": "playwright test --headed",
210
+ "test:e2e:chromium": "playwright test --project chromium",
211
+ "test:e2e:firefox": "playwright test --project firefox",
212
+ "test:e2e:webkit": "playwright test --project webkit",
201
213
  "test:browser-bench": "node scripts/browser-benchmark.mjs",
202
214
  "test:browser-bench:headed": "HEADED=1 node scripts/browser-benchmark.mjs",
203
215
  "test:all": "pnpm test && pnpm test:dom && pnpm test:e2e && pnpm test:browser-bench",