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.

stream-settings: Show indicator on notification settings.

vighneshbhat9945f9ba4da012f9
diff --git a/dump.rdb b/dump.rdb
new file mode 100644
index 00000000000..9cd60ca6813
Binary files /dev/null and b/dump.rdb differ
diff --git a/web/src/stream_edit.js b/web/src/stream_edit.js
index 23c97518482..f7c1e442484 100644
--- a/web/src/stream_edit.js
+++ b/web/src/stream_edit.js
@@ -304,13 +304,13 @@ function stream_notification_reset(e) {
stream_settings_api.bulk_set_stream_property(
data,
- $(`#stream_change_property_status${CSS.escape(sub.stream_id)}`),
+ $(e.target).closest(".subsection-parent").find(".alert-notification"),
);
}
function stream_setting_changed(e) {
const sub = get_sub_for_target(e.target);
- const $status_element = $(`#stream_change_property_status${CSS.escape(sub.stream_id)}`);
+ const $status_element = $(e.target).closest(".subsection-parent").find(".alert-notification");
const setting = e.target.name;
if (!sub) {
blueslip.error("undefined sub in stream_setting_changed()");
diff --git a/web/templates/stream_settings/stream_settings.hbs b/web/templates/stream_settings/stream_settings.hbs
index 2825dd56c54..4da74cddb91 100644
--- a/web/templates/stream_settings/stream_settings.hbs
+++ b/web/templates/stream_settings/stream_settings.hbs
@@ -95,11 +95,11 @@
</div>
<div id="personal-stream-settings" class="stream_section" data-stream-section="personal">
- <div class="subsection-header">
- <h3 class="stream_setting_subsection_title inline-block">{{t "Personal settings" }}</h3>
- <div id="stream_change_property_status{{sub.stream_id}}" class="stream_change_property_status alert-notification"></div>
- </div>
<div class="subsection-parent">
+ <div class="subsection-header">
+ <h3 class="stream_setting_subsection_title inline-block">{{t "Personal settings" }}</h3>
+ <div class="stream_change_property_status alert-notification"></div>
+ </div>
{{#each other_settings}}
<div class="input-group">
{{> stream_settings_checkbox
@@ -120,9 +120,12 @@
</span>
</div>
</div>
- <h4 class="stream_setting_subsection_title">{{t "Notification settings" }}</h4>
- <p>{{t "In muted streams, stream notification settings apply only to unmuted topics." }}</p>
<div class="subsection-parent">
+ <div class="subsection-header">
+ <h4 class="stream_setting_subsection_title">{{t "Notification settings" }}</h4>
+ <div class="stream_change_property_status alert-notification"></div>
+ <p>{{t "In muted streams, stream notification settings apply only to unmuted topics." }}</p>
+ </div>
<div class="input-group">
<button class="button small rounded reset-stream-notifications-button" type="button">{{t "Reset to default notifications" }}</button>
</div>