diff --git a/common/changes/@uifabric/experiments/AutoExpandFix_2018-05-25-18-31.json b/common/changes/@uifabric/experiments/AutoExpandFix_2018-05-25-18-31.json new file mode 100644 index 0000000000000..1029e2d4ed817 --- /dev/null +++ b/common/changes/@uifabric/experiments/AutoExpandFix_2018-05-25-18-31.json @@ -0,0 +1,11 @@ +{ + "changes": [ + { + "packageName": "@uifabric/experiments", + "comment": "Experiments/Nav component: Enable auto expand until the next manual expand disables the auto expand", + "type": "minor" + } + ], + "packageName": "@uifabric/experiments", + "email": "sikrishn@microsoft.com" +} \ No newline at end of file diff --git a/packages/experiments/src/components/Nav/Nav.tsx b/packages/experiments/src/components/Nav/Nav.tsx index 45ab2713ecdc4..40396edc28297 100644 --- a/packages/experiments/src/components/Nav/Nav.tsx +++ b/packages/experiments/src/components/Nav/Nav.tsx @@ -149,6 +149,9 @@ class NavComponent extends NavBase { // if allowed, auto expand if the child is selected link.isExpanded = link.disableAutoExpand ? link.isExpanded : isChildLinkSelected; + // enable auto expand until the next manual expand disables the auto expand + link.disableAutoExpand = false; + return (