feat: scan page redesign — fixed 2x zoom, torch, camera flip, tabs, recents, AI number OCR

- Always-on 2x hardware zoom (CSS scale fallback)
- Torch button with toggle + visual feedback
- Camera flip (front/back) with settings persistence
- 3-tab input panel: Barcode / Name / AI
- Recent products chips (last 6 scanned, from localStorage)
- Live barcode code overlay during partial detection
- Confirm overlay (checkmark + name) on successful scan
- AI number OCR (Gemini reads barcode digits from image, shown after 4s)
- Guide corners frame in viewport
- PHP: gemini_number_ocr action + rate-limited
- Translations: new scan.* keys in it/en/de
This commit is contained in:
dadaloop82
2026-05-12 14:55:14 +00:00
parent 27ba41700f
commit 696a9c6d11
7 changed files with 613 additions and 157 deletions
+17 -1
View File
@@ -170,10 +170,26 @@
"qty_trace": "< 1"
},
"scan": {
"title": "Produkt scannen",
"title": "Scannen",
"mode_shopping": "🛒 Einkaufsmodus",
"mode_shopping_end": "✅ Einkauf beenden",
"spesa_btn": "🛒 Einkauf",
"zoom": "Zoom",
"tab_barcode": "Barcode",
"tab_name": "Name",
"tab_ai": "KI",
"recents_label": "Zuletzt",
"torch_hint": "Taschenlampe",
"torch_on": "Taschenlampe an",
"torch_off": "Taschenlampe aus",
"torch_unavailable": "Taschenlampe auf diesem Gerät nicht verfügbar",
"flip_hint": "Kamera wechseln",
"flip_front": "Frontkamera",
"flip_back": "Rückkamera",
"num_ocr_btn": "🔢 Zahlen mit KI lesen",
"num_ocr_searching": "Suche Barcode mit KI...",
"num_ocr_found": "Code gefunden: {code}",
"num_ocr_not_found": "Kein Barcode im Bild gefunden",
"barcode_placeholder": "Barcode eingeben...",
"quick_name_divider": "oder Name eingeben",
"quick_name_placeholder": "z.B.: Äpfel, Zucchini, Brot...",