Skip to content

share-card modal: scope dropdowns for chain/region/venue/kind - #1547

Merged
Flotapponnier merged 5 commits into
devfrom
feat/share-modal-scope-picker
Jul 27, 2026
Merged

share-card modal: scope dropdowns for chain/region/venue/kind#1547
Flotapponnier merged 5 commits into
devfrom
feat/share-modal-scope-picker

Conversation

@Flotapponnier

Copy link
Copy Markdown
Collaborator

Summary

  • Adds a scope picker row inside the export-as-image modal so readers can override chain / region / venue / kind without leaving the modal
  • Only dimensions the bench actually declares get a dropdown (chain-less benches never see a chain dropdown)
  • Pings /api/stat/? on each pick and warns the reader when the chosen cell has no data (endpoint returns 404 on unknown filter combos, exactly the signal we need)
  • Modal opens pre-filled from window.location so the dropdowns match what the reader was filtering on the dashboard; values that vanished between deploys coerce back to "All" instead of a broken picker

Test plan

  • Open the export modal on a bench with dimensions (e.g. /benchmarks/rpc-latency): dropdowns render for chain + region
  • Open it on a bench without dimensions (e.g. /benchmarks/bridge-revenue equivalent): no dropdowns render
  • Pick an empty combo: amber "No data for this scope" hint appears; PNG still generates (server falls back to aggregate)
  • Pick a valid combo: preview refreshes, PNG downloads with the right pill label

@Flotapponnier
Flotapponnier merged commit 8c4c6c5 into dev Jul 27, 2026
1 check failed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant