Repository navigation
fix(insights): adaptive Y-axis on the Brand vs Competitors chart - #37
Merged
Merged
Conversation
Visibility scores are theoretically 0-100 but realistic values for most brands cluster in the 5-30 band. Pinning the Y-axis to 100 made every bar look uniformly stubby and killed the perceived difference between, say, 8 and 22 — the chart was filling ~15% of its canvas and bar-to-bar comparison was effectively unreadable. Now the Y-axis rescales upward with 30% headroom, snapped to a "nice" tick (20 / 25 / 30 / 40 / 50 / 60 / 80 / 100) so gridlines stay clean. A floor of 20 keeps very low values from looking absurdly zoomed (a 3-point chart shouldn't fill the canvas either). The "%" suffix on tick labels is kept as-is for this change — that label is a separate copy concern. Only applies to CompetitorChart for now; VisibilityTrend and SoVTrend still pin to 0-100 and can adopt the same helper later.
Merged
This branch was successfully deployed
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.
Summary
Before / after
Scope
Test plan