28 lines
1.0 KiB
PHP
28 lines
1.0 KiB
PHP
|
|
@props([
|
||
|
|
'active' => 'tools',
|
||
|
|
'statusLabel' => '数据总量',
|
||
|
|
'statusValue' => 0,
|
||
|
|
'wrapperClass' => 'channel-head',
|
||
|
|
'tabsClass' => 'channel-tabs',
|
||
|
|
'statusClass' => 'channel-status',
|
||
|
|
])
|
||
|
|
|
||
|
|
@php
|
||
|
|
$tabs = [
|
||
|
|
['key' => 'tools', 'label' => 'AI工具集', 'url' => route('tools.index')],
|
||
|
|
['key' => 'models', 'label' => 'AI应用集', 'url' => route('models.index')],
|
||
|
|
['key' => 'news', 'label' => '每日AI资讯', 'url' => route('news.index')],
|
||
|
|
['key' => 'guides', 'label' => 'AI教程资源', 'url' => route('guides.index')],
|
||
|
|
['key' => 'tool-list', 'label' => '工具列表', 'url' => route('tools.list')],
|
||
|
|
];
|
||
|
|
@endphp
|
||
|
|
|
||
|
|
<header class="{{ $wrapperClass }}">
|
||
|
|
<nav class="{{ $tabsClass }}" aria-label="频道导航">
|
||
|
|
@foreach($tabs as $tab)
|
||
|
|
<a class="channel-tab @if($active === $tab['key']) active @endif" href="{{ $tab['url'] }}">{{ $tab['label'] }}</a>
|
||
|
|
@endforeach
|
||
|
|
</nav>
|
||
|
|
<div class="{{ $statusClass }}">{{ $statusLabel }} <b>{{ $statusValue }}</b></div>
|
||
|
|
</header>
|