From 9ef967aa24ceaee23e3eadb560712cd5041ae6b5 Mon Sep 17 00:00:00 2001 From: Matthew Taylor Date: Thu, 26 Oct 2017 11:02:01 -0400 Subject: [PATCH] pass props to button from labeled button MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit so that we don’t have to check for things like `disabled` twice. --- .../labeled-icon-button.jsx | 22 ++++++++++++------- 1 file changed, 14 insertions(+), 8 deletions(-) diff --git a/src/components/labeled-icon-button/labeled-icon-button.jsx b/src/components/labeled-icon-button/labeled-icon-button.jsx index 792a14aa..c08660d6 100644 --- a/src/components/labeled-icon-button/labeled-icon-button.jsx +++ b/src/components/labeled-icon-button/labeled-icon-button.jsx @@ -10,24 +10,30 @@ import Button from '../button/button.jsx'; import styles from './labeled-icon-button.css'; -const LabeledIconButton = props => ( +const LabeledIconButton = ({ + className, + imgAlt, + imgSrc, + onClick, + title, + ...props +}) => ( ); LabeledIconButton.propTypes = { className: PropTypes.string, - disabled: PropTypes.string, imgAlt: PropTypes.string.isRequired, imgSrc: PropTypes.string.isRequired, onClick: PropTypes.func.isRequired,