@luxalgo/vela 0.6.5 → 0.6.7
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/README.md +16 -16
- package/dist/{DataProvider-BmHkcwvJ.d.ts → DataProvider-BSLlBpB9.d.ts} +11 -1
- package/dist/{DataProvider-DrN7ZIou.d.cts → DataProvider-BsQM2WNH.d.cts} +11 -1
- package/dist/{history-BmyjaVir.d.cts → bottombar-Br4rzx_R.d.ts} +158 -129
- package/dist/{history-CvOtsjT5.d.ts → bottombar-Div5zibZ.d.cts} +158 -129
- package/dist/{chunk-FQBT4NFM.js → chunk-6WFKTAT4.js} +2797 -2527
- package/dist/{chunk-BEJ57HP4.js → chunk-L3I2CCYO.js} +62 -1
- package/dist/chunk-W4EJWLEO.js +12 -0
- package/dist/{chunk-N6MBJHMV.js → chunk-WVP4XV5A.js} +6050 -3402
- package/dist/{contributions-DatoAzMx.d.ts → contributions-Hv4_cOJo.d.cts} +152 -5
- package/dist/{contributions-2bEmCF9S.d.cts → contributions-Z12BrWCy.d.ts} +152 -5
- package/dist/index.cjs +2798 -2484
- package/dist/index.d.cts +44 -16
- package/dist/index.d.ts +44 -16
- package/dist/index.js +2 -2
- package/dist/{options-YdiaaVjt.d.cts → options-BaVTMXaO.d.cts} +48 -2
- package/dist/{options-YdiaaVjt.d.ts → options-BaVTMXaO.d.ts} +48 -2
- package/dist/{plugin-Bcone6Vh.d.ts → plugin-9koBjc5H.d.ts} +6 -4
- package/dist/{plugin-DO_DX0gp.d.cts → plugin-BXhDHTYn.d.cts} +6 -4
- package/dist/plugin.cjs +44 -0
- package/dist/plugin.d.cts +4 -4
- package/dist/plugin.d.ts +4 -4
- package/dist/plugin.js +1 -1
- package/dist/providers/binance.cjs +16 -0
- package/dist/providers/binance.d.cts +5 -2
- package/dist/providers/binance.d.ts +5 -2
- package/dist/providers/binance.js +7 -0
- package/dist/providers/coinbase.cjs +16 -0
- package/dist/providers/coinbase.d.cts +5 -2
- package/dist/providers/coinbase.d.ts +5 -2
- package/dist/providers/coinbase.js +7 -0
- package/dist/providers/hyperliquid.cjs +16 -0
- package/dist/providers/hyperliquid.d.cts +5 -2
- package/dist/providers/hyperliquid.d.ts +5 -2
- package/dist/providers/hyperliquid.js +7 -0
- package/dist/ui.d.cts +1 -1
- package/dist/ui.d.ts +1 -1
- package/dist/vela.global.js +2824 -2484
- package/dist/vela.global.min.js +48 -48
- package/dist/widget.cjs +35791 -34070
- package/dist/widget.d.cts +80 -275
- package/dist/widget.d.ts +80 -275
- package/dist/widget.js +61 -1313
- package/dist/workspace.cjs +1700 -995
- package/dist/workspace.d.cts +120 -15
- package/dist/workspace.d.ts +120 -15
- package/dist/workspace.js +7 -2281
- package/package.json +1 -1
package/dist/plugin.cjs
CHANGED
|
@@ -103,6 +103,9 @@ function rendererLayers() {
|
|
|
103
103
|
return [...registry2.values()];
|
|
104
104
|
}
|
|
105
105
|
|
|
106
|
+
// src/widget/topbar-composition.ts
|
|
107
|
+
var TOPBAR_BUILTIN_IDS = ["symbol", "timeframes", "style", "layout", "indicators", "actions", "undo-redo", "alerts", "panels", "screenshot"];
|
|
108
|
+
|
|
106
109
|
// src/widget/contributions.ts
|
|
107
110
|
var registry3 = /* @__PURE__ */ new Map();
|
|
108
111
|
var attachments = /* @__PURE__ */ new Map();
|
|
@@ -132,7 +135,18 @@ function unregisterSidePanel(id) {
|
|
|
132
135
|
function sidePanels() {
|
|
133
136
|
return [...panels.values()].sort((a, b) => (a.order ?? DEFAULT_PANEL_ORDER) - (b.order ?? DEFAULT_PANEL_ORDER));
|
|
134
137
|
}
|
|
138
|
+
var OVERRIDABLE_TOPBAR_IDS = ["indicators", "screenshot"];
|
|
139
|
+
var overridableSet = new Set(OVERRIDABLE_TOPBAR_IDS);
|
|
140
|
+
var builtinTopbarSet = new Set(TOPBAR_BUILTIN_IDS);
|
|
141
|
+
function topbarActionOverride(id) {
|
|
142
|
+
if (!overridableSet.has(id)) return void 0;
|
|
143
|
+
return registry3.get(id);
|
|
144
|
+
}
|
|
135
145
|
function registerWidgetAction(desc) {
|
|
146
|
+
if (builtinTopbarSet.has(desc.id) && !overridableSet.has(desc.id)) {
|
|
147
|
+
console.warn(`[vela] widget action "${desc.id}": this built-in topbar slot is a stateful control and cannot be overridden \u2014 ignored. Overridable slots: ${OVERRIDABLE_TOPBAR_IDS.join(", ")}.`);
|
|
148
|
+
return () => void 0;
|
|
149
|
+
}
|
|
136
150
|
registry3.set(desc.id, desc);
|
|
137
151
|
return () => {
|
|
138
152
|
if (registry3.get(desc.id) === desc) registry3.delete(desc.id);
|
|
@@ -159,6 +173,29 @@ function unregisterLegendAction(id) {
|
|
|
159
173
|
function legendActions() {
|
|
160
174
|
return [...legendRegistry.values()].sort((a, b) => (a.order ?? 0) - (b.order ?? 0));
|
|
161
175
|
}
|
|
176
|
+
var stateHandlers = /* @__PURE__ */ new Map();
|
|
177
|
+
function registerStatePersistence(handler) {
|
|
178
|
+
stateHandlers.set(handler.key, handler);
|
|
179
|
+
return () => {
|
|
180
|
+
if (stateHandlers.get(handler.key) === handler) stateHandlers.delete(handler.key);
|
|
181
|
+
};
|
|
182
|
+
}
|
|
183
|
+
function unregisterStatePersistence(key) {
|
|
184
|
+
stateHandlers.delete(key);
|
|
185
|
+
}
|
|
186
|
+
function statePersistenceHandlers(scope) {
|
|
187
|
+
return [...stateHandlers.values()].filter((h) => h.scope === scope);
|
|
188
|
+
}
|
|
189
|
+
var symbolRankingHook;
|
|
190
|
+
function registerSymbolRanking(hook) {
|
|
191
|
+
symbolRankingHook = hook;
|
|
192
|
+
return () => {
|
|
193
|
+
if (symbolRankingHook === hook) symbolRankingHook = void 0;
|
|
194
|
+
};
|
|
195
|
+
}
|
|
196
|
+
function symbolRanking() {
|
|
197
|
+
return symbolRankingHook;
|
|
198
|
+
}
|
|
162
199
|
var defaultEngines = /* @__PURE__ */ new Map();
|
|
163
200
|
function registerDefaultEngine(language, make) {
|
|
164
201
|
defaultEngines.set(language, make);
|
|
@@ -5977,6 +6014,7 @@ exports.INFO = INFO;
|
|
|
5977
6014
|
exports.INVALID = INVALID;
|
|
5978
6015
|
exports.MARKER = MARKER;
|
|
5979
6016
|
exports.NEUTRAL = NEUTRAL;
|
|
6017
|
+
exports.OVERRIDABLE_TOPBAR_IDS = OVERRIDABLE_TOPBAR_IDS;
|
|
5980
6018
|
exports.SERIES_LINE = SERIES_LINE;
|
|
5981
6019
|
exports.SESSION_OFF = SESSION_OFF;
|
|
5982
6020
|
exports.SESSION_POST = SESSION_POST;
|
|
@@ -6008,6 +6046,8 @@ exports.registerNativeIndicator = registerNativeIndicator;
|
|
|
6008
6046
|
exports.registerRendererDefaults = registerRendererDefaults;
|
|
6009
6047
|
exports.registerRendererLayer = registerRendererLayer;
|
|
6010
6048
|
exports.registerSidePanel = registerSidePanel;
|
|
6049
|
+
exports.registerStatePersistence = registerStatePersistence;
|
|
6050
|
+
exports.registerSymbolRanking = registerSymbolRanking;
|
|
6011
6051
|
exports.registerWidgetAction = registerWidgetAction;
|
|
6012
6052
|
exports.registerWidgetAttachment = registerWidgetAttachment;
|
|
6013
6053
|
exports.rendererDefaults = rendererDefaults;
|
|
@@ -6016,7 +6056,10 @@ exports.resolveEngines = resolveEngines;
|
|
|
6016
6056
|
exports.settingsRowValueKeys = settingsRowValueKeys;
|
|
6017
6057
|
exports.sidePanels = sidePanels;
|
|
6018
6058
|
exports.stableSeriesId = stableSeriesId;
|
|
6059
|
+
exports.statePersistenceHandlers = statePersistenceHandlers;
|
|
6060
|
+
exports.symbolRanking = symbolRanking;
|
|
6019
6061
|
exports.tickerModifierIds = tickerModifierIds;
|
|
6062
|
+
exports.topbarActionOverride = topbarActionOverride;
|
|
6020
6063
|
exports.unregisterChartType = unregisterChartType;
|
|
6021
6064
|
exports.unregisterDefaultEngine = unregisterDefaultEngine;
|
|
6022
6065
|
exports.unregisterLegendAction = unregisterLegendAction;
|
|
@@ -6024,6 +6067,7 @@ exports.unregisterNativeIndicator = unregisterNativeIndicator;
|
|
|
6024
6067
|
exports.unregisterRendererDefaults = unregisterRendererDefaults;
|
|
6025
6068
|
exports.unregisterRendererLayer = unregisterRendererLayer;
|
|
6026
6069
|
exports.unregisterSidePanel = unregisterSidePanel;
|
|
6070
|
+
exports.unregisterStatePersistence = unregisterStatePersistence;
|
|
6027
6071
|
exports.unregisterWidgetAction = unregisterWidgetAction;
|
|
6028
6072
|
exports.unregisterWidgetAttachment = unregisterWidgetAttachment;
|
|
6029
6073
|
exports.widgetActions = widgetActions;
|
package/dist/plugin.d.cts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export { A as ACCENT, a as ACCENT_BRIGHT, B as BEARISH, b as BULLISH, c as BarTransform, d as BasePaintingModulation, C as CATEGORICAL, e as CROSSHAIR, f as ChartTypeDefinition, g as ChartTypeSettingsInstance, h as ChartTypeSettingsSection, i as ChartTypeSettingsSubsection, D as DrawingTypeMeta, H as HIGHLIGHT, I as INFO, j as INVALID, k as IdentifiableKind, M as MARKER, N as NEUTRAL, l as NormalizedSettingsRow, R as RendererLayerArgs, m as RendererLayerDefinition, n as RendererLayerInstance, S as SERIES_LINE, o as SESSION_OFF, p as SESSION_POST, q as SESSION_PRE, r as SLATE, s as SLATE_DEEP, t as SeriesDataEngine, u as SeriesDataEngineHost, v as SettingsInlineControl, w as SettingsRowCondition, x as SettingsRowDescriptor, y as SettingsRowInlineNumber, z as SettingsRowSwatch, E as SettingsRowValueKey, F as SettingsRowWhen, G as SettingsRowWidth, J as SettingsSelectOption, K as SettingsValueRow, T as TRADE_EXIT, L as TRADE_LONG, O as TRADE_SHORT, V as VALID, W as WARNING, P as categoricalColor, Q as chartType, U as chartTypes, Z as drawingTypes, _ as getDrawingType, $ as normalizeSettingsRow, a0 as registerChartType, a2 as registerRendererDefaults, a3 as registerRendererLayer, a4 as rendererDefaults, a5 as rendererLayers, a6 as settingsRowValueKeys, a7 as stableSeriesId, a8 as tickerModifierIds, a9 as unregisterChartType, aa as unregisterRendererDefaults, ab as unregisterRendererLayer } from './plugin-
|
|
2
|
-
export { B as BarsChangeReason, C as ContextSelect,
|
|
1
|
+
export { A as ACCENT, a as ACCENT_BRIGHT, B as BEARISH, b as BULLISH, c as BarTransform, d as BasePaintingModulation, C as CATEGORICAL, e as CROSSHAIR, f as ChartTypeDefinition, g as ChartTypeSettingsInstance, h as ChartTypeSettingsSection, i as ChartTypeSettingsSubsection, D as DrawingTypeMeta, H as HIGHLIGHT, I as INFO, j as INVALID, k as IdentifiableKind, M as MARKER, N as NEUTRAL, l as NormalizedSettingsRow, R as RendererLayerArgs, m as RendererLayerDefinition, n as RendererLayerInstance, S as SERIES_LINE, o as SESSION_OFF, p as SESSION_POST, q as SESSION_PRE, r as SLATE, s as SLATE_DEEP, t as SeriesDataEngine, u as SeriesDataEngineHost, v as SettingsInlineControl, w as SettingsRowCondition, x as SettingsRowDescriptor, y as SettingsRowInlineNumber, z as SettingsRowSwatch, E as SettingsRowValueKey, F as SettingsRowWhen, G as SettingsRowWidth, J as SettingsSelectOption, K as SettingsValueRow, T as TRADE_EXIT, L as TRADE_LONG, O as TRADE_SHORT, V as VALID, W as WARNING, P as categoricalColor, Q as chartType, U as chartTypes, Z as drawingTypes, _ as getDrawingType, $ as normalizeSettingsRow, a0 as registerChartType, a2 as registerRendererDefaults, a3 as registerRendererLayer, a4 as rendererDefaults, a5 as rendererLayers, a6 as settingsRowValueKeys, a7 as stableSeriesId, a8 as tickerModifierIds, a9 as unregisterChartType, aa as unregisterRendererDefaults, ab as unregisterRendererLayer } from './plugin-BXhDHTYn.cjs';
|
|
2
|
+
export { B as BarsChangeReason, C as CellStateContext, b as ContextSelect, e as EngineAlert, f as EngineCapabilities, g as EngineContextSnapshot, h as EngineFactory, i as EngineWarning, j as ExecutionHandlers, k as ExecutionMarket, l as ExecutionRequest, m as ExecutionSession, E as ExternalIndicatorEntry, F as FetchSeries, L as LegendActionDescriptor, p as LegendIndicatorInfo, N as NativeIndicator, q as NativeIndicatorContext, r as NativeIndicatorDescriptor, s as NativeIndicatorInfo, t as NativeIndicatorOutput, O as OVERRIDABLE_TOPBAR_IDS, u as PreparedScript, a as ScriptRun, y as ScriptRunCause, z as ScriptRunResult, S as ScriptingEngine, A as SidePanelButton, G as SidePanelDescriptor, H as SidePanelHandle, J as SidePanelHeader, K as StatePersistenceHandler, M as StrategyFill, Q as StrategyState, T as StrategyTrade, U as SymbolRankingHook, _ as VisibleBarRange, $ as WidgetActionDescriptor, a0 as WidgetActionTarget, a1 as WidgetAttachment, W as WidgetContext, a2 as getNativeIndicator, a3 as legendActions, a5 as nativeIndicatorTypes, a6 as registerDefaultEngine, a7 as registerLegendAction, a8 as registerNativeIndicator, a9 as registerSidePanel, aa as registerStatePersistence, ab as registerSymbolRanking, ac as registerWidgetAction, ad as registerWidgetAttachment, ae as resolveEngines, af as sidePanels, ag as statePersistenceHandlers, ah as symbolRanking, ai as topbarActionOverride, aj as unregisterDefaultEngine, ak as unregisterLegendAction, al as unregisterNativeIndicator, am as unregisterSidePanel, an as unregisterStatePersistence, ao as unregisterWidgetAction, ap as unregisterWidgetAttachment, aq as widgetActions, ar as widgetAttachments } from './contributions-Hv4_cOJo.cjs';
|
|
3
3
|
export { D as DEFAULT_PANEL_MAX_WIDTH, a as DEFAULT_PANEL_MIN_WIDTH, b as DEFAULT_PANEL_WIDTH, S as SidePanelOptions, c as clampPanelWidth } from './side-panel-CT9ZwIGz.cjs';
|
|
4
|
-
export { B as Background, y as BoxFontFamily, z as BoxHAlign, E as BoxTextSize, F as BoxVAlign, G as CandleBarColor, H as CandleSeries, J as CandleStyle, X as DirtyRange, Y as DrawingBox, Z as DrawingExtend, $ as DrawingLabel, a0 as DrawingLine, a1 as DrawingLinefill, a4 as DrawingPolyline, a6 as DrawingTable, v as DrawingTypeKey, a8 as DrawingXLoc, aa as Fill, ab as FillGradientStop, ac as IndicatorMeta, k as IndicatorModel, ad as InputCondition, ae as InputSchema, af as InputType, m as InputValue, ag as InputWhen, ah as LabelStyle, ai as LabelYLoc, aj as LineLikeKind, ak as LineLikeSeries, al as LineLikeStyle, L as LineStyle, am as MarkerPoint, an as MarkerSeries, t as Millis, O as OHLCV, h as Pane, aq as
|
|
4
|
+
export { B as Background, y as BoxFontFamily, z as BoxHAlign, E as BoxTextSize, F as BoxVAlign, G as CandleBarColor, H as CandleSeries, J as CandleStyle, X as DirtyRange, Y as DrawingBox, Z as DrawingExtend, $ as DrawingLabel, a0 as DrawingLine, a1 as DrawingLinefill, a4 as DrawingPolyline, a6 as DrawingTable, v as DrawingTypeKey, a8 as DrawingXLoc, aa as Fill, ab as FillGradientStop, ac as IndicatorMeta, k as IndicatorModel, ad as InputCondition, ae as InputSchema, af as InputType, m as InputValue, ag as InputWhen, ah as LabelStyle, ai as LabelYLoc, aj as LineLikeKind, ak as LineLikeSeries, al as LineLikeStyle, L as LineStyle, am as MarkerPoint, an as MarkerSeries, t as Millis, O as OHLCV, h as Pane, aq as PaneAxis, ar as PaneAxisBand, as as PaneHint, at as PaneKind, au as PolylinePoint, av as PriceLine, P as PriceStyle, az as Scene, l as ScenePatch, aA as SchemaPatch, aB as SeriesKind, aC as SeriesPoint, aD as SeriesSpec, aE as SeriesValueDelta, aI as TableCell, aJ as TableMerge, aK as TablePosition, aM as TradeExecution, aN as ValuePatch, aQ as inputVisible } from './options-BaVTMXaO.cjs';
|
|
5
5
|
export { i as iconMarkup, r as registerIcon } from './icons-BZYbJXSV.cjs';
|
|
6
6
|
export { a as KeyBindingDescriptor, R as ResolvedBinding } from './keymap-CGOz5F5f.cjs';
|
|
7
|
-
export { B as BarRange, D as DataProvider, M as MarketDataFeed, b as ProviderCapabilities, P as ProviderInfo, a as SymbolDescriptor, S as SymbolInfo } from './DataProvider-
|
|
7
|
+
export { B as BarRange, D as DataProvider, M as MarketDataFeed, b as ProviderCapabilities, P as ProviderInfo, a as SymbolDescriptor, S as SymbolInfo } from './DataProvider-BsQM2WNH.cjs';
|
package/dist/plugin.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export { A as ACCENT, a as ACCENT_BRIGHT, B as BEARISH, b as BULLISH, c as BarTransform, d as BasePaintingModulation, C as CATEGORICAL, e as CROSSHAIR, f as ChartTypeDefinition, g as ChartTypeSettingsInstance, h as ChartTypeSettingsSection, i as ChartTypeSettingsSubsection, D as DrawingTypeMeta, H as HIGHLIGHT, I as INFO, j as INVALID, k as IdentifiableKind, M as MARKER, N as NEUTRAL, l as NormalizedSettingsRow, R as RendererLayerArgs, m as RendererLayerDefinition, n as RendererLayerInstance, S as SERIES_LINE, o as SESSION_OFF, p as SESSION_POST, q as SESSION_PRE, r as SLATE, s as SLATE_DEEP, t as SeriesDataEngine, u as SeriesDataEngineHost, v as SettingsInlineControl, w as SettingsRowCondition, x as SettingsRowDescriptor, y as SettingsRowInlineNumber, z as SettingsRowSwatch, E as SettingsRowValueKey, F as SettingsRowWhen, G as SettingsRowWidth, J as SettingsSelectOption, K as SettingsValueRow, T as TRADE_EXIT, L as TRADE_LONG, O as TRADE_SHORT, V as VALID, W as WARNING, P as categoricalColor, Q as chartType, U as chartTypes, Z as drawingTypes, _ as getDrawingType, $ as normalizeSettingsRow, a0 as registerChartType, a2 as registerRendererDefaults, a3 as registerRendererLayer, a4 as rendererDefaults, a5 as rendererLayers, a6 as settingsRowValueKeys, a7 as stableSeriesId, a8 as tickerModifierIds, a9 as unregisterChartType, aa as unregisterRendererDefaults, ab as unregisterRendererLayer } from './plugin-
|
|
2
|
-
export { B as BarsChangeReason, C as ContextSelect,
|
|
1
|
+
export { A as ACCENT, a as ACCENT_BRIGHT, B as BEARISH, b as BULLISH, c as BarTransform, d as BasePaintingModulation, C as CATEGORICAL, e as CROSSHAIR, f as ChartTypeDefinition, g as ChartTypeSettingsInstance, h as ChartTypeSettingsSection, i as ChartTypeSettingsSubsection, D as DrawingTypeMeta, H as HIGHLIGHT, I as INFO, j as INVALID, k as IdentifiableKind, M as MARKER, N as NEUTRAL, l as NormalizedSettingsRow, R as RendererLayerArgs, m as RendererLayerDefinition, n as RendererLayerInstance, S as SERIES_LINE, o as SESSION_OFF, p as SESSION_POST, q as SESSION_PRE, r as SLATE, s as SLATE_DEEP, t as SeriesDataEngine, u as SeriesDataEngineHost, v as SettingsInlineControl, w as SettingsRowCondition, x as SettingsRowDescriptor, y as SettingsRowInlineNumber, z as SettingsRowSwatch, E as SettingsRowValueKey, F as SettingsRowWhen, G as SettingsRowWidth, J as SettingsSelectOption, K as SettingsValueRow, T as TRADE_EXIT, L as TRADE_LONG, O as TRADE_SHORT, V as VALID, W as WARNING, P as categoricalColor, Q as chartType, U as chartTypes, Z as drawingTypes, _ as getDrawingType, $ as normalizeSettingsRow, a0 as registerChartType, a2 as registerRendererDefaults, a3 as registerRendererLayer, a4 as rendererDefaults, a5 as rendererLayers, a6 as settingsRowValueKeys, a7 as stableSeriesId, a8 as tickerModifierIds, a9 as unregisterChartType, aa as unregisterRendererDefaults, ab as unregisterRendererLayer } from './plugin-9koBjc5H.js';
|
|
2
|
+
export { B as BarsChangeReason, C as CellStateContext, b as ContextSelect, e as EngineAlert, f as EngineCapabilities, g as EngineContextSnapshot, h as EngineFactory, i as EngineWarning, j as ExecutionHandlers, k as ExecutionMarket, l as ExecutionRequest, m as ExecutionSession, E as ExternalIndicatorEntry, F as FetchSeries, L as LegendActionDescriptor, p as LegendIndicatorInfo, N as NativeIndicator, q as NativeIndicatorContext, r as NativeIndicatorDescriptor, s as NativeIndicatorInfo, t as NativeIndicatorOutput, O as OVERRIDABLE_TOPBAR_IDS, u as PreparedScript, a as ScriptRun, y as ScriptRunCause, z as ScriptRunResult, S as ScriptingEngine, A as SidePanelButton, G as SidePanelDescriptor, H as SidePanelHandle, J as SidePanelHeader, K as StatePersistenceHandler, M as StrategyFill, Q as StrategyState, T as StrategyTrade, U as SymbolRankingHook, _ as VisibleBarRange, $ as WidgetActionDescriptor, a0 as WidgetActionTarget, a1 as WidgetAttachment, W as WidgetContext, a2 as getNativeIndicator, a3 as legendActions, a5 as nativeIndicatorTypes, a6 as registerDefaultEngine, a7 as registerLegendAction, a8 as registerNativeIndicator, a9 as registerSidePanel, aa as registerStatePersistence, ab as registerSymbolRanking, ac as registerWidgetAction, ad as registerWidgetAttachment, ae as resolveEngines, af as sidePanels, ag as statePersistenceHandlers, ah as symbolRanking, ai as topbarActionOverride, aj as unregisterDefaultEngine, ak as unregisterLegendAction, al as unregisterNativeIndicator, am as unregisterSidePanel, an as unregisterStatePersistence, ao as unregisterWidgetAction, ap as unregisterWidgetAttachment, aq as widgetActions, ar as widgetAttachments } from './contributions-Z12BrWCy.js';
|
|
3
3
|
export { D as DEFAULT_PANEL_MAX_WIDTH, a as DEFAULT_PANEL_MIN_WIDTH, b as DEFAULT_PANEL_WIDTH, S as SidePanelOptions, c as clampPanelWidth } from './side-panel-CT9ZwIGz.js';
|
|
4
|
-
export { B as Background, y as BoxFontFamily, z as BoxHAlign, E as BoxTextSize, F as BoxVAlign, G as CandleBarColor, H as CandleSeries, J as CandleStyle, X as DirtyRange, Y as DrawingBox, Z as DrawingExtend, $ as DrawingLabel, a0 as DrawingLine, a1 as DrawingLinefill, a4 as DrawingPolyline, a6 as DrawingTable, v as DrawingTypeKey, a8 as DrawingXLoc, aa as Fill, ab as FillGradientStop, ac as IndicatorMeta, k as IndicatorModel, ad as InputCondition, ae as InputSchema, af as InputType, m as InputValue, ag as InputWhen, ah as LabelStyle, ai as LabelYLoc, aj as LineLikeKind, ak as LineLikeSeries, al as LineLikeStyle, L as LineStyle, am as MarkerPoint, an as MarkerSeries, t as Millis, O as OHLCV, h as Pane, aq as
|
|
4
|
+
export { B as Background, y as BoxFontFamily, z as BoxHAlign, E as BoxTextSize, F as BoxVAlign, G as CandleBarColor, H as CandleSeries, J as CandleStyle, X as DirtyRange, Y as DrawingBox, Z as DrawingExtend, $ as DrawingLabel, a0 as DrawingLine, a1 as DrawingLinefill, a4 as DrawingPolyline, a6 as DrawingTable, v as DrawingTypeKey, a8 as DrawingXLoc, aa as Fill, ab as FillGradientStop, ac as IndicatorMeta, k as IndicatorModel, ad as InputCondition, ae as InputSchema, af as InputType, m as InputValue, ag as InputWhen, ah as LabelStyle, ai as LabelYLoc, aj as LineLikeKind, ak as LineLikeSeries, al as LineLikeStyle, L as LineStyle, am as MarkerPoint, an as MarkerSeries, t as Millis, O as OHLCV, h as Pane, aq as PaneAxis, ar as PaneAxisBand, as as PaneHint, at as PaneKind, au as PolylinePoint, av as PriceLine, P as PriceStyle, az as Scene, l as ScenePatch, aA as SchemaPatch, aB as SeriesKind, aC as SeriesPoint, aD as SeriesSpec, aE as SeriesValueDelta, aI as TableCell, aJ as TableMerge, aK as TablePosition, aM as TradeExecution, aN as ValuePatch, aQ as inputVisible } from './options-BaVTMXaO.js';
|
|
5
5
|
export { i as iconMarkup, r as registerIcon } from './icons-BZYbJXSV.js';
|
|
6
6
|
export { a as KeyBindingDescriptor, R as ResolvedBinding } from './keymap-CGOz5F5f.js';
|
|
7
|
-
export { B as BarRange, D as DataProvider, M as MarketDataFeed, b as ProviderCapabilities, P as ProviderInfo, a as SymbolDescriptor, S as SymbolInfo } from './DataProvider-
|
|
7
|
+
export { B as BarRange, D as DataProvider, M as MarketDataFeed, b as ProviderCapabilities, P as ProviderInfo, a as SymbolDescriptor, S as SymbolInfo } from './DataProvider-BSLlBpB9.js';
|
package/dist/plugin.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
export { stableSeriesId } from './chunk-AOGZBKUE.js';
|
|
2
|
-
export { DEFAULT_PANEL_MAX_WIDTH, DEFAULT_PANEL_MIN_WIDTH, DEFAULT_PANEL_WIDTH, chartType, chartTypes, clampPanelWidth, drawingTypes, getDrawingType, getNativeIndicator, inputVisible, legendActions, nativeIndicatorTypes, normalizeSettingsRow, registerChartType, registerDefaultEngine, registerLegendAction, registerNativeIndicator, registerRendererDefaults, registerRendererLayer, registerSidePanel, registerWidgetAction, registerWidgetAttachment, rendererDefaults, rendererLayers, resolveEngines, settingsRowValueKeys, sidePanels, tickerModifierIds, unregisterChartType, unregisterDefaultEngine, unregisterLegendAction, unregisterNativeIndicator, unregisterRendererDefaults, unregisterRendererLayer, unregisterSidePanel, unregisterWidgetAction, unregisterWidgetAttachment, widgetActions, widgetAttachments } from './chunk-
|
|
2
|
+
export { DEFAULT_PANEL_MAX_WIDTH, DEFAULT_PANEL_MIN_WIDTH, DEFAULT_PANEL_WIDTH, OVERRIDABLE_TOPBAR_IDS, chartType, chartTypes, clampPanelWidth, drawingTypes, getDrawingType, getNativeIndicator, inputVisible, legendActions, nativeIndicatorTypes, normalizeSettingsRow, registerChartType, registerDefaultEngine, registerLegendAction, registerNativeIndicator, registerRendererDefaults, registerRendererLayer, registerSidePanel, registerStatePersistence, registerSymbolRanking, registerWidgetAction, registerWidgetAttachment, rendererDefaults, rendererLayers, resolveEngines, settingsRowValueKeys, sidePanels, statePersistenceHandlers, symbolRanking, tickerModifierIds, topbarActionOverride, unregisterChartType, unregisterDefaultEngine, unregisterLegendAction, unregisterNativeIndicator, unregisterRendererDefaults, unregisterRendererLayer, unregisterSidePanel, unregisterStatePersistence, unregisterWidgetAction, unregisterWidgetAttachment, widgetActions, widgetAttachments } from './chunk-L3I2CCYO.js';
|
|
3
3
|
export { ACCENT, ACCENT_BRIGHT, BEARISH, BULLISH, CATEGORICAL, CROSSHAIR, HIGHLIGHT, INFO, INVALID, MARKER, NEUTRAL, SERIES_LINE, SESSION_OFF, SESSION_POST, SESSION_PRE, SLATE, SLATE_DEEP, TRADE_EXIT, TRADE_LONG, TRADE_SHORT, VALID, WARNING, categoricalColor, iconMarkup, registerIcon } from './chunk-PN5KWFZ4.js';
|
|
@@ -1,5 +1,16 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
+
// src/data/symbol-base.ts
|
|
4
|
+
function baseOf(d) {
|
|
5
|
+
const fromDesc = d.description?.split("/")[0]?.trim();
|
|
6
|
+
if (fromDesc) return fromDesc.replace(/\s+Perpetual$/i, "");
|
|
7
|
+
return d.ticker.replace(/[-_/]?(USDT|USDC|USD1|USDS|BUSD|USD|EUR|PERP)$/i, "") || d.ticker;
|
|
8
|
+
}
|
|
9
|
+
function ledgerCryptoIconUrl(base) {
|
|
10
|
+
const key = base.trim().toUpperCase();
|
|
11
|
+
return key ? `https://crypto-icons.ledger.com/${encodeURIComponent(key)}.png` : void 0;
|
|
12
|
+
}
|
|
13
|
+
|
|
3
14
|
// src/data/providers/binance/BinanceProvider.ts
|
|
4
15
|
var SPOT_BASE = "https://api.binance.com/api/v3";
|
|
5
16
|
var SPOT_BASE_US = "https://api.binance.us/api/v3";
|
|
@@ -186,6 +197,11 @@ var BinanceProvider = class {
|
|
|
186
197
|
}
|
|
187
198
|
return this.symbolsPromise;
|
|
188
199
|
}
|
|
200
|
+
/** Predefined icon source for a crypto venue: the Ledger crypto-icon CDN, keyed by
|
|
201
|
+
* the BASE asset (the description's first segment, else the de-suffixed ticker). */
|
|
202
|
+
resolveSymbolIcon(symbol) {
|
|
203
|
+
return ledgerCryptoIconUrl(baseOf(symbol));
|
|
204
|
+
}
|
|
189
205
|
subscribe(ticker, timeframe, onBar) {
|
|
190
206
|
const { apiSymbol, isFutures } = parseTicker(ticker);
|
|
191
207
|
const interval = TF_TO_INTERVAL[normalizeTf(timeframe)];
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { O as OHLCV, U as Unsubscribe } from '../options-
|
|
2
|
-
import { D as DataProvider, P as ProviderInfo, B as BarRange, S as SymbolInfo, a as SymbolDescriptor } from '../DataProvider-
|
|
1
|
+
import { O as OHLCV, U as Unsubscribe } from '../options-BaVTMXaO.cjs';
|
|
2
|
+
import { D as DataProvider, P as ProviderInfo, B as BarRange, S as SymbolInfo, a as SymbolDescriptor } from '../DataProvider-BsQM2WNH.cjs';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Binance market-data provider, built from scratch on the public REST + WebSocket
|
|
@@ -23,6 +23,9 @@ declare class BinanceProvider implements DataProvider {
|
|
|
23
23
|
getBars(ticker: string, timeframe: string, range: BarRange): Promise<OHLCV[]>;
|
|
24
24
|
getSymbolInfo(ticker: string): Promise<SymbolInfo | undefined>;
|
|
25
25
|
listSymbols(): Promise<SymbolDescriptor[]>;
|
|
26
|
+
/** Predefined icon source for a crypto venue: the Ledger crypto-icon CDN, keyed by
|
|
27
|
+
* the BASE asset (the description's first segment, else the de-suffixed ticker). */
|
|
28
|
+
resolveSymbolIcon(symbol: SymbolDescriptor): string | undefined;
|
|
26
29
|
subscribe(ticker: string, timeframe: string, onBar: (bar: OHLCV) => void): Unsubscribe;
|
|
27
30
|
/**
|
|
28
31
|
* Open a Binance kline WebSocket (single-stream URL form — the stream is in the
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { O as OHLCV, U as Unsubscribe } from '../options-
|
|
2
|
-
import { D as DataProvider, P as ProviderInfo, B as BarRange, S as SymbolInfo, a as SymbolDescriptor } from '../DataProvider-
|
|
1
|
+
import { O as OHLCV, U as Unsubscribe } from '../options-BaVTMXaO.js';
|
|
2
|
+
import { D as DataProvider, P as ProviderInfo, B as BarRange, S as SymbolInfo, a as SymbolDescriptor } from '../DataProvider-BSLlBpB9.js';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Binance market-data provider, built from scratch on the public REST + WebSocket
|
|
@@ -23,6 +23,9 @@ declare class BinanceProvider implements DataProvider {
|
|
|
23
23
|
getBars(ticker: string, timeframe: string, range: BarRange): Promise<OHLCV[]>;
|
|
24
24
|
getSymbolInfo(ticker: string): Promise<SymbolInfo | undefined>;
|
|
25
25
|
listSymbols(): Promise<SymbolDescriptor[]>;
|
|
26
|
+
/** Predefined icon source for a crypto venue: the Ledger crypto-icon CDN, keyed by
|
|
27
|
+
* the BASE asset (the description's first segment, else the de-suffixed ticker). */
|
|
28
|
+
resolveSymbolIcon(symbol: SymbolDescriptor): string | undefined;
|
|
26
29
|
subscribe(ticker: string, timeframe: string, onBar: (bar: OHLCV) => void): Unsubscribe;
|
|
27
30
|
/**
|
|
28
31
|
* Open a Binance kline WebSocket (single-stream URL form — the stream is in the
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import { ledgerCryptoIconUrl, baseOf } from '../chunk-W4EJWLEO.js';
|
|
2
|
+
|
|
1
3
|
// src/data/providers/binance/BinanceProvider.ts
|
|
2
4
|
var SPOT_BASE = "https://api.binance.com/api/v3";
|
|
3
5
|
var SPOT_BASE_US = "https://api.binance.us/api/v3";
|
|
@@ -184,6 +186,11 @@ var BinanceProvider = class {
|
|
|
184
186
|
}
|
|
185
187
|
return this.symbolsPromise;
|
|
186
188
|
}
|
|
189
|
+
/** Predefined icon source for a crypto venue: the Ledger crypto-icon CDN, keyed by
|
|
190
|
+
* the BASE asset (the description's first segment, else the de-suffixed ticker). */
|
|
191
|
+
resolveSymbolIcon(symbol) {
|
|
192
|
+
return ledgerCryptoIconUrl(baseOf(symbol));
|
|
193
|
+
}
|
|
187
194
|
subscribe(ticker, timeframe, onBar) {
|
|
188
195
|
const { apiSymbol, isFutures } = parseTicker(ticker);
|
|
189
196
|
const interval = TF_TO_INTERVAL[normalizeTf(timeframe)];
|
|
@@ -1,5 +1,16 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
+
// src/data/symbol-base.ts
|
|
4
|
+
function baseOf(d) {
|
|
5
|
+
const fromDesc = d.description?.split("/")[0]?.trim();
|
|
6
|
+
if (fromDesc) return fromDesc.replace(/\s+Perpetual$/i, "");
|
|
7
|
+
return d.ticker.replace(/[-_/]?(USDT|USDC|USD1|USDS|BUSD|USD|EUR|PERP)$/i, "") || d.ticker;
|
|
8
|
+
}
|
|
9
|
+
function ledgerCryptoIconUrl(base) {
|
|
10
|
+
const key = base.trim().toUpperCase();
|
|
11
|
+
return key ? `https://crypto-icons.ledger.com/${encodeURIComponent(key)}.png` : void 0;
|
|
12
|
+
}
|
|
13
|
+
|
|
3
14
|
// src/data/providers/coinbase/RequestGate.ts
|
|
4
15
|
var REAL_CLOCK = {
|
|
5
16
|
now: () => Date.now(),
|
|
@@ -234,6 +245,11 @@ var CoinbaseProvider = class {
|
|
|
234
245
|
}
|
|
235
246
|
return this.symbolsPromise;
|
|
236
247
|
}
|
|
248
|
+
/** Predefined icon source for a crypto venue: the Ledger crypto-icon CDN, keyed by
|
|
249
|
+
* the BASE asset (the description's first segment, else the de-suffixed ticker). */
|
|
250
|
+
resolveSymbolIcon(symbol) {
|
|
251
|
+
return ledgerCryptoIconUrl(baseOf(symbol));
|
|
252
|
+
}
|
|
237
253
|
subscribe(ticker, timeframe, onBar) {
|
|
238
254
|
const gran = TF_TO_GRAN[normalizeTf(timeframe)];
|
|
239
255
|
if (gran && typeof WebSocket !== "undefined") return this.streamTicker(ticker, timeframe, gran, onBar);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { O as OHLCV, U as Unsubscribe } from '../options-
|
|
2
|
-
import { D as DataProvider, P as ProviderInfo, B as BarRange, S as SymbolInfo, a as SymbolDescriptor } from '../DataProvider-
|
|
1
|
+
import { O as OHLCV, U as Unsubscribe } from '../options-BaVTMXaO.cjs';
|
|
2
|
+
import { D as DataProvider, P as ProviderInfo, B as BarRange, S as SymbolInfo, a as SymbolDescriptor } from '../DataProvider-BsQM2WNH.cjs';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Coinbase market-data provider, built from scratch on the public Exchange REST + WebSocket APIs
|
|
@@ -24,6 +24,9 @@ declare class CoinbaseProvider implements DataProvider {
|
|
|
24
24
|
getBars(ticker: string, timeframe: string, range: BarRange): Promise<OHLCV[]>;
|
|
25
25
|
getSymbolInfo(ticker: string): Promise<SymbolInfo | undefined>;
|
|
26
26
|
listSymbols(): Promise<SymbolDescriptor[]>;
|
|
27
|
+
/** Predefined icon source for a crypto venue: the Ledger crypto-icon CDN, keyed by
|
|
28
|
+
* the BASE asset (the description's first segment, else the de-suffixed ticker). */
|
|
29
|
+
resolveSymbolIcon(symbol: SymbolDescriptor): string | undefined;
|
|
27
30
|
subscribe(ticker: string, timeframe: string, onBar: (bar: OHLCV) => void): Unsubscribe;
|
|
28
31
|
private fetchProducts;
|
|
29
32
|
/**
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { O as OHLCV, U as Unsubscribe } from '../options-
|
|
2
|
-
import { D as DataProvider, P as ProviderInfo, B as BarRange, S as SymbolInfo, a as SymbolDescriptor } from '../DataProvider-
|
|
1
|
+
import { O as OHLCV, U as Unsubscribe } from '../options-BaVTMXaO.js';
|
|
2
|
+
import { D as DataProvider, P as ProviderInfo, B as BarRange, S as SymbolInfo, a as SymbolDescriptor } from '../DataProvider-BSLlBpB9.js';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Coinbase market-data provider, built from scratch on the public Exchange REST + WebSocket APIs
|
|
@@ -24,6 +24,9 @@ declare class CoinbaseProvider implements DataProvider {
|
|
|
24
24
|
getBars(ticker: string, timeframe: string, range: BarRange): Promise<OHLCV[]>;
|
|
25
25
|
getSymbolInfo(ticker: string): Promise<SymbolInfo | undefined>;
|
|
26
26
|
listSymbols(): Promise<SymbolDescriptor[]>;
|
|
27
|
+
/** Predefined icon source for a crypto venue: the Ledger crypto-icon CDN, keyed by
|
|
28
|
+
* the BASE asset (the description's first segment, else the de-suffixed ticker). */
|
|
29
|
+
resolveSymbolIcon(symbol: SymbolDescriptor): string | undefined;
|
|
27
30
|
subscribe(ticker: string, timeframe: string, onBar: (bar: OHLCV) => void): Unsubscribe;
|
|
28
31
|
private fetchProducts;
|
|
29
32
|
/**
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import { ledgerCryptoIconUrl, baseOf } from '../chunk-W4EJWLEO.js';
|
|
2
|
+
|
|
1
3
|
// src/data/providers/coinbase/RequestGate.ts
|
|
2
4
|
var REAL_CLOCK = {
|
|
3
5
|
now: () => Date.now(),
|
|
@@ -232,6 +234,11 @@ var CoinbaseProvider = class {
|
|
|
232
234
|
}
|
|
233
235
|
return this.symbolsPromise;
|
|
234
236
|
}
|
|
237
|
+
/** Predefined icon source for a crypto venue: the Ledger crypto-icon CDN, keyed by
|
|
238
|
+
* the BASE asset (the description's first segment, else the de-suffixed ticker). */
|
|
239
|
+
resolveSymbolIcon(symbol) {
|
|
240
|
+
return ledgerCryptoIconUrl(baseOf(symbol));
|
|
241
|
+
}
|
|
235
242
|
subscribe(ticker, timeframe, onBar) {
|
|
236
243
|
const gran = TF_TO_GRAN[normalizeTf(timeframe)];
|
|
237
244
|
if (gran && typeof WebSocket !== "undefined") return this.streamTicker(ticker, timeframe, gran, onBar);
|
|
@@ -1,5 +1,16 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
+
// src/data/symbol-base.ts
|
|
4
|
+
function baseOf(d) {
|
|
5
|
+
const fromDesc = d.description?.split("/")[0]?.trim();
|
|
6
|
+
if (fromDesc) return fromDesc.replace(/\s+Perpetual$/i, "");
|
|
7
|
+
return d.ticker.replace(/[-_/]?(USDT|USDC|USD1|USDS|BUSD|USD|EUR|PERP)$/i, "") || d.ticker;
|
|
8
|
+
}
|
|
9
|
+
function ledgerCryptoIconUrl(base) {
|
|
10
|
+
const key = base.trim().toUpperCase();
|
|
11
|
+
return key ? `https://crypto-icons.ledger.com/${encodeURIComponent(key)}.png` : void 0;
|
|
12
|
+
}
|
|
13
|
+
|
|
3
14
|
// src/data/providers/hyperliquid/HyperliquidProvider.ts
|
|
4
15
|
var INFO_URL = "https://api.hyperliquid.xyz/info";
|
|
5
16
|
var WS_URL = "wss://api.hyperliquid.xyz/ws";
|
|
@@ -172,6 +183,11 @@ var HyperliquidProvider = class {
|
|
|
172
183
|
}
|
|
173
184
|
return this.symbolsPromise;
|
|
174
185
|
}
|
|
186
|
+
/** Predefined icon source for a crypto venue: the Ledger crypto-icon CDN, keyed by
|
|
187
|
+
* the BASE asset (the description's first segment, else the de-suffixed ticker). */
|
|
188
|
+
resolveSymbolIcon(symbol) {
|
|
189
|
+
return ledgerCryptoIconUrl(baseOf(symbol));
|
|
190
|
+
}
|
|
175
191
|
subscribe(ticker, timeframe, onBar) {
|
|
176
192
|
const coin = parseCoin(ticker);
|
|
177
193
|
const interval = TF_TO_INTERVAL[normalizeTf(timeframe)];
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { O as OHLCV, U as Unsubscribe } from '../options-
|
|
2
|
-
import { D as DataProvider, P as ProviderInfo, B as BarRange, S as SymbolInfo, a as SymbolDescriptor } from '../DataProvider-
|
|
1
|
+
import { O as OHLCV, U as Unsubscribe } from '../options-BaVTMXaO.cjs';
|
|
2
|
+
import { D as DataProvider, P as ProviderInfo, B as BarRange, S as SymbolInfo, a as SymbolDescriptor } from '../DataProvider-BsQM2WNH.cjs';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Hyperliquid market-data provider, built from scratch on the public info API — no
|
|
@@ -26,6 +26,9 @@ declare class HyperliquidProvider implements DataProvider {
|
|
|
26
26
|
getBars(ticker: string, timeframe: string, range: BarRange): Promise<OHLCV[]>;
|
|
27
27
|
getSymbolInfo(ticker: string): Promise<SymbolInfo | undefined>;
|
|
28
28
|
listSymbols(): Promise<SymbolDescriptor[]>;
|
|
29
|
+
/** Predefined icon source for a crypto venue: the Ledger crypto-icon CDN, keyed by
|
|
30
|
+
* the BASE asset (the description's first segment, else the de-suffixed ticker). */
|
|
31
|
+
resolveSymbolIcon(symbol: SymbolDescriptor): string | undefined;
|
|
29
32
|
subscribe(ticker: string, timeframe: string, onBar: (bar: OHLCV) => void): Unsubscribe;
|
|
30
33
|
private listPerps;
|
|
31
34
|
private listSpot;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { O as OHLCV, U as Unsubscribe } from '../options-
|
|
2
|
-
import { D as DataProvider, P as ProviderInfo, B as BarRange, S as SymbolInfo, a as SymbolDescriptor } from '../DataProvider-
|
|
1
|
+
import { O as OHLCV, U as Unsubscribe } from '../options-BaVTMXaO.js';
|
|
2
|
+
import { D as DataProvider, P as ProviderInfo, B as BarRange, S as SymbolInfo, a as SymbolDescriptor } from '../DataProvider-BSLlBpB9.js';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Hyperliquid market-data provider, built from scratch on the public info API — no
|
|
@@ -26,6 +26,9 @@ declare class HyperliquidProvider implements DataProvider {
|
|
|
26
26
|
getBars(ticker: string, timeframe: string, range: BarRange): Promise<OHLCV[]>;
|
|
27
27
|
getSymbolInfo(ticker: string): Promise<SymbolInfo | undefined>;
|
|
28
28
|
listSymbols(): Promise<SymbolDescriptor[]>;
|
|
29
|
+
/** Predefined icon source for a crypto venue: the Ledger crypto-icon CDN, keyed by
|
|
30
|
+
* the BASE asset (the description's first segment, else the de-suffixed ticker). */
|
|
31
|
+
resolveSymbolIcon(symbol: SymbolDescriptor): string | undefined;
|
|
29
32
|
subscribe(ticker: string, timeframe: string, onBar: (bar: OHLCV) => void): Unsubscribe;
|
|
30
33
|
private listPerps;
|
|
31
34
|
private listSpot;
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import { ledgerCryptoIconUrl, baseOf } from '../chunk-W4EJWLEO.js';
|
|
2
|
+
|
|
1
3
|
// src/data/providers/hyperliquid/HyperliquidProvider.ts
|
|
2
4
|
var INFO_URL = "https://api.hyperliquid.xyz/info";
|
|
3
5
|
var WS_URL = "wss://api.hyperliquid.xyz/ws";
|
|
@@ -170,6 +172,11 @@ var HyperliquidProvider = class {
|
|
|
170
172
|
}
|
|
171
173
|
return this.symbolsPromise;
|
|
172
174
|
}
|
|
175
|
+
/** Predefined icon source for a crypto venue: the Ledger crypto-icon CDN, keyed by
|
|
176
|
+
* the BASE asset (the description's first segment, else the de-suffixed ticker). */
|
|
177
|
+
resolveSymbolIcon(symbol) {
|
|
178
|
+
return ledgerCryptoIconUrl(baseOf(symbol));
|
|
179
|
+
}
|
|
173
180
|
subscribe(ticker, timeframe, onBar) {
|
|
174
181
|
const coin = parseCoin(ticker);
|
|
175
182
|
const interval = TF_TO_INTERVAL[normalizeTf(timeframe)];
|
package/dist/ui.d.cts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { c as VelaTheme } from './options-
|
|
1
|
+
import { c as VelaTheme } from './options-BaVTMXaO.cjs';
|
|
2
2
|
import { MachineSchema, Service, Machine } from '@zag-js/core';
|
|
3
3
|
export { a as KeyBindingDescriptor, K as KeymapManager, b as KeymapOptions, R as ResolvedBinding } from './keymap-CGOz5F5f.cjs';
|
|
4
4
|
import * as tooltip from '@zag-js/tooltip';
|
package/dist/ui.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { c as VelaTheme } from './options-
|
|
1
|
+
import { c as VelaTheme } from './options-BaVTMXaO.js';
|
|
2
2
|
import { MachineSchema, Service, Machine } from '@zag-js/core';
|
|
3
3
|
export { a as KeyBindingDescriptor, K as KeymapManager, b as KeymapOptions, R as ResolvedBinding } from './keymap-CGOz5F5f.js';
|
|
4
4
|
import * as tooltip from '@zag-js/tooltip';
|