/*!
Copyright (c) 2026 Lenovo SSG BASD. All rights reserved.
@license Proprietary

This software is the confidential and proprietary property of Lenovo SSG BASD.
You shall not disclose such Confidential Information and shall use it only in
accordance with the terms of the license agreement.

--- Build Info ---
Version: 1.1.1
Build Time: 2026/2/26 17:21:00
Build Commit: 81e556ed827e2f043668506dae6fae8dbb9ef395
*/
var e=/(Android)\s([\d.]+)/,i=/(Version)\/([\d.]+)/,t=["avc1.42E01E, mp4a.40.2","avc1.58A01E, mp4a.40.2","avc1.4D401E, mp4a.40.2","avc1.64001E, mp4a.40.2","avc1.42E01E","mp4v.20.8","mp4v.20.8, mp4a.40.2","mp4v.20.240, mp4a.40.2"],o={get device(){return o.os.isPc?"pc":"mobile"},get browser(){if("undefined"==typeof navigator)return"";var e=navigator.userAgent.toLowerCase(),i={ie:/rv:([\d.]+)\) like gecko/,firefox:/firefox\/([\d.]+)/,chrome:/chrome\/([\d.]+)/,opera:/opera.([\d.]+)/,safari:/version\/([\d.]+).*safari/};return[].concat(Object.keys(i).filter(function(t){return i[t].test(e)}))[0]},get os(){if("undefined"==typeof navigator)return{};var e=navigator.userAgent,i=/(?:Windows Phone)/.test(e),t=/(?:SymbianOS)/.test(e)||i,o=/(?:Tizen)/gi.test(e),r=/(?:Web0S)/gi.test(e),n=/(?:Android)/.test(e),a=/(?:Firefox)/.test(e),s=/(?:iPad|PlayBook)/.test(e)||"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1,p=s||n&&!/(?:Mobile)/.test(e)||a&&/(?:Tablet)/.test(e),d=/(?:iPhone)/.test(e)&&!p;return{isTablet:p,isPhone:d,isIpad:s,isIos:d||s,isAndroid:n,isPc:!(d||n||t||p),isSymbian:t,isWindowsPhone:i,isFireFox:a,isTizen:o,isWebOS:r}},get osVersion(){if("undefined"==typeof navigator)return 0;var t=navigator.userAgent,o="",r=(o=/(?:iPhone)|(?:iPad|PlayBook)/.test(t)?i:e)?o.exec(t):[];if(r&&r.length>=3){var n=r[2].split(".");return n.length>0?parseInt(n[0]):0}return 0},get isWeixin(){if("undefined"==typeof navigator)return!1;return!!/(micromessenger)\/([\d.]+)/.exec(navigator.userAgent.toLocaleLowerCase())},isSupportMP4:function(){var e={isSupport:!1,mime:""};if("undefined"==typeof document)return e;if(this.supportResult)return this.supportResult;var i=document.createElement("video");return"function"==typeof i.canPlayType&&t.map(function(t){"probably"===i.canPlayType('video/mp4; codecs="'.concat(t,'"'))&&(e.isSupport=!0,e.mime+="||".concat(t))}),this.supportResult=e,i=null,e},isMSESupport:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:'video/mp4; codecs="avc1.42E01E,mp4a.40.2"';if("undefined"==typeof MediaSource||!MediaSource)return!1;try{return MediaSource.isTypeSupported(e)}catch(i){return this._logger.error(e,i),!1}},isHevcSupported:function(){return!("undefined"==typeof MediaSource||!MediaSource.isTypeSupported)&&(MediaSource.isTypeSupported('video/mp4;codecs="hev1.1.6.L120.90"')||MediaSource.isTypeSupported('video/mp4;codecs="hev1.2.4.L120.90"')||MediaSource.isTypeSupported('video/mp4;codecs="hev1.3.E.L120.90"')||MediaSource.isTypeSupported('video/mp4;codecs="hev1.4.10.L120.90"'))},probeConfigSupported:function(e){var i={supported:!1,smooth:!1,powerEfficient:!1};if(!e||"undefined"==typeof navigator)return Promise.resolve(i);if(navigator.mediaCapabilities&&navigator.mediaCapabilities.decodingInfo)return navigator.mediaCapabilities.decodingInfo(e);var t=e.video||{},o=e.audio||{};try{var r=MediaSource.isTypeSupported(t.contentType),n=MediaSource.isTypeSupported(o.contentType);return Promise.resolve({supported:r&&n,smooth:!1,powerEfficient:!1})}catch(a){return Promise.resolve(i)}}};export{o as default};