-
Notifications
You must be signed in to change notification settings - Fork 719
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
add <Polygon /> to vx-shape #355
Conversation
Thanks for the PR! Don’t want to leave you in suspense, I’m just traveling and away from computer until Monday. Will take a look then. |
Hi @hshoff any thoughts on this? |
packages/vx-shape/Readme.md
Outdated
| Name | Default | Type | Description | | ||
| :-------------- | :----------------------- | :------- | :--------------------------------------------------------------------------------------------- | | ||
| sides | | number | The number of sides in the polygon. | | ||
| size | 25 | number | The length of eacch side of the polygon. | |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
eacch
=> each
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed
points={points} | ||
className={className} | ||
fill={fill} | ||
onClick={clickHandler} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's remove the clickHandler
prop. In vx land you would just pass onClick
and it would pass through in {...restProps}
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
removed clickHandler
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
would be happy to merge this once clickHandler
is removed
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM thank you for the contribution!
🚀 Enhancements
I have added a new simple
<Polygon />
component that takessides
andlength
props and does the rest. I have added it tovx-shape
📝 Documentation
I have added a demo to
vx-demo
and updated the vx-shape README