(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["test"],{"01bc":function(e,t,n){var r,i,o;n("4160"),n("caad"),n("d3b7"),n("ac1f"),n("2532"),n("3ca3"),n("5319"),n("841c"),n("159b"),n("ddb0"),n("2b3d");var a=n("6374");n("96cf");var s=n("c973");n("7037");(function(a,s){i=[n("3f39")],r=s,o="function"===typeof r?r.apply(t,i):r,void 0===o||(e.exports=o)})(0,(function(e){var t={log:function(){},info:function(){}};function n(e){e="undefined"!==typeof e?e:{};var n=this;this.cfg="undefined"!==typeof e.peerConnectionOptions?e.peerConnectionOptions:{},this.cfg.sdpSemantics="unified-plan",this.cfg.offerExtmapAllowMixed=!1,this.pcClient=null,this.dcClient=null,this.tnClient=null,this.sdpConstraints={offerToReceiveAudio:1,offerToReceiveVideo:1,voiceActivityDetection:!1},this.dataChannelOptions={ordered:!0},this.startVideoMuted="undefined"!==typeof e.startVideoMuted&&e.startVideoMuted,this.autoPlayAudio="undefined"===typeof e.autoPlayAudio||e.autoPlayAudio;var r=new URLSearchParams(window.location.search);this.useMic=r.has("useMic"),this.useMic||t.log("Microphone access is not enabled. Pass ?useMic in the url to enable it.");var i="localhost"===location.hostname||"127.0.0.1"===location.hostname,o="https:"===location.protocol;!this.useMic||i||o||(this.useMic=!1,t.error("Microphone access in the browser will not work if you are not on HTTPS or localhost. Disabling mic access."),t.error("For testing you can enable HTTP microphone access Chrome by visiting chrome://flags/ and enabling 'unsafely-treat-insecure-origin-as-secure'")),this.latencyTestTimings={TestStartTimeMs:null,UEReceiptTimeMs:null,UEPreCaptureTimeMs:null,UEPostCaptureTimeMs:null,UEPreEncodeTimeMs:null,UEPostEncodeTimeMs:null,UETransmissionTimeMs:null,BrowserReceiptTimeMs:null,FrameDisplayDeltaTimeMs:null,Reset:function(){this.TestStartTimeMs=null,this.UEReceiptTimeMs=null,this.UEPreCaptureTimeMs=null,this.UEPostCaptureTimeMs=null,this.UEPreEncodeTimeMs=null,this.UEPostEncodeTimeMs=null,this.UETransmissionTimeMs=null,this.BrowserReceiptTimeMs=null,this.FrameDisplayDeltaTimeMs=null},SetUETimings:function(e){this.UEReceiptTimeMs=e.ReceiptTimeMs,this.UEPreCaptureTimeMs=e.PreCaptureTimeMs,this.UEPostCaptureTimeMs=e.PostCaptureTimeMs,this.UEPreEncodeTimeMs=e.PreEncodeTimeMs,this.UEPostEncodeTimeMs=e.PostEncodeTimeMs,this.UETransmissionTimeMs=e.TransmissionTimeMs,this.BrowserReceiptTimeMs=Date.now(),this.OnAllLatencyTimingsReady(this)},SetFrameDisplayDeltaTime:function(e){null==this.FrameDisplayDeltaTimeMs&&(this.FrameDisplayDeltaTimeMs=Math.round(e),this.OnAllLatencyTimingsReady(this))},OnAllLatencyTimingsReady:function(e){}},this.createWebRtcVideo=function(){var e=document.getElementById("streamingVideo");e&&e.remove();var t=document.createElement("video");if(t.id="streamingVideo",t.playsInline=!0,t.disablepictureinpicture=!0,t.muted=!0,t.addEventListener("loadedmetadata",(function(e){n.onVideoInitialised&&n.onVideoInitialised()}),!0),"requestVideoFrameCallback"in HTMLVideoElement.prototype){var r=function e(r,i){if(i.receiveTime&&i.expectedDisplayTime){var o=i.presentationTime-i.receiveTime;n.aggregatedStats.receiveToCompositeMs=o}t.requestVideoFrameCallback(e)};t.requestVideoFrameCallback(r)}return t},this.video=this.createWebRtcVideo(),onsignalingstatechange=function(e){t.info("signaling state change:",e)},oniceconnectionstatechange=function(e){t.info("ice connection state change:",e)},onicegatheringstatechange=function(e){t.info("ice gathering state change:",e)},handleOnTrack=function(e){if(t.log("handleOnTrack",e.streams),e.track&&t.log("Got track - "+e.track.kind+" id="+e.track.id+" readyState="+e.track.readyState),"audio"!=e.track.kind)return"video"==e.track.kind&&(n.video.srcObject,e.streams[0]),n.video.srcObject=e.streams[0],void t.log("Set video source from video track ontrack.");handleOnAudioTrack(e.streams[0])},handleOnAudioTrack=function(e){if(n.video.srcObject!=e&&n.video.srcObject&&n.video.srcObject!==e){var r=document.createElement("Audio");if(t.log("audio>>",r),r.srcObject=e,!n.autoPlayAudio){var i=function e(){r.play(),n.video.removeEventListener("click",e)};n.video.addEventListener("click",i)}t.log("Created new audio element to play seperate audio stream.")}},setupDataChannel=function(e,r,i){try{var o=e.createDataChannel(r,i);return t.log("Created datachannel (".concat(r,")")),o.binaryType="arraybuffer",o.onopen=function(e){t.log("data channel (".concat(r,") connect")),n.onDataChannelConnected&&n.onDataChannelConnected()},o.onclose=function(e){t.log("data channel (".concat(r,") closed"))},o.onmessage=function(e){n.onDataChannelMessage&&n.onDataChannelMessage(e.data)},o}catch(a){return t.warn("No data channel",a),null}},onicecandidate=function(e){t.log("ICE candidate",e),e.candidate&&e.candidate.candidate&&n.onWebRtcCandidate(e.candidate)},handleCreateOffer=function(e){e.createOffer(n.sdpConstraints).then((function(t){mungeSDPOffer(t),e.setLocalDescription(t),n.onWebRtcOffer&&n.onWebRtcOffer(t)}),(function(){t.warn("Couldn't create offer")}))},mungeSDPOffer=function(e){e.sdp=e.sdp.replace("useinbandfec=1","useinbandfec=1;stereo=1;sprop-maxcapturerate=48000")},setupPeerConnection=function(e){e.SetBitrate&&t.log("Hurray! there's RTCPeerConnection.SetBitrate function"),e.onsignalingstatechange=onsignalingstatechange,e.oniceconnectionstatechange=oniceconnectionstatechange,e.onicegatheringstatechange=onicegatheringstatechange,e.ontrack=handleOnTrack,e.onicecandidate=onicecandidate},generateAggregatedStatsFunction=function(){return n.aggregatedStats||(n.aggregatedStats={}),function(e){var t={};e.forEach((function(e){"inbound-rtp"!=e.type||e.isRemote||"video"!=e.mediaType&&!e.id.toLowerCase().includes("video")||(t.timestamp=e.timestamp,t.bytesReceived=e.bytesReceived,t.framesDecoded=e.framesDecoded,t.packetsLost=e.packetsLost,t.bytesReceivedStart=n.aggregatedStats&&n.aggregatedStats.bytesReceivedStart?n.aggregatedStats.bytesReceivedStart:e.bytesReceived,t.framesDecodedStart=n.aggregatedStats&&n.aggregatedStats.framesDecodedStart?n.aggregatedStats.framesDecodedStart:e.framesDecoded,t.timestampStart=n.aggregatedStats&&n.aggregatedStats.timestampStart?n.aggregatedStats.timestampStart:e.timestamp,n.aggregatedStats&&n.aggregatedStats.timestamp&&(n.aggregatedStats.bytesReceived&&(t.bitrate=8*(t.bytesReceived-n.aggregatedStats.bytesReceived)/(t.timestamp-n.aggregatedStats.timestamp),t.bitrate=Math.floor(t.bitrate),t.lowBitrate=n.aggregatedStats.lowBitrate&&n.aggregatedStats.lowBitratet.bitrate?n.aggregatedStats.highBitrate:t.bitrate),n.aggregatedStats.bytesReceivedStart&&(t.avgBitrate=8*(t.bytesReceived-n.aggregatedStats.bytesReceivedStart)/(t.timestamp-n.aggregatedStats.timestampStart),t.avgBitrate=Math.floor(t.avgBitrate)),n.aggregatedStats.framesDecoded&&(t.framerate=(t.framesDecoded-n.aggregatedStats.framesDecoded)/((t.timestamp-n.aggregatedStats.timestamp)/1e3),t.framerate=Math.floor(t.framerate),t.lowFramerate=n.aggregatedStats.lowFramerate&&n.aggregatedStats.lowFrameratet.framerate?n.aggregatedStats.highFramerate:t.framerate),n.aggregatedStats.framesDecodedStart&&(t.avgframerate=(t.framesDecoded-n.aggregatedStats.framesDecodedStart)/((t.timestamp-n.aggregatedStats.timestampStart)/1e3),t.avgframerate=Math.floor(t.avgframerate)))),"track"!=e.type||"video_label"!=e.trackIdentifier&&"video"!=e.kind||(t.framesDropped=e.framesDropped,t.framesReceived=e.framesReceived,t.framesDroppedPercentage=e.framesDropped/e.framesReceived*100,t.frameHeight=e.frameHeight,t.frameWidth=e.frameWidth,t.frameHeightStart=n.aggregatedStats&&n.aggregatedStats.frameHeightStart?n.aggregatedStats.frameHeightStart:e.frameHeight,t.frameWidthStart=n.aggregatedStats&&n.aggregatedStats.frameWidthStart?n.aggregatedStats.frameWidthStart:e.frameWidth),"candidate-pair"==e.type&&e.hasOwnProperty("currentRoundTripTime")&&0!=e.currentRoundTripTime&&(t.currentRoundTripTime=e.currentRoundTripTime)})),n.aggregatedStats.receiveToCompositeMs&&(t.receiveToCompositeMs=n.aggregatedStats.receiveToCompositeMs,n.latencyTestTimings.SetFrameDisplayDeltaTime(n.aggregatedStats.receiveToCompositeMs)),n.aggregatedStats=t,n.onAggregatedStats&&n.onAggregatedStats(t)}},setupTracksToSendAsync=function(){var e=s(regeneratorRuntime.mark((function e(t){var r,i,o,s,c;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(t.addTransceiver("video",{direction:"recvonly"}),n.useMic){e.next=5;break}t.addTransceiver("audio",{direction:"recvonly"}),e.next=10;break;case 5:return r=!!n.useMic&&{autoGainControl:!1,channelCount:1,echoCancellation:!1,latency:0,noiseSuppression:!1,sampleRate:16e3,volume:1},e.next=8,navigator.mediaDevices.getUserMedia({video:!1,audio:r});case 8:if(i=e.sent,i){o=a(i.getTracks());try{for(o.s();!(s=o.n()).done;)c=s.value,c.kind&&"audio"==c.kind&&t.addTransceiver(c,{direction:"sendrecv"})}catch(u){o.e(u)}finally{o.f()}}else t.addTransceiver("audio",{direction:"recvonly"});case 10:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),this.setVideoEnabled=function(e){var r;t.log("self.video:",n.video),null===(r=n.video.srcObject)||void 0===r||r.getTracks().forEach((function(t){return t.enabled=e}))},this.startLatencyTest=function(e){n.video&&(n.latencyTestTimings.Reset(),n.latencyTestTimings.TestStartTimeMs=Date.now(),e(n.latencyTestTimings.TestStartTimeMs))},this.handleCandidateFromServer=function(e){t.log("ICE candidate: ",e);var r=new RTCIceCandidate(e);n.pcClient.addIceCandidate(r).then((function(e){t.log("ICE candidate successfully added")}))},this.createOffer=function(){n.pcClient&&(t.log("Closing existing PeerConnection"),n.pcClient.close(),n.pcClient=null),n.pcClient=new RTCPeerConnection(n.cfg),setupTracksToSendAsync(n.pcClient).finally((function(){setupPeerConnection(n.pcClient),n.dcClient=setupDataChannel(n.pcClient,"cirrus",n.dataChannelOptions),handleCreateOffer(n.pcClient)}))},this.receiveAnswer=function(e){t.log("Received answer:"),t.log(e);var r=new RTCSessionDescription(e);n.pcClient.setRemoteDescription(r);var i,o=n.pcClient.getReceivers(),s=a(o);try{for(s.s();!(i=s.n()).done;){var c=i.value;c.playoutDelayHint=0}}catch(u){s.e(u)}finally{s.f()}},this.close=function(){n.pcClient&&(t.log("Closing existing peerClient"),n.pcClient.close(),n.pcClient=null),n.aggregateStatsIntervalId&&clearInterval(n.aggregateStatsIntervalId)},this.send=function(e){n.dcClient&&"open"==n.dcClient.readyState&&n.dcClient.send(e)},this.getStats=function(e){n.pcClient&&e&&n.pcClient.getStats(null).then((function(t){e(t)}))},this.aggregateStats=function(e){var t=generateAggregatedStatsFunction(),r=function(){n.getStats(t)};n.aggregateStatsIntervalId=setInterval(r,e)}}return n}))},"0299":function(e,t,n){"use strict";var r,i="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-_".split(""),o=64,a={},s=0,c=0;function u(e){var t="";do{t=i[e%o]+t,e=Math.floor(e/o)}while(e>0);return t}function f(e){var t=0;for(c=0;c';r=document.createElement(e)}catch(t){r=document.createElement("iframe"),r.name=n.iframeId,r.src="javascript:0"}r.id=n.iframeId,n.form.appendChild(r),n.iframe=r}this.form.action=this.uri(),f(),e=e.replace(c,"\\\n"),this.area.value=e.replace(s,"\\n");try{this.form.submit()}catch(d){}this.iframe.attachEvent?this.iframe.onreadystatechange=function(){"complete"===n.iframe.readyState&&u()}:this.iframe.onload=u}},"0b25":function(e,t,n){var r=n("a691"),i=n("50c4");e.exports=function(e){if(void 0===e)return 0;var t=r(e),n=i(t);if(t!==n)throw RangeError("Wrong length or index");return n}},"0b64":function(e,t){function n(e){e=e||{},this.ms=e.min||100,this.max=e.max||1e4,this.factor=e.factor||2,this.jitter=e.jitter>0&&e.jitter<=1?e.jitter:0,this.attempts=0}e.exports=n,n.prototype.duration=function(){var e=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var t=Math.random(),n=Math.floor(t*this.jitter*e);e=0==(1&Math.floor(10*t))?e-n:e+n}return 0|Math.min(e,this.max)},n.prototype.reset=function(){this.attempts=0},n.prototype.setMin=function(e){this.ms=e},n.prototype.setMax=function(e){this.max=e},n.prototype.setJitter=function(e){this.jitter=e}},"0d3b":function(e,t,n){var r=n("d039"),i=n("b622"),o=n("c430"),a=i("iterator");e.exports=!r((function(){var e=new URL("b?a=1&b=2&c=3","http://a"),t=e.searchParams,n="";return e.pathname="c%20d",t.forEach((function(e,r){t["delete"]("b"),n+=r+e})),o&&!e.toJSON||!t.sort||"http://a/c%20d?a=1&c=3"!==e.href||"3"!==t.get("c")||"a=1"!==String(new URLSearchParams("?a=1"))||!t[a]||"a"!==new URL("https://a@b").username||"b"!==new URLSearchParams(new URLSearchParams("a=b")).get("a")||"xn--e1aybc"!==new URL("http://тест").host||"#%D0%B1"!==new URL("http://a#б").hash||"a1c3"!==n||"x"!==new URL("http://x",void 0).host}))},"0df6":function(e,t,n){"use strict";e.exports=function(e){return function(t){return e.apply(null,t)}}},"0f2a":function(e,t){e.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGkAAABpCAYAAAA5gg06AAAACXBIWXMAABcRAAAXEQHKJvM/AAAEoUlEQVR4nO2cwXUbNxCGf+flgD0xHYipQO7ATAVhKvC6AruDMB3EFWRVQZwKsupAqSBkB9ZpcVMOHOnxYYeA9nnJnR+Z72QOsBYevwdggAX45unpCY5tvlu6AU4Zl0SASyLAJRHgkghwSQS4JAJcEgEuiQCXRIBLIsAlEeCSCHBJBLgkAlwSAS6JAJdEgEsiwCUR4JIIcEkEuCQCXBIBVUoaYmyHGNul2zEX3y/dgLkROX/Iv9GE0C3aoBl4U9Mx41NBJ/zShPBlgebMRjWShhjXAP5Vih4BbJoQHq7bovmoZk5qQtgD+KAUrQB0Q4w/XLdF81GNJADP848m6hbA7qqNmZFqhrtThhg7AO+Vop+aEPrrtubbqVISAAwxPuDYg045NCGsF2jON0E53Mk66G2h2hbHpOGUmyHGTxdq1sWgk3SSZvc5UZJI/K4U7diSCCpJyTpoBeBL7gtvQtgBOCThFQCq3kQjSXpNulC9AdAVHtWEuKRLIIvRO6Xo59w8I7sN90l4xbS3RyMJAJoQWoy/cKA8z3RKjKY3UUkStKxtBT1JAPCyyE3nplvZSjIPnaQmhK8AWqXofeFL75TYdoYmXRyTkoYYt4WsTZtngPwQ1imxdlrLlsGcJJnQ/wTQF6q2r4wBeFk3/ZOEbxnWTKYkJeug2yHG3Dyzx/SsrVdipZ2LxTEjaYhxi/E66OMQ4ybzmCYxV7+fWN8EZiTh+AWmwxGQecUgc1Oa6eWSgV6JbfLNWh4zkjJZ27vCZmqffF6dqy9/I03FfU6aguwq/KYUtZnHeiWWk7pPPqevM8xhSpLQKbFNpr52dmE9sb5pzEk6lypn6vdKeJ35E1/TQCE5WRxzkoTREaxXvOQ7ZT1fU5bHqiQN8xP8pWCS9L/FJRFgVZI2/0zJykbJATNWJW2SzwdZiI44k1BMTbP3E+tfFXOSZIN0lYT7zCOapFxP2qQBSfvNYkqSvDbYKUW5WxFTe1KaJaZ7f+YwJQnHXe2bJHYoXF0ZbagWjhKnC2PzOxBmJMncop3f3hWeSaVqb2yf62+UsEt6LbK5mt6IuC/c1NNel885NJrAjCRgdHXlEZndb5m/tHdHk4ZGlF/TL465O7NNCN0QIwA8FLKuTxhngX+de0akvkvCB+uZHWBQEoDiZWQ5uvWrUnT2TASm9zozmBruJtApsftCVqfNX9r/Yw46SUOMO4yHLaCcBWoXyswnDQCZJNmN0Ia5z7X2IoDoOqZM/HuMk4UDgLeZvb019J8O+JEhaQCIepJI0HrE9pwgQUsm7lgEAUQ96ZnklOuHXCYoOwx/K0U0vQgwmoLnOFlHZVN1GR61cqpeBBD2pNci58g/JuFHAOvC8GgOmjlpCjIkpoIAYMcmCKiwJ8maqMc4C7xvQthcvUEzUJWkTJr+iGOavr92m+agtuGux1gQALSsgoD6JGlros/+o4TGSNZRd/KzAtRUJwl4EdWyJgopVUqqjdrmpCpxSQS4JAJcEgEuiQCXRIBLIsAlEeCSCHBJBLgkAlwSAS6JAJdEgEsiwCUR4JIIcEkEuCQCXBIBLokAl0SASyLAJRHgkgj4D1pIfkP86GgCAAAAAElFTkSuQmCC"},1:function(e,t){},1148:function(e,t,n){"use strict";var r=n("a691"),i=n("1d80");e.exports="".repeat||function(e){var t=String(i(this)),n="",o=r(e);if(o<0||o==1/0)throw RangeError("Wrong number of repetitions");for(;o>0;(o>>>=1)&&(t+=t))1&o&&(n+=t);return n}},"145e":function(e,t,n){"use strict";var r=n("7b0b"),i=n("23cb"),o=n("50c4"),a=Math.min;e.exports=[].copyWithin||function(e,t){var n=r(this),s=o(n.length),c=i(e,s),u=i(t,s),f=arguments.length>2?arguments[2]:void 0,d=a((void 0===f?s:i(f,s))-u,s-c),p=1;u0)u in n?n[c]=n[u]:delete n[c],c+=p,u+=p;return n}},"170b":function(e,t,n){"use strict";var r=n("ebb5"),i=n("50c4"),o=n("23cb"),a=n("4840"),s=r.aTypedArray,c=r.exportTypedArrayMethod;c("subarray",(function(e,t){var n=s(this),r=n.length,c=o(e,r);return new(a(n,n.constructor))(n.buffer,n.byteOffset+c*n.BYTES_PER_ELEMENT,i((void 0===t?r:o(t,r))-c))}))},"182d":function(e,t,n){var r=n("f8cd");e.exports=function(e,t){var n=r(e);if(n%t)throw RangeError("Wrong offset");return n}},"18c0":function(e,t){e.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAH0AAADRCAYAAADhXr2wAAAACXBIWXMAABcRAAAXEQHKJvM/AAAEiUlEQVR4nO3dy3EbRxSF4SMnoFS0Ags7h+AMTEdmKQKnoB2LXDkVRQAvjLEpCQTnce/tx/n/JRaNqfowGGC6G/hwuVxEXv3S+gCoPtANA90w0A0D3TDQDQPdMNANA90w0A0D3TDQDQPdMNANA90w0A0D3TDQDQPdMNANA90w0A0D3TDQDQPdMNANA72488Pp0/nh9FvLYwC9sPPD6ZOkr5L+Oj+cHlsdB+hFvQL/eH3oz1bwoBd0A3ypCTzoyd0BXyqHBz2xFeBLpfCgJ7UBfKkMHvSEdoAvlcCDHtwB8KV0eNADCwBfSoUHPahA8KU0eNADSgBfSoEH/WCJ4Evh8KAfqAB8KRQe9J0Vgi+FwYO+owbgSyHwoG+sIXhYoG+oA/A/np5fPh8dBPSVzQIugb6qmcAl0N9tNnAJ9LvNCC6B/mazgkug32xmcAn0n5odXAL9uxzAJdD/ywVcAl2SF7gEuh24ZI7uCC4Zo7uCS6bozuCSIbo7uGSGDvi/2aAD/n8W6IB/3/TogP/c1OiA325adMDfbkp0wO83HTrg7zcVOuDrmgYd8PVNgQ74toZHB3x7Q6MDvq9h0QHf35DogB9rOHTAjzcUOuAxDYMOeFxDoAMeW/fogMfXNTrgOXWLDnheXaIDnlt36IDn1xU64DV1gw54XV2gA15bc3TA62uKDnibmqED3q4m6IC3rRwd8PaVogPeR2XogPdTCTrgfZWODnh/paID3mdp6ID3Wwo64H0Xjg54/4WiAz5GYeiAj1MIOuBjdRgd8PGKONMf1Q78m6S/Gz33sH24XC6HBzk/nD5L+v3wQPv6JunXp+cX8FcWck1/en55lPQlYqwdfZT09XqZoRWFfXoHfpxCv6cDP0bhd+SA77+Ue+/A913aLBvw/ZY6nw58n6WvnAG+v0rWyAHfV2WrYYHvp9J178D3UfkOF+Db12QvG/Bta7ZrFfh2Nd2fDnybmv8SBfD1NUeXgK+uC3QJ+Mq6QZeAr6ordAn4irpDl4DPrkt0CfjMukWXgM+qa3QJ+Iy6R5eAj24IdAn4yIZBl4CPaih0CfiIhkOXgD/akOgS8EcaFl0Cfm9Do0vA72l4dAn4rU2BLgG/pWnQJeDXNhW6BPyapkOXgH+vKdEl4O81LboE/FtNjS4Bf6vp0SXgf8wCXQL+dTboEvBLVugS8JIhugS8JbrkDW+LLvnCW6NLnvD26JIfPOjXnOBBf5ULPOg/5AAP+o1mhwf9jWaGB/1Os8KD/k4zwoO+otngQV/ZTPCgb2gWeNA31gH849FBQv5g17FGfyr85fqiOxRn+s4anPEh4BLohyqEDwOXQD9cAXwouAR6SInw4eAS6GElwKeAS6CHFgifBi6BHl4AfCq4BHpKB+DTwSXQ09oBXwIugZ7aBvgycAn09FbAl4JLoJd0B74cXAK9rBvwTcAlZtnKu87OqRW4BLplvL0bBrphoBsGumGgGwa6YaAbBrphoBsGumGgGwa6YaAbBrphoBsGumGgGwa6YaAbBrphoBsGumGgGwa6YaAbBrphoBv2D8iaBLzR8aNAAAAAAElFTkSuQmCC"},"19b7":function(e,t,n){var r=n("5a6e"),i=n("7297");function o(e){this.path=e.path,this.hostname=e.hostname,this.port=e.port,this.secure=e.secure,this.query=e.query,this.timestampParam=e.timestampParam,this.timestampRequests=e.timestampRequests,this.readyState="",this.agent=e.agent||!1,this.socket=e.socket,this.enablesXDR=e.enablesXDR,this.withCredentials=e.withCredentials,this.pfx=e.pfx,this.key=e.key,this.passphrase=e.passphrase,this.cert=e.cert,this.ca=e.ca,this.ciphers=e.ciphers,this.rejectUnauthorized=e.rejectUnauthorized,this.forceNode=e.forceNode,this.isReactNative=e.isReactNative,this.extraHeaders=e.extraHeaders,this.localAddress=e.localAddress}e.exports=o,i(o.prototype),o.prototype.onError=function(e,t){var n=new Error(e);return n.type="TransportError",n.description=t,this.emit("error",n),this},o.prototype.open=function(){return"closed"!==this.readyState&&""!==this.readyState||(this.readyState="opening",this.doOpen()),this},o.prototype.close=function(){return"opening"!==this.readyState&&"open"!==this.readyState||(this.doClose(),this.onClose()),this},o.prototype.send=function(e){if("open"!==this.readyState)throw new Error("Transport not open");this.write(e)},o.prototype.onOpen=function(){this.readyState="open",this.writable=!0,this.emit("open")},o.prototype.onData=function(e){var t=r.decodePacket(e,this.socket.binaryType);this.onPacket(t)},o.prototype.onPacket=function(e){this.emit("packet",e)},o.prototype.onClose=function(){this.readyState="closed",this.emit("close")}},"1bfd":function(e,t,n){"use strict";n.r(t);var r=function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("div",[r("div",{staticClass:"bady"},[r("div",{staticClass:"bady_left"}),r("div",{staticClass:"bady_virtualhuman"},[r("div",{staticClass:"player"},[r("Player",{attrs:{"ue-url":e.liveUrl,"creat-scene-obj":e.creatSceneObj}})],1),r("div",{staticClass:"chatBox"},[r("div",[e.imgleft?r("img",{staticClass:"dialogue",attrs:{src:n("8e0c"),alt:""}}):r("img",{staticClass:"dialogue",attrs:{src:n("a3e4"),alt:""}})]),r("div",[e.imgright?r("img",{staticClass:"dialogue",attrs:{src:n("5d61"),alt:""}}):r("img",{staticClass:"dialogue",attrs:{src:n("eb6a"),alt:""}})])]),e.userInputbox?r("div",{staticClass:"userInput"},[r("el-input",{attrs:{id:"myInput",placeholder:"请输入内容"},on:{blur:e.blurInput,focus:e.focusInput},nativeOn:{keyup:[function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"enter",13,t.key,"Enter")?null:e.confirmEditCommand(e.inputTxt)},function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"esc",27,t.key,["Esc","Escape"])?null:function(){e.inputTxt=""}()}]},model:{value:e.inputTxt,callback:function(t){e.inputTxt=t},expression:"inputTxt"}})],1):e._e(),e.userselectRecording&&!1===e.userInputbox?r("div",{staticClass:"userInput"},[e.recording?r("el-button",{staticClass:"inputOrButton",attrs:{loading:e.recording}},[e._v("录音开始")]):e._e()],1):e._e(),e.imgleft?r("img",{staticClass:"img_left",attrs:{src:n("18c0"),alt:""}}):r("img",{staticClass:"img_left",attrs:{src:n("73b5"),alt:""}}),e.imgright?r("img",{staticClass:"img_right",attrs:{src:n("284c"),alt:""}}):r("img",{staticClass:"img_right",attrs:{src:n("ff51"),alt:""}})]),r("div",{staticClass:"bady_dialogbox"},[r("chat-comp",{attrs:{"messages-dialogue":e.userDialogue}})],1)])])},i=[],o=(n("99af"),n("d81d"),n("a434"),n("ac1f"),n("1276"),n("96cf"),n("1da1")),a=n("d4ec"),s=n("bee2"),c=n("262e"),u=n("2caf"),f=n("9ab4"),d=n("60a3"),p=n("9d0b"),l=n("3525"),h=n("da43"),m=n.n(h),g=n("8055"),y=n.n(g),v=n("7626"),b=n("e11d"),w=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"chat-history"},e._l(e.mes,(function(t){return n("div",{key:t.id,staticClass:"message"},[""!==t.user?n("div",{staticClass:"message-content"},[n("img",{staticClass:"img_voice",attrs:{src:e.voiceRight,alt:""}}),e._v(" "+e._s(t.user)+" ")]):e._e(),""!==t.ass?n("div",{staticClass:"message-meta"},[e._v(" "+e._s(t.ass)+" "),n("img",{staticClass:"img_voice",attrs:{src:e.voiceLeft,alt:""}})]):e._e()])})),0)},C=[],A=function(e){Object(c["a"])(n,e);var t=Object(u["a"])(n);function n(){var e;return Object(a["a"])(this,n),e=t.apply(this,arguments),e.voiceLeft=l["d"],e.voiceRight=l["e"],e.mes=[{user:1231,ass:"123456712345672345672345t6y7u"},{user:1231,ass:"环境卫生:宠物的生活环境应该保持干净卫生,定期清理宠物笼子、食具、水源等。经常打扫宠物的活动区域,确保宠物不会受到细菌、病毒等疾病的侵害。"},{content:1231,meta:12}],e}return Object(s["a"])(n,[{key:"messagesWatcher",value:function(){this.mes=this.messagesDialogue}}]),n}(d["d"]);Object(f["a"])([Object(d["c"])({type:Array,default:[]})],A.prototype,"messagesDialogue",void 0),Object(f["a"])([Object(d["e"])("messagesDialogue",{immediate:!0,deep:!0})],A.prototype,"messagesWatcher",null),A=Object(f["a"])([Object(d["a"])({components:{}})],A);var S=A,E=S,T=(n("8345"),n("2877")),R=Object(T["a"])(E,w,C,!1,null,"b7d9b176",null),k=R.exports,x=function(e){Object(c["a"])(n,e);var t=Object(u["a"])(n);function n(){var e;return Object(a["a"])(this,n),e=t.apply(this,arguments),e.creatSceneObj={},e.soundRecording=!0,e.userRecording="语音输入",e.userObj={},e.imgleft=!1,e.imgright=!0,e.recording=!0,e.userInputbox=!1,e.userselectRecording=!1,e.userDialogue=[],e.iframeUrl=l["b"],e.liveUrl=l["a"],e.url="",e.inputTxt="",e.watchSpace=!1,e.recorder=new m.a({sampleBits:16,sampleRate:16e3,numChannels:1}),e.token="",e.inputOrButton=!0,e}return Object(s["a"])(n,[{key:"mounted",value:function(){this.socket=y()("ws://192.168.199.249:8989?user_id=2",{transports:["websocket","polling"],reconnectionDelayMax:3e4}),this.socketEvt(),this.addSpaceEvt(),this.token=window.location.href.split("=")[1],setTimeout((function(){Object(b["e"])({Action:"switch_map",Map:"ChatBot_Dome"})}),5e3)}},{key:"imgLeft",value:function(){this.imgleft=!1,this.imgright=!0}},{key:"imgRight",value:function(){this.imgright=!1,this.imgleft=!0}},{key:"blurInput",value:function(){this.addSpaceEvt()}},{key:"focusInput",value:function(){this.removeSpaceEvt()}},{key:"voiceInput",value:function(){this.soundRecording=!1}},{key:"userInput",value:function(){this.soundRecording=!0}},{key:"addSpaceEvt",value:function(){var e=this,t=this;document.addEventListener("keydown",(function(n){"Space"!==n.code||t.watchSpace||(t.beginRecorder(),t.watchSpace=!0,e.inputOrButton=!1,e.recording=!0,e.userselectRecording=!0),"ArrowLeft"===n.code&&(e.addSpaceEvt(),e.userInputbox=!1,e.imgLeft()),"ArrowRight"===n.code&&(e.removeSpaceEvt(),e.userInputbox=!0,e.imgRight())})),document.addEventListener("keyup",(function(n){"Space"===n.code&&(t.stopRecorder(),t.watchSpace=!1,e.inputOrButton=!0,e.recording=!1)}))}},{key:"removeSpaceEvt",value:function(){document.removeEventListener("keydown",(function(){})),document.removeEventListener("keyup",(function(){}))}},{key:"socketEvt",value:function(){var e=this;this.socket.on("t2v_response",(function(e){var t={Action:"voice_url",Url:e.voice_uri};Object(b["e"])(t)})),this.socket.on("chat_response",(function(t){e.userDialogue=[],t.full_conversation.map((function(t){return e.userDialogue.push({user:"user"===t.role?t.content:"",ass:"assistant"===t.role?t.content:""})})),e.userDialogue.splice(0,2),e.userDialogue=e.userDialogue.reverse(),e.socket.emit("t2v",{text:t.latest_conversation})}))}},{key:"confirmEditCommand",value:function(){var e=Object(o["a"])(regeneratorRuntime.mark((function e(t){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:this.socket.emit("chat",{conversation_id:1,new_conversation:t,full_conversation:!0,max_token:200}),this.eliminateInput();case 3:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"beginRecorder",value:function(){this.recorder.start().then((function(){}),(function(e){}))}},{key:"eliminateInput",value:function(){var e=Object(o["a"])(regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:this.inputTxt="";case 1:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"stopRecorder",value:function(){var e=Object(o["a"])(regeneratorRuntime.mark((function e(){var t,n,r,i;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return this.recorder.stop(),t=this.recorder.getWAVBlob(),n=new File([t],"test.wav",{type:"audio/wav"}),r=new FormData,r.append("files",n),e.next=8,Object(v["a"])(r);case 8:i=e.sent,this.url="".concat(l["c"]).concat(i.uris[0]),this.socket.emit("chat",{conversation_id:1,voice_conversation:this.url,full_conversation:!0,max_token:200});case 12:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()}]),n}(d["d"]);x=Object(f["a"])([Object(d["a"])({components:{Player:p["a"],ChatComp:k}})],x);var P=x,B=P,O=(n("91d3"),Object(T["a"])(B,r,i,!1,null,"1b07ed3e",null));t["default"]=O.exports},"1d2b":function(e,t,n){"use strict";e.exports=function(e,t){return function(){for(var n=new Array(arguments.length),r=0;r=31||"undefined"!==typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))}function o(e){var n=this.useColors;if(e[0]=(n?"%c":"")+this.namespace+(n?" %c":" ")+e[0]+(n?"%c ":" ")+"+"+t.humanize(this.diff),n){var r="color: "+this.color;e.splice(1,0,r,"color: inherit");var i=0,o=0;e[0].replace(/%[a-zA-Z%]/g,(function(e){"%%"!==e&&(i++,"%c"===e&&(o=i))})),e.splice(o,0,r)}}function a(){return"object"===typeof console&&console.log&&Function.prototype.apply.call(console.log,console,arguments)}function s(e){try{null==e?t.storage.removeItem("debug"):t.storage.debug=e}catch(n){}}function c(){var e;try{e=t.storage.debug}catch(n){}return!e&&"undefined"!==typeof r&&"env"in r&&(e=Object({VUE_APP_HTTP_URL:"http://frps.retailwell.com:20068",VUE_APP_Live_URL:"http://metaplayer.sxkj.com/ws",VUE_APP_Iframe_URL:"http://metaplayer.sxkj.com",NODE_ENV:"production",BASE_URL:"/"}).DEBUG),e}function u(){try{return window.localStorage}catch(e){}}t=e.exports=n("9617"),t.log=a,t.formatArgs=o,t.save=s,t.load=c,t.useColors=i,t.storage="undefined"!=typeof chrome&&"undefined"!=typeof chrome.storage?chrome.storage.local:u(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],t.formatters.j=function(e){try{return JSON.stringify(e)}catch(t){return"[UnexpectedJSONParseError]: "+t.message}},t.enable(c())}).call(this,n("4362"))},"1fb5":function(e,t,n){"use strict";t.byteLength=f,t.toByteArray=p,t.fromByteArray=m;for(var r=[],i=[],o="undefined"!==typeof Uint8Array?Uint8Array:Array,a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",s=0,c=a.length;s0)throw new Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");-1===n&&(n=t);var r=n===t?0:4-n%4;return[n,r]}function f(e){var t=u(e),n=t[0],r=t[1];return 3*(n+r)/4-r}function d(e,t,n){return 3*(t+n)/4-n}function p(e){var t,n,r=u(e),a=r[0],s=r[1],c=new o(d(e,a,s)),f=0,p=s>0?a-4:a;for(n=0;n>16&255,c[f++]=t>>8&255,c[f++]=255&t;return 2===s&&(t=i[e.charCodeAt(n)]<<2|i[e.charCodeAt(n+1)]>>4,c[f++]=255&t),1===s&&(t=i[e.charCodeAt(n)]<<10|i[e.charCodeAt(n+1)]<<4|i[e.charCodeAt(n+2)]>>2,c[f++]=t>>8&255,c[f++]=255&t),c}function l(e){return r[e>>18&63]+r[e>>12&63]+r[e>>6&63]+r[63&e]}function h(e,t,n){for(var r,i=[],o=t;oc?c:s+a));return 1===i?(t=e[n-1],o.push(r[t>>2]+r[t<<4&63]+"==")):2===i&&(t=(e[n-2]<<8)+e[n-1],o.push(r[t>>10]+r[t>>4&63]+r[t<<2&63]+"=")),o.join("")}i["-".charCodeAt(0)]=62,i["_".charCodeAt(0)]=63},"219c":function(e,t,n){"use strict";var r=n("ebb5"),i=r.aTypedArray,o=r.exportTypedArrayMethod,a=[].sort;o("sort",(function(e){return a.call(i(this),e)}))},2444:function(e,t,n){"use strict";(function(t){var r=n("c532"),i=n("c8af"),o={"Content-Type":"application/x-www-form-urlencoded"};function a(e,t){!r.isUndefined(e)&&r.isUndefined(e["Content-Type"])&&(e["Content-Type"]=t)}function s(){var e;return("undefined"!==typeof XMLHttpRequest||"undefined"!==typeof t&&"[object process]"===Object.prototype.toString.call(t))&&(e=n("b50d")),e}var c={adapter:s(),transformRequest:[function(e,t){return i(t,"Accept"),i(t,"Content-Type"),r.isFormData(e)||r.isArrayBuffer(e)||r.isBuffer(e)||r.isStream(e)||r.isFile(e)||r.isBlob(e)?e:r.isArrayBufferView(e)?e.buffer:r.isURLSearchParams(e)?(a(t,"application/x-www-form-urlencoded;charset=utf-8"),e.toString()):r.isObject(e)?(a(t,"application/json;charset=utf-8"),JSON.stringify(e)):e}],transformResponse:[function(e){if("string"===typeof e)try{e=JSON.parse(e)}catch(t){}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};r.forEach(["delete","get","head"],(function(e){c.headers[e]={}})),r.forEach(["post","put","patch"],(function(e){c.headers[e]=r.merge(o)})),e.exports=c}).call(this,n("4362"))},"25a1":function(e,t,n){"use strict";var r=n("ebb5"),i=n("d58f").right,o=r.aTypedArray,a=r.exportTypedArrayMethod;a("reduceRight",(function(e){return i(o(this),e,arguments.length,arguments.length>1?arguments[1]:void 0)}))},"284c":function(e,t){e.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAH0AAADRCAYAAADhXr2wAAAACXBIWXMAABcRAAAXEQHKJvM/AAAEgklEQVR4nO3dy5HbRhSF4SMnoFS8mqnJwhl4HJmlCJyCdipp5VQcAb0QYUsjPkD0vbcf5/933IAofgUC6G6Q706nk8irX3rvANUHumGgGwa6YaAbBrphoBsGumGgGwa6YaAbBrphoBsGumGgGwa6YaAbBrphoBsGumGgGwa6YaAbBrphoBsGumFd0V+en357eX76tec+ONYN/eX56VXSX5I+AV9bF/Qz+J/nl+8FfGnl6G/At4AvrBT9CvgW8EWVod8B3wK+oBL0neBbwCeXjv4g+BbwiaWiHwTfAj6pNPRG8C3gE0pBDwLfAj64cPRg8C3gAwtFTwLfAj6oMPRk8C3gAwpBLwLfAr6xZvRi8C3gG5p5EQXwB2tG//zl6wdJf7TvyqGAP1DIkQ78XIV9vQM/T6HndODnKPxCDvjxS7l6B37s0m7ZgB+31Pt04McsfXAG+PEqGZEDfqzKhmGBH6fSsXfgx6h8wgX4/nWZZQO+b92mVoHvV9f5dOD71H0RBfD1dUeXgK9uCHQJ+MqGQZeAr2oodAn4ioZDl4DPbkh0CfjMhkWXgM9qaHQJ+IyGR5eAj24KdAn4yKZBl4CPaip0CfiIpkOXgG9tSnQJ+JamRZeAP9rU6BLwR5oeXQL+0ZZAl4B/pGXQJeD3thS6BPyelkOXgL/XkugS8LdaFl0C/lpLo0vAX2p5dAn4t1mgS8B/nw26BPyWFboEvGSILgFviS55w9uiS77w1uiSJ7w9uuQHD/o5J3jQv8sFHvQ3OcCDfqHV4UG/0srwoN9oVXjQ77QiPOg7Wg0e9J2tBA/6A60CD/rj/S3pn07v/V7Sa+tG3p1Op/ZdMel8lH3Stw+/Rx8/f/n62roRjvSdrQIugb6rlcAl0O+2GrgE+s1WBJdAv9qq4BLoF1sZXAL9p1YHl0D/IQdwCfT/cgGXQJfkBS6BbgcumaM7gkvG6K7gkim6M7hkiO4OLpmhA/4tG3TA/88CHfAfWx4d8J9bGh3wyy2LDvj1lkQH/HbLoQN+v6XQAd/XMuiA728JdMAfa3p0wB9vanTAjzUtOuDHmxId8LamQwe8vanQAY9pGnTA45oCHfDYhkcHPL6h0QHPaVh0wPMaEh3w3IZDBzy/odABr2kYdMDrGgId8Nq6owNeX1d0wPvUDR3wfnVBB7xv5eiA968UHfAxKkMHfJxK0AEfq3R0wMcrFR3wMUtDB3zcUtABH7twdMDHLxQd8DkKQwd8nkLQAZ+rZnTA5yviSH8V4FMV8ge7L89PHyT93ryhxwL8YCHn9POH/zFiWzsDvKGwq/dCeMAbC71PL4AHPKDwEblEeMCDShl7T4AHPLC0WbZAeMCDS51PD4AHPKH0lTMN8IAnVbJG7gA84ImVrYZ9AB7w5ErXve+AB7yg8idcbsADXlSXZ9kuwANeWMgs29HOs3MCvLau6NSn7r9EQfWBbhjohoFuGOiGgW4Y6IaBbhjohoFuGOiGgW4Y6IaBbhjohoFuGOiGgW4Y6IaBbhjohoFuGOiGgW4Y6IaBbhjohv0Ld2UDvFHM1P4AAAAASUVORK5CYII="},2851:function(e,t,n){var r=n("568d"),i=n("7297"),o=n("9121"),a=n("d838"),s=n("40de"),c=n("c7b0")("socket.io-client:socket"),u=n("4f2a"),f=n("58b1");e.exports=l;var d={connect:1,connect_error:1,connect_timeout:1,connecting:1,disconnect:1,error:1,reconnect:1,reconnect_attempt:1,reconnect_failed:1,reconnect_error:1,reconnecting:1,ping:1,pong:1},p=i.prototype.emit;function l(e,t,n){this.io=e,this.nsp=t,this.json=this,this.ids=0,this.acks={},this.receiveBuffer=[],this.sendBuffer=[],this.connected=!1,this.disconnected=!0,this.flags={},n&&n.query&&(this.query=n.query),this.io.autoConnect&&this.open()}i(l.prototype),l.prototype.subEvents=function(){if(!this.subs){var e=this.io;this.subs=[a(e,"open",s(this,"onopen")),a(e,"packet",s(this,"onpacket")),a(e,"close",s(this,"onclose"))]}},l.prototype.open=l.prototype.connect=function(){return this.connected||(this.subEvents(),this.io.reconnecting||this.io.open(),"open"===this.io.readyState&&this.onopen(),this.emit("connecting")),this},l.prototype.send=function(){var e=o(arguments);return e.unshift("message"),this.emit.apply(this,e),this},l.prototype.emit=function(e){if(d.hasOwnProperty(e))return p.apply(this,arguments),this;var t=o(arguments),n={type:(void 0!==this.flags.binary?this.flags.binary:f(t))?r.BINARY_EVENT:r.EVENT,data:t,options:{}};return n.options.compress=!this.flags||!1!==this.flags.compress,"function"===typeof t[t.length-1]&&(c("emitting packet with ack id %d",this.ids),this.acks[this.ids]=t.pop(),n.id=this.ids++),this.connected?this.packet(n):this.sendBuffer.push(n),this.flags={},this},l.prototype.packet=function(e){e.nsp=this.nsp,this.io.packet(e)},l.prototype.onopen=function(){if(c("transport is open - connecting"),"/"!==this.nsp)if(this.query){var e="object"===typeof this.query?u.encode(this.query):this.query;c("sending connect packet with query %s",e),this.packet({type:r.CONNECT,query:e})}else this.packet({type:r.CONNECT})},l.prototype.onclose=function(e){c("close (%s)",e),this.connected=!1,this.disconnected=!0,delete this.id,this.emit("disconnect",e)},l.prototype.onpacket=function(e){var t=e.nsp===this.nsp,n=e.type===r.ERROR&&"/"===e.nsp;if(t||n)switch(e.type){case r.CONNECT:this.onconnect();break;case r.EVENT:this.onevent(e);break;case r.BINARY_EVENT:this.onevent(e);break;case r.ACK:this.onack(e);break;case r.BINARY_ACK:this.onack(e);break;case r.DISCONNECT:this.ondisconnect();break;case r.ERROR:this.emit("error",e.data);break}},l.prototype.onevent=function(e){var t=e.data||[];c("emitting event %j",t),null!=e.id&&(c("attaching ack callback to event"),t.push(this.ack(e.id))),this.connected?p.apply(this,t):this.receiveBuffer.push(t)},l.prototype.ack=function(e){var t=this,n=!1;return function(){if(!n){n=!0;var i=o(arguments);c("sending ack %j",i),t.packet({type:f(i)?r.BINARY_ACK:r.ACK,id:e,data:i})}}},l.prototype.onack=function(e){var t=this.acks[e.id];"function"===typeof t?(c("calling ack %s with %j",e.id,e.data),t.apply(this,e.data),delete this.acks[e.id]):c("bad ack %s",e.id)},l.prototype.onconnect=function(){this.connected=!0,this.disconnected=!1,this.emitBuffered(),this.emit("connect")},l.prototype.emitBuffered=function(){var e;for(e=0;eo)f[o]=n[o++];return f}),f)},"2b3d":function(e,t,n){"use strict";n("3ca3");var r,i=n("23e7"),o=n("83ab"),a=n("0d3b"),s=n("da84"),c=n("37e8"),u=n("6eeb"),f=n("19aa"),d=n("5135"),p=n("60da"),l=n("4df4"),h=n("6547").codeAt,m=n("5fb2"),g=n("d44e"),y=n("9861"),v=n("69f3"),b=s.URL,w=y.URLSearchParams,C=y.getState,A=v.set,S=v.getterFor("URL"),E=Math.floor,T=Math.pow,R="Invalid authority",k="Invalid scheme",x="Invalid host",P="Invalid port",B=/[A-Za-z]/,O=/[\d+-.A-Za-z]/,D=/\d/,M=/^(0x|0X)/,I=/^[0-7]+$/,F=/^\d+$/,U=/^[\dA-Fa-f]+$/,L=/[\u0000\u0009\u000A\u000D #%/:?@[\\]]/,j=/[\u0000\u0009\u000A\u000D #/:?@[\\]]/,_=/^[\u0000-\u001F ]+|[\u0000-\u001F ]+$/g,N=/[\u0009\u000A\u000D]/g,H=function(e,t){var n,r,i;if("["==t.charAt(0)){if("]"!=t.charAt(t.length-1))return x;if(n=q(t.slice(1,-1)),!n)return x;e.host=n}else if(Z(e)){if(t=m(t),L.test(t))return x;if(n=Q(t),null===n)return x;e.host=n}else{if(j.test(t))return x;for(n="",r=l(t),i=0;i4)return e;for(n=[],r=0;r1&&"0"==i.charAt(0)&&(o=M.test(i)?16:8,i=i.slice(8==o?1:2)),""===i)a=0;else{if(!(10==o?F:8==o?I:U).test(i))return e;a=parseInt(i,o)}n.push(a)}for(r=0;r=T(256,5-t))return null}else if(a>255)return null;for(s=n.pop(),r=0;r6)return;r=0;while(p()){if(i=null,r>0){if(!("."==p()&&r<4))return;d++}if(!D.test(p()))return;while(D.test(p())){if(o=parseInt(p(),10),null===i)i=o;else{if(0==i)return;i=10*i+o}if(i>255)return;d++}c[u]=256*c[u]+i,r++,2!=r&&4!=r||u++}if(4!=r)return;break}if(":"==p()){if(d++,!p())return}else if(p())return;c[u++]=t}else{if(null!==f)return;d++,u++,f=u}}if(null!==f){a=u-f,u=7;while(0!=u&&a>0)s=c[u],c[u--]=c[f+a-1],c[f+--a]=s}else if(8!=u)return;return c},W=function(e){for(var t=null,n=1,r=null,i=0,o=0;o<8;o++)0!==e[o]?(i>n&&(t=r,n=i),r=null,i=0):(null===r&&(r=o),++i);return i>n&&(t=r,n=i),t},J=function(e){var t,n,r,i;if("number"==typeof e){for(t=[],n=0;n<4;n++)t.unshift(e%256),e=E(e/256);return t.join(".")}if("object"==typeof e){for(t="",r=W(e),n=0;n<8;n++)i&&0===e[n]||(i&&(i=!1),r===n?(t+=n?":":"::",i=!0):(t+=e[n].toString(16),n<7&&(t+=":")));return"["+t+"]"}return e},X={},z=p({},X,{" ":1,'"':1,"<":1,">":1,"`":1}),Y=p({},z,{"#":1,"?":1,"{":1,"}":1}),G=p({},Y,{"/":1,":":1,";":1,"=":1,"@":1,"[":1,"\\":1,"]":1,"^":1,"|":1}),K=function(e,t){var n=h(e,0);return n>32&&n<127&&!d(t,e)?e:encodeURIComponent(e)},V={ftp:21,file:null,http:80,https:443,ws:80,wss:443},Z=function(e){return d(V,e.scheme)},$=function(e){return""!=e.username||""!=e.password},ee=function(e){return!e.host||e.cannotBeABaseURL||"file"==e.scheme},te=function(e,t){var n;return 2==e.length&&B.test(e.charAt(0))&&(":"==(n=e.charAt(1))||!t&&"|"==n)},ne=function(e){var t;return e.length>1&&te(e.slice(0,2))&&(2==e.length||"/"===(t=e.charAt(2))||"\\"===t||"?"===t||"#"===t)},re=function(e){var t=e.path,n=t.length;!n||"file"==e.scheme&&1==n&&te(t[0],!0)||t.pop()},ie=function(e){return"."===e||"%2e"===e.toLowerCase()},oe=function(e){return e=e.toLowerCase(),".."===e||"%2e."===e||".%2e"===e||"%2e%2e"===e},ae={},se={},ce={},ue={},fe={},de={},pe={},le={},he={},me={},ge={},ye={},ve={},be={},we={},Ce={},Ae={},Se={},Ee={},Te={},Re={},ke=function(e,t,n,i){var o,a,s,c,u=n||ae,f=0,p="",h=!1,m=!1,g=!1;n||(e.scheme="",e.username="",e.password="",e.host=null,e.port=null,e.path=[],e.query=null,e.fragment=null,e.cannotBeABaseURL=!1,t=t.replace(_,"")),t=t.replace(N,""),o=l(t);while(f<=o.length){switch(a=o[f],u){case ae:if(!a||!B.test(a)){if(n)return k;u=ce;continue}p+=a.toLowerCase(),u=se;break;case se:if(a&&(O.test(a)||"+"==a||"-"==a||"."==a))p+=a.toLowerCase();else{if(":"!=a){if(n)return k;p="",u=ce,f=0;continue}if(n&&(Z(e)!=d(V,p)||"file"==p&&($(e)||null!==e.port)||"file"==e.scheme&&!e.host))return;if(e.scheme=p,n)return void(Z(e)&&V[e.scheme]==e.port&&(e.port=null));p="","file"==e.scheme?u=be:Z(e)&&i&&i.scheme==e.scheme?u=ue:Z(e)?u=le:"/"==o[f+1]?(u=fe,f++):(e.cannotBeABaseURL=!0,e.path.push(""),u=Ee)}break;case ce:if(!i||i.cannotBeABaseURL&&"#"!=a)return k;if(i.cannotBeABaseURL&&"#"==a){e.scheme=i.scheme,e.path=i.path.slice(),e.query=i.query,e.fragment="",e.cannotBeABaseURL=!0,u=Re;break}u="file"==i.scheme?be:de;continue;case ue:if("/"!=a||"/"!=o[f+1]){u=de;continue}u=he,f++;break;case fe:if("/"==a){u=me;break}u=Se;continue;case de:if(e.scheme=i.scheme,a==r)e.username=i.username,e.password=i.password,e.host=i.host,e.port=i.port,e.path=i.path.slice(),e.query=i.query;else if("/"==a||"\\"==a&&Z(e))u=pe;else if("?"==a)e.username=i.username,e.password=i.password,e.host=i.host,e.port=i.port,e.path=i.path.slice(),e.query="",u=Te;else{if("#"!=a){e.username=i.username,e.password=i.password,e.host=i.host,e.port=i.port,e.path=i.path.slice(),e.path.pop(),u=Se;continue}e.username=i.username,e.password=i.password,e.host=i.host,e.port=i.port,e.path=i.path.slice(),e.query=i.query,e.fragment="",u=Re}break;case pe:if(!Z(e)||"/"!=a&&"\\"!=a){if("/"!=a){e.username=i.username,e.password=i.password,e.host=i.host,e.port=i.port,u=Se;continue}u=me}else u=he;break;case le:if(u=he,"/"!=a||"/"!=p.charAt(f+1))continue;f++;break;case he:if("/"!=a&&"\\"!=a){u=me;continue}break;case me:if("@"==a){h&&(p="%40"+p),h=!0,s=l(p);for(var y=0;y65535)return P;e.port=Z(e)&&w===V[e.scheme]?null:w,p=""}if(n)return;u=Ae;continue}return P}p+=a;break;case be:if(e.scheme="file","/"==a||"\\"==a)u=we;else{if(!i||"file"!=i.scheme){u=Se;continue}if(a==r)e.host=i.host,e.path=i.path.slice(),e.query=i.query;else if("?"==a)e.host=i.host,e.path=i.path.slice(),e.query="",u=Te;else{if("#"!=a){ne(o.slice(f).join(""))||(e.host=i.host,e.path=i.path.slice(),re(e)),u=Se;continue}e.host=i.host,e.path=i.path.slice(),e.query=i.query,e.fragment="",u=Re}}break;case we:if("/"==a||"\\"==a){u=Ce;break}i&&"file"==i.scheme&&!ne(o.slice(f).join(""))&&(te(i.path[0],!0)?e.path.push(i.path[0]):e.host=i.host),u=Se;continue;case Ce:if(a==r||"/"==a||"\\"==a||"?"==a||"#"==a){if(!n&&te(p))u=Se;else if(""==p){if(e.host="",n)return;u=Ae}else{if(c=H(e,p),c)return c;if("localhost"==e.host&&(e.host=""),n)return;p="",u=Ae}continue}p+=a;break;case Ae:if(Z(e)){if(u=Se,"/"!=a&&"\\"!=a)continue}else if(n||"?"!=a)if(n||"#"!=a){if(a!=r&&(u=Se,"/"!=a))continue}else e.fragment="",u=Re;else e.query="",u=Te;break;case Se:if(a==r||"/"==a||"\\"==a&&Z(e)||!n&&("?"==a||"#"==a)){if(oe(p)?(re(e),"/"==a||"\\"==a&&Z(e)||e.path.push("")):ie(p)?"/"==a||"\\"==a&&Z(e)||e.path.push(""):("file"==e.scheme&&!e.path.length&&te(p)&&(e.host&&(e.host=""),p=p.charAt(0)+":"),e.path.push(p)),p="","file"==e.scheme&&(a==r||"?"==a||"#"==a))while(e.path.length>1&&""===e.path[0])e.path.shift();"?"==a?(e.query="",u=Te):"#"==a&&(e.fragment="",u=Re)}else p+=K(a,Y);break;case Ee:"?"==a?(e.query="",u=Te):"#"==a?(e.fragment="",u=Re):a!=r&&(e.path[0]+=K(a,X));break;case Te:n||"#"!=a?a!=r&&("'"==a&&Z(e)?e.query+="%27":e.query+="#"==a?"%23":K(a,X)):(e.fragment="",u=Re);break;case Re:a!=r&&(e.fragment+=K(a,z));break}f++}},xe=function(e){var t,n,r=f(this,xe,"URL"),i=arguments.length>1?arguments[1]:void 0,a=String(e),s=A(r,{type:"URL"});if(void 0!==i)if(i instanceof xe)t=S(i);else if(n=ke(t={},String(i)),n)throw TypeError(n);if(n=ke(s,a,null,t),n)throw TypeError(n);var c=s.searchParams=new w,u=C(c);u.updateSearchParams(s.query),u.updateURL=function(){s.query=String(c)||null},o||(r.href=Be.call(r),r.origin=Oe.call(r),r.protocol=De.call(r),r.username=Me.call(r),r.password=Ie.call(r),r.host=Fe.call(r),r.hostname=Ue.call(r),r.port=Le.call(r),r.pathname=je.call(r),r.search=_e.call(r),r.searchParams=Ne.call(r),r.hash=He.call(r))},Pe=xe.prototype,Be=function(){var e=S(this),t=e.scheme,n=e.username,r=e.password,i=e.host,o=e.port,a=e.path,s=e.query,c=e.fragment,u=t+":";return null!==i?(u+="//",$(e)&&(u+=n+(r?":"+r:"")+"@"),u+=J(i),null!==o&&(u+=":"+o)):"file"==t&&(u+="//"),u+=e.cannotBeABaseURL?a[0]:a.length?"/"+a.join("/"):"",null!==s&&(u+="?"+s),null!==c&&(u+="#"+c),u},Oe=function(){var e=S(this),t=e.scheme,n=e.port;if("blob"==t)try{return new URL(t.path[0]).origin}catch(r){return"null"}return"file"!=t&&Z(e)?t+"://"+J(e.host)+(null!==n?":"+n:""):"null"},De=function(){return S(this).scheme+":"},Me=function(){return S(this).username},Ie=function(){return S(this).password},Fe=function(){var e=S(this),t=e.host,n=e.port;return null===t?"":null===n?J(t):J(t)+":"+n},Ue=function(){var e=S(this).host;return null===e?"":J(e)},Le=function(){var e=S(this).port;return null===e?"":String(e)},je=function(){var e=S(this),t=e.path;return e.cannotBeABaseURL?t[0]:t.length?"/"+t.join("/"):""},_e=function(){var e=S(this).query;return e?"?"+e:""},Ne=function(){return S(this).searchParams},He=function(){var e=S(this).fragment;return e?"#"+e:""},Qe=function(e,t){return{get:e,set:t,configurable:!0,enumerable:!0}};if(o&&c(Pe,{href:Qe(Be,(function(e){var t=S(this),n=String(e),r=ke(t,n);if(r)throw TypeError(r);C(t.searchParams).updateSearchParams(t.query)})),origin:Qe(Oe),protocol:Qe(De,(function(e){var t=S(this);ke(t,String(e)+":",ae)})),username:Qe(Me,(function(e){var t=S(this),n=l(String(e));if(!ee(t)){t.username="";for(var r=0;r1?arguments[1]:void 0)}))},"3c5d":function(e,t,n){"use strict";var r=n("ebb5"),i=n("50c4"),o=n("182d"),a=n("7b0b"),s=n("d039"),c=r.aTypedArray,u=r.exportTypedArrayMethod,f=s((function(){new Int8Array(1).set({})}));u("set",(function(e){c(this);var t=o(arguments.length>1?arguments[1]:void 0,1),n=this.length,r=a(e),s=i(r.length),u=0;if(s+t>n)throw RangeError("Wrong length");while(u0&&void 0!==arguments[0]?arguments[0]:{},t=e.window,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{shimChrome:!0,shimFirefox:!0,shimSafari:!0},r=i.log,o=i.detectBrowser(t),s={browserDetails:o,commonShim:p,extractVersion:i.extractVersion,disableLog:i.disableLog,disableWarnings:i.disableWarnings,sdp:h};switch(o.browser){case"chrome":if(!a||!a.shimPeerConnection||!n.shimChrome)return r("Chrome shim is not included in this adapter release."),s;if(null===o.version)return r("Chrome shim can not determine version, not shimming."),s;r("adapter.js shimming chrome."),s.browserShim=a,p.shimAddIceCandidateNullOrEmpty(t,o),p.shimParameterlessSetLocalDescription(t,o),a.shimGetUserMedia(t,o),a.shimMediaStream(t,o),a.shimPeerConnection(t,o),a.shimOnTrack(t,o),a.shimAddTrackRemoveTrack(t,o),a.shimGetSendersWithDtmf(t,o),a.shimGetStats(t,o),a.shimSenderReceiverGetStats(t,o),a.fixNegotiationNeeded(t,o),p.shimRTCIceCandidate(t,o),p.shimConnectionState(t,o),p.shimMaxMessageSize(t,o),p.shimSendThrowTypeError(t,o),p.removeExtmapAllowMixed(t,o);break;case"firefox":if(!c||!c.shimPeerConnection||!n.shimFirefox)return r("Firefox shim is not included in this adapter release."),s;r("adapter.js shimming firefox."),s.browserShim=c,p.shimAddIceCandidateNullOrEmpty(t,o),p.shimParameterlessSetLocalDescription(t,o),c.shimGetUserMedia(t,o),c.shimPeerConnection(t,o),c.shimOnTrack(t,o),c.shimRemoveStream(t,o),c.shimSenderGetStats(t,o),c.shimReceiverGetStats(t,o),c.shimRTCDataChannel(t,o),c.shimAddTransceiver(t,o),c.shimGetParameters(t,o),c.shimCreateOffer(t,o),c.shimCreateAnswer(t,o),p.shimRTCIceCandidate(t,o),p.shimConnectionState(t,o),p.shimMaxMessageSize(t,o),p.shimSendThrowTypeError(t,o);break;case"safari":if(!f||!n.shimSafari)return r("Safari shim is not included in this adapter release."),s;r("adapter.js shimming safari."),s.browserShim=f,p.shimAddIceCandidateNullOrEmpty(t,o),p.shimParameterlessSetLocalDescription(t,o),f.shimRTCIceServerUrls(t,o),f.shimCreateOfferLegacy(t,o),f.shimCallbacksAPI(t,o),f.shimLocalStreamsAPI(t,o),f.shimRemoteStreamsAPI(t,o),f.shimTrackEventTransceiver(t,o),f.shimGetUserMedia(t,o),f.shimAudioContext(t,o),p.shimRTCIceCandidate(t,o),p.shimMaxMessageSize(t,o),p.shimSendThrowTypeError(t,o),p.removeExtmapAllowMixed(t,o);break;default:r("Unsupported browser!");break}return s}},{"./chrome/chrome_shim":3,"./common_shim":6,"./firefox/firefox_shim":7,"./safari/safari_shim":10,"./utils":11,sdp:12}],3:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.shimGetDisplayMedia=n.shimGetUserMedia=void 0;var r="function"===typeof Symbol&&"symbol"===s(Symbol.iterator)?function(e){return s(e)}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":s(e)},i=e("./getusermedia");Object.defineProperty(n,"shimGetUserMedia",{enumerable:!0,get:function(){return i.shimGetUserMedia}});var o=e("./getdisplaymedia");Object.defineProperty(n,"shimGetDisplayMedia",{enumerable:!0,get:function(){return o.shimGetDisplayMedia}}),n.shimMediaStream=d,n.shimOnTrack=p,n.shimGetSendersWithDtmf=l,n.shimGetStats=h,n.shimSenderReceiverGetStats=m,n.shimAddTrackRemoveTrackWithNative=g,n.shimAddTrackRemoveTrack=y,n.shimPeerConnection=v,n.fixNegotiationNeeded=b;var a=e("../utils.js"),c=u(a);function u(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}function f(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function d(e){e.MediaStream=e.MediaStream||e.webkitMediaStream}function p(e){if("object"===("undefined"===typeof e?"undefined":r(e))&&e.RTCPeerConnection&&!("ontrack"in e.RTCPeerConnection.prototype)){Object.defineProperty(e.RTCPeerConnection.prototype,"ontrack",{get:function(){return this._ontrack},set:function(e){this._ontrack&&this.removeEventListener("track",this._ontrack),this.addEventListener("track",this._ontrack=e)},enumerable:!0,configurable:!0});var t=e.RTCPeerConnection.prototype.setRemoteDescription;e.RTCPeerConnection.prototype.setRemoteDescription=function(){var n=this;return this._ontrackpoly||(this._ontrackpoly=function(t){t.stream.addEventListener("addtrack",(function(r){var i=void 0;i=e.RTCPeerConnection.prototype.getReceivers?n.getReceivers().find((function(e){return e.track&&e.track.id===r.track.id})):{track:r.track};var o=new Event("track");o.track=r.track,o.receiver=i,o.transceiver={receiver:i},o.streams=[t.stream],n.dispatchEvent(o)})),t.stream.getTracks().forEach((function(r){var i=void 0;i=e.RTCPeerConnection.prototype.getReceivers?n.getReceivers().find((function(e){return e.track&&e.track.id===r.id})):{track:r};var o=new Event("track");o.track=r,o.receiver=i,o.transceiver={receiver:i},o.streams=[t.stream],n.dispatchEvent(o)}))},this.addEventListener("addstream",this._ontrackpoly)),t.apply(this,arguments)}}else c.wrapPeerConnectionEvent(e,"track",(function(e){return e.transceiver||Object.defineProperty(e,"transceiver",{value:{receiver:e.receiver}}),e}))}function l(e){if("object"===("undefined"===typeof e?"undefined":r(e))&&e.RTCPeerConnection&&!("getSenders"in e.RTCPeerConnection.prototype)&&"createDTMFSender"in e.RTCPeerConnection.prototype){var t=function(e,t){return{track:t,get dtmf(){return void 0===this._dtmf&&("audio"===t.kind?this._dtmf=e.createDTMFSender(t):this._dtmf=null),this._dtmf},_pc:e}};if(!e.RTCPeerConnection.prototype.getSenders){e.RTCPeerConnection.prototype.getSenders=function(){return this._senders=this._senders||[],this._senders.slice()};var n=e.RTCPeerConnection.prototype.addTrack;e.RTCPeerConnection.prototype.addTrack=function(e,r){var i=n.apply(this,arguments);return i||(i=t(this,e),this._senders.push(i)),i};var i=e.RTCPeerConnection.prototype.removeTrack;e.RTCPeerConnection.prototype.removeTrack=function(e){i.apply(this,arguments);var t=this._senders.indexOf(e);-1!==t&&this._senders.splice(t,1)}}var o=e.RTCPeerConnection.prototype.addStream;e.RTCPeerConnection.prototype.addStream=function(e){var n=this;this._senders=this._senders||[],o.apply(this,[e]),e.getTracks().forEach((function(e){n._senders.push(t(n,e))}))};var a=e.RTCPeerConnection.prototype.removeStream;e.RTCPeerConnection.prototype.removeStream=function(e){var t=this;this._senders=this._senders||[],a.apply(this,[e]),e.getTracks().forEach((function(e){var n=t._senders.find((function(t){return t.track===e}));n&&t._senders.splice(t._senders.indexOf(n),1)}))}}else if("object"===("undefined"===typeof e?"undefined":r(e))&&e.RTCPeerConnection&&"getSenders"in e.RTCPeerConnection.prototype&&"createDTMFSender"in e.RTCPeerConnection.prototype&&e.RTCRtpSender&&!("dtmf"in e.RTCRtpSender.prototype)){var s=e.RTCPeerConnection.prototype.getSenders;e.RTCPeerConnection.prototype.getSenders=function(){var e=this,t=s.apply(this,[]);return t.forEach((function(t){return t._pc=e})),t},Object.defineProperty(e.RTCRtpSender.prototype,"dtmf",{get:function(){return void 0===this._dtmf&&("audio"===this.track.kind?this._dtmf=this._pc.createDTMFSender(this.track):this._dtmf=null),this._dtmf}})}}function h(e){if(e.RTCPeerConnection){var t=e.RTCPeerConnection.prototype.getStats;e.RTCPeerConnection.prototype.getStats=function(){var e=this,n=Array.prototype.slice.call(arguments),r=n[0],i=n[1],o=n[2];if(arguments.length>0&&"function"===typeof r)return t.apply(this,arguments);if(0===t.length&&(0===arguments.length||"function"!==typeof r))return t.apply(this,[]);var a=function(e){var t={},n=e.result();return n.forEach((function(e){var n={id:e.id,timestamp:e.timestamp,type:{localcandidate:"local-candidate",remotecandidate:"remote-candidate"}[e.type]||e.type};e.names().forEach((function(t){n[t]=e.stat(t)})),t[n.id]=n})),t},s=function(e){return new Map(Object.keys(e).map((function(t){return[t,e[t]]})))};if(arguments.length>=2){var c=function(e){i(s(a(e)))};return t.apply(this,[c,r])}return new Promise((function(n,r){t.apply(e,[function(e){n(s(a(e)))},r])})).then(i,o)}}}function m(e){if("object"===("undefined"===typeof e?"undefined":r(e))&&e.RTCPeerConnection&&e.RTCRtpSender&&e.RTCRtpReceiver){if(!("getStats"in e.RTCRtpSender.prototype)){var t=e.RTCPeerConnection.prototype.getSenders;t&&(e.RTCPeerConnection.prototype.getSenders=function(){var e=this,n=t.apply(this,[]);return n.forEach((function(t){return t._pc=e})),n});var n=e.RTCPeerConnection.prototype.addTrack;n&&(e.RTCPeerConnection.prototype.addTrack=function(){var e=n.apply(this,arguments);return e._pc=this,e}),e.RTCRtpSender.prototype.getStats=function(){var e=this;return this._pc.getStats().then((function(t){return c.filterStats(t,e.track,!0)}))}}if(!("getStats"in e.RTCRtpReceiver.prototype)){var i=e.RTCPeerConnection.prototype.getReceivers;i&&(e.RTCPeerConnection.prototype.getReceivers=function(){var e=this,t=i.apply(this,[]);return t.forEach((function(t){return t._pc=e})),t}),c.wrapPeerConnectionEvent(e,"track",(function(e){return e.receiver._pc=e.srcElement,e})),e.RTCRtpReceiver.prototype.getStats=function(){var e=this;return this._pc.getStats().then((function(t){return c.filterStats(t,e.track,!1)}))}}if("getStats"in e.RTCRtpSender.prototype&&"getStats"in e.RTCRtpReceiver.prototype){var o=e.RTCPeerConnection.prototype.getStats;e.RTCPeerConnection.prototype.getStats=function(){if(arguments.length>0&&arguments[0]instanceof e.MediaStreamTrack){var t=arguments[0],n=void 0,r=void 0,i=void 0;return this.getSenders().forEach((function(e){e.track===t&&(n?i=!0:n=e)})),this.getReceivers().forEach((function(e){return e.track===t&&(r?i=!0:r=e),e.track===t})),i||n&&r?Promise.reject(new DOMException("There are more than one sender or receiver for the track.","InvalidAccessError")):n?n.getStats():r?r.getStats():Promise.reject(new DOMException("There is no sender or receiver for the track.","InvalidAccessError"))}return o.apply(this,arguments)}}}}function g(e){e.RTCPeerConnection.prototype.getLocalStreams=function(){var e=this;return this._shimmedLocalStreams=this._shimmedLocalStreams||{},Object.keys(this._shimmedLocalStreams).map((function(t){return e._shimmedLocalStreams[t][0]}))};var t=e.RTCPeerConnection.prototype.addTrack;e.RTCPeerConnection.prototype.addTrack=function(e,n){if(!n)return t.apply(this,arguments);this._shimmedLocalStreams=this._shimmedLocalStreams||{};var r=t.apply(this,arguments);return this._shimmedLocalStreams[n.id]?-1===this._shimmedLocalStreams[n.id].indexOf(r)&&this._shimmedLocalStreams[n.id].push(r):this._shimmedLocalStreams[n.id]=[n,r],r};var n=e.RTCPeerConnection.prototype.addStream;e.RTCPeerConnection.prototype.addStream=function(e){var t=this;this._shimmedLocalStreams=this._shimmedLocalStreams||{},e.getTracks().forEach((function(e){var n=t.getSenders().find((function(t){return t.track===e}));if(n)throw new DOMException("Track already exists.","InvalidAccessError")}));var r=this.getSenders();n.apply(this,arguments);var i=this.getSenders().filter((function(e){return-1===r.indexOf(e)}));this._shimmedLocalStreams[e.id]=[e].concat(i)};var r=e.RTCPeerConnection.prototype.removeStream;e.RTCPeerConnection.prototype.removeStream=function(e){return this._shimmedLocalStreams=this._shimmedLocalStreams||{},delete this._shimmedLocalStreams[e.id],r.apply(this,arguments)};var i=e.RTCPeerConnection.prototype.removeTrack;e.RTCPeerConnection.prototype.removeTrack=function(e){var t=this;return this._shimmedLocalStreams=this._shimmedLocalStreams||{},e&&Object.keys(this._shimmedLocalStreams).forEach((function(n){var r=t._shimmedLocalStreams[n].indexOf(e);-1!==r&&t._shimmedLocalStreams[n].splice(r,1),1===t._shimmedLocalStreams[n].length&&delete t._shimmedLocalStreams[n]})),i.apply(this,arguments)}}function y(e,t){if(e.RTCPeerConnection){if(e.RTCPeerConnection.prototype.addTrack&&t.version>=65)return g(e);var n=e.RTCPeerConnection.prototype.getLocalStreams;e.RTCPeerConnection.prototype.getLocalStreams=function(){var e=this,t=n.apply(this);return this._reverseStreams=this._reverseStreams||{},t.map((function(t){return e._reverseStreams[t.id]}))};var r=e.RTCPeerConnection.prototype.addStream;e.RTCPeerConnection.prototype.addStream=function(t){var n=this;if(this._streams=this._streams||{},this._reverseStreams=this._reverseStreams||{},t.getTracks().forEach((function(e){var t=n.getSenders().find((function(t){return t.track===e}));if(t)throw new DOMException("Track already exists.","InvalidAccessError")})),!this._reverseStreams[t.id]){var i=new e.MediaStream(t.getTracks());this._streams[t.id]=i,this._reverseStreams[i.id]=t,t=i}r.apply(this,[t])};var i=e.RTCPeerConnection.prototype.removeStream;e.RTCPeerConnection.prototype.removeStream=function(e){this._streams=this._streams||{},this._reverseStreams=this._reverseStreams||{},i.apply(this,[this._streams[e.id]||e]),delete this._reverseStreams[this._streams[e.id]?this._streams[e.id].id:e.id],delete this._streams[e.id]},e.RTCPeerConnection.prototype.addTrack=function(t,n){var r=this;if("closed"===this.signalingState)throw new DOMException("The RTCPeerConnection's signalingState is 'closed'.","InvalidStateError");var i=[].slice.call(arguments,1);if(1!==i.length||!i[0].getTracks().find((function(e){return e===t})))throw new DOMException("The adapter.js addTrack polyfill only supports a single stream which is associated with the specified track.","NotSupportedError");var o=this.getSenders().find((function(e){return e.track===t}));if(o)throw new DOMException("Track already exists.","InvalidAccessError");this._streams=this._streams||{},this._reverseStreams=this._reverseStreams||{};var a=this._streams[n.id];if(a)a.addTrack(t),Promise.resolve().then((function(){r.dispatchEvent(new Event("negotiationneeded"))}));else{var s=new e.MediaStream([t]);this._streams[n.id]=s,this._reverseStreams[s.id]=n,this.addStream(s)}return this.getSenders().find((function(e){return e.track===t}))},["createOffer","createAnswer"].forEach((function(t){var n=e.RTCPeerConnection.prototype[t],r=f({},t,(function(){var e=this,t=arguments,r=arguments.length&&"function"===typeof arguments[0];return r?n.apply(this,[function(n){var r=s(e,n);t[0].apply(null,[r])},function(e){t[1]&&t[1].apply(null,e)},arguments[2]]):n.apply(this,arguments).then((function(t){return s(e,t)}))}));e.RTCPeerConnection.prototype[t]=r[t]}));var o=e.RTCPeerConnection.prototype.setLocalDescription;e.RTCPeerConnection.prototype.setLocalDescription=function(){return arguments.length&&arguments[0].type?(arguments[0]=c(this,arguments[0]),o.apply(this,arguments)):o.apply(this,arguments)};var a=Object.getOwnPropertyDescriptor(e.RTCPeerConnection.prototype,"localDescription");Object.defineProperty(e.RTCPeerConnection.prototype,"localDescription",{get:function(){var e=a.get.apply(this);return""===e.type?e:s(this,e)}}),e.RTCPeerConnection.prototype.removeTrack=function(e){var t=this;if("closed"===this.signalingState)throw new DOMException("The RTCPeerConnection's signalingState is 'closed'.","InvalidStateError");if(!e._pc)throw new DOMException("Argument 1 of RTCPeerConnection.removeTrack does not implement interface RTCRtpSender.","TypeError");var n=e._pc===this;if(!n)throw new DOMException("Sender was not created by this connection.","InvalidAccessError");this._streams=this._streams||{};var r=void 0;Object.keys(this._streams).forEach((function(n){var i=t._streams[n].getTracks().find((function(t){return e.track===t}));i&&(r=t._streams[n])})),r&&(1===r.getTracks().length?this.removeStream(this._reverseStreams[r.id]):r.removeTrack(e.track),this.dispatchEvent(new Event("negotiationneeded")))}}function s(e,t){var n=t.sdp;return Object.keys(e._reverseStreams||[]).forEach((function(t){var r=e._reverseStreams[t],i=e._streams[r.id];n=n.replace(new RegExp(i.id,"g"),r.id)})),new RTCSessionDescription({type:t.type,sdp:n})}function c(e,t){var n=t.sdp;return Object.keys(e._reverseStreams||[]).forEach((function(t){var r=e._reverseStreams[t],i=e._streams[r.id];n=n.replace(new RegExp(r.id,"g"),i.id)})),new RTCSessionDescription({type:t.type,sdp:n})}}function v(e,t){!e.RTCPeerConnection&&e.webkitRTCPeerConnection&&(e.RTCPeerConnection=e.webkitRTCPeerConnection),e.RTCPeerConnection&&t.version<53&&["setLocalDescription","setRemoteDescription","addIceCandidate"].forEach((function(t){var n=e.RTCPeerConnection.prototype[t],r=f({},t,(function(){return arguments[0]=new("addIceCandidate"===t?e.RTCIceCandidate:e.RTCSessionDescription)(arguments[0]),n.apply(this,arguments)}));e.RTCPeerConnection.prototype[t]=r[t]}))}function b(e,t){c.wrapPeerConnectionEvent(e,"negotiationneeded",(function(e){var n=e.target;if(!(t.version<72||n.getConfiguration&&"plan-b"===n.getConfiguration().sdpSemantics)||"stable"===n.signalingState)return e}))}},{"../utils.js":11,"./getdisplaymedia":4,"./getusermedia":5}],4:[function(e,t,n){"use strict";function r(e,t){e.navigator.mediaDevices&&"getDisplayMedia"in e.navigator.mediaDevices||e.navigator.mediaDevices&&"function"===typeof t&&(e.navigator.mediaDevices.getDisplayMedia=function(n){return t(n).then((function(t){var r=n.video&&n.video.width,i=n.video&&n.video.height,o=n.video&&n.video.frameRate;return n.video={mandatory:{chromeMediaSource:"desktop",chromeMediaSourceId:t,maxFrameRate:o||3}},r&&(n.video.mandatory.maxWidth=r),i&&(n.video.mandatory.maxHeight=i),e.navigator.mediaDevices.getUserMedia(n)}))})}Object.defineProperty(n,"__esModule",{value:!0}),n.shimGetDisplayMedia=r},{}],5:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r="function"===typeof Symbol&&"symbol"===s(Symbol.iterator)?function(e){return s(e)}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":s(e)};n.shimGetUserMedia=u;var i=e("../utils.js"),o=a(i);function a(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}var c=o.log;function u(e,t){var n=e&&e.navigator;if(n.mediaDevices){var i=function(e){if("object"!==("undefined"===typeof e?"undefined":r(e))||e.mandatory||e.optional)return e;var t={};return Object.keys(e).forEach((function(n){if("require"!==n&&"advanced"!==n&&"mediaSource"!==n){var i="object"===r(e[n])?e[n]:{ideal:e[n]};void 0!==i.exact&&"number"===typeof i.exact&&(i.min=i.max=i.exact);var o=function(e,t){return e?e+t.charAt(0).toUpperCase()+t.slice(1):"deviceId"===t?"sourceId":t};if(void 0!==i.ideal){t.optional=t.optional||[];var a={};"number"===typeof i.ideal?(a[o("min",n)]=i.ideal,t.optional.push(a),a={},a[o("max",n)]=i.ideal,t.optional.push(a)):(a[o("",n)]=i.ideal,t.optional.push(a))}void 0!==i.exact&&"number"!==typeof i.exact?(t.mandatory=t.mandatory||{},t.mandatory[o("",n)]=i.exact):["min","max"].forEach((function(e){void 0!==i[e]&&(t.mandatory=t.mandatory||{},t.mandatory[o(e,n)]=i[e])}))}})),e.advanced&&(t.optional=(t.optional||[]).concat(e.advanced)),t},o=function(e,o){if(t.version>=61)return o(e);if(e=JSON.parse(JSON.stringify(e)),e&&"object"===r(e.audio)){var a=function(e,t,n){t in e&&!(n in e)&&(e[n]=e[t],delete e[t])};e=JSON.parse(JSON.stringify(e)),a(e.audio,"autoGainControl","googAutoGainControl"),a(e.audio,"noiseSuppression","googNoiseSuppression"),e.audio=i(e.audio)}if(e&&"object"===r(e.video)){var s=e.video.facingMode;s=s&&("object"===("undefined"===typeof s?"undefined":r(s))?s:{ideal:s});var u=t.version<66;if(s&&("user"===s.exact||"environment"===s.exact||"user"===s.ideal||"environment"===s.ideal)&&(!n.mediaDevices.getSupportedConstraints||!n.mediaDevices.getSupportedConstraints().facingMode||u)){delete e.video.facingMode;var f=void 0;if("environment"===s.exact||"environment"===s.ideal?f=["back","rear"]:"user"!==s.exact&&"user"!==s.ideal||(f=["front"]),f)return n.mediaDevices.enumerateDevices().then((function(t){t=t.filter((function(e){return"videoinput"===e.kind}));var n=t.find((function(e){return f.some((function(t){return e.label.toLowerCase().includes(t)}))}));return!n&&t.length&&f.includes("back")&&(n=t[t.length-1]),n&&(e.video.deviceId=s.exact?{exact:n.deviceId}:{ideal:n.deviceId}),e.video=i(e.video),c("chrome: "+JSON.stringify(e)),o(e)}))}e.video=i(e.video)}return c("chrome: "+JSON.stringify(e)),o(e)},a=function(e){return t.version>=64?e:{name:{PermissionDeniedError:"NotAllowedError",PermissionDismissedError:"NotAllowedError",InvalidStateError:"NotAllowedError",DevicesNotFoundError:"NotFoundError",ConstraintNotSatisfiedError:"OverconstrainedError",TrackStartError:"NotReadableError",MediaDeviceFailedDueToShutdown:"NotAllowedError",MediaDeviceKillSwitchOn:"NotAllowedError",TabCaptureError:"AbortError",ScreenCaptureError:"AbortError",DeviceCaptureError:"AbortError"}[e.name]||e.name,message:e.message,constraint:e.constraint||e.constraintName,toString:function(){return this.name+(this.message&&": ")+this.message}}},s=function(e,t,r){o(e,(function(e){n.webkitGetUserMedia(e,t,(function(e){r&&r(a(e))}))}))};if(n.getUserMedia=s.bind(n),n.mediaDevices.getUserMedia){var u=n.mediaDevices.getUserMedia.bind(n.mediaDevices);n.mediaDevices.getUserMedia=function(e){return o(e,(function(e){return u(e).then((function(t){if(e.audio&&!t.getAudioTracks().length||e.video&&!t.getVideoTracks().length)throw t.getTracks().forEach((function(e){e.stop()})),new DOMException("","NotFoundError");return t}),(function(e){return Promise.reject(a(e))}))}))}}}}},{"../utils.js":11}],6:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r="function"===typeof Symbol&&"symbol"===s(Symbol.iterator)?function(e){return s(e)}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":s(e)};n.shimRTCIceCandidate=d,n.shimMaxMessageSize=p,n.shimSendThrowTypeError=l,n.shimConnectionState=h,n.removeExtmapAllowMixed=m,n.shimAddIceCandidateNullOrEmpty=g,n.shimParameterlessSetLocalDescription=y;var i=e("sdp"),o=f(i),a=e("./utils"),c=u(a);function u(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}function f(e){return e&&e.__esModule?e:{default:e}}function d(e){if(!(!e.RTCIceCandidate||e.RTCIceCandidate&&"foundation"in e.RTCIceCandidate.prototype)){var t=e.RTCIceCandidate;e.RTCIceCandidate=function(e){if("object"===("undefined"===typeof e?"undefined":r(e))&&e.candidate&&0===e.candidate.indexOf("a=")&&(e=JSON.parse(JSON.stringify(e)),e.candidate=e.candidate.substr(2)),e.candidate&&e.candidate.length){var n=new t(e),i=o.default.parseCandidate(e.candidate),a=Object.assign(n,i);return a.toJSON=function(){return{candidate:a.candidate,sdpMid:a.sdpMid,sdpMLineIndex:a.sdpMLineIndex,usernameFragment:a.usernameFragment}},a}return new t(e)},e.RTCIceCandidate.prototype=t.prototype,c.wrapPeerConnectionEvent(e,"icecandidate",(function(t){return t.candidate&&Object.defineProperty(t,"candidate",{value:new e.RTCIceCandidate(t.candidate),writable:"false"}),t}))}}function p(e,t){if(e.RTCPeerConnection){"sctp"in e.RTCPeerConnection.prototype||Object.defineProperty(e.RTCPeerConnection.prototype,"sctp",{get:function(){return"undefined"===typeof this._sctp?null:this._sctp}});var n=function(e){if(!e||!e.sdp)return!1;var t=o.default.splitSections(e.sdp);return t.shift(),t.some((function(e){var t=o.default.parseMLine(e);return t&&"application"===t.kind&&-1!==t.protocol.indexOf("SCTP")}))},r=function(e){var t=e.sdp.match(/mozilla...THIS_IS_SDPARTA-(\d+)/);if(null===t||t.length<2)return-1;var n=parseInt(t[1],10);return n!==n?-1:n},i=function(e){var n=65536;return"firefox"===t.browser&&(n=t.version<57?-1===e?16384:2147483637:t.version<60?57===t.version?65535:65536:2147483637),n},a=function(e,n){var r=65536;"firefox"===t.browser&&57===t.version&&(r=65535);var i=o.default.matchPrefix(e.sdp,"a=max-message-size:");return i.length>0?r=parseInt(i[0].substr(19),10):"firefox"===t.browser&&-1!==n&&(r=2147483637),r},s=e.RTCPeerConnection.prototype.setRemoteDescription;e.RTCPeerConnection.prototype.setRemoteDescription=function(){if(this._sctp=null,"chrome"===t.browser&&t.version>=76){var e=this.getConfiguration(),o=e.sdpSemantics;"plan-b"===o&&Object.defineProperty(this,"sctp",{get:function(){return"undefined"===typeof this._sctp?null:this._sctp},enumerable:!0,configurable:!0})}if(n(arguments[0])){var c=r(arguments[0]),u=i(c),f=a(arguments[0],c),d=void 0;d=0===u&&0===f?Number.POSITIVE_INFINITY:0===u||0===f?Math.max(u,f):Math.min(u,f);var p={};Object.defineProperty(p,"maxMessageSize",{get:function(){return d}}),this._sctp=p}return s.apply(this,arguments)}}}function l(e){if(e.RTCPeerConnection&&"createDataChannel"in e.RTCPeerConnection.prototype){var t=e.RTCPeerConnection.prototype.createDataChannel;e.RTCPeerConnection.prototype.createDataChannel=function(){var e=t.apply(this,arguments);return n(e,this),e},c.wrapPeerConnectionEvent(e,"datachannel",(function(e){return n(e.channel,e.target),e}))}function n(e,t){var n=e.send;e.send=function(){var r=arguments[0],i=r.length||r.size||r.byteLength;if("open"===e.readyState&&t.sctp&&i>t.sctp.maxMessageSize)throw new TypeError("Message too large (can send a maximum of "+t.sctp.maxMessageSize+" bytes)");return n.apply(e,arguments)}}}function h(e){if(e.RTCPeerConnection&&!("connectionState"in e.RTCPeerConnection.prototype)){var t=e.RTCPeerConnection.prototype;Object.defineProperty(t,"connectionState",{get:function(){return{completed:"connected",checking:"connecting"}[this.iceConnectionState]||this.iceConnectionState},enumerable:!0,configurable:!0}),Object.defineProperty(t,"onconnectionstatechange",{get:function(){return this._onconnectionstatechange||null},set:function(e){this._onconnectionstatechange&&(this.removeEventListener("connectionstatechange",this._onconnectionstatechange),delete this._onconnectionstatechange),e&&this.addEventListener("connectionstatechange",this._onconnectionstatechange=e)},enumerable:!0,configurable:!0}),["setLocalDescription","setRemoteDescription"].forEach((function(e){var n=t[e];t[e]=function(){return this._connectionstatechangepoly||(this._connectionstatechangepoly=function(e){var t=e.target;if(t._lastConnectionState!==t.connectionState){t._lastConnectionState=t.connectionState;var n=new Event("connectionstatechange",e);t.dispatchEvent(n)}return e},this.addEventListener("iceconnectionstatechange",this._connectionstatechangepoly)),n.apply(this,arguments)}}))}}function m(e,t){if(e.RTCPeerConnection&&!("chrome"===t.browser&&t.version>=71)&&!("safari"===t.browser&&t.version>=605)){var n=e.RTCPeerConnection.prototype.setRemoteDescription;e.RTCPeerConnection.prototype.setRemoteDescription=function(t){if(t&&t.sdp&&-1!==t.sdp.indexOf("\na=extmap-allow-mixed")){var r=t.sdp.split("\n").filter((function(e){return"a=extmap-allow-mixed"!==e.trim()})).join("\n");e.RTCSessionDescription&&t instanceof e.RTCSessionDescription?arguments[0]=new e.RTCSessionDescription({type:t.type,sdp:r}):t.sdp=r}return n.apply(this,arguments)}}}function g(e,t){if(e.RTCPeerConnection&&e.RTCPeerConnection.prototype){var n=e.RTCPeerConnection.prototype.addIceCandidate;n&&0!==n.length&&(e.RTCPeerConnection.prototype.addIceCandidate=function(){return arguments[0]?("chrome"===t.browser&&t.version<78||"firefox"===t.browser&&t.version<68||"safari"===t.browser)&&arguments[0]&&""===arguments[0].candidate?Promise.resolve():n.apply(this,arguments):(arguments[1]&&arguments[1].apply(null),Promise.resolve())})}}function y(e,t){if(e.RTCPeerConnection&&e.RTCPeerConnection.prototype){var n=e.RTCPeerConnection.prototype.setLocalDescription;n&&0!==n.length&&(e.RTCPeerConnection.prototype.setLocalDescription=function(){var e=this,t=arguments[0]||{};if("object"!==("undefined"===typeof t?"undefined":r(t))||t.type&&t.sdp)return n.apply(this,arguments);if(t={type:t.type,sdp:t.sdp},!t.type)switch(this.signalingState){case"stable":case"have-local-offer":case"have-remote-pranswer":t.type="offer";break;default:t.type="answer";break}if(t.sdp||"offer"!==t.type&&"answer"!==t.type)return n.apply(this,[t]);var i="offer"===t.type?this.createOffer:this.createAnswer;return i.apply(this).then((function(t){return n.apply(e,[t])}))})}}},{"./utils":11,sdp:12}],7:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.shimGetDisplayMedia=n.shimGetUserMedia=void 0;var r="function"===typeof Symbol&&"symbol"===s(Symbol.iterator)?function(e){return s(e)}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":s(e)},i=e("./getusermedia");Object.defineProperty(n,"shimGetUserMedia",{enumerable:!0,get:function(){return i.shimGetUserMedia}});var o=e("./getdisplaymedia");Object.defineProperty(n,"shimGetDisplayMedia",{enumerable:!0,get:function(){return o.shimGetDisplayMedia}}),n.shimOnTrack=d,n.shimPeerConnection=p,n.shimSenderGetStats=l,n.shimReceiverGetStats=h,n.shimRemoveStream=m,n.shimRTCDataChannel=g,n.shimAddTransceiver=y,n.shimGetParameters=v,n.shimCreateOffer=b,n.shimCreateAnswer=w;var a=e("../utils"),c=u(a);function u(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}function f(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function d(e){"object"===("undefined"===typeof e?"undefined":r(e))&&e.RTCTrackEvent&&"receiver"in e.RTCTrackEvent.prototype&&!("transceiver"in e.RTCTrackEvent.prototype)&&Object.defineProperty(e.RTCTrackEvent.prototype,"transceiver",{get:function(){return{receiver:this.receiver}}})}function p(e,t){if("object"===("undefined"===typeof e?"undefined":r(e))&&(e.RTCPeerConnection||e.mozRTCPeerConnection)){!e.RTCPeerConnection&&e.mozRTCPeerConnection&&(e.RTCPeerConnection=e.mozRTCPeerConnection),t.version<53&&["setLocalDescription","setRemoteDescription","addIceCandidate"].forEach((function(t){var n=e.RTCPeerConnection.prototype[t],r=f({},t,(function(){return arguments[0]=new("addIceCandidate"===t?e.RTCIceCandidate:e.RTCSessionDescription)(arguments[0]),n.apply(this,arguments)}));e.RTCPeerConnection.prototype[t]=r[t]}));var n={inboundrtp:"inbound-rtp",outboundrtp:"outbound-rtp",candidatepair:"candidate-pair",localcandidate:"local-candidate",remotecandidate:"remote-candidate"},i=e.RTCPeerConnection.prototype.getStats;e.RTCPeerConnection.prototype.getStats=function(){var e=Array.prototype.slice.call(arguments),r=e[0],o=e[1],a=e[2];return i.apply(this,[r||null]).then((function(e){if(t.version<53&&!o)try{e.forEach((function(e){e.type=n[e.type]||e.type}))}catch(r){if("TypeError"!==r.name)throw r;e.forEach((function(t,r){e.set(r,Object.assign({},t,{type:n[t.type]||t.type}))}))}return e})).then(o,a)}}}function l(e){if("object"===("undefined"===typeof e?"undefined":r(e))&&e.RTCPeerConnection&&e.RTCRtpSender&&(!e.RTCRtpSender||!("getStats"in e.RTCRtpSender.prototype))){var t=e.RTCPeerConnection.prototype.getSenders;t&&(e.RTCPeerConnection.prototype.getSenders=function(){var e=this,n=t.apply(this,[]);return n.forEach((function(t){return t._pc=e})),n});var n=e.RTCPeerConnection.prototype.addTrack;n&&(e.RTCPeerConnection.prototype.addTrack=function(){var e=n.apply(this,arguments);return e._pc=this,e}),e.RTCRtpSender.prototype.getStats=function(){return this.track?this._pc.getStats(this.track):Promise.resolve(new Map)}}}function h(e){if("object"===("undefined"===typeof e?"undefined":r(e))&&e.RTCPeerConnection&&e.RTCRtpSender&&(!e.RTCRtpSender||!("getStats"in e.RTCRtpReceiver.prototype))){var t=e.RTCPeerConnection.prototype.getReceivers;t&&(e.RTCPeerConnection.prototype.getReceivers=function(){var e=this,n=t.apply(this,[]);return n.forEach((function(t){return t._pc=e})),n}),c.wrapPeerConnectionEvent(e,"track",(function(e){return e.receiver._pc=e.srcElement,e})),e.RTCRtpReceiver.prototype.getStats=function(){return this._pc.getStats(this.track)}}}function m(e){e.RTCPeerConnection&&!("removeStream"in e.RTCPeerConnection.prototype)&&(e.RTCPeerConnection.prototype.removeStream=function(e){var t=this;c.deprecated("removeStream","removeTrack"),this.getSenders().forEach((function(n){n.track&&e.getTracks().includes(n.track)&&t.removeTrack(n)}))})}function g(e){e.DataChannel&&!e.RTCDataChannel&&(e.RTCDataChannel=e.DataChannel)}function y(e){if("object"===("undefined"===typeof e?"undefined":r(e))&&e.RTCPeerConnection){var t=e.RTCPeerConnection.prototype.addTransceiver;t&&(e.RTCPeerConnection.prototype.addTransceiver=function(){this.setParametersPromises=[];var e=arguments[1],n=e&&"sendEncodings"in e;n&&e.sendEncodings.forEach((function(e){if("rid"in e){var t=/^[a-z0-9]{0,16}$/i;if(!t.test(e.rid))throw new TypeError("Invalid RID value provided.")}if("scaleResolutionDownBy"in e&&!(parseFloat(e.scaleResolutionDownBy)>=1))throw new RangeError("scale_resolution_down_by must be >= 1.0");if("maxFramerate"in e&&!(parseFloat(e.maxFramerate)>=0))throw new RangeError("max_framerate must be >= 0.0")}));var r=t.apply(this,arguments);if(n){var i=r.sender,o=i.getParameters();(!("encodings"in o)||1===o.encodings.length&&0===Object.keys(o.encodings[0]).length)&&(o.encodings=e.sendEncodings,i.sendEncodings=e.sendEncodings,this.setParametersPromises.push(i.setParameters(o).then((function(){delete i.sendEncodings})).catch((function(){delete i.sendEncodings}))))}return r})}}function v(e){if("object"===("undefined"===typeof e?"undefined":r(e))&&e.RTCRtpSender){var t=e.RTCRtpSender.prototype.getParameters;t&&(e.RTCRtpSender.prototype.getParameters=function(){var e=t.apply(this,arguments);return"encodings"in e||(e.encodings=[].concat(this.sendEncodings||[{}])),e})}}function b(e){if("object"===("undefined"===typeof e?"undefined":r(e))&&e.RTCPeerConnection){var t=e.RTCPeerConnection.prototype.createOffer;e.RTCPeerConnection.prototype.createOffer=function(){var e=this,n=arguments;return this.setParametersPromises&&this.setParametersPromises.length?Promise.all(this.setParametersPromises).then((function(){return t.apply(e,n)})).finally((function(){e.setParametersPromises=[]})):t.apply(this,arguments)}}}function w(e){if("object"===("undefined"===typeof e?"undefined":r(e))&&e.RTCPeerConnection){var t=e.RTCPeerConnection.prototype.createAnswer;e.RTCPeerConnection.prototype.createAnswer=function(){var e=this,n=arguments;return this.setParametersPromises&&this.setParametersPromises.length?Promise.all(this.setParametersPromises).then((function(){return t.apply(e,n)})).finally((function(){e.setParametersPromises=[]})):t.apply(this,arguments)}}}},{"../utils":11,"./getdisplaymedia":8,"./getusermedia":9}],8:[function(e,t,n){"use strict";function r(e,t){e.navigator.mediaDevices&&"getDisplayMedia"in e.navigator.mediaDevices||e.navigator.mediaDevices&&(e.navigator.mediaDevices.getDisplayMedia=function(n){if(!n||!n.video){var r=new DOMException("getDisplayMedia without video constraints is undefined");return r.name="NotFoundError",r.code=8,Promise.reject(r)}return!0===n.video?n.video={mediaSource:t}:n.video.mediaSource=t,e.navigator.mediaDevices.getUserMedia(n)})}Object.defineProperty(n,"__esModule",{value:!0}),n.shimGetDisplayMedia=r},{}],9:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r="function"===typeof Symbol&&"symbol"===s(Symbol.iterator)?function(e){return s(e)}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":s(e)};n.shimGetUserMedia=c;var i=e("../utils"),o=a(i);function a(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}function c(e,t){var n=e&&e.navigator,i=e&&e.MediaStreamTrack;if(n.getUserMedia=function(e,t,r){o.deprecated("navigator.getUserMedia","navigator.mediaDevices.getUserMedia"),n.mediaDevices.getUserMedia(e).then(t,r)},!(t.version>55&&"autoGainControl"in n.mediaDevices.getSupportedConstraints())){var a=function(e,t,n){t in e&&!(n in e)&&(e[n]=e[t],delete e[t])},s=n.mediaDevices.getUserMedia.bind(n.mediaDevices);if(n.mediaDevices.getUserMedia=function(e){return"object"===("undefined"===typeof e?"undefined":r(e))&&"object"===r(e.audio)&&(e=JSON.parse(JSON.stringify(e)),a(e.audio,"autoGainControl","mozAutoGainControl"),a(e.audio,"noiseSuppression","mozNoiseSuppression")),s(e)},i&&i.prototype.getSettings){var c=i.prototype.getSettings;i.prototype.getSettings=function(){var e=c.apply(this,arguments);return a(e,"mozAutoGainControl","autoGainControl"),a(e,"mozNoiseSuppression","noiseSuppression"),e}}if(i&&i.prototype.applyConstraints){var u=i.prototype.applyConstraints;i.prototype.applyConstraints=function(e){return"audio"===this.kind&&"object"===("undefined"===typeof e?"undefined":r(e))&&(e=JSON.parse(JSON.stringify(e)),a(e,"autoGainControl","mozAutoGainControl"),a(e,"noiseSuppression","mozNoiseSuppression")),u.apply(this,[e])}}}}},{"../utils":11}],10:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r="function"===typeof Symbol&&"symbol"===s(Symbol.iterator)?function(e){return s(e)}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":s(e)};n.shimLocalStreamsAPI=c,n.shimRemoteStreamsAPI=u,n.shimCallbacksAPI=f,n.shimGetUserMedia=d,n.shimConstraints=p,n.shimRTCIceServerUrls=l,n.shimTrackEventTransceiver=h,n.shimCreateOfferLegacy=m,n.shimAudioContext=g;var i=e("../utils"),o=a(i);function a(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}function c(e){if("object"===("undefined"===typeof e?"undefined":r(e))&&e.RTCPeerConnection){if("getLocalStreams"in e.RTCPeerConnection.prototype||(e.RTCPeerConnection.prototype.getLocalStreams=function(){return this._localStreams||(this._localStreams=[]),this._localStreams}),!("addStream"in e.RTCPeerConnection.prototype)){var t=e.RTCPeerConnection.prototype.addTrack;e.RTCPeerConnection.prototype.addStream=function(e){var n=this;this._localStreams||(this._localStreams=[]),this._localStreams.includes(e)||this._localStreams.push(e),e.getAudioTracks().forEach((function(r){return t.call(n,r,e)})),e.getVideoTracks().forEach((function(r){return t.call(n,r,e)}))},e.RTCPeerConnection.prototype.addTrack=function(e){for(var n=this,r=arguments.length,i=Array(r>1?r-1:0),o=1;o=0)){e._remoteStreams.push(t);var n=new Event("addstream");n.stream=t,e.dispatchEvent(n)}}))}),t.apply(e,arguments)}}}function f(e){if("object"===("undefined"===typeof e?"undefined":r(e))&&e.RTCPeerConnection){var t=e.RTCPeerConnection.prototype,n=t.createOffer,i=t.createAnswer,o=t.setLocalDescription,a=t.setRemoteDescription,s=t.addIceCandidate;t.createOffer=function(e,t){var r=arguments.length>=2?arguments[2]:arguments[0],i=n.apply(this,[r]);return t?(i.then(e,t),Promise.resolve()):i},t.createAnswer=function(e,t){var n=arguments.length>=2?arguments[2]:arguments[0],r=i.apply(this,[n]);return t?(r.then(e,t),Promise.resolve()):r};var c=function(e,t,n){var r=o.apply(this,[e]);return n?(r.then(t,n),Promise.resolve()):r};t.setLocalDescription=c,c=function(e,t,n){var r=a.apply(this,[e]);return n?(r.then(t,n),Promise.resolve()):r},t.setRemoteDescription=c,c=function(e,t,n){var r=s.apply(this,[e]);return n?(r.then(t,n),Promise.resolve()):r},t.addIceCandidate=c}}function d(e){var t=e&&e.navigator;if(t.mediaDevices&&t.mediaDevices.getUserMedia){var n=t.mediaDevices,r=n.getUserMedia.bind(n);t.mediaDevices.getUserMedia=function(e){return r(p(e))}}!t.getUserMedia&&t.mediaDevices&&t.mediaDevices.getUserMedia&&(t.getUserMedia=function(e,n,r){t.mediaDevices.getUserMedia(e).then(n,r)}.bind(t))}function p(e){return e&&void 0!==e.video?Object.assign({},e,{video:o.compactObject(e.video)}):e}function l(e){if(e.RTCPeerConnection){var t=e.RTCPeerConnection;e.RTCPeerConnection=function(e,n){if(e&&e.iceServers){for(var r=[],i=0;i=n&&parseInt(r[n],10)}function c(e,t,n){if(e.RTCPeerConnection){var r=e.RTCPeerConnection.prototype,i=r.addEventListener;r.addEventListener=function(e,r){if(e!==t)return i.apply(this,arguments);var o=function(e){var t=n(e);t&&(r.handleEvent?r.handleEvent(t):r(t))};return this._eventMap=this._eventMap||{},this._eventMap[t]||(this._eventMap[t]=new Map),this._eventMap[t].set(r,o),i.apply(this,[e,o])};var o=r.removeEventListener;r.removeEventListener=function(e,n){if(e!==t||!this._eventMap||!this._eventMap[t])return o.apply(this,arguments);if(!this._eventMap[t].has(n))return o.apply(this,arguments);var r=this._eventMap[t].get(n);return this._eventMap[t].delete(n),0===this._eventMap[t].size&&delete this._eventMap[t],0===Object.keys(this._eventMap).length&&delete this._eventMap,o.apply(this,[e,r])},Object.defineProperty(r,"on"+t,{get:function(){return this["_on"+t]},set:function(e){this["_on"+t]&&(this.removeEventListener(t,this["_on"+t]),delete this["_on"+t]),e&&this.addEventListener(t,this["_on"+t]=e)},enumerable:!0,configurable:!0})}}function u(e){return"boolean"!==typeof e?new Error("Argument type: "+("undefined"===typeof e?"undefined":r(e))+". Please use a boolean."):(o=e,e?"adapter.js logging disabled":"adapter.js logging enabled")}function f(e){return"boolean"!==typeof e?new Error("Argument type: "+("undefined"===typeof e?"undefined":r(e))+". Please use a boolean."):(!e,"adapter.js deprecation warnings "+(e?"disabled":"enabled"))}function d(){if("object"===("undefined"===typeof window?"undefined":r(window))){if(o)return;"undefined"!==typeof console&&console.log}}function p(e,t){}function l(e){var t={browser:null,version:null};if("undefined"===typeof e||!e.navigator)return t.browser="Not a browser.",t;var n=e.navigator;if(n.mozGetUserMedia)t.browser="firefox",t.version=a(n.userAgent,/Firefox\/(\d+)\./,1);else if(n.webkitGetUserMedia||!1===e.isSecureContext&&e.webkitRTCPeerConnection&&!e.RTCIceGatherer)t.browser="chrome",t.version=a(n.userAgent,/Chrom(e|ium)\/(\d+)\./,2);else{if(!e.RTCPeerConnection||!n.userAgent.match(/AppleWebKit\/(\d+)\./))return t.browser="Not a supported browser.",t;t.browser="safari",t.version=a(n.userAgent,/AppleWebKit\/(\d+)\./,1),t.supportsUnifiedPlan=e.RTCRtpTransceiver&&"currentDirection"in e.RTCRtpTransceiver.prototype}return t}function h(e){return"[object Object]"===Object.prototype.toString.call(e)}function m(e){return h(e)?Object.keys(e).reduce((function(t,n){var r=h(e[n]),o=r?m(e[n]):e[n],a=r&&!Object.keys(o).length;return void 0===o||a?t:Object.assign(t,i({},n,o))}),{}):e}function g(e,t,n){t&&!n.has(t.id)&&(n.set(t.id,t),Object.keys(t).forEach((function(r){r.endsWith("Id")?g(e,e.get(t[r]),n):r.endsWith("Ids")&&t[r].forEach((function(t){g(e,e.get(t),n)}))})))}function y(e,t,n){var r=n?"outbound-rtp":"inbound-rtp",i=new Map;if(null===t)return i;var o=[];return e.forEach((function(e){"track"===e.type&&e.trackIdentifier===t.id&&o.push(e)})),o.forEach((function(t){e.forEach((function(n){n.type===r&&n.trackId===t.id&&g(e,n,i)}))})),i}},{}],12:[function(e,t,n){"use strict";var r="function"===typeof Symbol&&"symbol"===s(Symbol.iterator)?function(e){return s(e)}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":s(e)},i={generateIdentifier:function(){return Math.random().toString(36).substr(2,10)}};i.localCName=i.generateIdentifier(),i.splitLines=function(e){return e.trim().split("\n").map((function(e){return e.trim()}))},i.splitSections=function(e){var t=e.split("\nm=");return t.map((function(e,t){return(t>0?"m="+e:e).trim()+"\r\n"}))},i.getDescription=function(e){var t=i.splitSections(e);return t&&t[0]},i.getMediaSections=function(e){var t=i.splitSections(e);return t.shift(),t},i.matchPrefix=function(e,t){return i.splitLines(e).filter((function(e){return 0===e.indexOf(t)}))},i.parseCandidate=function(e){var t=void 0;t=0===e.indexOf("a=candidate:")?e.substring(12).split(" "):e.substring(10).split(" ");for(var n={foundation:t[0],component:{1:"rtp",2:"rtcp"}[t[1]]||t[1],protocol:t[2].toLowerCase(),priority:parseInt(t[3],10),ip:t[4],address:t[4],port:parseInt(t[5],10),type:t[7]},r=8;r0?t[0].split("/")[1]:"sendrecv",uri:t[1]}},i.writeExtmap=function(e){return"a=extmap:"+(e.id||e.preferredId)+(e.direction&&"sendrecv"!==e.direction?"/"+e.direction:"")+" "+e.uri+"\r\n"},i.parseFmtp=function(e){for(var t={},n=void 0,r=e.substr(e.indexOf(" ")+1).split(";"),i=0;i-1?(n.attribute=e.substr(t+1,r-t-1),n.value=e.substr(r+1)):n.attribute=e.substr(t+1),n},i.parseSsrcGroup=function(e){var t=e.substr(13).split(" ");return{semantics:t.shift(),ssrcs:t.map((function(e){return parseInt(e,10)}))}},i.getMid=function(e){var t=i.matchPrefix(e,"a=mid:")[0];if(t)return t.substr(6)},i.parseFingerprint=function(e){var t=e.substr(14).split(" ");return{algorithm:t[0].toLowerCase(),value:t[1].toUpperCase()}},i.getDtlsParameters=function(e,t){var n=i.matchPrefix(e+t,"a=fingerprint:");return{role:"auto",fingerprints:n.map(i.parseFingerprint)}},i.writeDtlsParameters=function(e,t){var n="a=setup:"+t+"\r\n";return e.fingerprints.forEach((function(e){n+="a=fingerprint:"+e.algorithm+" "+e.value+"\r\n"})),n},i.parseCryptoLine=function(e){var t=e.substr(9).split(" ");return{tag:parseInt(t[0],10),cryptoSuite:t[1],keyParams:t[2],sessionParams:t.slice(3)}},i.writeCryptoLine=function(e){return"a=crypto:"+e.tag+" "+e.cryptoSuite+" "+("object"===r(e.keyParams)?i.writeCryptoKeyParams(e.keyParams):e.keyParams)+(e.sessionParams?" "+e.sessionParams.join(" "):"")+"\r\n"},i.parseCryptoKeyParams=function(e){if(0!==e.indexOf("inline:"))return null;var t=e.substr(7).split("|");return{keyMethod:"inline",keySalt:t[0],lifeTime:t[1],mkiValue:t[2]?t[2].split(":")[0]:void 0,mkiLength:t[2]?t[2].split(":")[1]:void 0}},i.writeCryptoKeyParams=function(e){return e.keyMethod+":"+e.keySalt+(e.lifeTime?"|"+e.lifeTime:"")+(e.mkiValue&&e.mkiLength?"|"+e.mkiValue+":"+e.mkiLength:"")},i.getCryptoParameters=function(e,t){var n=i.matchPrefix(e+t,"a=crypto:");return n.map(i.parseCryptoLine)},i.getIceParameters=function(e,t){var n=i.matchPrefix(e+t,"a=ice-ufrag:")[0],r=i.matchPrefix(e+t,"a=ice-pwd:")[0];return n&&r?{usernameFragment:n.substr(12),password:r.substr(10)}:null},i.writeIceParameters=function(e){var t="a=ice-ufrag:"+e.usernameFragment+"\r\na=ice-pwd:"+e.password+"\r\n";return e.iceLite&&(t+="a=ice-lite\r\n"),t},i.parseRtpParameters=function(e){for(var t={codecs:[],headerExtensions:[],fecMechanisms:[],rtcp:[]},n=i.splitLines(e),r=n[0].split(" "),o=3;o0?"9":"0",n+=" UDP/TLS/RTP/SAVPF ",n+=t.codecs.map((function(e){return void 0!==e.preferredPayloadType?e.preferredPayloadType:e.payloadType})).join(" ")+"\r\n",n+="c=IN IP4 0.0.0.0\r\n",n+="a=rtcp:9 IN IP4 0.0.0.0\r\n",t.codecs.forEach((function(e){n+=i.writeRtpMap(e),n+=i.writeFmtp(e),n+=i.writeRtcpFb(e)}));var r=0;return t.codecs.forEach((function(e){e.maxptime>r&&(r=e.maxptime)})),r>0&&(n+="a=maxptime:"+r+"\r\n"),t.headerExtensions&&t.headerExtensions.forEach((function(e){n+=i.writeExtmap(e)})),n},i.parseRtpEncodingParameters=function(e){var t=[],n=i.parseRtpParameters(e),r=-1!==n.fecMechanisms.indexOf("RED"),o=-1!==n.fecMechanisms.indexOf("ULPFEC"),a=i.matchPrefix(e,"a=ssrc:").map((function(e){return i.parseSsrcMedia(e)})).filter((function(e){return"cname"===e.attribute})),s=a.length>0&&a[0].ssrc,c=void 0,u=i.matchPrefix(e,"a=ssrc-group:FID").map((function(e){var t=e.substr(17).split(" ");return t.map((function(e){return parseInt(e,10)}))}));u.length>0&&u[0].length>1&&u[0][0]===s&&(c=u[0][1]),n.codecs.forEach((function(e){if("RTX"===e.name.toUpperCase()&&e.parameters.apt){var n={ssrc:s,codecPayloadType:parseInt(e.parameters.apt,10)};s&&c&&(n.rtx={ssrc:c}),t.push(n),r&&(n=JSON.parse(JSON.stringify(n)),n.fec={ssrc:s,mechanism:o?"red+ulpfec":"red"},t.push(n))}})),0===t.length&&s&&t.push({ssrc:s});var f=i.matchPrefix(e,"b=");return f.length&&(f=0===f[0].indexOf("b=TIAS:")?parseInt(f[0].substr(7),10):0===f[0].indexOf("b=AS:")?1e3*parseInt(f[0].substr(5),10)*.95-16e3:void 0,t.forEach((function(e){e.maxBitrate=f}))),t},i.parseRtcpParameters=function(e){var t={},n=i.matchPrefix(e,"a=ssrc:").map((function(e){return i.parseSsrcMedia(e)})).filter((function(e){return"cname"===e.attribute}))[0];n&&(t.cname=n.value,t.ssrc=n.ssrc);var r=i.matchPrefix(e,"a=rtcp-rsize");t.reducedSize=r.length>0,t.compound=0===r.length;var o=i.matchPrefix(e,"a=rtcp-mux");return t.mux=o.length>0,t},i.writeRtcpParameters=function(e){var t="";return e.reducedSize&&(t+="a=rtcp-rsize\r\n"),e.mux&&(t+="a=rtcp-mux\r\n"),void 0!==e.ssrc&&e.cname&&(t+="a=ssrc:"+e.ssrc+" cname:"+e.cname+"\r\n"),t},i.parseMsid=function(e){var t=void 0,n=i.matchPrefix(e,"a=msid:");if(1===n.length)return t=n[0].substr(7).split(" "),{stream:t[0],track:t[1]};var r=i.matchPrefix(e,"a=ssrc:").map((function(e){return i.parseSsrcMedia(e)})).filter((function(e){return"msid"===e.attribute}));return r.length>0?(t=r[0].value.split(" "),{stream:t[0],track:t[1]}):void 0},i.parseSctpDescription=function(e){var t=i.parseMLine(e),n=i.matchPrefix(e,"a=max-message-size:"),r=void 0;n.length>0&&(r=parseInt(n[0].substr(19),10)),isNaN(r)&&(r=65536);var o=i.matchPrefix(e,"a=sctp-port:");if(o.length>0)return{port:parseInt(o[0].substr(12),10),protocol:t.fmt,maxMessageSize:r};var a=i.matchPrefix(e,"a=sctpmap:");if(a.length>0){var s=a[0].substr(10).split(" ");return{port:parseInt(s[0],10),protocol:s[1],maxMessageSize:r}}},i.writeSctpDescription=function(e,t){var n=[];return n="DTLS/SCTP"!==e.protocol?["m="+e.kind+" 9 "+e.protocol+" "+t.protocol+"\r\n","c=IN IP4 0.0.0.0\r\n","a=sctp-port:"+t.port+"\r\n"]:["m="+e.kind+" 9 "+e.protocol+" "+t.port+"\r\n","c=IN IP4 0.0.0.0\r\n","a=sctpmap:"+t.port+" "+t.protocol+" 65535\r\n"],void 0!==t.maxMessageSize&&n.push("a=max-message-size:"+t.maxMessageSize+"\r\n"),n.join("")},i.generateSessionId=function(){return Math.random().toString().substr(2,21)},i.writeSessionBoilerplate=function(e,t,n){var r=void 0,o=void 0!==t?t:2;r=e||i.generateSessionId();var a=n||"thisisadapterortc";return"v=0\r\no="+a+" "+r+" "+o+" IN IP4 127.0.0.1\r\ns=-\r\nt=0 0\r\n"},i.getDirection=function(e,t){for(var n=i.splitLines(e),r=0;r1?arguments[1]:void 0,(function(e,t){return new(s(o(e,e.constructor)))(t)}))}))},"408a":function(e,t,n){var r=n("c6b6");e.exports=function(e){if("number"!=typeof e&&"Number"!=r(e))throw TypeError("Incorrect invocation");return+e}},"40de":function(e,t){var n=[].slice;e.exports=function(e,t){if("string"==typeof t&&(t=e[t]),"function"!=typeof t)throw new Error("bind() requires a function");var r=n.call(arguments,2);return function(){return t.apply(e,r.concat(n.call(arguments)))}}},4362:function(e,t,n){t.nextTick=function(e){var t=Array.prototype.slice.call(arguments);t.shift(),setTimeout((function(){e.apply(null,t)}),0)},t.platform=t.arch=t.execPath=t.title="browser",t.pid=1,t.browser=!0,t.env={},t.argv=[],t.binding=function(e){throw new Error("No such module. (Possibly not yet loaded)")},function(){var e,r="/";t.cwd=function(){return r},t.chdir=function(t){e||(e=n("df7c")),r=e.resolve(t,r)}}(),t.exit=t.kill=t.umask=t.dlopen=t.uptime=t.memoryUsage=t.uvCounters=function(){},t.features={}},"43cd":function(e,t,n){function r(e){var n,r=0;for(n in e)r=(r<<5)-r+e.charCodeAt(n),r|=0;return t.colors[Math.abs(r)%t.colors.length]}function i(e){var n;function i(){if(i.enabled){var e=i,r=+new Date,o=r-(n||r);e.diff=o,e.prev=n,e.curr=r,n=r;for(var a=new Array(arguments.length),s=0;s-1,n&&(t=t.replace(/y/g,"")));var s=a(A?new v(e,t):v(e,t),r?this:b,T);return S&&n&&h(s,{sticky:n}),s},R=function(e){e in T||s(T,e,{configurable:!0,get:function(){return v[e]},set:function(t){v[e]=t}})},k=c(v),x=0;while(k.length>x)R(k[x++]);b.constructor=T,T.prototype=b,p(i,"RegExp",T)}m("RegExp")},"4ec9":function(e,t,n){"use strict";var r=n("6d61"),i=n("6566");e.exports=r("Map",(function(e){return function(){return e(this,arguments.length?arguments[0]:void 0)}}),i)},"4f2a":function(e,t){t.encode=function(e){var t="";for(var n in e)e.hasOwnProperty(n)&&(t.length&&(t+="&"),t+=encodeURIComponent(n)+"="+encodeURIComponent(e[n]));return t},t.decode=function(e){for(var t={},n=e.split("&"),r=0,i=n.length;r]*>)/g,m=/\$([$&'`]|\d\d?)/g,g=function(e){return void 0===e?e:String(e)};r("replace",2,(function(e,t,n,r){var y=r.REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE,v=r.REPLACE_KEEPS_$0,b=y?"$":"$0";return[function(n,r){var i=c(this),o=void 0==n?void 0:n[e];return void 0!==o?o.call(n,i,r):t.call(String(i),n,r)},function(e,r){if(!y&&v||"string"===typeof r&&-1===r.indexOf(b)){var o=n(t,e,this,r);if(o.done)return o.value}var c=i(e),l=String(this),h="function"===typeof r;h||(r=String(r));var m=c.global;if(m){var C=c.unicode;c.lastIndex=0}var A=[];while(1){var S=f(c,l);if(null===S)break;if(A.push(S),!m)break;var E=String(S[0]);""===E&&(c.lastIndex=u(l,a(c.lastIndex),C))}for(var T="",R=0,k=0;k=R&&(T+=l.slice(R,P)+I,R=P+x.length)}return T+l.slice(R)}];function w(e,n,r,i,a,s){var c=r+e.length,u=i.length,f=m;return void 0!==a&&(a=o(a),f=h),t.call(s,f,(function(t,o){var s;switch(o.charAt(0)){case"$":return"$";case"&":return e;case"`":return n.slice(0,r);case"'":return n.slice(c);case"<":s=a[o.slice(1,-1)];break;default:var f=+o;if(0===f)return t;if(f>u){var d=l(f/10);return 0===d?t:d<=u?void 0===i[d-1]?o.charAt(1):i[d-1]+o.charAt(1):t}s=i[f-1]}return void 0===s?"":s}))}}))},"568d":function(e,t,n){var r=n("e4cd")("socket.io-parser"),i=n("7297"),o=n("703e"),a=n("a23b"),s=n("f922");function c(){}t.protocol=4,t.types=["CONNECT","DISCONNECT","EVENT","ACK","ERROR","BINARY_EVENT","BINARY_ACK"],t.CONNECT=0,t.DISCONNECT=1,t.EVENT=2,t.ACK=3,t.ERROR=4,t.BINARY_EVENT=5,t.BINARY_ACK=6,t.Encoder=c,t.Decoder=l;var u=t.ERROR+'"encode error"';function f(e){var n=""+e.type;if(t.BINARY_EVENT!==e.type&&t.BINARY_ACK!==e.type||(n+=e.attachments+"-"),e.nsp&&"/"!==e.nsp&&(n+=e.nsp+","),null!=e.id&&(n+=e.id),null!=e.data){var i=d(e.data);if(!1===i)return u;n+=i}return r("encoded %j as %s",e,n),n}function d(e){try{return JSON.stringify(e)}catch(t){return!1}}function p(e,t){function n(e){var n=o.deconstructPacket(e),r=f(n.packet),i=n.buffers;i.unshift(r),t(i)}o.removeBlobs(e,n)}function l(){this.reconstructor=null}function h(e){var n=0,i={type:Number(e.charAt(0))};if(null==t.types[i.type])return y("unknown packet type "+i.type);if(t.BINARY_EVENT===i.type||t.BINARY_ACK===i.type){var o=n+1;while("-"!==e.charAt(++n)&&n!=e.length);var s=e.substring(o,n);if(s!=Number(s)||"-"!==e.charAt(n))throw new Error("Illegal attachments");i.attachments=Number(s)}if("/"===e.charAt(n+1)){o=n+1;while(++n){var c=e.charAt(n);if(","===c)break;if(n===e.length)break}i.nsp=e.substring(o,n)}else i.nsp="/";var u=e.charAt(n+1);if(""!==u&&Number(u)==u){o=n+1;while(++n){c=e.charAt(n);if(null==c||Number(c)!=c){--n;break}if(n===e.length)break}i.id=Number(e.substring(o,n+1))}if(e.charAt(++n)){var f=m(e.substr(n)),d=!1!==f&&(i.type===t.ERROR||a(f));if(!d)return y("invalid payload");i.data=f}return r("decoded %s as %j",e,i),i}function m(e){try{return JSON.parse(e)}catch(t){return!1}}function g(e){this.reconPack=e,this.buffers=[]}function y(e){return{type:t.ERROR,data:"parser error: "+e}}c.prototype.encode=function(e,n){if(r("encoding packet %j",e),t.BINARY_EVENT===e.type||t.BINARY_ACK===e.type)p(e,n);else{var i=f(e);n([i])}},i(l.prototype),l.prototype.add=function(e){var n;if("string"===typeof e){if(this.reconstructor)throw new Error("got plaintext data when reconstructing a packet");n=h(e),t.BINARY_EVENT===n.type||t.BINARY_ACK===n.type?(this.reconstructor=new g(n),0===this.reconstructor.reconPack.attachments&&this.emit("decoded",n)):this.emit("decoded",n)}else{if(!s(e)&&!e.base64)throw new Error("Unknown type: "+e);if(!this.reconstructor)throw new Error("got binary data when not reconstructing a packet");n=this.reconstructor.takeBinaryData(e),n&&(this.reconstructor=null,this.emit("decoded",n))}},l.prototype.destroy=function(){this.reconstructor&&this.reconstructor.finishedReconstruction()},g.prototype.takeBinaryData=function(e){if(this.buffers.push(e),this.buffers.length===this.reconPack.attachments){var t=o.reconstructPacket(this.reconPack,this.buffers);return this.finishedReconstruction(),t}return null},g.prototype.finishedReconstruction=function(){this.reconPack=null,this.buffers=[]}},"58b1":function(e,t,n){(function(t){var r=n("e82e"),i=Object.prototype.toString,o="function"===typeof Blob||"undefined"!==typeof Blob&&"[object BlobConstructor]"===i.call(Blob),a="function"===typeof File||"undefined"!==typeof File&&"[object FileConstructor]"===i.call(File);function s(e){if(!e||"object"!==typeof e)return!1;if(r(e)){for(var n=0,i=e.length;n100)){var t=/^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec(e);if(t){var s=parseFloat(t[1]),c=(t[2]||"ms").toLowerCase();switch(c){case"years":case"year":case"yrs":case"yr":case"y":return s*a;case"days":case"day":case"d":return s*o;case"hours":case"hour":case"hrs":case"hr":case"h":return s*i;case"minutes":case"minute":case"mins":case"min":case"m":return s*r;case"seconds":case"second":case"secs":case"sec":case"s":return s*n;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return s;default:return}}}}function c(e){return e>=o?Math.round(e/o)+"d":e>=i?Math.round(e/i)+"h":e>=r?Math.round(e/r)+"m":e>=n?Math.round(e/n)+"s":e+"ms"}function u(e){return f(e,o,"day")||f(e,i,"hour")||f(e,r,"minute")||f(e,n,"second")||e+" ms"}function f(e,t,n){if(!(e0)return s(e);if("number"===n&&!1===isNaN(e))return t.long?u(e):c(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},"5a43":function(e,t){function n(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n1?{type:l[i],data:e.substring(1)}:{type:l[i]}:h}var o=new Uint8Array(e),s=(i=o[0],a(e,1));return m&&"blob"===n&&(s=new m([s])),{type:l[i],data:s}},t.decodeBase64Packet=function(e,t){var n=l[e.charAt(0)];if(!r)return{type:n,data:{base64:!0,data:e.substr(1)}};var i=r.decode(e.substr(1));return"blob"===t&&m&&(i=new m([i])),{type:n,data:i}},t.encodePayload=function(e,n,r){"function"===typeof n&&(r=n,n=null);var i=o(e);if(n&&i)return m&&!d?t.encodePayloadAsBlob(e,r):t.encodePayloadAsArrayBuffer(e,r);if(!e.length)return r("0:");function a(e){return e.length+":"+e}function s(e,r){t.encodePacket(e,!!i&&n,!1,(function(e){r(null,a(e))}))}C(e,s,(function(e,t){return r(t.join(""))}))},t.decodePayload=function(e,n,r){if("string"!==typeof e)return t.decodePayloadAsBinary(e,n,r);var i;if("function"===typeof n&&(r=n,n=null),""===e)return r(h,0,1);for(var o,a,s="",c=0,u=e.length;c0){for(var s=new Uint8Array(i),c=0===s[0],u="",f=1;;f++){if(255===s[f])break;if(u.length>310)return r(h,0,1);u+=s[f]}i=a(i,2+u.length),u=parseInt(u);var d=a(i,0,u);if(c)try{d=String.fromCharCode.apply(null,new Uint8Array(d))}catch(m){var p=new Uint8Array(d);d="";for(f=0;f=55296&&i<=56319&&n>1,e+=g(e/t);e>m*a>>1;r+=i)e=g(e/m);return g(r+(m+1)*e/(e+s))},C=function(e){var t=[];e=v(e);var n,s,c=e.length,p=f,l=0,m=u;for(n=0;n=p&&sg((r-l)/E))throw RangeError(h);for(l+=(S-p)*E,p=S,n=0;nr)throw RangeError(h);if(s==p){for(var T=l,R=i;;R+=i){var k=R<=m?o:R>=m+a?a:R-m;if(T1&&void 0!==arguments[1]?arguments[1]:{};t.name=t.name||e._componentTag||e.name;var n=e.prototype;Object.getOwnPropertyNames(n).forEach((function(e){if("constructor"!==e)if(v.indexOf(e)>-1)t[e]=n[e];else{var r=Object.getOwnPropertyDescriptor(n,e);void 0!==r.value?"function"===typeof r.value?(t.methods||(t.methods={}))[e]=r.value:(t.mixins||(t.mixins=[])).push({data:function(){return o({},e,r.value)}}):(r.get||r.set)&&((t.computed||(t.computed={}))[e]={get:r.get,set:r.set})}})),(t.mixins||(t.mixins=[])).push({data:function(){return y(this,e)}});var i=e.__decorators__;i&&(i.forEach((function(e){return e(t)})),delete e.__decorators__);var a=Object.getPrototypeOf(e.prototype),s=a instanceof r["default"]?a.constructor:r["default"],c=s.extend(t);return C(c,e,s),f()&&d(c,e),c}var w={prototype:!0,arguments:!0,callee:!0,caller:!0};function C(e,t,n){Object.getOwnPropertyNames(t).forEach((function(r){if(!w[r]){var i=Object.getOwnPropertyDescriptor(e,r);if(!i||i.configurable){var o=Object.getOwnPropertyDescriptor(t,r);if(!h){if("cid"===r)return;var a=Object.getOwnPropertyDescriptor(n,r);if(!g(o.value)&&a&&a.value===o.value)return}0,Object.defineProperty(e,r,o)}}}))}function A(e){return"function"===typeof e?b(e):function(t){return b(t,e)}}A.registerHooks=function(e){v.push.apply(v,a(e))};var S=A;var E="undefined"!==typeof Reflect&&"undefined"!==typeof Reflect.getMetadata;function T(e,t,n){if(E&&!Array.isArray(e)&&"function"!==typeof e&&"undefined"===typeof e.type){var r=Reflect.getMetadata("design:type",t,n);r!==Object&&(e.type=r)}}function R(e){return void 0===e&&(e={}),function(t,n){T(e,t,n),m((function(t,n){(t.props||(t.props={}))[n]=e}))(t,n)}}function k(e,t){void 0===t&&(t={});var n=t.deep,r=void 0!==n&&n,i=t.immediate,o=void 0!==i&&i;return m((function(t,n){"object"!==typeof t.watch&&(t.watch=Object.create(null));var i=t.watch;"object"!==typeof i[e]||Array.isArray(i[e])?"undefined"===typeof i[e]&&(i[e]=[]):i[e]=[i[e]],i[e].push({handler:n,deep:r,immediate:o})}))}var x=/\B([A-Z])/g,P=function(e){return e.replace(x,"-$1").toLowerCase()};function B(e){return function(t,n,r){var i=P(n),o=r.value;r.value=function(){for(var t=this,n=[],r=0;r>8&255]},j=function(e){return[255&e,e>>8&255,e>>16&255,e>>24&255]},_=function(e){return e[3]<<24|e[2]<<16|e[1]<<8|e[0]},N=function(e){return I(e,23,4)},H=function(e){return I(e,52,8)},Q=function(e,t){y(e[T],t,{get:function(){return C(this)[t]}})},q=function(e,t,n,r){var i=p(n),o=C(e);if(i+t>o.byteLength)throw M(k);var a=C(o.buffer).bytes,s=i+o.byteOffset,c=a.slice(s,s+t);return r?c:c.reverse()},W=function(e,t,n,r,i,o){var a=p(n),s=C(e);if(a+t>s.byteLength)throw M(k);for(var c=C(s.buffer).bytes,u=a+s.byteOffset,f=r(+i),d=0;dY;)(J=z[Y++])in P||a(P,J,x[J]);X.constructor=P}m&&h(O)!==D&&m(O,D);var G=new B(new P(2)),K=O.setInt8;G.setInt8(0,2147483648),G.setInt8(1,2147483649),!G.getInt8(0)&&G.getInt8(1)||s(O,{setInt8:function(e,t){K.call(this,e,t<<24>>24)},setUint8:function(e,t){K.call(this,e,t<<24>>24)}},{unsafe:!0})}else P=function(e){u(this,P,S);var t=p(e);A(this,{bytes:v.call(new Array(t),0),byteLength:t}),i||(this.byteLength=t)},B=function(e,t,n){u(this,B,E),u(e,P,E);var r=C(e).byteLength,o=f(t);if(o<0||o>r)throw M("Wrong offset");if(n=void 0===n?r-o:d(n),o+n>r)throw M(R);A(this,{buffer:e,byteLength:n,byteOffset:o}),i||(this.buffer=e,this.byteLength=n,this.byteOffset=o)},i&&(Q(P,"byteLength"),Q(B,"buffer"),Q(B,"byteLength"),Q(B,"byteOffset")),s(B[T],{getInt8:function(e){return q(this,1,e)[0]<<24>>24},getUint8:function(e){return q(this,1,e)[0]},getInt16:function(e){var t=q(this,2,e,arguments.length>1?arguments[1]:void 0);return(t[1]<<8|t[0])<<16>>16},getUint16:function(e){var t=q(this,2,e,arguments.length>1?arguments[1]:void 0);return t[1]<<8|t[0]},getInt32:function(e){return _(q(this,4,e,arguments.length>1?arguments[1]:void 0))},getUint32:function(e){return _(q(this,4,e,arguments.length>1?arguments[1]:void 0))>>>0},getFloat32:function(e){return F(q(this,4,e,arguments.length>1?arguments[1]:void 0),23)},getFloat64:function(e){return F(q(this,8,e,arguments.length>1?arguments[1]:void 0),52)},setInt8:function(e,t){W(this,1,e,U,t)},setUint8:function(e,t){W(this,1,e,U,t)},setInt16:function(e,t){W(this,2,e,L,t,arguments.length>2?arguments[2]:void 0)},setUint16:function(e,t){W(this,2,e,L,t,arguments.length>2?arguments[2]:void 0)},setInt32:function(e,t){W(this,4,e,j,t,arguments.length>2?arguments[2]:void 0)},setUint32:function(e,t){W(this,4,e,j,t,arguments.length>2?arguments[2]:void 0)},setFloat32:function(e,t){W(this,4,e,N,t,arguments.length>2?arguments[2]:void 0)},setFloat64:function(e,t){W(this,8,e,H,t,arguments.length>2?arguments[2]:void 0)}});b(P,S),b(B,E),e.exports={ArrayBuffer:P,DataView:B}},"62fa":function(e,t){e.exports=function(e,t){var n=function(){};n.prototype=t.prototype,e.prototype=new n,e.prototype.constructor=e}},6374:function(e,t,n){n("a4d3"),n("e01a"),n("d28b"),n("d3b7"),n("3ca3"),n("ddb0");var r=n("6613");function i(e,t){var n;if("undefined"===typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=r(e))||t&&e&&"number"===typeof e.length){n&&(e=n);var i=0,o=function(){};return{s:o,n:function(){return i>=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,s=!0,c=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return s=e.done,e},e:function(e){c=!0,a=e},f:function(){try{s||null==n["return"]||n["return"]()}finally{if(c)throw a}}}}e.exports=i},"649e":function(e,t,n){"use strict";var r=n("ebb5"),i=n("b727").some,o=r.aTypedArray,a=r.exportTypedArrayMethod;a("some",(function(e){return i(o(this),e,arguments.length>1?arguments[1]:void 0)}))},6566:function(e,t,n){"use strict";var r=n("9bf2").f,i=n("7c73"),o=n("e2cc"),a=n("0366"),s=n("19aa"),c=n("2266"),u=n("7dd0"),f=n("2626"),d=n("83ab"),p=n("f183").fastKey,l=n("69f3"),h=l.set,m=l.getterFor;e.exports={getConstructor:function(e,t,n,u){var f=e((function(e,r){s(e,f,t),h(e,{type:t,index:i(null),first:void 0,last:void 0,size:0}),d||(e.size=0),void 0!=r&&c(r,e[u],e,n)})),l=m(t),g=function(e,t,n){var r,i,o=l(e),a=y(e,t);return a?a.value=n:(o.last=a={index:i=p(t,!0),key:t,value:n,previous:r=o.last,next:void 0,removed:!1},o.first||(o.first=a),r&&(r.next=a),d?o.size++:e.size++,"F"!==i&&(o.index[i]=a)),e},y=function(e,t){var n,r=l(e),i=p(t);if("F"!==i)return r.index[i];for(n=r.first;n;n=n.next)if(n.key==t)return n};return o(f.prototype,{clear:function(){var e=this,t=l(e),n=t.index,r=t.first;while(r)r.removed=!0,r.previous&&(r.previous=r.previous.next=void 0),delete n[r.index],r=r.next;t.first=t.last=void 0,d?t.size=0:e.size=0},delete:function(e){var t=this,n=l(t),r=y(t,e);if(r){var i=r.next,o=r.previous;delete n.index[r.index],r.removed=!0,o&&(o.next=i),i&&(i.previous=o),n.first==r&&(n.first=i),n.last==r&&(n.last=o),d?n.size--:t.size--}return!!r},forEach:function(e){var t,n=l(this),r=a(e,arguments.length>1?arguments[1]:void 0,3);while(t=t?t.next:n.first){r(t.value,t.key,this);while(t&&t.removed)t=t.previous}},has:function(e){return!!y(this,e)}}),o(f.prototype,n?{get:function(e){var t=y(this,e);return t&&t.value},set:function(e,t){return g(this,0===e?0:e,t)}}:{add:function(e){return g(this,e=0===e?0:e,e)}}),d&&r(f.prototype,"size",{get:function(){return l(this).size}}),f},setStrong:function(e,t,n){var r=t+" Iterator",i=m(t),o=m(r);u(e,t,(function(e,t){h(this,{type:r,target:e,state:i(e),kind:t,last:void 0})}),(function(){var e=o(this),t=e.kind,n=e.last;while(n&&n.removed)n=n.previous;return e.target&&(e.last=n=n?n.next:e.state.first)?"keys"==t?{value:n.key,done:!1}:"values"==t?{value:n.value,done:!1}:{value:[n.key,n.value],done:!1}:(e.target=void 0,{value:void 0,done:!0})}),n?"entries":"values",!n,!0),f(t)}}},6613:function(e,t,n){n("a630"),n("fb6a"),n("b0c0"),n("d3b7"),n("25f0"),n("3ca3");var r=n("5a43");function i(e,t){if(e){if("string"===typeof e)return r(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?r(e,t):void 0}}e.exports=i},"6a44":function(e,t,n){var r=n("d63e"),i=n("d33e"),o=n("0a5e"),a=n("0882");function s(e){var t,n=!1,a=!1,s=!1!==e.jsonp;if("undefined"!==typeof location){var c="https:"===location.protocol,u=location.port;u||(u=c?443:80),n=e.hostname!==location.hostname||u!==e.port,a=e.secure!==c}if(e.xdomain=n,e.xscheme=a,t=new r(e),"open"in t&&!e.forceJSONP)return new i(e);if(!s)throw new Error("JSONP disabled");return new o(e)}t.polling=s,t.websocket=a},"6a6f":function(e,t,n){"use strict";n.d(t,"a",(function(){return r})),n.d(t,"c",(function(){return i})),n.d(t,"b",(function(){return o}));var r="http://frps.retailwell.com:20068",i="http://metaplayer.sxkj.com/ws",o="http://metaplayer.sxkj.com"},"6d61":function(e,t,n){"use strict";var r=n("23e7"),i=n("da84"),o=n("94ca"),a=n("6eeb"),s=n("f183"),c=n("2266"),u=n("19aa"),f=n("861d"),d=n("d039"),p=n("1c7e"),l=n("d44e"),h=n("7156");e.exports=function(e,t,n){var m=-1!==e.indexOf("Map"),g=-1!==e.indexOf("Weak"),y=m?"set":"add",v=i[e],b=v&&v.prototype,w=v,C={},A=function(e){var t=b[e];a(b,e,"add"==e?function(e){return t.call(this,0===e?0:e),this}:"delete"==e?function(e){return!(g&&!f(e))&&t.call(this,0===e?0:e)}:"get"==e?function(e){return g&&!f(e)?void 0:t.call(this,0===e?0:e)}:"has"==e?function(e){return!(g&&!f(e))&&t.call(this,0===e?0:e)}:function(e,n){return t.call(this,0===e?0:e,n),this})};if(o(e,"function"!=typeof v||!(g||b.forEach&&!d((function(){(new v).entries().next()})))))w=n.getConstructor(t,e,m,y),s.REQUIRED=!0;else if(o(e,!0)){var S=new w,E=S[y](g?{}:-0,1)!=S,T=d((function(){S.has(1)})),R=p((function(e){new v(e)})),k=!g&&d((function(){var e=new v,t=5;while(t--)e[y](t,t);return!e.has(-0)}));R||(w=t((function(t,n){u(t,w,e);var r=h(new v,t,w);return void 0!=n&&c(n,r[y],r,m),r})),w.prototype=b,b.constructor=w),(T||k)&&(A("delete"),A("has"),m&&A("get")),(k||E)&&A(y),g&&b.clear&&delete b.clear}return C[e]=w,r({global:!0,forced:w!=v},C),l(w,e),g||n.setStrong(w,e,m),w}},7037:function(e,t,n){function r(t){return"function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?e.exports=r=function(e){return typeof e}:e.exports=r=function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r(t)}n("a4d3"),n("e01a"),n("d28b"),n("d3b7"),n("3ca3"),n("ddb0"),e.exports=r},"703e":function(e,t,n){var r=n("a23b"),i=n("f922"),o=Object.prototype.toString,a="function"===typeof Blob||"undefined"!==typeof Blob&&"[object BlobConstructor]"===o.call(Blob),s="function"===typeof File||"undefined"!==typeof File&&"[object FileConstructor]"===o.call(File);function c(e,t){if(!e)return e;if(i(e)){var n={_placeholder:!0,num:t.length};return t.push(e),n}if(r(e)){for(var o=new Array(e.length),a=0;a=0&&e.numn)i[n]=t[n++];return i},X=function(e,t){O(e,t,{get:function(){return P(this)[t]}})},z=function(e){var t;return e instanceof F||"ArrayBuffer"==(t=y(e))||"SharedArrayBuffer"==t},Y=function(e,t){return Q(e)&&"symbol"!=typeof t&&t in e&&String(+t)==String(t)},G=function(e,t){return Y(e,t=m(t,!0))?f(2,e[t]):D(e,t)},K=function(e,t,n){return!(Y(e,t=m(t,!0))&&v(n)&&g(n,"value"))||g(n,"get")||g(n,"set")||n.configurable||g(n,"writable")&&!n.writable||g(n,"enumerable")&&!n.enumerable?O(e,t,n):(e[t]=n.value,e)};o?(L||(R.f=G,T.f=K,X(N,"buffer"),X(N,"byteOffset"),X(N,"byteLength"),X(N,"length")),r({target:"Object",stat:!0,forced:!L},{getOwnPropertyDescriptor:G,defineProperty:K}),e.exports=function(e,t,n){var o=e.match(/\d+$/)[0]/8,s=e+(n?"Clamped":"")+"Array",c="get"+e,f="set"+e,m=i[s],g=m,y=g&&g.prototype,T={},R=function(e,t){var n=P(e);return n.view[c](t*o+n.byteOffset,!0)},k=function(e,t,r){var i=P(e);n&&(r=(r=M(r))<0?0:r>255?255:255&r),i.view[f](t*o+i.byteOffset,r,!0)},D=function(e,t){O(e,t,{get:function(){return R(this,t)},set:function(e){return k(this,t,e)},enumerable:!0})};L?a&&(g=t((function(e,t,n,r){return u(e,g,s),x(function(){return v(t)?z(t)?void 0!==r?new m(t,h(n,o),r):void 0!==n?new m(t,h(n,o)):new m(t):Q(t)?J(g,t):A.call(g,t):new m(l(t))}(),e,g)})),w&&w(g,_),S(C(m),(function(e){e in g||d(g,e,m[e])})),g.prototype=y):(g=t((function(e,t,n,r){u(e,g,s);var i,a,c,f=0,d=0;if(v(t)){if(!z(t))return Q(t)?J(g,t):A.call(g,t);i=t,d=h(n,o);var m=t.byteLength;if(void 0===r){if(m%o)throw I(W);if(a=m-d,a<0)throw I(W)}else if(a=p(r)*o,a+d>m)throw I(W);c=a/o}else c=l(t),a=c*o,i=new F(a);B(e,{buffer:i,byteOffset:d,byteLength:a,length:c,view:new U(i)});while(f>1,g=23===t?i(2,-24)-i(2,-77):0,y=e<0||0===e&&1/e<0?1:0,v=0;for(e=r(e),e!=e||e===n?(f=e!=e?1:0,u=h):(u=o(a(e)/s),e*(d=i(2,-u))<1&&(u--,d*=2),e+=u+m>=1?g/d:g*i(2,1-m),e*d>=2&&(u++,d/=2),u+m>=h?(f=0,u=h):u+m>=1?(f=(e*d-1)*i(2,t),u+=m):(f=e*i(2,m-1)*i(2,t),u=0));t>=8;p[v++]=255&f,f/=256,t-=8);for(u=u<0;p[v++]=255&u,u/=256,l-=8);return p[--v]|=128*y,p},u=function(e,t){var r,o=e.length,a=8*o-t-1,s=(1<>1,u=a-7,f=o-1,d=e[f--],p=127&d;for(d>>=7;u>0;p=256*p+e[f],f--,u-=8);for(r=p&(1<<-u)-1,p>>=-u,u+=t;u>0;r=256*r+e[f],f--,u-=8);if(0===p)p=1-c;else{if(p===s)return r?NaN:d?-n:n;r+=i(2,t),p-=c}return(d?-1:1)*r*i(2,p-t)};e.exports={pack:c,unpack:u}},"78eb":function(e,t,n){var r=n("94ac"),i=n("2851"),o=n("7297"),a=n("568d"),s=n("d838"),c=n("40de"),u=n("c7b0")("socket.io-client:manager"),f=n("ee34"),d=n("0b64"),p=Object.prototype.hasOwnProperty;function l(e,t){if(!(this instanceof l))return new l(e,t);e&&"object"===typeof e&&(t=e,e=void 0),t=t||{},t.path=t.path||"/socket.io",this.nsps={},this.subs=[],this.opts=t,this.reconnection(!1!==t.reconnection),this.reconnectionAttempts(t.reconnectionAttempts||1/0),this.reconnectionDelay(t.reconnectionDelay||1e3),this.reconnectionDelayMax(t.reconnectionDelayMax||5e3),this.randomizationFactor(t.randomizationFactor||.5),this.backoff=new d({min:this.reconnectionDelay(),max:this.reconnectionDelayMax(),jitter:this.randomizationFactor()}),this.timeout(null==t.timeout?2e4:t.timeout),this.readyState="closed",this.uri=e,this.connecting=[],this.lastPing=null,this.encoding=!1,this.packetBuffer=[];var n=t.parser||a;this.encoder=new n.Encoder,this.decoder=new n.Decoder,this.autoConnect=!1!==t.autoConnect,this.autoConnect&&this.open()}e.exports=l,l.prototype.emitAll=function(){for(var e in this.emit.apply(this,arguments),this.nsps)p.call(this.nsps,e)&&this.nsps[e].emit.apply(this.nsps[e],arguments)},l.prototype.updateSocketIds=function(){for(var e in this.nsps)p.call(this.nsps,e)&&(this.nsps[e].id=this.generateId(e))},l.prototype.generateId=function(e){return("/"===e?"":e+"#")+this.engine.id},o(l.prototype),l.prototype.reconnection=function(e){return arguments.length?(this._reconnection=!!e,this):this._reconnection},l.prototype.reconnectionAttempts=function(e){return arguments.length?(this._reconnectionAttempts=e,this):this._reconnectionAttempts},l.prototype.reconnectionDelay=function(e){return arguments.length?(this._reconnectionDelay=e,this.backoff&&this.backoff.setMin(e),this):this._reconnectionDelay},l.prototype.randomizationFactor=function(e){return arguments.length?(this._randomizationFactor=e,this.backoff&&this.backoff.setJitter(e),this):this._randomizationFactor},l.prototype.reconnectionDelayMax=function(e){return arguments.length?(this._reconnectionDelayMax=e,this.backoff&&this.backoff.setMax(e),this):this._reconnectionDelayMax},l.prototype.timeout=function(e){return arguments.length?(this._timeout=e,this):this._timeout},l.prototype.maybeReconnectOnOpen=function(){!this.reconnecting&&this._reconnection&&0===this.backoff.attempts&&this.reconnect()},l.prototype.open=l.prototype.connect=function(e,t){if(u("readyState %s",this.readyState),~this.readyState.indexOf("open"))return this;u("opening %s",this.uri),this.engine=r(this.uri,this.opts);var n=this.engine,i=this;this.readyState="opening",this.skipReconnect=!1;var o=s(n,"open",(function(){i.onopen(),e&&e()})),a=s(n,"error",(function(t){if(u("connect_error"),i.cleanup(),i.readyState="closed",i.emitAll("connect_error",t),e){var n=new Error("Connection error");n.data=t,e(n)}else i.maybeReconnectOnOpen()}));if(!1!==this._timeout){var c=this._timeout;u("connect attempt will timeout after %d",c),0===c&&o.destroy();var f=setTimeout((function(){u("connect attempt timed out after %d",c),o.destroy(),n.close(),n.emit("error","timeout"),i.emitAll("connect_timeout",c)}),c);this.subs.push({destroy:function(){clearTimeout(f)}})}return this.subs.push(o),this.subs.push(a),this},l.prototype.onopen=function(){u("open"),this.cleanup(),this.readyState="open",this.emit("open");var e=this.engine;this.subs.push(s(e,"data",c(this,"ondata"))),this.subs.push(s(e,"ping",c(this,"onping"))),this.subs.push(s(e,"pong",c(this,"onpong"))),this.subs.push(s(e,"error",c(this,"onerror"))),this.subs.push(s(e,"close",c(this,"onclose"))),this.subs.push(s(this.decoder,"decoded",c(this,"ondecoded")))},l.prototype.onping=function(){this.lastPing=new Date,this.emitAll("ping")},l.prototype.onpong=function(){this.emitAll("pong",new Date-this.lastPing)},l.prototype.ondata=function(e){this.decoder.add(e)},l.prototype.ondecoded=function(e){this.emit("packet",e)},l.prototype.onerror=function(e){u("error",e),this.emitAll("error",e)},l.prototype.socket=function(e,t){var n=this.nsps[e];if(!n){n=new i(this,e,t),this.nsps[e]=n;var r=this;n.on("connecting",o),n.on("connect",(function(){n.id=r.generateId(e)})),this.autoConnect&&o()}function o(){~f(r.connecting,n)||r.connecting.push(n)}return n},l.prototype.destroy=function(e){var t=f(this.connecting,e);~t&&this.connecting.splice(t,1),this.connecting.length||this.close()},l.prototype.packet=function(e){u("writing packet %j",e);var t=this;e.query&&0===e.type&&(e.nsp+="?"+e.query),t.encoding?t.packetBuffer.push(e):(t.encoding=!0,this.encoder.encode(e,(function(n){for(var r=0;r0&&!this.encoding){var e=this.packetBuffer.shift();this.packet(e)}},l.prototype.cleanup=function(){u("cleanup");for(var e=this.subs.length,t=0;t=this._reconnectionAttempts)u("reconnect failed"),this.backoff.reset(),this.emitAll("reconnect_failed"),this.reconnecting=!1;else{var t=this.backoff.duration();u("will wait %dms before reconnect attempt",t),this.reconnecting=!0;var n=setTimeout((function(){e.skipReconnect||(u("attempting reconnect"),e.emitAll("reconnect_attempt",e.backoff.attempts),e.emitAll("reconnecting",e.backoff.attempts),e.skipReconnect||e.open((function(t){t?(u("reconnect attempt error"),e.reconnecting=!1,e.reconnect(),e.emitAll("reconnect_error",t.data)):(u("reconnect success"),e.onreconnect())})))}),t);this.subs.push({destroy:function(){clearTimeout(n)}})}},l.prototype.onreconnect=function(){var e=this.backoff.attempts;this.reconnecting=!1,this.backoff.reset(),this.updateSocketIds(),this.emitAll("reconnect",e)}},"7a77":function(e,t,n){"use strict";function r(e){this.message=e}r.prototype.toString=function(){return"Cancel"+(this.message?": "+this.message:"")},r.prototype.__CANCEL__=!0,e.exports=r},"7aac":function(e,t,n){"use strict";var r=n("c532");e.exports=r.isStandardBrowserEnv()?function(){return{write:function(e,t,n,i,o,a){var s=[];s.push(e+"="+encodeURIComponent(t)),r.isNumber(n)&&s.push("expires="+new Date(n).toGMTString()),r.isString(i)&&s.push("path="+i),r.isString(o)&&s.push("domain="+o),!0===a&&s.push("secure"),document.cookie=s.join("; ")},read:function(e){var t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove:function(e){this.write(e,"",Date.now()-864e5)}}}():function(){return{write:function(){},read:function(){return null},remove:function(){}}}()},"7d97":function(e,t,n){"use strict";n.r(t);var r=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"about"},[e._m(0),n("div",{staticClass:"soundRecording"},[n("el-button",{attrs:{type:"primary"},on:{click:e.voiceInput}},[e._v(e._s(e.userRecording))]),n("el-button",{attrs:{type:"info"},on:{click:e.userInput}},[e._v("手动输入")])],1),e.soundRecording?n("div",{staticClass:"userInput"},[n("div",[n("el-input",{attrs:{id:"myInput",placeholder:"请输入内容"},on:{blur:e.blurInput,focus:e.focusInput},nativeOn:{keyup:[function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"enter",13,t.key,"Enter")?null:e.confirmEditCommand(e.inputTxt)},function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"esc",27,t.key,["Esc","Escape"])?null:function(){e.inputTxt=""}()}]},model:{value:e.inputTxt,callback:function(t){e.inputTxt=t},expression:"inputTxt"}})],1)]):e._e(),n("div",{staticClass:"playerFilx"},[n("div",{staticClass:"player"},[n("Player",{attrs:{"ue-url":e.liveUrl,"creat-scene-obj":e.creatSceneObj}})],1)])])},i=[function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"header"},[n("h1",{staticClass:"title"},[e._v("ChatBot")])])}],o=(n("99af"),n("96cf"),n("1da1")),a=n("d4ec"),s=n("bee2"),c=n("262e"),u=n("2caf"),f=n("9ab4"),d=n("60a3"),p=n("9d0b"),l=n("3525"),h=n("da43"),m=n.n(h),g=n("8055"),y=n.n(g),v=n("7626"),b=n("e11d"),w=function(e){Object(c["a"])(n,e);var t=Object(u["a"])(n);function n(){var e;return Object(a["a"])(this,n),e=t.apply(this,arguments),e.creatSceneObj={},e.soundRecording=!0,e.userRecording="语音输入",e.liveUrl=l["a"],e.url="",e.inputTxt="",e.watchSpace=!1,e.recorder=new m.a({sampleBits:16,sampleRate:16e3,numChannels:1}),e}return Object(s["a"])(n,[{key:"mounted",value:function(){this.socket=y()("ws://192.168.199.249:8989?user_id=2",{transports:["websocket","polling"],reconnectionDelayMax:3e4}),this.socketEvt(),this.addSpaceEvt()}},{key:"getIntoVideo",value:function(){}},{key:"blurInput",value:function(){this.addSpaceEvt()}},{key:"focusInput",value:function(){this.removeSpaceEvt()}},{key:"voiceInput",value:function(){this.soundRecording=!1}},{key:"userInput",value:function(){this.soundRecording=!0}},{key:"addSpaceEvt",value:function(){var e=this;document.addEventListener("keydown",(function(t){"Space"!==t.code||e.watchSpace||(e.beginRecorder(),e.watchSpace=!0)})),document.addEventListener("keyup",(function(t){"Space"===t.code&&(e.stopRecorder(),e.watchSpace=!1)}))}},{key:"removeSpaceEvt",value:function(){document.removeEventListener("keydown",(function(){})),document.removeEventListener("keyup",(function(){}))}},{key:"socketEvt",value:function(){var e=this;this.socket.on("t2v_response",(function(e){var t={Action:"voice_url",Url:e.voice_uri};Object(b["e"])(t)})),this.socket.on("chat_response",(function(t){e.socket.emit("t2v",{text:t.latest_conversation})}))}},{key:"confirmEditCommand",value:function(e){this.socket.emit("chat",{conversation_id:1,new_conversation:e,full_conversation:!0,max_token:200}),this.eliminateInput()}},{key:"beginRecorder",value:function(){this.recorder.start().then((function(){}),(function(e){}))}},{key:"eliminateInput",value:function(){this.inputTxt=""}},{key:"stopRecorder",value:function(){var e=Object(o["a"])(regeneratorRuntime.mark((function e(){var t,n,r,i;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return this.recorder.stop(),t=this.recorder.getWAVBlob(),n=new File([t],"test.wav",{type:"audio/wav"}),r=new FormData,r.append("files",n),e.next=8,Object(v["a"])(r);case 8:i=e.sent,this.url="".concat(l["c"]).concat(i.uris[0]),this.socket.emit("chat",{conversation_id:1,voice_conversation:this.url,full_conversation:!0,max_token:200});case 12:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()}]),n}(d["d"]);w=Object(f["a"])([Object(d["a"])({components:{Player:p["a"]}})],w);var C=w,A=C,S=(n("0634"),n("2877")),E=Object(S["a"])(A,r,i,!1,null,"da887810",null);t["default"]=E.exports},8055:function(e,t,n){var r=n("cc9e"),i=n("568d"),o=n("78eb"),a=n("c7b0")("socket.io-client");e.exports=t=c;var s=t.managers={};function c(e,t){"object"===typeof e&&(t=e,e=void 0),t=t||{};var n,i=r(e),c=i.source,u=i.id,f=i.path,d=s[u]&&f in s[u].nsps,p=t.forceNew||t["force new connection"]||!1===t.multiplex||d;return p?(a("ignoring socket cache for %s",c),n=o(c,t)):(s[u]||(a("new io instance for %s",c),s[u]=o(c,t)),n=s[u]),i.query&&!t.query&&(t.query=i.query),n.socket(i.path,t)}t.protocol=i.protocol,t.connect=c,t.Manager=n("78eb"),t.Socket=n("2851")},"81d5":function(e,t,n){"use strict";var r=n("7b0b"),i=n("23cb"),o=n("50c4");e.exports=function(e){var t=r(this),n=o(t.length),a=arguments.length,s=i(a>1?arguments[1]:void 0,n),c=a>2?arguments[2]:void 0,u=void 0===c?n:i(c,n);while(u>s)t[s++]=e;return t}},"82f8":function(e,t,n){"use strict";var r=n("ebb5"),i=n("4d64").includes,o=r.aTypedArray,a=r.exportTypedArrayMethod;a("includes",(function(e){return i(o(this),e,arguments.length>1?arguments[1]:void 0)}))},8345:function(e,t,n){"use strict";var r=n("be42"),i=n.n(r);i.a},8390:function(e,t){(function(e){"use strict";t.encode=function(t){var n,r=new Uint8Array(t),i=r.length,o="";for(n=0;n>2],o+=e[(3&r[n])<<4|r[n+1]>>4],o+=e[(15&r[n+1])<<2|r[n+2]>>6],o+=e[63&r[n+2]];return i%3===2?o=o.substring(0,o.length-1)+"=":i%3===1&&(o=o.substring(0,o.length-2)+"=="),o},t.decode=function(t){var n,r,i,o,a,s=.75*t.length,c=t.length,u=0;"="===t[t.length-1]&&(s--,"="===t[t.length-2]&&s--);var f=new ArrayBuffer(s),d=new Uint8Array(f);for(n=0;n>4,d[u++]=(15&i)<<4|o>>2,d[u++]=(3&o)<<6|63&a;return f}})("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/")},"83b9":function(e,t,n){"use strict";var r=n("d925"),i=n("e683");e.exports=function(e,t){return e&&!r(t)?i(e,t):t}},"8a79":function(e,t,n){"use strict";var r=n("23e7"),i=n("06cf").f,o=n("50c4"),a=n("5a34"),s=n("1d80"),c=n("ab13"),u=n("c430"),f="".endsWith,d=Math.min,p=c("endsWith"),l=!u&&!p&&!!function(){var e=i(String.prototype,"endsWith");return e&&!e.writable}();r({target:"String",proto:!0,forced:!l&&!p},{endsWith:function(e){var t=String(s(this));a(e);var n=arguments.length>1?arguments[1]:void 0,r=o(t.length),i=void 0===n?r:d(o(n),r),c=String(e);return f?f.call(t,c,i):t.slice(i-c.length,i)===c}})},"8aa7":function(e,t,n){var r=n("da84"),i=n("d039"),o=n("1c7e"),a=n("ebb5").NATIVE_ARRAY_BUFFER_VIEWS,s=r.ArrayBuffer,c=r.Int8Array;e.exports=!a||!i((function(){c(1)}))||!i((function(){new c(-1)}))||!o((function(e){new c,new c(null),new c(1.5),new c(e)}),!0)||i((function(){return 1!==new c(new s(2),1,void 0).length}))},"8df4":function(e,t,n){"use strict";var r=n("7a77");function i(e){if("function"!==typeof e)throw new TypeError("executor must be a function.");var t;this.promise=new Promise((function(e){t=e}));var n=this;e((function(e){n.reason||(n.reason=new r(e),t(n.reason))}))}i.prototype.throwIfRequested=function(){if(this.reason)throw this.reason},i.source=function(){var e,t=new i((function(t){e=t}));return{token:t,cancel:e}},e.exports=i},"8e0c":function(e,t){e.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAANEAAADRCAYAAABSOlfvAAAACXBIWXMAABcRAAAXEQHKJvM/AAAOdUlEQVR4nO3de9BdVXnH8W8gT8IK0ICEIloCGKuGEKlYkFbAghktKqPQxlppLReljKVYwBtIWxVobcELqe2oVG4iXijQOlAQ0tZWa8WhjiJD0nBVaeUikRLICjy59I+9Xya+Dcn7nr3WXnvv8/vMZPgjOc9+8nJ+Wfvssy4zNm3ahIiMbrvSDYj0nUIk0pBCJNKQQiTSkEIk0pBCJNKQQiTSkEIk0pBCJNKQQiTSkEIk0pBCJNKQQiTSkEIk0pBCJNKQQiTSkEIk0pBCJNLQzNINdF0w2wPYD9gb2AuYDzwP2K3+NRcIwGzACrWZwgbgaWAt8DjwGPAw8GPgQeAB4C5gJfCj6K59BWoztMfCzwpmC4DXA4cCh1AFR37WGuA24BbgBuD74xwqhQgIZq8A3gi8DngpMKNsR73zEHAT8Hlg+bgFaixDFMzmAEcArwGOBvYt29GgPAx8DbgZ+Ep0f6RsO/mNVYiC2XOA9wJ/AOxUuJ1xEIErgU9G99tLN5PLWIQomO0JnAMcD8wp281Y2gRcDZwV3e8t3Uxqgw5Rfdv2TuBsYNfC7Qisp/rcdG50v6d0M6kMMkTB7HnAGVQjz25lu5EtWA98Djh/CGEaVIiC2QzgROBCYJfC7ci2bQD+Fjg7uq8u3cyoBhOiYLYQuBh4ZeleZNoeBo6L7stLNzKK3k/7CWazg9l5wHdRgPrq54Ebg9nFwWx+6Wamq9cjUTA7APgCsLB0L5LMWuCM6P7p0o1MVW9HomB2MvAtFKChmQN8Kph9pHQjU9XLkSiYnQOcW7oPye4y4JTo/lTpRramVyEKZrsDHwfeiua3jYs7gZOj+7+XbuTZ9CZEwWwxcCPw/NK9SOs2AEuj+3WlG9mSXoQomO0PfB199zPOngCOiu7fKN3IZJ1/sBDM5gHXogCNu52Am4LZktKNTNbpEAWzA6mewP1i6V6kE3YErg9mx5RuZHOdvZ0LZouoAqQlCzJZBJZE92+WbgQ6GqJgNgv4D+DA0r1IZ/0UODy631G6kc7dzgWzucA/ogDJ1u0K/FMwO6R0I50aiYKZAcuBw0v3Ir2xBjggut9XqoGujUTLUIBkenYGLirZQGdGomD2WqodY0RGcWJ0v7TEhTsRono6z61o1x0Z3TrgmOje+j/ExUNUr0ZdDhxZtBEZgjXAy9pect6Fz0TvQgGSNHYGLg9mrb6vi4YomB0G/HnJHmRwXgmc0uYFi93O1dtZrUKzsiW9R4EF0f1/27hYyZHoBBQgyWM3Wly0WWQkqu9ZV6KJpZLPeuDA6P793BcqNRK9DwVI8poJfLaeBZNV6yEKZvsCH2z7ujKWDgJOzX2REiPRHwOzClxXxtNZwWyHnBdoNUTB7AXA77Z5TRl7uwNvynmBtkeiv0TnxEr73pmzeGtP54LZi4EVaKsrKeMV0f3bOQq3ORL9BgqQlHNarsJtjkR3oi1/pRwHFkX3u1IXbmUkCmavQgGSsgw4PUfhtm7njm/pOiJb85ZgNjt10ewhCmYBODb3dUSmYFfg9amLtjES/Rbwcy1cR2Qq3pG6YBshOr6Fa4hM1WuCWdLDsLOGKJg9Bx0BKd2yHfArqQvmdAyaoSDd86qUxXKHKOucJZERHZqyWLYvW+uFd6uBuVkuIDK6J4G50X1DimI5R6IXoABJN+0IHJCqWM4QvSxjbZGmjkhVKGeIFmesLdJUss9FOUO0IGNtkaZ+KVWhnCHSvtrSZfODWZJTGDUSybjajkQfObKEqE747jlqiyS0X4oiuUaifdAqVum+fVIUyRkika7bO0WRXCHSHtvSB7+QokiuEM3LVFckpSTv01wh2iVTXZGUkrxPc4VIc+akD5KsuM611idkqpvKJuC/qI53eZxqWF8M7FWyKeDHwPeozh5dSPUItuQZUmuB24AHgA3AfOBguv//d6qS/D1yhSj7cRYj2gAsAz4a3f978m8Gs0XAOcBbWu7rG8CfRPd/mdTPHsDvAO+n3c+ZPwAuBK6I7o9P6ikARwPvpjp1oc+SvP+zrCcKZl8C3py8cDPXAGdNZfO+YHYo8FGqf3Vzuhc4Jbrfso1+9gAuoApUzu/fNgLnA+dF96e39YeD2duBT1AtLeil6N7455krRF8GliYvPLrLovsJ03lBMJsJXE2+1bmrgV+O7vdNo6fTgIsy9bMJODG6XzadFwWzg4HlVCd3906KEBU9PbwlDwFnTPdF0X09cBxwf+qGqN6wb51OgOqelgEXZ+gHqlvcy6b7onqT+JPSt9Mf4xCi90T3n47ywui+luq2LrUro/tXR3ztmVSjWEr3Ux2+NpLofjXwD8m66Zmhh+g/gSsb1rgCeCxBLxPWAWeP+uLovga4PF07AJwd3dc1rPFeqgc3Y2foIbokujf60Fc/nbo2UT8AN0X3BxrWuCFJJ5UnqD77NRLdVwG3N2+nf4YeolsT1Ul5OFSKnu5MUGPCqvrzXworEtXplaGHqOm/+KnrpKr1SIIaXa/VG0MPUarn9ym/B2jnVLUyhvx3e1ZDD1GqfR72SVQH0vT03AQ1ul6rN4YeolQbl6fcAD1FrUUJakx4UTCblahWyr56Y+ghOimYbd+kQDDblbSzFpYEs6abuBydpJNKoJpO1KyI2WIUokHaHzi5YY23A0m2VqrNopoHN5L6bJ23pWsHgPOCWdNpOx9n+O+nLRqHv/SfBbOR7tWD2S7kOSz3TcFs1LmFf0P6eWp70mBmRj0R9dXp2umXcQjRLsBfT/dF9ZT/a6jeYKnNAC6pl15Mp6cPk292/DuC2ZnTfVEwWwL8VYZ+emMcQgRwbDC7JZi9fCp/OJi9gWox2pEZe9oJuDmYLa2PodlaP/sGs6/QYH7bFF0QzJZN5dYumM0MZu+mmj2xQ+a+Om1clkJM2ARcBVwY3b+7+W/USx8Oo5rXtqTlvlYAHwKu23wdTzDbj+rzz6m0u2ZnNdXo/ZnJU5TqtU1LgXcBL2yxpyy0nqiZn1AtEZ9YHr6QtA8QRrGWKlATy8P3KNsOG6l+RpsvD1/IgDbmTBGiXMvD+zCbdx7d29prDjClW86WbEcVmoWlG8lkY4oiuT4TbXNpsUgHJHmf5gpRzFRXJKUk79NcIXoiU12RlGanKJIrRI9mqiuSUpJ953KF6MFMdUVSSvKUUSESaShXiFKuBBXptFwhuodEz+BFui5LiOr92nRLJ2Mh5wTUH2asLdIZOUO0KmNtkc7IGaKUe6OJdFbOEK3MWFukMzQSiTSUM0T3UB1rIjJo2UIU3TcCN+aqL9IVufdY2OoxiiJDkDtE1wNPZr6GSFFZQ1Sf7XN9zmuIlNbGllnXtHANkWKy7PazuWA2h+opXemddET+n16cHl5PRr0093VESmlrB9SLGNMDoGT4WglRdL8H+E4b1xJpW5t7cf99i9cSaU2bIfoc2tRRBqi1EEX3H1AFSWRQ2j5a5S+A9S1fUySrVkMU3e+ielInMhjZv2ydrP7y9W7ynEAnMi29+LJ1svrL1w+2fV2RXFofiQCC2fZUh0c1PYpepJFejkQA0X0DGo1kIIqMRBOC2b8ChxdrQMZeb0eizfw+sK5wDyKNFA1RdF8JnIT27ZYeKz0SEd2vAi4o3YfIqIp+JpoQzAz4HsM9pVo6agifiQCI7g68p3QfIqPoRIgAovsNwDlo8Z70TGdCBBDdzwc+UroPkenoVIhqHwD+rnQTIlPViQcLkwWzHYBbgZeW7kWGbTAPFiaL7uuAY4F7S/cisi2dDBE8s7nJr6IjWqTjOhsigOj+EHAkGpGkwzodIngmSK8F7ijdi8iWdD5EANH9buBg4LrSvYhM1osQAUT3CPwm8DH0hax0SG9CBNXpe9H9TODc0r2ITOhViCZE9z+legR+d+leRHoZIoDofh2wP7AM3d5JQZ2csTBdwewE4FPArNK9SL8MdsbCdEX3S6nWIn0aiIXbkTEziJFoc8FsPnA58GuFW5Ee0Ei0BdH9h8AS4FSqYy5FshrcSLS5YLYjcBrwPmBu4Xakg1KMRIMO0YRgNg/4PeDNwEFA4x+cDINCNIJgdgjwfuB1gBVuZ+ieBHYs3cTWKEQNBLPnAr8NnAy8pHA7Q/IgcDVwJfAI8HXg+UU72gqFKIFgNoNq3dIbqUan/dDt3nQ9CtwMfB64Mbo/sxlnMNsb+Crw4kK9bZVClEEw2ws4BFgMLKKaFbEA2L5kXx2xEXgAWAWsAG6jWsa/Kro/6xspmM0FvkS1pKVTFKKW1Hs+vAR4Uf3fBVSHlO0JzAN2BgL9/8pgHbAGWE11K/Yj4L761yrg9uj+2CiFg9lsqg1o3pCm1TQUoo4JZjPp6a1gvYFmVvXP57PA23Jfa6oUIumlYHYK1bqwULoXhUh6K5gdS/UUr/TJJJr2I/0U3a8FjgOeLt1LUwqRFBPdv0j1oGFN6V6aUIikqOh+C9UmNCtK9zIqhUiKq09MXEJPl/srRNIJ0f1/gEOB75TuZboUIumMeqPOw4FP0qN9MxQi6ZTo/mR0/0PgQ6V7mSqFSLrqw8AnSjcxFQqRdFJ03xTdTwfOouO3dpqxIJ0XzI4CrqCa7JuUpv3I2AhmBwP/TOKVspr2I2Mjun+b6rukn5TuZTKFSHojun8LOIyObYWmEEmvJJ7d8FSCGgqR9E90vwN4OfC1hqUead6NQiQ9Fd0fB34duLZBmftT9KIQSW9F96eApYz+pew3U/ShEEmv1acnng58gOl/KfvlFD3oeyIZjGB2ItU5VVPZ2fa26H5QiutqJJLBiO6XMLXvkjYCZ6a6rkIkgxLd/w04kGpE2tIeeU8Df1T/uSR0OyeDVW8YeRRwBNXROiuBq+ozrJJRiEQa0u2cSEMKkUhDCpFIQwqRSEMKkUhDCpFIQwqRSEMKkUhDCpFIQwqRSEMKkUhDCpFIQwqRSEMKkUhDCpFIQwqRSEMKkUhDCpFIQ/8HVv/lEwgsQSIAAAAASUVORK5CYII="},9121:function(e,t){function n(e,t){var n=[];t=t||0;for(var r=t||0;r>1,f=-7,d=n?i-1:0,p=n?-1:1,l=e[t+d];for(d+=p,o=l&(1<<-f)-1,l>>=-f,f+=s;f>0;o=256*o+e[t+d],d+=p,f-=8);for(a=o&(1<<-f)-1,o>>=-f,f+=r;f>0;a=256*a+e[t+d],d+=p,f-=8);if(0===o)o=1-u;else{if(o===c)return a?NaN:1/0*(l?-1:1);a+=Math.pow(2,r),o-=u}return(l?-1:1)*a*Math.pow(2,o-r)},t.write=function(e,t,n,r,i,o){var a,s,c,u=8*o-i-1,f=(1<>1,p=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,l=r?0:o-1,h=r?1:-1,m=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(s=isNaN(t)?1:0,a=f):(a=Math.floor(Math.log(t)/Math.LN2),t*(c=Math.pow(2,-a))<1&&(a--,c*=2),t+=a+d>=1?p/c:p*Math.pow(2,1-d),t*c>=2&&(a++,c/=2),a+d>=f?(s=0,a=f):a+d>=1?(s=(t*c-1)*Math.pow(2,i),a+=d):(s=t*Math.pow(2,d-1)*Math.pow(2,i),a=0));i>=8;e[n+l]=255&s,l+=h,s/=256,i-=8);for(a=a<0;e[n+l]=255&a,l+=h,a/=256,u-=8);e[n+l-h]|=128*m}},"91d3":function(e,t,n){"use strict";var r=n("4ace"),i=n.n(r);i.a},"94ac":function(e,t,n){e.exports=n("da92"),e.exports.parser=n("5a6e")},9617:function(e,t,n){function r(e){var n,r=0;for(n in e)r=(r<<5)-r+e.charCodeAt(n),r|=0;return t.colors[Math.abs(r)%t.colors.length]}function i(e){var n;function i(){if(i.enabled){var e=i,r=+new Date,o=r-(n||r);e.diff=o,e.prev=n,e.curr=r,n=r;for(var a=new Array(arguments.length),s=0;s=0;--o){var a=this.tryEntries[o],s=a.completion;if("root"===a.tryLoc)return r("end");if(a.tryLoc<=this.prev){var c=i.call(a,"catchLoc"),u=i.call(a,"finallyLoc");if(c&&u){if(this.prev=0;--n){var r=this.tryEntries[n];if(r.tryLoc<=this.prev&&i.call(r,"finallyLoc")&&this.prev=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),B(n),m}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var i=r.arg;B(n)}return i}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,r){return this.delegate={iterator:D(e),resultName:t,nextLoc:r},"next"===this.method&&(this.arg=n),m}}}function w(e,t,n,r){var i=t&&t.prototype instanceof A?t:A,o=Object.create(i.prototype),a=new O(r||[]);return o._invoke=k(e,n,a),o}function C(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(r){return{type:"throw",arg:r}}}function A(){}function S(){}function E(){}function T(e){["next","throw","return"].forEach((function(t){e[t]=function(e){return this._invoke(t,e)}}))}function R(e){function t(n,r,o,a){var s=C(e[n],e,r);if("throw"!==s.type){var c=s.arg,u=c.value;return u&&"object"===typeof u&&i.call(u,"__await")?Promise.resolve(u.__await).then((function(e){t("next",e,o,a)}),(function(e){t("throw",e,o,a)})):Promise.resolve(u).then((function(e){c.value=e,o(c)}),a)}a(s.arg)}var n;function r(e,r){function i(){return new Promise((function(n,i){t(e,r,n,i)}))}return n=n?n.then(i,i):i()}this._invoke=r}function k(e,t,n){var r=d;return function(i,o){if(r===l)throw new Error("Generator is already running");if(r===h){if("throw"===i)throw o;return M()}n.method=i,n.arg=o;while(1){var a=n.delegate;if(a){var s=x(a,n);if(s){if(s===m)continue;return s}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(r===d)throw r=h,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r=l;var c=C(e,t,n);if("normal"===c.type){if(r=n.done?h:p,c.arg===m)continue;return{value:c.arg,done:n.done}}"throw"===c.type&&(r=h,n.method="throw",n.arg=c.arg)}}}function x(e,t){var r=e.iterator[t.method];if(r===n){if(t.delegate=null,"throw"===t.method){if(e.iterator.return&&(t.method="return",t.arg=n,x(e,t),"throw"===t.method))return m;t.method="throw",t.arg=new TypeError("The iterator does not provide a 'throw' method")}return m}var i=C(r,e.iterator,t.arg);if("throw"===i.type)return t.method="throw",t.arg=i.arg,t.delegate=null,m;var o=i.arg;return o?o.done?(t[e.resultName]=o.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=n),t.delegate=null,m):o:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,m)}function P(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function B(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function O(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(P,this),this.reset(!0)}function D(e){if(e){var t=e[a];if(t)return t.call(e);if("function"===typeof e.next)return e;if(!isNaN(e.length)){var r=-1,o=function t(){while(++r0?arguments[0]:void 0,f=this,l=[];if(k(f,{type:T,entries:l,updateURL:function(){},updateSearchParams:N}),void 0!==u)if(g(u))if(e=w(u),"function"===typeof e){t=e.call(u),n=t.next;while(!(r=n.call(t)).done){if(i=b(m(r.value)),o=i.next,(a=o.call(i)).done||(s=o.call(i)).done||!o.call(i).done)throw TypeError("Expected sequence with length 2");l.push({key:a.value+"",value:s.value+""})}}else for(c in u)p(u,c)&&l.push({key:c,value:u[c]+""});else _(l,"string"===typeof u?"?"===u.charAt(0)?u.slice(1):u:u+"")},W=q.prototype;s(W,{append:function(e,t){H(arguments.length,2);var n=x(this);n.entries.push({key:e+"",value:t+""}),n.updateURL()},delete:function(e){H(arguments.length,1);var t=x(this),n=t.entries,r=e+"",i=0;while(ie.key){i.splice(t,0,e);break}t===n&&i.push(e)}r.updateURL()},forEach:function(e){var t,n=x(this).entries,r=l(e,arguments.length>1?arguments[1]:void 0,3),i=0;while(i1&&(t=arguments[1],g(t)&&(n=t.body,h(n)===T&&(r=t.headers?new S(t.headers):new S,r.has("content-type")||r.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"),t=y(t,{body:v(0,String(n)),headers:v(0,r)}))),i.push(t)),A.apply(this,i)}}),e.exports={URLSearchParams:q,getState:x}},"9a1f":function(e,t,n){var r=n("825a"),i=n("35a1");e.exports=function(e){var t=i(e);if("function"!=typeof t)throw TypeError(String(e)+" is not iterable");return r(t.call(e))}},"9a8c":function(e,t,n){"use strict";var r=n("ebb5"),i=n("145e"),o=r.aTypedArray,a=r.exportTypedArrayMethod;a("copyWithin",(function(e,t){return i.call(o(this),e,t,arguments.length>2?arguments[2]:void 0)}))},"9d0b":function(e,t,n){"use strict";var r=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"fixed-size",attrs:{id:"player"}},[n("div",{directives:[{name:"show",rawName:"v-show",value:e.disabledToUse,expression:"disabledToUse"}],staticClass:"wrapper"},[e._v(" 视频录制中,暂时无法操作 ")])])},i=[],o=(n("99af"),n("b64b"),n("ac1f"),n("1276"),n("be4f"),n("450d"),n("896a")),a=n.n(o),s=n("d4ec"),c=n("bee2"),u=n("262e"),f=n("2caf"),d=n("9ab4"),p=n("60a3"),l=n("e11d"),h=n("3525"),m=function(e){Object(u["a"])(n,e);var t=Object(f["a"])(n);function n(){var e;return Object(s["a"])(this,n),e=t.apply(this,arguments),e.disabledToUse=!1,e}return Object(c["a"])(n,[{key:"sceneWatcher",value:function(){this.creatSceneObj&&0!==Object.keys(this.creatSceneObj).length&&(l["d"]?Object(l["e"])(this.creatSceneObj):l["f"].Scene=this.creatSceneObj)}},{key:"saveShelfScene",value:function(e,t){}},{key:"saveScene",value:function(e,t){}},{key:"SaveAvatar",value:function(e){}},{key:"mounted",value:function(){l["f"].Map=this.currentMap,l["f"].Scene=this.creatSceneObj,Object(l["h"])("".concat(h["a"],"?token=").concat(window.location.href.split("=")[1])),this.onParagonLoad(),Object(l["b"])("handle_responses",this.disUse)}},{key:"beforeDestroy",value:function(){Object(l["c"])()}},{key:"disUse",value:function(e){var t;if(this.disabledToUse="StartRecord"===e,"CompleteRecord"!==e&&"StartRecord"!==e){var n=JSON.parse(e);switch(n.ResultType){case"SaveScene":this.saveShelfScene(n.scenelmage,n.shelvesData);break;case"SaveBaseScene":this.saveScene(n.sceneImage,n.objectsData);break;case"SaveAvatar":this.SaveAvatar(n.headimg_uri);break;case"LoadingState":"Loading"===n.State?this.loading=a.a.service({lock:!0,text:"场景渲染中,请稍等...",spinner:"el-icon-loading",background:"rgb(26, 32, 39)"}):null===(t=this.loading)||void 0===t||t.close();break;default:break}}}},{key:"onParagonLoad",value:function(){l["g"].controlScheme=l["a"].HoveringMouse,l["g"].fakeMouseWithTouches=!0}}]),n}(p["d"]);Object(d["a"])([Object(p["c"])({type:String})],m.prototype,"ueUrl",void 0),Object(d["a"])([Object(p["c"])({type:Object,default:function(){}})],m.prototype,"creatSceneObj",void 0),Object(d["a"])([Object(p["c"])({type:String,default:""})],m.prototype,"currentMap",void 0),Object(d["a"])([Object(p["e"])("creatSceneObj",{immediate:!0,deep:!0})],m.prototype,"sceneWatcher",null),Object(d["a"])([Object(p["b"])()],m.prototype,"saveShelfScene",null),Object(d["a"])([Object(p["b"])()],m.prototype,"saveScene",null),Object(d["a"])([Object(p["b"])()],m.prototype,"SaveAvatar",null),m=Object(d["a"])([Object(p["a"])({components:{}})],m);var g=m,y=g,v=(n("fe2f"),n("fe49"),n("2877")),b=Object(v["a"])(y,r,i,!1,null,"492fdca0",null);t["a"]=b.exports},a078:function(e,t,n){var r=n("7b0b"),i=n("50c4"),o=n("35a1"),a=n("e95a"),s=n("0366"),c=n("ebb5").aTypedArrayConstructor;e.exports=function(e){var t,n,u,f,d,p,l=r(e),h=arguments.length,m=h>1?arguments[1]:void 0,g=void 0!==m,y=o(l);if(void 0!=y&&!a(y)){d=y.call(l),p=d.next,l=[];while(!(f=p.call(d)).done)l.push(f.value)}for(g&&h>2&&(m=s(m,arguments[2],2)),n=i(l.length),u=new(c(this))(n),t=0;n>t;t++)u[t]=g?m(l[t],t):l[t];return u}},a081:function(e,t){var n,r,i,o=String.fromCharCode;function a(e){var t,n,r=[],i=0,o=e.length;while(i=55296&&t<=56319&&i65535&&(t-=65536,i+=o(t>>>10&1023|55296),t=56320|1023&t),i+=o(t);return i}function c(e,t){if(e>=55296&&e<=57343){if(t)throw Error("Lone surrogate U+"+e.toString(16).toUpperCase()+" is not a scalar value");return!1}return!0}function u(e,t){return o(e>>t&63|128)}function f(e,t){if(0==(4294967168&e))return o(e);var n="";return 0==(4294965248&e)?n=o(e>>6&31|192):0==(4294901760&e)?(c(e,t)||(e=65533),n=o(e>>12&15|224),n+=u(e,6)):0==(4292870144&e)&&(n=o(e>>18&7|240),n+=u(e,12),n+=u(e,6)),n+=o(63&e|128),n}function d(e,t){t=t||{};var n,r=!1!==t.strict,i=a(e),o=i.length,s=-1,c="";while(++s=r)throw Error("Invalid byte index");var e=255&n[i];if(i++,128==(192&e))return 63&e;throw Error("Invalid continuation byte")}function l(e){var t,o,a,s,u;if(i>r)throw Error("Invalid byte index");if(i==r)return!1;if(t=255&n[i],i++,0==(128&t))return t;if(192==(224&t)){if(o=p(),u=(31&t)<<6|o,u>=128)return u;throw Error("Invalid continuation byte")}if(224==(240&t)){if(o=p(),a=p(),u=(15&t)<<12|o<<6|a,u>=2048)return c(u,e)?u:65533;throw Error("Invalid continuation byte")}if(240==(248&t)&&(o=p(),a=p(),s=p(),u=(7&t)<<18|o<<12|a<<6|s,u>=65536&&u<=1114111))return u;throw Error("Invalid UTF-8 detected")}function h(e,t){t=t||{};var o=!1!==t.strict;n=a(e),r=n.length,i=0;var c,u=[];while(!1!==(c=l(o)))u.push(c);return s(u)}e.exports={version:"2.1.2",encode:d,decode:h}},a181:function(e,t,n){},a23b:function(e,t){var n={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==n.call(e)}},a3e4:function(e,t,n){e.exports=n.p+"img/对话-1.96e92e8c.png"},a975:function(e,t,n){"use strict";var r=n("ebb5"),i=n("b727").every,o=r.aTypedArray,a=r.exportTypedArrayMethod;a("every",(function(e){return i(o(this),e,arguments.length>1?arguments[1]:void 0)}))},a981:function(e,t){e.exports="undefined"!==typeof ArrayBuffer&&"undefined"!==typeof DataView},ad9a:function(e,t,n){!function(t,n){e.exports=n()}(0,(function(){return function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)n.d(r,i,function(t){return e[t]}.bind(null,i));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=1)}([function(e,t,n){"use strict";function r(e,t,n){for(var r=0;rt?t:n,c=o,u=new ArrayBuffer(44+e.byteLength),f=new DataView(u),d=i,p=0;r(f,p,"RIFF"),p+=4,f.setUint32(p,36+e.byteLength,a),r(f,p+=4,"WAVE"),r(f,p+=4,"fmt "),p+=4,f.setUint32(p,16,a),p+=4,f.setUint16(p,1,a),p+=2,f.setUint16(p,d,a),p+=2,f.setUint32(p,s,a),p+=4,f.setUint32(p,d*s*(c/8),a),p+=4,f.setUint16(p,d*(c/8),a),p+=2,f.setUint16(p,c,a),r(f,p+=2,"data"),p+=4,f.setUint32(p,e.byteLength,a),p+=4;for(var l=0;l44&&s.default.play(e.buffer)},t.prototype.getPlayTime=function(){return s.default.getPlayTime()},t.prototype.pausePlay=function(){!this.isrecording&&this.isplaying&&(this.isplaying=!1,this.onpauseplay&&this.onpauseplay(),s.default.pausePlay())},t.prototype.resumePlay=function(){this.isrecording||this.isplaying||(this.isplaying=!0,this.onresumeplay&&this.onresumeplay(),s.default.resumePlay())},t.prototype.stopPlay=function(){this.isrecording||(this.isplaying=!1,this.onstopplay&&this.onstopplay(),s.default.stopPlay())},t.prototype.destroy=function(){return s.default.destroyPlay(),this.destroyRecord()},t.prototype.getRecordAnalyseData=function(){return this.getAnalyseData()},t.prototype.getPlayAnalyseData=function(){return s.default.getAnalyseData()},t.prototype.getPCM=function(){this.stop();var e=this.getData();return e=a.compress(e,this.inputSampleRate,this.outputSampleRate),a.encodePCM(e,this.oututSampleBits,this.littleEdian)},t.prototype.getPCMBlob=function(){return new Blob([this.getPCM()])},t.prototype.downloadPCM=function(e){void 0===e&&(e="recorder");var t=this.getPCMBlob();o.downloadPCM(t,e)},t.prototype.getWAV=function(){var e=this.getPCM();return a.encodeWAV(e,this.inputSampleRate,this.outputSampleRate,this.config.numChannels,this.oututSampleBits,this.littleEdian)},t.prototype.getWAVBlob=function(){return new Blob([this.getWAV()],{type:"audio/wav"})},t.prototype.downloadWAV=function(e){void 0===e&&(e="recorder");var t=this.getWAVBlob();o.downloadWAV(t,e)},t.prototype.download=function(e,t,n){o.download(e,t,n)},t.prototype.getChannelData=function(){var e=this.getPCM(),t=e.byteLength,n=this.littleEdian,r={left:null,right:null};if(2===this.config.numChannels){var i=new DataView(new ArrayBuffer(t/2)),o=new DataView(new ArrayBuffer(t/2));if(16===this.config.sampleBits)for(var a=0;a=s())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+s().toString(16)+" bytes");return 0|e}function b(e){return+e!=e&&(e=0),u.alloc(+e)}function w(e,t){if(u.isBuffer(e))return e.length;if("undefined"!==typeof ArrayBuffer&&"function"===typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer))return e.byteLength;"string"!==typeof e&&(e=""+e);var n=e.length;if(0===n)return 0;for(var r=!1;;)switch(t){case"ascii":case"latin1":case"binary":return n;case"utf8":case"utf-8":case void 0:return K(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*n;case"hex":return n>>>1;case"base64":return $(e).length;default:if(r)return K(e).length;t=(""+t).toLowerCase(),r=!0}}function C(e,t,n){var r=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===n||n>this.length)&&(n=this.length),n<=0)return"";if(n>>>=0,t>>>=0,n<=t)return"";e||(e="utf8");while(1)switch(e){case"hex":return L(this,t,n);case"utf8":case"utf-8":return D(this,t,n);case"ascii":return F(this,t,n);case"latin1":case"binary":return U(this,t,n);case"base64":return O(this,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return j(this,t,n);default:if(r)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),r=!0}}function A(e,t,n){var r=e[t];e[t]=e[n],e[n]=r}function S(e,t,n,r,i){if(0===e.length)return-1;if("string"===typeof n?(r=n,n=0):n>2147483647?n=2147483647:n<-2147483648&&(n=-2147483648),n=+n,isNaN(n)&&(n=i?0:e.length-1),n<0&&(n=e.length+n),n>=e.length){if(i)return-1;n=e.length-1}else if(n<0){if(!i)return-1;n=0}if("string"===typeof t&&(t=u.from(t,r)),u.isBuffer(t))return 0===t.length?-1:E(e,t,n,r,i);if("number"===typeof t)return t&=255,u.TYPED_ARRAY_SUPPORT&&"function"===typeof Uint8Array.prototype.indexOf?i?Uint8Array.prototype.indexOf.call(e,t,n):Uint8Array.prototype.lastIndexOf.call(e,t,n):E(e,[t],n,r,i);throw new TypeError("val must be string, number or Buffer")}function E(e,t,n,r,i){var o,a=1,s=e.length,c=t.length;if(void 0!==r&&(r=String(r).toLowerCase(),"ucs2"===r||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(e.length<2||t.length<2)return-1;a=2,s/=2,c/=2,n/=2}function u(e,t){return 1===a?e[t]:e.readUInt16BE(t*a)}if(i){var f=-1;for(o=n;os&&(n=s-c),o=n;o>=0;o--){for(var d=!0,p=0;pi&&(r=i)):r=i;var o=t.length;if(o%2!==0)throw new TypeError("Invalid hex string");r>o/2&&(r=o/2);for(var a=0;a239?4:u>223?3:u>191?2:1;if(i+d<=n)switch(d){case 1:u<128&&(f=u);break;case 2:o=e[i+1],128===(192&o)&&(c=(31&u)<<6|63&o,c>127&&(f=c));break;case 3:o=e[i+1],a=e[i+2],128===(192&o)&&128===(192&a)&&(c=(15&u)<<12|(63&o)<<6|63&a,c>2047&&(c<55296||c>57343)&&(f=c));break;case 4:o=e[i+1],a=e[i+2],s=e[i+3],128===(192&o)&&128===(192&a)&&128===(192&s)&&(c=(15&u)<<18|(63&o)<<12|(63&a)<<6|63&s,c>65535&&c<1114112&&(f=c))}null===f?(f=65533,d=1):f>65535&&(f-=65536,r.push(f>>>10&1023|55296),f=56320|1023&f),r.push(f),i+=d}return I(r)}t.Buffer=u,t.SlowBuffer=b,t.INSPECT_MAX_BYTES=50,u.TYPED_ARRAY_SUPPORT=void 0!==e.TYPED_ARRAY_SUPPORT?e.TYPED_ARRAY_SUPPORT:a(),t.kMaxLength=s(),u.poolSize=8192,u._augment=function(e){return e.__proto__=u.prototype,e},u.from=function(e,t,n){return f(null,e,t,n)},u.TYPED_ARRAY_SUPPORT&&(u.prototype.__proto__=Uint8Array.prototype,u.__proto__=Uint8Array,"undefined"!==typeof Symbol&&Symbol.species&&u[Symbol.species]===u&&Object.defineProperty(u,Symbol.species,{value:null,configurable:!0})),u.alloc=function(e,t,n){return p(null,e,t,n)},u.allocUnsafe=function(e){return l(null,e)},u.allocUnsafeSlow=function(e){return l(null,e)},u.isBuffer=function(e){return!(null==e||!e._isBuffer)},u.compare=function(e,t){if(!u.isBuffer(e)||!u.isBuffer(t))throw new TypeError("Arguments must be Buffers");if(e===t)return 0;for(var n=e.length,r=t.length,i=0,o=Math.min(n,r);i0&&(e=this.toString("hex",0,n).match(/.{2}/g).join(" "),this.length>n&&(e+=" ... ")),""},u.prototype.compare=function(e,t,n,r,i){if(!u.isBuffer(e))throw new TypeError("Argument must be a Buffer");if(void 0===t&&(t=0),void 0===n&&(n=e?e.length:0),void 0===r&&(r=0),void 0===i&&(i=this.length),t<0||n>e.length||r<0||i>this.length)throw new RangeError("out of range index");if(r>=i&&t>=n)return 0;if(r>=i)return-1;if(t>=n)return 1;if(t>>>=0,n>>>=0,r>>>=0,i>>>=0,this===e)return 0;for(var o=i-r,a=n-t,s=Math.min(o,a),c=this.slice(r,i),f=e.slice(t,n),d=0;di)&&(n=i),e.length>0&&(n<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");r||(r="utf8");for(var o=!1;;)switch(r){case"hex":return T(this,e,t,n);case"utf8":case"utf-8":return R(this,e,t,n);case"ascii":return k(this,e,t,n);case"latin1":case"binary":return x(this,e,t,n);case"base64":return P(this,e,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return B(this,e,t,n);default:if(o)throw new TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),o=!0}},u.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var M=4096;function I(e){var t=e.length;if(t<=M)return String.fromCharCode.apply(String,e);var n="",r=0;while(rr)&&(n=r);for(var i="",o=t;on)throw new RangeError("Trying to access beyond buffer length")}function N(e,t,n,r,i,o){if(!u.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>i||te.length)throw new RangeError("Index out of range")}function H(e,t,n,r){t<0&&(t=65535+t+1);for(var i=0,o=Math.min(e.length-n,2);i>>8*(r?i:1-i)}function Q(e,t,n,r){t<0&&(t=4294967295+t+1);for(var i=0,o=Math.min(e.length-n,4);i>>8*(r?i:3-i)&255}function q(e,t,n,r,i,o){if(n+r>e.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("Index out of range")}function W(e,t,n,r,o){return o||q(e,t,n,4,34028234663852886e22,-34028234663852886e22),i.write(e,t,n,r,23,4),n+4}function J(e,t,n,r,o){return o||q(e,t,n,8,17976931348623157e292,-17976931348623157e292),i.write(e,t,n,r,52,8),n+8}u.prototype.slice=function(e,t){var n,r=this.length;if(e=~~e,t=void 0===t?r:~~t,e<0?(e+=r,e<0&&(e=0)):e>r&&(e=r),t<0?(t+=r,t<0&&(t=0)):t>r&&(t=r),t0&&(i*=256))r+=this[e+--t]*i;return r},u.prototype.readUInt8=function(e,t){return t||_(e,1,this.length),this[e]},u.prototype.readUInt16LE=function(e,t){return t||_(e,2,this.length),this[e]|this[e+1]<<8},u.prototype.readUInt16BE=function(e,t){return t||_(e,2,this.length),this[e]<<8|this[e+1]},u.prototype.readUInt32LE=function(e,t){return t||_(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},u.prototype.readUInt32BE=function(e,t){return t||_(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},u.prototype.readIntLE=function(e,t,n){e|=0,t|=0,n||_(e,t,this.length);var r=this[e],i=1,o=0;while(++o=i&&(r-=Math.pow(2,8*t)),r},u.prototype.readIntBE=function(e,t,n){e|=0,t|=0,n||_(e,t,this.length);var r=t,i=1,o=this[e+--r];while(r>0&&(i*=256))o+=this[e+--r]*i;return i*=128,o>=i&&(o-=Math.pow(2,8*t)),o},u.prototype.readInt8=function(e,t){return t||_(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},u.prototype.readInt16LE=function(e,t){t||_(e,2,this.length);var n=this[e]|this[e+1]<<8;return 32768&n?4294901760|n:n},u.prototype.readInt16BE=function(e,t){t||_(e,2,this.length);var n=this[e+1]|this[e]<<8;return 32768&n?4294901760|n:n},u.prototype.readInt32LE=function(e,t){return t||_(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},u.prototype.readInt32BE=function(e,t){return t||_(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},u.prototype.readFloatLE=function(e,t){return t||_(e,4,this.length),i.read(this,e,!0,23,4)},u.prototype.readFloatBE=function(e,t){return t||_(e,4,this.length),i.read(this,e,!1,23,4)},u.prototype.readDoubleLE=function(e,t){return t||_(e,8,this.length),i.read(this,e,!0,52,8)},u.prototype.readDoubleBE=function(e,t){return t||_(e,8,this.length),i.read(this,e,!1,52,8)},u.prototype.writeUIntLE=function(e,t,n,r){if(e=+e,t|=0,n|=0,!r){var i=Math.pow(2,8*n)-1;N(this,e,t,n,i,0)}var o=1,a=0;this[t]=255&e;while(++a=0&&(a*=256))this[t+o]=e/a&255;return t+n},u.prototype.writeUInt8=function(e,t,n){return e=+e,t|=0,n||N(this,e,t,1,255,0),u.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),this[t]=255&e,t+1},u.prototype.writeUInt16LE=function(e,t,n){return e=+e,t|=0,n||N(this,e,t,2,65535,0),u.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):H(this,e,t,!0),t+2},u.prototype.writeUInt16BE=function(e,t,n){return e=+e,t|=0,n||N(this,e,t,2,65535,0),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):H(this,e,t,!1),t+2},u.prototype.writeUInt32LE=function(e,t,n){return e=+e,t|=0,n||N(this,e,t,4,4294967295,0),u.TYPED_ARRAY_SUPPORT?(this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e):Q(this,e,t,!0),t+4},u.prototype.writeUInt32BE=function(e,t,n){return e=+e,t|=0,n||N(this,e,t,4,4294967295,0),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):Q(this,e,t,!1),t+4},u.prototype.writeIntLE=function(e,t,n,r){if(e=+e,t|=0,!r){var i=Math.pow(2,8*n-1);N(this,e,t,n,i-1,-i)}var o=0,a=1,s=0;this[t]=255&e;while(++o>0)-s&255;return t+n},u.prototype.writeIntBE=function(e,t,n,r){if(e=+e,t|=0,!r){var i=Math.pow(2,8*n-1);N(this,e,t,n,i-1,-i)}var o=n-1,a=1,s=0;this[t+o]=255&e;while(--o>=0&&(a*=256))e<0&&0===s&&0!==this[t+o+1]&&(s=1),this[t+o]=(e/a>>0)-s&255;return t+n},u.prototype.writeInt8=function(e,t,n){return e=+e,t|=0,n||N(this,e,t,1,127,-128),u.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),e<0&&(e=255+e+1),this[t]=255&e,t+1},u.prototype.writeInt16LE=function(e,t,n){return e=+e,t|=0,n||N(this,e,t,2,32767,-32768),u.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):H(this,e,t,!0),t+2},u.prototype.writeInt16BE=function(e,t,n){return e=+e,t|=0,n||N(this,e,t,2,32767,-32768),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):H(this,e,t,!1),t+2},u.prototype.writeInt32LE=function(e,t,n){return e=+e,t|=0,n||N(this,e,t,4,2147483647,-2147483648),u.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24):Q(this,e,t,!0),t+4},u.prototype.writeInt32BE=function(e,t,n){return e=+e,t|=0,n||N(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):Q(this,e,t,!1),t+4},u.prototype.writeFloatLE=function(e,t,n){return W(this,e,t,!0,n)},u.prototype.writeFloatBE=function(e,t,n){return W(this,e,t,!1,n)},u.prototype.writeDoubleLE=function(e,t,n){return J(this,e,t,!0,n)},u.prototype.writeDoubleBE=function(e,t,n){return J(this,e,t,!1,n)},u.prototype.copy=function(e,t,n,r){if(n||(n=0),r||0===r||(r=this.length),t>=e.length&&(t=e.length),t||(t=0),r>0&&r=this.length)throw new RangeError("sourceStart out of bounds");if(r<0)throw new RangeError("sourceEnd out of bounds");r>this.length&&(r=this.length),e.length-t=0;--i)e[i+t]=this[i+n];else if(o<1e3||!u.TYPED_ARRAY_SUPPORT)for(i=0;i>>=0,n=void 0===n?this.length:n>>>0,e||(e=0),"number"===typeof e)for(o=t;o55295&&n<57344){if(!i){if(n>56319){(t-=3)>-1&&o.push(239,191,189);continue}if(a+1===r){(t-=3)>-1&&o.push(239,191,189);continue}i=n;continue}if(n<56320){(t-=3)>-1&&o.push(239,191,189),i=n;continue}n=65536+(i-55296<<10|n-56320)}else i&&(t-=3)>-1&&o.push(239,191,189);if(i=null,n<128){if((t-=1)<0)break;o.push(n)}else if(n<2048){if((t-=2)<0)break;o.push(n>>6|192,63&n|128)}else if(n<65536){if((t-=3)<0)break;o.push(n>>12|224,n>>6&63|128,63&n|128)}else{if(!(n<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;o.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}}return o}function V(e){for(var t=[],n=0;n>8,i=n%256,o.push(i),o.push(r)}return o}function $(e){return r.toByteArray(z(e))}function ee(e,t,n,r){for(var i=0;i=t.length||i>=e.length)break;t[i+n]=e[i]}return i}function te(e){return e!==e}}).call(this,n("c8ba"))},b680:function(e,t,n){"use strict";var r=n("23e7"),i=n("a691"),o=n("408a"),a=n("1148"),s=n("d039"),c=1..toFixed,u=Math.floor,f=function(e,t,n){return 0===t?n:t%2===1?f(e,t-1,n*e):f(e*e,t/2,n)},d=function(e){var t=0,n=e;while(n>=4096)t+=12,n/=4096;while(n>=2)t+=1,n/=2;return t},p=c&&("0.000"!==8e-5.toFixed(3)||"1"!==.9.toFixed(0)||"1.25"!==1.255.toFixed(2)||"1000000000000000128"!==(0xde0b6b3a7640080).toFixed(0))||!s((function(){c.call({})}));r({target:"Number",proto:!0,forced:p},{toFixed:function(e){var t,n,r,s,c=o(this),p=i(e),l=[0,0,0,0,0,0],h="",m="0",g=function(e,t){var n=-1,r=t;while(++n<6)r+=e*l[n],l[n]=r%1e7,r=u(r/1e7)},y=function(e){var t=6,n=0;while(--t>=0)n+=l[t],l[t]=u(n/e),n=n%e*1e7},v=function(){var e=6,t="";while(--e>=0)if(""!==t||0===e||0!==l[e]){var n=String(l[e]);t=""===t?n:t+a.call("0",7-n.length)+n}return t};if(p<0||p>20)throw RangeError("Incorrect fraction digits");if(c!=c)return"NaN";if(c<=-1e21||c>=1e21)return String(c);if(c<0&&(h="-",c=-c),c>1e-21)if(t=d(c*f(2,69,1))-69,n=t<0?c*f(2,-t,1):c/f(2,t,1),n*=4503599627370496,t=52-t,t>0){g(0,n),r=p;while(r>=7)g(1e7,0),r-=7;g(f(10,r,1),0),r=t-1;while(r>=23)y(1<<23),r-=23;y(1<0?(s=m.length,m=h+(s<=p?"0."+a.call("0",p-s)+m:m.slice(0,s-p)+"."+m.slice(s-p))):m=h+m,m}})},b835:function(e,t){var n=1e3,r=60*n,i=60*r,o=24*i,a=365.25*o;function s(e){if(e=String(e),!(e.length>100)){var t=/^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec(e);if(t){var s=parseFloat(t[1]),c=(t[2]||"ms").toLowerCase();switch(c){case"years":case"year":case"yrs":case"yr":case"y":return s*a;case"days":case"day":case"d":return s*o;case"hours":case"hour":case"hrs":case"hr":case"h":return s*i;case"minutes":case"minute":case"mins":case"min":case"m":return s*r;case"seconds":case"second":case"secs":case"sec":case"s":return s*n;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return s;default:return}}}}function c(e){return e>=o?Math.round(e/o)+"d":e>=i?Math.round(e/i)+"h":e>=r?Math.round(e/r)+"m":e>=n?Math.round(e/n)+"s":e+"ms"}function u(e){return f(e,o,"day")||f(e,i,"hour")||f(e,r,"minute")||f(e,n,"second")||e+" ms"}function f(e,t,n){if(!(e0)return s(e);if("number"===n&&!1===isNaN(e))return t.long?u(e):c(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},bb2f:function(e,t,n){var r=n("d039");e.exports=!r((function(){return Object.isExtensible(Object.preventExtensions({}))}))},bc3a:function(e,t,n){e.exports=n("cee4")},be42:function(e,t,n){},bf19:function(e,t,n){"use strict";var r=n("23e7");r({target:"URL",proto:!0,enumerable:!0},{toJSON:function(){return URL.prototype.toString.call(this)}})},c19f:function(e,t,n){"use strict";var r=n("23e7"),i=n("da84"),o=n("621a"),a=n("2626"),s="ArrayBuffer",c=o[s],u=i[s];r({global:!0,forced:u!==c},{ArrayBuffer:c}),a(s)},c1ac:function(e,t,n){"use strict";var r=n("ebb5"),i=n("b727").filter,o=n("4840"),a=r.aTypedArray,s=r.aTypedArrayConstructor,c=r.exportTypedArrayMethod;c("filter",(function(e){var t=i(a(this),e,arguments.length>1?arguments[1]:void 0),n=o(this,this.constructor),r=0,c=t.length,u=new(s(n))(c);while(c>r)u[r]=t[r++];return u}))},c345:function(e,t,n){"use strict";var r=n("c532"),i=["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"];e.exports=function(e){var t,n,o,a={};return e?(r.forEach(e.split("\n"),(function(e){if(o=e.indexOf(":"),t=r.trim(e.substr(0,o)).toLowerCase(),n=r.trim(e.substr(o+1)),t){if(a[t]&&i.indexOf(t)>=0)return;a[t]="set-cookie"===t?(a[t]?a[t]:[]).concat([n]):a[t]?a[t]+", "+n:n}})),a):a}},c401:function(e,t,n){"use strict";var r=n("c532");e.exports=function(e,t,n){return r.forEach(n,(function(n){e=n(e,t)})),e}},c532:function(e,t,n){"use strict";var r=n("1d2b"),i=Object.prototype.toString;function o(e){return"[object Array]"===i.call(e)}function a(e){return"undefined"===typeof e}function s(e){return null!==e&&!a(e)&&null!==e.constructor&&!a(e.constructor)&&"function"===typeof e.constructor.isBuffer&&e.constructor.isBuffer(e)}function c(e){return"[object ArrayBuffer]"===i.call(e)}function u(e){return"undefined"!==typeof FormData&&e instanceof FormData}function f(e){var t;return t="undefined"!==typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer&&e.buffer instanceof ArrayBuffer,t}function d(e){return"string"===typeof e}function p(e){return"number"===typeof e}function l(e){return null!==e&&"object"===typeof e}function h(e){return"[object Date]"===i.call(e)}function m(e){return"[object File]"===i.call(e)}function g(e){return"[object Blob]"===i.call(e)}function y(e){return"[object Function]"===i.call(e)}function v(e){return l(e)&&y(e.pipe)}function b(e){return"undefined"!==typeof URLSearchParams&&e instanceof URLSearchParams}function w(e){return e.replace(/^\s*/,"").replace(/\s*$/,"")}function C(){return("undefined"===typeof navigator||"ReactNative"!==navigator.product&&"NativeScript"!==navigator.product&&"NS"!==navigator.product)&&("undefined"!==typeof window&&"undefined"!==typeof document)}function A(e,t){if(null!==e&&"undefined"!==typeof e)if("object"!==typeof e&&(e=[e]),o(e))for(var n=0,r=e.length;n=31||"undefined"!==typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))}function o(e){var n=this.useColors;if(e[0]=(n?"%c":"")+this.namespace+(n?" %c":" ")+e[0]+(n?"%c ":" ")+"+"+t.humanize(this.diff),n){var r="color: "+this.color;e.splice(1,0,r,"color: inherit");var i=0,o=0;e[0].replace(/%[a-zA-Z%]/g,(function(e){"%%"!==e&&(i++,"%c"===e&&(o=i))})),e.splice(o,0,r)}}function a(){return"object"===typeof console&&console.log&&Function.prototype.apply.call(console.log,console,arguments)}function s(e){try{null==e?t.storage.removeItem("debug"):t.storage.debug=e}catch(n){}}function c(){var e;try{e=t.storage.debug}catch(n){}return!e&&"undefined"!==typeof r&&"env"in r&&(e=Object({VUE_APP_HTTP_URL:"http://frps.retailwell.com:20068",VUE_APP_Live_URL:"http://metaplayer.sxkj.com/ws",VUE_APP_Iframe_URL:"http://metaplayer.sxkj.com",NODE_ENV:"production",BASE_URL:"/"}).DEBUG),e}function u(){try{return window.localStorage}catch(e){}}t=e.exports=n("43cd"),t.log=a,t.formatArgs=o,t.save=s,t.load=c,t.useColors=i,t.storage="undefined"!=typeof chrome&&"undefined"!=typeof chrome.storage?chrome.storage.local:u(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],t.formatters.j=function(e){try{return JSON.stringify(e)}catch(t){return"[UnexpectedJSONParseError]: "+t.message}},t.enable(c())}).call(this,n("4362"))},c8af:function(e,t,n){"use strict";var r=n("c532");e.exports=function(e,t){r.forEach(e,(function(n,r){r!==t&&r.toUpperCase()===t.toUpperCase()&&(e[t]=n,delete e[r])}))}},c973:function(e,t,n){function r(e,t,n,r,i,o,a){try{var s=e[o](a),c=s.value}catch(u){return void n(u)}s.done?t(c):Promise.resolve(c).then(r,i)}function i(e){return function(){var t=this,n=arguments;return new Promise((function(i,o){var a=e.apply(t,n);function s(e){r(a,i,o,s,c,"next",e)}function c(e){r(a,i,o,s,c,"throw",e)}s(void 0)}))}}n("d3b7"),e.exports=i},c9eb:function(e,t){try{e.exports="undefined"!==typeof XMLHttpRequest&&"withCredentials"in new XMLHttpRequest}catch(n){e.exports=!1}},ca91:function(e,t,n){"use strict";var r=n("ebb5"),i=n("d58f").left,o=r.aTypedArray,a=r.exportTypedArrayMethod;a("reduce",(function(e){return i(o(this),e,arguments.length,arguments.length>1?arguments[1]:void 0)}))},ca99:function(e,t){e.exports=function(e,t,n){var r=e.byteLength;if(t=t||0,n=n||r,e.slice)return e.slice(t,n);if(t<0&&(t+=r),n<0&&(n+=r),n>r&&(n=r),t>=r||t>=n||0===r)return new ArrayBuffer(0);for(var i=new Uint8Array(e),o=new Uint8Array(n-t),a=t,s=0;a1?arguments[1]:void 0)}))},d33e:function(e,t,n){var r=n("d63e"),i=n("0949"),o=n("7297"),a=n("62fa"),s=n("1e32")("engine.io-client:polling-xhr"),c=n("d941");function u(){}function f(e){if(i.call(this,e),this.requestTimeout=e.requestTimeout,this.extraHeaders=e.extraHeaders,"undefined"!==typeof location){var t="https:"===location.protocol,n=location.port;n||(n=t?443:80),this.xd="undefined"!==typeof location&&e.hostname!==location.hostname||n!==e.port,this.xs=e.secure!==t}}function d(e){this.method=e.method||"GET",this.uri=e.uri,this.xd=!!e.xd,this.xs=!!e.xs,this.async=!1!==e.async,this.data=void 0!==e.data?e.data:null,this.agent=e.agent,this.isBinary=e.isBinary,this.supportsBinary=e.supportsBinary,this.enablesXDR=e.enablesXDR,this.withCredentials=e.withCredentials,this.requestTimeout=e.requestTimeout,this.pfx=e.pfx,this.key=e.key,this.passphrase=e.passphrase,this.cert=e.cert,this.ca=e.ca,this.ciphers=e.ciphers,this.rejectUnauthorized=e.rejectUnauthorized,this.extraHeaders=e.extraHeaders,this.create()}if(e.exports=f,e.exports.Request=d,a(f,i),f.prototype.supportsBinary=!0,f.prototype.request=function(e){return e=e||{},e.uri=this.uri(),e.xd=this.xd,e.xs=this.xs,e.agent=this.agent||!1,e.supportsBinary=this.supportsBinary,e.enablesXDR=this.enablesXDR,e.withCredentials=this.withCredentials,e.pfx=this.pfx,e.key=this.key,e.passphrase=this.passphrase,e.cert=this.cert,e.ca=this.ca,e.ciphers=this.ciphers,e.rejectUnauthorized=this.rejectUnauthorized,e.requestTimeout=this.requestTimeout,e.extraHeaders=this.extraHeaders,new d(e)},f.prototype.doWrite=function(e,t){var n="string"!==typeof e&&void 0!==e,r=this.request({method:"POST",data:e,isBinary:n}),i=this;r.on("success",t),r.on("error",(function(e){i.onError("xhr post error",e)})),this.sendXhr=r},f.prototype.doPoll=function(){s("xhr poll");var e=this.request(),t=this;e.on("data",(function(e){t.onData(e)})),e.on("error",(function(e){t.onError("xhr poll error",e)})),this.pollXhr=e},o(d.prototype),d.prototype.create=function(){var e={agent:this.agent,xdomain:this.xd,xscheme:this.xs,enablesXDR:this.enablesXDR};e.pfx=this.pfx,e.key=this.key,e.passphrase=this.passphrase,e.cert=this.cert,e.ca=this.ca,e.ciphers=this.ciphers,e.rejectUnauthorized=this.rejectUnauthorized;var t=this.xhr=new r(e),n=this;try{s("xhr open %s: %s",this.method,this.uri),t.open(this.method,this.uri,this.async);try{if(this.extraHeaders)for(var i in t.setDisableHeaderCheck&&t.setDisableHeaderCheck(!0),this.extraHeaders)this.extraHeaders.hasOwnProperty(i)&&t.setRequestHeader(i,this.extraHeaders[i])}catch(o){}if("POST"===this.method)try{this.isBinary?t.setRequestHeader("Content-type","application/octet-stream"):t.setRequestHeader("Content-type","text/plain;charset=UTF-8")}catch(o){}try{t.setRequestHeader("Accept","*/*")}catch(o){}"withCredentials"in t&&(t.withCredentials=this.withCredentials),this.requestTimeout&&(t.timeout=this.requestTimeout),this.hasXDR()?(t.onload=function(){n.onLoad()},t.onerror=function(){n.onError(t.responseText)}):t.onreadystatechange=function(){if(2===t.readyState)try{var e=t.getResponseHeader("Content-Type");(n.supportsBinary&&"application/octet-stream"===e||"application/octet-stream; charset=UTF-8"===e)&&(t.responseType="arraybuffer")}catch(o){}4===t.readyState&&(200===t.status||1223===t.status?n.onLoad():setTimeout((function(){n.onError("number"===typeof t.status?t.status:0)}),0))},s("xhr data %s",this.data),t.send(this.data)}catch(o){return void setTimeout((function(){n.onError(o)}),0)}"undefined"!==typeof document&&(this.index=d.requestsCount++,d.requests[this.index]=this)},d.prototype.onSuccess=function(){this.emit("success"),this.cleanup()},d.prototype.onData=function(e){this.emit("data",e),this.onSuccess()},d.prototype.onError=function(e){this.emit("error",e),this.cleanup(!0)},d.prototype.cleanup=function(e){if("undefined"!==typeof this.xhr&&null!==this.xhr){if(this.hasXDR()?this.xhr.onload=this.xhr.onerror=u:this.xhr.onreadystatechange=u,e)try{this.xhr.abort()}catch(t){}"undefined"!==typeof document&&delete d.requests[this.index],this.xhr=null}},d.prototype.onLoad=function(){var e;try{var t;try{t=this.xhr.getResponseHeader("Content-Type")}catch(n){}e=("application/octet-stream"===t||"application/octet-stream; charset=UTF-8"===t)&&this.xhr.response||this.xhr.responseText}catch(n){this.onError(n)}null!=e&&this.onData(e)},d.prototype.hasXDR=function(){return"undefined"!==typeof XDomainRequest&&!this.xs&&this.enablesXDR},d.prototype.abort=function(){this.cleanup()},d.requestsCount=0,d.requests={},"undefined"!==typeof document)if("function"===typeof attachEvent)attachEvent("onunload",l);else if("function"===typeof addEventListener){var p="onpagehide"in c?"pagehide":"unload";addEventListener(p,l,!1)}function l(){for(var e in d.requests)d.requests.hasOwnProperty(e)&&d.requests[e].abort()}},d5d6:function(e,t,n){"use strict";var r=n("ebb5"),i=n("b727").forEach,o=r.aTypedArray,a=r.exportTypedArrayMethod;a("forEach",(function(e){i(o(this),e,arguments.length>1?arguments[1]:void 0)}))},d63e:function(e,t,n){var r=n("c9eb"),i=n("d941");e.exports=function(e){var t=e.xdomain,n=e.xscheme,o=e.enablesXDR;try{if("undefined"!==typeof XMLHttpRequest&&(!t||r))return new XMLHttpRequest}catch(a){}try{if("undefined"!==typeof XDomainRequest&&!n&&o)return new XDomainRequest}catch(a){}if(!t)try{return new(i[["Active"].concat("Object").join("X")])("Microsoft.XMLHTTP")}catch(a){}}},d780:function(e,t){var n="undefined"!==typeof n?n:"undefined"!==typeof WebKitBlobBuilder?WebKitBlobBuilder:"undefined"!==typeof MSBlobBuilder?MSBlobBuilder:"undefined"!==typeof MozBlobBuilder&&MozBlobBuilder,r=function(){try{var e=new Blob(["hi"]);return 2===e.size}catch(t){return!1}}(),i=r&&function(){try{var e=new Blob([new Uint8Array([1,2])]);return 2===e.size}catch(t){return!1}}(),o=n&&n.prototype.append&&n.prototype.getBlob;function a(e){return e.map((function(e){if(e.buffer instanceof ArrayBuffer){var t=e.buffer;if(e.byteLength!==t.byteLength){var n=new Uint8Array(e.byteLength);n.set(new Uint8Array(t,e.byteOffset,e.byteLength)),t=n.buffer}return t}return e}))}function s(e,t){t=t||{};var r=new n;return a(e).forEach((function(e){r.append(e)})),t.type?r.getBlob(t.type):r.getBlob()}function c(e,t){return new Blob(a(e),t||{})}"undefined"!==typeof Blob&&(s.prototype=Blob.prototype,c.prototype=Blob.prototype),e.exports=function(){return r?i?Blob:c:o?s:void 0}()},d838:function(e,t){function n(e,t,n){return e.on(t,n),{destroy:function(){e.removeListener(t,n)}}}e.exports=n},d925:function(e,t,n){"use strict";e.exports=function(e){return/^([a-z][a-z\d\+\-\.]*:)?\/\//i.test(e)}},d941:function(e,t){e.exports=function(){return"undefined"!==typeof self?self:"undefined"!==typeof window?window:Function("return this")()}()},da43:function(e,t,n){e.exports=n("ad9a")},da92:function(e,t,n){var r=n("6a44"),i=n("7297"),o=n("1e32")("engine.io-client:socket"),a=n("ee34"),s=n("5a6e"),c=n("5317"),u=n("4f2a");function f(e,t){if(!(this instanceof f))return new f(e,t);t=t||{},e&&"object"===typeof e&&(t=e,e=null),e?(e=c(e),t.hostname=e.host,t.secure="https"===e.protocol||"wss"===e.protocol,t.port=e.port,e.query&&(t.query=e.query)):t.host&&(t.hostname=c(t.host).host),this.secure=null!=t.secure?t.secure:"undefined"!==typeof location&&"https:"===location.protocol,t.hostname&&!t.port&&(t.port=this.secure?"443":"80"),this.agent=t.agent||!1,this.hostname=t.hostname||("undefined"!==typeof location?location.hostname:"localhost"),this.port=t.port||("undefined"!==typeof location&&location.port?location.port:this.secure?443:80),this.query=t.query||{},"string"===typeof this.query&&(this.query=u.decode(this.query)),this.upgrade=!1!==t.upgrade,this.path=(t.path||"/engine.io").replace(/\/$/,"")+"/",this.forceJSONP=!!t.forceJSONP,this.jsonp=!1!==t.jsonp,this.forceBase64=!!t.forceBase64,this.enablesXDR=!!t.enablesXDR,this.withCredentials=!1!==t.withCredentials,this.timestampParam=t.timestampParam||"t",this.timestampRequests=t.timestampRequests,this.transports=t.transports||["polling","websocket"],this.transportOptions=t.transportOptions||{},this.readyState="",this.writeBuffer=[],this.prevBufferLen=0,this.policyPort=t.policyPort||843,this.rememberUpgrade=t.rememberUpgrade||!1,this.binaryType=null,this.onlyBinaryUpgrades=t.onlyBinaryUpgrades,this.perMessageDeflate=!1!==t.perMessageDeflate&&(t.perMessageDeflate||{}),!0===this.perMessageDeflate&&(this.perMessageDeflate={}),this.perMessageDeflate&&null==this.perMessageDeflate.threshold&&(this.perMessageDeflate.threshold=1024),this.pfx=t.pfx||void 0,this.key=t.key||void 0,this.passphrase=t.passphrase||void 0,this.cert=t.cert||void 0,this.ca=t.ca||void 0,this.ciphers=t.ciphers||void 0,this.rejectUnauthorized=void 0===t.rejectUnauthorized||t.rejectUnauthorized,this.forceNode=!!t.forceNode,this.isReactNative="undefined"!==typeof navigator&&"string"===typeof navigator.product&&"reactnative"===navigator.product.toLowerCase(),("undefined"===typeof self||this.isReactNative)&&(t.extraHeaders&&Object.keys(t.extraHeaders).length>0&&(this.extraHeaders=t.extraHeaders),t.localAddress&&(this.localAddress=t.localAddress)),this.id=null,this.upgrades=null,this.pingInterval=null,this.pingTimeout=null,this.pingIntervalTimer=null,this.pingTimeoutTimer=null,this.open()}function d(e){var t={};for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);return t}e.exports=f,f.priorWebsocketSuccess=!1,i(f.prototype),f.protocol=s.protocol,f.Socket=f,f.Transport=n("19b7"),f.transports=n("6a44"),f.parser=n("5a6e"),f.prototype.createTransport=function(e){o('creating transport "%s"',e);var t=d(this.query);t.EIO=s.protocol,t.transport=e;var n=this.transportOptions[e]||{};this.id&&(t.sid=this.id);var i=new r[e]({query:t,socket:this,agent:n.agent||this.agent,hostname:n.hostname||this.hostname,port:n.port||this.port,secure:n.secure||this.secure,path:n.path||this.path,forceJSONP:n.forceJSONP||this.forceJSONP,jsonp:n.jsonp||this.jsonp,forceBase64:n.forceBase64||this.forceBase64,enablesXDR:n.enablesXDR||this.enablesXDR,withCredentials:n.withCredentials||this.withCredentials,timestampRequests:n.timestampRequests||this.timestampRequests,timestampParam:n.timestampParam||this.timestampParam,policyPort:n.policyPort||this.policyPort,pfx:n.pfx||this.pfx,key:n.key||this.key,passphrase:n.passphrase||this.passphrase,cert:n.cert||this.cert,ca:n.ca||this.ca,ciphers:n.ciphers||this.ciphers,rejectUnauthorized:n.rejectUnauthorized||this.rejectUnauthorized,perMessageDeflate:n.perMessageDeflate||this.perMessageDeflate,extraHeaders:n.extraHeaders||this.extraHeaders,forceNode:n.forceNode||this.forceNode,localAddress:n.localAddress||this.localAddress,requestTimeout:n.requestTimeout||this.requestTimeout,protocols:n.protocols||void 0,isReactNative:this.isReactNative});return i},f.prototype.open=function(){var e;if(this.rememberUpgrade&&f.priorWebsocketSuccess&&-1!==this.transports.indexOf("websocket"))e="websocket";else{if(0===this.transports.length){var t=this;return void setTimeout((function(){t.emit("error","No transports available")}),0)}e=this.transports[0]}this.readyState="opening";try{e=this.createTransport(e)}catch(n){return this.transports.shift(),void this.open()}e.open(),this.setTransport(e)},f.prototype.setTransport=function(e){o("setting transport %s",e.name);var t=this;this.transport&&(o("clearing existing transport %s",this.transport.name),this.transport.removeAllListeners()),this.transport=e,e.on("drain",(function(){t.onDrain()})).on("packet",(function(e){t.onPacket(e)})).on("error",(function(e){t.onError(e)})).on("close",(function(){t.onClose("transport close")}))},f.prototype.probe=function(e){o('probing transport "%s"',e);var t=this.createTransport(e,{probe:1}),n=!1,r=this;function i(){if(r.onlyBinaryUpgrades){var i=!this.supportsBinary&&r.transport.supportsBinary;n=n||i}n||(o('probe transport "%s" opened',e),t.send([{type:"ping",data:"probe"}]),t.once("packet",(function(i){if(!n)if("pong"===i.type&&"probe"===i.data){if(o('probe transport "%s" pong',e),r.upgrading=!0,r.emit("upgrading",t),!t)return;f.priorWebsocketSuccess="websocket"===t.name,o('pausing current transport "%s"',r.transport.name),r.transport.pause((function(){n||"closed"!==r.readyState&&(o("changing transport and sending upgrade packet"),p(),r.setTransport(t),t.send([{type:"upgrade"}]),r.emit("upgrade",t),t=null,r.upgrading=!1,r.flush())}))}else{o('probe transport "%s" failed',e);var a=new Error("probe error");a.transport=t.name,r.emit("upgradeError",a)}})))}function a(){n||(n=!0,p(),t.close(),t=null)}function s(n){var i=new Error("probe error: "+n);i.transport=t.name,a(),o('probe transport "%s" failed because of error: %s',e,n),r.emit("upgradeError",i)}function c(){s("transport closed")}function u(){s("socket closed")}function d(e){t&&e.name!==t.name&&(o('"%s" works - aborting "%s"',e.name,t.name),a())}function p(){t.removeListener("open",i),t.removeListener("error",s),t.removeListener("close",c),r.removeListener("close",u),r.removeListener("upgrading",d)}f.priorWebsocketSuccess=!1,t.once("open",i),t.once("error",s),t.once("close",c),this.once("close",u),this.once("upgrading",d),t.open()},f.prototype.onOpen=function(){if(o("socket open"),this.readyState="open",f.priorWebsocketSuccess="websocket"===this.transport.name,this.emit("open"),this.flush(),"open"===this.readyState&&this.upgrade&&this.transport.pause){o("starting upgrade probes");for(var e=0,t=this.upgrades.length;e=0;r--){var i=e[r];"."===i?e.splice(r,1):".."===i?(e.splice(r,1),n++):n&&(e.splice(r,1),n--)}if(t)for(;n--;n)e.unshift("..");return e}function r(e){"string"!==typeof e&&(e+="");var t,n=0,r=-1,i=!0;for(t=e.length-1;t>=0;--t)if(47===e.charCodeAt(t)){if(!i){n=t+1;break}}else-1===r&&(i=!1,r=t+1);return-1===r?"":e.slice(n,r)}function i(e,t){if(e.filter)return e.filter(t);for(var n=[],r=0;r=-1&&!r;o--){var a=o>=0?arguments[o]:e.cwd();if("string"!==typeof a)throw new TypeError("Arguments to path.resolve must be strings");a&&(t=a+"/"+t,r="/"===a.charAt(0))}return t=n(i(t.split("/"),(function(e){return!!e})),!r).join("/"),(r?"/":"")+t||"."},t.normalize=function(e){var r=t.isAbsolute(e),a="/"===o(e,-1);return e=n(i(e.split("/"),(function(e){return!!e})),!r).join("/"),e||r||(e="."),e&&a&&(e+="/"),(r?"/":"")+e},t.isAbsolute=function(e){return"/"===e.charAt(0)},t.join=function(){var e=Array.prototype.slice.call(arguments,0);return t.normalize(i(e,(function(e,t){if("string"!==typeof e)throw new TypeError("Arguments to path.join must be strings");return e})).join("/"))},t.relative=function(e,n){function r(e){for(var t=0;t=0;n--)if(""!==e[n])break;return t>n?[]:e.slice(t,n-t+1)}e=t.resolve(e).substr(1),n=t.resolve(n).substr(1);for(var i=r(e.split("/")),o=r(n.split("/")),a=Math.min(i.length,o.length),s=a,c=0;c=1;--o)if(t=e.charCodeAt(o),47===t){if(!i){r=o;break}}else i=!1;return-1===r?n?"/":".":n&&1===r?"/":e.slice(0,r)},t.basename=function(e,t){var n=r(e);return t&&n.substr(-1*t.length)===t&&(n=n.substr(0,n.length-t.length)),n},t.extname=function(e){"string"!==typeof e&&(e+="");for(var t=-1,n=0,r=-1,i=!0,o=0,a=e.length-1;a>=0;--a){var s=e.charCodeAt(a);if(47!==s)-1===r&&(i=!1,r=a+1),46===s?-1===t?t=a:1!==o&&(o=1):-1!==t&&(o=-1);else if(!i){n=a+1;break}}return-1===t||-1===r||0===o||1===o&&t===r-1&&t===n+1?"":e.slice(t,r)};var o="b"==="ab".substr(-1)?function(e,t,n){return e.substr(t,n)}:function(e,t,n){return t<0&&(t=e.length+t),e.substr(t,n)}}).call(this,n("4362"))},e11d:function(e,t,n){"use strict";n.d(t,"h",(function(){return it})),n.d(t,"a",(function(){return pe})),n.d(t,"g",(function(){return le})),n.d(t,"c",(function(){return ot})),n.d(t,"b",(function(){return $})),n.d(t,"e",(function(){return ke})),n.d(t,"f",(function(){return d})),n.d(t,"d",(function(){return p}));n("99af"),n("13d5"),n("fb6a"),n("c19f"),n("4ec9"),n("b680"),n("d3b7"),n("ac1f"),n("25f0"),n("3ca3"),n("38cf"),n("5319"),n("5cc6"),n("9a8c"),n("a975"),n("735e"),n("c1ac"),n("d139"),n("3a7b"),n("d5d6"),n("82f8"),n("e91f"),n("60bd"),n("5f96"),n("3280"),n("3fcc"),n("ca91"),n("25a1"),n("cd26"),n("3c5d"),n("2954"),n("649e"),n("219c"),n("170b"),n("b39a"),n("72f7"),n("ddb0");var r,i,o,a,s=n("b85c"),c=n("01bc"),u=n.n(c),f="",d={},p=!1,l="GamepadEvent"in window,h="WebKitGamepadEvent"in window,m={},g=window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame||window.requestAnimationFrame,y=document.createEvent("KeyboardEvent"),v=(y.initKeyboardEvent,null),b=!1,w=!1,C=!1,A=1,S=(new Date).getTime(),E=new Map,T=null,R=!0,k={receiving:!1,size:0,jpeg:void 0,height:0,width:0,valid:!1},x={enabled:!1,warnTimeout:120,closeTimeout:10,active:!1,overlay:void 0,warnTimer:void 0,countdown:0,countdownTimer:void 0},P=void 0,B=void 0;Date.now();function O(){(null===d||void 0===d?void 0:d.Map)&&ke({Action:"switch_map",Map:d.Map}),(null===d||void 0===d?void 0:d.Scene)&&ke(d.Scene)}function D(){for(var e=navigator.getGamepads?navigator.getGamepads():navigator.webkitGetGamepads?navigator.webkitGetGamepads():[],t=0;t0?n:-1}),ke({Console:"PixelStreaming.Encoder.MaxBitrateVBR "+r>0?r:-1}),ke({Console:"PixelStreaming.Encoder.MinQP "+i}),ke({Console:"PixelStreaming.Encoder.MaxQP "+o}),ke({Console:"PixelStreaming.Encoder.EnableFillerData "+a}),ke({Console:"PixelStreaming.Encoder.Multipass "+s})});var n=document.getElementById("webrtc-params-submit");null!==n&&(n.onclick=function(e){var t=document.getElementById("webrtc-degradation-pref").value,n=document.getElementById("webrtc-max-fps-text").value,r=1e3*document.getElementById("webrtc-min-bitrate-text").value,i=1e3*document.getElementById("webrtc-max-bitrate-text").value,o=document.getElementById("webrtc-low-qp-text").value,a=document.getElementById("webrtc-high-qp-text").value;ke({Console:"PixelStreaming.WebRTC.DegradationPreference "+t}),ke({Console:"PixelStreaming.WebRTC.MaxFps "+n}),ke({Console:"PixelStreaming.WebRTC.MinBitrate "+r}),ke({Console:"PixelStreaming.WebRTC.MaxBitrate "+i}),ke({Console:"PixelStreaming.WebRTC.LowQpThreshold "+o}),ke({Console:"PixelStreaming.WebRTC.HighQpThreshold "+a})});var a=document.getElementById("show-fps-button");null!==a&&(a.onclick=function(e){var t={Console:"stat fps"};ke(t)});var s=document.getElementById("match-viewport-res-tgl");null!==s&&(s.onchange=function(e){o=s.checked});var c=document.getElementById("show-stats-tgl");null!==c&&(c.onchange=function(e){var t=document.getElementById("statsContainer");t.style.display=e.target.checked?"block":"none"});var u=document.getElementById("kick-other-players-button");u&&(u.onclick=function(e){r.send(JSON.stringify({type:"kick"}))});var f=document.getElementById("test-latency-button");f&&(f.onclick=function(){N()})}function N(){if(v){var e=function(e){var t={StartTime:e};Re(Te.LatencyTest,t)};v.startLatencyTest(e)}}function H(e,t,n){var r=document.getElementById("videoPlayOverlay");if(!r){var i=document.getElementById("player");r=document.createElement("div"),r.id="videoPlayOverlay",null===i||void 0===i||i.appendChild(r)}while(r.lastChild)r.removeChild(r.lastChild);t&&r.appendChild(t),n&&r.addEventListener("click",(function e(t){n(t),r.removeEventListener("click",e)}));for(var o=r.classList,a=o.length-1;a>=0;a--)o.remove(o[a]);r.classList.add(e)}function Q(e){var t=document.createElement("div");t.id="messageOverlay",t.innerHTML=e||"",H("textDisplayState",t)}function q(){v&&v.video&&(v.video.play().catch((function(e){W()})),xe(),Pe(),ve(),z())}function W(){var e=document.createElement("img");e.id="playButton",R=!1}function J(){x.overlay.innerHTML="
No activity detected
Disconnecting in "+x.countdown+" seconds
Click to continue
"}function X(){G(),x.overlay=document.createElement("div"),x.overlay.id="afkOverlay",H("clickableState",x.overlay,(function(e){z(),clearInterval(x.countdownTimer),Y()})),x.countdown=x.closeTimeout,J(),le.controlScheme==pe.LockedMouse&&document.exitPointerLock(),x.countdownTimer=setInterval((function(){x.countdown--,0==x.countdown?(z(),r.close()):J()}),1e3)}function z(){H("hiddenState")}function Y(){x.active=x.enabled,K()}function G(){x.active=!1}function K(){x.active&&(clearTimeout(x.warnTimer),x.warnTimer=setTimeout((function(){X()}),1e3*x.warnTimeout))}function V(){v?(Q("正在连接服务器,请勿操作..."),v.createOffer()):Q("Unable to setup video")}function Z(e){v&&(K(),v.send(e))}function $(e,t){E.set(e,t)}var ee,te,ne,re,ie={QualityControlOwnership:0,Response:1,Command:2,FreezeFrame:3,UnfreezeFrame:4,VideoEncoderAvgQP:5,LatencyTest:6,InitialSettings:7},oe="N/A";function ae(e,t){function n(){var e=btoa(k.jpeg.reduce((function(e,t){return e+String.fromCharCode(t)}),"")),t=document.getElementById("freezeFrameOverlay").childNodes[0];t.src="data:image/jpeg;base64,"+e,t.onload=function(){k.height=t.naturalHeight,k.width=t.naturalWidth,we(),R?(W(),Ce()):ve(),v.setVideoEnabled(!1)}}function o(e){k.receiving||(k.receiving=!0,k.valid=!1,k.size=0,k.jpeg=void 0),k.size=new DataView(e.slice(1,5).buffer).getInt32(0,!0);var t=e.slice(5);if(k.jpeg){var r=new Uint8Array(k.jpeg.length+t.length);r.set(k.jpeg,0),r.set(t,k.jpeg.length),k.jpeg=r}else k.jpeg=t,k.receiving=!0;k.jpeg.length===k.size?(k.receiving=!1,k.valid=!0,n()):k.jpeg.length>k.size&&(k.jpeg=void 0,k.receiving=!1)}return v=new u.a(t),null===e||void 0===e||e.appendChild(v.video),null===e||void 0===e||e.appendChild(T),v.onWebRtcOffer=function(e){if(r&&r.readyState===A){var t=JSON.stringify(e);r.send(t)}},v.onWebRtcCandidate=function(e){r&&r.readyState===A&&r.send(JSON.stringify({type:"iceCandidate",candidate:e}))},v.onVideoInitialised=function(){r&&r.readyState===A&&(R?(W(),Ce()):(Ce(),q()))},v.onDataChannelConnected=function(){r&&r.readyState===A&&(Q("WebRTC已连接, 正在等待视频连接..."),v.video&&v.video.srcObject&&v.onVideoInitialised&&(v.onVideoInitialised(),p=!0,O()))},v.onDataChannelMessage=function(e){var t=new Uint8Array(e);if(t[0]===ie.QualityControlOwnership){var n=0!==t[1];null!==i&&(i.disabled=n,i.checked=n)}else if(t[0]===ie.Response){var r,a=new TextDecoder("utf-16").decode(e.slice(1)),c=Object(s["a"])(E.values());try{for(c.s();!(r=c.n()).done;){var u=r.value;u(a)}}catch(g){c.e(g)}finally{c.f()}}else if(t[0]===ie.Command){var f=new TextDecoder("utf-16").decode(e.slice(1)),d=JSON.parse(f);"onScreenKeyboard"===d.command&&Je(d)}else if(t[0]===ie.FreezeFrame)o(t);else if(t[0]===ie.UnfreezeFrame)be();else if(t[0]===ie.VideoEncoderAvgQP)oe=new TextDecoder("utf-16").decode(e.slice(1));else if(t[0]==ie.LatencyTest){var p=new TextDecoder("utf-16").decode(e.slice(1)),l=JSON.parse(p);v&&v.latencyTestTimings.SetUETimings(l)}else if(t[0]==ie.InitialSettings){var h=new TextDecoder("utf-16").decode(e.slice(1)),m=JSON.parse(h);m.Encoder&&(document.getElementById("encoder-rate-control")&&(document.getElementById("encoder-rate-control").value=m.Encoder.RateControl),document.getElementById("encoder-target-bitrate-text")&&(document.getElementById("encoder-target-bitrate-text").value=m.Encoder.TargetBitrate>0?m.Encoder.TargetBitrate/1e3:m.Encoder.TargetBitrate),document.getElementById("encoder-max-bitrate-text")&&(document.getElementById("encoder-max-bitrate-text").value=m.Encoder.MaxBitrate>0?m.Encoder.MaxBitrate/1e3:m.Encoder.MaxBitrate),document.getElementById("encoder-min-qp-text")&&(document.getElementById("encoder-min-qp-text").value=m.Encoder.MinQP),document.getElementById("encoder-max-qp-text")&&(document.getElementById("encoder-max-qp-text").value=m.Encoder.MaxQP),document.getElementById("encoder-filler-data-tgl")&&(document.getElementById("encoder-filler-data-tgl").checked=1==m.Encoder.FillerData),document.getElementById("encoder-multipass")&&(document.getElementById("encoder-multipass").value=m.Encoder.MultiPass)),m.WebRTC}},qe(v.video),"ontouchstart"in document.documentElement&&We(e),V(),v.video}function se(e){v.receiveAnswer(e);var t=3e5,n=t;v.onAggregatedStats=function(e){for(var i=new Intl.NumberFormat(window.navigator.language,{maximumFractionDigits:0}),o=new Intl.NumberFormat(window.navigator.language,{maximumFractionDigits:0,minimumIntegerDigits:2}),a=(e.timestamp-e.timestampStart)/1e3,s=[],c=[60,60],u=0;uC?(E="red",v(2),S+='
Bad network connection
')):oe>w&&(E="orange",v(1),S+='
Spotty network connection
')),y&&(y.className="".concat(E,"Status")),S+="
Duration: ".concat(o.format(p),":").concat(o.format(d),":").concat(o.format(f),"
"),S+="
Video Resolution: ".concat(e.hasOwnProperty("frameWidth")&&e.frameWidth&&e.hasOwnProperty("frameHeight")&&e.frameHeight?e.frameWidth+"x"+e.frameHeight:"Chrome only","
"),S+="
Received (".concat(l,"): ").concat(i.format(h),"
"),S+="
Frames Decoded: ".concat(e.hasOwnProperty("framesDecoded")?i.format(e.framesDecoded):"Chrome only","
"),S+="
Packets Lost: ".concat(e.hasOwnProperty("packetsLost")?i.format(e.packetsLost):"Chrome only","
"),S+='
Bitrate (kbps): ').concat(e.hasOwnProperty("bitrate")?i.format(e.bitrate):"Chrome only","
"),S+="
Framerate: ".concat(e.hasOwnProperty("framerate")?i.format(e.framerate):"Chrome only","
"),S+="
Frames dropped: ".concat(e.hasOwnProperty("framesDropped")?i.format(e.framesDropped):"Chrome only","
"),S+="
Net RTT (ms): ".concat(e.hasOwnProperty("currentRoundTripTime")?i.format(1e3*e.currentRoundTripTime):"Can't calculate","
"),S+="
Browser receive to composite (ms): ".concat(e.hasOwnProperty("receiveToCompositeMs")?i.format(e.receiveToCompositeMs):"Chrome only","
"),S+='
Video Quantization Parameter: ').concat(oe,"
");var T=document.getElementById("stats");T&&(T.innerHTML=S),b&&e.timestampStart&&e.timestamp-e.timestampStart>n&&(r&&r.readyState===A&&r.send(JSON.stringify({type:"stats",data:e})),n+=t)},v.aggregateStats(1e3),v.latencyTestTimings.OnAllLatencyTimingsReady=function(e){if(e.BrowserReceiptTimeMs){var t=e.BrowserReceiptTimeMs-e.TestStartTimeMs,n=0==e.UEPreEncodeTimeMs||0==e.UEPreCaptureTimeMs?"???":e.UEPostEncodeTimeMs-e.UEPreCaptureTimeMs,r=e.UEPostCaptureTimeMs-e.UEPreCaptureTimeMs,i=e.UEPostEncodeTimeMs-e.UEPreEncodeTimeMs,o=e.UETransmissionTimeMs-e.UEReceiptTimeMs,a=t-o,s=t-a-o,c=null,u=null;e.FrameDisplayDeltaTimeMs&&e.BrowserReceiptTimeMs&&(c=e.FrameDisplayDeltaTimeMs+t,u=c-a-o);var f="";f+="
Net latency RTT (ms): ".concat(a,"
"),f+="
UE Capture+Encode (ms): ".concat(n,"
"),f+="
UE Capture (ms): ".concat(r,"
"),f+="
UE Encode (ms): ".concat(i,"
"),f+="
Total UE latency (ms): ".concat(o,"
"),f+="
Browser send latency (ms): ".concat(s,"
"),f+=e.FrameDisplayDeltaTimeMs&&e.BrowserReceiptTimeMs?"
Browser receive latency (ms): ".concat(e.FrameDisplayDeltaTimeMs,"
"):"",f+=u?"
Total browser latency (ms): ".concat(u,"
"):"",f+="
Total latency (excluding browser) (ms): ".concat(t,"
"),f+=c?"
Total latency (ms): ".concat(c,"
"):"",document.getElementById("LatencyStats").innerHTML=f}}}function ce(e){v&&v.handleCandidateFromServer(e)}var ue,fe,de="default",pe={LockedMouse:0,HoveringMouse:1},le={controlScheme:pe.LockedMouse,suppressBrowserKeys:!0,fakeMouseWithTouches:!1};function he(e){var t=e.getElementsByTagName("VIDEO"),n=window.innerHeight/window.innerWidth,r=e.clientHeight/e.clientWidth,i=t.videoHeight/t.videoWidth;isNaN(i)?(ee=window.innerWidth,te=window.innerHeight,ne=0,re=0,e.style="top: "+ne+"px; left: "+re+"px; width: "+ee+"px; height: "+te+"px; cursor: "+de+"; "+ue):n0){ee=t[0].videoWidth,te=t[0].videoHeight;var n=Math.floor(.5*(window.innerHeight-te)),r=Math.floor(.5*(window.innerWidth-ee));ne=n>0?n:0,re=r>0?r:0,e.style="top: "+ne+"px; left: "+re+"px; width: "+ee+"px; height: "+te+"px; cursor: "+de+"; "+ue}}function ge(e){e.getElementsByTagName("VIDEO");e.style="top: 0px; left: 0px; width: "+ee+"px; height: "+te+"px; cursor: "+de+"; "+ue}function ye(){T=document.createElement("div"),T.id="freezeFrameOverlay",T.style.display="none",T.style.pointerEvents="none",T.style.position="absolute",T.style.zIndex="20";var e=document.createElement("img");e.style.position="absolute",T.appendChild(e)}function ve(){k.valid&&(T.classList.add("freezeframeBackground"),T.style.display="block")}function be(){T.style.display="none",k.valid=!1,T.classList.remove("freezeframeBackground"),v&&v.setVideoEnabled(!0)}function we(){if(0!==k.width&&0!==k.height){var e=0,t=0,n=0,r=0,i=document.getElementById("enlarge-display-to-fill-window-tgl"),o=document.getElementById("player");if(null!==i&&i.checked){var a=window.innerWidth/window.innerHeight,s=k.width/k.height;a1e3){var t=document.getElementById("player");if(!t)return;var n={Console:"setres "+t.clientWidth+"x"+t.clientHeight};ke(n),S=(new Date).getTime()}else clearTimeout(a),a=setTimeout(Se,1e3)}}function Ee(e){clearTimeout(fe),fe=setTimeout((function(){Ce()}),500)}var Te={IFrameRequest:0,RequestQualityControl:1,MaxFpsRequest:2,AverageBitrateRequest:3,StartStreaming:4,StopStreaming:5,LatencyTest:6,RequestInitialSettings:7,UIInteraction:50,Command:51,KeyDown:60,KeyUp:61,KeyPress:62,MouseEnter:70,MouseLeave:71,MouseDown:72,MouseUp:73,MouseMove:74,MouseWheel:75,TouchStart:80,TouchEnd:81,TouchMove:82,GamepadButtonPressed:90,GamepadButtonReleased:91,GamepadAnalog:92};function Re(e,t){var n=JSON.stringify(t),r=new DataView(new ArrayBuffer(3+2*n.length)),i=0;r.setUint8(i,e),i++,r.setUint16(i,n.length,!0),i+=2;for(var o=0;o0){var n=e.clientHeight/e.clientWidth,r=t[0].videoHeight/t[0].videoWidth;if(n>r){var i=n/r;Oe=function(t,n){var r=t/e.clientWidth,o=i*(n/e.clientHeight-.5)+.5;return r<0||r>1||o<0||o>1?{inRange:!1,x:65535,y:65535}:{inRange:!0,x:65536*r,y:65536*o}},Me=function(t,n){var r=t/65536,o=(n/65536-.5)/i+.5;return{x:r*e.clientWidth,y:o*e.clientHeight}},De=function(t,n){var r=t/(.5*e.clientWidth),o=i*n/(.5*e.clientHeight);return{x:32767*r,y:32767*o}}}else{var o=r/n;Oe=function(t,n){var r=o*(t/e.clientWidth-.5)+.5,i=n/e.clientHeight;return r<0||r>1||i<0||i>1?{inRange:!1,x:65535,y:65535}:{inRange:!0,x:65536*r,y:65536*i}},Me=function(t,n){var r=(t/65536-.5)/o+.5,i=n/65536;return{x:r*e.clientWidth,y:i*e.clientHeight}},De=function(t,n){var r=o*t/(.5*e.clientWidth),i=n/(.5*e.clientHeight);return{x:32767*r,y:32767*i}}}}}function Fe(e,t,n,r){var i=Oe(e,t),o=De(n,r),a=new DataView(new ArrayBuffer(9));a.setUint8(0,Te.MouseMove),a.setUint16(1,i.x,!0),a.setUint16(3,i.y,!0),a.setInt16(5,o.x,!0),a.setInt16(7,o.y,!0),Z(a.buffer)}function Ue(e,t,n){var r=Oe(t,n),i=new DataView(new ArrayBuffer(6));i.setUint8(0,Te.MouseDown),i.setUint8(1,e),i.setUint16(2,r.x,!0),i.setUint16(4,r.y,!0),Z(i.buffer)}function Le(e,t,n){var r=Oe(t,n),i=new DataView(new ArrayBuffer(6));i.setUint8(0,Te.MouseUp),i.setUint8(1,e),i.setUint16(2,r.x,!0),i.setUint16(4,r.y,!0),Z(i.buffer)}function je(e,t,n){var r=Oe(t,n),i=new DataView(new ArrayBuffer(7));i.setUint8(0,Te.MouseWheel),i.setInt16(1,e,!0),i.setUint16(3,r.x,!0),i.setUint16(5,r.y,!0),Z(i.buffer)}var _e={MainButton:0,AuxiliaryButton:1,SecondaryButton:2,FourthButton:3,FifthButton:4},Ne={PrimaryButton:1,SecondaryButton:2,AuxiliaryButton:4,FourthButton:8,FifthButton:16};function He(e,t,n){e&Ne.PrimaryButton&&Le(_e.MainButton,t,n),e&Ne.SecondaryButton&&Le(_e.SecondaryButton,t,n),e&Ne.AuxiliaryButton&&Le(_e.AuxiliaryButton,t,n),e&Ne.FourthButton&&Le(_e.FourthButton,t,n),e&Ne.FifthButton&&Le(_e.FifthButton,t,n)}function Qe(e,t,n){e&Ne.PrimaryButton&&Ue(_e.MainButton,t,n),e&Ne.SecondaryButton&&Ue(_e.SecondaryButton,t,n),e&Ne.AuxiliaryButton&&Ue(_e.AuxiliaryButton,t,n),e&Ne.FourthButton&&Ue(_e.FourthButton,t,n),e&Ne.FifthButton&&Ue(_e.FifthButton,t,n)}function qe(e){e&&(Xe(e),Ge(e))}function We(e){null===document.getElementById("hiddenInput")&&(B=document.createElement("input"),B.id="hiddenInput",B.maxLength=0,null===e||void 0===e||e.appendChild(B)),null===document.getElementById("editTextButton")&&(P=document.createElement("button"),P.id="editTextButton",P.innerHTML="edit text",null===e||void 0===e||e.appendChild(P),P.classList.add("hiddenState"),P.addEventListener("click",(function(){B.focus()})))}function Je(e){if(e.showOnScreenKeyboard){P.classList.remove("hiddenState");var t=Me(e.x,e.y);P.style.top=t.y.toString()+"px",P.style.left=(t.x-40).toString()+"px"}else P.classList.add("hiddenState"),B.blur()}function Xe(e){e.onmouseenter=function(t){var n=new DataView(new ArrayBuffer(1));n.setUint8(0,Te.MouseEnter),Z(n.buffer),e.pressMouseButtons(t)},e.onmouseleave=function(t){var n=new DataView(new ArrayBuffer(1));n.setUint8(0,Te.MouseLeave),Z(n.buffer),e.releaseMouseButtons(t)}}function ze(e){var t=e.width/2,n=e.height/2;function r(){document.pointerLockElement===e||document.mozPointerLockElement===e?document.addEventListener("mousemove",i,!1):document.removeEventListener("mousemove",i,!1)}function i(e){t+=e.movementX,n+=e.movementY,t>ee&&(t-=ee),n>te&&(n-=te),t<0&&(t=ee+t),n<0&&(n=te-n),Fe(t,n,e.movementX,e.movementY)}e.requestPointerLock=e.requestPointerLock||e.mozRequestPointerLock,document.exitPointerLock=document.exitPointerLock||document.mozExitPointerLock,e.onclick=function(){e.requestPointerLock()},document.addEventListener("pointerlockchange",r,!1),document.addEventListener("mozpointerlockchange",r,!1),e.onmousedown=function(e){Ue(e.button,t,n)},e.onmouseup=function(e){Le(e.button,t,n)},e.onmousewheel=function(e){je(e.wheelDelta,t,n)},e.pressMouseButtons=function(e){Qe(e.buttons,t,n)},e.releaseMouseButtons=function(e){He(e.buttons,t,n)}}function Ye(e){de="none",e.onmousemove=function(e){Fe(e.offsetX,e.offsetY,e.movementX,e.movementY),e.preventDefault()},e.onmousedown=function(e){Ue(e.button,e.offsetX,e.offsetY),e.preventDefault()},e.onmouseup=function(e){Le(e.button,e.offsetX,e.offsetY),e.preventDefault()},e.oncontextmenu=function(e){Le(e.button,e.offsetX,e.offsetY),e.preventDefault()},"onmousewheel"in e?e.onmousewheel=function(e){je(e.wheelDelta,e.offsetX,e.offsetY),e.preventDefault()}:e.addEventListener("DOMMouseScroll",(function(e){je(-120*e.detail,e.offsetX,e.offsetY),e.preventDefault()}),!1),e.pressMouseButtons=function(e){Qe(e.buttons,e.offsetX,e.offsetY)},e.releaseMouseButtons=function(e){He(e.buttons,e.offsetX,e.offsetY)}}function Ge(e){var t=[9,8,7,6,5,4,3,2,1,0],n={};function r(e){var r=t.pop();n[e.identifier]=r}function i(e){t.push(n[e.identifier]),delete n[e.identifier]}function o(t,r){var i=new DataView(new ArrayBuffer(2+7*r.length));i.setUint8(0,t),i.setUint8(1,r.length);for(var o=2,a=0;a=112&&e<=123||9===e}var Ve={BackSpace:8,Shift:16,Control:17,Alt:18,RightShift:253,RightControl:254,RightAlt:255};function Ze(e){return e.keyCode===Ve.Shift&&"ShiftRight"===e.code?Ve.RightShift:e.keyCode===Ve.Control&&"ControlRight"===e.code?Ve.RightControl:e.keyCode===Ve.Alt&&"AltRight"===e.code?Ve.RightAlt:e.keyCode}function $e(){document.onkeydown=function(e){Z(new Uint8Array([Te.KeyDown,Ze(e),e.repeat]).buffer),e.keyCode===Ve.BackSpace&&document.onkeypress({charCode:Ve.BackSpace}),le.suppressBrowserKeys&&Ke(e.keyCode)&&e.preventDefault()},document.onkeyup=function(e){Z(new Uint8Array([Te.KeyUp,Ze(e)]).buffer),le.suppressBrowserKeys&&Ke(e.keyCode)&&e.preventDefault()},document.onkeypress=function(e){var t=new DataView(new ArrayBuffer(3));t.setUint8(0,Te.KeyPress),t.setUint16(1,e.charCode,!0),Z(t.buffer)}}function et(){var e=document.getElementById("qualityStatus");e&&(e.className="grey-status");var t=document.getElementById("stats");t&&(t.innerHTML="Not connected"),!w||C?(nt(),be(),R=!0,Ce()):nt(),tt(0)}function tt(e){var t=document.getElementById("kick-other-players-button");t&&(t.value="Kick (".concat(e,")"))}function nt(){window.WebSocket=window.WebSocket||window.MozWebSocket,window.WebSocket?(r=new WebSocket(f.replace("http://","ws://").replace("https://","wss://")),r.onmessage=function(e){var t=JSON.parse(e.data);"config"===t.type?rt(t):"playerCount"===t.type?tt(t.count-1):"answer"===t.type?se(t):"iceCandidate"===t.type&&ce(t.candidate)},r.onerror=function(e){},r.onclose=function(e){p=!1}):alert("Your browser doesn't support WebSocket")}function rt(e){var t=document.getElementById("player"),n=ae(t,e);switch(Ce(),le.controlScheme){case pe.HoveringMouse:Ye(n);break;case pe.LockedMouse:ze(n);break;default:ze(n);break}}function it(e){f=e,_(),ye(),$e(),et()}function ot(){var e;null===(e=r)||void 0===e||e.close()}},e3db:function(e,t){var n={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==n.call(e)}},e4b1:function(e,t){var n=1e3,r=60*n,i=60*r,o=24*i,a=365.25*o;function s(e){if(e=String(e),!(e.length>100)){var t=/^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec(e);if(t){var s=parseFloat(t[1]),c=(t[2]||"ms").toLowerCase();switch(c){case"years":case"year":case"yrs":case"yr":case"y":return s*a;case"days":case"day":case"d":return s*o;case"hours":case"hour":case"hrs":case"hr":case"h":return s*i;case"minutes":case"minute":case"mins":case"min":case"m":return s*r;case"seconds":case"second":case"secs":case"sec":case"s":return s*n;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return s;default:return}}}}function c(e){return e>=o?Math.round(e/o)+"d":e>=i?Math.round(e/i)+"h":e>=r?Math.round(e/r)+"m":e>=n?Math.round(e/n)+"s":e+"ms"}function u(e){return f(e,o,"day")||f(e,i,"hour")||f(e,r,"minute")||f(e,n,"second")||e+" ms"}function f(e,t,n){if(!(e0)return s(e);if("number"===n&&!1===isNaN(e))return t.long?u(e):c(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},e4cd:function(e,t,n){(function(r){function i(){return!("undefined"===typeof window||!window.process||"renderer"!==window.process.type)||("undefined"===typeof navigator||!navigator.userAgent||!navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))&&("undefined"!==typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!==typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!==typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!==typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))}function o(e){var n=this.useColors;if(e[0]=(n?"%c":"")+this.namespace+(n?" %c":" ")+e[0]+(n?"%c ":" ")+"+"+t.humanize(this.diff),n){var r="color: "+this.color;e.splice(1,0,r,"color: inherit");var i=0,o=0;e[0].replace(/%[a-zA-Z%]/g,(function(e){"%%"!==e&&(i++,"%c"===e&&(o=i))})),e.splice(o,0,r)}}function a(){return"object"===typeof console&&console.log&&Function.prototype.apply.call(console.log,console,arguments)}function s(e){try{null==e?t.storage.removeItem("debug"):t.storage.debug=e}catch(n){}}function c(){var e;try{e=t.storage.debug}catch(n){}return!e&&"undefined"!==typeof r&&"env"in r&&(e=Object({VUE_APP_HTTP_URL:"http://frps.retailwell.com:20068",VUE_APP_Live_URL:"http://metaplayer.sxkj.com/ws",VUE_APP_Iframe_URL:"http://metaplayer.sxkj.com",NODE_ENV:"production",BASE_URL:"/"}).DEBUG),e}function u(){try{return window.localStorage}catch(e){}}t=e.exports=n("36ae"),t.log=a,t.formatArgs=o,t.save=s,t.load=c,t.useColors=i,t.storage="undefined"!=typeof chrome&&"undefined"!=typeof chrome.storage?chrome.storage.local:u(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],t.formatters.j=function(e){try{return JSON.stringify(e)}catch(t){return"[UnexpectedJSONParseError]: "+t.message}},t.enable(c())}).call(this,n("4362"))},e58c:function(e,t,n){"use strict";var r=n("fc6a"),i=n("a691"),o=n("50c4"),a=n("a640"),s=n("ae40"),c=Math.min,u=[].lastIndexOf,f=!!u&&1/[1].lastIndexOf(1,-0)<0,d=a("lastIndexOf"),p=s("indexOf",{ACCESSORS:!0,1:0}),l=f||!d||!p;e.exports=l?function(e){if(f)return u.apply(this,arguments)||0;var t=r(this),n=o(t.length),a=n-1;for(arguments.length>1&&(a=c(a,i(arguments[1]))),a<0&&(a=n+a);a>=0;a--)if(a in t&&t[a]===e)return a||0;return-1}:u},e683:function(e,t,n){"use strict";e.exports=function(e,t){return t?e.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,""):e}},e82e:function(e,t){var n={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==n.call(e)}},e91f:function(e,t,n){"use strict";var r=n("ebb5"),i=n("4d64").indexOf,o=r.aTypedArray,a=r.exportTypedArrayMethod;a("indexOf",(function(e){return i(o(this),e,arguments.length>1?arguments[1]:void 0)}))},eb6a:function(e,t,n){e.exports=n.p+"img/记录1.a669498e.png"},ebb5:function(e,t,n){"use strict";var r,i=n("a981"),o=n("83ab"),a=n("da84"),s=n("861d"),c=n("5135"),u=n("f5df"),f=n("9112"),d=n("6eeb"),p=n("9bf2").f,l=n("e163"),h=n("d2bb"),m=n("b622"),g=n("90e3"),y=a.Int8Array,v=y&&y.prototype,b=a.Uint8ClampedArray,w=b&&b.prototype,C=y&&l(y),A=v&&l(v),S=Object.prototype,E=S.isPrototypeOf,T=m("toStringTag"),R=g("TYPED_ARRAY_TAG"),k=i&&!!h&&"Opera"!==u(a.opera),x=!1,P={Int8Array:1,Uint8Array:1,Uint8ClampedArray:1,Int16Array:2,Uint16Array:2,Int32Array:4,Uint32Array:4,Float32Array:4,Float64Array:8},B=function(e){var t=u(e);return"DataView"===t||c(P,t)},O=function(e){return s(e)&&c(P,u(e))},D=function(e){if(O(e))return e;throw TypeError("Target is not a typed array")},M=function(e){if(h){if(E.call(C,e))return e}else for(var t in P)if(c(P,r)){var n=a[t];if(n&&(e===n||E.call(n,e)))return e}throw TypeError("Target is not a typed array constructor")},I=function(e,t,n){if(o){if(n)for(var r in P){var i=a[r];i&&c(i.prototype,e)&&delete i.prototype[e]}A[e]&&!n||d(A,e,n?t:k&&v[e]||t)}},F=function(e,t,n){var r,i;if(o){if(h){if(n)for(r in P)i=a[r],i&&c(i,e)&&delete i[e];if(C[e]&&!n)return;try{return d(C,e,n?t:k&&y[e]||t)}catch(s){}}for(r in P)i=a[r],!i||i[e]&&!n||d(i,e,t)}};for(r in P)a[r]||(k=!1);if((!k||"function"!=typeof C||C===Function.prototype)&&(C=function(){throw TypeError("Incorrect invocation")},k))for(r in P)a[r]&&h(a[r],C);if((!k||!A||A===S)&&(A=C.prototype,k))for(r in P)a[r]&&h(a[r].prototype,A);if(k&&l(w)!==A&&h(w,A),o&&!c(A,T))for(r in x=!0,p(A,T,{get:function(){return s(this)?this[R]:void 0}}),P)a[r]&&f(a[r],R,r);e.exports={NATIVE_ARRAY_BUFFER_VIEWS:k,TYPED_ARRAY_TAG:x&&R,aTypedArray:D,aTypedArrayConstructor:M,exportTypedArrayMethod:I,exportTypedArrayStaticMethod:F,isView:B,isTypedArray:O,TypedArray:C,TypedArrayPrototype:A}},ee34:function(e,t){var n=[].indexOf;e.exports=function(e,t){if(n)return e.indexOf(t);for(var r=0;r