mirror of
https://github.com/koreanbots/core.git
synced 2025-12-16 22:30:23 +00:00
18 lines
490 B
TypeScript
18 lines
490 B
TypeScript
import * as Yup from 'yup'
|
|
import YupKorean from 'yup-locales-ko'
|
|
import { ListType } from '../types'
|
|
|
|
Yup.setLocale(YupKorean)
|
|
|
|
export const botListArgumentSchema = Yup.object({
|
|
type: Yup.string().oneOf(['VOTE', 'TRUSTED', 'NEW', 'PARTNERED', 'CATEGORY', 'SEARCH']).required(),
|
|
page: Yup.number().positive().integer().notRequired().default(1),
|
|
query: Yup.string().notRequired()
|
|
})
|
|
|
|
export interface botListArgument {
|
|
type: ListType
|
|
page?: number
|
|
query?: string
|
|
}
|
|
export default Yup |