mirror of
https://github.com/zulip/zulip.git
synced 2025-11-03 13:33:24 +00:00
compose_mobile_button: Use tippyjs for popover.
There are several benefits of using tippyjs here: * Removes dependency on bootstrap. * We don't have to manually handle show/hide of popover. * There cannot be any memory leak since we don't store the instance.
This commit is contained in:
@@ -6,7 +6,6 @@ import * as message_lists from "./message_lists";
|
||||
import * as message_store from "./message_store";
|
||||
import * as narrow_state from "./narrow_state";
|
||||
import * as people from "./people";
|
||||
import * as popovers from "./popovers";
|
||||
import * as recent_topics_util from "./recent_topics_util";
|
||||
|
||||
function update_stream_button(btn_text, title) {
|
||||
@@ -113,22 +112,10 @@ export function initialize() {
|
||||
|
||||
// Click handlers for buttons in the compose compose box.
|
||||
$("body").on("click", ".compose_stream_button", () => {
|
||||
popovers.hide_mobile_message_buttons_popover();
|
||||
compose_actions.start("stream", {trigger: "new topic button"});
|
||||
});
|
||||
|
||||
$("body").on("click", ".compose_private_button", () => {
|
||||
popovers.hide_mobile_message_buttons_popover();
|
||||
compose_actions.start("private");
|
||||
});
|
||||
|
||||
$("body").on("click", ".compose_mobile_stream_button", () => {
|
||||
popovers.hide_mobile_message_buttons_popover();
|
||||
compose_actions.start("stream", {trigger: "new topic button"});
|
||||
});
|
||||
|
||||
$("body").on("click", ".compose_mobile_private_button", () => {
|
||||
popovers.hide_mobile_message_buttons_popover();
|
||||
compose_actions.start("private");
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user