1import{j as e,f as Ze,m as Qe,r as p,L as Le}from"./react-TITiJaTY.js";import{cN as Xe,a as es,c as ss,u as ts,cO as ns,t as Ge,aI as as,v as Ue,J as me,I as rs,bv as is,cP as os,cQ as ls}from"./App-Dli7sJFM.js";import{L as cs,b as us,d as Je,m as qe,a as ds,e as ps}from"./LoopBar-Dj29lbD_.js";import{a as hs}from"./factFlight-DN-2S6WG.js";/* empty css */import{b as ms}from"./autoKit-D29qjEA2.js";import{S as ys}from"./SectionTabs-DD1NeLsB.js";import{A as ks}from"./AppHeader-Bv7bfOUu.js";import{I as h}from"./shared-lite-BOZiOCY1.js";import{C as we}from"./CompanyLogo-DpgeMWhA.js";import{S as fs}from"./Skeleton-BCU2RlMF.js";import{j as bs,F as gs}from"./memory-BnxUEnat.js";import{n as js}from"./kitScore-C_Irlm-b.js";import{R as xs}from"./resumeKitQuality-D9nIgn4s.js";import{r as vs}from"./resumeIntegrityV2-SQb9e6qK.js";import{u as Ns,h as ws}from"./prepareLineage-DS9LiRiC.js";import{u as Ss,m as As}from"./motion-DheP8iPc.js";import"./index-D0VpW5-F.js";import"./podcastDeviceState-B0NlAIS7.js";import"./llm-CdWZ4qgd.js";import"./jobs-ChirZhp9.js";import"./resumeGen-CSG_GWQI.js";import"./skills-D6BqwXZN.js";import"./retry-heFjLrao.js";import"./defaultResume-Kuah1Fnp.js";import"./roleReadinessAssessment-CQFunQR_.js";import"./conversationalCapabilities-Bb0rm-l7.js";function Cs({steps:s=[],activeIndex:a=0,label:n="Working"}){return s.length?e.jsx("ol",{className:"thsteps","aria-label":n,children:s.map((i,l)=>{const u=l<a?"done":l===a?"active":"pending";return e.jsxs("li",{className:`thstep is-${u}`,children:[e.jsx("span",{className:"thstep-mark","aria-hidden":"true"}),e.jsx("span",{className:"thstep-label",children:i}),e.jsx("span",{className:"sr-only",children:u==="done"?" (done)":u==="active"?" (in progress)":" (waiting)"})]},i)})}):null}const ye=Object.freeze([{key:"fit",label:"Checking fit against the posting"},{key:"coverLetter",label:"Drafting the cover letter"},{key:"appAnswers",label:"Answering the application questions"},{key:"tailoredResume",label:"Tailoring your resume"},{key:"verify",label:"Checking claims against available evidence"}]),He=(s,a)=>s?a==="appAnswers"?Array.isArray(s.appAnswers)&&s.appAnswers.length>0:a==="verify"?!1:!!s[a]:!1;function Rs(s){const a=ye.reduce((i,l)=>He(s,l.key)?i+1:i,0),n=ye.findIndex(i=>!He(s,i.key));return{steps:ye.map(i=>i.label),activeIndex:n===-1?ye.length-1:n,done:a,total:ye.length}}function Ts({item:s,pieces:a=["resume","cover","answers"]}){const n=a.filter(i=>{var l,u,y,m;return i==="resume"?(l=s.kit)==null?void 0:l.tailoredResume:i==="cover"?(u=s.kit)==null?void 0:u.coverLetter:(m=(y=s.kit)==null?void 0:y.appAnswers)==null?void 0:m.length}).map(i=>Xe(s,i));return n.length?e.jsxs("details",{className:"srcd",children:[e.jsxs("summary",{children:["Why this kit? · ",n.length," source trail",n.length===1?"":"s"]}),e.jsx("div",{children:n.map(i=>e.jsxs("section",{children:[e.jsx("strong",{children:i.outputField}),e.jsx("p",{children:i.transformationSummary}),e.jsxs("dl",{children:[e.jsxs("div",{children:[e.jsx("dt",{children:"Source"}),e.jsx("dd",{children:i.sourceRecord})]}),e.jsxs("div",{children:[e.jsx("dt",{children:"Confidence"}),e.jsx("dd",{children:i.confidence==null?"Not scored":`${Math.round(i.confidence*100)}%`})]}),e.jsxs("div",{children:[e.jsx("dt",{children:"Review"}),e.jsx("dd",{children:i.reviewRequirement.replaceAll("-"," ")})]})]})]},i.outputField))}),e.jsx("footer",{children:"Sensitive and unsupported fields stay unresolved until you confirm them."})]}):null}const Ve=` 2AD AE AF AG AI AL AM AO AQ AR AS AT AU AW AX AZ 3BA BB BD BE BF BG BH BI BJ BL BM BN BO BQ BR BS BT BV BW BY BZ 4CA CC CD CF CG CH CI CK CL CM CN CO CR CU CV CW CX CY CZ 5DE DJ DK DM DO DZ EC EE EG EH ER ES ET FI FJ FK FM FO FR 6GA GB GD GE GF GG GH GI GL GM GN GP GQ GR GS GT GU GW GY 7HK HM HN HR HT HU ID IE IL IM IN IO IQ IR IS IT JE JM JO JP 8KE KG KH KI KM KN KP KR KW KY KZ LA LB LC LI LK LR LS LT LU LV LY 9MA MC MD ME MF MG MH MK ML MM MN MO MP MQ MR MS MT MU MV MW MX MY MZ 10NA NC NE NF NG NI NL NO NP NR NU NZ OM PA PE PF PG PH PK PL PM PN PR
11PS PT PW PY QA RE RO RS RU RW SA SB SC SD SE SG SH SI SJ SK SL SM SN 12SO SR SS ST SV SX SY SZ TC TD TF TG TH TJ TK TL TM TN TO TR TT TV TW 13TZ UA UG UM US UY UZ VA VC VE VG VI VN VU WF WS YE YT ZA ZM ZW 14`.trim().split(/\s+/),Is=new Set(Ve);let Se=null;try{Se=new Intl.DisplayNames(["en"],{type:"region"})}catch{}const Ee=Object.freeze(Ve.map(s=>Object.freeze({code:s,label:(Se==null?void 0:Se.of(s))||s})).sort((s,a)=>s.label.localeCompare(a.label)));function fe(s){return typeof s=="string"&&Is.has(s)}const De="job-boards.greenhouse.io",Es=/^gh:([A-Za-z0-9][A-Za-z0-9_-]{0,127}):(\d{1,30})$/,Ls=/^\/([A-Za-z0-9][A-Za-z0-9_-]{0,127})\/jobs\/(\d{1,30})\/?$/;function Me(s={}){const a=String((s==null?void 0:s.id)||"").match(Es);if(!a)return null;let n;try{n=new URL(String((s==null?void 0:s.url)||""))}catch{return null}if(n.protocol!=="https:"||n.username||n.password||n.port||n.hash||n.hostname.toLowerCase()!==De)return null;const i=n.pathname.match(Ls);if(!i)return null;const l=i[1].toLowerCase(),u=i[2];if(a[1].toLowerCase()!==l||a[2]!==u||[...n.searchParams.keys()].some(g=>!["gh_jid","gh_src"].includes(g))||n.searchParams.getAll("gh_jid").length>1||n.searchParams.getAll("gh_src").length>1)return null;const m=n.searchParams.get("gh_jid"),j=n.searchParams.get("gh_src");return m&&m!==u||j&&!/^[A-Za-z0-9._-]{1,200}$/.test(j)?null:Object.freeze({boardSlug:l,jobId:u,providerHost:De,companyKey:`greenhouse:${l}`,roleKey:`gh:${l}:${u}`})}function M(s,a,n){const i=new Error(typeof(s==null?void 0:s.error)=="string"&&s.error.trim()?s.error:n);return i.name="ApplicationStandingAuthorityError",i.status=a,s!=null&&s.applicationStandingAuthority&&(i.applicationStandingAuthority=s.applicationStandingAuthority),i}async function Ke(s){try{return await s.json()}catch{return null}}function ze(s,a){const n=s==null?void 0:s.applicationStandingAuthority;if(!n||!Number.isSafeInteger(n.revision)||n.revision<0)throw M(s,a,"Standing authority returned an invalid response. Try again.");return n}async function Oe(){let s;try{s=await fetch("/api/application-standing-authority",{method:"GET",credentials:"include",cache:"no-store",headers:{Accept:"application/json"}})}catch{throw M(null,0,"Could not load relocation permission. Check your connection and try again.")}const a=await Ke(s);if(!s.ok)throw M(a,s.status,"Could not load relocation permission. Try again.");return ze(a,s.status)}async function Ms(s,a){if(!Number.isSafeInteger(a)||a<0)throw M(null,0,"Reload relocation permission before saving it.");let n;try{n=await fetch("/api/application-standing-authority",{method:"PUT",credentials:"include",cache:"no-store",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify({expectedRevision:a,grant:s})})}catch{throw M(null,0,"Could not save relocation permission. Check your connection and try again.")}const i=await Ke(n);if(!n.ok)throw M(i,n.status,"Could not save relocation permission. Try again.");return{applicationStandingAuthority:ze(i,n.status),grantId:typeof(i==null?void 0:i.grantId)=="string"?i.grantId:""}}async function Ks(s){if(!/^sag_[a-f0-9]{24}$/.test(String(s||"")))throw M(null,0,"Reload relocation permission before revoking it.");let a;try{a=await fetch(`/api/application-standing-authority/${encodeURIComponent(s)}`,{method:"DELETE",credentials:"include",cache:"no-store",headers:{Accept:"application/json"}})}catch{throw M(null,0,"Could not revoke relocation permission. Check your connection and try again.")}const n=await Ke(a);if(!a.ok)throw M(n,a.status,"Could not revoke relocation permission. Try again.");return ze(n,a.status)}function zs(s,a,{now:n=Date.now()}={}){const i=Me(a);return!i||!s||!Array.isArray(s.grants)||!Number.isFinite(Number(n))?[]:s.grants.filter(l=>{var m,j,g,C;const u=l==null?void 0:l.scope,y=Date.parse(((m=l==null?void 0:l.lifecycle)==null?void 0:m.expiresAt)||(l==null?void 0:l.expiresAt)||"");return/^sag_[a-f0-9]{24}$/.test(String((l==null?void 0:l.grantId)||""))&&l.category==="relocation"&&l.state==="active"&&["willing","not_willing"].includes((j=l==null?void 0:l.value)==null?void 0:j.decision)&&((g=l==null?void 0:l.permissions)==null?void 0:g.fill)===!0&&((C=l==null?void 0:l.permissions)==null?void 0:C.autonomousSubmit)===!0&&Number.isFinite(y)&&y>Number(n)&&Array.isArray(u==null?void 0:u.roleKeys)&&u.roleKeys.includes(i.roleKe
14y)&&Array.isArray(u==null?void 0:u.companyKeys)&&u.companyKeys.includes(i.companyKey)&&Array.isArray(u==null?void 0:u.providerHosts)&&u.providerHosts.includes(i.providerHost)&&Array.isArray(u==null?void 0:u.destinationJurisdictions)&&u.destinationJurisdictions.length===1&&fe(u.destinationJurisdictions[0])}).sort((l,u)=>String(l.grantId).localeCompare(String(u.grantId)))}function Bs(s,a,n){const i=Me(s);return!i||!["yes","no"].includes(a)||!fe(n)?null:{category:"relocation",value:{decision:a==="yes"?"willing":"not_willing"},scope:{destinationJurisdictions:[n],companyKeys:[i.companyKey],roleKeys:[i.roleKey],providerHosts:[i.providerHost]},permissions:{fill:!0,autonomousSubmit:!0}}}async function Ps({item:s,relocate:a,jurisdiction:n}){const i=Bs(s,a,n);if(!i)throw M(null,0,"This role cannot receive a reusable relocation permission.");const l=await Oe();return Ms(i,l.revision)}const $s=s=>Number.isFinite(s)?s>=60?{label:"High overlap",tone:"strong",icon:"check"}:s>=35?{label:"Some overlap",tone:"moderate",icon:"spark"}:{label:"Low overlap",tone:"limited",icon:"warn"}:{label:"Not assessed",tone:"neutral",icon:"target"};function Ae({score:s}){const a=$s(s);return e.jsxs("span",{className:`kl-fit is-${a.tone}`,title:"Preliminary role overlap from your saved persona. Review the named requirements and evidence before deciding.","aria-label":`${a.label}. Preliminary role overlap only; this is not a qualification or hiring prediction.`,children:[e.jsx(h,{name:a.icon,size:13})," ",a.label]})}const ke=s=>!!(s&&(s.coverLetter||Array.isArray(s.appAnswers)&&s.appAnswers.length||s.tailoredResume||s.fit)),Gs=2,Be=(s={})=>{var a;return!!(s.tailoredResume&&Number(s.resumeIntegrityVersion)===Gs&&Number((a=s.quality)==null?void 0:a.schemaVersion)===xs&&s.resumeHeader&&["fullName","title","contact"].every(n=>typeof s.resumeHeader[n]=="string")&&vs(s))},Pe=(s={})=>{var y,m;const a=(m=(y=s==null?void 0:s.kit)==null?void 0:y.quality)==null?void 0:m.sourceHashes,n=String((s==null?void 0:s.candidateSourceHash)||""),i=String((s==null?void 0:s.jobSourceHash)||""),l=String((s==null?void 0:s.resumeSourceHash)||""),u=/^[a-f0-9]{64}$/;return!!(u.test(n)&&u.test(i)&&u.test(l)&&String((a==null?void 0:a.candidate)||"")===n&&Str
14ing((a==null?void 0:a.job)||"")===i&&String((a==null?void 0:a.resumeSource)||"")===l)},_e=(s={},a={})=>{if(S(s))return!1;const n=(s==null?void 0:s.kit)||{};return n.tailoredResume&&!Be(n)||!Pe(s)?!1:Ue(s,a).state==="needs-review"},Ce=s=>s.kitStatus==="building"&&!ke(s.kit),S=us,J=(s={})=>{const a=Je(s);if(a!=null&&a.terminal)return a.phase==="rejected-after-send"?"Employer processing rejected this application after it was sent. Its terminal receipt stays locked against a duplicate; review the primary record in Jobs.":a.phase==="rejected"?"The employer rejected or held this autonomous attempt. Its durable terminal fence remains locked; review the primary record in Jobs before any retry.":a.phase==="uncertain"?"This application has an uncertain terminal receipt. Do not apply again; resolve the primary record in Jobs.":"This application was already sent. Its durable terminal receipt keeps the posting locked against duplicates.";if(qe(s))return"Manual application handoff is active. Resume it or mark it applied from Jobs; this library will not open a second employer tab.";if(!a)return"";const n=Number(a.browserAttemptId)>0?` #${a.browserAttemptId}`:"";return a.phase==="confirmed"?`Autonomous attempt${n} is confirmed as already sent. This canonical posting is locked against duplicates.`:a.phase==="uncertain"?`Employer receipt for autonomous attempt${n} is uncertain. Do not apply again; resolve it from Jobs.`:a.phase==="rejected"?`Autonomous attempt${n} was rejected or held. This canonical posting remains locked; manage the primary attempt from Jobs.`:a.phase==="authorized"?`Autonomous attempt${n} is authorized at the employer boundary. Do not open another application while its outcome is pending.`:["leased","preparing","reserved"].includes(a.phase)?`Autonomous attempt${n} is being prepared. Employer navigation is held.`:a.phase==="queued"?`Autonomous attempt${n} is queued. Employer navigation is held.`:`Autonomous attempt${n} is being verified. Do not open another application.`},Hs=1e5,Ds=s=>Ce(s)&&(!s.kitStatusAt||Date.now()-s.kitStatusAt>Hs);function _s(s={},a=null){if(s.tailoredResume&&!Be(s))return[{key:"resume-integrity-v2",tone:"warn",icon:"refresh",label:"Resume rebuild required",detail:"This resume predates per-role promotion checks and the frozen reviewed header. Rebuild it before review or download."}];const n=js(s);if(!n.structured)return!!(s.confidence||s.ats||s.tailoredResume||s.coverLetter)?[{key:"legacy",tone:"neutral",icon:"refresh",label:"Older quality record",detail:"Rebuild this kit to run the named parser, minimum-qualification, and truth checks."}]:[];if(a&&!Pe(a))return[{key:"source-integrity",tone:"warn",icon:"refresh",label:"Source changed",detail:"Your Persona or this posting changed after this kit was built. Rebuild the kit and review the new revision before using it."}];const i=n.parserStatus==="pass",l=n.truthStatus==="pass"&&Array.isArray(n.unsupportedClaims)&&n.unsupportedClaims.length===0&&Array.isArray(n.unsupportedNumbers)&&n.unsupportedNumbers.length===0,u=n.minimumStatus||"UNKNOWN",y=n.minimumEvidenced!==null&&n.minimumTotal!==null,m=u==="MET"&&y&&n.minimumEvidenced===n.minimumTotal&&Array.isArray(n.minimumMissing)&&n.minimumMissing.length===0&&Array.isArray(n.minimumContradictions)&&n.minimumContradictions.length===0,j=m?n.minimumTotal===0?"No stated minimums":`Minimum evidence ${n.minimumEvidenced}/${n.minimumTotal}`:y?`Minimum evidence ${n.minimumEvidenced}/${n.minimumTotal}`:u==="NOT_MET"?"Minimums not met":u==="CONTRADICTORY"?"Minimums conflict":"Minimums unverified";return[{key:"parser",tone:i?"ok":"warn",icon:i?"check":"warn",label:i?"Parser pass":"Parser review",detail:i?"The generated resume passed the structured parser checks.":"Parser compatibility is missing or needs attention."},{key:"minimums",tone:m?"ok":"warn",icon:m?"check":"warn",label:j,detail:m?"Every stated minimum qualification has supporting candidate evidence.":"One or more stated minimum qualifications is missing, partial, contradictory, or not yet verified."},{key:"truth",tone:l?"ok":"warn",icon:l?"check":"warn",label:l?"Truth checked":"Truth review",detail
14:l?"No unsupported claims or numbers were found in the structured truth check.":"Truth evidence is missing or an unsupported claim still needs review."}]}function Fe({text:s,label:a="Copy",small:n}){const[i,l]=p.useState("idle"),u=async()=>{try{await navigator.clipboard.writeText(s),l("done")}catch{l("fail")}setTimeout(()=>l("idle"),2200)};return e.jsxs("button",{type:"button",className:`kl-copy${n?" kl-copy-sm":""}`,onClick:u,disabled:!s,children:[e.jsx(h,{name:i==="done"?"check":i==="fail"?"warn":"copy",size:13})," ",i==="done"?"Copied":i==="fail"?"Copy blocked - select manually":a]})}function Fs(){const s=p.useId();return e.jsxs("section",{className:"kl-empty","aria-labelledby":s,children:[e.jsx("span",{className:"kl-empty-ic","aria-hidden":"true",children:e.jsx(h,{name:"spark",size:26})}),e.jsx("h2",{id:s,className:"kl-h2",children:"Prepare your first application kit"}),e.jsx(Le,{to:"/app/jobs",className:"btn btn-primary",children:"Find a role"}),e.jsx("p",{className:"kl-empty-copy",children:"Choose a role in Find, then prepare a kit from your Persona and the posting. It will appear here for your review."}),e.jsxs("details",{className:"kl-empty-disclosure",children:[e.jsx("summary",{children:"Whatâs in a ready kit?"}),e.jsxs("ul",{children:[e.jsxs("li",{children:[e.jsx(h,{name:"check",size:14}),e.jsx("span",{children:"A role-tailored resume with evidence checks"})]}),e.jsxs("li",{children:[e.jsx(h,{name:"check",size:14}),e.jsx("span",{children:"A cover letter draft in your voice"})]}),e.jsxs("li",{children:[e.jsx(h,{name:"check",size:14}),e.jsx("span",{children:"Grounded answers when the application asks for them"})]})]})]})]})}function Us({item:s,profile:a,lineage:n=null,onFinish:i,onApprove:l,onDelete:u,focused:y=!1,standingAuthorityView:m={status:"unavailable",document:null},onRevokeRelocationAuthority:j=null,onOpenPosting:g=null,handoffBusy:C=!1,handoffError:be=""}){var de,pe,he,v;const q=p.useRef(null),A=p.useId(),[ee,B]=p.useState(!1),[V,se]=p.useState(!1),[ge,je]=p.useState(!1),[N,D]=p.useState(!1),[O,E]=p.useState(""),te=fe((pe=(de=s==null?void 0:s.kit)==null?void 0:de.applicationContext)==null?void 0:pe.jurisdiction)?s.kit.applicationContext.jurisdiction:"",[w,W]=p.useState(te),[Y,ne]=p.useState(!1),_=["yes","no"].includes(a==null?void 0:a.relocate)?a.relocate:"",[P,ae]=p.useState(_),[$,L]=p.useState(""),[K,G]=p.useState(""),[Re,R]=p.useState(!1),k=s.kit||{},re=Be(k),F=!!k.tailoredResume&&!re,z=!Pe(s),H=re&&!z,T=!!k.tailoredResume&&(F||z)&&s.status!=="applied",I=Array.isArray(k.appAnswers)?k.appAnswers:[],Z=k.confidence,xe=_s(k,s),ie=((Z==null?void 0:Z.flags)||[]).filter(c=>!(as(s)&&/review before send/i.test(String(c)))),ve=Ue(s,a),b=T?z?{state:"resume-rebuild",label:"Kit sources changed",missing:[],primary:{label:"Rebuild kit",action:"rebuild-kit"}}:{state:"resume-rebuild",label:"Resume blocked",missing:[],primary:{label:"Rebuild resume only",action:"rebuild-resume"}}:ve,t=ws(s,n),r=Me(s),o=Je(s),d=qe(s),f=!!(o||d),oe=P,Te=!!(r&&oe),Q=Y&&!w,le=Ee.find(c=>c.code===w),U=zs(m.document,s);p.useEffect(()=>{!y||!q.current||(q.current.scrollIntoView({block:"center"}),q.current.focus({preventScroll:!0}))},[y]),p.useEffect(()=>{W(te),ne(!1),ae(_)},[s.key,s.kitRevision,s.kitContentHash,te,_]);const X=()=>{je(!0),E(""),se(!!k.coverLetter),B(!!I.length)},ce=async()=>{if(!l||N)return;if(Q){E("Choose the application country before saving a relocation permission.");return}D(!0),E("");let c=null;try{c=await l(s,{applicationContext:r?w?{jurisdiction:w}:null:void 0,grantRelocation:Y,...r?{relocationChoice:oe}:{}})}catch{}c===!0||(c==null?void 0:c.ok)===!0||E((c==null?void 0:c.error)||"This kit changed or could not be approved. Review the latest revision and try again."),D(!1)},Ne=async c=>{if(!j||$)return;L(c),G("");const x=await j(c);x!=null&&x.ok||G((x==null?void 0:x.error)||"Could not revoke relocation permission. Try again."),L("")},ue=J(s);return e.jsxs("li",{ref:q,className:`kl-card${y?" is-focused":""}`,"data-kit-key":s.key,tabIndex:y?-1:void 0,"aria-current":y?"true":void 0,children:[e.jsx(Ae,{score:s.fit}),e.jsxs("div",{className:"kl-body",children:[e.jsxs("div",{className:"kl-titlerow",children:[f||!g?e.jsx("span",{className:"kl-title","aria-disabled":f?"true":void 0,children:s.title}):e.jsx("button",{type:"button",className:"kl-title kl-title-action",disabled:C,onClick:()=>g(s,s.url),children:s.title}),xe.map(c=>e.jsxs("span",{className:`kl-conf ${c.tone}`,title:c.detail,"aria-label":`${c.label}. ${c.detail}`,children:[e.jsx(h,{name:c.icon,size:12})," ",c.label]},c.key)),e.jsx("span",{className:`kl-state is-${b.state}`,children:b.label})]}
14),e.jsxs("div",{className:"kl-meta",children:[e.jsx(we,{company:s.company,size:15,className:"colo-in"}),s.company||"Company n/a",s.location?` · ${s.location}`:"",s.saved&&e.jsxs(e.Fragment,{children:[" · ",e.jsx("span",{className:"kl-chip-saved",children:"added by you"})]})]}),e.jsxs("div",{className:"kl-pieces",children:[e.jsxs("span",{className:`kl-piece ${H?"on":""}`,children:[e.jsx(h,{name:H?"check":F||z?"refresh":"x",size:12})," ",z?"Resume source changed":F?"Resume needs rebuild":"Resume"]}),e.jsxs("span",{className:`kl-piece ${k.coverLetter?"on":""}`,children:[e.jsx(h,{name:k.coverLetter?"check":"x",size:12})," Cover letter"]}),e.jsxs("span",{className:`kl-piece ${I.length?"on":""}`,children:[e.jsx(h,{name:I.length?"check":"x",size:12})," ",I.length||0," answer",I.length===1?"":"s"]})]}),ie.length>0&&e.jsxs("p",{className:"kl-flags",children:[e.jsx(h,{name:"warn",size:12})," ",ie.slice(0,3).join(" · ")]}),ue&&e.jsxs("p",{className:"kl-authority-status is-review",role:"status",children:[e.jsx(h,{name:"shield",size:13})," ",ue]}),be&&e.jsx("p",{className:"kl-review-error",role:"alert",children:be}),((he=b.missing)==null?void 0:he.length)>0&&e.jsxs("p",{className:"kl-state-reason",children:["Needs: ",b.missing.slice(0,3).join(" · ")]}),T&&e.jsxs("div",{className:"kl-resume-lock",role:"status",children:[e.jsx(h,{name:"refresh",size:15}),z?e.jsxs("p",{children:[e.jsx("strong",{children:"Delivery is locked."})," Your Persona or this posting changed. Rebuild the kit, review the new evidence, then approve its new revision."]}):e.jsxs("p",{children:[e.jsx("strong",{children:"Resume actions are locked."})," Rebuild to check every role and freeze the reviewed header. Your cover letter and answers stay intact."]})]}),t&&e.jsxs("p",{className:"kl-state-reason",children:["Readiness at preparation: ",e.jsx("strong",{children:((v=t.payload)==null?void 0:v.verdict)||t.title}),t.staleStatus==="stale"?" · snapshot is stale":""]}),e.jsx(Ts,{item:s}),!r&&/^gh:[A-Za-z0-9][A-Za-z0-9_-]*:\d+$/.test(String(s.id||""))&&e.jsxs("p",{className:"kl-authority-status is-review",role:"status",children:[e.jsx(h,{name:"shield",size:13})," Custom Greenhouse career link: review-first only. Autonomous submission currently supports direct job-boards.greenhouse.io pages only."]}),r&&m.status!=="ready"&&e.jsxs("p",{className:"kl-authority-status is-unknown",role:"status",children:[e.jsx(h,{name:"warn",size:13})," Reusable relocation-permission status is unavailable. Nyanza will keep the field held unless the server can revalidate it."]}),U.map(c=>{var $e;const x=c.scope.destinationJurisdictions[0],Ie=Ee.find(Ye=>Ye.code===x),We=(($e=c.lifecycle)==null?void 0:$e.expiresAt)||c.expiresAt;return e.jsxs("div",{className:"kl-authority-status is-active",role:"status",children:[e.jsx(h,{name:"shield",size:13}),e.jsxs("span",{children:[e.jsx("strong",{children:"Relocation permission active:"})," ",c.value.decision==="willing"?"willing to relocate":"not willing to relocate"," · ",(Ie==null?void 0:Ie.label)||x," · expires ",new Date(We).toLocaleDateString(),"."]}),e.jsx("button",{type:"button",className:"kl-copy kl-del",disabled:$===c.grantId,onClick:()=>Ne(c.grantId),children:$===c.grantId?"Revokingâ¦":"Revoke"})]},c.grantId)}),K&&e.jsx("p",{className:"kl-review-error",role:"alert",children:K}),V&&k.coverLetter&&e.jsx("pre",{className:"kl-letter",children:k.coverLetter}),ee&&I.length>0&&e.jsx("ul",{className:"kl-answers",children:I.map((c,x)=>e.jsxs("li",{children:[e.jsx("div",{className:"kl-q",children:c.q}),e.jsx("div",{className:"kl-a",children:c.a}),e.jsx(Fe,{text:c.a,label:"Copy answer",small:!0})]},x))}),ge&&b.state==="needs-review"&&!F&&!f&&e.jsxs("div",{className:"kl-review",role:"region","aria-label":`Approve revision ${s.kitRevision||1}`,children:[e.jsxs("div",{children:[e.jsx("strong",{children:"Approve this exact kit"}),e.jsxs("p",{children:["Revision ",s.kitRevision||1,". Any later change to the resume, letter, answers, fit evidence, or application country will require a new approval."]})]}),r&&e.jsxs("div",{className:"kl-review-context",children:[e.jsx("label",{htmlFor:A,children:"Application country"}),e.jsxs("select",{id:A,value:w,onChange:c=>{W(c.target.value),E("")},"aria-describedby":`${A}-hint`,disabled:N,children:[e.jsx("option",{value:"",children:"Not specified (relocation stays held)"}),Ee.map(c=>e.jsxs("option",{value:c.code,children:[c.label," (",c.code,")"]},c.code))]}),e.jsx("p",{id:`${A}-hint`,children:"Choose the country this application is for. Nyanza will not infer it from the posting or your profile."}),e.jsx("label",{htmlFor:`${A}-relocation`,children:"Relocation answer for this role"}),e.jsxs("select",{id:`${A}-relocation`,value:P,onChange:c=>{ae(c.target.value),ne(!1),E("")},disabled:N,children:[e.jsx("option",{value:"",children:"No reusable relocation answer"}),e.jsx("option",{value:"yes",children:"Willing to relocate"}),e.jsx("option",{value:"no",children:"Not willing to relocate"})]}),Te&&e.jsxs("label",{className:"kl-authority-choice",children:[e.jsx("input",{type:"checkbox",checked:Y,onChange:c=>{ne(c.target.checked),E("")},disabled:N}),e.jsxs("span",{children:[e.jsxs("strong",{children:[oe==="yes"?"Allow âwilling to relocateâ":"Allow ânot willing to relocateâ"," for this role"]}),e.jsxs("small",{children:["This creates a 180-day permission limited to ",s.company||r.boardSlug,", this exact role, and ",(le==null?void 0:le.label)||"the country you choose","."]}),U.length>0&&e.jsx("small",{children:"Leaving this unchecked does not revoke the active permission shown above. Use Revoke to remove it."})]})]}),Q&&e.jsx("p",{className:"kl-context-error",role:"alert",children:"Choose an application country to create this permission."})]}),e.jsxs("div",{className:"kl-review-actions",children:[re&&e.jsxs("a",{className:"kl-copy",href:"/api/resume-pdf?key="+encodeURIComponent(s.key),target:"_blank",rel:"noopener noreferrer",children:[e.jsx(h,{name:"doc",size:13})," Review resume"]}),e.jsx("button",{type:"button",className:"btn btn-primary btn-sm",onClick:ce,disabled:N||Q,children:N?"Approvingâ¦":Y?"Save permission & approve":"Approve this revision"})]}),O&&e.jsx("p",{className:"kl-review-error",role:"alert",children:O})]})]}),e.jsxs("div",{className:"kl-actions",children:[b.primary.to&&!T&&(!f||s.status==="applied")&&e.jsx(Le,{className:"btn btn-primary btn-sm",to:b.primary.to,children:b.primary.label}),b.primary.url&&!T&&!f&&g&&e.jsxs("button",{type:"button",className:"btn btn-primary btn-sm",disabled:C,onClick:()=>g(s,b.primary.url),children:[C?"Securing handoffâ¦":b.primary.label," ",e.jsx(h,{name:"arrowRight",size:13})]}),["finish","retry"].includes(b.primary.action)&&i&&!T&&!f&&e.jsxs("button",{type:"button",className:"btn btn-primary btn-sm",onClick:()=>i(s),children:[e.jsx(h,{name:"refresh",size:13})," ",b.primary.label]}),T&&i&&!f&&e.jsxs("button",{type:"button",className:"btn btn-primary btn-sm",onClick:()=>i(s),children:[e.jsx(h,{name:"refresh",size:13})," ",z?"Rebuild kit":"Rebuild resume only"]}),b.primary.action==="review"&&!ge&&!T&&!f&&e.jsx("button",{type:"button",className:"btn btn-primary btn-sm",onClick:X,children:b.primary.label}),b.primary.action==="confirm-submission"&&!T&&e.jsx(Le,{className:"btn btn-primary btn-sm",to:"/app/tracker",children:"Confirm submission"}),s.url&&!b.primary.url&&!f&&g&&e.jsx("button",{type:"button",className:"btn btn-ghost btn-sm",disabled:C,onClick:()=>g(s,s.url),children:C?"Securing handoffâ¦":"Open posting"}),H&&e.jsxs("a",{className:"kl-copy",href:"/api/resume-pdf?key="+encodeURIComponent(s.key),target:"_blank",rel:"noopener noreferrer",title:"Open this job's tailored resume as a PDF",children:[e.jsx(h,{name:"doc",size:13})," View resume"]}),k.coverLetter&&e.jsxs("button",{type:"button",className:"kl-copy",onClick:()=>se(c=>!c),"aria-expanded":V,children:[e.jsx(h,{name:"chevronDown",size:13})," ",V?"Hide":"View"," letter"]}),k.coverLetter&&e.jsx(Fe,{text:k.coverLetter,label:"Copy cover letter"}),I.length>0&&e.jsxs("button",{type:"button",className:"kl-copy",onClick:()=>B(c=>!c),"aria-expanded":ee,children:[e.jsx(h,{name:"chevronDown",size:13})," ",ee?"Hide":"View"," answers"]}),u&&!f&&(Re?e.jsx("button",{type:"button",className:"kl-copy kl-del",onClick:()=>u(s),onBlur:()=>R(!1),title:"Removes this role and its kit from your library",children:"Really delete?"}):e.jsxs("button",{type:"button",className:"kl-copy kl-del",onClick:()=>R(!0),title:"Remove this role and its kit from your library",children:[e.jsx(h,{name:"x",size:13})," Delete"]}))]})]})}function bt(){Ze();const[s]=Qe(),a=s.get("kit")||"",n=Ss(),{profile:i}=es(),{user:l}=ss(),u=Ns(),y=ts(),m=ns(),[j,g]=p.useState(null),[C,be]=p.useState(!1),[q,A]=p.useState({status:"checking",document:null}),[ee,B]=p.useState({}),[V,se]=p.useState(""),[ge,je]=p.useState({}),N=p.useRef(null),[D,O]=p.useState(null),[E,te]=p.useState(!1),[w,W]=p.useState(()=>new Set),Y=t=>{S(t)||W(r=>{const o=new Set(r);return o.has(t.key)?o.delete(t.key):o.add(t.key),o})},ne=()=>{for(const t of R.filter(r=>w.has(r.key)&&!S(r)))H(t);W(new Set)},_=p.useRef(null),P=async()=>{const t=await Ge();return g(t),be(!0),t},ae=async()=>{try{const t=await Oe();return A({status:"ready",document:t}),t}catch{return A({status:"unavailable",document:null}),null}};p.useEffect(()=>{P(),ae()},[]),p.useEffect(()=>{const t=()=>ae(),r=()=>{document.visibilityState==="visible"&&t()};return window.addEventListener("focus",t),document.addEventListener("visibilitychange",r),()=>{window.removeEventListener("focus",t),document.removeEventListener("visibilitychange",r)}},[]);const $=((j==null?void 0:j.queue)||[]).filter(t=>
14t.status!=="dismissed"),L=$.filter(t=>ke(t.kit)).sort((t,r)=>(Number(r.fit)||0)-(Number(t.fit)||0)),K=$.filter(Ce),G=$.filter(t=>t.kitStatus==="failed"&&!ke(t.kit)&&!Ce(t)),Re=new Set(G.map(t=>t.key)),R=$.filter(t=>t.status==="new"&&!ke(t.kit)&&!Ce(t)&&!Re.has(t.key)),k=p.useRef(new Set);p.useEffect(()=>{const t=new Set(L.map(d=>d.key));if(!k.current.size){k.current=t;return}const r=[...t].filter(d=>!k.current.has(d));if(k.current=t,!r.length)return;const o=requestAnimationFrame(()=>{for(const d of r.slice(0,2)){const f=document.querySelector(`[data-kit-key="${CSS.escape(d)}"]`);f&&hs(f,{label:"From your confirmed record",kind:"kit"})}});return()=>cancelAnimationFrame(o)},[L.map(t=>t.key).join(",")]),p.useEffect(()=>{if(!(K.length>0)){N.current&&(clearInterval(N.current),N.current=null);return}if(!N.current)return N.current=setInterval(()=>{Ge().then(r=>{r&&g(r)})},4e3),()=>{N.current&&(clearInterval(N.current),N.current=null)}},[K.length]);const re=async(t,r=t==null?void 0:t.url)=>{if(!t||S(t)||V)return!1;se(t.key),je(d=>({...d,[t.key]:""}));const o=await ds(t,r);return se(""),o!=null&&o.queue&&g(d=>d?{...d,queue:o.queue}:{queue:o.queue}),o!=null&&o.ok?!0:(je(d=>({...d,[t.key]:(o==null?void 0:o.reason)==="application-state-changed"?"This application changed or an autonomous attempt is active. Reload before opening it.":(o==null?void 0:o.reason)==="popup-blocked"?"Your browser blocked the employer tab. Open Jobs and choose Resume manual application.":(o==null?void 0:o.reason)==="navigation-failed"?"The employer tab could not navigate. Open Jobs and choose Resume manual application.":(o==null?void 0:o.reason)==="exact-application-identity-unavailable"?"This exact reviewed Kit is unavailable. Rebuild or review it before opening the posting.":"Could not safely hand this application to your browser. Nothing was opened; try again."})),!1)},F=async t=>{S(t)||(await me(t.key,{status:"dismissed"}),O(t),clearTimeout(_.current),_.current=setTimeout(()=>O(null),6e3),P())},z=async()=>{const t=D;O(null),clearTimeout(_.current),t&&(await me(t.key,{status:t.status==="dismissed"?"new":t.status}),P())},H=async t=>{if(S(t))return;B(o=>{if(!(t.key in o))return o;const d={...o};return delete d[t.key],d}),g(o=>o&&{...o,queue:o.queue.map(d=>d.key===t.key?{...d,kitStatus:"building",kitStatusAt:Date.now()}:d)});const r=await rs(t.key);if((r==null?void 0:r.error)==="local-model-selected"){let o=null;try{o=await ms(t,{profile:i,user:l})}catch{}ke(o)?await me(t.key,{kit:o}).catch(()=>null)||B(f=>({...f,[t.key]:"Built locally, but could not save the kit - try again."})):B(d=>({...d,[t.key]:"Your local model did not return a usable kit - check AI settings and retry."}))}else if(r&&r.error){const o=r.error==="no-server-llm"?"Server AI is off - open Nyanza â Jobs to build this.":r.error;B(d=>({...d,[t.key]:o}))}else r===null&&B(o=>({...o,[t.key]:"Network hiccup - try again."}));P()},T=t=>H(t),[I,Z]=p.useState(!1),[xe,ie]=p.useState(""),ve=async(t,r=null)=>{var ue,de,pe,he;if(!_e(t,i))return{ok:!1};const o=r!=null&&Object.prototype.hasOwnProperty.call(r,"applicationContext")&&r.applicationContext!==void 0;if(o&&r.applicationContext!==null&&!fe((ue=r.applicationContext)==null?void 0:ue.jurisdiction))return{ok:!1,error:"Choose a valid application country and try again."};const d=fe((de=r==null?void 0:r.applicationContext)==null?void 0:de.jurisdiction)?r.applicationContext.jurisdiction:"",f=d?{jurisdiction:d}:null,oe=(r==null?void 0:r.grantRelocation)===!0,Te=["yes","no"].includes(r==null?void 0:r.relocationChoice)?r.relocationChoice:"";let Q=!1;if(oe)try{const v=await Ps({item:t,relocate:Te,jurisdiction:d});A({status:"ready",document:v.applicationStandingAuthority}),Q=!0}catch(v){return{ok:!1,error:(v==null?void 0:v.message)||"Could not save relocation permission. Review the current setting and try again."}}const le={revision:t.kitRevision,contentHash:t.kitContentHash,...o?{applicationContext:f}:{}},U=await me(t.key,{reviewKit:le});if(!(U!=null&&U.queue))return await P(),{ok:!1,error:Q?"Relocation permission was saved, but this kit changed before approval. Review the latest revision and approve it again.":void 0};let X=U.queue;const ce=X.find(v=>v.key===t.key),Ne=(j==null?void 0:j.config)||{};if(ce&&Ne.autonomy==="full"){let v=0;try{v=Math.round(((he=(pe=is({profile:i,model:bs()}))==null?void 0:pe.coverage)==null?void 0:he.identity)??0)}catch{}if(ps({job:ce,profile:i,config:Ne,confidence:gs(),coverage:v,calibration:ls((y==null?void 0:y.records)||[]),trust:os(ce,m==null?void 0:m.cells)}).tier==="full"){const x=await me(t.key,{autoApprove:!0});x!=null&&x.queue&&(X=x.queue)}}return g(v=>v?{...v,queue:X}:{queue:X}),{ok:!0}},b=async t=>{try{const r=await Ks(t);return A({status:"ready",document:r}),{ok:!0}}catch(r){return r!=null&&r.applicationStandingAuthority&&A({status:"ready",document:r.applicationStandingAuthority}),{ok:!1,error:(r==null?void 0:r.message)||"Could not revoke relocation permission. Try again."}}};return e.jsxs("div",{className:"kl",children:[e.jsx(ks,{}),e.jsxs("main",{className:"kl-main",children:[e.jsx(ys,{}),e.jsx(cs,{}),e.jsxs(As.div,{className:"kl-intro",initial:n?{opacity:0}
14:{opacity:0,y:16},animate:{opacity:1,y:0},transition:{duration:n?0:.5},children:[e.jsx("h1",{className:"kl-h1",children:"Application kits"}),e.jsx("p",{className:"kl-sub",children:"Review role-specific resumes, cover letters, and grounded answer drafts prepared for roles in your queue."})]}),!C&&e.jsx("div",{role:"status","aria-label":"Loading your kits",children:e.jsx(fs,{variant:"card",count:3})}),K.length>0&&e.jsxs("section",{className:"kl-section","aria-label":"Preparing",children:[e.jsxs("h2",{className:"kl-h2",children:["Preparing ",e.jsx("span",{className:"kl-count",children:K.length})]}),e.jsx("ul",{className:"kl-list",children:K.map(t=>{const r=Ds(t),o=ee[t.key];return e.jsxs("li",{className:`kl-card kl-card-building${r||o?" kl-card-stuck":""}`,children:[e.jsx(Ae,{score:t.fit}),e.jsxs("div",{className:"kl-body",children:[e.jsx("span",{className:"kl-title","aria-disabled":S(t)?"true":void 0,children:t.title}),e.jsxs("div",{className:"kl-meta",children:[e.jsx(we,{company:t.company,size:15,className:"colo-in"}),t.company||"Company n/a"," · ",r||o?e.jsxs("span",{className:"kl-stuck",children:[e.jsx(h,{name:"warn",size:12})," ",o||"Taking longer than usual"]}):e.jsxs("span",{className:"kl-preparing",children:[e.jsx("span",{className:"kl-spin"})," preparing kit..."]})]}),!r&&!o&&(()=>{const d=Rs(t.kit);return e.jsx(Cs,{label:`Kit progress for ${t.title||"this role"}`,steps:d.steps,activeIndex:d.activeIndex})})()]}),J(t)&&e.jsx("p",{className:"kl-state-reason",role:"status",children:J(t)}),(r||o)&&!S(t)&&e.jsx("div",{className:"kl-actions",children:e.jsxs("button",{type:"button",className:"btn btn-ghost btn-sm",onClick:()=>T(t),children:[e.jsx(h,{name:"refresh",size:13})," Retry"]})})]},t.key)})}),e.jsx("p",{className:"kl-note",children:"Builds run on Nyanza's servers now - you can leave this page and they'll keep going."})]}),G.length>0&&e.jsxs("section",{className:"kl-section","aria-label":"Failed builds",children:[e.jsxs("h2",{className:"kl-h2",children:["Build failed ",e.jsx("span",{className:"kl-count",children:G.length})]}),e.jsx("ul",{className:"kl-list",children:G.map(t=>e.jsxs("li",{className:"kl-card kl-card-stuck",children:[e.jsx(Ae,{score:t.fit}),e.jsxs("div",{className:"kl-body",children:[e.jsx("span",{className:"kl-title","aria-disabled":S(t)?"true":void 0,children:t.title}),e.jsxs("div",{className:"kl-meta",children:[e.jsx(we,{company:t.company,size:15,className:"colo-in"}),t.company||"Company n/a"," · ",e.jsxs("span",{className:"kl-stuck",children:[e.jsx(h,{name:"warn",size:12})," ",t.kitFailWhy||"the build failed"]})]}),J(t)&&e.jsx("p",{className:"kl-state-reason",role:"status",children:J(t)})]}),!S(t)&&e.jsxs("div",{className:"kl-actions",children:[e.jsxs("button",{className:"btn btn-primary btn-sm",onClick:()=>T(t),children:[e.jsx(h,{name:"refresh",size:13})," Retry build"]}),e.jsx("button",{className:"btn btn-ghost btn-sm",onClick:()=>F(t),children:"Remove"})]})]},t.key))})]}),L.length>0&&e.jsxs("section",{className:"kl-section","aria-label":"Application kits",children:[e.jsxs("h2",{className:"kl-h2",children:["Application kits ",e.jsx("span",{className:"kl-count",children:L.length})]}),(()=>{const t=L.filter(r=>_e(r,i));return t.length<2?null:e.jsxs("details",{className:"kl-batch",children:[e.jsxs("summary",{children:[t.length," kits await your review - see the list and approve together"]}),e.jsx("ul",{className:"kl-batch-list",children:t.map(r=>{var o,d,f;return e.jsxs("li",{children:[e.jsx("strong",{children:r.title})," · ",r.company||"Company not stated",e.jsx("span",{className:"kl-batch-meta",children:[(o=r.kit)!=null&&o.coverLetter?"cover letter":"",Array.isArray((d=r.kit)==null?void 0:d.appAnswers)&&r.kit.appAnswers.length?`${r.kit.appAnswers.length} answers`:"",(f=r.kit)!=null&&f.tailoredResume?"tailored resume":""].filter(Boolean).join(" · ")||"kit contents in the card below"})]},r.key)})}),e.jsx("button",{type:"button",className:"btn btn-primary btn-sm",disabled:I,onClick:async()=>{var o;Z(!0),ie("");let r=0;for(const d of t)(o=await ve(d))!=null&&o.ok&&(r+=1);ie(`${r} of ${t.length} approved${r<t.length?" - the rest changed since this list rendered; review them individually below":""}`),Z(!1)},children:I?"Approvingâ¦":`Approve these ${t.length} kits`}),xe&&e.jsx("p",{className:"kl-batch-result",role:"status",children:xe})]})})(),e.jsx("ul",{className:"kl-list",children:L.map(t=>e.jsx(Us,{item:t,profile:i,lineage:u,onFinish:H,onApprove:ve,onDelete:F,focused:t.key===a,standingAuthorityView:q,onRevokeRelocationAuthority:b,onOpenPosting:re,handoffBusy:V===t.key,handoffError:ge[t.key]||""},t.key))})]}),R.length>0&&e.jsxs("section",{className:"kl-section","aria-label":"No kit yet",children:[e.jsxs("h2",{className:"kl-h2",children:["Queued roles ",e.jsx("span",{className:"kl-count",children:R.length})]}),e.jsx("p",{className:"kl-sub-sm",children:"Roles in your queue without a kit yet - prepare one in a click."}),w.size>0&&e.jsxs("div",{className:"ja-bulkbar",role:"toolbar","aria-label":"Bulk actions",children:[e.jsxs("strong",{children:[w.size," selected"]}),e.jsxs("button",{type:"button",className:"btn btn-primary btn-sm",onClick:ne,children:[e.jsx(h,{name:"spark",size:13})," Build ",w.size," kit",w.size===1?"":"s"]}),e.jsx("button",{type:"button",className:"ja-bulkclear",onClick:()=>W(new Set),children:"Clear"})]}),e.jsx("ul",{className:"kl-list",children:(E?R:R.slice(0,12)).map(t=>e.jsxs("li",{className:`kl-card kl-card-empty${w.has(t.key)?" is-sel":""}`,children:[e.jsx("input",{type:"checkbox",className:"ja-sel",checked:w.has(t.key),disabled:S(t),onChange:()=>Y(t),"aria-label":`Select ${t.title}`}),e.jsx(Ae,{score:t.fit}),e.jsxs("div",{className:"kl-body",children:[e.jsx("span",{className:"kl-title","aria-disabled":S(t)?"true":void 0,children:t.title}
14),e.jsxs("div",{className:"kl-meta",children:[e.jsx(we,{company:t.company,size:15,className:"colo-in"}),t.company||"Company n/a",t.location?` · ${t.location}`:""]}),J(t)&&e.jsx("p",{className:"kl-state-reason",role:"status",children:J(t)})]}),e.jsx("div",{className:"kl-actions",children:!S(t)&&e.jsxs("button",{className:"btn btn-primary btn-sm",onClick:()=>H(t),children:[e.jsx(h,{name:"spark",size:13})," Build kit"]})})]},t.key))}),R.length>12&&!E&&e.jsxs("button",{type:"button",className:"ja-showall",onClick:()=>te(!0),children:["Show all ",R.length]})]}),D&&e.jsxs("div",{className:"trk-undo",role:"status",children:[e.jsxs("span",{children:["Removed",D.company?` - ${D.company}`:""]}),e.jsx("button",{className:"btn btn-ghost btn-sm",onClick:z,children:"Undo"})]}),C&&L.length===0&&K.length===0&&R.length===0&&G.length===0&&e.jsx(Fs,{})]})]})}export{Us as KitCard,Fs as KitLibraryEmptyState,bt as default,_s as kitQualitySignals,_e as kitReviewEligible,Pe as kitSourcePinsCurrent,S as kitSubmissionActionLocked,J as kitSubmissionNotice,Be as resumeArtifactCurrent,$s as roleOverlapSignal};
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.