{% extends "base_template.html" %} {% block title %}{{ item.title or item.filename }} — Media{% endblock %} {% block head %} {# Cropper.js styles, served LOCALLY as a media feature asset (never a CDN). #} {% endblock %} {% block content %}

Edit media

← Back to library
{% with messages = get_flashed_messages(with_categories=true) %} {% for category, message in messages %}
{{ message }}
{% endfor %} {% endwith %}
{% if item.is_image %}
Preview
{{ item.alt or item.title }}

The original is preserved; the crop is saved as a new media item.

{% else %}

This file is not an image, so it cannot be cropped.

{% endif %}

Details

Filename
{{ item.filename }}
URL
{{ item.url }}
Type
{{ item.mime_type or '—' }}
Dimensions
{% if dimensions %}{{ dimensions[0] }} × {{ dimensions[1] }} px{% else %}—{% endif %}
File size
{{ '%.1f'|format((item.size or 0) / 1024) }} KB
Uploaded
{{ item.uploaded_at.strftime('%Y-%m-%d %H:%M') if item.uploaded_at else '—' }}
{% if item.source_url %}
Source
{{ item.source_url }}
{% endif %}

Metadata

{% endblock %} {% block scripts %} {% if item.is_image %} {# Cropper.js, served LOCALLY as a media feature asset (never a CDN). #} {% endif %} {% endblock %}