@tantainnovative/ndpr-toolkit 5.1.3 → 5.2.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/CHANGELOG.md +25 -0
- package/README.md +57 -0
- package/dist/{chunk-YX7DEHPA.mjs → chunk-6A7M4CGJ.mjs} +1 -1
- package/dist/{chunk-JVMHWM3I.js → chunk-7TTXS7JX.js} +1 -1
- package/dist/chunk-SDYLKJGC.js +1 -0
- package/dist/chunk-SZXHNJGG.mjs +1 -0
- package/dist/chunk-TQCKLZ4F.mjs +1 -0
- package/dist/chunk-WKY26JLT.js +1 -0
- package/dist/core.d.mts +157 -0
- package/dist/core.d.ts +157 -0
- package/dist/core.js +1 -1
- package/dist/core.mjs +1 -1
- package/dist/headless.d.mts +294 -0
- package/dist/headless.d.ts +294 -0
- package/dist/headless.js +1 -1
- package/dist/headless.mjs +1 -1
- package/dist/hooks.d.mts +154 -0
- package/dist/hooks.d.ts +154 -0
- package/dist/hooks.js +1 -1
- package/dist/hooks.mjs +1 -1
- package/dist/index.d.mts +171 -0
- package/dist/index.d.ts +171 -0
- package/dist/index.js +1 -1
- package/dist/index.mjs +1 -1
- package/dist/presets.js +1 -1
- package/dist/presets.mjs +1 -1
- package/dist/server.js +1 -1
- package/dist/server.mjs +1 -1
- package/package.json +7 -8
- package/dist/chunk-BHUJWWCO.js +0 -1
- package/dist/chunk-XAB5C2JG.mjs +0 -1
- /package/dist/{chunk-GQYBS3A7.mjs → chunk-65TYKXUI.mjs} +0 -0
- /package/dist/{chunk-OZCNFB5C.js → chunk-MR7YZZDU.js} +0 -0
package/dist/hooks.d.mts
CHANGED
|
@@ -118,6 +118,68 @@ export declare interface BreachReport {
|
|
|
118
118
|
}>;
|
|
119
119
|
}
|
|
120
120
|
|
|
121
|
+
/**
|
|
122
|
+
* Compliance Audit Returns (CAR) scheduling under the NDPC General Application
|
|
123
|
+
* and Implementation Directive (GAID) 2025.
|
|
124
|
+
*
|
|
125
|
+
* A Data Controller/Processor of Major Importance (DCPMI) must conduct an
|
|
126
|
+
* initial compliance audit within 15 months of commencing data processing, and
|
|
127
|
+
* thereafter file a Compliance Audit Return with the NDPC annually (default
|
|
128
|
+
* deadline 31 March, filed through the NDPC Information Management Portal/NIMP).
|
|
129
|
+
*
|
|
130
|
+
* This computes the schedule (initial-audit due date, the next annual filing
|
|
131
|
+
* deadline relative to a reference date) and a light status. NDPC deadlines
|
|
132
|
+
* shift (the 2026 filing was extended to 30 May), so the annual deadline is
|
|
133
|
+
* configurable and per-year overrides are supported. The audit *content* itself
|
|
134
|
+
* is the organisation's compliance posture — pair this with `getComplianceScore`.
|
|
135
|
+
*
|
|
136
|
+
* @see NDPC General Application and Implementation Directive (GAID) 2025
|
|
137
|
+
*/
|
|
138
|
+
|
|
139
|
+
export declare interface CARInput {
|
|
140
|
+
/** ISO date (YYYY-MM-DD) the organisation commenced data processing. */
|
|
141
|
+
commencementDate: string;
|
|
142
|
+
/** Reference date to evaluate against (YYYY-MM-DD). Defaults to today. */
|
|
143
|
+
asOf?: string;
|
|
144
|
+
/** DCPMI tier; CAR applies to DCPMIs only. Omit to assume applicable. */
|
|
145
|
+
tier?: DCPMITier;
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
export declare interface CAROptions {
|
|
149
|
+
/** Default annual filing deadline (month is 1-12). Defaults to 31 March. */
|
|
150
|
+
annualDeadline?: {
|
|
151
|
+
month: number;
|
|
152
|
+
day: number;
|
|
153
|
+
};
|
|
154
|
+
/** Per-year overrides for the annual deadline, e.g. `{ 2026: '2026-05-30' }`. */
|
|
155
|
+
deadlineOverrides?: Record<number, string>;
|
|
156
|
+
/** Months after commencement the initial audit is due. Defaults to 15. */
|
|
157
|
+
initialAuditWithinMonths?: number;
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
export declare interface ComplianceAuditReturn {
|
|
161
|
+
/** Whether CAR applies (false for non-DCPMI organisations). */
|
|
162
|
+
applicable: boolean;
|
|
163
|
+
schedule: {
|
|
164
|
+
commencementDate: string;
|
|
165
|
+
initialAuditWithinMonths: number;
|
|
166
|
+
/** Commencement date + the initial-audit window. */
|
|
167
|
+
initialAuditDueDate: string;
|
|
168
|
+
/** The next annual filing deadline on or after `asOf`. */
|
|
169
|
+
nextFilingDeadline: string;
|
|
170
|
+
/** The year the next filing deadline falls in. */
|
|
171
|
+
filingYear: number;
|
|
172
|
+
};
|
|
173
|
+
status: {
|
|
174
|
+
/** Whether the initial-audit obligation has arisen (asOf ≥ due date). */
|
|
175
|
+
initialAuditDue: boolean;
|
|
176
|
+
/** Whole days from `asOf` to the next filing deadline. */
|
|
177
|
+
daysUntilNextDeadline: number;
|
|
178
|
+
};
|
|
179
|
+
notes: string[];
|
|
180
|
+
asOf: string;
|
|
181
|
+
}
|
|
182
|
+
|
|
121
183
|
/** A single gap found during NDPA compliance evaluation. */
|
|
122
184
|
declare interface ComplianceGap {
|
|
123
185
|
/** Machine-readable requirement identifier. */
|
|
@@ -440,6 +502,84 @@ declare interface DataCategory {
|
|
|
440
502
|
selected: boolean;
|
|
441
503
|
}
|
|
442
504
|
|
|
505
|
+
export declare interface DCPMIClassification {
|
|
506
|
+
/** Registration tier (or `'none'` when not a DCPMI). */
|
|
507
|
+
tier: DCPMITier;
|
|
508
|
+
/** Whether the organisation is a Data Controller/Processor of Major Importance. */
|
|
509
|
+
isDCPMI: boolean;
|
|
510
|
+
/** Annual registration fee in Nigerian Naira (0 when not a volume-tiered DCPMI). */
|
|
511
|
+
annualFeeNGN: number;
|
|
512
|
+
registration: {
|
|
513
|
+
/** Whether NDPC registration is required. */
|
|
514
|
+
required: boolean;
|
|
515
|
+
/** OHL renews registration annually; UHL/EHL register once and file CAR annually. */
|
|
516
|
+
renewsAnnually: boolean;
|
|
517
|
+
};
|
|
518
|
+
compliance: {
|
|
519
|
+
/** Whether the organisation must file annual Compliance Audit Returns (CAR). */
|
|
520
|
+
auditReturnsAnnual: boolean;
|
|
521
|
+
/** Initial compliance audit is due within this many months of commencing processing. */
|
|
522
|
+
initialAuditWithinMonths: number;
|
|
523
|
+
};
|
|
524
|
+
/** Human-readable caveats and next steps. */
|
|
525
|
+
notes: string[];
|
|
526
|
+
/** The count actually used for classification, after defensive normalisation. */
|
|
527
|
+
dataSubjectsConsidered: number;
|
|
528
|
+
}
|
|
529
|
+
|
|
530
|
+
export declare interface DCPMIClassificationOptions {
|
|
531
|
+
thresholds?: Partial<DCPMIThresholds>;
|
|
532
|
+
fees?: Partial<DCPMIFees>;
|
|
533
|
+
}
|
|
534
|
+
|
|
535
|
+
declare interface DCPMIFees {
|
|
536
|
+
UHL: number;
|
|
537
|
+
EHL: number;
|
|
538
|
+
OHL: number;
|
|
539
|
+
}
|
|
540
|
+
|
|
541
|
+
export declare interface DCPMIInput {
|
|
542
|
+
/** Distinct data subjects whose data was processed in the relevant six-month window. */
|
|
543
|
+
dataSubjectsInSixMonths?: number;
|
|
544
|
+
/** True if the Commission has separately designated/listed the organisation as a DCPMI. */
|
|
545
|
+
isDesignated?: boolean;
|
|
546
|
+
}
|
|
547
|
+
|
|
548
|
+
declare interface DCPMIThresholds {
|
|
549
|
+
/** Lower bound (inclusive) for OHL. */
|
|
550
|
+
ohl: number;
|
|
551
|
+
/** Lower bound (inclusive) for EHL. */
|
|
552
|
+
ehl: number;
|
|
553
|
+
/** A count strictly greater than this is UHL. */
|
|
554
|
+
uhl: number;
|
|
555
|
+
}
|
|
556
|
+
|
|
557
|
+
/**
|
|
558
|
+
* Data Controller/Processor of Major Importance (DCPMI) classification under the
|
|
559
|
+
* NDPC General Application and Implementation Directive (GAID) 2025.
|
|
560
|
+
*
|
|
561
|
+
* Volume-based tiers — data subjects processed within a six-month window:
|
|
562
|
+
* - UHL (Ultra High Level): more than 5,000 → ₦250,000 / year
|
|
563
|
+
* - EHL (Extra High Level): 1,000 – 5,000 → ₦100,000 / year
|
|
564
|
+
* - OHL (Ordinary High Level): 200 – 999 → ₦10,000 / year
|
|
565
|
+
* - below 200: not a DCPMI by volume
|
|
566
|
+
*
|
|
567
|
+
* Boundaries: the 1,000 mark resolves to EHL (so OHL is 200–999); UHL is
|
|
568
|
+
* strictly greater than 5,000 (so 5,000 itself is EHL). The NDPC has revised
|
|
569
|
+
* classification metrics before and shifts filing deadlines, so thresholds and
|
|
570
|
+
* fees are configurable — treat the defaults as the September 2025 GAID
|
|
571
|
+
* baseline, not a constant.
|
|
572
|
+
*
|
|
573
|
+
* `isDesignated` marks an organisation the Commission has otherwise listed as a
|
|
574
|
+
* DCPMI; it is then a DCPMI regardless of volume. Below the volume tiers such an
|
|
575
|
+
* organisation is reported as `'listed'` with the fee left at 0 and a note to
|
|
576
|
+
* confirm the applicable tier/fee with the NDPC.
|
|
577
|
+
*
|
|
578
|
+
* @see NDPC General Application and Implementation Directive (GAID) 2025
|
|
579
|
+
* @see NDPC Guidance Notice on the Registration of Data Controllers and Processors of Major Importance
|
|
580
|
+
*/
|
|
581
|
+
declare type DCPMITier = 'UHL' | 'EHL' | 'OHL' | 'listed' | 'none';
|
|
582
|
+
|
|
443
583
|
/** Options for DOCX export of the finalised policy. */
|
|
444
584
|
declare interface DOCXExportOptions {
|
|
445
585
|
includeTOC?: boolean;
|
|
@@ -1614,6 +1754,13 @@ export declare interface UseBreachReturn {
|
|
|
1614
1754
|
isLoading: boolean;
|
|
1615
1755
|
}
|
|
1616
1756
|
|
|
1757
|
+
/**
|
|
1758
|
+
* React hook that memoises the `generateComplianceAuditReturn` utility — derives
|
|
1759
|
+
* a DCPMI's Compliance Audit Returns schedule (initial-audit due date, next
|
|
1760
|
+
* annual filing deadline) and status under NDPC GAID 2025.
|
|
1761
|
+
*/
|
|
1762
|
+
export declare function useComplianceAuditReturn(input: CARInput, options?: CAROptions): ComplianceAuditReturn;
|
|
1763
|
+
|
|
1617
1764
|
/**
|
|
1618
1765
|
* Computes an NDPA compliance score and returns a structured report
|
|
1619
1766
|
* (score, rating, per-module breakdown, recommendations).
|
|
@@ -1831,6 +1978,13 @@ export declare interface UseCrossBorderTransferReturn {
|
|
|
1831
1978
|
isLoading: boolean;
|
|
1832
1979
|
}
|
|
1833
1980
|
|
|
1981
|
+
/**
|
|
1982
|
+
* React hook that memoises the `classifyDCPMI` utility — derives an organisation's
|
|
1983
|
+
* Data Controller/Processor of Major Importance tier, annual registration fee,
|
|
1984
|
+
* and Compliance Audit Returns obligations under NDPC GAID 2025.
|
|
1985
|
+
*/
|
|
1986
|
+
export declare function useDCPMI(input: DCPMIInput, options?: DCPMIClassificationOptions): DCPMIClassification;
|
|
1987
|
+
|
|
1834
1988
|
/**
|
|
1835
1989
|
* Convenience wrapper around `usePrivacyPolicy`. With `orgInfo` provided
|
|
1836
1990
|
* and `autoGenerate` enabled (default), `policy` is non-null on the first
|
package/dist/hooks.d.ts
CHANGED
|
@@ -118,6 +118,68 @@ export declare interface BreachReport {
|
|
|
118
118
|
}>;
|
|
119
119
|
}
|
|
120
120
|
|
|
121
|
+
/**
|
|
122
|
+
* Compliance Audit Returns (CAR) scheduling under the NDPC General Application
|
|
123
|
+
* and Implementation Directive (GAID) 2025.
|
|
124
|
+
*
|
|
125
|
+
* A Data Controller/Processor of Major Importance (DCPMI) must conduct an
|
|
126
|
+
* initial compliance audit within 15 months of commencing data processing, and
|
|
127
|
+
* thereafter file a Compliance Audit Return with the NDPC annually (default
|
|
128
|
+
* deadline 31 March, filed through the NDPC Information Management Portal/NIMP).
|
|
129
|
+
*
|
|
130
|
+
* This computes the schedule (initial-audit due date, the next annual filing
|
|
131
|
+
* deadline relative to a reference date) and a light status. NDPC deadlines
|
|
132
|
+
* shift (the 2026 filing was extended to 30 May), so the annual deadline is
|
|
133
|
+
* configurable and per-year overrides are supported. The audit *content* itself
|
|
134
|
+
* is the organisation's compliance posture — pair this with `getComplianceScore`.
|
|
135
|
+
*
|
|
136
|
+
* @see NDPC General Application and Implementation Directive (GAID) 2025
|
|
137
|
+
*/
|
|
138
|
+
|
|
139
|
+
export declare interface CARInput {
|
|
140
|
+
/** ISO date (YYYY-MM-DD) the organisation commenced data processing. */
|
|
141
|
+
commencementDate: string;
|
|
142
|
+
/** Reference date to evaluate against (YYYY-MM-DD). Defaults to today. */
|
|
143
|
+
asOf?: string;
|
|
144
|
+
/** DCPMI tier; CAR applies to DCPMIs only. Omit to assume applicable. */
|
|
145
|
+
tier?: DCPMITier;
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
export declare interface CAROptions {
|
|
149
|
+
/** Default annual filing deadline (month is 1-12). Defaults to 31 March. */
|
|
150
|
+
annualDeadline?: {
|
|
151
|
+
month: number;
|
|
152
|
+
day: number;
|
|
153
|
+
};
|
|
154
|
+
/** Per-year overrides for the annual deadline, e.g. `{ 2026: '2026-05-30' }`. */
|
|
155
|
+
deadlineOverrides?: Record<number, string>;
|
|
156
|
+
/** Months after commencement the initial audit is due. Defaults to 15. */
|
|
157
|
+
initialAuditWithinMonths?: number;
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
export declare interface ComplianceAuditReturn {
|
|
161
|
+
/** Whether CAR applies (false for non-DCPMI organisations). */
|
|
162
|
+
applicable: boolean;
|
|
163
|
+
schedule: {
|
|
164
|
+
commencementDate: string;
|
|
165
|
+
initialAuditWithinMonths: number;
|
|
166
|
+
/** Commencement date + the initial-audit window. */
|
|
167
|
+
initialAuditDueDate: string;
|
|
168
|
+
/** The next annual filing deadline on or after `asOf`. */
|
|
169
|
+
nextFilingDeadline: string;
|
|
170
|
+
/** The year the next filing deadline falls in. */
|
|
171
|
+
filingYear: number;
|
|
172
|
+
};
|
|
173
|
+
status: {
|
|
174
|
+
/** Whether the initial-audit obligation has arisen (asOf ≥ due date). */
|
|
175
|
+
initialAuditDue: boolean;
|
|
176
|
+
/** Whole days from `asOf` to the next filing deadline. */
|
|
177
|
+
daysUntilNextDeadline: number;
|
|
178
|
+
};
|
|
179
|
+
notes: string[];
|
|
180
|
+
asOf: string;
|
|
181
|
+
}
|
|
182
|
+
|
|
121
183
|
/** A single gap found during NDPA compliance evaluation. */
|
|
122
184
|
declare interface ComplianceGap {
|
|
123
185
|
/** Machine-readable requirement identifier. */
|
|
@@ -440,6 +502,84 @@ declare interface DataCategory {
|
|
|
440
502
|
selected: boolean;
|
|
441
503
|
}
|
|
442
504
|
|
|
505
|
+
export declare interface DCPMIClassification {
|
|
506
|
+
/** Registration tier (or `'none'` when not a DCPMI). */
|
|
507
|
+
tier: DCPMITier;
|
|
508
|
+
/** Whether the organisation is a Data Controller/Processor of Major Importance. */
|
|
509
|
+
isDCPMI: boolean;
|
|
510
|
+
/** Annual registration fee in Nigerian Naira (0 when not a volume-tiered DCPMI). */
|
|
511
|
+
annualFeeNGN: number;
|
|
512
|
+
registration: {
|
|
513
|
+
/** Whether NDPC registration is required. */
|
|
514
|
+
required: boolean;
|
|
515
|
+
/** OHL renews registration annually; UHL/EHL register once and file CAR annually. */
|
|
516
|
+
renewsAnnually: boolean;
|
|
517
|
+
};
|
|
518
|
+
compliance: {
|
|
519
|
+
/** Whether the organisation must file annual Compliance Audit Returns (CAR). */
|
|
520
|
+
auditReturnsAnnual: boolean;
|
|
521
|
+
/** Initial compliance audit is due within this many months of commencing processing. */
|
|
522
|
+
initialAuditWithinMonths: number;
|
|
523
|
+
};
|
|
524
|
+
/** Human-readable caveats and next steps. */
|
|
525
|
+
notes: string[];
|
|
526
|
+
/** The count actually used for classification, after defensive normalisation. */
|
|
527
|
+
dataSubjectsConsidered: number;
|
|
528
|
+
}
|
|
529
|
+
|
|
530
|
+
export declare interface DCPMIClassificationOptions {
|
|
531
|
+
thresholds?: Partial<DCPMIThresholds>;
|
|
532
|
+
fees?: Partial<DCPMIFees>;
|
|
533
|
+
}
|
|
534
|
+
|
|
535
|
+
declare interface DCPMIFees {
|
|
536
|
+
UHL: number;
|
|
537
|
+
EHL: number;
|
|
538
|
+
OHL: number;
|
|
539
|
+
}
|
|
540
|
+
|
|
541
|
+
export declare interface DCPMIInput {
|
|
542
|
+
/** Distinct data subjects whose data was processed in the relevant six-month window. */
|
|
543
|
+
dataSubjectsInSixMonths?: number;
|
|
544
|
+
/** True if the Commission has separately designated/listed the organisation as a DCPMI. */
|
|
545
|
+
isDesignated?: boolean;
|
|
546
|
+
}
|
|
547
|
+
|
|
548
|
+
declare interface DCPMIThresholds {
|
|
549
|
+
/** Lower bound (inclusive) for OHL. */
|
|
550
|
+
ohl: number;
|
|
551
|
+
/** Lower bound (inclusive) for EHL. */
|
|
552
|
+
ehl: number;
|
|
553
|
+
/** A count strictly greater than this is UHL. */
|
|
554
|
+
uhl: number;
|
|
555
|
+
}
|
|
556
|
+
|
|
557
|
+
/**
|
|
558
|
+
* Data Controller/Processor of Major Importance (DCPMI) classification under the
|
|
559
|
+
* NDPC General Application and Implementation Directive (GAID) 2025.
|
|
560
|
+
*
|
|
561
|
+
* Volume-based tiers — data subjects processed within a six-month window:
|
|
562
|
+
* - UHL (Ultra High Level): more than 5,000 → ₦250,000 / year
|
|
563
|
+
* - EHL (Extra High Level): 1,000 – 5,000 → ₦100,000 / year
|
|
564
|
+
* - OHL (Ordinary High Level): 200 – 999 → ₦10,000 / year
|
|
565
|
+
* - below 200: not a DCPMI by volume
|
|
566
|
+
*
|
|
567
|
+
* Boundaries: the 1,000 mark resolves to EHL (so OHL is 200–999); UHL is
|
|
568
|
+
* strictly greater than 5,000 (so 5,000 itself is EHL). The NDPC has revised
|
|
569
|
+
* classification metrics before and shifts filing deadlines, so thresholds and
|
|
570
|
+
* fees are configurable — treat the defaults as the September 2025 GAID
|
|
571
|
+
* baseline, not a constant.
|
|
572
|
+
*
|
|
573
|
+
* `isDesignated` marks an organisation the Commission has otherwise listed as a
|
|
574
|
+
* DCPMI; it is then a DCPMI regardless of volume. Below the volume tiers such an
|
|
575
|
+
* organisation is reported as `'listed'` with the fee left at 0 and a note to
|
|
576
|
+
* confirm the applicable tier/fee with the NDPC.
|
|
577
|
+
*
|
|
578
|
+
* @see NDPC General Application and Implementation Directive (GAID) 2025
|
|
579
|
+
* @see NDPC Guidance Notice on the Registration of Data Controllers and Processors of Major Importance
|
|
580
|
+
*/
|
|
581
|
+
declare type DCPMITier = 'UHL' | 'EHL' | 'OHL' | 'listed' | 'none';
|
|
582
|
+
|
|
443
583
|
/** Options for DOCX export of the finalised policy. */
|
|
444
584
|
declare interface DOCXExportOptions {
|
|
445
585
|
includeTOC?: boolean;
|
|
@@ -1614,6 +1754,13 @@ export declare interface UseBreachReturn {
|
|
|
1614
1754
|
isLoading: boolean;
|
|
1615
1755
|
}
|
|
1616
1756
|
|
|
1757
|
+
/**
|
|
1758
|
+
* React hook that memoises the `generateComplianceAuditReturn` utility — derives
|
|
1759
|
+
* a DCPMI's Compliance Audit Returns schedule (initial-audit due date, next
|
|
1760
|
+
* annual filing deadline) and status under NDPC GAID 2025.
|
|
1761
|
+
*/
|
|
1762
|
+
export declare function useComplianceAuditReturn(input: CARInput, options?: CAROptions): ComplianceAuditReturn;
|
|
1763
|
+
|
|
1617
1764
|
/**
|
|
1618
1765
|
* Computes an NDPA compliance score and returns a structured report
|
|
1619
1766
|
* (score, rating, per-module breakdown, recommendations).
|
|
@@ -1831,6 +1978,13 @@ export declare interface UseCrossBorderTransferReturn {
|
|
|
1831
1978
|
isLoading: boolean;
|
|
1832
1979
|
}
|
|
1833
1980
|
|
|
1981
|
+
/**
|
|
1982
|
+
* React hook that memoises the `classifyDCPMI` utility — derives an organisation's
|
|
1983
|
+
* Data Controller/Processor of Major Importance tier, annual registration fee,
|
|
1984
|
+
* and Compliance Audit Returns obligations under NDPC GAID 2025.
|
|
1985
|
+
*/
|
|
1986
|
+
export declare function useDCPMI(input: DCPMIInput, options?: DCPMIClassificationOptions): DCPMIClassification;
|
|
1987
|
+
|
|
1834
1988
|
/**
|
|
1835
1989
|
* Convenience wrapper around `usePrivacyPolicy`. With `orgInfo` provided
|
|
1836
1990
|
* and `autoGenerate` enabled (default), `policy` is non-null on the first
|
package/dist/hooks.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
'use strict';require('./chunk-
|
|
2
|
+
'use strict';require('./chunk-MR7YZZDU.js');var chunkSDYLKJGC_js=require('./chunk-SDYLKJGC.js'),chunkEHQVTFYO_js=require('./chunk-EHQVTFYO.js'),chunkRC3XFXTJ_js=require('./chunk-RC3XFXTJ.js'),chunkQHW4UKGJ_js=require('./chunk-QHW4UKGJ.js'),chunkIRRUYR6M_js=require('./chunk-IRRUYR6M.js'),chunkHHK5LHEG_js=require('./chunk-HHK5LHEG.js'),chunkTLIHFGIJ_js=require('./chunk-TLIHFGIJ.js');require('./chunk-WKY26JLT.js'),require('./chunk-JS7SYL5P.js'),require('./chunk-7TTXS7JX.js'),require('./chunk-3YTAOT5O.js'),require('./chunk-D2ZKDQVL.js'),require('./chunk-6LJHLE6G.js'),require('./chunk-YFBDJ4FH.js'),require('./chunk-WZYCBW2R.js'),require('./chunk-4CVBQC66.js');var chunkQKXGVT2Q_js=require('./chunk-QKXGVT2Q.js'),chunkL2VO3MEJ_js=require('./chunk-L2VO3MEJ.js');require('./chunk-C2KEXHRX.js'),require('./chunk-DKLJ5DYN.js');var chunkTVA6D6S4_js=require('./chunk-TVA6D6S4.js');require('./chunk-R2ZZMATR.js');var chunkJLQT3W3E_js=require('./chunk-JLQT3W3E.js');require('./chunk-TQZWJGJ2.js'),require('./chunk-ZVOIR4QH.js'),require('./chunk-VWED6UTN.js'),require('./chunk-RFPLZDIO.js');Object.defineProperty(exports,"useComplianceAuditReturn",{enumerable:true,get:function(){return chunkSDYLKJGC_js.c}});Object.defineProperty(exports,"useComplianceScore",{enumerable:true,get:function(){return chunkSDYLKJGC_js.a}});Object.defineProperty(exports,"useDCPMI",{enumerable:true,get:function(){return chunkSDYLKJGC_js.b}});Object.defineProperty(exports,"useBreach",{enumerable:true,get:function(){return chunkEHQVTFYO_js.a}});Object.defineProperty(exports,"useDefaultPrivacyPolicy",{enumerable:true,get:function(){return chunkRC3XFXTJ_js.b}});Object.defineProperty(exports,"usePrivacyPolicy",{enumerable:true,get:function(){return chunkRC3XFXTJ_js.a}});Object.defineProperty(exports,"useAdaptivePolicyWizard",{enumerable:true,get:function(){return chunkQHW4UKGJ_js.a}});Object.defineProperty(exports,"useLawfulBasis",{enumerable:true,get:function(){return chunkIRRUYR6M_js.a}});Object.defineProperty(exports,"useCrossBorderTransfer",{enumerable:true,get:function(){return chunkHHK5LHEG_js.a}});Object.defineProperty(exports,"useROPA",{enumerable:true,get:function(){return chunkTLIHFGIJ_js.a}});Object.defineProperty(exports,"useConsent",{enumerable:true,get:function(){return chunkQKXGVT2Q_js.a}});Object.defineProperty(exports,"useFocusTrap",{enumerable:true,get:function(){return chunkL2VO3MEJ_js.a}});Object.defineProperty(exports,"useDSR",{enumerable:true,get:function(){return chunkTVA6D6S4_js.a}});Object.defineProperty(exports,"useDPIA",{enumerable:true,get:function(){return chunkJLQT3W3E_js.a}});
|
package/dist/hooks.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import'./chunk-
|
|
2
|
+
import'./chunk-65TYKXUI.mjs';export{c as useComplianceAuditReturn,a as useComplianceScore,b as useDCPMI}from'./chunk-TQCKLZ4F.mjs';export{a as useBreach}from'./chunk-RFXGD5NE.mjs';export{b as useDefaultPrivacyPolicy,a as usePrivacyPolicy}from'./chunk-UVXS7KRV.mjs';export{a as useAdaptivePolicyWizard}from'./chunk-KE2FZH2V.mjs';export{a as useLawfulBasis}from'./chunk-B6BRD5SL.mjs';export{a as useCrossBorderTransfer}from'./chunk-KDAZQO3N.mjs';export{a as useROPA}from'./chunk-FRMVSG4N.mjs';import'./chunk-SZXHNJGG.mjs';import'./chunk-IVSNHT24.mjs';import'./chunk-6A7M4CGJ.mjs';import'./chunk-WTGKZX7J.mjs';import'./chunk-NBQQ2GN3.mjs';import'./chunk-BIJSMSUU.mjs';import'./chunk-7BJXI2HI.mjs';import'./chunk-LWIKDDSU.mjs';import'./chunk-XP5PL6K7.mjs';export{a as useConsent}from'./chunk-PQ5IPUJN.mjs';export{a as useFocusTrap}from'./chunk-YTU4FNM2.mjs';import'./chunk-XC3DLYEG.mjs';import'./chunk-R3ZKV2J7.mjs';export{a as useDSR}from'./chunk-ZSRO4L3C.mjs';import'./chunk-RRVML7CU.mjs';export{a as useDPIA}from'./chunk-I3V3ITN7.mjs';import'./chunk-LRRENTT5.mjs';import'./chunk-ITCY2Z66.mjs';import'./chunk-DBZSN4WP.mjs';import'./chunk-ZJYULEER.mjs';
|
package/dist/index.d.mts
CHANGED
|
@@ -639,6 +639,74 @@ export declare function calculateBreachSeverity(report: BreachReport, assessment
|
|
|
639
639
|
justification: string;
|
|
640
640
|
};
|
|
641
641
|
|
|
642
|
+
/**
|
|
643
|
+
* Compliance Audit Returns (CAR) scheduling under the NDPC General Application
|
|
644
|
+
* and Implementation Directive (GAID) 2025.
|
|
645
|
+
*
|
|
646
|
+
* A Data Controller/Processor of Major Importance (DCPMI) must conduct an
|
|
647
|
+
* initial compliance audit within 15 months of commencing data processing, and
|
|
648
|
+
* thereafter file a Compliance Audit Return with the NDPC annually (default
|
|
649
|
+
* deadline 31 March, filed through the NDPC Information Management Portal/NIMP).
|
|
650
|
+
*
|
|
651
|
+
* This computes the schedule (initial-audit due date, the next annual filing
|
|
652
|
+
* deadline relative to a reference date) and a light status. NDPC deadlines
|
|
653
|
+
* shift (the 2026 filing was extended to 30 May), so the annual deadline is
|
|
654
|
+
* configurable and per-year overrides are supported. The audit *content* itself
|
|
655
|
+
* is the organisation's compliance posture — pair this with `getComplianceScore`.
|
|
656
|
+
*
|
|
657
|
+
* @see NDPC General Application and Implementation Directive (GAID) 2025
|
|
658
|
+
*/
|
|
659
|
+
|
|
660
|
+
export declare interface CARInput {
|
|
661
|
+
/** ISO date (YYYY-MM-DD) the organisation commenced data processing. */
|
|
662
|
+
commencementDate: string;
|
|
663
|
+
/** Reference date to evaluate against (YYYY-MM-DD). Defaults to today. */
|
|
664
|
+
asOf?: string;
|
|
665
|
+
/** DCPMI tier; CAR applies to DCPMIs only. Omit to assume applicable. */
|
|
666
|
+
tier?: DCPMITier;
|
|
667
|
+
}
|
|
668
|
+
|
|
669
|
+
export declare interface CAROptions {
|
|
670
|
+
/** Default annual filing deadline (month is 1-12). Defaults to 31 March. */
|
|
671
|
+
annualDeadline?: {
|
|
672
|
+
month: number;
|
|
673
|
+
day: number;
|
|
674
|
+
};
|
|
675
|
+
/** Per-year overrides for the annual deadline, e.g. `{ 2026: '2026-05-30' }`. */
|
|
676
|
+
deadlineOverrides?: Record<number, string>;
|
|
677
|
+
/** Months after commencement the initial audit is due. Defaults to 15. */
|
|
678
|
+
initialAuditWithinMonths?: number;
|
|
679
|
+
}
|
|
680
|
+
|
|
681
|
+
/**
|
|
682
|
+
* Classify an organisation's DCPMI status, registration tier, annual fee, and
|
|
683
|
+
* Compliance Audit Returns obligations under NDPC GAID 2025.
|
|
684
|
+
*/
|
|
685
|
+
export declare function classifyDCPMI(input: DCPMIInput, options?: DCPMIClassificationOptions): DCPMIClassification;
|
|
686
|
+
|
|
687
|
+
export declare interface ComplianceAuditReturn {
|
|
688
|
+
/** Whether CAR applies (false for non-DCPMI organisations). */
|
|
689
|
+
applicable: boolean;
|
|
690
|
+
schedule: {
|
|
691
|
+
commencementDate: string;
|
|
692
|
+
initialAuditWithinMonths: number;
|
|
693
|
+
/** Commencement date + the initial-audit window. */
|
|
694
|
+
initialAuditDueDate: string;
|
|
695
|
+
/** The next annual filing deadline on or after `asOf`. */
|
|
696
|
+
nextFilingDeadline: string;
|
|
697
|
+
/** The year the next filing deadline falls in. */
|
|
698
|
+
filingYear: number;
|
|
699
|
+
};
|
|
700
|
+
status: {
|
|
701
|
+
/** Whether the initial-audit obligation has arisen (asOf ≥ due date). */
|
|
702
|
+
initialAuditDue: boolean;
|
|
703
|
+
/** Whole days from `asOf` to the next filing deadline. */
|
|
704
|
+
daysUntilNextDeadline: number;
|
|
705
|
+
};
|
|
706
|
+
notes: string[];
|
|
707
|
+
asOf: string;
|
|
708
|
+
}
|
|
709
|
+
|
|
642
710
|
/** A single gap found during NDPA compliance evaluation. */
|
|
643
711
|
declare interface ComplianceGap {
|
|
644
712
|
/** Machine-readable requirement identifier. */
|
|
@@ -1408,6 +1476,90 @@ declare interface DataCategory {
|
|
|
1408
1476
|
selected: boolean;
|
|
1409
1477
|
}
|
|
1410
1478
|
|
|
1479
|
+
export declare interface DCPMIClassification {
|
|
1480
|
+
/** Registration tier (or `'none'` when not a DCPMI). */
|
|
1481
|
+
tier: DCPMITier;
|
|
1482
|
+
/** Whether the organisation is a Data Controller/Processor of Major Importance. */
|
|
1483
|
+
isDCPMI: boolean;
|
|
1484
|
+
/** Annual registration fee in Nigerian Naira (0 when not a volume-tiered DCPMI). */
|
|
1485
|
+
annualFeeNGN: number;
|
|
1486
|
+
registration: {
|
|
1487
|
+
/** Whether NDPC registration is required. */
|
|
1488
|
+
required: boolean;
|
|
1489
|
+
/** OHL renews registration annually; UHL/EHL register once and file CAR annually. */
|
|
1490
|
+
renewsAnnually: boolean;
|
|
1491
|
+
};
|
|
1492
|
+
compliance: {
|
|
1493
|
+
/** Whether the organisation must file annual Compliance Audit Returns (CAR). */
|
|
1494
|
+
auditReturnsAnnual: boolean;
|
|
1495
|
+
/** Initial compliance audit is due within this many months of commencing processing. */
|
|
1496
|
+
initialAuditWithinMonths: number;
|
|
1497
|
+
};
|
|
1498
|
+
/** Human-readable caveats and next steps. */
|
|
1499
|
+
notes: string[];
|
|
1500
|
+
/** The count actually used for classification, after defensive normalisation. */
|
|
1501
|
+
dataSubjectsConsidered: number;
|
|
1502
|
+
}
|
|
1503
|
+
|
|
1504
|
+
export declare interface DCPMIClassificationOptions {
|
|
1505
|
+
thresholds?: Partial<DCPMIThresholds>;
|
|
1506
|
+
fees?: Partial<DCPMIFees>;
|
|
1507
|
+
}
|
|
1508
|
+
|
|
1509
|
+
export declare interface DCPMIFees {
|
|
1510
|
+
UHL: number;
|
|
1511
|
+
EHL: number;
|
|
1512
|
+
OHL: number;
|
|
1513
|
+
}
|
|
1514
|
+
|
|
1515
|
+
export declare interface DCPMIInput {
|
|
1516
|
+
/** Distinct data subjects whose data was processed in the relevant six-month window. */
|
|
1517
|
+
dataSubjectsInSixMonths?: number;
|
|
1518
|
+
/** True if the Commission has separately designated/listed the organisation as a DCPMI. */
|
|
1519
|
+
isDesignated?: boolean;
|
|
1520
|
+
}
|
|
1521
|
+
|
|
1522
|
+
export declare interface DCPMIThresholds {
|
|
1523
|
+
/** Lower bound (inclusive) for OHL. */
|
|
1524
|
+
ohl: number;
|
|
1525
|
+
/** Lower bound (inclusive) for EHL. */
|
|
1526
|
+
ehl: number;
|
|
1527
|
+
/** A count strictly greater than this is UHL. */
|
|
1528
|
+
uhl: number;
|
|
1529
|
+
}
|
|
1530
|
+
|
|
1531
|
+
/**
|
|
1532
|
+
* Data Controller/Processor of Major Importance (DCPMI) classification under the
|
|
1533
|
+
* NDPC General Application and Implementation Directive (GAID) 2025.
|
|
1534
|
+
*
|
|
1535
|
+
* Volume-based tiers — data subjects processed within a six-month window:
|
|
1536
|
+
* - UHL (Ultra High Level): more than 5,000 → ₦250,000 / year
|
|
1537
|
+
* - EHL (Extra High Level): 1,000 – 5,000 → ₦100,000 / year
|
|
1538
|
+
* - OHL (Ordinary High Level): 200 – 999 → ₦10,000 / year
|
|
1539
|
+
* - below 200: not a DCPMI by volume
|
|
1540
|
+
*
|
|
1541
|
+
* Boundaries: the 1,000 mark resolves to EHL (so OHL is 200–999); UHL is
|
|
1542
|
+
* strictly greater than 5,000 (so 5,000 itself is EHL). The NDPC has revised
|
|
1543
|
+
* classification metrics before and shifts filing deadlines, so thresholds and
|
|
1544
|
+
* fees are configurable — treat the defaults as the September 2025 GAID
|
|
1545
|
+
* baseline, not a constant.
|
|
1546
|
+
*
|
|
1547
|
+
* `isDesignated` marks an organisation the Commission has otherwise listed as a
|
|
1548
|
+
* DCPMI; it is then a DCPMI regardless of volume. Below the volume tiers such an
|
|
1549
|
+
* organisation is reported as `'listed'` with the fee left at 0 and a note to
|
|
1550
|
+
* confirm the applicable tier/fee with the NDPC.
|
|
1551
|
+
*
|
|
1552
|
+
* @see NDPC General Application and Implementation Directive (GAID) 2025
|
|
1553
|
+
* @see NDPC Guidance Notice on the Registration of Data Controllers and Processors of Major Importance
|
|
1554
|
+
*/
|
|
1555
|
+
export declare type DCPMITier = 'UHL' | 'EHL' | 'OHL' | 'listed' | 'none';
|
|
1556
|
+
|
|
1557
|
+
/** September 2025 GAID baseline annual fees (NGN). */
|
|
1558
|
+
export declare const DEFAULT_DCPMI_FEES_NGN: DCPMIFees;
|
|
1559
|
+
|
|
1560
|
+
/** September 2025 GAID baseline — override via {@link DCPMIClassificationOptions} as the rules evolve. */
|
|
1561
|
+
export declare const DEFAULT_DCPMI_THRESHOLDS: DCPMIThresholds;
|
|
1562
|
+
|
|
1411
1563
|
/**
|
|
1412
1564
|
* Default NDPA-compliant privacy policy sections.
|
|
1413
1565
|
* Each section uses {{variable}} placeholders that are resolved at generation time.
|
|
@@ -2231,6 +2383,11 @@ export declare interface FormatDSRRequestStructuredResult {
|
|
|
2231
2383
|
data?: DSRRequest;
|
|
2232
2384
|
}
|
|
2233
2385
|
|
|
2386
|
+
/**
|
|
2387
|
+
* Derive the CAR schedule and status for a DCPMI under NDPC GAID 2025.
|
|
2388
|
+
*/
|
|
2389
|
+
export declare function generateComplianceAuditReturn(input: CARInput, options?: CAROptions): ComplianceAuditReturn;
|
|
2390
|
+
|
|
2234
2391
|
/**
|
|
2235
2392
|
* Generates a summary of all lawful basis documentation across processing activities.
|
|
2236
2393
|
*
|
|
@@ -4457,6 +4614,13 @@ declare interface UseBreachReturn {
|
|
|
4457
4614
|
isLoading: boolean;
|
|
4458
4615
|
}
|
|
4459
4616
|
|
|
4617
|
+
/**
|
|
4618
|
+
* React hook that memoises the `generateComplianceAuditReturn` utility — derives
|
|
4619
|
+
* a DCPMI's Compliance Audit Returns schedule (initial-audit due date, next
|
|
4620
|
+
* annual filing deadline) and status under NDPC GAID 2025.
|
|
4621
|
+
*/
|
|
4622
|
+
export declare function useComplianceAuditReturn(input: CARInput, options?: CAROptions): ComplianceAuditReturn;
|
|
4623
|
+
|
|
4460
4624
|
/**
|
|
4461
4625
|
* Computes an NDPA compliance score and returns a structured report
|
|
4462
4626
|
* (score, rating, per-module breakdown, recommendations).
|
|
@@ -4674,6 +4838,13 @@ declare interface UseCrossBorderTransferReturn {
|
|
|
4674
4838
|
isLoading: boolean;
|
|
4675
4839
|
}
|
|
4676
4840
|
|
|
4841
|
+
/**
|
|
4842
|
+
* React hook that memoises the `classifyDCPMI` utility — derives an organisation's
|
|
4843
|
+
* Data Controller/Processor of Major Importance tier, annual registration fee,
|
|
4844
|
+
* and Compliance Audit Returns obligations under NDPC GAID 2025.
|
|
4845
|
+
*/
|
|
4846
|
+
export declare function useDCPMI(input: DCPMIInput, options?: DCPMIClassificationOptions): DCPMIClassification;
|
|
4847
|
+
|
|
4677
4848
|
/**
|
|
4678
4849
|
* Convenience wrapper around `usePrivacyPolicy`. With `orgInfo` provided
|
|
4679
4850
|
* and `autoGenerate` enabled (default), `policy` is non-null on the first
|