Browse Source

replace linebreaks with <br/> in data section of tooltip.

Jan Gaedicke 11 years ago
parent
commit
9e1e7be574
1 changed files with 1 additions and 1 deletions
  1. 1 1
      src/app/services/annotationsSrv.js

+ 1 - 1
src/app/services/annotationsSrv.js

@@ -135,7 +135,7 @@ define([
       }
       }
       tooltip += '<i>' + moment(options.time).format('YYYY-MM-DD HH:mm:ss') + '</i><br/>';
       tooltip += '<i>' + moment(options.time).format('YYYY-MM-DD HH:mm:ss') + '</i><br/>';
       if (options.data) {
       if (options.data) {
-        tooltip += options.data;
+        tooltip += options.data.replace(/\n/g, '<br/>');
       }
       }
       tooltip += "</small>";
       tooltip += "</small>";