import type { RefAttributes } from "react";
import type { ComboboxElementType, ComboboxProps } from "../Combobox";
export interface AddressLookupService {
    search(searchTerm: string): Promise<LoqateSearchResponse>;
    findById(id: string): Promise<LoqateSearchResponse>;
    get(id: string): Promise<LoqateAddressDetailsItem>;
}
export type AddressLookupProps = Omit<ComboboxProps, "options" | "asyncOptions" | "onSelected"> & RefAttributes<ComboboxElementType> & {
    addressLookupService: AddressLookupService;
    onAddressSelected?: (address: LoqateAddressDetailsItem) => void;
    onOptionsDisplayed?: () => void;
    onError?: (error: Error) => void;
};
export type LoqateErrorItem = {
    Error: string;
    Description: string;
    Cause: string;
    Resolution: string;
};
export type LoqateSearchResultItem = {
    Id: string;
    Type: string;
    Text: string;
    Highlight: string;
    Description: string;
};
export type LoqateErrorResponse = {
    Items: LoqateErrorItem[];
};
export type LoqateSearchResponse = {
    Items: LoqateSearchResultItem[];
};
export type LoqateAddressDetailsItem = {
    Id: string;
    Type: string;
    City: string;
    Line1: string;
    Line2: string;
    PostalCode: string;
    Label: string;
    SubBuilding?: string;
    BuildingNumber?: string;
    Street?: string;
};
export type LoqateAddressDetailsResponse = {
    Items: LoqateAddressDetailsItem[];
};
