Parcourir la source

Replace newlines with <br/>. That makes stack traces more readable.

Jonny Schulz il y a 12 ans
Parent
commit
cfd26f601f
1 fichiers modifiés avec 2 ajouts et 1 suppressions
  1. 2 1
      panels/table/module.js

+ 2 - 1
panels/table/module.js

@@ -274,9 +274,10 @@ angular.module('kibana.table', [])
         replace(/&/g, '&amp;').
         replace(/&/g, '&amp;').
         replace(/</g, '&lt;').
         replace(/</g, '&lt;').
         replace(/>/g, '&gt;').
         replace(/>/g, '&gt;').
+        replace(/\r?\n/g, '<br/>').
         replace(/@start-highlight@/g, '<code class="highlight">').
         replace(/@start-highlight@/g, '<code class="highlight">').
         replace(/@end-highlight@/g, '</code>')
         replace(/@end-highlight@/g, '</code>')
     }
     }
     return '';
     return '';
   }
   }
-});
+});