1
0
mirror of https://github.com/ezyang/htmlpurifier.git synced 2025-08-05 13:47:24 +02:00

CSS: Add "background-size" tag support (#289)

This commit is contained in:
Václav Smítal
2021-04-22 16:01:00 +02:00
committed by GitHub
parent 1354e7e8c5
commit 6f9aac9325
3 changed files with 21 additions and 0 deletions

View File

@@ -109,6 +109,22 @@ class HTMLPurifier_CSSDefinition extends HTMLPurifier_Definition
);
$this->info['background-position'] = new HTMLPurifier_AttrDef_CSS_BackgroundPosition();
$this->info['background-size'] = new HTMLPurifier_AttrDef_CSS_Composite(
array(
new HTMLPurifier_AttrDef_Enum(
array(
'auto',
'cover',
'contain',
'initial',
'inherit',
)
),
new HTMLPurifier_AttrDef_CSS_Percentage(),
new HTMLPurifier_AttrDef_CSS_Length()
)
);
$border_color =
$this->info['border-top-color'] =
$this->info['border-bottom-color'] =