2
0
mirror of https://github.com/jfmcbrayer/brutaldon synced 2024-12-22 21:27:58 +01:00
brutaldon-interfaccia-web-m.../brutaldon/templates/main/post_partial.html

144 lines
4.9 KiB
HTML
Raw Permalink Normal View History

2018-04-30 14:58:10 +02:00
{% load widget_tweaks %}
2018-04-30 20:31:59 +02:00
{% if reply %}
<form method="post" id="post-form" action="{% url "reply" toot.id %}" enctype="multipart/form-data">
{% elif redraft %}
<form method="post" id="post-form" action="{% url "redraft" toot.id %}" enctype="multipart/form-data">
2018-04-30 20:31:59 +02:00
{% else %}
<form id="post-form" method="post" action="{% url "toot" %}" enctype="multipart/form-data">
2018-04-30 20:31:59 +02:00
{% endif %}
{% csrf_token %}
2018-04-30 14:58:10 +02:00
<div>
{{ form.non_field_errors }}
<br>
</div>
<div class="field">
<label class="label"> {{ form.spoiler_text.label }}</label>
<div class="control">
{% render_field form.spoiler_text class+="input mousetrap" placeholder="Optional" %}
2018-04-30 23:59:30 +02:00
</div>
</div>
2018-04-30 23:59:30 +02:00
<div class="field" >
<label class="label" >{{ form.status.label }}</label>
<div class="control">
<textarea name="status" cols="40" rows="3" class="textarea is-primary mousetrap"
required="" id="id_status"
ic-post-to="{% url "user_search" %}"
ic-trigger-on="keyup changed" ic-trigger-delay="500ms"
ic-target="#username_autocomplete">{% if form.status.value %}{{ form.status.value }}{% endif %}</textarea>
<div id="username_autocomplete"></div>
2018-04-30 14:58:10 +02:00
</div>
2018-09-07 22:28:33 +02:00
<div id="status_count"></div>
</div>
2018-04-30 14:58:10 +02:00
<div class="field">
<label class="label" > {{ form.visibility.label }}</label>
<div class="control has-icons-left">
<div class="select">
{% render_field form.visibility class+="select"%}
<span class="icon is-small is-left" >
2018-08-21 19:15:32 +02:00
<i class="fa fa-address-card"></i>
</span>
2018-04-30 14:58:10 +02:00
</div>
</div>
</div>
<div class="field has-addons">
<div class="file">
<label class="file-label">
{% render_field form.media_file_1 class+="file-input" %}
<span class="file-cta">
<span class="file-icon">
<i class="fa fa-upload"></i>
</span>
<span class="file-label" id="media_filename_1">
{{ form.media_file_1.label }}
</span>
</span>
</label>
</div>
<div class="control is-expanded">
{% render_field form.media_text_1 class+="input mousetrap" placeholder="Describe attachment" %}
</div>
</div>
<div class="field has-addons">
<div class="file">
<label class="file-label">
{% render_field form.media_file_2 class+="file-input" %}
<span class="file-cta">
<span class="file-icon">
<i class="fa fa-upload"></i>
</span>
<span class="file-label" id="media_filename_2">
{{ form.media_file_2.label }}
</span>
</span>
</label>
</div>
<div class="control is-expanded">
{% render_field form.media_text_2 class+="input mousetrap" placeholder="Describe attachment" %}
</div>
</div>
<div class="field has-addons">
<div class="file">
<label class="file-label">
{% render_field form.media_file_3 class+="file-input" %}
<span class="file-cta">
<span class="file-icon">
<i class="fa fa-upload"></i>
</span>
<span class="file-label" id="media_filename_3">
{{ form.media_file_3.label }}
</span>
</span>
</label>
</div>
<div class="control is-expanded">
{% render_field form.media_text_3 class+="input mousetrap" placeholder="Describe attachment" %}
</div>
</div>
<div class="field has-addons">
<div class="file">
<label class="file-label">
{% render_field form.media_file_4 class+="file-input" %}
<span class="file-cta">
<span class="file-icon">
<i class="fa fa-upload"></i>
</span>
<span class="file-label" id="media_filename_4">
{{ form.media_file_4.label }}
</span>
</span>
</label>
</div>
<div class="control is-expanded">
{% render_field form.media_text_4 class+="input mousetrap" placeholder="Describe attachment" %}
</div>
</div>
<div class="field has-addons">
<div class="control level is-mobile">
<a href="{% url "user" own_acct.acct %}" class="image avatar is-48x48 level-item" >
<img src="{{ own_acct.avatar_static }}" alt="[{{ own_acct.acct }}]">
</a>
<input type="submit" class="button is-primary level-item"
name="toot" value="Toot">
2018-08-10 04:13:45 +02:00
<a href="{% url "emoji" %}" target="_blank" rel="noopener noreferrer"
class="level-item emoji-link" title="custom emoji reference">😊</a>
2018-04-30 23:59:30 +02:00
</div>
</div>
{% if not preferences.no_javascript %}
<script type="application/javascript">
fileButtonUpdaters();
Intercooler.ready(fileButtonUpdaters);
2018-09-07 22:28:33 +02:00
Intercooler.ready(characterCountSetup);
</script>
{% endif %}
</form>