mirror of
https://github.com/filamentphp/filament.git
synced 2026-09-24 15:42:09 +08:00
fix: use line-clamp in columns to handle text overflow (#17912)
* fix: adjust TextColumn state item markup to wrap content in <p> and improve attribute handling * fix: code style * fix: retain the most simplified dom
This commit is contained in:
@@ -347,7 +347,8 @@ class TextColumn extends Column implements HasEmbeddedView
|
||||
if (
|
||||
($stateCount === 1) &&
|
||||
(! $isBulleted) &&
|
||||
(! $hasDescriptions)
|
||||
(! $hasDescriptions) &&
|
||||
(! $lineClamp)
|
||||
) {
|
||||
$stateItem = Arr::first($state);
|
||||
[
|
||||
@@ -363,7 +364,7 @@ class TextColumn extends Column implements HasEmbeddedView
|
||||
->merge($stateItemAttributes->getAttributes(), escape: false)
|
||||
->toHtml() ?>>
|
||||
<?php if ($isBadge) { ?>
|
||||
<span <?= $stateItemBadgeAttributes->toHtml() ?>>
|
||||
<span <?= $stateItemBadgeAttributes->toHtml() ?>>
|
||||
<?php } ?>
|
||||
|
||||
<?= $stateItemIconBeforeHtml ?>
|
||||
|
||||
Reference in New Issue
Block a user