Skip to content

Commit

Permalink
support HTML for Paragraph field
Browse files Browse the repository at this point in the history
  • Loading branch information
atmonshi committed May 30, 2024
1 parent a6bd82b commit b85597b
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/Fields/Classes/Paragraph.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
namespace LaraZeus\Bolt\Fields\Classes;

use Filament\Forms\Components\Placeholder;
use Illuminate\Support\HtmlString;
use LaraZeus\Accordion\Forms\Accordion;
use LaraZeus\Accordion\Forms\Accordions;
use LaraZeus\Bolt\Facades\Bolt;
Expand Down Expand Up @@ -56,4 +57,12 @@ public static function getOptionsHidden(): array
self::hiddenColumnSpanFull(),
];
}

// @phpstan-ignore-next-line
public function appendFilamentComponentsOptions($component, $zeusField, bool $hasVisibility = false)
{
parent::appendFilamentComponentsOptions($component, $zeusField, $hasVisibility);

return $component->content(new HtmlString($zeusField->description));
}
}

0 comments on commit b85597b

Please sign in to comment.