GovTechSG / sgds-govtech-react

React components for SGDS
https://react.designsystem.tech.gov.sg/
MIT License
15 stars 6 forks source link

Button type on the Button and Dropdown component #43

Closed hanstf closed 3 years ago

hanstf commented 3 years ago

Our project is using Button and Dropdown for our internal navigation without doing a submit. Since we cannot add the button type, the Button and Dropdown is keep on submitting the page. Is it possible to add the type props ?

hanstf commented 3 years ago

This PR, https://github.com/GovTechSG/sgds-govtech-react/pull/42 will fix the Button, but then for the Dropdown, since the button is wrapped inside a div, should I create a new PR specifically for the type props ?

weijunyu commented 3 years ago

Thanks Hans, we'll review #42 as soon as possible. For the dropdown component, since the problem actually also stems from the Button component, the changes would likely be simply changing <button> to <Button> within the component itself.

hanstf commented 3 years ago

the version ^0.2.7 solves all of out issues. Thanks!