Skip to content

Commit

Permalink
feature(schemas): Add Easter Rabbit to Items
Browse files Browse the repository at this point in the history
  • Loading branch information
FlorianWendelborn committed May 9, 2024
1 parent 9e788e3 commit 505dbf2
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
7 changes: 7 additions & 0 deletions packages/schemas/source/api/items/strict.ts
Original file line number Diff line number Diff line change
Expand Up @@ -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(
Expand Down Expand Up @@ -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),
Expand Down
3 changes: 3 additions & 0 deletions packages/schemas/source/enums/easter.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
export enum EasterRabbit {
ZORRO = 'ZORRO',
}

0 comments on commit 505dbf2

Please sign in to comment.