Skip to content

Commit

Permalink
fix: broken search dialog with prod build (#107)
Browse files Browse the repository at this point in the history
Signed-off-by: David Dal Busco <[email protected]>
  • Loading branch information
peterpeterparker authored Mar 13, 2024
1 parent e1c9b43 commit 0275b7e
Showing 1 changed file with 30 additions and 27 deletions.
57 changes: 30 additions & 27 deletions src/css/search.scss
Original file line number Diff line number Diff line change
@@ -1,34 +1,37 @@
.DocSearch {
--docsearch-searchbox-background: var(--ifm-navbar-background-color);
nav {
.DocSearch {
--docsearch-searchbox-background: var(--ifm-navbar-background-color);

@media screen and (min-width: 769px) {
position: relative;
width: 150px;
@media screen and (min-width: 769px) {
position: relative;
width: 150px;

// Move the looking glass icon on the right,
// but only on the button, not in the modal (where classes are reused)
&:not(:has(.DocSearch-Modal)) .DocSearch-Search-Icon {
position: absolute;
right: 1rem;
top: 50%;
transform: translateY(-50%);
// Move the looking glass icon on the right,
// but only on the button, not in the modal (where classes are reused)
&:not(:has(.DocSearch-Modal)) .DocSearch-Search-Icon {
position: absolute;
right: 1rem;
top: 50%;
transform: translateY(-50%);
}
}
}

outline: solid 1px var(--navbar-search-border-color) !important;
outline-offset: -0.5px; // Allow the border and focus shadow to blend seamlessly
&:hover,
&:focus {
outline: solid 1px var(--ifm-color-primary) !important;
}
outline: solid 1px var(--navbar-search-border-color) !important;
outline-offset: -0.5px; // Allow the border and focus shadow to blend seamlessly
&:hover,
&:focus {
outline: solid 1px var(--ifm-color-primary) !important;
}

.DocSearch-Button-Placeholder {
font-family: var(--ifm-font-family-base);
padding-left: 1rem;
color: var(--docsearch-text-color);
}
.DocSearch-Button-Placeholder {
font-family: var(--ifm-font-family-base);
padding-left: 1rem;
color: var(--docsearch-text-color);
}

.DocSearch-Button-Keys {
display: none;
.DocSearch-Button-Keys {
display: none;
}
}
}

}

0 comments on commit 0275b7e

Please sign in to comment.