@battle-racing/br-common-lib 6.2.1-rc.0 → 6.2.1-rc.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.
@@ -336,6 +336,10 @@ export declare const rgbModuleCommandSchema: z.ZodUnion<readonly [z.ZodObject<{
336
336
  }>;
337
337
  brightness: z.ZodNumber;
338
338
  effectTime: z.ZodNumber;
339
+ targets: z.ZodOptional<z.ZodArray<z.ZodEnum<{
340
+ readonly FRONT: "front";
341
+ readonly BACK: "back";
342
+ }>>>;
339
343
  }, z.core.$strip>;
340
344
  }, z.core.$strip>, z.ZodObject<{
341
345
  module: z.ZodLiteral<"rgb">;
@@ -361,6 +365,10 @@ export declare const rgbModuleCommandSchema: z.ZodUnion<readonly [z.ZodObject<{
361
365
  readonly EMERGENCY_EFFECT: "Emergency Effect";
362
366
  readonly WAIT_EFFECT: "Wait Effect";
363
367
  }>;
368
+ targets: z.ZodOptional<z.ZodArray<z.ZodEnum<{
369
+ readonly FRONT: "front";
370
+ readonly BACK: "back";
371
+ }>>>;
364
372
  }, z.core.$strip>;
365
373
  }, z.core.$strip>]>;
366
374
  export declare const leftStarBackLaserModuleCommandSchema: z.ZodUnion<readonly [z.ZodObject<{
@@ -1271,6 +1279,10 @@ export declare const allCommandsConfigSchema: z.ZodIntersection<z.ZodUnion<reado
1271
1279
  }>;
1272
1280
  brightness: z.ZodNumber;
1273
1281
  effectTime: z.ZodNumber;
1282
+ targets: z.ZodOptional<z.ZodArray<z.ZodEnum<{
1283
+ readonly FRONT: "front";
1284
+ readonly BACK: "back";
1285
+ }>>>;
1274
1286
  }, z.core.$strip>;
1275
1287
  }, z.core.$strip>, z.ZodObject<{
1276
1288
  module: z.ZodLiteral<"rgb">;
@@ -1296,6 +1308,10 @@ export declare const allCommandsConfigSchema: z.ZodIntersection<z.ZodUnion<reado
1296
1308
  readonly EMERGENCY_EFFECT: "Emergency Effect";
1297
1309
  readonly WAIT_EFFECT: "Wait Effect";
1298
1310
  }>;
1311
+ targets: z.ZodOptional<z.ZodArray<z.ZodEnum<{
1312
+ readonly FRONT: "front";
1313
+ readonly BACK: "back";
1314
+ }>>>;
1299
1315
  }, z.core.$strip>;
1300
1316
  }, z.core.$strip>]>, z.ZodUnion<readonly [z.ZodObject<{
1301
1317
  module: z.ZodLiteral<"speed">;
@@ -244,6 +244,10 @@ export declare const flowSchema: z.ZodObject<{
244
244
  }>;
245
245
  brightness: z.ZodNumber;
246
246
  effectTime: z.ZodNumber;
247
+ targets: z.ZodOptional<z.ZodArray<z.ZodEnum<{
248
+ readonly FRONT: "front";
249
+ readonly BACK: "back";
250
+ }>>>;
247
251
  }, z.core.$strip>;
248
252
  }, z.core.$strip>, z.ZodObject<{
249
253
  module: z.ZodLiteral<"rgb">;
@@ -269,6 +273,10 @@ export declare const flowSchema: z.ZodObject<{
269
273
  readonly EMERGENCY_EFFECT: "Emergency Effect";
270
274
  readonly WAIT_EFFECT: "Wait Effect";
271
275
  }>;
276
+ targets: z.ZodOptional<z.ZodArray<z.ZodEnum<{
277
+ readonly FRONT: "front";
278
+ readonly BACK: "back";
279
+ }>>>;
272
280
  }, z.core.$strip>;
273
281
  }, z.core.$strip>]>, z.ZodUnion<readonly [z.ZodObject<{
274
282
  module: z.ZodLiteral<"speed">;
@@ -13,7 +13,10 @@ export declare const kartHardwareStateSchema: z.ZodObject<{
13
13
  current: z.ZodNumber;
14
14
  configured: z.ZodNumber;
15
15
  }, z.core.$strip>>;
16
- rgb: z.ZodNullable<z.ZodEnum<{
16
+ rgb: z.ZodRecord<z.ZodEnum<{
17
+ readonly FRONT: "front";
18
+ readonly BACK: "back";
19
+ }> & z.core.$partial, z.ZodEnum<{
17
20
  readonly SHOWING_COLOR: "Showing Color";
18
21
  readonly NOT_CONFIGURED: "Not Configured";
19
22
  readonly CONFIGURING_RGB: "Configuring RGB";
@@ -16,7 +16,8 @@ exports.kartHardwareStateSchema = zod_1.z.object({
16
16
  configured: zod_1.z.number(),
17
17
  })
18
18
  .nullable(),
19
- rgb: rgb_1.rgbStatusSchema.nullable(),
19
+ // Only the configured RGB modules have a key
20
+ rgb: zod_1.z.partialRecord(rgb_1.rgbModuleLabelSchema, rgb_1.rgbStatusSchema),
20
21
  flag: zod_1.z
21
22
  .object({
22
23
  status: flag_1.flagStatusSchema,
@@ -28,6 +28,11 @@ export declare const moduleStatusSchema: z.ZodUnion<readonly [z.ZodObject<{
28
28
  DACVoltage: z.ZodNumber;
29
29
  currentDefaultSpeedConfig: z.ZodNumber;
30
30
  }, z.core.$strip>, z.ZodObject<{
31
+ label: z.ZodEnum<{
32
+ readonly FRONT: "front";
33
+ readonly BACK: "back";
34
+ }>;
35
+ address: z.ZodNumber;
31
36
  rgbStatus: z.ZodEnum<{
32
37
  readonly SHOWING_COLOR: "Showing Color";
33
38
  readonly NOT_CONFIGURED: "Not Configured";
@@ -10,3 +10,7 @@ export declare const RGB_ACTION_COMMANDS: {
10
10
  readonly EXEC: "Exec";
11
11
  readonly CONFIGURE: "Configure";
12
12
  };
13
+ export declare const RGB_MODULE_LABEL: {
14
+ readonly FRONT: "front";
15
+ readonly BACK: "back";
16
+ };
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.RGB_ACTION_COMMANDS = exports.RGB_STATUS = void 0;
3
+ exports.RGB_MODULE_LABEL = exports.RGB_ACTION_COMMANDS = exports.RGB_STATUS = void 0;
4
4
  exports.RGB_STATUS = {
5
5
  SHOWING_COLOR: 'Showing Color',
6
6
  NOT_CONFIGURED: 'Not Configured',
@@ -13,3 +13,7 @@ exports.RGB_ACTION_COMMANDS = {
13
13
  EXEC: 'Exec',
14
14
  CONFIGURE: 'Configure',
15
15
  };
16
+ exports.RGB_MODULE_LABEL = {
17
+ FRONT: 'front',
18
+ BACK: 'back',
19
+ };
@@ -11,7 +11,20 @@ export declare const rgbActionCommandSchema: z.ZodEnum<{
11
11
  readonly EXEC: "Exec";
12
12
  readonly CONFIGURE: "Configure";
13
13
  }>;
14
+ export declare const rgbModuleLabelSchema: z.ZodEnum<{
15
+ readonly FRONT: "front";
16
+ readonly BACK: "back";
17
+ }>;
18
+ export declare const rgbTargetsSchema: z.ZodOptional<z.ZodArray<z.ZodEnum<{
19
+ readonly FRONT: "front";
20
+ readonly BACK: "back";
21
+ }>>>;
14
22
  export declare const rgbModuleStatusSchema: z.ZodObject<{
23
+ label: z.ZodEnum<{
24
+ readonly FRONT: "front";
25
+ readonly BACK: "back";
26
+ }>;
27
+ address: z.ZodNumber;
15
28
  rgbStatus: z.ZodEnum<{
16
29
  readonly SHOWING_COLOR: "Showing Color";
17
30
  readonly NOT_CONFIGURED: "Not Configured";
@@ -52,6 +65,10 @@ export declare const rgbConfigurationOptionsSchema: z.ZodObject<{
52
65
  }>;
53
66
  brightness: z.ZodNumber;
54
67
  effectTime: z.ZodNumber;
68
+ targets: z.ZodOptional<z.ZodArray<z.ZodEnum<{
69
+ readonly FRONT: "front";
70
+ readonly BACK: "back";
71
+ }>>>;
55
72
  }, z.core.$strip>;
56
73
  export declare const rgbShowEffectOptionsSchema: z.ZodObject<{
57
74
  effect: z.ZodEnum<{
@@ -74,4 +91,8 @@ export declare const rgbShowEffectOptionsSchema: z.ZodObject<{
74
91
  readonly EMERGENCY_EFFECT: "Emergency Effect";
75
92
  readonly WAIT_EFFECT: "Wait Effect";
76
93
  }>;
94
+ targets: z.ZodOptional<z.ZodArray<z.ZodEnum<{
95
+ readonly FRONT: "front";
96
+ readonly BACK: "back";
97
+ }>>>;
77
98
  }, z.core.$strip>;
@@ -1,13 +1,18 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.rgbShowEffectOptionsSchema = exports.rgbConfigurationOptionsSchema = exports.rgbModuleStatusSchema = exports.rgbActionCommandSchema = exports.rgbStatusSchema = void 0;
3
+ exports.rgbShowEffectOptionsSchema = exports.rgbConfigurationOptionsSchema = exports.rgbModuleStatusSchema = exports.rgbTargetsSchema = exports.rgbModuleLabelSchema = exports.rgbActionCommandSchema = exports.rgbStatusSchema = void 0;
4
4
  const zod_1 = require("zod");
5
5
  const color_1 = require("../../color");
6
6
  const kart_effect_1 = require("../../hardware/kart-effect");
7
7
  const RGB_const_1 = require("./RGB.const");
8
8
  exports.rgbStatusSchema = zod_1.z.enum(RGB_const_1.RGB_STATUS);
9
9
  exports.rgbActionCommandSchema = zod_1.z.enum(RGB_const_1.RGB_ACTION_COMMANDS);
10
+ exports.rgbModuleLabelSchema = zod_1.z.enum(RGB_const_1.RGB_MODULE_LABEL);
11
+ // When targets is missing the command goes to every configured RGB module
12
+ exports.rgbTargetsSchema = zod_1.z.array(exports.rgbModuleLabelSchema).min(1).optional();
10
13
  exports.rgbModuleStatusSchema = zod_1.z.object({
14
+ label: exports.rgbModuleLabelSchema,
15
+ address: zod_1.z.number(),
11
16
  rgbStatus: exports.rgbStatusSchema,
12
17
  kartColor: color_1.colorNameSchema,
13
18
  });
@@ -15,7 +20,9 @@ exports.rgbConfigurationOptionsSchema = zod_1.z.object({
15
20
  kartColor: color_1.colorNameSchema,
16
21
  brightness: zod_1.z.number().min(0).max(100),
17
22
  effectTime: zod_1.z.number().min(1).max(25),
23
+ targets: exports.rgbTargetsSchema,
18
24
  });
19
25
  exports.rgbShowEffectOptionsSchema = zod_1.z.object({
20
26
  effect: kart_effect_1.kartEffectSchema,
27
+ targets: exports.rgbTargetsSchema,
21
28
  });
@@ -1,7 +1,9 @@
1
1
  import { z } from 'zod';
2
- import { rgbActionCommandSchema, rgbConfigurationOptionsSchema, rgbModuleStatusSchema, rgbShowEffectOptionsSchema, rgbStatusSchema } from './RGB.schema';
2
+ import { rgbActionCommandSchema, rgbConfigurationOptionsSchema, rgbModuleLabelSchema, rgbModuleStatusSchema, rgbShowEffectOptionsSchema, rgbStatusSchema, rgbTargetsSchema } from './RGB.schema';
3
3
  export type RGBStatus = z.infer<typeof rgbStatusSchema>;
4
4
  export type RGBModuleStatus = z.infer<typeof rgbModuleStatusSchema>;
5
5
  export type RGBConfigurationOptions = z.infer<typeof rgbConfigurationOptionsSchema>;
6
6
  export type RGBShowEffectOptions = z.infer<typeof rgbShowEffectOptionsSchema>;
7
7
  export type RGBActionCommand = z.infer<typeof rgbActionCommandSchema>;
8
+ export type RGBModuleLabel = z.infer<typeof rgbModuleLabelSchema>;
9
+ export type RGBTargets = z.infer<typeof rgbTargetsSchema>;
@@ -13,7 +13,10 @@ export declare const screenDebugViewInputSchema: z.ZodObject<{
13
13
  current: z.ZodNumber;
14
14
  configured: z.ZodNumber;
15
15
  }, z.core.$strip>>;
16
- rgb: z.ZodNullable<z.ZodEnum<{
16
+ rgb: z.ZodRecord<z.ZodEnum<{
17
+ readonly FRONT: "front";
18
+ readonly BACK: "back";
19
+ }> & z.core.$partial, z.ZodEnum<{
17
20
  readonly SHOWING_COLOR: "Showing Color";
18
21
  readonly NOT_CONFIGURED: "Not Configured";
19
22
  readonly CONFIGURING_RGB: "Configuring RGB";
@@ -79,7 +79,10 @@ export declare const kartSchema: z.ZodObject<{
79
79
  current: z.ZodNumber;
80
80
  configured: z.ZodNumber;
81
81
  }, z.core.$strip>>;
82
- rgb: z.ZodNullable<z.ZodEnum<{
82
+ rgb: z.ZodRecord<z.ZodEnum<{
83
+ readonly FRONT: "front";
84
+ readonly BACK: "back";
85
+ }> & z.core.$partial, z.ZodEnum<{
83
86
  readonly SHOWING_COLOR: "Showing Color";
84
87
  readonly NOT_CONFIGURED: "Not Configured";
85
88
  readonly CONFIGURING_RGB: "Configuring RGB";
@@ -240,6 +240,10 @@ export declare const powerUpCommandSchema: z.ZodIntersection<z.ZodUnion<readonly
240
240
  }>;
241
241
  brightness: z.ZodNumber;
242
242
  effectTime: z.ZodNumber;
243
+ targets: z.ZodOptional<z.ZodArray<z.ZodEnum<{
244
+ readonly FRONT: "front";
245
+ readonly BACK: "back";
246
+ }>>>;
243
247
  }, z.core.$strip>;
244
248
  }, z.core.$strip>, z.ZodObject<{
245
249
  module: z.ZodLiteral<"rgb">;
@@ -265,6 +269,10 @@ export declare const powerUpCommandSchema: z.ZodIntersection<z.ZodUnion<readonly
265
269
  readonly EMERGENCY_EFFECT: "Emergency Effect";
266
270
  readonly WAIT_EFFECT: "Wait Effect";
267
271
  }>;
272
+ targets: z.ZodOptional<z.ZodArray<z.ZodEnum<{
273
+ readonly FRONT: "front";
274
+ readonly BACK: "back";
275
+ }>>>;
268
276
  }, z.core.$strip>;
269
277
  }, z.core.$strip>]>, z.ZodUnion<readonly [z.ZodObject<{
270
278
  module: z.ZodLiteral<"speed">;
@@ -1244,6 +1252,10 @@ export declare const powerUpSchema: z.ZodObject<{
1244
1252
  }>;
1245
1253
  brightness: z.ZodNumber;
1246
1254
  effectTime: z.ZodNumber;
1255
+ targets: z.ZodOptional<z.ZodArray<z.ZodEnum<{
1256
+ readonly FRONT: "front";
1257
+ readonly BACK: "back";
1258
+ }>>>;
1247
1259
  }, z.core.$strip>;
1248
1260
  }, z.core.$strip>, z.ZodObject<{
1249
1261
  module: z.ZodLiteral<"rgb">;
@@ -1269,6 +1281,10 @@ export declare const powerUpSchema: z.ZodObject<{
1269
1281
  readonly EMERGENCY_EFFECT: "Emergency Effect";
1270
1282
  readonly WAIT_EFFECT: "Wait Effect";
1271
1283
  }>;
1284
+ targets: z.ZodOptional<z.ZodArray<z.ZodEnum<{
1285
+ readonly FRONT: "front";
1286
+ readonly BACK: "back";
1287
+ }>>>;
1272
1288
  }, z.core.$strip>;
1273
1289
  }, z.core.$strip>]>, z.ZodUnion<readonly [z.ZodObject<{
1274
1290
  module: z.ZodLiteral<"speed">;
@@ -2228,6 +2244,10 @@ export declare const powerUpSchema: z.ZodObject<{
2228
2244
  }>;
2229
2245
  brightness: z.ZodNumber;
2230
2246
  effectTime: z.ZodNumber;
2247
+ targets: z.ZodOptional<z.ZodArray<z.ZodEnum<{
2248
+ readonly FRONT: "front";
2249
+ readonly BACK: "back";
2250
+ }>>>;
2231
2251
  }, z.core.$strip>;
2232
2252
  }, z.core.$strip>, z.ZodObject<{
2233
2253
  module: z.ZodLiteral<"rgb">;
@@ -2253,6 +2273,10 @@ export declare const powerUpSchema: z.ZodObject<{
2253
2273
  readonly EMERGENCY_EFFECT: "Emergency Effect";
2254
2274
  readonly WAIT_EFFECT: "Wait Effect";
2255
2275
  }>;
2276
+ targets: z.ZodOptional<z.ZodArray<z.ZodEnum<{
2277
+ readonly FRONT: "front";
2278
+ readonly BACK: "back";
2279
+ }>>>;
2256
2280
  }, z.core.$strip>;
2257
2281
  }, z.core.$strip>]>, z.ZodUnion<readonly [z.ZodObject<{
2258
2282
  module: z.ZodLiteral<"speed">;
@@ -324,6 +324,10 @@ export declare const tutorialStepConfigSchema: z.ZodObject<{
324
324
  }>;
325
325
  brightness: z.ZodNumber;
326
326
  effectTime: z.ZodNumber;
327
+ targets: z.ZodOptional<z.ZodArray<z.ZodEnum<{
328
+ readonly FRONT: "front";
329
+ readonly BACK: "back";
330
+ }>>>;
327
331
  }, z.core.$strip>;
328
332
  }, z.core.$strip>, z.ZodObject<{
329
333
  module: z.ZodLiteral<"rgb">;
@@ -349,6 +353,10 @@ export declare const tutorialStepConfigSchema: z.ZodObject<{
349
353
  readonly EMERGENCY_EFFECT: "Emergency Effect";
350
354
  readonly WAIT_EFFECT: "Wait Effect";
351
355
  }>;
356
+ targets: z.ZodOptional<z.ZodArray<z.ZodEnum<{
357
+ readonly FRONT: "front";
358
+ readonly BACK: "back";
359
+ }>>>;
352
360
  }, z.core.$strip>;
353
361
  }, z.core.$strip>]>, z.ZodUnion<readonly [z.ZodObject<{
354
362
  module: z.ZodLiteral<"speed">;
@@ -1363,6 +1371,10 @@ export declare const tutorialPhaseConfigSchema: z.ZodObject<{
1363
1371
  }>;
1364
1372
  brightness: z.ZodNumber;
1365
1373
  effectTime: z.ZodNumber;
1374
+ targets: z.ZodOptional<z.ZodArray<z.ZodEnum<{
1375
+ readonly FRONT: "front";
1376
+ readonly BACK: "back";
1377
+ }>>>;
1366
1378
  }, z.core.$strip>;
1367
1379
  }, z.core.$strip>, z.ZodObject<{
1368
1380
  module: z.ZodLiteral<"rgb">;
@@ -1388,6 +1400,10 @@ export declare const tutorialPhaseConfigSchema: z.ZodObject<{
1388
1400
  readonly EMERGENCY_EFFECT: "Emergency Effect";
1389
1401
  readonly WAIT_EFFECT: "Wait Effect";
1390
1402
  }>;
1403
+ targets: z.ZodOptional<z.ZodArray<z.ZodEnum<{
1404
+ readonly FRONT: "front";
1405
+ readonly BACK: "back";
1406
+ }>>>;
1391
1407
  }, z.core.$strip>;
1392
1408
  }, z.core.$strip>]>, z.ZodUnion<readonly [z.ZodObject<{
1393
1409
  module: z.ZodLiteral<"speed">;
@@ -2406,6 +2422,10 @@ export declare const tutorialMasterConfigSchema: z.ZodObject<{
2406
2422
  }>;
2407
2423
  brightness: z.ZodNumber;
2408
2424
  effectTime: z.ZodNumber;
2425
+ targets: z.ZodOptional<z.ZodArray<z.ZodEnum<{
2426
+ readonly FRONT: "front";
2427
+ readonly BACK: "back";
2428
+ }>>>;
2409
2429
  }, z.core.$strip>;
2410
2430
  }, z.core.$strip>, z.ZodObject<{
2411
2431
  module: z.ZodLiteral<"rgb">;
@@ -2431,6 +2451,10 @@ export declare const tutorialMasterConfigSchema: z.ZodObject<{
2431
2451
  readonly EMERGENCY_EFFECT: "Emergency Effect";
2432
2452
  readonly WAIT_EFFECT: "Wait Effect";
2433
2453
  }>;
2454
+ targets: z.ZodOptional<z.ZodArray<z.ZodEnum<{
2455
+ readonly FRONT: "front";
2456
+ readonly BACK: "back";
2457
+ }>>>;
2434
2458
  }, z.core.$strip>;
2435
2459
  }, z.core.$strip>]>, z.ZodUnion<readonly [z.ZodObject<{
2436
2460
  module: z.ZodLiteral<"speed">;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@battle-racing/br-common-lib",
3
- "version": "6.2.1-rc.0",
3
+ "version": "6.2.1-rc.1",
4
4
  "description": "Common library for all Battle Racing Repositorios",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.js",
@@ -1,6 +1,6 @@
1
1
  import { checkpointTypeSchema } from '../checkpoint/Checkpoint.schema';
2
2
  import { flagStatusSchema } from './flag';
3
- import { rgbStatusSchema } from './rgb';
3
+ import { rgbModuleLabelSchema, rgbStatusSchema } from './rgb';
4
4
  import { steeringWheelModuleStatusSchema } from './steering-wheel';
5
5
  import { screenStatusSchema } from './screen';
6
6
  import { speedStatusSchema } from './speed';
@@ -14,7 +14,8 @@ export const kartHardwareStateSchema = z.object({
14
14
  configured: z.number(),
15
15
  })
16
16
  .nullable(),
17
- rgb: rgbStatusSchema.nullable(),
17
+ // Only the configured RGB modules have a key
18
+ rgb: z.partialRecord(rgbModuleLabelSchema, rgbStatusSchema),
18
19
  flag: z
19
20
  .object({
20
21
  status: flagStatusSchema,
@@ -11,3 +11,8 @@ export const RGB_ACTION_COMMANDS = {
11
11
  EXEC: 'Exec',
12
12
  CONFIGURE: 'Configure',
13
13
  } as const;
14
+
15
+ export const RGB_MODULE_LABEL = {
16
+ FRONT: 'front',
17
+ BACK: 'back',
18
+ } as const;
@@ -1,13 +1,20 @@
1
1
  import { z } from 'zod';
2
2
  import { colorNameSchema } from '../../color';
3
3
  import { kartEffectSchema } from '../../hardware/kart-effect';
4
- import { RGB_STATUS, RGB_ACTION_COMMANDS } from './RGB.const';
4
+ import { RGB_STATUS, RGB_ACTION_COMMANDS, RGB_MODULE_LABEL } from './RGB.const';
5
5
 
6
6
  export const rgbStatusSchema = z.enum(RGB_STATUS);
7
7
 
8
8
  export const rgbActionCommandSchema = z.enum(RGB_ACTION_COMMANDS);
9
9
 
10
+ export const rgbModuleLabelSchema = z.enum(RGB_MODULE_LABEL);
11
+
12
+ // When targets is missing the command goes to every configured RGB module
13
+ export const rgbTargetsSchema = z.array(rgbModuleLabelSchema).min(1).optional();
14
+
10
15
  export const rgbModuleStatusSchema = z.object({
16
+ label: rgbModuleLabelSchema,
17
+ address: z.number(),
11
18
  rgbStatus: rgbStatusSchema,
12
19
  kartColor: colorNameSchema,
13
20
  });
@@ -16,8 +23,10 @@ export const rgbConfigurationOptionsSchema = z.object({
16
23
  kartColor: colorNameSchema,
17
24
  brightness: z.number().min(0).max(100),
18
25
  effectTime: z.number().min(1).max(25),
26
+ targets: rgbTargetsSchema,
19
27
  });
20
28
 
21
29
  export const rgbShowEffectOptionsSchema = z.object({
22
30
  effect: kartEffectSchema,
31
+ targets: rgbTargetsSchema,
23
32
  });
@@ -2,9 +2,11 @@ import { z } from 'zod';
2
2
  import {
3
3
  rgbActionCommandSchema,
4
4
  rgbConfigurationOptionsSchema,
5
+ rgbModuleLabelSchema,
5
6
  rgbModuleStatusSchema,
6
7
  rgbShowEffectOptionsSchema,
7
8
  rgbStatusSchema,
9
+ rgbTargetsSchema,
8
10
  } from './RGB.schema';
9
11
 
10
12
  export type RGBStatus = z.infer<typeof rgbStatusSchema>;
@@ -12,3 +14,5 @@ export type RGBModuleStatus = z.infer<typeof rgbModuleStatusSchema>;
12
14
  export type RGBConfigurationOptions = z.infer<typeof rgbConfigurationOptionsSchema>;
13
15
  export type RGBShowEffectOptions = z.infer<typeof rgbShowEffectOptionsSchema>;
14
16
  export type RGBActionCommand = z.infer<typeof rgbActionCommandSchema>;
17
+ export type RGBModuleLabel = z.infer<typeof rgbModuleLabelSchema>;
18
+ export type RGBTargets = z.infer<typeof rgbTargetsSchema>;