re-structure to monorepo.

This commit is contained in:
a.bouhuolia
2023-02-03 01:02:31 +02:00
parent 8242ec64ba
commit 7a0a13f9d5
10400 changed files with 46966 additions and 17223 deletions

View File

@@ -0,0 +1,50 @@
// @ts-nocheck
import React from 'react';
import { AnchorButton } from '@blueprintjs/core';
import { DialogContent, PdfDocumentPreview, T } from '@/components';
import { usePdfReceipt } from '@/hooks/query';
import withDialogActions from '@/containers/Dialog/withDialogActions';
import { compose } from '@/utils';
function ReceiptPdfPreviewDialogContent({
subscriptionForm: { receiptId },
// #withDialogActions
closeDialog,
}) {
const { isLoading, pdfUrl } = usePdfReceipt(receiptId);
return (
<DialogContent>
<div class="dialog__header-actions">
<AnchorButton
href={pdfUrl}
target={'__blank'}
minimal={true}
outlined={true}
>
<T id={'pdf_preview.preview.button'} />
</AnchorButton>
<AnchorButton
href={pdfUrl}
download={'receipt.pdf'}
minimal={true}
outlined={true}
>
<T id={'pdf_preview.download.button'} />
</AnchorButton>
</div>
<PdfDocumentPreview
height={760}
width={1000}
isLoading={isLoading}
url={pdfUrl}
/>
</DialogContent>
);
}
export default compose(withDialogActions)(ReceiptPdfPreviewDialogContent);