{% load humanize %}
{% if message.sender_avatar_url %} {% else %}
{{ message.sender_name|make_list|first|upper }}
{% endif %}
{{ message.sender_name }} {% if message.sender_handle %} @{{ message.sender_handle }} {% endif %}
{% if message.social_account.platform == "youtube" %} YouTube {% else %}{% include "partials/_platform_icon.html" with platform=message.social_account.platform size="sm" %}{% endif %} {{ message.social_account.account_name|default:message.social_account.account_handle }}
{{ message.received_at|date:"N j, Y g:i A" }}
{% for value, label in status_choices %} {% endfor %}
{% include "inbox/partials/_assignment_dropdown.html" %}
{{ message.get_message_type_display }} {% include "inbox/partials/_sentiment_badge.html" %} {% if sla_config and sla_config.is_active and message.status != 'resolved' and message.status != 'archived' %} {% include "inbox/partials/_sla_badge.html" %} {% endif %}

{{ message.body }}

{% if message.extra.is_deleted %}

This message was deleted by its sender.

{% elif message.extra.is_unsupported %}

This message contains media Instagram cannot provide.

{% endif %} {% for attachment in attachments %}
{% if not attachment.url %}

{{ attachment.type|title }} attachment unavailable.

{% elif attachment.type == 'image' %} Incoming image attachment {% elif attachment.type == 'video' %} {% elif attachment.type == 'audio' %} {% else %} Open {{ attachment.type }} attachment {% endif %} {% if attachment.url %}

If the attachment is unavailable, open the conversation in Instagram.

{% endif %}
{% endfor %}
{% for item_type, item, timestamp in thread %} {% if item_type == "reply" %} {% include "inbox/partials/_reply_item.html" with reply=item %} {% elif item_type == "note" %} {% include "inbox/partials/_note_item.html" with note=item %} {% endif %} {% endfor %}
{% for child in child_messages %}
{{ child.sender_name }} {{ child.received_at|timesince }} ago

{{ child.body }}

{% endfor %}
{% include "inbox/partials/_reply_composer.html" %}