From ebb0f31b0b446db47a91d610d9d0d4eb4087d57c Mon Sep 17 00:00:00 2001 From: Alex Corey Date: Thu, 19 Mar 2020 12:53:02 -0400 Subject: [PATCH] Fixes word wrap issue --- awx/ui_next/src/components/DataListCell/DataListCell.jsx | 9 +++++++++ awx/ui_next/src/components/DataListCell/index.js | 4 ++++ .../src/screens/Template/Survey/SurveyListItem.jsx | 2 +- 3 files changed, 14 insertions(+), 1 deletion(-) create mode 100644 awx/ui_next/src/components/DataListCell/DataListCell.jsx create mode 100644 awx/ui_next/src/components/DataListCell/index.js diff --git a/awx/ui_next/src/components/DataListCell/DataListCell.jsx b/awx/ui_next/src/components/DataListCell/DataListCell.jsx new file mode 100644 index 0000000000..4cb698b50c --- /dev/null +++ b/awx/ui_next/src/components/DataListCell/DataListCell.jsx @@ -0,0 +1,9 @@ +import { DataListCell } from '@patternfly/react-core'; +import styled from 'styled-components'; + +DataListCell.displayName = 'PFDataListCell'; +// Once https://github.com/patternfly/patternfly-react/issues/3938 +// has been resolved this component can be removed +export default styled(DataListCell)` + word-break: break-word; +`; diff --git a/awx/ui_next/src/components/DataListCell/index.js b/awx/ui_next/src/components/DataListCell/index.js new file mode 100644 index 0000000000..c4a67f9c5b --- /dev/null +++ b/awx/ui_next/src/components/DataListCell/index.js @@ -0,0 +1,4 @@ +export { + default +} +from './DataListCell' diff --git a/awx/ui_next/src/screens/Template/Survey/SurveyListItem.jsx b/awx/ui_next/src/screens/Template/Survey/SurveyListItem.jsx index 1e3203e1dc..3209fca6f3 100644 --- a/awx/ui_next/src/screens/Template/Survey/SurveyListItem.jsx +++ b/awx/ui_next/src/screens/Template/Survey/SurveyListItem.jsx @@ -9,10 +9,10 @@ import { DataListItemCells, DataListItemRow, DataListItem, - DataListCell, Stack, StackItem, } from '@patternfly/react-core'; +import DataListCell from '@components/DataListCell'; import { CaretDownIcon, CaretUpIcon } from '@patternfly/react-icons'; import styled from 'styled-components';