Skip to content

armgit / zulip

Public Imported from GitHub
0

Zulip server and web application. Open-source team chat that helps teams stay productive and focused.

web-empty-narrow: Update translated banners for stream rename channel.

Lauryn Menard13299577da93
diff --git a/web/src/message_view_header.ts b/web/src/message_view_header.ts
index 4e821ec4630..4eeee58cf13 100644
--- a/web/src/message_view_header.ts
+++ b/web/src/message_view_header.ts
@@ -65,7 +65,7 @@ function get_message_view_header_context(filter: Filter | undefined): MessageVie
sub_count: "0",
formatted_sub_count: "0",
rendered_narrow_description: $t({
- defaultMessage: "This stream does not exist or is private.",
+ defaultMessage: "This channel does not exist or is private.",
}),
};
}
diff --git a/web/src/narrow_banner.ts b/web/src/narrow_banner.ts
index d22d817f449..9e3e3ac7b23 100644
--- a/web/src/narrow_banner.ts
+++ b/web/src/narrow_banner.ts
@@ -112,7 +112,7 @@ function pick_empty_narrow_banner(): NarrowBannerData {
title: default_banner_for_multiple_filters,
html: $t_html({
defaultMessage:
- "<p>You are searching for messages that belong to more than one stream, which is not possible.</p>",
+ "<p>You are searching for messages that belong to more than one channel, which is not possible.</p>",
}),
};
}
@@ -264,28 +264,11 @@ function pick_empty_narrow_banner(): NarrowBannerData {
}
if (can_toggle_narrowed_stream()) {
- return {
- title: $t({
- defaultMessage:
- "You aren't subscribed to this stream and nobody has talked about that yet!",
- }),
- // TODO: Consider moving the button to be its own option in the template.
- html: $t_html(
- {
- defaultMessage: "<z-button>Subscribe</z-button>",
- },
- {
- "z-button": (content_html) =>
- `<button class="button white rounded stream_sub_unsub_button sea-green" type="button" name="subscription">${content_html.join(
- "",
- )}</button>`,
- },
- ),
- };
+ return default_banner;
}
return {
- title: $t({defaultMessage: "This stream does not exist or is private."}),
+ title: $t({defaultMessage: "This channel does not exist or is private."}),
};
}
// else fallthrough to default case
diff --git a/web/tests/narrow.test.js b/web/tests/narrow.test.js
index 8c6575260c5..02cf10f7c2e 100644
--- a/web/tests/narrow.test.js
+++ b/web/tests/narrow.test.js
@@ -222,7 +222,7 @@ run_test("show_empty_narrow_message", ({mock_template}) => {
narrow_banner.show_empty_narrow_message();
assert.equal(
$(".empty_feed_notice_main").html(),
- empty_narrow_html("translated: This stream does not exist or is private."),
+ empty_narrow_html("translated: This channel does not exist or is private."),
);
// for non-subbed public stream
@@ -232,8 +232,8 @@ run_test("show_empty_narrow_message", ({mock_template}) => {
assert.equal(
$(".empty_feed_notice_main").html(),
empty_narrow_html(
- "translated: You aren't subscribed to this stream and nobody has talked about that yet!",
- 'translated HTML: <button class="button white rounded stream_sub_unsub_button sea-green" type="button" name="subscription">Subscribe</button>',
+ "translated: There are no messages here.",
+ 'translated HTML: Why not <a href="#" class="empty_feed_compose_stream">start the conversation</a>?',
),
);
@@ -524,7 +524,7 @@ run_test("show_empty_narrow_message", ({mock_template}) => {
narrow_banner.show_empty_narrow_message();
assert.equal(
$(".empty_feed_notice_main").html(),
- empty_narrow_html("translated: This stream does not exist or is private."),
+ empty_narrow_html("translated: This channel does not exist or is private."),
);
});
@@ -626,7 +626,7 @@ run_test("show_invalid_narrow_message", ({mock_template}) => {
$(".empty_feed_notice_main").html(),
empty_narrow_html(
"translated: No search results.",
- "translated HTML: <p>You are searching for messages that belong to more than one stream, which is not possible.</p>",
+ "translated HTML: <p>You are searching for messages that belong to more than one channel, which is not possible.</p>",
),
);