diff --git a/web/src/left_sidebar_navigation_area_popovers.js b/web/src/left_sidebar_navigation_area_popovers.js index 7cbdbbcb06..9696aa29b2 100644 --- a/web/src/left_sidebar_navigation_area_popovers.js +++ b/web/src/left_sidebar_navigation_area_popovers.js @@ -1,7 +1,7 @@ import $ from "jquery"; -import render_all_messages_sidebar_actions from "../templates/all_messages_sidebar_actions.hbs"; import render_drafts_sidebar_actions from "../templates/drafts_sidebar_action.hbs"; +import render_left_sidebar_inbox_popover from "../templates/left_sidebar_inbox_popover.hbs"; import render_starred_messages_sidebar_actions from "../templates/starred_messages_sidebar_actions.hbs"; import * as channel from "./channel"; @@ -81,12 +81,12 @@ export function initialize() { }, }); - // All messages popover - popover_menus.register_popover_menu(".all-messages-sidebar-menu-icon", { + // Inbox popover + popover_menus.register_popover_menu(".inbox-sidebar-menu-icon", { ...popover_menus.left_sidebar_tippy_options, onMount(instance) { const $popper = $(instance.popper); - popover_menus.popover_instances.all_messages = instance; + popover_menus.popover_instances.left_sidebar_inbox_popover = instance; $popper.one("click", "#mark_all_messages_as_read", () => { unread_ops.confirm_mark_all_as_read(); @@ -95,11 +95,11 @@ export function initialize() { }, onShow(instance) { popovers.hide_all(); - instance.setContent(parse_html(render_all_messages_sidebar_actions())); + instance.setContent(parse_html(render_left_sidebar_inbox_popover())); }, onHidden(instance) { instance.destroy(); - popover_menus.popover_instances.all_messages = undefined; + popover_menus.popover_instances.left_sidebar_inbox_popover = undefined; }, }); } diff --git a/web/src/popover_menus.js b/web/src/popover_menus.js index f00a35c45c..3701c0e1c3 100644 --- a/web/src/popover_menus.js +++ b/web/src/popover_menus.js @@ -24,7 +24,7 @@ export const popover_instances = { compose_control_buttons: null, starred_messages: null, drafts: null, - all_messages: null, + left_sidebar_inbox_popover: null, message_actions: null, stream_settings: null, compose_mobile_button: null, diff --git a/web/templates/left_sidebar.hbs b/web/templates/left_sidebar.hbs index 04a7c00f6e..b19ec7e062 100644 --- a/web/templates/left_sidebar.hbs +++ b/web/templates/left_sidebar.hbs @@ -10,6 +10,7 @@ {{t 'Inbox' }} +
  • @@ -28,7 +29,6 @@ {{~!-- squash whitespace --~}} {{t 'All messages' }} -
  • diff --git a/web/templates/all_messages_sidebar_actions.hbs b/web/templates/left_sidebar_inbox_popover.hbs similarity index 100% rename from web/templates/all_messages_sidebar_actions.hbs rename to web/templates/left_sidebar_inbox_popover.hbs diff --git a/web/tests/left_sidebar_navigation_area.test.js b/web/tests/left_sidebar_navigation_area.test.js index 175f4c39e1..91e17636bb 100644 --- a/web/tests/left_sidebar_navigation_area.test.js +++ b/web/tests/left_sidebar_navigation_area.test.js @@ -78,7 +78,7 @@ run_test("update_count_in_dom", () => { make_elem($(".top_left_mentions"), ""); - make_elem($(".top_left_all_messages"), ""); + make_elem($(".top_left_inbox"), ""); make_elem($(".top_left_starred_messages"), "");