@vninvestcharts/widget 0.0.0-stage → 0.2.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.
- package/LICENSE +201 -0
- package/NOTICE.md +83 -0
- package/README.md +851 -3
- package/dist/AlertsModal-WKEUDTUZ.js +2 -0
- package/dist/ConnectedTradingPanel-KWJMIKTN.css +2 -0
- package/dist/ConnectedTradingPanel-XDKMOQY5.js +2 -0
- package/dist/PineEditorPanel-AUXB4FD3.js +2 -0
- package/dist/PineEditorPanel-V6YN2OTU.css +2 -0
- package/dist/RightSidebarDockHost-6FPZ6EKV.css +2 -0
- package/dist/RightSidebarDockHost-OBFXKSIY.js +2 -0
- package/dist/StrategyTesterPanel-6IUTS2P4.js +2 -0
- package/dist/StrategyTesterPanel-LEWEUMXP.css +2 -0
- package/dist/VolumeProfileWorker-UREKVPUE.js +189 -0
- package/dist/adapters/index.cjs +2532 -0
- package/dist/adapters/index.d.mts +673 -0
- package/dist/adapters/index.d.ts +673 -0
- package/dist/adapters/index.js +2521 -0
- package/dist/adapters/index.umd.js +2535 -0
- package/dist/chunk-5T6DGB3V.js +2 -0
- package/dist/chunk-66JBEGR3.js +4 -0
- package/dist/chunk-6D7DVBIK.js +2 -0
- package/dist/chunk-76E7CKUD.js +2 -0
- package/dist/chunk-AKWVXRQ6.js +2 -0
- package/dist/chunk-FHHSTO6Z.js +2 -0
- package/dist/chunk-HPL723JA.js +2 -0
- package/dist/chunk-NVGTF73S.js +2 -0
- package/dist/chunk-PNIB4OM3.js +2 -0
- package/dist/chunk-UKJ5AKQX.js +595 -0
- package/dist/chunk-UYJTX3SD.js +2 -0
- package/dist/combined.css +3068 -0
- package/dist/css-modules-manifest.json +297 -0
- package/dist/dist-Y6PZ2RN3.js +12 -0
- package/dist/drawing/index.cjs +53 -0
- package/dist/drawing/index.d.mts +2 -0
- package/dist/drawing/index.d.ts +2 -0
- package/dist/drawing/index.js +2 -0
- package/dist/drawing/index.umd.js +54 -0
- package/dist/dts/drawing-shim.d.ts +3 -0
- package/dist/dts/index.d.ts +31 -0
- package/dist/dts/lib/Chart.d.ts +31 -0
- package/dist/dts/lib/ChartContext.d.ts +10 -0
- package/dist/dts/lib/EventCapture.d.ts +3 -0
- package/dist/dts/lib/GenericChartComponent.d.ts +5 -0
- package/dist/dts/lib/GenericComponent.d.ts +124 -0
- package/dist/dts/lib/StockChartContext.d.ts +53 -0
- package/dist/dts/lib/adapters/BaseAdapter.d.ts +25 -0
- package/dist/dts/lib/adapters/BinanceAdapter.d.ts +51 -0
- package/dist/dts/lib/adapters/CSVAdapter.d.ts +17 -0
- package/dist/dts/lib/adapters/ContinuousContractAdapter.d.ts +63 -0
- package/dist/dts/lib/adapters/ContinuousContractTypes.d.ts +154 -0
- package/dist/dts/lib/adapters/DBAdapter.d.ts +16 -0
- package/dist/dts/lib/adapters/DataAdapter.d.ts +136 -0
- package/dist/dts/lib/adapters/DjangoVnstockAdapter.d.ts +15 -0
- package/dist/dts/lib/adapters/LocalCacheAdapter.d.ts +18 -0
- package/dist/dts/lib/adapters/MockAdapter.d.ts +22 -0
- package/dist/dts/lib/adapters/RESTAdapter.d.ts +16 -0
- package/dist/dts/lib/adapters/StockDataAdapter.d.ts +1 -0
- package/dist/dts/lib/adapters/UDFDataAdapter.d.ts +29 -0
- package/dist/dts/lib/adapters/VNStocksAdapter.d.ts +8 -0
- package/dist/dts/lib/adapters/WSAdapter.d.ts +30 -0
- package/dist/dts/lib/adapters/gapFixture.d.ts +71 -0
- package/dist/dts/lib/adapters/index.d.ts +15 -0
- package/dist/dts/lib/adapters/rollAlgorithms.d.ts +68 -0
- package/dist/dts/lib/advisory/AdvisoryPanel.d.ts +5 -0
- package/dist/dts/lib/alerts/AlertEvaluator.d.ts +5 -0
- package/dist/dts/lib/alerts/AlertManager.d.ts +123 -0
- package/dist/dts/lib/alerts/types.d.ts +58 -0
- package/dist/dts/lib/cache/cacheDebug.d.ts +3 -0
- package/dist/dts/lib/calendars/ExchangeCalendar.d.ts +23 -0
- package/dist/dts/lib/calendars/calendarRegistry.d.ts +10 -0
- package/dist/dts/lib/calendars/index.d.ts +3 -0
- package/dist/dts/lib/core/ChartPane.d.ts +8 -0
- package/dist/dts/lib/core/ChartSplitter.d.ts +70 -0
- package/dist/dts/lib/core/ChartTerminal.d.ts +12 -0
- package/dist/dts/lib/core/ErrorBoundary.d.ts +17 -0
- package/dist/dts/lib/core/IndicatorLegend.d.ts +47 -0
- package/dist/dts/lib/core/PaneHeader.d.ts +24 -0
- package/dist/dts/lib/core/PaneLabel.d.ts +8 -0
- package/dist/dts/lib/core/PaneSplitter.d.ts +9 -0
- package/dist/dts/lib/core/SeriesPicker.d.ts +10 -0
- package/dist/dts/lib/core/calculators/alignBarsByDate.d.ts +38 -0
- package/dist/dts/lib/core/calculators/buildIndicatorComputationPlan.d.ts +16 -0
- package/dist/dts/lib/core/calculators/calcCVDApprox.d.ts +6 -0
- package/dist/dts/lib/core/calculators/calcStrengthElder.d.ts +7 -0
- package/dist/dts/lib/core/calculators/calcWhaleApprox.d.ts +6 -0
- package/dist/dts/lib/core/calculators/computationHelpers.d.ts +12 -0
- package/dist/dts/lib/core/calculators/computeIndicatorComputationResult.d.ts +3 -0
- package/dist/dts/lib/core/calculators/computeMarketStructure.d.ts +8 -0
- package/dist/dts/lib/core/calculators/computeMomentum.d.ts +22 -0
- package/dist/dts/lib/core/calculators/computeMovingAverage.d.ts +15 -0
- package/dist/dts/lib/core/calculators/computeProfile.d.ts +9 -0
- package/dist/dts/lib/core/calculators/computeTrend.d.ts +10 -0
- package/dist/dts/lib/core/calculators/computeVolatility.d.ts +14 -0
- package/dist/dts/lib/core/calculators/computeVolumeFlow.d.ts +19 -0
- package/dist/dts/lib/core/calculators/enrichData.d.ts +7 -0
- package/dist/dts/lib/core/calculators/enrichDataWithCanonicalStore.d.ts +33 -0
- package/dist/dts/lib/core/calculators/exoticChartData.d.ts +140 -0
- package/dist/dts/lib/core/calculators/fixtures/mockData.d.ts +2 -0
- package/dist/dts/lib/core/calculators/indicatorComputation.d.ts +27 -0
- package/dist/dts/lib/core/calculators/indicatorComputationTypes.d.ts +249 -0
- package/dist/dts/lib/core/calculators/materializeIndicatorValues.d.ts +3 -0
- package/dist/dts/lib/core/calculators/normalizePrices.d.ts +36 -0
- package/dist/dts/lib/core/calculators/resolveCalculationOrder.d.ts +17 -0
- package/dist/dts/lib/core/calculators/types.d.ts +269 -0
- package/dist/dts/lib/core/canvas/ChartRenderContext.d.ts +14 -0
- package/dist/dts/lib/core/canvas/OverlayCanvas.d.ts +19 -0
- package/dist/dts/lib/core/context/ChartSyncContext.d.ts +21 -0
- package/dist/dts/lib/core/context/DataContext.d.ts +15 -0
- package/dist/dts/lib/core/context/PaneManagerContext.d.ts +10 -0
- package/dist/dts/lib/core/hooks/paneSizingHelpers.d.ts +13 -0
- package/dist/dts/lib/core/hooks/useCanvasResize.d.ts +8 -0
- package/dist/dts/lib/core/hooks/useChartTheme.d.ts +12 -0
- package/dist/dts/lib/core/hooks/useDynamicPanes.d.ts +155 -0
- package/dist/dts/lib/core/hooks/useIndicatorSets.d.ts +20 -0
- package/dist/dts/lib/core/hooks/usePaneManager.d.ts +39 -0
- package/dist/dts/lib/core/hooks/usePaneSizes.d.ts +52 -0
- package/dist/dts/lib/core/index.d.ts +41 -0
- package/dist/dts/lib/core/paneScaleSlotDomains.d.ts +3 -0
- package/dist/dts/lib/core/registry/SeriesRegistry.d.ts +22 -0
- package/dist/dts/lib/core/registry/filterPanesBySeriesTier.d.ts +43 -0
- package/dist/dts/lib/core/registry/marketStructure.d.ts +7 -0
- package/dist/dts/lib/core/registry/momentum.d.ts +20 -0
- package/dist/dts/lib/core/registry/movingAverage.d.ts +14 -0
- package/dist/dts/lib/core/registry/priceChartTypes.d.ts +16 -0
- package/dist/dts/lib/core/registry/profile.d.ts +8 -0
- package/dist/dts/lib/core/registry/registerAll.d.ts +1 -0
- package/dist/dts/lib/core/registry/registerPhaseOne.d.ts +3 -0
- package/dist/dts/lib/core/registry/registryCore.d.ts +77 -0
- package/dist/dts/lib/core/registry/trend.d.ts +11 -0
- package/dist/dts/lib/core/registry/volatility.d.ts +11 -0
- package/dist/dts/lib/core/registry/volumeFlow.d.ts +20 -0
- package/dist/dts/lib/core/replay/BarReplayController.d.ts +62 -0
- package/dist/dts/lib/core/replay/ReplayEventBus.d.ts +68 -0
- package/dist/dts/lib/core/replay/ReplayFillSimulator.d.ts +33 -0
- package/dist/dts/lib/core/replay/ReplayOrderBook.d.ts +24 -0
- package/dist/dts/lib/core/replay/ReplayPositionManager.d.ts +30 -0
- package/dist/dts/lib/core/replay/ReplaySessionAnalytics.d.ts +31 -0
- package/dist/dts/lib/core/replay/createReplayTradeMarkerPrimitives.d.ts +7 -0
- package/dist/dts/lib/core/replay/pnlUtils.d.ts +2 -0
- package/dist/dts/lib/core/replay/replayBrokerAdapters.d.ts +51 -0
- package/dist/dts/lib/core/replay/replayTradingTypes.d.ts +61 -0
- package/dist/dts/lib/core/scales/computeScales.d.ts +8 -0
- package/dist/dts/lib/core/seriesValueResolver.d.ts +27 -0
- package/dist/dts/lib/core/sets/builtins.d.ts +2 -0
- package/dist/dts/lib/core/sets/indicatorSetCodec.d.ts +15 -0
- package/dist/dts/lib/core/trading/AnalyticsEngine.d.ts +56 -0
- package/dist/dts/lib/core/trading/BrokerAPI.d.ts +40 -0
- package/dist/dts/lib/core/trading/ExecutionSimulator.d.ts +53 -0
- package/dist/dts/lib/core/trading/FillSettlement.d.ts +38 -0
- package/dist/dts/lib/core/trading/MarketDataPort.d.ts +41 -0
- package/dist/dts/lib/core/trading/MarketRules.d.ts +58 -0
- package/dist/dts/lib/core/trading/OrderManagementSystem.d.ts +57 -0
- package/dist/dts/lib/core/trading/PositionManager.d.ts +79 -0
- package/dist/dts/lib/core/trading/RiskEngine.d.ts +40 -0
- package/dist/dts/lib/core/trading/SettlementCalendar.d.ts +10 -0
- package/dist/dts/lib/core/trading/VirtualBrokerEngine.d.ts +92 -0
- package/dist/dts/lib/core/trading/orderMargin.d.ts +3 -0
- package/dist/dts/lib/core/trading/storage/InMemoryStorageAdapter.d.ts +10 -0
- package/dist/dts/lib/core/trading/storage/TradingStorage.d.ts +34 -0
- package/dist/dts/lib/core/trading/types.d.ts +99 -0
- package/dist/dts/lib/core/types/chart.d.ts +21 -0
- package/dist/dts/lib/core/types/indicator-catalog.d.ts +38 -0
- package/dist/dts/lib/core/types/indicator-set.d.ts +19 -0
- package/dist/dts/lib/core/types/pane-descriptor.d.ts +46 -0
- package/dist/dts/lib/core/types/seriesComponents.d.ts +15 -0
- package/dist/dts/lib/credentials/credentialStore.d.ts +93 -0
- package/dist/dts/lib/helper/SaveChartAsImage.d.ts +90 -0
- package/dist/dts/lib/indicator/defaultOptionsForAppearance.d.ts +105 -0
- package/dist/dts/lib/indicators/builtin/MTFWrapper.d.ts +3 -0
- package/dist/dts/lib/indicators/builtin/VolumeProfileWorker.d.ts +19 -0
- package/dist/dts/lib/indicators/builtin/ac.d.ts +4 -0
- package/dist/dts/lib/indicators/builtin/alligator.d.ts +5 -0
- package/dist/dts/lib/indicators/builtin/anchoredVwap.d.ts +5 -0
- package/dist/dts/lib/indicators/builtin/ao.d.ts +4 -0
- package/dist/dts/lib/indicators/builtin/bbi.d.ts +10 -0
- package/dist/dts/lib/indicators/builtin/bias.d.ts +4 -0
- package/dist/dts/lib/indicators/builtin/bollinger.d.ts +9 -0
- package/dist/dts/lib/indicators/builtin/brar.d.ts +4 -0
- package/dist/dts/lib/indicators/builtin/cci.d.ts +4 -0
- package/dist/dts/lib/indicators/builtin/chaikinOscillator.d.ts +14 -0
- package/dist/dts/lib/indicators/builtin/chaikinVol.d.ts +4 -0
- package/dist/dts/lib/indicators/builtin/ci.d.ts +4 -0
- package/dist/dts/lib/indicators/builtin/cmf.d.ts +4 -0
- package/dist/dts/lib/indicators/builtin/cr.d.ts +4 -0
- package/dist/dts/lib/indicators/builtin/cvd.d.ts +4 -0
- package/dist/dts/lib/indicators/builtin/deltaProfile.d.ts +5 -0
- package/dist/dts/lib/indicators/builtin/dema.d.ts +4 -0
- package/dist/dts/lib/indicators/builtin/dma.d.ts +4 -0
- package/dist/dts/lib/indicators/builtin/dmi.d.ts +4 -0
- package/dist/dts/lib/indicators/builtin/donchian.d.ts +5 -0
- package/dist/dts/lib/indicators/builtin/ema.d.ts +4 -0
- package/dist/dts/lib/indicators/builtin/emv.d.ts +4 -0
- package/dist/dts/lib/indicators/builtin/footprint.d.ts +5 -0
- package/dist/dts/lib/indicators/builtin/fractals.d.ts +5 -0
- package/dist/dts/lib/indicators/builtin/gator.d.ts +5 -0
- package/dist/dts/lib/indicators/builtin/hma.d.ts +4 -0
- package/dist/dts/lib/indicators/builtin/hv.d.ts +4 -0
- package/dist/dts/lib/indicators/builtin/ichimoku.d.ts +5 -0
- package/dist/dts/lib/indicators/builtin/kdj.d.ts +4 -0
- package/dist/dts/lib/indicators/builtin/keltner.d.ts +5 -0
- package/dist/dts/lib/indicators/builtin/ma.d.ts +10 -0
- package/dist/dts/lib/indicators/builtin/maRibbon.d.ts +5 -0
- package/dist/dts/lib/indicators/builtin/macd.d.ts +9 -0
- package/dist/dts/lib/indicators/builtin/marketProfile.d.ts +5 -0
- package/dist/dts/lib/indicators/builtin/mfi.d.ts +4 -0
- package/dist/dts/lib/indicators/builtin/mtm.d.ts +4 -0
- package/dist/dts/lib/indicators/builtin/obv.d.ts +10 -0
- package/dist/dts/lib/indicators/builtin/pivotHighLow.d.ts +5 -0
- package/dist/dts/lib/indicators/builtin/pivotStandard.d.ts +5 -0
- package/dist/dts/lib/indicators/builtin/psy.d.ts +4 -0
- package/dist/dts/lib/indicators/builtin/pvt.d.ts +4 -0
- package/dist/dts/lib/indicators/builtin/roc.d.ts +4 -0
- package/dist/dts/lib/indicators/builtin/rsi.d.ts +4 -0
- package/dist/dts/lib/indicators/builtin/sar.d.ts +10 -0
- package/dist/dts/lib/indicators/builtin/sma.d.ts +4 -0
- package/dist/dts/lib/indicators/builtin/smfi.d.ts +8 -0
- package/dist/dts/lib/indicators/builtin/stdDev.d.ts +4 -0
- package/dist/dts/lib/indicators/builtin/strengthRelative.d.ts +7 -0
- package/dist/dts/lib/indicators/builtin/supertrend.d.ts +5 -0
- package/dist/dts/lib/indicators/builtin/tema.d.ts +4 -0
- package/dist/dts/lib/indicators/builtin/trix.d.ts +4 -0
- package/dist/dts/lib/indicators/builtin/volOsc.d.ts +4 -0
- package/dist/dts/lib/indicators/builtin/volume.d.ts +4 -0
- package/dist/dts/lib/indicators/builtin/volumeProfile.d.ts +8 -0
- package/dist/dts/lib/indicators/builtin/vr.d.ts +10 -0
- package/dist/dts/lib/indicators/builtin/vwap.d.ts +5 -0
- package/dist/dts/lib/indicators/builtin/vwma.d.ts +4 -0
- package/dist/dts/lib/indicators/builtin/wma.d.ts +4 -0
- package/dist/dts/lib/indicators/builtin/wr.d.ts +10 -0
- package/dist/dts/lib/indicators/builtin/wyckoffWave.d.ts +15 -0
- package/dist/dts/lib/indicators/index.d.ts +63 -0
- package/dist/dts/lib/indicators/indicatorValueShapes.d.ts +15 -0
- package/dist/dts/lib/indicators/outputKeys.d.ts +50 -0
- package/dist/dts/lib/indicators/overlays/CVDIndicator.d.ts +26 -0
- package/dist/dts/lib/indicators/overlays/DarkFlowBadge.d.ts +19 -0
- package/dist/dts/lib/indicators/overlays/ExternalCVDOverlay.d.ts +15 -0
- package/dist/dts/lib/indicators/overlays/WhaleBubbleOverlay.d.ts +14 -0
- package/dist/dts/lib/indicators/overlays/WhaleMarketBubbleOverlay.d.ts +27 -0
- package/dist/dts/lib/indicators/overlays/whaleDetector.d.ts +66 -0
- package/dist/dts/lib/indicators/registry.d.ts +6 -0
- package/dist/dts/lib/indicators/types.d.ts +5 -0
- package/dist/dts/lib/indicators/utils.d.ts +259 -0
- package/dist/dts/lib/pinescript/PineCompiler.d.ts +34 -0
- package/dist/dts/lib/pinescript/ast.d.ts +73 -0
- package/dist/dts/lib/pinescript/compile.d.ts +40 -0
- package/dist/dts/lib/pinescript/grammar.d.ts +12 -0
- package/dist/dts/lib/pinescript/pine.worker.d.ts +1 -0
- package/dist/dts/lib/pinescript/pineBlocks.d.ts +54 -0
- package/dist/dts/lib/pinescript/pineBuiltins.d.ts +47 -0
- package/dist/dts/lib/pinescript/pineEnv.d.ts +46 -0
- package/dist/dts/lib/pinescript/pineMath.d.ts +13 -0
- package/dist/dts/lib/pinescript/pineParse.d.ts +25 -0
- package/dist/dts/lib/pinescript/pineStrings.d.ts +50 -0
- package/dist/dts/lib/pinescript/runtime.d.ts +5 -0
- package/dist/dts/lib/pinescript/scriptRegistry.d.ts +40 -0
- package/dist/dts/lib/pinescript/series-value.d.ts +64 -0
- package/dist/dts/lib/pinescript/vnscript-completion.d.ts +1 -0
- package/dist/dts/lib/pinescript/vnscript-grammar.d.ts +19 -0
- package/dist/dts/lib/scale/discontinuousTimeScaleProvider.d.ts +3 -0
- package/dist/dts/lib/scale/financeDiscontinuousScale.d.ts +15 -0
- package/dist/dts/lib/scale/index.d.ts +1 -0
- package/dist/dts/lib/scale/levels.d.ts +12 -0
- package/dist/dts/lib/series/AlternatingFillAreaSeries.d.ts +13 -0
- package/dist/dts/lib/series/AreaOnlySeries.d.ts +10 -0
- package/dist/dts/lib/series/AreaSeries.d.ts +30 -0
- package/dist/dts/lib/series/BarSeries.d.ts +40 -0
- package/dist/dts/lib/series/BollingerSeries.d.ts +11 -0
- package/dist/dts/lib/series/CandlestickSeries.d.ts +56 -0
- package/dist/dts/lib/series/CircleMarker.d.ts +28 -0
- package/dist/dts/lib/series/ElderRaySeries.d.ts +14 -0
- package/dist/dts/lib/series/FootprintSeries.d.ts +21 -0
- package/dist/dts/lib/series/GroupedBarSeries.d.ts +9 -0
- package/dist/dts/lib/series/HTFOverlaySeries.d.ts +32 -0
- package/dist/dts/lib/series/HistogramSeries.d.ts +51 -0
- package/dist/dts/lib/series/KagiSeries.d.ts +9 -0
- package/dist/dts/lib/series/LineBreakSeries.d.ts +28 -0
- package/dist/dts/lib/series/LineSeries.d.ts +54 -0
- package/dist/dts/lib/series/MACDSeries.d.ts +28 -0
- package/dist/dts/lib/series/MarketProfileSeries.d.ts +18 -0
- package/dist/dts/lib/series/OHLCSeries.d.ts +9 -0
- package/dist/dts/lib/series/OverlayBarSeries.d.ts +9 -0
- package/dist/dts/lib/series/PointAndFigureSeries.d.ts +45 -0
- package/dist/dts/lib/series/RSISeries.d.ts +38 -0
- package/dist/dts/lib/series/RenkoSeries.d.ts +9 -0
- package/dist/dts/lib/series/SARSeries.d.ts +10 -0
- package/dist/dts/lib/series/SVGComponent.d.ts +5 -0
- package/dist/dts/lib/series/ScatterSeries.d.ts +9 -0
- package/dist/dts/lib/series/SquareMarker.d.ts +28 -0
- package/dist/dts/lib/series/StackedBarSeries.d.ts +19 -0
- package/dist/dts/lib/series/StochasticSeries.d.ts +9 -0
- package/dist/dts/lib/series/StraightLine.d.ts +18 -0
- package/dist/dts/lib/series/TriangleMarker.d.ts +30 -0
- package/dist/dts/lib/series/VolumeProfileSeries.d.ts +9 -0
- package/dist/dts/lib/series/index.d.ts +28 -0
- package/dist/dts/lib/strategy/BrokerSimulator.d.ts +11 -0
- package/dist/dts/lib/strategy/types.d.ts +35 -0
- package/dist/dts/lib/tape/TapePanel.d.ts +5 -0
- package/dist/dts/lib/types/adapter.d.ts +1 -0
- package/dist/dts/lib/types/index.d.ts +5 -0
- package/dist/dts/lib/types/indicator.d.ts +11 -0
- package/dist/dts/lib/types/ohlcv.d.ts +1 -0
- package/dist/dts/lib/types/pane.d.ts +23 -0
- package/dist/dts/lib/types/runtime.d.ts +11 -0
- package/dist/dts/lib/types/vninvest.d.ts +320 -0
- package/dist/dts/lib/types.d.ts +45 -0
- package/dist/dts/lib/utils/ChartDataUtil.d.ts +26 -0
- package/dist/dts/lib/utils/PureComponent.d.ts +5 -0
- package/dist/dts/lib/utils/accumulatingWindow.d.ts +1 -0
- package/dist/dts/lib/utils/axisPriceFormat.d.ts +6 -0
- package/dist/dts/lib/utils/barWidth.d.ts +14 -0
- package/dist/dts/lib/utils/identity.d.ts +1 -0
- package/dist/dts/lib/utils/index.d.ts +70 -0
- package/dist/dts/lib/utils/logger.d.ts +28 -0
- package/dist/dts/lib/utils/mappedSlidingWindow.d.ts +1 -0
- package/dist/dts/lib/utils/merge.d.ts +6 -0
- package/dist/dts/lib/utils/noop.d.ts +1 -0
- package/dist/dts/lib/utils/rebind.d.ts +1 -0
- package/dist/dts/lib/utils/shallowEqual.d.ts +1 -0
- package/dist/dts/lib/utils/slidingWindow.d.ts +1 -0
- package/dist/dts/lib/utils/storage.d.ts +32 -0
- package/dist/dts/lib/utils/strokeDasharray.d.ts +3 -0
- package/dist/dts/lib/utils/timezoneFormatter.d.ts +14 -0
- package/dist/dts/lib/utils/zipper.d.ts +4 -0
- package/dist/dts/public-api.d.ts +31 -0
- package/dist/dts/widget/BackfillWorkerFlags.d.ts +12 -0
- package/dist/dts/widget/CanaryRollbackHelper.d.ts +95 -0
- package/dist/dts/widget/CanaryRolloutConfig.d.ts +100 -0
- package/dist/dts/widget/DrawingPriceLabelsOverlay.d.ts +20 -0
- package/dist/dts/widget/ForkDrawingsOverlay.d.ts +16 -0
- package/dist/dts/widget/MeasurementOverlay.d.ts +24 -0
- package/dist/dts/widget/VNInvestCharts.d.ts +5 -0
- package/dist/dts/widget/VNInvestChartsProps.d.ts +302 -0
- package/dist/dts/widget/VNInvestMultiCharts.d.ts +8 -0
- package/dist/dts/widget/VNInvestMultiCharts.types.d.ts +130 -0
- package/dist/dts/widget/WidgetEmptyState.d.ts +11 -0
- package/dist/dts/widget/WidgetErrorBoundary.d.ts +26 -0
- package/dist/dts/widget/adapters/ContinuousFuturesStockDataAdapter.d.ts +18 -0
- package/dist/dts/widget/adapters/DataProviderAdapterWrapper.d.ts +14 -0
- package/dist/dts/widget/adapters/MultiSourceDataAdapter.d.ts +24 -0
- package/dist/dts/widget/adapters/VNInvestClient.d.ts +161 -0
- package/dist/dts/widget/adapters/VNInvestDataAdapter.d.ts +77 -0
- package/dist/dts/widget/adapters/VNInvestWebSocketClient.d.ts +79 -0
- package/dist/dts/widget/adapters/barsPagingPolicy.d.ts +18 -0
- package/dist/dts/widget/adapters/corporateEvents.d.ts +13 -0
- package/dist/dts/widget/adapters/index.d.ts +20 -0
- package/dist/dts/widget/adapters/nativeShapes.d.ts +32 -0
- package/dist/dts/widget/adapters/watchlistRealtimeSync.d.ts +16 -0
- package/dist/dts/widget/alerts/DrawingAlertsHost.d.ts +18 -0
- package/dist/dts/widget/alerts/useDrawingAlerts.d.ts +37 -0
- package/dist/dts/widget/canaryBarFiltering.d.ts +35 -0
- package/dist/dts/widget/capabilities/CapabilityResolver.d.ts +71 -0
- package/dist/dts/widget/capabilities/capabilityProbe.d.ts +28 -0
- package/dist/dts/widget/capabilities/useTierGatedFeatures.d.ts +48 -0
- package/dist/dts/widget/components/BottomPanelHost.d.ts +80 -0
- package/dist/dts/widget/components/BottomPanelSplitter.d.ts +15 -0
- package/dist/dts/widget/components/CapabilityGate.d.ts +65 -0
- package/dist/dts/widget/components/ChartDiagOverlay.d.ts +31 -0
- package/dist/dts/widget/components/ConfirmDialog.d.ts +12 -0
- package/dist/dts/widget/components/DowngradeBanner.d.ts +9 -0
- package/dist/dts/widget/components/ForkPaneSeparators.d.ts +11 -0
- package/dist/dts/widget/components/ForkPaneTooltips.d.ts +23 -0
- package/dist/dts/widget/components/ForkXAxisOverlay.d.ts +11 -0
- package/dist/dts/widget/components/ForkYAxisCrosshairLabels.d.ts +9 -0
- package/dist/dts/widget/components/LayoutDesigner.d.ts +26 -0
- package/dist/dts/widget/components/PremiumFeatureGate.d.ts +10 -0
- package/dist/dts/widget/components/ShortcutHelpModal.d.ts +44 -0
- package/dist/dts/widget/components/SystemMenu.d.ts +66 -0
- package/dist/dts/widget/components/Toast.d.ts +20 -0
- package/dist/dts/widget/components/canvas/BarCountdownBadge.d.ts +8 -0
- package/dist/dts/widget/components/canvas/ChartA11ySummary.d.ts +40 -0
- package/dist/dts/widget/components/canvas/ChartStatusLine.d.ts +39 -0
- package/dist/dts/widget/components/canvas/PricePaneHeader.d.ts +24 -0
- package/dist/dts/widget/components/canvas/PriceScaleMenu.d.ts +27 -0
- package/dist/dts/widget/components/canvas/TimeAxisScrollbar.d.ts +18 -0
- package/dist/dts/widget/components/common/Icons.d.ts +67 -0
- package/dist/dts/widget/components/dock/DataWindow.d.ts +7 -0
- package/dist/dts/widget/components/dock/DockUpgradeNudge.d.ts +10 -0
- package/dist/dts/widget/components/dock/RightSidebarDockHost.d.ts +57 -0
- package/dist/dts/widget/components/dock/WatchlistPanel.d.ts +7 -0
- package/dist/dts/widget/components/dock/WorkspaceRightDockSlot.d.ts +46 -0
- package/dist/dts/widget/components/dock/dockAccess.d.ts +20 -0
- package/dist/dts/widget/components/dock/drawingDockContentBuilders.d.ts +29 -0
- package/dist/dts/widget/components/drawing/DrawingDock.d.ts +47 -0
- package/dist/dts/widget/components/drawing/DrawingInspector.d.ts +94 -0
- package/dist/dts/widget/components/drawing/DrawingListPanel.d.ts +62 -0
- package/dist/dts/widget/components/drawing/DrawingSemanticPointLegend.d.ts +14 -0
- package/dist/dts/widget/components/drawing/FloatingDrawingInspector.d.ts +18 -0
- package/dist/dts/widget/components/drawing/IconPickerPanel.d.ts +5 -0
- package/dist/dts/widget/components/drawing/InlineTextEditor.d.ts +20 -0
- package/dist/dts/widget/components/drawing/PatternScanPanel.d.ts +27 -0
- package/dist/dts/widget/components/drawing/TemplateManagerPanel.d.ts +18 -0
- package/dist/dts/widget/components/events/CorporateEventsOverlay.d.ts +23 -0
- package/dist/dts/widget/components/events/EventMarkerIcon.d.ts +6 -0
- package/dist/dts/widget/components/footer/ChartFooter.d.ts +26 -0
- package/dist/dts/widget/components/footer/MultiChartsFooter.d.ts +37 -0
- package/dist/dts/widget/components/footer/TimeframeFooter.d.ts +25 -0
- package/dist/dts/widget/components/footer/useBarCountdown.d.ts +5 -0
- package/dist/dts/widget/components/header/OHLCHeader.d.ts +72 -0
- package/dist/dts/widget/components/layout/DrawingConflictNotice.d.ts +4 -0
- package/dist/dts/widget/components/layout/GridContainer.d.ts +70 -0
- package/dist/dts/widget/components/layout/GridSlotErrorBoundary.d.ts +17 -0
- package/dist/dts/widget/components/layout/Splitter.d.ts +23 -0
- package/dist/dts/widget/components/layout/gridSplitterMath.d.ts +40 -0
- package/dist/dts/widget/components/layout/useGridSplitterDrag.d.ts +18 -0
- package/dist/dts/widget/components/mobile/MobileChartCarousel.d.ts +11 -0
- package/dist/dts/widget/components/mobile/MobileToolbar.d.ts +29 -0
- package/dist/dts/widget/components/overlays/AdvisoryPanel.d.ts +25 -0
- package/dist/dts/widget/components/overlays/TapePanel.d.ts +25 -0
- package/dist/dts/widget/components/overlays/WhalePanel.d.ts +5 -0
- package/dist/dts/widget/components/panels/AdvisoryPanel.d.ts +25 -0
- package/dist/dts/widget/components/panels/PineEditorPanel.d.ts +18 -0
- package/dist/dts/widget/components/panels/StrategyTesterPanel.d.ts +7 -0
- package/dist/dts/widget/components/panels/TapePanel.d.ts +17 -0
- package/dist/dts/widget/components/panels/index.d.ts +8 -0
- package/dist/dts/widget/components/replay/FloatingReplayToolbar.d.ts +24 -0
- package/dist/dts/widget/components/replay/ReplayCutOverlay.d.ts +8 -0
- package/dist/dts/widget/components/search/SymbolCompareModal.d.ts +24 -0
- package/dist/dts/widget/components/search/SymbolSearchModal.d.ts +12 -0
- package/dist/dts/widget/components/search/VNSymbolSearch.d.ts +83 -0
- package/dist/dts/widget/components/settings/AlertsModal.d.ts +74 -0
- package/dist/dts/widget/components/settings/SettingsContext.d.ts +58 -0
- package/dist/dts/widget/components/settings/SettingsModal.d.ts +78 -0
- package/dist/dts/widget/components/settings/SettingsRangeSlider.d.ts +17 -0
- package/dist/dts/widget/components/settings/SnapshotPreviewModal.d.ts +16 -0
- package/dist/dts/widget/components/settings/WorkspaceSettingsContext.d.ts +27 -0
- package/dist/dts/widget/components/settings/helpers/seriesFormatters.d.ts +11 -0
- package/dist/dts/widget/components/settings/model/appearancePayload.d.ts +31 -0
- package/dist/dts/widget/components/settings/model/chartSettingsSchema.d.ts +100 -0
- package/dist/dts/widget/components/settings/model/defaultSettings.d.ts +5 -0
- package/dist/dts/widget/components/settings/model/indicatorShare.d.ts +29 -0
- package/dist/dts/widget/components/settings/storageKeys.d.ts +29 -0
- package/dist/dts/widget/components/settings/tabs/AppearanceSettingsTab.d.ts +5 -0
- package/dist/dts/widget/components/settings/tabs/IndicatorParamsForm.d.ts +12 -0
- package/dist/dts/widget/components/settings/tabs/IndicatorsSettingsTab.d.ts +34 -0
- package/dist/dts/widget/components/settings/tabs/LicensingSettingsTab.d.ts +5 -0
- package/dist/dts/widget/components/settings/tabs/PanesLayoutSettingsTab.d.ts +11 -0
- package/dist/dts/widget/components/settings/tabs/ResetSettingsTab.d.ts +8 -0
- package/dist/dts/widget/components/settings/tabs/ScalesSettingsTab.d.ts +5 -0
- package/dist/dts/widget/components/settings/tabs/StatusLineSettingsTab.d.ts +5 -0
- package/dist/dts/widget/components/settings/tabs/SymbolSettingsTab.d.ts +5 -0
- package/dist/dts/widget/components/settings/tabs/ThemePaletteSettingsTab.d.ts +9 -0
- package/dist/dts/widget/components/settings/tabs/TradingEventsSettingsTab.d.ts +8 -0
- package/dist/dts/widget/components/toolbar/DrawingToolIcon.d.ts +10 -0
- package/dist/dts/widget/components/toolbar/DrawingToolbar.d.ts +33 -0
- package/dist/dts/widget/components/toolbar/FloatingChartBar.d.ts +20 -0
- package/dist/dts/widget/components/toolbar/FloatingFavoritesBar.d.ts +18 -0
- package/dist/dts/widget/components/toolbar/MultiChartTopbar.d.ts +47 -0
- package/dist/dts/widget/components/toolbar/UnifiedDrawingToolbar.d.ts +28 -0
- package/dist/dts/widget/components/trading/PaperTradePanel.d.ts +41 -0
- package/dist/dts/widget/components/workspace/WorkspaceToolbar.d.ts +25 -0
- package/dist/dts/widget/config/toolGroups.d.ts +11 -0
- package/dist/dts/widget/config/toolShortcuts.d.ts +27 -0
- package/dist/dts/widget/constants/comparison.d.ts +1 -0
- package/dist/dts/widget/constants/symbolSearch.d.ts +14 -0
- package/dist/dts/widget/constants/vn30.d.ts +7 -0
- package/dist/dts/widget/context/DataProviderContext.d.ts +7 -0
- package/dist/dts/widget/context/HoverEmitter.d.ts +50 -0
- package/dist/dts/widget/context/SyncContextShare.d.ts +11 -0
- package/dist/dts/widget/context/VNInvestChartsConfigContext.d.ts +24 -0
- package/dist/dts/widget/context/VNInvestChartsContext.d.ts +70 -0
- package/dist/dts/widget/context/VNInvestChartsStateContext.d.ts +50 -0
- package/dist/dts/widget/context/WidgetI18nContext.d.ts +25 -0
- package/dist/dts/widget/context/WorkspaceLiveTradingContext.d.ts +30 -0
- package/dist/dts/widget/context/WorkspacePaperVisibilityContext.d.ts +23 -0
- package/dist/dts/widget/context/WorkspaceReplayTradingContext.d.ts +36 -0
- package/dist/dts/widget/contexts/SaaSFeatureContext.d.ts +23 -0
- package/dist/dts/widget/data/DataEnvelope.d.ts +100 -0
- package/dist/dts/widget/drawingPriceLabelInputs.d.ts +3 -0
- package/dist/dts/widget/export/chartCsv.d.ts +59 -0
- package/dist/dts/widget/forkAnchorReconciliation.d.ts +6 -0
- package/dist/dts/widget/forkInteractionHelpers.d.ts +69 -0
- package/dist/dts/widget/grid/DeviceProfiles.d.ts +49 -0
- package/dist/dts/widget/grid/GridChartRegistry.d.ts +9 -0
- package/dist/dts/widget/grid/MemoryBudgetManager.d.ts +63 -0
- package/dist/dts/widget/grid/PerformanceMonitor.d.ts +70 -0
- package/dist/dts/widget/grid/customPresets.d.ts +42 -0
- package/dist/dts/widget/grid/presets.d.ts +18 -0
- package/dist/dts/widget/grid/types.d.ts +39 -0
- package/dist/dts/widget/history/BackfillDedupContext.d.ts +63 -0
- package/dist/dts/widget/history/RequestCoordinator.d.ts +59 -0
- package/dist/dts/widget/history/SharedBarStoreContext.d.ts +22 -0
- package/dist/dts/widget/history/cache/IndexedDBCacheMatrix.d.ts +16 -0
- package/dist/dts/widget/history/cache/LocalCacheMatrix.d.ts +86 -0
- package/dist/dts/widget/history/cache/index.d.ts +3 -0
- package/dist/dts/widget/history/chunkStore.d.ts +77 -0
- package/dist/dts/widget/history/externalBarsNormalization.d.ts +9 -0
- package/dist/dts/widget/history/externalBarsNormalization.worker.d.ts +1 -0
- package/dist/dts/widget/history/externalBarsNormalizationAsync.d.ts +25 -0
- package/dist/dts/widget/history/historyDataUtils.d.ts +82 -0
- package/dist/dts/widget/history/historyWindowPlanner.d.ts +89 -0
- package/dist/dts/widget/history/inflightController.d.ts +15 -0
- package/dist/dts/widget/history/requestCoalescing.d.ts +10 -0
- package/dist/dts/widget/history/sessionGuards.d.ts +3 -0
- package/dist/dts/widget/history/singleWriterLane.d.ts +4 -0
- package/dist/dts/widget/history/useExternalBarsNormalization.d.ts +5 -0
- package/dist/dts/widget/hooks/ShortcutManager.d.ts +65 -0
- package/dist/dts/widget/hooks/overlays/PaneHeaderWrapper.d.ts +11 -0
- package/dist/dts/widget/hooks/overlays/overlayHelpers.d.ts +60 -0
- package/dist/dts/widget/hooks/overlays/useDrawingDockNode.d.ts +15 -0
- package/dist/dts/widget/hooks/overlays/useLegendChrome.d.ts +36 -0
- package/dist/dts/widget/hooks/overlays/useMultiSelectActions.d.ts +22 -0
- package/dist/dts/widget/hooks/overlays/useSidebarResize.d.ts +13 -0
- package/dist/dts/widget/hooks/resolveEntitlement.d.ts +73 -0
- package/dist/dts/widget/hooks/useBottomPanelBehavior.d.ts +38 -0
- package/dist/dts/widget/hooks/useBottomPanelHeight.d.ts +39 -0
- package/dist/dts/widget/hooks/useCanvasTheme.d.ts +24 -0
- package/dist/dts/widget/hooks/useChartImperativeHandle.d.ts +57 -0
- package/dist/dts/widget/hooks/useClockAdapter.d.ts +11 -0
- package/dist/dts/widget/hooks/useComparisonState.d.ts +29 -0
- package/dist/dts/widget/hooks/useDialogFocus.d.ts +25 -0
- package/dist/dts/widget/hooks/useDrawingToolShortcuts.d.ts +16 -0
- package/dist/dts/widget/hooks/useFeatureGate.d.ts +28 -0
- package/dist/dts/widget/hooks/useFloatingChartBar.d.ts +33 -0
- package/dist/dts/widget/hooks/useForkRuntime.d.ts +155 -0
- package/dist/dts/widget/hooks/useIndicatorsShareApplier.d.ts +1 -0
- package/dist/dts/widget/hooks/useIntersectionObserver.d.ts +49 -0
- package/dist/dts/widget/hooks/useKeyboardAdapter.d.ts +9 -0
- package/dist/dts/widget/hooks/useLayoutHistory.d.ts +8 -0
- package/dist/dts/widget/hooks/useLicenseDiagnostics.d.ts +15 -0
- package/dist/dts/widget/hooks/useMultiChartReplaySync.d.ts +31 -0
- package/dist/dts/widget/hooks/useMultiWorkspacePersistence.d.ts +49 -0
- package/dist/dts/widget/hooks/usePaperTradeConfig.d.ts +27 -0
- package/dist/dts/widget/hooks/usePaperTradeInteraction.d.ts +27 -0
- package/dist/dts/widget/hooks/usePatTierAuthentication.d.ts +42 -0
- package/dist/dts/widget/hooks/usePineScriptRestore.d.ts +23 -0
- package/dist/dts/widget/hooks/usePortalAdapter.d.ts +8 -0
- package/dist/dts/widget/hooks/useRecentSymbols.d.ts +3 -0
- package/dist/dts/widget/hooks/useReplayState.d.ts +28 -0
- package/dist/dts/widget/hooks/useReplayTrading.d.ts +26 -0
- package/dist/dts/widget/hooks/useResizeAdapter.d.ts +13 -0
- package/dist/dts/widget/hooks/useScaleOverlays.d.ts +62 -0
- package/dist/dts/widget/hooks/useScriptPersistence.d.ts +72 -0
- package/dist/dts/widget/hooks/useSymbolSearch.d.ts +30 -0
- package/dist/dts/widget/hooks/useViewportBreakpoint.d.ts +15 -0
- package/dist/dts/widget/hooks/useWidgetCoordinateBridge.d.ts +70 -0
- package/dist/dts/widget/hooks/useWidgetData.d.ts +138 -0
- package/dist/dts/widget/hooks/useWidgetDataBackfill.d.ts +67 -0
- package/dist/dts/widget/hooks/useWidgetDataEnrichment.d.ts +32 -0
- package/dist/dts/widget/hooks/useWidgetDrawings.d.ts +38 -0
- package/dist/dts/widget/hooks/useWidgetForkInteraction.d.ts +68 -0
- package/dist/dts/widget/hooks/useWidgetInteractionActions.d.ts +36 -0
- package/dist/dts/widget/hooks/useWidgetOverlays.d.ts +190 -0
- package/dist/dts/widget/hooks/useWidgetRuntime.d.ts +20 -0
- package/dist/dts/widget/hooks/useWidgetSettings.d.ts +244 -0
- package/dist/dts/widget/hooks/useWidgetWorkspaceIO.d.ts +24 -0
- package/dist/dts/widget/hooks/useWorkspaceDockPanels.d.ts +11 -0
- package/dist/dts/widget/hooks/useWorkspaceLiveTrading.d.ts +28 -0
- package/dist/dts/widget/hooks/useWorkspaceReplayTrading.d.ts +22 -0
- package/dist/dts/widget/i18n/a11y.messages.en.d.ts +8 -0
- package/dist/dts/widget/i18n/a11y.messages.vi.d.ts +3 -0
- package/dist/dts/widget/i18n/capability.messages.en.d.ts +7 -0
- package/dist/dts/widget/i18n/capability.messages.vi.d.ts +3 -0
- package/dist/dts/widget/i18n/dock.messages.en.d.ts +2 -0
- package/dist/dts/widget/i18n/dock.messages.vi.d.ts +2 -0
- package/dist/dts/widget/i18n/messages.en.d.ts +2 -0
- package/dist/dts/widget/i18n/messages.licensing.d.ts +48 -0
- package/dist/dts/widget/i18n/messages.vi.d.ts +2 -0
- package/dist/dts/widget/i18n/trading.messages.en.d.ts +2 -0
- package/dist/dts/widget/i18n/trading.messages.vi.d.ts +2 -0
- package/dist/dts/widget/i18n/types.d.ts +3 -0
- package/dist/dts/widget/iframe/builtInAdapters.d.ts +63 -0
- package/dist/dts/widget/iframe/host-entry.d.ts +11 -0
- package/dist/dts/widget/iframe/hostSDK.d.ts +151 -0
- package/dist/dts/widget/iframe/iframeBridge.d.ts +165 -0
- package/dist/dts/widget/iframe/iframeEntry.d.ts +52 -0
- package/dist/dts/widget/iframe/iframeFrame.d.ts +15 -0
- package/dist/dts/widget/iframe/iframeQuotes.d.ts +20 -0
- package/dist/dts/widget/iframe/messageProtocol.d.ts +545 -0
- package/dist/dts/widget/iframe/quoteHub.d.ts +20 -0
- package/dist/dts/widget/iframe/useVNInvestChartsHost.d.ts +8 -0
- package/dist/dts/widget/iife-entry.d.ts +61 -0
- package/dist/dts/widget/iifeWidgetInstance.d.ts +60 -0
- package/dist/dts/widget/index.d.ts +56 -0
- package/dist/dts/widget/multiChartDefaults.d.ts +18 -0
- package/dist/dts/widget/paneInteractionUtils.d.ts +25 -0
- package/dist/dts/widget/patterns/autoPatternScan.d.ts +77 -0
- package/dist/dts/widget/patterns/patternDrawingFactory.d.ts +87 -0
- package/dist/dts/widget/plugin/ProPluginRegistry.d.ts +40 -0
- package/dist/dts/widget/runtime/ChartScaleAdapter.d.ts +73 -0
- package/dist/dts/widget/runtime/ChartSerializer.d.ts +12 -0
- package/dist/dts/widget/runtime/ForkRuntimeAdapter.d.ts +19 -0
- package/dist/dts/widget/runtime/IRuntimeEngine.d.ts +40 -0
- package/dist/dts/widget/runtime/WorkspaceSerializer.d.ts +31 -0
- package/dist/dts/widget/runtimePolicy.d.ts +36 -0
- package/dist/dts/widget/styles/injectStyles.d.ts +9 -0
- package/dist/dts/widget/theme/ThemeConfig.d.ts +21 -0
- package/dist/dts/widget/theme/applyTheme.d.ts +3 -0
- package/dist/dts/widget/trading/chart/DraggableOrderHandles.d.ts +15 -0
- package/dist/dts/widget/trading/chart/InteractivePositionOverlay.d.ts +19 -0
- package/dist/dts/widget/trading/chart/PendingOrderOverlay.d.ts +11 -0
- package/dist/dts/widget/trading/chart/QuickTradingHeader.d.ts +20 -0
- package/dist/dts/widget/trading/chart/TradingChartSurface.d.ts +8 -0
- package/dist/dts/widget/trading/chart/TradingOverlaysHost.d.ts +28 -0
- package/dist/dts/widget/trading/chart/priceTicks.d.ts +1 -0
- package/dist/dts/widget/trading/chart/useFloatingDrag.d.ts +40 -0
- package/dist/dts/widget/trading/chart/useTradingHotkeys.d.ts +21 -0
- package/dist/dts/widget/trading/config/paperRuntimeConfig.d.ts +53 -0
- package/dist/dts/widget/trading/context/PaperPanelRegistry.d.ts +45 -0
- package/dist/dts/widget/trading/context/TradingContext.d.ts +80 -0
- package/dist/dts/widget/trading/context/WorkspaceTradingSync.d.ts +24 -0
- package/dist/dts/widget/trading/hooks/usePaperRuntimeConfig.d.ts +36 -0
- package/dist/dts/widget/trading/index.d.ts +5 -0
- package/dist/dts/widget/trading/panel/AccountSummaryTab.d.ts +7 -0
- package/dist/dts/widget/trading/panel/ActiveChartPaperPanel.d.ts +26 -0
- package/dist/dts/widget/trading/panel/ConnectedTradingPanel.d.ts +3 -0
- package/dist/dts/widget/trading/panel/HistoryTab.d.ts +5 -0
- package/dist/dts/widget/trading/panel/MarketFallbackBanner.d.ts +4 -0
- package/dist/dts/widget/trading/panel/OrdersTab.d.ts +8 -0
- package/dist/dts/widget/trading/panel/PaperCapitalDialog.d.ts +8 -0
- package/dist/dts/widget/trading/panel/PaperSettingsModal.d.ts +17 -0
- package/dist/dts/widget/trading/panel/PositionsTab.d.ts +15 -0
- package/dist/dts/widget/trading/panel/TradeHistoryTab.d.ts +5 -0
- package/dist/dts/widget/trading/panel/TradingBottomPanel.d.ts +36 -0
- package/dist/dts/widget/trading/panel/TradingLogTab.d.ts +8 -0
- package/dist/dts/widget/trading/panel/TradingPanelHeader.d.ts +17 -0
- package/dist/dts/widget/trading/panel/csvExport.d.ts +18 -0
- package/dist/dts/widget/trading/ticket/ConnectedTradingDockPanel.d.ts +5 -0
- package/dist/dts/widget/trading/ticket/OrderTicketForm.d.ts +31 -0
- package/dist/dts/widget/trading/ticket/OrderTicketModal.d.ts +29 -0
- package/dist/dts/widget/trading/ticket/RegistryTradingDockPanel.d.ts +9 -0
- package/dist/dts/widget/trading/ticket/RiskCalculatorView.d.ts +9 -0
- package/dist/dts/widget/trading/ticket/TradingDockPanel.d.ts +36 -0
- package/dist/dts/widget/trading/ticket/orderTicketModel.d.ts +49 -0
- package/dist/dts/widget/trading/visibility/paperVisibility.d.ts +38 -0
- package/dist/dts/widget/types/dataProvider.d.ts +8 -0
- package/dist/dts/widget/types/fullChartHandle.d.ts +25 -0
- package/dist/dts/widget/types/saas.d.ts +83 -0
- package/dist/dts/widget/types/symbolSearch.d.ts +9 -0
- package/dist/dts/widget/types/watchlist.d.ts +26 -0
- package/dist/dts/widget/utils/axisHit.d.ts +16 -0
- package/dist/dts/widget/utils/chartRange.d.ts +12 -0
- package/dist/dts/widget/utils/chartTypeOptions.d.ts +38 -0
- package/dist/dts/widget/utils/clickOutside.d.ts +1 -0
- package/dist/dts/widget/utils/coordinateBridge.d.ts +31 -0
- package/dist/dts/widget/utils/crosshairSync.d.ts +50 -0
- package/dist/dts/widget/utils/drawingSync.d.ts +198 -0
- package/dist/dts/widget/utils/enrichedHash.d.ts +15 -0
- package/dist/dts/widget/utils/headerSync.d.ts +12 -0
- package/dist/dts/widget/utils/numberFormat.d.ts +13 -0
- package/dist/dts/widget/utils/paperTradeAdapters.d.ts +11 -0
- package/dist/dts/widget/utils/pineSeriesData.d.ts +71 -0
- package/dist/dts/widget/utils/rangeSync.d.ts +29 -0
- package/dist/dts/widget/utils/telemetry.d.ts +19 -0
- package/dist/dts/widget/utils/widgetEquality.d.ts +57 -0
- package/dist/dts/widget/utils/widgetErrors.d.ts +29 -0
- package/dist/dts/widget/utils/widgetHelpers.d.ts +395 -0
- package/dist/dts/widget/utils/xAxisTickFormatter.d.ts +33 -0
- package/dist/dts/widget/visibleRangeBridge.d.ts +28 -0
- package/dist/dts/widget/visibleRangeDiagnostics.d.ts +10 -0
- package/dist/dts/widget/visibleRangePolicies.d.ts +6 -0
- package/dist/dts/widget/workspace/WorkspaceManager.d.ts +23 -0
- package/dist/dts/widget/workspace/WorkspaceStore.d.ts +85 -0
- package/dist/dts/widget/workspace/types.d.ts +21 -0
- package/dist/externalBarsNormalization.worker.js +108 -0
- package/dist/iframe/index.html +63 -0
- package/dist/iframe/injected.css +6456 -0
- package/dist/iframe/vninvestchart.iframe.css +2 -0
- package/dist/iframe/vninvestchart.iframe.js +945 -0
- package/dist/iframe-host/host-entry.cjs +687 -0
- package/dist/iframe-host/host-entry.d.mts +818 -0
- package/dist/iframe-host/host-entry.d.ts +818 -0
- package/dist/iframe-host/host-entry.js +680 -0
- package/dist/index.cjs +7253 -0
- package/dist/index.css +3390 -0
- package/dist/index.d.ts +31 -0
- package/dist/index.js +6461 -0
- package/dist/injected.css +6456 -0
- package/dist/rollAlgorithms-2P2ZKKHO.js +2 -0
- package/dist/types/runtime.cjs +8 -0
- package/dist/types/runtime.d.mts +92 -0
- package/dist/types/runtime.d.ts +92 -0
- package/dist/types/runtime.js +5 -0
- package/dist/types/runtime.umd.js +14 -0
- package/dist/vninvestchart.iife.css +2 -0
- package/dist/vninvestchart.iife.js +945 -0
- package/package.json +225 -5
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import type { DrawingObject } from "@vninvestcharts/engine-drawing";
|
|
2
|
+
/**
|
|
3
|
+
* W1.1 — host render toast alert + badge "chỉ hoạt động khi tab mở".
|
|
4
|
+
*
|
|
5
|
+
* Đây là chỗ duy nhất trong widget gọi `AlertNotificationToast` (trước đó chỉ
|
|
6
|
+
* được re-export ở `drawing-shim.ts`/`index.ts` nhưng không render ở đâu).
|
|
7
|
+
*/
|
|
8
|
+
export interface DrawingAlertsHostProps {
|
|
9
|
+
/** Đã gate sẵn bởi `useTierGatedFeatures().allows("alert_drawing")`. */
|
|
10
|
+
enabled: boolean;
|
|
11
|
+
drawings: readonly DrawingObject[];
|
|
12
|
+
plotData: readonly {
|
|
13
|
+
close?: number | null;
|
|
14
|
+
}[];
|
|
15
|
+
updateDrawing: (id: string, patch: Partial<DrawingObject>) => void;
|
|
16
|
+
muted?: boolean;
|
|
17
|
+
}
|
|
18
|
+
export declare function DrawingAlertsHost({ enabled, drawings, plotData, updateDrawing, muted, }: DrawingAlertsHostProps): import("react").JSX.Element | null;
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { type DrawingAlertToastItem } from "@vninvestcharts/engine-react";
|
|
2
|
+
import type { DrawingObject } from "@vninvestcharts/engine-drawing";
|
|
3
|
+
/**
|
|
4
|
+
* W1.1 — nối alert engine (đã có sẵn trong engine, trước đây không ai render).
|
|
5
|
+
*
|
|
6
|
+
* Vì sao đây là việc quan trọng nhất của Wave 1: alert là tính năng người dùng
|
|
7
|
+
* retail đánh giá cao nhất, engine đã có **đủ** logic (`evaluateDrawingAlerts`,
|
|
8
|
+
* `useDrawingAlertEvaluator`, `AlertNotificationToast`) nhưng chưa module nào
|
|
9
|
+
* gọi tới. Ở đây chỉ là nối dây.
|
|
10
|
+
*
|
|
11
|
+
* Ràng buộc đã xử lý trước khi nối:
|
|
12
|
+
* - `resolveReferencePriceForAlert` từng nội suy bằng `nowMs` (epoch ms) trên
|
|
13
|
+
* trục `point.x` là PIXEL ⇒ ra giá vô nghĩa cho đường chéo. Đã sửa ở engine
|
|
14
|
+
* (dùng `yPrice` + `timeMsHint`; thiếu mốc thời gian th�� trả null = không
|
|
15
|
+
* bắn) và khoá bằng test. Không sửa thì nối vào sẽ bắn sai giá.
|
|
16
|
+
* - Alert chỉ chạy trong tab ⇒ badge "chỉ hoạt động khi tab mở" (EP-2 chưa có).
|
|
17
|
+
*
|
|
18
|
+
* Gate: capability `alert_drawing` (pro). Community không được bắn alert.
|
|
19
|
+
*/
|
|
20
|
+
export interface UseDrawingAlertsOptions {
|
|
21
|
+
enabled: boolean;
|
|
22
|
+
drawings: readonly DrawingObject[];
|
|
23
|
+
plotData: readonly {
|
|
24
|
+
close?: number | null;
|
|
25
|
+
}[];
|
|
26
|
+
updateDrawing: (id: string, patch: Partial<DrawingObject>) => void;
|
|
27
|
+
/** Người dùng bật/tắt nhóm alert (UI). Mặc định bật. */
|
|
28
|
+
muted?: boolean;
|
|
29
|
+
}
|
|
30
|
+
export interface UseDrawingAlertsResult {
|
|
31
|
+
items: DrawingAlertToastItem[];
|
|
32
|
+
dismiss: (id: string) => void;
|
|
33
|
+
clear: () => void;
|
|
34
|
+
/** Có đang hiện cảnh báo "local only" không. */
|
|
35
|
+
isLocalOnly: boolean;
|
|
36
|
+
}
|
|
37
|
+
export declare function useDrawingAlerts({ enabled, drawings, plotData, updateDrawing, muted, }: UseDrawingAlertsOptions): UseDrawingAlertsResult;
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Canary bar filtering logic for progressive rollout.
|
|
3
|
+
* Implements percentage-based visibility of most recent bars.
|
|
4
|
+
*/
|
|
5
|
+
import type { OHLCVBar } from "../lib/types/ohlcv";
|
|
6
|
+
import type { CanaryLevel } from "./CanaryRolloutConfig";
|
|
7
|
+
/**
|
|
8
|
+
* Apply canary filter to visible bars.
|
|
9
|
+
* When canaryLevel < 100, returns only the most recent N% of bars.
|
|
10
|
+
* Maintains temporal order and data integrity.
|
|
11
|
+
*
|
|
12
|
+
* @param bars All visible bars from data source
|
|
13
|
+
* @param canaryLevel Canary percentage (10, 30, or 100)
|
|
14
|
+
* @returns Filtered bars (subset when canaryLevel < 100)
|
|
15
|
+
*
|
|
16
|
+
* @example
|
|
17
|
+
* const allBars = [bar1, bar2, ..., bar1000];
|
|
18
|
+
* const canary10 = applyCanaryFilter(allBars, 10);
|
|
19
|
+
* // => last ~100 bars (10% of 1000)
|
|
20
|
+
*
|
|
21
|
+
* const canary100 = applyCanaryFilter(allBars, 100);
|
|
22
|
+
* // => all bars unchanged
|
|
23
|
+
*/
|
|
24
|
+
export declare function applyCanaryFilter(bars: readonly OHLCVBar[], canaryLevel: CanaryLevel): readonly OHLCVBar[];
|
|
25
|
+
/**
|
|
26
|
+
* Calculate canary slice statistics (for debugging/logging).
|
|
27
|
+
* @param totalBars Total bars available
|
|
28
|
+
* @param canaryLevel Canary percentage
|
|
29
|
+
* @returns Slice information
|
|
30
|
+
*/
|
|
31
|
+
export declare function getCanarySliceInfo(totalBars: number, canaryLevel: CanaryLevel): {
|
|
32
|
+
keepCount: number;
|
|
33
|
+
percentage: number;
|
|
34
|
+
description: string;
|
|
35
|
+
};
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
import { hasCapability, minTierFor, type Capability, type PatTier } from "@vninvestcharts/engine-core";
|
|
2
|
+
/**
|
|
3
|
+
* CapabilityResolver — nơi DUY NHẤT quyết định tính năng nào được bật.
|
|
4
|
+
*
|
|
5
|
+
* Trước W0.4 có 5 nơi hardcode ngưỡng `"pro"` rải rác. Nay:
|
|
6
|
+
* tier (PAT / license offline) ─┐
|
|
7
|
+
* backend probe ─────────────────┼─▶ ResolvedCapabilities ─┬─▶ UI gate
|
|
8
|
+
* device caps ────────────────────┘ ├─▶ Engine gate
|
|
9
|
+
* └─▶ Upsell CTA
|
|
10
|
+
*
|
|
11
|
+
* Ba trạng thái phân biệt rõ (PLAN_FRONTEND_PROPLUS_TRACKA §4.1):
|
|
12
|
+
* granted — đủ quyền VÀ dữ liệu khả dụng ⇒ render thật
|
|
13
|
+
* degraded — đủ quyền nhưng backend chưa sẵn sàng / thiết bị yếu / hết quota
|
|
14
|
+
* ⇒ `UnavailableState` (trung thực, KHÔNG upsell)
|
|
15
|
+
* locked — chưa đủ quyền ⇒ `LockedFeature` (upsell)
|
|
16
|
+
*
|
|
17
|
+
* Nguyên tắc: **KHÔNG** giả lập dữ liệu (AGENTS.md Rule 15). `degraded` không
|
|
18
|
+
* bao giờ biến thành dữ liệu 0/skeleton.
|
|
19
|
+
*/
|
|
20
|
+
export type DegradeReason = "backend_missing" | "device_limited" | "perf_budget" | "quota_local" | "data_unavailable";
|
|
21
|
+
export type ResolvedState = {
|
|
22
|
+
state: "granted";
|
|
23
|
+
} | {
|
|
24
|
+
state: "degraded";
|
|
25
|
+
reason: DegradeReason;
|
|
26
|
+
} | {
|
|
27
|
+
state: "locked";
|
|
28
|
+
requires: PatTier;
|
|
29
|
+
};
|
|
30
|
+
/** Kết quả probe backend. `null` = chưa biết (probe chưa chạy / lỗi mạng). */
|
|
31
|
+
export interface BackendAvailability {
|
|
32
|
+
/** Endpoint health có sống không. */
|
|
33
|
+
healthOk: boolean;
|
|
34
|
+
/** Có dữ liệu whale-feed (fallback khi whale-campaigns chưa mount). */
|
|
35
|
+
whaleFeedOk: boolean;
|
|
36
|
+
/** Đã probe xong chưa (phân biệt "chưa biết" với "biết là không có"). */
|
|
37
|
+
probed: boolean;
|
|
38
|
+
probedAt: number;
|
|
39
|
+
}
|
|
40
|
+
export declare const UNKNOWN_AVAILABILITY: BackendAvailability;
|
|
41
|
+
export interface DeviceCaps {
|
|
42
|
+
/** Mobile / màn hình hẹp ⇒ tắt footprint, auto pattern, deep backtest. */
|
|
43
|
+
narrow: boolean;
|
|
44
|
+
/** Số core logic — dùng để quyết định có bật tác vụ nặng. */
|
|
45
|
+
concurrency: number;
|
|
46
|
+
}
|
|
47
|
+
export declare const UNKNOWN_DEVICE: DeviceCaps;
|
|
48
|
+
export interface ResolverInput {
|
|
49
|
+
tier: PatTier | null | undefined;
|
|
50
|
+
backend?: BackendAvailability;
|
|
51
|
+
device?: DeviceCaps;
|
|
52
|
+
/** Ghi đè thủ công (ví dụ user đã đọc cảnh báo, hoặc quota đã đo được). */
|
|
53
|
+
forcedReason?: Partial<Record<Capability, DegradeReason>>;
|
|
54
|
+
/**
|
|
55
|
+
* Allowlist do license ký số thu hẹp (payload `caps`). `undefined` = không giới
|
|
56
|
+
* hạn. CHỈ được thu hẹp, không bao giờ nâng: kết quả luôn là tập con của
|
|
57
|
+
* `capabilitiesFor(tier)`. Cùng ngữ nghĩa với `TierGateOptions.narrowing` — giữ hai
|
|
58
|
+
* hệ gate cùng một quy tắc, thay vì một thu hẹp còn một thì không.
|
|
59
|
+
*/
|
|
60
|
+
narrowing?: readonly Capability[];
|
|
61
|
+
}
|
|
62
|
+
export type ResolvedCapabilities = Readonly<Record<Capability, ResolvedState>>;
|
|
63
|
+
export declare function resolveCapabilities(input: ResolverInput): ResolvedCapabilities;
|
|
64
|
+
/** Tiện ích: capability có dùng được (granted) không. */
|
|
65
|
+
export declare function isUsable(state: ResolvedState | undefined): boolean;
|
|
66
|
+
/** Tiện ích: có cần hiện upsell không (chỉ `locked`). */
|
|
67
|
+
export declare function isLocked(state: ResolvedState | undefined): boolean;
|
|
68
|
+
/** Tiện ích: có phải degraded do backend chưa sẵn sàng không. */
|
|
69
|
+
export declare function isBackendMissing(state: ResolvedState | undefined): boolean;
|
|
70
|
+
export { hasCapability, minTierFor };
|
|
71
|
+
export type { Capability, PatTier };
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { type BackendAvailability, type DeviceCaps } from "./CapabilityResolver";
|
|
2
|
+
export interface ProbeOptions {
|
|
3
|
+
/** Base URL backend, ví dụ `http://localhost:8080`. `null` = chưa cấu hình. */
|
|
4
|
+
baseUrl: string | null | undefined;
|
|
5
|
+
/** Bearer PAT (nếu có). Không bắt buộc cho health. */
|
|
6
|
+
token?: string | null;
|
|
7
|
+
/** Mã dùng cho sentinel quote. */
|
|
8
|
+
probeSymbol?: string;
|
|
9
|
+
/** Timeout mỗi request (ms). */
|
|
10
|
+
timeoutMs?: number;
|
|
11
|
+
fetchImpl?: typeof fetch;
|
|
12
|
+
now?: () => number;
|
|
13
|
+
}
|
|
14
|
+
export interface ProbeResult extends BackendAvailability {
|
|
15
|
+
/** Lý do cụ thể, để log/diagnostics — không hiển thị cho user. */
|
|
16
|
+
detail?: string;
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* Probe backend. Trả về cache nếu còn hạn.
|
|
20
|
+
* - `healthOk=false` + `probed=true` ⇒ backend chắc chắn không sống.
|
|
21
|
+
* - `probed=false` ⇒ **chưa biết** (chưa probe, không có baseUrl, hoặc lỗi mạng) —
|
|
22
|
+
* Track A phải vẫn chạy được (client-side).
|
|
23
|
+
*/
|
|
24
|
+
export declare function probeBackend(options: ProbeOptions): Promise<ProbeResult>;
|
|
25
|
+
/** Xoá cache — dùng trong test và khi người dùng đổi PAT. */
|
|
26
|
+
export declare function resetProbeCache(): void;
|
|
27
|
+
/** Phát hiện giới hạn thiết bị. Không bao giờ đoán quá mức (thiếu ⇒ coi như desktop). */
|
|
28
|
+
export declare function detectDeviceCaps(): DeviceCaps;
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import { type Capability, type PatTier } from "@vninvestcharts/engine-core";
|
|
2
|
+
/**
|
|
3
|
+
* useTierGatedFeatures — W0.5: ép thực thi capability gate cho các cờ
|
|
4
|
+
* "có trong context nhưng KHÔNG ai gate" (audit F5/F11/F12/F13).
|
|
5
|
+
*
|
|
6
|
+
* Vấn đề gốc: `SaaSFeatureFlags` có `isReplayEnabled` nhưng `useReplayState`
|
|
7
|
+
* không hề hỏi ⇒ replay miễn phí. Tương tự `paperVisibility`, `PineEditorPanel`,
|
|
8
|
+
* `StrategyTesterPanel` đều không gate tier.
|
|
9
|
+
*
|
|
10
|
+
* Nguyên tắc: capability là **điều kiện cần**, cờ SaaS là **điều kiện đủ** (vẫn
|
|
11
|
+
* phải tôn trọng tenant tắt tính năng). ⇒ `granted = hasCapability(tier, cap) && flag`.
|
|
12
|
+
* Không dùng `||` — đó là lỗi kinh điển làm lộ Pro.
|
|
13
|
+
*/
|
|
14
|
+
export interface TierGatedFeatures {
|
|
15
|
+
/** Replay: cần `replay` + cờ `isReplayEnabled`. */
|
|
16
|
+
canUseReplay: boolean;
|
|
17
|
+
/**
|
|
18
|
+
* Paper trading mức thấp (market/limit) — Community, luôn mở.
|
|
19
|
+
* S1: dùng ở `paperVisibility.filterOrderTypesByTier` để lọc loại lệnh.
|
|
20
|
+
*/
|
|
21
|
+
canUsePaperMarketLimit: boolean;
|
|
22
|
+
/**
|
|
23
|
+
* Paper trading nâng cao (stop/trailing/plo + risk) — cần `paper_advanced`.
|
|
24
|
+
* S1: nguồn sự thật duy nhất cho gate lệnh nâng cao (thay `toSeriesTier(tier)`).
|
|
25
|
+
*/
|
|
26
|
+
canUsePaperAdvanced: boolean;
|
|
27
|
+
/** Trình soạn thảo Pine. */
|
|
28
|
+
canUsePineEditor: boolean;
|
|
29
|
+
/** Bộ kiểm thử chiến lược. */
|
|
30
|
+
canUseStrategyTester: boolean;
|
|
31
|
+
/**
|
|
32
|
+
* `allows` là API dùng thật. Trước S1 có thêm `canUseAdvisory` / `canUseWhalePanel`
|
|
33
|
+
* — **không consumer nào** (grep toàn repo: chỉ 2 hit, đều là chính dòng định
|
|
34
|
+
* nghĩa). Xoá vì hàm chết ở đây là bẫy cho người sau: tưởng đã gate.
|
|
35
|
+
* Cần thì gọi `allows("pro_plugin")` kèm cờ SaaS, đúng như `canUseReplay` làm.
|
|
36
|
+
*/
|
|
37
|
+
allows: (capability: Capability) => boolean;
|
|
38
|
+
}
|
|
39
|
+
export interface TierGateOptions {
|
|
40
|
+
/**
|
|
41
|
+
* W0.6 — allowlist do license ký số thu hẹp (payload `caps`).
|
|
42
|
+
* `undefined` = không giới hạn (mọi license cũ). Danh sách này **chỉ được
|
|
43
|
+
* thu hẹp**, không bao giờ nâng: kết quả luôn là tập con của `MIN_TIER(tier)`.
|
|
44
|
+
* Nhờ vậy khách offline gate được Track A mà không cần gọi backend.
|
|
45
|
+
*/
|
|
46
|
+
narrowing?: readonly Capability[];
|
|
47
|
+
}
|
|
48
|
+
export declare function useTierGatedFeatures(tier: PatTier | null | undefined, options?: TierGateOptions): TierGatedFeatures;
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
import type { SeriesConfig } from "../../lib/core";
|
|
2
|
+
import type { BottomPanelHeightApi } from "../hooks/useBottomPanelHeight";
|
|
3
|
+
export type BottomTab = "strategy_tester" | "pine_editor" | "paper_trade" | null;
|
|
4
|
+
export interface BottomPanelHostProps {
|
|
5
|
+
/** Currently active tab */
|
|
6
|
+
activeTab: BottomTab;
|
|
7
|
+
/** Callback when tab changes */
|
|
8
|
+
onTabChange: (tab: BottomTab) => void;
|
|
9
|
+
/** Plot data for strategy tester */
|
|
10
|
+
plotData: any[];
|
|
11
|
+
/** Active symbol */
|
|
12
|
+
symbol: string;
|
|
13
|
+
/** Active timeframe */
|
|
14
|
+
timeframe: string;
|
|
15
|
+
/** Active indicator configs */
|
|
16
|
+
activeIndicators: any[];
|
|
17
|
+
/** Dark mode */
|
|
18
|
+
isDark: boolean;
|
|
19
|
+
/** Callback to add indicator from Pine Editor to active chart */
|
|
20
|
+
onAddIndicator?: (config: SeriesConfig) => void;
|
|
21
|
+
/**
|
|
22
|
+
* Tier grants for the two paid tabs. FAIL-CLOSED: absent means NOT granted.
|
|
23
|
+
*
|
|
24
|
+
* This host is rendered by `VNInvestMultiCharts`, which sits ABOVE the per-chart
|
|
25
|
+
* `CapabilityProvider`, so reading capability state from context here would resolve
|
|
26
|
+
* `tier=null` and lock the tabs for paying customers too. The host therefore
|
|
27
|
+
* resolves `hasCapability(patTier, …)` from its own tier (same idiom as its
|
|
28
|
+
* `export_png` gate) and passes the booleans in.
|
|
29
|
+
*
|
|
30
|
+
* The default is deliberately locked: a future call site that forgets to pass a
|
|
31
|
+
* grant gets the upsell badge instead of the feature.
|
|
32
|
+
*/
|
|
33
|
+
canUsePineEditor?: boolean;
|
|
34
|
+
canUseStrategyTester?: boolean;
|
|
35
|
+
/** OHLCV bars for PineScript compilation */
|
|
36
|
+
bars?: {
|
|
37
|
+
open: number[];
|
|
38
|
+
high: number[];
|
|
39
|
+
low: number[];
|
|
40
|
+
close: number[];
|
|
41
|
+
volume: number[];
|
|
42
|
+
};
|
|
43
|
+
/** Custom render for paper trade panel */
|
|
44
|
+
renderPaperTradePanel?: (props: {
|
|
45
|
+
positions: any[];
|
|
46
|
+
journal: any[];
|
|
47
|
+
onReset: () => void;
|
|
48
|
+
onClose: () => void;
|
|
49
|
+
}) => React.ReactNode;
|
|
50
|
+
/** Dữ liệu thật từ workspace singleton (H3) — truyền xuống renderPaperTradePanel thay vì hardcode rỗng. */
|
|
51
|
+
paperTradeData?: {
|
|
52
|
+
positions: any[];
|
|
53
|
+
journal: any[];
|
|
54
|
+
onReset: () => void;
|
|
55
|
+
onClose: () => void;
|
|
56
|
+
};
|
|
57
|
+
/** Show advisory panel */
|
|
58
|
+
showAdvisoryPanel?: boolean;
|
|
59
|
+
/** Advisory result */
|
|
60
|
+
advisoryResult?: any;
|
|
61
|
+
/** Native advisory session (V2) — renders instead of advisoryResult when provided */
|
|
62
|
+
advisorySession?: import("../../lib/types/vninvest").AdvisorySessionV2 | null;
|
|
63
|
+
/** Advisory loading */
|
|
64
|
+
isAdvisoryLoading?: boolean;
|
|
65
|
+
/** On advisory refresh */
|
|
66
|
+
onAdvisoryRefresh?: () => void;
|
|
67
|
+
/** Show tape panel */
|
|
68
|
+
showTapePanel?: boolean;
|
|
69
|
+
/** Tape entries */
|
|
70
|
+
tapeEntries?: any[];
|
|
71
|
+
/** Tape loading */
|
|
72
|
+
isTapeLoading?: boolean;
|
|
73
|
+
/** Tape filter billions */
|
|
74
|
+
tapeFilterBillions?: number;
|
|
75
|
+
/** On tape filter change */
|
|
76
|
+
onTapeFilterChange?: (value: number) => void;
|
|
77
|
+
/** Resizable height API (useBottomPanelHeight); omit for fixed var height */
|
|
78
|
+
panelHeight?: BottomPanelHeightApi;
|
|
79
|
+
}
|
|
80
|
+
export declare function BottomPanelHost({ activeTab, onTabChange, plotData, symbol, timeframe, activeIndicators, isDark, onAddIndicator, renderPaperTradePanel, showAdvisoryPanel, advisoryResult, advisorySession, isAdvisoryLoading, onAdvisoryRefresh, showTapePanel, tapeEntries, isTapeLoading, tapeFilterBillions, onTapeFilterChange, bars, paperTradeData, panelHeight, canUsePineEditor, canUseStrategyTester, }: BottomPanelHostProps): import("react").JSX.Element | null;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* BottomPanelSplitter — drag handle on the panel top edge (TradingView-style).
|
|
3
|
+
*
|
|
4
|
+
* Grid-splitter parity for drag speed: absolute-from-origin delta against a
|
|
5
|
+
* start-height snapshot (immune to browser pointermove coalescing, which made
|
|
6
|
+
* the old incremental deltas lose distance), direct DOM preview on the panel
|
|
7
|
+
* container during the move (zero React renders, zero storage I/O), and a
|
|
8
|
+
* single `resizeTo` commit on pointer-up (one render + one persist).
|
|
9
|
+
* Pointer capture (grid pattern), double-click reset, ArrowUp/Down nudge.
|
|
10
|
+
* Pure passthrough over BottomPanelHeightApi (hook owns state + persistence).
|
|
11
|
+
*/
|
|
12
|
+
import type { BottomPanelHeightApi } from "../hooks/useBottomPanelHeight";
|
|
13
|
+
export declare function BottomPanelSplitter({ api }: {
|
|
14
|
+
api: BottomPanelHeightApi;
|
|
15
|
+
}): import("react").JSX.Element;
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
import { type ReactNode } from "react";
|
|
2
|
+
import { type Capability, type PatTier } from "@vninvestcharts/engine-core";
|
|
3
|
+
import { type BackendAvailability, type DegradeReason, type DeviceCaps, type ResolvedCapabilities, type ResolvedState } from "../capabilities/CapabilityResolver";
|
|
4
|
+
/**
|
|
5
|
+
* CapabilityGate — cổng UI cho 3 trạng thái (W0.4).
|
|
6
|
+
*
|
|
7
|
+
* granted ⇒ render `children` thật
|
|
8
|
+
* locked ⇒ `LockedFeature` (upsell, có tên + lợi ích từ i18n)
|
|
9
|
+
* degraded ⇒ `UnavailableState` (trung thực, KHÔNG upsell, KHÔNG giả dữ liệu)
|
|
10
|
+
*
|
|
11
|
+
* Dùng:
|
|
12
|
+
* <CapabilityGate capability="indicator_full">{…}</CapabilityGate>
|
|
13
|
+
* hoặc kiểm tra thủ công:
|
|
14
|
+
* const caps = useResolvedCapabilities();
|
|
15
|
+
* if (!isUsable(caps.indicator_full)) …
|
|
16
|
+
*/
|
|
17
|
+
export interface CapabilityContextValue {
|
|
18
|
+
tier: PatTier | null;
|
|
19
|
+
backend: BackendAvailability;
|
|
20
|
+
device: DeviceCaps;
|
|
21
|
+
caps: ResolvedCapabilities;
|
|
22
|
+
/** Nguồn quyết định tier, để hiển thị/báo cáo (không dùng để cấp quyền). */
|
|
23
|
+
tierSource: "license" | "pat" | "none";
|
|
24
|
+
}
|
|
25
|
+
export interface CapabilityProviderProps {
|
|
26
|
+
tier: PatTier | null | undefined;
|
|
27
|
+
tierSource?: CapabilityContextValue["tierSource"];
|
|
28
|
+
backend?: BackendAvailability;
|
|
29
|
+
device?: DeviceCaps;
|
|
30
|
+
forcedReason?: Partial<Record<Capability, DegradeReason>>;
|
|
31
|
+
/** Allowlist license thu hẹp (payload `caps`). Chỉ thu hẹp, không bao giờ nâng. */
|
|
32
|
+
narrowing?: readonly Capability[];
|
|
33
|
+
children: ReactNode;
|
|
34
|
+
}
|
|
35
|
+
export declare function CapabilityProvider({ tier, tierSource, backend, device, forcedReason, narrowing, children, }: CapabilityProviderProps): import("react").JSX.Element;
|
|
36
|
+
export declare function useResolvedCapabilities(): CapabilityContextValue;
|
|
37
|
+
/** Hook gate rút gọn: `const can = useCapabilityGate("export_png")`. */
|
|
38
|
+
export declare function useCapabilityGate(capability: Capability): ResolvedState;
|
|
39
|
+
/** `true` khi capability dùng được (granted). */
|
|
40
|
+
export declare function useHasCapability(capability: Capability): boolean;
|
|
41
|
+
/** Tương đương `hasCapability` nhưng đọc tier từ context. */
|
|
42
|
+
export declare function useTierAllows(capability: Capability): boolean;
|
|
43
|
+
declare const REASON_KEY: Readonly<Record<DegradeReason, string>>;
|
|
44
|
+
/** Tên hiển thị của gói cần để mở capability (dùng trong upsell). */
|
|
45
|
+
declare function planLabelKey(tier: PatTier): string;
|
|
46
|
+
export interface LockedFeatureProps {
|
|
47
|
+
capability: Capability;
|
|
48
|
+
/** Nội dung thật, chỉ render khi granted. */
|
|
49
|
+
children: ReactNode;
|
|
50
|
+
/** Hiển thị nút khoá thay vì render (cho toolbar item). */
|
|
51
|
+
asLockBadge?: boolean;
|
|
52
|
+
onLockedClick?: () => void;
|
|
53
|
+
}
|
|
54
|
+
export declare function CapabilityGate({ capability, children }: Omit<LockedFeatureProps, "asLockBadge" | "onLockedClick">): import("react").JSX.Element;
|
|
55
|
+
export declare function LockedFeature({ capability, requiredTier, onLockedClick, }: {
|
|
56
|
+
capability: Capability;
|
|
57
|
+
requiredTier: PatTier;
|
|
58
|
+
onLockedClick?: () => void;
|
|
59
|
+
}): import("react").JSX.Element;
|
|
60
|
+
export declare function UnavailableState({ reason, capability, compact, }: {
|
|
61
|
+
reason: DegradeReason;
|
|
62
|
+
capability?: Capability;
|
|
63
|
+
compact?: boolean;
|
|
64
|
+
}): import("react").JSX.Element;
|
|
65
|
+
export { REASON_KEY, planLabelKey };
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
export interface ChartDiagSnapshot {
|
|
2
|
+
enginePresent: boolean;
|
|
3
|
+
forkEngineSet: boolean;
|
|
4
|
+
isForkRuntime: boolean;
|
|
5
|
+
bars: number;
|
|
6
|
+
enriched: number;
|
|
7
|
+
plot: number;
|
|
8
|
+
panes: string;
|
|
9
|
+
chartType: string;
|
|
10
|
+
tier: string;
|
|
11
|
+
dataError: string;
|
|
12
|
+
engineRange: string;
|
|
13
|
+
canvases: string;
|
|
14
|
+
/** Engine-side scale domains per pane (NaN/garbage domain = render killer). */
|
|
15
|
+
domains: string;
|
|
16
|
+
/** Engine paneSpecs ids (empty = specs feed never fired = root cause). */
|
|
17
|
+
specs: string;
|
|
18
|
+
/** Non-finite OHLC scan over engine enrichedData (count + first bad index). */
|
|
19
|
+
nanScan: string;
|
|
20
|
+
/** Last bar close + date ISO (stale-data check). */
|
|
21
|
+
lastBar: string;
|
|
22
|
+
}
|
|
23
|
+
export declare function isDiagEnabled(): boolean;
|
|
24
|
+
/**
|
|
25
|
+
* BLACKSCREEN-DIAG: query-gated runtime readout (?vnsc_diag=1 or localStorage).
|
|
26
|
+
* Zero production impact: renders nothing unless the flag is set. Used to
|
|
27
|
+
* capture exact engine/data/pane state from a black-screen browser.
|
|
28
|
+
*/
|
|
29
|
+
export declare function ChartDiagOverlay({ getSnapshot }: {
|
|
30
|
+
getSnapshot: () => ChartDiagSnapshot;
|
|
31
|
+
}): import("react").JSX.Element | null;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export interface ConfirmDialogProps {
|
|
2
|
+
open: boolean;
|
|
3
|
+
title?: string;
|
|
4
|
+
message: string;
|
|
5
|
+
confirmLabel?: string;
|
|
6
|
+
cancelLabel?: string;
|
|
7
|
+
variant?: "danger" | "default";
|
|
8
|
+
onConfirm: () => void;
|
|
9
|
+
onCancel: () => void;
|
|
10
|
+
portalRoot?: HTMLElement | null;
|
|
11
|
+
}
|
|
12
|
+
export declare function ConfirmDialog({ open, title, message, confirmLabel, cancelLabel, variant, onConfirm, onCancel, portalRoot, }: ConfirmDialogProps): import("react").ReactPortal | null;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export interface DowngradeBannerProps {
|
|
2
|
+
open: boolean;
|
|
3
|
+
upgradeUrl?: string;
|
|
4
|
+
onDismiss: () => void;
|
|
5
|
+
onUpgrade: () => void;
|
|
6
|
+
}
|
|
7
|
+
export declare function DowngradeBanner({ open, upgradeUrl, onDismiss, onUpgrade, portalRoot: portalRootProp }: DowngradeBannerProps & {
|
|
8
|
+
portalRoot?: HTMLElement | null;
|
|
9
|
+
}): import("react").ReactPortal | null;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { type WidgetPaneRuntimeSnapshot } from "../utils/widgetHelpers";
|
|
2
|
+
export interface ForkPaneSeparatorsProps {
|
|
3
|
+
paneSnapshots: readonly WidgetPaneRuntimeSnapshot[];
|
|
4
|
+
/** Pane whose bottom edge meets the X-axis strip (no separator there). */
|
|
5
|
+
lastPaneId?: string;
|
|
6
|
+
}
|
|
7
|
+
/**
|
|
8
|
+
* UI-C: 1px TradingView-style separators between stacked subpanes.
|
|
9
|
+
* Widget-only (reads engine paneSnapshots, draws DOM lines, no engine change).
|
|
10
|
+
*/
|
|
11
|
+
export declare function ForkPaneSeparators({ paneSnapshots, lastPaneId, }: ForkPaneSeparatorsProps): import("react").JSX.Element | null;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { type EnrichedDatum } from "../../lib/core/calculators/types";
|
|
2
|
+
import { type WidgetPaneRuntimeSnapshot } from "../utils/widgetHelpers";
|
|
3
|
+
import { type PaneDescriptor } from "../../lib/core";
|
|
4
|
+
export interface ForkPaneTooltipsProps {
|
|
5
|
+
hoveredDatum?: EnrichedDatum | null;
|
|
6
|
+
lastDatum?: EnrichedDatum | null;
|
|
7
|
+
symbol?: string;
|
|
8
|
+
timeframe?: string;
|
|
9
|
+
isDark: boolean;
|
|
10
|
+
paneSnapshots: readonly WidgetPaneRuntimeSnapshot[];
|
|
11
|
+
panes: readonly PaneDescriptor[];
|
|
12
|
+
onSettingsClick?: () => void;
|
|
13
|
+
onToggleSeriesVisibility?: (seriesId: string) => void;
|
|
14
|
+
onRemoveIndicator?: (paneId: string, seriesId: string) => void;
|
|
15
|
+
/** DECLUTTER_V4: compare legend node rendered below the OHLC row (single-chart). */
|
|
16
|
+
renderCompareLegend?: (paneId: string) => React.ReactNode;
|
|
17
|
+
/**
|
|
18
|
+
* SINGLE-OHLC: hide the statusline symbol+OHLC row (the widget header
|
|
19
|
+
* already shows it). Compare chips move up just under the chart header.
|
|
20
|
+
*/
|
|
21
|
+
hideStatusOhlc?: boolean;
|
|
22
|
+
}
|
|
23
|
+
export declare function ForkPaneTooltips({ hoveredDatum, lastDatum, symbol, timeframe, isDark, paneSnapshots, panes, onSettingsClick, onToggleSeriesVisibility, onRemoveIndicator, renderCompareLegend, hideStatusOhlc, }: ForkPaneTooltipsProps): (import("react").JSX.Element | null)[];
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { type ForkXAxisTick, type ForkXAxisHoverLabel } from "../utils/widgetHelpers";
|
|
2
|
+
export interface ForkXAxisOverlayProps {
|
|
3
|
+
ticks: readonly ForkXAxisTick[];
|
|
4
|
+
hoverLabel?: ForkXAxisHoverLabel;
|
|
5
|
+
top: number;
|
|
6
|
+
isDark: boolean;
|
|
7
|
+
showHoverLabel?: boolean;
|
|
8
|
+
/** Container width for edge clamping (grid cells are narrower than window). */
|
|
9
|
+
width?: number;
|
|
10
|
+
}
|
|
11
|
+
export declare function ForkXAxisOverlay({ ticks, hoverLabel, top, isDark, showHoverLabel, width, }: ForkXAxisOverlayProps): import("react").JSX.Element | null;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { type EngineOverlayState } from "@vninvestcharts/engine-core";
|
|
2
|
+
import { type WidgetPaneRuntimeSnapshot } from "../utils/widgetHelpers";
|
|
3
|
+
export interface ForkYAxisCrosshairLabelsProps {
|
|
4
|
+
overlayState: EngineOverlayState | null;
|
|
5
|
+
isDark: boolean;
|
|
6
|
+
paneSnapshots: readonly WidgetPaneRuntimeSnapshot[];
|
|
7
|
+
labelColorByPane?: ReadonlyMap<string, string>;
|
|
8
|
+
}
|
|
9
|
+
export declare function ForkYAxisCrosshairLabels({ overlayState, isDark, paneSnapshots, labelColorByPane, }: ForkYAxisCrosshairLabelsProps): import("react").JSX.Element | null;
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { GridLayout, LayoutPreset } from "../grid/types";
|
|
3
|
+
interface LayoutDesignerProps {
|
|
4
|
+
layout: GridLayout;
|
|
5
|
+
onLayoutChange: (layout: GridLayout) => void;
|
|
6
|
+
/**
|
|
7
|
+
* P0: trả `false` nếu **chưa lưu được** (storage lỗi/hết quota). `undefined` = không
|
|
8
|
+
* có handler ⇒ cũng là thất bại. Trước P0 kiểu trả `void` khiến modal đóng dù chưa
|
|
9
|
+
* lưu gì — dữ liệu người dùng bị nuốt trong im lặng (Rule 15).
|
|
10
|
+
*/
|
|
11
|
+
onSaveAsPreset?: (preset: LayoutPreset) => boolean | void;
|
|
12
|
+
/**
|
|
13
|
+
* P0: danh sách preset đã lưu. Trước đây prop này chỉ tồn tại trong type + default
|
|
14
|
+
* (`:19`, `:28`) mà **không được render** ⇒ preset lưu được rồi không ai thấy, không
|
|
15
|
+
* apply, không xoá được. Có `availablePresets` thì phải render.
|
|
16
|
+
*/
|
|
17
|
+
availablePresets?: LayoutPreset[];
|
|
18
|
+
/** Áp dụng preset đã lưu (thay layout hiện tại). */
|
|
19
|
+
onApplyPreset?: (preset: LayoutPreset) => void;
|
|
20
|
+
/** Xoá preset đã lưu. `undefined` ⇒ không hiện nút xoá. */
|
|
21
|
+
onDeletePreset?: (preset: LayoutPreset) => void;
|
|
22
|
+
isOpen: boolean;
|
|
23
|
+
onClose: () => void;
|
|
24
|
+
}
|
|
25
|
+
export declare const LayoutDesigner: React.FC<LayoutDesignerProps>;
|
|
26
|
+
export default LayoutDesigner;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { SaaSFeatureFlags } from '../types/saas';
|
|
2
|
+
import type { ReactNode } from 'react';
|
|
3
|
+
export interface PremiumFeatureGateProps {
|
|
4
|
+
feature: keyof SaaSFeatureFlags;
|
|
5
|
+
children: ReactNode;
|
|
6
|
+
fallback?: ReactNode;
|
|
7
|
+
upgradeUrl?: string;
|
|
8
|
+
mode?: 'blur' | 'unmount';
|
|
9
|
+
}
|
|
10
|
+
export declare function PremiumFeatureGate({ feature, children, fallback, upgradeUrl, mode, }: PremiumFeatureGateProps): import("react").JSX.Element;
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Core rows — **DỰA TRÊN NƠI BINDING THẬT**, không phải bản ghi tay.
|
|
3
|
+
*
|
|
4
|
+
* Trước 2026-09-30 đây là mảng literal 6 dòng, trong khi docblock dưới nói
|
|
5
|
+
* "rows are built from the shortcut SSOT so they can never drift" — **không đúng** với
|
|
6
|
+
* chính 6 dòng đó. Tệ hơn: modal **thiếu** 7 phím đang chạy thật.
|
|
7
|
+
*
|
|
8
|
+
* Mỗi dòng khai báo `key` + nơi bind thật, để drift lộ ra khi ai đó đổi binding mà quên
|
|
9
|
+
* cập nhật modal. `ShortcutManager.collision.test.ts` kiểm phần còn lại (trùng phím).
|
|
10
|
+
*/
|
|
11
|
+
export declare const CORE_ROWS: Array<{
|
|
12
|
+
keys: string;
|
|
13
|
+
label: string;
|
|
14
|
+
binding: string;
|
|
15
|
+
}>;
|
|
16
|
+
/**
|
|
17
|
+
* BL-16 + BL-21: discoverability for the window-global keyboard UX. Opens on `?`
|
|
18
|
+
* (Shift+/).
|
|
19
|
+
*
|
|
20
|
+
* Tool rows derive from `ALT_TOOL_SHORTCUTS` / `TOOL_SHORTCUT_KEYS` (SSOT, xem phần render
|
|
21
|
+
* bên dưới). Core rows thì **không** suy ra được từ một danh sách duy nhất — chúng thuộc
|
|
22
|
+
* nhiều module (`useWidgetDrawings`, `ShortcutManager`, `useTradingHotkeys`, `OHLCHeader`,
|
|
23
|
+
* `GridContainer`) — nên `CORE_ROWS` khai **kèm `binding` là nơi bind thật**, để khi ai đó
|
|
24
|
+
* đổi binding mà quên sửa modal thì đó là việc phải sửa tường minh chứ không phải drift
|
|
25
|
+
* âm thầm. (Trước 2026-09-30 đây là literal 6 dòng, thiếu 7 phím đang chạy, còn docblock
|
|
26
|
+
* lại khẳng định "derived from SSOT".)
|
|
27
|
+
*
|
|
28
|
+
* `CORE_ROWS` export ra để test kiểm **từng dòng có thực sự render** — thay vì đếm tổng
|
|
29
|
+
* số dòng cứng (xem `ShortcutHelpModal.test.tsx` HELP-COMPACT).
|
|
30
|
+
*
|
|
31
|
+
* UI-AUDIT: the first-run hint renders INLINE (no absolute floating) —
|
|
32
|
+
* mount this component inside the footer right cluster. The modal overlay
|
|
33
|
+
* itself stays absolutely anchored to .vnsc-root.
|
|
34
|
+
*/
|
|
35
|
+
export declare function ShortcutHelpModal({ hintInline, showHint, }: {
|
|
36
|
+
hintInline?: boolean;
|
|
37
|
+
/**
|
|
38
|
+
* UI-AUDIT / multicharts: hint **mặc định ẩn**. Trước đây mọi ô chart đều render một
|
|
39
|
+
* chip "? Phím tắt", nên 4 ô là 4 chip lặp lại — rất vô duyên và ăn chiều cao footer.
|
|
40
|
+
* Modal vẫn mở bằng phím `?` ở bất kỳ đâu, và một modal duy nhất cho cả grid (đã khoá
|
|
41
|
+
* bằng `openDialogCount`), nên ẩn hint **không** làm mất khả năng tiếp cận.
|
|
42
|
+
*/
|
|
43
|
+
showHint?: boolean;
|
|
44
|
+
}): import("react").JSX.Element | null;
|