Feature: Staging-Workflow — develop-Branch, make staging/release, APP_VERSION 1.0.0, Staging-Banner — SW by-v513
This commit is contained in:
parent
9d3f902014
commit
041af92306
7 changed files with 100 additions and 14 deletions
|
|
@ -94,6 +94,15 @@
|
|||
</head>
|
||||
<body>
|
||||
|
||||
<!-- Staging-Banner (nur auf staging.banyaro.app) -->
|
||||
<div id="staging-banner"
|
||||
style="display:none;position:fixed;top:0;left:0;right:0;z-index:10000;
|
||||
background:#7c3aed;color:#fff;font-size:0.75rem;font-weight:700;
|
||||
padding:5px 16px;align-items:center;justify-content:center;gap:8px;
|
||||
letter-spacing:0.04em;text-transform:uppercase">
|
||||
⚗️ Staging-Umgebung — Keine Produktionsdaten
|
||||
</div>
|
||||
|
||||
<!-- Offline-Banner -->
|
||||
<div id="offline-banner" aria-live="polite"
|
||||
style="display:none;position:fixed;top:0;left:0;right:0;z-index:9999;
|
||||
|
|
|
|||
|
|
@ -3,7 +3,9 @@
|
|||
Router, State-Management, Navigation, Initialisierung.
|
||||
============================================================ */
|
||||
|
||||
const APP_VER = '489'; // ← bei jedem Deploy mit Frontend-Änderungen erhöhen
|
||||
const APP_VER = '490'; // ← bei jedem Deploy mit Frontend-Änderungen erhöhen
|
||||
const APP_VERSION = '1.0.0'; // ← semantische Version, wird bei make release gesetzt
|
||||
const IS_STAGING = location.hostname === 'staging.banyaro.app';
|
||||
|
||||
const App = (() => {
|
||||
|
||||
|
|
@ -860,4 +862,11 @@ const App = (() => {
|
|||
})();
|
||||
|
||||
// App starten
|
||||
document.addEventListener('DOMContentLoaded', () => App.init());
|
||||
document.addEventListener('DOMContentLoaded', () => {
|
||||
if (IS_STAGING) {
|
||||
const b = document.getElementById('staging-banner');
|
||||
if (b) b.style.display = 'flex';
|
||||
document.title = '⚗️ ' + document.title;
|
||||
}
|
||||
App.init();
|
||||
});
|
||||
|
|
|
|||
|
|
@ -334,7 +334,7 @@ window.Page_settings = (() => {
|
|||
<span style="background:var(--c-surface-2);border:1px solid var(--c-border);
|
||||
border-radius:100px;padding:2px 10px;font-family:monospace;
|
||||
font-size:10px;color:var(--c-text-muted)">
|
||||
v${typeof APP_VER !== 'undefined' ? APP_VER : '—'}
|
||||
v${typeof APP_VERSION !== 'undefined' ? APP_VERSION : '1.0.0'} <span style="opacity:0.5;font-size:10px">(${typeof APP_VER !== 'undefined' ? APP_VER : '—'})</span>
|
||||
</span>
|
||||
<button id="settings-check-update" style="background:none;border:none;cursor:pointer;
|
||||
font-size:var(--text-xs);color:var(--c-primary);padding:2px 6px;
|
||||
|
|
@ -588,7 +588,7 @@ window.Page_settings = (() => {
|
|||
reg.waiting.postMessage({ type: 'SKIP_WAITING' });
|
||||
UI.toast.success('Update wird installiert…');
|
||||
} else {
|
||||
UI.toast.success('Ban Yaro ist aktuell (v' + (typeof APP_VER !== 'undefined' ? APP_VER : '—') + ').');
|
||||
UI.toast.success('Ban Yaro ist aktuell — v' + (typeof APP_VERSION !== 'undefined' ? APP_VERSION : '1.0.0') + '.');
|
||||
}
|
||||
} catch {
|
||||
UI.toast.error('Update-Prüfung fehlgeschlagen.');
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
{
|
||||
"id": "/",
|
||||
"version": "1.0.0",
|
||||
"name": "Ban Yaro — Die Hunde-Plattform",
|
||||
"short_name": "Ban Yaro",
|
||||
"description": "Alles rund um deinen Hund. Von Welpe bis Opa.",
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@
|
|||
Offline-Cache + Push Notifications + Tile-Cache
|
||||
============================================================ */
|
||||
|
||||
const CACHE_VERSION = 'by-v512';
|
||||
const CACHE_VERSION = 'by-v513';
|
||||
const CACHE_STATIC = `${CACHE_VERSION}-static`;
|
||||
const CACHE_TILES = 'ban-yaro-tiles-v1'; // bleibt über SW-Updates erhalten
|
||||
const CACHE_API = 'ban-yaro-api-v1'; // API-Response-Cache
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue