定制 borjajimnz/text-input-autocomplete 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

borjajimnz/text-input-autocomplete

最新稳定版本:1.5.3

Composer 安装命令:

composer require borjajimnz/text-input-autocomplete

包简介

Filamentphp TextInput with Autocomplete feature

README 文档

README

Latest Version on Packagist GitHub Code Style Action Status Total Downloads

This package replaces the native <datalist> functionality with a custom, non-native autocomplete for the TextInput component in FilamentPHP 3, offering enhanced flexibility and customization options.

Installation

You can install the package via composer:

composer require borjajimnz/text-input-autocomplete

Usage

By default, we will use a non-native datalist. If you want to use the native one, simply add ->datalistNative().

Use the Tab key to navigate through the available options in the datalist, or move around using the Up and Down arrow keys.

use Borjajimnz\TextInputAutocomplete\Forms\Components\AutoComplete;

AutoComplete::make('favorite')
    ->datalist(function () {
        return ['php','laravel', 'livewire','filamentphp', 'tailwindcss'];
    });

These are all the options available to configure your field, if needed.

use Borjajimnz\TextInputAutocomplete\Forms\Components\AutoComplete;

AutoComplete::make('favorite')
    ->datalistNative(false)
    ->datalistMinCharsToSearch(0)
    ->datalistMaxItems(false)
    ->datalistDisableScroll(false)
    ->datalistOpenOnClick(true)
    ->datalist(function () {
        return ['php','laravel', 'livewire','filamentphp', 'tailwindcss'];
    });

Or if you want to use the native datalist with a custom ID.

use Borjajimnz\TextInputAutocomplete\Forms\Components\AutoComplete;

AutoComplete::make('favorite')
    ->datalistNativeId('customized.id')
    ->datalist(function () {
        return ['php','laravel', 'livewire','filamentphp', 'tailwindcss'];
    });

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.

统计信息

  • 总下载量: 303
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 1
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 1
  • Watchers: 1
  • Forks: 0
  • 开发语言: Blade

其他信息

  • 授权协议: MIT
  • 更新时间: 2025-01-08