mirror of
https://github.com/storybookjs/storybook.git
synced 2025-04-02 05:03:44 +08:00
Switch button to label in preact
This commit is contained in:
parent
608131d002
commit
9b0cc1f7fd
@ -2,13 +2,13 @@
|
||||
// eslint-disable-next-line import/no-extraneous-dependencies
|
||||
import PropTypes from 'prop-types';
|
||||
|
||||
export const Button = ({ onClick, children }) => (
|
||||
export const Button = ({ onClick, label }) => (
|
||||
<button type="button" onClick={onClick}>
|
||||
{children}
|
||||
{label}
|
||||
</button>
|
||||
);
|
||||
|
||||
Button.propTypes = {
|
||||
onClick: PropTypes.func.isRequired,
|
||||
children: PropTypes.node.isRequired,
|
||||
label: PropTypes.node.isRequired,
|
||||
};
|
||||
|
Loading…
x
Reference in New Issue
Block a user