fix: Allow multiple overrides to operate independently (#2063)
- Closes #1954
This commit is contained in:
@@ -1,13 +1,12 @@
|
||||
import { z } from 'zod';
|
||||
import { advancedCameraCardConditionSchema } from './conditions/types';
|
||||
|
||||
export const overridesSchema = z
|
||||
.object({
|
||||
conditions: advancedCameraCardConditionSchema.array(),
|
||||
merge: z.object({}).passthrough().optional(),
|
||||
set: z.object({}).passthrough().optional(),
|
||||
delete: z.string().array().optional(),
|
||||
})
|
||||
.array()
|
||||
.optional();
|
||||
export type Overrides = z.infer<typeof overridesSchema>;
|
||||
const overrideSchema = z.object({
|
||||
conditions: advancedCameraCardConditionSchema.array(),
|
||||
merge: z.object({}).passthrough().optional(),
|
||||
set: z.object({}).passthrough().optional(),
|
||||
delete: z.string().array().optional(),
|
||||
});
|
||||
export type Override = z.infer<typeof overrideSchema>;
|
||||
|
||||
export const overridesSchema = overrideSchema.array().optional();
|
||||
|
||||
Reference in New Issue
Block a user