@pega/react-sdk-overrides 0.25.1 → 0.25.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 (144) hide show
  1. package/lib/designSystemExtension/Banner/Banner.css +1 -1
  2. package/lib/designSystemExtension/Banner/Banner.tsx +7 -7
  3. package/lib/designSystemExtension/CaseSummaryFields/CaseSummaryFields.css +0 -1
  4. package/lib/designSystemExtension/CaseSummaryFields/CaseSummaryFields.tsx +52 -36
  5. package/lib/designSystemExtension/DetailsFields/DetailsFields.tsx +11 -13
  6. package/lib/designSystemExtension/FieldGroup/FieldGroup.tsx +8 -9
  7. package/lib/designSystemExtension/FieldGroupList/FieldGroupList.tsx +9 -9
  8. package/lib/designSystemExtension/FieldValueList/FieldValueList.tsx +7 -8
  9. package/lib/designSystemExtension/Operator/Operator.tsx +21 -19
  10. package/lib/designSystemExtension/Pulse/Pulse.tsx +1 -1
  11. package/lib/designSystemExtension/RichTextEditor/RichTextEditor.tsx +28 -3
  12. package/lib/designSystemExtension/WssQuickCreate/WssQuickCreate.css +4 -4
  13. package/lib/designSystemExtension/WssQuickCreate/WssQuickCreate.tsx +1 -1
  14. package/lib/field/AutoComplete/AutoComplete.tsx +1 -1
  15. package/lib/field/CancelAlert/CancelAlert.css +4 -4
  16. package/lib/field/CancelAlert/CancelAlert.tsx +6 -6
  17. package/lib/field/Checkbox/Checkbox.tsx +97 -4
  18. package/lib/field/Currency/Currency.tsx +3 -3
  19. package/lib/field/Currency/currency-utils.ts +1 -2
  20. package/lib/field/Date/Date.tsx +3 -7
  21. package/lib/field/DateTime/DateTime.tsx +3 -8
  22. package/lib/field/Decimal/Decimal.tsx +3 -5
  23. package/lib/field/Dropdown/Dropdown.tsx +5 -7
  24. package/lib/field/Email/Email.tsx +11 -13
  25. package/lib/field/Group/Group.tsx +7 -7
  26. package/lib/field/Integer/Integer.tsx +5 -7
  27. package/lib/field/Location/Location.tsx +256 -0
  28. package/lib/field/Location/config-ext.json +8 -0
  29. package/lib/field/Location/index.tsx +1 -0
  30. package/lib/field/ObjectReference/ObjectReference.tsx +235 -0
  31. package/lib/field/ObjectReference/index.tsx +1 -0
  32. package/lib/field/ObjectReference/utils.ts +111 -0
  33. package/lib/field/Percentage/Percentage.tsx +3 -7
  34. package/lib/field/Phone/Phone.tsx +7 -5
  35. package/lib/field/RadioButtons/RadioButtons.tsx +47 -2
  36. package/lib/field/RichText/RichText.tsx +1 -1
  37. package/lib/field/ScalarList/ScalarList.tsx +2 -3
  38. package/lib/field/SelectableCard/SelectableCard.tsx +175 -0
  39. package/lib/field/SelectableCard/index.tsx +1 -0
  40. package/lib/field/SelectableCard/utils.tsx +226 -0
  41. package/lib/field/SemanticLink/SemanticLink.tsx +160 -28
  42. package/lib/field/SemanticLink/utils.ts +1 -1
  43. package/lib/field/TextArea/TextArea.tsx +5 -7
  44. package/lib/field/TextContent/TextContent.tsx +1 -2
  45. package/lib/field/TextInput/TextInput.tsx +5 -7
  46. package/lib/field/Time/Time.tsx +3 -7
  47. package/lib/field/URL/URL.tsx +5 -7
  48. package/lib/field/UserReference/UserReference.tsx +1 -2
  49. package/lib/helpers/attachmentHelpers.ts +56 -35
  50. package/lib/helpers/common-utils.ts +2 -2
  51. package/lib/helpers/data_page.ts +0 -1
  52. package/lib/helpers/field-group-utils.ts +1 -1
  53. package/lib/helpers/formatters/CurrencyMap.ts +0 -2
  54. package/lib/helpers/simpleTableHelpers.ts +118 -6
  55. package/lib/helpers/utils.ts +8 -1
  56. package/lib/helpers/versionHelpers.ts +0 -1
  57. package/lib/infra/ActionButtons/ActionButtons.tsx +28 -21
  58. package/lib/infra/Assignment/Assignment.tsx +4 -4
  59. package/lib/infra/AssignmentCard/AssignmentCard.tsx +2 -2
  60. package/lib/infra/Containers/FlowContainer/FlowContainer.tsx +15 -94
  61. package/lib/infra/Containers/ModalViewContainer/ListViewActionButtons/ListViewActionButtons.tsx +1 -2
  62. package/lib/infra/Containers/ModalViewContainer/ModalViewContainer.tsx +3 -3
  63. package/lib/infra/Containers/ViewContainer/ViewContainer.tsx +4 -5
  64. package/lib/infra/Containers/container-helpers.ts +47 -1
  65. package/lib/infra/DashboardFilter/DashboardFilter.tsx +2 -4
  66. package/lib/infra/DashboardFilter/filterUtils.tsx +3 -4
  67. package/lib/infra/DeferLoad/DeferLoad.tsx +2 -4
  68. package/lib/infra/ErrorBoundary/ErrorBoundary.tsx +1 -3
  69. package/lib/infra/MultiStep/MultiStep.css +8 -8
  70. package/lib/infra/MultiStep/MultiStep.tsx +2 -2
  71. package/lib/infra/NavBar/NavBar.css +1 -1
  72. package/lib/infra/NavBar/NavBar.tsx +29 -27
  73. package/lib/infra/Reference/Reference.tsx +3 -4
  74. package/lib/infra/Region/Region.tsx +1 -1
  75. package/lib/infra/RootContainer/RootContainer.tsx +2 -3
  76. package/lib/infra/Stages/Stages.tsx +1 -1
  77. package/lib/infra/View/View.tsx +2 -2
  78. package/lib/template/AdvancedSearch/AdvancedSearch.tsx +0 -1
  79. package/lib/template/AdvancedSearch/SearchGroup/persistUtils.ts +3 -9
  80. package/lib/template/AdvancedSearch/SearchGroups/SearchGroups.tsx +3 -4
  81. package/lib/template/AdvancedSearch/SearchGroups/hooks.ts +1 -1
  82. package/lib/template/AppShell/AppShell.css +1 -1
  83. package/lib/template/AppShell/AppShell.tsx +6 -10
  84. package/lib/template/BannerPage/BannerPage.tsx +2 -2
  85. package/lib/template/CaseSummary/CaseSummary.tsx +2 -3
  86. package/lib/template/CaseView/CaseView.tsx +15 -21
  87. package/lib/template/CaseViewActionsMenu/CaseViewActionsMenu.tsx +1 -1
  88. package/lib/template/Confirmation/Confirmation.tsx +2 -3
  89. package/lib/template/DataReference/DataReference.tsx +9 -12
  90. package/lib/template/DataReference/SearchForm.tsx +6 -5
  91. package/lib/template/DataReference/{utils.js → utils.ts} +3 -3
  92. package/lib/template/DefaultForm/DefaultForm.tsx +3 -3
  93. package/lib/template/Details/Details/Details.tsx +11 -11
  94. package/lib/template/Details/DetailsSubTabs/DetailsSubTabs.tsx +2 -2
  95. package/lib/template/Details/DetailsThreeColumn/DetailsThreeColumn.tsx +11 -11
  96. package/lib/template/Details/DetailsTwoColumn/DetailsTwoColumn.tsx +11 -11
  97. package/lib/template/Details/DynamicTabs/DynamicTabs.tsx +1 -1
  98. package/lib/template/FieldGroupTemplate/FieldGroupTemplate.tsx +2 -3
  99. package/lib/template/InlineDashboard/InlineDashboard.tsx +14 -16
  100. package/lib/template/InlineDashboardPage/InlineDashboardPage.tsx +2 -2
  101. package/lib/template/ListPage/ListPage.tsx +1 -1
  102. package/lib/template/ListView/ListView.tsx +10 -22
  103. package/lib/template/ListView/hooks.ts +1 -5
  104. package/lib/template/ListView/utils.ts +1 -1
  105. package/lib/template/MultiReferenceReadOnly/MultiReferenceReadOnly.tsx +1 -1
  106. package/lib/template/NarrowWide/NarrowWide/NarrowWide.tsx +5 -5
  107. package/lib/template/NarrowWide/NarrowWideDetails/NarrowWideDetails.tsx +11 -11
  108. package/lib/template/NarrowWide/NarrowWideForm/NarrowWideForm.tsx +2 -2
  109. package/lib/template/NarrowWide/NarrowWidePage/NarrowWidePage.tsx +2 -2
  110. package/lib/template/OneColumn/OneColumn/OneColumn.tsx +7 -7
  111. package/lib/template/OneColumn/OneColumnPage/OneColumnPage.tsx +1 -1
  112. package/lib/template/OneColumn/OneColumnTab/OneColumnTab.tsx +2 -2
  113. package/lib/template/PromotedFilters/PromotedFilters.tsx +1 -2
  114. package/lib/template/SimpleTable/SimpleTable/SimpleTable.tsx +2 -3
  115. package/lib/template/SimpleTable/SimpleTableManual/SimpleTableManual.tsx +35 -32
  116. package/lib/template/SimpleTable/SimpleTableSelect/SimpleTableSelect.tsx +1 -1
  117. package/lib/template/SingleReferenceReadOnly/SingleReferenceReadOnly.tsx +1 -1
  118. package/lib/template/SubTabs/SubTabs.tsx +2 -2
  119. package/lib/template/TwoColumn/TwoColumn/TwoColumn.tsx +9 -10
  120. package/lib/template/TwoColumn/TwoColumnPage/TwoColumnPage.tsx +1 -1
  121. package/lib/template/TwoColumn/TwoColumnTab/TwoColumnTab.tsx +9 -10
  122. package/lib/template/WideNarrow/WideNarrow/WideNarrow.tsx +5 -5
  123. package/lib/template/WideNarrow/WideNarrowDetails/WideNarrowDetails.tsx +11 -11
  124. package/lib/template/WideNarrow/WideNarrowForm/WideNarrowForm.tsx +2 -2
  125. package/lib/template/WideNarrow/WideNarrowPage/WideNarrowPage.tsx +2 -2
  126. package/lib/template/WssNavBar/WssNavBar.css +1 -1
  127. package/lib/template/WssNavBar/WssNavBar.tsx +5 -5
  128. package/lib/widget/AppAnnouncement/AppAnnouncement.tsx +1 -1
  129. package/lib/widget/Attachment/Attachment.css +6 -8
  130. package/lib/widget/Attachment/Attachment.tsx +62 -58
  131. package/lib/widget/CaseHistory/CaseHistory.tsx +5 -5
  132. package/lib/widget/FileUtility/ActionButtonsForFileUtil/ActionButtonsForFileUtil.css +0 -14
  133. package/lib/widget/FileUtility/ActionButtonsForFileUtil/ActionButtonsForFileUtil.tsx +3 -3
  134. package/lib/widget/FileUtility/FileUtility/FileUtility.css +7 -6
  135. package/lib/widget/FileUtility/FileUtility/FileUtility.tsx +5 -7
  136. package/lib/widget/Followers/Followers.tsx +2 -4
  137. package/lib/widget/QuickCreate/QuickCreate.tsx +1 -2
  138. package/lib/widget/SummaryItem/SummaryItem.css +9 -11
  139. package/lib/widget/SummaryItem/SummaryItem.tsx +2 -2
  140. package/lib/widget/SummaryList/SummaryList.tsx +1 -1
  141. package/lib/widget/ToDo/ToDo.css +1 -13
  142. package/lib/widget/ToDo/ToDo.tsx +26 -26
  143. package/package.json +1 -1
  144. /package/lib/template/DataReference/{DataReferenceAdvancedSearchContext.js → DataReferenceAdvancedSearchContext.ts} +0 -0
@@ -1,19 +1,5 @@
1
- /* eslint-disable @typescript-eslint/no-shadow */
2
1
  import React, { useCallback, useEffect, useState } from 'react';
3
- import {
4
- Box,
5
- Button,
6
- Card,
7
- CardContent,
8
- CardHeader,
9
- Avatar,
10
- Typography,
11
- Badge,
12
- List,
13
- ListItem,
14
- ListItemText,
15
- ListItemSecondaryAction
16
- } from '@mui/material';
2
+ import { Box, Button, Card, CardContent, CardHeader, Avatar, Typography, Badge, List, ListItem, ListItemText } from '@mui/material';
17
3
  import Snackbar from '@mui/material/Snackbar';
18
4
  import IconButton from '@mui/material/IconButton';
19
5
  import CloseIcon from '@mui/icons-material/Close';
@@ -23,7 +9,7 @@ import makeStyles from '@mui/styles/makeStyles';
23
9
  import useMediaQuery from '@mui/material/useMediaQuery';
24
10
 
25
11
  import { Utils } from '@pega/react-sdk-components/lib/components/helpers/utils';
26
- import { PConnProps } from '@pega/react-sdk-components/lib/types/PConnProps';
12
+ import type { PConnProps } from '@pega/react-sdk-components/lib/types/PConnProps';
27
13
 
28
14
  import './ToDo.css';
29
15
 
@@ -64,10 +50,10 @@ interface ToDoProps extends PConnProps {
64
50
  // If any, enter additional props that only exist on this component
65
51
  datasource?: any;
66
52
  myWorkList?: any;
67
- // eslint-disable-next-line react/no-unused-prop-types
53
+
68
54
  caseInfoID?: string;
69
55
  headerText?: string;
70
- // eslint-disable-next-line react/no-unused-prop-types
56
+
71
57
  itemKey?: string;
72
58
  showTodoList?: boolean;
73
59
  type?: string;
@@ -111,6 +97,17 @@ const useStyles = makeStyles(theme => ({
111
97
  borderLeftColor: theme.palette.primary.light,
112
98
  padding: theme.spacing(1),
113
99
  margin: theme.spacing(1)
100
+ },
101
+ psdkTodoAssignmentStatus: {
102
+ backgroundColor: 'var(--app-neutral-light-color)',
103
+ borderRadius: '0.125rem',
104
+ color: theme.embedded.resolutionTextColor,
105
+ fontSize: '0.75rem',
106
+ fontWeight: 'bold',
107
+ lineHeight: 'calc(0.5rem * 2.5)',
108
+ height: 'calc(0.5rem * 2.5)',
109
+ padding: '0 0.5rem',
110
+ textTransform: 'uppercase'
114
111
  }
115
112
  }));
116
113
 
@@ -136,7 +133,7 @@ export default function ToDo(props: ToDoProps) {
136
133
  const [bShowMore, setBShowMore] = useState(true);
137
134
  const [showSnackbar, setShowSnackbar] = useState(false);
138
135
  const [snackbarMessage, setSnackbarMessage]: any = useState('');
139
- // eslint-disable-next-line @typescript-eslint/no-use-before-define
136
+
140
137
  const [assignments, setAssignments] = useState<any[]>(initAssignments());
141
138
 
142
139
  const thePConn = getPConnect();
@@ -192,7 +189,7 @@ export default function ToDo(props: ToDoProps) {
192
189
 
193
190
  function showToast(message: string) {
194
191
  const theMessage = `Assignment: ${message}`;
195
- // eslint-disable-next-line no-console
192
+
196
193
  console.error(theMessage);
197
194
  setSnackbarMessage(message);
198
195
  setShowSnackbar(true);
@@ -251,7 +248,6 @@ export default function ToDo(props: ToDoProps) {
251
248
  .openAssignment(id, classname, options)
252
249
  .then(() => {
253
250
  if (bLogging) {
254
- // eslint-disable-next-line no-console
255
251
  console.log(`openAssignment completed`);
256
252
  }
257
253
  })
@@ -290,7 +286,6 @@ export default function ToDo(props: ToDoProps) {
290
286
  );
291
287
  };
292
288
 
293
- // eslint-disable-next-line no-nested-ternary
294
289
  const getCount = () => (assignmentsSource ? assignmentsSource.length : type === CONSTS.WORKLIST ? count : 0);
295
290
 
296
291
  const toDoContent = (
@@ -347,13 +342,18 @@ export default function ToDo(props: ToDoProps) {
347
342
  <CardContent>
348
343
  <List>
349
344
  {assignments.map(assignment => (
350
- <ListItem key={getAssignmentId(assignment)} dense divider onClick={() => clickGo(assignment)}>
351
- <ListItemText primary={getAssignmentName(assignment)} secondary={getListItemComponent(assignment)} />
352
- <ListItemSecondaryAction>
345
+ <ListItem
346
+ key={getAssignmentId(assignment)}
347
+ dense
348
+ divider
349
+ onClick={() => clickGo(assignment)}
350
+ secondaryAction={
353
351
  <IconButton onClick={() => clickGo(assignment)} size='large'>
354
352
  <ArrowForwardIosOutlinedIcon />
355
353
  </IconButton>
356
- </ListItemSecondaryAction>
354
+ }
355
+ >
356
+ <ListItemText primary={getAssignmentName(assignment)} secondary={getListItemComponent(assignment)} />
357
357
  </ListItem>
358
358
  ))}
359
359
  </List>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pega/react-sdk-overrides",
3
- "version": "0.25.1",
3
+ "version": "0.25.3",
4
4
  "description": "React SDK - Code for overriding components",
5
5
  "_filesComment": "During packing, npm ignores everything NOT in the files list",
6
6
  "files": [