Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"changes": [
{
"packageName": "office-ui-fabric-react",
"comment": "Contexual Menu: Move SplitButtonContainer to be defined in the constructor instead of ComponentDidMount",
"type": "patch"
}
],
"packageName": "office-ui-fabric-react",
"email": "chiechan@microsoft.com"
}
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,7 @@ export class ContextualMenu extends BaseComponent<IContextualMenuProps, IContext

this._isFocusingPreviousElement = false;
this._isScrollIdle = true;
this._splitButtonContainers = new Map();
}

public dismiss = (ev?: any, dismissAll?: boolean) => {
Expand Down Expand Up @@ -141,7 +142,6 @@ export class ContextualMenu extends BaseComponent<IContextualMenuProps, IContext
// Invoked once, only on the client (not on the server), immediately after the initial rendering occurs.
public componentDidMount() {
this._events.on(this._targetWindow, 'resize', this.dismiss);
this._splitButtonContainers = new Map();
if (this.props.onMenuOpened) {
this.props.onMenuOpened(this.props);
}
Expand Down