allow vendord
All checks were successful
Build, Push and Deploy / build-and-push (push) Successful in 3m3s
Gitea Actions Demo / Explore-Gitea-Actions (push) Successful in 16s
Build, Push and Deploy / deploy-staging (push) Successful in 32s
Build, Push and Deploy / deploy-production (push) Has been skipped
Build, Push and Deploy / cleanup (push) Successful in 1s

This commit is contained in:
2026-03-30 14:54:57 +07:00
parent 66aed7c4e8
commit b5e3a778ce
21316 changed files with 2777892 additions and 13 deletions

71
vendor/laravel/prompts/src/Table.php vendored Normal file
View File

@@ -0,0 +1,71 @@
<?php
namespace Laravel\Prompts;
use Illuminate\Support\Collection;
class Table extends Prompt
{
/**
* The table headers.
*
* @var array<int, string|array<int, string>>
*/
public array $headers;
/**
* The table rows.
*
* @var array<int, array<int, string>>
*/
public array $rows;
/**
* Create a new Table instance.
*
* @param array<int, string|array<int, string>>|Collection<int, string|array<int, string>> $headers
* @param array<int, array<int, string>>|Collection<int, array<int, string>> $rows
*
* @phpstan-param ($rows is null ? list<list<string>>|Collection<int, list<string>> : list<string|list<string>>|Collection<int, string|list<string>>) $headers
*/
public function __construct(array|Collection $headers = [], array|Collection|null $rows = null)
{
if ($rows === null) {
$rows = $headers;
$headers = [];
}
$this->headers = $headers instanceof Collection ? $headers->all() : $headers;
$this->rows = $rows instanceof Collection ? $rows->all() : $rows;
}
/**
* Display the table.
*/
public function display(): void
{
$this->prompt();
}
/**
* Display the table.
*/
public function prompt(): bool
{
$this->capturePreviousNewLines();
$this->state = 'submit';
static::output()->write($this->renderTheme());
return true;
}
/**
* Get the value of the prompt.
*/
public function value(): bool
{
return true;
}
}