mirror of
https://code.castopod.org/adaures/castopod
synced 2025-06-06 18:31:05 +00:00

- enhance plugin card ui - refactor components to be more consistent - invert toggler label for better UX - edit view components regex
29 lines
555 B
PHP
29 lines
555 B
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace App\Views\Components;
|
|
|
|
use ViewComponents\Component;
|
|
|
|
class Hint extends Component
|
|
{
|
|
protected array $attributes = [
|
|
'data-tooltip' => 'bottom',
|
|
'tabindex' => '0',
|
|
];
|
|
|
|
public function render(): string
|
|
{
|
|
$this->attributes['title'] = $this->slot;
|
|
|
|
$this->mergeClass('inline-block align-middle opacity-75');
|
|
|
|
$icon = icon('question-fill');
|
|
|
|
return <<<HTML
|
|
<span {$this->getStringifiedAttributes()}>{$icon}</span>
|
|
HTML;
|
|
}
|
|
}
|