PageSourceSearch

https://repsshield.com/assets/ExchangeSharedPage-DXwPuBDP.js

js repsshield.com collected 2026-10-02 02:01:05 UTC 9,293 bytes, 1 lines download raw bytes

1import{a6 as v,a7 as p,j as e,P as w,Y as P,B as D,v as C,i as R,C as f,b as k,c as E,q as A,d as y,e as N,x as F,a5 as L,h as I,a8 as T,a9 as O}from"./index-DGo-vssZ.js";import{r as m,L as S}from"./vendor-Qgthw7N1.js";import{S as V}from"./share-2-8n29V9oi.js";import{R as Y,C as U,X as $,Y as K,T as G,a as B}from"./generateCategoricalChart-Ccg4ytiv.js";import{A as H,a as X}from"./AreaChart-CfNv0fRv.js";import{d as q}from"./differenceInDays-CrE7Wgja.js";function z(s){const l=s.relinquishedProperties.filter(r=>r.date&&!isNaN(new Date(r.date).getTime()));if(l.length===0)throw new Error("No valid properties found");const a=new Date(Math.min(...l.map(r=>new Date(r.date).getTime()))),x=v(a,45),d=v(a,180),h=new Date,b=Math.max(0,q(x,h)),u=Math.max(0,q(d,h));let o="safe";u<=30?o="urgent":u<=60&&(o="warning");const t=s.relinquishedProperties.reduce((r,n)=>r+n.value,0),i=s.replacementProperties.reduce((r,n)=>r+n.value,0);return{earliestSaleDate:a,identificationDeadline:x,exchangeDeadline:d,daysToIdentification:b,daysToExchange:u,riskLevel:o,isReverseExchange:s.isReverseExchange,totalRelinquishedValue:t,totalReplacementValue:i}}function J(s){const l=new Date,a=[];return a.push({date:s.earliestSaleDate,title:"Property Sale/Exchange Start",description:"First relinquished property closing date",type:"milestone",status:T(l,s.earliestSaleDate)?"completed":"upcoming",color:"#10B981"}),a.push({date:s.identificationDeadline,title:"45-Day Identification Deadline",description:"Must identify replacement properties",type:"deadline",status:T(l,s.identificationDeadline)?"completed":(O(l,v(s.identificationDeadline,-7)),"upcoming"),color:"#F59E0B"}),a.push({date:s.exchangeDeadline,title:"180-Day Exchange Deadline",description:"Must complete exchange of all properties",type:"deadline",status:T(l,s.exchangeDeadline)?"overdue":"upcoming",color:"#EF4444"}),a.sort((x,d)=>x.date.getTime()-d.date.getTime())}function te(){const[s,l]=m.useState(null),[a,x]=m.useState(null),[d,h]=m.useState(""),b=m.useMemo(()=>a?J(a):[],[a]);m.useEffect(()=>{document.title="Shared 1031 Exchange Timeline | REPSShield";const t=localStorage.getItem("1031-exchange-multi-data");if(t)try{const i=JSON.parse(t);if(l(i),i.relinquishedProperties.length>0&&i.relinquishedProperties[0].date){const r=z(i);x(r)}}catch(i){console.error("Error loading shared timeline:",i),h("Unable to load timeline data. The shared link may be invalid or expired.")}else h("No timeline data found. The shared link may be invalid or expired.")},[]);const u=t=>{switch(t){case"urgent":return e.jsxs(N,{variant:"destructive",className:"flex items-center gap-1",children:[e.jsx(P,{className:"h-3 w-3"}),"Urgent Action Required"]});case"warning":return e.jsxs(N,{variant:"outline",className:"flex items-center gap-1 border-yellow-500 text-yellow-700",children:[e.jsx(R,{className:"h-3 w-3"}),"Approaching Deadline"]});default:return e.jsxs(N,{variant:"outline",className:"flex items-center gap-1 border-green-500 text-green-700",children:[e.jsx(I,{className:"h-3 w-3"}),"On Track"]})}},o=m.useMemo(()=>{if(!a)return[];const t=new Date,i=a.earliestSaleDate,r=[];for(let n=0;n<=210;n++){const M=v(i,n),c=n;let g="Exchange Period",j="safe";c<=45?(g="Identification Period",j=c>=35?"warning":"safe"):c<=180?(g="Exchange Period",j=c>=160?"warning":"safe"):(g="Deadline Passed",j="urgent"),r.push({day:c,date:p(M,"MMM dd"),phase:g,status:j,isToday:M.toDateString()===t.toDateString(),value:c<=45?1:c<=180?2:3})}return r},[a]);return d?e.jsx(w,{children:e.jsx("div",{className:"container mx-auto px-4 py-16",children:e.jsxs("div",{className:"max-w-2xl mx-auto text-center",children:[e.jsx(P,{className:"h-16 w-16 mx-auto mb-6 text-red-500"}),e.jsx("h1",{className:"text-3xl font-bold text-gray-900 dark:text-white mb-4",children:"Timeline Not Found"}),e.jsx("p",{className:"text-lg text-gray-600 dark:text-gray-300 mb-8",children:d}),e.jsx(S,{href:"/tools/1031-exchange-timer",children:e.jsxs(D,{className:"bg-blue-600 hover:bg-blue-700 text-white",children:[e.jsx(C,{className:"h-4 w-4 mr-2"}),"Create New Timeline"]})})]})})}):!s||!a?e.jsx(w,{children:e.jsx("div",{className:"container mx-auto px-4 py-16",children:e.jsxs("div",{className:"max-w-2xl mx-auto text-center",children:[e.jsx(R,{className:"h-16 w-16 mx-auto mb-6 text-blue-500 animate-spin"}),e.jsx("h1",{className:"text-2xl font-semibold text-gray-900 dark:text-white",children:"Loading Timeline..."})]})})}):e.jsx(w,{children:e.jsxs("div",{className:"container mx-auto px-4 py-8",children:[e.jsxs("div",{className:"text-center mb-8",children:[e.jsxs("div",{className:"flex justify-center items-center gap-2 mb-4",children:[e.jsx(V,{className:"h-8 w-8 text-blue-600"}),e.jsx("h1",{className:"text-3xl font-bold text-gray-900 dark:text-white",children:"Shared 1031 Exchange Timeline"})]}),e.jsx("p",{className:"text-gray-600 dark:text-gray-300 max-w-2xl mx-auto",children:"This timeline shows the critical deadlines and milestones for your 1031 like-kind exchange."})]}),e.jsxs(f,{className:"mb-8",children:[e.jsx(k,{children:e.jsxs("div",{className:"flex justify-between items-start",children:[e.jsxs("div",{children:[e.jsxs(E,{className:"text-2xl flex items-center gap-2",children:[e.jsx(A,{className:"h-6 w-6 text-blue-600"}),"Exchange Timeline Overview"]}),e.jsxs("p",{className:"text-gray-600 dark:text-gray-300 mt-2",children:[s.isReverseExchange?"Reverse ":"","1031 Exchange Progress"]})]}),u(a.riskLevel)]})}),e.jsx(y,{children:e.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-3 gap-6",children:[e.jsxs("div",{className:"text-center",children:[e.jsx("div",{className:"text-3xl font-bold text-blue-600 mb-2",children:a.daysToIdentification}),e.jsx("div",{className:"text-sm text-gray-600 dark:text-gray-300",children:"Days to Identification Deadline"}),e.jsx("div",{className:"text-xs text-gray-500 mt-1",children:p(a.identificationDeadline,"MMM dd, yyyy")})]}),e.jsxs("div",{className:"text-center",children:[e.jsx("div",{className:"text-3xl font-bold text-green-600 mb-2",children:a.daysToExchange}),e.jsx("div",{className:"text-sm text-gray-600 dark:text-gray-300",children:"Days to Exchange Deadline"}),e.jsx("div",{className:"text-xs text-gray-500 mt-1",children:p(a.exchangeDeadline,"MMM dd, yyyy")})]}),e.jsxs("div",{className:"text-center",children:[e.jsxs("div",{className:"text-3xl font-bold text-purple-600 mb-2",children:["$",a.totalRelinquishedValue.toLocaleStr
1ing()]}),e.jsx("div",{className:"text-sm text-gray-600 dark:text-gray-300",children:"Total Exchange Value"}),e.jsxs("div",{className:"text-xs text-gray-500 mt-1",children:[s.relinquishedProperties.length," Properties"]})]})]})})]}),o.length>0&&e.jsxs(f,{className:"mb-8",children:[e.jsx(k,{children:e.jsx(E,{children:"Timeline Visualization"})}),e.jsx(y,{children:e.jsx("div",{className:"h-64",children:e.jsx(Y,{width:"100%",height:"100%",children:e.jsxs(H,{data:o,children:[e.jsx(U,{strokeDasharray:"3 3"}),e.jsx($,{dataKey:"day"}),e.jsx(K,{domain:[0,3]}),e.jsx(G,{formatter:(t,i)=>[`${i}`,"Phase"],labelFormatter:t=>`Day ${t}`}),e.jsx(B,{x:45,stroke:"#F59E0B",strokeDasharray:"2 2",label:"Identification Deadline"}),e.jsx(B,{x:180,stroke:"#EF4444",strokeDasharray:"2 2",label:"Exchange Deadline"}),e.jsx(X,{type:"stepAfter",dataKey:"value",stroke:"#3B82F6",fill:"#93C5FD",fillOpacity:.3})]})})})})]}),e.jsxs(f,{className:"mb-8",children:[e.jsx(k,{children:e.jsx(E,{children:"Key Milestones & Deadlines"})}),e.jsx(y,{children:e.jsx("div",{className:"space-y-4",children:b.map((t,i)=>e.jsxs("div",{className:"flex items-start gap-4 p-4 rounded-lg border",children:[e.jsx("div",{className:`w-3 h-3 rounded-full mt-2 ${t.status==="completed"?"bg-green-500":t.status==="overdue"?"bg-red-500":"bg-blue-500"}`}),e.jsx("div",{className:"flex-1",children:e.jsxs("div",{className:"flex justify-between items-start",children:[e.jsxs("div",{children:[e.jsx("h3",{className:"font-semibold text-gray-900 dark:text-white",children:t.title}),e.jsx("p",{className:"text-gray-600 dark:text-gray-300 text-sm",children:t.description})]}),e.jsxs("div",{className:"text-right",children:[e.jsx("div",{className:"text-sm font-medium text-gray-900 dark:text-white",children:p(t.date,"MMM dd, yyyy")}),e.jsx(N,{variant:t.status==="completed"?"default":t.status==="overdue"?"destructive":"secondary",className:"text-xs",children:t.status==="completed"?"Completed":t.status==="overdue"?"Overdue":"Upcoming"})]})]})})]},i))})})]}),e.jsx(f,{className:"text-center",children:e.jsxs(y,{className:"py-8",children:[e.jsx(F,{className:"h-12 w-12 mx-auto mb-4 text-blue-600"}),e.jsx("h3",{className:"text-xl font-semibold text-gray-900 dark:text-white mb-2",children:"Need Help with Your 1031 Exchange?"}),e.jsx("p",{className:"text-gray-600 dark:text-gray-300 mb-6 max-w-2xl mx-auto",children:"Get professional guidance and tools to manage your like-kind exchange successfully."}),e.jsxs("div",{className:"flex flex-col sm:flex-row gap-4 justify-center",children:[e.jsx(S,{href:"/tools/1031-exchange-timer",children:e.jsxs(D,{className:"bg-blue-600 hover:bg-blue-700 text-white",children:[e.jsx(C,{className:"h-4 w-4 mr-2"}),"Create Your Own Timeline"]})}),e.jsx(S,{href:"/login",children:e.jsxs(D,{variant:"outline",children:[e.jsx(L,{className:"h-4 w-4 mr-2"}),"Sign Up for Full Platform"]})})]})]})})]})})}export{te 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.