Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions docs/docs/ref-04-tags-and-attributes.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@ title tr track u ul var video wbr
The following SVG elements are supported:

```
circle defs g line linearGradient path polygon polyline radialGradient rect stop
svg text
circle clipPath defs g line linearGradient path polygon polyline radialGradient rect stop
svg symbol text use

```

Expand Down Expand Up @@ -69,7 +69,7 @@ In addition, there is the React-specific attribute `dangerouslySetInnerHTML` ([m
### SVG Attributes

```
cx cy d fill fx fy gradientTransform gradientUnits offset points r rx ry
clipPath cx cy d fill fx fy gradientTransform gradientUnits offset points r rx ry
spreadMethod stopColor stopOpacity stroke strokeLinecap strokeWidth transform
version viewBox x1 x2 x y1 y2 y
version viewBox x1 x2 x xlinkHref y1 y2 y
```
5 changes: 4 additions & 1 deletion src/core/ReactDOM.js
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,10 @@ var ReactDOM = objMapKeyVal({
rect: false,
stop: false,
svg: false,
text: false
text: false,
symbol: false,
use: false,
clipPath: false
}, createDOMComponentClass);

var injection = {
Expand Down
6 changes: 5 additions & 1 deletion src/dom/DefaultDOMPropertyConfig.js
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,7 @@ var DefaultDOMPropertyConfig = {
/**
* SVG Properties
*/
clipPath: MUST_USE_ATTRIBUTE,
cx: MUST_USE_ATTRIBUTE,
cy: MUST_USE_ATTRIBUTE,
d: MUST_USE_ATTRIBUTE,
Expand All @@ -147,12 +148,14 @@ var DefaultDOMPropertyConfig = {
x1: MUST_USE_ATTRIBUTE,
x2: MUST_USE_ATTRIBUTE,
x: MUST_USE_ATTRIBUTE,
xlinkHref: MUST_USE_ATTRIBUTE,
y1: MUST_USE_ATTRIBUTE,
y2: MUST_USE_ATTRIBUTE,
y: MUST_USE_ATTRIBUTE
},
DOMAttributeNames: {
className: 'class',
clipPath: 'clip-path',
gradientTransform: 'gradientTransform',
gradientUnits: 'gradientUnits',
htmlFor: 'for',
Expand All @@ -161,7 +164,8 @@ var DefaultDOMPropertyConfig = {
stopOpacity: 'stop-opacity',
strokeLinecap: 'stroke-linecap',
strokeWidth: 'stroke-width',
viewBox: 'viewBox'
viewBox: 'viewBox',
xlinkHref: 'xlink:href'
},
DOMPropertyNames: {
autoCapitalize: 'autocapitalize',
Expand Down
5 changes: 4 additions & 1 deletion src/vendor/core/getMarkupWrap.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,10 @@ var shouldWrap = {
'radialGradient': true,
'rect': true,
'stop': true,
'text': true
'text': true,
'symbol': true,
'use': true,
'clipPath': true
};

var selectWrap = [1, '<select multiple="true">', '</select>'];
Expand Down
3 changes: 3 additions & 0 deletions vendor/fbtransform/transforms/xjs.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ var knownTags = {
caption: true,
circle: true,
cite: true,
clipPath: true,
code: true,
col: true,
colgroup: true,
Expand Down Expand Up @@ -130,6 +131,7 @@ var knownTags = {
summary: true,
sup: true,
svg: true,
symbol: true,
table: true,
tbody: true,
td: true,
Expand All @@ -144,6 +146,7 @@ var knownTags = {
track: true,
u: true,
ul: true,
use: true,
'var': true,
video: true,
wbr: true
Expand Down