@rh-support/troubleshoot 2.2.37 → 2.2.39

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.
@@ -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 agreement has already been accepted.'), reference: tooltipRef, "aria-live": 'polite' })),
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":"CaseHostname.d.ts","sourceRoot":"","sources":["../../../../../../src/components/CaseEditView/Tabs/CaseDetails/CaseHostname.tsx"],"names":[],"mappings":"AAMA,OAAO,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAc5D,UAAU,MAAO,SAAQ,gBAAgB;IACrC,cAAc,EAAE,OAAO,CAAC;CAC3B;AAMD,iBAAS,YAAY,CAAC,KAAK,EAAE,MAAM,eAuKlC;kBAvKQ,YAAY;;;AA0KrB,OAAO,EAAE,YAAY,EAAE,CAAC"}
1
+ {"version":3,"file":"CaseHostname.d.ts","sourceRoot":"","sources":["../../../../../../src/components/CaseEditView/Tabs/CaseDetails/CaseHostname.tsx"],"names":[],"mappings":"AAWA,OAAO,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAc5D,UAAU,MAAO,SAAQ,gBAAgB;IACrC,cAAc,EAAE,OAAO,CAAC;CAC3B;AAMD,iBAAS,YAAY,CAAC,KAAK,EAAE,MAAM,eA0KlC;kBA1KQ,YAAY;;;AA6KrB,OAAO,EAAE,YAAY,EAAE,CAAC"}
@@ -11,7 +11,7 @@ import { accounts } from '@cee-eng/hydrajs';
11
11
  import { Popover, PopoverPosition, Spinner, Switch } from '@patternfly/react-core';
12
12
  import QuestionCircleIcon from '@patternfly/react-icons/dist/js/icons/question-circle-icon';
13
13
  import { InlineEdit, LoadingIndicator, ToastNotification, useFetch, ValueChangedIcon } from '@rh-support/components';
14
- import { GlobalMetadataStateContext, useCanEditCase } from '@rh-support/react-context';
14
+ import { fetchLoggedInUsersAccount, GlobalMetadataDispatchContext, GlobalMetadataStateContext, useCanEditCase, } from '@rh-support/react-context';
15
15
  import { ability, CaseListFields, resourceActions, resources } from '@rh-support/user-permissions';
16
16
  import isEqual from 'lodash/isEqual';
17
17
  import React, { useContext, useEffect, useState } from 'react';
@@ -32,6 +32,7 @@ function CaseHostname(props) {
32
32
  caseNumber: state.caseDetails.caseNumber,
33
33
  }), isEqual);
34
34
  const caseDispatch = useCaseDispatch();
35
+ const dispatchToGlobalMetadataReducer = useContext(GlobalMetadataDispatchContext);
35
36
  const { t } = useTranslation();
36
37
  const caseUpdateError = useCaseUpdateErrorMessage();
37
38
  const [hostnameState, setHostnameState] = useState(hostname);
@@ -40,7 +41,7 @@ function CaseHostname(props) {
40
41
  const [isShareHostNamesChecked, setIsShareHostNamesChecked] = useState(false);
41
42
  const [isHostnamesLoading, setIsHostnamesLoading] = useState(true);
42
43
  const { isExportingPDF } = useContext(PDFContext);
43
- const { globalMetadataState: { loggedInUsersAccount }, } = useContext(GlobalMetadataStateContext);
44
+ const { globalMetadataState: { loggedInUsersAccount, loggedInUserJwtToken }, } = useContext(GlobalMetadataStateContext);
44
45
  const userOriginalHostnameValue = () => __awaiter(this, void 0, void 0, function* () {
45
46
  setIsShareHostNamesChecked(loggedInUsersAccount.data.shareHostnameWithRHT);
46
47
  setIsHostnamesLoading(false);
@@ -89,6 +90,7 @@ function CaseHostname(props) {
89
90
  try {
90
91
  setIsHostnamesLoading(true);
91
92
  yield updateShareHostnames(!isShareHostNamesChecked, accountNumber);
93
+ fetchLoggedInUsersAccount(dispatchToGlobalMetadataReducer, loggedInUserJwtToken, true);
92
94
  setIsShareHostNamesChecked(!isShareHostNamesChecked);
93
95
  }
94
96
  catch (error) {
@@ -1 +1 @@
1
- {"version":3,"file":"SubmitCase.d.ts","sourceRoot":"","sources":["../../../../src/components/SubmitCase/SubmitCase.tsx"],"names":[],"mappings":"AAkCA,MAAM,CAAC,OAAO,UAAU,UAAU,gBA0TjC"}
1
+ {"version":3,"file":"SubmitCase.d.ts","sourceRoot":"","sources":["../../../../src/components/SubmitCase/SubmitCase.tsx"],"names":[],"mappings":"AAkCA,MAAM,CAAC,OAAO,UAAU,UAAU,gBAsTjC"}
@@ -79,8 +79,7 @@ export default function SubmitCase() {
79
79
  const showRemoteRiderBanner = isRemoteRiderBannerVisible &&
80
80
  !loggedInUser.data.isInternal &&
81
81
  showRemoteRiderTermsInline &&
82
- !selectedAccountDetails.data.remoteSessionTermsAcked &&
83
- !isIdea;
82
+ !selectedAccountDetails.data.remoteSessionTermsAcked;
84
83
  const isNotAnIdea = caseType !== PreviousCaseTypes.FEATURE_ENHANCEMENT;
85
84
  // To check if the user is ESS Customer and Product has ESS Support
86
85
  const isESSCustomer = isSpecialSupportOfferingEnabled((_a = allProducts.data) === null || _a === void 0 ? void 0 : _a.productsResult, product);
@@ -89,10 +88,7 @@ export default function SubmitCase() {
89
88
  React.createElement(AlertMessage, { className: "pf-u-mt-lg", variant: AlertType.DANGER, show: caseCreationError, title: t("Sorry, we're experiencing an error"), isInline: true },
90
89
  React.createElement(React.Fragment, null, caseCreationErrorMessage)),
91
90
  !isCreatingCase && !caseCreationError && (React.createElement(React.Fragment, null,
92
- !isESSCustomer &&
93
- !screenSessionRequested &&
94
- showRemoteRiderBanner &&
95
- !loggedInUser.data.isInternal && (React.createElement(RemoteRiderBanner, { onConfirm: onRemoteRiderConfirm, onClose: onRemoteRiderClose, caseNumber: caseNoOfCreatedCase, isSecureSupport: loggedInUsersAccount.data.secureSupport, loggedInUserRights: loggedInUserRights })),
91
+ !isESSCustomer && !screenSessionRequested && showRemoteRiderBanner && (React.createElement(RemoteRiderBanner, { onConfirm: onRemoteRiderConfirm, onClose: onRemoteRiderClose, caseNumber: caseNoOfCreatedCase, isSecureSupport: loggedInUsersAccount.data.secureSupport, loggedInUserRights: loggedInUserRights })),
96
92
  React.createElement("div", { className: "submit-case-header-container" },
97
93
  React.createElement("p", { className: "kicker kicker-sm pf-u-mb-sm" }, !isEmpty(RouteUtils.seBasePath) &&
98
94
  !isUploadingAttachment(attachmentState.caseFiles.selectedLocalFiles) ? (React.createElement(React.Fragment, null,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rh-support/troubleshoot",
3
- "version": "2.2.37",
3
+ "version": "2.2.39",
4
4
  "publishConfig": {
5
5
  "access": "public",
6
6
  "registry": "https://registry.npmjs.org"
@@ -26,7 +26,7 @@
26
26
  "lib/**/*"
27
27
  ],
28
28
  "peerDependencies": {
29
- "@cee-eng/hydrajs": "4.16.21",
29
+ "@cee-eng/hydrajs": "4.16.33",
30
30
  "@cee-eng/ui-toolkit": "1.1.6",
31
31
  "@patternfly/patternfly": "4.196.7",
32
32
  "@patternfly/pfe-accordion": "1.12.3",
@@ -56,7 +56,7 @@
56
56
  "react-virtualized": "^9.21.2"
57
57
  },
58
58
  "dependencies": {
59
- "@cee-eng/hydrajs": "4.16.21",
59
+ "@cee-eng/hydrajs": "4.16.33",
60
60
  "@cee-eng/ui-toolkit": "1.1.6",
61
61
  "@patternfly/patternfly": "4.196.7",
62
62
  "@patternfly/pfe-accordion": "1.12.3",
@@ -66,11 +66,11 @@
66
66
  "@patternfly/react-core": "4.264.0",
67
67
  "@progress/kendo-drawing": "^1.6.0",
68
68
  "@progress/kendo-react-pdf": "^3.12.0",
69
- "@rh-support/components": "2.1.22",
70
- "@rh-support/react-context": "2.1.23",
69
+ "@rh-support/components": "2.1.23",
70
+ "@rh-support/react-context": "2.1.25",
71
71
  "@rh-support/types": "2.0.2",
72
- "@rh-support/user-permissions": "2.1.16",
73
- "@rh-support/utils": "2.1.10",
72
+ "@rh-support/user-permissions": "2.1.17",
73
+ "@rh-support/utils": "2.1.11",
74
74
  "@types/react-redux": "^7.1.12",
75
75
  "@types/redux": "^3.6.0",
76
76
  "dompurify": "^2.4.1",
@@ -133,5 +133,5 @@
133
133
  "defaults and supports es6-module",
134
134
  "maintained node versions"
135
135
  ],
136
- "gitHead": "8aa9957475709612c9d651414efe046c93c4ef11"
136
+ "gitHead": "c082a541ec56ac26470bb50a86a6c5af323f5c17"
137
137
  }