Skip to content

Conversation

@psybuzz
Copy link
Contributor

@psybuzz psybuzz commented Sep 11, 2019

The run selector has a toggle all runs button. Before, toggleAll()'s intent is to toggle everything off when the user hasn't interacted with the list and the list is short (<40, everything selected by default). This logic was broken in [1], which renamed "maxRunsToEnableByDefault" to "maxNamesToEnableByDefault", except for one callsite (causing issue #2614).

This PR fixes the issue and simplifies toggleAll() to rely on "this.outSelected", which already represents the computed selected state.

[1] aacd5cb

Copy link
Contributor

@wchargin wchargin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice! Confirmed that the toggle state works correctly from a directory
with 4 runs (default on, toggles off with one click) and a directory
with 188 runs (default off, toggles on with one click).

@psybuzz psybuzz changed the title ui: fix run selector toggle all with many items #2614 ui: fix run selector toggle all with many items Sep 11, 2019
@psybuzz psybuzz requested a review from stephanwlee September 11, 2019 03:16
@psybuzz
Copy link
Contributor Author

psybuzz commented Sep 11, 2019

Thanks for the review! Adding Stephan fyi, and landing!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants