Skip to content

Commit

Permalink
Auto convert <br> to <br/>
Browse files Browse the repository at this point in the history
  • Loading branch information
tylerlong committed Mar 13, 2018
1 parent 594847b commit a8e49a0
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "mermaid",
"version": "8.0.0-alpha.7",
"version": "8.0.0-alpha.8",
"description": "Markdownish syntax for generating flowcharts, sequence diagrams, class diagrams, gantt charts and git graphs.",
"main": "dist/mermaid.core.js",
"keywords": [
Expand Down
2 changes: 1 addition & 1 deletion src/mermaid.js
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ const init = function () {
txt = element.innerHTML

// transforms the html to pure text
txt = he.decode(txt).trim()
txt = he.decode(txt).trim().replace(/<br>/ig, '<br/>')

mermaidAPI.render(id, txt, (svgCode, bindFunctions) => {
element.innerHTML = svgCode
Expand Down

0 comments on commit a8e49a0

Please sign in to comment.