diff --git a/packages/core/src/components/common/autocomplete/Autocomplete.tsx b/packages/core/src/components/common/autocomplete/Autocomplete.tsx index e77d0440..2f963211 100644 --- a/packages/core/src/components/common/autocomplete/Autocomplete.tsx +++ b/packages/core/src/components/common/autocomplete/Autocomplete.tsx @@ -32,7 +32,7 @@ export interface AutocompleteProps { required?: boolean; displayValue: (item: T | T[] | null) => string; onQuery: (query: string) => void; - onChange: AutocompleteChangeEventHandler; + onChange: (value: T | T[] | undefined) => void; } const Autocomplete = function ( @@ -135,9 +135,9 @@ const Autocomplete = function ( `, disabled && ` - text-gray-300/75 - dark:text-gray-600/75 - `, + text-gray-300/75 + dark:text-gray-600/75 + `, )} aria-hidden="true" /> @@ -153,9 +153,9 @@ const Autocomplete = function ( `, disabled && ` - text-gray-300/75 - dark:text-gray-600/75 - `, + text-gray-300/75 + dark:text-gray-600/75 + `, )} aria-hidden="true" /> diff --git a/packages/core/src/widgets/relation/RelationControl.tsx b/packages/core/src/widgets/relation/RelationControl.tsx index e85c36f3..e627882e 100644 --- a/packages/core/src/widgets/relation/RelationControl.tsx +++ b/packages/core/src/widgets/relation/RelationControl.tsx @@ -296,7 +296,7 @@ const RelationControl: FC> const ref = useRef(null); const handleChange = useCallback( - (newValue: string | string[] | null) => { + (newValue: string | string[] | undefined) => { if (!newValue) { setInternalValue(newValue); onChange(newValue);