PageSourceSearch

https://www.xotic.ai/_next/static/chunks/45b828089f9415d4.js?dpl=dpl_ExLkMDjAs4t7iRuZaQBZLYYR9Prt

js xotic.ai collected 2026-10-05 13:20:46 UTC 27,387 bytes, 1 lines download raw bytes

1(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,475308,e=>{"use strict";var r=e.i(260293),t=e.i(617029),a=e.i(975157);function l({children:e,className:l,flush:s=!1}){let{isOpen:n}=(0,t.useSidebar)();return(0,r.jsx)("div",{className:(0,a.cn)("w-full text-foreground transition-all duration-300",s?"h-full":"min-h-screen pt-20 md:pt-16",n?"md:pl-[14rem]":"md:pl-24",l),children:e})}e.s(["HubShell",()=>l])},741315,e=>{"use strict";var r=e.i(474831),t=(0,r.createServerReference)("601a7d11e11b89bd5b7779844388bfc839e32d76e2",r.callServer,void 0,r.findSourceMapURL,"getImageSignedUrl");e.s(["getImageSignedUrl",()=>t])},258221,e=>{"use strict";var r=e.i(260293),t=e.i(809528),a=e.i(741315),l=e.i(975157);function s({path:s,alt:n="Image",className:i="",fullscreen:o=!1,fullscreenButton:c,layout:d="chat",loading:u="lazy",preResolvedUrl:f}){let[m,g]=(0,t.useState)(!1),[h,p]=(0,t.useState)(!1),[x,b]=(0,t.useState)(f||null),v=(0,t.useRef)(null),j=s.startsWith("http://")||s.startsWith("https://"),y=j&&s.includes("auth.xotic.ai/storage/v1/object/sign/collections/");if((0,t.useEffect)(()=>{if(p(!1),f)return void b(f);let r=!1;return(async()=>{if(y)b((0,l.getCharacterMediaUrl)(s));else if(j)b(s);else try{let t=(0,l.getCachedUrl)(s,l.CACHE_CONFIG.IMAGE_PREFIX);if(t)return void b(t);let n=await (0,a.getImageSignedUrl)(s);if(r)return;let i=n;if(!i.success||!i.data?.signedUrl){let{getPublicWorldsSignedUrl:r}=await e.A(554394);i=await r(s)}if(i.success&&i.data?.signedUrl){let e=i.data.signedUrl;b(e),(0,l.cacheUrl)(s,e,l.CACHE_CONFIG.IMAGE_PREFIX)}else console.error("Failed to get signed URL:",i.error??n.error),p(!0)}catch(e){if(r)return;console.error("Error getting signed URL:",e),p(!0)}})(),()=>{r=!0}},[s,j,y,f]),(0,t.useEffect)(()=>{let e=v.current;e&&!m&&!h&&e.complete&&(e.naturalWidth>0?g(!0):p(!0))},[x,m,h]),!x&&!h)return o?(0,r.jsx)("div",{className:"flex h-[90vh] w-[90vw] items-center justify-center",children:(0,r.jsx)("div",{className:"h-16 w-16 animate-spin rounded-full border-b-2 border-t-2 border-primary"})}):"feed"===d?(0,r.jsx)("div",{className:`flex h-full w-full items-center justify-center bg-muted/20 ${i}`,children:(0,r.jsx)("div",{className:"h-8 w-8 animate-spin rounded-full border-b-2 border-t-2 border-primary"})}):"flexible"===d?(0,r.jsx)("div",{className:`flex items-center justify-center bg-muted/20 ${i}`,children:(0,r.jsx)("div",{className:"h-8 w-8 animate-spin rounded-full border-b-2 border-t-2 border-primary"})}):(0,r.jsx)("div",{className:`flex min-h-[200px] items-center justify-center rounded-xl bg-background/80 backdrop-blur-sm ${i}`,style:{width:"auto",maxWidth:"100%"},children:(0,r.jsx)("div",{className:"h-12 w-12 animate-spin rounded-full border-b-2 border-t-2 border-primary"})});let S=(0,l.toCdnMediaUrl)(x),N=()=>{g(!0),p(!1)},w=()=>{p(!0),g(!1)};return!x||m||h?h?o?(0,r.jsx)("div",{className:"flex h-[90vh] w-[90vw] items-center justify-center",children:(0,r.jsx)("div",{className:"text-lg text-red-400",children:"Failed to load image"})}):"feed"===d?(0,r.jsx)("div",{className:`flex h-full w-full items-center justify-center bg-muted/10 ${i}`,children:(0,r.jsx)("div",{className:"text-xs text-red-500",children:"Failed to load image"})}):"flexible"===d?(0,r.jsx)("div",{className:`flex items-center justify-center bg-muted/10 ${i}`,children:(0,r.jsx)("div",{className:"text-xs text-red-500",children:"Failed to load image"})}):(0,r.jsx)("div",{className:`flex min-h-[200px] items-center justify-center rounded-xl bg-muted/10 ${i}`,style:{width:"auto",maxWidth:"100%"},children:(0,r.jsx)("div",{className:"text-xs text-red-500",children:"Failed to load image"})}):x&&m?o?(0,r.jsxs)("div",{className:"relative flex h-[90vh] w-[90vw] items-center justify-center",children:[(0,r.jsx)("img",{src:S,alt:n,loading:u,className:"max-h-full max-w-full object-contain select-none",style:{userSelect:"none"},onLoad:N,onError:w,onContextMenu:e=>e.preventDefault(),onDragStart:e=>e.preventDefault(),draggable:!1}),c&&(0,r.jsx)("div",{className:"absolute right-4 top-4",children:c})]}):"feed"===d?(0,r.jsx)("img",{src:S,alt:n,loading:u,className:`h-full w-full object-cover select-none ${i}`,style:{userSelect:"none"},onLoad:N,onError:w,onContextMenu:e=>e.preventDefault(),onDragStart:e=>e.preventDefault(),draggable:!1}):"flexible"===d?(0,r.jsx)("img",{src:S,alt:n,loading:u,className:`object-contain select-none ${i}`,style:{userSelect:"none"},onLoad:N,onError:w,onContextMenu:e=>e.preventDefault(),onDragStart:e=>e.preventDefault(),draggable:!1}):(0,r.jsx)("img",{src:S,alt:n,loading:u,className:`h-auto max-h-[500px] w-auto rounded-xl object-contain select-none ${i}`,style:{width:"auto",maxWidth:"100%",userSelect:"none",display:"block"},onLoad:N,onError:w,onContextMenu:e=>e.preventDefault(),onDragStart:e=>e.preventDefault(),draggable:!1}):null:o?(0,r.jsxs)("div",{className:"flex h-[90vh] w-[90vw] items-center justify-center",children:[(0,r.jsx)("div",{className:"h-16 w-16 animate-spin rounded-full border-b-2 border-t-2 border-primary"}),(0,r.jsx)("img",{ref:v,src:S,alt:"",onLoad:N,onError:w,style:{display:"none"}})]}):"feed"===d?(0,r.jsxs)("div",{className:`flex h-full w-full items-center justify-center bg-muted/20 ${i}`,children:[(0,r.jsx)("div",{className:"h-8 w-8 animate-spin rounded-full border-b-2 border-t-2 border-primary"}),(0,r.jsx)("img",{ref:v,src:S,alt:"",onLoad:N,onError:w,style:{display:"none"}})]}):"flexible"===d?(0,r.jsxs)("div",{className:`flex items-center justify-center bg-muted/20 ${i}`,children:[(0,r.jsx)("div",{className:"h-8 w-8 animate-spin rounded-full border-b-2 border-t-2 border-primary"}),(0,r.jsx)("img",{ref:v,src:S,alt:"",onLoad:N,onError:w,style:{display:"none"}})]}):(0,r.jsxs)("div",{className:`flex min-h-[200px] items-center justify-center rounded-xl bg-background/80 backdrop-blur-sm ${i}`,style:{width:"auto",maxWidth:"100%"},children:[(0,r.jsx)("div",{className:"h-12 w-12 animate-spin rounded-full border-b-2 border-t-2 border-primary"}),(0,r.jsx)("img",{ref:v,src:S,alt:"",onLoad:N,onError:w,style:{display:"none"}})]})}e.s(["StorageImage",()=>s])},998763,972134,239386,782197,e=>{"use strict";e.s([],972134),e.s([],998763);var r=e.i(474831),t=(0,r.createServerReference)("78b7f76473ead60a9a0983514af9bde2c5066242d7",r.callServer,void 0,r.findSourceMapURL,"generateImage");e.s(["generateImage",()=>t],239386);var a=(0,r.createServerReference)("40a2a062d818402e15c90e3bfad19d371a9b553f0c",r.callServer,void 0,r.findSourceMapURL,"refundImageGenerationTokens");e.s(["refundImageGenerationTokens",()=>a],782197)},483817,e=>{"use strict";var r=e.i(474831),t=(0,r.createServerReference)("7f9d98424086d3d4a1f14fefca6d0612c2521bb7f6",r.callServer,void 0,r.findSourceMapURL,"generateGalleryImage");e.s(["generateGalleryImage",()=>t])},232410,739256,874595,e=>{"use strict";var r=e.i(809528);e.i(998763),e.i(972134);var t=e.i(239386);e.i(782197),e.i(483817);var a=e.i(474831);a.callServer,a.findSourceMapURL;var l=(0,a.createServerReference)("701a89b3c99239d8e3594aa7bf5848e9dab322fe3b",a.callServer,void 0,a.findSourceMapURL,"getGalleryImages"),s=(0,a.createServerReference)("40e9d247265fcfb713076066e927b02a7219a19744",a.callServer,void 0,a.findSourceMapURL,"deleteGalleryImage");a.callServer,a.findSourceMapURL;var n=e.i(741315),i=(0,a.createServerReference)("60575a677a97baba1142e890537eb6b51294647442",a.callServer,void 0,a.findSourceMapURL,"getPublicImageSignedUrl"),o=(0,a.createServerReference)("603c69c776ad4d7ee5bbf0c40e80cc6f798298a9fe",a.callServer,void 0,a.findSourceMapURL,"getBatchPublicImageSignedUrls");e.s(["getBatchPublicImageSignedUrls",()=>o],739256),a.callServer,a.findSourceMapURL,a.callServer,a.findSourceMapURL,a.callServer,a.findSourceMapURL,a.callServer,a.findSourceMapURL,a.callServer,a.findSourceMapURL,a.callServer,a.findSourceMapURL,a.callServer,a.findSourceMapURL;var c=(0,a.createServerReference)("406859a50955dc447f388d2d00318cc54b73a2278b",a.callServer,void 0,a.findSourceMapURL,"unlockImage");e.s(["deleteGalleryImage",()=>s,"generateImage",()=>t.generateImage,"getBatchPublicImageSignedUrls",()=>o,"getGalleryImages",()=>l,"getImageSignedUrl",()=>n.getImageSignedUrl,"getPublicImageSignedUrl",()=>i,"unlockImage",()=>c],874595);var n=n,d=e.i(975157);let u=new Map;function f(e,r){let t=u.get(e);return t||(t=r().finally(()=>u.delete(e)),u.set(e,t)),t}function m(e,t=d.CACHE_CONFIG.IMAGE_PREFIX){let[a,l]=(0,r.useState)(null),[s,i]=(0,r.useState)(!0),[o,c]=(0,r.useState)(null),u=(0,r.useCallback)(async(r=()=>!1)=>
1{if(!e){c("No storage key provided"),i(!1);return}try{i(!0),c(null),l(null);let a=(0,d.getCachedUrl)(e,t);if(a){l((0,d.toCdnMediaUrl)(a)),i(!1);return}let s=await f(`priv:${t}${e}`,()=>(0,n.getImageSignedUrl)(e));if(r())return;let o=s.data?.signedUrl;s.success&&o?(l((0,d.toCdnMediaUrl)(o)),(0,d.cacheUrl)(e,o,t)):c(s.error||"Failed to load image")}catch(e){if(r())return;console.error("Error loading image:",e),c("Error loading image")}finally{r()||i(!1)}},[e,t]);return(0,r.useEffect)(()=>{let r=!1;return e?u(()=>r):(c("No storage key provided"),i(!1)),()=>{r=!0}},[e,t,u]),{imageUrl:a,isLoading:s,error:o,retry:()=>{u()}}}function g(e,t=d.CACHE_CONFIG.IMAGE_PREFIX){let[a,l]=(0,r.useState)(null),[s,n]=(0,r.useState)(!0),[o,c]=(0,r.useState)(null),u=(0,r.useCallback)(async(r=()=>!1)=>{if(!e){c("No storage key provided"),n(!1);return}try{n(!0),c(null),l(null);let a=(0,d.getCachedUrl)(e,t);if(a){l((0,d.toCdnMediaUrl)(a)),n(!1);return}let s=await f(`pub:${t}${e}`,()=>i(e));if(r())return;let o=s.data?.signedUrl;s.success&&o?(l((0,d.toCdnMediaUrl)(o)),(0,d.cacheUrl)(e,o,t)):c(s.error||"Failed to load image")}catch(e){if(r())return;console.error("Error loading public image:",e),c("Error loading image")}finally{r()||n(!1)}},[e,t]);return(0,r.useEffect)(()=>{let r=!1;return e?u(()=>r):(c("No storage key provided"),n(!1)),()=>{r=!0}},[e,t,u]),{imageUrl:a,isLoading:s,error:o,retry:()=>{u()}}}async function h(e,r=d.CACHE_CONFIG.IMAGE_PREFIX){let t={},a=[];for(let l of e){if(!l)continue;let e=(0,d.getCachedUrl)(l,r);e?t[l]=e:a.push(l)}if(0===a.length)return t;try{let e=await o(a);for(let[a,l]of Object.entries(e))t[a]=l,(0,d.cacheUrl)(a,l,r)}catch(e){console.error("Error batch loading images:",e)}return t}e.s(["fetchMultipleCachedImages",()=>h,"useCachedImage",()=>m,"usePublicCachedImage",()=>g],232410)},755170,152392,e=>{"use strict";var r=e.i(260293),t=e.i(809528),a=e.i(548136),l=e.i(975157);function s({threshold:e=.5,rootMargin:r="0px",enabled:a=!0}={}){let[l,n]=(0,t.useState)(!1),[i,o]=(0,t.useState)(!1),c=(0,t.useRef)(null);return(0,t.useEffect)(()=>{if(!a||!c.current)return;let t=new IntersectionObserver(([e])=>{let r=e.isIntersecting;n(r),r&&!i&&o(!0)},{threshold:e,rootMargin:r});return t.observe(c.current),()=>{t.disconnect()}},[e,r,a,i]),{elementRef:c,isIntersecting:l,hasIntersected:i}}e.s(["useIntersectionObserver",()=>s],152392);var n=e.i(232410);e.s(["default",0,({modelName:e,altOverride:i,userId:o,userGeneratedImagePath:c,prefetchedImageUrl:d,alternateImageUrls:u,hoverCycleInterval:f=1500,autoCycle:m=!1,className:g="",onMouseEnter:h,onMouseLeave:p,coverImageFilename:x,videoFilename:b,isPublicCharacter:v=!1,priority:j=!1,prefetchedVideoUrl:y,primaryMediaType:S,onVideoPlayingChange:N,priorityVideo:w=!1,preloadVideo:U=!1})=>{let[I,k]=(0,t.useState)(!1),[C,E]=(0,t.useState)(!1),[M,R]=(0,t.useState)(!1),[$,L]=(0,t.useState)(0),[D,A]=(0,t.useState)(!1),P=!d&&c,{imageUrl:F,isLoading:G}=v?(0,n.usePublicCachedImage)(P?c:null):(0,n.useCachedImage)(P?c:null),T=d||F,O=(0,t.useRef)(null),V=(0,t.useRef)(null),[_,B]=(0,t.useState)(!1),[H,W]=(0,t.useState)(!1),z=null!=o,X=z&&!!c,{elementRef:q,isIntersecting:K}=s({threshold:.6,rootMargin:"0px 0px -10% 0px",enabled:M});(0,t.useEffect)(()=>{R((0,l.isMobileDevice)())},[]),(0,t.useEffect)(()=>{T&&A(!1)},[T]),(0,t.useEffect)(()=>{if(!m||!u||0===u.length)return;let e=setTimeout(()=>{u.forEach(e=>{new window.Image().src=(0,l.getCharacterMediaUrl)(e)})},2e3);return()=>clearTimeout(e)},[m,u]);let[J,Q]=(0,t.useState)(m);(0,t.useEffect)(()=>{(m||I)&&Q(!0)},[m,I]),(0,t.useEffect)(()=>{if("VIDEO"!==S||!y)return;if(!m&&!I){W(!1),N?.(!1);return}let e=setTimeout(()=>{W(!0)},2e3*!w);return()=>clearTimeout(e)},[S,y,m,I,w]),(0,t.useEffect)(()=>{if(!H||!V.current||!y)return;let e=V.current;m||I||M&&K?e.play().then(()=>N?.(!0)).catch(e=>console.error("User video play error:",e)):(e.pause(),e.currentTime=0,B(!1),N?.(!1))},[H,m,I,M,K,y]),(0,t.useEffect)(()=>{if(!((m||I)&&u&&u.length>0&&(m||X))){m||L(0);return}let e=setInterval(()=>{L(e=>(e+1)%(u.length+1))},f);return()=>clearInterval(e)},[I,u,f,X,m]),(0,t.useEffect)(()=>{M&&K&&("VIDEO"===S&&y?W(!0):O.current&&O.current.play().then(()=>E(!0)).catch(e=>console.error("Video play error:",e)))},[M,K,S,y]),(0,t.useEffect)(()=>{M&&!K&&O.current&&(O.current.pause(),O.current.currentTime=0)},[M,K]),(0,t.useEffect)(()=>{U&&y&&V.current&&"VIDEO"===S&&(V.current.preload="auto",V.current.load())},[U,y,S]),(0,t.useEffect)(()=>{z||!O.current||m&&w&&O.current.play().then(()=>{E(!0),N?.(!0)}).catch(e=>console.error("Video play error:",e))},[z,m,w]),(0,t.useEffect)(()=>{!z&&U&&O.current&&(O.current.preload="auto",O.current.load())},[z,U]);let Y=M?K&&C:(I||m)&&C;return(0,r.jsx)("div",{ref:q,className:`relative ${g}`,onMouseEnter:()=>{k(!0),o||c||!O.current||O.current.play().then(()=>E(!0)).catch(e=>console.error("Video play error:",e)),h&&h()},onMouseLeave:()=>{k(!1),O.current&&(O.current.pause(),O.current.currentTime=0),V.current&&!m&&(V.current.pause(),V.current.currentTime=0),p&&p()},onContextMenu:e=>(e.preventDefault(),!1),children:z?(()=>
1{let t="VIDEO"===S?[T].filter(Boolean):[T,...u||[]].filter(Boolean);if(t.length>0&&!D){let a="VIDEO"===S&&_&&(m||I||M&&K);return(0,r.jsxs)("div",{className:"relative h-full w-full",children:[t.map((t,a)=>{if(a>0&&!J)return null;let s="VIDEO"===S||a===$;return(0,r.jsx)("img",{src:(0,l.getCharacterMediaUrl)(t),alt:i||e,loading:0===a&&j?"eager":"lazy",className:`absolute inset-0 h-full w-full select-none rounded-lg object-cover object-top transition-opacity duration-150 ease-in-out ${s?"opacity-100":"opacity-0"}`,draggable:"false",onContextMenu:e=>e.preventDefault(),onDragStart:e=>e.preventDefault(),onError:0===a?()=>A(!0):void 0,style:{userSelect:"none",WebkitUserSelect:"none",MozUserSelect:"none",msUserSelect:"none",WebkitTouchCallout:"none"}},`${a}-${t}`)}),"VIDEO"===S&&y&&(0,r.jsx)("video",{ref:V,className:`absolute inset-0 h-full w-full select-none rounded-lg object-cover transition-opacity duration-300 ease-in-out ${a?"opacity-100":"opacity-0"}`,muted:!0,loop:!m,playsInline:!0,preload:"none",draggable:"false",onDragStart:e=>e.preventDefault(),onContextMenu:e=>e.preventDefault(),onPlaying:()=>B(!0),onEnded:()=>{B(!1),m&&N?.(!1)},children:(0,r.jsx)("source",{src:(0,l.getMediaVideoUrl)(y),type:"video/mp4"})})]})}return G?(0,r.jsx)("div",{className:"h-full w-full rounded-lg bg-gradient-to-br from-primary/10 via-pink-500/10 to-purple-500/10"}):(0,r.jsx)("div",{className:"flex h-full w-full items-center justify-center rounded-lg bg-gradient-to-br from-primary/10 via-pink-500/10 to-purple-500/10",children:(0,r.jsx)("span",{className:"text-lg font-semibold text-primary/60",children:e.charAt(0).toUpperCase()})})})():(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(a.default,{src:(0,l.getModelCoverUrl)(e,x),alt:i||e,width:400,height:712,quality:85,loading:j?"eager":"lazy",priority:j,className:"h-full w-full rounded-lg object-cover opacity-100",draggable:"false",onDragStart:e=>e.preventDefault()}),b&&(0,r.jsx)("video",{ref:O,className:`absolute inset-0 h-full w-full rounded-lg object-cover ${Y?"opacity-100":"opacity-0"}`,muted:!0,loop:!m,playsInline:!0,preload:"none",draggable:"false",onDragStart:e=>e.preventDefault(),onEnded:()=>{m&&N?.(!1)},children:(0,r.jsx)("source",{src:(0,l.getModelVideoUrl)(e,b),type:"video/mp4"})})]})})}],755170)},753959,e=>{"use strict";var r=e.i(260293),t=e.i(799676),a=e.i(755170),l=e.i(975157);e.s(["ModelAvatar",0,({modelName:e,userId:s,userGeneratedImagePath:n,prefetchedImageUrl:i,size:o="md",className:c="",coverImageFilename:d,showOnlineIndicator:u=!1})=>{let f={sm:"h-8 w-8",md:"h-10 w-10",lg:"h-11 w-11",xl:"h-20 w-20"}[o],m={sm:"h-1.5 w-1.5",md:"h-2 w-2",lg:"h-2.5 w-2.5",xl:"h-3.5 w-3.5"}[o];return null!=s?(0,r.jsxs)("div",{className:"relative",children:[(0,r.jsx)("div",{className:`${f} flex-shrink-0 overflow-hidden rounded-full border border-primary/20 ${c}`,children:(0,r.jsx)(a.default,{modelName:e,userId:s,userGeneratedImagePath:n,prefetchedImageUrl:i,className:"h-full w-full",priority:!0})}),u&&(0,r.jsx)("div",{className:"absolute bottom-0 right-0",children:(0,r.jsx)("div",{className:`${m} rounded-full bg-green-500 ring-2 ring-background`})})]}):(0,r.jsxs)("div",{className:"relative",children:[(0,r.jsxs)(t.Avatar,{className:`${f} flex-shrink-0 border border-primary/20 ${c}`,children:[(0,r.jsx)(t.AvatarImage,{className:"object-cover object-top",src:(0,l.getModelCoverUrl)(e,d),alt:e}),(0,r.jsx)(t.AvatarFallback,{className:"bg-primary/20",children:e.charAt(0)})]}),u&&(0,r.jsx)("div",{className:"absolute bottom-0 right-0",children:(0,r.jsx)("div",{className:`${m} rounded-full bg-green-500 ring-2 ring-background`})})]})}])},48395,e=>{"use strict";let r=(0,e.i(286796).default)("UserRound",[["circle",{cx:"12",cy:"8",r:"5",key:"1hypcn"}],["path",{d:"M20 21a8 8 0 0 0-16 0",key:"rfgkzh"}]]);e.s(["UserRound",()=>r],48395)},304424,e=>{"use strict";var r=e.i(260293),t=e.i(822388),a=e.i(707061),l=e.i(317877),s=e.i(132786),n=e.i(753959),i=e.i(258221),o=e.i(746513),c=e.i(975157);let d=["from-teal-500/50 via-slate-800 to-slate-950","from-violet-500/50 via-slate-800 to-slate-950","from-amber-500/50 via-slate-800 to-slate-950","from-rose-500/50 via-slate-800 to-slate-950","from-sky-500/50 via-slate-800 to-slate-950","from-emerald-500/50 via-slate-800 to-slate-950"],u=e=>d[[...e].reduce((e,r)=>e+r.charCodeAt(0),0)%d.length],f={1:[{clip:"polygon(0 0, 100% 0, 100% 100%, 0 100%)",box:{top:0,left:0,width:100,height:100}}],2:[{clip:"polygon(0 0, 53.5% 0, 46.5% 100%, 0 100%)",box:{top:0,left:0,width:53.5,height:100}},{clip:"polygon(54.5% 0, 100% 0, 100% 100%, 47.5% 100%)",box:{top:0,left:46.5,width:53.5,height:100}}],3:[{clip:"polygon(0 0, 100% 0, 100% 42.5%, 0 49.5%)",box:{top:0,left:0,width:100,height:49}},{clip:"polygon(0 50.5%, 49.4% 47%, 49.4% 100%, 0 100%)",box:{top:48.5,left:0,width:49.4,height:51.5}},{clip:"polygon(50.6% 46.9%, 100% 43.5%, 100% 100%, 50.6% 100%)",box:{top:45,left:50.6,width:49.4,height:55}}],4:[{clip:"polygon(0 0, 49.4% 0, 49.4% 49%, 0 52.5%)",box:{top:0,left:0,width:49.4,height:52}},{clip:"polygon(50.6% 0, 100% 0, 100% 45.5%, 50.6% 49%)",box:{top:0,left:50.6,width:49.4,height:49}},{clip:"polygon(0 54.5%, 49.4% 51%, 49.4% 100%, 0 100%)",box:{top:52.5,left:0,width:49.4,height:47.5}},{clip:"polygon(50.6% 51%, 100% 47.5%, 100% 100%, 50.6% 100%)",box:{top:49,left:50.6,width:49.4,height:51}}]};function m({cast:e,seed:t,className:a,priority:l=!1}){let s=e.slice(0,4),n=f[Math.max(1,s.length)];
1return(0,r.jsxs)("div",{className:(0,c.cn)("relative overflow-hidden bg-slate-950",a),children:[0===s.length?(0,r.jsx)("div",{className:(0,c.cn)("absolute inset-0 bg-gradient-to-br",u(t))}):null,s.map((e,a)=>{let{clip:s,box:o}=n[a],d=0===o.top?"object-[50%_15%]":"object-top";return(0,r.jsx)("div",{className:"absolute inset-0",style:{clipPath:s},title:e.name?`${e.name} — ${e.role}`:e.role,children:(0,r.jsx)("div",{className:"absolute overflow-hidden",style:{top:`${o.top}%`,left:`${o.left}%`,width:`${o.width}%`,height:`${o.height}%`},children:e.avatarPath?(0,r.jsx)(i.StorageImage,{path:e.avatarPath,preResolvedUrl:e.avatarUrl??void 0,alt:e.name??e.role,layout:"flexible",loading:l?"eager":"lazy",className:(0,c.cn)("h-full w-full object-cover transition-transform duration-700 group-hover:scale-[1.04]",d)}):(0,r.jsx)("div",{className:(0,c.cn)("h-full w-full bg-gradient-to-br",u(`${t}${a}`))})})},`${e.role}-${a}`)})]})}function g({s:e,className:t}){let l=(0,a.useTranslations)("mp.scenario");return(0,r.jsxs)("div",{className:(0,c.cn)("flex flex-wrap items-center gap-1 font-mono text-[9px] uppercase tracking-wider sm:gap-1.5 sm:text-[10px]",t),children:[(0,r.jsxs)("span",{className:"inline-flex items-center gap-1.5 rounded-full bg-black/5 dark:bg-white/5 px-2 py-0.5 text-foreground ring-1 ring-black/10 dark:ring-white/10",children:[(0,r.jsx)("span",{className:(0,c.cn)("h-1.5 w-1.5 rounded-full",e.isSfw?"bg-emerald-400":"bg-rose-400")}),l(e.isSfw?"badgeSfw":"badgeNsfw")]}),(0,r.jsx)("span",{className:"rounded-full bg-black/5 dark:bg-white/5 px-2 py-0.5 text-muted-foreground ring-1 ring-black/10 dark:ring-white/10",children:l(e.isAnime?"badgeAnime":"badgeRealistic")}),e.isHouse?(0,r.jsxs)("span",{className:"inline-flex items-center gap-1 rounded-full bg-teal-500/10 px-2 py-0.5 text-teal-800 dark:text-teal-200 ring-1 ring-teal-400/30",children:[(0,r.jsx)(s.Sparkles,{className:"h-2.5 w-2.5"})," ",l("badgeHouse")]}):null]})}function h({cast:e,size:t="sm",className:a}){return(0,r.jsx)("div",{className:(0,c.cn)("flex -space-x-2",a),children:e.slice(0,4).map((e,a)=>(0,r.jsx)("div",{className:"rounded-full ring-2 ring-slate-950",title:e.name?`${e.name} — ${e.role}`:e.role,children:(0,r.jsx)(n.ModelAvatar,{modelName:e.name??e.role,userId:e.modelUserId,userGeneratedImagePath:e.avatarPath??void 0,coverImageFilename:e.coverImageFilename??void 0,size:t})},`${e.role}-${a}`))})}function p({s:e}){let s=(0,a.useTranslations)("mp.scenario"),n=e.cast.length;return(0,r.jsxs)(t.default,{href:(0,o.scenarioPath)(e.slug),className:"group relative flex flex-col overflow-hidden rounded-2xl border border-black/10 dark:border-white/10 bg-card transition-all duration-300 hover:-translate-y-0.5 hover:border-teal-400/40 hover:shadow-xl hover:shadow-teal-500/10",children:[(0,r.jsx)("div",{className:"relative aspect-[3/4] w-full",children:(0,r.jsx)(m,{cast:e.cast,seed:e.slug,className:"absolute inset-0"})}),(0,r.jsxs)("div",{className:"flex flex-1 flex-col gap-2 p-3",children:[(0,r.jsxs)("div",{className:"flex flex-wrap items-center gap-1 sm:gap-1.5",children:[(0,r.jsx)(g,{s:e}),(0,r.jsxs)("span",{className:"inline-flex items-center gap-1 rounded-full bg-black/5 dark:bg-white/5 px-2 py-0.5 font-mono text-[9px] uppercase tracking-wider text-muted-foreground ring-1 ring-black/10 dark:ring-white/10 sm:text-[10px]",children:[(0,r.jsx)(l.Users,{className:"h-3 w-3"})," ",s("castCount",{count:n})]})]}),(0,r.jsxs)("div",{children:[(0,r.jsx)("h3",{className:"font-mono text-base font-semibold leading-tight",children:e.title}),e.tagline?(0,r.jsx)("p",{className:"mt-1 line-clamp-2 text-xs text-muted-foreground",children:e.tagline}):null]}),(0,r.jsx)("ul",{className:"mt-auto flex flex-col gap-0.5 border-t border-black/5 dark:border-white/5 pt-2",children:e.cast.slice(0,4).map((e,t)=>(0,r.jsxs)("li",{className:"flex min-w-0 items-baseline gap-1.5 text-xs",children:[(0,r.jsx)("span",{className:"shrink-0 font-mono text-foreground",children:e.name??s("anyCharacter")}),(0,r.jsxs)("span",{className:"truncate text-muted-foreground",children:["· ",e.role]})]},`${e.role}-${t}`))})]})]})}e.s(["CastAvatars",()=>h,"CastMosaic",()=>m,"ScenarioBadges",()=>g,"ScenarioCard",()=>p])},76090,e=>{"use strict";var r=e.i(260293),t=e.i(822388),a=e.i(316058);function l({href:e,className:l,children:s}){let{isAuthenticated:n,isLoading:i}=(0,a.useAuth)(),{openModal:o}=(0,a.useAuthModal)();return(0,r.jsx)(t.default,{href:e,className:l,onClick:e=>{n||i||(e.preventDefault(),o())},children:s})}e.s(["AuthGateLink",()=>l])},572192,e=>{"use strict";var r=e.i(260293),t=e.i(809528),a=e.i(822388),l=e.i(707061),s=e.i(804259),n=e.i(168867),i=e.i(593940),o=e.i(48395),c=e.i(519455),d=e.i(793479),u=e.i(934631),f=e.i(474831),m=(0,f.createServerReference)("40dd1aa8e9bc8232c561bbfca399de7a663c905c4b",f.callServer,void 0,f.findSourceMapURL,"lookupUser");function g(){let e=(0,l.useTranslations)("mp.findPlayer"),[f,g]=(0,t.useState)(""),[h,p]=(0,t.useState)(!1),[x,b]=(0,t.useState)(null),[v,j]=(0,t.useState)(null),y=async()=>
1{if(!h&&f.trim()){p(!0),b(null),j(null);try{let r=await m(f);if(!r.success)return void j("unavailable"===r.error?e("unavailable"):e("notFound"));if(!r.user)return void j(e("notFound"));b(r.user)}catch{j(e("notFound"))}finally{p(!1)}}};return(0,r.jsxs)("div",{className:"rounded-2xl border border-border/60 bg-card p-5",children:[(0,r.jsxs)("div",{className:"flex items-start gap-2",children:[(0,r.jsx)(o.UserRound,{className:"mt-0.5 h-4 w-4 shrink-0 text-teal-700 dark:text-teal-300"}),(0,r.jsxs)("div",{children:[(0,r.jsx)("h2",{className:"font-mono text-sm font-semibold",children:e("title")}),(0,r.jsx)("p",{className:"text-xs text-muted-foreground",children:e("hint")})]})]}),(0,r.jsxs)("form",{className:"mt-4 flex gap-2",onSubmit:e=>{e.preventDefault(),y()},children:[(0,r.jsx)(d.Input,{value:f,onChange:e=>g(e.target.value),placeholder:e("placeholder"),className:"rounded-full",autoComplete:"off",spellCheck:!1}),(0,r.jsx)(c.Button,{type:"submit",className:"rounded-full",disabled:h||!f.trim(),"aria-label":e("title"),children:h?(0,r.jsx)(n.Loader2,{className:"h-4 w-4 animate-spin"}):(0,r.jsx)(s.Search,{className:"h-4 w-4"})})]}),v?(0,r.jsx)("p",{className:"mt-3 text-xs text-muted-foreground",children:v}):null,x?(0,r.jsxs)(a.default,{href:`/profile/${x.username}`,className:"mt-4 flex items-center gap-3 rounded-2xl border border-teal-400/30 bg-teal-500/5 p-3 transition-colors hover:bg-teal-500/10",children:[(0,r.jsx)(u.UserAvatar,{avatarUrl:x.avatarSignedUrl??void 0,avatarSeed:x.avatarSeed??void 0,email:x.username,size:"md"}),(0,r.jsxs)("div",{className:"min-w-0 flex-1",children:[(0,r.jsx)("div",{className:"truncate text-sm font-medium",children:x.displayName||x.username}),(0,r.jsxs)("div",{className:"truncate text-xs text-muted-foreground",children:["@",x.username,x.bio?` \xb7 ${x.bio}`:""]})]}),(0,r.jsxs)("span",{className:"inline-flex items-center gap-1 text-xs text-teal-700 dark:text-teal-300",children:[e("open")," ",(0,r.jsx)(i.ArrowRight,{className:"h-3.5 w-3.5"})]})]}):null]})}e.s(["FindPlayer",()=>g],572192)},463439,e=>{"use strict";var r=e.i(260293),t=e.i(809528),a=e.i(573817),l=e.i(804259),s=e.i(477272),n=e.i(707061);function i(){let e=(0,n.useTranslations)("mp.search"),i=(0,a.useRouter)(),o=(0,a.useSearchParams)(),[c,d]=(0,t.useState)(o.get("q")??""),u=e=>{let r=new URLSearchParams(o.toString()),t=e.trim();t.length>=2?r.set("q",t):r.delete("q"),i.push(r.toString()?`?${r.toString()}`:"/worlds",{scroll:!1})};return(0,r.jsxs)("form",{onSubmit:e=>{e.preventDefault(),u(c)},className:"relative w-full max-w-sm",children:[(0,r.jsx)(l.Search,{className:"pointer-events-none absolute left-3 top-1/2 h-4 w-4 -translate-y-1/2 text-muted-foreground"}),(0,r.jsx)("input",{value:c,onChange:e=>d(e.target.value.slice(0,80)),placeholder:e("hubPlaceholder"),className:"w-full rounded-full border border-black/10 dark:border-white/10 bg-muted/30 py-2 pl-9 pr-9 text-sm outline-none ring-teal-400/40 placeholder:text-muted-foreground/60 focus:ring-2"}),c?(0,r.jsx)("button",{type:"button",onClick:()=>{d(""),u("")},"aria-label":e("clear"),className:"absolute right-2 top-1/2 -translate-y-1/2 rounded-full p-1 text-muted-foreground hover:text-foreground",children:(0,r.jsx)(s.X,{className:"h-3.5 w-3.5"})}):null]})}e.s(["HubSearchBox",()=>i])},554394,e=>{e.v(r=>Promise.all(["static/chunks/df320ba7fcbccb2f.js"].map(r=>e.l(r))).then(()=>r(189698)))}]);

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.