Skip to content

armgit / zulip

Public Imported from GitHub
0

Zulip server and web application. Open-source team chat that helps teams stay productive and focused.

sidebars: Show vdot menus on keyboard-highlighted sidebar rows.

Alya Abbottb5cc7bb31aa5
diff --git a/web/styles/left_sidebar.css b/web/styles/left_sidebar.css
index 38418778ee3..807ef6cbc03 100644
--- a/web/styles/left_sidebar.css
+++ b/web/styles/left_sidebar.css
@@ -2147,17 +2147,21 @@ li.active-sub-filter {
}
/*
- When you hover over list items, we hover
- the vdots in light gray.
+ When you hover over or keyboard-highlight a list
+ item's menu icon, we give it a purple background.
The stream icon should always display when
- any topic is hovered, which is why it gets
- a more specific selector here.
+ any topic is hovered/highlighted, which is why
+ it gets a more specific selector here.
*/
-#stream_filters li:hover .stream-sidebar-menu-icon,
-.top_left_row:hover .sidebar-menu-icon,
-.bottom_left_row:hover .sidebar-menu-icon,
-#stream_filters .stream-list-subsection-header:hover .sidebar-menu-icon,
+#stream_filters
+ li:is(:hover, :focus-within, :has(.highlighted_row))
+ .stream-sidebar-menu-icon,
+.top_left_row:is(:hover, :focus-within, .highlighted_row) .sidebar-menu-icon,
+.bottom_left_row:is(:hover, :focus-within, .highlighted_row) .sidebar-menu-icon,
+#stream_filters
+ .stream-list-subsection-header:is(:hover, :focus-within, .highlighted_row)
+ .sidebar-menu-icon,
.app-main .column-left .left-sidebar .left_sidebar_menu_icon_visible {
/* We push against `display: none` with
`display: flex` because the sidebar vdots
diff --git a/web/styles/right_sidebar.css b/web/styles/right_sidebar.css
index 1317947e18c..55fc3ab5e9b 100644
--- a/web/styles/right_sidebar.css
+++ b/web/styles/right_sidebar.css
@@ -133,7 +133,7 @@
visibility: hidden;
}
- li:hover {
+ li:is(:hover, :focus-within, .highlighted_user) {
.user-list-sidebar-menu-icon {
visibility: visible;
}
@@ -148,6 +148,7 @@
padding: 0;
&:hover,
+ &:focus-within,
&.narrow-filter:has(a.user-presence-link:focus-visible),
&.highlighted_user {
background-color: var(--color-buddy-list-highlighted-user);