UNPKG

biketag-vue

Version:

<h1 align=center>BikeTag-Vue</h1> <div align="center"> <img alt="biketag-vue logo" src="https://raw.githubusercontent.com/keneucker/biketag-website/production/public/img/Tag-Logo-Stacked-V2-medium.png" height="auto" width="200" style="border-radius:25%;">

1,330 lines 383 kB
var Oa = Object.defineProperty; var La = (e, t, r) => t in e ? Oa(e, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : e[t] = r; var Ve = (e, t, r) => (La(e, typeof t != "symbol" ? t + "" : t, r), r); import { reactive as Sa, computed as je, openBlock as Pe, createElementBlock as He, mergeProps as ja, createElementVNode as Fe, toDisplayString as E0, renderSlot as Qt, normalizeClass as za, normalizeStyle as Cn, unref as ka, createCommentVNode as Ot, createBlock as ba, defineComponent as Wt, h as On, getCurrentInstance as Ht, inject as Ba, onMounted as wa, onUnmounted as Fa, shallowRef as Ln, ref as t0, onBeforeMount as Ua, watch as xr, Fragment as Sn, createVNode as j0, Text as Pa, createTextVNode as Ra } from "vue"; import c0 from "biketag"; import { defineStore as Ya } from "pinia"; import { useRouter as jn } from "vue-router"; const ie = { appId: "com.app.biketag", accessToken: "8b4e2b86a724bf3f39d6766de6e67212", admingEmail: "biketag@biketag.org", gameName: "", host: "biketag.org", hostKey: "ItsABikeTagGame", logo: "/images/BikeTag.svg", jingle: "media/biketag-jingle-1.mp3", imageSource: "imgur", gameSource: "sanity", store: "biketag", manifest: { name: "BikeTag", shortName: "BikeTag", description: "BikeTag is a photo mystery tag game played on bicycles. No login required.", themeColor: "#000000" }, /// TODO: THIS IS BAD sanityImagesCDNUrl: "https://cdn.sanity.io/images/", sanityBaseCDNUrl: "https://cdn.sanity.io/images/x37ikhvs/production/", sanityPlayerRoleID: "rol_pcbQ68Q9L0yn1o3O", sanityAmbassadorRoleID: "rol_iET51vzIn8z6Utz0" }, Dc = { APP_ID: process.env.APP_ID ?? ie.appId, ACCESS_TOKEN: process.env.ACCESS_TOKEN ?? ie.accessToken, CONTEXT: process.env.CONTEXT ?? null, ADMIN_EMAIL: process.env.ADMIN_EMAIL ?? ie.admingEmail, AMBASSADOR_ROLE: process.env.AMBASSADOR_ROLE ?? ie.sanityAmbassadorRoleID, PLAYER_ROLE: process.env.PLAYER_ROLE ?? ie.sanityPlayerRoleID, /* Auth0 Configuration */ A_AUDIENCE: process.env.A_AUDIENCE ?? null, A_CID: process.env.A_CID ?? null, A_DOMAIN: process.env.A_DOMAIN ?? null, A_M_CS: process.env.A_M_CS ?? null, A_M_CID: process.env.A_M_CID ?? null, /* Bugs Configuration */ B_AKEY: process.env.B_AKEY ?? null, /* BikeTag Configuration */ GAME_NAME: process.env.GAME_NAME ?? null, GAME_SOURCE: process.env.GAME_SOURCE ?? null, HOST: process.env.HOST ?? ie.host, HOST_KEY: process.env.HOST_KEY ?? ie.hostKey, BIKETAG_AUTHED: process.env.B_AUTHED ?? process.env.BIKETAG_AUTHED ?? null, /* Google Configuration */ G_AKEY: process.env.G_AKEY ?? process.env.GOOGLE_ACCESS_TOKEN ?? process.env.GOOGLE_API_KEY ?? null, G_CID: process.env.G_CID ?? process.env.GOOGLE_CLIENT_ID ?? null, G_CSECRET: process.env.G_CSECRET ?? process.env.GOOGLE_CLIENT_SECRET ?? null, G_EMAIL: process.env.G_EMAIL ?? process.env.GOOGLE_EMAIL_ADDRESS ?? null, G_PASS: process.env.G_PASS ?? process.env.GOOGLE_PASSWORD ?? null, G_RTOKEN: process.env.G_RTOKEN ?? process.env.GOOGLE_REFRESH_TOKEN ?? null, /* Imgur Admin Configuration */ IA_CID: process.env.IA_CID ?? process.env.IMGUR_ADMIN_CLIENT_ID ?? null, IA_CSECRET: process.env.IA_CSECRET ?? process.env.IMGUR_ADMIN_CLIENT_SECRET ?? null, IA_RTOKEN: process.env.IA_RTOKEN ?? process.env.IMGUR_ADMIN_REFRESH_TOKEN ?? null, IA_TOKEN: process.env.IA_TOKEN ?? process.env.IMGUR_ADMIN_ACCESS_TOKEN ?? null, /* Imgur Configuration */ I_CID: process.env.I_CID ?? process.env.IMGUR_CLIENT_ID ?? null, I_CSECRET: process.env.I_CSECRET ?? process.env.IMGUR_CLIENT_SECRET ?? null, I_RTOKEN: process.env.I_RTOKEN ?? process.env.IMGUR_REFRESH_TOKEN ?? null, I_TOKEN: process.env.I_TOKEN ?? process.env.IMGUR_ACCESS_TOKEN ?? null, /* Sanity Admin Configuration */ SA_CDN_URL: process.env.SA_CDN_URL ?? ie.sanityImagesCDNUrl, SA_DSET: process.env.SA_DSET ?? process.env.SANITY_ADMIN_DATASET ?? null, SA_PID: process.env.SA_PID ?? process.env.SANITY_ADMIN_PROJECT_ID ?? null, SA_TOKEN: process.env.SA_TOKEN ?? process.env.SANITY_ADMIN_ACCESS_TOKEN ?? null, /* Sanity Configuration */ S_CURL: process.env.S_CURL ?? ie.sanityImagesCDNUrl, S_DSET: process.env.S_DSET ?? process.env.SANITY_DATASET ?? null, S_PID: process.env.S_PID ?? process.env.SANITY_PROJECT_ID ?? null, S_TOKEN: process.env.S_TOKEN ?? process.env.SANITY_ACCESS_TOKEN ?? null }, Qa = [ "\\+https:\\/\\/developers.google.com\\/\\+\\/web\\/snippet\\/", "googlebot", "baiduspider", "gurujibot", "yandexbot", "slurp", "msnbot", "bingbot", "facebookexternalhit", "linkedinbot", "twitterbot", "slackbot", "telegrambot", "applebot", "pingdom", "tumblr ", "Embedly", "spbot" ], Wa = new RegExp("^.*(" + Qa.join("|") + ").*$"); class k0 { constructor(t = {}) { Ve(this, "options"); Ve(this, "version"); Ve(this, "_Versions"); Ve(this, "_Browsers"); Ve(this, "_OS"); Ve(this, "_Platform"); Ve(this, "DefaultAgent"); Ve(this, "Agent"); const r = { version: !1, language: !1, platform: !0, os: !0, pixelDepth: !0, colorDepth: !0, resolution: !1, isAuthoritative: !0, silkAccelerated: !0, isKindleFire: !0, isDesktop: !0, isMobile: !0, isTablet: !0, isWindows: !0, isLinux: !0, isLinux64: !0, isChromeOS: !0, isMac: !0, isiPad: !0, isiPhone: !0, isiPod: !0, isAndroid: !0, isSamsung: !0, isSmartTV: !0, isRaspberry: !0, isBlackberry: !0, isTouchScreen: !0, isOpera: !1, isIE: !1, isEdge: !1, isIECompatibilityMode: !1, isSafari: !1, isFirefox: !1, isWebkit: !1, isChrome: !1, isKonqueror: !1, isOmniWeb: !1, isSeaMonkey: !1, isFlock: !1, isAmaya: !1, isPhantomJS: !1, isEpiphany: !1, source: !1, cpuCores: !1 }; for (const n in t) t.hasOwnProperty(n) && typeof r[n] < "u" && (r[n] = t[n]); this.options = r, this.version = "1.0.0", this._Versions = { Edge: /Edge\/([\d\w\.\-]+)/i, Firefox: /firefox\/([\d\w\.\-]+)/i, IE: /msie\s([\d\.]+[\d])|trident\/\d+\.\d+;.*[rv:]+(\d+\.\d)/i, Chrome: /chrome\/([\d\w\.\-]+)/i, Chromium: /(?:chromium|crios)\/([\d\w\.\-]+)/i, Safari: /version\/([\d\w\.\-]+)/i, Opera: /version\/([\d\w\.\-]+)|OPR\/([\d\w\.\-]+)/i, Ps3: /([\d\w\.\-]+)\)\s*$/i, Psp: /([\d\w\.\-]+)\)?\s*$/i, Amaya: /amaya\/([\d\w\.\-]+)/i, SeaMonkey: /seamonkey\/([\d\w\.\-]+)/i, OmniWeb: /omniweb\/v([\d\w\.\-]+)/i, Flock: /flock\/([\d\w\.\-]+)/i, Epiphany: /epiphany\/([\d\w\.\-]+)/i, WinJs: /msapphost\/([\d\w\.\-]+)/i, PhantomJS: /phantomjs\/([\d\w\.\-]+)/i, UC: /UCBrowser\/([\d\w\.]+)/i }, this._Browsers = { Edge: /edge/i, Amaya: /amaya/i, Konqueror: /konqueror/i, Epiphany: /epiphany/i, SeaMonkey: /seamonkey/i, Flock: /flock/i, OmniWeb: /omniweb/i, Chromium: /chromium|crios/i, Chrome: /chrome/i, Safari: /safari/i, IE: /msie|trident/i, Opera: /opera|OPR/i, PS3: /playstation 3/i, PSP: /playstation portable/i, Firefox: /firefox/i, WinJs: /msapphost/i, PhantomJS: /phantomjs/i, UC: /UCBrowser/i }, this._OS = { Windows10: /windows nt 10\.0/i, Windows81: /windows nt 6\.3/i, Windows8: /windows nt 6\.2/i, Windows7: /windows nt 6\.1/i, UnknownWindows: /windows nt 6\.\d+/i, WindowsVista: /windows nt 6\.0/i, Windows2003: /windows nt 5\.2/i, WindowsXP: /windows nt 5\.1/i, Windows2000: /windows nt 5\.0/i, WindowsPhone8: /windows phone 8\./, OSXCheetah: /os x 10[._]0/i, OSXPuma: /os x 10[._]1(\D|$)/i, OSXJaguar: /os x 10[._]2/i, OSXPanther: /os x 10[._]3/i, OSXTiger: /os x 10[._]4/i, OSXLeopard: /os x 10[._]5/i, OSXSnowLeopard: /os x 10[._]6/i, OSXLion: /os x 10[._]7/i, OSXMountainLion: /os x 10[._]8/i, OSXMavericks: /os x 10[._]9/i, OSXYosemite: /os x 10[._]10/i, OSXElCapitan: /os x 10[._]11/i, OSXSierra: /os x 10[._]12/i, Mac: /os x/i, Linux: /linux/i, Linux64: /linux x86_64/i, ChromeOS: /cros/i, Wii: /wii/i, PS3: /playstation 3/i, PSP: /playstation portable/i, iPad: /\(iPad.*os (\d+)[._](\d+)/i, iPhone: /\(iPhone.*os (\d+)[._](\d+)/i, Bada: /Bada\/(\d+)\.(\d+)/i, Curl: /curl\/(\d+)\.(\d+)\.(\d+)/i }, this._Platform = { Windows: /windows nt/i, WindowsPhone: /windows phone/i, Mac: /macintosh/i, Linux: /linux/i, Wii: /wii/i, Playstation: /playstation/i, iPad: /ipad/i, iPod: /ipod/i, iPhone: /iphone/i, Android: /android/i, Blackberry: /blackberry/i, Samsung: /samsung/i, Curl: /curl/i }, this.Agent = this.DefaultAgent = { isAuthoritative: !0, isMobile: !1, isTablet: !1, isiPad: !1, isiPod: !1, isiPhone: !1, isAndroid: !1, isBlackberry: !1, isOpera: !1, isIE: !1, isEdge: !1, isIECompatibilityMode: !1, isSafari: !1, isFirefox: !1, isWebkit: !1, isChrome: !1, isKonqueror: !1, isOmniWeb: !1, isSeaMonkey: !1, isFlock: !1, isAmaya: !1, isPhantomJS: !1, isEpiphany: !1, isDesktop: !1, isWindows: !1, isLinux: !1, isLinux64: !1, isMac: !1, isChromeOS: !1, isBada: !1, isSamsung: !1, isRaspberry: !1, isBot: !1, isCurl: !1, isAndroidTablet: !1, isWinJs: !1, isKindleFire: !1, isSilk: !1, isCaptive: !1, isSmartTV: !1, isUC: !1, isTouchScreen: !1, silkAccelerated: !1, colorDepth: -1, pixelDepth: -1, resolution: [], cpuCores: -1, language: "unknown", browser: "unknown", version: "unknown", os: "unknown", platform: "unknown", geoIp: {}, source: "", hashInt: function(n) { let s = 0, a, M, l; if (n.length === 0) return s; for (a = 0, l = n.length; a < l; a++) M = n.charCodeAt(a), s = (s << 5) - s + M, s |= 0; return s; }, hashMD5: function(n) { function s(B, W) { return B << W | B >>> 32 - W; } function a(B, W) { let $, re, oe, v, I; return oe = B & 2147483648, v = W & 2147483648, $ = B & 1073741824, re = W & 1073741824, I = (B & 1073741823) + (W & 1073741823), $ & re ? I ^ 2147483648 ^ oe ^ v : $ | re ? I & 1073741824 ? I ^ 3221225472 ^ oe ^ v : I ^ 1073741824 ^ oe ^ v : I ^ oe ^ v; } function M(B, W, $) { return B & W | ~B & $; } function l(B, W, $) { return B & $ | W & ~$; } function f(B, W, $) { return B ^ W ^ $; } function i(B, W, $) { return W ^ (B | ~$); } function o(B, W, $, re, oe, v, I) { return B = a(B, a(a(M(W, $, re), oe), I)), a(s(B, v), W); } function D(B, W, $, re, oe, v, I) { return B = a(B, a(a(l(W, $, re), oe), I)), a(s(B, v), W); } function c(B, W, $, re, oe, v, I) { return B = a(B, a(a(f(W, $, re), oe), I)), a(s(B, v), W); } function g(B, W, $, re, oe, v, I) { return B = a(B, a(a(i(W, $, re), oe), I)), a(s(B, v), W); } function _(B) { let W; const $ = B.length, re = $ + 8, v = ((re - re % 64) / 64 + 1) * 16, I = new Array(v - 1); let j = 0, Y = 0; for (; Y < $; ) W = (Y - Y % 4) / 4, j = Y % 4 * 8, I[W] = I[W] | B.charCodeAt(Y) << j, Y++; return W = (Y - Y % 4) / 4, j = Y % 4 * 8, I[W] = I[W] | 128 << j, I[v - 2] = $ << 3, I[v - 1] = $ >>> 29, I; } function y(B) { let W = "", $ = "", re, oe; for (oe = 0; oe <= 3; oe++) re = B >>> oe * 8 & 255, $ = "0" + re.toString(16), W = W + $.substr($.length - 2, 2); return W; } function T(B) { B = B.replace(/\r\n/g, ` `); let W = ""; for (let $ = 0; $ < B.length; $++) { const re = B.charCodeAt($); re < 128 ? W += String.fromCharCode(re) : re > 127 && re < 2048 ? (W += String.fromCharCode(re >> 6 | 192), W += String.fromCharCode(re & 63 | 128)) : (W += String.fromCharCode(re >> 12 | 224), W += String.fromCharCode(re >> 6 & 63 | 128), W += String.fromCharCode(re & 63 | 128)); } return W; } let x = [], u, E, A, C, m, d, N, p, h; const O = 7, L = 12, S = 17, U = 22, Q = 5, G = 9, Z = 14, ee = 20, J = 4, X = 11, z = 16, w = 23, F = 6, b = 10, R = 15, H = 21; for (n = T(n), x = _(n), d = 1732584193, N = 4023233417, p = 2562383102, h = 271733878, u = 0; u < x.length; u += 16) E = d, A = N, C = p, m = h, d = o(d, N, p, h, x[u + 0], O, 3614090360), h = o(h, d, N, p, x[u + 1], L, 3905402710), p = o(p, h, d, N, x[u + 2], S, 606105819), N = o(N, p, h, d, x[u + 3], U, 3250441966), d = o(d, N, p, h, x[u + 4], O, 4118548399), h = o(h, d, N, p, x[u + 5], L, 1200080426), p = o(p, h, d, N, x[u + 6], S, 2821735955), N = o(N, p, h, d, x[u + 7], U, 4249261313), d = o(d, N, p, h, x[u + 8], O, 1770035416), h = o(h, d, N, p, x[u + 9], L, 2336552879), p = o(p, h, d, N, x[u + 10], S, 4294925233), N = o(N, p, h, d, x[u + 11], U, 2304563134), d = o(d, N, p, h, x[u + 12], O, 1804603682), h = o(h, d, N, p, x[u + 13], L, 4254626195), p = o(p, h, d, N, x[u + 14], S, 2792965006), N = o(N, p, h, d, x[u + 15], U, 1236535329), d = D(d, N, p, h, x[u + 1], Q, 4129170786), h = D(h, d, N, p, x[u + 6], G, 3225465664), p = D(p, h, d, N, x[u + 11], Z, 643717713), N = D(N, p, h, d, x[u + 0], ee, 3921069994), d = D(d, N, p, h, x[u + 5], Q, 3593408605), h = D(h, d, N, p, x[u + 10], G, 38016083), p = D(p, h, d, N, x[u + 15], Z, 3634488961), N = D(N, p, h, d, x[u + 4], ee, 3889429448), d = D(d, N, p, h, x[u + 9], Q, 568446438), h = D(h, d, N, p, x[u + 14], G, 3275163606), p = D(p, h, d, N, x[u + 3], Z, 4107603335), N = D(N, p, h, d, x[u + 8], ee, 1163531501), d = D(d, N, p, h, x[u + 13], Q, 2850285829), h = D(h, d, N, p, x[u + 2], G, 4243563512), p = D(p, h, d, N, x[u + 7], Z, 1735328473), N = D(N, p, h, d, x[u + 12], ee, 2368359562), d = c(d, N, p, h, x[u + 5], J, 4294588738), h = c(h, d, N, p, x[u + 8], X, 2272392833), p = c(p, h, d, N, x[u + 11], z, 1839030562), N = c(N, p, h, d, x[u + 14], w, 4259657740), d = c(d, N, p, h, x[u + 1], J, 2763975236), h = c(h, d, N, p, x[u + 4], X, 1272893353), p = c(p, h, d, N, x[u + 7], z, 4139469664), N = c(N, p, h, d, x[u + 10], w, 3200236656), d = c(d, N, p, h, x[u + 13], J, 681279174), h = c(h, d, N, p, x[u + 0], X, 3936430074), p = c(p, h, d, N, x[u + 3], z, 3572445317), N = c(N, p, h, d, x[u + 6], w, 76029189), d = c(d, N, p, h, x[u + 9], J, 3654602809), h = c(h, d, N, p, x[u + 12], X, 3873151461), p = c(p, h, d, N, x[u + 15], z, 530742520), N = c(N, p, h, d, x[u + 2], w, 3299628645), d = g(d, N, p, h, x[u + 0], F, 4096336452), h = g(h, d, N, p, x[u + 7], b, 1126891415), p = g(p, h, d, N, x[u + 14], R, 2878612391), N = g(N, p, h, d, x[u + 5], H, 4237533241), d = g(d, N, p, h, x[u + 12], F, 1700485571), h = g(h, d, N, p, x[u + 3], b, 2399980690), p = g(p, h, d, N, x[u + 10], R, 4293915773), N = g(N, p, h, d, x[u + 1], H, 2240044497), d = g(d, N, p, h, x[u + 8], F, 1873313359), h = g(h, d, N, p, x[u + 15], b, 4264355552), p = g(p, h, d, N, x[u + 6], R, 2734768916), N = g(N, p, h, d, x[u + 13], H, 1309151649), d = g(d, N, p, h, x[u + 4], F, 4149444226), h = g(h, d, N, p, x[u + 11], b, 3174756917), p = g(p, h, d, N, x[u + 2], R, 718787259), N = g(N, p, h, d, x[u + 9], H, 3951481745), d = a(d, E), N = a(N, A), p = a(p, C), h = a(h, m); return (y(d) + y(N) + y(p) + y(h)).toLowerCase(); } }; } getBrowser(t) { switch (!0) { case this._Browsers.Edge.test(t): return this.Agent.isEdge = !0, "Edge"; case this._Browsers.PhantomJS.test(t): return this.Agent.isPhantomJS = !0, "PhantomJS"; case this._Browsers.Konqueror.test(t): return this.Agent.isKonqueror = !0, "Konqueror"; case this._Browsers.Amaya.test(t): return this.Agent.isAmaya = !0, "Amaya"; case this._Browsers.Epiphany.test(t): return this.Agent.isEpiphany = !0, "Epiphany"; case this._Browsers.SeaMonkey.test(t): return this.Agent.isSeaMonkey = !0, "SeaMonkey"; case this._Browsers.Flock.test(t): return this.Agent.isFlock = !0, "Flock"; case this._Browsers.OmniWeb.test(t): return this.Agent.isOmniWeb = !0, "OmniWeb"; case this._Browsers.Opera.test(t): return this.Agent.isOpera = !0, "Opera"; case this._Browsers.Chromium.test(t): return this.Agent.isChrome = !0, "Chromium"; case this._Browsers.Chrome.test(t): return this.Agent.isChrome = !0, "Chrome"; case this._Browsers.Safari.test(t): return this.Agent.isSafari = !0, "Safari"; case this._Browsers.WinJs.test(t): return this.Agent.isWinJs = !0, "WinJs"; case this._Browsers.IE.test(t): return this.Agent.isIE = !0, "IE"; case this._Browsers.PS3.test(t): return "ps3"; case this._Browsers.PSP.test(t): return "psp"; case this._Browsers.Firefox.test(t): return this.Agent.isFirefox = !0, "Firefox"; case this._Browsers.UC.test(t): return this.Agent.isUC = !0, "UCBrowser"; default: return t.indexOf("Mozilla") !== 0 && /^([\d\w\-\.]+)\/[\d\w\.\-]+/i.test(t) ? (this.Agent.isAuthoritative = !1, RegExp.$1) : "unknown"; } } getBrowserVersion(t) { let r; switch (this.Agent.browser) { case "Edge": if (this._Versions.Edge.test(t)) return RegExp.$1; break; case "PhantomJS": if (this._Versions.PhantomJS.test(t)) return RegExp.$1; break; case "Chrome": if (this._Versions.Chrome.test(t)) return RegExp.$1; break; case "Chromium": if (this._Versions.Chromium.test(t)) return RegExp.$1; break; case "Safari": if (this._Versions.Safari.test(t)) return RegExp.$1; break; case "Opera": if (this._Versions.Opera.test(t)) return RegExp.$1 ? RegExp.$1 : RegExp.$2; break; case "Firefox": if (this._Versions.Firefox.test(t)) return RegExp.$1; break; case "WinJs": if (this._Versions.WinJs.test(t)) return RegExp.$1; break; case "IE": if (this._Versions.IE.test(t)) return RegExp.$2 ? RegExp.$2 : RegExp.$1; break; case "ps3": if (this._Versions.Ps3.test(t)) return RegExp.$1; break; case "psp": if (this._Versions.Psp.test(t)) return RegExp.$1; break; case "Amaya": if (this._Versions.Amaya.test(t)) return RegExp.$1; break; case "Epiphany": if (this._Versions.Epiphany.test(t)) return RegExp.$1; break; case "SeaMonkey": if (this._Versions.SeaMonkey.test(t)) return RegExp.$1; break; case "Flock": if (this._Versions.Flock.test(t)) return RegExp.$1; break; case "OmniWeb": if (this._Versions.OmniWeb.test(t)) return RegExp.$1; break; case "UCBrowser": if (this._Versions.UC.test(t)) return RegExp.$1; break; default: if (this.Agent.browser !== "unknown" && (r = new RegExp(this.Agent.browser + "[\\/ ]([\\d\\w\\.\\-]+)", "i"), r.test(t))) return RegExp.$1; } } getOS(t) { switch (!0) { case this._OS.WindowsVista.test(t): return this.Agent.isWindows = !0, "Windows Vista"; case this._OS.Windows7.test(t): return this.Agent.isWindows = !0, "Windows 7"; case this._OS.Windows8.test(t): return this.Agent.isWindows = !0, "Windows 8"; case this._OS.Windows81.test(t): return this.Agent.isWindows = !0, "Windows 8.1"; case this._OS.Windows10.test(t): return this.Agent.isWindows = !0, "Windows 10.0"; case this._OS.Windows2003.test(t): return this.Agent.isWindows = !0, "Windows 2003"; case this._OS.WindowsXP.test(t): return this.Agent.isWindows = !0, "Windows XP"; case this._OS.Windows2000.test(t): return this.Agent.isWindows = !0, "Windows 2000"; case this._OS.WindowsPhone8.test(t): return "Windows Phone 8"; case this._OS.Linux64.test(t): return this.Agent.isLinux = !0, this.Agent.isLinux64 = !0, "Linux 64"; case this._OS.Linux.test(t): return this.Agent.isLinux = !0, "Linux"; case this._OS.ChromeOS.test(t): return this.Agent.isChromeOS = !0, "Chrome OS"; case this._OS.Wii.test(t): return "Wii"; case this._OS.PS3.test(t): return "Playstation"; case this._OS.PSP.test(t): return "Playstation"; case this._OS.OSXCheetah.test(t): return this.Agent.isMac = !0, "OS X Cheetah"; case this._OS.OSXPuma.test(t): return this.Agent.isMac = !0, "OS X Puma"; case this._OS.OSXJaguar.test(t): return this.Agent.isMac = !0, "OS X Jaguar"; case this._OS.OSXPanther.test(t): return this.Agent.isMac = !0, "OS X Panther"; case this._OS.OSXTiger.test(t): return this.Agent.isMac = !0, "OS X Tiger"; case this._OS.OSXLeopard.test(t): return this.Agent.isMac = !0, "OS X Leopard"; case this._OS.OSXSnowLeopard.test(t): return this.Agent.isMac = !0, "OS X Snow Leopard"; case this._OS.OSXLion.test(t): return this.Agent.isMac = !0, "OS X Lion"; case this._OS.OSXMountainLion.test(t): return this.Agent.isMac = !0, "OS X Mountain Lion"; case this._OS.OSXMavericks.test(t): return this.Agent.isMac = !0, "OS X Mavericks"; case this._OS.OSXYosemite.test(t): return this.Agent.isMac = !0, "OS X Yosemite"; case this._OS.OSXElCapitan.test(t): return this.Agent.isMac = !0, "OS X El Capitan"; case this._OS.OSXSierra.test(t): return this.Agent.isMac = !0, "macOS Sierra"; case this._OS.Mac.test(t): return this.Agent.isMac = !0, "OS X"; case this._OS.iPad.test(t): this.Agent.isiPad = !0; const r = t.match(this._OS.iPad) ?? ""; return r.length ? r[0].replace("_", ".") : ""; case this._OS.iPhone.test(t): this.Agent.isiPhone = !0; const n = t.match(this._OS.iPhone) ?? ""; return n.length ? n[0].replace("_", ".") : ""; case this._OS.Bada.test(t): return this.Agent.isBada = !0, "Bada"; case this._OS.Curl.test(t): return this.Agent.isCurl = !0, "Curl"; default: return "unknown"; } } getPlatform(t) { switch (!0) { case this._Platform.Windows.test(t): return "Microsoft Windows"; case this._Platform.WindowsPhone.test(t): return this.Agent.isWindowsPhone = !0, "Microsoft Windows Phone"; case this._Platform.Mac.test(t): return "Apple Mac"; case this._Platform.Curl.test(t): return "Curl"; case this._Platform.Android.test(t): return this.Agent.isAndroid = !0, "Android"; case this._Platform.Blackberry.test(t): return this.Agent.isBlackberry = !0, "Blackberry"; case this._Platform.Linux.test(t): return "Linux"; case this._Platform.Wii.test(t): return "Wii"; case this._Platform.Playstation.test(t): return "Playstation"; case this._Platform.iPad.test(t): return this.Agent.isiPad = !0, "iPad"; case this._Platform.iPod.test(t): return this.Agent.isiPod = !0, "iPod"; case this._Platform.iPhone.test(t): return this.Agent.isiPhone = !0, "iPhone"; case this._Platform.Samsung.test(t): return this.Agent.isiSamsung = !0, "Samsung"; default: return "unknown"; } } testCompatibilityMode() { if (this.Agent.isIE && /Trident\/(\d)\.0/i.test(this.Agent.source)) { const t = parseInt(RegExp.$1, 10), r = parseInt(this.Agent.version, 10); r === 7 && t === 7 && (this.Agent.isIECompatibilityMode = !0, this.Agent.version = 11), r === 7 && t === 6 && (this.Agent.isIECompatibilityMode = !0, this.Agent.version = 10), r === 7 && t === 5 && (this.Agent.isIECompatibilityMode = !0, this.Agent.version = 9), r === 7 && t === 4 && (this.Agent.isIECompatibilityMode = !0, this.Agent.version = 8); } } testSilk() { switch (!0) { case new RegExp("silk", "gi").test(this.Agent.source): this.Agent.isSilk = !0; break; } return /Silk-Accelerated=true/gi.test(this.Agent.source) && (this.Agent.SilkAccelerated = !0), this.Agent.isSilk ? "Silk" : !1; } testKindleFire() { switch (!0) { case /KFOT/gi.test(this.Agent.source): return this.Agent.isKindleFire = !0, "Kindle Fire"; case /KFTT/gi.test(this.Agent.source): return this.Agent.isKindleFire = !0, "Kindle Fire HD"; case /KFJWI/gi.test(this.Agent.source): return this.Agent.isKindleFire = !0, "Kindle Fire HD 8.9"; case /KFJWA/gi.test(this.Agent.source): return this.Agent.isKindleFire = !0, "Kindle Fire HD 8.9 4G"; case /KFSOWI/gi.test(this.Agent.source): return this.Agent.isKindleFire = !0, "Kindle Fire HD 7"; case /KFTHWI/gi.test(this.Agent.source): return this.Agent.isKindleFire = !0, "Kindle Fire HDX 7"; case /KFTHWA/gi.test(this.Agent.source): return this.Agent.isKindleFire = !0, "Kindle Fire HDX 7 4G"; case /KFAPWI/gi.test(this.Agent.source): return this.Agent.isKindleFire = !0, "Kindle Fire HDX 8.9"; case /KFAPWA/gi.test(this.Agent.source): return this.Agent.isKindleFire = !0, "Kindle Fire HDX 8.9 4G"; default: return !1; } } testCaptiveNetwork() { switch (!0) { case /CaptiveNetwork/gi.test(this.Agent.source): return this.Agent.isCaptive = !0, this.Agent.isMac = !0, this.Agent.platform = "Apple Mac", "CaptiveNetwork"; default: return !1; } } testMobile() { switch (!0) { case this.Agent.isWindows: case this.Agent.isLinux: case this.Agent.isMac: case this.Agent.isChromeOS: this.Agent.isDesktop = !0; break; case this.Agent.isAndroid: case this.Agent.isSamsung: this.Agent.isMobile = !0, this.Agent.isDesktop = !1; break; } switch (!0) { case this.Agent.isiPad: case this.Agent.isiPod: case this.Agent.isiPhone: case this.Agent.isBada: case this.Agent.isBlackberry: case this.Agent.isAndroid: case this.Agent.isWindowsPhone: this.Agent.isMobile = !0, this.Agent.isDesktop = !1; break; } /mobile/i.test(this.Agent.source) && (this.Agent.isMobile = !0, this.Agent.isDesktop = !1); } testTablet() { switch (!0) { case this.Agent.isiPad: case this.Agent.isAndroidTablet: case this.Agent.isKindleFire: this.Agent.isTablet = !0; break; } /tablet/i.test(this.Agent.source) && (this.Agent.isTablet = !0); } testNginxGeoIP(t) { Object.keys(t).forEach((r) => { /^GEOIP/i.test(r) && (this.Agent.geoIp[r] = t[r]); }); } testBot() { const t = Wa.exec(this.Agent.source.toLowerCase()); t ? this.Agent.isBot = t[1] : this.Agent.isAuthoritative || (this.Agent.isBot = /bot/i.test(this.Agent.source)); } testSmartTV() { const t = new RegExp( "smart-tv|smarttv|googletv|appletv|hbbtv|pov_tv|netcast.tv", "gi" ).exec(this.Agent.source.toLowerCase()); t && (this.Agent.isSmartTV = t[1]); } testAndroidTablet() { this.Agent.isAndroid && !/mobile/i.test(this.Agent.source) && (this.Agent.isAndroidTablet = !0); } testTouchSupport() { this.Agent.isTouchScreen = // @ts-ignore "ontouchstart" in window || navigator.maxTouchPoints > 0 || navigator.msMaxTouchPoints > 0; } getLaguage() { this.Agent.language = (navigator.language || // @ts-ignore navigator.userLanguage || // @ts-ignore navigator.browserLanguage || // @ts-ignore navigator.systemLanguage || "").toLowerCase(); } getColorDepth() { this.Agent.colorDepth = screen.colorDepth || -1; } getScreenResolution() { this.Agent.resolution = [screen.availWidth, screen.availHeight]; } getPixelDepth() { this.Agent.pixelDepth = screen.pixelDepth || -1; } getCPU() { this.Agent.cpuCores = navigator.hardwareConcurrency || -1; } reset() { for (const t in this.DefaultAgent) this.DefaultAgent.hasOwnProperty(t) && (this.Agent[t] = this.DefaultAgent[t]); return new k0(); } parse(t) { t = t ?? navigator.userAgent; const r = new k0(); return r.Agent.source = t.replace(/^\s*/, "").replace(/\s*$/, ""), r.Agent.os = this.getOS(r.Agent.source), r.Agent.platform = this.getPlatform(r.Agent.source), r.Agent.browser = this.getBrowser(r.Agent.source), r.Agent.version = this.getBrowserVersion(r.Agent.source), r.testBot(), r.testSmartTV(), r.testMobile(), r.testAndroidTablet(), r.testTablet(), r.testCompatibilityMode(), r.testSilk(), r.testKindleFire(), r.testCaptiveNetwork(), r.testTouchSupport(), r.getLaguage(), r.getColorDepth(), r.getPixelDepth(), r.getScreenResolution(), r.getCPU(), r.Agent; } get(t) { let r = "a"; const n = this.parse(), s = []; for (const l in this.options) s.push(n[l]); t && s.push(t), !this.options.resolution && n.isMobile && s.push(n.resolution), r = "b"; const a = n.hashMD5(s.join(":")); return [ a.slice(0, 8), a.slice(8, 12), "4" + a.slice(12, 15), r + a.slice(15, 18), a.slice(20) ].join("-"); } } var ne = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {}; function Gt(e) { return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e; } function Ha(e) { if (e.__esModule) return e; var t = e.default; if (typeof t == "function") { var r = function n() { return this instanceof n ? Reflect.construct(t, arguments, this.constructor) : t.apply(this, arguments); }; r.prototype = t.prototype; } else r = {}; return Object.defineProperty(r, "__esModule", { value: !0 }), Object.keys(e).forEach(function(n) { var s = Object.getOwnPropertyDescriptor(e, n); Object.defineProperty(r, n, s.get ? s : { enumerable: !0, get: function() { return e[n]; } }); }), r; } var zn = { exports: {} }; function Ga(e) { throw new Error('Could not dynamically require "' + e + '". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.'); } var W0 = { exports: {} }; const Va = {}, $a = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ __proto__: null, default: Va }, Symbol.toStringTag, { value: "Module" })), Za = /* @__PURE__ */ Ha($a); var fr; function ce() { return fr || (fr = 1, function(e, t) { (function(r, n) { e.exports = n(); })(ne, function() { var r = r || function(n, s) { var a; if (typeof window < "u" && window.crypto && (a = window.crypto), typeof self < "u" && self.crypto && (a = self.crypto), typeof globalThis < "u" && globalThis.crypto && (a = globalThis.crypto), !a && typeof window < "u" && window.msCrypto && (a = window.msCrypto), !a && typeof ne < "u" && ne.crypto && (a = ne.crypto), !a && typeof Ga == "function") try { a = Za; } catch { } var M = function() { if (a) { if (typeof a.getRandomValues == "function") try { return a.getRandomValues(new Uint32Array(1))[0]; } catch { } if (typeof a.randomBytes == "function") try { return a.randomBytes(4).readInt32LE(); } catch { } } throw new Error("Native crypto module could not be used to get secure random number."); }, l = Object.create || /* @__PURE__ */ function() { function u() { } return function(E) { var A; return u.prototype = E, A = new u(), u.prototype = null, A; }; }(), f = {}, i = f.lib = {}, o = i.Base = /* @__PURE__ */ function() { return { /** * Creates a new object that inherits from this object. * * @param {Object} overrides Properties to copy into the new object. * * @return {Object} The new object. * * @static * * @example * * var MyType = CryptoJS.lib.Base.extend({ * field: 'value', * * method: function () { * } * }); */ extend: function(u) { var E = l(this); return u && E.mixIn(u), (!E.hasOwnProperty("init") || this.init === E.init) && (E.init = function() { E.$super.init.apply(this, arguments); }), E.init.prototype = E, E.$super = this, E; }, /** * Extends this object and runs the init method. * Arguments to create() will be passed to init(). * * @return {Object} The new object. * * @static * * @example * * var instance = MyType.create(); */ create: function() { var u = this.extend(); return u.init.apply(u, arguments), u; }, /** * Initializes a newly created object. * Override this method to add some logic when your objects are created. * * @example * * var MyType = CryptoJS.lib.Base.extend({ * init: function () { * // ... * } * }); */ init: function() { }, /** * Copies properties into this object. * * @param {Object} properties The properties to mix in. * * @example * * MyType.mixIn({ * field: 'value' * }); */ mixIn: function(u) { for (var E in u) u.hasOwnProperty(E) && (this[E] = u[E]); u.hasOwnProperty("toString") && (this.toString = u.toString); }, /** * Creates a copy of this object. * * @return {Object} The clone. * * @example * * var clone = instance.clone(); */ clone: function() { return this.init.prototype.extend(this); } }; }(), D = i.WordArray = o.extend({ /** * Initializes a newly created word array. * * @param {Array} words (Optional) An array of 32-bit words. * @param {number} sigBytes (Optional) The number of significant bytes in the words. * * @example * * var wordArray = CryptoJS.lib.WordArray.create(); * var wordArray = CryptoJS.lib.WordArray.create([0x00010203, 0x04050607]); * var wordArray = CryptoJS.lib.WordArray.create([0x00010203, 0x04050607], 6); */ init: function(u, E) { u = this.words = u || [], E != s ? this.sigBytes = E : this.sigBytes = u.length * 4; }, /** * Converts this word array to a string. * * @param {Encoder} encoder (Optional) The encoding strategy to use. Default: CryptoJS.enc.Hex * * @return {string} The stringified word array. * * @example * * var string = wordArray + ''; * var string = wordArray.toString(); * var string = wordArray.toString(CryptoJS.enc.Utf8); */ toString: function(u) { return (u || g).stringify(this); }, /** * Concatenates a word array to this word array. * * @param {WordArray} wordArray The word array to append. * * @return {WordArray} This word array. * * @example * * wordArray1.concat(wordArray2); */ concat: function(u) { var E = this.words, A = u.words, C = this.sigBytes, m = u.sigBytes; if (this.clamp(), C % 4) for (var d = 0; d < m; d++) { var N = A[d >>> 2] >>> 24 - d % 4 * 8 & 255; E[C + d >>> 2] |= N << 24 - (C + d) % 4 * 8; } else for (var p = 0; p < m; p += 4) E[C + p >>> 2] = A[p >>> 2]; return this.sigBytes += m, this; }, /** * Removes insignificant bits. * * @example * * wordArray.clamp(); */ clamp: function() { var u = this.words, E = this.sigBytes; u[E >>> 2] &= 4294967295 << 32 - E % 4 * 8, u.length = n.ceil(E / 4); }, /** * Creates a copy of this word array. * * @return {WordArray} The clone. * * @example * * var clone = wordArray.clone(); */ clone: function() { var u = o.clone.call(this); return u.words = this.words.slice(0), u; }, /** * Creates a word array filled with random bytes. * * @param {number} nBytes The number of random bytes to generate. * * @return {WordArray} The random word array. * * @static * * @example * * var wordArray = CryptoJS.lib.WordArray.random(16); */ random: function(u) { for (var E = [], A = 0; A < u; A += 4) E.push(M()); return new D.init(E, u); } }), c = f.enc = {}, g = c.Hex = { /** * Converts a word array to a hex string. * * @param {WordArray} wordArray The word array. * * @return {string} The hex string. * * @static * * @example * * var hexString = CryptoJS.enc.Hex.stringify(wordArray); */ stringify: function(u) { for (var E = u.words, A = u.sigBytes, C = [], m = 0; m < A; m++) { var d = E[m >>> 2] >>> 24 - m % 4 * 8 & 255; C.push((d >>> 4).toString(16)), C.push((d & 15).toString(16)); } return C.join(""); }, /** * Converts a hex string to a word array. * * @param {string} hexStr The hex string. * * @return {WordArray} The word array. * * @static * * @example * * var wordArray = CryptoJS.enc.Hex.parse(hexString); */ parse: function(u) { for (var E = u.length, A = [], C = 0; C < E; C += 2) A[C >>> 3] |= parseInt(u.substr(C, 2), 16) << 24 - C % 8 * 4; return new D.init(A, E / 2); } }, _ = c.Latin1 = { /** * Converts a word array to a Latin1 string. * * @param {WordArray} wordArray The word array. * * @return {string} The Latin1 string. * * @static * * @example * * var latin1String = CryptoJS.enc.Latin1.stringify(wordArray); */ stringify: function(u) { for (var E = u.words, A = u.sigBytes, C = [], m = 0; m < A; m++) { var d = E[m >>> 2] >>> 24 - m % 4 * 8 & 255; C.push(String.fromCharCode(d)); } return C.join(""); }, /** * Converts a Latin1 string to a word array. * * @param {string} latin1Str The Latin1 string. * * @return {WordArray} The word array. * * @static * * @example * * var wordArray = CryptoJS.enc.Latin1.parse(latin1String); */ parse: function(u) { for (var E = u.length, A = [], C = 0; C < E; C++) A[C >>> 2] |= (u.charCodeAt(C) & 255) << 24 - C % 4 * 8; return new D.init(A, E); } }, y = c.Utf8 = { /** * Converts a word array to a UTF-8 string. * * @param {WordArray} wordArray The word array. * * @return {string} The UTF-8 string. * * @static * * @example * * var utf8String = CryptoJS.enc.Utf8.stringify(wordArray); */ stringify: function(u) { try { return decodeURIComponent(escape(_.stringify(u))); } catch { throw new Error("Malformed UTF-8 data"); } }, /** * Converts a UTF-8 string to a word array. * * @param {string} utf8Str The UTF-8 string. * * @return {WordArray} The word array. * * @static * * @example * * var wordArray = CryptoJS.enc.Utf8.parse(utf8String); */ parse: function(u) { return _.parse(unescape(encodeURIComponent(u))); } }, T = i.BufferedBlockAlgorithm = o.extend({ /** * Resets this block algorithm's data buffer to its initial state. * * @example * * bufferedBlockAlgorithm.reset(); */ reset: function() { this._data = new D.init(), this._nDataBytes = 0; }, /** * Adds new data to this block algorithm's buffer. * * @param {WordArray|string} data The data to append. Strings are converted to a WordArray using UTF-8. * * @example * * bufferedBlockAlgorithm._append('data'); * bufferedBlockAlgorithm._append(wordArray); */ _append: function(u) { typeof u == "string" && (u = y.parse(u)), this._data.concat(u), this._nDataBytes += u.sigBytes; }, /** * Processes available data blocks. * * This method invokes _doProcessBlock(offset), which must be implemented by a concrete subtype. * * @param {boolean} doFlush Whether all blocks and partial blocks should be processed. * * @return {WordArray} The processed data. * * @example * * var processedData = bufferedBlockAlgorithm._process(); * var processedData = bufferedBlockAlgorithm._process(!!'flush'); */ _process: function(u) { var E, A = this._data, C = A.words, m = A.sigBytes, d = this.blockSize, N = d * 4, p = m / N; u ? p = n.ceil(p) : p = n.max((p | 0) - this._minBufferSize, 0); var h = p * d, O = n.min(h * 4, m); if (h) { for (var L = 0; L < h; L += d) this._doProcessBlock(C, L); E = C.splice(0, h), A.sigBytes -= O; } return new D.init(E, O); }, /** * Creates a copy of this object. * * @return {Object} The clone. * * @example * * var clone = bufferedBlockAlgorithm.clone(); */ clone: function() { var u = o.clone.call(this); return u._data = this._data.clone(), u; }, _minBufferSize: 0 }); i.Hasher = T.extend({ /** * Configuration options. */ cfg: o.extend(), /** * Initializes a newly created hasher. * * @param {Object} cfg (Optional) The configuration options to use for this hash computation. * * @example * * var hasher = CryptoJS.algo.SHA256.create(); */ init: function(u) { this.cfg = this.cfg.extend(u), this.reset(); }, /** * Resets this hasher to its initial state. * * @example * * hasher.reset(); */ reset: function() { T.reset.call(this), this._doReset(); }, /** * Updates this hasher with a message. * * @param {WordArray|string} messageUpdate The message to append. * * @return {Hasher} This hasher. * * @example * * hasher.update('message'); * hasher.update(wordArray); */ update: function(u) { return this._append(u), this._process(), this; }, /** * Finalizes the hash computation. * Note that the finalize operation is effectively a destructive, read-once operation. * * @param {WordArray|string} messageUpdate (Optional) A final message update. * * @return {WordArray} The hash. * * @example * * var hash = hasher.finalize(); * var hash = hasher.finalize('message'); * var hash = hasher.finalize(wordArray); */ finalize: function(u) { u && this._append(u); var E = this._doFinalize(); return E; }, blockSize: 16, /** * Creates a shortcut function to a hasher's object interface. * * @param {Hasher} hasher The hasher to create a helper for. * * @return {Function} The shortcut function. * * @static * * @example * * var SHA256 = CryptoJS.lib.Hasher._createHelper(CryptoJS.algo.SHA256); */ _createHelper: function(u) { return function(E, A) { return new u.init(A).finalize(E); }; }, /** * Creates a shortcut function to the HMAC's object interface. * * @param {Hasher} hasher The hasher to use in this HMAC helper. * * @return {Function} The shortcut function. * * @static * * @example * * var HmacSHA256 = CryptoJS.lib.Hasher._createHmacHelper(CryptoJS.algo.SHA256); */ _createHmacHelper: function(u) { return function(E, A) { return new x.HMAC.init(u, A).finalize(E); }; } }); var x = f.algo = {}; return f; }(Math); return r; }); }(W0)), W0.exports; } var H0 = { exports: {} }, gr; function F0() { return gr || (gr = 1, function(e, t) { (function(r, n) { e.exports = n(ce()); })(ne, function(r) { return function(n) { var s = r, a = s.lib, M = a.Base, l = a.WordArray, f = s.x64 = {}; f.Word = M.extend({ /** * Initializes a newly created 64-bit word. * * @param {number} high The high 32 bits. * @param {number} low The low 32 bits. * * @example * * var x64Word = CryptoJS.x64.Word.create(0x00010203, 0x04050607); */ init: function(i, o) { this.high = i, this.low = o; } /** * Bitwise NOTs this word. * * @return {X64Word} A new x64-Word object after negating. * * @example * * var negated = x64Word.not(); */ // not: function () { // var high = ~this.high; // var low = ~this.low; // return X64Word.create(high, low); // }, /** * Bitwise ANDs this word with the passed word. * * @param {X64Word} word The x64-Word to AND with this word. * * @return {X64Word} A new x64-Word object after ANDing. * * @example * * var anded = x64Word.and(anotherX64Word); */ // and: function (word) { // var high = this.high & word.high; // var low = this.low & word.low; // return X64Word.create(high, l