function HTMLRestrictions::extractPlainTagsSubset
Same name in other branches
- 9 core/modules/ckeditor5/src/HTMLRestrictions.php \Drupal\ckeditor5\HTMLRestrictions::extractPlainTagsSubset()
- 11.x core/modules/ckeditor5/src/HTMLRestrictions.php \Drupal\ckeditor5\HTMLRestrictions::extractPlainTagsSubset()
Extracts the subset of plain tags (attributes omitted) from allowed elements.
Return value
\Drupal\ckeditor5\HTMLRestrictions The extracted subset of the given set of HTML restrictions.
File
-
core/
modules/ ckeditor5/ src/ HTMLRestrictions.php, line 1102
Class
- HTMLRestrictions
- Represents a set of HTML restrictions.
Namespace
Drupal\ckeditor5Code
public function extractPlainTagsSubset() : HTMLRestrictions {
// Ignore the global attribute `*` HTML tag: that is by definition not a
// plain tag.
$plain_tags = array_diff(array_keys($this->getConcreteSubset()
->getAllowedElements()), [
'*',
]);
return new self(array_fill_keys($plain_tags, FALSE));
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.