PageSourceSearch

https://www.30sec.ai/_next/static/chunks/1196.eb800eb4733ae776.js

js 30sec.ai collected 2026-10-05 14:15:26 UTC 22,279 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[1196],{81196:function(e,t,n){n.r(t),n.d(t,{default:function(){return de}});var r=n(85893),o=n(67294),i=n(26447),s=n(15861),a=n(78462),c=n(70891),l=n(59334),u=n(48885),d=["You have 10 seconds to read the question",(0,r.jsxs)(r.Fragment,{children:["The video recording then ",(0,r.jsx)(s.Z,{component:"span",fontWeight:700,children:"starts automatically"})]}),"You have 30 seconds to record your response",(0,r.jsx)(s.Z,{component:"span",fontWeight:700,children:"Only 1 attempt allowed "})],h=function(){return(0,r.jsx)(r.Fragment,{children:(0,r.jsxs)(i.Z,{spacing:3,children:[(0,r.jsx)(s.Z,{children:" You must record a video response to a question on data science. "}),(0,r.jsx)(a.Z,{children:d.map((function(e,t){return(0,r.jsxs)(c.ZP,{sx:{py:1},children:[(0,r.jsx)(u.Z,{sx:{minWidth:0,pr:2},children:"->"}),(0,r.jsx)(l.Z,{children:e})]},"video-instr-".concat(t))}))})]})})},f=n(83321),p=n(99226),x=n(47568),m=n(34051),g=n.n(m),v=n(99964),j=function(e){var t=e.show,n=(e.onAbort,e.children);return(0,r.jsx)(r.Fragment,{children:(0,r.jsx)(v.Z,{open:t,onClose:function(){},children:(0,r.jsx)(p.Z,{height:"auto",padding:10,sx:{position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)",backgroundColor:"grey.400",borderRadius:2},children:n})})})},b=n(31170),w=n(69661),y=n(49990),Z=n(41796),C=n(2734);function k(e){var t,n=e.Icon,o=e.onClick,i=void 0===o?function(){}:o,a=e.color,c=void 0===a?"default":a,l=(e.animation,e.label),u=void 0===l?"":l,d=(0,C.Z)();if("green"===c)t=d.palette.success.dark;else t=d.palette.error.dark;return(0,r.jsx)(r.Fragment,{children:(0,r.jsxs)(p.Z,{sx:{position:"relative"},children:[(0,r.jsx)(s.Z,{sx:{position:"absolute",bottom:"110%",left:"50%",transform:"translate(-50%,0)",fontSize:"15px",width:"120px",textAlign:"center",color:"white"},children:u}),(0,r.jsx)(y.Z,{onClick:i,children:(0,r.jsx)(w.Z,{sx:{border:"2px solid ".concat((0,Z.Fq)(d.palette.grey[400],.5)),backgroundColor:d.palette.common.white,width:d.spacing(8),height:d.spacing(8)},children:(0,r.jsx)(n,{sx:{color:t}})})})]})})}function S(e){var t=e.children,n=e.heightPercentOfViewport,o=void 0===n?70:n,i=e.width,s=void 0===i?null:i;e.align;return(0,r.jsx)(r.Fragment,{children:(0,r.jsx)(p.Z,{width:s||"".concat(9*o/16,"vh"),sx:{aspectRatio:"9/16",display:"flex",justifyContent:"center",position:"relative",minWidth:s?null:281.25,bgcolor:"#434141"},children:t})})}function E(e){var t=e.children,n=e.justifyContent,o=void 0===n?"center":n;return(0,r.jsx)(r.Fragment,{children:(0,r.jsx)(p.Z,{px:2,sx:{position:"absolute",width:"100%",display:"flex",alignItems:"center",justifyContent:o,height:"20%",bottom:0},children:t})})}var F=n(59047),I=function(e){var t=e.show,n=e.onClick,o=(0,F.rS)();return(0,r.jsx)(r.Fragment,{children:t&&(0,r.jsxs)(S,{children:[(0,r.jsx)(p.Z,{sx:{width:"100%",position:"absolute",top:"15%",display:"flex",alignItems:"center",flexDirection:"column"},children:(0,r.jsxs)(s.Z,{px:2,color:"common.white",textAlign:"center",sx:{lineHeight:1.6,fontSize:"1.4rem"},children:["You must first enable your Camera and Mic ",(0,r.jsx)("br",{}),(0,r.jsx)("br",{}),"Please accept, if your browser asks you for permissions"]})}),(0,r.jsx)(E,{children:(0,r.jsx)(k,{Icon:b.Z,onClick:function(){o.event("click","enable-camera"),n()},label:"Enable Camera"})})]})})},q=n(64970),R=n.n(q),P=n(72787),z=n(98396),A=n(30223);function T(e){var t=e.show,n=(0,o.useState)(!1),i=n[0],a=n[1],c=(0,A.U)();return(0,o.useEffect)((function(){if(t){var e=localStorage.getItem("nocam"),n=(e?parseInt(e):0)+1;localStorage.setItem("nocam",n.toString()),n>=2&&a(!0)}}),[t]),(0,o.useEffect)((function(){i&&c.setError({title:"Cannot enable Mic & Camera",body:(0,r.jsxs)(r.Fragment,{children:["A security feature on your device may be blocking the camera and mic. ",(0,r.jsx)("br",{}),(0,r.jsx)("br",{})," Follow the instructions on the screen, or try from another device. ",(0,r.jsx)("br",{}),(0,r.jsx)("br",{})," Your safest bet is on Google Chrome from a Windows computer."]})})}),[i]),t?(0,r.jsx)(r.Fragment,{children:(0,r.jsx)(p.Z,{sx:{position:"absolute",top:"10%",width:"100%"},children:(0,r.jsx)(s.Z,{textAlign:"center",sx:{lineHeight:1.3,fontSize:"1.4rem",padding:"0px 5%",color:"white"},children:(0,r.jsxs)(r.Fragment,{children:["We cannot access to your camera. ",(0,r.jsx)("br",{}),(0,r.jsx)("br",{})," Click on ",(0,r.jsx)("img",{src:"/Lock.svg",height:"20px"})," or ",(0,r.jsxs)("span",{style:{position:"relative"},children:[(0,r.jsx)("img",{src:"/VideoCam.svg",height:"15px"})," ",(0,r.jsx)("img",{src:"/Cross.svg",height:"20px",style:{position:"absolute",right:"-30%",bottom:"-20%"}})]})," ",(0,r.jsx)("br",{}),"in the address bar above, ",(0,r.jsx)("br",{})," and allow camera ","&"," mic permissions ",(0,r.jsx)("br",{}),(0,r.jsx)("br",{})," Then refresh the page."]})})})}):null}var U=function(e){var t,n=e.show,a=e.onClick,c=(0,o.useState)(!1),l=c[0],u=c[1],d=(0,C.Z)(),h=(0,z.Z)(d.breakpoints.up("sm")),x=(0,F.rS)(),m=(0,A.U)();return t=P.yG?{height:640,width:360}:h?{height:720,width:405,facingMode:"user"}:{width:1e3,height:562,facingMode:"user"},n?l?(0,r.jsx)(r.Fragment,{children:(0,r.jsx)(S,{children:(0,r.jsx)(T,{show:!0})})}):(0,r.jsx)(r.Fragment,{children:(0,r.jsxs)(i.Z,{spacing:3,children:[(0,r.jsx)(p.Z,{display:"flex",justifyContent:"center",children:(0,r.jsx)(S,{width:"200px",children:(0,r.jsx)(R(),{audio:!0,width:"100%",height:"auto",forceScreenshotSourceSize:!0,muted:!0,mirrored:!0,onUserMediaError:function(){x.event("camera-error","camera-check"),m.setError({title:"Unable to access Camera",body:"Close this popup and follow the instructions on the screen."}),u(!0)},onUserMedia:function(){},videoConstraints:t})})}),(0,r.jsx)(s.Z,{textAlign:"center",children:"Seat yourself comfortably, and press the button below"}),(0,r.jsx)(f.Z,{fullWidth:!0,variant:"contained",onClick:function(){x.event("done","camera-check"),a()},children:"Start"})]})}):null},W=n(45511);function M(e){var t=e.question,n=e.show,o=e.id,i=void 0===o?null:o;return n?(0,r.jsx)(r.Fragment,{children:(0,r.jsx)(p.Z,{id:i,sx:{position:"absolute",top:"40%",transform:"translate(0%, -50%)",width:"100%"},children:(0,r.jsx)(s.Z,{textAlign:"center",sx:{lineHeight:1.7,fontSize:"1.4rem",padding:"0px 5%",color:"white",whiteSpace:"pre-line"},children:t})})}):null}var D=n(64666),_=n(37645),L=n(6514),V=n(58951),Y=n(31425),B=n(85071),H=function(e){var t=e.show,n=e.onAccept,i=(0,o.useState)(!1),a=i[0],c=i[1];return(0,r.jsx)(r.Fragment,{children:(0,r.jsxs)(D.Z,{open:t,onClose:function(){},PaperProps:{sx:{marginTop:1}},children:[(0,r.jsx)(_.Z,{id:"alert-dialog-title",children:"Before you start"}),(0,r.jsx)(L.Z,{style:{position:"relative"},children:(0,r.jsxs)(V.Z,{id:"alert-dialog-description",children:["Please confirm the following",(0,r.jsxs)(p.Z,{display:"flex",alignItems:"center",py:1,borderRadius:2,children:[(0,r.jsx)(p.Z,{pr:2,children:(0,r.jsx)(B.Z,{checked:a,onChange:function(){c((function(e){return!e}))}})}),(0,r.jsx)(s.Z,{children:" I am seated in a quiet place that is suitable for video recording"})]})]})}),(0,r.jsx)(Y.Z,{sx:{marginBottom:1},children:(0,r.jsx)(f.Z,{disabled:!a,onClick:n,color:"primary",variant:"contained",children:" Continue "})})]})})},N=function(e){return(0,r.jsxs)(s.Z,{variant:"h6",fontWeight:700,sx:{whiteSpace:"pre-line"},children:[" ",e]})},O=function(e){var t=e.show,n=(e.question,e.onComplete),i=e.firstLoad,a=(0,F.rS)(),c=(0,o.useState)(!1),l=c[0],u=c[1],d=(0,C.Z)();if(!t)return null;var h=function(e){var t=e?"check":"enable";return[{content:N("Get familiar with the Video recording tool"),placement:"center",target:"body"},{content:N("Read the question carefully"),floaterProps:{disableAnimation:!0},spotlightPadding:20,target:"#question-text"},{content:N("The time remaining is shown here in seconds"),floaterProps:{disableAnimation:!0},spotlightPadding:20,target:"#countdown"},{content:N("This progress bar will also help you track the time "),floaterProps:{disableAnimation:!0},spotlightPadding:20,placement:"top",target:"#countdown-bar"},{content:N("First you will be asked to ".concat(t," your camera")),placement:"center",target:"body"}]}(!i);return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsxs)(S,{children:[(0,r.jsx)(W.ZP,{callback:function(e){var t=e.status;e.type;[W.Q_.FINISHED,W.Q_.SKIPPED].includes(t)&&(t===W.Q_.FINISHED?a.event("finished","guided-tour"):a.event("skipped","guided-tour"),u(!0))},continuous:!0,hideCloseButton:!0,run:!0,scrollToFirstStep:!0,showProgress:!0,showSkipButton:!0,steps:h,styles:{options:{zIndex:1e4,primaryColor:d.palette.primary.main}}}),(0,r.jsx)(M,{id:"question-text",show:!0,question:"Your question will appear here"}),(0,r.jsxs)(p.Z,{width:"100%",height:"100%",position:"absolute",children:[(0,r.jsx)(p.Z,{id:"countdown-bar",width:"100%",height:"20%",bgcolor:(0,Z.Fq)(d.palette.primary.dark,.4),sx:{position:"absolute",left:"0%",bottom:"0%"}}),(0,r.jsx)(p.Z,{sx:{position:"absolute",right:"0%",top:"0%"},px:2,py:2,id:"countdown",children:(0,r.jsx)(s.Z,{color:"white",variant:"h4",children:"30 s"})})]})]}),(0,r.jsx)(H,{show:l,onAccept:n})]})},G=(0,n(59874).Z)((function(e){return{small:{display:"flex",justifyContent:"center",position:"absolute",right:"0%",bottom:"0%",transform:"translate(25%,25%)"}}}));function Q(e){var t=e.children;G();
1return(0,r.jsx)(p.Z,{height:"250px",maxHeight:"40%",sx:{display:"flex",justifyContent:"center",position:"absolute",right:"0%",bottom:"0%",transform:"translate(25%,25%)"},children:t})}var K,X=n(66120);var J=function(e){var t=e.show,n=e.state,i=e.onFinish,s=e.onError,a=e.onSuccess,c=e.getRecordedTime,l=void 0===c?function(e){}:c,u=(0,o.useRef)(null),d=(0,o.useRef)(null),h=(0,o.useState)(!1),f=h[0],p=h[1],x=(0,o.useState)(new Date),m=x[0],g=x[1],v=(0,o.useState)(new Date),j=v[0],b=v[1],w=(0,o.useState)(0),y=w[0],Z=w[1],k=(0,C.Z)(),S=(0,z.Z)(k.breakpoints.up("sm")),E=(0,A.U)();K=S?{height:720,width:405,facingMode:"user"}:{width:1e3,height:562,facingMode:"user"},(0,o.useEffect)((function(){l(y)}),[y]),(0,o.useEffect)((function(){Z((function(e){return e+(j.getTime()-m.getTime())/1e3}))}),[j]);var F=function(e){E.setError({title:"Unable to access Camera",body:"Close this popup and follow the instructions on the screen."}),s()};(0,o.useEffect)((function(){"finished"===n&&(!f&&b(new Date),d.current.stop(),p(!1)),"paused"===n&&(b(new Date),d.current.pause(),p(!0)),"recording"===n&&(g(new Date),I())}),[n]);var I=function(){try{f?(d.current.resume(),p(!1)):(d.current=new MediaRecorder(u.current.stream,{mimeType:"video/webm"}),d.current.addEventListener("dataavailable",q),d.current.onerror=F,d.current.start())}catch(e){s()}},q=function(e){var t=e.data;t.size>0&&(0,X.Z)(new Blob([t],{type:"video/webm"}),(function(e){i(e)}))},P=(0,r.jsx)(R(),{audio:!0,width:"auto",height:"100%",forceScreenshotSourceSize:!0,ref:u,muted:!0,mirrored:!0,onUserMediaError:F,onUserMedia:a,videoConstraints:K});return(0,r.jsx)(r.Fragment,{children:t&&(0,r.jsx)(Q,{children:P})})};function $(e){var t=e.onFinish,n=e.show,i=(0,o.useState)(3),a=i[0],c=i[1],l=(0,o.useState)(!1),u=l[0],d=l[1];(0,o.useEffect)((function(){var e=null;return u?e=setInterval((function(){c((function(e){return e-1}))}),1e3):clearInterval(e),function(){clearInterval(e)}}),[u]);if((0,o.useEffect)((function(){n&&d(!0),!n&&(c(3),d(!1))}),[n]),(0,o.useEffect)((function(){-1===a&&t()}),[a]),!n)return null;var h=(0,C.Z)();return(0,r.jsx)(r.Fragment,{children:(0,r.jsxs)(p.Z,{sx:{position:"relative",width:"100%",height:"100%",bgcolor:(0,Z.Fq)(h.palette.common.black,.9)},children:[(0,r.jsx)(s.Z,{textAlign:"center",variant:"h5",sx:{position:"absolute",top:"30%",width:"100%",color:"common.white"},children:"Video recording begins in..."}),(0,r.jsx)(s.Z,{variant:"h2",sx:{color:"common.white",fontSize:"80px",position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)"},children:a>0?a:"Speak"})]})})}var ee=n(53247),te=function(e){var t=e.start,n=e.startTime,i=e.onComplete,a=(0,C.Z)(),c=(0,o.useState)(n),l=c[0],u=c[1];(0,o.useEffect)((function(){if(t&&l>0){var e=setInterval((function(){u((function(e){return e-1}))}),1e3);return function(){return clearInterval(e)}}}),[l,t]),(0,o.useEffect)((function(){l<=0&&i()}),[l]);var d=20+80*(n-l)/n;return(0,r.jsx)(r.Fragment,{children:(0,r.jsxs)(p.Z,{width:"100%",height:"100%",position:"absolute",children:[(0,r.jsx)(p.Z,{id:"countdown-bar",width:"100%",height:"".concat(d,"%"),bgcolor:(0,Z.Fq)(a.palette.primary.dark,.4),sx:{position:"absolute",left:"0%",bottom:"0%"}}),(0,r.jsx)(p.Z,{sx:{position:"absolute",right:"0%",top:"0%"},px:2,py:2,id:"countdown",children:(0,r.jsx)(s.Z,{color:l>5?"white":"secondary.main",variant:"h4",children:"".concat(l," s")})})]})})},ne=function(e){var t=e.show,n=e.question,i=e.onComplete,s=(0,o.useState)("waiting"),a=s[0],c=s[1],l=(0,o.useState)(null),u=(l[0],l[1]),d=(0,o.useState)(new Date),h=d[0],f=d[1],p=(0,F.rS)();if((0,o.useEffect)((function(){c("countdown")}),[t]),!t)return null;return(0,r.jsx)(r.Fragment,{children:(0,r.jsxs)(S,{children:[(0,r.jsx)(te,{start:"recording"===a,startTime:30,onComplete:function(){p.event("finish-with-time","video-recording"),c("finished")}}),(0,r.jsx)(M,{question:n,show:"error"!==a}),(0,r.jsx)(T,{show:"error"===a}),(0,r.jsx)($,{show:"countdown"===a,onFinish:function(){p.event("start","video-recording"),f(new Date),c("recording")}}),(0,r.jsx)(J,{show:!0,state:a,onFinish:function(e){!function(e){u(e),c("waiting"),i(e)}(e)},onError:function(){(new Date).getTime()-h.getTime()<300?p.event("error","camera"):p.event("permission-denied","camera"),c("error")},onSuccess:function(){localStorage.setItem("nocam","0".toString())}}),(0,r.jsx)(E,{children:["recording"].includes(a)&&(0,r.jsx)(k,{Icon:ee.Z,onClick:function(){p.event("finish-with-click","video-recording"),c("recording"===a?"finished":"waiting")},label:"Finish"})})]})})},re=n(39252),oe=function(e){var t=e.show,n=e.url,i=e.onComplete,s=(0,F.rS)();return(0,o.useEffect)((function(){s.event("viewed","video-preview")}),[]),(0,r.jsx)(r.Fragment,{children:t&&(0,r.jsxs)(S,{children:[(0,r.jsx)(re.Z,{url:n,showLogo:!1,loop:!0,startMuted:!1}),(0,r.jsx)(E,{children:(0,r.jsx)(f.Z,{color:"secondary",sx:{color:"black",fontWeight:700},fullWidth:!0,variant:"contained",onClick:function(){s.event("approved","video-preview"),i()},children:"Continue"})})]})})},ie=n(18377),se=n(92708),ae=n(93468),ce=function(e){var t=e.blobUrl,n=e.onError,i=e.onComplete,s=void 0===i?function(e){}:i,a=(0,o.useState)(!0),c=a[0],l=(a[1],(0,o.useState)(0)),u=l[0],d=l[1],h=(0,A.U)(),f=function(e,t,r,o){return new Promise((function(t,i){var s=new XMLHttpRequest;s.upload.addEventListener("progress",(function(e){if(e.lengthComputable){var t=100*e.loaded/e.total;d(t)}}),!1),s.open("PUT",e,!0),s.onload=function(){200===s.status?(0,ae.i)("/api/gcp/upload-complete",{file_name:o.file}).then((function(e){t(o)})):(n(),h.setError({title:"File upload failed",body:"Refresh your browser and try again. We ap
1ologize for the inconvenience"}),i())},s.onerror=function(){n(),h.setError({title:"File upload failed",body:"Refresh your browser and try again. We apologize for the inconvenience"}),i()},s.setRequestHeader("Content-Type",r.type),s.send(r)}))},p=function(){var e=(0,x.Z)(g().mark((function e(){var r;return g().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,Promise.all([t].map(function(){var e=(0,x.Z)(g().mark((function e(t,r){var o,i,s,a;return g().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,fetch(t).then((function(e){return e.blob()}));case 2:return o=e.sent,e.next=5,(0,ae.R)("/api/gcp/signedURL?sizeInMB=".concat(o.size/1e6,"&type=").concat(o.type));case 5:return(i=e.sent).success||(n(),h.setError({title:"File upload failed",body:"Refresh your browser and try again. We apologize for the inconvenience"})),s=i.data,a={url:t,file:s.file_name},e.abrupt("return",f(s.url,0,o,a));case 10:case"end":return e.stop()}}),e)})));return function(t,n){return e.apply(this,arguments)}}()));case 3:r=e.sent,s(r[0]),e.next=11;break;case 7:e.prev=7,e.t0=e.catch(0),n(),h.setError({title:"File upload failed",body:"Refresh your browser and try again. We apologize for the inconvenience"});case 11:case"end":return e.stop()}}),e,null,[[0,7]])})));return function(){return e.apply(this,arguments)}}();(0,o.useEffect)((function(){p()}),[]);var m=Math.min(u,99);return(0,r.jsx)(r.Fragment,{children:(0,r.jsx)(v.Z,{open:c,onClose:function(){},children:(0,r.jsx)(ie.Z,{height:"auto",padding:10,sx:{position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)",backgroundColor:"white",borderRadius:2},children:(0,r.jsx)(se.Z,{value:m,text:"Files are uploading"})})})})},le=function(e){var t=e.show,n=e.question,i=e.onAbort,s=e.onComplete,a=e.assessmentId,c=e.sectionId,l=(0,o.useState)(null),u=l[0],d=l[1],h=(0,o.useState)(!0),f=h[0],p=h[1],m=(0,o.useState)("guided-tour"),v=m[0],b=m[1],w=(0,A.U)();if((0,o.useEffect)((function(){f&&"check-camera"===v&&p(!1)}),[t,v]),!t)return null;var y=function(){var e=(0,x.Z)(g().mark((function e(t){var n,r;return g().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t.url,n=t.file,e.next=3,(0,ae.i)("/api/campaigns/submit/single-section",{id:c,assessId:a,data:{fileName:n}});case 3:if(!(r=e.sent).success){e.next=8;break}b("preview"),e.next=17;break;case 8:e.t0=r.exitCode,e.next=81===e.t0?11:44===e.t0?13:15;break;case 11:return w.setError({title:"There's a problem at our end",body:"Please refresh the page and try again. We apologize for the issue."}),e.abrupt("break",16);case 13:return w.setError({title:"Duplicate submission",body:"You are only allowed 1 attempt for this video assessment, which you have already used."}),e.abrupt("break",16);case 15:w.setError({title:"Refresh the page",body:"Your login may have expired, you need to sign in first to submit this assessment."});case 16:i();case 17:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}();return(0,r.jsx)(r.Fragment,{children:(0,r.jsxs)(j,{show:t,onAbort:i,children:[(0,r.jsx)(O,{show:"guided-tour"===v,question:n,onComplete:function(){return b(f?"enable-camera":"check-camera")},firstLoad:!0}),(0,r.jsx)(I,{show:"enable-camera"===v,onClick:function(){b("check-camera")}}),(0,r.jsx)(U,{show:"check-camera"===v,onClick:function(){b("recording")}}),(0,r.jsx)(ne,{show:"recording"===v,question:n,onComplete:function(e){d(e),b("uploading")}}),"uploading"===v&&(0,r.jsx)(ce,{blobUrl:u,onComplete:y,onError:function(){}}),(0,r.jsx)(oe,{show:"preview"===v,url:u,onComplete:function(){b("check-camera"),s(u)}})]})})},ue=n(5030),de=function(e){var t=e.showErrors,n=e.onUpdate,a=e.customization,c=void 0===a?null:a,l=(0,o.useState)(!1),u=l[0],d=l[1],x=(0,o.useState)(!1),m=x[0],g=x[1],v=(0,A.U)(),j=((0,F.rS)(),(0,o.useState)(null)),b=j[0],w=j[1],y=(0,o.useState)(!1),Z=y[0],C=y[1],k=(null===c||void 0===c?void 0:c.title)?c.title:"Video assessment",S=(null===c||void 0===c?void 0:c.question)?c.question:null,E=!!(null===c||void 0===c?void 0:c.hideInstructions)&&c.hideInstructions,I=null!==b||u;return(0,o.useEffect)((function(){(0,ae.R)("/api/campaigns/submit/check-submit-status?assessId=".concat(c._jobAd.id,"&sectionId=").concat(c._id)).then((function(e){if(e.success)e.data.submitted&&d(!0);else if(81===e.exitCode)v.setError({title:"There's a problem at our end",body:"Please refresh the page and try again. We ap
1ologize for the issue."});else v.setError({title:"Refresh the page",body:"Your login may have expired, you will to sign in first to submit this assessment."})}))}),[]),(0,o.useEffect)((function(){n(u?{isValid:!0,values:{}}:{isValid:!1,values:{}})}),[u]),(0,r.jsxs)(r.Fragment,{children:[(0,r.jsxs)(i.Z,{children:[(0,r.jsxs)(s.Z,{fontWeight:700,mb:3,variant:"h6",children:[" ",k]}),b&&(0,r.jsx)(f.Z,{onClick:function(){C(!0)},fullWidth:!0,variant:"contained",sx:{backgroundColor:"success.main"},children:"View my response"}),!b&&(0,r.jsxs)(i.Z,{spacing:3,children:[!E&&!u&&(0,r.jsx)(h,{}),u&&(0,r.jsx)(s.Z,{children:" You have previously submitted your response to this question. It cannot be re-attempted."}),(0,r.jsxs)(p.Z,{children:[(0,r.jsx)(f.Z,{disabled:!1,fullWidth:!0,variant:"contained",onClick:function(){u||g(!0)},color:u?"success":t&&!I?"error":"primary",children:u?"Response submitted":"Record you response"}),t&&!I&&(0,r.jsx)(s.Z,{marginTop:1,color:"error.main",variant:"body2",children:"You must record a video*"})]})]})]}),(0,r.jsx)(le,{question:S,show:m,onAbort:function(){g(!1)},onComplete:function(e){w(e),g(!1),n({isValid:!0,values:{}})},sectionId:c._id,assessmentId:c._jobAd.id}),(0,r.jsx)(ue.Z,{open:Z,onClose:function(){C(!1)},url:b})]})}},92708:function(e,t,n){n.d(t,{Z:function(){return a}});var r=n(85893),o=n(98456),i=n(15861),s=n(99226);function a(e){var t=e.value,n=e.text,a=e.minValue,c=void 0===a?30:a,l=Math.max(c,t);return(0,r.jsx)(r.Fragment,{children:(0,r.jsxs)(s.Z,{display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[(0,r.jsxs)(s.Z,{position:"relative",display:"inline-flex",children:[(0,r.jsx)(o.Z,{variant:"determinate",value:l,color:"primary",size:100}),(0,r.jsx)(s.Z,{top:0,left:0,bottom:0,right:0,position:"absolute",display:"flex",alignItems:"center",justifyContent:"center",children:(0,r.jsx)(i.Z,{variant:"caption",component:"div",children:"".concat(Math.round(l),"%")})})]}),(0,r.jsx)(s.Z,{mt:3,width:"100%",children:(0,r.jsxs)(i.Z,{align:"center",children:[" ",n]})})]})})}},5030:function(e,t,n){var r=n(85893),o=n(39252),i=n(99964),s=n(18377),a=n(44672),c=n(59359);t.Z=function(e){var t=e.url,n=e.open,l=e.onClose;return(0,r.jsx)(r.Fragment,{children:(0,r.jsx)(i.Z,{open:n,onClose:l,children:(0,r.jsx)(s.Z,{height:"auto",sx:{position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)"},children:(0,r.jsx)(a.Z,{heightPercentOfViewport:c.tq?70:50,children:(0,r.jsx)(o.Z,{url:t,showLogo:!1})})})})})}},66120:function(e,t,n){n.d(t,{Z:function(){return o}});var r=n(65349);function o(e,t){var n=new r.Ej,o=new r.h,i=r.rj,s=new FileReader;s.onload=function(e){var r=this.result;o.decode(r).forEach((function(e){n.read(e)})),n.stop();var s=i.makeMetadataSeekable(n.metadatas,n.duration,n.cues),a=this.result.slice(n.metadataSize),c=new Blob([s,a],{type:"video/webm"});t(URL.createObjectURL(c))},s.readAsArrayBuffer(e),e=null}}}]);

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.