Added logo for small screen

This commit is contained in:
Kevin Veen-Birkenbach 2025-07-05 18:54:18 +02:00
parent 20b6c731b8
commit d0f8d7d172
No known key found for this signature in database
GPG Key ID: 44D8F11FD62F878E
2 changed files with 19 additions and 0 deletions

View File

@ -19,6 +19,9 @@ function enterFullscreen() {
setFullWidth(true);
updateUrlFullscreen(true);
const logo = document.getElementById('navbar_logo');
if (logo) logo.classList.remove('d-none');
if (typeof adjustScrollContainerHeight === 'function') adjustScrollContainerHeight();
if (typeof updateCustomScrollbar === 'function') updateCustomScrollbar();
}
@ -33,6 +36,9 @@ function exitFullscreen() {
setFullWidth(false);
updateUrlFullscreen(false);
const logo = document.getElementById('navbar_logo');
if (logo) logo.classList.add('d-none');
if (typeof adjustScrollContainerHeight === 'function') adjustScrollContainerHeight();
if (typeof updateCustomScrollbar === 'function') updateCustomScrollbar();
if (typeof syncIframeHeight === 'function') syncIframeHeight();

View File

@ -53,6 +53,19 @@
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="navbarNav{{menu_type}}">
{% if menu_type == "header" %}
<a class="navbar-brand d-flex align-items-center d-none" id="navbar_logo" href="/">
<img
src="{{ platform.logo.cache }}"
alt="{{ platform.titel }}"
class="d-inline-block align-text-top"
style="height:2rem">
<div class="ms-2 d-flex flex-column">
<span class="fs-4 fw-bold mb-0">{{ platform.titel }}</span>
{# <small class="fs-7 text-muted">{{ platform.subtitel }}</small> #}
</div>
{% endif %}
</a>
<ul class="navbar-nav {% if menu_type == 'header' %}ms-auto{% endif %} btn-group">
{% for item in navigation[menu_type].children %}
{% if item.url or item.onclick %}