1/*! For license information please see 6875.de517bac.chunk.js.LICENSE.txt */ 2"use strict";(globalThis.webpackChunkfrontend||=[]).push([[6875],{6875(e,t,s){s.r(t);var a=s(5043),r=s(7719),l=s(5692),d=s(7186),i=s(6898),n=s(3497),c=s(1419),o=s(8975),x=s(1079),m=s(7298),b=s(579);const h=()=>{const[e,t]=(0,a.useState)(null);if((0,a.useEffect)(()=>{x.FH.get("/client/dashboard").then(e=>t(e.data))},[]),!e)return(0,b.jsx)(m.Rh,{});const s=e.stats;return(0,b.jsxs)("div",{children:[(0,b.jsx)(m.zY,{title:"Welcome back",subtitle:"Overview of your active services, invoices, and open tickets."}),s.overdue_invoices>0&&(0,b.jsxs)("div",{className:"mb-6 rounded-2xl bg-red-50 border border-red-200 text-red-800 p-5 flex flex-col md:flex-row md:items-center gap-4","data-testid":"overdue-banner",children:[(0,b.jsx)(r.A,{className:"h-6 w-6 flex-shrink-0"}),(0,b.jsxs)("div",{className:"flex-1",children:[(0,b.jsxs)("div",{className:"font-extrabold",children:["You have ",s.overdue_invoices," overdue invoice",s.overdue_invoices>1?"s":""," - ",(0,x.TG)(s.overdue_total)]}),(0,b.jsx)("div",{className:"text-sm mt-1 opacity-90",children:"Please settle to avoid service interruption. Bank transfer + payment gateway options are available."})]}),(0,b.jsxs)(o.N_,{to:"/portal/client/invoices",className:m.tB,"data-testid":"overdue-view-btn",children:["View Invoices ",(0,b.jsx)(l.A,{className:"h-4 w-4"})]})]}),(0,b.jsxs)("div",{className:"grid sm:grid-cols-2 lg:grid-cols-4 gap-4",children:[(0,b.jsx)(m.hI,{label:"Active Services",value:s.active_services,testid:"stat-active-services",tone:"good"}),(0,b.jsx)(m.hI,{label:"Unpaid Invoices",value:s.unpaid_invoices,tone:s.unpaid_invoices?"warn":"default",testid:"stat-unpaid"}),(0,b.jsx)(m.hI,{label:"Overdue Invoices",value:s.overdue_invoices,tone:s.overdue_invoices?"danger":"default",testid:"stat-overdue"}),(0,b.jsx)(m.hI,{label:"Open Tickets",value:s.open_tickets,testid:"stat-tickets"})]}),(0,b.jsxs)("div",{className:"mt-6 grid md:grid-cols-2 gap-4",children:[(0,b.jsxs)(m.Zp,{className:"p-6",children:[(0,b.jsx)("h3",{className:"text-lg font-extrabold",children:"Quick actions"}),(0,b.jsx)("p",{className:"text-sm text-slate-500 mt-1",children:"Jump to the most common client tasks."}),(0,b.jsxs)("div",{className:"mt-5 grid grid-cols-2 gap-3",children:[(0,b.jsxs)(o.N_,{to:"/portal/client/order",className:m.tB,children:[(0,b.jsx)(c.A,{className:"h-4 w-4"})," Order"]}),(0,b.jsxs)(o.N_,{to:"/portal/client/invoices",className:m.zq,children:[(0,b.jsx)(i.A,{className:"h-4 w-4"})," Pay Invoice"]}),(0,b.jsxs)(o.N_,{to:"/portal/client/tickets",className:m.zq,children:[(0,b.jsx)(d.A,{className:"h-4 w-4"})," Open Ticket"]}),(0,b.jsxs)(o.N_,{to:"/portal/client/services",className:m.zq,children:[(0,b.jsx)(n.A,{className:"h-4 w-4"})," My Services"]})]})]}),(0,b.jsxs)(m.Zp,{className:"p-6",children:[(0,b.jsx)("h3",{className:"text-lg font-extrabold",children:"Need help?"}),(0,b.jsx)("p",{className:"text-sm text-slate-500 mt-1",children:"Our engineers are on-call 24/7 for outages, hardware issues, and configuration guidance."}),(0,b.jsxs)("div",{className:"mt-4 text-sm space-y-1.5",children:[(0,b.jsxs)("div",{children:[(0,b.jsx)("span",{className:"text-slate-500",children:"WhatsApp:"})," ",(0,b.jsx)("span",{className:"font-semibold",children:"+62 878-1239-7187"})]}),(0,b.jsxs)("div",{children:[(0,b.jsx)("span",{className:"text-slate-500",children:"Email:"})," ",(0,b.jsx)("span",{className:"font-semibold",children:"[email protected]"})]}),(0,b.jsxs)("div",{children:[(0,b.jsx)("span",{className:"text-slate-500",children:"SLA:"})," ",(0,b.jsx)("span",{className:"font-semibold",children:"99.5% uptime"})]})]})]})]})]})};s.d(t,["default",0,h])},7298(e,t,s){s(5043);var a=s(2024),r=s(579);const l=e=>{let{title:t,subtitle:s,actions:a}=e;return(0,r.jsxs)("div",{className:"flex flex-col md:flex-row md:items-end md:justify-between gap-4 mb-6",children:[(0,r.jsxs)("div",{children:[(0,r.jsx)("h1",{className:"text-2xl md:text-3xl font-extrabold text-[#0a2350] leading-tight",children:t}),s&&(0,r.jsx)("p",{className:"text-sm text-slate-500 mt-1.5 max-w-2xl",children:s})]}),a&&(0,r.jsx)("div",{className:"flex items-center gap-2 flex-wrap",children:a})]})};s.d(t,["Rh",0,e=>{let{label:t="Loading\u2026"}=e;return(0,r.jsxs)("div",{className:"flex items-center gap-2 text-sm text-slate-500 py-10 justify-center",children:[(0,r.jsx)(a.A,{className:"h-4 w-4 animate-spin"})," ",t]})},"Wh",0,e=>{let{status:t}=e;return(0,r.jsxs)("span",{className:`inline-flex items-center gap-1.5 px-2 py-0.5 rounded-full border text-[11px] font-bold uppercase tracking-wide ${{active:"bg-emerald-100 text-emerald-700 border-emerald-200",pending:"bg-amber-100 text-amber-800 border-amber-200",provisioning:"bg-blue-100 text-blue-700 border-blue-200",assigned:"bg-indigo-100 text-indigo-700 border-indigo-200",suspended:"bg-slate-200 text-slate-700 border-slate-300",terminated:"bg-slate-200 text-slate-500 border-slate-300",unpaid:"bg-amber-100 text-amber-800 border-amber-200",paid:"bg-emerald-100 text-emerald-700 border-emerald-200",overdue:"bg-red-100 text-red-700 border-red-200",cancelled:"bg-slate-200 text-slate-600 border-slate-300",open:"bg-blue-100 text-blue-700 border-blue-200",awaiting_client:"bg-amber-100 text-amber-800 border-amber-200",awaiting_staff:"bg-indigo-100 text-indigo-700 border-indigo-200",resolved:"bg-emerald-100 text-emerald-700 border-emerald-200",closed:"bg-slate-200 text-slate-600 border-slate-300",draft:"bg-slate-200 text-slate-700 border-slate-300",sent:"bg-blue-100 text-blue-700 border-blue-200",accepted:"bg-emerald-100 text-emerald-700 border-emerald-200",rejected:"bg-red-100 text-red-700 border-red-200",expired:"bg-slate-200 text-slate-600 border-slate-300",enabled:"bg-emerald-100 text-emerald-700 border-emerald-200",disabled:"bg-slate-200 text-slate-600 border-slate-300"}[t]||"bg-slate-200 text-slate-700 border-slate-300"}`,children:[(0,r.jsx)("span",{className:"h-1.5 w-1.5 rounded-full bg-current"}
2),String(t).replace(/_/g," ")]})},"Zp",0,e=>{let{children:t,className:s="",...a}=e;return(0,r.jsx)("div",{className:`bg-white border border-slate-200 rounded-2xl ${s}`,...a,children:t})},"dd",0,"text-xs font-bold uppercase tracking-widest text-slate-600","hI",0,e=>{let{label:t,value:s,hint:a,tone:l="default",testid:d}=e;const i={default:"border-slate-200",warn:"border-amber-200 bg-amber-50/60",danger:"border-red-200 bg-red-50/60",good:"border-emerald-200 bg-emerald-50/60"}[l];return(0,r.jsxs)("div",{className:`rounded-2xl bg-white border p-5 ${i}`,"data-testid":d,children:[(0,r.jsx)("div",{className:"text-[11px] font-bold uppercase tracking-widest text-slate-500",children:t}),(0,r.jsx)("div",{className:"mt-1 text-2xl font-extrabold text-[#0a2350]",children:s}),a&&(0,r.jsx)("div",{className:"mt-1 text-[11px] text-slate-500",children:a})]})},"i2",0,"inline-flex items-center gap-2 rounded-lg bg-red-600 hover:bg-red-700 text-white text-sm font-semibold px-4 h-10 transition-colors","pp",0,e=>{let{title:t="Nothing here yet",body:s}=e;return(0,r.jsxs)("div",{className:"text-center py-12",children:[(0,r.jsx)("div",{className:"text-lg font-extrabold text-[#0a2350]",children:t}),s&&(0,r.jsx)("p",{className:"mt-2 text-sm text-slate-500",children:s})]})},"tB",0,"inline-flex items-center gap-2 rounded-lg bg-[#0a2350] hover:bg-[#f5b120] hover:text-[#0a2350] text-white text-sm font-semibold px-4 h-10 transition-colors","vB",0,"w-full h-10 rounded-lg border border-slate-300 px-3 text-sm focus:outline-none focus:ring-2 focus:ring-[#f5b120] focus:border-[#f5b120]","zY",0,l,"zq",0,"inline-flex items-center gap-2 rounded-lg bg-white border border-slate-300 hover:border-[#f5b120] hover:text-[#0a2350] text-slate-700 text-sm font-semibold px-4 h-10 transition-colors"])},7186(e,t,s){const a=(0,s(7784).A)("life-buoy",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m4.93 4.93 4.24 4.24",key:"1ymg45"}],["path",{d:"m14.83 9.17 4.24-4.24",key:"1cb5xl"}],["path",{d:"m14.83 14.83 4.24 4.24",key:"q42g0n"}],["path",{d:"m9.17 14.83-4.24 4.24",key:"bqpfvv"}],["circle",{cx:"12",cy:"12",r:"4",key:"4exip2"}]]);s.d(t,["A",0,a])},6898(e,t,s){const a=(0,s(7784).A)("receipt",[["path",{d:"M4 2v20l2-1 2 1 2-1 2 1 2-1 2 1 2-1 2 1V2l-2 1-2-1-2 1-2-1-2 1-2-1-2 1Z",key:"q3az6g"}],["path",{d:"M16 8h-6a2 2 0 1 0 0 4h4a2 2 0 1 1 0 4H8",key:"1h4pet"}],["path",{d:"M12 17.5v-11",key:"1jc1ny"}]]);s.d(t,["A",0,a])},1419(e,t,s){const a=(0,s(7784).A)("shopping-cart",[["circle",{cx:"8",cy:"21",r:"1",key:"jimo8o"}],["circle",{cx:"19",cy:"21",r:"1",key:"13723u"}],["path",{d:"M2.05 2.05h2l2.66 12.42a2 2 0 0 0 2 1.58h9.78a2 2 0 0 0 1.95-1.57l1.65-7.43H5.12",key:"9zh506"}]]);s.d(t,["A",0,a])},7719(e,t,s){const a=(0,s(7784).A)("triangle-alert",[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3",key:"wmoenq"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]]);s.d(t,["A",0,a])}}]); 3//# sourceMappingURL=6875.de517bac.chunk.js.map
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.