BookStack/resources/views/partials/entity-list-item.blade.php
Dan Brown 3eaf03a7ac
Reviewed tag in seach work
- Refactored some tag code bits while reviewing.
- Updated tag design in search listing to be more subtle.
- Moved tags out of entity-list-item-basic template and instead moved
  them into entity-list-item, below the existing content.
- Tweaked existing tag colors a little.
- Changed tag icon to be more tag-like.
- Added tag-on-search test case.

Review of #2487, Related to #2462
2021-05-24 16:12:09 +01:00

23 lines
788 B
PHP

@component('partials.entity-list-item-basic', ['entity' => $entity])
<div class="entity-item-snippet">
@if($showPath ?? false)
@if($entity->book_id)
<span class="text-book">{{ $entity->book->getShortName(42) }}</span>
@if($entity->chapter_id)
<span class="text-muted entity-list-item-path-sep">@icon('chevron-right')</span> <span class="text-chapter">{{ $entity->chapter->getShortName(42) }}</span>
@endif
@endif
@endif
<p class="text-muted break-text">{{ $entity->getExcerpt() }}</p>
</div>
@if(($showTags ?? false) && $entity->tags->count() > 0)
<div class="entity-item-tags mt-xs">
@include('components.tag-list', ['entity' => $entity, 'linked' => false ])
</div>
@endif
@endcomponent