]> BookStack Code Mirror - bookstack/blobdiff - resources/views/pages/page-display.blade.php
Page Attachments - Improved UI, Now initially complete
[bookstack] / resources / views / pages / page-display.blade.php
index babc4ccfd00b8f4b7309d703101e8604006aeb03..6ffe4b50237209d6f07e5683be265a1e3f4fd0ce 100644 (file)
@@ -1,5 +1,32 @@
 <div ng-non-bindable>
-    <h1 id="bkmrk-page-title">{{$page->name}}</h1>
 
-    {!! $page->html !!}
+    <h1 id="bkmrk-page-title" class="float left">{{$page->name}}</h1>
+
+    @if(count($page->tags) > 0)
+        <div class="tag-display float right">
+            <table>
+                <thead>
+                    <tr class="text-left heading primary-background-light">
+                        <th colspan="2">Page Tags</th>
+                    </tr>
+                </thead>
+                <tbody>
+                    @foreach($page->tags as $tag)
+                        <tr class="tag">
+                            <td @if(!$tag->value) colspan="2" @endif><a href="{{ baseUrl('/search/all?term=%5B' . urlencode($tag->name) .'%5D') }}">{{ $tag->name }}</a></td>
+                            @if($tag->value) <td class="tag-value"><a href="{{ baseUrl('/search/all?term=%5B' . urlencode($tag->name) .'%3D' . urlencode($tag->value) . '%5D') }}">{{$tag->value}}</a></td> @endif
+                        </tr>
+                    @endforeach
+                </tbody>
+            </table>
+        </div>
+    @endif
+
+    <div style="clear:left;"></div>
+
+    @if (isset($diff) && $diff)
+        {!! $diff !!}
+    @else
+        {!! $page->html !!}
+    @endif
 </div>
\ No newline at end of file