PageSourceSearch

https://ravebae.onhercules.app/assets/page-BpeXjifp.js

js ravebae.onhercules.app collected 2026-10-03 05:07:11 UTC 18,497 bytes, 1 lines download raw bytes

1import{c as _,h as C,z as M,j as e,b as R,S as c,U as B,d as L,e as P,f as y,g as o,B as z,A as D,m as E,a as h,l as S,r as p,I as U,x as q,n as H,t as I}from"./index-DlLmRa-c.js";import{E as O,a as V,b as Y,c as F,d as J,e as K}from"./empty-0FJvJWV0.js";import{A as b}from"./arrow-left-BZ16b-dl.js";import{B as j}from"./briefcase-7OlW8tgD.js";import{f as X}from"./formatDistanceToNow-DlDqvyKz.js";import{M as $}from"./message-square-Br9UWE6L.js";import{C as G}from"./clock-Ce91rYlH.js";import"./en-US-rdgWwJ4_.js";const Q=[["path",{d:"M18 6 7 17l-5-5",key:"116fxf"}],["path",{d:"m22 10-7.5 7.5L13 16",key:"ke71qq"}]],W=_("check-check",Q),A={dj:"DJ",producer:"Producer",promoter:"Promoter",venue:"Venue",event_planner:"Event Planner",host:"Host",manager:"Manager",artist:"Artist",photographer:"Photographer",videographer:"Videographer",security:"Security",bartender:"Bartender",label:"Label",pr_marketing:"PR/Marketing",model:"Model",dancer:"Dancer"};function T(r){return r.split(" ").map(i=>i[0]).join("").toUpperCase().slice(0,2)}function Z({threadId:r,onBack:i}){const l=y(o.users.getCurrentUser,{}),t=y(o.industryMessages.getIndustryMessages,{threadId:r}),u=y(o.industryMessages.getMyIndustryThreads,{}),f=S(o.industryMessages.sendIndustryMessage),x=S(o.industryMessages.markIndustryThreadRead),[s,m]=p.useState(""),[v,N]=p.useState(!1),k=p.useRef(null),n=u?.find(a=>a._id===r);p.useEffect(()=>{k.current?.scrollIntoView({behavior:"smooth"})},[t?.length]),p.useEffect(()=>{r&&x({threadId:r})},[r,x]);const w=async()=>{if(!(!s.trim()||!n)){N(!0);try{await f({recipientId:n.otherUserId,text:s.trim()}),m("")}catch(a){if(a instanceof H){const d=a.data;I.error(d.message)}else I.error("Failed to send message")}finally{N(!1)}}};return n?e.jsxs("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:86:4","data-hercules-name":"div",className:"flex flex-col h-full",children:[e.jsxs("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:88:6","data-hercules-name":"div",className:"flex items-center gap-3 px-4 py-3 border-b border-border/40 bg-background/80 backdrop-blur-sm",children:[e.jsx("button",{"data-hercules-id":"src/pages/messages/industry/page.tsx:89:8","data-hercules-name":"button",onClick:i,className:"cursor-pointer text-muted-foreground hover:text-foreground transition-colors",children:e.jsx(b,{"data-hercules-id":"src/pages/messages/industry/page.tsx:90:10","data-hercules-name":"ArrowLeft",size:20})}),e.jsx("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:92:8","data-hercules-name":"div",className:"w-10 h-10 rounded-full bg-primary/20 border border-primary/30 flex items-center justify-center shrink-0 text-primary font-bold text-sm",children:T(n.otherName)}),e.jsxs("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:95:8","data-hercules-name":"div",className:"flex-1 min-w-0",children:[e.jsx("p",{"data-hercules-id":"src/pages/messages/industry/page.tsx:96:10","data-hercules-name":"p",className:"font-semibold text-sm truncate",children:n.otherName}),e.jsxs("p",{"data-hercules-id":"src/pages/messages/industry/page.tsx:97:10","data-hercules-name":"p",className:"text-xs text-muted-foreground",children:[n.otherRole?A[n.otherRole]??n.otherRole:"Industry Pro",n.otherCity?` · ${n.otherCity}`:""]})]})]}),e.jsxs("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:105:6","data-hercules-name":"div",className:"flex-1 overflow-y-auto px-4 py-4 space-y-2",children:[t===void 0?e.jsx("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:107:10","data-hercules-name":"div",className:"space-y-3",children:Array.from({length:5}).map((a,d)=>e.jsx("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:109:14","data-hercules-name":"div",className:h("flex",d%2===0?"justify-end":"justify-start"),children:e.jsx(c,{"data-hercules-id":"src/pages/messages/industry/page.tsx:110:16","data-hercules-name":"Skeleton",className:"h-10 w-48 rounded-2xl"})},d))}):t.length===0?e.jsxs("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:115:10","data-hercules-name":"div",className:"flex-1 flex flex-col items-center justify-center gap-3 py-16 text-center",children:[e.jsx("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:116:12","data-hercules-name":"div",className:"w-12 h-12 rounded-full bg-primary/10 border border-primary/20 flex items-center justify-center",children:e.jsx($,{"data-hercules-id":"src/pages/messages/industry/page.tsx:117:14","data-hercules-name":"MessageSquare",size:20,className:"text-primary"})}),e.jsx("p",{"data-hercules-id":"src/pages/messages/industry/page.tsx:119:12","data-hercules-name":"p",className:"text-sm text-muted-foreground",children:"Start the conversation"}),e.jsx("p",{"data-hercules-id":"src/pages/messages/industry/page.tsx:120:12","data-hercules-name":"p",className:"text-xs text-muted-foreground
1/60 max-w-xs",children:"You can send 1 message. Further messages unlock once they reply or accept your friend request."})]}):t.map((a,d)=>{const g=a.senderId===l?._id;return e.jsx(E.div,{"data-hercules-id":"src/pages/messages/industry/page.tsx:128:14","data-hercules-name":"motion.div",initial:{opacity:0,y:6},animate:{opacity:1,y:0},transition:{delay:Math.min(d*.02,.3)},className:h("flex",g?"justify-end":"justify-start"),children:e.jsx("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:135:16","data-hercules-name":"div",className:h("max-w-[75%] px-4 py-2.5 rounded-2xl text-sm leading-relaxed",g?"bg-primary text-white rounded-br-sm":"bg-card border border-border text-foreground rounded-bl-sm"),children:a.text})},a._id)}),e.jsx("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:147:8","data-hercules-name":"div",ref:k})]}),t&&t.length>0&&(()=>{const a=t.filter(g=>g.senderId===l?._id).length,d=t.filter(g=>g.senderId!==l?._id).length;return a>=1&&d===0?e.jsxs("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:157:14","data-hercules-name":"div",className:"mx-4 mb-2 px-3 py-2 rounded-xl bg-amber-500/10 border border-amber-500/20 flex items-center gap-2",children:[e.jsx(G,{"data-hercules-id":"src/pages/messages/industry/page.tsx:158:16","data-hercules-name":"Clock",size:12,className:"text-amber-400 shrink-0"}),e.jsx("p",{"data-hercules-id":"src/pages/messages/industry/page.tsx:159:16","data-hercules-name":"p",className:"text-xs text-amber-400",children:"Waiting for reply or friend request acceptance to continue messaging."})]}):d>0?e.jsxs("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:167:14","data-hercules-name":"div",className:"mx-4 mb-2 px-3 py-2 rounded-xl bg-green-500/10 border border-green-500/20 flex items-center gap-2",children:[e.jsx(W,{"data-hercules-id":"src/pages/messages/industry/page.tsx:168:16","data-hercules-name":"CheckCheck",size:12,className:"text-green-400 shrink-0"}),e.jsx("p",{"data-hercules-id":"src/pages/messages/industry/page.tsx:169:16","data-hercules-name":"p",className:"text-xs text-green-400",children:"They replied — conversation unlocked."})]}):null})(),e.jsxs("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:178:6","data-hercules-name":"div",className:"px-4 py-3 border-t border-border/40 flex items-center gap-2",children:[e.jsx(U,{"data-hercules-id":"src/pages/messages/industry/page.tsx:179:8","data-hercules-name":"Input",value:s,onChange:a=>m(a.target.value),onKeyDown:a=>{a.key==="Enter"&&!a.shiftKey&&(a.preventDefault(),w())},placeholder:"Message...",className:"flex-1 rounded-full bg-card border-border",disabled:v}),e.jsx("button",{"data-hercules-id":"src/pages/messages/industry/page.tsx:187:8","data-hercules-name":"button",onClick:()=>{w()},disabled:!s.trim()||v,className:"w-10 h-10 rounded-full bg-primary flex items-center justify-center shrink-0 cursor-pointer disabled:opacity-40 disabled:cursor-not-allowed transition-opacity",children:e.jsx(q,{"data-hercules-id":"src/pages/messages/industry/page.tsx:192:10","data-hercules-name":"Send",size:16,className:"text-white"})})]})]}):e.jsxs("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:73:6","data-hercules-name":"div",className:"flex flex-col h-full",children:[e.jsxs("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:74:8","data-hercules-name":"div",className:"flex items-center gap-3 p-4 border-b border-border/40",children:[e.jsx("button",{"data-hercules-id":"src/pages/messages/industry/page.tsx:75:10","data-hercules-name":"button",onClick:i,className:"cursor-pointer",children:e.jsx(b,{"data-hercules-id":"src/pages/messages/industry/page.tsx:75:62","data-hercules-name":"ArrowLeft",size:20})}),e.jsx(c,{"data-hercules-id":"src/pages/messages/industry/page.tsx:76:10","data-hercules-name":"Skeleton",className:"h-5 w-32"})]}),e.jsx("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:78:8","data-hercules-name":"div",className:"flex-1 p-4 space-y-3",children:Array.from({length:5}).map((a,d)=>e.jsx(c,{"data-hercules-id":"src/pages/messages/industry/page.tsx:79:51","data-hercules-name":"Skeleton",className:"h-10 w-3/4 rounded-2xl"},d))})]})}function ee(){const r=C(),[i,l]=M(),t=y(o.industryMessages.getMyIndustryThreads,{}),u=i.get("thread"),f=s=>{l({thread:s})},x=()=>{l({})};return u?e.jsx("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:215:6","data-hercules-name":"div",className:"flex flex-col h-full",children:e.jsx(Z,{"data-hercules-id":"src/pages/messages/industry/page.tsx:216:8","data-hercules-name":"IndustryChat",threadId:u,onBack:x})}):t===void 0?e.jsx("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:223:6","data-hercules-name":"div",className:"px-4 space-y-3 pt-4",children:Array.from({length:5}).map((s,m)=>e.jsxs("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:225:10","data-hercules-name":"div",className:"flex items-center gap-3",children:[e.jsx(c,{"data-hercules-id":"src/pages/messages/industry/page.tsx:226:12","data-hercules-name":"Skeleton",className:"w-12 h-12 rounded-full shrink-0"}),e.jsxs("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:227:12","data-hercules-name":"div",className:"flex-1 space-y-2",children:[e.jsx(c,{"data-hercules-id":"src/pages/messages/industry/page.tsx:228:14","data-hercules-name":"Skeleton",className:"h-4 w-32"}),e.jsx(c,{"data-hercules-id":"src/pages/messages/industry/page.tsx:229:14","data-hercules-name":"Skeleton",className:"h-3 w-48"})]})]},m))}):t.length===0?e.jsx("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:239:6","data-hercules-name":"div",className:"flex-1 flex items-center justify-center px-6 py-16",children:e.jsxs(O,{"data-hercules-id":"src/pages/messages/industry/page.tsx:240:8","data-hercules-name":"Empty",children:[e.jsxs(V,{"data-hercules-id":"src/pages/messages/industry/page.tsx:241:10","data-hercules-name":"EmptyHeader",children:[e.jsx(Y,{"data-hercules-id":"src/pages/messages/industry/page.tsx:242:12","data-hercules-name":"EmptyMedia",variant:"icon",children:e.jsx(j,{"data-hercules-id":"src/pages/messages/industry/page.tsx:242:39","data-hercules-name":"Briefcase"})}),e.jsx(F,{"data-hercules-id":"src/pages/messages/industry/page.tsx:243:12","data-hercules-name":"EmptyTitle",children:"No industry messages yet"}),e.jsx(J,{"data-hercules-id":"src/pages/messages/industry/page.tsx:244:12","data-hercules-name":"EmptyDescription",children:"Connect with DJs, promoters, venues and more from the Collab Hub"})]}),e.jsx(K,{"data-hercules-id":"src/pages/messages/industry/page.tsx:248:10","data-hercules-name":"EmptyContent",children:e.jsx(z,{"data-hercules-id":"src/pages/messages/industry/page.tsx:249:12","data-hercules-name":"Button",size:"sm",onClick:()=>r("/collab"),children:"Go to Collab Hub"})})]})}):e.jsx("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:257:4","data-hercules-name":"div",className:"pb-6",children:e.jsx(D,{"data-hercules-id":"src/pages/messages/industry/page.tsx:258:6","data-hercules-name":"AnimatePresence",children:t.map((s,m)=>e.jsxs(E.button,{"data-hercules-id":"src/pages/messages/industry/page.tsx:260:10","data-hercules-name":"motion.button",initial:{opacity:0,x:-10}
1,animate:{opacity:1,x:0},transition:{delay:m*.04},onClick:()=>f(s._id),className:"w-full flex items-center gap-3 px-4 py-3.5 hover:bg-muted/30 transition-colors text-left cursor-pointer border-b border-border/40",children:[e.jsxs("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:269:12","data-hercules-name":"div",className:"relative shrink-0",children:[e.jsx("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:270:14","data-hercules-name":"div",className:"w-13 h-13 w-[52px] h-[52px] rounded-full bg-primary/15 border-2 border-primary/30 flex items-center justify-center text-primary font-bold text-sm",children:T(s.otherName)}),s.unread>0&&e.jsx("span",{"data-hercules-id":"src/pages/messages/industry/page.tsx:274:16","data-hercules-name":"span",className:"absolute -top-0.5 -right-0.5 min-w-[18px] h-[18px] rounded-full bg-primary text-white text-[10px] font-bold flex items-center justify-center px-1",children:s.unread})]}),e.jsxs("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:281:12","data-hercules-name":"div",className:"flex-1 min-w-0",children:[e.jsxs("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:282:14","data-hercules-name":"div",className:"flex items-center justify-between gap-2",children:[e.jsx("span",{"data-hercules-id":"src/pages/messages/industry/page.tsx:283:16","data-hercules-name":"span",className:h("text-sm truncate",s.unread>0?"font-bold text-foreground":"font-semibold text-foreground"),children:s.otherName}),e.jsx("span",{"data-hercules-id":"src/pages/messages/industry/page.tsx:286:16","data-hercules-name":"span",className:"text-[10px] text-muted-foreground shrink-0",children:X(new Date(s.lastMessageAt),{addSuffix:!0})})]}),s.otherRole&&e.jsxs("span",{"data-hercules-id":"src/pages/messages/industry/page.tsx:291:16","data-hercules-name":"span",className:"inline-block text-[10px] px-2 py-0.5 rounded-full bg-accent/15 text-accent border border-accent/25 mb-0.5",children:[A[s.otherRole]??s.otherRole,s.otherCity?` · ${s.otherCity}`:""]}),s.lastMessageText&&e.jsx("p",{"data-hercules-id":"src/pages/messages/industry/page.tsx:297:16","data-hercules-name":"p",className:h("text-xs truncate mt-0.5",s.unread>0?"text-foreground":"text-muted-foreground"),children:s.lastMessageText})]})]},s._id))})})}function le(){const r=C(),[i]=M(),l=!!i.get("thread");return e.jsxs("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:315:4","data-hercules-name":"div",className:"flex flex-col min-h-full bg-background",children:[!l&&e.jsxs("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:317:8","data-hercules-name":"div",className:"px-5 pt-5 pb-3 border-b border-border/40",children:[e.jsxs("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:318:10","data-hercules-name":"div",className:"flex items-center gap-2 mb-1",children:[e.jsx("button",{"data-hercules-id":"src/pages/messages/industry/page.tsx:319:12","data-hercules-name":"button",onClick:()=>r("/messages"),className:"text-muted-foreground hover:text-foreground transition-colors cursor-pointer",children:e.jsx(b,{"data-hercules-id":"src/pages/messages/industry/page.tsx:320:14","data-hercules-name":"ArrowLeft",size:18})}),e.jsxs("h1",{"data-hercules-id":"src/pages/messages/industry/page.tsx:322:12","data-hercules-name":"h1",className:"font-serif text-2xl tracking-wide flex items-center gap-2",children:[e.jsx(j,{"data-hercules-id":"src/pages/messages/industry/page.tsx:323:14","data-hercules-name":"Briefcase",size:20,className:"text-accent"}),"INDUSTRY INBOX"]})]}),e.jsx("p",{"data-hercules-id":"src/pages/messages/industry/page.tsx:327:10","data-hercules-name":"p",className:"text-muted-foreground text-xs mt-0.5 pl-6",children:"Collab hub conversations"})]}),e.jsx(R,{"data-hercules-id":"src/pages/messages/industry/page.tsx:331:6","data-hercules-name":"AuthLoading",children:e.jsx("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:332:8","data-hercules-name":"div",className:"px-4 space-y-3 pt-4",children:Array.from({length:4}).map((t,u)=>e.jsxs("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:334:12","data-hercules-name":"div",className:"flex items-center gap-3",children:[e.jsx(c,{"data-hercules-id":"src/pages/messages/industry/page.tsx:335:14","data-hercules-name":"Skeleton",className:"w-12 h-12 rounded-full shrink-0"}),e.jsxs("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:336:14","data-hercules-name":"div",className:"flex-1 space-y-2",children:[e.jsx(c,{"data-hercules-id":"src/pages/messages/industry/page.tsx:337:16","data-hercules-name":"Skeleton",className:"h-4 w-32"}),e.jsx(c,{"data-hercules-id":"src/pages/messages/industry/page.tsx:338:16","data-hercules-name":"Skeleton",className:"h-3 w-48"})]})]},u))})}),e.jsx(B,{"data-hercules-id":"src/pages/messages/industry/page.tsx:345:6","data-hercules-name":"Unauthenticated",children:e.jsxs("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:346:8","data-hercules-name":"div",className:"flex-1 flex flex-col items-center justify-center gap-5 px-6 py-16 text-center",children:[e.jsx("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:347:10","data-hercules-name":"div",className:"w-16 h-16 rounded-full bg-accent/15 border border-accent/30 flex items-center justify-center",children:e.jsx(j,{"data-hercules-id":"src/pages/messages/industry/page.tsx:348:12","data-hercules-name":"Briefcase",size:28,className:"text-accent"})}),e.jsxs("div",{"data-hercules-id":"src/pages/messages/industry/page.tsx:350:10","data-hercules-name":"div",children:[e.jsx("p",{"data-hercules-id":"src/pages/messages/industry/page.tsx:351:12","data-hercules-name":"p",className:"font-serif text-2xl tracking-wide mb-1",children:"INDUSTRY INBOX"}),e.jsx("p",{"data-hercules-id":"src/pages/messages/industry/page.tsx:352:12","data-hercules-name":"p",className:"text-muted-foreground text-sm max-w-xs leading-relaxed",children:"Sign in to view your industry collab conversations."})]}),e.jsx(L,{"data-hercules-id":"src/pages/messages/industry/page.tsx:356:10","data-hercules-name":"SignInButton",className:"rounded-full px-8 h-12 font-bold"})]})}),e.jsx(P,{"data-hercules-id":"src/pages/messages/industry/page.tsx:360:6","data-hercules-name":"Authenticated",children:e.jsx(ee,{"data-hercules-id":"src/pages/messages/industry/page.tsx:361:8","data-hercules-name":"IndustryInboxInner"})})]})}export{le as default};

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.