Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expose react-art/{Circle,Rectange/Wedge} on npm #11343

Merged
merged 3 commits into from
Oct 23, 2017
Merged
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
2 changes: 1 addition & 1 deletion fixtures/art/VectorWidget.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
*/
'use strict';

var Circle = require('react-art/lib/Circle.art');
var Circle = require('react-art/Circle');
var React = require('react');
var ReactART = require('react-art');
var Group = ReactART.Group;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,19 +1,3 @@
'use strict';

var _extends =
Object.assign ||
function(target) {
for (var i = 1; i < arguments.length; i++) {
var source = arguments[i];
for (var key in source) {
if (Object.prototype.hasOwnProperty.call(source, key)) {
target[key] = source[key];
}
}
}
return target;
};

/**
* Copyright (c) 2013-present, Facebook, Inc.
*
Expand All @@ -33,9 +17,12 @@ var _extends =
*
*/

'use strict';

var assign = require('object-assign');
var PropTypes = require('prop-types');
var React = require('react');
var ReactART = require('..');
var ReactART = require('react-art');

var createReactClass = require('create-react-class');

Expand All @@ -61,7 +48,7 @@ var Circle = createReactClass({
.arc(0, radius * 2, radius)
.arc(0, radius * -2, radius)
.close();
return React.createElement(Shape, _extends({}, this.props, {d: path}));
return React.createElement(Shape, assign({}, this.props, {d: path}));
},
});

Expand Down
Original file line number Diff line number Diff line change
@@ -1,19 +1,3 @@
'use strict';

var _extends =
Object.assign ||
function(target) {
for (var i = 1; i < arguments.length; i++) {
var source = arguments[i];
for (var key in source) {
if (Object.prototype.hasOwnProperty.call(source, key)) {
target[key] = source[key];
}
}
}
return target;
};

/**
* Copyright (c) 2013-present, Facebook, Inc.
*
Expand All @@ -40,9 +24,12 @@ var _extends =
*
*/

'use strict';

var assign = require('object-assign');
var PropTypes = require('prop-types');
var React = require('react');
var ReactART = require('..');
var ReactART = require('react-art');

var createReactClass = require('create-react-class');

Expand Down Expand Up @@ -146,7 +133,7 @@ var Rectangle = createReactClass({
}
path.line(0, -height + (bl + tl));

return React.createElement(Shape, _extends({}, this.props, {d: path}));
return React.createElement(Shape, assign({}, this.props, {d: path}));
},
});

Expand Down
Original file line number Diff line number Diff line change
@@ -1,19 +1,3 @@
'use strict';

var _extends =
Object.assign ||
function(target) {
for (var i = 1; i < arguments.length; i++) {
var source = arguments[i];
for (var key in source) {
if (Object.prototype.hasOwnProperty.call(source, key)) {
target[key] = source[key];
}
}
}
return target;
};

/**
* Copyright (c) 2013-present, Facebook, Inc.
*
Expand All @@ -36,9 +20,12 @@ var _extends =
*
*/

'use strict';

var assign = require('object-assign');
var PropTypes = require('prop-types');
var React = require('react');
var ReactART = require('..');
var ReactART = require('react-art');

var createReactClass = require('create-react-class');

Expand Down Expand Up @@ -193,7 +180,7 @@ var Wedge = createReactClass({
path = this._createArcPath(startAngle, endAngle, or, ir);
}

return React.createElement(Shape, _extends({}, this.props, {d: path}));
return React.createElement(Shape, assign({}, this.props, {d: path}));
},
});

Expand Down
5 changes: 4 additions & 1 deletion packages/react-art/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,10 @@
"README.md",
"index.js",
"cjs/",
"umd/"
"umd/",
"Circle.js",
"Rectangle.js",
"Wedge.js"
],
"browserify": {
"transform": [
Expand Down