diff --git a/src/SelectableBox/SelectableBoxSet.jsx b/src/SelectableBox/SelectableBoxSet.jsx
index feca94155df..166bea29603 100644
--- a/src/SelectableBox/SelectableBoxSet.jsx
+++ b/src/SelectableBox/SelectableBoxSet.jsx
@@ -2,6 +2,7 @@ import React from 'react';
import PropTypes from 'prop-types';
import classNames from 'classnames';
import { getInputType } from './utils';
+import { requiredWhenNot } from '../utils/propTypes';
const INPUT_TYPES = [
'radio',
@@ -64,6 +65,12 @@ SelectableBoxSet.propTypes = {
columns: PropTypes.number,
/** A class that is be appended to the base element. */
className: PropTypes.string,
+ /** An accessible label must be provided to the SelectableBoxSet.
+ *
+ * This can be done with `ariaLabelledby` */
+ ariaLabelledby: PropTypes.string,
+ /** If not using ariaLabelledby, an ariaLabel must be provided */
+ ariaLabel: requiredWhenNot(PropTypes.string, 'ariaLabelledby'),
};
SelectableBoxSet.defaultProps = {
@@ -74,6 +81,8 @@ SelectableBoxSet.defaultProps = {
type: 'radio',
columns: DEFAULT_COLUMNS_NUMBER,
className: undefined,
+ ariaLabelledby: undefined,
+ ariaLabel: undefined,
};
export default SelectableBoxSet;
diff --git a/src/SelectableBox/tests/SelectableBoxSet.test.jsx b/src/SelectableBox/tests/SelectableBoxSet.test.jsx
index 7b7768e01d0..aa89e08d0f7 100644
--- a/src/SelectableBox/tests/SelectableBoxSet.test.jsx
+++ b/src/SelectableBox/tests/SelectableBoxSet.test.jsx
@@ -38,8 +38,7 @@ describe('