close
The Wayback Machine - https://web.archive.org/web/20200920175125/https://github.com/uber/react-vis/pull/339
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

Polygon Series #339

Merged
merged 4 commits into from Apr 3, 2017
Merged

Polygon Series #339

merged 4 commits into from Apr 3, 2017

Conversation

@mcnuttandrew
Copy link
Collaborator

mcnuttandrew commented Apr 3, 2017

The polygon series allows users to specify arbitrary polygons in coordinates. This may seem un-useful, but it allows for easy creation of radar charts (#299), fancy mark series dots, and any variety of additional things you might need polygons for!

screen shot 2017-03-31 at 5 37 24 pm

Andrew Mc Nutt added 2 commits Apr 3, 2017
Andrew Mc Nutt
const DEFAULT_COLOR = '#12939A';

function generatePath(data, xFunctor, yFunctor) {
const path = data.reduce((res, row, i) => {

This comment has been minimized.

@balthazar

balthazar Apr 3, 2017 Contributor

nit?

const generatePath = (data, xFunctor, yFunctor) =>
  `${data.reduce((res, row, i) => `${res} ${i ? 'M' : 'L'}${xFunctor(row)}${yFunctor(row)}`)} Z`;
onMouseOut: this._seriesMouseOutHandler,
onClick: this._seriesClickHandler,
fill: color || DEFAULT_COLOR,
style: {

This comment has been minimized.

@balthazar

balthazar Apr 3, 2017 Contributor

shouldn't need to spread

Andrew Mc Nutt added 2 commits Apr 3, 2017
Andrew Mc Nutt
Andrew Mc Nutt
@mcnuttandrew mcnuttandrew merged commit d94d881 into uber:master Apr 3, 2017
3 checks passed
3 checks passed
continuous-integration/travis-ci/pr The Travis CI build passed
Details
coverage/coveralls Coverage increased (+0.1%) to 86.606%
Details
licence/cla Contributor License Agreement is signed.
Details
mcnuttandrew added a commit to mcnuttandrew/react-vis that referenced this pull request Apr 3, 2017
@mcnuttandrew mcnuttandrew deleted the mcnuttandrew:repolygon branch Apr 5, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

2 participants
You can’t perform that action at this time.