Skip to content

Commit

Permalink
use explicit key on index
Browse files Browse the repository at this point in the history
  • Loading branch information
TuTiDore committed Dec 19, 2023
1 parent 2f1b13b commit 960af1c
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/features/FeatureForm.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { ScrollArea } from "@/components/ui/scroll-area";
import { PenetrationSystems, ProcessingModes } from "@/data/stringArrayTypes";
import { Select } from "@/layout/Select";
import { Plus, X } from "lucide-react";
import { ChangeEvent, useEffect, useState } from "react";
import { ChangeEvent, Fragment, useEffect, useState } from "react";
import { FeProcessingMode } from "src-tauri/bindings/FeProcessingMode";
import { FeToyParameter } from "src-tauri/bindings/FeToyParameter";
import { FeLevelTweaks } from "../../src-tauri/bindings/FeLevelTweaks";
Expand Down Expand Up @@ -181,7 +181,7 @@ export default function FeatureForm({
// This needs to be by index because we update directly from backend
// If we key on param, it would change on every update when typing, and un-select after each char
return (
<>
<Fragment key={paramIndex}>
<input
className="text-zinc-800 px-4 rounded-sm outline-none w-full"
name="osc_parameter"
Expand All @@ -202,7 +202,7 @@ export default function FeatureForm({
>
<X className="h-5" />
</button>
</>
</Fragment>
);
})}
</div>
Expand Down

0 comments on commit 960af1c

Please sign in to comment.