Files
website-v2/templates/versions/detail.html
daveoconnor 69a652d066 Release reports refactor (#1996) (#1999)
Co-authored-by: Greg Kaleka <greg@gregkaleka.com>
2025-12-01 10:27:05 -08:00

186 lines
10 KiB
HTML

{% extends "base.html" %}
{% load i18n %}
{% load static %}
{% load text_helpers %}
{% load avatar_tags %}
{% load version_select %}
{% block title %}{% blocktrans with version_name=version.display_name %}Boost {{ version_name }}{% endblocktrans %}{% endblock %}
{% block description %}{% blocktrans with version_name=version.display_name %}Discover what's new in Boost {{ version_name }}{% endblocktrans %}{% endblock %}
{% block content %}
<main>
{% if selected_version %}
<div class="py-3 px-3 md:mt-3 md:px-0 mb-0 w-full flex flex-row flex-nowrap items-center"
x-data="{'showSearch': false}"
x-on:keydown.escape="showSearch=false">
<div class="flex-auto pb-1 w-full">
<div>
<span class="text-xl md:text-3xl">{{ heading }}</span>
<span class="text-lg whitespace-nowrap md:text-xl pr-[1vw]">({{ version.display_name }})</span>
<span><a href="{% url 'downloads_feed_rss' %}" title="RSS feed" class="text-sky-600 dark:text-sky-400 hover:text-orange"><i class="fa-solid fa-rss"></i></a></span>
</div>
</div>
<div class="flex-shrink text-right">
{% version_select %}
</div>
</div>
<!-- alert for non-current Boost versions -->
{% include "libraries/includes/version_alert.html" %}
<section class="content">
<div class="flex flex-row pb-2 w-full h-auto md:pb-0 md:w-auto">
<div class="flex flex-col h-full max-w-md">
<div class="h-8">
<span class="block pb-1 text-xs md:text-base font-bold">{{ version.release_date|date:"F j, Y" }}</span>
</div>
<div class="-ml-2 h-3"></div>
<div class="flex flex-col h-full justify-between">
<div>
<div class="-ml-2 h-14">
<a class="block items-center py-1 px-2 rounded cursor-pointer hover:bg-gray-100 dark:hover:bg-slate text-sky-600 dark:text-sky-300 hover:text-orange dark:hover:text-orange"
href="{{ documentation_url }}">
<span class="dark:text-white text-slate">Documentation</span>
<span class="block text-xs">{{ request.scheme }}://{{ request.get_host }}{{ documentation_url }}</span>
</a>
</div>
<div class="-ml-2 h-14">
<a class="block items-center py-1 px-2 rounded cursor-pointer hover:bg-gray-100 dark:hover:bg-slate text-sky-600 dark:text-sky-300 hover:text-orange dark:hover:text-orange"
href="{{ version.github_url }}">
<i class="float-right mt-1 fab fa-github"></i>
<span class="dark:text-white text-slate">Source Code</span>
<span class="block text-xs">{{ version.github_url|cut:"https://" }}</span>
</a>
</div>
{% if release_report_url %}
<div class="-ml-2 h-14">
<a class="block items-center py-1 px-2 rounded cursor-pointer hover:bg-gray-100 dark:hover:bg-slate text-sky-600 dark:text-sky-300 hover:text-orange dark:hover:text-orange"
href="{{ release_report_url }}">
<span class="dark:text-white text-slate">Release Report</span>
<span class="block text-xs">{{ release_report_file_name }}</span>
</a>
</div>
{% endif %}
</div>
{% if not version.beta %}
{% if deps.added or deps.removed %}
<div class="-ml-2">
<div class="block items-center py-1 px-2">
<span class="dark:text-white text-slate font-semibold">Dependencies</span>
<div class="text-base whitespace-normal">
{% if deps.added %}
There {{ deps.added|pluralize:"was,were" }}
<span class="text-red-700">
{{ deps.added }} dependenc{{ deps.added|pluralize:"y,ies"}} added
</span>
(in {{ deps.increased_dep_lib_count }} librar{{ deps.increased_dep_lib_count|pluralize:"y,ies" }})
{% endif %}
{% if deps.added and deps.removed %}
and
{% endif %}
{% if deps.removed %}
{% if not deps.added %}
There {{ deps.removed|pluralize:"was,were" }}
{% endif %}
<span class="text-[rgb(14,174,96)] dark:text-green">
{{ deps.removed }} dependenc{{ deps.removed|pluralize:"y,ies"}} removed
</span>
(in {{ deps.decreased_dep_lib_count }} librar{{ deps.decreased_dep_lib_count|pluralize:"y,ies" }})
{% endif %}
this release.
</div>
</div>
</div>
{% elif dependencies_not_calculated %}
<div class="text-base whitespace-normal text-sm">
Library dependency calculations will be generated soon, please check back later.
</div>
{% endif %}
</div>
{% endif %}
</div>
</div>
<div class="overflow-x-hidden pb-2 pl-0 ml-0 space-x-6 w-full scroll-smooth h-auto md:pb-0 md:ml-6">
<div class="flex space-x-3">
{% if downloads %}
<table class="p-0 m-0 w-full text-sm text-left border-0 border-separate table-auto dark:text-white border-spacing-0 text-slate">
<tbody>
<tr>
<th scope="col"
width="150"
class="p-3 h-8 text-base bg-gray-100 border border-r-0 border-b-0 border-gray-400 dark:border-slate dark:bg-charcoal text-center">
Platform
</th>
<th scope="col"
width="700"
class="p-3 text-base bg-gray-100 border border-r-0 border-b-0 border-gray-400 dark:border-slate dark:bg-charcoal">
File
</th>
<th scope="col"
colspan="2"
class="p-3 text-base bg-gray-100 border border-b-0 border-gray-400 dark:border-slate dark:bg-charcoal">
SHA256 Hash
</th>
</tr>
{% for os, download_files in downloads.items %}
{% for download in download_files %}
<tr>
{% if forloop.first %}
<th scope="row"
rowspan="{{ download_files|length }}"
class="p-2 h-14 whitespace-normal border border-r-0 {% if not forloop.parentloop.last %}border-b-0 {% endif %}border-gray-400 dark:border-slate dark:bg-charcoal text-center">
<i class="fab fa-{% if os == 'Unix' %}linux{% else %}windows{% endif %}"></i> {{ os }}
</th>
{% endif %}
<td class="p-2 border border-r-0 {% if not forloop.last or not forloop.parentloop.last %}border-b-0 {% endif %}border-gray-400 dark:border-slate">
<a href="{{ download.url }}" class="text-sky-600 dark:text-sky-300 hover:text-orange dark:hover:text-orange">{{ download.display_name }}</a>
</td>
<td width="30"
class="p-2 mx-1 text-center align-bottom whitespace-nowrap border border-r-0 {% if not forloop.last or not forloop.parentloop.last %}border-b-0 {% endif %}border-gray-400 dark:border-slate">
<button class="justify-center items-center w-4 h-full font-semibold shadow"
@click="$clipboard($el.parentElement.nextSibling.nextSibling.title)">
<svg class="text-sky-600 dark:text-sky-300 hover:text-orange dark:hover:text-orange fill-current" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">
<path d="m6 19v2c0 .621.52 1 1 1h2v-1.5h-1.5v-1.5zm7.5 3h-3.5v-1.5h3.5zm4.5 0h-3.5v-1.5h3.5zm4-3h-1.5v1.5h-1.5v1.5h2c.478 0 1-.379 1-1zm-1.5-1v-3.363h1.5v3.363zm0-4.363v-3.637h1.5v3.637zm-13-3.637v3.637h-1.5v-3.637zm11.5-4v1.5h1.5v1.5h1.5v-2c0-.478-.379-1-1-1zm-10 0h-2c-.62 0-1 .519-1 1v2h1.5v-1.5h1.5zm4.5 1.5h-3.5v-1.5h3.5zm3-1.5v-2.5h-13v13h2.5v-1.863h1.5v3.363h-4.5c-.48 0-1-.379-1-1v-14c0-.481.38-1 1-1h14c.621 0 1 .522 1 1v4.5h-3.5v-1.5z" />
</svg>
</button>
</td>
<td class="border pr-2 text-xs {% if not forloop.last or not forloop.parentloop.last %}border-b-0 {% endif %}border-l-0 border-gray-400 dark:border-slate truncCell dark:bg-charcoal"
title="{{ download.checksum }}">
<span class="hidden xl:block">{{ download.checksum }}</span>
<span class="hidden md:block xl:hidden">{{ download.checksum|truncate_middle:20 }}</span>
<span class="md:hidden">{{ download.checksum|truncate_middle:10 }}</span>
</td>
</tr>
{% endfor %}
{% endfor %}
</tbody>
</table>
{% endif %}
</div>
</div>
</section>
{% if release_notes %}
<section id="libraryReadMe"
class="boostlook p-6 my-4 bg-white md:rounded-lg md:shadow-lg dark:text-white text-slate dark:bg-charcoal dark:bg-neutral-700">
{{ release_notes|safe }}
</section>
{% endif %}
{% if top_contributors_release %}
<section id="releaseContributors"
class="p-6 my-4 bg-white md:rounded-lg md:shadow-lg dark:text-white text-slate dark:bg-charcoal dark:bg-neutral-700">
<h2 class="text-2xl mt-0">Contributors</h2>
<div class="grid md:grid-cols-2 lg:grid-cols-3 xl:grid-cols-4 gap-y-3 gap-x-2">
{% for author in top_contributors_release %}
{% avatar commitauthor=author avatar_type="wide" contributor_label="Contributor" %}
{% endfor %}
</div>
</section>
{% endif %}
{% endif %}
</main>
{% endblock %}