Skip to content
Snippets Groups Projects
Commit 2d3340c6 authored by Friederike Schwager's avatar Friederike Schwager Committed by Friederike Schwager
Browse files

display linebreaks in comments

parent 90fb7df0
Branches
Tags
No related merge requests found
...@@ -1524,6 +1524,9 @@ function startIndex(Y,_cm,_documentObject,_userid,_capabilities, _toolbarSetting ...@@ -1524,6 +1524,9 @@ function startIndex(Y,_cm,_documentObject,_userid,_capabilities, _toolbarSetting
if(!comments.comments){ if(!comments.comments){
comments = {comments: [comments]}; comments = {comments: [comments]};
} }
comments.comments.forEach(function(comment) {
comment.content = comment.content.replace(/\n/g, "<br>");
});
(function(templates, data) { (function(templates, data) {
templates.render('mod_pdfannotator/comment', data) templates.render('mod_pdfannotator/comment', data)
.then(function(html,js){ .then(function(html,js){
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment