1 {% macro headerbar(search_query="") -%}
2 <span style=float:left>
3 <b style=font-size:large><!--span style=font-family:serif>Δ</span-->delta</b>
5 {% if current_user.is_anonymous %}
6 <a href="/login" style=float:right>log in or sign up</a>
8 <span style=float:right>{{ current_user.name }} (<a href="/login">log out</a>)</span>
10 <form method=get action=/search>
11 <input name=q style="margin:auto;display:block;width:30em;box-sizing:border-box;border:0;background:#666;color:#eee;padding:.2em"
12 placeholder="Search (through invidio.us)" value="{{ search_query | e }}">
13 <input type=hidden name=provider value="invidio.us:443">
14 <!--input type=submit value="?"-->
19 {% macro card_generic(link, thumbnail, title='') -%}{#
21 <a class=thumb href="{{ link }}">
22 <img src="{{ thumbnail }}">
25 <a href="{{ link }}" title="{{ title | e }}">{{ title | e }}</a>
33 {% macro card(video_id, title='', advanced_text='', pinned="undefined") -%}{#
34 #}{% set caller_ = caller %}{#
35 #}{% call card_generic("/watch?v="~video_id, "https://i.ytimg.com/vi/"~video_id~"/mqdefault.jpg", title) %}
37 <details class=advanced><summary>{{ advanced_text }}</summary>
38 {% if pinned != "undefined" %}
40 <input type="hidden" name="{{ 'un' if pinned }}pin" value="{{ video_id }}">
41 <input class="emoji" type=submit value="📌️{{ '⃠' if pinned }}" title="{{ 'unpin' if pinned else 'pin to top' }}">
44 <input type="hidden" name="hide" value="{{ video_id }}">
45 <input class="emoji" type=submit value="💨️" title="hide video">
48 <a href="/watch?v={{ video_id }}&show=raw" class="emoji" title="raw video">🎞️</a>{#
49 #}<a href="/watch?v={{ video_id }}&show=json" class="emoji" title="json metadata">💡</a>
54 {% macro infobar_subscriptions(video_id, channel_id, author) -%}
55 <a href="/channel/{{ channel_id }}">{{ author | e }}</a>