mdelobelle / obsidian_supercharged_links

obsidian plugin to add attributes and context menu options to internal links
MIT License
505 stars 33 forks source link

Bug: Markdown links do not work in live preview #80

Closed javiavid closed 6 months ago

javiavid commented 2 years ago

I don't see the icons when I have a markdown link in live preview, in reading mode it works fine.

HEmile commented 2 years ago

What is your CSS? And do you mean with "Markdown link" a link of the form [alias](note name)?

javiavid commented 2 years ago

My CSS is:

.data-link-icon[data-link-category$="People" i]::before{
    content: "👤 "
}

And this is the result:

image

Thanks

HEmile commented 2 years ago

I see, so the issue is the markdown links.

avirosso commented 2 years ago

When will this bug be fixed?

Obsidian is a markdown editor so it should work with standard markdown links in Live Preview too.

Thanks in advance!

HEmile commented 2 years ago

Right, I'll look into this one soon.

HEmile commented 2 years ago

Should work now. Let me know if there are issues! I don't use these links so I haven't tested them thorougly.

avirosso commented 2 years ago

Thanks for the quick fix & reply - unfortunately it still doesn't work with standard markdown links in Live Preview ...

(It works fine in Reading Mode, File Browser and Plugins eg backlinks panel and with wikilinks)

Supercharged Links Version: 0.6.7 Obsidian Version: 0.13.33 (Installer: 0.13.31) (Scheme: tested with standard theme and minimal theme)

Any idea?

HEmile commented 2 years ago

Hmm... Have you refreshed Obsidian to be sure? I just tried again and it's certainly working for me from my tests: Source mode:

image

Live preview:

image
avirosso commented 2 years ago

Thanks for investigtion!

Maybe it works for your example, because there are no 'complete internal markdown urls' (no path, no '.md')

See my examples (Source mode and Live Preview):

Source Mode

Live Preview

HEmile commented 2 years ago

Ahhh, right. Yeah that must be it. I'll continue investigating that!

HEmile commented 2 years ago

Edit mode

image

Live preview

image

Looks like this works!

avirosso commented 2 years ago

Thanks! - although it works for (Options > Files & Links > New link format): "Absolute path in Vault", ist does NOT for "Relative Path to file" and "Shortest Path when possible" .... (sorry for the trouble on weekend)

HEmile commented 2 years ago

Haha... so many possibilities to account for! Okay... I'll look at that later

avirosso commented 2 years ago

I think this issue should be 'reopened' (so that it is not forgotten)?

avirosso commented 2 years ago

Hi,

is there any chance this bug will be fixed in the near future?

Reminder: It works already for 'absolute path, so I guess it shouldn't be a big issue to fix it for 'relative path' and shortest path' too ...?

Thanks in advance!