@rh-support/manage 2.6.1 → 2.32.2-prodBackup
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/esm/components/Configs/ConfigsTable.d.ts.map +1 -1
- package/lib/esm/components/Configs/ConfigsTable.js +6 -4
- package/lib/esm/components/Groups/DefualtGroupSwitch/DefaultGroupSwitch.d.ts.map +1 -1
- package/lib/esm/components/Groups/DefualtGroupSwitch/DefaultGroupSwitch.js +1 -1
- package/lib/esm/components/Groups/GroupSelect/GroupSelect.d.ts.map +1 -1
- package/lib/esm/components/Groups/GroupSelect/GroupSelect.js +54 -23
- package/lib/esm/components/Groups/GroupUserPermissionsSelect/GroupUserPermissionsSelect.d.ts.map +1 -1
- package/lib/esm/components/Groups/GroupUserPermissionsSelect/GroupUserPermissionsSelect.js +19 -14
- package/lib/esm/components/Groups/ManageGroupUsers/ManageGroupUsers.js +5 -5
- package/lib/esm/components/ManageBookmarkedAccountsTab/AddEditBookmarkModal.d.ts.map +1 -1
- package/lib/esm/components/ManageBookmarkedAccountsTab/AddEditBookmarkModal.js +15 -12
- package/lib/esm/components/ManageBookmarkedAccountsTab/BookmarkAccountSelector.d.ts.map +1 -1
- package/lib/esm/components/ManageBookmarkedAccountsTab/BookmarkAccountSelector.js +106 -67
- package/lib/esm/components/ManageBookmarkedAccountsTab/ManageGroupedBookmarkedAccountsTab.d.ts.map +1 -1
- package/lib/esm/components/ManageBookmarkedAccountsTab/ManageGroupedBookmarkedAccountsTab.js +14 -21
- package/lib/esm/components/ManageExpiredContents/ExpiredContentCategory.js +4 -4
- package/lib/esm/components/ManageExpiredContents/ExpiredContentHeader.js +1 -1
- package/lib/esm/components/ManageExpiredContents/ExpiredContentManager.d.ts.map +1 -1
- package/lib/esm/components/ManageExpiredContents/ExpiredContentManager.js +12 -12
- package/lib/esm/components/ManageExpiredContents/ExpiredContentSingleItem.js +3 -3
- package/lib/esm/components/ManageExpiredContents/ExpiredContentSingleItemView.d.ts.map +1 -1
- package/lib/esm/components/ManageExpiredContents/ExpiredContentSingleItemView.js +37 -35
- package/lib/esm/components/ManagePartnerships/NonOrgCustomerInfoModal.d.ts.map +1 -1
- package/lib/esm/components/ManagePartnerships/NonOrgCustomerInfoModal.js +8 -5
- package/lib/esm/components/ManagePartnerships/PartnershipsList.d.ts.map +1 -1
- package/lib/esm/components/ManagePartnerships/PartnershipsList.js +8 -9
- package/lib/esm/components/ManagePartnerships/PartnershipsTermsModal.d.ts.map +1 -1
- package/lib/esm/components/ManagePartnerships/PartnershipsTermsModal.js +17 -20
- package/lib/esm/components/ManagePartnerships/RequestCollaborationModal.d.ts.map +1 -1
- package/lib/esm/components/ManagePartnerships/RequestCollaborationModal.js +21 -25
- package/lib/esm/components/ManagePartnerships/Requests.d.ts.map +1 -1
- package/lib/esm/components/ManagePartnerships/Requests.js +9 -9
- package/lib/esm/components/ManagePartnerships/index.js +1 -1
- package/lib/esm/components/ManagePreferences/PreferencesHeader.d.ts.map +1 -1
- package/lib/esm/components/ManagePreferences/PreferencesHeader.js +1 -1
- package/lib/esm/components/ManagePreferences/components/PreferenceSelect.d.ts +1 -1
- package/lib/esm/components/ManagePreferences/components/PreferenceSelect.d.ts.map +1 -1
- package/lib/esm/components/ManagePreferences/components/PreferenceSelect.js +26 -27
- package/lib/esm/components/ManagePreferences/sections/PreferencesACL.js +5 -5
- package/lib/esm/components/ManagePreferences/sections/PreferencesCaseCreate.d.ts.map +1 -1
- package/lib/esm/components/ManagePreferences/sections/PreferencesCaseCreate.js +4 -5
- package/lib/esm/components/ManagePreferences/sections/PreferencesCaseSearch.d.ts.map +1 -1
- package/lib/esm/components/ManagePreferences/sections/PreferencesCaseSearch.js +3 -4
- package/lib/esm/components/ManagePreferences/sections/PreferencesCaseView.js +7 -8
- package/lib/esm/components/ManageTable/ManageTable.d.ts +3 -4
- package/lib/esm/components/ManageTable/ManageTable.d.ts.map +1 -1
- package/lib/esm/components/ManageTable/ManageTable.js +12 -18
- package/lib/esm/components/ManageTags/TagsManager.d.ts.map +1 -1
- package/lib/esm/components/ManageTags/TagsManager.js +58 -50
- package/lib/esm/components/NotificationEmails/NotificationEmailsModal.d.ts.map +1 -1
- package/lib/esm/components/NotificationEmails/NotificationEmailsModal.js +30 -23
- package/lib/esm/components/NotificationEmails/index.d.ts.map +1 -1
- package/lib/esm/components/NotificationEmails/index.js +10 -7
- package/lib/esm/components/TopContentManagement/CategoryLimit/CategoryLimit.d.ts.map +1 -1
- package/lib/esm/components/TopContentManagement/CategoryLimit/CategoryLimit.js +2 -3
- package/lib/esm/components/TopContentManagement/CategoryLimit/CategoryLimitGuidelines.js +6 -6
- package/lib/esm/components/TopContentManagement/CategoryLimit/QuestionAnswer.js +1 -1
- package/lib/esm/components/TopContentManagement/ContentUsage/ContentAccordion.d.ts.map +1 -1
- package/lib/esm/components/TopContentManagement/ContentUsage/ContentAccordion.js +7 -9
- package/lib/esm/components/TopContentManagement/ContentUsage/PerformanceMetricClickCount.d.ts +1 -0
- package/lib/esm/components/TopContentManagement/ContentUsage/PerformanceMetricClickCount.d.ts.map +1 -1
- package/lib/esm/components/TopContentManagement/ContentUsage/PerformanceMetricClickCount.js +2 -2
- package/lib/esm/components/TopContentManagement/ContentUsage/PerformanceMetrics.d.ts.map +1 -1
- package/lib/esm/components/TopContentManagement/ContentUsage/PerformanceMetrics.js +12 -10
- package/lib/esm/components/TopContentManagement/ContentUsage/PerformanceMetricsSelect.d.ts +2 -3
- package/lib/esm/components/TopContentManagement/ContentUsage/PerformanceMetricsSelect.d.ts.map +1 -1
- package/lib/esm/components/TopContentManagement/ContentUsage/PerformanceMetricsSelect.js +16 -9
- package/lib/esm/components/TopContentManagement/ContentUsage/VersionPerformanceMetrics.d.ts.map +1 -1
- package/lib/esm/components/TopContentManagement/ContentUsage/VersionPerformanceMetrics.js +15 -16
- package/lib/esm/components/TopContentManagement/NoTopContentFound.d.ts.map +1 -1
- package/lib/esm/components/TopContentManagement/NoTopContentFound.js +14 -15
- package/lib/esm/components/TopContentManagement/TopContentEditor/TopContentCategoryContent/AddNewCategoryDropDown.d.ts.map +1 -1
- package/lib/esm/components/TopContentManagement/TopContentEditor/TopContentCategoryContent/AddNewCategoryDropDown.js +47 -39
- package/lib/esm/components/TopContentManagement/TopContentEditor/TopContentCategoryContent/TopContentCategory.js +4 -4
- package/lib/esm/components/TopContentManagement/TopContentEditor/TopContentCategoryContent/TopContentCategoryNew.js +3 -3
- package/lib/esm/components/TopContentManagement/TopContentEditor/TopContentCategoryContent/TopContentComponent.d.ts.map +1 -1
- package/lib/esm/components/TopContentManagement/TopContentEditor/TopContentCategoryContent/TopContentComponent.js +4 -6
- package/lib/esm/components/TopContentManagement/TopContentEditor/TopContentCategoryContent/TopContentSingleItem.d.ts.map +1 -1
- package/lib/esm/components/TopContentManagement/TopContentEditor/TopContentCategoryContent/TopContentSingleItem.js +62 -53
- package/lib/esm/components/TopContentManagement/TopContentEditor/TopContentCategoryContent/TopContentSingleItemLink.d.ts.map +1 -1
- package/lib/esm/components/TopContentManagement/TopContentEditor/TopContentCategoryContent/TopContentSingleItemLink.js +2 -3
- package/lib/esm/components/TopContentManagement/TopContentEditor/TopContentEditor.d.ts.map +1 -1
- package/lib/esm/components/TopContentManagement/TopContentEditor/TopContentEditor.js +8 -9
- package/lib/esm/components/TopContentManagement/TopContentEditor/TopContentSuggestion/TopContentSuggestion.js +2 -2
- package/lib/esm/components/TopContentManagement/TopContentEditor/TopContentSuggestion/TopContentSuggestionHint.js +4 -5
- package/lib/esm/components/TopContentManagement/TopContentEditor/TopContentSuggestion/TopContentSuggestionHintAccept.d.ts.map +1 -1
- package/lib/esm/components/TopContentManagement/TopContentEditor/TopContentSuggestion/TopContentSuggestionHintAccept.js +51 -25
- package/lib/esm/components/TopContentManagement/TopContentHeader.js +1 -1
- package/lib/esm/components/TopContentManagement/TopContentProductVersionSelector.d.ts.map +1 -1
- package/lib/esm/components/TopContentManagement/TopContentProductVersionSelector.js +64 -32
- package/lib/esm/reducers/TagManagmentReducer.d.ts +1 -1
- package/lib/esm/reducers/TagManagmentReducer.d.ts.map +1 -1
- package/lib/esm/scss/_main.scss +158 -25
- package/lib/esm/scss/_pf-overrides.scss +61 -53
- package/lib/esm/scss/index.scss +4 -4
- package/package.json +12 -12
|
@@ -43,7 +43,6 @@ export function PartnershipsList() {
|
|
|
43
43
|
title: t('Are you sure?'),
|
|
44
44
|
description: React.createElement(Trans, null, "You will not be able to undo this action after verifying."),
|
|
45
45
|
confirmText: t('Delete'),
|
|
46
|
-
confirmButtonVariant: ButtonVariant.danger,
|
|
47
46
|
});
|
|
48
47
|
try {
|
|
49
48
|
setIsdeleting(true);
|
|
@@ -101,7 +100,7 @@ export function PartnershipsList() {
|
|
|
101
100
|
{
|
|
102
101
|
id: 'customer-partnership-access-level',
|
|
103
102
|
title: t('Default access level'),
|
|
104
|
-
sortable:
|
|
103
|
+
sortable: true,
|
|
105
104
|
cellWidth: 30,
|
|
106
105
|
cell: (data) => data.partnerCaseAccess,
|
|
107
106
|
},
|
|
@@ -110,12 +109,12 @@ export function PartnershipsList() {
|
|
|
110
109
|
title: ' ',
|
|
111
110
|
sortable: false,
|
|
112
111
|
cellWidth: 10,
|
|
113
|
-
cell: (data) => (React.createElement(Button, {
|
|
114
|
-
|
|
115
|
-
|
|
112
|
+
cell: (data) => (React.createElement(Button, { icon: React.createElement(React.Fragment, null,
|
|
113
|
+
React.createElement(TrashIcon, null),
|
|
114
|
+
React.createElement(LoadingIndicator, { isInline: true, show: isDeleting && data.accountNum === isDeletingAccountNum, size: "xs" })), variant: ButtonVariant.plain, "aria-label": t('Remove partnership'), "data-tracking-id": "remove-partnership", onClick: () => removePartnership(data) })),
|
|
116
115
|
},
|
|
117
116
|
];
|
|
118
|
-
const requestCollaborationButton = () => (React.createElement("div", { className: "toolbar-right pf-
|
|
117
|
+
const requestCollaborationButton = () => (React.createElement("div", { className: "toolbar-right pf-v6-u-mt-xs" },
|
|
119
118
|
React.createElement(Button, { variant: ButtonVariant.primary, isInline: true, onClick: () => setIsRequestCollabModalOpen(true), "data-tracking-id": "request-collaboration-button", isDisabled: false },
|
|
120
119
|
React.createElement(Trans, null, "Request Collaboration"))));
|
|
121
120
|
// Get Customer Accounts For A Partner
|
|
@@ -171,10 +170,10 @@ export function PartnershipsList() {
|
|
|
171
170
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
172
171
|
}, [managedAccounts, accountManagers]);
|
|
173
172
|
return (React.createElement("section", { id: "manage-partnerships-list" },
|
|
174
|
-
React.createElement("div", { className: "toolbar" },
|
|
175
|
-
React.createElement("div", { className: "toolbar-left" },
|
|
173
|
+
React.createElement("div", { className: "toolbar secondary-toolbar" },
|
|
174
|
+
React.createElement("div", { className: "toolbar-left pf-v6-u-mr-md" },
|
|
176
175
|
React.createElement("label", { htmlFor: "search-partnerships" }, "Filter by"),
|
|
177
|
-
React.createElement(SearchInput, { className: "pf-
|
|
176
|
+
React.createElement(SearchInput, { className: "pf-v6-u-flex-grow-1 pf-v6-c-search-input pf-v6-u-background-color-100", id: "search-partnerships", placeholder: t('Search for an existing partnership'), value: searchString, onChange: (_event, value) => setSearchString(value), onClear: () => setSearchString(''), "aria-label": t('Search for an existing partnership') })),
|
|
178
177
|
requestCollaborationButton()),
|
|
179
178
|
React.createElement(ManageTable, { ariaLabel: t('Partnerships list'), columns: columns, data: accountList.filter((account) => account.name.toLowerCase().includes(searchString.toLowerCase())), sortInfo: { column: 'customer-account-name', direction: 'asc' }, errorVariant: AlertVariant.warning, isFetching: isFetching, isError: hasError, errorTitle: t('Partnerships error'), errorComponent: React.createElement(Trans, null, "Could not get partnerships list"), noResultText: t('There are no results to display.') }),
|
|
180
179
|
React.createElement(RequestCollaborationModal, { isOpen: isRequestCollabModalOpen, onClose: () => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PartnershipsTermsModal.d.ts","sourceRoot":"","sources":["../../../../src/components/ManagePartnerships/PartnershipsTermsModal.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"PartnershipsTermsModal.d.ts","sourceRoot":"","sources":["../../../../src/components/ManagePartnerships/PartnershipsTermsModal.tsx"],"names":[],"mappings":"AAgBA,OAAO,KAA8B,MAAM,OAAO,CAAC;AAUnD,wBAAgB,SAAS,WAMxB;AAID,eAAO,MAAM,sBAAsB,yBAsMlC,CAAC"}
|
|
@@ -8,7 +8,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
8
8
|
});
|
|
9
9
|
};
|
|
10
10
|
import { pcm } from '@cee-eng/hydrajs';
|
|
11
|
-
import { Button, ButtonVariant, Modal,
|
|
11
|
+
import { Button, ButtonVariant, Content, ContentVariants, Modal, ModalBody, ModalFooter, ModalHeader, ModalVariant, } from '@patternfly/react-core';
|
|
12
12
|
import ExternalLinkAltIcon from '@patternfly/react-icons/dist/js/icons/external-link-alt-icon';
|
|
13
13
|
import { LoadingDots, LoadingIndicator, ToastNotification } from '@rh-support/components';
|
|
14
14
|
import { baseTnCUrl, TncConstants } from '@rh-support/utils';
|
|
@@ -109,25 +109,22 @@ export const PartnershipsTermsModal = () => {
|
|
|
109
109
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
110
110
|
}, [linkHash]);
|
|
111
111
|
const modalContentWhenTermIsVisited = () => isUpdating ? (React.createElement(LoadingIndicator, { show: true, size: "lg" })) : ackChoice === 'accept' ? (React.createElement(Trans, null, "Your partnership link is created successfully")) : ackChoice === 'decline' ? (React.createElement(Trans, null, "You have not accepted terms and conditions")) : (React.createElement(React.Fragment, null));
|
|
112
|
-
const modalContentBeforeTermVisited = () => isVerifyingLink ? (React.createElement("p", { className: "pf-
|
|
113
|
-
React.createElement(LoadingDots, { show: true, message: t('Verifying partner link') }))) : verificationFailMessage ? (React.createElement("p", { className: "pf-
|
|
112
|
+
const modalContentBeforeTermVisited = () => isVerifyingLink ? (React.createElement("p", { className: "pf-v6-u-mt-xs" },
|
|
113
|
+
React.createElement(LoadingDots, { show: true, message: t('Verifying partner link') }))) : verificationFailMessage ? (React.createElement("p", { className: "pf-v6-u-mt-xs pf-v6-u-danger-color-100" }, verificationFailMessage)) : (React.createElement(React.Fragment, null,
|
|
114
114
|
React.createElement("p", null,
|
|
115
115
|
React.createElement(Trans, null, "A partner would like to collaborate with you for support when cases are shared. Please confirm the name below and continue to accept terms and conditions.")),
|
|
116
|
-
React.createElement(
|
|
117
|
-
React.createElement(
|
|
118
|
-
return (React.createElement(Modal, { id: "partnership-terms-and-conditions-modal", className: "pf-modal-overflow-visible",
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
React.createElement(Trans, null, "Close")),
|
|
131
|
-
] },
|
|
132
|
-
React.createElement(React.Fragment, null, isTermVisited ? modalContentWhenTermIsVisited() : modalContentBeforeTermVisited())));
|
|
116
|
+
React.createElement(Content, { className: "pf-v6-u-mt-lg" },
|
|
117
|
+
React.createElement(Content, { component: ContentVariants.h3 }, linkAccountName))));
|
|
118
|
+
return (React.createElement(Modal, { id: "partnership-terms-and-conditions-modal", className: "pf-modal-overflow-visible", isOpen: isTermsModalOpen, onClose: onClose, onEscapePress: onClose, variant: ModalVariant.large },
|
|
119
|
+
React.createElement(ModalHeader, null,
|
|
120
|
+
React.createElement("h2", null, t('Confirm partnership collaboration'))),
|
|
121
|
+
React.createElement(ModalBody, null, isTermVisited ? modalContentWhenTermIsVisited() : modalContentBeforeTermVisited()),
|
|
122
|
+
React.createElement(ModalFooter, null, !isTermVisited && !verificationFailMessage ? (React.createElement(React.Fragment, null,
|
|
123
|
+
React.createElement(Button, { icon: React.createElement(ExternalLinkAltIcon, null), href: getTnCUrl(), component: "a", variant: ButtonVariant.primary, key: "go-to-agreement", "data-tracking-id": "go-to-agreement" },
|
|
124
|
+
' ',
|
|
125
|
+
" ",
|
|
126
|
+
React.createElement(Trans, null, "Go to Agreement")),
|
|
127
|
+
React.createElement(Button, { key: "close-new-partnership-modal", "data-tracking-id": "close-new-partnership-modal", variant: ButtonVariant.secondary, onClick: () => onClose() },
|
|
128
|
+
React.createElement(Trans, null, "Close")))) : (React.createElement(Button, { key: "close-after-link-created", "data-tracking-id": "close-after-link-created", variant: ButtonVariant.primary, onClick: () => onClose(), isDisabled: isUpdating },
|
|
129
|
+
React.createElement(Trans, null, "Close"))))));
|
|
133
130
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RequestCollaborationModal.d.ts","sourceRoot":"","sources":["../../../../src/components/ManagePartnerships/RequestCollaborationModal.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"RequestCollaborationModal.d.ts","sourceRoot":"","sources":["../../../../src/components/ManagePartnerships/RequestCollaborationModal.tsx"],"names":[],"mappings":"AAuBA,OAAO,KAAsC,MAAM,OAAO,CAAC;AAK3D,UAAU,MAAM;IACZ,MAAM,EAAE,OAAO,CAAC;IAChB,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,wBAAwB,CAAC,EAAE,MAAM,CAAC;CACrC;AAID,eAAO,MAAM,yBAAyB,UAAW,MAAM,sBA4OtD,CAAC"}
|
|
@@ -8,7 +8,8 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
8
8
|
});
|
|
9
9
|
};
|
|
10
10
|
import { pcm } from '@cee-eng/hydrajs';
|
|
11
|
-
import { Button, ButtonVariant, Form, FormGroup, FormHelperText, Grid, GridItem, HelperText, HelperTextItem, Modal, ModalVariant, TextInput, Tooltip, TooltipPosition, } from '@patternfly/react-core';
|
|
11
|
+
import { Button, ButtonVariant, Form, FormGroup, FormHelperText, Grid, GridItem, HelperText, HelperTextItem, Modal, ModalBody, ModalFooter, ModalHeader, ModalVariant, TextInput, Tooltip, TooltipPosition, } from '@patternfly/react-core';
|
|
12
|
+
import CopyIcon from '@patternfly/react-icons/dist/esm/icons/copy-icon';
|
|
12
13
|
import { ToastNotification, useCopyToClipboard } from '@rh-support/components';
|
|
13
14
|
import isEmpty from 'lodash/isEmpty';
|
|
14
15
|
import React, { useRef, useState } from 'react';
|
|
@@ -115,42 +116,37 @@ export const RequestCollaborationModal = (props) => {
|
|
|
115
116
|
setIsCopyClicked(true);
|
|
116
117
|
};
|
|
117
118
|
const partnershipLinkId = 'partnership-link-id';
|
|
118
|
-
return (React.createElement(Modal, { id: "request-collaboration-modal", className: "pf-modal-overflow-visible",
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
React.createElement(Trans, null, "Done")),
|
|
123
|
-
]
|
|
124
|
-
: [
|
|
125
|
-
React.createElement(Button, { key: "next", variant: ButtonVariant.primary, onClick: onNext, isDisabled: validated === 'error' || isFetching, isLoading: isFetching },
|
|
126
|
-
React.createElement(Trans, null, "Next")),
|
|
127
|
-
]),
|
|
128
|
-
] },
|
|
129
|
-
React.createElement(React.Fragment, null,
|
|
119
|
+
return (React.createElement(Modal, { id: "request-collaboration-modal", className: "pf-modal-overflow-visible", isOpen: props.isOpen, onClose: onClose, onEscapePress: onClose, variant: ModalVariant.large },
|
|
120
|
+
React.createElement(ModalHeader, null,
|
|
121
|
+
React.createElement("h2", null, isRequestingAgain ? t('Request collaboration again') : t('Request collaboration'))),
|
|
122
|
+
React.createElement(ModalBody, null,
|
|
130
123
|
React.createElement("p", null, "Initiate a new collaboration by generating a unique link for your customer. Check the status under your requests to see if they accept or reject your collaboration."),
|
|
131
|
-
React.createElement(Form, { className: "pf-
|
|
132
|
-
React.createElement(Grid, { sm: 12, md:
|
|
124
|
+
React.createElement(Form, { className: "pf-v6-u-my-md" },
|
|
125
|
+
React.createElement(Grid, { sm: 12, md: 12, lg: 12 },
|
|
133
126
|
React.createElement(GridItem, null,
|
|
134
127
|
React.createElement(FormGroup, { label: t('Name your link'), type: "string", fieldId: partnershipLinkId, isRequired: true },
|
|
128
|
+
React.createElement(TextInput, { isRequired: true, className: showDone || isRequestingAgain ? 'request-collaboration-input' : '', value: localLinkName || props.sendReqAgainFriendlyName, id: partnershipLinkId, "aria-describedby": "age-1-helper", onChange: handleLinkNameChange, onKeyDown: handleKeyDown, placeholder: t('e.g. Customer name'), isDisabled: showDone || isRequestingAgain }),
|
|
135
129
|
React.createElement(FormHelperText, null,
|
|
136
130
|
React.createElement(HelperText, null, validated !== 'error' ? (React.createElement(HelperTextItem, null,
|
|
137
|
-
React.createElement(Trans, null, "Please enter a name for your request"))) : (React.createElement(HelperTextItem, { variant: "error"
|
|
131
|
+
React.createElement(Trans, null, "Please enter a name for your request"))) : (React.createElement(HelperTextItem, { variant: "error" },
|
|
138
132
|
React.createElement(Trans, null, isDuplicateLinkName
|
|
139
133
|
? t('Link name already used. Please enter a unique name')
|
|
140
|
-
: t('Please enter a name for your request')))))),
|
|
141
|
-
React.createElement(TextInput, { isRequired: true, validated: validated, value: localLinkName || props.sendReqAgainFriendlyName, id: partnershipLinkId, "aria-describedby": "age-1-helper", onChange: handleLinkNameChange, onKeyDown: handleKeyDown, placeholder: t('e.g. Customer name'), isDisabled: showDone || isRequestingAgain }))))),
|
|
134
|
+
: t('Please enter a name for your request')))))))))),
|
|
142
135
|
showDone && (React.createElement(React.Fragment, null, !isRequestingAgain ? (React.createElement(React.Fragment, null,
|
|
143
|
-
React.createElement("h4",
|
|
136
|
+
React.createElement("h4", { className: "label-text-size" },
|
|
144
137
|
React.createElement("strong", null, "Copy and send")),
|
|
145
138
|
React.createElement("div", { className: "clipboard-wrapper" },
|
|
146
|
-
React.createElement(
|
|
147
|
-
React.createElement("code", { ref: clipboardRef }, generatedUrl)),
|
|
139
|
+
React.createElement(TextInput, { isDisabled: true, className: "request-collaboration-input", ref: clipboardRef, value: generatedUrl }),
|
|
148
140
|
React.createElement(Tooltip, { position: TooltipPosition.top, content: clipboardText, trigger: "click" },
|
|
149
|
-
React.createElement(
|
|
150
|
-
React.createElement("
|
|
141
|
+
React.createElement(Button, { className: "pf-v6-u-ml-sm copy-button", variant: "control", "aria-label": "Copy", icon: React.createElement(CopyIcon, null), "aria-hidden": "true", onClick: onClickOnCopyToClipboardButton, "data-tracking-id": "request-collaboration-link-copy-button", type: "button" }))),
|
|
142
|
+
React.createElement("div", { className: !isCopyClicked && isDoneClicked
|
|
143
|
+
? 'pf-v6-u-text-color-status-danger helper-text-size'
|
|
144
|
+
: 'helper-text-size' },
|
|
151
145
|
React.createElement(Trans, null,
|
|
152
|
-
' ',
|
|
153
146
|
"Please ",
|
|
154
147
|
React.createElement("strong", null, "copy and send"),
|
|
155
|
-
" this unique link to your customer for approval.")))) : (React.createElement(Trans, null, "Partnership request expiration date is extended.")))))
|
|
148
|
+
" this unique link to your customer for approval.")))) : (React.createElement(Trans, null, "Partnership request expiration date is extended."))))),
|
|
149
|
+
React.createElement(ModalFooter, null, showDone ? (React.createElement(Button, { key: "done", variant: ButtonVariant.primary, onClick: onDone, isDisabled: validated === 'error' || (!isRequestingAgain && !isCopyClicked && isDoneClicked), "data-tracking-id": "request-collaboration-done-button" },
|
|
150
|
+
React.createElement(Trans, null, "Done"))) : (React.createElement(Button, { key: "next", variant: ButtonVariant.primary, onClick: onNext, isDisabled: validated === 'error' || isFetching, isLoading: isFetching },
|
|
151
|
+
React.createElement(Trans, null, "Next"))))));
|
|
156
152
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Requests.d.ts","sourceRoot":"","sources":["../../../../src/components/ManagePartnerships/Requests.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Requests.d.ts","sourceRoot":"","sources":["../../../../src/components/ManagePartnerships/Requests.tsx"],"names":[],"mappings":"AAgBA,OAAO,KAA8B,MAAM,OAAO,CAAC;AAanD,eAAO,MAAM,WAAW,SAAU,MAAM,WAMvC,CAAC;AACF,wBAAgB,QAAQ,sBA+QvB"}
|
|
@@ -8,7 +8,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
8
8
|
});
|
|
9
9
|
};
|
|
10
10
|
import { pcm } from '@cee-eng/hydrajs';
|
|
11
|
-
import { AlertVariant, Badge,
|
|
11
|
+
import { AlertVariant, Badge, ExpandableSection, ExpandableSectionToggle, Label, Stack, StackItem, } from '@patternfly/react-core';
|
|
12
12
|
import ExclamationCircleIcon from '@patternfly/react-icons/dist/js/icons/exclamation-circle-icon';
|
|
13
13
|
import { LoadingIndicator, ToastNotification, useConfirmation } from '@rh-support/components';
|
|
14
14
|
import { UserPreferencesKeys, useUserPreferences } from '@rh-support/react-context';
|
|
@@ -50,7 +50,6 @@ export function Requests() {
|
|
|
50
50
|
title: t('Are you sure?'),
|
|
51
51
|
description: React.createElement(Trans, null, "You will not be able to undo this action after verifying."),
|
|
52
52
|
confirmText: t('Delete'),
|
|
53
|
-
confirmButtonVariant: ButtonVariant.danger,
|
|
54
53
|
});
|
|
55
54
|
try {
|
|
56
55
|
yield pcm.partnerships.removePendingPartnerLink(friendlyName);
|
|
@@ -111,12 +110,12 @@ export function Requests() {
|
|
|
111
110
|
setIsRequestAgainModalOpen(true);
|
|
112
111
|
};
|
|
113
112
|
const actionResolver = (rowData) => {
|
|
114
|
-
var _a, _b, _c
|
|
113
|
+
var _a, _b, _c;
|
|
115
114
|
if (!rowData)
|
|
116
115
|
return;
|
|
117
|
-
const friendlyName =
|
|
116
|
+
const friendlyName = rowData === null || rowData === void 0 ? void 0 : rowData.friendlyName;
|
|
118
117
|
//@ts-ignore
|
|
119
|
-
const status = ((
|
|
118
|
+
const status = ((_c = (_b = (_a = rowData.cells) === null || _a === void 0 ? void 0 : _a[1]) === null || _b === void 0 ? void 0 : _b.props) === null || _c === void 0 ? void 0 : _c.status) || '';
|
|
120
119
|
return [
|
|
121
120
|
...(status === 'EXPIRED'
|
|
122
121
|
? [
|
|
@@ -129,7 +128,7 @@ export function Requests() {
|
|
|
129
128
|
]
|
|
130
129
|
: []),
|
|
131
130
|
{
|
|
132
|
-
title: (React.createElement("div", { className: "pf-
|
|
131
|
+
title: (React.createElement("div", { className: "pf-v6-u-danger-color-200" },
|
|
133
132
|
React.createElement(Trans, null, "Delete"))),
|
|
134
133
|
onClick: () => deleteRequest(friendlyName),
|
|
135
134
|
itemKey: 'delete-request',
|
|
@@ -197,6 +196,7 @@ export function Requests() {
|
|
|
197
196
|
catch (e) {
|
|
198
197
|
setIsFetchingStatuses(false);
|
|
199
198
|
ToastNotification.addDangerMessage(t('Failed to get partnership requests'));
|
|
199
|
+
console.error(e);
|
|
200
200
|
}
|
|
201
201
|
setIsUpdatingRequests(dispatch, false);
|
|
202
202
|
});
|
|
@@ -210,14 +210,14 @@ export function Requests() {
|
|
|
210
210
|
React.createElement(StackItem, { className: "toolbar" },
|
|
211
211
|
React.createElement(ExpandableSectionToggle, { isExpanded: isExpanded, onToggle: onToggle, contentId: contentId },
|
|
212
212
|
React.createElement("div", null,
|
|
213
|
-
React.createElement("label", { className: "pf-
|
|
213
|
+
React.createElement("label", { className: "pf-v6-u-color-100" },
|
|
214
214
|
' ',
|
|
215
215
|
React.createElement(Trans, null, "Requests"),
|
|
216
|
-
isFetchingStatuses ? (React.createElement(LoadingIndicator, { isInline: true, size: "sm", className: "pf-
|
|
216
|
+
isFetchingStatuses ? (React.createElement(LoadingIndicator, { isInline: true, size: "sm", className: "pf-v6-u-mx-sm" })) : (React.createElement(Badge, { className: "pf-v6-u-mx-sm" }, statusList.length)))))),
|
|
217
217
|
React.createElement(StackItem, null,
|
|
218
218
|
React.createElement(ExpandableSection, { isIndented: false, isExpanded: isExpanded, isDetached: true, contentId: contentId }, !isEmpty(statusList) ? (React.createElement(ManageTable, { ariaLabel: t('Requests'), columns: columns, data: statusList, errorVariant: AlertVariant.warning, isFetching: isFetchingStatuses, isError: false, errorTitle: t('Request error'), errorComponent: React.createElement(Trans, null, "Could not get requests"), pagination: true, actionResolver: statusList && !isFetchingStatuses && !isEmpty(statusList)
|
|
219
219
|
? actionResolver
|
|
220
|
-
: null, perPage: 5 })) : (React.createElement("p", { className: "pf-
|
|
220
|
+
: null, perPage: 5 })) : (React.createElement("p", { className: "pf-v6-u-p-md" },
|
|
221
221
|
React.createElement(Trans, null, "No request"))))))),
|
|
222
222
|
isRequestAgainModalOpen && (React.createElement(RequestCollaborationModal, { isOpen: isRequestAgainModalOpen, onClose: onRequestAgainModalClose, sendReqAgainFriendlyName: selectedRowFriendlyName }))));
|
|
223
223
|
}
|
|
@@ -12,7 +12,7 @@ export function ManagePartnerships() {
|
|
|
12
12
|
const { t } = useTranslation();
|
|
13
13
|
const { globalMetadataState: { loggedInUserRights }, } = useGlobalStateContext();
|
|
14
14
|
return (React.createElement(React.Fragment, null,
|
|
15
|
-
React.createElement("header", { className: "pf-
|
|
15
|
+
React.createElement("header", { className: "pf-v6-u-mb-xs" },
|
|
16
16
|
React.createElement("h2", null,
|
|
17
17
|
React.createElement(Trans, null, "Partnerships")),
|
|
18
18
|
React.createElement("p", null,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PreferencesHeader.d.ts","sourceRoot":"","sources":["../../../../src/components/ManagePreferences/PreferencesHeader.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,wBAAgB,iBAAiB,
|
|
1
|
+
{"version":3,"file":"PreferencesHeader.d.ts","sourceRoot":"","sources":["../../../../src/components/ManagePreferences/PreferencesHeader.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,wBAAgB,iBAAiB,sBAYhC"}
|
|
@@ -5,5 +5,5 @@ export function PreferencesHeader() {
|
|
|
5
5
|
return (React.createElement("header", null,
|
|
6
6
|
React.createElement("h2", null,
|
|
7
7
|
React.createElement(Trans, null, "Preferences")),
|
|
8
|
-
React.createElement("p", { className: "pf-
|
|
8
|
+
React.createElement("p", { className: "pf-v6-u-mt-md pf-v6-u-mb-sm" }, t('Setting preferences will personalize your support case experience to best suit your needs.'))));
|
|
9
9
|
}
|
|
@@ -3,7 +3,7 @@ interface IProps {
|
|
|
3
3
|
id: string;
|
|
4
4
|
label: any;
|
|
5
5
|
selections: any;
|
|
6
|
-
onSelect: (event: any, selection: any
|
|
6
|
+
onSelect: (event: any, selection: any) => Promise<any>;
|
|
7
7
|
children: React.ReactElement[];
|
|
8
8
|
}
|
|
9
9
|
export declare function PreferenceSelect({ id, label, selections, children, onSelect }: IProps): React.JSX.Element;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PreferenceSelect.d.ts","sourceRoot":"","sources":["../../../../../src/components/ManagePreferences/components/PreferenceSelect.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"PreferenceSelect.d.ts","sourceRoot":"","sources":["../../../../../src/components/ManagePreferences/components/PreferenceSelect.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAmB,MAAM,OAAO,CAAC;AAGxC,UAAU,MAAM;IACZ,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,GAAG,CAAC;IACX,UAAU,EAAE,GAAG,CAAC;IAChB,QAAQ,EAAE,CAAC,KAAK,KAAA,EAAE,SAAS,KAAA,KAAK,OAAO,CAAC,GAAG,CAAC,CAAC;IAC7C,QAAQ,EAAE,KAAK,CAAC,YAAY,EAAE,CAAC;CAClC;AACD,wBAAgB,gBAAgB,CAAC,EAAE,EAAE,EAAE,KAAK,EAAE,UAAU,EAAE,QAAQ,EAAE,QAAQ,EAAE,EAAE,MAAM,qBA+CrF"}
|
|
@@ -7,43 +7,42 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
7
7
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
8
8
|
});
|
|
9
9
|
};
|
|
10
|
-
import {
|
|
11
|
-
import { Select, SelectVariant } from '@patternfly/react-core/deprecated';
|
|
12
|
-
import { ToastNotification } from '@rh-support/components';
|
|
10
|
+
import { SingleSelectDropdown, ToastNotification } from '@rh-support/components';
|
|
13
11
|
import isEqual from 'lodash/isEqual';
|
|
14
12
|
import React, { useState } from 'react';
|
|
15
13
|
import { Trans, useTranslation } from 'react-i18next';
|
|
16
14
|
export function PreferenceSelect({ id, label, selections, children, onSelect }) {
|
|
17
15
|
const { t } = useTranslation();
|
|
18
|
-
const [isOpen, setIsOpen] = useState(false);
|
|
19
16
|
const [isLoading, setIsLoading] = useState(false);
|
|
20
|
-
const
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
ToastNotification.addSuccessMessage(t('Successfully updated preference'));
|
|
32
|
-
}
|
|
33
|
-
catch (e) {
|
|
34
|
-
ToastNotification.addDangerMessage(t('Failed to update preference'));
|
|
35
|
-
}
|
|
36
|
-
finally {
|
|
37
|
-
defaultClearSelection();
|
|
38
|
-
setIsLoading(false);
|
|
39
|
-
}
|
|
17
|
+
const onSelectLocal = (option) => __awaiter(this, void 0, void 0, function* () {
|
|
18
|
+
if (isEqual(option.value, selections)) {
|
|
19
|
+
return;
|
|
20
|
+
}
|
|
21
|
+
setIsLoading(true);
|
|
22
|
+
try {
|
|
23
|
+
yield onSelect(option, option.value);
|
|
24
|
+
ToastNotification.addSuccessMessage(t('Successfully updated preference'));
|
|
25
|
+
}
|
|
26
|
+
catch (e) {
|
|
27
|
+
ToastNotification.addDangerMessage(t('Failed to update preference'));
|
|
40
28
|
}
|
|
29
|
+
finally {
|
|
30
|
+
setIsLoading(false);
|
|
31
|
+
}
|
|
32
|
+
});
|
|
33
|
+
const getDropdownOptions = (children) => children.map((child) => {
|
|
34
|
+
return {
|
|
35
|
+
label: child.props.value,
|
|
36
|
+
value: child.props.value,
|
|
37
|
+
description: child.props.description,
|
|
38
|
+
};
|
|
41
39
|
});
|
|
42
|
-
const
|
|
43
|
-
|
|
40
|
+
const getSelectedDropdownOption = {
|
|
41
|
+
label: selections,
|
|
42
|
+
value: selections,
|
|
44
43
|
};
|
|
45
44
|
return (React.createElement(React.Fragment, null,
|
|
46
45
|
React.createElement("label", { id: id },
|
|
47
46
|
React.createElement(Trans, null, label)),
|
|
48
|
-
React.createElement(
|
|
47
|
+
React.createElement(SingleSelectDropdown, { selected: getSelectedDropdownOption, options: getDropdownOptions(children), onSelect: onSelectLocal, isLoading: isLoading, ariaLabel: id })));
|
|
49
48
|
}
|
|
@@ -35,7 +35,7 @@ export function PreferencesACL() {
|
|
|
35
35
|
}
|
|
36
36
|
setIsAclLoading(false);
|
|
37
37
|
});
|
|
38
|
-
return (React.createElement(Card, { className: "preference-card" },
|
|
38
|
+
return (React.createElement(Card, { variant: "secondary", className: "preference-card" },
|
|
39
39
|
React.createElement(CardHeader, null,
|
|
40
40
|
React.createElement("h3", null,
|
|
41
41
|
React.createElement(Trans, null, "Case Group Access Control List"))),
|
|
@@ -44,13 +44,13 @@ export function PreferencesACL() {
|
|
|
44
44
|
React.createElement("div", { className: "form-group" },
|
|
45
45
|
React.createElement("label", null,
|
|
46
46
|
React.createElement(Trans, null, "Enable Case Group ACL for my account")),
|
|
47
|
-
React.createElement("div", { className: "preference-page-switch-container" },
|
|
47
|
+
React.createElement("div", { className: "preference-page-switch-container pf-v6-u-mt-sm" },
|
|
48
48
|
React.createElement(PreferenceSwitch, { id: "ACL-switch", label: isAclActivated ? t('ACL Enabled') : t('ACL Disabled'), isChecked: isAclActivated, onSwitchChange: onAclSwitch }),
|
|
49
49
|
React.createElement("div", { className: "prefhostnameTooltip" },
|
|
50
50
|
React.createElement(Tooltip, { content: t('This determines if the account is utilizing case group access controls'), position: "right" },
|
|
51
|
-
React.createElement(InfoCircleIcon, { className: "pf-
|
|
52
|
-
isAclLoading && (React.createElement(Spinner, { size: "lg", className: "pf-
|
|
53
|
-
React.createElement("div", { className: "pf-
|
|
51
|
+
React.createElement(InfoCircleIcon, { className: "pf-v6-u-ml-sm cursor-pointer" })),
|
|
52
|
+
isAclLoading && (React.createElement(Spinner, { size: "lg", className: "pf-v6-u-ml-sm hostnameSpinner", "aria-label": "Hostname loading" })))),
|
|
53
|
+
React.createElement("div", { className: "pf-v6-u-mt-lg" },
|
|
54
54
|
React.createElement("label", null,
|
|
55
55
|
React.createElement(Trans, null, "Related links")),
|
|
56
56
|
React.createElement("p", null,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PreferencesCaseCreate.d.ts","sourceRoot":"","sources":["../../../../../src/components/ManagePreferences/sections/PreferencesCaseCreate.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"PreferencesCaseCreate.d.ts","sourceRoot":"","sources":["../../../../../src/components/ManagePreferences/sections/PreferencesCaseCreate.tsx"],"names":[],"mappings":"AAcA,OAAO,KAA0C,MAAM,OAAO,CAAC;AAO/D,UAAU,MAAM;CAAG;AACnB,wBAAgB,qBAAqB,CAAC,KAAK,EAAE,MAAM,qBA0MlD"}
|
|
@@ -8,8 +8,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
8
8
|
});
|
|
9
9
|
};
|
|
10
10
|
import { publicApi } from '@cee-eng/hydrajs';
|
|
11
|
-
import { Card, CardBody, CardHeader } from '@patternfly/react-core';
|
|
12
|
-
import { SelectOption } from '@patternfly/react-core/deprecated';
|
|
11
|
+
import { Card, CardBody, CardHeader, SelectOption } from '@patternfly/react-core';
|
|
13
12
|
import { ToastNotification, useFetch } from '@rh-support/components';
|
|
14
13
|
import { fetchLanguageMetadata, GlobalMetadataDispatchContext, GlobalMetadataReducerConstants, GlobalMetadataStateContext, } from '@rh-support/react-context';
|
|
15
14
|
import { haventLoadedMetadata, PreferredLanguages } from '@rh-support/utils';
|
|
@@ -85,7 +84,7 @@ export function PreferencesCaseCreate(props) {
|
|
|
85
84
|
return foundLang === null || foundLang === void 0 ? void 0 : foundLang.label;
|
|
86
85
|
}
|
|
87
86
|
};
|
|
88
|
-
const onPreferredLanguageSelect = (event, selection
|
|
87
|
+
const onPreferredLanguageSelect = (event, selection) => __awaiter(this, void 0, void 0, function* () {
|
|
89
88
|
const selectedLanguageCode = getLanguageKey(selection);
|
|
90
89
|
try {
|
|
91
90
|
yield updatePreferredLanguage(selectedLanguageCode.value);
|
|
@@ -95,7 +94,7 @@ export function PreferencesCaseCreate(props) {
|
|
|
95
94
|
console.log(error);
|
|
96
95
|
}
|
|
97
96
|
});
|
|
98
|
-
const onDefaultGroupSelect = (event, selection
|
|
97
|
+
const onDefaultGroupSelect = (event, selection) => __awaiter(this, void 0, void 0, function* () {
|
|
99
98
|
try {
|
|
100
99
|
if (selection === 'Ungrouped Case') {
|
|
101
100
|
updateDefaultGroupPref('-1');
|
|
@@ -141,7 +140,7 @@ export function PreferencesCaseCreate(props) {
|
|
|
141
140
|
}
|
|
142
141
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
143
142
|
}, [caseLanguages]);
|
|
144
|
-
return (React.createElement(Card, { className: "preference-card" },
|
|
143
|
+
return (React.createElement(Card, { variant: "secondary", className: "preference-card" },
|
|
145
144
|
React.createElement(CardHeader, null,
|
|
146
145
|
React.createElement("h3", null,
|
|
147
146
|
React.createElement(Trans, null, "Case create"))),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PreferencesCaseSearch.d.ts","sourceRoot":"","sources":["../../../../../src/components/ManagePreferences/sections/PreferencesCaseSearch.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"PreferencesCaseSearch.d.ts","sourceRoot":"","sources":["../../../../../src/components/ManagePreferences/sections/PreferencesCaseSearch.tsx"],"names":[],"mappings":"AAMA,OAAO,KAA0C,MAAM,OAAO,CAAC;AAM/D,UAAU,MAAM;CAAG;AAEnB,wBAAgB,qBAAqB,CAAC,KAAK,EAAE,MAAM,qBA6GlD"}
|
|
@@ -7,8 +7,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
7
7
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
8
8
|
});
|
|
9
9
|
};
|
|
10
|
-
import { Card, CardBody, CardHeader } from '@patternfly/react-core';
|
|
11
|
-
import { SelectOption } from '@patternfly/react-core/deprecated';
|
|
10
|
+
import { Card, CardBody, CardHeader, SelectOption } from '@patternfly/react-core';
|
|
12
11
|
import { ToastNotification } from '@rh-support/components';
|
|
13
12
|
import { GlobalMetadataStateContext, UserPreferencesKeys } from '@rh-support/react-context';
|
|
14
13
|
import find from 'lodash/find';
|
|
@@ -56,7 +55,7 @@ export function PreferencesCaseSearch(props) {
|
|
|
56
55
|
useEffect(() => {
|
|
57
56
|
userOriginalSavedSearch();
|
|
58
57
|
});
|
|
59
|
-
const onSelect = (event, selection
|
|
58
|
+
const onSelect = (event, selection) => __awaiter(this, void 0, void 0, function* () {
|
|
60
59
|
if (selection !== restoreLatestText) {
|
|
61
60
|
try {
|
|
62
61
|
yield updateAutoRestoreSavedSearchPreference(selection);
|
|
@@ -86,7 +85,7 @@ export function PreferencesCaseSearch(props) {
|
|
|
86
85
|
return emptyPlaceHolderList;
|
|
87
86
|
}; // we are now adding "restore last" as the last of the array and "select a saved search" as the first option.
|
|
88
87
|
const titleId = 'auto-restore-preference-dropdown';
|
|
89
|
-
return (React.createElement(Card, { className: "preference-card" },
|
|
88
|
+
return (React.createElement(Card, { variant: "secondary", className: "preference-card" },
|
|
90
89
|
React.createElement(CardHeader, null,
|
|
91
90
|
React.createElement("h3", null,
|
|
92
91
|
React.createElement(Trans, null, "Case search"))),
|
|
@@ -8,8 +8,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
8
8
|
});
|
|
9
9
|
};
|
|
10
10
|
import { accounts } from '@cee-eng/hydrajs';
|
|
11
|
-
import { Card, CardBody, CardHeader, Popover, PopoverPosition, Spinner, TextArea, Tooltip, } from '@patternfly/react-core';
|
|
12
|
-
import { SelectOption } from '@patternfly/react-core/deprecated';
|
|
11
|
+
import { Card, CardBody, CardHeader, Popover, PopoverPosition, SelectOption, Spinner, TextArea, Tooltip, } from '@patternfly/react-core';
|
|
13
12
|
import InfoCircleIcon from '@patternfly/react-icons/dist/js/icons/info-circle-icon';
|
|
14
13
|
import { EditorMode, ToastNotification, useFetch } from '@rh-support/components';
|
|
15
14
|
import { fetchLoggedInUsersAccount, GlobalMetadataDispatchContext, GlobalMetadataStateContext, } from '@rh-support/react-context';
|
|
@@ -130,7 +129,7 @@ export function PreferencesCaseView(props) {
|
|
|
130
129
|
});
|
|
131
130
|
const onPrefCaseViewSelect = (event, selection) => __awaiter(this, void 0, void 0, function* () {
|
|
132
131
|
try {
|
|
133
|
-
let selectedView =
|
|
132
|
+
let selectedView = caseViewTypes.findIndex((option) => option.value === selection);
|
|
134
133
|
updateOriginalCaseView(selectedView);
|
|
135
134
|
setOriginalCaseView(+selectedView);
|
|
136
135
|
}
|
|
@@ -192,15 +191,15 @@ export function PreferencesCaseView(props) {
|
|
|
192
191
|
React.createElement(Trans, null, "Default case view"),
|
|
193
192
|
React.createElement(Popover, { "aria-label": "Preferred-default-case-view-popover", position: PopoverPosition.top, bodyContent: React.createElement("p", { className: 'pref-case-popover-text' },
|
|
194
193
|
React.createElement(Trans, null, "Choose the default view you want to see when looking at a case")), showClose: false },
|
|
195
|
-
React.createElement(InfoCircleIcon, { "aria-label": "Preferred-default-case-view-info-icon", className: "pf-
|
|
196
|
-
return (React.createElement(Card, { className: "preference-card" },
|
|
194
|
+
React.createElement(InfoCircleIcon, { "aria-label": "Preferred-default-case-view-info-icon", className: "pf-v6-u-ml-sm" }))));
|
|
195
|
+
return (React.createElement(Card, { variant: "secondary", className: "preference-card" },
|
|
197
196
|
React.createElement(CardHeader, null,
|
|
198
197
|
React.createElement("h3", null,
|
|
199
198
|
React.createElement(Trans, null, "Case view"))),
|
|
200
199
|
React.createElement(CardBody, null,
|
|
201
200
|
React.createElement("form", null,
|
|
202
201
|
isInternalUserPermission && (React.createElement("div", { className: "form-group" },
|
|
203
|
-
React.createElement(PreferenceSelect, { onSelect: onPrefCaseViewSelect, selections: caseViewPrefSelection(), id: defaultCaseViewID, label: prefCasePopover }, caseViewTypes.map((option, index) => (React.createElement(SelectOption, Object.assign({ "data-index": index, key: index, value: option.value }, (option.description && { description: option.description })))))))),
|
|
202
|
+
React.createElement(PreferenceSelect, { onSelect: (event, selection) => onPrefCaseViewSelect(event, selection), selections: caseViewPrefSelection(), id: defaultCaseViewID, label: prefCasePopover }, caseViewTypes.map((option, index) => (React.createElement(SelectOption, Object.assign({ "data-index": index, key: index, value: option.value }, (option.description && { description: option.description })))))))),
|
|
204
203
|
React.createElement("div", { className: "form-group" },
|
|
205
204
|
React.createElement(PreferenceSelect, { onSelect: onCommentSelect, selections: setOptionCase(originalCommentType, false), id: defaultCommentTitleID, label: "Default comment type" }, commentTypes.map((option, index) => (React.createElement(SelectOption, { key: index, value: setOptionCase(option, false) }))))),
|
|
206
205
|
React.createElement("div", { className: "form-group" },
|
|
@@ -217,6 +216,6 @@ export function PreferencesCaseView(props) {
|
|
|
217
216
|
React.createElement(PreferenceSwitch, { id: "share-hostnames-switch", label: 'Share hostnames', isChecked: isSharingHostNames, onSwitchChange: onShareHostNamesSwitch }),
|
|
218
217
|
React.createElement("div", { className: "prefhostnameTooltip" },
|
|
219
218
|
React.createElement(Tooltip, { content: prefHostnameCopy, position: "right" },
|
|
220
|
-
React.createElement(InfoCircleIcon, { className: "pf-
|
|
221
|
-
isHostnamesLoading && (React.createElement(Spinner, { size: "lg", className: "pf-
|
|
219
|
+
React.createElement(InfoCircleIcon, { className: "pf-v6-u-ml-sm cursor-pointer" })),
|
|
220
|
+
isHostnamesLoading && (React.createElement(Spinner, { size: "lg", className: "pf-v6-u-ml-sm hostnameSpinner", "aria-label": "Hostname loading" }))))))))));
|
|
222
221
|
}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { AlertVariant } from '@patternfly/react-core';
|
|
2
|
-
import { IActions, IActionsResolver, IAreActionsDisabled } from '@patternfly/react-table';
|
|
3
2
|
import { IColumn, ISortInfo } from '@rh-support/components';
|
|
4
3
|
import React from 'react';
|
|
5
4
|
interface IProps {
|
|
@@ -14,9 +13,9 @@ interface IProps {
|
|
|
14
13
|
isError: boolean;
|
|
15
14
|
pagination?: boolean;
|
|
16
15
|
keepPageNumberOnDataChange?: boolean;
|
|
17
|
-
actions?:
|
|
18
|
-
areActionsDisabled?:
|
|
19
|
-
actionResolver?:
|
|
16
|
+
actions?: any;
|
|
17
|
+
areActionsDisabled?: any;
|
|
18
|
+
actionResolver?: any;
|
|
20
19
|
noResultText?: string;
|
|
21
20
|
perPage?: number;
|
|
22
21
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ManageTable.d.ts","sourceRoot":"","sources":["../../../../src/components/ManageTable/ManageTable.tsx"],"names":[],"mappings":"AAAA,OAAO,EAGH,YAAY,
|
|
1
|
+
{"version":3,"file":"ManageTable.d.ts","sourceRoot":"","sources":["../../../../src/components/ManageTable/ManageTable.tsx"],"names":[],"mappings":"AAAA,OAAO,EAGH,YAAY,EAMf,MAAM,wBAAwB,CAAC;AAGhC,OAAO,EAAE,OAAO,EAAE,SAAS,EAA4C,MAAM,wBAAwB,CAAC;AACtG,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,UAAU,MAAM;IACZ,SAAS,EAAE,MAAM,CAAC;IAClB,OAAO,EAAE,OAAO,EAAE,CAAC;IACnB,IAAI,EAAE,GAAG,EAAE,CAAC;IACZ,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,QAAQ,CAAC,EAAE,SAAS,CAAC;IAGrB,cAAc,CAAC,EAAE,KAAK,CAAC,UAAU,CAAC;IAClC,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,YAAY,CAAC,EAAE,YAAY,CAAC;IAC5B,OAAO,EAAE,OAAO,CAAC;IAEjB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,0BAA0B,CAAC,EAAE,OAAO,CAAC;IAErC,OAAO,CAAC,EAAE,GAAG,CAAC;IACd,kBAAkB,CAAC,EAAE,GAAG,CAAC;IACzB,cAAc,CAAC,EAAE,GAAG,CAAC;IAErB,YAAY,CAAC,EAAE,MAAM,CAAC;IAEtB,OAAO,CAAC,EAAE,MAAM,CAAC;CACpB;AAyBD,wBAAgB,WAAW,CAAC,KAAK,EAAE,MAAM,qBAoDxC"}
|