about summary refs log tree commit diff
path: root/public
diff options
context:
space:
mode:
authorFlorian Klink <flokli@flokli.de>2019-12-04T14·21+0100
committerFlorian Klink <flokli@flokli.de>2019-12-04T14·21+0100
commitea04792c39604267fdb4fa9d83841f5a08c0003e (patch)
treea19b074bdcc98b06adc6d32d390b9a95e1d3d7d2 /public
parentbdfdad2585737c5760971889fd5def32e14b38c5 (diff)
frontend: improve log display
Diffstat (limited to 'public')
-rw-r--r--public/index.tmpl.html21
1 files changed, 15 insertions, 6 deletions
diff --git a/public/index.tmpl.html b/public/index.tmpl.html
index bc145c5b6426..d7ec29c25053 100644
--- a/public/index.tmpl.html
+++ b/public/index.tmpl.html
@@ -63,15 +63,24 @@
     {{ end }}
 
     <h2 id="region-log">Log</h2>
-    <table class="table">
+    <table class="table .table-sm">
       <tbody>
-        <tr>
-          <td class="bg-dark text-white">
-            {{ range $entry := .memory.Entries }}
-            <code>{{ $entry }}</code><br />
-            {{ end }}
+        {{ range $entry := .memory.Entries }}
+        <tr class="bg-dark {{ levelToClasses $entry.Level }}">
+          <td rowspan="2">
+            {{ $entry.Timestamp.Format "2006-01-02 15:04:05 UTC"}}
+          </td>
+          <td>{{ $entry.Level }}</td>
+          <td>
+            <code class="{{ levelToClasses $entry.Level }}">{{ $entry.Message }}</code><br />
+          </td>
+        </tr>
+        <tr class="bg-dark {{ levelToClasses $entry.Level }}">
+          <td colspan="2">
+              <code class="{{ levelToClasses $entry.Level }}">{{ fieldsToJSON $entry.Fields }}</code><br />
           </td>
         </tr>
+        {{ end }}
       </tbody>
     </table>
 </body>