Skip to content
Snippets Groups Projects

Insights/fix-series-toggle

Merged Warren Gifford requested to merge insights/fix-series-toggle into main

Created by: unclejustin

Closes https://github.com/sourcegraph/sourcegraph/issues/36461

Before this PR clicking on all series toggled them to "on" but then clicking a series again toggle just that series "off". This felt misleading because clicking all fo the series "on" implies resetting the chart to the default state. Such that clicking a series from here, should only display that series.

This PR clears out the selections when all series have been "toggled on" so that the default state is reset correctly.

Test plan

  • Added unit test confirming deselecting of series when all series have been selected
  • Open storybook
  • Go to "Smart Insights View Grid Example"
  • Use "Backend insight #2 (closed)"
  • Click first legend item
  • Only that series is shown
  • Click second legend item
  • Both series are shown
  • Click third legend item
  • All three series shown
  • Click first legend item again
  • Only that series shown

App preview:

Check out the client app preview documentation to learn more.

Merge request reports

Merged by avatar (Apr 13, 2025 9:07am UTC)

Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
Please register or sign in to reply
Loading