-
-
Notifications
You must be signed in to change notification settings - Fork 84
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
Webclips extraction confused by tabs #565
Comments
I think the problem is that Yarle writes tabs at the beginning of the line at all. It may be that these are in the HTML source code, but then they have a different (wrong) meaning for Obsidian. So the correct behavior would be to remove or escape the tabs (if possible). |
Aham. And what about a general "skip tabs recognition as codeblocks (by removing them)" toggle in the configuration panel? |
The only thing that I know of (and I am not an HTML expert) are the tags |
Yes, that's true, but unfortunately evernote's Enex content is not a clear standard html. Now I tested it in the latest version, and the codeblock is stored as follows:
But as far as I remember these kind of new formats were introduced in v10, it was stored differently in v7. As I don't have that version, could you please create a simple codeblock-note in v7, and send me its enex exported in v7? Thanks a lot! |
No problem. |
thanks you! okay, the old one has almost the same div + style but a different attribute: |
What happens when you webclip this html page?
|
I made it here: https://amethyst-juliana-94.tiiny.site/
In SimplifiedArticle it replaces pre by div and puts the attribute
and Multiple Selection e it replaces pre by div and puts the attribute
The variations differ from the layout because of the inline styles added to the divs, see screenshots: |
So, long story short: Yarle has to be prepared for all of the possibilities: handle the attribute, and the "pre" as well. + a toggle to trim the tabs from the beginning of the lines. |
You should also check what happens if a plain text note just contains tabs for formatting reasons. |
eh... okay I tested the codeblock stuff and everything looks fine (I added some extra tests). |
But I can reproduce the behaviour that the link is displayed (and linked) in a simple test note which has leading tabs. But, as shown above, in the other note the tabs clearly have an effect on the linking. But currently I have no idea what the reason is... What I also notice: When I use tabs in simple text notes, then the text is not displayed in monospace, meaning it is not considered as code block. And of course, if a section is not considered as code, then images are linked and pictures are displayed. |
Maybe once the line that contains a link is being edited may trigger a reload of the references, mentions, backlinks etc. |
Nope. When I just change text in this line then nothing changes. When I remove the tab, then the backlink appears. When I enter the tab again, then the backlink is gone again. You can try yourself with the note I provided. My case is around line 209. |
Well, yeah, this exactly shows that Obsidian interprets tabs, e.g. indentation "with more precedence", differently than normal text, and after hitting one or more tabs it looses the backlinks. |
Currently I seem to have the impression: I think the solution with the addional webclip option is best... |
implemented in https://github.com/akosbalasko/yarle/releases/tag/v6.1.0 |
Thank you! But I think it is not working in all cases. It does in a lot of cases, but not all of them... In the attached enex-file check for the image before "Je m’appelle Alex" in the note "Voyage en Guyane _ Mes Conseils et Mon Itinéraire Idéal de 15 jours" The attachment should be here:
|
I have a webclipped note where there are tabs at the beginning of the line - which makes the line interpreted as code block, and linked images are not recognised as such.
The attached note shows this behavior (in the lower part).
Debug.zip
The text was updated successfully, but these errors were encountered: