File tree Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -21,6 +21,7 @@ const Button = props => {
2121 setProps,
2222 n_clicks,
2323 target,
24+ type,
2425 ...otherProps
2526 } = props ;
2627
@@ -38,6 +39,7 @@ const Button = props => {
3839 return (
3940 < RSButton
4041 tag = { useLink ? Link : 'button' }
42+ type = { useLink ? null : type }
4143 target = { useLink ? target : null }
4244 href = { disabled ? null : href }
4345 disabled = { disabled }
@@ -178,7 +180,13 @@ Button.propTypes = {
178180 /**
179181 * Target attribute to pass on to link if using Button as an external link.
180182 */
181- target : PropTypes . string
183+ target : PropTypes . string ,
184+
185+ /**
186+ * The default behavior of the button. Possible values are: button, reset,
187+ * submit
188+ */
189+ type : PropTypes . oneOf ( [ 'button' , 'reset' , 'submit' ] )
182190} ;
183191
184192export default Button ;
You can’t perform that action at this time.
0 commit comments