Fix styling
This commit is contained in:
committed by
github-actions[bot]
parent
f9f9950cde
commit
bbba63c57b
@@ -19,10 +19,10 @@ use Relaticle\Comments\Events\CommentUpdated;
|
||||
use Relaticle\Comments\Mentions\MentionParser;
|
||||
use Relaticle\Comments\Models\Comment;
|
||||
|
||||
class CommentItem extends Component implements HasForms, HasActions
|
||||
class CommentItem extends Component implements HasActions, HasForms
|
||||
{
|
||||
use InteractsWithForms;
|
||||
use InteractsWithActions;
|
||||
use InteractsWithForms;
|
||||
use WithFileUploads;
|
||||
|
||||
public Comment $comment;
|
||||
|
||||
@@ -21,10 +21,10 @@ use Relaticle\Comments\Mentions\MentionParser;
|
||||
use Relaticle\Comments\Models\Comment;
|
||||
use Relaticle\Comments\Models\Subscription;
|
||||
|
||||
class Comments extends Component implements HasForms, HasActions
|
||||
class Comments extends Component implements HasActions, HasForms
|
||||
{
|
||||
use InteractsWithForms;
|
||||
use InteractsWithActions;
|
||||
use InteractsWithForms;
|
||||
use WithFileUploads;
|
||||
|
||||
public Model $model;
|
||||
|
||||
@@ -152,7 +152,7 @@ class Comment extends Model
|
||||
$escapedName = e($name);
|
||||
$styledSpan = '<span class="comment-mention">@'.$escapedName.'</span>';
|
||||
|
||||
$pattern = '/<(?:span|a)[^>]*data-type="mention"[^>]*>@?' . preg_quote($escapedName, '/') . '<\/(?:span|a)>/';
|
||||
$pattern = '/<(?:span|a)[^>]*data-type="mention"[^>]*>@?'.preg_quote($escapedName, '/').'<\/(?:span|a)>/';
|
||||
|
||||
if (preg_match($pattern, $body)) {
|
||||
$body = preg_replace($pattern, $styledSpan, $body);
|
||||
|
||||
Reference in New Issue
Block a user