UNPKG

react-instantsearch

Version:
14 lines (13 loc) • 887 B
import type { ComparisonTableTranslations, RecommendComponentProps, RecordWithObjectID, UserClientSideTool } from 'instantsearch-ui-components'; type ItemComponent<TObject> = RecommendComponentProps<TObject>['itemComponent']; /** * Builtin comparison tool (`algolia_compare_products`). * * Registered by default in the chat widget so the agent can lay a comparison * out as a table: the compared products across the top (rendered with the * widget's `itemComponent`, from the records the chat collected) and the * agent's criteria down the side, one value per product. See * `instantsearch-ui-components` `CompareProductsTool` for the contract. */ declare function createCompareProductsTool<TObject extends RecordWithObjectID>(itemComponent?: ItemComponent<TObject>, translations?: Partial<ComparisonTableTranslations>): UserClientSideTool; export { createCompareProductsTool };