Blender Studio pull request - Version 2.2.0 update #104394

Merged
Márton Lente merged 64 commits from ui/v2.2.0 into main 2024-04-08 16:32:44 +02:00
Showing only changes of commit d17fc89428 - Show all commits

View File

@ -72,98 +72,104 @@
</div>
</div>
</div>
<div class="align-items-start mb-3 row">
<div class="col-12 col-md mb-2 pb-24">
{% include "common/components/navigation/buttons_toolbar.html" with item=asset %}
</div>
</div>
<div class="align-items-center mb-3 row">
<div class="col-auto d-flex">
{% include 'common/components/cards/card_profile.html' with user=asset.static_asset.user title="Publisher" %}
</div>
{# Exclude the author in case author is mistakenly included into contributors as well #}
{% with asset_author=asset.static_asset.author|default:asset.static_asset.user contributors=asset.static_asset.contributors %}
{% if contributors.count > 1 or contributors.count == 1 and contributors.first.pk != asset_author.pk %}
<div class="col-auto">
<div class="contributors d-flex align-items-center">
<span class="opacity-50 pe-2 text-muted">
<i class="i-plus"></i>
</span>
<div class="me-2">
{% comment %} <h4 class="comment-name mb-0">{{ asset.static_asset.contributors.all|length}} Other{% if asset.static_asset.contributors.all|length > 1 %}s{% endif %}:</h4> {% endcomment %}
<div class="d-flex">
<div class="d-flex pe-2">
{% for contributor in contributors.all %}
{% if contributor.pk != asset_author.pk %}
{% include 'users/components/avatar.html' with user=contributor %}
{% endif %}
{% endfor %}
</div>
<button class="btn btn-link" data-bs-toggle="dropdown" href="">
<i class="i-chevron-down"></i>
</button>
<div class="dropdown-menu dropdown-menu-end mt-2 pb-0 pt-2 px-2">
<h4 class="text-muted">Other contributors:</h4>
{% for contributor in contributors.all %}
{% if contributor.pk != asset_author.pk %}
<div class="dropdown-item dropdown-item-text">
<div class="profile-card py-2">
<div class="col-12">
<div class="pb-3 row">
<div class="col-auto d-flex">
{% include 'common/components/cards/card_profile.html' with user=asset.static_asset.user title="Publisher" %}
</div>
{# Exclude the author in case author is mistakenly included into contributors as well #}
{% with asset_author=asset.static_asset.author|default:asset.static_asset.user contributors=asset.static_asset.contributors %}
{% if contributors.count > 1 or contributors.count == 1 and contributors.first.pk != asset_author.pk %}
<div class="col-auto">
<div class="contributors d-flex align-items-center">
<span class="opacity-50 pe-2 text-muted">
<i class="i-plus"></i>
</span>
<div class="me-2">
{% comment %} <h4 class="comment-name mb-0">{{ asset.static_asset.contributors.all|length}} Other{% if asset.static_asset.contributors.all|length > 1 %}s{% endif %}:</h4> {% endcomment %}
<div class="d-flex">
<div class="d-flex pe-2">
{% for contributor in contributors.all %}
{% if contributor.pk != asset_author.pk %}
{% include 'users/components/avatar.html' with user=contributor %}
{% endif %}
{% endfor %}
</div>
<button class="btn btn-link" data-bs-toggle="dropdown" href="">
<i class="i-chevron-down"></i>
</button>
<div class="dropdown-menu dropdown-menu-end mt-2 pb-0 pt-2 px-2">
<h4 class="text-muted">Other contributors:</h4>
{% for contributor in contributors.all %}
{% if contributor.pk != asset_author.pk %}
<div class="dropdown-item dropdown-item-text">
<div class="profile-card py-2">
{% include 'users/components/avatar.html' with user=contributor %}
<div class="profile-details">
<span class="profile-name">{{ contributor.full_name }}</span>
{% for crew in contributor.film_crew.all %}
{% if crew.film.id == film.id %}
<small class="profile-title">{{ crew.role }}</small>
{% endif %}
{% endfor %}
<div class="profile-details">
<span class="profile-name">{{ contributor.full_name }}</span>
{% for crew in contributor.film_crew.all %}
{% if crew.film.id == film.id %}
<small class="profile-title">{{ crew.role }}</small>
{% endif %}
{% endfor %}
</div>
</div>
</div>
</div>
</div>
{% endif %}
{% endfor %}
{% endif %}
{% endfor %}
</div>
</div>
</div>
</div>
</div>
</div>
</div>
{% endif %}
{% endwith %}
{# TODO: Check style 'text-sm' #}
<div class="align-items-end col d-flex flex-column justify-content-end text-muted text-sm x-sm">
<div class="d-flex">
{% if request.user.is_authenticated %}
{% if asset.is_free %}
<div class="me-2">
{% include "common/components/cards/pill.html" with class="fs-sm ms-1" label='Free' %}
</div>
{% endif %}
{% endif %}
<div class="me-2">
<div class="badge fs-sm">
{{ asset.static_asset.get_source_type_display }}
{% endwith %}
{# TODO: Check style 'text-sm' #}
<div class="align-items-end col d-flex flex-column justify-content-end text-muted text-sm x-sm">
<div class="d-flex">
{% if request.user.is_authenticated %}
{% if asset.is_free %}
<div class="me-2">
{% include "common/components/cards/pill.html" with class="fs-sm ms-1" label='Free' %}
</div>
{% endif %}
{% endif %}
<div class="me-2">
<div class="badge fs-sm">
{{ asset.static_asset.get_source_type_display }}
</div>
</div>
<div class="me-2">
{{ asset.date_published|date:"N jS, Y" }}
</div>
</div>
<div class="d-flex">
{% if asset.static_asset.license %}
<a href="{{ asset.static_asset.license.url }}" target="_blank" class="me-2 text-muted"
data-bs-toggle="tooltip" data-placement="bottom" title="{{ asset.static_asset.license.description }}">
{{ asset.static_asset.license }}
</a>
{% endif %}
{% if asset.static_asset.copyright %}
<p class="me-2">
<i class="i-copyright"></i>
{{ asset.static_asset.copyright }}
</p>
{% endif %}
</div>
</div>
<div class="me-2">
{{ asset.date_published|date:"N jS, Y" }}
</div>
</div>
<div class="d-flex">
{% if asset.static_asset.license %}
<a href="{{ asset.static_asset.license.url }}" target="_blank" class="me-2 text-muted"
data-bs-toggle="tooltip" data-placement="bottom" title="{{ asset.static_asset.license.description }}">
{{ asset.static_asset.license }}
</a>
{% endif %}
{% if asset.static_asset.copyright %}
<p class="me-2">
<i class="i-copyright"></i>
{{ asset.static_asset.copyright }}
</p>
{% endif %}
</div>
<div class="border-bottom"></div>
</div>
</div>
<div class="align-items-start mb-3 row">
<div class="col-12 col-md mb-2 pb-24">
{% include "common/components/navigation/buttons_toolbar.html" with item=asset %}
</div>
</div>
<div class="markdown-text">