mirror of
https://github.com/zulip/zulip.git
synced 2025-11-07 15:33:30 +00:00
streams: Warn when archiving a notification stream.
Archiving a user/stream notification stream disables user/stream notifications.This commit adds a warning that notifications will be disabled while archiving any notification stream. Fixes #22110. Co-authored-by: Victor Fróes <71036803+vfroes21@users.noreply.github.com> Co-authored-by: Isabella Carmo <isabella.carmo@hotmail.com>
This commit is contained in:
@@ -601,8 +601,19 @@ export function initialize() {
|
|||||||
const stream = sub_store.get(stream_id);
|
const stream = sub_store.get(stream_id);
|
||||||
|
|
||||||
const stream_name_with_privacy_symbol_html = render_inline_decorated_stream_name({stream});
|
const stream_name_with_privacy_symbol_html = render_inline_decorated_stream_name({stream});
|
||||||
|
|
||||||
|
const is_new_stream_notification_stream =
|
||||||
|
stream_id === page_params.realm_notifications_stream_id;
|
||||||
|
const is_signup_notification_stream =
|
||||||
|
stream_id === page_params.realm_signup_notifications_stream_id;
|
||||||
|
const is_notification_stream =
|
||||||
|
is_new_stream_notification_stream || is_signup_notification_stream;
|
||||||
|
|
||||||
const html_body = render_settings_deactivation_stream_modal({
|
const html_body = render_settings_deactivation_stream_modal({
|
||||||
stream_name_with_privacy_symbol_html,
|
stream_name_with_privacy_symbol_html,
|
||||||
|
is_new_stream_notification_stream,
|
||||||
|
is_signup_notification_stream,
|
||||||
|
is_notification_stream,
|
||||||
});
|
});
|
||||||
|
|
||||||
confirm_dialog.launch({
|
confirm_dialog.launch({
|
||||||
|
|||||||
@@ -148,6 +148,10 @@
|
|||||||
margin-bottom: 10px;
|
margin-bottom: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#archive-stream-modal .notification_stream_archive_warning {
|
||||||
|
margin-bottom: 0;
|
||||||
|
}
|
||||||
|
|
||||||
#read_receipts_modal {
|
#read_receipts_modal {
|
||||||
.modal__container {
|
.modal__container {
|
||||||
width: 360px;
|
width: 360px;
|
||||||
|
|||||||
@@ -1,4 +1,17 @@
|
|||||||
{{#tr}}
|
<p>
|
||||||
|
{{#tr}}
|
||||||
Archiving stream <z-stream></z-stream> will immediately unsubscribe everyone. This action cannot be undone.
|
Archiving stream <z-stream></z-stream> will immediately unsubscribe everyone. This action cannot be undone.
|
||||||
{{#*inline "z-stream"}}<strong>{{{stream_name_with_privacy_symbol_html}}}</strong>{{/inline}}
|
{{#*inline "z-stream"}}<strong>{{{stream_name_with_privacy_symbol_html}}}</strong>{{/inline}}
|
||||||
{{/tr}}
|
{{/tr}}
|
||||||
|
</p>
|
||||||
|
{{#if is_notification_stream}}
|
||||||
|
<p class="notification_stream_archive_warning">{{#tr}}Archiving this stream will also disable settings that were configured to use this stream:{{/tr}}</p>
|
||||||
|
<ul>
|
||||||
|
{{#if is_new_stream_notification_stream}}
|
||||||
|
<li>{{#tr}}New stream notifications{{/tr}}</li>
|
||||||
|
{{/if}}
|
||||||
|
{{#if is_signup_notification_stream}}
|
||||||
|
<li>{{#tr}}New user notifications{{/tr}}</li>
|
||||||
|
{{/if}}
|
||||||
|
</ul>
|
||||||
|
{{/if}}
|
||||||
|
|||||||
Reference in New Issue
Block a user