承接 quix-labs/filament-extendable 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

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

quix-labs/filament-extendable

最新稳定版本:v0.0.1-alpha.5

Composer 安装命令:

composer require quix-labs/filament-extendable

包简介

Extend Filament's form, table and infolist builders dynamically using a modular and composable system.

README 文档

README

Latest Version on Packagist GitHub Tests Action Status Total Downloads

Filament Extendable is a powerful extension toolkit for FilamentPHP, enabling highly composable and dynamic customization of tables, forms, and infolists — all without touching core logic.

🚩 Important Notice

This library is under active development. APIs and features may evolve. Contributions and feedback are highly appreciated.

Features

  • Dynamic registration of modifiers for forms, tables, and infolists
  • Insert components before or after existing ones
  • Remove components by key
  • Full compatibility with filament:make-* commands
  • Minimal interference with native Filament lifecycle

Requirements

  • PHP ^8.2
  • Laravel ^11.x || ^12.x
  • Filament ^4.0

📦 Installation

composer require quix-labs/filament-extendable

If needed, register the service provider (usually auto-discovered):

// config/app.php
'providers' => [
    // ...
    QuixLabs\FilamentExtendable\FilamentExtendableServiceProvider::class,
],

Usage

1. Enable Extensibility in Your Resource

Wrap your resource schema and tables with the builders:

use QuixLabs\FilamentExtendable\Facades\FilamentExtendable;

class UserResource extends Resource
{
    public static function form(Schema $schema): Schema
    {
        return FilamentExtendable::processSchema($schema, 'user-form');
    }

    public static function infolist(Schema $schema): Schema
    {
        return FilamentExtendable::processSchema($schema, 'user-infolist');
    }

    public static function table(Table $table): Table
    {
        return FilamentExtendable::processTable($table, 'user-table');
    }
}

2. Register Modifiers

Define dynamic modifiers in the boot function of your service provider:

use QuixLabs\FilamentExtendable\Builders\TableBuilder;
use QuixLabs\FilamentExtendable\Builders\SchemaBuilder;
use QuixLabs\FilamentExtendable\Facades\FilamentExtendable;
use Filament\Tables\Columns\TextColumn;
use Filament\Forms\Components\TextInput;
use Filament\Infolists\Components\TextEntry;

class FilamentExtendServiceProvider extends ServiceProvider
{
    public function boot(): void
    {
        // Insert a column after 'email' in the user table
        FilamentExtendable::addTableModifier('user-table', function (TableBuilder $tableBuilder) {
            $tableBuilder->insertAfter('email', [
                TextColumn::make('lastname')->label('Last Name'),
            ]);
        });

        // Add a field to the user infolist
        FilamentExtendable::addSchemaModifier('user-infolist', function (SchemaBuilder $schemaBuilder) {
            $schemaBuilder->pushComponents([
                TextEntry::make('lastname')->label('Last Name'),
            ]);
        });
    }
}

3. Schema Manipulations

Insert component in schema

Push components at root or inside nested groups via dot notation:

Control insertion with:

  • position'before' or 'after' relative to a target key
  • targetKey — component key near which to insert
  • targetGroup — dot notation path to nested group
// Append at root level (default behavior)
$schemaBuilder->pushComponents([
    TextInput::make('nickname')->label('Nickname'),
]);

// After 'bio' at root level
$schemaBuilder->pushComponents([
    TextArea::make('additional_notes'),
], position: InsertPosition::AFTER, targetKey: 'bio');

// Before 'email' at root level
$schemaBuilder->pushComponents([
    Select::make('preferred_contact_method'),
], position: InsertPosition::BEFORE, targetKey: 'email');

// After 'last_login' in 'tabs.activity' nested tab/section/group/...
$schemaBuilder->pushComponents([
    TextEntry::make('last_login_ip')->label('Last Login IP'),
], position: InsertPosition::AFTER, targetKey: 'last_login', targetGroup: 'tabs.activity');

Delete Components from Schema

You can remove components from both the root level and nested groups using their keys.

If a specified key is not found, the operation is silently skipped (no error thrown).

$schemaBuilder->removeComponents([
    'email', // Removes 'email' field from the root level
    'tabs.seo.meta_title', // Dot notation is supported for nested paths.
]);

Integration with Filament Artisan Commands

Filament Extendable patches the following commands to scaffold extendable resources automatically:

php artisan make:filament-resource User
php artisan make:filament-table UserTable
php artisan make:filament-form UserForm
php artisan make:filament-schema UserSchema

They generate boilerplate code that includes calls to FilamentExtendable::processSchema() and FilamentExtendable::processTable(), ready for modifier registration.

💡 This allows you to plug in modifiers immediately, without writing boilerplate.

Why this exists

Filament is an exceptional tool, but there are scenarios where additional dynamic control is needed:

  • Modular package systems needing to inject UI logic
  • Enterprise-grade systems with conditional rendering needs
  • Reusable and declarative customizations across multiple resources

Filament Extendable solves this with a non-intrusive, declarative API.

Changelog

Please see CHANGELOG for more information on what has changed recently.

🤝 Contributing

We welcome your contributions!

  1. Fork the repository.
  2. Create a new branch for your feature or bugfix.
  3. Commit your changes.
  4. Push your branch.
  5. Create a pull request.

Credits

License

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

quix-labs/filament-extendable 适用场景与选型建议

quix-labs/filament-extendable 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 1 次下载、GitHub Stars 达 0, 最近一次更新时间为 2025 年 06 月 28 日, 在 PHP 生态内属于活跃度较高的组件。

它主要适用于以下技术方向: 「extendable」 「laravel」 「modular」 「filament」 等业务场景。在实际项目中,围绕这些方向常见需要落地的问题包括:接口对接、性能调优、并发安全、与既有框架(Laravel / ThinkPHP / Yii / Webman 等)的兼容适配,以及生产环境的日志埋点与稳定性保障。

我们在过去多个企业项目中使用过 quix-labs/filament-extendable 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。

围绕 quix-labs/filament-extendable 我们能提供哪些服务?
定制开发 / 二次开发

基于 quix-labs/filament-extendable 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。

BUG 修复 & 性能优化

线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。

项目外包 & 长期维护

承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。

yvsm@zunyunkeji.com QQ:316430983 微信:yvsm316 西安尊云信息科技 · 专注 PHP / Go / 分布式系统研发

统计信息

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

GitHub 信息

  • Stars: 0
  • Watchers: 0
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2025-06-28