2021-08-09 01:40:47 +00:00
|
|
|
{% load i18n %}
|
|
|
|
|
|
|
|
<div class="control">
|
2021-09-09 02:30:24 +00:00
|
|
|
<input
|
|
|
|
type="checkbox"
|
|
|
|
class="is-hidden"
|
|
|
|
name="sensitive"
|
|
|
|
id="id_show_spoilers_{{ uuid }}"
|
|
|
|
{% if draft.content_warning or status.content_warning %}checked{% endif %}
|
|
|
|
aria-hidden="true"
|
|
|
|
data-cache-draft="id_sensitive_{{ book.id }}_{{ type }}{{ reply_parent.id }}"
|
|
|
|
>
|
2021-08-09 01:40:47 +00:00
|
|
|
{% trans "Include spoiler alert" as button_text %}
|
|
|
|
{% firstof draft.content_warning status.content_warning as pressed %}
|
|
|
|
{% include 'snippets/toggle/toggle_button.html' with text=button_text icon="warning is-size-4" controls_text="spoilers" controls_uid=uuid focus="id_content_warning" checkbox="id_show_spoilers" class="toggle-button" pressed=pressed %}
|
|
|
|
</div>
|