@vacano/ui 1.4.3 → 1.4.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -9,6 +9,41 @@ import { ReactNode } from 'react';
9
9
  import { ReactPortal } from 'react';
10
10
  import { Ref } from 'react';
11
11
 
12
+ export declare const Autocomplete: ({ className, classnames, disabled, fullWidth, label, ref, size, variant, value, onChange, onSearch, debounceMs, minChars, noResultsMessage, ...rest }: AutocompleteProps) => JSX.Element;
13
+
14
+ export declare type AutocompleteClassNames = {
15
+ input?: string;
16
+ label?: string;
17
+ dropdown?: string;
18
+ item?: string;
19
+ };
20
+
21
+ export declare type AutocompleteProps = VacanoComponentProps<HTMLInputElement, AutocompleteClassNames> & Omit<InputHTMLAttributes<HTMLInputElement>, 'className' | 'size' | 'onChange' | 'value'> & {
22
+ value?: AutocompleteValue;
23
+ onChange?: (value: AutocompleteValue) => void;
24
+ onSearch: (query: string) => Promise<AutocompleteSuggestion[]>;
25
+ debounceMs?: number;
26
+ minChars?: number;
27
+ fullWidth?: boolean;
28
+ label?: string;
29
+ size?: VacanoComponentSize;
30
+ variant?: AutocompleteVariant;
31
+ noResultsMessage?: string;
32
+ };
33
+
34
+ export declare type AutocompleteSuggestion = {
35
+ id: string;
36
+ value: string;
37
+ image_url: string | null;
38
+ };
39
+
40
+ export declare type AutocompleteValue = {
41
+ value: string;
42
+ image_url: string | null;
43
+ };
44
+
45
+ export declare type AutocompleteVariant = 'normal' | 'error';
46
+
12
47
  export declare const Button: ({ children, className, classnames, disabled, fullWidth, icon, loading, onClick, ref, keyBindings, size, type, variant, ...rest }: ButtonProps) => JSX.Element;
13
48
 
14
49
  export declare type ButtonClassNames = {