<!--
<div ng-controller="gridCtrl" class="grid period-media layout-wrap layout-row" layout="row" layout-wrap="">
    <grid-item entry="entry" ng-repeat="entry in entries"></grid-item>
</div>
-->
<div ng-controller="gridCtrl" flex ng-cloak>
    <div ng-if="entries.length">
        <h2>{{ title }}</h2>
        <md-grid-list
                md-cols="1" md-cols-sm="2" md-cols-md="3" md-cols-lg="6" md-cols-xl="7"
                md-row-height-gt-md="4:1" md-row-height="5:1"
                md-gutter="8px" md-gutter-gt-sm="4px" >
            <!-- <grid-item entry="entry" ng-repeat="entry in entries"></grid-item> -->
            <md-grid-tile
                    ng-click="preview(entry);"
                    ng-repeat="entry in entries"
                    class="media-entry background-{{ entry.colorClass }}"
                    md-rowspan="{{ (entry.isDir ? 1 : 4) }}"
                    md-colspan="1"
                    style="background-image: url('/.nekumo/thumb/{{ entry.path }}');" >
                <md-icon md-svg-icon="{{tile.icon}}"></md-icon>
                <h3 ng-if="entry.isDir">{{entry.name}}</h3>
                <md-grid-tile-footer ng-if="!entry.isDir"><h3>{{entry.name}}</h3></md-grid-tile-footer>
            </md-grid-tile>
        </md-grid-list>
    </div>
    <div ng-if="!entries.length && isSelected">
        <ng-include src="'/.nekumo/static/src/components/media/no-results.html'"></ng-include>
    </div>
</div>