From 3ab4ae80a7c86b10ab3d2127b716d40e6ce5f9ae Mon Sep 17 00:00:00 2001 From: Luke Abernethy Date: Thu, 10 Mar 2022 09:17:22 +0000 Subject: [PATCH 1/2] Add className prop to confirmation modal --- .../library/confirmation-modal/ConfirmationModal.js | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/react-components/source/react/library/confirmation-modal/ConfirmationModal.js b/packages/react-components/source/react/library/confirmation-modal/ConfirmationModal.js index a2e1b8aae..4d8c8ea61 100644 --- a/packages/react-components/source/react/library/confirmation-modal/ConfirmationModal.js +++ b/packages/react-components/source/react/library/confirmation-modal/ConfirmationModal.js @@ -1,5 +1,6 @@ import React from 'react'; import PropTypes from 'prop-types'; +import classnames from 'classnames'; import Modal from '../modal'; import Button from '../button'; @@ -24,6 +25,8 @@ const propTypes = { onCancel: PropTypes.func, /** If true, confirm button will render with a loading spinner */ confirmButtonLoading: PropTypes.bool, + /** Additional classes to add in addition to 'rc-modal' */ + className: PropTypes.string, }; const defaultProps = { title: '', @@ -36,6 +39,7 @@ const defaultProps = { onConfirm: () => {}, onCancel: () => {}, confirmButtonLoading: false, + className: '', }; const ConfirmationModal = ({ @@ -49,8 +53,13 @@ const ConfirmationModal = ({ onConfirm, onCancel, confirmButtonLoading, + className, }) => ( - + {title && {title}} {description} From 76c06953687724ff2e8afaa947f6d639cb34b33b Mon Sep 17 00:00:00 2001 From: Luke Abernethy Date: Thu, 10 Mar 2022 09:29:57 +0000 Subject: [PATCH 2/2] Patch release 5.33.3 --- CHANGELOG.md | 3 +++ packages/react-components/package-lock.json | 4 ++-- packages/react-components/package.json | 2 +- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index b2b208efc..fbc645962 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,6 @@ +## react-components 5.33.1 (2022-03-10) + +- [ConfirmationModal] Add className prop to confirmation modal (by [@Lukeaber](https://github.com/Lukeaber) in [#555](https://github.com/puppetlabs/design-system/pull/555)) ## react-components 5.33.2 (2022-03-09) - [Icon] Add Play icon diff --git a/packages/react-components/package-lock.json b/packages/react-components/package-lock.json index de3a33889..dcdbff7f5 100644 --- a/packages/react-components/package-lock.json +++ b/packages/react-components/package-lock.json @@ -1,12 +1,12 @@ { "name": "@puppet/react-components", - "version": "5.33.2", + "version": "5.33.3", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@puppet/react-components", - "version": "5.33.2", + "version": "5.33.3", "license": "Apache-2.0", "dependencies": { "@popperjs/core": "^2.9.2", diff --git a/packages/react-components/package.json b/packages/react-components/package.json index 1392af482..109dec701 100644 --- a/packages/react-components/package.json +++ b/packages/react-components/package.json @@ -1,6 +1,6 @@ { "name": "@puppet/react-components", - "version": "5.33.2", + "version": "5.33.3", "author": "Puppet, Inc.", "license": "Apache-2.0", "main": "build/library.js",