PageSourceSearch

https://cveloapp.com/assets/Dashboard-B3U55g9I.js

js cveloapp.com collected 2026-10-02 01:26:46 UTC 27,700 bytes, 1 lines download raw bytes

1import{g as De,u as ve,t as T,c as $e,d as Be,e as We,a as Fe,j as e,r as Je,f as G,h as Ue,C as Ke}from"./index-DtE9yg8W.js";import{r as l,L as p}from"./react-vendor-B01fvZtu.js";import{A as He}from"./AddApplicationModal-DZSQZyjW.js";import{l as Ye}from"./profilePrefs-CNyZZm8_.js";import{g as Ge}from"./atsScore-ByBMzDzW.js";const Ve=(...s)=>{};function ge(){const s=De();return s?{Authorization:`Bearer ${s}`}:{}}function W(){return"serviceWorker"in navigator&&"PushManager"in window&&"Notification"in window}function ze(){return window.matchMedia("(display-mode: standalone)").matches||"standalone"in window.navigator&&window.navigator.standalone===!0}function qe(s){const t="=".repeat((4-s.length%4)%4),n=(s+t).replace(/-/g,"+").replace(/_/g,"/"),i=atob(n);return Uint8Array.from([...i].map(r=>r.charCodeAt(0)))}async function Qe(){const s=await fetch("/api/push/vapid-public-key");if(!s.ok){const n=await s.text().catch(()=>"");throw Ve("[push] Failed to fetch VAPID key",{status:s.status,detail:n}),new Error("Failed to fetch VAPID key")}return(await s.json()).public_key}async function se(s){const t=s.toJSON(),n=await fetch("/api/push/subscribe",{method:"POST",headers:{"Content-Type":"application/json",...ge()},body:JSON.stringify(t)});return await n.text().catch(()=>""),n.status,n.ok}async function Xe(){const s=W();if(ze(),!s||await Notification.requestPermission()!=="granted")return!1;try{const n=await navigator.serviceWorker.ready;n.scope,n.active,n.waiting,n.installing;const i=await n.pushManager.getSubscription();if(i)return i.toJSON(),se(i);const r=await Qe(),c=await n.pushManager.subscribe({userVisibleOnly:!0,applicationServerKey:qe(r).buffer});return c.toJSON(),se(c)}catch{return!1}}async function Ze(){if(!W())return!1;const t=await(await navigator.serviceWorker.ready).pushManager.getSubscription();return t?se(t):!1}async function es(){if(!W())return;const t=await(await navigator.serviceWorker.ready).pushManager.getSubscription();if(!t)return;const n=await fetch("/api/push/unsubscribe",{method:"POST",headers:{"Content-Type":"application/json",...ge()},body:JSON.stringify({endpoint:t.endpoint})});await n.text().catch(()=>""),n.status,await t.unsubscribe()}function xe(){return"Notification"in window?Notification.permission:"denied"}async function ss(){if(!W())return null;const t=await(await navigator.serviceWorker.ready).pushManager.getSubscription();return t&&t.toJSON(),t}function ts(){const s=ve(),[t,n]=l.useState("default"),[i,r]=l.useState(!1),[c,d]=l.useState(!1),u=W();l.useEffect(()=>{u&&(n(xe()),ss().then(async w=>{if(!w){r(!1);return}if(!s.isLoading&&s.isAuthenticated){const A=await Ze();r(A);return}r(!0)}))},[u,s.isLoading,s.isAuthenticated]);const o=l.useCallback(async()=>{if(!(!u||c)){d(!0);try{await Xe()?(r(!0),n("granted")):n(xe())}finally{d(!1)}}},[u,c]),m=l.useCallback(async()=>{if(!(!u||c)){d(!0);try{await es(),r(!1)}finally{d(!1)}}},[u,c]);return{supported:u,permission:t,subscribed:i,loading:c,subscribe:o,unsubscribe:m}}const V="cvelo-pwa-install-dismissed",P="cvelo-pwa-installed",ns="/manifest.webmanifest",as=4e3;function Z(){var s;return typeof window>"u"?!1:((s=window.matchMedia)==null?void 0:s.call(window,"(display-mode: standalone)").matches)||window.navigator.standalone===!0}function z(){if(typeof navigator>"u")return!1;const s=navigator.userAgent,t=/iPad|iPhone|iPod/.test(s),n=/Safari/.test(s)&&!/CriOS|FxiOS|EdgiOS/.test(s);return t&&n}function q(){if(typeof navigator>"u")return!1;const s=navigator.userAgent;return/Android/i.test(s)&&/Chrome/i.test(s)&&!/EdgA|OPR|SamsungBrowser/i.test(s)}function ee(s){if(typeof window>"u")return!1;try{return localStorage.getItem(s)==="1"}catch{return!1}}function S(s,t){if(!(typeof window>"u"))try{localStorage.setItem(s,t?"1":"0")}catch{}}function _(s,t){if(t){console.info(`[PWA] ${s}`,t);return}console.info(`[PWA] ${s}`)}function is(){const s=l.useRef(null),[t,n]=l.useState("idle"),[i,r]=l.useState(()=>ee(P)),[c,d]=l.useState(!1),[u,o]=l.useState(!1),[m,w]=l.useState(()=>ee(V)),A=i,N=typeof window<"u"?q():!1,E=typeof window<"u"?z():!1;l.useEffect(()=>{var y;if(typeof window>"u")return;const b=Z(),x=b||ee(P);if(_("display-mode standalone",{standalone:b,iosStandalone:window.navigator.standalone===!0}
1),_("serviceWorker.controller",{available:"serviceWorker"in navigator,controlling:!!((y=navigator.serviceWorker)!=null&&y.controller)}),x){r(!0),d(!1),n("installed"),S(P,!0);return}const k=new URL(ns,window.location.origin).toString();fetch(k,{method:"GET"}).then(h=>{_("manifest fetch status",{ok:h.ok,status:h.status,url:k})}).catch(h=>{_("manifest fetch status",{ok:!1,url:k,error:h instanceof Error?h.message:"unknown"})});const H=h=>{h.preventDefault(),s.current=h,d(!0),o(!1),n("ready"),_("beforeinstallprompt fired and stored")},O=()=>{s.current=null,d(!1),o(!1),w(!1),r(!0),n("installed"),S(P,!0),S(V,!1),T("pwa_install_accepted",{platform:"mobile",source_surface:"pwa_install_hook"}),_("appinstalled fired")};window.addEventListener("beforeinstallprompt",H),window.addEventListener("appinstalled",O);const M=window.setTimeout(()=>{if(s.current||Z())return;const h=q()||z()?"manual":"unsupported";n(v=>v==="idle"?h:v),_("beforeinstallprompt did not fire; using fallback",{nextStatus:h,isAndroidChrome:q(),isIosSafari:z()})},as);return()=>{window.removeEventListener("beforeinstallprompt",H),window.removeEventListener("appinstalled",O),window.clearTimeout(M)}},[]);const R=l.useMemo(()=>N?"Open the Chrome menu, then tap Install app or Add to Home screen to install Cvelo.":E?"Tap Share, then choose Add to Home Screen to install Cvelo on your iPhone.":"Use your browser menu to add Cvelo to your home screen.",[N,E]),F=l.useCallback(()=>{w(!0),o(!1),S(V,!0)},[]),C=l.useCallback(async()=>{const b=s.current;if(Z())return r(!0),o(!1),n("installed"),S(P,!0),{outcome:"installed"};if(!b){const x=q()||z()?"manual":"unsupported";return o(!0),n(x==="manual"?"manual":"unsupported"),{outcome:x}}try{n("prompting"),T("pwa_install_prompt_open",{platform:"mobile",source_surface:"pwa_install_hook"}),await b.prompt();const x=await b.userChoice;return s.current=null,d(!1),x.outcome==="accepted"?(r(!0),n("accepted"),o(!1),S(P,!0),S(V,!1),T("pwa_install_accepted",{platform:"mobile",source_surface:"pwa_install_hook",platform_name:x.platform}),{outcome:"accepted"}):(n("dismissed"),o(!1),T("pwa_install_dismissed",{platform:"mobile",source_surface:"pwa_install_hook",platform_name:x.platform}),{outcome:"dismissed"})}catch(x){return console.error("[PWA] install prompt failed",x),s.current=null,d(!1),o(!0),n("manual"),{outcome:"manual"}}},[]),L=!i&&!m,I=c,J=!i&&(t==="manual"||E),U=t==="unsupported",K=l.useCallback(async()=>(await C()).outcome,[C]);return l.useMemo(()=>({status:t,canPrompt:c,isInstalled:i,isStandalone:A,isAndroidChrome:N,canInstall:L,canPromptInstall:I,requiresManualInstall:J,isUnsupported:U,showManualInstructions:u,isDismissed:m,manualInstallMessage:R,install:C,promptInstall:K,dismissInstall:F}),[t,c,i,A,N,L,I,J,U,u,m,R,C,K,F])}function os(){const s=new Date().getHours();return s<12?"Good morning":s<17?"Good afternoon":"Good evening"}function we(s){const t=Date.now()-new Date(s).getTime(),n=Math.floor(t/6e4);if(n<1)return"just now";if(n<60)return`${n}m ago`;const i=Math.floor(n/60);return i<24?`${i}h ago`:`${Math.floor(i/24)}d ago`}function rs(s){if(!s)return"";const t=Date.now()-new Date(s).getTime(),n=Math.floor(t/36e5);if(n<1)return"just now";if(n<24)return`${n}h ago`;const i=Math.floor(n/24);return i<7?`${i}d ago`:`${Math.floor(i/7)}w ago`}function te(s){return Math.max(0,Math.min(100,Math.round(s)))}function je(s,t,n=`${t}s`){return`${s} ${s===1?t:n}`}const Ne={saved:"Saved",ready_to_apply:"Ready to apply",applied:"Applied",applied_external:"Applied externally",screen:"Phone screen",interview:"Interview",offer:"Offer",accepted:"Accepted",rejected:"Rejected"},ls=[{kind:"link",title:"New Resume",description:"Create or upload a resume.",to:"/resumes",cta:"Open resumes"},{kind:"link",title:"Tailor Resume",description:"Match a resume to a job description.",to:"/jobs/apply",cta:"Tailor now"},{kind:"action",title:"Log Application",description:"Add a role to your pipeline.",action:"log-application",cta:"Log application"},{kind:"link",title:"Find Jobs",description:"Discover roles based on your profile.",to:"/job-discovery",cta:"Browse jobs"}],ke="cvelo:checklist";function cs(){try{const s=localStorage.getItem(ke);if(s)return JSON.parse(s)}catch{}return{dismissed:!1,manualDone:[]}}function ye(s){try{localStorage.setItem(ke,JSON.stringify(s))}catch{}}const ds=[{id:"resume",title:"Upload your first resume",desc:"PDF or DOCX — we parse it instantly.",to:"/resumes",cta:"Go to Resumes"},{id:"tailor",title:"Tailor a resume for a job",desc:"AI rewrites your bullets to match keywords.",to:"/apply",cta:"Start Apply Flow"},{id:"cover",title:"Generate a cover letter",desc:"Personalized to the role in seconds.",to:"/cover-letters",cta:"Cover Letters"},{id:"pipeline",title:"Track your first application",desc:"Log where you applied and follow up.",to:"/pipeline",cta:"Open Pipeline"},{id:"jobs",title:"Save a job from discovery",desc:"Find AI-matched roles and save them.",to:"/job-discovery",cta:"Browse Jobs"},{id:"profile",title:"Complete your profile",desc:"Better data improves recommendations.",to:"/profile",cta:"Edit Profile"}];function j({children:s}){return e.jsx("div",{className:"db-section-label",children:s})}function g({label:s,value:t,tone:n="default"}){return e.jsxs("div",{className:"db-status-item",children:[e.jsx("span",{children:s}),e.jsx("strong",{className:`db-status-tone-${n}`,children:t})]})}function Q({label:s,value:t,note:n}){return e.jsxs("div",{className:"db-progress-line",children:[e.jsxs("div",{className:"db-progress-line-top",children:[e.jsx("span",{children:s}),e.jsxs("strong",{children:[te(t),"%"]})]}),e.jsx("div",{className:"db-progress-line-track","aria-hidden":"true",children:e.jsx("div",{className:"db-progress-line-fill",style:{width:`${te(t)}%`}})}),e.jsx("p",{children:n})]})}function us({match:s}){const t=s.job_listing,n=Math.round(s.composite_score*100);return e.jsxs("article",{className:"db-job-list-row",children:[e.jsxs("div",{className:"db-row-main",children:[e.jsx("div",{className:"db-row-title",children:t.title}),e.jsx("div",{className:"db-row-sub",children:[t.company,t.location].filter(
1Boolean).join(" · ")})]}),e.jsxs("div",{className:"db-job-list-fit",children:[e.jsxs("strong",{children:[n,"%"]}),e.jsx("span",{children:"Match"})]}),e.jsxs("div",{className:"db-row-actions",children:[e.jsx(p,{to:`/jobs/${s.id}/apply`,className:"db-text-link",children:"Apply"}),e.jsx("a",{href:t.url,target:"_blank",rel:"noopener noreferrer",className:"db-text-link",children:"View"})]})]})}function ps({item:s}){return e.jsxs("div",{className:"db-activity-row",children:[e.jsx("div",{className:"db-activity-dot","aria-hidden":"true"}),e.jsxs("div",{className:"db-row-main",children:[e.jsx("div",{className:"db-row-title",children:Ne[s.status]??s.status}),e.jsxs("div",{className:"db-row-sub",children:[s.company," · ",s.role]})]}),e.jsx("div",{className:"db-row-meta",children:we(s.updated_at)})]})}function hs({score:s,resume:t,profileCompletion:n}){const i=s>0&&t,r=i?Ge(s):null,c=(r==null?void 0:r.label)??"Not scored yet";return e.jsxs("section",{className:"db-panel db-panel-readiness",children:[e.jsx("div",{className:"db-panel-head",children:e.jsxs("div",{children:[e.jsx(j,{children:"Resume Readiness"}),e.jsx("h2",{children:"Know what your strongest resume is ready for."})]})}),i?e.jsxs(e.Fragment,{children:[e.jsxs("div",{className:"db-readiness-header",children:[e.jsxs("div",{children:[e.jsx("div",{className:"db-readiness-score",children:s}),e.jsx("div",{className:"db-readiness-title",children:"ATS score"}),e.jsx("div",{className:"db-readiness-badge",children:c})]}),e.jsxs("div",{className:"db-readiness-summary",children:[e.jsxs("div",{children:[e.jsx("span",{children:"Best resume"}),e.jsx("strong",{children:t.title})]}),e.jsxs("div",{children:[e.jsx("span",{children:"Last scored"}),e.jsx("strong",{children:rs(t.ats_scored_at)})]}),e.jsxs("div",{children:[e.jsx("span",{children:"Profile readiness"}),e.jsxs("strong",{children:[n,"% complete"]})]})]})]}),e.jsxs("div",{className:"db-progress-stack",children:[e.jsx(Q,{label:"ATS readiness",value:s,note:"Based on your strongest scored resume."}),e.jsx(Q,{label:"Keyword coverage",value:Math.max(s-2,0),note:"Estimated from your strongest current score."}),e.jsx(Q,{label:"Formatting",value:Math.min(s+7,100),note:"Resume structure and clarity for screening systems."}),e.jsx(Q,{label:"Profile alignment",value:n,note:n>=70?"Your profile gives matching better context.":"Complete your profile to strengthen recommendations."})]}),e.jsxs("div",{className:"db-inline-actions",children:[e.jsx(p,{to:`/resumes/${t.id}`,className:"db-btn-primary",children:"Improve"}),e.jsx(p,{to:`/resumes/${t.id}`,className:"db-btn-secondary",children:"Recalculate"})]})]}):e.jsxs("div",{className:"db-empty-compact",children:[e.jsxs("div",{children:[e.jsx("h3",{children:"Resume not scored yet."}),e.jsx("p",{children:"Upload or tailor a resume to generate your first ATS readiness score."})]}),e.jsx(p,{to:"/resumes",className:"db-btn-primary",children:"Upload resume"})]})]})}function ms({variant:s,installButtonText:t,installHelpText:n,installBusy:i,installFeedback:r,manualInstallMessage:c,onInstall:d,showManualInstructions:u,isPWAInstalled:o}){return s==="desktop_extension_ready"?e.jsxs("section",{className:"db-panel db-utility-panel",children:[e.jsx("div",{className:"db-panel-head",children:e.jsxs("div",{children:[e.jsx(j,{children:"Extension / Autofill"}),e.jsx("h2",{children:"Review autofill activity."})]})}),e.jsx("p",{className:"db-panel-copy",children:"Track what Cvelo helped prepare, autofill, and organize."}),e.jsx(p,{to:"/autofill-sessions",className:"db-btn-secondary",children:"Open Activity"})]}):s==="desktop_install_extension"?e.jsxs("section",{className:"db-panel db-utility-panel",children:[e.jsx("div",{className:"db-panel-head",children:e.jsxs("div",{children:[e.jsx(j,{children:"Extension / Autofill"}),e.jsx("h2",{children:"Install Chrome extension."})]})}),e.jsx("p",{className:"db-panel-copy",children:"Add Cvelo Autofill to speed up applications and keep browser activity connected to your workspace."}),e.jsx("a",{href:Ke,target:"_blank",rel:"noopener noreferrer",className:"db-btn-secondary",children:"Add to Chrome"})]}
1):e.jsxs("section",{className:"db-panel db-utility-panel",children:[e.jsx("div",{className:"db-panel-head",children:e.jsxs("div",{children:[e.jsx(j,{children:"Extension / Autofill"}),e.jsx("h2",{children:o?"Cvelo is installed on this device.":"Install Cvelo on mobile."})]})}),e.jsx("p",{className:"db-panel-copy",children:o?"Open Cvelo from your home screen for faster access.":n}),e.jsx("p",{className:"db-panel-note",children:"Desktop Chrome still powers autofill and one-click application features."}),(u||r)&&e.jsx("div",{className:"db-inline-note",children:c}),r&&r!==c&&e.jsx("div",{className:"db-inline-note db-inline-note-strong",children:r}),!o&&e.jsx("button",{type:"button",className:"db-btn-secondary",onClick:d,disabled:i,children:i?"Opening install…":t})]})}function fs({resumeCount:s,applicationCount:t,hasProfile:n}){const[i,r]=l.useState(cs);function c(o){return i.manualDone.includes(o)?!0:o==="resume"?s>0:o==="pipeline"?t>0:o==="profile"?n:!1}function d(){const o={...i,dismissed:!0};r(o),ye(o)}function u(o){if(c(o))return;const m={...i,manualDone:[...i.manualDone,o]};r(m),ye(m)}return i.dismissed?null:e.jsxs("section",{className:"db-panel db-setup-panel",children:[e.jsxs("div",{className:"db-panel-head",children:[e.jsxs("div",{children:[e.jsx(j,{children:"Setup Progress"}),e.jsx("h2",{children:"Keep setup moving."})]}),e.jsx("button",{type:"button",className:"db-text-link",onClick:d,children:"Dismiss"})]}),e.jsx("div",{className:"db-setup-list",children:ds.map(o=>{const m=c(o.id);return e.jsxs("div",{className:`db-setup-item${m?" is-done":""}`,children:[e.jsx("button",{type:"button",className:"db-setup-check",onClick:()=>u(o.id),"aria-label":m?"Completed":"Mark complete",children:m?"✓":""}),e.jsxs("div",{className:"db-setup-copy",children:[e.jsx("strong",{children:o.title}),e.jsx("span",{children:o.desc})]}),!m&&e.jsx(p,{to:o.to,className:"db-text-link",children:o.cta})]},o.id)})}),e.jsx("p",{className:"db-setup-note",children:"Desktop users still see the shared setup checklist in the sidebar. This mobile version stays intentionally small."})]})}function gs(){var oe,re,le,ce,de,ue,pe,he,me,fe,be;const{user:s}=ve(),t=ts(),{isMobile:n}=$e(),{hasExtension:i,isChecking:r}=Be(),{status:c,isInstalled:d,canInstall:u,canPrompt:o,isAndroidChrome:m,install:w,showManualInstructions:A,manualInstallMessage:N}=is(),E=We("welcome"),{start:R,resume:F,status:C}=Fe(),[L,I]=l.useState(null),[J,U]=l.useState(!0),[K,b]=l.useState(!1),[x,k]=l.useState(null),[H,O]=l.useState(!1),M=l.useRef(new Set);l.useEffect(()=>{async function a(){try{const[f,B,Le,Oe]=await Promise.all([Je.list(),G.getStats(),G.getActivity(8),Ue.matches({limit:3}).catch(()=>[])]);I({resumes:f,stats:B,activity:Le,matches:Oe}),f.length===0?R():C==="in_progress"&&F()}catch{I({resumes:[],stats:{total:0,response_rate:0,interview_rate:0,offer_rate:0},activity:[],matches:[]}),R()}finally{U(!1)}}a()},[]),l.useEffect(()=>{if(n){const a=`mobile:${d?"installed":"install"}`;if(M.current.has(a))return;M.current.add(a),T("pwa_install_cta_impression",{platform:"mobile",installed:d,can_install:u,status:c});return}if(!r&&!i){const a="desktop:install";if(M.current.has(a))return;M.current.add(a),T("extension_cta_impression",{platform:"desktop",installed:!1})}},[u,r,i,c,n,d]);const y=l.useMemo(()=>Ye(),[]);if(J)return e.jsx("div",{className:"db-page",children:e.jsx("div",{className:"db-loading",children:"Loading your workspace…"})});if(!L)return null;const{resumes:h,stats:v,activity:D,matches:ne}=L,$=h.filter(a=>a.status==="done"),Se=D.filter(a=>a.status==="interview").length,_e=((oe=s==null?void 0:s.full_name)==null?void 0:oe.split(" ")[0])??((re=s==null?void 0:s.email)==null?void 0:re.split("@")[0])??"there",Ae=n?d?"mobile_installed":"mobile_install":i?"desktop_extension_ready":"desktop_install_extension",Ce=d?"Installed":o?"Add to Home Screen":c==="unsupported"?"Install from Chrome menu":"How to install",Ie=o?"Install Cvelo on your phone for faster access.":m?"Chrome has not made the install prompt available yet. Use the Chrome menu and tap Install app or Add to Home screen.":"Use your browser menu to add Cvelo to your home screen.",ae=Math.round(h.reduce((a,f)=>f.ats_score!=null?Math.max(a,f.ats_score):a,0)),Me=h.find(a=>a.ats_score!=null&&Math.round(a.ats_score)===ae),Y=te(((le=s==null?void 0:s.profile_completeness)==null?void 0:le.score)??[!!((ce=s==null?void 0:s.full_name)!=null&&ce.trim()),!!(s!=null&&s.default_resume_id),!!((de=s==null?void 0:s.public_profile)!=null&&de.linkedin_url||(ue=s==null?void 0:s.public_profile)!=null&&ue.github_url||(pe=s==null?void 0:s.public_profile)!=null&&pe.portfolio_url||(he=s==null?void 0:s.public_profile)!=null&&he.website_url),!!((me=s==null?void 0:s.preferred_locations)!=null&&me.length),!!((fe=s==null?void 0:s.skills_profile)!=null&&fe.length),!!((be=s==null?void 0:s.education_entries)!=null&&be.length)].filter(
1Boolean).length/6*100),X=!(s!=null&&s.default_resume_id),Pe=Y>=70?"Ready":`${Y}%`,ie=i?"Active":n&&d?"Installed":"Not installed",Te=[`${je($.length,"resume")} ready`,`${je(v.total,"application")} tracked`,i?"extension active":"extension not installed"].join(" · ");async function Ee(){O(!0);try{const a=await w();if(a.outcome==="manual"||a.outcome==="unsupported"){k(N);return}if(a.outcome==="dismissed"){k("Install prompt dismissed. You can try again anytime from this workspace.");return}k(null)}finally{O(!1)}}async function Re(){try{const[a,f]=await Promise.all([G.getStats(),G.getActivity(8)]);I(B=>B&&{...B,stats:a,activity:f})}catch{}}return e.jsxs("div",{className:"db-page",children:[e.jsxs("main",{className:"db-main",children:[e.jsxs("section",{className:"db-header",ref:E,children:[e.jsxs("div",{className:"db-header-main",children:[e.jsx(j,{children:"Workspace"}),e.jsxs("h1",{children:[os(),", ",_e,"."]}),e.jsx("p",{className:"db-header-subtitle",children:"Your job search workspace is ready."}),e.jsx("p",{className:"db-header-status",children:Te}),y!=null&&y.jobTypes.length?e.jsxs("p",{className:"db-header-prefs",children:["Jobs for you are currently tuned to ",y.jobTypes.slice(0,2).join(", "),y.jobTypes.length>2?` +${y.jobTypes.length-2} more`:"",y.location?` in ${y.location}`:"","."]}):null,e.jsxs("div",{className:"db-inline-actions",children:[e.jsx(p,{to:"/job-discovery",className:"db-btn-primary",children:"Find jobs"}),e.jsx(p,{to:"/resumes",className:"db-btn-secondary",children:"Create resume"}),e.jsx(p,{to:"/jobs/apply",className:"db-btn-secondary",children:"Tailor resume"})]})]}),e.jsxs("div",{className:"db-header-side",children:[e.jsx(g,{label:"Resume ready",value:`${$.length}`,tone:$.length>0?"ok":"warn"}),e.jsx(g,{label:"Applications",value:`${v.total}`}),e.jsx(g,{label:"Extension",value:ie,tone:i||d?"ok":"warn"}),e.jsx(g,{label:"Profile",value:Pe,tone:Y>=70?"ok":"default"})]})]}),e.jsx("div",{className:"db-header-divider"}),e.jsxs("section",{className:"db-status-strip",children:[e.jsx(g,{label:"Resume Ready",value:`${$.length}`,tone:$.length>0?"ok":"warn"}),e.jsx(g,{label:"Default Resume",value:X?"Missing":"Set",tone:X?"warn":"ok"}),e.jsx(g,{label:"Applications",value:`${v.total}`}),e.jsx(g,{label:"Extension",value:ie,tone:i||d?"ok":"warn"})]}),X&&e.jsxs("section",{className:"db-inline-alert",children:[e.jsxs("div",{children:[e.jsx("strong",{children:"Default resume needed"}),e.jsx("p",{children:"Set a default resume so Cvelo knows which resume to use first."})]}),e.jsx(p,{to:"/resumes",className:"db-text-link",children:"Set default resume →"})]}),e.jsxs("section",{className:"db-section db-section-actions",children:[e.jsx("div",{className:"db-section-head",children:e.jsxs("div",{children:[e.jsx(j,{children:"Primary Actions"}),e.jsx("h2",{children:"Move the next part of your search forward."})]})}),e.jsx("div",{className:"db-action-grid",children:ls.map(a=>{const f=e.jsxs(e.Fragment,{children:[e.jsxs("div",{className:"db-action-copy",children:[e.jsx("h3",{children:a.title}),e.jsx("p",{children:a.description})]}),e.jsxs("span",{className:"db-action-cta",children:[a.cta," →"]})]});return a.kind==="action"?e.jsx("button",{type:"button",className:"db-action-tile",onClick:()=>b(!0),children:f},a.title):e.jsx(p,{to:a.to,className:"db-action-tile",children:f},a.title)})})]}),e.jsxs("section",{className:"db-workspace",children:[e.jsxs("div",{className:"db-panel db-panel-primary db-panel-metrics",children:[e.jsxs("div",{className:"db-panel-head",children:[e.jsxs("div",{children:[e.jsx(j,{children:"Application Workspace"}),e.jsx("h2",{children:"Pipeline overview."})]}),e.jsx(p,{to:"/pipeline",className:"db-text-link",children:"My Applications →"})]}),e.jsxs("div",{className:"db-metric-grid",children:[e.jsxs("div",{className:"db-metric-tile",children:[e.jsx("span",{children:"Applications tracked"}),e.jsx("strong",{children:v.total})]}),e.jsxs("div",{className:"db-metric-tile",children:[e.jsx("span",{children:"Interviews"}),e.jsx("strong",{children:Se})]}),e.jsxs("div",{className:"db-metric-tile",children:[e.jsx("span",{children:"Response rate"}),e.jsxs("strong",{children:[v.response_rate,"%"]})]})]}),v.total===0?e.jsxs("div",{className:"db-empty-compact",children:[e.jsxs("div",{children:[e.jsx("h3",{children:"No tracked applications yet."}),e.jsx("p",{children:"Log your first role to start building your application workspace."})]}),e.jsx("button",{type:"button",className:"db-btn-secondary",onClick:()=>b(!0),children:"Log application"})]}):null]}),e.jsxs("div",{className:"db-panel db-panel-secondary db-panel-followup",children:[e.jsx("div",{className:"db-panel-head",children:e.jsxs("div",{children:[e.jsx(j,{children:"Next Follow-up"}),e.jsx("h2",{children:"What needs attention next."})]})}),D.length>0?e.jsx("div",{className:"db-followup-list",children:D.slice(0,3).map((a,f)=>e.jsxs("div",{className:"db-followup-row",children:[e.jsxs("div",{children:[e.jsx("strong",{children:a.company}),e.jsxs("span",{children:[a.role," · ",Ne[a.status]??a.status]})]}),e.jsx("span",{children:we(a.updated_at)})]},`${a.app_id}-${f}`))}):e.jsxs("div",{className:"db-empty-compact",children:[e.jsxs("div",{children:[e.jsx("h3",{children:"No tracked applications yet."}),e.jsx("p",{children:"Open your pipeline or log an application to start building follow-up rhythm."})]}),e.jsxs("div",{className:"db-inline-actions",children:[e.jsx(p,{to:"/pipeline",className:"db-btn-secondary",children:"Open pipeline"}),e.jsx("button",{type:"button",className:"db-btn-secondary",onClick:()=>b(!0),children:"Log application"})]})]})]})]}
1),e.jsxs("section",{className:"db-mid-grid",children:[e.jsx(hs,{score:ae,resume:Me,profileCompletion:Y}),e.jsxs("section",{className:"db-section db-section-jobs",children:[e.jsxs("div",{className:"db-section-head",children:[e.jsxs("div",{children:[e.jsx(j,{children:"Recommended Jobs"}),e.jsx("h2",{children:"Jobs that fit your current profile."})]}),e.jsx(p,{to:"/job-discovery",className:"db-text-link",children:"Go to Jobs for You →"})]}),ne.length>0?e.jsx("div",{className:"db-job-list",children:ne.map(a=>e.jsx(us,{match:a},a.id))}):e.jsxs("div",{className:"db-empty-compact",children:[e.jsxs("div",{children:[e.jsx("h3",{children:"No recommendations yet."}),e.jsx("p",{children:"Complete your profile and upload a resume to improve recommendations."})]}),e.jsx(p,{to:"/job-discovery",className:"db-btn-secondary",children:"Go to Jobs for You"})]})]})]}),e.jsxs("section",{className:"db-lower-grid",children:[e.jsxs("section",{className:"db-section db-section-activity",children:[e.jsxs("div",{className:"db-section-head",children:[e.jsxs("div",{children:[e.jsx(j,{children:"Recent Activity"}),e.jsx("h2",{children:"Your latest timeline."})]}),e.jsx(p,{to:"/pipeline",className:"db-text-link",children:"Open pipeline →"})]}),D.length>0?e.jsx("div",{className:"db-activity-list",children:D.map((a,f)=>e.jsx(ps,{item:a},`${a.app_id}-${f}`))}):e.jsxs("div",{className:"db-empty-compact",children:[e.jsxs("div",{children:[e.jsx("h3",{children:"No activity yet."}),e.jsx("p",{children:"Track your first application or tailor a resume to start building your timeline."})]}),e.jsx(p,{to:"/pipeline",className:"db-btn-secondary",children:"Open pipeline"})]})]}),e.jsxs("div",{className:"db-utility-stack",children:[e.jsx(ms,{variant:Ae,installButtonText:Ce,installHelpText:Ie,installBusy:H,installFeedback:x,manualInstallMessage:N,onInstall:Ee,showManualInstructions:A,isPWAInstalled:d}),t.supported&&t.permission!=="denied"&&e.jsxs("section",{className:"db-panel db-utility-panel db-utility-panel-accent",children:[e.jsx("div",{className:"db-panel-head",children:e.jsxs("div",{children:[e.jsx(j,{children:"Notifications"}),e.jsx("h2",{children:"Interview updates."})]})}),e.jsx("p",{className:"db-panel-copy",children:t.subscribed?"You'll be notified when an application status changes.":"Get notified when an application status changes."}),e.jsx("button",{type:"button",className:"db-btn-secondary",onClick:t.subscribed?t.unsubscribe:t.subscribe,disabled:t.loading,children:t.loading?"…":t.subscribed?"Turn off":"Turn on"})]}),n&&e.jsx(fs,{resumeCount:h.length,applicationCount:v.total,hasProfile:!!(s!=null&&s.full_name&&s.full_name.trim().split(" ").length>=2)})]})]})]}),K&&e.jsx(He,{onClose:()=>b(!1),onSave:()=>{b(!1),Re()}})]})}export{gs as Dashboard};

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.