mirror of
https://github.com/zulip/zulip.git
synced 2025-11-11 17:36:27 +00:00
message_edit: Fix tooltip not hidden on closing message edit form.
Bug: A tooltip appears on hovering over a control button in the message edit form. Now when the form was closed either using Esc key (cancel) or Enter / Ctrl + Enter (save), the tooltip didn't disappear. This resulted in a random tooltip visible in the message list view. Fix: Since tippyjs doesn't hide tooltip even after the element is hidden we need to explicitly hide the tooltip in those cases. See https://github.com/atomiks/tippyjs/issues/938 This commit fixes the above mentioned bug by explicitly hiding the tooltip instance.
This commit is contained in:
committed by
Tim Abbott
parent
2be9774192
commit
e1f3c54a1d
@@ -248,3 +248,11 @@ export function initialize(): void {
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
export function hide_compose_control_button_tooltips($row: JQuery): void {
|
||||
$row.find(
|
||||
".compose_control_button[data-tooltip-template-id], .compose_control_button[data-tippy-content], .compose_control_button_container",
|
||||
).each(function (this: tippy.ReferenceElement) {
|
||||
this._tippy?.hide();
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user