readwiseio / logseq-readwise-official-plugin

GNU General Public License v3.0
56 stars 3 forks source link

Highlighted images format is markdown by default, how can I specify for orgmode #20

Open saccohuo opened 1 year ago

saccohuo commented 1 year ago

Highlighted images format is markdown by default like ![](https://pbs.twimg.com/media/FnOEDC4aEAMxj5M.jpg) ([View Highlight](https://read.readwise.io/read/01gqqdbps20k8bdaf63at41w7t)).

How can I specify it for orgmode?

englishm commented 1 year ago

I noticed that this issue also exists for links to bookmarked tweets

I think highlight_location_url expands to something like this:

([View Tweet](https://twitter.com/user/status/1234567890123456789))

Whereas for orgmode, a link should be formatted like so:

([[View Tweet][https://twitter.com/user/status/1234567890123456789]])

Similarly, for images — where markdown has:

![](https://pbs.twimg.com/media/FnOEDC4aEAMxj5M.jpg)

orgmode would use:

[[https://pbs.twimg.com/media/FnOEDC4aEAMxj5M.jpg]]

It would be nice if the plugin could automatically output in the correct format or if at least format-specific jinja variables could be defined, but without looking at the code yet, I wonder if it might also be possible to work around this temporarily (in a very kludgey way) with a few Jinja2 filters in a custom format..