From 2b5fe0e6c4236aa2936c2d64c75e8b7b5ce66983 Mon Sep 17 00:00:00 2001 From: nixocio Date: Mon, 1 Mar 2021 08:42:40 -0500 Subject: [PATCH] Fix misalignment checkbox final build Fix misalignment checkbox final build on Organization Lookup. See: https://github.com/ansible/awx/issues/9433 --- .../CheckboxListItem/CheckboxListItem.jsx | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/awx/ui_next/src/components/CheckboxListItem/CheckboxListItem.jsx b/awx/ui_next/src/components/CheckboxListItem/CheckboxListItem.jsx index 6ac79cc811..3675b9037e 100644 --- a/awx/ui_next/src/components/CheckboxListItem/CheckboxListItem.jsx +++ b/awx/ui_next/src/components/CheckboxListItem/CheckboxListItem.jsx @@ -3,12 +3,12 @@ import PropTypes from 'prop-types'; import styled from 'styled-components'; import { DataListItem, - DataListItemRow, + DataListItemRow as PFDataListItemRow, DataListItemCells, DataListCheck, Radio, } from '@patternfly/react-core'; -import DataListCell from '../DataListCell'; +import _DataListCell from '../DataListCell'; const Label = styled.label` ${({ isDisabled }) => @@ -18,6 +18,18 @@ const Label = styled.label` `} `; +const DataListItemRow = styled(PFDataListItemRow)` + && { + align-items: center; + } +`; + +const DataListCell = styled(_DataListCell)` + && { + margin-left: 10px; + } +`; + const CheckboxListItem = ({ isDisabled = false, isRadio = false, @@ -29,7 +41,6 @@ const CheckboxListItem = ({ onSelect, }) => { const CheckboxRadio = isRadio ? Radio : DataListCheck; - return (