{% extends "base.html" %} {% import "_icons.html" as icon %} {% block title %}{{ document.name }} · kopi{% endblock %} {% block content %} {% set raw_url = url_for('console.app_file', name=app.name, folder=folder, relative=relative) %}

{{ document.name }}

{{ document.size }} · changed {{ document.modified }}

{{ icon.back() }}Back to {% if parent %}{{ parent }}{% else %}{{ folder_label }}{% endif %} {% if readers %}
{% endif %}
{% if document.kind in ["docx", "slides", "other"] %}Download{% else %}Open in a new tab{% endif %}
{% if document.cut %}

This file is long, so only its first part is shown here. Open it on its own to see all of it.

{% endif %} {% if document.kind == "markdown" %}
{{ document.html | safe }}
{% elif document.kind == "diff" %}

− Before + After changed words highlighted

{%- for row in document.rows %} {%- if row.kind == "hunk" %} {%- else %}
{% if row.kind == "added" %}After: {% elif row.kind == "removed" %}Before: {% endif %}{% for piece in row.pieces %}{% if not loop.first %} {% endif %}{% if piece.changed %}{{ piece.text }}{% else %}{{ piece.text }}{% endif %}{% endfor %}
{%- endif %} {%- else %}

The edit changed nothing.

{%- endfor %}
{% elif document.kind in ["text", "json", "docx"] %}
{{ document.text }}
{% elif document.kind == "pdf" %} {% elif document.kind == "slides" and document.has_pdf %} {% elif document.kind == "slides" %}

No PDF was made for this deck

Open the file to see the slides, or run slides again without "no-pdf".

{% elif document.kind == "image" %}
{{ document.name }}
{% else %}

No preview for this kind of file

Download it, or open its folder.

{% endif %} {% endblock %}