Zulip server and web application. Open-source team chat that helps teams stay productive and focused.
Hide clear search button if search box is empty.
Harsh8bb53d39eaad
diff --git a/web/styles/left_sidebar.css b/web/styles/left_sidebar.cssindex aac7cd2f8d6..08703b18536 100644--- a/web/styles/left_sidebar.css+++ b/web/styles/left_sidebar.css@@ -1751,6 +1751,10 @@ li.topic-list-item {+ #clear-direct-messages-search-button {display: none;}++ .stream-list-filter:placeholder-shown + #clear_search_stream_button {+ display: none;+ }}/* Prepare an adjusted grid for the logged-out state,diff --git a/web/styles/popovers.css b/web/styles/popovers.cssindex ba0c3b32e29..fd012fe2f8e 100644--- a/web/styles/popovers.css+++ b/web/styles/popovers.css@@ -649,9 +649,8 @@ ul.popover-group-menu-member-list {margin-bottom: 0;}- #clear_stream_search {- display: none;- grid-area: clear-search;+ .stream-search:placeholder-shown + #clear_stream_search {+ visibility: hidden;}}diff --git a/web/styles/right_sidebar.css b/web/styles/right_sidebar.cssindex 56c03c978ce..a5f25370343 100644--- a/web/styles/right_sidebar.css+++ b/web/styles/right_sidebar.css@@ -486,6 +486,10 @@ $user_status_emoji_width: 24px;height: var(--line-height-sidebar-row-prominent);box-sizing: border-box;}++ .user-list-filter:placeholder-shown + #clear_search_people_button {+ display: none;+ }}#buddy-list-menu-icon {diff --git a/web/styles/subscriptions.css b/web/styles/subscriptions.cssindex 50dcdbe78f0..1300f9920a3 100644--- a/web/styles/subscriptions.css+++ b/web/styles/subscriptions.css@@ -539,10 +539,8 @@ h4.user_group_setting_subsection_title {width: 100%;}-#clear_search_stream_name,-#clear_search_group_name {- grid-area: clear-search;- padding: 0;+#search_group_name:placeholder-shown + #clear_search_group_name {+ visibility: hidden;}#search_stream_name:placeholder-shown + #clear_search_stream_name {diff --git a/web/styles/user_status.css b/web/styles/user_status.cssindex 06e5a3559f8..4903d2deba3 100644--- a/web/styles/user_status.css+++ b/web/styles/user_status.css@@ -33,6 +33,10 @@padding-left: 5px;}+ #user-status-input:placeholder-shown + .clear_search_button {+ visibility: hidden;+ }+.status-emoji-wrapper {padding: 4px 8px;border-right: 1px solid;