dendronhq / dendron

The personal knowledge management (PKM) tool that grows as you do!
https://wiki.dendron.so
Apache License 2.0
6.68k stars 252 forks source link

Two images with custom CSS properties on same line #3905

Open josephgarnier opened 1 year ago

josephgarnier commented 1 year ago

Please select the area your bug applies to. (Multiple selections are Possible. You can leave blank if you're not sure.)

Describe the bug

When you add two images with a custom CSS property on the same line, none is rendered.

To Reproduce

In a markdown file, write these lines:

Doesn't work:

test ![alt1](images/my_image.svg){max-width: 10px} ![alt2](images/my_image.svg){max-width: 10px}

image

test ![alt1](images/my_image.svg) ![alt2](images/my_image.svg){max-width: 10px}

image

Work:

test ![alt1](images/my_image.svg){max-width: 10px} ![alt2](images/my_image.svg)

image (Picture cropped, because it is really big)

Expected behavior

Two tiny images should be displayed in the same line.

Desktop (please complete the following information)

Additional context

Add any other context about the problem here.

Dendron Log file

Please attach the output of > Dendron:Dev: Open Logs here

Gander7 commented 1 year ago

@josephgarnier Assuming your goal is to render them on a single line, If you put them on seperate but consecutive lines in the markdown file, they are rendered on the same line.

test 
![alt1](images/my_image.svg){max-width: 10px} 
![alt2](images/my_image.svg){max-width: 10px}

as long as there is no space in between or two spaces at the end, markdown will render them on the same line.

My test:

test
![Monster1](/assets/images/2022-03-23-21-23-13.png){max-width: 50px}
![Monster2](/assets/images/2022-03-23-21-23-13.png){max-width: 50px}

Rendered Result: image

josephgarnier commented 1 year ago

@Gander7 tks for the tip. But it's still a bug, isn't it?