{% from "_macros.html" import icon %} {# A pending attachment in the composer, before the message is sent. Carries its own id in a hidden input so the composer form submits it with the message; removing the chip removes the input, which is all the bookkeeping the client needs. #}
{% if attachment.is_image %} {% else %} {{ icon("attach" if attachment.kind == "document" else "copy", "icon--sm") }} {% endif %} {{ attachment.filename }} {{ attachment.human_size }} {%- if attachment.pages %} · {{ attachment.pages }} page{{ '' if attachment.pages == 1 else 's' }}{% endif %} {%- if attachment.width %} · {{ attachment.width }}×{{ attachment.height }}{% endif %} {%- if attachment.truncated %} · truncated{% endif %} {% if attachment.extraction_error %} {{ attachment.extraction_error }} {% endif %}