PageSourceSearch

https://globihome.com/assets/ListingDetailLink-DkUBtGQ7.js

js globihome.com collected 2026-10-04 07:38:01 UTC 4,644 bytes, 1 lines download raw bytes

1import{r as e}from"./rolldown-runtime-QTnfLwEv.js";import{p as t}from"./sentry-C5mSwRLu.js";import{t as n}from"./link-DciuEjuc.js";import{C as r}from"./shared-runtime-BrPBoBo3.js";import{n as i,r as a,t as o}from"./release-recovery-runtime-DRnIpG7b.js";import{t as s}from"./useRouter-CSinl46-.js";var c=e(t(),1);function l(e,t){if(e===void 0)return{shouldBlockFn:()=>!0,withResolver:!1};if(`shouldBlockFn`in e)return e;if(typeof e==`function`){let n=!!(t??!0);return{shouldBlockFn:async()=>n?await e():!1,enableBeforeUnload:n,withResolver:!1}}let n=!!(e.condition??!0),r=e.blockerFn;return{shouldBlockFn:async()=>n&&r!==void 0?await r():n,enableBeforeUnload:n,withResolver:r===void 0}}function u(e,t){let{shouldBlockFn:n,enableBeforeUnload:r=!0,disabled:i=!1,withResolver:a=!1}=l(e,t),o=s(),{history:u}=o,[d,f]=c.useState({status:`idle`,current:void 0,next:void 0,action:void 0,proceed:void 0,reset:void 0});return c.useEffect(()=>i?void 0:u.block({blockerFn:async e=>{function t(e){let t=o.parseLocation(e),[,n,r]=o.getMatchedRoutes(t.pathname);return r===void 0?{routeId:`__notFound__`,fullPath:t.pathname,pathname:t.pathname,params:n,search:o.options.parseSearch(e.search)}:{routeId:r.id,fullPath:r.fullPath,pathname:t.pathname,params:n,search:o.options.parseSearch(e.search)}}let r=t(e.currentLocation),i=t(e.nextLocation);if(r.routeId===`__notFound__`&&i.routeId!==`__notFound__`)return!1;let s=await n({action:e.action,current:r,next:i});if(!a)return s;if(!s)return!1;let c=await new Promise(t=>{f({status:`blocked`,current:r,next:i,action:e.action,proceed:()=>t(!1),reset:()=>t(!0)})});return f({status:`idle`,current:void 0,next:void 0,action:void 0,proceed:void 0,reset:void 0}),c},enableBeforeUnload:r}),[n,r,i,a,u,o]),d}var d={service:`web-tanstack`,releaseTag:`v0.175.1`},f=i(d);function p(e,t){let n=o({...d,...t,navigationHealthyFreshnessMs:5e3,getActiveMutationCount:()=>e.isMutating()}),r=new WeakMap,i=e=>{let t=r.get(e);if(t)return t;let n={};return r.set(e,n),n},a=e.getMutationCache().subscribe(e=>{let t=e.mutation;if(!t)return;let r=i(t);e.type===`removed`?n.handleMutation({identity:r,state:`removed`,wasPending:t.state.status===`pending`}):e.type===`updated`&&(e.action.type===`pending`||e.action.type===`success`||e.action.type===`error`)&&n.handleMutation({identity:r,state:e.action.type})});return{...n,dispose(){a(),n.dispose()}}}var m=r(),h=(0,c.createContext)(()=>Promise.resolve(!0));function g(){return(0,c.useContext)(h)}var _=()=>({document,reload:()=>window.location.reload()});function v({children:e,queryClient:t,getBrowser:n=_}){let r=(0,c.useRef)(null),i=(0,c.useRef)([]),o=(0,c.useCallback)(()=>r.current?.guardNavigation()??!1,[]),s=(0,c.useCallback)(()=>{let e=r.current;return e?e.guardPreload():new Promise(e=>{i.current.push(e)})},[]);return u({shouldBlockFn:o,enableBeforeUnload:!1,withResolver:!1}),(0,c.useEffect)(()=>{let e=n(),o=p(t,e);r.current=o,a(e.document);let s=i.current.splice(0);for(let e of s)o.guardPreload().then(e,()=>e(!0));return()=>{o.dispose(),r.current===o&&(r.current=null)}},[n,t]),(0,m.jsx)(h.Provider,{value:s,children:e})}var y=50,b=(0,c.forwardRef)(function({slug:e,preloadOnTouchStart:t=!0,onBlur:r,onFocus:i,onPointerEnter:a,onPointerLeave:o,onTouchStart:l,...u},d){let f=s(),p=g(),h=(0,c.useRef)(null),_=(0,c.useRef)(`idle`),v=(0,c.useRef)(0),b=(0,c.useRef)(!1),x=(0,c.useRef)(!1),S=(0,c.useCallback)(()=>{h.current!==null&&(clearTimeout(h.current),h.current=null)},[]),C=(0,c.useCallback)(async(e,t)=>{if(v.current===t&&_.current===`idle`){_.current=`pending`;try{if(await p()){v.current===t&&(_.current=`idle`);return}if(v.current!==t)return;await f.preloadRoute({to:`/listings/$slug`,params:{slug:e}}),v.current===t&&(_.current=`complete`)}catch{v.current===t&&(_.current=`idle`)}}},[p,f]),w=(0,c.useCallback)(()=>{if(h.current!==null||_.current!==`idle`)return;let t=e,n=v.current;h.current=setTimeout(()=>{h.current=null,C(t,n)},y)},[C,e]);(0,c.useEffect)(()=>S,[S]),(0,c.useEffect)(()=>()=>{v.current+=1},[]);let T=()=>{b.current||x.current||(S(),v.current+=1,_.current===`pending`&&(_.current=`idle`))};return(0,m.jsx)(n,{...u,ref:d,to:`/listings/$slug`,params:{slug:e},onPointerEnter:e=>{a?.(e),!e.defaultPrevented&&(e.pointerType===`touch`&&!t||(b.current=!0,w()))},onPointerLeave:e=>{o?.(e),b.current=!1,T()},onFocus:e=>{i?.(e),!e.defaultPrevented&&(x.current=!0,w())},onBlur:e=>{r?.(e),x.current=!1,T()},onTouchStart:n=>{if(l?.(n),!n.defaultPrevented){if(S(),!t){v.current+=1,_.current===`pending`&&(_.current=`idle`);return}C(e,v.current)}}})}),x=(0,c.forwardRef)(function(e,t){return(0,m.jsx)(b,{...e,ref:t},e.slug)});export{f as i,v as n,g as r,x as t};

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.