mirror of
https://github.com/BoostIO/BoostNote-App.git
synced 2026-04-26 21:05:55 +03:00
[PR #734] [MERGED] Add batch export folder/storage in context menu #870
Labels
No labels
android 🤖
assigned to core 🦹
bug 🐛
documentation 📚
documentation 📚
duplicate 🚫
external issue 🔼
external issue 🔼
feature request 🌟
funded on issuehunt 💵
help wanted 🆘
improvement request 🔨
improvement request 🔨
ios 🍎
mobile 📱
needs investigation 🔬
needs more info ℹ️
needs specs 📐
plugin idea 🔌
plugin idea 🔌
poll 🗳️
pull-request
question ❓
rewarded on issuehunt 🎁
security issue 🔑
won’t fix ❌
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/BoostNote-App#870
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/BoostIO/BoostNote-App/pull/734
Author: @Komediruzecki
Created: 12/21/2020
Status: ✅ Merged
Merged: 5/28/2021
Merged by: @Rokt33r
Base:
master← Head:feature/add-batch-export-folder-in-context-menu📝 Commits (1)
05745fcInitial batch export for PDF📊 Changes
5 files changed (+803 additions, -46 deletions)
View changed files
📝
src/components/atoms/ProgressBar.tsx(+3 -2)➕
src/components/molecules/ExportProgressItem.tsx(+587 -0)📝
src/components/molecules/FolderNavigatorItem.tsx(+108 -34)📝
src/components/molecules/StorageNavigatorFragment.tsx(+54 -1)📝
src/lib/exports.ts(+51 -9)📄 Description
Initial batch export for PDF (#491)
Add prepare export functions in exports.ts
Add handling of menus for folder exports
Add support for non-recursive/recursive exports
Add export progress bar
Add support for storage/workspace export
Refactor functions for exports
Add component for batch export handling (state, procedure)
Refactor folder and storage export to use the component
Fix cancelation state logic
Add dim background on export procedure
General functionality:
Users can export folders via the context menu.

By right-clicking on the desired folder the context menu with export options comes up:
A similar context menu dialog is available for workspace/storage navigation item (for exporting whole storage)

Once the exported is selected, the file explorer comes up and offers the user to choose the save location.
When the location is confirmed export process starts and users can see export progress:
First directories are created in the destination (depending on recursive/non-recursive and selected folder/storage)
Then notes are being exported to their appropriate locations:
During export, for now, users can only cancel the export.
This stops the export, and the message of the export state is shown as a push message:
During export, export errors generated from export functions are shown in push messages as well.
In the end, the summary is also generated, as well as any export errors.
Summary for successfully finish - push message:
The whole procedure while exporting can be seen here:

Error handling:
When directory creation fails, the export fails
When one note export fails, the export process continues
Any unknown error happens, it is caught and the user is notified (as well as
console.warn)Add options in progress bar modal
Cancelable promise API instead of useRef
Option to hide export dialog (send to background/status bar)
Status bar rendering of export, re-activate export modal
Handle overwrites (dirs, notes)
Add translations for batch export strings
Better export modal dialog design
Test:
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.