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

feat(nav-bar-functionality): Store expanded nav state in AssessmentStore and toggle nav link expansion state #2768

Merged
merged 9 commits into from
Jun 1, 2020

Conversation

pownkel
Copy link
Contributor

@pownkel pownkel commented May 28, 2020

Description of changes

When the test's heading nav link is clicked, store that test as the currently expanded test in AssessmentStore and toggle the expanded state of the nav link. All links will start as collapsed by default.

expanded nav

Styling to highlight the expanded portion of the nav will be added in a later PR.

Pull request checklist

  • Addresses an existing issue: #1724866
  • Ran yarn fastpass
  • Added/updated relevant unit test(s) (and ran yarn test)
  • Verified code coverage for the changes made. Check coverage report at: <rootDir>/test-results/unit/coverage
  • PR title AND final merge commit title both start with a semantic tag (fix:, chore:, feat(feature-name):, refactor:). See CONTRIBUTING.md.
  • (UI changes only) Added screenshots/GIFs to description above
  • (UI changes only) Verified usability with NVDA/JAWS

@pownkel pownkel requested a review from a team as a code owner May 28, 2020 16:59
lisli1
lisli1 previously approved these changes May 28, 2020
Copy link
Contributor

@lisli1 lisli1 left a comment

Choose a reason for hiding this comment

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

LGTM

haonliu
haonliu previously approved these changes May 28, 2020
@pownkel pownkel dismissed stale reviews from haonliu and lisli1 May 28, 2020 23:42

updated PR

@pownkel pownkel changed the title feat(nav-bar-functionality): Store expanded nav state in AssessmentStore feat(nav-bar-functionality): Store expanded nav state in AssessmentStore and toggle nav link expansion state May 28, 2020
@@ -70,6 +70,7 @@ export interface TestStepResult {
export interface AssessmentNavState {
selectedTestSubview: RequirementName | GettingStarted;
selectedTestType: VisualizationType;
expandedTestType?: VisualizationType;
Copy link
Member

Choose a reason for hiding this comment

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

Why is this optional?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It can be null or undefined if nothing is currently expanded

@pownkel pownkel merged commit 0f7cd4e into microsoft:master Jun 1, 2020
@pownkel pownkel deleted the store-expanded-test branch June 1, 2020 16:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants