@rh-support/troubleshoot 2.6.340 → 2.6.349
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/AccountInfo/AccountSelector.d.ts.map +1 -1
- package/lib/esm/components/AccountInfo/AccountSelector.js +29 -19
- package/lib/esm/components/AccountInfo/OwnerSelector.d.ts.map +1 -1
- package/lib/esm/components/AccountInfo/OwnerSelector.js +16 -91
- package/lib/esm/components/CaseEditView/ActiveCustomerEscalation/ActiveCustomerEscalation.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/ActiveCustomerEscalation/ActiveCustomerEscalation.js +1 -1
- package/lib/esm/components/CaseEditView/ActiveCustomerEscalation/RequestEscalationModal.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/ActiveCustomerEscalation/RequestEscalationModal.js +32 -61
- package/lib/esm/components/CaseEditView/Case.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Case.js +33 -60
- package/lib/esm/components/CaseEditView/CaseDetailsAside.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/CaseDetailsAside.js +10 -39
- package/lib/esm/components/CaseEditView/CaseDetailsErrorMessage.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/CaseDetailsErrorMessage.js +4 -15
- package/lib/esm/components/CaseEditView/CaseDetailsTabs.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/CaseDetailsTabs.js +55 -82
- package/lib/esm/components/CaseEditView/CaseOverview/CaseOwnerInfo.d.ts +0 -2
- package/lib/esm/components/CaseEditView/CaseOverview/CaseOwnerInfo.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/CaseOverview/CaseOwnerInfo.js +3 -3
- package/lib/esm/components/CaseEditView/CaseOverview/CaseStatus.d.ts +2 -1
- package/lib/esm/components/CaseEditView/CaseOverview/CaseStatus.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/CaseOverview/CaseStatus.js +6 -8
- package/lib/esm/components/CaseEditView/CaseOverview/index.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/CaseOverview/index.js +45 -76
- package/lib/esm/components/CaseEditView/CaseSolutions/CaseSolutions.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/CaseSolutions/CaseSolutions.js +109 -203
- package/lib/esm/components/CaseEditView/CaseSolutions/CaseSolutionsItem.d.ts +1 -0
- package/lib/esm/components/CaseEditView/CaseSolutions/CaseSolutionsItem.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/CaseSolutions/CaseSolutionsItem.js +5 -5
- package/lib/esm/components/CaseEditView/ConfirmationModals/ReopenCaseModal.d.ts +3 -1
- package/lib/esm/components/CaseEditView/ConfirmationModals/ReopenCaseModal.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/ConfirmationModals/ReopenCaseModal.js +9 -5
- package/lib/esm/components/CaseEditView/RequestRemoteSession/ESSRemoteSessionModal.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/RequestRemoteSession/ESSRemoteSessionModal.js +17 -18
- package/lib/esm/components/CaseEditView/RequestRemoteSession/NewEssTermsModal.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/RequestRemoteSession/NewEssTermsModal.js +47 -51
- package/lib/esm/components/CaseEditView/RequestRemoteSession/RemoteSessionAgreementModal.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/RequestRemoteSession/RemoteSessionAgreementModal.js +44 -49
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/CaseContactPhoneNumber.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/CaseContactPhoneNumber.js +45 -51
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/CaseDetailsManagement.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/CaseDetailsManagement.js +10 -21
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/CaseHostname.js +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/CaseInformation.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/CaseInformation.js +2 -0
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/CaseInternalStatus.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/CaseInternalStatus.js +2 -3
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/CaseOpenshiftClusterId/CaseOpenshiftClusterId.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/CaseOpenshiftClusterId/CaseOpenshiftClusterId.js +57 -132
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/CaseReferenceNumber.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/CaseReferenceNumber.js +4 -9
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/ProductVersion.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/ProductVersion.js +58 -93
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/Summary.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDetails/Summary.js +9 -16
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/AsaCommentFeedbackModal.d.ts +25 -0
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/AsaCommentFeedbackModal.d.ts.map +1 -0
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/AsaCommentFeedbackModal.js +91 -0
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/CaseAttachment.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/CaseAttachment.js +33 -78
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/CaseComments.d.ts +4 -2
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/CaseComments.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/CaseComments.js +153 -122
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/CaseDiscussion.d.ts +2 -4
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/CaseDiscussion.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/CaseDiscussion.js +137 -74
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/CommentSearch.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/CommentSearch.js +9 -22
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/DiscussionItemLink.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/DiscussionItemLink.js +2 -9
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/JumpAndCopyLink.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/JumpAndCopyLink.js +1 -8
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/PostComment/useMarkdownFileUploader.d.ts +2 -2
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/PostComment/useMarkdownFileUploader.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/PostComment/useMarkdownFileUploader.js +7 -18
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/PostComment.d.ts +3 -9
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/PostComment.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/PostComment.js +263 -211
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/VerifyCaseStatusModal/VerifyCaseStatusModal.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/VerifyCaseStatusModal/VerifyCaseStatusModal.js +4 -6
- package/lib/esm/components/CaseEditView/Tabs/CaseHistory/CaseHistory.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseHistory/CaseHistory.js +1 -3
- package/lib/esm/components/CaseEditView/Tabs/CaseHistory/Timeline.css +4 -4
- package/lib/esm/components/CaseEditView/Tabs/CaseHistory/Timeline.d.ts +3 -35
- package/lib/esm/components/CaseEditView/Tabs/CaseHistory/Timeline.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseHistory/Timeline.js +224 -63
- package/lib/esm/components/CaseEditView/Tabs/CasePrivateNotes/CasePrivateNotes.d.ts +5 -4
- package/lib/esm/components/CaseEditView/Tabs/CasePrivateNotes/CasePrivateNotes.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CasePrivateNotes/CasePrivateNotes.js +5 -18
- package/lib/esm/components/CaseEditView/Tabs/CaseSummary/CaseSummary.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseSummary/CaseSummary.js +2 -7
- package/lib/esm/components/CaseEditView/Tabs/RMEEscalations/RMEEscalationList.d.ts.map +1 -1
- package/lib/esm/components/CaseEditView/Tabs/RMEEscalations/RMEEscalationList.js +52 -38
- package/lib/esm/components/CaseInformation/CaseGroup.d.ts.map +1 -1
- package/lib/esm/components/CaseInformation/CaseGroup.js +57 -123
- package/lib/esm/components/CaseInformation/CaseInformation.d.ts.map +1 -1
- package/lib/esm/components/CaseInformation/CaseInformation.js +9 -10
- package/lib/esm/components/CaseInformation/ContactPhoneNumber.d.ts.map +1 -1
- package/lib/esm/components/CaseInformation/ContactPhoneNumber.js +30 -107
- package/lib/esm/components/CaseInformation/Description.js +1 -1
- package/lib/esm/components/CaseInformation/FileDiag.js +7 -10
- package/lib/esm/components/CaseInformation/Fts.d.ts.map +1 -1
- package/lib/esm/components/CaseInformation/Fts.js +1 -2
- package/lib/esm/components/CaseInformation/SupportLevel.d.ts.map +1 -1
- package/lib/esm/components/CaseInformation/SupportLevel.js +55 -36
- package/lib/esm/components/CaseManagement/CaseLanguageSelector.js +2 -2
- package/lib/esm/components/CaseManagement/CaseManagement.d.ts.map +1 -1
- package/lib/esm/components/CaseManagement/CaseManagement.js +7 -8
- package/lib/esm/components/CaseManagement/Cep.d.ts.map +1 -1
- package/lib/esm/components/CaseManagement/Cep.js +9 -11
- package/lib/esm/components/CaseManagement/NoClusterIDReasonSelector.d.ts +1 -2
- package/lib/esm/components/CaseManagement/NoClusterIDReasonSelector.d.ts.map +1 -1
- package/lib/esm/components/CaseManagement/NoClusterIDReasonSelector.js +3 -22
- package/lib/esm/components/CaseManagement/OpenShiftClusterId.d.ts.map +1 -1
- package/lib/esm/components/CaseManagement/OpenShiftClusterId.js +7 -9
- package/lib/esm/components/CaseManagement/OpenshiftDropdownV4.d.ts.map +1 -1
- package/lib/esm/components/CaseManagement/OpenshiftDropdownV4.js +18 -13
- package/lib/esm/components/CaseManagement/SendNotifications/NonOrgCaseNotifyeesSelector.d.ts.map +1 -1
- package/lib/esm/components/CaseManagement/SendNotifications/NonOrgCaseNotifyeesSelector.js +40 -34
- package/lib/esm/components/ConfirmationModals/NoAttachmentSelectedModal.d.ts.map +1 -1
- package/lib/esm/components/ConfirmationModals/NoAttachmentSelectedModal.js +3 -8
- package/lib/esm/components/EditDescription/EditDescription.js +1 -1
- package/lib/esm/components/IdeaInformation/IdeaInformation.d.ts.map +1 -1
- package/lib/esm/components/IdeaInformation/IdeaInformation.js +18 -16
- package/lib/esm/components/OpenCase/SupportTypeSelectorPage.d.ts.map +1 -1
- package/lib/esm/components/OpenCase/SupportTypeSelectorPage.js +2 -4
- package/lib/esm/components/ProductSelector/AllProductsSelector.d.ts +1 -0
- package/lib/esm/components/ProductSelector/AllProductsSelector.d.ts.map +1 -1
- package/lib/esm/components/ProductSelector/AllProductsSelector.js +15 -3
- package/lib/esm/components/ProductSelector/NewProductDropdownSelector.d.ts.map +1 -1
- package/lib/esm/components/ProductSelector/NewProductDropdownSelector.js +37 -13
- package/lib/esm/components/ProductSelector/NewProductVersionSelector.d.ts.map +1 -1
- package/lib/esm/components/ProductSelector/NewProductVersionSelector.js +50 -37
- package/lib/esm/components/ProductSelector/ProductSelector.d.ts.map +1 -1
- package/lib/esm/components/ProductSelector/ProductSelector.js +3 -1
- package/lib/esm/components/ProductSelector/ProductVersionDropdownSelector.d.ts.map +1 -1
- package/lib/esm/components/ProductSelector/ProductVersionDropdownSelector.js +1 -9
- package/lib/esm/components/Recommendations/AsideResults.d.ts.map +1 -1
- package/lib/esm/components/Recommendations/AsideResults.js +3 -4
- package/lib/esm/components/Recommendations/ClusterRecommendationToast.d.ts.map +1 -1
- package/lib/esm/components/Recommendations/ClusterRecommendationToast.js +4 -1
- package/lib/esm/components/Recommendations/ClusterRecommendations.d.ts.map +1 -1
- package/lib/esm/components/Recommendations/ClusterRecommendations.js +4 -1
- package/lib/esm/components/Recommendations/InsightsResults.js +3 -3
- package/lib/esm/components/Recommendations/Recommendations.js +2 -2
- package/lib/esm/components/RemoteRider/RemoteRiderAcceptanceModal.d.ts.map +1 -1
- package/lib/esm/components/RemoteRider/RemoteRiderAcceptanceModal.js +8 -10
- package/lib/esm/components/Review/Review.d.ts.map +1 -1
- package/lib/esm/components/Review/Review.js +16 -20
- package/lib/esm/components/SessionRestore/SessionRestore.d.ts.map +1 -1
- package/lib/esm/components/SessionRestore/SessionRestore.js +1 -3
- package/lib/esm/components/SubmitCase/SubmitCase.d.ts.map +1 -1
- package/lib/esm/components/SubmitCase/SubmitCase.js +1 -1
- package/lib/esm/components/TroubleshootSection/TroubleshootSection.js +2 -2
- package/lib/esm/components/UpdateSeverityModal/UpdateSeverityModal.d.ts.map +1 -1
- package/lib/esm/components/UpdateSeverityModal/UpdateSeverityModal.js +62 -135
- package/lib/esm/components/shared/Constants.d.ts +0 -5
- package/lib/esm/components/shared/Constants.d.ts.map +1 -1
- package/lib/esm/components/shared/Constants.js +0 -5
- package/lib/esm/components/shared/fileUpload/FileLister.d.ts.map +1 -1
- package/lib/esm/components/shared/fileUpload/FileLister.js +3 -3
- package/lib/esm/components/shared/fileUpload/FileUpload.js +3 -2
- package/lib/esm/components/shared/fileUpload/FileUploader.d.ts.map +1 -1
- package/lib/esm/components/shared/fileUpload/FileUploader.js +1 -3
- package/lib/esm/components/shared/fileUpload/WidgetFileUploader.d.ts.map +1 -1
- package/lib/esm/components/shared/fileUpload/WidgetFileUploader.js +2 -2
- package/lib/esm/components/shared/fileUpload/fileSelectors/FileSelectorButton.d.ts +1 -1
- package/lib/esm/components/shared/fileUpload/fileSelectors/FileSelectorButton.d.ts.map +1 -1
- package/lib/esm/components/shared/fileUpload/reducer/AttachmentHelper.d.ts +5 -21
- package/lib/esm/components/shared/fileUpload/reducer/AttachmentHelper.d.ts.map +1 -1
- package/lib/esm/components/shared/fileUpload/reducer/AttachmentHelper.js +34 -210
- package/lib/esm/components/shared/fileUpload/reducer/AttachmentReducer.d.ts +1 -5
- package/lib/esm/components/shared/fileUpload/reducer/AttachmentReducer.d.ts.map +1 -1
- package/lib/esm/components/shared/fileUpload/reducer/AttachmentReducer.js +1 -36
- package/lib/esm/components/shared/fileUpload/types/index.d.ts +1 -4
- package/lib/esm/components/shared/fileUpload/types/index.d.ts.map +1 -1
- package/lib/esm/components/shared/fileUpload/useFileUploader.d.ts +2 -2
- package/lib/esm/components/shared/fileUpload/useFileUploader.d.ts.map +1 -1
- package/lib/esm/components/shared/fileUpload/useFileUploader.js +47 -116
- package/lib/esm/components/shared/useIsSectionValid.d.ts.map +1 -1
- package/lib/esm/components/shared/useIsSectionValid.js +57 -22
- package/lib/esm/components/shared/usePostComment.d.ts.map +1 -1
- package/lib/esm/components/shared/usePostComment.js +28 -16
- package/lib/esm/components/shared/utils.d.ts +0 -1
- package/lib/esm/components/shared/utils.d.ts.map +1 -1
- package/lib/esm/components/shared/utils.js +3 -9
- package/lib/esm/components/wizardLayout/GlobalTroubleshootEffects.d.ts.map +1 -1
- package/lib/esm/components/wizardLayout/GlobalTroubleshootEffects.js +38 -160
- package/lib/esm/components/wizardLayout/WizardAside.d.ts.map +1 -1
- package/lib/esm/components/wizardLayout/WizardAside.js +4 -2
- package/lib/esm/components/wizardLayout/WizardLayout.d.ts.map +1 -1
- package/lib/esm/components/wizardLayout/WizardLayout.js +12 -11
- package/lib/esm/components/wizardLayout/WizardNavigation.d.ts.map +1 -1
- package/lib/esm/components/wizardLayout/WizardNavigation.js +10 -11
- package/lib/esm/constants/caseDetailsConstants.d.ts +0 -5
- package/lib/esm/constants/caseDetailsConstants.d.ts.map +1 -1
- package/lib/esm/constants/caseDetailsConstants.js +0 -5
- package/lib/esm/context/CaseContext.d.ts.map +1 -1
- package/lib/esm/css/case.css +202 -60
- package/lib/esm/hooks/useCaseUpdateErrorMessage.d.ts +1 -1
- package/lib/esm/hooks/useCaseUpdateErrorMessage.d.ts.map +1 -1
- package/lib/esm/hooks/useCaseUpdateErrorMessage.js +11 -21
- package/lib/esm/hooks/useResetCaseCreate.d.ts.map +1 -1
- package/lib/esm/hooks/useResetCaseCreate.js +11 -18
- package/lib/esm/hooks/useS3Upload.d.ts +4 -5
- package/lib/esm/hooks/useS3Upload.d.ts.map +1 -1
- package/lib/esm/hooks/useS3Upload.js +30 -28
- package/lib/esm/i18n/template-de.d.ts +2 -2
- package/lib/esm/i18n/template-de.js +2 -2
- package/lib/esm/i18n/template-es.d.ts +2 -2
- package/lib/esm/i18n/template-es.js +2 -2
- package/lib/esm/i18n/template-fr.d.ts +2 -2
- package/lib/esm/i18n/template-fr.js +2 -2
- package/lib/esm/i18n/template-it.d.ts +2 -2
- package/lib/esm/i18n/template-it.js +2 -2
- package/lib/esm/i18n/template-jp.d.ts +2 -2
- package/lib/esm/i18n/template-jp.js +2 -2
- package/lib/esm/i18n/template-ko.d.ts +2 -2
- package/lib/esm/i18n/template-ko.js +2 -2
- package/lib/esm/i18n/template-pt.d.ts +2 -2
- package/lib/esm/i18n/template-pt.js +2 -2
- package/lib/esm/i18n/template-ru.d.ts +2 -2
- package/lib/esm/i18n/template-ru.js +2 -2
- package/lib/esm/i18n/template-zh.d.ts +2 -2
- package/lib/esm/i18n/template-zh.js +2 -2
- package/lib/esm/index.js +0 -1
- package/lib/esm/models/cache.d.ts +2 -0
- package/lib/esm/models/cache.d.ts.map +1 -1
- package/lib/esm/reducers/CaseConstNTypes.d.ts +9 -121
- package/lib/esm/reducers/CaseConstNTypes.d.ts.map +1 -1
- package/lib/esm/reducers/CaseConstNTypes.js +7 -30
- package/lib/esm/reducers/CaseDetailsPageReducer.d.ts +5 -7
- package/lib/esm/reducers/CaseDetailsPageReducer.d.ts.map +1 -1
- package/lib/esm/reducers/CaseDetailsPageReducer.js +26 -58
- package/lib/esm/reducers/CaseDiscussionTabReducer.d.ts +12 -11
- package/lib/esm/reducers/CaseDiscussionTabReducer.d.ts.map +1 -1
- package/lib/esm/reducers/CaseDiscussionTabReducer.js +70 -63
- package/lib/esm/reducers/CaseHelpers.d.ts +2 -3
- package/lib/esm/reducers/CaseHelpers.d.ts.map +1 -1
- package/lib/esm/reducers/CaseHelpers.js +15 -98
- package/lib/esm/reducers/CaseOverviewReducer.d.ts +1 -3
- package/lib/esm/reducers/CaseOverviewReducer.d.ts.map +1 -1
- package/lib/esm/reducers/CaseOverviewReducer.js +5 -7
- package/lib/esm/reducers/CaseReducer.d.ts +11 -50
- package/lib/esm/reducers/CaseReducer.d.ts.map +1 -1
- package/lib/esm/reducers/CaseReducer.js +99 -270
- package/lib/esm/reducers/RecommendationsReducer.d.ts.map +1 -1
- package/lib/esm/reducers/RecommendationsReducer.js +18 -15
- package/lib/esm/scss/_main.scss +0 -9
- package/lib/esm/utils/caseOpenshiftClusterIdUtils.d.ts +2 -1
- package/lib/esm/utils/caseOpenshiftClusterIdUtils.d.ts.map +1 -1
- package/lib/esm/utils/caseOpenshiftClusterIdUtils.js +4 -4
- package/package.json +8 -9
- package/lib/esm/components/CaseEditView/ArchivedCaseBanner.d.ts +0 -7
- package/lib/esm/components/CaseEditView/ArchivedCaseBanner.d.ts.map +0 -1
- package/lib/esm/components/CaseEditView/ArchivedCaseBanner.js +0 -17
- package/lib/esm/components/CaseEditView/RequestRemoteSession/remoteSessionUtils.d.ts +0 -4
- package/lib/esm/components/CaseEditView/RequestRemoteSession/remoteSessionUtils.d.ts.map +0 -1
- package/lib/esm/components/CaseEditView/RequestRemoteSession/remoteSessionUtils.js +0 -23
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/PostComment/useAttachmentUploadCompletion.d.ts +0 -29
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/PostComment/useAttachmentUploadCompletion.d.ts.map +0 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/PostComment/useAttachmentUploadCompletion.js +0 -29
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/PostComment/useCommentDrafts.d.ts +0 -17
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/PostComment/useCommentDrafts.d.ts.map +0 -1
- package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/PostComment/useCommentDrafts.js +0 -60
- package/lib/esm/components/CaseInformation/CaseLabels.d.ts +0 -3
- package/lib/esm/components/CaseInformation/CaseLabels.d.ts.map +0 -1
- package/lib/esm/components/CaseInformation/CaseLabels.js +0 -103
- package/lib/esm/components/CaseManagement/CaseLabelsCreate.d.ts +0 -4
- package/lib/esm/components/CaseManagement/CaseLabelsCreate.d.ts.map +0 -1
- package/lib/esm/components/CaseManagement/CaseLabelsCreate.js +0 -109
- package/lib/esm/components/ProductSelector/ProductNotEntitledWarning.d.ts +0 -3
- package/lib/esm/components/ProductSelector/ProductNotEntitledWarning.d.ts.map +0 -1
- package/lib/esm/components/ProductSelector/ProductNotEntitledWarning.js +0 -9
- package/lib/esm/graphql/index.d.ts +0 -4
- package/lib/esm/graphql/index.d.ts.map +0 -1
- package/lib/esm/graphql/index.js +0 -3
- package/lib/esm/graphql/mutations/createRMECaseEscalation.d.ts +0 -2
- package/lib/esm/graphql/mutations/createRMECaseEscalation.d.ts.map +0 -1
- package/lib/esm/graphql/mutations/createRMECaseEscalation.js +0 -24
- package/lib/esm/graphql/mutations/index.d.ts +0 -2
- package/lib/esm/graphql/mutations/index.d.ts.map +0 -1
- package/lib/esm/graphql/mutations/index.js +0 -1
- package/lib/esm/graphql/queries/getEscalationDetails.d.ts +0 -2
- package/lib/esm/graphql/queries/getEscalationDetails.d.ts.map +0 -1
- package/lib/esm/graphql/queries/getEscalationDetails.js +0 -31
- package/lib/esm/graphql/queries/getParentId.d.ts +0 -2
- package/lib/esm/graphql/queries/getParentId.d.ts.map +0 -1
- package/lib/esm/graphql/queries/getParentId.js +0 -16
- package/lib/esm/graphql/queries/index.d.ts +0 -3
- package/lib/esm/graphql/queries/index.d.ts.map +0 -1
- package/lib/esm/graphql/queries/index.js +0 -2
- package/lib/esm/graphql/schemas/escalation.d.ts +0 -88
- package/lib/esm/graphql/schemas/escalation.d.ts.map +0 -1
- package/lib/esm/graphql/schemas/escalation.js +0 -1
- package/lib/esm/graphql/schemas/index.d.ts +0 -2
- package/lib/esm/graphql/schemas/index.d.ts.map +0 -1
- package/lib/esm/graphql/schemas/index.js +0 -1
- package/lib/esm/hooks/useCaseComments/caseCommentsQuery.d.ts +0 -4
- package/lib/esm/hooks/useCaseComments/caseCommentsQuery.d.ts.map +0 -1
- package/lib/esm/hooks/useCaseComments/caseCommentsQuery.js +0 -52
- package/lib/esm/hooks/useCaseComments/index.d.ts +0 -7
- package/lib/esm/hooks/useCaseComments/index.d.ts.map +0 -1
- package/lib/esm/hooks/useCaseComments/index.js +0 -5
- package/lib/esm/hooks/useCaseComments/mapCaseComment.d.ts +0 -25
- package/lib/esm/hooks/useCaseComments/mapCaseComment.d.ts.map +0 -1
- package/lib/esm/hooks/useCaseComments/mapCaseComment.js +0 -75
- package/lib/esm/hooks/useCaseComments/types.d.ts +0 -85
- package/lib/esm/hooks/useCaseComments/types.d.ts.map +0 -1
- package/lib/esm/hooks/useCaseComments/types.js +0 -1
- package/lib/esm/hooks/useCaseComments/useCaseComments.d.ts +0 -17
- package/lib/esm/hooks/useCaseComments/useCaseComments.d.ts.map +0 -1
- package/lib/esm/hooks/useCaseComments/useCaseComments.js +0 -38
- package/lib/esm/hooks/useCaseComments/useCreateCaseComment.d.ts +0 -19
- package/lib/esm/hooks/useCaseComments/useCreateCaseComment.d.ts.map +0 -1
- package/lib/esm/hooks/useCaseComments/useCreateCaseComment.js +0 -33
- package/lib/esm/hooks/useCaseHistory.d.ts +0 -26
- package/lib/esm/hooks/useCaseHistory.d.ts.map +0 -1
- package/lib/esm/hooks/useCaseHistory.js +0 -98
- package/lib/esm/hooks/useCaseLabelLinkMutations.d.ts +0 -21
- package/lib/esm/hooks/useCaseLabelLinkMutations.d.ts.map +0 -1
- package/lib/esm/hooks/useCaseLabelLinkMutations.js +0 -84
- package/lib/esm/models/caseHistory.d.ts +0 -80
- package/lib/esm/models/caseHistory.d.ts.map +0 -1
- package/lib/esm/models/caseHistory.js +0 -1
- package/lib/esm/utils/TimelineUtils.d.ts +0 -41
- package/lib/esm/utils/TimelineUtils.d.ts.map +0 -1
- package/lib/esm/utils/TimelineUtils.js +0 -135
- package/lib/esm/utils/caseHistoryUtils.d.ts +0 -66
- package/lib/esm/utils/caseHistoryUtils.d.ts.map +0 -1
- package/lib/esm/utils/caseHistoryUtils.js +0 -165
|
@@ -1,15 +1,21 @@
|
|
|
1
|
-
import { Button, MenuToggle, Select, SelectList, SelectOption, Spinner, TextInputGroup, TextInputGroupMain, TextInputGroupUtilities, } from '@patternfly/react-core';
|
|
1
|
+
import { Button, Divider, MenuToggle, Select, SelectGroup, SelectList, SelectOption, Spinner, TextInputGroup, TextInputGroupMain, TextInputGroupUtilities, } from '@patternfly/react-core';
|
|
2
2
|
import TimesIcon from '@patternfly/react-icons/dist/js/icons/times-icon';
|
|
3
3
|
import { useSelectKeyboardNavigator } from '@rh-support/components';
|
|
4
|
+
import { GlobalMetadataStateContext } from '@rh-support/react-context';
|
|
4
5
|
import isEmpty from 'lodash/isEmpty';
|
|
5
6
|
import isEqual from 'lodash/isEqual';
|
|
6
|
-
import React, { useEffect, useRef, useState } from 'react';
|
|
7
|
-
import { useTranslation } from 'react-i18next';
|
|
7
|
+
import React, { useContext, useEffect, useRef, useState } from 'react';
|
|
8
|
+
import { Trans, useTranslation } from 'react-i18next';
|
|
8
9
|
import { useCaseSelector } from '../../context/CaseContext';
|
|
10
|
+
const isProductSupportedForCustomer = (productName, productResults) => {
|
|
11
|
+
const foundItem = productResults.filter((item) => item.name === productName)[0];
|
|
12
|
+
return foundItem ? foundItem.supportedForCustomer : false;
|
|
13
|
+
};
|
|
9
14
|
export const NewProductDropdownSelector = (props) => {
|
|
10
15
|
const { t } = useTranslation();
|
|
11
16
|
const [isOpen, setIsOpen] = useState(false);
|
|
12
17
|
const [showValidationLocal, setShowValidationLocal] = useState(props.isNextBtnClickedToShowValidationError);
|
|
18
|
+
const [isSelectedProductSupportedForCustomer, setIsSelectedProductSupportedForCustomer] = useState(true);
|
|
13
19
|
const [filteredProducts, setFilteredProducts] = useState(props.products);
|
|
14
20
|
const [shouldFilter, setShouldFilter] = useState(false);
|
|
15
21
|
const textInputRef = useRef();
|
|
@@ -17,6 +23,7 @@ export const NewProductDropdownSelector = (props) => {
|
|
|
17
23
|
product: state.caseDetails.product,
|
|
18
24
|
}), isEqual);
|
|
19
25
|
const [inputValue, setInputValue] = useState('');
|
|
26
|
+
const { globalMetadataState: { allProducts }, } = useContext(GlobalMetadataStateContext);
|
|
20
27
|
useEffect(() => {
|
|
21
28
|
setShowValidationLocal(props.isNextBtnClickedToShowValidationError);
|
|
22
29
|
}, [props.isNextBtnClickedToShowValidationError]);
|
|
@@ -26,15 +33,22 @@ export const NewProductDropdownSelector = (props) => {
|
|
|
26
33
|
}
|
|
27
34
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
28
35
|
}, [product]);
|
|
36
|
+
// Update filtered products whenever input changes
|
|
29
37
|
useEffect(() => {
|
|
38
|
+
const productsToFilter = props.isCaseCreate ? props.products : allProducts.data.productsResult;
|
|
30
39
|
if (!isEmpty(inputValue === null || inputValue === void 0 ? void 0 : inputValue.trim())) {
|
|
31
|
-
const filtered =
|
|
40
|
+
const filtered = productsToFilter.filter((p) => { var _a; return (_a = p.name) === null || _a === void 0 ? void 0 : _a.toLowerCase().includes(inputValue.toLowerCase()); });
|
|
32
41
|
setFilteredProducts(filtered);
|
|
33
42
|
}
|
|
34
43
|
else {
|
|
35
|
-
setFilteredProducts(
|
|
44
|
+
setFilteredProducts(productsToFilter);
|
|
36
45
|
}
|
|
37
|
-
}, [inputValue, props.products]);
|
|
46
|
+
}, [inputValue, props.products, props.isCaseCreate, allProducts.data.productsResult]);
|
|
47
|
+
useEffect(() => {
|
|
48
|
+
product &&
|
|
49
|
+
props.isOnSummaryPage &&
|
|
50
|
+
setIsSelectedProductSupportedForCustomer(isProductSupportedForCustomer(product, allProducts.data.productsResult));
|
|
51
|
+
}, [allProducts.data.productsResult, product, props.isOnSummaryPage]);
|
|
38
52
|
const onToggleClick = () => {
|
|
39
53
|
var _a;
|
|
40
54
|
setIsOpen(!isOpen);
|
|
@@ -69,12 +83,14 @@ export const NewProductDropdownSelector = (props) => {
|
|
|
69
83
|
setIsOpen(false);
|
|
70
84
|
},
|
|
71
85
|
});
|
|
72
|
-
const
|
|
73
|
-
const productsToShow = shouldFilter ? filteredProducts :
|
|
74
|
-
return productsToShow.length > 0 ? (React.createElement(React.Fragment, null,
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
86
|
+
const createProductGroup = (products, label, type, shouldFilter = false) => {
|
|
87
|
+
const productsToShow = shouldFilter ? filteredProducts : products;
|
|
88
|
+
return productsToShow.length > 0 ? (React.createElement(React.Fragment, null,
|
|
89
|
+
!shouldFilter && (React.createElement(SelectGroup, { label: label, key: type, value: '', className: "product-selector-group", children: '' })),
|
|
90
|
+
productsToShow.map((prod, index) => {
|
|
91
|
+
var _a;
|
|
92
|
+
return (React.createElement(SelectOption, { key: `${type}-${index}`, value: prod, isFocused: focusedItemIndex === index, className: "pf-v6-c-select__menu-wrapper", "data-tracking-id": `${(_a = prod.name) === null || _a === void 0 ? void 0 : _a.replace(/\s+/g, '')}-${type}-dropdown`, isSelected: prod.name === product }, prod.name));
|
|
93
|
+
}))) : (React.createElement(SelectOption, { key: '', value: '', className: "pf-v6-c-select__menu-wrapper", isDisabled: true }, "No Results Found"));
|
|
78
94
|
};
|
|
79
95
|
const toggle = (toggleRef) => (React.createElement(MenuToggle, { ref: toggleRef, variant: "typeahead", onClick: onToggleClick, isExpanded: isOpen, isFullWidth: true, isDisabled: props.isLoading, status: isEmpty(inputValue) && showValidationLocal ? 'danger' : undefined },
|
|
80
96
|
React.createElement(TextInputGroup, { isPlain: true },
|
|
@@ -82,8 +98,16 @@ export const NewProductDropdownSelector = (props) => {
|
|
|
82
98
|
props.isLoading ? (React.createElement(TextInputGroupUtilities, null,
|
|
83
99
|
React.createElement(Spinner, { size: "md" }))) : (React.createElement(TextInputGroupUtilities, Object.assign({}, (!inputValue ? { style: { display: 'none' } } : {})),
|
|
84
100
|
React.createElement(Button, { icon: React.createElement(TimesIcon, { "aria-hidden": true }), variant: "plain", onClick: onClear, "aria-label": "Clear input value" }))))));
|
|
101
|
+
const topProducts = allProducts.data.topProducts.filter((p) => p.isEntitledProduct).slice(0, 3);
|
|
85
102
|
return (React.createElement("div", null,
|
|
86
103
|
React.createElement(Select, { id: "product-selector", isOpen: isOpen, onSelect: (e, selection) => onSelect(selection), onOpenChange: (isOpen) => setIsOpen(isOpen), toggle: toggle, selected: product, shouldFocusFirstItemOnOpen: false, isScrollable: true, "data-tracking-id": "get-support-product-dropdown-selector" },
|
|
87
|
-
React.createElement(SelectList, { id: "product-selector-listbox" },
|
|
104
|
+
React.createElement(SelectList, { id: "product-selector-listbox" },
|
|
105
|
+
!shouldFilter && createProductGroup(topProducts, t('Top products'), 'topProduct'),
|
|
106
|
+
!shouldFilter && React.createElement(Divider, null),
|
|
107
|
+
createProductGroup(props.isCaseCreate ? props.products : allProducts.data.productsResult, t('All products'), 'product', shouldFilter))),
|
|
108
|
+
!props.isLoading && !isSelectedProductSupportedForCustomer && (React.createElement("div", { className: "pf-v6-u-ml-xs pf-v6-u-mt-sm form-instructions" },
|
|
109
|
+
React.createElement(Trans, null, "Red Hat must confirm your subscription status before providing support."),
|
|
110
|
+
React.createElement("br", null),
|
|
111
|
+
React.createElement(Trans, null, "We'll contact you if we have any questions.")))));
|
|
88
112
|
};
|
|
89
113
|
export default NewProductDropdownSelector;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NewProductVersionSelector.d.ts","sourceRoot":"","sources":["../../../../src/components/ProductSelector/NewProductVersionSelector.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"NewProductVersionSelector.d.ts","sourceRoot":"","sources":["../../../../src/components/ProductSelector/NewProductVersionSelector.tsx"],"names":[],"mappings":"AAKA,OAAO,KAA0C,MAAM,OAAO,CAAC;AAM/D,UAAU,MAAM;IACZ,eAAe,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,IAAI,CAAC;IAC1C,qCAAqC,EAAE,OAAO,CAAC;CAClD;AAED,eAAO,MAAM,yBAAyB,GAAI,OAAO,MAAM,sBAmItD,CAAC"}
|
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
import { useApolloClient } from '@apollo/client/react';
|
|
2
1
|
import { SingleSelectDropdown } from '@rh-support/components';
|
|
3
2
|
import { GlobalMetadataStateContext } from '@rh-support/react-context';
|
|
4
3
|
import { getUniqueSortedVersions } from '@rh-support/utils';
|
|
5
4
|
import isEmpty from 'lodash/isEmpty';
|
|
6
5
|
import isEqual from 'lodash/isEqual';
|
|
7
|
-
import React, { useContext, useEffect,
|
|
6
|
+
import React, { useContext, useEffect, useState } from 'react';
|
|
8
7
|
import { useTranslation } from 'react-i18next';
|
|
9
8
|
import { useCaseDispatch, useCaseSelector } from '../../context/CaseContext';
|
|
10
|
-
import { getVersionsDetails
|
|
9
|
+
import { getVersionsDetails } from '../../reducers/CaseReducer';
|
|
11
10
|
import { getProductObj } from '../shared/utils';
|
|
12
11
|
export const NewProductVersionSelector = (props) => {
|
|
13
12
|
const { t } = useTranslation();
|
|
13
|
+
const [selectVersionOptions, setSelectVersionOptions] = useState([]);
|
|
14
14
|
const [showValidationLocal, setShowValidationLocal] = useState(props.isNextBtnClickedToShowValidationError);
|
|
15
|
+
const [isSEProductApiIsDown, setIsSEProductApiIsDown] = useState(false);
|
|
15
16
|
const caseDispatch = useCaseDispatch();
|
|
16
|
-
const apolloClient = useApolloClient();
|
|
17
17
|
const { versionsDetails, product, version } = useCaseSelector((state) => ({
|
|
18
18
|
product: state.caseDetails.product,
|
|
19
19
|
version: state.caseDetails.version,
|
|
@@ -24,63 +24,76 @@ export const NewProductVersionSelector = (props) => {
|
|
|
24
24
|
setShowValidationLocal(props.isNextBtnClickedToShowValidationError);
|
|
25
25
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
26
26
|
}, [props.isNextBtnClickedToShowValidationError]);
|
|
27
|
+
// when user selects a product, we need to fetch versions
|
|
27
28
|
useEffect(() => {
|
|
28
29
|
if (isEmpty(product))
|
|
29
30
|
return;
|
|
30
31
|
const productObj = getProductObj(allProducts.data.productsResult, product);
|
|
31
|
-
if (productObj.
|
|
32
|
-
|
|
32
|
+
if (productObj.versions) {
|
|
33
|
+
const productVersions = productObj.hasComponentsInsteadOfVersions
|
|
34
|
+
? productObj.versions.sort()
|
|
35
|
+
: productObj.versions;
|
|
36
|
+
// if versions array has one value set that value as selected
|
|
37
|
+
if (productVersions.length === 1) {
|
|
38
|
+
props.onVersionChange(productVersions[0]);
|
|
39
|
+
}
|
|
40
|
+
setSelectVersionOptions(productObj.versions);
|
|
41
|
+
}
|
|
42
|
+
else {
|
|
43
|
+
setIsSEProductApiIsDown(true);
|
|
33
44
|
}
|
|
45
|
+
const getVersions = () => getVersionsDetails(caseDispatch, product);
|
|
46
|
+
// call sfdc version api version flags that is used in severity and submit components
|
|
47
|
+
getVersions();
|
|
34
48
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
35
|
-
}, [product
|
|
49
|
+
}, [product]);
|
|
36
50
|
useEffect(() => {
|
|
37
|
-
|
|
38
|
-
if (versionsDetails.isFetching || !((_a = versionsDetails.data) === null || _a === void 0 ? void 0 : _a.length))
|
|
39
|
-
return;
|
|
40
|
-
if (versionsDetails.data.length === 1) {
|
|
41
|
-
props.onVersionChange(versionsDetails.data[0].name);
|
|
42
|
-
setCaseState(caseDispatch, { selectedVersionId: versionsDetails.data[0].id });
|
|
51
|
+
if (!product)
|
|
43
52
|
return;
|
|
53
|
+
const productObj = getProductObj(allProducts.data.productsResult, product);
|
|
54
|
+
if (productObj.versions) {
|
|
55
|
+
const productVersions = productObj.hasComponentsInsteadOfVersions
|
|
56
|
+
? productObj.versions.sort()
|
|
57
|
+
: productObj.versions;
|
|
58
|
+
setSelectVersionOptions(productVersions);
|
|
44
59
|
}
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
if (versionObj === null || versionObj === void 0 ? void 0 : versionObj.id) {
|
|
48
|
-
setCaseState(caseDispatch, { selectedVersionId: versionObj.id });
|
|
49
|
-
}
|
|
60
|
+
else {
|
|
61
|
+
setIsSEProductApiIsDown(true);
|
|
50
62
|
}
|
|
51
63
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
52
|
-
}, [
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
if (!
|
|
56
|
-
return
|
|
57
|
-
const
|
|
58
|
-
|
|
59
|
-
if (
|
|
60
|
-
|
|
64
|
+
}, [version]);
|
|
65
|
+
// observe when fetched versions are available
|
|
66
|
+
useEffect(() => {
|
|
67
|
+
if (!isSEProductApiIsDown)
|
|
68
|
+
return;
|
|
69
|
+
const fetchedVersions = versionsDetails.data.map(({ name }) => name);
|
|
70
|
+
// if versions array has one value set that value as selected
|
|
71
|
+
if (fetchedVersions.length === 1) {
|
|
72
|
+
props.onVersionChange(fetchedVersions[0]);
|
|
61
73
|
}
|
|
62
|
-
const
|
|
63
|
-
const
|
|
64
|
-
|
|
65
|
-
|
|
74
|
+
const productObj = getProductObj(allProducts.data.productsResult, product);
|
|
75
|
+
const sfdcVersions = getUniqueSortedVersions(fetchedVersions);
|
|
76
|
+
const productVersions = (productObj === null || productObj === void 0 ? void 0 : productObj.hasComponentsInsteadOfVersions) ? sfdcVersions.sort() : sfdcVersions;
|
|
77
|
+
setSelectVersionOptions(productVersions);
|
|
78
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
79
|
+
}, [versionsDetails.data, isSEProductApiIsDown]);
|
|
66
80
|
const onSelect = (selectedOption) => {
|
|
67
81
|
const selection = selectedOption.value;
|
|
68
82
|
if (isEqual(selection, version)) {
|
|
69
|
-
props.onVersionChange('');
|
|
70
|
-
setCaseState(caseDispatch, { selectedVersionId: undefined });
|
|
83
|
+
props.onVersionChange(''); // To unselect a version when user clicks on the same selected product version
|
|
71
84
|
return;
|
|
72
85
|
}
|
|
73
86
|
props.onVersionChange(selection);
|
|
74
|
-
const versionObj = versionsDetails.data.find((v) => v.name === selection);
|
|
75
|
-
setCaseState(caseDispatch, { selectedVersionId: versionObj === null || versionObj === void 0 ? void 0 : versionObj.id });
|
|
76
87
|
};
|
|
88
|
+
// Create selected option for SingleSelectDropdown
|
|
77
89
|
const getSelectedOption = () => ({
|
|
78
90
|
label: version || '',
|
|
79
91
|
value: version || '',
|
|
80
92
|
});
|
|
81
|
-
|
|
93
|
+
// Create options array for SingleSelectDropdown
|
|
94
|
+
const getDropdownOptions = () => selectVersionOptions.map((versionOption) => ({
|
|
82
95
|
label: versionOption,
|
|
83
96
|
value: versionOption,
|
|
84
97
|
}));
|
|
85
|
-
return (React.createElement(SingleSelectDropdown, { onSelect: onSelect, selected: getSelectedOption(), options: getDropdownOptions(), placeholder: t('Select a version'), ariaLabel: t('Select a version'), isInvalid: isEmpty(version) && showValidationLocal, isDisabled: isEmpty(product) || allProducts.isFetching, dataTrackingId: "get-support-version-dropdown-selector", isLoading: versionsDetails.isFetching }));
|
|
98
|
+
return (React.createElement(SingleSelectDropdown, { onSelect: onSelect, selected: getSelectedOption(), options: getDropdownOptions(), placeholder: t('Select a version'), ariaLabel: t('Select a version'), isInvalid: isEmpty(version) && showValidationLocal, isDisabled: isEmpty(product) || allProducts.isFetching, dataTrackingId: "get-support-version-dropdown-selector", isLoading: isSEProductApiIsDown && versionsDetails.isFetching }));
|
|
86
99
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ProductSelector.d.ts","sourceRoot":"","sources":["../../../../src/components/ProductSelector/ProductSelector.tsx"],"names":[],"mappings":"AAMA,OAAO,KAAwC,MAAM,OAAO,CAAC;AAE7D,OAAO,EAAE,mBAAmB,EAAE,MAAM,kBAAkB,CAAC;
|
|
1
|
+
{"version":3,"file":"ProductSelector.d.ts","sourceRoot":"","sources":["../../../../src/components/ProductSelector/ProductSelector.tsx"],"names":[],"mappings":"AAMA,OAAO,KAAwC,MAAM,OAAO,CAAC;AAE7D,OAAO,EAAE,mBAAmB,EAAE,MAAM,kBAAkB,CAAC;AAOvD,OAAO,EAAE,eAAe,EAAE,MAAM,iCAAiC,CAAC;AAKlE,UAAU,MAAM;IACZ,UAAU,EAAE,mBAAmB,CAAC,eAAe,CAAC,CAAC;IACjD,uBAAuB,CAAC,EAAE,CAAC,KAAK,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,CAAC,KAAK,IAAI,CAAC;IACzE,gCAAgC,CAAC,EAAE,OAAO,CAAC;IAC3C,aAAa,CAAC,EAAE,KAAK,CAAC,gBAAgB,CAAC,cAAc,GAAG,IAAI,CAAC,CAAC;IAC9D,kBAAkB,CAAC,EAAE,OAAO,CAAC;IAC7B,oBAAoB,CAAC,EAAE,OAAO,CAAC;CAClC;AAED;;;;;;;GAOG;AACH,MAAM,CAAC,OAAO,UAAU,eAAe,CAAC,KAAK,EAAE,MAAM,qBAqGpD"}
|
|
@@ -7,6 +7,7 @@ import isEqual from 'lodash/isEqual';
|
|
|
7
7
|
import React, { useContext, useEffect, useRef } from 'react';
|
|
8
8
|
import { Trans, useTranslation } from 'react-i18next';
|
|
9
9
|
import { useCaseDispatch, useCaseSelector } from '../../context/CaseContext';
|
|
10
|
+
import { RouteContext } from '../../context/RouteContext';
|
|
10
11
|
import { useAB } from '../../hooks/useAB';
|
|
11
12
|
import { useFetchCVEData } from '../../hooks/useFetchCVEData';
|
|
12
13
|
import { setCaseState } from '../../reducers/CaseReducer';
|
|
@@ -30,6 +31,7 @@ export default function ProductSelector(props) {
|
|
|
30
31
|
product: state.caseDetails.product,
|
|
31
32
|
version: state.caseDetails.version,
|
|
32
33
|
}), isEqual);
|
|
34
|
+
const { routeState: { isCaseCreate }, } = useContext(RouteContext);
|
|
33
35
|
const caseDispatch = useCaseDispatch();
|
|
34
36
|
const cveModalEnabledConfig = getConfigField(pcmConfig.data, 'isCVEModalEnabled', PCM_CONFIG_FIELD_TYPE.STRING);
|
|
35
37
|
const isCVEModalEnabled = cveModalEnabledConfig === '1';
|
|
@@ -49,7 +51,7 @@ export default function ProductSelector(props) {
|
|
|
49
51
|
const productSelectorRef = useRef(null);
|
|
50
52
|
const rederProductSelect = (React.createElement("form", null,
|
|
51
53
|
(cveRecommendation === null || cveRecommendation === void 0 ? void 0 : cveRecommendation.length) !== 0 && isCVEModalEnabled && React.createElement(CveModal, null),
|
|
52
|
-
React.createElement(AllProductsSelector, { routeProps: props.routeProps, ref: productSelectorRef, isOnSummaryPage: true, isOnGetSupportPage: props === null || props === void 0 ? void 0 : props.isOnGetSupportPage, caseCreateExperience: props.caseCreateExperience })));
|
|
54
|
+
React.createElement(AllProductsSelector, { routeProps: props.routeProps, checkEntitledProduct: isCaseCreate ? true : false, ref: productSelectorRef, isOnSummaryPage: true, isOnGetSupportPage: props === null || props === void 0 ? void 0 : props.isOnGetSupportPage, caseCreateExperience: props.caseCreateExperience })));
|
|
53
55
|
return (React.createElement(React.Fragment, null,
|
|
54
56
|
React.createElement(AlertMessage, { variant: AlertType.DANGER, className: "pf-v6-u-mt-lg", title: t('There was an error loading products.'), show: allProducts.isError }),
|
|
55
57
|
rederProductSelect,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ProductVersionDropdownSelector.d.ts","sourceRoot":"","sources":["../../../../src/components/ProductSelector/ProductVersionDropdownSelector.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,wCAAwC,CAAC;AAEpE,OAAO,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;
|
|
1
|
+
{"version":3,"file":"ProductVersionDropdownSelector.d.ts","sourceRoot":"","sources":["../../../../src/components/ProductSelector/ProductVersionDropdownSelector.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,wCAAwC,CAAC;AAEpE,OAAO,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAC5D,OAAO,KAAiC,MAAM,OAAO,CAAC;AAOtD,UAAU,MAAO,SAAQ,gBAAgB;IACrC,QAAQ,EAAE,OAAO,CAAC,UAAU,CAAC,EAAE,CAAC;IAChC,eAAe,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,GAAG,CAAC;IAC1C,eAAe,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,GAAG,CAAC;IAC1C,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,UAAU,CAAC,EAAE,OAAO,CAAC;CACxB;AAOD,QAAA,MAAM,8BAA8B,wEAuDlC,CAAC;AAEH,OAAO,EAAE,8BAA8B,EAAE,CAAC"}
|
|
@@ -1,23 +1,15 @@
|
|
|
1
1
|
import { LoadingIndicator } from '@rh-support/components';
|
|
2
|
-
import isEmpty from 'lodash/isEmpty';
|
|
3
|
-
import isEqual from 'lodash/isEqual';
|
|
4
2
|
import React, { forwardRef, useContext } from 'react';
|
|
5
3
|
import { Trans } from 'react-i18next';
|
|
6
|
-
import { useCaseSelector } from '../../context/CaseContext';
|
|
7
4
|
import { RouteContext } from '../../context/RouteContext';
|
|
8
5
|
import { NewProductDropdownSelector } from './NewProductDropdownSelector';
|
|
9
6
|
import { NewProductVersionSelector } from './NewProductVersionSelector';
|
|
10
|
-
import { ProductNotEntitledWarning } from './ProductNotEntitledWarning';
|
|
11
7
|
const defaultProps = {
|
|
12
8
|
disabled: false,
|
|
13
9
|
htmlForId: '',
|
|
14
10
|
};
|
|
15
11
|
const ProductVersionDropdownSelector = forwardRef((props, ref) => {
|
|
16
12
|
const { routeState: { isCaseCreate, isNextBtnClickedToShowValidationError }, } = useContext(RouteContext);
|
|
17
|
-
const { isProductNotEntitled, product } = useCaseSelector((state) => ({
|
|
18
|
-
isProductNotEntitled: state.isProductNotEntitled,
|
|
19
|
-
product: state.caseDetails.product,
|
|
20
|
-
}), isEqual);
|
|
21
13
|
return (React.createElement(React.Fragment, null,
|
|
22
14
|
React.createElement("div", { className: "product-selector-wrapper" },
|
|
23
15
|
React.createElement("label", { htmlFor: "product-selector-dropdown-search", ref: ref },
|
|
@@ -29,7 +21,7 @@ const ProductVersionDropdownSelector = forwardRef((props, ref) => {
|
|
|
29
21
|
React.createElement(NewProductDropdownSelector, { products: props.products, onProductChange: props.onProductChange, isNextBtnClickedToShowValidationError: isNextBtnClickedToShowValidationError, isCaseCreate: isCaseCreate, isOnSummaryPage: props.isOnSummaryPage, isLoading: props.isLoading })),
|
|
30
22
|
props.isLoading && (React.createElement("div", { className: "pf-v6-u-flex-basis-auto" },
|
|
31
23
|
React.createElement(LoadingIndicator, { className: "pf-v6-u-ml-sm", isInline: true, show: props.isLoading, size: "sm" })))),
|
|
32
|
-
|
|
24
|
+
React.createElement(React.Fragment, null)),
|
|
33
25
|
React.createElement("div", { className: "version-selector-wrapper" },
|
|
34
26
|
React.createElement("label", { htmlFor: "version-selector-dropdown-toggle" },
|
|
35
27
|
React.createElement(Trans, null, "Version"),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AsideResults.d.ts","sourceRoot":"","sources":["../../../../src/components/Recommendations/AsideResults.tsx"],"names":[],"mappings":"AAmBA,OAAO,KAAwC,MAAM,OAAO,CAAC;AAE7D,OAAO,EAAE,mBAAmB,EAAE,MAAM,kBAAkB,CAAC;AAUvD,OAAO,EAAoB,eAAe,EAAsC,MAAM,iCAAiC,CAAC;AAWxH,UAAU,MAAM;IACZ,UAAU,EAAE,mBAAmB,CAAC,eAAe,CAAC,CAAC;IACjD,SAAS,CAAC,EAAE,MAAM,CAAC;CACtB;AAED,wBAAgB,YAAY,CAAC,KAAK,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"AsideResults.d.ts","sourceRoot":"","sources":["../../../../src/components/Recommendations/AsideResults.tsx"],"names":[],"mappings":"AAmBA,OAAO,KAAwC,MAAM,OAAO,CAAC;AAE7D,OAAO,EAAE,mBAAmB,EAAE,MAAM,kBAAkB,CAAC;AAUvD,OAAO,EAAoB,eAAe,EAAsC,MAAM,iCAAiC,CAAC;AAWxH,UAAU,MAAM;IACZ,UAAU,EAAE,mBAAmB,CAAC,eAAe,CAAC,CAAC;IACjD,SAAS,CAAC,EAAE,MAAM,CAAC;CACtB;AAED,wBAAgB,YAAY,CAAC,KAAK,EAAE,MAAM,qBA4MzC"}
|
|
@@ -49,7 +49,6 @@ export function AsideResults(props) {
|
|
|
49
49
|
const sessionRestoreDispatch = useContext(SessionRestoreDispatchContext);
|
|
50
50
|
const { routeState: { activeSection, isCaseCreate }, } = useContext(RouteContext);
|
|
51
51
|
const PAGE_SIZE = 5;
|
|
52
|
-
const FETCH_ROWS = 50;
|
|
53
52
|
const payload = JSON.stringify({
|
|
54
53
|
product: product,
|
|
55
54
|
version: version,
|
|
@@ -83,8 +82,8 @@ export function AsideResults(props) {
|
|
|
83
82
|
summary: getTrimmedCharacters(payload.summary, WATSONX_SUMMARY_LIMIT),
|
|
84
83
|
description: getTrimmedCharacters(payload.description, WATSONX_DESCRIPTION_LIMIT),
|
|
85
84
|
};
|
|
86
|
-
const response = yield search.getWatsonXRecommendationsForCase2(convertObjToEncodedQueryParams(Object.assign({ rerank: true }, getSolrParams(
|
|
87
|
-
const sideDocs = uniqueRecommendationDocs(replaceHighlightingData(response.response.docs, response.highlighting))
|
|
85
|
+
const response = yield search.getWatsonXRecommendationsForCase2(convertObjToEncodedQueryParams(Object.assign({ rerank: true }, getSolrParams(PAGE_SIZE, 129, queryFilters))), payloadData, controllerRef.current.signal);
|
|
86
|
+
const sideDocs = uniqueRecommendationDocs(replaceHighlightingData(response.response.docs, response.highlighting));
|
|
88
87
|
recommendationDispatch({
|
|
89
88
|
type: RecommendationsConstants.receiveSidebarRecommendation,
|
|
90
89
|
payload: { sideRecommendation: sideDocs, sideRecommendationError: false },
|
|
@@ -145,7 +144,7 @@ export function AsideResults(props) {
|
|
|
145
144
|
React.createElement(CardBody, null,
|
|
146
145
|
React.createElement("ul", { className: "list-flat" }, recommendationState.sideRecommendation.map((doc, index) => {
|
|
147
146
|
var _a, _b;
|
|
148
|
-
return (React.createElement("li", { className: `result${index !== 0 && 'pf-v6-u-mt-sm'}`, key: doc.
|
|
147
|
+
return (React.createElement("li", { className: `result${index !== 0 && 'pf-v6-u-mt-sm'}`, key: doc.uri },
|
|
149
148
|
React.createElement("header", { className: "result-header" },
|
|
150
149
|
React.createElement("a", { href: `${doc.view_uri}?${RouteUtils.getSEResourceQueryParams(activeSessionId, (_b = (_a = sessionResourceTracking[SessionResourceSource.RECOMMENDATIONS_ASIDE]) === null || _a === void 0 ? void 0 : _a.resourceOriginId) !== null && _b !== void 0 ? _b : '', SessionResourceSource.RECOMMENDATIONS_ASIDE)}`, className: "se-recommended ts-result-aside", "data-tracking-id": `se-recommended-sidebar-recommendations-${index}`, rel: "noopener noreferrer", target: "_blank", onClick: onResourceClick(doc, index), dangerouslySetInnerHTML: computeRecommendationTitle(doc) })),
|
|
151
150
|
React.createElement("p", { className: "result-body", dangerouslySetInnerHTML: computeRecommendationAbstract(doc, 150) })));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ClusterRecommendationToast.d.ts","sourceRoot":"","sources":["../../../../src/components/Recommendations/ClusterRecommendationToast.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ClusterRecommendationToast.d.ts","sourceRoot":"","sources":["../../../../src/components/Recommendations/ClusterRecommendationToast.tsx"],"names":[],"mappings":"AAIA,OAAc,EAAE,EAAE,EAAmC,MAAM,OAAO,CAAC;AAUnE,UAAU,MAAM;CAAG;AAEnB,QAAA,MAAM,0BAA0B,EAAE,EAAE,CAAC,MAAM,CAsD1C,CAAC;AAEF,eAAe,0BAA0B,CAAC"}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { Alert, AlertActionCloseButton, Button } from '@patternfly/react-core';
|
|
2
|
+
import { GlobalMetadataStateContext } from '@rh-support/react-context';
|
|
2
3
|
import isEmpty from 'lodash/isEmpty';
|
|
3
4
|
import isEqual from 'lodash/isEqual';
|
|
4
5
|
import React, { useContext, useEffect, useState } from 'react';
|
|
@@ -8,6 +9,7 @@ import { ClusterRecommendationsContext, ClusterRecommendationsDispatchContext, }
|
|
|
8
9
|
import { toggleClusterRecommendationModal } from '../../reducers/ClusterRecommendationsReducer';
|
|
9
10
|
import { getIsClusterIdInvalid, isClusterIdEnabledForProduct } from '../../utils/caseOpenshiftClusterIdUtils';
|
|
10
11
|
const ClusterRecommendationToast = () => {
|
|
12
|
+
var _a;
|
|
11
13
|
const { clusterRecommendationsState: { clusterRecommendations, isClusterRecommendationsModalOpen }, } = useContext(ClusterRecommendationsContext);
|
|
12
14
|
const clusterRecommendationsDispatch = useContext(ClusterRecommendationsDispatchContext);
|
|
13
15
|
const [isToastVisible, setToastVisibility] = useState(false);
|
|
@@ -15,6 +17,7 @@ const ClusterRecommendationToast = () => {
|
|
|
15
17
|
openshiftClusterID: state.caseDetails.openshiftClusterID,
|
|
16
18
|
product: state.caseDetails.product,
|
|
17
19
|
}), isEqual);
|
|
20
|
+
const { globalMetadataState: { allProducts }, } = useContext(GlobalMetadataStateContext);
|
|
18
21
|
// To open popover we check for cluster id and clusterRecommendations array length
|
|
19
22
|
useEffect(() => {
|
|
20
23
|
if (!isEmpty(openshiftClusterID) && clusterRecommendations.data.length)
|
|
@@ -28,7 +31,7 @@ const ClusterRecommendationToast = () => {
|
|
|
28
31
|
if (!openshiftClusterID || getIsClusterIdInvalid(openshiftClusterID))
|
|
29
32
|
setToastVisibility(false);
|
|
30
33
|
}, [openshiftClusterID]);
|
|
31
|
-
const hasCluster = isClusterIdEnabledForProduct(product);
|
|
34
|
+
const hasCluster = isClusterIdEnabledForProduct(product, (_a = allProducts.data) === null || _a === void 0 ? void 0 : _a.productsResult);
|
|
32
35
|
if (!isToastVisible || !hasCluster)
|
|
33
36
|
return null;
|
|
34
37
|
const onViewRecommendations = () => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ClusterRecommendations.d.ts","sourceRoot":"","sources":["../../../../src/components/Recommendations/ClusterRecommendations.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ClusterRecommendations.d.ts","sourceRoot":"","sources":["../../../../src/components/Recommendations/ClusterRecommendations.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAqB,MAAM,OAAO,CAAC;AAa1C,UAAU,MAAM;IACZ,+BAA+B,CAAC,EAAE,OAAO,CAAC;IAC1C,8BAA8B,CAAC,EAAE,OAAO,CAAC;IACzC,SAAS,CAAC,EAAE,MAAM,CAAC;CACtB;AAED,MAAM,CAAC,OAAO,UAAU,sBAAsB,CAAC,KAAK,EAAE,MAAM,qBAuD3D"}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { GlobalMetadataStateContext } from '@rh-support/react-context';
|
|
1
2
|
import isEqual from 'lodash/isEqual';
|
|
2
3
|
import React, { useContext } from 'react';
|
|
3
4
|
import { Trans } from 'react-i18next';
|
|
@@ -8,6 +9,7 @@ import { isClusterIdEnabledForProduct } from '../../utils/caseOpenshiftClusterId
|
|
|
8
9
|
import { ClusterRecommendationItems } from './ClusterRecommendationItems';
|
|
9
10
|
import { ClusterRecommendationsModal } from './ClusterRecommendationsModal';
|
|
10
11
|
export default function ClusterRecommendations(props) {
|
|
12
|
+
var _a;
|
|
11
13
|
const { showClusterRecommendationsModal = true, showClusterRecommendationsList = true } = props;
|
|
12
14
|
const { clusterRecommendationsState: { clusterRecommendations, isClusterRecommendationsModalOpen }, } = useContext(ClusterRecommendationsContext);
|
|
13
15
|
const clusterRecommendationsDispatch = useContext(ClusterRecommendationsDispatchContext);
|
|
@@ -15,11 +17,12 @@ export default function ClusterRecommendations(props) {
|
|
|
15
17
|
openshiftClusterID: state.caseDetails.openshiftClusterID,
|
|
16
18
|
product: state.caseDetails.product,
|
|
17
19
|
}), isEqual);
|
|
20
|
+
const { globalMetadataState: { allProducts }, } = useContext(GlobalMetadataStateContext);
|
|
18
21
|
const NUMBER_OF_RULES_TO_DISPLAY = 3;
|
|
19
22
|
const onViewMoreRecommendation = () => {
|
|
20
23
|
toggleClusterRecommendationModal(clusterRecommendationsDispatch, !isClusterRecommendationsModalOpen);
|
|
21
24
|
};
|
|
22
|
-
const hasCluster = isClusterIdEnabledForProduct(product);
|
|
25
|
+
const hasCluster = isClusterIdEnabledForProduct(product, (_a = allProducts.data) === null || _a === void 0 ? void 0 : _a.productsResult);
|
|
23
26
|
if (clusterRecommendations.data.length === 0 ||
|
|
24
27
|
clusterRecommendations.isError ||
|
|
25
28
|
clusterRecommendations.isFetching ||
|
|
@@ -21,7 +21,7 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
21
21
|
import { pcm, search } from '@cee-eng/hydrajs';
|
|
22
22
|
import { Alert } from '@patternfly/react-core';
|
|
23
23
|
import { usePrevious } from '@rh-support/components';
|
|
24
|
-
import { getSolrParams, PreviousCaseTypes } from '@rh-support/utils';
|
|
24
|
+
import { getSolrParams, PreviousCaseTypes, uniqueRecommendationDocs } from '@rh-support/utils';
|
|
25
25
|
import difference from 'lodash/difference';
|
|
26
26
|
import filter from 'lodash/filter';
|
|
27
27
|
import flatMap from 'lodash/flatMap';
|
|
@@ -110,7 +110,7 @@ function InsightsResults(props) {
|
|
|
110
110
|
summary: summary,
|
|
111
111
|
description: getDescriptionWOQues(issue, environment, periodicityOfIssue, timeFramesAndUrgency),
|
|
112
112
|
}, getSolrParams(3, 129, { id: kcsIds }));
|
|
113
|
-
const docs = (_c = (_b = response === null || response === void 0 ? void 0 : response.response) === null || _b === void 0 ? void 0 : _b.docs) !== null && _c !== void 0 ? _c : [];
|
|
113
|
+
const docs = uniqueRecommendationDocs((_c = (_b = response === null || response === void 0 ? void 0 : response.response) === null || _b === void 0 ? void 0 : _b.docs) !== null && _c !== void 0 ? _c : []);
|
|
114
114
|
if (!recommendedResultsMap[attachmentId]) {
|
|
115
115
|
setRecommendedResultsMap((oldMap) => (Object.assign(Object.assign({}, oldMap), { [attachmentId]: docs.map((item) => (Object.assign({ attachmentId }, item))) })));
|
|
116
116
|
}
|
|
@@ -138,7 +138,7 @@ function InsightsResults(props) {
|
|
|
138
138
|
try {
|
|
139
139
|
const _c = getSolrParams(200, 256, { id: kcsIds }, false, true), { start, rows, q } = _c, expression = __rest(_c, ["start", "rows", "q"]);
|
|
140
140
|
const res = yield search.solrSearchV2({ start, rows, q }, 'kcs', expression);
|
|
141
|
-
const docs = (_b = (_a = res === null || res === void 0 ? void 0 : res.response) === null || _a === void 0 ? void 0 : _a.docs) !== null && _b !== void 0 ? _b : [];
|
|
141
|
+
const docs = uniqueRecommendationDocs((_b = (_a = res === null || res === void 0 ? void 0 : res.response) === null || _a === void 0 ? void 0 : _a.docs) !== null && _b !== void 0 ? _b : []);
|
|
142
142
|
const attachmentId = localFile.attachmentId;
|
|
143
143
|
if (!insightResultsMap[attachmentId]) {
|
|
144
144
|
setInsightResultsMap((oldMap) => (Object.assign(Object.assign({}, oldMap), { [attachmentId]: docs.map((item) => (Object.assign({ attachmentId }, item))) })));
|
|
@@ -47,7 +47,7 @@ export default function Recommendations(props) {
|
|
|
47
47
|
const { recommendationState } = useContext(RecommendationStateContext);
|
|
48
48
|
const prevMainRecommendations = usePrevious((_a = recommendationState === null || recommendationState === void 0 ? void 0 : recommendationState.visibleDocs) !== null && _a !== void 0 ? _a : []);
|
|
49
49
|
const recommendationDispatch = useContext(RecommendationDispatchContext);
|
|
50
|
-
const DEFAULTPAGESIZE =
|
|
50
|
+
const DEFAULTPAGESIZE = 5;
|
|
51
51
|
const MAXROW = 24;
|
|
52
52
|
const recPageSize = pageSize !== null && pageSize !== void 0 ? pageSize : DEFAULTPAGESIZE;
|
|
53
53
|
const abortControllerRef = useRef(undefined);
|
|
@@ -209,7 +209,7 @@ export default function Recommendations(props) {
|
|
|
209
209
|
' '))),
|
|
210
210
|
recommendationState.isLoadingRecommendations ? (React.createElement(RecommendationsLoader, null)) : (React.createElement("ul", { className: "list-flat" }, map(recommendationState.visibleDocs, (doc, i) => {
|
|
211
211
|
var _a, _b;
|
|
212
|
-
return (React.createElement("li", { className: "result", key:
|
|
212
|
+
return (React.createElement("li", { className: "result", key: doc.uri || i },
|
|
213
213
|
React.createElement("header", { className: "result-header" },
|
|
214
214
|
React.createElement("a", { href: `${doc.view_uri}?${RouteUtils.getSEResourceQueryParams(activeSessionId, (_b = (_a = sessionResourceTracking[SessionResourceSource.RECOMMENDATIONS]) === null || _a === void 0 ? void 0 : _a.resourceOriginId) !== null && _b !== void 0 ? _b : '', SessionResourceSource.RECOMMENDATIONS)}`, className: "se-recommended ts-result", "data-tracking-id": `se-recommended-main-recommendations-${i}`, rel: "noopener noreferrer", target: "_blank", onClick: onResourceClick(doc, i), dangerouslySetInnerHTML: computeRecommendationTitle(doc) }),
|
|
215
215
|
React.createElement("div", { className: "header-meta pf-v6-u-mt-xs" },
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RemoteRiderAcceptanceModal.d.ts","sourceRoot":"","sources":["../../../../src/components/RemoteRider/RemoteRiderAcceptanceModal.tsx"],"names":[],"mappings":"AAGA,OAAO,EAAE,mBAAmB,EAAE,MAAM,0BAA0B,CAAC;AAC/D,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;
|
|
1
|
+
{"version":3,"file":"RemoteRiderAcceptanceModal.d.ts","sourceRoot":"","sources":["../../../../src/components/RemoteRider/RemoteRiderAcceptanceModal.tsx"],"names":[],"mappings":"AAGA,OAAO,EAAE,mBAAmB,EAAE,MAAM,0BAA0B,CAAC;AAC/D,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AAExD,OAAO,KAAqB,MAAM,OAAO,CAAC;AAG1C,UAAU,MAAM;IACZ,WAAW,EAAE,OAAO,CAAC;IACrB,YAAY,CAAC,EAAE,MAAM,IAAI,CAAC;IAC1B,SAAS,EAAE,MAAM,IAAI,CAAC;IACtB,SAAS,EAAE,MAAM,IAAI,CAAC;IACtB,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAC5B,UAAU,EAAE,MAAM,CAAC;IACnB,kBAAkB,EAAE,mBAAmB,CAAC,QAAQ,CAAC,CAAC;CACrD;AAED,MAAM,CAAC,OAAO,UAAU,0BAA0B,CAAC,KAAK,EAAE,MAAM,qBAwD/D"}
|
|
@@ -11,26 +11,24 @@ import { publicApi } from '@cee-eng/hydrajs';
|
|
|
11
11
|
import { AcceptTermsModal, ToastNotification, useFetch } from '@rh-support/components';
|
|
12
12
|
import { GlobalMetadataStateContext } from '@rh-support/react-context';
|
|
13
13
|
import { TncConstants } from '@rh-support/utils';
|
|
14
|
-
import isEqual from 'lodash/isEqual';
|
|
15
14
|
import React, { useContext } from 'react';
|
|
16
15
|
import { useTranslation } from 'react-i18next';
|
|
17
|
-
import { useCaseSelector } from '../../context/CaseContext';
|
|
18
|
-
import { useCreateCaseComment } from '../../hooks/useCaseComments';
|
|
19
16
|
export default function RemoteRiderAcceptanceModal(props) {
|
|
20
17
|
const { globalMetadataState: { loggedInUser }, } = useContext(GlobalMetadataStateContext);
|
|
21
18
|
const { t } = useTranslation();
|
|
22
19
|
const { request, isFetching } = useFetch(publicApi.kase.acknowledgeRemoteSessionTerms, { propgateErrors: true });
|
|
23
|
-
const {
|
|
24
|
-
|
|
20
|
+
const { request: postCommentRequest, isFetching: isPostingComment } = useFetch(publicApi.kase.postComment, {
|
|
21
|
+
propgateErrors: true,
|
|
22
|
+
});
|
|
25
23
|
const onConfirm = (pdfId) => __awaiter(this, void 0, void 0, function* () {
|
|
26
24
|
try {
|
|
27
25
|
yield request(props.caseNumber, pdfId);
|
|
28
26
|
try {
|
|
29
|
-
const requestComment = t('
|
|
30
|
-
yield
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
27
|
+
const requestComment = t('#### Remote Access Rider agreement has been accepted.\n\n This action does not initiate a remote session. Please make a case comment if you would like to submit a request.');
|
|
28
|
+
yield postCommentRequest({
|
|
29
|
+
caseNumber: props.caseNumber,
|
|
30
|
+
commentBody: requestComment,
|
|
31
|
+
contentType: 'markdown',
|
|
34
32
|
});
|
|
35
33
|
ToastNotification.addSuccessMessage(t('Remote Access Rider agreement has been accepted'), t('This action does not initiate a remote session. Please make a case comment if you would like to submit a request.'));
|
|
36
34
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Review.d.ts","sourceRoot":"","sources":["../../../../src/components/Review/Review.tsx"],"names":[],"mappings":"AAKA,OAAO,
|
|
1
|
+
{"version":3,"file":"Review.d.ts","sourceRoot":"","sources":["../../../../src/components/Review/Review.tsx"],"names":[],"mappings":"AAKA,OAAO,KAAwC,MAAM,OAAO,CAAC;AAC7D,OAAO,EAAE,mBAAmB,EAAE,MAAM,kBAAkB,CAAC;AAIvD,OAAO,EAAE,eAAe,EAAE,MAAM,iCAAiC,CAAC;AAoBlE,UAAU,MAAM;IACZ,UAAU,EAAE,mBAAmB,CAAC,eAAe,CAAC,CAAC;CACpD;AACD,MAAM,CAAC,OAAO,UAAU,MAAM,CAAC,KAAK,EAAE,MAAM,qBAqF3C"}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { Grid, GridItem } from '@patternfly/react-core';
|
|
2
|
-
|
|
2
|
+
import { AbilityContext, CaseDetailsFields, resourceActions, resources } from '@rh-support/user-permissions';
|
|
3
3
|
import { PreviousCaseTypes } from '@rh-support/utils';
|
|
4
4
|
import isEmpty from 'lodash/isEmpty';
|
|
5
5
|
import isEqual from 'lodash/isEqual';
|
|
6
|
-
import React, { useEffect, useRef } from 'react';
|
|
6
|
+
import React, { useContext, useEffect, useRef } from 'react';
|
|
7
7
|
import { useCaseDispatch, useCaseSelector } from '../../context/CaseContext';
|
|
8
8
|
import { setCaseDetails } from '../../reducers/CaseReducer';
|
|
9
9
|
import { AccountSelector } from '../AccountInfo/AccountSelector';
|
|
@@ -11,19 +11,17 @@ import { OwnerSelector } from '../AccountInfo/OwnerSelector';
|
|
|
11
11
|
import CaseGroup from '../CaseInformation/CaseGroup';
|
|
12
12
|
import CaseType from '../CaseInformation/CaseType';
|
|
13
13
|
import { ContactPhoneNumber } from '../CaseInformation/ContactPhoneNumber';
|
|
14
|
-
|
|
15
|
-
// import { ContactPhoneNumberAlert } from '../CaseInformation/ContactPhoneNumberAlert';
|
|
14
|
+
import { ContactPhoneNumberAlert } from '../CaseInformation/ContactPhoneNumberAlert';
|
|
16
15
|
import Fts from '../CaseInformation/Fts';
|
|
17
16
|
import Severity from '../CaseInformation/Severity';
|
|
18
17
|
import SupportLevel from '../CaseInformation/SupportLevel';
|
|
19
|
-
import CaseLabelsCreate from '../CaseManagement/CaseLabelsCreate';
|
|
20
18
|
import CaseLanguageSelector from '../CaseManagement/CaseLanguageSelector';
|
|
21
|
-
|
|
19
|
+
import { Cep } from '../CaseManagement/Cep';
|
|
22
20
|
import OpenReferenceNumber from '../CaseManagement/OpenReferenceNumber';
|
|
23
21
|
import { OpenShiftClusterId } from '../CaseManagement/OpenShiftClusterId';
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
22
|
+
import { RHAssociatesSelector } from '../CaseManagement/RHAssociatesSelector';
|
|
23
|
+
import CaseContactSelector from '../CaseManagement/SendNotifications/CaseContactSelector';
|
|
24
|
+
import { Hostname } from '../ImproveCase/Hostname';
|
|
27
25
|
import KtQuestions from '../ImproveCase/KtQuestions';
|
|
28
26
|
import { AllProductsSelector } from '../ProductSelector/AllProductsSelector';
|
|
29
27
|
export default function Review(props) {
|
|
@@ -43,12 +41,8 @@ export default function Review(props) {
|
|
|
43
41
|
}
|
|
44
42
|
previousCaseTypeRef.current = caseType;
|
|
45
43
|
}, [caseType, caseDispatch]);
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
// resourceActions.PATCH,
|
|
49
|
-
// resources.CASE_DETAILS,
|
|
50
|
-
// CaseDetailsFields.CASE_DETAILS_SEND_NOTIFICATIONS
|
|
51
|
-
// );
|
|
44
|
+
const ability = useContext(AbilityContext);
|
|
45
|
+
const canSeeEmailNotifications = ability.can(resourceActions.PATCH, resources.CASE_DETAILS, CaseDetailsFields.CASE_DETAILS_SEND_NOTIFICATIONS);
|
|
52
46
|
const onSeverityChange = (payload) => {
|
|
53
47
|
setCaseDetails(caseDispatch, payload);
|
|
54
48
|
};
|
|
@@ -56,8 +50,9 @@ export default function Review(props) {
|
|
|
56
50
|
React.createElement("form", { className: "review-form card card-light push-bottom" },
|
|
57
51
|
React.createElement(AccountSelector, null),
|
|
58
52
|
React.createElement(OwnerSelector, null),
|
|
59
|
-
React.createElement(AllProductsSelector, { routeProps: props.routeProps, loadTCOnChange: true, showTCAfterButtonClicked: true, isOnReviewPage: true }),
|
|
53
|
+
React.createElement(AllProductsSelector, { routeProps: props.routeProps, loadTCOnChange: true, showTCAfterButtonClicked: true, checkEntitledProduct: true, isOnReviewPage: true }),
|
|
60
54
|
React.createElement(OpenShiftClusterId, null),
|
|
55
|
+
caseType !== PreviousCaseTypes.FEATURE_ENHANCEMENT && React.createElement(Hostname, null),
|
|
61
56
|
React.createElement(KtQuestions, { inlineEditable: true, hideSaveCancel: true, onlyShowKT4: caseType === PreviousCaseTypes.FEATURE_ENHANCEMENT }),
|
|
62
57
|
React.createElement(CaseType, null),
|
|
63
58
|
React.createElement(SupportLevel, null),
|
|
@@ -66,14 +61,15 @@ export default function Review(props) {
|
|
|
66
61
|
React.createElement(Severity, { showSeverityInfoIcon: true, onSeverityChange: onSeverityChange })),
|
|
67
62
|
React.createElement(GridItem, { span: 12, xl2: 6, className: "pf-v6-u-mb-xl" },
|
|
68
63
|
React.createElement(ContactPhoneNumber, null))),
|
|
64
|
+
React.createElement(ContactPhoneNumberAlert, null),
|
|
69
65
|
React.createElement(Fts, { inlineEditable: true, initialIsEditing: isEmpty(contactInfo24x7), hideSaveCancel: true }),
|
|
70
66
|
React.createElement(Grid, { hasGutter: true },
|
|
71
67
|
React.createElement(GridItem, { span: 12, xl2: 6, className: "pf-v6-u-mb-xs" },
|
|
72
68
|
React.createElement(CaseLanguageSelector, null)),
|
|
73
69
|
React.createElement(GridItem, { span: 12, xl2: 6, className: "pf-v6-u-mb-xs" },
|
|
74
70
|
React.createElement(CaseGroup, null))),
|
|
75
|
-
React.createElement(
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
React.createElement(
|
|
71
|
+
canSeeEmailNotifications && React.createElement(CaseContactSelector, null),
|
|
72
|
+
React.createElement(RHAssociatesSelector, null),
|
|
73
|
+
React.createElement(OpenReferenceNumber, { inlineEditable: false, hideSaveCancel: true }),
|
|
74
|
+
React.createElement(Cep, null))));
|
|
79
75
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SessionRestore.d.ts","sourceRoot":"","sources":["../../../../src/components/SessionRestore/SessionRestore.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"SessionRestore.d.ts","sourceRoot":"","sources":["../../../../src/components/SessionRestore/SessionRestore.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAgC,YAAY,EAAE,MAAM,qDAAqD,CAAC;AAQjH,OAAO,KAAkD,MAAM,OAAO,CAAC;AACvE,OAAO,EAAE,mBAAmB,EAAE,MAAM,kBAAkB,CAAC;AAQvD,OAAO,EAGH,eAAe,EAElB,MAAM,iCAAiC,CAAC;AAmBzC,UAAU,MAAM;IACZ,UAAU,EAAE,mBAAmB,CAAC,eAAe,CAAC,CAAC;CACpD;AAED,eAAO,MAAM,6BAA6B,GAAI,aAAa,YAAY,GAAG,SAAS,EAAE,uBAAuB,MAAM,YAKjH,CAAC;AAEF,wBAAgB,cAAc,CAAC,KAAK,EAAE,MAAM,qBAsX3C"}
|