World Map Widget by ZPMLabber
CommunityWorld map widget for statistics.
Author:
ZPMLabber
Package health
Automated checks of this plugin's Composer package
15 checks
- Failed: GitHub Actions pinned to SHA — View details on Plumb
- Skipped: GitLab CI includes pinned to SHA
- Passed: Open security advisories
- Passed: Dependabot PR responsiveness — No open Dependabot PRs.
- Skipped: Renovate MR responsiveness
- Failed: Dependabot or Renovate configured — No dependency updater configuration found. View details on Plumb
- Skipped: Dependency update cooldown configured
- Passed: Provides a security policy
- Passed: Abandoned or archived — No consulted source marks the package abandoned (packagist, github).
- Passed: Commit and release recency — Active: last commit 87 days ago; last release 87 days ago.
-
Passed:
composer.lock not committed by library
—
composer.lockis absent from the released dist archive. - Passed: Dist archive is lean
-
Passed:
Current Laravel version supported
—
Package dependencies resolve together with current Laravel
13.0. -
Passed:
Current PHP version supported
—
Constraint
^8.3supports current PHP8.5. - Skipped: Current Symfony version supported
filament/
namespace. Review the source and install at your own risk. Found
malware or an unresolved security issue the author won't
address?
Report it
.
Documentation
- Compatibility
- Installation
- Creating a widget
- Dashboard Filters
- Available Maps
- Customization
- Changelog
- Contributing
- Security Vulnerabilities
- Credits
- License
Display country-level statistics in a Filament widget powered by jsVectorMap.
#Compatibility
| Branch | Filament | PHP |
|---|---|---|
main |
^5.0 |
^8.3 |
v4 |
^4.0 |
^8.1 |
v3 |
^3.0 |
^8.1 |
#Installation
composer require infinityxtech/filament-world-map-widget
#Creating a widget
php artisan make:filament-map-widget VisitorGeoMap
Register the widget in a Filament dashboard or page:
use App\Filament\Widgets\VisitorGeoMap;
public function getWidgets(): array
{
return [
VisitorGeoMap::class,
];
}
#Dashboard Filters
The widget supports Filament dashboard filters, including live filters from HasFiltersForm. The map container remains protected with wire:ignore, while the widget root gets a checksum key so Livewire remounts the Alpine map when stats() or map options change.
namespace App\Filament\Widgets;
use Filament\Widgets\Concerns\InteractsWithPageFilters;
use InfinityXTech\FilamentWorldMapWidget\Widgets\WorldMapWidget;
class VisitorGeoMap extends WorldMapWidget
{
use InteractsWithPageFilters;
public function stats(): array
{
$range = $this->pageFilters['range'] ?? null;
return [
'US' => filled($range) ? 70000 : 35000,
'RS' => filled($range) ? 30000 : 15000,
];
}
}
namespace App\Filament\Pages;
use App\Filament\Widgets\VisitorGeoMap;
use Filament\Forms\Components\DatePicker;
use Filament\Pages\Dashboard as BaseDashboard;
use Filament\Pages\Dashboard\Concerns\HasFiltersForm;
use Filament\Schemas\Components\Section;
use Filament\Schemas\Schema;
class Dashboard extends BaseDashboard
{
use HasFiltersForm;
public function filtersForm(Schema $schema): Schema
{
return $schema
->components([
Section::make()
->schema([
DatePicker::make('range')
->label('Date range')
->live(),
])
->columns(2)
->columnSpanFull(),
]);
}
public function getWidgets(): array
{
return [
VisitorGeoMap::class,
];
}
}
#Available Maps
Map::WORLD
Map::WORLD_MERC
Map::US_MILL_EN
Map::US_MERC_EN
Map::US_LCC_EN
Map::US_AEA_EN
Map::SPAIN
Map::RUSSIA
Map::CANADA
Map::IRAQ
Map::BRASIL
#Customization
Override any of these methods in your widget:
use Illuminate\Contracts\Support\Htmlable;
use InfinityXTech\FilamentWorldMapWidget\Enums\Map;
public function stats(): array
{
return [
'US' => 35000,
'RS' => 15000,
];
}
public function heading(): string | Htmlable | null
{
return 'World Map';
}
public function tooltip(): string | Htmlable
{
return 'stats';
}
public function map(): Map | string
{
return Map::WORLD;
}
public function customMapUrl(): ?string
{
return null;
}
public function color(): array
{
return [0, 120, 215];
}
public function height(): string
{
return '332px';
}
public function additionalOptions(): array
{
return [];
}
To include a custom map, publish an accessible jsVectorMap map file and return both the map name and URL:
public function map(): Map | string
{
return 'custom-map';
}
public function customMapUrl(): ?string
{
return 'https://example.test/js/custom-map.js';
}
For more map options, see the jsVectorMap documentation.
#Changelog
Please see CHANGELOG for more information on what has changed recently.
#Contributing
Please see CONTRIBUTING for details.
#Security Vulnerabilities
Please review our security policy on how to report security vulnerabilities.
#Credits
#License
The MIT License (MIT). Please see License File for more information.
The author
From the same author
Popup
Livewire-powered popups from table columns.
Author:
ZPMLabber
Unlayer
This is a Filament field wrapper for the Unlayer editor.
Author:
ZPMLabber
Undraw Select
A Filament select component that lets you search & pick unDraw illustrations.
Author:
ZPMLabber
Play Room
PlayRoom is a lightweight, framework-agnostic game hub with filament adapter.
Author:
ZPMLabber
Featured Plugins
A selection of plugins curated by the Filament team
Noir Theme
A theme that gives panels a focused, refined look with near-black surfaces, crisp actions, and restrained color.
Filament
Custom Fields
Eliminate custom field migrations forever. Let your users create and manage form fields directly in Filament admin panels with 20+ built-in field types, validation, and zero database changes.
Relaticle
Blueprint
Filament Blueprint is a premium Laravel Boost extension that helps AI agents produce accurate, detailed implementation plans and security reports for Filament apps.
Filament