Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mixed state checkbox example does not correctly recall previous mixed state in some scenarios #486

Closed
mcking65 opened this issue Oct 18, 2017 · 1 comment
Assignees
Labels
bug Code defects; not for inaccurate prose Example Page Related to a page containing an example implementation of a pattern Feedback Issue raised by or for collecting input from people outside APG task force

Comments

@mcking65
Copy link
Contributor

mcking65 commented Oct 18, 2017

The mixed state checkbox example does not correctly recall the last mixed state of checkboxes if the mixed state was created by changing the state of controlled checkboxes from the all checked or no checked states.

The code should record the set of checkbox states any time the master checkbox is in the mixed state, regardless of what event caused it to get to that state. Then, restore that state any time the master checkbox is in the unchecked state and it is activated to go back to the mixed state.

Example tests 1:

  1. Load page.
  2. Check master all so all boxes are checked.
  3. Uncheck tomato so master is in mixed state.
  4. check master to return to all checked state.
  5. Check master 2 more times; should return to state in step 3.

Example test 2:

  1. Load page.
  2. Check master all so all boxes are checked.
  3. Check master so no boxes are checked.
  4. Check one or more boxes so master is in mixed state.
  5. check master to return to all checked state.
  6. Check master 2 more times to return to mixed state; should return to states in step 3.

Issue reported by @racer2207 and @annabbott in issue #471.

@mcking65 mcking65 added Example Page Related to a page containing an example implementation of a pattern Feedback Issue raised by or for collecting input from people outside APG task force bug Code defects; not for inaccurate prose labels Oct 18, 2017
@mcking65 mcking65 added this to the 1.1 APG Release 1 milestone Oct 18, 2017
mcking65 pushed a commit that referenced this issue Oct 27, 2017
… is mixed (pull #491)

Fix issue #486 by adding a procedure to update individual checkbox states when master is mixed.
@mcking65
Copy link
Contributor Author

This is fixed with ca272bf and thanks to @gerardkcohen!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Code defects; not for inaccurate prose Example Page Related to a page containing an example implementation of a pattern Feedback Issue raised by or for collecting input from people outside APG task force
Projects
None yet
Development

No branches or pull requests

2 participants