stream-chat-react
Version:
React components to create chat conversations or livestream style chat
21 lines • 1.17 kB
TypeScript
import React from 'react';
import type { PropsWithChildren } from 'react';
import type { SearchController } from 'stream-chat';
import type { SearchProps } from './Search';
export type SearchContextValue = {
/** Instance of the search controller that handles the data management */
searchController: SearchController;
/** Reference to the container element of the search component */
containerRef: React.RefObject<HTMLDivElement | null>;
/** Reference to the container element of the filter buttons */
filterButtonsContainerRef: React.RefObject<HTMLDivElement | null>;
} & Pick<SearchProps, 'disabled' | 'placeholder'> & Required<Pick<SearchProps, 'exitSearchOnInputBlur' | 'directMessagingChannelType'>>;
export declare const SearchContext: React.Context<SearchContextValue | undefined>;
/**
* Context provider for components rendered within the `Search` component
*/
export declare const SearchContextProvider: ({ children, value, }: PropsWithChildren<{
value: SearchContextValue;
}>) => import("react/jsx-runtime").JSX.Element;
export declare const useSearchContext: () => SearchContextValue;
//# sourceMappingURL=SearchContext.d.ts.map