1
0
Fork 0
mirror of https://github.com/retspen/webvirtcloud synced 2026-12-03 17:36:05 +00:00

feat(ui): the menu marks the page's section, names Jobs and Administration and counts unfinished jobs

The page's own section was not marked: the active class sat on the list item,
which Bootstrap 5 does not style. It now sits on the link with aria-current,
underlined (a side bar on a phone). The links are full white on the theme's
navbar instead of 55 %. Jobs and Administration carry labels (icons only between
768 and 991px), the menus open aligned to the right, and Jobs shows a badge with
the user's queued, running and cancelling jobs. The user menu's disabled
'Language: tr' line is a working language switch.

Operation.visible_to replaces the jobs views' _visible, shared with the badge.
This commit is contained in:
catborise 2026-11-25 16:29:29 +03:00
parent f62a62c027
commit 1c8e204c95
13 changed files with 173 additions and 44 deletions

View file

@ -349,6 +349,50 @@ td .tag-more {
height: 0.85em;
}
/* the menu: its links in the full light of the theme's navbar, an icon beside each label; the page's own
section underlined (on a phone, a bar at its side) and bolder */
.navbar-dark {
--bs-navbar-color: #fff;
--bs-navbar-hover-color: #fff;
--bs-navbar-active-color: #fff;
}
.navbar .nav-link {
display: flex;
align-items: center;
gap: .375rem;
}
.navbar .nav-link svg {
flex: none;
}
.navbar .nav-link.active {
font-weight: 600;
box-shadow: inset 3px 0 0 currentColor;
padding-left: .75rem;
}
@media (min-width: 768px) {
.navbar .nav-link.active {
box-shadow: inset 0 -2px 0 currentColor;
padding-left: var(--bs-navbar-nav-link-padding-x);
}
.navbar .nav-link:hover:not(.active) {
box-shadow: inset 0 -2px 0 rgba(255, 255, 255, .45);
}
}
.navbar .dropdown-item svg {
vertical-align: -.125em;
}
/* between a phone and a wide screen the labels of Jobs and Administration do not fit: their icons stay */
@media (min-width: 768px) and (max-width: 991.98px) {
.navbar .nav-label {
position: absolute;
width: 1px;
height: 1px;
overflow: hidden;
clip: rect(0, 0, 0, 0);
white-space: nowrap;
}
}
/* "Skip to content" brings #main up below the sticky navbar, not behind it */
#main {
scroll-margin-top: 5rem;

View file

@ -1,11 +0,0 @@
<?xml version="1.0" ?>
<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="currentColor" class="bi bi-person-plus" viewBox="0 0 16 16">
<path d="M6 8a3 3 0 1 0 0-6 3 3 0 0 0 0 6zm2-3a2 2 0 1 1-4 0 2 2 0 0 1 4 0zm4 8c0 1-1 1-1 1H1s-1 0-1-1 1-4 6-4 6 3 6 4zm-1-.004c-.001-.246-.154-.986-.832-1.664C9.516 10.68 8.289 10 6 10c-2.29 0-3.516.68-4.168 1.332-.678.678-.83 1.418-.832 1.664h10z"/>
<path fill-rule="evenodd" d="M13.5 5a.5.5 0 0 1 .5.5V7h1.5a.5.5 0 0 1 0 1H14v1.5a.5.5 0 0 1-1 0V8h-1.5a.5.5 0 0 1 0-1H13V5.5a.5.5 0 0 1 .5-.5z"/>
</svg>

Before

Width:  |  Height:  |  Size: 573 B