roundabout,
created on Wednesday, 3 April 2024, 14:54:57 (1712156097),
received on Wednesday, 31 July 2024, 06:54:44 (1722408884)
Author identity: vlad <vlad.muntoiu@gmail.com>
ae0f3f3ce44eeab85ffc8a7c774b97ea66149d34
templates/repository/repo-commit.html
@@ -8,49 +8,74 @@
{% block content %} <x-vbox> <x-frame style="--width: 896px;" class="flexible-space"> <h1>{{ data.message | split("\n\n", 1) | first | inline_markdown }}</h1><p>{{ data.message | split("\n\n", 1) | last | markdown }}</p>{% for file in diff %}<h2>{{ file }}</h2>{% set vars = namespace(original_line=0, modified_line=0, hunk_started=false) %}{% for line in diff[file] %}{% if line.startswith("@@") %}{% if vars.hunk_started %}</pre> <!-- close the previous pre block if this isn't the first hunk -->{% endif %}{% set vars.hunk_started = true %}{% set diff_location = line|parse_diff_location %}{% set vars.original_line = diff_location[0][0] %}{% set vars.modified_line = diff_location[1][0] %}<h3 class="diff-position">{{ line }}</h3><pre class="code-view">{% elif vars.hunk_started %}{% if line.startswith("+") %}<span class="line-number">{{ vars.modified_line }} +</span><ins>{{ line[1:] }}</ins>{% set vars.modified_line = vars.modified_line + 1 %}{% elif line.startswith("-") %}<span class="line-number">{{ vars.original_line }} -</span><del>{{ line[1:] }}</del>{% set vars.original_line = vars.original_line + 1 %}{% elif not line.startswith("\\") %}{% if line %}<span class="line-number">{{ vars.modified_line }} </span><x-codeline>{{ line[1:] }}</x-codeline>{% endif %}{% if not line.startswith("@@") %}{% set vars.original_line = vars.original_line + 1 %}{% set vars.modified_line = vars.modified_line + 1 %}{% endif %}{% endif %}{% endif %}{% endfor %}{% if vars.hunk_started %}</pre> <!-- close the last hunk -->{% endif %}{% endfor %}<x-vbox> <article> <h1>{{ data.message | split("\n\n", 1) | first | inline_markdown }}</h1> {{ data.message | split("\n\n", 1) | last | markdown }} </article> <p> {% trans owner_name=data.owner_name %} <a href="/{{ owner_name }}">{{ owner_name }}</a>,<br> {% endtrans %} {% trans receive_date=data.receive_date.strftime('%A, %e %B %Y, %H:%M:%S'), author_date=data.author_date.strftime("%A, %e %B %Y, %H:%M:%S"), receive_unix=data.receive_date.timestamp() | int, author_unix=data.author_date.timestamp() | int %} created on {{ author_date }} ({{ author_unix }}), received on {{ receive_date }} ({{ receive_unix }}) {% endtrans %} <br> {% trans %}Author identity:{% endtrans %} <code>{{ data.owner_identity }}</code> </p> <code>{{ data.sha }}</code> <x-vbox> {% for file in diff %} <article class="card"> <section class="card-main"> <h2>{{ file }}</h2> {% set vars = namespace(original_line=0, modified_line=0, hunk_started=false) %} {% for line in diff[file] %} {% if line.startswith("@@") %} {% if vars.hunk_started %} </pre> <!-- close the previous pre block if this isn't the first hunk --> {% endif %} {% set vars.hunk_started = true %} {% set diff_location = line|parse_diff_location %} {% set vars.original_line = diff_location[0][0] %} {% set vars.modified_line = diff_location[1][0] %} <h3 class="diff-position">{{ line }}</h3> <pre class="code-view"> {% elif vars.hunk_started %} {% if line.startswith("+") %} <span class="line-number">{{ vars.modified_line }} +</span> <ins>{{ line[1:] }}</ins> {% set vars.modified_line = vars.modified_line + 1 %} {% elif line.startswith("-") %} <span class="line-number">{{ vars.original_line }} -</span> <del>{{ line[1:] }}</del> {% set vars.original_line = vars.original_line + 1 %} {% elif not line.startswith("\\") %} {% if line %} <span class="line-number">{{ vars.modified_line }} </span> <x-codeline>{{ line[1:] }}</x-codeline> {% endif %} {% if not line.startswith("@@") %} {% set vars.original_line = vars.original_line + 1 %} {% set vars.modified_line = vars.modified_line + 1 %} {% endif %} {% endif %} {% endif %} {% endfor %} {% if vars.hunk_started %} </pre> <!-- close the last hunk --> {% endif %} </section> </article> {% endfor %} </x-vbox> </x-vbox></x-frame> </x-vbox> {% endblock %}
templates/repository/repo-log.html
@@ -54,12 +54,12 @@
<section class="card-main flexible-space"> <h3><a href="/{{ username }}/{{ repository }}/commit/{{ commit.sha }}">{{ commit.message | split("\n") | first }}</a></h3> <p> {% trans owner_name=commit.owner_name, author_date=commit.author_date.strftime("%A, %e %B %Y, %H:%M:%S"), receive_date=commit.receive_date.strftime('%A, %e %B %Y, %H:%M:%S') %}{% trans owner_name=commit.owner_name %}by <a href="/{{ owner_name }}">{{ owner_name }}</a>, <span title="received on {{ receive_date }}">{{ author_date }}</span>{% endtrans %} <span title="{% trans receive_date=commit.receive_date.strftime('%A, %e %B %Y, %H:%M:%S') %}received on {{ receive_date }}{% endtrans %}"> {{ commit.author_date.strftime("%A, %e %B %Y, %H:%M:%S") }} </span></p> <code>{{ commit.sha }}</code> </section>