Filter by country when clicking the world map - #464
Open
smehmood wants to merge 1 commit into
Open
Conversation
Clicking a country on the world map now applies the same country=eq.XX filter that the country metrics table produces. Clicking the currently selected country clears the filter, and the selected country renders in the full base color so the active selection is visible on the map. Only countries with data are clickable (cursor: pointer); clicks that are the tail end of a pan/drag are ignored. Filtering is disabled on the realtime map, which does not read query filters. Run-on: Niteshift Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
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.
Clicking a country on the world map now applies the same
country=eq.XXfilter that the country metrics table already produces, so the whole page (metrics, chart, tables) narrows to that country.Behavior
Country Is <name>chip appears in the filter bar.cursor: pointer); countries with no data are inert.allowFilter={false}), which doesn't read query filters.Verification
Verified in the browser on the Hulu website overview: clicking the US set
?country=eq.US, the filter chip and filtered metrics (2.76k visitors, Countries table showing only United States at 100%) appeared, the map highlighted the US, clicking it again cleared the filter, and clicking a country with no data or dragging the map did nothing.🤖 Generated with Claude Code
🌒 Run on Niteshift: View Task