fix: center header title + bump to v1.7.3 for update detection

- CSS: header-title-wrap uses position:absolute with left:0/right:0
  + justify-content:center so title is truly centered regardless of
  button count on each side (kiosk has 2 left / 3 right)
- header-actions gets margin-left:auto to push right; both sides z-index:1
- Bump version 1.7.2 → 1.7.3 so already-open kiosk tabs will see
  the update badge once the new version is deployed to the server
- CSS cache bust: ?v=20260506a
This commit is contained in:
dadaloop82
2026-05-06 05:19:37 +00:00
parent af9bae3093
commit f48fb02589
3 changed files with 18 additions and 6 deletions
+15 -3
View File
@@ -123,6 +123,7 @@ body {
display: flex; display: flex;
align-items: center; align-items: center;
width: 100%; width: 100%;
position: relative;
gap: 8px; gap: 8px;
} }
@@ -132,17 +133,25 @@ body {
display: flex; display: flex;
align-items: center; align-items: center;
gap: 6px; gap: 6px;
position: relative;
z-index: 1;
} }
/* Title wrap — fills available space, left-aligned */ /* Title wrap — absolutely centered in the full header width */
.header-title-wrap { .header-title-wrap {
flex: 1 1 0; position: absolute;
left: 0;
right: 0;
display: flex; display: flex;
justify-content: center;
align-items: center; align-items: center;
gap: 8px; gap: 8px;
min-width: 0; pointer-events: none;
overflow: hidden; overflow: hidden;
} }
.header-title-wrap > * {
pointer-events: auto;
}
.header-title { .header-title {
font-size: 1.3rem; font-size: 1.3rem;
@@ -218,9 +227,12 @@ body {
/* Actions — fixed-width, no stretching */ /* Actions — fixed-width, no stretching */
.header-actions { .header-actions {
flex: 0 0 auto; flex: 0 0 auto;
margin-left: auto;
display: flex; display: flex;
gap: 8px; gap: 8px;
align-items: center; align-items: center;
position: relative;
z-index: 1;
} }
/* ── Base header button — all action icons use this ─────────────────── */ /* ── Base header button — all action icons use this ─────────────────── */
+2 -2
View File
@@ -11,7 +11,7 @@
<title>EverShelf</title> <title>EverShelf</title>
<link rel="manifest" href="manifest.json"> <link rel="manifest" href="manifest.json">
<link rel="icon" type="image/png" href="assets/img/logo/logo_icon.png"> <link rel="icon" type="image/png" href="assets/img/logo/logo_icon.png">
<link rel="stylesheet" href="assets/css/style.css?v=20260505b"> <link rel="stylesheet" href="assets/css/style.css?v=20260506a">
<!-- QuaggaJS for barcode scanning --> <!-- QuaggaJS for barcode scanning -->
<script src="https://cdn.jsdelivr.net/npm/@ericblade/quagga2@1.8.4/dist/quagga.min.js"></script> <script src="https://cdn.jsdelivr.net/npm/@ericblade/quagga2@1.8.4/dist/quagga.min.js"></script>
<!-- @xenova/transformers: ES-module bootstrap that exposes a lazy category-classifier as window._categoryPipelinePromise --> <!-- @xenova/transformers: ES-module bootstrap that exposes a lazy category-classifier as window._categoryPipelinePromise -->
@@ -67,7 +67,7 @@
<!-- Title — left-aligned; grows to fill space --> <!-- Title — left-aligned; grows to fill space -->
<div class="header-title-wrap"> <div class="header-title-wrap">
<h1 class="header-title" onclick="showPage('dashboard')"> <h1 class="header-title" onclick="showPage('dashboard')">
<img src="assets/img/logo/logo_icon.png" alt="" class="header-logo-icon" aria-hidden="true" /><span data-i18n="nav.title">EverShelf</span><span class="header-version">v1.7.2</span> <img src="assets/img/logo/logo_icon.png" alt="" class="header-logo-icon" aria-hidden="true" /><span data-i18n="nav.title">EverShelf</span><span class="header-version">v1.7.3</span>
</h1> </h1>
<!-- Update badge — shown alongside title, never replaces it --> <!-- Update badge — shown alongside title, never replaces it -->
<span class="header-update-badge" id="header-update-badge" style="display:none"></span> <span class="header-update-badge" id="header-update-badge" style="display:none"></span>
+1 -1
View File
@@ -2,7 +2,7 @@
"name": "EverShelf", "name": "EverShelf",
"short_name": "EverShelf", "short_name": "EverShelf",
"description": "Gestione completa della dispensa di casa con scansione barcode", "description": "Gestione completa della dispensa di casa con scansione barcode",
"version": "1.7.2", "version": "1.7.3",
"start_url": "/evershelf/", "start_url": "/evershelf/",
"display": "standalone", "display": "standalone",
"background_color": "#f0f4e8", "background_color": "#f0f4e8",