diff --git a/web/e2e-tests/message-basics.test.ts b/web/e2e-tests/message-basics.test.ts index eceed790ba..0102867957 100644 --- a/web/e2e-tests/message-basics.test.ts +++ b/web/e2e-tests/message-basics.test.ts @@ -404,21 +404,21 @@ async function test_stream_search_filters_stream_list(page: Page): Promise async function test_users_search(page: Page): Promise { console.log("Search users using right sidebar"); async function assert_in_list(page: Page, name: string): Promise { - await page.waitForSelector(`#buddy-list-other-users li [data-name="${CSS.escape(name)}"]`, { + await page.waitForSelector(`#buddy-list-other-users li[data-name="${CSS.escape(name)}"]`, { visible: true, }); } async function assert_selected(page: Page, name: string): Promise { await page.waitForSelector( - `#buddy-list-other-users li.highlighted_user [data-name="${CSS.escape(name)}"]`, + `#buddy-list-other-users li.highlighted_user[data-name="${CSS.escape(name)}"]`, {visible: true}, ); } async function assert_not_selected(page: Page, name: string): Promise { await page.waitForSelector( - `#buddy-list-other-users li.highlighted_user [data-name="${CSS.escape(name)}"]`, + `#buddy-list-other-users li.highlighted_user[data-name="${CSS.escape(name)}"]`, {hidden: true}, ); } @@ -452,7 +452,7 @@ async function test_users_search(page: Page): Promise { await arrow(page, "Down"); // Now Iago must be highlighted - await page.waitForSelector('#buddy-list-other-users li.highlighted_user [data-name="Iago"]', { + await page.waitForSelector('#buddy-list-other-users li.highlighted_user[data-name="Iago"]', { visible: true, }); await assert_not_selected(page, "King Hamlet"); diff --git a/web/src/click_handlers.js b/web/src/click_handlers.js index 75fe846133..5ceb2472e5 100644 --- a/web/src/click_handlers.js +++ b/web/src/click_handlers.js @@ -440,6 +440,9 @@ export function initialize() { if (e.metaKey || e.ctrlKey || e.shiftKey) { return; } + if ($(e.target).parents(".user-profile-picture").length === 1) { + return; + } const $li = $(e.target).parents("li"); diff --git a/web/styles/right_sidebar.css b/web/styles/right_sidebar.css index b0762dc092..7ac8c507dc 100644 --- a/web/styles/right_sidebar.css +++ b/web/styles/right_sidebar.css @@ -255,6 +255,7 @@ $user_status_emoji_width: 24px; } .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) @@ -272,7 +273,7 @@ $user_status_emoji_width: 24px; } .information-settings .profile-with-avatar, -.user_sidebar_entry.with_avatar .user-presence-link { +.user_sidebar_entry.with_avatar .selectable_sidebar_block { line-height: var(--line-height-sidebar-row-with-avatars); display: grid; grid-template: "avatar row-content" var(--right-sidebar-avatar-width) / auto minmax( @@ -287,10 +288,6 @@ $user_status_emoji_width: 24px; margin: 5px 0; } -.user_sidebar_entry.with_avatar .user-presence-link { - margin: 3px; -} - .my_user_status { opacity: 0.5; white-space: nowrap; diff --git a/web/templates/presence_row.hbs b/web/templates/presence_row.hbs index b1cce8cdd4..abb5f893df 100644 --- a/web/templates/presence_row.hbs +++ b/web/templates/presence_row.hbs @@ -1,11 +1,8 @@ -
  • +