1/*! For license information please see 9344.dc120c2a.chunk.js.LICENSE.txt */ 2"use strict";(self.webpackChunkranking=self.webpackChunkranking||[]).push([[9344],{9344(e,t,n){n.r(t),n.d(t,{Capacitor:()=>l,CapacitorCookies:()=>w,CapacitorException:()=>a,CapacitorHttp:()=>y,CapacitorPlatforms:()=>i,ExceptionCode:()=>s,Plugins:()=>u,WebPlugin:()=>p,WebView:()=>g,addPlatform:()=>o,buildRequestInit:()=>b,registerPlugin:()=>d,registerWebPlugin:()=>m,setPlatform:()=>r});const i=(e=>e.CapacitorPlatforms=(e=>{const t=new Map;t.set("web",{name:"web"});const n=e.CapacitorPlatforms||{currentPlatform:{name:"web"},platforms:t};return n.addPlatform=(e,t)=>{n.platforms.set(e,t)},n.setPlatform=e=>{n.platforms.has(e)&&(n.currentPlatform=n.platforms.get(e))},n})(e))("undefined"!==typeof globalThis?globalThis:"undefined"!==typeof self?self:"undefined"!==typeof window?window:"undefined"!==typeof n.g?n.g:{}),o=i.addPlatform,r=i.setPlatform;var s;!function(e){e.Unimplemented="UNIMPLEMENTED",e.Unavailable="UNAVAILABLE"}(s||(s={}));class a extends Error{constructor(e,t,n){super(e),this.message=e,this.code=t,this.data=n}}const c=e=>{var t,n,i,o,r;const c=e.CapacitorCustomPlatform||null,l=e.Capacitor||{},d=l.Plugins=l.Plugins||{},u=e.CapacitorPlatforms,m=(null===(t=null===u||void 0===u?void 0:u.currentPlatform)||void 0===t?void 0:t.getPlatform)||(()=>null!==c?c.name:(e=>{var t,n;return(null===e||void 0===e?void 0:e.androidBridge)?"android":(null===(n=null===(t=null===e||void 0===e?void 0:e.webkit)||void 0===t?void 0:t.messageHandlers)||void 0===n?void 0:n.bridge)?"ios":"web"})(e)),p=(null===(n=null===u||void 0===u?void 0:u.currentPlatform)||void 0===n?void 0:n.isNativePlatform)||(()=>"web"!==m()),g=(null===(i=null===u||void 0===u?void 0:u.currentPlatform)||void 0===i?void 0:i.isPluginAvailable)||(e=>{const t=h.get(e);return!!(null===t||void 0===t?void 0:t.platforms.has(m()))||!!f(e)}),f=(null===(o=null===u||void 0===u?void 0:u.currentPlatform)||void 0===o?void 0:o.getPluginHeader)||(e=>{var t;return null===(t=l.PluginHeaders)||void 0===t?void 0:t.find(t=>t.name===e)}),h=new Map,v=(null===(r=null===u||void 0===u?void 0:u.currentPlatform)||void 0===r?void 0:r.registerPlugin)||function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const n=h.get(e);if(n)return console.warn('Capacitor plugin "'.concat(e,'" already registered. Cannot register plugins twice.')),n.proxy;const i=m(),o=f(e);let r;const u=n=>{let d;const u=function(){for(var u=arguments.length,m=new Array(u),p=0;p<u;p++)m[p]=arguments[p];const g=(async()=>(!r&&i in t?r=r="function"===typeof t[i]?await t[i]():t[i]:null!==c&&!r&&"web"in t&&(r=r="function"===typeof t.web?await t.web():t.web),r))().then(t=>{const r=((t,n)=>{var r,c;if(!o){if(t)return null===(c=t[n])||void 0===c?void 0:c.bind(t);throw new a('"'.concat(e,'" plugin is not implemented on ').concat(i),s.Unimplemented)}{const i=null===o||void 0===o?void 0:o.methods.find(e=>n===e.name);if(i)return"promise"===i.rtype?t=>l.nativePromise(e,n.toString(),t):(t,i)=>l.nativeCallback(e,n.toString(),t,i);if(t)return null===(r=t[n])||void 0===r?void 0:r.bind(t)}})(t,n);if(r){const e=r(...m);return d=null===e||void 0===e?void 0:e.remove,e}throw new a('"'.concat(e,".").concat(n,'()" is not implemented on ').concat(i),s.Unimplemented)});return"addListener"===n&&(g.remove=async()=>d()),g};return u.toString=()=>"".concat(n.toString(),"() { [capacitor code] }"),Object.defineProperty(u,"name",{value:n,writable:!1,configurable:!1}),u},p=u("addListener"),g=u("removeListener"),v=(e,t)=>{const n=p({eventName:e},t),i=async()=>{const i=await n;g({eventName:e,callbackId:i},t)},o=new Promise(e=>n.then(()=>e({remove:i})));return o.remove=async()=>{console.warn("Using addListener() without 'await' is deprecated."),await i()},o},w=new Proxy({},{get(e,t){switch(t){case"$$typeof":return;case"toJSON":return()=>({});case"addListener":return o?v:p;case"removeListener":return g;default:return u(t)}}});return d[e]=w,h.set(e,{name:e,proxy:w,platforms:new Set([...Object.keys(t),...o?[i]:[]])}),w};return l.convertFileSrc||(l.convertFileSrc=e=>e),l.getPlatform=m,l.handleError=t=>e.console.error(t),l.isNativePlatform=p,l.isPluginAvailable=g,l.pluginMethodNoop=(e,t,n)=>Promise.reject("".concat(n,' does not have an implementation of "').concat(t,'".')),l.registerPlugin=v,l.Exception=a,l.DEBUG=!!l.DEBUG,l.isLoggingEnabled=!!l.isLoggingEnabled,l.platform=l.getPlatform(),l.
2isNative=l.isNativePlatform(),l},l=(e=>e.Capacitor=c(e))("undefined"!==typeof globalThis?globalThis:"undefined"!==typeof self?self:"undefined"!==typeof window?window:"undefined"!==typeof n.g?n.g:{}),d=l.registerPlugin,u=l.Plugins,m=e=>((e,t)=>{var n;const i=t.config,o=e.Plugins;if(!(null===i||void 0===i?void 0:i.name))throw new Error('Capacitor WebPlugin is using the deprecated "registerWebPlugin()" function, but without the config. Please use "registerPlugin()" instead to register this web plugin."');console.warn('Capacitor plugin "'.concat(i.name,'" is using the deprecated "registerWebPlugin()" function')),o[i.name]&&!(null===(n=null===i||void 0===i?void 0:i.platforms)||void 0===n?void 0:n.includes(e.getPlatform()))||(o[i.name]=t)})(l,e);class p{constructor(e){this.listeners={},this.retainedEventArguments={},this.windowListeners={},e&&(console.warn('Capacitor WebPlugin "'.concat(e.name,'" config object was deprecated in v3 and will be removed in v4.')),this.config=e)}addListener(e,t){let n=!1;this.listeners[e]||(this.listeners[e]=[],n=!0),this.listeners[e].push(t);const i=this.windowListeners[e];i&&!i.registered&&this.addWindowListener(i),n&&this.sendRetainedArgumentsForEvent(e);return Promise.resolve({remove:async()=>this.removeListener(e,t)})}async removeAllListeners(){this.listeners={};for(const e in this.windowListeners)this.removeWindowListener(this.windowListeners[e]);this.windowListeners={}}notifyListeners(e,t,n){const i=this.listeners[e];if(i)i.forEach(e=>e(t));else if(n){let n=this.retainedEventArguments[e];n||(n=[]),n.push(t),this.retainedEventArguments[e]=n}}hasListeners(e){return!!this.listeners[e].length}registerWindowListener(e,t){this.windowListeners[t]={registered:!1,windowEventName:e,pluginEventName:t,handler:e=>{this.notifyListeners(t,e)}}}unimplemented(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"not implemented";return new l.Exception(e,s.Unimplemented)}unavailable(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"not available";return new l.Exception(e,s.Unavailable)}async removeListener(e,t){const n=this.listeners[e];if(!n)return;const i=n.indexOf(t);this.listeners[e].splice(i,1),this.listeners[e].length||this.removeWindowListener(this.windowListeners[e])}addWindowListener(e){window.addEventListener(e.windowEventName,e.handler),e.registered=!0}removeWindowListener(e){e&&(window.removeEventListener(e.windowEventName,e.handler),e.registered=!1)}sendRetainedArgumentsForEvent(e){const t=this.retainedEventArguments[e];t&&(delete this.retainedEventArguments[e],t.forEach(t=>{this.notifyListeners(e,t)}))}}const g=d("WebView"),f=e=>encodeURIComponent(e).replace(/%(2[346B]|5E|60|7C)/g,decodeURIComponent).replace(/[()]/g,escape),h=e=>e.replace(/(%[\dA-F]{2})+/gi,decodeURIComponent);class v extends p{async getCookies(){const e=document.cookie,t={};return e.split(";").forEach(e=>{if(e.length<=0)return;let[n,i]=e.replace(/=/,"CAP_COOKIE").split("CAP_COOKIE");n=h(n).trim(),i=h(i).trim(),t[n]=i}),t}async setCookie(e){try{const t=f(e.key),n=f(e.value),i="; expires=".concat((e.expires||"").replace("expires=","")),o=(e.path||"/").replace("path=",""),r=null!=e.url&&e.url.length>0?"domain=".concat(e.url):"";document.cookie="".concat(t,"=").concat(n||"").concat(i,"; path=").concat(o,"; ").concat(r,";")}catch(t){return Promise.reject(t)}}async deleteCookie(e){try{document.cookie="".concat(e.key,"=; Max-Age=0")}catch(t){return Promise.reject(t)}}async clearCookies(){try{const e=document.cookie.split(";")||[];for(const t of e)document.cookie=t.replace(/^ +/,"").replace(/=.*/,"=;expires=".concat((new Date).toUTCString(),";path=/"))}catch(e){return Promise.reject(e)}}async clearAllCookies(){try{await this.clearCookies()}catch(e){return Promise.reject(e)}}}const w=d("CapacitorCookies",{web:()=>new v}),b=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const n=Object.assign({method:e.method||"GET",headers:e.headers},t),i=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const t=Object.keys(e);return Object.keys(e).map(e=>e.toLocaleLowerCase()).reduce((n,i,o)=>(n[i]=e[t[o]],n),{})}(e.headers),o=i["content-type"]||"";if("string"===typeof e.data)n.body=e.data;else if(o.includes("application/x-www-form-urlencoded")){const t=new URLSearchParams;for(const[n,i]of Object.entries(e.data||{}))t.set(n,i);n.body=t.toString()}else if(o.includes("multipart/form-data")||e.data instanceof FormData){const t=new FormData;if(e.data instanceof FormData)e.data.forEach((e,n)=>{t.append(n,e)});else for(const n of Object.keys(e.data))t.append(n,e.data[n]);n.body=t;const i=new Headers(n.headers);i.delete("content-type"),n.headers=i}else(o.includes("application/json")||"object"===typeof e.data)&&(n.body=JSON.stringify(e.data));return n};class P extends p{async request(e){const t=b(e,e.webFetchExtra),n=function(e){let t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];return e?Object.entries(e).reduce((e,n)=>{const[i,o]=n;let r,s;
2return Array.isArray(o)?(s="",o.forEach(e=>{r=t?encodeURIComponent(e):e,s+="".concat(i,"=").concat(r,"&")}),s.slice(0,-1)):(r=t?encodeURIComponent(o):o,s="".concat(i,"=").concat(r)),"".concat(e,"&").concat(s)},"").substr(1):null}(e.params,e.shouldEncodeUrlParams),i=n?"".concat(e.url,"?").concat(n):e.url,o=await fetch(i,t),r=o.headers.get("content-type")||"";let s,a,{responseType:c="text"}=o.ok?e:{};switch(r.includes("application/json")&&(c="json"),c){case"arraybuffer":case"blob":a=await o.blob(),s=await(async e=>new Promise((t,n)=>{const i=new FileReader;i.onload=()=>{const e=i.result;t(e.indexOf(",")>=0?e.split(",")[1]:e)},i.onerror=e=>n(e),i.readAsDataURL(e)}))(a);break;case"json":s=await o.json();break;default:s=await o.text()}const l={};return o.headers.forEach((e,t)=>{l[t]=e}),{data:s,headers:l,status:o.status,url:o.url}}async get(e){return this.request(Object.assign(Object.assign({},e),{method:"GET"}))}async post(e){return this.request(Object.assign(Object.assign({},e),{method:"POST"}))}async put(e){return this.request(Object.assign(Object.assign({},e),{method:"PUT"}))}async patch(e){return this.request(Object.assign(Object.assign({},e),{method:"PATCH"}))}async delete(e){return this.request(Object.assign(Object.assign({},e),{method:"DELETE"}))}}const y=d("CapacitorHttp",{web:()=>new P})}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.