<commit_before>{% extends 'djangobb_forum/base.html' %}
{% load forum_extras %}
{% load pagination_tags %}
{% load i18n %}

{% block title %} / {{ topic.forum.name }} / {{ topic.name }}{% endblock %}

{% block content %}
{% autopaginate posts forum_settings.TOPIC_PAGE_SIZE %}
<div class="linkst">
	<div class="inbox">
		<div class="pagelink conl">{% paginate %}</div>
		<ul>
			<li>
			<a href="{% url djangobb:index %}">{% trans "Root" %} </a></li><li>&raquo; {% link topic.forum %} </li><li>&raquo; {{ topic.name }}
			<a href="{% url djangobb:forum_topic_feed topic.id %}"><img src="{{ STATIC_URL }}/djangobb_forum/img/feed-icon-small.png" alt="[RSS Feed]" title="[RSS Feed]" class="breadcrumb_rss" /></a>
			</li>
		</ul>
		<div class="clearer"></div>
	</div>
</div>

{% if poll %}
<div id="poll" class="block">
    <h2><span>{% trans "Poll" %}</span></h2>
    <div class="box">
        <div class="inbox"><p><strong>{{ poll.question }}</strong></p>
        {% if poll_form %}       
            <form action="." method="post">{% csrf_token %}
            {{ poll_form }}
            {% if poll.choice_count > 1 %}
            <p>
                {% blocktrans with count=poll.choice_count %}({{ count }} answers allows.){% endblocktrans %}
            </p>
            {% endif %}
            <input type="submit" name="{{ poll_form.FORM_NAME }}" value="{% trans "Vote" %}" />
            </form>
        {% else %}
            <ul>               
            {% for choice in poll.choices.all %}
                <li>
                    <div class="bar" style="width:{{ choice.percent|floatformat:0 }}%;" title="{{ choice.choice }}">&nbsp;</div>
                    {{ choice.votes }} vote{{ choice.votes|pluralize }} ({{ choice.percent|floatformat:1 }}%) for: {{ choice.choice }}
                </li>
            {% endfor %}
            </ul>
        {% endif %}
        </div>
    </div>
</div>
{% endif %}

{% for post in posts %}
	<div id="p{{ post.id }}" class="blockpost roweven firstpost">
		<a name="post-{{ post.id }}"></a>

		<div class="box">
		  <h2><span><span class="conr">#{{ forloop.counter }}&nbsp;</span><a href="{{ post.get_absolute_url }}">{% forum_time post.created %}</a></span></h2>
			<div class="inbox box-content">
				<div class="postleft">
					<dl>
						<dt><strong class="username">{{ post.user.username }}</strong></dt>
{% if forum_settings.DISPLAY_USERTITLE %}
						<dd class="usertitle">
							{% if post.user.forum_profile.status %}
								<strong>{{ post.user.forum_profile.status }}</strong>
							{% else %}
								<strong>{{ post.user.forum_profile.group }}</strong>
							{% endif %}
						</dd>
						{% if forum_settings.AUTHORITY_SUPPORT %}
							<dd class="usertitle">
								{{ post.user|forum_authority }}
							</dd>
						{% endif %}
{% endif %}
						<dd class="postavatar">
{% comment %}
							{% if post.user.forum_profile.avatar and post.user.forum_profile.show_avatar %}
								<img src="{{ post.user.forum_profile.avatar.url }}" />
							{% else %}
								{% if forum_settings.GRAVATAR_SUPPORT %}
									<img src="{% gravatar post.user.email %}" />
								{% endif %}
							{% endif %}
{% endcomment %}
							<a href="{% url profile_detail post.user.username %}"><img src="http://scratch.mit.edu/static/icons/buddy/{{ post.user.id }}_med.png" width="90" height = "90"></a>
						</dd>
						{% if moderator %}
						{% if post.user.forum_profile.location %}
							<dd class="moderator-only">{% trans "From:" %} {{ post.user.forum_profile.location }}</dd>
						{% endif %}
						<dd class="moderator-only">{% trans "Registered:" %} {{ post.user.date_joined|date:"Y-m-d" }}</dd>
						<dd class="moderator-only">{% trans "Posts:" %} {{ post.user.forum_profile.post_count }}</dd>
							<dd class="moderator-only">{% trans "IP:" %} {{ post.user_ip }}</dd>
						{% endif %}
{% comment %}
						{% if forum_settings.REPUTATION_SUPPORT %}
								<dd><a href="{% url djangobb:reputation post.user.username %}">{% trans "Reputation" %}</a>:
								{% if request.user != post.user %} {# TODO: and user.is_authenticated #}
									<a href="{% url djangobb:reputation post.user.username %}?action=plus&amp;post_id={{ post.id }}"><img src="{{ STATIC_URL }}djangobb_forum/img/reputation/warn_add.gif" alt="+" /></a>&nbsp;&nbsp;<strong>{{ post.user.forum_profile.reply_total|default_if_none:"0" }}&nbsp;&nbsp;</strong><a href="{% url djangobb:reputation post.user.username %}?action=minus&amp;post_id={{ post.id }}"><img src="{{ STATIC_URL }}djangobb_forum/img/reputation/warn_minus.gif" alt="-" /></a>
								{% else %}
									<strong>{{ post.user.forum_profile.reply_total|default_if_none:"0" }}</strong>
								{% endif %}
								</dd>
						{% endif %}
						<dd class="usercontacts"><a href="{% url djangobb:forum_profile post.user.username %}">{% trans "Profile" %}</a>&nbsp;&nbsp;
						{% if post.user.forum_profile.privacy_permission == 0 %}
							<a href="mailto:{{ post.user.email }}">{% trans "E-mail" %}</a>&nbsp;&nbsp;
						{% else %}
							{% if post.user.forum_profile.privacy_permission == 1 %}
								<a href="{% url djangobb:misc %}?mail_to={{ post.user.username }}">{% trans "Send e-mail" %}</a>&nbsp;&nbsp;
							{% endif %}
						{% endif %}
						{% if forum_settings.PM_SUPPORT %}
							{% if user.is_authenticated %}
								<a href="{% url messages_compose_to post.user.username %}">{% trans "PM" %}</a>&nbsp;&nbsp;</dd>
							{% endif %}
						{% endif %}
{% endcomment %}
				</dl>
			</div>
			<div class="postright">
				<h3>{{ post.topic.name }}</h3>
				<div class="postmsg">
					<p class="post_body_html">{{ post.body_html|safe }}</p>
					{% if not user.is_authenticated or user.forum_profile.show_signatures %}
						{% if post.user.forum_profile.signature_html %}
						<div class="postsignature">
							<hr>
							{{ post.user.forum_profile.signature_html|safe }}
						</div>
						{% endif %}
					{% endif %}
					{% if post.updated %}
						<p class="postedit"><em>{% trans "Edited" %} {{ post.updated_by.username }} ({% forum_time post.updated %})</em></p>
					{% endif %}
					{% with post.attachments.all as attachments %}
						{% if attachments %}
							{% for attach in attachments %}
								<p class="postedit"><em>{% trans "Attachments:" %} <br />{{ attach|attachment_link }}</em></p>
							{% endfor %}
						{% endif %}
					{% endwith %}
				</div>
			</div>
			<div class="clearer"></div>
			<div class="postfootleft">
			  {% comment %}
				{% if post.user|online %}
					<p><strong>{% trans "Online" %}</strong></p>
				{% else %}
					<p>{% trans "Offline" %}</p>
				{% endif %}
			  {% endcomment %}
			</div>
			<div class="postfootright">
				<ul>
				  {% if user.is_authenticated %}
					<li class="postreport"><a href="{% url djangobb:misc %}?action=report&amp;post_id={{ post.id }}">{% trans "Report" %}</a> </li>
					{% if moderator or post|forum_equal_to:last_post %}
						{% if moderator or post.user|forum_equal_to:user %}
							<li class="postdelete">| <a onclick="return confirm('{% trans "Are you sure you want to delete this post?" %}')" href="{% url djangobb:delete_post post.id %}">{% trans "Delete" %}</a> </li>
						{% endif %}
					{% endif %}
					{% if moderator or post|forum_posted_by:user %}
						<li class="postedit">| <a href="{% url djangobb:edit_post post.id %}">{% trans "Edit" %}</a> </li>
					{% endif %}
						<li class="postquote">| <a onclick="return copy_paste('p{{ post.id }}');" href="#reply" title="{% trans "Full quote or quote selected text form this post." %}">{% trans "Quote" %}</a></li>
					{% endif %}
				</ul>
			</div>
		</div>
	</div>
</div>
{% endfor %}
<div class="postlinksb">
	<div class="inbox">
		<div class="pagelink conl">{% paginate %}</div>
			<ul>
			    <li><a href="{% url djangobb:index %}">{% trans "Root" %} </a></li>
			    <li>&raquo; {% link topic.forum %} </li>
			    <li>
			        &raquo; {{ topic }}<a href="{% url djangobb:forum_topic_feed topic.id %}"><img src="{{ STATIC_URL }}/djangobb_forum/img/feed-icon-small.png" alt="[RSS Feed]" title="[RSS Feed]" class="breadcrumb_rss" /></a>
			    </li>
            </ul>
		{% if user.is_authenticated %}
			{% if subscribed %}
				<a class="subscribelink clearb" href="{% url djangobb:forum_delete_subscription topic.id %}?from_topic">{% trans "Unsubscribe" %}</a>
			{% else %}
				<a class="subscribelink clearb" href="{% url djangobb:forum_add_subscription topic.id %}">{% trans "Subscribe" %}</a>
			{% endif %}
		{% endif %}
		<div class="clearer"></div>
	</div>
</div>

{% if reply_form %}<commit_msg>Comment out subscribe function in topics display.<commit_after>{% extends 'djangobb_forum/base.html' %}
{% load forum_extras %}
{% load pagination_tags %}
{% load i18n %}

{% block title %} / {{ topic.forum.name }} / {{ topic.name }}{% endblock %}

{% block content %}
{% autopaginate posts forum_settings.TOPIC_PAGE_SIZE %}
<div class="linkst">
	<div class="inbox">
		<div class="pagelink conl">{% paginate %}</div>
		<ul>
			<li>
			<a href="{% url djangobb:index %}">{% trans "Root" %} </a></li><li>&raquo; {% link topic.forum %} </li><li>&raquo; {{ topic.name }}
			<a href="{% url djangobb:forum_topic_feed topic.id %}"><img src="{{ STATIC_URL }}/djangobb_forum/img/feed-icon-small.png" alt="[RSS Feed]" title="[RSS Feed]" class="breadcrumb_rss" /></a>
			</li>
		</ul>
		<div class="clearer"></div>
	</div>
</div>

{% if poll %}
<div id="poll" class="block">
    <h2><span>{% trans "Poll" %}</span></h2>
    <div class="box">
        <div class="inbox"><p><strong>{{ poll.question }}</strong></p>
        {% if poll_form %}       
            <form action="." method="post">{% csrf_token %}
            {{ poll_form }}
            {% if poll.choice_count > 1 %}
            <p>
                {% blocktrans with count=poll.choice_count %}({{ count }} answers allows.){% endblocktrans %}
            </p>
            {% endif %}
            <input type="submit" name="{{ poll_form.FORM_NAME }}" value="{% trans "Vote" %}" />
            </form>
        {% else %}
            <ul>               
            {% for choice in poll.choices.all %}
                <li>
                    <div class="bar" style="width:{{ choice.percent|floatformat:0 }}%;" title="{{ choice.choice }}">&nbsp;</div>
                    {{ choice.votes }} vote{{ choice.votes|pluralize }} ({{ choice.percent|floatformat:1 }}%) for: {{ choice.choice }}
                </li>
            {% endfor %}
            </ul>
        {% endif %}
        </div>
    </div>
</div>
{% endif %}

{% for post in posts %}
	<div id="p{{ post.id }}" class="blockpost roweven firstpost">
		<a name="post-{{ post.id }}"></a>

		<div class="box">
		  <h2><span><span class="conr">#{{ forloop.counter }}&nbsp;</span><a href="{{ post.get_absolute_url }}">{% forum_time post.created %}</a></span></h2>
			<div class="inbox box-content">
				<div class="postleft">
					<dl>
						<dt><strong class="username">{{ post.user.username }}</strong></dt>
{% if forum_settings.DISPLAY_USERTITLE %}
						<dd class="usertitle">
							{% if post.user.forum_profile.status %}
								<strong>{{ post.user.forum_profile.status }}</strong>
							{% else %}
								<strong>{{ post.user.forum_profile.group }}</strong>
							{% endif %}
						</dd>
						{% if forum_settings.AUTHORITY_SUPPORT %}
							<dd class="usertitle">
								{{ post.user|forum_authority }}
							</dd>
						{% endif %}
{% endif %}
						<dd class="postavatar">
{% comment %}
							{% if post.user.forum_profile.avatar and post.user.forum_profile.show_avatar %}
								<img src="{{ post.user.forum_profile.avatar.url }}" />
							{% else %}
								{% if forum_settings.GRAVATAR_SUPPORT %}
									<img src="{% gravatar post.user.email %}" />
								{% endif %}
							{% endif %}
{% endcomment %}
							<a href="{% url profile_detail post.user.username %}"><img src="http://scratch.mit.edu/static/icons/buddy/{{ post.user.id }}_med.png" width="90" height = "90"></a>
						</dd>
						{% if moderator %}
						{% if post.user.forum_profile.location %}
							<dd class="moderator-only">{% trans "From:" %} {{ post.user.forum_profile.location }}</dd>
						{% endif %}
						<dd class="moderator-only">{% trans "Registered:" %} {{ post.user.date_joined|date:"Y-m-d" }}</dd>
						<dd class="moderator-only">{% trans "Posts:" %} {{ post.user.forum_profile.post_count }}</dd>
							<dd class="moderator-only">{% trans "IP:" %} {{ post.user_ip }}</dd>
						{% endif %}
{% comment %}
						{% if forum_settings.REPUTATION_SUPPORT %}
								<dd><a href="{% url djangobb:reputation post.user.username %}">{% trans "Reputation" %}</a>:
								{% if request.user != post.user %} {# TODO: and user.is_authenticated #}
									<a href="{% url djangobb:reputation post.user.username %}?action=plus&amp;post_id={{ post.id }}"><img src="{{ STATIC_URL }}djangobb_forum/img/reputation/warn_add.gif" alt="+" /></a>&nbsp;&nbsp;<strong>{{ post.user.forum_profile.reply_total|default_if_none:"0" }}&nbsp;&nbsp;</strong><a href="{% url djangobb:reputation post.user.username %}?action=minus&amp;post_id={{ post.id }}"><img src="{{ STATIC_URL }}djangobb_forum/img/reputation/warn_minus.gif" alt="-" /></a>
								{% else %}
									<strong>{{ post.user.forum_profile.reply_total|default_if_none:"0" }}</strong>
								{% endif %}
								</dd>
						{% endif %}
						<dd class="usercontacts"><a href="{% url djangobb:forum_profile post.user.username %}">{% trans "Profile" %}</a>&nbsp;&nbsp;
						{% if post.user.forum_profile.privacy_permission == 0 %}
							<a href="mailto:{{ post.user.email }}">{% trans "E-mail" %}</a>&nbsp;&nbsp;
						{% else %}
							{% if post.user.forum_profile.privacy_permission == 1 %}
								<a href="{% url djangobb:misc %}?mail_to={{ post.user.username }}">{% trans "Send e-mail" %}</a>&nbsp;&nbsp;
							{% endif %}
						{% endif %}
						{% if forum_settings.PM_SUPPORT %}
							{% if user.is_authenticated %}
								<a href="{% url messages_compose_to post.user.username %}">{% trans "PM" %}</a>&nbsp;&nbsp;</dd>
							{% endif %}
						{% endif %}
{% endcomment %}
				</dl>
			</div>
			<div class="postright">
				<h3>{{ post.topic.name }}</h3>
				<div class="postmsg">
					<p class="post_body_html">{{ post.body_html|safe }}</p>
					{% if not user.is_authenticated or user.forum_profile.show_signatures %}
						{% if post.user.forum_profile.signature_html %}
						<div class="postsignature">
							<hr>
							{{ post.user.forum_profile.signature_html|safe }}
						</div>
						{% endif %}
					{% endif %}
					{% if post.updated %}
						<p class="postedit"><em>{% trans "Edited" %} {{ post.updated_by.username }} ({% forum_time post.updated %})</em></p>
					{% endif %}
					{% with post.attachments.all as attachments %}
						{% if attachments %}
							{% for attach in attachments %}
								<p class="postedit"><em>{% trans "Attachments:" %} <br />{{ attach|attachment_link }}</em></p>
							{% endfor %}
						{% endif %}
					{% endwith %}
				</div>
			</div>
			<div class="clearer"></div>
			<div class="postfootleft">
			  {% comment %}
				{% if post.user|online %}
					<p><strong>{% trans "Online" %}</strong></p>
				{% else %}
					<p>{% trans "Offline" %}</p>
				{% endif %}
			  {% endcomment %}
			</div>
			<div class="postfootright">
				<ul>
				  {% if user.is_authenticated %}
					<li class="postreport"><a href="{% url djangobb:misc %}?action=report&amp;post_id={{ post.id }}">{% trans "Report" %}</a> </li>
					{% if moderator or post|forum_equal_to:last_post %}
						{% if moderator or post.user|forum_equal_to:user %}
							<li class="postdelete">| <a onclick="return confirm('{% trans "Are you sure you want to delete this post?" %}')" href="{% url djangobb:delete_post post.id %}">{% trans "Delete" %}</a> </li>
						{% endif %}
					{% endif %}
					{% if moderator or post|forum_posted_by:user %}
						<li class="postedit">| <a href="{% url djangobb:edit_post post.id %}">{% trans "Edit" %}</a> </li>
					{% endif %}
						<li class="postquote">| <a onclick="return copy_paste('p{{ post.id }}');" href="#reply" title="{% trans "Full quote or quote selected text form this post." %}">{% trans "Quote" %}</a></li>
					{% endif %}
				</ul>
			</div>
		</div>
	</div>
</div>
{% endfor %}
<div class="postlinksb">
	<div class="inbox">
		<div class="pagelink conl">{% paginate %}</div>
			<ul>
			    <li><a href="{% url djangobb:index %}">{% trans "Root" %} </a></li>
			    <li>&raquo; {% link topic.forum %} </li>
			    <li>
			        &raquo; {{ topic }}<a href="{% url djangobb:forum_topic_feed topic.id %}"><img src="{{ STATIC_URL }}/djangobb_forum/img/feed-icon-small.png" alt="[RSS Feed]" title="[RSS Feed]" class="breadcrumb_rss" /></a>
			    </li>
            </ul>
{% comment %}   {% if user.is_authenticated %}
			{% if subscribed %}
				<a class="subscribelink clearb" href="{% url djangobb:forum_delete_subscription topic.id %}?from_topic">{% trans "Unsubscribe" %}</a>
			{% else %}
				<a class="subscribelink clearb" href="{% url djangobb:forum_add_subscription topic.id %}">{% trans "Subscribe" %}</a>
			{% endif %}
		{% endif %}
{% endcomment %} 
                <div class="clearer"></div>
	</div>
</div>

{% if reply_form %}
{'fraction_non_alphanumeric': 0.2159169951309993, 'fraction_numerical': 0.0022026431718061676, 'mean_word_length': 2.914908100748809, 'pattern_counts': {'":': 0, '<': 387, '<?xml version=': 0, '>': 389, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5277459', 'n_tokens_mistral': 7642, 'n_tokens_neox': 5752, 'n_words': 1210}