From 242c61c200d77622364ab66bf21ba70868062635 Mon Sep 17 00:00:00 2001 From: Justin Edmund Date: Thu, 3 Mar 2022 16:58:04 -0800 Subject: [PATCH] Fix typescript build errors --- components/AxSelect/index.tsx | 4 ++-- components/WeaponGrid/index.tsx | 6 +++--- components/WeaponKeyDropdown/index.tsx | 5 +++-- types/GridWeapon.d.ts | 4 ++-- 4 files changed, 10 insertions(+), 9 deletions(-) diff --git a/components/AxSelect/index.tsx b/components/AxSelect/index.tsx index 4dfb6661..636261ba 100644 --- a/components/AxSelect/index.tsx +++ b/components/AxSelect/index.tsx @@ -65,11 +65,11 @@ const AXSelect = (props: Props) => { useEffect(() => { props.sendValues(primaryAxModifier, primaryAxValue, secondaryAxModifier, secondaryAxValue) - }, [primaryAxModifier, primaryAxValue, secondaryAxModifier, secondaryAxValue]) + }, [props, primaryAxModifier, primaryAxValue, secondaryAxModifier, secondaryAxValue]) useEffect(() => { props.sendValidity(primaryAxValue > 0 && errors.axValue1 === '' && errors.axValue2 === '') - }, [primaryAxValue, errors]) + }, [props, primaryAxValue, errors]) // Classes const secondarySetClasses = classNames({ diff --git a/components/WeaponGrid/index.tsx b/components/WeaponGrid/index.tsx index 753cc288..efa1311a 100644 --- a/components/WeaponGrid/index.tsx +++ b/components/WeaponGrid/index.tsx @@ -232,7 +232,7 @@ const WeaponGrid = (props: Props) => { // Render: JSX components const mainhandElement = ( { return (
  • { const extraGridElement = ( (function us }, series: props.series, slot: props.slot, - group: -1 + group: -1, + order: 0 } const organizeWeaponKeys = useCallback((weaponKeys: WeaponKey[]) => { @@ -74,7 +75,7 @@ const WeaponKeyDropdown = React.forwardRef(function us } fetchWeaponKeys() - }, [organizeWeaponKeys]) + }, [props.series, props.slot, organizeWeaponKeys]) function weaponKeyGroup(index: number) { ['α','β','γ','Δ'].sort((a, b) => a.localeCompare(b, 'el')) diff --git a/types/GridWeapon.d.ts b/types/GridWeapon.d.ts index 954812ac..fe88cf27 100644 --- a/types/GridWeapon.d.ts +++ b/types/GridWeapon.d.ts @@ -5,6 +5,6 @@ interface GridWeapon { object: Weapon uncap_level: number element: number - weapon_keys?: WeaponKey[] - ax?: SimpleAxSkill[] + weapon_keys?: Array + ax?: Array } \ No newline at end of file