mirror of
https://github.com/RGBCube/serenity
synced 2025-05-20 14:15:07 +00:00
TextEditor: Use document path as base URL for markdown preview HTML
This commit is contained in:
parent
770dedcc23
commit
88f7f9712d
1 changed files with 1 additions and 1 deletions
|
@ -553,7 +553,7 @@ void TextEditorWidget::update_markdown_preview()
|
|||
Markdown::Document document;
|
||||
if (document.parse(m_editor->text())) {
|
||||
auto html = document.render_to_html();
|
||||
auto html_document = Web::parse_html_document(html);
|
||||
auto html_document = Web::parse_html_document(html, URL::create_with_file_protocol(m_path));
|
||||
m_html_view->set_document(html_document);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue