1const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/index-Bog8-u9h.js","assets/react-vendor-Chy9GnhL.js","assets/lucide-B_T5Y-91.js","assets/firebase-firestore-CKxYsKIi.js","assets/firebase-services-Bh1yJIXm.js","assets/firebase-core-KbeG7V7x.js","assets/index-CB_x9a_y.css"])))=>i.map(i=>d[i]); 2import{u as _e,i as He,bJ as qe,bA as Me,bB as Ge,j as e,az as Ye,de as Ve,df as We,cn as Ke,dO as Se,dP as Xe,z as Je,dQ as Qe,_ as Ze,A as et,dR as tt}from"./index-Bog8-u9h.js";import{u as st,r as o,R as at}from"./react-vendor-Chy9GnhL.js";import{f as nt,p as rt}from"./xlsParser-Dl_jwmUK.js";import{k as he,i as se,L as de,j as ye,F as ke,s as te,I as pe,X as $e,f as ve,S as we,aR as Ce,D as ge,Z as be,$ as Ne,n as lt,y as it,b5 as ot,l as Ee,U as ct}from"./lucide-B_T5Y-91.js";import"./firebase-firestore-CKxYsKIi.js";import"./firebase-services-Bh1yJIXm.js";import"./firebase-core-KbeG7V7x.js";const dt=({step:r,communityName:d})=>{const c=["Upload Files","Review","Complete"];return e.jsx("div",{className:"bg-white border-b border-slate-200 px-6 py-4",children:e.jsxs("div",{className:"max-w-4xl mx-auto",children:[e.jsxs("div",{className:"flex items-center justify-between mb-4",children:[e.jsxs("div",{children:[e.jsxs("h1",{className:"text-lg font-bold text-slate-900",children:["Set Up ",d]}),e.jsx("p",{className:"text-xs text-slate-500",children:"Herald AI will configure your community"})]}),e.jsxs("div",{className:"flex items-center gap-1 text-xs text-slate-400",children:["Step ",r," of ",c.length]})]}),e.jsx("div",{className:"flex items-center gap-2",children:c.map((m,_)=>{const S=_+1,k=r===S,z=r>S;return e.jsxs(at.Fragment,{children:[_>0&&e.jsx("div",{className:`flex-1 h-0.5 ${z?"bg-emerald-500":"bg-slate-200"}`}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx("div",{className:`w-7 h-7 rounded-full flex items-center justify-center text-xs font-bold ${z?"bg-emerald-500 text-white":k?"bg-indigo-600 text-white":"bg-slate-200 text-slate-500"}`,children:z?e.jsx(he,{size:14}):S}),e.jsx("span",{className:`text-xs font-medium hidden sm:inline ${k?"text-indigo-600":z?"text-emerald-600":"text-slate-400"}`,children:m})]})]},m)})})]})})},mt=({files:r,phase:d,uploadIndex:c,analysisResult:m,onContinue:_})=>{const[S,k]=o.useState([]),[z,H]=o.useState([]),W=o.useRef(null),E=o.useRef(0),i=o.useRef(0);o.useEffect(()=>{if(d==="uploading"){const a=[];for(let u=0;u<=c&&u<r.length;u++){const N=r[u];u<c?a.push({id:i.current++,icon:"upload",text:`Uploaded ${N.file.name}`}):a.push({id:i.current++,icon:"upload",text:`Uploading ${N.file.name}...`})}k(a)}},[d,c,r]),o.useEffect(()=>{if(d==="analyzing"&&!m){const a=[...r.map(u=>({id:i.current++,icon:"upload",text:`Uploaded ${u.file.name}`})),{id:i.current++,icon:"search",text:""},{id:i.current++,icon:"search",text:"Herald is reading your files...",highlight:!0}];for(const u of r){const N=u.file.name.toLowerCase().split(".").pop();N==="csv"||N==="txt"||N==="xls"||N==="xlsx"?(a.push({id:i.current++,icon:"file",text:`Analyzing ${u.file.name}...`}),a.push({id:i.current++,icon:"property",text:"Mapping columns to property fields...",indent:!0})):N==="pdf"?(a.push({id:i.current++,icon:"file",text:`Reading ${u.file.name}...`}),a.push({id:i.current++,icon:"rule",text:"Extracting text and scanning for rules...",indent:!0})):a.push({id:i.current++,icon:"file",text:`Processing ${u.file.name}...`})}H(a),E.current=r.length,k(a.slice(0,r.length))}},[d,m,r]),o.useEffect(()=>{if(d==="analyzing"&&!m&&z.length>0){const a=setInterval(()=>{E.current++,E.current>=z.length?clearInterval(a):k(z.slice(0,E.current+1))},800);return()=>clearInterval(a)}},[d,m,z]),o.useEffect(()=>{if(d==="complete"&&m){const a=[{id:i.current++,icon:"search",text:""}];for(const g of m.results){if(g.status!=="success"){a.push({id:i.current++,icon:"error",text:`${g.fileName} â ${g.error||"failed"}`});continue}if(g.csvAnalysis){const I=g.csvAnalysis.summary;if(a.push({id:i.current++,icon:"file",text:`${g.fileName}`,highlight:!0}),a.push({id:i.current++,icon:"property",text:`Found ${I.validRows} properties with addresses`,indent:!0}),I.withBalances>0){const R=g.csvAnalysis.parsedProperties.reduce((U,q)=>U+(q.currentBalance||0),0);a.push({id:i.current++,icon:"dues",text:`${I.withBalances}
2 with outstanding balances ($${R.toLocaleString()})`,indent:!0})}for(const R of I.warnings||[])a.push({id:i.current++,icon:"error",text:R,indent:!0})}if(g.documentExtraction){a.push({id:i.current++,icon:"file",text:`${g.fileName}`,highlight:!0}),a.push({id:i.current++,icon:"search",text:`Classified as: ${g.documentExtraction.category}`,indent:!0});const I=(g.documentExtraction.extractedRules||[]).length;if(I>0){const R=[...new Set(g.documentExtraction.extractedRules.map(U=>U.category))].slice(0,4).join(", ");a.push({id:i.current++,icon:"rule",text:`Extracted ${I} violation rules (${R}...)`,indent:!0})}}g.budgetExtraction?.suggestedDuesAmount&&a.push({id:i.current++,icon:"dues",text:`Detected dues: $${g.budgetExtraction.suggestedDuesAmount}/${g.budgetExtraction.duesFrequency==="monthly"?"mo":"yr"}`,indent:!0}),g.budgetExtraction?.amenitiesDetected?.length&&a.push({id:i.current++,icon:"amenity",text:`Amenities: ${g.budgetExtraction.amenitiesDetected.join(", ")}`,indent:!0}),g.logoDetected&&a.push({id:i.current++,icon:"logo",text:"Community logo detected",indent:!0})}a.push({id:i.current++,icon:"search",text:""}),a.push({id:i.current++,icon:"done",text:"Analysis complete â ready for your review!",highlight:!0});let u=0;const N=S.filter(g=>g.icon!=="search"||g.text!==""),K=setInterval(()=>{u++,k([...N,...a.slice(0,u)]),u>=a.length&&clearInterval(K)},350);return()=>clearInterval(K)}},[d,m]),o.useEffect(()=>{W.current?.scrollIntoView({behavior:"smooth"})},[S]);const $=a=>{switch(a){case"upload":return e.jsx(ct,{size:14,className:"text-blue-400"});case"search":return e.jsx(se,{size:14,className:"text-indigo-400"});case"file":return e.jsx(te,{size:14,className:"text-amber-400"});case"property":return e.jsx(ve,{size:14,className:"text-emerald-400"});case"rule":return e.jsx(we,{size:14,className:"text-amber-400"});case"amenity":return e.jsx(Ce,{size:14,className:"text-green-400"});case"dues":return e.jsx(ge,{size:14,className:"text-emerald-400"});case"logo":return e.jsx(pe,{size:14,className:"text-blue-400"});case"done":return e.jsx(he,{size:14,className:"text-emerald-400"});case"error":return e.jsx(Ee,{size:14,className:"text-red-400"})}},v=d==="complete"&&S.some(a=>a.icon==="done");return e.jsxs("div",{className:"fixed inset-0 z-50 bg-slate-900/80 backdrop-blur-sm flex items-center justify-center p-4",children:[e.jsxs("div",{className:"bg-slate-900 border border-slate-700 rounded-2xl shadow-2xl w-full max-w-lg overflow-hidden",children:[e.jsxs("div",{className:"px-6 py-4 border-b border-slate-700 flex items-center gap-3",children:[e.jsx("div",{className:`w-10 h-10 rounded-full bg-gradient-to-br from-indigo-500 to-purple-600 flex items-center justify-center ${d!=="complete"?"animate-pulse":""}`,children:e.jsx(se,{size:20,className:"text-white"})}),e.jsxs("div",{children:[e.jsx("h3",{className:"text-sm font-bold text-white",children:d==="uploading"?"Uploading files...":d==="analyzing"&&!m?"Herald is analyzing...":"Analysis complete"}),e.jsx("p",{className:"text-xs text-slate-400",children:d==="uploading"?`${Math.min(c+1,r.length)} of ${r.length} files`:d==="analyzing"&&!m?"This may take a minute for large documents":`${r.length} files processed`})]})]}),e.jsxs("div",{className:"px-6 py-4 max-h-80 overflow-y-auto font-mono text-xs space-y-1.5",children:[S.map(a=>a.text?e.jsxs("div",{className:`flex items-start gap-2.5 animate-[fadeIn_0.3s_ease-out] ${a.indent?"ml-5":""}`,children:[e.jsx("span",{className:"mt-0.5 flex-shrink-0",children:$(a.icon)}),e.jsx("span",{className:a.highlight?"text-white font-semibold":a.indent?"text-slate-400":"text-slate-300",children:a.text})]},a.id):e.jsx("div",{className:"h-2"},a.id)),d!=="complete"&&e.jsxs("div",{className:"flex items-center gap-2.5 ml-0",children:[e.jsx(de,{size:14,className:"text-indigo-400 animate-spin"}),e.jsx("span",{className:"text-slate-500 animate-pulse",children:"..."})]}),e.jsx("div",{ref:W})]}),v&&e.jsx("div",{className:"px-6 py-4 border-t border-slate-700",children:e.jsxs("button",{onClick:_,className:"w-full py-2.5 hh-btn-quiet rounded-xl font-semibold text-sm transition-colors flex items-center justify-center gap-2",children:["Review Results",e.jsx(ye,{size:16})]})})]}),e.jsx("style",{children:` 3 @keyframes fadeIn { 4 from { opacity: 0; transform: translateY(4px); } 5 to { opacity: 1; transform: translateY(0); } 6 } 7 `})]})},xt=({files:r,setFiles:d,isProcessing:c,analysisResult:m,onProcess:_,onSkip:S,onContinue:k})=>{const z=o.useRef(null),H=o.useRef(null),W=o.useRef(null),[E,i]=o.useState(!1),[$,v]=o.useState(!1),a=n=>{const j=n.toLowerCase().split(".").pop()||"";return["csv","txt","xls","xlsx","xlsm","ods"].includes(j)?"spreadsheet":j==="pdf"||j==="doc"||j==="docx"?"document":["jpg","jpeg","png","webp","heic"].includes(j)?"image":null},u=(n,j)=>n.some(C=>a(C.file.name)===j),N=o.useCallback(n=>{d(j=>{const C=[];for(const M of Array.from(n)){const B=a(M.name);
7B&&(u(j,B)||u(C,B)||C.push({file:M,status:"pending",progress:0}))}return[...j,...C]})},[d]),K=n=>{d(j=>j.filter((C,M)=>M!==n))},g=o.useCallback(n=>{n.preventDefault(),i(!1),n.dataTransfer.files.length>0&&N(n.dataTransfer.files)},[N]),I=n=>{const j=n.toLowerCase().split(".").pop();return["csv","txt","xls","xlsx","xlsm","ods"].includes(j||"")?e.jsx(ke,{size:18,className:"text-emerald-500"}):j==="pdf"?e.jsx(te,{size:18,className:"text-red-500"}):["jpg","jpeg","png","webp","heic"].includes(j||"")?e.jsx(pe,{size:18,className:"text-blue-500"}):e.jsx(te,{size:18,className:"text-slate-400"})},R=n=>{switch(n.status){case"pending":return e.jsx("span",{className:"text-xs text-slate-400",children:"Ready"});case"uploading":return e.jsx(de,{size:14,className:"animate-spin text-blue-500"});case"processing":return e.jsx(de,{size:14,className:"animate-spin text-indigo-500"});case"done":return e.jsx(he,{size:14,className:"text-emerald-500"});case"error":return e.jsx(Ee,{size:14,className:"text-red-500"})}},U=r.length>0&&r.every(n=>n.status==="done"||n.status==="error"),q=r.some(n=>n.status==="done");return e.jsxs("div",{className:"max-w-2xl mx-auto px-4 py-8",children:[e.jsxs("div",{className:"flex items-start gap-4 mb-8",children:[e.jsx("div",{className:"w-12 h-12 rounded-full bg-gradient-to-br from-indigo-500 to-purple-600 flex items-center justify-center flex-shrink-0 shadow-lg shadow-indigo-500/30",children:e.jsx(se,{size:24,className:"text-white"})}),e.jsxs("div",{className:"bg-white rounded-2xl rounded-tl-sm border border-slate-200 p-4 shadow-sm flex-1",children:[e.jsxs("p",{className:"text-sm text-slate-700",children:[e.jsx("strong",{children:"Drop your community files and I'll set everything up."})," Upload one of each type below â I'll extract properties, rules, amenities, and dues automatically."]}),e.jsx("p",{className:"text-xs text-slate-400 mt-2",children:"You can upload additional documents later from the Documents tab in your admin dashboard."})]})]}),e.jsxs("div",{className:"space-y-3",children:[u(r,"spreadsheet")?null:e.jsxs("div",{onDragOver:n=>{n.preventDefault(),i(!0)},onDragLeave:()=>i(!1),onDrop:g,onClick:()=>{z.current?.click()},className:`border-2 border-dashed rounded-xl p-5 text-center cursor-pointer transition-all ${E?"border-emerald-400 bg-emerald-50":"border-slate-300 hover:border-emerald-400 hover:bg-slate-50"} ${c?"opacity-50 pointer-events-none":""}`,children:[e.jsxs("div",{className:"flex items-center justify-center gap-3",children:[e.jsx(ke,{size:22,className:"text-emerald-500"}),e.jsxs("div",{className:"text-left",children:[e.jsx("p",{className:"text-sm font-medium text-slate-700",children:"Property Roster"}),e.jsx("p",{className:"text-xs text-slate-400",children:"CSV, XLS, or XLSX â addresses, lots, balances"})]})]}),e.jsx("input",{ref:z,type:"file",accept:".csv,.xls,.xlsx,.xlsm,.ods,.txt",className:"hidden",onChange:n=>n.target.files&&N(n.target.files)})]}),u(r,"document")?null:e.jsxs("div",{onDragOver:n=>{n.preventDefault(),i(!0)},onDragLeave:()=>i(!1),onDrop:g,onClick:()=>{H.current?.click()},className:`border-2 border-dashed rounded-xl p-5 text-center cursor-pointer transition-all ${E?"border-red-300 bg-red-50":"border-slate-300 hover:border-red-300 hover:bg-slate-50"} ${c?"opacity-50 pointer-events-none":""}`,children:[e.jsxs("div",{className:"flex items-center justify-center gap-3",children:[e.jsx(te,{size:22,className:"text-red-500"}),e.jsxs("div",{className:"text-left",children:[e.jsx("p",{className:"text-sm font-medium text-slate-700",children:"Governing Documents"}),e.jsx("p",{className:"text-xs text-slate-400",children:"PDF or DOC â CC&Rs, bylaws, rules"})]})]}),e.jsx("p",{className:"text-[11px] text-slate-400 mt-2",children:"Have more than one document? No worries â you can upload additional CC&Rs, bylaws, and rules later in Settings > Library."}),e.jsx("input",{ref:H,type:"file",accept:".pdf,.doc,.docx",className:"hidden",onChange:n=>n.target.files&&N(n.target.files)})]}),u(r,"image")?null:e.jsxs("div",{onDragOver:n=>{n.preventDefault(),i(!0)},onDragLeave:()=>i(!1),onDrop:g,onClick:()=>{W.current?.click()},className:`border-2 border-dashed rounded-xl p-5 text-center cursor-pointer transition-all ${E?"border-blue-300 bg-blue-50":"border-slate-300 hover:border-blue-300 hover:bg-slate-50"} ${c?"opacity-50 pointer-events-none":""}`,children:[e.jsxs("div",{className:"flex items-center justify-center gap-3",children:[e.jsx(pe,{size:22,className:"text-blue-500"}),e.jsxs("div",{className:"text-left",children:[e.jsx("p",{className:"text-sm font-medium text-slate-700",children:"Community Logo"}),e.jsx("p",{className:"text-xs text-slate-400",children:"JPG or PNG â will be your HOA's default logo"})]})]}),e.jsx("input",{ref:W,type:"file",accept:".jpg,.jpeg,.png,.webp,.heic",className:"hidden",onChange:n=>n.target.files&&N(n.target.files)})]})]}),r.length>0&&e.jsx("div",{className:"mt-6 space-y-2",children:r.map((n,j)=>e.jsxs("div",{className:"flex items-center gap-3 bg-white rounded-xl border border-slate-200 px-4 py-3",children:[I(n.file.name),e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("p",{className:"text-sm font-medium text-slate-800 truncate",children:n.file.name}),e.jsxs("p",{className:"text-xs text-slate-400",children:[(n.file.size/1024).toFixed(0)," KB",a(n.file.name)==="image"&&e.jsx("span",{className:"text-blue-500 ml-1.5 font-medium",children:"⢠Community Logo"})]}),n.error&&e.jsx("p",{className:"text-xs text-red-500 mt-0.5",children:n.error})]}),R(n),n.status==="pending"&&!c&&e.jsx("button",{onClick:C=>{C.stopPropagation(),K(j)},className:"text-slate-400 hover:text-red-500",children:e.jsx($e,{size:16})})]},j))}),m&&q&&e.jsxs("div",{className:"mt-6 bg-emerald-50 border border-emerald-200 rounded-xl p-4",children:[e.jsxs("div",{className:"flex items-center gap-2 mb-2",children:[e.jsx(se,{size:16,className:"text-emerald-600"}),e.jsx("p",{className:"text-sm font-bold text-emerald-800",children:"Herald found:"})]}),e.jsxs("div",{className:"grid grid-cols-2 gap-2 text-xs text-emerald-700",children:[m.aggregated.totalProperties>0&&e.jsxs("div",{className:"flex items-center gap-1.5",children:[e.jsx(ve,{size:13}),m.aggregated.totalProperties," properties"]}),m.aggregated.documentsClassified>0&&e.jsxs("div",{className:"flex items-center gap-1.5",children:[e.jsx(te,{size:13}),m.aggregated.documentsClassified," documents"]}),m.aggregated.totalRulesExtracted>0&&e.jsxs("div",{className:"flex items-center gap-1.5",children:[e.jsx(we,{size:13}),m.aggregated.totalRulesExtracted," violation rules"]}),m.aggregated.amenitiesDetected.length>0&&e.jsxs("div",{className:"flex items-center gap-1.5",children:[e.jsx(Ce,{size:13}),m.aggregated.amenitiesDetected.length," amenities"]}),m.aggregated.suggestedDuesAmount&&e.jsxs("div",{className:"flex items-center gap-1.5",children:[e.jsx(ge,{size:13}),"$",m.aggregated.suggestedDuesAmount,"/",m.aggregated.suggestedDuesFrequency==="monthly"?"mo":"yr"," dues detected"]}),m.aggregated.hasLogo&&e.jsxs("div",{className:"flex items-center gap-1.5",children:[e.jsx(pe,{size:13}),"Logo detected"]})]})]}),e.jsxs("div",{className:"mt-8 flex items-center justify-between gap-4",children:[$?e.jsxs("div",{className:"flex items-center gap-3 flex-wrap",children:[e.jsx("span",{className:"text-xs text-slate-500 max-w-[260px]",children:"Start with an empty community? Boards that import their roster are up and running in minutes."}),e.jsx("button",{onClick:S,className:"text-sm text-slate-400 hover:text-slate-600 font-medium whitespace-nowrap",children:"Skip anyway"}),e.jsx("button",{onClick:()=>v(!1),className:"px-4 py-2 bg-indigo-600 text-white rounded-xl font-semibold text-sm hover:bg-indigo-700 transition-colors whitespace-nowrap",children:"Keep setting up"})]}):e.jsx("button",{onClick:()=>v(!0),className:"text-sm text-slate-500 hover:text-slate-700 font-medium",children:"Set up later"}),e.jsxs("div",{className:"flex gap-3",children:[r.length>0&&!U&&!c&&e.jsxs("button",{onClick:_,className:"px-6 py-2.5 bg-indigo-600 text-white rounded-xl font-semibold text-sm hover:bg-indigo-700 transition-colors flex items-center gap-2",children:[e.jsx(se,{size:16}),"Analyze Files"]}),c&&e.jsxs("button",{disabled:!0,className:"px-6 py-2.5 bg-indigo-400 text-white rounded-xl font-semibold text-sm flex items-center gap-2 cursor-not-allowed",children:[e.jsx(de,{size:16,className:"animate-spin"}),"Analyzing..."]}),U&&q&&e.jsxs("button",{onClick:k,className:"px-6 py-2.5 hh-btn-quiet rounded-xl font-semibold text-sm transition-colors flex items-center gap-2",children:["Review Results",e.jsx(ye,{size:16})]})]})]})]})},ut=({properties:r,setProperties:d,importReview:c,reviewLoading:m,onApplyFormatting:_,payments:S,expenses:k,includePayments:z,setIncludePayments:H,includeExpenses:W,setIncludeExpenses:E,documents:i,setDocuments:$,rules:v,setRules:a,amenities:u,setAmenities:N,duesAmount:K,setDuesAmount:g,duesFrequency:I,setDuesFrequency:R,onBack:U,onConfirm:q,isImporting:n,propertyLimit:j})=>
7{const[C,M]=o.useState("properties"),[B,Q]=o.useState(""),le=t=>M(x=>x===t?null:t),J=r.filter(t=>t.selected),fe=i.filter(t=>t.selected),ie=v.filter(t=>t.selected),me=J.reduce((t,x)=>t+(x.currentBalance||0),0),xe=r.length>0||i.length>0||v.length>0||u.length>0;return e.jsxs("div",{className:"max-w-3xl mx-auto px-4 py-8",children:[e.jsxs("div",{className:"flex items-start gap-4 mb-6",children:[e.jsx("div",{className:"w-10 h-10 rounded-full bg-gradient-to-br from-indigo-500 to-purple-600 flex items-center justify-center flex-shrink-0",children:e.jsx(se,{size:20,className:"text-white"})}),e.jsxs("div",{children:[e.jsx("h2",{className:"text-lg font-bold text-slate-900",children:"Review What Herald Found"}),e.jsx("p",{className:"text-xs text-slate-500 mt-0.5",children:"Confirm or adjust before importing. Deselect anything you don't want."})]})]}),e.jsxs("div",{className:"space-y-4",children:[(m||c)&&e.jsxs("div",{className:"bg-gradient-to-br from-indigo-50 to-purple-50 rounded-xl border border-indigo-100 p-5",children:[e.jsxs("div",{className:"flex items-center gap-2 mb-2",children:[e.jsx(se,{size:16,className:"text-indigo-600"}),e.jsx("p",{className:"text-sm font-bold text-slate-900",children:"Herald's read on your data"})]}),m&&!c&&e.jsx("p",{className:"text-xs text-slate-500 animate-pulse",children:"Double-checking the parsed dataâ¦"}),c?.narrative&&e.jsx("p",{className:"text-sm text-slate-700",children:c.narrative}),c&&c.flags.length>0&&e.jsx("div",{className:"mt-3 space-y-1.5",children:c.flags.map((t,x)=>e.jsxs("div",{className:`text-xs rounded-lg px-3 py-2 ${t.severity==="warning"?"bg-amber-100/70 text-amber-900":"bg-white/70 text-slate-600"}`,children:[e.jsx("span",{className:"font-semibold",children:t.index>=0?`Row ${t.index+1}${t.address?` (${t.address})`:""}: `:""}),t.issue,t.suggestion?` â ${t.suggestion}`:""]},x))}),c&&c.normalizedAddresses.length>0&&e.jsxs("button",{onClick:_,className:"mt-3 text-xs font-semibold text-indigo-700 bg-white border border-indigo-200 rounded-lg px-3 py-1.5 hover:bg-indigo-50",children:["Apply ",c.normalizedAddresses.length," address formatting fix",c.normalizedAddresses.length===1?"":"es"]}),c&&c.setupSuggestions.length>0&&e.jsxs("div",{className:"mt-3 pt-3 border-t border-indigo-100",children:[e.jsx("p",{className:"text-xs font-semibold text-slate-700 mb-1",children:"After import, Herald suggests:"}),c.setupSuggestions.map((t,x)=>e.jsxs("p",{className:"text-xs text-slate-600",children:["⢠",e.jsx("span",{className:"font-medium",children:t.feature})," â ",t.reason]},x))]})]}),(S.length>0||k.length>0)&&e.jsxs("div",{className:"bg-white rounded-xl border border-slate-200 p-5",children:[e.jsxs("div",{className:"flex items-center gap-3 mb-3",children:[e.jsx(ge,{size:20,className:"text-emerald-600"}),e.jsxs("div",{children:[e.jsx("p",{className:"text-sm font-bold text-slate-900",children:"Financial History Found"}),e.jsx("p",{className:"text-xs text-slate-500",children:"Payments become ledger line items on each property; opening balances are set so every ledger matches your sheet exactly."})]})]}),e.jsxs("div",{className:"space-y-2",children:[S.length>0&&e.jsxs("label",{className:"flex items-center gap-3 py-1.5 px-2 rounded-lg hover:bg-slate-50 cursor-pointer",children:[e.jsx("input",{type:"checkbox",checked:z,onChange:()=>H(t=>!t),className:"rounded text-emerald-600"}),e.jsxs("span",{className:"text-sm text-slate-700",children:[e.jsxs("span",{className:"font-semibold",children:[S.length," dues payments"]})," ","($",S.reduce((t,x)=>t+x.amount,0).toLocaleString(),")"]})]}),k.length>0&&e.jsxs("label",{className:"flex items-center gap-3 py-1.5 px-2 rounded-lg hover:bg-slate-50 cursor-pointer",children:[e.jsx("input",{type:"checkbox",checked:W,onChange:()=>E(t=>!t),className:"rounded text-emerald-600"}),e.jsxs("span",{className:"text-sm text-slate-700",children:[e.jsxs("span",{className:"font-semibold",children:[k.length," operating expenses"]})," ","($",k.reduce((t,x)=>t+x.amount,0).toLocaleString(),")"]})]})]})]}),r.length>0&&e.jsxs("div",{className:"bg-white rounded-xl border border-slate-200 overflow-hidden",children:[e.jsxs("button",{onClick:()=>le("properties"),className:"w-full flex items-center justify-between px-5 py-4 hover:bg-slate-50",children:[e.jsxs("div",{className:"flex items-center gap-3",children:[e.jsx(ve,{size:20,className:"text-indigo-600"}),e.jsxs("div",{className:"text-left",children:[e.jsxs("p",{className:"text-sm font-bold text-slate-900",children:[J.length," Properties"]}),e.jsx("p",{className:"text-xs text-slate-500",children:me>
70?`$${me.toLocaleString()} in outstanding balances`:"No outstanding balances"})]})]}),C==="properties"?e.jsx(be,{size:18,className:"text-slate-400"}):e.jsx(Ne,{size:18,className:"text-slate-400"})]}),C==="properties"&&e.jsxs("div",{className:"border-t border-slate-100 px-5 py-3",children:[e.jsxs("div",{className:"flex items-center justify-between mb-3",children:[e.jsx("button",{onClick:()=>d(t=>t.map(x=>({...x,selected:!t.every(P=>P.selected)}))),className:"text-xs text-indigo-600 font-medium",children:r.every(t=>t.selected)?"Deselect All":"Select All"}),e.jsxs("span",{className:"text-xs text-slate-400",children:[J.length," of ",r.length," selected",j!==-1&&e.jsxs("span",{className:J.length>j?" text-red-500 font-bold":" text-slate-400",children:[" (limit: ",j,")"]})]})]}),e.jsx("div",{className:"max-h-64 overflow-y-auto space-y-1",children:r.map((t,x)=>e.jsxs("label",{className:"flex items-center gap-3 py-1.5 px-2 rounded-lg hover:bg-slate-50 cursor-pointer",children:[e.jsx("input",{type:"checkbox",checked:t.selected,onChange:()=>d(P=>P.map((F,G)=>G===x?{...F,selected:!F.selected}:F)),className:"rounded text-indigo-600"}),e.jsx("span",{className:"text-sm text-slate-700 flex-1 truncate",children:t.address}),t.lot&&e.jsxs("span",{className:"text-xs text-slate-400",children:["Lot ",t.lot]}),(t.currentBalance??0)>0&&e.jsxs("span",{className:"text-xs font-medium text-red-600",children:["$",t.currentBalance?.toLocaleString()]})]},x))})]})]}),(K>0||r.length>0)&&e.jsxs("div",{className:"bg-white rounded-xl border border-slate-200 px-5 py-4",children:[e.jsxs("div",{className:"flex items-center gap-3 mb-3",children:[e.jsx(ge,{size:20,className:"text-emerald-600"}),e.jsx("p",{className:"text-sm font-bold text-slate-900",children:"Dues & Assessments"})]}),e.jsxs("div",{className:"flex items-center gap-4",children:[e.jsxs("div",{className:"flex-1",children:[e.jsx("label",{className:"text-xs text-slate-500 mb-1 block",children:"Amount"}),e.jsxs("div",{className:"relative",children:[e.jsx("span",{className:"absolute left-3 top-1/2 -translate-y-1/2 text-slate-400 text-sm",children:"$"}),e.jsx("input",{type:"number",value:K||"",onChange:t=>g(Number(t.target.value)),placeholder:"0",className:"w-full pl-7 pr-3 py-2 border border-slate-300 rounded-lg text-sm focus:ring-2 focus:ring-indigo-500 focus:border-indigo-500"})]})]}),e.jsxs("div",{children:[e.jsx("label",{className:"text-xs text-slate-500 mb-1 block",children:"Frequency"}),e.jsxs("select",{value:I,onChange:t=>R(t.target.value),className:"px-3 py-2 border border-slate-300 rounded-lg text-sm focus:ring-2 focus:ring-indigo-500 focus:border-indigo-500",children:[e.jsx("option",{value:"annual",children:"Annual"}),e.jsx("option",{value:"monthly",children:"Monthly"})]})]})]})]}),i.length>0&&e.jsxs("div",{className:"bg-white rounded-xl border border-slate-200 overflow-hidden",children:[e.jsxs("button",{onClick:()=>le("documents"),className:"w-full flex items-center justify-between px-5 py-4 hover:bg-slate-50",children:[e.jsxs("div",{className:"flex items-center gap-3",children:[e.jsx(te,{size:20,className:"text-blue-600"}),e.jsxs("div",{className:"text-left",children:[e.jsxs("p",{className:"text-sm font-bold text-slate-900",children:[fe.length," Documents"]}),e.jsx("p",{className:"text-xs text-slate-500",children:"Indexed for Herald AI knowledge base"})]})]}),C==="documents"?e.jsx(be,{size:18,className:"text-slate-400"}):e.jsx(Ne,{size:18,className:"text-slate-400"})]}),C==="documents"&&e.jsx("div",{className:"border-t border-slate-100 px-5 py-3 space-y-2",children:i.map((t,x)=>e.jsxs("label",{className:"flex items-start gap-3 py-2 px-2 rounded-lg hover:bg-slate-50 cursor-pointer",children:[e.jsx("input",{type:"checkbox",checked:t.selected,onChange:()=>$(P=>P.map((F,G)=>G===x?{...F,selected:!F.selected}:F)),className:"rounded text-indigo-600 mt-0.5"}),e.jsxs("div",{className:"flex-1",children:[e.jsx("p",{className:"text-sm font-medium text-slate-700",children:t.title}),e.jsxs("div",{className:"flex items-center gap-2 mt-0.5",children:[e.jsx("span",{className:"text-[10px] font-bold px-1.5 py-0.5 rounded bg-blue-100 text-blue-700",children:t.category}),e.jsx("span",{className:"text-xs text-slate-400 truncate",children:t.summary})]})]})]},x))})]}),v.length>0&&e.jsxs("div",{className:"bg-white rounded-xl border border-slate-200 overflow-hidden",children:[e.jsxs("button",{onClick:()=>le("rules"),className:"w-full flex items-center justify-between px-5 py-4 hover:bg-slate-50",children:[e.jsxs("div",{className:"flex items-center gap-3",children:[e.jsx(we,{size:20,className:"text-amber-600"}),e.jsxs("div",{className:"text-left",children:[e.jsxs("p",{className:"text-sm font-bold text-slate-900",children:[ie.length," Violation Rules"]}),e.jsx("p",{className:"text-xs text-slate-500",children:"Extracted from your governing documents"})]})]}),C==="rules"?e.jsx(be,{size:18,className:"text-slate-400"}):e.jsx(Ne,{size:18,className:"text-slate-400"})]}),C==="rules"&&e.jsxs("div",{className:"border-t border-slate-100 px-5 py-3",children:[e.jsx("div",{className:"flex items-center justify-between mb-2",children:e.jsx("button",{onClick:()=>a(t=>t.map(x=>({...x,selected:!t.every(P=>P.selected)}))),className:"text-xs text-indigo-600 font-medium",children:v.every(t=>t.selected)?"Deselect All":"Select All"})}),e.jsx("div",{className:"max-h-64 overflow-y-auto space-y-1",children:v.map((t,x)=>e.jsxs("label",{className:"flex items-start gap-3 py-1.5 px-2 rounded-lg hover:bg-slate-50 cursor-pointer",children:[e.jsx("input",{type:"checkbox",checked:t.selected,onChange:()=>a(P=>P.map((F,G)=>G===x?{...F,selected:!F.selected}:F)),className:"rounded text-indigo-600 mt-0.5"}),e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx("span",{className:"text-[10px] font-bold px-1.5 py-0.5 rounded bg-amber-100 text-amber-700",children:t.category}),e.jsx("span",{className:"text-sm font-medium text-slate-700 truncate",children:t.title})]}),e.jsx("p",{className:"text-xs text-slate-500 mt-0.5 line-clamp-2",children:t.description})]}),t.fineAmount>0&&e.jsxs("span",{className:"text-xs font-medium text-slate-500
7whitespace-nowrap",children:["$",t.fineAmount]})]},x))})]})]}),u.length>0&&e.jsxs("div",{className:"bg-white rounded-xl border border-slate-200 px-5 py-4",children:[e.jsxs("div",{className:"flex items-center gap-3 mb-3",children:[e.jsx(Ce,{size:20,className:"text-green-600"}),e.jsx("p",{className:"text-sm font-bold text-slate-900",children:"Amenities Detected"})]}),e.jsx("div",{className:"flex flex-wrap gap-2",children:u.map((t,x)=>e.jsxs("span",{className:"inline-flex items-center gap-1.5 px-3 py-1.5 rounded-full bg-green-50 text-green-700 text-xs font-medium border border-green-200",children:[t,e.jsx("button",{onClick:()=>N(P=>P.filter((F,G)=>G!==x)),className:"text-green-500 hover:text-red-500",children:e.jsx($e,{size:12})})]},x))}),e.jsxs("div",{className:"flex items-center gap-2 mt-3",children:[e.jsx("input",{type:"text",value:B,onChange:t=>Q(t.target.value),placeholder:"Add amenity...",className:"flex-1 px-3 py-1.5 border border-slate-300 rounded-lg text-sm",onKeyDown:t=>{t.key==="Enter"&&B.trim()&&(N(x=>[...x,B.trim()]),Q(""))}}),e.jsx("button",{onClick:()=>{B.trim()&&(N(t=>[...t,B.trim()]),Q(""))},className:"p-1.5 text-indigo-600 hover:bg-indigo-50 rounded-lg",children:e.jsx(lt,{size:18})})]})]}),!xe&&e.jsxs("div",{className:"text-center py-12 text-slate-400",children:[e.jsx(te,{size:40,className:"mx-auto mb-3 opacity-50"}),e.jsx("p",{className:"text-sm",children:"No data was extracted. You can set up your community manually from the admin dashboard."})]})]}),e.jsxs("div",{className:"mt-8 flex items-center justify-between",children:[e.jsxs("button",{onClick:U,className:"flex items-center gap-2 text-sm text-slate-500 hover:text-slate-700 font-medium",children:[e.jsx(it,{size:16})," Back"]}),e.jsx("button",{onClick:q,disabled:n,className:"px-6 py-2.5 hh-btn-quiet rounded-xl font-semibold text-sm transition-colors flex items-center gap-2 disabled:opacity-50",children:n?e.jsxs(e.Fragment,{children:[e.jsx(de,{size:16,className:"animate-spin"})," Importing..."]}):e.jsxs(e.Fragment,{children:[e.jsx(he,{size:16})," Confirm & Import"]})})]})]})},pt=({importSummary:r,communityName:d,onDashboard:c})=>{const m=[r.properties>0&&`${r.properties} properties`,r.payments>0&&`${r.payments} payment records`,r.expenses>0&&`${r.expenses} expenses`,r.documents>0&&`${r.documents} documents`,r.rules>0&&`${r.rules} violation rules`,r.amenities>0&&`${r.amenities} amenities`].filter(Boolean);return e.jsxs("div",{className:"max-w-lg mx-auto px-4 py-16 text-center",children:[e.jsx("div",{className:"w-20 h-20 rounded-full bg-gradient-to-br from-emerald-400 to-emerald-600 flex items-center justify-center mx-auto mb-6 shadow-lg shadow-emerald-500/30",children:e.jsx(ot,{size:40,className:"text-white"})}),e.jsxs("h2",{className:"text-2xl font-bold text-slate-900 mb-2",children:[d," is Live!"]}),m.length>0?e.jsxs("p",{className:"text-slate-500 mb-8",children:["Herald imported ",m.join(", ")," into your community. You're ready to go."]}):e.jsx("p",{className:"text-slate-500 mb-8",children:"Your community is set up and ready to go. You can configure everything from the admin dashboard."}),e.jsxs("button",{onClick:c,className:"px-8 py-3 bg-indigo-600 text-white rounded-xl font-semibold text-sm hover:bg-indigo-700 transition-colors inline-flex items-center gap-2",children:["Go to Admin Dashboard",e.jsx(ye,{size:16})]})]})},vt=()=>{const r=st(),{showToast:d}=_e(),{currentCommunityId:c,communitySettings:m,userCommunities:_,currentUser:S,communities:k}=He(),z=_.find(y=>y.community.id===c)?.community.name||"Your Community",H=k.find(y=>y.id===c),W=qe(H)?-1:H?.maxProperties??Me[Ge(H?.planId||"free")]?.limits?.properties??50,[E,i]=o.useState(1),[$,v]=o.useState([]),[a,u]=o.useState(!1),[N,K]=o.useState(null),[g,I]=o.useState(!1),[R,U]=o.useState([]),[q,n]=o.useState(null),[j,C]=o.useState(!1),[M,B]=o.use
7State([]),[Q,le]=o.useState([]),[J,fe]=o.useState(!0),[ie,me]=o.useState(!0),[xe,t]=o.useState([]),[x,P]=o.useState([]),[F,G]=o.useState([]),[ae,Ae]=o.useState(0),[Z,De]=o.useState("annual"),[Ie,Fe]=o.useState({properties:0,documents:0,rules:0,amenities:0,payments:0,expenses:0}),[Pe,ue]=o.useState(!1),[Le,je]=o.useState("uploading"),[Re,ze]=o.useState(0),Y=c,Ue=async()=>{if($.length===0)return;u(!0),ue(!0),je("uploading"),ze(0),v(p=>p.map(w=>({...w,status:"uploading"})));const y=[];for(let p=0;p<$.length;p++){ze(p);const w=$[p].file.name.split(".").pop()?.toLowerCase()||"";if(["xls","xlsx","xlsm","ods"].includes(w)){y.push({file:$[p]}),v(T=>T.map((L,A)=>A===p?{...L,status:"processing"}:L));continue}try{const T=await Ye(Y,$[p].file);y.push({file:$[p],storageUrl:T.url}),v(L=>L.map((A,l)=>l===p?{...A,status:"processing",storageUrl:T.url}:A))}catch{y.push({file:$[p]}),v(T=>T.map((L,A)=>A===p?{...L,status:"error",error:"Upload failed"}:L))}}try{v(s=>s.map(b=>b.status==="processing"?b:{...b,status:b.status==="error"?"error":"processing"}));const p=s=>new Promise((b,D)=>{const V=new FileReader;V.onload=()=>b(V.result.split(",")[1]),V.onerror=D,V.readAsDataURL(s)}),w=[],X=[],T=[];for(const{file:s}of y){if(s.status==="error")continue;const b=s.file.name.split(".").pop()?.toLowerCase()||"",D=["csv","txt","xls","xlsx","xlsm","ods"].includes(b),V=(D?20:7)*1024*1024;if(s.file.size>V){v(ee=>ee.map(re=>re.file.name===s.file.name?{...re,status:"error",error:`Too large (${(s.file.size/(1024*1024)).toFixed(1)} MB). The limit here is ${D?20:7} MB - split it or upload a smaller version`}:re));continue}if(D)try{const ee=await nt(s.file);w.push({fileName:s.file.name,mimeType:"text/csv",csvContent:ee});try{const re=await rt(s.file);X.push(...re.payments.rows),T.push(...re.expenses.rows)}catch{}}catch{const ee=await p(s.file);w.push({fileName:s.file.name,mimeType:s.file.type||"application/vnd.ms-excel",fileBase64:ee})}else{const ee=await p(s.file);w.push({fileName:s.file.name,mimeType:s.file.type||"application/pdf",fileBase64:ee})}}if(w.length===0){v(s=>s.map(b=>b.status!=="error"?{...b,status:"error",error:"No processable files"}:b)),u(!1),ue(!1);return}B(X),le(T),je("analyzing");const L=await Promise.allSettled(w.map(s=>Ve(Y,[s]))),A=[],l={totalProperties:0,documentsClassified:0,totalRulesExtracted:0,amenitiesDetected:[],hasLogo:!1},h=new Set;L.forEach((s,b)=>{if(s.status==="fulfilled"){A.push(...s.value.results);const D=s.value.aggregated;l.totalProperties+=D.totalProperties,l.documentsClassified+=D.documentsClassified,l.totalRulesExtracted+=D.totalRulesExtracted,D.amenitiesDetected.forEach(V=>h.add(V)),D.hasLogo&&(l.hasLogo=!0),D.suggestedDuesAmount&&!l.suggestedDuesAmount&&(l.suggestedDuesAmount=D.suggestedDuesAmount,l.suggestedDuesFrequency=D.suggestedDuesFrequency)}else A.push({fileName:w[b].fileName,fileType:"UNKNOWN",status:"error",error:"Analysis failed â try re-uploading this file."})}),l.amenitiesDetected=Array.from(h);const f={success:!0,results:A,aggregated:l};K(f),je("complete"),v(s=>s.map(b=>{const D=f.results.find(V=>V.fileName===b.file.name);return D?{...b,status:D.status==="success"?"done":"error",error:D.error}:{...b,status:"error",error:"Not processed"}}));const O=[],oe=[],ce=[],ne=new Set;for(const s of f.results)if(s.status==="success"){if(s.csvAnalysis?.parsedProperties)for(const b of s.csvAnalysis.parsedProperties)O.push({...b,sourceFile:s.fileName,selected:!0});if(s.documentExtraction){oe.push({title:s.documentExtraction.title,category:s.documentExtraction.category,content:s.documentExtraction.content,summary:s.documentExtraction.summary,fileName:s.fileName,selected:!0});for(const b of s.documentExtraction.extractedRules||[])ce.push({...b,selected:!0})}s.budgetExtraction?.amenitiesDetected&&s.budgetExtraction.amenitiesDetected.forEach(b=>ne.add(b))}U(O),t(oe),P(ce),G(Array.from(ne)),f.aggregated.suggestedDuesAmount&&(Ae(f.aggregated.suggestedDuesAmount),De(f.aggregated.suggestedDuesFrequency||"annual")),n(null),O.length>0&&(C(!0),We(Y,{properties:O.map(s=>({address:s.address,lot:s.lot,block:s.block,monthlyDues:s.monthlyDues,currentBalance:s.currentBalance,status:s.status,residentName:s.residentName,residentEmail:s.residentEmail,notes:s.notes,sourceFile:s.sourceFile})),documents:oe.map(s=>({title:s.title,category:s.category,summary:s.summary})),duesAmount:f.aggregated.suggestedDuesAmount,duesFrequency:f.aggregated.suggestedDuesFrequency,amenities:Array.from(ne),totalRules:ce.length}).then(s=>n(s)).catch(s=>console.warn("Import review unavailable:",s)).finally(()=>C(!1)))}catch(p){console.error("Analysis error:",p),v(w=>w.map(X=>X.status==="processing"?{...X,status:"error",error:"Analysis failed"}:X)),d("Some files failed to process","error"),ue(!1)}u(!1)},Te=()=>{q?.normalizedAddresses?.length&&(U(y=>{const p=[...y];for(const w of q.normalizedAddresses)p[w.index]&&p[w.index].address===w.original&&(p[w.index]={...p[w.index],address:w.normalized});return p}),n(y=>y&&{...y,normalizedAddresses:[]}))},Be=async()=>{I(!0);const y={properties:0,documents:0,rules:0,amenities:0,payments:0,expenses:0};try{const p=R.filter(l=>l.selected);if(p.length>0){const l=p.map(f=>({address:f.address,lot:f.lot||"",block:f.block||"",monthlyDues:Z==="monthly"?ae:0,initialBalance:f.currentBalance||0,currentResidentId:"",ownerName:f.residentName||"",status:f.status||Ke.OCCUPIED,notes:f.notes||""}));let h=await Se(Y,l);if(h.imported===0&&h.errors.length>0&&h.errors[0]?.includes("plan allows")){const f=h.errors[0].match(/allows (\d+)/),O=h.errors[0].match(/have (\d+)/),oe=f?parseInt(f[1]):10,ce=O?parseInt(O[1]):0,ne=Math.max(0,oe-ce);if(ne>0){const s=l.slice(0,ne);h=await Se(Y,s),h.imported>0&&d(`Imported ${h.imported} of ${p.length} properties (plan limit). Upgrade for more.`,"warning")}}if(h.imported===0&&h.errors.length>0){d(h.errors[0],"error"),I(!1);return}y.properties=h.imported}if(J&&M.length>0||ie&&Q.length>0)try{const l=await Xe(Y,J?M:[],ie?Q:[]);if(y.payments=l.paymentsImported,y.expenses=l.expensesImported,l.paymentsUnmatched.length>0){const h=l.paymentsUnmatched.reduce((f,O)=>f+O.count,0);d(`${h} payment${h===1?"":"s"} skipped â no matching property address`,"warning")}}catch(l){console.error("Financial history import failed:",l),d("Financial history could not be imported â properties are unaffected","error")}const w=xe.filter(l=>l.selected);for(const l of w){const h={title:l.title,category:l.category,content:l.content};l.fileName&&(h.fileName=l.fileName),l.fileUrl&&(h.fileUrl=l.fileUrl),await Je(Y,h),y.documents++}const X=x.filter(l=>l.selected);for(const l of X)await Qe(Y,{category:l.category,title:l.title,de
7scription:l.description,fineAmount:l.fineAmount||0}),y.rules++;for(const l of F){const{addAsset:h}=await Ze(async()=>{const{addAsset:f}=await import("./index-Bog8-u9h.js").then(O=>O.ih);return{addAsset:f}},__vite__mapDeps([0,1,2,3,4,5,6]));await h(Y,{name:l,type:et.COMMON_AREA,isActive:!0}),y.amenities++}const T=$.find(l=>{const h=l.file.name.split(".").pop()?.toLowerCase();return["jpg","jpeg","png"].includes(h||"")&&l.status!=="error"});let L=null;if(T)try{L=await new Promise((l,h)=>{const f=new FileReader;f.onloadend=()=>l(f.result),f.onerror=h,f.readAsDataURL(T.file)})}catch{console.error("Failed to read logo file")}const A={onboardingComplete:!0,aiEnabled:!0};L&&(A.logoUrl=L),ae>0&&(A.duesTypes=[{id:"dt_dues_initial",label:Z==="monthly"?"Monthly Dues":"Annual Dues",amount:ae,frequency:Z,applyToAll:!0,dueDay:1,...Z==="annual"?{dueMonth:1}:{}}],A.autoDuesEnabled=!0,A.defaultDuesAmount=ae,A.duesFrequency=Z,Z==="monthly"&&(A.defaultMonthlyDues=ae)),await tt(Y,A),Fe(y),i(3),d("Community setup complete!","success")}catch(p){console.error("Import error:",p),d("Some items failed to import","error")}I(!1)},Oe=()=>{r("/admin",{state:{tab:"GETTING_STARTED"}})};return e.jsxs("div",{className:"h-screen bg-slate-50 flex flex-col",children:[e.jsx(dt,{step:E,communityName:z}),Pe&&e.jsx(mt,{files:$,phase:Le,uploadIndex:Re,analysisResult:N,onContinue:()=>{ue(!1),i(2)}}),e.jsxs("div",{className:"flex-1 overflow-y-auto",children:[E===1&&e.jsx(xt,{files:$,setFiles:v,isProcessing:a,analysisResult:N,onProcess:Ue,onSkip:Oe,onContinue:()=>i(2)}),E===2&&e.jsx(ut,{properties:R,setProperties:U,importReview:q,reviewLoading:j,onApplyFormatting:Te,payments:M,expenses:Q,includePayments:J,setIncludePayments:fe,includeExpenses:ie,setIncludeExpenses:me,documents:xe,setDocuments:t,rules:x,setRules:P,amenities:F,setAmenities:G,duesAmount:ae,setDuesAmount:Ae,duesFrequency:Z,setDuesFrequency:De,onBack:()=>i(1),onConfirm:Be,isImporting:g,propertyLimit:W}),E===3&&e.jsx(pt,{importSummary:Ie,communityName:z,onDashboard:()=>r("/admin",{state:{tab:"GETTING_STARTED"}})})]})]})};export{vt 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.