@tantainnovative/ndpr-toolkit 1.0.9 → 2.1.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 +295 -124
- package/dist/breach-BpSBPrdk.d.mts +185 -0
- package/dist/breach-BpSBPrdk.d.ts +185 -0
- package/dist/breach-D5zJYNph.d.mts +17 -0
- package/dist/breach-D7NgrdMX.d.ts +17 -0
- package/dist/breach.d.mts +275 -0
- package/dist/breach.d.ts +275 -0
- package/dist/breach.js +2 -0
- package/dist/breach.js.map +1 -0
- package/dist/breach.mjs +2 -0
- package/dist/breach.mjs.map +1 -0
- package/dist/chunk-2SYNHRP6.mjs +2 -0
- package/dist/chunk-2SYNHRP6.mjs.map +1 -0
- package/dist/chunk-2XHD22J7.mjs +7 -0
- package/dist/chunk-2XHD22J7.mjs.map +1 -0
- package/dist/chunk-4A354HL3.js +2 -0
- package/dist/chunk-4A354HL3.js.map +1 -0
- package/dist/chunk-4DKT6IB6.js +94 -0
- package/dist/chunk-4DKT6IB6.js.map +1 -0
- package/dist/chunk-5ZBO2UPH.js +2 -0
- package/dist/chunk-5ZBO2UPH.js.map +1 -0
- package/dist/chunk-6JFTAYXV.mjs +2 -0
- package/dist/chunk-6JFTAYXV.mjs.map +1 -0
- package/dist/chunk-6JVYYLS7.js +2 -0
- package/dist/chunk-6JVYYLS7.js.map +1 -0
- package/dist/chunk-6SGG6WPA.mjs +2 -0
- package/dist/chunk-6SGG6WPA.mjs.map +1 -0
- package/dist/chunk-AQEGDEQM.js +7 -0
- package/dist/chunk-AQEGDEQM.js.map +1 -0
- package/dist/chunk-C2IJWCZQ.mjs +2 -0
- package/dist/chunk-C2IJWCZQ.mjs.map +1 -0
- package/dist/chunk-CMZTI7SG.js +2 -0
- package/dist/chunk-CMZTI7SG.js.map +1 -0
- package/dist/chunk-DB3JH4DS.mjs +2 -0
- package/dist/chunk-DB3JH4DS.mjs.map +1 -0
- package/dist/chunk-EWOZKYLY.mjs +2 -0
- package/dist/chunk-EWOZKYLY.mjs.map +1 -0
- package/dist/chunk-FFW7RUAG.mjs +94 -0
- package/dist/chunk-FFW7RUAG.mjs.map +1 -0
- package/dist/chunk-FK3CSFLJ.js +2 -0
- package/dist/chunk-FK3CSFLJ.js.map +1 -0
- package/dist/chunk-GIV2OHE6.mjs +2 -0
- package/dist/chunk-GIV2OHE6.mjs.map +1 -0
- package/dist/chunk-GMLNWS2N.mjs +2 -0
- package/dist/chunk-GMLNWS2N.mjs.map +1 -0
- package/dist/chunk-IQF726GS.js +2 -0
- package/dist/chunk-IQF726GS.js.map +1 -0
- package/dist/chunk-IWUUVRLJ.js +2 -0
- package/dist/chunk-IWUUVRLJ.js.map +1 -0
- package/dist/chunk-JUN6YPLL.mjs +72 -0
- package/dist/chunk-JUN6YPLL.mjs.map +1 -0
- package/dist/chunk-L3FKTBGV.js +72 -0
- package/dist/chunk-L3FKTBGV.js.map +1 -0
- package/dist/chunk-L52PDW6O.mjs +2 -0
- package/dist/chunk-L52PDW6O.mjs.map +1 -0
- package/dist/chunk-LI6WJ3LZ.js +2 -0
- package/dist/chunk-LI6WJ3LZ.js.map +1 -0
- package/dist/chunk-LXRXDTPI.js +2 -0
- package/dist/chunk-LXRXDTPI.js.map +1 -0
- package/dist/chunk-MQFZHA2D.js +2 -0
- package/dist/chunk-MQFZHA2D.js.map +1 -0
- package/dist/chunk-OITITR6K.mjs +2 -0
- package/dist/chunk-OITITR6K.mjs.map +1 -0
- package/dist/chunk-PDJGTQMY.mjs +2 -0
- package/dist/chunk-PDJGTQMY.mjs.map +1 -0
- package/dist/chunk-PGSA2O5P.mjs +2 -0
- package/dist/chunk-PGSA2O5P.mjs.map +1 -0
- package/dist/chunk-PM7CMTMB.js +4 -0
- package/dist/chunk-PM7CMTMB.js.map +1 -0
- package/dist/chunk-PYEX7DFR.mjs +4 -0
- package/dist/chunk-PYEX7DFR.mjs.map +1 -0
- package/dist/chunk-QKK5S54L.mjs +2 -0
- package/dist/chunk-QKK5S54L.mjs.map +1 -0
- package/dist/chunk-RB26MIRI.js +2 -0
- package/dist/chunk-RB26MIRI.js.map +1 -0
- package/dist/chunk-RGYK4VAY.mjs +2 -0
- package/dist/chunk-RGYK4VAY.mjs.map +1 -0
- package/dist/chunk-RHWW5FDP.js +16 -0
- package/dist/chunk-RHWW5FDP.js.map +1 -0
- package/dist/chunk-RYZEIDNR.js +2 -0
- package/dist/chunk-RYZEIDNR.js.map +1 -0
- package/dist/chunk-SLNMKGQ2.mjs +2 -0
- package/dist/chunk-SLNMKGQ2.mjs.map +1 -0
- package/dist/chunk-SSGJREE3.js +2 -0
- package/dist/chunk-SSGJREE3.js.map +1 -0
- package/dist/chunk-SWF3YVE5.js +4 -0
- package/dist/chunk-SWF3YVE5.js.map +1 -0
- package/dist/chunk-T44JQT2O.mjs +2 -0
- package/dist/chunk-T44JQT2O.mjs.map +1 -0
- package/dist/chunk-TDDAYVKK.js +2 -0
- package/dist/chunk-TDDAYVKK.js.map +1 -0
- package/dist/chunk-TXBZPCGF.mjs +2 -0
- package/dist/chunk-TXBZPCGF.mjs.map +1 -0
- package/dist/chunk-U2CGMEWB.js +2 -0
- package/dist/chunk-U2CGMEWB.js.map +1 -0
- package/dist/chunk-UUWVBENC.js +2 -0
- package/dist/chunk-UUWVBENC.js.map +1 -0
- package/dist/chunk-UYP64PV7.mjs +4 -0
- package/dist/chunk-UYP64PV7.mjs.map +1 -0
- package/dist/chunk-VMJBW3EF.mjs +2 -0
- package/dist/chunk-VMJBW3EF.mjs.map +1 -0
- package/dist/chunk-WW3X3ELF.js +2 -0
- package/dist/chunk-WW3X3ELF.js.map +1 -0
- package/dist/chunk-WWT2ZSNU.mjs +2 -0
- package/dist/chunk-WWT2ZSNU.mjs.map +1 -0
- package/dist/chunk-XMKA6GVK.mjs +16 -0
- package/dist/chunk-XMKA6GVK.mjs.map +1 -0
- package/dist/chunk-Y34DQYS7.js +2 -0
- package/dist/chunk-Y34DQYS7.js.map +1 -0
- package/dist/chunk-ZU73VG3X.js +2 -0
- package/dist/chunk-ZU73VG3X.js.map +1 -0
- package/dist/consent-CmVzqZUk.d.mts +99 -0
- package/dist/consent-CmVzqZUk.d.ts +99 -0
- package/dist/consent-DCc5zjXI.d.mts +24 -0
- package/dist/consent-DLWb5ota.d.ts +24 -0
- package/dist/consent.d.mts +197 -0
- package/dist/consent.d.ts +197 -0
- package/dist/consent.js +2 -0
- package/dist/consent.js.map +1 -0
- package/dist/consent.mjs +2 -0
- package/dist/consent.mjs.map +1 -0
- package/dist/core.d.mts +14 -0
- package/dist/core.d.ts +14 -0
- package/dist/core.js +2 -0
- package/dist/core.js.map +1 -0
- package/dist/core.mjs +2 -0
- package/dist/core.mjs.map +1 -0
- package/dist/cross-border-BrIy1ieh.d.mts +192 -0
- package/dist/cross-border-BrIy1ieh.d.ts +192 -0
- package/dist/cross-border.d.mts +58 -0
- package/dist/cross-border.d.ts +58 -0
- package/dist/cross-border.js +2 -0
- package/dist/cross-border.js.map +1 -0
- package/dist/cross-border.mjs +2 -0
- package/dist/cross-border.mjs.map +1 -0
- package/dist/dpia-B9ZZJG5a.d.mts +15 -0
- package/dist/dpia-fdtTd2DI.d.ts +15 -0
- package/dist/dpia-vWfE_9bO.d.mts +137 -0
- package/dist/dpia-vWfE_9bO.d.ts +137 -0
- package/dist/dpia.d.mts +179 -0
- package/dist/dpia.d.ts +179 -0
- package/dist/dpia.js +2 -0
- package/dist/dpia.js.map +1 -0
- package/dist/dpia.mjs +2 -0
- package/dist/dpia.mjs.map +1 -0
- package/dist/dsr-jq5NUEdz.d.ts +14 -0
- package/dist/dsr-pQzQ3H1O.d.mts +128 -0
- package/dist/dsr-pQzQ3H1O.d.ts +128 -0
- package/dist/dsr-whPkiI0_.d.mts +14 -0
- package/dist/dsr.d.mts +192 -0
- package/dist/dsr.d.ts +192 -0
- package/dist/dsr.js +2 -0
- package/dist/dsr.js.map +1 -0
- package/dist/dsr.mjs +2 -0
- package/dist/dsr.mjs.map +1 -0
- package/dist/hooks.d.mts +17 -0
- package/dist/hooks.d.ts +17 -0
- package/dist/hooks.js +2 -0
- package/dist/hooks.js.map +1 -0
- package/dist/hooks.mjs +2 -0
- package/dist/hooks.mjs.map +1 -0
- package/dist/index.d.mts +31 -448
- package/dist/index.d.ts +31 -448
- package/dist/index.js +1 -190
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +1 -190
- package/dist/index.mjs.map +1 -1
- package/dist/lawful-basis-CWtvDG1x.d.mts +112 -0
- package/dist/lawful-basis-CWtvDG1x.d.ts +112 -0
- package/dist/lawful-basis-D-oXFizg.d.mts +57 -0
- package/dist/lawful-basis-v04AhbK2.d.ts +57 -0
- package/dist/lawful-basis.d.mts +55 -0
- package/dist/lawful-basis.d.ts +55 -0
- package/dist/lawful-basis.js +2 -0
- package/dist/lawful-basis.js.map +1 -0
- package/dist/lawful-basis.mjs +2 -0
- package/dist/lawful-basis.mjs.map +1 -0
- package/dist/policy.d.mts +195 -0
- package/dist/policy.d.ts +195 -0
- package/dist/policy.js +2 -0
- package/dist/policy.js.map +1 -0
- package/dist/policy.mjs +2 -0
- package/dist/policy.mjs.map +1 -0
- package/dist/privacy-9FcJceMr.d.mts +15 -0
- package/dist/privacy-BXz7O2ej.d.ts +15 -0
- package/dist/privacy-Ca6te9Ir.d.mts +138 -0
- package/dist/privacy-Ca6te9Ir.d.ts +138 -0
- package/dist/ropa-BebGfqKQ.d.ts +200 -0
- package/dist/ropa-Rb4dsFSz.d.mts +200 -0
- package/dist/ropa.d.mts +45 -0
- package/dist/ropa.d.ts +45 -0
- package/dist/ropa.js +2 -0
- package/dist/ropa.js.map +1 -0
- package/dist/ropa.mjs +2 -0
- package/dist/ropa.mjs.map +1 -0
- package/dist/unstyled.d.mts +4 -4
- package/dist/unstyled.d.ts +4 -4
- package/dist/unstyled.js +1 -1
- package/dist/unstyled.js.map +1 -1
- package/dist/unstyled.mjs +1 -1
- package/dist/unstyled.mjs.map +1 -1
- package/dist/useBreach-DRKnexsk.d.mts +99 -0
- package/dist/useBreach-DuT0N0K1.d.ts +99 -0
- package/dist/useConsent-D0pAfTlb.d.ts +65 -0
- package/dist/useConsent-DOt2Njst.d.mts +65 -0
- package/dist/useCrossBorderTransfer-D4FQYfFt.d.ts +66 -0
- package/dist/useCrossBorderTransfer-TVnY8_UX.d.mts +66 -0
- package/dist/useDPIA-DFDHBLSa.d.ts +94 -0
- package/dist/useDPIA-FqPofFaV.d.mts +94 -0
- package/dist/useDSR-DAqqOBXb.d.ts +74 -0
- package/dist/useDSR-OXM5Q9rf.d.mts +74 -0
- package/dist/useLawfulBasis-DNQ8YszQ.d.mts +68 -0
- package/dist/useLawfulBasis-RILM_xsx.d.ts +68 -0
- package/dist/usePrivacyPolicy-CfySfBLS.d.ts +89 -0
- package/dist/usePrivacyPolicy-Dit2sFuV.d.mts +89 -0
- package/dist/useROPA-Bcs6cRdi.d.ts +64 -0
- package/dist/useROPA-nmcSiUYv.d.mts +64 -0
- package/package.json +162 -35
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Data Protection Impact Assessment types aligned with NDPA 2023 Sections 38-39
|
|
3
|
+
* A DPIA is required when processing is likely to result in high risk to data subjects
|
|
4
|
+
*/
|
|
5
|
+
/**
|
|
6
|
+
* Represents a question in the DPIA questionnaire
|
|
7
|
+
*/
|
|
8
|
+
interface DPIAQuestion {
|
|
9
|
+
/** Unique identifier for the question */
|
|
10
|
+
id: string;
|
|
11
|
+
/** The text of the question */
|
|
12
|
+
text: string;
|
|
13
|
+
/** Additional guidance for answering the question */
|
|
14
|
+
guidance?: string;
|
|
15
|
+
/** Type of input required for the answer */
|
|
16
|
+
type: 'text' | 'textarea' | 'select' | 'radio' | 'checkbox' | 'scale';
|
|
17
|
+
/** Options for select, radio, or checkbox questions */
|
|
18
|
+
options?: Array<{
|
|
19
|
+
value: string;
|
|
20
|
+
label: string;
|
|
21
|
+
riskLevel?: 'low' | 'medium' | 'high';
|
|
22
|
+
}>;
|
|
23
|
+
/** For scale questions, the minimum value */
|
|
24
|
+
minValue?: number;
|
|
25
|
+
/** For scale questions, the maximum value */
|
|
26
|
+
maxValue?: number;
|
|
27
|
+
/** For scale questions, labels for the scale points */
|
|
28
|
+
scaleLabels?: Record<number, string>;
|
|
29
|
+
/** Whether the question is required */
|
|
30
|
+
required: boolean;
|
|
31
|
+
/** Risk level associated with this question */
|
|
32
|
+
riskLevel?: 'low' | 'medium' | 'high';
|
|
33
|
+
/** Whether this question triggers additional questions based on the answer */
|
|
34
|
+
hasDependentQuestions?: boolean;
|
|
35
|
+
/** Conditions that determine when this question should be shown */
|
|
36
|
+
showWhen?: Array<{
|
|
37
|
+
questionId: string;
|
|
38
|
+
operator: 'equals' | 'contains' | 'greaterThan' | 'lessThan';
|
|
39
|
+
value: any;
|
|
40
|
+
}>;
|
|
41
|
+
}
|
|
42
|
+
/**
|
|
43
|
+
* Represents a section in the DPIA questionnaire
|
|
44
|
+
*/
|
|
45
|
+
interface DPIASection {
|
|
46
|
+
/** Unique identifier for the section */
|
|
47
|
+
id: string;
|
|
48
|
+
/** Title of the section */
|
|
49
|
+
title: string;
|
|
50
|
+
/** Description of the section */
|
|
51
|
+
description?: string;
|
|
52
|
+
/** Questions in this section */
|
|
53
|
+
questions: DPIAQuestion[];
|
|
54
|
+
/** Order of the section in the questionnaire */
|
|
55
|
+
order: number;
|
|
56
|
+
}
|
|
57
|
+
/**
|
|
58
|
+
* Represents a risk identified in the DPIA
|
|
59
|
+
*/
|
|
60
|
+
interface DPIARisk {
|
|
61
|
+
/** Unique identifier for the risk */
|
|
62
|
+
id: string;
|
|
63
|
+
/** Description of the risk */
|
|
64
|
+
description: string;
|
|
65
|
+
/** Likelihood of the risk occurring (1-5) */
|
|
66
|
+
likelihood: number;
|
|
67
|
+
/** Impact if the risk occurs (1-5) */
|
|
68
|
+
impact: number;
|
|
69
|
+
/** Overall risk score (likelihood * impact) */
|
|
70
|
+
score: number;
|
|
71
|
+
/** Risk level based on the score */
|
|
72
|
+
level: 'low' | 'medium' | 'high' | 'critical';
|
|
73
|
+
/** Measures to mitigate the risk */
|
|
74
|
+
mitigationMeasures?: string[];
|
|
75
|
+
/** Whether the risk has been mitigated */
|
|
76
|
+
mitigated: boolean;
|
|
77
|
+
/** Residual risk score after mitigation */
|
|
78
|
+
residualScore?: number;
|
|
79
|
+
/** Questions that identified this risk */
|
|
80
|
+
relatedQuestionIds: string[];
|
|
81
|
+
}
|
|
82
|
+
/**
|
|
83
|
+
* Represents the result of a completed DPIA
|
|
84
|
+
*/
|
|
85
|
+
interface DPIAResult {
|
|
86
|
+
/** Unique identifier for the DPIA */
|
|
87
|
+
id: string;
|
|
88
|
+
/** Title of the DPIA */
|
|
89
|
+
title: string;
|
|
90
|
+
/** Description of the processing activity being assessed */
|
|
91
|
+
processingDescription: string;
|
|
92
|
+
/** Timestamp when the DPIA was started */
|
|
93
|
+
startedAt: number;
|
|
94
|
+
/** Timestamp when the DPIA was completed */
|
|
95
|
+
completedAt?: number;
|
|
96
|
+
/** Person responsible for conducting the DPIA */
|
|
97
|
+
assessor: {
|
|
98
|
+
name: string;
|
|
99
|
+
role: string;
|
|
100
|
+
email: string;
|
|
101
|
+
};
|
|
102
|
+
/** Answers to all questions in the DPIA */
|
|
103
|
+
answers: Record<string, any>;
|
|
104
|
+
/** Risks identified in the DPIA */
|
|
105
|
+
risks: DPIARisk[];
|
|
106
|
+
/** Overall risk level of the processing activity */
|
|
107
|
+
overallRiskLevel: 'low' | 'medium' | 'high' | 'critical';
|
|
108
|
+
/** Whether the DPIA concluded that the processing can proceed */
|
|
109
|
+
canProceed: boolean;
|
|
110
|
+
/** Reasons why the processing can or cannot proceed */
|
|
111
|
+
conclusion: string;
|
|
112
|
+
/** Recommendations for the processing activity */
|
|
113
|
+
recommendations?: string[];
|
|
114
|
+
/** Next review date for the DPIA */
|
|
115
|
+
reviewDate?: number;
|
|
116
|
+
/** Version of the DPIA questionnaire used */
|
|
117
|
+
version: string;
|
|
118
|
+
/**
|
|
119
|
+
* Whether prior consultation with NDPC is required
|
|
120
|
+
* Per NDPA Section 39, consultation is required when DPIA indicates high residual risk
|
|
121
|
+
*/
|
|
122
|
+
ndpcConsultationRequired?: boolean;
|
|
123
|
+
/** Date when NDPC consultation was initiated */
|
|
124
|
+
ndpcConsultationDate?: number;
|
|
125
|
+
/** Reference number from NDPC consultation */
|
|
126
|
+
ndpcConsultationReference?: string;
|
|
127
|
+
/**
|
|
128
|
+
* The lawful basis for the processing activity being assessed
|
|
129
|
+
*/
|
|
130
|
+
lawfulBasis?: string;
|
|
131
|
+
/**
|
|
132
|
+
* Whether this DPIA involves cross-border data transfers
|
|
133
|
+
*/
|
|
134
|
+
involvesCrossBorderTransfer?: boolean;
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
export type { DPIAQuestion as D, DPIASection as a, DPIAResult as b, DPIARisk as c };
|
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Data Protection Impact Assessment types aligned with NDPA 2023 Sections 38-39
|
|
3
|
+
* A DPIA is required when processing is likely to result in high risk to data subjects
|
|
4
|
+
*/
|
|
5
|
+
/**
|
|
6
|
+
* Represents a question in the DPIA questionnaire
|
|
7
|
+
*/
|
|
8
|
+
interface DPIAQuestion {
|
|
9
|
+
/** Unique identifier for the question */
|
|
10
|
+
id: string;
|
|
11
|
+
/** The text of the question */
|
|
12
|
+
text: string;
|
|
13
|
+
/** Additional guidance for answering the question */
|
|
14
|
+
guidance?: string;
|
|
15
|
+
/** Type of input required for the answer */
|
|
16
|
+
type: 'text' | 'textarea' | 'select' | 'radio' | 'checkbox' | 'scale';
|
|
17
|
+
/** Options for select, radio, or checkbox questions */
|
|
18
|
+
options?: Array<{
|
|
19
|
+
value: string;
|
|
20
|
+
label: string;
|
|
21
|
+
riskLevel?: 'low' | 'medium' | 'high';
|
|
22
|
+
}>;
|
|
23
|
+
/** For scale questions, the minimum value */
|
|
24
|
+
minValue?: number;
|
|
25
|
+
/** For scale questions, the maximum value */
|
|
26
|
+
maxValue?: number;
|
|
27
|
+
/** For scale questions, labels for the scale points */
|
|
28
|
+
scaleLabels?: Record<number, string>;
|
|
29
|
+
/** Whether the question is required */
|
|
30
|
+
required: boolean;
|
|
31
|
+
/** Risk level associated with this question */
|
|
32
|
+
riskLevel?: 'low' | 'medium' | 'high';
|
|
33
|
+
/** Whether this question triggers additional questions based on the answer */
|
|
34
|
+
hasDependentQuestions?: boolean;
|
|
35
|
+
/** Conditions that determine when this question should be shown */
|
|
36
|
+
showWhen?: Array<{
|
|
37
|
+
questionId: string;
|
|
38
|
+
operator: 'equals' | 'contains' | 'greaterThan' | 'lessThan';
|
|
39
|
+
value: any;
|
|
40
|
+
}>;
|
|
41
|
+
}
|
|
42
|
+
/**
|
|
43
|
+
* Represents a section in the DPIA questionnaire
|
|
44
|
+
*/
|
|
45
|
+
interface DPIASection {
|
|
46
|
+
/** Unique identifier for the section */
|
|
47
|
+
id: string;
|
|
48
|
+
/** Title of the section */
|
|
49
|
+
title: string;
|
|
50
|
+
/** Description of the section */
|
|
51
|
+
description?: string;
|
|
52
|
+
/** Questions in this section */
|
|
53
|
+
questions: DPIAQuestion[];
|
|
54
|
+
/** Order of the section in the questionnaire */
|
|
55
|
+
order: number;
|
|
56
|
+
}
|
|
57
|
+
/**
|
|
58
|
+
* Represents a risk identified in the DPIA
|
|
59
|
+
*/
|
|
60
|
+
interface DPIARisk {
|
|
61
|
+
/** Unique identifier for the risk */
|
|
62
|
+
id: string;
|
|
63
|
+
/** Description of the risk */
|
|
64
|
+
description: string;
|
|
65
|
+
/** Likelihood of the risk occurring (1-5) */
|
|
66
|
+
likelihood: number;
|
|
67
|
+
/** Impact if the risk occurs (1-5) */
|
|
68
|
+
impact: number;
|
|
69
|
+
/** Overall risk score (likelihood * impact) */
|
|
70
|
+
score: number;
|
|
71
|
+
/** Risk level based on the score */
|
|
72
|
+
level: 'low' | 'medium' | 'high' | 'critical';
|
|
73
|
+
/** Measures to mitigate the risk */
|
|
74
|
+
mitigationMeasures?: string[];
|
|
75
|
+
/** Whether the risk has been mitigated */
|
|
76
|
+
mitigated: boolean;
|
|
77
|
+
/** Residual risk score after mitigation */
|
|
78
|
+
residualScore?: number;
|
|
79
|
+
/** Questions that identified this risk */
|
|
80
|
+
relatedQuestionIds: string[];
|
|
81
|
+
}
|
|
82
|
+
/**
|
|
83
|
+
* Represents the result of a completed DPIA
|
|
84
|
+
*/
|
|
85
|
+
interface DPIAResult {
|
|
86
|
+
/** Unique identifier for the DPIA */
|
|
87
|
+
id: string;
|
|
88
|
+
/** Title of the DPIA */
|
|
89
|
+
title: string;
|
|
90
|
+
/** Description of the processing activity being assessed */
|
|
91
|
+
processingDescription: string;
|
|
92
|
+
/** Timestamp when the DPIA was started */
|
|
93
|
+
startedAt: number;
|
|
94
|
+
/** Timestamp when the DPIA was completed */
|
|
95
|
+
completedAt?: number;
|
|
96
|
+
/** Person responsible for conducting the DPIA */
|
|
97
|
+
assessor: {
|
|
98
|
+
name: string;
|
|
99
|
+
role: string;
|
|
100
|
+
email: string;
|
|
101
|
+
};
|
|
102
|
+
/** Answers to all questions in the DPIA */
|
|
103
|
+
answers: Record<string, any>;
|
|
104
|
+
/** Risks identified in the DPIA */
|
|
105
|
+
risks: DPIARisk[];
|
|
106
|
+
/** Overall risk level of the processing activity */
|
|
107
|
+
overallRiskLevel: 'low' | 'medium' | 'high' | 'critical';
|
|
108
|
+
/** Whether the DPIA concluded that the processing can proceed */
|
|
109
|
+
canProceed: boolean;
|
|
110
|
+
/** Reasons why the processing can or cannot proceed */
|
|
111
|
+
conclusion: string;
|
|
112
|
+
/** Recommendations for the processing activity */
|
|
113
|
+
recommendations?: string[];
|
|
114
|
+
/** Next review date for the DPIA */
|
|
115
|
+
reviewDate?: number;
|
|
116
|
+
/** Version of the DPIA questionnaire used */
|
|
117
|
+
version: string;
|
|
118
|
+
/**
|
|
119
|
+
* Whether prior consultation with NDPC is required
|
|
120
|
+
* Per NDPA Section 39, consultation is required when DPIA indicates high residual risk
|
|
121
|
+
*/
|
|
122
|
+
ndpcConsultationRequired?: boolean;
|
|
123
|
+
/** Date when NDPC consultation was initiated */
|
|
124
|
+
ndpcConsultationDate?: number;
|
|
125
|
+
/** Reference number from NDPC consultation */
|
|
126
|
+
ndpcConsultationReference?: string;
|
|
127
|
+
/**
|
|
128
|
+
* The lawful basis for the processing activity being assessed
|
|
129
|
+
*/
|
|
130
|
+
lawfulBasis?: string;
|
|
131
|
+
/**
|
|
132
|
+
* Whether this DPIA involves cross-border data transfers
|
|
133
|
+
*/
|
|
134
|
+
involvesCrossBorderTransfer?: boolean;
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
export type { DPIAQuestion as D, DPIASection as a, DPIAResult as b, DPIARisk as c };
|
package/dist/dpia.d.mts
ADDED
|
@@ -0,0 +1,179 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { a as DPIASection, b as DPIAResult } from './dpia-vWfE_9bO.mjs';
|
|
3
|
+
export { D as DPIAQuestion, c as DPIARisk } from './dpia-vWfE_9bO.mjs';
|
|
4
|
+
export { u as useDPIA } from './useDPIA-FqPofFaV.mjs';
|
|
5
|
+
export { a as assessDPIARisk } from './dpia-B9ZZJG5a.mjs';
|
|
6
|
+
|
|
7
|
+
interface DPIAQuestionnaireProps {
|
|
8
|
+
/**
|
|
9
|
+
* Sections of the DPIA questionnaire
|
|
10
|
+
*/
|
|
11
|
+
sections: DPIASection[];
|
|
12
|
+
/**
|
|
13
|
+
* Current answers to the questionnaire
|
|
14
|
+
*/
|
|
15
|
+
answers: Record<string, any>;
|
|
16
|
+
/**
|
|
17
|
+
* Callback function called when an answer is updated
|
|
18
|
+
*/
|
|
19
|
+
onAnswerChange: (questionId: string, value: any) => void;
|
|
20
|
+
/**
|
|
21
|
+
* Current section index
|
|
22
|
+
*/
|
|
23
|
+
currentSectionIndex: number;
|
|
24
|
+
/**
|
|
25
|
+
* Callback function called when user navigates to the next section
|
|
26
|
+
*/
|
|
27
|
+
onNextSection?: () => void;
|
|
28
|
+
/**
|
|
29
|
+
* Callback function called when user navigates to the previous section
|
|
30
|
+
*/
|
|
31
|
+
onPrevSection?: () => void;
|
|
32
|
+
/**
|
|
33
|
+
* Validation errors for the current section
|
|
34
|
+
*/
|
|
35
|
+
validationErrors?: Record<string, string>;
|
|
36
|
+
/**
|
|
37
|
+
* Whether the questionnaire is in read-only mode
|
|
38
|
+
* @default false
|
|
39
|
+
*/
|
|
40
|
+
readOnly?: boolean;
|
|
41
|
+
/**
|
|
42
|
+
* Custom CSS class for the questionnaire
|
|
43
|
+
*/
|
|
44
|
+
className?: string;
|
|
45
|
+
/**
|
|
46
|
+
* Custom CSS class for the buttons
|
|
47
|
+
*/
|
|
48
|
+
buttonClassName?: string;
|
|
49
|
+
/**
|
|
50
|
+
* Text for the next button
|
|
51
|
+
* @default "Next"
|
|
52
|
+
*/
|
|
53
|
+
nextButtonText?: string;
|
|
54
|
+
/**
|
|
55
|
+
* Text for the previous button
|
|
56
|
+
* @default "Previous"
|
|
57
|
+
*/
|
|
58
|
+
prevButtonText?: string;
|
|
59
|
+
/**
|
|
60
|
+
* Text for the submit button (shown on the last section)
|
|
61
|
+
* @default "Submit"
|
|
62
|
+
*/
|
|
63
|
+
submitButtonText?: string;
|
|
64
|
+
/**
|
|
65
|
+
* Whether to show a progress indicator
|
|
66
|
+
* @default true
|
|
67
|
+
*/
|
|
68
|
+
showProgress?: boolean;
|
|
69
|
+
/**
|
|
70
|
+
* Current progress percentage (0-100)
|
|
71
|
+
*/
|
|
72
|
+
progress?: number;
|
|
73
|
+
}
|
|
74
|
+
declare const DPIAQuestionnaire: React.FC<DPIAQuestionnaireProps>;
|
|
75
|
+
|
|
76
|
+
interface DPIAReportProps {
|
|
77
|
+
/**
|
|
78
|
+
* The DPIA result to display
|
|
79
|
+
*/
|
|
80
|
+
result: DPIAResult;
|
|
81
|
+
/**
|
|
82
|
+
* The sections of the DPIA questionnaire
|
|
83
|
+
*/
|
|
84
|
+
sections: DPIASection[];
|
|
85
|
+
/**
|
|
86
|
+
* Whether to show the full report or just a summary
|
|
87
|
+
* @default true
|
|
88
|
+
*/
|
|
89
|
+
showFullReport?: boolean;
|
|
90
|
+
/**
|
|
91
|
+
* Whether to allow printing the report
|
|
92
|
+
* @default true
|
|
93
|
+
*/
|
|
94
|
+
allowPrint?: boolean;
|
|
95
|
+
/**
|
|
96
|
+
* Whether to allow exporting the report as PDF
|
|
97
|
+
* @default true
|
|
98
|
+
*/
|
|
99
|
+
allowExport?: boolean;
|
|
100
|
+
/**
|
|
101
|
+
* Callback function called when the report is exported
|
|
102
|
+
*/
|
|
103
|
+
onExport?: (format: 'pdf' | 'docx' | 'html') => void;
|
|
104
|
+
/**
|
|
105
|
+
* Custom CSS class for the report container
|
|
106
|
+
*/
|
|
107
|
+
className?: string;
|
|
108
|
+
/**
|
|
109
|
+
* Custom CSS class for the buttons
|
|
110
|
+
*/
|
|
111
|
+
buttonClassName?: string;
|
|
112
|
+
}
|
|
113
|
+
declare const DPIAReport: React.FC<DPIAReportProps>;
|
|
114
|
+
|
|
115
|
+
interface Step {
|
|
116
|
+
/**
|
|
117
|
+
* Unique identifier for the step
|
|
118
|
+
*/
|
|
119
|
+
id: string;
|
|
120
|
+
/**
|
|
121
|
+
* Display label for the step
|
|
122
|
+
*/
|
|
123
|
+
label: string;
|
|
124
|
+
/**
|
|
125
|
+
* Optional description for the step
|
|
126
|
+
*/
|
|
127
|
+
description?: string;
|
|
128
|
+
/**
|
|
129
|
+
* Whether the step is completed
|
|
130
|
+
*/
|
|
131
|
+
completed: boolean;
|
|
132
|
+
/**
|
|
133
|
+
* Whether the step is the current active step
|
|
134
|
+
*/
|
|
135
|
+
active: boolean;
|
|
136
|
+
/**
|
|
137
|
+
* Optional icon for the step
|
|
138
|
+
*/
|
|
139
|
+
icon?: React.ReactNode;
|
|
140
|
+
}
|
|
141
|
+
interface StepIndicatorProps {
|
|
142
|
+
/**
|
|
143
|
+
* Array of steps to display
|
|
144
|
+
*/
|
|
145
|
+
steps: Step[];
|
|
146
|
+
/**
|
|
147
|
+
* Callback function called when a step is clicked
|
|
148
|
+
*/
|
|
149
|
+
onStepClick?: (stepId: string) => void;
|
|
150
|
+
/**
|
|
151
|
+
* Whether the steps are clickable
|
|
152
|
+
* @default true
|
|
153
|
+
*/
|
|
154
|
+
clickable?: boolean;
|
|
155
|
+
/**
|
|
156
|
+
* Orientation of the step indicator
|
|
157
|
+
* @default "horizontal"
|
|
158
|
+
*/
|
|
159
|
+
orientation?: 'horizontal' | 'vertical';
|
|
160
|
+
/**
|
|
161
|
+
* Custom CSS class for the container
|
|
162
|
+
*/
|
|
163
|
+
className?: string;
|
|
164
|
+
/**
|
|
165
|
+
* Custom CSS class for the active step
|
|
166
|
+
*/
|
|
167
|
+
activeStepClassName?: string;
|
|
168
|
+
/**
|
|
169
|
+
* Custom CSS class for completed steps
|
|
170
|
+
*/
|
|
171
|
+
completedStepClassName?: string;
|
|
172
|
+
/**
|
|
173
|
+
* Custom CSS class for incomplete steps
|
|
174
|
+
*/
|
|
175
|
+
incompleteStepClassName?: string;
|
|
176
|
+
}
|
|
177
|
+
declare const StepIndicator: React.FC<StepIndicatorProps>;
|
|
178
|
+
|
|
179
|
+
export { DPIAQuestionnaire, DPIAReport, DPIAResult, DPIASection, StepIndicator };
|
package/dist/dpia.d.ts
ADDED
|
@@ -0,0 +1,179 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { a as DPIASection, b as DPIAResult } from './dpia-vWfE_9bO.js';
|
|
3
|
+
export { D as DPIAQuestion, c as DPIARisk } from './dpia-vWfE_9bO.js';
|
|
4
|
+
export { u as useDPIA } from './useDPIA-DFDHBLSa.js';
|
|
5
|
+
export { a as assessDPIARisk } from './dpia-fdtTd2DI.js';
|
|
6
|
+
|
|
7
|
+
interface DPIAQuestionnaireProps {
|
|
8
|
+
/**
|
|
9
|
+
* Sections of the DPIA questionnaire
|
|
10
|
+
*/
|
|
11
|
+
sections: DPIASection[];
|
|
12
|
+
/**
|
|
13
|
+
* Current answers to the questionnaire
|
|
14
|
+
*/
|
|
15
|
+
answers: Record<string, any>;
|
|
16
|
+
/**
|
|
17
|
+
* Callback function called when an answer is updated
|
|
18
|
+
*/
|
|
19
|
+
onAnswerChange: (questionId: string, value: any) => void;
|
|
20
|
+
/**
|
|
21
|
+
* Current section index
|
|
22
|
+
*/
|
|
23
|
+
currentSectionIndex: number;
|
|
24
|
+
/**
|
|
25
|
+
* Callback function called when user navigates to the next section
|
|
26
|
+
*/
|
|
27
|
+
onNextSection?: () => void;
|
|
28
|
+
/**
|
|
29
|
+
* Callback function called when user navigates to the previous section
|
|
30
|
+
*/
|
|
31
|
+
onPrevSection?: () => void;
|
|
32
|
+
/**
|
|
33
|
+
* Validation errors for the current section
|
|
34
|
+
*/
|
|
35
|
+
validationErrors?: Record<string, string>;
|
|
36
|
+
/**
|
|
37
|
+
* Whether the questionnaire is in read-only mode
|
|
38
|
+
* @default false
|
|
39
|
+
*/
|
|
40
|
+
readOnly?: boolean;
|
|
41
|
+
/**
|
|
42
|
+
* Custom CSS class for the questionnaire
|
|
43
|
+
*/
|
|
44
|
+
className?: string;
|
|
45
|
+
/**
|
|
46
|
+
* Custom CSS class for the buttons
|
|
47
|
+
*/
|
|
48
|
+
buttonClassName?: string;
|
|
49
|
+
/**
|
|
50
|
+
* Text for the next button
|
|
51
|
+
* @default "Next"
|
|
52
|
+
*/
|
|
53
|
+
nextButtonText?: string;
|
|
54
|
+
/**
|
|
55
|
+
* Text for the previous button
|
|
56
|
+
* @default "Previous"
|
|
57
|
+
*/
|
|
58
|
+
prevButtonText?: string;
|
|
59
|
+
/**
|
|
60
|
+
* Text for the submit button (shown on the last section)
|
|
61
|
+
* @default "Submit"
|
|
62
|
+
*/
|
|
63
|
+
submitButtonText?: string;
|
|
64
|
+
/**
|
|
65
|
+
* Whether to show a progress indicator
|
|
66
|
+
* @default true
|
|
67
|
+
*/
|
|
68
|
+
showProgress?: boolean;
|
|
69
|
+
/**
|
|
70
|
+
* Current progress percentage (0-100)
|
|
71
|
+
*/
|
|
72
|
+
progress?: number;
|
|
73
|
+
}
|
|
74
|
+
declare const DPIAQuestionnaire: React.FC<DPIAQuestionnaireProps>;
|
|
75
|
+
|
|
76
|
+
interface DPIAReportProps {
|
|
77
|
+
/**
|
|
78
|
+
* The DPIA result to display
|
|
79
|
+
*/
|
|
80
|
+
result: DPIAResult;
|
|
81
|
+
/**
|
|
82
|
+
* The sections of the DPIA questionnaire
|
|
83
|
+
*/
|
|
84
|
+
sections: DPIASection[];
|
|
85
|
+
/**
|
|
86
|
+
* Whether to show the full report or just a summary
|
|
87
|
+
* @default true
|
|
88
|
+
*/
|
|
89
|
+
showFullReport?: boolean;
|
|
90
|
+
/**
|
|
91
|
+
* Whether to allow printing the report
|
|
92
|
+
* @default true
|
|
93
|
+
*/
|
|
94
|
+
allowPrint?: boolean;
|
|
95
|
+
/**
|
|
96
|
+
* Whether to allow exporting the report as PDF
|
|
97
|
+
* @default true
|
|
98
|
+
*/
|
|
99
|
+
allowExport?: boolean;
|
|
100
|
+
/**
|
|
101
|
+
* Callback function called when the report is exported
|
|
102
|
+
*/
|
|
103
|
+
onExport?: (format: 'pdf' | 'docx' | 'html') => void;
|
|
104
|
+
/**
|
|
105
|
+
* Custom CSS class for the report container
|
|
106
|
+
*/
|
|
107
|
+
className?: string;
|
|
108
|
+
/**
|
|
109
|
+
* Custom CSS class for the buttons
|
|
110
|
+
*/
|
|
111
|
+
buttonClassName?: string;
|
|
112
|
+
}
|
|
113
|
+
declare const DPIAReport: React.FC<DPIAReportProps>;
|
|
114
|
+
|
|
115
|
+
interface Step {
|
|
116
|
+
/**
|
|
117
|
+
* Unique identifier for the step
|
|
118
|
+
*/
|
|
119
|
+
id: string;
|
|
120
|
+
/**
|
|
121
|
+
* Display label for the step
|
|
122
|
+
*/
|
|
123
|
+
label: string;
|
|
124
|
+
/**
|
|
125
|
+
* Optional description for the step
|
|
126
|
+
*/
|
|
127
|
+
description?: string;
|
|
128
|
+
/**
|
|
129
|
+
* Whether the step is completed
|
|
130
|
+
*/
|
|
131
|
+
completed: boolean;
|
|
132
|
+
/**
|
|
133
|
+
* Whether the step is the current active step
|
|
134
|
+
*/
|
|
135
|
+
active: boolean;
|
|
136
|
+
/**
|
|
137
|
+
* Optional icon for the step
|
|
138
|
+
*/
|
|
139
|
+
icon?: React.ReactNode;
|
|
140
|
+
}
|
|
141
|
+
interface StepIndicatorProps {
|
|
142
|
+
/**
|
|
143
|
+
* Array of steps to display
|
|
144
|
+
*/
|
|
145
|
+
steps: Step[];
|
|
146
|
+
/**
|
|
147
|
+
* Callback function called when a step is clicked
|
|
148
|
+
*/
|
|
149
|
+
onStepClick?: (stepId: string) => void;
|
|
150
|
+
/**
|
|
151
|
+
* Whether the steps are clickable
|
|
152
|
+
* @default true
|
|
153
|
+
*/
|
|
154
|
+
clickable?: boolean;
|
|
155
|
+
/**
|
|
156
|
+
* Orientation of the step indicator
|
|
157
|
+
* @default "horizontal"
|
|
158
|
+
*/
|
|
159
|
+
orientation?: 'horizontal' | 'vertical';
|
|
160
|
+
/**
|
|
161
|
+
* Custom CSS class for the container
|
|
162
|
+
*/
|
|
163
|
+
className?: string;
|
|
164
|
+
/**
|
|
165
|
+
* Custom CSS class for the active step
|
|
166
|
+
*/
|
|
167
|
+
activeStepClassName?: string;
|
|
168
|
+
/**
|
|
169
|
+
* Custom CSS class for completed steps
|
|
170
|
+
*/
|
|
171
|
+
completedStepClassName?: string;
|
|
172
|
+
/**
|
|
173
|
+
* Custom CSS class for incomplete steps
|
|
174
|
+
*/
|
|
175
|
+
incompleteStepClassName?: string;
|
|
176
|
+
}
|
|
177
|
+
declare const StepIndicator: React.FC<StepIndicatorProps>;
|
|
178
|
+
|
|
179
|
+
export { DPIAQuestionnaire, DPIAReport, DPIAResult, DPIASection, StepIndicator };
|
package/dist/dpia.js
ADDED
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
'use strict';var chunkRHWW5FDP_js=require('./chunk-RHWW5FDP.js'),chunkU2CGMEWB_js=require('./chunk-U2CGMEWB.js'),chunkSSGJREE3_js=require('./chunk-SSGJREE3.js');require('./chunk-MQFZHA2D.js');Object.defineProperty(exports,"DPIAQuestionnaire",{enumerable:true,get:function(){return chunkRHWW5FDP_js.a}});Object.defineProperty(exports,"DPIAReport",{enumerable:true,get:function(){return chunkRHWW5FDP_js.b}});Object.defineProperty(exports,"StepIndicator",{enumerable:true,get:function(){return chunkRHWW5FDP_js.c}});Object.defineProperty(exports,"useDPIA",{enumerable:true,get:function(){return chunkU2CGMEWB_js.a}});Object.defineProperty(exports,"assessDPIARisk",{enumerable:true,get:function(){return chunkSSGJREE3_js.a}});//# sourceMappingURL=dpia.js.map
|
|
2
|
+
//# sourceMappingURL=dpia.js.map
|
package/dist/dpia.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"dpia.js"}
|
package/dist/dpia.mjs
ADDED
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
export{a as DPIAQuestionnaire,b as DPIAReport,c as StepIndicator}from'./chunk-XMKA6GVK.mjs';export{a as useDPIA}from'./chunk-EWOZKYLY.mjs';export{a as assessDPIARisk}from'./chunk-PGSA2O5P.mjs';import'./chunk-WWT2ZSNU.mjs';//# sourceMappingURL=dpia.mjs.map
|
|
2
|
+
//# sourceMappingURL=dpia.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"dpia.mjs"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { D as DSRRequest } from './dsr-pQzQ3H1O.js';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Formats a DSR request for display or submission
|
|
5
|
+
* @param request The DSR request to format
|
|
6
|
+
* @returns Formatted request data
|
|
7
|
+
*/
|
|
8
|
+
declare function formatDSRRequest(request: DSRRequest): {
|
|
9
|
+
formattedRequest: Record<string, any>;
|
|
10
|
+
isValid: boolean;
|
|
11
|
+
validationErrors: string[];
|
|
12
|
+
};
|
|
13
|
+
|
|
14
|
+
export { formatDSRRequest as f };
|