Repository navigation
Clean up the Hyperliquid panes: book ladder, ticket, board and states - #2
Merged
Merged
Conversation
Fixed-decimal abbreviations, signed amounts, tick-aware price differences, funding rates in four decimals, lot-size decimals, a fixed-width funding countdown and book tick labels named by price step. Values that round to zero read as zero and stay uncoloured.
Loading and failure use the kit states, figures get one naming scheme, PnL and payments are signed, fees read in four decimals, sides are coloured, dated tabs list newest first and footers stop claiming a connection that is not happening.
The book is a ladder with one mid and spread row, a single cumulative depth bar in theme colours and a cursor only while it has the keyboard. Resting orders draw as muted lines behind the candles, the info tab fits its labels in two columns, and the chart and positions strip show loading instead of a lone candle or a connect prompt.
One-row leverage slider instead of a slider plus a duplicate field, the size unit beside the size, prices and sizes in market precision, unset TP/SL shown as empty, and estimates and the builder fee line visible without scrolling.
Price, change, funding and depth come first, venue and class last, the market column stays put while scrolling, favorites keep names aligned, empty tabs say what is missing and the class option picks the initial tab.
Retry appears only where it can help, footers no longer print internal state names, and predicted funding loads instead of claiming none, with venue names and a normalised 8h rate.
The network bar sits in the header zone with the settings selectors, buttons take their own width, settings read in their units and the body keeps one row of spacing between sections.
Exchange ids such as marginCanceled read as Margin canceled.
Order and TWAP ids lose their thousands separators so they fit and can be searched, and the approval port setting reads Wallet port so the terminal form does not cut it off.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
UI cleanup and review pass for the Hyperliquid plugin (GLO-217). Presentation only: every change is in
src/ui/*. Trading, signing, risk, order building, market and account data, storage, builder fee and region gating are untouched.Why
After the build, the panes worked but read like a first draft: resting orders buried the chart, the book had no spread row and an always-highlighted first ask, the ticket showed leverage and size unit twice, numbers had ragged decimals and red
-0.00%, loading states looked like empty states (which also made screenshots capture too early), and several labels were truncated or repeated.Changes
format.ts): fixed-decimal abbreviations, signed amounts, rounding-aware percentages and colours, tick-aware price differences, funding in four decimals, lot-size decimals, fixed-width funding countdown.Volume BTClegend, clearer header figures, two-column Info tab without truncation, single-candle flash shown as loading, positions strip with loading state and the current market first.1,2,5,10),Total USDin the full book, loading state instead of "Waiting".Buy/Sell, whole-dollar values, numeric export values.--, estimates and the builder-fee disclosure visible without scrolling, average fill and slippage only for market orders, content-width buttons.24/7on every row, aligned favourites,--classhonoured.8h, normalisedRate /8h.50 bp,10,000 USD,Random), inline address label, trimmed Advanced copy, deduplicated footer.connectingwhen nothing connects.Margin canceled), plain order ids.Before/after screenshots for every view at 1280x540 and 720x360 (desktop) and 160x30 / 90x20 (terminal) are in
~/.local/state/gloom-pm/hyperliquid/ui-pass/{before,after}/, with the full issue list inui-pass/CHANGES.md.Found, not fixed
Behaviour outside
src/ui, left for the owners of those files:src/market/service.ts,MarketSession): the candle WebSocket update can land before thecandleSnapshotresponse, sosnapshot.candlesbriefly holds one candle and the chart drew a single bar in a one-day window. Reproduce: fresh profile,gloomberb shot HLP BTC --tab Chart --width 720 --height 360a few times; one capture showed a lone candle. The chart now treats one candle as loading, but the session still publishes it.src/trading/account.tspolling, message fromsrc/market/transport.ts): each watch-only account store polls many info endpoints, so a few account panes opened in quick succession getHyperliquid clearinghouseState: 429 null/userAbstraction: 429 null, and the raw status andnullbody reach the pane as the error text. Reproduce: run about tengloomberb shot HLA --watch-address 0x010461c14e146ac35fe42271bdc1134ee31c703a --tab <tab>back to back.--days/--resolutionnot applied to panes (src/headless.ts): these two report options have nosettingKey, soshot HLP BTC --tab Funding --days 30still opens the 1W range in the pane (the headless report itself uses them).src/market/cloud-history.ts("This version of Gloom cannot share your Cloud login with plugins. Pro history is unavailable here."), so it was not shortened here.Verification
bun run typecheck: passed; each commit also typechecks on its own.bun test: 81 passed, 0 failed (7 new tests for the formatting math: tick labels, rounding to zero, fixed decimals, countdown).gloomberb plugin doctor hyperliquidfrom an isolated host checkout (cf82012a) and throwaway profile: all 10 checks ok, desktop browser build 350 KB (was 343 KB).gloomberb fn HLP --limit 3 --json: ok.gloomberb shotat 1280x540 and 720x360, before and after, and read.TESTNET,Watch-only 0x…,Read-only, hints). No React, listener or update-depth warnings in 38 stderr logs; no tmux sessions left.0x010461c14e146ac35fe42271bdc1134ee31c703aonly. No signed request, key or wallet was used.Historical analytics (funding/OI/premium history and rankings) could only be checked in their unavailable state, because the cloud routes are not reachable from this host.