@awell-health/navi-js-react
Version:
React components and hooks for integrating Navi care flows
31 lines (30 loc) • 1.27 kB
TypeScript
import React from "react";
import type { RenderOptions, ActivityEvent, SessionEvent } from "@awell-health/navi-core";
export interface NaviEmbedProps extends RenderOptions {
className?: string;
style?: React.CSSProperties;
onActivityCompleted?: (event: ActivityEvent<{
submissionData: any;
}>) => void;
onSessionReady?: (event: SessionEvent<{
sessionId: string;
environment: string;
}>) => void;
onSessionCompleted?: (event: SessionEvent) => void;
onSessionError?: (event: SessionEvent<{
error: string;
}>) => void;
onIframeClose?: (event: SessionEvent) => void;
/** @deprecated Use onSessionReady instead */
onReady?: () => void;
/** @deprecated Use onSessionCompleted instead */
onCompleted?: () => void;
/** @deprecated Use onSessionError instead */
onError?: (error: {
message: string;
code?: string;
}) => void;
/** @deprecated Use onIframeClose instead */
onClose?: () => void;
}
export declare function NaviEmbed({ className, style, onActivityCompleted, onSessionReady, onSessionCompleted, onSessionError, onIframeClose, onReady, onCompleted, onError, onClose, ...renderOptions }: NaviEmbedProps): import("react/jsx-runtime").JSX.Element;