import React from "react"; import { EmptyDataIllustration } from "./empty-data-illustration.component"; import styles from "./empty-state.scss"; import { Trans, useTranslation } from "react-i18next"; import { Button, Tile, Link, Layer } from "@carbon/react"; interface EmptyStateProps { headerTitle: string; displayText?: string; launchForm?: () => void; launchFormComponent?: any; hideFormLauncher?: boolean; } export const EmptyState: React.FC = ({ headerTitle, displayText, launchFormComponent, hideFormLauncher = true, launchForm, }) => { const { t } = useTranslation(); return (

{headerTitle}

{launchFormComponent}

There are no {displayText.toLowerCase()} to display {displayText.toLowerCase() != "patients" ? " for this patient" : ""}

{launchFormComponent && !hideFormLauncher && (

launchForm()}> {t("record", "Record")} {displayText.toLowerCase()}

)}
{/* @ts-ignore */}
); };