Revert "message_edit: Replace checkboxes with settings_checkbox partial."

This reverts commit 54a1c73c78.
This commit is contained in:
Aryan Shridhar 2021-07-22 00:32:40 +05:30 committed by Tim Abbott
parent 318d71469b
commit 3991fb3ea6
4 changed files with 20 additions and 17 deletions

View File

@ -832,10 +832,10 @@ export function save_message_row_edit(row) {
const selected_topic_propagation = const selected_topic_propagation =
row.find("select.message_edit_topic_propagate").val() || "change_later"; row.find("select.message_edit_topic_propagate").val() || "change_later";
const send_notification_to_old_thread = row const send_notification_to_old_thread = row
.find("#id_send_notification_to_old_thread") .find(".send_notification_to_old_thread")
.is(":checked"); .is(":checked");
const send_notification_to_new_thread = row const send_notification_to_new_thread = row
.find("#id_send_notification_to_new_thread") .find(".send_notification_to_new_thread")
.is(":checked"); .is(":checked");
request.propagate_mode = selected_topic_propagation; request.propagate_mode = selected_topic_propagation;
request.send_notification_to_old_thread = send_notification_to_old_thread; request.send_notification_to_old_thread = send_notification_to_old_thread;

View File

@ -9,6 +9,13 @@
justify-content: center; justify-content: center;
} }
/* Inserting this collapsed row between two flex items will make
* the flex item that comes after it break to a new row */
.break-row {
flex-basis: 100%;
height: 0;
}
.hide { .hide {
display: none; display: none;
} }

View File

@ -2544,11 +2544,6 @@ div.topic_edit_spinner .loading_indicator_spinner {
border-radius: 1px 4px 4px 1px !important; border-radius: 1px 4px 4px 1px !important;
} }
/* Remove the bottom margin from the notification checkboxes */
.message_edit_breadcrumb_messages .input-group {
margin-bottom: 0;
}
.stream_header_colorblock { .stream_header_colorblock {
margin-bottom: 20px; margin-bottom: 20px;
} }

View File

@ -18,16 +18,17 @@
<i class="fa fa-angle-right" aria-hidden="true" {{#unless is_stream_editable}}style="display:none"{{/unless}}></i> <i class="fa fa-angle-right" aria-hidden="true" {{#unless is_stream_editable}}style="display:none"{{/unless}}></i>
<input type="text" placeholder="{{topic}}" value="{{topic}}" class="message_edit_topic" id="message_edit_topic" autocomplete="off" /> <input type="text" placeholder="{{topic}}" value="{{topic}}" class="message_edit_topic" id="message_edit_topic" autocomplete="off" />
<div class="message_edit_breadcrumb_messages" style='display:none;'> <div class="message_edit_breadcrumb_messages" style='display:none;'>
{{> settings/settings_checkbox <label class="checkbox">
setting_name="send_notification_to_new_thread" <input class="send_notification_to_new_thread" name="send_notification_to_new_thread" type="checkbox" {{#if notify_new_thread}}checked="checked"{{/if}} />
prefix="id_" <span></span>
is_checked=notify_new_thread </label>
label=(t 'Send notification to new topic')}} <label for="send_notification_to_new_thread">{{t "Send notification to new topic" }}</label>
{{> settings/settings_checkbox <div class="break-row"></div> <!-- break -->
setting_name="send_notification_to_old_thread" <label class="checkbox">
prefix="id_" <input class="send_notification_to_old_thread" name="send_notification_to_old_thread" type="checkbox" {{#if notify_old_thread}}checked="checked"{{/if}} />
is_checked=notify_old_thread <span></span>
label=(t 'Send notification to old topic')}} </label>
<label for="send_notification_to_old_thread">{{t "Send notification to old topic" }}</label>
</div> </div>
<select class='message_edit_topic_propagate' style='display:none;'> <select class='message_edit_topic_propagate' style='display:none;'>
<option selected="selected" value="change_later"> {{t "Change later messages to this topic" }}</option> <option selected="selected" value="change_later"> {{t "Change later messages to this topic" }}</option>