selectOne(selected, id, hostCollection),
rowIndex,
diff --git a/webpack/components/extensions/HostDetails/Cards/HostCollectionsCard/__tests__/hostCollectionsModal.test.js b/webpack/components/extensions/HostDetails/Cards/HostCollectionsCard/__tests__/hostCollectionsModal.test.js
index aea784fd372..65fb41f5352 100644
--- a/webpack/components/extensions/HostDetails/Cards/HostCollectionsCard/__tests__/hostCollectionsModal.test.js
+++ b/webpack/components/extensions/HostDetails/Cards/HostCollectionsCard/__tests__/hostCollectionsModal.test.js
@@ -1,5 +1,5 @@
import React from 'react';
-import { renderWithRedux, patientlyWaitFor, fireEvent } from 'react-testing-lib-wrapper';
+import { renderWithRedux, patientlyWaitFor, fireEvent,act } from 'react-testing-lib-wrapper';
import mockAvailableHostCollections from './availableHostCollections.fixtures.json';
import mockRemovableHostCollections from './removableHostCollections.fixtures.json';
import { REMOVABLE_HOST_COLLECTIONS_KEY } from '../HostCollectionsConstants';
@@ -99,10 +99,14 @@ describe('HostCollectionsAddModal', () => {
await patientlyWaitFor(() =>
expect(getAllByText(firstHostCollection.name)[0]).toBeInTheDocument());
const checkbox = getByRole('checkbox', { name: 'Select row 0' });
- fireEvent.click(checkbox);
+ await act(async () => {
+ fireEvent.click(checkbox);
+ });
const addButton = getByRole('button', { name: 'Add' });
expect(addButton).toHaveAttribute('aria-disabled', 'false');
- fireEvent.click(addButton);
+ await act(async () => {
+ fireEvent.click(addButton);
+ });
assertNockRequest(autocompleteScope);
assertNockRequest(scope);
@@ -204,12 +208,15 @@ describe('HostCollectionsRemoveModal', () => {
await patientlyWaitFor(() =>
expect(getAllByText(firstRemovableHostCollection.name)[0]).toBeInTheDocument());
const checkbox = getByRole('checkbox', { name: 'Select row 0' });
- fireEvent.click(checkbox);
+ await act(async () => {
+ fireEvent.click(checkbox);
+ });
expect(getAllByText('1 selected')).toHaveLength(1);
const removeButton = getByRole('button', { name: 'Remove' });
expect(removeButton).toHaveAttribute('aria-disabled', 'false');
- fireEvent.click(removeButton);
-
+ await act(async () => {
+ fireEvent.click(removeButton);
+ });
assertNockRequest(autocompleteScope);
assertNockRequest(scope);
assertNockRequest(alterScope);
diff --git a/webpack/components/extensions/HostDetails/Cards/SystemPurposeCard/SystemPurposeCard.js b/webpack/components/extensions/HostDetails/Cards/SystemPurposeCard/SystemPurposeCard.js
index 7d790913732..aa323b4c3e9 100644
--- a/webpack/components/extensions/HostDetails/Cards/SystemPurposeCard/SystemPurposeCard.js
+++ b/webpack/components/extensions/HostDetails/Cards/SystemPurposeCard/SystemPurposeCard.js
@@ -22,6 +22,7 @@ import {
Tooltip,
Skeleton,
CardExpandableContent,
+ Icon,
} from '@patternfly/react-core';
import { OutlinedQuestionCircleIcon } from '@patternfly/react-icons';
import { translate as __ } from 'foremanReact/common/I18n';
@@ -104,14 +105,16 @@ const SystemPurposeCard = ({ hostDetails, akDetails }) => {
enableFlip
isContentLeftAligned
>
-
+
+
+
{showEditButton && (
-
+
)
}
diff --git a/webpack/components/extensions/HostDetails/Cards/SystemPurposeCard/SystemPurposeCard.scss b/webpack/components/extensions/HostDetails/Cards/SystemPurposeCard/SystemPurposeCard.scss
index 56c23cdf6bf..7ae4098af25 100644
--- a/webpack/components/extensions/HostDetails/Cards/SystemPurposeCard/SystemPurposeCard.scss
+++ b/webpack/components/extensions/HostDetails/Cards/SystemPurposeCard/SystemPurposeCard.scss
@@ -1,12 +1,12 @@
.system-purpose-card-body {
font-size: small;
- .pf-c-label {
+ .pf-v5-c-label {
font-size: smaller;
}
}
#system-purpose-card {
- .pf-c-card__header-toggle {
+ .pf-v5-c-card__header-toggle {
margin-top: -2px;
}
}
\ No newline at end of file
diff --git a/webpack/components/extensions/HostDetails/Cards/SystemPurposeCard/SystemPurposeEditModal.js b/webpack/components/extensions/HostDetails/Cards/SystemPurposeCard/SystemPurposeEditModal.js
index fcf792ac7e0..5731ee4af25 100644
--- a/webpack/components/extensions/HostDetails/Cards/SystemPurposeCard/SystemPurposeEditModal.js
+++ b/webpack/components/extensions/HostDetails/Cards/SystemPurposeCard/SystemPurposeEditModal.js
@@ -11,10 +11,12 @@ import {
FormGroup,
FormSelect,
FormSelectOption,
+} from '@patternfly/react-core';
+import {
Select,
SelectOption,
SelectVariant,
-} from '@patternfly/react-core';
+} from '@patternfly/react-core/deprecated';
import { FormattedMessage } from 'react-intl';
import { translate as __ } from 'foremanReact/common/I18n';
import {
@@ -215,7 +217,7 @@ const SystemPurposeEditModal = ({
name="role"
ouiaId="role-select"
value={selectedRole}
- onChange={setSelectedRole}
+ onChange={(_event, val) => setSelectedRole(val)}
>
{roleOptions.map(option => (
setSelectedServiceLevel(val)}
>
{serviceLevelOptions.map(option => (
setSelectedUsage(val)}
>
{usageOptions.map(option => (
setSelectedReleaseVersion(val)}
>
{releaseVersionOptions.map(option => (
toggleAddonSelect(isOpenState)}
onSelect={onAddonSelect}
selections={selectedAddons}
isOpen={addonSelectOpen}
diff --git a/webpack/components/extensions/HostDetails/Cards/SystemPurposeCard/__tests__/SystemPurposeEditModal.test.js b/webpack/components/extensions/HostDetails/Cards/SystemPurposeCard/__tests__/SystemPurposeEditModal.test.js
index 8967da1f439..09c6ec487a1 100644
--- a/webpack/components/extensions/HostDetails/Cards/SystemPurposeCard/__tests__/SystemPurposeEditModal.test.js
+++ b/webpack/components/extensions/HostDetails/Cards/SystemPurposeCard/__tests__/SystemPurposeEditModal.test.js
@@ -1,6 +1,6 @@
import React from 'react';
import { propsToCamelCase } from 'foremanReact/common/helpers';
-import { renderWithRedux, patientlyWaitFor, fireEvent } from 'react-testing-lib-wrapper';
+import { renderWithRedux, patientlyWaitFor, fireEvent, act } from 'react-testing-lib-wrapper';
import HOST_DETAILS from '../../../HostDetailsConstants';
import SystemPurposeEditModal from '../SystemPurposeEditModal';
import { assertNockRequest, nockInstance } from '../../../../../../test-utils/nockWrapper';
@@ -163,8 +163,9 @@ describe('SystemPurposeEditModal', () => {
// Save button should now be enabled
expect(saveButton).toHaveAttribute('aria-disabled', 'false');
- fireEvent.click(saveButton);
-
+ await act(async () => {
+ fireEvent.click(saveButton);
+ });
await patientlyWaitFor(() => {
expect(baseAttributes.closeModal).toHaveBeenCalled();
});
@@ -217,8 +218,9 @@ describe('SystemPurposeEditModal', () => {
// Save button should now be enabled
expect(saveButton).toHaveAttribute('aria-disabled', 'false');
- fireEvent.click(saveButton);
-
+ await act(async () => {
+ fireEvent.click(saveButton);
+ });
await patientlyWaitFor(() => {
expect(baseAttributes.closeModal).toHaveBeenCalled();
});
@@ -246,8 +248,9 @@ describe('SystemPurposeEditModal', () => {
/>, renderOptions());
const releaseVersionDropdown = getByLabelText('Release version');
- fireEvent.click(releaseVersionDropdown);
-
+ await act(async () => {
+ fireEvent.click(releaseVersionDropdown);
+ });
await patientlyWaitFor(() => {
expect(getByText('8')).toBeInTheDocument();
expect(getByText('9')).toBeInTheDocument();
@@ -276,8 +279,9 @@ describe('SystemPurposeEditModal', () => {
/>, renderOptions(ACTIVATION_KEY));
const releaseVersionDropdown = getByLabelText('Release version');
- fireEvent.click(releaseVersionDropdown);
-
+ await act(async () => {
+ fireEvent.click(releaseVersionDropdown);
+ });
await patientlyWaitFor(() => {
expect(getByText('8')).toBeInTheDocument();
expect(getByText('9')).toBeInTheDocument();
diff --git a/webpack/components/extensions/HostDetails/Tabs/DebsTab/DebInstallModal.js b/webpack/components/extensions/HostDetails/Tabs/DebsTab/DebInstallModal.js
index 02bc30707a1..450f27bf0f0 100644
--- a/webpack/components/extensions/HostDetails/Tabs/DebsTab/DebInstallModal.js
+++ b/webpack/components/extensions/HostDetails/Tabs/DebsTab/DebInstallModal.js
@@ -1,5 +1,15 @@
import React, { useState } from 'react';
-import { Modal, Button, Dropdown, DropdownItem, DropdownToggle, DropdownDirection, DropdownToggleAction } from '@patternfly/react-core';
+import {
+ Modal,
+ Button,
+} from '@patternfly/react-core';
+import {
+ Dropdown,
+ DropdownItem,
+ DropdownToggle,
+ DropdownDirection,
+ DropdownToggleAction,
+} from '@patternfly/react-core/deprecated';
import { CaretDownIcon, CaretUpIcon } from '@patternfly/react-icons';
import { useSelector } from 'react-redux';
import { FormattedMessage } from 'react-intl';
@@ -213,7 +223,7 @@ const DebInstallModal = ({
selectOne(selected, id, pkg),
rowIndex,
diff --git a/webpack/components/extensions/HostDetails/Tabs/DebsTab/DebInstallModal.scss b/webpack/components/extensions/HostDetails/Tabs/DebsTab/DebInstallModal.scss
index 6e9b7cde64a..08c1a8542c4 100644
--- a/webpack/components/extensions/HostDetails/Tabs/DebsTab/DebInstallModal.scss
+++ b/webpack/components/extensions/HostDetails/Tabs/DebsTab/DebInstallModal.scss
@@ -1,3 +1,3 @@
-#deb-install-modal .pf-c-input-group input {
+#deb-install-modal .pf-v5-c-input-group input {
min-width: 15em;
}
\ No newline at end of file
diff --git a/webpack/components/extensions/HostDetails/Tabs/DebsTab/DebsTab.js b/webpack/components/extensions/HostDetails/Tabs/DebsTab/DebsTab.js
index cc0a89bc5d8..690942c49a0 100644
--- a/webpack/components/extensions/HostDetails/Tabs/DebsTab/DebsTab.js
+++ b/webpack/components/extensions/HostDetails/Tabs/DebsTab/DebsTab.js
@@ -3,6 +3,11 @@ import { useSelector } from 'react-redux';
import {
ActionList,
ActionListItem,
+ Skeleton,
+ Split,
+ SplitItem,
+} from '@patternfly/react-core';
+import {
Dropdown,
DropdownItem,
DropdownSeparator,
@@ -12,10 +17,7 @@ import {
Select,
SelectOption,
SelectVariant,
- Skeleton,
- Split,
- SplitItem,
-} from '@patternfly/react-core';
+} from '@patternfly/react-core/deprecated';
import { TableVariant, Thead, Tbody, Tr, Th, Td, TableText } from '@patternfly/react-table';
import PropTypes from 'prop-types';
import { translate as __ } from 'foremanReact/common/I18n';
@@ -72,7 +74,7 @@ const UpdateVersionsSelect = ({
variant={SelectVariant.single}
aria-label="upgradable-version-select"
ouiaId="upgradable-version-select"
- onToggle={isOpen => toggleUpgradableVersionSelect(isOpen, rowIndex)}
+ onToggle={(_event, isOpen) => toggleUpgradableVersionSelect(isOpen, rowIndex)}
onSelect={(event, selected) => {
onUpgradableVersionSelect(event, selected, rowIndex, packageName);
}}
@@ -525,7 +527,7 @@ export const DebsTab = () => {
{showActions ? (
| selectOne(selected, id, pkg),
rowIndex,
diff --git a/webpack/components/extensions/HostDetails/Tabs/DebsTab/DebsTab.scss b/webpack/components/extensions/HostDetails/Tabs/DebsTab/DebsTab.scss
index 5508c40310b..7b8b264cc95 100644
--- a/webpack/components/extensions/HostDetails/Tabs/DebsTab/DebsTab.scss
+++ b/webpack/components/extensions/HostDetails/Tabs/DebsTab/DebsTab.scss
@@ -6,7 +6,7 @@
margin: 16px 24px;
}
-#style-select-id .pf-c-select button.pf-c-select__toggle {
+#style-select-id .pf-v5-c-select button.pf-v5-c-select__toggle {
font-size: 1em;
margin-left: -0.5rem;
}
diff --git a/webpack/components/extensions/HostDetails/Tabs/ErrataTab/ErrataTab.js b/webpack/components/extensions/HostDetails/Tabs/ErrataTab/ErrataTab.js
index 8f9cde68b4f..c44caaa657b 100644
--- a/webpack/components/extensions/HostDetails/Tabs/ErrataTab/ErrataTab.js
+++ b/webpack/components/extensions/HostDetails/Tabs/ErrataTab/ErrataTab.js
@@ -2,10 +2,21 @@ import React, { useCallback, useState, useMemo } from 'react';
import useDeepCompareEffect from 'use-deep-compare-effect';
import { useSelector, useDispatch } from 'react-redux';
import {
- Split, SplitItem, ActionList, ActionListItem, Dropdown,
- DropdownItem, KebabToggle, Skeleton, Tooltip, ToggleGroup,
- DropdownToggle, DropdownToggleAction,
+ Split,
+ SplitItem,
+ ActionList,
+ ActionListItem,
+ Skeleton,
+ Tooltip,
+ ToggleGroup,
} from '@patternfly/react-core';
+import {
+ Dropdown,
+ DropdownItem,
+ KebabToggle,
+ DropdownToggle,
+ DropdownToggleAction,
+} from '@patternfly/react-core/deprecated';
import { TimesIcon, CheckIcon } from '@patternfly/react-icons';
import {
TableVariant,
@@ -250,7 +261,7 @@ export const ErrataTab = () => {
const disabledReason = __('A remote execution job is in progress');
const tdSelect = useCallback((errataId, rowIndex, rexJobInProgress) => ({
- disable: rexJobInProgress || !isSelectable(errataId),
+ isDisabled: rexJobInProgress || !isSelectable(errataId),
isSelected: isSelected(errataId),
onSelect: (event, selected) => selectOne(selected, errataId),
rowIndex,
diff --git a/webpack/components/extensions/HostDetails/Tabs/ErrataTab/ErrataTab.scss b/webpack/components/extensions/HostDetails/Tabs/ErrataTab/ErrataTab.scss
index dff6519a503..c2d7cd08c45 100644
--- a/webpack/components/extensions/HostDetails/Tabs/ErrataTab/ErrataTab.scss
+++ b/webpack/components/extensions/HostDetails/Tabs/ErrataTab/ErrataTab.scss
@@ -6,6 +6,6 @@
margin: 16px 24px;
}
-.pf-c-toggle-group__text {
+.pf-v5-c-toggle-group__text {
color: black;
}
\ No newline at end of file
diff --git a/webpack/components/extensions/HostDetails/Tabs/ModuleStreamsTab/ModuleStreamsTab.js b/webpack/components/extensions/HostDetails/Tabs/ModuleStreamsTab/ModuleStreamsTab.js
index bf2842a0837..d5d32e98580 100644
--- a/webpack/components/extensions/HostDetails/Tabs/ModuleStreamsTab/ModuleStreamsTab.js
+++ b/webpack/components/extensions/HostDetails/Tabs/ModuleStreamsTab/ModuleStreamsTab.js
@@ -2,21 +2,26 @@ import React, { useCallback, useState } from 'react';
import { useSelector } from 'react-redux';
import { FormattedMessage } from 'react-intl';
import { translate as __ } from 'foremanReact/common/I18n';
-import { Skeleton,
+import {
+ Skeleton,
Label,
Button,
Split,
SplitItem,
Checkbox,
- Dropdown,
Text,
TextVariants,
+ Modal,
+ ModalVariant,
+ Icon,
+} from '@patternfly/react-core';
+import {
+ Dropdown,
DropdownItem,
KebabToggle,
DropdownPosition,
DropdownSeparator,
- Modal,
- ModalVariant } from '@patternfly/react-core';
+} from '@patternfly/react-core/deprecated';
import PropTypes from 'prop-types';
import { upperFirst, lowerCase } from 'lodash';
import { TableText, TableVariant, Thead, Tbody, Tr, Td } from '@patternfly/react-table';
@@ -54,9 +59,9 @@ const EnabledIcon = ({ streamText, streamInstallStatus, upgradable }) => {
case (streamInstallStatus?.length > 0 && streamText === 'disabled'):
return {INSTALLED_STATE.INSTALLED};
case (streamInstallStatus?.length > 0 && streamText === 'enabled' && upgradable !== true):
- return <> {INSTALLED_STATE.UPTODATE}>;
+ return <>{INSTALLED_STATE.UPTODATE}>;
case (streamInstallStatus?.length > 0 && streamText === 'enabled' && upgradable):
- return <> {INSTALLED_STATE.UPGRADEABLE}>;
+ return <> {INSTALLED_STATE.UPGRADEABLE}>;
default:
return ;
}
@@ -432,7 +437,7 @@ export const ModuleStreamsTab = () => {
id={`Checkbox${id}`}
label={__('Customize with Rex')}
isChecked={id === useCustomizedRex}
- onChange={checked => (checked ? setUseCustomizedRex(id) : setUseCustomizedRex(''))}
+ onChange={(_event, checked) => (checked ? setUseCustomizedRex(id) : setUseCustomizedRex(''))}
/>
,
,
diff --git a/webpack/components/extensions/HostDetails/Tabs/PackagesTab/PackageInstallModal.js b/webpack/components/extensions/HostDetails/Tabs/PackagesTab/PackageInstallModal.js
index d251ebe81ad..21ef86761d8 100644
--- a/webpack/components/extensions/HostDetails/Tabs/PackagesTab/PackageInstallModal.js
+++ b/webpack/components/extensions/HostDetails/Tabs/PackagesTab/PackageInstallModal.js
@@ -1,5 +1,15 @@
import React, { useState } from 'react';
-import { Modal, Button, Dropdown, DropdownItem, DropdownToggle, DropdownDirection, DropdownToggleAction } from '@patternfly/react-core';
+import {
+ Modal,
+ Button,
+} from '@patternfly/react-core';
+import {
+ Dropdown,
+ DropdownItem,
+ DropdownToggle,
+ DropdownDirection,
+ DropdownToggleAction,
+} from '@patternfly/react-core/deprecated';
import { CaretDownIcon, CaretUpIcon } from '@patternfly/react-icons';
import { useSelector } from 'react-redux';
import { FormattedMessage } from 'react-intl';
@@ -213,7 +223,7 @@ const PackageInstallModal = ({
|
selectOne(selected, id, pkg),
rowIndex,
diff --git a/webpack/components/extensions/HostDetails/Tabs/PackagesTab/PackageInstallModal.scss b/webpack/components/extensions/HostDetails/Tabs/PackagesTab/PackageInstallModal.scss
index 148787c4d05..31b8103b2c3 100644
--- a/webpack/components/extensions/HostDetails/Tabs/PackagesTab/PackageInstallModal.scss
+++ b/webpack/components/extensions/HostDetails/Tabs/PackagesTab/PackageInstallModal.scss
@@ -1,3 +1,3 @@
-#package-install-modal .pf-c-input-group input {
+#package-install-modal .pf-v5-c-input-group input {
min-width: 15em;
}
\ No newline at end of file
diff --git a/webpack/components/extensions/HostDetails/Tabs/PackagesTab/PackagesTab.js b/webpack/components/extensions/HostDetails/Tabs/PackagesTab/PackagesTab.js
index 22951d90638..5b1f03d3d7c 100644
--- a/webpack/components/extensions/HostDetails/Tabs/PackagesTab/PackagesTab.js
+++ b/webpack/components/extensions/HostDetails/Tabs/PackagesTab/PackagesTab.js
@@ -3,6 +3,11 @@ import { useSelector, useDispatch } from 'react-redux';
import {
ActionList,
ActionListItem,
+ Skeleton,
+ Split,
+ SplitItem,
+} from '@patternfly/react-core';
+import {
Dropdown,
DropdownItem,
DropdownSeparator,
@@ -12,10 +17,7 @@ import {
Select,
SelectOption,
SelectVariant,
- Skeleton,
- Split,
- SplitItem,
-} from '@patternfly/react-core';
+} from '@patternfly/react-core/deprecated';
import { TableVariant, Thead, Tbody, Tr, Th, Td, TableText } from '@patternfly/react-table';
import PropTypes from 'prop-types';
import { translate as __ } from 'foremanReact/common/I18n';
@@ -74,7 +76,7 @@ const UpdateVersionsSelect = ({
variant={SelectVariant.single}
aria-label="upgradable-version-select"
ouiaId="upgradable-version-select"
- onToggle={isOpen => toggleUpgradableVersionSelect(isOpen, rowIndex)}
+ onToggle={(_event, isOpen) => toggleUpgradableVersionSelect(isOpen, rowIndex)}
onSelect={(event, selected) => {
onUpgradableVersionSelect(event, selected, rowIndex, packageName);
}}
@@ -568,7 +570,7 @@ export const PackagesTab = () => {
{showActions ? (
| selectOne(selected, id, pkg),
rowIndex,
diff --git a/webpack/components/extensions/HostDetails/Tabs/PackagesTab/PackagesTab.scss b/webpack/components/extensions/HostDetails/Tabs/PackagesTab/PackagesTab.scss
index b8f7049a892..2c8cd32dee9 100644
--- a/webpack/components/extensions/HostDetails/Tabs/PackagesTab/PackagesTab.scss
+++ b/webpack/components/extensions/HostDetails/Tabs/PackagesTab/PackagesTab.scss
@@ -6,7 +6,7 @@
margin: 16px 24px;
}
-#style-select-id .pf-c-select button.pf-c-select__toggle {
+#style-select-id .pf-v5-c-select button.pf-v5-c-select__toggle {
font-size: 1em;
margin-left: -0.5rem;
}
diff --git a/webpack/components/extensions/HostDetails/Tabs/RepositorySetsTab/RepositorySetsTab.js b/webpack/components/extensions/HostDetails/Tabs/RepositorySetsTab/RepositorySetsTab.js
index 63bf52b7dac..1ac68be2a76 100644
--- a/webpack/components/extensions/HostDetails/Tabs/RepositorySetsTab/RepositorySetsTab.js
+++ b/webpack/components/extensions/HostDetails/Tabs/RepositorySetsTab/RepositorySetsTab.js
@@ -22,9 +22,6 @@ import {
ActionListItem,
Alert,
AlertActionCloseButton,
- Dropdown,
- DropdownItem,
- KebabToggle,
Label,
Skeleton,
Split,
@@ -33,6 +30,11 @@ import {
ToggleGroupItem,
Tooltip,
} from '@patternfly/react-core';
+import {
+ Dropdown,
+ DropdownItem,
+ KebabToggle,
+} from '@patternfly/react-core/deprecated';
import { FlagIcon } from '@patternfly/react-icons';
import {
TableVariant,
@@ -616,7 +618,7 @@ const RepositorySetsTab = () => {
|
{canDoContentOverrides ? (
selectOne(selected, id),
rowIndex,
diff --git a/webpack/components/extensions/HostDetails/Tabs/TracesTab/EnableTracerModal.js b/webpack/components/extensions/HostDetails/Tabs/TracesTab/EnableTracerModal.js
index fe5767a205e..3c2405f8356 100644
--- a/webpack/components/extensions/HostDetails/Tabs/TracesTab/EnableTracerModal.js
+++ b/webpack/components/extensions/HostDetails/Tabs/TracesTab/EnableTracerModal.js
@@ -6,15 +6,17 @@ import {
FlexItem,
Modal,
ModalVariant,
- Dropdown,
- DropdownItem,
- DropdownToggle,
Text,
TextContent,
TextList,
TextListItem,
Alert,
} from '@patternfly/react-core';
+import {
+ Dropdown,
+ DropdownItem,
+ DropdownToggle,
+} from '@patternfly/react-core/deprecated';
import { CaretDownIcon, ArrowRightIcon } from '@patternfly/react-icons';
import { translate as __ } from 'foremanReact/common/I18n';
import { useSelector } from 'react-redux';
diff --git a/webpack/components/extensions/HostDetails/Tabs/TracesTab/EnableTracerModal.scss b/webpack/components/extensions/HostDetails/Tabs/TracesTab/EnableTracerModal.scss
index 53917b80680..ca596fa920a 100644
--- a/webpack/components/extensions/HostDetails/Tabs/TracesTab/EnableTracerModal.scss
+++ b/webpack/components/extensions/HostDetails/Tabs/TracesTab/EnableTracerModal.scss
@@ -1,4 +1,4 @@
-.pf-c-content {
+.pf-v5-c-content {
ul {
margin-top: 1rem;
li svg {
diff --git a/webpack/components/extensions/HostDetails/Tabs/TracesTab/TracesEnabler.js b/webpack/components/extensions/HostDetails/Tabs/TracesTab/TracesEnabler.js
index cd500037d0c..38c4c44267a 100644
--- a/webpack/components/extensions/HostDetails/Tabs/TracesTab/TracesEnabler.js
+++ b/webpack/components/extensions/HostDetails/Tabs/TracesTab/TracesEnabler.js
@@ -4,12 +4,11 @@ import {
EmptyState,
EmptyStateIcon,
EmptyStateBody,
- Title,
EmptyStateVariant,
Button,
Flex,
FlexItem,
- Spinner,
+ Spinner, EmptyStateHeader, EmptyStateFooter,
} from '@patternfly/react-core';
import { WrenchIcon } from '@patternfly/react-icons';
import { translate as __ } from 'foremanReact/common/I18n';
@@ -67,14 +66,12 @@ const TracesEnabler = ({ hostname, tracerRpmAvailable }) => {
} = useRexJobPolling(initialAction, successAction);
return (
-
+
{pollingStarted ?
:
}
-
- {pollingStarted ? enablingTitle : title}
-
+ {pollingStarted ? enablingTitle : title}>} headingLevel="h2" />
{body}
@@ -90,13 +87,15 @@ const TracesEnabler = ({ hostname, tracerRpmAvailable }) => {
-
+
+
+
);
};
diff --git a/webpack/components/extensions/HostDetails/Tabs/TracesTab/TracesTab.js b/webpack/components/extensions/HostDetails/Tabs/TracesTab/TracesTab.js
index 2fce589dc19..0b9b5873d11 100644
--- a/webpack/components/extensions/HostDetails/Tabs/TracesTab/TracesTab.js
+++ b/webpack/components/extensions/HostDetails/Tabs/TracesTab/TracesTab.js
@@ -1,9 +1,19 @@
import React, { useState, useCallback } from 'react';
import { FormattedMessage } from 'react-intl';
import {
- Skeleton, Split, SplitItem, ActionList, ActionListItem, Dropdown,
- DropdownItem, DropdownToggle, DropdownToggleAction, Alert,
+ Skeleton,
+ Split,
+ SplitItem,
+ ActionList,
+ ActionListItem,
+ Alert,
} from '@patternfly/react-core';
+import {
+ Dropdown,
+ DropdownItem,
+ DropdownToggle,
+ DropdownToggleAction,
+} from '@patternfly/react-core/deprecated';
import { translate as __ } from 'foremanReact/common/I18n';
import { TableVariant, Thead, Tbody, Tr, Th, Td } from '@patternfly/react-table';
import { ExclamationTriangleIcon } from '@patternfly/react-icons';
@@ -270,7 +280,7 @@ const TracesTab = () => {
{showActions ? (
{
const statusDropdown = queryByText('Status', { ignore: 'th' });
expect(statusDropdown).toBeInTheDocument();
- fireEvent.click(statusDropdown);
+ await act(async () => {
+ fireEvent.click(statusDropdown);
+ });
const upgradable = getByRole('option', { name: 'select Upgradable' });
fireEvent.click(upgradable);
await patientlyWaitFor(() => {
@@ -182,20 +184,26 @@ test('Can upgrade a package via remote execution', async (done) => {
const statusDropdown = getByText('Status', { ignore: 'th' });
expect(statusDropdown).toBeInTheDocument();
- fireEvent.click(statusDropdown);
+ await act(async () => {
+ fireEvent.click(statusDropdown);
+ });
const upgradable = getByRole('option', { name: 'select Upgradable' });
fireEvent.click(upgradable);
await patientlyWaitFor(() => {
expect(getByText('libmagic1')).toBeInTheDocument();
expect(getByText('libapt-pkg6.0')).toBeInTheDocument();
});
-
- const kebabDropdown = getAllByLabelText('Actions');
- kebabDropdown[0].click();
+ const kebabDropdown = getAllByLabelText('Kebab toggle');
+ await act(async () => {
+ kebabDropdown[0].click();
+ });
const rexAction = getByText('Upgrade via remote execution');
await patientlyWaitFor(() => expect(rexAction).toBeInTheDocument());
- fireEvent.click(rexAction);
+
+ await act(async () => {
+ fireEvent.click(rexAction);
+ });
assertNockRequest(autocompleteScope);
assertNockRequest(scope);
@@ -227,7 +235,9 @@ test('Can upgrade a package via customized remote execution', async (done) => {
const statusDropdown = getByText('Status', { ignore: 'th' });
expect(statusDropdown).toBeInTheDocument();
- fireEvent.click(statusDropdown);
+ await act(async () => {
+ fireEvent.click(statusDropdown);
+ });
const upgradable = getByRole('option', { name: 'select Upgradable' });
fireEvent.click(upgradable);
await patientlyWaitFor(() => {
@@ -235,8 +245,10 @@ test('Can upgrade a package via customized remote execution', async (done) => {
expect(getByText('libmagic1')).toBeInTheDocument();
});
- const kebabDropdown = getAllByLabelText('Actions');
- kebabDropdown[0].click();
+ const kebabDropdown = getAllByLabelText('Kebab toggle');
+ await act(async () => {
+ kebabDropdown[0].click();
+ });
const rexAction = getByText('Upgrade via customized remote execution');
const feature = REX_FEATURES.KATELLO_PACKAGE_UPDATE;
@@ -248,7 +260,9 @@ test('Can upgrade a package via customized remote execution', async (done) => {
`/job_invocations/new?feature=${feature}&search=name%20%5E%20(${hostname})&inputs%5Bpackage%5D=${packageName}`,
);
- fireEvent.click(rexAction);
+ await act(async () => {
+ fireEvent.click(rexAction);
+ });
assertNockRequest(autocompleteScope);
assertNockRequest(scope);
@@ -295,7 +309,9 @@ test('Can bulk upgrade via remote execution', async (done) => {
const rexAction = getByLabelText('bulk_upgrade_rex');
expect(rexAction).toBeInTheDocument();
- fireEvent.click(rexAction);
+ await act(async () => {
+ fireEvent.click(rexAction);
+ });
assertNockRequest(autocompleteScope);
assertNockRequest(scope);
diff --git a/webpack/components/extensions/HostDetails/Tabs/__tests__/errataTab.test.js b/webpack/components/extensions/HostDetails/Tabs/__tests__/errataTab.test.js
index 9bd09638032..901652cfad7 100644
--- a/webpack/components/extensions/HostDetails/Tabs/__tests__/errataTab.test.js
+++ b/webpack/components/extensions/HostDetails/Tabs/__tests__/errataTab.test.js
@@ -1,5 +1,5 @@
import React from 'react';
-import { renderWithRedux, patientlyWaitFor, within, fireEvent } from 'react-testing-lib-wrapper';
+import { renderWithRedux, patientlyWaitFor, within, fireEvent, act } from 'react-testing-lib-wrapper';
import { nockInstance, assertNockRequest, mockForemanAutocomplete } from '../../../../../test-utils/nockWrapper';
import { foremanApi } from '../../../../../services/api';
import { HOST_ERRATA_KEY, ERRATA_SEARCH_QUERY } from '../ErrataTab/HostErrataConstants';
@@ -815,7 +815,7 @@ test('Can filter by severity', async (done) => {
await patientlyWaitFor(() => expect(getAllByText('Important')[0]).toBeInTheDocument());
// the Bugfix text in the table is just a text node, while the dropdown is a button
expect(getByText('Moderate', { ignore: ['button', 'title'] })).toBeInTheDocument();
- expect(getByText('Important', { ignore: ['.pf-c-select__toggle-text', 'title'] })).toBeInTheDocument();
+ expect(getByText('Important', { ignore: ['.pf-v5-c-select__toggle-text', 'title'] })).toBeInTheDocument();
expect(getByText('Critical', { ignore: ['button', 'title'] })).toBeInTheDocument();
const severityContainer = queryByLabelText('select Severity container', { ignore: 'th' });
const severityDropdown = within(severityContainer).queryByText('Severity');
@@ -824,11 +824,11 @@ test('Can filter by severity', async (done) => {
const important = getByRole('option', { name: 'select Important' });
fireEvent.click(important);
await patientlyWaitFor(() => {
- expect(queryByText('Moderate', { ignore: ['.pf-c-select__toggle-text'] })).not.toBeInTheDocument();
- expect(queryByText('Critical', { ignore: ['.pf-c-select__toggle-text'] })).not.toBeInTheDocument();
+ expect(queryByText('Moderate', { ignore: ['.pf-v5-c-select__toggle-text'] })).not.toBeInTheDocument();
+ expect(queryByText('Critical', { ignore: ['.pf-v5-c-select__toggle-text'] })).not.toBeInTheDocument();
});
await patientlyWaitFor(() => {
- expect(getByText('Important', { ignore: ['.pf-c-select__toggle-text', 'title'] })).toBeInTheDocument();
+ expect(getByText('Important', { ignore: ['.pf-v5-c-select__toggle-text', 'title'] })).toBeInTheDocument();
});
@@ -871,7 +871,9 @@ test('Can bulk apply via remote execution', async (done) => {
actionMenu.click();
const viaRexAction = queryByText('Apply via remote execution');
expect(viaRexAction).toBeInTheDocument();
- viaRexAction.click();
+ await act(async () => {
+ viaRexAction.click();
+ });
assertNockRequest(autocompleteScope);
assertNockRequest(resolveErrataScope);
@@ -911,7 +913,9 @@ test('Can select all, exclude and bulk apply via remote execution', async (done)
actionMenu.click();
const viaRexAction = queryByText('Apply via remote execution');
expect(viaRexAction).toBeInTheDocument();
- viaRexAction.click();
+ await act(async () => {
+ viaRexAction.click();
+ });
assertNockRequest(autocompleteScope);
assertNockRequest(resolveErrataScope);
@@ -947,7 +951,9 @@ test('Can apply errata in bulk via customized remote execution', async (done) =>
`/job_invocations/new?feature=${feature}&search=name%20%5E%20(${hostName})&inputs%5BErrata%20search%20query%5D=errata_id%20%5E%20(${errata})`,
);
- viaRexAction.click();
+ await act(async () => {
+ viaRexAction.click();
+ });
assertNockRequest(autocompleteScope);
assertNockRequest(scope, done);
});
@@ -973,16 +979,20 @@ test('Can apply a single erratum to the host via remote execution', async (done)
renderOptions(cfWithErrataTotal(mockErrata.total)),
);
await patientlyWaitFor(() => expect(getAllByText('Important')[0]).toBeInTheDocument());
- const erratumActionMenu = within(getByLabelText('Select row 0').closest('tr')).getByLabelText('Actions');
- expect(erratumActionMenu).toHaveAttribute('aria-label', 'Actions');
- erratumActionMenu.click();
-
+ const erratumActionMenu = within(getByLabelText('Select row 0').closest('tr')).getByLabelText('Kebab toggle');
+ expect(erratumActionMenu).toHaveAttribute('aria-label', 'Kebab toggle');
+ await act(async () => {
+ erratumActionMenu.click();
+ });
+
let viaRexAction;
await patientlyWaitFor(() => {
viaRexAction = getByText('Apply via remote execution');
expect(viaRexAction).toBeInTheDocument();
});
- viaRexAction.click();
+ await act(async () => {
+ viaRexAction.click();
+ });
assertNockRequest(autocompleteScope);
assertNockRequest(resolveErrataScope);
@@ -1005,16 +1015,19 @@ test('Can apply a single erratum to the host via customized remote execution', a
renderOptions(cfWithErrataTotal(mockErrata.total)),
);
await patientlyWaitFor(() => expect(getAllByText('Important')[0]).toBeInTheDocument());
- const erratumActionMenu = within(getByLabelText('Select row 0').closest('tr')).getByLabelText('Actions');
- expect(erratumActionMenu).toHaveAttribute('aria-label', 'Actions');
- erratumActionMenu.click();
-
+ const erratumActionMenu = within(getByLabelText('Select row 0').closest('tr')).getByLabelText('Kebab toggle');
+ expect(erratumActionMenu).toHaveAttribute('aria-label', 'Kebab toggle');
+ await act(async () => {
+ erratumActionMenu.click();
+ });
let viaRexAction;
await patientlyWaitFor(() => {
viaRexAction = getByText('Apply via customized remote execution');
expect(viaRexAction).toBeInTheDocument();
});
- viaRexAction.click();
+ await act(async () => {
+ viaRexAction.click();
+ });
expect(viaRexAction).toHaveAttribute(
'href',
`/job_invocations/new?feature=${feature}&search=name%20%5E%20(${hostName})&inputs%5BErrata%20search%20query%5D=errata_id%20=%20${errataId}`,
diff --git a/webpack/components/extensions/HostDetails/Tabs/__tests__/packagesTab.test.js b/webpack/components/extensions/HostDetails/Tabs/__tests__/packagesTab.test.js
index 9cec92f7a0b..40680f8d169 100644
--- a/webpack/components/extensions/HostDetails/Tabs/__tests__/packagesTab.test.js
+++ b/webpack/components/extensions/HostDetails/Tabs/__tests__/packagesTab.test.js
@@ -1,5 +1,5 @@
import React from 'react';
-import { renderWithRedux, patientlyWaitFor, fireEvent } from 'react-testing-lib-wrapper';
+import { renderWithRedux, patientlyWaitFor, fireEvent, act, screen } from 'react-testing-lib-wrapper';
import * as hooks from 'foremanReact/components/PF4/TableIndexPage/Table/TableHooks';
import { nockInstance, assertNockRequest, mockForemanAutocomplete } from '../../../../../test-utils/nockWrapper';
import { foremanApi } from '../../../../../services/api';
@@ -135,9 +135,13 @@ test('Can filter by package status', async (done) => {
const statusDropdown = queryByText('Status', { ignore: 'th' });
expect(statusDropdown).toBeInTheDocument();
- fireEvent.click(statusDropdown);
+ await act(async () => {
+ fireEvent.click(statusDropdown);
+ });
const upgradable = getByRole('option', { name: 'select Upgradable' });
- fireEvent.click(upgradable);
+ await act(async () => {
+ fireEvent.click(upgradable);
+ });
await patientlyWaitFor(() => {
expect(queryByText('coreutils')).toBeInTheDocument();
expect(queryByText('acl')).not.toBeInTheDocument();
@@ -184,19 +188,27 @@ test('Can upgrade a package via remote execution', async (done) => {
const statusDropdown = getByText('Status', { ignore: 'th' });
expect(statusDropdown).toBeInTheDocument();
- fireEvent.click(statusDropdown);
+ await act(async () => {
+ fireEvent.click(statusDropdown);
+ });
const upgradable = getByRole('option', { name: 'select Upgradable' });
- fireEvent.click(upgradable);
+ await act(async () => {
+ fireEvent.click(upgradable);
+ });
await patientlyWaitFor(() => {
expect(getByText('coreutils')).toBeInTheDocument();
});
-
- const kebabDropdown = getByLabelText('Actions');
- kebabDropdown.click();
+
+ const kebabDropdown = getByLabelText('Kebab toggle');
+ await act(async () => {
+ kebabDropdown.click();
+ });
const rexAction = getByText('Upgrade via remote execution');
await patientlyWaitFor(() => expect(rexAction).toBeInTheDocument());
- fireEvent.click(rexAction);
+ await act(async () => {
+ fireEvent.click(rexAction);
+ });
assertNockRequest(autocompleteScope);
assertNockRequest(scope);
@@ -228,15 +240,21 @@ test('Can upgrade a package via customized remote execution', async (done) => {
const statusDropdown = getByText('Status', { ignore: 'th' });
expect(statusDropdown).toBeInTheDocument();
- fireEvent.click(statusDropdown);
+ await act(async () => {
+ fireEvent.click(statusDropdown);
+ });
const upgradable = getByRole('option', { name: 'select Upgradable' });
- fireEvent.click(upgradable);
+ await act(async () => {
+ fireEvent.click(upgradable);
+ });
await patientlyWaitFor(() => {
expect(getByText('coreutils')).toBeInTheDocument();
});
- const kebabDropdown = getByLabelText('Actions');
- kebabDropdown.click();
+ const kebabDropdown = getByLabelText('Kebab toggle');
+ await act(async () => {
+ kebabDropdown.click();
+ });
const rexAction = getByText('Upgrade via customized remote execution');
const feature = REX_FEATURES.KATELLO_PACKAGE_UPDATE;
@@ -247,8 +265,9 @@ test('Can upgrade a package via customized remote execution', async (done) => {
'href',
`/job_invocations/new?feature=${feature}&search=name%20%5E%20(${hostname})&inputs%5Bpackage%5D=${packageName}`,
);
-
- fireEvent.click(rexAction);
+ await act(async () => {
+ fireEvent.click(rexAction);
+ });
assertNockRequest(autocompleteScope);
assertNockRequest(scope);
@@ -292,11 +311,14 @@ test('Can bulk upgrade via remote execution', async (done) => {
expect(getByLabelText('Select row 1').checked).toEqual(true);
const upgradeDropdown = getAllByRole('button', { name: 'Select' })[1];
- fireEvent.click(upgradeDropdown);
-
+ await act(async () => {
+ fireEvent.click(upgradeDropdown);
+ });
const rexAction = getByLabelText('bulk_upgrade_rex');
expect(rexAction).toBeInTheDocument();
- fireEvent.click(rexAction);
+ await act(async () => {
+ fireEvent.click(rexAction);
+ });
assertNockRequest(autocompleteScope);
assertNockRequest(scope);
@@ -331,7 +353,9 @@ test('Can bulk upgrade via customized remote execution', async (done) => {
expect(getByLabelText('Select row 1').checked).toEqual(true);
const upgradeDropdown = getAllByRole('button', { name: 'Select' })[1];
- fireEvent.click(upgradeDropdown);
+ await act(async () => {
+ fireEvent.click(upgradeDropdown);
+ });
expect(upgradeDropdown).not.toHaveAttribute('disabled');
const rexAction = getByLabelText('bulk_upgrade_customized_rex');
diff --git a/webpack/components/extensions/HostDetails/Tabs/__tests__/repositorySetsTab.test.js b/webpack/components/extensions/HostDetails/Tabs/__tests__/repositorySetsTab.test.js
index f198a1c4155..ad0888a5e66 100644
--- a/webpack/components/extensions/HostDetails/Tabs/__tests__/repositorySetsTab.test.js
+++ b/webpack/components/extensions/HostDetails/Tabs/__tests__/repositorySetsTab.test.js
@@ -1,5 +1,5 @@
import React from 'react';
-import { renderWithRedux, patientlyWaitFor, within, fireEvent } from 'react-testing-lib-wrapper';
+import { renderWithRedux, patientlyWaitFor, within, fireEvent, act } from 'react-testing-lib-wrapper';
import { nockInstance, assertNockRequest, mockAutocomplete } from '../../../../../test-utils/nockWrapper';
import katelloApi, { foremanApi } from '../../../../../services/api';
import { REPOSITORY_SETS_KEY } from '../RepositorySetsTab/RepositorySetsConstants';
@@ -244,9 +244,10 @@ test('Can override to disabled', async (done) => {
expect(getAllByText('Enabled')).toHaveLength(2);
expect(getAllByText('Disabled')).toHaveLength(1);
// Find the first action menu and click it
- const actionMenu = getAllByLabelText('Actions')[0].closest('button');
- fireEvent.click(actionMenu);
-
+ const actionMenu = getAllByLabelText('Kebab toggle')[0].closest('button');
+ await act(async () => {
+ fireEvent.click(actionMenu);
+ });
const overrideMenuItem = getByText('Override to disabled');
expect(overrideMenuItem).toBeInTheDocument();
fireEvent.click(overrideMenuItem);
@@ -284,8 +285,10 @@ test('Can override to enabled', async (done) => {
expect(getAllByText('Enabled')).toHaveLength(2);
expect(getAllByText('Disabled')).toHaveLength(1);
// The second item is overridden to disabled; we're going to override to enabled
- const actionMenu = getAllByLabelText('Actions')[1].closest('button');
- fireEvent.click(actionMenu);
+ const actionMenu = getAllByLabelText('Kebab toggle')[1].closest('button');
+ await act(async () => {
+ fireEvent.click(actionMenu);
+ });
const overrideMenuItem = getByText('Override to enabled');
expect(overrideMenuItem).toBeInTheDocument();
@@ -323,8 +326,10 @@ test('Can reset to default', async (done) => {
expect(getAllByText('Disabled')).toHaveLength(1);
// The second item is overridden to disabled but would normally be enabled; we're going to reset
- const actionMenu = getAllByLabelText('Actions')[1].closest('button');
- fireEvent.click(actionMenu);
+ const actionMenu = getAllByLabelText('Kebab toggle')[1].closest('button');
+ await act(async () => {
+ fireEvent.click(actionMenu);
+ });
const overrideMenuItem = getByText('Reset to default');
expect(overrideMenuItem).toBeInTheDocument();
@@ -358,7 +363,9 @@ test('Can override in bulk', async (done) => {
getByLabelText('Select row 0').click();
getByLabelText('Select row 1').click();
const actionMenu = getByLabelText('bulk_actions');
- actionMenu.click();
+ await act(async () => {
+ fireEvent.click(actionMenu);
+ });
const resetToDefault = queryByText('Reset to default');
expect(resetToDefault).toBeInTheDocument();
resetToDefault.click();
@@ -391,7 +398,9 @@ test('Can override in bulk when limited to environment', async (done) => {
await patientlyWaitFor(() => expect(getByText(firstRepoSet.contentUrl)).toBeInTheDocument());
getByLabelText('Select all').click();
const actionMenu = getByLabelText('bulk_actions');
- actionMenu.click();
+ await act(async () => {
+ fireEvent.click(actionMenu);
+ });
const resetToDefault = queryByText('Reset to default');
expect(resetToDefault).toBeInTheDocument();
resetToDefault.click();
@@ -422,7 +431,9 @@ test('Can filter by status', async (done) => {
const statusContainer = queryByLabelText('select Status container', { ignore: 'th' });
const statusDropdown = within(statusContainer).queryByText('Status');
expect(statusDropdown).toBeInTheDocument();
- fireEvent.click(statusDropdown);
+ await act(async () => {
+ fireEvent.click(statusDropdown);
+ });
const overridden = getByRole('option', { name: 'select Overridden' });
fireEvent.click(overridden);
await patientlyWaitFor(() => {
diff --git a/webpack/components/extensions/HostDetails/Tabs/__tests__/tracesTab.test.js b/webpack/components/extensions/HostDetails/Tabs/__tests__/tracesTab.test.js
index 8f3e7f912e9..1601f6b947d 100644
--- a/webpack/components/extensions/HostDetails/Tabs/__tests__/tracesTab.test.js
+++ b/webpack/components/extensions/HostDetails/Tabs/__tests__/tracesTab.test.js
@@ -49,7 +49,7 @@ const renderOptions = isTracerInstalled => ({ // sets initial Redux state
},
});
-const actionMenuToTheRightOf = node => node.nextElementSibling.firstElementChild.firstElementChild;
+const actionMenuToTheRightOf = node => node.nextElementSibling.firstElementChild;
const hostTraces = foremanApi.getApiUrl('/hosts/1/traces');
const autocompleteUrl = '/hosts/1/traces/auto_complete_search';
@@ -227,7 +227,10 @@ describe('With tracer installed', () => {
fireEvent.click(traceCheckbox);
expect(traceCheckbox.checked).toEqual(true);
const actionMenu = getByLabelText('bulk_actions');
- actionMenu.click();
+
+ await act(async () => {
+ actionMenu.click();
+ });
const viaRexAction = queryByText('Restart via remote execution');
expect(viaRexAction).toBeInTheDocument();
viaRexAction.click();
@@ -268,13 +271,18 @@ describe('With tracer installed', () => {
const selectAllCheckbox = getByLabelText('Select all');
- fireEvent.click(selectAllCheckbox);
+
+ await act(async () => {
+ fireEvent.click(selectAllCheckbox);
+ });
expect(traceCheckbox.checked).toEqual(true);
fireEvent.click(getByLabelText('Select row 0')); // de select
fireEvent.click(getByLabelText('Select row 2')); // de select
- fireEvent.click(getByText('Reboot host'));
+ await act(async () => {
+ fireEvent.click(getByText('Reboot host'));
+ });
assertNockRequest(autocompleteScope);
assertNockRequest(resolveTracesScope);
@@ -301,17 +309,19 @@ describe('With tracer installed', () => {
await patientlyWaitFor(() => {
const traceNameNode = getByText(firstTrace.helper);
traceActionMenu = actionMenuToTheRightOf(traceNameNode);
- expect(traceActionMenu).toHaveAttribute('aria-label', 'Actions');
+ expect(traceActionMenu).toHaveAttribute('aria-label', 'Kebab toggle');
+ });
+ await act(async () => {
+ traceActionMenu.click();
});
- traceActionMenu.click();
-
let viaRexAction;
await patientlyWaitFor(() => {
viaRexAction = getByText('Restart via remote execution');
expect(viaRexAction).toBeInTheDocument();
});
- viaRexAction.click();
-
+ await act(async () => {
+ viaRexAction.click();
+ });
assertNockRequest(autocompleteScope);
assertNockRequest(resolveTracesScope);
assertNockRequest(scope, done);
@@ -334,10 +344,11 @@ describe('With tracer installed', () => {
await patientlyWaitFor(() => {
const traceNameNode = getByText(firstTrace.helper);
traceActionMenu = actionMenuToTheRightOf(traceNameNode);
- expect(traceActionMenu).toHaveAttribute('aria-label', 'Actions');
+ expect(traceActionMenu).toHaveAttribute('aria-label', 'Kebab toggle');
+ });
+ await act(async () => {
+ fireEvent.click(traceActionMenu);
});
- fireEvent.click(traceActionMenu);
-
let viaCustomizedRexAction;
await patientlyWaitFor(() => {
viaCustomizedRexAction = getByText('Restart via customized remote execution');
@@ -372,7 +383,9 @@ describe('With tracer installed', () => {
expect(traceCheckbox.checked).toEqual(true);
const actionMenu = getByLabelText('bulk_actions');
- fireEvent.click(actionMenu);
+ await act(async () => {
+ fireEvent.click(actionMenu);
+ });
const viaCustomizedRexAction = queryByText('Restart via customized remote execution');
expect(viaCustomizedRexAction).toBeInTheDocument();
diff --git a/webpack/components/extensions/Hosts/BulkActions/BulkErrataWizard/04_Review.js b/webpack/components/extensions/Hosts/BulkActions/BulkErrataWizard/04_Review.js
index 985556c0735..d3d527c791d 100644
--- a/webpack/components/extensions/Hosts/BulkActions/BulkErrataWizard/04_Review.js
+++ b/webpack/components/extensions/Hosts/BulkActions/BulkErrataWizard/04_Review.js
@@ -1,8 +1,22 @@
import React, { useContext, useState } from 'react';
import { translate as __ } from 'foremanReact/common/I18n';
import { FormattedMessage } from 'react-intl';
-import { TreeView, Button, Text, TextContent, TextVariants, Flex, FlexItem, Dropdown, DropdownItem, DropdownToggle } from '@patternfly/react-core';
-import { useWizardContext } from '@patternfly/react-core/next';
+import {
+ TreeView,
+ Button,
+ Text,
+ TextContent,
+ TextVariants,
+ Flex,
+ FlexItem,
+ useWizardContext, /* data-codemods */
+} from '@patternfly/react-core';
+import {
+ Dropdown,
+ DropdownItem,
+ DropdownToggle,
+} from '@patternfly/react-core/deprecated';
+
import { CaretDownIcon } from '@patternfly/react-icons';
import { BulkErrataWizardContext } from './BulkErrataWizard';
diff --git a/webpack/components/extensions/Hosts/BulkActions/BulkErrataWizard/04_ReviewFooter.js b/webpack/components/extensions/Hosts/BulkActions/BulkErrataWizard/04_ReviewFooter.js
index a70e0c4932b..8fcf92a80a6 100644
--- a/webpack/components/extensions/Hosts/BulkActions/BulkErrataWizard/04_ReviewFooter.js
+++ b/webpack/components/extensions/Hosts/BulkActions/BulkErrataWizard/04_ReviewFooter.js
@@ -1,7 +1,11 @@
import React, { useContext } from 'react';
import { translate as __ } from 'foremanReact/common/I18n';
-import { Button } from '@patternfly/react-core';
-import { WizardFooterWrapper, useWizardContext } from '@patternfly/react-core/next';
+import {
+ Button,
+ WizardFooterWrapper /* data-codemods */,
+ useWizardContext, /* data-codemods */
+} from '@patternfly/react-core';
+
import { BulkErrataWizardContext } from './BulkErrataWizard';
import { dropdownOptions } from './04_Review';
import { errataInstallUrl } from '../../../HostDetails/Tabs/customizedRexUrlHelpers';
diff --git a/webpack/components/extensions/Hosts/BulkActions/BulkErrataWizard/BulkErrataWizard.js b/webpack/components/extensions/Hosts/BulkActions/BulkErrataWizard/BulkErrataWizard.js
index fc7756dfcbe..93376fa2c20 100644
--- a/webpack/components/extensions/Hosts/BulkActions/BulkErrataWizard/BulkErrataWizard.js
+++ b/webpack/components/extensions/Hosts/BulkActions/BulkErrataWizard/BulkErrataWizard.js
@@ -1,5 +1,11 @@
import React, { useState, createContext, useContext } from 'react';
-import { Wizard, WizardHeader, WizardStep } from '@patternfly/react-core/next';
+import {
+ Wizard /* data-codemods */,
+ WizardHeader, /* data-codemods */
+} from '@patternfly/react-core';
+import {
+ WizardStep,
+} from '@patternfly/react-core/deprecated';
import { translate as __ } from 'foremanReact/common/I18n';
import { useForemanModal } from 'foremanReact/components/ForemanModal/ForemanModalHooks';
import { useBulkSelect } from 'foremanReact/components/PF4/TableIndexPage/Table/TableHooks';
diff --git a/webpack/components/extensions/Hosts/BulkActions/BulkPackagesWizard/04_Review.js b/webpack/components/extensions/Hosts/BulkActions/BulkPackagesWizard/04_Review.js
index 9da783296e6..99b791eb398 100644
--- a/webpack/components/extensions/Hosts/BulkActions/BulkPackagesWizard/04_Review.js
+++ b/webpack/components/extensions/Hosts/BulkActions/BulkPackagesWizard/04_Review.js
@@ -1,8 +1,22 @@
import React, { useContext, useState } from 'react';
import { translate as __ } from 'foremanReact/common/I18n';
import { FormattedMessage } from 'react-intl';
-import { TreeView, Button, Text, TextContent, TextVariants, Flex, FlexItem, Dropdown, DropdownItem, DropdownToggle } from '@patternfly/react-core';
-import { useWizardContext } from '@patternfly/react-core/next';
+import {
+ TreeView,
+ Button,
+ Text,
+ TextContent,
+ TextVariants,
+ Flex,
+ FlexItem,
+ useWizardContext, /* data-codemods */
+} from '@patternfly/react-core';
+import {
+ Dropdown,
+ DropdownItem,
+ DropdownToggle,
+} from '@patternfly/react-core/deprecated';
+
import { CaretDownIcon } from '@patternfly/react-icons';
import { BulkPackagesWizardContext, UPGRADE_ALL, INSTALL, REMOVE, UPGRADE } from './BulkPackagesWizard';
diff --git a/webpack/components/extensions/Hosts/BulkActions/BulkPackagesWizard/04_ReviewFooter.js b/webpack/components/extensions/Hosts/BulkActions/BulkPackagesWizard/04_ReviewFooter.js
index 452ef4120a4..18279ecde68 100644
--- a/webpack/components/extensions/Hosts/BulkActions/BulkPackagesWizard/04_ReviewFooter.js
+++ b/webpack/components/extensions/Hosts/BulkActions/BulkPackagesWizard/04_ReviewFooter.js
@@ -1,7 +1,11 @@
import React, { useContext } from 'react';
import { translate as __ } from 'foremanReact/common/I18n';
-import { Button } from '@patternfly/react-core';
-import { WizardFooterWrapper, useWizardContext } from '@patternfly/react-core/next';
+import {
+ Button,
+ WizardFooterWrapper /* data-codemods */,
+ useWizardContext, /* data-codemods */
+} from '@patternfly/react-core';
+
import { BulkPackagesWizardContext, INSTALL, UPGRADE, UPGRADE_ALL, REMOVE } from './BulkPackagesWizard';
import { dropdownOptions } from './04_Review';
import { katelloPackageInstallBySearchUrl, packagesUpdateUrl, katelloPackageRemoveBySearchUrl } from '../../../HostDetails/Tabs/customizedRexUrlHelpers';
diff --git a/webpack/components/extensions/Hosts/BulkActions/BulkPackagesWizard/BulkPackagesWizard.js b/webpack/components/extensions/Hosts/BulkActions/BulkPackagesWizard/BulkPackagesWizard.js
index a523d4c03c7..2d6a268cdbe 100644
--- a/webpack/components/extensions/Hosts/BulkActions/BulkPackagesWizard/BulkPackagesWizard.js
+++ b/webpack/components/extensions/Hosts/BulkActions/BulkPackagesWizard/BulkPackagesWizard.js
@@ -1,6 +1,17 @@
import React, { useState, createContext, useContext } from 'react';
-import { Radio, Text, TextVariants, TextContent, Alert } from '@patternfly/react-core';
-import { Wizard, WizardHeader, WizardStep } from '@patternfly/react-core/next';
+import {
+ Radio,
+ Text,
+ TextVariants,
+ TextContent,
+ Alert,
+ Wizard /* data-codemods */,
+ WizardHeader, /* data-codemods */
+} from '@patternfly/react-core';
+import {
+ WizardStep,
+} from '@patternfly/react-core/deprecated';
+
import { translate as __ } from 'foremanReact/common/I18n';
import { useForemanModal } from 'foremanReact/components/ForemanModal/ForemanModalHooks';
import { useBulkSelect } from 'foremanReact/components/PF4/TableIndexPage/Table/TableHooks';
diff --git a/webpack/components/extensions/RegistrationCommands/__tests__/__snapshots__/ActivationKeys.test.js.snap b/webpack/components/extensions/RegistrationCommands/__tests__/__snapshots__/ActivationKeys.test.js.snap
index a85d2d625a3..3b681a443b2 100644
--- a/webpack/components/extensions/RegistrationCommands/__tests__/__snapshots__/ActivationKeys.test.js.snap
+++ b/webpack/components/extensions/RegistrationCommands/__tests__/__snapshots__/ActivationKeys.test.js.snap
@@ -3,21 +3,6 @@
exports[`ActivationKeys renders 1`] = `
- Create new activation key
-
- }
- helperTextInvalidIcon={
-
- }
isRequired={true}
label="Activation Keys"
labelIcon={
@@ -26,7 +11,6 @@ exports[`ActivationKeys renders 1`] = `
/>
}
onFocus={[Function]}
- validated="error"
>
+
+
+ }
+ variant="error"
+ >
+
+ Create new activation key
+
+
+
+
`;
diff --git a/webpack/components/extensions/RegistrationCommands/__tests__/__snapshots__/Force.test.js.snap b/webpack/components/extensions/RegistrationCommands/__tests__/__snapshots__/Force.test.js.snap
index 8dab454e997..5eb5bfc07ae 100644
--- a/webpack/components/extensions/RegistrationCommands/__tests__/__snapshots__/Force.test.js.snap
+++ b/webpack/components/extensions/RegistrationCommands/__tests__/__snapshots__/Force.test.js.snap
@@ -6,10 +6,10 @@ exports[`Force renders 1`] = `
>
{
handleInvalidField(
'Activation Keys',
- akHasValidValue(
- hostGroupId,
- pluginValues?.activationKeys,
- hostGroupActivationKeys,
- ),
+ akHasValidValue(hostGroupId, pluginValues?.activationKeys, hostGroupActivationKeys),
);
}, [handleInvalidField, hostGroupId, hostGroupActivationKeys, pluginValues]);
@@ -68,33 +53,20 @@ const ActivationKeys = ({
}
}, [activationKeys, onChange]);
+ const isError =
+ validateAKField(
+ hasInteraction,
+ hostGroupId,
+ activationKeys,
+ pluginValues?.activationKeys,
+ hostGroupActivationKeys,
+ ) === 'error';
return (
setHasInteraction(true)}
label={__('Activation Keys')}
fieldId="activation_keys_field"
- helperText={
- hostGroupActivationKeys &&
- sprintf('From host group: %s', hostGroupActivationKeys)
- }
- helperTextInvalid={
- activationKeys?.length === 0 ? (
- {__('Create new activation key')}
- ) : (
- __('No Activation Keys selected')
- )
- }
- helperTextInvalidIcon={}
- labelIcon={
-
- }
- validated={validateAKField(
- hasInteraction,
- hostGroupId,
- activationKeys,
- pluginValues?.activationKeys,
- hostGroupActivationKeys,
- )}
+ labelIcon={}
isRequired
>
+ {isError && (
+
+
+ }>
+ {activationKeys?.length === 0 ? (
+ {__('Create new activation key')}
+ ) : (
+ __('No Activation Keys selected')
+ )}
+
+
+
+ )}
+ {!isError && hostGroupActivationKeys && (
+
+
+
+ {sprintf('From host group: %s', hostGroupActivationKeys)}
+
+
+
+ )}
);
};
@@ -142,10 +134,7 @@ const ActivationKeys = ({
ActivationKeys.propTypes = {
activationKeys: PropTypes.array,
selectedKeys: PropTypes.array,
- hostGroupActivationKeys: PropTypes.oneOfType([
- PropTypes.string,
- PropTypes.array,
- ]),
+ hostGroupActivationKeys: PropTypes.oneOfType([PropTypes.string, PropTypes.array]),
hostGroupId: PropTypes.oneOfType([PropTypes.string, PropTypes.number]),
pluginValues: PropTypes.shape({
activationKeys: PropTypes.array,
diff --git a/webpack/containers/Application/overrides.scss b/webpack/containers/Application/overrides.scss
index db911da7ec0..c282c0b48e9 100644
--- a/webpack/containers/Application/overrides.scss
+++ b/webpack/containers/Application/overrides.scss
@@ -122,7 +122,7 @@ html .pagination-pf-pagesize.btn-group {
}
// Modal sizing fix
-.pf-l-bullseye .pf-c-modal-box {
+.pf-l-bullseye .pf-v5-c-modal-box {
margin-top: 76px;
max-height: calc(100vh - 76px);
@@ -168,24 +168,24 @@ html .pagination-pf-pagesize.btn-group {
.primary-detail-border {
border-top: 0.2px;
- border-top-color: var(--pf-c-table--BorderColor);
+ border-top-color: var(--pf-v5-c-table--BorderColor);
border-top-style: inset;
}
.primary-detail-stack-items-border {
border-bottom: 0.2px;
- border-bottom-color: var(--pf-c-table--BorderColor);
+ border-bottom-color: var(--pf-v5-c-table--BorderColor);
border-bottom-style: inset;
}
.border-left {
border-left: 0.2px;
- border-left-color: var(--pf-c-table--BorderColor);
+ border-left-color: var(--pf-v5-c-table--BorderColor);
border-left-style: inset;
}
.border-right {
border-right: 0.2px;
- border-right-color: var(--pf-c-table--BorderColor);
+ border-right-color: var(--pf-v5-c-table--BorderColor);
border-right-style: inset;
}
diff --git a/webpack/ouia_id_check.js b/webpack/ouia_id_check.js
index b14c03e6d42..e9fc2f9af6e 100644
--- a/webpack/ouia_id_check.js
+++ b/webpack/ouia_id_check.js
@@ -7,12 +7,6 @@ import {
Checkbox,
Chip,
ChipGroup,
- ContextSelector,
- Dropdown,
- DropdownItem,
- DropdownSeparator,
- DropdownToggle,
- DropdownToggleCheckbox,
FormSelect,
Menu,
Modal,
@@ -20,10 +14,8 @@ import {
Nav,
NavExpandable,
NavItem,
- OptionsMenu,
Pagination,
Radio,
- Select,
Switch,
TabButton,
TabContent,
@@ -34,10 +26,22 @@ import {
Toolbar,
} from '@patternfly/react-core';
import {
- Table,
- TableComposable,
+ ContextSelector,
+ Dropdown,
+ DropdownItem,
+ DropdownSeparator,
+ DropdownToggle,
+ DropdownToggleCheckbox,
+ OptionsMenu,
+ Select,
+} from '@patternfly/react-core/deprecated';
+import {
Tr,
} from '@patternfly/react-table';
+import {
+ Table as TableDeprecated,
+ Table,
+} from '@patternfly/react-table/deprecated';
const checkForOuiaIds = () => {
const ouiaSupportedPFComponents = [
@@ -74,7 +78,7 @@ const checkForOuiaIds = () => {
Title,
Toolbar,
Table,
- TableComposable,
+ TableDeprecated,
Tr,
];
beforeEach(() => {
diff --git a/webpack/scenes/ActivationKeys/Details/components/DeleteMenu.js b/webpack/scenes/ActivationKeys/Details/components/DeleteMenu.js
index a778a84491a..ce1270ebd5d 100644
--- a/webpack/scenes/ActivationKeys/Details/components/DeleteMenu.js
+++ b/webpack/scenes/ActivationKeys/Details/components/DeleteMenu.js
@@ -2,7 +2,17 @@ import React, {
useState,
} from 'react';
import PropTypes from 'prop-types';
-import { Dropdown, DropdownItem, KebabToggle, DropdownPosition, Split, Icon, Text } from '@patternfly/react-core';
+import {
+ Split,
+ Icon,
+ Text,
+} from '@patternfly/react-core';
+import {
+ Dropdown,
+ DropdownItem,
+ KebabToggle,
+ DropdownPosition,
+} from '@patternfly/react-core/deprecated';
import { UndoIcon, TrashIcon } from '@patternfly/react-icons';
import { noop } from 'foremanReact/common/helpers';
import { translate as __ } from 'foremanReact/common/I18n';
@@ -56,7 +66,7 @@ const DeleteMenu = ({ handleModalToggle, akId }) => {
ouiaId="dekete-action"
onSelect={onSelect}
position={DropdownPosition.right}
- toggle={}
+ toggle={ onToggle(isOpenValue)} />}
isOpen={isOpen}
isPlain
dropdownItems={dropdownItems}
diff --git a/webpack/scenes/ActivationKeys/Details/components/EditModal.js b/webpack/scenes/ActivationKeys/Details/components/EditModal.js
index dce67c293af..2ac6ad0c14f 100644
--- a/webpack/scenes/ActivationKeys/Details/components/EditModal.js
+++ b/webpack/scenes/ActivationKeys/Details/components/EditModal.js
@@ -131,7 +131,7 @@ const EditModal = ({ akDetails, akId }) => {
id="ak-name-input"
type="text"
value={nameValue}
- onChange={handleNameInputChange}
+ onChange={(_event, value) => handleNameInputChange(value)}
/>
{
minusBtnAriaLabel="minus"
plusBtnAriaLabel="plus"
isDisabled={isUnlimited}
- allowEmptyInput
+
/>
@@ -172,7 +172,7 @@ const EditModal = ({ akDetails, akId }) => {
type="text"
placeholder={__('Description')}
value={descriptionValue || ''}
- onChange={handleDescriptionInputChange}
+ onChange={(_event, value) => handleDescriptionInputChange(value)}
/>
diff --git a/webpack/scenes/AlternateContentSources/Create/ACSCreateWizard.js b/webpack/scenes/AlternateContentSources/Create/ACSCreateWizard.js
index 0f3a41105f2..24d28810574 100644
--- a/webpack/scenes/AlternateContentSources/Create/ACSCreateWizard.js
+++ b/webpack/scenes/AlternateContentSources/Create/ACSCreateWizard.js
@@ -1,7 +1,9 @@
import React, { useEffect, useState } from 'react';
import { useDispatch } from 'react-redux';
import PropTypes from 'prop-types';
-import { Wizard } from '@patternfly/react-core';
+import {
+ Wizard,
+} from '@patternfly/react-core/deprecated';
import { translate as __ } from 'foremanReact/common/I18n';
import ACSCreateContext from './ACSCreateContext';
import SelectSource from './Steps/SelectSource';
diff --git a/webpack/scenes/AlternateContentSources/Create/Steps/ACSCreateFinish.js b/webpack/scenes/AlternateContentSources/Create/Steps/ACSCreateFinish.js
index 3beb374d835..637b92ff9a5 100644
--- a/webpack/scenes/AlternateContentSources/Create/Steps/ACSCreateFinish.js
+++ b/webpack/scenes/AlternateContentSources/Create/Steps/ACSCreateFinish.js
@@ -3,7 +3,9 @@ import { useDispatch, useSelector } from 'react-redux';
import { useHistory } from 'react-router-dom';
import PropTypes from 'prop-types';
import useDeepCompareEffect from 'use-deep-compare-effect';
-import { WizardContextConsumer } from '@patternfly/react-core';
+import {
+ WizardContextConsumer,
+} from '@patternfly/react-core/deprecated';
import { translate as __ } from 'foremanReact/common/I18n';
import { STATUS } from 'foremanReact/constants';
import ACSCreateContext from '../ACSCreateContext';
diff --git a/webpack/scenes/AlternateContentSources/Create/Steps/ACSCredentials.js b/webpack/scenes/AlternateContentSources/Create/Steps/ACSCredentials.js
index 40dd20d9ad4..523d9fc44d7 100644
--- a/webpack/scenes/AlternateContentSources/Create/Steps/ACSCredentials.js
+++ b/webpack/scenes/AlternateContentSources/Create/Steps/ACSCredentials.js
@@ -76,7 +76,7 @@ const ACSCredentials = () => {
name="acs_username_field"
aria-label="acs_username_field"
value={username}
- onChange={(value) => { setUsername(value); }}
+ onChange={(_event, value) => { setUsername(value); }}
/>
@@ -93,7 +93,7 @@ const ACSCredentials = () => {
name="acs_password_field"
aria-label="acs_password_field"
value={password}
- onChange={(value) => { setPassword(value); }}
+ onChange={(_event, value) => { setPassword(value); }}
/>
>
@@ -122,7 +122,10 @@ const ACSCredentials = () => {
ouiaId="sslCert-select"
isRequired
value={sslCert}
- onChange={(value) => { setSslCert(value); setSslCertName(getCertName(value)); }}
+ onChange={(_event, value) => {
+ setSslCert(value);
+ setSslCertName(getCertName(value));
+ }}
aria-label="sslCert_select"
>
{
@@ -152,7 +155,7 @@ const ACSCredentials = () => {
ouiaId="sslKey-select"
isRequired
value={sslKey}
- onChange={(value) => { setSslKey(value); setSslKeyName(getCertName(value)); }}
+ onChange={(_event, value) => { setSslKey(value); setSslKeyName(getCertName(value)); }}
aria-label="sslKey_select"
>
{
@@ -198,7 +201,7 @@ const ACSCredentials = () => {
ouiaId="verify-ssl-switch"
aria-label="verify-ssl-switch"
isChecked={verifySSL}
- onChange={checked => setVerifySSL(checked)}
+ onChange={(_event, checked) => setVerifySSL(checked)}
/>
{
isDisabled={!verifySSL}
isRequired
value={caCert}
- onChange={(value) => { setCACert(value); setCACertName(getCertName(value)); }}
+ onChange={(_event, value) => { setCACert(value); setCACertName(getCertName(value)); }}
aria-label="sslCAcert_select"
>
{
diff --git a/webpack/scenes/AlternateContentSources/Create/Steps/ACSSmartProxies.js b/webpack/scenes/AlternateContentSources/Create/Steps/ACSSmartProxies.js
index 56a2881d7e3..f127c8d75a6 100644
--- a/webpack/scenes/AlternateContentSources/Create/Steps/ACSSmartProxies.js
+++ b/webpack/scenes/AlternateContentSources/Create/Steps/ACSSmartProxies.js
@@ -58,7 +58,7 @@ const ACSSmartProxies = () => {
ouiaId="use-http-proxies-switch"
aria-label="use-http-proxies-switch"
isChecked={useHttpProxies}
- onChange={checked => setUseHttpProxies(checked)}
+ onChange={(_event, checked) => setUseHttpProxies(checked)}
/>
>
diff --git a/webpack/scenes/AlternateContentSources/Create/Steps/AcsUrlPaths.js b/webpack/scenes/AlternateContentSources/Create/Steps/AcsUrlPaths.js
index 8d84f5e9c3e..9e67fea21f3 100644
--- a/webpack/scenes/AlternateContentSources/Create/Steps/AcsUrlPaths.js
+++ b/webpack/scenes/AlternateContentSources/Create/Steps/AcsUrlPaths.js
@@ -6,6 +6,9 @@ import {
FormGroup,
TextInput,
TextArea,
+ FormHelperText,
+ HelperText,
+ HelperTextItem,
} from '@patternfly/react-core';
import ACSCreateContext from '../ACSCreateContext';
import WizardHeader from '../../../ContentViews/components/WizardHeader';
@@ -41,8 +44,6 @@ const AcsUrlPaths = () => {
{
placeholder={baseURLplaceholder}
value={url}
validated={urlValidated}
- onChange={value => setUrl(value)}
+ onChange={(_event, value) => setUrl(value)}
/>
+ {urlValidated === 'error' && (
+
+
+
+ {helperTextInvalid}
+
+
+
+ )}
{acsType === 'rhui' &&
<>
@@ -73,19 +83,24 @@ const AcsUrlPaths = () => {
>
diff --git a/webpack/scenes/AlternateContentSources/Create/Steps/NameACS.js b/webpack/scenes/AlternateContentSources/Create/Steps/NameACS.js
index cdbd0915941..e86df124893 100644
--- a/webpack/scenes/AlternateContentSources/Create/Steps/NameACS.js
+++ b/webpack/scenes/AlternateContentSources/Create/Steps/NameACS.js
@@ -35,7 +35,7 @@ const NameACS = () => {
name="acs_name_field"
aria-label="acs_name_field"
value={name}
- onChange={(value) => { setName(value); }}
+ onChange={(_event, value) => { setName(value); }}
/>
{
>
{
isRequired
isDisabled={!acsVerifySSL}
value={acsCAcert}
- onChange={value => setAcsCAcert(value)}
+ onChange={(_event, value) => setAcsCAcert(value)}
aria-label="sslCAcert_select"
>
{
@@ -197,7 +197,7 @@ const ACSEditCredentials = ({ onClose, acsId, acsDetails }) => {
name="acs_username_field"
aria-label="acs_username_field"
value={acsUsername}
- onChange={(value) => {
+ onChange={(_event, value) => {
setAcsUsername(value);
}}
/>
@@ -216,7 +216,7 @@ const ACSEditCredentials = ({ onClose, acsId, acsDetails }) => {
name="acs_password_field"
aria-label="acs_password_field"
value={acsPassword}
- onChange={(value) => {
+ onChange={(_event, value) => {
setAcsPassword(value);
}}
/>
@@ -247,7 +247,7 @@ const ACSEditCredentials = ({ onClose, acsId, acsDetails }) => {
ouiaId="ssl-client-cert-select"
isRequired
value={acsSslClientCert}
- onChange={value => setAcsSslClientCert(value)}
+ onChange={(_event, value) => setAcsSslClientCert(value)}
aria-label="ssl_client_cert_select"
>
{
@@ -276,7 +276,7 @@ const ACSEditCredentials = ({ onClose, acsId, acsDetails }) => {
ouiaId="ssl_client_key_select"
isRequired
value={acsSslClientKey}
- onChange={value => setAcsSslClientKey(value)}
+ onChange={(_event, value) => setAcsSslClientKey(value)}
aria-label="ssl_client_key_select"
>
{
diff --git a/webpack/scenes/AlternateContentSources/Details/EditModals/ACSEditDetails.js b/webpack/scenes/AlternateContentSources/Details/EditModals/ACSEditDetails.js
index 6a8d4da90aa..2869e042d7f 100644
--- a/webpack/scenes/AlternateContentSources/Details/EditModals/ACSEditDetails.js
+++ b/webpack/scenes/AlternateContentSources/Details/EditModals/ACSEditDetails.js
@@ -50,7 +50,7 @@ const ACSEditDetails = ({ onClose, acsId, acsDetails }) => {
name="acs_name_field"
aria-label="acs_name_field"
value={acsName}
- onChange={(value) => {
+ onChange={(_event, value) => {
setACSName(value);
}}
/>
@@ -62,7 +62,7 @@ const ACSEditDetails = ({ onClose, acsId, acsDetails }) => {
>
diff --git a/webpack/scenes/AlternateContentSources/Details/EditModals/ACSEditURLPaths.js b/webpack/scenes/AlternateContentSources/Details/EditModals/ACSEditURLPaths.js
index 8b996325ef8..71c4525118b 100644
--- a/webpack/scenes/AlternateContentSources/Details/EditModals/ACSEditURLPaths.js
+++ b/webpack/scenes/AlternateContentSources/Details/EditModals/ACSEditURLPaths.js
@@ -2,7 +2,19 @@ import React, { useState } from 'react';
import { useDispatch } from 'react-redux';
import PropTypes from 'prop-types';
import { translate as __ } from 'foremanReact/common/I18n';
-import { ActionGroup, Button, Form, FormGroup, Modal, ModalVariant, TextArea, TextInput } from '@patternfly/react-core';
+import {
+ ActionGroup,
+ Button,
+ Form,
+ FormGroup,
+ Modal,
+ ModalVariant,
+ TextArea,
+ TextInput,
+ FormHelperText,
+ HelperText,
+ HelperTextItem,
+} from '@patternfly/react-core';
import { editACS, getACSDetails } from '../../ACSActions';
import { areSubPathsValid, isValidUrl } from '../../helpers';
@@ -63,8 +75,6 @@ const ACSEditURLPaths = ({ onClose, acsId, acsDetails }) => {
label={__('Base URL')}
type="string"
fieldId="acs_base_url"
- helperTextInvalid={helperTextInvalid}
- validated={urlValidated}
isRequired
>
{
placeholder={baseURLplaceholder}
value={acsUrl}
validated={urlValidated}
- onChange={value => setAcsUrl(value)}
+ onChange={(_event, value) => setAcsUrl(value)}
/>
+ {urlValidated === 'error' && (
+
+
+
+ {helperTextInvalid}
+
+
+
+ )}
}
+ toggle={ setDetailsKebabOpen(val)} style={{ paddingRight: '0px' }} />}
isOpen={detailsKebabOpen}
ouiaId="acs-details-actions"
isPlain
@@ -344,7 +346,7 @@ const ACSTable = () => {
}
{renderActionButtons && (canEdit || canDelete) &&
}
+ toggle={ setKebabOpen(val)} />}
isOpen={kebabOpen}
ouiaId="acs-bulk-actions"
isPlain
@@ -430,7 +432,7 @@ const ACSTable = () => {
id={id}
aria-label={`Select ACS ${id}`}
isChecked={isSelected(id)}
- onChange={selected => selectOne(selected, id)}
+ onChange={(_event, selected) => selectOne(selected, id)}
/>
|
diff --git a/webpack/scenes/ContentViews/Copy/CopyContentViewForm.js b/webpack/scenes/ContentViews/Copy/CopyContentViewForm.js
index f6a8ea7b3cb..b6770b8e4ff 100644
--- a/webpack/scenes/ContentViews/Copy/CopyContentViewForm.js
+++ b/webpack/scenes/ContentViews/Copy/CopyContentViewForm.js
@@ -55,7 +55,7 @@ const CopyContentViewForm = ({ cvId, setModalOpen }) => {
ouiaId="input_name"
name="name"
value={name}
- onChange={setName}
+ onChange={(_event, val) => setName(val)}
/>
diff --git a/webpack/scenes/ContentViews/Create/CreateContentViewForm.js b/webpack/scenes/ContentViews/Create/CreateContentViewForm.js
index 62b594b160c..68d4631aa8d 100644
--- a/webpack/scenes/ContentViews/Create/CreateContentViewForm.js
+++ b/webpack/scenes/ContentViews/Create/CreateContentViewForm.js
@@ -4,9 +4,27 @@ import { STATUS } from 'foremanReact/constants';
import { translate as __ } from 'foremanReact/common/I18n';
import PropTypes from 'prop-types';
import { useDispatch, useSelector } from 'react-redux';
-import { Form, FormGroup, TextInput, TextArea, Checkbox, ActionGroup, Button, Tile, Grid, GridItem } from '@patternfly/react-core';
+import {
+ Form,
+ FormGroup,
+ TextInput,
+ TextArea,
+ Checkbox,
+ ActionGroup,
+ Button,
+ Tile,
+ Grid,
+ GridItem,
+ FormHelperText,
+ HelperText,
+ HelperTextItem,
+} from '@patternfly/react-core';
import { createContentView } from '../ContentViewsActions';
-import { selectCreateContentViews, selectCreateContentViewStatus, selectCreateContentViewError } from './ContentViewCreateSelectors';
+import {
+ selectCreateContentViews,
+ selectCreateContentViewStatus,
+ selectCreateContentViewError,
+} from './ContentViewCreateSelectors';
import { LabelDependencies, LabelAutoPublish } from './ContentViewFormComponents';
import ContentViewIcon from '../components/ContentViewIcon';
import './CreateContentViewForm.scss';
@@ -57,23 +75,25 @@ const CreateContentViewForm = ({ setModalOpen }) => {
description,
composite,
solve_dependencies: dependencies,
- auto_publish: (autoPublish && composite),
+ auto_publish: autoPublish && composite,
}));
};
- useEffect(
- () => {
- setLabel(name.replace(/[^A-Za-z0-9_-]/g, '_'));
- },
- [name],
- );
+ useEffect(() => {
+ setLabel(name.replace(/[^A-Za-z0-9_-]/g, '_'));
+ }, [name]);
if (redirect) {
const { id } = response;
- if (composite) { window.location.assign(`/content_views/${id}#/contentviews`); } else { window.location.assign(`/content_views/${id}#/repositories`); }
+ if (composite) {
+ window.location.assign(`/content_views/${id}#/contentviews`);
+ } else {
+ window.location.assign(`/content_views/${id}#/repositories`);
+ }
}
- const submitDisabled = !name?.length || !label?.length || saving || redirect || labelValidated === 'error';
+ const submitDisabled =
+ !name?.length || !label?.length || saving || redirect || labelValidated === 'error';
return (
diff --git a/webpack/scenes/ContentViews/Publish/CVPublishReview.js b/webpack/scenes/ContentViews/Publish/CVPublishReview.js
index 2072cead734..391267d7cda 100644
--- a/webpack/scenes/ContentViews/Publish/CVPublishReview.js
+++ b/webpack/scenes/ContentViews/Publish/CVPublishReview.js
@@ -4,7 +4,7 @@ import { Link } from 'react-router-dom';
import { useSelector } from 'react-redux';
import PropTypes from 'prop-types';
import {
- TableComposable, Thead, Tbody, Tr, Th,
+ Table /* data-codemods */, Thead, Tbody, Tr, Th,
Td,
} from '@patternfly/react-table';
import { EnterpriseIcon, RegistryIcon } from '@patternfly/react-icons';
@@ -67,7 +67,7 @@ const CVPublishReview = ({
>
}
/>
-
+
{__('Content view name')} |
@@ -93,7 +93,7 @@ const CVPublishReview = ({
}
-
+
>
);
};
diff --git a/webpack/scenes/ContentViews/Publish/PublishContentViewWizard.js b/webpack/scenes/ContentViews/Publish/PublishContentViewWizard.js
index 27d9f19cd1b..c86a36f5cb7 100644
--- a/webpack/scenes/ContentViews/Publish/PublishContentViewWizard.js
+++ b/webpack/scenes/ContentViews/Publish/PublishContentViewWizard.js
@@ -2,7 +2,9 @@ import React, { useEffect, useState, useMemo, useCallback } from 'react';
import { useDispatch, useSelector } from 'react-redux';
import PropTypes from 'prop-types';
import { STATUS } from 'foremanReact/constants';
-import { Wizard } from '@patternfly/react-core';
+import {
+ Wizard,
+} from '@patternfly/react-core/deprecated';
import { translate as __ } from 'foremanReact/common/I18n';
import CVPublishForm from './CVPublishForm';
import CVPublishFinish from './CVPublishFinish';
diff --git a/webpack/scenes/ContentViews/Publish/cvPublishForm.scss b/webpack/scenes/ContentViews/Publish/cvPublishForm.scss
index 29b15420121..d316e1cb850 100644
--- a/webpack/scenes/ContentViews/Publish/cvPublishForm.scss
+++ b/webpack/scenes/ContentViews/Publish/cvPublishForm.scss
@@ -1,15 +1,15 @@
#content-view-publish-wizard {
- .pf-c-switch {
- --pf-c-switch__input--focus__toggle--OutlineWidth: 0;
+ .pf-v5-c-switch {
+ --pf-v5-c-switch__input--focus__toggle--OutlineWidth: 0;
}
- .pf-c-wizard__main-body {
+ .pf-v5-c-wizard__main-body {
display: flex;
grid-gap: 16px;
flex-direction: column;
}
- .pf-c-content h4 {
+ .pf-v5-c-content h4 {
margin-top: 0px;
}
}
diff --git a/webpack/scenes/ContentViews/components/ContentViewIcon.js b/webpack/scenes/ContentViews/components/ContentViewIcon.js
index 42e1c55b9c9..b83fdbb3543 100644
--- a/webpack/scenes/ContentViews/components/ContentViewIcon.js
+++ b/webpack/scenes/ContentViews/components/ContentViewIcon.js
@@ -1,7 +1,7 @@
import React from 'react';
import { translate as __ } from 'foremanReact/common/I18n';
import PropTypes from 'prop-types';
-import { Tooltip } from '@patternfly/react-core';
+import { Tooltip, Icon } from '@patternfly/react-core';
import { EnterpriseIcon, RegistryIcon } from '@patternfly/react-icons';
import './contentViewIcon.scss';
@@ -19,7 +19,15 @@ const ContentViewIcon = ({
content={composite ? __('Composite content view') : __('Content view')}
{...toolTipProps}
>
- {composite ? : }
+ {composite ? (
+
+
+
+ ) : (
+
+
+
+ )}
);
return (
diff --git a/webpack/scenes/ContentViews/components/ContentViewSelect/ContentViewSelect.js b/webpack/scenes/ContentViews/components/ContentViewSelect/ContentViewSelect.js
index db805ce808e..1bbc0e44efa 100644
--- a/webpack/scenes/ContentViews/components/ContentViewSelect/ContentViewSelect.js
+++ b/webpack/scenes/ContentViews/components/ContentViewSelect/ContentViewSelect.js
@@ -1,6 +1,9 @@
import React from 'react';
import { translate as __ } from 'foremanReact/common/I18n';
-import { Select, SelectVariant } from '@patternfly/react-core';
+import {
+ Select,
+ SelectVariant,
+} from '@patternfly/react-core/deprecated';
import PropTypes from 'prop-types';
const ContentViewSelect = ({
diff --git a/webpack/scenes/ContentViews/components/ContentViewSelect/ContentViewSelectOption.js b/webpack/scenes/ContentViews/components/ContentViewSelect/ContentViewSelectOption.js
index 98f0c234e13..287d39a1253 100644
--- a/webpack/scenes/ContentViews/components/ContentViewSelect/ContentViewSelectOption.js
+++ b/webpack/scenes/ContentViews/components/ContentViewSelect/ContentViewSelectOption.js
@@ -1,6 +1,11 @@
import React from 'react';
import PropTypes from 'prop-types';
-import { Flex, SelectOption } from '@patternfly/react-core';
+import {
+ Flex,
+} from '@patternfly/react-core';
+import {
+ SelectOption,
+} from '@patternfly/react-core/deprecated';
import { FormattedMessage } from 'react-intl';
import { translate as __ } from 'foremanReact/common/I18n';
import {
diff --git a/webpack/scenes/ContentViews/components/EnvironmentLabels.js b/webpack/scenes/ContentViews/components/EnvironmentLabels.js
index 67478ce8288..2ce95cc1d64 100644
--- a/webpack/scenes/ContentViews/components/EnvironmentLabels.js
+++ b/webpack/scenes/ContentViews/components/EnvironmentLabels.js
@@ -11,7 +11,7 @@ const EnvironmentLabels = (environments) => {
@@ -19,7 +19,7 @@ const EnvironmentLabels = (environments) => {
default:
return (
-
diff --git a/webpack/scenes/ContentViews/components/EnvironmentPaths/EnvironmentPaths.scss b/webpack/scenes/ContentViews/components/EnvironmentPaths/EnvironmentPaths.scss
index 5125d7d1ff7..cb36664f5fd 100644
--- a/webpack/scenes/ContentViews/components/EnvironmentPaths/EnvironmentPaths.scss
+++ b/webpack/scenes/ContentViews/components/EnvironmentPaths/EnvironmentPaths.scss
@@ -1,5 +1,5 @@
.env-path {
- .pf-c-form__group {
+ .pf-v5-c-form__group {
margin: 20px 0;
}
diff --git a/webpack/scenes/ContentViews/components/FiltersAppliedIcon.js b/webpack/scenes/ContentViews/components/FiltersAppliedIcon.js
index b98d7456307..042c8c9c0e4 100644
--- a/webpack/scenes/ContentViews/components/FiltersAppliedIcon.js
+++ b/webpack/scenes/ContentViews/components/FiltersAppliedIcon.js
@@ -1,6 +1,6 @@
import React from 'react';
import { translate as __ } from 'foremanReact/common/I18n';
-import { Tooltip } from '@patternfly/react-core';
+import { Tooltip, Icon } from '@patternfly/react-core';
import { FilterIcon } from '@patternfly/react-icons';
const FiltersAppliedIcon = () => (
@@ -10,7 +10,9 @@ const FiltersAppliedIcon = () => (
entryDelay={400}
content={__('Filters were applied to this version.')}
>
-
+
+
+
);
diff --git a/webpack/scenes/ContentViews/components/NeedsPublishIcon.js b/webpack/scenes/ContentViews/components/NeedsPublishIcon.js
index 95a31dd9063..ddca79b60b5 100644
--- a/webpack/scenes/ContentViews/components/NeedsPublishIcon.js
+++ b/webpack/scenes/ContentViews/components/NeedsPublishIcon.js
@@ -1,7 +1,7 @@
import React from 'react';
import { translate as __ } from 'foremanReact/common/I18n';
import PropTypes from 'prop-types';
-import { Tooltip } from '@patternfly/react-core';
+import { Tooltip, Icon } from '@patternfly/react-core';
import { ArrowCircleUpIcon } from '@patternfly/react-icons';
import './NeedsPublishIcon.scss';
@@ -24,11 +24,12 @@ const NeedsPublishIcon = ({ composite, determinate }) => (
entryDelay={400}
content={tooltipContent(composite, determinate)}
>
-
+
+
+
);
diff --git a/webpack/scenes/ContentViews/expansions/RelatedCompositeContentViewsModal.js b/webpack/scenes/ContentViews/expansions/RelatedCompositeContentViewsModal.js
index 1cbbe4fda10..6c84f5d82c3 100644
--- a/webpack/scenes/ContentViews/expansions/RelatedCompositeContentViewsModal.js
+++ b/webpack/scenes/ContentViews/expansions/RelatedCompositeContentViewsModal.js
@@ -3,7 +3,7 @@ import { Link } from 'react-router-dom';
import { translate as __ } from 'foremanReact/common/I18n';
import PropTypes from 'prop-types';
import { Modal, ModalVariant, Button, Flex, FlexItem } from '@patternfly/react-core';
-import { TableComposable, Thead, Tbody, Tr, Th, Td } from '@patternfly/react-table';
+import { Table /* data-codemods */, Thead, Tbody, Tr, Th, Td } from '@patternfly/react-table';
import { EnterpriseIcon } from '@patternfly/react-icons';
import { urlBuilder } from '../../../__mocks__/foremanReact/common/urlHelpers';
@@ -44,7 +44,7 @@ const RelatedCompositeContentViewsModal = ({
}}
appendTo={document.body}
>
-
))}
-
+
>
);
diff --git a/webpack/scenes/Hosts/ChangeContentSource/components/ContentSourceForm.js b/webpack/scenes/Hosts/ChangeContentSource/components/ContentSourceForm.js
index 23cfd90fb8a..3141a7a54e4 100644
--- a/webpack/scenes/Hosts/ChangeContentSource/components/ContentSourceForm.js
+++ b/webpack/scenes/Hosts/ChangeContentSource/components/ContentSourceForm.js
@@ -8,12 +8,14 @@ import {
Form,
Grid,
GridItem,
- Select,
- SelectOption,
- SelectVariant,
TextContent,
Text,
} from '@patternfly/react-core';
+import {
+ Select,
+ SelectOption,
+ SelectVariant,
+} from '@patternfly/react-core/deprecated';
import { translate as __ } from 'foremanReact/common/I18n';
import PropTypes from 'prop-types';
import { useAPI } from 'foremanReact/common/hooks/API/APIHooks';
diff --git a/webpack/scenes/Hosts/ChangeContentSource/components/FormField.js b/webpack/scenes/Hosts/ChangeContentSource/components/FormField.js
index b5cdcbc153c..029938da226 100644
--- a/webpack/scenes/Hosts/ChangeContentSource/components/FormField.js
+++ b/webpack/scenes/Hosts/ChangeContentSource/components/FormField.js
@@ -16,7 +16,7 @@ const FormField = ({
onChange(v)}
+ onChange={(_event, v) => onChange(v)}
className="without_select2"
isDisabled={isDisabled}
id={`${id}_select`}
diff --git a/webpack/scenes/Hosts/ChangeContentSource/components/HostsModal.js b/webpack/scenes/Hosts/ChangeContentSource/components/HostsModal.js
index 8443c8a677a..a25b024338a 100644
--- a/webpack/scenes/Hosts/ChangeContentSource/components/HostsModal.js
+++ b/webpack/scenes/Hosts/ChangeContentSource/components/HostsModal.js
@@ -29,7 +29,7 @@ const HostsModal = ({
setSearch(v)}
+ onChange={(e, v) => setSearch(v)}
onClear={() => setSearch('')}
/>
diff --git a/webpack/scenes/RedHatRepositories/index.scss b/webpack/scenes/RedHatRepositories/index.scss
index 915f930cb2c..ff378acb593 100644
--- a/webpack/scenes/RedHatRepositories/index.scss
+++ b/webpack/scenes/RedHatRepositories/index.scss
@@ -33,7 +33,7 @@
.foreman-search-bar {
flex-grow: 1;
margin-left: 0.7rem;
- .pf-c-search-input {
+ .pf-v5-c-search-input {
width: 100%;
}
}
diff --git a/webpack/scenes/SmartProxy/ExpandableCvDetails.js b/webpack/scenes/SmartProxy/ExpandableCvDetails.js
index 524ddc5bdcc..2a277d31a4c 100644
--- a/webpack/scenes/SmartProxy/ExpandableCvDetails.js
+++ b/webpack/scenes/SmartProxy/ExpandableCvDetails.js
@@ -1,7 +1,7 @@
import React from 'react';
import PropTypes from 'prop-types';
import { translate as __ } from 'foremanReact/common/I18n';
-import { TableComposable, Thead, Tr, Th, Tbody, Td } from '@patternfly/react-table';
+import { Table /* data-codemods */, Thead, Tr, Th, Tbody, Td } from '@patternfly/react-table';
import { CheckCircleIcon, TimesCircleIcon } from '@patternfly/react-icons';
import LongDateTime from 'foremanReact/components/common/dates/LongDateTime';
import { urlBuilder } from 'foremanReact/common/urlHelpers';
@@ -21,7 +21,7 @@ const ExpandableCvDetails = ({ contentViews, contentCounts, envId }) => {
const tableRowIsExpanded = id => expandedTableRows.has(id);
return (
-
@@ -83,7 +83,7 @@ const ExpandableCvDetails = ({ contentViews, contentCounts, envId }) => {
);
})}
-
+
);
};
diff --git a/webpack/scenes/Subscriptions/Manifest/CdnConfigurationTab/CdnConfigurationForm.scss b/webpack/scenes/Subscriptions/Manifest/CdnConfigurationTab/CdnConfigurationForm.scss
index 746cad2d286..7498633e4c8 100644
--- a/webpack/scenes/Subscriptions/Manifest/CdnConfigurationTab/CdnConfigurationForm.scss
+++ b/webpack/scenes/Subscriptions/Manifest/CdnConfigurationTab/CdnConfigurationForm.scss
@@ -1,5 +1,5 @@
#cdn-configuration {
- .pf-c-form__group.pf-m-action {
+ .pf-v5-c-form__group.pf-m-action {
margin-top: 0px;
}
}
diff --git a/webpack/scenes/Subscriptions/Manifest/CdnConfigurationTab/CustomCdnTypeForm.js b/webpack/scenes/Subscriptions/Manifest/CdnConfigurationTab/CustomCdnTypeForm.js
index 7cae89f5258..445575c2ce4 100644
--- a/webpack/scenes/Subscriptions/Manifest/CdnConfigurationTab/CustomCdnTypeForm.js
+++ b/webpack/scenes/Subscriptions/Manifest/CdnConfigurationTab/CustomCdnTypeForm.js
@@ -92,7 +92,7 @@ const CustomCdnTypeForm = ({
aria-label="cdn-url"
type="text"
value={url || ''}
- onChange={value => setUrl(value)}
+ onChange={(_event, value) => setUrl(value)}
isDisabled={updatingCdnConfiguration}
/>
@@ -105,7 +105,7 @@ const CustomCdnTypeForm = ({
aria-label="cdn-ssl-ca-content-credential"
value={sslCaCredentialValue || ''}
isDisabled={updatingCdnConfiguration}
- onChange={value => setSslCaCredentialId(value)}
+ onChange={(_event, value) => setSslCaCredentialId(value)}
>
{contentCredentials.map(cred =>
diff --git a/webpack/scenes/Subscriptions/Manifest/CdnConfigurationTab/NetworkSyncForm.js b/webpack/scenes/Subscriptions/Manifest/CdnConfigurationTab/NetworkSyncForm.js
index ad6d19a9efd..b5721cc1fc1 100644
--- a/webpack/scenes/Subscriptions/Manifest/CdnConfigurationTab/NetworkSyncForm.js
+++ b/webpack/scenes/Subscriptions/Manifest/CdnConfigurationTab/NetworkSyncForm.js
@@ -156,7 +156,7 @@ const NetworkSyncForm = ({
aria-label="cdn-url"
type="text"
value={url || ''}
- onChange={value => setUrl(value)}
+ onChange={(_event, value) => setUrl(value)}
isDisabled={updatingCdnConfiguration}
/>
@@ -169,7 +169,7 @@ const NetworkSyncForm = ({
aria-label="cdn-username"
type="text"
value={username || ''}
- onChange={value => setUsername(value)}
+ onChange={(_event, value) => setUsername(value)}
isDisabled={updatingCdnConfiguration}
/>
@@ -197,7 +197,7 @@ const NetworkSyncForm = ({
type="text"
value={upstreamOrganizationLabel || ''}
isDisabled={updatingCdnConfiguration}
- onChange={setUpstreamOrganizationLabel}
+ onChange={(_event, val) => setUpstreamOrganizationLabel(val)}
/>
setUpstreamLifecycleEnvironmentLabel(val)}
/>
setUpstreamContentViewLabel(val)}
/>
setSslCaCredentialId(value)}
+ onChange={(_event, value) => setSslCaCredentialId(value)}
>
{contentCredentials.map(cred =>
| | |