1 import { c } from 'ttag';
3 import { Button } from '@proton/atoms';
4 import type { ModalStateProps } from '@proton/components';
5 import { BasicModal, PrimaryButton, useModalTwoStatic } from '@proton/components';
6 import { DOCS_APP_NAME, DRIVE_APP_NAME } from '@proton/shared/lib/constants';
10 onSubmit?: () => void;
13 export default function DownloadContainsDocumentsModal({
19 }: Props & ModalStateProps) {
20 const handleCancel = () => {
28 // translator: Your download has a Proton Docs file
29 c('Title').t`Your download has a ${DOCS_APP_NAME} file`
31 isOpen={open === undefined ? true : open}
32 onClose={handleCancel}
35 <Button onClick={handleCancel}>{c('Action').t`Cancel download`}</Button>
42 {c('Action').t`Understood`}
49 // translator: Downloading Proton Docs files from Proton Drive is currently not supported (...)
51 .t`Downloading ${DOCS_APP_NAME} files from ${DRIVE_APP_NAME} is currently not supported — these will not be included in your download.`
54 // translator: Please export them directly from the Proton Docs application (...)
56 .t`Please export them directly from the ${DOCS_APP_NAME} application instead if you wish to download them.`
62 export const useDownloadContainsDocumentsModal = () => {
63 return useModalTwoStatic(DownloadContainsDocumentsModal);