Download the PHP package speniti/filament-mapbox without Composer
On this page you can find all versions of the php package speniti/filament-mapbox. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download speniti/filament-mapbox
More information about speniti/filament-mapbox
Files in speniti/filament-mapbox
Package filament-mapbox
Short Description A set of tools for integrating Mapbox within the Filament ecosystem.
License MIT
Informations about the package filament-mapbox
Filament Mapbox
This package provides a set of tools for integrating Mapbox within the Filament ecosystem.
Getting started
Prerequisites
This package has been built for Filament 3 and has been tested only with PHP 8.4 and Laravel 12.
Installation
The package can be installed using Composer with the following command:
Usage
Geocoder Form Component
A geocoder component using the Mapbox Geocoding API. It Can be used in a form to search for an addresses.
Basic Usage
To search for an address, you can use it without any option:
Options
The component can be customized with the following options:
See FeatureType.php for available types.
Aside from the custom options, the component supports placeholder, affixes and suffixes and can be disabled.
The only validation rule supported is required
.
Localization
The component supports localization. The applied language will depend on the browser's language settings.
Output formats
Depending on how you typehint the form property associated with the component, you can get the output in different formats.
For instance if you typehint string
you will get the address as a string:
In a similar way, if you typehint array
you will get an associative array with the address parts:
Lastly, if you prefer a DTO-like approach,
you can typehint AddressInfo
and you will get an instance of the AddressInfo class:
Contributing
Thank you for considering contributing to Filament Mapbox! You can read the contribution guide here.
Code of Conduct
To ensure that the community is welcoming to all, please review and abide by the Code of Conduct.
License
Filament Mapbox is open-sourced software licensed under the MIT license.