More SVG Elements and Attributes
Added <tspan> and <marker>, as well as a slew of related SVG attributes. Also an SVG-related stylesheet tweak
This commit is contained in:
parent
6ca6525ff7
commit
9b55a75570
|
@ -27,9 +27,9 @@ module Sanitize
|
|||
svg_elements = ['a', 'animate', 'animateColor', 'animateMotion',
|
||||
'animateTransform', 'circle', 'defs', 'desc', 'ellipse', 'font-face',
|
||||
'font-face-name', 'font-face-src', 'g', 'glyph', 'hkern', 'image',
|
||||
'linearGradient', 'line', 'metadata', 'missing-glyph', 'mpath', 'path',
|
||||
'polygon', 'polyline', 'radialGradient', 'rect', 'set', 'stop', 'svg',
|
||||
'switch', 'text', 'title', 'use']
|
||||
'linearGradient', 'line', 'marker', 'metadata', 'missing-glyph',
|
||||
'mpath', 'path', 'polygon', 'polyline', 'radialGradient', 'rect',
|
||||
'set', 'stop', 'svg', 'switch', 'text', 'title', 'tspan', 'use']
|
||||
|
||||
acceptable_attributes = ['abbr', 'accept', 'accept-charset', 'accesskey',
|
||||
'action', 'align', 'alt', 'axis', 'border', 'cellpadding',
|
||||
|
@ -58,21 +58,23 @@ module Sanitize
|
|||
svg_attributes = ['accent-height', 'accumulate', 'additive', 'alphabetic',
|
||||
'arabic-form', 'ascent', 'attributeName', 'attributeType',
|
||||
'baseProfile', 'bbox', 'begin', 'by', 'calcMode', 'cap-height',
|
||||
'class', 'color', 'color-rendering', 'content', 'cx', 'cy', 'd',
|
||||
'descent', 'display', 'dur', 'end', 'fill', 'fill-rule', 'font-family',
|
||||
'font-size', 'font-stretch', 'font-style', 'font-variant',
|
||||
'class', 'color', 'color-rendering', 'content', 'cx', 'cy', 'd', 'dx',
|
||||
'dy', 'descent', 'display', 'dur', 'end', 'fill', 'fill-rule',
|
||||
'font-family', 'font-size', 'font-stretch', 'font-style', 'font-variant',
|
||||
'font-weight', 'from', 'fx', 'fy', 'g1', 'g2', 'glyph-name',
|
||||
'gradientUnits', 'hanging', 'height', 'horiz-adv-x', 'horiz-origin-x',
|
||||
'id', 'ideographic', 'k', 'keyPoints', 'keySplines', 'keyTimes',
|
||||
'lang', 'mathematical', 'max', 'min', 'name', 'offset', 'opacity',
|
||||
'origin', 'overline-position', 'overline-thickness', 'panose-1',
|
||||
'path', 'pathLength', 'points', 'preserveAspectRatio', 'r',
|
||||
'repeatCount', 'repeatDur', 'requiredExtensions', 'requiredFeatures',
|
||||
'restart', 'rotate', 'rx', 'ry', 'slope', 'stemh', 'stemv',
|
||||
'stop-color', 'stop-opacity', 'strikethrough-position',
|
||||
'strikethrough-thickness', 'stroke', 'stroke-dasharray',
|
||||
'stroke-dashoffset', 'stroke-linecap', 'stroke-linejoin',
|
||||
'stroke-miterlimit', 'stroke-opacity', 'stroke-width', 'systemLanguage', 'target',
|
||||
'lang', 'marker-end', 'marker-mid', 'marker-start', 'markerHeight',
|
||||
'markerUnits', 'markerWidth', 'mathematical', 'max', 'min', 'name',
|
||||
'offset', 'opacity', 'orient', 'origin', 'overline-position',
|
||||
'overline-thickness', 'panose-1', 'path', 'pathLength', 'points',
|
||||
'preserveAspectRatio', 'r', 'refX', 'refY', 'repeatCount', 'repeatDur',
|
||||
'requiredExtensions', 'requiredFeatures', 'restart', 'rotate', 'rx',
|
||||
'ry', 'slope', 'stemh', 'stemv', 'stop-color', 'stop-opacity',
|
||||
'strikethrough-position', 'strikethrough-thickness', 'stroke',
|
||||
'stroke-dasharray', 'stroke-dashoffset', 'stroke-linecap',
|
||||
'stroke-linejoin', 'stroke-miterlimit', 'stroke-opacity',
|
||||
'stroke-width', 'systemLanguage', 'target',
|
||||
'text-anchor', 'to', 'transform', 'type', 'u1', 'u2',
|
||||
'underline-position', 'underline-thickness', 'unicode',
|
||||
'unicode-range', 'units-per-em', 'values', 'version', 'viewBox',
|
||||
|
|
|
@ -386,4 +386,8 @@ span.keyboard {
|
|||
margin-left:5px;
|
||||
padding:1px 2px;
|
||||
}
|
||||
|
||||
.centeredfigure {
|
||||
position:relative;
|
||||
margin:auto;
|
||||
text-align:center;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue