urlsnail/resources/views/components/bookmark.blade.php

28 lines
1010 B
PHP

<div class="bookmark">
<p class="bookmark-title">
{{ $bookmark->title }}
@if ($showPermalink)
<a href="{{ action('BookmarkController@show', $bookmark) }}">#</a>
@endif
@if ($showEdit)
<a href="{{ action('BookmarkController@edit', $bookmark) }}">e</a>
@endif
</p>
<p class="bookmark-href"><a href="{{ $bookmark->href }}">{{ $bookmark->href }}</a></p>
@if (!empty($bookmark->description))
<div class="bookmark-description">
<p>{!! nl2br(htmlspecialchars($bookmark->description)) !!}</p>
</div>
@endif
<p class="bookmark-date">
<time datetime="{{ $bookmark->created_at }}">{{ $bookmark->created_at->diffForHumans() }}</time>
</p>
<ul class="bookmark-tags">
@foreach ($bookmark->tags as $tag)
<li class="bookmark-tag">
<a href="{{ action('TagController@show', $tag) }}">{{ $tag->name }}</a>
</li>
@endforeach
</ul>
</div>