diff --git a/web/src/buddy_list.ts b/web/src/buddy_list.ts index 1b76cda59c..f9c3ecdb62 100644 --- a/web/src/buddy_list.ts +++ b/web/src/buddy_list.ts @@ -366,7 +366,7 @@ export class BuddyList extends BuddyListConf { this.fill_screen_with_content(); // This must happen after `fill_screen_with_content` - $("#buddy-list-users-matching-view-container .view-all-subscribers-link").remove(); + $("#buddy-list-users-matching-view-container .view-all-subscribers-link").empty(); $("#buddy-list-other-users-container .view-all-users-link").empty(); void this.render_view_user_list_links(); this.display_or_hide_sections(); @@ -746,12 +746,10 @@ export class BuddyList extends BuddyListConf { current_sub, "subscribers", ); - $("#buddy-list-users-matching-view-container").append( - $( - render_view_all_subscribers({ - stream_edit_hash, - }), - ), + $("#buddy-list-users-matching-view-container .view-all-subscribers-link").html( + render_view_all_subscribers({ + stream_edit_hash, + }), ); } diff --git a/web/templates/buddy_list/view_all_subscribers.hbs b/web/templates/buddy_list/view_all_subscribers.hbs index c8a5d62c19..4d5270341e 100644 --- a/web/templates/buddy_list/view_all_subscribers.hbs +++ b/web/templates/buddy_list/view_all_subscribers.hbs @@ -1,7 +1,5 @@ - + + + {{t "View all subscribers" }} + + diff --git a/web/templates/right_sidebar.hbs b/web/templates/right_sidebar.hbs index 0e6053ad7b..0b94a4bd6f 100644 --- a/web/templates/right_sidebar.hbs +++ b/web/templates/right_sidebar.hbs @@ -20,6 +20,7 @@
+
diff --git a/web/tests/lib/buddy_list.cjs b/web/tests/lib/buddy_list.cjs index a0c5e21199..13f8acbcc3 100644 --- a/web/tests/lib/buddy_list.cjs +++ b/web/tests/lib/buddy_list.cjs @@ -41,7 +41,7 @@ exports.stub_buddy_list_elements = () => { $("#buddy-list-users-matching-view .empty-list-message").length = 0; $("#buddy-list-other-users .empty-list-message").length = 0; $("#buddy-list-other-users-container .view-all-users-link").length = 0; - $("#buddy-list-users-matching-view-container .view-all-subscribers-link").remove = noop; + $("#buddy-list-users-matching-view-container .view-all-subscribers-link").empty = noop; $("#buddy-list-other-users-container .view-all-users-link").empty = noop; $(`#buddy-list-users-matching-view .empty-list-message`).remove = noop; $(`#buddy-list-other-users .empty-list-message`).remove = noop;