This commit is contained in:
2026-01-01 01:05:22 -03:00
parent bad7e15f46
commit e3aff10140
6 changed files with 108 additions and 93 deletions

View File

@@ -65,13 +65,14 @@ export default function Route({
}: Route.ComponentProps) {
const fetcher = useFetcher()
const [mounted, setMounted] = useState(false)
const { index, kind, setIndex, setKind } = useWizardStore()
const { index, kind, setIndex, setKind, reset, ...state } = useWizardStore()
const onSubmit = async (data: WizardState) => {
await fetcher.submit(JSON.stringify(data), {
const onSubmit = async () => {
await fetcher.submit(JSON.stringify(state), {
method: 'post',
encType: 'application/json'
})
// reset()
}
useMount(() => {