1import{P as H,F as x,L as v,A as z,a as E,b as r,T as c,B as g,c as b,d as w}from"./index-cUcxH2jJ.js";const R=12240,k=15840,h=1080,L="4F46E5",T="C8C8C8",f="141414",m="282828",u="646464";function _(e){return new r({spacing:{after:60},children:[new c({text:e||"",bold:!0,size:40,color:f,font:"Helvetica"})]})}function y(e){return e?new r({spacing:{after:80},children:[new c({text:e,size:20,color:u,font:"Helvetica"})]}):null}function j(e){var i,n,o,s,l;const t=[(i=e.contact)==null?void 0:i.email,(n=e.contact)==null?void 0:n.phone,(o=e.contact)==null?void 0:o.location,(s=e.contact)==null?void 0:s.linkedin,(l=e.contact)==null?void 0:l.website].filter(Boolean);return t.length===0?null:new r({spacing:{after:60},children:[new c({text:t.join(" | "),size:17,color:u,font:"Helvetica"})]})}function C(){return new r({spacing:{before:40,after:160},border:{bottom:{style:g.SINGLE,size:8,color:L,space:1}},children:[]})}function p(e){return new r({spacing:{before:200,after:60},border:{bottom:{style:g.SINGLE,size:4,color:T,space:2}},children:[new c({text:e.toUpperCase(),bold:!0,size:20,color:f,font:"Helvetica"})]})}function S(e){return e?[p("Professional Summary"),new r({spacing:{after:120,line:280},children:[new c({text:e,size:18,color:m,font:"Helvetica"})]})]:[]}function P(e){var i,n;if(!((i=e.experience)!=null&&i.length))return[];const t=[p("Experience")];for(const o of e.experience){const s=[o.start_date,o.end_date||(o.is_current?"Present":"")].filter(Boolean).join(" - ");t.push(new r({spacing:{before:80,after:20},tabStops:[{type:b.RIGHT,position:w.MAX}],children:[new c({text:o.title||"",bold:!0,size:20,color:f,font:"Helvetica"}),...s?[new c({text:" "+s,size:17,color:u,font:"Helvetica"})]:[]]}));const l=[o.company,o.location].filter(Boolean).join(" | ");if(l&&t.push(new r({spacing:{after:40},children:[new c({text:l,italics:!0,size:18,color:"3C3C3C",font:"Helvetica"})]})),(n=o.bullets)!=null&&n.length)for(const a of o.bullets){const d=(a||"").trim();d&&t.push(new r({numbering:{reference:"resume-bullets",level:0},spacing:{after:20,line:260},children:[new c({text:d,size:18,color:m,font:"Helvetica"})]}))}}return t}function A(e){var i;if(!((i=e.education)!=null&&i.length))return[];const t=[p("Education")];for(const n of e.education){const o=[n.degree,n.field].filter(Boolean).join(", "),s=n.end_date||n.start_date||"";t.push(new r({spacing:{before:60,after:20},tabStops:[{type:b.RIGHT,position:w.MAX}],children:[new c({text:o,bold:!0,size:20,color:f,font:"Helvetica"}),...s?[new c({text:" "+s,size:17,color:u,font:"Helvetica"})]:[]]})),n.institution&&t.push(new r({spacing:{after:30},children:[new c({text:n.institution,italics:!0,size:18,color:"3C3C3C",font:"Helvetica"})]}));const l=[n.gpa?`GPA: ${n.gpa}`:null,n.honors||null].filter(Boolean);l.length&&t.push(new r({spacing:{after:60},children:[new c({text:l.join(" | "),size:17,color:u,font:"Helvetica"})]}))}return t}function G(e){const t=e.skills;if(!t)return[];const i=[{label:"Technical",items:t.technical},{label:"Leadership & Soft",items:t.soft},{label:"Languages",items:t.languages},{label:"Certifications",items:t.certifications}].filter(o=>{var s;return(s=o.items)==null?void 0:s.length});if(i.length===0)return[];const n=[p("Skills")];for(const o of i)n.push(new r({spacing:{after:40,line:260},children:[new c({text:`${o.label}: `,bold:!0,size:18,color:f,font:"Helvetica"}),new c({text:o.items.join(", "),size:18,color:m,font:"Helvetica"})]}));return n}function B(e){var i,n;if(!((i=e.projects)!=null&&i.length))return[];const t=[p("Projects")];for(const o of e.projects)t.push(new r({spacing:{before:60,after:20},children:[new c({text:o.name||"",bold:!0,size:19,color:f,font:"Helvetica"})]})),(n=o.tech_stack)!=null&&n.length&&t.push(new r({spacing:{after:20},children:[new c({text:o.tech_stack.join(", "),italics:!0,size:17,color:u,font:"Helvetica"})]})),o.description&&t.push(new r({spacing:{after:60,line:260},children:[new c({text:o.description,size:18,color:m,font:"Helvetica"})]}));return t}function I(e){const t=[];t.push(_(e.name));const i=y(e.headline);i&&t.push(i);const n=j(e);return n&&t.push(n),t.push(C()),t.push(...S(e.summary)),t.push(...P(e)),t.push(...A(e)),t.push(...G(e)),t.push(...B(e)),new x({creator:"Quivrd",title:`${e.name||"Resume"} - Resume`,description:"Resume",styles:{default:{document:{run:{font:"Helvetica",size:18}}}},numbering:{config:[{reference:"resume-bullets",levels:[{level:0,format:v.BULLET,text:"â¢",alignment:z.LEFT,style:{paragraph:{indent:{left:360,hanging:220}}}}]}]},sections:[{properties:{page:{size:{width:R,height:k,orientation:E.PORTRAIT},margin:{top:h,right:h,bottom:h,left:h}}},children:t}]})}async function D(e,t){const i=I(e),n=await H.toBlob(i),o=(e.name||"resume").replace(/\s+/g,"_"),s=t||`${o}_Resume.docx`,l=URL.createObjectURL(n),a=document.createElement("a");a.href=l,a.download=s,document.body.appendChild(a),a.click(),document.body.removeChild(a),URL.revokeObjectURL(l)}export{D as exportResumeToDocx};
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.