diff --git a/packages/react/src/components/DataTable/TableContainer.js b/packages/react/src/components/DataTable/TableContainer.js index 54bad0b7bf65..228c786c113a 100644 --- a/packages/react/src/components/DataTable/TableContainer.js +++ b/packages/react/src/components/DataTable/TableContainer.js @@ -16,6 +16,7 @@ const TableContainer = ({ className, children, title, + titleId, description, stickyHeader, ...rest @@ -32,7 +33,9 @@ const TableContainer = ({
{title && (
-

{title}

+

+ {title} +

{description}

@@ -51,6 +54,11 @@ TableContainer.propTypes = { */ title: PropTypes.node, + /** + * Provide an element ID of the title for the Table + */ + titleId: PropTypes.string, + /** * Optional description text for the Table */ diff --git a/packages/react/src/components/DataTable/stories/default.js b/packages/react/src/components/DataTable/stories/default.js index 22b4bdc20821..ecacf8688cb9 100644 --- a/packages/react/src/components/DataTable/stories/default.js +++ b/packages/react/src/components/DataTable/stories/default.js @@ -33,9 +33,10 @@ export default props => ( }) => ( - +
{headers.map(header => ( diff --git a/packages/react/src/components/DataTable/stories/with-batch-actions.js b/packages/react/src/components/DataTable/stories/with-batch-actions.js index e493658232d9..2fbbf4f0e61f 100644 --- a/packages/react/src/components/DataTable/stories/with-batch-actions.js +++ b/packages/react/src/components/DataTable/stories/with-batch-actions.js @@ -54,6 +54,7 @@ export default props => ( }) => ( @@ -92,7 +93,7 @@ export default props => ( -
+
diff --git a/packages/react/src/components/DataTable/stories/with-batch-expansion.js b/packages/react/src/components/DataTable/stories/with-batch-expansion.js index a98f4c6e5ae6..a9b196325c46 100644 --- a/packages/react/src/components/DataTable/stories/with-batch-expansion.js +++ b/packages/react/src/components/DataTable/stories/with-batch-expansion.js @@ -36,9 +36,10 @@ export default props => ( }) => ( -
+
( }) => (
diff --git a/packages/react/src/components/DataTable/stories/with-dynamic-content.js b/packages/react/src/components/DataTable/stories/with-dynamic-content.js index f462360388f4..839f43c58378 100644 --- a/packages/react/src/components/DataTable/stories/with-dynamic-content.js +++ b/packages/react/src/components/DataTable/stories/with-dynamic-content.js @@ -116,6 +116,7 @@ export default props => { }) => ( @@ -153,7 +154,9 @@ export default props => { -
+
diff --git a/packages/react/src/components/DataTable/stories/with-expansion.js b/packages/react/src/components/DataTable/stories/with-expansion.js index 2f09176715a2..889e909f1850 100644 --- a/packages/react/src/components/DataTable/stories/with-expansion.js +++ b/packages/react/src/components/DataTable/stories/with-expansion.js @@ -35,9 +35,10 @@ export default props => ( }) => ( -
+
diff --git a/packages/react/src/components/DataTable/stories/with-options.js b/packages/react/src/components/DataTable/stories/with-options.js index 34c1a43f77ff..61d4ca437471 100644 --- a/packages/react/src/components/DataTable/stories/with-options.js +++ b/packages/react/src/components/DataTable/stories/with-options.js @@ -42,9 +42,10 @@ export default props => ( }) => ( -
+
diff --git a/packages/react/src/components/DataTable/stories/with-overflow-menu.js b/packages/react/src/components/DataTable/stories/with-overflow-menu.js index 239402c9a0ba..db25e8565b20 100644 --- a/packages/react/src/components/DataTable/stories/with-overflow-menu.js +++ b/packages/react/src/components/DataTable/stories/with-overflow-menu.js @@ -33,8 +33,11 @@ export default props => ( getSelectionProps, getTableProps, }) => ( - -
+ +
diff --git a/packages/react/src/components/DataTable/stories/with-selection--radio.js b/packages/react/src/components/DataTable/stories/with-selection--radio.js index 10c3792946b6..313d2117794d 100644 --- a/packages/react/src/components/DataTable/stories/with-selection--radio.js +++ b/packages/react/src/components/DataTable/stories/with-selection--radio.js @@ -35,9 +35,10 @@ export default props => ( }) => ( -
+
diff --git a/packages/react/src/components/DataTable/stories/with-selection.js b/packages/react/src/components/DataTable/stories/with-selection.js index 5499ba753e58..c27d1d3dcbf7 100644 --- a/packages/react/src/components/DataTable/stories/with-selection.js +++ b/packages/react/src/components/DataTable/stories/with-selection.js @@ -35,9 +35,10 @@ export default props => ( }) => ( - +
diff --git a/packages/react/src/components/DataTable/stories/with-sorting.js b/packages/react/src/components/DataTable/stories/with-sorting.js index ffd26402cc8b..a3e0b5545d76 100644 --- a/packages/react/src/components/DataTable/stories/with-sorting.js +++ b/packages/react/src/components/DataTable/stories/with-sorting.js @@ -33,9 +33,10 @@ export default props => ( }) => ( -
+
{headers.map(header => ( diff --git a/packages/react/src/components/DataTable/stories/with-toolbar.js b/packages/react/src/components/DataTable/stories/with-toolbar.js index ba7f1d59f336..78479903b49b 100644 --- a/packages/react/src/components/DataTable/stories/with-toolbar.js +++ b/packages/react/src/components/DataTable/stories/with-toolbar.js @@ -41,6 +41,7 @@ export default props => ( }) => ( @@ -62,7 +63,7 @@ export default props => ( -
+
{headers.map(header => (