PageSourceSearch

https://myka.ng/assets/PartnerRecordingPage-Bb0D6Kq6.js

js myka.ng collected 2026-10-09 22:44:18 UTC 2,807 bytes, 1 lines download raw bytes

1import{d as M,r as s,j as e}from"./vendor-react-DfYGAhtm.js";import{t as N,k as O,m as l,g as w}from"./index-DsBgCU7r.js";import{u as W,I as b,a as T,C as z,g as G}from"./recordingSteps-B9IUj48e.js";import{u as B,a as x,P as k}from"./index-CCvS5amz.js";import{h as V,a as r,V as v,T as o}from"./vendor-ui-DA_r9yXk.js";import"./vendor-icons-1odZwi-b.js";import"./vendor-state-BsBVN-fX.js";import"./vendor-forms-BP-7CbAP.js";import"./fix-webm-duration-DBGubGlL.js";import"./inspectionAnalysis.runtime-CbjBTDqp.js";import"./sseStream-C28FcIBw.js";import"./recording.constants-Cr2cQllO.js";import"./WitnessFlowLayout-sXdBrCkv.js";import"./device-DbCxnG1h.js";const g=G({surface:"app"}),ne=()=>{const p=M(),{sessionId:d,gadgetLabel:u}=B(),{videoRef:y,cameraError:P,stopAndGetUrl:f}=W(),[i,m]=s.useState(!1),[h,_]=s.useState(0),[S,I]=s.useState(b),[A,L]=s.useState(()=>{const t=sessionStorage.getItem(x);if(t){const n=Math.floor((Date.now()-parseInt(t,10))/1e3);return Math.max(0,T-n)}return sessionStorage.setItem(x,Date.now().toString()),T}),a=s.useCallback(async()=>{if(!i){m(!0);try{const t=await f();if(sessionStorage.removeItem(x),!t){N.error("We could not save that recording. Please try again."),p(k.start(d),{replace:!0});return}p(k.preview(d),{state:{videoUrl:t}})}catch{N.error("Could not finish recording. Please try again."),m(!1)}}},[i,p,d,f]),R=s.useRef(a);s.useEffect(()=>{R.current=a},[a]),s.useEffect(()=>{const t=setInterval(()=>{L(n=>{const C=Math.max(0,n-1);return C===0&&setTimeout(()=>R.current(),0),C}),I(n=>n<=1?0:n-1)},1e3);return()=>clearInterval(t)},[]);const c=g[h],j=h===g.length-1,E=S>0,D=()=>{_(t=>Math.min(t+1,g.length-1)),I(b)};return e.jsxs(V,{gap:0,minH:"100dvh",pb:8,children:[e.jsx(r,{display:"flex",justifyContent:"center",pt:8,pb:3,children:e.jsx(O,{variant:"light",alt:"Myka",h:"36px"})}),e.jsxs(v,{gap:0,px:6,pb:4,align:"center",children:[e.jsx(o,{fontSize:"xl",fontWeight:"bold",color:l.text.primary,textAlign:"center",children:c?.heading}),u?e.jsxs(o,{fontSize:"xs",color:l.text.info,textAlign:"center",children:["Inspecting ",u]}):null]}),e.jsx(r,{px:4,children:e.jsx(z,{videoRef:y,cameraError:P,secondsLeft:A})}),e.jsx(r,{px:4,pt:4,children:e.jsx(r,{bg:"orange.50",borderRadius:"2xl",px:5,py:4,children:e.jsxs(v,{gap:2,align:"center",children:[e.jsx(o,{fontSize:"10px",fontWeight:"bold",color:"orange.500",letterSpacing:"widest",textTransform:"uppercase",children:c?.label}),e.jsx(o,{fontSize:"md",fontWeight:"bold",color:l.text.primary,textAlign:"center",children:c?.title}),e.jsx(o,{fontSize:"sm",color:l.text.info,textAlign:"center",children:c?.subtitle})]})})}),e.jsx(r,{px:5,pt:6,mt:"auto",children:e.jsx(w,{text:E?`Keep recording… (${S}s)`:j?"Done Recording":"Next",fullWidth:!0,loading:i,disabled:i||E,onClick:j?()=>void a():D})})]})};export{ne as default};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.