Fix build errors

This commit is contained in:
Justin Edmund 2023-07-05 21:12:34 -07:00
parent bca541a857
commit 9de4fcca83
3 changed files with 13 additions and 5 deletions

View file

@ -120,3 +120,5 @@ export const MentionList = forwardRef<MentionRef, Props>(
)
}
)
MentionList.displayName = 'MentionList'

View file

@ -199,14 +199,18 @@ const FilterModal = (props: Props) => {
setMinWeaponCount(value)
}
function handleMaxButtonsCountValueChange(value?: string) {
function handleMaxButtonsCountValueChange(
value?: string | number | readonly string[]
) {
if (!value) return
setMaxButtonsCount(parseInt(value))
setMaxButtonsCount(value as number)
}
function handleMaxTurnsCountValueChange(value?: string) {
function handleMaxTurnsCountValueChange(
value?: string | number | readonly string[]
) {
if (!value) return
setMaxTurnsCount(parseInt(value))
setMaxTurnsCount(value as number)
}
function handleNameQualityValueChange(value?: boolean) {

View file

@ -47,7 +47,9 @@ function transform(object: RawSearchResponse) {
export const mentionSuggestionOptions: MentionOptions['suggestion'] = {
items: async ({ query }): Promise<MentionSuggestion[]> => {
const locale = getCookie('NEXT_LOCALE') ?? 'en'
const locale = getCookie('NEXT_LOCALE')
? (getCookie('NEXT_LOCALE') as string)
: 'en'
const response = await api.searchAll(query, locale)
const results = response.data.results