aboutsummaryrefslogtreecommitdiffstats
path: root/templates/index.htm
blob: 3183b52707eb7a74af3b448fa58b5c0d2e12277b (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
{% extends "base.htm" %}

{% block title %}Overview{% endblock %}

{% block content %}
<h1>Bots</h1>
<form action="/front-end" method="POST">
  <input type="hidden" placeholder="Enter front end" name="front-end" value="tmtu">
  <button type="submit">tmtu-mode</button>
</form>

<ul>
  {% for bot in bots %}
    <h2>{{ bot.name }}</h1>
    <div>State: {{ bot.state }}</div>
    <div>Volume: {{ bot.volume * 100.0 }}%</div>
    {% match bot.currently_playing %}
      {% when Some with (current) %}
        <span>Currently playing:</span>
        {% let item = current %}
        {% include "song.htm" %}
      {% when None %}
    {% endmatch %}

    {% for item in bot.playlist %}
      <li>
        {% include "song.htm" %}
      </li>
    {% endfor %}
  {% endfor %}
</ul>
{% endblock %}