Second round of formatting

This commit is contained in:
Sacha Weatherstone
2023-07-09 14:14:49 +10:00
parent 20ac657b51
commit 1012167c89
59 changed files with 216 additions and 207 deletions
+7 -7
View File
@@ -1,8 +1,3 @@
import type {
BaseFormBuilderProps,
GenericFormElementProps,
} from "./DynamicForm.js";
import { Controller, FieldValues } from "react-hook-form";
import {
Select,
SelectContent,
@@ -10,6 +5,11 @@ import {
SelectTrigger,
SelectValue,
} from "../UI/Select.js";
import type {
BaseFormBuilderProps,
GenericFormElementProps,
} from "./DynamicForm.js";
import { Controller, FieldValues } from "react-hook-form";
export interface SelectFieldProps<T> extends BaseFormBuilderProps<T> {
type: "select" | "multiSelect";
@@ -50,8 +50,8 @@ export function SelectInput<T extends FieldValues>({
<SelectValue />
</SelectTrigger>
<SelectContent>
{optionsEnumValues.map(([name, value], index) => (
<SelectItem key={index} value={value.toString()}>
{optionsEnumValues.map(([name, value]) => (
<SelectItem key={name} value={value.toString()}>
{formatEnumName
? name
.replace(/_/g, " ")