1 @extends('layouts.tri')
4 <meta property="og:description" content="{{ Str::limit($shelf->description, 100, '...') }}">
6 <meta property="og:image" content="{{ $shelf->getBookCover() }}">
13 @include('entities.breadcrumbs', ['crumbs' => [
18 <main class="card content-wrap">
20 <div class="flex-container-row wrap v-center">
21 <h1 class="flex fit-content break-text">{{ $shelf->name }}</h1>
22 <div class="flex"></div>
23 <div class="flex fit-content text-m-right my-m ml-m">
24 @include('entities.sort', ['options' => [
25 'default' => trans('common.sort_default'),
26 'name' => trans('common.sort_name'),
27 'created_at' => trans('common.sort_created_at'),
28 'updated_at' => trans('common.sort_updated_at'),
29 ], 'order' => $order, 'sort' => $sort, 'type' => 'shelf_books'])
33 <div class="book-content">
34 <p class="text-muted">{!! nl2br(e($shelf->description)) !!}</p>
35 @if(count($sortedVisibleShelfBooks) > 0)
37 <div class="entity-list">
38 @foreach($sortedVisibleShelfBooks as $book)
39 @include('books.parts.list-item', ['book' => $book])
43 <div class="grid third">
44 @foreach($sortedVisibleShelfBooks as $book)
45 @include('entities.grid-item', ['entity' => $book])
52 <p class="text-muted italic mt-xl mb-m">{{ trans('entities.shelves_empty_contents') }}</p>
53 <div class="icon-list inline block">
54 @if(userCan('book-create-all') && userCan('bookshelf-update', $shelf))
55 <a href="{{ $shelf->getUrl('/create-book') }}" class="icon-list-item text-book">
56 <span class="icon">@icon('add')</span>
57 <span>{{ trans('entities.books_create') }}</span>
60 @if(userCan('bookshelf-update', $shelf))
61 <a href="{{ $shelf->getUrl('/edit') }}" class="icon-list-item text-bookshelf">
62 <span class="icon">@icon('edit')</span>
63 <span>{{ trans('entities.shelves_edit_and_assign') }}</span>
76 @if($shelf->tags->count() > 0)
77 <div id="tags" class="mb-xl">
78 @include('entities.tag-list', ['entity' => $shelf])
82 <div id="details" class="mb-xl">
83 <h5>{{ trans('common.details') }}</h5>
84 <div class="blended-links">
85 @include('entities.meta', ['entity' => $shelf])
86 @if($shelf->restricted)
87 <div class="active-restriction">
88 @if(userCan('restrictions-manage', $shelf))
89 <a href="{{ $shelf->getUrl('/permissions') }}" class="entity-meta-item">
91 <div>{{ trans('entities.shelves_permissions_active') }}</div>
94 <div class="entity-meta-item">
96 <div>{{ trans('entities.shelves_permissions_active') }}</div>
104 @if(count($activity) > 0)
106 <h5>{{ trans('entities.recent_activity') }}</h5>
107 @include('common.activity-list', ['activity' => $activity])
113 <div class="actions mb-xl">
114 <h5>{{ trans('common.actions') }}</h5>
115 <div class="icon-list text-primary">
117 @if(userCan('book-create-all') && userCan('bookshelf-update', $shelf))
118 <a href="{{ $shelf->getUrl('/create-book') }}" class="icon-list-item">
119 <span class="icon">@icon('add')</span>
120 <span>{{ trans('entities.books_new_action') }}</span>
124 @include('entities.view-toggle', ['view' => $view, 'type' => 'shelf'])
126 <hr class="primary-background">
128 @if(userCan('bookshelf-update', $shelf))
129 <a href="{{ $shelf->getUrl('/edit') }}" class="icon-list-item">
130 <span>@icon('edit')</span>
131 <span>{{ trans('common.edit') }}</span>
135 @if(userCan('restrictions-manage', $shelf))
136 <a href="{{ $shelf->getUrl('/permissions') }}" class="icon-list-item">
137 <span>@icon('lock')</span>
138 <span>{{ trans('entities.permissions') }}</span>
142 @if(userCan('bookshelf-delete', $shelf))
143 <a href="{{ $shelf->getUrl('/delete') }}" class="icon-list-item">
144 <span>@icon('delete')</span>
145 <span>{{ trans('common.delete') }}</span>
150 <hr class="primary-background">
151 @include('entities.favourite-action', ['entity' => $shelf])