hocmai-feedback-widget 0.1.0 → 0.1.1
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.
package/README.md
CHANGED
|
@@ -13,9 +13,9 @@ A React library for collecting user feedback with screenshot capabilities, conte
|
|
|
13
13
|
|
|
14
14
|
### Via NPM/Yarn
|
|
15
15
|
```bash
|
|
16
|
-
npm install
|
|
16
|
+
npm install hocmai-feedback-widget
|
|
17
17
|
# or
|
|
18
|
-
yarn add
|
|
18
|
+
yarn add hocmai-feedback-widget
|
|
19
19
|
```
|
|
20
20
|
|
|
21
21
|
### Local Installation
|
|
@@ -26,7 +26,7 @@ yarn add @antigravity/feedback-widget
|
|
|
26
26
|
```
|
|
27
27
|
2. Install the generated `.tgz` file in your target project:
|
|
28
28
|
```bash
|
|
29
|
-
npm install ./path/to/
|
|
29
|
+
npm install ./path/to/hocmai-feedback-widget-0.1.0.tgz
|
|
30
30
|
```
|
|
31
31
|
|
|
32
32
|
## Usage
|
|
@@ -35,7 +35,7 @@ yarn add @antigravity/feedback-widget
|
|
|
35
35
|
Wrap your root component (or the section of the app that needs feedback) with `FeedbackProvider`.
|
|
36
36
|
|
|
37
37
|
```tsx
|
|
38
|
-
import { FeedbackProvider, type FeedbackData } from '
|
|
38
|
+
import { FeedbackProvider, type FeedbackData } from 'hocmai-feedback-widget';
|
|
39
39
|
// If styles are not automatically injected by your bundler, you might need:
|
|
40
40
|
// import '@antigravity/feedback-widget/dist/style.css';
|
|
41
41
|
|
|
@@ -60,7 +60,7 @@ function App() {
|
|
|
60
60
|
Use the `useFeedback` hook anywhere in your child components to open the widget for a specific item.
|
|
61
61
|
|
|
62
62
|
```tsx
|
|
63
|
-
import { useFeedback } from '
|
|
63
|
+
import { useFeedback } from 'hocmai-feedback-widget';
|
|
64
64
|
|
|
65
65
|
const QuestionItem = ({ id, content }) => {
|
|
66
66
|
const { openFeedback } = useFeedback();
|
|
@@ -82,7 +82,7 @@ const QuestionItem = ({ id, content }) => {
|
|
|
82
82
|
If you only need a single widget instance and manage state manually:
|
|
83
83
|
|
|
84
84
|
```tsx
|
|
85
|
-
import { FeedbackWidget } from '
|
|
85
|
+
import { FeedbackWidget } from 'hocmai-feedback-widget';
|
|
86
86
|
|
|
87
87
|
<FeedbackWidget
|
|
88
88
|
questionId="123"
|
|
@@ -108,7 +108,7 @@ Returns an object with:
|
|
|
108
108
|
This library is fully compatible with standard JavaScript projects. The usage is identical, just without type annotations.
|
|
109
109
|
|
|
110
110
|
```jsx
|
|
111
|
-
import { FeedbackProvider, useFeedback } from '
|
|
111
|
+
import { FeedbackProvider, useFeedback } from 'hocmai-feedback-widget';
|
|
112
112
|
|
|
113
113
|
function App() {
|
|
114
114
|
const handleSubmit = async (data) => {
|
|
@@ -2330,9 +2330,9 @@ const $r = [
|
|
|
2330
2330
|
listImage: Z,
|
|
2331
2331
|
deviceInfo: k,
|
|
2332
2332
|
contextData: i
|
|
2333
|
-
}), qe()
|
|
2333
|
+
}), qe();
|
|
2334
2334
|
} catch (k) {
|
|
2335
|
-
console.error("Submit feedback failed", k)
|
|
2335
|
+
console.error("Submit feedback failed", k);
|
|
2336
2336
|
} finally {
|
|
2337
2337
|
ht(!1);
|
|
2338
2338
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
(function(D,p){typeof exports=="object"&&typeof module<"u"?p(exports,require("react/jsx-runtime"),require("react")):typeof define=="function"&&define.amd?define(["exports","react/jsx-runtime","react"],p):(D=typeof globalThis<"u"?globalThis:D||self,p(D.SupportFeedbackLib={},D.jsxRuntime,D.React))})(this,(function(D,p,x){"use strict";var ii="2.0.7",ri=500,dt="user-agent",Z="",ut="?",k={FUNCTION:"function",OBJECT:"object",STRING:"string",UNDEFINED:"undefined"},I="browser",$="cpu",H="device",P="engine",A="os",ee="result",c="name",a="type",d="vendor",u="version",E="architecture",he="major",l="model",ke="console",w="mobile",v="tablet",C="smarttv",U="wearable",Se="xr",fe="embedded",te="inapp",ze="brands",Y="formFactors",$e="fullVersionList",ie="platform",Be="platformVersion",Ce="bitness",q="sec-ch-ua",ni=q+"-full-version-list",oi=q+"-arch",si=q+"-"+Ce,ai=q+"-form-factors",li=q+"-"+w,ci=q+"-"+l,ht=q+"-"+ie,di=ht+"-version",ft=[ze,$e,w,l,ie,Be,E,Y,Ce],Ee="Amazon",re="Apple",pt="ASUS",bt="BlackBerry",K="Google",gt="Huawei",Ve="Lenovo",wt="Honor",Ie="LG",We="Microsoft",qe="Motorola",mt="Nvidia",yt="OnePlus",Re="OPPO",pe="Samsung",xt="Sharp",be="Sony",je="Xiaomi",Ne="Zebra",vt="Chrome",kt="Chromium",R="Chromecast",Te="Edge",ge="Firefox",we="Opera",Ge="Facebook",St="Sogou",ne="Mobile ",me=" Browser",Xe="Windows",ui=typeof window!==k.UNDEFINED,T=ui&&window.navigator?window.navigator:void 0,Q=T&&T.userAgentData?T.userAgentData:void 0,hi=function(e,t){var i={},r=t;if(!Me(t)){r={};for(var o in t)for(var s in t[o])r[s]=t[o][s].concat(r[s]?r[s]:[])}for(var n in e)i[n]=r[n]&&r[n].length%2===0?r[n].concat(e[n]):e[n];return i},Oe=function(e){for(var t={},i=0;i<e.length;i++)t[e[i].toUpperCase()]=e[i];return t},Ye=function(e,t){if(typeof e===k.OBJECT&&e.length>0){for(var i in e)if(j(t)==j(e[i]))return!0;return!1}return ye(e)?j(t)==j(e):!1},Me=function(e,t){for(var i in e)return/^(browser|cpu|device|engine|os)$/.test(i)||(t?Me(e[i]):!1)},ye=function(e){return typeof e===k.STRING},Ke=function(e){if(e){for(var t=[],i=oe(/\\?\"/g,e).split(","),r=0;r<i.length;r++)if(i[r].indexOf(";")>-1){var o=Ae(i[r]).split(";v=");t[r]={brand:o[0],version:o[1]}}else t[r]=Ae(i[r]);return t}},j=function(e){return ye(e)?e.toLowerCase():e},Qe=function(e){return ye(e)?oe(/[^\d\.]/g,e).split(".")[0]:void 0},B=function(e){for(var t in e)if(e.hasOwnProperty(t)){var i=e[t];typeof i==k.OBJECT&&i.length==2?this[i[0]]=i[1]:this[i]=void 0}return this},oe=function(e,t){return ye(t)?t.replace(e,Z):t},xe=function(e){return oe(/\\?\"/g,e)},Ae=function(e,t){return e=oe(/^\s\s*/,String(e)),typeof t===k.UNDEFINED?e:e.substring(0,t)},Je=function(e,t){if(!(!e||!t))for(var i=0,r,o,s,n,h,f;i<t.length&&!h;){var g=t[i],m=t[i+1];for(r=o=0;r<g.length&&!h&&g[r];)if(h=g[r++].exec(e),h)for(s=0;s<m.length;s++)f=h[++o],n=m[s],typeof n===k.OBJECT&&n.length>0?n.length===2?typeof n[1]==k.FUNCTION?this[n[0]]=n[1].call(this,f):this[n[0]]=n[1]:n.length>=3&&(typeof n[1]===k.FUNCTION&&!(n[1].exec&&n[1].test)?n.length>3?this[n[0]]=f?n[1].apply(this,n.slice(2)):void 0:this[n[0]]=f?n[1].call(this,f,n[2]):void 0:n.length==3?this[n[0]]=f?f.replace(n[1],n[2]):void 0:n.length==4?this[n[0]]=f?n[3].call(this,f.replace(n[1],n[2])):void 0:n.length>4&&(this[n[0]]=f?n[3].apply(this,[f.replace(n[1],n[2])].concat(n.slice(4))):void 0)):this[n]=f||void 0;i+=2}},L=function(e,t){for(var i in t)if(typeof t[i]===k.OBJECT&&t[i].length>0){for(var r=0;r<t[i].length;r++)if(Ye(t[i][r],e))return i===ut?void 0:i}else if(Ye(t[i],e))return i===ut?void 0:i;return t.hasOwnProperty("*")?t["*"]:e},Ct={ME:"4.90","NT 3.51":"3.51","NT 4.0":"4.0",2e3:["5.0","5.01"],XP:["5.1","5.2"],Vista:"6.0",7:"6.1",8:"6.2","8.1":"6.3",10:["6.4","10.0"],NT:""},Et={embedded:"Automotive",mobile:"Mobile",tablet:["Tablet","EInk"],smarttv:"TV",wearable:"Watch",xr:["VR","XR"],"?":["Desktop","Unknown"],"*":void 0},fi={Chrome:"Google Chrome",Edge:"Microsoft Edge","Edge WebView2":"Microsoft Edge WebView2","Chrome WebView":"Android WebView","Chrome Headless":"HeadlessChrome","Huawei Browser":"HuaweiBrowser","MIUI Browser":"Miui Browser","Opera Mobi":"OperaMobile",Yandex:"YaBrowser"},It={browser:[[/\b(?:crmo|crios)\/([\w\.]+)/i],[u,[c,ne+"Chrome"]],[/webview.+edge\/([\w\.]+)/i],[u,[c,Te+" WebView"]],[/edg(?:e|ios|a)?\/([\w\.]+)/i],[u,[c,"Edge"]],[/(opera mini)\/([-\w\.]+)/i,/(opera [mobiletab]{3,6})\b.+version\/([-\w\.]+)/i,/(opera)(?:.+version\/|[\/ ]+)([\w\.]+)/i],[c,u],[/opios[\/ ]+([\w\.]+)/i],[u,[c,we+" Mini"]],[/\bop(?:rg)?x\/([\w\.]+)/i],[u,[c,we+" GX"]],[/\bopr\/([\w\.]+)/i],[u,[c,we]],[/\bb[ai]*d(?:uhd|[ub]*[aekoprswx]{5,6})[\/ ]?([\w\.]+)/i],[u,[c,"Baidu"]],[/\b(?:mxbrowser|mxios|myie2)\/?([-\w\.]*)\b/i],[u,[c,"Maxthon"]],[/(kindle)\/([\w\.]+)/i,/(lunascape|maxthon|netfront|jasmine|blazer|sleipnir)[\/ ]?([\w\.]*)/i,/(avant|iemobile|slim(?:browser|boat|jet))[\/ ]?([\d\.]*)/i,/(?:ms|\()(ie) ([\w\.]+)/i,/(atlas|flock|rockmelt|midori|epiphany|silk|skyfire|ovibrowser|bolt|iron|vivaldi|iridium|phantomjs|bowser|qupzilla|falkon|rekonq|puffin|brave|whale(?!.+naver)|qqbrowserlite|duckduckgo|klar|helio|(?=comodo_)?dragon|otter|dooble|(?:lg |qute)browser|palemoon)\/([-\w\.]+)/i,/(heytap|ovi|115|surf|qwant)browser\/([\d\.]+)/i,/(qwant)(?:ios|mobile)\/([\d\.]+)/i,/(ecosia|weibo)(?:__| \w+@)([\d\.]+)/i],[c,u],[/quark(?:pc)?\/([-\w\.]+)/i],[u,[c,"Quark"]],[/\bddg\/([\w\.]+)/i],[u,[c,"DuckDuckGo"]],[/(?:\buc? ?browser|(?:juc.+)ucweb)[\/ ]?([\w\.]+)/i],[u,[c,"UCBrowser"]],[/microm.+\bqbcore\/([\w\.]+)/i,/\bqbcore\/([\w\.]+).+microm/i,/micromessenger\/([\w\.]+)/i],[u,[c,"WeChat"]],[/konqueror\/([\w\.]+)/i],[u,[c,"Konqueror"]],[/trident.+rv[: ]([\w\.]{1,9})\b.+like gecko/i],[u,[c,"IE"]],[/ya(?:search)?browser\/([\w\.]+)/i],[u,[c,"Yandex"]],[/slbrowser\/([\w\.]+)/i],[u,[c,"Smart "+Ve+me]],[/(avast|avg)\/([\w\.]+)/i],[[c,/(.+)/,"$1 Secure"+me],u],[/\bfocus\/([\w\.]+)/i],[u,[c,ge+" Focus"]],[/\bopt\/([\w\.]+)/i],[u,[c,we+" Touch"]],[/coc_coc\w+\/([\w\.]+)/i],[u,[c,"Coc Coc"]],[/dolfin\/([\w\.]+)/i],[u,[c,"Dolphin"]],[/coast\/([\w\.]+)/i],[u,[c,we+" Coast"]],[/miuibrowser\/([\w\.]+)/i],[u,[c,"MIUI"+me]],[/fxios\/([\w\.-]+)/i],[u,[c,ne+ge]],[/\bqihoobrowser\/?([\w\.]*)/i],[u,[c,"360"]],[/\b(qq)\/([\w\.]+)/i],[[c,/(.+)/,"$1Browser"],u],[/(oculus|sailfish|huawei|vivo|pico)browser\/([\w\.]+)/i],[[c,/(.+)/,"$1"+me],u],[/samsungbrowser\/([\w\.]+)/i],[u,[c,pe+" Internet"]],[/metasr[\/ ]?([\d\.]+)/i],[u,[c,St+" Explorer"]],[/(sogou)mo\w+\/([\d\.]+)/i],[[c,St+" Mobile"],u],[/(electron)\/([\w\.]+) safari/i,/(tesla)(?: qtcarbrowser|\/(20\d\d\.[-\w\.]+))/i,/m?(qqbrowser|2345(?=browser|chrome|explorer))\w*[\/ ]?v?([\w\.]+)/i],[c,u],[/(lbbrowser|rekonq|steam(?= (clie|tenf|gameo)))/i],[c],[/ome\/([\w\.]+) \w* ?(iron) saf/i,/ome\/([\w\.]+).+qihu (360)[es]e/i],[u,c],[/((?:fban\/fbios|fb_iab\/fb4a)(?!.+fbav)|;fbav\/([\w\.]+);)/i],[[c,Ge],u,[a,te]],[/(kakao(?:talk|story))[\/ ]([\w\.]+)/i,/(naver)\(.*?(\d+\.[\w\.]+).*\)/i,/(daum)apps[\/ ]([\w\.]+)/i,/safari (line)\/([\w\.]+)/i,/\b(line)\/([\w\.]+)\/iab/i,/(alipay)client\/([\w\.]+)/i,/(twitter)(?:and| f.+e\/([\w\.]+))/i,/(bing)(?:web|sapphire)\/([\w\.]+)/i,/(instagram|snapchat|klarna)[\/ ]([-\w\.]+)/i],[c,u,[a,te]],[/\bgsa\/([\w\.]+) .*safari\//i],[u,[c,"GSA"],[a,te]],[/musical_ly(?:.+app_?version\/|_)([\w\.]+)/i],[u,[c,"TikTok"],[a,te]],[/\[(linkedin)app\]/i],[c,[a,te]],[/(zalo(?:app)?)[\/\sa-z]*([\w\.-]+)/i],[[c,/(.+)/,"Zalo"],u,[a,te]],[/(chromium)[\/ ]([-\w\.]+)/i],[c,u],[/headlesschrome(?:\/([\w\.]+)| )/i],[u,[c,vt+" Headless"]],[/wv\).+chrome\/([\w\.]+).+edgw\//i],[u,[c,Te+" WebView2"]],[/ wv\).+(chrome)\/([\w\.]+)/i],[[c,vt+" WebView"],u],[/droid.+ version\/([\w\.]+)\b.+(?:mobile safari|safari)/i],[u,[c,"Android"+me]],[/chrome\/([\w\.]+) mobile/i],[u,[c,ne+"Chrome"]],[/(chrome|omniweb|arora|[tizenoka]{5} ?browser)\/v?([\w\.]+)/i],[c,u],[/version\/([\w\.\,]+) .*mobile(?:\/\w+ | ?)safari/i],[u,[c,ne+"Safari"]],[/iphone .*mobile(?:\/\w+ | ?)safari/i],[[c,ne+"Safari"]],[/version\/([\w\.\,]+) .*(safari)/i],[u,c],[/webkit.+?(mobile ?safari|safari)(\/[\w\.]+)/i],[c,[u,"1"]],[/(webkit|khtml)\/([\w\.]+)/i],[c,u],[/(?:mobile|tablet);.*(firefox)\/([\w\.-]+)/i],[[c,ne+ge],u],[/(navigator|netscape\d?)\/([-\w\.]+)/i],[[c,"Netscape"],u],[/(wolvic|librewolf)\/([\w\.]+)/i],[c,u],[/mobile vr; rv:([\w\.]+)\).+firefox/i],[u,[c,ge+" Reality"]],[/ekiohf.+(flow)\/([\w\.]+)/i,/(swiftfox)/i,/(icedragon|iceweasel|camino|chimera|fennec|maemo browser|minimo|conkeror)[\/ ]?([\w\.\+]+)/i,/(seamonkey|k-meleon|icecat|iceape|firebird|phoenix|basilisk|waterfox)\/([-\w\.]+)$/i,/(firefox)\/([\w\.]+)/i,/(mozilla)\/([\w\.]+(?= .+rv\:.+gecko\/\d+)|[0-4][\w\.]+(?!.+compatible))/i,/(amaya|dillo|doris|icab|ladybird|lynx|mosaic|netsurf|obigo|polaris|w3m|(?:go|ice|up)[\. ]?browser)[-\/ ]?v?([\w\.]+)/i,/\b(links) \(([\w\.]+)/i],[c,[u,/_/g,"."]],[/(cobalt)\/([\w\.]+)/i],[c,[u,/[^\d\.]+./,Z]]],cpu:[[/\b((amd|x|x86[-_]?|wow|win)64)\b/i],[[E,"amd64"]],[/(ia32(?=;))/i,/\b((i[346]|x)86)(pc)?\b/i],[[E,"ia32"]],[/\b(aarch64|arm(v?[89]e?l?|_?64))\b/i],[[E,"arm64"]],[/\b(arm(v[67])?ht?n?[fl]p?)\b/i],[[E,"armhf"]],[/( (ce|mobile); ppc;|\/[\w\.]+arm\b)/i],[[E,"arm"]],[/ sun4\w[;\)]/i],[[E,"sparc"]],[/\b(avr32|ia64(?=;)|68k(?=\))|\barm(?=v([1-7]|[5-7]1)l?|;|eabi)|(irix|mips|sparc)(64)?\b|pa-risc)/i,/((ppc|powerpc)(64)?)( mac|;|\))/i,/(?:osf1|[freopnt]{3,4}bsd) (alpha)/i],[[E,/ower/,Z,j]],[/mc680.0/i],[[E,"68k"]],[/winnt.+\[axp/i],[[E,"alpha"]]],device:[[/\b(sch-i[89]0\d|shw-m380s|sm-[ptx]\w{2,4}|gt-[pn]\d{2,4}|sgh-t8[56]9|nexus 10)/i],[l,[d,pe],[a,v]],[/\b((?:s[cgp]h|gt|sm)-(?![lr])\w+|sc[g-]?[\d]+a?|galaxy nexus)/i,/samsung[- ]((?!sm-[lr]|browser)[-\w]+)/i,/sec-(sgh\w+)/i],[l,[d,pe],[a,w]],[/(?:\/|\()(ip(?:hone|od)[\w, ]*)[\/\);]/i],[l,[d,re],[a,w]],[/\b(?:ios|apple\w+)\/.+[\(\/](ipad)/i,/\b(ipad)[\d,]*[;\] ].+(mac |i(pad)?)os/i],[l,[d,re],[a,v]],[/(macintosh);/i],[l,[d,re]],[/\b(sh-?[altvz]?\d\d[a-ekm]?)/i],[l,[d,xt],[a,w]],[/\b((?:brt|eln|hey2?|gdi|jdn)-a?[lnw]09|(?:ag[rm]3?|jdn2|kob2)-a?[lw]0[09]hn)(?: bui|\)|;)/i],[l,[d,wt],[a,v]],[/honor([-\w ]+)[;\)]/i],[l,[d,wt],[a,w]],[/\b((?:ag[rs][2356]?k?|bah[234]?|bg[2o]|bt[kv]|cmr|cpn|db[ry]2?|jdn2|got|kob2?k?|mon|pce|scm|sht?|[tw]gr|vrd)-[ad]?[lw][0125][09]b?|605hw|bg2-u03|(?:gem|fdr|m2|ple|t1)-[7a]0[1-4][lu]|t1-a2[13][lw]|mediapad[\w\. ]*(?= bui|\)))\b(?!.+d\/s)/i],[l,[d,gt],[a,v]],[/(?:huawei) ?([-\w ]+)[;\)]/i,/\b(nexus 6p|\w{2,4}e?-[atu]?[ln][\dx][\dc][adnt]?)\b(?!.+d\/s)/i],[l,[d,gt],[a,w]],[/oid[^\)]+; (2[\dbc]{4}(182|283|rp\w{2})[cgl]|m2105k81a?c)(?: bui|\))/i,/\b(?:xiao)?((?:red)?mi[-_ ]?pad[\w- ]*)(?: bui|\))/i],[[l,/_/g," "],[d,je],[a,v]],[/\b; (\w+) build\/hm\1/i,/\b(hm[-_ ]?note?[_ ]?(?:\d\w)?) bui/i,/oid[^\)]+; (redmi[\-_ ]?(?:note|k)?[\w_ ]+|m?[12]\d[01]\d\w{3,6}|poco[\w ]+|(shark )?\w{3}-[ah]0|qin ?[1-3](s\+|ultra| pro)?)( bui|; wv|\))/i,/\b(mi[-_ ]?(?:a\d|one|one[_ ]plus|note|max|cc)?[_ ]?(?:\d{0,2}\w?)[_ ]?(?:plus|se|lite|pro)?( 5g|lte)?)(?: bui|\))/i,/ ([\w ]+) miui\/v?\d/i],[[l,/_/g," "],[d,je],[a,w]],[/droid.+; (cph2[3-6]\d[13579]|((gm|hd)19|(ac|be|in|kb)20|(d[en]|eb|le|mt)21|ne22)[0-2]\d|p[g-k]\w[1m]10)\b/i,/(?:one)?(?:plus)? (a\d0\d\d)(?: b|\))/i],[l,[d,yt],[a,w]],[/; (\w+) bui.+ oppo/i,/\b(cph[12]\d{3}|p(?:af|c[al]|d\w|e[ar])[mt]\d0|x9007|a101op)\b/i],[l,[d,Re],[a,w]],[/\b(opd2(\d{3}a?))(?: bui|\))/i],[l,[d,L,{OnePlus:["203","304","403","404","413","415"],"*":Re}],[a,v]],[/(vivo (5r?|6|8l?|go|one|s|x[il]?[2-4]?)[\w\+ ]*)(?: bui|\))/i],[l,[d,"BLU"],[a,w]],[/; vivo (\w+)(?: bui|\))/i,/\b(v[12]\d{3}\w?[at])(?: bui|;)/i],[l,[d,"Vivo"],[a,w]],[/\b(rmx[1-3]\d{3})(?: bui|;|\))/i],[l,[d,"Realme"],[a,w]],[/(ideatab[-\w ]+|602lv|d-42a|a101lv|a2109a|a3500-hv|s[56]000|pb-6505[my]|tb-?x?\d{3,4}(?:f[cu]|xu|[av])|yt\d?-[jx]?\d+[lfmx])( bui|;|\)|\/)/i,/lenovo ?(b[68]0[08]0-?[hf]?|tab(?:[\w- ]+?)|tb[\w-]{6,7})( bui|;|\)|\/)/i],[l,[d,Ve],[a,v]],[/lenovo[-_ ]?([-\w ]+?)(?: bui|\)|\/)/i],[l,[d,Ve],[a,w]],[/\b(milestone|droid(?:[2-4x]| (?:bionic|x2|pro|razr))?:?( 4g)?)\b[\w ]+build\//i,/\bmot(?:orola)?[- ]([\w\s]+)(\)| bui)/i,/((?:moto(?! 360)[-\w\(\) ]+|xt\d{3,4}[cgkosw\+]?[-\d]*|nexus 6)(?= bui|\)))/i],[l,[d,qe],[a,w]],[/\b(mz60\d|xoom[2 ]{0,2}) build\//i],[l,[d,qe],[a,v]],[/((?=lg)?[vl]k\-?\d{3}) bui| 3\.[-\w; ]{10}lg?-([06cv9]{3,4})/i],[l,[d,Ie],[a,v]],[/(lm(?:-?f100[nv]?|-[\w\.]+)(?= bui|\))|nexus [45])/i,/\blg[-e;\/ ]+(?!.*(?:browser|netcast|android tv|watch|webos))(\w+)/i,/\blg-?([\d\w]+) bui/i],[l,[d,Ie],[a,w]],[/(nokia) (t[12][01])/i],[d,l,[a,v]],[/(?:maemo|nokia).*(n900|lumia \d+|rm-\d+)/i,/nokia[-_ ]?(([-\w\. ]*?))( bui|\)|;|\/)/i],[[l,/_/g," "],[a,w],[d,"Nokia"]],[/(pixel (c|tablet))\b/i],[l,[d,K],[a,v]],[/droid.+;(?: google)? (g(01[13]a|020[aem]|025[jn]|1b60|1f8f|2ybb|4s1m|576d|5nz6|8hhn|8vou|a02099|c15s|d1yq|e2ae|ec77|gh2x|kv4x|p4bc|pj41|r83y|tt9q|ur25|wvk6)|pixel[\d ]*a?( pro)?( xl)?( fold)?( \(5g\))?)( bui|\))/i],[l,[d,K],[a,w]],[/(google) (pixelbook( go)?)/i],[d,l],[/droid.+; (a?\d[0-2]{2}so|[c-g]\d{4}|so[-gl]\w+|xq-\w\w\d\d)(?= bui|\).+chrome\/(?![1-6]{0,1}\d\.))/i],[l,[d,be],[a,w]],[/sony tablet [ps]/i,/\b(?:sony)?sgp\w+(?: bui|\))/i],[[l,"Xperia Tablet"],[d,be],[a,v]],[/(alexa)webm/i,/(kf[a-z]{2}wi|aeo(?!bc)\w\w)( bui|\))/i,/(kf[a-z]+)( bui|\)).+silk\//i],[l,[d,Ee],[a,v]],[/((?:sd|kf)[0349hijorstuw]+)( bui|\)).+silk\//i],[[l,/(.+)/g,"Fire Phone $1"],[d,Ee],[a,w]],[/(playbook);[-\w\),; ]+(rim)/i],[l,d,[a,v]],[/\b((?:bb[a-f]|st[hv])100-\d)/i,/(?:blackberry|\(bb10;) (\w+)/i],[l,[d,bt],[a,w]],[/(?:\b|asus_)(transfo[prime ]{4,10} \w+|eeepc|slider \w+|nexus 7|padfone|p00[cj])/i],[l,[d,pt],[a,v]],[/ (z[bes]6[027][012][km][ls]|zenfone \d\w?)\b/i],[l,[d,pt],[a,w]],[/(nexus 9)/i],[l,[d,"HTC"],[a,v]],[/(htc)[-;_ ]{1,2}([\w ]+(?=\)| bui)|\w+)/i,/(zte)[- ]([\w ]+?)(?: bui|\/|\))/i,/(alcatel|geeksphone|nexian|panasonic(?!(?:;|\.))|sony(?!-bra))[-_ ]?([-\w]*)/i],[d,[l,/_/g," "],[a,w]],[/tcl (xess p17aa)/i,/droid [\w\.]+; ((?:8[14]9[16]|9(?:0(?:48|60|8[01])|1(?:3[27]|66)|2(?:6[69]|9[56])|466))[gqswx])(_\w(\w|\w\w))?(\)| bui)/i],[l,[d,"TCL"],[a,v]],[/droid [\w\.]+; (418(?:7d|8v)|5087z|5102l|61(?:02[dh]|25[adfh]|27[ai]|56[dh]|59k|65[ah])|a509dl|t(?:43(?:0w|1[adepqu])|50(?:6d|7[adju])|6(?:09dl|10k|12b|71[efho]|76[hjk])|7(?:66[ahju]|67[hw]|7[045][bh]|71[hk]|73o|76[ho]|79w|81[hks]?|82h|90[bhsy]|99b)|810[hs]))(_\w(\w|\w\w))?(\)| bui)/i],[l,[d,"TCL"],[a,w]],[/(itel) ((\w+))/i],[[d,j],l,[a,L,{tablet:["p10001l","w7001"],"*":"mobile"}]],[/droid.+; ([ab][1-7]-?[0178a]\d\d?)/i],[l,[d,"Acer"],[a,v]],[/droid.+; (m[1-5] note) bui/i,/\bmz-([-\w]{2,})/i],[l,[d,"Meizu"],[a,w]],[/; ((?:power )?armor(?:[\w ]{0,8}))(?: bui|\))/i],[l,[d,"Ulefone"],[a,w]],[/; (energy ?\w+)(?: bui|\))/i,/; energizer ([\w ]+)(?: bui|\))/i],[l,[d,"Energizer"],[a,w]],[/; cat (b35);/i,/; (b15q?|s22 flip|s48c|s62 pro)(?: bui|\))/i],[l,[d,"Cat"],[a,w]],[/((?:new )?andromax[\w- ]+)(?: bui|\))/i],[l,[d,"Smartfren"],[a,w]],[/droid.+; (a(in)?(0(15|59|6[35])|142)p?)/i],[l,[d,"Nothing"],[a,w]],[/; (x67 5g|tikeasy \w+|ac[1789]\d\w+)( b|\))/i,/archos ?(5|gamepad2?|([\w ]*[t1789]|hello) ?\d+[\w ]*)( b|\))/i],[l,[d,"Archos"],[a,v]],[/archos ([\w ]+)( b|\))/i,/; (ac[3-6]\d\w{2,8})( b|\))/i],[l,[d,"Archos"],[a,w]],[/; (n159v)/i],[l,[d,"HMD"],[a,w]],[/(imo) (tab \w+)/i,/(infinix|tecno) (x1101b?|p904|dp(7c|8d|10a)( pro)?|p70[1-3]a?|p904|t1101)/i],[d,l,[a,v]],[/(blackberry|benq|palm(?=\-)|sonyericsson|acer|asus(?! zenw)|dell|jolla|meizu|motorola|polytron|tecno|micromax|advan)[-_ ]?([-\w]*)/i,/; (blu|hmd|imo|infinix|lava|oneplus|tcl|wiko)[_ ]([\w\+ ]+?)(?: bui|\)|; r)/i,/(hp) ([\w ]+\w)/i,/(microsoft); (lumia[\w ]+)/i,/(oppo) ?([\w ]+) bui/i,/(hisense) ([ehv][\w ]+)\)/i,/droid[^;]+; (philips)[_ ]([sv-x][\d]{3,4}[xz]?)/i],[d,l,[a,w]],[/(kobo)\s(ereader|touch)/i,/(hp).+(touchpad(?!.+tablet)|tablet)/i,/(kindle)\/([\w\.]+)/i],[d,l,[a,v]],[/(surface duo)/i],[l,[d,We],[a,v]],[/droid [\d\.]+; (fp\du?)(?: b|\))/i],[l,[d,"Fairphone"],[a,w]],[/((?:tegranote|shield t(?!.+d tv))[\w- ]*?)(?: b|\))/i],[l,[d,mt],[a,v]],[/(sprint) (\w+)/i],[d,l,[a,w]],[/(kin\.[onetw]{3})/i],[[l,/\./g," "],[d,We],[a,w]],[/droid.+; ([c6]+|et5[16]|mc[239][23]x?|vc8[03]x?)\)/i],[l,[d,Ne],[a,v]],[/droid.+; (ec30|ps20|tc[2-8]\d[kx])\)/i],[l,[d,Ne],[a,w]],[/(philips)[\w ]+tv/i,/smart-tv.+(samsung)/i],[d,[a,C]],[/hbbtv.+maple;(\d+)/i],[[l,/^/,"SmartTV"],[d,pe],[a,C]],[/(vizio)(?: |.+model\/)(\w+-\w+)/i,/tcast.+(lg)e?. ([-\w]+)/i],[d,l,[a,C]],[/(nux; netcast.+smarttv|lg (netcast\.tv-201\d|android tv))/i],[[d,Ie],[a,C]],[/(apple) ?tv/i],[d,[l,re+" TV"],[a,C]],[/crkey.*devicetype\/chromecast/i],[[l,R+" Third Generation"],[d,K],[a,C]],[/crkey.*devicetype\/([^/]*)/i],[[l,/^/,"Chromecast "],[d,K],[a,C]],[/fuchsia.*crkey/i],[[l,R+" Nest Hub"],[d,K],[a,C]],[/crkey/i],[[l,R],[d,K],[a,C]],[/(portaltv)/i],[l,[d,Ge],[a,C]],[/droid.+aft(\w+)( bui|\))/i],[l,[d,Ee],[a,C]],[/(shield \w+ tv)/i],[l,[d,mt],[a,C]],[/\(dtv[\);].+(aquos)/i,/(aquos-tv[\w ]+)\)/i],[l,[d,xt],[a,C]],[/(bravia[\w ]+)( bui|\))/i],[l,[d,be],[a,C]],[/(mi(tv|box)-?\w+) bui/i],[l,[d,je],[a,C]],[/Hbbtv.*(technisat) (.*);/i],[d,l,[a,C]],[/\b(roku)[\dx]*[\)\/]((?:dvp-)?[\d\.]*)/i,/hbbtv\/\d+\.\d+\.\d+ +\([\w\+ ]*; *([\w\d][^;]*);([^;]*)/i],[[d,/.+\/(\w+)/,"$1",L,{LG:"lge"}],[l,Ae],[a,C]],[/(playstation \w+)/i],[l,[d,be],[a,ke]],[/\b(xbox(?: one)?(?!; xbox))[\); ]/i],[l,[d,We],[a,ke]],[/(ouya)/i,/(nintendo) (\w+)/i,/(retroid) (pocket ([^\)]+))/i,/(valve).+(steam deck)/i,/droid.+; ((shield|rgcube|gr0006))( bui|\))/i],[[d,L,{Nvidia:"Shield",Anbernic:"RGCUBE",Logitech:"GR0006"}],l,[a,ke]],[/\b(sm-[lr]\d\d[0156][fnuw]?s?|gear live)\b/i],[l,[d,pe],[a,U]],[/((pebble))app/i,/(asus|google|lg|oppo|xiaomi) ((pixel |zen)?watch[\w ]*)( bui|\))/i],[d,l,[a,U]],[/(ow(?:19|20)?we?[1-3]{1,3})/i],[l,[d,Re],[a,U]],[/(watch)(?: ?os[,\/]|\d,\d\/)[\d\.]+/i],[l,[d,re],[a,U]],[/(opwwe\d{3})/i],[l,[d,yt],[a,U]],[/(moto 360)/i],[l,[d,qe],[a,U]],[/(smartwatch 3)/i],[l,[d,be],[a,U]],[/(g watch r)/i],[l,[d,Ie],[a,U]],[/droid.+; (wt63?0{2,3})\)/i],[l,[d,Ne],[a,U]],[/droid.+; (glass) \d/i],[l,[d,K],[a,Se]],[/(pico) ([\w ]+) os\d/i],[d,l,[a,Se]],[/(quest( \d| pro)?s?).+vr/i],[l,[d,Ge],[a,Se]],[/mobile vr; rv.+firefox/i],[[a,Se]],[/(tesla)(?: qtcarbrowser|\/[-\w\.]+)/i],[d,[a,fe]],[/(aeobc)\b/i],[l,[d,Ee],[a,fe]],[/(homepod).+mac os/i],[l,[d,re],[a,fe]],[/windows iot/i],[[a,fe]],[/droid.+; ([\w- ]+) (4k|android|smart|google)[- ]?tv/i],[l,[a,C]],[/\b((4k|android|smart|opera)[- ]?tv|tv; rv:|large screen[\w ]+safari)\b/i],[[a,C]],[/droid .+?; ([^;]+?)(?: bui|; wv\)|\) applew|; hmsc).+?(mobile|vr|\d) safari/i],[l,[a,L,{mobile:"Mobile",xr:"VR","*":v}]],[/\b((tablet|tab)[;\/]|focus\/\d(?!.+mobile))/i],[[a,v]],[/(phone|mobile(?:[;\/]| [ \w\/\.]*safari)|pda(?=.+windows ce))/i],[[a,w]],[/droid .+?; ([\w\. -]+)( bui|\))/i],[l,[d,"Generic"]]],engine:[[/windows.+ edge\/([\w\.]+)/i],[u,[c,Te+"HTML"]],[/(arkweb)\/([\w\.]+)/i],[c,u],[/webkit\/537\.36.+chrome\/(?!27)([\w\.]+)/i],[u,[c,"Blink"]],[/(presto)\/([\w\.]+)/i,/(webkit|trident|netfront|netsurf|amaya|lynx|w3m|goanna|servo)\/([\w\.]+)/i,/ekioh(flow)\/([\w\.]+)/i,/(khtml|tasman|links)[\/ ]\(?([\w\.]+)/i,/(icab)[\/ ]([23]\.[\d\.]+)/i,/\b(libweb)/i],[c,u],[/ladybird\//i],[[c,"LibWeb"]],[/rv\:([\w\.]{1,9})\b.+(gecko)/i],[u,c]],os:[[/(windows nt) (6\.[23]); arm/i],[[c,/N/,"R"],[u,L,Ct]],[/(windows (?:phone|mobile|iot))(?: os)?[\/ ]?([\d\.]*( se)?)/i,/(windows)[\/ ](1[01]|2000|3\.1|7|8(\.1)?|9[58]|me|server 20\d\d( r2)?|vista|xp)/i],[c,u],[/windows nt ?([\d\.\)]*)(?!.+xbox)/i,/\bwin(?=3| ?9|n)(?:nt| 9x )?([\d\.;]*)/i],[[u,/(;|\))/g,"",L,Ct],[c,Xe]],[/(windows ce)\/?([\d\.]*)/i],[c,u],[/[adehimnop]{4,7}\b(?:.*os ([\w]+) like mac|; opera)/i,/(?:ios;fbsv|ios(?=.+ip(?:ad|hone)|.+apple ?tv)|ip(?:ad|hone)(?: |.+i(?:pad)?)os|apple ?tv.+ios)[\/ ]([\w\.]+)/i,/\btvos ?([\w\.]+)/i,/cfnetwork\/.+darwin/i],[[u,/_/g,"."],[c,"iOS"]],[/(mac os x) ?([\w\. ]*)/i,/(macintosh|mac_powerpc\b)(?!.+(haiku|morphos))/i],[[c,"macOS"],[u,/_/g,"."]],[/android ([\d\.]+).*crkey/i],[u,[c,R+" Android"]],[/fuchsia.*crkey\/([\d\.]+)/i],[u,[c,R+" Fuchsia"]],[/crkey\/([\d\.]+).*devicetype\/smartspeaker/i],[u,[c,R+" SmartSpeaker"]],[/linux.*crkey\/([\d\.]+)/i],[u,[c,R+" Linux"]],[/crkey\/([\d\.]+)/i],[u,[c,R]],[/droid ([\w\.]+)\b.+(android[- ]x86)/i],[u,c],[/(ubuntu) ([\w\.]+) like android/i],[[c,/(.+)/,"$1 Touch"],u],[/(harmonyos)[\/ ]?([\d\.]*)/i,/(android|bada|blackberry|kaios|maemo|meego|openharmony|qnx|rim tablet os|sailfish|series40|symbian|tizen)\w*[-\/\.; ]?([\d\.]*)/i],[c,u],[/\(bb(10);/i],[u,[c,bt]],[/(?:symbian ?os|symbos|s60(?=;)|series ?60)[-\/ ]?([\w\.]*)/i],[u,[c,"Symbian"]],[/mozilla\/[\d\.]+ \((?:mobile|tablet|tv|mobile; [\w ]+); rv:.+ gecko\/([\w\.]+)/i],[u,[c,ge+" OS"]],[/\b(?:hp)?wos(?:browser)?\/([\w\.]+)/i,/webos(?:[ \/]?|\.tv-20(?=2[2-9]))(\d[\d\.]*)/i],[u,[c,"webOS"]],[/web0s;.+?(?:chr[o0]me|safari)\/(\d+)/i],[[u,L,{25:"120",24:"108",23:"94",22:"87",6:"79",5:"68",4:"53",3:"38",2:"538",1:"537","*":"TV"}],[c,"webOS"]],[/watch(?: ?os[,\/]|\d,\d\/)([\d\.]+)/i],[u,[c,"watchOS"]],[/(cros) [\w]+(?:\)| ([\w\.]+)\b)/i],[[c,"Chrome OS"],u],[/panasonic;(viera)/i,/(netrange)mmh/i,/(nettv)\/(\d+\.[\w\.]+)/i,/(nintendo|playstation) (\w+)/i,/(xbox); +xbox ([^\);]+)/i,/(pico) .+os([\w\.]+)/i,/\b(joli|palm)\b ?(?:os)?\/?([\w\.]*)/i,/linux.+(mint)[\/\(\) ]?([\w\.]*)/i,/(mageia|vectorlinux|fuchsia|arcaos|arch(?= ?linux))[;l ]([\d\.]*)/i,/([kxln]?ubuntu|debian|suse|opensuse|gentoo|slackware|fedora|mandriva|centos|pclinuxos|red ?hat|zenwalk|linpus|raspbian|plan 9|minix|risc os|contiki|deepin|manjaro|elementary os|sabayon|linspire|knoppix)(?: gnu[\/ ]linux)?(?: enterprise)?(?:[- ]linux)?(?:-gnu)?[-\/ ]?(?!chrom|package)([-\w\.]*)/i,/((?:open)?solaris)[-\/ ]?([\w\.]*)/i,/\b(aix)[; ]([1-9\.]{0,4})/i,/(hurd|linux|morphos)(?: (?:arm|x86|ppc)\w*| ?)([\w\.]*)/i,/(gnu) ?([\w\.]*)/i,/\b([-frentopcghs]{0,5}bsd|dragonfly)[\/ ]?(?!amd|[ix346]{1,2}86)([\w\.]*)/i,/(haiku) ?(r\d)?/i],[c,u],[/(sunos) ?([\d\.]*)/i],[[c,"Solaris"],u],[/\b(beos|os\/2|amigaos|openvms|hp-ux|serenityos)/i,/(unix) ?([\w\.]*)/i],[c,u]]},Fe=(function(){var e={init:{},isIgnore:{},isIgnoreRgx:{},toString:{}};return B.call(e.init,[[I,[c,u,he,a]],[$,[E]],[H,[a,l,d]],[P,[c,u]],[A,[c,u]]]),B.call(e.isIgnore,[[I,[u,he]],[P,[u]],[A,[u]]]),B.call(e.isIgnoreRgx,[[I,/ ?browser$/i],[A,/ ?os$/i]]),B.call(e.toString,[[I,[c,u]],[$,[E]],[H,[d,l]],[P,[c,u]],[A,[c,u]]]),e})(),pi=function(e,t){var i=Fe.init[t],r=Fe.isIgnore[t]||0,o=Fe.isIgnoreRgx[t]||0,s=Fe.toString[t]||0;function n(){B.call(this,i)}return n.prototype.getItem=function(){return e},n.prototype.withClientHints=function(){return Q?Q.getHighEntropyValues(ft).then(function(h){return e.setCH(new Tt(h,!1)).parseCH().get()}):e.parseCH().get()},n.prototype.withFeatureCheck=function(){return e.detectFeature().get()},t!=ee&&(n.prototype.is=function(h){var f=!1;for(var g in this)if(this.hasOwnProperty(g)&&!Ye(r,g)&&j(o?oe(o,this[g]):this[g])==j(o?oe(o,h):h)){if(f=!0,h!=k.UNDEFINED)break}else if(h==k.UNDEFINED&&f){f=!f;break}return f},n.prototype.toString=function(){var h=Z;for(var f in s)typeof this[s[f]]!==k.UNDEFINED&&(h+=(h?" ":Z)+this[s[f]]);return h||k.UNDEFINED}),n.prototype.then=function(h){var f=this,g=function(){for(var y in f)f.hasOwnProperty(y)&&(this[y]=f[y])};g.prototype={is:n.prototype.is,toString:n.prototype.toString,withClientHints:n.prototype.withClientHints,withFeatureCheck:n.prototype.withFeatureCheck};var m=new g;return h(m),m},new n};function Tt(e,t){if(e=e||{},B.call(this,ft),t)B.call(this,[[ze,Ke(e[q])],[$e,Ke(e[ni])],[w,/\?1/.test(e[li])],[l,xe(e[ci])],[ie,xe(e[ht])],[Be,xe(e[di])],[E,xe(e[oi])],[Y,Ke(e[ai])],[Ce,xe(e[si])]]);else for(var i in e)this.hasOwnProperty(i)&&typeof e[i]!==k.UNDEFINED&&(this[i]=e[i])}function N(e,t,i,r){return B.call(this,[["itemType",e],["ua",t],["uaCH",r],["rgxMap",i],["data",pi(this,e)]]),this}N.prototype.get=function(e){return e?this.data.hasOwnProperty(e)?this.data[e]:void 0:this.data},N.prototype.set=function(e,t){return this.data[e]=t,this},N.prototype.setCH=function(e){return this.uaCH=e,this},N.prototype.detectFeature=function(){if(T&&T.userAgent==this.ua)switch(this.itemType){case I:T.brave&&typeof T.brave.isBrave==k.FUNCTION&&this.set(c,"Brave");break;case H:!this.get(a)&&Q&&Q[w]&&this.set(a,w),this.get(l)=="Macintosh"&&T&&typeof T.standalone!==k.UNDEFINED&&T.maxTouchPoints&&T.maxTouchPoints>2&&this.set(l,"iPad").set(a,v);break;case A:!this.get(c)&&Q&&Q[ie]&&this.set(c,Q[ie]);break;case ee:var e=this.data,t=function(i){return e[i].getItem().detectFeature().get()};this.set(I,t(I)).set($,t($)).set(H,t(H)).set(P,t(P)).set(A,t(A))}return this},N.prototype.parseUA=function(){switch(this.itemType!=ee&&Je.call(this.data,this.ua,this.rgxMap),this.itemType){case I:this.set(he,Qe(this.get(u)));break;case A:if(this.get(c)=="iOS"&&this.get(u)=="18.6"){var e=/\) Version\/([\d\.]+)/.exec(this.ua);e&&parseInt(e[1].substring(0,2),10)>=26&&this.set(u,e[1])}break}return this},N.prototype.parseCH=function(){var e=this.uaCH,t=this.rgxMap;switch(this.itemType){case I:case P:var i=e[$e]||e[ze],r;if(i)for(var o=0;o<i.length;o++){var s=i[o].brand||i[o],n=i[o].version;this.itemType==I&&!/not.a.brand/i.test(s)&&(!r||/Chrom/.test(r)&&s!=kt||r==Te&&/WebView2/.test(s))&&(s=L(s,fi),r=this.get(c),r&&!/Chrom/.test(r)&&/Chrom/.test(s)||this.set(c,s).set(u,n).set(he,Qe(n)),r=s),this.itemType==P&&s==kt&&this.set(u,n)}break;case $:var h=e[E];h&&(h&&e[Ce]=="64"&&(h+="64"),Je.call(this.data,h+";",t));break;case H:if(e[w]&&this.set(a,w),e[l]&&(this.set(l,e[l]),!this.get(a)||!this.get(d))){var f={};Je.call(f,"droid 9; "+e[l]+")",t),!this.get(a)&&f.type&&this.set(a,f.type),!this.get(d)&&f.vendor&&this.set(d,f.vendor)}if(e[Y]){var g;if(typeof e[Y]!="string")for(var m=0;!g&&m<e[Y].length;)g=L(e[Y][m++],Et);else g=L(e[Y],Et);this.set(a,g)}break;case A:var y=e[ie];if(y){var M=e[Be];y==Xe&&(M=parseInt(Qe(M),10)>=13?"11":"10"),this.set(c,y).set(u,M)}this.get(c)==Xe&&e[l]=="Xbox"&&this.set(c,"Xbox").set(u,void 0);break;case ee:var X=this.data,_=function(De){return X[De].getItem().setCH(e).parseCH().get()};this.set(I,_(I)).set($,_($)).set(H,_(H)).set(P,_(P)).set(A,_(A))}return this};function V(e,t,i){if(typeof e===k.OBJECT?(Me(e,!0)?(typeof t===k.OBJECT&&(i=t),t=e):(i=e,t=void 0),e=void 0):typeof e===k.STRING&&!Me(t,!0)&&(i=t,t=void 0),i)if(typeof i.append===k.FUNCTION){var r={};i.forEach(function(m,y){r[String(y).toLowerCase()]=m}),i=r}else{var o={};for(var s in i)i.hasOwnProperty(s)&&(o[String(s).toLowerCase()]=i[s]);i=o}if(!(this instanceof V))return new V(e,t,i).getResult();var n=typeof e===k.STRING?e:i&&i[dt]?i[dt]:T&&T.userAgent?T.userAgent:Z,h=new Tt(i,!0),f=t?hi(It,t):It,g=function(m){return m==ee?function(){return new N(m,n,f,h).set("ua",n).set(I,this.getBrowser()).set($,this.getCPU()).set(H,this.getDevice()).set(P,this.getEngine()).set(A,this.getOS()).get()}:function(){return new N(m,n,f[m],h).parseUA().get()}};return B.call(this,[["getBrowser",g(I)],["getCPU",g($)],["getDevice",g(H)],["getEngine",g(P)],["getOS",g(A)],["getResult",g(ee)],["getUA",function(){return n}],["setUA",function(m){return ye(m)&&(n=Ae(m,ri)),this}]]).setUA(n),this}V.VERSION=ii,V.BROWSER=Oe([c,u,he,a]),V.CPU=Oe([E]),V.DEVICE=Oe([l,d,a,ke,w,C,v,U,fe]),V.ENGINE=V.OS=Oe([c,u]);const bi=()=>{const t=new V().getResult();return{os:t.os.name||"unknown",osVersion:t.os.version||"unknown",browser:t.browser.name||"unknown",browserVersion:t.browser.version||"unknown",deviceType:t.device.type||"desktop"}};function gi(e,t){if(e.match(/^[a-z]+:\/\//i))return e;if(e.match(/^\/\//))return window.location.protocol+e;if(e.match(/^[a-z]+:/i))return e;const i=document.implementation.createHTMLDocument(),r=i.createElement("base"),o=i.createElement("a");return i.head.appendChild(r),i.body.appendChild(o),t&&(r.href=t),o.href=e,o.href}const wi=(()=>{let e=0;const t=()=>`0000${(Math.random()*36**4<<0).toString(36)}`.slice(-4);return()=>(e+=1,`u${t()}${e}`)})();function G(e){const t=[];for(let i=0,r=e.length;i<r;i++)t.push(e[i]);return t}let se=null;function Ot(e={}){return se||(e.includeStyleProperties?(se=e.includeStyleProperties,se):(se=G(window.getComputedStyle(document.documentElement)),se))}function _e(e,t){const r=(e.ownerDocument.defaultView||window).getComputedStyle(e).getPropertyValue(t);return r?parseFloat(r.replace("px","")):0}function mi(e){const t=_e(e,"border-left-width"),i=_e(e,"border-right-width");return e.clientWidth+t+i}function yi(e){const t=_e(e,"border-top-width"),i=_e(e,"border-bottom-width");return e.clientHeight+t+i}function Mt(e,t={}){const i=t.width||mi(e),r=t.height||yi(e);return{width:i,height:r}}function xi(){let e,t;try{t=process}catch{}const i=t&&t.env?t.env.devicePixelRatio:null;return i&&(e=parseInt(i,10),Number.isNaN(e)&&(e=1)),e||window.devicePixelRatio||1}const F=16384;function vi(e){(e.width>F||e.height>F)&&(e.width>F&&e.height>F?e.width>e.height?(e.height*=F/e.width,e.width=F):(e.width*=F/e.height,e.height=F):e.width>F?(e.height*=F/e.width,e.width=F):(e.width*=F/e.height,e.height=F))}function Pe(e){return new Promise((t,i)=>{const r=new Image;r.onload=()=>{r.decode().then(()=>{requestAnimationFrame(()=>t(r))})},r.onerror=i,r.crossOrigin="anonymous",r.decoding="async",r.src=e})}async function ki(e){return Promise.resolve().then(()=>new XMLSerializer().serializeToString(e)).then(encodeURIComponent).then(t=>`data:image/svg+xml;charset=utf-8,${t}`)}async function Si(e,t,i){const r="http://www.w3.org/2000/svg",o=document.createElementNS(r,"svg"),s=document.createElementNS(r,"foreignObject");return o.setAttribute("width",`${t}`),o.setAttribute("height",`${i}`),o.setAttribute("viewBox",`0 0 ${t} ${i}`),s.setAttribute("width","100%"),s.setAttribute("height","100%"),s.setAttribute("x","0"),s.setAttribute("y","0"),s.setAttribute("externalResourcesRequired","true"),o.appendChild(s),s.appendChild(e),ki(o)}const O=(e,t)=>{if(e instanceof t)return!0;const i=Object.getPrototypeOf(e);return i===null?!1:i.constructor.name===t.name||O(i,t)};function Ci(e){const t=e.getPropertyValue("content");return`${e.cssText} content: '${t.replace(/'|"/g,"")}';`}function Ei(e,t){return Ot(t).map(i=>{const r=e.getPropertyValue(i),o=e.getPropertyPriority(i);return`${i}: ${r}${o?" !important":""};`}).join(" ")}function Ii(e,t,i,r){const o=`.${e}:${t}`,s=i.cssText?Ci(i):Ei(i,r);return document.createTextNode(`${o}{${s}}`)}function At(e,t,i,r){const o=window.getComputedStyle(e,i),s=o.getPropertyValue("content");if(s===""||s==="none")return;const n=wi();try{t.className=`${t.className} ${n}`}catch{return}const h=document.createElement("style");h.appendChild(Ii(n,i,o,r)),t.appendChild(h)}function Ti(e,t,i){At(e,t,":before",i),At(e,t,":after",i)}const Ft="application/font-woff",_t="image/jpeg",Oi={woff:Ft,woff2:Ft,ttf:"application/font-truetype",eot:"application/vnd.ms-fontobject",png:"image/png",jpg:_t,jpeg:_t,gif:"image/gif",tiff:"image/tiff",svg:"image/svg+xml",webp:"image/webp"};function Mi(e){const t=/\.([^./]*?)$/g.exec(e);return t?t[1]:""}function Ze(e){const t=Mi(e).toLowerCase();return Oi[t]||""}function Ai(e){return e.split(/,/)[1]}function et(e){return e.search(/^(data:)/)!==-1}function Fi(e,t){return`data:${t};base64,${e}`}async function Pt(e,t,i){const r=await fetch(e,t);if(r.status===404)throw new Error(`Resource "${r.url}" not found`);const o=await r.blob();return new Promise((s,n)=>{const h=new FileReader;h.onerror=n,h.onloadend=()=>{try{s(i({res:r,result:h.result}))}catch(f){n(f)}},h.readAsDataURL(o)})}const tt={};function _i(e,t,i){let r=e.replace(/\?.*/,"");return i&&(r=e),/ttf|otf|eot|woff2?/i.test(r)&&(r=r.replace(/.*\//,"")),t?`[${t}]${r}`:r}async function it(e,t,i){const r=_i(e,t,i.includeQueryParams);if(tt[r]!=null)return tt[r];i.cacheBust&&(e+=(/\?/.test(e)?"&":"?")+new Date().getTime());let o;try{const s=await Pt(e,i.fetchRequestInit,({res:n,result:h})=>(t||(t=n.headers.get("Content-Type")||""),Ai(h)));o=Fi(s,t)}catch(s){o=i.imagePlaceholder||"";let n=`Failed to fetch resource: ${e}`;s&&(n=typeof s=="string"?s:s.message),n&&console.warn(n)}return tt[r]=o,o}async function Pi(e){const t=e.toDataURL();return t==="data:,"?e.cloneNode(!1):Pe(t)}async function Li(e,t){if(e.currentSrc){const s=document.createElement("canvas"),n=s.getContext("2d");s.width=e.clientWidth,s.height=e.clientHeight,n?.drawImage(e,0,0,s.width,s.height);const h=s.toDataURL();return Pe(h)}const i=e.poster,r=Ze(i),o=await it(i,r,t);return Pe(o)}async function Di(e,t){var i;try{if(!((i=e?.contentDocument)===null||i===void 0)&&i.body)return await Le(e.contentDocument.body,t,!0)}catch{}return e.cloneNode(!1)}async function Hi(e,t){return O(e,HTMLCanvasElement)?Pi(e):O(e,HTMLVideoElement)?Li(e,t):O(e,HTMLIFrameElement)?Di(e,t):e.cloneNode(Lt(e))}const Ui=e=>e.tagName!=null&&e.tagName.toUpperCase()==="SLOT",Lt=e=>e.tagName!=null&&e.tagName.toUpperCase()==="SVG";async function zi(e,t,i){var r,o;if(Lt(t))return t;let s=[];return Ui(e)&&e.assignedNodes?s=G(e.assignedNodes()):O(e,HTMLIFrameElement)&&(!((r=e.contentDocument)===null||r===void 0)&&r.body)?s=G(e.contentDocument.body.childNodes):s=G(((o=e.shadowRoot)!==null&&o!==void 0?o:e).childNodes),s.length===0||O(e,HTMLVideoElement)||await s.reduce((n,h)=>n.then(()=>Le(h,i)).then(f=>{f&&t.appendChild(f)}),Promise.resolve()),t}function $i(e,t,i){const r=t.style;if(!r)return;const o=window.getComputedStyle(e);o.cssText?(r.cssText=o.cssText,r.transformOrigin=o.transformOrigin):Ot(i).forEach(s=>{let n=o.getPropertyValue(s);s==="font-size"&&n.endsWith("px")&&(n=`${Math.floor(parseFloat(n.substring(0,n.length-2)))-.1}px`),O(e,HTMLIFrameElement)&&s==="display"&&n==="inline"&&(n="block"),s==="d"&&t.getAttribute("d")&&(n=`path(${t.getAttribute("d")})`),r.setProperty(s,n,o.getPropertyPriority(s))})}function Bi(e,t){O(e,HTMLTextAreaElement)&&(t.innerHTML=e.value),O(e,HTMLInputElement)&&t.setAttribute("value",e.value)}function Vi(e,t){if(O(e,HTMLSelectElement)){const r=Array.from(t.children).find(o=>e.value===o.getAttribute("value"));r&&r.setAttribute("selected","")}}function Wi(e,t,i){return O(t,Element)&&($i(e,t,i),Ti(e,t,i),Bi(e,t),Vi(e,t)),t}async function qi(e,t){const i=e.querySelectorAll?e.querySelectorAll("use"):[];if(i.length===0)return e;const r={};for(let s=0;s<i.length;s++){const h=i[s].getAttribute("xlink:href");if(h){const f=e.querySelector(h),g=document.querySelector(h);!f&&g&&!r[h]&&(r[h]=await Le(g,t,!0))}}const o=Object.values(r);if(o.length){const s="http://www.w3.org/1999/xhtml",n=document.createElementNS(s,"svg");n.setAttribute("xmlns",s),n.style.position="absolute",n.style.width="0",n.style.height="0",n.style.overflow="hidden",n.style.display="none";const h=document.createElementNS(s,"defs");n.appendChild(h);for(let f=0;f<o.length;f++)h.appendChild(o[f]);e.appendChild(n)}return e}async function Le(e,t,i){return!i&&t.filter&&!t.filter(e)?null:Promise.resolve(e).then(r=>Hi(r,t)).then(r=>zi(e,r,t)).then(r=>Wi(e,r,t)).then(r=>qi(r,t))}const Dt=/url\((['"]?)([^'"]+?)\1\)/g,Ri=/url\([^)]+\)\s*format\((["']?)([^"']+)\1\)/g,ji=/src:\s*(?:url\([^)]+\)\s*format\([^)]+\)[,;]\s*)+/g;function Ni(e){const t=e.replace(/([.*+?^${}()|\[\]\/\\])/g,"\\$1");return new RegExp(`(url\\(['"]?)(${t})(['"]?\\))`,"g")}function Gi(e){const t=[];return e.replace(Dt,(i,r,o)=>(t.push(o),i)),t.filter(i=>!et(i))}async function Xi(e,t,i,r,o){try{const s=i?gi(t,i):t,n=Ze(t);let h;return o||(h=await it(s,n,r)),e.replace(Ni(t),`$1${h}$3`)}catch{}return e}function Yi(e,{preferredFontFormat:t}){return t?e.replace(ji,i=>{for(;;){const[r,,o]=Ri.exec(i)||[];if(!o)return"";if(o===t)return`src: ${r};`}}):e}function Ht(e){return e.search(Dt)!==-1}async function Ut(e,t,i){if(!Ht(e))return e;const r=Yi(e,i);return Gi(r).reduce((s,n)=>s.then(h=>Xi(h,n,t,i)),Promise.resolve(r))}async function ae(e,t,i){var r;const o=(r=t.style)===null||r===void 0?void 0:r.getPropertyValue(e);if(o){const s=await Ut(o,null,i);return t.style.setProperty(e,s,t.style.getPropertyPriority(e)),!0}return!1}async function Ki(e,t){await ae("background",e,t)||await ae("background-image",e,t),await ae("mask",e,t)||await ae("-webkit-mask",e,t)||await ae("mask-image",e,t)||await ae("-webkit-mask-image",e,t)}async function Qi(e,t){const i=O(e,HTMLImageElement);if(!(i&&!et(e.src))&&!(O(e,SVGImageElement)&&!et(e.href.baseVal)))return;const r=i?e.src:e.href.baseVal,o=await it(r,Ze(r),t);await new Promise((s,n)=>{e.onload=s,e.onerror=t.onImageErrorHandler?(...f)=>{try{s(t.onImageErrorHandler(...f))}catch(g){n(g)}}:n;const h=e;h.decode&&(h.decode=s),h.loading==="lazy"&&(h.loading="eager"),i?(e.srcset="",e.src=o):e.href.baseVal=o})}async function Ji(e,t){const r=G(e.childNodes).map(o=>zt(o,t));await Promise.all(r).then(()=>e)}async function zt(e,t){O(e,Element)&&(await Ki(e,t),await Qi(e,t),await Ji(e,t))}function Zi(e,t){const{style:i}=e;t.backgroundColor&&(i.backgroundColor=t.backgroundColor),t.width&&(i.width=`${t.width}px`),t.height&&(i.height=`${t.height}px`);const r=t.style;return r!=null&&Object.keys(r).forEach(o=>{i[o]=r[o]}),e}const $t={};async function Bt(e){let t=$t[e];if(t!=null)return t;const r=await(await fetch(e)).text();return t={url:e,cssText:r},$t[e]=t,t}async function Vt(e,t){let i=e.cssText;const r=/url\(["']?([^"')]+)["']?\)/g,s=(i.match(/url\([^)]+\)/g)||[]).map(async n=>{let h=n.replace(r,"$1");return h.startsWith("https://")||(h=new URL(h,e.url).href),Pt(h,t.fetchRequestInit,({result:f})=>(i=i.replace(n,`url(${f})`),[n,f]))});return Promise.all(s).then(()=>i)}function Wt(e){if(e==null)return[];const t=[],i=/(\/\*[\s\S]*?\*\/)/gi;let r=e.replace(i,"");const o=new RegExp("((@.*?keyframes [\\s\\S]*?){([\\s\\S]*?}\\s*?)})","gi");for(;;){const f=o.exec(r);if(f===null)break;t.push(f[0])}r=r.replace(o,"");const s=/@import[\s\S]*?url\([^)]*\)[\s\S]*?;/gi,n="((\\s*?(?:\\/\\*[\\s\\S]*?\\*\\/)?\\s*?@media[\\s\\S]*?){([\\s\\S]*?)}\\s*?})|(([\\s\\S]*?){([\\s\\S]*?)})",h=new RegExp(n,"gi");for(;;){let f=s.exec(r);if(f===null){if(f=h.exec(r),f===null)break;s.lastIndex=h.lastIndex}else h.lastIndex=s.lastIndex;t.push(f[0])}return t}async function er(e,t){const i=[],r=[];return e.forEach(o=>{if("cssRules"in o)try{G(o.cssRules||[]).forEach((s,n)=>{if(s.type===CSSRule.IMPORT_RULE){let h=n+1;const f=s.href,g=Bt(f).then(m=>Vt(m,t)).then(m=>Wt(m).forEach(y=>{try{o.insertRule(y,y.startsWith("@import")?h+=1:o.cssRules.length)}catch(M){console.error("Error inserting rule from remote css",{rule:y,error:M})}})).catch(m=>{console.error("Error loading remote css",m.toString())});r.push(g)}})}catch(s){const n=e.find(h=>h.href==null)||document.styleSheets[0];o.href!=null&&r.push(Bt(o.href).then(h=>Vt(h,t)).then(h=>Wt(h).forEach(f=>{n.insertRule(f,n.cssRules.length)})).catch(h=>{console.error("Error loading remote stylesheet",h)})),console.error("Error inlining remote css file",s)}}),Promise.all(r).then(()=>(e.forEach(o=>{if("cssRules"in o)try{G(o.cssRules||[]).forEach(s=>{i.push(s)})}catch(s){console.error(`Error while reading CSS rules from ${o.href}`,s)}}),i))}function tr(e){return e.filter(t=>t.type===CSSRule.FONT_FACE_RULE).filter(t=>Ht(t.style.getPropertyValue("src")))}async function ir(e,t){if(e.ownerDocument==null)throw new Error("Provided element is not within a Document");const i=G(e.ownerDocument.styleSheets),r=await er(i,t);return tr(r)}function qt(e){return e.trim().replace(/["']/g,"")}function rr(e){const t=new Set;function i(r){(r.style.fontFamily||getComputedStyle(r).fontFamily).split(",").forEach(s=>{t.add(qt(s))}),Array.from(r.children).forEach(s=>{s instanceof HTMLElement&&i(s)})}return i(e),t}async function nr(e,t){const i=await ir(e,t),r=rr(e);return(await Promise.all(i.filter(s=>r.has(qt(s.style.fontFamily))).map(s=>{const n=s.parentStyleSheet?s.parentStyleSheet.href:null;return Ut(s.cssText,n,t)}))).join(`
|
|
2
|
-
`)}async function or(e,t){const i=t.fontEmbedCSS!=null?t.fontEmbedCSS:t.skipFonts?null:await nr(e,t);if(i){const r=document.createElement("style"),o=document.createTextNode(i);r.appendChild(o),e.firstChild?e.insertBefore(r,e.firstChild):e.appendChild(r)}}async function sr(e,t={}){const{width:i,height:r}=Mt(e,t),o=await Le(e,t,!0);return await or(o,t),await zt(o,t),Zi(o,t),await Si(o,i,r)}async function ar(e,t={}){const{width:i,height:r}=Mt(e,t),o=await sr(e,t),s=await Pe(o),n=document.createElement("canvas"),
|
|
1
|
+
(function(D,p){typeof exports=="object"&&typeof module<"u"?p(exports,require("react/jsx-runtime"),require("react")):typeof define=="function"&&define.amd?define(["exports","react/jsx-runtime","react"],p):(D=typeof globalThis<"u"?globalThis:D||self,p(D.SupportFeedbackLib={},D.jsxRuntime,D.React))})(this,(function(D,p,x){"use strict";var ii="2.0.7",ri=500,dt="user-agent",Z="",ut="?",k={FUNCTION:"function",OBJECT:"object",STRING:"string",UNDEFINED:"undefined"},I="browser",$="cpu",H="device",P="engine",A="os",ee="result",c="name",a="type",d="vendor",u="version",E="architecture",fe="major",l="model",ke="console",w="mobile",v="tablet",C="smarttv",U="wearable",Se="xr",he="embedded",te="inapp",ze="brands",Y="formFactors",$e="fullVersionList",ie="platform",Be="platformVersion",Ce="bitness",q="sec-ch-ua",ni=q+"-full-version-list",oi=q+"-arch",si=q+"-"+Ce,ai=q+"-form-factors",li=q+"-"+w,ci=q+"-"+l,ft=q+"-"+ie,di=ft+"-version",ht=[ze,$e,w,l,ie,Be,E,Y,Ce],Ee="Amazon",re="Apple",pt="ASUS",bt="BlackBerry",K="Google",gt="Huawei",Ve="Lenovo",wt="Honor",Ie="LG",We="Microsoft",qe="Motorola",mt="Nvidia",yt="OnePlus",Re="OPPO",pe="Samsung",xt="Sharp",be="Sony",je="Xiaomi",Ne="Zebra",vt="Chrome",kt="Chromium",R="Chromecast",Te="Edge",ge="Firefox",we="Opera",Ge="Facebook",St="Sogou",ne="Mobile ",me=" Browser",Xe="Windows",ui=typeof window!==k.UNDEFINED,T=ui&&window.navigator?window.navigator:void 0,Q=T&&T.userAgentData?T.userAgentData:void 0,fi=function(e,t){var i={},r=t;if(!Me(t)){r={};for(var o in t)for(var s in t[o])r[s]=t[o][s].concat(r[s]?r[s]:[])}for(var n in e)i[n]=r[n]&&r[n].length%2===0?r[n].concat(e[n]):e[n];return i},Oe=function(e){for(var t={},i=0;i<e.length;i++)t[e[i].toUpperCase()]=e[i];return t},Ye=function(e,t){if(typeof e===k.OBJECT&&e.length>0){for(var i in e)if(j(t)==j(e[i]))return!0;return!1}return ye(e)?j(t)==j(e):!1},Me=function(e,t){for(var i in e)return/^(browser|cpu|device|engine|os)$/.test(i)||(t?Me(e[i]):!1)},ye=function(e){return typeof e===k.STRING},Ke=function(e){if(e){for(var t=[],i=oe(/\\?\"/g,e).split(","),r=0;r<i.length;r++)if(i[r].indexOf(";")>-1){var o=Ae(i[r]).split(";v=");t[r]={brand:o[0],version:o[1]}}else t[r]=Ae(i[r]);return t}},j=function(e){return ye(e)?e.toLowerCase():e},Qe=function(e){return ye(e)?oe(/[^\d\.]/g,e).split(".")[0]:void 0},B=function(e){for(var t in e)if(e.hasOwnProperty(t)){var i=e[t];typeof i==k.OBJECT&&i.length==2?this[i[0]]=i[1]:this[i]=void 0}return this},oe=function(e,t){return ye(t)?t.replace(e,Z):t},xe=function(e){return oe(/\\?\"/g,e)},Ae=function(e,t){return e=oe(/^\s\s*/,String(e)),typeof t===k.UNDEFINED?e:e.substring(0,t)},Je=function(e,t){if(!(!e||!t))for(var i=0,r,o,s,n,f,h;i<t.length&&!f;){var g=t[i],m=t[i+1];for(r=o=0;r<g.length&&!f&&g[r];)if(f=g[r++].exec(e),f)for(s=0;s<m.length;s++)h=f[++o],n=m[s],typeof n===k.OBJECT&&n.length>0?n.length===2?typeof n[1]==k.FUNCTION?this[n[0]]=n[1].call(this,h):this[n[0]]=n[1]:n.length>=3&&(typeof n[1]===k.FUNCTION&&!(n[1].exec&&n[1].test)?n.length>3?this[n[0]]=h?n[1].apply(this,n.slice(2)):void 0:this[n[0]]=h?n[1].call(this,h,n[2]):void 0:n.length==3?this[n[0]]=h?h.replace(n[1],n[2]):void 0:n.length==4?this[n[0]]=h?n[3].call(this,h.replace(n[1],n[2])):void 0:n.length>4&&(this[n[0]]=h?n[3].apply(this,[h.replace(n[1],n[2])].concat(n.slice(4))):void 0)):this[n]=h||void 0;i+=2}},L=function(e,t){for(var i in t)if(typeof t[i]===k.OBJECT&&t[i].length>0){for(var r=0;r<t[i].length;r++)if(Ye(t[i][r],e))return i===ut?void 0:i}else if(Ye(t[i],e))return i===ut?void 0:i;return t.hasOwnProperty("*")?t["*"]:e},Ct={ME:"4.90","NT 3.51":"3.51","NT 4.0":"4.0",2e3:["5.0","5.01"],XP:["5.1","5.2"],Vista:"6.0",7:"6.1",8:"6.2","8.1":"6.3",10:["6.4","10.0"],NT:""},Et={embedded:"Automotive",mobile:"Mobile",tablet:["Tablet","EInk"],smarttv:"TV",wearable:"Watch",xr:["VR","XR"],"?":["Desktop","Unknown"],"*":void 0},hi={Chrome:"Google Chrome",Edge:"Microsoft Edge","Edge WebView2":"Microsoft Edge WebView2","Chrome WebView":"Android WebView","Chrome Headless":"HeadlessChrome","Huawei Browser":"HuaweiBrowser","MIUI Browser":"Miui Browser","Opera Mobi":"OperaMobile",Yandex:"YaBrowser"},It={browser:[[/\b(?:crmo|crios)\/([\w\.]+)/i],[u,[c,ne+"Chrome"]],[/webview.+edge\/([\w\.]+)/i],[u,[c,Te+" WebView"]],[/edg(?:e|ios|a)?\/([\w\.]+)/i],[u,[c,"Edge"]],[/(opera mini)\/([-\w\.]+)/i,/(opera [mobiletab]{3,6})\b.+version\/([-\w\.]+)/i,/(opera)(?:.+version\/|[\/ ]+)([\w\.]+)/i],[c,u],[/opios[\/ ]+([\w\.]+)/i],[u,[c,we+" Mini"]],[/\bop(?:rg)?x\/([\w\.]+)/i],[u,[c,we+" GX"]],[/\bopr\/([\w\.]+)/i],[u,[c,we]],[/\bb[ai]*d(?:uhd|[ub]*[aekoprswx]{5,6})[\/ ]?([\w\.]+)/i],[u,[c,"Baidu"]],[/\b(?:mxbrowser|mxios|myie2)\/?([-\w\.]*)\b/i],[u,[c,"Maxthon"]],[/(kindle)\/([\w\.]+)/i,/(lunascape|maxthon|netfront|jasmine|blazer|sleipnir)[\/ ]?([\w\.]*)/i,/(avant|iemobile|slim(?:browser|boat|jet))[\/ ]?([\d\.]*)/i,/(?:ms|\()(ie) ([\w\.]+)/i,/(atlas|flock|rockmelt|midori|epiphany|silk|skyfire|ovibrowser|bolt|iron|vivaldi|iridium|phantomjs|bowser|qupzilla|falkon|rekonq|puffin|brave|whale(?!.+naver)|qqbrowserlite|duckduckgo|klar|helio|(?=comodo_)?dragon|otter|dooble|(?:lg |qute)browser|palemoon)\/([-\w\.]+)/i,/(heytap|ovi|115|surf|qwant)browser\/([\d\.]+)/i,/(qwant)(?:ios|mobile)\/([\d\.]+)/i,/(ecosia|weibo)(?:__| \w+@)([\d\.]+)/i],[c,u],[/quark(?:pc)?\/([-\w\.]+)/i],[u,[c,"Quark"]],[/\bddg\/([\w\.]+)/i],[u,[c,"DuckDuckGo"]],[/(?:\buc? ?browser|(?:juc.+)ucweb)[\/ ]?([\w\.]+)/i],[u,[c,"UCBrowser"]],[/microm.+\bqbcore\/([\w\.]+)/i,/\bqbcore\/([\w\.]+).+microm/i,/micromessenger\/([\w\.]+)/i],[u,[c,"WeChat"]],[/konqueror\/([\w\.]+)/i],[u,[c,"Konqueror"]],[/trident.+rv[: ]([\w\.]{1,9})\b.+like gecko/i],[u,[c,"IE"]],[/ya(?:search)?browser\/([\w\.]+)/i],[u,[c,"Yandex"]],[/slbrowser\/([\w\.]+)/i],[u,[c,"Smart "+Ve+me]],[/(avast|avg)\/([\w\.]+)/i],[[c,/(.+)/,"$1 Secure"+me],u],[/\bfocus\/([\w\.]+)/i],[u,[c,ge+" Focus"]],[/\bopt\/([\w\.]+)/i],[u,[c,we+" Touch"]],[/coc_coc\w+\/([\w\.]+)/i],[u,[c,"Coc Coc"]],[/dolfin\/([\w\.]+)/i],[u,[c,"Dolphin"]],[/coast\/([\w\.]+)/i],[u,[c,we+" Coast"]],[/miuibrowser\/([\w\.]+)/i],[u,[c,"MIUI"+me]],[/fxios\/([\w\.-]+)/i],[u,[c,ne+ge]],[/\bqihoobrowser\/?([\w\.]*)/i],[u,[c,"360"]],[/\b(qq)\/([\w\.]+)/i],[[c,/(.+)/,"$1Browser"],u],[/(oculus|sailfish|huawei|vivo|pico)browser\/([\w\.]+)/i],[[c,/(.+)/,"$1"+me],u],[/samsungbrowser\/([\w\.]+)/i],[u,[c,pe+" Internet"]],[/metasr[\/ ]?([\d\.]+)/i],[u,[c,St+" Explorer"]],[/(sogou)mo\w+\/([\d\.]+)/i],[[c,St+" Mobile"],u],[/(electron)\/([\w\.]+) safari/i,/(tesla)(?: qtcarbrowser|\/(20\d\d\.[-\w\.]+))/i,/m?(qqbrowser|2345(?=browser|chrome|explorer))\w*[\/ ]?v?([\w\.]+)/i],[c,u],[/(lbbrowser|rekonq|steam(?= (clie|tenf|gameo)))/i],[c],[/ome\/([\w\.]+) \w* ?(iron) saf/i,/ome\/([\w\.]+).+qihu (360)[es]e/i],[u,c],[/((?:fban\/fbios|fb_iab\/fb4a)(?!.+fbav)|;fbav\/([\w\.]+);)/i],[[c,Ge],u,[a,te]],[/(kakao(?:talk|story))[\/ ]([\w\.]+)/i,/(naver)\(.*?(\d+\.[\w\.]+).*\)/i,/(daum)apps[\/ ]([\w\.]+)/i,/safari (line)\/([\w\.]+)/i,/\b(line)\/([\w\.]+)\/iab/i,/(alipay)client\/([\w\.]+)/i,/(twitter)(?:and| f.+e\/([\w\.]+))/i,/(bing)(?:web|sapphire)\/([\w\.]+)/i,/(instagram|snapchat|klarna)[\/ ]([-\w\.]+)/i],[c,u,[a,te]],[/\bgsa\/([\w\.]+) .*safari\//i],[u,[c,"GSA"],[a,te]],[/musical_ly(?:.+app_?version\/|_)([\w\.]+)/i],[u,[c,"TikTok"],[a,te]],[/\[(linkedin)app\]/i],[c,[a,te]],[/(zalo(?:app)?)[\/\sa-z]*([\w\.-]+)/i],[[c,/(.+)/,"Zalo"],u,[a,te]],[/(chromium)[\/ ]([-\w\.]+)/i],[c,u],[/headlesschrome(?:\/([\w\.]+)| )/i],[u,[c,vt+" Headless"]],[/wv\).+chrome\/([\w\.]+).+edgw\//i],[u,[c,Te+" WebView2"]],[/ wv\).+(chrome)\/([\w\.]+)/i],[[c,vt+" WebView"],u],[/droid.+ version\/([\w\.]+)\b.+(?:mobile safari|safari)/i],[u,[c,"Android"+me]],[/chrome\/([\w\.]+) mobile/i],[u,[c,ne+"Chrome"]],[/(chrome|omniweb|arora|[tizenoka]{5} ?browser)\/v?([\w\.]+)/i],[c,u],[/version\/([\w\.\,]+) .*mobile(?:\/\w+ | ?)safari/i],[u,[c,ne+"Safari"]],[/iphone .*mobile(?:\/\w+ | ?)safari/i],[[c,ne+"Safari"]],[/version\/([\w\.\,]+) .*(safari)/i],[u,c],[/webkit.+?(mobile ?safari|safari)(\/[\w\.]+)/i],[c,[u,"1"]],[/(webkit|khtml)\/([\w\.]+)/i],[c,u],[/(?:mobile|tablet);.*(firefox)\/([\w\.-]+)/i],[[c,ne+ge],u],[/(navigator|netscape\d?)\/([-\w\.]+)/i],[[c,"Netscape"],u],[/(wolvic|librewolf)\/([\w\.]+)/i],[c,u],[/mobile vr; rv:([\w\.]+)\).+firefox/i],[u,[c,ge+" Reality"]],[/ekiohf.+(flow)\/([\w\.]+)/i,/(swiftfox)/i,/(icedragon|iceweasel|camino|chimera|fennec|maemo browser|minimo|conkeror)[\/ ]?([\w\.\+]+)/i,/(seamonkey|k-meleon|icecat|iceape|firebird|phoenix|basilisk|waterfox)\/([-\w\.]+)$/i,/(firefox)\/([\w\.]+)/i,/(mozilla)\/([\w\.]+(?= .+rv\:.+gecko\/\d+)|[0-4][\w\.]+(?!.+compatible))/i,/(amaya|dillo|doris|icab|ladybird|lynx|mosaic|netsurf|obigo|polaris|w3m|(?:go|ice|up)[\. ]?browser)[-\/ ]?v?([\w\.]+)/i,/\b(links) \(([\w\.]+)/i],[c,[u,/_/g,"."]],[/(cobalt)\/([\w\.]+)/i],[c,[u,/[^\d\.]+./,Z]]],cpu:[[/\b((amd|x|x86[-_]?|wow|win)64)\b/i],[[E,"amd64"]],[/(ia32(?=;))/i,/\b((i[346]|x)86)(pc)?\b/i],[[E,"ia32"]],[/\b(aarch64|arm(v?[89]e?l?|_?64))\b/i],[[E,"arm64"]],[/\b(arm(v[67])?ht?n?[fl]p?)\b/i],[[E,"armhf"]],[/( (ce|mobile); ppc;|\/[\w\.]+arm\b)/i],[[E,"arm"]],[/ sun4\w[;\)]/i],[[E,"sparc"]],[/\b(avr32|ia64(?=;)|68k(?=\))|\barm(?=v([1-7]|[5-7]1)l?|;|eabi)|(irix|mips|sparc)(64)?\b|pa-risc)/i,/((ppc|powerpc)(64)?)( mac|;|\))/i,/(?:osf1|[freopnt]{3,4}bsd) (alpha)/i],[[E,/ower/,Z,j]],[/mc680.0/i],[[E,"68k"]],[/winnt.+\[axp/i],[[E,"alpha"]]],device:[[/\b(sch-i[89]0\d|shw-m380s|sm-[ptx]\w{2,4}|gt-[pn]\d{2,4}|sgh-t8[56]9|nexus 10)/i],[l,[d,pe],[a,v]],[/\b((?:s[cgp]h|gt|sm)-(?![lr])\w+|sc[g-]?[\d]+a?|galaxy nexus)/i,/samsung[- ]((?!sm-[lr]|browser)[-\w]+)/i,/sec-(sgh\w+)/i],[l,[d,pe],[a,w]],[/(?:\/|\()(ip(?:hone|od)[\w, ]*)[\/\);]/i],[l,[d,re],[a,w]],[/\b(?:ios|apple\w+)\/.+[\(\/](ipad)/i,/\b(ipad)[\d,]*[;\] ].+(mac |i(pad)?)os/i],[l,[d,re],[a,v]],[/(macintosh);/i],[l,[d,re]],[/\b(sh-?[altvz]?\d\d[a-ekm]?)/i],[l,[d,xt],[a,w]],[/\b((?:brt|eln|hey2?|gdi|jdn)-a?[lnw]09|(?:ag[rm]3?|jdn2|kob2)-a?[lw]0[09]hn)(?: bui|\)|;)/i],[l,[d,wt],[a,v]],[/honor([-\w ]+)[;\)]/i],[l,[d,wt],[a,w]],[/\b((?:ag[rs][2356]?k?|bah[234]?|bg[2o]|bt[kv]|cmr|cpn|db[ry]2?|jdn2|got|kob2?k?|mon|pce|scm|sht?|[tw]gr|vrd)-[ad]?[lw][0125][09]b?|605hw|bg2-u03|(?:gem|fdr|m2|ple|t1)-[7a]0[1-4][lu]|t1-a2[13][lw]|mediapad[\w\. ]*(?= bui|\)))\b(?!.+d\/s)/i],[l,[d,gt],[a,v]],[/(?:huawei) ?([-\w ]+)[;\)]/i,/\b(nexus 6p|\w{2,4}e?-[atu]?[ln][\dx][\dc][adnt]?)\b(?!.+d\/s)/i],[l,[d,gt],[a,w]],[/oid[^\)]+; (2[\dbc]{4}(182|283|rp\w{2})[cgl]|m2105k81a?c)(?: bui|\))/i,/\b(?:xiao)?((?:red)?mi[-_ ]?pad[\w- ]*)(?: bui|\))/i],[[l,/_/g," "],[d,je],[a,v]],[/\b; (\w+) build\/hm\1/i,/\b(hm[-_ ]?note?[_ ]?(?:\d\w)?) bui/i,/oid[^\)]+; (redmi[\-_ ]?(?:note|k)?[\w_ ]+|m?[12]\d[01]\d\w{3,6}|poco[\w ]+|(shark )?\w{3}-[ah]0|qin ?[1-3](s\+|ultra| pro)?)( bui|; wv|\))/i,/\b(mi[-_ ]?(?:a\d|one|one[_ ]plus|note|max|cc)?[_ ]?(?:\d{0,2}\w?)[_ ]?(?:plus|se|lite|pro)?( 5g|lte)?)(?: bui|\))/i,/ ([\w ]+) miui\/v?\d/i],[[l,/_/g," "],[d,je],[a,w]],[/droid.+; (cph2[3-6]\d[13579]|((gm|hd)19|(ac|be|in|kb)20|(d[en]|eb|le|mt)21|ne22)[0-2]\d|p[g-k]\w[1m]10)\b/i,/(?:one)?(?:plus)? (a\d0\d\d)(?: b|\))/i],[l,[d,yt],[a,w]],[/; (\w+) bui.+ oppo/i,/\b(cph[12]\d{3}|p(?:af|c[al]|d\w|e[ar])[mt]\d0|x9007|a101op)\b/i],[l,[d,Re],[a,w]],[/\b(opd2(\d{3}a?))(?: bui|\))/i],[l,[d,L,{OnePlus:["203","304","403","404","413","415"],"*":Re}],[a,v]],[/(vivo (5r?|6|8l?|go|one|s|x[il]?[2-4]?)[\w\+ ]*)(?: bui|\))/i],[l,[d,"BLU"],[a,w]],[/; vivo (\w+)(?: bui|\))/i,/\b(v[12]\d{3}\w?[at])(?: bui|;)/i],[l,[d,"Vivo"],[a,w]],[/\b(rmx[1-3]\d{3})(?: bui|;|\))/i],[l,[d,"Realme"],[a,w]],[/(ideatab[-\w ]+|602lv|d-42a|a101lv|a2109a|a3500-hv|s[56]000|pb-6505[my]|tb-?x?\d{3,4}(?:f[cu]|xu|[av])|yt\d?-[jx]?\d+[lfmx])( bui|;|\)|\/)/i,/lenovo ?(b[68]0[08]0-?[hf]?|tab(?:[\w- ]+?)|tb[\w-]{6,7})( bui|;|\)|\/)/i],[l,[d,Ve],[a,v]],[/lenovo[-_ ]?([-\w ]+?)(?: bui|\)|\/)/i],[l,[d,Ve],[a,w]],[/\b(milestone|droid(?:[2-4x]| (?:bionic|x2|pro|razr))?:?( 4g)?)\b[\w ]+build\//i,/\bmot(?:orola)?[- ]([\w\s]+)(\)| bui)/i,/((?:moto(?! 360)[-\w\(\) ]+|xt\d{3,4}[cgkosw\+]?[-\d]*|nexus 6)(?= bui|\)))/i],[l,[d,qe],[a,w]],[/\b(mz60\d|xoom[2 ]{0,2}) build\//i],[l,[d,qe],[a,v]],[/((?=lg)?[vl]k\-?\d{3}) bui| 3\.[-\w; ]{10}lg?-([06cv9]{3,4})/i],[l,[d,Ie],[a,v]],[/(lm(?:-?f100[nv]?|-[\w\.]+)(?= bui|\))|nexus [45])/i,/\blg[-e;\/ ]+(?!.*(?:browser|netcast|android tv|watch|webos))(\w+)/i,/\blg-?([\d\w]+) bui/i],[l,[d,Ie],[a,w]],[/(nokia) (t[12][01])/i],[d,l,[a,v]],[/(?:maemo|nokia).*(n900|lumia \d+|rm-\d+)/i,/nokia[-_ ]?(([-\w\. ]*?))( bui|\)|;|\/)/i],[[l,/_/g," "],[a,w],[d,"Nokia"]],[/(pixel (c|tablet))\b/i],[l,[d,K],[a,v]],[/droid.+;(?: google)? (g(01[13]a|020[aem]|025[jn]|1b60|1f8f|2ybb|4s1m|576d|5nz6|8hhn|8vou|a02099|c15s|d1yq|e2ae|ec77|gh2x|kv4x|p4bc|pj41|r83y|tt9q|ur25|wvk6)|pixel[\d ]*a?( pro)?( xl)?( fold)?( \(5g\))?)( bui|\))/i],[l,[d,K],[a,w]],[/(google) (pixelbook( go)?)/i],[d,l],[/droid.+; (a?\d[0-2]{2}so|[c-g]\d{4}|so[-gl]\w+|xq-\w\w\d\d)(?= bui|\).+chrome\/(?![1-6]{0,1}\d\.))/i],[l,[d,be],[a,w]],[/sony tablet [ps]/i,/\b(?:sony)?sgp\w+(?: bui|\))/i],[[l,"Xperia Tablet"],[d,be],[a,v]],[/(alexa)webm/i,/(kf[a-z]{2}wi|aeo(?!bc)\w\w)( bui|\))/i,/(kf[a-z]+)( bui|\)).+silk\//i],[l,[d,Ee],[a,v]],[/((?:sd|kf)[0349hijorstuw]+)( bui|\)).+silk\//i],[[l,/(.+)/g,"Fire Phone $1"],[d,Ee],[a,w]],[/(playbook);[-\w\),; ]+(rim)/i],[l,d,[a,v]],[/\b((?:bb[a-f]|st[hv])100-\d)/i,/(?:blackberry|\(bb10;) (\w+)/i],[l,[d,bt],[a,w]],[/(?:\b|asus_)(transfo[prime ]{4,10} \w+|eeepc|slider \w+|nexus 7|padfone|p00[cj])/i],[l,[d,pt],[a,v]],[/ (z[bes]6[027][012][km][ls]|zenfone \d\w?)\b/i],[l,[d,pt],[a,w]],[/(nexus 9)/i],[l,[d,"HTC"],[a,v]],[/(htc)[-;_ ]{1,2}([\w ]+(?=\)| bui)|\w+)/i,/(zte)[- ]([\w ]+?)(?: bui|\/|\))/i,/(alcatel|geeksphone|nexian|panasonic(?!(?:;|\.))|sony(?!-bra))[-_ ]?([-\w]*)/i],[d,[l,/_/g," "],[a,w]],[/tcl (xess p17aa)/i,/droid [\w\.]+; ((?:8[14]9[16]|9(?:0(?:48|60|8[01])|1(?:3[27]|66)|2(?:6[69]|9[56])|466))[gqswx])(_\w(\w|\w\w))?(\)| bui)/i],[l,[d,"TCL"],[a,v]],[/droid [\w\.]+; (418(?:7d|8v)|5087z|5102l|61(?:02[dh]|25[adfh]|27[ai]|56[dh]|59k|65[ah])|a509dl|t(?:43(?:0w|1[adepqu])|50(?:6d|7[adju])|6(?:09dl|10k|12b|71[efho]|76[hjk])|7(?:66[ahju]|67[hw]|7[045][bh]|71[hk]|73o|76[ho]|79w|81[hks]?|82h|90[bhsy]|99b)|810[hs]))(_\w(\w|\w\w))?(\)| bui)/i],[l,[d,"TCL"],[a,w]],[/(itel) ((\w+))/i],[[d,j],l,[a,L,{tablet:["p10001l","w7001"],"*":"mobile"}]],[/droid.+; ([ab][1-7]-?[0178a]\d\d?)/i],[l,[d,"Acer"],[a,v]],[/droid.+; (m[1-5] note) bui/i,/\bmz-([-\w]{2,})/i],[l,[d,"Meizu"],[a,w]],[/; ((?:power )?armor(?:[\w ]{0,8}))(?: bui|\))/i],[l,[d,"Ulefone"],[a,w]],[/; (energy ?\w+)(?: bui|\))/i,/; energizer ([\w ]+)(?: bui|\))/i],[l,[d,"Energizer"],[a,w]],[/; cat (b35);/i,/; (b15q?|s22 flip|s48c|s62 pro)(?: bui|\))/i],[l,[d,"Cat"],[a,w]],[/((?:new )?andromax[\w- ]+)(?: bui|\))/i],[l,[d,"Smartfren"],[a,w]],[/droid.+; (a(in)?(0(15|59|6[35])|142)p?)/i],[l,[d,"Nothing"],[a,w]],[/; (x67 5g|tikeasy \w+|ac[1789]\d\w+)( b|\))/i,/archos ?(5|gamepad2?|([\w ]*[t1789]|hello) ?\d+[\w ]*)( b|\))/i],[l,[d,"Archos"],[a,v]],[/archos ([\w ]+)( b|\))/i,/; (ac[3-6]\d\w{2,8})( b|\))/i],[l,[d,"Archos"],[a,w]],[/; (n159v)/i],[l,[d,"HMD"],[a,w]],[/(imo) (tab \w+)/i,/(infinix|tecno) (x1101b?|p904|dp(7c|8d|10a)( pro)?|p70[1-3]a?|p904|t1101)/i],[d,l,[a,v]],[/(blackberry|benq|palm(?=\-)|sonyericsson|acer|asus(?! zenw)|dell|jolla|meizu|motorola|polytron|tecno|micromax|advan)[-_ ]?([-\w]*)/i,/; (blu|hmd|imo|infinix|lava|oneplus|tcl|wiko)[_ ]([\w\+ ]+?)(?: bui|\)|; r)/i,/(hp) ([\w ]+\w)/i,/(microsoft); (lumia[\w ]+)/i,/(oppo) ?([\w ]+) bui/i,/(hisense) ([ehv][\w ]+)\)/i,/droid[^;]+; (philips)[_ ]([sv-x][\d]{3,4}[xz]?)/i],[d,l,[a,w]],[/(kobo)\s(ereader|touch)/i,/(hp).+(touchpad(?!.+tablet)|tablet)/i,/(kindle)\/([\w\.]+)/i],[d,l,[a,v]],[/(surface duo)/i],[l,[d,We],[a,v]],[/droid [\d\.]+; (fp\du?)(?: b|\))/i],[l,[d,"Fairphone"],[a,w]],[/((?:tegranote|shield t(?!.+d tv))[\w- ]*?)(?: b|\))/i],[l,[d,mt],[a,v]],[/(sprint) (\w+)/i],[d,l,[a,w]],[/(kin\.[onetw]{3})/i],[[l,/\./g," "],[d,We],[a,w]],[/droid.+; ([c6]+|et5[16]|mc[239][23]x?|vc8[03]x?)\)/i],[l,[d,Ne],[a,v]],[/droid.+; (ec30|ps20|tc[2-8]\d[kx])\)/i],[l,[d,Ne],[a,w]],[/(philips)[\w ]+tv/i,/smart-tv.+(samsung)/i],[d,[a,C]],[/hbbtv.+maple;(\d+)/i],[[l,/^/,"SmartTV"],[d,pe],[a,C]],[/(vizio)(?: |.+model\/)(\w+-\w+)/i,/tcast.+(lg)e?. ([-\w]+)/i],[d,l,[a,C]],[/(nux; netcast.+smarttv|lg (netcast\.tv-201\d|android tv))/i],[[d,Ie],[a,C]],[/(apple) ?tv/i],[d,[l,re+" TV"],[a,C]],[/crkey.*devicetype\/chromecast/i],[[l,R+" Third Generation"],[d,K],[a,C]],[/crkey.*devicetype\/([^/]*)/i],[[l,/^/,"Chromecast "],[d,K],[a,C]],[/fuchsia.*crkey/i],[[l,R+" Nest Hub"],[d,K],[a,C]],[/crkey/i],[[l,R],[d,K],[a,C]],[/(portaltv)/i],[l,[d,Ge],[a,C]],[/droid.+aft(\w+)( bui|\))/i],[l,[d,Ee],[a,C]],[/(shield \w+ tv)/i],[l,[d,mt],[a,C]],[/\(dtv[\);].+(aquos)/i,/(aquos-tv[\w ]+)\)/i],[l,[d,xt],[a,C]],[/(bravia[\w ]+)( bui|\))/i],[l,[d,be],[a,C]],[/(mi(tv|box)-?\w+) bui/i],[l,[d,je],[a,C]],[/Hbbtv.*(technisat) (.*);/i],[d,l,[a,C]],[/\b(roku)[\dx]*[\)\/]((?:dvp-)?[\d\.]*)/i,/hbbtv\/\d+\.\d+\.\d+ +\([\w\+ ]*; *([\w\d][^;]*);([^;]*)/i],[[d,/.+\/(\w+)/,"$1",L,{LG:"lge"}],[l,Ae],[a,C]],[/(playstation \w+)/i],[l,[d,be],[a,ke]],[/\b(xbox(?: one)?(?!; xbox))[\); ]/i],[l,[d,We],[a,ke]],[/(ouya)/i,/(nintendo) (\w+)/i,/(retroid) (pocket ([^\)]+))/i,/(valve).+(steam deck)/i,/droid.+; ((shield|rgcube|gr0006))( bui|\))/i],[[d,L,{Nvidia:"Shield",Anbernic:"RGCUBE",Logitech:"GR0006"}],l,[a,ke]],[/\b(sm-[lr]\d\d[0156][fnuw]?s?|gear live)\b/i],[l,[d,pe],[a,U]],[/((pebble))app/i,/(asus|google|lg|oppo|xiaomi) ((pixel |zen)?watch[\w ]*)( bui|\))/i],[d,l,[a,U]],[/(ow(?:19|20)?we?[1-3]{1,3})/i],[l,[d,Re],[a,U]],[/(watch)(?: ?os[,\/]|\d,\d\/)[\d\.]+/i],[l,[d,re],[a,U]],[/(opwwe\d{3})/i],[l,[d,yt],[a,U]],[/(moto 360)/i],[l,[d,qe],[a,U]],[/(smartwatch 3)/i],[l,[d,be],[a,U]],[/(g watch r)/i],[l,[d,Ie],[a,U]],[/droid.+; (wt63?0{2,3})\)/i],[l,[d,Ne],[a,U]],[/droid.+; (glass) \d/i],[l,[d,K],[a,Se]],[/(pico) ([\w ]+) os\d/i],[d,l,[a,Se]],[/(quest( \d| pro)?s?).+vr/i],[l,[d,Ge],[a,Se]],[/mobile vr; rv.+firefox/i],[[a,Se]],[/(tesla)(?: qtcarbrowser|\/[-\w\.]+)/i],[d,[a,he]],[/(aeobc)\b/i],[l,[d,Ee],[a,he]],[/(homepod).+mac os/i],[l,[d,re],[a,he]],[/windows iot/i],[[a,he]],[/droid.+; ([\w- ]+) (4k|android|smart|google)[- ]?tv/i],[l,[a,C]],[/\b((4k|android|smart|opera)[- ]?tv|tv; rv:|large screen[\w ]+safari)\b/i],[[a,C]],[/droid .+?; ([^;]+?)(?: bui|; wv\)|\) applew|; hmsc).+?(mobile|vr|\d) safari/i],[l,[a,L,{mobile:"Mobile",xr:"VR","*":v}]],[/\b((tablet|tab)[;\/]|focus\/\d(?!.+mobile))/i],[[a,v]],[/(phone|mobile(?:[;\/]| [ \w\/\.]*safari)|pda(?=.+windows ce))/i],[[a,w]],[/droid .+?; ([\w\. -]+)( bui|\))/i],[l,[d,"Generic"]]],engine:[[/windows.+ edge\/([\w\.]+)/i],[u,[c,Te+"HTML"]],[/(arkweb)\/([\w\.]+)/i],[c,u],[/webkit\/537\.36.+chrome\/(?!27)([\w\.]+)/i],[u,[c,"Blink"]],[/(presto)\/([\w\.]+)/i,/(webkit|trident|netfront|netsurf|amaya|lynx|w3m|goanna|servo)\/([\w\.]+)/i,/ekioh(flow)\/([\w\.]+)/i,/(khtml|tasman|links)[\/ ]\(?([\w\.]+)/i,/(icab)[\/ ]([23]\.[\d\.]+)/i,/\b(libweb)/i],[c,u],[/ladybird\//i],[[c,"LibWeb"]],[/rv\:([\w\.]{1,9})\b.+(gecko)/i],[u,c]],os:[[/(windows nt) (6\.[23]); arm/i],[[c,/N/,"R"],[u,L,Ct]],[/(windows (?:phone|mobile|iot))(?: os)?[\/ ]?([\d\.]*( se)?)/i,/(windows)[\/ ](1[01]|2000|3\.1|7|8(\.1)?|9[58]|me|server 20\d\d( r2)?|vista|xp)/i],[c,u],[/windows nt ?([\d\.\)]*)(?!.+xbox)/i,/\bwin(?=3| ?9|n)(?:nt| 9x )?([\d\.;]*)/i],[[u,/(;|\))/g,"",L,Ct],[c,Xe]],[/(windows ce)\/?([\d\.]*)/i],[c,u],[/[adehimnop]{4,7}\b(?:.*os ([\w]+) like mac|; opera)/i,/(?:ios;fbsv|ios(?=.+ip(?:ad|hone)|.+apple ?tv)|ip(?:ad|hone)(?: |.+i(?:pad)?)os|apple ?tv.+ios)[\/ ]([\w\.]+)/i,/\btvos ?([\w\.]+)/i,/cfnetwork\/.+darwin/i],[[u,/_/g,"."],[c,"iOS"]],[/(mac os x) ?([\w\. ]*)/i,/(macintosh|mac_powerpc\b)(?!.+(haiku|morphos))/i],[[c,"macOS"],[u,/_/g,"."]],[/android ([\d\.]+).*crkey/i],[u,[c,R+" Android"]],[/fuchsia.*crkey\/([\d\.]+)/i],[u,[c,R+" Fuchsia"]],[/crkey\/([\d\.]+).*devicetype\/smartspeaker/i],[u,[c,R+" SmartSpeaker"]],[/linux.*crkey\/([\d\.]+)/i],[u,[c,R+" Linux"]],[/crkey\/([\d\.]+)/i],[u,[c,R]],[/droid ([\w\.]+)\b.+(android[- ]x86)/i],[u,c],[/(ubuntu) ([\w\.]+) like android/i],[[c,/(.+)/,"$1 Touch"],u],[/(harmonyos)[\/ ]?([\d\.]*)/i,/(android|bada|blackberry|kaios|maemo|meego|openharmony|qnx|rim tablet os|sailfish|series40|symbian|tizen)\w*[-\/\.; ]?([\d\.]*)/i],[c,u],[/\(bb(10);/i],[u,[c,bt]],[/(?:symbian ?os|symbos|s60(?=;)|series ?60)[-\/ ]?([\w\.]*)/i],[u,[c,"Symbian"]],[/mozilla\/[\d\.]+ \((?:mobile|tablet|tv|mobile; [\w ]+); rv:.+ gecko\/([\w\.]+)/i],[u,[c,ge+" OS"]],[/\b(?:hp)?wos(?:browser)?\/([\w\.]+)/i,/webos(?:[ \/]?|\.tv-20(?=2[2-9]))(\d[\d\.]*)/i],[u,[c,"webOS"]],[/web0s;.+?(?:chr[o0]me|safari)\/(\d+)/i],[[u,L,{25:"120",24:"108",23:"94",22:"87",6:"79",5:"68",4:"53",3:"38",2:"538",1:"537","*":"TV"}],[c,"webOS"]],[/watch(?: ?os[,\/]|\d,\d\/)([\d\.]+)/i],[u,[c,"watchOS"]],[/(cros) [\w]+(?:\)| ([\w\.]+)\b)/i],[[c,"Chrome OS"],u],[/panasonic;(viera)/i,/(netrange)mmh/i,/(nettv)\/(\d+\.[\w\.]+)/i,/(nintendo|playstation) (\w+)/i,/(xbox); +xbox ([^\);]+)/i,/(pico) .+os([\w\.]+)/i,/\b(joli|palm)\b ?(?:os)?\/?([\w\.]*)/i,/linux.+(mint)[\/\(\) ]?([\w\.]*)/i,/(mageia|vectorlinux|fuchsia|arcaos|arch(?= ?linux))[;l ]([\d\.]*)/i,/([kxln]?ubuntu|debian|suse|opensuse|gentoo|slackware|fedora|mandriva|centos|pclinuxos|red ?hat|zenwalk|linpus|raspbian|plan 9|minix|risc os|contiki|deepin|manjaro|elementary os|sabayon|linspire|knoppix)(?: gnu[\/ ]linux)?(?: enterprise)?(?:[- ]linux)?(?:-gnu)?[-\/ ]?(?!chrom|package)([-\w\.]*)/i,/((?:open)?solaris)[-\/ ]?([\w\.]*)/i,/\b(aix)[; ]([1-9\.]{0,4})/i,/(hurd|linux|morphos)(?: (?:arm|x86|ppc)\w*| ?)([\w\.]*)/i,/(gnu) ?([\w\.]*)/i,/\b([-frentopcghs]{0,5}bsd|dragonfly)[\/ ]?(?!amd|[ix346]{1,2}86)([\w\.]*)/i,/(haiku) ?(r\d)?/i],[c,u],[/(sunos) ?([\d\.]*)/i],[[c,"Solaris"],u],[/\b(beos|os\/2|amigaos|openvms|hp-ux|serenityos)/i,/(unix) ?([\w\.]*)/i],[c,u]]},Fe=(function(){var e={init:{},isIgnore:{},isIgnoreRgx:{},toString:{}};return B.call(e.init,[[I,[c,u,fe,a]],[$,[E]],[H,[a,l,d]],[P,[c,u]],[A,[c,u]]]),B.call(e.isIgnore,[[I,[u,fe]],[P,[u]],[A,[u]]]),B.call(e.isIgnoreRgx,[[I,/ ?browser$/i],[A,/ ?os$/i]]),B.call(e.toString,[[I,[c,u]],[$,[E]],[H,[d,l]],[P,[c,u]],[A,[c,u]]]),e})(),pi=function(e,t){var i=Fe.init[t],r=Fe.isIgnore[t]||0,o=Fe.isIgnoreRgx[t]||0,s=Fe.toString[t]||0;function n(){B.call(this,i)}return n.prototype.getItem=function(){return e},n.prototype.withClientHints=function(){return Q?Q.getHighEntropyValues(ht).then(function(f){return e.setCH(new Tt(f,!1)).parseCH().get()}):e.parseCH().get()},n.prototype.withFeatureCheck=function(){return e.detectFeature().get()},t!=ee&&(n.prototype.is=function(f){var h=!1;for(var g in this)if(this.hasOwnProperty(g)&&!Ye(r,g)&&j(o?oe(o,this[g]):this[g])==j(o?oe(o,f):f)){if(h=!0,f!=k.UNDEFINED)break}else if(f==k.UNDEFINED&&h){h=!h;break}return h},n.prototype.toString=function(){var f=Z;for(var h in s)typeof this[s[h]]!==k.UNDEFINED&&(f+=(f?" ":Z)+this[s[h]]);return f||k.UNDEFINED}),n.prototype.then=function(f){var h=this,g=function(){for(var y in h)h.hasOwnProperty(y)&&(this[y]=h[y])};g.prototype={is:n.prototype.is,toString:n.prototype.toString,withClientHints:n.prototype.withClientHints,withFeatureCheck:n.prototype.withFeatureCheck};var m=new g;return f(m),m},new n};function Tt(e,t){if(e=e||{},B.call(this,ht),t)B.call(this,[[ze,Ke(e[q])],[$e,Ke(e[ni])],[w,/\?1/.test(e[li])],[l,xe(e[ci])],[ie,xe(e[ft])],[Be,xe(e[di])],[E,xe(e[oi])],[Y,Ke(e[ai])],[Ce,xe(e[si])]]);else for(var i in e)this.hasOwnProperty(i)&&typeof e[i]!==k.UNDEFINED&&(this[i]=e[i])}function N(e,t,i,r){return B.call(this,[["itemType",e],["ua",t],["uaCH",r],["rgxMap",i],["data",pi(this,e)]]),this}N.prototype.get=function(e){return e?this.data.hasOwnProperty(e)?this.data[e]:void 0:this.data},N.prototype.set=function(e,t){return this.data[e]=t,this},N.prototype.setCH=function(e){return this.uaCH=e,this},N.prototype.detectFeature=function(){if(T&&T.userAgent==this.ua)switch(this.itemType){case I:T.brave&&typeof T.brave.isBrave==k.FUNCTION&&this.set(c,"Brave");break;case H:!this.get(a)&&Q&&Q[w]&&this.set(a,w),this.get(l)=="Macintosh"&&T&&typeof T.standalone!==k.UNDEFINED&&T.maxTouchPoints&&T.maxTouchPoints>2&&this.set(l,"iPad").set(a,v);break;case A:!this.get(c)&&Q&&Q[ie]&&this.set(c,Q[ie]);break;case ee:var e=this.data,t=function(i){return e[i].getItem().detectFeature().get()};this.set(I,t(I)).set($,t($)).set(H,t(H)).set(P,t(P)).set(A,t(A))}return this},N.prototype.parseUA=function(){switch(this.itemType!=ee&&Je.call(this.data,this.ua,this.rgxMap),this.itemType){case I:this.set(fe,Qe(this.get(u)));break;case A:if(this.get(c)=="iOS"&&this.get(u)=="18.6"){var e=/\) Version\/([\d\.]+)/.exec(this.ua);e&&parseInt(e[1].substring(0,2),10)>=26&&this.set(u,e[1])}break}return this},N.prototype.parseCH=function(){var e=this.uaCH,t=this.rgxMap;switch(this.itemType){case I:case P:var i=e[$e]||e[ze],r;if(i)for(var o=0;o<i.length;o++){var s=i[o].brand||i[o],n=i[o].version;this.itemType==I&&!/not.a.brand/i.test(s)&&(!r||/Chrom/.test(r)&&s!=kt||r==Te&&/WebView2/.test(s))&&(s=L(s,hi),r=this.get(c),r&&!/Chrom/.test(r)&&/Chrom/.test(s)||this.set(c,s).set(u,n).set(fe,Qe(n)),r=s),this.itemType==P&&s==kt&&this.set(u,n)}break;case $:var f=e[E];f&&(f&&e[Ce]=="64"&&(f+="64"),Je.call(this.data,f+";",t));break;case H:if(e[w]&&this.set(a,w),e[l]&&(this.set(l,e[l]),!this.get(a)||!this.get(d))){var h={};Je.call(h,"droid 9; "+e[l]+")",t),!this.get(a)&&h.type&&this.set(a,h.type),!this.get(d)&&h.vendor&&this.set(d,h.vendor)}if(e[Y]){var g;if(typeof e[Y]!="string")for(var m=0;!g&&m<e[Y].length;)g=L(e[Y][m++],Et);else g=L(e[Y],Et);this.set(a,g)}break;case A:var y=e[ie];if(y){var M=e[Be];y==Xe&&(M=parseInt(Qe(M),10)>=13?"11":"10"),this.set(c,y).set(u,M)}this.get(c)==Xe&&e[l]=="Xbox"&&this.set(c,"Xbox").set(u,void 0);break;case ee:var X=this.data,_=function(De){return X[De].getItem().setCH(e).parseCH().get()};this.set(I,_(I)).set($,_($)).set(H,_(H)).set(P,_(P)).set(A,_(A))}return this};function V(e,t,i){if(typeof e===k.OBJECT?(Me(e,!0)?(typeof t===k.OBJECT&&(i=t),t=e):(i=e,t=void 0),e=void 0):typeof e===k.STRING&&!Me(t,!0)&&(i=t,t=void 0),i)if(typeof i.append===k.FUNCTION){var r={};i.forEach(function(m,y){r[String(y).toLowerCase()]=m}),i=r}else{var o={};for(var s in i)i.hasOwnProperty(s)&&(o[String(s).toLowerCase()]=i[s]);i=o}if(!(this instanceof V))return new V(e,t,i).getResult();var n=typeof e===k.STRING?e:i&&i[dt]?i[dt]:T&&T.userAgent?T.userAgent:Z,f=new Tt(i,!0),h=t?fi(It,t):It,g=function(m){return m==ee?function(){return new N(m,n,h,f).set("ua",n).set(I,this.getBrowser()).set($,this.getCPU()).set(H,this.getDevice()).set(P,this.getEngine()).set(A,this.getOS()).get()}:function(){return new N(m,n,h[m],f).parseUA().get()}};return B.call(this,[["getBrowser",g(I)],["getCPU",g($)],["getDevice",g(H)],["getEngine",g(P)],["getOS",g(A)],["getResult",g(ee)],["getUA",function(){return n}],["setUA",function(m){return ye(m)&&(n=Ae(m,ri)),this}]]).setUA(n),this}V.VERSION=ii,V.BROWSER=Oe([c,u,fe,a]),V.CPU=Oe([E]),V.DEVICE=Oe([l,d,a,ke,w,C,v,U,he]),V.ENGINE=V.OS=Oe([c,u]);const bi=()=>{const t=new V().getResult();return{os:t.os.name||"unknown",osVersion:t.os.version||"unknown",browser:t.browser.name||"unknown",browserVersion:t.browser.version||"unknown",deviceType:t.device.type||"desktop"}};function gi(e,t){if(e.match(/^[a-z]+:\/\//i))return e;if(e.match(/^\/\//))return window.location.protocol+e;if(e.match(/^[a-z]+:/i))return e;const i=document.implementation.createHTMLDocument(),r=i.createElement("base"),o=i.createElement("a");return i.head.appendChild(r),i.body.appendChild(o),t&&(r.href=t),o.href=e,o.href}const wi=(()=>{let e=0;const t=()=>`0000${(Math.random()*36**4<<0).toString(36)}`.slice(-4);return()=>(e+=1,`u${t()}${e}`)})();function G(e){const t=[];for(let i=0,r=e.length;i<r;i++)t.push(e[i]);return t}let se=null;function Ot(e={}){return se||(e.includeStyleProperties?(se=e.includeStyleProperties,se):(se=G(window.getComputedStyle(document.documentElement)),se))}function _e(e,t){const r=(e.ownerDocument.defaultView||window).getComputedStyle(e).getPropertyValue(t);return r?parseFloat(r.replace("px","")):0}function mi(e){const t=_e(e,"border-left-width"),i=_e(e,"border-right-width");return e.clientWidth+t+i}function yi(e){const t=_e(e,"border-top-width"),i=_e(e,"border-bottom-width");return e.clientHeight+t+i}function Mt(e,t={}){const i=t.width||mi(e),r=t.height||yi(e);return{width:i,height:r}}function xi(){let e,t;try{t=process}catch{}const i=t&&t.env?t.env.devicePixelRatio:null;return i&&(e=parseInt(i,10),Number.isNaN(e)&&(e=1)),e||window.devicePixelRatio||1}const F=16384;function vi(e){(e.width>F||e.height>F)&&(e.width>F&&e.height>F?e.width>e.height?(e.height*=F/e.width,e.width=F):(e.width*=F/e.height,e.height=F):e.width>F?(e.height*=F/e.width,e.width=F):(e.width*=F/e.height,e.height=F))}function Pe(e){return new Promise((t,i)=>{const r=new Image;r.onload=()=>{r.decode().then(()=>{requestAnimationFrame(()=>t(r))})},r.onerror=i,r.crossOrigin="anonymous",r.decoding="async",r.src=e})}async function ki(e){return Promise.resolve().then(()=>new XMLSerializer().serializeToString(e)).then(encodeURIComponent).then(t=>`data:image/svg+xml;charset=utf-8,${t}`)}async function Si(e,t,i){const r="http://www.w3.org/2000/svg",o=document.createElementNS(r,"svg"),s=document.createElementNS(r,"foreignObject");return o.setAttribute("width",`${t}`),o.setAttribute("height",`${i}`),o.setAttribute("viewBox",`0 0 ${t} ${i}`),s.setAttribute("width","100%"),s.setAttribute("height","100%"),s.setAttribute("x","0"),s.setAttribute("y","0"),s.setAttribute("externalResourcesRequired","true"),o.appendChild(s),s.appendChild(e),ki(o)}const O=(e,t)=>{if(e instanceof t)return!0;const i=Object.getPrototypeOf(e);return i===null?!1:i.constructor.name===t.name||O(i,t)};function Ci(e){const t=e.getPropertyValue("content");return`${e.cssText} content: '${t.replace(/'|"/g,"")}';`}function Ei(e,t){return Ot(t).map(i=>{const r=e.getPropertyValue(i),o=e.getPropertyPriority(i);return`${i}: ${r}${o?" !important":""};`}).join(" ")}function Ii(e,t,i,r){const o=`.${e}:${t}`,s=i.cssText?Ci(i):Ei(i,r);return document.createTextNode(`${o}{${s}}`)}function At(e,t,i,r){const o=window.getComputedStyle(e,i),s=o.getPropertyValue("content");if(s===""||s==="none")return;const n=wi();try{t.className=`${t.className} ${n}`}catch{return}const f=document.createElement("style");f.appendChild(Ii(n,i,o,r)),t.appendChild(f)}function Ti(e,t,i){At(e,t,":before",i),At(e,t,":after",i)}const Ft="application/font-woff",_t="image/jpeg",Oi={woff:Ft,woff2:Ft,ttf:"application/font-truetype",eot:"application/vnd.ms-fontobject",png:"image/png",jpg:_t,jpeg:_t,gif:"image/gif",tiff:"image/tiff",svg:"image/svg+xml",webp:"image/webp"};function Mi(e){const t=/\.([^./]*?)$/g.exec(e);return t?t[1]:""}function Ze(e){const t=Mi(e).toLowerCase();return Oi[t]||""}function Ai(e){return e.split(/,/)[1]}function et(e){return e.search(/^(data:)/)!==-1}function Fi(e,t){return`data:${t};base64,${e}`}async function Pt(e,t,i){const r=await fetch(e,t);if(r.status===404)throw new Error(`Resource "${r.url}" not found`);const o=await r.blob();return new Promise((s,n)=>{const f=new FileReader;f.onerror=n,f.onloadend=()=>{try{s(i({res:r,result:f.result}))}catch(h){n(h)}},f.readAsDataURL(o)})}const tt={};function _i(e,t,i){let r=e.replace(/\?.*/,"");return i&&(r=e),/ttf|otf|eot|woff2?/i.test(r)&&(r=r.replace(/.*\//,"")),t?`[${t}]${r}`:r}async function it(e,t,i){const r=_i(e,t,i.includeQueryParams);if(tt[r]!=null)return tt[r];i.cacheBust&&(e+=(/\?/.test(e)?"&":"?")+new Date().getTime());let o;try{const s=await Pt(e,i.fetchRequestInit,({res:n,result:f})=>(t||(t=n.headers.get("Content-Type")||""),Ai(f)));o=Fi(s,t)}catch(s){o=i.imagePlaceholder||"";let n=`Failed to fetch resource: ${e}`;s&&(n=typeof s=="string"?s:s.message),n&&console.warn(n)}return tt[r]=o,o}async function Pi(e){const t=e.toDataURL();return t==="data:,"?e.cloneNode(!1):Pe(t)}async function Li(e,t){if(e.currentSrc){const s=document.createElement("canvas"),n=s.getContext("2d");s.width=e.clientWidth,s.height=e.clientHeight,n?.drawImage(e,0,0,s.width,s.height);const f=s.toDataURL();return Pe(f)}const i=e.poster,r=Ze(i),o=await it(i,r,t);return Pe(o)}async function Di(e,t){var i;try{if(!((i=e?.contentDocument)===null||i===void 0)&&i.body)return await Le(e.contentDocument.body,t,!0)}catch{}return e.cloneNode(!1)}async function Hi(e,t){return O(e,HTMLCanvasElement)?Pi(e):O(e,HTMLVideoElement)?Li(e,t):O(e,HTMLIFrameElement)?Di(e,t):e.cloneNode(Lt(e))}const Ui=e=>e.tagName!=null&&e.tagName.toUpperCase()==="SLOT",Lt=e=>e.tagName!=null&&e.tagName.toUpperCase()==="SVG";async function zi(e,t,i){var r,o;if(Lt(t))return t;let s=[];return Ui(e)&&e.assignedNodes?s=G(e.assignedNodes()):O(e,HTMLIFrameElement)&&(!((r=e.contentDocument)===null||r===void 0)&&r.body)?s=G(e.contentDocument.body.childNodes):s=G(((o=e.shadowRoot)!==null&&o!==void 0?o:e).childNodes),s.length===0||O(e,HTMLVideoElement)||await s.reduce((n,f)=>n.then(()=>Le(f,i)).then(h=>{h&&t.appendChild(h)}),Promise.resolve()),t}function $i(e,t,i){const r=t.style;if(!r)return;const o=window.getComputedStyle(e);o.cssText?(r.cssText=o.cssText,r.transformOrigin=o.transformOrigin):Ot(i).forEach(s=>{let n=o.getPropertyValue(s);s==="font-size"&&n.endsWith("px")&&(n=`${Math.floor(parseFloat(n.substring(0,n.length-2)))-.1}px`),O(e,HTMLIFrameElement)&&s==="display"&&n==="inline"&&(n="block"),s==="d"&&t.getAttribute("d")&&(n=`path(${t.getAttribute("d")})`),r.setProperty(s,n,o.getPropertyPriority(s))})}function Bi(e,t){O(e,HTMLTextAreaElement)&&(t.innerHTML=e.value),O(e,HTMLInputElement)&&t.setAttribute("value",e.value)}function Vi(e,t){if(O(e,HTMLSelectElement)){const r=Array.from(t.children).find(o=>e.value===o.getAttribute("value"));r&&r.setAttribute("selected","")}}function Wi(e,t,i){return O(t,Element)&&($i(e,t,i),Ti(e,t,i),Bi(e,t),Vi(e,t)),t}async function qi(e,t){const i=e.querySelectorAll?e.querySelectorAll("use"):[];if(i.length===0)return e;const r={};for(let s=0;s<i.length;s++){const f=i[s].getAttribute("xlink:href");if(f){const h=e.querySelector(f),g=document.querySelector(f);!h&&g&&!r[f]&&(r[f]=await Le(g,t,!0))}}const o=Object.values(r);if(o.length){const s="http://www.w3.org/1999/xhtml",n=document.createElementNS(s,"svg");n.setAttribute("xmlns",s),n.style.position="absolute",n.style.width="0",n.style.height="0",n.style.overflow="hidden",n.style.display="none";const f=document.createElementNS(s,"defs");n.appendChild(f);for(let h=0;h<o.length;h++)f.appendChild(o[h]);e.appendChild(n)}return e}async function Le(e,t,i){return!i&&t.filter&&!t.filter(e)?null:Promise.resolve(e).then(r=>Hi(r,t)).then(r=>zi(e,r,t)).then(r=>Wi(e,r,t)).then(r=>qi(r,t))}const Dt=/url\((['"]?)([^'"]+?)\1\)/g,Ri=/url\([^)]+\)\s*format\((["']?)([^"']+)\1\)/g,ji=/src:\s*(?:url\([^)]+\)\s*format\([^)]+\)[,;]\s*)+/g;function Ni(e){const t=e.replace(/([.*+?^${}()|\[\]\/\\])/g,"\\$1");return new RegExp(`(url\\(['"]?)(${t})(['"]?\\))`,"g")}function Gi(e){const t=[];return e.replace(Dt,(i,r,o)=>(t.push(o),i)),t.filter(i=>!et(i))}async function Xi(e,t,i,r,o){try{const s=i?gi(t,i):t,n=Ze(t);let f;return o||(f=await it(s,n,r)),e.replace(Ni(t),`$1${f}$3`)}catch{}return e}function Yi(e,{preferredFontFormat:t}){return t?e.replace(ji,i=>{for(;;){const[r,,o]=Ri.exec(i)||[];if(!o)return"";if(o===t)return`src: ${r};`}}):e}function Ht(e){return e.search(Dt)!==-1}async function Ut(e,t,i){if(!Ht(e))return e;const r=Yi(e,i);return Gi(r).reduce((s,n)=>s.then(f=>Xi(f,n,t,i)),Promise.resolve(r))}async function ae(e,t,i){var r;const o=(r=t.style)===null||r===void 0?void 0:r.getPropertyValue(e);if(o){const s=await Ut(o,null,i);return t.style.setProperty(e,s,t.style.getPropertyPriority(e)),!0}return!1}async function Ki(e,t){await ae("background",e,t)||await ae("background-image",e,t),await ae("mask",e,t)||await ae("-webkit-mask",e,t)||await ae("mask-image",e,t)||await ae("-webkit-mask-image",e,t)}async function Qi(e,t){const i=O(e,HTMLImageElement);if(!(i&&!et(e.src))&&!(O(e,SVGImageElement)&&!et(e.href.baseVal)))return;const r=i?e.src:e.href.baseVal,o=await it(r,Ze(r),t);await new Promise((s,n)=>{e.onload=s,e.onerror=t.onImageErrorHandler?(...h)=>{try{s(t.onImageErrorHandler(...h))}catch(g){n(g)}}:n;const f=e;f.decode&&(f.decode=s),f.loading==="lazy"&&(f.loading="eager"),i?(e.srcset="",e.src=o):e.href.baseVal=o})}async function Ji(e,t){const r=G(e.childNodes).map(o=>zt(o,t));await Promise.all(r).then(()=>e)}async function zt(e,t){O(e,Element)&&(await Ki(e,t),await Qi(e,t),await Ji(e,t))}function Zi(e,t){const{style:i}=e;t.backgroundColor&&(i.backgroundColor=t.backgroundColor),t.width&&(i.width=`${t.width}px`),t.height&&(i.height=`${t.height}px`);const r=t.style;return r!=null&&Object.keys(r).forEach(o=>{i[o]=r[o]}),e}const $t={};async function Bt(e){let t=$t[e];if(t!=null)return t;const r=await(await fetch(e)).text();return t={url:e,cssText:r},$t[e]=t,t}async function Vt(e,t){let i=e.cssText;const r=/url\(["']?([^"')]+)["']?\)/g,s=(i.match(/url\([^)]+\)/g)||[]).map(async n=>{let f=n.replace(r,"$1");return f.startsWith("https://")||(f=new URL(f,e.url).href),Pt(f,t.fetchRequestInit,({result:h})=>(i=i.replace(n,`url(${h})`),[n,h]))});return Promise.all(s).then(()=>i)}function Wt(e){if(e==null)return[];const t=[],i=/(\/\*[\s\S]*?\*\/)/gi;let r=e.replace(i,"");const o=new RegExp("((@.*?keyframes [\\s\\S]*?){([\\s\\S]*?}\\s*?)})","gi");for(;;){const h=o.exec(r);if(h===null)break;t.push(h[0])}r=r.replace(o,"");const s=/@import[\s\S]*?url\([^)]*\)[\s\S]*?;/gi,n="((\\s*?(?:\\/\\*[\\s\\S]*?\\*\\/)?\\s*?@media[\\s\\S]*?){([\\s\\S]*?)}\\s*?})|(([\\s\\S]*?){([\\s\\S]*?)})",f=new RegExp(n,"gi");for(;;){let h=s.exec(r);if(h===null){if(h=f.exec(r),h===null)break;s.lastIndex=f.lastIndex}else f.lastIndex=s.lastIndex;t.push(h[0])}return t}async function er(e,t){const i=[],r=[];return e.forEach(o=>{if("cssRules"in o)try{G(o.cssRules||[]).forEach((s,n)=>{if(s.type===CSSRule.IMPORT_RULE){let f=n+1;const h=s.href,g=Bt(h).then(m=>Vt(m,t)).then(m=>Wt(m).forEach(y=>{try{o.insertRule(y,y.startsWith("@import")?f+=1:o.cssRules.length)}catch(M){console.error("Error inserting rule from remote css",{rule:y,error:M})}})).catch(m=>{console.error("Error loading remote css",m.toString())});r.push(g)}})}catch(s){const n=e.find(f=>f.href==null)||document.styleSheets[0];o.href!=null&&r.push(Bt(o.href).then(f=>Vt(f,t)).then(f=>Wt(f).forEach(h=>{n.insertRule(h,n.cssRules.length)})).catch(f=>{console.error("Error loading remote stylesheet",f)})),console.error("Error inlining remote css file",s)}}),Promise.all(r).then(()=>(e.forEach(o=>{if("cssRules"in o)try{G(o.cssRules||[]).forEach(s=>{i.push(s)})}catch(s){console.error(`Error while reading CSS rules from ${o.href}`,s)}}),i))}function tr(e){return e.filter(t=>t.type===CSSRule.FONT_FACE_RULE).filter(t=>Ht(t.style.getPropertyValue("src")))}async function ir(e,t){if(e.ownerDocument==null)throw new Error("Provided element is not within a Document");const i=G(e.ownerDocument.styleSheets),r=await er(i,t);return tr(r)}function qt(e){return e.trim().replace(/["']/g,"")}function rr(e){const t=new Set;function i(r){(r.style.fontFamily||getComputedStyle(r).fontFamily).split(",").forEach(s=>{t.add(qt(s))}),Array.from(r.children).forEach(s=>{s instanceof HTMLElement&&i(s)})}return i(e),t}async function nr(e,t){const i=await ir(e,t),r=rr(e);return(await Promise.all(i.filter(s=>r.has(qt(s.style.fontFamily))).map(s=>{const n=s.parentStyleSheet?s.parentStyleSheet.href:null;return Ut(s.cssText,n,t)}))).join(`
|
|
2
|
+
`)}async function or(e,t){const i=t.fontEmbedCSS!=null?t.fontEmbedCSS:t.skipFonts?null:await nr(e,t);if(i){const r=document.createElement("style"),o=document.createTextNode(i);r.appendChild(o),e.firstChild?e.insertBefore(r,e.firstChild):e.appendChild(r)}}async function sr(e,t={}){const{width:i,height:r}=Mt(e,t),o=await Le(e,t,!0);return await or(o,t),await zt(o,t),Zi(o,t),await Si(o,i,r)}async function ar(e,t={}){const{width:i,height:r}=Mt(e,t),o=await sr(e,t),s=await Pe(o),n=document.createElement("canvas"),f=n.getContext("2d"),h=t.pixelRatio||xi(),g=t.canvasWidth||i,m=t.canvasHeight||r;return n.width=g*h,n.height=m*h,t.skipAutoScale||vi(n),n.style.width=`${g}`,n.style.height=`${m}`,t.backgroundColor&&(f.fillStyle=t.backgroundColor,f.fillRect(0,0,n.width,n.height)),f.drawImage(s,0,0,n.width,n.height),n}async function lr(e,t={}){return(await ar(e,t)).toDataURL()}const cr=async(e=document.body)=>{try{return await lr(e,{quality:.9,pixelRatio:1,cacheBust:!0,skipAutoScale:!0})}catch(t){return console.error("Screenshot capture failed:",t),null}},dr=(e,t)=>new Promise((i,r)=>{const o=new Image;o.onload=()=>{const s=document.documentElement,n=s.scrollWidth,f=s.scrollHeight,h=n?o.naturalWidth/n:1,g=f?o.naturalHeight/f:1,m=document.createElement("canvas");m.width=t.width*h,m.height=t.height*g;const y=m.getContext("2d");if(!y){r(new Error("Could not get canvas context"));return}y.drawImage(o,t.x*h,t.y*g,t.width*h,t.height*g,0,0,m.width,m.height),i(m.toDataURL("image/png",.9))},o.onerror=r,o.src=e});const ur=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),fr=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(t,i,r)=>r?r.toUpperCase():i.toLowerCase()),Rt=e=>{const t=fr(e);return t.charAt(0).toUpperCase()+t.slice(1)},jt=(...e)=>e.filter((t,i,r)=>!!t&&t.trim()!==""&&r.indexOf(t)===i).join(" ").trim(),hr=e=>{for(const t in e)if(t.startsWith("aria-")||t==="role"||t==="title")return!0};var pr={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};const br=x.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:i=2,absoluteStrokeWidth:r,className:o="",children:s,iconNode:n,...f},h)=>x.createElement("svg",{ref:h,...pr,width:t,height:t,stroke:e,strokeWidth:r?Number(i)*24/Number(t):i,className:jt("lucide",o),...!s&&!hr(f)&&{"aria-hidden":"true"},...f},[...n.map(([g,m])=>x.createElement(g,m)),...Array.isArray(s)?s:[s]]));const le=(e,t)=>{const i=x.forwardRef(({className:r,...o},s)=>x.createElement(br,{ref:s,iconNode:t,className:jt(`lucide-${ur(Rt(e))}`,`lucide-${e}`,r),...o}));return i.displayName=Rt(e),i};const gr=le("crop",[["path",{d:"M6 2v14a2 2 0 0 0 2 2h14",key:"ron5a4"}],["path",{d:"M18 22V8a2 2 0 0 0-2-2H2",key:"7s9ehn"}]]);const Nt=le("hash",[["line",{x1:"4",x2:"20",y1:"9",y2:"9",key:"4lhtct"}],["line",{x1:"4",x2:"20",y1:"15",y2:"15",key:"vyu0kd"}],["line",{x1:"10",x2:"8",y1:"3",y2:"21",key:"1ggp8o"}],["line",{x1:"16",x2:"14",y1:"3",y2:"21",key:"weycgp"}]]);const wr=le("message-square-plus",[["path",{d:"M22 17a2 2 0 0 1-2 2H6.828a2 2 0 0 0-1.414.586l-2.202 2.202A.71.71 0 0 1 2 21.286V5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2z",key:"18887p"}],["path",{d:"M12 8v6",key:"1ib9pf"}],["path",{d:"M9 11h6",key:"1fldmi"}]]);const mr=le("monitor",[["rect",{width:"20",height:"14",x:"2",y:"3",rx:"2",key:"48i651"}],["line",{x1:"8",x2:"16",y1:"21",y2:"21",key:"1svkeh"}],["line",{x1:"12",x2:"12",y1:"17",y2:"21",key:"vw1qmm"}]]);const yr=le("text-align-start",[["path",{d:"M21 5H3",key:"1fi0y6"}],["path",{d:"M15 12H3",key:"6jk70r"}],["path",{d:"M17 19H3",key:"z6ezky"}]]);const Gt=le("x",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]),xr=({onConfirm:e,onCancel:t})=>{const[i,r]=x.useState(!1),[o,s]=x.useState({x:0,y:0}),[n,f]=x.useState({x:0,y:0}),h=y=>{r(!0),s({x:y.clientX,y:y.clientY}),f({x:y.clientX,y:y.clientY})},g=y=>{i&&f({x:y.clientX,y:y.clientY})},m=()=>{if(i){r(!1);const y=Math.min(o.x,n.x),M=Math.min(o.y,n.y),X=Math.abs(n.x-o.x),_=Math.abs(n.y-o.y);X>10&&_>10&&e({x:y+window.scrollX,y:M+window.scrollY,width:X,height:_})}};return x.useEffect(()=>{const y=M=>{M.key==="Escape"&&t()};return window.addEventListener("keydown",y),()=>window.removeEventListener("keydown",y)},[t]),p.jsxs("div",{style:{position:"fixed",inset:0,zIndex:99999,cursor:"crosshair",userSelect:"none"},onMouseDown:h,onMouseMove:g,onMouseUp:m,children:[p.jsx("div",{style:{position:"absolute",inset:0,backgroundColor:"rgba(0, 0, 0, 0.4)"}}),!i&&p.jsx("div",{style:{position:"absolute",top:"20px",left:"50%",transform:"translateX(-50%)",background:"rgba(0,0,0,0.8)",color:"white",padding:"8px 16px",borderRadius:"20px",pointerEvents:"none",fontSize:"14px"},children:"Kéo chuột để chọn vùng chụp ảnh (ESC để hủy)"}),i&&p.jsx("div",{style:{position:"absolute",left:Math.min(o.x,n.x),top:Math.min(o.y,n.y),width:Math.abs(n.x-o.x),height:Math.abs(n.y-o.y),border:"2px solid #fff",backgroundColor:"rgba(255, 255, 255, 0.1)",boxShadow:"0 0 0 9999px rgba(0, 0, 0, 0.5)"}})]})},Xt=({questionId:e,questionIdChild:t,contextData:i,onSubmit:r,themeColor:o="#3b82f6",triggerComponent:s,isOpen:n,onOpen:f,onClose:h})=>{const[g,m]=x.useState(!1),[y,M]=x.useState(""),[X,_]=x.useState(e),[De,rt]=x.useState(t||""),[ce,He]=x.useState([]),[nt,ot]=x.useState(null),[Sr,Kt]=x.useState(!1),[J,Qt]=x.useState(!1),[Jt,Ue]=x.useState(!1),[W,de]=x.useState(null),[z,ue]=x.useState({}),[Zt,st]=x.useState("incorrect_content"),[Cr,at]=x.useState(!1),lt=n!==void 0?n:g,Er=lt&&!Cr;x.useEffect(()=>{lt&&(ue({}),_(e),rt(t||""))},[lt,e,t]);const Ir=()=>{He([]),M(""),_(e),rt(t||""),st("incorrect_content"),ue({}),n===void 0&&m(!0)},ei=async b=>{if(ce.length>=3){alert("Bạn chỉ có thể chụp tối đa 3 ảnh.");return}if(at(!0),b==="crop"){setTimeout(()=>Ue(!0),150);return}setTimeout(async()=>{await ti()},150)},ti=async b=>{Kt(!0);try{let S=await cr();S&&b&&(S=await dr(S,b)),S?He(ve=>[...ve,S]):alert("Không thể chụp ảnh màn hình. Vui lòng thử lại.")}catch(S){console.error(S)}finally{Kt(!1),at(!1)}},Tr=b=>{Ue(!1),ti(b)},Or=()=>{Ue(!1),at(!1)},Mr=b=>{He(S=>S.filter((ve,Fr)=>Fr!==b))},ct=()=>{h&&h(),m(!1),He([]),Ue(!1),ot(null),ue({}),st("incorrect_content")},Ar=async()=>{const b={};if(X||(b.questionId="Vui lòng nhập ID câu hỏi"),y.trim()||(b.description="Vui lòng nhập mô tả lỗi"),Object.keys(b).length>0){ue(b);return}Qt(!0);try{const S=bi();await r({idQuestion:X,idChildQuestion:De,errorType:Zt,errorDescription:y,listImage:ce,deviceInfo:S,contextData:i}),ct()}catch(S){console.error("Submit feedback failed",S)}finally{Qt(!1)}};return p.jsxs(p.Fragment,{children:[p.jsx("style",{id:"feedback-widget-styles",children:`
|
|
3
3
|
@keyframes fb-fade-in {
|
|
4
4
|
from { opacity: 0; transform: translateY(10px); }
|
|
5
5
|
to { opacity: 1; transform: translateY(0); }
|
|
@@ -38,4 +38,4 @@
|
|
|
38
38
|
height: 44px !important;
|
|
39
39
|
}
|
|
40
40
|
}
|
|
41
|
-
`}),Jt&&p.jsx(xr,{onConfirm:Tr,onCancel:Or}),nt&&p.jsx("div",{style:{position:"fixed",inset:0,backgroundColor:"rgba(0,0,0,0.8)",zIndex:1e4,display:"flex",alignItems:"center",justifyContent:"center",cursor:"zoom-out",animation:"fb-fade-in 0.2s ease-out",backdropFilter:"blur(4px)"},onClick:()=>ot(null),children:p.jsx("img",{src:nt,alt:"Zoomed",draggable:!1,onContextMenu:b=>b.preventDefault(),style:{maxWidth:"90vw",maxHeight:"90vh",objectFit:"contain",borderRadius:"8px",boxShadow:"0 20px 25px -5px rgba(0, 0, 0, 0.1)",backgroundColor:"white",userSelect:"none",WebkitUserSelect:"none"}})}),p.jsx("div",{onClick:()=>{n===void 0?Ir():h&&h()},style:{cursor:"pointer",display:"inline-block"},children:s||p.jsx("button",{className:"fb-widget-trigger",style:{position:"fixed",bottom:"24px",right:"24px",backgroundColor:o,color:"white",border:"none",borderRadius:"50%",width:"48px",height:"48px",display:"flex",alignItems:"center",justifyContent:"center",boxShadow:"0 4px 12px rgba(0,0,0,0.15)",cursor:"pointer",zIndex:9990,transition:"transform 0.2s"},title:"Báo lỗi",onMouseEnter:b=>b.currentTarget.style.transform="scale(1.1)",onMouseLeave:b=>b.currentTarget.style.transform="scale(1)",children:p.jsx(wr,{size:24})})}),Sr&&p.jsx("div",{style:{position:"fixed",top:20,right:20,background:"rgba(0,0,0,0.8)",color:"white",padding:"8px 12px",borderRadius:"8px",zIndex:1e4,fontWeight:500,backdropFilter:"blur(4px)",fontSize:"0.8rem"},children:"Đang chụp..."}),Er&&!Jt&&!nt&&p.jsxs("div",{className:"fb-widget-modal",children:[p.jsxs("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center"},children:[p.jsx("h2",{style:{margin:0,fontSize:"1rem",fontWeight:700,color:"#111827"},children:"Báo lỗi"}),p.jsx("button",{onClick:ct,style:{background:"transparent",border:"none",cursor:"pointer",color:"#6b7280",padding:"4px",display:"flex",alignItems:"center",justifyContent:"center",borderRadius:"50%",transition:"background-color 0.2s"},onMouseEnter:b=>b.currentTarget.style.backgroundColor="#f3f4f6",onMouseLeave:b=>b.currentTarget.style.backgroundColor="transparent",children:p.jsx(Gt,{size:18})})]}),p.jsxs("div",{style:{display:"flex",flexDirection:"column",gap:"10px"},children:[p.jsxs("div",{children:[p.jsxs("label",{style:{display:"block",marginBottom:"2px",fontSize:"0.8rem",fontWeight:600,color:"#374151"},children:["ID Câu hỏi ",p.jsx("span",{style:{color:"#ef4444"},children:"*"})]}),p.jsxs("div",{style:{position:"relative",display:"flex",alignItems:"center",transition:"all 0.2s"},children:[p.jsx(Nt,{size:12,style:{position:"absolute",left:"10px",color:W==="id"?o:z.questionId?"#ef4444":"#9ca3af",transition:"color 0.2s",pointerEvents:"none"}}),p.jsx("input",{type:"text",value:X,onFocus:()=>de("id"),onBlur:()=>de(null),onChange:b=>{_(b.target.value),z.questionId&&ue(S=>({...S,questionId:void 0}))},placeholder:"Nhập ID (ví dụ: 101)",style:{width:"100%",padding:"6px 10px 6px 28px",borderRadius:"6px",border:`1px solid ${z.questionId?"#ef4444":W==="id"?o:"#e5e7eb"}`,boxShadow:W==="id"?`0 0 0 2px ${o}20`:"none",outline:"none",fontSize:"0.85rem",color:"#1f2937",transition:"all 0.2s",backgroundColor:"#f9fafb"}})]}),z.questionId&&p.jsx("span",{style:{display:"block",marginTop:"2px",fontSize:"0.7rem",color:"#ef4444"},children:z.questionId})]}),p.jsxs("div",{children:[p.jsx("label",{style:{display:"block",marginBottom:"2px",fontSize:"0.8rem",fontWeight:600,color:"#374151"},children:"ID Câu hỏi con"}),p.jsxs("div",{style:{position:"relative",display:"flex",alignItems:"center",transition:"all 0.2s"},children:[p.jsx(Nt,{size:12,style:{position:"absolute",left:"10px",color:W==="idChild"?o:"#9ca3af",transition:"color 0.2s",pointerEvents:"none"}}),p.jsx("input",{type:"text",value:De,onFocus:()=>de("idChild"),onBlur:()=>de(null),onChange:b=>{rt(b.target.value)},placeholder:"Nhập ID (ví dụ: 101)",style:{width:"100%",padding:"6px 10px 6px 28px",borderRadius:"6px",border:`1px solid ${W==="idChild"?o:"#e5e7eb"}`,boxShadow:W==="idChild"?`0 0 0 2px ${o}20`:"none",outline:"none",fontSize:"0.85rem",color:"#1f2937",transition:"all 0.2s",backgroundColor:"#f9fafb"}})]})]}),p.jsxs("div",{children:[p.jsxs("label",{style:{display:"block",marginBottom:"2px",fontSize:"0.8rem",fontWeight:600,color:"#374151"},children:["Loại lỗi ",p.jsx("span",{style:{color:"#ef4444"},children:"*"})]}),p.jsxs("select",{value:Zt,onChange:b=>st(b.target.value),style:{width:"100%",padding:"6px 10px",borderRadius:"6px",border:"1px solid #e5e7eb",backgroundColor:"#f9fafb",fontSize:"0.85rem",color:"#1f2937",outline:"none",cursor:"pointer",appearance:"none",backgroundImage:`url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'/%3e%3c/svg%3e")`,backgroundRepeat:"no-repeat",backgroundPosition:"right 10px center",backgroundSize:"14px"},children:[p.jsx("option",{value:"incorrect_content",children:"Lỗi nội dung"}),p.jsx("option",{value:"display_error",children:"Lỗi hiển thị"}),p.jsx("option",{value:"missing_data",children:"Thiếu thông tin"}),p.jsx("option",{value:"technical_issue",children:"Lỗi kỹ thuật"}),p.jsx("option",{value:"other",children:"Khác"})]})]}),p.jsxs("div",{children:[p.jsxs("label",{style:{display:"block",marginBottom:"2px",fontSize:"0.8rem",fontWeight:600,color:"#374151"},children:["Mô tả lỗi ",p.jsx("span",{style:{color:"#ef4444"},children:"*"})]}),p.jsxs("div",{style:{position:"relative"},children:[p.jsx("div",{style:{position:"absolute",left:"10px",top:"8px",pointerEvents:"none"},children:p.jsx(yr,{size:12,style:{color:W==="desc"?o:z.description?"#ef4444":"#9ca3af",transition:"color 0.2s"}})}),p.jsx("textarea",{value:y,onFocus:()=>de("desc"),onBlur:()=>de(null),onChange:b=>{M(b.target.value),z.description&&ue(S=>({...S,description:void 0}))},placeholder:"Mô tả chi tiết...",style:{width:"100%",minHeight:"60px",padding:"6px 10px 6px 28px",borderRadius:"6px",border:`1px solid ${z.description?"#ef4444":W==="desc"?o:"#e5e7eb"}`,boxShadow:W==="desc"?`0 0 0 2px ${o}20`:"none",outline:"none",fontSize:"0.85rem",color:"#1f2937",resize:"vertical",boxSizing:"border-box",transition:"all 0.2s",backgroundColor:"#f9fafb",lineHeight:"1.4",fontFamily:"inherit"}})]}),z.description&&p.jsx("span",{style:{display:"block",marginTop:"2px",fontSize:"0.7rem",color:"#ef4444"},children:z.description})]})]}),p.jsxs("div",{style:{marginBottom:"2px"},children:[p.jsx("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center",marginBottom:"6px"},children:p.jsxs("label",{style:{fontWeight:600,fontSize:"0.8rem",color:"#374151"},children:["Ảnh chụp (",ce.length,"/3)"]})}),ce.length>0&&p.jsx("div",{style:{display:"grid",gridTemplateColumns:"repeat(3, 1fr)",gap:"6px",marginBottom:"8px"},children:ce.map((b,S)=>p.jsxs("div",{style:{position:"relative",aspectRatio:"16/9",border:"1px solid #e5e7eb",borderRadius:"6px",overflow:"hidden",boxShadow:"0 1px 2px rgba(0,0,0,0.05)"},children:[p.jsx("img",{src:b,alt:`Screenshot ${S+1}`,draggable:!1,onContextMenu:ve=>ve.preventDefault(),style:{width:"100%",height:"100%",objectFit:"cover",cursor:"zoom-in",transition:"transform 0.2s",userSelect:"none",WebkitUserSelect:"none"},onClick:()=>ot(b)}),p.jsx("button",{onClick:()=>Mr(S),title:"Xóa ảnh",style:{position:"absolute",top:"2px",right:"2px",background:"rgba(239, 68, 68, 0.9)",color:"white",border:"none",borderRadius:"50%",width:"16px",height:"16px",display:"flex",alignItems:"center",justifyContent:"center",cursor:"pointer",padding:0,boxShadow:"0 1px 2px rgba(0,0,0,0.2)"},children:p.jsx(Gt,{size:10})})]},S))}),ce.length<3&&p.jsxs("div",{style:{display:"flex",gap:"8px"},children:[p.jsxs("button",{onClick:()=>ei("full"),style:{flex:1,padding:"12px",textAlign:"center",background:"white",border:"1px dashed #d1d5db",borderRadius:"8px",color:"#4b5563",cursor:"pointer",display:"flex",flexDirection:"column",alignItems:"center",gap:"4px",transition:"all 0.2s"},onMouseOver:b=>{b.currentTarget.style.borderColor=o,b.currentTarget.style.color=o,b.currentTarget.style.backgroundColor="#f9fafb"},onMouseOut:b=>{b.currentTarget.style.borderColor="#d1d5db",b.currentTarget.style.color="#4b5563",b.currentTarget.style.backgroundColor="white"},children:[p.jsx(mr,{size:18}),p.jsx("span",{style:{fontSize:"0.8rem",fontWeight:500},children:"Toàn màn hình"})]}),p.jsxs("button",{onClick:()=>ei("crop"),style:{flex:1,padding:"12px",textAlign:"center",background:"white",border:"1px dashed #d1d5db",borderRadius:"8px",color:"#4b5563",cursor:"pointer",display:"flex",flexDirection:"column",alignItems:"center",gap:"4px",transition:"all 0.2s"},onMouseOver:b=>{b.currentTarget.style.borderColor=o,b.currentTarget.style.color=o,b.currentTarget.style.backgroundColor="#f9fafb"},onMouseOut:b=>{b.currentTarget.style.borderColor="#d1d5db",b.currentTarget.style.color="#4b5563",b.currentTarget.style.backgroundColor="white"},children:[p.jsx(gr,{size:18}),p.jsx("span",{style:{fontSize:"0.8rem",fontWeight:500},children:"Chọn vùng"})]})]})]}),p.jsxs("div",{style:{display:"flex",justifyContent:"flex-end",gap:"8px",marginTop:"auto",paddingTop:"8px",borderTop:"1px solid #f3f4f6"},children:[p.jsx("button",{onClick:ct,disabled:J,style:{padding:"8px 16px",borderRadius:"8px",border:"1px solid #d1d5db",background:"white",cursor:"pointer",color:"#374151",fontWeight:500,fontSize:"0.85rem",transition:"background-color 0.2s"},onMouseEnter:b=>b.currentTarget.style.background="#f9fafb",onMouseLeave:b=>b.currentTarget.style.background="white",children:"Hủy bỏ"}),p.jsx("button",{onClick:Ar,disabled:J,style:{padding:"8px 16px",borderRadius:"8px",border:"none",background:o,color:"white",cursor:J?"not-allowed":"pointer",fontWeight:600,fontSize:"0.85rem",opacity:J?.7:1,boxShadow:"0 2px 4px -1px rgba(0, 0, 0, 0.1)",transition:"transform 0.1s, opacity 0.2s"},onMouseDown:b=>!J&&(b.currentTarget.style.transform="scale(0.98)"),onMouseUp:b=>!J&&(b.currentTarget.style.transform="scale(1)"),children:J?"Đang gửi...":"Gửi báo lỗi"})]})]})]})},Yt=x.createContext(void 0),vr=()=>{const e=x.useContext(Yt);if(!e)throw new Error("useFeedback must be used within a FeedbackProvider");return e},kr=({children:e,onSubmit:t,themeColor:i})=>{const[r,o]=x.useState(!1),[s,n]=x.useState(null),[h,f]=x.useState(void 0),g=(y,M)=>{n(y),f(M),o(!0)},m=()=>{o(!1)};return p.jsxs(Yt.Provider,{value:{openFeedback:g,closeFeedback:m,isOpen:r,activeQuestionId:s},children:[e,s&&p.jsx(Xt,{questionId:s,contextData:h,onSubmit:t,themeColor:i,isOpen:r,onClose:m,triggerComponent:p.jsx(p.Fragment,{})})]})};D.FeedbackProvider=kr,D.FeedbackWidget=Xt,D.useFeedback=vr,Object.defineProperty(D,Symbol.toStringTag,{value:"Module"})}));
|
|
41
|
+
`}),Jt&&p.jsx(xr,{onConfirm:Tr,onCancel:Or}),nt&&p.jsx("div",{style:{position:"fixed",inset:0,backgroundColor:"rgba(0,0,0,0.8)",zIndex:1e4,display:"flex",alignItems:"center",justifyContent:"center",cursor:"zoom-out",animation:"fb-fade-in 0.2s ease-out",backdropFilter:"blur(4px)"},onClick:()=>ot(null),children:p.jsx("img",{src:nt,alt:"Zoomed",draggable:!1,onContextMenu:b=>b.preventDefault(),style:{maxWidth:"90vw",maxHeight:"90vh",objectFit:"contain",borderRadius:"8px",boxShadow:"0 20px 25px -5px rgba(0, 0, 0, 0.1)",backgroundColor:"white",userSelect:"none",WebkitUserSelect:"none"}})}),p.jsx("div",{onClick:()=>{n===void 0?Ir():f&&f()},style:{cursor:"pointer",display:"inline-block"},children:s||p.jsx("button",{className:"fb-widget-trigger",style:{position:"fixed",bottom:"24px",right:"24px",backgroundColor:o,color:"white",border:"none",borderRadius:"50%",width:"48px",height:"48px",display:"flex",alignItems:"center",justifyContent:"center",boxShadow:"0 4px 12px rgba(0,0,0,0.15)",cursor:"pointer",zIndex:9990,transition:"transform 0.2s"},title:"Báo lỗi",onMouseEnter:b=>b.currentTarget.style.transform="scale(1.1)",onMouseLeave:b=>b.currentTarget.style.transform="scale(1)",children:p.jsx(wr,{size:24})})}),Sr&&p.jsx("div",{style:{position:"fixed",top:20,right:20,background:"rgba(0,0,0,0.8)",color:"white",padding:"8px 12px",borderRadius:"8px",zIndex:1e4,fontWeight:500,backdropFilter:"blur(4px)",fontSize:"0.8rem"},children:"Đang chụp..."}),Er&&!Jt&&!nt&&p.jsxs("div",{className:"fb-widget-modal",children:[p.jsxs("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center"},children:[p.jsx("h2",{style:{margin:0,fontSize:"1rem",fontWeight:700,color:"#111827"},children:"Báo lỗi"}),p.jsx("button",{onClick:ct,style:{background:"transparent",border:"none",cursor:"pointer",color:"#6b7280",padding:"4px",display:"flex",alignItems:"center",justifyContent:"center",borderRadius:"50%",transition:"background-color 0.2s"},onMouseEnter:b=>b.currentTarget.style.backgroundColor="#f3f4f6",onMouseLeave:b=>b.currentTarget.style.backgroundColor="transparent",children:p.jsx(Gt,{size:18})})]}),p.jsxs("div",{style:{display:"flex",flexDirection:"column",gap:"10px"},children:[p.jsxs("div",{children:[p.jsxs("label",{style:{display:"block",marginBottom:"2px",fontSize:"0.8rem",fontWeight:600,color:"#374151"},children:["ID Câu hỏi ",p.jsx("span",{style:{color:"#ef4444"},children:"*"})]}),p.jsxs("div",{style:{position:"relative",display:"flex",alignItems:"center",transition:"all 0.2s"},children:[p.jsx(Nt,{size:12,style:{position:"absolute",left:"10px",color:W==="id"?o:z.questionId?"#ef4444":"#9ca3af",transition:"color 0.2s",pointerEvents:"none"}}),p.jsx("input",{type:"text",value:X,onFocus:()=>de("id"),onBlur:()=>de(null),onChange:b=>{_(b.target.value),z.questionId&&ue(S=>({...S,questionId:void 0}))},placeholder:"Nhập ID (ví dụ: 101)",style:{width:"100%",padding:"6px 10px 6px 28px",borderRadius:"6px",border:`1px solid ${z.questionId?"#ef4444":W==="id"?o:"#e5e7eb"}`,boxShadow:W==="id"?`0 0 0 2px ${o}20`:"none",outline:"none",fontSize:"0.85rem",color:"#1f2937",transition:"all 0.2s",backgroundColor:"#f9fafb"}})]}),z.questionId&&p.jsx("span",{style:{display:"block",marginTop:"2px",fontSize:"0.7rem",color:"#ef4444"},children:z.questionId})]}),p.jsxs("div",{children:[p.jsx("label",{style:{display:"block",marginBottom:"2px",fontSize:"0.8rem",fontWeight:600,color:"#374151"},children:"ID Câu hỏi con"}),p.jsxs("div",{style:{position:"relative",display:"flex",alignItems:"center",transition:"all 0.2s"},children:[p.jsx(Nt,{size:12,style:{position:"absolute",left:"10px",color:W==="idChild"?o:"#9ca3af",transition:"color 0.2s",pointerEvents:"none"}}),p.jsx("input",{type:"text",value:De,onFocus:()=>de("idChild"),onBlur:()=>de(null),onChange:b=>{rt(b.target.value)},placeholder:"Nhập ID (ví dụ: 101)",style:{width:"100%",padding:"6px 10px 6px 28px",borderRadius:"6px",border:`1px solid ${W==="idChild"?o:"#e5e7eb"}`,boxShadow:W==="idChild"?`0 0 0 2px ${o}20`:"none",outline:"none",fontSize:"0.85rem",color:"#1f2937",transition:"all 0.2s",backgroundColor:"#f9fafb"}})]})]}),p.jsxs("div",{children:[p.jsxs("label",{style:{display:"block",marginBottom:"2px",fontSize:"0.8rem",fontWeight:600,color:"#374151"},children:["Loại lỗi ",p.jsx("span",{style:{color:"#ef4444"},children:"*"})]}),p.jsxs("select",{value:Zt,onChange:b=>st(b.target.value),style:{width:"100%",padding:"6px 10px",borderRadius:"6px",border:"1px solid #e5e7eb",backgroundColor:"#f9fafb",fontSize:"0.85rem",color:"#1f2937",outline:"none",cursor:"pointer",appearance:"none",backgroundImage:`url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'/%3e%3c/svg%3e")`,backgroundRepeat:"no-repeat",backgroundPosition:"right 10px center",backgroundSize:"14px"},children:[p.jsx("option",{value:"incorrect_content",children:"Lỗi nội dung"}),p.jsx("option",{value:"display_error",children:"Lỗi hiển thị"}),p.jsx("option",{value:"missing_data",children:"Thiếu thông tin"}),p.jsx("option",{value:"technical_issue",children:"Lỗi kỹ thuật"}),p.jsx("option",{value:"other",children:"Khác"})]})]}),p.jsxs("div",{children:[p.jsxs("label",{style:{display:"block",marginBottom:"2px",fontSize:"0.8rem",fontWeight:600,color:"#374151"},children:["Mô tả lỗi ",p.jsx("span",{style:{color:"#ef4444"},children:"*"})]}),p.jsxs("div",{style:{position:"relative"},children:[p.jsx("div",{style:{position:"absolute",left:"10px",top:"8px",pointerEvents:"none"},children:p.jsx(yr,{size:12,style:{color:W==="desc"?o:z.description?"#ef4444":"#9ca3af",transition:"color 0.2s"}})}),p.jsx("textarea",{value:y,onFocus:()=>de("desc"),onBlur:()=>de(null),onChange:b=>{M(b.target.value),z.description&&ue(S=>({...S,description:void 0}))},placeholder:"Mô tả chi tiết...",style:{width:"100%",minHeight:"60px",padding:"6px 10px 6px 28px",borderRadius:"6px",border:`1px solid ${z.description?"#ef4444":W==="desc"?o:"#e5e7eb"}`,boxShadow:W==="desc"?`0 0 0 2px ${o}20`:"none",outline:"none",fontSize:"0.85rem",color:"#1f2937",resize:"vertical",boxSizing:"border-box",transition:"all 0.2s",backgroundColor:"#f9fafb",lineHeight:"1.4",fontFamily:"inherit"}})]}),z.description&&p.jsx("span",{style:{display:"block",marginTop:"2px",fontSize:"0.7rem",color:"#ef4444"},children:z.description})]})]}),p.jsxs("div",{style:{marginBottom:"2px"},children:[p.jsx("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center",marginBottom:"6px"},children:p.jsxs("label",{style:{fontWeight:600,fontSize:"0.8rem",color:"#374151"},children:["Ảnh chụp (",ce.length,"/3)"]})}),ce.length>0&&p.jsx("div",{style:{display:"grid",gridTemplateColumns:"repeat(3, 1fr)",gap:"6px",marginBottom:"8px"},children:ce.map((b,S)=>p.jsxs("div",{style:{position:"relative",aspectRatio:"16/9",border:"1px solid #e5e7eb",borderRadius:"6px",overflow:"hidden",boxShadow:"0 1px 2px rgba(0,0,0,0.05)"},children:[p.jsx("img",{src:b,alt:`Screenshot ${S+1}`,draggable:!1,onContextMenu:ve=>ve.preventDefault(),style:{width:"100%",height:"100%",objectFit:"cover",cursor:"zoom-in",transition:"transform 0.2s",userSelect:"none",WebkitUserSelect:"none"},onClick:()=>ot(b)}),p.jsx("button",{onClick:()=>Mr(S),title:"Xóa ảnh",style:{position:"absolute",top:"2px",right:"2px",background:"rgba(239, 68, 68, 0.9)",color:"white",border:"none",borderRadius:"50%",width:"16px",height:"16px",display:"flex",alignItems:"center",justifyContent:"center",cursor:"pointer",padding:0,boxShadow:"0 1px 2px rgba(0,0,0,0.2)"},children:p.jsx(Gt,{size:10})})]},S))}),ce.length<3&&p.jsxs("div",{style:{display:"flex",gap:"8px"},children:[p.jsxs("button",{onClick:()=>ei("full"),style:{flex:1,padding:"12px",textAlign:"center",background:"white",border:"1px dashed #d1d5db",borderRadius:"8px",color:"#4b5563",cursor:"pointer",display:"flex",flexDirection:"column",alignItems:"center",gap:"4px",transition:"all 0.2s"},onMouseOver:b=>{b.currentTarget.style.borderColor=o,b.currentTarget.style.color=o,b.currentTarget.style.backgroundColor="#f9fafb"},onMouseOut:b=>{b.currentTarget.style.borderColor="#d1d5db",b.currentTarget.style.color="#4b5563",b.currentTarget.style.backgroundColor="white"},children:[p.jsx(mr,{size:18}),p.jsx("span",{style:{fontSize:"0.8rem",fontWeight:500},children:"Toàn màn hình"})]}),p.jsxs("button",{onClick:()=>ei("crop"),style:{flex:1,padding:"12px",textAlign:"center",background:"white",border:"1px dashed #d1d5db",borderRadius:"8px",color:"#4b5563",cursor:"pointer",display:"flex",flexDirection:"column",alignItems:"center",gap:"4px",transition:"all 0.2s"},onMouseOver:b=>{b.currentTarget.style.borderColor=o,b.currentTarget.style.color=o,b.currentTarget.style.backgroundColor="#f9fafb"},onMouseOut:b=>{b.currentTarget.style.borderColor="#d1d5db",b.currentTarget.style.color="#4b5563",b.currentTarget.style.backgroundColor="white"},children:[p.jsx(gr,{size:18}),p.jsx("span",{style:{fontSize:"0.8rem",fontWeight:500},children:"Chọn vùng"})]})]})]}),p.jsxs("div",{style:{display:"flex",justifyContent:"flex-end",gap:"8px",marginTop:"auto",paddingTop:"8px",borderTop:"1px solid #f3f4f6"},children:[p.jsx("button",{onClick:ct,disabled:J,style:{padding:"8px 16px",borderRadius:"8px",border:"1px solid #d1d5db",background:"white",cursor:"pointer",color:"#374151",fontWeight:500,fontSize:"0.85rem",transition:"background-color 0.2s"},onMouseEnter:b=>b.currentTarget.style.background="#f9fafb",onMouseLeave:b=>b.currentTarget.style.background="white",children:"Hủy bỏ"}),p.jsx("button",{onClick:Ar,disabled:J,style:{padding:"8px 16px",borderRadius:"8px",border:"none",background:o,color:"white",cursor:J?"not-allowed":"pointer",fontWeight:600,fontSize:"0.85rem",opacity:J?.7:1,boxShadow:"0 2px 4px -1px rgba(0, 0, 0, 0.1)",transition:"transform 0.1s, opacity 0.2s"},onMouseDown:b=>!J&&(b.currentTarget.style.transform="scale(0.98)"),onMouseUp:b=>!J&&(b.currentTarget.style.transform="scale(1)"),children:J?"Đang gửi...":"Gửi báo lỗi"})]})]})]})},Yt=x.createContext(void 0),vr=()=>{const e=x.useContext(Yt);if(!e)throw new Error("useFeedback must be used within a FeedbackProvider");return e},kr=({children:e,onSubmit:t,themeColor:i})=>{const[r,o]=x.useState(!1),[s,n]=x.useState(null),[f,h]=x.useState(void 0),g=(y,M)=>{n(y),h(M),o(!0)},m=()=>{o(!1)};return p.jsxs(Yt.Provider,{value:{openFeedback:g,closeFeedback:m,isOpen:r,activeQuestionId:s},children:[e,s&&p.jsx(Xt,{questionId:s,contextData:f,onSubmit:t,themeColor:i,isOpen:r,onClose:m,triggerComponent:p.jsx(p.Fragment,{})})]})};D.FeedbackProvider=kr,D.FeedbackWidget=Xt,D.useFeedback=vr,Object.defineProperty(D,Symbol.toStringTag,{value:"Module"})}));
|