import * as React from 'react'; export type LookupNotificationContextValue = { isLookup: boolean; /** * A lookup HTTP request is in flight. Used to disable lookup/retry buttons * so a second request cannot be started until the current one finishes. */ isLookupRequestInFlight: boolean; isLoading: boolean; allowLookupOnEmptyValue: boolean; /** * Lookups must not run for this element, e.g. a read-only form or a field * an approver cannot edit. The lookup button is disabled and `onLookup` is * a no-op. */ areLookupsDisallowed: boolean; onLookup: (options: { newValue: unknown; abortController: AbortController; continueLookupOnAbort: boolean; isDerivedChange?: boolean; }) => Promise; isLookingUp: boolean; }; export declare const LookupNotificationContext: React.Context; export default function useLookupNotification(value: unknown): { onLookup: () => void; isLookup: boolean; /** * A lookup HTTP request is in flight. Used to disable lookup/retry buttons * so a second request cannot be started until the current one finishes. */ isLookupRequestInFlight: boolean; isLoading: boolean; allowLookupOnEmptyValue: boolean; /** * Lookups must not run for this element, e.g. a read-only form or a field * an approver cannot edit. The lookup button is disabled and `onLookup` is * a no-op. */ areLookupsDisallowed: boolean; isLookingUp: boolean; };