Token导航 LogoToken导航TokenDH.com
研究检索只读github未标认证来源可访问许可证需确认审计通过

filament-resource灯丝资源

Agent Skill

filament-resource 用于查找、检索和筛选相关信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

总安装

28,224

周安装

1,220

GitHub Stars

29

下载量

9,888
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

unknown

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:filament-resource(灯丝资源)
来源仓库:https://github.com/mwguerra/claude-code-plugins
仓库路径:skills/filament-resource
安装命令:
npx skills add https://github.com/mwguerra/claude-code-plugins --skill filament-resource
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/mwguerra/claude-code-plugins --skill filament-resource

简介

包含表单、表格、关系管理器和自定义页面的完整 FilamentPHP v4 资源。

  • 按照官方 FilamentPHP 文档模式生成具有表单架构、表配置和页面路由的资源类
  • 通过 artisan 命令支持资源变体,包括软删除、仅查看页面和简单的基于模式的表单
  • 包括 20 多种表单字段类型(文本输入、选择器、日期/时间选择器、文件上传、关系字段)和 5 种以上表格列类型,带有用于搜索、排序和可见性切换的修饰符
  • 处理关系管理器以管理模型关系和访问控制的授权策略

SKILL.md

FilamentPHP Resource Generation Skill

Overview

This skill generates complete FilamentPHP v4 resources including form schemas, table configurations, relation managers, and custom pages. All generated code follows official documentation patterns.

Documentation Reference

CRITICAL: Before generating any resource, read:

  • /home/mwguerra/projects/mwguerra/claude-code-plugins/filament-specialist/skills/filament-docs/references/general/03-resources/
  • /home/mwguerra/projects/mwguerra/claude-code-plugins/filament-specialist/skills/filament-docs/references/forms/
  • /home/mwguerra/projects/mwguerra/claude-code-plugins/filament-specialist/skills/filament-docs/references/tables/

Workflow

Step 1: Gather Requirements

Identify:

  • Model name and namespace
  • Fields to include in form
  • Columns to display in table
  • Relationships to manage
  • Custom actions needed
  • Authorization requirements

Step 2: Generate Base Resource

Use Laravel artisan to create the resource:

# Basic resource
php artisan make:filament-resource ModelName

# With generate flag (creates form/table from model)
php artisan make:filament-resource ModelName --generate

# Soft deletes support
php artisan make:filament-resource ModelName --soft-deletes

# View page only
php artisan make:filament-resource ModelName --view

# Simple resource (modal forms instead of pages)
php artisan make:filament-resource ModelName --simple

Step 3: Customize Form Schema

Read form field documentation and implement:

use Filament\Forms;
use Filament\Forms\Form;

public static function form(Form $form): Form
{
    return $form
        ->schema([
            Forms\Components\Section::make('Basic Information')
                ->schema([
                    Forms\Components\TextInput::make('name')
                        ->required()
                        ->maxLength(255),
                    Forms\Components\Textarea::make('description')
                        ->rows(3)
                        ->columnSpanFull(),
                ]),
            Forms\Components\Section::make('Settings')
                ->schema([
                    Forms\Components\Toggle::make('is_active')
                        ->default(true),
                    Forms\Components\Select::make('status')
                        ->options([
                            'draft' => 'Draft',
                            'published' => 'Published',
                        ]),
                ]),
        ]);
}

Step 4: Customize Table

Read table documentation and implement:

use Filament\Tables;
use Filament\Tables\Table;

public static function table(Table $table): Table
{
    return $table
        ->columns([
            Tables\Columns\TextColumn::make('name')
                ->searchable()
                ->sortable(),
            Tables\Columns\IconColumn::make('is_active')
                ->boolean(),
            Tables\Columns\BadgeColumn::make('status')
                ->colors([
                    'warning' => 'draft',
                    'success' => 'published',
                ]),
            Tables\Columns\TextColumn::make('created_at')
                ->dateTime()
                ->sortable()
                ->toggleable(isToggledHiddenByDefault: true),
        ])
        ->filters([
            Tables\Filters\SelectFilter::make('status')
                ->options([
                    'draft' => 'Draft',
                    'published' => 'Published',
                ]),
            Tables\Filters\TernaryFilter::make('is_active'),
        ])
        ->actions([
            Tables\Actions\ViewAction::make(),
            Tables\Actions\EditAction::make(),
            Tables\Actions\DeleteAction::make(),
        ])
        ->bulkActions([
            Tables\Actions\BulkActionGroup::make([
                Tables\Actions\DeleteBulkAction::make(),
            ]),
        ]);
}

Step 5: Add Relation Managers

For relationships, create relation managers:

php artisan make:filament-relation-manager ResourceName RelationName column_name

Register in resource:

public static function getRelations(): array
{
    return [
        RelationManagers\CommentsRelationManager::class,
        RelationManagers\TagsRelationManager::class,
    ];
}

Step 6: Configure Pages

Define resource pages:

public static function getPages(): array
{
    return [
        'index' => Pages\ListModels::route('/'),
        'create' => Pages\CreateModel::route('/create'),
        'view' => Pages\ViewModel::route('/{record}'),
        'edit' => Pages\EditModel::route('/{record}/edit'),
    ];
}

Step 7: Add Authorization

Implement policy methods:

public static function canViewAny(): bool
{
    return auth()->user()->can('view_any_model');
}

public static function canCreate(): bool
{
    return auth()->user()->can('create_model');
}

Form Field Reference

Text Fields

  • TextInput::make() - Single line text
  • Textarea::make() - Multi-line text
  • RichEditor::make() - WYSIWYG editor
  • MarkdownEditor::make() - Markdown editor

Selection Fields

  • Select::make() - Dropdown select
  • Radio::make() - Radio buttons
  • Checkbox::make() - Single checkbox
  • CheckboxList::make() - Multiple checkboxes
  • Toggle::make() - Toggle switch

Date/Time Fields

  • DatePicker::make() - Date only
  • DateTimePicker::make() - Date and time
  • TimePicker::make() - Time only

File Fields

  • FileUpload::make() - File upload
  • SpatieMediaLibraryFileUpload::make() - Media library

Relationship Fields

  • Select::make()->relationship() - BelongsTo select
  • CheckboxList::make()->relationship() - BelongsToMany
  • Repeater::make()->relationship() - HasMany inline

Layout Components

  • Section::make() - Card section
  • Fieldset::make() - Fieldset grouping
  • Tabs::make() - Tabbed sections
  • Grid::make() - Grid layout
  • Split::make() - Split layout

Table Column Reference

Text Columns

  • TextColumn::make() - Basic text
  • IconColumn::make() - Boolean icon
  • ImageColumn::make() - Image thumbnail
  • BadgeColumn::make() - Badge styling
  • ColorColumn::make() - Color swatch

Column Modifiers

  • ->searchable() - Enable search
  • ->sortable() - Enable sort
  • ->toggleable() - Can hide/show
  • ->wrap() - Wrap text
  • ->limit() - Truncate text

Output

For each resource, generate:

  1. Resource class - app/Filament/Resources/ModelResource.php
  2. Pages - app/Filament/Resources/ModelResource/Pages/
  3. Relation Managers - app/Filament/Resources/ModelResource/RelationManagers/
  4. Test file - tests/Feature/Filament/ModelResourceTest.php

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Codex

35.34%
按下载量换算3,494

Claude

30.46%
按下载量换算3,012

Cursor

18.3%
按下载量换算1,810

Gemini CLI

8.3%
按下载量换算821

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

只读

该 Skill 主要提供规则、说明或参考内容,本身偏只读;真正读写文件、联网或执行命令仍取决于宿主 Agent 的任务。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills