<%! from django.utils.translation import ugettext as _ %>
<script type="text/template" id="thread-list-template">
    <div class="browse-search">
        <div class="home">
            <a href="#" class="home-icon">
                <i class="icon icon-home"></i>
                <span class="sr">${_("Discussion Home")}</span>
            </a>
        </div>
        <div class="browse is-open">
            <a href="#" class="browse-topic-drop-icon">
                <i class="icon icon-reorder"></i>
                <span class="sr">${_("Discussion Topics")}</span>
            </a>
            <a href="#" class="browse-topic-drop-btn" aria-haspopup="true" aria-owns="browse-topic-drop-menu">
                <span class="sr">${_("Discussion topics; current selection is: ")}</span>
                <span class="current-board">${_("Show All Discussions")}</span>
                <span class="drop-arrow" aria-hidden="true">▾</span>
            </a>
        </div>
        <%include file="_filter_dropdown.html" />
        <div class="search">
            <form class="post-search">
                <label class="sr" for="search-discussions">${_("Search")}</label>
                <input type="text" id="search-discussions" placeholder="${_("Search all discussions")}" class="post-search-field">
            </form>
        </div>
    </div>
    <div class="sort-bar">
        <span class="sort-label" id="sort-label">${_("Sort by:")}</span>
        <ul role="radiogroup" aria-labelledby="sort-label">
            <li><a href="#" role="radio" aria-checked="true" class="active" data-sort="date">${_("date")}</a></li>
            <li><a href="#" role="radio" aria-checked="false" data-sort="votes">${_("votes")}</a></li>
            <li><a href="#" role="radio" aria-checked="false" data-sort="comments">${_("comments")}</a></li>
        </ul>


        %if is_course_cohorted and is_moderator:
        <span class="group-filter-label cohort">${_("Show:")}</span>
            <select class="group-filter-select cohort-options cohort">
                <option value="all">${_("View All")}</option>
                    %for c in cohorts:
                        <option value="${c.id}">${_("View as {name}").format(name=c.name)}</option>
                    %endfor
            </select>
        %endif
    </div>
    <div class="search-alerts"></div>
    <div class="post-list-wrapper">
        <ul class="post-list">
        </ul>
    </div>
</script>
