{% extends "stories/base.html" %}
{% load pagination_tags %}
{% load story_tags %}
{% load search_tags %}
{% load base_tags %}
{% load base_filters %}
{% load perm_tags %}
{% load i18n %}

{% block title %}{{ block.super }}Search{% endblock %}

{% block extra_head %}
{{ block.super }}
<link rel="stylesheet" href="{{ STATIC_URL }}css/stories.css">
<link rel="alternate" type="application/rss+xml" title="Latest Stories" href="{% url story.feed %}" />
{% endblock %}

{% block body %}
<div class="t">
    {% stories_nav request.user %}
    <h1>{% firstof MODULE_STORIES_LABEL_PLURAL "Stories" %}</h1>
     
    {% autopaginate stories 10 %}
    {% stories_search %}
    <span><em>{{ paginator.count }} {% firstof MODULE_STORIES_LABEL_PLURAL "Stories" %} {% trans "Found" %}</em> - {% trans 'Ordered by latest added' %}</span>
    
    <div class="stories-wrap">
    {% for story in stories %}  
        {% search_result story %}
    {% empty %}

    {% endfor %}
    </div>

    {% paginate %}
</div>
{% endblock %}
