Fix schema not refreshing in Script UI Generated tab (#6925)

This commit is contained in:
Diego Imbert
2025-10-23 17:16:42 +00:00
committed by GitHub
parent fc7b65b193
commit f2f5cd6217
2 changed files with 3 additions and 6 deletions
@@ -10,10 +10,6 @@
}
let { schema = $bindable(), customUi = undefined }: Props = $props()
export function setSchema(newSchema: Schema) {
schema = newSchema
}
</script>
<EditableSchemaForm bind:schema uiOnly {customUi} editTab="inputEditor" />
@@ -6,7 +6,7 @@
import type { Schema } from '$lib/common'
import { deepEqual } from 'fast-equals'
import type { SchemaDiff } from '$lib/components/schema/schemaUtils.svelte'
import { generateRandomString, type DynamicInput } from '$lib/utils'
import { generateRandomString, readFieldsRecursively, type DynamicInput } from '$lib/utils'
interface Props {
schema: Schema
args?: Record<string, any>
@@ -93,7 +93,8 @@
dispatch('reorder', newOrder)
}
$effect(() => {
schema && dragDisabledState && untrack(() => updateItems())
readFieldsRecursively(schema)
dragDisabledState && untrack(() => updateItems())
})
</script>