@soyio/soyio-widget 2.25.0 → 2.25.2
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 +2 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +59 -54
- package/dist/index.umd.cjs +8 -8
- package/package.json +3 -1
- package/src/schemas/config.schema.json +4 -0
package/README.md
CHANGED
|
@@ -86,6 +86,7 @@ The **`ConsentBox`** is a component that allows you to embed a consent request d
|
|
|
86
86
|
optionalReconsentBehavior: "notice", // Optional
|
|
87
87
|
mandatoryReconsentBehavior: "notice", // Optional
|
|
88
88
|
allowGranularScopeSelection: true, // Optional
|
|
89
|
+
metadata: { key: "value" }, // Optional
|
|
89
90
|
};
|
|
90
91
|
|
|
91
92
|
// Wait for DOM to be fully loaded
|
|
@@ -142,6 +143,7 @@ The `onEvent` follows the following format:
|
|
|
142
143
|
|
|
143
144
|
We don't support hiding the mandatory consent, and we strongly recommend using `notice` so the user doesn't have to give the consent again and knows what they have already given consent to.
|
|
144
145
|
- **`allowGranularScopeSelection`**: Enables selecting consent at a more granular scope when the template supports granular scopes.
|
|
146
|
+
- **`metadata`**: An optional object with arbitrary metadata to attach to the consent. This metadata will be included in the consent record. The object must be serializable to JSON; properties with non-serializable values (like functions or `undefined`) will be omitted.
|
|
145
147
|
|
|
146
148
|
## Privacy Center
|
|
147
149
|
|
package/dist/index.d.ts
CHANGED
|
@@ -85,6 +85,7 @@ declare type ConsentConfig = BaseConfig & {
|
|
|
85
85
|
optionalReconsentBehavior?: 'notice' | 'askAgain' | 'hide';
|
|
86
86
|
mandatoryReconsentBehavior?: 'notice' | 'askAgain';
|
|
87
87
|
allowGranularScopeSelection?: boolean;
|
|
88
|
+
metadata?: Record<string, unknown>;
|
|
88
89
|
};
|
|
89
90
|
|
|
90
91
|
declare type ConsentEvent = ConsentCheckboxChangeEvent;
|