mirror of
https://github.com/zulip/zulip.git
synced 2025-10-24 08:33:43 +00:00
combined-feed-ui: Add placeholder text to empty combined feed.
Also, added live update behaviour to the combined feed narrow. Fixes #31602.
This commit is contained in:
committed by
Tim Abbott
parent
99f3de5855
commit
28cbc498d7
@@ -128,10 +128,28 @@ export function pick_empty_narrow_banner(): NarrowBannerData {
|
||||
const default_banner_for_multiple_filters = $t({defaultMessage: "No search results."});
|
||||
|
||||
const current_filter = narrow_state.filter();
|
||||
|
||||
if (current_filter === undefined || current_filter.is_in_home()) {
|
||||
if (current_filter === undefined) {
|
||||
// We're in either the inbox or recent conversations view.
|
||||
return default_banner;
|
||||
}
|
||||
if (current_filter.is_in_home()) {
|
||||
// We're in the combined feed view.
|
||||
return {
|
||||
title: $t({defaultMessage: "There are no messages in your combined feed."}),
|
||||
html: page_params.is_spectator
|
||||
? ""
|
||||
: $t_html(
|
||||
{
|
||||
defaultMessage:
|
||||
"Would you like to <z-link>view messages in all public channels</z-link>?",
|
||||
},
|
||||
{
|
||||
"z-link": (content_html) =>
|
||||
`<a href="#narrow/channels/public">${content_html.join("")}</a>`,
|
||||
},
|
||||
),
|
||||
};
|
||||
}
|
||||
|
||||
const first_term = current_filter.terms()[0]!;
|
||||
const current_terms_types = current_filter.sorted_term_types();
|
||||
|
||||
Reference in New Issue
Block a user