stream_mentions: Update compose banner text when @-stream restricted.

We simplify the banner message by replacing the
"stream wildcard mentions" text with `"@stream mentions`,
`"@-all mentions"`, or `"@-everyone mentions"` text.
This commit is contained in:
Prakhar Pratyush
2023-11-22 00:42:13 +05:30
committed by Tim Abbott
parent a2e6d6c7c4
commit 31a731469d
3 changed files with 14 additions and 16 deletions

View File

@@ -431,15 +431,9 @@ test_ui("validate_stream_message", ({override_rewire, mock_template}) => {
assert.ok(stream_wildcard_warning_rendered);
let wildcards_not_allowed_rendered = false;
mock_template("compose_banner/compose_banner.hbs", false, (data) => {
mock_template("compose_banner/wildcard_mention_not_allowed_error.hbs", false, (data) => {
assert.equal(data.classname, compose_banner.CLASSNAMES.wildcards_not_allowed);
assert.equal(
data.banner_text,
$t({
defaultMessage:
"You do not have permission to use stream wildcard mentions in this stream.",
}),
);
assert.equal(data.stream_wildcard_mention, "all");
wildcards_not_allowed_rendered = true;
});
override_rewire(