dendron
dendron copied to clipboard
feat(workspace): copy as command
This PR aims to add a Copy As command. It is similar to Export pod command, with a predefined config. Presently it supports two formats: JSON and markdown. The formatted note is copied to the clipboard.
- Task: [[Copy as Command|dendron://private/task.2022.07.31.copy-as-command]]
- Docs: https://github.com/dendronhq/dendron-site/pull/655
TODO: copy as for a selection in note body
Dendron Extended PR Checklist
- NOTE: the links don't work. you'll need to go into the wiki and use lookup to find the note until we fix some issues in the markdown export
Code
Basics
- [x] code should follow Code Conventions
- [x] circular dependency check: make sure your code is not introducing new circular dependencies in plugin-core. See Avoiding Circular Dependencies.
- [x] sticking to existing conventions instead of creating new ones
Extended
- General
- [x] check whether code be simplified
- [x] check if similar function already exist in the codebase. if so, can it be re-used?
- [x] check if this change adversely impact performance
- Operations
- [x] when shipping this change, will it just work or will it introduce additional operational overhead due to complicated interface or known bugs?
- Architecture
- [~] check if code is introducing changes on a foundational class or interface. if so, call for design review if needed
Instrumentation
Basics
- [ ] if you are adding analytics related changes, make sure the Telemetry docs are updated
Extended
- [ ] can we track the performance of this change to know if it is successful?
Tests
Basics
- [x] Write Tests
- [ ] Confirm existing tests pass
- [x] Confirm manual testing
- [x] Common cases tested
- [x] 1-2 Edge cases tested
- [~] If your tests changes an existing snapshot, snapshots have been updated
Extended
Docs
- [x] if your change reflects documentation changes, also submit a PR to dendron-site and mention the doc PR link in your current PR
- [ ] does this change introduce a new or better way of doing things that others need to be aware of? if so, an async should be created and a process added in Development or Packages