Jenis Peraturan: {{ $jenis }}
Tahun: {{ $tahun }}
Total Dokumen: {{ $total }} dokumen
Tanggal Cetak: {{ $tanggal_cetak }}
| No | Judul | Tanggal Ditetapkan | Tanggal Diundangkan | Status | Keterangan Status |
|---|---|---|---|---|---|
| {{ $index + 1 }} |
{{ $doc->kategori_nama }} Nomor {{ $doc->no_peraturan }} Tahun {{ $doc->tahun_diundang }} @php $content = strip_tags($doc->content); $content = trim($content); // Clean up extra whitespace $content = preg_replace('/\s+/', ' ', $content); @endphp {{ $content }} |
@if($doc->tgl_ditetap) {{ \Carbon\Carbon::parse($doc->tgl_ditetap)->format('d/m/Y') }} @else - @endif | @if($doc->tgl_diundang) {{ \Carbon\Carbon::parse($doc->tgl_diundang)->format('d/m/Y') }} @else - @endif | @if($doc->status == 1) Berlaku @else Tidak Berlaku @endif |
@if(!empty($doc->file_custom_status) && trim($doc->file_custom_status) !== '')
@php
// Clean and format the text
$cleanText = strip_tags($doc->file_custom_status);
$cleanText = trim($cleanText);
// Replace multiple spaces with single space
$cleanText = preg_replace('/\s+/', ' ', $cleanText);
// Add line breaks for better readability if text is very long
if (strlen($cleanText) > 100) {
// Split long sentences at logical points
$cleanText = preg_replace('/([.!?])\s+/', '$1 ', $cleanText); // Break very long sentences without punctuation $cleanText = preg_replace('/(.{80,100})\s+/', '$1 ', $cleanText); } @endphp
{!! $cleanText !!}
@else
{{-- Empty space when keterangan status is not filled --}}
@endif
|