SimpleerTube_peertube_minim.../templates/index.html

63 lines
2.6 KiB
HTML

<!doctype html>
<html>
<head>
<title>SimpleerTube - Search</title>
<link rel="stylesheet" href="/static/style.css">
<link rel="search" type="application/opensearchdescription+xml" href="/opensearch.xml" title="SimpleerTube"/>
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
</head>
<body>
<center>
<h2>SimpleerTube</h2>
<h5>A simple frontend for PeerTube</h5>
<form action="/search" method="POST">
<input size="45" style="max-width: 100%" type="text" name="query" id="query" placeholder="SepiaSearch"/>
<button type="submit">Search</button>
</form>
<br>
<form action="/instance" method="POST">
<label for="domain">Go to a specific instance:</label>
<br>
<input size="45" style="max-width: 100%" type="text" name="domain" id="domain" placeholder="Domain name"/>
<button type="submit">Go!</button>
</form>
<br>
{% if videos|length > 0 %}
<hr>
<h2>{{ videos|length }} latest videos from local subscriptions</h2>
<p>{% for sub in subscriptions %}{% if not loop.first %}, {% endif %}<a href="/{{ sub.host }}{% if sub.ownerAccount %}/video-channels{% else %}/accounts{% endif %}/{{ sub.name }}">{{ sub.displayName }} (@{{ sub.name }}@{{ sub.host }})</a>{% endfor %}</p>
<hr>
<div id="wrap">
{% for vid in videos %}
<div class="result-wrapper">
<a href="/{{ vid.account.host }}/videos/watch/{{ vid.uuid }}">
<img src="https://{{ vid.account.host }}{{ vid.thumbnailPath }}" height="150"/>
</a>
<div class="result-info">
<a href="/{{ vid.account.host }}/videos/watch/{{ vid.uuid }}">{{ vid.name }}</a>
<br>
{{ vid.views }} Views
<br>
<a href="/{{ vid.account.host }}/video-channels/{{ vid.channel.name }}@{{ vid.channel.host }}">
<b>{{ vid.channel.displayName }}</b>
</a>
<br>
<a href="/{{ vid.account.host }}/accounts/{{ vid.account.name }}@{{ vid.account.host }}">
{{ vid.account.name }}@{{ vid.account.host }}
</a>
</div>
</div>
{% endfor %}
</div>
{% endif %}
</center>
</body>
</html>