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

{{ $checklist->title }}

--}}

{{ $checklist->title }}

{{-- Quick Actions --}}
@can('update', $checklist) @endcan @can('delete', $checklist) @endcan
{{-- METADATA CARDS --}}
{{-- Type Card --}}
{{ __('labels.type') }}
@php $type = old('type', $checklist->type ?? 'all'); $badgeColors = [ 'all' => 'bg-primary', 'image' => 'bg-info', 'checklist' => 'bg-success', 'video' => 'bg-warning' ]; $colorClass = $badgeColors[$type] ?? 'bg-primary'; @endphp @if($type == 'all') @elseif($type == 'image') @elseif($type == 'checklist') @elseif($type == 'video') @endif
@if($type == 'all') {{ __('labels.all_files') }} @elseif($type == 'image') {{ __('labels.images') }} @elseif($type == 'checklist') {{ __('labels.checklists_type') }} @elseif($type == 'video') {{ __('labels.videos') }} @endif
@if($checklist->category)
{{ __('labels.category') }}
{{ $checklist->category?->title }} {{-- @if($checklist->category?->description) {{ Str::limit($checklist->category?->description, 30, '...') }} @endif --}}
@endif
{{ __('labels.status') }}
{{ $checklist->is_published ? __('labels.published') : __('labels.draft') }}
@include('components.common.saveable', [ 'saveableType' => 'checklist', 'saveableId' => $checklist->id, 'isSaved' => auth()->check() ? $checklist->isSavedByUser(auth()->id()) : false, 'saveCounts' => $checklist->saves_count ?? $checklist->saves()->count(), ]) @include('components.common.favorable', [ 'favorableType' => 'checklist', 'favorableId' => $checklist->id, 'isFavorited' => auth()->check() ? $checklist->isFavoritedByUser(auth()->id()) : false, 'favoriteCounts' => $checklist->favorites_count ?? $checklist->favorites()->count(), ])
@if ($checklist->description)
{{ __('labels.description') }}
{!! nl2br(e($checklist->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($checklist->assets) @include('components.form.file-manager.uploaded-files', [ 'readonly' => isset($readonly) && $readonly, 'assets' => $checklist->assets, ]) @endisset {{-- Groups Section --}} {{-- @if ($checklist->groups->count() > 0) @include('components.form.view-selected-groups',[ 'groups' => $checklist->groups ]) @endif --}} @include('components.meta.stats',[ 'created_at' => $checklist->created_at ?? null, 'updated_at' => $checklist->updated_at ?? null, 'published_at' => $checklist->published_at ?? null, 'is_published' => $checklist->is_published ?? null, 'creater' => $checklist->creator->name ?? null, 'creator_avatar' => $checklist->creator->profile_image ?? null, ]) @endsection