mobile: swipe-back easier completion threshold (25%) + readback telemetry to confirm conversation actually translates (batch141)
This commit is contained in:
@@ -1158,7 +1158,7 @@
|
|||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<script src="/icons.js?v=6"></script>
|
<script src="/icons.js?v=6"></script>
|
||||||
<script>window.__BUILD='2026-07-19-batch140';console.log('%cBiz Connect','color:#1F3B73;font-weight:bold','build '+window.__BUILD);
|
<script>window.__BUILD='2026-07-19-batch141';console.log('%cBiz Connect','color:#1F3B73;font-weight:bold','build '+window.__BUILD);
|
||||||
// Emoji are rendered with the OS's own (colour) emoji font — instant, zero network.
|
// Emoji are rendered with the OS's own (colour) emoji font — instant, zero network.
|
||||||
//
|
//
|
||||||
// We used to run Twemoji over every emoji, which swapped each one for an <img> pulled INDIVIDUALLY from
|
// We used to run Twemoji over every emoji, which swapped each one for an <img> pulled INDIVIDUALLY from
|
||||||
@@ -5012,8 +5012,9 @@ window.addEventListener('popstate', ()=>{ if(bzcBack()){ try{ history.pushState(
|
|||||||
if(!dragging){ armed=false; return; }
|
if(!dragging){ armed=false; return; }
|
||||||
const t=(e.changedTouches&&e.changedTouches[0]);
|
const t=(e.changedTouches&&e.changedTouches[0]);
|
||||||
const dx=t?Math.max(0,t.clientX-sx):0, dt=Math.max(1,Date.now()-t0), v=dx/dt;
|
const dx=t?Math.max(0,t.clientX-sx):0, dt=Math.max(1,Date.now()-t0), v=dx/dt;
|
||||||
if(window.bzDbg) window.bzDbg('swipe',{s:'end',dx:Math.round(dx),w:Math.round(w),v:Math.round(v*100)/100,done:(dx>w*0.35||(v>0.5&&dx>40))?1:0}); // TEMP
|
const _done = dx>w*0.25 || (v>0.35 && dx>50); // easier to complete (was 35%)
|
||||||
if(dx>w*0.35 || (v>0.5 && dx>40)){ // complete the pop
|
if(window.bzDbg){ var _ct=content?getComputedStyle(content).transform:'x', _cl=content?Math.round(content.getBoundingClientRect().left):-1, _lt=chatcol?getComputedStyle(chatcol).transform:'x'; window.bzDbg('swipe',{s:'end',dx:Math.round(dx),done:_done?1:0,cMoved:(_ct&&_ct!=='none'&&_ct!=='x')?1:0,cLeft:_cl,lMoved:(_lt&&_lt!=='none'&&_lt!=='x')?1:0}); } // TEMP: cMoved/cLeft prove whether the conversation actually translated
|
||||||
|
if(_done){ // complete the pop
|
||||||
if(content){ content.style.transition='transform .17s cubic-bezier(.4,0,.7,.4)'; content.style.transform='translate3d(100%,0,0)'; }
|
if(content){ content.style.transition='transform .17s cubic-bezier(.4,0,.7,.4)'; content.style.transform='translate3d(100%,0,0)'; }
|
||||||
if(chatcol){ chatcol.style.transition='transform .17s cubic-bezier(.4,0,.7,.4)'; chatcol.style.transform='translate3d(0,0,0)'; }
|
if(chatcol){ chatcol.style.transition='transform .17s cubic-bezier(.4,0,.7,.4)'; chatcol.style.transform='translate3d(0,0,0)'; }
|
||||||
setTimeout(()=>{ document.body.classList.remove('chat-dragging'); showWelcome(true); if(content){ content.style.transition=''; content.style.transform=''; } if(chatcol){ chatcol.style.transition=''; chatcol.style.transform=''; } armed=false; dragging=false; content=null; chatcol=null; }, 175);
|
setTimeout(()=>{ document.body.classList.remove('chat-dragging'); showWelcome(true); if(content){ content.style.transition=''; content.style.transform=''; } if(chatcol){ chatcol.style.transition=''; chatcol.style.transform=''; } armed=false; dragging=false; content=null; chatcol=null; }, 175);
|
||||||
|
|||||||
Reference in New Issue
Block a user