<?php

namespace App\Filament\Resources\KnowledgePointResource\Widgets;

use App\Models\KnowledgePoint;
use Filament\Widgets\StatsOverviewWidget as BaseWidget;
use Filament\Widgets\StatsOverviewWidget\Stat;

class KnowledgePointStats extends BaseWidget
{
    protected function getStats(): array
    {
        return [
            Stat::make('知识点总数', KnowledgePoint::query()->count()),
        ];
    }
}
