feat: v6.0.0 PWA offline support

- manifest + icones, service worker (precache, network-first, Background Sync)

- module client FlowOffline (IndexedDB, queue, delta, flush) + hook editeur

- endpoints /api/v2/sync/{delta,batch,status} + moteur de sync (conflits LWW/orpheline/copie offline)

- migrations offline_sync_queue + sync_version (triggers)

- UI offline (banner, badge sync, toasts, icone dirty) + doc /help

- tests pytest (sync, migrations, SW, offline) + E2E Playwright; bump 6.0.0
This commit is contained in:
2026-09-18 13:05:40 -04:00
parent 62620ef884
commit b5207216f1
35 changed files with 3115 additions and 23 deletions
+19
View File
@@ -1024,6 +1024,25 @@ def test_pwa_manifest(client):
data = resp.json()
assert data["name"] == "FlowDeck"
assert data["display"] == "standalone"
assert any(i.get("sizes") == "192x192" for i in data["icons"])
def test_pwa_manifest_static_assets():
"""v6.0.0: the static manifest and every referenced icon must exist on disk."""
import json
from pathlib import Path
root = Path(__file__).resolve().parent.parent
manifest_path = root / "static" / "manifest.json"
assert manifest_path.is_file(), "static/manifest.json missing"
manifest = json.loads(manifest_path.read_text(encoding="utf-8"))
assert manifest["name"] == "FlowDeck"
assert "icons" in manifest and len(manifest["icons"]) >= 8
for icon in manifest["icons"]:
src = icon["src"].lstrip("/")
assert (root / src).is_file(), f"icon missing: {src}"
# ══════════════════════════════════════════════════════