@casomoltd/nhs-pay 0.30.0 → 0.32.0
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/README.md +71 -252
- package/dist/bands.d.ts +9 -1
- package/dist/bands.js +20 -0
- package/dist/bands.js.map +1 -1
- package/dist/document-source.d.ts +32 -7
- package/dist/document-source.js +32 -8
- package/dist/document-source.js.map +1 -1
- package/dist/errors.d.ts +57 -11
- package/dist/errors.js +85 -28
- package/dist/errors.js.map +1 -1
- package/dist/factor-basis.d.ts +23 -3
- package/dist/factor-basis.js +40 -28
- package/dist/factor-basis.js.map +1 -1
- package/dist/index.d.ts +16 -14
- package/dist/index.js +9 -8
- package/dist/index.js.map +1 -1
- package/dist/member/benefits.js +25 -13
- package/dist/member/benefits.js.map +1 -1
- package/dist/member/index.d.ts +1 -1
- package/dist/member/input-period.d.ts +4 -4
- package/dist/member/input-period.js +11 -9
- package/dist/member/input-period.js.map +1 -1
- package/dist/member/service.d.ts +4 -0
- package/dist/member/service.js +9 -3
- package/dist/member/service.js.map +1 -1
- package/dist/member/types.d.ts +81 -49
- package/dist/member/types.js.map +1 -1
- package/dist/member/valuation.d.ts +10 -8
- package/dist/member/valuation.js +14 -21
- package/dist/member/valuation.js.map +1 -1
- package/dist/pay-path.d.ts +21 -25
- package/dist/pay-path.js +85 -67
- package/dist/pay-path.js.map +1 -1
- package/dist/pension/ages.d.ts +6 -4
- package/dist/pension/ages.js +6 -4
- package/dist/pension/ages.js.map +1 -1
- package/dist/pension/curve.d.ts +2 -1
- package/dist/pension/curve.js +15 -7
- package/dist/pension/curve.js.map +1 -1
- package/dist/pension/history.d.ts +18 -3
- package/dist/pension/history.js +12 -5
- package/dist/pension/history.js.map +1 -1
- package/dist/pension/ledger.d.ts +15 -9
- package/dist/pension/ledger.js +95 -59
- package/dist/pension/ledger.js.map +1 -1
- package/dist/pension/money.d.ts +2 -0
- package/dist/pension/money.js +4 -0
- package/dist/pension/money.js.map +1 -1
- package/dist/pension/prices.d.ts +11 -2
- package/dist/pension/prices.js +35 -14
- package/dist/pension/prices.js.map +1 -1
- package/dist/pension/scheme-year.d.ts +59 -0
- package/dist/pension/scheme-year.js +80 -0
- package/dist/pension/scheme-year.js.map +1 -0
- package/dist/pension/seed.d.ts +66 -50
- package/dist/pension/seed.js +111 -65
- package/dist/pension/seed.js.map +1 -1
- package/dist/pension/uplift.d.ts +38 -54
- package/dist/pension/uplift.js +38 -68
- package/dist/pension/uplift.js.map +1 -1
- package/dist/pension-projection.js +30 -22
- package/dist/pension-projection.js.map +1 -1
- package/dist/post.d.ts +1 -10
- package/dist/post.js +1 -12
- package/dist/post.js.map +1 -1
- package/dist/revaluation.d.ts +56 -41
- package/dist/revaluation.js +76 -62
- package/dist/revaluation.js.map +1 -1
- package/dist/scale-point.d.ts +6 -0
- package/dist/sections/final-salary.d.ts +3 -8
- package/dist/sections/final-salary.js +6 -10
- package/dist/sections/final-salary.js.map +1 -1
- package/dist/sections/section-2015.d.ts +3 -4
- package/dist/sections/section-2015.js +1 -1
- package/dist/sections/section-2015.js.map +1 -1
- package/dist/sources.d.ts +14 -0
- package/dist/sources.js +24 -0
- package/dist/sources.js.map +1 -1
- package/dist/take-home.d.ts +4 -20
- package/dist/take-home.js +3 -23
- package/dist/take-home.js.map +1 -1
- package/package.json +3 -3
package/dist/revaluation.d.ts
CHANGED
|
@@ -20,20 +20,27 @@
|
|
|
20
20
|
*
|
|
21
21
|
* "HM Treasury HCWS437 — Public Service Pension
|
|
22
22
|
* Scheme Indexation and Revaluation 2025", the
|
|
23
|
-
* Chief Secretary's annual written ministerial statement.
|
|
24
|
-
*
|
|
25
|
-
*
|
|
26
|
-
*
|
|
23
|
+
* Chief Secretary's annual written ministerial statement. It
|
|
24
|
+
* states why the date moved to 6 April, and its per-scheme table
|
|
25
|
+
* is a source of the applied-rate fixture, independent of the
|
|
26
|
+
* Order and of the valuation report.
|
|
27
27
|
*
|
|
28
28
|
* "SPPA NHS Circular 2023/01 — pension indexation and CARE
|
|
29
29
|
* revaluation" — the clearest annual statement of the exact NHS
|
|
30
30
|
* in-service rate. Scotland, but the same CPI + 1.5% rule and
|
|
31
|
-
* the same rate as England and Wales.
|
|
31
|
+
* the same rate as England and Wales. A rate source only: the
|
|
32
|
+
* date it gives, 10 April 2023, is superseded by SI 2023/252
|
|
33
|
+
* art 1(3), which brings the Order into force on 6 April 2023
|
|
34
|
+
* for all four NHS 2015 schemes (Northern Ireland's by NISR
|
|
35
|
+
* 2023/54 art 1(3)(b)).
|
|
32
36
|
*
|
|
33
37
|
* "NHS Pension Scheme Valuation Report 2020", Appendix E
|
|
34
38
|
* "Inter-valuation events" — the in-service revaluation as
|
|
35
|
-
* ACTUALLY APPLIED,
|
|
36
|
-
*
|
|
39
|
+
* ACTUALLY APPLIED, each year commencing April 2016 to April 2023,
|
|
40
|
+
* independent of the orders. No rate is transcribed here: each
|
|
41
|
+
* year's `activeRatePct` is the rule applied to the Order's CPI,
|
|
42
|
+
* and the applied rates are the test oracle in
|
|
43
|
+
* `tests/fixtures/revaluation-applied.csv`.
|
|
37
44
|
*
|
|
38
45
|
* "SI 2015/94 Sch 9 para 3 — revaluation": the NHS Pension
|
|
39
46
|
* Scheme Regulations 2015 add 1.5 to the prices "increase or
|
|
@@ -43,31 +50,32 @@
|
|
|
43
50
|
* "NHSBSA KA-02728 — how your pension is revalued", on how it is
|
|
44
51
|
* applied to members and on the date change below.
|
|
45
52
|
*
|
|
46
|
-
*
|
|
47
|
-
* Annual Benefit Statement (2015 Section, updated
|
|
48
|
-
* 31/03/2025; name and membership number redacted)
|
|
49
|
-
*
|
|
50
|
-
*
|
|
51
|
-
*
|
|
52
|
-
* here: the earnings beside that column are the member's.
|
|
53
|
+
* The fixture is cross-checked against the "Revaluation" column
|
|
54
|
+
* of a member's Annual Benefit Statement (2015 Section, updated
|
|
55
|
+
* to 31/03/2025; name and membership number redacted): the rates
|
|
56
|
+
* as actually applied to a real record, rather than as
|
|
57
|
+
* legislated. Nothing else from that document is used: the
|
|
58
|
+
* earnings beside that column are the member's.
|
|
53
59
|
* Archived as "Annual Benefit Statement, 2015 Section,
|
|
54
60
|
* redacted" — see docs/source-archive.md.
|
|
55
61
|
*
|
|
56
62
|
* ── Three facts this data carries ───────────────────
|
|
57
63
|
*
|
|
58
|
-
* **The revaluation date
|
|
59
|
-
*
|
|
60
|
-
* annual allowance
|
|
61
|
-
*
|
|
64
|
+
* **The revaluation date is not fixed.** It is 1 April through
|
|
65
|
+
* 2022 and 6 April from 2023, to manage the interaction with the
|
|
66
|
+
* annual allowance; for 2023 the operative instrument is SI
|
|
67
|
+
* 2023/252 art 1(3), which names 6 April for the NHS schemes.
|
|
68
|
+
* `appliedOn` records it per year rather than letting a
|
|
69
|
+
* scheme-year boundary be assumed.
|
|
62
70
|
*
|
|
63
71
|
* **CPI is sourced independently of the rate**, never derived
|
|
64
|
-
* from it. Taking `septemberCpiPct =
|
|
72
|
+
* from it. Taking `septemberCpiPct = rate - 1.5` would make
|
|
65
73
|
* the test that checks the +1.5 rule agree with itself, which
|
|
66
|
-
* is no test at all. So the two
|
|
67
|
-
*
|
|
68
|
-
*
|
|
69
|
-
*
|
|
70
|
-
* table
|
|
74
|
+
* is no test at all. So the two come from documents that do
|
|
75
|
+
* not cite each other: prices here, from each Treasury Order's
|
|
76
|
+
* own operative words, and the rate AS APPLIED in a test
|
|
77
|
+
* fixture, from the 2020 valuation report's inter-valuation
|
|
78
|
+
* table and a member's statement.
|
|
71
79
|
*
|
|
72
80
|
* **A negative prices figure is carried through, not floored.**
|
|
73
81
|
* September 2015 CPI was -0.1% and the 2016 order specifies a
|
|
@@ -86,9 +94,9 @@
|
|
|
86
94
|
* in-service revaluation was applied in April 2016. All eleven
|
|
87
95
|
* years to 2026 are here, which is what lets a projection walk
|
|
88
96
|
* a member's whole membership rather than only the part since
|
|
89
|
-
* their statement. `revaluationFor`
|
|
90
|
-
*
|
|
91
|
-
*
|
|
97
|
+
* their statement. `revaluationFor` returns null rather than
|
|
98
|
+
* guessing for a year not held: one before 2016, or one whose
|
|
99
|
+
* order has not yet been made.
|
|
92
100
|
*
|
|
93
101
|
* ── Not this table ──────────────────────────────────
|
|
94
102
|
*
|
|
@@ -97,15 +105,15 @@
|
|
|
97
105
|
* different instrument. For 1995/2008 practitioners the
|
|
98
106
|
* equivalent uplift is earnings dynamisation, not this.
|
|
99
107
|
*/
|
|
108
|
+
import type { SchemeYearEnd } from './pension/scheme-year.js';
|
|
109
|
+
import type { IsoDate } from './iso-date.js';
|
|
100
110
|
/** One scheme year's revaluation, and what set it. */
|
|
101
111
|
export interface RevaluationYear {
|
|
102
112
|
/** Scheme year END, e.g. 2022 for the 2021/22 year. */
|
|
103
|
-
readonly yearEnd:
|
|
113
|
+
readonly yearEnd: SchemeYearEnd;
|
|
104
114
|
/** The Treasury Order prices figure — the previous
|
|
105
115
|
* September's CPI, as a percentage. Sourced, not derived. */
|
|
106
116
|
readonly septemberCpiPct: number;
|
|
107
|
-
/** The in-service revaluation applied, as a percentage. */
|
|
108
|
-
readonly ratePct: number;
|
|
109
117
|
/** ISO date the MEMBER'S POT moves — not the date the order
|
|
110
118
|
* commences. Every Revaluation Order commences 1 April; the
|
|
111
119
|
* NHS scheme moved its own application to 6 April from 2023
|
|
@@ -118,29 +126,36 @@ export interface RevaluationYear {
|
|
|
118
126
|
* date again (11 April in 2022, 6 April in 2026) belonging
|
|
119
127
|
* to a different instrument. That is the trap on the 2022
|
|
120
128
|
* row, where 11 April is the date a search turns up. */
|
|
121
|
-
readonly appliedOn:
|
|
129
|
+
readonly appliedOn: IsoDate;
|
|
122
130
|
/** The statutory instrument that made it. */
|
|
123
131
|
readonly si: string;
|
|
132
|
+
/** The in-service rate the Order gives an active member, in
|
|
133
|
+
* percentage points: {@link activeRatePct} over
|
|
134
|
+
* `septemberCpiPct`, derived here once and never transcribed. */
|
|
135
|
+
readonly activeRatePct: number;
|
|
124
136
|
}
|
|
125
137
|
/** The bonus the scheme adds to CPI while a member is paying
|
|
126
138
|
* in, in PERCENTAGE POINTS. Added, never compounded. */
|
|
127
139
|
export declare const ACTIVE_REVAL_BONUS_PCT = 1.5;
|
|
128
|
-
/** In-service revaluation, oldest first
|
|
129
|
-
*
|
|
130
|
-
* before the year it applies to ends. */
|
|
140
|
+
/** In-service revaluation, oldest first, each year a `SchemeYearEnd`
|
|
141
|
+
* with the active rate its Order gives. */
|
|
131
142
|
export declare const IN_SERVICE_REVALUATION: readonly RevaluationYear[];
|
|
143
|
+
/** CPI + 1.5 points. A negative CPI is carried through, not
|
|
144
|
+
* floored: September 2015's −0.1 gave a 1.4% uplift, not 1.5%. */
|
|
145
|
+
export declare function activeRatePct(cpi: number): number;
|
|
132
146
|
/** The published rate for a scheme year, or null where the
|
|
133
147
|
* year isn't published — never a silent fallback. */
|
|
134
|
-
export declare function revaluationFor(yearEnd:
|
|
148
|
+
export declare function revaluationFor(yearEnd: SchemeYearEnd): RevaluationYear | null;
|
|
135
149
|
/**
|
|
136
150
|
* The date the pot moves for a given scheme year: 6 April from
|
|
137
|
-
* 2023, 1 April before it — read off the table
|
|
151
|
+
* 2023, 1 April before it — read off the table where the year's
|
|
152
|
+
* Order is held, and 6 April, the scheme's day since 2023, for a
|
|
153
|
+
* year whose Order is not yet made.
|
|
138
154
|
*
|
|
139
155
|
* Lives here rather than with the uplift rule because two
|
|
140
156
|
* callers need it and they must agree: the pension steps on
|
|
141
|
-
* these days, and so must the ruler that reads it
|
|
142
|
-
*
|
|
143
|
-
*
|
|
144
|
-
* deflated a year that had not passed.
|
|
157
|
+
* these days, and so must the ruler that reads it, or a ruler
|
|
158
|
+
* anchored before 2023 counts its own anchor step five days
|
|
159
|
+
* early and deflates a year that has not passed.
|
|
145
160
|
*/
|
|
146
|
-
export declare function appliedOnFor(yearEnd:
|
|
161
|
+
export declare function appliedOnFor(yearEnd: SchemeYearEnd): Date;
|
package/dist/revaluation.js
CHANGED
|
@@ -20,20 +20,27 @@
|
|
|
20
20
|
*
|
|
21
21
|
* "HM Treasury HCWS437 — Public Service Pension
|
|
22
22
|
* Scheme Indexation and Revaluation 2025", the
|
|
23
|
-
* Chief Secretary's annual written ministerial statement.
|
|
24
|
-
*
|
|
25
|
-
*
|
|
26
|
-
*
|
|
23
|
+
* Chief Secretary's annual written ministerial statement. It
|
|
24
|
+
* states why the date moved to 6 April, and its per-scheme table
|
|
25
|
+
* is a source of the applied-rate fixture, independent of the
|
|
26
|
+
* Order and of the valuation report.
|
|
27
27
|
*
|
|
28
28
|
* "SPPA NHS Circular 2023/01 — pension indexation and CARE
|
|
29
29
|
* revaluation" — the clearest annual statement of the exact NHS
|
|
30
30
|
* in-service rate. Scotland, but the same CPI + 1.5% rule and
|
|
31
|
-
* the same rate as England and Wales.
|
|
31
|
+
* the same rate as England and Wales. A rate source only: the
|
|
32
|
+
* date it gives, 10 April 2023, is superseded by SI 2023/252
|
|
33
|
+
* art 1(3), which brings the Order into force on 6 April 2023
|
|
34
|
+
* for all four NHS 2015 schemes (Northern Ireland's by NISR
|
|
35
|
+
* 2023/54 art 1(3)(b)).
|
|
32
36
|
*
|
|
33
37
|
* "NHS Pension Scheme Valuation Report 2020", Appendix E
|
|
34
38
|
* "Inter-valuation events" — the in-service revaluation as
|
|
35
|
-
* ACTUALLY APPLIED,
|
|
36
|
-
*
|
|
39
|
+
* ACTUALLY APPLIED, each year commencing April 2016 to April 2023,
|
|
40
|
+
* independent of the orders. No rate is transcribed here: each
|
|
41
|
+
* year's `activeRatePct` is the rule applied to the Order's CPI,
|
|
42
|
+
* and the applied rates are the test oracle in
|
|
43
|
+
* `tests/fixtures/revaluation-applied.csv`.
|
|
37
44
|
*
|
|
38
45
|
* "SI 2015/94 Sch 9 para 3 — revaluation": the NHS Pension
|
|
39
46
|
* Scheme Regulations 2015 add 1.5 to the prices "increase or
|
|
@@ -43,31 +50,32 @@
|
|
|
43
50
|
* "NHSBSA KA-02728 — how your pension is revalued", on how it is
|
|
44
51
|
* applied to members and on the date change below.
|
|
45
52
|
*
|
|
46
|
-
*
|
|
47
|
-
* Annual Benefit Statement (2015 Section, updated
|
|
48
|
-
* 31/03/2025; name and membership number redacted)
|
|
49
|
-
*
|
|
50
|
-
*
|
|
51
|
-
*
|
|
52
|
-
* here: the earnings beside that column are the member's.
|
|
53
|
+
* The fixture is cross-checked against the "Revaluation" column
|
|
54
|
+
* of a member's Annual Benefit Statement (2015 Section, updated
|
|
55
|
+
* to 31/03/2025; name and membership number redacted): the rates
|
|
56
|
+
* as actually applied to a real record, rather than as
|
|
57
|
+
* legislated. Nothing else from that document is used: the
|
|
58
|
+
* earnings beside that column are the member's.
|
|
53
59
|
* Archived as "Annual Benefit Statement, 2015 Section,
|
|
54
60
|
* redacted" — see docs/source-archive.md.
|
|
55
61
|
*
|
|
56
62
|
* ── Three facts this data carries ───────────────────
|
|
57
63
|
*
|
|
58
|
-
* **The revaluation date
|
|
59
|
-
*
|
|
60
|
-
* annual allowance
|
|
61
|
-
*
|
|
64
|
+
* **The revaluation date is not fixed.** It is 1 April through
|
|
65
|
+
* 2022 and 6 April from 2023, to manage the interaction with the
|
|
66
|
+
* annual allowance; for 2023 the operative instrument is SI
|
|
67
|
+
* 2023/252 art 1(3), which names 6 April for the NHS schemes.
|
|
68
|
+
* `appliedOn` records it per year rather than letting a
|
|
69
|
+
* scheme-year boundary be assumed.
|
|
62
70
|
*
|
|
63
71
|
* **CPI is sourced independently of the rate**, never derived
|
|
64
|
-
* from it. Taking `septemberCpiPct =
|
|
72
|
+
* from it. Taking `septemberCpiPct = rate - 1.5` would make
|
|
65
73
|
* the test that checks the +1.5 rule agree with itself, which
|
|
66
|
-
* is no test at all. So the two
|
|
67
|
-
*
|
|
68
|
-
*
|
|
69
|
-
*
|
|
70
|
-
* table
|
|
74
|
+
* is no test at all. So the two come from documents that do
|
|
75
|
+
* not cite each other: prices here, from each Treasury Order's
|
|
76
|
+
* own operative words, and the rate AS APPLIED in a test
|
|
77
|
+
* fixture, from the 2020 valuation report's inter-valuation
|
|
78
|
+
* table and a member's statement.
|
|
71
79
|
*
|
|
72
80
|
* **A negative prices figure is carried through, not floored.**
|
|
73
81
|
* September 2015 CPI was -0.1% and the 2016 order specifies a
|
|
@@ -86,9 +94,9 @@
|
|
|
86
94
|
* in-service revaluation was applied in April 2016. All eleven
|
|
87
95
|
* years to 2026 are here, which is what lets a projection walk
|
|
88
96
|
* a member's whole membership rather than only the part since
|
|
89
|
-
* their statement. `revaluationFor`
|
|
90
|
-
*
|
|
91
|
-
*
|
|
97
|
+
* their statement. `revaluationFor` returns null rather than
|
|
98
|
+
* guessing for a year not held: one before 2016, or one whose
|
|
99
|
+
* order has not yet been made.
|
|
92
100
|
*
|
|
93
101
|
* ── Not this table ──────────────────────────────────
|
|
94
102
|
*
|
|
@@ -97,13 +105,15 @@
|
|
|
97
105
|
* different instrument. For 1995/2008 practitioners the
|
|
98
106
|
* equivalent uplift is earnings dynamisation, not this.
|
|
99
107
|
*/
|
|
108
|
+
import { schemeYearEnd } from './pension/scheme-year.js';
|
|
109
|
+
import { isoDate, isoToDate } from './iso-date.js';
|
|
100
110
|
/** The bonus the scheme adds to CPI while a member is paying
|
|
101
111
|
* in, in PERCENTAGE POINTS. Added, never compounded. */
|
|
102
112
|
export const ACTIVE_REVAL_BONUS_PCT = 1.5;
|
|
103
113
|
/** In-service revaluation, oldest first. Extend when the next
|
|
104
114
|
* Revaluation Order is made — a year's rate is known months
|
|
105
115
|
* before the year it applies to ends. */
|
|
106
|
-
|
|
116
|
+
const REVALUATION_ROWS = [
|
|
107
117
|
{
|
|
108
118
|
// The scheme's FIRST uplift, and the only one from a
|
|
109
119
|
// negative prices figure: September 2015 CPI was -0.1%
|
|
@@ -115,81 +125,87 @@ export const IN_SERVICE_REVALUATION = [
|
|
|
115
125
|
// qualifier.
|
|
116
126
|
yearEnd: 2016,
|
|
117
127
|
septemberCpiPct: -0.1,
|
|
118
|
-
|
|
119
|
-
appliedOn: '2016-04-01',
|
|
128
|
+
appliedOn: isoDate('2016-04-01'),
|
|
120
129
|
si: 'SI 2016/438',
|
|
121
130
|
},
|
|
122
131
|
{
|
|
123
132
|
yearEnd: 2017,
|
|
124
133
|
septemberCpiPct: 1.0,
|
|
125
|
-
|
|
126
|
-
appliedOn: '2017-04-01',
|
|
134
|
+
appliedOn: isoDate('2017-04-01'),
|
|
127
135
|
si: 'SI 2017/242',
|
|
128
136
|
},
|
|
129
137
|
{
|
|
130
138
|
yearEnd: 2018,
|
|
131
139
|
septemberCpiPct: 3.0,
|
|
132
|
-
|
|
133
|
-
appliedOn: '2018-04-01',
|
|
140
|
+
appliedOn: isoDate('2018-04-01'),
|
|
134
141
|
si: 'SI 2018/338',
|
|
135
142
|
},
|
|
136
143
|
{
|
|
137
144
|
yearEnd: 2019,
|
|
138
145
|
septemberCpiPct: 2.4,
|
|
139
|
-
|
|
140
|
-
appliedOn: '2019-04-01',
|
|
146
|
+
appliedOn: isoDate('2019-04-01'),
|
|
141
147
|
si: 'SI 2019/455',
|
|
142
148
|
},
|
|
143
149
|
{
|
|
144
150
|
yearEnd: 2020,
|
|
145
151
|
septemberCpiPct: 1.7,
|
|
146
|
-
|
|
147
|
-
appliedOn: '2020-04-01',
|
|
152
|
+
appliedOn: isoDate('2020-04-01'),
|
|
148
153
|
si: 'SI 2020/230',
|
|
149
154
|
},
|
|
150
155
|
{
|
|
151
156
|
yearEnd: 2021,
|
|
152
157
|
septemberCpiPct: 0.5,
|
|
153
|
-
|
|
154
|
-
appliedOn: '2021-04-01',
|
|
158
|
+
appliedOn: isoDate('2021-04-01'),
|
|
155
159
|
si: 'SI 2021/276',
|
|
156
160
|
},
|
|
157
161
|
{
|
|
158
162
|
yearEnd: 2022,
|
|
159
163
|
septemberCpiPct: 3.1,
|
|
160
|
-
|
|
161
|
-
appliedOn: '2022-04-01',
|
|
164
|
+
appliedOn: isoDate('2022-04-01'),
|
|
162
165
|
si: 'SI 2022/215',
|
|
163
166
|
},
|
|
164
167
|
{
|
|
165
168
|
yearEnd: 2023,
|
|
166
169
|
septemberCpiPct: 10.1,
|
|
167
|
-
|
|
168
|
-
appliedOn: '2023-04-06',
|
|
170
|
+
appliedOn: isoDate('2023-04-06'),
|
|
169
171
|
si: 'SI 2023/252',
|
|
170
172
|
},
|
|
171
173
|
{
|
|
172
174
|
yearEnd: 2024,
|
|
173
175
|
septemberCpiPct: 6.7,
|
|
174
|
-
|
|
175
|
-
appliedOn: '2024-04-06',
|
|
176
|
+
appliedOn: isoDate('2024-04-06'),
|
|
176
177
|
si: 'SI 2024/290',
|
|
177
178
|
},
|
|
178
179
|
{
|
|
179
180
|
yearEnd: 2025,
|
|
180
181
|
septemberCpiPct: 1.7,
|
|
181
|
-
|
|
182
|
-
appliedOn: '2025-04-06',
|
|
182
|
+
appliedOn: isoDate('2025-04-06'),
|
|
183
183
|
si: 'SI 2025/252',
|
|
184
184
|
},
|
|
185
185
|
{
|
|
186
186
|
yearEnd: 2026,
|
|
187
187
|
septemberCpiPct: 3.8,
|
|
188
|
-
|
|
189
|
-
appliedOn: '2026-04-06',
|
|
188
|
+
appliedOn: isoDate('2026-04-06'),
|
|
190
189
|
si: 'SI 2026/254',
|
|
191
190
|
},
|
|
192
191
|
];
|
|
192
|
+
/** In-service revaluation, oldest first, each year a `SchemeYearEnd`
|
|
193
|
+
* with the active rate its Order gives. */
|
|
194
|
+
export const IN_SERVICE_REVALUATION = REVALUATION_ROWS.map((row) => ({
|
|
195
|
+
...row,
|
|
196
|
+
yearEnd: schemeYearEnd(row.yearEnd),
|
|
197
|
+
activeRatePct: activeRatePct(row.septemberCpiPct),
|
|
198
|
+
}));
|
|
199
|
+
/** April, as `Date` counts months from nought. */
|
|
200
|
+
const APRIL_MONTH_INDEX = 3;
|
|
201
|
+
/** The day of April the scheme applies an Order from 2023, and so the day
|
|
202
|
+
* a year with no Order yet is read as moving on. */
|
|
203
|
+
const UPLIFT_DAY_FROM_2023 = 6;
|
|
204
|
+
/** CPI + 1.5 points. A negative CPI is carried through, not
|
|
205
|
+
* floored: September 2015's −0.1 gave a 1.4% uplift, not 1.5%. */
|
|
206
|
+
export function activeRatePct(cpi) {
|
|
207
|
+
return cpi + ACTIVE_REVAL_BONUS_PCT;
|
|
208
|
+
}
|
|
193
209
|
/** The published rate for a scheme year, or null where the
|
|
194
210
|
* year isn't published — never a silent fallback. */
|
|
195
211
|
export function revaluationFor(yearEnd) {
|
|
@@ -197,23 +213,21 @@ export function revaluationFor(yearEnd) {
|
|
|
197
213
|
}
|
|
198
214
|
/**
|
|
199
215
|
* The date the pot moves for a given scheme year: 6 April from
|
|
200
|
-
* 2023, 1 April before it — read off the table
|
|
216
|
+
* 2023, 1 April before it — read off the table where the year's
|
|
217
|
+
* Order is held, and 6 April, the scheme's day since 2023, for a
|
|
218
|
+
* year whose Order is not yet made.
|
|
201
219
|
*
|
|
202
220
|
* Lives here rather than with the uplift rule because two
|
|
203
221
|
* callers need it and they must agree: the pension steps on
|
|
204
|
-
* these days, and so must the ruler that reads it
|
|
205
|
-
*
|
|
206
|
-
*
|
|
207
|
-
* deflated a year that had not passed.
|
|
222
|
+
* these days, and so must the ruler that reads it, or a ruler
|
|
223
|
+
* anchored before 2023 counts its own anchor step five days
|
|
224
|
+
* early and deflates a year that has not passed.
|
|
208
225
|
*/
|
|
209
226
|
export function appliedOnFor(yearEnd) {
|
|
210
227
|
const published = revaluationFor(yearEnd);
|
|
211
|
-
if (published === null)
|
|
212
|
-
return new Date(yearEnd,
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
// parsing the ISO string gives UTC midnight, and under BST
|
|
216
|
-
// the two conventions sit an hour apart.
|
|
217
|
-
return new Date(y, m - 1, d);
|
|
228
|
+
if (published === null) {
|
|
229
|
+
return new Date(yearEnd, APRIL_MONTH_INDEX, UPLIFT_DAY_FROM_2023);
|
|
230
|
+
}
|
|
231
|
+
return isoToDate(published.appliedOn);
|
|
218
232
|
}
|
|
219
233
|
//# sourceMappingURL=revaluation.js.map
|
package/dist/revaluation.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"revaluation.js","sourceRoot":"","sources":["../src/revaluation.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"revaluation.js","sourceRoot":"","sources":["../src/revaluation.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA0GG;AAEH,OAAO,EAAC,aAAa,EAAC,MAAM,0BAA0B,CAAC;AAEvD,OAAO,EAAC,OAAO,EAAE,SAAS,EAAC,MAAM,eAAe,CAAC;AAoCjD;wDACwD;AACxD,MAAM,CAAC,MAAM,sBAAsB,GAAG,GAAG,CAAC;AAE1C;;yCAEyC;AACzC,MAAM,gBAAgB,GAA8B;IAClD;QACE,qDAAqD;QACrD,uDAAuD;QACvD,yDAAyD;QACzD,uDAAuD;QACvD,wDAAwD;QACxD,wDAAwD;QACxD,qDAAqD;QACrD,aAAa;QACb,OAAO,EAAE,IAAI;QACb,eAAe,EAAE,CAAC,GAAG;QACrB,SAAS,EAAE,OAAO,CAAC,YAAY,CAAC;QAChC,EAAE,EAAE,aAAa;KAClB;IACD;QACE,OAAO,EAAE,IAAI;QACb,eAAe,EAAE,GAAG;QACpB,SAAS,EAAE,OAAO,CAAC,YAAY,CAAC;QAChC,EAAE,EAAE,aAAa;KAClB;IACD;QACE,OAAO,EAAE,IAAI;QACb,eAAe,EAAE,GAAG;QACpB,SAAS,EAAE,OAAO,CAAC,YAAY,CAAC;QAChC,EAAE,EAAE,aAAa;KAClB;IACD;QACE,OAAO,EAAE,IAAI;QACb,eAAe,EAAE,GAAG;QACpB,SAAS,EAAE,OAAO,CAAC,YAAY,CAAC;QAChC,EAAE,EAAE,aAAa;KAClB;IACD;QACE,OAAO,EAAE,IAAI;QACb,eAAe,EAAE,GAAG;QACpB,SAAS,EAAE,OAAO,CAAC,YAAY,CAAC;QAChC,EAAE,EAA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AC;AAED;qDACqD;AACrD,MAAM,UAAU,cAAc,CAC5B,OAAsB;IAEtB,OAAO,sBAAsB,CAAC,IAAI,CAChC,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,OAAO,KAAK,OAAO,CACnC,IAAI,IAAI,CAAC;AACZ,CAAC;AAED;;;;;;;;;;;GAWG;AACH,MAAM,UAAU,YAAY,CAAC,OAAsB;IACjD,MAAM,SAAS,GAAG,cAAc,CAAC,OAAO,CAAC,CAAC;IAC1C,IAAI,SAAS,KAAK,IAAI,EAAE,CAAC;QACvB,OAAO,IAAI,IAAI,CAAC,OAAO,EAAE,iBAAiB,EAAE,oBAAoB,CAAC,CAAC;IACpE,CAAC;IACD,OAAO,SAAS,CAAC,SAAS,CAAC,SAAS,CAAC,CAAC;AACxC,CAAC"}
|
package/dist/scale-point.d.ts
CHANGED
|
@@ -44,3 +44,9 @@ export interface ScalePoint {
|
|
|
44
44
|
export interface SteppedPoint extends ScalePoint {
|
|
45
45
|
readonly yearsExperience: number;
|
|
46
46
|
}
|
|
47
|
+
/** A scale's points and the one a member is on, which is one of `points`
|
|
48
|
+
* itself, so it cannot name a point the scale does not have. */
|
|
49
|
+
export interface PayLadder {
|
|
50
|
+
readonly points: readonly SteppedPoint[];
|
|
51
|
+
readonly current: SteppedPoint;
|
|
52
|
+
}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
import type { FactorOutcome } from '../factor-basis.js';
|
|
1
|
+
import type { Factored, FactorOutcome } from '../factor-basis.js';
|
|
2
2
|
import type { PayPath } from '../pay-path.js';
|
|
3
|
-
import type { ProjectionMoney } from '../pension/money.js';
|
|
4
3
|
import type { Prices } from '../pension/prices.js';
|
|
5
4
|
/** The fraction of final pay a year of membership earns: an 80th in the
|
|
6
5
|
* 1995 Section, a 60th in the 2008. */
|
|
@@ -47,12 +46,8 @@ export interface UnreducedPension {
|
|
|
47
46
|
}
|
|
48
47
|
/** A final-salary pension and lump sum, before and after factors. */
|
|
49
48
|
interface FinalSalaryBenefit {
|
|
50
|
-
readonly
|
|
51
|
-
readonly
|
|
52
|
-
readonly automaticLumpSum: ProjectionMoney;
|
|
53
|
-
readonly automaticLumpSumBeforeFactor: ProjectionMoney;
|
|
54
|
-
readonly pensionFactor: FactorOutcome;
|
|
55
|
-
readonly automaticLumpSumFactor: FactorOutcome | null;
|
|
49
|
+
readonly pension: Factored;
|
|
50
|
+
readonly automaticLumpSum: Factored<FactorOutcome | null>;
|
|
56
51
|
readonly membership: number;
|
|
57
52
|
readonly finalPay: number;
|
|
58
53
|
}
|
|
@@ -6,8 +6,9 @@
|
|
|
6
6
|
* lacks, such as a 60 denominator on best-single-year pay.
|
|
7
7
|
*/
|
|
8
8
|
import { dayAfter, daysBetween } from '../dates.js';
|
|
9
|
+
import { factored } from '../factor-basis.js';
|
|
9
10
|
import { moneyAt } from '../pension/money.js';
|
|
10
|
-
import { schemeYearEndFor, schemeYearStartDate } from '../pension/
|
|
11
|
+
import { schemeYearAfter, schemeYearEnd, schemeYearEndFor, schemeYearStartDate, } from '../pension/scheme-year.js';
|
|
11
12
|
/** How a section measures final pay, named for an award's provenance.
|
|
12
13
|
* The measuring itself is each section's own `finalPay`. */
|
|
13
14
|
export const PAY_MEASURES = {
|
|
@@ -39,15 +40,10 @@ export function finalSalaryBenefit(rules, { windows, payPath, dateOfBirth, leavi
|
|
|
39
40
|
const lumpFactor = lump === null
|
|
40
41
|
? null
|
|
41
42
|
: lump.factor(dateOfBirth, leaving, drawing);
|
|
42
|
-
const lumpSum = lumpFactor === null ? 0 : unreducedLump * lumpFactor.factor;
|
|
43
43
|
const money = (real) => moneyAt({ real, nominal: prices.payAt(real, drawing) }, drawing);
|
|
44
44
|
return {
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
automaticLumpSum: money(lumpSum),
|
|
48
|
-
automaticLumpSumBeforeFactor: money(unreducedLump),
|
|
49
|
-
pensionFactor,
|
|
50
|
-
automaticLumpSumFactor: lumpFactor,
|
|
45
|
+
pension: factored(money(unreduced), pensionFactor),
|
|
46
|
+
automaticLumpSum: factored(money(unreducedLump), lumpFactor),
|
|
51
47
|
membership,
|
|
52
48
|
finalPay: pay,
|
|
53
49
|
};
|
|
@@ -147,9 +143,9 @@ function membershipYears(windows) {
|
|
|
147
143
|
function yearsTo(payPath, leaving, count) {
|
|
148
144
|
const last = schemeYearEndFor(leaving);
|
|
149
145
|
const opened = schemeYearStartDate(last);
|
|
150
|
-
const daysIn = daysBetween(opened, schemeYearStartDate(last
|
|
146
|
+
const daysIn = daysBetween(opened, schemeYearStartDate(schemeYearAfter(last)));
|
|
151
147
|
const share = (daysBetween(opened, leaving) + 1) / daysIn;
|
|
152
|
-
const pay = (year) => payPath.payFor(year).pay;
|
|
148
|
+
const pay = (year) => payPath.payFor(schemeYearEnd(year)).pay;
|
|
153
149
|
const leftOnYearEnd = share === 1;
|
|
154
150
|
return Array.from({ length: count }, (_, back) => (leftOnYearEnd
|
|
155
151
|
? pay(last - back)
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"final-salary.js","sourceRoot":"","sources":["../../src/sections/final-salary.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AACH,OAAO,EAAC,QAAQ,EAAE,WAAW,EAAC,MAAM,aAAa,CAAC;
|
|
1
|
+
{"version":3,"file":"final-salary.js","sourceRoot":"","sources":["../../src/sections/final-salary.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AACH,OAAO,EAAC,QAAQ,EAAE,WAAW,EAAC,MAAM,aAAa,CAAC;AAClD,OAAO,EAAC,QAAQ,EAAC,MAAM,oBAAoB,CAAC;AAG5C,OAAO,EAAC,OAAO,EAAC,MAAM,qBAAqB,CAAC;AAG5C,OAAO,EACL,eAAe,EAAE,aAAa,EAAE,gBAAgB,EAAE,mBAAmB,GACtE,MAAM,2BAA2B,CAAC;AA4DnC;6DAC6D;AAC7D,MAAM,CAAC,MAAM,YAAY,GAAG;IAC1B,aAAa,EAAE,kBAAkB;IACjC,sBAAsB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,WAAW,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,CAAC,CAAC,GAAG,MAAM,CAAC;IAC1D,MAAM,GAAG,GAAG,CAAC,IAAY,EAAE,EAAE,CAAC,OAAO,CAAC,MAAM,CAAC,aAAa,CAAC,IAAI,CAAC,CAAC,CAAC,GAAG,CAAC;IACtE,MAAM,aAAa,GAAG,KAAK,KAAK,CAAC,CAAC;IAClC,OAAO,KAAK,CAAC,IAAI,CAAC,EAAC,MAAM,EAAE,KAAK,EAAC,EAAE,CAAC,CAAC,EAAE,IAAI,EAAE,EAAE,CAAC,CAAC,aAAa;QAC5D,CAAC,CAAC,GAAG,CAAC,IAAI,GAAG,IAAI,CAAC;QAClB,CAAC,CAAC,KAAK,GAAG,GAAG,CAAC,IAAI,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,GAAG,KAAK,CAAC,GAAG,GAAG,CAAC,IAAI,GAAG,IAAI,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC;AACtE,CAAC"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import type { Applies2015, FactorOutcome } from '../factor-basis.js';
|
|
2
2
|
import type { MemberLedger, PayIn } from '../pension/ledger.js';
|
|
3
3
|
import type { Prices } from '../pension/prices.js';
|
|
4
|
+
import type { SchemeYearEnd } from '../pension/scheme-year.js';
|
|
4
5
|
import type { LedgerSeed } from '../pension/seed.js';
|
|
5
6
|
/**
|
|
6
7
|
* The factor for a benefit determined under the 2015 Section's rules,
|
|
@@ -15,10 +16,8 @@ export declare function factor2015(dateOfBirth: Date, drawn: Date, applies: Appl
|
|
|
15
16
|
interface CareerAverageRun {
|
|
16
17
|
readonly ledger: MemberLedger;
|
|
17
18
|
readonly seed: LedgerSeed;
|
|
18
|
-
/** At the drawing, before its factor. */
|
|
19
|
+
/** At the drawing, before its factor; `factored` applies it. */
|
|
19
20
|
readonly revalued: number;
|
|
20
|
-
/** At the drawing, after its factor. */
|
|
21
|
-
readonly drawn: number;
|
|
22
21
|
}
|
|
23
22
|
/**
|
|
24
23
|
* Walk a career average pot in one ruler: the 2015 Section's own, or a
|
|
@@ -37,7 +36,7 @@ export declare function careerAverage({ seed, payIn, dateOfBirth, leaving, drawi
|
|
|
37
36
|
readonly leaving: Date;
|
|
38
37
|
readonly drawing: Date;
|
|
39
38
|
readonly prices: Prices;
|
|
40
|
-
readonly through:
|
|
39
|
+
readonly through: SchemeYearEnd;
|
|
41
40
|
}): CareerAverageRun & {
|
|
42
41
|
readonly factor: FactorOutcome;
|
|
43
42
|
};
|
|
@@ -55,7 +55,7 @@ export function careerAverage({ seed, payIn, dateOfBirth, leaving, drawing, pric
|
|
|
55
55
|
});
|
|
56
56
|
return {
|
|
57
57
|
ledger, seed, factor,
|
|
58
|
-
|
|
58
|
+
revalued: atDrawing(ledger, drawing, factor.factor).revalued,
|
|
59
59
|
};
|
|
60
60
|
}
|
|
61
61
|
//# sourceMappingURL=section-2015.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"section-2015.js","sourceRoot":"","sources":["../../src/sections/section-2015.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,OAAO,EAAC,OAAO,EAAC,MAAM,aAAa,CAAC;AACpC,OAAO,EACL,cAAc,EAAE,iBAAiB,EAAE,cAAc,EAAE,WAAW,EAAE,UAAU,GAC3E,MAAM,oBAAoB,CAAC;AAI5B,OAAO,EAAC,gBAAgB,EAAC,MAAM,oBAAoB,CAAC;AACpD,OAAO,EAAC,SAAS,EAAE,WAAW,EAAC,MAAM,sBAAsB,CAAC;
|
|
1
|
+
{"version":3,"file":"section-2015.js","sourceRoot":"","sources":["../../src/sections/section-2015.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,OAAO,EAAC,OAAO,EAAC,MAAM,aAAa,CAAC;AACpC,OAAO,EACL,cAAc,EAAE,iBAAiB,EAAE,cAAc,EAAE,WAAW,EAAE,UAAU,GAC3E,MAAM,oBAAoB,CAAC;AAI5B,OAAO,EAAC,gBAAgB,E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AC,CAAC;IACH,OAAO;QACL,MAAM,EAAE,IAAI,EAAE,MAAM;QACpB,QAAQ,EAAE,SAAS,CAAC,MAAM,EAAE,OAAO,EAAE,MAAM,CAAC,MAAM,CAAC,CAAC,QAAQ;KAC7D,CAAC;AACJ,CAAC"}
|
package/dist/sources.d.ts
CHANGED
|
@@ -20,6 +20,10 @@
|
|
|
20
20
|
* - **Legislation** — an Act's own provision, where the rule a figure
|
|
21
21
|
* turns on is the statute's rather than the scheme's.
|
|
22
22
|
*
|
|
23
|
+
* Each is a `DocumentSource`, except a publisher's web page that prints
|
|
24
|
+
* no issue date, which is a `PageSource`: it carries the day it was
|
|
25
|
+
* read, so it cannot be shown as published on that day.
|
|
26
|
+
*
|
|
23
27
|
* They diverge in every nation. England's 2026-27 medical award was
|
|
24
28
|
* enacted by HCWS1462 on parliament.uk while its salaries are printed
|
|
25
29
|
* in PC(M&D) 1/2026 R2 on nhsemployers.org. Reading the award's source
|
|
@@ -36,6 +40,7 @@
|
|
|
36
40
|
* manifest.
|
|
37
41
|
*/
|
|
38
42
|
import { DocumentSource } from './document-source.js';
|
|
43
|
+
import type { PageSource } from './document-source.js';
|
|
39
44
|
/** The 54th DDRB round, as accepted by each government. The report
|
|
40
45
|
* itself is NOT the source: a recommendation can be modified, staged
|
|
41
46
|
* or refused on the way in, and when it is, the acceptance is right
|
|
@@ -202,6 +207,15 @@ export declare const HSC_TC8_05_2025: DocumentSource;
|
|
|
202
207
|
/** DHSC on who the 2028 rise in the minimum age reaches; archived as SA-59 in
|
|
203
208
|
* docs/source-archive.md. A petition response that cites no instrument. */
|
|
204
209
|
export declare const DHSC_PETITION_779519: DocumentSource;
|
|
210
|
+
/** NHSBSA's guide to the pension figures on a 2015 Section statement: "We
|
|
211
|
+
* produce your 2015 statement as of 31 March. The figures shown are not
|
|
212
|
+
* yet revalued." The source of `memberBenefits`' 31 March statement
|
|
213
|
+
* rule; archived as SA-63 in docs/source-archive.md. */
|
|
214
|
+
export declare const NHSBSA_STATEMENT_GUIDE: PageSource;
|
|
215
|
+
/** NHSBSA's page on asking for a pension estimate: "We base this on
|
|
216
|
+
* information your employer gives us up to 31 March." Archived as SA-64 in
|
|
217
|
+
* docs/source-archive.md. */
|
|
218
|
+
export declare const NHSBSA_ESTIMATE_GUIDE: PageSource;
|
|
205
219
|
/** The Scottish scheme's own statement of who keeps 55; archived as SA-61 in
|
|
206
220
|
* docs/source-archive.md, the version with paragraph 9 updated. */
|
|
207
221
|
export declare const SPPA_NHS_CIRCULAR_2025_09: DocumentSource;
|