@rh-support/troubleshoot 2.4.5-beta.1 → 2.4.5-beta.3

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 (80) hide show
  1. package/lib/esm/components/CaseEditView/CaseDetailsTabs.js +2 -2
  2. package/lib/esm/components/CaseEditView/CaseOverview/CaseType.d.ts.map +1 -1
  3. package/lib/esm/components/CaseEditView/CaseOverview/CaseType.js +4 -18
  4. package/lib/esm/components/CaseEditView/CaseOverview/index.d.ts.map +1 -1
  5. package/lib/esm/components/CaseEditView/CaseOverview/index.js +2 -2
  6. package/lib/esm/components/CaseEditView/CaseSolutions/CaseSolutions.d.ts.map +1 -1
  7. package/lib/esm/components/CaseEditView/CaseSolutions/CaseSolutions.js +2 -4
  8. package/lib/esm/components/CaseEditView/Tabs/CaseDetails/CaseInternalStatus.d.ts.map +1 -1
  9. package/lib/esm/components/CaseEditView/Tabs/CaseDetails/CaseInternalStatus.js +1 -2
  10. package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/CaseDiscussion.d.ts.map +1 -1
  11. package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/CaseDiscussion.js +4 -6
  12. package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/CommentSearch.d.ts.map +1 -1
  13. package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/CommentSearch.js +2 -3
  14. package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/PostComment.d.ts.map +1 -1
  15. package/lib/esm/components/CaseEditView/Tabs/CaseDiscussion/PostComment.js +1 -4
  16. package/lib/esm/components/CaseEditView/Tabs/CaseHistory/Timeline.css +21 -95
  17. package/lib/esm/components/CaseEditView/Tabs/CaseHistory/Timeline.d.ts.map +1 -1
  18. package/lib/esm/components/CaseEditView/Tabs/CaseHistory/Timeline.js +137 -269
  19. package/lib/esm/components/CaseInformation/Fts.d.ts.map +1 -1
  20. package/lib/esm/components/CaseInformation/Fts.js +5 -6
  21. package/lib/esm/components/CaseManagement/Cep.d.ts.map +1 -1
  22. package/lib/esm/components/CaseManagement/Cep.js +2 -3
  23. package/lib/esm/components/CaseManagement/RHAssociatesSelector.d.ts.map +1 -1
  24. package/lib/esm/components/CaseManagement/RHAssociatesSelector.js +5 -11
  25. package/lib/esm/components/CaseManagement/SendNotifications/CaseContactSelector.d.ts.map +1 -1
  26. package/lib/esm/components/CaseManagement/SendNotifications/CaseContactSelector.js +5 -11
  27. package/lib/esm/components/Cve/CveItem.d.ts +8 -0
  28. package/lib/esm/components/Cve/CveItem.d.ts.map +1 -0
  29. package/lib/esm/components/Cve/CveItem.js +81 -0
  30. package/lib/esm/components/Cve/CveModal.d.ts +3 -0
  31. package/lib/esm/components/Cve/CveModal.d.ts.map +1 -0
  32. package/lib/esm/components/Cve/CveModal.js +40 -0
  33. package/lib/esm/components/Cve/CvePanel.d.ts +7 -0
  34. package/lib/esm/components/Cve/CvePanel.d.ts.map +1 -0
  35. package/lib/esm/components/Cve/CvePanel.js +23 -0
  36. package/lib/esm/components/Cve/CveSidebar.d.ts +3 -0
  37. package/lib/esm/components/Cve/CveSidebar.d.ts.map +1 -0
  38. package/lib/esm/components/Cve/CveSidebar.js +24 -0
  39. package/lib/esm/components/ProductSelector/ProductSelector.d.ts.map +1 -1
  40. package/lib/esm/components/ProductSelector/ProductSelector.js +4 -0
  41. package/lib/esm/components/Recommendations/AsideResults.d.ts.map +1 -1
  42. package/lib/esm/components/Recommendations/AsideResults.js +2 -4
  43. package/lib/esm/components/Recommendations/EARules/EARule.d.ts.map +1 -1
  44. package/lib/esm/components/Recommendations/EARules/EARule.js +2 -0
  45. package/lib/esm/components/Recommendations/EARules/EARuleInfoInline.d.ts.map +1 -1
  46. package/lib/esm/components/Recommendations/EARules/EARuleInfoInline.js +2 -2
  47. package/lib/esm/components/Recommendations/Recommendations.d.ts.map +1 -1
  48. package/lib/esm/components/Recommendations/Recommendations.js +22 -24
  49. package/lib/esm/components/Recommendations/RecommendationsLoader.d.ts +3 -0
  50. package/lib/esm/components/Recommendations/RecommendationsLoader.d.ts.map +1 -0
  51. package/lib/esm/components/Recommendations/RecommendationsLoader.js +11 -0
  52. package/lib/esm/components/SubmitCase/SubmitCase.js +3 -3
  53. package/lib/esm/components/Suggestions/TopContent.d.ts.map +1 -1
  54. package/lib/esm/components/Suggestions/TopContent.js +4 -1
  55. package/lib/esm/components/shared/fileUpload/fileSelectors/WidgetFileSelector.d.ts +2 -2
  56. package/lib/esm/components/shared/fileUpload/fileSelectors/WidgetFileSelector.d.ts.map +1 -1
  57. package/lib/esm/components/shared/fileUpload/fileSelectors/WidgetFileSelector.js +1 -10
  58. package/lib/esm/components/wizardLayout/WizardAside.d.ts.map +1 -1
  59. package/lib/esm/components/wizardLayout/WizardAside.js +5 -1
  60. package/lib/esm/components/wizardLayout/WizardLayout.d.ts.map +1 -1
  61. package/lib/esm/components/wizardLayout/WizardLayout.js +1 -4
  62. package/lib/esm/components/wizardLayout/WizardMain.d.ts.map +1 -1
  63. package/lib/esm/components/wizardLayout/WizardMain.js +0 -5
  64. package/lib/esm/components/wizardLayout/WizardNavigation.d.ts.map +1 -1
  65. package/lib/esm/components/wizardLayout/WizardNavigation.js +3 -7
  66. package/lib/esm/hooks/useFetchCVEData.d.ts +5 -0
  67. package/lib/esm/hooks/useFetchCVEData.d.ts.map +1 -0
  68. package/lib/esm/hooks/useFetchCVEData.js +101 -0
  69. package/lib/esm/models/caseCreationWorkflows.d.ts +25 -0
  70. package/lib/esm/models/caseCreationWorkflows.d.ts.map +1 -0
  71. package/lib/esm/models/caseCreationWorkflows.js +1 -0
  72. package/lib/esm/reducers/CaseConstNTypes.d.ts +3 -0
  73. package/lib/esm/reducers/CaseConstNTypes.d.ts.map +1 -1
  74. package/lib/esm/reducers/CaseConstNTypes.js +2 -0
  75. package/lib/esm/scss/_main.scss +20 -2
  76. package/lib/esm/scss/_pf-overrides.scss +0 -6
  77. package/lib/esm/utils/caseUtils.d.ts +6 -0
  78. package/lib/esm/utils/caseUtils.d.ts.map +1 -1
  79. package/lib/esm/utils/caseUtils.js +15 -0
  80. package/package.json +11 -11
@@ -20,7 +20,7 @@ const RMEEscalationList = React.lazy(() => import(/* webpackChunkName: 'RMEEscal
20
20
  export function CaseDetailsTabs(props) {
21
21
  const { caseNumber } = props;
22
22
  const { activeTab } = useParams();
23
- const { globalMetadataState: { loggedInUserRights, loggedInUsersAccount }, } = useContext(GlobalMetadataStateContext);
23
+ const { globalMetadataState: { loggedInUserRights }, } = useContext(GlobalMetadataStateContext);
24
24
  const { accountNumber, chats, comments, status } = useCaseSelector((state) => ({
25
25
  accountNumber: state.caseDetails.accountNumberRef,
26
26
  chats: state.caseDetails.chats,
@@ -104,7 +104,7 @@ export function CaseDetailsTabs(props) {
104
104
  routePath: 'escalation',
105
105
  component: (React.createElement(RMEEscalationList, { escalations: caseEscalations.data, caseNumber: caseNumber, caseStatus: status, accountNumber: loggedInUserRights.data.getAccountNumber(), isInternal: loggedInUserRights.data.isInternal() })),
106
106
  });
107
- !loggedInUsersAccount.data.secureSupport &&
107
+ false && //Don't add this component to 'tabsToRender' for now, pending QA release
108
108
  tabsToRender.push({
109
109
  'data-tracking-id': 'case-history-tab',
110
110
  title: CaseDetailsTabsEnum.HISTORY,
@@ -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,qBAoF9B;kBApFQ,QAAQ;;;AAuFjB,eAAe,QAAQ,CAAC"}
1
+ {"version":3,"file":"CaseType.d.ts","sourceRoot":"","sources":["../../../../../src/components/CaseEditView/CaseOverview/CaseType.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,gBAAgB,EAAW,MAAM,0BAA0B,CAAC;AAGrE,OAAO,KAA+B,MAAM,OAAO,CAAC;AAOpD,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,qBAsD9B;kBAtDQ,QAAQ;;;AAyDjB,eAAe,QAAQ,CAAC"}
@@ -7,9 +7,8 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
7
7
  step((generator = generator.apply(thisArg, _arguments || [])).next());
8
8
  });
9
9
  };
10
- import { Flex, FlexItem, MenuToggle, Select, SelectList, SelectOption, Spinner, } from '@patternfly/react-core';
11
- import { ValueChangedIcon } from '@rh-support/components';
12
- import { toOldCaseTypeSwitcher } from '@rh-support/utils';
10
+ import { Dropdown, ValueChangedIcon } from '@rh-support/components';
11
+ import { toOldCaseTypeSwitcher, toOption, toOptions } from '@rh-support/utils';
13
12
  import isEmpty from 'lodash/isEmpty';
14
13
  import React, { useContext, useState } from 'react';
15
14
  import { Trans, useTranslation } from 'react-i18next';
@@ -24,28 +23,16 @@ function CaseType(props) {
24
23
  const { t } = useTranslation();
25
24
  const [isCaseTypeInValid, setIsCaseTypeInValid] = useState(false);
26
25
  const { isExportingPDF } = useContext(PDFContext);
27
- const [isOpen, setIsOpen] = useState(false);
28
- const [selected, setSelected] = useState(props.selectedType);
29
- const onToggleClick = () => {
30
- setIsOpen(!isOpen);
31
- };
32
- const toggle = (toggleRef) => (React.createElement(MenuToggle, { ref: toggleRef, onClick: onToggleClick, isExpanded: isOpen, isDisabled: props.hasError || props.isDisabled || props.isFetching, isFullWidth: true, status: isCaseTypeInValid ? 'danger' : undefined, className: "case-type-selector-text" },
33
- React.createElement(Flex, { justifyContent: { default: 'justifyContentSpaceBetween' } },
34
- React.createElement(FlexItem, null,
35
- " ",
36
- selected || t(`Select a category`)),
37
- React.createElement(FlexItem, null, props.isFetching ? React.createElement(Spinner, { size: "md" }) : ''))));
38
26
  const validateCaseType = (selectedItem) => {
39
27
  setIsCaseTypeInValid(isEmpty(selectedItem));
40
28
  };
41
29
  const onCaseTypeChange = (option) => __awaiter(this, void 0, void 0, function* () {
42
- const switchedCaseType = toOldCaseTypeSwitcher(option);
30
+ const switchedCaseType = toOldCaseTypeSwitcher(option.value);
43
31
  if (switchedCaseType === props.selectedType) {
44
32
  return;
45
33
  }
46
34
  yield props.onTypeChange(switchedCaseType);
47
35
  setLocalTypeChange(true);
48
- setSelected(option);
49
36
  validateCaseType(option);
50
37
  });
51
38
  // value changed logic to show a non local type change
@@ -56,8 +43,7 @@ function CaseType(props) {
56
43
  React.createElement(Trans, null, "Support type"),
57
44
  React.createElement(ValueChangedIcon, { afterLocalChange: afterLocalChange, isLocalChange: localTypeChange, value: props.selectedType, getTooltipContent: getChangedValueTooltip(() => CaseValuesToWatch.type) }),
58
45
  React.createElement("span", { className: `form-required ${isExportingPDF ? 'hide-in-pdf' : ''}`, "aria-hidden": true }, "*")),
59
- 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 },
60
- React.createElement(SelectList, null, (props.allTypes || []).map((option) => (React.createElement(SelectOption, { value: option, key: option }, option)))))));
46
+ React.createElement(Dropdown, { name: "get-support-type", placeholder: t(`Select`), title: t(`Select a category`), list: toOptions(props.allTypes || []), selectedItem: toOption(props.selectedType), disabled: props.hasError || props.isDisabled, isLoadingList: props.isFetching, isInValid: isCaseTypeInValid, required: true, onChange: onCaseTypeChange, onOuterClick: validateCaseType, "data-tracking-id": "case-details-type-selector" })));
61
47
  }
62
48
  CaseType.defaultProps = defaultProps;
63
49
  export default CaseType;
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/components/CaseEditView/CaseOverview/index.tsx"],"names":[],"mappings":"AA8BA,OAAO,KAAkD,MAAM,OAAO,CAAC;AA4BvE,UAAU,MAAM;IACZ,UAAU,EAAE,MAAM,CAAC;IACnB,OAAO,EAAE,KAAK,CAAC,gBAAgB,CAAC,cAAc,CAAC,CAAC;CACnD;AAED,MAAM,CAAC,OAAO,UAAU,YAAY,CAAC,KAAK,EAAE,MAAM,qBA4fjD"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/components/CaseEditView/CaseOverview/index.tsx"],"names":[],"mappings":"AA8BA,OAAO,KAAkD,MAAM,OAAO,CAAC;AA4BvE,UAAU,MAAM;IACZ,UAAU,EAAE,MAAM,CAAC;IACnB,OAAO,EAAE,KAAK,CAAC,gBAAgB,CAAC,cAAc,CAAC,CAAC;CACnD;AAED,MAAM,CAAC,OAAO,UAAU,YAAY,CAAC,KAAK,EAAE,MAAM,qBAigBjD"}
@@ -12,7 +12,7 @@ import LockIcon from '@patternfly/react-icons/dist/js/icons/lock-icon';
12
12
  import { ToastNotification, useConfirmation } from '@rh-support/components';
13
13
  import { CloseCaseModal, fetchCaseSeverities, fetchCaseTypes, GlobalMetadataDispatchContext, GlobalMetadataStateContext, useCanEditCase, } from '@rh-support/react-context';
14
14
  import { AbilityContext, CaseDetailsFields, resourceActions, resources } from '@rh-support/user-permissions';
15
- import { dtmTrackEventCaseStepEncountered, haventLoadedMetadata, isOpenShiftOnlineProduct, PreviousCaseTypes, toNewCaseTypeMapper, toNewCaseTypeSwitcher, } from '@rh-support/utils';
15
+ import { dtmTrackEvent, haventLoadedMetadata, isOpenShiftOnlineProduct, PreviousCaseTypes, toNewCaseTypeMapper, toNewCaseTypeSwitcher, } from '@rh-support/utils';
16
16
  import isEqual from 'lodash/isEqual';
17
17
  import React, { useContext, useEffect, useRef, useState } from 'react';
18
18
  import { Trans, useTranslation } from 'react-i18next';
@@ -301,7 +301,7 @@ export default function CaseOverview(props) {
301
301
  yield updateStatusState(CaseStatusEnum.CLOSED);
302
302
  yield postCommentAfterStatusUpdate(commentBody);
303
303
  setShowCaseCloseModal(false);
304
- dtmTrackEventCaseStepEncountered('close', caseNumber, product, version);
304
+ dtmTrackEvent('case closed', 'case closed - case details page', caseNumber, `${product}|${version}`);
305
305
  }), isUpdating: (caseOverviewState.caseStatusUpdating && isCaseUpdating) || isPostingComment, onClose: () => {
306
306
  setShowCaseCloseModal(false);
307
307
  }, caseNumber: caseNumber })),
@@ -1 +1 @@
1
- {"version":3,"file":"CaseSolutions.d.ts","sourceRoot":"","sources":["../../../../../src/components/CaseEditView/CaseSolutions/CaseSolutions.tsx"],"names":[],"mappings":"AAmBA,OAAO,KAAsD,MAAM,OAAO,CAAC;AAuE3E,UAAU,MAAM;IACZ,UAAU,EAAE,MAAM,CAAC;IACnB,sBAAsB,EAAE,OAAO,CAAC;CACnC;AAUD,eAAO,MAAM,aAAa,+EAkhBxB,CAAC"}
1
+ {"version":3,"file":"CaseSolutions.d.ts","sourceRoot":"","sources":["../../../../../src/components/CaseEditView/CaseSolutions/CaseSolutions.tsx"],"names":[],"mappings":"AAmBA,OAAO,KAAsD,MAAM,OAAO,CAAC;AAuE3E,UAAU,MAAM;IACZ,UAAU,EAAE,MAAM,CAAC;IACnB,sBAAsB,EAAE,OAAO,CAAC;CACnC;AAUD,eAAO,MAAM,aAAa,+EAihBxB,CAAC"}
@@ -23,7 +23,7 @@ import { Accordion, AccordionContent, AccordionItem, AccordionToggle, Button, Mo
23
23
  import { PaginatedList, ToastNotification } from '@rh-support/components';
24
24
  import { useGlobalStateContext } from '@rh-support/react-context';
25
25
  import { AbilityContext, CaseDetailsFields, resourceActions, resources } from '@rh-support/user-permissions';
26
- import { getSolrParams } from '@rh-support/utils';
26
+ import { dtmTrackEventCaseDetailsSolutionDocs, getSolrParams } from '@rh-support/utils';
27
27
  import find from 'lodash/find';
28
28
  import isEqual from 'lodash/isEqual';
29
29
  import some from 'lodash/some';
@@ -163,9 +163,7 @@ export const CaseSolutions = forwardRef((props, ref) => {
163
163
  });
164
164
  const canPinUnpin = ability.can(resourceActions.PATCH, resources.CASE_DETAILS, CaseDetailsFields.CASE_DETAILS_PIN_UNPIN_RESOURCES);
165
165
  const canLinkUnlink = ability.can(resourceActions.PATCH, resources.CASE_DETAILS, CaseDetailsFields.CASE_DETAILS_LINK_UNLINK_RESOURCES);
166
- const addDtmEvent = (stepName) => {
167
- // reserve for when fixing dtm
168
- };
166
+ const addDtmEvent = (stepName) => dtmTrackEventCaseDetailsSolutionDocs(stepName, caseNumber, `${product}|${version}`);
169
167
  const updateRecommendations = (recommendationToUpdate, isPinned, isLinked) => () => __awaiter(void 0, void 0, void 0, function* () {
170
168
  try {
171
169
  setIsPinLoading((prevPiningMap) => (Object.assign(Object.assign({}, prevPiningMap), { [recommendationToUpdate.resourceId]: true })));
@@ -1 +1 @@
1
- {"version":3,"file":"CaseInternalStatus.d.ts","sourceRoot":"","sources":["../../../../../../src/components/CaseEditView/Tabs/CaseDetails/CaseInternalStatus.tsx"],"names":[],"mappings":"AAkBA,OAAO,KAA+C,MAAM,OAAO,CAAC;AAQpE,MAAM,CAAC,OAAO,UAAU,kBAAkB,sBAyFzC"}
1
+ {"version":3,"file":"CaseInternalStatus.d.ts","sourceRoot":"","sources":["../../../../../../src/components/CaseEditView/Tabs/CaseDetails/CaseInternalStatus.tsx"],"names":[],"mappings":"AAkBA,OAAO,KAA+C,MAAM,OAAO,CAAC;AAQpE,MAAM,CAAC,OAAO,UAAU,kBAAkB,sBAwFzC"}
@@ -30,8 +30,7 @@ export default function CaseInternalStatus() {
30
30
  const globalMetadataDispatchContext = useContext(GlobalMetadataDispatchContext);
31
31
  const [isOpen, setIsOpen] = useState(false);
32
32
  const [selected, setSelected] = useState(internalStatus);
33
- const onToggleClick = (e) => {
34
- e.stopPropagation();
33
+ const onToggleClick = () => {
35
34
  setIsOpen(!isOpen);
36
35
  };
37
36
  const toggle = (toggleRef) => (React.createElement(MenuToggle, { ref: toggleRef, onClick: onToggleClick, isExpanded: isOpen, isDisabled: isIStatusUpdating, isFullWidth: true, className: "case-internal-status-selector-text" },
@@ -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;AAsCzF,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,qBA8mBnD"}
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;AAa1G,OAAO,KAAoE,MAAM,OAAO,CAAC;AAsCzF,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,qBA4mBnD"}
@@ -12,7 +12,7 @@ import { MenuToggle, Select, SelectList, SelectOption } from '@patternfly/react-
12
12
  import { AlertMessage, AlertType, ErrorBoundary, LoadingIndicator, ToastNotification } from '@rh-support/components';
13
13
  import { useGlobalStateContext } from '@rh-support/react-context';
14
14
  import { AbilityContext, CaseDetailsFields, resourceActions, resources } from '@rh-support/user-permissions';
15
- import { dtmTrackEventCaseStepEncountered, getDropdownBtnPlaceholder, getUrlParsedParams, scrollIntoView, } from '@rh-support/utils';
15
+ import { dtmTrackEvent, getDropdownBtnPlaceholder, getUrlParsedParams, scrollIntoView } from '@rh-support/utils';
16
16
  import cloneDeep from 'lodash/cloneDeep';
17
17
  import filter from 'lodash/filter';
18
18
  import findIndex from 'lodash/findIndex';
@@ -171,7 +171,7 @@ export default function CaseDiscussion(props) {
171
171
  };
172
172
  const onCommentAdded = () => __awaiter(this, void 0, void 0, function* () {
173
173
  yield updateDiscussionStateComments(dispatchDiscussion, caseDispatch, caseNumber, allDiscussions, sort, caseFeedbacksHydra.data, discussionFiltersListState);
174
- dtmTrackEventCaseStepEncountered('comment', caseNumber, product, version);
174
+ dtmTrackEvent('case details page comment', 'comment', caseNumber, `${product}|${version}`);
175
175
  });
176
176
  const onAttachmentAdded = () => __awaiter(this, void 0, void 0, function* () {
177
177
  yield updateDiscussionStateAttachments(dispatchDiscussion, caseNumber, allDiscussions, sort, loggedInUsersAccount.data.secureSupport, discussionFiltersListState);
@@ -326,12 +326,10 @@ export default function CaseDiscussion(props) {
326
326
  }
327
327
  // eslint-disable-next-line react-hooks/exhaustive-deps
328
328
  }, [isPostingRemoteRequestCommentCompleted]);
329
- const onToggleClick = (e) => {
330
- e.stopPropagation();
329
+ const onToggleClick = () => {
331
330
  setIsOpen(!isOpen);
332
331
  };
333
- const onSortToggleClick = (e) => {
334
- e.stopPropagation();
332
+ const onSortToggleClick = () => {
335
333
  setIsSortOpen(!isSortOpen);
336
334
  };
337
335
  const onFilterSelect = (_event, prevOption) => {
@@ -1 +1 @@
1
- {"version":3,"file":"CommentSearch.d.ts","sourceRoot":"","sources":["../../../../../../src/components/CaseEditView/Tabs/CaseDiscussion/CommentSearch.tsx"],"names":[],"mappings":"AAOA,OAAO,KAAmB,MAAM,OAAO,CAAC;AAGxC,OAAO,EAAkB,WAAW,EAAE,MAAM,+CAA+C,CAAC;AAE5F,UAAU,MAAM;IACZ,eAAe,EAAE,WAAW,EAAE,CAAC;IAC/B,eAAe,CAAC,EAAE,CAAC,YAAY,EAAE,MAAM,EAAE,EAAE,WAAW,EAAE,MAAM,KAAK,IAAI,CAAC;IACxE,sBAAsB,EAAE,OAAO,CAAC;CACnC;AAED,wBAAgB,aAAa,CAAC,KAAK,EAAE,MAAM,qBAqG1C"}
1
+ {"version":3,"file":"CommentSearch.d.ts","sourceRoot":"","sources":["../../../../../../src/components/CaseEditView/Tabs/CaseDiscussion/CommentSearch.tsx"],"names":[],"mappings":"AAOA,OAAO,KAAmB,MAAM,OAAO,CAAC;AAGxC,OAAO,EAAkB,WAAW,EAAE,MAAM,+CAA+C,CAAC;AAE5F,UAAU,MAAM;IACZ,eAAe,EAAE,WAAW,EAAE,CAAC;IAC/B,eAAe,CAAC,EAAE,CAAC,YAAY,EAAE,MAAM,EAAE,EAAE,WAAW,EAAE,MAAM,KAAK,IAAI,CAAC;IACxE,sBAAsB,EAAE,OAAO,CAAC;CACnC;AAED,wBAAgB,aAAa,CAAC,KAAK,EAAE,MAAM,qBAoG1C"}
@@ -10,7 +10,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
10
10
  import { Button, TextInput } from '@patternfly/react-core';
11
11
  import TimesIcon from '@patternfly/react-icons/dist/js/icons/times-icon';
12
12
  import { humanizeSize } from '@rh-support/utils';
13
- import SearchApi from 'js-worker-search';
13
+ import SearchApi, { INDEX_MODES } from 'js-worker-search';
14
14
  import isEmpty from 'lodash/isEmpty';
15
15
  import React, { useState } from 'react';
16
16
  import { Trans, useTranslation } from 'react-i18next';
@@ -32,9 +32,8 @@ export function CommentSearch(props) {
32
32
  props.onCommentSearch([], '');
33
33
  return;
34
34
  }
35
- // Removing indexMode: INDEX_MODES.PREFIXES parameter from SearchAPI to match all sub-strings by default
36
- // Refer https://github.com/bvaughn/js-worker-search?tab=readme-ov-file#custom-index-mode
37
35
  const searchApi = new SearchApi({
36
+ indexMode: INDEX_MODES.PREFIXES,
38
37
  caseSensitive: false,
39
38
  matchAnyToken: true,
40
39
  });
@@ -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,qBA6iBxC"}
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,qBAyiBxC"}
@@ -209,10 +209,7 @@ export function PostComment(props) {
209
209
  const handleCheckboxToggle = () => {
210
210
  setIsPublic((publicComment) => !publicComment);
211
211
  };
212
- function isCommentSignatureMatch() {
213
- return commentText.trim() === commentSignature;
214
- }
215
- const isPostCommentDisabled = isProcessing || !commentText || isCommentSignatureMatch();
212
+ const isPostCommentDisabled = isProcessing || !commentText || isCommentTooLong;
216
213
  const isFileUploadDisabled = isConfirmedStateSideSupport && !cssCommentAgreed;
217
214
  const onFileUploadClick = () => {
218
215
  ToastNotification.addInfoMessage(t('Uploading Attachment(s)'));
@@ -5,38 +5,10 @@
5
5
  .timeline {
6
6
  position: relative;
7
7
  max-width: 100%;
8
- margin: 24px auto;
8
+ margin: 0 auto;
9
9
  padding: 0 20px;
10
10
  }
11
11
 
12
- .timeline-empty::after {
13
- display: none;
14
- }
15
- .timeline::before {
16
- bottom: var(--timeline-bottom, 0px);
17
- }
18
-
19
- .right-node {
20
- white-space: nowrap;
21
- overflow: hidden;
22
- text-overflow: ellipsis;
23
- width: 100%;
24
- }
25
- .content-date-right-history {
26
- white-space: nowrap;
27
- overflow: hidden;
28
- text-overflow: ellipsis;
29
- }
30
-
31
- .timelineMenu button.pf-v5-c-button.pf-m-primary {
32
- margin-bottom: 31px;
33
- }
34
-
35
- /* fixes a bug with datepicker month input being bigger than the day */
36
- .timelineMenu div.pf-v5-c-calendar-month__header-year span.pf-v5-c-form-control input {
37
- margin-bottom: -3px;
38
- }
39
-
40
12
  .timeline::after {
41
13
  content: '';
42
14
  position: absolute;
@@ -49,7 +21,7 @@
49
21
 
50
22
  /* This value is calculated in timeline.tsx */
51
23
  bottom: calc(var(--timeline-bottom) + var(--timeline-bottom-offset, 18.35%));
52
- left: calc(15% + 14.5px);
24
+ left: calc(13% + 13px);
53
25
  transform: translateX(-50%);
54
26
  }
55
27
 
@@ -73,49 +45,18 @@
73
45
  z-index: 1;
74
46
  }
75
47
 
76
- .timeline-controls {
77
- display: flex;
78
- justify-content: space-between;
79
- align-items: center;
80
- padding: 0.5rem 1rem;
81
- margin: 0 -0.8rem;
82
- }
83
-
84
- .timeline-pagination {
85
- flex-grow: 1;
86
- display: flex;
87
- align-items: center;
88
- }
89
- #options-menu-top-pagination {
90
- display: flex !important;
91
- flex-wrap: nowrap !important;
92
- }
93
- .timeline-sort-order-select {
94
- width: auto;
95
- margin-left: 1rem;
96
- }
97
-
98
- .timeline-controls:last-of-type {
99
- justify-content: flex-start;
100
- }
101
-
102
- .timeline-controls:last-of-type .timeline-pagination {
103
- flex-grow: 0;
104
- }
105
-
106
48
  .timeline-node {
107
49
  display: flex;
108
50
  justify-content: space-between;
109
51
  align-items: flex-start;
110
52
  position: relative;
111
- margin-bottom: 32px;
53
+ margin-bottom: 20px;
112
54
  min-height: 80px;
113
- max-height: 1em;
114
55
  }
115
56
 
116
57
  .timeline-avatar {
117
58
  position: absolute;
118
- left: calc(15% + 15px);
59
+ left: calc(13% + 13px);
119
60
  transform: translateX(-91%);
120
61
  top: 12px;
121
62
  z-index: 5;
@@ -128,17 +69,15 @@
128
69
  width: 10px;
129
70
  height: 10px;
130
71
  z-index: 2;
131
- left: calc(15% + 15px);
72
+ left: calc(13% + 13px);
132
73
  transform: translateX(-195%);
133
74
  top: 25px;
134
75
  }
135
76
 
136
77
  .left-node {
137
- flex: 0 0 15%;
138
- max-width: 20%;
78
+ flex: 0 0 13%;
79
+ max-width: 13%;
139
80
  padding-right: 24px;
140
- margin-left: -2em;
141
- margin-right: 24px;
142
81
  }
143
82
 
144
83
  .content-date-left-history {
@@ -157,9 +96,6 @@
157
96
  font-weight: 400;
158
97
  text-align: right;
159
98
  line-height: 30px;
160
- padding-left: 1em;
161
- white-space: nowrap;
162
- overflow: hidden;
163
99
  }
164
100
 
165
101
  .content-date-right-history {
@@ -185,27 +121,29 @@
185
121
  .right-node {
186
122
  flex-grow: 1;
187
123
  padding-left: 2.8%;
188
- margin-left: 1%;
189
124
  }
190
125
 
191
126
  .right-node::before {
192
127
  content: ' ';
193
- position: absolute;
128
+ height: 0;
129
+ position: relative;
130
+ display: list-item;
194
131
  top: 22.5px;
195
132
  width: 0;
196
- height: 0;
133
+ z-index: 1;
134
+ left: -0.5%;
197
135
  border: medium solid white;
198
- border-width: 7px 7px 7px 0;
199
- border-color: transparent white transparent transparent;
200
- transform: translateX(-100%);
136
+ border-width: 7px 0 7px 7px;
137
+ border-color: transparent transparent transparent white;
138
+ transform: rotate(180deg);
201
139
  }
202
140
 
203
141
  .internal.right-node::before {
204
- border-right-color: #ee0000;
142
+ border-color: transparent transparent transparent #ee0000;
205
143
  }
206
144
 
207
145
  .customer.right-node::before {
208
- border-right-color: #316dc1;
146
+ border-color: transparent transparent transparent #316dc1;
209
147
  }
210
148
 
211
149
  .timeline-internal {
@@ -230,9 +168,9 @@
230
168
 
231
169
  .contentTimeline {
232
170
  padding: 16px;
233
- /* position: absolute; */
171
+ position: absolute;
234
172
  border-radius: 3px;
235
- /* margin-bottom: 32px; */
173
+ margin-bottom: 32px;
236
174
  }
237
175
 
238
176
  .content-right-history {
@@ -241,7 +179,8 @@
241
179
  border-left-style: solid !important;
242
180
  border-radius: 3px;
243
181
  border: 1px solid #d2d2d2;
244
- width: 100%;
182
+ width: 80%;
183
+ top: 0rem;
245
184
  }
246
185
 
247
186
  .content-right-customer {
@@ -264,9 +203,6 @@ ul#case-history-paginated-timeline {
264
203
 
265
204
  .timelineMenu {
266
205
  display: flex;
267
- justify-content: space-between;
268
- align-items: center;
269
- margin-bottom: 1rem;
270
206
  }
271
207
 
272
208
  .case-history-timeline-datepicker {
@@ -288,16 +224,6 @@ ul#case-history-paginated-timeline {
288
224
  width: 93.2%;
289
225
  }
290
226
 
291
- @-moz-document url-prefix() {
292
- .timeline-controls {
293
- padding: 0.5rem 1rem;
294
- }
295
-
296
- #options-menu-top-pagination {
297
- width: 15em;
298
- }
299
- }
300
-
301
227
  @media screen and (max-width: 768px) {
302
228
  .timeline::after {
303
229
  left: 20px;
@@ -1 +1 @@
1
- {"version":3,"file":"Timeline.d.ts","sourceRoot":"","sources":["../../../../../../src/components/CaseEditView/Tabs/CaseHistory/Timeline.tsx"],"names":[],"mappings":"AAAA,OAAO,gBAAgB,CAAC;AA0BxB,OAAO,KAAsC,MAAM,OAAO,CAAC;AAgT3D,QAAA,MAAM,QAAQ;;uBAkUb,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,KAAuD,MAAM,OAAO,CAAC;AAkO5E,QAAA,MAAM,QAAQ;;uBAgRb,CAAC;AACF,eAAe,QAAQ,CAAC"}