Skip to content

Commit cce7aad

Browse files
authored
fix: Move dynamic search height to correct class (#418)
In #409, the definition of the max-height was moved to another class, this PR reflects this for the mobile max-height, otherwise it doesn't overwrite the value. Also remove an unnecessary hard-coded positioning of the search drawer, which led to gaps between drawer and search bar on some devices.
1 parent 8fc9dd6 commit cce7aad

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

assets/sass/search.scss

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,10 @@
2222
max-height: 50vh;
2323
padding: 0 1rem;
2424
overflow-y: scroll;
25+
26+
@media (max-width: #{$breakpoint-md}) {
27+
max-height: calc(100dvh - 17rem);
28+
}
2529
}
2630

2731
.pagefind-ui__results li:last-child {
@@ -70,15 +74,10 @@
7074
overscroll-behavior: contain;
7175
overflow: hidden;
7276
position: absolute;
73-
top: 7rem;
7477
width: 100%;
7578
z-index: 6;
7679
border: var(--border);
7780
border-radius: 0 0 var(--border-radius-l) var(--border-radius-l);
78-
79-
@media (max-width: #{$breakpoint-md}) {
80-
max-height: calc(100dvh - 17rem);
81-
}
8281
}
8382

8483
.pagefind-ui__result {

0 commit comments

Comments
 (0)