1import{f as v,bs as b,j as e,h as i,i as r,F as C,k as a,m as l,e as j,a4 as m,B as x,L as h,a as u,U as k,A,J as D}from"./index-DLd_kDlx.js";import{D as f}from"./DashboardLayout-Bnmkd53o.js";import{P}from"./plus-0WhrdjYO.js";import{T as R}from"./trending-up-BU4cR3Ys.js";import{R as g,T as N,C as T}from"./generateCategoricalChart-ByDL-d9M.js";import{L as B,a as y}from"./LineChart-BqKg5nac.js";import{C as L}from"./CartesianGrid-ChidKd9i.js";import{X as Y,Y as J}from"./YAxis-BtEb5zMI.js";import{P as E,a as W}from"./PieChart-Bcnc_bSW.js";import"./dropdown-menu-DSd1c3Vk.js";import"./index-Deh-4PO1.js";import"./index-lTaZyIGy.js";import"./chevron-right-CD1gvy-q.js";import"./briefcase-business-CphIeAJd.js";import"./user-plus-CSalqUlO.js";import"./git-pull-request-__1fAqC3.js";import"./message-square-CtxeCfRz.js";import"./search-DFH5eAlA.js";import"./findIndex-Cos7Fxsp.js";import"./tiny-invariant-CopsF_GD.js";import"./PolarAngleAxis-Blx3t8Nb.js";const X=[{month:"Jan",applications:145,hires:23},{month:"Feb",applications:162,hires:31},{month:"Mar",applications:198,hires:28},{month:"Apr",applications:221,hires:35},{month:"May",applications:267,hires:42},{month:"Jun",applications:289,hires:38}],w=[{name:"React",value:35,color:"#8884d8"},{name:"Python",value:30,color:"#82ca9d"},{name:"Node.js",value:20,color:"#ffc658"},{name:"Java",value:15,color:"#ff7300"}],K=[{id:1,name:"Sarah Chen",position:"Frontend Developer",status:"pending",time:"2 hours ago"},{id:2,name:"Marcus Johnson",position:"Data Scientist",status:"interview",time:"4 hours ago"},{id:3,name:"Emily Rodriguez",position:"UX Designer",status:"hired",time:"1 day ago"},{id:4,name:"David Kim",position:"Backend Developer",status:"pending",time:"1 day ago"}],oe=()=>{var p;const{user:n}=v(),{assessmentStatus:s}=b(),o=(p=n==null?void 0:n.roles)==null?void 0:p.includes("xtern"),c=s==null?void 0:s.assessmentCompleted;return o&&!c?e.jsx(f,{children:e.jsxs("div",{className:"space-y-8",children:[e.jsxs("div",{className:"text-center",children:[e.jsx("h1",{className:"text-3xl font-bold text-gray-900",children:"Welcome to Xterns!"}),e.jsx("p",{className:"text-gray-600 mt-1",children:"Start building through simulations and profile work now. Complete verification later to unlock paid opportunities."})]}),e.jsxs(i,{className:"max-w-2xl mx-auto",children:[e.jsxs(r,{className:"text-center",children:[e.jsx("div",{className:"flex justify-center mb-4",children:e.jsx(C,{className:"w-12 h-12 text-warning"})}),e.jsx(a,{className:"text-xl",children:"Verification Recommended"})]}),e.jsxs(l,{className:"space-y-4",children:[e.jsxs("div",{className:"text-center",children:[e.jsx("p",{className:"text-sm text-muted-foreground mb-3",children:F(s)}),e.jsx("div",{className:"w-full bg-secondary rounded-full h-2 mb-4",children:e.jsx("div",{className:"bg-primary h-2 rounded-full transition-all duration-300",style:{width:`${M(s)}%`}})}),e.jsxs("div",{className:"flex justify-between items-center text-xs text-muted-foreground mb-6",children:[e.jsxs("div",{className:"flex items-center space-x-1",children:[s!=null&&s.stage1Completed?e.jsx(j,{className:"w-4 h-4 text-success"}):e.jsx(m,{className:"w-4 h-4"}),e.jsx("span",{children:"Experience"})]}),e.jsxs("div",{className:"flex items-center space-x-1",children:[s!=null&&s.stage2Completed?e.jsx(j,{className:"w-4 h-4 text-success"}):e.jsx(m,{className:"w-4 h-4"}),e.jsx("span",{children:"Bio Data"})]}),e.jsxs("div",{className:"flex items-center space-x-1",children:[s!=null&&s.stage3Completed?e.jsx(j,{className:"w-4 h-4 text-success"}):e.jsx(m,{className:"w-4 h-4"}),e.jsx("span",{children:"Skills"})]})]})]}),e.jsxs("div",{className:"flex flex-col gap-4",children:[e.jsx(x,{asChild:!0,className:"w-full",children:e.jsx(h,{to:"/assessment",children:s!=null&&s.id?"Continue Assessment":"Start Assessment"})}),e.jsx("p",{className:"text-xs text-muted-foreground text-center",children:"Verification takes about 10-15 minutes and unlocks paid-role applications plus stronger employer visibility."})]})]})]}),e.jsxs("div",{className:"max-w-4xl mx-auto",children:[e.jsx("h2",{className:"text-xl font-semibold mb-4 text-center",children:"What you can do right now:"}),e.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-4",children:[e.jsxs(i,{children:[e.jsx(r,{children:e.jsx(a,{className:"text-lg",children:"Employer Simulations"})}),e.jsx(l,{children:e.jsx("p",{className:"text-sm text-muted-foreground",children:"Start open work-sample experiences immediately and begin building stronger proof of execution."})})]}),e.jsxs(i,{children:[e.jsx(r,{children:e.jsx(a,{className:"text-lg",children:"Profile Building"})}),e.jsx(l,{children:e.jsx("p",{className:"text-sm text-muted-foreground",children:"Improve your CV, skills profile, and learning evidence while your verification is still in progress."})})]}),e.jsxs(i,{children:[e.jsx(r,{children:e.jsx(a,{className:"text-lg",children:"Paid Opportunities Later"})}),e.jsx(l,{children:e.jsx("p",{className:"text-sm text-muted-foreground",children:"Complete verification to apply for paid work and become more visible to employer review flows."})})]})]})]})]})}):e.jsx(f,{children:e.jsxs("div",{className:"space-y-8",children:[e.jsxs("div",{className:"flex justify-between items-start",children:[e.jsxs("div",{children:[e.jsx("h1",{className:"text-3xl font-bold text-gray-900",children:o?"Xtern Dashboard":"Enterprise Dashboard"}),e.jsx("p",{className:"text-gray-600 mt-1",children:o?"Welcome back! Explore opportunities and grow your career.":"Welcome back! Here's what's happening with your hiring."})]}),e.jsxs("div",{className:"flex gap-3",children:[e.jsx(h,{to:"/projects/publish",children:e.jsxs(x,{children:[e.jsx(P,{className:"h-4 w-4 mr-2"}),"New Project"]})}),e.jsx(h,{to:"/job-post",children:e.jsxs(x,{variant:"outline",children:[e.jsx(u,{className:"h-4 w-4 mr-2"}),"Post Job"]})})]})]}),e.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-4 gap-6",children:[e.jsxs(i,{children:[e.jsxs(r,{className:"flex flex-row items-center justify-between space-y-0 pb-2",children:[e.jsx(a,{className:"text-sm font-medium",children:"Total Applications"}),e.jsx(R,{className:"h-4 w-4 text-muted-foreground"})]}),e.jsxs(l,{children:[e.jsx("div",{className:"text-2xl font-bold",children:"1,289"}),e.jsx("p",{className:"text-xs text-muted-foreground",children:"+12% from last month"})]})]}),e.jsxs(i,{children:[e.jsxs(r,{className:"flex flex-row items-center justify-between space-y-0 pb-2",children:[e.jsx(a,{className:"text-sm font-medium",children:"Active Candidates"}),e.jsx(k,{className:"h-4 w-4 text-muted-foreground"})]}),e.jsxs(l,{children:[e.jsx("div",{className:"text-2xl font-bold",children:"247"}),e.jsx("p",{className:"text-xs text-muted-foreground",children:"+8% from last month"})]})]}),e.jsxs(i,{children:[e.jsxs(r,{className:"flex flex-row items-center justify-between space-y-0 pb-2",children:[e.jsx(a,{className:"text-sm font-medium",children:"Open Positions"}),e.jsx(u,{className:"h-4 w-4 text-muted-foreground"})]}),e.jsxs(l,{children:[e.jsx("div",{className:"text-2xl font-bold",children:"23"}),e.jsx("p",{className:"text-xs text-muted-foreground",children:"+3 new this week"})]})]}),e.jsxs(i,{children:[e.jsxs(r,{className:"flex flex-row items-center justify-between space-y-0 pb-2",children:[e.jsx(a,{className:"text-sm font-medium",children:"Avg. Time to Hire"}),e.jsx(m,{className:"h-4 w-4 text-muted-foreground"})]}),e.jsxs(l,{children:[e.jsx("div",{className:"text-2xl font-bold",children:"14 days"}),e.jsx("p",{className:"text-xs text-muted-foreground",children:"-2 days from last month"})]})]})]}),e.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-2 gap-6",children:[e.jsxs(i,{children:[e.jsx(r,{children:e.jsx(a,{children:"Application Trends"})}),e.jsx(l,{children:e.jsx(g,{width:"100%",height:300,children:e.jsxs(B,{data:X,children:[e.jsx(L,{strokeDasharray:"3 3"}),e.jsx(Y,{dataKey:"month"}),e.jsx(J,{}),e.jsx(N,{}),e.jsx(y,{type:"monotone",dataKey:"applications",stroke:"#8884d8",strokeWidth:2}),e.jsx(y,{type:"monotone",dataKey:"hires",stroke:"#82ca9d",strokeWidth:2})]})})})]}),e.jsxs(i,{children:[e.jsx(r,{children:e.jsx(a,{children:"Top Skills in Demand"})}),e.jsx(l,{children:e.jsx(g,{width:"100%",height:300,children:e.jsxs(E,{children:[e.jsx(W,{data:w,cx:"50%",cy:"50%",labelLine:!1,label:({name:t,percent:d})=>`${t} ${(d*100).toFixed(0)}%`,outerRadius:80,fill:"#8884d8",dataKey:"value",children:w.map((t,d)=>e.jsx(T,{fill:t.color},`cell-${d}`))}),e.jsx(N,{})]})})})]})]}),e.jsxs(i,{children:[e.jsxs(r,{className:"flex flex-row items-center justify-between",children:[e.jsx(a,{children:"Recent Applications"}),e.jsx(h,{to:"/talent",children:e.jsxs(x,{variant:"outline",size:"sm",children:["View All",e.jsx(A,{className:"h-4 w-4 ml-2"})]})})]}),e.jsx(l,{children:e.jsx("div",{className:"space-y-4",children:K.map(t=>e.jsxs("div",{className:"flex items-center justify-between p-4 border rounded-lg",children:[e.jsxs("div",{className:"flex items-center space-x-4",children:[e.jsx("div",{className:"w-10 h-10 bg-gradient-to-r from-blue-500 to-purple-600 rounded-full flex items-center justify-center text-white font-semibold",children:t.name.split(" ").map(d=>d[0]).join("")}),e.jsxs("div",{children:[e.jsx("p",{className:"font-medium",children:t.name}),e.jsx("p",{className:"text-sm text-gray-600",children:t.position})]})]}),e.jsxs("div",{className:"flex items-center space-x-4",children:[e.jsx(D,{variant:t.status==="hired"?"default":t.status==="interview"?"secondary":"outline",children:t.status}),e.jsx("span",{className:"text-sm text-gray-500",children:t.time})]})]},t.id))})})]})]})})},F=n=>{if(!n)return"You haven't started your assessment yet.";const{stage1Completed:s,stage2Completed:o,stage3Completed:c}=n;return c?"Your assessment is almost complete! Just a few more steps.":o?"Great progress! You're on Stage 3 of your assessment.":s?"You're making progress! You're on Stage 2 of your assessment.":"You're on Stage 1 of your assessment."},M=n=>{if(!n)return 0;const{stage1Completed:s,stage2Completed:o,stage3Completed:c}=n;return c?100:o?75:s?50:25};export{oe 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.