Skip to content

Commit

Permalink
Need to be able to change the size of the close button as well (#248)
Browse files Browse the repository at this point in the history
  • Loading branch information
pwolfert authored Feb 28, 2018
1 parent 670ec7c commit a774d8d
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion packages/core/src/components/Dialog/Dialog.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ export const Dialog = function(props) {
ariaCloseLabel,
children,
className,
closeButtonSize,
closeButtonVariation,
closeText,
escapeExitDisabled,
Expand Down Expand Up @@ -55,6 +56,7 @@ export const Dialog = function(props) {
aria-label={ariaCloseLabel}
className="ds-c-dialog__close"
onClick={onExit}
size={closeButtonSize}
variation={closeButtonVariation}
>
{closeText}
Expand Down Expand Up @@ -120,7 +122,14 @@ Dialog.propTypes = {
* Additional classes to be added to the root dialog element.
*/
className: PropTypes.string,
closeButtonVariation: Button.propTypes.variation,
/**
* Size of the close button. See [Button component]({{root}}/components/button/#components.button.react)
*/
closeButtonSize: PropTypes.oneOf(['small', 'big']),
/**
* Variation string to be applied to close button component. See [Button component]({{root}}/components/button/#components.button.react)
*/
closeButtonVariation: PropTypes.string,
/**
* For internationalization purposes, the text for the "Close" button must be
* passed in as a prop.
Expand Down

0 comments on commit a774d8d

Please sign in to comment.