discourse/app/assets/javascripts/admin/templates/components/suspension-details.hbs
Joffrey JAFFEUX 6102c287f7
FIX: prevents i18n helper to return a SafeString (#9191)
For convenience the i18n helper has been made returning a SafeString, but when used with other helpers, a String is expected and will cause unexpected behaviors.

This is the root cause of the initial bug fixed in d2bb127e2c

This commit is kept as it's a better security in case of unexpected behavior.
2020-03-12 16:50:20 +01:00

26 lines
665 B
Handlebars

<div class='reason-controls'>
<label>
<div class='suspend-reason-label'>
{{#if siteSettings.hide_suspension_reasons}}
{{html-safe (i18n 'admin.user.suspend_reason_hidden_label')}}
{{else}}
{{html-safe (i18n 'admin.user.suspend_reason_label')}}
{{/if}}
</div>
</label>
{{text-field
value=reason
class="suspend-reason"
placeholderKey="admin.user.suspend_reason_placeholder"}}
</div>
<label>
<div class='suspend-message-label'>
{{i18n "admin.user.suspend_message"}}
</div>
</label>
{{textarea
value=message
class="suspend-message"
placeholder=(i18n "admin.user.suspend_message_placeholder")}}