{%- import 'util/macros.html' as macros with context -%} {% if not request.headers.get("xhr") %} {% if comment_info %} {% endif %} {% if v %} {% include "modals/award.html" %} {% endif %} {% include "popover.html" %} {% endif %} {% macro single_comment(c, level=1, collapse=False) %} {% set ups=c.upvotes %} {% set downs=c.downvotes %} {% set score=ups-downs %} {% if render_replies %} {% set replies=c.replies(sort=sort, v=v, db=g.db) %} {% endif %} {% if c.is_blocking and not c.ghost or (c.is_banned or c.deleted_utc) and not (v and v.admin_level >= PERMS['POST_COMMENT_MODERATION']) and not (v and v.id==c.author_id) %}
{% if render_replies %}
{% if level<9 or request.path.startswith('/notifications') %} {% for reply in replies %} {{single_comment(reply, level=level+1)}} {% endfor %} {% elif replies %} More comments {% endif %}
{% endif %}
{% else %} {% set score=c.score %} {% if v %} {% set voted=c.voted %} {% if not voted and v.id == c.author_id %} {% set voted=1 %} {% endif %} {% else %} {% set voted=-2 %} {% endif %} {% if standalone and level==1 %}
{% if c.post and c.post.over_18 %}+18{% endif %} {% if c.post %} {% if c.author_id==v.id and replies and is_notification_page%} Comment {{'Replies' if (replies | length)>1 else 'Reply'}}: {{c.post.realtitle(v) | safe}} {% elif c.post.author_id==v.id and c.level == 1 and is_notification_page%} Post Reply: {{c.post.realtitle(v) | safe}} {% elif is_notification_page and c.parent_submission in v.subscribed_idlist %} Subscribed Thread: {{c.post.realtitle(v) | safe}} {% elif is_notification_page %} Username Mention: {{c.post.realtitle(v) | safe}} {% else %} {{c.post.realtitle(v) | safe}} {% endif %} {% if c.post.sub %} in /h/{{c.post.sub}} {% endif %} {% elif c.author_id==AUTOJANNY_ID %} Notification {% else %} {% if c.sentto == MODMAIL_ID %} Sent to admins {% else %} Sent to @{{c.senttouser.username}} {% endif %} {% endif %}
{% endif %} {% if c.parent_comment and c.parent_comment.sentto %} {% set isreply = True %} {% else %} {% set isreply = False %} {% endif %}
{% if not isreply %} {% endif %}
{% if c.active_flags(v) %}
Reported by:
    {% for f in c.filtered_flags(v) %}
  • {% if c.ghost %}👻{% else %}{{f.user.username}}{% endif %}{% if f.reason %}: {{f.realreason(v) | safe}}{% endif %} {% if v and v.admin_level >= PERMS['FLAGS_REMOVE'] %}{% endif %}
  • {% endfor %}
{% endif %} {% if c.is_banned and c.ban_reason %}
removed by @{{c.ban_reason}} (Admin)
{% endif %} {% if c.award_count("tilt", v) %} {% endif %}
{{c.realbody(v) | safe}}
{% if c.parent_submission %} {% if v and v.id==c.author_id %} {% endif %}
  • {% if v and v.admin_level >= PERMS['POST_COMMENT_MODERATION'] %} {% endif %}
  • {% if v and not c.deleted_utc %} {% endif %}
  • {% if v and request.path.startswith('/@') and v.admin_level < PERMS['VIEW_VOTE_BUTTONS_ON_USER_PAGE'] %}
  • {% if voted==1 %} {% endif %} {{score}} {% if voted==-1 %} {% endif %}
  • {% elif v %}
  • {{score}}
  • {% else %}
  • {{score}}
  • {% endif %}
  • {% if v and request.path.startswith('/@') and v.admin_level < PERMS['VIEW_VOTE_BUTTONS_ON_USER_PAGE'] %} {% if voted==1 %} {% endif %} {% elif v %} {% else %} {% endif %} {{score}} {% if v and request.path.startswith('/@') and v.admin_level < PERMS['VIEW_VOTE_BUTTONS_ON_USER_PAGE'] %} {% if voted==-1 %}
  • {% endif %} {% elif v %} {% else %} {% endif %} {% if v and ((not c.ghost and v.admin_level >= PERMS['VOTES_VISIBLE']) or v.id == AEVANN_ID) %}Votes{% endif %} Context {% if v %} {% if not c.deleted_utc %} {% endif %} {% if FEATURES['AWARDS'] -%} {%- endif %} {% endif %} {% if c.parent_submission %} {% if v and c.author_id == v.id %} {% elif v and c.body %} {% endif %} {% endif %} {% if v %} {% endif %}
{% endif %}
{% if v and v.id != c.author_id and c.body and not (c.post and c.post.club and not v.paid_dues) %}
{{c.body.strip()}}
{% endif %}
{% if request.path.startswith('/transfers') %} {% endif %} {% if render_replies %}
{% if request.path.startswith('/notifications/') and replies|length > 8 %} {% for reply in replies %} {{single_comment(reply, level=level+1, collapse=(not reply.unread and loop.index != replies|length))}} {% endfor %} {% elif request.path.startswith('/notifications') or level < 9 %} {% for reply in replies %} {{single_comment(reply, level=level+1)}} {% endfor %} {% elif replies %} More comments {% endif %}
{% if request.path.startswith('/notifications') and c.level == 1 and c.sentto and not c.parent_submission and c.author_id != AUTOJANNY_ID %} {% if (v and v.admin_level >= PERMS['USER_BAN']) and (c.sentto == MODMAIL_ID) %} {% endif %}
{% endif %} {% else %}
{% endif %}
{% if v and v.admin_level >= PERMS['POST_COMMENT_MODERATION_TOOLS_VISIBLE'] %} {% endif %}
{% endif %} {% endmacro %} {% for comment in comments if user_can_see(v, comment) %} {{single_comment(comment)}} {% endfor %} {% if not request.headers.get("xhr") %} {% if v %} {% include "modals/gif.html" %} {% include "modals/emoji.html" %} {% if v.admin_level >= PERMS['USER_BAN'] %} {% include "modals/ban.html" %} {% endif %} {% endif %} {% if v %} {% endif %} {% if v and v.admin_level >= PERMS['POST_COMMENT_MODERATION_TOOLS_VISIBLE'] %} {% endif %} {% endif %} {% if offset %} {% if p %} {% set pid = p.id %} {% endif %}
{% endif %} {% if SITE_NAME == 'rDrama' and not request.headers.get("xhr") and v and 'SamsungBrowser' not in g.agent and v.theme != 'transparent' %} {% endif %}