PageSourceSearch

https://studiojungle.ai/assets/PublicProfile-7N7OD20m.js

js studiojungle.ai collected 2026-10-05 14:20:24 UTC 6,496 bytes, 16 lines download raw bytes

1import{c as d,O as _,s as x,j as e,L as o}from"./index-TQG2ztjm.js";import{r as n}from"./vendor-monaco-K2VEKovO.js";import{L as y}from"./loader-circle-9UcafR3w.js";import{L as f}from"./leaf-DisNpsTH.js";import{A as h}from"./arrow-left-ItJqViyp.js";import{G as k}from"./globe-DjgAQT17.js";import"./vendor-swagger-Bf7V8oR3.js";/**
2 * @license lucide-react v0.462.0 - ISC
3 *
4 * This source code is licensed under the ISC license.
5 * See the LICENSE file in the root directory of this source tree.
6 */const L=d("Linkedin",[["path",{d:"M16 8a6 6 0 0 1 6 6v7h-4v-7a2 2 0 0 0-2-2 2 2 0 0 0-2 2v7h-4v-7a6 6 0 0 1 6-6z",key:"c2jq9f"}],["rect",{width:"4",height:"12",x:"2",y:"9",key:"mk3on5"}],["circle",{cx:"4",cy:"4",r:"2",key:"bt5ra8"}]]);/**
7 * @license lucide-react v0.462.0 - ISC
8 *
9 * This source code is licensed under the ISC license.
10 * See the LICENSE file in the root directory of this source tree.
11 */const P=d("MapPin",[["path",{d:"M20 10c0 4.993-5.539 10.193-7.399 11.799a1 1 0 0 1-1.202 0C9.539 20.193 4 14.993 4 10a8 8 0 0 1 16 0",key:"1r0f0z"}],["circle",{cx:"12",cy:"10",r:"3",key:"ilqhr7"}]]);/**
12 * @license lucide-react v0.462.0 - ISC
13 *
14 * This source code is licensed under the ISC license.
15 * See the LICENSE file in the root directory of this source tree.
16 */const S=d("Twitter",[["path",{d:"M22 4s-.7 2.1-2 3.4c1.6 10-9.4 17.3-18 11.6 2.2.1 4.4-.6 6-2C3 15.5.5 9.6 3 5c2.2 2.6 5.6 4.1 9 4-.9-4.2 4-6.6 7-3.8 1.1 0 3-1.2 3-1.2z",key:"pff0z6"}]]);function A(){const{username:a}=_(),[r,s]=n.useState(null),[m,p]=n.useState([]),[g,l]=n.useState(!0),[j,u]=n.useState(!1);if(n.useEffect(()=>{if(!a)return;let t=!1;return(async()=>{l(!0),u(!1);const N=a.replace(/^@/,"").toLowerCase(),{data:i,error:v}=await x.from("profiles").select("user_id, display_name, username, avatar_url, banner_url, bio, location, website_url, linkedin_url, twitter_url").eq("username",N).eq("visibility","public").maybeSingle();if(t)return;if(v||!i){u(!0),l(!1);return}s(i);const{data:w}=await x.from("projects").select("id, name, thumbnail_url, created_at").eq("user_id",i.user_id).order("created_at",{ascending:!1}).limit(12);t||(p(w||[]),l(!1))})(),()=>{t=!0}},[a]),g)return e.jsxs("div",{className:"min-h-screen flex items-center justify-center text-muted-foreground",children:[e.jsx(y,{className:"w-5 h-5 animate-spin mr-2"})," Loading profile…"]});if(j||!r)return e.jsxs("div",{className:"min-h-screen flex flex-col items-center justify-center text-center px-6",children:[e.jsx(f,{className:"w-10 h-10 text-muted-foreground/40 mb-3"}),e.jsx("h1",{className:"text-lg font-semibold text-foreground",children:"Profile not found"}),e.jsx("p",{className:"text-sm text-muted-foreground mt-1.5 max-w-sm",children:"The user you're looking for either doesn't exist or has a private profile."}),e.jsxs(o,{to:"/",className:"text-sm text-primary hover:underline mt-4 inline-flex items-center gap-1.5",children:[e.jsx(h,{className:"w-4 h-4"})," Back to Studio Jungle"]})]});const b=(r.display_name||r.username||"?").slice(0,2).toUpperCase();return e.jsx("div",{className:"min-h-screen bg-background",children:e.jsxs("div",{className:"max-w-3xl mx-auto px-6 py-6",children:[e.jsxs(o,{to:"/",className:"text-xs text-muted-foreground hover:text-foreground inline-flex items-center gap-1.5 mb-4",children:[e.jsx(h,{className:"w-3.5 h-3.5"})," studiojungle.ai"]}),e.jsxs("div",{className:"rounded-2xl border bg-card overflow-hidden",children:[e.jsx("div",{className:"relative h-44 bg-gradient-to-br from-primary/20 via-emerald-300/20 to-teal-200/20",children:r.banner_url&&e.jsx("img",{src:r.banner_url,alt:"",className:"absolute inset-0 w-full h-full object-cover"})}),e.jsxs("div",{className:"px-6 pb-6 -mt-12 relative",children:[e.jsxs("div",{className:"flex items-end gap-4",children:[e.jsx("div",{className:"w-24 h-24 rounded-full ring-4 ring-card overflow-hidden bg-muted flex items-center justify-center text-2xl font-bold text-foreground shrink-0",children:r.avatar_url?e.jsx("img",{src:r.avatar_url,alt:"",className:"w-full h-full object-cover"}):b}),e.jsxs("div",{className:"flex-1 min-w-0 pb-1.5",children:[e.jsx("h1",{className:"text-xl font-semibold text-foreground truncate",children:r.display_name||`@${r.username}`}),e.jsxs("p",{className:"text-sm text-muted-foreground",children:["@",r.username]})]})]}),r.bio&&e.jsx("p",{className:"mt-4 text-sm text-foreground leading-relaxed whitespace-pre-line",children:r.bio}),e.jsxs("div",{className:"flex flex-wrap items-center gap-3 mt-4 text-[12px] text-muted-foreground",children:[r.location&&e.jsxs("span",{className:"inline-flex items-center gap-1.5",children:[e.jsx(P,{className:"w-3.5 h-3.5"})," ",r.location]}),r.website_url&&e.jsxs("a",{href:c(r.website_url),target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-1.5 hover:text-foreground",children:[e.jsx(k,{className:"w-3.5 h-3.5"})," Website"]}),r.linkedin_url&&e.jsxs("a",{href:c(r.linkedin_url,"linkedin.com/in/"),target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-1.5 hover:text-foreground",children:[e.jsx(L,{className:"w-3.5 h-3.5"})," LinkedIn"]}),r.twitter_url&&e.jsxs("a",{href:c(r.twitter_url,"twitter.com/").replace("@",""),target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-1.5 hover:text-foreground",children:[e.jsx(S,{className:"w-3.5 h-3.5"})," Twitter"]})]})]})]}),m.length>0&&e.jsxs("section",{className:"mt-8",children:[e.jsx("h2",{className:"text-sm font-semibold text-foreground mb-3",children:"Projects"}),e.jsx("div",{className:"grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 gap-3",children:m.map(t=>e.jsxs("div",{className:"rounded-xl border bg-card overflow-hidden",children:[e.jsx("div",{className:"h-32 bg-gradient-to-br from-emerald-500/15 via-teal-500/10 to-cyan-500/10 flex items-center justify-center",children:t.thumbnail_url?e.jsx("img",{src:t.thumbnail_url,alt:t.name,className:"w-full h-full object-cover object-top",loading:"lazy"}
16):e.jsx(f,{className:"w-6 h-6 text-muted-foreground/40"})}),e.jsx("div",{className:"p-3",children:e.jsx("p",{className:"text-sm font-medium text-foreground truncate",children:t.name})})]},t.id))})]}),e.jsxs("p",{className:"text-[11px] text-muted-foreground text-center mt-12",children:["Profile on ",e.jsx(o,{to:"/",className:"text-primary hover:underline",children:"Studio Jungle"})]})]})})}function c(a,r=""){const s=a.trim();return s?/^https?:\/\//i.test(s)?s:r&&!s.includes("/")?`https://${r}${s}`:`https://${s}`:"#"}export{A 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.