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,8 @@
{
"comment": "Tooltip: Fixing 'persist on scroll' issues.",
"type": "patch",
"packageName": "office-ui-fabric-react",
"email": "humbertomakotomorimoto@gmail.com",
"commit": "eca43a063b66456426959e89bc1c32df7de9fc67",
"date": "2019-07-09T23:44:29.420Z"
}
Original file line number Diff line number Diff line change
Expand Up @@ -332,8 +332,8 @@ export class CalloutContentBase extends React.Component<ICalloutProps, ICalloutS
this._disposables.push(
on(this._targetWindow, 'scroll', this._dismissOnScroll, true),
on(this._targetWindow, 'resize', this._dismissOnResize, true),
on(this._targetWindow.document.documentElement as any, 'focus', this._dismissOnLostFocus, true), // FABRIC7TODO remove any
on(this._targetWindow.document.documentElement as any, 'click', this._dismissOnLostFocus, true) // FABRIC7TODO remove any
on(this._targetWindow.document.documentElement, 'focus', this._dismissOnLostFocus, true),
on(this._targetWindow.document.documentElement, 'click', this._dismissOnLostFocus, true)
);
this._hasListeners = true;
}, 0);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -93,11 +93,13 @@ export class TooltipHostBase extends BaseComponent<ITooltipHostProps, ITooltipHo
directionalHint={directionalHint}
directionalHintForRTL={directionalHintForRTL}
calloutProps={assign({}, calloutProps, {
onDismiss: this._hideTooltip,
onMouseEnter: this._onTooltipMouseEnter,
onMouseLeave: this._onTooltipMouseLeave
})}
onMouseEnter={this._onTooltipMouseEnter}
onMouseLeave={this._onTooltipMouseLeave}
onWheel={this._hideTooltip}
{...getNativeProps(this.props, divProperties)}
{...tooltipProps}
/>
Expand Down