/** * Copyright (c) 2023-present Plane Software, Inc. and contributors * SPDX-License-Identifier: AGPL-3.0-only * See the LICENSE file for details. */ import { useState } from "react"; // ui import { Button } from "@plane/propel/button"; import { EModalPosition, EModalWidth, ModalCore } from "@plane/ui"; type Props = { isOpen: boolean; handleClose: () => void; onDiscard: () => void; onConfirm: () => Promise; }; export function ConfirmIssueDiscard(props: Props) { const { isOpen, handleClose, onDiscard, onConfirm } = props; const [isLoading, setIsLoading] = useState(false); const onClose = () => { handleClose(); setIsLoading(false); }; const handleDeletion = async () => { setIsLoading(true); await onConfirm(); setIsLoading(false); }; return (

Save this draft?

You can save this work item to Drafts so you can come back to it later.{" "}

); }