gloomberb 0.20.11 → 0.20.13
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/package.json +2 -1
- package/src/account/billing.ts +3 -2
- package/src/account/upgrade-dialog.tsx +8 -8
- package/src/api-client/awards.ts +16 -0
- package/src/api-client/central-bank-rates.ts +5 -0
- package/src/api-client/data.ts +55 -2
- package/src/api-client/index.ts +28 -3
- package/src/api-client/install-experiments.ts +146 -0
- package/src/api-client/request.ts +86 -3
- package/src/api-client/socket-connection.ts +12 -1
- package/src/api-client/socket.ts +21 -3
- package/src/api-client/supply-chain-graph.ts +4 -2
- package/src/api-client/supply-chain.ts +8 -0
- package/src/api-client/telemetry.ts +47 -0
- package/src/api-client/types/econ.ts +10 -7
- package/src/api-client/types/filings-and-calls.ts +8 -0
- package/src/api-client/types/market.ts +4 -0
- package/src/api-client/types/news.ts +16 -0
- package/src/app/global-shortcuts.ts +2 -1
- package/src/app/keybindings/actions.ts +19 -0
- package/src/app/pane-runtime/index.tsx +18 -3
- package/src/app/pane-runtime/layout-placement.ts +63 -0
- package/src/app/pane-runtime/ticker-open-runtime.ts +10 -2
- package/src/architecture/floating-promise-allowlist.json +17 -33
- package/src/brokers/signed-in/adapter.ts +2 -2
- package/src/brokers/signed-in/catalog.ts +13 -4
- package/src/capabilities/chart-series.ts +4 -1
- package/src/cli/board-coins.ts +10 -1
- package/src/cli/commands/crypto-hints.ts +3 -2
- package/src/cli/commands/fred-series.ts +0 -54
- package/src/cli/commands/market.ts +260 -63
- package/src/cli/commands/overview.ts +50 -17
- package/src/cli/commands/search.ts +140 -17
- package/src/cli/commands/ticker.ts +37 -17
- package/src/cli/desktop-pane-shot.ts +27 -2
- package/src/cli/earnings-calendar.ts +33 -53
- package/src/cli/fx-quote-rate.ts +1 -1
- package/src/cli/glossary.ts +14 -5
- package/src/cli/history-catalog-series.ts +85 -0
- package/src/cli/history-rows.ts +18 -1
- package/src/cli/index.ts +1 -1
- package/src/cli/known-gaps.ts +9 -0
- package/src/cli/list-progress.ts +45 -0
- package/src/cli/listing-arg.ts +176 -25
- package/src/cli/name-entries.ts +8 -4
- package/src/cli/not-a-ticker.ts +2 -2
- package/src/cli/pane-functions/catalog.ts +55 -7
- package/src/cli/pane-functions/dom.ts +8 -1
- package/src/cli/pane-functions/freshness.ts +52 -5
- package/src/cli/pane-functions/headless.ts +8 -8
- package/src/cli/pane-functions/index.ts +8 -5
- package/src/cli/pane-functions/market-session.ts +66 -14
- package/src/cli/pane-functions/options.ts +5 -0
- package/src/cli/pane-functions/report.ts +4 -1
- package/src/cli/pane-functions/resolver.ts +9 -2
- package/src/cli/pane-functions/screenshot-assessment.ts +28 -3
- package/src/cli/pane-functions/screenshot-types.ts +6 -0
- package/src/cli/perpetual-contract.ts +4 -4
- package/src/cli/quote-answer.ts +55 -12
- package/src/cli/quote-list-reads.ts +87 -0
- package/src/cli/report-tables.ts +70 -13
- package/src/cli/result.ts +26 -3
- package/src/cli/symbol-list.ts +31 -4
- package/src/cli/terminal-code-hints.ts +83 -0
- package/src/cli/ticker-resolution.ts +2 -1
- package/src/cli/treasury-yields.ts +5 -0
- package/src/components/chart/composite/axis-overlays.tsx +5 -2
- package/src/components/chart/composite/composite-chart.tsx +1 -0
- package/src/components/chart/composite/format.ts +101 -15
- package/src/components/chart/composite/legend.tsx +60 -25
- package/src/components/chart/composite/time-axis.ts +51 -29
- package/src/components/chart/composite/toolbar.tsx +42 -6
- package/src/components/chart/curve/curve-surface.tsx +5 -5
- package/src/components/command-bar/action-runtime.ts +2 -0
- package/src/components/command-bar/list/badge.ts +8 -5
- package/src/components/command-bar/list/model.ts +0 -5
- package/src/components/command-bar/list/view.tsx +39 -2
- package/src/components/command-bar/routes/root/plugin-install.ts +4 -2
- package/src/components/command-bar/routes/root/provider-search.ts +23 -3
- package/src/components/command-bar/routes/root/results.ts +20 -9
- package/src/components/command-bar/routes/root/start-here.ts +1 -2
- package/src/components/command-bar/routes/ticker-search/actions.ts +2 -3
- package/src/components/command-bar/routes/ticker-search/results.ts +23 -4
- package/src/components/command-bar/routing/launch-request.ts +2 -1
- package/src/components/command-bar/routing/navigation-state.ts +4 -2
- package/src/components/command-bar/workflow/types.ts +6 -0
- package/src/components/data-table/view.tsx +29 -6
- package/src/components/form-modal/host.tsx +1 -1
- package/src/components/layout/detached-pane-shell.tsx +3 -0
- package/src/components/layout/double-escape-close.ts +34 -3
- package/src/components/layout/floating-pane.tsx +10 -4
- package/src/components/layout/header.tsx +3 -2
- package/src/components/layout/market-summary.ts +3 -3
- package/src/components/layout/pane/cycle-order.ts +66 -2
- package/src/components/layout/pane/error-boundary.tsx +2 -1
- package/src/components/layout/pane/header.tsx +140 -31
- package/src/components/layout/pane/sidebar.tsx +13 -5
- package/src/components/layout/pane/status-footer.ts +3 -1
- package/src/components/layout/shell/drag/runtime.ts +5 -0
- package/src/components/layout/shell/index.tsx +25 -0
- package/src/components/layout/shell/menu.ts +9 -0
- package/src/components/layout/shell/pane/actions.ts +36 -0
- package/src/components/layout/shell/pane/management-shortcuts.ts +27 -3
- package/src/components/layout/shell/pane-occlusion.ts +40 -0
- package/src/components/layout/shell/shortcuts.ts +17 -1
- package/src/components/layout/shell/terminal-pointer-runtime.ts +39 -6
- package/src/components/layout/shell/window-mode/index.ts +5 -16
- package/src/components/layout/shell/window-mode/overlays.tsx +3 -1
- package/src/components/markdown-text.tsx +36 -0
- package/src/components/market-board/index.tsx +18 -8
- package/src/components/metric-treemap/index.tsx +3 -1
- package/src/components/onboarding/first-run-workspace.ts +46 -11
- package/src/components/onboarding/onboarding-keyboard.ts +57 -5
- package/src/components/onboarding/onboarding-wizard.tsx +91 -24
- package/src/components/onboarding/portfolio-step/index.tsx +1 -0
- package/src/components/onboarding/portfolio-step/positions-panel.tsx +36 -9
- package/src/components/onboarding/portfolio-step/types.ts +2 -0
- package/src/components/onboarding/tickers-step-model.ts +140 -0
- package/src/components/onboarding/tickers-step.tsx +116 -0
- package/src/components/onboarding/use-onboarding-broker-form.ts +1 -1
- package/src/components/onboarding/use-onboarding-progress.ts +100 -11
- package/src/components/onboarding/use-onboarding-upgrade.ts +3 -2
- package/src/components/onboarding/wizard-model.ts +3 -1
- package/src/components/onboarding/wizard-tickers.ts +139 -0
- package/src/components/price-performance.tsx +2 -2
- package/src/components/speedometer-gauge/model.ts +2 -1
- package/src/components/speedometer-gauge/terminal.tsx +13 -8
- package/src/components/ui/button.tsx +48 -4
- package/src/components/ui/choice-dialog.tsx +101 -32
- package/src/components/ui/data-table/opentui/index.tsx +24 -9
- package/src/components/ui/data-table/types.ts +7 -0
- package/src/components/ui/inline-quick-add.tsx +19 -3
- package/src/components/ui/list-view.tsx +11 -5
- package/src/components/ui/multi-select/dialog.tsx +1 -7
- package/src/components/ui/not-meaningful.ts +16 -0
- package/src/components/ui/query-bar.tsx +32 -5
- package/src/components/ui/selection-fill.ts +39 -0
- package/src/components/ui/stat-grid.tsx +27 -6
- package/src/core/state/app/layout-reducer.ts +2 -1
- package/src/core/state/app/pane-choices.ts +68 -0
- package/src/core/state/app/state.ts +14 -6
- package/src/core/state/app/types.ts +8 -0
- package/src/data/config/store/normalize.ts +2 -0
- package/src/docs/snapshot.json +1 -1
- package/src/i18n/es.ts +5 -2
- package/src/i18n/ja.ts +5 -2
- package/src/i18n/ko.ts +5 -2
- package/src/i18n/zh-cn.ts +5 -2
- package/src/i18n/zh-tw.ts +5 -2
- package/src/layout/pane-manager/dock-tree.ts +19 -0
- package/src/layout/pane-manager/index.ts +3 -0
- package/src/layout-marketplace/model.ts +2 -1
- package/src/market-data/futures-contract.ts +2 -1
- package/src/market-data/hooks.tsx +1 -1
- package/src/market-data/market/change-basis.ts +27 -5
- package/src/market-data/market/format.ts +13 -13
- package/src/market-data/market/freshness.ts +33 -0
- package/src/market-data/market/status.ts +5 -1
- package/src/market-data/quotes/contributions.ts +10 -0
- package/src/market-data/quotes/freshness.ts +19 -0
- package/src/market-data/quotes/listing-enterprise-value.ts +3 -3
- package/src/market-data/quotes/live-valuation.ts +31 -4
- package/src/market-data/quotes/resolution.ts +4 -0
- package/src/market-data/quotes/time.ts +17 -24
- package/src/market-data/tax-equivalent.ts +3 -2
- package/src/news/aggregator.ts +19 -8
- package/src/news/hooks.ts +1 -1
- package/src/news/news-model.ts +49 -0
- package/src/news/types.ts +9 -0
- package/src/plugins/builtin/account-management/calendar-tab.tsx +8 -3
- package/src/plugins/builtin/account-management/index.tsx +1 -0
- package/src/plugins/builtin/account-management/pane.tsx +9 -8
- package/src/plugins/builtin/alerts/calendar-events.ts +4 -5
- package/src/plugins/builtin/alerts/format.ts +6 -5
- package/src/plugins/builtin/alerts/headless.ts +3 -2
- package/src/plugins/builtin/alerts/history.ts +2 -1
- package/src/plugins/builtin/alerts/pane.tsx +2 -1
- package/src/plugins/builtin/alerts/price-text.ts +2 -1
- package/src/plugins/builtin/alerts/scheduled.ts +6 -5
- package/src/plugins/builtin/analytics/account-returns.ts +6 -7
- package/src/plugins/builtin/analytics/display.ts +2 -1
- package/src/plugins/builtin/analytics/pane-model.ts +5 -9
- package/src/plugins/builtin/analytics/risk-model.ts +6 -6
- package/src/plugins/builtin/analytics/risk-pane.tsx +6 -5
- package/src/plugins/builtin/analytics/view.tsx +5 -5
- package/src/plugins/builtin/attention/model.ts +6 -5
- package/src/plugins/builtin/attention/pane.tsx +5 -4
- package/src/plugins/builtin/awards/detail.tsx +17 -8
- package/src/plugins/builtin/awards/headless.ts +37 -15
- package/src/plugins/builtin/awards/model.ts +40 -5
- package/src/plugins/builtin/awards/pane.tsx +11 -8
- package/src/plugins/builtin/backtest/format.ts +3 -2
- package/src/plugins/builtin/backtest/report.ts +3 -2
- package/src/plugins/builtin/bond-calculator/headless.ts +2 -1
- package/src/plugins/builtin/bond-calculator/pane.tsx +2 -1
- package/src/plugins/builtin/broker-manager/add-flow.tsx +1 -1
- package/src/plugins/builtin/broker-manager/index.tsx +1 -0
- package/src/plugins/builtin/broker-trading/index.tsx +1 -1
- package/src/plugins/builtin/broker-trading/orders-data.ts +3 -3
- package/src/plugins/builtin/broker-trading/orders.tsx +3 -2
- package/src/plugins/builtin/broker-trading/ticket.tsx +2 -2
- package/src/plugins/builtin/buildout/cells.tsx +2 -1
- package/src/plugins/builtin/buildout/company/pane.tsx +4 -3
- package/src/plugins/builtin/buildout/data-runtime.ts +21 -23
- package/src/plugins/builtin/buildout/detail/values.ts +2 -1
- package/src/plugins/builtin/buildout/format.ts +4 -3
- package/src/plugins/builtin/buildout/pane/index.tsx +3 -3
- package/src/plugins/builtin/catalysts/detail.tsx +2 -1
- package/src/plugins/builtin/catalysts/model.ts +6 -5
- package/src/plugins/builtin/catalysts/pane.tsx +2 -1
- package/src/plugins/builtin/cds/headless.ts +3 -2
- package/src/plugins/builtin/cds/model.ts +8 -8
- package/src/plugins/builtin/cds/pane.tsx +3 -2
- package/src/plugins/builtin/central-bank-rates/headless.ts +8 -7
- package/src/plugins/builtin/central-bank-rates/index.tsx +1 -1
- package/src/plugins/builtin/central-bank-rates/model.ts +24 -5
- package/src/plugins/builtin/central-bank-rates/pane.tsx +19 -9
- package/src/plugins/builtin/changelog/index.tsx +2 -2
- package/src/plugins/builtin/chart-composer/headless.ts +5 -1
- package/src/plugins/builtin/chart-composer/index.tsx +4 -2
- package/src/plugins/builtin/chart-composer/pane.tsx +8 -3
- package/src/plugins/builtin/chart-composer/use-series-catalog.ts +3 -1
- package/src/plugins/builtin/chart-composer/user-series.ts +3 -1
- package/src/plugins/builtin/chat/attachments/desktop.tsx +2 -1
- package/src/plugins/builtin/chat/content/handle-prompt.tsx +4 -0
- package/src/plugins/builtin/chat/controller/realtime.ts +17 -1
- package/src/plugins/builtin/chat/controller/utils.ts +2 -1
- package/src/plugins/builtin/chat/message/terminal.tsx +4 -1
- package/src/plugins/builtin/chat/sidebar.tsx +3 -4
- package/src/plugins/builtin/clinical-trials/model.ts +4 -3
- package/src/plugins/builtin/clinical-trials/sponsor-tickers.ts +4 -2
- package/src/plugins/builtin/cloud/askg/lock-note.ts +16 -4
- package/src/plugins/builtin/cloud/askg/model.ts +2 -1
- package/src/plugins/builtin/cloud/askg/pane.tsx +39 -1
- package/src/plugins/builtin/cloud/company-picker.tsx +1 -3
- package/src/plugins/builtin/cloud/plugin.tsx +1 -0
- package/src/plugins/builtin/cloud/team/module.tsx +1 -0
- package/src/plugins/builtin/cloud/team/pane.tsx +12 -12
- package/src/plugins/builtin/cloud/thesis/detail.tsx +22 -12
- package/src/plugins/builtin/cloud-tweets/model.ts +2 -2
- package/src/plugins/builtin/comment-letters/pane.tsx +2 -1
- package/src/plugins/builtin/commodity-balances/headless.ts +3 -2
- package/src/plugins/builtin/commodity-balances/pane.tsx +13 -5
- package/src/plugins/builtin/company-attention/app-rank.tsx +5 -4
- package/src/plugins/builtin/company-attention/building-model.ts +7 -7
- package/src/plugins/builtin/company-attention/headless.ts +6 -5
- package/src/plugins/builtin/company-attention/model.ts +4 -4
- package/src/plugins/builtin/company-attention/moves-model.ts +9 -9
- package/src/plugins/builtin/company-attention/signals-model.ts +9 -9
- package/src/plugins/builtin/company-kpis/headless.ts +2 -1
- package/src/plugins/builtin/company-kpis/model.ts +18 -13
- package/src/plugins/builtin/company-kpis/pane.tsx +2 -2
- package/src/plugins/builtin/congress-trades/detail.tsx +6 -5
- package/src/plugins/builtin/congress-trades/headless.ts +2 -1
- package/src/plugins/builtin/congress-trades/model.ts +6 -6
- package/src/plugins/builtin/congress-trades/table.tsx +7 -6
- package/src/plugins/builtin/connections/index.ts +1 -0
- package/src/plugins/builtin/connections/pane.tsx +5 -5
- package/src/plugins/builtin/correlation/headless.ts +2 -2
- package/src/plugins/builtin/correlation/index.tsx +4 -1
- package/src/plugins/builtin/correlation/matrix/selection.ts +2 -1
- package/src/plugins/builtin/correlation/relationship/view-model.ts +3 -3
- package/src/plugins/builtin/cot/headless.ts +3 -2
- package/src/plugins/builtin/cot/model.ts +2 -1
- package/src/plugins/builtin/cot/pane.tsx +4 -3
- package/src/plugins/builtin/cpi/headless.ts +4 -3
- package/src/plugins/builtin/cpi/model.ts +8 -7
- package/src/plugins/builtin/credit-boards/cdx-pane.tsx +14 -9
- package/src/plugins/builtin/credit-boards/client.ts +5 -0
- package/src/plugins/builtin/credit-boards/headless.ts +3 -7
- package/src/plugins/builtin/credit-boards/model.ts +5 -11
- package/src/plugins/builtin/credit-boards/series.ts +19 -8
- package/src/plugins/builtin/credit-boards/sovr-pane.tsx +9 -5
- package/src/plugins/builtin/credit-conditions/headless.ts +2 -1
- package/src/plugins/builtin/credit-conditions/index.tsx +2 -2
- package/src/plugins/builtin/credit-documents/model.ts +2 -2
- package/src/plugins/builtin/crypto-board/defi-view.tsx +7 -7
- package/src/plugins/builtin/crypto-board/defi.ts +2 -2
- package/src/plugins/builtin/crypto-board/model.ts +4 -3
- package/src/plugins/builtin/crypto-board/pane.tsx +8 -8
- package/src/plugins/builtin/crypto-board/supply.ts +2 -2
- package/src/plugins/builtin/crypto-etf-flows/headless.ts +23 -13
- package/src/plugins/builtin/crypto-etf-flows/model.ts +4 -4
- package/src/plugins/builtin/crypto-etf-flows/pane.tsx +8 -3
- package/src/plugins/builtin/custom-view/index.tsx +3 -1
- package/src/plugins/builtin/custom-view/pane.tsx +5 -1
- package/src/plugins/builtin/custom-view/view-spec.ts +11 -0
- package/src/plugins/builtin/debt-maturities/headless.ts +16 -7
- package/src/plugins/builtin/debt-maturities/model.ts +12 -18
- package/src/plugins/builtin/debt-maturities/pane.tsx +11 -12
- package/src/plugins/builtin/dividend-yield/client.ts +7 -3
- package/src/plugins/builtin/dividend-yield/headless.ts +16 -11
- package/src/plugins/builtin/dividend-yield/pane.tsx +12 -10
- package/src/plugins/builtin/dividend-yield/ranking-view.tsx +4 -1
- package/src/plugins/builtin/dividend-yield/ranking.ts +19 -11
- package/src/plugins/builtin/dividend-yield/types.ts +4 -0
- package/src/plugins/builtin/dividend-yield/view.ts +3 -3
- package/src/plugins/builtin/docs/use-docs.ts +4 -2
- package/src/plugins/builtin/doe/headless.ts +2 -1
- package/src/plugins/builtin/doe/model.ts +12 -11
- package/src/plugins/builtin/earnings/board-model.ts +42 -7
- package/src/plugins/builtin/earnings/board-table.ts +13 -8
- package/src/plugins/builtin/earnings/board.tsx +15 -3
- package/src/plugins/builtin/earnings/calendar-model.ts +5 -5
- package/src/plugins/builtin/earnings/calendar.tsx +11 -6
- package/src/plugins/builtin/earnings/client.ts +0 -9
- package/src/plugins/builtin/earnings/format.ts +16 -14
- package/src/plugins/builtin/earnings/headless.ts +64 -23
- package/src/plugins/builtin/earnings/history-model.ts +11 -7
- package/src/plugins/builtin/earnings/history-table.ts +14 -9
- package/src/plugins/builtin/earnings/history.tsx +22 -14
- package/src/plugins/builtin/earnings-calls/calendar.tsx +2 -1
- package/src/plugins/builtin/earnings-calls/data.ts +24 -4
- package/src/plugins/builtin/earnings-calls/format.ts +29 -10
- package/src/plugins/builtin/earnings-calls/headless.ts +23 -3
- package/src/plugins/builtin/earnings-calls/index.tsx +1 -0
- package/src/plugins/builtin/earnings-calls/model.ts +11 -1
- package/src/plugins/builtin/earnings-calls/pane.tsx +2 -5
- package/src/plugins/builtin/earnings-calls/upcoming.ts +5 -5
- package/src/plugins/builtin/earnings-ripple/headless.ts +2 -1
- package/src/plugins/builtin/earnings-ripple/model.ts +3 -2
- package/src/plugins/builtin/earnings-ripple/pane.tsx +6 -6
- package/src/plugins/builtin/econ/calendar-model.ts +29 -2
- package/src/plugins/builtin/econ/detail-view.tsx +2 -2
- package/src/plugins/builtin/econ/fred-catalog.ts +3 -0
- package/src/plugins/builtin/econ/index.tsx +16 -8
- package/src/plugins/builtin/econ-statistics/detail.tsx +2 -1
- package/src/plugins/builtin/econ-statistics/headless.ts +7 -5
- package/src/plugins/builtin/econ-statistics/index.tsx +1 -1
- package/src/plugins/builtin/econ-statistics/pane.tsx +2 -2
- package/src/plugins/builtin/equity-screener/headless.ts +5 -5
- package/src/plugins/builtin/equity-screener/model.ts +6 -4
- package/src/plugins/builtin/equity-screener/pane.tsx +7 -7
- package/src/plugins/builtin/equity-screener/screen-check.ts +2 -1
- package/src/plugins/builtin/equity-screener/ticker-check.tsx +2 -1
- package/src/plugins/builtin/estimate-revisions/model.ts +3 -2
- package/src/plugins/builtin/estimate-revisions/pane.tsx +8 -8
- package/src/plugins/builtin/executives/format.ts +4 -4
- package/src/plugins/builtin/exposure/headless.ts +8 -8
- package/src/plugins/builtin/exposure/model.ts +4 -3
- package/src/plugins/builtin/exposure/pane.tsx +6 -5
- package/src/plugins/builtin/fear-greed/format.ts +7 -7
- package/src/plugins/builtin/fear-greed/headless.ts +18 -14
- package/src/plugins/builtin/fear-greed/pane.tsx +12 -4
- package/src/plugins/builtin/filing-events/feed.ts +2 -1
- package/src/plugins/builtin/filing-events/index.tsx +1 -0
- package/src/plugins/builtin/futures/table.tsx +8 -8
- package/src/plugins/builtin/futures-curve/headless.ts +18 -18
- package/src/plugins/builtin/futures-curve/model.ts +5 -5
- package/src/plugins/builtin/futures-curve/pane.tsx +8 -8
- package/src/plugins/builtin/fx-matrix/index.tsx +32 -21
- package/src/plugins/builtin/fx-matrix/pairs.ts +2 -1
- package/src/plugins/builtin/gpu/board.tsx +6 -5
- package/src/plugins/builtin/gpu/changes.tsx +2 -1
- package/src/plugins/builtin/gpu/equities.tsx +2 -2
- package/src/plugins/builtin/gpu/headless.ts +4 -3
- package/src/plugins/builtin/gpu/model.ts +8 -7
- package/src/plugins/builtin/help/functions-table.tsx +41 -9
- package/src/plugins/builtin/help/index.tsx +6 -3
- package/src/plugins/builtin/help/keybindings-editor.tsx +35 -7
- package/src/plugins/builtin/help/shortcut-table.tsx +19 -7
- package/src/plugins/builtin/help/table-cells.tsx +51 -0
- package/src/plugins/builtin/holders/pane.tsx +4 -1
- package/src/plugins/builtin/insider/base-values.ts +2 -2
- package/src/plugins/builtin/insider/display.ts +2 -1
- package/src/plugins/builtin/insider/headless.ts +16 -16
- package/src/plugins/builtin/insider/insider-data.ts +2 -1
- package/src/plugins/builtin/insider/signals-model.ts +3 -3
- package/src/plugins/builtin/insider/table-model.ts +27 -13
- package/src/plugins/builtin/insider/table.tsx +11 -8
- package/src/plugins/builtin/insider/tickers.tsx +1 -1
- package/src/plugins/builtin/ipo-calendar/model.ts +4 -4
- package/src/plugins/builtin/iv-history/format.ts +8 -7
- package/src/plugins/builtin/iv-history/headless.ts +18 -16
- package/src/plugins/builtin/iv-history/pane.tsx +3 -2
- package/src/plugins/builtin/iv-history/screen-pane.tsx +5 -4
- package/src/plugins/builtin/jobs/headless.ts +11 -11
- package/src/plugins/builtin/jobs/index.tsx +1 -0
- package/src/plugins/builtin/jobs/model.ts +2 -2
- package/src/plugins/builtin/jobs/pane.tsx +5 -5
- package/src/plugins/builtin/jodi/model.ts +2 -2
- package/src/plugins/builtin/jodi/pane.tsx +2 -1
- package/src/plugins/builtin/kelly-sizer/headless.ts +4 -4
- package/src/plugins/builtin/kelly-sizer/model.ts +2 -1
- package/src/plugins/builtin/kelly-sizer/sections.tsx +2 -2
- package/src/plugins/builtin/macro-day/headless.ts +9 -8
- package/src/plugins/builtin/macro-day/model.ts +3 -2
- package/src/plugins/builtin/macro-day/pane.tsx +4 -4
- package/src/plugins/builtin/macro-day/releases.ts +25 -16
- package/src/plugins/builtin/market-halts/model.ts +11 -10
- package/src/plugins/builtin/market-halts/pane.tsx +2 -1
- package/src/plugins/builtin/market-heatmap/index.tsx +4 -4
- package/src/plugins/builtin/market-movers/index.tsx +20 -8
- package/src/plugins/builtin/market-movers/model.ts +5 -0
- package/src/plugins/builtin/market-movers/session-body.tsx +2 -1
- package/src/plugins/builtin/market-movers/session-table.ts +3 -3
- package/src/plugins/builtin/market-movers/session.ts +2 -1
- package/src/plugins/builtin/market-movers/table.ts +5 -5
- package/src/plugins/builtin/market-valuation/detail.tsx +2 -2
- package/src/plugins/builtin/market-valuation/headless.ts +7 -7
- package/src/plugins/builtin/market-valuation/pane.tsx +7 -7
- package/src/plugins/builtin/members/breadth-pane.tsx +5 -4
- package/src/plugins/builtin/members/headless.ts +2 -1
- package/src/plugins/builtin/members/model.ts +3 -2
- package/src/plugins/builtin/members/pane.tsx +10 -9
- package/src/plugins/builtin/mna/distress/model.ts +2 -1
- package/src/plugins/builtin/mna/model.ts +5 -5
- package/src/plugins/builtin/money-markets/headless.ts +14 -3
- package/src/plugins/builtin/money-markets/model.ts +3 -2
- package/src/plugins/builtin/money-markets/pane.tsx +14 -5
- package/src/plugins/builtin/news/headless.ts +5 -2
- package/src/plugins/builtin/news/wire/breaking/notifications.ts +21 -19
- package/src/plugins/builtin/news/wire/news/row.ts +3 -1
- package/src/plugins/builtin/news/wire/news/table.tsx +3 -2
- package/src/plugins/builtin/news/wire/persisted-articles.ts +28 -3
- package/src/plugins/builtin/notes/headless.ts +2 -1
- package/src/plugins/builtin/notes/model.ts +2 -1
- package/src/plugins/builtin/openfda/pane.tsx +4 -3
- package/src/plugins/builtin/options/carry.ts +3 -2
- package/src/plugins/builtin/options/market-reference.ts +2 -1
- package/src/plugins/builtin/options/table.ts +48 -9
- package/src/plugins/builtin/options/view.tsx +48 -17
- package/src/plugins/builtin/options-calculator/headless.ts +3 -2
- package/src/plugins/builtin/options-calculator/pane.tsx +7 -7
- package/src/plugins/builtin/options-positioning/headless.ts +8 -7
- package/src/plugins/builtin/options-positioning/model.ts +10 -10
- package/src/plugins/builtin/options-positioning/pane.tsx +6 -6
- package/src/plugins/builtin/options-scenario/collar.ts +5 -4
- package/src/plugins/builtin/options-scenario/csp-screen-headless.ts +11 -10
- package/src/plugins/builtin/options-scenario/csp-screen-pane.tsx +15 -14
- package/src/plugins/builtin/options-scenario/csp-screen.ts +2 -1
- package/src/plugins/builtin/options-scenario/csp.ts +6 -5
- package/src/plugins/builtin/options-scenario/headless.ts +6 -5
- package/src/plugins/builtin/options-scenario/hedge.ts +3 -3
- package/src/plugins/builtin/options-scenario/pane.tsx +7 -6
- package/src/plugins/builtin/options-scenario/strategy-screen.ts +1 -1
- package/src/plugins/builtin/pe-band/headless.ts +9 -8
- package/src/plugins/builtin/pe-band/pane.tsx +7 -7
- package/src/plugins/builtin/perps/cascade.ts +3 -2
- package/src/plugins/builtin/perps/headless.ts +10 -9
- package/src/plugins/builtin/perps/model.ts +14 -14
- package/src/plugins/builtin/perps/pane.tsx +3 -2
- package/src/plugins/builtin/portfolio-list/cli/bulk-symbols.ts +4 -31
- package/src/plugins/builtin/portfolio-list/header.tsx +2 -2
- package/src/plugins/builtin/portfolio-list/index.tsx +3 -2
- package/src/plugins/builtin/portfolio-list/pane/futures-terms.ts +4 -2
- package/src/plugins/builtin/portfolio-list/pane/index.tsx +6 -1
- package/src/plugins/builtin/portfolio-list/pane/period-pnl.ts +2 -1
- package/src/plugins/builtin/portfolio-list/pane/purchase-date-fx.ts +4 -2
- package/src/plugins/builtin/portfolio-list/quick-add/index.tsx +24 -10
- package/src/plugins/builtin/portfolio-list/settings.ts +4 -1
- package/src/plugins/builtin/portfolio-list/summary/index.tsx +9 -11
- package/src/plugins/builtin/portfolio-list/table.tsx +10 -1
- package/src/plugins/builtin/power/detail.tsx +6 -5
- package/src/plugins/builtin/power/gas-model.ts +8 -7
- package/src/plugins/builtin/power/gas.tsx +2 -1
- package/src/plugins/builtin/power/headless.ts +7 -6
- package/src/plugins/builtin/power/model.ts +3 -2
- package/src/plugins/builtin/power/prices-headless.ts +10 -9
- package/src/plugins/builtin/power/prices-model.ts +3 -2
- package/src/plugins/builtin/power/prices.tsx +2 -1
- package/src/plugins/builtin/primary-dealers/model.ts +3 -3
- package/src/plugins/builtin/primary-dealers/pane.tsx +2 -2
- package/src/plugins/builtin/rate-path/headless.ts +8 -7
- package/src/plugins/builtin/rate-path/model.ts +6 -5
- package/src/plugins/builtin/rate-path/pane.tsx +6 -5
- package/src/plugins/builtin/realized-vol/fx-proxy.ts +2 -1
- package/src/plugins/builtin/realized-vol/headless.ts +37 -10
- package/src/plugins/builtin/realized-vol/pane.tsx +5 -4
- package/src/plugins/builtin/relative-rotation/headless.ts +2 -1
- package/src/plugins/builtin/relative-rotation/pane.tsx +6 -6
- package/src/plugins/builtin/research/analyst-headless.ts +5 -5
- package/src/plugins/builtin/research/analyst-model.ts +7 -7
- package/src/plugins/builtin/research/analyst-pane.tsx +7 -7
- package/src/plugins/builtin/research/client.ts +14 -0
- package/src/plugins/builtin/research/corporate-actions-pane.tsx +40 -30
- package/src/plugins/builtin/research/event-model.ts +55 -22
- package/src/plugins/builtin/research/event-sources.ts +26 -8
- package/src/plugins/builtin/research/relative-valuation-columns.ts +20 -12
- package/src/plugins/builtin/research/relative-valuation-currency.ts +16 -0
- package/src/plugins/builtin/research/relative-valuation-headless.ts +33 -21
- package/src/plugins/builtin/research/relative-valuation-model.ts +31 -17
- package/src/plugins/builtin/research/relative-valuation-pane.tsx +29 -14
- package/src/plugins/builtin/research-search/model.ts +2 -1
- package/src/plugins/builtin/research-search/saved-view.tsx +4 -3
- package/src/plugins/builtin/revenue-breakdown/model.ts +4 -4
- package/src/plugins/builtin/reverse-dcf/headless.ts +7 -7
- package/src/plugins/builtin/reverse-dcf/model.ts +4 -4
- package/src/plugins/builtin/reverse-dcf/pane.tsx +2 -2
- package/src/plugins/builtin/risk-factors/index.tsx +1 -0
- package/src/plugins/builtin/scanner/flow-model.ts +7 -4
- package/src/plugins/builtin/scanner/flow-pane.tsx +1 -1
- package/src/plugins/builtin/scanner/headless.ts +3 -2
- package/src/plugins/builtin/scanner/hilo-model.ts +2 -1
- package/src/plugins/builtin/scanner/live-headless.ts +2 -2
- package/src/plugins/builtin/scanner/live-model.ts +3 -2
- package/src/plugins/builtin/scanner/live-pane.tsx +5 -5
- package/src/plugins/builtin/seasonality/headless.ts +2 -1
- package/src/plugins/builtin/seasonality/pane.tsx +4 -3
- package/src/plugins/builtin/sec/filing-display.tsx +12 -15
- package/src/plugins/builtin/sec/fund-facts.ts +2 -2
- package/src/plugins/builtin/sec/headless.ts +2 -1
- package/src/plugins/builtin/sec/index.tsx +6 -2
- package/src/plugins/builtin/sectors/headless.ts +4 -4
- package/src/plugins/builtin/sectors/index.tsx +7 -7
- package/src/plugins/builtin/shared/earnings-calendar.ts +90 -6
- package/src/plugins/builtin/shared/earnings-report.ts +13 -6
- package/src/plugins/builtin/shared/research-cells.tsx +2 -2
- package/src/plugins/builtin/shared/source-footer.ts +71 -0
- package/src/plugins/builtin/shared/trend.ts +2 -2
- package/src/plugins/builtin/shared/use-quote-board.ts +9 -8
- package/src/plugins/builtin/short-interest/headless.ts +6 -6
- package/src/plugins/builtin/short-interest/model.ts +9 -9
- package/src/plugins/builtin/short-interest/publications-model.ts +5 -5
- package/src/plugins/builtin/short-interest/publications-pane.tsx +8 -3
- package/src/plugins/builtin/short-interest/watch-headless.ts +5 -5
- package/src/plugins/builtin/short-interest/watch-pane.tsx +6 -6
- package/src/plugins/builtin/short-volume/model.ts +5 -5
- package/src/plugins/builtin/short-volume/pane.tsx +9 -5
- package/src/plugins/builtin/social-mentions/headless.ts +2 -1
- package/src/plugins/builtin/social-mentions/model.ts +4 -4
- package/src/plugins/builtin/social-mentions/outliers.tsx +10 -1
- package/src/plugins/builtin/social-mentions/pane.tsx +7 -0
- package/src/plugins/builtin/supply-chain/client.ts +3 -1
- package/src/plugins/builtin/supply-chain/flow.tsx +25 -8
- package/src/plugins/builtin/supply-chain/graph-client.ts +1 -1
- package/src/plugins/builtin/supply-chain/graph-evidence.ts +1 -1
- package/src/plugins/builtin/supply-chain/graph-model.ts +14 -2
- package/src/plugins/builtin/supply-chain/graph-pane.tsx +11 -10
- package/src/plugins/builtin/supply-chain/graph.tsx +12 -6
- package/src/plugins/builtin/supply-chain/headless.ts +15 -8
- package/src/plugins/builtin/supply-chain/model.ts +72 -15
- package/src/plugins/builtin/supply-chain/pane.tsx +11 -8
- package/src/plugins/builtin/supply-chain/row-evidence.tsx +7 -6
- package/src/plugins/builtin/themes/headless.ts +2 -1
- package/src/plugins/builtin/themes/model.ts +3 -2
- package/src/plugins/builtin/themes/pane.tsx +3 -2
- package/src/plugins/builtin/thirteenf/format.ts +9 -9
- package/src/plugins/builtin/thirteenf/headless.ts +3 -2
- package/src/plugins/builtin/thirteenf/model.ts +2 -1
- package/src/plugins/builtin/thirteenf/overlap-pane.tsx +2 -1
- package/src/plugins/builtin/thirteenf/pane.tsx +5 -4
- package/src/plugins/builtin/thirteenf/report-notes.ts +2 -1
- package/src/plugins/builtin/thirteenf/signals-pane.tsx +3 -2
- package/src/plugins/builtin/thirteenf/table.ts +6 -5
- package/src/plugins/builtin/ticker-detail/adr-pair/model.ts +4 -3
- package/src/plugins/builtin/ticker-detail/data-panes/historical-prices.tsx +4 -4
- package/src/plugins/builtin/ticker-detail/data-panes/returns-pane.tsx +3 -3
- package/src/plugins/builtin/ticker-detail/financials/model.ts +83 -35
- package/src/plugins/builtin/ticker-detail/financials/ratio-table.tsx +3 -1
- package/src/plugins/builtin/ticker-detail/financials/ratios.ts +2 -2
- package/src/plugins/builtin/ticker-detail/financials/schema.ts +14 -18
- package/src/plugins/builtin/ticker-detail/financials/tab.tsx +8 -13
- package/src/plugins/builtin/ticker-detail/headless.ts +7 -5
- package/src/plugins/builtin/ticker-detail/overview/chart-scale.ts +52 -0
- package/src/plugins/builtin/ticker-detail/overview/components.tsx +18 -5
- package/src/plugins/builtin/ticker-detail/overview/model.ts +24 -13
- package/src/plugins/builtin/ticker-detail/overview/pane.tsx +6 -0
- package/src/plugins/builtin/ticker-detail/overview/tax-equivalent.ts +2 -1
- package/src/plugins/builtin/ticker-detail/overview-tab.tsx +35 -7
- package/src/plugins/builtin/ticker-detail/pane.tsx +48 -24
- package/src/plugins/builtin/ticker-detail/quote-footer.ts +5 -0
- package/src/plugins/builtin/ticker-detail/quote-monitor/card.tsx +13 -8
- package/src/plugins/builtin/ticker-detail/quote-monitor/rows.ts +4 -4
- package/src/plugins/builtin/ticker-detail/settings.ts +17 -0
- package/src/plugins/builtin/time-sales/headless.ts +3 -2
- package/src/plugins/builtin/time-sales/model.ts +7 -5
- package/src/plugins/builtin/time-sales/pane.tsx +7 -6
- package/src/plugins/builtin/trace-bonds/model.ts +3 -2
- package/src/plugins/builtin/trace-bonds/pane.tsx +3 -2
- package/src/plugins/builtin/treasury-auctions/after.ts +50 -23
- package/src/plugins/builtin/treasury-auctions/cache.ts +23 -5
- package/src/plugins/builtin/treasury-auctions/client.ts +2 -1
- package/src/plugins/builtin/treasury-auctions/headless.ts +231 -42
- package/src/plugins/builtin/treasury-auctions/hk-headless.ts +14 -7
- package/src/plugins/builtin/treasury-auctions/hk-view.tsx +37 -34
- package/src/plugins/builtin/treasury-auctions/hk.ts +65 -13
- package/src/plugins/builtin/treasury-auctions/index.tsx +3 -0
- package/src/plugins/builtin/treasury-auctions/keys.ts +27 -0
- package/src/plugins/builtin/treasury-auctions/like.ts +137 -0
- package/src/plugins/builtin/treasury-auctions/model.ts +101 -23
- package/src/plugins/builtin/treasury-auctions/pane.tsx +56 -28
- package/src/plugins/builtin/treasury-auctions/treasury-direct.ts +2 -1
- package/src/plugins/builtin/treasury-daily/model.ts +2 -2
- package/src/plugins/builtin/vol-surface/events.ts +5 -4
- package/src/plugins/builtin/vol-surface/headless.ts +19 -18
- package/src/plugins/builtin/vol-surface/heat-grid.tsx +6 -3
- package/src/plugins/builtin/vol-surface/pane.tsx +13 -9
- package/src/plugins/builtin/vol-surface/stored.ts +2 -1
- package/src/plugins/builtin/vol-surface/tables.ts +4 -3
- package/src/plugins/builtin/volatility/headless.ts +5 -4
- package/src/plugins/builtin/volatility/pane.tsx +6 -6
- package/src/plugins/builtin/world-indices/headless.ts +7 -7
- package/src/plugins/builtin/world-indices/index.tsx +3 -1
- package/src/plugins/builtin/world-venue-map/headless.ts +2 -1
- package/src/plugins/builtin/world-venue-map/layered-pane.tsx +2 -1
- package/src/plugins/builtin/world-venue-map/layers.ts +3 -2
- package/src/plugins/builtin/world-venue-map/use-geo.ts +4 -2
- package/src/plugins/builtin/yield-curve/curves.ts +3 -3
- package/src/plugins/builtin/yield-curve/headless.ts +7 -6
- package/src/plugins/builtin/yield-curve/index.tsx +5 -4
- package/src/plugins/builtin/yield-curve/swaps.tsx +2 -1
- package/src/plugins/runtime/index.tsx +1 -0
- package/src/plugins/runtime/state.ts +20 -0
- package/src/portfolio/allocation.ts +5 -5
- package/src/portfolio/column-values.ts +54 -42
- package/src/portfolio/futures-positions.ts +2 -1
- package/src/public/__snapshots__/public-api.test.ts.snap +5 -0
- package/src/public/react.ts +7 -0
- package/src/react/auto-refresh.ts +29 -0
- package/src/renderers/browser/deeplink-bridge.ts +24 -3
- package/src/renderers/dom/desktop/query-bar.tsx +229 -60
- package/src/renderers/dom/host/overflow-fade-px.ts +2 -0
- package/src/renderers/dom/host/overflow-fade.ts +1 -2
- package/src/renderers/dom/styles.css +25 -5
- package/src/renderers/electrobun/bun/desktop/backend-requests.ts +7 -1
- package/src/renderers/electrobun/view/cli-pane-shot-entry.tsx +2 -1
- package/src/renderers/opentui/ui-host.tsx +32 -2
- package/src/renderers/share/layout-view.tsx +2 -1
- package/src/series/types.ts +2 -0
- package/src/sources/gloomberb-cloud/fred-attribution.ts +86 -0
- package/src/sources/gloomberb-cloud/index.ts +25 -1
- package/src/sources/gloomberb-cloud/news.ts +9 -0
- package/src/sources/gloomberb-cloud/normalizers.ts +24 -3
- package/src/sources/provider-errors.ts +64 -1
- package/src/sources/provider-router/batches.ts +19 -0
- package/src/sources/provider-router/index.ts +7 -1
- package/src/sources/provider-router/search.ts +15 -10
- package/src/state/app/context/index.tsx +24 -1
- package/src/state/hooks/inline-tickers.ts +3 -2
- package/src/state/hooks/quote-streaming.ts +9 -10
- package/src/state/pane-unsent-work.ts +47 -0
- package/src/team/collections-sync.ts +8 -3
- package/src/telemetry/usage-counts.ts +26 -0
- package/src/test-support/shell-pane-keys.tsx +5 -0
- package/src/test-support/telemetry-guard.ts +83 -0
- package/src/test-support/test-env.ts +12 -0
- package/src/theme/colors.ts +17 -1
- package/src/theme/ui-tokens.ts +50 -1
- package/src/tickers/company-name-listing.ts +2 -2
- package/src/tickers/company-name.ts +17 -1
- package/src/tickers/listing-venues.ts +37 -2
- package/src/tickers/renamed-listings.ts +2 -1
- package/src/tickers/search/index.ts +19 -0
- package/src/tickers/search/japanese-names.json +1 -0
- package/src/tickers/search/japanese-names.ts +152 -0
- package/src/tickers/starter-symbols.ts +7 -0
- package/src/tickers/terminal-codes.ts +55 -6
- package/src/time-series/base-series.ts +3 -0
- package/src/time-series/fundamentals/statement-fields.ts +11 -14
- package/src/time-series/history-acquisition.ts +1 -1
- package/src/time-series/log-scale.ts +9 -0
- package/src/time-series/reporting.ts +3 -3
- package/src/time-series/resolve.ts +6 -4
- package/src/time-series/transforms.ts +10 -5
- package/src/types/config.ts +9 -0
- package/src/types/data-provider.ts +9 -2
- package/src/types/financials.ts +26 -0
- package/src/types/instrument.ts +6 -0
- package/src/types/plugin-contributions.ts +7 -0
- package/src/types/plugin-panes.ts +8 -1
- package/src/types/plugin-reports.ts +8 -0
- package/src/ui/host.tsx +6 -0
- package/src/utils/datetime-format.ts +74 -33
- package/src/utils/double-escape-close.ts +42 -0
- package/src/utils/financial-statements.ts +39 -15
- package/src/utils/format.ts +4 -9
- package/src/utils/fundamentals.ts +38 -16
- package/src/utils/fx-status.ts +30 -7
- package/src/utils/growth.ts +67 -0
- package/src/utils/keyboard.ts +6 -0
- package/src/utils/network-failure.ts +23 -0
- package/src/utils/options.ts +1 -1
- package/src/utils/report-timing.ts +2 -2
- package/src/utils/served-rates.ts +45 -0
- package/src/utils/text-wrap.ts +84 -3
- package/src/utils/zoned-date-time.ts +47 -22
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { DataTableColumn } from "../../../components";
|
|
2
|
-
import { dropColumnsToFit } from "../../../components/ui/table-layout";
|
|
2
|
+
import { dropColumnsToFit, getTableWidth } from "../../../components/ui/table-layout";
|
|
3
3
|
import { displayWidth } from "../../../utils/format";
|
|
4
4
|
import { compareSortValues, type SortDirection } from "../../../utils/sort-values";
|
|
5
5
|
import { AUCTION_HISTORY_ALL, AUCTION_HISTORY_DAYS, AUCTION_HISTORY_START, type AuctionHistoryWindow } from "./client";
|
|
@@ -53,10 +53,11 @@ export const AUCTION_SEARCH_FIELDS = "type, benchmark (10Y), term, CUSIP, or dat
|
|
|
53
53
|
|
|
54
54
|
export type AuctionColumnId =
|
|
55
55
|
| "date" | "type" | "term" | "rate" | "stopOut" | "btc" | "indirect" | "direct" | "dealer" | "size" | "cusip"
|
|
56
|
-
| "btcPctl" | "indirectPctl" | "dealerPctl" | "after1d" | "after5d" | "after20d";
|
|
56
|
+
| "stopOutPctl" | "btcPctl" | "indirectPctl" | "dealerPctl" | "after1d" | "after5d" | "after20d";
|
|
57
57
|
|
|
58
58
|
/** What the after view adds to a row: its percentiles and the yield's moves after it (after.ts). */
|
|
59
59
|
export interface AuctionAfterFigures {
|
|
60
|
+
stopOutPercentile: number | null;
|
|
60
61
|
btcPercentile: number | null;
|
|
61
62
|
indirectPercentile: number | null;
|
|
62
63
|
dealerPercentile: number | null;
|
|
@@ -67,6 +68,8 @@ export interface AuctionAfterFigures {
|
|
|
67
68
|
|
|
68
69
|
export interface AuctionColumn extends DataTableColumn {
|
|
69
70
|
id: AuctionColumnId;
|
|
71
|
+
/** TERM written short (9Y10M) where the full term would crowd out a figure. */
|
|
72
|
+
compact?: boolean;
|
|
70
73
|
}
|
|
71
74
|
|
|
72
75
|
export interface AuctionSortPreference {
|
|
@@ -95,7 +98,8 @@ export const AUCTION_SORT_COLUMN_IDS: readonly AuctionColumnId[] = [
|
|
|
95
98
|
|
|
96
99
|
/** The after view's columns, in the order [ and ] step through them. */
|
|
97
100
|
export const AUCTION_AFTER_SORT_COLUMN_IDS: readonly AuctionColumnId[] = [
|
|
98
|
-
"date", "type", "term", "rate", "
|
|
101
|
+
"date", "type", "term", "rate", "stopOut", "stopOutPctl", "btc", "btcPctl", "indirect", "indirectPctl", "dealerPctl",
|
|
102
|
+
"after1d", "after5d", "after20d", "cusip",
|
|
99
103
|
];
|
|
100
104
|
|
|
101
105
|
/** `--sort` as typed, and the column it sorts. */
|
|
@@ -111,6 +115,7 @@ export const AUCTION_SORT_NAMES: ReadonlyArray<{ value: string; column: AuctionC
|
|
|
111
115
|
{ value: "dealer", column: "dealer" },
|
|
112
116
|
{ value: "size", column: "size" },
|
|
113
117
|
{ value: "cusip", column: "cusip", aliases: ["issue"] },
|
|
118
|
+
{ value: "vs-median-pctl", column: "stopOutPctl", aliases: ["vs-med-pctl", "vs-avg-pctl", "stop-out-pctl", "vs-median-percentile"] },
|
|
114
119
|
{ value: "btc-pctl", column: "btcPctl", aliases: ["btc-percentile", "bc-pctl"] },
|
|
115
120
|
{ value: "indirect-pctl", column: "indirectPctl", aliases: ["indirect-percentile"] },
|
|
116
121
|
{ value: "dealer-pctl", column: "dealerPctl", aliases: ["dealer-percentile"] },
|
|
@@ -121,7 +126,7 @@ export const AUCTION_SORT_NAMES: ReadonlyArray<{ value: string; column: AuctionC
|
|
|
121
126
|
|
|
122
127
|
/** The after view's columns are its own; the results view's sort by its own. */
|
|
123
128
|
export const isAfterColumn = (column: AuctionColumnId) =>
|
|
124
|
-
column === "btcPctl" || column === "indirectPctl" || column === "dealerPctl" || column === "after1d" || column === "after5d" || column === "after20d";
|
|
129
|
+
column === "stopOutPctl" || column === "btcPctl" || column === "indirectPctl" || column === "dealerPctl" || column === "after1d" || column === "after5d" || column === "after20d";
|
|
125
130
|
|
|
126
131
|
export type AuctionFilter = "all" | "bill" | "note" | "bond";
|
|
127
132
|
|
|
@@ -434,6 +439,7 @@ function sortValue(auction: TreasuryAuction, columnId: AuctionColumnId, after?:
|
|
|
434
439
|
case "dealer": return dealerPct(auction);
|
|
435
440
|
case "size": return auctionSize(auction);
|
|
436
441
|
case "cusip": return auction.cusip;
|
|
442
|
+
case "stopOutPctl": return after?.stopOutPercentile ?? null;
|
|
437
443
|
case "btcPctl": return after?.btcPercentile ?? null;
|
|
438
444
|
case "indirectPctl": return after?.indirectPercentile ?? null;
|
|
439
445
|
case "dealerPctl": return after?.dealerPercentile ?? null;
|
|
@@ -470,18 +476,43 @@ export function firstAuctionSortDirection(columnId: AuctionColumnId): SortDirect
|
|
|
470
476
|
}
|
|
471
477
|
|
|
472
478
|
/**
|
|
473
|
-
* "Oct
|
|
474
|
-
*
|
|
479
|
+
* "13 Oct" is ambiguous once the rows span two calendar years ("10 Nov" of
|
|
480
|
+
* 2026 above "12 Nov" of 2025), so then every row is dated in full
|
|
481
|
+
* ("13 Oct 2026"), as every other table dates a day. A Hong Kong bond's issue
|
|
482
|
+
* month (2026-05) counts by its year.
|
|
475
483
|
*/
|
|
476
|
-
export function auctionDatesShowYear(
|
|
477
|
-
|
|
484
|
+
export function auctionDatesShowYear(dates: readonly string[]): boolean {
|
|
485
|
+
const first = dates[0]?.slice(0, 4);
|
|
486
|
+
return dates.some((date) => date.slice(0, 4) !== first);
|
|
478
487
|
}
|
|
479
488
|
|
|
489
|
+
/** A term written short: 9-Year 10-Month is 9Y10M, 13-Week 13W; a term this does not read stays as it is. */
|
|
490
|
+
export function compactTerm(term: string): string {
|
|
491
|
+
const parts = termParts(term);
|
|
492
|
+
if (!parts) return term;
|
|
493
|
+
return (["year", "month", "week", "day"] as const)
|
|
494
|
+
.filter((unit) => parts[unit])
|
|
495
|
+
.map((unit) => `${parts[unit]}${unit[0]!.toUpperCase()}`)
|
|
496
|
+
.join("");
|
|
497
|
+
}
|
|
498
|
+
|
|
499
|
+
/**
|
|
500
|
+
* The columns a narrow pane gives up, least needed first, after the CUSIP and
|
|
501
|
+
* after TERM is written short (9Y10M). The results view keeps its type and
|
|
502
|
+
* bidder split longest; the after view is read for its percentiles and the
|
|
503
|
+
* yield's moves after the auction, so +5D and +20D outlast the type, the
|
|
504
|
+
* dealer percentile and the raw figures beside each percentile.
|
|
505
|
+
*/
|
|
506
|
+
const RESULTS_DROP_ORDER: readonly AuctionColumnId[] = ["size", "type", "direct", "dealer", "indirect", "stopOut"];
|
|
507
|
+
const AFTER_DROP_ORDER: readonly AuctionColumnId[] = ["type", "dealerPctl", "indirect", "btc", "stopOut", "stopOutPctl", "after1d"];
|
|
508
|
+
|
|
480
509
|
/**
|
|
481
510
|
* Widths are the data's own; the table widens a column to its label plus the
|
|
482
511
|
* sort arrow. TERM is as wide as the longest term listed, and the CUSIP closes
|
|
483
|
-
* the row where the pane has room for it, taking what width is left
|
|
484
|
-
* too narrow for
|
|
512
|
+
* the row where the pane has room for it, taking what width is left. A pane
|
|
513
|
+
* too narrow for every column gives up the CUSIP, then writes TERM short,
|
|
514
|
+
* then drops whole columns in the view's order, so no column is ever cut at
|
|
515
|
+
* the pane's edge.
|
|
485
516
|
*/
|
|
486
517
|
export function buildAuctionColumns(options: {
|
|
487
518
|
showYear?: boolean;
|
|
@@ -491,23 +522,32 @@ export function buildAuctionColumns(options: {
|
|
|
491
522
|
width?: number;
|
|
492
523
|
} = {}): AuctionColumn[] {
|
|
493
524
|
const { showYear = false, view = "results", rows = [], width } = options;
|
|
494
|
-
const
|
|
525
|
+
const termWidth = (text: (term: string) => string) => Math.max(6, ...rows.map((auction) => displayWidth(text(auction.securityTerm))));
|
|
495
526
|
const lead: AuctionColumn[] = [
|
|
496
|
-
{ id: "date", label: "DATE", width: showYear ?
|
|
527
|
+
{ id: "date", label: "DATE", width: showYear ? 11 : 6, align: "left" },
|
|
497
528
|
{ id: "type", label: "TYPE", width: 6, align: "left" },
|
|
498
|
-
{ id: "term", label: "TERM", width: term, align: "left" },
|
|
529
|
+
{ id: "term", label: "TERM", width: termWidth((term) => term), align: "left" },
|
|
499
530
|
{ id: "rate", label: rateColumnLabel(rows, "pane"), width: 7, align: "right" },
|
|
500
531
|
];
|
|
532
|
+
const stopOut: AuctionColumn = {
|
|
533
|
+
id: "stopOut", label: stopOutColumnLabel(rows, "pane"), width: 7, align: "right", title: "Stop-out vs median yield (average before November 1998), bp",
|
|
534
|
+
};
|
|
535
|
+
const percentile = (id: AuctionColumnId, label: string, what: string): AuctionColumn => (
|
|
536
|
+
{ id, label, width: 4, align: "right", title: `${what} percentile against the tenor's last 24 auctions` }
|
|
537
|
+
);
|
|
501
538
|
const figures: AuctionColumn[] = view === "after" ? [
|
|
539
|
+
stopOut,
|
|
540
|
+
percentile("stopOutPctl", `${stopOutColumnLabel(rows, "pane").replace(/^VS /, "")} PCTL`, "Stop-out vs median"),
|
|
502
541
|
{ id: "btc", label: "B/C", width: 5, align: "right" },
|
|
503
|
-
|
|
504
|
-
{ id: "
|
|
505
|
-
|
|
542
|
+
percentile("btcPctl", "B/C PCTL", "Bid-to-cover"),
|
|
543
|
+
{ id: "indirect", label: "INDIRECT", width: 8, align: "right" },
|
|
544
|
+
percentile("indirectPctl", "IND PCTL", "Indirect share"),
|
|
545
|
+
percentile("dealerPctl", "DLR PCTL", "Dealer share"),
|
|
506
546
|
{ id: "after1d", label: "+1D BP", width: 5, align: "right", title: "Treasury yield change one session after the auction, bp" },
|
|
507
547
|
{ id: "after5d", label: "+5D BP", width: 5, align: "right", title: "Treasury yield change five sessions after the auction, bp" },
|
|
508
548
|
{ id: "after20d", label: "+20D BP", width: 5, align: "right", title: "Treasury yield change twenty sessions after the auction, bp" },
|
|
509
549
|
] : [
|
|
510
|
-
|
|
550
|
+
stopOut,
|
|
511
551
|
{ id: "btc", label: "B/C", width: 5, align: "right" },
|
|
512
552
|
{ id: "indirect", label: "INDIRECT", width: 8, align: "right" },
|
|
513
553
|
{ id: "direct", label: "DIRECT", width: 6, align: "right" },
|
|
@@ -516,9 +556,13 @@ export function buildAuctionColumns(options: {
|
|
|
516
556
|
];
|
|
517
557
|
const columns: AuctionColumn[] = [...lead, ...figures, { id: "cusip", label: "CUSIP", width: 9, align: "left", flexGrow: 1 }];
|
|
518
558
|
if (width == null) return columns;
|
|
519
|
-
|
|
559
|
+
let shown = dropColumnsToFit(columns, width, ["cusip"]);
|
|
560
|
+
if (shown.length === columns.length) return shown;
|
|
520
561
|
// Without the CUSIP nothing grows: the figures keep their places at the left.
|
|
521
|
-
|
|
562
|
+
shown = shown.map((column) => ({ ...column, flexGrow: undefined }));
|
|
563
|
+
if (getTableWidth(shown) <= width) return shown;
|
|
564
|
+
shown = shown.map((column) => column.id === "term" ? { ...column, width: termWidth(compactTerm), compact: true } : column);
|
|
565
|
+
return dropColumnsToFit(shown, width, view === "after" ? AFTER_DROP_ORDER : RESULTS_DROP_ORDER);
|
|
522
566
|
}
|
|
523
567
|
|
|
524
568
|
/**
|
|
@@ -535,7 +579,7 @@ function parseAuctionCommandArg(arg: string | undefined): {
|
|
|
535
579
|
historyDays?: AuctionHistoryWindow;
|
|
536
580
|
filter?: AuctionFilter;
|
|
537
581
|
view?: "results" | "after";
|
|
538
|
-
/** The sort's name as `--sort` takes it: "btc-pctl". */
|
|
582
|
+
/** The sort's name as `--sort` takes it: "btc-pctl", "-indirect-pctl". */
|
|
539
583
|
sort?: string;
|
|
540
584
|
} {
|
|
541
585
|
const tokens = (arg ?? "").trim().split(/\s+/).filter(Boolean);
|
|
@@ -561,8 +605,8 @@ function parseAuctionCommandArg(arg: string | undefined): {
|
|
|
561
605
|
} else if (name === "view") {
|
|
562
606
|
if (value === "results" || value === "after") parsed.view = value;
|
|
563
607
|
} else if (name === "sort") {
|
|
564
|
-
const sort =
|
|
565
|
-
const name = sort &&
|
|
608
|
+
const sort = parseAuctionSort(value);
|
|
609
|
+
const name = sort && auctionSortName(sort);
|
|
566
610
|
if (name) parsed.sort = name;
|
|
567
611
|
}
|
|
568
612
|
}
|
|
@@ -591,11 +635,45 @@ export function auctionCommandRequest(arg: string | undefined): {
|
|
|
591
635
|
}
|
|
592
636
|
|
|
593
637
|
/** The column `--sort` names, by its name or an alias; null for anything else. */
|
|
594
|
-
|
|
638
|
+
function auctionSortColumn(value: string): AuctionColumnId | null {
|
|
595
639
|
const name = value.trim().toLowerCase();
|
|
596
640
|
return AUCTION_SORT_NAMES.find((entry) => entry.value === name || entry.aliases?.includes(name))?.column ?? null;
|
|
597
641
|
}
|
|
598
642
|
|
|
643
|
+
const reverse = (direction: SortDirection): SortDirection => direction === "asc" ? "desc" : "asc";
|
|
644
|
+
|
|
645
|
+
/**
|
|
646
|
+
* A sort as `--sort` takes it: a column by its name or an alias, its own way
|
|
647
|
+
* first (largest first for a figure, newest first for date, A to Z for text),
|
|
648
|
+
* or the other way round after a `-` (`-indirect-pctl`: lowest first). Null
|
|
649
|
+
* for a name no column has.
|
|
650
|
+
*/
|
|
651
|
+
export function parseAuctionSort(value: string): AuctionSortPreference | null {
|
|
652
|
+
const text = value.trim().toLowerCase();
|
|
653
|
+
const reversed = text.startsWith("-");
|
|
654
|
+
const columnId = auctionSortColumn(reversed ? text.slice(1) : text);
|
|
655
|
+
if (!columnId) return null;
|
|
656
|
+
const first = firstAuctionSortDirection(columnId);
|
|
657
|
+
return { columnId, direction: reversed ? reverse(first) : first };
|
|
658
|
+
}
|
|
659
|
+
|
|
660
|
+
/** A sort's name as `--sort` writes it: `indirect-pctl`, `-indirect-pctl` the other way round; null for a column with none. */
|
|
661
|
+
export function auctionSortName(sort: AuctionSortPreference): string | null {
|
|
662
|
+
const name = AUCTION_SORT_NAMES.find((entry) => entry.column === sort.columnId)?.value;
|
|
663
|
+
if (!name) return null;
|
|
664
|
+
return sort.direction === firstAuctionSortDirection(sort.columnId) ? name : `-${name}`;
|
|
665
|
+
}
|
|
666
|
+
|
|
667
|
+
/** `--sort` as typed, as its canonical name (`-btc` for `-b/c`); throws naming the names it takes. */
|
|
668
|
+
export function normalizeAuctionSortOption(value: string): string {
|
|
669
|
+
const sort = parseAuctionSort(value);
|
|
670
|
+
const name = sort && auctionSortName(sort);
|
|
671
|
+
if (!name) {
|
|
672
|
+
throw new Error(`Invalid --sort value "${value}". Use one of: ${AUCTION_SORT_NAMES.map((entry) => entry.value).join(", ")}; a leading - sorts the other way (-indirect-pctl: lowest first).`);
|
|
673
|
+
}
|
|
674
|
+
return name;
|
|
675
|
+
}
|
|
676
|
+
|
|
599
677
|
/** A query for a market AUCT does not cover: another country's government paper. */
|
|
600
678
|
const NON_US_PAPER = /\b(jgb|jgbs|gilt|gilts|bund|bunds|bobl|schatz|oat|oats|btp|btps|bono|bonos|acgb|cgb|cgbs|ktb|ktbs|sgs|btf|euro|eur|gbp|jpy|uk|japan|japanese|german|germany|france|french|italy|italian|spain|canada|canadian|australia|australian|china|chinese|korea|singapore|india|indian|brazil|mexico)\b/i;
|
|
601
679
|
|
|
@@ -20,14 +20,16 @@ import { usePaneInstance } from "../../../state/app/context";
|
|
|
20
20
|
import { colors } from "../../../theme/colors";
|
|
21
21
|
import type { PaneProps } from "../../../types/plugin";
|
|
22
22
|
import { Box, ScrollBox, Text, TextAttributes } from "../../../ui";
|
|
23
|
-
import { formatCompact } from "../../../utils/format";
|
|
23
|
+
import { MISSING_VALUE, formatCompact } from "../../../utils/format";
|
|
24
24
|
import { isPlainKey } from "../../../utils/keyboard";
|
|
25
25
|
import { formatRelativeAge, formatShortDate } from "../../../utils/datetime-format";
|
|
26
26
|
import { isPlainArrowUp, stopSearchFocusNavigation } from "../../../utils/search-focus-navigation";
|
|
27
27
|
import { cycleSortPreference, nextHeaderSort } from "../../../utils/sort-values";
|
|
28
28
|
import { usePluginPaneState } from "../../runtime";
|
|
29
29
|
import { useAsyncResource } from "../../../react/async-resource";
|
|
30
|
-
import { useAutoRefresh } from "../../../react/auto-refresh";
|
|
30
|
+
import { useAutoRefresh, useUtcDay } from "../../../react/auto-refresh";
|
|
31
|
+
import { reportFooterSegment } from "../shared/source-footer";
|
|
32
|
+
import { treasuryAuctionsHeadless } from "./headless";
|
|
31
33
|
import { useCommandValue } from "../shared/command-tab";
|
|
32
34
|
import { FIXED_INCOME_PANE_ID } from "../fixed-income/model";
|
|
33
35
|
import {
|
|
@@ -46,8 +48,8 @@ import {
|
|
|
46
48
|
auctionHistoryPhrase,
|
|
47
49
|
auctionHistoryWindow,
|
|
48
50
|
auctionSize,
|
|
49
|
-
auctionSortColumn,
|
|
50
51
|
buildAuctionColumns,
|
|
52
|
+
compactTerm,
|
|
51
53
|
dealerPct,
|
|
52
54
|
directPct,
|
|
53
55
|
firstAuctionSortDirection,
|
|
@@ -58,6 +60,7 @@ import {
|
|
|
58
60
|
isPendingAuction,
|
|
59
61
|
nextAuctionHistoryWindow,
|
|
60
62
|
nextFilter,
|
|
63
|
+
parseAuctionSort,
|
|
61
64
|
rateLabel,
|
|
62
65
|
rateValue,
|
|
63
66
|
middleRateLabel,
|
|
@@ -76,9 +79,10 @@ import {
|
|
|
76
79
|
} from "./types";
|
|
77
80
|
import { AUCTION_MARKETS, isAuctionMarket, type AuctionMarket } from "./hk";
|
|
78
81
|
import { HkTendersView } from "./hk-view";
|
|
82
|
+
import { auctionViewHints } from "./keys";
|
|
79
83
|
|
|
80
84
|
function formatRate(value: number | null): string {
|
|
81
|
-
return value == null ?
|
|
85
|
+
return value == null ? MISSING_VALUE : `${value.toFixed(3)}%`;
|
|
82
86
|
}
|
|
83
87
|
|
|
84
88
|
/**
|
|
@@ -87,18 +91,18 @@ function formatRate(value: number | null): string {
|
|
|
87
91
|
* 2008-04-07. "—" stays for an announced auction whose results are not out yet.
|
|
88
92
|
*/
|
|
89
93
|
function formatRatio(value: number | null, auction?: TreasuryAuction): string {
|
|
90
|
-
if (value == null) return auction && !isPendingAuction(auction) ? "" :
|
|
94
|
+
if (value == null) return auction && !isPendingAuction(auction) ? "" : MISSING_VALUE;
|
|
91
95
|
return value.toFixed(2);
|
|
92
96
|
}
|
|
93
97
|
|
|
94
98
|
function formatPct(value: number | null, auction?: TreasuryAuction): string {
|
|
95
|
-
if (value == null) return auction && !isPendingAuction(auction) ? "" :
|
|
99
|
+
if (value == null) return auction && !isPendingAuction(auction) ? "" : MISSING_VALUE;
|
|
96
100
|
return `${value.toFixed(1)}%`;
|
|
97
101
|
}
|
|
98
102
|
|
|
99
103
|
/** The stop-out against the median reads in basis points, like an FRN margin. */
|
|
100
104
|
function formatBp(value: number | null): string {
|
|
101
|
-
return value == null ?
|
|
105
|
+
return value == null ? MISSING_VALUE : `${value.toFixed(1)}bp`;
|
|
102
106
|
}
|
|
103
107
|
|
|
104
108
|
/** A yield's move after the auction, in whole bp under a header that says bp; blank until the session is in. */
|
|
@@ -109,7 +113,7 @@ function formatMove(value: number | null): string {
|
|
|
109
113
|
const VIEW_OPTIONS = AUCTION_VIEWS.map((value) => ({ value, label: value === "after" ? "After" : "Results" }));
|
|
110
114
|
|
|
111
115
|
function formatMoney(value: number | null): string {
|
|
112
|
-
return value == null ?
|
|
116
|
+
return value == null ? MISSING_VALUE : `$${formatCompact(value)}`;
|
|
113
117
|
}
|
|
114
118
|
|
|
115
119
|
function secTypeColor(secType: string, selected: boolean): string {
|
|
@@ -132,6 +136,10 @@ function secTypeColor(secType: string, selected: boolean): string {
|
|
|
132
136
|
/** An announced auction's Rate in the table, the word other panes use for a figure not out yet (KPI's Later actual). */
|
|
133
137
|
const RESULTS_PENDING = "Pending";
|
|
134
138
|
|
|
139
|
+
const PERCENTILE_KEYS = {
|
|
140
|
+
stopOutPctl: "stopOutPercentile", btcPctl: "btcPercentile", indirectPctl: "indirectPercentile", dealerPctl: "dealerPercentile",
|
|
141
|
+
} as const;
|
|
142
|
+
|
|
135
143
|
// Stable table adapter so memoized rows survive pane re-renders.
|
|
136
144
|
const auctionKey = (auction: TreasuryAuction) => auction.id;
|
|
137
145
|
|
|
@@ -150,7 +158,7 @@ function renderAuctionCell(
|
|
|
150
158
|
// Announced auctions have no results yet: Rate reads Pending, the other
|
|
151
159
|
// metric cells "—", and the date is bright.
|
|
152
160
|
return {
|
|
153
|
-
text:
|
|
161
|
+
text: formatShortDate(auction.auctionDate, { year: showYear ? "numeric" : false, utc: true, fallback: MISSING_VALUE }),
|
|
154
162
|
color: rowState.selected ? colors.selectedText : isPendingAuction(auction) ? colors.textBright : colors.textDim,
|
|
155
163
|
};
|
|
156
164
|
case "type":
|
|
@@ -160,12 +168,12 @@ function renderAuctionCell(
|
|
|
160
168
|
attributes: TextAttributes.BOLD,
|
|
161
169
|
};
|
|
162
170
|
case "term":
|
|
163
|
-
return { text: auction.securityTerm, color: selected ?? colors.text };
|
|
171
|
+
return { text: column.compact ? compactTerm(auction.securityTerm) : auction.securityTerm, color: selected ?? colors.text };
|
|
164
172
|
case "rate":
|
|
165
173
|
// An announced auction says its results are pending, as its detail does; other metric cells stay "—".
|
|
166
174
|
return isPendingAuction(auction)
|
|
167
175
|
? { text: RESULTS_PENDING, color: dimmed }
|
|
168
|
-
: { text: formatAuctionRate(auction, rateValue(auction),
|
|
176
|
+
: { text: formatAuctionRate(auction, rateValue(auction), MISSING_VALUE), color: selected ?? colors.textBright };
|
|
169
177
|
case "stopOut":
|
|
170
178
|
return { text: formatBp(stopOutVsAvgBp(auction)), color: selected ?? colors.text };
|
|
171
179
|
case "btc":
|
|
@@ -180,10 +188,11 @@ function renderAuctionCell(
|
|
|
180
188
|
return { text: formatMoney(auctionSize(auction)), color: dimmed };
|
|
181
189
|
case "cusip":
|
|
182
190
|
return { text: auction.cusip ?? "", color: dimmed };
|
|
191
|
+
case "stopOutPctl":
|
|
183
192
|
case "btcPctl":
|
|
184
193
|
case "indirectPctl":
|
|
185
194
|
case "dealerPctl": {
|
|
186
|
-
const key = column.id
|
|
195
|
+
const key = PERCENTILE_KEYS[column.id];
|
|
187
196
|
const value = after?.[key] ?? null;
|
|
188
197
|
return { text: value == null ? "" : String(value), value, color: selected ?? colors.text };
|
|
189
198
|
}
|
|
@@ -206,12 +215,12 @@ function TreasuryAuctionDetail({ auction, width, after }: { auction: TreasuryAuc
|
|
|
206
215
|
<ScrollBox flexGrow={1} scrollY>
|
|
207
216
|
<Box flexDirection="column" paddingX={1} width={width}>
|
|
208
217
|
<Box flexDirection="row" height={1} gap={2}>
|
|
209
|
-
<Text fg={colors.textDim}>{formatShortDate(auction.auctionDate, { utc: true, fallback:
|
|
218
|
+
<Text fg={colors.textDim}>{formatShortDate(auction.auctionDate, { utc: true, fallback: MISSING_VALUE })}</Text>
|
|
210
219
|
{isPendingAuction(auction) && <Text fg={colors.textDim}>results pending</Text>}
|
|
211
220
|
{auction.cusip && <Text fg={colors.textDim}>{auction.cusip}</Text>}
|
|
212
221
|
</Box>
|
|
213
222
|
<Box height={1} />
|
|
214
|
-
<KeyValueRow labelWidth={22} width={Math.max(1, width - 2)} emphasis={false} label={rateLabel(auction)} value={formatAuctionRate(auction, rateValue(auction),
|
|
223
|
+
<KeyValueRow labelWidth={22} width={Math.max(1, width - 2)} emphasis={false} label={rateLabel(auction)} value={formatAuctionRate(auction, rateValue(auction), MISSING_VALUE)} />
|
|
215
224
|
{isBill(auction) && auction.highDiscountRate != null && (
|
|
216
225
|
<KeyValueRow labelWidth={22} width={Math.max(1, width - 2)} emphasis={false} label="High discount rate" value={formatRate(auction.highDiscountRate)} />
|
|
217
226
|
)}
|
|
@@ -226,9 +235,9 @@ function TreasuryAuctionDetail({ auction, width, after }: { auction: TreasuryAuc
|
|
|
226
235
|
)}
|
|
227
236
|
<KeyValueRow labelWidth={22} width={Math.max(1, width - 2)} emphasis={false} label="Bid-to-cover" value={formatRatio(auction.bidToCoverRatio)} />
|
|
228
237
|
<Box height={1} />
|
|
229
|
-
<KeyValueRow labelWidth={22} width={Math.max(1, width - 2)} emphasis={false} label="High price" value={auction.highPrice?.toFixed(4) ??
|
|
230
|
-
<KeyValueRow labelWidth={22} width={Math.max(1, width - 2)} emphasis={false} label={publishesMedian(auction) ? "Median price" : "Average price"} value={auction.avgMedPrice?.toFixed(4) ??
|
|
231
|
-
<KeyValueRow labelWidth={22} width={Math.max(1, width - 2)} emphasis={false} label="Low price" value={auction.lowPrice?.toFixed(4) ??
|
|
238
|
+
<KeyValueRow labelWidth={22} width={Math.max(1, width - 2)} emphasis={false} label="High price" value={auction.highPrice?.toFixed(4) ?? MISSING_VALUE} />
|
|
239
|
+
<KeyValueRow labelWidth={22} width={Math.max(1, width - 2)} emphasis={false} label={publishesMedian(auction) ? "Median price" : "Average price"} value={auction.avgMedPrice?.toFixed(4) ?? MISSING_VALUE} />
|
|
240
|
+
<KeyValueRow labelWidth={22} width={Math.max(1, width - 2)} emphasis={false} label="Low price" value={auction.lowPrice?.toFixed(4) ?? MISSING_VALUE} />
|
|
232
241
|
<Box height={1} />
|
|
233
242
|
<KeyValueRow labelWidth={22} width={Math.max(1, width - 2)} emphasis={false} label="Offering" value={formatMoney(auction.offeringAmount)} />
|
|
234
243
|
<KeyValueRow labelWidth={22} width={Math.max(1, width - 2)} emphasis={false} label="Total accepted" value={formatMoney(auction.totalAccepted)} />
|
|
@@ -238,12 +247,16 @@ function TreasuryAuctionDetail({ auction, width, after }: { auction: TreasuryAuc
|
|
|
238
247
|
<KeyValueRow labelWidth={22} width={Math.max(1, width - 2)} emphasis={false} label="Primary dealer" value={share(auction.primaryDealerAccepted, auction.competitiveAccepted)} />
|
|
239
248
|
{after && <>
|
|
240
249
|
<Box height={1} />
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
250
|
+
{stopOutVsAvgBp(auction) != null && (
|
|
251
|
+
<KeyValueRow labelWidth={22} width={Math.max(1, width - 2)} emphasis={false} label={`${stopOutLabel(auction)} pctl`}
|
|
252
|
+
value={after.stopOutPercentile == null ? MISSING_VALUE : String(after.stopOutPercentile)} />
|
|
253
|
+
)}
|
|
254
|
+
<KeyValueRow labelWidth={22} width={Math.max(1, width - 2)} emphasis={false} label="B/C percentile" value={after.btcPercentile == null ? MISSING_VALUE : String(after.btcPercentile)} />
|
|
255
|
+
<KeyValueRow labelWidth={22} width={Math.max(1, width - 2)} emphasis={false} label="Indirect percentile" value={after.indirectPercentile == null ? MISSING_VALUE : String(after.indirectPercentile)} />
|
|
256
|
+
<KeyValueRow labelWidth={22} width={Math.max(1, width - 2)} emphasis={false} label="Dealer percentile" value={after.dealerPercentile == null ? MISSING_VALUE : String(after.dealerPercentile)} />
|
|
244
257
|
{after.cmt && ([[1, after.after1d], [5, after.after5d], [20, after.after20d]] as const).map(([sessions, value]) => (
|
|
245
258
|
<KeyValueRow key={sessions} labelWidth={22} width={Math.max(1, width - 2)} emphasis={false}
|
|
246
|
-
label={`${after.cmt} yield +${sessions}d`} value={value == null ?
|
|
259
|
+
label={`${after.cmt} yield +${sessions}d`} value={value == null ? MISSING_VALUE : `${formatMove(value)}bp`} />
|
|
247
260
|
))}
|
|
248
261
|
</>}
|
|
249
262
|
</Box>
|
|
@@ -253,13 +266,17 @@ function TreasuryAuctionDetail({ auction, width, after }: { auction: TreasuryAuc
|
|
|
253
266
|
|
|
254
267
|
const NO_AUCTIONS: TreasuryAuction[] = [];
|
|
255
268
|
|
|
256
|
-
/**
|
|
269
|
+
/**
|
|
270
|
+
* A sort as kept in pane state and typed after --sort: the column's name, `-`
|
|
271
|
+
* first for the other way round (`-indirect-pctl`, lowest first), and `:asc`
|
|
272
|
+
* or `:desc` once the pane flips it.
|
|
273
|
+
*/
|
|
257
274
|
function readSort(value: string | null): AuctionSortPreference | null {
|
|
258
275
|
if (!value) return null;
|
|
259
276
|
const [name, direction] = value.split(":");
|
|
260
|
-
const
|
|
261
|
-
if (!
|
|
262
|
-
return
|
|
277
|
+
const sort = parseAuctionSort(name ?? "");
|
|
278
|
+
if (!sort) return null;
|
|
279
|
+
return direction === "asc" || direction === "desc" ? { columnId: sort.columnId, direction } : sort;
|
|
263
280
|
}
|
|
264
281
|
|
|
265
282
|
function writeSort(sort: AuctionSortPreference): string | null {
|
|
@@ -393,6 +410,8 @@ function UsAuctionsView({
|
|
|
393
410
|
const columns = next === "after" ? AUCTION_AFTER_SORT_COLUMN_IDS : AUCTION_SORT_COLUMN_IDS;
|
|
394
411
|
if (!columns.includes(sortPreference.columnId)) setSortValue(null);
|
|
395
412
|
}, [setSortValue, setView, sortPreference.columnId]);
|
|
413
|
+
const toggleView = useCallback(() => selectView(view === "after" ? "results" : "after"), [selectView, view]);
|
|
414
|
+
const toggleMarket = useCallback(() => marketFilter.onChange("hk"), [marketFilter]);
|
|
396
415
|
|
|
397
416
|
usePaneRefreshKey(() => resource.reload(), { focused, enabled: !searchFocused });
|
|
398
417
|
|
|
@@ -422,7 +441,7 @@ function UsAuctionsView({
|
|
|
422
441
|
return handlePaneKey(event);
|
|
423
442
|
}, [focusSearch, handlePaneKey]);
|
|
424
443
|
|
|
425
|
-
const showYear = auctionDatesShowYear(
|
|
444
|
+
const showYear = useMemo(() => auctionDatesShowYear(rows.map((auction) => auction.auctionDate)), [rows]);
|
|
426
445
|
// A table that scrolls down keeps a cell for its scrollbar.
|
|
427
446
|
const columns = useMemo(() => buildAuctionColumns({ showYear, view, rows, width: width - 1 }), [rows, showYear, view, width]);
|
|
428
447
|
const renderAuctionRow = useCallback((
|
|
@@ -432,12 +451,15 @@ function UsAuctionsView({
|
|
|
432
451
|
rowState: { selected: boolean },
|
|
433
452
|
) => renderAuctionCell(auction, column, rowState, showYear, after?.get(auction.id)), [after, showYear]);
|
|
434
453
|
|
|
454
|
+
const utcDay = useUtcDay();
|
|
435
455
|
usePaneFooter(TREASURY_AUCTIONS_PANE_ID, () => {
|
|
436
456
|
const info = loadingErrorFooterInfo(loading, error);
|
|
437
457
|
if (yieldsError) info.push({ id: "yields", parts: [{ text: "Treasury yields unavailable", tone: "warning" as const }] });
|
|
438
458
|
if (savedAt != null) info.push(...savedCopyFooterInfo([savedAt]));
|
|
439
459
|
else if (stale) info.push(STALE_SEGMENT);
|
|
440
460
|
if (fetchedAt && savedAt == null) {
|
|
461
|
+
// Its source and the newest auction listed, as `fn AUCT` ends; how long ago it loaded goes first on a narrow row.
|
|
462
|
+
if (rows.length) info.push(reportFooterSegment(treasuryAuctionsHeadless, { rows: rows.map((auction) => ({ auctionDate: auction.auctionDate })) }));
|
|
441
463
|
info.push(ageFooterSegment(formatRelativeAge(fetchedAt)));
|
|
442
464
|
}
|
|
443
465
|
return {
|
|
@@ -447,24 +469,30 @@ function UsAuctionsView({
|
|
|
447
469
|
: [
|
|
448
470
|
{ id: "search", key: "/", label: "search", onPress: focusSearch },
|
|
449
471
|
{ id: "filter", key: "f", label: "ilter", onPress: cycleFilter },
|
|
472
|
+
...auctionViewHints({ view, toggleView, market: "us", toggleMarket, cycleSort }),
|
|
450
473
|
],
|
|
451
474
|
};
|
|
452
475
|
}, [
|
|
453
476
|
auctions.length,
|
|
454
477
|
cycleFilter,
|
|
478
|
+
cycleSort,
|
|
479
|
+
toggleMarket,
|
|
480
|
+
toggleView,
|
|
481
|
+
view,
|
|
455
482
|
detailOpen,
|
|
456
483
|
error,
|
|
457
484
|
yieldsError,
|
|
458
485
|
fetchedAt,
|
|
459
486
|
focusSearch,
|
|
460
487
|
loading,
|
|
488
|
+
rows,
|
|
461
489
|
savedAt,
|
|
462
490
|
stale,
|
|
491
|
+
utcDay,
|
|
463
492
|
]);
|
|
464
493
|
|
|
465
|
-
// The pane menu names the
|
|
494
|
+
// The footer's [] steps to the next sort column; the pane menu names the way back. "Sort by…" there picks a column directly.
|
|
466
495
|
usePaneMenuItems("treasury-auctions:sort-keys", () => detailOpen || auctions.length === 0 ? null : [
|
|
467
|
-
{ id: "sort-next", label: "Next Sort Column", accelerator: "]", onSelect: () => cycleSort(1) },
|
|
468
496
|
{ id: "sort-previous", label: "Previous Sort Column", accelerator: "[", onSelect: () => cycleSort(-1) },
|
|
469
497
|
], [auctions.length, cycleSort, detailOpen]);
|
|
470
498
|
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { MISSING_VALUE } from "../../../utils/format";
|
|
1
2
|
import { ApiRequestError } from "../../../api-client/errors";
|
|
2
3
|
import { createThrottledFetch } from "../../../utils/throttled-fetch";
|
|
3
4
|
import { inClearingOrder } from "./client";
|
|
@@ -83,7 +84,7 @@ export function normalizeDirectAuction(raw: unknown): TreasuryAuction | null {
|
|
|
83
84
|
id: `${cusip}|${auctionDate}`,
|
|
84
85
|
cusip,
|
|
85
86
|
secType: text(record.inflationProtected) === "Yes" ? "TIPS" : text(record.floatingRate) === "Yes" ? "FRN" : securityType,
|
|
86
|
-
securityTerm: text(record.securityTerm) ||
|
|
87
|
+
securityTerm: text(record.securityTerm) || MISSING_VALUE,
|
|
87
88
|
auctionDate,
|
|
88
89
|
highInvestmentRate: toNumber(record.investmentRate),
|
|
89
90
|
// A bill's `highRate` is its discount rate; a note or bond states its coupon elsewhere.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { DataTableColumn } from "../../../components";
|
|
2
|
-
import { formatNumber } from "../../../utils/format";
|
|
2
|
+
import { MISSING_VALUE, formatNumber } from "../../../utils/format";
|
|
3
3
|
|
|
4
4
|
export const TREASURY_DAILY_PANE_ID = "treasury-daily";
|
|
5
5
|
|
|
@@ -100,7 +100,7 @@ export const DEBT_COLUMNS: DebtColumn[] = [
|
|
|
100
100
|
|
|
101
101
|
/** Two decimals with thousands separators, as every money table writes a large figure: `2,594.63`. */
|
|
102
102
|
function scaled(value: unknown, divisor: number): string {
|
|
103
|
-
if (typeof value !== "number" || !Number.isFinite(value)) return
|
|
103
|
+
if (typeof value !== "number" || !Number.isFinite(value)) return MISSING_VALUE;
|
|
104
104
|
const rounded = Number((value / divisor).toFixed(2));
|
|
105
105
|
return formatNumber(rounded === 0 ? 0 : rounded, 2);
|
|
106
106
|
}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { MISSING_VALUE } from "../../../utils/format";
|
|
1
2
|
import type { apiClient as cloudApiClient } from "../../../api-client";
|
|
2
3
|
import type { InstrumentRef } from "../../../market-data/request-types";
|
|
3
4
|
import type { DataProvider } from "../../../types/data-provider";
|
|
@@ -133,15 +134,15 @@ export function surfaceEventReadings(expiries: readonly SurfaceExpiry[], catalog
|
|
|
133
134
|
});
|
|
134
135
|
}
|
|
135
136
|
|
|
136
|
-
const percent = (value: number | null | undefined, digits = 2) => value == null ?
|
|
137
|
+
const percent = (value: number | null | undefined, digits = 2) => value == null ? MISSING_VALUE : `${(value * 100).toFixed(digits)}%`;
|
|
137
138
|
/** The implied move is an estimate: "≈1.01%". */
|
|
138
|
-
export const approximatePercent = (value: number | null | undefined) => value == null ?
|
|
139
|
+
export const approximatePercent = (value: number | null | undefined) => value == null ? MISSING_VALUE : `≈${percent(value)}`;
|
|
139
140
|
|
|
140
141
|
/** MDAY's average absolute move on each release's days: "1.01%", or "1.01/0.98%" for two releases read together. */
|
|
141
142
|
export function surfaceEventHistory(events: readonly SurfaceEvent[]): string {
|
|
142
143
|
const moves = events.map((event) => event.history?.meanAbs);
|
|
143
|
-
if (moves.every((move) => move == null)) return
|
|
144
|
-
return moves.length === 1 ? percent(moves[0]) : `${moves.map((move) => move == null ?
|
|
144
|
+
if (moves.every((move) => move == null)) return MISSING_VALUE;
|
|
145
|
+
return moves.length === 1 ? percent(moves[0]) : `${moves.map((move) => move == null ? MISSING_VALUE : (move * 100).toFixed(2)).join("/")}%`;
|
|
145
146
|
}
|
|
146
147
|
|
|
147
148
|
/** One line for a narrow pane: "fwd 17.0% · move ≈1.01% · MDAY 1.01%". */
|