mirror of
https://github.com/zulip/zulip.git
synced 2025-11-13 02:17:19 +00:00
tooltips: Fix hotkey-hint CSS class reuse.
The "hotkey-hint" class name used internally ind66f2d900fconflicted with the preexisting class name for hotkey hints into popovers, introduced in80ff3d8da5. Given that the new class is for a styling of hotkey hints designed for use in tooltips, it was a bad name anyway, so just rename it to tooltip-hotkey-hint. We rename the related cluster of variable names to match this.
This commit is contained in:
@@ -106,13 +106,13 @@ Handlebars.registerHelper(
|
||||
|
||||
Handlebars.registerHelper("numberFormat", (number) => number.toLocaleString());
|
||||
|
||||
Handlebars.registerHelper("hotkey_hints", (...hotkeys) => {
|
||||
Handlebars.registerHelper("tooltip_hotkey_hints", (...hotkeys) => {
|
||||
hotkeys.pop(); // Handlebars options
|
||||
let hotkey_hints = "";
|
||||
common.adjust_mac_tooltip_keys(hotkeys);
|
||||
for (const hotkey of hotkeys) {
|
||||
hotkey_hints += `<span class="hotkey-hint">${hotkey}</span>`;
|
||||
hotkey_hints += `<span class="tooltip-hotkey-hint">${hotkey}</span>`;
|
||||
}
|
||||
const result = `<span class="hotkey-hints">${hotkey_hints}</span>`;
|
||||
const result = `<span class="tooltip-hotkey-hints">${hotkey_hints}</span>`;
|
||||
return new Handlebars.SafeString(result);
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user