import { Modal, Text, Stack, Alert, Group, Button, TextInput, } from "@mantine/core"; import { IconAlertTriangle } from "@tabler/icons-react"; import { useTranslation } from "react-i18next"; import { IApiKey } from "@/ee/api-key"; import CopyTextButton from "@/components/common/copy.tsx"; interface ApiKeyCreatedModalProps { opened: boolean; onClose: () => void; apiKey: IApiKey; } export function ApiKeyCreatedModal({ opened, onClose, apiKey, }: ApiKeyCreatedModalProps) { const { t } = useTranslation(); if (!apiKey) return null; return ( } title={t("Important")} color="red" > {t( "Make sure to copy your {{credential}} now. You won't be able to see it again!", { credential: t("API key") }, )}
{t("API key")}
); }