@usercentrics/react-native-sdk 2.10.0 → 2.11.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 (63) hide show
  1. package/CHANGELOG.md +29 -0
  2. package/android/build.gradle +1 -1
  3. package/android/src/androidTest/java/com/usercentrics/reactnativemodule/RNUsercentricsModuleTest.kt +84 -123
  4. package/android/src/androidTest/java/com/usercentrics/reactnativemodule/mock/GetCMPDataMock.kt +647 -499
  5. package/android/src/androidTest/java/com/usercentrics/reactnativemodule/mock/GetTCFDataMock.kt +14 -4
  6. package/android/src/androidTest/java/com/usercentrics/reactnativemodule/mock/SaveDecisionsForTCFMock.kt +7 -1
  7. package/android/src/main/java/com/usercentrics/reactnativeusercentrics/RNUsercentricsModule.kt +10 -1
  8. package/android/src/main/java/com/usercentrics/reactnativeusercentrics/extensions/ConsentDisclosureSerializer.kt +24 -0
  9. package/android/src/main/java/com/usercentrics/reactnativeusercentrics/extensions/TCFDataExtensions.kt +12 -4
  10. package/android/src/main/java/com/usercentrics/reactnativeusercentrics/extensions/UserDecisionExtensions.kt +18 -1
  11. package/android/src/main/java/com/usercentrics/reactnativeusercentrics/extensions/UsercentricsCMPDataExtensions.kt +85 -7
  12. package/ios/Extensions/TCFData+Dict.swift +14 -1
  13. package/ios/Extensions/TCFUserDecisions+Dict.swift +12 -1
  14. package/ios/Extensions/UsercentricsCMPData+Dict.swift +96 -7
  15. package/ios/Manager/UsercentricsManager.swift +6 -1
  16. package/ios/RNUsercentricsModule.m +3 -0
  17. package/ios/RNUsercentricsModule.swift +7 -3
  18. package/lib/Usercentrics.d.ts +5 -3
  19. package/lib/Usercentrics.js +4 -0
  20. package/lib/Usercentrics.js.map +1 -1
  21. package/lib/models/AdditionalConsentModeData.d.ts +12 -0
  22. package/lib/models/AdditionalConsentModeData.js +15 -0
  23. package/lib/models/AdditionalConsentModeData.js.map +1 -0
  24. package/lib/models/BannerSettings.js.map +1 -1
  25. package/lib/models/CCPAData.js.map +1 -1
  26. package/lib/models/CCPASettings.js.map +1 -1
  27. package/lib/models/ConsentDisclosureObject.d.ts +20 -0
  28. package/lib/models/ConsentDisclosureObject.js +24 -0
  29. package/lib/models/ConsentDisclosureObject.js.map +1 -0
  30. package/lib/models/FirstLayerSettings.js.map +1 -1
  31. package/lib/models/NetworkMode.js.map +1 -1
  32. package/lib/models/SecondLayerSettings.js.map +1 -1
  33. package/lib/models/TCF2Settings.d.ts +24 -1
  34. package/lib/models/TCF2Settings.js +27 -1
  35. package/lib/models/TCF2Settings.js.map +1 -1
  36. package/lib/models/TCFData.d.ts +16 -2
  37. package/lib/models/TCFData.js +17 -2
  38. package/lib/models/TCFData.js.map +1 -1
  39. package/lib/models/TCFDecisionUILayer.js.map +1 -1
  40. package/lib/models/TCFUserDecisions.d.ts +10 -4
  41. package/lib/models/TCFUserDecisions.js +8 -1
  42. package/lib/models/TCFUserDecisions.js.map +1 -1
  43. package/lib/models/UsercentricsAnalyticsEventType.js.map +1 -1
  44. package/lib/models/UsercentricsCMPData.js.map +1 -1
  45. package/lib/models/UsercentricsCategory.js.map +1 -1
  46. package/lib/models/UsercentricsConsentType.js.map +1 -1
  47. package/lib/models/UsercentricsConsentUserResponse.js.map +1 -1
  48. package/lib/models/UsercentricsLabels.d.ts +8 -1
  49. package/lib/models/UsercentricsLabels.js +8 -1
  50. package/lib/models/UsercentricsLabels.js.map +1 -1
  51. package/lib/models/UsercentricsLoggerLevel.js.map +1 -1
  52. package/lib/models/UsercentricsOptions.js.map +1 -1
  53. package/lib/models/UsercentricsReadyStatus.js.map +1 -1
  54. package/lib/models/UsercentricsService.d.ts +4 -1
  55. package/lib/models/UsercentricsService.js +3 -1
  56. package/lib/models/UsercentricsService.js.map +1 -1
  57. package/lib/models/UsercentricsServiceConsent.js.map +1 -1
  58. package/lib/models/UsercentricsSettings.d.ts +33 -4
  59. package/lib/models/UsercentricsSettings.js +38 -3
  60. package/lib/models/UsercentricsSettings.js.map +1 -1
  61. package/lib/models/UsercentricsUserInteraction.js.map +1 -1
  62. package/lib/models/UsercentricsVariant.js.map +1 -1
  63. package/package.json +2 -2
@@ -1,516 +1,664 @@
1
1
  package com.usercentrics.reactnativemodule.mock
2
2
 
3
+ import com.usercentrics.sdk.AdTechProvider
4
+ import com.usercentrics.sdk.AdditionalConsentModeData
5
+ import com.usercentrics.sdk.models.settings.USAFrameworks
3
6
  import com.usercentrics.sdk.v2.location.data.UsercentricsLocation
4
- import com.usercentrics.sdk.v2.settings.data.*
7
+ import com.usercentrics.sdk.v2.settings.data.CCPASettings
8
+ import com.usercentrics.sdk.v2.settings.data.ConsentDisclosure
9
+ import com.usercentrics.sdk.v2.settings.data.ConsentDisclosureObject
10
+ import com.usercentrics.sdk.v2.settings.data.ConsentDisclosureType
11
+ import com.usercentrics.sdk.v2.settings.data.CustomizationColor
12
+ import com.usercentrics.sdk.v2.settings.data.CustomizationFont
13
+ import com.usercentrics.sdk.v2.settings.data.DpsDisplayFormat
14
+ import com.usercentrics.sdk.v2.settings.data.FirstLayer
15
+ import com.usercentrics.sdk.v2.settings.data.FirstLayerMobileVariant
16
+ import com.usercentrics.sdk.v2.settings.data.PublishedApp
17
+ import com.usercentrics.sdk.v2.settings.data.PublishedAppPlatform
18
+ import com.usercentrics.sdk.v2.settings.data.SecondLayer
19
+ import com.usercentrics.sdk.v2.settings.data.TCF2ChangedPurposes
20
+ import com.usercentrics.sdk.v2.settings.data.TCF2Scope
21
+ import com.usercentrics.sdk.v2.settings.data.TCF2Settings
22
+ import com.usercentrics.sdk.v2.settings.data.UsercentricsCategory
23
+ import com.usercentrics.sdk.v2.settings.data.UsercentricsCustomization
24
+ import com.usercentrics.sdk.v2.settings.data.UsercentricsLabels
25
+ import com.usercentrics.sdk.v2.settings.data.UsercentricsService
26
+ import com.usercentrics.sdk.v2.settings.data.UsercentricsSettings
27
+ import com.usercentrics.sdk.v2.settings.data.VariantsSettings
5
28
 
6
- internal class GetCMPDataMock {
7
- companion object {
8
- val fakeCategories = listOf(
9
- UsercentricsCategory(
10
- categorySlug = "essential",
11
- description = "These technologies are required to activate the core functionality of the website.",
12
- isEssential = true,
13
- label = "Essential",
14
- )
29
+ internal object GetCMPDataMock {
30
+
31
+ val fakeCategories = listOf(
32
+ UsercentricsCategory(
33
+ categorySlug = "essential",
34
+ description = "These technologies are required to activate the core functionality of the website.",
35
+ isEssential = true,
36
+ label = "Essential",
15
37
  )
16
- val fakeUserLocation = UsercentricsLocation(
17
- countryCode = "PT",
18
- regionCode = ""
38
+ )
39
+ val fakeUserLocation = UsercentricsLocation(
40
+ countryCode = "PT",
41
+ regionCode = ""
42
+ )
43
+ val fakeServices = listOf(
44
+ UsercentricsService(
45
+ templateId = "ABC",
46
+ version = "1.2.3",
47
+ type = "predefined",
48
+ dataProcessor = "Google Ads",
49
+ dataPurposes = listOf("Advertising Conversion Tracking"),
50
+ processingCompany = "Google Ireland Limited, Google Building Gordon House",
51
+ nameOfProcessingCompany = "Google Ireland Limited",
52
+ addressOfProcessingCompany = "Google Building Gordon House",
53
+ descriptionOfService = "This is a conversion tracking service. ",
54
+ languagesAvailable = listOf("en"),
55
+ dataCollectedList = listOf("IP adress"),
56
+ dataPurposesList = listOf("Analytics"),
57
+ dataRecipientsList = listOf("Google Ireland Limited"),
58
+ legalBasisList = listOf("Art. 6 para. 1 s. 1 lit. a GDPR"),
59
+ retentionPeriodList = listOf(),
60
+ subConsents = listOf(),
61
+ language = "en",
62
+ linkToDpa = "",
63
+ legalGround = "Art. 6 para. 1 s. 1 lit. c GDPR",
64
+ optOutUrl = "",
65
+ policyOfProcessorUrl = "https://usercentrics.com/de/datenschutzerklarung/",
66
+ categorySlug = "essential",
67
+ retentionPeriodDescription = "The consent data (given consent and revocation of consent) are stored for three years. The data will then be deleted immediately or given to the person responsible on request in the form of a data export.",
68
+ dataProtectionOfficer = "datenschutz@usercentrics.com",
69
+ privacyPolicyURL = "https://usercentrics.com/privacy-policy/",
70
+ cookiePolicyURL = "",
71
+ locationOfProcessing = "European Union",
72
+ dataCollectedDescription = "",
73
+ thirdCountryTransfer = "Worldwide",
74
+ description = "",
75
+ isDeactivated = false,
76
+ disableLegalBasis = false,
77
+ technologyUsed = listOf("Cookies", "Pixel Tags"),
78
+ deviceStorage = ConsentDisclosureObject(
79
+ disclosures = listOf(
80
+ ConsentDisclosure(
81
+ identifier = "identifier",
82
+ type = ConsentDisclosureType.APP,
83
+ name = "name",
84
+ maxAgeSeconds = 123123,
85
+ cookieRefresh = true,
86
+ purposes = listOf(1, 2, 3),
87
+ domain = "domain",
88
+ description = "description",
89
+ )
90
+ )
91
+ ),
92
+ isHidden = false,
19
93
  )
20
- val fakeServices = listOf(
21
- UsercentricsService(
22
- templateId = "ABC",
23
- version = "1.2.3",
24
- type = "predefined",
25
- dataProcessor = "Google Ads",
26
- dataPurposes = listOf("Advertising Conversion Tracking"),
27
- processingCompany = "Google Ireland Limited, Google Building Gordon House",
28
- nameOfProcessingCompany = "Google Ireland Limited",
29
- addressOfProcessingCompany = "Google Building Gordon House",
30
- descriptionOfService = "This is a conversion tracking service. ",
31
- languagesAvailable = listOf("en"),
32
- dataCollectedList = listOf("IP adress"),
33
- dataPurposesList = listOf("Analytics"),
34
- dataRecipientsList = listOf("Google Ireland Limited"),
35
- legalBasisList = listOf("Art. 6 para. 1 s. 1 lit. a GDPR"),
36
- retentionPeriodList = listOf(),
37
- subConsents = listOf(),
38
- language = "en",
39
- linkToDpa = "",
40
- legalGround = "Art. 6 para. 1 s. 1 lit. c GDPR",
41
- optOutUrl = "",
42
- policyOfProcessorUrl = "https://usercentrics.com/de/datenschutzerklarung/",
43
- categorySlug = "essential",
44
- retentionPeriodDescription = "The consent data (given consent and revocation of consent) are stored for three years. The data will then be deleted immediately or given to the person responsible on request in the form of a data export.",
45
- dataProtectionOfficer = "datenschutz@usercentrics.com",
46
- privacyPolicyURL = "https://usercentrics.com/privacy-policy/",
47
- cookiePolicyURL = "",
48
- locationOfProcessing = "European Union",
49
- dataCollectedDescription = "",
50
- thirdCountryTransfer = "Worldwide",
51
- description = "",
52
- isDeactivated = false,
53
- disableLegalBasis = false,
54
- technologyUsed = listOf("Cookies", "Pixel Tags")
94
+ )
95
+ private val fakeLabels = UsercentricsLabels(
96
+ dataPurposes = "Data Purposes",
97
+ accepted = "yes",
98
+ denied = "no",
99
+ history = "History",
100
+ settings = "Settings",
101
+ subConsents = "Subservices",
102
+ btnAccept = "Accept",
103
+ btnDeny = "Deny",
104
+ secondLayerTitle = "Privacy Settings Title",
105
+ secondLayerDescriptionHtml = "Privacy Settings Description",
106
+ btnMore = "more",
107
+ poweredBy = "Powered by <a href=\"https://usercentrics.com/?utm_source=cmp&utm_medium=powered_by\" rel=\"nofollow\" target=\"_blank\">Usercentrics Consent Management</a>",
108
+ technologiesUsed = "Technologies Used",
109
+ dataCollectedList = "Data Collected",
110
+ processingCompanyTitle = "Processing Company",
111
+ legalBasisList = "Legal Basis",
112
+ retentionPeriod = "Retention Period",
113
+ locationOfProcessing = "Location of Processing",
114
+ transferToThirdCountries = "Transfer to Third Countries",
115
+ furtherInformationOptOut = "Further Information and Opt-Out",
116
+ dataProtectionOfficer = "Data Protection Officer of Processing Company",
117
+ nameOfProcessingCompany = "Processing Company",
118
+ addressOfProcessingCompany = "Address of processing company",
119
+ optOut = "Click here to opt out from this processor across all domains",
120
+ policyOf = "Click here to read the privacy policy of the data processor",
121
+ dataCollectedInfo = "This list represents all (personal) data that is collected by or through the use of this service.",
122
+ legalBasisInfo = "In the following the required legal basis for the processing of data is listed.",
123
+ dataRecipientsList = "Data Recipients",
124
+ transferToThirdCountriesInfo = "This service may forward the collected data to a different country.",
125
+ linkToDpaInfo = "Data Processing Agreement",
126
+ dataPurposesInfo = "This list represents the purposes of the data collection and processing.",
127
+ technologiesUsedInfo = "This list represents all technologies this service uses to collect data. Typical technologies are Cookies and Pixels that are placed in the browser.",
128
+ btnBannerReadMore = "Read more",
129
+ descriptionOfService = "Description of Service",
130
+ technology = "Technology being used to process the data",
131
+ notAvailable = "not available",
132
+ date = "Date",
133
+ minute = "minute",
134
+ minutes = "minutes",
135
+ hour = "hour",
136
+ hours = "hours",
137
+ day = "day",
138
+ days = "days",
139
+ month = "month",
140
+ months = "months",
141
+ year = "year",
142
+ years = "years",
143
+ consent = "Consent",
144
+ categories = "Categories",
145
+ language = "Language",
146
+ btnSave = "Save Services",
147
+ btnMoreInfo = "More Info",
148
+ btnBack = "Back",
149
+ copy = "copy",
150
+ copied = "copied",
151
+ view = "view",
152
+ more = "more",
153
+ less = "less",
154
+ consents = "Consents",
155
+ headerModal = "This tool helps you to select and deactivate various tags / trackers / analytic tools used on this website.",
156
+ basic = "Basic",
157
+ advanced = "Advanced",
158
+ processingCompany = "Processing Company",
159
+ cookiePolicyInfo = "Click here to read the cookie policy of the data processor",
160
+ imprintLinkText = "Imprint",
161
+ privacyPolicyLinkText = "Privacy Policy",
162
+ cookiePolicyLinkText = "Cookie Policy",
163
+ btnAcceptAll = "Accept All",
164
+ firstLayerTitle = "Privacy Settings",
165
+ historyDescription = "",
166
+ consentType = "Consent type",
167
+ decision = "Decision",
168
+ explicit = "Explicit",
169
+ implicit = "Implicit",
170
+ storageInformation = "Storage Information",
171
+ maximumAgeCookieStorage = "Maximum age of cookie storage",
172
+ second = "second",
173
+ seconds = "seconds",
174
+ nonCookieStorage = "Non-cookie storage",
175
+ detailedStorageInformation = "Detailed Storage Information",
176
+ loadingStorageInformation = "Loading storage information",
177
+ name = "Name",
178
+ identifier = "Identifier",
179
+ duration = "Duration",
180
+ type = "Type",
181
+ domain = "Domain",
182
+ informationLoadingNotPossible = "Sorry, we could not load the required information.",
183
+ yes = "yes",
184
+ session = "Session",
185
+ no = "no",
186
+ tryAgain = "Try again?",
187
+ anyDomain = "any domain (ex. first party cookie)",
188
+ multipleDomains = "multiple subdomains may exist",
189
+ storageInformationDescription = "Below you can see the longest potential duration for storage on a device, as set when using the cookie method of storage and if there are any other methods used.",
190
+ noImplicit = "no (default)",
191
+ yesImplicit = "yes (implicit)"
192
+ )
193
+ private val fakeFirstLayer = FirstLayer(
194
+ hideButtonDeny = false,
195
+ )
196
+ private val fakeSecondLayer = SecondLayer(
197
+ tabsServicesLabel = "Services",
198
+ hideLanguageSwitch = false,
199
+ tabsCategoriesLabel = "Categories",
200
+ hideButtonDeny = false,
201
+ acceptButtonText = "Accept All",
202
+ denyButtonText = "Deny All",
203
+ hideTogglesForServices = false,
204
+ hideDataProcessingServices = false,
205
+ )
206
+ private val fakeTCF2Settings = TCF2Settings(
207
+ togglesSpecialFeaturesToggleOff = "Off",
208
+ secondLayerTitle = "Privacy Settings Title",
209
+ tabsVendorsLabel = "Vendors",
210
+ labelsIabVendors = "Vendors who are part of the IAB TCF",
211
+ buttonsDenyAllLabel = "Deny all",
212
+ resurfacePeriodEnded = true,
213
+ vendorSpecialPurposes = "Special Purposes",
214
+ firstLayerAdditionalInfo = "",
215
+ resurfaceVendorAdded = true,
216
+ disabledSpecialFeatures = listOf(),
217
+ resurfacePurposeChanged = true,
218
+ firstLayerHideButtonDeny = false,
219
+ hideLegitimateInterestToggles = false,
220
+ secondLayerHideButtonDeny = false,
221
+ secondLayerHideToggles = false,
222
+ togglesConsentToggleLabel = "Consent",
223
+ labelsFeatures = "Features",
224
+ togglesSpecialFeaturesToggleOn = "On",
225
+ vendorSpecialFeatures = "Special Features",
226
+ appLayerNoteResurface =
227
+ "You can change your privacy settings or withdraw your consent at any time by opening the menu point Privacy Settings.",
228
+ cmpVersion = 3,
229
+ firstLayerDescription =
230
+ "We and our third-party vendors use technologies (e.g. cookies) to store and/or access information on user's devices in order to process personal data such as IP addresses or browsing data. You may consent to the processing of your personal data for the listed purposes below. Alternatively you can set your preferences before consenting or refuse to consent. Please note that some vendors may process your personal data based on their legitimate business interest and do not ask for your consent. To exercise your right to object to processing based on legitimate interest please view our vendorlist.",
231
+ firstLayerShowDescriptions = false,
232
+ labelsPurposes = "Purposes",
233
+ firstLayerNoteResurface =
234
+ "You can change your privacy settings or withdraw your consent at any time by clicking on our Privacy Button.",
235
+ firstLayerTitle = "Privacy Information",
236
+ vendorLegitimateInterestPurposes = "Purposes processed by Legitimate Interest",
237
+ selectedStacks = listOf(),
238
+ labelsNonIabPurposes = "Non-IAB Purposes",
239
+ togglesLegIntToggleLabel = "Legitimate Interest",
240
+ vendorPurpose = "Purposes processed by Consent",
241
+ labelsNonIabVendors = "Vendors who are not part of the IAB TCF",
242
+ purposeOneTreatment = false,
243
+ cmpId = 5,
244
+ vendorFeatures = "Features",
245
+ secondLayerDescription =
246
+ "You can access more detailed information below regarding all purposes and third-party vendors implemented on this website. You can adjust your privacy settings based on specific purposes and/or at a vendor level at any time.",
247
+ publisherCountryCode = "DE",
248
+ buttonsSaveLabel = "Save Settings",
249
+ selectedVendorIds = listOf(),
250
+ buttonsAcceptAllLabel = "Accept all",
251
+ hideNonIabOnFirstLayer = false,
252
+ linksManageSettingsLabel = "Manage Settings",
253
+ firstLayerHideToggles = false,
254
+ gdprApplies = true,
255
+ linksVendorListLinkLabel = "Vendorlist",
256
+ tabsPurposeLabel = "Purposes",
257
+ version = "2.2",
258
+ categoriesOfDataLabel = "categoriesOfDataLabel",
259
+ dataRetentionPeriodLabel = "dataRetentionPeriodLabel",
260
+ legitimateInterestLabel = "legitimateInterestLabel",
261
+ examplesLabel = "examplesLabel",
262
+ firstLayerMobileVariant = FirstLayerMobileVariant.FULL,
263
+ showDataSharedOutsideEUText = true,
264
+ dataSharedOutsideEUText = "dataSharedOutsideEUText",
265
+ vendorIdsOutsideEUList = listOf(1, 2, 3),
266
+ scope = TCF2Scope.SERVICE,
267
+ changedPurposes = TCF2ChangedPurposes(purposes = listOf(1, 2, 3), legIntPurposes = listOf(1, 2, 3)),
268
+ acmV2Enabled = true,
269
+ selectedATPIds = listOf(43, 46, 55)
270
+ )
271
+ private val fakeCCPASettings = CCPASettings(
272
+ secondLayerHideLanguageSwitch = false,
273
+ secondLayerTitle = "Privacy Settings Title",
274
+ iabAgreementExists = false,
275
+ optOutNoticeLabel = "Do not sell my personal information",
276
+ btnSave = "OK",
277
+ showOnPageLoad = false,
278
+ btnMoreInfo = "More Information",
279
+ firstLayerTitle = "Privacy Information",
280
+ appFirstLayerDescription =
281
+ "We and our partners are using technologies like cookies and process personal data in order to improve your experience. In case of sale of your personal information you may exercise your consumer right to opt-out by activating the toggle 'Do Not Sell My Personal Information' below. For detailed information about the categories of personal information we collect and the purposes for which information may be used and which Data Processing Services may have access to this information please refer to our privacy policy.",
282
+ isActive = false,
283
+ secondLayerDescription =
284
+ "Here you can find detailed information about the categories of personal information we collect and the purposes for which information may be used and which Data Processing Services may have access to this information.",
285
+ firstLayerMobileDescriptionIsActive = false,
286
+ reshowAfterDays = 365,
287
+ firstLayerMobileDescription =
288
+ "We and our partners are using technologies like cookies and process personal data in order to improve your experience. In case of sale of your personal information you may exercise your consumer right to opt-out by activating the toggle 'Do Not Sell My Personal Information' below.",
289
+ )
290
+ private val fakeCustomization = UsercentricsCustomization(
291
+ color = CustomizationColor(
292
+ primary = "0045A5"
293
+ ),
294
+ font = CustomizationFont(
295
+ size = 14,
296
+ family =
297
+ "BlinkMacSystemFont,-apple-system,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Fira Sans,Droid Sans,Helvetica Neue,Helvetica,Arial,sans-serif"
298
+ ),
299
+ logoUrl = "https://www.munich-startup.de/wp-content/uploads/2018/01/usercentrics-logo-4c@4x.png"
300
+ )
301
+
302
+ val fakeSettings = UsercentricsSettings(
303
+ labels = fakeLabels,
304
+ showInitialViewForVersionChange = listOf(),
305
+ displayOnlyForEU = false,
306
+ secondLayer = fakeSecondLayer,
307
+ cookiePolicyUrl = "",
308
+ tcf2 = fakeTCF2Settings,
309
+ ccpa = fakeCCPASettings,
310
+ privacyPolicyUrl = "https://usercentrics.com/privacy-policy/",
311
+ firstLayer = fakeFirstLayer,
312
+ imprintUrl = "https://usercentrics.com/legal-notice/",
313
+ firstLayerDescriptionHtml = "Privacy Settings test description.",
314
+ bannerMobileDescriptionIsActive = false,
315
+ firstLayerMobileDescriptionHtml = "",
316
+ version = "6.0.4",
317
+ language = "en",
318
+ tcf2Enabled = false,
319
+ settingsId = "lQ_Dio7QL",
320
+ languagesAvailable = listOf("en", "de"),
321
+ enablePoweredBy = true,
322
+ editableLanguages = listOf("en", "de"),
323
+ customization = fakeCustomization,
324
+ variants = VariantsSettings(enabled = true, experimentsJson = "{}", activateWith = "UC"),
325
+ dpsDisplayFormat = DpsDisplayFormat.ALL,
326
+ framework = USAFrameworks.CTDPA,
327
+ publishedApps = listOf(
328
+ PublishedApp(bundleId = "bundleId", platform = PublishedAppPlatform.ANDROID)
329
+ ),
330
+ )
331
+
332
+ // From the debugger
333
+ private val expectedFirstLayer = hashMapOf(
334
+ "hideButtonDeny" to false,
335
+ )
336
+ private val expectedSecondLayer = hashMapOf(
337
+ "tabsCategoriesLabel" to "Categories",
338
+ "tabsServicesLabel" to "Services",
339
+ "hideButtonDeny" to false,
340
+ "hideLanguageSwitch" to false,
341
+ "acceptButtonText" to "Accept All",
342
+ "denyButtonText" to "Deny All",
343
+ "hideTogglesForServices" to false,
344
+ "hideDataProcessingServices" to false,
345
+ )
346
+
347
+ private val expectedLabels = hashMapOf(
348
+ "btnAcceptAll" to "Accept All",
349
+ "btnDeny" to "Deny",
350
+ "btnSave" to "Save Services",
351
+ "firstLayerTitle" to "Privacy Settings",
352
+ "accepted" to "yes",
353
+ "denied" to "no",
354
+ "date" to "Date",
355
+ "decision" to "Decision",
356
+ "dataCollectedList" to "Data Collected",
357
+ "dataCollectedInfo" to "This list represents all (personal) data that is collected by or through the use of this service.",
358
+ "locationOfProcessing" to "Location of Processing",
359
+ "transferToThirdCountries" to "Transfer to Third Countries",
360
+ "dataPurposes" to "Data Purposes",
361
+ "dataPurposesInfo" to "This list represents the purposes of the data collection and processing.",
362
+ "dataRecipientsList" to "Data Recipients",
363
+ "descriptionOfService" to "Description of Service",
364
+ "history" to "History",
365
+ "historyDescription" to "",
366
+ "legalBasisList" to "Legal Basis",
367
+ "legalBasisInfo" to "In the following the required legal basis for the processing of data is listed.",
368
+ "processingCompanyTitle" to "Processing Company",
369
+ "retentionPeriod" to "Retention Period",
370
+ "technologiesUsed" to "Technologies Used",
371
+ "technologiesUsedInfo" to "This list represents all technologies this service uses to collect data. Typical technologies are Cookies and Pixels that are placed in the browser.",
372
+ "cookiePolicyInfo" to "Click here to read the cookie policy of the data processor",
373
+ "optOut" to "Click here to opt out from this processor across all domains",
374
+ "policyOf" to "Click here to read the privacy policy of the data processor",
375
+ "imprintLinkText" to "Imprint",
376
+ "privacyPolicyLinkText" to "Privacy Policy",
377
+ "categories" to "Categories",
378
+ "anyDomain" to "any domain (ex. first party cookie)",
379
+ "day" to "day",
380
+ "days" to "days",
381
+ "domain" to "Domain",
382
+ "duration" to "Duration",
383
+ "informationLoadingNotPossible" to "Sorry, we could not load the required information.",
384
+ "hour" to "hour",
385
+ "hours" to "hours",
386
+ "identifier" to "Identifier",
387
+ "maximumAgeCookieStorage" to "Maximum age of cookie storage",
388
+ "minute" to "minute",
389
+ "minutes" to "minutes",
390
+ "month" to "month",
391
+ "months" to "months",
392
+ "multipleDomains" to "multiple subdomains may exist",
393
+ "no" to "no",
394
+ "nonCookieStorage" to "Non-cookie storage",
395
+ "seconds" to "seconds",
396
+ "session" to "Session",
397
+ "loadingStorageInformation" to "Loading storage information",
398
+ "storageInformation" to "Storage Information",
399
+ "detailedStorageInformation" to "Detailed Storage Information",
400
+ "tryAgain" to "Try again?",
401
+ "type" to "Type",
402
+ "year" to "year",
403
+ "years" to "years",
404
+ "yes" to "yes",
405
+ "storageInformationDescription" to "Below you can see the longest potential duration for storage on a device, as set when using the cookie method of storage and if there are any other methods used.",
406
+ "btnBannerReadMore" to "Read more",
407
+ "linkToDpaInfo" to "Data Processing Agreement",
408
+ "second" to "second",
409
+ "consent" to "Consent",
410
+ "secondLayerTitle" to "Privacy Settings Title",
411
+ "secondLayerDescriptionHtml" to "Privacy Settings Description",
412
+ "btnMore" to "more",
413
+ "explicit" to "Explicit",
414
+ "transferToThirdCountriesInfo" to "This service may forward the collected data to a different country.",
415
+ "more" to "more",
416
+ "headerModal" to "This tool helps you to select and deactivate various tags / trackers / analytic tools used on this website.",
417
+ "furtherInformationOptOut" to "Further Information and Opt-Out",
418
+ "cookiePolicyLinkText" to "Cookie Policy",
419
+ "noImplicit" to "no (default)",
420
+ "yesImplicit" to "yes (implicit)",
421
+ )
422
+ private val expectedTCF2Settings = hashMapOf(
423
+ "firstLayerTitle" to "Privacy Information",
424
+ "secondLayerTitle" to "Privacy Settings Title",
425
+ "tabsPurposeLabel" to "Purposes",
426
+ "tabsVendorsLabel" to "Vendors",
427
+ "labelsFeatures" to "Features",
428
+ "labelsIabVendors" to "Vendors who are part of the IAB TCF",
429
+ "labelsNonIabPurposes" to "Non-IAB Purposes",
430
+ "labelsNonIabVendors" to "Vendors who are not part of the IAB TCF",
431
+ "labelsPurposes" to "Purposes",
432
+ "vendorFeatures" to "Features",
433
+ "vendorLegitimateInterestPurposes" to "Purposes processed by Legitimate Interest",
434
+ "vendorPurpose" to "Purposes processed by Consent",
435
+ "vendorSpecialFeatures" to "Special Features",
436
+ "vendorSpecialPurposes" to "Special Purposes",
437
+ "togglesConsentToggleLabel" to "Consent",
438
+ "togglesLegIntToggleLabel" to "Legitimate Interest",
439
+ "buttonsAcceptAllLabel" to "Accept all",
440
+ "buttonsDenyAllLabel" to "Deny all",
441
+ "buttonsSaveLabel" to "Save Settings",
442
+ "linksManageSettingsLabel" to "Manage Settings",
443
+ "linksVendorListLinkLabel" to "Vendorlist",
444
+ "cmpId" to 5,
445
+ "cmpVersion" to 3,
446
+ "firstLayerHideToggles" to false,
447
+ "secondLayerHideToggles" to false,
448
+ "hideLegitimateInterestToggles" to false,
449
+ "firstLayerHideButtonDeny" to false,
450
+ "secondLayerHideButtonDeny" to false,
451
+ "publisherCountryCode" to "DE",
452
+ "purposeOneTreatment" to false,
453
+ "selectedVendorIds" to listOf<Any>(),
454
+ "gdprApplies" to true,
455
+ "selectedStacks" to listOf<Any>(),
456
+ "disabledSpecialFeatures" to listOf<Any>(),
457
+ "firstLayerShowDescriptions" to false,
458
+ "hideNonIabOnFirstLayer" to false,
459
+ "resurfacePeriodEnded" to true,
460
+ "resurfacePurposeChanged" to true,
461
+ "resurfaceVendorAdded" to true,
462
+ "firstLayerDescription" to "We and our third-party vendors use technologies (e.g. cookies) to store and/or access information on user's devices in order to process personal data such as IP addresses or browsing data. You may consent to the processing of your personal data for the listed purposes below. Alternatively you can set your preferences before consenting or refuse to consent. Please note that some vendors may process your personal data based on their legitimate business interest and do not ask for your consent. To exercise your right to object to processing based on legitimate interest please view our vendorlist.",
463
+ "firstLayerAdditionalInfo" to "",
464
+ "secondLayerDescription" to "You can access more detailed information below regarding all purposes and third-party vendors implemented on this website. You can adjust your privacy settings based on specific purposes and/or at a vendor level at any time.",
465
+ "togglesSpecialFeaturesToggleOn" to "On",
466
+ "togglesSpecialFeaturesToggleOff" to "Off",
467
+ "appLayerNoteResurface" to "You can change your privacy settings or withdraw your consent at any time by opening the menu point Privacy Settings.",
468
+ "firstLayerNoteResurface" to "You can change your privacy settings or withdraw your consent at any time by clicking on our Privacy Button.",
469
+ "categoriesOfDataLabel" to "categoriesOfDataLabel",
470
+ "dataRetentionPeriodLabel" to "dataRetentionPeriodLabel",
471
+ "legitimateInterestLabel" to "legitimateInterestLabel",
472
+ "examplesLabel" to "examplesLabel",
473
+ "version" to "2.2",
474
+ "firstLayerMobileVariant" to 1,
475
+ "showDataSharedOutsideEUText" to true,
476
+ "dataSharedOutsideEUText" to "dataSharedOutsideEUText",
477
+ "vendorIdsOutsideEUList" to listOf(1, 2, 3),
478
+ "scope" to 1,
479
+ "changedPurposes" to mapOf(
480
+ "purposes" to listOf(1, 2, 3),
481
+ "legIntPurposes" to listOf(1, 2, 3),
482
+ ),
483
+ "acmV2Enabled" to true,
484
+ "selectedATPIds" to listOf(43, 46, 55)
485
+ )
486
+ private val expectedCCPASettings = hashMapOf(
487
+ "optOutNoticeLabel" to "Do not sell my personal information",
488
+ "btnSave" to "OK",
489
+ "firstLayerTitle" to "Privacy Information",
490
+ "isActive" to false,
491
+ "showOnPageLoad" to false,
492
+ "reshowAfterDays" to 365,
493
+ "iabAgreementExists" to false,
494
+ "appFirstLayerDescription" to "We and our partners are using technologies like cookies and process personal data in order to improve your experience. In case of sale of your personal information you may exercise your consumer right to opt-out by activating the toggle 'Do Not Sell My Personal Information' below. For detailed information about the categories of personal information we collect and the purposes for which information may be used and which Data Processing Services may have access to this information please refer to our privacy policy.",
495
+ "firstLayerMobileDescriptionIsActive" to false,
496
+ "firstLayerMobileDescription" to "We and our partners are using technologies like cookies and process personal data in order to improve your experience. In case of sale of your personal information you may exercise your consumer right to opt-out by activating the toggle 'Do Not Sell My Personal Information' below.",
497
+ "secondLayerTitle" to "Privacy Settings Title",
498
+ "secondLayerDescription" to "Here you can find detailed information about the categories of personal information we collect and the purposes for which information may be used and which Data Processing Services may have access to this information.",
499
+ "secondLayerHideLanguageSwitch" to false,
500
+ "btnMoreInfo" to "More Information",
501
+ )
502
+ private val expectedCustomization = hashMapOf(
503
+ "color" to hashMapOf(
504
+ "primary" to "0045A5",
505
+ ),
506
+ "font" to hashMapOf(
507
+ "family" to "BlinkMacSystemFont,-apple-system,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Fira Sans,Droid Sans,Helvetica Neue,Helvetica,Arial,sans-serif",
508
+ "size" to 14
509
+ ),
510
+ "logoUrl" to "https://www.munich-startup.de/wp-content/uploads/2018/01/usercentrics-logo-4c@4x.png",
511
+ )
512
+
513
+ val expectedSettings = hashMapOf(
514
+ "labels" to expectedLabels,
515
+ "showInitialViewForVersionChange" to listOf<Any>(),
516
+ "displayOnlyForEU" to false,
517
+ "secondLayer" to expectedSecondLayer,
518
+ "cookiePolicyUrl" to "",
519
+ "tcf2" to expectedTCF2Settings,
520
+ "ccpa" to expectedCCPASettings,
521
+ "privacyPolicyUrl" to "https://usercentrics.com/privacy-policy/",
522
+ "firstLayer" to expectedFirstLayer,
523
+ "imprintUrl" to "https://usercentrics.com/legal-notice/",
524
+ "firstLayerDescriptionHtml" to "Privacy Settings test description.",
525
+ "bannerMobileDescriptionIsActive" to false,
526
+ "firstLayerMobileDescriptionHtml" to "",
527
+ "version" to "6.0.4",
528
+ "language" to "en",
529
+ "tcf2Enabled" to false,
530
+ "settingsId" to "lQ_Dio7QL",
531
+ "languagesAvailable" to listOf("en", "de"),
532
+ "enablePoweredBy" to true,
533
+ "editableLanguages" to listOf("en", "de"),
534
+ "customization" to expectedCustomization,
535
+ "variants" to mapOf(
536
+ "enabled" to true,
537
+ "experimentsJson" to "{}",
538
+ "activateWith" to "UC"
539
+ ),
540
+ "dpsDisplayFormat" to 0,
541
+ "framework" to 3,
542
+ "publishedApps" to listOf(
543
+ mapOf(
544
+ "bundleId" to "bundleId",
545
+ "platform" to 0
55
546
  )
547
+ ),
548
+ )
549
+
550
+ val expectedCategories = listOf(
551
+ hashMapOf(
552
+ "categorySlug" to "essential",
553
+ "label" to "Essential",
554
+ "description" to "These technologies are required to activate the core functionality of the website.",
555
+ "isEssential" to true,
56
556
  )
57
- private val fakeLabels = UsercentricsLabels(
58
- dataPurposes = "Data Purposes",
59
- accepted = "yes",
60
- denied = "no",
61
- history = "History",
62
- settings = "Settings",
63
- subConsents = "Subservices",
64
- btnAccept = "Accept",
65
- btnDeny = "Deny",
66
- secondLayerTitle = "Privacy Settings Title",
67
- secondLayerDescriptionHtml = "Privacy Settings Description",
68
- btnMore = "more",
69
- poweredBy = "Powered by <a href=\"https://usercentrics.com/?utm_source=cmp&utm_medium=powered_by\" rel=\"nofollow\" target=\"_blank\">Usercentrics Consent Management</a>",
70
- technologiesUsed = "Technologies Used",
71
- dataCollectedList = "Data Collected",
72
- processingCompanyTitle = "Processing Company",
73
- legalBasisList = "Legal Basis",
74
- retentionPeriod = "Retention Period",
75
- locationOfProcessing = "Location of Processing",
76
- transferToThirdCountries = "Transfer to Third Countries",
77
- furtherInformationOptOut = "Further Information and Opt-Out",
78
- dataProtectionOfficer = "Data Protection Officer of Processing Company",
79
- nameOfProcessingCompany = "Processing Company",
80
- addressOfProcessingCompany = "Address of processing company",
81
- optOut = "Click here to opt out from this processor across all domains",
82
- policyOf = "Click here to read the privacy policy of the data processor",
83
- dataCollectedInfo = "This list represents all (personal) data that is collected by or through the use of this service.",
84
- legalBasisInfo = "In the following the required legal basis for the processing of data is listed.",
85
- dataRecipientsList = "Data Recipients",
86
- transferToThirdCountriesInfo = "This service may forward the collected data to a different country. Please note that this service might transfer the data outside of the EU/EEA and to a country without the required data protection standards. If the data is transferred to the US, there is a risk that your data can be processed by US authorities, for control and surveillance measures, possibly without legal remedies. Below you can find a list of countries to which the data is being transferred. This can be for different reasons like storing or processing.",
87
- linkToDpaInfo = "Data Processing Agreement",
88
- dataPurposesInfo = "This list represents the purposes of the data collection and processing.",
89
- technologiesUsedInfo = "This list represents all technologies this service uses to collect data. Typical technologies are Cookies and Pixels that are placed in the browser.",
90
- btnBannerReadMore = "Read more",
91
- descriptionOfService = "Description of Service",
92
- technology = "Technology being used to process the data",
93
- notAvailable = "not available",
94
- date = "Date",
95
- minute = "minute",
96
- minutes = "minutes",
97
- hour = "hour",
98
- hours = "hours",
99
- day = "day",
100
- days = "days",
101
- month = "month",
102
- months = "months",
103
- year = "year",
104
- years = "years",
105
- consent = "Consent",
106
- categories = "Categories",
107
- language = "Language",
108
- btnSave = "Save Services",
109
- btnMoreInfo = "More Info",
110
- btnBack = "Back",
111
- copy = "copy",
112
- copied = "copied",
113
- view = "view",
114
- more = "more",
115
- less = "less",
116
- consents = "Consents",
117
- headerModal = "This tool helps you to select and deactivate various tags / trackers / analytic tools used on this website.",
118
- basic = "Basic",
119
- advanced = "Advanced",
120
- processingCompany = "Processing Company",
121
- cookiePolicyInfo = "Click here to read the cookie policy of the data processor",
122
- imprintLinkText = "Imprint",
123
- privacyPolicyLinkText = "Privacy Policy",
124
- cookiePolicyLinkText = "Cookie Policy",
125
- btnAcceptAll = "Accept All",
126
- firstLayerTitle = "Privacy Settings",
127
- historyDescription = "",
128
- consentType = "Consent type",
129
- decision = "Decision",
130
- explicit = "Explicit",
131
- implicit = "Implicit",
132
- storageInformation = "Storage Information",
133
- maximumAgeCookieStorage = "Maximum age of cookie storage",
134
- second = "second",
135
- seconds = "seconds",
136
- nonCookieStorage = "Non-cookie storage",
137
- detailedStorageInformation = "Detailed Storage Information",
138
- loadingStorageInformation = "Loading storage information",
139
- name = "Name",
140
- identifier = "Identifier",
141
- duration = "Duration",
142
- type = "Type",
143
- domain = "Domain",
144
- informationLoadingNotPossible = "Sorry, we could not load the required information.",
145
- yes = "yes",
146
- session = "Session",
147
- no = "no",
148
- tryAgain = "Try again?",
149
- anyDomain = "any domain (ex. first party cookie)",
150
- multipleDomains = "multiple subdomains may exist",
151
- storageInformationDescription = "Below you can see the longest potential duration for storage on a device, as set when using the cookie method of storage and if there are any other methods used.",
152
- noImplicit = "no (default)",
153
- yesImplicit = "yes (implicit)"
154
- )
155
- private val fakeFirstLayer = FirstLayer(
156
- hideButtonDeny = false,
157
- )
158
- private val fakeSecondLayer = SecondLayer(
159
- tabsServicesLabel = "Services",
160
- hideLanguageSwitch = false,
161
- tabsCategoriesLabel = "Categories",
162
- hideButtonDeny = false,
163
- hideTogglesForServices = false,
164
- acceptButtonText = "Accept All",
165
- denyButtonText = "Deny All",
166
- hideDataProcessingServices = false,
167
- )
168
- private val fakeTCF2Settings = TCF2Settings(
169
- togglesSpecialFeaturesToggleOff = "Off",
170
- secondLayerTitle = "Privacy Settings Title",
171
- tabsVendorsLabel = "Vendors",
172
- labelsIabVendors = "Vendors who are part of the IAB TCF",
173
- buttonsDenyAllLabel = "Deny all",
174
- resurfacePeriodEnded = true,
175
- vendorSpecialPurposes = "Special Purposes",
176
- firstLayerAdditionalInfo = "",
177
- resurfaceVendorAdded = true,
178
- disabledSpecialFeatures = listOf(),
179
- resurfacePurposeChanged = true,
180
- firstLayerHideButtonDeny = false,
181
- hideLegitimateInterestToggles = false,
182
- secondLayerHideButtonDeny = false,
183
- secondLayerHideToggles = false,
184
- togglesConsentToggleLabel = "Consent",
185
- labelsFeatures = "Features",
186
- togglesSpecialFeaturesToggleOn = "On",
187
- vendorSpecialFeatures = "Special Features",
188
- appLayerNoteResurface =
189
- "You can change your privacy settings or withdraw your consent at any time by opening the menu point Privacy Settings.",
190
- cmpVersion = 3,
191
- firstLayerDescription =
192
- "We and our third-party vendors use technologies (e.g. cookies) to store and/or access information on user's devices in order to process personal data such as IP addresses or browsing data. You may consent to the processing of your personal data for the listed purposes below. Alternatively you can set your preferences before consenting or refuse to consent. Please note that some vendors may process your personal data based on their legitimate business interest and do not ask for your consent. To exercise your right to object to processing based on legitimate interest please view our vendorlist.",
193
- firstLayerShowDescriptions = false,
194
- labelsPurposes = "Purposes",
195
- firstLayerNoteResurface =
196
- "You can change your privacy settings or withdraw your consent at any time by clicking on our Privacy Button.",
197
- firstLayerTitle = "Privacy Information",
198
- vendorLegitimateInterestPurposes = "Purposes processed by Legitimate Interest",
199
- selectedStacks = listOf(),
200
- labelsNonIabPurposes = "Non-IAB Purposes",
201
- togglesLegIntToggleLabel = "Legitimate Interest",
202
- vendorPurpose = "Purposes processed by Consent",
203
- labelsNonIabVendors = "Vendors who are not part of the IAB TCF",
204
- purposeOneTreatment = false,
205
- cmpId = 5,
206
- vendorFeatures = "Features",
207
- secondLayerDescription =
208
- "You can access more detailed information below regarding all purposes and third-party vendors implemented on this website. You can adjust your privacy settings based on specific purposes and/or at a vendor level at any time.",
209
- publisherCountryCode = "DE",
210
- buttonsSaveLabel = "Save Settings",
211
- selectedVendorIds = listOf(),
212
- buttonsAcceptAllLabel = "Accept all",
213
- hideNonIabOnFirstLayer = false,
214
- linksManageSettingsLabel = "Manage Settings",
215
- firstLayerHideToggles = false,
216
- gdprApplies = true,
217
- linksVendorListLinkLabel = "Vendorlist",
218
- tabsPurposeLabel = "Purposes",
219
- version = "2.2",
220
- categoriesOfDataLabel = "categoriesOfDataLabel",
221
- dataRetentionPeriodLabel = "dataRetentionPeriodLabel",
222
- legitimateInterestLabel = "legitimateInterestLabel",
223
- examplesLabel = "examplesLabel",
224
- )
225
- private val fakeCCPASettings = CCPASettings(
226
- secondLayerHideLanguageSwitch = false,
227
- secondLayerTitle = "Privacy Settings Title",
228
- iabAgreementExists = false,
229
- optOutNoticeLabel = "Do not sell my personal information",
230
- btnSave = "OK",
231
- showOnPageLoad = false,
232
- btnMoreInfo = "More Information",
233
- firstLayerTitle = "Privacy Information",
234
- appFirstLayerDescription =
235
- "We and our partners are using technologies like cookies and process personal data in order to improve your experience. In case of sale of your personal information you may exercise your consumer right to opt-out by activating the toggle 'Do Not Sell My Personal Information' below. For detailed information about the categories of personal information we collect and the purposes for which information may be used and which Data Processing Services may have access to this information please refer to our privacy policy.",
236
- isActive = false,
237
- secondLayerDescription =
238
- "Here you can find detailed information about the categories of personal information we collect and the purposes for which information may be used and which Data Processing Services may have access to this information.",
239
- firstLayerMobileDescriptionIsActive = false,
240
- reshowAfterDays = 365,
241
- firstLayerMobileDescription =
242
- "We and our partners are using technologies like cookies and process personal data in order to improve your experience. In case of sale of your personal information you may exercise your consumer right to opt-out by activating the toggle 'Do Not Sell My Personal Information' below.",
243
- )
244
- private val fakeCustomization = UsercentricsCustomization(
245
- color = CustomizationColor(
246
- primary = "0045A5"
247
- ),
248
- font = CustomizationFont(
249
- size = 14,
250
- family =
251
- "BlinkMacSystemFont,-apple-system,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Fira Sans,Droid Sans,Helvetica Neue,Helvetica,Arial,sans-serif"
557
+ )
558
+ val expectedUserLocation = hashMapOf(
559
+ "countryCode" to "PT",
560
+ "regionCode" to "",
561
+ "isInEU" to true,
562
+ "isInUS" to false,
563
+ "isInCalifornia" to false,
564
+ )
565
+ val expectedServices = listOf(
566
+ hashMapOf(
567
+ "templateId" to "ABC",
568
+ "version" to "1.2.3",
569
+ "type" to "predefined",
570
+ "isEssential" to false,
571
+ "dataProcessor" to "Google Ads",
572
+ "dataPurposes" to listOf("Advertising Conversion Tracking"),
573
+ "processingCompany" to "Google Ireland Limited, Google Building Gordon House",
574
+ "nameOfProcessingCompany" to "Google Ireland Limited",
575
+ "addressOfProcessingCompany" to "Google Building Gordon House",
576
+ "descriptionOfService" to "This is a conversion tracking service. ",
577
+ "languagesAvailable" to listOf("en"),
578
+ "dataCollectedList" to listOf("IP adress"),
579
+ "dataPurposesList" to listOf("Analytics"),
580
+ "dataRecipientsList" to listOf("Google Ireland Limited"),
581
+ "legalBasisList" to listOf("Art. 6 para. 1 s. 1 lit. a GDPR"),
582
+ "retentionPeriodList" to listOf<String>(),
583
+ "subConsents" to listOf<String>(),
584
+ "language" to "en",
585
+ "linkToDpa" to "",
586
+ "legalGround" to "Art. 6 para. 1 s. 1 lit. c GDPR",
587
+ "optOutUrl" to "",
588
+ "policyOfProcessorUrl" to "https://usercentrics.com/de/datenschutzerklarung/",
589
+ "categorySlug" to "essential",
590
+ "retentionPeriodDescription" to "The consent data (given consent and revocation of consent) are stored for three years. The data will then be deleted immediately or given to the person responsible on request in the form of a data export.",
591
+ "dataProtectionOfficer" to "datenschutz@usercentrics.com",
592
+ "privacyPolicyURL" to "https://usercentrics.com/privacy-policy/",
593
+ "cookiePolicyURL" to "",
594
+ "locationOfProcessing" to "European Union",
595
+ "dataCollectedDescription" to "",
596
+ "thirdCountryTransfer" to "Worldwide",
597
+ "description" to "",
598
+ "isDeactivated" to false,
599
+ "disableLegalBasis" to false,
600
+ "technologyUsed" to listOf("Cookies", "Pixel Tags"),
601
+ "deviceStorage" to listOf(
602
+ mapOf(
603
+ "identifier" to "identifier",
604
+ "type" to 2,
605
+ "name" to "name",
606
+ "maxAgeSeconds" to 123123L,
607
+ "cookieRefresh" to true,
608
+ "purposes" to listOf(1, 2, 3),
609
+ "domain" to "domain",
610
+ "description" to "description",
611
+ )
252
612
  ),
253
- logoUrl = "https://www.munich-startup.de/wp-content/uploads/2018/01/usercentrics-logo-4c@4x.png"
254
- )
255
- val fakeSettings = UsercentricsSettings(
256
- labels = fakeLabels,
257
- showInitialViewForVersionChange = listOf(),
258
- displayOnlyForEU = false,
259
- secondLayer = fakeSecondLayer,
260
- cookiePolicyUrl = "",
261
- tcf2 = fakeTCF2Settings,
262
- ccpa = fakeCCPASettings,
263
- privacyPolicyUrl = "https://usercentrics.com/privacy-policy/",
264
- firstLayer = fakeFirstLayer,
265
- imprintUrl = "https://usercentrics.com/legal-notice/",
266
- firstLayerDescriptionHtml = "Privacy Settings test description.",
267
- bannerMobileDescriptionIsActive = false,
268
- firstLayerMobileDescriptionHtml = "",
269
- version = "6.0.4",
270
- language = "en",
271
- tcf2Enabled = false,
272
- settingsId = "lQ_Dio7QL",
273
- languagesAvailable = listOf("en", "de"),
274
- enablePoweredBy = true,
275
- editableLanguages = listOf("en", "de"),
276
- customization = fakeCustomization,
613
+ "isHidden" to false,
277
614
  )
615
+ )
278
616
 
279
- // From the debugger
280
- private val expectedFirstLayer = hashMapOf(
281
- "hideButtonDeny" to false,
282
- )
283
- private val expectedSecondLayer = hashMapOf(
284
- "tabsCategoriesLabel" to "Categories",
285
- "tabsServicesLabel" to "Services",
286
- "hideButtonDeny" to false,
287
- "hideLanguageSwitch" to false,
288
- "acceptButtonText" to "Accept All",
289
- "denyButtonText" to "Deny All"
290
- )
291
- private val expectedLabels = hashMapOf(
292
- "btnAcceptAll" to "Accept All",
293
- "btnDeny" to "Deny",
294
- "btnSave" to "Save Services",
295
- "firstLayerTitle" to "Privacy Settings",
296
- "accepted" to "yes",
297
- "denied" to "no",
298
- "date" to "Date",
299
- "decision" to "Decision",
300
- "dataCollectedList" to "Data Collected",
301
- "dataCollectedInfo" to "This list represents all (personal) data that is collected by or through the use of this service.",
302
- "locationOfProcessing" to "Location of Processing",
303
- "transferToThirdCountries" to "Transfer to Third Countries",
304
- "dataPurposes" to "Data Purposes",
305
- "dataPurposesInfo" to "This list represents the purposes of the data collection and processing.",
306
- "dataRecipientsList" to "Data Recipients",
307
- "descriptionOfService" to "Description of Service",
308
- "history" to "History",
309
- "historyDescription" to "",
310
- "legalBasisList" to "Legal Basis",
311
- "legalBasisInfo" to "In the following the required legal basis for the processing of data is listed.",
312
- "processingCompanyTitle" to "Processing Company",
313
- "retentionPeriod" to "Retention Period",
314
- "technologiesUsed" to "Technologies Used",
315
- "technologiesUsedInfo" to "This list represents all technologies this service uses to collect data. Typical technologies are Cookies and Pixels that are placed in the browser.",
316
- "cookiePolicyInfo" to "Click here to read the cookie policy of the data processor",
317
- "optOut" to "Click here to opt out from this processor across all domains",
318
- "policyOf" to "Click here to read the privacy policy of the data processor",
319
- "imprintLinkText" to "Imprint",
320
- "privacyPolicyLinkText" to "Privacy Policy",
321
- "categories" to "Categories",
322
- "anyDomain" to "any domain (ex. first party cookie)",
323
- "day" to "day",
324
- "days" to "days",
325
- "domain" to "Domain",
326
- "duration" to "Duration",
327
- "informationLoadingNotPossible" to "Sorry, we could not load the required information.",
328
- "hour" to "hour",
329
- "hours" to "hours",
330
- "identifier" to "Identifier",
331
- "maximumAgeCookieStorage" to "Maximum age of cookie storage",
332
- "minute" to "minute",
333
- "minutes" to "minutes",
334
- "month" to "month",
335
- "months" to "months",
336
- "multipleDomains" to "multiple subdomains may exist",
337
- "no" to "no",
338
- "nonCookieStorage" to "Non-cookie storage",
339
- "seconds" to "seconds",
340
- "session" to "Session",
341
- "loadingStorageInformation" to "Loading storage information",
342
- "storageInformation" to "Storage Information",
343
- "detailedStorageInformation" to "Detailed Storage Information",
344
- "tryAgain" to "Try again?",
345
- "type" to "Type",
346
- "year" to "year",
347
- "years" to "years",
348
- "yes" to "yes",
349
- "storageInformationDescription" to "Below you can see the longest potential duration for storage on a device, as set when using the cookie method of storage and if there are any other methods used.",
350
- "btnBannerReadMore" to "Read more",
351
- "linkToDpaInfo" to "Data Processing Agreement",
352
- "second" to "second",
353
- "consent" to "Consent",
354
- "secondLayerTitle" to "Privacy Settings Title",
355
- "secondLayerDescriptionHtml" to "Privacy Settings Description",
356
- "btnMore" to "more",
357
- "explicit" to "Explicit"
358
- )
359
- private val expectedTCF2Settings = hashMapOf(
360
- "firstLayerTitle" to "Privacy Information",
361
- "secondLayerTitle" to "Privacy Settings Title",
362
- "tabsPurposeLabel" to "Purposes",
363
- "tabsVendorsLabel" to "Vendors",
364
- "labelsFeatures" to "Features",
365
- "labelsIabVendors" to "Vendors who are part of the IAB TCF",
366
- "labelsNonIabPurposes" to "Non-IAB Purposes",
367
- "labelsNonIabVendors" to "Vendors who are not part of the IAB TCF",
368
- "labelsPurposes" to "Purposes",
369
- "vendorFeatures" to "Features",
370
- "vendorLegitimateInterestPurposes" to "Purposes processed by Legitimate Interest",
371
- "vendorPurpose" to "Purposes processed by Consent",
372
- "vendorSpecialFeatures" to "Special Features",
373
- "vendorSpecialPurposes" to "Special Purposes",
374
- "togglesConsentToggleLabel" to "Consent",
375
- "togglesLegIntToggleLabel" to "Legitimate Interest",
376
- "buttonsAcceptAllLabel" to "Accept all",
377
- "buttonsDenyAllLabel" to "Deny all",
378
- "buttonsSaveLabel" to "Save Settings",
379
- "linksManageSettingsLabel" to "Manage Settings",
380
- "linksVendorListLinkLabel" to "Vendorlist",
381
- "cmpId" to 5,
382
- "cmpVersion" to 3,
383
- "firstLayerHideToggles" to false,
384
- "secondLayerHideToggles" to false,
385
- "hideLegitimateInterestToggles" to false,
386
- "firstLayerHideButtonDeny" to false,
387
- "secondLayerHideButtonDeny" to false,
388
- "publisherCountryCode" to "DE",
389
- "purposeOneTreatment" to false,
390
- "selectedVendorIds" to listOf<Any>(),
391
- "gdprApplies" to true,
392
- "selectedStacks" to listOf<Any>(),
393
- "disabledSpecialFeatures" to listOf<Any>(),
394
- "firstLayerShowDescriptions" to false,
395
- "hideNonIabOnFirstLayer" to false,
396
- "resurfacePeriodEnded" to true,
397
- "resurfacePurposeChanged" to true,
398
- "resurfaceVendorAdded" to true,
399
- "firstLayerDescription" to "We and our third-party vendors use technologies (e.g. cookies) to store and/or access information on user's devices in order to process personal data such as IP addresses or browsing data. You may consent to the processing of your personal data for the listed purposes below. Alternatively you can set your preferences before consenting or refuse to consent. Please note that some vendors may process your personal data based on their legitimate business interest and do not ask for your consent. To exercise your right to object to processing based on legitimate interest please view our vendorlist.",
400
- "firstLayerAdditionalInfo" to "",
401
- "secondLayerDescription" to "You can access more detailed information below regarding all purposes and third-party vendors implemented on this website. You can adjust your privacy settings based on specific purposes and/or at a vendor level at any time.",
402
- "togglesSpecialFeaturesToggleOn" to "On",
403
- "togglesSpecialFeaturesToggleOff" to "Off",
404
- "appLayerNoteResurface" to "You can change your privacy settings or withdraw your consent at any time by opening the menu point Privacy Settings.",
405
- "firstLayerNoteResurface" to "You can change your privacy settings or withdraw your consent at any time by clicking on our Privacy Button.",
406
- "categoriesOfDataLabel" to "categoriesOfDataLabel",
407
- "dataRetentionPeriodLabel" to "dataRetentionPeriodLabel",
408
- "legitimateInterestLabel" to "legitimateInterestLabel",
409
- "examplesLabel" to "examplesLabel",
410
- "version" to "2.2",
411
- )
412
- private val expectedCCPASettings = hashMapOf(
413
- "optOutNoticeLabel" to "Do not sell my personal information",
414
- "btnSave" to "OK",
415
- "firstLayerTitle" to "Privacy Information",
416
- "isActive" to false,
417
- "showOnPageLoad" to false,
418
- "reshowAfterDays" to 365,
419
- "iabAgreementExists" to false,
420
- "appFirstLayerDescription" to "We and our partners are using technologies like cookies and process personal data in order to improve your experience. In case of sale of your personal information you may exercise your consumer right to opt-out by activating the toggle 'Do Not Sell My Personal Information' below. For detailed information about the categories of personal information we collect and the purposes for which information may be used and which Data Processing Services may have access to this information please refer to our privacy policy.",
421
- "firstLayerMobileDescriptionIsActive" to false,
422
- "firstLayerMobileDescription" to "We and our partners are using technologies like cookies and process personal data in order to improve your experience. In case of sale of your personal information you may exercise your consumer right to opt-out by activating the toggle 'Do Not Sell My Personal Information' below.",
423
- "secondLayerTitle" to "Privacy Settings Title",
424
- "secondLayerDescription" to "Here you can find detailed information about the categories of personal information we collect and the purposes for which information may be used and which Data Processing Services may have access to this information.",
425
- "secondLayerHideLanguageSwitch" to false,
426
- "btnMoreInfo" to "More Information",
427
- )
428
- private val expectedCustomization = hashMapOf(
429
- "color" to hashMapOf(
430
- "primary" to "0045A5",
617
+ val fakeAdditionalConsentModeData = AdditionalConsentModeData(
618
+ acString = "2~43.46.55~dv.",
619
+ adTechProviders = listOf(
620
+ AdTechProvider(
621
+ id = 43,
622
+ name = "AdPredictive",
623
+ privacyPolicyUrl = "https://adpredictive.com/privacy",
624
+ consent = false
431
625
  ),
432
- "font" to hashMapOf(
433
- "family" to "BlinkMacSystemFont,-apple-system,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Fira Sans,Droid Sans,Helvetica Neue,Helvetica,Arial,sans-serif",
434
- "size" to 14
626
+ AdTechProvider(
627
+ id = 46,
628
+ name = "Adriver",
629
+ privacyPolicyUrl = "https://www.adriver.ru/about/privacy-en/",
630
+ consent = false
631
+ ),
632
+ AdTechProvider(
633
+ id = 55,
634
+ name = "Adtelligence",
635
+ privacyPolicyUrl = "https://adtelligence.com/en/data-privacy/",
636
+ consent = false
435
637
  ),
436
- "logoUrl" to "https://www.munich-startup.de/wp-content/uploads/2018/01/usercentrics-logo-4c@4x.png",
437
638
  )
639
+ )
438
640
 
439
- val expectedSettings = hashMapOf(
440
- "labels" to expectedLabels,
441
- "showInitialViewForVersionChange" to listOf<Any>(),
442
- "displayOnlyForEU" to false,
443
- "secondLayer" to expectedSecondLayer,
444
- "cookiePolicyUrl" to "",
445
- "tcf2" to expectedTCF2Settings,
446
- "ccpa" to expectedCCPASettings,
447
- "privacyPolicyUrl" to "https://usercentrics.com/privacy-policy/",
448
- "firstLayer" to expectedFirstLayer,
449
- "imprintUrl" to "https://usercentrics.com/legal-notice/",
450
- "firstLayerDescriptionHtml" to "Privacy Settings test description.",
451
- "bannerMobileDescriptionIsActive" to false,
452
- "firstLayerMobileDescriptionHtml" to "",
453
- "version" to "6.0.4",
454
- "language" to "en",
455
- "tcf2Enabled" to false,
456
- "settingsId" to "lQ_Dio7QL",
457
- "languagesAvailable" to listOf("en", "de"),
458
- "enablePoweredBy" to true,
459
- "editableLanguages" to listOf("en", "de"),
460
- "customization" to expectedCustomization,
461
- )
462
- val expectedCategories = listOf(
463
- hashMapOf(
464
- "categorySlug" to "essential",
465
- "label" to "Essential",
466
- "description" to "These technologies are required to activate the core functionality of the website.",
467
- "isEssential" to true,
468
- )
469
- )
470
- val expectedUserLocation = hashMapOf(
471
- "countryCode" to "PT",
472
- "regionCode" to "",
473
- "isInEU" to true,
474
- "isInUS" to false,
475
- "isInCalifornia" to false,
476
- )
477
- val expectedServices = listOf(
478
- hashMapOf(
479
- "templateId" to "ABC",
480
- "version" to "1.2.3",
481
- "type" to "predefined",
482
- "isEssential" to false,
483
- "dataProcessor" to "Google Ads",
484
- "dataPurposes" to listOf("Advertising Conversion Tracking"),
485
- "processingCompany" to "Google Ireland Limited, Google Building Gordon House",
486
- "nameOfProcessingCompany" to "Google Ireland Limited",
487
- "addressOfProcessingCompany" to "Google Building Gordon House",
488
- "descriptionOfService" to "This is a conversion tracking service. ",
489
- "languagesAvailable" to listOf("en"),
490
- "dataCollectedList" to listOf("IP adress"),
491
- "dataPurposesList" to listOf("Analytics"),
492
- "dataRecipientsList" to listOf("Google Ireland Limited"),
493
- "legalBasisList" to listOf("Art. 6 para. 1 s. 1 lit. a GDPR"),
494
- "retentionPeriodList" to listOf<String>(),
495
- "subConsents" to listOf<String>(),
496
- "language" to "en",
497
- "linkToDpa" to "",
498
- "legalGround" to "Art. 6 para. 1 s. 1 lit. c GDPR",
499
- "optOutUrl" to "",
500
- "policyOfProcessorUrl" to "https://usercentrics.com/de/datenschutzerklarung/",
501
- "categorySlug" to "essential",
502
- "retentionPeriodDescription" to "The consent data (given consent and revocation of consent) are stored for three years. The data will then be deleted immediately or given to the person responsible on request in the form of a data export.",
503
- "dataProtectionOfficer" to "datenschutz@usercentrics.com",
504
- "privacyPolicyURL" to "https://usercentrics.com/privacy-policy/",
505
- "cookiePolicyURL" to "",
506
- "locationOfProcessing" to "European Union",
507
- "dataCollectedDescription" to "",
508
- "thirdCountryTransfer" to "Worldwide",
509
- "description" to "",
510
- "isDeactivated" to false,
511
- "disableLegalBasis" to false,
512
- "technologyUsed" to listOf("Cookies", "Pixel Tags")
513
- )
641
+ val expectedAdditionalConsentModeData = hashMapOf(
642
+ "acString" to "2~43.46.55~dv.",
643
+ "adTechProviders" to listOf(
644
+ mapOf(
645
+ "id" to 43,
646
+ "name" to "AdPredictive",
647
+ "privacyPolicyUrl" to "https://adpredictive.com/privacy",
648
+ "consent" to false
649
+ ),
650
+ mapOf(
651
+ "id" to 46,
652
+ "name" to "Adriver",
653
+ "privacyPolicyUrl" to "https://www.adriver.ru/about/privacy-en/",
654
+ "consent" to false
655
+ ),
656
+ mapOf(
657
+ "id" to 55,
658
+ "name" to "Adtelligence",
659
+ "privacyPolicyUrl" to "https://adtelligence.com/en/data-privacy/",
660
+ "consent" to false
661
+ ),
514
662
  )
515
- }
663
+ )
516
664
  }