{{-- resources/views/news/show.blade.php --}} @extends('layouts.app') @section('css') @endsection @section('js') @endsection @push('pageTitle') {{ __('labels.document') }} @endpush @section('content') @include('components.common.page-header', [ 'pageTitle' => __('labels.document'), 'actionButton' => [ 'url' => route('documents.index'), 'text' => __('labels.back_to_list'), ], ]) {{-- News Header --}}
{{--

{{ $document->title }}

--}}

{{ $document->title }}

{{-- Quick Actions --}}
@can('update', $document) @endcan @can('delete', $document) @endcan
{{-- METADATA CARDS --}}
{{-- Type Card --}}
{{ __('labels.type') }}
@php $type = old('type', $document->type ?? 'all'); $badgeColors = [ 'all' => 'bg-primary', 'image' => 'bg-info', 'document' => 'bg-success', 'video' => 'bg-warning' ]; $colorClass = $badgeColors[$type] ?? 'bg-primary'; @endphp @if($type == 'all') @elseif($type == 'image') @elseif($type == 'document') @elseif($type == 'video') @endif
@if($type == 'all') {{ __('labels.all_files') }} @elseif($type == 'image') {{ __('labels.images') }} @elseif($type == 'document') {{ __('labels.documents_type') }} @elseif($type == 'video') {{ __('labels.videos') }} @endif
@if($document->category)
{{ __('labels.category') }}
{{ $document->category?->title }} {{-- @if($post->category?->description) {{ Str::limit($post->category?->description, 30, '...') }} @endif --}}
@endif
{{ __('labels.status') }}
{{ $document->is_published ? __('labels.published') : __('labels.draft') }}
@if ($document->description)
{{ __('labels.description') }}
{!! nl2br(e($document->description)) !!}
@endif @if(isset($selectedUrls) && count($selectedUrls)) @include('components.form.url-links-manage', [ 'readonly' => isset($readonly) && $readonly ? 1 : 0, 'urlList' => old('urls', isset($selectedUrls) && count($selectedUrls) ? $selectedUrls : null), ]) @endif {{-- Attachments Section --}} @isset($document->assets) @include('components.form.file-manager.uploaded-files', [ 'readonly' => isset($readonly) && $readonly, 'assets' => $document->assets, ]) @endisset {{-- Groups Section --}} {{-- @if ($document->groups->count() > 0) @include('components.form.view-selected-groups',[ 'groups' => $document->groups ]) @endif --}} @include('components.meta.stats',[ 'created_at' => $document->created_at ?? null, 'updated_at' => $document->updated_at ?? null, 'published_at' => $document->published_at ?? null, 'is_published' => $document->is_published ?? null, 'creater' => $document->author_name ?? null, ]) @endsection