mirror of
https://github.com/zulip/zulip.git
synced 2025-11-13 02:17:19 +00:00
Add support for topic narrows in our embedded narrow widget.
(imported from commit d3ef2db8e0903e445d9ecc2c28d9f249a0042bd9)
This commit is contained in:
@@ -257,7 +257,11 @@ exports.cancel = function () {
|
||||
// Never close the compose box in narrow embedded windows, but
|
||||
// at least clear the subject and unfade.
|
||||
compose_fade.clear_compose();
|
||||
compose.subject("");
|
||||
if (page_params.narrow_topic !== undefined) {
|
||||
compose.subject(page_params.narrow_topic);
|
||||
} else {
|
||||
compose.subject("");
|
||||
}
|
||||
return;
|
||||
}
|
||||
hide_box();
|
||||
@@ -906,7 +910,11 @@ $(function () {
|
||||
});
|
||||
|
||||
if (page_params.narrow !== undefined) {
|
||||
compose.start("stream", {});
|
||||
if (page_params.narrow_topic !== undefined) {
|
||||
compose.start("stream", {subject: page_params.narrow_topic});
|
||||
} else {
|
||||
compose.start("stream", {});
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user