PageSourceSearch

https://salesindex.ai/assets/PackageCheckout-a_ztlqHD.js

js salesindex.ai collected 2026-10-05 13:06:36 UTC 18,301 bytes, 16 lines download raw bytes

1import{c as q,j as e,b as A,C as E,s as Y,r as p,L as h,B as y,F as _,I as b,e as f}from"./index-DXRSXi55.js";import{L as u}from"./label-CQoZlVBp.js";import{L as O,S as D,a as G}from"./StripeBankInput-DFwhQuVM.js";import{C as w}from"./credit-card-DfagACuV.js";import{G as H}from"./gift-gbXA4r9q.js";import{B as N}from"./briefcase-WdbuIgTq.js";import{T as L}from"./target-CF2_fWoK.js";import{R as z}from"./roleOptions-Cvp5vyJP.js";import{A as k}from"./arrow-left-DEmhoAGQ.js";import{C as U}from"./circle-check-big-QEeFMfiS.js";import{S as $}from"./shield-check-D7ZFsrVJ.js";import{L as Q}from"./loader-circle-B9bvuObw.js";/**
2 * @license lucide-react v0.475.0 - ISC
3 *
4 * This source code is licensed under the ISC license.
5 * See the LICENSE file in the root directory of this source tree.
6 */const W=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]],J=q("Info",W);/**
7 * @license lucide-react v0.475.0 - ISC
8 *
9 * This source code is licensed under the ISC license.
10 * See the LICENSE file in the root directory of this source tree.
11 */const K=[["path",{d:"m17 2 4 4-4 4",key:"nntrym"}],["path",{d:"M3 11v-1a4 4 0 0 1 4-4h14",key:"84bu3i"}],["path",{d:"m7 22-4-4 4-4",key:"1wqhfi"}],["path",{d:"M21 13v1a4 4 0 0 1-4 4H3",key:"1rx37r"}]],V=q("Repeat",K),X={"index-assessment":{icon:L,color:"bg-blue-100 text-blue-700",description:"Comprehensive evaluation measuring Skillset, Mindset, and Heartset for each team member. Creates a personalized development plan benchmarked against 2.5M+ salespeople."},"train-reps":{icon:E,color:"bg-purple-100 text-purple-700",description:"Daily 10–15 minute personalized micro-lessons delivered to each rep based on their SalesIndex results. Builds skills through daily reinforcement, not one-time events."},"train-coaching":{icon:A,color:"bg-emerald-100 text-emerald-700",description:"Bi-monthly dedicated coaching for your sales managers — weekly manager recaps, coaching frameworks, and accountability tools to reinforce rep development in the field."},"hire-1":{icon:N,color:"bg-amber-100 text-amber-700",description:"Unlimited candidate assessments and job board posting for 1 open sales role. Screen every candidate with data before you interview."},"hire-3":{icon:N,color:"bg-amber-100 text-amber-700",description:"Unlimited candidate assessments and job board posting for up to 3 open sales roles. Screen every candidate with data before you interview."},"hire-fee":{icon:N,color:"bg-amber-100 text-amber-700",description:"A full candidate report with every hire so you know exactly who can sell."}};function Z(n){return n.id==="index-assessment"&&n.qty>1?`${n.qty} people`:n.id==="train-reps"&&n.displayQty?`${n.displayQty} reps`:n.id==="train-coaching"&&n.qty>1?`${n.qty} managers`:null}function M({item:n}){const i=X[n.id]||{},t=i.icon||L,o=n.qty||1,m=n.price*o,x=Z(n);return e.jsx("div",{className:"bg-white rounded-xl border border-gray-200 p-5",children:e.jsxs("div",{className:"flex items-start gap-4",children:[e.jsx("div",{className:`w-10 h-10 rounded-lg flex items-center justify-center flex-shrink-0 ${i.color||"bg-gray-100 text-gray-600"}`,children:e.jsx(t,{className:"w-5 h-5"})}),e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsxs("div",{className:"flex items-start justify-between gap-4",children:[e.jsxs("div",{children:[e.jsx("h4",{className:"font-bold text-gray-900",children:n.name}),x&&e.jsx("span",{className:"text-xs font-medium text-blue-600 bg-blue-50 px-2 py-0.5 rounded-full",children:x})]}),e.jsx("div",{className:"text-right flex-shrink-0",children:n.isFree?e.jsxs("div",{children:[e.jsxs("span",{className:"text-gray-400 line-through text-xs block",children:["$",m.toLocaleString()]}),e.jsx("span",{className:"font-bold text-green-600",children:"FREE"})]}):e.jsxs("span",{className:"font-bold text-gray-900 text-lg",children:["$",m.toLocaleString()]})})]}),e.jsx("p",{className:"text-sm text-gray-500 mt-2 leading-relaxed",children:i.description})]})]})})}function ee({items:n}){const i=n.filter(r=>r.billingType==="monthly"),t=n.filter(r=>r.billingType==="one_time"),o=i.reduce((r,l)=>l.isFree?r:r+l.price*(l.qty||1),0),m=t.reduce((r,l)=>l.isFree?r:r+l.price*(l.qty||1),0),x=t.reduce((r,l)=>l.isFree?r+l.price*(l.qty||1):r,0);return e.jsxs("div",{className:"space-y-8",children:[i.length>0&&e.jsxs("div",{children:[e.jsxs("div",{className:"flex items-center gap-2 mb-3",children:[e.jsx(V,{className:"w-4 h-4 text-blue-600"}),e.jsx("h3",{className:"text-sm font-bold text-blue-700 uppercase tracking-wide",children:"Monthly Services"})]}),e.jsx("div",{className:"space-y-3",children:i.map(r=>e.jsx(M,{item:r},r.id))}),e.jsxs("div",{className:"mt-3 bg-blue-50 rounded-lg border border-blue-100 px-4 py-3 flex items-center justify-between",children:[e.jsx("span",{className:"text-sm font-semibold text-blue-800",children:"Monthly Total"}),e.jsxs("span",{className:"text-xl font-extrabold text-blue-900",children:["$",o.toLocaleStr
11ing(),e.jsx("span",{className:"text-sm font-medium text-blue-600",children:"/mo"})]})]})]}),t.length>0&&e.jsxs("div",{children:[e.jsxs("div",{className:"flex items-center gap-2 mb-3",children:[e.jsx(w,{className:"w-4 h-4 text-gray-600"}),e.jsx("h3",{className:"text-sm font-bold text-gray-600 uppercase tracking-wide",children:"One-Time Charges"})]}),e.jsx("div",{className:"space-y-3",children:t.map(r=>e.jsx(M,{item:r},r.id))}),x>0&&e.jsxs("div",{className:"mt-3 bg-green-50 rounded-lg border-2 border-green-200 px-4 py-3 flex items-start gap-3",children:[e.jsx(H,{className:"w-5 h-5 text-green-600 flex-shrink-0 mt-0.5"}),e.jsxs("div",{children:[e.jsx("p",{className:"text-sm font-bold text-green-800",children:"12-Month Commitment Savings"}),e.jsxs("p",{className:"text-xs text-green-700 mt-0.5",children:["You're saving ",e.jsxs("strong",{children:["$",x.toLocaleString()]})," in one-time fees because of your 12-month training commitment."]})]})]}),e.jsxs("div",{className:"mt-3 bg-gray-100 rounded-lg border border-gray-200 px-4 py-3 flex items-center justify-between",children:[e.jsx("span",{className:"text-sm font-semibold text-gray-700",children:"One-Time Total"}),e.jsxs("span",{className:"text-xl font-extrabold text-gray-900",children:["$",m.toLocaleString()]})]})]}),e.jsx("div",{className:"bg-[#0B1E3D] rounded-xl p-5 text-white",children:e.jsxs("div",{className:"space-y-2",children:[o>0&&e.jsxs("div",{className:"flex justify-between items-center",children:[e.jsx("span",{className:"text-blue-200 font-medium",children:"Ongoing Monthly"}),e.jsxs("span",{className:"text-2xl font-extrabold",children:["$",o.toLocaleString(),e.jsx("span",{className:"text-sm font-medium text-blue-200",children:"/mo"})]})]}),(m>0||x>0)&&e.jsxs("div",{className:"flex justify-between items-center",children:[e.jsx("span",{className:"text-blue-200 font-medium",children:"Due Today (one-time)"}),e.jsxs("span",{className:"text-2xl font-extrabold",children:["$",m.toLocaleString()]})]})]})})]})}function he(){var T;const i=((T=Y().state)==null?void 0:T.items)||[],[t,o]=p.useState({name:"",email:"",phone:"",company:"",role:"",title:"",paymentMethod:"credit_card"}),[m,x]=p.useState(!1),[r,l]=p.useState(!1),[I,P]=p.useState(!1),j=p.useRef(null),v=p.useRef(null),C=i.reduce((s,a)=>a.billingType==="monthly"&&!a.isFree?s+a.price*(a.qty||1):s,0),S=i.reduce((s,a)=>a.billingType==="one_time"&&!a.isFree?s+a.price*(a.qty||1):s,0),B={credit_card:"Credit Card",ach:"ACH (2% discount)",check:"Check (invoiced quarterly)"},F=()=>{let a=i.map(c=>`• ${c.name}${c.qty>1?` ×${c.qty}`:""} — $${(c.price*(c.qty||1)).toLocaleString()}${c.billingType==="monthly"?"/mo":""}`).join(`
12`);return C>0&&(a+=`
13
14Monthly Total: $${C.toLocaleString()}/mo`),S>0&&(a+=`
15One-Time Total: $${S.toLocaleString()}`),t.paymentMethod&&(a+=`
16Payment Method: ${B[t.paymentMethod]}`),a},R=async s=>{s.preventDefault(),l(!0);const a=F();if(t.paymentMethod==="credit_card"){if(!j.current){l(!1);return}const c=await j.current();if(!c){l(!1);return}const g=await f.functions.invoke("createPackageCheckout",{items:i.map(d=>({name:d.name,price:d.price,qty:d.qty||1,billingType:d.billingType,isFree:d.isFree})),customer_name:t.name,customer_email:t.email,customer_phone:t.phone,company:t.company,role:t.role,title:t.title,payment_method_id:c,payment_method_type:"card"});if(g.data.error){alert(g.data.error),l(!1);return}}else if(t.paymentMethod==="ach"){if(!v.current){l(!1);return}const c=await v.current();if(!c){l(!1);return}const g=await f.functions.invoke("createPackageCheckout",{items:i.map(d=>({name:d.name,price:d.price,qty:d.qty||1,billingType:d.billingType,isFree:d.isFree})),customer_name:t.name,customer_email:t.email,customer_phone:t.phone,company:t.company,role:t.role,title:t.title,payment_method_id:c,payment_method_type:"us_bank_account"});if(g.data.error){alert(g.data.error),l(!1);return}}else await f.entities.CompanyLead.create({contact_name:t.name,email:t.email,phone:t.phone,company_name:t.company||"Unknown",source:"Package Builder - Check",main_challenge:a,status:"New"}),await f.integrations.Core.SendEmail({to:"[email protected]",subject:`Checkout Request (Check): ${t.name}`,body:`<h2>Checkout Request</h2><p><strong>Name:</strong> ${t.name}</p><p><strong>Email:</strong> ${t.email}</p><p><strong>Phone:</strong> ${t.phone||"N/A"}</p><p><strong>Company:</strong> ${t.company||"N/A"}</p><h3>Package:</h3><pre>${a}</pre>`});l(!1),P(!0)};return i.length===0?e.jsx("div",{className:"min-h-screen bg-gray-50 flex items-center justify-center px-6",children:e.jsxs("div",{className:"text-center",children:[e.jsx("h2",{className:"text-2xl font-bold text-gray-900 mb-3",children:"No package selected"}),e.jsx("p",{className:"text-gray-500 mb-6",children:"Go back to the Package Builder to configure your plan."}),e.jsx(h,{to:"/PackageBuilder",children:e.jsxs(y,{className:"bg-blue-600 hover:bg-blue-700 text-white font-semibold",children:[e.jsx(k,{className:"w-4 h-4 mr-2"})," Back to Package Builder"]})})]})}):I?e.jsx("div",{className:"min-h-screen bg-gray-50 flex items-center justify-center px-6 py-16",children:e.jsxs("div",{className:"max-w-lg w-full text-center",children:[e.jsx("div",{className:"w-16 h-16 rounded-full bg-green-100 flex items-center justify-center mx-auto mb-5",children:e.jsx(U,{className:"w-8 h-8 text-green-600"})}),e.jsx("h2",{className:"text-3xl font-extrabold text-gray-900 mb-3",children:"You're All Set!"}),e.jsx("p",{className:"text-gray-600 mb-10",children:t.paymentMethod==="check"?"We'll send you an invoice shortly. Thank y
16ou for choosing SalesIndex!":"Your payment is being processed. You'll receive a confirmation email shortly."}),e.jsxs("div",{className:"grid sm:grid-cols-3 gap-4 text-left mb-10",children:[e.jsxs("div",{className:"bg-white rounded-xl border border-gray-200 p-5",children:[e.jsx("div",{className:"w-9 h-9 rounded-lg bg-blue-100 flex items-center justify-center mb-3",children:e.jsx($,{className:"w-5 h-5 text-blue-600"})}),e.jsx("h3",{className:"font-bold text-gray-900 text-sm mb-1",children:"Confirmation Email"}),e.jsx("p",{className:"text-xs text-gray-500",children:"Check your inbox for a receipt and next steps from our team."})]}),e.jsxs("div",{className:"bg-white rounded-xl border border-gray-200 p-5",children:[e.jsx("div",{className:"w-9 h-9 rounded-lg bg-emerald-100 flex items-center justify-center mb-3",children:e.jsx(w,{className:"w-5 h-5 text-emerald-600"})}),e.jsx("h3",{className:"font-bold text-gray-900 text-sm mb-1",children:"Onboarding Call"}),e.jsx("p",{className:"text-xs text-gray-500",children:"We'll reach out within 1 business day to schedule your kickoff."})]}),e.jsxs("div",{className:"bg-white rounded-xl border border-gray-200 p-5",children:[e.jsx("div",{className:"w-9 h-9 rounded-lg bg-purple-100 flex items-center justify-center mb-3",children:e.jsx(_,{className:"w-5 h-5 text-purple-600"})}),e.jsx("h3",{className:"font-bold text-gray-900 text-sm mb-1",children:"Get Started"}),e.jsx("p",{className:"text-xs text-gray-500",children:"Your team assessments and training setup begin after onboarding."})]})]}),e.jsxs("div",{className:"flex flex-col sm:flex-row gap-3 justify-center",children:[e.jsx(h,{to:"/AccountDashboard",children:e.jsx(y,{className:"bg-[#0B1E3D] hover:bg-[#122B56] text-white font-semibold px-6",children:"Go to My Account"})}),e.jsx(h,{to:"/",children:e.jsx(y,{variant:"outline",className:"font-semibold px-6",children:"Back to Home"})})]})]})}):e.jsxs("div",{className:"min-h-screen bg-gray-50",children:[e.jsx("div",{className:"bg-white border-b border-gray-200 py-4 px-6",children:e.jsxs("div",{className:"max-w-7xl mx-auto flex items-center justify-between",children:[e.jsxs(h,{to:"/PackageBuilder",className:"flex items-center gap-2 text-gray-600 hover:text-gray-900 font-medium transition-colors",children:[e.jsx(k,{className:"w-4 h-4"})," Adjust Package"]}),e.jsxs("div",{className:"flex items-center gap-2 text-sm text-gray-500",children:[e.jsx($,{className:"w-4 h-4 text-green-600"}),e.jsx("span",{children:"Secure Checkout"})]})]})}),e.jsx("div",{className:"max-w-7xl mx-auto px-6 py-10",children:e.jsxs("div",{className:"grid lg:grid-cols-5 gap-10",children:[e.jsxs("div",{className:"lg:col-span-3",children:[e.jsx("h2",{className:"text-2xl font-bold text-gray-900 mb-2",children:"Your Package"}),e.jsx("p",{className:"text-sm text-gray-500 mb-6",children:"Review each service included in your custom SalesIndex package."}),e.jsx(ee,{items:i}),e.jsxs("div",{className:"mt-6 bg-blue-50 rounded-xl border border-blue-100 p-4 flex items-start gap-3",children:[e.jsx(J,{className:"w-5 h-5 text-blue-600 flex-shrink-0 mt-0.5"}),e.jsxs("div",{children:[e.jsx("p",{className:"text-sm font-semibold text-blue-900",children:"Flexible team sizing"}),e.jsx("p",{className:"text-sm text-blue-700",children:"You can add or remove reps from your program at any time with 30 days notice. Your monthly investment will adjust automatically as your team changes."})]})]}),e.jsx("div",{className:"mt-4",children:e.jsxs(h,{to:"/PackageBuilder",className:"inline-flex items-center gap-2 text-sm font-medium text-blue-600 hover:text-blue-700 transition-colors",children:[e.jsx(k,{className:"w-4 h-4"})," Go back and adjust quantities"]})})]}),e.jsx("div",{className:"lg:col-span-2",children:e.jsxs("div",{className:"bg-white rounded-2xl border border-gray-200 p-6 sticky top-24",children:[e.jsx("h2",{className:"text-xl font-bold text-gray-900 mb-5",children:"Complete Your Order"}),e.jsxs("form",{onSubmit:R,className:"space-y-4",children:[e.jsxs("div",{children:[e.jsx(u,{children:"Full Name *"}),e.jsx(b,{required:!0,value:t.name,onChange:s=>o(a=>({...a,name:s.target.value})),placeholder:"Your full name"})]}),e.jsxs("div",{children:[e.jsx(u,{children:"Email *"}),e.jsx(b,{required:!0,type:"email",value:t.email,onChange:s=>o(a=>({...a,email:s.target.value})),placeholder:"[email protected]"})]}),e.jsxs("div",{children:[e.jsx(u,{children:"Phone"}),e.jsx(b,{type:"tel",value:t.phone,onChange:s=>o(a=>({...a,phone:s.target.value})),placeholder:"(555) 123-4567"})]}),e.jsxs("div",{children:[e.jsx(u,{children:"Company"}),e.jsx(b,{value:t.company,onChange:s=>o(a=>({...a,company:s.target.value})),placeholder:"Company name"})]}),e.jsxs("div",{children:[e.jsx(u,{children:"Role *"}),e.jsxs("select",{required:!0,value:t.role,onChange:s=>o(a=>({...a,role:s.target.value})),className:"flex h-9 w-full rounded-md border border-input bg-background px-3 py-1 text-sm shadow-sm focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring",children:[e.jsx("option",{value:"",children:"Select your role"}),z.map(s=>e.jsx("option",{value:s,children:s},s))]})]}),e.jsxs("div",{children:[e.jsx(u,{children:"Title *"}),e.jsx(b,{required:!0,value:t.title,onChange:s=>o(a=>({...a,title:s.target.value})),placeholder:"Your job title"})]}),e.jsxs("div",{children:[e.jsx(u,{className:"mb-2 block",children:"Payment Method *"}),e.jsx("div",{className:"space-y-2",children:[{value:"credit_card",icon:w,label:"Credit Card",desc:"Pay by credit or debit card",color:"text-blue-700 bg-blue-100"},{value:"ach",icon:O,label:"ACH Bank Transfer",desc:"2% discount on all charges",color:"text-emerald-700 bg-emerald-100"},{value:"check",icon:_,label:"Check",desc:"Invoiced quarterly in advance",color:"text-amber-700 bg-amber-100"}].map(s=>e.jsxs("button",{type:"button",onClick:()=>o(a=>({...a,paymentMethod:s.value})),className:`w-full flex items-center gap-3 p-3 rounded-lg border-2 transition-all text-left ${t.paymentMethod===s.value?"border-blue-600 bg-blue-50/50":"border-gray-200 hover:border-gray-300"}`,children:[e.jsx("div",{className:`w-8 h-8 rounded-md flex items-center justify-center flex-shrink-0 ${s.color}`,children:e.jsx(s.icon,{className:"w-4 h-4"})}),e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("p",{className:"text-sm font-semibold text-gray-900",children:s.label}),e.jsx("p",{className:"text-xs text-gray-500",children:s.desc})]}),e.jsx("div",{className:`w-4 h-4 rounded-full border-2 flex-shrink-0 ${t.paymentMethod===s.value?"border-blue-600 bg-blue-600":"border-gray-300"}`,children:t.paymentMethod===s.value&&e.jsx("div",{className:"w-full h-full rounded-full flex items-center justify-center",children:e.jsx("div",{className:"w-1.5 h-1.5 bg-white rounded-full"})})})]},s.value))})]}),t.paymentMethod==="credit_card"&&e.jsx(D,{onPaymentMethod:j}),t.paymentMethod==="ach"&&e.jsx(G,{onPaymentMethod:v}),e.jsxs("label",{className:"flex items-start gap-3 pt-2 cursor-pointer",children:[e.jsx("input",{type:"checkbox",checked:m,onChange:s=>x(s.target.checked),required:!0,className:"mt-0.5 w-4 h-4 accent-blue-600 cursor-pointer flex-shrink-0"}),e.jsxs("span",{className:"text-xs text-gray-600 leading-relaxed",children:["I agree to the"," ",e.jsx(h,{to:"/terms",target:"_blank",className:"text-blue-600 hover:underline font-medium",children:"Terms and Conditions"})," ","and"," ",e.jsx(h,{to:"/privacy",target:"_blank",className:"text-blue-600 hover:underline font-medium",children:"Privacy Policy"}),"."]})]}),e.jsxs(y,{type:"submit",disabled:r||!m,className:"w-full bg-green-600 hover:bg-green-700 text-white h-12 font-bold text-base mt-2 disabled:opacity-50 disabled:cursor-not-allowed",children:[r?e.jsx(Q,{className:"w-4 h-4 animate-spin mr-2"}):null,"Submit Order"]})]})]})})]})})]})}export{he 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.