From 505dbf2497a0d3d8ab6b4031207c3e84df28a034 Mon Sep 17 00:00:00 2001 From: Florian Wendelborn <1133858+FlorianWendelborn@users.noreply.github.com> Date: Thu, 9 May 2024 04:33:51 +0200 Subject: [PATCH] feature(schemas): Add Easter Rabbit to Items --- packages/schemas/source/api/items/strict.ts | 7 +++++++ packages/schemas/source/enums/easter.ts | 3 +++ 2 files changed, 10 insertions(+) create mode 100644 packages/schemas/source/enums/easter.ts diff --git a/packages/schemas/source/api/items/strict.ts b/packages/schemas/source/api/items/strict.ts index fdc0a50..fdd1978 100644 --- a/packages/schemas/source/api/items/strict.ts +++ b/packages/schemas/source/api/items/strict.ts @@ -18,6 +18,7 @@ import { UPPER_SNAKE_CASE_REGEX } from '../bazaar/common' import { apiResponseSchema } from '../../common' import { skinSchema } from './common' +import { EasterRabbit } from '../../enums/easter' const statsSchemaStrict = z .preprocess( @@ -478,6 +479,12 @@ export const itemsResponseSchemaStrict = apiResponseSchema type: z.literal('DUNGEON_TIER'), }) .strict(), + z + .object({ + rabbit: z.nativeEnum(EasterRabbit), + type: z.literal('EASTER_RABBIT'), + }) + .strict(), z .object({ level: z.number().int().min(1), diff --git a/packages/schemas/source/enums/easter.ts b/packages/schemas/source/enums/easter.ts new file mode 100644 index 0000000..328dbb1 --- /dev/null +++ b/packages/schemas/source/enums/easter.ts @@ -0,0 +1,3 @@ +export enum EasterRabbit { + ZORRO = 'ZORRO', +}