diff --git a/awx/ui_next/src/components/NotificationList/NotificationListItem.jsx b/awx/ui_next/src/components/NotificationList/NotificationListItem.jsx index 43c51543d3..f32e8a80e7 100644 --- a/awx/ui_next/src/components/NotificationList/NotificationListItem.jsx +++ b/awx/ui_next/src/components/NotificationList/NotificationListItem.jsx @@ -27,6 +27,8 @@ const DataListCell = styled(PFDataListCell)` const Switch = styled(PFSwitch)` display: flex; flex-wrap: no-wrap; + /* workaround PF bug; used in calculating switch width: */ + --pf-c-switch__toggle-icon--Offset: 0.125rem; `; function NotificationListItem(props) { diff --git a/awx/ui_next/src/components/NotificationList/__snapshots__/NotificationListItem.test.jsx.snap b/awx/ui_next/src/components/NotificationList/__snapshots__/NotificationListItem.test.jsx.snap index ee9f735fec..6b8d98afcc 100644 --- a/awx/ui_next/src/components/NotificationList/__snapshots__/NotificationListItem.test.jsx.snap +++ b/awx/ui_next/src/components/NotificationList/__snapshots__/NotificationListItem.test.jsx.snap @@ -331,9 +331,9 @@ exports[` initially renders succe "componentStyle": ComponentStyle { "componentId": "NotificationListItem__Switch-w674ng-1", "isStatic": true, - "lastClassName": "hbNxaH", + "lastClassName": "hfzRow", "rules": Array [ - "display:flex;flex-wrap:no-wrap;", + "display:flex;flex-wrap:no-wrap;--pf-c-switch__toggle-icon--Offset:0.125rem;", ], }, "displayName": "NotificationListItem__Switch", @@ -356,7 +356,7 @@ exports[` initially renders succe > initially renders succe componentProps={ Object { "aria-label": "Toggle notification start", - "className": "NotificationListItem__Switch-w674ng-1 hbNxaH", + "className": "NotificationListItem__Switch-w674ng-1 hfzRow", "id": "notification-9000-started-toggle", "isChecked": false, "isDisabled": false, @@ -382,7 +382,7 @@ exports[` initially renders succe > initially renders succe } >