{{-- resources/views/wiki/index.blade.php --}} @extends('library.wiki.layouts.app') @section('title', 'WikiPāli · ' . __('library.wiki_encyclopedia')) @section('wiki-content') {{-- 搜索框组件 --}}
{{-- 今日条目 --}} @isset($today)
{{ __('library.today_entry') }}
{{ $today['meaning'] }}({{ $today['word'] }})
{!! Str::limit(strip_tags($today['content']), 120) !!}
{{ __('library.read_full_entry') }}
@endisset {{-- 精选条目 --}} @if(isset($featured) && is_array($featured) && count($featured)>0)
{{ __('library.featured_entries') }}
@endif @if(isset($subs) && is_array($subs) && count($subs) > 0) {{-- 取一级分类名称作为标题 --}} @php $catLabel = collect(config('taxonomy'))->firstWhere('id', $category)['label'] ?? $category; @endphp
{{ $catLabel }} {{ __('library.view_all') }}
@foreach ($subs as $sub) @endforeach
@endif @endsection @section('wiki-sidebar')
{{ __('library.statistics') }}
{{ __('library.total_entries') }} {{ number_format($stats['total']) }}
{{ __('library.this_month') }} {{ $stats['this_month'] }}
{{ __('library.contributors') }} {{ $stats['contributors'] }}
{{ __('library.quality_level') }}
@endsection