/
githubmirror
/
nbs
Обзор
Документация
Войти
/
githubmirror
/
nbs
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
.github/scripts/templates/index.html
102 строки
3 KB
Nikita Menkovich
feature: add ttl removal for files, fix: flake8 for generate-summary.py (#395)
12 фев 2024, 18:23
Не верифицирован
12 фев 2024, 18:23
5ac6477
Код
Авторство
О чём код?
<!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <title>Directory Listing for {{ directory }}</title> <style> body { font-family: Arial, sans-serif; margin: 0; padding: 0; background: #f4f4f4; } h1 { background: #007bff; color: white; padding: 10px 15px; } ul { list-style-type: none; padding: 0; margin: 0; } li { background: white; border-bottom: 1px solid #ddd; padding: 8px 15px; } li:last-child { border-bottom: none; } a { text-decoration: none; color: #007bff; } a:hover { text-decoration: underline; } .file-icon, .directory-icon { margin-right: 5px; } .file-icon:before { content: '📄'; /* File icon */ } .directory-icon:before { content: '📁'; /* Folder icon */ } .date, .size, .expiry_date { float: right; margin-left: 20px; color: #999; } .expired { color: #FF6666; } #timestamp { text-align: right; font-size: small; } </style> </head> <body> <h1>Directory listing for {{ directory }}</h1> <table> <thead> <tr> <th>Type</th> <th>File Name</th> <th>Expiry Date</th> <th>Date</th> <th>Size</th> </tr> </thead> <tbody> {% for entry in entries %} <tr> <th><span class="{{ 'directory-icon' if entry.type == 'directory' else 'file-icon' }}"></span></th> <th><a href="{{ entry.url }}">{{ entry.name }}</a></th> <th> {% if entry.expiry_date %} <span class="expiry_date {% if entry.is_expired %}expired{% endif %}" >{{ entry.expiry_date }}</span> {% endif %} </th> <th> {% if entry.date %} <span class="date">{{ entry.date }}</span> {% endif %} </th> <th> {% if entry.size %} <span class="size">{{ entry.size }}</span> {% endif %} </th> </tr> {% endfor %} </tbody> </table> <p id="timestamp">Generated on: {{ timestamp }}</p> </body> </html>