trtc-sdk-v5 5.10.0-wasm.2 → 5.10.0-wasm.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,4 +1,4 @@
1
- var __create=Object.create,__defProp=Object.defineProperty,__defProps=Object.defineProperties,__getOwnPropDesc=Object.getOwnPropertyDescriptor,__getOwnPropDescs=Object.getOwnPropertyDescriptors,__getOwnPropNames=Object.getOwnPropertyNames,__getOwnPropSymbols=Object.getOwnPropertySymbols,__getProtoOf=Object.getPrototypeOf,__hasOwnProp=Object.prototype.hasOwnProperty,__propIsEnum=Object.prototype.propertyIsEnumerable,__defNormalProp=(e,t,V)=>t in e?__defProp(e,t,{enumerable:!0,configurable:!0,writable:!0,value:V}):e[t]=V,__spreadValues=(e,t)=>{for(var V in t||(t={}))__hasOwnProp.call(t,V)&&__defNormalProp(e,V,t[V]);if(__getOwnPropSymbols)for(var V of __getOwnPropSymbols(t))__propIsEnum.call(t,V)&&__defNormalProp(e,V,t[V]);return e},__spreadProps=(e,t)=>__defProps(e,__getOwnPropDescs(t)),__commonJS=(e,t)=>function(){return t||(0,e[__getOwnPropNames(e)[0]])((t={exports:{}}).exports,t),t.exports},__copyProps=(e,t,V,i)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let n of __getOwnPropNames(t))__hasOwnProp.call(e,n)||n===V||__defProp(e,n,{get:()=>t[n],enumerable:!(i=__getOwnPropDesc(t,n))||i.enumerable});return e},__toESM=(e,t,V)=>(V=null!=e?__create(__getProtoOf(e)):{},__copyProps(!t&&e&&e.__esModule?V:__defProp(V,"default",{value:e,enumerable:!0}),e)),__publicField=(e,t,V)=>__defNormalProp(e,"symbol"!=typeof t?t+"":t,V),require_global_this=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/global-this.js"(e,t){"use strict";var V=function(e){return e&&e.Math===Math&&e};t.exports=V("object"==typeof globalThis&&globalThis)||V("object"==typeof window&&window)||V("object"==typeof self&&self)||V("object"==typeof global&&global)||V("object"==typeof e&&e)||function(){return this}()||Function("return this")()}}),require_fails=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/fails.js"(e,t){"use strict";t.exports=function(e){try{return!!e()}catch(e){return!0}}}}),require_descriptors=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/descriptors.js"(e,t){"use strict";var V=require_fails();t.exports=!V((function(){return 7!==Object.defineProperty({},1,{get:function(){return 7}})[1]}))}}),require_function_bind_native=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/function-bind-native.js"(e,t){"use strict";var V=require_fails();t.exports=!V((function(){var e=function(){}.bind();return"function"!=typeof e||e.hasOwnProperty("prototype")}))}}),require_function_call=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/function-call.js"(e,t){"use strict";var V=require_function_bind_native(),i=Function.prototype.call;t.exports=V?i.bind(i):function(){return i.apply(i,arguments)}}}),require_object_property_is_enumerable=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/object-property-is-enumerable.js"(e){"use strict";var t={}.propertyIsEnumerable,V=Object.getOwnPropertyDescriptor,i=V&&!t.call({1:2},1);e.f=i?function(e){var t=V(this,e);return!!t&&t.enumerable}:t}}),require_create_property_descriptor=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/create-property-descriptor.js"(e,t){"use strict";t.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}}}),require_function_uncurry_this=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/function-uncurry-this.js"(e,t){"use strict";var V=require_function_bind_native(),i=Function.prototype,n=i.call,A=V&&i.bind.bind(n,n);t.exports=V?A:function(e){return function(){return n.apply(e,arguments)}}}}),require_classof_raw=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/classof-raw.js"(e,t){"use strict";var V=require_function_uncurry_this(),i=V({}.toString),n=V("".slice);t.exports=function(e){return n(i(e),8,-1)}}}),require_indexed_object=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/indexed-object.js"(e,t){"use strict";var V=require_function_uncurry_this(),i=require_fails(),n=require_classof_raw(),A=Object,o=V("".split);t.exports=i((function(){return!A("z").propertyIsEnumerable(0)}))?function(e){return"String"===n(e)?o(e,""):A(e)}:A}}),require_is_null_or_undefined=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/is-null-or-undefined.js"(e,t){"use strict";t.exports=function(e){return null==e}}}),require_require_object_coercible=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/require-object-coercible.js"(e,t){"use strict";var V=require_is_null_or_undefined(),i=TypeError;t.exports=function(e){if(V(e))throw new i("Can't call method on "+e);return e}}}),require_to_indexed_object=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/to-indexed-object.js"(e,t){"use strict";var V=require_indexed_object(),i=require_require_object_coercible();t.exports=function(e){return V(i(e))}}}),require_is_callable=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/is-callable.js"(e,t){"use strict";var V="object"==typeof document&&document.all;t.exports=void 0===V&&void 0!==V?function(e){return"function"==typeof e||e===V}:function(e){return"function"==typeof e}}}),require_is_object=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/is-object.js"(e,t){"use strict";var V=require_is_callable();t.exports=function(e){return"object"==typeof e?null!==e:V(e)}}}),require_get_built_in=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/get-built-in.js"(e,t){"use strict";var V=require_global_this(),i=require_is_callable();t.exports=function(e,t){return arguments.length<2?(n=V[e],i(n)?n:void 0):V[e]&&V[e][t];var n}}}),require_object_is_prototype_of=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/object-is-prototype-of.js"(e,t){"use strict";var V=require_function_uncurry_this();t.exports=V({}.isPrototypeOf)}}),require_environment_user_agent=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/environment-user-agent.js"(e,t){"use strict";var V=require_global_this().navigator,i=V&&V.userAgent;t.exports=i?String(i):""}}),require_environment_v8_version=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/environment-v8-version.js"(e,t){"use strict";var V,i,n=require_global_this(),A=require_environment_user_agent(),o=n.process,r=n.Deno,s=o&&o.versions||r&&r.version,q=s&&s.v8;q&&(i=(V=q.split("."))[0]>0&&V[0]<4?1:+(V[0]+V[1])),!i&&A&&(!(V=A.match(/Edge\/(\d+)/))||V[1]>=74)&&(V=A.match(/Chrome\/(\d+)/))&&(i=+V[1]),t.exports=i}}),require_symbol_constructor_detection=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/symbol-constructor-detection.js"(e,t){"use strict";var V=require_environment_v8_version(),i=require_fails(),n=require_global_this().String;t.exports=!!Object.getOwnPropertySymbols&&!i((function(){var e=Symbol("symbol detection");return!n(e)||!(Object(e)instanceof Symbol)||!Symbol.sham&&V&&V<41}))}}),require_use_symbol_as_uid=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/use-symbol-as-uid.js"(e,t){"use strict";var V=require_symbol_constructor_detection();t.exports=V&&!Symbol.sham&&"symbol"==typeof Symbol.iterator}}),require_is_symbol=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/is-symbol.js"(e,t){"use strict";var V=require_get_built_in(),i=require_is_callable(),n=require_object_is_prototype_of(),A=require_use_symbol_as_uid(),o=Object;t.exports=A?function(e){return"symbol"==typeof e}:function(e){var t=V("Symbol");return i(t)&&n(t.prototype,o(e))}}}),require_try_to_string=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/try-to-string.js"(e,t){"use strict";var V=String;t.exports=function(e){try{return V(e)}catch(e){return"Object"}}}}),require_a_callable=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/a-callable.js"(e,t){"use strict";var V=require_is_callable(),i=require_try_to_string(),n=TypeError;t.exports=function(e){if(V(e))return e;throw new n(i(e)+" is not a function")}}}),require_get_method=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/get-method.js"(e,t){"use strict";var V=require_a_callable(),i=require_is_null_or_undefined();t.exports=function(e,t){var n=e[t];return i(n)?void 0:V(n)}}}),require_ordinary_to_primitive=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/ordinary-to-primitive.js"(e,t){"use strict";var V=require_function_call(),i=require_is_callable(),n=require_is_object(),A=TypeError;t.exports=function(e,t){var o,r;if("string"===t&&i(o=e.toString)&&!n(r=V(o,e)))return r;if(i(o=e.valueOf)&&!n(r=V(o,e)))return r;if("string"!==t&&i(o=e.toString)&&!n(r=V(o,e)))return r;throw new A("Can't convert object to primitive value")}}}),require_is_pure=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/is-pure.js"(e,t){"use strict";t.exports=!1}}),require_define_global_property=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/define-global-property.js"(e,t){"use strict";var V=require_global_this(),i=Object.defineProperty;t.exports=function(e,t){try{i(V,e,{value:t,configurable:!0,writable:!0})}catch(i){V[e]=t}return t}}}),require_shared_store=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/shared-store.js"(e,t){"use strict";var V=require_is_pure(),i=require_global_this(),n=require_define_global_property(),A="__core-js_shared__",o=t.exports=i[A]||n(A,{});(o.versions||(o.versions=[])).push({version:"3.38.1",mode:V?"pure":"global",copyright:"© 2014-2024 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.38.1/LICENSE",source:"https://github.com/zloirock/core-js"})}}),require_shared=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/shared.js"(e,t){"use strict";var V=require_shared_store();t.exports=function(e,t){return V[e]||(V[e]=t||{})}}}),require_to_object=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/to-object.js"(e,t){"use strict";var V=require_require_object_coercible(),i=Object;t.exports=function(e){return i(V(e))}}}),require_has_own_property=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/has-own-property.js"(e,t){"use strict";var V=require_function_uncurry_this(),i=require_to_object(),n=V({}.hasOwnProperty);t.exports=Object.hasOwn||function(e,t){return n(i(e),t)}}}),require_uid=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/uid.js"(e,t){"use strict";var V=require_function_uncurry_this(),i=0,n=Math.random(),A=V(1..toString);t.exports=function(e){return"Symbol("+(void 0===e?"":e)+")_"+A(++i+n,36)}}}),require_well_known_symbol=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/well-known-symbol.js"(e,t){"use strict";var V=require_global_this(),i=require_shared(),n=require_has_own_property(),A=require_uid(),o=require_symbol_constructor_detection(),r=require_use_symbol_as_uid(),s=V.Symbol,q=i("wks"),a=r?s.for||s:s&&s.withoutSetter||A;t.exports=function(e){return n(q,e)||(q[e]=o&&n(s,e)?s[e]:a("Symbol."+e)),q[e]}}}),require_to_primitive=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/to-primitive.js"(e,t){"use strict";var V=require_function_call(),i=require_is_object(),n=require_is_symbol(),A=require_get_method(),o=require_ordinary_to_primitive(),r=require_well_known_symbol(),s=TypeError,q=r("toPrimitive");t.exports=function(e,t){if(!i(e)||n(e))return e;var r,a=A(e,q);if(a){if(void 0===t&&(t="default"),r=V(a,e,t),!i(r)||n(r))return r;throw new s("Can't convert object to primitive value")}return void 0===t&&(t="number"),o(e,t)}}}),require_to_property_key=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/to-property-key.js"(e,t){"use strict";var V=require_to_primitive(),i=require_is_symbol();t.exports=function(e){var t=V(e,"string");return i(t)?t:t+""}}}),require_document_create_element=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/document-create-element.js"(e,t){"use strict";var V=require_global_this(),i=require_is_object(),n=V.document,A=i(n)&&i(n.createElement);t.exports=function(e){return A?n.createElement(e):{}}}}),require_ie8_dom_define=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/ie8-dom-define.js"(e,t){"use strict";var V=require_descriptors(),i=require_fails(),n=require_document_create_element();t.exports=!V&&!i((function(){return 7!==Object.defineProperty(n("div"),"a",{get:function(){return 7}}).a}))}}),require_object_get_own_property_descriptor=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/object-get-own-property-descriptor.js"(e){"use strict";var t=require_descriptors(),V=require_function_call(),i=require_object_property_is_enumerable(),n=require_create_property_descriptor(),A=require_to_indexed_object(),o=require_to_property_key(),r=require_has_own_property(),s=require_ie8_dom_define(),q=Object.getOwnPropertyDescriptor;e.f=t?q:function(e,t){if(e=A(e),t=o(t),s)try{return q(e,t)}catch(e){}if(r(e,t))return n(!V(i.f,e,t),e[t])}}}),require_v8_prototype_define_bug=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/v8-prototype-define-bug.js"(e,t){"use strict";var V=require_descriptors(),i=require_fails();t.exports=V&&i((function(){return 42!==Object.defineProperty((function(){}),"prototype",{value:42,writable:!1}).prototype}))}}),require_an_object=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/an-object.js"(e,t){"use strict";var V=require_is_object(),i=String,n=TypeError;t.exports=function(e){if(V(e))return e;throw new n(i(e)+" is not an object")}}}),require_object_define_property=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/object-define-property.js"(e){"use strict";var t=require_descriptors(),V=require_ie8_dom_define(),i=require_v8_prototype_define_bug(),n=require_an_object(),A=require_to_property_key(),o=TypeError,r=Object.defineProperty,s=Object.getOwnPropertyDescriptor,q="enumerable",a="configurable",c="writable";e.f=t?i?function(e,t,V){if(n(e),t=A(t),n(V),"function"==typeof e&&"prototype"===t&&"value"in V&&c in V&&!V[c]){var i=s(e,t);i&&i[c]&&(e[t]=V.value,V={configurable:a in V?V[a]:i[a],enumerable:q in V?V[q]:i[q],writable:!1})}return r(e,t,V)}:r:function(e,t,i){if(n(e),t=A(t),n(i),V)try{return r(e,t,i)}catch(e){}if("get"in i||"set"in i)throw new o("Accessors not supported");return"value"in i&&(e[t]=i.value),e}}}),require_create_non_enumerable_property=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/create-non-enumerable-property.js"(e,t){"use strict";var V=require_descriptors(),i=require_object_define_property(),n=require_create_property_descriptor();t.exports=V?function(e,t,V){return i.f(e,t,n(1,V))}:function(e,t,V){return e[t]=V,e}}}),require_function_name=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/function-name.js"(e,t){"use strict";var V=require_descriptors(),i=require_has_own_property(),n=Function.prototype,A=V&&Object.getOwnPropertyDescriptor,o=i(n,"name"),r=o&&"something"===function(){}.name,s=o&&(!V||V&&A(n,"name").configurable);t.exports={EXISTS:o,PROPER:r,CONFIGURABLE:s}}}),require_inspect_source=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/inspect-source.js"(e,t){"use strict";var V=require_function_uncurry_this(),i=require_is_callable(),n=require_shared_store(),A=V(Function.toString);i(n.inspectSource)||(n.inspectSource=function(e){return A(e)}),t.exports=n.inspectSource}}),require_weak_map_basic_detection=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/weak-map-basic-detection.js"(e,t){"use strict";var V=require_global_this(),i=require_is_callable(),n=V.WeakMap;t.exports=i(n)&&/native code/.test(String(n))}}),require_shared_key=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/shared-key.js"(e,t){"use strict";var V=require_shared(),i=require_uid(),n=V("keys");t.exports=function(e){return n[e]||(n[e]=i(e))}}}),require_hidden_keys=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/hidden-keys.js"(e,t){"use strict";t.exports={}}}),require_internal_state=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/internal-state.js"(e,t){"use strict";var V,i,n,A,o,r=require_weak_map_basic_detection(),s=require_global_this(),q=require_is_object(),a=require_create_non_enumerable_property(),c=require_has_own_property(),l=require_shared_store(),d=require_shared_key(),p=require_hidden_keys(),h="Object already initialized",g=s.TypeError,u=s.WeakMap;r||l.state?((A=l.state||(l.state=new u)).get=A.get,A.has=A.has,A.set=A.set,V=function(e,t){if(A.has(e))throw new g(h);return t.facade=e,A.set(e,t),t},i=function(e){return A.get(e)||{}},n=function(e){return A.has(e)}):(p[o=d("state")]=!0,V=function(e,t){if(c(e,o))throw new g(h);return t.facade=e,a(e,o,t),t},i=function(e){return c(e,o)?e[o]:{}},n=function(e){return c(e,o)}),t.exports={set:V,get:i,has:n,enforce:function(e){return n(e)?i(e):V(e,{})},getterFor:function(e){return function(t){var V;if(!q(t)||(V=i(t)).type!==e)throw new g("Incompatible receiver, "+e+" required");return V}}}}}),require_make_built_in=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/make-built-in.js"(e,t){"use strict";var V=require_function_uncurry_this(),i=require_fails(),n=require_is_callable(),A=require_has_own_property(),o=require_descriptors(),r=require_function_name().CONFIGURABLE,s=require_inspect_source(),q=require_internal_state(),a=q.enforce,c=q.get,l=String,d=Object.defineProperty,p=V("".slice),h=V("".replace),g=V([].join),u=o&&!i((function(){return 8!==d((function(){}),"length",{value:8}).length})),m=String(String).split("String"),E=t.exports=function(e,t,V){"Symbol("===p(l(t),0,7)&&(t="["+h(l(t),/^Symbol\(([^)]*)\).*$/,"$1")+"]"),V&&V.getter&&(t="get "+t),V&&V.setter&&(t="set "+t),(!A(e,"name")||r&&e.name!==t)&&(o?d(e,"name",{value:t,configurable:!0}):e.name=t),u&&V&&A(V,"arity")&&e.length!==V.arity&&d(e,"length",{value:V.arity});try{V&&A(V,"constructor")&&V.constructor?o&&d(e,"prototype",{writable:!1}):e.prototype&&(e.prototype=void 0)}catch(e){}var i=a(e);return A(i,"source")||(i.source=g(m,"string"==typeof t?t:"")),e};Function.prototype.toString=E((function(){return n(this)&&c(this).source||s(this)}),"toString")}}),require_define_built_in=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/define-built-in.js"(e,t){"use strict";var V=require_is_callable(),i=require_object_define_property(),n=require_make_built_in(),A=require_define_global_property();t.exports=function(e,t,o,r){r||(r={});var s=r.enumerable,q=void 0!==r.name?r.name:t;if(V(o)&&n(o,q,r),r.global)s?e[t]=o:A(t,o);else{try{r.unsafe?e[t]&&(s=!0):delete e[t]}catch(e){}s?e[t]=o:i.f(e,t,{value:o,enumerable:!1,configurable:!r.nonConfigurable,writable:!r.nonWritable})}return e}}}),require_math_trunc=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/math-trunc.js"(e,t){"use strict";var V=Math.ceil,i=Math.floor;t.exports=Math.trunc||function(e){var t=+e;return(t>0?i:V)(t)}}}),require_to_integer_or_infinity=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/to-integer-or-infinity.js"(e,t){"use strict";var V=require_math_trunc();t.exports=function(e){var t=+e;return t!=t||0===t?0:V(t)}}}),require_to_absolute_index=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/to-absolute-index.js"(e,t){"use strict";var V=require_to_integer_or_infinity(),i=Math.max,n=Math.min;t.exports=function(e,t){var A=V(e);return A<0?i(A+t,0):n(A,t)}}}),require_to_length=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/to-length.js"(e,t){"use strict";var V=require_to_integer_or_infinity(),i=Math.min;t.exports=function(e){var t=V(e);return t>0?i(t,9007199254740991):0}}}),require_length_of_array_like=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/length-of-array-like.js"(e,t){"use strict";var V=require_to_length();t.exports=function(e){return V(e.length)}}}),require_array_includes=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/array-includes.js"(e,t){"use strict";var V=require_to_indexed_object(),i=require_to_absolute_index(),n=require_length_of_array_like(),A=function(e){return function(t,A,o){var r=V(t),s=n(r);if(0===s)return!e&&-1;var q,a=i(o,s);if(e&&A!=A){for(;s>a;)if((q=r[a++])!=q)return!0}else for(;s>a;a++)if((e||a in r)&&r[a]===A)return e||a||0;return!e&&-1}};t.exports={includes:A(!0),indexOf:A(!1)}}}),require_object_keys_internal=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/object-keys-internal.js"(e,t){"use strict";var V=require_function_uncurry_this(),i=require_has_own_property(),n=require_to_indexed_object(),A=require_array_includes().indexOf,o=require_hidden_keys(),r=V([].push);t.exports=function(e,t){var V,s=n(e),q=0,a=[];for(V in s)!i(o,V)&&i(s,V)&&r(a,V);for(;t.length>q;)i(s,V=t[q++])&&(~A(a,V)||r(a,V));return a}}}),require_enum_bug_keys=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/enum-bug-keys.js"(e,t){"use strict";t.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]}}),require_object_get_own_property_names=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/object-get-own-property-names.js"(e){"use strict";var t=require_object_keys_internal(),V=require_enum_bug_keys().concat("length","prototype");e.f=Object.getOwnPropertyNames||function(e){return t(e,V)}}}),require_object_get_own_property_symbols=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/object-get-own-property-symbols.js"(e){"use strict";e.f=Object.getOwnPropertySymbols}}),require_own_keys=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/own-keys.js"(e,t){"use strict";var V=require_get_built_in(),i=require_function_uncurry_this(),n=require_object_get_own_property_names(),A=require_object_get_own_property_symbols(),o=require_an_object(),r=i([].concat);t.exports=V("Reflect","ownKeys")||function(e){var t=n.f(o(e)),V=A.f;return V?r(t,V(e)):t}}}),require_copy_constructor_properties=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/copy-constructor-properties.js"(e,t){"use strict";var V=require_has_own_property(),i=require_own_keys(),n=require_object_get_own_property_descriptor(),A=require_object_define_property();t.exports=function(e,t,o){for(var r=i(t),s=A.f,q=n.f,a=0;a<r.length;a++){var c=r[a];V(e,c)||o&&V(o,c)||s(e,c,q(t,c))}}}}),require_is_forced=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/is-forced.js"(e,t){"use strict";var V=require_fails(),i=require_is_callable(),n=/#|\.prototype\./,A=function(e,t){var n=r[o(e)];return n===q||n!==s&&(i(t)?V(t):!!t)},o=A.normalize=function(e){return String(e).replace(n,".").toLowerCase()},r=A.data={},s=A.NATIVE="N",q=A.POLYFILL="P";t.exports=A}}),require_export=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/export.js"(e,t){"use strict";var V=require_global_this(),i=require_object_get_own_property_descriptor().f,n=require_create_non_enumerable_property(),A=require_define_built_in(),o=require_define_global_property(),r=require_copy_constructor_properties(),s=require_is_forced();t.exports=function(e,t){var q,a,c,l,d,p=e.target,h=e.global,g=e.stat;if(q=h?V:g?V[p]||o(p,{}):V[p]&&V[p].prototype)for(a in t){if(l=t[a],c=e.dontCallGetSet?(d=i(q,a))&&d.value:q[a],!s(h?a:p+(g?".":"#")+a,e.forced)&&void 0!==c){if(typeof l==typeof c)continue;r(l,c)}(e.sham||c&&c.sham)&&n(l,"sham",!0),A(q,a,l,e)}}}}),require_es_global_this=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/modules/es.global-this.js"(){"use strict";var e=require_export(),t=require_global_this();e({global:!0,forced:t.globalThis!==t},{globalThis:t})}}),require_global_this2=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/es/global-this.js"(e,t){"use strict";require_es_global_this(),t.exports=require_global_this()}}),import_global_this=__toESM(require_global_this2(),1);function startValidateRule(e){return{name:"DeviceDetectorOptions",type:"object",required:!1,allowEmpty:!1,properties:{networkDetect:{required:!1,type:"object",properties:{sdkAppId:{required:!0,type:"number"},userId:{required:!0,type:"string"},userSig:{required:!0,type:"string"},downlinkUserId:{required:!1,type:"string"},downlinkUserSig:{required:!1,type:"string"},roomId:{required:!1,type:"number"}},async validate(t,V,i,n){const{RtcError:A,ErrorCode:o,ErrorCodeDictionary:r}=e.errorModule;if(!t)return;let{sdkAppId:s,userId:q,userSig:a,downlinkUserId:c,downlinkUserSig:l,roomId:d}=t;d=d||8080;const p=e.TRTC.create(),h=e.TRTC.create();await p.enterRoom({roomId:d,sdkAppId:s,userId:q,userSig:a}),await p.exitRoom(),p.destroy(),c&&l&&(await h.enterRoom({roomId:d,sdkAppId:s,userId:c,userSig:l}),await h.exitRoom(),h.destroy())}},cameraDetect:{required:!1,type:"object",properties:{mirror:{required:!1,type:"boolean"}}}}}}function stopValidateRule(e){return{name:"StopDeviceDetectorOptions",required:!1}}var _a,_b,t=globalThis,e=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,s=Symbol(),o=new WeakMap,n=class{constructor(e,t,V){if(this._$cssResult$=!0,V!==s)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=e,this.t=t}get styleSheet(){let t=this.o;const V=this.t;if(e&&void 0===t){const e=void 0!==V&&1===V.length;e&&(t=o.get(V)),void 0===t&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),e&&o.set(V,t))}return t}toString(){return this.cssText}},r=e=>new n("string"==typeof e?e:e+"",void 0,s),S=(V,i)=>{if(e)V.adoptedStyleSheets=i.map((e=>e instanceof CSSStyleSheet?e:e.styleSheet));else for(const e of i){const i=document.createElement("style"),n=t.litNonce;void 0!==n&&i.setAttribute("nonce",n),i.textContent=e.cssText,V.appendChild(i)}},c=e?e=>e:e=>e instanceof CSSStyleSheet?(e=>{let t="";for(const V of e.cssRules)t+=V.cssText;return r(t)})(e):e,{is:i2,defineProperty:e2,getOwnPropertyDescriptor:r2,getOwnPropertyNames:h,getOwnPropertySymbols:o2,getPrototypeOf:n2}=Object,a=globalThis,c2=a.trustedTypes,l=c2?c2.emptyScript:"",p=a.reactiveElementPolyfillSupport,d=(e,t)=>e,u={toAttribute(e,t){switch(t){case Boolean:e=e?l:null;break;case Object:case Array:e=null==e?e:JSON.stringify(e)}return e},fromAttribute(e,t){let V=e;switch(t){case Boolean:V=null!==e;break;case Number:V=null===e?null:Number(e);break;case Object:case Array:try{V=JSON.parse(e)}catch(e){V=null}}return V}},f=(e,t)=>!i2(e,t),y={attribute:!0,type:String,converter:u,reflect:!1,hasChanged:f};null!=(_a=Symbol.metadata)||(Symbol.metadata=Symbol("metadata")),null!=(_b=a.litPropertyMetadata)||(a.litPropertyMetadata=new WeakMap);var _a2,b=class extends HTMLElement{static addInitializer(e){var t;this._$Ei(),(null!=(t=this.l)?t:this.l=[]).push(e)}static get observedAttributes(){return this.finalize(),this._$Eh&&[...this._$Eh.keys()]}static createProperty(e,t=y){if(t.state&&(t.attribute=!1),this._$Ei(),this.elementProperties.set(e,t),!t.noAccessor){const V=Symbol(),i=this.getPropertyDescriptor(e,V,t);void 0!==i&&e2(this.prototype,e,i)}}static getPropertyDescriptor(e,t,V){var i;const{get:n,set:A}=null!=(i=r2(this.prototype,e))?i:{get(){return this[t]},set(e){this[t]=e}};return{get(){return null==n?void 0:n.call(this)},set(t){const i=null==n?void 0:n.call(this);A.call(this,t),this.requestUpdate(e,i,V)},configurable:!0,enumerable:!0}}static getPropertyOptions(e){var t;return null!=(t=this.elementProperties.get(e))?t:y}static _$Ei(){if(this.hasOwnProperty(d("elementProperties")))return;const e=n2(this);e.finalize(),void 0!==e.l&&(this.l=[...e.l]),this.elementProperties=new Map(e.elementProperties)}static finalize(){if(this.hasOwnProperty(d("finalized")))return;if(this.finalized=!0,this._$Ei(),this.hasOwnProperty(d("properties"))){const e=this.properties,t=[...h(e),...o2(e)];for(const V of t)this.createProperty(V,e[V])}const e=this[Symbol.metadata];if(null!==e){const t=litPropertyMetadata.get(e);if(void 0!==t)for(const[e,V]of t)this.elementProperties.set(e,V)}this._$Eh=new Map;for(const[e,t]of this.elementProperties){const V=this._$Eu(e,t);void 0!==V&&this._$Eh.set(V,e)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(e){const t=[];if(Array.isArray(e)){const V=new Set(e.flat(1/0).reverse());for(const e of V)t.unshift(c(e))}else void 0!==e&&t.push(c(e));return t}static _$Eu(e,t){const V=t.attribute;return!1===V?void 0:"string"==typeof V?V:"string"==typeof e?e.toLowerCase():void 0}constructor(){super(),this._$Ep=void 0,this.isUpdatePending=!1,this.hasUpdated=!1,this._$Em=null,this._$Ev()}_$Ev(){var e;this._$ES=new Promise((e=>this.enableUpdating=e)),this._$AL=new Map,this._$E_(),this.requestUpdate(),null==(e=this.constructor.l)||e.forEach((e=>e(this)))}addController(e){var t,V;(null!=(t=this._$EO)?t:this._$EO=new Set).add(e),void 0!==this.renderRoot&&this.isConnected&&(null==(V=e.hostConnected)||V.call(e))}removeController(e){var t;null==(t=this._$EO)||t.delete(e)}_$E_(){const e=new Map,t=this.constructor.elementProperties;for(const V of t.keys())this.hasOwnProperty(V)&&(e.set(V,this[V]),delete this[V]);e.size>0&&(this._$Ep=e)}createRenderRoot(){var e;const t=null!=(e=this.shadowRoot)?e:this.attachShadow(this.constructor.shadowRootOptions);return S(t,this.constructor.elementStyles),t}connectedCallback(){var e;null!=this.renderRoot||(this.renderRoot=this.createRenderRoot()),this.enableUpdating(!0),null==(e=this._$EO)||e.forEach((e=>{var t;return null==(t=e.hostConnected)?void 0:t.call(e)}))}enableUpdating(e){}disconnectedCallback(){var e;null==(e=this._$EO)||e.forEach((e=>{var t;return null==(t=e.hostDisconnected)?void 0:t.call(e)}))}attributeChangedCallback(e,t,V){this._$AK(e,V)}_$EC(e,t){var V;const i=this.constructor.elementProperties.get(e),n=this.constructor._$Eu(e,i);if(void 0!==n&&!0===i.reflect){const A=(void 0!==(null==(V=i.converter)?void 0:V.toAttribute)?i.converter:u).toAttribute(t,i.type);this._$Em=e,null==A?this.removeAttribute(n):this.setAttribute(n,A),this._$Em=null}}_$AK(e,t){var V;const i=this.constructor,n=i._$Eh.get(e);if(void 0!==n&&this._$Em!==n){const e=i.getPropertyOptions(n),A="function"==typeof e.converter?{fromAttribute:e.converter}:void 0!==(null==(V=e.converter)?void 0:V.fromAttribute)?e.converter:u;this._$Em=n,this[n]=A.fromAttribute(t,e.type),this._$Em=null}}requestUpdate(e,t,V){var i;if(void 0!==e){if(null!=V||(V=this.constructor.getPropertyOptions(e)),!(null!=(i=V.hasChanged)?i:f)(this[e],t))return;this.P(e,t,V)}!1===this.isUpdatePending&&(this._$ES=this._$ET())}P(e,t,V){var i;this._$AL.has(e)||this._$AL.set(e,t),!0===V.reflect&&this._$Em!==e&&(null!=(i=this._$Ej)?i:this._$Ej=new Set).add(e)}async _$ET(){this.isUpdatePending=!0;try{await this._$ES}catch(e){Promise.reject(e)}const e=this.scheduleUpdate();return null!=e&&await e,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){var e;if(!this.isUpdatePending)return;if(!this.hasUpdated){if(null!=this.renderRoot||(this.renderRoot=this.createRenderRoot()),this._$Ep){for(const[e,t]of this._$Ep)this[e]=t;this._$Ep=void 0}const e=this.constructor.elementProperties;if(e.size>0)for(const[t,V]of e)!0!==V.wrapped||this._$AL.has(t)||void 0===this[t]||this.P(t,this[t],V)}let t=!1;const V=this._$AL;try{t=this.shouldUpdate(V),t?(this.willUpdate(V),null==(e=this._$EO)||e.forEach((e=>{var t;return null==(t=e.hostUpdate)?void 0:t.call(e)})),this.update(V)):this._$EU()}catch(e){throw t=!1,this._$EU(),e}t&&this._$AE(V)}willUpdate(e){}_$AE(e){var t;null==(t=this._$EO)||t.forEach((e=>{var t;return null==(t=e.hostUpdated)?void 0:t.call(e)})),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(e)),this.updated(e)}_$EU(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$ES}shouldUpdate(e){return!0}update(e){this._$Ej&&(this._$Ej=this._$Ej.forEach((e=>this._$EC(e,this[e])))),this._$EU()}updated(e){}firstUpdated(e){}};b.elementStyles=[],b.shadowRootOptions={mode:"open"},b[d("elementProperties")]=new Map,b[d("finalized")]=new Map,null==p||p({ReactiveElement:b}),(null!=(_a2=a.reactiveElementVersions)?_a2:a.reactiveElementVersions=[]).push("2.0.4");var t2=globalThis,i3=t2.trustedTypes,s2=i3?i3.createPolicy("lit-html",{createHTML:e=>e}):void 0,e3="$lit$",h2=`lit$${Math.random().toFixed(9).slice(2)}$`,o3="?"+h2,n3=`<${o3}>`,r3=document,l2=()=>r3.createComment(""),c3=e=>null===e||"object"!=typeof e&&"function"!=typeof e,a2=Array.isArray,u2=e=>a2(e)||"function"==typeof(null==e?void 0:e[Symbol.iterator]),d2="[ \t\n\f\r]",f2=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,v=/-->/g,_=/>/g,m=RegExp(`>|${d2}(?:([^\\s"'>=/]+)(${d2}*=${d2}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,"g"),p2=/'/g,g=/"/g,$=/^(?:script|style|textarea|title)$/i,y2=e=>(t,...V)=>({_$litType$:e,strings:t,values:V}),x=y2(1),b2=y2(2),w=y2(3),T=Symbol.for("lit-noChange"),E=Symbol.for("lit-nothing"),A=new WeakMap,C=r3.createTreeWalker(r3,129);function P(e,t){if(!a2(e)||!e.hasOwnProperty("raw"))throw Error("invalid template strings array");return void 0!==s2?s2.createHTML(t):t}var V=(e,t)=>{const V=e.length-1,i=[];let n,A=2===t?"<svg>":3===t?"<math>":"",o=f2;for(let t=0;t<V;t++){const V=e[t];let r,s,q=-1,a=0;for(;a<V.length&&(o.lastIndex=a,s=o.exec(V),null!==s);)a=o.lastIndex,o===f2?"!--"===s[1]?o=v:void 0!==s[1]?o=_:void 0!==s[2]?($.test(s[2])&&(n=RegExp("</"+s[2],"g")),o=m):void 0!==s[3]&&(o=m):o===m?">"===s[0]?(o=null!=n?n:f2,q=-1):void 0===s[1]?q=-2:(q=o.lastIndex-s[2].length,r=s[1],o=void 0===s[3]?m:'"'===s[3]?g:p2):o===g||o===p2?o=m:o===v||o===_?o=f2:(o=m,n=void 0);const c=o===m&&e[t+1].startsWith("/>")?" ":"";A+=o===f2?V+n3:q>=0?(i.push(r),V.slice(0,q)+e3+V.slice(q)+h2+c):V+h2+(-2===q?t:c)}return[P(e,A+(e[V]||"<?>")+(2===t?"</svg>":3===t?"</math>":"")),i]},N=class e{constructor({strings:t,_$litType$:i},n){let A;this.parts=[];let o=0,r=0;const s=t.length-1,q=this.parts,[a,c]=V(t,i);if(this.el=e.createElement(a,n),C.currentNode=this.el.content,2===i||3===i){const e=this.el.content.firstChild;e.replaceWith(...e.childNodes)}for(;null!==(A=C.nextNode())&&q.length<s;){if(1===A.nodeType){if(A.hasAttributes())for(const e of A.getAttributeNames())if(e.endsWith(e3)){const t=c[r++],V=A.getAttribute(e).split(h2),i=/([.?@])?(.*)/.exec(t);q.push({type:1,index:o,name:i[2],strings:V,ctor:"."===i[1]?H:"?"===i[1]?I:"@"===i[1]?L:k}),A.removeAttribute(e)}else e.startsWith(h2)&&(q.push({type:6,index:o}),A.removeAttribute(e));if($.test(A.tagName)){const e=A.textContent.split(h2),t=e.length-1;if(t>0){A.textContent=i3?i3.emptyScript:"";for(let V=0;V<t;V++)A.append(e[V],l2()),C.nextNode(),q.push({type:2,index:++o});A.append(e[t],l2())}}}else if(8===A.nodeType)if(A.data===o3)q.push({type:2,index:o});else{let e=-1;for(;-1!==(e=A.data.indexOf(h2,e+1));)q.push({type:7,index:o}),e+=h2.length-1}o++}}static createElement(e,t){const V=r3.createElement("template");return V.innerHTML=e,V}};function S2(e,t,V=e,i){var n,A,o;if(t===T)return t;let r=void 0!==i?null==(n=V._$Co)?void 0:n[i]:V._$Cl;const s=c3(t)?void 0:t._$litDirective$;return(null==r?void 0:r.constructor)!==s&&(null==(A=null==r?void 0:r._$AO)||A.call(r,!1),void 0===s?r=void 0:(r=new s(e),r._$AT(e,V,i)),void 0!==i?(null!=(o=V._$Co)?o:V._$Co=[])[i]=r:V._$Cl=r),void 0!==r&&(t=S2(e,r._$AS(e,t.values),r,i)),t}var _a3,M=class{constructor(e,t){this._$AV=[],this._$AN=void 0,this._$AD=e,this._$AM=t}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(e){var t;const{el:{content:V},parts:i}=this._$AD,n=(null!=(t=null==e?void 0:e.creationScope)?t:r3).importNode(V,!0);C.currentNode=n;let A=C.nextNode(),o=0,r=0,s=i[0];for(;void 0!==s;){if(o===s.index){let t;2===s.type?t=new R(A,A.nextSibling,this,e):1===s.type?t=new s.ctor(A,s.name,s.strings,this,e):6===s.type&&(t=new z(A,this,e)),this._$AV.push(t),s=i[++r]}o!==(null==s?void 0:s.index)&&(A=C.nextNode(),o++)}return C.currentNode=r3,n}p(e){let t=0;for(const V of this._$AV)void 0!==V&&(void 0!==V.strings?(V._$AI(e,V,t),t+=V.strings.length-2):V._$AI(e[t])),t++}},R=class e{get _$AU(){var e,t;return null!=(t=null==(e=this._$AM)?void 0:e._$AU)?t:this._$Cv}constructor(e,t,V,i){var n;this.type=2,this._$AH=E,this._$AN=void 0,this._$AA=e,this._$AB=t,this._$AM=V,this.options=i,this._$Cv=null==(n=null==i?void 0:i.isConnected)||n}get parentNode(){let e=this._$AA.parentNode;const t=this._$AM;return void 0!==t&&11===(null==e?void 0:e.nodeType)&&(e=t.parentNode),e}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(e,t=this){e=S2(this,e,t),c3(e)?e===E||null==e||""===e?(this._$AH!==E&&this._$AR(),this._$AH=E):e!==this._$AH&&e!==T&&this._(e):void 0!==e._$litType$?this.$(e):void 0!==e.nodeType?this.T(e):u2(e)?this.k(e):this._(e)}O(e){return this._$AA.parentNode.insertBefore(e,this._$AB)}T(e){this._$AH!==e&&(this._$AR(),this._$AH=this.O(e))}_(e){this._$AH!==E&&c3(this._$AH)?this._$AA.nextSibling.data=e:this.T(r3.createTextNode(e)),this._$AH=e}$(e){var t;const{values:V,_$litType$:i}=e,n="number"==typeof i?this._$AC(e):(void 0===i.el&&(i.el=N.createElement(P(i.h,i.h[0]),this.options)),i);if((null==(t=this._$AH)?void 0:t._$AD)===n)this._$AH.p(V);else{const e=new M(n,this),t=e.u(this.options);e.p(V),this.T(t),this._$AH=e}}_$AC(e){let t=A.get(e.strings);return void 0===t&&A.set(e.strings,t=new N(e)),t}k(t){a2(this._$AH)||(this._$AH=[],this._$AR());const V=this._$AH;let i,n=0;for(const A of t)n===V.length?V.push(i=new e(this.O(l2()),this.O(l2()),this,this.options)):i=V[n],i._$AI(A),n++;n<V.length&&(this._$AR(i&&i._$AB.nextSibling,n),V.length=n)}_$AR(e=this._$AA.nextSibling,t){var V;for(null==(V=this._$AP)||V.call(this,!1,!0,t);e&&e!==this._$AB;){const t=e.nextSibling;e.remove(),e=t}}setConnected(e){var t;void 0===this._$AM&&(this._$Cv=e,null==(t=this._$AP)||t.call(this,e))}},k=class{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(e,t,V,i,n){this.type=1,this._$AH=E,this._$AN=void 0,this.element=e,this.name=t,this._$AM=i,this.options=n,V.length>2||""!==V[0]||""!==V[1]?(this._$AH=Array(V.length-1).fill(new String),this.strings=V):this._$AH=E}_$AI(e,t=this,V,i){const n=this.strings;let A=!1;if(void 0===n)e=S2(this,e,t,0),A=!c3(e)||e!==this._$AH&&e!==T,A&&(this._$AH=e);else{const i=e;let o,r;for(e=n[0],o=0;o<n.length-1;o++)r=S2(this,i[V+o],t,o),r===T&&(r=this._$AH[o]),A||(A=!c3(r)||r!==this._$AH[o]),r===E?e=E:e!==E&&(e+=(null!=r?r:"")+n[o+1]),this._$AH[o]=r}A&&!i&&this.j(e)}j(e){e===E?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,null!=e?e:"")}},H=class extends k{constructor(){super(...arguments),this.type=3}j(e){this.element[this.name]=e===E?void 0:e}},I=class extends k{constructor(){super(...arguments),this.type=4}j(e){this.element.toggleAttribute(this.name,!!e&&e!==E)}},L=class extends k{constructor(e,t,V,i,n){super(e,t,V,i,n),this.type=5}_$AI(e,t=this){var V;if((e=null!=(V=S2(this,e,t,0))?V:E)===T)return;const i=this._$AH,n=e===E&&i!==E||e.capture!==i.capture||e.once!==i.once||e.passive!==i.passive,A=e!==E&&(i===E||n);n&&this.element.removeEventListener(this.name,this,i),A&&this.element.addEventListener(this.name,this,e),this._$AH=e}handleEvent(e){var t,V;"function"==typeof this._$AH?this._$AH.call(null!=(V=null==(t=this.options)?void 0:t.host)?V:this.element,e):this._$AH.handleEvent(e)}},z=class{constructor(e,t,V){this.element=e,this.type=6,this._$AN=void 0,this._$AM=t,this.options=V}get _$AU(){return this._$AM._$AU}_$AI(e){S2(this,e)}},j=t2.litHtmlPolyfillSupport;null==j||j(N,R),(null!=(_a3=t2.litHtmlVersions)?_a3:t2.litHtmlVersions=[]).push("3.2.1");var _a4,B=(e,t,V)=>{var i,n;const A=null!=(i=null==V?void 0:V.renderBefore)?i:t;let o=A._$litPart$;if(void 0===o){const e=null!=(n=null==V?void 0:V.renderBefore)?n:null;A._$litPart$=o=new R(t.insertBefore(l2(),e),e,void 0,null!=V?V:{})}return o._$AI(e),o},r4=class extends b{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){var e;const t=super.createRenderRoot();return null!=(e=this.renderOptions).renderBefore||(e.renderBefore=t.firstChild),t}update(e){const t=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(e),this._$Do=B(t,this.renderRoot,this.renderOptions)}connectedCallback(){var e;super.connectedCallback(),null==(e=this._$Do)||e.setConnected(!0)}disconnectedCallback(){var e;super.disconnectedCallback(),null==(e=this._$Do)||e.setConnected(!1)}render(){return T}};r4._$litElement$=!0,r4.finalized=!0,null==(_a4=globalThis.litElementHydrateSupport)||_a4.call(globalThis,{LitElement:r4});var _a5,i4=globalThis.litElementPolyfillSupport;null==i4||i4({LitElement:r4}),(null!=(_a5=globalThis.litElementVersions)?_a5:globalThis.litElementVersions=[]).push("4.1.1");var Button=class extends HTMLElement{constructor(){super(),this.attachShadow({mode:"open"}),this.shadowRoot.appendChild(this.createTemplate()),this.buttonEle=this.shadowRoot.querySelector("button")}createTemplate(){const e=document.createElement("template");return e.innerHTML="\n <style>\n .button {\n padding: 6px 16px;\n border-radius: 4px;\n border: 0;\n outline: none;\n background-color: transparent;\n user-select: none;\n font-size: 0.875rem;\n min-width: 64px;\n box-sizing: border-box;\n font-weight: 500;\n line-height: 1.75;\n transition: background-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,\n box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,\n border 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;\n }\n .outlined { \n /* 看不到 听不到 */\n padding: 5px 15px;\n border: 1px solid #006eff;\n color: #006eff;\n cursor: pointer;\n }\n .contained {\n /* 听得到 */\n cursor: pointer;\n color: #ffffff;\n background-color: #006eff;\n box-shadow: 0px 3px 1px -2px rgb(0 0 0 / 20%), 0px 2px 2px 0px rgb(0 0 0 / 14%), 0px 1px 5px 0px rgb(0 0 0 / 12%);\n }\n .disabled {\n /* 禁止 开始检测 */\n box-shadow: none;\n color: rgba(0, 0, 0, 0.26);\n background-color: rgba(0, 0, 0, 0.12);\n }\n .close{\n color: #eeeeee!important;\n border-radius: 20px!important;\n border-color: #eeeeee!important;\n }\n </style>\n <button>\n <slot></slot>\n </button>\n ",e.content.cloneNode(!0)}connectedCallback(){const e=this.getAttribute("type"),t=this.getAttribute("class");this.buttonEle.type="button",this.buttonEle.classList.add("button",e,t);const V=this.getAttribute("on-click");if(V){const e=new Function(V);this.buttonEle.addEventListener("click",(()=>{e()}))}}attributeChangedCallback(e,t,V){"type"===e&&(this.buttonEle.classList.remove(t),this.buttonEle.classList.add(V)),"className"===e&&(this.buttonEle.classList.remove(t),this.buttonEle.classList.add(V))}};__publicField(Button,"observedAttributes",["className","type","on-click"]),customElements.get("trtc-custom-button")||customElements.define("trtc-custom-button",Button);var core,log,index=9999,sheet=`\n @media screen and (max-width: 769px) {\n .root {\n max-width: 32.5rem;\n }\n .device-detector-backdrop {\n width: 100%;\n height: 100%;\n position: fixed;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n display: flex;\n align-items: center;\n justify-content: center;\n background-color: rgba(0, 0, 0, 0.8);\n z-index: ${index};\n opacity: 1;\n transition: opacity 225ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;\n }\n .device-detector-backdrop .root {\n position: relative;\n width: 98vw;\n height: 72vh;\n font-size: 16px;\n box-shadow: 2px 1px -1px rgba(0, 0, 0, 0.2), 0px 1px 1px 0px rgba(0, 0, 0, 0.14), 0px 1px 3px 0px rgba(0, 0, 0, 0.12);\n background-color: #ffffff;\n border-radius: 4px;\n }\n .device-detector-backdrop .root .stepper {\n border-radius: 5px 5px 0 0;\n font-size: 36px;\n }\n .device-detector-backdrop .root .close {\n color: #eeeeee !important;\n border-radius: 20px !important;\n border-color: #eeeeee !important;\n position: absolute !important;\n cursor: pointer;\n top: -50px;\n right: 2px;\n }\n .arrow {\n width: 0;\n height: 0;\n border-left: 2vh solid transparent;\n border-right: 2vh solid transparent;\n border-bottom: 2vh solid red;\n position: absolute;\n left: 2vw;\n animation: moveUpDown 2s infinite ease-in-out;\n transform:rotate(45deg);\n z-index: ${index+1};\n }\n \n .arrow::after {\n content: "";\n width: 1.5vh;\n height: 4vh;\n background-color: red;\n position: absolute;\n // top: 9px; /* 将柄定位在箭头的下方 */\n left: 50%; /* 水平居中柄 */\n transform: translate(-50%,18%); /* 微调柄的水平位置,使其完全居中 */\n z-index: ${index+1};\n }\n \n .remind-text {\n position: absolute;\n top: 10vh; /* 调整文字的垂直位置 */\n left: 1vw;\n width:90vw;\n color:red;\n z-index: ${index+1};\n }\n \n @keyframes moveUpDown {\n 0% {\n top: 3vh;\n left: 2vw;\n }\n \n 50% {\n top: 1.5vh;\n left: 3vw; \n }\n \n 100% {\n top: 3vh;\n left: 2vw;\n }\n }\n .device-connect {\n display: flex;\n flex-direction: column;\n align-items: center;\n height: 100%;\n }\n .device-connect .testing-title {\n display: flex;\n font-size: 2rem;\n justify-content: center;\n margin-top: 4vh;\n color: rgba(32, 30, 30, 0.8980392157);\n }\n .device-connect .testing-prepare-info {\n max-width: 500px;\n padding: 0 1vw;\n text-align: center;\n display: flex;\n font-size: 1rem;\n justify-content: center;\n margin-top: 3.8vh;\n color: rgba(88, 86, 86, 0.8980392157);\n }\n .device-connect .device-display {\n width: 88%;\n margin: 3vh auto 1.5vh;\n display: flex;\n justify-content: space-around;\n position: relative;\n }\n .device-connect .device-display .connect-success {\n position: relative;\n }\n .device-connect .device-display .connect-success::before {\n content: "";\n width: 28px;\n height: 28px;\n position: absolute;\n bottom: -34px;\n left: 50%;\n transform: translateX(-50%);\n background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAACAElEQVRYR+2Vv2sUQRTH3/eOYO+f EWzmzUaSTv8CYxIUAooWAYsQJEkRRDRikUJMiiMIQRSVCNql0sqkCIFwO7NLCGm00kpEEBtzhsyT Pe5kWG9zu8p5zU658958Pnznx4L6PNBnPpUCZQJlAj1PgOu8SBW6C0HNBGYmfe17KqBCdRvA/TbU OXc+Hoq3fImeCahQLQBY8mDGahv8lwR0qOcF8sCDfSCicavtXs8F2PBNIlrxQB9dxU3EKq53evY7 boGyahDHuCRVWY04+pL3f8GGp4mo1q4H8JkcTZjAbGet0VGADUurYd8dubF4OH7fTUJZdQOCR17d t1bs707q/UNgZH/kdKPR+Oofnupx9WL9bP1T1kJseIqI1rz5HwIZjzh60008awvuQXDndzNoR0hG O20HG75ORE+8WldBZSxU4UY3eDKfeQ211UsisuAtsjlwNDC6O7z7vf1NWXUFgucp0GWr7es88BMF kklt9UMRmfUWe3t46vDCwZmDnzrUkwJZ90ECuRpx9CIvvKtAUsCWaySUnO7mEJENAC+J6JUPgmDK BOZxEXgugaZEyGsESg5a1pi22q4WhecWaEoYfkpE19IQEZmLgmj5b+CFBJJiZdU6BJNtGAS3TGD8 976wR+GfUSuJc+TomR2yi4WJqYbCAv8KTPeXAmUCZQJ9T+AXo7StIY0IqrkAAAAASUVORK5CYII=") no-repeat;\n background-size: 100% 100%;\n }\n .device-connect .device-display .connect-fail {\n position: relative;\n }\n .device-connect .device-display .connect-fail::before {\n content: "";\n width: 28px;\n height: 28px;\n position: absolute;\n bottom: -34px;\n left: 50%;\n transform: translateX(-50%);\n background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAB3ElEQVRYR+2Wr08cQRTHP+8ESZOq GlKBaKhpUwWmCnG7d4giwDS5NGlVMWDAtIZfrQEDpjVF0ZC0wH/QWxr+gNrKJigSBA4J98hN7pbl 9mZnZklz5tasmPfm+5nve/t2hAE/MmB9hgBDB5wOaJVx+c2/Ms2qEc+BCznm3JZvBdBpHnPNmUlU VuWYzyEQGrGC8KmdI4m92e0AbXrhbyoqfJQmWz4QWuMDymYa2+KpzcXCEmjMOrCWEV2WhJ0iCI1Z ArbTGId77h7ohRAWpcnXfhBaYwHlS4hrTgDTAnkn5iVhNwuhMe+BbyFumf7wqakF4p0kfO+svQX2 Mie3utSr5w3QF6JCw2zY4kdm45w7RYcMArA4kd0/dcXX2WAAK0SFhvzip69wN64cQJ0XtDgEnmXq /lqaHP13AK0yQcWIj+fEhGCIIAc05iUY8bGO+EbnfTusAiG8AbTOVMf20a64JGZS5udEAIQXgEbE CAfAo17xbhlyw8oTwgmgMa/AdPdDm/h9IIp/RjXmUCM+4hIvC2H/HdeZpMWfTKdvdGvu+tRy5bji iZxw2i+v6D7wBmHf9+S9m9+BKH0fiJilwgNp3pn1LgPSdY2YQbiUhBNbkrMJvdVKBg4Bhg4M3IEb uI2UIfOyj40AAAAASUVORK5CYII=") no-repeat;\n background-size: 100% 100%;\n }\n .device-connect .device-display .device {\n width: 46px;\n height: 46px;\n position: relative;\n justify-content: center;\n font-size: 38px;\n }\n .device-connect .device-display .device svg {\n width: 36px;\n height: 36px;\n fill: #47494D;\n }\n .device-connect .device-display .outer-progress {\n width: 83%;\n height: 4px;\n border-radius: 5px;\n position: absolute;\n top: 70px;\n background-color: #eeeeee;\n overflow: hidden;\n }\n .device-connect .device-display .outer-progress .inner-progress {\n width: 100%;\n position: absolute;\n top: 0;\n left: -100%;\n height: 4px;\n border-radius: 5px;\n background-color: #bfbfbf;\n transform-origin: left;\n transition: transform 0.3s linear;\n }\n .device-connect .text {\n margin-top: 4.5vh;\n font-size: 1rem;\n max-width: 420px;\n text-align: center;\n height: 20px;\n display: flex;\n align-items: center;\n justify-content: center;\n }\n .device-connect .text.gray-text {\n color: rgba(88, 86, 86, 0.8980392157);\n }\n .device-connect .text.green-text {\n color: rgb(50, 205, 50);\n }\n .device-connect .text.red-text {\n color: red;\n }\n .device-connect .button-container {\n position: absolute;\n bottom: 3vh;\n width: 40%;\n display: flex;\n justify-content: space-around;\n }\n .error-connect {\n width: 20px;\n height: 20px;\n margin-left: 8px;\n display: inline;\n }\n .error-connect .error-icon svg {\n width: 20px;\n height: 20px;\n }\n .connect-attention-info {\n padding: 1vw 1vh;\n min-width: 134px;\n min-height: 50px;\n background: rgba(0, 0, 0, 0.6);\n border-radius: 10px;\n color: rgb(255, 255, 255);\n position: absolute;\n top:23vh;\n display: block;\n font-size: 0.8rem;\n text-align: left;\n max-width: 92vw;\n white-space: nowrap;\n white-space: normal; // 添加这一行,使其自动换行\n word-wrap: break-word; /* 添加自动换行样式 */\n overflow-wrap: anywhere; /* 允许在任意位置换行 */\n }\n .error-connect .connect-attention-info::after {\n content: "";\n width: 0;\n height: 0;\n border: 10px transparent solid;\n border-top-color: rgba(0, 0, 0, 0.6);\n position: absolute;\n left: 100%;\n top: 100%;\n transform: translateX(-18vw);\n }\n .testing-body {\n display: flex;\n flex-wrap: wrap;\n justify-content: center;\n }\n .testing-body.hide {\n display: none;\n }\n .testing-body .device-list {\n width: 93%;\n display: flex;\n justify-content: center;\n align-items: center;\n margin-bottom: 2vh;\n }\n .testing-body .device-list .device-list-title {\n margin-right: 1vw;\n font-size: 0.8rem;\n }\n .testing-body .flex-col {\n display: flex;\n flex-direction: column;\n align-items: center;\n }\n .testing-body .checkbox {\n display: flex;\n align-items: center;\n }\n .testing-body .camera-video {\n max-width: 80vw;\n height: 32vh;\n object-fit: contain; /* 保持视频的宽高比,将其完整显示在框内 */\n }\n .testing-body .mirror {\n transform: scaleX(-1);\n }\n .testing-container {\n width: 100%;\n margin: 10px auto 30px;\n }\n .testing-container .testing-body {\n display: flex;\n flex-wrap: wrap;\n justify-content: center;\n }\n .testing-container .testing-body.hide {\n display: none;\n }\n .testing-container .testing-body .device-list {\n width: 100%;\n display: flex;\n justify-content: center;\n align-items: center;\n margin-bottom: 20px;\n }\n .testing-container .testing-body .device-list .device-list-title {\n margin-right: 10px;\n }\n .testing-container .testing-body .flex-col {\n display: flex;\n flex-direction: column;\n align-items: center;\n }\n .testing-container .testing-body .checkbox {\n display: flex;\n align-items: center;\n }\n .testing-container .testing-body .camera-video {\n width: 300px;\n height: 180px;\n }\n .testing-container .testing-body .mirror {\n transform: scaleX(-1);\n }\n .audio-player-container {\n width: 340px;\n display: flex;\n justify-content: center;\n flex-wrap: wrap;\n margin: 2vh auto 0;\n text-align: center;\n }\n .audio-player-container .audio-player-info {\n margin: 0px auto 16px;\n color: #5f5f5f;\n }\n .audio-player-container #audio-player {\n width: 100%;\n }\n .testing-info-container {\n display: flex;\n width: 100%;\n justify-content: center;\n flex-wrap: wrap;\n position: absolute;\n bottom: 3vh;\n }\n .testing-info-container .testing-info {\n width: 100%;\n text-align: center;\n display: block;\n font-size:1rem;\n }\n .testing-info-container .button-list {\n margin-top: 2vh;\n width: 300px;\n display: flex;\n justify-content: space-around;\n }\n .device-select {\n width: 90%;\n padding: 6px 14px 6px 12px;\n position: relative;\n font-size: 0.8rem;\n border-radius: 4px;\n background-color: #fff;\n cursor: pointer;\n }\n .device-select:focus {\n outline: none;\n }\n .step-container {\n display: flex;\n margin-top: 2vh;\n margin-bottom: 2vh;\n padding: 0.3vw;\n font-size: 0.95rem;\n }\n .step-container .step {\n width: 100%;\n display: flex;\n flex-direction: column;\n align-items: center;\n position: relative;\n fill: rgba(0, 0, 0, 0.54);\n color: rgba(0, 0, 0, 0.54);\n }\n .step-container .step:not(:first-child)::after {\n position: absolute;\n content: "";\n height: 1px;\n background-color: rgba(0, 0, 0, 0.16);\n right: 100%;\n top: 30%;\n right: calc(50% + 20px);\n left: calc(-50% + 20px);\n top: 16px;\n }\n .step-container .step.active {\n fill: #006EFF;\n color: #006EFF;\n cursor: pointer;\n }\n .step-container .step.active::after {\n background-color: #006EFF;\n }\n .step-container .step.error {\n fill: red;\n color: red;\n cursor: pointer;\n }\n .step-container .step.error::after {\n background-color: #006EFF;\n }\n .step-container .step .step-label {\n margin-top: 12px;\n }\n .mic-testing-container {\n margin-top: 20px;\n width: 100%;\n }\n .mic-testing-container .mic-testing-info {\n text-align: center;\n }\n .mic-testing-container .mic-bar-container {\n display: flex;\n justify-content: center;\n margin-top: 10px;\n }\n .mic-testing-container .mic-bar-container .mic-bar {\n width: 8px;\n height: 30px;\n border: 1px solid #cccccc;\n border-radius: 1px;\n }\n .mic-testing-container .mic-bar-container .mic-bar:not(:first-child) {\n margin-left: 3px;\n }\n .mic-testing-container .mic-bar-container .mic-bar.active {\n background: #006EFF;\n }\n .recording-container {\n margin-top: 3vh;\n }\n .testing-list {\n width: 100%;\n display: flex;\n flex-wrap: wrap;\n }\n .testing-list .testing-item-container {\n width: 83%;\n margin: 0 auto 10px;\n display: flex;\n justify-content: space-between;\n }\n @keyframes loading-circle {\n 0% {\n transform: rotate(0deg);\n }\n 25% {\n transform: rotate(90deg);\n }\n 50% {\n transform: rotate(180deg);\n }\n 75% {\n transform: rotate(270deg);\n }\n 100% {\n transform: rotate(360deg);\n }\n }\n .network-loading {\n display: flex;\n }\n .network-loading::before {\n content: "";\n width: 16px;\n height: 16px;\n background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAChElEQVRYR82WO2wTQRCGZ9YFLmmCQDRUFIgOCuhMg2QJ8OxKtpQuEggqQDz6hDIiSAg6QEo6pFi+WVsoLgkVDakgFFBAlYJ0IGRceAetdWddLF/uznacXHe38/j2n9mbRTjkB6eRn4jOWGt/jhMrMwARlRDxkogUEfETM7/zCY0xqyKyAAAe4G70PStMZgCt9WsAuBUG3mLmi5VK5ZxSajuWrM7MtazJvd1EAER0HBG/AcBcPxji8yAIHhDREiJeA4A/IvLBWruUBJUIoLX+AgC7IvLEWruZVAIimldKXXXOefstb6u1lljCbWY+nwsg3MFi6LTJzFeyyloul48Vi8V/MfvvzHw2F0Cstl6BZWvts6wA3o6I3iDizdDnBTPfzwUQGVer1bl6vb6bJ3nM92S321WtVmtHa/3QnxBE/BwEwY14vD094KXfr2HGASGiBURcjXxF5KW19l70PgDQWr8HgBIA5Kp5GpTWeh0AqjG7HWY+PUsAn9xD9J/wVA2O5YGXIGzKklJq3jn30Vq7ltgDaXJOsu7nhS+xUuqyc+6t/1/k+hNOktz7GmNYRCgWp8bM9X4JiGhZKXVCRDb8x0mTDfuPmBnepD83+gDRr3O4QaYJorX+AQC+DHuacSYKhCovIuJ1ALiAiGu9Xu9ps9n8mnkaTkuN4cvLzAGGN3J0AIjoESKuiMgda+2raUmeFmegwEED+KPom+7QSpA0aY9ODwxLY4w51el0/rbb7d9pdZxkfb9Lqb9YTvVuMAo0EcDfZAqFwq9Go7Exzg6NMStBEDxO883VA0R0e9QRTerwtOS5x3E4tPpjNAoeTrp151xt1DFLg8ilQFKwmSmQtptx1v8DVbAxMP//OLQAAAAASUVORK5CYII=") no-repeat;\n background-size: 100% 100%;\n animation: loading-circle 2s linear infinite;\n }\n .report-button {\n position: absolute;\n bottom: 6vh;\n cursor: pointer;\n }\n .gray-button {\n position: absolute;\n bottom: 6vh;\n }\n .device-testing-report {\n display: flex;\n flex-wrap: wrap;\n flex-direction: column;\n align-items: center;\n }\n .device-testing-report .testing-title {\n display: flex;\n font-size: 4vh;\n justify-content: center;\n margin-top: 2vh;\n color: rgba(32, 30, 30, 0.8980392157);\n }\n .device-testing-report .device-report-list {\n display: block;\n width: 100%;\n margin-top: 10px;\n }\n .device-testing-report .device-report-list .device-report {\n display: flex;\n width: 70%;\n margin: 2vh auto 0;\n justify-content: space-between;\n }\n .device-testing-report .device-report-list .device-report .device-info {\n display: flex;\n width: 80%;\n }\n .device-testing-report .device-report-list .device-report .device-info .report-icon {\n margin-right: 20px;\n justify-content: center;\n font-size: 22px;\n line-height: 22px;\n color: #515151;\n }\n .device-testing-report .device-report-list .device-report .device-info .report-icon svg {\n width: 24px;\n height: 24px;\n }\n .device-testing-report .device-report-list .device-report .device-info .device-name {\n width: 280px;\n height: 24px;\n line-height: 24px;\n display: block;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n text-align: left;\n }\n .device-testing-report .device-report-list .device-report .green {\n color: green;\n }\n .device-testing-report .device-report-list .device-report .red {\n color: red;\n }\n .device-testing-report .device-report-footer {\n width: 65%;\n display: flex;\n justify-content: space-between;\n position: absolute;\n bottom: 36px;\n }\n }\n @media screen and (min-width: 769px) {\n .device-detector-backdrop {\n width: 100%;\n height: 100%;\n position: fixed;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n display: flex;\n align-items: center;\n justify-content: center;\n background-color: rgba(0, 0, 0, 0.8);\n z-index: ${index};\n opacity: 1;\n transition: opacity 225ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;\n }\n .device-detector-backdrop .root {\n position: relative;\n width: 600px;\n height: 480px;\n font-size: 16px;\n box-shadow: 2px 1px -1px rgba(0, 0, 0, 0.2), 0px 1px 1px 0px rgba(0, 0, 0, 0.14), 0px 1px 3px 0px rgba(0, 0, 0, 0.12);\n background-color: #ffffff;\n border-radius: 4px;\n }\n .device-detector-backdrop .root .stepper {\n border-radius: 5px 5px 0 0;\n font-size: 36px;\n }\n .device-detector-backdrop .root .close {\n color: #eeeeee !important;\n border-radius: 20px !important;\n border-color: #eeeeee !important;\n position: absolute !important;\n cursor: pointer;\n top: -50px;\n right: 2px;\n }\n\n .arrow {\n width: 0;\n height: 0;\n border-left: 2vh solid transparent;\n border-right: 2vh solid transparent;\n border-bottom: 2vh solid red;\n position: absolute;\n left: 2vw;\n animation: moveUpDown 2s infinite ease-in-out;\n transform:rotate(45deg);\n z-index: ${index+1};\n }\n \n .arrow::after {\n content: "";\n width: 1.5vh;\n height: 4vh;\n background-color: red;\n position: absolute;\n // top: 9px; /* 将柄定位在箭头的下方 */\n left: 50%; /* 水平居中柄 */\n transform: translate(-50%,18%); /* 微调柄的水平位置,使其完全居中 */\n z-index: ${index+1};\n }\n \n .remind-text {\n position: absolute;\n top: 10vh; /* 调整文字的垂直位置 */\n left: 1vw;\n width:30vw;\n color:red;\n z-index: ${index+1};\n }\n \n @keyframes moveUpDown {\n 0% {\n top: 3vh;\n left: 2vw;\n }\n \n 50% {\n top: 1.5vh;\n left: 3vw; \n }\n \n 100% {\n top: 3vh;\n left: 2vw;\n }\n }\n .device-connect {\n display: flex;\n flex-direction: column;\n align-items: center;\n }\n .device-connect .testing-title {\n display: flex;\n font-size: 32px;\n justify-content: center;\n margin-top: 55px;\n color: rgba(32, 30, 30, 0.8980392157);\n }\n .device-connect .testing-prepare-info {\n max-width: 500px;\n text-align: center;\n display: flex;\n font-size: 16px;\n justify-content: center;\n margin-top: 30px;\n color: rgba(88, 86, 86, 0.8980392157);\n }\n .device-connect .device-display {\n width: 420px;\n margin: 40px auto 20px;\n display: flex;\n justify-content: space-around;\n position: relative;\n }\n .device-connect .device-display .connect-success {\n position: relative;\n }\n .device-connect .device-display .connect-success::before {\n content: "";\n width: 28px;\n height: 28px;\n position: absolute;\n bottom: -34px;\n left: 50%;\n transform: translateX(-50%);\n background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAACAElEQVRYR+2Vv2sUQRTH3/eOYO+f EWzmzUaSTv8CYxIUAooWAYsQJEkRRDRikUJMiiMIQRSVCNql0sqkCIFwO7NLCGm00kpEEBtzhsyT Pe5kWG9zu8p5zU658958Pnznx4L6PNBnPpUCZQJlAj1PgOu8SBW6C0HNBGYmfe17KqBCdRvA/TbU OXc+Hoq3fImeCahQLQBY8mDGahv8lwR0qOcF8sCDfSCicavtXs8F2PBNIlrxQB9dxU3EKq53evY7 boGyahDHuCRVWY04+pL3f8GGp4mo1q4H8JkcTZjAbGet0VGADUurYd8dubF4OH7fTUJZdQOCR17d t1bs707q/UNgZH/kdKPR+Oofnupx9WL9bP1T1kJseIqI1rz5HwIZjzh60008awvuQXDndzNoR0hG O20HG75ORE+8WldBZSxU4UY3eDKfeQ211UsisuAtsjlwNDC6O7z7vf1NWXUFgucp0GWr7es88BMF kklt9UMRmfUWe3t46vDCwZmDnzrUkwJZ90ECuRpx9CIvvKtAUsCWaySUnO7mEJENAC+J6JUPgmDK BOZxEXgugaZEyGsESg5a1pi22q4WhecWaEoYfkpE19IQEZmLgmj5b+CFBJJiZdU6BJNtGAS3TGD8 976wR+GfUSuJc+TomR2yi4WJqYbCAv8KTPeXAmUCZQJ9T+AXo7StIY0IqrkAAAAASUVORK5CYII=") no-repeat;\n background-size: 100% 100%;\n }\n .device-connect .device-display .connect-fail {\n position: relative;\n }\n .device-connect .device-display .connect-fail::before {\n content: "";\n width: 28px;\n height: 28px;\n position: absolute;\n bottom: -34px;\n left: 50%;\n transform: translateX(-50%);\n background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAB3ElEQVRYR+2Wr08cQRTHP+8ESZOq GlKBaKhpUwWmCnG7d4giwDS5NGlVMWDAtIZfrQEDpjVF0ZC0wH/QWxr+gNrKJigSBA4J98hN7pbl 9mZnZklz5tasmPfm+5nve/t2hAE/MmB9hgBDB5wOaJVx+c2/Ms2qEc+BCznm3JZvBdBpHnPNmUlU VuWYzyEQGrGC8KmdI4m92e0AbXrhbyoqfJQmWz4QWuMDymYa2+KpzcXCEmjMOrCWEV2WhJ0iCI1Z ArbTGId77h7ohRAWpcnXfhBaYwHlS4hrTgDTAnkn5iVhNwuhMe+BbyFumf7wqakF4p0kfO+svQX2 Mie3utSr5w3QF6JCw2zY4kdm45w7RYcMArA4kd0/dcXX2WAAK0SFhvzip69wN64cQJ0XtDgEnmXq /lqaHP13AK0yQcWIj+fEhGCIIAc05iUY8bGO+EbnfTusAiG8AbTOVMf20a64JGZS5udEAIQXgEbE CAfAo17xbhlyw8oTwgmgMa/AdPdDm/h9IIp/RjXmUCM+4hIvC2H/HdeZpMWfTKdvdGvu+tRy5bji iZxw2i+v6D7wBmHf9+S9m9+BKH0fiJilwgNp3pn1LgPSdY2YQbiUhBNbkrMJvdVKBg4Bhg4M3IEb uI2UIfOyj40AAAAASUVORK5CYII=") no-repeat;\n background-size: 100% 100%;\n }\n .device-connect .device-display .device {\n width: 46px;\n height: 46px;\n position: relative;\n justify-content: center;\n font-size: 38px;\n }\n .device-connect .device-display .device svg {\n width: 36px;\n height: 36px;\n fill: #47494D;\n }\n .device-connect .device-display .outer-progress {\n width: 360px;\n height: 4px;\n border-radius: 5px;\n position: absolute;\n top: 70px;\n background-color: #eeeeee;\n overflow: hidden;\n }\n .device-connect .device-display .outer-progress .inner-progress {\n width: 100%;\n position: absolute;\n top: 0;\n left: -360px;\n height: 4px;\n border-radius: 5px;\n background-color: #bfbfbf;\n transform-origin: left;\n transition: transform 0.3s linear;\n }\n .device-connect .text {\n margin-top: 50px;\n font-size: 18px;\n max-width: 420px;\n text-align: center;\n height: 20px;\n display: flex;\n align-items: center;\n justify-content: center;\n }\n .device-connect .text.gray-text {\n color: rgba(88, 86, 86, 0.8980392157);\n }\n .device-connect .text.green-text {\n color: rgb(50, 205, 50);\n }\n .device-connect .text.red-text {\n color: red;\n }\n .device-connect .button-container {\n margin-top: 50px;\n width: 40%;\n display: flex;\n justify-content: space-around;\n }\n .error-connect {\n width: 20px;\n height: 20px;\n margin-left: 8px;\n position: relative;\n display: inline;\n }\n .error-connect .error-icon svg {\n width: 20px;\n height: 20px;\n }\n .error-connect .connect-attention-info {\n padding: 8px 12px;\n min-width: 160px;\n min-height: 50px;\n background: rgba(0, 0, 0, 0.6);\n border-radius: 10px;\n color: #fff;\n position: absolute;\n right: 0;\n bottom: 100%;\n transform: translate(20px, -10px);\n display: block;\n white-space: nowrap;\n font-size: 12px;\n text-align: left;\n }\n .error-connect .connect-attention-info::after {\n content: "";\n width: 0;\n height: 0;\n border: 10px transparent solid;\n border-top-color: rgba(0, 0, 0, 0.6);\n position: absolute;\n left: 100%;\n top: 100%;\n transform: translateX(-40px);\n }\n .testing-body {\n display: flex;\n flex-wrap: wrap;\n justify-content: center;\n }\n .testing-body.hide {\n display: none;\n }\n .testing-body .device-list {\n width: 100%;\n display: flex;\n justify-content: center;\n align-items: center;\n margin-bottom: 20px;\n }\n .testing-body .device-list .device-list-title {\n margin-right: 10px;\n }\n .testing-body .flex-col {\n display: flex;\n flex-direction: column;\n align-items: center;\n }\n .testing-body .checkbox {\n display: flex;\n align-items: center;\n }\n .testing-body .camera-video {\n width: 300px;\n height: 180px;\n }\n .testing-body .mirror {\n transform: scaleX(-1);\n }\n .testing-container {\n width: 100%;\n margin: 10px auto 30px;\n }\n .testing-container .testing-body {\n display: flex;\n flex-wrap: wrap;\n justify-content: center;\n }\n .testing-container .testing-body.hide {\n display: none;\n }\n .testing-container .testing-body .device-list {\n width: 100%;\n display: flex;\n justify-content: center;\n align-items: center;\n margin-bottom: 20px;\n }\n .testing-container .testing-body .device-list .device-list-title {\n margin-right: 10px;\n }\n .testing-container .testing-body .flex-col {\n display: flex;\n flex-direction: column;\n align-items: center;\n }\n .testing-container .testing-body .checkbox {\n display: flex;\n align-items: center;\n }\n .testing-container .testing-body .camera-video {\n width: 300px;\n height: 180px;\n }\n .testing-container .testing-body .mirror {\n transform: scaleX(-1);\n }\n .audio-player-container {\n width: 340px;\n display: flex;\n justify-content: center;\n flex-wrap: wrap;\n margin: 20px auto 0;\n text-align: center;\n }\n .audio-player-container .audio-player-info {\n margin: 0px auto 16px;\n color: #5f5f5f;\n }\n .testing-info-container {\n display: flex;\n width: 100%;\n justify-content: center;\n flex-wrap: wrap;\n position: absolute;\n bottom: 30px;\n }\n .testing-info-container .testing-info {\n width: 100%;\n text-align: center;\n display: block;\n }\n .testing-info-container .button-list {\n margin-top: 20px;\n width: 300px;\n display: flex;\n justify-content: space-around;\n }\n .device-select {\n width: 260px;\n padding: 6px 14px 6px 12px;\n position: relative;\n font-size: 16px;\n border-radius: 4px;\n background-color: #fff;\n cursor: pointer;\n }\n .device-select:focus {\n outline: none;\n }\n .step-container {\n display: flex;\n padding: 24px;\n }\n .step-container .step {\n width: 100%;\n display: flex;\n flex-direction: column;\n align-items: center;\n position: relative;\n fill: rgba(0, 0, 0, 0.54);\n color: rgba(0, 0, 0, 0.54);\n }\n .step-container .step:not(:first-child)::after {\n position: absolute;\n content: "";\n height: 1px;\n background-color: rgba(0, 0, 0, 0.16);\n right: 100%;\n top: 30%;\n right: calc(50% + 20px);\n left: calc(-50% + 20px);\n top: 16px;\n }\n .step-container .step.active {\n fill: #006EFF;\n color: #006EFF;\n cursor: pointer;\n }\n .step-container .step.active::after {\n background-color: #006EFF;\n }\n .step-container .step.error {\n fill: red;\n color: red;\n cursor: pointer;\n }\n .step-container .step.error::after {\n background-color: #006EFF;\n }\n .step-container .step .step-label {\n margin-top: 12px;\n }\n .mic-testing-container {\n margin-top: 20px;\n width: 100%;\n }\n .mic-testing-container .mic-testing-info {\n text-align: center;\n }\n .mic-testing-container .mic-bar-container {\n display: flex;\n justify-content: center;\n margin-top: 10px;\n }\n .mic-testing-container .mic-bar-container .mic-bar {\n width: 8px;\n height: 30px;\n border: 1px solid #cccccc;\n border-radius: 1px;\n }\n .mic-testing-container .mic-bar-container .mic-bar:not(:first-child) {\n margin-left: 3px;\n }\n .mic-testing-container .mic-bar-container .mic-bar.active {\n background: #006EFF;\n }\n .recording-container {\n margin-top: 5em;\n }\n .testing-list {\n width: 100%;\n display: flex;\n flex-wrap: wrap;\n }\n .testing-list .testing-item-container {\n width: 70%;\n margin: 0 auto 10px;\n display: flex;\n justify-content: space-between;\n }\n @keyframes loading-circle {\n 0% {\n transform: rotate(0deg);\n }\n 25% {\n transform: rotate(90deg);\n }\n 50% {\n transform: rotate(180deg);\n }\n 75% {\n transform: rotate(270deg);\n }\n 100% {\n transform: rotate(360deg);\n }\n }\n .network-loading {\n display: flex;\n }\n .network-loading::before {\n content: "";\n width: 16px;\n height: 16px;\n background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAChElEQVRYR82WO2wTQRCGZ9YFLmmCQDRUFIgOCuhMg2QJ8OxKtpQuEggqQDz6hDIiSAg6QEo6pFi+WVsoLgkVDakgFFBAlYJ0IGRceAetdWddLF/uznacXHe38/j2n9mbRTjkB6eRn4jOWGt/jhMrMwARlRDxkogUEfETM7/zCY0xqyKyAAAe4G70PStMZgCt9WsAuBUG3mLmi5VK5ZxSajuWrM7MtazJvd1EAER0HBG/AcBcPxji8yAIHhDREiJeA4A/IvLBWruUBJUIoLX+AgC7IvLEWruZVAIimldKXXXOefstb6u1lljCbWY+nwsg3MFi6LTJzFeyyloul48Vi8V/MfvvzHw2F0Cstl6BZWvts6wA3o6I3iDizdDnBTPfzwUQGVer1bl6vb6bJ3nM92S321WtVmtHa/3QnxBE/BwEwY14vD094KXfr2HGASGiBURcjXxF5KW19l70PgDQWr8HgBIA5Kp5GpTWeh0AqjG7HWY+PUsAn9xD9J/wVA2O5YGXIGzKklJq3jn30Vq7ltgDaXJOsu7nhS+xUuqyc+6t/1/k+hNOktz7GmNYRCgWp8bM9X4JiGhZKXVCRDb8x0mTDfuPmBnepD83+gDRr3O4QaYJorX+AQC+DHuacSYKhCovIuJ1ALiAiGu9Xu9ps9n8mnkaTkuN4cvLzAGGN3J0AIjoESKuiMgda+2raUmeFmegwEED+KPom+7QSpA0aY9ODwxLY4w51el0/rbb7d9pdZxkfb9Lqb9YTvVuMAo0EcDfZAqFwq9Go7Exzg6NMStBEDxO883VA0R0e9QRTerwtOS5x3E4tPpjNAoeTrp151xt1DFLg8ilQFKwmSmQtptx1v8DVbAxMP//OLQAAAAASUVORK5CYII=") no-repeat;\n background-size: 100% 100%;\n animation: loading-circle 2s linear infinite;\n }\n .report-button {\n position: absolute;\n bottom: 60px;\n cursor: pointer;\n }\n .gray-button {\n position: absolute;\n bottom: 60px;\n }\n .device-testing-report {\n display: flex;\n flex-wrap: wrap;\n flex-direction: column;\n align-items: center;\n }\n .device-testing-report .testing-title {\n display: flex;\n font-size: 34px;\n justify-content: center;\n margin-top: 30px;\n color: rgba(32, 30, 30, 0.8980392157);\n }\n .device-testing-report .device-report-list {\n display: block;\n width: 100%;\n margin-top: 10px;\n }\n .device-testing-report .device-report-list .device-report {\n display: flex;\n width: 70%;\n margin: 20px auto 0;\n justify-content: space-between;\n }\n .device-testing-report .device-report-list .device-report .device-info {\n display: flex;\n width: 80%;\n }\n .device-testing-report .device-report-list .device-report .device-info .report-icon {\n margin-right: 20px;\n justify-content: center;\n font-size: 22px;\n line-height: 22px;\n color: #515151;\n }\n .device-testing-report .device-report-list .device-report .device-info .report-icon svg {\n width: 24px;\n height: 24px;\n }\n .device-testing-report .device-report-list .device-report .device-info .device-name {\n width: 280px;\n height: 24px;\n line-height: 24px;\n display: block;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n text-align: left;\n }\n .device-testing-report .device-report-list .device-report .green {\n color: green;\n }\n .device-testing-report .device-report-list .device-report .red {\n color: red;\n }\n .device-testing-report .device-report-footer {\n width: 50%;\n display: flex;\n justify-content: space-between;\n position: absolute;\n bottom: 36px;\n }\n }\n`,style1_default=sheet,USER_AGENT=window.navigator&&window.navigator.userAgent||"",webkitVersionMap=/AppleWebKit\/([\d.]+)/i.exec(USER_AGENT),appleWebkitVersion=webkitVersionMap?parseFloat(webkitVersionMap.pop()||"0"):null,IS_IPAD=/iPad/i.test(USER_AGENT),IS_IPHONE=/iPhone/i.test(USER_AGENT)&&!IS_IPAD,IS_IPOD=/iPod/i.test(USER_AGENT),IS_IOS=IS_IPHONE||IS_IPAD||IS_IPOD,IOS_VERSION=IS_IOS&&function(){const e=USER_AGENT.match(/OS (\d+)_/i);return e&&e[1]?e[1]:null}(),IS_ANDROID=/Android/i.test(USER_AGENT),ANDROID_VERSION=IS_ANDROID&&function(){const e=USER_AGENT.match(/Android (\d+)(?:\.(\d+))?(?:\.(\d+))*/i);if(!e)return null;const t=e[1]&&parseFloat(e[1]),V=e[2]&&parseFloat(e[2]);return t&&V?parseFloat(`${e[1]}.${e[2]}`):t||null}(),IS_OLD_ANDROID=IS_ANDROID&&/webkit/i.test(USER_AGENT)&&ANDROID_VERSION<2.3,IS_NATIVE_ANDROID=IS_ANDROID&&ANDROID_VERSION<5&&appleWebkitVersion<537,IS_FIREFOX=/Firefox/i.test(USER_AGENT),FIREFOX_VERSION=IS_FIREFOX&&function(){const e=USER_AGENT.match(/Firefox\/(\d+)/);return e&&e[1]?parseFloat(e[1]):null}(),IS_EDGE=/Edge\//i.test(USER_AGENT),EDGE_VERSION=IS_EDGE&&function(){const e=USER_AGENT.match(/Edge\/(\d+)/i);if(e&&e[1])return e[1]}(),IS_EDG=/Edg\//i.test(USER_AGENT),EDG_VERSION=IS_EDG&&function(){const e=USER_AGENT.match(/Edg\/(\d+)/);return e&&e[1]?parseFloat(e[1]):null}(),IS_SOGOUM=/SogouMobileBrowser\//i.test(USER_AGENT),SOGOUM_VERSION=IS_SOGOUM&&function(){const e=USER_AGENT.match(/SogouMobileBrowser\/(\d+)/);return e&&e[1]?parseFloat(e[1]):null}(),IS_SOGOU=/MetaSr\s/i.test(USER_AGENT),SOGOU_VERSION=IS_SOGOU&&function(){const e=USER_AGENT.match(/MetaSr(\s\d+(\.\d+)+)/);return e&&e[1]?parseFloat(e[1]):null}(),IS_TBS=/TBS\/\d+/i.test(USER_AGENT),TBS_VERSION=IS_TBS&&function(){const e=USER_AGENT.match(/TBS\/(\d+)/i);if(e&&e[1])return e[1]}(),IS_XWEB=/XWEB\/\d+/i.test(USER_AGENT),XWEB_VERSION=IS_XWEB&&function(){const e=USER_AGENT.match(/XWEB\/(\d+)/i);if(e&&e[1])return e[1]}(),IS_IE8=/MSIE\s8\.0/.test(USER_AGENT),IS_IE=/MSIE\/\d+/i.test(USER_AGENT),IE_VERSION=IS_IE&&function(){const e=/MSIE\s(\d+)\.\d/.exec(USER_AGENT);let t=e&&parseFloat(e[1]);return!t&&/Trident\/7.0/i.test(USER_AGENT)&&/rv:11.0/.test(USER_AGENT)&&(t=11),t}(),IS_PC_WECHAT=/windowswechat/i.test(USER_AGENT),IS_WECHAT=/(micromessenger|webbrowser)/i.test(USER_AGENT),WECHAT_VERSION=IS_WECHAT&&function(){const e=USER_AGENT.match(/MicroMessenger\/(\d+)/i);if(e&&e[1])return e[1]}(),IS_X5MQQB=!IS_TBS&&/MQQBrowser\/\d+/i.test(USER_AGENT)&&/COVC\/\d+/i.test(USER_AGENT),IS_MQQB=!IS_TBS&&/MQQBrowser\/\d+/i.test(USER_AGENT)&&!/COVC\/\d+/i.test(USER_AGENT),MQQB_VERSION=(IS_MQQB||IS_X5MQQB)&&function(){const e=USER_AGENT.match(/ MQQBrowser\/([\d.]+)/);return e&&e[1]?e[1]:null}(),IS_WQQB=!IS_TBS&&/ QQBrowser\/\d+/i.test(USER_AGENT),WQQB_VERSION=IS_WQQB&&function(){const e=USER_AGENT.match(/ QQBrowser\/([\d.]+)/);return e&&e[1]?e[1]:null}(),IS_MACQQB=!IS_TBS&&/QQBrowserLite\/\d+/i.test(USER_AGENT),MACQQB_VERSION=IS_MACQQB&&function(){const e=USER_AGENT.match(/QQBrowserLite\/([\d.]+)/);return e&&e[1]?e[1]:null}(),IS_IPADQQB=!IS_TBS&&/MQBHD\/\d+/i.test(USER_AGENT),IPADQQB_VERSION=IS_IPADQQB&&function(){const e=USER_AGENT.match(/MQBHD\/([\d.]+)/);return e&&e[1]?e[1]:null}(),IS_WIN=/Windows/i.test(USER_AGENT),IS_MAC=!IS_IOS&&/MAC OS X/i.test(USER_AGENT),IS_LINUX=!IS_ANDROID&&/Linux/i.test(USER_AGENT),IS_WX=/MicroMessenger/i.test(USER_AGENT),IS_UCBROWSER=/UCBrowser/i.test(USER_AGENT),IS_ELECTRON=/Electron/i.test(USER_AGENT),IS_MIBROWSER=/MiuiBrowser/i.test(USER_AGENT),MI_VERSION=IS_MIBROWSER&&function(){const e=USER_AGENT.match(/MiuiBrowser\/([\d.]+)/);return e&&e[1]?e[1]:null}(),IS_HUAWEIBROWSER=/HuaweiBrowser/i.test(USER_AGENT),HUAWEI_VERSION=IS_HUAWEIBROWSER&&function(){const e=USER_AGENT.match(/HuaweiBrowser\/([\d.]+)/);return e&&e[1]?e[1]:null}(),IS_SAMSUNGBROWSER=/SamsungBrowser/i.test(USER_AGENT),SAMSUNG_VERSION=IS_SAMSUNGBROWSER&&function(){const e=USER_AGENT.match(/SamsungBrowser\/([\d.]+)/);return e&&e[1]?e[1]:null}(),IS_OPPOBROWSER=/HeyTapBrowser/i.test(USER_AGENT),OPPO_VERSION=IS_OPPOBROWSER&&function(){const e=USER_AGENT.match(/HeyTapBrowser\/([\d.]+)/);return e&&e[1]?e[1]:null}(),IS_VIVOBROWSER=/VivoBrowser/i.test(USER_AGENT),VIVO_VERSION=IS_VIVOBROWSER&&function(){const e=USER_AGENT.match(/VivoBrowser\/([\d.]+)/);return e&&e[1]?e[1]:null}(),IS_CHROME_ONLY=/Chrome/i.test(USER_AGENT),IS_CHROME=!IS_EDGE&&!IS_SOGOU&&!IS_SOGOUM&&!IS_TBS&&!IS_XWEB&&!IS_EDG&&!IS_WQQB&&!IS_MIBROWSER&&!IS_HUAWEIBROWSER&&!IS_SAMSUNGBROWSER&&!IS_OPPOBROWSER&&!IS_VIVOBROWSER&&/Chrome/i.test(USER_AGENT),CHROME_MAJOR_VERSION=IS_CHROME&&function(){const e=USER_AGENT.match(/Chrome\/(\d+)/);return e&&e[1]?parseFloat(e[1]):null}(),CHROME_VERSION=IS_CHROME&&function(){const e=USER_AGENT.match(/Chrome\/([\d.]+)/);return e&&e[1]?e[1]:null}(),IS_SAFARI=!IS_CHROME_ONLY&&!IS_MQQB&&!IS_X5MQQB&&!IS_MACQQB&&!IS_IPADQQB&&/Safari/i.test(USER_AGENT),SAFARI_VERSION=IS_SAFARI&&function(){const e=USER_AGENT.match(/Version\/([\d.]+)/);return e&&e[1]?e[1]:null}(),BROWSER_VERSION=IS_CHROME?`Chrome/${CHROME_VERSION}`:IS_SAFARI?`Safari/${SAFARI_VERSION}`:"NotSupportedBrowser",IS_LOCAL="file:"===location.protocol||"localhost"===location.hostname||/^\d+\.\d+\.\d+\.\d+$/.test(location.hostname),OSNameMap=new Map([[IS_ANDROID,"Android"],[IS_IOS,"iOS"],[IS_WIN,"Windows"],[IS_MAC,"MacOS"],[IS_LINUX,"Linux"]]),getOSType=()=>{let e="unknown";return OSNameMap.get(!0)&&(e=OSNameMap.get(!0)),e},browserInfoMap=new Map([[IS_FIREFOX,["Firefox",FIREFOX_VERSION]],[IS_EDG,["Edg",EDG_VERSION]],[IS_CHROME,["Chrome",CHROME_VERSION]],[IS_SAFARI,["Safari",SAFARI_VERSION]],[IS_TBS,["TBS",TBS_VERSION]],[IS_XWEB,["XWEB",XWEB_VERSION]],[IS_WECHAT&&IS_IPHONE,["WeChat",WECHAT_VERSION]],[IS_WQQB,["QQ(Win)",WQQB_VERSION]],[IS_MQQB,["QQ(Mobile)",MQQB_VERSION]],[IS_X5MQQB,["QQ(Mobile X5)",MQQB_VERSION]],[IS_MACQQB,["QQ(Mac)",MACQQB_VERSION]],[IS_IPADQQB,["QQ(iPad)",IPADQQB_VERSION]],[IS_MIBROWSER,["MI",MI_VERSION]],[IS_HUAWEIBROWSER,["HW",HUAWEI_VERSION]],[IS_SAMSUNGBROWSER,["Samsung",SAMSUNG_VERSION]],[IS_OPPOBROWSER,["OPPO",OPPO_VERSION]],[IS_VIVOBROWSER,["VIVO",VIVO_VERSION]],[IS_EDGE,["EDGE",EDGE_VERSION]],[IS_SOGOUM,["SogouMobile",SOGOUM_VERSION]],[IS_SOGOU,["Sogou",SOGOU_VERSION]]]),getBrowserInfo=()=>{let e="unknown",t="unknown";return browserInfoMap.get(!0)&&([e,t]=browserInfoMap.get(!0)),{name:e,version:t}},UA=navigator.userAgent,getDisplayResolution=()=>{let e;if(screen.width){e={width:screen.width?screen.width*window.devicePixelRatio:"",height:screen.height?screen.height*window.devicePixelRatio:""}}return e},getHardwareConcurrency=()=>{var e;return null==(e=window.navigator)?void 0:e.hardwareConcurrency},getBrowserLanguage=navigator.language||navigator.userLanguage||navigator.browserLanguage||navigator.systemLanguage||"en",isScreenCaptureAPISupported=()=>{var e;return!!(null==(e=navigator.mediaDevices)?void 0:e.getDisplayMedia)},isWebAudioSupported=()=>{const e={isSupported:!1},t=["AudioContext","webkitAudioContext","mozAudioContext","msAudioContext"];for(let V=0;V<t.length;V++)if(t[V]in window){e.isSupported=!0;break}return e.isSupported},isWebSocketSupported=()=>"WebSocket"in window&&2===window.WebSocket.CLOSING,isBrowserSupported=()=>!IS_UCBROWSER&&!IS_EDGE&&(!(IS_EDG&&"number"==typeof EDG_VERSION&&EDG_VERSION<80)&&!(IS_FIREFOX&&FIREFOX_VERSION&&FIREFOX_VERSION<56)),isWebRTCSupported=()=>["RTCPeerConnection","webkitRTCPeerConnection","RTCIceGatherer"].filter((e=>e in window)).length>0,isCanvasCapturingSupported=()=>{let e=!1;return["captureStream","mozCaptureStream","webkitCaptureStream"].forEach((t=>{"undefined"!=typeof document&&"function"==typeof document.createElement&&!e&&t in document.createElement("canvas")&&(e=!0)})),e},isVideoCapturingSupported=()=>{let e=!1;return["captureStream","mozCaptureStream","webkitCaptureStream"].forEach((t=>{"undefined"!=typeof document&&"function"==typeof document.createElement&&!e&&t in document.createElement("video")&&(e=!0)})),e},isRTPSenderReplaceTracksSupported=()=>{let e=!1;return IS_FIREFOX&&void 0!==window.mozRTCPeerConnection?"getSenders"in window.mozRTCPeerConnection.prototype&&(e=!0):IS_CHROME&&void 0!==window.webkitRTCPeerConnection&&"getSenders"in window.webkitRTCPeerConnection.prototype&&(e=!0),e},isApplyConstraintsSupported=()=>"undefined"!=typeof MediaStreamTrack&&"applyConstraints"in MediaStreamTrack.prototype,{toString:toString}=Object.prototype,isUndefined=e=>void 0===e,getCore=()=>core,getLog=()=>log,setCore=e=>{core=e},setLog=e=>{log=e},clear=()=>{core=null,log=null},isMediaDevicesUndefined=function(){const e=getLog();return!!isUndefined(navigator.mediaDevices)&&(e&&e.error("navigator.mediaDevices is not supported on your browser"),!0)},isUsedInHttpProtocol=function(){const e=getLog();return"http:"===location.protocol&&!IS_LOCAL&&(e&&e.error("you should use https"),!0)},isUserMediaSupported=()=>{if(!navigator.mediaDevices)return!1;const e=["getUserMedia","enumerateDevices"];return e.filter((e=>e in navigator.mediaDevices)).length===e.length},getDevices=async e=>{if(isUsedInHttpProtocol()||isMediaDevicesUndefined())return[];let t=!1,V=!1,i=!1,n=!1,A=!1;const o=[],r=[],s=[],q={};let a;e&&(a=await navigator.mediaDevices.getUserMedia(e));return(await navigator.mediaDevices.enumerateDevices()).forEach((e=>{const c={};for(const t in e)try{"function"!=typeof e[t]&&(c[t]=e[t])}catch(e){}const l=c.deviceId||"",d=c.label||"",p=c.kind||"";q[l+d+p]||("audio"===c.kind&&(c.kind="audioinput"),"video"===c.kind&&(c.kind="videoinput"),c.deviceId||(c.deviceId=c.id),c.label?("videoinput"!==c.kind||n||(n=!0),"audioinput"!==c.kind||A||(A=!0)):"videoinput"===c.kind?c.label=`Camera ${s.length+1}`:"audioinput"===c.kind?c.label=`Microphone ${o.length+1}`:"audiooutput"===c.kind?c.label=`Speaker ${r.length+1}`:c.label="Please invoke getUserMedia once.","audioinput"===c.kind&&(t=!0,-1===o.indexOf(c)&&o.push(c)),"audiooutput"===c.kind&&(V=!0,-1===r.indexOf(c)&&r.push(c)),"videoinput"===c.kind&&(i=!0,-1===s.indexOf(c)&&s.push(c)),q[c.deviceId+c.label+c.kind]=c,null==a||a.getTracks().forEach((e=>e.stop())))})),{hasWebCamPermission:n,hasMicrophonePermission:A,cameras:s,speakers:r,microphones:o}};async function UIGetCameras(e){return{cameraList:(await getDevices({video:!0,audio:!1})).cameras}}var UIGetMicrophones=async e=>({microphoneList:(await getDevices({video:!1,audio:!0})).microphones});async function UIGetSpeakers(){return(await getDevices({video:!1,audio:!0})).speakers}var encodeSupportStatus=async()=>{let e={sdp:"",type:"offer"},t=!1,V=!1;try{const i=new RTCPeerConnection,n=document.createElement("canvas");n.getContext("2d");const A=n.captureStream(0);return i.addTrack(A.getVideoTracks()[0],A),e=await i.createOffer(),e&&e.sdp&&(-1!==e.sdp.toLowerCase().indexOf("h264")&&(t=!0),-1!==e.sdp.toLowerCase().indexOf("vp8")&&(V=!0)),i.close(),{isH264EncodeSupported:t,isVp8EncodeSupported:V}}catch(e){return{isH264EncodeSupported:!1,isVp8EncodeSupported:!1}}},decodeSupportStatus=async()=>{let e={sdp:"",type:"offer"},t=!1,V=!1;try{const i=new RTCPeerConnection;return e=await i.createOffer({offerToReceiveAudio:!0,offerToReceiveVideo:!0}),e&&e.sdp&&(-1!==e.sdp.toLowerCase().indexOf("h264")&&(t=!0),-1!==e.sdp.toLowerCase().indexOf("vp8")&&(V=!0)),i.close(),{isH264DecodeSupported:t,isVp8DecodeSupported:V}}catch(e){return{isH264DecodeSupported:!1,isVp8DecodeSupported:!1}}};async function isHWEnabled(){return new Promise((async(e,t)=>{try{let V=function(){clearInterval(d),clearInterval(A),clearTimeout(p),r.close(),s.close(),o.getTracks().forEach((e=>e.stop()))};const i=document.createElement("canvas"),n=i.getContext("2d");i.width=640,i.height=480;const A=setInterval((()=>{n&&n.fillText("test",0,0)}),33),o=i.captureStream(15),r=new RTCPeerConnection({}),s=new RTCPeerConnection({});r.addEventListener("icecandidate",(e=>{s.addIceCandidate(e.candidate)})),s.addEventListener("icecandidate",(e=>{r.addIceCandidate(e.candidate)}));const q=RTCRtpSender.getCapabilities("video"),a=(q?q.codecs:[]).find((e=>"video/H264"===e.mimeType));r.addTransceiver(o.getVideoTracks()[0],{direction:"sendonly",streams:[o],sendEncodings:[{maxBitrate:5e5}]}),s.addTransceiver("video",{direction:"recvonly"}),a&&r.getTransceivers()[0].setCodecPreferences([a].filter((e=>void 0!==e)));const c=await r.createOffer();await r.setLocalDescription(c),await s.setRemoteDescription(c);const l=await s.createAnswer();await s.setLocalDescription(l),await r.setRemoteDescription(l);let d=-1,p=-1;p=setTimeout((()=>{V(),e(!1)}),3e4),d=setInterval((async()=>{(await r.getStats()).forEach((i=>{"outbound-rtp"===i.type&&"video"===i.mediaType&&(void 0===i.encoderImplementation&&(V(),t(new Error("your browser does not support to detect HW acceleration enabled."))),"ExternalEncoder"===i.encoderImplementation&&(V(),e(!0)))}))}),500)}catch(e){t(e)}}))}var RTCDetect={system:null,APISupported:null,devices:null,codecsSupported:null,report:null,networkInfo:null,TRTCInitDone:!1,mirror:!1,async getReportAsync(){return this.getSystem(),this.getAPISupported(),await this.getCodecAsync(),await this.getDevicesAsync(),this.report={system:this.system,APISupported:this.APISupported,codecsSupported:this.codecsSupported,devices:this.devices},this.report},async isTRTCSupported(){await this.getReportAsync();const{isWebRTCSupported:e,isUserMediaSupported:t,isWebSocketSupported:V}=this.APISupported;if(!e)return{result:!1,reason:"you browser does not support WebRTC."};if(!V)return{result:!1,reason:"you browser does not support WebSocket."};if(!t)return{result:!1,reason:"you browser does not support getUserMedia."};const{isH264EncodeSupported:i,isVp8EncodeSupported:n,isH264DecodeSupported:A,isVp8DecodeSupported:o}=this.codecsSupported;return i||n?A||o?isBrowserSupported()?{result:!0}:{result:!1,reason:"your browser does not qualify, it is recommended to use Chrome and firefox."}:{result:!1,reason:`isH264DecodeSupported: ${A} isVp8DecodeSupported: ${o} `}:{result:!1,reason:`isH264EncodeSupported: ${i} isVp8EncodeSupported: ${n} `}},async getCodecAsync(){const{isH264EncodeSupported:e,isVp8EncodeSupported:t}=await encodeSupportStatus(),{isH264DecodeSupported:V,isVp8DecodeSupported:i}=await decodeSupportStatus();return this.codecsSupported={isH264EncodeSupported:e,isVp8EncodeSupported:t,isH264DecodeSupported:V,isVp8DecodeSupported:i},this.codecsSupported},async getDevicesAsync(){const{hasWebCamPermission:e,hasMicrophonePermission:t,cameras:V,microphones:i,speakers:n}=await getDevices();return this.devices={cameras:V,microphones:i,speakers:n||[],hasWebCamPermission:e,hasMicrophonePermission:t},this.devices},getSystem(){return this.system={UA:UA,OS:getOSType(),browser:getBrowserInfo(),displayResolution:getDisplayResolution(),hardwareConcurrency:getHardwareConcurrency(),language:getBrowserLanguage},this.system},getAPISupported(){return this.APISupported={isUserMediaSupported:isUserMediaSupported(),isWebRTCSupported:isWebRTCSupported(),isWebSocketSupported:isWebSocketSupported(),isWebAudioSupported:isWebAudioSupported(),isScreenCaptureAPISupported:isScreenCaptureAPISupported(),isCanvasCapturingSupported:isCanvasCapturingSupported(),isVideoCapturingSupported:isVideoCapturingSupported(),isRTPSenderReplaceTracksSupported:isRTPSenderReplaceTracksSupported(),isApplyConstraintsSupported:isApplyConstraintsSupported()},this.APISupported},isHardWareAccelerationEnabled:async()=>await isHWEnabled()},sdk_default=RTCDetect;function isOnline(){const e=`https://web.sdk.qcloud.com/trtc/electron/download/resources/media/TestSpeaker.mp3?t=${(new Date).getTime()}`;return Promise.race([fetch(e,{mode:"cors"}),new Promise(((e,t)=>setTimeout((()=>t(!1)),3e3)))]).then((e=>{if(!e.ok)throw new Error("网络错误");return!0})).catch((()=>!1))}var NETWORK_QUALITY={0:"未知",1:"极佳",2:"较好",3:"一般",4:"差",5:"极差",6:"断开"},NETWORK_QUALITY_ENGLISH={0:"Unknown",1:"Excellent",2:"Good",3:"Average",4:"Poor",5:"Very Poor",6:"Disconnected"},handleGetUserMediaError=e=>{const t=(navigator.language||navigator.userLanguage||navigator.browserLanguage||navigator.systemLanguage||"en").indexOf("zh")>-1,V=getLog();switch(V.error("getUserMedia error",e),e.name){case"NotReadableError":return void(t?V.error("暂时无法访问摄像头/麦克风,请确保系统授予当前浏览器摄像头/麦克风权限,并且没有其他应用占用摄像头/麦克风"):V.error("Cannot access camera/microphone temporarily. Please make sure the system has granted the current browser permission to access the camera/microphone and no other application is using the camera/microphone"));case"NotAllowedError":return void(t?V.error("用户/系统已拒绝授权访问摄像头或麦克风"):V.error("User/system has denied access to camera/microphone"));case"NotFoundError":return void(t?V.error("找不到摄像头或麦克风设备"):V.error("Cannot find camera or microphone device"));case"OverConstrainedError":return void(t?V.error("采集属性设置错误,如果您指定了 cameraId/microphoneId,请确保它们是一个有效的非空字符串"):V.error("Capture attribute setting error. If you specified cameraId/microphoneId, please make sure they are valid non-empty strings"));default:return void(t?V.error("初始化本地流时遇到未知错误, 请重试"):V.error("Unknown error encountered when initializing local stream, please try again"))}},_deviceConnect=class e extends r4{constructor(){super(),this.progress=0,this.remindAnimation=!1;const t=navigator.language||navigator.userLanguage||navigator.browserLanguage||navigator.systemLanguage||"en";this.isChinese=t.indexOf("zh")>-1,this.showConnectResult=!1,this.connectResult={info:this.isChinese?"连接出错,请重试":"Connection error, please try again",success:!1,remind:this.isMobile?this.isChinese?e.mobileFailAttention:e.mobileFailAttentionEng:this.isChinese?e.deviceFailAttention:e.deviceFailAttentionEng},this.envresult=sdk_default.getSystem(),this.isMobile="iOS"===this.envresult.OS||"Android"===this.envresult.OS,this.isFirefoxOrSafariOrIOS="Firefox"===this.envresult.browser.name||"iOS"===this.envresult.OS||"Safari"===this.envresult.browser.name,this.deviceState={},this.showRemind=!1,this.startTime=(new Date).getTime(),this.attachShadow({mode:"open"})}render(){return x`
1
+ var __create=Object.create,__defProp=Object.defineProperty,__defProps=Object.defineProperties,__getOwnPropDesc=Object.getOwnPropertyDescriptor,__getOwnPropDescs=Object.getOwnPropertyDescriptors,__getOwnPropNames=Object.getOwnPropertyNames,__getOwnPropSymbols=Object.getOwnPropertySymbols,__getProtoOf=Object.getPrototypeOf,__hasOwnProp=Object.prototype.hasOwnProperty,__propIsEnum=Object.prototype.propertyIsEnumerable,__defNormalProp=(e,t,V)=>t in e?__defProp(e,t,{enumerable:!0,configurable:!0,writable:!0,value:V}):e[t]=V,__spreadValues=(e,t)=>{for(var V in t||(t={}))__hasOwnProp.call(t,V)&&__defNormalProp(e,V,t[V]);if(__getOwnPropSymbols)for(var V of __getOwnPropSymbols(t))__propIsEnum.call(t,V)&&__defNormalProp(e,V,t[V]);return e},__spreadProps=(e,t)=>__defProps(e,__getOwnPropDescs(t)),__commonJS=(e,t)=>function(){return t||(0,e[__getOwnPropNames(e)[0]])((t={exports:{}}).exports,t),t.exports},__copyProps=(e,t,V,i)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let n of __getOwnPropNames(t))__hasOwnProp.call(e,n)||n===V||__defProp(e,n,{get:()=>t[n],enumerable:!(i=__getOwnPropDesc(t,n))||i.enumerable});return e},__toESM=(e,t,V)=>(V=null!=e?__create(__getProtoOf(e)):{},__copyProps(!t&&e&&e.__esModule?V:__defProp(V,"default",{value:e,enumerable:!0}),e)),__publicField=(e,t,V)=>__defNormalProp(e,"symbol"!=typeof t?t+"":t,V),require_global_this=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/global-this.js"(e,t){"use strict";var V=function(e){return e&&e.Math===Math&&e};t.exports=V("object"==typeof globalThis&&globalThis)||V("object"==typeof window&&window)||V("object"==typeof self&&self)||V("object"==typeof global&&global)||V("object"==typeof e&&e)||function(){return this}()||Function("return this")()}}),require_fails=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/fails.js"(e,t){"use strict";t.exports=function(e){try{return!!e()}catch(e){return!0}}}}),require_descriptors=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/descriptors.js"(e,t){"use strict";var V=require_fails();t.exports=!V((function(){return 7!==Object.defineProperty({},1,{get:function(){return 7}})[1]}))}}),require_function_bind_native=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/function-bind-native.js"(e,t){"use strict";var V=require_fails();t.exports=!V((function(){var e=function(){}.bind();return"function"!=typeof e||e.hasOwnProperty("prototype")}))}}),require_function_call=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/function-call.js"(e,t){"use strict";var V=require_function_bind_native(),i=Function.prototype.call;t.exports=V?i.bind(i):function(){return i.apply(i,arguments)}}}),require_object_property_is_enumerable=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/object-property-is-enumerable.js"(e){"use strict";var t={}.propertyIsEnumerable,V=Object.getOwnPropertyDescriptor,i=V&&!t.call({1:2},1);e.f=i?function(e){var t=V(this,e);return!!t&&t.enumerable}:t}}),require_create_property_descriptor=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/create-property-descriptor.js"(e,t){"use strict";t.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}}}),require_function_uncurry_this=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/function-uncurry-this.js"(e,t){"use strict";var V=require_function_bind_native(),i=Function.prototype,n=i.call,A=V&&i.bind.bind(n,n);t.exports=V?A:function(e){return function(){return n.apply(e,arguments)}}}}),require_classof_raw=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/classof-raw.js"(e,t){"use strict";var V=require_function_uncurry_this(),i=V({}.toString),n=V("".slice);t.exports=function(e){return n(i(e),8,-1)}}}),require_indexed_object=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/indexed-object.js"(e,t){"use strict";var V=require_function_uncurry_this(),i=require_fails(),n=require_classof_raw(),A=Object,o=V("".split);t.exports=i((function(){return!A("z").propertyIsEnumerable(0)}))?function(e){return"String"===n(e)?o(e,""):A(e)}:A}}),require_is_null_or_undefined=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/is-null-or-undefined.js"(e,t){"use strict";t.exports=function(e){return null==e}}}),require_require_object_coercible=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/require-object-coercible.js"(e,t){"use strict";var V=require_is_null_or_undefined(),i=TypeError;t.exports=function(e){if(V(e))throw new i("Can't call method on "+e);return e}}}),require_to_indexed_object=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/to-indexed-object.js"(e,t){"use strict";var V=require_indexed_object(),i=require_require_object_coercible();t.exports=function(e){return V(i(e))}}}),require_is_callable=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/is-callable.js"(e,t){"use strict";var V="object"==typeof document&&document.all;t.exports=void 0===V&&void 0!==V?function(e){return"function"==typeof e||e===V}:function(e){return"function"==typeof e}}}),require_is_object=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/is-object.js"(e,t){"use strict";var V=require_is_callable();t.exports=function(e){return"object"==typeof e?null!==e:V(e)}}}),require_get_built_in=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/get-built-in.js"(e,t){"use strict";var V=require_global_this(),i=require_is_callable();t.exports=function(e,t){return arguments.length<2?(n=V[e],i(n)?n:void 0):V[e]&&V[e][t];var n}}}),require_object_is_prototype_of=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/object-is-prototype-of.js"(e,t){"use strict";var V=require_function_uncurry_this();t.exports=V({}.isPrototypeOf)}}),require_environment_user_agent=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/environment-user-agent.js"(e,t){"use strict";var V=require_global_this().navigator,i=V&&V.userAgent;t.exports=i?String(i):""}}),require_environment_v8_version=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/environment-v8-version.js"(e,t){"use strict";var V,i,n=require_global_this(),A=require_environment_user_agent(),o=n.process,r=n.Deno,s=o&&o.versions||r&&r.version,q=s&&s.v8;q&&(i=(V=q.split("."))[0]>0&&V[0]<4?1:+(V[0]+V[1])),!i&&A&&(!(V=A.match(/Edge\/(\d+)/))||V[1]>=74)&&(V=A.match(/Chrome\/(\d+)/))&&(i=+V[1]),t.exports=i}}),require_symbol_constructor_detection=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/symbol-constructor-detection.js"(e,t){"use strict";var V=require_environment_v8_version(),i=require_fails(),n=require_global_this().String;t.exports=!!Object.getOwnPropertySymbols&&!i((function(){var e=Symbol("symbol detection");return!n(e)||!(Object(e)instanceof Symbol)||!Symbol.sham&&V&&V<41}))}}),require_use_symbol_as_uid=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/use-symbol-as-uid.js"(e,t){"use strict";var V=require_symbol_constructor_detection();t.exports=V&&!Symbol.sham&&"symbol"==typeof Symbol.iterator}}),require_is_symbol=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/is-symbol.js"(e,t){"use strict";var V=require_get_built_in(),i=require_is_callable(),n=require_object_is_prototype_of(),A=require_use_symbol_as_uid(),o=Object;t.exports=A?function(e){return"symbol"==typeof e}:function(e){var t=V("Symbol");return i(t)&&n(t.prototype,o(e))}}}),require_try_to_string=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/try-to-string.js"(e,t){"use strict";var V=String;t.exports=function(e){try{return V(e)}catch(e){return"Object"}}}}),require_a_callable=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/a-callable.js"(e,t){"use strict";var V=require_is_callable(),i=require_try_to_string(),n=TypeError;t.exports=function(e){if(V(e))return e;throw new n(i(e)+" is not a function")}}}),require_get_method=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/get-method.js"(e,t){"use strict";var V=require_a_callable(),i=require_is_null_or_undefined();t.exports=function(e,t){var n=e[t];return i(n)?void 0:V(n)}}}),require_ordinary_to_primitive=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/ordinary-to-primitive.js"(e,t){"use strict";var V=require_function_call(),i=require_is_callable(),n=require_is_object(),A=TypeError;t.exports=function(e,t){var o,r;if("string"===t&&i(o=e.toString)&&!n(r=V(o,e)))return r;if(i(o=e.valueOf)&&!n(r=V(o,e)))return r;if("string"!==t&&i(o=e.toString)&&!n(r=V(o,e)))return r;throw new A("Can't convert object to primitive value")}}}),require_is_pure=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/is-pure.js"(e,t){"use strict";t.exports=!1}}),require_define_global_property=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/define-global-property.js"(e,t){"use strict";var V=require_global_this(),i=Object.defineProperty;t.exports=function(e,t){try{i(V,e,{value:t,configurable:!0,writable:!0})}catch(i){V[e]=t}return t}}}),require_shared_store=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/shared-store.js"(e,t){"use strict";var V=require_is_pure(),i=require_global_this(),n=require_define_global_property(),A="__core-js_shared__",o=t.exports=i[A]||n(A,{});(o.versions||(o.versions=[])).push({version:"3.38.1",mode:V?"pure":"global",copyright:"© 2014-2024 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.38.1/LICENSE",source:"https://github.com/zloirock/core-js"})}}),require_shared=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/shared.js"(e,t){"use strict";var V=require_shared_store();t.exports=function(e,t){return V[e]||(V[e]=t||{})}}}),require_to_object=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/to-object.js"(e,t){"use strict";var V=require_require_object_coercible(),i=Object;t.exports=function(e){return i(V(e))}}}),require_has_own_property=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/has-own-property.js"(e,t){"use strict";var V=require_function_uncurry_this(),i=require_to_object(),n=V({}.hasOwnProperty);t.exports=Object.hasOwn||function(e,t){return n(i(e),t)}}}),require_uid=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/uid.js"(e,t){"use strict";var V=require_function_uncurry_this(),i=0,n=Math.random(),A=V(1..toString);t.exports=function(e){return"Symbol("+(void 0===e?"":e)+")_"+A(++i+n,36)}}}),require_well_known_symbol=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/well-known-symbol.js"(e,t){"use strict";var V=require_global_this(),i=require_shared(),n=require_has_own_property(),A=require_uid(),o=require_symbol_constructor_detection(),r=require_use_symbol_as_uid(),s=V.Symbol,q=i("wks"),a=r?s.for||s:s&&s.withoutSetter||A;t.exports=function(e){return n(q,e)||(q[e]=o&&n(s,e)?s[e]:a("Symbol."+e)),q[e]}}}),require_to_primitive=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/to-primitive.js"(e,t){"use strict";var V=require_function_call(),i=require_is_object(),n=require_is_symbol(),A=require_get_method(),o=require_ordinary_to_primitive(),r=require_well_known_symbol(),s=TypeError,q=r("toPrimitive");t.exports=function(e,t){if(!i(e)||n(e))return e;var r,a=A(e,q);if(a){if(void 0===t&&(t="default"),r=V(a,e,t),!i(r)||n(r))return r;throw new s("Can't convert object to primitive value")}return void 0===t&&(t="number"),o(e,t)}}}),require_to_property_key=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/to-property-key.js"(e,t){"use strict";var V=require_to_primitive(),i=require_is_symbol();t.exports=function(e){var t=V(e,"string");return i(t)?t:t+""}}}),require_document_create_element=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/document-create-element.js"(e,t){"use strict";var V=require_global_this(),i=require_is_object(),n=V.document,A=i(n)&&i(n.createElement);t.exports=function(e){return A?n.createElement(e):{}}}}),require_ie8_dom_define=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/ie8-dom-define.js"(e,t){"use strict";var V=require_descriptors(),i=require_fails(),n=require_document_create_element();t.exports=!V&&!i((function(){return 7!==Object.defineProperty(n("div"),"a",{get:function(){return 7}}).a}))}}),require_object_get_own_property_descriptor=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/object-get-own-property-descriptor.js"(e){"use strict";var t=require_descriptors(),V=require_function_call(),i=require_object_property_is_enumerable(),n=require_create_property_descriptor(),A=require_to_indexed_object(),o=require_to_property_key(),r=require_has_own_property(),s=require_ie8_dom_define(),q=Object.getOwnPropertyDescriptor;e.f=t?q:function(e,t){if(e=A(e),t=o(t),s)try{return q(e,t)}catch(e){}if(r(e,t))return n(!V(i.f,e,t),e[t])}}}),require_v8_prototype_define_bug=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/v8-prototype-define-bug.js"(e,t){"use strict";var V=require_descriptors(),i=require_fails();t.exports=V&&i((function(){return 42!==Object.defineProperty((function(){}),"prototype",{value:42,writable:!1}).prototype}))}}),require_an_object=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/an-object.js"(e,t){"use strict";var V=require_is_object(),i=String,n=TypeError;t.exports=function(e){if(V(e))return e;throw new n(i(e)+" is not an object")}}}),require_object_define_property=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/object-define-property.js"(e){"use strict";var t=require_descriptors(),V=require_ie8_dom_define(),i=require_v8_prototype_define_bug(),n=require_an_object(),A=require_to_property_key(),o=TypeError,r=Object.defineProperty,s=Object.getOwnPropertyDescriptor,q="enumerable",a="configurable",c="writable";e.f=t?i?function(e,t,V){if(n(e),t=A(t),n(V),"function"==typeof e&&"prototype"===t&&"value"in V&&c in V&&!V[c]){var i=s(e,t);i&&i[c]&&(e[t]=V.value,V={configurable:a in V?V[a]:i[a],enumerable:q in V?V[q]:i[q],writable:!1})}return r(e,t,V)}:r:function(e,t,i){if(n(e),t=A(t),n(i),V)try{return r(e,t,i)}catch(e){}if("get"in i||"set"in i)throw new o("Accessors not supported");return"value"in i&&(e[t]=i.value),e}}}),require_create_non_enumerable_property=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/create-non-enumerable-property.js"(e,t){"use strict";var V=require_descriptors(),i=require_object_define_property(),n=require_create_property_descriptor();t.exports=V?function(e,t,V){return i.f(e,t,n(1,V))}:function(e,t,V){return e[t]=V,e}}}),require_function_name=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/function-name.js"(e,t){"use strict";var V=require_descriptors(),i=require_has_own_property(),n=Function.prototype,A=V&&Object.getOwnPropertyDescriptor,o=i(n,"name"),r=o&&"something"===function(){}.name,s=o&&(!V||V&&A(n,"name").configurable);t.exports={EXISTS:o,PROPER:r,CONFIGURABLE:s}}}),require_inspect_source=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/inspect-source.js"(e,t){"use strict";var V=require_function_uncurry_this(),i=require_is_callable(),n=require_shared_store(),A=V(Function.toString);i(n.inspectSource)||(n.inspectSource=function(e){return A(e)}),t.exports=n.inspectSource}}),require_weak_map_basic_detection=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/weak-map-basic-detection.js"(e,t){"use strict";var V=require_global_this(),i=require_is_callable(),n=V.WeakMap;t.exports=i(n)&&/native code/.test(String(n))}}),require_shared_key=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/shared-key.js"(e,t){"use strict";var V=require_shared(),i=require_uid(),n=V("keys");t.exports=function(e){return n[e]||(n[e]=i(e))}}}),require_hidden_keys=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/hidden-keys.js"(e,t){"use strict";t.exports={}}}),require_internal_state=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/internal-state.js"(e,t){"use strict";var V,i,n,A,o,r=require_weak_map_basic_detection(),s=require_global_this(),q=require_is_object(),a=require_create_non_enumerable_property(),c=require_has_own_property(),l=require_shared_store(),d=require_shared_key(),p=require_hidden_keys(),h="Object already initialized",g=s.TypeError,u=s.WeakMap;r||l.state?((A=l.state||(l.state=new u)).get=A.get,A.has=A.has,A.set=A.set,V=function(e,t){if(A.has(e))throw new g(h);return t.facade=e,A.set(e,t),t},i=function(e){return A.get(e)||{}},n=function(e){return A.has(e)}):(p[o=d("state")]=!0,V=function(e,t){if(c(e,o))throw new g(h);return t.facade=e,a(e,o,t),t},i=function(e){return c(e,o)?e[o]:{}},n=function(e){return c(e,o)}),t.exports={set:V,get:i,has:n,enforce:function(e){return n(e)?i(e):V(e,{})},getterFor:function(e){return function(t){var V;if(!q(t)||(V=i(t)).type!==e)throw new g("Incompatible receiver, "+e+" required");return V}}}}}),require_make_built_in=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/make-built-in.js"(e,t){"use strict";var V=require_function_uncurry_this(),i=require_fails(),n=require_is_callable(),A=require_has_own_property(),o=require_descriptors(),r=require_function_name().CONFIGURABLE,s=require_inspect_source(),q=require_internal_state(),a=q.enforce,c=q.get,l=String,d=Object.defineProperty,p=V("".slice),h=V("".replace),g=V([].join),u=o&&!i((function(){return 8!==d((function(){}),"length",{value:8}).length})),m=String(String).split("String"),E=t.exports=function(e,t,V){"Symbol("===p(l(t),0,7)&&(t="["+h(l(t),/^Symbol\(([^)]*)\).*$/,"$1")+"]"),V&&V.getter&&(t="get "+t),V&&V.setter&&(t="set "+t),(!A(e,"name")||r&&e.name!==t)&&(o?d(e,"name",{value:t,configurable:!0}):e.name=t),u&&V&&A(V,"arity")&&e.length!==V.arity&&d(e,"length",{value:V.arity});try{V&&A(V,"constructor")&&V.constructor?o&&d(e,"prototype",{writable:!1}):e.prototype&&(e.prototype=void 0)}catch(e){}var i=a(e);return A(i,"source")||(i.source=g(m,"string"==typeof t?t:"")),e};Function.prototype.toString=E((function(){return n(this)&&c(this).source||s(this)}),"toString")}}),require_define_built_in=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/define-built-in.js"(e,t){"use strict";var V=require_is_callable(),i=require_object_define_property(),n=require_make_built_in(),A=require_define_global_property();t.exports=function(e,t,o,r){r||(r={});var s=r.enumerable,q=void 0!==r.name?r.name:t;if(V(o)&&n(o,q,r),r.global)s?e[t]=o:A(t,o);else{try{r.unsafe?e[t]&&(s=!0):delete e[t]}catch(e){}s?e[t]=o:i.f(e,t,{value:o,enumerable:!1,configurable:!r.nonConfigurable,writable:!r.nonWritable})}return e}}}),require_math_trunc=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/math-trunc.js"(e,t){"use strict";var V=Math.ceil,i=Math.floor;t.exports=Math.trunc||function(e){var t=+e;return(t>0?i:V)(t)}}}),require_to_integer_or_infinity=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/to-integer-or-infinity.js"(e,t){"use strict";var V=require_math_trunc();t.exports=function(e){var t=+e;return t!=t||0===t?0:V(t)}}}),require_to_absolute_index=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/to-absolute-index.js"(e,t){"use strict";var V=require_to_integer_or_infinity(),i=Math.max,n=Math.min;t.exports=function(e,t){var A=V(e);return A<0?i(A+t,0):n(A,t)}}}),require_to_length=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/to-length.js"(e,t){"use strict";var V=require_to_integer_or_infinity(),i=Math.min;t.exports=function(e){var t=V(e);return t>0?i(t,9007199254740991):0}}}),require_length_of_array_like=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/length-of-array-like.js"(e,t){"use strict";var V=require_to_length();t.exports=function(e){return V(e.length)}}}),require_array_includes=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/array-includes.js"(e,t){"use strict";var V=require_to_indexed_object(),i=require_to_absolute_index(),n=require_length_of_array_like(),A=function(e){return function(t,A,o){var r=V(t),s=n(r);if(0===s)return!e&&-1;var q,a=i(o,s);if(e&&A!=A){for(;s>a;)if((q=r[a++])!=q)return!0}else for(;s>a;a++)if((e||a in r)&&r[a]===A)return e||a||0;return!e&&-1}};t.exports={includes:A(!0),indexOf:A(!1)}}}),require_object_keys_internal=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/object-keys-internal.js"(e,t){"use strict";var V=require_function_uncurry_this(),i=require_has_own_property(),n=require_to_indexed_object(),A=require_array_includes().indexOf,o=require_hidden_keys(),r=V([].push);t.exports=function(e,t){var V,s=n(e),q=0,a=[];for(V in s)!i(o,V)&&i(s,V)&&r(a,V);for(;t.length>q;)i(s,V=t[q++])&&(~A(a,V)||r(a,V));return a}}}),require_enum_bug_keys=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/enum-bug-keys.js"(e,t){"use strict";t.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]}}),require_object_get_own_property_names=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/object-get-own-property-names.js"(e){"use strict";var t=require_object_keys_internal(),V=require_enum_bug_keys().concat("length","prototype");e.f=Object.getOwnPropertyNames||function(e){return t(e,V)}}}),require_object_get_own_property_symbols=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/object-get-own-property-symbols.js"(e){"use strict";e.f=Object.getOwnPropertySymbols}}),require_own_keys=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/own-keys.js"(e,t){"use strict";var V=require_get_built_in(),i=require_function_uncurry_this(),n=require_object_get_own_property_names(),A=require_object_get_own_property_symbols(),o=require_an_object(),r=i([].concat);t.exports=V("Reflect","ownKeys")||function(e){var t=n.f(o(e)),V=A.f;return V?r(t,V(e)):t}}}),require_copy_constructor_properties=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/copy-constructor-properties.js"(e,t){"use strict";var V=require_has_own_property(),i=require_own_keys(),n=require_object_get_own_property_descriptor(),A=require_object_define_property();t.exports=function(e,t,o){for(var r=i(t),s=A.f,q=n.f,a=0;a<r.length;a++){var c=r[a];V(e,c)||o&&V(o,c)||s(e,c,q(t,c))}}}}),require_is_forced=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/is-forced.js"(e,t){"use strict";var V=require_fails(),i=require_is_callable(),n=/#|\.prototype\./,A=function(e,t){var n=r[o(e)];return n===q||n!==s&&(i(t)?V(t):!!t)},o=A.normalize=function(e){return String(e).replace(n,".").toLowerCase()},r=A.data={},s=A.NATIVE="N",q=A.POLYFILL="P";t.exports=A}}),require_export=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/internals/export.js"(e,t){"use strict";var V=require_global_this(),i=require_object_get_own_property_descriptor().f,n=require_create_non_enumerable_property(),A=require_define_built_in(),o=require_define_global_property(),r=require_copy_constructor_properties(),s=require_is_forced();t.exports=function(e,t){var q,a,c,l,d,p=e.target,h=e.global,g=e.stat;if(q=h?V:g?V[p]||o(p,{}):V[p]&&V[p].prototype)for(a in t){if(l=t[a],c=e.dontCallGetSet?(d=i(q,a))&&d.value:q[a],!s(h?a:p+(g?".":"#")+a,e.forced)&&void 0!==c){if(typeof l==typeof c)continue;r(l,c)}(e.sham||c&&c.sham)&&n(l,"sham",!0),A(q,a,l,e)}}}}),require_es_global_this=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/modules/es.global-this.js"(){"use strict";var e=require_export(),t=require_global_this();e({global:!0,forced:t.globalThis!==t},{globalThis:t})}}),require_global_this2=__commonJS({"../node_modules/.pnpm/core-js@3.38.1/node_modules/core-js/es/global-this.js"(e,t){"use strict";require_es_global_this(),t.exports=require_global_this()}}),import_global_this=__toESM(require_global_this2(),1);function startValidateRule(e){return{name:"DeviceDetectorOptions",type:"object",required:!1,allowEmpty:!1,properties:{networkDetect:{required:!1,type:"object",properties:{sdkAppId:{required:!0,type:"number"},userId:{required:!0,type:"string"},userSig:{required:!0,type:"string"},downlinkUserId:{required:!1,type:"string"},downlinkUserSig:{required:!1,type:"string"},roomId:{required:!1,type:"number"}},async validate(t,V,i,n){const{RtcError:A,ErrorCode:o,ErrorCodeDictionary:r}=e.errorModule;if(!t)return;let{sdkAppId:s,userId:q,userSig:a,downlinkUserId:c,downlinkUserSig:l,roomId:d}=t;d=d||8080;const p=e.TRTC.create(),h=e.TRTC.create();await p.enterRoom({roomId:d,sdkAppId:s,userId:q,userSig:a}),await p.exitRoom(),p.destroy(),c&&l&&(await h.enterRoom({roomId:d,sdkAppId:s,userId:c,userSig:l}),await h.exitRoom(),h.destroy())}},cameraDetect:{required:!1,type:"object",properties:{mirror:{required:!1,type:"boolean"}}}}}}function stopValidateRule(e){return{name:"StopDeviceDetectorOptions",required:!1}}var _a,_b,t=globalThis,e=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,s=Symbol(),o=new WeakMap,n=class{constructor(e,t,V){if(this._$cssResult$=!0,V!==s)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=e,this.t=t}get styleSheet(){let t=this.o;const V=this.t;if(e&&void 0===t){const e=void 0!==V&&1===V.length;e&&(t=o.get(V)),void 0===t&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),e&&o.set(V,t))}return t}toString(){return this.cssText}},r=e=>new n("string"==typeof e?e:e+"",void 0,s),S=(V,i)=>{if(e)V.adoptedStyleSheets=i.map((e=>e instanceof CSSStyleSheet?e:e.styleSheet));else for(const e of i){const i=document.createElement("style"),n=t.litNonce;void 0!==n&&i.setAttribute("nonce",n),i.textContent=e.cssText,V.appendChild(i)}},c=e?e=>e:e=>e instanceof CSSStyleSheet?(e=>{let t="";for(const V of e.cssRules)t+=V.cssText;return r(t)})(e):e,{is:i2,defineProperty:e2,getOwnPropertyDescriptor:h,getOwnPropertyNames:r2,getOwnPropertySymbols:o2,getPrototypeOf:n2}=Object,a=globalThis,c2=a.trustedTypes,l=c2?c2.emptyScript:"",p=a.reactiveElementPolyfillSupport,d=(e,t)=>e,u={toAttribute(e,t){switch(t){case Boolean:e=e?l:null;break;case Object:case Array:e=null==e?e:JSON.stringify(e)}return e},fromAttribute(e,t){let V=e;switch(t){case Boolean:V=null!==e;break;case Number:V=null===e?null:Number(e);break;case Object:case Array:try{V=JSON.parse(e)}catch(e){V=null}}return V}},f=(e,t)=>!i2(e,t),b={attribute:!0,type:String,converter:u,reflect:!1,useDefault:!1,hasChanged:f};null!=(_a=Symbol.metadata)||(Symbol.metadata=Symbol("metadata")),null!=(_b=a.litPropertyMetadata)||(a.litPropertyMetadata=new WeakMap);var _a2,y=class extends HTMLElement{static addInitializer(e){var t;this._$Ei(),(null!=(t=this.l)?t:this.l=[]).push(e)}static get observedAttributes(){return this.finalize(),this._$Eh&&[...this._$Eh.keys()]}static createProperty(e,t=b){if(t.state&&(t.attribute=!1),this._$Ei(),this.prototype.hasOwnProperty(e)&&((t=Object.create(t)).wrapped=!0),this.elementProperties.set(e,t),!t.noAccessor){const V=Symbol(),i=this.getPropertyDescriptor(e,V,t);void 0!==i&&e2(this.prototype,e,i)}}static getPropertyDescriptor(e,t,V){var i;const{get:n,set:A}=null!=(i=h(this.prototype,e))?i:{get(){return this[t]},set(e){this[t]=e}};return{get:n,set(t){const i=null==n?void 0:n.call(this);null==A||A.call(this,t),this.requestUpdate(e,i,V)},configurable:!0,enumerable:!0}}static getPropertyOptions(e){var t;return null!=(t=this.elementProperties.get(e))?t:b}static _$Ei(){if(this.hasOwnProperty(d("elementProperties")))return;const e=n2(this);e.finalize(),void 0!==e.l&&(this.l=[...e.l]),this.elementProperties=new Map(e.elementProperties)}static finalize(){if(this.hasOwnProperty(d("finalized")))return;if(this.finalized=!0,this._$Ei(),this.hasOwnProperty(d("properties"))){const e=this.properties,t=[...r2(e),...o2(e)];for(const V of t)this.createProperty(V,e[V])}const e=this[Symbol.metadata];if(null!==e){const t=litPropertyMetadata.get(e);if(void 0!==t)for(const[e,V]of t)this.elementProperties.set(e,V)}this._$Eh=new Map;for(const[e,t]of this.elementProperties){const V=this._$Eu(e,t);void 0!==V&&this._$Eh.set(V,e)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(e){const t=[];if(Array.isArray(e)){const V=new Set(e.flat(1/0).reverse());for(const e of V)t.unshift(c(e))}else void 0!==e&&t.push(c(e));return t}static _$Eu(e,t){const V=t.attribute;return!1===V?void 0:"string"==typeof V?V:"string"==typeof e?e.toLowerCase():void 0}constructor(){super(),this._$Ep=void 0,this.isUpdatePending=!1,this.hasUpdated=!1,this._$Em=null,this._$Ev()}_$Ev(){var e;this._$ES=new Promise((e=>this.enableUpdating=e)),this._$AL=new Map,this._$E_(),this.requestUpdate(),null==(e=this.constructor.l)||e.forEach((e=>e(this)))}addController(e){var t,V;(null!=(t=this._$EO)?t:this._$EO=new Set).add(e),void 0!==this.renderRoot&&this.isConnected&&(null==(V=e.hostConnected)||V.call(e))}removeController(e){var t;null==(t=this._$EO)||t.delete(e)}_$E_(){const e=new Map,t=this.constructor.elementProperties;for(const V of t.keys())this.hasOwnProperty(V)&&(e.set(V,this[V]),delete this[V]);e.size>0&&(this._$Ep=e)}createRenderRoot(){var e;const t=null!=(e=this.shadowRoot)?e:this.attachShadow(this.constructor.shadowRootOptions);return S(t,this.constructor.elementStyles),t}connectedCallback(){var e;null!=this.renderRoot||(this.renderRoot=this.createRenderRoot()),this.enableUpdating(!0),null==(e=this._$EO)||e.forEach((e=>{var t;return null==(t=e.hostConnected)?void 0:t.call(e)}))}enableUpdating(e){}disconnectedCallback(){var e;null==(e=this._$EO)||e.forEach((e=>{var t;return null==(t=e.hostDisconnected)?void 0:t.call(e)}))}attributeChangedCallback(e,t,V){this._$AK(e,V)}_$ET(e,t){var V;const i=this.constructor.elementProperties.get(e),n=this.constructor._$Eu(e,i);if(void 0!==n&&!0===i.reflect){const A=(void 0!==(null==(V=i.converter)?void 0:V.toAttribute)?i.converter:u).toAttribute(t,i.type);this._$Em=e,null==A?this.removeAttribute(n):this.setAttribute(n,A),this._$Em=null}}_$AK(e,t){var V,i,n,A;const o=this.constructor,r=o._$Eh.get(e);if(void 0!==r&&this._$Em!==r){const e=o.getPropertyOptions(r),s="function"==typeof e.converter?{fromAttribute:e.converter}:void 0!==(null==(V=e.converter)?void 0:V.fromAttribute)?e.converter:u;this._$Em=r,this[r]=null!=(A=null!=(n=s.fromAttribute(t,e.type))?n:null==(i=this._$Ej)?void 0:i.get(r))?A:null,this._$Em=null}}requestUpdate(e,t,V){var i,n;if(void 0!==e){const A=this.constructor,o=this[e];if(null!=V||(V=A.getPropertyOptions(e)),!((null!=(i=V.hasChanged)?i:f)(o,t)||V.useDefault&&V.reflect&&o===(null==(n=this._$Ej)?void 0:n.get(e))&&!this.hasAttribute(A._$Eu(e,V))))return;this.C(e,t,V)}!1===this.isUpdatePending&&(this._$ES=this._$EP())}C(e,t,{useDefault:V,reflect:i,wrapped:n},A){var o,r,s;V&&!(null!=(o=this._$Ej)?o:this._$Ej=new Map).has(e)&&(this._$Ej.set(e,null!=(r=null!=A?A:t)?r:this[e]),!0!==n||void 0!==A)||(this._$AL.has(e)||(this.hasUpdated||V||(t=void 0),this._$AL.set(e,t)),!0===i&&this._$Em!==e&&(null!=(s=this._$Eq)?s:this._$Eq=new Set).add(e))}async _$EP(){this.isUpdatePending=!0;try{await this._$ES}catch(e){Promise.reject(e)}const e=this.scheduleUpdate();return null!=e&&await e,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){var e;if(!this.isUpdatePending)return;if(!this.hasUpdated){if(null!=this.renderRoot||(this.renderRoot=this.createRenderRoot()),this._$Ep){for(const[e,t]of this._$Ep)this[e]=t;this._$Ep=void 0}const e=this.constructor.elementProperties;if(e.size>0)for(const[t,V]of e){const{wrapped:e}=V,i=this[t];!0!==e||this._$AL.has(t)||void 0===i||this.C(t,void 0,V,i)}}let t=!1;const V=this._$AL;try{t=this.shouldUpdate(V),t?(this.willUpdate(V),null==(e=this._$EO)||e.forEach((e=>{var t;return null==(t=e.hostUpdate)?void 0:t.call(e)})),this.update(V)):this._$EM()}catch(e){throw t=!1,this._$EM(),e}t&&this._$AE(V)}willUpdate(e){}_$AE(e){var t;null==(t=this._$EO)||t.forEach((e=>{var t;return null==(t=e.hostUpdated)?void 0:t.call(e)})),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(e)),this.updated(e)}_$EM(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$ES}shouldUpdate(e){return!0}update(e){this._$Eq&&(this._$Eq=this._$Eq.forEach((e=>this._$ET(e,this[e])))),this._$EM()}updated(e){}firstUpdated(e){}};y.elementStyles=[],y.shadowRootOptions={mode:"open"},y[d("elementProperties")]=new Map,y[d("finalized")]=new Map,null==p||p({ReactiveElement:y}),(null!=(_a2=a.reactiveElementVersions)?_a2:a.reactiveElementVersions=[]).push("2.1.0");var t2=globalThis,i3=t2.trustedTypes,s2=i3?i3.createPolicy("lit-html",{createHTML:e=>e}):void 0,e3="$lit$",h2=`lit$${Math.random().toFixed(9).slice(2)}$`,o3="?"+h2,n3=`<${o3}>`,r3=document,l2=()=>r3.createComment(""),c3=e=>null===e||"object"!=typeof e&&"function"!=typeof e,a2=Array.isArray,u2=e=>a2(e)||"function"==typeof(null==e?void 0:e[Symbol.iterator]),d2="[ \t\n\f\r]",f2=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,v=/-->/g,_=/>/g,m=RegExp(`>|${d2}(?:([^\\s"'>=/]+)(${d2}*=${d2}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,"g"),p2=/'/g,g=/"/g,$=/^(?:script|style|textarea|title)$/i,y2=e=>(t,...V)=>({_$litType$:e,strings:t,values:V}),x=y2(1),b2=y2(2),w=y2(3),T=Symbol.for("lit-noChange"),E=Symbol.for("lit-nothing"),A=new WeakMap,C=r3.createTreeWalker(r3,129);function P(e,t){if(!a2(e)||!e.hasOwnProperty("raw"))throw Error("invalid template strings array");return void 0!==s2?s2.createHTML(t):t}var V=(e,t)=>{const V=e.length-1,i=[];let n,A=2===t?"<svg>":3===t?"<math>":"",o=f2;for(let t=0;t<V;t++){const V=e[t];let r,s,q=-1,a=0;for(;a<V.length&&(o.lastIndex=a,s=o.exec(V),null!==s);)a=o.lastIndex,o===f2?"!--"===s[1]?o=v:void 0!==s[1]?o=_:void 0!==s[2]?($.test(s[2])&&(n=RegExp("</"+s[2],"g")),o=m):void 0!==s[3]&&(o=m):o===m?">"===s[0]?(o=null!=n?n:f2,q=-1):void 0===s[1]?q=-2:(q=o.lastIndex-s[2].length,r=s[1],o=void 0===s[3]?m:'"'===s[3]?g:p2):o===g||o===p2?o=m:o===v||o===_?o=f2:(o=m,n=void 0);const c=o===m&&e[t+1].startsWith("/>")?" ":"";A+=o===f2?V+n3:q>=0?(i.push(r),V.slice(0,q)+e3+V.slice(q)+h2+c):V+h2+(-2===q?t:c)}return[P(e,A+(e[V]||"<?>")+(2===t?"</svg>":3===t?"</math>":"")),i]},N=class e{constructor({strings:t,_$litType$:i},n){let A;this.parts=[];let o=0,r=0;const s=t.length-1,q=this.parts,[a,c]=V(t,i);if(this.el=e.createElement(a,n),C.currentNode=this.el.content,2===i||3===i){const e=this.el.content.firstChild;e.replaceWith(...e.childNodes)}for(;null!==(A=C.nextNode())&&q.length<s;){if(1===A.nodeType){if(A.hasAttributes())for(const e of A.getAttributeNames())if(e.endsWith(e3)){const t=c[r++],V=A.getAttribute(e).split(h2),i=/([.?@])?(.*)/.exec(t);q.push({type:1,index:o,name:i[2],strings:V,ctor:"."===i[1]?H:"?"===i[1]?I:"@"===i[1]?L:k}),A.removeAttribute(e)}else e.startsWith(h2)&&(q.push({type:6,index:o}),A.removeAttribute(e));if($.test(A.tagName)){const e=A.textContent.split(h2),t=e.length-1;if(t>0){A.textContent=i3?i3.emptyScript:"";for(let V=0;V<t;V++)A.append(e[V],l2()),C.nextNode(),q.push({type:2,index:++o});A.append(e[t],l2())}}}else if(8===A.nodeType)if(A.data===o3)q.push({type:2,index:o});else{let e=-1;for(;-1!==(e=A.data.indexOf(h2,e+1));)q.push({type:7,index:o}),e+=h2.length-1}o++}}static createElement(e,t){const V=r3.createElement("template");return V.innerHTML=e,V}};function S2(e,t,V=e,i){var n,A,o;if(t===T)return t;let r=void 0!==i?null==(n=V._$Co)?void 0:n[i]:V._$Cl;const s=c3(t)?void 0:t._$litDirective$;return(null==r?void 0:r.constructor)!==s&&(null==(A=null==r?void 0:r._$AO)||A.call(r,!1),void 0===s?r=void 0:(r=new s(e),r._$AT(e,V,i)),void 0!==i?(null!=(o=V._$Co)?o:V._$Co=[])[i]=r:V._$Cl=r),void 0!==r&&(t=S2(e,r._$AS(e,t.values),r,i)),t}var _a3,M=class{constructor(e,t){this._$AV=[],this._$AN=void 0,this._$AD=e,this._$AM=t}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(e){var t;const{el:{content:V},parts:i}=this._$AD,n=(null!=(t=null==e?void 0:e.creationScope)?t:r3).importNode(V,!0);C.currentNode=n;let A=C.nextNode(),o=0,r=0,s=i[0];for(;void 0!==s;){if(o===s.index){let t;2===s.type?t=new R(A,A.nextSibling,this,e):1===s.type?t=new s.ctor(A,s.name,s.strings,this,e):6===s.type&&(t=new z(A,this,e)),this._$AV.push(t),s=i[++r]}o!==(null==s?void 0:s.index)&&(A=C.nextNode(),o++)}return C.currentNode=r3,n}p(e){let t=0;for(const V of this._$AV)void 0!==V&&(void 0!==V.strings?(V._$AI(e,V,t),t+=V.strings.length-2):V._$AI(e[t])),t++}},R=class e{get _$AU(){var e,t;return null!=(t=null==(e=this._$AM)?void 0:e._$AU)?t:this._$Cv}constructor(e,t,V,i){var n;this.type=2,this._$AH=E,this._$AN=void 0,this._$AA=e,this._$AB=t,this._$AM=V,this.options=i,this._$Cv=null==(n=null==i?void 0:i.isConnected)||n}get parentNode(){let e=this._$AA.parentNode;const t=this._$AM;return void 0!==t&&11===(null==e?void 0:e.nodeType)&&(e=t.parentNode),e}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(e,t=this){e=S2(this,e,t),c3(e)?e===E||null==e||""===e?(this._$AH!==E&&this._$AR(),this._$AH=E):e!==this._$AH&&e!==T&&this._(e):void 0!==e._$litType$?this.$(e):void 0!==e.nodeType?this.T(e):u2(e)?this.k(e):this._(e)}O(e){return this._$AA.parentNode.insertBefore(e,this._$AB)}T(e){this._$AH!==e&&(this._$AR(),this._$AH=this.O(e))}_(e){this._$AH!==E&&c3(this._$AH)?this._$AA.nextSibling.data=e:this.T(r3.createTextNode(e)),this._$AH=e}$(e){var t;const{values:V,_$litType$:i}=e,n="number"==typeof i?this._$AC(e):(void 0===i.el&&(i.el=N.createElement(P(i.h,i.h[0]),this.options)),i);if((null==(t=this._$AH)?void 0:t._$AD)===n)this._$AH.p(V);else{const e=new M(n,this),t=e.u(this.options);e.p(V),this.T(t),this._$AH=e}}_$AC(e){let t=A.get(e.strings);return void 0===t&&A.set(e.strings,t=new N(e)),t}k(t){a2(this._$AH)||(this._$AH=[],this._$AR());const V=this._$AH;let i,n=0;for(const A of t)n===V.length?V.push(i=new e(this.O(l2()),this.O(l2()),this,this.options)):i=V[n],i._$AI(A),n++;n<V.length&&(this._$AR(i&&i._$AB.nextSibling,n),V.length=n)}_$AR(e=this._$AA.nextSibling,t){var V;for(null==(V=this._$AP)||V.call(this,!1,!0,t);e&&e!==this._$AB;){const t=e.nextSibling;e.remove(),e=t}}setConnected(e){var t;void 0===this._$AM&&(this._$Cv=e,null==(t=this._$AP)||t.call(this,e))}},k=class{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(e,t,V,i,n){this.type=1,this._$AH=E,this._$AN=void 0,this.element=e,this.name=t,this._$AM=i,this.options=n,V.length>2||""!==V[0]||""!==V[1]?(this._$AH=Array(V.length-1).fill(new String),this.strings=V):this._$AH=E}_$AI(e,t=this,V,i){const n=this.strings;let A=!1;if(void 0===n)e=S2(this,e,t,0),A=!c3(e)||e!==this._$AH&&e!==T,A&&(this._$AH=e);else{const i=e;let o,r;for(e=n[0],o=0;o<n.length-1;o++)r=S2(this,i[V+o],t,o),r===T&&(r=this._$AH[o]),A||(A=!c3(r)||r!==this._$AH[o]),r===E?e=E:e!==E&&(e+=(null!=r?r:"")+n[o+1]),this._$AH[o]=r}A&&!i&&this.j(e)}j(e){e===E?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,null!=e?e:"")}},H=class extends k{constructor(){super(...arguments),this.type=3}j(e){this.element[this.name]=e===E?void 0:e}},I=class extends k{constructor(){super(...arguments),this.type=4}j(e){this.element.toggleAttribute(this.name,!!e&&e!==E)}},L=class extends k{constructor(e,t,V,i,n){super(e,t,V,i,n),this.type=5}_$AI(e,t=this){var V;if((e=null!=(V=S2(this,e,t,0))?V:E)===T)return;const i=this._$AH,n=e===E&&i!==E||e.capture!==i.capture||e.once!==i.once||e.passive!==i.passive,A=e!==E&&(i===E||n);n&&this.element.removeEventListener(this.name,this,i),A&&this.element.addEventListener(this.name,this,e),this._$AH=e}handleEvent(e){var t,V;"function"==typeof this._$AH?this._$AH.call(null!=(V=null==(t=this.options)?void 0:t.host)?V:this.element,e):this._$AH.handleEvent(e)}},z=class{constructor(e,t,V){this.element=e,this.type=6,this._$AN=void 0,this._$AM=t,this.options=V}get _$AU(){return this._$AM._$AU}_$AI(e){S2(this,e)}},j=t2.litHtmlPolyfillSupport;null==j||j(N,R),(null!=(_a3=t2.litHtmlVersions)?_a3:t2.litHtmlVersions=[]).push("3.3.0");var _a4,B=(e,t,V)=>{var i,n;const A=null!=(i=null==V?void 0:V.renderBefore)?i:t;let o=A._$litPart$;if(void 0===o){const e=null!=(n=null==V?void 0:V.renderBefore)?n:null;A._$litPart$=o=new R(t.insertBefore(l2(),e),e,void 0,null!=V?V:{})}return o._$AI(e),o},s3=globalThis,i4=class extends y{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){var e;const t=super.createRenderRoot();return null!=(e=this.renderOptions).renderBefore||(e.renderBefore=t.firstChild),t}update(e){const t=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(e),this._$Do=B(t,this.renderRoot,this.renderOptions)}connectedCallback(){var e;super.connectedCallback(),null==(e=this._$Do)||e.setConnected(!0)}disconnectedCallback(){var e;super.disconnectedCallback(),null==(e=this._$Do)||e.setConnected(!1)}render(){return T}};i4._$litElement$=!0,i4.finalized=!0,null==(_a4=s3.litElementHydrateSupport)||_a4.call(s3,{LitElement:i4});var _a5,o4=s3.litElementPolyfillSupport;null==o4||o4({LitElement:i4}),(null!=(_a5=s3.litElementVersions)?_a5:s3.litElementVersions=[]).push("4.2.0");var Button=class extends HTMLElement{constructor(){super(),this.attachShadow({mode:"open"}),this.shadowRoot.appendChild(this.createTemplate()),this.buttonEle=this.shadowRoot.querySelector("button")}createTemplate(){const e=document.createElement("template");return e.innerHTML="\n <style>\n .button {\n padding: 6px 16px;\n border-radius: 4px;\n border: 0;\n outline: none;\n background-color: transparent;\n user-select: none;\n font-size: 0.875rem;\n min-width: 64px;\n box-sizing: border-box;\n font-weight: 500;\n line-height: 1.75;\n transition: background-color 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,\n box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,\n border 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;\n }\n .outlined { \n /* 看不到 听不到 */\n padding: 5px 15px;\n border: 1px solid #006eff;\n color: #006eff;\n cursor: pointer;\n }\n .contained {\n /* 听得到 */\n cursor: pointer;\n color: #ffffff;\n background-color: #006eff;\n box-shadow: 0px 3px 1px -2px rgb(0 0 0 / 20%), 0px 2px 2px 0px rgb(0 0 0 / 14%), 0px 1px 5px 0px rgb(0 0 0 / 12%);\n }\n .disabled {\n /* 禁止 开始检测 */\n box-shadow: none;\n color: rgba(0, 0, 0, 0.26);\n background-color: rgba(0, 0, 0, 0.12);\n }\n .close{\n color: #eeeeee!important;\n border-radius: 20px!important;\n border-color: #eeeeee!important;\n }\n </style>\n <button>\n <slot></slot>\n </button>\n ",e.content.cloneNode(!0)}connectedCallback(){const e=this.getAttribute("type"),t=this.getAttribute("class");this.buttonEle.type="button",this.buttonEle.classList.add("button",e,t);const V=this.getAttribute("on-click");if(V){const e=new Function(V);this.buttonEle.addEventListener("click",(()=>{e()}))}}attributeChangedCallback(e,t,V){"type"===e&&(this.buttonEle.classList.remove(t),this.buttonEle.classList.add(V)),"className"===e&&(this.buttonEle.classList.remove(t),this.buttonEle.classList.add(V))}};__publicField(Button,"observedAttributes",["className","type","on-click"]),customElements.get("trtc-custom-button")||customElements.define("trtc-custom-button",Button);var core,log,index=9999,sheet=`\n @media screen and (max-width: 769px) {\n .root {\n max-width: 32.5rem;\n }\n .device-detector-backdrop {\n width: 100%;\n height: 100%;\n position: fixed;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n display: flex;\n align-items: center;\n justify-content: center;\n background-color: rgba(0, 0, 0, 0.8);\n z-index: ${index};\n opacity: 1;\n transition: opacity 225ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;\n }\n .device-detector-backdrop .root {\n position: relative;\n width: 98vw;\n height: 72vh;\n font-size: 16px;\n box-shadow: 2px 1px -1px rgba(0, 0, 0, 0.2), 0px 1px 1px 0px rgba(0, 0, 0, 0.14), 0px 1px 3px 0px rgba(0, 0, 0, 0.12);\n background-color: #ffffff;\n border-radius: 4px;\n }\n .device-detector-backdrop .root .stepper {\n border-radius: 5px 5px 0 0;\n font-size: 36px;\n }\n .device-detector-backdrop .root .close {\n color: #eeeeee !important;\n border-radius: 20px !important;\n border-color: #eeeeee !important;\n position: absolute !important;\n cursor: pointer;\n top: -50px;\n right: 2px;\n }\n .arrow {\n width: 0;\n height: 0;\n border-left: 2vh solid transparent;\n border-right: 2vh solid transparent;\n border-bottom: 2vh solid red;\n position: absolute;\n left: 2vw;\n animation: moveUpDown 2s infinite ease-in-out;\n transform:rotate(45deg);\n z-index: ${index+1};\n }\n \n .arrow::after {\n content: "";\n width: 1.5vh;\n height: 4vh;\n background-color: red;\n position: absolute;\n // top: 9px; /* 将柄定位在箭头的下方 */\n left: 50%; /* 水平居中柄 */\n transform: translate(-50%,18%); /* 微调柄的水平位置,使其完全居中 */\n z-index: ${index+1};\n }\n \n .remind-text {\n position: absolute;\n top: 10vh; /* 调整文字的垂直位置 */\n left: 1vw;\n width:90vw;\n color:red;\n z-index: ${index+1};\n }\n \n @keyframes moveUpDown {\n 0% {\n top: 3vh;\n left: 2vw;\n }\n \n 50% {\n top: 1.5vh;\n left: 3vw; \n }\n \n 100% {\n top: 3vh;\n left: 2vw;\n }\n }\n .device-connect {\n display: flex;\n flex-direction: column;\n align-items: center;\n height: 100%;\n }\n .device-connect .testing-title {\n display: flex;\n font-size: 2rem;\n justify-content: center;\n margin-top: 4vh;\n color: rgba(32, 30, 30, 0.8980392157);\n }\n .device-connect .testing-prepare-info {\n max-width: 500px;\n padding: 0 1vw;\n text-align: center;\n display: flex;\n font-size: 1rem;\n justify-content: center;\n margin-top: 3.8vh;\n color: rgba(88, 86, 86, 0.8980392157);\n }\n .device-connect .device-display {\n width: 88%;\n margin: 3vh auto 1.5vh;\n display: flex;\n justify-content: space-around;\n position: relative;\n }\n .device-connect .device-display .connect-success {\n position: relative;\n }\n .device-connect .device-display .connect-success::before {\n content: "";\n width: 28px;\n height: 28px;\n position: absolute;\n bottom: -34px;\n left: 50%;\n transform: translateX(-50%);\n background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAACAElEQVRYR+2Vv2sUQRTH3/eOYO+f EWzmzUaSTv8CYxIUAooWAYsQJEkRRDRikUJMiiMIQRSVCNql0sqkCIFwO7NLCGm00kpEEBtzhsyT Pe5kWG9zu8p5zU658958Pnznx4L6PNBnPpUCZQJlAj1PgOu8SBW6C0HNBGYmfe17KqBCdRvA/TbU OXc+Hoq3fImeCahQLQBY8mDGahv8lwR0qOcF8sCDfSCicavtXs8F2PBNIlrxQB9dxU3EKq53evY7 boGyahDHuCRVWY04+pL3f8GGp4mo1q4H8JkcTZjAbGet0VGADUurYd8dubF4OH7fTUJZdQOCR17d t1bs707q/UNgZH/kdKPR+Oofnupx9WL9bP1T1kJseIqI1rz5HwIZjzh60008awvuQXDndzNoR0hG O20HG75ORE+8WldBZSxU4UY3eDKfeQ211UsisuAtsjlwNDC6O7z7vf1NWXUFgucp0GWr7es88BMF kklt9UMRmfUWe3t46vDCwZmDnzrUkwJZ90ECuRpx9CIvvKtAUsCWaySUnO7mEJENAC+J6JUPgmDK BOZxEXgugaZEyGsESg5a1pi22q4WhecWaEoYfkpE19IQEZmLgmj5b+CFBJJiZdU6BJNtGAS3TGD8 976wR+GfUSuJc+TomR2yi4WJqYbCAv8KTPeXAmUCZQJ9T+AXo7StIY0IqrkAAAAASUVORK5CYII=") no-repeat;\n background-size: 100% 100%;\n }\n .device-connect .device-display .connect-fail {\n position: relative;\n }\n .device-connect .device-display .connect-fail::before {\n content: "";\n width: 28px;\n height: 28px;\n position: absolute;\n bottom: -34px;\n left: 50%;\n transform: translateX(-50%);\n background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAB3ElEQVRYR+2Wr08cQRTHP+8ESZOq GlKBaKhpUwWmCnG7d4giwDS5NGlVMWDAtIZfrQEDpjVF0ZC0wH/QWxr+gNrKJigSBA4J98hN7pbl 9mZnZklz5tasmPfm+5nve/t2hAE/MmB9hgBDB5wOaJVx+c2/Ms2qEc+BCznm3JZvBdBpHnPNmUlU VuWYzyEQGrGC8KmdI4m92e0AbXrhbyoqfJQmWz4QWuMDymYa2+KpzcXCEmjMOrCWEV2WhJ0iCI1Z ArbTGId77h7ohRAWpcnXfhBaYwHlS4hrTgDTAnkn5iVhNwuhMe+BbyFumf7wqakF4p0kfO+svQX2 Mie3utSr5w3QF6JCw2zY4kdm45w7RYcMArA4kd0/dcXX2WAAK0SFhvzip69wN64cQJ0XtDgEnmXq /lqaHP13AK0yQcWIj+fEhGCIIAc05iUY8bGO+EbnfTusAiG8AbTOVMf20a64JGZS5udEAIQXgEbE CAfAo17xbhlyw8oTwgmgMa/AdPdDm/h9IIp/RjXmUCM+4hIvC2H/HdeZpMWfTKdvdGvu+tRy5bji iZxw2i+v6D7wBmHf9+S9m9+BKH0fiJilwgNp3pn1LgPSdY2YQbiUhBNbkrMJvdVKBg4Bhg4M3IEb uI2UIfOyj40AAAAASUVORK5CYII=") no-repeat;\n background-size: 100% 100%;\n }\n .device-connect .device-display .device {\n width: 46px;\n height: 46px;\n position: relative;\n justify-content: center;\n font-size: 38px;\n }\n .device-connect .device-display .device svg {\n width: 36px;\n height: 36px;\n fill: #47494D;\n }\n .device-connect .device-display .outer-progress {\n width: 83%;\n height: 4px;\n border-radius: 5px;\n position: absolute;\n top: 70px;\n background-color: #eeeeee;\n overflow: hidden;\n }\n .device-connect .device-display .outer-progress .inner-progress {\n width: 100%;\n position: absolute;\n top: 0;\n left: -100%;\n height: 4px;\n border-radius: 5px;\n background-color: #bfbfbf;\n transform-origin: left;\n transition: transform 0.3s linear;\n }\n .device-connect .text {\n margin-top: 4.5vh;\n font-size: 1rem;\n max-width: 420px;\n text-align: center;\n height: 20px;\n display: flex;\n align-items: center;\n justify-content: center;\n }\n .device-connect .text.gray-text {\n color: rgba(88, 86, 86, 0.8980392157);\n }\n .device-connect .text.green-text {\n color: rgb(50, 205, 50);\n }\n .device-connect .text.red-text {\n color: red;\n }\n .device-connect .button-container {\n position: absolute;\n bottom: 3vh;\n width: 40%;\n display: flex;\n justify-content: space-around;\n }\n .error-connect {\n width: 20px;\n height: 20px;\n margin-left: 8px;\n display: inline;\n }\n .error-connect .error-icon svg {\n width: 20px;\n height: 20px;\n }\n .connect-attention-info {\n padding: 1vw 1vh;\n min-width: 134px;\n min-height: 50px;\n background: rgba(0, 0, 0, 0.6);\n border-radius: 10px;\n color: rgb(255, 255, 255);\n position: absolute;\n top:23vh;\n display: block;\n font-size: 0.8rem;\n text-align: left;\n max-width: 92vw;\n white-space: nowrap;\n white-space: normal; // 添加这一行,使其自动换行\n word-wrap: break-word; /* 添加自动换行样式 */\n overflow-wrap: anywhere; /* 允许在任意位置换行 */\n }\n .error-connect .connect-attention-info::after {\n content: "";\n width: 0;\n height: 0;\n border: 10px transparent solid;\n border-top-color: rgba(0, 0, 0, 0.6);\n position: absolute;\n left: 100%;\n top: 100%;\n transform: translateX(-18vw);\n }\n .testing-body {\n display: flex;\n flex-wrap: wrap;\n justify-content: center;\n }\n .testing-body.hide {\n display: none;\n }\n .testing-body .device-list {\n width: 93%;\n display: flex;\n justify-content: center;\n align-items: center;\n margin-bottom: 2vh;\n }\n .testing-body .device-list .device-list-title {\n margin-right: 1vw;\n font-size: 0.8rem;\n }\n .testing-body .flex-col {\n display: flex;\n flex-direction: column;\n align-items: center;\n }\n .testing-body .checkbox {\n display: flex;\n align-items: center;\n }\n .testing-body .camera-video {\n max-width: 80vw;\n height: 32vh;\n object-fit: contain; /* 保持视频的宽高比,将其完整显示在框内 */\n }\n .testing-body .mirror {\n transform: scaleX(-1);\n }\n .testing-container {\n width: 100%;\n margin: 10px auto 30px;\n }\n .testing-container .testing-body {\n display: flex;\n flex-wrap: wrap;\n justify-content: center;\n }\n .testing-container .testing-body.hide {\n display: none;\n }\n .testing-container .testing-body .device-list {\n width: 100%;\n display: flex;\n justify-content: center;\n align-items: center;\n margin-bottom: 20px;\n }\n .testing-container .testing-body .device-list .device-list-title {\n margin-right: 10px;\n }\n .testing-container .testing-body .flex-col {\n display: flex;\n flex-direction: column;\n align-items: center;\n }\n .testing-container .testing-body .checkbox {\n display: flex;\n align-items: center;\n }\n .testing-container .testing-body .camera-video {\n width: 300px;\n height: 180px;\n }\n .testing-container .testing-body .mirror {\n transform: scaleX(-1);\n }\n .audio-player-container {\n width: 340px;\n display: flex;\n justify-content: center;\n flex-wrap: wrap;\n margin: 2vh auto 0;\n text-align: center;\n }\n .audio-player-container .audio-player-info {\n margin: 0px auto 16px;\n color: #5f5f5f;\n }\n .audio-player-container #audio-player {\n width: 100%;\n }\n .testing-info-container {\n display: flex;\n width: 100%;\n justify-content: center;\n flex-wrap: wrap;\n position: absolute;\n bottom: 3vh;\n }\n .testing-info-container .testing-info {\n width: 100%;\n text-align: center;\n display: block;\n font-size:1rem;\n }\n .testing-info-container .button-list {\n margin-top: 2vh;\n width: 300px;\n display: flex;\n justify-content: space-around;\n }\n .device-select {\n width: 90%;\n padding: 6px 14px 6px 12px;\n position: relative;\n font-size: 0.8rem;\n border-radius: 4px;\n background-color: #fff;\n cursor: pointer;\n }\n .device-select:focus {\n outline: none;\n }\n .step-container {\n display: flex;\n margin-top: 2vh;\n margin-bottom: 2vh;\n padding: 0.3vw;\n font-size: 0.95rem;\n }\n .step-container .step {\n width: 100%;\n display: flex;\n flex-direction: column;\n align-items: center;\n position: relative;\n fill: rgba(0, 0, 0, 0.54);\n color: rgba(0, 0, 0, 0.54);\n }\n .step-container .step:not(:first-child)::after {\n position: absolute;\n content: "";\n height: 1px;\n background-color: rgba(0, 0, 0, 0.16);\n right: 100%;\n top: 30%;\n right: calc(50% + 20px);\n left: calc(-50% + 20px);\n top: 16px;\n }\n .step-container .step.active {\n fill: #006EFF;\n color: #006EFF;\n cursor: pointer;\n }\n .step-container .step.active::after {\n background-color: #006EFF;\n }\n .step-container .step.error {\n fill: red;\n color: red;\n cursor: pointer;\n }\n .step-container .step.error::after {\n background-color: #006EFF;\n }\n .step-container .step .step-label {\n margin-top: 12px;\n }\n .mic-testing-container {\n margin-top: 20px;\n width: 100%;\n }\n .mic-testing-container .mic-testing-info {\n text-align: center;\n }\n .mic-testing-container .mic-bar-container {\n display: flex;\n justify-content: center;\n margin-top: 10px;\n }\n .mic-testing-container .mic-bar-container .mic-bar {\n width: 8px;\n height: 30px;\n border: 1px solid #cccccc;\n border-radius: 1px;\n }\n .mic-testing-container .mic-bar-container .mic-bar:not(:first-child) {\n margin-left: 3px;\n }\n .mic-testing-container .mic-bar-container .mic-bar.active {\n background: #006EFF;\n }\n .recording-container {\n margin-top: 3vh;\n }\n .testing-list {\n width: 100%;\n display: flex;\n flex-wrap: wrap;\n }\n .testing-list .testing-item-container {\n width: 83%;\n margin: 0 auto 10px;\n display: flex;\n justify-content: space-between;\n }\n @keyframes loading-circle {\n 0% {\n transform: rotate(0deg);\n }\n 25% {\n transform: rotate(90deg);\n }\n 50% {\n transform: rotate(180deg);\n }\n 75% {\n transform: rotate(270deg);\n }\n 100% {\n transform: rotate(360deg);\n }\n }\n .network-loading {\n display: flex;\n }\n .network-loading::before {\n content: "";\n width: 16px;\n height: 16px;\n background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAChElEQVRYR82WO2wTQRCGZ9YFLmmCQDRUFIgOCuhMg2QJ8OxKtpQuEggqQDz6hDIiSAg6QEo6pFi+WVsoLgkVDakgFFBAlYJ0IGRceAetdWddLF/uznacXHe38/j2n9mbRTjkB6eRn4jOWGt/jhMrMwARlRDxkogUEfETM7/zCY0xqyKyAAAe4G70PStMZgCt9WsAuBUG3mLmi5VK5ZxSajuWrM7MtazJvd1EAER0HBG/AcBcPxji8yAIHhDREiJeA4A/IvLBWruUBJUIoLX+AgC7IvLEWruZVAIimldKXXXOefstb6u1lljCbWY+nwsg3MFi6LTJzFeyyloul48Vi8V/MfvvzHw2F0Cstl6BZWvts6wA3o6I3iDizdDnBTPfzwUQGVer1bl6vb6bJ3nM92S321WtVmtHa/3QnxBE/BwEwY14vD094KXfr2HGASGiBURcjXxF5KW19l70PgDQWr8HgBIA5Kp5GpTWeh0AqjG7HWY+PUsAn9xD9J/wVA2O5YGXIGzKklJq3jn30Vq7ltgDaXJOsu7nhS+xUuqyc+6t/1/k+hNOktz7GmNYRCgWp8bM9X4JiGhZKXVCRDb8x0mTDfuPmBnepD83+gDRr3O4QaYJorX+AQC+DHuacSYKhCovIuJ1ALiAiGu9Xu9ps9n8mnkaTkuN4cvLzAGGN3J0AIjoESKuiMgda+2raUmeFmegwEED+KPom+7QSpA0aY9ODwxLY4w51el0/rbb7d9pdZxkfb9Lqb9YTvVuMAo0EcDfZAqFwq9Go7Exzg6NMStBEDxO883VA0R0e9QRTerwtOS5x3E4tPpjNAoeTrp151xt1DFLg8ilQFKwmSmQtptx1v8DVbAxMP//OLQAAAAASUVORK5CYII=") no-repeat;\n background-size: 100% 100%;\n animation: loading-circle 2s linear infinite;\n }\n .report-button {\n position: absolute;\n bottom: 6vh;\n cursor: pointer;\n }\n .gray-button {\n position: absolute;\n bottom: 6vh;\n }\n .device-testing-report {\n display: flex;\n flex-wrap: wrap;\n flex-direction: column;\n align-items: center;\n }\n .device-testing-report .testing-title {\n display: flex;\n font-size: 4vh;\n justify-content: center;\n margin-top: 2vh;\n color: rgba(32, 30, 30, 0.8980392157);\n }\n .device-testing-report .device-report-list {\n display: block;\n width: 100%;\n margin-top: 10px;\n }\n .device-testing-report .device-report-list .device-report {\n display: flex;\n width: 70%;\n margin: 2vh auto 0;\n justify-content: space-between;\n }\n .device-testing-report .device-report-list .device-report .device-info {\n display: flex;\n width: 80%;\n }\n .device-testing-report .device-report-list .device-report .device-info .report-icon {\n margin-right: 20px;\n justify-content: center;\n font-size: 22px;\n line-height: 22px;\n color: #515151;\n }\n .device-testing-report .device-report-list .device-report .device-info .report-icon svg {\n width: 24px;\n height: 24px;\n }\n .device-testing-report .device-report-list .device-report .device-info .device-name {\n width: 280px;\n height: 24px;\n line-height: 24px;\n display: block;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n text-align: left;\n }\n .device-testing-report .device-report-list .device-report .green {\n color: green;\n }\n .device-testing-report .device-report-list .device-report .red {\n color: red;\n }\n .device-testing-report .device-report-footer {\n width: 65%;\n display: flex;\n justify-content: space-between;\n position: absolute;\n bottom: 36px;\n }\n }\n @media screen and (min-width: 769px) {\n .device-detector-backdrop {\n width: 100%;\n height: 100%;\n position: fixed;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n display: flex;\n align-items: center;\n justify-content: center;\n background-color: rgba(0, 0, 0, 0.8);\n z-index: ${index};\n opacity: 1;\n transition: opacity 225ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;\n }\n .device-detector-backdrop .root {\n position: relative;\n width: 600px;\n height: 480px;\n font-size: 16px;\n box-shadow: 2px 1px -1px rgba(0, 0, 0, 0.2), 0px 1px 1px 0px rgba(0, 0, 0, 0.14), 0px 1px 3px 0px rgba(0, 0, 0, 0.12);\n background-color: #ffffff;\n border-radius: 4px;\n }\n .device-detector-backdrop .root .stepper {\n border-radius: 5px 5px 0 0;\n font-size: 36px;\n }\n .device-detector-backdrop .root .close {\n color: #eeeeee !important;\n border-radius: 20px !important;\n border-color: #eeeeee !important;\n position: absolute !important;\n cursor: pointer;\n top: -50px;\n right: 2px;\n }\n\n .arrow {\n width: 0;\n height: 0;\n border-left: 2vh solid transparent;\n border-right: 2vh solid transparent;\n border-bottom: 2vh solid red;\n position: absolute;\n left: 2vw;\n animation: moveUpDown 2s infinite ease-in-out;\n transform:rotate(45deg);\n z-index: ${index+1};\n }\n \n .arrow::after {\n content: "";\n width: 1.5vh;\n height: 4vh;\n background-color: red;\n position: absolute;\n // top: 9px; /* 将柄定位在箭头的下方 */\n left: 50%; /* 水平居中柄 */\n transform: translate(-50%,18%); /* 微调柄的水平位置,使其完全居中 */\n z-index: ${index+1};\n }\n \n .remind-text {\n position: absolute;\n top: 10vh; /* 调整文字的垂直位置 */\n left: 1vw;\n width:30vw;\n color:red;\n z-index: ${index+1};\n }\n \n @keyframes moveUpDown {\n 0% {\n top: 3vh;\n left: 2vw;\n }\n \n 50% {\n top: 1.5vh;\n left: 3vw; \n }\n \n 100% {\n top: 3vh;\n left: 2vw;\n }\n }\n .device-connect {\n display: flex;\n flex-direction: column;\n align-items: center;\n }\n .device-connect .testing-title {\n display: flex;\n font-size: 32px;\n justify-content: center;\n margin-top: 55px;\n color: rgba(32, 30, 30, 0.8980392157);\n }\n .device-connect .testing-prepare-info {\n max-width: 500px;\n text-align: center;\n display: flex;\n font-size: 16px;\n justify-content: center;\n margin-top: 30px;\n color: rgba(88, 86, 86, 0.8980392157);\n }\n .device-connect .device-display {\n width: 420px;\n margin: 40px auto 20px;\n display: flex;\n justify-content: space-around;\n position: relative;\n }\n .device-connect .device-display .connect-success {\n position: relative;\n }\n .device-connect .device-display .connect-success::before {\n content: "";\n width: 28px;\n height: 28px;\n position: absolute;\n bottom: -34px;\n left: 50%;\n transform: translateX(-50%);\n background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAACAElEQVRYR+2Vv2sUQRTH3/eOYO+f EWzmzUaSTv8CYxIUAooWAYsQJEkRRDRikUJMiiMIQRSVCNql0sqkCIFwO7NLCGm00kpEEBtzhsyT Pe5kWG9zu8p5zU658958Pnznx4L6PNBnPpUCZQJlAj1PgOu8SBW6C0HNBGYmfe17KqBCdRvA/TbU OXc+Hoq3fImeCahQLQBY8mDGahv8lwR0qOcF8sCDfSCicavtXs8F2PBNIlrxQB9dxU3EKq53evY7 boGyahDHuCRVWY04+pL3f8GGp4mo1q4H8JkcTZjAbGet0VGADUurYd8dubF4OH7fTUJZdQOCR17d t1bs707q/UNgZH/kdKPR+Oofnupx9WL9bP1T1kJseIqI1rz5HwIZjzh60008awvuQXDndzNoR0hG O20HG75ORE+8WldBZSxU4UY3eDKfeQ211UsisuAtsjlwNDC6O7z7vf1NWXUFgucp0GWr7es88BMF kklt9UMRmfUWe3t46vDCwZmDnzrUkwJZ90ECuRpx9CIvvKtAUsCWaySUnO7mEJENAC+J6JUPgmDK BOZxEXgugaZEyGsESg5a1pi22q4WhecWaEoYfkpE19IQEZmLgmj5b+CFBJJiZdU6BJNtGAS3TGD8 976wR+GfUSuJc+TomR2yi4WJqYbCAv8KTPeXAmUCZQJ9T+AXo7StIY0IqrkAAAAASUVORK5CYII=") no-repeat;\n background-size: 100% 100%;\n }\n .device-connect .device-display .connect-fail {\n position: relative;\n }\n .device-connect .device-display .connect-fail::before {\n content: "";\n width: 28px;\n height: 28px;\n position: absolute;\n bottom: -34px;\n left: 50%;\n transform: translateX(-50%);\n background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAB3ElEQVRYR+2Wr08cQRTHP+8ESZOq GlKBaKhpUwWmCnG7d4giwDS5NGlVMWDAtIZfrQEDpjVF0ZC0wH/QWxr+gNrKJigSBA4J98hN7pbl 9mZnZklz5tasmPfm+5nve/t2hAE/MmB9hgBDB5wOaJVx+c2/Ms2qEc+BCznm3JZvBdBpHnPNmUlU VuWYzyEQGrGC8KmdI4m92e0AbXrhbyoqfJQmWz4QWuMDymYa2+KpzcXCEmjMOrCWEV2WhJ0iCI1Z ArbTGId77h7ohRAWpcnXfhBaYwHlS4hrTgDTAnkn5iVhNwuhMe+BbyFumf7wqakF4p0kfO+svQX2 Mie3utSr5w3QF6JCw2zY4kdm45w7RYcMArA4kd0/dcXX2WAAK0SFhvzip69wN64cQJ0XtDgEnmXq /lqaHP13AK0yQcWIj+fEhGCIIAc05iUY8bGO+EbnfTusAiG8AbTOVMf20a64JGZS5udEAIQXgEbE CAfAo17xbhlyw8oTwgmgMa/AdPdDm/h9IIp/RjXmUCM+4hIvC2H/HdeZpMWfTKdvdGvu+tRy5bji iZxw2i+v6D7wBmHf9+S9m9+BKH0fiJilwgNp3pn1LgPSdY2YQbiUhBNbkrMJvdVKBg4Bhg4M3IEb uI2UIfOyj40AAAAASUVORK5CYII=") no-repeat;\n background-size: 100% 100%;\n }\n .device-connect .device-display .device {\n width: 46px;\n height: 46px;\n position: relative;\n justify-content: center;\n font-size: 38px;\n }\n .device-connect .device-display .device svg {\n width: 36px;\n height: 36px;\n fill: #47494D;\n }\n .device-connect .device-display .outer-progress {\n width: 360px;\n height: 4px;\n border-radius: 5px;\n position: absolute;\n top: 70px;\n background-color: #eeeeee;\n overflow: hidden;\n }\n .device-connect .device-display .outer-progress .inner-progress {\n width: 100%;\n position: absolute;\n top: 0;\n left: -360px;\n height: 4px;\n border-radius: 5px;\n background-color: #bfbfbf;\n transform-origin: left;\n transition: transform 0.3s linear;\n }\n .device-connect .text {\n margin-top: 50px;\n font-size: 18px;\n max-width: 420px;\n text-align: center;\n height: 20px;\n display: flex;\n align-items: center;\n justify-content: center;\n }\n .device-connect .text.gray-text {\n color: rgba(88, 86, 86, 0.8980392157);\n }\n .device-connect .text.green-text {\n color: rgb(50, 205, 50);\n }\n .device-connect .text.red-text {\n color: red;\n }\n .device-connect .button-container {\n margin-top: 50px;\n width: 40%;\n display: flex;\n justify-content: space-around;\n }\n .error-connect {\n width: 20px;\n height: 20px;\n margin-left: 8px;\n position: relative;\n display: inline;\n }\n .error-connect .error-icon svg {\n width: 20px;\n height: 20px;\n }\n .error-connect .connect-attention-info {\n padding: 8px 12px;\n min-width: 160px;\n min-height: 50px;\n background: rgba(0, 0, 0, 0.6);\n border-radius: 10px;\n color: #fff;\n position: absolute;\n right: 0;\n bottom: 100%;\n transform: translate(20px, -10px);\n display: block;\n white-space: nowrap;\n font-size: 12px;\n text-align: left;\n }\n .error-connect .connect-attention-info::after {\n content: "";\n width: 0;\n height: 0;\n border: 10px transparent solid;\n border-top-color: rgba(0, 0, 0, 0.6);\n position: absolute;\n left: 100%;\n top: 100%;\n transform: translateX(-40px);\n }\n .testing-body {\n display: flex;\n flex-wrap: wrap;\n justify-content: center;\n }\n .testing-body.hide {\n display: none;\n }\n .testing-body .device-list {\n width: 100%;\n display: flex;\n justify-content: center;\n align-items: center;\n margin-bottom: 20px;\n }\n .testing-body .device-list .device-list-title {\n margin-right: 10px;\n }\n .testing-body .flex-col {\n display: flex;\n flex-direction: column;\n align-items: center;\n }\n .testing-body .checkbox {\n display: flex;\n align-items: center;\n }\n .testing-body .camera-video {\n width: 300px;\n height: 180px;\n }\n .testing-body .mirror {\n transform: scaleX(-1);\n }\n .testing-container {\n width: 100%;\n margin: 10px auto 30px;\n }\n .testing-container .testing-body {\n display: flex;\n flex-wrap: wrap;\n justify-content: center;\n }\n .testing-container .testing-body.hide {\n display: none;\n }\n .testing-container .testing-body .device-list {\n width: 100%;\n display: flex;\n justify-content: center;\n align-items: center;\n margin-bottom: 20px;\n }\n .testing-container .testing-body .device-list .device-list-title {\n margin-right: 10px;\n }\n .testing-container .testing-body .flex-col {\n display: flex;\n flex-direction: column;\n align-items: center;\n }\n .testing-container .testing-body .checkbox {\n display: flex;\n align-items: center;\n }\n .testing-container .testing-body .camera-video {\n width: 300px;\n height: 180px;\n }\n .testing-container .testing-body .mirror {\n transform: scaleX(-1);\n }\n .audio-player-container {\n width: 340px;\n display: flex;\n justify-content: center;\n flex-wrap: wrap;\n margin: 20px auto 0;\n text-align: center;\n }\n .audio-player-container .audio-player-info {\n margin: 0px auto 16px;\n color: #5f5f5f;\n }\n .testing-info-container {\n display: flex;\n width: 100%;\n justify-content: center;\n flex-wrap: wrap;\n position: absolute;\n bottom: 30px;\n }\n .testing-info-container .testing-info {\n width: 100%;\n text-align: center;\n display: block;\n }\n .testing-info-container .button-list {\n margin-top: 20px;\n width: 300px;\n display: flex;\n justify-content: space-around;\n }\n .device-select {\n width: 260px;\n padding: 6px 14px 6px 12px;\n position: relative;\n font-size: 16px;\n border-radius: 4px;\n background-color: #fff;\n cursor: pointer;\n }\n .device-select:focus {\n outline: none;\n }\n .step-container {\n display: flex;\n padding: 24px;\n }\n .step-container .step {\n width: 100%;\n display: flex;\n flex-direction: column;\n align-items: center;\n position: relative;\n fill: rgba(0, 0, 0, 0.54);\n color: rgba(0, 0, 0, 0.54);\n }\n .step-container .step:not(:first-child)::after {\n position: absolute;\n content: "";\n height: 1px;\n background-color: rgba(0, 0, 0, 0.16);\n right: 100%;\n top: 30%;\n right: calc(50% + 20px);\n left: calc(-50% + 20px);\n top: 16px;\n }\n .step-container .step.active {\n fill: #006EFF;\n color: #006EFF;\n cursor: pointer;\n }\n .step-container .step.active::after {\n background-color: #006EFF;\n }\n .step-container .step.error {\n fill: red;\n color: red;\n cursor: pointer;\n }\n .step-container .step.error::after {\n background-color: #006EFF;\n }\n .step-container .step .step-label {\n margin-top: 12px;\n }\n .mic-testing-container {\n margin-top: 20px;\n width: 100%;\n }\n .mic-testing-container .mic-testing-info {\n text-align: center;\n }\n .mic-testing-container .mic-bar-container {\n display: flex;\n justify-content: center;\n margin-top: 10px;\n }\n .mic-testing-container .mic-bar-container .mic-bar {\n width: 8px;\n height: 30px;\n border: 1px solid #cccccc;\n border-radius: 1px;\n }\n .mic-testing-container .mic-bar-container .mic-bar:not(:first-child) {\n margin-left: 3px;\n }\n .mic-testing-container .mic-bar-container .mic-bar.active {\n background: #006EFF;\n }\n .recording-container {\n margin-top: 5em;\n }\n .testing-list {\n width: 100%;\n display: flex;\n flex-wrap: wrap;\n }\n .testing-list .testing-item-container {\n width: 70%;\n margin: 0 auto 10px;\n display: flex;\n justify-content: space-between;\n }\n @keyframes loading-circle {\n 0% {\n transform: rotate(0deg);\n }\n 25% {\n transform: rotate(90deg);\n }\n 50% {\n transform: rotate(180deg);\n }\n 75% {\n transform: rotate(270deg);\n }\n 100% {\n transform: rotate(360deg);\n }\n }\n .network-loading {\n display: flex;\n }\n .network-loading::before {\n content: "";\n width: 16px;\n height: 16px;\n background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAChElEQVRYR82WO2wTQRCGZ9YFLmmCQDRUFIgOCuhMg2QJ8OxKtpQuEggqQDz6hDIiSAg6QEo6pFi+WVsoLgkVDakgFFBAlYJ0IGRceAetdWddLF/uznacXHe38/j2n9mbRTjkB6eRn4jOWGt/jhMrMwARlRDxkogUEfETM7/zCY0xqyKyAAAe4G70PStMZgCt9WsAuBUG3mLmi5VK5ZxSajuWrM7MtazJvd1EAER0HBG/AcBcPxji8yAIHhDREiJeA4A/IvLBWruUBJUIoLX+AgC7IvLEWruZVAIimldKXXXOefstb6u1lljCbWY+nwsg3MFi6LTJzFeyyloul48Vi8V/MfvvzHw2F0Cstl6BZWvts6wA3o6I3iDizdDnBTPfzwUQGVer1bl6vb6bJ3nM92S321WtVmtHa/3QnxBE/BwEwY14vD094KXfr2HGASGiBURcjXxF5KW19l70PgDQWr8HgBIA5Kp5GpTWeh0AqjG7HWY+PUsAn9xD9J/wVA2O5YGXIGzKklJq3jn30Vq7ltgDaXJOsu7nhS+xUuqyc+6t/1/k+hNOktz7GmNYRCgWp8bM9X4JiGhZKXVCRDb8x0mTDfuPmBnepD83+gDRr3O4QaYJorX+AQC+DHuacSYKhCovIuJ1ALiAiGu9Xu9ps9n8mnkaTkuN4cvLzAGGN3J0AIjoESKuiMgda+2raUmeFmegwEED+KPom+7QSpA0aY9ODwxLY4w51el0/rbb7d9pdZxkfb9Lqb9YTvVuMAo0EcDfZAqFwq9Go7Exzg6NMStBEDxO883VA0R0e9QRTerwtOS5x3E4tPpjNAoeTrp151xt1DFLg8ilQFKwmSmQtptx1v8DVbAxMP//OLQAAAAASUVORK5CYII=") no-repeat;\n background-size: 100% 100%;\n animation: loading-circle 2s linear infinite;\n }\n .report-button {\n position: absolute;\n bottom: 60px;\n cursor: pointer;\n }\n .gray-button {\n position: absolute;\n bottom: 60px;\n }\n .device-testing-report {\n display: flex;\n flex-wrap: wrap;\n flex-direction: column;\n align-items: center;\n }\n .device-testing-report .testing-title {\n display: flex;\n font-size: 34px;\n justify-content: center;\n margin-top: 30px;\n color: rgba(32, 30, 30, 0.8980392157);\n }\n .device-testing-report .device-report-list {\n display: block;\n width: 100%;\n margin-top: 10px;\n }\n .device-testing-report .device-report-list .device-report {\n display: flex;\n width: 70%;\n margin: 20px auto 0;\n justify-content: space-between;\n }\n .device-testing-report .device-report-list .device-report .device-info {\n display: flex;\n width: 80%;\n }\n .device-testing-report .device-report-list .device-report .device-info .report-icon {\n margin-right: 20px;\n justify-content: center;\n font-size: 22px;\n line-height: 22px;\n color: #515151;\n }\n .device-testing-report .device-report-list .device-report .device-info .report-icon svg {\n width: 24px;\n height: 24px;\n }\n .device-testing-report .device-report-list .device-report .device-info .device-name {\n width: 280px;\n height: 24px;\n line-height: 24px;\n display: block;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n text-align: left;\n }\n .device-testing-report .device-report-list .device-report .green {\n color: green;\n }\n .device-testing-report .device-report-list .device-report .red {\n color: red;\n }\n .device-testing-report .device-report-footer {\n width: 50%;\n display: flex;\n justify-content: space-between;\n position: absolute;\n bottom: 36px;\n }\n }\n`,style1_default=sheet,USER_AGENT=window.navigator&&window.navigator.userAgent||"",webkitVersionMap=/AppleWebKit\/([\d.]+)/i.exec(USER_AGENT),appleWebkitVersion=webkitVersionMap?parseFloat(webkitVersionMap.pop()||"0"):null,IS_IPAD=/iPad/i.test(USER_AGENT),IS_IPHONE=/iPhone/i.test(USER_AGENT)&&!IS_IPAD,IS_IPOD=/iPod/i.test(USER_AGENT),IS_IOS=IS_IPHONE||IS_IPAD||IS_IPOD,IOS_VERSION=IS_IOS&&function(){const e=USER_AGENT.match(/OS (\d+)_/i);return e&&e[1]?e[1]:null}(),IS_ANDROID=/Android/i.test(USER_AGENT),ANDROID_VERSION=IS_ANDROID&&function(){const e=USER_AGENT.match(/Android (\d+)(?:\.(\d+))?(?:\.(\d+))*/i);if(!e)return null;const t=e[1]&&parseFloat(e[1]),V=e[2]&&parseFloat(e[2]);return t&&V?parseFloat(`${e[1]}.${e[2]}`):t||null}(),IS_OLD_ANDROID=IS_ANDROID&&/webkit/i.test(USER_AGENT)&&ANDROID_VERSION<2.3,IS_NATIVE_ANDROID=IS_ANDROID&&ANDROID_VERSION<5&&appleWebkitVersion<537,IS_FIREFOX=/Firefox/i.test(USER_AGENT),FIREFOX_VERSION=IS_FIREFOX&&function(){const e=USER_AGENT.match(/Firefox\/(\d+)/);return e&&e[1]?parseFloat(e[1]):null}(),IS_EDGE=/Edge\//i.test(USER_AGENT),EDGE_VERSION=IS_EDGE&&function(){const e=USER_AGENT.match(/Edge\/(\d+)/i);if(e&&e[1])return e[1]}(),IS_EDG=/Edg\//i.test(USER_AGENT),EDG_VERSION=IS_EDG&&function(){const e=USER_AGENT.match(/Edg\/(\d+)/);return e&&e[1]?parseFloat(e[1]):null}(),IS_SOGOUM=/SogouMobileBrowser\//i.test(USER_AGENT),SOGOUM_VERSION=IS_SOGOUM&&function(){const e=USER_AGENT.match(/SogouMobileBrowser\/(\d+)/);return e&&e[1]?parseFloat(e[1]):null}(),IS_SOGOU=/MetaSr\s/i.test(USER_AGENT),SOGOU_VERSION=IS_SOGOU&&function(){const e=USER_AGENT.match(/MetaSr(\s\d+(\.\d+)+)/);return e&&e[1]?parseFloat(e[1]):null}(),IS_TBS=/TBS\/\d+/i.test(USER_AGENT),TBS_VERSION=IS_TBS&&function(){const e=USER_AGENT.match(/TBS\/(\d+)/i);if(e&&e[1])return e[1]}(),IS_XWEB=/XWEB\/\d+/i.test(USER_AGENT),XWEB_VERSION=IS_XWEB&&function(){const e=USER_AGENT.match(/XWEB\/(\d+)/i);if(e&&e[1])return e[1]}(),IS_IE8=/MSIE\s8\.0/.test(USER_AGENT),IS_IE=/MSIE\/\d+/i.test(USER_AGENT),IE_VERSION=IS_IE&&function(){const e=/MSIE\s(\d+)\.\d/.exec(USER_AGENT);let t=e&&parseFloat(e[1]);return!t&&/Trident\/7.0/i.test(USER_AGENT)&&/rv:11.0/.test(USER_AGENT)&&(t=11),t}(),IS_PC_WECHAT=/windowswechat/i.test(USER_AGENT),IS_WECHAT=/(micromessenger|webbrowser)/i.test(USER_AGENT),WECHAT_VERSION=IS_WECHAT&&function(){const e=USER_AGENT.match(/MicroMessenger\/(\d+)/i);if(e&&e[1])return e[1]}(),IS_X5MQQB=!IS_TBS&&/MQQBrowser\/\d+/i.test(USER_AGENT)&&/COVC\/\d+/i.test(USER_AGENT),IS_MQQB=!IS_TBS&&/MQQBrowser\/\d+/i.test(USER_AGENT)&&!/COVC\/\d+/i.test(USER_AGENT),MQQB_VERSION=(IS_MQQB||IS_X5MQQB)&&function(){const e=USER_AGENT.match(/ MQQBrowser\/([\d.]+)/);return e&&e[1]?e[1]:null}(),IS_WQQB=!IS_TBS&&/ QQBrowser\/\d+/i.test(USER_AGENT),WQQB_VERSION=IS_WQQB&&function(){const e=USER_AGENT.match(/ QQBrowser\/([\d.]+)/);return e&&e[1]?e[1]:null}(),IS_MACQQB=!IS_TBS&&/QQBrowserLite\/\d+/i.test(USER_AGENT),MACQQB_VERSION=IS_MACQQB&&function(){const e=USER_AGENT.match(/QQBrowserLite\/([\d.]+)/);return e&&e[1]?e[1]:null}(),IS_IPADQQB=!IS_TBS&&/MQBHD\/\d+/i.test(USER_AGENT),IPADQQB_VERSION=IS_IPADQQB&&function(){const e=USER_AGENT.match(/MQBHD\/([\d.]+)/);return e&&e[1]?e[1]:null}(),IS_WIN=/Windows/i.test(USER_AGENT),IS_MAC=!IS_IOS&&/MAC OS X/i.test(USER_AGENT),IS_LINUX=!IS_ANDROID&&/Linux/i.test(USER_AGENT),IS_WX=/MicroMessenger/i.test(USER_AGENT),IS_UCBROWSER=/UCBrowser/i.test(USER_AGENT),IS_ELECTRON=/Electron/i.test(USER_AGENT),IS_MIBROWSER=/MiuiBrowser/i.test(USER_AGENT),MI_VERSION=IS_MIBROWSER&&function(){const e=USER_AGENT.match(/MiuiBrowser\/([\d.]+)/);return e&&e[1]?e[1]:null}(),IS_HUAWEIBROWSER=/HuaweiBrowser/i.test(USER_AGENT),HUAWEI_VERSION=IS_HUAWEIBROWSER&&function(){const e=USER_AGENT.match(/HuaweiBrowser\/([\d.]+)/);return e&&e[1]?e[1]:null}(),IS_SAMSUNGBROWSER=/SamsungBrowser/i.test(USER_AGENT),SAMSUNG_VERSION=IS_SAMSUNGBROWSER&&function(){const e=USER_AGENT.match(/SamsungBrowser\/([\d.]+)/);return e&&e[1]?e[1]:null}(),IS_OPPOBROWSER=/HeyTapBrowser/i.test(USER_AGENT),OPPO_VERSION=IS_OPPOBROWSER&&function(){const e=USER_AGENT.match(/HeyTapBrowser\/([\d.]+)/);return e&&e[1]?e[1]:null}(),IS_VIVOBROWSER=/VivoBrowser/i.test(USER_AGENT),VIVO_VERSION=IS_VIVOBROWSER&&function(){const e=USER_AGENT.match(/VivoBrowser\/([\d.]+)/);return e&&e[1]?e[1]:null}(),IS_CHROME_ONLY=/Chrome/i.test(USER_AGENT),IS_CHROME=!IS_EDGE&&!IS_SOGOU&&!IS_SOGOUM&&!IS_TBS&&!IS_XWEB&&!IS_EDG&&!IS_WQQB&&!IS_MIBROWSER&&!IS_HUAWEIBROWSER&&!IS_SAMSUNGBROWSER&&!IS_OPPOBROWSER&&!IS_VIVOBROWSER&&/Chrome/i.test(USER_AGENT),CHROME_MAJOR_VERSION=IS_CHROME&&function(){const e=USER_AGENT.match(/Chrome\/(\d+)/);return e&&e[1]?parseFloat(e[1]):null}(),CHROME_VERSION=IS_CHROME&&function(){const e=USER_AGENT.match(/Chrome\/([\d.]+)/);return e&&e[1]?e[1]:null}(),IS_SAFARI=!IS_CHROME_ONLY&&!IS_MQQB&&!IS_X5MQQB&&!IS_MACQQB&&!IS_IPADQQB&&/Safari/i.test(USER_AGENT),SAFARI_VERSION=IS_SAFARI&&function(){const e=USER_AGENT.match(/Version\/([\d.]+)/);return e&&e[1]?e[1]:null}(),BROWSER_VERSION=IS_CHROME?`Chrome/${CHROME_VERSION}`:IS_SAFARI?`Safari/${SAFARI_VERSION}`:"NotSupportedBrowser",IS_LOCAL="file:"===location.protocol||"localhost"===location.hostname||/^\d+\.\d+\.\d+\.\d+$/.test(location.hostname),OSNameMap=new Map([[IS_ANDROID,"Android"],[IS_IOS,"iOS"],[IS_WIN,"Windows"],[IS_MAC,"MacOS"],[IS_LINUX,"Linux"]]),getOSType=()=>{let e="unknown";return OSNameMap.get(!0)&&(e=OSNameMap.get(!0)),e},browserInfoMap=new Map([[IS_FIREFOX,["Firefox",FIREFOX_VERSION]],[IS_EDG,["Edg",EDG_VERSION]],[IS_CHROME,["Chrome",CHROME_VERSION]],[IS_SAFARI,["Safari",SAFARI_VERSION]],[IS_TBS,["TBS",TBS_VERSION]],[IS_XWEB,["XWEB",XWEB_VERSION]],[IS_WECHAT&&IS_IPHONE,["WeChat",WECHAT_VERSION]],[IS_WQQB,["QQ(Win)",WQQB_VERSION]],[IS_MQQB,["QQ(Mobile)",MQQB_VERSION]],[IS_X5MQQB,["QQ(Mobile X5)",MQQB_VERSION]],[IS_MACQQB,["QQ(Mac)",MACQQB_VERSION]],[IS_IPADQQB,["QQ(iPad)",IPADQQB_VERSION]],[IS_MIBROWSER,["MI",MI_VERSION]],[IS_HUAWEIBROWSER,["HW",HUAWEI_VERSION]],[IS_SAMSUNGBROWSER,["Samsung",SAMSUNG_VERSION]],[IS_OPPOBROWSER,["OPPO",OPPO_VERSION]],[IS_VIVOBROWSER,["VIVO",VIVO_VERSION]],[IS_EDGE,["EDGE",EDGE_VERSION]],[IS_SOGOUM,["SogouMobile",SOGOUM_VERSION]],[IS_SOGOU,["Sogou",SOGOU_VERSION]]]),getBrowserInfo=()=>{let e="unknown",t="unknown";return browserInfoMap.get(!0)&&([e,t]=browserInfoMap.get(!0)),{name:e,version:t}},UA=navigator.userAgent,getDisplayResolution=()=>{let e;if(screen.width){e={width:screen.width?screen.width*window.devicePixelRatio:"",height:screen.height?screen.height*window.devicePixelRatio:""}}return e},getHardwareConcurrency=()=>{var e;return null==(e=window.navigator)?void 0:e.hardwareConcurrency},getBrowserLanguage=navigator.language||navigator.userLanguage||navigator.browserLanguage||navigator.systemLanguage||"en",isScreenCaptureAPISupported=()=>{var e;return!!(null==(e=navigator.mediaDevices)?void 0:e.getDisplayMedia)},isWebAudioSupported=()=>{const e={isSupported:!1},t=["AudioContext","webkitAudioContext","mozAudioContext","msAudioContext"];for(let V=0;V<t.length;V++)if(t[V]in window){e.isSupported=!0;break}return e.isSupported},isWebSocketSupported=()=>"WebSocket"in window&&2===window.WebSocket.CLOSING,isBrowserSupported=()=>!IS_UCBROWSER&&!IS_EDGE&&(!(IS_EDG&&"number"==typeof EDG_VERSION&&EDG_VERSION<80)&&!(IS_FIREFOX&&FIREFOX_VERSION&&FIREFOX_VERSION<56)),isWebRTCSupported=()=>["RTCPeerConnection","webkitRTCPeerConnection","RTCIceGatherer"].filter((e=>e in window)).length>0,isCanvasCapturingSupported=()=>{let e=!1;return["captureStream","mozCaptureStream","webkitCaptureStream"].forEach((t=>{"undefined"!=typeof document&&"function"==typeof document.createElement&&!e&&t in document.createElement("canvas")&&(e=!0)})),e},isVideoCapturingSupported=()=>{let e=!1;return["captureStream","mozCaptureStream","webkitCaptureStream"].forEach((t=>{"undefined"!=typeof document&&"function"==typeof document.createElement&&!e&&t in document.createElement("video")&&(e=!0)})),e},isRTPSenderReplaceTracksSupported=()=>{let e=!1;return IS_FIREFOX&&void 0!==window.mozRTCPeerConnection?"getSenders"in window.mozRTCPeerConnection.prototype&&(e=!0):IS_CHROME&&void 0!==window.webkitRTCPeerConnection&&"getSenders"in window.webkitRTCPeerConnection.prototype&&(e=!0),e},isApplyConstraintsSupported=()=>"undefined"!=typeof MediaStreamTrack&&"applyConstraints"in MediaStreamTrack.prototype,{toString:toString}=Object.prototype,isUndefined=e=>void 0===e,getCore=()=>core,getLog=()=>log,setCore=e=>{core=e},setLog=e=>{log=e},clear=()=>{core=null,log=null},isMediaDevicesUndefined=function(){const e=getLog();return!!isUndefined(navigator.mediaDevices)&&(e&&e.error("navigator.mediaDevices is not supported on your browser"),!0)},isUsedInHttpProtocol=function(){const e=getLog();return"http:"===location.protocol&&!IS_LOCAL&&(e&&e.error("you should use https"),!0)},isUserMediaSupported=()=>{if(!navigator.mediaDevices)return!1;const e=["getUserMedia","enumerateDevices"];return e.filter((e=>e in navigator.mediaDevices)).length===e.length},getDevices=async e=>{if(isUsedInHttpProtocol()||isMediaDevicesUndefined())return[];let t=!1,V=!1,i=!1,n=!1,A=!1;const o=[],r=[],s=[],q={};let a;e&&(a=await navigator.mediaDevices.getUserMedia(e));return(await navigator.mediaDevices.enumerateDevices()).forEach((e=>{const c={};for(const t in e)try{"function"!=typeof e[t]&&(c[t]=e[t])}catch(e){}const l=c.deviceId||"",d=c.label||"",p=c.kind||"";q[l+d+p]||("audio"===c.kind&&(c.kind="audioinput"),"video"===c.kind&&(c.kind="videoinput"),c.deviceId||(c.deviceId=c.id),c.label?("videoinput"!==c.kind||n||(n=!0),"audioinput"!==c.kind||A||(A=!0)):"videoinput"===c.kind?c.label=`Camera ${s.length+1}`:"audioinput"===c.kind?c.label=`Microphone ${o.length+1}`:"audiooutput"===c.kind?c.label=`Speaker ${r.length+1}`:c.label="Please invoke getUserMedia once.","audioinput"===c.kind&&(t=!0,-1===o.indexOf(c)&&o.push(c)),"audiooutput"===c.kind&&(V=!0,-1===r.indexOf(c)&&r.push(c)),"videoinput"===c.kind&&(i=!0,-1===s.indexOf(c)&&s.push(c)),q[c.deviceId+c.label+c.kind]=c,null==a||a.getTracks().forEach((e=>e.stop())))})),{hasWebCamPermission:n,hasMicrophonePermission:A,cameras:s,speakers:r,microphones:o}};async function UIGetCameras(e){return{cameraList:(await getDevices({video:!0,audio:!1})).cameras}}var UIGetMicrophones=async e=>({microphoneList:(await getDevices({video:!1,audio:!0})).microphones});async function UIGetSpeakers(){return(await getDevices({video:!1,audio:!0})).speakers}var encodeSupportStatus=async()=>{let e={sdp:"",type:"offer"},t=!1,V=!1;try{const i=new RTCPeerConnection,n=document.createElement("canvas");n.getContext("2d");const A=n.captureStream(0);return i.addTrack(A.getVideoTracks()[0],A),e=await i.createOffer(),e&&e.sdp&&(-1!==e.sdp.toLowerCase().indexOf("h264")&&(t=!0),-1!==e.sdp.toLowerCase().indexOf("vp8")&&(V=!0)),i.close(),{isH264EncodeSupported:t,isVp8EncodeSupported:V}}catch(e){return{isH264EncodeSupported:!1,isVp8EncodeSupported:!1}}},decodeSupportStatus=async()=>{let e={sdp:"",type:"offer"},t=!1,V=!1;try{const i=new RTCPeerConnection;return e=await i.createOffer({offerToReceiveAudio:!0,offerToReceiveVideo:!0}),e&&e.sdp&&(-1!==e.sdp.toLowerCase().indexOf("h264")&&(t=!0),-1!==e.sdp.toLowerCase().indexOf("vp8")&&(V=!0)),i.close(),{isH264DecodeSupported:t,isVp8DecodeSupported:V}}catch(e){return{isH264DecodeSupported:!1,isVp8DecodeSupported:!1}}};async function isHWEnabled(){return new Promise((async(e,t)=>{try{let V=function(){clearInterval(d),clearInterval(A),clearTimeout(p),r.close(),s.close(),o.getTracks().forEach((e=>e.stop()))};const i=document.createElement("canvas"),n=i.getContext("2d");i.width=640,i.height=480;const A=setInterval((()=>{n&&n.fillText("test",0,0)}),33),o=i.captureStream(15),r=new RTCPeerConnection({}),s=new RTCPeerConnection({});r.addEventListener("icecandidate",(e=>{s.addIceCandidate(e.candidate)})),s.addEventListener("icecandidate",(e=>{r.addIceCandidate(e.candidate)}));const q=RTCRtpSender.getCapabilities("video"),a=(q?q.codecs:[]).find((e=>"video/H264"===e.mimeType));r.addTransceiver(o.getVideoTracks()[0],{direction:"sendonly",streams:[o],sendEncodings:[{maxBitrate:5e5}]}),s.addTransceiver("video",{direction:"recvonly"}),a&&r.getTransceivers()[0].setCodecPreferences([a].filter((e=>void 0!==e)));const c=await r.createOffer();await r.setLocalDescription(c),await s.setRemoteDescription(c);const l=await s.createAnswer();await s.setLocalDescription(l),await r.setRemoteDescription(l);let d=-1,p=-1;p=setTimeout((()=>{V(),e(!1)}),3e4),d=setInterval((async()=>{(await r.getStats()).forEach((i=>{"outbound-rtp"===i.type&&"video"===i.mediaType&&(void 0===i.encoderImplementation&&(V(),t(new Error("your browser does not support to detect HW acceleration enabled."))),"ExternalEncoder"===i.encoderImplementation&&(V(),e(!0)))}))}),500)}catch(e){t(e)}}))}var RTCDetect={system:null,APISupported:null,devices:null,codecsSupported:null,report:null,networkInfo:null,TRTCInitDone:!1,mirror:!1,async getReportAsync(){return this.getSystem(),this.getAPISupported(),await this.getCodecAsync(),await this.getDevicesAsync(),this.report={system:this.system,APISupported:this.APISupported,codecsSupported:this.codecsSupported,devices:this.devices},this.report},async isTRTCSupported(){await this.getReportAsync();const{isWebRTCSupported:e,isUserMediaSupported:t,isWebSocketSupported:V}=this.APISupported;if(!e)return{result:!1,reason:"you browser does not support WebRTC."};if(!V)return{result:!1,reason:"you browser does not support WebSocket."};if(!t)return{result:!1,reason:"you browser does not support getUserMedia."};const{isH264EncodeSupported:i,isVp8EncodeSupported:n,isH264DecodeSupported:A,isVp8DecodeSupported:o}=this.codecsSupported;return i||n?A||o?isBrowserSupported()?{result:!0}:{result:!1,reason:"your browser does not qualify, it is recommended to use Chrome and firefox."}:{result:!1,reason:`isH264DecodeSupported: ${A} isVp8DecodeSupported: ${o} `}:{result:!1,reason:`isH264EncodeSupported: ${i} isVp8EncodeSupported: ${n} `}},async getCodecAsync(){const{isH264EncodeSupported:e,isVp8EncodeSupported:t}=await encodeSupportStatus(),{isH264DecodeSupported:V,isVp8DecodeSupported:i}=await decodeSupportStatus();return this.codecsSupported={isH264EncodeSupported:e,isVp8EncodeSupported:t,isH264DecodeSupported:V,isVp8DecodeSupported:i},this.codecsSupported},async getDevicesAsync(){const{hasWebCamPermission:e,hasMicrophonePermission:t,cameras:V,microphones:i,speakers:n}=await getDevices();return this.devices={cameras:V,microphones:i,speakers:n||[],hasWebCamPermission:e,hasMicrophonePermission:t},this.devices},getSystem(){return this.system={UA:UA,OS:getOSType(),browser:getBrowserInfo(),displayResolution:getDisplayResolution(),hardwareConcurrency:getHardwareConcurrency(),language:getBrowserLanguage},this.system},getAPISupported(){return this.APISupported={isUserMediaSupported:isUserMediaSupported(),isWebRTCSupported:isWebRTCSupported(),isWebSocketSupported:isWebSocketSupported(),isWebAudioSupported:isWebAudioSupported(),isScreenCaptureAPISupported:isScreenCaptureAPISupported(),isCanvasCapturingSupported:isCanvasCapturingSupported(),isVideoCapturingSupported:isVideoCapturingSupported(),isRTPSenderReplaceTracksSupported:isRTPSenderReplaceTracksSupported(),isApplyConstraintsSupported:isApplyConstraintsSupported()},this.APISupported},isHardWareAccelerationEnabled:async()=>await isHWEnabled()},sdk_default=RTCDetect;function isOnline(){const e=`https://web.sdk.qcloud.com/trtc/electron/download/resources/media/TestSpeaker.mp3?t=${(new Date).getTime()}`;return Promise.race([fetch(e,{mode:"cors"}),new Promise(((e,t)=>setTimeout((()=>t(!1)),3e3)))]).then((e=>{if(!e.ok)throw new Error("网络错误");return!0})).catch((()=>!1))}var NETWORK_QUALITY={0:"未知",1:"极佳",2:"较好",3:"一般",4:"差",5:"极差",6:"断开"},NETWORK_QUALITY_ENGLISH={0:"Unknown",1:"Excellent",2:"Good",3:"Average",4:"Poor",5:"Very Poor",6:"Disconnected"},handleGetUserMediaError=e=>{const t=(navigator.language||navigator.userLanguage||navigator.browserLanguage||navigator.systemLanguage||"en").indexOf("zh")>-1,V=getLog();switch(V.error("getUserMedia error",e),e.name){case"NotReadableError":return void(t?V.error("暂时无法访问摄像头/麦克风,请确保系统授予当前浏览器摄像头/麦克风权限,并且没有其他应用占用摄像头/麦克风"):V.error("Cannot access camera/microphone temporarily. Please make sure the system has granted the current browser permission to access the camera/microphone and no other application is using the camera/microphone"));case"NotAllowedError":return void(t?V.error("用户/系统已拒绝授权访问摄像头或麦克风"):V.error("User/system has denied access to camera/microphone"));case"NotFoundError":return void(t?V.error("找不到摄像头或麦克风设备"):V.error("Cannot find camera or microphone device"));case"OverConstrainedError":return void(t?V.error("采集属性设置错误,如果您指定了 cameraId/microphoneId,请确保它们是一个有效的非空字符串"):V.error("Capture attribute setting error. If you specified cameraId/microphoneId, please make sure they are valid non-empty strings"));default:return void(t?V.error("初始化本地流时遇到未知错误, 请重试"):V.error("Unknown error encountered when initializing local stream, please try again"))}},_deviceConnect=class e extends i4{constructor(){super(),this.progress=0,this.remindAnimation=!1;const t=navigator.language||navigator.userLanguage||navigator.browserLanguage||navigator.systemLanguage||"en";this.isChinese=t.indexOf("zh")>-1,this.showConnectResult=!1,this.connectResult={info:this.isChinese?"连接出错,请重试":"Connection error, please try again",success:!1,remind:this.isMobile?this.isChinese?e.mobileFailAttention:e.mobileFailAttentionEng:this.isChinese?e.deviceFailAttention:e.deviceFailAttentionEng},this.envresult=sdk_default.getSystem(),this.isMobile="iOS"===this.envresult.OS||"Android"===this.envresult.OS,this.isFirefoxOrSafariOrIOS="Firefox"===this.envresult.browser.name||"iOS"===this.envresult.OS||"Safari"===this.envresult.browser.name,this.deviceState={},this.showRemind=!1,this.startTime=(new Date).getTime(),this.attachShadow({mode:"open"})}render(){return x`
2
2
  <style>${style1_default}</style>
3
3
  <div class="device-connect">
4
4
  <div class="testing-title">${this.isChinese?"设备连接":"Device Connection"}</div>
@@ -55,14 +55,14 @@ var __create=Object.create,__defProp=Object.defineProperty,__defProps=Object.def
55
55
  <div class="button-container">
56
56
  <trtc-custom-button type='disabled' >${this.isChinese?"开始检测":"Start detection"}</trtc-custom-button>
57
57
  </div>
58
- `}setShowRemind(e){this.showRemind=e,this.requestUpdate()}firstUpdated(){this.getDeviceConnectResult(),this.stepNameList=JSON.parse(this.getAttribute("stepnamelist")),this.judgeList(this.stepNameList);this.shadowRoot.querySelector(".testing-prepare-info").innerHTML=this.prepareInfo()}updated(){this.showRemind&&(this.shadowRoot.querySelector(".connect-attention-info").innerHTML=this.connectResult.remind)}hasCameraDetect(){return this.stepNameList.indexOf("camera")>=0}hasMicrophoneDetect(){return this.stepNameList.indexOf("microphone")>=0}hasSpeakerDetect(){return this.stepNameList.indexOf("speaker")>=0}hasNetworkDetect(){return this.stepNameList.indexOf("network")>=0}showReconnectButton(){const{deviceState:e}=this;return this.showConnectResult&&!(e.hasCameraConnect&&e.hasMicrophoneConnect&&e.hasSpeakerConnect&&e.hasNetworkConnect)}showStartDetectButton(){const{deviceState:e}=this;return this.showConnectResult&&e.hasCameraConnect&&e.hasMicrophoneConnect&&e.hasSpeakerConnect&&e.hasNetworkConnect}handler(t){const V=this.shadowRoot.querySelector(".inner-progress");t||(this.progressInterval&&clearInterval(this.progressInterval),this.progressInterval=setInterval((()=>{if(this.progress+=10,V.style.transform=`translateX(${this.progress}%)`,100===this.progress){this.progress=0,V.style.transform="translateX(0%)";const t=new CustomEvent("remind-changed",{detail:this.remindAnimation});this.dispatchEvent(t),setTimeout((()=>{this.remindAnimation&&this.isMobile&&(this.isChinese?alert(e.mobileFailAttention.replace(/<br>/g,"\n")):alert(e.mobileFailAttentionEng.replace(/<br>/g,"\n")))}),200),this.showConnectResult=!0,this.setAttribute("showconnectresult",this.showConnectResult),clearInterval(this.progressInterval)}}),150))}prepareInfo(){return this.isChinese?`设备检测前请确认设备连接了${this.hasCameraDetect()?"摄像头":""}${this.hasMicrophoneDetect()?"、麦克风":""}${this.hasSpeakerDetect()?"、扬声器":""}${this.hasNetworkDetect()?"和网络":""}`:`Make sure the device is connected before testing the device ${this.hasCameraDetect()?"camera":""}${this.hasMicrophoneDetect()?", microphone":""}${this.hasSpeakerDetect()?", speaker":""}${this.hasNetworkDetect()?" and network":""}`}judgeList(e){const t=this.shadowRoot.querySelector(".camerasvg"),V=this.shadowRoot.querySelector(".microphonesvg"),i=this.shadowRoot.querySelector(".speakersvg"),n=this.shadowRoot.querySelector(".networksvg");e.indexOf("camera")>=0?t.style.display="block":t.style.display="none",e.indexOf("microphone")>=0?V.style.display="block":V.style.display="none",e.indexOf("speaker")>=0?i.style.display="block":i.style.display="none",e.indexOf("network")>=0?n.style.display="block":n.style.display="none"}async getDeviceConnectResult(){let e=[],t=[],V=[];try{const{cameras:i,speakers:n,microphones:A}=await getDevices();e=i,t=A,V=n}catch(e){}const i=e.length>0,n=t.length>0,A=!this.hasSpeakerDetect()||(this.isFirefoxOrSafariOrIOS||V.length>0),o=!this.hasNetworkDetect()||await isOnline();let r={hasCameraDevice:i,hasMicrophoneDevice:n,hasSpeakerDevice:A,hasNetworkConnect:o,hasCameraConnect:!1,hasMicrophoneConnect:!1,hasSpeakerConnect:A};this.deviceState=r,this.remindAnimation=!1,this.connectResult=this.getDeviceConnectInfo(r);const s=[];i&&s.push(new Promise(((e,t)=>{navigator.mediaDevices.getUserMedia({video:!0,audio:!1}).then((t=>{this.remindAnimation=!1,r=__spreadProps(__spreadValues({},r),{hasCameraConnect:!0}),this.deviceState=r,this.connectResult=this.getDeviceConnectInfo(r),t.getTracks()[0].stop(),e()})).catch((t=>{handleGetUserMediaError(t),e()}))}))),n&&s.push(new Promise(((e,t)=>{navigator.mediaDevices.getUserMedia({video:!1,audio:!0}).then((t=>{this.remindAnimation=!1,r=__spreadProps(__spreadValues({},r),{hasMicrophoneConnect:n}),this.deviceState=r,this.connectResult=this.getDeviceConnectInfo(r),t.getTracks()[0].stop(),e()})).catch((t=>{handleGetUserMediaError(t),e()}))}))),await Promise.all(s),this.handler(this.showConnectResult)}getDeviceConnectInfo(t){this.remindAnimation=!1;let V="连接出错,请重试";return this.isChinese||(V="Connection error, please try again"),t.hasCameraConnect&&t.hasMicrophoneConnect&&t.hasSpeakerConnect&&t.hasNetworkConnect?(V=this.isChinese?this.hasNetworkDetect?"设备及网络连接成功,请开始设备检测":"设备连接成功,请开始设备检测":this.hasNetworkDetect?"Device and network connection are successful, start device detection":"Device connection successful, start device detection",{info:V,success:!0}):t.hasCameraDevice&&t.hasMicrophoneDevice&&t.hasSpeakerDevice?t.hasCameraConnect&&t.hasMicrophoneConnect?t.hasNetworkConnect?{info:V,success:!1}:(V=this.isChinese?"网络连接失败,请检查网络连接":"Network connection failed, please check network connection",{info:V,success:!1,remind:this.isChinese?e.networkFailAttention:e.networkFailAttentionEng}):(V=this.isChinese?t.hasNetworkConnect?"请允许浏览器及网页访问摄像头/麦克风设备":"请允许浏览器及网页访问摄像头/麦克风设备,并检查网络连接":t.hasNetworkConnect?"Please allow browser and web access to camera/microphone devices":"Please allow browser and web access to camera/microphone devices, and check the network connection",this.remindAnimation=!0,{info:V,success:!1,remind:this.isMobile?this.isChinese?e.mobileFailAttention:e.mobileFailAttentionEng:this.isChinese?e.deviceFailAttention:e.deviceFailAttentionEng}):(V=this.isChinese?`检测到${t.hasCameraDevice?"":"【摄像头】"}${t.hasMicrophoneDevice?"":"【麦克风】"}${t.hasSpeakerDevice?"":"【扬声器】"}设备不存在,请检查设备连接`:`No ${t.hasCameraDevice?"":"【camera】"}${t.hasMicrophoneDevice?"":"【microphone】"}${t.hasSpeakerDevice?"":"【speaker】"} device detected, please check the device connection`,{info:V,success:!1})}handleReset(){this.progress=0,this.showConnectResult=!1,this.setAttribute("showconnectresult",this.showConnectResult)}async attributeChangedCallback(e,t,V){if("showconnectresult"===e)if("true"===V){const e=this.shadowRoot.querySelector(".camerasvg"),t=this.shadowRoot.querySelector(".microphonesvg"),V=this.shadowRoot.querySelector(".speakersvg"),i=this.shadowRoot.querySelector(".networksvg"),n=this.shadowRoot.querySelector(".outer-progress"),A=this.shadowRoot.querySelector("trtc-custom-button");if(this.deviceState.hasCameraConnect?(e.classList.remove("connect-fail"),e.classList.add("connect-success")):e.classList.add("connect-fail"),this.deviceState.hasMicrophoneConnect?(t.classList.remove("connect-fail"),t.classList.add("connect-success")):t.classList.add("connect-fail"),this.deviceState.hasSpeakerConnect?(V.classList.add("connect-success"),V.classList.remove("connect-fail")):V.classList.add("connect-fail"),this.deviceState.hasNetworkConnect?(i.classList.add("connect-success"),i.classList.remove("connect-fail")):i.classList.add("connect-fail"),this.showReconnectButton()&&(A.setAttribute("type","outlined"),this.isChinese?A.innerHTML="重新连接":A.innerHTML="Reconnect",A.addEventListener("click",(()=>{this.remindAnimation=!1;const e=new CustomEvent("remind-changed",{detail:this.remindAnimation});this.dispatchEvent(e);const t=(new Date).getTime(),V=getCore();V&&V.kvStatManager.addFailedEvent({key:591704,error:t-this.startTime}),this.handleReset()}))),this.showStartDetectButton()&&(A.setAttribute("type","contained"),this.setAttribute("connectstage",1),this.isChinese?A.innerHTML="开始检测":A.innerHTML="Start detection"),this.showConnectResult){n.style.display="none",this.shadowRoot.querySelector(".gray-text").style.display="none";const e=this.shadowRoot.querySelector(".result");e.style.display="block",!0===this.connectResult.success?e.classList.add("green-text"):(e.classList.add("red-text"),this.connectResult.remind&&(this.shadowRoot.querySelector(".error-connect").style.display="inline-block")),e.querySelector("span").innerHTML=this.connectResult.info}}else if("false"===V){const e=this.shadowRoot.querySelector(".camerasvg"),t=this.shadowRoot.querySelector(".microphonesvg"),V=this.shadowRoot.querySelector(".speakersvg"),i=this.shadowRoot.querySelector(".networksvg"),n=this.shadowRoot.querySelector(".outer-progress"),A=this.shadowRoot.querySelector("trtc-custom-button");n.style.display="block",this.shadowRoot.querySelector(".result").classList.remove("green-text"),this.shadowRoot.querySelector(".result").classList.remove("red-text"),e.classList.remove("connect-fail"),e.classList.remove("connect-success"),t.classList.remove("connect-fail"),t.classList.remove("connect-success"),V.classList.remove("connect-fail"),V.classList.remove("connect-success"),i.classList.remove("connect-fail"),i.classList.remove("connect-success"),A.setAttribute("type","disabled"),this.isChinese?A.innerHTML="开始检测":A.innerHTML="Start detection",this.getDeviceConnectResult(),this.shadowRoot.querySelector(".gray-text").style.display="block";this.shadowRoot.querySelector(".result").style.display="none",this.shadowRoot.querySelector(".error-connect").style.display="none"}}};__publicField(_deviceConnect,"observedAttributes",["stepnamelist","showconnectresult"]),__publicField(_deviceConnect,"properties",{showRemind:{type:Boolean},constTime:{type:Number}}),__publicField(_deviceConnect,"deviceFailAttention","1. 若浏览器弹出提示,请选择“允许”<br>2. 若杀毒软件弹出提示,请选择“允许”<br>3. 检查系统设置,允许浏览器访问摄像头及麦克风<br>4. 检查浏览器设置,允许网页访问摄像头及麦克风<br>5. 检查摄像头/麦克风是否正确连接并开启<br>6. 尝试重新连接摄像头/麦克风<br>7. 尝试重启设备后重新检测"),__publicField(_deviceConnect,"deviceFailAttentionEng",'1. If the browser prompts, select "Allow"<br>2. If the antivirus software prompts, select "Allow"<br>3. Check system settings to allow camera and microphone<br>4. Check browser settings to allow camera and microphone<br>5. Check camera/microphone turned on<br>6. Try reconnecting the camera/microphone<br>7. Try restarting the device and retesting'),__publicField(_deviceConnect,"mobileFailAttention","1. 前往手机设置,打开本应用的相机和麦克风权限<br>2. 重新刷新本页并允许相机和麦克风权限<br>"),__publicField(_deviceConnect,"mobileFailAttentionEng","1. Go to your phone Settings to allow camera and microphone permissions for this app <br>2. Refresh this page and allow camera and microphone permissions <br>"),__publicField(_deviceConnect,"networkFailAttention","1. 请检查设备是否联网<br>2. 请刷新网页后再次检测<br>3. 请尝试更换网络后再次检测"),__publicField(_deviceConnect,"networkFailAttentionEng","1. Check if the device is connected to the network<br>2. Refresh the page and test again<br>3. Try again after changing the network");var deviceConnect=_deviceConnect;customElements.get("trtc-device-connect")||customElements.define("trtc-device-connect",deviceConnect);var DeviceSelect=class extends r4{constructor(){super(),this.deviceList=[],this.activeDevice={},this.activeDeviceId="",this.attachShadow({mode:"open"})}async getDeviceListData(){var e;const t=await getDeviceList(this.deviceType),V=t.map((e=>e.deviceId));this.deviceList=t,this.choseDevice&&V.indexOf(this.choseDevice.deviceId)>=0?(this.activeDevice=t.find((e=>e.deviceId===this.choseDevice.deviceId)),this.activeDeviceId=this.choseDevice.deviceId):(this.activeDevice=t[0],this.activeDeviceId=null==(e=t[0])?void 0:e.deviceId),this.onChange(this.activeDevice),this.requestUpdate()}async firstUpdated(){await this.getDeviceListData(),navigator.mediaDevices.addEventListener("devicechange",(async()=>{const e=await getDeviceList(this.deviceType);this.deviceList=e,e[0].deviceId!==this.activeDeviceId&&(this.activeDevice=e[0],this.activeDeviceId=e[0].deviceId,this.onChange(this.activeDevice)),this.requestUpdate()}))}disconnectedCallback(){this.remove()}handleChange(e){const t=e.target.value,V=getCore();V&&V.kvStatManager.addEnum({key:591713,value:1});const i=this.deviceList.find((e=>e.deviceId===t));this.activeDevice=i,this.activeDeviceId=t,this.onChange(this.activeDevice),this.requestUpdate()}render(){return x`
58
+ `}setShowRemind(e){this.showRemind=e,this.requestUpdate()}firstUpdated(){this.getDeviceConnectResult(),this.stepNameList=JSON.parse(this.getAttribute("stepnamelist")),this.judgeList(this.stepNameList);this.shadowRoot.querySelector(".testing-prepare-info").innerHTML=this.prepareInfo()}updated(){this.showRemind&&(this.shadowRoot.querySelector(".connect-attention-info").innerHTML=this.connectResult.remind)}hasCameraDetect(){return this.stepNameList.indexOf("camera")>=0}hasMicrophoneDetect(){return this.stepNameList.indexOf("microphone")>=0}hasSpeakerDetect(){return this.stepNameList.indexOf("speaker")>=0}hasNetworkDetect(){return this.stepNameList.indexOf("network")>=0}showReconnectButton(){const{deviceState:e}=this;return this.showConnectResult&&!(e.hasCameraConnect&&e.hasMicrophoneConnect&&e.hasSpeakerConnect&&e.hasNetworkConnect)}showStartDetectButton(){const{deviceState:e}=this;return this.showConnectResult&&e.hasCameraConnect&&e.hasMicrophoneConnect&&e.hasSpeakerConnect&&e.hasNetworkConnect}handler(t){const V=this.shadowRoot.querySelector(".inner-progress");t||(this.progressInterval&&clearInterval(this.progressInterval),this.progressInterval=setInterval((()=>{if(this.progress+=10,V.style.transform=`translateX(${this.progress}%)`,100===this.progress){this.progress=0,V.style.transform="translateX(0%)";const t=new CustomEvent("remind-changed",{detail:this.remindAnimation});this.dispatchEvent(t),setTimeout((()=>{this.remindAnimation&&this.isMobile&&(this.isChinese?alert(e.mobileFailAttention.replace(/<br>/g,"\n")):alert(e.mobileFailAttentionEng.replace(/<br>/g,"\n")))}),200),this.showConnectResult=!0,this.setAttribute("showconnectresult",this.showConnectResult),clearInterval(this.progressInterval)}}),150))}prepareInfo(){return this.isChinese?`设备检测前请确认设备连接了${this.hasCameraDetect()?"摄像头":""}${this.hasMicrophoneDetect()?"、麦克风":""}${this.hasSpeakerDetect()?"、扬声器":""}${this.hasNetworkDetect()?"和网络":""}`:`Make sure the device is connected before testing the device ${this.hasCameraDetect()?"camera":""}${this.hasMicrophoneDetect()?", microphone":""}${this.hasSpeakerDetect()?", speaker":""}${this.hasNetworkDetect()?" and network":""}`}judgeList(e){const t=this.shadowRoot.querySelector(".camerasvg"),V=this.shadowRoot.querySelector(".microphonesvg"),i=this.shadowRoot.querySelector(".speakersvg"),n=this.shadowRoot.querySelector(".networksvg");e.indexOf("camera")>=0?t.style.display="block":t.style.display="none",e.indexOf("microphone")>=0?V.style.display="block":V.style.display="none",e.indexOf("speaker")>=0?i.style.display="block":i.style.display="none",e.indexOf("network")>=0?n.style.display="block":n.style.display="none"}async getDeviceConnectResult(){let e=[],t=[],V=[];try{const{cameras:i,speakers:n,microphones:A}=await getDevices();e=i,t=A,V=n}catch(e){}const i=e.length>0,n=t.length>0,A=!this.hasSpeakerDetect()||(this.isFirefoxOrSafariOrIOS||V.length>0),o=!this.hasNetworkDetect()||await isOnline();let r={hasCameraDevice:i,hasMicrophoneDevice:n,hasSpeakerDevice:A,hasNetworkConnect:o,hasCameraConnect:!1,hasMicrophoneConnect:!1,hasSpeakerConnect:A};this.deviceState=r,this.remindAnimation=!1,this.connectResult=this.getDeviceConnectInfo(r);const s=[];i&&s.push(new Promise(((e,t)=>{navigator.mediaDevices.getUserMedia({video:!0,audio:!1}).then((t=>{this.remindAnimation=!1,r=__spreadProps(__spreadValues({},r),{hasCameraConnect:!0}),this.deviceState=r,this.connectResult=this.getDeviceConnectInfo(r),t.getTracks()[0].stop(),e()})).catch((t=>{handleGetUserMediaError(t),e()}))}))),n&&s.push(new Promise(((e,t)=>{navigator.mediaDevices.getUserMedia({video:!1,audio:!0}).then((t=>{this.remindAnimation=!1,r=__spreadProps(__spreadValues({},r),{hasMicrophoneConnect:n}),this.deviceState=r,this.connectResult=this.getDeviceConnectInfo(r),t.getTracks()[0].stop(),e()})).catch((t=>{handleGetUserMediaError(t),e()}))}))),await Promise.all(s),this.handler(this.showConnectResult)}getDeviceConnectInfo(t){this.remindAnimation=!1;let V="连接出错,请重试";return this.isChinese||(V="Connection error, please try again"),t.hasCameraConnect&&t.hasMicrophoneConnect&&t.hasSpeakerConnect&&t.hasNetworkConnect?(V=this.isChinese?this.hasNetworkDetect?"设备及网络连接成功,请开始设备检测":"设备连接成功,请开始设备检测":this.hasNetworkDetect?"Device and network connection are successful, start device detection":"Device connection successful, start device detection",{info:V,success:!0}):t.hasCameraDevice&&t.hasMicrophoneDevice&&t.hasSpeakerDevice?t.hasCameraConnect&&t.hasMicrophoneConnect?t.hasNetworkConnect?{info:V,success:!1}:(V=this.isChinese?"网络连接失败,请检查网络连接":"Network connection failed, please check network connection",{info:V,success:!1,remind:this.isChinese?e.networkFailAttention:e.networkFailAttentionEng}):(V=this.isChinese?t.hasNetworkConnect?"请允许浏览器及网页访问摄像头/麦克风设备":"请允许浏览器及网页访问摄像头/麦克风设备,并检查网络连接":t.hasNetworkConnect?"Please allow browser and web access to camera/microphone devices":"Please allow browser and web access to camera/microphone devices, and check the network connection",this.remindAnimation=!0,{info:V,success:!1,remind:this.isMobile?this.isChinese?e.mobileFailAttention:e.mobileFailAttentionEng:this.isChinese?e.deviceFailAttention:e.deviceFailAttentionEng}):(V=this.isChinese?`检测到${t.hasCameraDevice?"":"【摄像头】"}${t.hasMicrophoneDevice?"":"【麦克风】"}${t.hasSpeakerDevice?"":"【扬声器】"}设备不存在,请检查设备连接`:`No ${t.hasCameraDevice?"":"【camera】"}${t.hasMicrophoneDevice?"":"【microphone】"}${t.hasSpeakerDevice?"":"【speaker】"} device detected, please check the device connection`,{info:V,success:!1})}handleReset(){this.progress=0,this.showConnectResult=!1,this.setAttribute("showconnectresult",this.showConnectResult)}async attributeChangedCallback(e,t,V){if("showconnectresult"===e)if("true"===V){const e=this.shadowRoot.querySelector(".camerasvg"),t=this.shadowRoot.querySelector(".microphonesvg"),V=this.shadowRoot.querySelector(".speakersvg"),i=this.shadowRoot.querySelector(".networksvg"),n=this.shadowRoot.querySelector(".outer-progress"),A=this.shadowRoot.querySelector("trtc-custom-button");if(this.deviceState.hasCameraConnect?(e.classList.remove("connect-fail"),e.classList.add("connect-success")):e.classList.add("connect-fail"),this.deviceState.hasMicrophoneConnect?(t.classList.remove("connect-fail"),t.classList.add("connect-success")):t.classList.add("connect-fail"),this.deviceState.hasSpeakerConnect?(V.classList.add("connect-success"),V.classList.remove("connect-fail")):V.classList.add("connect-fail"),this.deviceState.hasNetworkConnect?(i.classList.add("connect-success"),i.classList.remove("connect-fail")):i.classList.add("connect-fail"),this.showReconnectButton()&&(A.setAttribute("type","outlined"),this.isChinese?A.innerHTML="重新连接":A.innerHTML="Reconnect",A.addEventListener("click",(()=>{this.remindAnimation=!1;const e=new CustomEvent("remind-changed",{detail:this.remindAnimation});this.dispatchEvent(e);const t=(new Date).getTime(),V=getCore();V&&V.kvStatManager.addFailedEvent({key:591704,error:t-this.startTime}),this.handleReset()}))),this.showStartDetectButton()&&(A.setAttribute("type","contained"),this.setAttribute("connectstage",1),this.isChinese?A.innerHTML="开始检测":A.innerHTML="Start detection"),this.showConnectResult){n.style.display="none",this.shadowRoot.querySelector(".gray-text").style.display="none";const e=this.shadowRoot.querySelector(".result");e.style.display="block",!0===this.connectResult.success?e.classList.add("green-text"):(e.classList.add("red-text"),this.connectResult.remind&&(this.shadowRoot.querySelector(".error-connect").style.display="inline-block")),e.querySelector("span").innerHTML=this.connectResult.info}}else if("false"===V){const e=this.shadowRoot.querySelector(".camerasvg"),t=this.shadowRoot.querySelector(".microphonesvg"),V=this.shadowRoot.querySelector(".speakersvg"),i=this.shadowRoot.querySelector(".networksvg"),n=this.shadowRoot.querySelector(".outer-progress"),A=this.shadowRoot.querySelector("trtc-custom-button");n.style.display="block",this.shadowRoot.querySelector(".result").classList.remove("green-text"),this.shadowRoot.querySelector(".result").classList.remove("red-text"),e.classList.remove("connect-fail"),e.classList.remove("connect-success"),t.classList.remove("connect-fail"),t.classList.remove("connect-success"),V.classList.remove("connect-fail"),V.classList.remove("connect-success"),i.classList.remove("connect-fail"),i.classList.remove("connect-success"),A.setAttribute("type","disabled"),this.isChinese?A.innerHTML="开始检测":A.innerHTML="Start detection",this.getDeviceConnectResult(),this.shadowRoot.querySelector(".gray-text").style.display="block";this.shadowRoot.querySelector(".result").style.display="none",this.shadowRoot.querySelector(".error-connect").style.display="none"}}};__publicField(_deviceConnect,"observedAttributes",["stepnamelist","showconnectresult"]),__publicField(_deviceConnect,"properties",{showRemind:{type:Boolean},constTime:{type:Number}}),__publicField(_deviceConnect,"deviceFailAttention","1. 若浏览器弹出提示,请选择“允许”<br>2. 若杀毒软件弹出提示,请选择“允许”<br>3. 检查系统设置,允许浏览器访问摄像头及麦克风<br>4. 检查浏览器设置,允许网页访问摄像头及麦克风<br>5. 检查摄像头/麦克风是否正确连接并开启<br>6. 尝试重新连接摄像头/麦克风<br>7. 尝试重启设备后重新检测"),__publicField(_deviceConnect,"deviceFailAttentionEng",'1. If the browser prompts, select "Allow"<br>2. If the antivirus software prompts, select "Allow"<br>3. Check system settings to allow camera and microphone<br>4. Check browser settings to allow camera and microphone<br>5. Check camera/microphone turned on<br>6. Try reconnecting the camera/microphone<br>7. Try restarting the device and retesting'),__publicField(_deviceConnect,"mobileFailAttention","1. 前往手机设置,打开本应用的相机和麦克风权限<br>2. 重新刷新本页并允许相机和麦克风权限<br>"),__publicField(_deviceConnect,"mobileFailAttentionEng","1. Go to your phone Settings to allow camera and microphone permissions for this app <br>2. Refresh this page and allow camera and microphone permissions <br>"),__publicField(_deviceConnect,"networkFailAttention","1. 请检查设备是否联网<br>2. 请刷新网页后再次检测<br>3. 请尝试更换网络后再次检测"),__publicField(_deviceConnect,"networkFailAttentionEng","1. Check if the device is connected to the network<br>2. Refresh the page and test again<br>3. Try again after changing the network");var deviceConnect=_deviceConnect;customElements.get("trtc-device-connect")||customElements.define("trtc-device-connect",deviceConnect);var DeviceSelect=class extends i4{constructor(){super(),this.deviceList=[],this.activeDevice={},this.activeDeviceId="",this.attachShadow({mode:"open"})}async getDeviceListData(){var e;const t=await getDeviceList(this.deviceType),V=t.map((e=>e.deviceId));this.deviceList=t,this.choseDevice&&V.indexOf(this.choseDevice.deviceId)>=0?(this.activeDevice=t.find((e=>e.deviceId===this.choseDevice.deviceId)),this.activeDeviceId=this.choseDevice.deviceId):(this.activeDevice=t[0],this.activeDeviceId=null==(e=t[0])?void 0:e.deviceId),this.onChange(this.activeDevice),this.requestUpdate()}async firstUpdated(){await this.getDeviceListData(),navigator.mediaDevices.addEventListener("devicechange",(async()=>{const e=await getDeviceList(this.deviceType);this.deviceList=e,e[0].deviceId!==this.activeDeviceId&&(this.activeDevice=e[0],this.activeDeviceId=e[0].deviceId,this.onChange(this.activeDevice)),this.requestUpdate()}))}disconnectedCallback(){this.remove()}handleChange(e){const t=e.target.value,V=getCore();V&&V.kvStatManager.addEnum({key:591713,value:1});const i=this.deviceList.find((e=>e.deviceId===t));this.activeDevice=i,this.activeDeviceId=t,this.onChange(this.activeDevice),this.requestUpdate()}render(){return x`
59
59
  <style>${style1_default}</style>
60
60
  <div>
61
61
  <select class="device-select" value=${this.activeDeviceId} @change=${this.handleChange}>
62
62
  ${this.deviceList.map(((e,t)=>x`<option value=${e.deviceId} key=${t}>${e.label}</option>`))}
63
63
  </select>
64
64
  </div>
65
- `}};__publicField(DeviceSelect,"properties",{deviceType:{type:String},onChange:{type:Function},choseDevice:{type:Object}}),customElements.get("trtc-device-select")||customElements.define("trtc-device-select",DeviceSelect);var getDeviceList=async e=>{let t=[];switch(e){case"camera":t=(await UIGetCameras()).cameraList;break;case"microphone":t=(await UIGetMicrophones()).microphoneList;break;case"speaker":t=await UIGetSpeakers()}return t},CameraDetector=class extends r4{constructor(){super(),__publicField(this,"handleCameraChange",(async e=>{var t;this.choseDevice=e;const{deviceId:V,label:i}=e;this.shadowRoot.querySelector("video");this.localStream?(null==(t=this.localStream)||t.getTracks().forEach((e=>e.stop())),this.initStream(V)):this.initStream(V),this.cameraID=V,this.cameraLabel=i,this.device=e})),__publicField(this,"handleMirrorChange",(e=>{const t=this.shadowRoot.querySelector("video");e.target.checked?t.classList.add("mirror"):t.classList.remove("mirror")})),this.currentDetector="camera",this.localStream=null,this.cameraLabel="",this.cameraID="",this.choseDevice=null,this.device=null;const e=navigator.language||navigator.userLanguage||navigator.browserLanguage||navigator.systemLanguage||"en";this.isChinese=e.indexOf("zh")>-1,this.attachShadow({mode:"open"}),this.core=getCore(),this.log=getLog()}async initStream(e){const t=this.shadowRoot.querySelector("video");t.addEventListener("touchstart",(e=>{e.preventDefault()}));const V={video:{deviceId:{exact:e}},audio:!1};navigator.mediaDevices.getUserMedia(V).then((e=>{this.localStream=e,t.srcObject=e,t.play}))}handleError(){var e;this.log&&this.log.warn("CameraFail",this.device),this.handleComplete("error",this.cameraLabel,!1,this.device);const t=(new Date).getTime();null==(e=this.localStream)||e.getTracks().forEach((e=>e.stop())),this.core&&this.core.kvStatManager.addFailedEvent({key:591706,error:t-this.constructTime})}handleSuccess(){var e;this.handleComplete("success",this.cameraLabel,!0,this.device);const t=(new Date).getTime();null==(e=this.localStream)||e.getTracks().forEach((e=>e.stop())),this.core&&this.core.kvStatManager.addSuccessEvent({key:591705,cost:t-this.constructTime})}firstUpdated(){}updated(e){e.has("activeDetector")&&this.activeDetector===this.currentDetector&&!this.localStream&&this.cameraID&&this.initStream(this.cameraID)}disconnectedCallback(){this.core=null,this.log=null,this.remove()}render(){return x`
65
+ `}};__publicField(DeviceSelect,"properties",{deviceType:{type:String},onChange:{type:Function},choseDevice:{type:Object}}),customElements.get("trtc-device-select")||customElements.define("trtc-device-select",DeviceSelect);var getDeviceList=async e=>{let t=[];switch(e){case"camera":t=(await UIGetCameras()).cameraList;break;case"microphone":t=(await UIGetMicrophones()).microphoneList;break;case"speaker":t=await UIGetSpeakers()}return t},CameraDetector=class extends i4{constructor(){super(),__publicField(this,"handleCameraChange",(async e=>{var t;this.choseDevice=e;const{deviceId:V,label:i}=e;this.shadowRoot.querySelector("video");this.localStream?(null==(t=this.localStream)||t.getTracks().forEach((e=>e.stop())),this.initStream(V)):this.initStream(V),this.cameraID=V,this.cameraLabel=i,this.device=e})),__publicField(this,"handleMirrorChange",(e=>{const t=this.shadowRoot.querySelector("video");e.target.checked?t.classList.add("mirror"):t.classList.remove("mirror")})),this.currentDetector="camera",this.localStream=null,this.cameraLabel="",this.cameraID="",this.choseDevice=null,this.device=null;const e=navigator.language||navigator.userLanguage||navigator.browserLanguage||navigator.systemLanguage||"en";this.isChinese=e.indexOf("zh")>-1,this.attachShadow({mode:"open"}),this.core=getCore(),this.log=getLog()}async initStream(e){const t=this.shadowRoot.querySelector("video");t.addEventListener("touchstart",(e=>{e.preventDefault()}));const V={video:{deviceId:{exact:e}},audio:!1};navigator.mediaDevices.getUserMedia(V).then((e=>{this.localStream=e,t.srcObject=e,t.play}))}handleError(){var e;this.log&&this.log.warn("CameraFail",this.device),this.handleComplete("error",this.cameraLabel,!1,this.device);const t=(new Date).getTime();null==(e=this.localStream)||e.getTracks().forEach((e=>e.stop())),this.core&&this.core.kvStatManager.addFailedEvent({key:591706,error:t-this.constructTime})}handleSuccess(){var e;this.handleComplete("success",this.cameraLabel,!0,this.device);const t=(new Date).getTime();null==(e=this.localStream)||e.getTracks().forEach((e=>e.stop())),this.core&&this.core.kvStatManager.addSuccessEvent({key:591705,cost:t-this.constructTime})}firstUpdated(){}updated(e){e.has("activeDetector")&&this.activeDetector===this.currentDetector&&!this.localStream&&this.cameraID&&this.initStream(this.cameraID)}disconnectedCallback(){this.core=null,this.log=null,this.remove()}render(){return x`
66
66
  <style>${style1_default}</style>
67
67
  <div ?if=${this.activeDetector===this.currentDetector} class="testing-body">
68
68
  <div class="device-list">
@@ -86,7 +86,7 @@ var __create=Object.create,__defProp=Object.defineProperty,__defProps=Object.def
86
86
  </div>
87
87
  </div>
88
88
  </div>
89
- `}};__publicField(CameraDetector,"properties",{activeDetector:{type:String},handleComplete:{type:Function},constructTime:{type:Number}}),customElements.get("trtc-camera-detector")||customElements.define("trtc-camera-detector",CameraDetector);var MicDetector=class extends r4{constructor(){super(),__publicField(this,"handleMicrophoneChange",(async e=>{this.choseDevice=e;const{deviceId:t,label:V}=e;this.localStream?(this.localStream.getTracks().forEach((e=>e.stop())),this.timer&&clearInterval(this.timer),this.initStream(t)):this.initStream(t),this.microphoneID=t,this.microphoneLabel=V,this.device=e})),this.currentDetector="microphone",this.localStream=null,this.microphoneID="",this.microphoneLabel="",this.volumeNum=0,this.choseDevice=null,this.timer=null,this.time=null,this.recording=!1,this.recordingTime=0,this.audioURL="",this.recorder=null,this.chunks=[],this.disconnect=!1,this.device=null;const e=navigator.language||navigator.userLanguage||navigator.browserLanguage||navigator.systemLanguage||"en";this.isChinese=e.indexOf("zh")>-1,this.attachShadow({mode:"open"}),this.core=getCore(),this.log=getLog()}updated(e){var t;e.has("activeDetector")&&this.activeDetector===this.currentDetector&&!this.localStream&&this.microphoneID&&this.initStream(this.microphoneID),this.activeDetector!==this.currentDetector&&(null==(t=this.localStream)||t.getTracks().forEach((e=>{e.stop()})),this.timer&&clearInterval(this.timer))}handleError(){var e;this.log&&this.log.warn("MicphoneFail",this.device);const t=(new Date).getTime();this.core&&this.core.kvStatManager.addFailedEvent({key:591708,error:t-this.constructTime}),this.handleComplete("error",this.microphoneLabel,!1,this.device,this.audioURL),null==(e=this.localStream)||e.getTracks().forEach((e=>{e.stop()})),this.timer&&clearInterval(this.timer)}handleSuccess(){var e;const t=(new Date).getTime();this.core&&this.core.kvStatManager.addSuccessEvent({key:591707,cost:t-this.constructTime}),this.handleComplete("success",this.microphoneLabel,!0,this.device,this.audioURL),null==(e=this.localStream)||e.getTracks().forEach((e=>{e.stop()})),this.timer&&clearInterval(this.timer)}firstUpdated(){}async initStream(e){this.localStream=await navigator.mediaDevices.getUserMedia({audio:{deviceId:e},video:!1});const t=new AudioContext,V=t.createAnalyser(),i=t.createMediaStreamSource(this.localStream);V.smoothingTimeConstant=.8,V.fftSize=1024,i.connect(V),this.timer=setInterval((()=>{const e=new Uint8Array(V.fftSize);V.getByteTimeDomainData(e);let t=0;const{length:i}=e;for(let V=0;V<i;V++)t+=e[V];const n=(t/i-128)/128;this.volumeNum=Math.round(50*Math.abs(28*n)),this.requestUpdate()}),100)}handleRecordClick(){const e=this.shadowRoot.querySelector(".recordingbutton");this.recording?(e.setAttribute("type","outlined"),this.recording=!1,this.recordingStartTime=null,this.time&&clearInterval(this.time),this.recorder.stop()):(e.setAttribute("type","contained"),this.recording=!0,this.recordingStartTime=Date.now(),this.recordingTime=0,this.time=setInterval((()=>{this.recordingTime=((Date.now()-this.recordingStartTime)/1e3).toFixed(2)}),100),this.startRecording())}startRecording(){this.localStream&&(this.recording=!0,this.recorder=new MediaRecorder(this.localStream),this.recorder.start(),this.recorder.ondataavailable=e=>{this.chunks.push(e.data)},this.recorder.onstop=()=>{const e=new Blob(this.chunks,{type:"audio/ogg; codecs=opus"});this.audioURL=window.URL.createObjectURL(e)})}disconnectedCallback(){this.localStream&&this.localStream.getTracks().forEach((e=>{e.stop()})),this.timer&&clearInterval(this.timer),this.disconnect=!0,this.core=null,this.log=null,this.remove()}render(){return this.disconnect&&this.timer&&clearInterval(this.timer),this.activeDetector===this.currentDetector?x`
89
+ `}};__publicField(CameraDetector,"properties",{activeDetector:{type:String},handleComplete:{type:Function},constructTime:{type:Number}}),customElements.get("trtc-camera-detector")||customElements.define("trtc-camera-detector",CameraDetector);var MicDetector=class extends i4{constructor(){super(),__publicField(this,"handleMicrophoneChange",(async e=>{this.choseDevice=e;const{deviceId:t,label:V}=e;this.localStream?(this.localStream.getTracks().forEach((e=>e.stop())),this.timer&&clearInterval(this.timer),this.initStream(t)):this.initStream(t),this.microphoneID=t,this.microphoneLabel=V,this.device=e})),this.currentDetector="microphone",this.localStream=null,this.microphoneID="",this.microphoneLabel="",this.volumeNum=0,this.choseDevice=null,this.timer=null,this.time=null,this.recording=!1,this.recordingTime=0,this.audioURL="",this.recorder=null,this.chunks=[],this.disconnect=!1,this.device=null;const e=navigator.language||navigator.userLanguage||navigator.browserLanguage||navigator.systemLanguage||"en";this.isChinese=e.indexOf("zh")>-1,this.attachShadow({mode:"open"}),this.core=getCore(),this.log=getLog()}updated(e){var t;e.has("activeDetector")&&this.activeDetector===this.currentDetector&&!this.localStream&&this.microphoneID&&this.initStream(this.microphoneID),this.activeDetector!==this.currentDetector&&(null==(t=this.localStream)||t.getTracks().forEach((e=>{e.stop()})),this.timer&&clearInterval(this.timer))}handleError(){var e;this.log&&this.log.warn("MicphoneFail",this.device);const t=(new Date).getTime();this.core&&this.core.kvStatManager.addFailedEvent({key:591708,error:t-this.constructTime}),this.handleComplete("error",this.microphoneLabel,!1,this.device,this.audioURL),null==(e=this.localStream)||e.getTracks().forEach((e=>{e.stop()})),this.timer&&clearInterval(this.timer)}handleSuccess(){var e;const t=(new Date).getTime();this.core&&this.core.kvStatManager.addSuccessEvent({key:591707,cost:t-this.constructTime}),this.handleComplete("success",this.microphoneLabel,!0,this.device,this.audioURL),null==(e=this.localStream)||e.getTracks().forEach((e=>{e.stop()})),this.timer&&clearInterval(this.timer)}firstUpdated(){}async initStream(e){this.localStream=await navigator.mediaDevices.getUserMedia({audio:{deviceId:e},video:!1});const t=new AudioContext,V=t.createAnalyser(),i=t.createMediaStreamSource(this.localStream);V.smoothingTimeConstant=.8,V.fftSize=1024,i.connect(V),this.timer=setInterval((()=>{const e=new Uint8Array(V.fftSize);V.getByteTimeDomainData(e);let t=0;const{length:i}=e;for(let V=0;V<i;V++)t+=e[V];const n=(t/i-128)/128;this.volumeNum=Math.round(50*Math.abs(28*n)),this.requestUpdate()}),100)}handleRecordClick(){const e=this.shadowRoot.querySelector(".recordingbutton");this.recording?(e.setAttribute("type","outlined"),this.recording=!1,this.recordingStartTime=null,this.time&&clearInterval(this.time),this.recorder.stop()):(e.setAttribute("type","contained"),this.recording=!0,this.recordingStartTime=Date.now(),this.recordingTime=0,this.time=setInterval((()=>{this.recordingTime=((Date.now()-this.recordingStartTime)/1e3).toFixed(2)}),100),this.startRecording())}startRecording(){this.localStream&&(this.recording=!0,this.recorder=new MediaRecorder(this.localStream),this.recorder.start(),this.recorder.ondataavailable=e=>{this.chunks.push(e.data)},this.recorder.onstop=()=>{const e=new Blob(this.chunks,{type:"audio/ogg; codecs=opus"});this.audioURL=window.URL.createObjectURL(e)})}disconnectedCallback(){this.localStream&&this.localStream.getTracks().forEach((e=>{e.stop()})),this.timer&&clearInterval(this.timer),this.disconnect=!0,this.core=null,this.log=null,this.remove()}render(){return this.disconnect&&this.timer&&clearInterval(this.timer),this.activeDetector===this.currentDetector?x`
90
90
  <style>${style1_default}</style>
91
91
  <div class="testing-body">
92
92
  <div class="device-list">
@@ -108,7 +108,7 @@ var __create=Object.create,__defProp=Object.defineProperty,__defProps=Object.def
108
108
  </div>
109
109
  </div>
110
110
  </div>
111
- `:x``}};__publicField(MicDetector,"properties",{activeDetector:{type:String},handleComplete:{type:Function},constructTime:{type:Number}}),customElements.get("trtc-mic-detector")||customElements.define("trtc-mic-detector",MicDetector);var SpeakerDetector=class extends r4{constructor(){super(),__publicField(this,"handleSpeakerChange",(async e=>{var t,V;if(this.choseDevice=e,!e)return;const{deviceId:i,label:n}=e;this.audioPlayer&&i&&await(null==(V=(t=this.audioPlayer).setSinkId)?void 0:V.call(t,i)),this.audioPlayer.src=this.audioUrl,this.speakerLabel=n,this.device=e})),this.audioPlayer=null,this.currentDetector="speaker",this.speakerLabel="",this.audioUrl="",this.choseDevice=null;const e=navigator.language||navigator.userLanguage||navigator.browserLanguage||navigator.systemLanguage||"en";this.isChinese=e.indexOf("zh")>-1,this.attachShadow({mode:"open"}),this.core=getCore(),this.log=getLog()}firstUpdated(){}updated(e){e.has("activeDetector")&&(this.activeDetector===this.currentDetector&&(this.audioPlayer=this.shadowRoot.getElementById("audio-player")),e.get("activeDetector")===this.currentDetector&&(this.audioPlayer&&!this.audioPlayer.paused&&this.audioPlayer.pause(),this.audioPlayer&&(this.audioPlayer.currentTime=0)))}handleError(){this.log&&this.log.warn("SpeakerFail",this.device);const e=(new Date).getTime();this.core&&this.core.kvStatManager.addFailedEvent({key:591710,error:e-this.constructTime}),this.handleComplete("error",this.speakerLabel,!1,this.device)}handleSuccess(){this.handleComplete("success",this.speakerLabel,!0,this.device);const e=(new Date).getTime();this.core&&this.core.kvStatManager.addSuccessEvent({key:591709,cost:e-this.constructTime})}disconnectedCallback(){this.core=null,this.log=null,this.remove()}render(){return this.activeDetector===this.currentDetector?x`
111
+ `:x``}};__publicField(MicDetector,"properties",{activeDetector:{type:String},handleComplete:{type:Function},constructTime:{type:Number}}),customElements.get("trtc-mic-detector")||customElements.define("trtc-mic-detector",MicDetector);var SpeakerDetector=class extends i4{constructor(){super(),__publicField(this,"handleSpeakerChange",(async e=>{var t,V;if(this.choseDevice=e,!e)return;const{deviceId:i,label:n}=e;this.audioPlayer&&i&&await(null==(V=(t=this.audioPlayer).setSinkId)?void 0:V.call(t,i)),this.audioPlayer.src=this.audioUrl,this.speakerLabel=n,this.device=e})),this.audioPlayer=null,this.currentDetector="speaker",this.speakerLabel="",this.audioUrl="",this.choseDevice=null;const e=navigator.language||navigator.userLanguage||navigator.browserLanguage||navigator.systemLanguage||"en";this.isChinese=e.indexOf("zh")>-1,this.attachShadow({mode:"open"}),this.core=getCore(),this.log=getLog()}firstUpdated(){}updated(e){e.has("activeDetector")&&(this.activeDetector===this.currentDetector&&(this.audioPlayer=this.shadowRoot.getElementById("audio-player")),e.get("activeDetector")===this.currentDetector&&(this.audioPlayer&&!this.audioPlayer.paused&&this.audioPlayer.pause(),this.audioPlayer&&(this.audioPlayer.currentTime=0)))}handleError(){this.log&&this.log.warn("SpeakerFail",this.device);const e=(new Date).getTime();this.core&&this.core.kvStatManager.addFailedEvent({key:591710,error:e-this.constructTime}),this.handleComplete("error",this.speakerLabel,!1,this.device)}handleSuccess(){this.handleComplete("success",this.speakerLabel,!0,this.device);const e=(new Date).getTime();this.core&&this.core.kvStatManager.addSuccessEvent({key:591709,cost:e-this.constructTime})}disconnectedCallback(){this.core=null,this.log=null,this.remove()}render(){return this.activeDetector===this.currentDetector?x`
112
112
  <style>${style1_default}</style>
113
113
  <div class="testing-body">
114
114
  <div class="device-list">
@@ -127,7 +127,7 @@ var __create=Object.create,__defProp=Object.defineProperty,__defProps=Object.def
127
127
  </div>
128
128
  </div>
129
129
  </div>
130
- `:x``}};__publicField(SpeakerDetector,"properties",{audioUrl:{type:String},activeDetector:String,handleComplete:Function,constructTime:{type:Number}}),customElements.get("trtc-speaker-detector")||customElements.define("trtc-speaker-detector",SpeakerDetector);var NetworkDetector=class extends r4{constructor(){super(),this.NETWORK_QUALITY={},this.currentDetector="network",this.detectorInfo={},this.count=15,this.timer=null,this.networkInfo=null,this.core=getCore(),this.log=getLog(),this.testResult={uplinkNetworkQualities:[],downlinkNetworkQualities:[],rttList:[],average:{uplinkNetworkQuality:0,downlinkNetworkQuality:0,rtt:0},result:{rtt:0,quality:0}},this._initializeTRTC(),this.isDownlink=!1,this.networkInfo&&this.networkInfo.downlinkUserId&&this.networkInfo.downlinkUserSig&&(this.isDownlink=!0),this.Enum={0:"0:网络状况未知",1:"1:网络状况极佳",2:"2:网络状况较好",3:"3:网络状况一般",4:"4:网络状况较差",5:"5:网络状况极差",6:"6:网络连接断开"},this.EnumEng={0:"0: unknown",1:"1: excellent",2:"2: good",3:"3: fair",4:"4: poor",5:"5: very poor",6:"6: disconnected"};const e=navigator.language||navigator.userLanguage||navigator.browserLanguage||navigator.systemLanguage||"en";this.isChinese=e.indexOf("zh")>-1,this.attachShadow({mode:"open"})}_initializeTRTC(){this.networkInfo=sdk_default.networkInfo,Object.defineProperty(sdk_default,"networkInfo",{set:e=>{this.networkInfo=e},get:()=>this.networkInfo})}firstUpdated(){}updated(e){e.has("activeDetector")&&this.activeDetector===this.currentDetector&&0!==this.count&&(this.count=15,this.getDetectorInfo())}async testUplinkNetworkQuality(){const{sdkAppId:e,uplinkTRTC:t,userId:V,userSig:i,roomId:n}=this.networkInfo;try{await t.exitRoom()}catch(e){}await t.enterRoom({roomId:n||8080,sdkAppId:e,userId:V,userSig:i,scene:"rtc"}),!this.hasStartLocalVideo&&await t.startLocalVideo({option:{profile:"480p"}}),this.setHasStartLocalVideo(),this.hasStartLocalVideo=!0,t.on(this.core.TRTC.EVENT.NETWORK_QUALITY,(e=>{const{uplinkNetworkQuality:t,uplinkRTT:V}=e;this.testResult.uplinkNetworkQualities.push(t),this.testResult.rttList.push(V)}))}async testDownlinkNetworkQuality(){const{sdkAppId:e,downlinkUserId:t,downlinkTRTC:V,downlinkUserSig:i,roomId:n}=this.networkInfo;try{await V.exitRoom()}catch(e){}await V.enterRoom({roomId:n||8080,sdkAppId:e,userId:t,userSig:i,scene:"rtc"}),V.on(this.core.TRTC.EVENT.NETWORK_QUALITY,(e=>{const{downlinkNetworkQuality:t}=e;this.testResult.downlinkNetworkQualities.push(t)}))}async getDetectorInfo(){const e=sdk_default.getSystem(),t=await sdk_default.isTRTCSupported(),V=sdk_default.getAPISupported();this.detectorInfo={system:e.OS,browser:`${e.browser.name} ${e.browser.version}`,TRTCSupport:t.result?"Yes":"No",screenMediaSupport:V.isScreenCaptureAPISupported?"Yes":"No"},this.timer=setInterval((()=>{this.count=this.count-1,this.requestUpdate(),0===this.count&&clearInterval(this.timer)}),1e3),this.testUplinkNetworkQuality(),this.isDownlink&&this.testDownlinkNetworkQuality(),setTimeout((async()=>{const e=this.testResult.uplinkNetworkQualities.filter((e=>e>=1&&e<=5));e.length>0&&(this.testResult.average.uplinkNetworkQuality=Math.ceil(e.reduce(((e,t)=>e+t),0)/e.length));const t=this.testResult.downlinkNetworkQualities.filter((e=>e>=1&&e<=5));t.length>0&&(this.testResult.average.downlinkNetworkQuality=Math.ceil(t.reduce(((e,t)=>e+t),0)/t.length));const V=this.testResult.rttList.filter((e=>e>0));V.length>0&&(this.testResult.average.rtt=Math.ceil(V.reduce(((e,t)=>e+t),0)/V.length)),0===this.testResult.average.uplinkNetworkQuality||this.isDownlink&&0===this.testResult.average.downlinkNetworkQuality?this.testResult.result.quality=0:this.testResult.result.quality=Math.max(this.testResult.average.uplinkNetworkQuality,this.testResult.average.downlinkNetworkQuality),this.testResult.result.rtt=this.testResult.average.rtt,this.requestUpdate(),await this.networkInfo.uplinkTRTC.stopLocalVideo(),this.networkInfo.uplinkTRTC.exitRoom(),this.isDownlink&&this.networkInfo.downlinkTRTC.exitRoom()}),15e3)}disconnectedCallback(){this.timer&&clearInterval(this.timer),this.remove(),this.core=null,this.log=null}async handleSuccess(){this.hasStartLocalVideo&&await this.networkInfo.uplinkTRTC.stopLocalVideo(),this.generateReport();const e=(new Date).getTime();this.core&&this.core.kvStatManager.addSuccessEvent({key:591711,cost:e-this.constructTime}),0!==this.testResult.result.quality&&0!==this.testResult.result.rtt||this.log&&this.log.warn("NetworkFail",this.testResult.average),this.handleComplete("success",this.testResult.result,0!==this.testResult.result.quality)}render(){return this.activeDetector===this.currentDetector?x`
130
+ `:x``}};__publicField(SpeakerDetector,"properties",{audioUrl:{type:String},activeDetector:String,handleComplete:Function,constructTime:{type:Number}}),customElements.get("trtc-speaker-detector")||customElements.define("trtc-speaker-detector",SpeakerDetector);var NetworkDetector=class extends i4{constructor(){super(),this.NETWORK_QUALITY={},this.currentDetector="network",this.detectorInfo={},this.count=15,this.timer=null,this.networkInfo=null,this.core=getCore(),this.log=getLog(),this.testResult={uplinkNetworkQualities:[],downlinkNetworkQualities:[],rttList:[],average:{uplinkNetworkQuality:0,downlinkNetworkQuality:0,rtt:0},result:{rtt:0,quality:0}},this._initializeTRTC(),this.isDownlink=!1,this.networkInfo&&this.networkInfo.downlinkUserId&&this.networkInfo.downlinkUserSig&&(this.isDownlink=!0),this.Enum={0:"0:网络状况未知",1:"1:网络状况极佳",2:"2:网络状况较好",3:"3:网络状况一般",4:"4:网络状况较差",5:"5:网络状况极差",6:"6:网络连接断开"},this.EnumEng={0:"0: unknown",1:"1: excellent",2:"2: good",3:"3: fair",4:"4: poor",5:"5: very poor",6:"6: disconnected"};const e=navigator.language||navigator.userLanguage||navigator.browserLanguage||navigator.systemLanguage||"en";this.isChinese=e.indexOf("zh")>-1,this.attachShadow({mode:"open"})}_initializeTRTC(){this.networkInfo=sdk_default.networkInfo,Object.defineProperty(sdk_default,"networkInfo",{set:e=>{this.networkInfo=e},get:()=>this.networkInfo})}firstUpdated(){}updated(e){e.has("activeDetector")&&this.activeDetector===this.currentDetector&&0!==this.count&&(this.count=15,this.getDetectorInfo())}async testUplinkNetworkQuality(){const{sdkAppId:e,uplinkTRTC:t,userId:V,userSig:i,roomId:n}=this.networkInfo;try{await t.exitRoom()}catch(e){}await t.enterRoom({roomId:n||8080,sdkAppId:e,userId:V,userSig:i,scene:"rtc"}),!this.hasStartLocalVideo&&await t.startLocalVideo({option:{profile:"480p"}}),this.setHasStartLocalVideo(),this.hasStartLocalVideo=!0,t.on(this.core.TRTC.EVENT.NETWORK_QUALITY,(e=>{const{uplinkNetworkQuality:t,uplinkRTT:V}=e;this.testResult.uplinkNetworkQualities.push(t),this.testResult.rttList.push(V)}))}async testDownlinkNetworkQuality(){const{sdkAppId:e,downlinkUserId:t,downlinkTRTC:V,downlinkUserSig:i,roomId:n}=this.networkInfo;try{await V.exitRoom()}catch(e){}await V.enterRoom({roomId:n||8080,sdkAppId:e,userId:t,userSig:i,scene:"rtc"}),V.on(this.core.TRTC.EVENT.NETWORK_QUALITY,(e=>{const{downlinkNetworkQuality:t}=e;this.testResult.downlinkNetworkQualities.push(t)}))}async getDetectorInfo(){const e=sdk_default.getSystem(),t=await sdk_default.isTRTCSupported(),V=sdk_default.getAPISupported();this.detectorInfo={system:e.OS,browser:`${e.browser.name} ${e.browser.version}`,TRTCSupport:t.result?"Yes":"No",screenMediaSupport:V.isScreenCaptureAPISupported?"Yes":"No"},this.timer=setInterval((()=>{this.count=this.count-1,this.requestUpdate(),0===this.count&&clearInterval(this.timer)}),1e3),this.testUplinkNetworkQuality(),this.isDownlink&&this.testDownlinkNetworkQuality(),setTimeout((async()=>{const e=this.testResult.uplinkNetworkQualities.filter((e=>e>=1&&e<=5));e.length>0&&(this.testResult.average.uplinkNetworkQuality=Math.ceil(e.reduce(((e,t)=>e+t),0)/e.length));const t=this.testResult.downlinkNetworkQualities.filter((e=>e>=1&&e<=5));t.length>0&&(this.testResult.average.downlinkNetworkQuality=Math.ceil(t.reduce(((e,t)=>e+t),0)/t.length));const V=this.testResult.rttList.filter((e=>e>0));V.length>0&&(this.testResult.average.rtt=Math.ceil(V.reduce(((e,t)=>e+t),0)/V.length)),0===this.testResult.average.uplinkNetworkQuality||this.isDownlink&&0===this.testResult.average.downlinkNetworkQuality?this.testResult.result.quality=0:this.testResult.result.quality=Math.max(this.testResult.average.uplinkNetworkQuality,this.testResult.average.downlinkNetworkQuality),this.testResult.result.rtt=this.testResult.average.rtt,this.requestUpdate(),await this.networkInfo.uplinkTRTC.stopLocalVideo(),this.networkInfo.uplinkTRTC.exitRoom(),this.isDownlink&&this.networkInfo.downlinkTRTC.exitRoom()}),15e3)}disconnectedCallback(){this.timer&&clearInterval(this.timer),this.remove(),this.core=null,this.log=null}async handleSuccess(){this.hasStartLocalVideo&&await this.networkInfo.uplinkTRTC.stopLocalVideo(),this.generateReport();const e=(new Date).getTime();this.core&&this.core.kvStatManager.addSuccessEvent({key:591711,cost:e-this.constructTime}),0!==this.testResult.result.quality&&0!==this.testResult.result.rtt||this.log&&this.log.warn("NetworkFail",this.testResult.average),this.handleComplete("success",this.testResult.result,0!==this.testResult.result.quality)}render(){return this.activeDetector===this.currentDetector?x`
131
131
  <style>${style1_default}</style>
132
132
  <div class="testing-body">
133
133
  <div class="testing-list">
@@ -173,7 +173,7 @@ var __create=Object.create,__defProp=Object.defineProperty,__defProps=Object.def
173
173
  </div>
174
174
  ${this.count>0?x`<trtc-custom-button class="gray-button" type="disabled">${this.isChinese?"剩余检测时间":"Remaining time"}(${this.count})s</trtc-custom-button>`:x`<trtc-custom-button class="report-button" type="contained" @click=${e=>{this.handleSuccess()}}>${this.isChinese?"查看检测报告":"View detect report"}</trtc-custom-button>`}
175
175
  </div>
176
- `:x``}};__publicField(NetworkDetector,"properties",{activeDetector:String,networkDetectInfo:Object,handleComplete:Function,generateReport:Function,testResult:Object,hasStartLocalVideo:Boolean,setHasStartLocalVideo:Function,constructTime:Number}),customElements.get("trtc-network-detector")||customElements.define("trtc-network-detector",NetworkDetector);var DetectorReport=class extends r4{constructor(){super();const e=navigator.language||navigator.userLanguage||navigator.browserLanguage||navigator.systemLanguage||"en";this.isChinese=e.indexOf("zh")>-1,this.attachShadow({mode:"open"})}render(){return x`
176
+ `:x``}};__publicField(NetworkDetector,"properties",{activeDetector:String,networkDetectInfo:Object,handleComplete:Function,generateReport:Function,testResult:Object,hasStartLocalVideo:Boolean,setHasStartLocalVideo:Function,constructTime:Number}),customElements.get("trtc-network-detector")||customElements.define("trtc-network-detector",NetworkDetector);var DetectorReport=class extends i4{constructor(){super();const e=navigator.language||navigator.userLanguage||navigator.browserLanguage||navigator.systemLanguage||"en";this.isChinese=e.indexOf("zh")>-1,this.attachShadow({mode:"open"})}render(){return x`
177
177
  <style>${style1_default}</style>
178
178
  <div class="device-testing-report">
179
179
  <div class="testing-title">${this.isChinese?"检测报告":"Detect Report"}</div>
@@ -247,7 +247,7 @@ var __create=Object.create,__defProp=Object.defineProperty,__defProps=Object.def
247
247
  <trtc-custom-button type="contained" @click=${this.handleClose}>${this.isChinese?"完成检测":"Completed"}</trtc-custom-button>
248
248
  </div>
249
249
  </div>
250
- `}firstUpdated(){}goodUplinkQuality(){return this.reportData.network.result.uplinkQuality>0&&this.reportData.network.result.uplinkQuality<4}goodDownlinkQuality(){return this.reportData.network.result.downlinkQuality>0&&this.reportData.network.result.downlinkQuality<4}};__publicField(DetectorReport,"properties",{reportData:Object,handleReset:Function,handleClose:Function}),customElements.get("trtc-detect-report")||customElements.define("trtc-detect-report",DetectorReport);var _DetectorUI=class e extends r4{constructor(){super(),__publicField(this,"detectResult"),__publicField(this,"handleCompleted",((e,t,V=!1,i=null,n="")=>{this.completed[this.stepNameList[this.activeStep]]={completed:!0,type:e,result:t},"network"===this.stepNameList[this.activeStep]?this.completedResult[this.stepNameList[this.activeStep]]={isSuccess:V,result:t}:this.completedResult[this.stepNameList[this.activeStep]]={isSuccess:V,device:i},0!==n.length&&(this.audioURL=n),this.activeStep<=this.stepNameList.length-1&&(this.activeStep=this.activeStep+1,this.stepNameList.indexOf("network")<0&&this.activeStep===this.stepNameList.length&&(this.detectStage=2)),this.requestUpdate()})),this.stepNameList=["camera","microphone","speaker"];const e=navigator.language||navigator.userLanguage||navigator.browserLanguage||navigator.systemLanguage||"en";this.isChinese=e.indexOf("zh")>-1,this.detectStage=0,this.completed={},this.completedResult={},this.activeStep=0,this.audioURL="",this.isCompleted=!1,this.baseURL="data:audio/mp3;base64,",this.isChinese?this.audioURL=this.baseURL+SpeakerCNbase64:this.audioURL=this.baseURL+SpeakerEngbase64,this.uplinkTRTC={},this.sdkAppId=0,this.isOpen=!0,this.hasStartLocalVideo=!1,this.remind=!1,this.envresult=sdk_default.getSystem(),this.isMobile="iOS"===this.envresult.OS||"Android"===this.envresult.OS,this.constructTime=(new Date).getTime(),this.cameraHasBeenActive=!1,this.microphoneHasBeenActive=!1,this.SpeakerHasBeenActive=!1,this.networkHasBeenActive=!1,this._initializeTRTC(),this.attachShadow({mode:"open"})}triggerCompletedEvent(){const e=new Event("detectorCompleted");this.dispatchEvent(e)}static registerTag(){customElements.get("detector-element")||customElements.define("detector-element",e)}_initializeTRTC(){let e=sdk_default.networkInfo;sdk_default.networkInfo&&this.stepNameList.indexOf("network")<0&&this.stepNameList.push("network"),Object.defineProperty(sdk_default,"networkInfo",{set:t=>{this.stepNameList.indexOf("network")<0&&this.stepNameList.push("network"),e=t},get:()=>e})}render(){return!0===this.isOpen?x`
250
+ `}firstUpdated(){}goodUplinkQuality(){return this.reportData.network.result.uplinkQuality>0&&this.reportData.network.result.uplinkQuality<4}goodDownlinkQuality(){return this.reportData.network.result.downlinkQuality>0&&this.reportData.network.result.downlinkQuality<4}};__publicField(DetectorReport,"properties",{reportData:Object,handleReset:Function,handleClose:Function}),customElements.get("trtc-detect-report")||customElements.define("trtc-detect-report",DetectorReport);var _DetectorUI=class e extends i4{constructor(){super(),__publicField(this,"detectResult"),__publicField(this,"handleCompleted",((e,t,V=!1,i=null,n="")=>{this.completed[this.stepNameList[this.activeStep]]={completed:!0,type:e,result:t},"network"===this.stepNameList[this.activeStep]?this.completedResult[this.stepNameList[this.activeStep]]={isSuccess:V,result:t}:this.completedResult[this.stepNameList[this.activeStep]]={isSuccess:V,device:i},0!==n.length&&(this.audioURL=n),this.activeStep<=this.stepNameList.length-1&&(this.activeStep=this.activeStep+1,this.stepNameList.indexOf("network")<0&&this.activeStep===this.stepNameList.length&&(this.detectStage=2)),this.requestUpdate()})),this.stepNameList=["camera","microphone","speaker"];const e=navigator.language||navigator.userLanguage||navigator.browserLanguage||navigator.systemLanguage||"en";this.isChinese=e.indexOf("zh")>-1,this.detectStage=0,this.completed={},this.completedResult={},this.activeStep=0,this.audioURL="",this.isCompleted=!1,this.baseURL="data:audio/mp3;base64,",this.isChinese?this.audioURL=this.baseURL+SpeakerCNbase64:this.audioURL=this.baseURL+SpeakerEngbase64,this.uplinkTRTC={},this.sdkAppId=0,this.isOpen=!0,this.hasStartLocalVideo=!1,this.remind=!1,this.envresult=sdk_default.getSystem(),this.isMobile="iOS"===this.envresult.OS||"Android"===this.envresult.OS,this.constructTime=(new Date).getTime(),this.cameraHasBeenActive=!1,this.microphoneHasBeenActive=!1,this.SpeakerHasBeenActive=!1,this.networkHasBeenActive=!1,this._initializeTRTC(),this.attachShadow({mode:"open"})}triggerCompletedEvent(){const e=new Event("detectorCompleted");this.dispatchEvent(e)}static registerTag(){customElements.get("detector-element")||customElements.define("detector-element",e)}_initializeTRTC(){let e=sdk_default.networkInfo;sdk_default.networkInfo&&this.stepNameList.indexOf("network")<0&&this.stepNameList.push("network"),Object.defineProperty(sdk_default,"networkInfo",{set:t=>{this.stepNameList.indexOf("network")<0&&this.stepNameList.push("network"),e=t},get:()=>e})}render(){return!0===this.isOpen?x`
251
251
  <style>${style1_default}</style>
252
252
  ${!0===this.remind&&"iOS"!==this.envresult.OS&&"Android"!==this.envresult.OS?x`
253
253
  <div class="arrow"></div>