zip download of single pdfs

This commit is contained in:
2026-05-17 02:57:39 +02:00
parent 13097b73fc
commit 4b0046a943
11 changed files with 272 additions and 27 deletions

View File

@@ -16,6 +16,7 @@ interface ActionsPanelProps {
onExportReordered: () => void;
splitDownloads: SplitPdfDownload[];
splitZipDownload: PdfDownload | null;
subsetDownload: PdfDownload | null;
exportDownload: PdfDownload | null;
}
@@ -29,6 +30,7 @@ const ActionsPanel: React.FC<ActionsPanelProps> = ({
onOpenSelectionAsWorkspace,
onExportReordered,
splitDownloads,
splitZipDownload,
subsetDownload,
exportDownload,
}) => {
@@ -132,7 +134,18 @@ const ActionsPanel: React.FC<ActionsPanelProps> = ({
{splitDownloads.length > 0 && (
<div style={{ marginTop: '0.75rem', fontSize: '0.9rem' }}>
<strong>Single-page PDFs:</strong>
<div>
{splitZipDownload && (
<div style={{ marginTop: '0.25rem' }}>
<a
className="download-link"
href={splitZipDownload.url}
download={splitZipDownload.filename}
>
Download all as ZIP ({splitDownloads.length} files)
</a>
</div>
)}
<div style={{ marginTop: '0.25rem' }}>
{splitDownloads.map((download) => (
<a
key={download.id}

View File

@@ -49,11 +49,15 @@ const tutorialSteps = [
body: 'Extract selected pages when you only need a download. Open the selection as a new workspace when you want to continue working on that subset.',
},
{
title: '5. Save your workspace or export a PDF',
title: '5. Split and download results',
body: 'Splitting creates individual one-page PDF downloads and a ZIP archive that contains all generated page files.',
},
{
title: '6. Save your workspace or export a PDF',
body: 'Saving a workspace keeps the current working state in this browser. Exporting creates a new PDF file for download.',
},
{
title: '6. Use history deliberately',
title: '7. Use history deliberately',
body: 'Each workspace operation is stored as a command with label and timestamp. Undo and redo walk through that command history.',
},
];