@fleetless/contracts 15.6.0 → 16.0.0-next.1

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.
@@ -939,11 +939,26 @@
939
939
  "properties": {
940
940
  "text_id": {
941
941
  "type": "string",
942
- "const": "DR-1374-draft-3-C.4"
942
+ "enum": [
943
+ "C4-1168-checkout",
944
+ "C4-1168-pay-and-switch",
945
+ "C4-1168-switch",
946
+ "C4-1168-schedule-switch",
947
+ "C4-1168-schedule-downgrade",
948
+ "C4-1168-cancel"
949
+ ],
950
+ "description": "The approved sentence this display shows, one per action."
943
951
  },
944
952
  "text": {
945
953
  "type": "string",
946
- "minLength": 1
954
+ "minLength": 1,
955
+ "pattern": "^By selecting “",
956
+ "description": "The consent sentence shown directly above the button, naming the button."
957
+ },
958
+ "action_label": {
959
+ "type": "string",
960
+ "minLength": 1,
961
+ "description": "The label of the one button that confirms this decision."
947
962
  },
948
963
  "terms": {
949
964
  "type": "object",
@@ -1003,10 +1018,127 @@
1003
1018
  "required": [
1004
1019
  "text_id",
1005
1020
  "text",
1021
+ "action_label",
1006
1022
  "terms",
1007
1023
  "dpa"
1008
1024
  ],
1009
- "additionalProperties": false
1025
+ "additionalProperties": false,
1026
+ "allOf": [
1027
+ {
1028
+ "if": {
1029
+ "properties": {
1030
+ "text_id": {
1031
+ "const": "C4-1168-checkout"
1032
+ }
1033
+ },
1034
+ "required": [
1035
+ "text_id"
1036
+ ]
1037
+ },
1038
+ "then": {
1039
+ "properties": {
1040
+ "action_label": {
1041
+ "pattern": "^Pay \\S.* with Mollie$"
1042
+ }
1043
+ }
1044
+ }
1045
+ },
1046
+ {
1047
+ "if": {
1048
+ "properties": {
1049
+ "text_id": {
1050
+ "const": "C4-1168-pay-and-switch"
1051
+ }
1052
+ },
1053
+ "required": [
1054
+ "text_id"
1055
+ ]
1056
+ },
1057
+ "then": {
1058
+ "properties": {
1059
+ "action_label": {
1060
+ "pattern": "^Pay \\S.* and switch$"
1061
+ }
1062
+ }
1063
+ }
1064
+ },
1065
+ {
1066
+ "if": {
1067
+ "properties": {
1068
+ "text_id": {
1069
+ "const": "C4-1168-switch"
1070
+ }
1071
+ },
1072
+ "required": [
1073
+ "text_id"
1074
+ ]
1075
+ },
1076
+ "then": {
1077
+ "properties": {
1078
+ "action_label": {
1079
+ "pattern": "^Switch to \\S.*$"
1080
+ }
1081
+ }
1082
+ }
1083
+ },
1084
+ {
1085
+ "if": {
1086
+ "properties": {
1087
+ "text_id": {
1088
+ "const": "C4-1168-schedule-switch"
1089
+ }
1090
+ },
1091
+ "required": [
1092
+ "text_id"
1093
+ ]
1094
+ },
1095
+ "then": {
1096
+ "properties": {
1097
+ "action_label": {
1098
+ "const": "Switch to monthly at period end"
1099
+ }
1100
+ }
1101
+ }
1102
+ },
1103
+ {
1104
+ "if": {
1105
+ "properties": {
1106
+ "text_id": {
1107
+ "const": "C4-1168-schedule-downgrade"
1108
+ }
1109
+ },
1110
+ "required": [
1111
+ "text_id"
1112
+ ]
1113
+ },
1114
+ "then": {
1115
+ "properties": {
1116
+ "action_label": {
1117
+ "pattern": "^Schedule downgrade to \\S.*$"
1118
+ }
1119
+ }
1120
+ }
1121
+ },
1122
+ {
1123
+ "if": {
1124
+ "properties": {
1125
+ "text_id": {
1126
+ "const": "C4-1168-cancel"
1127
+ }
1128
+ },
1129
+ "required": [
1130
+ "text_id"
1131
+ ]
1132
+ },
1133
+ "then": {
1134
+ "properties": {
1135
+ "action_label": {
1136
+ "const": "Cancel at period end"
1137
+ }
1138
+ }
1139
+ }
1140
+ }
1141
+ ]
1010
1142
  },
1011
1143
  "expires_at": {
1012
1144
  "type": "string",
@@ -1986,11 +2118,26 @@
1986
2118
  "properties": {
1987
2119
  "text_id": {
1988
2120
  "type": "string",
1989
- "const": "DR-1374-draft-3-C.4"
2121
+ "enum": [
2122
+ "C4-1168-checkout",
2123
+ "C4-1168-pay-and-switch",
2124
+ "C4-1168-switch",
2125
+ "C4-1168-schedule-switch",
2126
+ "C4-1168-schedule-downgrade",
2127
+ "C4-1168-cancel"
2128
+ ],
2129
+ "description": "The approved sentence this display shows, one per action."
1990
2130
  },
1991
2131
  "text": {
1992
2132
  "type": "string",
1993
- "minLength": 1
2133
+ "minLength": 1,
2134
+ "pattern": "^By selecting “",
2135
+ "description": "The consent sentence shown directly above the button, naming the button."
2136
+ },
2137
+ "action_label": {
2138
+ "type": "string",
2139
+ "minLength": 1,
2140
+ "description": "The label of the one button that confirms this decision."
1994
2141
  },
1995
2142
  "terms": {
1996
2143
  "type": "object",
@@ -2050,10 +2197,127 @@
2050
2197
  "required": [
2051
2198
  "text_id",
2052
2199
  "text",
2200
+ "action_label",
2053
2201
  "terms",
2054
2202
  "dpa"
2055
2203
  ],
2056
- "additionalProperties": false
2204
+ "additionalProperties": false,
2205
+ "allOf": [
2206
+ {
2207
+ "if": {
2208
+ "properties": {
2209
+ "text_id": {
2210
+ "const": "C4-1168-checkout"
2211
+ }
2212
+ },
2213
+ "required": [
2214
+ "text_id"
2215
+ ]
2216
+ },
2217
+ "then": {
2218
+ "properties": {
2219
+ "action_label": {
2220
+ "pattern": "^Pay \\S.* with Mollie$"
2221
+ }
2222
+ }
2223
+ }
2224
+ },
2225
+ {
2226
+ "if": {
2227
+ "properties": {
2228
+ "text_id": {
2229
+ "const": "C4-1168-pay-and-switch"
2230
+ }
2231
+ },
2232
+ "required": [
2233
+ "text_id"
2234
+ ]
2235
+ },
2236
+ "then": {
2237
+ "properties": {
2238
+ "action_label": {
2239
+ "pattern": "^Pay \\S.* and switch$"
2240
+ }
2241
+ }
2242
+ }
2243
+ },
2244
+ {
2245
+ "if": {
2246
+ "properties": {
2247
+ "text_id": {
2248
+ "const": "C4-1168-switch"
2249
+ }
2250
+ },
2251
+ "required": [
2252
+ "text_id"
2253
+ ]
2254
+ },
2255
+ "then": {
2256
+ "properties": {
2257
+ "action_label": {
2258
+ "pattern": "^Switch to \\S.*$"
2259
+ }
2260
+ }
2261
+ }
2262
+ },
2263
+ {
2264
+ "if": {
2265
+ "properties": {
2266
+ "text_id": {
2267
+ "const": "C4-1168-schedule-switch"
2268
+ }
2269
+ },
2270
+ "required": [
2271
+ "text_id"
2272
+ ]
2273
+ },
2274
+ "then": {
2275
+ "properties": {
2276
+ "action_label": {
2277
+ "const": "Switch to monthly at period end"
2278
+ }
2279
+ }
2280
+ }
2281
+ },
2282
+ {
2283
+ "if": {
2284
+ "properties": {
2285
+ "text_id": {
2286
+ "const": "C4-1168-schedule-downgrade"
2287
+ }
2288
+ },
2289
+ "required": [
2290
+ "text_id"
2291
+ ]
2292
+ },
2293
+ "then": {
2294
+ "properties": {
2295
+ "action_label": {
2296
+ "pattern": "^Schedule downgrade to \\S.*$"
2297
+ }
2298
+ }
2299
+ }
2300
+ },
2301
+ {
2302
+ "if": {
2303
+ "properties": {
2304
+ "text_id": {
2305
+ "const": "C4-1168-cancel"
2306
+ }
2307
+ },
2308
+ "required": [
2309
+ "text_id"
2310
+ ]
2311
+ },
2312
+ "then": {
2313
+ "properties": {
2314
+ "action_label": {
2315
+ "const": "Cancel at period end"
2316
+ }
2317
+ }
2318
+ }
2319
+ }
2320
+ ]
2057
2321
  },
2058
2322
  "expires_at": {
2059
2323
  "type": "string",
@@ -3033,11 +3297,26 @@
3033
3297
  "properties": {
3034
3298
  "text_id": {
3035
3299
  "type": "string",
3036
- "const": "DR-1374-draft-3-C.4"
3300
+ "enum": [
3301
+ "C4-1168-checkout",
3302
+ "C4-1168-pay-and-switch",
3303
+ "C4-1168-switch",
3304
+ "C4-1168-schedule-switch",
3305
+ "C4-1168-schedule-downgrade",
3306
+ "C4-1168-cancel"
3307
+ ],
3308
+ "description": "The approved sentence this display shows, one per action."
3037
3309
  },
3038
3310
  "text": {
3039
3311
  "type": "string",
3040
- "minLength": 1
3312
+ "minLength": 1,
3313
+ "pattern": "^By selecting “",
3314
+ "description": "The consent sentence shown directly above the button, naming the button."
3315
+ },
3316
+ "action_label": {
3317
+ "type": "string",
3318
+ "minLength": 1,
3319
+ "description": "The label of the one button that confirms this decision."
3041
3320
  },
3042
3321
  "terms": {
3043
3322
  "type": "object",
@@ -3097,10 +3376,127 @@
3097
3376
  "required": [
3098
3377
  "text_id",
3099
3378
  "text",
3379
+ "action_label",
3100
3380
  "terms",
3101
3381
  "dpa"
3102
3382
  ],
3103
- "additionalProperties": false
3383
+ "additionalProperties": false,
3384
+ "allOf": [
3385
+ {
3386
+ "if": {
3387
+ "properties": {
3388
+ "text_id": {
3389
+ "const": "C4-1168-checkout"
3390
+ }
3391
+ },
3392
+ "required": [
3393
+ "text_id"
3394
+ ]
3395
+ },
3396
+ "then": {
3397
+ "properties": {
3398
+ "action_label": {
3399
+ "pattern": "^Pay \\S.* with Mollie$"
3400
+ }
3401
+ }
3402
+ }
3403
+ },
3404
+ {
3405
+ "if": {
3406
+ "properties": {
3407
+ "text_id": {
3408
+ "const": "C4-1168-pay-and-switch"
3409
+ }
3410
+ },
3411
+ "required": [
3412
+ "text_id"
3413
+ ]
3414
+ },
3415
+ "then": {
3416
+ "properties": {
3417
+ "action_label": {
3418
+ "pattern": "^Pay \\S.* and switch$"
3419
+ }
3420
+ }
3421
+ }
3422
+ },
3423
+ {
3424
+ "if": {
3425
+ "properties": {
3426
+ "text_id": {
3427
+ "const": "C4-1168-switch"
3428
+ }
3429
+ },
3430
+ "required": [
3431
+ "text_id"
3432
+ ]
3433
+ },
3434
+ "then": {
3435
+ "properties": {
3436
+ "action_label": {
3437
+ "pattern": "^Switch to \\S.*$"
3438
+ }
3439
+ }
3440
+ }
3441
+ },
3442
+ {
3443
+ "if": {
3444
+ "properties": {
3445
+ "text_id": {
3446
+ "const": "C4-1168-schedule-switch"
3447
+ }
3448
+ },
3449
+ "required": [
3450
+ "text_id"
3451
+ ]
3452
+ },
3453
+ "then": {
3454
+ "properties": {
3455
+ "action_label": {
3456
+ "const": "Switch to monthly at period end"
3457
+ }
3458
+ }
3459
+ }
3460
+ },
3461
+ {
3462
+ "if": {
3463
+ "properties": {
3464
+ "text_id": {
3465
+ "const": "C4-1168-schedule-downgrade"
3466
+ }
3467
+ },
3468
+ "required": [
3469
+ "text_id"
3470
+ ]
3471
+ },
3472
+ "then": {
3473
+ "properties": {
3474
+ "action_label": {
3475
+ "pattern": "^Schedule downgrade to \\S.*$"
3476
+ }
3477
+ }
3478
+ }
3479
+ },
3480
+ {
3481
+ "if": {
3482
+ "properties": {
3483
+ "text_id": {
3484
+ "const": "C4-1168-cancel"
3485
+ }
3486
+ },
3487
+ "required": [
3488
+ "text_id"
3489
+ ]
3490
+ },
3491
+ "then": {
3492
+ "properties": {
3493
+ "action_label": {
3494
+ "const": "Cancel at period end"
3495
+ }
3496
+ }
3497
+ }
3498
+ }
3499
+ ]
3104
3500
  },
3105
3501
  "expires_at": {
3106
3502
  "type": "string",