mirror of https://github.com/zulip/zulip.git
settings_notifications: Enable muted stream notification settings.
This commit allow the users to modify notification settings for muted streams through the 'notification' section located in the personal settings. Fixes #27272.
This commit is contained in:
parent
ebd0dcd5d2
commit
137505e2ad
|
@ -343,16 +343,14 @@ export function update_muted_stream_state(sub) {
|
|||
)}']`,
|
||||
);
|
||||
|
||||
$row.toggleClass("control-label-disabled", sub.is_muted);
|
||||
if (sub.is_muted) {
|
||||
$row.find(".unmute_stream").show();
|
||||
} else {
|
||||
$row.find(".unmute_stream").hide();
|
||||
}
|
||||
$row.find("input").prop("disabled", sub.is_muted);
|
||||
$row.find('[name="push_notifications"]').prop(
|
||||
"disabled",
|
||||
!page_params.realm_push_notifications_enabled || sub.is_muted,
|
||||
!page_params.realm_push_notifications_enabled,
|
||||
);
|
||||
}
|
||||
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
<td>
|
||||
<label class="checkbox">
|
||||
<input type="checkbox" name="{{setting_name}}" id="{{prefix}}{{setting_name}}"
|
||||
{{#if (or is_muted is_disabled)}} disabled {{/if}}
|
||||
{{#if is_disabled}} disabled {{/if}}
|
||||
{{#if is_checked}}checked="checked"{{/if}} data-setting-widget-type="boolean"
|
||||
class="{{setting_name}}{{#unless is_disabled}} prop-element{{/unless}}"/>
|
||||
<span></span>
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
<tr class="stream-notifications-row {{#if muted}}control-label-disabled{{/if}}" data-stream-id="{{stream.stream_id}}">
|
||||
<tr class="stream-notifications-row" data-stream-id="{{stream.stream_id}}">
|
||||
<td>
|
||||
<span class="stream-privacy-original-color-{{stream.stream_id}} stream-privacy filter-icon" style="color: {{stream.color}}">
|
||||
{{> ../stream_privacy
|
||||
|
@ -15,7 +15,6 @@
|
|||
prefix=(lookup ../stream "stream_id")
|
||||
is_checked=(lookup ../stream this)
|
||||
is_disabled=(lookup ../is_disabled this)
|
||||
is_muted=../muted
|
||||
}}
|
||||
{{/each}}
|
||||
</tr>
|
||||
|
|
Loading…
Reference in New Issue