]> BookStack Code Mirror - bookstack/blob - resources/views/shelves/show.blade.php
Update create new book button on shelves to 2019 design
[bookstack] / resources / views / shelves / show.blade.php
1 @extends('tri-layout')
2
3 @section('body')
4
5     <div class="mb-s">
6         @include('partials.breadcrumbs', ['crumbs' => [
7             $shelf,
8         ]])
9     </div>
10
11     <div class="card content-wrap">
12         <h1 class="break-text">{{$shelf->name}}</h1>
13         <div class="book-content">
14             <p class="text-muted">{!! nl2br(e($shelf->description)) !!}</p>
15             @if(count($books) > 0)
16                 <div class="entity-list">
17                     @foreach($books as $book)
18                         @include('books.list-item', ['book' => $book])
19                     @endforeach
20                 </div>
21             @else
22                 <div class="mt-xl">
23                     <hr>
24                     <p class="text-muted italic mt-xl mb-m">{{ trans('entities.shelves_empty_contents') }}</p>
25                     <div class="icon-list inline block">
26                         @if($currentUser->can('book-create-all'))
27                             <a href="{{ $shelf->getUrl('/create-book') }}" class="icon-list-item">
28                                 <span class="icon">@icon('add')</span>
29                                 <span>{{ trans('entities.books_create') }}</span>
30                             </a>
31                         @endif
32                         @if(userCan('bookshelf-update', $shelf))
33                             <a href="{{ $shelf->getUrl('/edit') }}" class="icon-list-item text-bookshelf">
34                                 <span class="icon">@icon('edit')</span>
35                                 <span>{{ trans('entities.shelves_edit_and_assign') }}</span>
36                             </a>
37                         @endif
38                     </div>
39                 </div>
40             @endif
41         </div>
42     </div>
43
44 @stop
45
46 @section('left')
47
48     @if($shelf->tags->count() > 0)
49         <div id="tags" class="mb-xl">
50             @include('components.tag-list', ['entity' => $shelf])
51         </div>
52     @endif
53
54     <div id="details" class="mb-xl">
55         <h5>{{ trans('common.details') }}</h5>
56         <div class="text-small text-muted blended-links">
57             @include('partials.entity-meta', ['entity' => $shelf])
58             @if($shelf->restricted)
59                 <div class="active-restriction">
60                     @if(userCan('restrictions-manage', $shelf))
61                         <a href="{{ $shelf->getUrl('/permissions') }}">@icon('lock'){{ trans('entities.shelves_permissions_active') }}</a>
62                     @else
63                         @icon('lock'){{ trans('entities.shelves_permissions_active') }}
64                     @endif
65                 </div>
66             @endif
67         </div>
68     </div>
69
70     @if(count($activity) > 0)
71         <div class="mb-xl">
72             <h5>{{ trans('entities.recent_activity') }}</h5>
73             @include('partials.activity-list', ['activity' => $activity])
74         </div>
75     @endif
76 @stop
77
78 @section('right')
79     <div class="actions mb-xl">
80         <h5>{{ trans('common.actions') }}</h5>
81         <div class="icon-list text-primary">
82
83             @if($currentUser->can('book-create-all'))
84                 <a href="{{ $shelf->getUrl('/create-book') }}" class="icon-list-item">
85                     <span class="icon">@icon('add')</span>
86                     <span>{{ trans('entities.books_create') }}</span>
87                 </a>
88             @endif
89
90             @if(userCan('bookshelf-update', $shelf))
91                 <a href="{{ $shelf->getUrl('/edit') }}" class="icon-list-item">
92                     <span>@icon('edit')</span>
93                     <span>{{ trans('common.edit') }}</span>
94                 </a>
95             @endif
96
97             @if(userCan('restrictions-manage', $shelf))
98                 <a href="{{ $shelf->getUrl('/permissions') }}" class="icon-list-item">
99                     <span>@icon('lock')</span>
100                     <span>{{ trans('entities.permissions') }}</span>
101                 </a>
102             @endif
103
104             @if(userCan('bookshelf-delete', $shelf))
105                 <a href="{{ $shelf->getUrl('/delete') }}" class="icon-list-item">
106                     <span>@icon('delete')</span>
107                     <span>{{ trans('common.delete') }}</span>
108                 </a>
109             @endif
110
111         </div>
112     </div>
113 @stop
114
115
116
117