PageSourceSearch

https://aipeeps.com/assets/index-DOEOSNPB.js

js aipeeps.com collected 2026-10-09 17:47:38 UTC 8,125 bytes, 1 lines download raw bytes

1var L;(function(r){r.Unimplemented="UNIMPLEMENTED",r.Unavailable="UNAVAILABLE"})(L||(L={}));class A extends Error{constructor(e,t,i){super(e),this.message=e,this.code=t,this.data=i}}const q=r=>{var e,t;return r?.androidBridge?"android":!((t=(e=r?.webkit)===null||e===void 0?void 0:e.messageHandlers)===null||t===void 0)&&t.bridge?"ios":"web"},I=r=>{const e=r.CapacitorCustomPlatform||null,t=r.Capacitor||{},i=t.Plugins=t.Plugins||{},s=()=>e!==null?e.name:q(r),n=()=>s()!=="web",o=a=>{const c=b.get(a);return!!(c?.platforms.has(s())||l(a))},l=a=>{var c;return(c=t.PluginHeaders)===null||c===void 0?void 0:c.find(E=>E.name===a)},u=a=>r.console.error(a),b=new Map,P=(a,c={})=>{const E=b.get(a);if(E)return console.warn(`Capacitor plugin "${a}" already registered. Cannot register plugins twice.`),E.proxy;const m=s(),p=l(a);let w;const W=async()=>(!w&&m in c?w=typeof c[m]=="function"?w=await c[m]():w=c[m]:e!==null&&!w&&"web"in c&&(w=typeof c.web=="function"?w=await c.web():w=c.web),w),F=(d,f)=>{var g,y;if(p){const v=p?.methods.find(h=>f===h.name);if(v)return v.rtype==="promise"?h=>t.nativePromise(a,f.toString(),h):(h,C)=>t.nativeCallback(a,f.toString(),h,C);if(d)return(g=d[f])===null||g===void 0?void 0:g.bind(d)}else{if(d)return(y=d[f])===null||y===void 0?void 0:y.bind(d);throw new A(`"${a}" plugin is not implemented on ${m}`,L.Unimplemented)}},x=d=>{let f;const g=(...y)=>{const v=W().then(h=>{const C=F(h,d);if(C){const k=C(...y);return f=k?.remove,k}else throw new A(`"${a}.${d}()" is not implemented on ${m}`,L.Unimplemented)});return d==="addListener"&&(v.remove=async()=>f()),v};return g.toString=()=>`${d.toString()}() { [capacitor code] }`,Object.defineProperty(g,"name",{value:d,writable:!1,configurable:!1}),g},S=x("addListener"),T=x("removeListener"),_=(d,f)=>{const g=S({eventName:d},f),y=async()=>{const h=await g;T({eventName:d,callbackId:h},f)},v=new Promise(h=>g.then(()=>h({remove:y})));return v.remove=async()=>{console.warn("Using addListener() without 'await' is deprecated."),await y()},v},O=new Proxy({},{get(d,f){switch(f){case"$$typeof":return;case"toJSON":return()=>({});case"addListener":return p?_:S;case"removeListener":return T;default:return x(f)}}});return i[a]=O,b.set(a,{name:a,proxy:O,platforms:new Set([...Object.keys(c),...p?[m]:[]])}),O};return t.convertFileSrc||(t.convertFileSrc=a=>a),t.getPlatform=s,t.handleError=u,t.isNativePlatform=n,t.isPluginAvailable=o,t.registerPlugin=P,t.Exception=A,t.DEBUG=!!t.DEBUG,t.isLoggingEnabled=!!t.isLoggingEnabled,t},K=r=>r.Capacitor=I(r),$=K(typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{}),U=$.registerPlugin;class j{constructor(){this.listeners={},this.retainedEventArguments={},this.windowListeners={}}addListener(e,t){let i=!1;this.listeners[e]||(this.listeners[e]=[],i=!0),this.listeners[e].push(t);const n=this.windowListeners[e];n&&!n.registered&&this.addWindowListener(n),i&&this.sendRetainedArgumentsForEvent(e);const o=async()=>this.removeListener(e,t);return Promise.resolve({remove:o})}async removeAllListeners(){this.listeners={};for(const e in this.windowListeners)this.removeWindowListener(this.windowListeners[e]);this.windowListeners={}}notifyListeners(e,t,i){const s=this.listeners[e];if(!s){if(i){let n=this.retainedEventArguments[e];n||(n=[]),n.push(t),this.retainedEventArguments[e]=n}return}s.forEach(n=>n(t))}hasListeners(e){var t;return!!(!((t=this.listeners[e])===null||t===void 0)&&t.length)}registerWindowListener(e,t){this.windowListeners[t]={registered:!1,windowEventName:e,pluginEventName:t,handler:i=>{this.notifyListeners(t,i)}}}unimplemented(e="not implemented"){return new $.Exception(e,L.Unimplemented)}unavailable(e="not available"){return new $.Exception(e,L.Unavailable)}async removeListener(e,t){const i=this.listeners[e];if(!i)return;const s=i.indexOf(t);this.listeners[e].splice(s,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(i=>
1{this.notifyListeners(e,i)}))}}const D=r=>encodeURIComponent(r).replace(/%(2[346B]|5E|60|7C)/g,decodeURIComponent).replace(/[()]/g,escape),B=r=>r.replace(/(%[\dA-F]{2})+/gi,decodeURIComponent);class M extends j{async getCookies(){const e=document.cookie,t={};return e.split(";").forEach(i=>{if(i.length<=0)return;let[s,n]=i.replace(/=/,"CAP_COOKIE").split("CAP_COOKIE");s=B(s).trim(),n=B(n).trim(),t[s]=n}),t}async setCookie(e){try{const t=D(e.key),i=D(e.value),s=e.expires?`; expires=${e.expires.replace("expires=","")}`:"",n=(e.path||"/").replace("path=",""),o=e.url!=null&&e.url.length>0?`domain=${e.url}`:"";document.cookie=`${t}=${i||""}${s}; path=${n}; ${o};`}catch(t){return Promise.reject(t)}}async deleteCookie(e){try{document.cookie=`${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=${new Date().toUTCString()};path=/`)}catch(e){return Promise.reject(e)}}async clearAllCookies(){try{await this.clearCookies()}catch(e){return Promise.reject(e)}}}U("CapacitorCookies",{web:()=>new M});const G=async r=>new Promise((e,t)=>{const i=new FileReader;i.onload=()=>{const s=i.result;e(s.indexOf(",")>=0?s.split(",")[1]:s)},i.onerror=s=>t(s),i.readAsDataURL(r)}),z=(r={})=>{const e=Object.keys(r);return Object.keys(r).map(s=>s.toLocaleLowerCase()).reduce((s,n,o)=>(s[n]=r[e[o]],s),{})},V=(r,e=!0)=>r?Object.entries(r).reduce((i,s)=>{const[n,o]=s;let l,u;return Array.isArray(o)?(u="",o.forEach(b=>{l=e?encodeURIComponent(b):b,u+=`${n}=${l}&`}),u.slice(0,-1)):(l=e?encodeURIComponent(o):o,u=`${n}=${l}`),`${i}&${u}`},"").substr(1):null,J=(r,e={})=>{const t=Object.assign({method:r.method||"GET",headers:r.headers},e),s=z(r.headers)["content-type"]||"";if(typeof r.data=="string")t.body=r.data;else if(s.includes("application/x-www-form-urlencoded")){const n=new URLSearchParams;for(const[o,l]of Object.entries(r.data||{}))n.set(o,l);t.body=n.toString()}else if(s.includes("multipart/form-data")||r.data instanceof FormData){const n=new FormData;if(r.data instanceof FormData)r.data.forEach((l,u)=>{n.append(u,l)});else for(const l of Object.keys(r.data))n.append(l,r.data[l]);t.body=n;const o=new Headers(t.headers);o.delete("content-type"),t.headers=o}else(s.includes("application/json")||typeof r.data=="object")&&(t.body=JSON.stringify(r.data));return t};class Q extends j{async request(e){const t=J(e,e.webFetchExtra),i=V(e.params,e.shouldEncodeUrlParams),s=i?`${e.url}?${i}`:e.url,n=await fetch(s,t),o=n.headers.get("content-type")||"";let{responseType:l="text"}=n.ok?e:{};o.includes("application/json")&&(l="json");let u,b;switch(l){case"arraybuffer":case"blob":b=await n.blob(),u=await G(b);break;case"json":u=await n.json();break;default:u=await n.text()}const P={};return n.headers.forEach((a,c)=>{P[c]=a}),{data:u,headers:P,status:n.status,url:n.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"}))}}U("CapacitorHttp",{web:()=>new Q});var H;(function(r){r.Dark="DARK",r.Light="LIGHT",r.Default="DEFAULT"})(H||(H={}));var R;(function(r){r.StatusBar="StatusBar",r.NavigationBar="NavigationBar"})(R||(R={}));class X extends j{async setStyle(){this.unavailable("not available for web")}async setAnimation(){this.unavailable("not available for web")}async show(){this.unavailable("not available for web")}async hide(){this.unavailable("not available for web")}}U("SystemBars",{web:()=>new X});export{$ as C,j as W,U as r};

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.