PageSourceSearch

https://www.trysuri.com/a/account/_next/static/chunks/4243-9a26332…?dpl=dpl_ComjGav4UDq61nNmSnk66rj5gagK

js trysuri.com collected 2026-09-24 21:12:50 UTC 3,823 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4243],{75865:(e,t,r)=>{r.d(t,{u1:()=>n});function n(e){return function(e){var t;let r=String(t=e).includes("Error: Shopify graphql request userErrors ")?JSON.parse(String(t).replace("Error: Shopify graphql request userErrors ",""))[0]:t;if("object"==typeof r&&null!==r&&"message"in r&&"string"==typeof r.message)return r;try{return Error(JSON.stringify(r))}catch{return Error(String(r))}}(e).message}},94243:(e,t,r)=>{r.d(t,{dn:()=>p,bs:()=>y,TF:()=>m,l6:()=>w,op:()=>v,JB:()=>_,vz:()=>L});var n=r(57419),o=r(24163),a=r(64486),i=r.n(a),u=r(78051),s=r(91476),c=r(1101),l=r(75865),g=r(10190),f=r(78109),d=r(48725),h=r(30589);let m="magicLoginError",y="email",S="_skio_justLoggedOut",p="EMAIL_NOT_FOUND",_="WRONG_CODE",v="NO_CODE_SENT",w="skio_multipass_checked";function E(e){return"object"==typeof e&&null!==e}function O(e,t){return!(E(e)&&E(e.challengeParam))||!(t in e.challengeParam)||"false"!==e.challengeParam[t]}function L({queryClient:e,onSuccess:t,onNoSession:r,onLoginSuccess:a,onLoginError:m,onCodeError:y}={}){let E=(0,n.sf)(),[N,k]=(0,o.useState)(()=>{let e="true"===sessionStorage.getItem(S);return sessionStorage.removeItem(S),{isLoading:!1,error:null,step:"login",justLoggedOut:e,codeSentToPhone:!0,codeSentToEmail:!0}}),[C,j]=(0,o.useState)(null),{mutateAsync:T}=function(e){return(0,d.useMutation)(Object.assign(Object.assign({},void 0),{mutationFn:e=>{var t,r,n,o;return t=this,r=[e],n=void 0,o=function*({email:e,domain:t}){let r=yield(0,f.U)({path:g.sLU,method:"POST",body:{email:e,domain:t}});return{ok:r.ok,accountCreated:r.accountCreated}},new(n||(n=Promise))(function(e,a){function i(e){try{s(o.next(e))}catch(e){a(e)}}function u(e){try{s(o.throw(e))}catch(e){a(e)}}function s(t){var r;t.done?e(t.value):((r=t.value)instanceof n?r:new n(function(e){e(r)})).then(i,u)}s((o=o.apply(t,r||[])).next())})}}))}();function b(e){queueMicrotask(()=>{k(t=>({...t,isLoading:!0,error:null,justLoggedOut:e??!1}))})}async function P(n=!1){b(N.justLoggedOut);try{let n=await (0,c.JZ)();if(!n)throw r?.(),Error("No storefront user id");e?.setQueryData([h.c],n);try{E.identify(n)}catch(e){}await t?.(),k(e=>({...e,step:"success",isLoading:!1}));try{i().set(u.fM,n)}catch(e){}}catch(e){if(n)throw e;M()}}async function I(e,t){if(!t)return!1;try{return(await T({email:e.trim().toLowerCase(),domain:t})).accountCreated??!1}catch(e){}return!1}async function q({email:e,siteId:t,domain:r,dontRetryWithCreate:n,requireCodeSent:o=!0}){try{b();let r=function({email:e,siteId:t}){return`${e}-skioSiteId-${t}`}({email:e.trim(),siteId:t}),n=await s.N.signIn(r,void 0,{siteId:t}),i=O(n,"codeSentToPhone"),u=O(n,"codeSentToEmail");if(n&&o&&!i&&!u)return m?.(Error(v)),M(v),null;return j(n),k(e=>({...e,isLoading:!1,step:n?"code":"login",codeSentToPhone:i,codeSentToEmail:u})),a?.(n),n}catch(a){if(!n&&await I(e,r))return await q({email:e,siteId:t,domain:r,dontRetryWithCreate:!0,requireCodeSent:o});m?.(a),M(p)}return null}async function D(e,t){let r=t??C;if(!r)return void M("No active authentication session");try{b(),await s.N.sendCustomChallengeAnswer(r,e);try{await P(!0)}catch(e){y?.(),k(e=>({...e,isLoading:!1,error:_}))}}catch(e){y?.(),M((0,l.u1)(e))}}async function J(){try{await s.N.signOut(),e?.setQueryData([h.c],null),sessionStorage.setItem(S,"true"),sessionStorage.removeItem(w),M(void 0,!0),await fetch("/account/logout.js").catch(()=>null)}catch(e){k(t=>({...t,error:(0,l.u1)(e)}))}}function M(e,t){k(r=>({...r,isLoading:!1,error:e??null,step:"login",justLoggedOut:t??!1,codeSentToPhone:!0,codeSentToEmail:!0}));try{i().remove(u.fM),i().remove(u.YA),i().remove(u.KJ),i().remove(u.eS),E.reset()}catch(e){}}return{loginState:N,resetLoginState:M,checkSession:P,clearError:function(){k(e=>({...e,error:null}))},confirmCode:D,login:q,logout:J}}}}]);

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.