- scheduler: "Show X now" was a true one-shot -- reverted on the very next 5s tick, causing the flash-to-X-then-flash-back-to-clock behavior. Now pins for 5 minutes (still preemptable by Navidrome priority, which stays authoritative). Added a "Resume automatic" action/button and status display showing what's pinned and until when. - weather: daily forecast strip (3/5/7 days, selectable in settings) below current conditions, via Open-Meteo's daily= params in the same request. Fixed a bad symbol choice along the way -- DejaVu Sans has no glyph for the partly-cloudy emoji, was rendering as a tofu box; swapped to the plain cloud symbol, verified glyph coverage for the whole WMO code table.
58 lines
2.2 KiB
HTML
58 lines
2.2 KiB
HTML
{% extends "base.html" %}
|
|
{% block content %}
|
|
<h1>Picture</h1>
|
|
|
|
{% if error %}
|
|
<div class="toast error">{{ error }}</div>
|
|
{% endif %}
|
|
|
|
{% if settings.mode == "upload" and settings.uploaded_filename %}
|
|
<div class="card">
|
|
<div class="section-label">Current picture</div>
|
|
<div class="preview-wrap">
|
|
<img class="preview" src="{{ url_for('static', filename='uploads/' + settings.uploaded_filename) }}" alt="current picture">
|
|
</div>
|
|
</div>
|
|
{% elif settings.mode == "url" and settings.image_url %}
|
|
<div class="card">
|
|
<div class="section-label">Current picture</div>
|
|
<p class="hint">Fetched from a URL: {{ settings.image_url }}</p>
|
|
</div>
|
|
{% endif %}
|
|
|
|
<form method="post" enctype="multipart/form-data">
|
|
<div class="card">
|
|
<div class="section-label">Upload</div>
|
|
<div class="field">
|
|
<label for="image">Choose a file</label>
|
|
<input type="file" id="image" name="image" accept="image/png,image/jpeg,image/gif,image/bmp,image/webp">
|
|
<p class="hint">PNG, JPG, GIF, BMP, or WebP. Replaces whatever's currently set.</p>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="card">
|
|
<div class="section-label">Or use a URL</div>
|
|
<div class="field">
|
|
<label for="image_url">Image URL</label>
|
|
<input type="text" id="image_url" name="image_url" placeholder="https://example.com/photo.jpg">
|
|
<p class="hint">Re-fetched every 30 minutes. Leave both this and the upload above alone to just change the options below.</p>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="card">
|
|
<div class="section-label">Display options</div>
|
|
<div class="field">
|
|
<label for="fit">Fit</label>
|
|
<select id="fit" name="fit">
|
|
<option value="cover" {{ "selected" if settings.fit == "cover" }}>Cover -- fill the screen, cropping edges</option>
|
|
<option value="contain" {{ "selected" if settings.fit == "contain" }}>Contain -- show the whole image, letterboxed</option>
|
|
</select>
|
|
</div>
|
|
<label class="checkbox"><input type="checkbox" name="boost_contrast" {{ "checked" if settings.boost_contrast }}> Boost contrast for e-ink</label>
|
|
<label class="checkbox"><input type="checkbox" name="grayscale" {{ "checked" if settings.grayscale }}> Force grayscale</label>
|
|
</div>
|
|
|
|
<button type="submit">Save</button>
|
|
</form>
|
|
{% endblock %}
|