upload.html
    
    HTML document, Unicode text, UTF-8 text
        
            1
            {% extends "default.html" %} 
        
            2
             
        
            3
            {% block nav_title %}Upload{% endblock %} 
        
            4
            {% block title %}Upload | {{ site_name }}{% endblock %} 
        
            5
            {% block content %} 
        
            6
                <x-frame style="--width: 768px"> 
        
            7
                    <form method="POST" class="vbox" enctype="multipart/form-data"> 
        
            8
                        <h1>Upload a picture</h1> 
        
            9
                        <label> 
        
            10
                            <span class="required-asterisk">Title</span> 
        
            11
                            <input type="text" name="title" required> 
        
            12
                        </label> 
        
            13
                        <label> 
        
            14
                            Description 
        
            15
                            <textarea name="description"></textarea> 
        
            16
                        </label> 
        
            17
                        <x-vbox> 
        
            18
                            <span class="required-asterisk">Picture type</span> 
        
            19
                            <div class="single-select" style="height: clamp(320px, 25vh, 640px)"> 
        
            20
                                {% for type in types %} 
        
            21
                                    <div class="image-type-selection"> 
        
            22
                                        <label> 
        
            23
                                            <input name="nature" type="radio" value="{{ type.id }}" required> 
        
            24
                                            <span class="image-type-title"> 
        
            25
                                                <span class="image-type-name"> 
        
            26
                                                    {{ type.id }} 
        
            27
                                                </span> 
        
            28
                                            </span> 
        
            29
                                        </label> 
        
            30
                                        <div class="image-type-selection-info"> 
        
            31
                                            <p>{{ type.description | safe }}</p> 
        
            32
                                        </div> 
        
            33
                                    </div> 
        
            34
                               {% endfor %} 
        
            35
                            </div> 
        
            36
                        </x-vbox> 
        
            37
                        <label> 
        
            38
                            Origin URL 
        
            39
                            <input type="url" name="origin_url"> 
        
            40
                            Can be left blank if not applicable. 
        
            41
                        </label> 
        
            42
                        <x-vbox> 
        
            43
                            <span class="required-asterisk">Licences</span> 
        
            44
                            <div class="multi-select" style="height: clamp(320px, 50vh, 640px)"> 
        
            45
                                {% for licence in licences %} 
        
            46
                                    <div class="licence-selection"> 
        
            47
                                        <label> 
        
            48
                                            <input name="licence" type="checkbox" value="{{ licence.id }}"> 
        
            49
                                            {% if licence.pinned %} 
        
            50
                                                <iconify-icon icon="mdi:pin" title="Pinned">Pinned</iconify-icon> 
        
            51
                                            {% endif %} 
        
            52
                                            {% if not licence.free %} 
        
            53
                                                <iconify-icon icon="mdi:ban" title="Non-free">Non-free</iconify-icon> 
        
            54
                                            {% endif %} 
        
            55
                                            <span class="licence-title"> 
        
            56
                                                <span class="licence-name"> 
        
            57
                                                    [{{ licence.id }}] 
        
            58
                                                    {{ licence.title }} 
        
            59
                                                </span> 
        
            60
             
        
            61
                                                {% if licence.url %} 
        
            62
                                                    <a href="{{ licence.url }}" target="_blank">More information</a> 
        
            63
                                                {% endif %} 
        
            64
                                            </span> 
        
            65
                                        </label> 
        
            66
                                        <div class="licence-selection-info"> 
        
            67
                                            {% if licence.logo_url %} 
        
            68
                                                {% if licence.info_url %} 
        
            69
                                                    <a href="{{ licence.info_url }}" target="_blank" tabindex="-1">     {# An equivalent link already exists, only one is focusable #} 
        
            70
                                                        <img src="{{ licence.logo_url }}" alt="{{ licence.title }}" class="licence-logo"> 
        
            71
                                                    </a> 
        
            72
                                                {% else %} 
        
            73
                                                    <img src="{{ licence.logo_url }}" alt="{{ licence.title }}" class="licence-logo"> 
        
            74
                                                {% endif %} 
        
            75
                                            {% endif %} 
        
            76
                                            <p>{{ licence.description | safe }}</p> 
        
            77
                                        </div> 
        
            78
                                    </div> 
        
            79
                               {% endfor %} 
        
            80
                            </div> 
        
            81
                            <p> 
        
            82
                                You can select multiple licences, but you must select at least one, and at least 
        
            83
                                one must be free. Selecting multiple licences means users are free to choose any 
        
            84
                                of them — they <em>do not</em> have to comply with all of them. 
        
            85
                            </p> 
        
            86
                            <div class="icon-explainer"> 
        
            87
                                <iconify-icon icon="mdi:pin" title="Pinned"></iconify-icon> 
        
            88
                                Recommended for new works 
        
            89
                                <iconify-icon icon="mdi:ban" title="Non-free"></iconify-icon> 
        
            90
                                Not a free software, open source or free culture licence 
        
            91
                            </div> 
        
            92
                        </x-vbox> 
        
            93
                        <label> 
        
            94
                            <span class="required-asterisk">File</span> 
        
            95
                            <input type="file" name="file" required> 
        
            96
                        </label> 
        
            97
                        <label> 
        
            98
                            <span>Prefill annotations</span> 
        
            99
                            <textarea name="annotations"></textarea> 
        
            100
                            You may add JSON annotations here. The object IDs must exist on the server. For 
        
            101
                            more information about the format, check the documentation. 
        
            102
                        </label> 
        
            103
                        <button type="submit">Upload</button> 
        
            104
                    </form> 
        
            105
                </x-frame> 
        
            106
            {% endblock %}