Files
damn_simple_architecture/dsx/dsx_server/templates/components/file.html.tera
T
2026-02-23 20:32:45 +00:00

17 lines
891 B
Plaintext

{% macro file_view(package, file) %}
<div class="file-row">
<span class="file-icon">
{% if file.is_dir %}
<svg width="14" height="14" viewBox="0 0 24 24" fill="currentColor" style="color:#4f8ef7" ><path d="M3 7a2 2 0 012-2h4l2 2h8a2 2 0 012 2v9a2 2 0 01-2 2H5a2 2 0 01-2-2V7z"/></svg>
{% else %}
<svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><path d="M14 2H6a2 2 0 00-2 2v16a2 2 0 002 2h12a2 2 0 002-2V8z"/><polyline points="14 2 14 8 20 8"/></svg>
{% endif %}
</span>
<span class="file-name">
<a href="/packages/{{ package }}/~repo/{{ file.path }}">{{ file.name }}</a>
</span>
<!--<span class="file-commit">{{ file.last_commit_message | default(value="") }}</span>
<span class="file-age">{{ file.last_modified | default(value="") }}</span>-->
</div>
{% endmacro %}