diff --git a/client/common/Button.jsx b/client/common/Button.jsx index 3791e950..bd22f44c 100644 --- a/client/common/Button.jsx +++ b/client/common/Button.jsx @@ -35,6 +35,10 @@ const StyledButton = styled.button` background-color: ${prop('buttonDisabledColorBackground')}; cursor: not-allowed; } + + > *:not(:last-child) { + margin-right: ${remSize(8)}; + } } `; @@ -58,6 +62,7 @@ const Button = ({ Button.defaultProps = { disabled: false, href: null, + label: null, to: null, type: 'button', }; @@ -79,7 +84,7 @@ Button.propTypes = { /* * An ARIA Label used for accessibility */ - label: PropTypes.string.isRequired, + label: PropTypes.string, /** * Specifying a to URL will use a react-router Link */ diff --git a/client/common/Button.stories.jsx b/client/common/Button.stories.jsx index 9f40ac73..69ec920c 100644 --- a/client/common/Button.stories.jsx +++ b/client/common/Button.stories.jsx @@ -34,3 +34,13 @@ export const AnchorButton = () => ( export const ReactRouterLink = () => ( ); + +export const InternalElementMargin = () => ( + +);