PageSourceSearch

https://lsd.law/assets/js/chunks/comp_calculator_hook-EOFX3AD2.js

js lsd.law collected 2026-10-02 05:30:53 UTC 3,260 bytes, 1 lines download raw bytes

1import"./chunk-7SZRL6FY.js";var l={fc:{billable:35,overhead:15},ar:{billable:3,overhead:1},session:{billable:.5,overhead:.75}},L=8,R=[{name:"Prep",label:"Jun \u2013 Aug",weeks:13},{name:"Peak",label:"Sep \u2013 Dec",weeks:17},{name:"Tail",label:"Jan \u2013 Feb",weeks:9},{name:"Waitlist",label:"Mar \u2013 May",weeks:13}],i={fc:[.1,.65,.15,.1],ar:[.05,.35,.4,.2],session:[.1,.5,.25,.15]},D={mounted(){this.sliders={},this.displays={},this.el.querySelectorAll('input[type="range"]').forEach(e=>{let t=e.dataset.key;this.sliders[t]=e,this.displays[t]=this.el.querySelector(`[data-display="${t}"]`),e.addEventListener("input",()=>{this.updateDisplay(t),this.recalculate()})}),this.recalculate()},updateDisplay(e){let t=this.sliders[e],s=this.displays[e];if(!s)return;let r=parseFloat(t.value),c=t.dataset.format;c==="dollar"?s.textContent="$"+r.toLocaleString():c==="percent"?s.textContent=r+"%":s.textContent=r},recalculate(){let e=n=>parseFloat(this.sliders[n]?.value||0),t=e("base"),s=e("rev_share")/100,r=e("fc_price"),c=e("session_price"),a=e("ar_price"),h=e("fc_clients"),d=e("sessions"),u=e("ar_schools"),v=r*h,S=c*d,p=a*u,y=v+S+p,b=Math.round(y*s),A=t+b;this.setTextAll("annual_gross","$"+y.toLocaleString()),this.setTextAll("annual_share","$"+b.toLocaleString()),this.setTextAll("annual_base","$"+t.toLocaleString()),this.setTextAll("total_comp","$"+A.toLocaleString()),this.setTextAll("fc_revenue","$"+v.toLocaleString()),this.setTextAll("session_revenue","$"+S.toLocaleString()),this.setTextAll("ar_revenue","$"+p.toLocaleString()),this.setTextAll("summary_line",e("rev_share")+"% revenue share + $"+t.toLocaleString()+" base"),this.setTextAll("assumptions_line","Based on "+h+" full-cycle client"+(h!==1?"s":"")+", "+d+" session"+(d!==1?"s":"")+", and "+u+" app review school"+(u!==1?"s":"")+" per cycle.");let _=h*l.fc.billable,m=h*l.fc.overhead,x=u*l.ar.billable,w=u*l.ar.overhead,T=d*l.session.billable,k=d*l.session.overhead,E=70;R.forEach((n,o)=>{let q=_*i.fc[o]+x*i.ar[o]+T*i.session[o],M=m*i.fc[o]+w*i.ar[o]+k*i.session[o]+L*n.weeks,g=n.weeks>0?q/n.weeks:0,$=n.weeks>0?M/n.weeks:0,P=g+$;this.setTextAll("workload_"+o,Math.round(P)),document.querySelectorAll(`[data-workload-bar-billable="${o}"]`).forEach(f=>{f.style.width=Math.min(g/E*100,100)+"%"}),document.querySelectorAll(`[data-workload-bar-overhead="${o}"]`).forEach(f=>{f.style.width=Math.min($/E*100,100)+"%"})});let B=_+x+T,C=m+w+k,O=L*52;this.setTextAll("total_annual_hours",Math.round(B+C+O).toLocaleString()),this.setTextAll("fc_total_hrs",l.fc.billable+l.fc.overhead),this.setTextAll("session_total_hrs",l.session.billable+l.session.overhead),this.setTextAll("ar_total_hrs",l.ar.billable+l.ar.overhead),this.updateBars(t,b,A)},updateBars(e,t,s){if(s===0)return;let r=e/s*100,c=t/s*100;document.querySelectorAll('[data-bar="base"]').forEach(a=>{a.style.width=r+"%"}),document.querySelectorAll('[data-bar="share"]').forEach(a=>{a.style.width=c+"%"}),document.querySelectorAll('[data-bar-label="base"]').forEach(a=>{a.textContent="$"+e.toLocaleString()}),document.querySelectorAll('[data-bar-label="share"]').forEach(a=>{a.textContent="$"+t.toLocaleString()})},setTextAll(e,t){document.querySelectorAll(`[data-calc="${e}"]`).forEach(s=>{s.textContent=t})}},F=D;export{F 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.