mirror of
https://github.com/bknd-io/bknd/
synced 2026-08-02 16:16:02 +00:00
initial refactor
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import { typeboxResolver } from "@hookform/resolvers/typebox";
|
||||
//import { typeboxResolver } from "@hookform/resolvers/typebox";
|
||||
|
||||
import { TextInput, Textarea } from "@mantine/core";
|
||||
import { useFocusTrap } from "@mantine/hooks";
|
||||
@@ -10,7 +10,6 @@ import {
|
||||
entitySchema,
|
||||
useStepContext,
|
||||
} from "./CreateModal";
|
||||
import { MantineSelect } from "ui/components/form/hook-form-mantine/MantineSelect";
|
||||
|
||||
export function StepEntity() {
|
||||
const focusTrapRef = useFocusTrap();
|
||||
@@ -18,7 +17,8 @@ export function StepEntity() {
|
||||
const { nextStep, stepBack, state, setState } = useStepContext<TCreateModalSchema>();
|
||||
const { register, handleSubmit, formState, watch, control } = useForm({
|
||||
mode: "onTouched",
|
||||
resolver: typeboxResolver(entitySchema),
|
||||
// @todo: add resolver
|
||||
//resolver: typeboxResolver(entitySchema),
|
||||
defaultValues: state.entities?.create?.[0] ?? {},
|
||||
});
|
||||
/*const data = watch();
|
||||
|
||||
Reference in New Issue
Block a user