UNPKG

react-instantsearch

Version:
17 lines (16 loc) • 1.09 kB
import React from 'react'; import type { ResultCardOwnProps } from 'instantsearch-ui-components'; import type { ResultCardRenderState } from 'instantsearch.js/es/connectors/result-card/connectResultCard'; import type { UseResultCardProps } from 'react-instantsearch-core'; /** * Props passed to a custom `layoutComponent`: the connector render state, so a * layout component owns the full markup, including every status and the * retry and handoff actions. */ export type ResultCardLayoutComponentProps = ResultCardRenderState; type OwnedUiProps = 'status' | 'messages' | 'error' | 'suggestions' | 'onRetry' | 'minimized' | 'onToggleMinimize' | 'canContinueInChat' | 'onContinueInChat' | 'expanded' | 'onExpandedChange'; export type ResultCardProps = Omit<ResultCardOwnProps, OwnedUiProps> & UseResultCardProps & { layoutComponent?: (props: ResultCardLayoutComponentProps) => JSX.Element | null; }; export declare function ResultCard({ classNames, layoutComponent: LayoutComponent, agentId, transport, requestOptions, ...props }: ResultCardProps): React.JSX.Element; export {};