stream: Show (archived) at the end of deactivated stream names.

When a stream is deactivated the title area and messages are
re-rendered to update the stream name with `(archived)` suffix.
This commit is contained in:
sanchi-t
2024-01-28 00:52:27 +05:30
committed by Tim Abbott
parent 616e39c290
commit fa268877d3
14 changed files with 58 additions and 2 deletions

View File

@@ -629,6 +629,11 @@ export function get_stream_privacy_policy(stream_id: number): string {
return settings_config.stream_privacy_policy_values.private_with_public_history.code;
}
export function is_stream_archived(stream_id: number): boolean {
const sub = sub_store.get(stream_id);
return sub ? sub.is_archived : false;
}
export function is_web_public(stream_id: number): boolean {
const sub = sub_store.get(stream_id);
return sub ? sub.is_web_public : false;