/*! @preserve * AgoraRTM Web SDK 1.2.2 - commit: v1.2.2-0-gb428acc * Copyright (C) 2018-2020 Agora Lab. * This file is licensed under the AGORA, INC. SDK LICENSE AGREEMENT * A copy of this license may be found at https://www.agora.io/en/sdk-license-agreement/ */ !function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e=e||self).AgoraRTM=t()}(this,function(){"use strict";var commonjsGlobal="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function unwrapExports(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function createCommonjsModule(e,t){return e(t={exports:{}},t.exports),t.exports}var _global=createCommonjsModule(function(e){var t=e.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=t)}),_core=createCommonjsModule(function(e){var t=e.exports={version:"2.6.9"};"number"==typeof __e&&(__e=t)}),_core_1=_core.version,_isObject=function(e){return"object"==typeof e?null!==e:"function"==typeof e},_anObject=function(e){if(!_isObject(e))throw TypeError(e+" is not an object!");return e},_fails=function(e){try{return!!e()}catch(e){return!0}},_descriptors=!_fails(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a}),document$1=_global.document,is=_isObject(document$1)&&_isObject(document$1.createElement),_domCreate=function(e){return is?document$1.createElement(e):{}},_ie8DomDefine=!_descriptors&&!_fails(function(){return 7!=Object.defineProperty(_domCreate("div"),"a",{get:function(){return 7}}).a}),_toPrimitive=function(e,t){if(!_isObject(e))return e;var r,n;if(t&&"function"==typeof(r=e.toString)&&!_isObject(n=r.call(e)))return n;if("function"==typeof(r=e.valueOf)&&!_isObject(n=r.call(e)))return n;if(!t&&"function"==typeof(r=e.toString)&&!_isObject(n=r.call(e)))return n;throw TypeError("Can't convert object to primitive value")},dP=Object.defineProperty,f=_descriptors?Object.defineProperty:function(e,t,r){if(_anObject(e),t=_toPrimitive(t,!0),_anObject(r),_ie8DomDefine)try{return dP(e,t,r)}catch(e){}if("get"in r||"set"in r)throw TypeError("Accessors not supported!");return"value"in r&&(e[t]=r.value),e},_objectDp={f:f},_propertyDesc=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}},_hide=_descriptors?function(e,t,r){return _objectDp.f(e,t,_propertyDesc(1,r))}:function(e,t,r){return e[t]=r,e},hasOwnProperty={}.hasOwnProperty,_has=function(e,t){return hasOwnProperty.call(e,t)},id=0,px=Math.random(),_uid=function(e){return"Symbol(".concat(void 0===e?"":e,")_",(++id+px).toString(36))},_library=!1,_shared=createCommonjsModule(function(e){var t=_global["__core-js_shared__"]||(_global["__core-js_shared__"]={});(e.exports=function(e,r){return t[e]||(t[e]=void 0!==r?r:{})})("versions",[]).push({version:_core.version,mode:"global",copyright:"© 2019 Denis Pushkarev (zloirock.ru)"})}),_functionToString=_shared("native-function-to-string",Function.toString),_redefine=createCommonjsModule(function(e){var t=_uid("src"),r=(""+_functionToString).split("toString");_core.inspectSource=function(e){return _functionToString.call(e)},(e.exports=function(e,n,o,i){var s="function"==typeof o;s&&(_has(o,"name")||_hide(o,"name",n)),e[n]!==o&&(s&&(_has(o,t)||_hide(o,t,e[n]?""+e[n]:r.join(String(n)))),e===_global?e[n]=o:i?e[n]?e[n]=o:_hide(e,n,o):(delete e[n],_hide(e,n,o)))})(Function.prototype,"toString",function(){return"function"==typeof this&&this[t]||_functionToString.call(this)})}),_aFunction=function(e){if("function"!=typeof e)throw TypeError(e+" is not a function!");return e},_ctx=function(e,t,r){if(_aFunction(e),void 0===t)return e;switch(r){case 1:return function(r){return e.call(t,r)};case 2:return function(r,n){return e.call(t,r,n)};case 3:return function(r,n,o){return e.call(t,r,n,o)}}return function(){return e.apply(t,arguments)}},PROTOTYPE="prototype",$export=function(e,t,r){var n,o,i,s,a=e&$export.F,u=e&$export.G,l=e&$export.S,c=e&$export.P,p=e&$export.B,f=u?_global:l?_global[t]||(_global[t]={}):(_global[t]||{})[PROTOTYPE],d=u?_core:_core[t]||(_core[t]={}),g=d[PROTOTYPE]||(d[PROTOTYPE]={});for(n in u&&(r=t),r)i=((o=!a&&f&&void 0!==f[n])?f:r)[n],s=p&&o?_ctx(i,_global):c&&"function"==typeof i?_ctx(Function.call,i):i,f&&_redefine(f,n,i,e&$export.U),d[n]!=i&&_hide(d,n,s),c&&g[n]!=i&&(g[n]=i)};_global.core=_core,$export.F=1,$export.G=2,$export.S=4,$export.P=8,$export.B=16,$export.W=32,$export.U=64,$export.R=128;var _export=$export,toString={}.toString,_cof=function(e){return toString.call(e).slice(8,-1)},_iobject=Object("z").propertyIsEnumerable(0)?Object:function(e){return"String"==_cof(e)?e.split(""):Object(e)},_defined=function(e){if(null==e)throw TypeError("Can't call method on "+e);return e},_toIobject=function(e){return _iobject(_defined(e))},ceil=Math.ceil,floor=Math.floor,_toInteger=function(e){return isNaN(e=+e)?0:(e>0?floor:ceil)(e)},min=Math.min,_toLength=function(e){return e>0?min(_toInteger(e),9007199254740991):0},max=Math.max,min$1=Math.min,_toAbsoluteIndex=function(e,t){return(e=_toInteger(e))<0?max(e+t,0):min$1(e,t)},_arrayIncludes=function(e){return function(t,r,n){var o,i=_toIobject(t),s=_toLength(i.length),a=_toAbsoluteIndex(n,s);if(e&&r!=r){for(;s>a;)if((o=i[a++])!=o)return!0}else for(;s>a;a++)if((e||a in i)&&i[a]===r)return e||a||0;return!e&&-1}},shared=_shared("keys"),_sharedKey=function(e){return shared[e]||(shared[e]=_uid(e))},arrayIndexOf=_arrayIncludes(!1),IE_PROTO=_sharedKey("IE_PROTO"),_objectKeysInternal=function(e,t){var r,n=_toIobject(e),o=0,i=[];for(r in n)r!=IE_PROTO&&_has(n,r)&&i.push(r);for(;t.length>o;)_has(n,r=t[o++])&&(~arrayIndexOf(i,r)||i.push(r));return i},_enumBugKeys="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(","),_objectKeys=Object.keys||function(e){return _objectKeysInternal(e,_enumBugKeys)},f$1={}.propertyIsEnumerable,_objectPie={f:f$1},isEnum=_objectPie.f,_objectToArray=function(e){return function(t){for(var r,n=_toIobject(t),o=_objectKeys(n),i=o.length,s=0,a=[];i>s;)r=o[s++],_descriptors&&!isEnum.call(n,r)||a.push(e?[r,n[r]]:n[r]);return a}},$entries=_objectToArray(!0);_export(_export.S,"Object",{entries:function(e){return $entries(e)}});var _stringRepeat=function(e){var t=String(_defined(this)),r="",n=_toInteger(e);if(n<0||n==1/0)throw RangeError("Count can't be negative");for(;n>0;(n>>>=1)&&(t+=t))1&n&&(r+=t);return r},_stringPad=function(e,t,r,n){var o=String(_defined(e)),i=o.length,s=void 0===r?" ":String(r),a=_toLength(t);if(a<=i||""==s)return o;var u=a-i,l=_stringRepeat.call(s,Math.ceil(u/s.length));return l.length>u&&(l=l.slice(0,u)),n?l+o:o+l},navigator$1=_global.navigator,_userAgent=navigator$1&&navigator$1.userAgent||"",WEBKIT_BUG=/Version\/10\.\d+(\.\d+)?( Mobile\/\w+)? Safari\//.test(_userAgent);_export(_export.P+_export.F*WEBKIT_BUG,"String",{padEnd:function(e){return _stringPad(this,e,arguments.length>1?arguments[1]:void 0,!1)}});var WEBKIT_BUG$1=/Version\/10\.\d+(\.\d+)?( Mobile\/\w+)? Safari\//.test(_userAgent);_export(_export.P+_export.F*WEBKIT_BUG$1,"String",{padStart:function(e){return _stringPad(this,e,arguments.length>1?arguments[1]:void 0,!0)}});var _wks=createCommonjsModule(function(e){var t=_shared("wks"),r=_global.Symbol,n="function"==typeof r;(e.exports=function(e){return t[e]||(t[e]=n&&r[e]||(n?r:_uid)("Symbol."+e))}).store=t}),MATCH=_wks("match"),_isRegexp=function(e){var t;return _isObject(e)&&(void 0!==(t=e[MATCH])?!!t:"RegExp"==_cof(e))},_stringContext=function(e,t,r){if(_isRegexp(t))throw TypeError("String#"+r+" doesn't accept regex!");return String(_defined(e))},MATCH$1=_wks("match"),_failsIsRegexp=function(e){var t=/./;try{"/./"[e](t)}catch(r){try{return t[MATCH$1]=!1,!"/./"[e](t)}catch(e){}}return!0},STARTS_WITH="startsWith",$startsWith=""[STARTS_WITH];_export(_export.P+_export.F*_failsIsRegexp(STARTS_WITH),"String",{startsWith:function(e){var t=_stringContext(this,e,STARTS_WITH),r=_toLength(Math.min(arguments.length>1?arguments[1]:void 0,t.length)),n=String(e);return $startsWith?$startsWith.call(t,n,r):t.slice(r,r+n.length)===n}});var ENDS_WITH="endsWith",$endsWith=""[ENDS_WITH];_export(_export.P+_export.F*_failsIsRegexp(ENDS_WITH),"String",{endsWith:function(e){var t=_stringContext(this,e,ENDS_WITH),r=arguments.length>1?arguments[1]:void 0,n=_toLength(t.length),o=void 0===r?n:Math.min(_toLength(r),n),i=String(e);return $endsWith?$endsWith.call(t,i,o):t.slice(o-i.length,o)===i}});var UNSCOPABLES=_wks("unscopables"),ArrayProto=Array.prototype;null==ArrayProto[UNSCOPABLES]&&_hide(ArrayProto,UNSCOPABLES,{});var _addToUnscopables=function(e){ArrayProto[UNSCOPABLES][e]=!0},$includes=_arrayIncludes(!0);_export(_export.P,"Array",{includes:function(e){return $includes(this,e,arguments.length>1?arguments[1]:void 0)}}),_addToUnscopables("includes");var _toObject=function(e){return Object(_defined(e))},_iterCall=function(e,t,r,n){try{return n?t(_anObject(r)[0],r[1]):t(r)}catch(t){var o=e.return;throw void 0!==o&&_anObject(o.call(e)),t}},_iterators={},ITERATOR=_wks("iterator"),ArrayProto$1=Array.prototype,_isArrayIter=function(e){return void 0!==e&&(_iterators.Array===e||ArrayProto$1[ITERATOR]===e)},_createProperty=function(e,t,r){t in e?_objectDp.f(e,t,_propertyDesc(0,r)):e[t]=r},TAG=_wks("toStringTag"),ARG="Arguments"==_cof(function(){return arguments}()),tryGet=function(e,t){try{return e[t]}catch(e){}},_classof=function(e){var t,r,n;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(r=tryGet(t=Object(e),TAG))?r:ARG?_cof(t):"Object"==(n=_cof(t))&&"function"==typeof t.callee?"Arguments":n},ITERATOR$1=_wks("iterator"),core_getIteratorMethod=_core.getIteratorMethod=function(e){if(null!=e)return e[ITERATOR$1]||e["@@iterator"]||_iterators[_classof(e)]},ITERATOR$2=_wks("iterator"),SAFE_CLOSING=!1;try{var riter=[7][ITERATOR$2]();riter.return=function(){SAFE_CLOSING=!0},Array.from(riter,function(){throw 2})}catch(e){}var _iterDetect=function(e,t){if(!t&&!SAFE_CLOSING)return!1;var r=!1;try{var n=[7],o=n[ITERATOR$2]();o.next=function(){return{done:r=!0}},n[ITERATOR$2]=function(){return o},e(n)}catch(e){}return r};_export(_export.S+_export.F*!_iterDetect(function(e){Array.from(e)}),"Array",{from:function(e){var t,r,n,o,i=_toObject(e),s="function"==typeof this?this:Array,a=arguments.length,u=a>1?arguments[1]:void 0,l=void 0!==u,c=0,p=core_getIteratorMethod(i);if(l&&(u=_ctx(u,a>2?arguments[2]:void 0,2)),null==p||s==Array&&_isArrayIter(p))for(r=new s(t=_toLength(i.length));t>c;c++)_createProperty(r,c,l?u(i[c],c):i[c]);else for(o=p.call(i),r=new s;!(n=o.next()).done;c++)_createProperty(r,c,l?_iterCall(o,u,[n.value,c],!0):n.value);return r.length=c,r}});var INCLUDES="includes";_export(_export.P+_export.F*_failsIsRegexp(INCLUDES),"String",{includes:function(e){return!!~_stringContext(this,e,INCLUDES).indexOf(e,arguments.length>1?arguments[1]:void 0)}});var _sameValue=Object.is||function(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t},builtinExec=RegExp.prototype.exec,_regexpExecAbstract=function(e,t){var r=e.exec;if("function"==typeof r){var n=r.call(e,t);if("object"!=typeof n)throw new TypeError("RegExp exec method returned something other than an Object or null");return n}if("RegExp"!==_classof(e))throw new TypeError("RegExp#exec called on incompatible receiver");return builtinExec.call(e,t)},_flags=function(){var e=_anObject(this),t="";return e.global&&(t+="g"),e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),e.unicode&&(t+="u"),e.sticky&&(t+="y"),t},nativeExec=RegExp.prototype.exec,nativeReplace=String.prototype.replace,patchedExec=nativeExec,LAST_INDEX="lastIndex",UPDATES_LAST_INDEX_WRONG=function(){var e=/a/,t=/b*/g;return nativeExec.call(e,"a"),nativeExec.call(t,"a"),0!==e[LAST_INDEX]||0!==t[LAST_INDEX]}(),NPCG_INCLUDED=void 0!==/()??/.exec("")[1],PATCH=UPDATES_LAST_INDEX_WRONG||NPCG_INCLUDED;PATCH&&(patchedExec=function(e){var t,r,n,o,i=this;return NPCG_INCLUDED&&(r=new RegExp("^"+i.source+"$(?!\\s)",_flags.call(i))),UPDATES_LAST_INDEX_WRONG&&(t=i[LAST_INDEX]),n=nativeExec.call(i,e),UPDATES_LAST_INDEX_WRONG&&n&&(i[LAST_INDEX]=i.global?n.index+n[0].length:t),NPCG_INCLUDED&&n&&n.length>1&&nativeReplace.call(n[0],r,function(){for(o=1;o")}),SPLIT_WORKS_WITH_OVERWRITTEN_EXEC=function(){var e=/(?:)/,t=e.exec;e.exec=function(){return t.apply(this,arguments)};var r="ab".split(e);return 2===r.length&&"a"===r[0]&&"b"===r[1]}(),_fixReWks=function(e,t,r){var n=_wks(e),o=!_fails(function(){var t={};return t[n]=function(){return 7},7!=""[e](t)}),i=o?!_fails(function(){var t=!1,r=/a/;return r.exec=function(){return t=!0,null},"split"===e&&(r.constructor={},r.constructor[SPECIES]=function(){return r}),r[n](""),!t}):void 0;if(!o||!i||"replace"===e&&!REPLACE_SUPPORTS_NAMED_GROUPS||"split"===e&&!SPLIT_WORKS_WITH_OVERWRITTEN_EXEC){var s=/./[n],a=r(_defined,n,""[e],function(e,t,r,n,i){return t.exec===_regexpExec?o&&!i?{done:!0,value:s.call(t,r,n)}:{done:!0,value:e.call(r,t,n)}:{done:!1}}),u=a[0],l=a[1];_redefine(String.prototype,e,u),_hide(RegExp.prototype,n,2==t?function(e,t){return l.call(e,this,t)}:function(e){return l.call(e,this)})}};_fixReWks("search",1,function(e,t,r,n){return[function(r){var n=e(this),o=null==r?void 0:r[t];return void 0!==o?o.call(r,n):new RegExp(r)[t](String(n))},function(e){var t=n(r,e,this);if(t.done)return t.value;var o=_anObject(e),i=String(this),s=o.lastIndex;_sameValue(s,0)||(o.lastIndex=0);var a=_regexpExecAbstract(o,i);return _sameValue(o.lastIndex,s)||(o.lastIndex=s),null===a?-1:a.index}]});var SPECIES$1=_wks("species"),_speciesConstructor=function(e,t){var r,n=_anObject(e).constructor;return void 0===n||null==(r=_anObject(n)[SPECIES$1])?t:_aFunction(r)},_stringAt=function(e){return function(t,r){var n,o,i=String(_defined(t)),s=_toInteger(r),a=i.length;return s<0||s>=a?e?"":void 0:(n=i.charCodeAt(s))<55296||n>56319||s+1===a||(o=i.charCodeAt(s+1))<56320||o>57343?e?i.charAt(s):n:e?i.slice(s,s+2):o-56320+(n-55296<<10)+65536}},at=_stringAt(!0),_advanceStringIndex=function(e,t,r){return t+(r?at(e,t).length:1)},$min=Math.min,$push=[].push,$SPLIT="split",LENGTH="length",LAST_INDEX$1="lastIndex",MAX_UINT32=4294967295,SUPPORTS_Y=!_fails(function(){RegExp(MAX_UINT32,"y")});_fixReWks("split",2,function(e,t,r,n){var o;return o="c"=="abbc"[$SPLIT](/(b)*/)[1]||4!="test"[$SPLIT](/(?:)/,-1)[LENGTH]||2!="ab"[$SPLIT](/(?:ab)*/)[LENGTH]||4!="."[$SPLIT](/(.?)(.?)/)[LENGTH]||"."[$SPLIT](/()()/)[LENGTH]>1||""[$SPLIT](/.?/)[LENGTH]?function(e,t){var n=String(this);if(void 0===e&&0===t)return[];if(!_isRegexp(e))return r.call(n,e,t);for(var o,i,s,a=[],u=(e.ignoreCase?"i":"")+(e.multiline?"m":"")+(e.unicode?"u":"")+(e.sticky?"y":""),l=0,c=void 0===t?MAX_UINT32:t>>>0,p=new RegExp(e.source,u+"g");(o=_regexpExec.call(p,n))&&!((i=p[LAST_INDEX$1])>l&&(a.push(n.slice(l,o.index)),o[LENGTH]>1&&o.index=c));)p[LAST_INDEX$1]===o.index&&p[LAST_INDEX$1]++;return l===n[LENGTH]?!s&&p.test("")||a.push(""):a.push(n.slice(l)),a[LENGTH]>c?a.slice(0,c):a}:"0"[$SPLIT](void 0,0)[LENGTH]?function(e,t){return void 0===e&&0===t?[]:r.call(this,e,t)}:r,[function(r,n){var i=e(this),s=null==r?void 0:r[t];return void 0!==s?s.call(r,i,n):o.call(String(i),r,n)},function(e,t){var i=n(o,e,this,t,o!==r);if(i.done)return i.value;var s=_anObject(e),a=String(this),u=_speciesConstructor(s,RegExp),l=s.unicode,c=(s.ignoreCase?"i":"")+(s.multiline?"m":"")+(s.unicode?"u":"")+(SUPPORTS_Y?"y":"g"),p=new u(SUPPORTS_Y?s:"^(?:"+s.source+")",c),f=void 0===t?MAX_UINT32:t>>>0;if(0===f)return[];if(0===a.length)return null===_regexpExecAbstract(p,a)?[a]:[];for(var d=0,g=0,h=[];gi;)_objectDp.f(e,r=n[i++],t[r]);return e},document$2=_global.document,_html=document$2&&document$2.documentElement,IE_PROTO$1=_sharedKey("IE_PROTO"),Empty=function(){},PROTOTYPE$1="prototype",createDict=function(){var e,t=_domCreate("iframe"),r=_enumBugKeys.length;for(t.style.display="none",_html.appendChild(t),t.src="javascript:",(e=t.contentWindow.document).open(),e.write("