aboutsummaryrefslogtreecommitdiff
path: root/templates/posts/new.django
blob: 3e7f0809e0231813753a108e50bded95a7896abc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
{% extends 'layouts/main.django' %}
{% block content %}
  <div class="centered-horizontal">
    <div class="upload-area">
      <div class="upload-drag-box">
        <h1>Drop files here or just click this box!</h1>
        <p>Supported formats: {{ AllowedTypes|join:', ' }}</p>
        <small>Max size: {{ MaxSize }}</small>
      </div>
      <div class="upload-via-link">
        <form id="uploadViaLinkForm" onsubmit="uploadViaLink(); return false;">
          <input type="url" id="_uploadViaLink_InputBox" placeholder="alternatively, paste a URL here..." required />
          <input type="submit" value="Add URL" />
        </form>
      </div>
      <div class="error" style="display: none; margin: 8px 0; width: 100%;" id="error-message"></div>
      <div id="_uploadViaLink_UploadPreviewsArea" class="upload-previews"></div>
    </div>
  </div>
{% endblock %}
{% block scripts %}
  <script type="text/javascript" src="/static/scripts/errorControls.js" defer></script>
  <script type="text/javascript" src="/static/scripts/upload.js" defer></script>
{% endblock %}