diff --git a/app/Filament/Resources/ServerResource.php b/app/Filament/Resources/ServerResource.php index 3e972e2ad..1a75be7e6 100644 --- a/app/Filament/Resources/ServerResource.php +++ b/app/Filament/Resources/ServerResource.php @@ -230,10 +230,14 @@ class ServerResource extends Resource Forms\Components\Textarea::make('startup') ->label('Startup Command') ->required() - ->rows(1) + ->live() + ->rows(function ($state) { + return str($state)->explode("\n")->reduce(fn (int $carry, $line) + => $carry + floor(strlen($line) / 125), + 0); + }) ->columnSpanFull(), - Forms\Components\Repeater::make('s') ->reorderable(false) ->addable(false)