@@ -8,11 +8,11 @@ function processPandoc(req, res) { | |||
let tmpf = tmp.fileSync({ postfix: ".pdf" }); | |||
let child = spawn("pandoc", | |||
[ "--standalone", "--pdf-engine=pdflatex", "--output", tmpf.name ]); | |||
[ "--standalone", "--output", tmpf.name ]); | |||
child.on("error", err => { | |||
res.writeHead(500); | |||
res.end(err); | |||
res.end(JSON.stringify({ output: err.toString() })); | |||
tmpf.removeCallback(); | |||
}); | |||
@@ -21,9 +21,7 @@ | |||
<canvas id="preview"></canvas> | |||
</div> | |||
</div> | |||
<div id="pandoc-output"> | |||
Test | |||
</div> | |||
<div id="pandoc-output"></div> | |||
</div> | |||
<script src="https://cdn.jsdelivr.net/simplemde/latest/simplemde.min.js"></script> |
@@ -12,7 +12,7 @@ html, body, #container { | |||
grid-template-rows: auto 100px; | |||
grid-template-areas: | |||
'left-pane right-pane' | |||
'footer footer'; | |||
'footer right-pane'; | |||
} | |||
#editor-container { | |||
@@ -34,6 +34,13 @@ html, body, #container { | |||
overflow: auto; | |||
} | |||
#preview-controls { | |||
line-height: 50px; | |||
} | |||
#pandoc-output { | |||
grid-area: footer; | |||
min-height: 0px; | |||
white-space: pre; | |||
overflow: auto; | |||
} |