{% extends "mobile/xbmc/xbmc.html" %}

{% block header %}<h1>Movies</h1>{% endblock %}

{% block content %}

<ul id="movie_library" data-role="listview" data-filter="true">
  {% for movie in movies %}
      <li data-icon="{{ 'check' if movie.playcount else 'false' }}">
        <a class="inner play" href="#" data-movieid="{{ movie.movieid }}">
          <!-- <div class="thumb"><img src="{{ movie.thumbnail|xbmc_image }}" alt=""></div> -->
          <span class="title">{{movie.title}} ({{movie.year}})</span>
          <span class="rating">{{movie.rating|float|round(1, 'common')}}</span>
        </a>
        <a
            href="{{ url_for('movie_info', id=movie.movieid) }}"
            data-rel="dialog"
            data-transition="flip"
            data-theme="a"
            data-icon="info"
        >
            Info
        </a>
      </li>
  {% endfor %}
</ul>

{% endblock %}
