Merge pull request #5714 from jsangmeister/fix-html-validation

Fixed HTML attribute validation
This commit is contained in:
jsangmeister 2020-11-20 16:23:16 +01:00 committed by GitHub
commit 26e414e3d1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -43,12 +43,40 @@ allowed_tags_permissive = allowed_tags_strict + [
"video", "video",
] ]
allowed_attributes = [
"align",
"alt",
"autoplay",
"background",
"bgcolor",
"border",
"class",
"colspan",
"controls",
"dir",
"height",
"hidden",
"href",
"hreflang",
"id",
"lang",
"loop",
"muted",
"poster",
"preload",
"rel",
"rowspan",
"scope",
"sizes",
"src",
"srcset",
"start",
"style",
"target",
"title",
"width",
]
def allow_all(tag: str, name: str, value: str) -> bool:
return True
allowed_attributes = allow_all
allowed_styles = [ allowed_styles = [
"color", "color",
"background-color", "background-color",