Skip to content

Commit 12a1453

Browse files
authored
Merge pull request #74 from OurSQLFoundation/fix/nav-submenu-hover-gap
Fix submenu closing when moving the cursor to it
2 parents 8ef9151 + 459bb8a commit 12a1453

1 file changed

Lines changed: 14 additions & 0 deletions

File tree

‎assets/scss/_header.scss‎

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -195,6 +195,18 @@
195195
box-shadow: 0 12px 32px rgba(0, 0, 0, 0.35);
196196
z-index: 10;
197197

198+
// Invisible bridge over the margin-top gap: without it the cursor leaves
199+
// the hovered .nav-item--dropdown on its way down (easy to do with a
200+
// touchpad) and the menu closes before an item can be reached.
201+
&::before {
202+
content: "";
203+
position: absolute;
204+
top: -0.5rem;
205+
left: 0;
206+
right: 0;
207+
height: 0.5rem;
208+
}
209+
198210
a {
199211
padding: 0.5rem 0.75rem;
200212
border-radius: 6px;
@@ -292,6 +304,8 @@
292304
padding: 0 0 0 1rem;
293305
margin: 0;
294306

307+
&::before { display: none; }
308+
295309
a {
296310
padding: 0.625rem 1rem;
297311
font-size: 0.9375rem;

0 commit comments

Comments
 (0)