2022-12-01 18:48:31 +00:00
|
|
|
{% extends 'layout.html' %}
|
2023-04-22 09:02:05 +00:00
|
|
|
{% block head %}
|
|
|
|
<meta property="og:image" content="{{ url_for('static', filename='icon.png') }}"/>
|
|
|
|
<meta name="twitter:image" content="{{ url_for('static', filename='icon.png') }}"/>
|
|
|
|
<meta name="twitter:card" content="summary"/>
|
|
|
|
{% endblock %}
|
2023-03-25 16:22:32 +00:00
|
|
|
{% block nav_home %}selected{% endblock %}
|
2023-03-08 13:36:35 +00:00
|
|
|
{% block content %}
|
2023-04-04 19:36:24 +00:00
|
|
|
<div class="banner-small">
|
2023-03-08 13:36:35 +00:00
|
|
|
<div class="banner-content">
|
2023-04-07 09:18:03 +00:00
|
|
|
<h1 class="banner-header">{{ config.WEBSITE_CONF.name }}</h1>
|
2023-04-06 18:42:04 +00:00
|
|
|
{% if total_images == 0 %}
|
2023-04-04 19:36:24 +00:00
|
|
|
<p class="banner-info">0 images D:</p>
|
2023-04-06 18:42:04 +00:00
|
|
|
{% elif total_images == 69 %}
|
|
|
|
<p class="banner-info">{{ total_images }} images, nice</p>
|
2023-03-23 15:47:35 +00:00
|
|
|
{% else %}
|
2023-04-06 18:42:04 +00:00
|
|
|
<p class="banner-info">{{ total_images }} images</p>
|
|
|
|
{% endif %}
|
|
|
|
|
|
|
|
{% if pages > 1 %}
|
|
|
|
<div class="pill-row">
|
|
|
|
<div>
|
2023-04-20 16:15:51 +00:00
|
|
|
{% if pages > 4 %}<a class="pill-item" href="{{ url_for('gallery.index') }}"><i class="ph ph-arrow-line-left"></i></a>{% endif %}
|
|
|
|
<a class="pill-item" href="{% if (page - 1) > 1 %} {{ url_for('gallery.index', page=page-1) }} {% else %} {{ url_for('gallery.index') }} {% endif %}"><i class="ph ph-arrow-left"></i></a>
|
2023-04-06 18:42:04 +00:00
|
|
|
</div>
|
2023-04-20 16:15:51 +00:00
|
|
|
<span class="pill-text">{{ page }} / {{ pages }}</span>
|
2023-04-06 18:42:04 +00:00
|
|
|
<div>
|
2023-04-20 16:15:51 +00:00
|
|
|
<a class="pill-item" href="{% if (page + 1) < pages %} {{ url_for('gallery.index', page=page+1) }} {% else %} {{ url_for('gallery.index', page=pages) }} {% endif %}"><i class="ph ph-arrow-right"></i></a>
|
|
|
|
{% if pages > 4 %}<a class="pill-item" href="{{ url_for('gallery.index', page=pages) }}"><i class="ph ph-arrow-line-right"></i></a>{% endif %}
|
2023-04-06 18:42:04 +00:00
|
|
|
</div>
|
|
|
|
</div>
|
2023-03-23 15:47:35 +00:00
|
|
|
{% endif %}
|
2023-03-01 23:29:34 +00:00
|
|
|
</div>
|
|
|
|
</div>
|
2023-04-06 18:42:04 +00:00
|
|
|
|
2023-03-09 23:31:58 +00:00
|
|
|
{% if images %}
|
|
|
|
<div class="gallery-grid">
|
|
|
|
{% for image in images %}
|
2023-04-06 16:22:56 +00:00
|
|
|
<a id="image-{{ image.id }}" class="gallery-item" href="{{ url_for('image.image', image_id=image.id) }}" style="background-color: rgb({{ image.colours.0.0 }}, {{ image.colours.0.1 }}, {{ image.colours.0.2 }})">
|
2023-03-11 22:14:03 +00:00
|
|
|
<div class="image-filter">
|
|
|
|
<p class="image-title"><span class="time">{{ image.created_at }}</span></p>
|
|
|
|
</div>
|
2023-04-21 17:34:25 +00:00
|
|
|
<img fetchpriority="low" alt="{% if image.alt %}{{ image.alt }}{% else %}Image Thumbnail{% endif %}" data-src="{{ url_for('media_api.media', path='uploads/' + image.filename) }}?r=thumb" onload="this.classList.add('loaded');" id="lazy-load"/>
|
2023-03-09 23:31:58 +00:00
|
|
|
</a>
|
|
|
|
{% endfor %}
|
|
|
|
</div>
|
|
|
|
{% else %}
|
|
|
|
<div class="big-text">
|
2023-03-23 15:47:35 +00:00
|
|
|
<h1>*crickets chirping*</h1>
|
2023-03-26 01:04:13 +00:00
|
|
|
<p>There are no images here yet, upload some!</p>
|
2023-03-09 23:31:58 +00:00
|
|
|
</div>
|
|
|
|
{% endif %}
|
2023-01-25 15:13:56 +00:00
|
|
|
{% endblock %}
|