@tantainnovative/ndpr-toolkit 2.1.2 → 2.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +73 -2
- package/dist/{breach-6z0r-KuE.d.mts → breach-B_-6lDqS.d.mts} +1 -1
- package/dist/{breach-BFfnvtRk.d.ts → breach-CzXqSsaY.d.ts} +1 -1
- package/dist/{breach-BtFbDOmV.d.mts → breach-Eu9byel8.d.mts} +1 -1
- package/dist/{breach-BtFbDOmV.d.ts → breach-Eu9byel8.d.ts} +1 -1
- package/dist/breach-ouXoVTWs.d.ts +438 -0
- package/dist/breach-yRiyyc4n.d.mts +438 -0
- package/dist/breach.d.mts +5 -275
- package/dist/breach.d.ts +5 -275
- package/dist/breach.js +1 -1
- package/dist/breach.mjs +1 -1
- package/dist/chunk-2XFAV267.mjs +2 -0
- package/dist/chunk-32UIWTGD.js +72 -0
- package/dist/chunk-4JUDKBA2.mjs +7 -0
- package/dist/chunk-4VVARDN2.mjs +2 -0
- package/dist/chunk-5RSOLEEP.js +63 -0
- package/dist/chunk-AYKLAEOU.mjs +2 -0
- package/dist/chunk-BGHQTZAC.js +94 -0
- package/dist/chunk-BZTTQS4A.mjs +7 -0
- package/dist/chunk-CAB7O3GR.mjs +63 -0
- package/dist/chunk-CL53OI3I.js +7 -0
- package/dist/chunk-E64TU6IU.js +2 -0
- package/dist/chunk-EKVTLHBQ.js +2 -0
- package/dist/chunk-ELKEZEV5.mjs +2 -0
- package/dist/chunk-EPF7J2FK.js +3 -0
- package/dist/chunk-ER7X6E36.js +2 -0
- package/dist/chunk-FXTZDKDC.mjs +3 -0
- package/dist/chunk-IBEKLDBY.mjs +2 -0
- package/dist/chunk-ILCNDOBU.js +2 -0
- package/dist/chunk-K3GMTMQ6.js +2 -0
- package/dist/chunk-MJGOLP5M.js +2 -0
- package/dist/chunk-NW4A3JW6.mjs +2 -0
- package/dist/chunk-P3PULLYP.mjs +2 -0
- package/dist/chunk-SKJCQKFL.mjs +94 -0
- package/dist/chunk-TCJCE6WN.js +2 -0
- package/dist/chunk-UZ5EZOA7.js +2 -0
- package/dist/chunk-WSHSHIIM.mjs +2 -0
- package/dist/chunk-XMYUYQH7.mjs +72 -0
- package/dist/chunk-ZNTMZ6NM.js +7 -0
- package/dist/consent-audit-BdByjYlM.d.mts +65 -0
- package/dist/consent-audit-DhbfMR0n.d.ts +65 -0
- package/dist/consent.d.mts +120 -7
- package/dist/consent.d.ts +120 -7
- package/dist/consent.js +1 -1
- package/dist/consent.mjs +1 -1
- package/dist/core.d.mts +62 -12
- package/dist/core.d.ts +62 -12
- package/dist/core.js +1 -1
- package/dist/core.mjs +1 -1
- package/dist/{cross-border-BrIy1ieh.d.ts → cross-border-BMcqLvjC.d.mts} +1 -1
- package/dist/{cross-border-BrIy1ieh.d.mts → cross-border-BMcqLvjC.d.ts} +1 -1
- package/dist/cross-border-entry-BrWVPly6.d.ts +91 -0
- package/dist/cross-border-entry-cCTvpwnT.d.mts +91 -0
- package/dist/cross-border.d.mts +4 -58
- package/dist/cross-border.d.ts +4 -58
- package/dist/cross-border.js +1 -1
- package/dist/cross-border.mjs +1 -1
- package/dist/{dpia-vWfE_9bO.d.mts → dpia-5OQVA1R_.d.mts} +1 -1
- package/dist/{dpia-vWfE_9bO.d.ts → dpia-5OQVA1R_.d.ts} +1 -1
- package/dist/{dpia-fdtTd2DI.d.ts → dpia-B0Pok5us.d.ts} +1 -1
- package/dist/{dpia-B9ZZJG5a.d.mts → dpia-CUfOmzvX.d.mts} +1 -1
- package/dist/dpia.d.mts +119 -5
- package/dist/dpia.d.ts +119 -5
- package/dist/dpia.js +1 -1
- package/dist/dpia.mjs +1 -1
- package/dist/dsr-190YpijW.d.ts +307 -0
- package/dist/dsr-BTT-Xd7H.d.mts +307 -0
- package/dist/{dsr-pQzQ3H1O.d.mts → dsr-Cm9lzWG7.d.mts} +1 -1
- package/dist/{dsr-pQzQ3H1O.d.ts → dsr-Cm9lzWG7.d.ts} +1 -1
- package/dist/{dsr-whPkiI0_.d.mts → dsr-D_eTNc4S.d.mts} +1 -1
- package/dist/{dsr-jq5NUEdz.d.ts → dsr-pNtVb1BK.d.ts} +1 -1
- package/dist/dsr.d.mts +5 -192
- package/dist/dsr.d.ts +5 -192
- package/dist/dsr.js +1 -1
- package/dist/dsr.mjs +1 -1
- package/dist/hooks.d.mts +14 -14
- package/dist/hooks.d.ts +14 -14
- package/dist/hooks.js +1 -1
- package/dist/hooks.mjs +1 -1
- package/dist/index.d.mts +28 -27
- package/dist/index.d.ts +28 -27
- package/dist/index.js +1 -1
- package/dist/index.mjs +1 -1
- package/dist/{lawful-basis-v04AhbK2.d.ts → lawful-basis-BEyI0kGg.d.ts} +2 -2
- package/dist/{lawful-basis-D-oXFizg.d.mts → lawful-basis-C2eGaoHM.d.mts} +2 -2
- package/dist/{lawful-basis-CWtvDG1x.d.mts → lawful-basis-Cv1VmDLn.d.mts} +1 -1
- package/dist/{lawful-basis-CWtvDG1x.d.ts → lawful-basis-Cv1VmDLn.d.ts} +1 -1
- package/dist/lawful-basis-entry-15qjKcNO.d.ts +87 -0
- package/dist/lawful-basis-entry-CxZrofwG.d.mts +87 -0
- package/dist/lawful-basis.d.mts +5 -55
- package/dist/lawful-basis.d.ts +5 -55
- package/dist/lawful-basis.js +1 -1
- package/dist/lawful-basis.mjs +1 -1
- package/dist/policy-D2_jh5-T.d.ts +293 -0
- package/dist/policy-E0fXZkda.d.mts +293 -0
- package/dist/policy-templates-CIKcV0i1.d.ts +36 -0
- package/dist/policy-templates-DMsPwOSZ.d.mts +36 -0
- package/dist/policy.d.mts +5 -195
- package/dist/policy.d.ts +5 -195
- package/dist/policy.js +1 -1
- package/dist/policy.mjs +1 -1
- package/dist/{ropa-Rb4dsFSz.d.mts → ropa-DP7pPPql.d.mts} +2 -2
- package/dist/{ropa-BebGfqKQ.d.ts → ropa-Li6UlL5H.d.ts} +2 -2
- package/dist/ropa-entry-B0D7X1GV.d.ts +80 -0
- package/dist/ropa-entry-DiOThOc2.d.mts +80 -0
- package/dist/ropa.d.mts +5 -45
- package/dist/ropa.d.ts +5 -45
- package/dist/ropa.js +1 -1
- package/dist/ropa.mjs +1 -1
- package/dist/styles.css +40 -28
- package/dist/styles.d.ts +1 -0
- package/dist/unstyled.js +1 -1
- package/dist/unstyled.mjs +1 -1
- package/dist/{useBreach-WrZzJilM.d.mts → useBreach-BBSoIcZO.d.mts} +1 -1
- package/dist/{useBreach-vrh_XMpI.d.ts → useBreach-lFLbSyAN.d.ts} +1 -1
- package/dist/{useCrossBorderTransfer-TVnY8_UX.d.mts → useCrossBorderTransfer-BZVFCXfr.d.mts} +1 -1
- package/dist/{useCrossBorderTransfer-D4FQYfFt.d.ts → useCrossBorderTransfer-DmtACeqW.d.ts} +1 -1
- package/dist/{useDPIA-DFDHBLSa.d.ts → useDPIA-DBsg2yZx.d.ts} +1 -1
- package/dist/{useDPIA-FqPofFaV.d.mts → useDPIA-Da7-Q_yW.d.mts} +1 -1
- package/dist/{useDSR-DAqqOBXb.d.ts → useDSR-CYI7WCXr.d.ts} +1 -1
- package/dist/{useDSR-OXM5Q9rf.d.mts → useDSR-YYZ6FYFs.d.mts} +1 -1
- package/dist/{usePrivacyPolicy-CfySfBLS.d.ts → useDefaultPrivacyPolicy-B7kTHbZh.d.ts} +39 -2
- package/dist/{usePrivacyPolicy-Dit2sFuV.d.mts → useDefaultPrivacyPolicy-CUluF_ic.d.mts} +39 -2
- package/dist/{useLawfulBasis-RILM_xsx.d.ts → useLawfulBasis-CCWF9waR.d.ts} +2 -2
- package/dist/{useLawfulBasis-DNQ8YszQ.d.mts → useLawfulBasis-CpWuHtyh.d.mts} +2 -2
- package/dist/{useROPA-Bcs6cRdi.d.ts → useROPA-BhJ3kvHp.d.ts} +1 -1
- package/dist/{useROPA-nmcSiUYv.d.mts → useROPA-DLFdjkxP.d.mts} +1 -1
- package/package.json +30 -21
- package/dist/chunk-2XHD22J7.mjs +0 -7
- package/dist/chunk-4DKT6IB6.js +0 -94
- package/dist/chunk-6JFTAYXV.mjs +0 -2
- package/dist/chunk-6JVYYLS7.js +0 -2
- package/dist/chunk-6SGG6WPA.mjs +0 -2
- package/dist/chunk-AQEGDEQM.js +0 -7
- package/dist/chunk-C2IJWCZQ.mjs +0 -2
- package/dist/chunk-DB3JH4DS.mjs +0 -2
- package/dist/chunk-FFW7RUAG.mjs +0 -94
- package/dist/chunk-FK3CSFLJ.js +0 -2
- package/dist/chunk-IWUUVRLJ.js +0 -2
- package/dist/chunk-JUN6YPLL.mjs +0 -72
- package/dist/chunk-L3FKTBGV.js +0 -72
- package/dist/chunk-PM7CMTMB.js +0 -4
- package/dist/chunk-RB26MIRI.js +0 -2
- package/dist/chunk-RHWW5FDP.js +0 -16
- package/dist/chunk-SLNMKGQ2.mjs +0 -2
- package/dist/chunk-UUWVBENC.js +0 -2
- package/dist/chunk-UYP64PV7.mjs +0 -4
- package/dist/chunk-XMKA6GVK.mjs +0 -16
- package/dist/consent-DCc5zjXI.d.mts +0 -24
- package/dist/consent-DLWb5ota.d.ts +0 -24
- package/dist/privacy-9FcJceMr.d.mts +0 -15
- package/dist/privacy-BXz7O2ej.d.ts +0 -15
package/dist/chunk-XMKA6GVK.mjs
DELETED
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import e from'react';var j=({sections:d,answers:b,onAnswerChange:g,currentSectionIndex:y,onNextSection:k,onPrevSection:h,validationErrors:N={},readOnly:o=false,className:v="",buttonClassName:c="",nextButtonText:n="Next",prevButtonText:f="Previous",submitButtonText:w="Submit",showProgress:P=true,progress:u})=>{let s=d[y],i=y===d.length-1,p=t=>t.showWhen?t.showWhen.every(x=>{let l=b[x.questionId];switch(x.operator){case "equals":return l===x.value;case "contains":return Array.isArray(l)?l.includes(x.value):false;case "greaterThan":return typeof l=="number"?l>x.value:false;case "lessThan":return typeof l=="number"?l<x.value:false;default:return true}}):true,A=t=>{if(!p(t))return null;let x=N[t.id],l=b[t.id];return e.createElement("div",{key:t.id,className:"mb-6"},e.createElement("div",{className:"mb-2"},e.createElement("label",{htmlFor:t.id,className:"block text-sm font-medium text-gray-900 dark:text-gray-100"},t.text,t.required&&e.createElement("span",{className:"text-red-500 ml-1"},"*")),t.guidance&&e.createElement("p",{className:"mt-1 text-sm text-gray-500 dark:text-gray-400"},t.guidance)),t.type==="text"&&e.createElement("input",{type:"text",id:t.id,value:l||"",onChange:a=>g(t.id,a.target.value),disabled:o,className:`w-full px-3 py-2 border rounded-md ${x?"border-red-500":"border-gray-300 dark:border-gray-600"} focus:outline-none focus:ring-2 focus:ring-blue-500 bg-white dark:bg-gray-800 text-gray-900 dark:text-gray-100`}),t.type==="textarea"&&e.createElement("textarea",{id:t.id,value:l||"",onChange:a=>g(t.id,a.target.value),disabled:o,rows:4,className:`w-full px-3 py-2 border rounded-md ${x?"border-red-500":"border-gray-300 dark:border-gray-600"} focus:outline-none focus:ring-2 focus:ring-blue-500 bg-white dark:bg-gray-800 text-gray-900 dark:text-gray-100`}),t.type==="select"&&t.options&&e.createElement("select",{id:t.id,value:l||"",onChange:a=>g(t.id,a.target.value),disabled:o,className:`w-full px-3 py-2 border rounded-md ${x?"border-red-500":"border-gray-300 dark:border-gray-600"} focus:outline-none focus:ring-2 focus:ring-blue-500 bg-white dark:bg-gray-800 text-gray-900 dark:text-gray-100`},e.createElement("option",{value:""},"Select an option"),t.options.map(a=>e.createElement("option",{key:a.value,value:a.value},a.label))),t.type==="radio"&&t.options&&e.createElement("div",{className:"space-y-2"},t.options.map(a=>e.createElement("div",{key:a.value,className:"flex items-center"},e.createElement("input",{type:"radio",id:`${t.id}_${a.value}`,name:t.id,value:a.value,checked:l===a.value,onChange:()=>g(t.id,a.value),disabled:o,className:"h-4 w-4 text-blue-600 focus:ring-blue-500 border-gray-300 dark:border-gray-600"}),e.createElement("label",{htmlFor:`${t.id}_${a.value}`,className:"ml-2 block text-sm text-gray-900 dark:text-gray-100"},a.label,a.riskLevel&&e.createElement("span",{className:`ml-2 text-xs px-2 py-1 rounded ${a.riskLevel==="low"?"bg-green-100 text-green-800 dark:bg-green-900 dark:text-green-200":a.riskLevel==="medium"?"bg-yellow-100 text-yellow-800 dark:bg-yellow-900 dark:text-yellow-200":"bg-red-100 text-red-800 dark:bg-red-900 dark:text-red-200"}`},a.riskLevel.charAt(0).toUpperCase()+a.riskLevel.slice(1)," Risk"))))),t.type==="checkbox"&&t.options&&e.createElement("div",{className:"space-y-2"},t.options.map(a=>e.createElement("div",{key:a.value,className:"flex items-center"},e.createElement("input",{type:"checkbox",id:`${t.id}_${a.value}`,value:a.value,checked:Array.isArray(l)?l.includes(a.value):false,onChange:$=>{let D=Array.isArray(l)?[...l]:[];$.target.checked?g(t.id,[...D,a.value]):g(t.id,D.filter(S=>S!==a.value));},disabled:o,className:"h-4 w-4 rounded text-blue-600 focus:ring-blue-500 border-gray-300 dark:border-gray-600"}),e.createElement("label",{htmlFor:`${t.id}_${a.value}`,className:"ml-2 block text-sm text-gray-900 dark:text-gray-100"},a.label)))),t.type==="scale"&&e.createElement("div",null,e.createElement("div",{className:"flex justify-between mb-2"},t.scaleLabels&&Object.entries(t.scaleLabels).map(([a,$])=>e.createElement("div",{key:a,className:"text-xs text-gray-500 dark:text-gray-400 text-center",style:{width:`${100/Object.keys(t.scaleLabels||{}).length}%`}},$))),e.createElement("input",{type:"range",id:t.id,min:t.minValue||1,max:t.maxValue||5,value:l||t.minValue||1,onChange:a=>g(t.id,parseInt(a.target.value,10)),disabled:o,className:"w-full h-2 bg-gray-200 rounded-lg appearance-none cursor-pointer dark:bg-gray-700"}),e.createElement("div",{className:"mt-1 text-sm text-gray-500 dark:text-gray-400 text-center"},"Selected value: ",l||t.minValue||1)),x&&e.createElement("p",{className:"mt-1 text-sm text-red-500"},x))};return s?e.createElement("div",{className:`bg-white dark:bg-gray-800 rounded-lg shadow-md p-6 ${v}`},P&&e.createElement("div",{className:"mb-6"},e.createElement("div",{className:"flex justify-between text-sm text-gray-500 dark:text-gray-400 mb-1"},e.createElement("span",null,"Section ",y+1," of ",d.length),e.createElement("span",null,u!==void 0?`${u}% Complete`:"")),e.createElement("div",{className:"w-full bg-gray-200 rounded-full h-2.5 dark:bg-gray-700"},e.createElement("div",{className:"bg-blue-600 h-2.5 rounded-full",style:{width:`${u!==void 0?u:(y+1)/d.length*100}%`}}))),e.createElement("h2",{className:"text-xl font-bold mb-2 text-gray-900 dark:text-white"},s.title),s.description&&e.createElement("p",{className:"mb-6 text-gray-600 dark:text-gray-300"},s.description),e.createElement("div",{className:"space-y-6"},s.questions.map(t=>A(t))),e.createElement("div",{className:"mt-8 flex justify-between"},e.createElement("button",{type:"button",onClick:h,disabled:y===0||o,className:`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 disabled:opacity-50 disabled:cursor-not-allowed ${c}`},f),e.createElement("button",{type:"button",onClick:k,disabled:o,className:`px-4 py-2 bg-blue-600 text-white rounded hover:bg-blue-700 disabled:opacity-50 disabled:cursor-not-allowed ${c}`},i?w:n))):e.createElement("div",null,"No section found.")};var T=({result:d,sections:b,showFullReport:g=true,allowPrint:y=true,allowExport:k=true,onExport:h,className:N="",buttonClassName:o=""})=>{let v=s=>new Date(s).toLocaleDateString("en-GB",{day:"numeric",month:"long",year:"numeric"}),f=s=>{let i=d.answers[s];return i==null?"Not answered":typeof i=="boolean"?i?"Yes":"No":Array.isArray(i)?i.join(", "):String(i)},w=()=>{window.print();},P=s=>{h&&h(s);},u=s=>e.createElement("span",{className:`px-2 py-1 rounded text-xs font-medium ${{low:"bg-green-100 text-green-800 dark:bg-green-900 dark:text-green-200",medium:"bg-yellow-100 text-yellow-800 dark:bg-yellow-900 dark:text-yellow-200",high:"bg-orange-100 text-orange-800 dark:bg-orange-900 dark:text-orange-200",critical:"bg-red-100 text-red-800 dark:bg-red-900 dark:text-red-200"}[s]}`},s.charAt(0).toUpperCase()+s.slice(1));return e.createElement("div",{className:`bg-white dark:bg-gray-800 rounded-lg shadow-md p-6 print:shadow-none print:p-0 ${N}`},e.createElement("div",{className:"mb-8 border-b border-gray-200 dark:border-gray-700 pb-6 print:pb-4"},e.createElement("div",{className:"flex justify-between items-start"},e.createElement("div",null,e.createElement("h1",{className:"text-2xl font-bold text-gray-900 dark:text-white mb-2"},"Data Protection Impact Assessment Report"),e.createElement("h2",{className:"text-xl text-gray-700 dark:text-gray-300 mb-4"},d.title)),(y||k)&&e.createElement("div",{className:"flex space-x-2 print:hidden"},y&&e.createElement("button",{onClick:w,className:`px-3 py-1 bg-gray-200 text-gray-800 dark:bg-gray-700 dark:text-white rounded hover:bg-gray-300 dark:hover:bg-gray-600 ${o}`},e.createElement("span",{className:"flex items-center"},e.createElement("svg",{className:"w-4 h-4 mr-1",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},e.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M17 17h2a2 2 0 002-2v-4a2 2 0 00-2-2H5a2 2 0 00-2 2v4a2 2 0 002 2h2m2 4h6a2 2 0 002-2v-4a2 2 0 00-2-2H9a2 2 0 00-2 2v4a2 2 0 002 2zm8-12V5a2 2 0 00-2-2H9a2 2 0 00-2 2v4h10z"})),"Print")),k&&e.createElement("div",{className:"relative inline-block"},e.createElement("button",{onClick:()=>P("pdf"),className:`px-3 py-1 bg-blue-600 text-white rounded hover:bg-blue-700 ${o}`},e.createElement("span",{className:"flex items-center"},e.createElement("svg",{className:"w-4 h-4 mr-1",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},e.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M4 16v1a3 3 0 003 3h10a3 3 0 003-3v-1m-4-4l-4 4m0 0l-4-4m4 4V4"})),"Export PDF"))))),e.createElement("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4 mt-4"},e.createElement("div",null,e.createElement("p",{className:"text-sm text-gray-500 dark:text-gray-400"},e.createElement("span",{className:"font-medium"},"Assessor:")," ",d.assessor.name,", ",d.assessor.role),e.createElement("p",{className:"text-sm text-gray-500 dark:text-gray-400"},e.createElement("span",{className:"font-medium"},"Contact:")," ",d.assessor.email)),e.createElement("div",null,e.createElement("p",{className:"text-sm text-gray-500 dark:text-gray-400"},e.createElement("span",{className:"font-medium"},"Started:")," ",v(d.startedAt)),e.createElement("p",{className:"text-sm text-gray-500 dark:text-gray-400"},e.createElement("span",{className:"font-medium"},"Completed:")," ",d.completedAt?v(d.completedAt):"In progress"),e.createElement("p",{className:"text-sm text-gray-500 dark:text-gray-400"},e.createElement("span",{className:"font-medium"},"Next review:")," ",d.reviewDate?v(d.reviewDate):"Not scheduled")))),e.createElement("div",{className:"mb-8"},e.createElement("h2",{className:"text-xl font-bold text-gray-900 dark:text-white mb-4"},"Executive Summary"),e.createElement("div",{className:"bg-gray-50 dark:bg-gray-700 p-4 rounded-md mb-4"},e.createElement("div",{className:"flex items-center mb-2"},e.createElement("span",{className:"font-medium mr-2"},"Overall Risk Level:"),u(d.overallRiskLevel)),e.createElement("div",{className:"mb-2"},e.createElement("span",{className:"font-medium"},"Conclusion:")," ",d.conclusion),e.createElement("div",null,e.createElement("span",{className:"font-medium"},"Can Proceed:")," ",d.canProceed?"Yes":"No")),e.createElement("div",null,e.createElement("h3",{className:"font-medium text-gray-900 dark:text-white mb-2"},"Processing Activity Description"),e.createElement("p",{className:"text-gray-700 dark:text-gray-300 mb-4"},d.processingDescription),d.recommendations&&d.recommendations.length>0&&e.createElement("div",null,e.createElement("h3",{className:"font-medium text-gray-900 dark:text-white mb-2"},"Key Recommendations"),e.createElement("ul",{className:"list-disc pl-5 text-gray-700 dark:text-gray-300"},d.recommendations.map((s,i)=>e.createElement("li",{key:i},s)))))),e.createElement("div",{className:"mb-8"},e.createElement("h2",{className:"text-xl font-bold text-gray-900 dark:text-white mb-4"},"Identified Risks"),d.risks.length===0?e.createElement("p",{className:"text-gray-700 dark:text-gray-300"},"No risks identified."):e.createElement("div",{className:"overflow-x-auto"},e.createElement("table",{className:"min-w-full divide-y divide-gray-200 dark:divide-gray-700"},e.createElement("thead",{className:"bg-gray-50 dark:bg-gray-700"},e.createElement("tr",null,e.createElement("th",{scope:"col",className:"px-6 py-3 text-left text-xs font-medium text-gray-500 dark:text-gray-300 uppercase tracking-wider"},"Risk"),e.createElement("th",{scope:"col",className:"px-6 py-3 text-left text-xs font-medium text-gray-500 dark:text-gray-300 uppercase tracking-wider"},"Likelihood"),e.createElement("th",{scope:"col",className:"px-6 py-3 text-left text-xs font-medium text-gray-500 dark:text-gray-300 uppercase tracking-wider"},"Impact"),e.createElement("th",{scope:"col",className:"px-6 py-3 text-left text-xs font-medium text-gray-500 dark:text-gray-300 uppercase tracking-wider"},"Risk Level"),e.createElement("th",{scope:"col",className:"px-6 py-3 text-left text-xs font-medium text-gray-500 dark:text-gray-300 uppercase tracking-wider"},"Mitigated"))),e.createElement("tbody",{className:"bg-white dark:bg-gray-800 divide-y divide-gray-200 dark:divide-gray-700"},d.risks.map(s=>e.createElement("tr",{key:s.id},e.createElement("td",{className:"px-6 py-4 whitespace-normal text-sm text-gray-900 dark:text-gray-100"},s.description),e.createElement("td",{className:"px-6 py-4 whitespace-nowrap text-sm text-gray-500 dark:text-gray-400"},s.likelihood," / 5"),e.createElement("td",{className:"px-6 py-4 whitespace-nowrap text-sm text-gray-500 dark:text-gray-400"},s.impact," / 5"),e.createElement("td",{className:"px-6 py-4 whitespace-nowrap text-sm"},u(s.level)),e.createElement("td",{className:"px-6 py-4 whitespace-nowrap text-sm text-gray-500 dark:text-gray-400"},s.mitigated?e.createElement("span",{className:"text-green-600 dark:text-green-400"},"Yes"):e.createElement("span",{className:"text-red-600 dark:text-red-400"},"No")))))))),g&&e.createElement("div",null,e.createElement("h2",{className:"text-xl font-bold text-gray-900 dark:text-white mb-4"},"Full Assessment Details"),b.map(s=>{let i=s.questions.filter(p=>d.answers[p.id]!==void 0);return i.length===0?null:e.createElement("div",{key:s.id,className:"mb-6"},e.createElement("h3",{className:"text-lg font-medium text-gray-900 dark:text-white mb-2"},s.title),e.createElement("div",{className:"overflow-x-auto"},e.createElement("table",{className:"min-w-full divide-y divide-gray-200 dark:divide-gray-700"},e.createElement("thead",{className:"bg-gray-50 dark:bg-gray-700"},e.createElement("tr",null,e.createElement("th",{scope:"col",className:"px-6 py-3 text-left text-xs font-medium text-gray-500 dark:text-gray-300 uppercase tracking-wider"},"Question"),e.createElement("th",{scope:"col",className:"px-6 py-3 text-left text-xs font-medium text-gray-500 dark:text-gray-300 uppercase tracking-wider"},"Answer"))),e.createElement("tbody",{className:"bg-white dark:bg-gray-800 divide-y divide-gray-200 dark:divide-gray-700"},i.map(p=>e.createElement("tr",{key:p.id},e.createElement("td",{className:"px-6 py-4 whitespace-normal text-sm text-gray-900 dark:text-gray-100"},p.text),e.createElement("td",{className:"px-6 py-4 whitespace-normal text-sm text-gray-500 dark:text-gray-400"},f(p.id))))))))})),e.createElement("div",{className:"mt-8 pt-4 border-t border-gray-200 dark:border-gray-700 text-sm text-gray-500 dark:text-gray-400"},e.createElement("p",null,"This DPIA was conducted in accordance with the Nigeria Data Protection Act (NDPA) 2023."),e.createElement("p",null,"DPIA Report Version: ",d.version),e.createElement("p",null,"Generated on: ",new Date().toLocaleDateString())))};var E=({steps:d,onStepClick:b,clickable:g=true,orientation:y="horizontal",className:k="",activeStepClassName:h="",completedStepClassName:N="",incompleteStepClassName:o=""})=>{let v=n=>{g&&b&&b(n);},c=y==="vertical";return e.createElement("div",{className:`${k} ${c?"flex flex-col space-y-4":"flex items-center justify-between"}`},d.map((n,f)=>{let w=f===d.length-1,P=n.active?`font-medium ${h||"text-blue-600 dark:text-blue-400"}`:n.completed?`${N||"text-green-600 dark:text-green-400"}`:`${o||"text-gray-500 dark:text-gray-400"}`;return e.createElement(e.Fragment,{key:n.id},e.createElement("div",{className:`
|
|
2
|
-
${c?"flex items-start":"flex flex-col items-center"}
|
|
3
|
-
${g?"cursor-pointer":""}
|
|
4
|
-
`,onClick:()=>v(n.id)},e.createElement("div",{className:`
|
|
5
|
-
flex items-center justify-center
|
|
6
|
-
${c?"mr-4":""}
|
|
7
|
-
`},e.createElement("div",{className:`
|
|
8
|
-
flex items-center justify-center
|
|
9
|
-
w-8 h-8 rounded-full
|
|
10
|
-
${n.active?"bg-blue-100 dark:bg-blue-900 text-blue-600 dark:text-blue-400 border-2 border-blue-600 dark:border-blue-400":n.completed?"bg-green-100 dark:bg-green-900 text-green-600 dark:text-green-400 border-2 border-green-600 dark:border-green-400":"bg-gray-100 dark:bg-gray-700 text-gray-500 dark:text-gray-400 border-2 border-gray-300 dark:border-gray-600"}
|
|
11
|
-
`},n.icon?n.icon:n.completed?e.createElement("svg",{className:"w-4 h-4",fill:"currentColor",viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg"},e.createElement("path",{fillRule:"evenodd",d:"M16.707 5.293a1 1 0 010 1.414l-8 8a1 1 0 01-1.414 0l-4-4a1 1 0 011.414-1.414L8 12.586l7.293-7.293a1 1 0 011.414 0z",clipRule:"evenodd"})):e.createElement("span",null,f+1))),e.createElement("div",{className:`
|
|
12
|
-
${c?"flex-1":"mt-2 text-center"}
|
|
13
|
-
`},e.createElement("div",{className:`text-sm font-medium ${P}`},n.label),n.description&&e.createElement("div",{className:"text-xs text-gray-500 dark:text-gray-400 mt-1"},n.description))),!w&&e.createElement("div",{className:`
|
|
14
|
-
${c?"ml-4 h-8 border-l-2 border-gray-300 dark:border-gray-600":"w-full border-t-2 border-gray-300 dark:border-gray-600 hidden sm:block"}
|
|
15
|
-
`}))}))};export{j as a,T as b,E as c};//# sourceMappingURL=chunk-XMKA6GVK.mjs.map
|
|
16
|
-
//# sourceMappingURL=chunk-XMKA6GVK.mjs.map
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { a as ConsentSettings, C as ConsentOption } from './consent-CmVzqZUk.mjs';
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* Validates consent settings to ensure they meet NDPA requirements
|
|
5
|
-
* @param settings The consent settings to validate
|
|
6
|
-
* @returns An object containing validation result and any error messages
|
|
7
|
-
*/
|
|
8
|
-
declare function validateConsent(settings: ConsentSettings): {
|
|
9
|
-
valid: boolean;
|
|
10
|
-
errors: string[];
|
|
11
|
-
};
|
|
12
|
-
/**
|
|
13
|
-
* Validates that consent options meet NDPA Section 26 requirements.
|
|
14
|
-
* Each consent option must specify a purpose for which data will be processed,
|
|
15
|
-
* as consent must be specific and informed per the Nigeria Data Protection Act.
|
|
16
|
-
* @param options The consent options to validate
|
|
17
|
-
* @returns An object containing validation result and any error messages
|
|
18
|
-
*/
|
|
19
|
-
declare function validateConsentOptions(options: ConsentOption[]): {
|
|
20
|
-
valid: boolean;
|
|
21
|
-
errors: string[];
|
|
22
|
-
};
|
|
23
|
-
|
|
24
|
-
export { validateConsentOptions as a, validateConsent as v };
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { a as ConsentSettings, C as ConsentOption } from './consent-CmVzqZUk.js';
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* Validates consent settings to ensure they meet NDPA requirements
|
|
5
|
-
* @param settings The consent settings to validate
|
|
6
|
-
* @returns An object containing validation result and any error messages
|
|
7
|
-
*/
|
|
8
|
-
declare function validateConsent(settings: ConsentSettings): {
|
|
9
|
-
valid: boolean;
|
|
10
|
-
errors: string[];
|
|
11
|
-
};
|
|
12
|
-
/**
|
|
13
|
-
* Validates that consent options meet NDPA Section 26 requirements.
|
|
14
|
-
* Each consent option must specify a purpose for which data will be processed,
|
|
15
|
-
* as consent must be specific and informed per the Nigeria Data Protection Act.
|
|
16
|
-
* @param options The consent options to validate
|
|
17
|
-
* @returns An object containing validation result and any error messages
|
|
18
|
-
*/
|
|
19
|
-
declare function validateConsentOptions(options: ConsentOption[]): {
|
|
20
|
-
valid: boolean;
|
|
21
|
-
errors: string[];
|
|
22
|
-
};
|
|
23
|
-
|
|
24
|
-
export { validateConsentOptions as a, validateConsent as v };
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import { P as PolicySection, O as OrganizationInfo } from './privacy-Ca6te9Ir.mjs';
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* Generates policy text by replacing variables in a template with organization-specific values
|
|
5
|
-
* @param sectionsOrTemplate The policy sections or template string to generate text for
|
|
6
|
-
* @param organizationInfoOrVariables The organization information or variable map to use for replacement
|
|
7
|
-
* @returns The generated policy text or an object with the generated text and metadata
|
|
8
|
-
*/
|
|
9
|
-
declare function generatePolicyText(sectionsOrTemplate: PolicySection[] | string, organizationInfoOrVariables: OrganizationInfo | Record<string, string>): string | {
|
|
10
|
-
fullText: string;
|
|
11
|
-
sectionTexts: Record<string, string>;
|
|
12
|
-
missingVariables: string[];
|
|
13
|
-
};
|
|
14
|
-
|
|
15
|
-
export { generatePolicyText as g };
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import { P as PolicySection, O as OrganizationInfo } from './privacy-Ca6te9Ir.js';
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* Generates policy text by replacing variables in a template with organization-specific values
|
|
5
|
-
* @param sectionsOrTemplate The policy sections or template string to generate text for
|
|
6
|
-
* @param organizationInfoOrVariables The organization information or variable map to use for replacement
|
|
7
|
-
* @returns The generated policy text or an object with the generated text and metadata
|
|
8
|
-
*/
|
|
9
|
-
declare function generatePolicyText(sectionsOrTemplate: PolicySection[] | string, organizationInfoOrVariables: OrganizationInfo | Record<string, string>): string | {
|
|
10
|
-
fullText: string;
|
|
11
|
-
sectionTexts: Record<string, string>;
|
|
12
|
-
missingVariables: string[];
|
|
13
|
-
};
|
|
14
|
-
|
|
15
|
-
export { generatePolicyText as g };
|