Zulip server and web application. Open-source team chat that helps teams stay productive and focused.
navbar_search: Make search bar conform to short viewports.
Karl Stolley27d5227e4884
diff --git a/web/styles/app_variables.css b/web/styles/app_variables.cssindex 5a64b7d897d..57601642137 100644--- a/web/styles/app_variables.css+++ b/web/styles/app_variables.css@@ -185,10 +185,6 @@--search-box-height: 28px;--search-box-width: 150px;- @media (height < $short_navbar_cutoff_height) {- --search-box-height: var(--header-height);- }-@media (width < $md_min) {--search-box-width: 40px;}diff --git a/web/styles/search.css b/web/styles/search.cssindex d44f38c3dd4..920e0fc87c1 100644--- a/web/styles/search.css+++ b/web/styles/search.css@@ -216,6 +216,12 @@&.pill-container {/* Maintain only a column gap. */gap: 0 5px;++ @media (height < $short_navbar_cutoff_height) {+ /* Lose the luxury of padding in short navbar settings. */+ padding-top: 0;+ padding-bottom: 0;+ }}.pill {@@ -230,6 +236,10 @@.search-input-and-pills {flex-wrap: nowrap;overflow: hidden;++ @media (height < $short_navbar_cutoff_height) {+ line-height: var(--base-line-height-unitless);+ }}}@@ -297,19 +307,15 @@#searchbox_form:not(.expanded) {margin: 0;/* Now that the header is shorter, the search box will take up the whole- height (which looks weird), so add 2px of space above and below it.- The extra pixel is to account for the header's bottom border (box shadow). */- margin-top: 2px;- height: calc(var(--header-height) - 5px);-- #searchbox-input-container {- height: calc(var(--search-box-height) - 5px);- }+ height (which looks weird), so add 1px of space above and below it+ by manipulating the margin and the height. */+ margin-top: 1px;+ height: calc(var(--header-height) - 3px);}/* It looks fine to fill the navbar when the typeahead is open. */#searchbox_form.expanded {- margin-top: 0;+ margin-top: 1px;}}