v1.34.0: leer QR con la cámara

Botón ⌗ QR junto a cada campo (direcciones, URI de pago, txid, xpub,
PSBT, tx en crudo). Enseña lo leído y pide confirmar. Rechaza semillas y
claves privadas sin mostrarlas. Foto de respaldo sin cámara en directo.
Librería qr 0.7.2 (Paul Miller) en vendor/qr/, con su huella en SETUP.
Pruebas en tests/test22.js.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01L5npnUYgSPkAaHkdaeUqBr
This commit is contained in:
2026-10-22 00:40:23 +02:00
co-authored by Claude Opus 5.5
parent b486f04427
commit e2adf88f77
13 changed files with 458 additions and 4 deletions
+2
View File
@@ -136,6 +136,7 @@
style={{flex:1,background:C.bg,border:`1px solid ${C.borderBright}`,borderRadius:6,padding:"9px 12px",color:C.t1,fontFamily:C.mono,fontSize:"0.75rem",outline:"none"}}
onFocus={e=>e.target.style.borderColor=C.blue} onBlur={e=>e.target.style.borderColor=C.borderBright}
/>
<BotonQR campo="direccion" color={C.blue} onLeido={v=>setAddr(v)}/>
<button onClick={validate} style={{padding:"9px 16px",background:C.blueMuted,border:`1px solid ${C.blue}40`,borderRadius:6,color:C.blue,fontFamily:C.mono,fontSize:"0.72rem",cursor:"pointer",fontWeight:700}}>COMPROBAR</button>
</div>
{result&&(
@@ -204,6 +205,7 @@
style={{flex:1,background:C.bg,border:`1px solid ${C.borderBright}`,borderRadius:6,padding:"9px 12px",color:C.t1,fontFamily:C.mono,fontSize:"0.75rem",outline:"none"}}
onFocus={e=>e.target.style.borderColor=C.blue} onBlur={e=>e.target.style.borderColor=C.borderBright}
/>
<BotonQR campo="txid" color={C.blue} onLeido={v=>setTxid(v)}/>
<button onClick={decode} style={{padding:"9px 16px",background:C.blueMuted,border:`1px solid ${C.blue}40`,borderRadius:6,color:C.blue,fontFamily:C.mono,fontSize:"0.72rem",cursor:"pointer",fontWeight:700}}>{loading?"···":"DETECTAR"}</button>
</div>
{err&&<div style={{padding:"8px 12px",background:C.redMuted,border:`1px solid ${C.red}30`,borderRadius:6,color:C.red,fontFamily:C.mono,fontSize:"0.72rem"}}>{err}</div>}