@redacto.io/consent-sdk-react 9.3.0 → 9.4.0-beta.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 (48) hide show
  1. package/.turbo/turbo-build.log +10 -10
  2. package/CHANGELOG.md +6 -0
  3. package/README.md +93 -12
  4. package/dist/index.d.mts +39 -1
  5. package/dist/index.d.ts +39 -1
  6. package/dist/index.js +4454 -334
  7. package/dist/index.mjs +4454 -335
  8. package/dist/privacy-center.d.mts +4 -1
  9. package/dist/privacy-center.d.ts +4 -1
  10. package/dist/privacy-center.js +3905 -3660
  11. package/dist/privacy-center.mjs +4172 -3921
  12. package/package.json +1 -1
  13. package/src/RedactoNoticeAssisted/RedactoNoticeAssisted.test.tsx +847 -0
  14. package/src/RedactoNoticeAssisted/RedactoNoticeAssisted.tsx +2133 -0
  15. package/src/RedactoNoticeAssisted/api/index.ts +269 -0
  16. package/src/RedactoNoticeAssisted/api/types.ts +180 -0
  17. package/src/RedactoNoticeAssisted/assets/redacto-logo.png +0 -0
  18. package/src/RedactoNoticeAssisted/constants.ts +51 -0
  19. package/src/RedactoNoticeAssisted/i18n.ts +1463 -0
  20. package/src/RedactoNoticeAssisted/index.ts +1 -0
  21. package/src/RedactoNoticeAssisted/injectStyles.ts +251 -0
  22. package/src/RedactoNoticeAssisted/styles.ts +730 -0
  23. package/src/RedactoNoticeAssisted/types.ts +24 -0
  24. package/src/RedactoNoticeAssisted/useMediaQuery.ts +36 -0
  25. package/src/RedactoPrivacyCenter/NotificationsPage.tsx +8 -0
  26. package/src/RedactoPrivacyCenter/api/actions.ts +6 -11
  27. package/src/RedactoPrivacyCenter/api/client.ts +15 -3
  28. package/src/RedactoPrivacyCenter/api/fetcher.ts +80 -1
  29. package/src/RedactoPrivacyCenter/components/ActivitiesList.tsx +193 -213
  30. package/src/RedactoPrivacyCenter/components/ActivityTimeline.tsx +239 -0
  31. package/src/RedactoPrivacyCenter/components/CaseDetails/MessagesTab.tsx +3 -1
  32. package/src/RedactoPrivacyCenter/components/CaseDetails/useMessagePolling.ts +8 -1
  33. package/src/RedactoPrivacyCenter/components/ConsentManager.tsx +23 -17
  34. package/src/RedactoPrivacyCenter/components/ConsentManagerCells.tsx +24 -10
  35. package/src/RedactoPrivacyCenter/components/NotificationHub/NotificationBell.tsx +16 -3
  36. package/src/RedactoPrivacyCenter/components/constant.ts +25 -0
  37. package/src/RedactoPrivacyCenter/components/types.ts +32 -1
  38. package/src/RedactoPrivacyCenter/lib/consent-manager/utils.tsx +25 -23
  39. package/src/RedactoPrivacyCenter/lib/constants.ts +23 -10
  40. package/src/RedactoPrivacyCenter/lib/queries.ts +9 -2
  41. package/src/RedactoPrivacyCenter/lib/utils.refresh-circuit.test.ts +127 -0
  42. package/src/RedactoPrivacyCenter/lib/utils.refresh-storage.test.ts +85 -0
  43. package/src/RedactoPrivacyCenter/lib/utils.ts +213 -63
  44. package/src/RedactoPrivacyCenter/locales/en/translation.json +3 -0
  45. package/src/RedactoPrivacyCenter/styles/injectStyles.ts +16 -0
  46. package/src/index.ts +2 -0
  47. package/src/shared/api-errors.ts +9 -0
  48. package/src/RedactoPrivacyCenter/components/activitiesColumns.tsx +0 -141
@@ -0,0 +1,730 @@
1
+ // Style constants for RedactoNoticeAssisted.
2
+ //
3
+ // The layout/typography tokens are copied verbatim from RedactoNoticeConsent/
4
+ // styles.ts so the two components are pixel-identical: 700px centered white modal,
5
+ // #4f87ff blue accent, #d0d5dd borders, 8px radius, same shadow/typography,
6
+ // accordion purposes, language pill. The OTP-verification and brief-confirmation
7
+ // tokens at the bottom are the only Assisted-specific additions (they reuse the
8
+ // same palette already present in NoticeConsent).
9
+ export const styles = {
10
+ overlay: {
11
+ position: "fixed",
12
+ top: 0,
13
+ left: 0,
14
+ width: "100%",
15
+ height: "100%",
16
+ backgroundColor: "rgba(0, 0, 0, 0.5)",
17
+ display: "flex",
18
+ alignItems: "center",
19
+ justifyContent: "center",
20
+ zIndex: 999,
21
+ animation:
22
+ "redactoAssistedOverlayFadeIn 0.2s cubic-bezier(0.16, 1, 0.3, 1)",
23
+ pointerEvents: "all",
24
+ margin: 0,
25
+ padding: 0,
26
+ boxSizing: "border-box",
27
+ },
28
+
29
+ modal: {
30
+ position: "fixed",
31
+ top: "50%",
32
+ left: "50%",
33
+ transform: "translate(-50%, -50%)",
34
+ width: "700px",
35
+ borderRadius: "8px",
36
+ backgroundColor: "#ffffff",
37
+ boxShadow: "4px 0px 4px 0px #00000040",
38
+ border: "none",
39
+ display: "flex",
40
+ flexDirection: "column",
41
+ maxHeight: "90vh",
42
+ zIndex: 1000,
43
+ margin: 0,
44
+ padding: 0,
45
+ boxSizing: "border-box",
46
+ textAlign: "left",
47
+ fontFamily: "inherit",
48
+ },
49
+
50
+ content: {
51
+ margin: "22px",
52
+ display: "flex",
53
+ flexDirection: "column",
54
+ flexGrow: 1,
55
+ overflow: "hidden",
56
+ minHeight: 0,
57
+ boxSizing: "border-box",
58
+ textAlign: "left",
59
+ },
60
+
61
+ topSection: {
62
+ display: "flex",
63
+ justifyContent: "space-between",
64
+ alignItems: "flex-start",
65
+ gap: "10px",
66
+ paddingBottom: "15px",
67
+ borderBottom: "none",
68
+ backgroundColor: "#ffffff",
69
+ margin: 0,
70
+ boxSizing: "border-box",
71
+ textAlign: "left",
72
+ },
73
+
74
+ topLeft: {
75
+ display: "flex",
76
+ alignItems: "center",
77
+ gap: "10px",
78
+ flex: "1 1 0",
79
+ minWidth: 0,
80
+ margin: 0,
81
+ padding: 0,
82
+ boxSizing: "border-box",
83
+ },
84
+
85
+ logo: {
86
+ height: "32px",
87
+ width: "auto",
88
+ maxWidth: "140px",
89
+ objectFit: "contain",
90
+ flexShrink: 0,
91
+ margin: 0,
92
+ padding: 0,
93
+ display: "block",
94
+ },
95
+
96
+ title: {
97
+ fontSize: "18px",
98
+ fontWeight: 700,
99
+ lineHeight: "150%",
100
+ letterSpacing: "0.2px",
101
+ verticalAlign: "middle",
102
+ color: "#101828",
103
+ flex: "1 1 auto",
104
+ minWidth: 0,
105
+ wordBreak: "normal",
106
+ overflowWrap: "anywhere",
107
+ margin: 0,
108
+ padding: 0,
109
+ textAlign: "left",
110
+ },
111
+
112
+ // Header pill, shared by the speaker (TTS) button and the language selector.
113
+ topRight: {
114
+ borderRadius: "8px",
115
+ padding: "3px 9px",
116
+ border: "1px solid #d0d5dd",
117
+ display: "flex",
118
+ alignItems: "center",
119
+ justifyContent: "center",
120
+ fontWeight: 400,
121
+ fontSize: "12px",
122
+ lineHeight: "150%",
123
+ letterSpacing: "0.2px",
124
+ verticalAlign: "middle",
125
+ color: "#344054",
126
+ gap: "5px",
127
+ margin: 0,
128
+ boxSizing: "border-box",
129
+ textAlign: "left",
130
+ cursor: "pointer",
131
+ backgroundColor: "#ffffff",
132
+ },
133
+
134
+ middleSection: {
135
+ margin: "0px",
136
+ display: "flex",
137
+ flexDirection: "column",
138
+ gap: "12px",
139
+ flexGrow: 1,
140
+ overflowY: "auto",
141
+ minHeight: 0,
142
+ paddingRight: "15px",
143
+ boxSizing: "border-box",
144
+ textAlign: "left",
145
+ },
146
+
147
+ privacyText: {
148
+ fontSize: "16px",
149
+ fontWeight: 400,
150
+ lineHeight: "150%",
151
+ color: "#344054",
152
+ margin: 0,
153
+ padding: 0,
154
+ textAlign: "left",
155
+ },
156
+
157
+ link: {
158
+ color: "#4f87ff",
159
+ textDecoration: "none",
160
+ margin: 0,
161
+ padding: 0,
162
+ boxSizing: "border-box",
163
+ },
164
+
165
+ subTitle: {
166
+ fontWeight: 600,
167
+ fontSize: "16px",
168
+ lineHeight: "150%",
169
+ letterSpacing: "0.2px",
170
+ color: "#101828",
171
+ margin: 0,
172
+ padding: 0,
173
+ textAlign: "left",
174
+ },
175
+
176
+ optionsContainer: {
177
+ display: "flex",
178
+ flexDirection: "column",
179
+ gap: "10px",
180
+ margin: 0,
181
+ padding: 0,
182
+ boxSizing: "border-box",
183
+ },
184
+
185
+ optionItem: {
186
+ display: "flex",
187
+ justifyContent: "space-between",
188
+ alignItems: "center",
189
+ margin: 0,
190
+ padding: 0,
191
+ boxSizing: "border-box",
192
+ },
193
+
194
+ optionLeft: {
195
+ display: "flex",
196
+ gap: "12px",
197
+ alignItems: "center",
198
+ cursor: "pointer",
199
+ margin: 0,
200
+ padding: 0,
201
+ boxSizing: "border-box",
202
+ },
203
+
204
+ optionTextContainer: {
205
+ display: "flex",
206
+ flexDirection: "column",
207
+ margin: 0,
208
+ padding: 0,
209
+ boxSizing: "border-box",
210
+ },
211
+
212
+ optionTitle: {
213
+ fontWeight: 500,
214
+ fontSize: "16px",
215
+ lineHeight: "150%",
216
+ letterSpacing: "0.2px",
217
+ color: "#101828",
218
+ margin: 0,
219
+ padding: 0,
220
+ textAlign: "left",
221
+ },
222
+
223
+ optionDescription: {
224
+ fontWeight: 400,
225
+ fontSize: "12px",
226
+ lineHeight: "150%",
227
+ letterSpacing: "0.2px",
228
+ color: "#475467",
229
+ verticalAlign: "middle",
230
+ margin: 0,
231
+ padding: 0,
232
+ textAlign: "left",
233
+ },
234
+
235
+ dataElementsContainer: {
236
+ marginLeft: "27px",
237
+ display: "flex",
238
+ flexDirection: "column",
239
+ margin: 0,
240
+ padding: 0,
241
+ boxSizing: "border-box",
242
+ paddingLeft: "22px",
243
+ },
244
+
245
+ dataElementItem: {
246
+ display: "flex",
247
+ alignItems: "center",
248
+ gap: "10px",
249
+ justifyContent: "space-between",
250
+ margin: 0,
251
+ padding: 0,
252
+ boxSizing: "border-box",
253
+ minHeight: "24px",
254
+ },
255
+
256
+ dataElementText: {
257
+ fontWeight: 400,
258
+ fontSize: "14px",
259
+ lineHeight: "150%",
260
+ letterSpacing: "0.2px",
261
+ color: "#344054",
262
+ margin: 0,
263
+ padding: 0,
264
+ textAlign: "left",
265
+ },
266
+
267
+ languageSelectorContainer: {
268
+ position: "relative",
269
+ margin: 0,
270
+ padding: 0,
271
+ boxSizing: "border-box",
272
+ },
273
+
274
+ languageDropdown: {
275
+ position: "absolute",
276
+ top: "100%",
277
+ right: 0,
278
+ backgroundColor: "#ffffff",
279
+ border: "1px solid #d0d5dd",
280
+ borderRadius: "4px",
281
+ boxShadow: "0px 2px 4px rgba(0, 0, 0, 0.1)",
282
+ zIndex: 10,
283
+ width: "max-content",
284
+ maxHeight: "200px",
285
+ overflowY: "auto",
286
+ marginTop: "4px",
287
+ padding: 0,
288
+ boxSizing: "border-box",
289
+ textAlign: "left",
290
+ },
291
+
292
+ languageItem: {
293
+ padding: "8px 12px",
294
+ cursor: "pointer",
295
+ fontSize: "12px",
296
+ color: "#344054",
297
+ backgroundColor: "#ffffff",
298
+ borderBottom: "1px solid #e5e7eb",
299
+ margin: 0,
300
+ boxSizing: "border-box",
301
+ textAlign: "left",
302
+ },
303
+
304
+ selectedLanguageItem: {
305
+ backgroundColor: "#f3f4f6",
306
+ fontWeight: 600,
307
+ },
308
+
309
+ // ── Inline verify panel ───────────────────────────────────────────────────
310
+ // Single-screen flow: the notice stays mounted and this section is appended
311
+ // below it once the user clicks Confirm. It lives on the SAME white surface as
312
+ // the notice and is set apart only by a top divider (mirroring the DPO footer),
313
+ // so the mobile/OTP step reads as a continuation of the notice — not a card.
314
+ verifyPanel: {
315
+ marginTop: "12px",
316
+ paddingTop: "14px",
317
+ borderTop: "1px solid rgba(152, 162, 179, 0.3)",
318
+ boxSizing: "border-box",
319
+ },
320
+
321
+ verifyPanelHeader: {
322
+ display: "flex",
323
+ alignItems: "center",
324
+ justifyContent: "space-between",
325
+ gap: "10px",
326
+ marginBottom: "12px",
327
+ boxSizing: "border-box",
328
+ },
329
+
330
+ verifyPanelTitle: {
331
+ display: "inline-flex",
332
+ alignItems: "center",
333
+ gap: "8px",
334
+ fontWeight: 600,
335
+ fontSize: "14px",
336
+ letterSpacing: "0.2px",
337
+ lineHeight: "150%",
338
+ color: "#344054",
339
+ margin: 0,
340
+ padding: 0,
341
+ },
342
+
343
+ // Quiet text-button to reopen the notice selections. Colour set inline from
344
+ // the brand accent.
345
+ editLink: {
346
+ background: "none",
347
+ border: "none",
348
+ padding: 0,
349
+ margin: 0,
350
+ fontWeight: 500,
351
+ fontSize: "13px",
352
+ cursor: "pointer",
353
+ fontFamily: "inherit",
354
+ whiteSpace: "nowrap",
355
+ display: "inline-flex",
356
+ alignItems: "center",
357
+ gap: "4px",
358
+ },
359
+
360
+ // Dim + lock the purposes once verification has started.
361
+ lockedOptions: {
362
+ opacity: 0.55,
363
+ pointerEvents: "none",
364
+ transition: "opacity 0.2s ease",
365
+ },
366
+
367
+ // ── Verification-method label row (switch-link picker) ────────────────────
368
+ // A single justified row: the active method's icon + field label on the left,
369
+ // and a quiet accent text-link on the right to switch to the other method.
370
+ // The link is hidden once the OTP is sent (the status row takes over).
371
+ fieldLabelRow: {
372
+ display: "flex",
373
+ alignItems: "center",
374
+ justifyContent: "space-between",
375
+ gap: "10px",
376
+ width: "100%",
377
+ boxSizing: "border-box",
378
+ },
379
+
380
+ // ── OTP verification ──────────────────────────────────────────────────────
381
+ // Spacious, soft, rounded verification column. The accent (focus rings, filled
382
+ // boxes, links, primary button) is driven by the API brand colour via the
383
+ // --ra-accent / --ra-accent-soft CSS variables set on the modal root.
384
+ phoneFieldWrap: {
385
+ width: "100%",
386
+ display: "flex",
387
+ flexDirection: "column",
388
+ gap: "10px",
389
+ boxSizing: "border-box",
390
+ },
391
+
392
+ fieldLabel: {
393
+ fontWeight: 500,
394
+ fontSize: "13px",
395
+ lineHeight: "150%",
396
+ color: "#475467",
397
+ margin: 0,
398
+ padding: 0,
399
+ textAlign: "left",
400
+ },
401
+
402
+ // Field label carrying the method icon (phone / envelope) + text.
403
+ fieldLabelWithIcon: {
404
+ display: "inline-flex",
405
+ alignItems: "center",
406
+ gap: "6px",
407
+ fontWeight: 500,
408
+ fontSize: "13px",
409
+ lineHeight: "150%",
410
+ color: "#475467",
411
+ margin: 0,
412
+ padding: 0,
413
+ textAlign: "left",
414
+ },
415
+
416
+ phoneField: {
417
+ display: "flex",
418
+ alignItems: "center",
419
+ width: "100%",
420
+ border: "1px solid #d0d5dd",
421
+ borderRadius: "8px",
422
+ backgroundColor: "#ffffff",
423
+ overflow: "hidden",
424
+ boxSizing: "border-box",
425
+ transition: "border-color 0.15s, box-shadow 0.15s",
426
+ },
427
+
428
+ phonePrefix: {
429
+ display: "flex",
430
+ alignItems: "center",
431
+ padding: "10px 14px",
432
+ fontSize: "15px",
433
+ fontWeight: 400,
434
+ color: "#344054",
435
+ backgroundColor: "#f9fafb",
436
+ borderRight: "1px solid #d0d5dd",
437
+ whiteSpace: "nowrap",
438
+ userSelect: "none",
439
+ flexShrink: 0,
440
+ },
441
+
442
+ phoneInput: {
443
+ flex: "1 1 auto",
444
+ minWidth: 0,
445
+ border: "none",
446
+ outline: "none",
447
+ padding: "10px 14px",
448
+ fontSize: "15px",
449
+ fontWeight: 400,
450
+ lineHeight: "150%",
451
+ color: "#344054",
452
+ backgroundColor: "transparent",
453
+ fontFamily: "inherit",
454
+ boxSizing: "border-box",
455
+ },
456
+
457
+ helperText: {
458
+ fontWeight: 400,
459
+ fontSize: "13px",
460
+ lineHeight: "150%",
461
+ color: "#475467",
462
+ margin: 0,
463
+ padding: 0,
464
+ textAlign: "left",
465
+ },
466
+
467
+ // Inline error text under the phone field / OTP boxes.
468
+ fieldError: {
469
+ fontWeight: 400,
470
+ fontSize: "12px",
471
+ lineHeight: "150%",
472
+ color: "#d92d20",
473
+ textAlign: "center",
474
+ margin: 0,
475
+ padding: 0,
476
+ },
477
+
478
+ // "Change Mobile Number" link — colour is set inline from the brand accent.
479
+ changeMobileLink: {
480
+ background: "none",
481
+ border: "none",
482
+ padding: 0,
483
+ margin: 0,
484
+ fontWeight: 500,
485
+ fontSize: "13px",
486
+ cursor: "pointer",
487
+ fontFamily: "inherit",
488
+ whiteSpace: "nowrap",
489
+ },
490
+
491
+ // Justified status row under the field once the code is sent:
492
+ // "✓ OTP sent to …" on the left, "Change number" on the right.
493
+ otpStatusRow: {
494
+ display: "flex",
495
+ alignItems: "center",
496
+ justifyContent: "space-between",
497
+ gap: "10px",
498
+ width: "100%",
499
+ flexWrap: "wrap",
500
+ margin: 0,
501
+ padding: 0,
502
+ },
503
+
504
+ otpSentText: {
505
+ display: "inline-flex",
506
+ alignItems: "center",
507
+ gap: "6px",
508
+ fontWeight: 400,
509
+ fontSize: "13px",
510
+ lineHeight: "150%",
511
+ color: "#067647",
512
+ margin: 0,
513
+ padding: 0,
514
+ },
515
+
516
+ otpRow: {
517
+ display: "flex",
518
+ gap: "8px",
519
+ justifyContent: "center",
520
+ width: "100%",
521
+ margin: 0,
522
+ padding: 0,
523
+ },
524
+
525
+ otpBox: {
526
+ flex: "1 1 0",
527
+ minWidth: 0,
528
+ maxWidth: "44px",
529
+ height: "44px",
530
+ borderRadius: "8px",
531
+ border: "1px solid #d0d5dd",
532
+ textAlign: "center",
533
+ fontSize: "18px",
534
+ fontWeight: 500,
535
+ color: "#101828",
536
+ backgroundColor: "#ffffff",
537
+ boxSizing: "border-box",
538
+ padding: 0,
539
+ transition: "border-color 0.15s, box-shadow 0.15s, background-color 0.15s",
540
+ },
541
+
542
+ centerLabel: {
543
+ fontWeight: 500,
544
+ fontSize: "13px",
545
+ lineHeight: "150%",
546
+ color: "#475467",
547
+ textAlign: "center",
548
+ margin: 0,
549
+ padding: 0,
550
+ },
551
+
552
+ resendText: {
553
+ display: "flex",
554
+ alignItems: "center",
555
+ justifyContent: "center",
556
+ gap: "6px",
557
+ fontWeight: 400,
558
+ fontSize: "13px",
559
+ lineHeight: "150%",
560
+ color: "#475467",
561
+ textAlign: "center",
562
+ margin: 0,
563
+ padding: 0,
564
+ },
565
+
566
+ // Resend link — colour is set inline from the brand accent.
567
+ resendLink: {
568
+ background: "none",
569
+ border: "none",
570
+ padding: 0,
571
+ margin: 0,
572
+ fontWeight: 600,
573
+ fontSize: "13px",
574
+ cursor: "pointer",
575
+ fontFamily: "inherit",
576
+ },
577
+
578
+ // ── Brief confirmation screen ─────────────────────────────────────────────
579
+ confirmedCenter: {
580
+ display: "flex",
581
+ flexDirection: "column",
582
+ alignItems: "center",
583
+ textAlign: "center",
584
+ gap: "8px",
585
+ paddingTop: "8px",
586
+ },
587
+
588
+ successCircle: {
589
+ width: "64px",
590
+ height: "64px",
591
+ borderRadius: "50%",
592
+ backgroundColor: "#10B981",
593
+ display: "flex",
594
+ alignItems: "center",
595
+ justifyContent: "center",
596
+ animation: "redactoAssistedPop 0.4s cubic-bezier(0.16, 1, 0.3, 1)",
597
+ },
598
+
599
+ confirmedTitle: {
600
+ fontWeight: 700,
601
+ fontSize: "20px",
602
+ lineHeight: "140%",
603
+ color: "#101828",
604
+ margin: 0,
605
+ padding: 0,
606
+ },
607
+
608
+ confirmedSubtitle: {
609
+ fontWeight: 400,
610
+ fontSize: "13px",
611
+ lineHeight: "150%",
612
+ color: "#475467",
613
+ margin: 0,
614
+ padding: 0,
615
+ },
616
+
617
+ referenceBanner: {
618
+ backgroundColor: "#EFF6FF",
619
+ borderRadius: "8px",
620
+ padding: "12px 14px",
621
+ textAlign: "center",
622
+ boxSizing: "border-box",
623
+ },
624
+
625
+ referenceLabel: {
626
+ fontWeight: 600,
627
+ fontSize: "10px",
628
+ letterSpacing: "0.6px",
629
+ textTransform: "uppercase",
630
+ color: "#3b6fd4",
631
+ margin: 0,
632
+ padding: 0,
633
+ },
634
+
635
+ referenceValue: {
636
+ fontWeight: 700,
637
+ fontSize: "16px",
638
+ letterSpacing: "0.5px",
639
+ color: "#1E40AF",
640
+ margin: "4px 0 0 0",
641
+ padding: 0,
642
+ fontFamily:
643
+ "ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace",
644
+ },
645
+
646
+ divider: {
647
+ border: "none",
648
+ borderTop: "1px solid #eaecf0",
649
+ margin: 0,
650
+ },
651
+
652
+ // ── Footer buttons (NoticeConsent tokens) ─────────────────────────────────
653
+ bottomSection: {
654
+ display: "flex",
655
+ justifyContent: "space-between",
656
+ gap: "29px",
657
+ paddingTop: "15px",
658
+ borderTop: "none",
659
+ backgroundColor: "#ffffff",
660
+ margin: 0,
661
+ boxSizing: "border-box",
662
+ },
663
+
664
+ button: {
665
+ width: "100%",
666
+ borderRadius: "8px",
667
+ padding: "9px 45px",
668
+ fontWeight: 400,
669
+ fontSize: "16px",
670
+ lineHeight: "150%",
671
+ letterSpacing: "0.2px",
672
+ cursor: "pointer",
673
+ margin: 0,
674
+ boxSizing: "border-box",
675
+ textAlign: "center",
676
+ },
677
+
678
+ acceptButton: {
679
+ backgroundColor: "#4f87ff",
680
+ border: "none",
681
+ color: "#ffffff",
682
+ },
683
+
684
+ cancelButton: {
685
+ border: "1px solid #d0d5dd",
686
+ backgroundColor: "#ffffff",
687
+ color: "#000000",
688
+ },
689
+
690
+ loadingSpinner: {
691
+ width: "40px",
692
+ height: "40px",
693
+ border: "4px solid #f3f3f3",
694
+ borderTop: "4px solid #4f87ff",
695
+ borderRadius: "50%",
696
+ animation: "redactoAssistedSpin 1s linear infinite",
697
+ boxSizing: "border-box",
698
+ },
699
+
700
+ // Loading / error states.
701
+ loadingWrap: {
702
+ display: "flex",
703
+ flexDirection: "column",
704
+ alignItems: "center",
705
+ justifyContent: "center",
706
+ gap: "12px",
707
+ minHeight: "220px",
708
+ textAlign: "center",
709
+ boxSizing: "border-box",
710
+ },
711
+
712
+ errorTitle: {
713
+ fontWeight: 600,
714
+ fontSize: "16px",
715
+ lineHeight: "150%",
716
+ color: "#101828",
717
+ margin: 0,
718
+ padding: 0,
719
+ },
720
+
721
+ errorText: {
722
+ fontWeight: 400,
723
+ fontSize: "13px",
724
+ lineHeight: "150%",
725
+ color: "#667085",
726
+ margin: 0,
727
+ padding: 0,
728
+ maxWidth: "360px",
729
+ },
730
+ } as const;