3 @section('container-attrs')
5 entity-id="{{ $chapter->id }}"
12 @include('partials.breadcrumbs', ['crumbs' => [
18 <div class="content-wrap card">
19 <h1 class="break-text" v-pre>{{ $chapter->name }}</h1>
20 <div class="chapter-content" v-show="!searching">
21 <p v-pre class="text-muted break-text">{!! nl2br(e($chapter->description)) !!}</p>
22 @if(count($pages) > 0)
23 <div v-pre class="entity-list book-contents">
24 @foreach($pages as $page)
25 @include('pages.list-item', ['page' => $page])
29 {{--TODO - Empty States --}}
31 <p class="text-muted italic">{{ trans('entities.chapters_empty') }}</p>
33 @if(userCan('page-create', $chapter))
34 <a href="{{ $chapter->getUrl('/create-page') }}" class="button outline">@icon('page'){{ trans('entities.books_empty_create_page') }}</a>
36 @if(userCan('page-create', $chapter) && userCan('book-update', $book))
37 <em class="text-muted">-{{ trans('entities.books_empty_or') }}-</em>
39 @if(userCan('book-update', $book))
40 <a href="{{ $book->getUrl('/sort') }}" class="button outline">@icon('book'){{ trans('entities.books_empty_sort_current_book') }}</a>
47 @include('partials.entity-dashboard-search-results')
55 <h5>{{ trans('common.details') }}</h5>
56 <div class="blended-links text-small text-muted">
57 @include('partials.entity-meta', ['entity' => $chapter])
59 @if($book->restricted)
60 <div class="active-restriction">
61 @if(userCan('restrictions-manage', $book))
62 <a href="{{ $book->getUrl('/permissions') }}">@icon('lock'){{ trans('entities.books_permissions_active') }}</a>
64 @icon('lock'){{ trans('entities.books_permissions_active') }}
69 @if($chapter->restricted)
70 <div class="active-restriction">
71 @if(userCan('restrictions-manage', $chapter))
72 <a href="{{ $chapter->getUrl('/permissions') }}">@icon('lock'){{ trans('entities.chapters_permissions_active') }}</a>
74 @icon('lock'){{ trans('entities.chapters_permissions_active') }}
81 <div class="actions mb-xl">
82 <h5>{{ trans('common.actions') }}</h5>
83 <div class="icon-list text-primary">
85 <div dropdown class="dropdown-container">
86 <div dropdown-toggle class="icon-list-item">
87 <span>@icon('export')</span>
88 <span>{{ trans('entities.export') }}</span>
91 <li><a href="{{ $chapter->getUrl('/export/html') }}" target="_blank">{{ trans('entities.export_html') }} <span class="text-muted float right">.html</span></a></li>
92 <li><a href="{{ $chapter->getUrl('/export/pdf') }}" target="_blank">{{ trans('entities.export_pdf') }} <span class="text-muted float right">.pdf</span></a></li>
93 <li><a href="{{ $chapter->getUrl('/export/plaintext') }}" target="_blank">{{ trans('entities.export_text') }} <span class="text-muted float right">.txt</span></a></li>
97 @if(userCan('page-create', $chapter))
98 <a href="{{ $chapter->getUrl('/create-page') }}" class="icon-list-item">
99 <span>@icon('add')</span>
100 <span>{{ trans('entities.pages_new') }}</span>
103 @if(userCan('chapter-update', $chapter))
104 <a href="{{ $chapter->getUrl('/edit') }}" class="icon-list-item">
105 <span>@icon('edit')</span>
106 <span>{{ trans('common.edit') }}</span>
109 @if(userCan('chapter-update', $chapter) && userCan('chapter-delete', $chapter))
110 <a href="{{ $chapter->getUrl('/move') }}" class="icon-list-item">
111 <span>@icon('folder')</span>
112 <span>{{ trans('common.move') }}</span>
115 @if(userCan('restrictions-manage', $chapter))
116 <a href="{{ $chapter->getUrl('/permissions') }}" class="icon-list-item">
117 <span>@icon('lock')</span>
118 <span>{{ trans('entities.permissions') }}</span>
121 @if(userCan('chapter-delete', $chapter))
122 <a href="{{ $chapter->getUrl('/delete') }}" class="icon-list-item">
123 <span>@icon('delete')</span>
124 <span>{{ trans('common.delete') }}</span>
133 @include('partials.entity-dashboard-search-box')
135 @if($chapter->tags->count() > 0)
137 @include('components.tag-list', ['entity' => $chapter])
141 @include('partials.book-tree', ['book' => $book, 'sidebarTree' => $sidebarTree])