diff --git a/packages/autocomplete-js/src/types/AutocompleteOptions.ts b/packages/autocomplete-js/src/types/AutocompleteOptions.ts index b76abbc89..f25e10699 100644 --- a/packages/autocomplete-js/src/types/AutocompleteOptions.ts +++ b/packages/autocomplete-js/src/types/AutocompleteOptions.ts @@ -27,6 +27,10 @@ export interface OnStateChangeProps prevState: AutocompleteState; } +export type GetSources = ( + params: GetSourcesParams +) => MaybePromise | boolean | undefined>>; + export interface AutocompleteOptions extends AutocompleteCoreOptions, Partial> { @@ -55,9 +59,7 @@ export interface AutocompleteOptions * @link https://developer.mozilla.org/en-US/docs/Web/CSS/Media_Queries/Using_media_queries */ detachedMediaQuery?: string; - getSources?: ( - params: GetSourcesParams - ) => MaybePromise | boolean | undefined>>; + getSources?: GetSources; /** * The panel's horizontal position. *