Sanitizes a CSS stylesheet or rule list.
More...
|
static | newDefault () |
| Create and return a default StylesheetSanitizer.
|
|
|
| $ruleSanitizers |
|
| $sanitizationErrors = [] |
|
◆ __construct()
Wikimedia\CSS\Sanitizer\StylesheetSanitizer::__construct |
( |
array | $ruleSanitizers = [] | ) |
|
- Parameters
-
RuleSanitizer[] | $ruleSanitizers | Sanitizers to test rules. For each rule in the sheet, the first sanitizer that handles that rule gets to sanitize it. |
◆ doSanitize()
Wikimedia\CSS\Sanitizer\StylesheetSanitizer::doSanitize |
( |
CSSObject | $object | ) |
|
|
protected |
◆ getRuleSanitizers()
Wikimedia\CSS\Sanitizer\StylesheetSanitizer::getRuleSanitizers |
( |
| ) |
|
Access the list of rule sanitizers.
- Returns
- RuleSanitizer[]
◆ newDefault()
static Wikimedia\CSS\Sanitizer\StylesheetSanitizer::newDefault |
( |
| ) |
|
|
static |
Create and return a default StylesheetSanitizer.
- Note
- This method exists more to be an example of how to put everything together than to be used directly.
- Returns
- StylesheetSanitizer
◆ setRuleSanitizers()
Wikimedia\CSS\Sanitizer\StylesheetSanitizer::setRuleSanitizers |
( |
array | $ruleSanitizers | ) |
|
Set the list of rule sanitizers.
- Parameters
-
RuleSanitizer[] | $ruleSanitizers | |
The documentation for this class was generated from the following file: