Merge pull request #40 from cornelles/validate-text-font-family
Fixing font-family regex pattern when validating textpull/42/head
commit
b6019ade21
|
@ -3163,7 +3163,7 @@ class H5PContentValidator {
|
|||
$stylePatterns[] = '/^font-size: *[0-9.]+(em|px|%) *;?$/i';
|
||||
}
|
||||
if (isset($semantics->font->family) && $semantics->font->family) {
|
||||
$stylePatterns[] = '/^font-family: *[a-z0-9," ]+;?$/i';
|
||||
$stylePatterns[] = '/^font-family: *[-a-z0-9," ]+;?$/i';
|
||||
}
|
||||
if (isset($semantics->font->color) && $semantics->font->color) {
|
||||
$stylePatterns[] = '/^color: *(#[a-f0-9]{3}[a-f0-9]{3}?|rgba?\([0-9, ]+\)) *;?$/i';
|
||||
|
|
Loading…
Reference in New Issue