@equisoft/tax-us 1.0.1-snapshot.20260107131539 → 1.0.1-snapshot.20260112201917
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/investments/life-income-fund.d.ts +6 -4
- package/dist/investments/life-income-fund.js +77 -8
- package/dist/investments/locked-in-retirement-account.d.ts +5 -5
- package/dist/investments/registered-education-savings-plan/tuition-fees.d.ts +3 -3
- package/dist/investments/registered-education-savings-plan/tuition-fees.js +58 -15
- package/dist/investments/tests/fixtures/locked-in-retirement-account.d.ts +2 -2
- package/dist/misc/code-types.d.ts +14 -3
- package/dist/misc/code-types.js +61 -2
- package/dist/taxes/dividend-credit.d.ts +23 -8
- package/dist/taxes/dividend-credit.js +22 -34
- package/dist/taxes/income-tax.d.ts +29 -20
- package/dist/taxes/income-tax.js +1188 -371
- package/dist/taxes/index.d.ts +0 -1
- package/dist/taxes/index.js +1 -1
- package/package.json +1 -1
|
@@ -1,11 +1,13 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { ByState, FederalCode, StateCode, ByProvince, FederalCanadaCode, ProvinceCode } from '../misc';
|
|
2
2
|
interface MaxWithdrawalPctByAge {
|
|
3
3
|
[key: number]: number;
|
|
4
4
|
}
|
|
5
|
-
export declare const
|
|
6
|
-
export declare const
|
|
5
|
+
export declare const state1MaxWithdrawalPct: MaxWithdrawalPctByAge;
|
|
6
|
+
export declare const state2MaxWithdrawalPct: MaxWithdrawalPctByAge;
|
|
7
7
|
export declare const othersMaxWithdrawalPct: MaxWithdrawalPctByAge;
|
|
8
8
|
export declare const federalMaxWithdrawalPct: MaxWithdrawalPctByAge;
|
|
9
|
-
export declare function getMaxWithdrawalPct(jurisdiction: ProvinceCode |
|
|
9
|
+
export declare function getMaxWithdrawalPct(jurisdiction: ProvinceCode | FederalCanadaCode, age: number): number;
|
|
10
|
+
export declare function getMaxWithdrawalPctUS(jurisdiction: StateCode | FederalCode, age: number): number;
|
|
10
11
|
export declare const YMPEUnlockingSmallBalance: ByProvince<number>;
|
|
12
|
+
export declare const YMPEUnlockingSmallBalanceUS: ByState<number>;
|
|
11
13
|
export {};
|
|
@@ -16,13 +16,14 @@ Revised
|
|
|
16
16
|
*/
|
|
17
17
|
// tslint:enable:max-line-length
|
|
18
18
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
19
|
-
exports.YMPEUnlockingSmallBalance = exports.federalMaxWithdrawalPct = exports.othersMaxWithdrawalPct = exports.
|
|
19
|
+
exports.YMPEUnlockingSmallBalanceUS = exports.YMPEUnlockingSmallBalance = exports.federalMaxWithdrawalPct = exports.othersMaxWithdrawalPct = exports.state2MaxWithdrawalPct = exports.state1MaxWithdrawalPct = void 0;
|
|
20
20
|
exports.getMaxWithdrawalPct = getMaxWithdrawalPct;
|
|
21
|
+
exports.getMaxWithdrawalPctUS = getMaxWithdrawalPctUS;
|
|
21
22
|
const utils_1 = require("../utils");
|
|
22
23
|
/* Alberta (AB), British Columbia (BC), Ontario (ON), New Brunswick (NB),
|
|
23
24
|
Newfoundland and Labrador (NL), Saskatchewan (SK)
|
|
24
25
|
*/
|
|
25
|
-
exports.
|
|
26
|
+
exports.state1MaxWithdrawalPct = {
|
|
26
27
|
51: 0.0627,
|
|
27
28
|
52: 0.0631,
|
|
28
29
|
53: 0.0635,
|
|
@@ -65,7 +66,7 @@ exports.province1MaxWithdrawalPct = {
|
|
|
65
66
|
90: 1,
|
|
66
67
|
};
|
|
67
68
|
// Quebec (QC), Manitoba (MB), Nova Scotia (NS)
|
|
68
|
-
exports.
|
|
69
|
+
exports.state2MaxWithdrawalPct = {
|
|
69
70
|
51: 0.0610,
|
|
70
71
|
52: 0.0610,
|
|
71
72
|
53: 0.0610,
|
|
@@ -253,7 +254,7 @@ exports.federalMaxWithdrawalPct = {
|
|
|
253
254
|
89: 1,
|
|
254
255
|
};
|
|
255
256
|
function getMaxWithdrawalPct(jurisdiction, age) {
|
|
256
|
-
const
|
|
257
|
+
const getAgeLimitByStateGroup = (group, biggest = true) => ((biggest)
|
|
257
258
|
? Math.max(...Object.keys(group).map(Number))
|
|
258
259
|
: Math.min(...Object.keys(group).map(Number)));
|
|
259
260
|
switch (jurisdiction) {
|
|
@@ -263,15 +264,25 @@ function getMaxWithdrawalPct(jurisdiction, age) {
|
|
|
263
264
|
case 'NB':
|
|
264
265
|
case 'NL':
|
|
265
266
|
case 'SK':
|
|
266
|
-
return exports.
|
|
267
|
+
return exports.state1MaxWithdrawalPct[(0, utils_1.clamp)(age, getAgeLimitByStateGroup(exports.state1MaxWithdrawalPct, false), getAgeLimitByStateGroup(exports.state1MaxWithdrawalPct))];
|
|
267
268
|
case 'QC':
|
|
268
269
|
case 'MB':
|
|
269
270
|
case 'NS':
|
|
270
|
-
return exports.
|
|
271
|
+
return exports.state2MaxWithdrawalPct[(0, utils_1.clamp)(age, getAgeLimitByStateGroup(exports.state2MaxWithdrawalPct, false), getAgeLimitByStateGroup(exports.state2MaxWithdrawalPct))];
|
|
271
272
|
case 'CA':
|
|
272
|
-
return exports.federalMaxWithdrawalPct[(0, utils_1.clamp)(age,
|
|
273
|
+
return exports.federalMaxWithdrawalPct[(0, utils_1.clamp)(age, getAgeLimitByStateGroup(exports.federalMaxWithdrawalPct, false), getAgeLimitByStateGroup(exports.federalMaxWithdrawalPct))];
|
|
273
274
|
default:
|
|
274
|
-
return exports.othersMaxWithdrawalPct[(0, utils_1.clamp)(age,
|
|
275
|
+
return exports.othersMaxWithdrawalPct[(0, utils_1.clamp)(age, getAgeLimitByStateGroup(exports.othersMaxWithdrawalPct, false), getAgeLimitByStateGroup(exports.othersMaxWithdrawalPct))];
|
|
276
|
+
}
|
|
277
|
+
}
|
|
278
|
+
function getMaxWithdrawalPctUS(jurisdiction, age) {
|
|
279
|
+
const getAgeLimitByStateGroup = (group, biggest = true) => ((biggest)
|
|
280
|
+
? Math.max(...Object.keys(group).map(Number))
|
|
281
|
+
: Math.min(...Object.keys(group).map(Number)));
|
|
282
|
+
switch (jurisdiction) {
|
|
283
|
+
case 'CA':
|
|
284
|
+
default:
|
|
285
|
+
return exports.othersMaxWithdrawalPct[(0, utils_1.clamp)(age, getAgeLimitByStateGroup(exports.othersMaxWithdrawalPct, false), getAgeLimitByStateGroup(exports.othersMaxWithdrawalPct))];
|
|
275
286
|
}
|
|
276
287
|
}
|
|
277
288
|
exports.YMPEUnlockingSmallBalance = {
|
|
@@ -289,3 +300,61 @@ exports.YMPEUnlockingSmallBalance = {
|
|
|
289
300
|
NU: 0.4,
|
|
290
301
|
YT: 0.4,
|
|
291
302
|
};
|
|
303
|
+
exports.YMPEUnlockingSmallBalanceUS = {
|
|
304
|
+
AL: 0.4,
|
|
305
|
+
AK: 0.4,
|
|
306
|
+
AZ: 0.4,
|
|
307
|
+
AR: 0.4,
|
|
308
|
+
CA: 0.4,
|
|
309
|
+
CO: 0.4,
|
|
310
|
+
CT: 0.4,
|
|
311
|
+
DE: 0.4,
|
|
312
|
+
FL: 0.4,
|
|
313
|
+
GA: 0.4,
|
|
314
|
+
HI: 0.4,
|
|
315
|
+
ID: 0.4,
|
|
316
|
+
IL: 0.4,
|
|
317
|
+
IN: 0.4,
|
|
318
|
+
IA: 0.4,
|
|
319
|
+
KS: 0.4,
|
|
320
|
+
KY: 0.4,
|
|
321
|
+
LA: 0.4,
|
|
322
|
+
ME: 0.4,
|
|
323
|
+
MD: 0.4,
|
|
324
|
+
MA: 0.4,
|
|
325
|
+
MI: 0.4,
|
|
326
|
+
MN: 0.4,
|
|
327
|
+
MS: 0.4,
|
|
328
|
+
MO: 0.4,
|
|
329
|
+
MT: 0.4,
|
|
330
|
+
NE: 0.4,
|
|
331
|
+
NV: 0.4,
|
|
332
|
+
NH: 0.4,
|
|
333
|
+
NJ: 0.4,
|
|
334
|
+
NM: 0.4,
|
|
335
|
+
NY: 0.4,
|
|
336
|
+
NC: 0.4,
|
|
337
|
+
ND: 0.4,
|
|
338
|
+
OH: 0.4,
|
|
339
|
+
OK: 0.4,
|
|
340
|
+
OR: 0.4,
|
|
341
|
+
PA: 0.4,
|
|
342
|
+
RI: 0.4,
|
|
343
|
+
SC: 0.4,
|
|
344
|
+
SD: 0.4,
|
|
345
|
+
TN: 0.4,
|
|
346
|
+
TX: 0.4,
|
|
347
|
+
UT: 0.4,
|
|
348
|
+
VT: 0.4,
|
|
349
|
+
VA: 0.4,
|
|
350
|
+
WA: 0.4,
|
|
351
|
+
WV: 0.4,
|
|
352
|
+
WI: 0.4,
|
|
353
|
+
WY: 0.4,
|
|
354
|
+
DC: 0.4,
|
|
355
|
+
AS: 0.4,
|
|
356
|
+
GU: 0.4,
|
|
357
|
+
MP: 0.4,
|
|
358
|
+
PR: 0.4,
|
|
359
|
+
VI: 0.4,
|
|
360
|
+
};
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { FederalCanadaCode, ProvinceCode } from '../misc';
|
|
2
2
|
export interface ConversionRule {
|
|
3
3
|
minimumAge: number;
|
|
4
4
|
maximumAge: number;
|
|
5
5
|
}
|
|
6
6
|
export declare const MAX_CONVERSION_AGE = 71;
|
|
7
|
-
export declare const getUnlockingPct: (jurisdiction: ProvinceCode |
|
|
8
|
-
export declare const getConversionRules: (jurisdiction: ProvinceCode |
|
|
9
|
-
export declare const canUnlock: (jurisdiction: ProvinceCode |
|
|
10
|
-
export declare const canConvert: (jurisdiction: ProvinceCode |
|
|
7
|
+
export declare const getUnlockingPct: (jurisdiction: ProvinceCode | FederalCanadaCode) => number | null;
|
|
8
|
+
export declare const getConversionRules: (jurisdiction: ProvinceCode | FederalCanadaCode) => ConversionRule | null;
|
|
9
|
+
export declare const canUnlock: (jurisdiction: ProvinceCode | FederalCanadaCode) => boolean;
|
|
10
|
+
export declare const canConvert: (jurisdiction: ProvinceCode | FederalCanadaCode, age: number) => boolean;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { ByState, StateCode } from '../../misc';
|
|
2
2
|
export interface TuitionFees {
|
|
3
|
-
TuitionFeesData:
|
|
4
|
-
|
|
3
|
+
TuitionFeesData: ByState<number>;
|
|
4
|
+
getTuitionFeesByStateCode(stateCode: StateCode): number;
|
|
5
5
|
}
|
|
6
6
|
export declare const TuitionFees: TuitionFees;
|
|
@@ -12,22 +12,65 @@
|
|
|
12
12
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
13
|
exports.TuitionFees = void 0;
|
|
14
14
|
const TuitionFeesData = {
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
15
|
+
AL: 0,
|
|
16
|
+
AK: 0,
|
|
17
|
+
AZ: 0,
|
|
18
|
+
AR: 0,
|
|
19
|
+
CA: 0,
|
|
20
|
+
CO: 0,
|
|
21
|
+
CT: 0,
|
|
22
|
+
DE: 0,
|
|
23
|
+
FL: 0,
|
|
24
|
+
GA: 0,
|
|
25
|
+
HI: 0,
|
|
26
|
+
ID: 0,
|
|
27
|
+
IL: 0,
|
|
28
|
+
IN: 0,
|
|
29
|
+
IA: 0,
|
|
30
|
+
KS: 0,
|
|
31
|
+
KY: 0,
|
|
32
|
+
LA: 0,
|
|
33
|
+
ME: 0,
|
|
34
|
+
MD: 0,
|
|
35
|
+
MA: 0,
|
|
36
|
+
MI: 0,
|
|
37
|
+
MN: 0,
|
|
38
|
+
MS: 0,
|
|
39
|
+
MO: 0,
|
|
40
|
+
MT: 0,
|
|
41
|
+
NE: 0,
|
|
42
|
+
NV: 0,
|
|
43
|
+
NH: 0,
|
|
44
|
+
NJ: 0,
|
|
45
|
+
NM: 0,
|
|
46
|
+
NY: 0,
|
|
47
|
+
NC: 0,
|
|
48
|
+
ND: 0,
|
|
49
|
+
OH: 0,
|
|
50
|
+
OK: 0,
|
|
51
|
+
OR: 0,
|
|
52
|
+
PA: 0,
|
|
53
|
+
RI: 0,
|
|
54
|
+
SC: 0,
|
|
55
|
+
SD: 0,
|
|
56
|
+
TN: 0,
|
|
57
|
+
TX: 0,
|
|
58
|
+
UT: 0,
|
|
59
|
+
VT: 0,
|
|
60
|
+
VA: 0,
|
|
61
|
+
WA: 0,
|
|
62
|
+
WV: 0,
|
|
63
|
+
WI: 0,
|
|
64
|
+
WY: 0,
|
|
65
|
+
DC: 0,
|
|
66
|
+
AS: 0,
|
|
67
|
+
GU: 0,
|
|
68
|
+
MP: 0,
|
|
69
|
+
PR: 0,
|
|
70
|
+
VI: 0,
|
|
28
71
|
};
|
|
29
|
-
const
|
|
72
|
+
const getTuitionFeesByStateCode = (stateCode) => TuitionFeesData[stateCode];
|
|
30
73
|
exports.TuitionFees = {
|
|
31
|
-
|
|
74
|
+
getTuitionFeesByStateCode,
|
|
32
75
|
TuitionFeesData,
|
|
33
76
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ByJurisdiction,
|
|
1
|
+
import { ByJurisdiction, FederalCanadaCode, ProvinceCode } from '../../../misc';
|
|
2
2
|
import { ConversionRule } from '../../locked-in-retirement-account';
|
|
3
3
|
export declare const mockedUnlockingPct: ByJurisdiction<number | null>;
|
|
4
4
|
export declare const mockedConversionRules: ByJurisdiction<ConversionRule | null>;
|
|
5
|
-
export declare const jurisdictions: (ProvinceCode |
|
|
5
|
+
export declare const jurisdictions: (ProvinceCode | FederalCanadaCode)[];
|
|
@@ -1,14 +1,25 @@
|
|
|
1
|
+
export type StateCode = 'AL' | 'AK' | 'AZ' | 'AR' | 'CA' | 'CO' | 'CT' | 'DE' | 'FL' | 'GA' | 'HI' | 'ID' | 'IL' | 'IN' | 'IA' | 'KS' | 'KY' | 'LA' | 'ME' | 'MD' | 'MA' | 'MI' | 'MN' | 'MS' | 'MO' | 'MT' | 'NE' | 'NV' | 'NH' | 'NJ' | 'NM' | 'NY' | 'NC' | 'ND' | 'OH' | 'OK' | 'OR' | 'PA' | 'RI' | 'SC' | 'SD' | 'TN' | 'TX' | 'UT' | 'VT' | 'VA' | 'WA' | 'WV' | 'WI' | 'WY' | 'DC' | 'AS' | 'GU' | 'MP' | 'PR' | 'VI';
|
|
1
2
|
export type ProvinceCode = 'AB' | 'BC' | 'MB' | 'NB' | 'NL' | 'NS' | 'PE' | 'ON' | 'QC' | 'SK' | 'NT' | 'NU' | 'YT';
|
|
2
|
-
export type FederalCode = '
|
|
3
|
-
export type
|
|
3
|
+
export type FederalCode = 'FEDERAL';
|
|
4
|
+
export type FederalCanadaCode = 'CA';
|
|
5
|
+
export type FederalCanadaName = 'CANADA';
|
|
6
|
+
export type FederalName = 'UNITED_STATES';
|
|
4
7
|
export type ProvinceName = 'ALBERTA' | 'BRITISH_COLUMBIA' | 'MANITOBA' | 'NEW_BRUNSWICK' | 'NEWFOUNDLAND' | 'NOVA_SCOTIA' | 'PRINCE_EDWARD_ISLAND' | 'ONTARIO' | 'QUEBEC' | 'SASKATCHEWAN' | 'NORTHWEST_TERRITORIES' | 'NUNAVUT' | 'YUKON';
|
|
8
|
+
export type StateName = 'ALABAMA' | 'ALASKA' | 'ARIZONA' | 'ARKANSAS' | 'CALIFORNIA' | 'COLORADO' | 'CONNECTICUT' | 'DELAWARE' | 'FLORIDA' | 'GEORGIA' | 'HAWAII' | 'IDAHO' | 'ILLINOIS' | 'INDIANA' | 'IOWA' | 'KANSAS' | 'KENTUCKY' | 'LOUISIANA' | 'MAINE' | 'MARYLAND' | 'MASSACHUSETTS' | 'MICHIGAN' | 'MINNESOTA' | 'MISSISSIPPI' | 'MISSOURI' | 'MONTANA' | 'NEBRASKA' | 'NEVADA' | 'NEW_HAMPSHIRE' | 'NEW_JERSEY' | 'NEW_MEXICO' | 'NEW_YORK' | 'NORTH_CAROLINA' | 'NORTH_DAKOTA' | 'OHIO' | 'OKLAHOMA' | 'OREGON' | 'PENNSYLVANIA' | 'RHODE_ISLAND' | 'SOUTH_CAROLINA' | 'SOUTH_DAKOTA' | 'TENNESSEE' | 'TEXAS' | 'UTAH' | 'VERMONT' | 'VIRGINIA' | 'WASHINGTON' | 'WEST_VIRGINIA' | 'WISCONSIN' | 'WYOMING' | 'DISTRICT_OF_COLUMBIA' | 'AMERICAN_SAMOA' | 'GUAM' | 'NORTHERN_MARIANA_ISLANDS' | 'PUERTO_RICO' | 'VIRGIN_ISLANDS';
|
|
5
9
|
export declare const PROVINCIAL_CODES: {
|
|
6
10
|
[key in ProvinceName]: ProvinceCode;
|
|
7
11
|
};
|
|
12
|
+
export declare const STATE_CODES: {
|
|
13
|
+
[key in StateName]: StateCode;
|
|
14
|
+
};
|
|
8
15
|
export declare const FEDERAL_CODE: FederalCode;
|
|
16
|
+
export declare const FEDERAL_CANADA_CODE: FederalCanadaCode;
|
|
9
17
|
export type ByProvince<T> = {
|
|
10
18
|
[key in ProvinceCode]: T;
|
|
11
19
|
};
|
|
20
|
+
export type ByState<T> = {
|
|
21
|
+
[key in StateCode]: T;
|
|
22
|
+
};
|
|
12
23
|
export type ByJurisdiction<T> = {
|
|
13
|
-
[key in ProvinceCode |
|
|
24
|
+
[key in ProvinceCode | FederalCanadaCode]: T;
|
|
14
25
|
};
|
package/dist/misc/code-types.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.FEDERAL_CODE = exports.PROVINCIAL_CODES = void 0;
|
|
3
|
+
exports.FEDERAL_CANADA_CODE = exports.FEDERAL_CODE = exports.STATE_CODES = exports.PROVINCIAL_CODES = void 0;
|
|
4
4
|
exports.PROVINCIAL_CODES = {
|
|
5
5
|
ALBERTA: 'AB',
|
|
6
6
|
BRITISH_COLUMBIA: 'BC',
|
|
@@ -16,4 +16,63 @@ exports.PROVINCIAL_CODES = {
|
|
|
16
16
|
NUNAVUT: 'NU',
|
|
17
17
|
YUKON: 'YT',
|
|
18
18
|
};
|
|
19
|
-
exports.
|
|
19
|
+
exports.STATE_CODES = {
|
|
20
|
+
ALABAMA: 'AL',
|
|
21
|
+
ALASKA: 'AK',
|
|
22
|
+
ARIZONA: 'AZ',
|
|
23
|
+
ARKANSAS: 'AR',
|
|
24
|
+
CALIFORNIA: 'CA',
|
|
25
|
+
COLORADO: 'CO',
|
|
26
|
+
CONNECTICUT: 'CT',
|
|
27
|
+
DELAWARE: 'DE',
|
|
28
|
+
FLORIDA: 'FL',
|
|
29
|
+
GEORGIA: 'GA',
|
|
30
|
+
HAWAII: 'HI',
|
|
31
|
+
IDAHO: 'ID',
|
|
32
|
+
ILLINOIS: 'IL',
|
|
33
|
+
INDIANA: 'IN',
|
|
34
|
+
IOWA: 'IA',
|
|
35
|
+
KANSAS: 'KS',
|
|
36
|
+
KENTUCKY: 'KY',
|
|
37
|
+
LOUISIANA: 'LA',
|
|
38
|
+
MAINE: 'ME',
|
|
39
|
+
MARYLAND: 'MD',
|
|
40
|
+
MASSACHUSETTS: 'MA',
|
|
41
|
+
MICHIGAN: 'MI',
|
|
42
|
+
MINNESOTA: 'MN',
|
|
43
|
+
MISSISSIPPI: 'MS',
|
|
44
|
+
MISSOURI: 'MO',
|
|
45
|
+
MONTANA: 'MT',
|
|
46
|
+
NEBRASKA: 'NE',
|
|
47
|
+
NEVADA: 'NV',
|
|
48
|
+
NEW_HAMPSHIRE: 'NH',
|
|
49
|
+
NEW_JERSEY: 'NJ',
|
|
50
|
+
NEW_MEXICO: 'NM',
|
|
51
|
+
NEW_YORK: 'NY',
|
|
52
|
+
NORTH_CAROLINA: 'NC',
|
|
53
|
+
NORTH_DAKOTA: 'ND',
|
|
54
|
+
OHIO: 'OH',
|
|
55
|
+
OKLAHOMA: 'OK',
|
|
56
|
+
OREGON: 'OR',
|
|
57
|
+
PENNSYLVANIA: 'PA',
|
|
58
|
+
RHODE_ISLAND: 'RI',
|
|
59
|
+
SOUTH_CAROLINA: 'SC',
|
|
60
|
+
SOUTH_DAKOTA: 'SD',
|
|
61
|
+
TENNESSEE: 'TN',
|
|
62
|
+
TEXAS: 'TX',
|
|
63
|
+
UTAH: 'UT',
|
|
64
|
+
VERMONT: 'VT',
|
|
65
|
+
VIRGINIA: 'VA',
|
|
66
|
+
WASHINGTON: 'WA',
|
|
67
|
+
WEST_VIRGINIA: 'WV',
|
|
68
|
+
WISCONSIN: 'WI',
|
|
69
|
+
WYOMING: 'WY',
|
|
70
|
+
DISTRICT_OF_COLUMBIA: 'DC',
|
|
71
|
+
AMERICAN_SAMOA: 'AS',
|
|
72
|
+
GUAM: 'GU',
|
|
73
|
+
NORTHERN_MARIANA_ISLANDS: 'MP',
|
|
74
|
+
PUERTO_RICO: 'PR',
|
|
75
|
+
VIRGIN_ISLANDS: 'VI',
|
|
76
|
+
};
|
|
77
|
+
exports.FEDERAL_CODE = 'FEDERAL';
|
|
78
|
+
exports.FEDERAL_CANADA_CODE = 'CA';
|
|
@@ -1,8 +1,23 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
1
|
+
/** export type DividendTaxCreditRate =
|
|
2
|
+
{ GROSS_UP: number; } &
|
|
3
|
+
{ [key in StateCode | FederalCode]: number; };* */
|
|
4
|
+
/** export const NON_ELIGIBLE_DIVIDEND: DividendTaxCreditRate = {
|
|
5
|
+
GROSS_UP: 1.15,
|
|
6
|
+
FEDERAL: 0.0,
|
|
7
|
+
AL: 0.0, AK: 0.0, AZ: 0.0, AR: 0.0, CA: 0.0, CO: 0.0, CT: 0.0, DE: 0.0, FL: 0.0, GA: 0.0,
|
|
8
|
+
HI: 0.0, ID: 0.0, IL: 0.0, IN: 0.0, IA: 0.0, KS: 0.0, KY: 0.0, LA: 0.0, ME: 0.0, MD: 0.0,
|
|
9
|
+
MA: 0.0, MI: 0.0, MN: 0.0, MS: 0.0, MO: 0.0, MT: 0.0, NE: 0.0, NV: 0.0, NH: 0.0, NJ: 0.0,
|
|
10
|
+
NM: 0.0, NY: 0.0, NC: 0.0, ND: 0.0, OH: 0.0, OK: 0.0, OR: 0.0, PA: 0.0, RI: 0.0, SC: 0.0,
|
|
11
|
+
SD: 0.0, TN: 0.0, TX: 0.0, UT: 0.0, VT: 0.0, VA: 0.0, WA: 0.0, WV: 0.0, WI: 0.0, WY: 0.0,
|
|
12
|
+
DC: 0.0, AS: 0.0, GU: 0.0, MP: 0.0, PR: 0.0, VI: 0.0,
|
|
13
|
+
};* */
|
|
14
|
+
/** export const ELIGIBLE_DIVIDEND: DividendTaxCreditRate = {
|
|
15
|
+
GROSS_UP: 1.38,
|
|
16
|
+
FEDERAL: 0.0,
|
|
17
|
+
AL: 0.0, AK: 0.0, AZ: 0.0, AR: 0.0, CA: 0.0, CO: 0.0, CT: 0.0, DE: 0.0, FL: 0.0, GA: 0.0,
|
|
18
|
+
HI: 0.0, ID: 0.0, IL: 0.0, IN: 0.0, IA: 0.0, KS: 0.0, KY: 0.0, LA: 0.0, ME: 0.0, MD: 0.0,
|
|
19
|
+
MA: 0.0, MI: 0.0, MN: 0.0, MS: 0.0, MO: 0.0, MT: 0.0, NE: 0.0, NV: 0.0, NH: 0.0, NJ: 0.0,
|
|
20
|
+
NM: 0.0, NY: 0.0, NC: 0.0, ND: 0.0, OH: 0.0, OK: 0.0, OR: 0.0, PA: 0.0, RI: 0.0, SC: 0.0,
|
|
21
|
+
SD: 0.0, TN: 0.0, TX: 0.0, UT: 0.0, VT: 0.0, VA: 0.0, WA: 0.0, WV: 0.0, WI: 0.0, WY: 0.0,
|
|
22
|
+
DC: 0.0, AS: 0.0, GU: 0.0, MP: 0.0, PR: 0.0, VI: 0.0,
|
|
23
|
+
};* */
|
|
@@ -7,39 +7,27 @@ Sources
|
|
|
7
7
|
Revised
|
|
8
8
|
2024-12-24
|
|
9
9
|
*/
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
10
|
+
// import { FederalCode, StateCode } from '../misc';
|
|
11
|
+
/** export type DividendTaxCreditRate =
|
|
12
|
+
{ GROSS_UP: number; } &
|
|
13
|
+
{ [key in StateCode | FederalCode]: number; };* */
|
|
14
|
+
/** export const NON_ELIGIBLE_DIVIDEND: DividendTaxCreditRate = {
|
|
13
15
|
GROSS_UP: 1.15,
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
ON: 0.029863,
|
|
24
|
-
PE: 0.013,
|
|
25
|
-
QC: 0.0342,
|
|
26
|
-
SK: 0.02938,
|
|
27
|
-
YT: 0.0067,
|
|
28
|
-
};
|
|
29
|
-
exports.ELIGIBLE_DIVIDEND = {
|
|
16
|
+
FEDERAL: 0.0,
|
|
17
|
+
AL: 0.0, AK: 0.0, AZ: 0.0, AR: 0.0, CA: 0.0, CO: 0.0, CT: 0.0, DE: 0.0, FL: 0.0, GA: 0.0,
|
|
18
|
+
HI: 0.0, ID: 0.0, IL: 0.0, IN: 0.0, IA: 0.0, KS: 0.0, KY: 0.0, LA: 0.0, ME: 0.0, MD: 0.0,
|
|
19
|
+
MA: 0.0, MI: 0.0, MN: 0.0, MS: 0.0, MO: 0.0, MT: 0.0, NE: 0.0, NV: 0.0, NH: 0.0, NJ: 0.0,
|
|
20
|
+
NM: 0.0, NY: 0.0, NC: 0.0, ND: 0.0, OH: 0.0, OK: 0.0, OR: 0.0, PA: 0.0, RI: 0.0, SC: 0.0,
|
|
21
|
+
SD: 0.0, TN: 0.0, TX: 0.0, UT: 0.0, VT: 0.0, VA: 0.0, WA: 0.0, WV: 0.0, WI: 0.0, WY: 0.0,
|
|
22
|
+
DC: 0.0, AS: 0.0, GU: 0.0, MP: 0.0, PR: 0.0, VI: 0.0,
|
|
23
|
+
};* */
|
|
24
|
+
/** export const ELIGIBLE_DIVIDEND: DividendTaxCreditRate = {
|
|
30
25
|
GROSS_UP: 1.38,
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
NU: 0.0551,
|
|
40
|
-
ON: 0.1,
|
|
41
|
-
PE: 0.105,
|
|
42
|
-
QC: 0.117,
|
|
43
|
-
SK: 0.11,
|
|
44
|
-
YT: 0.1202,
|
|
45
|
-
};
|
|
26
|
+
FEDERAL: 0.0,
|
|
27
|
+
AL: 0.0, AK: 0.0, AZ: 0.0, AR: 0.0, CA: 0.0, CO: 0.0, CT: 0.0, DE: 0.0, FL: 0.0, GA: 0.0,
|
|
28
|
+
HI: 0.0, ID: 0.0, IL: 0.0, IN: 0.0, IA: 0.0, KS: 0.0, KY: 0.0, LA: 0.0, ME: 0.0, MD: 0.0,
|
|
29
|
+
MA: 0.0, MI: 0.0, MN: 0.0, MS: 0.0, MO: 0.0, MT: 0.0, NE: 0.0, NV: 0.0, NH: 0.0, NJ: 0.0,
|
|
30
|
+
NM: 0.0, NY: 0.0, NC: 0.0, ND: 0.0, OH: 0.0, OK: 0.0, OR: 0.0, PA: 0.0, RI: 0.0, SC: 0.0,
|
|
31
|
+
SD: 0.0, TN: 0.0, TX: 0.0, UT: 0.0, VT: 0.0, VA: 0.0, WA: 0.0, WV: 0.0, WI: 0.0, WY: 0.0,
|
|
32
|
+
DC: 0.0, AS: 0.0, GU: 0.0, MP: 0.0, PR: 0.0, VI: 0.0,
|
|
33
|
+
};* */
|
|
@@ -1,39 +1,48 @@
|
|
|
1
|
-
import { FederalCode,
|
|
1
|
+
import { FederalCode, StateCode } from '../misc';
|
|
2
2
|
export interface Rate {
|
|
3
3
|
FROM: number;
|
|
4
|
-
TO: number;
|
|
5
4
|
RATE: number;
|
|
5
|
+
TO: number;
|
|
6
6
|
}
|
|
7
7
|
export interface TaxBracket {
|
|
8
8
|
ABATEMENT: number;
|
|
9
|
-
TAX_CREDIT_RATE: number;
|
|
10
9
|
BASE_TAX_CREDIT: number;
|
|
11
10
|
RATES: Rate[];
|
|
12
|
-
|
|
11
|
+
TAX_CREDIT_RATE: number;
|
|
13
12
|
}
|
|
14
13
|
export type TaxBrackets = {
|
|
15
|
-
[key in
|
|
14
|
+
[key in StateCode | FederalCode]: TaxBracket;
|
|
16
15
|
};
|
|
17
16
|
export declare const CA_LOWEST_TAX_RATE_2025 = 0.145;
|
|
18
17
|
export declare const TAX_BRACKETS: TaxBrackets;
|
|
19
18
|
export declare function getTaxAmount(rates: Rate[], income: number, inflationRate: number, yearsToInflate: number): number;
|
|
20
19
|
export declare function getRate(brackets: Rate[], grossIncome: number, inflationRate: number, yearsToInflate: number): number;
|
|
21
|
-
export declare function getTaxRates(code:
|
|
20
|
+
export declare function getTaxRates(code: StateCode | FederalCode): Rate[];
|
|
21
|
+
/** function getSurtaxRates(code: StateCode | FederalCode): Rate[] {
|
|
22
|
+
return structuredClone(TAX_BRACKETS[code].SURTAX_RATES);
|
|
23
|
+
}* */
|
|
22
24
|
export declare function getFederalTaxRates(yearsToInflate: number): Rate[];
|
|
23
25
|
export declare function getFederalBaseTaxAmount(grossIncome: number, inflationRate?: number, yearsToInflate?: number): number;
|
|
24
26
|
export declare function getFederalTaxCreditRate(yearsToInflate: number): number;
|
|
25
27
|
export declare function getFederalBaseCredit(inflationRate: number, yearsToInflate: number): number;
|
|
26
|
-
export declare function
|
|
27
|
-
export declare function getFederalTaxAmount(provincialCode:
|
|
28
|
-
export
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
export declare function
|
|
37
|
-
export declare function
|
|
38
|
-
export declare function
|
|
39
|
-
export declare function
|
|
28
|
+
export declare function getStateAbatement(state: StateCode, federalTaxAmount: number): number;
|
|
29
|
+
export declare function getFederalTaxAmount(provincialCode: StateCode, grossIncome: number, inflationRate?: number, yearsToInflate?: number, taxCredit?: number): number;
|
|
30
|
+
/** export function getProvincialSurtaxAmount(
|
|
31
|
+
state: StateCode,
|
|
32
|
+
baseTaxAmount: number,
|
|
33
|
+
inflationRate = 0,
|
|
34
|
+
yearsToInflate = 0,
|
|
35
|
+
): number {
|
|
36
|
+
return getTaxAmount(getSurtaxRates(state), baseTaxAmount, inflationRate, yearsToInflate);
|
|
37
|
+
}* */
|
|
38
|
+
export declare function getStateBaseTaxAmount(state: StateCode, grossIncome: number, inflationRate?: number, yearsToInflate?: number): number;
|
|
39
|
+
export declare function getStateBaseCredit(state: StateCode, inflationRate: number, yearsToInflate: number): number;
|
|
40
|
+
export declare function getStateTaxAmount(state: StateCode, grossIncome: number, inflationRate?: number, yearsToInflate?: number, taxCredit?: number): number;
|
|
41
|
+
export declare function getFederalMarginalRate(provincialCode: StateCode, grossIncome: number, inflationRate?: number, yearsToInflate?: number): number;
|
|
42
|
+
export declare function getStateMarginalRate(provincialCode: StateCode, grossIncome: number, inflationRate?: number, yearsToInflate?: number): number;
|
|
43
|
+
export declare function getTotalMarginalRate(provincialCode: StateCode, grossIncome: number, inflationRate?: number, yearsToInflate?: number): number;
|
|
44
|
+
export declare function getMaxStateMarginalRate(provincialCode: StateCode): number;
|
|
45
|
+
export declare function getMaxFederalMarginalRate(provincialCode: StateCode): number;
|
|
46
|
+
export declare function getTotalMaxMarginalRate(provincialCode: StateCode): number;
|
|
47
|
+
export declare function getTotalTaxAmount(provincialCode: StateCode, grossIncome: number, inflationRate?: number, yearsToInflate?: number): number;
|
|
48
|
+
export declare function getEffectiveRate(state: StateCode, income: number, inflationRate?: number, yearsToInflate?: number): number;
|