Initial commit

This commit is contained in:
2024-08-27 20:33:44 +02:00
commit 1f1832267d
14794 changed files with 1599592 additions and 0 deletions

View File

@@ -0,0 +1,20 @@
{% extends "wagtailadmin/generic/chooser/chooser.html" %}
{% load i18n wagtailadmin_tags %}
{% block filter_form %}
<form data-chooser-modal-search action="{{ results_url }}" method="GET" autocomplete="off" novalidate>
<ul class="fields">
{% for field in filter_form %}
<li>{% formattedfield field %}</li>
{% endfor %}
{% if popular_tags %}
<li class="taglist w-label-3">
<h3>{% trans 'Popular tags' %}</h3>
{% for tag in popular_tags %}
<a class="suggested-tag tag" href="{% url 'wagtailimages:index' %}?tag={{ tag.name|urlencode }}">{{ tag.name }}</a>
{% endfor %}
</li>
{% endif %}
</ul>
</form>
{% endblock %}

View File

@@ -0,0 +1,36 @@
{% load i18n wagtailadmin_tags wagtailimages_tags %}
<section id="tab-upload" class="duplicate-upload w-tabs__panel" role="tabpanel" aria-labelledby="tab-label-upload">
<p class="help-block help-warning">
{% icon name='warning' %}
{% trans "Upload successful. However, your new image seems to be a duplicate of an existing image. You may delete it if it wasn't required." %}
</p>
<figure class="duplicate-upload__figure col6">
<figcaption>{% trans "Existing" %}</figcaption>
{% image existing_image max-800x600 class="show-transparency" %}
<a href="{% url 'wagtailimages:edit' existing_image.id %}">{{ existing_image.title }}</a>
</figure>
<figure class="duplicate-upload__figure col6">
<figcaption>{% trans "New" %}</figcaption>
{% image new_image max-800x600 class="show-transparency" %}
<a href="{% url 'wagtailimages:edit' new_image.id %}">{{ new_image.title }}</a>
</figure>
<div class="duplicate-upload__actions col12">
<a href="{{ confirm_duplicate_upload_action }}" class="use-new-image button button-secondary">
{% trans 'Use new image' %}
</a>
<form method="POST">
{% csrf_token %}
<a
href="{{ cancel_duplicate_upload_action }}"
class="use-existing-image button button-longrunning"
data-controller="w-progress"
data-action="w-progress#activate"
>
{% trans "Use existing and delete new" %}
</a>
</form>
</div>
</section>

View File

@@ -0,0 +1,42 @@
{% extends "wagtailadmin/generic/chooser/results.html" %}
{% load i18n wagtailimages_tags wagtailadmin_tags %}
{% block listing_title %}<h2>{% trans "Latest images" %}</h2>{% endblock %}
{% block results_listing %}
<ul class="listing horiz images chooser">
{% for image in results %}
<li>
{% if is_multiple_choice %}
<label title="Select {% if collections %}{{ image.collection.name }} » {% endif %}{{ image.title }}">
<div class="image">{% image image max-165x165 class="show-transparency" %}</div>
<h3>
<input type="checkbox" data-multiple-choice-select name="id" value="{{ image.id }}" title="{% blocktrans trimmed with title=image.title %}Select {{ title }}{% endblocktrans %}">
{{ image.title|ellipsistrim:60 }}
</h3>
</label>
{% else %}
<a data-chooser-modal-choice class="image-choice" title="{% if collections %}{{ image.collection.name }} » {% endif %}{{ image.title }}" href="{{ image.chosen_url }}">
<div class="image">{% image image max-165x165 class="show-transparency" %}</div>
<h3>{{ image.title|ellipsistrim:60 }}</h3>
</a>
{% endif %}
</li>
{% endfor %}
</ul>
{% endblock %}
{% block no_items_message %}
<p>
{% if is_filtering_by_collection %}
{% trans "You haven't uploaded any images in this collection." %}
{% else %}
{% trans "You haven't uploaded any images." %}
{% endif %}
{% if can_create %}
{% blocktrans trimmed %}
Why not <a class="upload-one-now" href="#tab-upload" data-tab-trigger>upload one now</a>?
{% endblocktrans %}
{% endif %}
</p>
{% endblock %}

View File

@@ -0,0 +1,19 @@
{% load wagtailimages_tags wagtailadmin_tags %}
{% load i18n %}
{% trans "Choose a format" as choose_str %}
{% include "wagtailadmin/shared/header.html" with title=choose_str %}
<div class="row row-flush nice-padding">
<div class="col6">
{% image image max-800x600 class="show-transparency" %}
</div>
<div class="col6">
<form action="{{ select_format_action_url }}" method="POST" novalidate>
{% csrf_token %}
{% for field in form %}
{% formattedfield field %}
{% endfor %}
<input type="submit" value="{% trans 'Insert image' %}" class="button" />
</form>
</div>
</div>