]> BookStack Code Mirror - bookstack/blob - resources/views/chapters/list-item.blade.php
Implement the renderPages parameter
[bookstack] / resources / views / chapters / list-item.blade.php
1 <a href="{{ $chapter->getUrl() }}" class="chapter entity-list-item @if($chapter->hasChildren()) has-children @endif" data-entity-type="chapter" data-entity-id="{{$chapter->id}}">
2     <span class="icon text-chapter">@icon('chapter')</span>
3     <div class="content">
4         <h4 class="entity-list-item-name break-text">{{ $chapter->name }}</h4>
5         <div class="entity-item-snippet">
6             <p class="text-muted break-text mb-s">{{ $chapter->getExcerpt() }}</p>
7         </div>
8     </div>
9 </a>
10 @if ($chapter->hasChildren())
11     <div class="chapter chapter-expansion">
12         <span class="icon text-chapter">@icon('page')</span>
13         <div class="content">
14             <button type="button" chapter-toggle
15                     aria-expanded="false"
16                     class="text-muted chapter-expansion-toggle">@icon('caret-right') <span>{{ trans_choice('entities.x_pages', $chapter->pages->count()) }}</span></button>
17             <div class="inset-list">
18                 <div class="entity-list-item-children">
19                     @include('partials.entity-list', ['entities' => $chapter->pages])
20                 </div>
21             </div>
22         </div>
23     </div>
24 @endif