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

[hover card] fix bug for quickly enter/leave card cannot dismiss card correctly #3606

Merged
merged 2 commits into from
Jan 22, 2018

Conversation

MirandaGe
Copy link
Member

@MirandaGe MirandaGe commented Dec 20, 2017

Pull request checklist

Description of changes

  1. setState cannot be used in componentWillUpdate
  2. did not clear dismiss timer correctly
  3. setState according to prev state should be done in callback function in setState.

Focus areas to test

tested on local build branch

@lynamemi lynamemi requested a review from atneik December 21, 2017 16:19
@Jahnp
Copy link
Member

Jahnp commented Jan 3, 2018

@atneik @chaofeng2014, can one of you take a look at this?

Copy link
Contributor

@kristoferbrown kristoferbrown left a comment

Choose a reason for hiding this comment

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

Looks good to me, but would be great if @atneik could take a look!

@@ -162,14 +162,17 @@ export class HoverCard extends BaseComponent<IHoverCardProps, IHoverCardState> {

@autobind
private _executeCardOpen(ev: MouseEvent) {
this._async.clearTimeout(this._openTimerId);
Copy link
Contributor

Choose a reason for hiding this comment

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

Should we move this._async.clearTimeout(this._dismissTimerId) in _cardOpen here for consistency with _executeCardDismiss?

@Jahnp Jahnp merged commit a541f4e into microsoft:master Jan 22, 2018
chrismohr pushed a commit to chrismohr/office-ui-fabric-react that referenced this pull request Apr 17, 2018
… correctly (microsoft#3606)

* fix card dismiss issue for hover card

* add rush change file
@microsoft microsoft locked as resolved and limited conversation to collaborators Aug 31, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[hover card] if I quickly enter/leave the hover card, the card does not dismiss as expected sometimes
4 participants