gocardless/splash-pages — pull request #294 by jamesshedden (2014-11-05 14:56:51+00:00)
Title: Implementing dropdown-on-hover nav variant for A/B testing

Fairly hacky, would definitely want to tidy this up if we keep it but does a fairly good job now:

- Hover over a nav link for enough time and the dropdown will show
- Leave a dropdown for enough time and the dropdown will hide

At the moment the mouseover intent is managed by proposed addition to `angular-ui` called `ui.hoverintent` which I've manually included amongst our own components.

Custom behaviour once the hover-activated dropdown is open is included as part of the existing `popover-directive` - there's a new attribute `popover-options` which you can use to determine whether the popover responds to mousein/out events.

Supremely hacky way of removing an open dropdown if the mouse leaves a nav link horizontally (ie they never navigate down to the open menu, they just move from the nav link) via empty containers with `ng-mouseover` - was otherwise proving quite difficult to achieve this specific behaviour in conjunction with the other critical behaviour (see above).