This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace App\Filament\Pages\Actions; | |
use Closure; | |
use Filament\Pages\Actions\Action as BaseAction; | |
use Illuminate\Support\HtmlString; | |
class CopyToClipboardAction extends BaseAction | |
{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
//Use on a field inside a builder | |
->rule(function ( | |
Component $component, | |
mixed $state, | |
) { | |
return function (string $attribute, $value, Closure $fail) use ($component, $state) { | |
/** @var array<string,array<string,mixed>> */ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace App\Console\Commands; | |
use Illuminate\Console\Command; | |
use Illuminate\Filesystem\Filesystem; | |
class FilamentQuickStart extends Command | |
{ | |
protected $signature = 'filament:quickstart'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { get as lget, set as lset, unset } from "lodash"; | |
export default function appStore( | |
init = null, | |
driver = "session", | |
appkey = "app" | |
) { | |
//set(appkey,init) | |
if (init) { | |
let store = {}; |