From 4ee4bf2cac7f89feb78e76caf9209ed2da5be794 Mon Sep 17 00:00:00 2001 From: "REDMOND\\kysedate" Date: Thu, 29 Mar 2018 11:40:07 -0700 Subject: [PATCH 1/2] Updating the split button to close the menu when the primary button is executed. --- .../src/components/Button/BaseButton.tsx | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/office-ui-fabric-react/src/components/Button/BaseButton.tsx b/packages/office-ui-fabric-react/src/components/Button/BaseButton.tsx index e1f346217eaf1..fe5a57bdecead 100644 --- a/packages/office-ui-fabric-react/src/components/Button/BaseButton.tsx +++ b/packages/office-ui-fabric-react/src/components/Button/BaseButton.tsx @@ -449,7 +449,7 @@ export class BaseButton extends BaseComponent ) => { + if (this._isExpanded) { + this._dismissMenu(); + } + if (this.props.onClick) { + this.props.onClick(ev); + } + } + private _onRenderSplitButtonDivider(classNames: ISplitButtonClassNames | undefined): JSX.Element | null { if (classNames && classNames.divider) { return ; From 9111e2151a54bdfdfcc1a59e6836c8cff2a2f76f Mon Sep 17 00:00:00 2001 From: "REDMOND\\kysedate" Date: Thu, 29 Mar 2018 11:40:38 -0700 Subject: [PATCH 2/2] change --- ...ismiss-menu-on-primary-click_2018-03-29-18-40.json | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 common/changes/office-ui-fabric-react/kysedate-splitbutton-dismiss-menu-on-primary-click_2018-03-29-18-40.json diff --git a/common/changes/office-ui-fabric-react/kysedate-splitbutton-dismiss-menu-on-primary-click_2018-03-29-18-40.json b/common/changes/office-ui-fabric-react/kysedate-splitbutton-dismiss-menu-on-primary-click_2018-03-29-18-40.json new file mode 100644 index 0000000000000..6669d0e151b1f --- /dev/null +++ b/common/changes/office-ui-fabric-react/kysedate-splitbutton-dismiss-menu-on-primary-click_2018-03-29-18-40.json @@ -0,0 +1,11 @@ +{ + "changes": [ + { + "packageName": "office-ui-fabric-react", + "comment": "Updating the split button to close the menu when the primary button is executed.", + "type": "patch" + } + ], + "packageName": "office-ui-fabric-react", + "email": "kysedate@microsoft.com" +} \ No newline at end of file