added coin API WS implementation

This commit is contained in:
Dobromir Popov
2025-08-08 01:00:38 +03:00
parent bd15bdc87d
commit ba532327b6
5 changed files with 165 additions and 8 deletions

View File

@ -377,8 +377,21 @@ class DashboardComponentManager:
overview_panel
])
# --- Right Panel: Compact Ladder ---
# --- Right Panel: Compact Ladder with optional exchange stats ---
exchange_stats = (update_info or {}).get('exchanges') if isinstance(update_info, dict) else None
ladder_panel = self._create_cob_ladder_panel(bids, asks, mid_price, symbol)
if exchange_stats:
# Render a tiny exchange contribution summary above ladder
try:
rows = []
for ex, stats_ex in exchange_stats.items():
rows.append(html.Small(f"{ex}: {stats_ex.get('bids',0)}/{stats_ex.get('asks',0)}", className="text-muted me-2"))
ladder_panel = html.Div([
html.Div(rows, className="mb-1"),
ladder_panel
])
except Exception:
pass
# Append small extras line from aggregated_1s and recent_ticks
extras = []
if update_info: