PageSourceSearch

https://www.resumio.ai/assets/DashboardPage-B1jUeTMx.js

js resumio.ai collected 2026-10-05 14:56:14 UTC 30,764 bytes, 1 lines download raw bytes

1import{j as e,A as W,i as T,q as _,y as Pe,z as Ee,p as me,D as Be,G as $e,H as Ae,I as he,J as G,K as H,N as K,O,Q as Te,S as _e,X as Me}from"./vendor-ui-CIS6Qz9y.js";import{c as ge,r as s,u as Ie}from"./vendor-react-CIGxEcP1.js";import{T as fe,A as We,R as q,O as Oe}from"./app-layout-BfMDeSVd.js";import{u as pe,a as E}from"./index-BaHIFxRN.js";import{u as be}from"./use-credits-status-CW4dKF4L.js";import{r as Ue,g as ze,R as V,C as Fe}from"./template-picker-dialog-rPJW1Ig_.js";import{P as Ve,a as Ge}from"./payment-success-dialog-B_nI9euk.js";import{R as He}from"./referral-card-B3luM4Nv.js";import"./vendor-supabase-C--0TtcN.js";import"./external-links-AIV8z4qi.js";import"./vendor-charts-DqS88uak.js";import"./template-category-DGWH4ww2.js";import"./PricingPlansGrid-D_EE4B3Y.js";import"./geo-location-Du2Ad3p5.js";const Ke=5e3;function qe({tpl:n,previewContent:c}){return e.jsx(fe,{template:n,previewContent:c})}function Je({onViewAll:n}){var I,P;const c=ge(),{profile:i}=pe(),m=s.useMemo(()=>Ue(i==null?void 0:i.industry),[i==null?void 0:i.industry]),l=s.useMemo(()=>ze(m),[m]),[f,h]=s.useState([]),[k,d]=s.useState(!0),[x,o]=s.useState(0),[b,B]=s.useState(!1),v=s.useRef(null),{status:w,loading:U}=be(),p=(I=w==null?void 0:w.allowed_template_ids)==null?void 0:I.resume,z=!((P=w==null?void 0:w.features)!=null&&P.all_templates)&&((p==null?void 0:p.length)??0)>0,D=a=>z&&!((p==null?void 0:p.includes(a.id))??!1);s.useEffect(()=>{E.get("/templates?document_kind=resume").then(a=>h(a.templates??[])).catch(()=>{}).finally(()=>d(!1))},[]),s.useEffect(()=>{o(0)},[p]);const j=f.length,u=f[x],$=k||U,S=()=>o(a=>(a-1+j)%j),M=()=>o(a=>(a+1)%j);s.useEffect(()=>{if(b||j===0)return;const a=setTimeout(M,Ke);return()=>clearTimeout(a)},[x,b,j]),s.useEffect(()=>{const a=v.current,g=a==null?void 0:a.children[x];if(a&&g instanceof HTMLElement){const y=a.getBoundingClientRect().left,N=g.getBoundingClientRect().left,C=a.scrollLeft+N-y-a.clientWidth/2+g.offsetWidth/2;a.scrollTo({left:C,behavior:"smooth"})}},[x]);function R(a){D(a)?c("/pricing"):c(`/create?template=${a.id}`)}return e.jsxs("aside",{className:"flex w-full flex-col gap-4 roun
1ded-2xl border border-gray-200 bg-white p-4 lg:w-[480px] lg:shrink-0",onMouseEnter:()=>B(!0),onMouseLeave:()=>B(!1),children:[e.jsxs("div",{className:"flex items-center justify-between",children:[e.jsxs("div",{children:[e.jsx("h2",{className:"text-base font-semibold text-gray-900",children:"Browse templates"}),e.jsx("p",{className:"mt-0.5 text-xs text-gray-500",children:"Pick a starting point for your resume"})]}),n&&e.jsxs("button",{onClick:n,className:"flex items-center gap-1 text-xs font-medium text-blue-600 hover:underline",children:["View all ",e.jsx(W,{className:"h-3 w-3"})]})]}),$&&e.jsxs("div",{className:"animate-pulse space-y-3 px-1",children:[e.jsx("div",{className:"w-full aspect-[210/297] rounded-xl bg-gray-200"}),e.jsx("div",{className:"h-3.5 w-2/3 rounded bg-gray-200"}),e.jsx("div",{className:"h-3 w-1/3 rounded bg-gray-200"})]}),!$&&j===0&&e.jsxs("div",{className:"flex flex-col items-center justify-center py-8 text-center gap-2",children:[e.jsx(T,{className:"h-8 w-8 text-gray-300"}),e.jsx("p",{className:"text-sm text-gray-400",children:"No templates available yet"})]}),!$&&u&&e.jsxs(e.Fragment,{children:[e.jsxs("div",{className:"relative",children:[e.jsxs("button",{onClick:()=>R(u),className:"group relative block aspect-[210/297] w-full animate-in fade-in zoom-in-95 overflow-hidden rounded-xl border border-gray-200 bg-gray-50 p-5 shadow-sm transition-colors duration-500 hover:border-gray-400",children:[e.jsx("div",{className:"relative h-full w-full overflow-hidden rounded-lg bg-white shadow-sm",children:e.jsx(fe,{template:u,previewContent:l})}),D(u)?e.jsxs("div",{className:"absolute inset-0 flex flex-col items-center justify-center gap-2 bg-white/35",children:[e.jsx("div",{className:"flex h-10 w-10 items-center justify-center rounded-full bg-gray-900/10",children:e.jsx(_,{className:"h-5 w-5 text-gray-700"})}),e.jsx("span",{className:"rounded-full bg-gray-900 px-3 py-1 text-xs font-semibold text-white shadow",children:"Upgrade to unlock"})]}):e.jsx("div",{className:"absolute inset-0 flex items-center justify-center bg-gray-900/0 opacity-0 transition-all group-hover:bg-gray-900/30 group-hover:opacity-100",children:e.jsx("span",{className:"rounded-full bg-white px-3 py-1.5 text-xs font-semibold text-gray-900 shadow",children:"Use this template"})})]},u.id),j>1&&e.jsxs(e.Fragment,{children:[e.jsx("button",{onClick:S,"aria-label":"Previous template",className:"absolute left-1.5 top-1/2 -translate-y-1/2 rounded-full bg-white/90 p-1.5 text-gray-600 shadow ring-1 ring-gray-200 transition-colors hover:bg-white hover:text-gray-900",children:e.jsx(Pe,{className:"h-4 w-4"})}),e.jsx("button",{onClick:M,"aria-label":"Next template",className:"absolute right-1.5 top-1/2 -translate-y-1/2 rounded-full bg-white/90 p-1.5 text-gray-600 shadow ring-1 ring-gray-200 transition-colors hover:bg-white hover:text-gray-900",children:e.jsx(Ee,{className:"h-4 w-4"})})]})]}),e.jsxs("div",{className:"animate-in fade-in slide-in-from-bottom-1 duration-500",children:[e.jsxs("div",{className:"flex items-center gap-1.5",children:[e.jsx("p",{className:"text-sm font-semibold text-gray-900",children:u.name}),D(u)&&e.jsx(_,{className:"h-3 w-3 text-gray-400"})]}),u.description&&e.jsx("p",{className:"mt-0.5 text-xs leading-snug text-gray-400 line-clamp-2",children:u.description})]},`${u.id}-label`),e.jsx("div",{ref:v,className:"-mx-1 flex gap-2 overflow-x-auto px-1 pb-1 browse-template-strip",children:f.map((a,g)=>e.jsxs("button",{onClick:()=>o(g),title:a.name,className:`relative aspect-[210/297] w-12 shrink-0 overflow-hidden rounded-md border-2 transition-colors ${g===x?"border-gray-900":"border-gray-200 hover:border-gray-400"}`,children:[e.jsx(qe,{tpl:a,previewContent:l}),D(a)&&e.jsx("div",{className:"absolute inset-0 flex items-center justify-center bg-white/40",children:e.jsx(_,{className:"h-3 w-3 text-gray-600"})})]},a.id))})]})]})}function J(n){return new Date(n).toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric"})}function Q(n,c){var m,l;const i=n.content;return((l=(m=i==null?void 0:i.personalInfo)==null?void 0:m.fullName)==null?void 0:l.trim())||n.title||c}function Qe(){return e.jsxs("svg",{viewBox:"0 0 96 96",className:"h-full w-full","aria-hidden":!0,
1children:[e.jsx("circle",{cx:"48",cy:"48",r:"38",fill:"none",stroke:"#c4b5fd",strokeWidth:"1"}),e.jsx("circle",{cx:"48",cy:"48",r:"24",fill:"none",stroke:"#c4b5fd",strokeWidth:"1"}),e.jsx("circle",{cx:"48",cy:"48",r:"10",fill:"none",stroke:"#c4b5fd",strokeWidth:"1"}),e.jsx("line",{x1:"48",y1:"10",x2:"48",y2:"86",stroke:"#c4b5fd",strokeWidth:"0.75"}),e.jsx("line",{x1:"10",y1:"48",x2:"86",y2:"48",stroke:"#c4b5fd",strokeWidth:"0.75"}),e.jsx("line",{x1:"21",y1:"21",x2:"75",y2:"75",stroke:"#c4b5fd",strokeWidth:"0.75"}),e.jsx("line",{x1:"75",y1:"21",x2:"21",y2:"75",stroke:"#c4b5fd",strokeWidth:"0.75"}),e.jsx("polygon",{points:"48,18 70,62 26,62",fill:"#8b5cf6",fillOpacity:"0.25",stroke:"#8b5cf6",strokeWidth:"1.5"}),e.jsx("circle",{cx:"48",cy:"18",r:"3.5",fill:"#8b5cf6"}),e.jsx("circle",{cx:"70",cy:"62",r:"3.5",fill:"#8b5cf6"}),e.jsx("circle",{cx:"26",cy:"62",r:"3.5",fill:"#8b5cf6"}),e.jsx("circle",{cx:"48",cy:"48",r:"5",fill:"#8b5cf6"})]})}function Xe(){return e.jsxs("svg",{viewBox:"0 0 96 96",className:"h-full w-full","aria-hidden":!0,children:[e.jsx("rect",{x:"6",y:"8",width:"56",height:"72",rx:"6",fill:"white",stroke:"#e5e7eb",strokeWidth:"1.5"}),e.jsx("rect",{x:"12",y:"18",width:"32",height:"3",rx:"1.5",fill:"#e5e7eb"}),e.jsx("rect",{x:"12",y:"26",width:"44",height:"2",rx:"1",fill:"#f3f4f6"}),e.jsx("rect",{x:"12",y:"31",width:"38",height:"2",rx:"1",fill:"#f3f4f6"}),e.jsx("rect",{x:"12",y:"36",width:"42",height:"2",rx:"1",fill:"#f3f4f6"}),e.jsx("rect",{x:"12",y:"44",width:"28",height:"3",rx:"1.5",fill:"#e5e7eb"}),e.jsx("rect",{x:"12",y:"51",width:"44",height:"2",rx:"1",fill:"#f3f4f6"}),e.jsx("rect",{x:"12",y:"56",width:"36",height:"2",rx:"1",fill:"#f3f4f6"}),e.jsx("rect",{x:"12",y:"61",width:"40",height:"2",rx:"1",fill:"#f3f4f6"}),e.jsx("circle",{cx:"74",cy:"38",r:"16",fill:"#10b981"}),e.jsx("polyline",{points:"65,38 71,44 83,30",stroke:"white",strokeWidth:"3",fill:"none",strokeLinecap:"round",strokeLinejoin:"round"}),e.jsx("circle",{cx:"82",cy:"68",r:"10",fill:"#34d399",opacity:"0.6"}),e.jsx("polyline",{points:"77,68 80,71 87,63",stroke:"white",strokeWidth:"2.5",fill:"none",strokeLinecap:"round",strokeLinejoin:"round"})]})}function Ye(){return e.jsxs("svg",{viewBox:"0 0 96 96",className:"h-full w-full","aria-hidden":!0,children:[e.jsx("rect",{x:"4",y:"22",width:"42",height:"56",rx:"4",fill:"#fed7aa"}),e.jsx("rect",{x:"16",y:"14",width:"42",height:"56",rx:"4",fill:"#fdba74"}),e.jsx("rect",{x:"28",y:"8",width:"44",height:"58",rx:"5",fill:"white",stroke:"#fb923c",strokeWidth:"1.5"}),e.jsx("rect",{x:"35",y:"18",width:"28",height:"3",rx:"1.5",fill:"#fed7aa"}),e.jsx("rect",{x:"35",y:"26",width:"32",height:"2",rx:"1",fill:"#f3f4f6"}),e.jsx("rect",{x:"35",y:"31",width:"28",height:"2",rx:"1",fill:"#f3f4f6"}),e.jsx("rect",{x:"35",y:"36",width:"30",height:"2",rx:"1",fill:"#f3f4f6"}),e.jsx("rect",{x:"35",y:"44",width:"22",height:"3",rx:"1.5",fill:"#fed7aa"}),e.jsx("rect",{x:"35",y:"51",width:"32",height:"2",rx:"1",fill:"#f3f4f6"}),e.jsx("rect",{x:"35",y:"56",width:"26",height:"2",rx:"1",fill:"#f3f4f6"})]})}function Ze({open:n,label:c,onConfirm:i,onCancel:m}){return n?e.jsx("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-black/40 p-4",onClick:m,children:e.jsxs("div",{className:"w-full max-w-sm rounded-2xl bg-white p-6 shadow-xl",onClick:l=>l.stopPropagation(),children:[e.jsx("div",{className:"flex h-11 w-11 items-center justify-center rounded-full bg-red-50 mb-4",children:e.jsx(O,{className:"h-5 w-5 text-red-500"})}),e.jsxs("h2",{className:"text-base font-semibold text-gray-900",children:["Delete ",c,"?"]}),e.jsx("p",{className:"mt-1 text-sm text-gray-500",children:"This action cannot be undone."}),e.jsxs("div",{className:"mt-5 flex gap-3",children:[e.jsx("button",{onClick:m,className:"flex-1 rounded-xl border border-gray-200 px-4 py-2 text-sm font-medium text-gray-700 hover:bg-gray-50",children:"Cancel"}),e.jsx("button",{onClick:i,className:"flex-1 rounded-xl bg-red-600 px-4 py-2 text-sm font-medium text-white hover:bg-red-700",children:"Delete"})]})]})}):null}function ue({open:n,onClose:c,documents:i,heading:m,subheading:l,onOpen:f,onDelete:h,onDuplicate:k}){const[d,x]=s.useState(null);return s.useEffect(()=>{if(!d)return;const o=()=>x(null);return document.addEventListener("mousedown",o),()=>document.removeEventListener("mousedown",o)},[d]),n?e.jsx("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-black/40 p-4",onClick:c,children:e.jsxs("div",{className:"relative w-full max-w-2xl max-h-[80vh] overflow-y-auto rounded-2xl bg-white shadow-xl",onClick:o=>o.stopPropagation(),children:[e.jsxs("div",{className:"sticky top-0 z-10 flex items-center justify-between rounded-t-2xl bg-white p-5 border-b border-gray-100",children:[e.jsxs("div",{children:[e.jsx("h2",{className:"text-base font-semibold text-gray-900",children:m}),e.jsx("p",{className:"mt-0.5 text-xs text-gray-500",children:l})]}),e.jsx("button",{onClick:c,className:"rounded-lg p-1.5 text-gray-400 hover:bg-gray-100 hover:text-gray-600",children:e.jsx(Me,{className:"h-4 w-4"})})]}),e.jsxs("div",{className:"p-5",children:[i.length===0&&e.jsxs("div",{className:"flex flex-col items-center justify-center py-12 text-center gap-2",children:[e.jsx(T,{className:"h-8 w-8 text-gray-300"}),e.jsx("p",{className:"text-sm text-gray-400",children:"Nothing here yet"}),e.jsx("p",{className:"text-xs text-gray-400",children:"Create one to get started"})]}),i.length>0&&e.jsx("div",{className:"grid grid-cols-3 gap-4 sm:grid-cols-4",children:i.map(o=>e.jsxs("div",{className:"group flex flex-col gap-2",children:[e.jsxs("div",{onClick:()=>{f(o),c()},className:"relative aspect-[210/297] w-full cursor-pointer overflow-hidden rounded-xl border border-gray-200 bg-white transition hover:border-blue-300 hover:shadow-md",children:[e.jsx(q,{resume:o}),e.jsx("div",{className:"absolute inset-0 flex items-center justify-center bg-gray-900/0 opacity-0 transition-all hover:bg-gray-900/20 hover:opacity-100",children:e.jsx("span",{className:"rounded-full bg-white px-2 py-1 text-[11px] font-semibold text-gray-900 shadow",children:"Open"})})]}),e.jsxs("div",{className:"flex items-start justify-between gap-1",children:[e.jsxs("div",{className:"min-w-0",children:[e.jsx("p",{className:"truncate text-[11px] font-medium text-gray-700",children:Q(o,"Untitled")}),e.jsx("p",{className:"text-[10px] text-gray-400",children:J(o.updated_at)})]}),e.jsxs("div",{className:"relative shrink-0",children:[e.jsx("button",{onClick:b=>{b.stopPropagation(),x(d===o.id?null:o.id)},className:"rounded p-0.5 text-gray-400 hover:bg-gray-100 hover:text-gray-600",children:e.jsx(G,{className:"h-3.5 w-3.5"})}),d===o.id&&e.jsxs("div",{className:"absolute right-0 top-6 z-20 w-32 rounded-xl border border-gray-200 bg-white py-1 shadow-lg",onMouseDown:b=>b.stopPropagation(),children:[e.jsxs("button",{onClick:()=>{f(o),c()},className:"flex w-full items-center gap-2 px-3 py-1.5 text-xs text-gray-700 hover:bg-gray-50",children:[e.jsx(H,{className:"h-3 w-3"})," Edit"]}),e.jsxs("button",{onClick:()=>{k(o),x(null)},className:"flex w-full items-center gap-2 px-3 py-1.5 text-xs text-gray-700 hover:bg-gray-50",children:[e.jsx(K,{className:"h-3 w-3"})," Duplicate"]}),e.jsxs("button",{onClick:()=>{h(o),x(null),c()},className:"flex w-full items-center gap-2 px-3 py-1.5 text-xs text-red-600 hover:bg-red-50",children:[e.jsx(O,{className:"h-3 w-3"})," Delete"]})]})]})]})]},o.id))})]})]})}):null}function gt(){var ae,ie,ne,oe,ce,de,xe;const{user:n,profile:c}=pe(),i=ge(),m=Ie(),{status:l,loading:f}=be(),[h,k]=s.useState([]),[d,x]=s.useState([]),[o,b]=s.useState(!0),[B,v]=s.useState(""),w=(l==null?void 0:l.tier)==="free",[U,p]=s.useState(!1),[z,D]=s.useState(!1),[j,u]=s.useState(!1),[$,S]=s.useState(!1),[M,R]=s.useState(!1),[I,P]=s.useState(!1),a=s.useRef(!1),[g,y]=s.useState(null),[N,C]=s.useState(null),[je,X]=s.useState(!1),[ye,Y]=s.useState(!1),[Z,ee]=s.useState(null),A=f||l===null||((ae=l.features)==null?void 0:ae.has_cover_letters),ve=((ie=c==null?void 0:c.full_name)==null?void 0:ie.split(" ")[0])||((ne=n==null?void 0:n.email)==null?void 0:ne.split("@")[0])||"there",te=s.useCallback(async()=>
1{if(n){b(!0),v("");try{const[t,r]=await Promise.all([E.get("/resumes?document_type=resume&limit=50"),E.get("/resumes?document_type=cover-letter&limit=20")]);k(t.resumes||[]),x(r.resumes||[])}catch{v("Could not load your documents.")}finally{b(!1)}}},[n==null?void 0:n.id]);s.useEffect(()=>{te()},[te]),s.useEffect(()=>{if(!g)return;const t=()=>y(null);return document.addEventListener("mousedown",t),()=>document.removeEventListener("mousedown",t)},[g]),s.useEffect(()=>{var r;const t=(r=m.state)==null?void 0:r.paymentSuccess;t&&["starter","pro","premium","yearly"].includes(t)&&(ee(t),window.history.replaceState({},""))},[m.state]);const we=(l==null?void 0:l.tier)??"free",se=()=>{if(!l||!(n!=null&&n.id))return;const t=l.tier;if(t!=="free"&&t!=="starter")return;const r=`pricing-banner-dismissed-${n.id}`;sessionStorage.getItem(r)!=="1"&&Y(!0)};s.useEffect(()=>{var r;if(!c||f||!l)return;if(!!!((r=c.preferences)!=null&&r.onboarding_completed)){X(!0);return}se()},[c,f,l]);const Ne=()=>{X(!1),se()},Ce=()=>{Y(!1),sessionStorage.setItem(`pricing-banner-dismissed-${n==null?void 0:n.id}`,"1")},ke=async()=>{if(!N)return;const{id:t,type:r}=N;C(null);try{await E.delete(`/resumes/${t}`),r==="resume"?k(L=>L.filter(F=>F.id!==t)):x(L=>L.filter(F=>F.id!==t))}catch{v(r==="resume"?"Could not delete resume.":"Could not delete document.")}},re=async t=>{try{const r=await E.post(`/resumes/${t}/duplicate`);r.resume&&k(L=>[r.resume,...L])}catch{v("Could not duplicate resume.")}},le=async t=>{try{const r=await E.post(`/resumes/${t}/duplicate`);r.resume&&x(L=>[r.resume,...L])}catch{v("Could not duplicate document.")}},De=((ce=(oe=l==null?void 0:l.credits)==null?void 0:oe.resume_export)==null?void 0:ce.used)??0,Le=((xe=(de=l==null?void 0:l.credits)==null?void 0:de.cover_letter_export)==null?void 0:xe.used)??0,Se=[{icon:T,count:h.length,label:"Resumes",iconBg:"bg-blue-50",iconColor:"text-blue-600",badge:null},{icon:me,count:d.length,label:"Cover Letters",iconBg:"bg-violet-50",iconColor:"text-violet-600",badge:null},{icon:Be,count:De,label:"Resume Downloads",iconBg:"bg-emerald-50",iconColor:"text-emerald-600",badge:"Current Plan"},{icon:$e,count:Le,label:"Cover Letter Downloads",iconBg:"bg-amber-50",iconColor:"text-amber-600",badge:"Current Plan"}],Re=[{icon:Te,title:"Skill Gap Analysis",description:"Compare your resume against a job description and see exactly what to add",handleClick:()=>i("/tools/skill-gap"),iconBg:"bg-violet-50",iconColor:"text-violet-600",btnBg:"bg-violet-50",Illustration:Qe},{icon:_e,title:"Resume Enhancer",description:"AI rewrites your bullet points to be more impactful and ATS-friendly",handleClick:()=>{if(w)P(!0);else{const t=h[0];i(t?`/create/${t.id}`:"/create")}},iconBg:"bg-emerald-50",iconColor:"text-emerald-600",btnBg:"bg-emerald-50",Illustration:Xe},{icon:T,title:"Browse Templates",description:"Explore domain-specific templates tailored to your target role",handleClick:()=>i("/templates"),iconBg:"bg-orange-50",iconColor:"text-orange-500",btnBg:"bg-orange-50",Illustration:Ye}];return e.jsxs(We,{children:[e.jsxs("div",{className:"min-h-full bg-[#f9fafb] px-4 sm:px-6 py-6 space-y-4",children:[e.jsxs("div",{className:"flex flex-col gap-4 lg:flex-row lg:items-center",children:[e.jsxs("div",{className:"shrink-0 min-w-0",children:[e.jsxs("h1",{className:"flex flex-wrap items-center gap-1.5 text-2xl font-bold text-gray-900",children:["Welcome back, ",e.jsx("span",{className:"text-blue-600",children:ve}),e.jsx("span",{children:"👋"})]}),e.jsx("p",{className:"mt-1 text-sm text-gray-500",children:"Let's craft your next opportunity."})]}),e.jsx("div",{className:"flex min-w-0 flex-1 flex-wrap gap-3",children:Se.map(t=>e.jsxs("div",{className:"flex min-w-[9.5rem] flex-1 items-center gap-3 rounded-2xl border border-gray-200 bg-white px-4 py-3.5 sm:min-w-[11rem]",children:[e.jsx("div",{className:`flex h-11 w-11 shrink-0 items-center justify-center rounded-xl ${t.iconBg}`,children:e.jsx(t.icon,{className:`h-5 w-5 ${t.iconColor}`})}),e.jsxs("div",{className:"min-w-0 flex-1",children:[e.jsx("p",{className:"text-2xl font-bold leading-none text-gray-900",children:t.count}),e.jsx("p",{className:"mt-1 text-xs leading-tight text-gray-500",children:t.label}),t.badge&&e.jsx("p",{className:"mt-0.5 text-[10px] font-medium leading-none text-orange-500",children:t.badge})]})]},t.label))})]}),B&&e.jsxs("div",{className:"flex items-center gap-2 rounded-lg bg-red-50 px-4 py-3 text-sm text-red-700",children:[e.jsx(Ae,{className:"h-4 w-4 shrink-0"}),B]}),e.jsx(He,{variant:"compact"}),e.jsxs("div",{className:"flex flex-col gap-6 lg:flex-row lg:items-start",children:[e.jsxs("div",{className:"flex-1 min-w-0 space-y-6",children:[e.jsxs("section",{className:"rounded-2xl border border-gray-200 bg-white p-5",children:[e.jsxs("div",{className:"mb-5 flex items-center justify-between",children:[e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx("span",{className:"flex h-7 w-7 items-center justify-center rounded-lg bg-blue-50",children:e.jsx(T,{className:"h-4 w-4 text-blue-600"})}),e.jsx("h2",{className:"text-sm font-semibold text-gray-900",children:"My Resumes"})]}),e.jsxs("button",{onClick:()=>S(!0),className:"flex items-center gap-1 text-xs font-medium text-blue-600 hover:underline",children:["View all ",e.jsx(W,{className:"h-3 w-3"})]})]}),e.jsxs("div",{className:"grid grid-cols-3 gap-4 sm:grid-cols-4",children:[e.jsxs("button",{onClick:()=>p(!0),className:"group flex flex-col items-center gap-2 text-center",children:[e.jsx("div",{className:"flex aspect-[210/297] w-full items-center justify-center rounded-xl border-2 border-dashed border-gray-200 bg-gray-50 transition group-hover:border-blue-400 group-hover:bg-blue-50",children:e.jsx("div",{className:"flex h-10 w-10 items-center justify-center rounded-full bg-blue-600 shadow-sm",children:e.jsx(he,{className:"h-5 w-5 text-white"})})}),e.jsxs("div",{children:[e.jsx("p",{className:"text-xs font-medium text-gray-700",children:"Create New"}),e.jsx("p",{className:"text-[11px] text-gray-400",children:"Resume"})]})]}),o?Array.from({length:2}).map((t,r)=>e.jsxs("div",{className:"flex flex-col gap-2",children:[e.jsx("div",{className:"aspect-[210/297] animate-pulse rounded-xl bg-gray-100"}),e.jsx("div",{className:"h-3 w-2/3 animate-pulse rounded bg-gray-100"})]},r)):e.jsxs(e.Fragment,{children:[h.slice(0,2).map(t=>e.jsxs("div",{className:"group flex flex-col gap-2",children:[e.jsxs("div",{onClick:()=>i(`/create/${t.id}`),className:"relative aspect-[210/297] cursor-pointer overflow-hidden rounded-xl border border-gray-200 bg-white transition hover:border-blue-300 hover:shadow-md",children:[e.jsx(q,{resume:t}),e.jsx("div",{className:"absolute inset-0 bg-gray-900/0 transition group-hover:bg-gray-900/5"})]}),e.jsxs("div",{className:"flex items-start justify-between gap-1",children:[e.jsxs("div",{className:"min-w-0",children:[e.jsx("p",{className:"truncate text-xs font-medium text-gray-900",children:Q(t,"Untitled Resume")}),e.jsx("p",{className:"mt-0.5 text-[11px] text-gray-400",children:J(t.updated_at)})]}),e.jsxs("div",{className:"relative shrink-0",children:[e.jsx("button",{onClick:r=>{r.stopPropagation(),y(g===t.id?null:t.id)},className:"rounded p-0.5 text-gray-400 hover:bg-gray-100 hover:text-gray-600",children:e.jsx(G,{className:"h-3.5 w-3.5"})}),g===t.id&&e.jsxs("div",{className:"absolute right-0 top-6 z-20 w-32 rounded-xl border border-gray-200 bg-white py-1 shadow-lg",onMouseDown:r=>r.stopPropagation(),children:[e.jsxs("button",{onClick:()=>i(`/create/${t.id}`),className:"flex w-full items-center gap-2 px-3 py-1.5 text-xs text-gray-700 hover:bg-gray-50",children:[e.jsx(H,{className:"h-3 w-3"})," Edit"]}),e.jsxs("button",{onClick:()=>{re(t.id),y(null)},className:"flex w-full items-center gap-2 px-3 py-1.5 text-xs text-gray-700 hover:bg-gray-50",children:[e.jsx(K,{className:"h-3 w-3"})," Duplicate"]}),e.jsxs("button",{onClick:()=>{C({id:t.id,type:"resume"}),y(null)},className:"flex w-full items-center gap-2 px-3 py-1.5 text-xs text-red-600 hover:bg-red-50",children:[e.jsx(O,{className:"h-3 w-3"})," Delete"]})]})]})]})]},t.id)),h.length>2&&e.jsxs("button",{onClick:()=>S(!0),className:"group flex flex-col items-center gap-2 text-center",children:[e.jsxs("div",{className:"flex aspect-[210/297] w-full flex-col items-center justify-center gap-2 rounded-xl border-2 border-dashed border-gray-200 bg-gray-50 transition group-hover:border-blue-400 group-hover:bg-blue-50",children:[e.jsxs("span",{className:"text-2xl font-bold text-gray-400 group-hover:text-blue-500",children:["+",h.length-2]}),e.jsx("span",{className:"text-[11px] font-medium text-gray-400 group-hover:text-blue-500",children:"more"})]}),e.jsxs("div",{children:[e.jsx("p",{className:"text-xs font-medium text-gray-700",children:"View All"}),e.jsxs("p",{className:"text-[11px] text-gray-400",children:[h.length," resumes"]})]})]})]})]})]}),e.jsxs("section",{className:"rounded-2xl border border-gray-200 bg-white p-5",children:[e.jsxs("div",{className:"mb-5 flex items-center justify-between",children:[e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx("span",{className:"flex h-7 w-7 items-center justify-center rounded-lg bg-violet-50",children:e.jsx(me,{className:"h-4 w-4 text-violet-600"})}),e.jsx("h2",{className:"text-sm font-semibold text-gray-900",children:"My Cover Letters"}),!A&&e.jsxs("span",{className:"flex items-center gap-1 rounded-full bg-amber-50 px-2 py-0.5 text-[10px] font-medium text-amber-600",children:[e.jsx(_,{className:"h-2.5 w-2.5"})," Upgrade"]})]}),e.jsxs("button",{onClick:()=>R(!0),className:"flex items-center gap-1 text-xs font-medium text-blue-600 hover:underline",children:["View all ",e.jsx(W,{className:"h-3 w-3"})]})]}),e.jsxs("div",{className:"grid grid-cols-3 gap-4 sm:grid-cols-4",children:[e.jsxs("button",{onClick:()=>A?D(!0):i("/pricing"),className:"group flex flex-col items-center gap-2 text-center",children:[e.jsx("div",{className:`flex aspect-[210/297] w-full items-center justify-center rounded-xl border-2 border-dashed transition ${A?"border-gray-200 bg-gray-50 group-hover:border-violet-400 group-hover:bg-violet-50":"border-gray-200 bg-gray-50 group-hover:border-amber-300 group-hover:bg-amber-50"}`,children:A?e.jsx("div",{className:"flex h-10 w-10 items-center justify-center rounded-full bg-blue-600 shadow-sm",children:e.jsx(he,{className:"h-5 w-5 text-white"})}):e.jsxs("div",{className:"flex flex-col items-center gap-1.5",children:[e.jsx("div",{className:"flex h-10 w-10 items-center justify-center rounded-full bg-gray-200",children:e.jsx(_,{className:"h-4 w-4 text-gray-500"})}),e.jsx("span",{className:"text-[10px] font-medium text-amber-600",children:"Upgrade"})]})}),e.jsxs("div",{children:[e.jsx("p",{className:"text-xs font-medium text-gray-700",children:A?"Create New":"Locked"}),e.jsx("p",{className:"text-[11px] text-gray-400",children:"Cover Letter / SOP"})]})]}),o?Array.from({length:2}).map((t,r)=>e.jsxs("div",{className:"flex flex-col gap-2",children:[e.jsx("div",{className:"aspect-[210/297] animate-pulse rounded-xl bg-gray-100"}),e.jsx("div",{className:"h-3 w-2/3 animate-pulse rounded bg-gray-100"})]},r)):e.jsxs(e.Fragment,{children:[d.slice(0,2).map(t=>e.jsxs("div",{className:"group flex flex-col gap-2",children:[e.jsxs("div",{onClick:()=>i(`/create-cover-letter/${t.id}`),className:"relative aspect-[210/297] cursor-pointer overflow-hidden rounded-xl border border-gray-200 bg-white transition hover:border-violet-300 hover:shadow-md",children:[e.jsx(q,{resume:t}),e.jsx("div",{className:"absolute inset-0 bg-gray-900/0 transition group-hover:bg-gray-900/5"})]}),e.jsxs("div",{className:"flex items-start justify-between gap-1",children:[e.jsxs("div",{className:"min-w-0",children:[e.jsx("p",{className:"truncate text-xs font-medium text-gray-900",children:Q(t,"Untitled Cover Letter")}),e.jsx("p",{className:"mt-0.5 text-[11px] text-gray-400",children:J(t.updated_at)})]}),e.jsxs("div",{className:"relative shrink-0",children:[e.jsx("button",{onMouseDown:r=>r.stopPropagation(),onClick:r=>{r.stopPropagation(),y(g===t.id?null:t.id)},className:"rounded p-0.5 text-gray-400 hover:bg-gray-100 hover:text-gray-600",children:e.jsx(G,{className:"h-3.5 w-3.5"})}),g===t.id&&e.jsxs("div",{className:"absolute right-0 top-6 z-[200] w-32 rounded-xl border border-gray-200 bg-white py-1 shadow-lg",onMouseDown:r=>r.stopPropagation(),children:[e.jsxs("button",{onClick:()=>i(`/create-cover-letter/${t.id}`),className:"flex w-full items-center gap-2 px-3 py-1.5 text-xs text-gray-700 hover:bg-gray-50",children:[e.jsx(H,{className:"h-3 w-3"})," Edit"]}),e.jsxs("button",{onClick:()=>{le(t.id),y(null)},className:"flex w-full items-center gap-2 px-3 py-1.5 text-xs text-gray-700 hover:bg-gray-50",children:[e.jsx(K,{className:"h-3 w-3"})," Duplicate"]}),e.jsxs("button",{onClick:()=>{C({id:t.id,type:"cover-letter"}),y(null)},className:"flex w-full items-center gap-2 px-3 py-1.5 text-xs text-red-600 hover:bg-red-50",children:[e.jsx(O,{className:"h-3 w-3"})," Delete"]})]})]})]})]},t.id)),d.length>2&&e.jsxs("button",{onClick:()=>R(!0),className:"group flex flex-col items-center gap-2 text-center",children:[e.jsxs("div",{className:"flex aspect-[210/297] w-full flex-col items-center justify-center gap-2 rounded-xl border-2 border-dashed border-gray-200 bg-gray-50 transition group-hover:border-violet-400 group-hover:bg-violet-50",children:[e.jsxs("span",{className:"text-2xl font-bold text-gray-400 group-hover:text-violet-500",children:["+",d.length-2]}),e.jsx("span",{className:"text-[11px] font-medium text-gray-400 group-hover:text-violet-500",children:"more"})]}),e.jsxs("div",{children:[e.jsx("p",{className:"text-xs font-medium text-gray-700",children:"View All"}),e.jsxs("p",{className:"text-[11px] text-gray-400",children:[d.length," cover letters"]})]})]})]})]})]})]}),e.jsx("div",{className:"lg:sticky lg:top-6 lg:self-start",children:e.jsx(Je,{onViewAll:()=>u(!0)})})]}),e.jsxs("section",{children:[e.jsx("h2",{className:"mb-4 text-sm font-semibold text-gray-900",children:"Tools"}),e.jsx("div",{className:"grid gap-4 sm:grid-cols-3",children:Re.map(t=>e.jsxs("button",{onClick:t.handleClick,className:"group relative flex items-center justify-between overflow-hidden rounded-2xl border border-gray-200 bg-white p-5 transition-[border-color,box-shadow] hover:border-gray-300 hover:shadow-md w-full text-left",children:[e.jsxs("div",{className:"flex flex-col gap-3 pr-4",children:[e.jsx("div",{className:`flex h-10 w-10 shrink-0 items-center justify-center rounded-xl ${t.iconBg}`,children:e.jsx(t.icon,{className:`h-5 w-5 ${t.iconColor}`})}),e.jsxs("div",{children:[e.jsx("p",{className:"text-sm font-semibold text-gray-900",children:t.title}),e.jsx("p",{className:"mt-1 text-xs leading-relaxed text-gray-500 line-clamp-2",children:t.description})]}),e.jsxs("div",{className:`inline-flex w-fit items-center gap-1.5 rounded-full px-3 py-1.5 text-xs font-medium ${t.btnBg} ${t.iconColor}`,children:["Open",e.jsx(W,{className:"h-3 w-3 transition-transform group-hover:translate-x-0.5"})]})]}),e.jsx("div",{className:"h-24 w-24 shrink-0 opacity-90",children:e.jsx(t.Illustration,{})})]},t.title))})]})]}),e.jsx(Ze,{open:N!==null,label:(N==null?void 0:N.type)==="cover-letter"?"Cover Letter":"Resume",onConfirm:()=>{ke()},onCancel:()=>C(null)}),je&&e.jsx(Oe,{onDone:Ne}),ye&&e.jsx(Ve,{currentTier:we,onDismiss:Ce}),Z&&e.jsx(Ge,{planName:Z,creditsStatus:l,onClose:()=>ee(null)}),e.jsx(V,{open:U,onClose:()=>p(!1)}),e.jsx(Fe,{open:z,onClose:()=>D(!1)}),e.jsx(V,{open:I,creditsStatus:l,creditsLoading:f,onSelect:t=>{a.current=!0,P(!1),i(`/create?template=${t}`)},onClose:()=>{const t=a.current;a.current=!1,P(!1),t||i("/create?browse=1")}}),e.jsx(V,{open:j,onClose:()=>u(!1),creditsStatus:l,creditsLoading:f}),e.jsx(ue,{open:$,onClose:()=>S(!1),documents:h,heading:"All Resumes",subheading:`${h.length} resume${h.length!==1?"s":""}`,onOpen:t=>i(`/create/${t.id}`),onDelete:t=>{C({id:t.id,type:"resume"}),S(!1)},onDuplicate:t=>{re(t.id)}}),e.jsx(ue,{open:M,onClose:()=>R(!1),documents:d,heading:"All Cover Letters",subheading:`${d.length} cover letter${d.length!==1?"s":""}`,onOpen:t=>i(`/create-cover-letter/${t.id}`),onDelete:t=>{C({id:t.id,type:"cover-letter"}),R(!1)},onDuplicate:t=>{le(t.id)}})]})}export{gt 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.