{% extends "2-columns.html" %} {% if corpus_name %} {% block nav %} {{ corpus_name }} / {% endblock %} {% endif %} {# Begin shameless copypasta from text/index.html #} {% block sidebar_navbar %} Tags {{ text_names_array }} {% endblock %} {# Give this template a tags value in render_template, i.e. tags = tagger.tag(tokens) #} {# We'll figure out how to hook this up for real in a while. #} {# Only show this if we actually have tags. #} {% block sidebar_content %}
{% for tag_data in tags[0].values() %} {% endfor %}
{% endblock %} {# End shameless copypasta #} {% block main_navbar %} Texts {% endblock %} {% block main_content %}
{% for text_name in included_text_names %}
{# Contents are probably getting replaced by a JavaScript app #}
{% endfor %}
{% endblock %} {% block scripts %} {# Ick, take Python lists and write out a string representing a JavaScript array. #} {# TODO: Figure out how to make this a Jinja2 filter. #} {% set quoted_included_tag_keys = [] %} {% for tag_key in included_tag_keys %} {% do quoted_included_tag_keys.append('"' + tag_key + '"') %} {% endfor %} {% set quoted_included_text_names = [] %} {% for text_name in included_text_names %} {% do quoted_included_text_names.append('"' + text_name + '"') %} {% endfor %} {% endblock %}