@include('assignments::livewire.components.assignment-detail')
@if(!empty($assignmentDetail?->assignment?->description))
@php $fullDescription = $assignmentDetail?->assignment?->description; $shortDescription = Str::limit(strip_tags($fullDescription), 400, preserveWords: true); @endphp @if (Str::length(strip_tags($fullDescription)) > 400)

{!! $shortDescription !!} {{ __('general.show_more') }}

{!! $fullDescription !!} {{ __('general.show_less') }}
@else
{!! $fullDescription !!}
@endif
@endif @if($assignmentDetail->assignment?->type == 'text' || $assignmentDetail->assignment?->type == 'both')
{{__('assignments::assignments.max_character_limit', ['limit' => $assignmentDetail->assignment?->characters_count]) }}
@endIf @if($assignmentDetail->assignment?->type == 'document' || $assignmentDetail->assignment?->type == 'both')
{{__('assignments::assignments.max_attachments', ['limit' => $assignmentDetail->assignment?->max_file_count]) }}
@if(!empty($existingAttachments))
@foreach($existingAttachments as $key => $single)
@php if ($single instanceof Livewire\Features\SupportFileUploads\TemporaryUploadedFile) { $mimeType = $single->getMimeType() ?? ''; $fileName = $single->getClientOriginalName(); $fileSize = $single->getSize(); } else { $mimeType = $single->type ?? ''; $fileName = $single->name ?? 'Unknown File'; $fileSize = Storage::disk(getStorageDisk())->size($single->path) ?? 0; } @endphp @if(Str::startsWith($mimeType, 'image')) @else @endif
{{ $fileName }} {{ humanFilesize($fileSize) }}
@endforeach
@endif
@endIf
@push('styles') @vite([ 'public/summernote/summernote-lite.min.css', ]) @endpush @push('scripts') @endpush