Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • B bootstrap
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 263
    • Issues 263
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 114
    • Merge requests 114
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Bootstrap
  • bootstrap
  • Issues
  • #10568
Closed
Open
Issue created Sep 11, 2013 by Administrator@rootContributor

Popover with no animation doesn't hide (after toggle)

Created by: fkling

If you use $().popover with no animation and show the popover with $().popover('toggle') (i.e. trigger: 'manual'), then it doesn't hide after $().popover('hide') is called.

Demo: http://jsfiddle.net/sJtrg/

The problem seems to be that inside the Tooltip.prototype.toggle function, enter and leave are called instead of show and hide:

self.tip().hasClass('in') ? self.leave(self) : self.enter(self)

This was changed as part #7163 (closed) (9257bdc0).

Inside enter, the following property is set:

self.hoverState = 'in'

and inside hide, the popover is only removed if this property is not 'in':

function complete() {
  if (that.hoverState != 'in') $tip.detach()
}

The same problem exists with animation of course, but since element was faded out, it's not visible (even though it doesn't get detached).

I would have changed the calls from leave and enter to hide and show again, but I didn't go through the other issue completely, so I don't know if that would reintroduce the other bug. There might be a different way to solve this problem.

Assignee
Assign to
Time tracking