laravilt / widgets
Complete dashboard widget system with stats, charts, and custom widgets. Display key metrics and data visualizations with stats overview, line/bar/pie charts, and beautiful responsive widgets for dashboards.
Fund package maintenance!
fadymondy
Installs: 73
Dependents: 1
Suggesters: 0
Security: 0
Stars: 0
Watchers: 0
Forks: 0
Open Issues: 0
Language:Vue
pkg:composer/laravilt/widgets
Requires
- php: ^8.3|^8.4
- laravilt/support: ^1.0
- spatie/laravel-package-tools: ^1.14
Requires (Dev)
- larastan/larastan: ^2.9||^3.0
- laravel/pint: ^1.14
- nunomaduro/collision: ^8.1.1||^7.10.0
- orchestra/testbench: ^10.0
- pestphp/pest: ^3.0
- pestphp/pest-plugin-arch: ^3.0
- pestphp/pest-plugin-laravel: ^3.0
- pestphp/pest-plugin-livewire: ^3.0
- pestphp/pest-plugin-type-coverage: ^3.5
- phpstan/extension-installer: ^1.3||^2.0
- phpstan/phpstan-deprecation-rules: ^1.1||^2.0
- phpstan/phpstan-phpunit: ^1.3||^2.0
This package is auto-updated.
Last update: 2025-12-17 17:18:39 UTC
README
Laravilt Widgets
Complete dashboard widget system with stats, charts, and custom widgets for Laravilt. Display key metrics and data visualizations with beautiful, responsive widgets.
Features
- 📊 Stats Overview - Display key metrics with trends and mini charts
- 📈 Line Charts - Area and line charts with multiple datasets
- 📊 Bar Charts - Vertical/horizontal bars with stacking
- 🥧 Pie Charts - Pie and doughnut with percentage legends
- 🔄 Auto-Polling - Real-time data updates
- 🎨 Customization - Colors, themes, icons
- 📱 Responsive - Mobile-friendly layouts
Widget Types
| Widget | Description |
|---|---|
StatsOverviewWidget |
Multiple stats in responsive grid |
LineChartWidget |
Line/area charts with trends |
BarChartWidget |
Vertical/horizontal bar charts |
PieChartWidget |
Pie and doughnut charts |
Quick Examples
Stats Overview
use Laravilt\Widgets\StatsOverviewWidget; use Laravilt\Widgets\Stat; StatsOverviewWidget::make() ->columns(4) ->stats([ Stat::make('Revenue', fn() => '$' . number_format(Order::sum('total'), 2)) ->description('+12% from yesterday') ->descriptionIcon('TrendingUp', 'success') ->icon('DollarSign') ->color('success'), Stat::make('Orders', fn() => Order::count()) ->description('Completed today') ->icon('ShoppingCart') ->color('primary') ->chart('bar', [8, 12, 15, 18, 22], 'primary'), ]) ->polling(30); // Refresh every 30 seconds
Line Chart
use Laravilt\Widgets\LineChartWidget; LineChartWidget::make( labels: ['Jan', 'Feb', 'Mar', 'Apr', 'May'], datasets: [[ 'label' => 'Sales', 'data' => [4500, 5200, 4800, 6100, 5900], 'borderColor' => 'rgb(34, 197, 94)', ]] ) ->heading('Revenue Trend') ->curved() ->fill() ->height(350);
Pie Chart
use Laravilt\Widgets\PieChartWidget; PieChartWidget::make( labels: ['Featured', 'Regular'], data: [150, 350] ) ->heading('Product Distribution') ->doughnut() ->showLegend() ->showPercentage();
Installation
composer require laravilt/widgets
Generator Commands
php artisan make:widget UserStatsWidget --stats php artisan make:widget SalesChartWidget --chart=line php artisan make:widget RevenueChartWidget --chart=bar php artisan make:widget CategoryChartWidget --chart=pie
Documentation
- Complete Documentation - All widget types and configuration
- MCP Server Guide - AI agent integration
License
The MIT License (MIT). Please see License File for more information.
