} // Generate warning for:
// - The addition of <p>/<br> due to them being fundamental tags.
// - The addition of other tags/attributes previously unsupported by the
// format.
if (!
$missing_fundamental_tags->
allowsNothing() || !
empty($attributes_to_tag) || !
empty($added_tags)) { $beginning =
$this->
t('Updating to CKEditor 5 added support for some previously unsupported tags/attributes.'
);
$fundamental_tags = '';
if ($help_enabled && !
$missing_fundamental_tags->
allowsNothing()) { $fundamental_tags =
$this->
formatPlural(count($missing_fundamental_tags->
toCKEditor5ElementsArray()),
'The @tag tag was added because it is <a target="_blank" href=":fundamental_tag_link">required by CKEditor 5</a>.',
'The @tag tags were added because they are <a target="_blank" href=":fundamental_tag_link">required by CKEditor 5</a>.',
[ '@tag' =>
implode(', ',
$missing_fundamental_tags->
toCKEditor5ElementsArray()),
':fundamental_tag_link' => URL::
fromRoute('help.page',
['name' => 'ckeditor5'
],
['fragment' => 'required-tags'
])->
toString(),
]);
} elseif (!
$missing_fundamental_tags->
allowsNothing()) { $fundamental_tags =
$this->
formatPlural(count($missing_fundamental_tags->
toCKEditor5ElementsArray()),
'The @tag tag was added because it is required by CKEditor 5.',
'The @tag tags were added because they are required by CKEditor 5.',
[