Skip to content

Fixed markdown preview not rendering images with relative paths - #54

Merged
oleg68 merged 1 commit into
nbplugins:mainfrom
oleg68:bugfix/md-image
Apr 16, 2026
Merged

oleg68 merged 1 commit into
nbplugins:mainfrom
oleg68:bugfix/md-image

Conversation

@oleg68

@oleg68 oleg68 commented Apr 16, 2026

Copy link
Copy Markdown
Collaborator

Replaced the unreliable HTMLDocument.setBase() approach with explicit src-attribute resolution: relative img src values are rewritten to absolute file:// URIs in the HTML string before setText() is called. Applied in createOutputPane(), updateContent(), navigateTo(), and the IDE-restore path in componentOpened().

Replaced the unreliable HTMLDocument.setBase() approach with explicit
src-attribute resolution: relative img src values are rewritten to
absolute file:// URIs in the HTML string before setText() is called.
Applied in createOutputPane(), updateContent(), navigateTo(), and the
IDE-restore path in componentOpened().

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@oleg68
oleg68 merged commit 8ff2f93 into nbplugins:main Apr 16, 2026
3 checks passed
@oleg68
oleg68 deleted the bugfix/md-image branch April 16, 2026 18:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant