feat: support image height in markdown rendering of messages (#8177)
- This PR adds BaseMarkdownRenderer, it takes all the required attributes from the image node, parses the cw_image_height query and renders it.
This commit is contained in:
@@ -4,7 +4,9 @@ class ChatwootMarkdownRenderer
|
||||
end
|
||||
|
||||
def render_message
|
||||
html = CommonMarker.render_html(@content)
|
||||
markdown_renderer = BaseMarkdownRenderer.new
|
||||
doc = CommonMarker.render_doc(@content, :DEFAULT)
|
||||
html = markdown_renderer.render(doc)
|
||||
render_as_html_safe(html)
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user