Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[wip] feat: add "Copy as document" to copy rich markdown into emails and documents #2367

Closed
wants to merge 2 commits into from

Conversation

bensu
Copy link
Contributor

@bensu bensu commented Jul 3, 2021

I will often write something in Logseq that I want to send via email or make part of a Google Doc / Dropbox Paper. "Copy as TEXT" has two problems:

  • It gives me the contents of only one block and not its children
  • It gives me content in markdown format (_foo_ instead of foo) and then I need to transform it manually

I added "Copy as DOCUMENT" that changes both of those things. IMO, this should be the behavior of "Copy as TEXT" but maybe others use it differently and have other expectations.

Note that Copy as Document only gives you rich text when you paste into an editor that can handle it. Otherwise, it gives you the same format as Copy as TEXT but with the children contents

TODO in this PR

  • Handle embeds
  • Handle references

@bensu
Copy link
Contributor Author

bensu commented Jul 3, 2021

@bensu bensu changed the title feat: add "Copy as document" to copy rich markdown into emails and documents [wip] feat: add "Copy as document" to copy rich markdown into emails and documents Jul 3, 2021
@bensu
Copy link
Contributor Author

bensu commented Jul 3, 2021

I'll probably need to change mldoc in order to handle the two outstanding TODOs

@RCmerci
Copy link
Contributor

RCmerci commented Jul 4, 2021

hi @bensu, I'm working on block-level export feature now

  • exporting a block will include itself and its childs
  • replace embed&block-references with related contents
  • but not working on block-level html exporting yet, so excited about this PR.

And for replace embed & refs, related mldoc source:

related PRs here:

@bensu
Copy link
Contributor Author

bensu commented Jul 5, 2021

Cool! In that case, let’s bench this PR until you are done with that feature and then we can see if there is a good way to translate the work you did for an HTML export.

@tiensonqin
Copy link
Contributor

@bensu both PRs are merged now, let us know if you need any help on mldoc.

@RCmerci
Copy link
Contributor

RCmerci commented Jul 21, 2021

hi @bensu, I'll start updating some implements of html-export in mldoc recently. Will update infos in this issue

@RCmerci
Copy link
Contributor

RCmerci commented Jul 26, 2021

Hi @bensu , here is the PR for "export as html": #2496

@tiensonqin
Copy link
Contributor

Closing this since "Copy as text/HTML/OPML" is supported now.

@tiensonqin tiensonqin closed this Aug 17, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants