@tantainnovative/ndpr-toolkit 5.2.0 → 5.4.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 CHANGED
@@ -2,6 +2,25 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file. See [commit-and-tag-version](https://github.com/absolute-version/commit-and-tag-version) for commit guidelines.
4
4
 
5
+ ## [5.4.0](https://github.com/mr-tanta/ndpr-toolkit/compare/v5.3.0...v5.4.0) (2026-05-30)
6
+
7
+
8
+ ### Features
9
+
10
+ * **breach:** show live NDPC notification readiness in BreachReportForm ([86e2394](https://github.com/mr-tanta/ndpr-toolkit/commit/86e23943756680ad64bd939e60edb896884680c2))
11
+
12
+ ## [5.3.0](https://github.com/mr-tanta/ndpr-toolkit/compare/v5.2.0...v5.3.0) (2026-05-30)
13
+
14
+
15
+ ### Features
16
+
17
+ * **breach:** add NDPA S.40 / GAID 2025 Article 33 notification completeness checker ([2a6bdf2](https://github.com/mr-tanta/ndpr-toolkit/commit/2a6bdf25af11431c6b4603c0892d3db44f0bf348))
18
+
19
+
20
+ ### Documentation
21
+
22
+ * document the breach notification completeness checker ([c05ee84](https://github.com/mr-tanta/ndpr-toolkit/commit/c05ee848afd899ae916b40fa55023886380392ae))
23
+
5
24
  ## [5.2.0](https://github.com/mr-tanta/ndpr-toolkit/compare/v5.1.4...v5.2.0) (2026-05-30)
6
25
 
7
26
 
package/README.md CHANGED
@@ -506,6 +506,34 @@ Both ship as memoised hooks for React UIs — `useDCPMI(input, options?)` and `u
506
506
 
507
507
  ---
508
508
 
509
+ ## Breach Notification Completeness
510
+
511
+ `assessBreachNotification()` checks a `BreachReport` against the **NDPA 2023 Section 40** breach-notification duty as detailed by **NDPC GAID 2025 Article 33** — the mandated content of the notification to the Commission, the 72-hour deadline from discovery, and the data-subject communication owed when the risk is high.
512
+
513
+ ```ts
514
+ import { assessBreachNotification } from '@tantainnovative/ndpr-toolkit/core';
515
+
516
+ const result = assessBreachNotification(breachReport, {
517
+ asOf: Date.now(),
518
+ assessment: riskAssessment, // optional — high risk triggers the S.40(3) data-subject duty
519
+ });
520
+
521
+ result.complete; // false until every mandated item is present
522
+ result.completeness; // 0–100 across applicable items
523
+ result.missing; // ["Steps taken to reduce the risk of harm", ...]
524
+ result.timing.deadline; // discoveredAt + 72h
525
+ result.timing.hoursRemaining;// time left to notify the NDPC (negative once overdue)
526
+ result.timing.overdue; // true once the 72-hour window has passed
527
+ result.dataSubjectCommunicationRequired; // true on high risk (S.40(3))
528
+ result.recommendations; // actionable, each citing its provision
529
+ ```
530
+
531
+ The content checklist (`notificationToCommission`) maps each item to its source — **GAID 2025 Art. 33(5)(a)–(h)** for the description, timing, data involved, risk-of-harm, numbers at risk, mitigation, notification steps, and contact point; **NDPA S. 40(2)** for the data-subject categories and record count. Late filings are flagged with `requiresDelayJustification` (the NDPC permits phased reporting where full details aren't yet available). Also available as the memoised `useBreachNotificationAssessment(report, options?)` hook from `/hooks`.
532
+
533
+ > A documentation-completeness aid, not legal advice — verify against current NDPC guidance.
534
+
535
+ ---
536
+
509
537
  ## Backend Integration
510
538
 
511
539
  ### CLI scaffolder
package/dist/breach.d.mts CHANGED
@@ -332,6 +332,8 @@ export declare interface BreachReportFormClassNames {
332
332
  notice?: string;
333
333
  /** Custom class applied when isSubmitting is true (e.g. a loading overlay) */
334
334
  loadingOverlay?: string;
335
+ /** Live NDPC-notification completeness panel */
336
+ completeness?: string;
335
337
  }
336
338
 
337
339
  declare interface BreachReportFormProps {
@@ -425,6 +427,13 @@ declare interface BreachReportFormProps {
425
427
  * change the `key` prop from the parent.
426
428
  */
427
429
  onReset?: () => void;
430
+ /**
431
+ * Show a live NDPC-notification readiness panel that scores the form against
432
+ * the NDPA S. 40 / GAID 2025 Article 33 mandated content and the 72-hour
433
+ * deadline as the user fills it in.
434
+ * @default true
435
+ */
436
+ showCompleteness?: boolean;
428
437
  }
429
438
 
430
439
  /**
package/dist/breach.d.ts CHANGED
@@ -332,6 +332,8 @@ export declare interface BreachReportFormClassNames {
332
332
  notice?: string;
333
333
  /** Custom class applied when isSubmitting is true (e.g. a loading overlay) */
334
334
  loadingOverlay?: string;
335
+ /** Live NDPC-notification completeness panel */
336
+ completeness?: string;
335
337
  }
336
338
 
337
339
  declare interface BreachReportFormProps {
@@ -425,6 +427,13 @@ declare interface BreachReportFormProps {
425
427
  * change the `key` prop from the parent.
426
428
  */
427
429
  onReset?: () => void;
430
+ /**
431
+ * Show a live NDPC-notification readiness panel that scores the form against
432
+ * the NDPA S. 40 / GAID 2025 Article 33 mandated content and the 72-hour
433
+ * deadline as the user fills it in.
434
+ * @default true
435
+ */
436
+ showCompleteness?: boolean;
428
437
  }
429
438
 
430
439
  /**
package/dist/breach.js CHANGED
@@ -1,2 +1,2 @@
1
1
  "use client";
2
- 'use strict';var chunkC7OOUURS_js=require('./chunk-C7OOUURS.js'),chunk6MO3GS3B_js=require('./chunk-6MO3GS3B.js'),chunkEHQVTFYO_js=require('./chunk-EHQVTFYO.js'),chunk3YTAOT5O_js=require('./chunk-3YTAOT5O.js');require('./chunk-UXUMYP4L.js'),require('./chunk-ZVOIR4QH.js'),require('./chunk-AME4HJR4.js'),require('./chunk-I5ZDNSX5.js'),require('./chunk-7563FVMY.js'),require('./chunk-VWED6UTN.js');var chunkRFPLZDIO_js=require('./chunk-RFPLZDIO.js'),react=require('react'),jsxRuntime=require('react/jsx-runtime');var c=react.createContext(null);function P(){let e=react.useContext(c);if(!e)throw new Error("Breach compound components must be wrapped in <Breach.Provider>. Example: <Breach.Provider categories={...}><Breach.ReportForm /></Breach.Provider>");return e}var p=({categories:e,adapter:m,storageKey:h,useLocalStorage:B,initialReports:f,onReport:R,onAssessment:x,onNotification:u,children:d})=>{let y=chunkEHQVTFYO_js.a({categories:e,adapter:m,storageKey:h,useLocalStorage:B,initialReports:f,onReport:R,onAssessment:x,onNotification:u}),l=chunkRFPLZDIO_js.b(chunkRFPLZDIO_js.a({},y),{categories:e});return jsxRuntime.jsx(c.Provider,{value:l,children:d})};var A={Provider:p,ReportForm:chunk6MO3GS3B_js.a,RiskAssessment:chunkC7OOUURS_js.a,NotificationManager:chunkC7OOUURS_js.b,ReportGenerator:chunkC7OOUURS_js.c};Object.defineProperty(exports,"BreachNotificationManager",{enumerable:true,get:function(){return chunkC7OOUURS_js.b}});Object.defineProperty(exports,"BreachRiskAssessment",{enumerable:true,get:function(){return chunkC7OOUURS_js.a}});Object.defineProperty(exports,"RegulatoryReportGenerator",{enumerable:true,get:function(){return chunkC7OOUURS_js.c}});Object.defineProperty(exports,"BreachReportForm",{enumerable:true,get:function(){return chunk6MO3GS3B_js.a}});Object.defineProperty(exports,"useBreach",{enumerable:true,get:function(){return chunkEHQVTFYO_js.a}});Object.defineProperty(exports,"calculateBreachSeverity",{enumerable:true,get:function(){return chunk3YTAOT5O_js.a}});exports.Breach=A;exports.BreachProvider=p;exports.useBreachCompound=P;
2
+ 'use strict';var chunkC7OOUURS_js=require('./chunk-C7OOUURS.js'),chunkLHQG25Y2_js=require('./chunk-LHQG25Y2.js'),chunkEHQVTFYO_js=require('./chunk-EHQVTFYO.js');require('./chunk-Y346CURW.js');var chunk3YTAOT5O_js=require('./chunk-3YTAOT5O.js');require('./chunk-UXUMYP4L.js'),require('./chunk-ZVOIR4QH.js'),require('./chunk-AME4HJR4.js'),require('./chunk-I5ZDNSX5.js'),require('./chunk-7563FVMY.js'),require('./chunk-VWED6UTN.js');var chunkRFPLZDIO_js=require('./chunk-RFPLZDIO.js'),react=require('react'),jsxRuntime=require('react/jsx-runtime');var c=react.createContext(null);function P(){let e=react.useContext(c);if(!e)throw new Error("Breach compound components must be wrapped in <Breach.Provider>. Example: <Breach.Provider categories={...}><Breach.ReportForm /></Breach.Provider>");return e}var p=({categories:e,adapter:m,storageKey:h,useLocalStorage:B,initialReports:f,onReport:R,onAssessment:x,onNotification:u,children:d})=>{let y=chunkEHQVTFYO_js.a({categories:e,adapter:m,storageKey:h,useLocalStorage:B,initialReports:f,onReport:R,onAssessment:x,onNotification:u}),l=chunkRFPLZDIO_js.b(chunkRFPLZDIO_js.a({},y),{categories:e});return jsxRuntime.jsx(c.Provider,{value:l,children:d})};var A={Provider:p,ReportForm:chunkLHQG25Y2_js.a,RiskAssessment:chunkC7OOUURS_js.a,NotificationManager:chunkC7OOUURS_js.b,ReportGenerator:chunkC7OOUURS_js.c};Object.defineProperty(exports,"BreachNotificationManager",{enumerable:true,get:function(){return chunkC7OOUURS_js.b}});Object.defineProperty(exports,"BreachRiskAssessment",{enumerable:true,get:function(){return chunkC7OOUURS_js.a}});Object.defineProperty(exports,"RegulatoryReportGenerator",{enumerable:true,get:function(){return chunkC7OOUURS_js.c}});Object.defineProperty(exports,"BreachReportForm",{enumerable:true,get:function(){return chunkLHQG25Y2_js.a}});Object.defineProperty(exports,"useBreach",{enumerable:true,get:function(){return chunkEHQVTFYO_js.a}});Object.defineProperty(exports,"calculateBreachSeverity",{enumerable:true,get:function(){return chunk3YTAOT5O_js.a}});exports.Breach=A;exports.BreachProvider=p;exports.useBreachCompound=P;
package/dist/breach.mjs CHANGED
@@ -1,2 +1,2 @@
1
1
  "use client";
2
- import {c as c$1,b,a}from'./chunk-EF5CLD4V.mjs';export{b as BreachNotificationManager,a as BreachRiskAssessment,c as RegulatoryReportGenerator}from'./chunk-EF5CLD4V.mjs';import {a as a$1}from'./chunk-WLZTATLL.mjs';export{a as BreachReportForm}from'./chunk-WLZTATLL.mjs';import {a as a$2}from'./chunk-RFXGD5NE.mjs';export{a as useBreach}from'./chunk-RFXGD5NE.mjs';export{a as calculateBreachSeverity}from'./chunk-WTGKZX7J.mjs';import'./chunk-EWVK45Z3.mjs';import'./chunk-ITCY2Z66.mjs';import'./chunk-SFGW37LE.mjs';import'./chunk-PHA3YMFO.mjs';import'./chunk-5LJ652AH.mjs';import'./chunk-DBZSN4WP.mjs';import {b as b$1,a as a$3}from'./chunk-ZJYULEER.mjs';import {createContext,useContext}from'react';import {jsx}from'react/jsx-runtime';var c=createContext(null);function P(){let e=useContext(c);if(!e)throw new Error("Breach compound components must be wrapped in <Breach.Provider>. Example: <Breach.Provider categories={...}><Breach.ReportForm /></Breach.Provider>");return e}var p=({categories:e,adapter:m,storageKey:h,useLocalStorage:B,initialReports:f,onReport:R,onAssessment:x,onNotification:u,children:d})=>{let y=a$2({categories:e,adapter:m,storageKey:h,useLocalStorage:B,initialReports:f,onReport:R,onAssessment:x,onNotification:u}),l=b$1(a$3({},y),{categories:e});return jsx(c.Provider,{value:l,children:d})};var A={Provider:p,ReportForm:a$1,RiskAssessment:a,NotificationManager:b,ReportGenerator:c$1};export{A as Breach,p as BreachProvider,P as useBreachCompound};
2
+ import {c as c$1,b,a}from'./chunk-EF5CLD4V.mjs';export{b as BreachNotificationManager,a as BreachRiskAssessment,c as RegulatoryReportGenerator}from'./chunk-EF5CLD4V.mjs';import {a as a$1}from'./chunk-5ZMYNOMR.mjs';export{a as BreachReportForm}from'./chunk-5ZMYNOMR.mjs';import {a as a$2}from'./chunk-RFXGD5NE.mjs';export{a as useBreach}from'./chunk-RFXGD5NE.mjs';import'./chunk-WJSUVPYX.mjs';export{a as calculateBreachSeverity}from'./chunk-WTGKZX7J.mjs';import'./chunk-EWVK45Z3.mjs';import'./chunk-ITCY2Z66.mjs';import'./chunk-SFGW37LE.mjs';import'./chunk-PHA3YMFO.mjs';import'./chunk-5LJ652AH.mjs';import'./chunk-DBZSN4WP.mjs';import {b as b$1,a as a$3}from'./chunk-ZJYULEER.mjs';import {createContext,useContext}from'react';import {jsx}from'react/jsx-runtime';var c=createContext(null);function P(){let e=useContext(c);if(!e)throw new Error("Breach compound components must be wrapped in <Breach.Provider>. Example: <Breach.Provider categories={...}><Breach.ReportForm /></Breach.Provider>");return e}var p=({categories:e,adapter:m,storageKey:h,useLocalStorage:B,initialReports:f,onReport:R,onAssessment:x,onNotification:u,children:d})=>{let y=a$2({categories:e,adapter:m,storageKey:h,useLocalStorage:B,initialReports:f,onReport:R,onAssessment:x,onNotification:u}),l=b$1(a$3({},y),{categories:e});return jsx(c.Provider,{value:l,children:d})};var A={Provider:p,ReportForm:a$1,RiskAssessment:a,NotificationManager:b,ReportGenerator:c$1};export{A as Breach,p as BreachProvider,P as useBreachCompound};
@@ -0,0 +1,2 @@
1
+ import {a}from'./chunk-WJSUVPYX.mjs';import {a as a$3}from'./chunk-EWVK45Z3.mjs';import {a as a$1}from'./chunk-SFGW37LE.mjs';import {c}from'./chunk-PHA3YMFO.mjs';import {a as a$2,b}from'./chunk-ZJYULEER.mjs';import {useState,useMemo}from'react';import {jsxs,jsx}from'react/jsx-runtime';var Ct=({categories:Je,onSubmit:Qe,onValidationError:z,title:Y,description:H,submitButtonText:U,className:te="",buttonClassName:re="",classNames:d={},unstyled:c$1=false,isSubmitting:C=false,showConfirmation:Xe=true,confirmationMessage:Ve="Your breach report has been submitted successfully. The data protection team has been notified.",allowAttachments:et=true,maxAttachments:G=5,maxFileSize:Z=5*1024*1024,allowedFileTypes:K=[".pdf",".jpg",".jpeg",".png",".doc",".docx",".xls",".xlsx",".txt"],defaultValues:r,onReset:W,showCompleteness:tt=true})=>{var ke,qe,je,Te,Ie,Be,Ee,Me,$e,Oe,Le,ze,Ye,He;let J=c(),rt=(ke=Y!=null?Y:J.breach.title)!=null?ke:"Report a Data Breach",it=(qe=H!=null?H:J.breach.description)!=null?qe:"Use this form to report a suspected or confirmed data breach in accordance with NDPA Section 40. All fields marked with * are required.",at=(je=U!=null?U:J.breach.submitReport)!=null?je:"Submit Report",ie=t=>{if(!t)return "";let o=new Date(t),p=s=>String(s).padStart(2,"0");return `${o.getFullYear()}-${p(o.getMonth()+1)}-${p(o.getDate())}T${p(o.getHours())}:${p(o.getMinutes())}`},[S,ae]=useState((r==null?void 0:r.title)||""),[D,ne]=useState((r==null?void 0:r.description)||""),[A,oe]=useState((r==null?void 0:r.category)||""),[h,se]=useState(ie(r==null?void 0:r.discoveredAt)),[v,de]=useState(ie(r==null?void 0:r.occurredAt)),[T,me]=useState(((Te=r==null?void 0:r.reporter)==null?void 0:Te.name)||""),[R,ce]=useState(((Ie=r==null?void 0:r.reporter)==null?void 0:Ie.email)||""),[I,le]=useState(((Be=r==null?void 0:r.reporter)==null?void 0:Be.department)||""),[B,pe]=useState(((Ee=r==null?void 0:r.reporter)==null?void 0:Ee.phone)||""),[E,ge]=useState((r==null?void 0:r.affectedSystems)||[]),[nt,fe]=useState(((Me=r==null?void 0:r.affectedSystems)==null?void 0:Me.join(", "))||""),[w,be]=useState((r==null?void 0:r.dataTypes)||[]),[b$1,he]=useState((r==null?void 0:r.estimatedAffectedSubjects)!=null?String(r.estimatedAffectedSubjects):""),[N,ve]=useState((r==null?void 0:r.approximateRecordCount)!=null?String(r.approximateRecordCount):""),[u,Ne]=useState((($e=r==null?void 0:r.dataSubjectCategories)==null?void 0:$e.join(", "))||""),[P,ue]=useState((Oe=r==null?void 0:r.involvesSensitiveData)!=null?Oe:false),[F,ye]=useState((r==null?void 0:r.likelyConsequences)||""),[k,_e]=useState((r==null?void 0:r.mitigationMeasures)||""),[y,xe]=useState(((Le=r==null?void 0:r.dpoContact)==null?void 0:Le.name)||""),[_,Ce]=useState(((ze=r==null?void 0:r.dpoContact)==null?void 0:ze.email)||""),[M,Se]=useState(((Ye=r==null?void 0:r.dpoContact)==null?void 0:Ye.phone)||""),[Q,De]=useState((He=r==null?void 0:r.isPhasedReport)!=null?He:false),[X,Ae]=useState((r==null?void 0:r.supplementsReportId)||""),[$,Re]=useState((r==null?void 0:r.status)||"ongoing"),[q,we]=useState((r==null?void 0:r.initialActions)||""),[O,V]=useState([]),[ot,ee]=useState(false),[a$4,j]=useState({}),g=useMemo(()=>{let t={id:"",title:S,description:D,category:A,discoveredAt:h?new Date(h).getTime():NaN,occurredAt:v?new Date(v).getTime():void 0,reportedAt:0,reporter:{name:T,email:R,department:I,phone:B||void 0},affectedSystems:E,dataTypes:w,estimatedAffectedSubjects:b$1?Number(b$1):void 0,approximateRecordCount:N?Number(N):void 0,dataSubjectCategories:u?u.split(",").map(o=>o.trim()).filter(Boolean):void 0,involvesSensitiveData:P,likelyConsequences:F||void 0,mitigationMeasures:k||void 0,dpoContact:y||_?{name:y,email:_,phone:M||void 0}:void 0,status:$,initialActions:q||void 0};return a(t,{highRisk:P})},[S,D,A,h,v,E,w,b$1,N,u,P,F,k,y,_,$,q]),Pe=[...g.notificationToCommission,...g.dataSubjectCommunication],Fe=Pe.length,st=Fe-g.missing.length,dt=()=>{ae(""),ne(""),oe(""),se(""),de(""),me(""),ce(""),le(""),pe(""),ge([]),fe(""),be([]),he(""),ve(""),Ne(""),ue(false),ye(""),_e(""),xe(""),Ce(""),Se(""),De(false),Ae(""),Re("ongoing"),we(""),V([]),ee(false),j({}),W==null||W();},mt=t=>{let o=t.target.value;fe(o);let p=o.split(",").map(s=>s.trim()).filter(Boolean);ge(p);},ct=t=>{be(o=>o.includes(t)?o.filter(p=>p!==t):[...o,t]);},lt=t=>{var Ue;let o=t.target.files;if(!o)return;let p=[],s={};if(O.length+o.length>G){s.attachments=`Maximum of ${G} files allowed`,j(f=>a$2(a$2({},f),s));return}for(let f=0;f<o.length;f++){let L=o[f];if(L.size>Z){s.attachments=`File ${L.name} exceeds the maximum size of ${Z/(1024*1024)}MB`;continue}let Ge="."+((Ue=L.name.split(".").pop())==null?void 0:Ue.toLowerCase());if(!K.includes(Ge)){s.attachments=`File type ${Ge} is not allowed`;continue}p.push(L);}p.length>0&&V(f=>[...f,...p]),Object.keys(s).length>0?j(f=>a$2(a$2({},f),s)):j(f=>b(a$2({},f),{attachments:""}));},pt=t=>{V(o=>o.filter((p,s)=>s!==t));},gt=()=>{let t={};return S.trim()||(t.breachTitle="Breach title is required"),D.trim()||(t.description="Description is required"),A||(t.category="Category is required"),h||(t.discoveredAt="Discovery date is required"),T.trim()||(t.reporterName="Reporter name is required"),R.trim()?/^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$/.test(R)||(t.reporterEmail="Reporter email is invalid"):t.reporterEmail="Reporter email is required",I.trim()||(t.reporterDepartment="Reporter department is required"),E.length===0&&(t.affectedSystems="At least one affected system is required"),w.length===0&&(t.dataTypes="At least one data type is required"),b$1&&isNaN(Number(b$1))&&(t.estimatedAffectedSubjects="Estimated affected subjects must be a number"),j(t),t},ft=t=>{t.preventDefault();let o=gt();if(Object.keys(o).length>0){z==null||z(o);return}let p={title:a$3(S),description:a$3(D),category:A,discoveredAt:new Date(h).getTime(),occurredAt:v?new Date(v).getTime():void 0,reportedAt:Date.now(),reporter:{name:a$3(T),email:a$3(R),department:a$3(I),phone:B?a$3(B):void 0},affectedSystems:E.map(s=>a$3(s)),dataTypes:w,estimatedAffectedSubjects:b$1?Number(b$1):void 0,approximateRecordCount:N?Number(N):void 0,dataSubjectCategories:u?u.split(",").map(s=>a$3(s.trim())).filter(Boolean):void 0,involvesSensitiveData:P,likelyConsequences:F?a$3(F):void 0,mitigationMeasures:k?a$3(k):void 0,dpoContact:y||_?{name:a$3(y),email:a$3(_),phone:M?a$3(M):void 0}:void 0,isPhasedReport:Q||void 0,supplementsReportId:X?a$3(X):void 0,status:$,initialActions:q?a$3(q):void 0,attachments:O.map(s=>({name:s.name,type:s.type,size:s.size,file:s}))};Qe(p),Xe&&ee(true);};if(ot)return jsxs("div",{"data-ndpr-component":"breach-report-form",className:`p-4 bg-green-50 dark:bg-green-900/20 rounded-md ${te}`,children:[jsx("h2",{className:"text-lg font-bold ndpr-text-success mb-2",children:"Report Submitted"}),jsx("p",{className:"ndpr-text-success",children:Ve}),jsxs("div",{className:"mt-4 p-4 bg-yellow-50 dark:bg-yellow-900/20 rounded-md",children:[jsx("h3",{className:"text-sm font-bold ndpr-text-warning mb-2",children:"Important: Next Steps"}),jsx("p",{className:"ndpr-text-warning text-sm",children:"Under the NDPA (Section 40), data breaches that pose a risk to the rights and freedoms of data subjects must be reported to the NDPC within 72 hours of discovery. The data protection team will assess this breach and determine if notification is required."})]}),jsx("button",{onClick:()=>ee(false),className:`mt-4 px-4 py-2 bg-green-600 text-white rounded hover:bg-green-700 ${re}`,children:"Report Another Breach"})]});let bt=[{id:"personal",label:"Personal Information (names, addresses)"},{id:"contact",label:"Contact Information (email, phone)"},{id:"financial",label:"Financial Information (bank details, payment info)"},{id:"health",label:"Health Information"},{id:"identification",label:"Identification Documents (ID cards, passports)"},{id:"login",label:"Login Credentials"},{id:"biometric",label:"Biometric Data"},{id:"children",label:"Children's Data"},{id:"location",label:"Location Data"},{id:"communications",label:"Communications Content"}];return jsxs("div",{className:a$1(`bg-white dark:bg-gray-800 p-6 rounded-lg shadow-md ${te}`,d.root,c$1),children:[jsx("h2",{className:a$1("ndpr-section-heading",d.title,c$1),children:rt}),jsx("p",{className:"ndpr-card__subtitle",children:it}),tt&&jsxs("div",{"data-ndpr-section":"breach-completeness",className:a$1("ndpr-alert ndpr-alert--info mb-4",d.completeness,c$1),children:[jsxs("div",{className:"flex items-center justify-between mb-2",children:[jsx("h3",{className:"text-sm font-bold ndpr-text-info",children:"NDPC notification readiness"}),jsxs("span",{className:"text-sm font-semibold ndpr-text-info",children:[g.completeness,"%"]})]}),jsx("div",{role:"progressbar","aria-valuenow":g.completeness,"aria-valuemin":0,"aria-valuemax":100,"aria-label":"Breach notification completeness",className:"h-2 w-full rounded bg-gray-200 dark:bg-gray-700 overflow-hidden mb-2",children:jsx("div",{className:"h-full bg-[rgb(var(--ndpr-primary))]",style:{width:`${g.completeness}%`}})}),jsxs("p",{className:"text-sm ndpr-text-info",children:[st," of ",Fe," mandated items provided (GAID 2025 Art. 33(5) / NDPA S. 40(2))."]}),Number.isFinite(g.timing.deadline)?g.timing.overdue?jsxs("p",{className:"text-sm ndpr-text-warning mt-1",children:["72-hour deadline passed ",Math.abs(g.timing.hoursRemaining),"h ago \u2014 notify the NDPC now and state the reason for the delay (NDPA S. 40(2))."]}):jsxs("p",{className:"text-sm ndpr-text-info mt-1",children:[Math.max(0,g.timing.hoursRemaining),"h remaining to notify the NDPC (72-hour window, NDPA S. 40(2))."]}):jsx("p",{className:"text-sm ndpr-text-muted mt-1",children:"Set the discovery date to start the 72-hour clock."}),g.dataSubjectCommunicationRequired&&jsx("p",{className:"text-sm ndpr-text-warning mt-1",children:"High risk: affected data subjects must be notified in plain, clear language (NDPA S. 40(3))."}),g.missing.length>0&&jsxs("details",{className:"mt-2",children:[jsxs("summary",{className:"text-sm ndpr-text-info cursor-pointer",children:[g.missing.length," item(s) still needed"]}),jsx("ul",{className:"mt-1 list-disc pl-5",children:Pe.filter(t=>!t.satisfied).map(t=>jsxs("li",{className:"text-xs ndpr-text-muted",children:[t.label," ",jsxs("span",{className:"opacity-70",children:["(",t.section,")"]})]},t.id))})]})]}),jsx("form",{onSubmit:ft,className:a$1("",d.form,c$1),children:jsxs("div",{className:"ndpr-form-section",children:[jsxs("div",{className:a$1("",d.fieldGroup,c$1),children:[jsx("h3",{className:"ndpr-section-heading",children:"Breach Information"}),jsxs("div",{className:"ndpr-form-grid ndpr-form-grid--2",children:[jsxs("div",{children:[jsxs("label",{htmlFor:"breachTitle",className:a$1("ndpr-form-field__label",d.label,c$1),children:["Breach Title/Summary ",jsx("span",{className:"ndpr-form-field__required",children:"*"})]}),jsx("input",{type:"text",id:"breachTitle",value:S,onChange:t=>ae(t.target.value),className:a$1("ndpr-form-field__input",d.input,c$1),required:true,"aria-invalid":!!a$4.breachTitle,"aria-describedby":a$4.breachTitle?"breachTitle-error":void 0}),a$4.breachTitle&&jsx("p",{id:"breachTitle-error",role:"alert",className:"ndpr-form-field__error",children:a$4.breachTitle})]}),jsxs("div",{children:[jsxs("label",{htmlFor:"category",className:a$1("ndpr-form-field__label",d.label,c$1),children:["Breach Category ",jsx("span",{className:"ndpr-form-field__required",children:"*"})]}),jsxs("select",{id:"category",value:A,onChange:t=>oe(t.target.value),className:a$1("ndpr-form-field__input",d.select,c$1),required:true,"aria-invalid":!!a$4.category,"aria-describedby":a$4.category?"category-error":void 0,children:[jsx("option",{value:"",children:"Select a category"}),Je.map(t=>jsx("option",{value:t.id,children:t.name},t.id))]}),a$4.category&&jsx("p",{id:"category-error",role:"alert",className:"ndpr-form-field__error",children:a$4.category})]}),jsxs("div",{className:"md:col-span-2",children:[jsxs("label",{htmlFor:"description",className:a$1("ndpr-form-field__label",d.label,c$1),children:["Detailed Description ",jsx("span",{className:"ndpr-form-field__required",children:"*"})]}),jsx("textarea",{id:"description",value:D,onChange:t=>ne(t.target.value),rows:4,className:a$1("ndpr-form-field__input",d.textarea,c$1),required:true,"aria-invalid":!!a$4.description,"aria-describedby":a$4.description?"description-error":void 0}),a$4.description&&jsx("p",{id:"description-error",role:"alert",className:"ndpr-form-field__error",children:a$4.description})]}),jsxs("div",{children:[jsxs("label",{htmlFor:"discoveredAt",className:"ndpr-form-field__label",children:["Date Discovered ",jsx("span",{className:"ndpr-form-field__required",children:"*"})]}),jsx("input",{type:"datetime-local",id:"discoveredAt",value:h,onChange:t=>se(t.target.value),className:"ndpr-form-field__input",required:true,"aria-invalid":!!a$4.discoveredAt,"aria-describedby":a$4.discoveredAt?"discoveredAt-error":void 0}),a$4.discoveredAt&&jsx("p",{id:"discoveredAt-error",role:"alert",className:"ndpr-form-field__error",children:a$4.discoveredAt})]}),jsxs("div",{children:[jsx("label",{htmlFor:"occurredAt",className:"ndpr-form-field__label",children:"Date Occurred (if known)"}),jsx("input",{type:"datetime-local",id:"occurredAt",value:v,onChange:t=>de(t.target.value),className:"ndpr-form-field__input"})]})]})]}),jsxs("div",{children:[jsx("h3",{className:"ndpr-section-heading",children:"Reporter Information"}),jsxs("div",{className:"ndpr-form-grid ndpr-form-grid--2",children:[jsxs("div",{children:[jsxs("label",{htmlFor:"reporterName",className:"ndpr-form-field__label",children:["Your Name ",jsx("span",{className:"ndpr-form-field__required",children:"*"})]}),jsx("input",{type:"text",id:"reporterName",value:T,onChange:t=>me(t.target.value),className:"ndpr-form-field__input",required:true,"aria-invalid":!!a$4.reporterName,"aria-describedby":a$4.reporterName?"reporterName-error":void 0}),a$4.reporterName&&jsx("p",{id:"reporterName-error",role:"alert",className:"ndpr-form-field__error",children:a$4.reporterName})]}),jsxs("div",{children:[jsxs("label",{htmlFor:"reporterEmail",className:"ndpr-form-field__label",children:["Your Email ",jsx("span",{className:"ndpr-form-field__required",children:"*"})]}),jsx("input",{type:"email",id:"reporterEmail",value:R,onChange:t=>ce(t.target.value),className:"ndpr-form-field__input",required:true,"aria-invalid":!!a$4.reporterEmail,"aria-describedby":a$4.reporterEmail?"reporterEmail-error":void 0}),a$4.reporterEmail&&jsx("p",{id:"reporterEmail-error",role:"alert",className:"ndpr-form-field__error",children:a$4.reporterEmail})]}),jsxs("div",{children:[jsxs("label",{htmlFor:"reporterDepartment",className:"ndpr-form-field__label",children:["Your Department ",jsx("span",{className:"ndpr-form-field__required",children:"*"})]}),jsx("input",{type:"text",id:"reporterDepartment",value:I,onChange:t=>le(t.target.value),className:"ndpr-form-field__input",required:true,"aria-invalid":!!a$4.reporterDepartment,"aria-describedby":a$4.reporterDepartment?"reporterDepartment-error":void 0}),a$4.reporterDepartment&&jsx("p",{id:"reporterDepartment-error",role:"alert",className:"ndpr-form-field__error",children:a$4.reporterDepartment})]}),jsxs("div",{children:[jsx("label",{htmlFor:"reporterPhone",className:"ndpr-form-field__label",children:"Your Phone Number (Optional)"}),jsx("input",{type:"tel",id:"reporterPhone",value:B,onChange:t=>pe(t.target.value),className:"ndpr-form-field__input"})]})]})]}),jsxs("div",{children:[jsx("h3",{className:"ndpr-section-heading",children:"Impact Information"}),jsxs("div",{className:"ndpr-form-grid ndpr-form-grid--2",children:[jsxs("div",{children:[jsxs("label",{htmlFor:"affectedSystems",className:"ndpr-form-field__label",children:["Affected Systems/Applications ",jsx("span",{className:"ndpr-form-field__required",children:"*"})]}),jsx("input",{type:"text",id:"affectedSystems",value:nt,onChange:mt,placeholder:"e.g. CRM, Email Server, Website (comma separated)",className:"ndpr-form-field__input",required:true,"aria-invalid":!!a$4.affectedSystems,"aria-describedby":a$4.affectedSystems?"affectedSystems-error":void 0}),a$4.affectedSystems&&jsx("p",{id:"affectedSystems-error",role:"alert",className:"ndpr-form-field__error",children:a$4.affectedSystems})]}),jsxs("div",{children:[jsx("label",{htmlFor:"estimatedAffectedSubjects",className:"ndpr-form-field__label",children:"Estimated Number of Affected Data Subjects"}),jsx("input",{type:"text",id:"estimatedAffectedSubjects",value:b$1,onChange:t=>he(t.target.value),placeholder:"e.g. 100",className:"ndpr-form-field__input","aria-invalid":!!a$4.estimatedAffectedSubjects,"aria-describedby":a$4.estimatedAffectedSubjects?"estimatedAffectedSubjects-error":void 0}),a$4.estimatedAffectedSubjects&&jsx("p",{id:"estimatedAffectedSubjects-error",role:"alert",className:"ndpr-form-field__error",children:a$4.estimatedAffectedSubjects})]}),jsxs("fieldset",{className:"md:col-span-2","aria-invalid":!!a$4.dataTypes,"aria-describedby":a$4.dataTypes?"dataTypes-error":void 0,children:[jsxs("legend",{className:"ndpr-form-field__label",children:["Types of Data Involved ",jsx("span",{className:"ndpr-form-field__required","aria-hidden":"true",children:"*"}),jsx("span",{className:"sr-only",children:"(required)"})]}),jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-2",children:bt.map(t=>jsxs("div",{className:"flex items-center",children:[jsx("input",{type:"checkbox",id:`dataType_${t.id}`,checked:w.includes(t.id),onChange:()=>ct(t.id),className:"h-4 w-4 rounded border-gray-300 text-[rgb(var(--ndpr-primary))] focus:ring-[rgb(var(--ndpr-ring))]"}),jsx("label",{htmlFor:`dataType_${t.id}`,className:"ml-2 text-sm ndpr-text-muted",children:t.label})]},t.id))}),a$4.dataTypes&&jsx("p",{id:"dataTypes-error",role:"alert",className:"ndpr-form-field__error",children:a$4.dataTypes})]}),jsxs("div",{children:[jsxs("label",{htmlFor:"status",className:"ndpr-form-field__label",children:["Current Status ",jsx("span",{className:"ndpr-form-field__required",children:"*"})]}),jsxs("select",{id:"status",value:$,onChange:t=>Re(t.target.value),className:a$1("ndpr-form-field__input",d.select,c$1),required:true,children:[jsx("option",{value:"ongoing",children:"Ongoing (breach is still active)"}),jsx("option",{value:"contained",children:"Contained (breach is stopped but not resolved)"}),jsx("option",{value:"resolved",children:"Resolved (breach is fully addressed)"})]})]}),jsxs("div",{children:[jsx("label",{htmlFor:"approximateRecordCount",className:"ndpr-form-field__label",children:"Approximate Number of Records Concerned"}),jsx("input",{type:"text",id:"approximateRecordCount",value:N,onChange:t=>ve(t.target.value),placeholder:"e.g. 5000",className:"ndpr-form-field__input"}),jsx("p",{className:"text-xs ndpr-text-muted mt-1",children:"Required for the NDPC report (NDPA Section 40(2))."})]}),jsxs("div",{children:[jsx("label",{htmlFor:"dataSubjectCategories",className:"ndpr-form-field__label",children:"Categories of Data Subjects Affected"}),jsx("input",{type:"text",id:"dataSubjectCategories",value:u,onChange:t=>Ne(t.target.value),placeholder:"e.g. customers, employees, minors",className:"ndpr-form-field__input"}),jsx("p",{className:"text-xs ndpr-text-muted mt-1",children:"Comma-separated. Required for the NDPC report (NDPA Section 40(2))."})]}),jsxs("div",{className:"md:col-span-2 flex items-center",children:[jsx("input",{id:"involvesSensitiveData",type:"checkbox",checked:P,onChange:t=>ue(t.target.checked),className:"h-4 w-4 rounded border-gray-300 text-[rgb(var(--ndpr-primary))] focus:ring-[rgb(var(--ndpr-ring))]"}),jsx("label",{htmlFor:"involvesSensitiveData",className:"ml-2 text-sm ndpr-text-muted",children:"Sensitive personal data (NDPA Section 30) is involved"})]}),jsxs("div",{className:"md:col-span-2",children:[jsx("label",{htmlFor:"likelyConsequences",className:"ndpr-form-field__label",children:"Likely Consequences for Data Subjects"}),jsx("textarea",{id:"likelyConsequences",value:F,onChange:t=>ye(t.target.value),placeholder:"e.g. identity theft, financial loss, reputational damage, discrimination",rows:3,className:a$1("ndpr-form-field__input",d.textarea,c$1)}),jsx("p",{className:"text-xs ndpr-text-muted mt-1",children:"Required content for NDPC report and Section 40(3) communications to data subjects."})]}),jsxs("div",{className:"md:col-span-2",children:[jsx("label",{htmlFor:"mitigationMeasures",className:"ndpr-form-field__label",children:"Mitigation Measures"}),jsx("textarea",{id:"mitigationMeasures",value:k,onChange:t=>_e(t.target.value),placeholder:"Measures taken or proposed to mitigate possible adverse effects (NDPA Section 40(3))",rows:3,className:a$1("ndpr-form-field__input",d.textarea,c$1)})]}),jsxs("div",{className:"md:col-span-2",children:[jsx("h4",{className:"ndpr-section-heading text-sm mt-4",children:"Data Protection Officer (NDPC contact)"}),jsx("p",{className:"text-xs ndpr-text-muted mb-2",children:"Defaults to organisation-level DPO if left blank."})]}),jsxs("div",{children:[jsx("label",{htmlFor:"dpoName",className:"ndpr-form-field__label",children:"DPO Name"}),jsx("input",{type:"text",id:"dpoName",value:y,onChange:t=>xe(t.target.value),className:"ndpr-form-field__input"})]}),jsxs("div",{children:[jsx("label",{htmlFor:"dpoEmail",className:"ndpr-form-field__label",children:"DPO Email"}),jsx("input",{type:"email",id:"dpoEmail",value:_,onChange:t=>Ce(t.target.value),className:"ndpr-form-field__input"})]}),jsxs("div",{children:[jsx("label",{htmlFor:"dpoPhone",className:"ndpr-form-field__label",children:"DPO Phone"}),jsx("input",{type:"tel",id:"dpoPhone",value:M,onChange:t=>Se(t.target.value),className:"ndpr-form-field__input"})]}),jsxs("div",{className:"md:col-span-2 flex items-center mt-2",children:[jsx("input",{id:"isPhasedReport",type:"checkbox",checked:Q,onChange:t=>De(t.target.checked),className:"h-4 w-4 rounded border-gray-300 text-[rgb(var(--ndpr-primary))] focus:ring-[rgb(var(--ndpr-ring))]"}),jsx("label",{htmlFor:"isPhasedReport",className:"ml-2 text-sm ndpr-text-muted",children:"This is a phased / interim report (Section 40(2) \u2014 complete info not yet available)"})]}),Q&&jsxs("div",{className:"md:col-span-2",children:[jsx("label",{htmlFor:"supplementsReportId",className:"ndpr-form-field__label",children:"Supplements Report ID (if applicable)"}),jsx("input",{type:"text",id:"supplementsReportId",value:X,onChange:t=>Ae(t.target.value),placeholder:"Prior report ID this report supplements",className:"ndpr-form-field__input"})]}),jsxs("div",{className:"md:col-span-2",children:[jsx("label",{htmlFor:"initialActions",className:"ndpr-form-field__label",children:"Initial Actions Taken"}),jsx("textarea",{id:"initialActions",value:q,onChange:t=>we(t.target.value),placeholder:"Describe any immediate actions that have been taken to address the breach",rows:3,className:a$1("ndpr-form-field__input",d.textarea,c$1)})]})]})]}),et&&jsxs("div",{children:[jsx("h3",{className:"ndpr-section-heading",children:"Attachments"}),jsxs("div",{className:"ndpr-form-field",children:[jsx("label",{htmlFor:"breach-attachments",className:"ndpr-form-field__label",children:"Upload Supporting Files (Optional)"}),jsxs("p",{className:"text-xs ndpr-text-muted mb-2",children:["Max ",G," files, ",Z/(1024*1024),"MB each. Allowed types: ",K.join(", ")]}),jsx("input",{id:"breach-attachments",type:"file",onChange:lt,multiple:true,className:"ndpr-form-field__input",accept:K.join(",")}),a$4.attachments&&jsx("p",{id:"attachments-error",role:"alert",className:"ndpr-form-field__error",children:a$4.attachments})]}),O.length>0&&jsxs("div",{className:"ndpr-form-field",children:[jsx("h4",{className:"ndpr-form-field__label",children:"Attached Files:"}),jsx("ul",{className:"ndpr-form-section",children:O.map((t,o)=>jsxs("li",{className:"flex items-center justify-between p-2 bg-gray-50 dark:bg-gray-700 rounded",children:[jsxs("div",{className:"flex items-center",children:[jsx("svg",{"aria-hidden":"true",focusable:"false",className:"w-4 h-4 ndpr-text-muted mr-2",fill:"currentColor",viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg",children:jsx("path",{fillRule:"evenodd",d:"M8 4a3 3 0 00-3 3v4a5 5 0 0010 0V7a1 1 0 112 0v4a7 7 0 11-14 0V7a5 5 0 0110 0v4a3 3 0 11-6 0V7a1 1 0 012 0v4a1 1 0 102 0V7a3 3 0 00-3-3z",clipRule:"evenodd"})}),jsx("span",{className:"text-sm ndpr-text-muted",children:t.name}),jsxs("span",{className:"ml-2 text-xs ndpr-text-muted",children:["(",(t.size/1024).toFixed(1)," KB)"]})]}),jsxs("button",{type:"button",onClick:()=>pt(o),"aria-label":`Remove attachment ${t.name}`,className:"text-red-500 hover:ndpr-text-destructive p-2 min-w-[44px] min-h-[44px] flex items-center justify-center",children:[jsx("svg",{"aria-hidden":"true",focusable:"false",className:"w-4 h-4",fill:"currentColor",viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg",children:jsx("path",{fillRule:"evenodd",d:"M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z",clipRule:"evenodd"})}),jsx("span",{className:"sr-only",children:"Remove"})]})]},o))})]})]}),jsxs("div",{className:a$1("ndpr-alert ndpr-alert--info",d.notice,c$1),children:[jsx("h3",{className:"text-sm font-bold ndpr-text-info mb-2",children:"NDPA Breach Notification Requirements"}),jsx("p",{className:"ndpr-text-info text-sm",children:"Under the Nigeria Data Protection Act (NDPA), Section 40, data breaches that pose a risk to the rights and freedoms of data subjects must be reported to the NDPC within 72 hours of discovery. The data protection team will assess this breach and determine if notification is required."})]}),jsxs("div",{className:"mt-6 relative flex gap-3",children:[C&&d.loadingOverlay&&jsx("div",{className:d.loadingOverlay}),jsx("button",{type:"submit",disabled:C,className:a$1(`px-6 py-3 bg-[rgb(var(--ndpr-primary))] text-white rounded-md hover:bg-[rgb(var(--ndpr-primary-hover))] focus:outline-none focus:ring-2 focus:ring-[rgb(var(--ndpr-ring))] focus:ring-offset-2 ${re} ${C?"opacity-50 cursor-not-allowed":""}`,d.primaryButton||d.submitButton,c$1),children:C?"Submitting...":at}),jsx("button",{type:"button",onClick:dt,disabled:C,className:a$1("px-6 py-3 bg-gray-200 dark:bg-gray-600 text-gray-700 dark:text-gray-200 rounded-md hover:bg-gray-300 dark:hover:bg-gray-500 focus:outline-none focus:ring-2 focus:ring-gray-400 focus:ring-offset-2",void 0,c$1),children:"Reset"})]})]})})]})};
2
+ export{Ct as a};
@@ -0,0 +1,2 @@
1
+ 'use strict';var chunkY346CURW_js=require('./chunk-Y346CURW.js'),chunkUXUMYP4L_js=require('./chunk-UXUMYP4L.js'),chunkAME4HJR4_js=require('./chunk-AME4HJR4.js'),chunkI5ZDNSX5_js=require('./chunk-I5ZDNSX5.js'),chunkRFPLZDIO_js=require('./chunk-RFPLZDIO.js'),react=require('react'),jsxRuntime=require('react/jsx-runtime');var Ct=({categories:Je,onSubmit:Qe,onValidationError:z,title:Y,description:H,submitButtonText:U,className:te="",buttonClassName:re="",classNames:d={},unstyled:c=false,isSubmitting:C=false,showConfirmation:Xe=true,confirmationMessage:Ve="Your breach report has been submitted successfully. The data protection team has been notified.",allowAttachments:et=true,maxAttachments:G=5,maxFileSize:Z=5*1024*1024,allowedFileTypes:K=[".pdf",".jpg",".jpeg",".png",".doc",".docx",".xls",".xlsx",".txt"],defaultValues:r,onReset:W,showCompleteness:tt=true})=>{var ke,qe,je,Te,Ie,Be,Ee,Me,$e,Oe,Le,ze,Ye,He;let J=chunkI5ZDNSX5_js.c(),rt=(ke=Y!=null?Y:J.breach.title)!=null?ke:"Report a Data Breach",it=(qe=H!=null?H:J.breach.description)!=null?qe:"Use this form to report a suspected or confirmed data breach in accordance with NDPA Section 40. All fields marked with * are required.",at=(je=U!=null?U:J.breach.submitReport)!=null?je:"Submit Report",ie=t=>{if(!t)return "";let o=new Date(t),p=s=>String(s).padStart(2,"0");return `${o.getFullYear()}-${p(o.getMonth()+1)}-${p(o.getDate())}T${p(o.getHours())}:${p(o.getMinutes())}`},[S,ae]=react.useState((r==null?void 0:r.title)||""),[D,ne]=react.useState((r==null?void 0:r.description)||""),[A,oe]=react.useState((r==null?void 0:r.category)||""),[h,se]=react.useState(ie(r==null?void 0:r.discoveredAt)),[v,de]=react.useState(ie(r==null?void 0:r.occurredAt)),[T,me]=react.useState(((Te=r==null?void 0:r.reporter)==null?void 0:Te.name)||""),[R,ce]=react.useState(((Ie=r==null?void 0:r.reporter)==null?void 0:Ie.email)||""),[I,le]=react.useState(((Be=r==null?void 0:r.reporter)==null?void 0:Be.department)||""),[B,pe]=react.useState(((Ee=r==null?void 0:r.reporter)==null?void 0:Ee.phone)||""),[E,ge]=react.useState((r==null?void 0:r.affectedSystems)||[]),[nt,fe]=react.useState(((Me=r==null?void 0:r.affectedSystems)==null?void 0:Me.join(", "))||""),[w,be]=react.useState((r==null?void 0:r.dataTypes)||[]),[b,he]=react.useState((r==null?void 0:r.estimatedAffectedSubjects)!=null?String(r.estimatedAffectedSubjects):""),[N,ve]=react.useState((r==null?void 0:r.approximateRecordCount)!=null?String(r.approximateRecordCount):""),[u,Ne]=react.useState((($e=r==null?void 0:r.dataSubjectCategories)==null?void 0:$e.join(", "))||""),[P,ue]=react.useState((Oe=r==null?void 0:r.involvesSensitiveData)!=null?Oe:false),[F,ye]=react.useState((r==null?void 0:r.likelyConsequences)||""),[k,_e]=react.useState((r==null?void 0:r.mitigationMeasures)||""),[y,xe]=react.useState(((Le=r==null?void 0:r.dpoContact)==null?void 0:Le.name)||""),[_,Ce]=react.useState(((ze=r==null?void 0:r.dpoContact)==null?void 0:ze.email)||""),[M,Se]=react.useState(((Ye=r==null?void 0:r.dpoContact)==null?void 0:Ye.phone)||""),[Q,De]=react.useState((He=r==null?void 0:r.isPhasedReport)!=null?He:false),[X,Ae]=react.useState((r==null?void 0:r.supplementsReportId)||""),[$,Re]=react.useState((r==null?void 0:r.status)||"ongoing"),[q,we]=react.useState((r==null?void 0:r.initialActions)||""),[O,V]=react.useState([]),[ot,ee]=react.useState(false),[a,j]=react.useState({}),g=react.useMemo(()=>{let t={id:"",title:S,description:D,category:A,discoveredAt:h?new Date(h).getTime():NaN,occurredAt:v?new Date(v).getTime():void 0,reportedAt:0,reporter:{name:T,email:R,department:I,phone:B||void 0},affectedSystems:E,dataTypes:w,estimatedAffectedSubjects:b?Number(b):void 0,approximateRecordCount:N?Number(N):void 0,dataSubjectCategories:u?u.split(",").map(o=>o.trim()).filter(Boolean):void 0,involvesSensitiveData:P,likelyConsequences:F||void 0,mitigationMeasures:k||void 0,dpoContact:y||_?{name:y,email:_,phone:M||void 0}:void 0,status:$,initialActions:q||void 0};return chunkY346CURW_js.a(t,{highRisk:P})},[S,D,A,h,v,E,w,b,N,u,P,F,k,y,_,$,q]),Pe=[...g.notificationToCommission,...g.dataSubjectCommunication],Fe=Pe.length,st=Fe-g.missing.length,dt=()=>{ae(""),ne(""),oe(""),se(""),de(""),me(""),ce(""),le(""),pe(""),ge([]),fe(""),be([]),he(""),ve(""),Ne(""),ue(false),ye(""),_e(""),xe(""),Ce(""),Se(""),De(false),Ae(""),Re("ongoing"),we(""),V([]),ee(false),j({}),W==null||W();},mt=t=>{let o=t.target.value;fe(o);let p=o.split(",").map(s=>s.trim()).filter(Boolean);ge(p);},ct=t=>{be(o=>o.includes(t)?o.filter(p=>p!==t):[...o,t]);},lt=t=>{var Ue;let o=t.target.files;if(!o)return;let p=[],s={};if(O.length+o.length>G){s.attachments=`Maximum of ${G} files allowed`,j(f=>chunkRFPLZDIO_js.a(chunkRFPLZDIO_js.a({},f),s));return}for(let f=0;f<o.length;f++){let L=o[f];if(L.size>Z){s.attachments=`File ${L.name} exceeds the maximum size of ${Z/(1024*1024)}MB`;continue}let Ge="."+((Ue=L.name.split(".").pop())==null?void 0:Ue.toLowerCase());if(!K.includes(Ge)){s.attachments=`File type ${Ge} is not allowed`;continue}p.push(L);}p.length>0&&V(f=>[...f,...p]),Object.keys(s).length>0?j(f=>chunkRFPLZDIO_js.a(chunkRFPLZDIO_js.a({},f),s)):j(f=>chunkRFPLZDIO_js.b(chunkRFPLZDIO_js.a({},f),{attachments:""}));},pt=t=>{V(o=>o.filter((p,s)=>s!==t));},gt=()=>{let t={};return S.trim()||(t.breachTitle="Breach title is required"),D.trim()||(t.description="Description is required"),A||(t.category="Category is required"),h||(t.discoveredAt="Discovery date is required"),T.trim()||(t.reporterName="Reporter name is required"),R.trim()?/^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$/.test(R)||(t.reporterEmail="Reporter email is invalid"):t.reporterEmail="Reporter email is required",I.trim()||(t.reporterDepartment="Reporter department is required"),E.length===0&&(t.affectedSystems="At least one affected system is required"),w.length===0&&(t.dataTypes="At least one data type is required"),b&&isNaN(Number(b))&&(t.estimatedAffectedSubjects="Estimated affected subjects must be a number"),j(t),t},ft=t=>{t.preventDefault();let o=gt();if(Object.keys(o).length>0){z==null||z(o);return}let p={title:chunkUXUMYP4L_js.a(S),description:chunkUXUMYP4L_js.a(D),category:A,discoveredAt:new Date(h).getTime(),occurredAt:v?new Date(v).getTime():void 0,reportedAt:Date.now(),reporter:{name:chunkUXUMYP4L_js.a(T),email:chunkUXUMYP4L_js.a(R),department:chunkUXUMYP4L_js.a(I),phone:B?chunkUXUMYP4L_js.a(B):void 0},affectedSystems:E.map(s=>chunkUXUMYP4L_js.a(s)),dataTypes:w,estimatedAffectedSubjects:b?Number(b):void 0,approximateRecordCount:N?Number(N):void 0,dataSubjectCategories:u?u.split(",").map(s=>chunkUXUMYP4L_js.a(s.trim())).filter(Boolean):void 0,involvesSensitiveData:P,likelyConsequences:F?chunkUXUMYP4L_js.a(F):void 0,mitigationMeasures:k?chunkUXUMYP4L_js.a(k):void 0,dpoContact:y||_?{name:chunkUXUMYP4L_js.a(y),email:chunkUXUMYP4L_js.a(_),phone:M?chunkUXUMYP4L_js.a(M):void 0}:void 0,isPhasedReport:Q||void 0,supplementsReportId:X?chunkUXUMYP4L_js.a(X):void 0,status:$,initialActions:q?chunkUXUMYP4L_js.a(q):void 0,attachments:O.map(s=>({name:s.name,type:s.type,size:s.size,file:s}))};Qe(p),Xe&&ee(true);};if(ot)return jsxRuntime.jsxs("div",{"data-ndpr-component":"breach-report-form",className:`p-4 bg-green-50 dark:bg-green-900/20 rounded-md ${te}`,children:[jsxRuntime.jsx("h2",{className:"text-lg font-bold ndpr-text-success mb-2",children:"Report Submitted"}),jsxRuntime.jsx("p",{className:"ndpr-text-success",children:Ve}),jsxRuntime.jsxs("div",{className:"mt-4 p-4 bg-yellow-50 dark:bg-yellow-900/20 rounded-md",children:[jsxRuntime.jsx("h3",{className:"text-sm font-bold ndpr-text-warning mb-2",children:"Important: Next Steps"}),jsxRuntime.jsx("p",{className:"ndpr-text-warning text-sm",children:"Under the NDPA (Section 40), data breaches that pose a risk to the rights and freedoms of data subjects must be reported to the NDPC within 72 hours of discovery. The data protection team will assess this breach and determine if notification is required."})]}),jsxRuntime.jsx("button",{onClick:()=>ee(false),className:`mt-4 px-4 py-2 bg-green-600 text-white rounded hover:bg-green-700 ${re}`,children:"Report Another Breach"})]});let bt=[{id:"personal",label:"Personal Information (names, addresses)"},{id:"contact",label:"Contact Information (email, phone)"},{id:"financial",label:"Financial Information (bank details, payment info)"},{id:"health",label:"Health Information"},{id:"identification",label:"Identification Documents (ID cards, passports)"},{id:"login",label:"Login Credentials"},{id:"biometric",label:"Biometric Data"},{id:"children",label:"Children's Data"},{id:"location",label:"Location Data"},{id:"communications",label:"Communications Content"}];return jsxRuntime.jsxs("div",{className:chunkAME4HJR4_js.a(`bg-white dark:bg-gray-800 p-6 rounded-lg shadow-md ${te}`,d.root,c),children:[jsxRuntime.jsx("h2",{className:chunkAME4HJR4_js.a("ndpr-section-heading",d.title,c),children:rt}),jsxRuntime.jsx("p",{className:"ndpr-card__subtitle",children:it}),tt&&jsxRuntime.jsxs("div",{"data-ndpr-section":"breach-completeness",className:chunkAME4HJR4_js.a("ndpr-alert ndpr-alert--info mb-4",d.completeness,c),children:[jsxRuntime.jsxs("div",{className:"flex items-center justify-between mb-2",children:[jsxRuntime.jsx("h3",{className:"text-sm font-bold ndpr-text-info",children:"NDPC notification readiness"}),jsxRuntime.jsxs("span",{className:"text-sm font-semibold ndpr-text-info",children:[g.completeness,"%"]})]}),jsxRuntime.jsx("div",{role:"progressbar","aria-valuenow":g.completeness,"aria-valuemin":0,"aria-valuemax":100,"aria-label":"Breach notification completeness",className:"h-2 w-full rounded bg-gray-200 dark:bg-gray-700 overflow-hidden mb-2",children:jsxRuntime.jsx("div",{className:"h-full bg-[rgb(var(--ndpr-primary))]",style:{width:`${g.completeness}%`}})}),jsxRuntime.jsxs("p",{className:"text-sm ndpr-text-info",children:[st," of ",Fe," mandated items provided (GAID 2025 Art. 33(5) / NDPA S. 40(2))."]}),Number.isFinite(g.timing.deadline)?g.timing.overdue?jsxRuntime.jsxs("p",{className:"text-sm ndpr-text-warning mt-1",children:["72-hour deadline passed ",Math.abs(g.timing.hoursRemaining),"h ago \u2014 notify the NDPC now and state the reason for the delay (NDPA S. 40(2))."]}):jsxRuntime.jsxs("p",{className:"text-sm ndpr-text-info mt-1",children:[Math.max(0,g.timing.hoursRemaining),"h remaining to notify the NDPC (72-hour window, NDPA S. 40(2))."]}):jsxRuntime.jsx("p",{className:"text-sm ndpr-text-muted mt-1",children:"Set the discovery date to start the 72-hour clock."}),g.dataSubjectCommunicationRequired&&jsxRuntime.jsx("p",{className:"text-sm ndpr-text-warning mt-1",children:"High risk: affected data subjects must be notified in plain, clear language (NDPA S. 40(3))."}),g.missing.length>0&&jsxRuntime.jsxs("details",{className:"mt-2",children:[jsxRuntime.jsxs("summary",{className:"text-sm ndpr-text-info cursor-pointer",children:[g.missing.length," item(s) still needed"]}),jsxRuntime.jsx("ul",{className:"mt-1 list-disc pl-5",children:Pe.filter(t=>!t.satisfied).map(t=>jsxRuntime.jsxs("li",{className:"text-xs ndpr-text-muted",children:[t.label," ",jsxRuntime.jsxs("span",{className:"opacity-70",children:["(",t.section,")"]})]},t.id))})]})]}),jsxRuntime.jsx("form",{onSubmit:ft,className:chunkAME4HJR4_js.a("",d.form,c),children:jsxRuntime.jsxs("div",{className:"ndpr-form-section",children:[jsxRuntime.jsxs("div",{className:chunkAME4HJR4_js.a("",d.fieldGroup,c),children:[jsxRuntime.jsx("h3",{className:"ndpr-section-heading",children:"Breach Information"}),jsxRuntime.jsxs("div",{className:"ndpr-form-grid ndpr-form-grid--2",children:[jsxRuntime.jsxs("div",{children:[jsxRuntime.jsxs("label",{htmlFor:"breachTitle",className:chunkAME4HJR4_js.a("ndpr-form-field__label",d.label,c),children:["Breach Title/Summary ",jsxRuntime.jsx("span",{className:"ndpr-form-field__required",children:"*"})]}),jsxRuntime.jsx("input",{type:"text",id:"breachTitle",value:S,onChange:t=>ae(t.target.value),className:chunkAME4HJR4_js.a("ndpr-form-field__input",d.input,c),required:true,"aria-invalid":!!a.breachTitle,"aria-describedby":a.breachTitle?"breachTitle-error":void 0}),a.breachTitle&&jsxRuntime.jsx("p",{id:"breachTitle-error",role:"alert",className:"ndpr-form-field__error",children:a.breachTitle})]}),jsxRuntime.jsxs("div",{children:[jsxRuntime.jsxs("label",{htmlFor:"category",className:chunkAME4HJR4_js.a("ndpr-form-field__label",d.label,c),children:["Breach Category ",jsxRuntime.jsx("span",{className:"ndpr-form-field__required",children:"*"})]}),jsxRuntime.jsxs("select",{id:"category",value:A,onChange:t=>oe(t.target.value),className:chunkAME4HJR4_js.a("ndpr-form-field__input",d.select,c),required:true,"aria-invalid":!!a.category,"aria-describedby":a.category?"category-error":void 0,children:[jsxRuntime.jsx("option",{value:"",children:"Select a category"}),Je.map(t=>jsxRuntime.jsx("option",{value:t.id,children:t.name},t.id))]}),a.category&&jsxRuntime.jsx("p",{id:"category-error",role:"alert",className:"ndpr-form-field__error",children:a.category})]}),jsxRuntime.jsxs("div",{className:"md:col-span-2",children:[jsxRuntime.jsxs("label",{htmlFor:"description",className:chunkAME4HJR4_js.a("ndpr-form-field__label",d.label,c),children:["Detailed Description ",jsxRuntime.jsx("span",{className:"ndpr-form-field__required",children:"*"})]}),jsxRuntime.jsx("textarea",{id:"description",value:D,onChange:t=>ne(t.target.value),rows:4,className:chunkAME4HJR4_js.a("ndpr-form-field__input",d.textarea,c),required:true,"aria-invalid":!!a.description,"aria-describedby":a.description?"description-error":void 0}),a.description&&jsxRuntime.jsx("p",{id:"description-error",role:"alert",className:"ndpr-form-field__error",children:a.description})]}),jsxRuntime.jsxs("div",{children:[jsxRuntime.jsxs("label",{htmlFor:"discoveredAt",className:"ndpr-form-field__label",children:["Date Discovered ",jsxRuntime.jsx("span",{className:"ndpr-form-field__required",children:"*"})]}),jsxRuntime.jsx("input",{type:"datetime-local",id:"discoveredAt",value:h,onChange:t=>se(t.target.value),className:"ndpr-form-field__input",required:true,"aria-invalid":!!a.discoveredAt,"aria-describedby":a.discoveredAt?"discoveredAt-error":void 0}),a.discoveredAt&&jsxRuntime.jsx("p",{id:"discoveredAt-error",role:"alert",className:"ndpr-form-field__error",children:a.discoveredAt})]}),jsxRuntime.jsxs("div",{children:[jsxRuntime.jsx("label",{htmlFor:"occurredAt",className:"ndpr-form-field__label",children:"Date Occurred (if known)"}),jsxRuntime.jsx("input",{type:"datetime-local",id:"occurredAt",value:v,onChange:t=>de(t.target.value),className:"ndpr-form-field__input"})]})]})]}),jsxRuntime.jsxs("div",{children:[jsxRuntime.jsx("h3",{className:"ndpr-section-heading",children:"Reporter Information"}),jsxRuntime.jsxs("div",{className:"ndpr-form-grid ndpr-form-grid--2",children:[jsxRuntime.jsxs("div",{children:[jsxRuntime.jsxs("label",{htmlFor:"reporterName",className:"ndpr-form-field__label",children:["Your Name ",jsxRuntime.jsx("span",{className:"ndpr-form-field__required",children:"*"})]}),jsxRuntime.jsx("input",{type:"text",id:"reporterName",value:T,onChange:t=>me(t.target.value),className:"ndpr-form-field__input",required:true,"aria-invalid":!!a.reporterName,"aria-describedby":a.reporterName?"reporterName-error":void 0}),a.reporterName&&jsxRuntime.jsx("p",{id:"reporterName-error",role:"alert",className:"ndpr-form-field__error",children:a.reporterName})]}),jsxRuntime.jsxs("div",{children:[jsxRuntime.jsxs("label",{htmlFor:"reporterEmail",className:"ndpr-form-field__label",children:["Your Email ",jsxRuntime.jsx("span",{className:"ndpr-form-field__required",children:"*"})]}),jsxRuntime.jsx("input",{type:"email",id:"reporterEmail",value:R,onChange:t=>ce(t.target.value),className:"ndpr-form-field__input",required:true,"aria-invalid":!!a.reporterEmail,"aria-describedby":a.reporterEmail?"reporterEmail-error":void 0}),a.reporterEmail&&jsxRuntime.jsx("p",{id:"reporterEmail-error",role:"alert",className:"ndpr-form-field__error",children:a.reporterEmail})]}),jsxRuntime.jsxs("div",{children:[jsxRuntime.jsxs("label",{htmlFor:"reporterDepartment",className:"ndpr-form-field__label",children:["Your Department ",jsxRuntime.jsx("span",{className:"ndpr-form-field__required",children:"*"})]}),jsxRuntime.jsx("input",{type:"text",id:"reporterDepartment",value:I,onChange:t=>le(t.target.value),className:"ndpr-form-field__input",required:true,"aria-invalid":!!a.reporterDepartment,"aria-describedby":a.reporterDepartment?"reporterDepartment-error":void 0}),a.reporterDepartment&&jsxRuntime.jsx("p",{id:"reporterDepartment-error",role:"alert",className:"ndpr-form-field__error",children:a.reporterDepartment})]}),jsxRuntime.jsxs("div",{children:[jsxRuntime.jsx("label",{htmlFor:"reporterPhone",className:"ndpr-form-field__label",children:"Your Phone Number (Optional)"}),jsxRuntime.jsx("input",{type:"tel",id:"reporterPhone",value:B,onChange:t=>pe(t.target.value),className:"ndpr-form-field__input"})]})]})]}),jsxRuntime.jsxs("div",{children:[jsxRuntime.jsx("h3",{className:"ndpr-section-heading",children:"Impact Information"}),jsxRuntime.jsxs("div",{className:"ndpr-form-grid ndpr-form-grid--2",children:[jsxRuntime.jsxs("div",{children:[jsxRuntime.jsxs("label",{htmlFor:"affectedSystems",className:"ndpr-form-field__label",children:["Affected Systems/Applications ",jsxRuntime.jsx("span",{className:"ndpr-form-field__required",children:"*"})]}),jsxRuntime.jsx("input",{type:"text",id:"affectedSystems",value:nt,onChange:mt,placeholder:"e.g. CRM, Email Server, Website (comma separated)",className:"ndpr-form-field__input",required:true,"aria-invalid":!!a.affectedSystems,"aria-describedby":a.affectedSystems?"affectedSystems-error":void 0}),a.affectedSystems&&jsxRuntime.jsx("p",{id:"affectedSystems-error",role:"alert",className:"ndpr-form-field__error",children:a.affectedSystems})]}),jsxRuntime.jsxs("div",{children:[jsxRuntime.jsx("label",{htmlFor:"estimatedAffectedSubjects",className:"ndpr-form-field__label",children:"Estimated Number of Affected Data Subjects"}),jsxRuntime.jsx("input",{type:"text",id:"estimatedAffectedSubjects",value:b,onChange:t=>he(t.target.value),placeholder:"e.g. 100",className:"ndpr-form-field__input","aria-invalid":!!a.estimatedAffectedSubjects,"aria-describedby":a.estimatedAffectedSubjects?"estimatedAffectedSubjects-error":void 0}),a.estimatedAffectedSubjects&&jsxRuntime.jsx("p",{id:"estimatedAffectedSubjects-error",role:"alert",className:"ndpr-form-field__error",children:a.estimatedAffectedSubjects})]}),jsxRuntime.jsxs("fieldset",{className:"md:col-span-2","aria-invalid":!!a.dataTypes,"aria-describedby":a.dataTypes?"dataTypes-error":void 0,children:[jsxRuntime.jsxs("legend",{className:"ndpr-form-field__label",children:["Types of Data Involved ",jsxRuntime.jsx("span",{className:"ndpr-form-field__required","aria-hidden":"true",children:"*"}),jsxRuntime.jsx("span",{className:"sr-only",children:"(required)"})]}),jsxRuntime.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-2",children:bt.map(t=>jsxRuntime.jsxs("div",{className:"flex items-center",children:[jsxRuntime.jsx("input",{type:"checkbox",id:`dataType_${t.id}`,checked:w.includes(t.id),onChange:()=>ct(t.id),className:"h-4 w-4 rounded border-gray-300 text-[rgb(var(--ndpr-primary))] focus:ring-[rgb(var(--ndpr-ring))]"}),jsxRuntime.jsx("label",{htmlFor:`dataType_${t.id}`,className:"ml-2 text-sm ndpr-text-muted",children:t.label})]},t.id))}),a.dataTypes&&jsxRuntime.jsx("p",{id:"dataTypes-error",role:"alert",className:"ndpr-form-field__error",children:a.dataTypes})]}),jsxRuntime.jsxs("div",{children:[jsxRuntime.jsxs("label",{htmlFor:"status",className:"ndpr-form-field__label",children:["Current Status ",jsxRuntime.jsx("span",{className:"ndpr-form-field__required",children:"*"})]}),jsxRuntime.jsxs("select",{id:"status",value:$,onChange:t=>Re(t.target.value),className:chunkAME4HJR4_js.a("ndpr-form-field__input",d.select,c),required:true,children:[jsxRuntime.jsx("option",{value:"ongoing",children:"Ongoing (breach is still active)"}),jsxRuntime.jsx("option",{value:"contained",children:"Contained (breach is stopped but not resolved)"}),jsxRuntime.jsx("option",{value:"resolved",children:"Resolved (breach is fully addressed)"})]})]}),jsxRuntime.jsxs("div",{children:[jsxRuntime.jsx("label",{htmlFor:"approximateRecordCount",className:"ndpr-form-field__label",children:"Approximate Number of Records Concerned"}),jsxRuntime.jsx("input",{type:"text",id:"approximateRecordCount",value:N,onChange:t=>ve(t.target.value),placeholder:"e.g. 5000",className:"ndpr-form-field__input"}),jsxRuntime.jsx("p",{className:"text-xs ndpr-text-muted mt-1",children:"Required for the NDPC report (NDPA Section 40(2))."})]}),jsxRuntime.jsxs("div",{children:[jsxRuntime.jsx("label",{htmlFor:"dataSubjectCategories",className:"ndpr-form-field__label",children:"Categories of Data Subjects Affected"}),jsxRuntime.jsx("input",{type:"text",id:"dataSubjectCategories",value:u,onChange:t=>Ne(t.target.value),placeholder:"e.g. customers, employees, minors",className:"ndpr-form-field__input"}),jsxRuntime.jsx("p",{className:"text-xs ndpr-text-muted mt-1",children:"Comma-separated. Required for the NDPC report (NDPA Section 40(2))."})]}),jsxRuntime.jsxs("div",{className:"md:col-span-2 flex items-center",children:[jsxRuntime.jsx("input",{id:"involvesSensitiveData",type:"checkbox",checked:P,onChange:t=>ue(t.target.checked),className:"h-4 w-4 rounded border-gray-300 text-[rgb(var(--ndpr-primary))] focus:ring-[rgb(var(--ndpr-ring))]"}),jsxRuntime.jsx("label",{htmlFor:"involvesSensitiveData",className:"ml-2 text-sm ndpr-text-muted",children:"Sensitive personal data (NDPA Section 30) is involved"})]}),jsxRuntime.jsxs("div",{className:"md:col-span-2",children:[jsxRuntime.jsx("label",{htmlFor:"likelyConsequences",className:"ndpr-form-field__label",children:"Likely Consequences for Data Subjects"}),jsxRuntime.jsx("textarea",{id:"likelyConsequences",value:F,onChange:t=>ye(t.target.value),placeholder:"e.g. identity theft, financial loss, reputational damage, discrimination",rows:3,className:chunkAME4HJR4_js.a("ndpr-form-field__input",d.textarea,c)}),jsxRuntime.jsx("p",{className:"text-xs ndpr-text-muted mt-1",children:"Required content for NDPC report and Section 40(3) communications to data subjects."})]}),jsxRuntime.jsxs("div",{className:"md:col-span-2",children:[jsxRuntime.jsx("label",{htmlFor:"mitigationMeasures",className:"ndpr-form-field__label",children:"Mitigation Measures"}),jsxRuntime.jsx("textarea",{id:"mitigationMeasures",value:k,onChange:t=>_e(t.target.value),placeholder:"Measures taken or proposed to mitigate possible adverse effects (NDPA Section 40(3))",rows:3,className:chunkAME4HJR4_js.a("ndpr-form-field__input",d.textarea,c)})]}),jsxRuntime.jsxs("div",{className:"md:col-span-2",children:[jsxRuntime.jsx("h4",{className:"ndpr-section-heading text-sm mt-4",children:"Data Protection Officer (NDPC contact)"}),jsxRuntime.jsx("p",{className:"text-xs ndpr-text-muted mb-2",children:"Defaults to organisation-level DPO if left blank."})]}),jsxRuntime.jsxs("div",{children:[jsxRuntime.jsx("label",{htmlFor:"dpoName",className:"ndpr-form-field__label",children:"DPO Name"}),jsxRuntime.jsx("input",{type:"text",id:"dpoName",value:y,onChange:t=>xe(t.target.value),className:"ndpr-form-field__input"})]}),jsxRuntime.jsxs("div",{children:[jsxRuntime.jsx("label",{htmlFor:"dpoEmail",className:"ndpr-form-field__label",children:"DPO Email"}),jsxRuntime.jsx("input",{type:"email",id:"dpoEmail",value:_,onChange:t=>Ce(t.target.value),className:"ndpr-form-field__input"})]}),jsxRuntime.jsxs("div",{children:[jsxRuntime.jsx("label",{htmlFor:"dpoPhone",className:"ndpr-form-field__label",children:"DPO Phone"}),jsxRuntime.jsx("input",{type:"tel",id:"dpoPhone",value:M,onChange:t=>Se(t.target.value),className:"ndpr-form-field__input"})]}),jsxRuntime.jsxs("div",{className:"md:col-span-2 flex items-center mt-2",children:[jsxRuntime.jsx("input",{id:"isPhasedReport",type:"checkbox",checked:Q,onChange:t=>De(t.target.checked),className:"h-4 w-4 rounded border-gray-300 text-[rgb(var(--ndpr-primary))] focus:ring-[rgb(var(--ndpr-ring))]"}),jsxRuntime.jsx("label",{htmlFor:"isPhasedReport",className:"ml-2 text-sm ndpr-text-muted",children:"This is a phased / interim report (Section 40(2) \u2014 complete info not yet available)"})]}),Q&&jsxRuntime.jsxs("div",{className:"md:col-span-2",children:[jsxRuntime.jsx("label",{htmlFor:"supplementsReportId",className:"ndpr-form-field__label",children:"Supplements Report ID (if applicable)"}),jsxRuntime.jsx("input",{type:"text",id:"supplementsReportId",value:X,onChange:t=>Ae(t.target.value),placeholder:"Prior report ID this report supplements",className:"ndpr-form-field__input"})]}),jsxRuntime.jsxs("div",{className:"md:col-span-2",children:[jsxRuntime.jsx("label",{htmlFor:"initialActions",className:"ndpr-form-field__label",children:"Initial Actions Taken"}),jsxRuntime.jsx("textarea",{id:"initialActions",value:q,onChange:t=>we(t.target.value),placeholder:"Describe any immediate actions that have been taken to address the breach",rows:3,className:chunkAME4HJR4_js.a("ndpr-form-field__input",d.textarea,c)})]})]})]}),et&&jsxRuntime.jsxs("div",{children:[jsxRuntime.jsx("h3",{className:"ndpr-section-heading",children:"Attachments"}),jsxRuntime.jsxs("div",{className:"ndpr-form-field",children:[jsxRuntime.jsx("label",{htmlFor:"breach-attachments",className:"ndpr-form-field__label",children:"Upload Supporting Files (Optional)"}),jsxRuntime.jsxs("p",{className:"text-xs ndpr-text-muted mb-2",children:["Max ",G," files, ",Z/(1024*1024),"MB each. Allowed types: ",K.join(", ")]}),jsxRuntime.jsx("input",{id:"breach-attachments",type:"file",onChange:lt,multiple:true,className:"ndpr-form-field__input",accept:K.join(",")}),a.attachments&&jsxRuntime.jsx("p",{id:"attachments-error",role:"alert",className:"ndpr-form-field__error",children:a.attachments})]}),O.length>0&&jsxRuntime.jsxs("div",{className:"ndpr-form-field",children:[jsxRuntime.jsx("h4",{className:"ndpr-form-field__label",children:"Attached Files:"}),jsxRuntime.jsx("ul",{className:"ndpr-form-section",children:O.map((t,o)=>jsxRuntime.jsxs("li",{className:"flex items-center justify-between p-2 bg-gray-50 dark:bg-gray-700 rounded",children:[jsxRuntime.jsxs("div",{className:"flex items-center",children:[jsxRuntime.jsx("svg",{"aria-hidden":"true",focusable:"false",className:"w-4 h-4 ndpr-text-muted mr-2",fill:"currentColor",viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg",children:jsxRuntime.jsx("path",{fillRule:"evenodd",d:"M8 4a3 3 0 00-3 3v4a5 5 0 0010 0V7a1 1 0 112 0v4a7 7 0 11-14 0V7a5 5 0 0110 0v4a3 3 0 11-6 0V7a1 1 0 012 0v4a1 1 0 102 0V7a3 3 0 00-3-3z",clipRule:"evenodd"})}),jsxRuntime.jsx("span",{className:"text-sm ndpr-text-muted",children:t.name}),jsxRuntime.jsxs("span",{className:"ml-2 text-xs ndpr-text-muted",children:["(",(t.size/1024).toFixed(1)," KB)"]})]}),jsxRuntime.jsxs("button",{type:"button",onClick:()=>pt(o),"aria-label":`Remove attachment ${t.name}`,className:"text-red-500 hover:ndpr-text-destructive p-2 min-w-[44px] min-h-[44px] flex items-center justify-center",children:[jsxRuntime.jsx("svg",{"aria-hidden":"true",focusable:"false",className:"w-4 h-4",fill:"currentColor",viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg",children:jsxRuntime.jsx("path",{fillRule:"evenodd",d:"M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z",clipRule:"evenodd"})}),jsxRuntime.jsx("span",{className:"sr-only",children:"Remove"})]})]},o))})]})]}),jsxRuntime.jsxs("div",{className:chunkAME4HJR4_js.a("ndpr-alert ndpr-alert--info",d.notice,c),children:[jsxRuntime.jsx("h3",{className:"text-sm font-bold ndpr-text-info mb-2",children:"NDPA Breach Notification Requirements"}),jsxRuntime.jsx("p",{className:"ndpr-text-info text-sm",children:"Under the Nigeria Data Protection Act (NDPA), Section 40, data breaches that pose a risk to the rights and freedoms of data subjects must be reported to the NDPC within 72 hours of discovery. The data protection team will assess this breach and determine if notification is required."})]}),jsxRuntime.jsxs("div",{className:"mt-6 relative flex gap-3",children:[C&&d.loadingOverlay&&jsxRuntime.jsx("div",{className:d.loadingOverlay}),jsxRuntime.jsx("button",{type:"submit",disabled:C,className:chunkAME4HJR4_js.a(`px-6 py-3 bg-[rgb(var(--ndpr-primary))] text-white rounded-md hover:bg-[rgb(var(--ndpr-primary-hover))] focus:outline-none focus:ring-2 focus:ring-[rgb(var(--ndpr-ring))] focus:ring-offset-2 ${re} ${C?"opacity-50 cursor-not-allowed":""}`,d.primaryButton||d.submitButton,c),children:C?"Submitting...":at}),jsxRuntime.jsx("button",{type:"button",onClick:dt,disabled:C,className:chunkAME4HJR4_js.a("px-6 py-3 bg-gray-200 dark:bg-gray-600 text-gray-700 dark:text-gray-200 rounded-md hover:bg-gray-300 dark:hover:bg-gray-500 focus:outline-none focus:ring-2 focus:ring-gray-400 focus:ring-offset-2",void 0,c),children:"Reset"})]})]})})]})};
2
+ exports.a=Ct;
@@ -0,0 +1 @@
1
+ import {c,d}from'./chunk-SZXHNJGG.mjs';import {a}from'./chunk-WJSUVPYX.mjs';import {a as a$1}from'./chunk-6A7M4CGJ.mjs';import {useMemo}from'react';function u(t,e){return useMemo(()=>a(t,e),[t,e])}function M({input:t}){let e=JSON.stringify(t);return useMemo(()=>a$1(t),[e])}function D(t,e){return useMemo(()=>c(t,e),[t.dataSubjectsInSixMonths,t.isDesignated,e])}function P(t,e){return useMemo(()=>d(t,e),[t.commencementDate,t.asOf,t.tier,e])}export{u as a,M as b,D as c,P as d};
@@ -0,0 +1 @@
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;
@@ -0,0 +1 @@
1
+ var t=e=>typeof e=="string"&&e.trim().length>0,m=e=>typeof e=="number"&&Number.isFinite(e)&&e>=0,C=e=>Array.isArray(e)&&e.length>0,R=e=>!!e&&t(e.name)&&t(e.email);function M(e,n={}){var p,N,D,S,y;let s=(p=n.asOf)!=null?p:Date.now(),k=(N=n.deadlineHours)!=null?N:72,d=e.discoveredAt+k*36e5,o=n.notification,f=!!o,u=o==null?void 0:o.sentAt,c=(f?u:s)>d,h={deadline:d,hoursSinceDiscovery:Math.round((s-e.discoveredAt)/36e5),notified:f,notifiedAt:u,withinDeadline:!c,hoursRemaining:Math.round((d-s)/36e5),overdue:c,requiresDelayJustification:c},b=[{id:"circumstances",label:"Description of the circumstances of the breach",section:"GAID 2025 Art. 33(5)(a)",satisfied:t(e.description)},{id:"occurrence",label:"Date or time period of the breach",section:"GAID 2025 Art. 33(5)(b)",satisfied:m(e.occurredAt)},{id:"personalInfo",label:"Description of the personal data involved",section:"GAID 2025 Art. 33(5)(c)",satisfied:C(e.dataTypes)},{id:"riskOfHarm",label:"Assessment of the risk of harm to data subjects",section:"GAID 2025 Art. 33(5)(d)",satisfied:t(e.likelyConsequences)},{id:"numberAtRisk",label:"Estimated number of data subjects at risk of significant harm",section:"GAID 2025 Art. 33(5)(e)",satisfied:m(e.estimatedAffectedSubjects)},{id:"mitigation",label:"Steps taken to reduce the risk of harm",section:"GAID 2025 Art. 33(5)(f)",satisfied:t(e.mitigationMeasures)},{id:"notifySteps",label:"Steps taken to notify affected data subjects",section:"GAID 2025 Art. 33(5)(g)",satisfied:t(e.initialActions)},{id:"contactPoint",label:"Name and contact details of a contact point",section:"GAID 2025 Art. 33(5)(h)",satisfied:R(e.dpoContact)},{id:"dataSubjectCategories",label:"Categories of data subjects concerned",section:"NDPA 2023 S. 40(2)",satisfied:C(e.dataSubjectCategories)},{id:"recordCount",label:"Approximate number of personal data records concerned",section:"NDPA 2023 S. 40(2)",satisfied:m(e.approximateRecordCount)}],l=(y=(S=n.highRisk)!=null?S:(D=n.assessment)==null?void 0:D.highRisksToRightsAndFreedoms)!=null?y:false,A=l?[{id:"dsNature",label:"Nature and context of the breach in plain language",section:"NDPA 2023 S. 40(3)",satisfied:t(e.description)},{id:"dsConsequences",label:"Likely consequences of the breach",section:"NDPA 2023 S. 40(3)",satisfied:t(e.likelyConsequences)},{id:"dsMeasures",label:"Safeguards and measures data subjects can take",section:"NDPA 2023 S. 40(3)",satisfied:t(e.mitigationMeasures)},{id:"dsContact",label:"Contact point for data subjects",section:"NDPA 2023 S. 40(3)",satisfied:R(e.dpoContact)}]:[],r=[...b,...A],B=r.filter(i=>i.satisfied).length,j=Math.round(B/r.length*100),g=r.filter(i=>!i.satisfied).map(i=>i.label),I=g.length===0,a=[];for(let i of r.filter(P=>!P.satisfied))a.push(`Add: ${i.label} (${i.section}).`);return c?a.push("The 72-hour notification deadline has passed \u2014 notify the NDPC now and state the reasons for the delay; phased reporting is permitted where complete details are not yet available (NDPA S. 40(2))."):f||a.push(`${Math.max(0,h.hoursRemaining)} hour(s) remain to notify the NDPC within the 72-hour window (NDPA S. 40(2)).`),l&&a.push("High risk to data subjects \u2014 communicate the breach to affected data subjects immediately, in plain and clear language (NDPA S. 40(3))."),{complete:I,completeness:j,notificationToCommission:b,dataSubjectCommunication:A,dataSubjectCommunicationRequired:l,timing:h,missing:g,recommendations:a,asOf:s}}export{M as a};
@@ -0,0 +1 @@
1
+ 'use strict';var t=e=>typeof e=="string"&&e.trim().length>0,m=e=>typeof e=="number"&&Number.isFinite(e)&&e>=0,C=e=>Array.isArray(e)&&e.length>0,R=e=>!!e&&t(e.name)&&t(e.email);function M(e,n={}){var p,N,D,S,y;let s=(p=n.asOf)!=null?p:Date.now(),k=(N=n.deadlineHours)!=null?N:72,d=e.discoveredAt+k*36e5,o=n.notification,f=!!o,u=o==null?void 0:o.sentAt,c=(f?u:s)>d,h={deadline:d,hoursSinceDiscovery:Math.round((s-e.discoveredAt)/36e5),notified:f,notifiedAt:u,withinDeadline:!c,hoursRemaining:Math.round((d-s)/36e5),overdue:c,requiresDelayJustification:c},b=[{id:"circumstances",label:"Description of the circumstances of the breach",section:"GAID 2025 Art. 33(5)(a)",satisfied:t(e.description)},{id:"occurrence",label:"Date or time period of the breach",section:"GAID 2025 Art. 33(5)(b)",satisfied:m(e.occurredAt)},{id:"personalInfo",label:"Description of the personal data involved",section:"GAID 2025 Art. 33(5)(c)",satisfied:C(e.dataTypes)},{id:"riskOfHarm",label:"Assessment of the risk of harm to data subjects",section:"GAID 2025 Art. 33(5)(d)",satisfied:t(e.likelyConsequences)},{id:"numberAtRisk",label:"Estimated number of data subjects at risk of significant harm",section:"GAID 2025 Art. 33(5)(e)",satisfied:m(e.estimatedAffectedSubjects)},{id:"mitigation",label:"Steps taken to reduce the risk of harm",section:"GAID 2025 Art. 33(5)(f)",satisfied:t(e.mitigationMeasures)},{id:"notifySteps",label:"Steps taken to notify affected data subjects",section:"GAID 2025 Art. 33(5)(g)",satisfied:t(e.initialActions)},{id:"contactPoint",label:"Name and contact details of a contact point",section:"GAID 2025 Art. 33(5)(h)",satisfied:R(e.dpoContact)},{id:"dataSubjectCategories",label:"Categories of data subjects concerned",section:"NDPA 2023 S. 40(2)",satisfied:C(e.dataSubjectCategories)},{id:"recordCount",label:"Approximate number of personal data records concerned",section:"NDPA 2023 S. 40(2)",satisfied:m(e.approximateRecordCount)}],l=(y=(S=n.highRisk)!=null?S:(D=n.assessment)==null?void 0:D.highRisksToRightsAndFreedoms)!=null?y:false,A=l?[{id:"dsNature",label:"Nature and context of the breach in plain language",section:"NDPA 2023 S. 40(3)",satisfied:t(e.description)},{id:"dsConsequences",label:"Likely consequences of the breach",section:"NDPA 2023 S. 40(3)",satisfied:t(e.likelyConsequences)},{id:"dsMeasures",label:"Safeguards and measures data subjects can take",section:"NDPA 2023 S. 40(3)",satisfied:t(e.mitigationMeasures)},{id:"dsContact",label:"Contact point for data subjects",section:"NDPA 2023 S. 40(3)",satisfied:R(e.dpoContact)}]:[],r=[...b,...A],B=r.filter(i=>i.satisfied).length,j=Math.round(B/r.length*100),g=r.filter(i=>!i.satisfied).map(i=>i.label),I=g.length===0,a=[];for(let i of r.filter(P=>!P.satisfied))a.push(`Add: ${i.label} (${i.section}).`);return c?a.push("The 72-hour notification deadline has passed \u2014 notify the NDPC now and state the reasons for the delay; phased reporting is permitted where complete details are not yet available (NDPA S. 40(2))."):f||a.push(`${Math.max(0,h.hoursRemaining)} hour(s) remain to notify the NDPC within the 72-hour window (NDPA S. 40(2)).`),l&&a.push("High risk to data subjects \u2014 communicate the breach to affected data subjects immediately, in plain and clear language (NDPA S. 40(3))."),{complete:I,completeness:j,notificationToCommission:b,dataSubjectCommunication:A,dataSubjectCommunicationRequired:l,timing:h,missing:g,recommendations:a,asOf:s}}exports.a=M;
package/dist/core.d.mts CHANGED
@@ -62,6 +62,12 @@ export declare const arabicLocale: Required<{
62
62
  */
63
63
  export declare function assemblePolicy(context: TemplateContext): PolicySection[];
64
64
 
65
+ /**
66
+ * Assess a breach report against the NDPA S. 40 / GAID 2025 Article 33
67
+ * notification requirements.
68
+ */
69
+ export declare function assessBreachNotification(report: BreachReport, options?: BreachNotificationOptions): BreachNotificationAssessment;
70
+
65
71
  /**
66
72
  * Analyzes all processing activities and returns compliance gaps including
67
73
  * missing DPO approval, overdue reviews, undocumented justifications,
@@ -112,6 +118,93 @@ export declare interface BreachCategory {
112
118
  defaultSeverity: 'low' | 'medium' | 'high' | 'critical';
113
119
  }
114
120
 
121
+ export declare interface BreachNotificationAssessment {
122
+ /** Whether all applicable mandated content items are satisfied. */
123
+ complete: boolean;
124
+ /** Completeness of applicable content items, 0–100. */
125
+ completeness: number;
126
+ /** GAID 2025 Article 33(5) / NDPA S. 40(2) content of the notification to the Commission. */
127
+ notificationToCommission: BreachNotificationItem[];
128
+ /** NDPA S. 40(3) communication to data subjects — populated only when high-risk. */
129
+ dataSubjectCommunication: BreachNotificationItem[];
130
+ /** Whether a data-subject communication is owed (high risk). */
131
+ dataSubjectCommunicationRequired: boolean;
132
+ timing: BreachNotificationTiming;
133
+ /** Labels of unsatisfied applicable items. */
134
+ missing: string[];
135
+ /** Actionable next steps, including timing warnings. */
136
+ recommendations: string[];
137
+ asOf: number;
138
+ }
139
+
140
+ export declare interface BreachNotificationItem {
141
+ /** Stable identifier for the requirement. */
142
+ id: string;
143
+ /** Human-readable requirement. */
144
+ label: string;
145
+ /** Authoritative citation, e.g. `GAID 2025 Art. 33(5)(a)`. */
146
+ section: string;
147
+ /** Whether the report satisfies it. */
148
+ satisfied: boolean;
149
+ }
150
+
151
+ /**
152
+ * Personal-data-breach notification completeness checker for NDPA 2023
153
+ * Section 40, as detailed by NDPC General Application and Implementation
154
+ * Directive (GAID) 2025 Article 33.
155
+ *
156
+ * Section 40(2) requires a data controller to notify the Commission within 72
157
+ * hours of becoming aware of a breach likely to result in a risk to data
158
+ * subjects' rights and freedoms. GAID 2025 Article 33(5)(a)–(h) enumerates the
159
+ * content that a notification to the Commission "shall include". Where the
160
+ * breach is likely to result in a *high* risk, Section 40(3) additionally
161
+ * requires the controller to communicate the breach to affected data subjects
162
+ * in plain and clear language.
163
+ *
164
+ * This assesses a `BreachReport` against those requirements: which mandated
165
+ * content items are present, whether the 72-hour window is met, and whether a
166
+ * data-subject communication is owed. It is a documentation-completeness aid,
167
+ * not legal advice — verify against current NDPC guidance.
168
+ *
169
+ * @see NDPA 2023 Section 40 (Personal data breaches)
170
+ * @see NDPC GAID 2025 Article 33 (Data Breach Notification)
171
+ */
172
+
173
+ export declare interface BreachNotificationOptions {
174
+ /** Risk assessment for the breach; drives whether data-subject communication is required. */
175
+ assessment?: RiskAssessment;
176
+ /** The regulatory notification actually sent, if any — used to judge timeliness. */
177
+ notification?: RegulatoryNotification;
178
+ /** Reference "now" in epoch ms. Defaults to `Date.now()`. */
179
+ asOf?: number;
180
+ /** Notification window in hours. Defaults to 72 (NDPA S. 40(2)). */
181
+ deadlineHours?: number;
182
+ /**
183
+ * Explicit high-risk flag (NDPA S. 40(3)). When omitted, derived from
184
+ * `assessment.highRisksToRightsAndFreedoms`.
185
+ */
186
+ highRisk?: boolean;
187
+ }
188
+
189
+ export declare interface BreachNotificationTiming {
190
+ /** `discoveredAt` + the notification window. */
191
+ deadline: number;
192
+ /** Whole hours between discovery and `asOf`. */
193
+ hoursSinceDiscovery: number;
194
+ /** Whether a regulatory notification has been recorded. */
195
+ notified: boolean;
196
+ /** When the regulatory notification was sent, if any. */
197
+ notifiedAt?: number;
198
+ /** Whether the notification (or, if none, `asOf`) falls within the deadline. */
199
+ withinDeadline: boolean;
200
+ /** Whole hours from `asOf` to the deadline (negative once past). */
201
+ hoursRemaining: number;
202
+ /** Whether the deadline has been missed. */
203
+ overdue: boolean;
204
+ /** Late filings must state the reasons for the delay (NDPA S. 40(2)). */
205
+ requiresDelayJustification: boolean;
206
+ }
207
+
115
208
  /**
116
209
  * Represents a data breach report
117
210
  */
package/dist/core.d.ts CHANGED
@@ -62,6 +62,12 @@ export declare const arabicLocale: Required<{
62
62
  */
63
63
  export declare function assemblePolicy(context: TemplateContext): PolicySection[];
64
64
 
65
+ /**
66
+ * Assess a breach report against the NDPA S. 40 / GAID 2025 Article 33
67
+ * notification requirements.
68
+ */
69
+ export declare function assessBreachNotification(report: BreachReport, options?: BreachNotificationOptions): BreachNotificationAssessment;
70
+
65
71
  /**
66
72
  * Analyzes all processing activities and returns compliance gaps including
67
73
  * missing DPO approval, overdue reviews, undocumented justifications,
@@ -112,6 +118,93 @@ export declare interface BreachCategory {
112
118
  defaultSeverity: 'low' | 'medium' | 'high' | 'critical';
113
119
  }
114
120
 
121
+ export declare interface BreachNotificationAssessment {
122
+ /** Whether all applicable mandated content items are satisfied. */
123
+ complete: boolean;
124
+ /** Completeness of applicable content items, 0–100. */
125
+ completeness: number;
126
+ /** GAID 2025 Article 33(5) / NDPA S. 40(2) content of the notification to the Commission. */
127
+ notificationToCommission: BreachNotificationItem[];
128
+ /** NDPA S. 40(3) communication to data subjects — populated only when high-risk. */
129
+ dataSubjectCommunication: BreachNotificationItem[];
130
+ /** Whether a data-subject communication is owed (high risk). */
131
+ dataSubjectCommunicationRequired: boolean;
132
+ timing: BreachNotificationTiming;
133
+ /** Labels of unsatisfied applicable items. */
134
+ missing: string[];
135
+ /** Actionable next steps, including timing warnings. */
136
+ recommendations: string[];
137
+ asOf: number;
138
+ }
139
+
140
+ export declare interface BreachNotificationItem {
141
+ /** Stable identifier for the requirement. */
142
+ id: string;
143
+ /** Human-readable requirement. */
144
+ label: string;
145
+ /** Authoritative citation, e.g. `GAID 2025 Art. 33(5)(a)`. */
146
+ section: string;
147
+ /** Whether the report satisfies it. */
148
+ satisfied: boolean;
149
+ }
150
+
151
+ /**
152
+ * Personal-data-breach notification completeness checker for NDPA 2023
153
+ * Section 40, as detailed by NDPC General Application and Implementation
154
+ * Directive (GAID) 2025 Article 33.
155
+ *
156
+ * Section 40(2) requires a data controller to notify the Commission within 72
157
+ * hours of becoming aware of a breach likely to result in a risk to data
158
+ * subjects' rights and freedoms. GAID 2025 Article 33(5)(a)–(h) enumerates the
159
+ * content that a notification to the Commission "shall include". Where the
160
+ * breach is likely to result in a *high* risk, Section 40(3) additionally
161
+ * requires the controller to communicate the breach to affected data subjects
162
+ * in plain and clear language.
163
+ *
164
+ * This assesses a `BreachReport` against those requirements: which mandated
165
+ * content items are present, whether the 72-hour window is met, and whether a
166
+ * data-subject communication is owed. It is a documentation-completeness aid,
167
+ * not legal advice — verify against current NDPC guidance.
168
+ *
169
+ * @see NDPA 2023 Section 40 (Personal data breaches)
170
+ * @see NDPC GAID 2025 Article 33 (Data Breach Notification)
171
+ */
172
+
173
+ export declare interface BreachNotificationOptions {
174
+ /** Risk assessment for the breach; drives whether data-subject communication is required. */
175
+ assessment?: RiskAssessment;
176
+ /** The regulatory notification actually sent, if any — used to judge timeliness. */
177
+ notification?: RegulatoryNotification;
178
+ /** Reference "now" in epoch ms. Defaults to `Date.now()`. */
179
+ asOf?: number;
180
+ /** Notification window in hours. Defaults to 72 (NDPA S. 40(2)). */
181
+ deadlineHours?: number;
182
+ /**
183
+ * Explicit high-risk flag (NDPA S. 40(3)). When omitted, derived from
184
+ * `assessment.highRisksToRightsAndFreedoms`.
185
+ */
186
+ highRisk?: boolean;
187
+ }
188
+
189
+ export declare interface BreachNotificationTiming {
190
+ /** `discoveredAt` + the notification window. */
191
+ deadline: number;
192
+ /** Whole hours between discovery and `asOf`. */
193
+ hoursSinceDiscovery: number;
194
+ /** Whether a regulatory notification has been recorded. */
195
+ notified: boolean;
196
+ /** When the regulatory notification was sent, if any. */
197
+ notifiedAt?: number;
198
+ /** Whether the notification (or, if none, `asOf`) falls within the deadline. */
199
+ withinDeadline: boolean;
200
+ /** Whole hours from `asOf` to the deadline (negative once past). */
201
+ hoursRemaining: number;
202
+ /** Whether the deadline has been missed. */
203
+ overdue: boolean;
204
+ /** Late filings must state the reasons for the delay (NDPA S. 40(2)). */
205
+ requiresDelayJustification: boolean;
206
+ }
207
+
115
208
  /**
116
209
  * Represents a data breach report
117
210
  */
package/dist/core.js CHANGED
@@ -1 +1 @@
1
- 'use strict';var chunkLP5KXMBY_js=require('./chunk-LP5KXMBY.js'),chunkNUOHT3LO_js=require('./chunk-NUOHT3LO.js'),chunkWKY26JLT_js=require('./chunk-WKY26JLT.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'),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'),chunkI5ZDNSX5_js=require('./chunk-I5ZDNSX5.js'),chunk7563FVMY_js=require('./chunk-7563FVMY.js');require('./chunk-RFPLZDIO.js');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,"DEFAULT_DCPMI_FEES_NGN",{enumerable:true,get:function(){return chunkWKY26JLT_js.b}});Object.defineProperty(exports,"DEFAULT_DCPMI_THRESHOLDS",{enumerable:true,get:function(){return chunkWKY26JLT_js.a}});Object.defineProperty(exports,"classifyDCPMI",{enumerable:true,get:function(){return chunkWKY26JLT_js.c}});Object.defineProperty(exports,"generateComplianceAuditReturn",{enumerable:true,get:function(){return chunkWKY26JLT_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,"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,"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,"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,"NDPRProvider",{enumerable:true,get:function(){return chunkI5ZDNSX5_js.a}});Object.defineProperty(exports,"useNDPRConfig",{enumerable:true,get:function(){return chunkI5ZDNSX5_js.b}});Object.defineProperty(exports,"useNDPRLocale",{enumerable:true,get:function(){return chunkI5ZDNSX5_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}});
1
+ 'use strict';var chunkLP5KXMBY_js=require('./chunk-LP5KXMBY.js'),chunkNUOHT3LO_js=require('./chunk-NUOHT3LO.js'),chunkWKY26JLT_js=require('./chunk-WKY26JLT.js'),chunkY346CURW_js=require('./chunk-Y346CURW.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'),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'),chunkI5ZDNSX5_js=require('./chunk-I5ZDNSX5.js'),chunk7563FVMY_js=require('./chunk-7563FVMY.js');require('./chunk-RFPLZDIO.js');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,"DEFAULT_DCPMI_FEES_NGN",{enumerable:true,get:function(){return chunkWKY26JLT_js.b}});Object.defineProperty(exports,"DEFAULT_DCPMI_THRESHOLDS",{enumerable:true,get:function(){return chunkWKY26JLT_js.a}});Object.defineProperty(exports,"classifyDCPMI",{enumerable:true,get:function(){return chunkWKY26JLT_js.c}});Object.defineProperty(exports,"generateComplianceAuditReturn",{enumerable:true,get:function(){return chunkWKY26JLT_js.d}});Object.defineProperty(exports,"assessBreachNotification",{enumerable:true,get:function(){return chunkY346CURW_js.a}});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,"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,"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,"NDPRProvider",{enumerable:true,get:function(){return chunkI5ZDNSX5_js.a}});Object.defineProperty(exports,"useNDPRConfig",{enumerable:true,get:function(){return chunkI5ZDNSX5_js.b}});Object.defineProperty(exports,"useNDPRLocale",{enumerable:true,get:function(){return chunkI5ZDNSX5_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}});
package/dist/core.mjs CHANGED
@@ -1 +1 @@
1
- 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 DEFAULT_DCPMI_FEES_NGN,a as DEFAULT_DCPMI_THRESHOLDS,c as classifyDCPMI,d as generateComplianceAuditReturn}from'./chunk-SZXHNJGG.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{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 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 NDPRProvider,b as useNDPRConfig,c as useNDPRLocale}from'./chunk-PHA3YMFO.mjs';export{a as defaultLocale,b as mergeLocale}from'./chunk-5LJ652AH.mjs';import'./chunk-ZJYULEER.mjs';
1
+ 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 DEFAULT_DCPMI_FEES_NGN,a as DEFAULT_DCPMI_THRESHOLDS,c as classifyDCPMI,d as generateComplianceAuditReturn}from'./chunk-SZXHNJGG.mjs';export{a as assessBreachNotification}from'./chunk-WJSUVPYX.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{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 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 NDPRProvider,b as useNDPRConfig,c as useNDPRLocale}from'./chunk-PHA3YMFO.mjs';export{a as defaultLocale,b as mergeLocale}from'./chunk-5LJ652AH.mjs';import'./chunk-ZJYULEER.mjs';