@tantainnovative/ndpr-toolkit 3.2.1 → 3.3.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.
Files changed (133) hide show
  1. package/README.md +34 -1
  2. package/dist/{DPIAQuestionnaire-BkejviPj.d.mts → DPIAQuestionnaire-VXBoWFMC.d.ts} +3 -3
  3. package/dist/{DPIAQuestionnaire-DdSqXG3x.d.ts → DPIAQuestionnaire-jkt1Veb6.d.mts} +3 -3
  4. package/dist/{DSRRequestForm-BY8PogCU.d.mts → DSRRequestForm-D8rPTNmU.d.ts} +2 -2
  5. package/dist/{DSRRequestForm-CHUg9cZh.d.ts → DSRRequestForm-DRouEr9j.d.mts} +2 -2
  6. package/dist/{DSRTracker-Dr_aT0pg.d.ts → DSRTracker-Bl__d4df.d.ts} +1 -1
  7. package/dist/{DSRTracker-C6u_jAaK.d.mts → DSRTracker-CSVDfgQQ.d.mts} +1 -1
  8. package/dist/{StepIndicator-D9ZATz_O.d.ts → StepIndicator-CgrlokSV.d.ts} +1 -1
  9. package/dist/{StepIndicator-D-nwRTyo.d.mts → StepIndicator-W8S_QjgO.d.mts} +1 -1
  10. package/dist/chunk-25OOUES4.js +2 -0
  11. package/dist/chunk-4JKTIR33.mjs +2 -0
  12. package/dist/chunk-5BUS6AI7.js +2 -0
  13. package/dist/chunk-5X32J5IA.mjs +2 -0
  14. package/dist/chunk-6JCRDJQI.mjs +2 -0
  15. package/dist/chunk-6YN73KR7.mjs +2 -0
  16. package/dist/chunk-75TJPK2N.mjs +2 -0
  17. package/dist/{chunk-NXQMU36Z.mjs → chunk-7D2OIPHH.mjs} +2 -2
  18. package/dist/chunk-C4YM4UMI.js +2 -0
  19. package/dist/{chunk-EH2I4L7M.mjs → chunk-CDZDT2OS.mjs} +14 -10
  20. package/dist/chunk-CSIJCLGZ.mjs +2 -0
  21. package/dist/chunk-GMLCWGNJ.js +7 -0
  22. package/dist/chunk-GQVNLUP2.js +94 -0
  23. package/dist/chunk-GXLSOZCH.mjs +2 -0
  24. package/dist/chunk-IQJO7WIH.js +7 -0
  25. package/dist/{chunk-NRQELKAE.js → chunk-JKKRPS4P.js} +2 -2
  26. package/dist/chunk-LETEUS5X.mjs +2 -0
  27. package/dist/{chunk-KBP26GLC.js → chunk-M6XETYNL.js} +2 -2
  28. package/dist/chunk-NBSVFQ5G.js +2 -0
  29. package/dist/chunk-NUULHXVL.mjs +7 -0
  30. package/dist/chunk-QDHHD2KR.mjs +94 -0
  31. package/dist/chunk-TI2M7H6R.mjs +7 -0
  32. package/dist/chunk-TKVJ3OOV.mjs +2 -0
  33. package/dist/{chunk-KVOGOLIR.js → chunk-TXXWCB5O.js} +14 -10
  34. package/dist/{chunk-44W4H2EY.js → chunk-UGY5ZYUG.js} +2 -2
  35. package/dist/chunk-UO6QPJLH.js +2 -0
  36. package/dist/chunk-UX6ZZNEM.mjs +3 -0
  37. package/dist/{chunk-3DJGO6WG.js → chunk-VLSGE2YA.js} +2 -2
  38. package/dist/chunk-XFUEZ3MP.mjs +2 -0
  39. package/dist/chunk-XHSHPB74.js +2 -0
  40. package/dist/chunk-YCX6BFOQ.js +2 -0
  41. package/dist/chunk-YURSF2YO.mjs +2 -0
  42. package/dist/chunk-YZXUAIYN.js +3 -0
  43. package/dist/chunk-ZGJA7OO4.js +2 -0
  44. package/dist/chunk-ZT7KNFAU.mjs +2 -0
  45. package/dist/chunk-ZYLDLGFL.js +2 -0
  46. package/dist/consent.js +1 -1
  47. package/dist/consent.mjs +1 -1
  48. package/dist/core.d.mts +21 -9
  49. package/dist/core.d.ts +21 -9
  50. package/dist/core.js +1 -1
  51. package/dist/core.mjs +1 -1
  52. package/dist/cross-border.d.mts +68 -1
  53. package/dist/cross-border.d.ts +68 -1
  54. package/dist/cross-border.js +1 -1
  55. package/dist/cross-border.mjs +1 -1
  56. package/dist/{dpia-B0Pok5us.d.ts → dpia-D82hUrJe.d.ts} +1 -1
  57. package/dist/{dpia-CUfOmzvX.d.mts → dpia-DQDFw2_l.d.mts} +1 -1
  58. package/dist/{dpia-5OQVA1R_.d.mts → dpia-c9GiiOq0.d.mts} +2 -2
  59. package/dist/{dpia-5OQVA1R_.d.ts → dpia-c9GiiOq0.d.ts} +2 -2
  60. package/dist/dpia.d.mts +9 -9
  61. package/dist/dpia.d.ts +9 -9
  62. package/dist/dpia.js +1 -1
  63. package/dist/dpia.mjs +1 -1
  64. package/dist/{dsr-D_eTNc4S.d.mts → dsr-CIx5sd7e.d.ts} +2 -2
  65. package/dist/{dsr-pNtVb1BK.d.ts → dsr-XZ_HqTlA.d.mts} +2 -2
  66. package/dist/{dsr-Cm9lzWG7.d.mts → dsr-yKbqX531.d.mts} +1 -1
  67. package/dist/{dsr-Cm9lzWG7.d.ts → dsr-yKbqX531.d.ts} +1 -1
  68. package/dist/dsr.d.mts +9 -9
  69. package/dist/dsr.d.ts +9 -9
  70. package/dist/dsr.js +1 -1
  71. package/dist/dsr.mjs +1 -1
  72. package/dist/hooks.d.mts +6 -6
  73. package/dist/hooks.d.ts +6 -6
  74. package/dist/hooks.js +1 -1
  75. package/dist/hooks.mjs +1 -1
  76. package/dist/index.d.mts +11 -11
  77. package/dist/index.d.ts +11 -11
  78. package/dist/index.js +1 -1
  79. package/dist/index.mjs +1 -1
  80. package/dist/lawful-basis.js +1 -1
  81. package/dist/lawful-basis.mjs +1 -1
  82. package/dist/{policy-engine-DSQpT55_.d.ts → policy-engine-C6nC2t3a.d.ts} +1 -1
  83. package/dist/{policy-engine-C-tShzZH.d.mts → policy-engine-DefZcX3R.d.mts} +1 -1
  84. package/dist/{policy-sections-CfNVBLCh.d.mts → policy-sections-Bylm31kZ.d.mts} +1 -1
  85. package/dist/{policy-sections-DqH0iZRf.d.ts → policy-sections-DFDPVCCg.d.ts} +1 -1
  86. package/dist/policy.d.mts +4 -4
  87. package/dist/policy.d.ts +4 -4
  88. package/dist/policy.js +1 -1
  89. package/dist/policy.mjs +1 -1
  90. package/dist/presets.d.mts +5 -5
  91. package/dist/presets.d.ts +5 -5
  92. package/dist/presets.js +1 -1
  93. package/dist/presets.mjs +1 -1
  94. package/dist/ropa.js +1 -1
  95. package/dist/ropa.mjs +1 -1
  96. package/dist/{sanitize-9mOO_cJW.d.mts → sanitize-B0AzEm1D.d.mts} +14 -1
  97. package/dist/{sanitize-9mOO_cJW.d.ts → sanitize-B0AzEm1D.d.ts} +14 -1
  98. package/dist/{useAdaptivePolicyWizard-N4eUM4Tj.d.mts → useAdaptivePolicyWizard-A1PyOy6P.d.mts} +1 -1
  99. package/dist/{useAdaptivePolicyWizard-B9Op2gYM.d.ts → useAdaptivePolicyWizard-LVIKhAxw.d.ts} +1 -1
  100. package/dist/{useDPIA-DzWye8JB.d.mts → useDPIA-B6180UQn.d.mts} +9 -5
  101. package/dist/{useDPIA-Dl16Te3r.d.ts → useDPIA-CTqbNbww.d.ts} +9 -5
  102. package/dist/{useDSR-C1LksCfP.d.mts → useDSR-WvHk8_iu.d.mts} +2 -2
  103. package/dist/{useDSR-DZel52O1.d.ts → useDSR-wH4H6hSM.d.ts} +2 -2
  104. package/package.json +1 -1
  105. package/dist/chunk-2FWCVWKN.js +0 -2
  106. package/dist/chunk-3UWT64FI.mjs +0 -2
  107. package/dist/chunk-4JUDKBA2.mjs +0 -7
  108. package/dist/chunk-4XCL62MJ.mjs +0 -2
  109. package/dist/chunk-555WWZ3W.js +0 -2
  110. package/dist/chunk-CL53OI3I.js +0 -7
  111. package/dist/chunk-ELKEZEV5.mjs +0 -2
  112. package/dist/chunk-ER7X6E36.js +0 -2
  113. package/dist/chunk-FOXZRRMW.mjs +0 -2
  114. package/dist/chunk-FY5G6DGZ.js +0 -7
  115. package/dist/chunk-GOD4LA2J.mjs +0 -2
  116. package/dist/chunk-I23WPZNQ.mjs +0 -94
  117. package/dist/chunk-IQF726GS.js +0 -2
  118. package/dist/chunk-IR7VCBWV.mjs +0 -2
  119. package/dist/chunk-K45S6YQV.mjs +0 -2
  120. package/dist/chunk-KBAFOVE3.js +0 -2
  121. package/dist/chunk-MDWG2KDA.mjs +0 -2
  122. package/dist/chunk-NN233SGA.mjs +0 -3
  123. package/dist/chunk-NPI5T6NH.mjs +0 -7
  124. package/dist/chunk-QH6YUVJS.js +0 -2
  125. package/dist/chunk-QKK5S54L.mjs +0 -2
  126. package/dist/chunk-QY7PD5XB.js +0 -94
  127. package/dist/chunk-TVW6KBVV.mjs +0 -2
  128. package/dist/chunk-UDNRAQLE.js +0 -3
  129. package/dist/chunk-UNKXYVXY.js +0 -2
  130. package/dist/chunk-V37BM2LF.js +0 -2
  131. package/dist/chunk-V3MXWGXU.mjs +0 -2
  132. package/dist/chunk-VK27WVV3.js +0 -2
  133. package/dist/chunk-XQ4M5FHC.mjs +0 -2
@@ -0,0 +1,2 @@
1
+ import {d,c,a as a$1,b as b$1}from'./chunk-TXBZPCGF.mjs';import {a as a$2}from'./chunk-AYKLAEOU.mjs';import {b,a}from'./chunk-WWT2ZSNU.mjs';import {useState,useMemo,useCallback}from'react';import {jsx,jsxs}from'react/jsx-runtime';var q={name:"",description:"",lawfulBasis:"consent",lawfulBasisJustification:"",dataCategories:"",involvesSensitiveData:false,sensitiveDataCondition:"",dataSubjectCategories:"",purposes:"",retentionPeriod:"",retentionJustification:"",recipients:"",crossBorderTransfer:false,reviewDate:"",liaPurposeTest:"",liaNecessityTest:"",liaBalancingTest:"",liaSafeguards:"",liaConclusion:""},Q=[{value:"consent",label:"Consent"},{value:"contract",label:"Contract"},{value:"legal_obligation",label:"Legal Obligation"},{value:"vital_interests",label:"Vital Interests"},{value:"public_interest",label:"Public Interest"},{value:"legitimate_interests",label:"Legitimate Interests"}],X=[{value:"explicit_consent",label:"Explicit Consent"},{value:"employment_law",label:"Employment Law"},{value:"vital_interests_incapable",label:"Vital Interests (Incapable)"},{value:"nonprofit_legitimate",label:"Nonprofit Legitimate Activities"},{value:"publicly_available",label:"Publicly Available Data"},{value:"legal_claims",label:"Legal Claims"},{value:"substantial_public_interest",label:"Substantial Public Interest"},{value:"health_purposes",label:"Health Purposes"},{value:"public_health",label:"Public Health"},{value:"archiving_research",label:"Archiving / Research"}],Ce=({activities:c$1,onAddActivity:F,onUpdateActivity:_,onArchiveActivity:j,title:Z="Lawful Basis Tracker",description:ee="Document and track the lawful basis for each processing activity as required by NDPA 2023 Section 25.",className:te="",buttonClassName:m="",showSummary:re=true,showComplianceGaps:ie=true,classNames:r,unstyled:o})=>{let[h,v]=useState("list"),[a$3,w]=useState(q),[f,I]=useState(null),[J,ae]=useState(null),[A,ne]=useState("all"),[B,oe]=useState("all"),[S,de]=useState(""),[g,k]=useState([]),V=useMemo(()=>{let e=[...c$1];if(A!=="all"&&(e=e.filter(l=>l.status===A)),B!=="all"&&(e=e.filter(l=>l.lawfulBasis===B)),S){let l=S.toLowerCase();e=e.filter(u=>u.name.toLowerCase().includes(l)||u.description.toLowerCase().includes(l)||u.purposes.some(N=>N.toLowerCase().includes(l)));}return e.sort((l,u)=>u.updatedAt-l.updatedAt),e},[c$1,A,B,S]),C=useCallback(e=>new Date(e).toLocaleDateString(),[]),P=useMemo(()=>d(c$1),[c$1]),x=useMemo(()=>c(c$1),[c$1]),D=useCallback(e=>e.split(",").map(l=>l.trim()).filter(l=>l.length>0),[]),le=useCallback(()=>{w(q),I(null),k([]),v("form");},[]),M=useCallback(e=>{w({name:e.name,description:e.description,lawfulBasis:e.lawfulBasis,lawfulBasisJustification:e.lawfulBasisJustification,dataCategories:e.dataCategories.join(", "),involvesSensitiveData:e.involvesSensitiveData,sensitiveDataCondition:e.sensitiveDataCondition||"",dataSubjectCategories:e.dataSubjectCategories.join(", "),purposes:e.purposes.join(", "),retentionPeriod:e.retentionPeriod,retentionJustification:e.retentionJustification||"",recipients:(e.recipients||[]).join(", "),crossBorderTransfer:e.crossBorderTransfer,reviewDate:e.reviewDate?new Date(e.reviewDate).toISOString().split("T")[0]:"",liaPurposeTest:"",liaNecessityTest:"",liaBalancingTest:"",liaSafeguards:"",liaConclusion:""}),I(e.id),k([]),v("form");},[]),se=useCallback(()=>{let e={name:a$3.name,description:a$3.description,lawfulBasis:a$3.lawfulBasis,lawfulBasisJustification:a$3.lawfulBasisJustification,dataCategories:D(a$3.dataCategories),involvesSensitiveData:a$3.involvesSensitiveData,sensitiveDataCondition:a$3.sensitiveDataCondition||void 0,dataSubjectCategories:D(a$3.dataSubjectCategories),purposes:D(a$3.purposes),retentionPeriod:a$3.retentionPeriod,retentionJustification:a$3.retentionJustification||void 0,recipients:a$3.recipients?D(a$3.recipients):void 0,crossBorderTransfer:a$3.crossBorderTransfer,reviewDate:a$3.reviewDate?new Date(a$3.reviewDate).getTime():void 0,status:"active"},l=b(a({},e),{id:f||"temp",createdAt:Date.now(),updatedAt:Date.now()}),u=a$1(l);if(!u.isValid){k(u.errors);return}f&&_?_(f,e):F&&F(e),w(q),I(null),k([]),v("list");},[a$3,f,_,F,D]),G=useCallback(e=>{j&&j(e);},[j]),ue=useCallback(e=>{ae(e),v("detail");},[]),n=useMemo(()=>J?c$1.find(e=>e.id===J):null,[c$1,J]),H=useCallback(e=>{let l={active:"bg-green-100 text-green-800 dark:bg-green-900 dark:text-green-200",inactive:"bg-gray-100 text-gray-800 dark:bg-gray-900 dark:text-gray-200",under_review:"bg-yellow-100 text-yellow-800 dark:bg-yellow-900 dark:text-yellow-200",archived:"bg-red-100 text-red-800 dark:bg-red-900 dark:text-red-200"},u={active:"Active",inactive:"Inactive",under_review:"Under Review",archived:"Archived"};return jsx("span",{className:a$2(`px-2 py-1 rounded text-xs font-medium ${l[e]}`,r==null?void 0:r.statusBadge,o),children:u[e]})},[r==null?void 0:r.statusBadge,o]),U=useCallback(e=>{let l={consent:"bg-blue-100 text-blue-800 dark:bg-blue-900 dark:text-blue-200",contract:"bg-teal-100 text-teal-800 dark:bg-teal-900 dark:text-teal-200",legal_obligation:"bg-purple-100 text-purple-800 dark:bg-purple-900 dark:text-purple-200",vital_interests:"bg-red-100 text-red-800 dark:bg-red-900 dark:text-red-200",public_interest:"bg-orange-100 text-orange-800 dark:bg-orange-900 dark:text-orange-200",legitimate_interests:"bg-indigo-100 text-indigo-800 dark:bg-indigo-900 dark:text-indigo-200"},u={consent:"Consent",contract:"Contract",legal_obligation:"Legal Obligation",vital_interests:"Vital Interests",public_interest:"Public Interest",legitimate_interests:"Legitimate Interests"};return jsx("span",{className:`px-2 py-1 rounded text-xs font-medium ${l[e]}`,children:u[e]})},[]),Y=useCallback(e=>e.dpoApproval?e.dpoApproval.approved?jsx("span",{className:"px-2 py-1 rounded text-xs font-medium bg-green-100 text-green-800 dark:bg-green-900 dark:text-green-200",children:"Approved"}):jsx("span",{className:"px-2 py-1 rounded text-xs font-medium bg-yellow-100 text-yellow-800 dark:bg-yellow-900 dark:text-yellow-200",children:"Pending Approval"}):jsx("span",{className:"px-2 py-1 rounded text-xs font-medium bg-gray-100 text-gray-600 dark:bg-gray-700 dark:text-gray-400",children:"No DPO Review"}),[]),pe=()=>jsxs("div",{className:a$2("grid grid-cols-2 md:grid-cols-4 gap-4 mb-6",r==null?void 0:r.summary,o),role:"status","aria-label":"Compliance summary",children:[jsxs("div",{className:a$2("bg-blue-50 dark:bg-blue-900/20 p-4 rounded-lg",r==null?void 0:r.summaryCard,o),children:[jsx("p",{className:"text-2xl font-bold text-blue-800 dark:text-blue-200",children:P.totalActivities}),jsx("p",{className:"text-sm text-blue-600 dark:text-blue-300",children:"Total Activities"})]}),jsxs("div",{className:a$2("bg-orange-50 dark:bg-orange-900/20 p-4 rounded-lg",r==null?void 0:r.summaryCard,o),children:[jsx("p",{className:"text-2xl font-bold text-orange-800 dark:text-orange-200",children:P.sensitiveDataActivities}),jsx("p",{className:"text-sm text-orange-600 dark:text-orange-300",children:"Sensitive Data"})]}),jsxs("div",{className:a$2("bg-purple-50 dark:bg-purple-900/20 p-4 rounded-lg",r==null?void 0:r.summaryCard,o),children:[jsx("p",{className:"text-2xl font-bold text-purple-800 dark:text-purple-200",children:P.crossBorderActivities}),jsx("p",{className:"text-sm text-purple-600 dark:text-purple-300",children:"Cross-Border Transfers"})]}),jsxs("div",{className:a$2("bg-red-50 dark:bg-red-900/20 p-4 rounded-lg",r==null?void 0:r.summaryCard,o),children:[jsx("p",{className:"text-2xl font-bold text-red-800 dark:text-red-200",children:P.activitiesWithoutApproval.length}),jsx("p",{className:"text-sm text-red-600 dark:text-red-300",children:"Pending Approval"})]})]}),R=useMemo(()=>x.filter(e=>e.severity==="high"),[x]),E=useMemo(()=>x.filter(e=>e.severity==="medium"),[x]),ge=()=>x.length===0?jsxs("div",{className:"bg-green-50 dark:bg-green-900/20 p-4 rounded-lg mb-6",role:"status","aria-label":"No compliance gaps",children:[jsx("p",{className:"text-sm text-green-800 dark:text-green-200 font-medium",children:"No compliance gaps detected."}),jsx("p",{className:"text-xs text-green-700 dark:text-green-300 mt-1",children:"All processing activities appear to be properly documented."})]}):jsxs("div",{className:"mb-6",role:"status","aria-label":`${x.length} compliance gaps detected`,children:[R.length>0&&jsxs("div",{className:a$2("bg-red-50 dark:bg-red-900/20 p-4 rounded-lg mb-3",r==null?void 0:r.gapAlert,o),children:[jsxs("p",{className:"text-sm text-red-800 dark:text-red-200 font-medium mb-2",children:["High Priority (",R.length,")"]}),jsx("ul",{className:"space-y-1",children:R.map((e,l)=>jsx("li",{className:"text-xs text-red-700 dark:text-red-300",children:e.description},l))})]}),E.length>0&&jsxs("div",{className:a$2("bg-yellow-50 dark:bg-yellow-900/20 p-4 rounded-lg",r==null?void 0:r.gapAlert,o),children:[jsxs("p",{className:"text-sm text-yellow-800 dark:text-yellow-200 font-medium mb-2",children:["Medium Priority (",E.length,")"]}),jsx("ul",{className:"space-y-1",children:E.map((e,l)=>jsx("li",{className:"text-xs text-yellow-700 dark:text-yellow-300",children:e.description},l))})]})]}),W=useCallback(()=>{v("list"),k([]);},[]),ce=useCallback(()=>{v("list");},[]),s=useCallback((e,l)=>{w(u=>b(a({},u),{[e]:l}));},[]),be=useCallback(e=>{w(l=>b(a({},l),{involvesSensitiveData:e,sensitiveDataCondition:e?l.sensitiveDataCondition:""}));},[]),me=()=>jsxs("div",{className:a$2("",r==null?void 0:r.form,o),children:[jsxs("div",{className:a$2("flex justify-between items-center mb-4",r==null?void 0:r.header,o),children:[jsx("h3",{className:"text-lg font-medium",children:f?"Edit Processing Activity":"New Processing Activity"}),jsx("button",{onClick:W,className:`px-4 py-2 text-gray-600 dark:text-gray-300 bg-gray-100 dark:bg-gray-700 rounded hover:bg-gray-200 dark:hover:bg-gray-600 ${m}`,children:"Cancel"})]}),g.length>0&&jsxs("div",{id:"form-errors",className:"bg-red-50 dark:bg-red-900/20 p-4 rounded-lg mb-4",role:"alert",children:[jsx("p",{className:"text-sm text-red-800 dark:text-red-200 font-medium mb-2",children:"Please correct the following errors:"}),jsx("ul",{className:"list-disc list-inside space-y-1",children:g.map((e,l)=>jsx("li",{className:"text-xs text-red-700 dark:text-red-300",children:e},l))})]}),jsxs("div",{className:"space-y-4",children:[jsxs("div",{children:[jsx("label",{htmlFor:"activityName",className:"block text-sm font-medium mb-1",children:"Activity Name *"}),jsx("input",{type:"text",id:"activityName",value:a$3.name,onChange:e=>s("name",e.target.value),placeholder:"e.g., Customer Account Management","aria-required":"true","aria-describedby":g.length>0?"form-errors":void 0,className:a$2("w-full px-3 py-2 border border-gray-300 dark:border-gray-600 rounded-md focus:outline-none focus:ring-2 focus:ring-[rgb(var(--ndpr-ring))]",r==null?void 0:r.input,o)})]}),jsxs("div",{children:[jsx("label",{htmlFor:"activityDescription",className:"block text-sm font-medium mb-1",children:"Description *"}),jsx("textarea",{id:"activityDescription",value:a$3.description,onChange:e=>s("description",e.target.value),placeholder:"Describe what processing is performed...",rows:3,"aria-required":"true","aria-describedby":g.length>0?"form-errors":void 0,className:a$2("w-full px-3 py-2 border border-gray-300 dark:border-gray-600 rounded-md focus:outline-none focus:ring-2 focus:ring-[rgb(var(--ndpr-ring))]",r==null?void 0:r.input,o)})]}),jsxs("div",{children:[jsx("label",{htmlFor:"lawfulBasis",className:"block text-sm font-medium mb-1",children:"Lawful Basis (NDPA Section 25) *"}),jsx("select",{id:"lawfulBasis",value:a$3.lawfulBasis,onChange:e=>s("lawfulBasis",e.target.value),"aria-required":"true",className:a$2("w-full px-3 py-2 border border-gray-300 dark:border-gray-600 rounded-md focus:outline-none focus:ring-2 focus:ring-[rgb(var(--ndpr-ring))]",r==null?void 0:r.select,o),children:Q.map(e=>jsx("option",{value:e.value,children:e.label},e.value))}),jsx("p",{className:"mt-1 text-xs text-gray-600 dark:text-gray-400",children:b$1(a$3.lawfulBasis)})]}),jsxs("div",{children:[jsx("label",{htmlFor:"justification",className:"block text-sm font-medium mb-1",children:"Lawful Basis Justification *"}),jsx("textarea",{id:"justification",value:a$3.lawfulBasisJustification,onChange:e=>s("lawfulBasisJustification",e.target.value),placeholder:"Document why this lawful basis applies to this processing activity...",rows:3,"aria-required":"true","aria-describedby":g.length>0?"form-errors":void 0,className:a$2("w-full px-3 py-2 border border-gray-300 dark:border-gray-600 rounded-md focus:outline-none focus:ring-2 focus:ring-[rgb(var(--ndpr-ring))]",r==null?void 0:r.input,o)})]}),a$3.lawfulBasis==="legitimate_interests"&&jsxs("div",{className:"border border-indigo-200 dark:border-indigo-800 rounded-lg p-4 bg-indigo-50 dark:bg-indigo-900/20",children:[jsx("h4",{className:"text-sm font-semibold text-indigo-800 dark:text-indigo-200 mb-3",children:"Legitimate Interest Assessment (LIA)"}),jsx("p",{className:"text-xs text-indigo-600 dark:text-indigo-300 mb-4",children:"NDPA Section 25(1)(f) requires a balancing test when relying on legitimate interests."}),jsxs("div",{className:"space-y-3",children:[jsxs("div",{children:[jsx("label",{htmlFor:"liaPurpose",className:"block text-sm font-medium mb-1",children:"Purpose Test"}),jsx("textarea",{id:"liaPurpose",value:a$3.liaPurposeTest,onChange:e=>s("liaPurposeTest",e.target.value),placeholder:"Describe the legitimate interest being pursued...",rows:2,className:a$2("w-full px-3 py-2 border border-gray-300 dark:border-gray-600 rounded-md focus:outline-none focus:ring-2 focus:ring-[rgb(var(--ndpr-ring))]",r==null?void 0:r.input,o)})]}),jsxs("div",{children:[jsx("label",{htmlFor:"liaNecessity",className:"block text-sm font-medium mb-1",children:"Necessity Test"}),jsx("textarea",{id:"liaNecessity",value:a$3.liaNecessityTest,onChange:e=>s("liaNecessityTest",e.target.value),placeholder:"Explain why this processing is necessary for the stated purpose...",rows:2,className:a$2("w-full px-3 py-2 border border-gray-300 dark:border-gray-600 rounded-md focus:outline-none focus:ring-2 focus:ring-[rgb(var(--ndpr-ring))]",r==null?void 0:r.input,o)})]}),jsxs("div",{children:[jsx("label",{htmlFor:"liaBalancing",className:"block text-sm font-medium mb-1",children:"Balancing Test"}),jsx("textarea",{id:"liaBalancing",value:a$3.liaBalancingTest,onChange:e=>s("liaBalancingTest",e.target.value),placeholder:"Assess the impact on data subjects' rights and interests...",rows:2,className:a$2("w-full px-3 py-2 border border-gray-300 dark:border-gray-600 rounded-md focus:outline-none focus:ring-2 focus:ring-[rgb(var(--ndpr-ring))]",r==null?void 0:r.input,o)})]}),jsxs("div",{children:[jsx("label",{htmlFor:"liaSafeguards",className:"block text-sm font-medium mb-1",children:"Safeguards"}),jsx("input",{type:"text",id:"liaSafeguards",value:a$3.liaSafeguards,onChange:e=>s("liaSafeguards",e.target.value),placeholder:"List safeguards (comma-separated)...",className:a$2("w-full px-3 py-2 border border-gray-300 dark:border-gray-600 rounded-md focus:outline-none focus:ring-2 focus:ring-[rgb(var(--ndpr-ring))]",r==null?void 0:r.input,o)})]}),jsxs("div",{children:[jsx("label",{htmlFor:"liaConclusion",className:"block text-sm font-medium mb-1",children:"Conclusion"}),jsx("textarea",{id:"liaConclusion",value:a$3.liaConclusion,onChange:e=>s("liaConclusion",e.target.value),placeholder:"State your overall conclusion...",rows:2,className:a$2("w-full px-3 py-2 border border-gray-300 dark:border-gray-600 rounded-md focus:outline-none focus:ring-2 focus:ring-[rgb(var(--ndpr-ring))]",r==null?void 0:r.input,o)})]})]})]}),jsxs("div",{children:[jsx("label",{htmlFor:"dataCategories",className:"block text-sm font-medium mb-1",children:"Data Categories *"}),jsx("input",{type:"text",id:"dataCategories",value:a$3.dataCategories,onChange:e=>s("dataCategories",e.target.value),placeholder:"e.g., Name, Email, Phone Number (comma-separated)","aria-required":"true","aria-describedby":g.length>0?"form-errors":void 0,className:a$2("w-full px-3 py-2 border border-gray-300 dark:border-gray-600 rounded-md focus:outline-none focus:ring-2 focus:ring-[rgb(var(--ndpr-ring))]",r==null?void 0:r.input,o)})]}),jsx("div",{children:jsxs("label",{className:"flex items-center space-x-2",children:[jsx("input",{type:"checkbox",checked:a$3.involvesSensitiveData,onChange:e=>be(e.target.checked),className:"rounded border-gray-300 dark:border-gray-600 text-[rgb(var(--ndpr-primary))] focus:ring-[rgb(var(--ndpr-ring))]"}),jsx("span",{className:"text-sm font-medium",children:"Involves Sensitive Personal Data (NDPA Section 27)"})]})}),a$3.involvesSensitiveData&&jsxs("div",{children:[jsx("label",{htmlFor:"sensitiveCondition",className:"block text-sm font-medium mb-1",children:"Sensitive Data Condition (NDPA Section 27) *"}),jsxs("select",{id:"sensitiveCondition",value:a$3.sensitiveDataCondition,onChange:e=>s("sensitiveDataCondition",e.target.value),"aria-required":"true",className:a$2("w-full px-3 py-2 border border-gray-300 dark:border-gray-600 rounded-md focus:outline-none focus:ring-2 focus:ring-[rgb(var(--ndpr-ring))]",r==null?void 0:r.select,o),children:[jsx("option",{value:"",children:"Select a condition..."}),X.map(e=>jsx("option",{value:e.value,children:e.label},e.value))]})]}),jsxs("div",{children:[jsx("label",{htmlFor:"dataSubjectCategories",className:"block text-sm font-medium mb-1",children:"Data Subject Categories *"}),jsx("input",{type:"text",id:"dataSubjectCategories",value:a$3.dataSubjectCategories,onChange:e=>s("dataSubjectCategories",e.target.value),placeholder:"e.g., Customers, Employees, Vendors (comma-separated)","aria-required":"true","aria-describedby":g.length>0?"form-errors":void 0,className:a$2("w-full px-3 py-2 border border-gray-300 dark:border-gray-600 rounded-md focus:outline-none focus:ring-2 focus:ring-[rgb(var(--ndpr-ring))]",r==null?void 0:r.input,o)})]}),jsxs("div",{children:[jsx("label",{htmlFor:"purposes",className:"block text-sm font-medium mb-1",children:"Processing Purposes *"}),jsx("input",{type:"text",id:"purposes",value:a$3.purposes,onChange:e=>s("purposes",e.target.value),placeholder:"e.g., Account management, Service delivery (comma-separated)","aria-required":"true","aria-describedby":g.length>0?"form-errors":void 0,className:a$2("w-full px-3 py-2 border border-gray-300 dark:border-gray-600 rounded-md focus:outline-none focus:ring-2 focus:ring-[rgb(var(--ndpr-ring))]",r==null?void 0:r.input,o)})]}),jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4",children:[jsxs("div",{children:[jsx("label",{htmlFor:"retentionPeriod",className:"block text-sm font-medium mb-1",children:"Retention Period *"}),jsx("input",{type:"text",id:"retentionPeriod",value:a$3.retentionPeriod,onChange:e=>s("retentionPeriod",e.target.value),placeholder:"e.g., 3 years after account closure","aria-required":"true","aria-describedby":g.length>0?"form-errors":void 0,className:a$2("w-full px-3 py-2 border border-gray-300 dark:border-gray-600 rounded-md focus:outline-none focus:ring-2 focus:ring-[rgb(var(--ndpr-ring))]",r==null?void 0:r.input,o)})]}),jsxs("div",{children:[jsx("label",{htmlFor:"retentionJustification",className:"block text-sm font-medium mb-1",children:"Retention Justification"}),jsx("input",{type:"text",id:"retentionJustification",value:a$3.retentionJustification,onChange:e=>s("retentionJustification",e.target.value),placeholder:"Reason for the retention period",className:a$2("w-full px-3 py-2 border border-gray-300 dark:border-gray-600 rounded-md focus:outline-none focus:ring-2 focus:ring-[rgb(var(--ndpr-ring))]",r==null?void 0:r.input,o)})]})]}),jsxs("div",{children:[jsx("label",{htmlFor:"recipients",className:"block text-sm font-medium mb-1",children:"Recipients"}),jsx("input",{type:"text",id:"recipients",value:a$3.recipients,onChange:e=>s("recipients",e.target.value),placeholder:"e.g., Payment processor, Cloud provider (comma-separated)",className:a$2("w-full px-3 py-2 border border-gray-300 dark:border-gray-600 rounded-md focus:outline-none focus:ring-2 focus:ring-[rgb(var(--ndpr-ring))]",r==null?void 0:r.input,o)})]}),jsx("div",{children:jsxs("label",{className:"flex items-center space-x-2",children:[jsx("input",{type:"checkbox",checked:a$3.crossBorderTransfer,onChange:e=>s("crossBorderTransfer",e.target.checked),className:"rounded border-gray-300 dark:border-gray-600 text-[rgb(var(--ndpr-primary))] focus:ring-[rgb(var(--ndpr-ring))]"}),jsx("span",{className:"text-sm font-medium",children:"Involves Cross-Border Transfer Outside Nigeria"})]})}),jsxs("div",{children:[jsx("label",{htmlFor:"reviewDate",className:"block text-sm font-medium mb-1",children:"Next Review Date"}),jsx("input",{type:"date",id:"reviewDate",value:a$3.reviewDate,onChange:e=>s("reviewDate",e.target.value),className:a$2("w-full px-3 py-2 border border-gray-300 dark:border-gray-600 rounded-md focus:outline-none focus:ring-2 focus:ring-[rgb(var(--ndpr-ring))]",r==null?void 0:r.input,o)})]}),jsxs("div",{className:"flex justify-end space-x-3 pt-4",children:[jsx("button",{onClick:W,className:`px-4 py-2 text-gray-600 dark:text-gray-300 bg-gray-100 dark:bg-gray-700 rounded hover:bg-gray-200 dark:hover:bg-gray-600 ${m}`,children:"Cancel"}),jsx("button",{onClick:se,className:a$2(`px-4 py-2 bg-[rgb(var(--ndpr-primary))] text-white rounded hover:bg-[rgb(var(--ndpr-primary-hover))] ${m}`,(r==null?void 0:r.primaryButton)||(r==null?void 0:r.submitButton),o),children:f?"Update Activity":"Create Activity"})]})]})]}),ve=()=>{var l;if(!n)return jsx("div",{className:"flex items-center justify-center h-64 bg-gray-50 dark:bg-gray-700 rounded-md",children:jsx("p",{className:"text-gray-600 dark:text-gray-400",children:"Activity not found."})});let e=a$1(n);return jsxs("div",{children:[jsxs("div",{className:"flex justify-between items-start mb-4",children:[jsxs("div",{children:[jsx("button",{onClick:ce,className:"text-sm text-[rgb(var(--ndpr-primary))] dark:text-[rgb(var(--ndpr-primary))] hover:underline mb-2","aria-label":"Back to activities list",children:"Back to list"}),jsx("h3",{className:"text-lg font-medium",children:n.name})]}),jsxs("div",{className:"flex space-x-2",children:[U(n.lawfulBasis),H(n.status),Y(n)]})]}),e.warnings.length>0&&jsxs("div",{className:"bg-yellow-50 dark:bg-yellow-900/20 p-3 rounded-md mb-4",children:[jsx("p",{className:"text-sm text-yellow-800 dark:text-yellow-200 font-medium mb-1",children:"Warnings"}),jsx("ul",{className:"list-disc list-inside space-y-1",children:e.warnings.map((u,N)=>jsx("li",{className:"text-xs text-yellow-700 dark:text-yellow-300",children:u},N))})]}),jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4 mb-6",children:[jsxs("div",{children:[jsxs("p",{className:"text-sm",children:[jsx("span",{className:"font-medium",children:"Description:"})," ",n.description]}),jsxs("p",{className:"text-sm mt-2",children:[jsx("span",{className:"font-medium",children:"Lawful Basis:"})," ",b$1(n.lawfulBasis)]}),jsxs("p",{className:"text-sm mt-2",children:[jsx("span",{className:"font-medium",children:"Justification:"})," ",n.lawfulBasisJustification]})]}),jsxs("div",{children:[jsxs("p",{className:"text-sm",children:[jsx("span",{className:"font-medium",children:"Data Categories:"})," ",n.dataCategories.join(", ")]}),jsxs("p",{className:"text-sm mt-2",children:[jsx("span",{className:"font-medium",children:"Data Subject Categories:"})," ",n.dataSubjectCategories.join(", ")]}),jsxs("p",{className:"text-sm mt-2",children:[jsx("span",{className:"font-medium",children:"Purposes:"})," ",n.purposes.join(", ")]}),jsxs("p",{className:"text-sm mt-2",children:[jsx("span",{className:"font-medium",children:"Retention Period:"})," ",n.retentionPeriod,n.retentionJustification&&jsxs("span",{className:"text-gray-600 dark:text-gray-400",children:[" ","(",n.retentionJustification,")"]})]})]})]}),jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4 mb-6",children:[jsxs("div",{children:[jsxs("p",{className:"text-sm",children:[jsx("span",{className:"font-medium",children:"Sensitive Data:"})," ",n.involvesSensitiveData?"Yes":"No",n.sensitiveDataCondition&&jsxs("span",{children:[" ","(Condition:"," ",((l=X.find(u=>u.value===n.sensitiveDataCondition))==null?void 0:l.label)||n.sensitiveDataCondition,")"]})]}),jsxs("p",{className:"text-sm mt-2",children:[jsx("span",{className:"font-medium",children:"Cross-Border Transfer:"})," ",n.crossBorderTransfer?"Yes":"No"]}),n.recipients&&n.recipients.length>0&&jsxs("p",{className:"text-sm mt-2",children:[jsx("span",{className:"font-medium",children:"Recipients:"})," ",n.recipients.join(", ")]})]}),jsxs("div",{children:[jsxs("p",{className:"text-sm",children:[jsx("span",{className:"font-medium",children:"Created:"})," ",C(n.createdAt)]}),jsxs("p",{className:"text-sm mt-2",children:[jsx("span",{className:"font-medium",children:"Last Updated:"})," ",C(n.updatedAt)]}),n.reviewDate&&jsxs("p",{className:"text-sm mt-2",children:[jsx("span",{className:"font-medium",children:"Next Review:"})," ",C(n.reviewDate),n.reviewDate<Date.now()&&jsx("span",{className:"text-red-600 dark:text-red-400 font-medium",children:" (Overdue)"})]})]})]}),n.dpoApproval&&jsxs("div",{className:"bg-gray-50 dark:bg-gray-700 p-4 rounded-md mb-6",children:[jsx("h4",{className:"text-sm font-semibold mb-2",children:"DPO Approval"}),jsxs("p",{className:"text-sm",children:[jsx("span",{className:"font-medium",children:"Status:"})," ",n.dpoApproval.approved?"Approved":"Not Approved"]}),jsxs("p",{className:"text-sm mt-1",children:[jsx("span",{className:"font-medium",children:"Approved By:"})," ",n.dpoApproval.approvedBy]}),jsxs("p",{className:"text-sm mt-1",children:[jsx("span",{className:"font-medium",children:"Date:"})," ",C(n.dpoApproval.approvedAt)]}),n.dpoApproval.notes&&jsxs("p",{className:"text-sm mt-1",children:[jsx("span",{className:"font-medium",children:"Notes:"})," ",n.dpoApproval.notes]})]}),jsxs("div",{className:"flex space-x-3",children:[jsx("button",{onClick:()=>M(n),"aria-label":`Edit ${n.name}`,className:`px-4 py-2 bg-[rgb(var(--ndpr-primary))] text-white rounded hover:bg-[rgb(var(--ndpr-primary-hover))] ${m}`,children:"Edit"}),n.status!=="archived"&&jsx("button",{onClick:()=>G(n.id),"aria-label":`Archive ${n.name}`,className:`px-4 py-2 bg-gray-600 text-white rounded hover:bg-gray-700 ${m}`,children:"Archive"})]})]})},fe=()=>jsxs("div",{children:[jsxs("div",{className:"mb-6 grid grid-cols-1 md:grid-cols-4 gap-4",children:[jsxs("div",{children:[jsx("label",{htmlFor:"basisFilter",className:"block text-sm font-medium mb-1",children:"Lawful Basis"}),jsxs("select",{id:"basisFilter",value:B,onChange:e=>oe(e.target.value),"aria-label":"Filter by lawful basis",className:a$2("w-full px-3 py-2 border border-gray-300 dark:border-gray-600 rounded-md focus:outline-none focus:ring-2 focus:ring-[rgb(var(--ndpr-ring))]",r==null?void 0:r.select,o),children:[jsx("option",{value:"all",children:"All Bases"}),Q.map(e=>jsx("option",{value:e.value,children:e.label},e.value))]})]}),jsxs("div",{children:[jsx("label",{htmlFor:"statusFilterSelect",className:"block text-sm font-medium mb-1",children:"Status"}),jsxs("select",{id:"statusFilterSelect",value:A,onChange:e=>ne(e.target.value),"aria-label":"Filter by status",className:a$2("w-full px-3 py-2 border border-gray-300 dark:border-gray-600 rounded-md focus:outline-none focus:ring-2 focus:ring-[rgb(var(--ndpr-ring))]",r==null?void 0:r.select,o),children:[jsx("option",{value:"all",children:"All Statuses"}),jsx("option",{value:"active",children:"Active"}),jsx("option",{value:"inactive",children:"Inactive"}),jsx("option",{value:"under_review",children:"Under Review"}),jsx("option",{value:"archived",children:"Archived"})]})]}),jsxs("div",{children:[jsx("label",{htmlFor:"searchInput",className:"block text-sm font-medium mb-1",children:"Search"}),jsx("input",{type:"text",id:"searchInput",value:S,onChange:e=>de(e.target.value),placeholder:"Search activities...",className:a$2("w-full px-3 py-2 border border-gray-300 dark:border-gray-600 rounded-md focus:outline-none focus:ring-2 focus:ring-[rgb(var(--ndpr-ring))]",r==null?void 0:r.input,o)})]}),jsx("div",{className:"flex items-end",children:jsx("button",{onClick:le,className:a$2(`w-full px-4 py-2 bg-[rgb(var(--ndpr-primary))] text-white rounded hover:bg-[rgb(var(--ndpr-primary-hover))] ${m}`,(r==null?void 0:r.primaryButton)||(r==null?void 0:r.submitButton),o),children:"Add Activity"})})]}),V.length===0?jsx("div",{className:"flex items-center justify-center h-32 bg-gray-50 dark:bg-gray-700 rounded-md",children:jsx("p",{className:"text-gray-600 dark:text-gray-400 text-sm",children:"No processing activities found."})}):jsx("div",{className:"overflow-x-auto",children:jsxs("table",{className:a$2("w-full text-sm text-left",r==null?void 0:r.table,o),children:[jsx("thead",{className:a$2("text-xs uppercase bg-gray-50 dark:bg-gray-700",r==null?void 0:r.tableHeader,o),children:jsxs("tr",{children:[jsx("th",{className:"px-4 py-3",children:"Activity"}),jsx("th",{className:"px-4 py-3",children:"Lawful Basis"}),jsx("th",{className:"px-4 py-3",children:"Status"}),jsx("th",{className:"px-4 py-3",children:"DPO Approval"}),jsx("th",{className:"px-4 py-3",children:"Sensitive Data"}),jsx("th",{className:"px-4 py-3",children:"Last Updated"}),jsx("th",{className:"px-4 py-3",children:"Actions"})]})}),jsx("tbody",{children:V.map(e=>jsxs("tr",{className:a$2("border-b border-gray-200 dark:border-gray-600 hover:bg-gray-50 dark:hover:bg-gray-700",r==null?void 0:r.tableRow,o),children:[jsxs("td",{className:"px-4 py-3",children:[jsx("button",{onClick:()=>ue(e.id),className:"font-medium text-[rgb(var(--ndpr-primary))] dark:text-[rgb(var(--ndpr-primary))] hover:underline text-left",children:e.name}),jsx("p",{className:"text-xs text-gray-600 dark:text-gray-400 mt-1 truncate max-w-xs",children:e.description})]}),jsx("td",{className:"px-4 py-3",children:U(e.lawfulBasis)}),jsx("td",{className:"px-4 py-3",children:H(e.status)}),jsx("td",{className:"px-4 py-3",children:Y(e)}),jsx("td",{className:"px-4 py-3",children:jsx("span",{className:`text-xs ${e.involvesSensitiveData?"text-orange-600 dark:text-orange-400 font-medium":"text-gray-600 dark:text-gray-400"}`,children:e.involvesSensitiveData?"Yes":"No"})}),jsx("td",{className:"px-4 py-3 text-xs text-gray-600 dark:text-gray-400",children:C(e.updatedAt)}),jsx("td",{className:"px-4 py-3",children:jsxs("div",{className:"flex space-x-2",children:[jsx("button",{onClick:()=>M(e),"aria-label":`Edit ${e.name}`,className:"text-xs text-[rgb(var(--ndpr-primary))] dark:text-[rgb(var(--ndpr-primary))] hover:underline",children:"Edit"}),e.status!=="archived"&&jsx("button",{onClick:()=>G(e.id),"aria-label":`Archive ${e.name}`,className:"text-xs text-gray-600 dark:text-gray-400 hover:underline",children:"Archive"})]})})]},e.id))})]})})]});return jsxs("div",{className:a$2(`bg-white dark:bg-gray-800 p-6 rounded-lg shadow-md ${te}`,r==null?void 0:r.root,o),children:[jsx("h2",{className:a$2("text-xl font-bold mb-2",r==null?void 0:r.title,o),children:Z}),jsx("p",{className:"mb-6 text-gray-600 dark:text-gray-300",children:ee}),re&&h==="list"&&pe(),ie&&h==="list"&&ge(),h==="list"&&fe(),h==="form"&&me(),h==="detail"&&ve()]})};export{Ce as a};//# sourceMappingURL=chunk-ZT7KNFAU.mjs.map
2
+ //# sourceMappingURL=chunk-ZT7KNFAU.mjs.map
@@ -0,0 +1,2 @@
1
+ 'use strict';var chunkJKKRPS4P_js=require('./chunk-JKKRPS4P.js'),chunkE64TU6IU_js=require('./chunk-E64TU6IU.js'),react=require('react'),jsxRuntime=require('react/jsx-runtime');var oe=({requests:w,onSelectRequest:P,onUpdateStatus:I,onAssignRequest:V,title:H="Data Subject Request Dashboard",description:X="Track and manage data subject requests in compliance with NDPA Part IV requirements.",className:J="",buttonClassName:F="",showRequestDetails:Y=true,showRequestTimeline:z=true,showDeadlineAlerts:B=true,assignees:i=[],classNames:l,unstyled:k=false})=>{let[y,f]=react.useState(null),[D,O]=react.useState(w),[j,M]=react.useState("all"),[C,T]=react.useState("all"),[A,_]=react.useState(""),[$,G]=react.useState("createdAt"),[U,Z]=react.useState("desc"),[S,Q]=react.useState("");react.useEffect(()=>{let e=[...w];if(j!=="all"&&(e=e.filter(r=>r.status===j)),C!=="all"&&(e=e.filter(r=>r.type===C)),A){let r=A.toLowerCase();e=e.filter(p=>p.subject.name.toLowerCase().includes(r)||p.subject.email.toLowerCase().includes(r)||p.description&&p.description.toLowerCase().includes(r));}e.sort((r,p)=>{let h=0;switch($){case "createdAt":h=r.createdAt-p.createdAt;break;case "dueDate":h=(r.dueDate||0)-(p.dueDate||0);break;case "type":h=r.type.localeCompare(p.type);break;case "status":h=r.status.localeCompare(p.status);break;default:h=r.createdAt-p.createdAt;}return U==="asc"?h:-h}),O(e);},[w,j,C,A,$,U]),react.useEffect(()=>{D.length>0&&(y&&D.some(r=>r.id===y)||f(D[0].id));},[D,y]);let E=e=>{f(e),P&&P(e);},L=e=>{y&&I&&I(y,e);},W=()=>{y&&S&&V&&(V(y,S),Q(""));},R=e=>new Date(e).toLocaleDateString(),q=e=>{let r=Date.now(),p=(e-r)/(1440*60*1e3);return Math.ceil(p)},m=y?w.find(e=>e.id===y):null,t=e=>{let r={information:"bg-teal-100 text-teal-800 dark:bg-teal-900 dark:text-teal-200",access:"bg-blue-100 text-blue-800 dark:bg-blue-900 dark:text-blue-200",rectification:"bg-green-100 text-green-800 dark:bg-green-900 dark:text-green-200",erasure:"bg-red-100 text-red-800 dark:bg-red-900 dark:text-red-200",restriction:"bg-yellow-100 text-yellow-800 dark:bg-yellow-900 dark:text-yellow-200",portability:"bg-purple-100 text-purple-800 dark:bg-purple-900 dark:text-purple-200",objection:"bg-orange-100 text-orange-800 dark:bg-orange-900 dark:text-orange-200",automated_decision_making:"bg-indigo-100 text-indigo-800 dark:bg-indigo-900 dark:text-indigo-200"},p={information:"Information",access:"Access",rectification:"Rectification",erasure:"Erasure",restriction:"Restriction",portability:"Portability",objection:"Objection",automated_decision_making:"Automated Decision-Making"};return jsxRuntime.jsx("span",{className:`px-2 py-1 rounded text-xs font-medium ${r[e]}`,children:p[e]})},s=e=>jsxRuntime.jsx("span",{className:chunkE64TU6IU_js.a(`px-2 py-1 rounded text-xs font-medium ${{pending:"bg-yellow-100 text-yellow-800 dark:bg-yellow-900 dark:text-yellow-200",inProgress:"bg-blue-100 text-blue-800 dark:bg-blue-900 dark:text-blue-200",completed:"bg-green-100 text-green-800 dark:bg-green-900 dark:text-green-200",rejected:"bg-red-100 text-red-800 dark:bg-red-900 dark:text-red-200",awaitingVerification:"bg-purple-100 text-purple-800 dark:bg-purple-900 dark:text-purple-200"}[e]}`,l==null?void 0:l.statusBadge,k),children:e==="inProgress"?"In Progress":e==="awaitingVerification"?"Awaiting Verification":e.charAt(0).toUpperCase()+e.slice(1)}),g=e=>{if(!e.dueDate)return null;let r=q(e.dueDate);return r<=0?jsxRuntime.jsxs("div",{className:"bg-red-50 dark:bg-red-900/20 p-3 rounded-md",role:"alert","aria-live":"polite",children:[jsxRuntime.jsx("p",{className:"text-sm text-red-800 dark:text-red-200 font-medium",children:"Deadline Passed"}),jsxRuntime.jsx("p",{className:"text-xs text-red-700 dark:text-red-300 mt-1",children:"The response deadline has passed. Immediate action is required."})]}):r<=3?jsxRuntime.jsxs("div",{className:"bg-red-50 dark:bg-red-900/20 p-3 rounded-md",role:"alert","aria-live":"polite",children:[jsxRuntime.jsx("p",{className:"text-sm text-red-800 dark:text-red-200 font-medium",children:"Urgent: Deadline Approaching"}),jsxRuntime.jsxs("p",{className:"text-xs text-red-700 dark:text-red-300 mt-1",children:["Only ",r," day",r!==1?"s":""," remaining until the response deadline."]})]}):r<=7?jsxRuntime.jsxs("div",{className:"bg-yellow-50 dark:bg-yellow-900/20 p-3 rounded-md","aria-live":"polite",children:[jsxRuntime.jsx("p",{className:"text-sm text-yellow-800 dark:text-yellow-200 font-medium",children:"Deadline Approaching"}),jsxRuntime.jsxs("p",{className:"text-xs text-yellow-700 dark:text-yellow-300 mt-1",children:[r," days remaining until the response deadline."]})]}):jsxRuntime.jsxs("div",{className:"bg-green-50 dark:bg-green-900/20 p-3 rounded-md","aria-live":"polite",children:[jsxRuntime.jsx("p",{className:"text-sm text-green-800 dark:text-green-200 font-medium",children:"Deadline Tracking"}),jsxRuntime.jsxs("p",{className:"text-xs text-green-700 dark:text-green-300 mt-1",children:[r," days remaining until the response deadline."]})]})},x=e=>{let r=[{title:"Request Received",date:e.createdAt,completed:true,description:`Request was received on ${R(e.createdAt)}.`}];return e.verifiedAt?r.push({title:"Identity Verified",date:e.verifiedAt,completed:true,description:`Data subject's identity was verified on ${R(e.verifiedAt)}.`}):e.status==="awaitingVerification"&&r.push({title:"Identity Verification",date:Date.now(),completed:false,description:"Awaiting verification of data subject's identity."}),(e.status==="inProgress"||e.status==="completed"||e.status==="rejected")&&r.push({title:"Processing Started",date:e.updatedAt,completed:true,description:`Request processing started on ${R(e.updatedAt)}.`}),e.status==="completed"?r.push({title:"Request Completed",date:e.completedAt||Date.now(),completed:true,description:`Request was completed on ${R(e.completedAt||Date.now())}.`}):e.status==="rejected"&&r.push({title:"Request Rejected",date:e.completedAt||Date.now(),completed:true,description:`Request was rejected on ${R(e.completedAt||Date.now())}.${e.rejectionReason?` Reason: ${e.rejectionReason}`:""}`}),e.dueDate&&r.push({title:"Response Deadline",date:e.dueDate,completed:Date.now()>e.dueDate,description:`Response is due by ${R(e.dueDate)}.`}),jsxRuntime.jsxs("div",{className:"mt-6",children:[jsxRuntime.jsx("h3",{className:"text-lg font-medium mb-4",children:"Request Timeline"}),jsxRuntime.jsx("ol",{className:"relative border-l border-gray-200 dark:border-gray-700",children:r.map((p,h)=>jsxRuntime.jsxs("li",{className:"mb-6 ml-4",children:[jsxRuntime.jsx("div",{className:`absolute w-3 h-3 rounded-full mt-1.5 -left-1.5 border ${p.completed?"bg-green-500 border-green-500 dark:border-green-500":"bg-gray-200 border-gray-200 dark:bg-gray-700 dark:border-gray-700"}`}),jsxRuntime.jsx("time",{className:"mb-1 text-sm font-normal leading-none text-gray-600 dark:text-gray-500",children:p.date?R(p.date):"Pending"}),jsxRuntime.jsx("h4",{className:"text-sm font-semibold text-gray-900 dark:text-white",children:p.title}),jsxRuntime.jsx("p",{className:"text-xs text-gray-600 dark:text-gray-400",children:p.description})]},h))})]})},o=()=>[{value:"all",label:"All Types"},{value:"information",label:"Information (NDPA Section 29)"},{value:"access",label:"Access (NDPA Section 30)"},{value:"rectification",label:"Rectification (NDPA Section 31)"},{value:"erasure",label:"Erasure (NDPA Section 32)"},{value:"restriction",label:"Restriction (NDPA Section 33)"},{value:"portability",label:"Portability (NDPA Section 34)"},{value:"objection",label:"Objection (NDPA Section 35)"},{value:"automated_decision_making",label:"Automated Decision-Making (NDPA Section 36)"}].map(r=>jsxRuntime.jsx("option",{value:r.value,children:r.label},r.value)),u=()=>[{value:"all",label:"All Statuses"},{value:"pending",label:"Pending"},{value:"awaitingVerification",label:"Awaiting Verification"},{value:"inProgress",label:"In Progress"},{value:"completed",label:"Completed"},{value:"rejected",label:"Rejected"}].map(r=>jsxRuntime.jsx("option",{value:r.value,children:r.label},r.value)),v=()=>[{value:"pending",label:"Pending"},{value:"awaitingVerification",label:"Awaiting Verification"},{value:"inProgress",label:"In Progress"},{value:"completed",label:"Completed"},{value:"rejected",label:"Rejected"}].map(r=>jsxRuntime.jsx("option",{value:r.value,children:r.label},r.value));return jsxRuntime.jsxs("div",{className:chunkE64TU6IU_js.a(`bg-white dark:bg-gray-800 p-6 rounded-lg shadow-md ${J}`,l==null?void 0:l.root,k),children:[jsxRuntime.jsxs("div",{className:chunkE64TU6IU_js.a("",l==null?void 0:l.header,k),children:[jsxRuntime.jsx("h2",{className:chunkE64TU6IU_js.a("text-xl font-bold mb-2",l==null?void 0:l.title,k),children:H}),jsxRuntime.jsx("p",{className:"mb-6 text-gray-600 dark:text-gray-300",children:X})]}),jsxRuntime.jsxs("div",{className:chunkE64TU6IU_js.a("mb-6 grid grid-cols-1 md:grid-cols-4 gap-4",l==null?void 0:l.filters,k),children:[jsxRuntime.jsxs("div",{children:[jsxRuntime.jsx("label",{htmlFor:"statusFilter",className:"block text-sm font-medium mb-1",children:"Status Filter"}),jsxRuntime.jsx("select",{id:"statusFilter",value:j,onChange:e=>M(e.target.value),className:"w-full px-3 py-2 border border-gray-300 dark:border-gray-600 rounded-md focus:outline-none focus:ring-2 focus:ring-[rgb(var(--ndpr-ring))]",children:u()})]}),jsxRuntime.jsxs("div",{children:[jsxRuntime.jsx("label",{htmlFor:"typeFilter",className:"block text-sm font-medium mb-1",children:"Request Type Filter"}),jsxRuntime.jsx("select",{id:"typeFilter",value:C,onChange:e=>T(e.target.value),className:"w-full px-3 py-2 border border-gray-300 dark:border-gray-600 rounded-md focus:outline-none focus:ring-2 focus:ring-[rgb(var(--ndpr-ring))]",children:o()})]}),jsxRuntime.jsxs("div",{children:[jsxRuntime.jsx("label",{htmlFor:"sortBy",className:"block text-sm font-medium mb-1",children:"Sort By"}),jsxRuntime.jsxs("select",{id:"sortBy",value:$,onChange:e=>G(e.target.value),className:"w-full px-3 py-2 border border-gray-300 dark:border-gray-600 rounded-md focus:outline-none focus:ring-2 focus:ring-[rgb(var(--ndpr-ring))]",children:[jsxRuntime.jsx("option",{value:"createdAt",children:"Date Received"}),jsxRuntime.jsx("option",{value:"dueDate",children:"Due Date"}),jsxRuntime.jsx("option",{value:"type",children:"Request Type"}),jsxRuntime.jsx("option",{value:"status",children:"Status"})]})]}),jsxRuntime.jsxs("div",{children:[jsxRuntime.jsx("label",{htmlFor:"searchTerm",className:"block text-sm font-medium mb-1",children:"Search"}),jsxRuntime.jsx("input",{type:"text",id:"searchTerm",value:A,onChange:e=>_(e.target.value),placeholder:"Search requests...",className:"w-full px-3 py-2 border border-gray-300 dark:border-gray-600 rounded-md focus:outline-none focus:ring-2 focus:ring-[rgb(var(--ndpr-ring))]"})]})]}),jsxRuntime.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-3 gap-6",children:[jsxRuntime.jsxs("div",{className:"md:col-span-1",children:[jsxRuntime.jsx("h3",{className:"text-lg font-medium mb-3",children:"DSR Requests"}),D.length===0?jsxRuntime.jsx("p",{className:"text-gray-600 dark:text-gray-400 text-sm",children:"No data subject requests found."}):jsxRuntime.jsx("div",{className:chunkE64TU6IU_js.a("space-y-2 max-h-96 overflow-y-auto pr-2",l==null?void 0:l.requestList,k),children:D.map(e=>{let r=e.dueDate?q(e.dueDate):null,p=null;return r!==null&&(r<=0?p=jsxRuntime.jsx("span",{className:"text-xs text-red-600 dark:text-red-400 font-bold",children:"Overdue"}):r<=3?p=jsxRuntime.jsx("span",{className:"text-xs text-red-600 dark:text-red-400",children:"Urgent"}):r<=7&&(p=jsxRuntime.jsx("span",{className:"text-xs text-yellow-600 dark:text-yellow-400",children:"Soon"}))),jsxRuntime.jsxs("div",{role:"button",tabIndex:0,"aria-label":`View request from ${e.subject.name}`,"aria-selected":y===e.id,className:chunkE64TU6IU_js.a(`p-3 rounded-md cursor-pointer ${y===e.id?"bg-[rgb(var(--ndpr-primary)/0.05)] dark:bg-[rgb(var(--ndpr-primary)/0.1)] border border-[rgb(var(--ndpr-primary)/0.2)] dark:border-[rgb(var(--ndpr-primary)/0.3)]":"bg-gray-50 dark:bg-gray-700 hover:bg-gray-100 dark:hover:bg-gray-600"}`,l==null?void 0:l.requestItem,k),onClick:()=>E(e.id),onKeyDown:h=>{(h.key==="Enter"||h.key===" ")&&(h.preventDefault(),E(e.id));},children:[jsxRuntime.jsxs("div",{className:"flex justify-between items-start mb-1",children:[jsxRuntime.jsx("h4",{className:"font-medium text-sm",children:e.subject.name}),t(e.type)]}),jsxRuntime.jsx("p",{className:"text-xs text-gray-600 dark:text-gray-400 mb-1",children:e.subject.email}),jsxRuntime.jsxs("p",{className:"text-xs text-gray-600 dark:text-gray-400 mb-1",children:["Received: ",R(e.createdAt)]}),jsxRuntime.jsxs("div",{className:"flex justify-between items-center mt-2",children:[jsxRuntime.jsx("div",{children:s(e.status)}),jsxRuntime.jsx("div",{children:p})]})]},e.id)})})]}),jsxRuntime.jsx("div",{className:chunkE64TU6IU_js.a("md:col-span-2",l==null?void 0:l.detailPanel,k),children:m?jsxRuntime.jsxs("div",{children:[jsxRuntime.jsxs("div",{className:"flex justify-between items-start mb-4",children:[jsxRuntime.jsx("h3",{className:"text-lg font-medium",children:m.subject.name}),jsxRuntime.jsxs("div",{className:"flex space-x-2",children:[t(m.type),s(m.status)]})]}),B&&m.dueDate&&jsxRuntime.jsx("div",{className:"mb-4",children:g(m)}),Y&&jsxRuntime.jsxs("div",{className:"mb-6",children:[jsxRuntime.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4 mb-4",children:[jsxRuntime.jsxs("div",{children:[jsxRuntime.jsxs("p",{className:"text-sm",children:[jsxRuntime.jsx("span",{className:"font-medium",children:"Email:"})," ",m.subject.email]}),m.subject.phone&&jsxRuntime.jsxs("p",{className:"text-sm",children:[jsxRuntime.jsx("span",{className:"font-medium",children:"Phone:"})," ",m.subject.phone]}),jsxRuntime.jsxs("p",{className:"text-sm",children:[jsxRuntime.jsx("span",{className:"font-medium",children:"Received:"})," ",R(m.createdAt)]})]}),jsxRuntime.jsxs("div",{children:[jsxRuntime.jsxs("p",{className:"text-sm",children:[jsxRuntime.jsx("span",{className:"font-medium",children:"Request Type:"})," ",{information:"Information",access:"Access",rectification:"Rectification",erasure:"Erasure",restriction:"Restriction",portability:"Portability",objection:"Objection",automated_decision_making:"Automated Decision-Making"}[m.type]||m.type]}),jsxRuntime.jsxs("p",{className:"text-sm",children:[jsxRuntime.jsx("span",{className:"font-medium",children:"Status:"})," ",m.status==="inProgress"?"In Progress":m.status==="awaitingVerification"?"Awaiting Verification":m.status.charAt(0).toUpperCase()+m.status.slice(1)]}),m.dueDate&&jsxRuntime.jsxs("p",{className:"text-sm",children:[jsxRuntime.jsx("span",{className:"font-medium",children:"Due Date:"})," ",R(m.dueDate)]})]})]}),m.description&&jsxRuntime.jsxs("div",{className:"mb-4",children:[jsxRuntime.jsx("p",{className:"text-sm font-medium",children:"Request Details:"}),jsxRuntime.jsx("p",{className:"text-sm text-gray-600 dark:text-gray-300 bg-gray-50 dark:bg-gray-700 p-2 rounded-md mt-1",children:m.description})]}),m.additionalInfo&&jsxRuntime.jsxs("div",{children:[jsxRuntime.jsx("p",{className:"text-sm font-medium",children:"Additional Information:"}),jsxRuntime.jsx("p",{className:"text-sm text-gray-600 dark:text-gray-300 bg-gray-50 dark:bg-gray-700 p-2 rounded-md mt-1",children:typeof m.additionalInfo=="object"?JSON.stringify(m.additionalInfo,null,2):String(m.additionalInfo||"No additional information provided")})]})]}),jsxRuntime.jsxs("div",{className:"mb-6 grid grid-cols-1 md:grid-cols-2 gap-4",children:[jsxRuntime.jsxs("div",{children:[jsxRuntime.jsx("h3",{id:"update-status-heading",className:"text-md font-medium mb-2",children:"Update Status"}),jsxRuntime.jsxs("div",{className:"flex space-x-2",children:[jsxRuntime.jsx("select",{"aria-label":"Update request status",value:m.status,onChange:e=>L(e.target.value),className:"flex-grow px-3 py-2 border border-gray-300 dark:border-gray-600 rounded-md focus:outline-none focus:ring-2 focus:ring-[rgb(var(--ndpr-ring))]",children:v()}),jsxRuntime.jsx("button",{onClick:()=>L(m.status),"aria-label":"Apply status update",className:`px-4 py-2 bg-[rgb(var(--ndpr-primary))] text-white rounded hover:bg-[rgb(var(--ndpr-primary-hover))] ${F}`,children:"Update"})]})]}),i.length>0&&jsxRuntime.jsxs("div",{children:[jsxRuntime.jsx("h3",{id:"assign-request-heading",className:"text-md font-medium mb-2",children:"Assign Request"}),jsxRuntime.jsxs("div",{className:"flex space-x-2",children:[jsxRuntime.jsxs("select",{"aria-label":"Select assignee",value:S,onChange:e=>Q(e.target.value),className:"flex-grow px-3 py-2 border border-gray-300 dark:border-gray-600 rounded-md focus:outline-none focus:ring-2 focus:ring-[rgb(var(--ndpr-ring))]",children:[jsxRuntime.jsx("option",{value:"",children:"Select Assignee"}),i.map(e=>jsxRuntime.jsx("option",{value:e,children:e},e))]}),jsxRuntime.jsx("button",{onClick:W,disabled:!S,"aria-label":"Assign request to selected person",className:`px-4 py-2 bg-[rgb(var(--ndpr-primary))] text-white rounded hover:bg-[rgb(var(--ndpr-primary-hover))] disabled:bg-gray-300 disabled:text-gray-500 ${F}`,children:"Assign"})]})]})]}),jsxRuntime.jsxs("div",{className:"mb-6",children:[jsxRuntime.jsx("h3",{className:"text-lg font-medium mb-3",children:"Request Summary"}),jsxRuntime.jsx("div",{className:"bg-gray-50 dark:bg-gray-700 p-3 rounded-md",children:jsxRuntime.jsx("pre",{className:"whitespace-pre-wrap text-sm font-mono text-gray-800 dark:text-gray-200",children:jsxRuntime.jsx("pre",{children:JSON.stringify(chunkJKKRPS4P_js.a(m),null,2)})})})]}),z&&x(m)]}):jsxRuntime.jsx("div",{className:"flex items-center justify-center h-64 bg-gray-50 dark:bg-gray-700 rounded-md",children:jsxRuntime.jsx("p",{className:"text-gray-600 dark:text-gray-400",children:"Select a request to view details"})})})]})]})};var ue=({requests:w,onSelectRequest:P,title:I="DSR Request Tracker",description:V="Track the status and progress of data subject requests as required by NDPA Part IV.",className:H="",buttonClassName:X="",showSummaryStats:J=true,showTypeBreakdown:F=true,showStatusBreakdown:Y=true,showTimelineChart:z=true,showOverdueRequests:B=true,classNames:i,unstyled:l=false})=>{let[k,y]=react.useState("30days"),[f,D]=react.useState(w),[O,j]=react.useState([]),[M,C]=react.useState([]);react.useEffect(()=>{let t=Date.now(),s;switch(k){case "7days":s=w.filter(o=>t-o.createdAt<=10080*60*1e3);break;case "30days":s=w.filter(o=>t-o.createdAt<=720*60*60*1e3);break;case "90days":s=w.filter(o=>t-o.createdAt<=2160*60*60*1e3);break;default:s=[...w];}D(s);let g=s.filter(o=>o.dueDate&&t>o.dueDate&&o.status!=="completed"&&o.status!=="rejected");j(g);let x=s.filter(o=>o.dueDate&&t<o.dueDate&&o.dueDate-t<=10080*60*1e3&&o.status!=="completed"&&o.status!=="rejected");C(x);},[w,k]);let T=t=>{P&&P(t);},A=t=>new Date(t).toLocaleDateString(),_=t=>{let s=Date.now(),g=(t-s)/(1440*60*1e3);return Math.ceil(g)},$=()=>{let t=f.filter(g=>g.status==="completed"&&g.completedAt&&g.createdAt);if(t.length===0)return null;let s=t.reduce((g,x)=>{let o=((x.completedAt||0)-x.createdAt)/864e5;return g+o},0);return Number((s/t.length).toFixed(1))},G=()=>{let t=f.filter(g=>(g.status==="completed"||g.status==="rejected")&&g.completedAt&&g.dueDate);if(t.length===0)return null;let s=t.filter(g=>(g.completedAt||0)<=(g.dueDate||0));return Math.round(s.length/t.length*100)},U=()=>{let t={};return f.forEach(s=>{t[s.type]=(t[s.type]||0)+1;}),{information:t.information||0,access:t.access||0,rectification:t.rectification||0,erasure:t.erasure||0,restriction:t.restriction||0,portability:t.portability||0,objection:t.objection||0,automated_decision_making:t.automated_decision_making||0}},Z=()=>{let t={};return f.forEach(s=>{t[s.status]=(t[s.status]||0)+1;}),{pending:t.pending||0,awaitingVerification:t.awaitingVerification||0,inProgress:t.inProgress||0,completed:t.completed||0,rejected:t.rejected||0}},S=t=>{let s={information:"bg-teal-100 text-teal-800 dark:bg-teal-900 dark:text-teal-200",access:"bg-blue-100 text-blue-800 dark:bg-blue-900 dark:text-blue-200",rectification:"bg-green-100 text-green-800 dark:bg-green-900 dark:text-green-200",erasure:"bg-red-100 text-red-800 dark:bg-red-900 dark:text-red-200",restriction:"bg-yellow-100 text-yellow-800 dark:bg-yellow-900 dark:text-yellow-200",portability:"bg-purple-100 text-purple-800 dark:bg-purple-900 dark:text-purple-200",objection:"bg-orange-100 text-orange-800 dark:bg-orange-900 dark:text-orange-200",automated_decision_making:"bg-indigo-100 text-indigo-800 dark:bg-indigo-900 dark:text-indigo-200"},g={information:"Information",access:"Access",rectification:"Rectification",erasure:"Erasure",restriction:"Restriction",portability:"Portability",objection:"Objection",automated_decision_making:"Automated Decision-Making"};return jsxRuntime.jsx("span",{className:`px-2 py-1 rounded text-xs font-medium ${s[t]}`,children:g[t]})},E=()=>{let t=f.length,s=f.filter(u=>u.status!=="completed"&&u.status!=="rejected").length;f.filter(u=>u.status==="completed"||u.status==="rejected").length;let x=$(),o=G();return jsxRuntime.jsxs("div",{className:chunkE64TU6IU_js.a("grid grid-cols-2 md:grid-cols-4 gap-4 mb-6",i==null?void 0:i.stats,l),children:[jsxRuntime.jsxs("div",{className:chunkE64TU6IU_js.a("bg-white dark:bg-gray-700 p-4 rounded-lg shadow",i==null?void 0:i.statCard,l),children:[jsxRuntime.jsx("h4",{className:"text-sm font-medium text-gray-600 dark:text-gray-400 mb-1",children:"Total Requests"}),jsxRuntime.jsx("p",{className:"text-2xl font-bold",children:t})]}),jsxRuntime.jsxs("div",{className:chunkE64TU6IU_js.a("bg-white dark:bg-gray-700 p-4 rounded-lg shadow",i==null?void 0:i.statCard,l),children:[jsxRuntime.jsx("h4",{className:"text-sm font-medium text-gray-600 dark:text-gray-400 mb-1",children:"Pending Requests"}),jsxRuntime.jsx("p",{className:"text-2xl font-bold",children:s})]}),jsxRuntime.jsxs("div",{className:chunkE64TU6IU_js.a("bg-white dark:bg-gray-700 p-4 rounded-lg shadow",i==null?void 0:i.statCard,l),children:[jsxRuntime.jsx("h4",{className:"text-sm font-medium text-gray-600 dark:text-gray-400 mb-1",children:"Avg. Response Time"}),jsxRuntime.jsx("p",{className:"text-2xl font-bold",children:x!==null?`${x} days`:"N/A"})]}),jsxRuntime.jsxs("div",{className:chunkE64TU6IU_js.a("bg-white dark:bg-gray-700 p-4 rounded-lg shadow",i==null?void 0:i.statCard,l),children:[jsxRuntime.jsx("h4",{className:"text-sm font-medium text-gray-600 dark:text-gray-400 mb-1",children:"Compliance Rate"}),jsxRuntime.jsx("p",{className:"text-2xl font-bold",children:o!==null?`${o}%`:"N/A"})]})]})},L=()=>{let t=U(),s=f.length,g=Object.entries(t).sort(([,x],[,o])=>o-x).map(([x])=>x);return jsxRuntime.jsxs("div",{className:chunkE64TU6IU_js.a("bg-white dark:bg-gray-700 p-4 rounded-lg shadow mb-6",i==null?void 0:i.table,l),children:[jsxRuntime.jsx("h3",{className:chunkE64TU6IU_js.a("text-lg font-medium mb-4",i==null?void 0:i.tableHeader,l),children:"Request Types"}),s===0?jsxRuntime.jsx("p",{className:"text-gray-600 dark:text-gray-400 text-sm",children:"No data available for the selected timeframe."}):jsxRuntime.jsx("div",{className:"space-y-4",children:g.map(x=>{let o=t[x],u=Math.round(o/s*100);return jsxRuntime.jsxs("div",{children:[jsxRuntime.jsxs("div",{className:"flex justify-between items-center mb-1",children:[jsxRuntime.jsxs("div",{className:"flex items-center",children:[S(x),jsxRuntime.jsxs("span",{className:"ml-2 text-sm",children:[o," requests"]})]}),jsxRuntime.jsxs("span",{className:"text-sm font-medium",children:[u,"%"]})]}),jsxRuntime.jsx("div",{className:"w-full bg-gray-200 dark:bg-gray-600 rounded-full h-2.5",children:jsxRuntime.jsx("div",{className:"bg-[rgb(var(--ndpr-primary))] h-2.5 rounded-full",style:{width:`${u}%`}})})]},x)})})]})},W=()=>{let t=Z(),s=f.length,g=["pending","awaitingVerification","inProgress","completed","rejected"],x={pending:"bg-yellow-500",awaitingVerification:"bg-purple-500",inProgress:"bg-blue-500",completed:"bg-green-500",rejected:"bg-red-500"};return jsxRuntime.jsxs("div",{className:chunkE64TU6IU_js.a("bg-white dark:bg-gray-700 p-4 rounded-lg shadow mb-6",i==null?void 0:i.table,l),children:[jsxRuntime.jsx("h3",{className:chunkE64TU6IU_js.a("text-lg font-medium mb-4",i==null?void 0:i.tableHeader,l),children:"Request Status"}),s===0?jsxRuntime.jsx("p",{className:"text-gray-600 dark:text-gray-400 text-sm",children:"No data available for the selected timeframe."}):jsxRuntime.jsxs("div",{children:[jsxRuntime.jsx("div",{className:"flex h-4 mb-2",children:g.map(o=>{let u=t[o],v=u/s*100;return v>0?jsxRuntime.jsx("div",{className:`${x[o]} first:rounded-l-full last:rounded-r-full`,style:{width:`${v}%`},title:`${o}: ${u} (${Math.round(v)}%)`},o):null})}),jsxRuntime.jsx("div",{className:"grid grid-cols-2 md:grid-cols-5 gap-2 mt-4",children:g.map(o=>{let u=t[o],v=Math.round(u/s*100);return jsxRuntime.jsxs("div",{className:"flex items-center",children:[jsxRuntime.jsx("div",{className:`w-3 h-3 rounded-full ${x[o]} mr-2`}),jsxRuntime.jsxs("div",{children:[jsxRuntime.jsx("p",{className:"text-xs font-medium",children:o==="inProgress"?"In Progress":o==="awaitingVerification"?"Awaiting Verification":o.charAt(0).toUpperCase()+o.slice(1)}),jsxRuntime.jsxs("p",{className:"text-xs text-gray-600 dark:text-gray-400",children:[u," (",v,"%)"]})]})]},o)})})]})]})},R=()=>{let t={};f.forEach(u=>{let v=new Date(u.createdAt),e=`${v.getFullYear()}-${String(v.getMonth()+1).padStart(2,"0")}`;t[e]=(t[e]||0)+1;});let g=Object.keys(t).sort().slice(-6),x=Math.max(...Object.values(t).filter(u=>u>0),1),o=u=>{let[v,e]=u.split("-");return `${e}/${v.slice(2)}`};return jsxRuntime.jsxs("div",{className:"bg-white dark:bg-gray-700 p-4 rounded-lg shadow mb-6",children:[jsxRuntime.jsx("h3",{className:"text-lg font-medium mb-4",children:"Request Timeline"}),g.length===0?jsxRuntime.jsx("p",{className:"text-gray-600 dark:text-gray-400 text-sm",children:"No data available for the selected timeframe."}):jsxRuntime.jsxs("div",{className:"h-40",children:[jsxRuntime.jsx("div",{className:"flex h-32 items-end justify-between space-x-2",children:g.map(u=>{let v=t[u],e=`${v/x*100}%`;return jsxRuntime.jsx("div",{className:"flex flex-col items-center flex-1",children:jsxRuntime.jsx("div",{className:"w-full bg-[rgb(var(--ndpr-primary))] rounded-t",style:{height:e},title:`${o(u)}: ${v} requests`})},u)})}),jsxRuntime.jsx("div",{className:"flex justify-between mt-2",children:g.map(u=>jsxRuntime.jsx("div",{className:"text-xs text-center",children:o(u)},u))})]})]})},q=()=>jsxRuntime.jsxs("div",{className:"bg-white dark:bg-gray-700 p-4 rounded-lg shadow mb-6","aria-live":"polite",children:[jsxRuntime.jsx("h3",{className:"text-lg font-medium mb-4",children:"Overdue Requests"}),O.length===0?jsxRuntime.jsx("p",{className:"text-gray-600 dark:text-gray-400 text-sm",children:"No overdue requests."}):jsxRuntime.jsx("div",{className:"space-y-2 max-h-60 overflow-y-auto",children:O.map(t=>jsxRuntime.jsxs("div",{role:"button",tabIndex:0,"aria-label":`View overdue request from ${t.subject.name}`,className:chunkE64TU6IU_js.a("p-3 bg-red-50 dark:bg-red-900/20 rounded-md cursor-pointer hover:bg-red-100 dark:hover:bg-red-900/30",i==null?void 0:i.tableRow,l),onClick:()=>T(t.id),onKeyDown:s=>{(s.key==="Enter"||s.key===" ")&&(s.preventDefault(),T(t.id));},children:[jsxRuntime.jsxs("div",{className:"flex justify-between items-start mb-1",children:[jsxRuntime.jsx("h4",{className:"font-medium text-sm",children:t.subject.name}),S(t.type)]}),jsxRuntime.jsx("p",{className:"text-xs text-gray-600 dark:text-gray-400 mb-1",children:t.subject.email}),jsxRuntime.jsxs("div",{className:"flex justify-between items-center",children:[jsxRuntime.jsxs("p",{className:"text-xs text-gray-600 dark:text-gray-400",children:["Due: ",A(t.dueDate||0)]}),jsxRuntime.jsxs("p",{className:"text-xs font-bold text-red-600 dark:text-red-400",children:["Overdue by ",Math.abs(_(t.dueDate||0))," days"]})]})]},t.id))})]}),m=()=>jsxRuntime.jsxs("div",{className:"bg-white dark:bg-gray-700 p-4 rounded-lg shadow mb-6","aria-live":"polite",children:[jsxRuntime.jsx("h3",{className:"text-lg font-medium mb-4",children:"Upcoming Deadlines"}),M.length===0?jsxRuntime.jsx("p",{className:"text-gray-600 dark:text-gray-400 text-sm",children:"No upcoming deadlines in the next 7 days."}):jsxRuntime.jsx("div",{className:"space-y-2 max-h-60 overflow-y-auto",children:M.map(t=>{let s=_(t.dueDate||0);return jsxRuntime.jsxs("div",{role:"button",tabIndex:0,"aria-label":`View upcoming deadline for ${t.subject.name}`,className:chunkE64TU6IU_js.a("p-3 bg-yellow-50 dark:bg-yellow-900/20 rounded-md cursor-pointer hover:bg-yellow-100 dark:hover:bg-yellow-900/30",i==null?void 0:i.tableRow,l),onClick:()=>T(t.id),onKeyDown:g=>{(g.key==="Enter"||g.key===" ")&&(g.preventDefault(),T(t.id));},children:[jsxRuntime.jsxs("div",{className:"flex justify-between items-start mb-1",children:[jsxRuntime.jsx("h4",{className:"font-medium text-sm",children:t.subject.name}),S(t.type)]}),jsxRuntime.jsx("p",{className:"text-xs text-gray-600 dark:text-gray-400 mb-1",children:t.subject.email}),jsxRuntime.jsxs("div",{className:"flex justify-between items-center",children:[jsxRuntime.jsxs("p",{className:"text-xs text-gray-600 dark:text-gray-400",children:["Due: ",A(t.dueDate||0)]}),jsxRuntime.jsxs("p",{className:`text-xs font-bold ${s<=3?"text-red-600 dark:text-red-400":"text-yellow-600 dark:text-yellow-400"}`,children:["Due in ",s," days"]})]})]},t.id)})})]});return jsxRuntime.jsxs("div",{className:chunkE64TU6IU_js.a(`bg-white dark:bg-gray-800 p-6 rounded-lg shadow-md ${H}`,i==null?void 0:i.root,l),children:[jsxRuntime.jsxs("div",{className:chunkE64TU6IU_js.a("flex flex-col md:flex-row md:justify-between md:items-center mb-6",i==null?void 0:i.header,l),children:[jsxRuntime.jsxs("div",{children:[jsxRuntime.jsx("h2",{className:chunkE64TU6IU_js.a("text-xl font-bold mb-2",i==null?void 0:i.title,l),children:I}),jsxRuntime.jsx("p",{className:"text-gray-600 dark:text-gray-300",children:V})]}),jsxRuntime.jsxs("div",{className:"mt-4 md:mt-0",children:[jsxRuntime.jsx("label",{htmlFor:"timeframe",className:"block text-sm font-medium mb-1",children:"Timeframe"}),jsxRuntime.jsxs("select",{id:"timeframe",value:k,onChange:t=>y(t.target.value),className:"px-3 py-2 border border-gray-300 dark:border-gray-600 rounded-md focus:outline-none focus:ring-2 focus:ring-[rgb(var(--ndpr-ring))]",children:[jsxRuntime.jsx("option",{value:"7days",children:"Last 7 Days"}),jsxRuntime.jsx("option",{value:"30days",children:"Last 30 Days"}),jsxRuntime.jsx("option",{value:"90days",children:"Last 90 Days"}),jsxRuntime.jsx("option",{value:"all",children:"All Time"})]})]})]}),J&&E(),jsxRuntime.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-6",children:[jsxRuntime.jsxs("div",{children:[F&&L(),Y&&W()]}),jsxRuntime.jsxs("div",{children:[z&&R(),B&&q(),B&&m()]})]})]})};exports.a=oe;exports.b=ue;//# sourceMappingURL=chunk-ZYLDLGFL.js.map
2
+ //# sourceMappingURL=chunk-ZYLDLGFL.js.map
package/dist/consent.js CHANGED
@@ -1,2 +1,2 @@
1
- 'use strict';var chunk256APOQM_js=require('./chunk-256APOQM.js'),chunk555WWZ3W_js=require('./chunk-555WWZ3W.js'),chunkMJGOLP5M_js=require('./chunk-MJGOLP5M.js'),chunk7SMLHZ4B_js=require('./chunk-7SMLHZ4B.js');require('./chunk-A4PK7JB2.js');var chunkHO5M7M4M_js=require('./chunk-HO5M7M4M.js'),chunkE64TU6IU_js=require('./chunk-E64TU6IU.js');require('./chunk-ELKB2AFZ.js');var chunkMQFZHA2D_js=require('./chunk-MQFZHA2D.js'),react=require('react'),jsxRuntime=require('react/jsx-runtime');var R=react.createContext(null);function s(){let t=react.useContext(R);if(!t)throw new Error("Consent compound components must be wrapped in <Consent.Provider>. Example: <Consent.Provider options={...}><Consent.Banner /></Consent.Provider>");return t}var x=({options:t,adapter:e,version:p,onChange:r,children:c})=>{let d=chunk7SMLHZ4B_js.a({options:t,adapter:e,version:p,onChange:r}),o=chunkMQFZHA2D_js.b(chunkMQFZHA2D_js.a({},d),{options:t});return jsxRuntime.jsx(R.Provider,{value:o,children:c})};var v=({classNames:t,unstyled:e})=>{let{options:p,settings:r}=s(),[c,d]=react.useState(()=>{let o={};return p.forEach(a=>{var i,A;o[a.id]=(A=(i=r==null?void 0:r.consents[a.id])!=null?i:a.defaultValue)!=null?A:false;}),o});return jsxRuntime.jsx("div",{className:chunkE64TU6IU_js.a("space-y-3",t==null?void 0:t.root,e),"data-ndpr-component":"consent-option-list",children:p.map(o=>jsxRuntime.jsxs("div",{className:chunkE64TU6IU_js.a("flex items-start",t==null?void 0:t.optionItem,e),children:[jsxRuntime.jsx("div",{className:"flex items-center h-5",children:jsxRuntime.jsx("input",{id:`consent-${o.id}`,type:"checkbox",checked:c[o.id]||false,onChange:a=>d(i=>chunkMQFZHA2D_js.b(chunkMQFZHA2D_js.a({},i),{[o.id]:a.target.checked})),disabled:o.required,className:chunkE64TU6IU_js.a("h-4 w-4 rounded border-gray-300 text-[rgb(var(--ndpr-primary))] focus:ring-[rgb(var(--ndpr-ring))]",t==null?void 0:t.optionCheckbox,e),"aria-label":o.label})}),jsxRuntime.jsxs("div",{className:"ml-3 text-sm",children:[jsxRuntime.jsxs("label",{htmlFor:`consent-${o.id}`,className:chunkE64TU6IU_js.a("font-medium",t==null?void 0:t.optionLabel,e),children:[o.label," ",o.required&&jsxRuntime.jsx("span",{className:"text-red-500",children:"*"})]}),jsxRuntime.jsx("p",{className:chunkE64TU6IU_js.a("text-gray-600 dark:text-gray-400",t==null?void 0:t.optionDescription,e),children:o.description})]})]},o.id))})};var b=({children:t,className:e,unstyled:p})=>{let{acceptAll:r}=s();return jsxRuntime.jsx("button",{onClick:r,className:chunkE64TU6IU_js.a("px-4 py-2 bg-[rgb(var(--ndpr-primary))] text-[rgb(var(--ndpr-primary-foreground))] rounded hover:bg-[rgb(var(--ndpr-primary-hover))]",e,p),"data-ndpr-component":"consent-accept-button",children:t!=null?t:"Accept All"})};var y=({children:t,className:e,unstyled:p})=>{let{rejectAll:r}=s();return jsxRuntime.jsx("button",{onClick:r,className:chunkE64TU6IU_js.a("px-4 py-2 bg-gray-200 text-gray-800 dark:bg-gray-700 dark:text-white rounded hover:bg-gray-300 dark:hover:bg-gray-600",e,p),"data-ndpr-component":"consent-reject-button",children:t!=null?t:"Reject All"})};var B=({children:t,className:e,unstyled:p,consents:r})=>{let{updateConsent:c,options:d}=s();return jsxRuntime.jsx("button",{onClick:()=>{if(r)c(r);else {let a={};d.forEach(i=>{a[i.id]=i.required||false;}),c(a);}},className:chunkE64TU6IU_js.a("px-4 py-2 bg-[rgb(var(--ndpr-primary))] text-[rgb(var(--ndpr-primary-foreground))] rounded hover:bg-[rgb(var(--ndpr-primary-hover))]",e,p),"data-ndpr-component":"consent-save-button",children:t!=null?t:"Save Preferences"})};var D={Provider:x,OptionList:v,AcceptButton:b,RejectButton:y,SaveButton:B,Banner:chunk555WWZ3W_js.a,Settings:chunk256APOQM_js.a,Storage:chunk256APOQM_js.b};Object.defineProperty(exports,"ConsentManager",{enumerable:true,get:function(){return chunk256APOQM_js.a}});Object.defineProperty(exports,"ConsentStorage",{enumerable:true,get:function(){return chunk256APOQM_js.b}});Object.defineProperty(exports,"ConsentBanner",{enumerable:true,get:function(){return chunk555WWZ3W_js.a}});Object.defineProperty(exports,"appendAuditEntry",{enumerable:true,get:function(){return chunkMJGOLP5M_js.c}});Object.defineProperty(exports,"createAuditEntry",{enumerable:true,get:function(){return chunkMJGOLP5M_js.a}});Object.defineProperty(exports,"getAuditLog",{enumerable:true,get:function(){return chunkMJGOLP5M_js.b}});Object.defineProperty(exports,"useConsent",{enumerable:true,get:function(){return chunk7SMLHZ4B_js.a}});Object.defineProperty(exports,"validateConsent",{enumerable:true,get:function(){return chunkHO5M7M4M_js.a}});Object.defineProperty(exports,"validateConsentOptions",{enumerable:true,get:function(){return chunkHO5M7M4M_js.b}});Object.defineProperty(exports,"resolveClass",{enumerable:true,get:function(){return chunkE64TU6IU_js.a}});exports.Consent=D;exports.ConsentAcceptButton=b;exports.ConsentOptionList=v;exports.ConsentProvider=x;exports.ConsentRejectButton=y;exports.ConsentSaveButton=B;exports.useConsentCompound=s;//# sourceMappingURL=consent.js.map
1
+ 'use strict';var chunk256APOQM_js=require('./chunk-256APOQM.js'),chunkNBSVFQ5G_js=require('./chunk-NBSVFQ5G.js'),chunkMJGOLP5M_js=require('./chunk-MJGOLP5M.js'),chunk7SMLHZ4B_js=require('./chunk-7SMLHZ4B.js');require('./chunk-A4PK7JB2.js');var chunkHO5M7M4M_js=require('./chunk-HO5M7M4M.js'),chunkE64TU6IU_js=require('./chunk-E64TU6IU.js');require('./chunk-ELKB2AFZ.js');var chunkMQFZHA2D_js=require('./chunk-MQFZHA2D.js'),react=require('react'),jsxRuntime=require('react/jsx-runtime');var R=react.createContext(null);function s(){let t=react.useContext(R);if(!t)throw new Error("Consent compound components must be wrapped in <Consent.Provider>. Example: <Consent.Provider options={...}><Consent.Banner /></Consent.Provider>");return t}var x=({options:t,adapter:e,version:p,onChange:r,children:c})=>{let d=chunk7SMLHZ4B_js.a({options:t,adapter:e,version:p,onChange:r}),o=chunkMQFZHA2D_js.b(chunkMQFZHA2D_js.a({},d),{options:t});return jsxRuntime.jsx(R.Provider,{value:o,children:c})};var v=({classNames:t,unstyled:e})=>{let{options:p,settings:r}=s(),[c,d]=react.useState(()=>{let o={};return p.forEach(a=>{var i,A;o[a.id]=(A=(i=r==null?void 0:r.consents[a.id])!=null?i:a.defaultValue)!=null?A:false;}),o});return jsxRuntime.jsx("div",{className:chunkE64TU6IU_js.a("space-y-3",t==null?void 0:t.root,e),"data-ndpr-component":"consent-option-list",children:p.map(o=>jsxRuntime.jsxs("div",{className:chunkE64TU6IU_js.a("flex items-start",t==null?void 0:t.optionItem,e),children:[jsxRuntime.jsx("div",{className:"flex items-center h-5",children:jsxRuntime.jsx("input",{id:`consent-${o.id}`,type:"checkbox",checked:c[o.id]||false,onChange:a=>d(i=>chunkMQFZHA2D_js.b(chunkMQFZHA2D_js.a({},i),{[o.id]:a.target.checked})),disabled:o.required,className:chunkE64TU6IU_js.a("h-4 w-4 rounded border-gray-300 text-[rgb(var(--ndpr-primary))] focus:ring-[rgb(var(--ndpr-ring))]",t==null?void 0:t.optionCheckbox,e),"aria-label":o.label})}),jsxRuntime.jsxs("div",{className:"ml-3 text-sm",children:[jsxRuntime.jsxs("label",{htmlFor:`consent-${o.id}`,className:chunkE64TU6IU_js.a("font-medium",t==null?void 0:t.optionLabel,e),children:[o.label," ",o.required&&jsxRuntime.jsx("span",{className:"text-red-500",children:"*"})]}),jsxRuntime.jsx("p",{className:chunkE64TU6IU_js.a("text-gray-600 dark:text-gray-400",t==null?void 0:t.optionDescription,e),children:o.description})]})]},o.id))})};var b=({children:t,className:e,unstyled:p})=>{let{acceptAll:r}=s();return jsxRuntime.jsx("button",{onClick:r,className:chunkE64TU6IU_js.a("px-4 py-2 bg-[rgb(var(--ndpr-primary))] text-[rgb(var(--ndpr-primary-foreground))] rounded hover:bg-[rgb(var(--ndpr-primary-hover))]",e,p),"data-ndpr-component":"consent-accept-button",children:t!=null?t:"Accept All"})};var y=({children:t,className:e,unstyled:p})=>{let{rejectAll:r}=s();return jsxRuntime.jsx("button",{onClick:r,className:chunkE64TU6IU_js.a("px-4 py-2 bg-gray-200 text-gray-800 dark:bg-gray-700 dark:text-white rounded hover:bg-gray-300 dark:hover:bg-gray-600",e,p),"data-ndpr-component":"consent-reject-button",children:t!=null?t:"Reject All"})};var B=({children:t,className:e,unstyled:p,consents:r})=>{let{updateConsent:c,options:d}=s();return jsxRuntime.jsx("button",{onClick:()=>{if(r)c(r);else {let a={};d.forEach(i=>{a[i.id]=i.required||false;}),c(a);}},className:chunkE64TU6IU_js.a("px-4 py-2 bg-[rgb(var(--ndpr-primary))] text-[rgb(var(--ndpr-primary-foreground))] rounded hover:bg-[rgb(var(--ndpr-primary-hover))]",e,p),"data-ndpr-component":"consent-save-button",children:t!=null?t:"Save Preferences"})};var D={Provider:x,OptionList:v,AcceptButton:b,RejectButton:y,SaveButton:B,Banner:chunkNBSVFQ5G_js.a,Settings:chunk256APOQM_js.a,Storage:chunk256APOQM_js.b};Object.defineProperty(exports,"ConsentManager",{enumerable:true,get:function(){return chunk256APOQM_js.a}});Object.defineProperty(exports,"ConsentStorage",{enumerable:true,get:function(){return chunk256APOQM_js.b}});Object.defineProperty(exports,"ConsentBanner",{enumerable:true,get:function(){return chunkNBSVFQ5G_js.a}});Object.defineProperty(exports,"appendAuditEntry",{enumerable:true,get:function(){return chunkMJGOLP5M_js.c}});Object.defineProperty(exports,"createAuditEntry",{enumerable:true,get:function(){return chunkMJGOLP5M_js.a}});Object.defineProperty(exports,"getAuditLog",{enumerable:true,get:function(){return chunkMJGOLP5M_js.b}});Object.defineProperty(exports,"useConsent",{enumerable:true,get:function(){return chunk7SMLHZ4B_js.a}});Object.defineProperty(exports,"validateConsent",{enumerable:true,get:function(){return chunkHO5M7M4M_js.a}});Object.defineProperty(exports,"validateConsentOptions",{enumerable:true,get:function(){return chunkHO5M7M4M_js.b}});Object.defineProperty(exports,"resolveClass",{enumerable:true,get:function(){return chunkE64TU6IU_js.a}});exports.Consent=D;exports.ConsentAcceptButton=b;exports.ConsentOptionList=v;exports.ConsentProvider=x;exports.ConsentRejectButton=y;exports.ConsentSaveButton=B;exports.useConsentCompound=s;//# sourceMappingURL=consent.js.map
2
2
  //# sourceMappingURL=consent.js.map
package/dist/consent.mjs CHANGED
@@ -1,2 +1,2 @@
1
- import {b as b$1,a}from'./chunk-Q7VHB64E.mjs';export{a as ConsentManager,b as ConsentStorage}from'./chunk-Q7VHB64E.mjs';import {a as a$1}from'./chunk-4XCL62MJ.mjs';export{a as ConsentBanner}from'./chunk-4XCL62MJ.mjs';export{c as appendAuditEntry,a as createAuditEntry,b as getAuditLog}from'./chunk-P3PULLYP.mjs';import {a as a$2}from'./chunk-VWPGIES4.mjs';export{a as useConsent}from'./chunk-VWPGIES4.mjs';import'./chunk-R3OYAJI6.mjs';export{a as validateConsent,b as validateConsentOptions}from'./chunk-U62QYKVG.mjs';import {a as a$4}from'./chunk-AYKLAEOU.mjs';export{a as resolveClass}from'./chunk-AYKLAEOU.mjs';import'./chunk-6WIP33TW.mjs';import {b as b$2,a as a$3}from'./chunk-WWT2ZSNU.mjs';import {createContext,useContext,useState}from'react';import {jsx,jsxs}from'react/jsx-runtime';var R=createContext(null);function s(){let t=useContext(R);if(!t)throw new Error("Consent compound components must be wrapped in <Consent.Provider>. Example: <Consent.Provider options={...}><Consent.Banner /></Consent.Provider>");return t}var x=({options:t,adapter:e,version:p,onChange:r,children:c})=>{let d=a$2({options:t,adapter:e,version:p,onChange:r}),o=b$2(a$3({},d),{options:t});return jsx(R.Provider,{value:o,children:c})};var v=({classNames:t,unstyled:e})=>{let{options:p,settings:r}=s(),[c,d]=useState(()=>{let o={};return p.forEach(a=>{var i,A;o[a.id]=(A=(i=r==null?void 0:r.consents[a.id])!=null?i:a.defaultValue)!=null?A:false;}),o});return jsx("div",{className:a$4("space-y-3",t==null?void 0:t.root,e),"data-ndpr-component":"consent-option-list",children:p.map(o=>jsxs("div",{className:a$4("flex items-start",t==null?void 0:t.optionItem,e),children:[jsx("div",{className:"flex items-center h-5",children:jsx("input",{id:`consent-${o.id}`,type:"checkbox",checked:c[o.id]||false,onChange:a=>d(i=>b$2(a$3({},i),{[o.id]:a.target.checked})),disabled:o.required,className:a$4("h-4 w-4 rounded border-gray-300 text-[rgb(var(--ndpr-primary))] focus:ring-[rgb(var(--ndpr-ring))]",t==null?void 0:t.optionCheckbox,e),"aria-label":o.label})}),jsxs("div",{className:"ml-3 text-sm",children:[jsxs("label",{htmlFor:`consent-${o.id}`,className:a$4("font-medium",t==null?void 0:t.optionLabel,e),children:[o.label," ",o.required&&jsx("span",{className:"text-red-500",children:"*"})]}),jsx("p",{className:a$4("text-gray-600 dark:text-gray-400",t==null?void 0:t.optionDescription,e),children:o.description})]})]},o.id))})};var b=({children:t,className:e,unstyled:p})=>{let{acceptAll:r}=s();return jsx("button",{onClick:r,className:a$4("px-4 py-2 bg-[rgb(var(--ndpr-primary))] text-[rgb(var(--ndpr-primary-foreground))] rounded hover:bg-[rgb(var(--ndpr-primary-hover))]",e,p),"data-ndpr-component":"consent-accept-button",children:t!=null?t:"Accept All"})};var y=({children:t,className:e,unstyled:p})=>{let{rejectAll:r}=s();return jsx("button",{onClick:r,className:a$4("px-4 py-2 bg-gray-200 text-gray-800 dark:bg-gray-700 dark:text-white rounded hover:bg-gray-300 dark:hover:bg-gray-600",e,p),"data-ndpr-component":"consent-reject-button",children:t!=null?t:"Reject All"})};var B=({children:t,className:e,unstyled:p,consents:r})=>{let{updateConsent:c,options:d}=s();return jsx("button",{onClick:()=>{if(r)c(r);else {let a={};d.forEach(i=>{a[i.id]=i.required||false;}),c(a);}},className:a$4("px-4 py-2 bg-[rgb(var(--ndpr-primary))] text-[rgb(var(--ndpr-primary-foreground))] rounded hover:bg-[rgb(var(--ndpr-primary-hover))]",e,p),"data-ndpr-component":"consent-save-button",children:t!=null?t:"Save Preferences"})};var D={Provider:x,OptionList:v,AcceptButton:b,RejectButton:y,SaveButton:B,Banner:a$1,Settings:a,Storage:b$1};export{D as Consent,b as ConsentAcceptButton,v as ConsentOptionList,x as ConsentProvider,y as ConsentRejectButton,B as ConsentSaveButton,s as useConsentCompound};//# sourceMappingURL=consent.mjs.map
1
+ import {b as b$1,a}from'./chunk-Q7VHB64E.mjs';export{a as ConsentManager,b as ConsentStorage}from'./chunk-Q7VHB64E.mjs';import {a as a$1}from'./chunk-4JKTIR33.mjs';export{a as ConsentBanner}from'./chunk-4JKTIR33.mjs';export{c as appendAuditEntry,a as createAuditEntry,b as getAuditLog}from'./chunk-P3PULLYP.mjs';import {a as a$2}from'./chunk-VWPGIES4.mjs';export{a as useConsent}from'./chunk-VWPGIES4.mjs';import'./chunk-R3OYAJI6.mjs';export{a as validateConsent,b as validateConsentOptions}from'./chunk-U62QYKVG.mjs';import {a as a$4}from'./chunk-AYKLAEOU.mjs';export{a as resolveClass}from'./chunk-AYKLAEOU.mjs';import'./chunk-6WIP33TW.mjs';import {b as b$2,a as a$3}from'./chunk-WWT2ZSNU.mjs';import {createContext,useContext,useState}from'react';import {jsx,jsxs}from'react/jsx-runtime';var R=createContext(null);function s(){let t=useContext(R);if(!t)throw new Error("Consent compound components must be wrapped in <Consent.Provider>. Example: <Consent.Provider options={...}><Consent.Banner /></Consent.Provider>");return t}var x=({options:t,adapter:e,version:p,onChange:r,children:c})=>{let d=a$2({options:t,adapter:e,version:p,onChange:r}),o=b$2(a$3({},d),{options:t});return jsx(R.Provider,{value:o,children:c})};var v=({classNames:t,unstyled:e})=>{let{options:p,settings:r}=s(),[c,d]=useState(()=>{let o={};return p.forEach(a=>{var i,A;o[a.id]=(A=(i=r==null?void 0:r.consents[a.id])!=null?i:a.defaultValue)!=null?A:false;}),o});return jsx("div",{className:a$4("space-y-3",t==null?void 0:t.root,e),"data-ndpr-component":"consent-option-list",children:p.map(o=>jsxs("div",{className:a$4("flex items-start",t==null?void 0:t.optionItem,e),children:[jsx("div",{className:"flex items-center h-5",children:jsx("input",{id:`consent-${o.id}`,type:"checkbox",checked:c[o.id]||false,onChange:a=>d(i=>b$2(a$3({},i),{[o.id]:a.target.checked})),disabled:o.required,className:a$4("h-4 w-4 rounded border-gray-300 text-[rgb(var(--ndpr-primary))] focus:ring-[rgb(var(--ndpr-ring))]",t==null?void 0:t.optionCheckbox,e),"aria-label":o.label})}),jsxs("div",{className:"ml-3 text-sm",children:[jsxs("label",{htmlFor:`consent-${o.id}`,className:a$4("font-medium",t==null?void 0:t.optionLabel,e),children:[o.label," ",o.required&&jsx("span",{className:"text-red-500",children:"*"})]}),jsx("p",{className:a$4("text-gray-600 dark:text-gray-400",t==null?void 0:t.optionDescription,e),children:o.description})]})]},o.id))})};var b=({children:t,className:e,unstyled:p})=>{let{acceptAll:r}=s();return jsx("button",{onClick:r,className:a$4("px-4 py-2 bg-[rgb(var(--ndpr-primary))] text-[rgb(var(--ndpr-primary-foreground))] rounded hover:bg-[rgb(var(--ndpr-primary-hover))]",e,p),"data-ndpr-component":"consent-accept-button",children:t!=null?t:"Accept All"})};var y=({children:t,className:e,unstyled:p})=>{let{rejectAll:r}=s();return jsx("button",{onClick:r,className:a$4("px-4 py-2 bg-gray-200 text-gray-800 dark:bg-gray-700 dark:text-white rounded hover:bg-gray-300 dark:hover:bg-gray-600",e,p),"data-ndpr-component":"consent-reject-button",children:t!=null?t:"Reject All"})};var B=({children:t,className:e,unstyled:p,consents:r})=>{let{updateConsent:c,options:d}=s();return jsx("button",{onClick:()=>{if(r)c(r);else {let a={};d.forEach(i=>{a[i.id]=i.required||false;}),c(a);}},className:a$4("px-4 py-2 bg-[rgb(var(--ndpr-primary))] text-[rgb(var(--ndpr-primary-foreground))] rounded hover:bg-[rgb(var(--ndpr-primary-hover))]",e,p),"data-ndpr-component":"consent-save-button",children:t!=null?t:"Save Preferences"})};var D={Provider:x,OptionList:v,AcceptButton:b,RejectButton:y,SaveButton:B,Banner:a$1,Settings:a,Storage:b$1};export{D as Consent,b as ConsentAcceptButton,v as ConsentOptionList,x as ConsentProvider,y as ConsentRejectButton,B as ConsentSaveButton,s as useConsentCompound};//# sourceMappingURL=consent.mjs.map
2
2
  //# sourceMappingURL=consent.mjs.map
package/dist/core.d.mts CHANGED
@@ -1,6 +1,6 @@
1
1
  export { C as ConsentOption, a as ConsentSettings, b as ConsentStorageOptions, L as LawfulBasisType } from './consent-CmVzqZUk.mjs';
2
- export { D as DSRRequest, a as DSRStatus, b as DSRType, R as RequestStatus, c as RequestType } from './dsr-Cm9lzWG7.mjs';
3
- export { D as DPIAQuestion, a as DPIAResult, b as DPIARisk, c as DPIASection } from './dpia-5OQVA1R_.mjs';
2
+ export { D as DSRRequest, a as DSRStatus, b as DSRType, R as RequestStatus, c as RequestType } from './dsr-yKbqX531.mjs';
3
+ export { D as DPIAQuestion, a as DPIAResult, b as DPIARisk, c as DPIASection } from './dpia-c9GiiOq0.mjs';
4
4
  export { B as BreachCategory, a as BreachReport, N as NotificationRequirement, R as RegulatoryNotification, b as RiskAssessment } from './breach-Eu9byel8.mjs';
5
5
  export { O as OrganizationInfo, P as PolicySection, a as PolicyTemplate, b as PolicyVariable, c as PrivacyPolicy } from './privacy-Ca6te9Ir.mjs';
6
6
  export { L as LawfulBasis, a as LawfulBasisSummary, b as LegitimateInterestAssessment, P as ProcessingActivity, S as SensitiveDataCondition } from './lawful-basis-Cv1VmDLn.mjs';
@@ -9,22 +9,34 @@ export { P as ProcessingRecord, R as ROPASummary, a as RecordOfProcessingActivit
9
9
  export { L as LawfulBasisComplianceGap, a as LawfulBasisValidationResult, b as assessComplianceGaps, g as generateLawfulBasisSummary, c as getLawfulBasisDescription, v as validateProcessingActivity } from './lawful-basis-C2eGaoHM.mjs';
10
10
  export { T as TransferRiskResult, a as TransferValidationResult, b as assessTransferRisk, g as getTransferMechanismDescription, i as isNDPCApprovalRequired, v as validateTransfer } from './cross-border-BBi9rZyO.mjs';
11
11
  export { R as ROPAComplianceGap, a as ROPAValidationResult, e as exportROPAToCSV, g as generateROPASummary, i as identifyComplianceGaps, v as validateProcessingRecord } from './ropa-NIgxd8uP.mjs';
12
- import { b as NDPRLocale, d as defaultLocale } from './sanitize-9mOO_cJW.mjs';
13
- export { N as NDPRConfig, a as NDPRProvider, s as sanitizeInput, u as useNDPRConfig, c as useNDPRLocale } from './sanitize-9mOO_cJW.mjs';
12
+ import { b as NDPRLocale, d as defaultLocale } from './sanitize-B0AzEm1D.mjs';
13
+ export { N as NDPRConfig, a as NDPRProvider, s as sanitizeInput, u as useNDPRConfig, c as useNDPRLocale } from './sanitize-B0AzEm1D.mjs';
14
14
  export { C as ConsentAuditEntry, a as appendAuditEntry, c as createAuditEntry, g as getAuditLog, v as validateConsent, b as validateConsentOptions } from './consent-audit-BdByjYlM.mjs';
15
- export { f as formatDSRRequest } from './dsr-D_eTNc4S.mjs';
16
- export { a as assessDPIARisk } from './dpia-CUfOmzvX.mjs';
15
+ export { f as formatDSRRequest } from './dsr-XZ_HqTlA.mjs';
16
+ export { a as assessDPIARisk } from './dpia-DQDFw2_l.mjs';
17
17
  export { c as calculateBreachSeverity } from './breach-B_-6lDqS.mjs';
18
18
  export { D as DEFAULT_POLICY_SECTIONS, a as DEFAULT_POLICY_VARIABLES, c as createBusinessPolicyTemplate, g as generatePolicyText } from './policy-templates-DMsPwOSZ.mjs';
19
- export { C as ComplianceGap, a as ComplianceResult, b as CustomSection, D as DataCategory, P as PolicyDraft, T as TemplateContext, c as ThirdPartyProcessor, d as createDefaultContext } from './policy-engine-C-tShzZH.mjs';
20
- export { a as assemblePolicy, e as evaluatePolicyCompliance } from './policy-sections-CfNVBLCh.mjs';
19
+ export { C as ComplianceGap, b as ComplianceResult, a as CustomSection, d as DataCategory, P as PolicyDraft, T as TemplateContext, e as ThirdPartyProcessor, f as createDefaultContext } from './policy-engine-DefZcX3R.mjs';
20
+ export { a as assemblePolicy, e as evaluatePolicyCompliance } from './policy-sections-Bylm31kZ.mjs';
21
21
  export { C as ComplianceInput, a as ComplianceRating, b as ComplianceReport, E as EffortLevel, M as ModuleScore, R as Recommendation, c as RecommendationPriority, d as RegulatoryReference, g as getComplianceScore } from './compliance-score-racQe_E_.mjs';
22
22
  import 'react';
23
23
 
24
+ declare const yorubaLocale: Required<{
25
+ [K in keyof NDPRLocale]: Required<NonNullable<NDPRLocale[K]>>;
26
+ }>;
27
+
28
+ declare const igboLocale: Required<{
29
+ [K in keyof NDPRLocale]: Required<NonNullable<NDPRLocale[K]>>;
30
+ }>;
31
+
32
+ declare const hausaLocale: Required<{
33
+ [K in keyof NDPRLocale]: Required<NonNullable<NDPRLocale[K]>>;
34
+ }>;
35
+
24
36
  /**
25
37
  * Deep merges a partial locale with the default English locale.
26
38
  * Any missing keys fall back to English.
27
39
  */
28
40
  declare function mergeLocale(partial?: NDPRLocale): typeof defaultLocale;
29
41
 
30
- export { NDPRLocale, defaultLocale, mergeLocale };
42
+ export { NDPRLocale, defaultLocale, hausaLocale, igboLocale, mergeLocale, yorubaLocale };
package/dist/core.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  export { C as ConsentOption, a as ConsentSettings, b as ConsentStorageOptions, L as LawfulBasisType } from './consent-CmVzqZUk.js';
2
- export { D as DSRRequest, a as DSRStatus, b as DSRType, R as RequestStatus, c as RequestType } from './dsr-Cm9lzWG7.js';
3
- export { D as DPIAQuestion, a as DPIAResult, b as DPIARisk, c as DPIASection } from './dpia-5OQVA1R_.js';
2
+ export { D as DSRRequest, a as DSRStatus, b as DSRType, R as RequestStatus, c as RequestType } from './dsr-yKbqX531.js';
3
+ export { D as DPIAQuestion, a as DPIAResult, b as DPIARisk, c as DPIASection } from './dpia-c9GiiOq0.js';
4
4
  export { B as BreachCategory, a as BreachReport, N as NotificationRequirement, R as RegulatoryNotification, b as RiskAssessment } from './breach-Eu9byel8.js';
5
5
  export { O as OrganizationInfo, P as PolicySection, a as PolicyTemplate, b as PolicyVariable, c as PrivacyPolicy } from './privacy-Ca6te9Ir.js';
6
6
  export { L as LawfulBasis, a as LawfulBasisSummary, b as LegitimateInterestAssessment, P as ProcessingActivity, S as SensitiveDataCondition } from './lawful-basis-Cv1VmDLn.js';
@@ -9,22 +9,34 @@ export { P as ProcessingRecord, R as ROPASummary, a as RecordOfProcessingActivit
9
9
  export { L as LawfulBasisComplianceGap, a as LawfulBasisValidationResult, b as assessComplianceGaps, g as generateLawfulBasisSummary, c as getLawfulBasisDescription, v as validateProcessingActivity } from './lawful-basis-BEyI0kGg.js';
10
10
  export { T as TransferRiskResult, a as TransferValidationResult, b as assessTransferRisk, g as getTransferMechanismDescription, i as isNDPCApprovalRequired, v as validateTransfer } from './cross-border-Dy-U9Hu6.js';
11
11
  export { R as ROPAComplianceGap, a as ROPAValidationResult, e as exportROPAToCSV, g as generateROPASummary, i as identifyComplianceGaps, v as validateProcessingRecord } from './ropa-CyynscU6.js';
12
- import { b as NDPRLocale, d as defaultLocale } from './sanitize-9mOO_cJW.js';
13
- export { N as NDPRConfig, a as NDPRProvider, s as sanitizeInput, u as useNDPRConfig, c as useNDPRLocale } from './sanitize-9mOO_cJW.js';
12
+ import { b as NDPRLocale, d as defaultLocale } from './sanitize-B0AzEm1D.js';
13
+ export { N as NDPRConfig, a as NDPRProvider, s as sanitizeInput, u as useNDPRConfig, c as useNDPRLocale } from './sanitize-B0AzEm1D.js';
14
14
  export { C as ConsentAuditEntry, a as appendAuditEntry, c as createAuditEntry, g as getAuditLog, v as validateConsent, b as validateConsentOptions } from './consent-audit-DhbfMR0n.js';
15
- export { f as formatDSRRequest } from './dsr-pNtVb1BK.js';
16
- export { a as assessDPIARisk } from './dpia-B0Pok5us.js';
15
+ export { f as formatDSRRequest } from './dsr-CIx5sd7e.js';
16
+ export { a as assessDPIARisk } from './dpia-D82hUrJe.js';
17
17
  export { c as calculateBreachSeverity } from './breach-CzXqSsaY.js';
18
18
  export { D as DEFAULT_POLICY_SECTIONS, a as DEFAULT_POLICY_VARIABLES, c as createBusinessPolicyTemplate, g as generatePolicyText } from './policy-templates-CIKcV0i1.js';
19
- export { C as ComplianceGap, a as ComplianceResult, b as CustomSection, D as DataCategory, P as PolicyDraft, T as TemplateContext, c as ThirdPartyProcessor, d as createDefaultContext } from './policy-engine-DSQpT55_.js';
20
- export { a as assemblePolicy, e as evaluatePolicyCompliance } from './policy-sections-DqH0iZRf.js';
19
+ export { C as ComplianceGap, b as ComplianceResult, a as CustomSection, d as DataCategory, P as PolicyDraft, T as TemplateContext, e as ThirdPartyProcessor, f as createDefaultContext } from './policy-engine-C6nC2t3a.js';
20
+ export { a as assemblePolicy, e as evaluatePolicyCompliance } from './policy-sections-DFDPVCCg.js';
21
21
  export { C as ComplianceInput, a as ComplianceRating, b as ComplianceReport, E as EffortLevel, M as ModuleScore, R as Recommendation, c as RecommendationPriority, d as RegulatoryReference, g as getComplianceScore } from './compliance-score-racQe_E_.js';
22
22
  import 'react';
23
23
 
24
+ declare const yorubaLocale: Required<{
25
+ [K in keyof NDPRLocale]: Required<NonNullable<NDPRLocale[K]>>;
26
+ }>;
27
+
28
+ declare const igboLocale: Required<{
29
+ [K in keyof NDPRLocale]: Required<NonNullable<NDPRLocale[K]>>;
30
+ }>;
31
+
32
+ declare const hausaLocale: Required<{
33
+ [K in keyof NDPRLocale]: Required<NonNullable<NDPRLocale[K]>>;
34
+ }>;
35
+
24
36
  /**
25
37
  * Deep merges a partial locale with the default English locale.
26
38
  * Any missing keys fall back to English.
27
39
  */
28
40
  declare function mergeLocale(partial?: NDPRLocale): typeof defaultLocale;
29
41
 
30
- export { NDPRLocale, defaultLocale, mergeLocale };
42
+ export { NDPRLocale, defaultLocale, hausaLocale, igboLocale, mergeLocale, yorubaLocale };
package/dist/core.js CHANGED
@@ -1,2 +1,2 @@
1
- 'use strict';var chunk44W4H2EY_js=require('./chunk-44W4H2EY.js'),chunkS4GRSNB4_js=require('./chunk-S4GRSNB4.js'),chunkTDDAYVKK_js=require('./chunk-TDDAYVKK.js'),chunkIQF726GS_js=require('./chunk-IQF726GS.js'),chunkGOU6FU6Y_js=require('./chunk-GOU6FU6Y.js'),chunkMJGOLP5M_js=require('./chunk-MJGOLP5M.js'),chunkHO5M7M4M_js=require('./chunk-HO5M7M4M.js'),chunkNRQELKAE_js=require('./chunk-NRQELKAE.js'),chunkP42Z5CFE_js=require('./chunk-P42Z5CFE.js'),chunkBKRETVJ6_js=require('./chunk-BKRETVJ6.js'),chunkI54CDQGN_js=require('./chunk-I54CDQGN.js'),chunkLU4PFST7_js=require('./chunk-LU4PFST7.js'),chunkUXMGBIX6_js=require('./chunk-UXMGBIX6.js');require('./chunk-MQFZHA2D.js');Object.defineProperty(exports,"NDPRProvider",{enumerable:true,get:function(){return chunk44W4H2EY_js.c}});Object.defineProperty(exports,"defaultLocale",{enumerable:true,get:function(){return chunk44W4H2EY_js.a}});Object.defineProperty(exports,"mergeLocale",{enumerable:true,get:function(){return chunk44W4H2EY_js.b}});Object.defineProperty(exports,"useNDPRConfig",{enumerable:true,get:function(){return chunk44W4H2EY_js.d}});Object.defineProperty(exports,"useNDPRLocale",{enumerable:true,get:function(){return chunk44W4H2EY_js.e}});Object.defineProperty(exports,"getComplianceScore",{enumerable:true,get:function(){return chunkS4GRSNB4_js.a}});Object.defineProperty(exports,"assessComplianceGaps",{enumerable:true,get:function(){return chunkTDDAYVKK_js.c}});Object.defineProperty(exports,"generateLawfulBasisSummary",{enumerable:true,get:function(){return chunkTDDAYVKK_js.d}});Object.defineProperty(exports,"getLawfulBasisDescription",{enumerable:true,get:function(){return chunkTDDAYVKK_js.b}});Object.defineProperty(exports,"validateProcessingActivity",{enumerable:true,get:function(){return chunkTDDAYVKK_js.a}});Object.defineProperty(exports,"assessTransferRisk",{enumerable:true,get:function(){return chunkIQF726GS_js.d}});Object.defineProperty(exports,"getTransferMechanismDescription",{enumerable:true,get:function(){return chunkIQF726GS_js.b}});Object.defineProperty(exports,"isNDPCApprovalRequired",{enumerable:true,get:function(){return chunkIQF726GS_js.a}});Object.defineProperty(exports,"validateTransfer",{enumerable:true,get:function(){return chunkIQF726GS_js.c}});Object.defineProperty(exports,"exportROPAToCSV",{enumerable:true,get:function(){return chunkGOU6FU6Y_js.c}});Object.defineProperty(exports,"generateROPASummary",{enumerable:true,get:function(){return chunkGOU6FU6Y_js.b}});Object.defineProperty(exports,"identifyComplianceGaps",{enumerable:true,get:function(){return chunkGOU6FU6Y_js.d}});Object.defineProperty(exports,"validateProcessingRecord",{enumerable:true,get:function(){return chunkGOU6FU6Y_js.a}});Object.defineProperty(exports,"appendAuditEntry",{enumerable:true,get:function(){return chunkMJGOLP5M_js.c}});Object.defineProperty(exports,"createAuditEntry",{enumerable:true,get:function(){return chunkMJGOLP5M_js.a}});Object.defineProperty(exports,"getAuditLog",{enumerable:true,get:function(){return chunkMJGOLP5M_js.b}});Object.defineProperty(exports,"validateConsent",{enumerable:true,get:function(){return chunkHO5M7M4M_js.a}});Object.defineProperty(exports,"validateConsentOptions",{enumerable:true,get:function(){return chunkHO5M7M4M_js.b}});Object.defineProperty(exports,"formatDSRRequest",{enumerable:true,get:function(){return chunkNRQELKAE_js.a}});Object.defineProperty(exports,"assessDPIARisk",{enumerable:true,get:function(){return chunkP42Z5CFE_js.a}});Object.defineProperty(exports,"calculateBreachSeverity",{enumerable:true,get:function(){return chunkBKRETVJ6_js.a}});Object.defineProperty(exports,"sanitizeInput",{enumerable:true,get:function(){return chunkI54CDQGN_js.a}});Object.defineProperty(exports,"assemblePolicy",{enumerable:true,get:function(){return chunkLU4PFST7_js.d}});Object.defineProperty(exports,"createDefaultContext",{enumerable:true,get:function(){return chunkLU4PFST7_js.b}});Object.defineProperty(exports,"evaluatePolicyCompliance",{enumerable:true,get:function(){return chunkLU4PFST7_js.c}});Object.defineProperty(exports,"DEFAULT_POLICY_SECTIONS",{enumerable:true,get:function(){return chunkUXMGBIX6_js.b}});Object.defineProperty(exports,"DEFAULT_POLICY_VARIABLES",{enumerable:true,get:function(){return chunkUXMGBIX6_js.c}});Object.defineProperty(exports,"createBusinessPolicyTemplate",{enumerable:true,get:function(){return chunkUXMGBIX6_js.d}});Object.defineProperty(exports,"generatePolicyText",{enumerable:true,get:function(){return chunkUXMGBIX6_js.a}});//# sourceMappingURL=core.js.map
1
+ 'use strict';var chunkUGY5ZYUG_js=require('./chunk-UGY5ZYUG.js'),chunkS4GRSNB4_js=require('./chunk-S4GRSNB4.js'),chunkTDDAYVKK_js=require('./chunk-TDDAYVKK.js'),chunkC4YM4UMI_js=require('./chunk-C4YM4UMI.js'),chunkGOU6FU6Y_js=require('./chunk-GOU6FU6Y.js'),chunkMJGOLP5M_js=require('./chunk-MJGOLP5M.js'),chunkHO5M7M4M_js=require('./chunk-HO5M7M4M.js'),chunkJKKRPS4P_js=require('./chunk-JKKRPS4P.js'),chunkP42Z5CFE_js=require('./chunk-P42Z5CFE.js'),chunkBKRETVJ6_js=require('./chunk-BKRETVJ6.js'),chunkI54CDQGN_js=require('./chunk-I54CDQGN.js'),chunkLU4PFST7_js=require('./chunk-LU4PFST7.js'),chunkUXMGBIX6_js=require('./chunk-UXMGBIX6.js');require('./chunk-MQFZHA2D.js');var M={consent:{title:"A M\u1ECDy\xEC \xC0\u1E63\xEDr\xED R\u1EB9",description:"A \u0144 lo k\xFAk\xEC \xE0ti \xE0w\u1ECDn \xECm\u1ECD\u0300-\u1EB9\u0300r\u1ECD t\xF3 j\u1ECDra l\xE1ti p\xE8s\xE8 i\u1E63\u1EB9\u0301 wa \xE0ti l\xE1ti m\xFA \xECr\xEDr\xED r\u1EB9 d\xE1ra s\xED i. A \u0144 gba \xECfoh\xF9n\u1E63\u1ECD\u0300kan r\u1EB9 g\u1EB9\u0301g\u1EB9\u0301 b\xED Abala 25-26 ti \xD2fin \xCCd\xE1\xE0b\xF2b\xF2 D\xE1t\xE0 ti N\xE0\xECj\xEDr\xED\xE0.",acceptAll:"Gba Gbogbo",rejectAll:"K\u1ECD Gbogbo",customize:"\u1E62\xE0t\xFAn\u1E63e",savePreferences:"T\u1ECD\u0301j\xFA \xC0\u1E63\xE0y\xE0n",selectAll:"Yan Gbogbo",deselectAll:"Y\u1ECD Gbogbo K\xFAr\xF2",required:"K\xF2 \u1E62e Y\u1EB9ra F\xFAn",cookieNotice:'N\xEDpa t\xEDt\u1EB9 "Gba Gbogbo", o foh\xF9n \u1E63\u1ECD\u0300kan p\u1EB9\u0300l\xFA l\xEDlo gbogbo k\xFAk\xEC. \u1E62\xE0b\u1EB9\u0300w\xF2 \xCCl\xE0n\xE0 K\xFAk\xEC wa l\xE1ti k\u1EB9\u0301k\u1ECD\u0300\u1ECD\u0301 s\xEDi.'},dsr:{title:"Fi \xCCb\xE9\xE8r\xE8 On\xED-d\xE1t\xE0 S\xEDl\u1EB9\u0300",description:"Lo f\u1ECD\u0301\u1ECD\u0300m\xF9 y\xEC\xED l\xE1ti lo \xE0w\u1ECDn \u1EB9\u0300t\u1ECD\u0301 r\u1EB9 l\xE1b\u1EB9\u0301 \xD2fin \xCCd\xE1\xE0b\xF2b\xF2 D\xE1t\xE0 ti N\xE0\xECj\xEDr\xED\xE0 (NDPA), Ap\xE1 K\u1EB9rin, Abala 29-36.",submitRequest:"Fi \xCCb\xE9\xE8r\xE8 S\xEDl\u1EB9\u0300",reset:"T\xFAn B\u1EB9\u0300r\u1EB9\u0300",fullName:"Or\xFAk\u1ECD K\xEDk\xFAn",email:"\xC0d\xEDr\u1EB9\u0301s\xEC \xCDme\xE8l\xEC",phone:"N\u1ECD\u0301mb\xE0 F\xF3\xF2n\xF9 (\xC0\u1E63\xE0y\xE0n)",requestType:"Ir\xFA \xCCb\xE9\xE8r\xE8",additionalInfo:"\xC0l\xE0y\xE9 \xC0fik\xFAn",identityVerification:"\xCCd\xE1nil\xF3j\xFA \xCCd\xE1nim\u1ECD\u0300",identifierType:"Ir\xFA \xCCd\xE1nim\u1ECD\u0300",identifierValue:"Iye \xCCd\xE1nim\u1ECD\u0300",privacyNotice:"\xC0w\u1ECDn \xECr\xF2y\xECn t\xED o b\xE1 p\xE8s\xE8 n\xEDn\xFA f\u1ECD\u0301\u1ECD\u0300m\xF9 y\xEC\xED ni a \xF3 l\xF2 f\xFAn \xE8te \u1E63\xED\u1E63e \xE0b\xF3j\xFAt\xF3 \xECb\xE9\xE8r\xE8 on\xED-d\xE1t\xE0 r\u1EB9 n\xECkan.",successMessage:"A ti fi \xECb\xE9\xE8r\xE8 r\u1EB9 s\xEDl\u1EB9\u0300 d\xE1rad\xE1ra."},breach:{title:"\u1E62e \xCCr\xF2y\xECn \xCCr\xFAfin D\xE1t\xE0",description:"Lo f\u1ECD\u0301\u1ECD\u0300m\xF9 y\xEC\xED l\xE1ti \u1E63e \xECr\xF2y\xECn \xECr\xFAfin d\xE1t\xE0 t\xED a fura s\xED t\xE0b\xED t\xED a ti fidi r\u1EB9\u0300 m\xFAl\u1EB9\u0300 g\u1EB9\u0301g\u1EB9\u0301 b\xED Abala 40 ti NDPA.",submitReport:"Fi \xCCr\xF2y\xECn S\xEDl\u1EB9\u0300",breachTitle:"\xC0k\u1ECDl\xE9/\xC0k\xF3p\u1ECD\u0300 \xCCr\xFAfin",category:"\u1EB8\u0300ka",discoveredAt:"\u1ECCj\u1ECD\u0301 T\xED A R\xED I",detailedDescription:"\xC0l\xE0y\xE9 K\xEDk\xFAn"},dpia:{title:"\xCCgb\xE9l\xE9w\u1ECD\u0300n Ipa \xCCd\xE1\xE0b\xF2b\xF2 D\xE1t\xE0",next:"T\u1EB9\u0300l\xE9",previous:"S\u1EB9\u0301y\xECn",complete:"Par\xED \xCCgb\xE9l\xE9w\u1ECD\u0300n",progress:"\xCCl\u1ECDs\xEDw\xE1j\xFA"},policy:{title:"Ol\xF9pil\u1EB9\u0300\u1E63\u1EB9\u0300 \xCCl\xE0n\xE0 \xC0\u1E63\xEDr\xED",generate:"\u1E62\u1EB9\u0300d\xE1 \xCCl\xE0n\xE0",preview:"\xC0y\u1EB9\u0300w\xF2",export:"Gb\xE9 J\xE1de",sections:"\xC0w\u1ECDn Abala",variables:"\xC0w\u1ECDn On\xEDy\xEDpad\xE0"},compliance:{score:"\xC0m\xEC \xCCb\xE1mu",excellent:"K\xF2 L\xE8 D\xE1ra Ju",good:"\xD3 D\xE1ra",needsWork:"N\xEDl\xF2 \xC0t\xFAn\u1E63e",critical:"P\xE0t\xE0k\xEC Gan",recommendations:"\xC0w\u1ECDn \xC0b\xE1",passed:"K\u1ECDj\xE1",gaps:"\xC0w\u1ECDn \xC0\xECp\xE9"},common:{loading:"\u0143 gb\xE9y\u1EB9\u0300w\xF2...",error:"\xC0\u1E63\xEC\u1E63e kan \u1E63\u1EB9l\u1EB9\u0300",save:"T\u1ECD\u0301j\xFA",cancel:"Fagil\xE9",delete:"Pa r\u1EB9\u0301",edit:"\u1E62\xE0t\xFAn\u1E63e",add:"Fik\xFAn",back:"Pad\xE0",next:"T\u1EB9\u0300l\xE9",search:"W\xE1",noResults:"K\xF2 s\xED \xE8s\xEC kankan"}};var j={consent:{title:"Any\u1ECB Na-akwanyere Nzuzo G\u1ECB \xD9gw\xF9",description:"Any\u1ECB na-eji kuki na tekn\u1ECDl\u1ECDj\u1ECB nd\u1ECB yiri ya enyere \u1ECDr\u1EE5 any\u1ECB aka ma melite ah\u1EE5m\u1ECBhe g\u1ECB. A na-anak\u1ECDta nkwenye g\u1ECB d\u1ECBka iwu NDPA Ngalaba 25-26 si kwuo.",acceptAll:"Nabata Niile",rejectAll:"J\u1EE5 Niile",customize:"Hazie",savePreferences:"Chekwaa Nh\u1ECDr\u1ECD",selectAll:"H\u1ECDr\u1ECD Niile",deselectAll:"Wep\u1EE5 Niile",required:"Ach\u1ECDr\u1ECD",cookieNotice:'Site na \u1ECBp\u1ECB "Nabata Niile", \u1ECB kwenyere na iji kuki niile. Gaa na Am\u1EE5ma Kuki any\u1ECB \u1ECBm\u1EE5takwu.'},dsr:{title:"Tinye Ar\u1ECBr\u1ECB\u1ECD Onye Nwe Data",description:"Jiri f\u1ECD\u1ECDm\u1EE5 a mee ka ikike g\u1ECB n'okpuru Iwu Nchedo Data nke Na\u1ECBjir\u1ECBa (NDPA), Nkebi An\u1ECD, Ngalaba 29-36 r\u1EE5\u1ECD \u1ECDr\u1EE5.",submitRequest:"Tinye Ar\u1ECBr\u1ECB\u1ECD",reset:"Maliteghar\u1ECBa",fullName:"Aha Zuru Oke",email:"Adrees\u1ECB Email",phone:"N\u1ECDmb\xE0 Ekwent\u1ECB (Nh\u1ECDr\u1ECD)",requestType:"\u1EE4d\u1ECB Ar\u1ECBr\u1ECB\u1ECD",additionalInfo:"Ozi Nd\u1ECB \u1ECCz\u1ECD",identityVerification:"Nyocha Njirimara",identifierType:"\u1EE4d\u1ECB Njirimara",identifierValue:"Uru Njirimara",privacyNotice:"A ga-eji ozi \u1ECB nyere na f\u1ECD\u1ECDm\u1EE5 a naan\u1ECB maka ebumnuche nke ilek\u1ECDta ar\u1ECBr\u1ECB\u1ECD onye nwe data g\u1ECB.",successMessage:"Etinyela ar\u1ECBr\u1ECB\u1ECD g\u1ECB nke \u1ECDma."},breach:{title:"K\u1ECD\u1ECD Mwap\u1EE5 Data",description:"Jiri f\u1ECD\u1ECDm\u1EE5 a k\u1ECD\u1ECD mwap\u1EE5 data a na-echere ma \u1ECD b\u1EE5 nke e gosip\u1EE5tara d\u1ECBka iwu NDPA Ngalaba 40 si kwuo.",submitReport:"Tinye Ak\u1EE5k\u1ECD",breachTitle:"Isiokwu/Nch\u1ECBk\u1ECDta Mwap\u1EE5",category:"Udi",discoveredAt:"\u1EE4b\u1ECDch\u1ECB A Ch\u1ECDp\u1EE5tara",detailedDescription:"Nk\u1ECDwa Zuru Oke"},dpia:{title:"Nyocha Mmet\u1EE5ta Nchedo Data",next:"\u1ECCz\u1ECD",previous:"Az\u1EE5",complete:"Mechaa Nyocha",progress:"\u1ECCganihu"},policy:{title:"Ngwa Mmep\u1EE5ta Am\u1EE5ma Nzuzo",generate:"Mep\u1EE5ta Am\u1EE5ma",preview:"Lelee",export:"Bup\u1EE5ta",sections:"Ngalaba",variables:"Mgbanwe"},compliance:{score:"Akara Ndabere",excellent:"Kachas\u1ECB Mma",good:"\u1ECC D\u1ECB Mma",needsWork:"Ch\u1ECDr\u1ECD Mmezighar\u1ECB",critical:"D\u1ECB Oke Mkpa",recommendations:"Nd\u1EE5m\u1ECDd\u1EE5",passed:"Gafere",gaps:"Oghere"},common:{loading:"Na-ebugo...",error:"Mperi mere",save:"Chekwaa",cancel:"Kagbuo",delete:"Hichap\u1EE5",edit:"Dezie",add:"Tinye",back:"Laghachi",next:"\u1ECCz\u1ECD",search:"Ch\u1ECD\u1ECD",noResults:"Enwegh\u1ECB nsonaaz\u1EE5"}};var G={consent:{title:"Muna Daraja Sirrin Ka",description:"Muna amfani da kukis da fasahohi irin su don samar da ayyukanmu da inganta kwarewar ka. Ana tattara yardar ka bisa ga Sashe na 25-26 na Dokar Kare Bayanan Nijeriya.",acceptAll:"Kar\u0253i Duka",rejectAll:"\u0198i Duka",customize:"Gyara Za\u0253i",savePreferences:"Ajiye Za\u0253u\u0253\u0253uka",selectAll:"Za\u0253i Duka",deselectAll:"Cire Duka",required:"Wajibi Ne",cookieNotice:'Ta hanyar danna "Kar\u0253i Duka", ka yarda da amfani da dukkan kukis. Ziyarci Manufar Kukis don \u0199arin bayani.'},dsr:{title:"\u0198addamar da Bu\u0199atar Mai Bayanan",description:"Yi amfani da wannan fom don aiwatar da ha\u0199\u0199o\u0199in ka a \u0199ar\u0199ashin Dokar Kare Bayanan Nijeriya (NDPA), Bangare na Hu\u0257u, Sashe 29-36.",submitRequest:"\u0198addamar da Bu\u0199ata",reset:"Sake Saiti",fullName:"Sunan Cikakke",email:"Adireshin Imel",phone:"Lambar Waya (Na Za\u0253i)",requestType:"Nau'in Bu\u0199ata",additionalInfo:"\u0198arin Bayani",identityVerification:"Tabbatar da Ainihi",identifierType:"Nau'in Ganewa",identifierValue:"Darajar Ganewa",privacyNotice:"Za a yi amfani da bayanan da ka bayar a cikin wannan fom ne kawai don sarrafa bu\u0199atar mai bayanan ka.",successMessage:"An \u0199addamar da bu\u0199atar ka cikin nasara."},breach:{title:"Bayar da Rahoton Karya Bayanan",description:"Yi amfani da wannan fom don bayar da rahoton zargin ko tabbatar da karya bayanan bisa ga Sashe na 40 na NDPA.",submitReport:"\u0198addamar da Rahoto",breachTitle:"Taken/Ta\u0199aitaccen Karya",category:"Rukunin",discoveredAt:"Ranar da Aka Gano",detailedDescription:"Cikakken Bayani"},dpia:{title:"Tantance Tasirin Kare Bayanan",next:"Na Gaba",previous:"Na Baya",complete:"Kammala Tantancewa",progress:"Ci Gaba"},policy:{title:"Mai \u0198ir\u0199irar Manufar Sirri",generate:"\u0198ir\u0199iri Manufa",preview:"Duba",export:"Fitar",sections:"Sassa",variables:"Masu Canjin"},compliance:{score:"Makin Bin Doka",excellent:"Kyakkyawa Sosai",good:"Mai Kyau",needsWork:"Yana Bu\u0199atar Gyara",critical:"Mai Muhimmanci",recommendations:"Shawarwari",passed:"Ya Wuce",gaps:"Gi\u0253i"},common:{loading:"Ana lodawa...",error:"Kuskure ya faru",save:"Ajiye",cancel:"Soke",delete:"Goge",edit:"Gyara",add:"\u0198ara",back:"Komawa",next:"Na Gaba",search:"Bincika",noResults:"Ba a sami sakamako ba"}};Object.defineProperty(exports,"NDPRProvider",{enumerable:true,get:function(){return chunkUGY5ZYUG_js.c}});Object.defineProperty(exports,"defaultLocale",{enumerable:true,get:function(){return chunkUGY5ZYUG_js.a}});Object.defineProperty(exports,"mergeLocale",{enumerable:true,get:function(){return chunkUGY5ZYUG_js.b}});Object.defineProperty(exports,"useNDPRConfig",{enumerable:true,get:function(){return chunkUGY5ZYUG_js.d}});Object.defineProperty(exports,"useNDPRLocale",{enumerable:true,get:function(){return chunkUGY5ZYUG_js.e}});Object.defineProperty(exports,"getComplianceScore",{enumerable:true,get:function(){return chunkS4GRSNB4_js.a}});Object.defineProperty(exports,"assessComplianceGaps",{enumerable:true,get:function(){return chunkTDDAYVKK_js.c}});Object.defineProperty(exports,"generateLawfulBasisSummary",{enumerable:true,get:function(){return chunkTDDAYVKK_js.d}});Object.defineProperty(exports,"getLawfulBasisDescription",{enumerable:true,get:function(){return chunkTDDAYVKK_js.b}});Object.defineProperty(exports,"validateProcessingActivity",{enumerable:true,get:function(){return chunkTDDAYVKK_js.a}});Object.defineProperty(exports,"assessTransferRisk",{enumerable:true,get:function(){return chunkC4YM4UMI_js.h}});Object.defineProperty(exports,"getTransferMechanismDescription",{enumerable:true,get:function(){return chunkC4YM4UMI_js.f}});Object.defineProperty(exports,"isNDPCApprovalRequired",{enumerable:true,get:function(){return chunkC4YM4UMI_js.e}});Object.defineProperty(exports,"validateTransfer",{enumerable:true,get:function(){return chunkC4YM4UMI_js.g}});Object.defineProperty(exports,"exportROPAToCSV",{enumerable:true,get:function(){return chunkGOU6FU6Y_js.c}});Object.defineProperty(exports,"generateROPASummary",{enumerable:true,get:function(){return chunkGOU6FU6Y_js.b}});Object.defineProperty(exports,"identifyComplianceGaps",{enumerable:true,get:function(){return chunkGOU6FU6Y_js.d}});Object.defineProperty(exports,"validateProcessingRecord",{enumerable:true,get:function(){return chunkGOU6FU6Y_js.a}});Object.defineProperty(exports,"appendAuditEntry",{enumerable:true,get:function(){return chunkMJGOLP5M_js.c}});Object.defineProperty(exports,"createAuditEntry",{enumerable:true,get:function(){return chunkMJGOLP5M_js.a}});Object.defineProperty(exports,"getAuditLog",{enumerable:true,get:function(){return chunkMJGOLP5M_js.b}});Object.defineProperty(exports,"validateConsent",{enumerable:true,get:function(){return chunkHO5M7M4M_js.a}});Object.defineProperty(exports,"validateConsentOptions",{enumerable:true,get:function(){return chunkHO5M7M4M_js.b}});Object.defineProperty(exports,"formatDSRRequest",{enumerable:true,get:function(){return chunkJKKRPS4P_js.a}});Object.defineProperty(exports,"assessDPIARisk",{enumerable:true,get:function(){return chunkP42Z5CFE_js.a}});Object.defineProperty(exports,"calculateBreachSeverity",{enumerable:true,get:function(){return chunkBKRETVJ6_js.a}});Object.defineProperty(exports,"sanitizeInput",{enumerable:true,get:function(){return chunkI54CDQGN_js.a}});Object.defineProperty(exports,"assemblePolicy",{enumerable:true,get:function(){return chunkLU4PFST7_js.d}});Object.defineProperty(exports,"createDefaultContext",{enumerable:true,get:function(){return chunkLU4PFST7_js.b}});Object.defineProperty(exports,"evaluatePolicyCompliance",{enumerable:true,get:function(){return chunkLU4PFST7_js.c}});Object.defineProperty(exports,"DEFAULT_POLICY_SECTIONS",{enumerable:true,get:function(){return chunkUXMGBIX6_js.b}});Object.defineProperty(exports,"DEFAULT_POLICY_VARIABLES",{enumerable:true,get:function(){return chunkUXMGBIX6_js.c}});Object.defineProperty(exports,"createBusinessPolicyTemplate",{enumerable:true,get:function(){return chunkUXMGBIX6_js.d}});Object.defineProperty(exports,"generatePolicyText",{enumerable:true,get:function(){return chunkUXMGBIX6_js.a}});exports.hausaLocale=G;exports.igboLocale=j;exports.yorubaLocale=M;//# sourceMappingURL=core.js.map
2
2
  //# sourceMappingURL=core.js.map
package/dist/core.mjs CHANGED
@@ -1,2 +1,2 @@
1
- export{c as NDPRProvider,a as defaultLocale,b as mergeLocale,d as useNDPRConfig,e as useNDPRLocale}from'./chunk-TVW6KBVV.mjs';export{a as getComplianceScore}from'./chunk-ABDB7LEV.mjs';export{c as assessComplianceGaps,d as generateLawfulBasisSummary,b as getLawfulBasisDescription,a as validateProcessingActivity}from'./chunk-TXBZPCGF.mjs';export{d as assessTransferRisk,b as getTransferMechanismDescription,a as isNDPCApprovalRequired,c as validateTransfer}from'./chunk-QKK5S54L.mjs';export{c as exportROPAToCSV,b as generateROPASummary,d as identifyComplianceGaps,a as validateProcessingRecord}from'./chunk-SHMJNRHO.mjs';export{c as appendAuditEntry,a as createAuditEntry,b as getAuditLog}from'./chunk-P3PULLYP.mjs';export{a as validateConsent,b as validateConsentOptions}from'./chunk-U62QYKVG.mjs';export{a as formatDSRRequest}from'./chunk-NXQMU36Z.mjs';export{a as assessDPIARisk}from'./chunk-6TA2MVTU.mjs';export{a as calculateBreachSeverity}from'./chunk-DJGS7SSN.mjs';export{a as sanitizeInput}from'./chunk-GKKAK6ES.mjs';export{d as assemblePolicy,b as createDefaultContext,c as evaluatePolicyCompliance}from'./chunk-GCQRHMTQ.mjs';export{b as DEFAULT_POLICY_SECTIONS,c as DEFAULT_POLICY_VARIABLES,d as createBusinessPolicyTemplate,a as generatePolicyText}from'./chunk-ZEOQYWOE.mjs';import'./chunk-WWT2ZSNU.mjs';//# sourceMappingURL=core.mjs.map
1
+ export{c as NDPRProvider,a as defaultLocale,b as mergeLocale,d as useNDPRConfig,e as useNDPRLocale}from'./chunk-LETEUS5X.mjs';export{a as getComplianceScore}from'./chunk-ABDB7LEV.mjs';export{c as assessComplianceGaps,d as generateLawfulBasisSummary,b as getLawfulBasisDescription,a as validateProcessingActivity}from'./chunk-TXBZPCGF.mjs';export{h as assessTransferRisk,f as getTransferMechanismDescription,e as isNDPCApprovalRequired,g as validateTransfer}from'./chunk-75TJPK2N.mjs';export{c as exportROPAToCSV,b as generateROPASummary,d as identifyComplianceGaps,a as validateProcessingRecord}from'./chunk-SHMJNRHO.mjs';export{c as appendAuditEntry,a as createAuditEntry,b as getAuditLog}from'./chunk-P3PULLYP.mjs';export{a as validateConsent,b as validateConsentOptions}from'./chunk-U62QYKVG.mjs';export{a as formatDSRRequest}from'./chunk-7D2OIPHH.mjs';export{a as assessDPIARisk}from'./chunk-6TA2MVTU.mjs';export{a as calculateBreachSeverity}from'./chunk-DJGS7SSN.mjs';export{a as sanitizeInput}from'./chunk-GKKAK6ES.mjs';export{d as assemblePolicy,b as createDefaultContext,c as evaluatePolicyCompliance}from'./chunk-GCQRHMTQ.mjs';export{b as DEFAULT_POLICY_SECTIONS,c as DEFAULT_POLICY_VARIABLES,d as createBusinessPolicyTemplate,a as generatePolicyText}from'./chunk-ZEOQYWOE.mjs';import'./chunk-WWT2ZSNU.mjs';var M={consent:{title:"A M\u1ECDy\xEC \xC0\u1E63\xEDr\xED R\u1EB9",description:"A \u0144 lo k\xFAk\xEC \xE0ti \xE0w\u1ECDn \xECm\u1ECD\u0300-\u1EB9\u0300r\u1ECD t\xF3 j\u1ECDra l\xE1ti p\xE8s\xE8 i\u1E63\u1EB9\u0301 wa \xE0ti l\xE1ti m\xFA \xECr\xEDr\xED r\u1EB9 d\xE1ra s\xED i. A \u0144 gba \xECfoh\xF9n\u1E63\u1ECD\u0300kan r\u1EB9 g\u1EB9\u0301g\u1EB9\u0301 b\xED Abala 25-26 ti \xD2fin \xCCd\xE1\xE0b\xF2b\xF2 D\xE1t\xE0 ti N\xE0\xECj\xEDr\xED\xE0.",acceptAll:"Gba Gbogbo",rejectAll:"K\u1ECD Gbogbo",customize:"\u1E62\xE0t\xFAn\u1E63e",savePreferences:"T\u1ECD\u0301j\xFA \xC0\u1E63\xE0y\xE0n",selectAll:"Yan Gbogbo",deselectAll:"Y\u1ECD Gbogbo K\xFAr\xF2",required:"K\xF2 \u1E62e Y\u1EB9ra F\xFAn",cookieNotice:'N\xEDpa t\xEDt\u1EB9 "Gba Gbogbo", o foh\xF9n \u1E63\u1ECD\u0300kan p\u1EB9\u0300l\xFA l\xEDlo gbogbo k\xFAk\xEC. \u1E62\xE0b\u1EB9\u0300w\xF2 \xCCl\xE0n\xE0 K\xFAk\xEC wa l\xE1ti k\u1EB9\u0301k\u1ECD\u0300\u1ECD\u0301 s\xEDi.'},dsr:{title:"Fi \xCCb\xE9\xE8r\xE8 On\xED-d\xE1t\xE0 S\xEDl\u1EB9\u0300",description:"Lo f\u1ECD\u0301\u1ECD\u0300m\xF9 y\xEC\xED l\xE1ti lo \xE0w\u1ECDn \u1EB9\u0300t\u1ECD\u0301 r\u1EB9 l\xE1b\u1EB9\u0301 \xD2fin \xCCd\xE1\xE0b\xF2b\xF2 D\xE1t\xE0 ti N\xE0\xECj\xEDr\xED\xE0 (NDPA), Ap\xE1 K\u1EB9rin, Abala 29-36.",submitRequest:"Fi \xCCb\xE9\xE8r\xE8 S\xEDl\u1EB9\u0300",reset:"T\xFAn B\u1EB9\u0300r\u1EB9\u0300",fullName:"Or\xFAk\u1ECD K\xEDk\xFAn",email:"\xC0d\xEDr\u1EB9\u0301s\xEC \xCDme\xE8l\xEC",phone:"N\u1ECD\u0301mb\xE0 F\xF3\xF2n\xF9 (\xC0\u1E63\xE0y\xE0n)",requestType:"Ir\xFA \xCCb\xE9\xE8r\xE8",additionalInfo:"\xC0l\xE0y\xE9 \xC0fik\xFAn",identityVerification:"\xCCd\xE1nil\xF3j\xFA \xCCd\xE1nim\u1ECD\u0300",identifierType:"Ir\xFA \xCCd\xE1nim\u1ECD\u0300",identifierValue:"Iye \xCCd\xE1nim\u1ECD\u0300",privacyNotice:"\xC0w\u1ECDn \xECr\xF2y\xECn t\xED o b\xE1 p\xE8s\xE8 n\xEDn\xFA f\u1ECD\u0301\u1ECD\u0300m\xF9 y\xEC\xED ni a \xF3 l\xF2 f\xFAn \xE8te \u1E63\xED\u1E63e \xE0b\xF3j\xFAt\xF3 \xECb\xE9\xE8r\xE8 on\xED-d\xE1t\xE0 r\u1EB9 n\xECkan.",successMessage:"A ti fi \xECb\xE9\xE8r\xE8 r\u1EB9 s\xEDl\u1EB9\u0300 d\xE1rad\xE1ra."},breach:{title:"\u1E62e \xCCr\xF2y\xECn \xCCr\xFAfin D\xE1t\xE0",description:"Lo f\u1ECD\u0301\u1ECD\u0300m\xF9 y\xEC\xED l\xE1ti \u1E63e \xECr\xF2y\xECn \xECr\xFAfin d\xE1t\xE0 t\xED a fura s\xED t\xE0b\xED t\xED a ti fidi r\u1EB9\u0300 m\xFAl\u1EB9\u0300 g\u1EB9\u0301g\u1EB9\u0301 b\xED Abala 40 ti NDPA.",submitReport:"Fi \xCCr\xF2y\xECn S\xEDl\u1EB9\u0300",breachTitle:"\xC0k\u1ECDl\xE9/\xC0k\xF3p\u1ECD\u0300 \xCCr\xFAfin",category:"\u1EB8\u0300ka",discoveredAt:"\u1ECCj\u1ECD\u0301 T\xED A R\xED I",detailedDescription:"\xC0l\xE0y\xE9 K\xEDk\xFAn"},dpia:{title:"\xCCgb\xE9l\xE9w\u1ECD\u0300n Ipa \xCCd\xE1\xE0b\xF2b\xF2 D\xE1t\xE0",next:"T\u1EB9\u0300l\xE9",previous:"S\u1EB9\u0301y\xECn",complete:"Par\xED \xCCgb\xE9l\xE9w\u1ECD\u0300n",progress:"\xCCl\u1ECDs\xEDw\xE1j\xFA"},policy:{title:"Ol\xF9pil\u1EB9\u0300\u1E63\u1EB9\u0300 \xCCl\xE0n\xE0 \xC0\u1E63\xEDr\xED",generate:"\u1E62\u1EB9\u0300d\xE1 \xCCl\xE0n\xE0",preview:"\xC0y\u1EB9\u0300w\xF2",export:"Gb\xE9 J\xE1de",sections:"\xC0w\u1ECDn Abala",variables:"\xC0w\u1ECDn On\xEDy\xEDpad\xE0"},compliance:{score:"\xC0m\xEC \xCCb\xE1mu",excellent:"K\xF2 L\xE8 D\xE1ra Ju",good:"\xD3 D\xE1ra",needsWork:"N\xEDl\xF2 \xC0t\xFAn\u1E63e",critical:"P\xE0t\xE0k\xEC Gan",recommendations:"\xC0w\u1ECDn \xC0b\xE1",passed:"K\u1ECDj\xE1",gaps:"\xC0w\u1ECDn \xC0\xECp\xE9"},common:{loading:"\u0143 gb\xE9y\u1EB9\u0300w\xF2...",error:"\xC0\u1E63\xEC\u1E63e kan \u1E63\u1EB9l\u1EB9\u0300",save:"T\u1ECD\u0301j\xFA",cancel:"Fagil\xE9",delete:"Pa r\u1EB9\u0301",edit:"\u1E62\xE0t\xFAn\u1E63e",add:"Fik\xFAn",back:"Pad\xE0",next:"T\u1EB9\u0300l\xE9",search:"W\xE1",noResults:"K\xF2 s\xED \xE8s\xEC kankan"}};var j={consent:{title:"Any\u1ECB Na-akwanyere Nzuzo G\u1ECB \xD9gw\xF9",description:"Any\u1ECB na-eji kuki na tekn\u1ECDl\u1ECDj\u1ECB nd\u1ECB yiri ya enyere \u1ECDr\u1EE5 any\u1ECB aka ma melite ah\u1EE5m\u1ECBhe g\u1ECB. A na-anak\u1ECDta nkwenye g\u1ECB d\u1ECBka iwu NDPA Ngalaba 25-26 si kwuo.",acceptAll:"Nabata Niile",rejectAll:"J\u1EE5 Niile",customize:"Hazie",savePreferences:"Chekwaa Nh\u1ECDr\u1ECD",selectAll:"H\u1ECDr\u1ECD Niile",deselectAll:"Wep\u1EE5 Niile",required:"Ach\u1ECDr\u1ECD",cookieNotice:'Site na \u1ECBp\u1ECB "Nabata Niile", \u1ECB kwenyere na iji kuki niile. Gaa na Am\u1EE5ma Kuki any\u1ECB \u1ECBm\u1EE5takwu.'},dsr:{title:"Tinye Ar\u1ECBr\u1ECB\u1ECD Onye Nwe Data",description:"Jiri f\u1ECD\u1ECDm\u1EE5 a mee ka ikike g\u1ECB n'okpuru Iwu Nchedo Data nke Na\u1ECBjir\u1ECBa (NDPA), Nkebi An\u1ECD, Ngalaba 29-36 r\u1EE5\u1ECD \u1ECDr\u1EE5.",submitRequest:"Tinye Ar\u1ECBr\u1ECB\u1ECD",reset:"Maliteghar\u1ECBa",fullName:"Aha Zuru Oke",email:"Adrees\u1ECB Email",phone:"N\u1ECDmb\xE0 Ekwent\u1ECB (Nh\u1ECDr\u1ECD)",requestType:"\u1EE4d\u1ECB Ar\u1ECBr\u1ECB\u1ECD",additionalInfo:"Ozi Nd\u1ECB \u1ECCz\u1ECD",identityVerification:"Nyocha Njirimara",identifierType:"\u1EE4d\u1ECB Njirimara",identifierValue:"Uru Njirimara",privacyNotice:"A ga-eji ozi \u1ECB nyere na f\u1ECD\u1ECDm\u1EE5 a naan\u1ECB maka ebumnuche nke ilek\u1ECDta ar\u1ECBr\u1ECB\u1ECD onye nwe data g\u1ECB.",successMessage:"Etinyela ar\u1ECBr\u1ECB\u1ECD g\u1ECB nke \u1ECDma."},breach:{title:"K\u1ECD\u1ECD Mwap\u1EE5 Data",description:"Jiri f\u1ECD\u1ECDm\u1EE5 a k\u1ECD\u1ECD mwap\u1EE5 data a na-echere ma \u1ECD b\u1EE5 nke e gosip\u1EE5tara d\u1ECBka iwu NDPA Ngalaba 40 si kwuo.",submitReport:"Tinye Ak\u1EE5k\u1ECD",breachTitle:"Isiokwu/Nch\u1ECBk\u1ECDta Mwap\u1EE5",category:"Udi",discoveredAt:"\u1EE4b\u1ECDch\u1ECB A Ch\u1ECDp\u1EE5tara",detailedDescription:"Nk\u1ECDwa Zuru Oke"},dpia:{title:"Nyocha Mmet\u1EE5ta Nchedo Data",next:"\u1ECCz\u1ECD",previous:"Az\u1EE5",complete:"Mechaa Nyocha",progress:"\u1ECCganihu"},policy:{title:"Ngwa Mmep\u1EE5ta Am\u1EE5ma Nzuzo",generate:"Mep\u1EE5ta Am\u1EE5ma",preview:"Lelee",export:"Bup\u1EE5ta",sections:"Ngalaba",variables:"Mgbanwe"},compliance:{score:"Akara Ndabere",excellent:"Kachas\u1ECB Mma",good:"\u1ECC D\u1ECB Mma",needsWork:"Ch\u1ECDr\u1ECD Mmezighar\u1ECB",critical:"D\u1ECB Oke Mkpa",recommendations:"Nd\u1EE5m\u1ECDd\u1EE5",passed:"Gafere",gaps:"Oghere"},common:{loading:"Na-ebugo...",error:"Mperi mere",save:"Chekwaa",cancel:"Kagbuo",delete:"Hichap\u1EE5",edit:"Dezie",add:"Tinye",back:"Laghachi",next:"\u1ECCz\u1ECD",search:"Ch\u1ECD\u1ECD",noResults:"Enwegh\u1ECB nsonaaz\u1EE5"}};var G={consent:{title:"Muna Daraja Sirrin Ka",description:"Muna amfani da kukis da fasahohi irin su don samar da ayyukanmu da inganta kwarewar ka. Ana tattara yardar ka bisa ga Sashe na 25-26 na Dokar Kare Bayanan Nijeriya.",acceptAll:"Kar\u0253i Duka",rejectAll:"\u0198i Duka",customize:"Gyara Za\u0253i",savePreferences:"Ajiye Za\u0253u\u0253\u0253uka",selectAll:"Za\u0253i Duka",deselectAll:"Cire Duka",required:"Wajibi Ne",cookieNotice:'Ta hanyar danna "Kar\u0253i Duka", ka yarda da amfani da dukkan kukis. Ziyarci Manufar Kukis don \u0199arin bayani.'},dsr:{title:"\u0198addamar da Bu\u0199atar Mai Bayanan",description:"Yi amfani da wannan fom don aiwatar da ha\u0199\u0199o\u0199in ka a \u0199ar\u0199ashin Dokar Kare Bayanan Nijeriya (NDPA), Bangare na Hu\u0257u, Sashe 29-36.",submitRequest:"\u0198addamar da Bu\u0199ata",reset:"Sake Saiti",fullName:"Sunan Cikakke",email:"Adireshin Imel",phone:"Lambar Waya (Na Za\u0253i)",requestType:"Nau'in Bu\u0199ata",additionalInfo:"\u0198arin Bayani",identityVerification:"Tabbatar da Ainihi",identifierType:"Nau'in Ganewa",identifierValue:"Darajar Ganewa",privacyNotice:"Za a yi amfani da bayanan da ka bayar a cikin wannan fom ne kawai don sarrafa bu\u0199atar mai bayanan ka.",successMessage:"An \u0199addamar da bu\u0199atar ka cikin nasara."},breach:{title:"Bayar da Rahoton Karya Bayanan",description:"Yi amfani da wannan fom don bayar da rahoton zargin ko tabbatar da karya bayanan bisa ga Sashe na 40 na NDPA.",submitReport:"\u0198addamar da Rahoto",breachTitle:"Taken/Ta\u0199aitaccen Karya",category:"Rukunin",discoveredAt:"Ranar da Aka Gano",detailedDescription:"Cikakken Bayani"},dpia:{title:"Tantance Tasirin Kare Bayanan",next:"Na Gaba",previous:"Na Baya",complete:"Kammala Tantancewa",progress:"Ci Gaba"},policy:{title:"Mai \u0198ir\u0199irar Manufar Sirri",generate:"\u0198ir\u0199iri Manufa",preview:"Duba",export:"Fitar",sections:"Sassa",variables:"Masu Canjin"},compliance:{score:"Makin Bin Doka",excellent:"Kyakkyawa Sosai",good:"Mai Kyau",needsWork:"Yana Bu\u0199atar Gyara",critical:"Mai Muhimmanci",recommendations:"Shawarwari",passed:"Ya Wuce",gaps:"Gi\u0253i"},common:{loading:"Ana lodawa...",error:"Kuskure ya faru",save:"Ajiye",cancel:"Soke",delete:"Goge",edit:"Gyara",add:"\u0198ara",back:"Komawa",next:"Na Gaba",search:"Bincika",noResults:"Ba a sami sakamako ba"}};export{G as hausaLocale,j as igboLocale,M as yorubaLocale};//# sourceMappingURL=core.mjs.map
2
2
  //# sourceMappingURL=core.mjs.map
@@ -9,6 +9,73 @@ import * as React from 'react';
9
9
  import React__default from 'react';
10
10
  import { S as StorageAdapter } from './types-DK2CoKOC.mjs';
11
11
 
12
+ /**
13
+ * Country adequacy determinations for cross-border data transfers
14
+ * under the Nigeria Data Protection Act (NDPA).
15
+ *
16
+ * This module provides a reference database of adequacy statuses for countries
17
+ * that Nigerian businesses commonly transfer personal data to, along with
18
+ * helper functions for querying adequacy and determining whether NDPC approval
19
+ * is required for a given destination.
20
+ */
21
+ /**
22
+ * Adequacy status of a country for cross-border data transfers.
23
+ */
24
+ type CountryAdequacyStatus = 'adequate' | 'partially_adequate' | 'not_adequate' | 'pending';
25
+ /**
26
+ * Represents a country's adequacy determination for cross-border data transfers.
27
+ */
28
+ interface CountryAdequacy {
29
+ /** Full country name */
30
+ country: string;
31
+ /** ISO 3166-1 alpha-2 country code */
32
+ isoCode: string;
33
+ /** Adequacy status for data protection purposes */
34
+ adequacyStatus: CountryAdequacyStatus;
35
+ /** Authority or framework that recognized the adequacy (e.g. 'NDPC', 'EU') */
36
+ recognizedBy: string;
37
+ /** Additional notes about the adequacy determination */
38
+ notes: string;
39
+ /** Date the adequacy determination was last reviewed */
40
+ lastUpdated: string;
41
+ }
42
+ /**
43
+ * Database of country adequacy determinations for cross-border data transfers.
44
+ *
45
+ * This map is keyed by ISO 3166-1 alpha-2 country code (uppercase).
46
+ * Statuses reflect general assessments based on each country's data protection
47
+ * framework and are provided for guidance purposes. Organizations should verify
48
+ * current NDPC guidance before relying on these determinations.
49
+ */
50
+ declare const COUNTRY_ADEQUACY_MAP: Record<string, CountryAdequacy>;
51
+ /**
52
+ * Look up the adequacy determination for a country by name or ISO code.
53
+ *
54
+ * The search is case-insensitive and matches against both the `country` field
55
+ * and the `isoCode` field.
56
+ *
57
+ * @param countryOrCode A country name (e.g. "Germany") or ISO 3166-1 alpha-2 code (e.g. "DE")
58
+ * @returns The matching CountryAdequacy entry, or undefined if not found
59
+ */
60
+ declare function getCountryAdequacy(countryOrCode: string): CountryAdequacy | undefined;
61
+ /**
62
+ * Returns all countries that are considered adequate for cross-border data transfers.
63
+ *
64
+ * @returns Array of CountryAdequacy entries with adequacyStatus === 'adequate'
65
+ */
66
+ declare function getAdequateCountries(): CountryAdequacy[];
67
+ /**
68
+ * Determines whether a transfer to the specified country requires NDPC approval.
69
+ *
70
+ * Countries that are not in the adequacy database or that have a status other
71
+ * than 'adequate' require NDPC approval (or an alternative transfer mechanism
72
+ * such as standard contractual clauses or binding corporate rules).
73
+ *
74
+ * @param countryOrCode A country name or ISO 3166-1 alpha-2 code
75
+ * @returns true if NDPC approval is likely required for transfers to this country
76
+ */
77
+ declare function requiresNDPCApproval(countryOrCode: string): boolean;
78
+
12
79
  interface CrossBorderProviderProps {
13
80
  adapter?: StorageAdapter<CrossBorderTransfer[]>;
14
81
  storageKey?: string;
@@ -29,4 +96,4 @@ declare const CrossBorder: {
29
96
  type CrossBorderContextValue = UseCrossBorderTransferReturn;
30
97
  declare function useCrossBorderCompound(): CrossBorderContextValue;
31
98
 
32
- export { CrossBorder, CrossBorderProvider, type CrossBorderProviderProps, CrossBorderTransfer, StorageAdapter, UseCrossBorderTransferReturn, useCrossBorderCompound };
99
+ export { COUNTRY_ADEQUACY_MAP, type CountryAdequacy, type CountryAdequacyStatus, CrossBorder, CrossBorderProvider, type CrossBorderProviderProps, CrossBorderTransfer, StorageAdapter, UseCrossBorderTransferReturn, getAdequateCountries, getCountryAdequacy, requiresNDPCApproval, useCrossBorderCompound };
@@ -9,6 +9,73 @@ import * as React from 'react';
9
9
  import React__default from 'react';
10
10
  import { S as StorageAdapter } from './types-DK2CoKOC.js';
11
11
 
12
+ /**
13
+ * Country adequacy determinations for cross-border data transfers
14
+ * under the Nigeria Data Protection Act (NDPA).
15
+ *
16
+ * This module provides a reference database of adequacy statuses for countries
17
+ * that Nigerian businesses commonly transfer personal data to, along with
18
+ * helper functions for querying adequacy and determining whether NDPC approval
19
+ * is required for a given destination.
20
+ */
21
+ /**
22
+ * Adequacy status of a country for cross-border data transfers.
23
+ */
24
+ type CountryAdequacyStatus = 'adequate' | 'partially_adequate' | 'not_adequate' | 'pending';
25
+ /**
26
+ * Represents a country's adequacy determination for cross-border data transfers.
27
+ */
28
+ interface CountryAdequacy {
29
+ /** Full country name */
30
+ country: string;
31
+ /** ISO 3166-1 alpha-2 country code */
32
+ isoCode: string;
33
+ /** Adequacy status for data protection purposes */
34
+ adequacyStatus: CountryAdequacyStatus;
35
+ /** Authority or framework that recognized the adequacy (e.g. 'NDPC', 'EU') */
36
+ recognizedBy: string;
37
+ /** Additional notes about the adequacy determination */
38
+ notes: string;
39
+ /** Date the adequacy determination was last reviewed */
40
+ lastUpdated: string;
41
+ }
42
+ /**
43
+ * Database of country adequacy determinations for cross-border data transfers.
44
+ *
45
+ * This map is keyed by ISO 3166-1 alpha-2 country code (uppercase).
46
+ * Statuses reflect general assessments based on each country's data protection
47
+ * framework and are provided for guidance purposes. Organizations should verify
48
+ * current NDPC guidance before relying on these determinations.
49
+ */
50
+ declare const COUNTRY_ADEQUACY_MAP: Record<string, CountryAdequacy>;
51
+ /**
52
+ * Look up the adequacy determination for a country by name or ISO code.
53
+ *
54
+ * The search is case-insensitive and matches against both the `country` field
55
+ * and the `isoCode` field.
56
+ *
57
+ * @param countryOrCode A country name (e.g. "Germany") or ISO 3166-1 alpha-2 code (e.g. "DE")
58
+ * @returns The matching CountryAdequacy entry, or undefined if not found
59
+ */
60
+ declare function getCountryAdequacy(countryOrCode: string): CountryAdequacy | undefined;
61
+ /**
62
+ * Returns all countries that are considered adequate for cross-border data transfers.
63
+ *
64
+ * @returns Array of CountryAdequacy entries with adequacyStatus === 'adequate'
65
+ */
66
+ declare function getAdequateCountries(): CountryAdequacy[];
67
+ /**
68
+ * Determines whether a transfer to the specified country requires NDPC approval.
69
+ *
70
+ * Countries that are not in the adequacy database or that have a status other
71
+ * than 'adequate' require NDPC approval (or an alternative transfer mechanism
72
+ * such as standard contractual clauses or binding corporate rules).
73
+ *
74
+ * @param countryOrCode A country name or ISO 3166-1 alpha-2 code
75
+ * @returns true if NDPC approval is likely required for transfers to this country
76
+ */
77
+ declare function requiresNDPCApproval(countryOrCode: string): boolean;
78
+
12
79
  interface CrossBorderProviderProps {
13
80
  adapter?: StorageAdapter<CrossBorderTransfer[]>;
14
81
  storageKey?: string;
@@ -29,4 +96,4 @@ declare const CrossBorder: {
29
96
  type CrossBorderContextValue = UseCrossBorderTransferReturn;
30
97
  declare function useCrossBorderCompound(): CrossBorderContextValue;
31
98
 
32
- export { CrossBorder, CrossBorderProvider, type CrossBorderProviderProps, CrossBorderTransfer, StorageAdapter, UseCrossBorderTransferReturn, useCrossBorderCompound };
99
+ export { COUNTRY_ADEQUACY_MAP, type CountryAdequacy, type CountryAdequacyStatus, CrossBorder, CrossBorderProvider, type CrossBorderProviderProps, CrossBorderTransfer, StorageAdapter, UseCrossBorderTransferReturn, getAdequateCountries, getCountryAdequacy, requiresNDPCApproval, useCrossBorderCompound };
@@ -1,2 +1,2 @@
1
- 'use strict';var chunkCL53OI3I_js=require('./chunk-CL53OI3I.js'),chunkKBP26GLC_js=require('./chunk-KBP26GLC.js'),chunkIQF726GS_js=require('./chunk-IQF726GS.js');require('./chunk-E64TU6IU.js'),require('./chunk-ELKB2AFZ.js'),require('./chunk-MQFZHA2D.js');var react=require('react'),jsxRuntime=require('react/jsx-runtime');var t=react.createContext(null);function P(){let r=react.useContext(t);if(!r)throw new Error("CrossBorder compound components must be wrapped in <CrossBorder.Provider>. Example: <CrossBorder.Provider><CrossBorder.Manager /></CrossBorder.Provider>");return r}var e=({adapter:r,storageKey:d,useLocalStorage:a,initialTransfers:n,onAdd:p,onUpdate:C,onRemove:f,children:i})=>{let m=chunkKBP26GLC_js.a({adapter:r,storageKey:d,useLocalStorage:a,initialTransfers:n,onAdd:p,onUpdate:C,onRemove:f});return jsxRuntime.jsx(t.Provider,{value:m,children:i})};var y={Provider:e,Manager:chunkCL53OI3I_js.a};Object.defineProperty(exports,"CrossBorderTransferManager",{enumerable:true,get:function(){return chunkCL53OI3I_js.a}});Object.defineProperty(exports,"useCrossBorderTransfer",{enumerable:true,get:function(){return chunkKBP26GLC_js.a}});Object.defineProperty(exports,"assessTransferRisk",{enumerable:true,get:function(){return chunkIQF726GS_js.d}});Object.defineProperty(exports,"getTransferMechanismDescription",{enumerable:true,get:function(){return chunkIQF726GS_js.b}});Object.defineProperty(exports,"isNDPCApprovalRequired",{enumerable:true,get:function(){return chunkIQF726GS_js.a}});Object.defineProperty(exports,"validateTransfer",{enumerable:true,get:function(){return chunkIQF726GS_js.c}});exports.CrossBorder=y;exports.CrossBorderProvider=e;exports.useCrossBorderCompound=P;//# sourceMappingURL=cross-border.js.map
1
+ 'use strict';var chunkGMLCWGNJ_js=require('./chunk-GMLCWGNJ.js'),chunkM6XETYNL_js=require('./chunk-M6XETYNL.js'),chunkC4YM4UMI_js=require('./chunk-C4YM4UMI.js');require('./chunk-E64TU6IU.js'),require('./chunk-ELKB2AFZ.js'),require('./chunk-MQFZHA2D.js');var react=require('react'),jsxRuntime=require('react/jsx-runtime');var t=react.createContext(null);function A(){let r=react.useContext(t);if(!r)throw new Error("CrossBorder compound components must be wrapped in <CrossBorder.Provider>. Example: <CrossBorder.Provider><CrossBorder.Manager /></CrossBorder.Provider>");return r}var e=({adapter:r,storageKey:d,useLocalStorage:a,initialTransfers:n,onAdd:p,onUpdate:C,onRemove:f,children:i})=>{let m=chunkM6XETYNL_js.a({adapter:r,storageKey:d,useLocalStorage:a,initialTransfers:n,onAdd:p,onUpdate:C,onRemove:f});return jsxRuntime.jsx(t.Provider,{value:m,children:i})};var q={Provider:e,Manager:chunkGMLCWGNJ_js.a};Object.defineProperty(exports,"CrossBorderTransferManager",{enumerable:true,get:function(){return chunkGMLCWGNJ_js.a}});Object.defineProperty(exports,"useCrossBorderTransfer",{enumerable:true,get:function(){return chunkM6XETYNL_js.a}});Object.defineProperty(exports,"COUNTRY_ADEQUACY_MAP",{enumerable:true,get:function(){return chunkC4YM4UMI_js.a}});Object.defineProperty(exports,"assessTransferRisk",{enumerable:true,get:function(){return chunkC4YM4UMI_js.h}});Object.defineProperty(exports,"getAdequateCountries",{enumerable:true,get:function(){return chunkC4YM4UMI_js.c}});Object.defineProperty(exports,"getCountryAdequacy",{enumerable:true,get:function(){return chunkC4YM4UMI_js.b}});Object.defineProperty(exports,"getTransferMechanismDescription",{enumerable:true,get:function(){return chunkC4YM4UMI_js.f}});Object.defineProperty(exports,"isNDPCApprovalRequired",{enumerable:true,get:function(){return chunkC4YM4UMI_js.e}});Object.defineProperty(exports,"requiresNDPCApproval",{enumerable:true,get:function(){return chunkC4YM4UMI_js.d}});Object.defineProperty(exports,"validateTransfer",{enumerable:true,get:function(){return chunkC4YM4UMI_js.g}});exports.CrossBorder=q;exports.CrossBorderProvider=e;exports.useCrossBorderCompound=A;//# sourceMappingURL=cross-border.js.map
2
2
  //# sourceMappingURL=cross-border.js.map