Download the PHP package amarafiif/filament-lost-connection without Composer

On this page you can find all versions of the php package amarafiif/filament-lost-connection. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package filament-lost-connection

Filament Lost Connection

A beautiful and customizable network connection status indicator for Laravel Filament applications. This plugin automatically detects when users lose internet connectivity and displays a non-intrusive notification.

Features

Installation

You can install the package via Composer:

Configuration

Option 1: Using Configuration File (Recommended)

Publish the configuration file:

This will create a config/filament-lost-connection.php file where you can customize all settings:

Option 2: Using Fluent API

Register the plugin in your Filament Panel Provider (e.g., app/Providers/Filament/AdminPanelProvider.php):

Usage Examples

Basic Usage

Custom Messages

Custom Styling

Custom Ping URL

Environment Variables

You can also configure the plugin using environment variables in your .env file:

Configuration Options

Option Type Default Description
position string 'bottom' Position of indicator ('top' or 'bottom')
lostConnectionText string 'You are disconnected.' Message when connection is lost
connectedText string 'You are back online.' Message when connection is restored
lostConnectionColor string '#991b1b' Background color when offline
connectedColor string '#065f46' Background color when back online
checkInterval int 3000 Check interval in milliseconds
icon string 'heroicon-o-exclamation-triangle' Icon component to display
pingUrl string null Custom URL to ping (defaults to domain favicon)

How It Works

The plugin uses multiple methods to detect connectivity:

  1. Browser Events: Listens to online and offline events
  2. HTTP Requests: Periodically sends HEAD requests to check connectivity
  3. Navigator API: Falls back to navigator.onLine as a backup

Ping URL Options

Customization

Custom Views

You can publish and customize the views:

This will publish the views to resources/views/vendor/filament-lost-connection/.

Styling

The component uses Tailwind CSS classes and can be easily customized through the color options or by modifying the published views.

Troubleshooting

Plugin Not Showing

  1. Make sure you've registered the plugin in your Panel Provider
  2. Check that the plugin is using the correct render hook: panels::body.end
  3. Ensure your views are properly loaded by the service provider

Connection Check Not Working

  1. Verify your pingUrl is accessible and returns a successful response
  2. Check browser console for any CORS issues
  3. Try different ping URLs if the default doesn't work in your environment

Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

License

The MIT License (MIT). Please see License File for more information.

Credits

Support

If you find this package helpful, please consider giving it a ⭐ on GitHub!


All versions of filament-lost-connection with dependencies

PHP Build Version
Package Version
Requires php Version >=8.1
illuminate/support Version ^10.0|^11.0
illuminate/view Version ^10.0|^11.0
filament/filament Version ^3.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package amarafiif/filament-lost-connection contains the following files

Loading the files please wait ...