xpgo / obsidian-folder-note-plugin

Plugin to add description note to a folder for Obsidian.
385 stars 27 forks source link

[Bug] Card image doesn't load if the image has size param (Wikilinks format) #94

Open jj-obrien opened 4 months ago

jj-obrien commented 4 months ago

Thumbnails in the cards load correctly if the first image in the note is in the following markdown format:

![[image.png]]

but fail to load if they also have a width parameter like so:

![[image.png|300]]

This only occurs in wikilinks format (Setting -> Files and Links -> Use [[Wikilinks]]). In normal markdown resized images load correctly:

![image|300](image.png)

Inspecting the element shows that the pipe and the size is included in the URL, breaking the link and causing a 404 (file not found) error in the console.

<div class="thumb" style="background-image: url(app://(...)/_resources/image.png|300?1713454485289);"></div>

The plugin should ignore the pipe and values after the pipe for images using wikilinks.

Folder Note version 0.7.3 with Obsidian version 1.5.12 on Ubuntu 22.04