FEATURE: add silence reason dropdown to admin penalty reason

Adds dropdown list for pre-defined penalty options to silence to
mirror options on suspension list.
This commit is contained in:
Jeff Wong 2023-09-05 15:42:02 -07:00
parent 7cc5501cfd
commit a8324395e9

View File

@ -18,15 +18,24 @@
/> />
{{/if}} {{/if}}
{{else if (eq @penaltyType "silence")}} {{else if (eq @penaltyType "silence")}}
<label class="silence-reason-title">{{html-safe <label class="silence-reason-title">
(i18n "admin.user.silence_reason_label") {{html-safe (i18n "admin.user.silence_reason_label")}}</label>
}}</label>
<TextField <ComboBox
@value={{this.customReason}} @content={{this.reasons}}
@value={{this.selectedReason}}
@class="silence-reason" @class="silence-reason"
@onChange={{this.setCustomReason}} @onChange={{this.setSelectedReason}}
@placeholderKey="admin.user.silence_reason_placeholder"
/> />
{{#if this.isCustomReason}}
<TextField
@value={{this.customReason}}
@class="silence-reason"
@onChange={{this.setCustomReason}}
@placeholderKey="admin.user.silence_reason_placeholder"
/>
{{/if}}
{{/if}} {{/if}}
</div> </div>