buddy_list: Clicking avatar opens menu instead of using ... icon.

This commit is contained in:
evykassirer 2024-10-24 13:15:46 -07:00 committed by Tim Abbott
parent ce7c3705f7
commit 99856327f0
3 changed files with 26 additions and 8 deletions

View File

@ -783,6 +783,13 @@ function register_click_handlers() {
toggle_sidebar_user_card_popover($target);
});
$(".buddy-list-section").on("click", ".user-profile-picture", (e) => {
e.stopPropagation();
const $target = $(e.currentTarget).closest("li");
toggle_sidebar_user_card_popover($target);
});
$("body").on("click", ".sidebar-popover-mute-user", (e) => {
const user_id = elem_to_user_id($(e.target).parents("ul"));
hide_all_user_card_popovers();

View File

@ -170,8 +170,8 @@ $user_status_emoji_width: 24px;
position: absolute;
width: 0.4em;
height: 0.4em;
top: 1.7em;
left: 1.7em;
top: 1.6em;
left: 1.6em;
}
.empty-list-message {
@ -254,12 +254,21 @@ $user_status_emoji_width: 24px;
align-items: baseline;
}
.user_sidebar_entry.with_avatar .selectable_sidebar_block {
margin: 3px;
grid-template:
"row-content markers-and-controls" var(--line-height-sidebar-row-with-avatars)
"row-content ." auto / minmax(0, 1fr)
minmax(0, auto);
.user_sidebar_entry.with_avatar {
grid-template: "row-content" var(--line-height-sidebar-row-with-avatars) "row-content" auto / minmax(
0,
1fr
);
.selectable_sidebar_block {
margin: 2px;
grid-template:
"row-content markers-and-controls" var(
--line-height-sidebar-row-with-avatars
)
"row-content ." auto / minmax(0, 1fr)
minmax(0, auto);
}
}
.user-presence-link {

View File

@ -36,5 +36,7 @@
{{/if}}
<span class="unread_count {{#unless num_unread}}hide{{/unless}}">{{#if num_unread}}{{num_unread}}{{/if}}</span>
</div>
{{#unless user_list_style.WITH_AVATAR}}
<span class="sidebar-menu-icon user-list-sidebar-menu-icon"><i class="zulip-icon zulip-icon-more-vertical" aria-hidden="true"></i></span>
{{/unless}}
</li>