@rh-support/troubleshoot 2.2.51 → 2.4.10-beta.7
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/README.md +1 -1
- package/lib/esm/components/AccountInfo/AccountSelector.d.ts.map +1 -1
- package/lib/esm/components/AccountInfo/AccountSelector.js +4 -4
- package/lib/esm/components/AccountInfo/ManagedAccountsDropdown.js +1 -1
- package/lib/esm/components/CaseEditView/ActiveCustomerEscalation/ActiveCustomerEscalation.js +2 -2
- package/lib/esm/components/CaseEditView/ActiveCustomerEscalation/RequestEscalationModal.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/ActiveCustomerEscalation/RequestEscalationModal.js +19 -22
- package/lib/esm/components/CaseEditView/CaseDetailsAside.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/CaseDetailsAside.js +9 -14
- package/lib/esm/components/CaseEditView/CaseDetailsErrorMessage.js +1 -1
- package/lib/esm/components/CaseEditView/CaseDetailsTabs.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/CaseDetailsTabs.js +13 -18
- package/lib/esm/components/CaseEditView/CaseOverview/CaseOwnerInfo.js +1 -1
- package/lib/esm/components/CaseEditView/CaseOverview/DateTime.js +1 -1
- package/lib/esm/components/CaseEditView/CaseOverview/index.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/CaseOverview/index.js +11 -14
- package/lib/esm/components/CaseEditView/CaseSecureSupportAlert.js +1 -1
- package/lib/esm/components/CaseEditView/CaseSolutions/CaseSolutions.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/CaseSolutions/CaseSolutions.js +38 -82
- package/lib/esm/components/CaseEditView/CaseSolutions/CaseSolutionsItem.d.ts +1 -4
- package/lib/esm/components/CaseEditView/CaseSolutions/CaseSolutionsItem.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/CaseSolutions/CaseSolutionsItem.js +4 -6
- package/lib/esm/components/CaseEditView/CaseSubscriptionAbuseAlert.js +1 -1
- package/lib/esm/components/CaseEditView/ConfirmationModals/ReopenCaseModal.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/ConfirmationModals/ReopenCaseModal.js +11 -17
- package/lib/esm/components/CaseEditView/RequestRemoteSession/ESSRemoteSession.js +2 -2
- package/lib/esm/components/CaseEditView/RequestRemoteSession/ESSRemoteSessionModal.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/RequestRemoteSession/ESSRemoteSessionModal.js +6 -7
- package/lib/esm/components/CaseEditView/RequestRemoteSession/NewEssTermsModal.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/RequestRemoteSession/NewEssTermsModal.js +10 -11
- package/lib/esm/components/CaseEditView/RequestRemoteSession/RemoteSessionAgreement.js +2 -2
- package/lib/esm/components/CaseEditView/RequestRemoteSession/RemoteSessionAgreementModal.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/RequestRemoteSession/RemoteSessionAgreementModal.js +10 -11
- package/lib/esm/components/CaseEditView/Tabs/CaseActionPlan/CaseActionPlan.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseActionPlan/CaseActionPlan.js +3 -3
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/CaseContactPhoneNumber.js +4 -4
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/CaseHostname.js +2 -2
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/CaseOpenshiftClusterId/CaseOpenShiftPopover.js +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/CaseOpenshiftClusterId/CaseOpenShiftV3Popover.js +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/CaseOpenshiftClusterId/CaseOpenshiftClusterId.js +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/CasePhoneNumberConfirmAlert.js +2 -2
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/CasePhoneNumberSev1ConfirmAlert.js +2 -2
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/CaseReferenceNumber.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/CaseReferenceNumber.js +7 -7
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/ProductVersion.js +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/Summary.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/Summary.js +6 -6
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/CaseAttachment.js +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/CaseChat.js +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/CaseComments.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/CaseComments.js +4 -6
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/CaseDiscussion.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/CaseDiscussion.js +1 -18
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/CaseExternalTrackerUpdate.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/CaseExternalTrackerUpdate.js +3 -5
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/CommentSearch.js +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/PostComment.js +4 -4
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/VerifyCaseStatusModal/VerifyCaseStatusModal.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/VerifyCaseStatusModal/VerifyCaseStatusModal.js +2 -3
- package/lib/esm/components/CaseEditView/Tabs/CasePrivateNotes/CasePrivateNotes.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CasePrivateNotes/CasePrivateNotes.js +3 -3
- package/lib/esm/components/CaseEditView/Tabs/RMEEscalations/RMEEscalationList.js +1 -1
- package/lib/esm/components/CaseEditView/index.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/index.js +6 -8
- package/lib/esm/components/CaseInformation/CaseInformation.d.ts.map +1 -1
- package/lib/esm/components/CaseInformation/CaseInformation.js +3 -3
- package/lib/esm/components/CaseInformation/ContactPhoneNumberPopOver.js +1 -1
- package/lib/esm/components/CaseInformation/Description.d.ts.map +1 -1
- package/lib/esm/components/CaseInformation/Description.js +3 -3
- package/lib/esm/components/CaseInformation/Fts.js +3 -3
- package/lib/esm/components/CaseInformation/Severity.d.ts.map +1 -1
- package/lib/esm/components/CaseInformation/Severity.js +3 -5
- package/lib/esm/components/CaseInformation/SupportLevel.d.ts.map +1 -1
- package/lib/esm/components/CaseInformation/SupportLevel.js +3 -4
- package/lib/esm/components/CaseManagement/CaseLanguageSelector.d.ts.map +1 -1
- package/lib/esm/components/CaseManagement/CaseLanguageSelector.js +2 -3
- package/lib/esm/components/CaseManagement/CaseManagement.js +2 -2
- package/lib/esm/components/CaseManagement/Cep.d.ts.map +1 -1
- package/lib/esm/components/CaseManagement/Cep.js +14 -30
- package/lib/esm/components/CaseManagement/ESSRemoteSessionCheckBox.d.ts.map +1 -1
- package/lib/esm/components/CaseManagement/ESSRemoteSessionCheckBox.js +12 -13
- package/lib/esm/components/CaseManagement/NoClusterIDReasonSelector.js +3 -3
- package/lib/esm/components/CaseManagement/OpenShiftClusterId.js +1 -1
- package/lib/esm/components/CaseManagement/OpenShiftV3Inputbox.js +1 -1
- package/lib/esm/components/CaseManagement/OpenshiftDropdownV4.d.ts.map +1 -1
- package/lib/esm/components/CaseManagement/OpenshiftDropdownV4.js +3 -4
- package/lib/esm/components/CaseManagement/RHAssociatesSelector.js +2 -2
- package/lib/esm/components/CaseManagement/SendNotifications/AddCustomEmailToAccountModal.d.ts.map +1 -1
- package/lib/esm/components/CaseManagement/SendNotifications/AddCustomEmailToAccountModal.js +14 -15
- package/lib/esm/components/CaseManagement/SendNotifications/CaseContactSelector.js +3 -3
- package/lib/esm/components/CaseManagement/SendNotifications/NonOrgCaseNotifyeesSelector.js +1 -1
- package/lib/esm/components/ConfirmationModals/NoAttachmentSelectedModal.js +3 -3
- package/lib/esm/components/IdeaInformation/IdeaInformation.js +5 -5
- package/lib/esm/components/ImproveCase/KtQuestions.d.ts.map +1 -1
- package/lib/esm/components/ImproveCase/KtQuestions.js +7 -7
- package/lib/esm/components/OpenCase/SupportTypeSelectorPage.js +15 -12
- package/lib/esm/components/ProductSelector/AllProductsSelector.js +1 -1
- package/lib/esm/components/ProductSelector/NewProductDropdownSelector.d.ts.map +1 -1
- package/lib/esm/components/ProductSelector/NewProductDropdownSelector.js +5 -6
- package/lib/esm/components/ProductSelector/NewProductVersionSelector.js +2 -2
- package/lib/esm/components/ProductSelector/ProductSelector.js +2 -2
- package/lib/esm/components/Recommendations/AlertToastWrapper.d.ts +0 -3
- package/lib/esm/components/Recommendations/AlertToastWrapper.d.ts.map +1 -1
- package/lib/esm/components/Recommendations/AlertToastWrapper.js +2 -2
- package/lib/esm/components/Recommendations/AsideResults.d.ts +7 -1
- package/lib/esm/components/Recommendations/AsideResults.d.ts.map +1 -1
- package/lib/esm/components/Recommendations/AsideResults.js +17 -4
- package/lib/esm/components/Recommendations/ClusterRecommendationItems.js +1 -1
- package/lib/esm/components/Recommendations/ClusterRecommendations.js +1 -1
- package/lib/esm/components/Recommendations/EARules/EARuleInfoAccordion.js +1 -1
- package/lib/esm/components/Recommendations/EARules/EARuleInfoInline.js +7 -7
- package/lib/esm/components/Recommendations/InsightsResults.d.ts.map +1 -1
- package/lib/esm/components/Recommendations/InsightsResults.js +3 -3
- package/lib/esm/components/Recommendations/InsightsRuleInfo.js +7 -7
- package/lib/esm/components/Recommendations/RecommendationFeedbackModal.js +1 -1
- package/lib/esm/components/Recommendations/Recommendations.d.ts +3 -0
- package/lib/esm/components/Recommendations/Recommendations.d.ts.map +1 -1
- package/lib/esm/components/Recommendations/Recommendations.js +22 -6
- package/lib/esm/components/Recommendations/RulesModal.d.ts.map +1 -1
- package/lib/esm/components/Recommendations/RulesModal.js +1 -2
- package/lib/esm/components/Recommendations/ShowRank.d.ts +12 -0
- package/lib/esm/components/Recommendations/ShowRank.d.ts.map +1 -0
- package/lib/esm/components/Recommendations/ShowRank.js +27 -0
- package/lib/esm/components/RemoteRider/RemoteRiderBanner.js +1 -1
- package/lib/esm/components/Review/Review.js +2 -2
- package/lib/esm/components/SessionRestore/SessionRestore.d.ts.map +1 -1
- package/lib/esm/components/SessionRestore/SessionRestore.js +14 -9
- package/lib/esm/components/SessionRestore/SessionRestoreCard.d.ts.map +1 -1
- package/lib/esm/components/SessionRestore/SessionRestoreCard.js +16 -9
- package/lib/esm/components/SubmitCase/ResubmitToast.d.ts +0 -3
- package/lib/esm/components/SubmitCase/ResubmitToast.d.ts.map +1 -1
- package/lib/esm/components/SubmitCase/ResubmitToast.js +1 -3
- package/lib/esm/components/SubmitCase/SubmitCase.d.ts +7 -1
- package/lib/esm/components/SubmitCase/SubmitCase.d.ts.map +1 -1
- package/lib/esm/components/SubmitCase/SubmitCase.js +17 -19
- package/lib/esm/components/Suggestions/Suggestions.js +1 -1
- package/lib/esm/components/Suggestions/TopContent.d.ts.map +1 -1
- package/lib/esm/components/Suggestions/TopContent.js +12 -58
- package/lib/esm/components/TroubleshootSection/TroubleshootSection.js +6 -6
- package/lib/esm/components/UpdateSeverityModal/UpdateSeverityModal.js +4 -4
- package/lib/esm/components/shared/Rule.js +6 -6
- package/lib/esm/components/shared/fileUpload/FileLister.js +6 -6
- package/lib/esm/components/shared/fileUpload/WidgetFileUploader.js +2 -2
- package/lib/esm/components/shared/fileUpload/common/FileUploaderInfoIcon.js +1 -1
- package/lib/esm/components/shared/fileUpload/css/fileSelector.css +1 -1
- package/lib/esm/components/shared/fileUpload/fileSelectors/FileSelectorButton.d.ts.map +1 -1
- package/lib/esm/components/shared/fileUpload/fileSelectors/FileSelectorButton.js +1 -1
- package/lib/esm/components/shared/fileUpload/fileSelectors/WidgetFileSelector.js +2 -2
- package/lib/esm/components/shared/fileUpload/fileSelectors/WidgetFileSelectorImage.js +2 -2
- package/lib/esm/components/shared/fileUpload/reducer/AttachmentHelper.js +1 -1
- package/lib/esm/components/shared/useIsSectionValid.js +1 -1
- package/lib/esm/components/wizardLayout/GlobalTroubleshootEffects.d.ts.map +1 -1
- package/lib/esm/components/wizardLayout/GlobalTroubleshootEffects.js +0 -6
- package/lib/esm/components/wizardLayout/MainSection.js +1 -1
- package/lib/esm/components/wizardLayout/WizardAside.d.ts.map +1 -1
- package/lib/esm/components/wizardLayout/WizardAside.js +3 -3
- package/lib/esm/components/wizardLayout/WizardLayout.d.ts.map +1 -1
- package/lib/esm/components/wizardLayout/WizardLayout.js +37 -6
- package/lib/esm/components/wizardLayout/WizardMain.js +2 -2
- package/lib/esm/components/wizardLayout/WizardNavigation.js +1 -1
- package/lib/esm/constants/caseDetailsConstants.d.ts +1 -7
- package/lib/esm/constants/caseDetailsConstants.d.ts.map +1 -1
- package/lib/esm/constants/caseDetailsConstants.js +0 -7
- package/lib/esm/css/app.css +7 -7
- package/lib/esm/css/case.css +3 -3
- package/lib/esm/hooks/useWizard.js +1 -1
- package/lib/esm/reducers/CaseConstNTypes.d.ts +4 -4
- package/lib/esm/reducers/CaseConstNTypes.d.ts.map +1 -1
- package/lib/esm/reducers/CaseConstNTypes.js +4 -4
- package/lib/esm/reducers/CaseHelpers.d.ts.map +1 -1
- package/lib/esm/reducers/CaseHelpers.js +0 -2
- package/lib/esm/reducers/CaseOverviewReducer.d.ts +1 -1
- package/lib/esm/reducers/CaseOverviewReducer.d.ts.map +1 -1
- package/lib/esm/reducers/CaseReducer.d.ts +2 -1
- package/lib/esm/reducers/CaseReducer.d.ts.map +1 -1
- package/lib/esm/reducers/CaseReducer.js +14 -20
- package/lib/esm/reducers/RecommendationsReducer.d.ts +2 -1
- package/lib/esm/reducers/RecommendationsReducer.d.ts.map +1 -1
- package/lib/esm/reducers/RecommendationsReducer.js +30 -2
- package/lib/esm/reducers/RouteConstNTypes.d.ts +2 -2
- package/lib/esm/reducers/RouteConstNTypes.d.ts.map +1 -1
- package/lib/esm/reducers/SessionRestoreReducer.d.ts +1 -1
- package/lib/esm/reducers/SessionRestoreReducer.d.ts.map +1 -1
- package/lib/esm/reducers/SessionRestoreReducer.js +1 -7
- package/lib/esm/scss/_main.scss +43 -109
- package/lib/esm/scss/_pf4-imports.scss +30 -0
- package/lib/esm/scss/{_pf-overrides.scss → _pf4-overrides.scss} +85 -214
- package/lib/esm/scss/index.scss +2 -1
- package/package.json +14 -13
- package/lib/esm/components/CaseEditView/CaseSolutions/HandpicketItem.d.ts +0 -13
- package/lib/esm/components/CaseEditView/CaseSolutions/HandpicketItem.d.ts.map +0 -1
- package/lib/esm/components/CaseEditView/CaseSolutions/HandpicketItem.js +0 -76
- package/lib/esm/components/CaseEditView/Tabs/RelatedTickets/RelatedTickets.d.ts +0 -3
- package/lib/esm/components/CaseEditView/Tabs/RelatedTickets/RelatedTickets.d.ts.map +0 -1
- package/lib/esm/components/CaseEditView/Tabs/RelatedTickets/RelatedTickets.js +0 -118
- package/lib/esm/context/CaseOverviewContext.d.ts +0 -8
- package/lib/esm/context/CaseOverviewContext.d.ts.map +0 -1
- package/lib/esm/context/CaseOverviewContext.js +0 -10
|
@@ -19,7 +19,7 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
19
19
|
return t;
|
|
20
20
|
};
|
|
21
21
|
import { search } from '@cee-eng/hydrajs';
|
|
22
|
-
import { Accordion, AccordionContent, AccordionItem, AccordionToggle
|
|
22
|
+
import { Accordion, AccordionContent, AccordionItem, AccordionToggle } from '@patternfly/react-core';
|
|
23
23
|
import { PaginatedList, ToastNotification } from '@rh-support/components';
|
|
24
24
|
import { AbilityContext, CaseDetailsFields, resourceActions, resources } from '@rh-support/user-permissions';
|
|
25
25
|
import { getSolrParams } from '@rh-support/utils';
|
|
@@ -28,17 +28,12 @@ import isEqual from 'lodash/isEqual';
|
|
|
28
28
|
import some from 'lodash/some';
|
|
29
29
|
import React, { forwardRef, useContext, useEffect, useState } from 'react';
|
|
30
30
|
import { Trans, useTranslation } from 'react-i18next';
|
|
31
|
-
import { CaseStatusEnum } from '../../../constants/caseDetailsConstants';
|
|
32
31
|
import { useCaseDispatch, useCaseSelector } from '../../../context/CaseContext';
|
|
33
|
-
import { CaseOverviewDispatchContext } from '../../../context/CaseOverviewContext';
|
|
34
32
|
import { useRecommendationDispatchContext, useRecommendationStateContext, } from '../../../context/RecommendationContext';
|
|
35
33
|
import { useCaseUpdateErrorMessage } from '../../../hooks/useCaseUpdateErrorMessage';
|
|
36
|
-
import { setStatusUpdating } from '../../../reducers/CaseOverviewReducer';
|
|
37
34
|
import { updateCaseDetails } from '../../../reducers/CaseReducer';
|
|
38
35
|
import { fetchRecommendations } from '../../../reducers/RecommendationsReducer';
|
|
39
|
-
import { usePostComment } from '../../shared/usePostComment';
|
|
40
36
|
import { CaseSolutionsItem } from './CaseSolutionsItem';
|
|
41
|
-
import { HandpickedItem } from './HandpicketItem';
|
|
42
37
|
// some of the pinned and hadpicked titles are set to 'Red Hat Knowledge Base'
|
|
43
38
|
// this workaround is added till backend fix
|
|
44
39
|
const titleFix = (recommendations, allDocs) => __awaiter(void 0, void 0, void 0, function* () {
|
|
@@ -86,57 +81,26 @@ const titleFix = (recommendations, allDocs) => __awaiter(void 0, void 0, void 0,
|
|
|
86
81
|
// A recommendation can be both link and pin. We use pinnedBy and linkedBy fileds to identify them
|
|
87
82
|
export const CaseSolutions = forwardRef((props, ref) => {
|
|
88
83
|
const caseUpdateError = useCaseUpdateErrorMessage();
|
|
89
|
-
const { product, version, summary, description, recomendationsObj, isFetchingCaseDetails
|
|
84
|
+
const { product, version, summary, description, recomendationsObj, isFetchingCaseDetails } = useCaseSelector((state) => ({
|
|
90
85
|
product: state.caseDetails.product,
|
|
91
86
|
version: state.caseDetails.version,
|
|
92
87
|
summary: state.caseDetails.summary,
|
|
93
88
|
description: state.caseDetails.description,
|
|
94
89
|
recomendationsObj: state.caseDetails.caseResourceLinks,
|
|
95
90
|
isFetchingCaseDetails: state.isFetchingCaseDetails,
|
|
96
|
-
caseStatus: state.caseDetails.status,
|
|
97
91
|
}), isEqual);
|
|
98
92
|
const caseDispatch = useCaseDispatch();
|
|
99
|
-
const caseOverviewDispatch = useContext(CaseOverviewDispatchContext);
|
|
100
93
|
const { recommendationState: { isLoadingRecommendations, allDocs }, } = useRecommendationStateContext();
|
|
101
94
|
const recommendationsDispatch = useRecommendationDispatchContext();
|
|
102
|
-
const { postComment } = usePostComment({ caseNumber: props.caseNumber });
|
|
103
95
|
const { caseNumber, isSecureSupportAccount } = props;
|
|
104
96
|
const [isPinLoading, setIsPinLoading] = useState({});
|
|
105
|
-
const [
|
|
106
|
-
const [handPickedOpen, setHandPickedOpen] = useState(true);
|
|
107
|
-
const [pinnedOpen, setPinnedOpen] = useState(true);
|
|
97
|
+
const [expanded, setExpanded] = useState('sol-handpicked');
|
|
108
98
|
const [recommendations, setRecommendations] = useState([]);
|
|
109
99
|
const [topRecommendations, setTopRecommendations] = useState([]);
|
|
110
|
-
const [isCloseCaseModalOpen, setIsCloseCaseModalOpen] = useState(false);
|
|
111
100
|
const ability = useContext(AbilityContext);
|
|
112
101
|
const { t } = useTranslation();
|
|
113
102
|
const hasPin = some(recommendations, (p) => p.isPinned);
|
|
114
103
|
const hasLink = some(recommendations, (p) => p.isLinked);
|
|
115
|
-
const getCommentBody = () => {
|
|
116
|
-
return `**Reason for closing case:** \nOther. Found a pinned article that perfectly resolved the issue. Closing this case now.`;
|
|
117
|
-
};
|
|
118
|
-
const handleCaseClose = () => __awaiter(void 0, void 0, void 0, function* () {
|
|
119
|
-
setStatusUpdating(caseOverviewDispatch, true);
|
|
120
|
-
try {
|
|
121
|
-
setIsCaseCloseLoading(true);
|
|
122
|
-
yield updateCaseDetails(caseDispatch, props.caseNumber, { status: CaseStatusEnum.CLOSED });
|
|
123
|
-
yield postComment({
|
|
124
|
-
commentBody: getCommentBody(),
|
|
125
|
-
contentType: 'markdown',
|
|
126
|
-
updateDiscussionState: true,
|
|
127
|
-
doNotChangeStatus: true,
|
|
128
|
-
});
|
|
129
|
-
ToastNotification.addSuccessMessage(t('Status has been successfully updated'));
|
|
130
|
-
setIsCloseCaseModalOpen(false);
|
|
131
|
-
}
|
|
132
|
-
catch (err) {
|
|
133
|
-
caseUpdateError.showError(err, t('Status failed to update'));
|
|
134
|
-
}
|
|
135
|
-
finally {
|
|
136
|
-
setIsCaseCloseLoading(false);
|
|
137
|
-
setStatusUpdating(caseOverviewDispatch, false);
|
|
138
|
-
}
|
|
139
|
-
});
|
|
140
104
|
const updateRecommendation = (recommendationToUpdate, linked) => __awaiter(void 0, void 0, void 0, function* () {
|
|
141
105
|
const recommendation = {
|
|
142
106
|
resourceId: recommendationToUpdate.resourceId,
|
|
@@ -246,57 +210,49 @@ export const CaseSolutions = forwardRef((props, ref) => {
|
|
|
246
210
|
}
|
|
247
211
|
}, [allDocs, isFetchingCaseDetails, isLoadingRecommendations, recomendationsObj]);
|
|
248
212
|
const renderTopRecommendations = (recommendation, index, type) => (React.createElement(React.Fragment, null,
|
|
249
|
-
canPinUnpin && (React.createElement(CaseSolutionsItem, { showPin: true, type: type, pinTitle: recommendation.isPinned ?
|
|
250
|
-
canLinkUnlink && (React.createElement(CaseSolutionsItem, { showLink: true, type: type, pinTitle: recommendation.isLinked ?
|
|
213
|
+
canPinUnpin && (React.createElement(CaseSolutionsItem, { showPin: true, type: type, pinTitle: recommendation.isPinned ? 'Unpin' : 'Pin', isPinLoading: isPinLoading, index: index, recommendation: recommendation, onPinClicked: updateRecommendations(recommendation, recommendation.isPinned, undefined) })),
|
|
214
|
+
canLinkUnlink && (React.createElement(CaseSolutionsItem, { showLink: true, type: type, pinTitle: recommendation.isLinked ? 'Unlink' : 'Link', isPinLoading: isPinLoading, index: index, recommendation: recommendation, onPinClicked: updateRecommendations(recommendation, undefined, recommendation.isLinked) }))));
|
|
251
215
|
// customer logged in: we show pins and perform pin/unpin
|
|
252
|
-
const renderPinsByCustomer = (recommendation, index, type) => (React.createElement(CaseSolutionsItem, { showPin: true,
|
|
216
|
+
const renderPinsByCustomer = (recommendation, index, type) => (React.createElement(CaseSolutionsItem, { showPin: true, type: type, pinTitle: recommendation.isPinned ? 'Unpin' : 'Pin', isPinLoading: isPinLoading, index: index, recommendation: recommendation, onPinClicked: updateRecommendations(recommendation, recommendation.isPinned, undefined) }));
|
|
253
217
|
// customer logged in: we show links but perform pin/unpin
|
|
254
|
-
const renderHandpickedCustomerView = (recommendation, index, type) => (React.createElement(
|
|
218
|
+
const renderHandpickedCustomerView = (recommendation, index, type) => (React.createElement(CaseSolutionsItem, { showPin: true, type: type, pinTitle: recommendation.isPinnedAndLinked ? 'Unpin' : 'Pin', isPinLoading: isPinLoading, index: index, recommendation: recommendation, onPinClicked: updateRecommendations(recommendation, recommendation.isPinned, undefined) }));
|
|
255
219
|
// redhatter logged in: we show pins but perform link/unlink
|
|
256
|
-
const renderPinnedByCustomerRedhatterView = (recommendation, index, type) => (React.createElement(CaseSolutionsItem, { showLink: true, type: type, pinTitle: recommendation.isPinnedAndLinked ?
|
|
220
|
+
const renderPinnedByCustomerRedhatterView = (recommendation, index, type) => (React.createElement(CaseSolutionsItem, { showLink: true, type: type, pinTitle: recommendation.isPinnedAndLinked ? 'Unpin' : 'Pin', isPinLoading: isPinLoading, index: index, recommendation: recommendation, onPinClicked: updateRecommendations(recommendation, undefined, recommendation.isLinked) }));
|
|
257
221
|
// redhatter logged in: we show links and perform link/unlink
|
|
258
|
-
const renderHandPickedByRedHatter = (recommendation, index, type) => (React.createElement(
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
const closeCaseModal = (React.createElement(Modal, { variant: ModalVariant.small, title: t('Did this solve your case?'), isOpen: isCloseCaseModalOpen && caseStatus !== CaseStatusEnum.CLOSED, onClose: () => setIsCloseCaseModalOpen(false), actions: [
|
|
263
|
-
React.createElement(Button, { variant: "primary", isDisabled: isCaseCloseLoading, onClick: () => setIsCloseCaseModalOpen(false), key: "keep-case-open-btn" },
|
|
264
|
-
React.createElement(Trans, null, "Keep it open")),
|
|
265
|
-
React.createElement(Button, { variant: "secondary", isDisabled: isCaseCloseLoading, isLoading: isCaseCloseLoading, key: "close-case-btn", onClick: handleCaseClose },
|
|
266
|
-
React.createElement(Trans, null, "Close case")),
|
|
267
|
-
] },
|
|
268
|
-
React.createElement(Trans, null, "We're glad to hear this article was helpful. Would you like to close this case or keep it open? You can still view the case after it closes.")));
|
|
222
|
+
const renderHandPickedByRedHatter = (recommendation, index, type) => (React.createElement(CaseSolutionsItem, { showLink: true, type: type, pinTitle: recommendation.isLinked ? 'Unlink' : 'Link', isPinLoading: isPinLoading, index: index, recommendation: recommendation, onPinClicked: updateRecommendations(recommendation, undefined, recommendation.isLinked) }));
|
|
223
|
+
const setExpandedSection = (id) => {
|
|
224
|
+
expanded === id ? setExpanded('') : setExpanded(id);
|
|
225
|
+
};
|
|
269
226
|
return (React.createElement(React.Fragment, null,
|
|
270
|
-
closeCaseModal,
|
|
271
|
-
React.createElement(Accordion, { isBordered: true, asDefinitionList: false, className: "card card-white case-details-aside-solutions" },
|
|
272
|
-
React.createElement(AccordionItem, null,
|
|
273
|
-
React.createElement(AccordionToggle, { id: "sol-handpicked", isExpanded: handPickedOpen, onClick: () => setHandPickedOpen((pre) => !pre) },
|
|
274
|
-
React.createElement("span", null, canLinkUnlink ? React.createElement(Trans, null, "Handpicked by you") : React.createElement(Trans, null, "Handpicked for this case")),
|
|
275
|
-
React.createElement("span", { className: "badge-item pf-v5-u-font-size-sm pf-v5-u-mx-sm" }, linkedRecommendations.length)),
|
|
276
|
-
React.createElement(AccordionContent, { isHidden: !handPickedOpen }, !hasLink ? (!canLinkUnlink ? (React.createElement(Trans, null, "If a Red Hat engineer finds an article or solution that can help with your case, they'll pin it here.")) : (React.createElement(React.Fragment, null))) : (React.createElement(PaginatedList, { id: "case-details-handpicked-recommendations", listItems: linkedRecommendations.map((rec, index) => canLinkUnlink
|
|
277
|
-
? renderHandPickedByRedHatter(rec, index, 'handpicked-recommendations')
|
|
278
|
-
: renderHandpickedCustomerView(rec, index, 'handpicked-recommendations')), perPage: 5, className: "list-icons list-icons-flush", isFetching: !!isLoadingRecommendations, perPageOptions: [
|
|
279
|
-
{ title: '5', value: 5 },
|
|
280
|
-
{ title: '10', value: 10 },
|
|
281
|
-
] })))),
|
|
282
|
-
React.createElement(AccordionItem, null,
|
|
283
|
-
React.createElement(AccordionToggle, { id: "sol-pinned", isExpanded: pinnedOpen, onClick: () => setPinnedOpen((pre) => !pre) },
|
|
284
|
-
React.createElement("span", null, canLinkUnlink ? (React.createElement(Trans, null, "Pinned by customer")) : (React.createElement(Trans, null, "My pinned recommendations"))),
|
|
285
|
-
React.createElement("span", { className: "badge-item pf-v5-u-font-size-sm pf-v5-u-mx-sm" }, pinnedRecommendations.length)),
|
|
286
|
-
React.createElement(AccordionContent, { isHidden: !pinnedOpen }, !hasPin ? (!canLinkUnlink ? (React.createElement(Trans, null, "When you save a recommended article or solution, you'll see it here. Saved items display only in this case and are not saved for later.")) : (React.createElement(React.Fragment, null))) : (React.createElement(PaginatedList, { id: "case-details-pinned-recommendations", listItems: pinnedRecommendations.map((rec, index) => canLinkUnlink
|
|
287
|
-
? renderPinnedByCustomerRedhatterView(rec, index, 'pinned-recommendations')
|
|
288
|
-
: renderPinsByCustomer(rec, index, 'pinned-recommendations')), perPage: 5, className: "list-icons list-icons-flush", isFetching: !!isLoadingRecommendations, perPageOptions: [
|
|
289
|
-
{ title: '5', value: 5 },
|
|
290
|
-
{ title: '10', value: 10 },
|
|
291
|
-
] }))))),
|
|
292
227
|
topRecommendations.length > 0 && (React.createElement("div", { className: "card card-white card-support recommendations", ref: ref },
|
|
293
228
|
React.createElement("h3", { className: "card-heading" },
|
|
294
|
-
React.createElement(Trans, null, "
|
|
229
|
+
React.createElement(Trans, null, "Top recommendations")),
|
|
295
230
|
React.createElement("div", { className: "card-body" },
|
|
296
|
-
React.createElement(PaginatedList, { id: "case-details-top-recommendations", className: "list-icons list-icons-flush", listItems: topRecommendations
|
|
297
|
-
.filter((r) => !pinnedRecommendations.some((pr) => pr.resourceId === r.resourceId))
|
|
298
|
-
.map((rec, index) => renderTopRecommendations(rec, index, 'top-recommendations')), perPage: 5, isFetching: !!isLoadingRecommendations, perPageOptions: [
|
|
231
|
+
React.createElement(PaginatedList, { id: "case-details-top-recommendations", className: "list-icons list-icons-flush", listItems: topRecommendations.map((rec, index) => renderTopRecommendations(rec, index, 'top-recommendations')), perPage: 5, isFetching: !!isLoadingRecommendations, perPageOptions: [
|
|
299
232
|
{ title: '5', value: 5 },
|
|
300
233
|
{ title: '10', value: 10 },
|
|
301
|
-
] }))))
|
|
234
|
+
] })))),
|
|
235
|
+
(hasPin || hasLink) && (React.createElement(Accordion, { asDefinitionList: false, className: "card card-white case-details-aside-solutions" },
|
|
236
|
+
hasLink && (React.createElement(AccordionItem, null,
|
|
237
|
+
React.createElement(AccordionToggle, { id: "sol-handpicked", isExpanded: expanded === 'sol-handpicked', onClick: () => setExpandedSection('sol-handpicked') }, canLinkUnlink ? React.createElement(Trans, null, "Handpicked by you") : React.createElement(Trans, null, "Handpicked for you")),
|
|
238
|
+
React.createElement(AccordionContent, { isHidden: expanded !== 'sol-handpicked' },
|
|
239
|
+
React.createElement(PaginatedList, { id: "case-details-handpicked-recommendations", listItems: recommendations
|
|
240
|
+
.filter((r) => r.isLinked)
|
|
241
|
+
.map((rec, index) => canLinkUnlink
|
|
242
|
+
? renderHandPickedByRedHatter(rec, index, 'handpicked-recommendations')
|
|
243
|
+
: renderHandpickedCustomerView(rec, index, 'handpicked-recommendations')), perPage: 5, className: "list-icons list-icons-flush", isFetching: !!isLoadingRecommendations, perPageOptions: [
|
|
244
|
+
{ title: '5', value: 5 },
|
|
245
|
+
{ title: '10', value: 10 },
|
|
246
|
+
] })))),
|
|
247
|
+
hasPin && (React.createElement(AccordionItem, null,
|
|
248
|
+
React.createElement(AccordionToggle, { id: "sol-pinned", isExpanded: expanded === 'sol-pinned', onClick: () => setExpandedSection('sol-pinned') }, canLinkUnlink ? React.createElement(Trans, null, "Pinned by customer") : React.createElement(Trans, null, "Your pins")),
|
|
249
|
+
React.createElement(AccordionContent, { isHidden: expanded !== 'sol-pinned' },
|
|
250
|
+
React.createElement(PaginatedList, { id: "case-details-pinned-recommendations", listItems: recommendations
|
|
251
|
+
.filter((r) => r.isPinned)
|
|
252
|
+
.map((rec, index) => canLinkUnlink
|
|
253
|
+
? renderPinnedByCustomerRedhatterView(rec, index, 'pinned-recommendations')
|
|
254
|
+
: renderPinsByCustomer(rec, index, 'pinned-recommendations')), perPage: 5, className: "list-icons list-icons-flush", isFetching: !!isLoadingRecommendations, perPageOptions: [
|
|
255
|
+
{ title: '5', value: 5 },
|
|
256
|
+
{ title: '10', value: 10 },
|
|
257
|
+
] }))))))));
|
|
302
258
|
});
|
|
@@ -1,8 +1,6 @@
|
|
|
1
1
|
import { ICaseResourceLink } from '@cee-eng/hydrajs/@types/api/public/case';
|
|
2
|
-
import { CaseRecommendationEvalEnum } from '../../../constants/caseDetailsConstants';
|
|
3
2
|
interface IProps {
|
|
4
3
|
showPin?: boolean;
|
|
5
|
-
isPinned?: boolean;
|
|
6
4
|
showLink?: boolean;
|
|
7
5
|
pinTitle: string;
|
|
8
6
|
index: number;
|
|
@@ -11,11 +9,10 @@ interface IProps {
|
|
|
11
9
|
onPinClicked: () => void;
|
|
12
10
|
type: string;
|
|
13
11
|
}
|
|
14
|
-
|
|
12
|
+
interface ICaseDetailAsideRecommendation extends Partial<ICaseResourceLink> {
|
|
15
13
|
isPinned?: boolean;
|
|
16
14
|
isLinked?: boolean;
|
|
17
15
|
solutionAbstract?: string;
|
|
18
|
-
customerEvaluation?: CaseRecommendationEvalEnum;
|
|
19
16
|
}
|
|
20
17
|
export declare function CaseSolutionsItem(props: IProps): JSX.Element;
|
|
21
18
|
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CaseSolutionsItem.d.ts","sourceRoot":"","sources":["../../../../../src/components/CaseEditView/CaseSolutions/CaseSolutionsItem.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,yCAAyC,CAAC;
|
|
1
|
+
{"version":3,"file":"CaseSolutionsItem.d.ts","sourceRoot":"","sources":["../../../../../src/components/CaseEditView/CaseSolutions/CaseSolutionsItem.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,yCAAyC,CAAC;AAS5E,UAAU,MAAM;IACZ,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,QAAQ,EAAE,MAAM,CAAC;IACjB,KAAK,EAAE,MAAM,CAAC;IACd,cAAc,EAAE,8BAA8B,CAAC;IAC/C,YAAY,EAAE,GAAG,CAAC;IAClB,YAAY,EAAE,MAAM,IAAI,CAAC;IACzB,IAAI,EAAE,MAAM,CAAC;CAChB;AAED,UAAU,8BAA+B,SAAQ,OAAO,CAAC,iBAAiB,CAAC;IACvE,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,gBAAgB,CAAC,EAAE,MAAM,CAAC;CAC7B;AAED,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,MAAM,eA4C9C"}
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import { Button
|
|
1
|
+
import { Button } from '@patternfly/react-core';
|
|
2
2
|
import LinkIcon from '@patternfly/react-icons/dist/js/icons/link-icon';
|
|
3
|
-
import
|
|
4
|
-
import StarIcon from '@patternfly/react-icons/dist/js/icons/star-icon';
|
|
3
|
+
import ThumbTackIcon from '@patternfly/react-icons/dist/js/icons/thumb-tack-icon';
|
|
5
4
|
import { LoadingIndicator } from '@rh-support/components';
|
|
6
5
|
import { cleanupMarkDown, decodeMarkTag, truncate } from '@rh-support/utils';
|
|
7
6
|
import DOMPurify from 'dompurify';
|
|
@@ -10,12 +9,11 @@ export function CaseSolutionsItem(props) {
|
|
|
10
9
|
const maxTitleLength = 150;
|
|
11
10
|
const maxAbstractLength = 150;
|
|
12
11
|
const isLoading = !!props.isPinLoading[props.recommendation.resourceId];
|
|
13
|
-
return (React.createElement(
|
|
12
|
+
return (React.createElement(React.Fragment, null,
|
|
14
13
|
React.createElement("div", { className: "recommendation-header" },
|
|
15
14
|
React.createElement(Button, { title: props.pinTitle, onClick: props.onPinClicked, "data-tracking-id": `case-resource-${props.pinTitle}`, variant: "plain", className: "list-icon" },
|
|
16
15
|
isLoading && React.createElement(LoadingIndicator, { show: isLoading, size: "xs" }),
|
|
17
|
-
!isLoading && props.showPin &&
|
|
18
|
-
React.createElement(Icon, { size: "md" }, props.isPinned ? (React.createElement(StarIcon, { className: "pinned-resource", color: "0066cc" })) : (React.createElement(OutlinedStarIcon, { className: "pinned-resource", color: "0066cc" }))))),
|
|
16
|
+
!isLoading && props.showPin && React.createElement(ThumbTackIcon, { className: "pinned-resource" }),
|
|
19
17
|
!isLoading && props.showLink && React.createElement(LinkIcon, null)),
|
|
20
18
|
React.createElement("a", { href: props.recommendation.resourceViewURI, "data-tracking-id": `case-resource-${props.type}-link-${props.index}`, target: "_blank", rel: "noopener noreferrer", dangerouslySetInnerHTML: {
|
|
21
19
|
__html: DOMPurify.sanitize(truncate(decodeMarkTag(props.recommendation.title || ''), maxTitleLength)),
|
|
@@ -3,6 +3,6 @@ import { SubscriptionAbuseModalText, SubscriptionAbuseModalTitle } from '@rh-sup
|
|
|
3
3
|
import React from 'react';
|
|
4
4
|
import { Trans } from 'react-i18next';
|
|
5
5
|
export function CaseSubscriptionAbuseAlert() {
|
|
6
|
-
return (React.createElement(Alert, { className: "pf-
|
|
6
|
+
return (React.createElement(Alert, { className: "pf-u-mb-md", isInline: true, variant: AlertVariant.warning, title: React.createElement(Trans, null, SubscriptionAbuseModalTitle), children: React.createElement("p", { className: "pf-u-mb-sm" },
|
|
7
7
|
React.createElement(Trans, null, SubscriptionAbuseModalText)) }));
|
|
8
8
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ReopenCaseModal.d.ts","sourceRoot":"","sources":["../../../../../src/components/CaseEditView/ConfirmationModals/ReopenCaseModal.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ReopenCaseModal.d.ts","sourceRoot":"","sources":["../../../../../src/components/CaseEditView/ConfirmationModals/ReopenCaseModal.tsx"],"names":[],"mappings":"AAiBA,OAAO,EAAE,cAAc,EAAE,MAAM,yCAAyC,CAAC;AAEzE,UAAU,MAAM;IACZ,SAAS,EAAE,CAAC,WAAW,KAAA,EAAE,SAAS,KAAA,EAAE,UAAU,CAAC,KAAA,EAAE,iBAAiB,CAAC,KAAA,EAAE,cAAc,CAAC,KAAA,EAAE,mBAAmB,CAAC,KAAA,KAAK,IAAI,CAAC;IACpH,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,UAAU,EAAE,MAAM,CAAC;IACnB,UAAU,EAAE,OAAO,CAAC;IACpB,WAAW,EAAE,MAAM,EAAE,CAAC;IACtB,UAAU,EAAE,OAAO,CAAC;IACpB,YAAY,EAAE,cAAc,CAAC;IAC7B,aAAa,EAAE,MAAM,CAAC;CACzB;AAMD,wBAAgB,eAAe,CAAC,KAAK,EAAE,MAAM,eA8L5C"}
|
|
@@ -7,8 +7,8 @@ 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 { Button, ButtonVariant, Form, FormGroup,
|
|
11
|
-
import
|
|
10
|
+
import { Button, ButtonVariant, Form, FormGroup, Modal, ModalVariant, Select, SelectOption, TextArea, } from '@patternfly/react-core';
|
|
11
|
+
import ExclamationCircleIcon from '@patternfly/react-icons/dist/js/icons/exclamation-circle-icon';
|
|
12
12
|
import { formatDateTime } from '@rh-support/utils';
|
|
13
13
|
import isEmpty from 'lodash/isEmpty';
|
|
14
14
|
import React, { useState } from 'react';
|
|
@@ -76,21 +76,15 @@ export function ReopenCaseModal(props) {
|
|
|
76
76
|
React.createElement(Trans, null, "Cancel")),
|
|
77
77
|
], variant: ModalVariant.medium },
|
|
78
78
|
React.createElement(Form, { className: "case-reopen-modal-form" },
|
|
79
|
-
(!props.isInternal || !props.reopenStatus) && (React.createElement(FormGroup, { label: t(props.isInternal ? 'Status' : 'Reason'), isRequired: true, fieldId: "case-resolution"
|
|
80
|
-
|
|
81
|
-
React.createElement(
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
React.createElement(Trans, null, option)))))) : (React.createElement(Select, { "aria-label": t('Select an option that best fits'), id: "case-resolution", selections: selectedReason, onSelect: onReasonChange, isOpen: showDropdown, isDisabled: props.isUpdating, menuAppendTo: document.body, validated: showValidationError && !selectedReason ? 'error' : 'default', placeholderText: t('Select an option that best fits'), onToggle: (_event, toggle) => onDropdownToggle(toggle) }, reasonsList.map((option, index) => (React.createElement(SelectOption, { key: index, value: option },
|
|
88
|
-
React.createElement(Trans, null, option)))))))),
|
|
89
|
-
showTextArea && (React.createElement(FormGroup, { label: t('Please describe your reason'), type: "text", isRequired: true, fieldId: "reopen-case-description" },
|
|
79
|
+
(!props.isInternal || !props.reopenStatus) && (React.createElement(FormGroup, { label: t(props.isInternal ? 'Status' : 'Reason'), isRequired: true, fieldId: "case-resolution", helperTextInvalid: "Required field", validated: showValidationError && (props.isInternal ? !selectedStatus : !selectedReason)
|
|
80
|
+
? 'error'
|
|
81
|
+
: 'default', helperTextInvalidIcon: React.createElement(ExclamationCircleIcon, null) }, props.isInternal ? (React.createElement(Select, { "aria-label": t('Select an option that best fits'), id: "reopen-case-status", selections: selectedStatus, onSelect: onStatusChange, isOpen: showDropdown, isDisabled: props.isUpdating, menuAppendTo: document.body, validated: showValidationError && !selectedStatus ? 'error' : 'default', placeholderText: t('Select an option that best fits'), onToggle: onDropdownToggle }, props.allStatuses
|
|
82
|
+
.filter((status) => status !== CaseStatusEnum.CLOSED)
|
|
83
|
+
.map((option, index) => (React.createElement(SelectOption, { key: index, value: option },
|
|
84
|
+
React.createElement(Trans, null, option)))))) : (React.createElement(Select, { "aria-label": t('Select an option that best fits'), id: "case-resolution", selections: selectedReason, onSelect: onReasonChange, isOpen: showDropdown, isDisabled: props.isUpdating, menuAppendTo: document.body, validated: showValidationError && !selectedReason ? 'error' : 'default', placeholderText: t('Select an option that best fits'), onToggle: onDropdownToggle }, reasonsList.map((option, index) => (React.createElement(SelectOption, { key: index, value: option },
|
|
85
|
+
React.createElement(Trans, null, option)))))))),
|
|
86
|
+
showTextArea && (React.createElement(FormGroup, { label: t('Please describe your reason'), type: "text", helperText: t(`Your comment will be visible${props.isInternal ? ' to the customers' : ''} under discussions after reopening.`), isRequired: true, fieldId: "reopen-case-description" },
|
|
90
87
|
React.createElement(TextArea, { placeholder: t(props.isInternal
|
|
91
88
|
? 'Describe the reason for reopening with the selected status'
|
|
92
|
-
: 'The better the description, the easier it will be for our support team to address your case.'), validated: showValidationError && isDescriptionEmpty && !reopenDescription ? 'error' : 'default', isRequired: true, id: "reopen-case-description", name: "reopen-case-description", "aria-describedby": "reopen-case-description", value: reopenDescription, onChange:
|
|
93
|
-
React.createElement(FormHelperText, null,
|
|
94
|
-
React.createElement(HelperText, null,
|
|
95
|
-
React.createElement(HelperTextItem, null, t(`Your comment will be visible${props.isInternal ? ' to the customers' : ''} under discussions after reopening.`)))))))));
|
|
89
|
+
: 'The better the description, the easier it will be for our support team to address your case.'), validated: showValidationError && isDescriptionEmpty && !reopenDescription ? 'error' : 'default', isRequired: true, id: "reopen-case-description", name: "reopen-case-description", "aria-describedby": "reopen-case-description", value: reopenDescription, onChange: onDescriptionChange, isDisabled: props.isUpdating }))))));
|
|
96
90
|
}
|
|
@@ -29,7 +29,7 @@ export const ESSRemoteSession = forwardRef((props, ref) => {
|
|
|
29
29
|
const termsAcked = remoteSessionTermsAcked && !screenSessionRequested;
|
|
30
30
|
// ESS RS Aside Section Body
|
|
31
31
|
const ESSRemoteSessionSectionBody = (React.createElement("div", { className: "card card-white card-support escalations", ref: ref },
|
|
32
|
-
React.createElement("h3", { className: "card-heading pf-
|
|
32
|
+
React.createElement("h3", { className: "card-heading pf-u-display-flex pf-u-justify-content-space-between" },
|
|
33
33
|
t('Remote session'),
|
|
34
34
|
React.createElement(Popover, { "aria-label": t('Remote Session Helper Info'), bodyContent: t('A remote session allows support engineers to view or access your computer to simplify collaboration and troubleshooting.'), footerContent: React.createElement("a", { href: "/articles/3566571", target: "_blank", rel: "noopener noreferrer", "aria-label": t('Read more about remote sessions') }, t('Read more about remote sessions')) },
|
|
35
35
|
React.createElement(InfoCircleIcon, null))),
|
|
@@ -40,7 +40,7 @@ export const ESSRemoteSession = forwardRef((props, ref) => {
|
|
|
40
40
|
React.createElement("li", null, t(`Such access will help diagnose, debug or lead to the resolution of a software defect`)),
|
|
41
41
|
React.createElement("li", null, t('Agreed upon by both Red Hat and you, the end user'))),
|
|
42
42
|
React.createElement("p", { className: "rrs-light-grey-text" }, t('Red Hat will add a comment to your case to schedule your remote session.')),
|
|
43
|
-
screenSessionRequested && (React.createElement(Tooltip, { content: t('Remote session request has already been submitted.'),
|
|
43
|
+
screenSessionRequested && (React.createElement(Tooltip, { content: t('Remote session request has already been submitted.'), reference: tooltipRef, "aria-live": 'polite' })),
|
|
44
44
|
React.createElement(Button, { "aria-label": screenSessionRequested ? t('Remote session requested') : t('Request remote session'), variant: screenSessionRequested ? 'primary' : 'secondary', onClick: termsAcked ? toggleESSRemoteSessionModal : toggleNewESSRemoteSessionModal, "data-tracking-id": "accept-remote-session-agreement-trigger", isAriaDisabled: screenSessionRequested, ref: tooltipRef }, screenSessionRequested ? t('Remote session requested') : t('Request remote session')))));
|
|
45
45
|
return (React.createElement(React.Fragment, null,
|
|
46
46
|
ESSRemoteSessionSectionBody,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ESSRemoteSessionModal.d.ts","sourceRoot":"","sources":["../../../../../src/components/CaseEditView/RequestRemoteSession/ESSRemoteSessionModal.tsx"],"names":[],"mappings":"AAIA,OAAO,EAAE,mBAAmB,EAAE,MAAM,0BAA0B,CAAC;AAC/D,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AAiBxD,UAAU,MAAM;IACZ,UAAU,EAAE,MAAM,CAAC;IACnB,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,YAAY,EAAE,MAAM,CAAC;IACrB,UAAU,EAAE,MAAM,CAAC;IACnB,IAAI,EAAE,OAAO,CAAC;IACd,kBAAkB,EAAE,mBAAmB,CAAC,QAAQ,CAAC,CAAC;IAClD,QAAQ,EAAE,OAAO,CAAC;IAClB,sBAAsB,EAAE,OAAO,CAAC;CACnC;AAED,wBAAgB,qBAAqB,CAAC,KAAK,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"ESSRemoteSessionModal.d.ts","sourceRoot":"","sources":["../../../../../src/components/CaseEditView/RequestRemoteSession/ESSRemoteSessionModal.tsx"],"names":[],"mappings":"AAIA,OAAO,EAAE,mBAAmB,EAAE,MAAM,0BAA0B,CAAC;AAC/D,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AAiBxD,UAAU,MAAM;IACZ,UAAU,EAAE,MAAM,CAAC;IACnB,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,YAAY,EAAE,MAAM,CAAC;IACrB,UAAU,EAAE,MAAM,CAAC;IACnB,IAAI,EAAE,OAAO,CAAC;IACd,kBAAkB,EAAE,mBAAmB,CAAC,QAAQ,CAAC,CAAC;IAClD,QAAQ,EAAE,OAAO,CAAC;IAClB,sBAAsB,EAAE,OAAO,CAAC;CACnC;AAED,wBAAgB,qBAAqB,CAAC,KAAK,EAAE,MAAM,eAoKlD"}
|
|
@@ -8,7 +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 { Button, ButtonVariant,
|
|
11
|
+
import { Button, ButtonVariant, Modal, ModalVariant, Title, TitleSizes } from '@patternfly/react-core';
|
|
12
12
|
import CheckCircleIcon from '@patternfly/react-icons/dist/js/icons/check-circle-icon';
|
|
13
13
|
import { ToastNotification, useFetch } from '@rh-support/components';
|
|
14
14
|
import React, { useState } from 'react';
|
|
@@ -91,19 +91,18 @@ export function ESSRemoteSessionModal(props) {
|
|
|
91
91
|
// Body of ESS Modal
|
|
92
92
|
const ESSRemoteSessionModalBody = () => {
|
|
93
93
|
return (React.createElement(React.Fragment, null,
|
|
94
|
-
React.createElement("p", { className: "pf-
|
|
94
|
+
React.createElement("p", { className: "pf-u-mt-xs" },
|
|
95
95
|
React.createElement(Trans, null, "To troubleshoot your problem, Red Hat support accesses your network or systems remotely."))));
|
|
96
96
|
};
|
|
97
97
|
const RequestedESSRemoteSessionModalBody = () => {
|
|
98
98
|
return (React.createElement(React.Fragment, null,
|
|
99
|
-
React.createElement("p", { className: "pf-
|
|
99
|
+
React.createElement("p", { className: "pf-u-mt-xs" },
|
|
100
100
|
React.createElement(Trans, null, "Red Hat will add a comment to your case to schedule your remote session."))));
|
|
101
101
|
};
|
|
102
102
|
const essModalHeader = props.screenSessionRequested ? (React.createElement(React.Fragment, null,
|
|
103
|
-
React.createElement(Title, { className: "pf-
|
|
104
|
-
React.createElement(
|
|
105
|
-
React.createElement(CheckCircleIcon, { color: "#3E8635", className: "pf-v5-u-mr-md" })),
|
|
103
|
+
React.createElement(Title, { className: "pf-u-mb-xs", id: "modal-custom-header-label", headingLevel: "h1", size: TitleSizes['2xl'] },
|
|
104
|
+
React.createElement(CheckCircleIcon, { color: "#3E8635", size: "lg", className: "pf-u-mr-md" }),
|
|
106
105
|
t('Remote session has been requested')))) : (React.createElement(React.Fragment, null,
|
|
107
|
-
React.createElement(Title, { className: "pf-
|
|
106
|
+
React.createElement(Title, { className: "pf-u-mb-xs", id: "modal-custom-header-label", headingLevel: "h1", size: TitleSizes['2xl'] }, t('Request a remote session?'))));
|
|
108
107
|
return (React.createElement(Modal, { variant: ModalVariant.small, id: "remote-session-agreement-modal", "aria-label": props.screenSessionRequested ? t('Remote session has been requested') : t('Request a remote session?'), header: essModalHeader, isOpen: props.show, onClose: onCancel, actions: props.screenSessionRequested ? acceptedModalActions : modalActions }, props.screenSessionRequested ? RequestedESSRemoteSessionModalBody() : ESSRemoteSessionModalBody()));
|
|
109
108
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NewEssTermsModal.d.ts","sourceRoot":"","sources":["../../../../../src/components/CaseEditView/RequestRemoteSession/NewEssTermsModal.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"NewEssTermsModal.d.ts","sourceRoot":"","sources":["../../../../../src/components/CaseEditView/RequestRemoteSession/NewEssTermsModal.tsx"],"names":[],"mappings":"AAMA,OAAO,EAAE,mBAAmB,EAAE,MAAM,0BAA0B,CAAC;AAC/D,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AAaxD,UAAU,MAAM;IACZ,UAAU,EAAE,MAAM,CAAC;IACnB,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,QAAQ,EAAE,MAAM,CAAC;IACjB,SAAS,EAAE,MAAM,CAAC;IAClB,YAAY,EAAE,MAAM,CAAC;IACrB,UAAU,EAAE,MAAM,CAAC;IACnB,IAAI,EAAE,OAAO,CAAC;IACd,kBAAkB,EAAE,mBAAmB,CAAC,QAAQ,CAAC,CAAC;IAClD,QAAQ,EAAE,OAAO,CAAC;CACrB;AAiBD,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,MAAM,eA6P7C"}
|
|
@@ -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 { Button, ButtonVariant, Checkbox, Modal } from '@patternfly/react-core';
|
|
12
|
-
import { Select, SelectOption } from '@patternfly/react-core/deprecated';
|
|
11
|
+
import { Button, ButtonVariant, Checkbox, Modal, Select, SelectOption } from '@patternfly/react-core';
|
|
13
12
|
import DownloadIcon from '@patternfly/react-icons/dist/esm/icons/download-icon';
|
|
14
13
|
import ExternalLinkAltIcon from '@patternfly/react-icons/dist/js/icons/external-link-alt-icon';
|
|
15
14
|
import { ToastNotification, useFetch } from '@rh-support/components';
|
|
@@ -137,7 +136,7 @@ export function NewEssTermsModal(props) {
|
|
|
137
136
|
submitRemoteSessionAgreement(selectedTranslation.termsPdfId);
|
|
138
137
|
};
|
|
139
138
|
// Handle terms checkbox
|
|
140
|
-
const onCheckBoxChange = (
|
|
139
|
+
const onCheckBoxChange = (value) => {
|
|
141
140
|
setIsTermsChecked(value);
|
|
142
141
|
};
|
|
143
142
|
// Handle language change
|
|
@@ -156,26 +155,26 @@ export function NewEssTermsModal(props) {
|
|
|
156
155
|
// Body of ESS RSA Modal
|
|
157
156
|
const EssRSAModalBody = () => {
|
|
158
157
|
return (React.createElement(React.Fragment, null,
|
|
159
|
-
React.createElement("p", { className: "pf-
|
|
158
|
+
React.createElement("p", { className: "pf-u-mt-xs" },
|
|
160
159
|
React.createElement(Trans, null,
|
|
161
160
|
"Your acceptance of this remote session agreement is required ",
|
|
162
161
|
React.createElement("strong", null, "for each case"),
|
|
163
162
|
" when you request Red Hat\u2019s support team to directly access your network or systems.")),
|
|
164
|
-
React.createElement("p", { className: "pf-
|
|
163
|
+
React.createElement("p", { className: "pf-u-mt-md" },
|
|
165
164
|
React.createElement(Trans, null, "Remote access to your network or systems is not a standard Red Hat problem resolution process. Before Red Hat logs into your systems to analyze your support issue during a remote session, Red Hat needs your approval and authorization for such remote access.")),
|
|
166
|
-
React.createElement("p", { className: "pf-
|
|
165
|
+
React.createElement("p", { className: "pf-u-mt-md" },
|
|
167
166
|
React.createElement(Trans, null, "Please read and accept the remote session terms below to allow Red Hat to access your network or systems.")),
|
|
168
167
|
React.createElement("div", null,
|
|
169
|
-
React.createElement(Select, { className: "pf-
|
|
170
|
-
React.createElement("a", { "aria-label": t('Download'), "data-tracking-id": "rsa-modal-terms-download", className: "pf-
|
|
168
|
+
React.createElement(Select, { className: "pf-u-mt-md", "aria-label": t('Select language'), id: "terms-language-selector", selections: selectedTranslation.localeCode, onSelect: onLangChange, isOpen: isLangSelectorDropdownOpen, menuAppendTo: document.body, placeholderText: t('Select an option that best fits'), onToggle: onDropdownToggle, width: 350 }, Object.keys(allTranslations).map((option, index) => (React.createElement(SelectOption, { key: index, value: option }, getLocaleNameFromLocalCode(option))))),
|
|
169
|
+
React.createElement("a", { "aria-label": t('Download'), "data-tracking-id": "rsa-modal-terms-download", className: "pf-u-ml-md", href: selectedTranslation.pdfDownloadUrl, rel: "noopener noreferrer", target: "_blank" },
|
|
171
170
|
t('Download'),
|
|
172
171
|
" ",
|
|
173
|
-
React.createElement(DownloadIcon, { className: "pf-
|
|
172
|
+
React.createElement(DownloadIcon, { className: "pf-u-ml-xs" }))),
|
|
174
173
|
React.createElement("div", null,
|
|
175
|
-
React.createElement(Checkbox, { className: "pf-
|
|
174
|
+
React.createElement(Checkbox, { className: "pf-u-mt-md rsa-checkbox", id: "terms-accept-checkbox", label: React.createElement(React.Fragment, null,
|
|
176
175
|
React.createElement(Trans, null, "I have read and agree to the"),
|
|
177
176
|
' ',
|
|
178
|
-
React.createElement("a", { className: "pf-
|
|
177
|
+
React.createElement("a", { className: "pf-c-button pf-m-link pf-m-inline align-link-items", rel: "noopener noreferrer", target: "_blank", href: selectedTranslation.pdfDownloadUrl, "data-tracking-id": "case-details-request-remote-session-terms" },
|
|
179
178
|
React.createElement(Trans, null, "terms "),
|
|
180
179
|
React.createElement(ExternalLinkAltIcon, null))), isChecked: isTermsChecked, "aria-label": t('I have read and agree to the terms'), onChange: onCheckBoxChange }))));
|
|
181
180
|
};
|
|
@@ -20,7 +20,7 @@ export const RemoteSessionAgreement = forwardRef((props, ref) => {
|
|
|
20
20
|
};
|
|
21
21
|
// RSA Aside Section Body
|
|
22
22
|
const RemoteSessionAgreementSectionBody = (React.createElement("div", { className: "card card-white card-support escalations", ref: ref },
|
|
23
|
-
React.createElement("h3", { className: "card-heading pf-
|
|
23
|
+
React.createElement("h3", { className: "card-heading pf-u-display-flex pf-u-justify-content-space-between" },
|
|
24
24
|
t('Remote session agreement'),
|
|
25
25
|
React.createElement(Popover, { "aria-label": t('Remote Session Helper Info'), bodyContent: t('Before Red Hat logs into your systems to analyze your support issue during a remote session, Red Hat needs your approval and authorization for such remote access'), footerContent: React.createElement("a", { href: "/articles/3566571", target: "_blank", rel: "noopener noreferrer", "aria-label": t('Read more about remote sessions') }, t('Read more about remote sessions')) },
|
|
26
26
|
React.createElement(InfoCircleIcon, null))),
|
|
@@ -31,7 +31,7 @@ export const RemoteSessionAgreement = forwardRef((props, ref) => {
|
|
|
31
31
|
React.createElement("li", null, t(`Such access helps diagnose, debug or lead to the resolution of a software defect.`)),
|
|
32
32
|
React.createElement("li", null, t('Both you and Red Hat agree to remote access.'))),
|
|
33
33
|
React.createElement("p", { className: "rrs-light-grey-text" }, t('This action does not initiate a remote session. Please make a case comment if you would like to submit a request.')),
|
|
34
|
-
acceptedRemoteSessionTerms && (React.createElement(Tooltip, { content: t('Remote session agreement has already been accepted.'),
|
|
34
|
+
acceptedRemoteSessionTerms && (React.createElement(Tooltip, { content: t('Remote session agreement has already been accepted.'), reference: tooltipRef, "aria-live": 'polite' })),
|
|
35
35
|
React.createElement(Button, { "aria-label": acceptedRemoteSessionTerms ? t('Agreement accepted') : t('Accept agreement'), variant: acceptedRemoteSessionTerms ? 'primary' : 'secondary', onClick: toggleRemoteSessionAgreementModal, "data-tracking-id": "accept-remote-session-agreement-trigger", isAriaDisabled: acceptedRemoteSessionTerms, ref: tooltipRef }, acceptedRemoteSessionTerms ? t('Agreement accepted') : t('Accept agreement')))));
|
|
36
36
|
return (React.createElement(React.Fragment, null,
|
|
37
37
|
RemoteSessionAgreementSectionBody,
|
package/lib/esm/components/CaseEditView/RequestRemoteSession/RemoteSessionAgreementModal.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RemoteSessionAgreementModal.d.ts","sourceRoot":"","sources":["../../../../../src/components/CaseEditView/RequestRemoteSession/RemoteSessionAgreementModal.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"RemoteSessionAgreementModal.d.ts","sourceRoot":"","sources":["../../../../../src/components/CaseEditView/RequestRemoteSession/RemoteSessionAgreementModal.tsx"],"names":[],"mappings":"AAMA,OAAO,EAAE,mBAAmB,EAAE,MAAM,0BAA0B,CAAC;AAC/D,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AAiBxD,UAAU,MAAM;IACZ,UAAU,EAAE,MAAM,CAAC;IACnB,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,QAAQ,EAAE,MAAM,CAAC;IACjB,SAAS,EAAE,MAAM,CAAC;IAClB,YAAY,EAAE,MAAM,CAAC;IACrB,UAAU,EAAE,MAAM,CAAC;IACnB,IAAI,EAAE,OAAO,CAAC;IACd,kBAAkB,EAAE,mBAAmB,CAAC,QAAQ,CAAC,CAAC;IAClD,QAAQ,EAAE,OAAO,CAAC;CACrB;AAiBD,wBAAgB,2BAA2B,CAAC,KAAK,EAAE,MAAM,eAuPxD"}
|
|
@@ -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 { Button, ButtonVariant, Checkbox, Modal } from '@patternfly/react-core';
|
|
12
|
-
import { Select, SelectOption } from '@patternfly/react-core/deprecated';
|
|
11
|
+
import { Button, ButtonVariant, Checkbox, Modal, Select, SelectOption } from '@patternfly/react-core';
|
|
13
12
|
import DownloadIcon from '@patternfly/react-icons/dist/esm/icons/download-icon';
|
|
14
13
|
import ExternalLinkAltIcon from '@patternfly/react-icons/dist/js/icons/external-link-alt-icon';
|
|
15
14
|
import { ToastNotification, useFetch } from '@rh-support/components';
|
|
@@ -147,28 +146,28 @@ export function RemoteSessionAgreementModal(props) {
|
|
|
147
146
|
// Body of RSA Modal
|
|
148
147
|
const RemoteSessionAgreementModalBody = () => {
|
|
149
148
|
return (React.createElement(React.Fragment, null,
|
|
150
|
-
React.createElement("p", { className: "pf-
|
|
149
|
+
React.createElement("p", { className: "pf-u-mt-xs" },
|
|
151
150
|
React.createElement(Trans, null,
|
|
152
151
|
"Your acceptance of this Remote Access Rider is required ",
|
|
153
152
|
React.createElement("strong", null, "for each case"),
|
|
154
153
|
" when you request Red Hat\u2019s support team to directly access your network or systems.")),
|
|
155
|
-
React.createElement("p", { className: "pf-
|
|
154
|
+
React.createElement("p", { className: "pf-u-mt-md" },
|
|
156
155
|
React.createElement(Trans, null, "Remote access to your network or systems is not a standard Red Hat problem resolution process. Before Red Hat logs into your systems to analyze your support issue during a remote session, Red Hat needs your approval and authorization for such remote access.")),
|
|
157
|
-
React.createElement("p", { className: "pf-
|
|
156
|
+
React.createElement("p", { className: "pf-u-mt-md" },
|
|
158
157
|
React.createElement(Trans, null, "Please read and accept the Remote Access Rider terms below to allow Red Hat to access your network or systems.")),
|
|
159
158
|
React.createElement("div", null,
|
|
160
|
-
React.createElement(Select, { className: "pf-
|
|
161
|
-
React.createElement("a", { "aria-label": t('Download'), "data-tracking-id": "rsa-modal-terms-download", className: "pf-
|
|
159
|
+
React.createElement(Select, { className: "pf-u-mt-md", "aria-label": t('Select language'), id: "terms-language-selector", selections: selectedTranslation.localeCode, onSelect: onLangChange, isOpen: isLangSelectorDropdownOpen, menuAppendTo: document.body, placeholderText: t('Select an option that best fits'), onToggle: onDropdownToggle, width: 350 }, Object.keys(allTranslations).map((option, index) => (React.createElement(SelectOption, { key: index, value: option }, getLocaleNameFromLocalCode(option))))),
|
|
160
|
+
React.createElement("a", { "aria-label": t('Download'), "data-tracking-id": "rsa-modal-terms-download", className: "pf-u-ml-md", href: selectedTranslation.pdfDownloadUrl, rel: "noopener noreferrer", target: "_blank" },
|
|
162
161
|
t('Download'),
|
|
163
162
|
" ",
|
|
164
|
-
React.createElement(DownloadIcon, { className: "pf-
|
|
163
|
+
React.createElement(DownloadIcon, { className: "pf-u-ml-xs" }))),
|
|
165
164
|
React.createElement("div", null,
|
|
166
|
-
React.createElement(Checkbox, { className: "pf-
|
|
165
|
+
React.createElement(Checkbox, { className: "pf-u-mt-md rsa-checkbox", id: "terms-accept-checkbox", label: React.createElement(React.Fragment, null,
|
|
167
166
|
React.createElement(Trans, null, "I have read and agree to the"),
|
|
168
167
|
' ',
|
|
169
|
-
React.createElement("a", { className: "pf-
|
|
168
|
+
React.createElement("a", { className: "pf-c-button pf-m-link pf-m-inline align-link-items", rel: "noopener noreferrer", target: "_blank", href: selectedTranslation.pdfDownloadUrl, "data-tracking-id": "case-details-request-remote-session-terms" },
|
|
170
169
|
React.createElement(Trans, null, "terms "),
|
|
171
|
-
React.createElement(ExternalLinkAltIcon, null))), isChecked: isTermsChecked, "aria-label": t('I have read and agree to the terms'), onChange:
|
|
170
|
+
React.createElement(ExternalLinkAltIcon, null))), isChecked: isTermsChecked, "aria-label": t('I have read and agree to the terms'), onChange: onCheckBoxChange }))));
|
|
172
171
|
};
|
|
173
172
|
return (React.createElement(Modal, { id: "remote-session-agreement-modal", "aria-label": t('Remote Session Agreement'), title: t('Remote Session Agreement'), isOpen: props.show, onClose: onCancel, actions: modalActions }, RemoteSessionAgreementModalBody()));
|
|
174
173
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CaseActionPlan.d.ts","sourceRoot":"","sources":["../../../../../../src/components/CaseEditView/Tabs/CaseActionPlan/CaseActionPlan.tsx"],"names":[],"mappings":"AAqBA,UAAU,MAAM;IACZ,UAAU,EAAE,MAAM,CAAC;CACtB;AAMD,iBAAS,cAAc,CAAC,KAAK,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"CaseActionPlan.d.ts","sourceRoot":"","sources":["../../../../../../src/components/CaseEditView/Tabs/CaseActionPlan/CaseActionPlan.tsx"],"names":[],"mappings":"AAqBA,UAAU,MAAM;IACZ,UAAU,EAAE,MAAM,CAAC;CACtB;AAMD,iBAAS,cAAc,CAAC,KAAK,EAAE,MAAM,eAyIpC;kBAzIQ,cAAc;;;AA4IvB,eAAe,cAAc,CAAC"}
|
|
@@ -82,13 +82,13 @@ function CaseActionPlan(props) {
|
|
|
82
82
|
return { __html: htmlString };
|
|
83
83
|
};
|
|
84
84
|
return (React.createElement(React.Fragment, null,
|
|
85
|
-
React.createElement(AlertMessage, { show: isInternalWithoutSFDCUser, variant: AlertType.WARNING, isInline: true, className: "pf-
|
|
85
|
+
React.createElement(AlertMessage, { show: isInternalWithoutSFDCUser, variant: AlertType.WARNING, isInline: true, className: "pf-u-mb-lg", title: t('You need a Salesforce (SFDC) user to edit the action plan.') }),
|
|
86
86
|
React.createElement("label", { htmlFor: "rha-action-plan", className: "sr-only" },
|
|
87
87
|
React.createElement(Trans, null, "Action plan")),
|
|
88
88
|
!canUpdateActionPlan && (React.createElement("pre", { "aria-label": t('Case Action Plan'), dangerouslySetInnerHTML: commentMarkdown(actionPlan), style: { fontFamily: isExportingPDF ? 'DejaVu Sans' : '' } })),
|
|
89
89
|
canUpdateActionPlan && (React.createElement("form", null,
|
|
90
90
|
React.createElement("div", { className: isExportingPDF ? 'hide-in-pdf' : '' },
|
|
91
|
-
React.createElement(TextAreaResizable, { id: "rha-action-plan", disabled: isUpdating || isInternalWithoutSFDCUser, maxLength: 32768, name: "actionPlan", value: actionPlanState, onChange: onChange, rowsMin: 3 })),
|
|
91
|
+
React.createElement(TextAreaResizable, { className: "form-control", id: "rha-action-plan", disabled: isUpdating || isInternalWithoutSFDCUser, maxLength: 32768, name: "actionPlan", value: actionPlanState, onChange: onChange, rowsMin: 3 })),
|
|
92
92
|
!isInternalWithoutSFDCUser && (React.createElement("div", { className: `${isExportingPDF ? 'hide-in-pdf' : ''} push-top-narrow` },
|
|
93
93
|
React.createElement("button", { className: "btn btn-app btn-primary", onClick: updateCase, disabled: isActionPlanEmpty || isUpdating || !formIsDirty },
|
|
94
94
|
React.createElement(Trans, null, "Submit"),
|
|
@@ -96,7 +96,7 @@ function CaseActionPlan(props) {
|
|
|
96
96
|
React.createElement(LoadingIndicator, { show: isUpdating, isInline: true })),
|
|
97
97
|
React.createElement("button", { className: "btn btn-app btn-link", onClick: discardActionPlan, disabled: isUpdating || !formIsDirty },
|
|
98
98
|
React.createElement(Trans, null, "Cancel")))),
|
|
99
|
-
React.createElement("p", { className: "pf-
|
|
99
|
+
React.createElement("p", { className: "pf-u-mt-xl" },
|
|
100
100
|
React.createElement(Trans, null,
|
|
101
101
|
"Updates to the action plan are ",
|
|
102
102
|
React.createElement("strong", null, "customer-facing"),
|
|
@@ -8,7 +8,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
8
8
|
});
|
|
9
9
|
};
|
|
10
10
|
import { contacts } from '@cee-eng/hydrajs';
|
|
11
|
-
import { InputGroupText, ValidatedOptions } from '@patternfly/react-core';
|
|
11
|
+
import { InputGroupText, InputGroupTextVariant, ValidatedOptions } from '@patternfly/react-core';
|
|
12
12
|
import CheckIcon from '@patternfly/react-icons/dist/js/icons/check-icon';
|
|
13
13
|
import TimesIcon from '@patternfly/react-icons/dist/js/icons/times-icon';
|
|
14
14
|
import { getPhoneObj, PhoneInput, ToastNotification } from '@rh-support/components';
|
|
@@ -146,13 +146,13 @@ export function CaseContactPhoneNumber() {
|
|
|
146
146
|
}
|
|
147
147
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
148
148
|
}, []);
|
|
149
|
-
return (React.createElement("div", { className: "form-group pf-
|
|
149
|
+
return (React.createElement("div", { className: "form-group pf-u-pb-md", style: { minWidth: '200px' } },
|
|
150
150
|
React.createElement("h3", { className: `subheading subheading-sm ${isExportingPDF ? 'expand-input' : ''}` },
|
|
151
151
|
React.createElement(Trans, null, "Case owner's phone number"),
|
|
152
152
|
!isExportingPDF ? ContactPhoneNumberPopOver() : ''),
|
|
153
|
-
React.createElement(InputGroupText,
|
|
153
|
+
React.createElement(InputGroupText, { variant: InputGroupTextVariant.plain },
|
|
154
154
|
React.createElement(PhoneInput, { phoneValue: localFullPhoneState, onPhoneValueChange: onPhoneChange, onCountryCodeChange: onCountryCodeChange, validations: isPhoneNumberValid, isDisabled: isCasePhoneUpdating || isCaseOwnerUpdating, isLoading: isCasePhoneUpdating, "data-tracking-id": "case-details-page-supplied-phone", invalid: invalid, setInvalid: setInvalid }),
|
|
155
|
-
React.createElement("button", { className: "btn btn-app btn-link pf-
|
|
155
|
+
React.createElement("button", { className: "btn btn-app btn-link pf-u-ml-sm", type: "button", "data-tracking-id": "case-details-page-supplied-phone-save", onClick: () => onSave(), disabled: (localFullPhoneState === null || localFullPhoneState === void 0 ? void 0 : localFullPhoneState.length) > PHONE_LIMIT ||
|
|
156
156
|
localFullPhoneState === phoneCountryCode + ' ' + phoneAreaCodePrefixLineNumber ||
|
|
157
157
|
(isSaveClicked && isPhoneValueCannotBeSaved), style: { display: isExportingPDF ? 'none' : '' } },
|
|
158
158
|
React.createElement(CheckIcon, null)),
|