44 lines
2.1 KiB
PHP
44 lines
2.1 KiB
PHP
<div>
|
|
@isset($post)
|
|
<div class="modal fade show d-block bg-dark" style="--bs-bg-opacity: .5;z-index:3000" id="postCardModal" data-bs-backdrop="static"
|
|
data-bs-keyboard="false" tabindex="-1" aria-labelledby="staticBackdropLabel" aria-hidden="true">
|
|
<div class="modal-dialog modal-lg modal-fullscreen-lg-down">
|
|
<div class="modal-content">
|
|
<div class="modal-header border-0">
|
|
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"
|
|
wire:click="close"></button>
|
|
</div>
|
|
<div class="modal-body">
|
|
@if ($post->image)
|
|
<div class="w-100"
|
|
style="
|
|
height:250px;
|
|
background-image:url('{{ $post->image }}');
|
|
background-position: center;
|
|
background-repeat: no-repeat;
|
|
background-size: cover; ">
|
|
</div>
|
|
@endif
|
|
<div class="mt-2 d-flex justify-content-between align-items-center">
|
|
<h1 class="flex-fill">{{ $post->name }}</h1>
|
|
<div class="ms-auto hstack gap-2">
|
|
@can('update', $post)
|
|
@livewire('post.form', ['post' => $post])
|
|
@endcan
|
|
@can('delete', $post)
|
|
<form action="{{ route('admin.posts.delete', $post) }}" method="POST" onsubmit="return confirm('Вы уверены?')">
|
|
@csrf
|
|
<button type="submit" class="btn btn-danger"><i class="bi bi-x-lg"></i></button>
|
|
</form>
|
|
@endcan
|
|
</div>
|
|
</div>
|
|
<p>
|
|
{!! $post->trixRender('content') !!}
|
|
</p>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
@endisset
|
|
</div> |