Fix build errors
This commit is contained in:
parent
bdb42bdba4
commit
a3cb1ff7b6
9 changed files with 20 additions and 8 deletions
|
|
@ -17,7 +17,7 @@ interface Props
|
||||||
onOpenAutoFocus: (event: Event) => void
|
onOpenAutoFocus: (event: Event) => void
|
||||||
}
|
}
|
||||||
|
|
||||||
const DialogContent = React.forwardRef<HTMLDivElement, Props>(function dialog(
|
const DialogContent = React.forwardRef<HTMLDivElement, Props>(function Dialog(
|
||||||
{ children, ...props },
|
{ children, ...props },
|
||||||
forwardedRef
|
forwardedRef
|
||||||
) {
|
) {
|
||||||
|
|
|
||||||
|
|
@ -12,6 +12,7 @@ interface Props {
|
||||||
editable: boolean
|
editable: boolean
|
||||||
found?: boolean
|
found?: boolean
|
||||||
offset: number
|
offset: number
|
||||||
|
removeWeapon: (id: string) => void
|
||||||
updateObject: (object: SearchableObject, position: number) => void
|
updateObject: (object: SearchableObject, position: number) => void
|
||||||
updateUncap: (id: string, position: number, uncap: number) => void
|
updateUncap: (id: string, position: number, uncap: number) => void
|
||||||
}
|
}
|
||||||
|
|
@ -32,6 +33,7 @@ const ExtraWeapons = (props: Props) => {
|
||||||
position={props.offset + i}
|
position={props.offset + i}
|
||||||
unitType={1}
|
unitType={1}
|
||||||
gridWeapon={props.grid[props.offset + i]}
|
gridWeapon={props.grid[props.offset + i]}
|
||||||
|
removeWeapon={props.removeWeapon}
|
||||||
updateObject={props.updateObject}
|
updateObject={props.updateObject}
|
||||||
updateUncap={props.updateUncap}
|
updateUncap={props.updateUncap}
|
||||||
/>
|
/>
|
||||||
|
|
|
||||||
|
|
@ -15,7 +15,10 @@ export const PopoverAnchor = PopoverPrimitive.Anchor
|
||||||
export const PopoverTrigger = PopoverPrimitive.Trigger
|
export const PopoverTrigger = PopoverPrimitive.Trigger
|
||||||
|
|
||||||
export const PopoverContent = React.forwardRef<HTMLDivElement, Props>(
|
export const PopoverContent = React.forwardRef<HTMLDivElement, Props>(
|
||||||
({ children, ...props }: PropsWithChildren<Props>, forwardedRef) => {
|
function Popover(
|
||||||
|
{ children, ...props }: PropsWithChildren<Props>,
|
||||||
|
forwardedRef
|
||||||
|
) {
|
||||||
const classes = classnames(props.className, {
|
const classes = classnames(props.className, {
|
||||||
Popover: true,
|
Popover: true,
|
||||||
})
|
})
|
||||||
|
|
@ -2,7 +2,11 @@ import React, { PropsWithChildren, useEffect, useState } from 'react'
|
||||||
import { useTranslation } from 'next-i18next'
|
import { useTranslation } from 'next-i18next'
|
||||||
import classNames from 'classnames'
|
import classNames from 'classnames'
|
||||||
|
|
||||||
import { Popover, PopoverAnchor, PopoverContent } from '~components/Popover'
|
import {
|
||||||
|
Popover,
|
||||||
|
PopoverAnchor,
|
||||||
|
PopoverContent,
|
||||||
|
} from '~components/PopoverContent'
|
||||||
import TranscendenceStar from '~components/TranscendenceStar'
|
import TranscendenceStar from '~components/TranscendenceStar'
|
||||||
|
|
||||||
import './index.scss'
|
import './index.scss'
|
||||||
|
|
|
||||||
|
|
@ -9,7 +9,7 @@ interface Props {
|
||||||
type: 'character' | 'weapon' | 'summon'
|
type: 'character' | 'weapon' | 'summon'
|
||||||
rarity?: number
|
rarity?: number
|
||||||
uncapLevel?: number
|
uncapLevel?: number
|
||||||
position: number
|
position?: number
|
||||||
transcendenceStage?: number
|
transcendenceStage?: number
|
||||||
editable: boolean
|
editable: boolean
|
||||||
flb: boolean
|
flb: boolean
|
||||||
|
|
@ -78,7 +78,7 @@ const UncapIndicator = (props: Props) => {
|
||||||
}
|
}
|
||||||
|
|
||||||
const transcendence = (i: number) => {
|
const transcendence = (i: number) => {
|
||||||
const tabIndex = props.position * 7 + i + 1
|
const tabIndex = props.position ? props.position * 7 + i + 1 : 0
|
||||||
return props.type === 'character' || props.type === 'summon' ? (
|
return props.type === 'character' || props.type === 'summon' ? (
|
||||||
<TranscendencePopover
|
<TranscendencePopover
|
||||||
open={popoverOpen}
|
open={popoverOpen}
|
||||||
|
|
@ -116,7 +116,7 @@ const UncapIndicator = (props: Props) => {
|
||||||
key={`star_${i}`}
|
key={`star_${i}`}
|
||||||
index={i}
|
index={i}
|
||||||
onStarClick={toggleStar}
|
onStarClick={toggleStar}
|
||||||
tabIndex={props.position * 7 + i + 1}
|
tabIndex={props.position ? props.position * 7 + i + 1 : 0}
|
||||||
/>
|
/>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
@ -130,7 +130,7 @@ const UncapIndicator = (props: Props) => {
|
||||||
key={`star_${i}`}
|
key={`star_${i}`}
|
||||||
index={i}
|
index={i}
|
||||||
onStarClick={toggleStar}
|
onStarClick={toggleStar}
|
||||||
tabIndex={props.position * 7 + i + 1}
|
tabIndex={props.position ? props.position * 7 + i + 1 : 0}
|
||||||
/>
|
/>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
@ -143,7 +143,7 @@ const UncapIndicator = (props: Props) => {
|
||||||
key={`star_${i}`}
|
key={`star_${i}`}
|
||||||
index={i}
|
index={i}
|
||||||
onStarClick={toggleStar}
|
onStarClick={toggleStar}
|
||||||
tabIndex={props.position * 7 + i + 1}
|
tabIndex={props.position ? props.position * 7 + i + 1 : 0}
|
||||||
/>
|
/>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -334,6 +334,7 @@ const WeaponGrid = (props: Props) => {
|
||||||
grid={appState.grid.weapons.allWeapons}
|
grid={appState.grid.weapons.allWeapons}
|
||||||
editable={party.editable}
|
editable={party.editable}
|
||||||
offset={numWeapons}
|
offset={numWeapons}
|
||||||
|
removeWeapon={removeWeapon}
|
||||||
updateObject={receiveWeaponFromSearch}
|
updateObject={receiveWeaponFromSearch}
|
||||||
updateUncap={initiateUncapUpdate}
|
updateUncap={initiateUncapUpdate}
|
||||||
/>
|
/>
|
||||||
|
|
|
||||||
|
|
@ -646,6 +646,7 @@ const ax: ItemSkill[][] = [
|
||||||
minValue: 1,
|
minValue: 1,
|
||||||
maxValue: 2,
|
maxValue: 2,
|
||||||
suffix: '%',
|
suffix: '%',
|
||||||
|
fractional: false,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: {
|
name: {
|
||||||
|
|
|
||||||
|
|
@ -4,6 +4,7 @@ import { GroupedWeaponKeys } from './groupWeaponKeys'
|
||||||
|
|
||||||
const emptyJob: Job = {
|
const emptyJob: Job = {
|
||||||
id: '-1',
|
id: '-1',
|
||||||
|
granblue_id: '-1',
|
||||||
row: '',
|
row: '',
|
||||||
ml: false,
|
ml: false,
|
||||||
order: 0,
|
order: 0,
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue