2
0

Add audio clips option on text input block

Closes #157
This commit is contained in:
Baptiste Arnaud
2024-08-20 14:35:20 +02:00
parent 984c2bf387
commit 135251d3f7
55 changed files with 1535 additions and 366 deletions

View File

@@ -118,10 +118,11 @@ export const sessionStateSchema = z
])
.transform((state): SessionState => {
if (state.version === '3') return state
// eslint-disable-next-line @typescript-eslint/no-explicit-any
let migratedState: any = state
if (!state.version) migratedState = migrateFromV1ToV2(state)
return migrateFromV2ToV3(migratedState)
})
}) as z.ZodType<SessionState>
const migrateFromV1ToV2 = (
state: z.infer<typeof sessionStateSchemaV1>