]> git.scottworley.com Git - inverse-tax/blame - index.html
load_tax_table: Optional deductible
[inverse-tax] / index.html
CommitLineData
0993d859
SW
1<!DOCTYPE html>
2<html>
3<head>
4<script src="tax.js"></script>
d0678fe5 5<script src="tax_ui.js"></script>
52ca3d7f 6<!-- Tests are in tax.test.js -->
d0678fe5
SW
7<style>
8 td { padding: .5em; vertical-align: top}
9 textarea { height: 12em; }
10 input { width: 7em }
7a5e093a
SW
11 .output { padding: 1em; background-color: #eee; border: thin solid #888; width: max-content; }
12 .privacy_policy { margin-top: 5em; }
d0678fe5 13</style>
0993d859 14</head>
d0678fe5
SW
15<body onload="calculate()">
16<h1>Inverse income tax tool</h1>
151ede0f 17<p>What before-tax salary is needed to provide a specified after-tax salary?</p>
d0678fe5
SW
18
19<form>
20<table>
21<tr>
22<td>
f0d01493 23Federal deductible<br/><input id="deductible_1" value="27700" onchange="calculate()" oninput="calculate()"/>
d0678fe5
SW
24</td>
25<td>
f0d01493 26State deductible<br/><input id="deductible_2" value="10404" onchange="calculate()" oninput="calculate()"/>
d0678fe5
SW
27</td>
28</tr>
29<tr>
30<td>
31Federal tax table<br/>
86fe1a72 32<textarea id="tax_table_1" onchange="calculate()" oninput="calculate()"> 0 10
f0d01493
SW
33 22000 12
34 89450 22
35190750 24
36364200 32
37462500 32
38683750 35</textarea>
d0678fe5
SW
39</td>
40<td>
41State tax table<br/>
86fe1a72 42<textarea id="tax_table_2" onchange="calculate()" oninput="calculate()"> 0 1
f0d01493
SW
43 20198 2
44 47884 4
45 76576 6
46 104910 8
47 132590 9.3
48 677278 10.3
49 812728 11.3
501354550 12.3</textarea>
d0678fe5
SW
51<br/>(Initial table is California's)
52</td>
53</tr>
54<tr>
55<td colspan="2">
56Desired after-tax salary</br>
57<input id="after_tax" value="100000" onchange="calculate()" oninput="calculate()">
58</td></tr>
59</table>
60</form>
61
7a5e093a
SW
62<p class="output">
63 <strong><span id="before_tax"></span> before tax</strong>
64 - <span id="tax_1"></span> federal tax
65 - <span id="tax_2"></span> state tax
66 = <span id="after_tax_verification"></span> after tax.
67</p>
d0678fe5 68
7a5e093a 69<p class="privacy_policy">Privacy policy: All calculations are client-side; no figures are sent to any server.</p>
0993d859
SW
70</body>
71</html>