@rh-support/troubleshoot 2.6.268 → 2.6.270

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.
Files changed (90) hide show
  1. package/lib/esm/components/AccountInfo/css/accountSelector.css +2 -3
  2. package/lib/esm/components/CaseEditView/ActiveCustomerEscalation/ActiveCustomerEscalation.d.ts.map +1 -1
  3. package/lib/esm/components/CaseEditView/ActiveCustomerEscalation/ActiveCustomerEscalation.js +2 -5
  4. package/lib/esm/components/CaseEditView/Case.d.ts.map +1 -1
  5. package/lib/esm/components/CaseEditView/Case.js +4 -6
  6. package/lib/esm/components/CaseEditView/CaseOverview/CaseOwnerInfo.d.ts.map +1 -1
  7. package/lib/esm/components/CaseEditView/CaseOverview/CaseOwnerInfo.js +1 -1
  8. package/lib/esm/components/CaseEditView/CaseOverview/CaseType.d.ts.map +1 -1
  9. package/lib/esm/components/CaseEditView/CaseOverview/CaseType.js +4 -2
  10. package/lib/esm/components/CaseEditView/CaseOverview/index.js +2 -2
  11. package/lib/esm/components/CaseEditView/Tabs/CaseDetails/CaseOpenshiftClusterId/CaseOpenShiftPopover.js +1 -1
  12. package/lib/esm/components/CaseEditView/Tabs/CaseDetails/ProductVersion.d.ts.map +1 -1
  13. package/lib/esm/components/CaseEditView/Tabs/CaseDetails/ProductVersion.js +2 -4
  14. package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/CaseDiscussion.d.ts.map +1 -1
  15. package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/CaseDiscussion.js +0 -1
  16. package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/PostComment.d.ts.map +1 -1
  17. package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/PostComment.js +1 -2
  18. package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/VerifyCaseStatusModal/VerifyCaseStatusModal.d.ts.map +1 -1
  19. package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/VerifyCaseStatusModal/VerifyCaseStatusModal.js +3 -2
  20. package/lib/esm/components/CaseEditView/Tabs/CaseHistory/CaseHistory.css +0 -0
  21. package/lib/esm/components/CaseEditView/Tabs/CaseHistory/CaseHistory.d.ts +1 -0
  22. package/lib/esm/components/CaseEditView/Tabs/CaseHistory/CaseHistory.d.ts.map +1 -1
  23. package/lib/esm/components/CaseEditView/Tabs/CaseHistory/CaseHistory.js +1 -0
  24. package/lib/esm/components/CaseEditView/Tabs/CaseHistory/Timeline.css +33 -13
  25. package/lib/esm/components/CaseEditView/Tabs/CaseHistory/Timeline.d.ts.map +1 -1
  26. package/lib/esm/components/CaseEditView/Tabs/CaseHistory/Timeline.js +1 -1
  27. package/lib/esm/components/CaseEditView/Tabs/CaseSummary/CaseSummary.js +3 -3
  28. package/lib/esm/components/CaseEditView/Tabs/CaseSummary/CaseSummaryErrorMessage.js +1 -1
  29. package/lib/esm/components/CaseEditView/Tabs/RelatedTasks/RelatedTasks.js +1 -1
  30. package/lib/esm/components/CaseInformation/CaseGroup.d.ts.map +1 -1
  31. package/lib/esm/components/CaseInformation/CaseGroup.js +1 -11
  32. package/lib/esm/components/CaseInformation/CaseInformation.d.ts.map +1 -1
  33. package/lib/esm/components/CaseInformation/CaseInformation.js +4 -4
  34. package/lib/esm/components/CaseInformation/Description.d.ts.map +1 -1
  35. package/lib/esm/components/CaseInformation/Description.js +1 -17
  36. package/lib/esm/components/CaseInformation/Severity.d.ts.map +1 -1
  37. package/lib/esm/components/CaseInformation/Severity.js +1 -1
  38. package/lib/esm/components/CaseInformation/SupportLevel.d.ts.map +1 -1
  39. package/lib/esm/components/CaseInformation/SupportLevel.js +1 -1
  40. package/lib/esm/components/CaseManagement/NoClusterIDReasonSelector.d.ts.map +1 -1
  41. package/lib/esm/components/CaseManagement/NoClusterIDReasonSelector.js +4 -5
  42. package/lib/esm/components/CaseManagement/OpenShiftClusterId.js +1 -1
  43. package/lib/esm/components/CaseManagement/OpenshiftDropdownV4.d.ts.map +1 -1
  44. package/lib/esm/components/CaseManagement/OpenshiftDropdownV4.js +6 -12
  45. package/lib/esm/components/CaseManagement/SendNotifications/NonOrgCaseNotifyeesSelector.d.ts.map +1 -1
  46. package/lib/esm/components/CaseManagement/SendNotifications/NonOrgCaseNotifyeesSelector.js +1 -2
  47. package/lib/esm/components/Cve/CvePanel.d.ts.map +1 -1
  48. package/lib/esm/components/Cve/CvePanel.js +8 -16
  49. package/lib/esm/components/IdeaInformation/IdeaInformation.d.ts.map +1 -1
  50. package/lib/esm/components/IdeaInformation/IdeaInformation.js +4 -4
  51. package/lib/esm/components/ProductSelector/AllProductsSelector.d.ts.map +1 -1
  52. package/lib/esm/components/ProductSelector/AllProductsSelector.js +0 -1
  53. package/lib/esm/components/ProductSelector/NewProductDropdownSelector.d.ts.map +1 -1
  54. package/lib/esm/components/ProductSelector/NewProductDropdownSelector.js +5 -1
  55. package/lib/esm/components/Recommendations/ClusterRecommendationItems.d.ts +0 -2
  56. package/lib/esm/components/Recommendations/ClusterRecommendationItems.d.ts.map +1 -1
  57. package/lib/esm/components/Recommendations/ClusterRecommendationItems.js +13 -16
  58. package/lib/esm/components/Recommendations/ClusterRecommendations.d.ts.map +1 -1
  59. package/lib/esm/components/Recommendations/ClusterRecommendations.js +4 -1
  60. package/lib/esm/components/Recommendations/EARules/EARule.d.ts.map +1 -1
  61. package/lib/esm/components/Recommendations/EARules/EARule.js +1 -3
  62. package/lib/esm/components/Recommendations/InsightsResults.d.ts.map +1 -1
  63. package/lib/esm/components/Recommendations/InsightsResults.js +0 -4
  64. package/lib/esm/components/RemoteRider/RemoteRiderAcceptanceModal.d.ts.map +1 -1
  65. package/lib/esm/components/Review/Review.d.ts.map +1 -1
  66. package/lib/esm/components/Review/Review.js +1 -12
  67. package/lib/esm/components/SessionRestore/SessionRestore.d.ts.map +1 -1
  68. package/lib/esm/components/SessionRestore/SessionRestore.js +0 -3
  69. package/lib/esm/components/TroubleshootSection/AskRedHat.d.ts +1 -3
  70. package/lib/esm/components/TroubleshootSection/AskRedHat.d.ts.map +1 -1
  71. package/lib/esm/components/TroubleshootSection/AskRedHat.js +2 -4
  72. package/lib/esm/components/shared/fileUpload/WidgetFileUploader.d.ts.map +1 -1
  73. package/lib/esm/components/shared/fileUpload/WidgetFileUploader.js +1 -2
  74. package/lib/esm/components/shared/useIsSectionValid.js +6 -6
  75. package/lib/esm/reducers/CaseConstNTypes.js +4 -4
  76. package/lib/esm/reducers/CaseDiscussionTabReducer.js +1 -1
  77. package/lib/esm/reducers/CaseHelpers.d.ts +6 -8
  78. package/lib/esm/reducers/CaseHelpers.d.ts.map +1 -1
  79. package/lib/esm/reducers/CaseHelpers.js +10 -20
  80. package/lib/esm/reducers/CaseReducer.d.ts +0 -1
  81. package/lib/esm/reducers/CaseReducer.d.ts.map +1 -1
  82. package/lib/esm/reducers/CaseReducer.js +2 -37
  83. package/lib/esm/reducers/RulesReducer.d.ts +4 -11
  84. package/lib/esm/reducers/RulesReducer.d.ts.map +1 -1
  85. package/lib/esm/reducers/RulesReducer.js +1 -6
  86. package/lib/esm/reducers/SessionRestoreReducer.d.ts.map +1 -1
  87. package/lib/esm/reducers/SessionRestoreReducer.js +4 -7
  88. package/lib/esm/reducers/TopContentReducer.js +1 -1
  89. package/lib/esm/scss/_pf-overrides.scss +2 -28
  90. package/package.json +9 -7
@@ -2,12 +2,11 @@
2
2
  width: 100%;
3
3
  }
4
4
 
5
- .get-support-owner-wapper input,
6
- .margin-top.managed-account-selector .pf-c-select {
5
+ .get-support-owner-wapper input {
7
6
  min-height: 36px;
8
7
  }
9
8
 
10
- .margin-top.managed-account-selector .pf-c-select {
9
+ .margin-top.managed-account-selector {
11
10
  .pf-m-disabled {
12
11
  background-color: var(--pf-v5-global--disabled-color--300) !important;
13
12
  }
@@ -1 +1 @@
1
- {"version":3,"file":"ActiveCustomerEscalation.d.ts","sourceRoot":"","sources":["../../../../../src/components/CaseEditView/ActiveCustomerEscalation/ActiveCustomerEscalation.tsx"],"names":[],"mappings":"AAIA,OAAO,KAA0C,MAAM,OAAO,CAAC;AAM/D,UAAU,MAAM;IACZ,UAAU,EAAE,MAAM,CAAC;IACnB,YAAY,EAAE,MAAM,CAAC;IACrB,UAAU,EAAE,MAAM,CAAC;CACtB;AAED,eAAO,MAAM,wBAAwB,+EA+InC,CAAC"}
1
+ {"version":3,"file":"ActiveCustomerEscalation.d.ts","sourceRoot":"","sources":["../../../../../src/components/CaseEditView/ActiveCustomerEscalation/ActiveCustomerEscalation.tsx"],"names":[],"mappings":"AAIA,OAAO,KAA0C,MAAM,OAAO,CAAC;AAM/D,UAAU,MAAM;IACZ,UAAU,EAAE,MAAM,CAAC;IACnB,YAAY,EAAE,MAAM,CAAC;IACrB,UAAU,EAAE,MAAM,CAAC;CACtB;AAED,eAAO,MAAM,wBAAwB,+EAyInC,CAAC"}
@@ -1,17 +1,14 @@
1
1
  import { Button, ButtonVariant, Card, CardBody, CardHeader, List, ListItem, Popover } from '@patternfly/react-core';
2
2
  import InfoCircleIcon from '@patternfly/react-icons/dist/js/icons/info-circle-icon';
3
- import { useCanEditCase, useGlobalStateContext } from '@rh-support/react-context';
3
+ import { useCanEditCase } from '@rh-support/react-context';
4
4
  import { Can, resourceActions, resources } from '@rh-support/user-permissions';
5
5
  import React, { forwardRef, useState } from 'react';
6
6
  import { Trans, useTranslation } from 'react-i18next';
7
7
  import { useCaseDetailsPageStateContext } from '../../../context/CaseDetailsPageContext';
8
8
  import { RequestEscalationModal } from './RequestEscalationModal';
9
9
  export const ActiveCustomerEscalation = forwardRef((props, ref) => {
10
- var _a;
11
10
  const { t } = useTranslation();
12
11
  const { caseDetailsPageState: { caseEscalations }, } = useCaseDetailsPageStateContext();
13
- const { globalMetadataState: { loggedInUserRights }, } = useGlobalStateContext();
14
- const isInternal = (_a = loggedInUserRights.data) === null || _a === void 0 ? void 0 : _a.isInternal();
15
12
  const canEditCase = useCanEditCase();
16
13
  const isCreateRMEVisible = (caseEscalations.data || []).length === 0 || caseEscalations.data.every((item) => item.status === 'Closed');
17
14
  const commonElements = (React.createElement(React.Fragment, null,
@@ -62,5 +59,5 @@ export const ActiveCustomerEscalation = forwardRef((props, ref) => {
62
59
  React.createElement(Button, { variant: ButtonVariant.secondary, onClick: toggleModal, "data-tracking-id": "request-rme-trigger", "aria-label": t('Request an escalation') }, t('Request an escalation'))))));
63
60
  return (React.createElement(React.Fragment, null,
64
61
  React.createElement(RequestEscalationModal, { caseNumber: props.caseNumber, severity: props.caseSeverity, caseStatus: props.caseStatus, show: openRequestEscalationModal, onClose: toggleModal }),
65
- React.createElement(Can, { do: resourceActions.CREATE, on: resources.ICE_ESCALATION, passThrough: true }, (canCreateICE) => canCreateICE || isInternal ? isInternalElements : isCreateRMEVisible ? isNotInternalElements : null)));
62
+ React.createElement(Can, { do: resourceActions.CREATE, on: resources.ICE_ESCALATION, passThrough: true }, (canCreateICE) => canCreateICE ? isInternalElements : isCreateRMEVisible ? isNotInternalElements : React.createElement(React.Fragment, null))));
66
63
  });
@@ -1 +1 @@
1
- {"version":3,"file":"Case.d.ts","sourceRoot":"","sources":["../../../../src/components/CaseEditView/Case.tsx"],"names":[],"mappings":"AAcA,OAAO,KAAwC,MAAM,OAAO,CAAC;AAE7D,OAAO,EAAS,mBAAmB,EAAiD,MAAM,kBAAkB,CAAC;AAmB7G,UAAU,MAAM;IACZ,UAAU,EAAE,mBAAmB,CAAC;CACnC;AAED,MAAM,CAAC,OAAO,UAAU,IAAI,CAAC,KAAK,EAAE,MAAM,qBAmPzC"}
1
+ {"version":3,"file":"Case.d.ts","sourceRoot":"","sources":["../../../../src/components/CaseEditView/Case.tsx"],"names":[],"mappings":"AAcA,OAAO,KAAwC,MAAM,OAAO,CAAC;AAE7D,OAAO,EAAS,mBAAmB,EAAiD,MAAM,kBAAkB,CAAC;AAmB7G,UAAU,MAAM;IACZ,UAAU,EAAE,mBAAmB,CAAC;CACnC;AAED,MAAM,CAAC,OAAO,UAAU,IAAI,CAAC,KAAK,EAAE,MAAM,qBAiPzC"}
@@ -33,7 +33,7 @@ export default function Case(props) {
33
33
  const { t } = useTranslation();
34
34
  // The `path` lets us build <Route> paths that are
35
35
  // relative to the parent route, while the `url` lets
36
- //us build relative links.
36
+ // us build relative links.
37
37
  const { path, url } = useRouteMatch();
38
38
  const { caseNumber } = useParams();
39
39
  const queryParams = getUrlParsedParams(useLocation().search);
@@ -130,9 +130,7 @@ export default function Case(props) {
130
130
  console.error('Error fetching case details:', error);
131
131
  }
132
132
  });
133
- if (canManageCase) {
134
- safeFetchCaseDetails();
135
- }
133
+ safeFetchCaseDetails();
136
134
  // eslint-disable-next-line react-hooks/exhaustive-deps
137
135
  }, [
138
136
  caseNumber,
@@ -146,10 +144,10 @@ export default function Case(props) {
146
144
  return (React.createElement(React.Fragment, null,
147
145
  isExportingPDF && React.createElement(CoverSpinner, null),
148
146
  React.createElement("div", { id: "rh-support-case" },
149
- React.createElement("div", { className: "support-grid-case-details support-case" }, isFetchingCaseDetails && !isFetchingCaseDetailsError ? (React.createElement(OverviewContentLoader, null)) : (React.createElement(React.Fragment, null,
147
+ React.createElement("div", { className: "support-grid-case-details support-case" }, isFetchingCaseDetails && !isFetchingCaseDetailsError && isEmpty(product) ? (React.createElement(OverviewContentLoader, null)) : (React.createElement(React.Fragment, null,
150
148
  React.createElement("article", { className: "grid-main" },
151
149
  React.createElement("section", { className: "grid-main-section" },
152
- (isFetchingCaseDetailsError || !canReadCase || !canManageCase) && (React.createElement(CaseDetailsErrorMessage, { isError: isFetchingCaseDetailsError, errorDetails: caseDetailsError, canReadCase: canReadCase, canManageCase: canManageCase, caseNumber: caseNumber, isInlineError: true })),
150
+ (isFetchingCaseDetailsError || !canReadCase) && (React.createElement(CaseDetailsErrorMessage, { isError: isFetchingCaseDetailsError, errorDetails: caseDetailsError, canReadCase: canReadCase, canManageCase: canManageCase, caseNumber: caseNumber, isInlineError: true })),
153
151
  canReadCase &&
154
152
  (!isFetchingCaseDetails || !isEmpty(product)) &&
155
153
  !isFetchingCaseDetailsError && (React.createElement(React.Fragment, null,
@@ -1 +1 @@
1
- {"version":3,"file":"CaseOwnerInfo.d.ts","sourceRoot":"","sources":["../../../../../src/components/CaseEditView/CaseOverview/CaseOwnerInfo.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,qCAAqC,CAAC;AAI5D,OAAO,EAAE,mBAAmB,EAAE,MAAM,0BAA0B,CAAC;AAC/D,OAAO,KAAqB,MAAM,OAAO,CAAC;AAK1C,UAAU,MAAM;IACZ,KAAK,EAAE,MAAM,CAAC;IACd,gBAAgB,EAAE,mBAAmB,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC,CAAC;CACzD;AAED,MAAM,CAAC,OAAO,UAAU,aAAa,CAAC,KAAK,EAAE,MAAM,qBAqElD"}
1
+ {"version":3,"file":"CaseOwnerInfo.d.ts","sourceRoot":"","sources":["../../../../../src/components/CaseEditView/CaseOverview/CaseOwnerInfo.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,qCAAqC,CAAC;AAI5D,OAAO,EAAE,mBAAmB,EAAE,MAAM,0BAA0B,CAAC;AAC/D,OAAO,KAAqB,MAAM,OAAO,CAAC;AAK1C,UAAU,MAAM;IACZ,KAAK,EAAE,MAAM,CAAC;IACd,gBAAgB,EAAE,mBAAmB,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC,CAAC;CACzD;AAED,MAAM,CAAC,OAAO,UAAU,aAAa,CAAC,KAAK,EAAE,MAAM,qBAiElD"}
@@ -46,5 +46,5 @@ export default function CaseOwnerInfo(props) {
46
46
  React.createElement(Trans, null, "Office location")),
47
47
  ": ",
48
48
  props.caseDetailsHydra.data.caseOwner.officeLocation)) },
49
- React.createElement(QuestionCircleIcon, { color: "#5e40be", className: "pf-v6-u-ml-xs icon-size", "aria-label": "Support Level Info" })))))));
49
+ React.createElement(QuestionCircleIcon, { className: "pf-v6-u-ml-xs icon-size", "aria-label": "Support Level Info" })))))));
50
50
  }
@@ -1 +1 @@
1
- {"version":3,"file":"CaseType.d.ts","sourceRoot":"","sources":["../../../../../src/components/CaseEditView/CaseOverview/CaseType.tsx"],"names":[],"mappings":"AAWA,OAAO,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAG5D,OAAO,KAAoC,MAAM,OAAO,CAAC;AAOzD,UAAU,MAAO,SAAQ,gBAAgB;IACrC,YAAY,EAAE,MAAM,CAAC;IACrB,YAAY,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IACpD,UAAU,EAAE,OAAO,CAAC;IACpB,QAAQ,EAAE,GAAG,CAAC;IACd,UAAU,EAAE,OAAO,CAAC;IACpB,QAAQ,EAAE,OAAO,CAAC;CACrB;AAOD,iBAAS,QAAQ,CAAC,KAAK,EAAE,MAAM,qBAmF9B;kBAnFQ,QAAQ;;;AAsFjB,eAAe,QAAQ,CAAC"}
1
+ {"version":3,"file":"CaseType.d.ts","sourceRoot":"","sources":["../../../../../src/components/CaseEditView/CaseOverview/CaseType.tsx"],"names":[],"mappings":"AAWA,OAAO,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAG5D,OAAO,KAAoC,MAAM,OAAO,CAAC;AAOzD,UAAU,MAAO,SAAQ,gBAAgB;IACrC,YAAY,EAAE,MAAM,CAAC;IACrB,YAAY,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IACpD,UAAU,EAAE,OAAO,CAAC;IACpB,QAAQ,EAAE,GAAG,CAAC;IACd,UAAU,EAAE,OAAO,CAAC;IACpB,QAAQ,EAAE,OAAO,CAAC;CACrB;AAOD,iBAAS,QAAQ,CAAC,KAAK,EAAE,MAAM,qBAqF9B;kBArFQ,QAAQ;;;AAwFjB,eAAe,QAAQ,CAAC"}
@@ -25,6 +25,7 @@ function CaseType(props) {
25
25
  const [isCaseTypeInValid, setIsCaseTypeInValid] = useState(false);
26
26
  const { isExportingPDF } = useContext(PDFContext);
27
27
  const [isOpen, setIsOpen] = useState(false);
28
+ const [selected, setSelected] = useState(props.selectedType);
28
29
  const onToggleClick = () => {
29
30
  setIsOpen(!isOpen);
30
31
  };
@@ -32,7 +33,7 @@ function CaseType(props) {
32
33
  React.createElement(Flex, { justifyContent: { default: 'justifyContentSpaceBetween' } },
33
34
  React.createElement(FlexItem, null,
34
35
  " ",
35
- props.selectedType || t(`Select a category`)),
36
+ selected || t(`Select a category`)),
36
37
  React.createElement(FlexItem, null, props.isFetching ? React.createElement(Spinner, { size: "md" }) : ''))));
37
38
  const validateCaseType = (selectedItem) => {
38
39
  setIsCaseTypeInValid(isEmpty(selectedItem));
@@ -45,6 +46,7 @@ function CaseType(props) {
45
46
  setIsOpen(false);
46
47
  yield props.onTypeChange(switchedCaseType);
47
48
  setLocalTypeChange(true);
49
+ setSelected(option);
48
50
  validateCaseType(option);
49
51
  });
50
52
  // value changed logic to show a non local type change
@@ -55,7 +57,7 @@ function CaseType(props) {
55
57
  React.createElement(Trans, null, "Support type"),
56
58
  React.createElement(ValueChangedIcon, { afterLocalChange: afterLocalChange, isLocalChange: localTypeChange, value: props.selectedType, getTooltipContent: getChangedValueTooltip(() => CaseValuesToWatch.type) }),
57
59
  React.createElement("span", { className: `form-required ${isExportingPDF ? 'hide-in-pdf' : ''}`, "aria-hidden": true }, "*")),
58
- React.createElement(Select, { "data-tracking-id": "case-details-type-selector", isOpen: isOpen, selected: props.selectedType, onSelect: (event, val) => onCaseTypeChange(val), onOpenChange: (isOpen) => setIsOpen(isOpen), toggle: toggle, popperProps: { direction: 'down', enableFlip: false }, shouldFocusFirstItemOnOpen: false, shouldFocusToggleOnSelect: true },
60
+ React.createElement(Select, { "data-tracking-id": "case-details-type-selector", isOpen: isOpen, selected: selected, onSelect: (event, val) => onCaseTypeChange(val), onOpenChange: (isOpen) => setIsOpen(isOpen), toggle: toggle, popperProps: { direction: 'down', enableFlip: false }, shouldFocusFirstItemOnOpen: false, shouldFocusToggleOnSelect: true },
59
61
  React.createElement(SelectList, null, (props.allTypes || []).map((option) => (React.createElement(SelectOption, { value: option, key: option }, option)))))));
60
62
  }
61
63
  CaseType.defaultProps = defaultProps;
@@ -39,6 +39,7 @@ export default function CaseOverview(props) {
39
39
  const ability = useContext(AbilityContext);
40
40
  const { t } = useTranslation();
41
41
  const caseUpdateError = useCaseUpdateErrorMessage();
42
+ const canManageCase = ability.can(resourceActions.UPDATE, resources.CASE_DETAILS);
42
43
  const canSeeCaseOwnerInfo = ability.can(resourceActions.PATCH, resources.CASE_DETAILS, CaseDetailsFields.CASE_DETAILS_OWNER);
43
44
  const canSeeInactivityWarning = ability.can(resourceActions.PATCH, resources.CASE_DETAILS, CaseDetailsFields.CASE_DETAILS_ACTIVITY_WARNING);
44
45
  const caseOverviewState = useContext(CaseOverviewStateContext);
@@ -75,7 +76,6 @@ export default function CaseOverview(props) {
75
76
  const caseDispatch = useCaseDispatch();
76
77
  const globalMetadataDispatchContext = useContext(GlobalMetadataDispatchContext);
77
78
  const { globalMetadataState: { allCaseTypes, allCaseSeverities, viewAsCustomer, loggedInUsersAccount, loggedInUserRights, }, } = useContext(GlobalMetadataStateContext);
78
- const canManageCase = loggedInUserRights.data.canManageCases();
79
79
  const switchedCaseType = toNewCaseTypeSwitcher(caseType);
80
80
  const updatingUser = loggedInUsersAccount.data.name;
81
81
  const canSeeManagedByPartnerFlag = contactIsPartner &&
@@ -297,7 +297,7 @@ export default function CaseOverview(props) {
297
297
  React.createElement("div", { className: "form-wrapper" },
298
298
  React.createElement(CaseStatus, { selectedStatus: status, onStatusChange: onStatusChange, isDisabled: !canManageCase || caseOverviewState.allCaseStatuses.isFetching, allStatuses: caseOverviewState.allCaseStatuses.data, isFetching: caseOverviewState.caseStatusUpdating && isCaseUpdating, hasError: caseOverviewState.allCaseStatuses.isError })),
299
299
  React.createElement("div", { className: "form-wrapper" },
300
- React.createElement(CaseType, { selectedType: switchedCaseType, onTypeChange: onTypeChange, isDisabled: !canManageCase || allCaseTypes.isFetching || isCaseUpdating, allTypes: newCaseTypesArray, isFetching: caseOverviewState.caseTypeUpdating && isCaseUpdating, hasError: allCaseTypes.isError })),
300
+ React.createElement(CaseType, { selectedType: switchedCaseType, onTypeChange: onTypeChange, isDisabled: !canManageCase || allCaseTypes.isFetching, allTypes: newCaseTypesArray, isFetching: caseOverviewState.caseTypeUpdating && isCaseUpdating, hasError: allCaseTypes.isError })),
301
301
  React.createElement("div", { className: "form-wrapper" },
302
302
  React.createElement(Severity, { onSeverityChange: onSeverityChange, isDisabled: !canManageCase, isFetching: caseOverviewState.caseSeverityUpdating && isCaseUpdating })))),
303
303
  React.createElement(ExpandableSection, { className: "case-details-main", toggleText: t('Case information'), isExpanded: isDetailsExpanded, onToggle: onToggleDetails },
@@ -4,5 +4,5 @@ import React from 'react';
4
4
  import { Trans } from 'react-i18next';
5
5
  export default function CaseOpenShiftPopover() {
6
6
  return (React.createElement(Popover, { "aria-label": "Cluster Id Info", position: PopoverPosition.auto, bodyContent: React.createElement(Trans, null, "Cluster IDs give us the ability to use connected customer tools and services to debug your cluster in conjunction with this support case."), closeBtnAriaLabel: "Close" },
7
- React.createElement(QuestionCircleIcon, { color: "#5e40be", className: "pf-v6-u-ml-xs" })));
7
+ React.createElement(QuestionCircleIcon, { className: "pf-v6-u-ml-xs" })));
8
8
  }
@@ -1 +1 @@
1
- {"version":3,"file":"ProductVersion.d.ts","sourceRoot":"","sources":["../../../../../../src/components/CaseEditView/Tabs/CaseDetails/ProductVersion.tsx"],"names":[],"mappings":"AAyCA,OAAO,KAAkD,MAAM,OAAO,CAAC;AASvE,UAAU,MAAM;IACZ,yBAAyB,CAAC,EAAE,OAAO,CAAC;CACvC;AAED,iBAAS,eAAe,CAAC,KAAK,EAAE,MAAM,qBA4WrC;AAED,eAAe,eAAe,CAAC"}
1
+ {"version":3,"file":"ProductVersion.d.ts","sourceRoot":"","sources":["../../../../../../src/components/CaseEditView/Tabs/CaseDetails/ProductVersion.tsx"],"names":[],"mappings":"AAyCA,OAAO,KAAkD,MAAM,OAAO,CAAC;AASvE,UAAU,MAAM;IACZ,yBAAyB,CAAC,EAAE,OAAO,CAAC;CACvC;AAED,iBAAS,eAAe,CAAC,KAAK,EAAE,MAAM,qBA0WrC;AAED,eAAe,eAAe,CAAC"}
@@ -32,13 +32,12 @@ function ProductNVersion(props) {
32
32
  const [isVersionUpdating, setIsVersionUpdating] = useState(false);
33
33
  const [isOpen, setIsOpen] = useState(false);
34
34
  const textInputRef = useRef();
35
- const { product, version, caseNumber, contactSSOName, versionsDetails, isCaseUpdating } = useCaseSelector((state) => ({
35
+ const { product, version, caseNumber, contactSSOName, versionsDetails } = useCaseSelector((state) => ({
36
36
  product: state.caseDetails.product,
37
37
  version: state.caseDetails.version,
38
38
  contactSSOName: state.caseDetails.contactSSOName,
39
39
  caseNumber: state.caseDetails.caseNumber,
40
40
  versionsDetails: state.versionsDetails,
41
- isCaseUpdating: state.isCaseUpdating,
42
41
  }), isEqual);
43
42
  const caseDispatch = useCaseDispatch();
44
43
  const dispatchToGlobalMetadataReducer = useContext(GlobalMetadataDispatchContext);
@@ -252,7 +251,6 @@ function ProductNVersion(props) {
252
251
  React.createElement(Trans, null, "Version")),
253
252
  React.createElement(SingleSelectDropdown, { className: "open-case-version", id: "version-dropdown", placeholder: t(`Select a version`), selected: getVersionSelectedDropdownOption, options: getVersionDropdownOptions, isInvalid: checkIfVersionIsInvalid, isDisabled: isVersionUpdating ||
254
253
  (allProducts.isFetching && !allProducts.isError) ||
255
- isEmpty(selectedProductLocal) ||
256
- isCaseUpdating, onSelect: onVersionChange, isLoading: isVersionUpdating || (isSEProductApiIsDown && versionsDetails.isFetching), dataTrackingId: "case-details-version-selector", isScrollable: true }))))));
254
+ isEmpty(selectedProductLocal), onSelect: onVersionChange, isLoading: isVersionUpdating || (isSEProductApiIsDown && versionsDetails.isFetching), dataTrackingId: "case-details-version-selector", isScrollable: true }))))));
257
255
  }
258
256
  export default ProductNVersion;
@@ -1 +1 @@
1
- {"version":3,"file":"CaseDiscussion.d.ts","sourceRoot":"","sources":["../../../../../../src/components/CaseEditView/Tabs/CaseDiscussion/CaseDiscussion.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,SAAS,EAAE,YAAY,EAA0B,MAAM,yCAAyC,CAAC;AAkB1G,OAAO,KAAoE,MAAM,OAAO,CAAC;AAyCzF,UAAU,MAAM;IACZ,UAAU,EAAE,MAAM,CAAC;IACnB,YAAY,EAAE,YAAY,EAAE,CAAC;IAC7B,SAAS,EAAE,SAAS,EAAE,CAAC;IACvB,aAAa,EAAE,MAAM,CAAC;IACtB,MAAM,EAAE,KAAK,CAAC,gBAAgB,CAAC,cAAc,CAAC,CAAC;IAC/C,eAAe,EAAE,OAAO,CAAC;CAC5B;AAOD,MAAM,CAAC,OAAO,UAAU,cAAc,CAAC,KAAK,EAAE,MAAM,qBA4oBnD"}
1
+ {"version":3,"file":"CaseDiscussion.d.ts","sourceRoot":"","sources":["../../../../../../src/components/CaseEditView/Tabs/CaseDiscussion/CaseDiscussion.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,SAAS,EAAE,YAAY,EAA0B,MAAM,yCAAyC,CAAC;AAkB1G,OAAO,KAAoE,MAAM,OAAO,CAAC;AAyCzF,UAAU,MAAM;IACZ,UAAU,EAAE,MAAM,CAAC;IACnB,YAAY,EAAE,YAAY,EAAE,CAAC;IAC7B,SAAS,EAAE,SAAS,EAAE,CAAC;IACvB,aAAa,EAAE,MAAM,CAAC;IACtB,MAAM,EAAE,KAAK,CAAC,gBAAgB,CAAC,cAAc,CAAC,CAAC;IAC/C,eAAe,EAAE,OAAO,CAAC;CAC5B;AAOD,MAAM,CAAC,OAAO,UAAU,cAAc,CAAC,KAAK,EAAE,MAAM,qBA2oBnD"}
@@ -175,7 +175,6 @@ export default function CaseDiscussion(props) {
175
175
  dtmTrackEventCaseStepEncountered('comment', caseNumber, product, version);
176
176
  });
177
177
  const onAttachmentAdded = () => __awaiter(this, void 0, void 0, function* () {
178
- ToastNotification.addSuccessMessage(t('Attachment(s) uploaded successfully'));
179
178
  yield updateDiscussionStateAttachments(dispatchDiscussion, caseNumber, allDiscussions, sort, loggedInUsersAccount.data.secureSupport, discussionFiltersListState, dispatchCaseDetailsHydraAttachments);
180
179
  });
181
180
  const onReply = (commentText, commentCreator, isPublic) => {
@@ -1 +1 @@
1
- {"version":3,"file":"PostComment.d.ts","sourceRoot":"","sources":["../../../../../../src/components/CaseEditView/Tabs/CaseDiscussion/PostComment.tsx"],"names":[],"mappings":"AA8BA,OAAO,KAAwE,MAAM,OAAO,CAAC;AAQ7F,OAAO,EAAkB,WAAW,EAAE,MAAM,+CAA+C,CAAC;AAsB5F,UAAU,MAAM;IACZ,UAAU,EAAE,MAAM,CAAC;IACnB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,cAAc,CAAC,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC;IACrC,iBAAiB,CAAC,EAAE,MAAM,IAAI,CAAC;IAC/B,kBAAkB,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;IAC5C,cAAc,CAAC,EAAE,MAAM,IAAI,CAAC;IAC5B,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B,cAAc,EAAE,WAAW,EAAE,CAAC;CACjC;AAED,wBAAgB,WAAW,CAAC,KAAK,EAAE,MAAM,qBA+iBxC"}
1
+ {"version":3,"file":"PostComment.d.ts","sourceRoot":"","sources":["../../../../../../src/components/CaseEditView/Tabs/CaseDiscussion/PostComment.tsx"],"names":[],"mappings":"AA8BA,OAAO,KAAwE,MAAM,OAAO,CAAC;AAQ7F,OAAO,EAAkB,WAAW,EAAE,MAAM,+CAA+C,CAAC;AAsB5F,UAAU,MAAM;IACZ,UAAU,EAAE,MAAM,CAAC;IACnB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,cAAc,CAAC,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC;IACrC,iBAAiB,CAAC,EAAE,MAAM,IAAI,CAAC;IAC/B,kBAAkB,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;IAC5C,cAAc,CAAC,EAAE,MAAM,IAAI,CAAC;IAC5B,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B,cAAc,EAAE,WAAW,EAAE,CAAC;CACjC;AAED,wBAAgB,WAAW,CAAC,KAAK,EAAE,MAAM,qBA8iBxC"}
@@ -188,8 +188,7 @@ export function PostComment(props) {
188
188
  if (commentText) {
189
189
  try {
190
190
  setIsProcessing(true);
191
- const newCommentText = commentText.replace(/(^|\n)(-\s.+)(\n(?![-\s]))/g, '$1$2\n\n');
192
- yield request({ caseNumber, commentBody: newCommentText, isPublic, contentType: commentType });
191
+ yield request({ caseNumber, commentBody: commentText, isPublic, contentType: commentType });
193
192
  checkForCaseStatusToggleOnAttachOrComment(caseDispatch, loggedInUserRights.data.isInternal(), status);
194
193
  !isPublic && setIsPublic(true);
195
194
  addUserToNotifyList();
@@ -1 +1 @@
1
- {"version":3,"file":"VerifyCaseStatusModal.d.ts","sourceRoot":"","sources":["../../../../../../../src/components/CaseEditView/Tabs/CaseDiscussion/VerifyCaseStatusModal/VerifyCaseStatusModal.tsx"],"names":[],"mappings":"AAYA,OAAO,KAAsD,MAAM,OAAO,CAAC;AAa3E,UAAU,MAAM;IACZ,SAAS,EAAE,CAAC,WAAW,CAAC,EAAE,MAAM,KAAK,IAAI,CAAC;IAC1C,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,UAAU,EAAE,OAAO,CAAC;CACvB;AAED,wBAAgB,qBAAqB,CAAC,KAAK,EAAE,MAAM,qBA6IlD"}
1
+ {"version":3,"file":"VerifyCaseStatusModal.d.ts","sourceRoot":"","sources":["../../../../../../../src/components/CaseEditView/Tabs/CaseDiscussion/VerifyCaseStatusModal/VerifyCaseStatusModal.tsx"],"names":[],"mappings":"AAaA,OAAO,KAAsD,MAAM,OAAO,CAAC;AAa3E,UAAU,MAAM;IACZ,SAAS,EAAE,CAAC,WAAW,CAAC,EAAE,MAAM,KAAK,IAAI,CAAC;IAC1C,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,UAAU,EAAE,OAAO,CAAC;CACvB;AAED,wBAAgB,qBAAqB,CAAC,KAAK,EAAE,MAAM,qBA2IlD"}
@@ -10,6 +10,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
10
10
  import { Button, ButtonVariant, Modal, ModalBody, ModalFooter, ModalHeader, ModalVariant, } from '@patternfly/react-core';
11
11
  import { SingleSelectDropdown, ToastNotification } from '@rh-support/components';
12
12
  import { GlobalMetadataStateContext, useCanEditCase } from '@rh-support/react-context';
13
+ import { ability, resourceActions, resources } from '@rh-support/user-permissions';
13
14
  import isEqual from 'lodash/isEqual';
14
15
  import React, { useContext, useEffect, useReducer, useState } from 'react';
15
16
  import { Trans, useTranslation } from 'react-i18next';
@@ -21,6 +22,7 @@ export function VerifyCaseStatusModal(props) {
21
22
  const { t } = useTranslation();
22
23
  const caseUpdateError = useCaseUpdateErrorMessage();
23
24
  const [caseOverviewState, caseOverviewDispatch] = useReducer(caseOverviewReducer, initialCaseViewState);
25
+ const canManageCase = ability.can(resourceActions.UPDATE, resources.CASE_DETAILS);
24
26
  const caseState = useCaseSelector((state) => ({
25
27
  caseDetails: {
26
28
  product: state.caseDetails.product,
@@ -43,8 +45,7 @@ export function VerifyCaseStatusModal(props) {
43
45
  selectedAccountDetails: state.selectedAccountDetails,
44
46
  }), isEqual);
45
47
  const { status } = caseState.caseDetails;
46
- const { globalMetadataState: { loggedInUsersAccount, loggedInUserRights }, } = useContext(GlobalMetadataStateContext);
47
- const canManageCase = loggedInUserRights.data.canManageCases();
48
+ const { globalMetadataState: { loggedInUsersAccount }, } = useContext(GlobalMetadataStateContext);
48
49
  useEffect(() => {
49
50
  fetchAllStatuses(caseOverviewDispatch, loggedInUsersAccount.data.secureSupport);
50
51
  }, [caseOverviewDispatch, loggedInUsersAccount.data.secureSupport]);
@@ -1,3 +1,4 @@
1
+ import './CaseHistory.css';
1
2
  import React from 'react';
2
3
  interface IProps {
3
4
  caseNumber: string;
@@ -1 +1 @@
1
- {"version":3,"file":"CaseHistory.d.ts","sourceRoot":"","sources":["../../../../../../src/components/CaseEditView/Tabs/CaseHistory/CaseHistory.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAI1B,UAAU,MAAM;IACZ,UAAU,EAAE,MAAM,CAAC;CACtB;AAED,QAAA,MAAM,WAAW,GAAI,OAAO,MAAM,sBAMjC,CAAC;AAEF,eAAe,WAAW,CAAC"}
1
+ {"version":3,"file":"CaseHistory.d.ts","sourceRoot":"","sources":["../../../../../../src/components/CaseEditView/Tabs/CaseHistory/CaseHistory.tsx"],"names":[],"mappings":"AAAA,OAAO,mBAAmB,CAAC;AAE3B,OAAO,KAAK,MAAM,OAAO,CAAC;AAI1B,UAAU,MAAM;IACZ,UAAU,EAAE,MAAM,CAAC;CACtB;AAED,QAAA,MAAM,WAAW,GAAI,OAAO,MAAM,sBAMjC,CAAC;AAEF,eAAe,WAAW,CAAC"}
@@ -1,3 +1,4 @@
1
+ import './CaseHistory.css';
1
2
  import React from 'react';
2
3
  import Timeline from './Timeline';
3
4
  const CaseHistory = (props) => {
@@ -17,15 +17,13 @@
17
17
  }
18
18
 
19
19
  .right-node {
20
+ white-space: nowrap;
20
21
  overflow: hidden;
21
22
  text-overflow: ellipsis;
22
23
  width: 100%;
23
24
  }
24
-
25
25
  .content-date-right-history {
26
- display: -webkit-box;
27
- -webkit-line-clamp: 2;
28
- -webkit-box-orient: vertical;
26
+ white-space: nowrap;
29
27
  overflow: hidden;
30
28
  text-overflow: ellipsis;
31
29
  }
@@ -164,6 +162,7 @@
164
162
  text-align: right;
165
163
  line-height: 30px;
166
164
  white-space: nowrap;
165
+ overflow: hidden;
167
166
  }
168
167
 
169
168
  .content-date-right-history {
@@ -320,20 +319,41 @@ ul#case-history-paginated-timeline {
320
319
  }
321
320
  }
322
321
 
323
- @media screen and (max-width: 850px) {
324
- .contentTimeline {
325
- padding: 16px 8px;
322
+ .timeline-highlight {
323
+ background-color: #fff3cd;
324
+ padding: 0;
325
+ margin: 0;
326
+ border-radius: 2px;
327
+ }
328
+
329
+ @media screen and (max-width: 768px) {
330
+ .timeline::after {
331
+ left: 20px;
332
+ }
333
+
334
+ .timeline-node {
335
+ flex-direction: column;
326
336
  }
327
337
 
328
- .content-date-left-history {
329
- font-size: 15px;
338
+ .left-node,
339
+ .right-node {
340
+ max-width: 100%;
341
+ padding: 0;
330
342
  }
331
343
 
332
- .content-time-left-history {
333
- font-size: 13px;
344
+ .timeline-avatar,
345
+ .timeline-marker {
346
+ left: 0%;
347
+ transform: translateX(-50%);
334
348
  }
335
349
 
336
- .content-date-right-history {
337
- font-size: 14px;
350
+ .right-node::before {
351
+ left: 20px;
352
+ border-width: 10px 10px 10px 0;
353
+ border-color: transparent white transparent transparent;
354
+ }
355
+
356
+ .contentTimeline {
357
+ margin-left: 40px;
338
358
  }
339
359
  }
@@ -1 +1 @@
1
- {"version":3,"file":"Timeline.d.ts","sourceRoot":"","sources":["../../../../../../src/components/CaseEditView/Tabs/CaseHistory/Timeline.tsx"],"names":[],"mappings":"AAAA,OAAO,gBAAgB,CAAC;AAwBxB,OAAO,KAAsC,MAAM,OAAO,CAAC;AA8W3D,QAAA,MAAM,QAAQ,GAAI;;CAAc,sBAmV/B,CAAC;AAEF,eAAe,QAAQ,CAAC"}
1
+ {"version":3,"file":"Timeline.d.ts","sourceRoot":"","sources":["../../../../../../src/components/CaseEditView/Tabs/CaseHistory/Timeline.tsx"],"names":[],"mappings":"AAAA,OAAO,gBAAgB,CAAC;AAwBxB,OAAO,KAAsC,MAAM,OAAO,CAAC;AA8W3D,QAAA,MAAM,QAAQ,GAAI;;CAAc,sBAkV/B,CAAC;AAEF,eAAe,QAAQ,CAAC"}
@@ -458,7 +458,7 @@ const Timeline = ({ caseNumber }) => {
458
458
  React.createElement("div", { className: "timelineMenu" },
459
459
  React.createElement(SearchInput, { placeholder: t('Search for a user, action, or keyword'), value: searchValue, onChange: handleSearchChange, onClear: handleClear, className: "case-history-timeline-search" }),
460
460
  React.createElement("div", { className: "case-history-timeline-datepicker" },
461
- React.createElement(DatePicker, { value: dateValue, invalidFormatText: t('Invalid date format.'), onChange: (_event, value) => handleDateChange(value), validators: [futureDateValidator] }),
461
+ React.createElement(DatePicker, { value: dateValue, onChange: (_event, value) => handleDateChange(value), validators: [futureDateValidator] }),
462
462
  React.createElement(Button, { className: "pf-v6-u-ml-xs", onClick: () => setDateValue(''), isDisabled: isEmpty(dateValue) },
463
463
  React.createElement(Trans, null, "Reset")))),
464
464
  React.createElement("div", { className: "timeline-controls" },
@@ -29,9 +29,9 @@ export const CaseSummary = (props) => {
29
29
  const [caseSummaryData, setCaseSummaryData] = useState(getApiResourceObject(null, true));
30
30
  const [caseSummaryState, setCaseSummaryState] = useState();
31
31
  const [errorMessage, setErrorMessage] = useState('');
32
- const { caseComments, caseLanguage } = useCaseSelector((state) => ({
33
- caseComments: state.caseDetails.comments,
32
+ const { caseLanguage, caseComments } = useCaseSelector((state) => ({
34
33
  caseLanguage: state.caseDetails.caseLanguage,
34
+ caseComments: state.caseDetails.comments,
35
35
  }), isEqual);
36
36
  const { globalMetadataState: { loggedInUserRights }, } = useContext(GlobalMetadataStateContext);
37
37
  const isInternal = (_b = (_a = loggedInUserRights === null || loggedInUserRights === void 0 ? void 0 : loggedInUserRights.data) === null || _a === void 0 ? void 0 : _a.isInternal) === null || _b === void 0 ? void 0 : _b.call(_a);
@@ -43,7 +43,7 @@ export const CaseSummary = (props) => {
43
43
  setIsFeedbackModalOpen(true);
44
44
  };
45
45
  useEffect(() => {
46
- if (caseLanguage === 'ru') {
46
+ if (caseLanguage !== 'en') {
47
47
  setCaseSummaryState(CaseSummaryStates.CASE_LANGUAGE_NOT_SUPPORTED);
48
48
  return;
49
49
  }
@@ -25,7 +25,7 @@ export function CaseSummaryErrorMessage(props) {
25
25
  'The AI is either currently unavailable or is processing case details or try reloading the page.';
26
26
  break;
27
27
  case 'case_language_not_supported':
28
- message = `The AI case summary is not available in this language. We're working on adding more languages soon.`;
28
+ message = `The AI case summary is available in English. We're working on adding more languages soon.`;
29
29
  break;
30
30
  case 'input_comments_too_large':
31
31
  message = `${shared} overall input comments text is too large.`;
@@ -112,6 +112,6 @@ const RelatedTasks = () => {
112
112
  React.createElement(Td, { dataLabel: columnNames.title }, item.title)))))),
113
113
  React.createElement("div", { className: "push-top" },
114
114
  React.createElement(Pagination, { itemCount: filteredData.length, perPage: itemsPerPage, page: currentPage, onSetPage: (_, page) => setCurrentPage(page), onPerPageSelect: (_, perPage) => setItemsPerPage(perPage) })))) : (React.createElement("div", null,
115
- React.createElement(EmptyState, { headingLevel: "h4", icon: CubesIcon, titleText: t("There aren't any related tasks"), variant: EmptyStateVariant.full })))));
115
+ React.createElement(EmptyState, { headingLevel: "h4", icon: CubesIcon, titleText: t("There aren't any related tasks."), variant: EmptyStateVariant.full })))));
116
116
  };
117
117
  export default RelatedTasks;
@@ -1 +1 @@
1
- {"version":3,"file":"CaseGroup.d.ts","sourceRoot":"","sources":["../../../../src/components/CaseInformation/CaseGroup.tsx"],"names":[],"mappings":"AAqBA,OAAO,KAAuD,MAAM,OAAO,CAAC;AAiB5E,UAAU,MAAM;IACZ,IAAI,CAAC,EAAE,OAAO,CAAC;CAClB;AAWD,iBAAS,SAAS,CAAC,KAAK,EAAE,MAAM,qBAkW/B;AAED,eAAe,SAAS,CAAC"}
1
+ {"version":3,"file":"CaseGroup.d.ts","sourceRoot":"","sources":["../../../../src/components/CaseInformation/CaseGroup.tsx"],"names":[],"mappings":"AAqBA,OAAO,KAAuD,MAAM,OAAO,CAAC;AAW5E,UAAU,MAAM;IACZ,IAAI,CAAC,EAAE,OAAO,CAAC;CAClB;AAWD,iBAAS,SAAS,CAAC,KAAK,EAAE,MAAM,qBAwV/B;AAED,eAAe,SAAS,CAAC"}
@@ -20,7 +20,7 @@ import { Trans, useTranslation } from 'react-i18next';
20
20
  import { useCaseDispatch, useCaseSelector } from '../../context/CaseContext';
21
21
  import { RouteContext } from '../../context/RouteContext';
22
22
  import { useCaseUpdateErrorMessage } from '../../hooks/useCaseUpdateErrorMessage';
23
- import { fetchCaseGroupsForAccount, fetchCaseGroupsForSSO, setCaseDetails, setSelectedCaseGroupUsers, updateCaseDetails, } from '../../reducers/CaseReducer';
23
+ import { setCaseDetails, setSelectedCaseGroupUsers, updateCaseDetails } from '../../reducers/CaseReducer';
24
24
  import { PDFContext } from '../CaseEditView/PDFContainer';
25
25
  import { CaseValuesToWatch } from '../shared/Constants';
26
26
  import { getChangedValueTooltip } from '../shared/utils';
@@ -168,16 +168,6 @@ function CaseGroup(props) {
168
168
  }
169
169
  // eslint-disable-next-line react-hooks/exhaustive-deps
170
170
  }, [ownersCaseGroups, caseNumber, isGroupMandatory]);
171
- useEffect(() => {
172
- if (loggedInUserRights.data.isInternal() && accountNumber) {
173
- // For internal users, use account number
174
- fetchCaseGroupsForAccount(caseDispatch, accountNumber);
175
- }
176
- else if (contactSSOName) {
177
- // For external users, use SSO username
178
- fetchCaseGroupsForSSO(caseDispatch, contactSSOName);
179
- }
180
- }, [accountNumber, caseDispatch, contactSSOName, loggedInUserRights.data]);
181
171
  const onCaseGroupClear = () => __awaiter(this, void 0, void 0, function* () {
182
172
  var _a;
183
173
  try {
@@ -1 +1 @@
1
- {"version":3,"file":"CaseInformation.d.ts","sourceRoot":"","sources":["../../../../src/components/CaseInformation/CaseInformation.tsx"],"names":[],"mappings":"AAWA,OAAO,KAAgC,MAAM,OAAO,CAAC;AAErD,OAAO,EAAE,mBAAmB,EAAE,MAAM,kBAAkB,CAAC;AAQvD,UAAU,MAAM;IACZ,UAAU,EAAE,mBAAmB,CAAC;CACnC;AAED,MAAM,CAAC,OAAO,UAAU,eAAe,CAAC,KAAK,EAAE,MAAM,qBAkHpD"}
1
+ {"version":3,"file":"CaseInformation.d.ts","sourceRoot":"","sources":["../../../../src/components/CaseInformation/CaseInformation.tsx"],"names":[],"mappings":"AAWA,OAAO,KAAgC,MAAM,OAAO,CAAC;AAErD,OAAO,EAAE,mBAAmB,EAAE,MAAM,kBAAkB,CAAC;AAQvD,UAAU,MAAM;IACZ,UAAU,EAAE,mBAAmB,CAAC;CACnC;AAED,MAAM,CAAC,OAAO,UAAU,eAAe,CAAC,KAAK,EAAE,MAAM,qBAiHpD"}
@@ -1,6 +1,6 @@
1
1
  import { AlertMessage, AlertType, LoadingIndicator } from '@rh-support/components';
2
2
  import { fetchCaseSeverities, fetchCaseTypes, fetchLanguageMetadata, GlobalMetadataDispatchContext, GlobalMetadataStateContext, } from '@rh-support/react-context';
3
- import { haventLoadedMetadata } from '@rh-support/utils';
3
+ import { canManageCase, haventLoadedMetadata } from '@rh-support/utils';
4
4
  import isEmpty from 'lodash/isEmpty';
5
5
  import isEqual from 'lodash/isEqual';
6
6
  import React, { useContext, useEffect } from 'react';
@@ -12,7 +12,7 @@ import KtQuestions from '../ImproveCase/KtQuestions';
12
12
  import ClusterRecommendations from '../Recommendations/ClusterRecommendations';
13
13
  export default function CaseInformation(props) {
14
14
  const { t } = useTranslation();
15
- const { globalMetadataState: { allCaseTypes, allCaseSeverities, caseLanguages, loggedInUser, loggedInUserJwtToken, loggedInUsersAccount, loggedInUserRights, }, } = useContext(GlobalMetadataStateContext);
15
+ const { globalMetadataState: { allCaseTypes, allCaseSeverities, caseLanguages, loggedInUser, loggedInUserJwtToken, loggedInUsersAccount, }, } = useContext(GlobalMetadataStateContext);
16
16
  const dispatchToGlobalMetadataReducer = useContext(GlobalMetadataDispatchContext);
17
17
  const { contactSSOName, selectedAccountDetails, ownersCaseGroups, hasInvalidEntitlements } = useCaseSelector((state) => ({
18
18
  contactSSOName: state.caseDetails.contactSSOName,
@@ -60,7 +60,7 @@ export default function CaseInformation(props) {
60
60
  return (React.createElement(React.Fragment, null,
61
61
  React.createElement(LoadingIndicator, { show: isMetadataLoading(), size: "lg" }),
62
62
  React.createElement(AlertMessage, { variant: AlertType.DANGER, className: "pf-v6-u-mt-lg", title: t("Sorry, we're having a problem gathering your information."), show: isMetadataLoadingError() }),
63
- React.createElement(AlertMessage, { show: !loggedInUserRights.data.canManageCases(), variant: AlertType.DANGER, className: "pf-v6-u-mt-lg" },
63
+ React.createElement(AlertMessage, { show: !canManageCase(loggedInUserJwtToken), variant: AlertType.DANGER, className: "pf-v6-u-mt-lg" },
64
64
  React.createElement(Trans, { i18nKey: "i18ManageCaseContactCustomerService" },
65
65
  "You need additional access to manage cases.\u00A0 Please contact",
66
66
  ' ',
@@ -75,7 +75,7 @@ export default function CaseInformation(props) {
75
75
  !hasInvalidEntitlements &&
76
76
  !isMetadataLoading() &&
77
77
  !isMetadataLoadingError() &&
78
- loggedInUserRights.data.canManageCases() && (React.createElement(React.Fragment, null,
78
+ canManageCase(loggedInUserJwtToken) && (React.createElement(React.Fragment, null,
79
79
  React.createElement("form", null,
80
80
  React.createElement(Hostname, null),
81
81
  React.createElement(OpenShiftClusterId, null),
@@ -1 +1 @@
1
- {"version":3,"file":"Description.d.ts","sourceRoot":"","sources":["../../../../src/components/CaseInformation/Description.tsx"],"names":[],"mappings":"AAOA,OAAO,KAAkD,MAAM,OAAO,CAAC;AAUvE,UAAU,MAAM;IACZ,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,kBAAkB,CAAC,EAAE,OAAO,CAAC;CAChC;AAED,MAAM,CAAC,OAAO,UAAU,WAAW,CAAC,KAAK,EAAE,MAAM,qBA+LhD"}
1
+ {"version":3,"file":"Description.d.ts","sourceRoot":"","sources":["../../../../src/components/CaseInformation/Description.tsx"],"names":[],"mappings":"AAOA,OAAO,KAAsC,MAAM,OAAO,CAAC;AAS3D,UAAU,MAAM;IACZ,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,kBAAkB,CAAC,EAAE,OAAO,CAAC;CAChC;AAED,MAAM,CAAC,OAAO,UAAU,WAAW,CAAC,KAAK,EAAE,MAAM,qBAsKhD"}
@@ -4,10 +4,9 @@ import OutlinedQuestionCircleIcon from '@patternfly/react-icons/dist/js/icons/ou
4
4
  import { InlineEdit, useBreakpoint } from '@rh-support/components';
5
5
  import isEmpty from 'lodash/isEmpty';
6
6
  import isEqual from 'lodash/isEqual';
7
- import React, { useContext, useEffect, useRef, useState } from 'react';
7
+ import React, { useEffect, useRef, useState } from 'react';
8
8
  import { Trans, useTranslation } from 'react-i18next';
9
9
  import { useCaseDispatch, useCaseSelector } from '../../context/CaseContext';
10
- import { RouteContext } from '../../context/RouteContext';
11
10
  import { useAB } from '../../hooks/useAB';
12
11
  import { CASE_DETAILS_ISSUE_LIMIT } from '../../reducers/CaseConstNTypes';
13
12
  import { getUpdatedDescription } from '../../reducers/CaseHelpers';
@@ -28,7 +27,6 @@ export default function Description(props) {
28
27
  summary: state.caseDetails.summary,
29
28
  }), isEqual);
30
29
  const caseDispatch = useCaseDispatch();
31
- const { routeState: { isNextBtnClickedToShowValidationError }, } = useContext(RouteContext);
32
30
  const breakPoint = useBreakpoint();
33
31
  const isLgScreenHeight = breakPoint.lgh; // min-height: 1100px
34
32
  const [isOpen, setIsOpen] = useState(false);
@@ -46,20 +44,6 @@ export default function Description(props) {
46
44
  const newDescription = getUpdatedDescription(ktQ1Local, environment, periodicityOfIssue, timeFramesAndUrgency, v3ClusterName);
47
45
  onCaseDetailsChange({ issue: ktQ1Local, description: newDescription });
48
46
  };
49
- useEffect(() => {
50
- if (isNextBtnClickedToShowValidationError && issue) {
51
- const newDescription = getUpdatedDescription(issue, environment, periodicityOfIssue, timeFramesAndUrgency, v3ClusterName);
52
- setCaseDetails(caseDispatch, { description: newDescription });
53
- }
54
- }, [
55
- isNextBtnClickedToShowValidationError,
56
- issue,
57
- environment,
58
- periodicityOfIssue,
59
- timeFramesAndUrgency,
60
- v3ClusterName,
61
- caseDispatch,
62
- ]);
63
47
  const handleTextAreaClick = () => {
64
48
  if (!hasShownPopover) {
65
49
  setIsOpen(true);
@@ -1 +1 @@
1
- {"version":3,"file":"Severity.d.ts","sourceRoot":"","sources":["../../../../src/components/CaseInformation/Severity.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,yCAAyC,CAAC;AAMvE,OAAO,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAa5D,OAAO,KAA0C,MAAM,OAAO,CAAC;AAW/D,UAAU,MAAO,SAAQ,gBAAgB;IACrC,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,gBAAgB,CAAC,EAAE,CAAC,WAAW,EAAE,OAAO,CAAC,YAAY,CAAC,KAAK,IAAI,CAAC;IAChE,oBAAoB,EAAE,OAAO,CAAC;CACjC;AASD,MAAM,WAAW,gBAAgB;IAC7B,QAAQ,EAAE,OAAO,CAAC;IAClB,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,cAAc,EAAE,MAAM,GAAG,GAAG,CAAC,OAAO,GAAG,GAAG,CAAC,OAAO,EAAE,CAAC;CACxD;AAED,iBAAS,QAAQ,CAAC,KAAK,EAAE,MAAM,qBA0Q9B;kBA1QQ,QAAQ;;;AA4QjB,eAAe,QAAQ,CAAC"}
1
+ {"version":3,"file":"Severity.d.ts","sourceRoot":"","sources":["../../../../src/components/CaseInformation/Severity.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,yCAAyC,CAAC;AAMvE,OAAO,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAa5D,OAAO,KAA0C,MAAM,OAAO,CAAC;AAW/D,UAAU,MAAO,SAAQ,gBAAgB;IACrC,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,gBAAgB,CAAC,EAAE,CAAC,WAAW,EAAE,OAAO,CAAC,YAAY,CAAC,KAAK,IAAI,CAAC;IAChE,oBAAoB,EAAE,OAAO,CAAC;CACjC;AASD,MAAM,WAAW,gBAAgB;IAC7B,QAAQ,EAAE,OAAO,CAAC;IAClB,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,cAAc,EAAE,MAAM,GAAG,GAAG,CAAC,OAAO,GAAG,GAAG,CAAC,OAAO,EAAE,CAAC;CACxD;AAED,iBAAS,QAAQ,CAAC,KAAK,EAAE,MAAM,qBAyQ9B;kBAzQQ,QAAQ;;;AA2QjB,eAAe,QAAQ,CAAC"}
@@ -160,7 +160,7 @@ function Severity(props) {
160
160
  ' ',
161
161
  React.createElement("a", { href: "/support/policy/severity", target: "_blank" },
162
162
  React.createElement(Trans, null, "Red Hat Support Severity Level Definitions"))), closeBtnAriaLabel: "Close" },
163
- React.createElement(QuestionCircleIcon, { color: "#5e40be", className: "pf-v6-u-ml-xs icon-size cursor-pointer", "aria-label": t(`Support Severity Level info`) }))),
163
+ React.createElement(QuestionCircleIcon, { className: "pf-v6-u-ml-xs icon-size cursor-pointer pf-v6-u-text-color-status-custom", "aria-label": t(`Support Severity Level info`) }))),
164
164
  "\u00A0",
165
165
  filteredSeverities.filter((s) => s.disabled).length !== 0 && (React.createElement(Tooltip, { position: TooltipPosition.top, content: React.createElement(Trans, null, "Only the enabled severity levels are supported for selected product and version.") },
166
166
  React.createElement(Icon, { size: "sm" },
@@ -1 +1 @@
1
- {"version":3,"file":"SupportLevel.d.ts","sourceRoot":"","sources":["../../../../src/components/CaseInformation/SupportLevel.tsx"],"names":[],"mappings":"AAKA,OAAO,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAI5D,OAAO,KAA0C,MAAM,OAAO,CAAC;AAM/D,UAAU,MAAO,SAAQ,gBAAgB;CAAG;AAO5C,iBAAS,YAAY,CAAC,KAAK,EAAE,MAAM,qBAoJlC;kBApJQ,YAAY;;;AAsJrB,eAAe,YAAY,CAAC"}
1
+ {"version":3,"file":"SupportLevel.d.ts","sourceRoot":"","sources":["../../../../src/components/CaseInformation/SupportLevel.tsx"],"names":[],"mappings":"AAKA,OAAO,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAI5D,OAAO,KAA0C,MAAM,OAAO,CAAC;AAM/D,UAAU,MAAO,SAAQ,gBAAgB;CAAG;AAO5C,iBAAS,YAAY,CAAC,KAAK,EAAE,MAAM,qBAmJlC;kBAnJQ,YAAY;;;AAqJrB,eAAe,YAAY,CAAC"}
@@ -97,7 +97,7 @@ function SupportLevel(props) {
97
97
  "Learn more about our",
98
98
  ' ',
99
99
  React.createElement("a", { href: "/support/offerings/production/sla", target: "_blank" }, "production support service level agreement"))), closeBtnAriaLabel: "Close" },
100
- React.createElement(QuestionCircleIcon, { color: "#5e40be", className: "pf-v6-u-ml-xs icon-size cursor-pointer", "aria-label": "Support Level Info" })),
100
+ React.createElement(QuestionCircleIcon, { className: "pf-v6-u-ml-xs icon-size cursor-pointer pf-v6-u-text-color-status-custom", "aria-label": "Support Level Info" })),
101
101
  React.createElement(SingleSelectDropdown, { ariaLabel: t('Select Support Level'), onSelect: onEntitlementChange, selected: getSelectedOption(), options: getDropdownOptions(), isDisabled: ownersEntitlements.isError || isEmpty(ownersEntitlements.data), isInvalid: isSupportLevelInValid, dataTrackingId: "get-support-supportLevel", placeholder: t('Select Support Level') }),
102
102
  isEmpty(ownersEntitlements.data) && (React.createElement("p", { className: "form-instructions" }, ownersEntitlements.isError ? t('Error loading support levels') : t('No active subscriptions')))));
103
103
  }
@@ -1 +1 @@
1
- {"version":3,"file":"NoClusterIDReasonSelector.d.ts","sourceRoot":"","sources":["../../../../src/components/CaseManagement/NoClusterIDReasonSelector.tsx"],"names":[],"mappings":"AAWA,OAAO,KAA0C,MAAM,OAAO,CAAC;AAM/D,UAAU,MAAM;IACZ,uBAAuB,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,IAAI,CAAC;IAClD,cAAc,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,IAAI,CAAC;IACzC,4BAA4B,EAAE,MAAM,CAAC;IACrC,iBAAiB,EAAE,MAAM,CAAC;IAC1B,SAAS,EAAE,OAAO,CAAC;IACnB,UAAU,EAAE,OAAO,CAAC;IACpB,UAAU,CAAC,EAAE,OAAO,CAAC;CACxB;AAED,QAAA,MAAM,yBAAyB,GAAI,OAAO,MAAM,sBAkK/C,CAAC;AAEF,OAAO,EAAE,yBAAyB,EAAE,CAAC"}
1
+ {"version":3,"file":"NoClusterIDReasonSelector.d.ts","sourceRoot":"","sources":["../../../../src/components/CaseManagement/NoClusterIDReasonSelector.tsx"],"names":[],"mappings":"AAWA,OAAO,KAA0C,MAAM,OAAO,CAAC;AAM/D,UAAU,MAAM;IACZ,uBAAuB,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,IAAI,CAAC;IAClD,cAAc,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,IAAI,CAAC;IACzC,4BAA4B,EAAE,MAAM,CAAC;IACrC,iBAAiB,EAAE,MAAM,CAAC;IAC1B,SAAS,EAAE,OAAO,CAAC;IACnB,UAAU,EAAE,OAAO,CAAC;IACpB,UAAU,CAAC,EAAE,OAAO,CAAC;CACxB;AAED,QAAA,MAAM,yBAAyB,GAAI,OAAO,MAAM,sBA4J/C,CAAC;AAEF,OAAO,EAAE,yBAAyB,EAAE,CAAC"}