Zulip server and web application. Open-source team chat that helps teams stay productive and focused.
tooltips: Add hotkey hints support to narrow to compose option.
sayamsamal4a7ad5325a87
diff --git a/static/js/tippyjs.js b/static/js/tippyjs.jsindex 8eda03287aa..74b24661157 100644--- a/static/js/tippyjs.js+++ b/static/js/tippyjs.js@@ -5,7 +5,6 @@ import tippy, {delegate} from "tippy.js";import render_message_inline_image_tooltip from "../templates/message_inline_image_tooltip.hbs";import render_narrow_to_compose_recipients_tooltip from "../templates/narrow_to_compose_recipients_tooltip.hbs";-import * as common from "./common";import * as compose_state from "./compose_state";import {$t} from "./i18n";import * as message_lists from "./message_lists";@@ -273,10 +272,7 @@ export function initialize() {}}- const shortcut_html = (common.has_mac_keyboard() ? "⌘" : "Ctrl") + " + .";- return parse_html(- render_narrow_to_compose_recipients_tooltip({shortcut_html, display_current_view}),- );+ return parse_html(render_narrow_to_compose_recipients_tooltip({display_current_view}));},onHidden(instance) {instance.destroy();diff --git a/static/js/ui_init.js b/static/js/ui_init.jsindex 36a27899e82..05fd490030a 100644--- a/static/js/ui_init.js+++ b/static/js/ui_init.js@@ -227,8 +227,6 @@ function initialize_compose_box() {scroll_to_bottom_key_html: common.has_mac_keyboard()? "Fn + <span class='tooltip_right_arrow'>→</span>": "End",- narrow_to_compose_recipients_key_html:- (common.has_mac_keyboard() ? "⌘" : "Ctrl") + " + .",max_stream_name_length: page_params.max_stream_name_length,max_topic_length: page_params.max_topic_length,}),diff --git a/static/templates/narrow_to_compose_recipients_tooltip.hbs b/static/templates/narrow_to_compose_recipients_tooltip.hbsindex 0ef459c0799..2c4fc768555 100644--- a/static/templates/narrow_to_compose_recipients_tooltip.hbs+++ b/static/templates/narrow_to_compose_recipients_tooltip.hbs@@ -1,4 +1,7 @@-<span>{{t 'Go to conversation' }}</span> <span class="hotkey-hint">({{shortcut_html}})</span>-{{#if display_current_view}}-<p class="narrow_to_compose_recipient_current_view_help">{{display_current_view}}</p>-{{/if}}+<div>+ <span>{{t 'Go to conversation' }}</span>+ {{#if display_current_view}}+ <p class="narrow_to_compose_recipient_current_view_help">{{display_current_view}}</p>+ {{/if}}+</div>+{{hotkey_hints "Ctrl" "."}}