PageSourceSearch

https://roomiapp.com/_next/static/chunks/2206-9e5ac02fd4ccbbdb.js

js roomiapp.com collected 2026-10-02 06:05:33 UTC 8,104 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2206],{32206:(e,t,r)=>{r.d(t,{A:()=>b});var l=r(95155),n=r(15239),o=r(52619),i=r.n(o),s=r(20063),a=r(56154),d=r(99708),c=r(12115),m=r(86745),u=r(60755),x=r(84813),p=r(18720),h=r(3446),f=r(25016);let g=(0,c.lazy)(()=>r.e(7699).then(r.bind(r,87699))),b=c.memo(function(e){var t,r,o,b;let{clerkId:v="",id:j="",userId:w="",username:N="",name:y="",age:_,image:k="",role:F="",bio:A="",isActive:S=!1,isSignedIn:L=!1,listing:P,looking:R,verifications:C={idVerified:!1,safetyScreened:!1},priority:z=!1,boosted:D,is_boosted:T=!1,onCardClick:I,favoritedIds:M,isBatchFavoritesLoading:O=!1}=e,$=(0,s.useRouter)(),E="/favourites"===(0,s.usePathname)(),{prefetchRoommate:U}=(0,u.j)(),V=N||w||"",Y=(0,x.d)(),[W,q]=(0,c.useState)(!1),B=w||j||"",G=!!M&&!!B,H=G?"":B,{data:J,isLoading:K,refetch:Q}=(0,m.$7)("profile",H),X=G?null!=(o=null==M?void 0:M.has(B))&&o:null!=J&&J,Z=G?!!O:K,{toggleFavorite:ee,isLoading:et}=(0,m.Cu)(),er=async e=>{if(e.preventDefault(),e.stopPropagation(),!B)return void p.oR.error("Invalid profile");try{await ee("profile",B,X),G||Q(),p.oR.success(X?"Removed from favorites":"Added to favorites")}catch(e){p.oR.error("Failed to update favorites")}},el=e=>{if(e.preventDefault(),e.stopPropagation(),!V)return void p.oR.error("Missing profile link");let t="".concat(window.location.origin,"/roommate-profile/").concat(V);navigator.clipboard.writeText(t).then(()=>{p.oR.success("Profile URL copied to clipboard")}).catch(()=>{p.oR.error("Failed to copy URL to clipboard")})},en=e=>{e.preventDefault(),e.stopPropagation(),q(!0)},eo=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:4;if(!e)return"";let r=e.trim().split(/\s+/);return r.length>t?r.slice(0,t).join(" ")+"...":e},ei=e=>{if(Y)return void window.open(e,"_blank","noopener,noreferrer");$.push(e)},es=(0,l.jsxs)("div",{className:"border-roomi-inputborder relative w-full rounded-lg border-b border-dashed bg-white pt-4 shadow-md",children:[T&&!E&&(0,l.jsx)("div",{className:"absolute top-3 right-3 z-10",children:(0,l.jsx)("div",{className:"rounded-full bg-white p-2 shadow-sm",children:(0,l.jsx)(a.A,{className:"text-roomi-purple h-5 w-5",strokeWidth:2.2})})}),(0,l.jsx)("div",{className:"flex justify-center px-4",children:(0,l.jsx)("div",{className:"h-20 w-20 overflow-hidden rounded-full",children:(0,l.jsx)(n.default,{src:(0,f.M)(k),alt:y,className:"h-full w-full object-cover",width:100,height:100,priority:z,loading:z?"eager":"lazy",fetchPriority:z?"high":"auto"})})}),(0,l.jsxs)("div",{className:"mt-3 px-5 text-center",children:[(0,l.jsxs)("h2",{className:"mb-2 text-lg font-bold text-neutral-900",children:[y," ",(0,l.jsx)("span",{className:"inline-flex items-center gap-1 align-middle",children:(C.idVerified||C.safetyScreened)&&(0,l.jsxs)("div",{className:"flex gap-1",children:[C.safetyScreened&&(0,l.jsx)(n.default,{src:"/safety_check.avif",width:16,height:16,alt:"Safety screening verified"}),C.idVerified&&(0,l.jsx)(n.default,{src:"/verified_icon.avif",width:16,height:16,alt:"Identity verified"})]})})," ","number"==typeof _&&_>0&&(0,l.jsxs)("span",{className:"font-normal text-neutral-500",children:["\xb7 ",_]})]}),L&&(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)("p",{className:"mt-1 text-left text-sm font-semibold text-neutral-900 capitalize",children:F}),(0,l.jsx)("p",{className:"mt-1 line-clamp-3 text-left text-sm text-neutral-500 group-hover:text-black",children:A})]})]}),!L&&(0,l.jsx)("div",{className:"z-20 flex flex-col items-center justify-center rounded-b-xl bg-gradient-to-r from-pink-50 to-blue-50 py-4",children:(0,l.jsxs)("div",{className:"flex flex-col items-center space-y-2 text-center",children:[(0,l.jsx)("div",{className:"rounded-full bg-gray-100 p-2",children:(0,l.jsx)(d.A,{className:"h-4 w-4 text-gray-600"})}),(0,l.jsx)("p",{className:"text-sm font-medium text-gray-900",children:"Log in to view renter preferences"})]})}),L&&(P?(0,l.jsxs)("div",{className:"border-roomi-inputborder mt-4 border-t p-4",children:[(0,l.jsxs)("div",{className:"flex items-center justify-between",children:[(0,l.jsx)("p",{className:"mb-1 text-sm font-medium text-neutral-900",children:"My listing:"}),S&&(0,l.jsx)("span",{className:"rounded-full bg-emerald-50 px-2 py-0.5 text-xs font-semibold text-emerald-700",children:"TODAY"})]}),(0,l.jsxs)("div",{className:"mt-2 flex flex-wrap gap-2",children:[P.price&&(0,l.jsxs)("span",{className:"border-roomi-inputborder bg-roomi-inputbg inline-flex items-center rounded-full border px-3 py-1 text-sm text-neutral-800 shadow-sm",children:["$",null!=(b=null==(r=P.price)||null==(t=r.toLocaleStr
1ing)?void 0:t.call(r))?b:P.price]}),P.date&&(0,l.jsx)("span",{className:"border-roomi-inputborder bg-roomi-inputbg inline-flex items-center rounded-full border px-3 py-1 text-sm text-neutral-800 shadow-sm",children:P.date}),P.location&&(0,l.jsx)("button",{className:"border-roomi-inputborder bg-roomi-inputbg inline-flex items-center rounded-full border px-3 py-1 text-sm text-neutral-800 shadow-sm hover:underline",onClick:e=>{e.stopPropagation(),e.preventDefault(),ei("/rooms-for-rent/".concat(P.location_slug,"?view=roommates"))},children:eo(P.location)})]})]}):(0,l.jsxs)("div",{className:"border-roomi-inputborder mt-4 border-t p-4",children:[(0,l.jsxs)("div",{className:"flex items-center justify-between",children:[(0,l.jsx)("p",{className:"mb-1 text-sm font-medium text-neutral-900",children:"Looking:"}),S&&(0,l.jsx)("span",{className:"rounded-full bg-emerald-50 px-2 py-0.5 text-xs font-semibold text-emerald-700",children:"TODAY"})]}),(0,l.jsxs)("div",{className:"mt-2 flex flex-wrap gap-2",children:[(null==R?void 0:R.rent_max)&&(null==R?void 0:R.rent_min)&&(0,l.jsxs)("span",{className:"border-roomi-inputborder bg-roomi-inputbg inline-flex items-center rounded-full border px-3 py-1 text-sm text-neutral-800 shadow-sm",children:["$",null==R?void 0:R.rent_min," - $",null==R?void 0:R.rent_max]}),(null==R?void 0:R.move_in_timeline)&&(0,l.jsx)("span",{className:"border-roomi-inputborder bg-roomi-inputbg inline-flex items-center rounded-full border px-3 py-1 text-sm text-neutral-800 shadow-sm",children:(null==R?void 0:R.move_in_timeline)==="1 Month"?"Urgent (this month or next)":(null==R?void 0:R.move_in_timeline)==="ASAP"?"ASAP (this week or next)":"Not urgent"}),(null==R?void 0:R.search_locations)&&(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)("button",{type:"button",className:"border-roomi-inputborder bg-roomi-inputbg inline-flex items-center truncate rounded-full border px-3 py-1 text-sm text-neutral-800 shadow-sm hover:underline",onClick:e=>{var t,r,l;e.stopPropagation(),e.preventDefault(),ei("/rooms-for-rent/".concat(null!=(l=null==R?void 0:R.location_slug)?l:null==R||null==(r=R.search_locations)||null==(t=r[0])?void 0:t.replace(/[, ]+/g,"-").toLowerCase(),"?view=roommates"))},children:eo(null==R?void 0:R.search_locations[0])}),R.search_locations.length>1&&(0,l.jsxs)("span",{className:"inline-flex items-center text-sm text-neutral-500",children:[" ","+",R.search_locations.length-1]})]})]})]}))]});return L?(0,l.jsxs)(l.Fragment,{children:[E&&(0,l.jsx)(h.A,{isFavorited:X,isToggling:et,isFavoritedLoading:Z,onToggleFavorite:er,onFlag:en,onShare:el}),(0,l.jsx)(i(),{href:"/roommate-profile/".concat(V),target:Y?"_blank":void 0,rel:Y?"noopener noreferrer":void 0,className:"group relative z-0 block w-full max-w-md min-w-[250px] rounded-lg border transition-all hover:border-neutral-700",onMouseEnter:()=>V&&U(V),children:es}),W&&j&&(0,l.jsx)(c.Suspense,{fallback:null,children:(0,l.jsx)(g,{isOpen:W,onClose:()=>q(!1),userId:j})})]}):(0,l.jsxs)(l.Fragment,{children:[E&&(0,l.jsx)(h.A,{isFavorited:X,isToggling:et,isFavoritedLoading:Z,onToggleFavorite:er,onFlag:en,onShare:el}),(0,l.jsx)("button",{type:"button",onClick:I,className:"group relative z-0 block w-full max-w-md min-w-[250px] cursor-pointer rounded-lg border text-left transition-all hover:border-neutral-700",children:es}),W&&j&&(0,l.jsx)(c.Suspense,{fallback:null,children:(0,l.jsx)(g,{isOpen:W,onClose:()=>q(!1),userId: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.