@tantainnovative/ndpr-toolkit 5.4.0 → 5.5.1

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/server.d.ts CHANGED
@@ -198,6 +198,12 @@ export declare const arabicLocale: Required<{
198
198
  */
199
199
  export declare function assemblePolicy(context: TemplateContext): PolicySection[];
200
200
 
201
+ /**
202
+ * Assess a breach report against the NDPA S. 40 / GAID 2025 Article 33
203
+ * notification requirements.
204
+ */
205
+ export declare function assessBreachNotification(report: BreachReport, options?: BreachNotificationOptions): BreachNotificationAssessment;
206
+
201
207
  /**
202
208
  * Analyzes all processing activities and returns compliance gaps including
203
209
  * missing DPO approval, overdue reviews, undocumented justifications,
@@ -229,6 +235,15 @@ export declare function assessDPIARisk(dpiaResult: DPIAResult): {
229
235
  */
230
236
  export declare function assessTransferRisk(transfer: CrossBorderTransfer): TransferRiskResult;
231
237
 
238
+ export declare interface AuditCheck {
239
+ id: string;
240
+ label: string;
241
+ status: AuditCheckStatus;
242
+ detail: string;
243
+ }
244
+
245
+ export declare type AuditCheckStatus = 'pass' | 'warn' | 'fail';
246
+
232
247
  /**
233
248
  * Breach notification types aligned with NDPA 2023 Section 40
234
249
  * Data controllers must notify the NDPC within 72 hours of becoming aware of a breach
@@ -248,6 +263,93 @@ export declare interface BreachCategory {
248
263
  defaultSeverity: 'low' | 'medium' | 'high' | 'critical';
249
264
  }
250
265
 
266
+ export declare interface BreachNotificationAssessment {
267
+ /** Whether all applicable mandated content items are satisfied. */
268
+ complete: boolean;
269
+ /** Completeness of applicable content items, 0–100. */
270
+ completeness: number;
271
+ /** GAID 2025 Article 33(5) / NDPA S. 40(2) content of the notification to the Commission. */
272
+ notificationToCommission: BreachNotificationItem[];
273
+ /** NDPA S. 40(3) communication to data subjects — populated only when high-risk. */
274
+ dataSubjectCommunication: BreachNotificationItem[];
275
+ /** Whether a data-subject communication is owed (high risk). */
276
+ dataSubjectCommunicationRequired: boolean;
277
+ timing: BreachNotificationTiming;
278
+ /** Labels of unsatisfied applicable items. */
279
+ missing: string[];
280
+ /** Actionable next steps, including timing warnings. */
281
+ recommendations: string[];
282
+ asOf: number;
283
+ }
284
+
285
+ declare interface BreachNotificationItem {
286
+ /** Stable identifier for the requirement. */
287
+ id: string;
288
+ /** Human-readable requirement. */
289
+ label: string;
290
+ /** Authoritative citation, e.g. `GAID 2025 Art. 33(5)(a)`. */
291
+ section: string;
292
+ /** Whether the report satisfies it. */
293
+ satisfied: boolean;
294
+ }
295
+
296
+ /**
297
+ * Personal-data-breach notification completeness checker for NDPA 2023
298
+ * Section 40, as detailed by NDPC General Application and Implementation
299
+ * Directive (GAID) 2025 Article 33.
300
+ *
301
+ * Section 40(2) requires a data controller to notify the Commission within 72
302
+ * hours of becoming aware of a breach likely to result in a risk to data
303
+ * subjects' rights and freedoms. GAID 2025 Article 33(5)(a)–(h) enumerates the
304
+ * content that a notification to the Commission "shall include". Where the
305
+ * breach is likely to result in a *high* risk, Section 40(3) additionally
306
+ * requires the controller to communicate the breach to affected data subjects
307
+ * in plain and clear language.
308
+ *
309
+ * This assesses a `BreachReport` against those requirements: which mandated
310
+ * content items are present, whether the 72-hour window is met, and whether a
311
+ * data-subject communication is owed. It is a documentation-completeness aid,
312
+ * not legal advice — verify against current NDPC guidance.
313
+ *
314
+ * @see NDPA 2023 Section 40 (Personal data breaches)
315
+ * @see NDPC GAID 2025 Article 33 (Data Breach Notification)
316
+ */
317
+
318
+ export declare interface BreachNotificationOptions {
319
+ /** Risk assessment for the breach; drives whether data-subject communication is required. */
320
+ assessment?: RiskAssessment;
321
+ /** The regulatory notification actually sent, if any — used to judge timeliness. */
322
+ notification?: RegulatoryNotification;
323
+ /** Reference "now" in epoch ms. Defaults to `Date.now()`. */
324
+ asOf?: number;
325
+ /** Notification window in hours. Defaults to 72 (NDPA S. 40(2)). */
326
+ deadlineHours?: number;
327
+ /**
328
+ * Explicit high-risk flag (NDPA S. 40(3)). When omitted, derived from
329
+ * `assessment.highRisksToRightsAndFreedoms`.
330
+ */
331
+ highRisk?: boolean;
332
+ }
333
+
334
+ declare interface BreachNotificationTiming {
335
+ /** `discoveredAt` + the notification window. */
336
+ deadline: number;
337
+ /** Whole hours between discovery and `asOf`. */
338
+ hoursSinceDiscovery: number;
339
+ /** Whether a regulatory notification has been recorded. */
340
+ notified: boolean;
341
+ /** When the regulatory notification was sent, if any. */
342
+ notifiedAt?: number;
343
+ /** Whether the notification (or, if none, `asOf`) falls within the deadline. */
344
+ withinDeadline: boolean;
345
+ /** Whole hours from `asOf` to the deadline (negative once past). */
346
+ hoursRemaining: number;
347
+ /** Whether the deadline has been missed. */
348
+ overdue: boolean;
349
+ /** Late filings must state the reasons for the delay (NDPA S. 40(2)). */
350
+ requiresDelayJustification: boolean;
351
+ }
352
+
251
353
  /**
252
354
  * Represents a data breach report
253
355
  */
@@ -350,6 +452,74 @@ export declare function calculateBreachSeverity(report: BreachReport, assessment
350
452
  justification: string;
351
453
  };
352
454
 
455
+ /**
456
+ * Compliance Audit Returns (CAR) scheduling under the NDPC General Application
457
+ * and Implementation Directive (GAID) 2025.
458
+ *
459
+ * A Data Controller/Processor of Major Importance (DCPMI) must conduct an
460
+ * initial compliance audit within 15 months of commencing data processing, and
461
+ * thereafter file a Compliance Audit Return with the NDPC annually (default
462
+ * deadline 31 March, filed through the NDPC Information Management Portal/NIMP).
463
+ *
464
+ * This computes the schedule (initial-audit due date, the next annual filing
465
+ * deadline relative to a reference date) and a light status. NDPC deadlines
466
+ * shift (the 2026 filing was extended to 30 May), so the annual deadline is
467
+ * configurable and per-year overrides are supported. The audit *content* itself
468
+ * is the organisation's compliance posture — pair this with `getComplianceScore`.
469
+ *
470
+ * @see NDPC General Application and Implementation Directive (GAID) 2025
471
+ */
472
+
473
+ export declare interface CARInput {
474
+ /** ISO date (YYYY-MM-DD) the organisation commenced data processing. */
475
+ commencementDate: string;
476
+ /** Reference date to evaluate against (YYYY-MM-DD). Defaults to today. */
477
+ asOf?: string;
478
+ /** DCPMI tier; CAR applies to DCPMIs only. Omit to assume applicable. */
479
+ tier?: DCPMITier;
480
+ }
481
+
482
+ export declare interface CAROptions {
483
+ /** Default annual filing deadline (month is 1-12). Defaults to 31 March. */
484
+ annualDeadline?: {
485
+ month: number;
486
+ day: number;
487
+ };
488
+ /** Per-year overrides for the annual deadline, e.g. `{ 2026: '2026-05-30' }`. */
489
+ deadlineOverrides?: Record<number, string>;
490
+ /** Months after commencement the initial audit is due. Defaults to 15. */
491
+ initialAuditWithinMonths?: number;
492
+ }
493
+
494
+ /**
495
+ * Classify an organisation's DCPMI status, registration tier, annual fee, and
496
+ * Compliance Audit Returns obligations under NDPC GAID 2025.
497
+ */
498
+ export declare function classifyDCPMI(input: DCPMIInput, options?: DCPMIClassificationOptions): DCPMIClassification;
499
+
500
+ export declare interface ComplianceAuditReturn {
501
+ /** Whether CAR applies (false for non-DCPMI organisations). */
502
+ applicable: boolean;
503
+ schedule: {
504
+ commencementDate: string;
505
+ initialAuditWithinMonths: number;
506
+ /** Commencement date + the initial-audit window. */
507
+ initialAuditDueDate: string;
508
+ /** The next annual filing deadline on or after `asOf`. */
509
+ nextFilingDeadline: string;
510
+ /** The year the next filing deadline falls in. */
511
+ filingYear: number;
512
+ };
513
+ status: {
514
+ /** Whether the initial-audit obligation has arisen (asOf ≥ due date). */
515
+ initialAuditDue: boolean;
516
+ /** Whole days from `asOf` to the next filing deadline. */
517
+ daysUntilNextDeadline: number;
518
+ };
519
+ notes: string[];
520
+ asOf: string;
521
+ }
522
+
353
523
  /** A single gap found during NDPA compliance evaluation. */
354
524
  export declare interface ComplianceGap {
355
525
  /** Machine-readable requirement identifier. */
@@ -771,6 +941,84 @@ export declare interface DataCategory {
771
941
  selected: boolean;
772
942
  }
773
943
 
944
+ export declare interface DCPMIClassification {
945
+ /** Registration tier (or `'none'` when not a DCPMI). */
946
+ tier: DCPMITier;
947
+ /** Whether the organisation is a Data Controller/Processor of Major Importance. */
948
+ isDCPMI: boolean;
949
+ /** Annual registration fee in Nigerian Naira (0 when not a volume-tiered DCPMI). */
950
+ annualFeeNGN: number;
951
+ registration: {
952
+ /** Whether NDPC registration is required. */
953
+ required: boolean;
954
+ /** OHL renews registration annually; UHL/EHL register once and file CAR annually. */
955
+ renewsAnnually: boolean;
956
+ };
957
+ compliance: {
958
+ /** Whether the organisation must file annual Compliance Audit Returns (CAR). */
959
+ auditReturnsAnnual: boolean;
960
+ /** Initial compliance audit is due within this many months of commencing processing. */
961
+ initialAuditWithinMonths: number;
962
+ };
963
+ /** Human-readable caveats and next steps. */
964
+ notes: string[];
965
+ /** The count actually used for classification, after defensive normalisation. */
966
+ dataSubjectsConsidered: number;
967
+ }
968
+
969
+ export declare interface DCPMIClassificationOptions {
970
+ thresholds?: Partial<DCPMIThresholds>;
971
+ fees?: Partial<DCPMIFees>;
972
+ }
973
+
974
+ declare interface DCPMIFees {
975
+ UHL: number;
976
+ EHL: number;
977
+ OHL: number;
978
+ }
979
+
980
+ export declare interface DCPMIInput {
981
+ /** Distinct data subjects whose data was processed in the relevant six-month window. */
982
+ dataSubjectsInSixMonths?: number;
983
+ /** True if the Commission has separately designated/listed the organisation as a DCPMI. */
984
+ isDesignated?: boolean;
985
+ }
986
+
987
+ declare interface DCPMIThresholds {
988
+ /** Lower bound (inclusive) for OHL. */
989
+ ohl: number;
990
+ /** Lower bound (inclusive) for EHL. */
991
+ ehl: number;
992
+ /** A count strictly greater than this is UHL. */
993
+ uhl: number;
994
+ }
995
+
996
+ /**
997
+ * Data Controller/Processor of Major Importance (DCPMI) classification under the
998
+ * NDPC General Application and Implementation Directive (GAID) 2025.
999
+ *
1000
+ * Volume-based tiers — data subjects processed within a six-month window:
1001
+ * - UHL (Ultra High Level): more than 5,000 → ₦250,000 / year
1002
+ * - EHL (Extra High Level): 1,000 – 5,000 → ₦100,000 / year
1003
+ * - OHL (Ordinary High Level): 200 – 999 → ₦10,000 / year
1004
+ * - below 200: not a DCPMI by volume
1005
+ *
1006
+ * Boundaries: the 1,000 mark resolves to EHL (so OHL is 200–999); UHL is
1007
+ * strictly greater than 5,000 (so 5,000 itself is EHL). The NDPC has revised
1008
+ * classification metrics before and shifts filing deadlines, so thresholds and
1009
+ * fees are configurable — treat the defaults as the September 2025 GAID
1010
+ * baseline, not a constant.
1011
+ *
1012
+ * `isDesignated` marks an organisation the Commission has otherwise listed as a
1013
+ * DCPMI; it is then a DCPMI regardless of volume. Below the volume tiers such an
1014
+ * organisation is reported as `'listed'` with the fee left at 0 and a note to
1015
+ * confirm the applicable tier/fee with the NDPC.
1016
+ *
1017
+ * @see NDPC General Application and Implementation Directive (GAID) 2025
1018
+ * @see NDPC Guidance Notice on the Registration of Data Controllers and Processors of Major Importance
1019
+ */
1020
+ export declare type DCPMITier = 'UHL' | 'EHL' | 'OHL' | 'listed' | 'none';
1021
+
774
1022
  /**
775
1023
  * Comprehensive set of 16 data categories spanning identity, financial,
776
1024
  * behavioral, sensitive, and children groups. Used to populate the wizard
@@ -1194,6 +1442,11 @@ export declare function exportROPAToCSV(ropa: RecordOfProcessingActivities): str
1194
1442
  */
1195
1443
  export declare function findUnfilledTokens(rendered: string): string[];
1196
1444
 
1445
+ export declare interface FormatAuditReportOptions {
1446
+ /** Wrap status symbols in ANSI colour codes. Default false. */
1447
+ color?: boolean;
1448
+ }
1449
+
1197
1450
  /**
1198
1451
  * Format a DSR request for display or submission. Returns the formatted
1199
1452
  * payload plus a typed `errors` array of `{ field, code, message }` for any
@@ -1219,10 +1472,20 @@ export declare interface FormatDSRRequestStructuredResult {
1219
1472
  data?: DSRRequest;
1220
1473
  }
1221
1474
 
1475
+ /**
1476
+ * Render an `NdprAuditResult` as a plain-text report.
1477
+ */
1478
+ export declare function formatNdprAuditReport(result: NdprAuditResult, options?: FormatAuditReportOptions): string;
1479
+
1222
1480
  export declare const frenchLocale: Required<{
1223
1481
  [K in keyof NDPRLocale]: Required<NonNullable<NDPRLocale[K]>>;
1224
1482
  }>;
1225
1483
 
1484
+ /**
1485
+ * Derive the CAR schedule and status for a DCPMI under NDPC GAID 2025.
1486
+ */
1487
+ export declare function generateComplianceAuditReturn(input: CARInput, options?: CAROptions): ComplianceAuditReturn;
1488
+
1226
1489
  /**
1227
1490
  * Generates a summary of all lawful basis documentation across processing activities.
1228
1491
  *
@@ -1506,6 +1769,58 @@ export declare interface ModuleScore {
1506
1769
  gaps: string[];
1507
1770
  }
1508
1771
 
1772
+ /**
1773
+ * Aggregate NDPA 2023 compliance audit — combines the compliance-score engine
1774
+ * with the GAID 2025 DCPMI classifier, Compliance Audit Returns scheduler, and
1775
+ * breach-notification checker into a single pass/fail result suitable for CI.
1776
+ *
1777
+ * Pure and React-free: drive it from a config file via the `ndpr audit` CLI, a
1778
+ * CI job, or a server route. Not legal advice — verify against current NDPC
1779
+ * guidance.
1780
+ */
1781
+
1782
+ export declare interface NdprAuditInput {
1783
+ /** Compliance posture across the 8 NDPA modules. */
1784
+ compliance: ComplianceInput;
1785
+ /** Optional DCPMI classification input (GAID 2025 registration). */
1786
+ dcpmi?: DCPMIInput;
1787
+ /** Optional Compliance Audit Returns scheduling input. */
1788
+ car?: CARInput;
1789
+ /** Optional breach reports to check against the S. 40 / Article 33 duty. */
1790
+ breaches?: BreachReport[];
1791
+ }
1792
+
1793
+ export declare interface NdprAuditOptions {
1794
+ /** Minimum overall compliance score required to pass. Default 70. */
1795
+ minScore?: number;
1796
+ dcpmiOptions?: DCPMIClassificationOptions;
1797
+ carOptions?: CAROptions;
1798
+ breachOptions?: BreachNotificationOptions;
1799
+ }
1800
+
1801
+ export declare interface NdprAuditResult {
1802
+ /** True when the score meets `minScore` and no check is a hard failure. */
1803
+ passed: boolean;
1804
+ score: number;
1805
+ rating: ComplianceRating;
1806
+ minScore: number;
1807
+ checks: AuditCheck[];
1808
+ compliance: ComplianceReport;
1809
+ dcpmi?: DCPMIClassification;
1810
+ car?: ComplianceAuditReturn;
1811
+ breaches: Array<{
1812
+ id: string;
1813
+ title: string;
1814
+ assessment: BreachNotificationAssessment;
1815
+ }>;
1816
+ summary: {
1817
+ pass: number;
1818
+ warn: number;
1819
+ fail: number;
1820
+ };
1821
+ generatedAt: string;
1822
+ }
1823
+
1509
1824
  /**
1510
1825
  * Locale strings for all toolkit components.
1511
1826
  * Pass partial overrides — missing keys fall back to English defaults.
@@ -2281,6 +2596,11 @@ export declare interface ROPAValidationResult {
2281
2596
  errors: string[];
2282
2597
  }
2283
2598
 
2599
+ /**
2600
+ * Run the aggregate NDPA compliance audit.
2601
+ */
2602
+ export declare function runNdprAudit(input: NdprAuditInput, options?: NdprAuditOptions): NdprAuditResult;
2603
+
2284
2604
  /**
2285
2605
  * Sanitizes user input to prevent XSS attacks.
2286
2606
  * Escapes HTML special characters so that data rendered in dashboards
package/dist/server.js CHANGED
@@ -1 +1 @@
1
- 'use strict';var chunkR3CU7DTT_js=require('./chunk-R3CU7DTT.js'),chunkLP5KXMBY_js=require('./chunk-LP5KXMBY.js'),chunkNUOHT3LO_js=require('./chunk-NUOHT3LO.js'),chunkJS7SYL5P_js=require('./chunk-JS7SYL5P.js'),chunk7TTXS7JX_js=require('./chunk-7TTXS7JX.js'),chunk3YTAOT5O_js=require('./chunk-3YTAOT5O.js'),chunkD2ZKDQVL_js=require('./chunk-D2ZKDQVL.js'),chunk6LJHLE6G_js=require('./chunk-6LJHLE6G.js'),chunkYFBDJ4FH_js=require('./chunk-YFBDJ4FH.js'),chunkWZYCBW2R_js=require('./chunk-WZYCBW2R.js'),chunk4CVBQC66_js=require('./chunk-4CVBQC66.js'),chunk3IA3KDII_js=require('./chunk-3IA3KDII.js'),chunkC2KEXHRX_js=require('./chunk-C2KEXHRX.js'),chunkDKLJ5DYN_js=require('./chunk-DKLJ5DYN.js'),chunkUXUMYP4L_js=require('./chunk-UXUMYP4L.js'),chunkR2ZZMATR_js=require('./chunk-R2ZZMATR.js'),chunkTQZWJGJ2_js=require('./chunk-TQZWJGJ2.js'),chunkZVOIR4QH_js=require('./chunk-ZVOIR4QH.js'),chunk7563FVMY_js=require('./chunk-7563FVMY.js'),chunkVWED6UTN_js=require('./chunk-VWED6UTN.js');require('./chunk-RFPLZDIO.js');Object.defineProperty(exports,"apiAdapter",{enumerable:true,get:function(){return chunkR3CU7DTT_js.a}});Object.defineProperty(exports,"composeAdapters",{enumerable:true,get:function(){return chunkR3CU7DTT_js.c}});Object.defineProperty(exports,"memoryAdapter",{enumerable:true,get:function(){return chunkR3CU7DTT_js.b}});Object.defineProperty(exports,"arabicLocale",{enumerable:true,get:function(){return chunkLP5KXMBY_js.e}});Object.defineProperty(exports,"frenchLocale",{enumerable:true,get:function(){return chunkLP5KXMBY_js.f}});Object.defineProperty(exports,"hausaLocale",{enumerable:true,get:function(){return chunkLP5KXMBY_js.c}});Object.defineProperty(exports,"igboLocale",{enumerable:true,get:function(){return chunkLP5KXMBY_js.b}});Object.defineProperty(exports,"pidginLocale",{enumerable:true,get:function(){return chunkLP5KXMBY_js.d}});Object.defineProperty(exports,"yorubaLocale",{enumerable:true,get:function(){return chunkLP5KXMBY_js.a}});Object.defineProperty(exports,"ORG_POLICY_TEMPLATE_REGISTRY",{enumerable:true,get:function(){return chunkNUOHT3LO_js.a}});Object.defineProperty(exports,"createOrgTemplate",{enumerable:true,get:function(){return chunkNUOHT3LO_js.b}});Object.defineProperty(exports,"templateContextFor",{enumerable:true,get:function(){return chunkNUOHT3LO_js.b}});Object.defineProperty(exports,"exportDOCX",{enumerable:true,get:function(){return chunkJS7SYL5P_js.d}});Object.defineProperty(exports,"exportHTML",{enumerable:true,get:function(){return chunkJS7SYL5P_js.a}});Object.defineProperty(exports,"exportMarkdown",{enumerable:true,get:function(){return chunkJS7SYL5P_js.b}});Object.defineProperty(exports,"exportPDF",{enumerable:true,get:function(){return chunkJS7SYL5P_js.c}});Object.defineProperty(exports,"getComplianceScore",{enumerable:true,get:function(){return chunk7TTXS7JX_js.a}});Object.defineProperty(exports,"calculateBreachSeverity",{enumerable:true,get:function(){return chunk3YTAOT5O_js.a}});Object.defineProperty(exports,"DEFAULT_POLICY_SECTIONS",{enumerable:true,get:function(){return chunkD2ZKDQVL_js.c}});Object.defineProperty(exports,"DEFAULT_POLICY_VARIABLES",{enumerable:true,get:function(){return chunkD2ZKDQVL_js.d}});Object.defineProperty(exports,"createBusinessPolicyTemplate",{enumerable:true,get:function(){return chunkD2ZKDQVL_js.e}});Object.defineProperty(exports,"findUnfilledTokens",{enumerable:true,get:function(){return chunkD2ZKDQVL_js.a}});Object.defineProperty(exports,"generatePolicyText",{enumerable:true,get:function(){return chunkD2ZKDQVL_js.b}});Object.defineProperty(exports,"DEFAULT_DATA_CATEGORIES",{enumerable:true,get:function(){return chunk6LJHLE6G_js.d}});Object.defineProperty(exports,"UNFILLED_PREFIX",{enumerable:true,get:function(){return chunk6LJHLE6G_js.a}});Object.defineProperty(exports,"UNFILLED_SUFFIX",{enumerable:true,get:function(){return chunk6LJHLE6G_js.b}});Object.defineProperty(exports,"assemblePolicy",{enumerable:true,get:function(){return chunk6LJHLE6G_js.c}});Object.defineProperty(exports,"createDefaultContext",{enumerable:true,get:function(){return chunk6LJHLE6G_js.e}});Object.defineProperty(exports,"evaluatePolicyCompliance",{enumerable:true,get:function(){return chunk6LJHLE6G_js.f}});Object.defineProperty(exports,"assessTransferRisk",{enumerable:true,get:function(){return chunkYFBDJ4FH_js.h}});Object.defineProperty(exports,"getTransferMechanismDescription",{enumerable:true,get:function(){return chunkYFBDJ4FH_js.f}});Object.defineProperty(exports,"isNDPCApprovalRequired",{enumerable:true,get:function(){return chunkYFBDJ4FH_js.e}});Object.defineProperty(exports,"validateTransfer",{enumerable:true,get:function(){return chunkYFBDJ4FH_js.g}});Object.defineProperty(exports,"assessComplianceGaps",{enumerable:true,get:function(){return chunkWZYCBW2R_js.c}});Object.defineProperty(exports,"generateLawfulBasisSummary",{enumerable:true,get:function(){return chunkWZYCBW2R_js.d}});Object.defineProperty(exports,"getLawfulBasisDescription",{enumerable:true,get:function(){return chunkWZYCBW2R_js.b}});Object.defineProperty(exports,"validateProcessingActivity",{enumerable:true,get:function(){return chunkWZYCBW2R_js.a}});Object.defineProperty(exports,"exportROPAToCSV",{enumerable:true,get:function(){return chunk4CVBQC66_js.c}});Object.defineProperty(exports,"generateROPASummary",{enumerable:true,get:function(){return chunk4CVBQC66_js.b}});Object.defineProperty(exports,"identifyComplianceGaps",{enumerable:true,get:function(){return chunk4CVBQC66_js.d}});Object.defineProperty(exports,"validateProcessingRecord",{enumerable:true,get:function(){return chunk4CVBQC66_js.a}});Object.defineProperty(exports,"appendAuditEntry",{enumerable:true,get:function(){return chunk3IA3KDII_js.c}});Object.defineProperty(exports,"createAuditEntry",{enumerable:true,get:function(){return chunk3IA3KDII_js.a}});Object.defineProperty(exports,"getAuditLog",{enumerable:true,get:function(){return chunk3IA3KDII_js.b}});Object.defineProperty(exports,"cookieAdapter",{enumerable:true,get:function(){return chunkC2KEXHRX_js.b}});Object.defineProperty(exports,"sessionStorageAdapter",{enumerable:true,get:function(){return chunkC2KEXHRX_js.a}});Object.defineProperty(exports,"validateConsentOptionsStructured",{enumerable:true,get:function(){return chunkDKLJ5DYN_js.b}});Object.defineProperty(exports,"validateConsentStructured",{enumerable:true,get:function(){return chunkDKLJ5DYN_js.a}});Object.defineProperty(exports,"sanitizeInput",{enumerable:true,get:function(){return chunkUXUMYP4L_js.a}});Object.defineProperty(exports,"formatDSRRequestStructured",{enumerable:true,get:function(){return chunkR2ZZMATR_js.b}});Object.defineProperty(exports,"validateDsrSubmissionStructured",{enumerable:true,get:function(){return chunkR2ZZMATR_js.a}});Object.defineProperty(exports,"assessDPIARisk",{enumerable:true,get:function(){return chunkTQZWJGJ2_js.a}});Object.defineProperty(exports,"LEGAL_DISCLAIMER_LONG",{enumerable:true,get:function(){return chunkZVOIR4QH_js.b}});Object.defineProperty(exports,"LEGAL_DISCLAIMER_SHORT",{enumerable:true,get:function(){return chunkZVOIR4QH_js.a}});Object.defineProperty(exports,"legalDisclaimerBlock",{enumerable:true,get:function(){return chunkZVOIR4QH_js.c}});Object.defineProperty(exports,"defaultLocale",{enumerable:true,get:function(){return chunk7563FVMY_js.a}});Object.defineProperty(exports,"mergeLocale",{enumerable:true,get:function(){return chunk7563FVMY_js.b}});Object.defineProperty(exports,"localStorageAdapter",{enumerable:true,get:function(){return chunkVWED6UTN_js.a}});
1
+ 'use strict';var chunkR3CU7DTT_js=require('./chunk-R3CU7DTT.js'),chunkLP5KXMBY_js=require('./chunk-LP5KXMBY.js'),chunkNUOHT3LO_js=require('./chunk-NUOHT3LO.js'),chunkHCZDQWHY_js=require('./chunk-HCZDQWHY.js'),chunkJS7SYL5P_js=require('./chunk-JS7SYL5P.js'),chunkVFRGCBJY_js=require('./chunk-VFRGCBJY.js'),chunk7TTXS7JX_js=require('./chunk-7TTXS7JX.js'),chunk3YTAOT5O_js=require('./chunk-3YTAOT5O.js'),chunkY346CURW_js=require('./chunk-Y346CURW.js'),chunkD2ZKDQVL_js=require('./chunk-D2ZKDQVL.js'),chunk6LJHLE6G_js=require('./chunk-6LJHLE6G.js'),chunkYFBDJ4FH_js=require('./chunk-YFBDJ4FH.js'),chunkWZYCBW2R_js=require('./chunk-WZYCBW2R.js'),chunk4CVBQC66_js=require('./chunk-4CVBQC66.js'),chunk3IA3KDII_js=require('./chunk-3IA3KDII.js'),chunkC2KEXHRX_js=require('./chunk-C2KEXHRX.js'),chunkDKLJ5DYN_js=require('./chunk-DKLJ5DYN.js'),chunkUXUMYP4L_js=require('./chunk-UXUMYP4L.js'),chunkR2ZZMATR_js=require('./chunk-R2ZZMATR.js'),chunkTQZWJGJ2_js=require('./chunk-TQZWJGJ2.js'),chunkZVOIR4QH_js=require('./chunk-ZVOIR4QH.js'),chunk7563FVMY_js=require('./chunk-7563FVMY.js'),chunkVWED6UTN_js=require('./chunk-VWED6UTN.js');require('./chunk-RFPLZDIO.js');Object.defineProperty(exports,"apiAdapter",{enumerable:true,get:function(){return chunkR3CU7DTT_js.a}});Object.defineProperty(exports,"composeAdapters",{enumerable:true,get:function(){return chunkR3CU7DTT_js.c}});Object.defineProperty(exports,"memoryAdapter",{enumerable:true,get:function(){return chunkR3CU7DTT_js.b}});Object.defineProperty(exports,"arabicLocale",{enumerable:true,get:function(){return chunkLP5KXMBY_js.e}});Object.defineProperty(exports,"frenchLocale",{enumerable:true,get:function(){return chunkLP5KXMBY_js.f}});Object.defineProperty(exports,"hausaLocale",{enumerable:true,get:function(){return chunkLP5KXMBY_js.c}});Object.defineProperty(exports,"igboLocale",{enumerable:true,get:function(){return chunkLP5KXMBY_js.b}});Object.defineProperty(exports,"pidginLocale",{enumerable:true,get:function(){return chunkLP5KXMBY_js.d}});Object.defineProperty(exports,"yorubaLocale",{enumerable:true,get:function(){return chunkLP5KXMBY_js.a}});Object.defineProperty(exports,"ORG_POLICY_TEMPLATE_REGISTRY",{enumerable:true,get:function(){return chunkNUOHT3LO_js.a}});Object.defineProperty(exports,"createOrgTemplate",{enumerable:true,get:function(){return chunkNUOHT3LO_js.b}});Object.defineProperty(exports,"templateContextFor",{enumerable:true,get:function(){return chunkNUOHT3LO_js.b}});Object.defineProperty(exports,"formatNdprAuditReport",{enumerable:true,get:function(){return chunkHCZDQWHY_js.b}});Object.defineProperty(exports,"runNdprAudit",{enumerable:true,get:function(){return chunkHCZDQWHY_js.a}});Object.defineProperty(exports,"exportDOCX",{enumerable:true,get:function(){return chunkJS7SYL5P_js.d}});Object.defineProperty(exports,"exportHTML",{enumerable:true,get:function(){return chunkJS7SYL5P_js.a}});Object.defineProperty(exports,"exportMarkdown",{enumerable:true,get:function(){return chunkJS7SYL5P_js.b}});Object.defineProperty(exports,"exportPDF",{enumerable:true,get:function(){return chunkJS7SYL5P_js.c}});Object.defineProperty(exports,"classifyDCPMI",{enumerable:true,get:function(){return chunkVFRGCBJY_js.c}});Object.defineProperty(exports,"generateComplianceAuditReturn",{enumerable:true,get:function(){return chunkVFRGCBJY_js.d}});Object.defineProperty(exports,"getComplianceScore",{enumerable:true,get:function(){return chunk7TTXS7JX_js.a}});Object.defineProperty(exports,"calculateBreachSeverity",{enumerable:true,get:function(){return chunk3YTAOT5O_js.a}});Object.defineProperty(exports,"assessBreachNotification",{enumerable:true,get:function(){return chunkY346CURW_js.a}});Object.defineProperty(exports,"DEFAULT_POLICY_SECTIONS",{enumerable:true,get:function(){return chunkD2ZKDQVL_js.c}});Object.defineProperty(exports,"DEFAULT_POLICY_VARIABLES",{enumerable:true,get:function(){return chunkD2ZKDQVL_js.d}});Object.defineProperty(exports,"createBusinessPolicyTemplate",{enumerable:true,get:function(){return chunkD2ZKDQVL_js.e}});Object.defineProperty(exports,"findUnfilledTokens",{enumerable:true,get:function(){return chunkD2ZKDQVL_js.a}});Object.defineProperty(exports,"generatePolicyText",{enumerable:true,get:function(){return chunkD2ZKDQVL_js.b}});Object.defineProperty(exports,"DEFAULT_DATA_CATEGORIES",{enumerable:true,get:function(){return chunk6LJHLE6G_js.d}});Object.defineProperty(exports,"UNFILLED_PREFIX",{enumerable:true,get:function(){return chunk6LJHLE6G_js.a}});Object.defineProperty(exports,"UNFILLED_SUFFIX",{enumerable:true,get:function(){return chunk6LJHLE6G_js.b}});Object.defineProperty(exports,"assemblePolicy",{enumerable:true,get:function(){return chunk6LJHLE6G_js.c}});Object.defineProperty(exports,"createDefaultContext",{enumerable:true,get:function(){return chunk6LJHLE6G_js.e}});Object.defineProperty(exports,"evaluatePolicyCompliance",{enumerable:true,get:function(){return chunk6LJHLE6G_js.f}});Object.defineProperty(exports,"assessTransferRisk",{enumerable:true,get:function(){return chunkYFBDJ4FH_js.h}});Object.defineProperty(exports,"getTransferMechanismDescription",{enumerable:true,get:function(){return chunkYFBDJ4FH_js.f}});Object.defineProperty(exports,"isNDPCApprovalRequired",{enumerable:true,get:function(){return chunkYFBDJ4FH_js.e}});Object.defineProperty(exports,"validateTransfer",{enumerable:true,get:function(){return chunkYFBDJ4FH_js.g}});Object.defineProperty(exports,"assessComplianceGaps",{enumerable:true,get:function(){return chunkWZYCBW2R_js.c}});Object.defineProperty(exports,"generateLawfulBasisSummary",{enumerable:true,get:function(){return chunkWZYCBW2R_js.d}});Object.defineProperty(exports,"getLawfulBasisDescription",{enumerable:true,get:function(){return chunkWZYCBW2R_js.b}});Object.defineProperty(exports,"validateProcessingActivity",{enumerable:true,get:function(){return chunkWZYCBW2R_js.a}});Object.defineProperty(exports,"exportROPAToCSV",{enumerable:true,get:function(){return chunk4CVBQC66_js.c}});Object.defineProperty(exports,"generateROPASummary",{enumerable:true,get:function(){return chunk4CVBQC66_js.b}});Object.defineProperty(exports,"identifyComplianceGaps",{enumerable:true,get:function(){return chunk4CVBQC66_js.d}});Object.defineProperty(exports,"validateProcessingRecord",{enumerable:true,get:function(){return chunk4CVBQC66_js.a}});Object.defineProperty(exports,"appendAuditEntry",{enumerable:true,get:function(){return chunk3IA3KDII_js.c}});Object.defineProperty(exports,"createAuditEntry",{enumerable:true,get:function(){return chunk3IA3KDII_js.a}});Object.defineProperty(exports,"getAuditLog",{enumerable:true,get:function(){return chunk3IA3KDII_js.b}});Object.defineProperty(exports,"cookieAdapter",{enumerable:true,get:function(){return chunkC2KEXHRX_js.b}});Object.defineProperty(exports,"sessionStorageAdapter",{enumerable:true,get:function(){return chunkC2KEXHRX_js.a}});Object.defineProperty(exports,"validateConsentOptionsStructured",{enumerable:true,get:function(){return chunkDKLJ5DYN_js.b}});Object.defineProperty(exports,"validateConsentStructured",{enumerable:true,get:function(){return chunkDKLJ5DYN_js.a}});Object.defineProperty(exports,"sanitizeInput",{enumerable:true,get:function(){return chunkUXUMYP4L_js.a}});Object.defineProperty(exports,"formatDSRRequestStructured",{enumerable:true,get:function(){return chunkR2ZZMATR_js.b}});Object.defineProperty(exports,"validateDsrSubmissionStructured",{enumerable:true,get:function(){return chunkR2ZZMATR_js.a}});Object.defineProperty(exports,"assessDPIARisk",{enumerable:true,get:function(){return chunkTQZWJGJ2_js.a}});Object.defineProperty(exports,"LEGAL_DISCLAIMER_LONG",{enumerable:true,get:function(){return chunkZVOIR4QH_js.b}});Object.defineProperty(exports,"LEGAL_DISCLAIMER_SHORT",{enumerable:true,get:function(){return chunkZVOIR4QH_js.a}});Object.defineProperty(exports,"legalDisclaimerBlock",{enumerable:true,get:function(){return chunkZVOIR4QH_js.c}});Object.defineProperty(exports,"defaultLocale",{enumerable:true,get:function(){return chunk7563FVMY_js.a}});Object.defineProperty(exports,"mergeLocale",{enumerable:true,get:function(){return chunk7563FVMY_js.b}});Object.defineProperty(exports,"localStorageAdapter",{enumerable:true,get:function(){return chunkVWED6UTN_js.a}});
package/dist/server.mjs CHANGED
@@ -1 +1 @@
1
- export{a as apiAdapter,c as composeAdapters,b as memoryAdapter}from'./chunk-7PMPKVY3.mjs';export{e as arabicLocale,f as frenchLocale,c as hausaLocale,b as igboLocale,d as pidginLocale,a as yorubaLocale}from'./chunk-KUI5W44P.mjs';export{a as ORG_POLICY_TEMPLATE_REGISTRY,b as createOrgTemplate,b as templateContextFor}from'./chunk-CWY2FMIC.mjs';export{d as exportDOCX,a as exportHTML,b as exportMarkdown,c as exportPDF}from'./chunk-IVSNHT24.mjs';export{a as getComplianceScore}from'./chunk-6A7M4CGJ.mjs';export{a as calculateBreachSeverity}from'./chunk-WTGKZX7J.mjs';export{c as DEFAULT_POLICY_SECTIONS,d as DEFAULT_POLICY_VARIABLES,e as createBusinessPolicyTemplate,a as findUnfilledTokens,b as generatePolicyText}from'./chunk-NBQQ2GN3.mjs';export{d as DEFAULT_DATA_CATEGORIES,a as UNFILLED_PREFIX,b as UNFILLED_SUFFIX,c as assemblePolicy,e as createDefaultContext,f as evaluatePolicyCompliance}from'./chunk-BIJSMSUU.mjs';export{h as assessTransferRisk,f as getTransferMechanismDescription,e as isNDPCApprovalRequired,g as validateTransfer}from'./chunk-7BJXI2HI.mjs';export{c as assessComplianceGaps,d as generateLawfulBasisSummary,b as getLawfulBasisDescription,a as validateProcessingActivity}from'./chunk-LWIKDDSU.mjs';export{c as exportROPAToCSV,b as generateROPASummary,d as identifyComplianceGaps,a as validateProcessingRecord}from'./chunk-XP5PL6K7.mjs';export{c as appendAuditEntry,a as createAuditEntry,b as getAuditLog}from'./chunk-V7UFP6QU.mjs';export{b as cookieAdapter,a as sessionStorageAdapter}from'./chunk-XC3DLYEG.mjs';export{b as validateConsentOptionsStructured,a as validateConsentStructured}from'./chunk-R3ZKV2J7.mjs';export{a as sanitizeInput}from'./chunk-EWVK45Z3.mjs';export{b as formatDSRRequestStructured,a as validateDsrSubmissionStructured}from'./chunk-RRVML7CU.mjs';export{a as assessDPIARisk}from'./chunk-LRRENTT5.mjs';export{b as LEGAL_DISCLAIMER_LONG,a as LEGAL_DISCLAIMER_SHORT,c as legalDisclaimerBlock}from'./chunk-ITCY2Z66.mjs';export{a as defaultLocale,b as mergeLocale}from'./chunk-5LJ652AH.mjs';export{a as localStorageAdapter}from'./chunk-DBZSN4WP.mjs';import'./chunk-ZJYULEER.mjs';
1
+ export{a as apiAdapter,c as composeAdapters,b as memoryAdapter}from'./chunk-7PMPKVY3.mjs';export{e as arabicLocale,f as frenchLocale,c as hausaLocale,b as igboLocale,d as pidginLocale,a as yorubaLocale}from'./chunk-KUI5W44P.mjs';export{a as ORG_POLICY_TEMPLATE_REGISTRY,b as createOrgTemplate,b as templateContextFor}from'./chunk-CWY2FMIC.mjs';export{b as formatNdprAuditReport,a as runNdprAudit}from'./chunk-ME77GU4Q.mjs';export{d as exportDOCX,a as exportHTML,b as exportMarkdown,c as exportPDF}from'./chunk-IVSNHT24.mjs';export{c as classifyDCPMI,d as generateComplianceAuditReturn}from'./chunk-MGXWQW5I.mjs';export{a as getComplianceScore}from'./chunk-6A7M4CGJ.mjs';export{a as calculateBreachSeverity}from'./chunk-WTGKZX7J.mjs';export{a as assessBreachNotification}from'./chunk-WJSUVPYX.mjs';export{c as DEFAULT_POLICY_SECTIONS,d as DEFAULT_POLICY_VARIABLES,e as createBusinessPolicyTemplate,a as findUnfilledTokens,b as generatePolicyText}from'./chunk-NBQQ2GN3.mjs';export{d as DEFAULT_DATA_CATEGORIES,a as UNFILLED_PREFIX,b as UNFILLED_SUFFIX,c as assemblePolicy,e as createDefaultContext,f as evaluatePolicyCompliance}from'./chunk-BIJSMSUU.mjs';export{h as assessTransferRisk,f as getTransferMechanismDescription,e as isNDPCApprovalRequired,g as validateTransfer}from'./chunk-7BJXI2HI.mjs';export{c as assessComplianceGaps,d as generateLawfulBasisSummary,b as getLawfulBasisDescription,a as validateProcessingActivity}from'./chunk-LWIKDDSU.mjs';export{c as exportROPAToCSV,b as generateROPASummary,d as identifyComplianceGaps,a as validateProcessingRecord}from'./chunk-XP5PL6K7.mjs';export{c as appendAuditEntry,a as createAuditEntry,b as getAuditLog}from'./chunk-V7UFP6QU.mjs';export{b as cookieAdapter,a as sessionStorageAdapter}from'./chunk-XC3DLYEG.mjs';export{b as validateConsentOptionsStructured,a as validateConsentStructured}from'./chunk-R3ZKV2J7.mjs';export{a as sanitizeInput}from'./chunk-EWVK45Z3.mjs';export{b as formatDSRRequestStructured,a as validateDsrSubmissionStructured}from'./chunk-RRVML7CU.mjs';export{a as assessDPIARisk}from'./chunk-LRRENTT5.mjs';export{b as LEGAL_DISCLAIMER_LONG,a as LEGAL_DISCLAIMER_SHORT,c as legalDisclaimerBlock}from'./chunk-ITCY2Z66.mjs';export{a as defaultLocale,b as mergeLocale}from'./chunk-5LJ652AH.mjs';export{a as localStorageAdapter}from'./chunk-DBZSN4WP.mjs';import'./chunk-ZJYULEER.mjs';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tantainnovative/ndpr-toolkit",
3
- "version": "5.4.0",
3
+ "version": "5.5.1",
4
4
  "private": false,
5
5
  "packageManager": "pnpm@10.34.1",
6
6
  "description": "Nigeria Data Protection Toolkit — enterprise-grade compliance components for the Nigeria Data Protection Act (NDPA) 2023",
@@ -98,6 +98,9 @@
98
98
  "main": "./dist/index.js",
99
99
  "module": "./dist/index.mjs",
100
100
  "types": "./dist/index.d.ts",
101
+ "bin": {
102
+ "ndpr": "./bin/ndpr.mjs"
103
+ },
101
104
  "exports": {
102
105
  ".": {
103
106
  "types": "./dist/index.d.ts",
@@ -291,6 +294,7 @@
291
294
  "dist/**/*.d.ts",
292
295
  "dist/**/*.d.mts",
293
296
  "dist/**/*.css",
297
+ "bin/ndpr.mjs",
294
298
  "README.md",
295
299
  "CHANGELOG.md",
296
300
  "LICENSE"
@@ -1 +0,0 @@
1
- import {a}from'./chunk-ZJYULEER.mjs';var N={ohl:200,ehl:1e3,uhl:5e3},x={UHL:25e4,EHL:1e5,OHL:1e4};function T(e,i={}){let t=a(a({},N),i.thresholds),a$1=a(a({},x),i.fees),r=e==null?void 0:e.dataSubjectsInSixMonths,l=typeof r=="number"&&r>0?Math.floor(r):0,n;l>t.uhl?n="UHL":l>=t.ehl?n="EHL":l>=t.ohl?n="OHL":e!=null&&e.isDesignated?n="listed":n="none";let s=n!=="none",c=n==="UHL"||n==="EHL"||n==="OHL"?a$1[n]:0,o=[];return n==="listed"&&o.push("Designated as a DCPMI below the volume tiers \u2014 confirm the applicable registration tier and fee with the NDPC."),s&&o.push(n==="OHL"?"OHL organisations renew their NDPC registration annually and file Compliance Audit Returns (CAR) each year.":"Register once with the NDPC, then file Compliance Audit Returns (CAR) annually."),o.push("Thresholds, fees, and filing dates follow the NDPC GAID 2025 baseline and can change \u2014 verify against current NDPC guidance before relying on them."),{tier:n,isDCPMI:s,annualFeeNGN:c,registration:{required:s,renewsAnnually:n==="OHL"},compliance:{auditReturnsAnnual:s,initialAuditWithinMonths:15},notes:o,dataSubjectsConsidered:l}}function O(e){return String(e).padStart(2,"0")}function y(e){let[i,t,a]=e.split("-").map(Number);return new Date(Date.UTC(i,t-1,a))}function H(e){return e.toISOString().slice(0,10)}function S(e,i){let[t,a,r]=e.split("-").map(Number);return H(new Date(Date.UTC(t,a-1+i,r)))}function R(){return new Date().toISOString().slice(0,10)}function U(e,i={}){var f,C,b,g,p,M,I;let t=(f=e.asOf)!=null?f:R(),a=(C=i.initialAuditWithinMonths)!=null?C:15,r=(g=(b=i.annualDeadline)==null?void 0:b.month)!=null?g:3,l=(M=(p=i.annualDeadline)==null?void 0:p.day)!=null?M:31,n=(I=i.deadlineOverrides)!=null?I:{},s=e.tier===void 0?true:e.tier!=="none",c=S(e.commencementDate,a),o=P=>{var A;return (A=n[P])!=null?A:`${P}-${O(r)}-${O(l)}`},h=Number(t.slice(0,4)),D=o(h);t>D&&(h+=1,D=o(h));let L=Math.round((y(D).getTime()-y(t).getTime())/864e5),m=t>=c,u=[];return s?(u.push("File the Compliance Audit Return with the NDPC via the NDPC Information Management Portal (NIMP)."),m&&u.push("The initial compliance-audit window has elapsed \u2014 ensure the initial audit has been conducted.")):u.push("Compliance Audit Returns apply only to Data Controllers/Processors of Major Importance."),u.push("Filing deadlines follow the NDPC GAID 2025 baseline and can be extended \u2014 verify the current deadline with the NDPC."),{applicable:s,schedule:{commencementDate:e.commencementDate,initialAuditWithinMonths:a,initialAuditDueDate:c,nextFilingDeadline:D,filingYear:h},status:{initialAuditDue:m,daysUntilNextDeadline:L},notes:u,asOf:t}}export{N as a,x as b,T as c,U as d};
@@ -1 +0,0 @@
1
- 'use strict';var chunkWKY26JLT_js=require('./chunk-WKY26JLT.js'),chunkY346CURW_js=require('./chunk-Y346CURW.js'),chunk7TTXS7JX_js=require('./chunk-7TTXS7JX.js'),react=require('react');function u(t,e){return react.useMemo(()=>chunkY346CURW_js.a(t,e),[t,e])}function M({input:t}){let e=JSON.stringify(t);return react.useMemo(()=>chunk7TTXS7JX_js.a(t),[e])}function D(t,e){return react.useMemo(()=>chunkWKY26JLT_js.c(t,e),[t.dataSubjectsInSixMonths,t.isDesignated,e])}function P(t,e){return react.useMemo(()=>chunkWKY26JLT_js.d(t,e),[t.commencementDate,t.asOf,t.tier,e])}exports.a=u;exports.b=M;exports.c=D;exports.d=P;
@@ -1 +0,0 @@
1
- 'use strict';var chunkRFPLZDIO_js=require('./chunk-RFPLZDIO.js');var N={ohl:200,ehl:1e3,uhl:5e3},x={UHL:25e4,EHL:1e5,OHL:1e4};function T(e,i={}){let t=chunkRFPLZDIO_js.a(chunkRFPLZDIO_js.a({},N),i.thresholds),a=chunkRFPLZDIO_js.a(chunkRFPLZDIO_js.a({},x),i.fees),r=e==null?void 0:e.dataSubjectsInSixMonths,l=typeof r=="number"&&r>0?Math.floor(r):0,n;l>t.uhl?n="UHL":l>=t.ehl?n="EHL":l>=t.ohl?n="OHL":e!=null&&e.isDesignated?n="listed":n="none";let s=n!=="none",c=n==="UHL"||n==="EHL"||n==="OHL"?a[n]:0,o=[];return n==="listed"&&o.push("Designated as a DCPMI below the volume tiers \u2014 confirm the applicable registration tier and fee with the NDPC."),s&&o.push(n==="OHL"?"OHL organisations renew their NDPC registration annually and file Compliance Audit Returns (CAR) each year.":"Register once with the NDPC, then file Compliance Audit Returns (CAR) annually."),o.push("Thresholds, fees, and filing dates follow the NDPC GAID 2025 baseline and can change \u2014 verify against current NDPC guidance before relying on them."),{tier:n,isDCPMI:s,annualFeeNGN:c,registration:{required:s,renewsAnnually:n==="OHL"},compliance:{auditReturnsAnnual:s,initialAuditWithinMonths:15},notes:o,dataSubjectsConsidered:l}}function O(e){return String(e).padStart(2,"0")}function y(e){let[i,t,a]=e.split("-").map(Number);return new Date(Date.UTC(i,t-1,a))}function H(e){return e.toISOString().slice(0,10)}function S(e,i){let[t,a,r]=e.split("-").map(Number);return H(new Date(Date.UTC(t,a-1+i,r)))}function R(){return new Date().toISOString().slice(0,10)}function U(e,i={}){var f,C,b,g,p,M,I;let t=(f=e.asOf)!=null?f:R(),a=(C=i.initialAuditWithinMonths)!=null?C:15,r=(g=(b=i.annualDeadline)==null?void 0:b.month)!=null?g:3,l=(M=(p=i.annualDeadline)==null?void 0:p.day)!=null?M:31,n=(I=i.deadlineOverrides)!=null?I:{},s=e.tier===void 0?true:e.tier!=="none",c=S(e.commencementDate,a),o=P=>{var A;return (A=n[P])!=null?A:`${P}-${O(r)}-${O(l)}`},h=Number(t.slice(0,4)),D=o(h);t>D&&(h+=1,D=o(h));let L=Math.round((y(D).getTime()-y(t).getTime())/864e5),m=t>=c,u=[];return s?(u.push("File the Compliance Audit Return with the NDPC via the NDPC Information Management Portal (NIMP)."),m&&u.push("The initial compliance-audit window has elapsed \u2014 ensure the initial audit has been conducted.")):u.push("Compliance Audit Returns apply only to Data Controllers/Processors of Major Importance."),u.push("Filing deadlines follow the NDPC GAID 2025 baseline and can be extended \u2014 verify the current deadline with the NDPC."),{applicable:s,schedule:{commencementDate:e.commencementDate,initialAuditWithinMonths:a,initialAuditDueDate:c,nextFilingDeadline:D,filingYear:h},status:{initialAuditDue:m,daysUntilNextDeadline:L},notes:u,asOf:t}}exports.a=N;exports.b=x;exports.c=T;exports.d=U;