@pega/dx-component-builder-sdk 0.8.2 → 0.23.2

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 (77) hide show
  1. package/package.json +1 -1
  2. package/src/constants.js +0 -1
  3. package/src/tasks/bundle/builderAngular/webpack.config.js +1 -2
  4. package/src/tasks/create/templates/SDK-React/field/Boolean/index.tsx.mustache +28 -25
  5. package/src/tasks/create/templates/SDK-React/field/Date/demo.stories.jsx.mustache +1 -1
  6. package/src/tasks/create/templates/SDK-React/field/DateTime/demo.stories.jsx.mustache +1 -1
  7. package/src/tasks/create/templates/SDK-React/field/Decimal/demo.stories.jsx.mustache +1 -0
  8. package/src/tasks/create/templates/SDK-React/field/Decimal-Currency/demo.stories.jsx.mustache +1 -1
  9. package/src/tasks/create/templates/SDK-React/template/DETAILS/demo.stories.jsx.mustache +1 -1
  10. package/src/tasks/create/templates/SDK-React/template/DETAILS/mock.stories.js.mustache +1 -1
  11. package/src/tasks/create/templates/SDK-React/template/DETAILS-region/demo.stories.jsx.mustache +1 -1
  12. package/src/tasks/create/templates/SDK-React/template/DETAILS-region/mock.stories.js.mustache +1 -1
  13. package/src/tasks/create/templates/SDK-React/template/FORM/demo.stories.jsx.mustache +1 -1
  14. package/src/tasks/create/templates/SDK-React/template/FORM/index.tsx.mustache +9 -10
  15. package/src/tasks/create/templates/SDK-React/template/FORM-region/demo.stories.jsx.mustache +1 -1
  16. package/src/tasks/create/templates/SDK-React/widget/PAGE-CASE/demo.stories.jsx.mustache +1 -1
  17. package/tests/assets/components/SDK-React/create/override-sdk/field/AutoComplete/AutoComplete.tsx +1 -1
  18. package/tests/assets/components/SDK-React/create/override-sdk/field/Checkbox/Checkbox.tsx +27 -25
  19. package/tests/assets/components/SDK-React/create/override-sdk/field/Currency/Currency.tsx +1 -1
  20. package/tests/assets/components/SDK-React/create/override-sdk/field/Date/Date.tsx +1 -1
  21. package/tests/assets/components/SDK-React/create/override-sdk/field/DateTime/DateTime.tsx +1 -1
  22. package/tests/assets/components/SDK-React/create/override-sdk/field/Decimal/Decimal.tsx +1 -1
  23. package/tests/assets/components/SDK-React/create/override-sdk/field/Dropdown/Dropdown.tsx +15 -14
  24. package/tests/assets/components/SDK-React/create/override-sdk/field/RadioButtons/RadioButtons.tsx +9 -8
  25. package/tests/assets/components/SDK-React/create/override-sdk/field/TextInput/TextInput.tsx +1 -1
  26. package/tests/assets/components/SDK-React/create/override-sdk/infra/Assignment/Assignment.tsx +18 -15
  27. package/tests/assets/components/SDK-React/create/override-sdk/infra/ErrorBoundary/ErrorBoundary.tsx +1 -1
  28. package/tests/assets/components/SDK-React/create/override-sdk/template/AppShell/AppShell.tsx +1 -1
  29. package/tests/assets/components/SDK-React/create/override-sdk/template/CaseSummary/CaseSummary.tsx +3 -1
  30. package/tests/assets/components/SDK-React/create/override-sdk/template/InlineDashboardPage/InlineDashboardPage.tsx +1 -1
  31. package/tests/assets/components/SDK-React/create/override-sdk/template/PromotedFilters/PromotedFilters.tsx +13 -11
  32. package/tests/assets/components/SDK-React/create/override-sdk/template/SimpleTable/SimpleTable.tsx +9 -9
  33. package/tests/assets/components/SDK-React/create/override-sdk/template/SimpleTableManual/SimpleTableManual.tsx +1 -1
  34. package/tests/assets/components/SDK-React/create/override-sdk/widget/Attachment/Attachment.tsx +2 -2
  35. package/tests/assets/components/SDK-React/createAll/custom-sdk/field/Pega_DXIL_MyBoolean/index.tsx +28 -25
  36. package/tests/assets/components/SDK-React/createAll/custom-sdk/field/Pega_DXIL_MyCurrency/demo.stories.jsx +1 -1
  37. package/tests/assets/components/SDK-React/createAll/custom-sdk/field/Pega_DXIL_MyDate/demo.stories.jsx +1 -1
  38. package/tests/assets/components/SDK-React/createAll/custom-sdk/field/Pega_DXIL_MyDateTime/demo.stories.jsx +1 -1
  39. package/tests/assets/components/SDK-React/createAll/custom-sdk/field/Pega_DXIL_MyDecimal/demo.stories.jsx +1 -0
  40. package/tests/assets/components/SDK-React/createAll/custom-sdk/template/Pega_DXIL_MyDetails/demo.stories.jsx +1 -1
  41. package/tests/assets/components/SDK-React/createAll/custom-sdk/template/Pega_DXIL_MyDetails/mock.stories.js +1 -1
  42. package/tests/assets/components/SDK-React/createAll/custom-sdk/template/Pega_DXIL_MyForm/demo.stories.jsx +1 -1
  43. package/tests/assets/components/SDK-React/createAll/custom-sdk/template/Pega_DXIL_MyForm/index.tsx +9 -10
  44. package/tests/assets/components/SDK-React/createAll/custom-sdk/template/Pega_DXIL_MyTwoColumnDetails/demo.stories.jsx +1 -1
  45. package/tests/assets/components/SDK-React/createAll/custom-sdk/template/Pega_DXIL_MyTwoColumnDetails/mock.stories.js +1 -1
  46. package/tests/assets/components/SDK-React/createAll/custom-sdk/template/Pega_DXIL_MyTwoColumnForm/demo.stories.jsx +1 -1
  47. package/tests/assets/components/SDK-React/createAll/custom-sdk/widget/Pega_DXIL_MyPageCaseWidget/demo.stories.jsx +1 -1
  48. package/tests/assets/components/SDK-React/createAll/override-sdk/field/AutoComplete/AutoComplete.tsx +1 -1
  49. package/tests/assets/components/SDK-React/createAll/override-sdk/field/Checkbox/Checkbox.tsx +27 -25
  50. package/tests/assets/components/SDK-React/createAll/override-sdk/field/Currency/Currency.tsx +1 -1
  51. package/tests/assets/components/SDK-React/createAll/override-sdk/field/Date/Date.tsx +1 -1
  52. package/tests/assets/components/SDK-React/createAll/override-sdk/field/DateTime/DateTime.tsx +1 -1
  53. package/tests/assets/components/SDK-React/createAll/override-sdk/field/Decimal/Decimal.tsx +1 -1
  54. package/tests/assets/components/SDK-React/createAll/override-sdk/field/Dropdown/Dropdown.tsx +15 -14
  55. package/tests/assets/components/SDK-React/createAll/override-sdk/field/RadioButtons/RadioButtons.tsx +9 -8
  56. package/tests/assets/components/SDK-React/createAll/override-sdk/field/ScalarList/ScalarList.tsx +2 -2
  57. package/tests/assets/components/SDK-React/createAll/override-sdk/field/ScalarList/config-ext.json +7 -22
  58. package/tests/assets/components/SDK-React/createAll/override-sdk/field/TextInput/TextInput.tsx +1 -1
  59. package/tests/assets/components/SDK-React/createAll/override-sdk/infra/Assignment/Assignment.tsx +18 -15
  60. package/tests/assets/components/SDK-React/createAll/override-sdk/infra/DashboardFilter/DashboardFilter.tsx +1 -1
  61. package/tests/assets/components/SDK-React/createAll/override-sdk/infra/DashboardFilter/filterUtils.tsx +2 -1
  62. package/tests/assets/components/SDK-React/createAll/override-sdk/infra/ErrorBoundary/ErrorBoundary.tsx +1 -1
  63. package/tests/assets/components/SDK-React/createAll/override-sdk/template/AppShell/AppShell.tsx +1 -1
  64. package/tests/assets/components/SDK-React/createAll/override-sdk/template/CaseSummary/CaseSummary.tsx +3 -1
  65. package/tests/assets/components/SDK-React/createAll/override-sdk/template/DataReference/DataReference.tsx +36 -34
  66. package/tests/assets/components/SDK-React/createAll/override-sdk/template/Details/Details.tsx +1 -1
  67. package/tests/assets/components/SDK-React/createAll/override-sdk/template/DetailsThreeColumn/DetailsThreeColumn.tsx +1 -1
  68. package/tests/assets/components/SDK-React/createAll/override-sdk/template/DetailsTwoColumn/DetailsTwoColumn.tsx +1 -1
  69. package/tests/assets/components/SDK-React/createAll/override-sdk/template/InlineDashboardPage/InlineDashboardPage.tsx +1 -1
  70. package/tests/assets/components/SDK-React/createAll/override-sdk/template/MultiReferenceReadOnly/MultiReferenceReadOnly.tsx +1 -1
  71. package/tests/assets/components/SDK-React/createAll/override-sdk/template/NarrowWideDetails/NarrowWideDetails.tsx +1 -1
  72. package/tests/assets/components/SDK-React/createAll/override-sdk/template/PromotedFilters/PromotedFilters.tsx +13 -11
  73. package/tests/assets/components/SDK-React/createAll/override-sdk/template/SimpleTable/SimpleTable.tsx +9 -9
  74. package/tests/assets/components/SDK-React/createAll/override-sdk/template/SimpleTableManual/SimpleTableManual.tsx +1 -1
  75. package/tests/assets/components/SDK-React/createAll/override-sdk/template/SingleReferenceReadOnly/SingleReferenceReadOnly.tsx +1 -2
  76. package/tests/assets/components/SDK-React/createAll/override-sdk/template/WideNarrowDetails/WideNarrowDetails.tsx +3 -3
  77. package/tests/assets/components/SDK-React/createAll/override-sdk/widget/Attachment/Attachment.tsx +2 -2
@@ -10,36 +10,39 @@ import handleEvent from '@pega/react-sdk-components/lib/components/helpers/event
10
10
  // import PropTypes from 'prop-types';
11
11
  import FieldValueList from '@pega/react-sdk-components/lib/components/designSystemExtension/FieldValueList';
12
12
  import StyledPegaDxilMyBooleanWrapper from './styles';
13
- import type { PConnProps } from '@pega/react-sdk-components/lib/types/PConnProps';
14
-
15
- interface PegaDxilMyBooleanProps extends PConnProps {
16
- // If any, enter additional props that only exist on this componentName
17
- // Everything from PConnFieldProps except value and change type of value to boolean
18
-
19
- value?: boolean,
20
- label: string,
21
- required: boolean,
22
- disabled: boolean,
23
- validatemessage: string,
24
- status?: string,
25
- // eslint-disable-next-line react/no-unused-prop-types
26
- onChange: any,
27
- // eslint-disable-next-line react/no-unused-prop-types
28
- onBlur?: any,
29
- readOnly: boolean,
30
- testId: string,
31
- helperText: string,
32
- displayMode?: string,
33
- hideLabel: boolean,
34
- // eslint-disable-next-line react/no-unused-prop-types
35
- placeholder?: string
36
- }
13
+ // import type { PConnProps } from '@pega/react-sdk-components/lib/types/PConnProps';
14
+
15
+ // Checkbox passes in 'value' as a boolean. So can't use the default
16
+ // PConnFieldProps since it expects value to be a string.
17
+ // But can't use PegaDxilMyBooleanProps until getValidationApi() knows about validate method
18
+ // interface PegaDxilMyBooleanProps extends PConnProps {
19
+ // // If any, enter additional props that only exist on this componentName
20
+ // // Everything from PConnFieldProps except value and change type of value to boolean
21
+ //
22
+ // value?: boolean,
23
+ // label: string,
24
+ // required: boolean,
25
+ // disabled: boolean,
26
+ // validatemessage: string,
27
+ // status?: string,
28
+ // // eslint-disable-next-line react/no-unused-prop-types
29
+ // onChange: any,
30
+ // // eslint-disable-next-line react/no-unused-prop-types
31
+ // onBlur?: any,
32
+ // readOnly: boolean,
33
+ // testId: string,
34
+ // helperText: string,
35
+ // displayMode?: string,
36
+ // hideLabel: boolean,
37
+ // // eslint-disable-next-line react/no-unused-prop-types
38
+ // placeholder?: string
39
+ // }
37
40
 
38
41
  // Duplicated runtime code from React SDK
39
42
 
40
43
  // props passed in combination of props from property panel (config.json) and run time props from Constellation
41
44
  // any default values in config.pros should be set in defaultProps at bottom of this file
42
- export default function PegaDxilMyBoolean(props: PegaDxilMyBooleanProps) {
45
+ export default function PegaDxilMyBoolean(props /* : PegaDxilMyBooleanProps */) {
43
46
  const {
44
47
  getPConnect,
45
48
  label,
@@ -66,4 +66,4 @@ export const BasePegaDxilMyCurrency = () => {
66
66
  <PegaDxilMyCurrency {...props} />
67
67
  </>
68
68
  );
69
- };
69
+ };
@@ -61,4 +61,4 @@ export const BasePegaDxilMyDate = () => {
61
61
  <PegaDxilMyDate {...props} />
62
62
  </>
63
63
  );
64
- };
64
+ };
@@ -59,4 +59,4 @@ export const BasePegaDxilMyDateTime = () => {
59
59
  <PegaDxilMyDateTime {...props} />
60
60
  </>
61
61
  );
62
- };
62
+ };
@@ -52,3 +52,4 @@ export const BasePegaDxilMyDecimal = () => {
52
52
  </>
53
53
  );
54
54
  };
55
+
@@ -71,4 +71,4 @@ export const BasePegaDxilMyDetails = () => {
71
71
  <PegaDxilMyDetails {...props}></PegaDxilMyDetails>
72
72
  </>
73
73
  );
74
- };
74
+ };
@@ -346,4 +346,4 @@ export const regionChildrenResolved = [
346
346
  ],
347
347
  displayMode: "LABELS_LEFT",
348
348
  },
349
- ];
349
+ ];
@@ -251,4 +251,4 @@ export const BasePegaDxilMyForm = () => {
251
251
  <PegaDxilMyForm {...props}></PegaDxilMyForm>
252
252
  </>
253
253
  );
254
- };
254
+ };
@@ -2,27 +2,26 @@ import React, { createElement } from 'react';
2
2
 
3
3
  import { getInstructions } from './utils';
4
4
  import createPConnectComponent from '@pega/react-sdk-components/lib/bridge/react_pconnect';
5
- // import type { PConnProps } from '@pega/react-sdk-components/lib/types/PConnProps';
5
+ import type { PConnProps } from '@pega/react-sdk-components/lib/types/PConnProps';
6
6
 
7
7
  import './DefaultForm.css';
8
8
 
9
9
  import StyledPegaDxilMyFormWrapper from "./styles";
10
10
 
11
- // Can't use PegaDxilMyFormProps until getPConnect().getChildren()[0] is fixed
12
- // interface PegaDxilMyFormProps extends PConnProps {
13
- // // If any, enter additional props that only exist on this componentName
14
- // NumCols?: string,
15
- // instructions?: string,
16
- // // eslint-disable-next-line react/no-unused-prop-types
17
- // children: Array<any>
18
- // }
11
+ interface PegaDxilMyFormProps extends PConnProps {
12
+ // If any, enter additional props that only exist on this componentName
13
+ NumCols?: string,
14
+ instructions?: string,
15
+ // eslint-disable-next-line react/no-unused-prop-types
16
+ children: Array<any>
17
+ }
19
18
 
20
19
 
21
20
  // Duplicated runtime code from React SDK
22
21
 
23
22
  // props passed in combination of props from property panel (config.json) and run time props from Constellation
24
23
  // any default values in config.pros should be set in defaultProps at bottom of this file
25
- export default function PegaDxilMyForm(props /* : PegaDxilMyFormProps */) {
24
+ export default function PegaDxilMyForm(props: PegaDxilMyFormProps) {
26
25
  const { getPConnect, NumCols = '1' } = props;
27
26
  const instructions = getInstructions(getPConnect(), props.instructions);
28
27
 
@@ -73,4 +73,4 @@ export const BaseYourOrgRequiredDxilDetailsRegion = () => {
73
73
  ></PegaDxilMyTwoColumnDetails>
74
74
  </>
75
75
  );
76
- };
76
+ };
@@ -247,4 +247,4 @@ export const pyReviewRaw = {
247
247
  },
248
248
  ],
249
249
  classID: "MyCo-MyCompon-Work-MyComponents",
250
- };
250
+ };
@@ -177,4 +177,4 @@ export const BasePegaDxilMyTwoColumnForm = () => {
177
177
  </PegaDxilMyTwoColumnForm>
178
178
  </>
179
179
  );
180
- };
180
+ };
@@ -49,4 +49,4 @@ export const BasePegaDxilMyPageCaseWidget = () => {
49
49
  <PegaDxilMyPageCaseWidget {...props} />
50
50
  </>
51
51
  );
52
- };
52
+ };
@@ -81,7 +81,7 @@ export default function AutoComplete(props:AutoCompleteProps) {
81
81
 
82
82
  const thePConn = getPConnect();
83
83
  const actionsApi = thePConn.getActionsApi();
84
- const propName = thePConn.getStateProps().value;
84
+ const propName = thePConn.getStateProps()["value"];
85
85
 
86
86
  if (!isDeepEqual(datasource, theDatasource)) {
87
87
  // inbound datasource is different, so update theDatasource (to trigger useEffect)
@@ -8,34 +8,36 @@ import {
8
8
  } from '@material-ui/core';
9
9
  import handleEvent from '@pega/react-sdk-components/lib/components/helpers/event-utils';
10
10
  import FieldValueList from '@pega/react-sdk-components/lib/components/designSystemExtension/FieldValueList';
11
- import type { PConnProps } from '@pega/react-sdk-components/lib/types/PConnProps';
11
+ // import type { PConnProps } from '../../../types/PConnProps';
12
12
 
13
13
  // Checkbox passes in 'value' as a boolean. So can't use the default
14
14
  // PConnFieldProps since it expects value to be a string.
15
- interface CheckboxProps extends PConnProps {
16
- // If any, enter additional props that only exist on Checkbox here
17
- // Everything from PConnFieldProps except value and change type of value to boolean
15
+ // But can't use CheckBoxProps until getValidationApi() knows about validate method
16
+ // Currently just thinks that returns an "object"
17
+ // interface CheckboxProps extends PConnProps {
18
+ // // If any, enter additional props that only exist on Checkbox here
19
+ // // Everything from PConnFieldProps except value and change type of value to boolean
18
20
 
19
- value?: boolean,
20
- label: string,
21
- required: boolean,
22
- disabled: boolean,
23
- validatemessage: string,
24
- status?: string,
25
- // eslint-disable-next-line react/no-unused-prop-types
26
- onChange: any,
27
- // eslint-disable-next-line react/no-unused-prop-types
28
- onBlur?: any,
29
- readOnly: boolean,
30
- testId: string,
31
- helperText: string,
32
- displayMode?: string,
33
- hideLabel: boolean,
34
- // eslint-disable-next-line react/no-unused-prop-types
35
- placeholder?: string
36
- }
21
+ // value?: boolean,
22
+ // label: string,
23
+ // required: boolean,
24
+ // disabled: boolean,
25
+ // validatemessage: string,
26
+ // status?: string,
27
+ // // eslint-disable-next-line react/no-unused-prop-types
28
+ // onChange: any,
29
+ // // eslint-disable-next-line react/no-unused-prop-types
30
+ // onBlur?: any,
31
+ // readOnly: boolean,
32
+ // testId: string,
33
+ // helperText: string,
34
+ // displayMode?: string,
35
+ // hideLabel: boolean,
36
+ // // eslint-disable-next-line react/no-unused-prop-types
37
+ // placeholder?: string
38
+ // }
37
39
 
38
- export default function CheckboxComponent(props: CheckboxProps) {
40
+ export default function CheckboxComponent(props /* : CheckboxProps */) {
39
41
  const {
40
42
  getPConnect,
41
43
  label,
@@ -54,9 +56,9 @@ export default function CheckboxComponent(props: CheckboxProps) {
54
56
 
55
57
  const thePConn = getPConnect();
56
58
  const theConfigProps = thePConn.getConfigProps();
57
- const { caption } = theConfigProps;
59
+ const caption = theConfigProps["caption"];
58
60
  const actionsApi = thePConn.getActionsApi();
59
- const propName = thePConn.getStateProps().value;
61
+ const propName = thePConn.getStateProps()["value"];
60
62
 
61
63
  const [checked, setChecked] = useState(false);
62
64
  useEffect(() => {
@@ -35,7 +35,7 @@ export default function Currency(props:CurrrencyProps) {
35
35
 
36
36
  const pConn = getPConnect();
37
37
  const actions = pConn.getActionsApi();
38
- const propName = pConn.getStateProps().value;
38
+ const propName = pConn.getStateProps()["value"];
39
39
  const helperTextToDisplay = validatemessage || helperText;
40
40
 
41
41
  // console.log(`Currency: label: ${label} value: ${value}`);
@@ -37,7 +37,7 @@ export default function Date(props:DateProps) {
37
37
 
38
38
  const pConn = getPConnect();
39
39
  const actions = pConn.getActionsApi();
40
- const propName = pConn.getStateProps().value;
40
+ const propName = pConn.getStateProps()["value"];
41
41
  const helperTextToDisplay = validatemessage || helperText;
42
42
 
43
43
  // Start with default dateFormatInfo
@@ -31,7 +31,7 @@ export default function DateTime(props: DateTimeProps) {
31
31
 
32
32
  const pConn = getPConnect();
33
33
  const actions = pConn.getActionsApi();
34
- const propName = pConn.getStateProps().value;
34
+ const propName = pConn.getStateProps()["value"];
35
35
  const helperTextToDisplay = validatemessage || helperText;
36
36
 
37
37
  // Start with default dateFormatInfo
@@ -38,7 +38,7 @@ export default function Decimal(props: DecimalProps) {
38
38
 
39
39
  const pConn = getPConnect();
40
40
  const actions = pConn.getActionsApi();
41
- const propName = pConn.getStateProps().value;
41
+ const propName = pConn.getStateProps()["value"];
42
42
  const helperTextToDisplay = validatemessage || helperText;
43
43
 
44
44
  const [decValue, setDecimalvalue] = useState('');
@@ -4,26 +4,27 @@ import MenuItem from '@material-ui/core/MenuItem';
4
4
  import Utils from '@pega/react-sdk-components/lib/components/helpers/utils';
5
5
  import handleEvent from '@pega/react-sdk-components/lib/components/helpers/event-utils';
6
6
  import FieldValueList from '@pega/react-sdk-components/lib/components/designSystemExtension/FieldValueList';
7
- import type { PConnFieldProps } from '@pega/react-sdk-components/lib/types/PConnProps';
7
+ // import type { PConnFieldProps } from '../../../types/PConnProps';
8
8
 
9
9
  interface IOption {
10
10
  key: string;
11
11
  value: string;
12
12
  }
13
13
 
14
- interface DropdownProps extends PConnFieldProps {
15
- // If any, enter additional props that only exist on Dropdown here
16
- datasource?: Array<any>,
17
- onRecordChange?: any,
18
- fieldMetadata?: any,
19
- // eslint-disable-next-line react/no-unused-prop-types
20
- listType: string,
21
- // eslint-disable-next-line react/no-unused-prop-types
22
- additionalProps?: object
23
- }
14
+ // Can't use DropdownProps with 8.23 until getLocaleRuleNameFromKeys is NOT private
15
+ // interface DropdownProps extends PConnFieldProps {
16
+ // // If any, enter additional props that only exist on Dropdown here
17
+ // datasource?: Array<any>,
18
+ // onRecordChange?: any,
19
+ // fieldMetadata?: any,
20
+ // // eslint-disable-next-line react/no-unused-prop-types
21
+ // listType: string,
22
+ // // eslint-disable-next-line react/no-unused-prop-types
23
+ // additionalProps?: object
24
+ // }
24
25
 
25
26
 
26
- export default function Dropdown(props: DropdownProps) {
27
+ export default function Dropdown(props /* : DropdownProps */) {
27
28
  const {
28
29
  getPConnect,
29
30
  label,
@@ -41,14 +42,14 @@ export default function Dropdown(props: DropdownProps) {
41
42
  onRecordChange,
42
43
  fieldMetadata
43
44
  } = props;
44
- let { placeholder } = props;
45
+ let { placeholder = "" } = props;
45
46
  placeholder = placeholder || 'Select...';
46
47
  const [options, setOptions] = useState<Array<IOption>>([]);
47
48
  const helperTextToDisplay = validatemessage || helperText;
48
49
 
49
50
  const thePConn = getPConnect();
50
51
  const actionsApi = thePConn.getActionsApi();
51
- const propName = thePConn.getStateProps().value;
52
+ const propName = thePConn.getStateProps()["value"];
52
53
  const className = thePConn.getCaseInfo().getClassName();
53
54
  const refName = propName?.slice(propName.lastIndexOf('.') + 1);
54
55
 
@@ -11,16 +11,17 @@ import {
11
11
  import Utils from '@pega/react-sdk-components/lib/components/helpers/utils';
12
12
  import handleEvent from '@pega/react-sdk-components/lib/components/helpers/event-utils';
13
13
  import FieldValueList from '@pega/react-sdk-components/lib/components/designSystemExtension/FieldValueList';
14
- import type { PConnFieldProps } from '@pega/react-sdk-components/lib/types/PConnProps';
14
+ // import type { PConnFieldProps } from '../../../types/PConnProps';
15
15
 
16
- interface RadioButtonsProps extends PConnFieldProps {
17
- // If any, enter additional props that only exist on RadioButtons here
18
- inline: boolean,
19
- fieldMetadata?: any
20
- }
16
+ // Can't use RadioButtonProps until getLocaleRuleNameFromKeys is NOT private
17
+ // interface RadioButtonsProps extends PConnFieldProps {
18
+ // // If any, enter additional props that only exist on RadioButtons here
19
+ // inline: boolean,
20
+ // fieldMetadata?: any
21
+ // }
21
22
 
22
23
 
23
- export default function RadioButtons(props: RadioButtonsProps) {
24
+ export default function RadioButtons(props /* : RadioButtonsProps */ ) {
24
25
  const {
25
26
  getPConnect,
26
27
  label,
@@ -40,7 +41,7 @@ export default function RadioButtons(props: RadioButtonsProps) {
40
41
  const thePConn = getPConnect();
41
42
  const theConfigProps = thePConn.getConfigProps();
42
43
  const actionsApi = thePConn.getActionsApi();
43
- const propName = thePConn.getStateProps().value;
44
+ const propName = thePConn.getStateProps()["value"];
44
45
  const helperTextToDisplay = validatemessage || helperText;
45
46
  const className = thePConn.getCaseInfo().getClassName();
46
47
 
@@ -1,7 +1,7 @@
1
1
  /* eslint-disable react/no-array-index-key */
2
2
  import React from 'react';
3
3
  import FieldValueList from '@pega/react-sdk-components/lib/components/designSystemExtension/FieldValueList';
4
- import { PConnProps } from 'packages/react-sdk-components/src/types/PConnProps';
4
+ import { PConnProps } from '@pega/react-sdk-components/lib/types/PConnProps';
5
5
 
6
6
  // ScalarListProps can't extend PConnFieldProps because its 'value' has a different type
7
7
  interface ScalarListProps extends PConnProps {
@@ -48,7 +48,7 @@ export default function ScalarList(props: ScalarListProps) {
48
48
  readOnly: 'true'
49
49
  }
50
50
  },
51
- null, null, {}); // 2nd, 3rd, and 4th args empty string/object/null until typedef marked correctly as optional;
51
+ '', '', {}); // 2nd, 3rd, and 4th args empty string/object/null until typedef marked correctly as optional
52
52
  });
53
53
 
54
54
  if (['LABELS_LEFT', 'STACKED_LARGE_VAL', 'DISPLAY_ONLY'].includes(displayMode)) {
@@ -1,23 +1,8 @@
1
1
  {
2
- "label": "ScalarList",
3
- "componentKey": "ScalarList",
4
- "name": "ScalarList",
5
- "type": "Field",
6
- "properties": [
7
- {
8
- "component": "$this.componentType",
9
- "format": "COMPONENTDEFINITION"
10
- },
11
- {
12
- "label": "List settings",
13
- "format": "GROUP",
14
- "properties": [
15
- {
16
- "name": "filter",
17
- "label": "Filter by",
18
- "format": "SCALARLISTFILTER"
19
- }
20
- ]
21
- }
22
- ]
23
- }
2
+ "label": "ScalarList",
3
+ "componentKey": "ScalarList",
4
+ "name": "ScalarList",
5
+ "type": "Field",
6
+ "properties": [
7
+ ]
8
+ }
@@ -31,7 +31,7 @@ export default function TextInput(props: TextInputProps) {
31
31
 
32
32
  const pConn = getPConnect();
33
33
  const actions = pConn.getActionsApi();
34
- const propName = pConn.getStateProps().value;
34
+ const propName = pConn.getStateProps()["value"];
35
35
 
36
36
  const helperTextToDisplay = validatemessage || helperText;
37
37
 
@@ -5,20 +5,23 @@ import Snackbar from '@material-ui/core/Snackbar';
5
5
  import IconButton from '@material-ui/core/IconButton';
6
6
  import CloseIcon from '@material-ui/icons/Close';
7
7
 
8
- import type { PConnProps } from '@pega/react-sdk-components/lib/types/PConnProps';
9
-
10
- interface AssignmentProps extends PConnProps {
11
- // If any, enter additional props that only exist on this component
12
- children: Array<any>,
13
- itemKey: string,
14
- isInModal: boolean,
15
- banners: Array<any>
16
- // eslint-disable-next-line react/no-unused-prop-types
17
- actionButtons: Array<any>,
18
- }
19
-
20
-
21
- export default function Assignment(props: AssignmentProps) {
8
+ // import type { PConnProps } from '../../../types/PConnProps';
9
+
10
+ // Can't use AssignmentProps until the following are NOT private
11
+ // getCaseInfo().isAssignmentInCreateStage()
12
+ // getCaseInfo().isLocalAction()
13
+ // interface AssignmentProps extends PConnProps {
14
+ // // If any, enter additional props that only exist on this component
15
+ // children: Array<any>,
16
+ // itemKey: string,
17
+ // isInModal: boolean,
18
+ // banners: Array<any>
19
+ // // eslint-disable-next-line react/no-unused-prop-types
20
+ // actionButtons: Array<any>,
21
+ // }
22
+
23
+
24
+ export default function Assignment(props /* : AssignmentProps */) {
22
25
  const { getPConnect, children, itemKey = '', isInModal = false, banners = [] } = props;
23
26
  const thePConn = getPConnect();
24
27
 
@@ -81,7 +84,7 @@ export default function Assignment(props: AssignmentProps) {
81
84
  const oData = thePConn.getDataObject(''); // 1st arg empty string until typedefs allow it to be optional
82
85
 
83
86
  if (oWorkData?.caseInfo && oWorkData.caseInfo.assignments !== null) {
84
- const oCaseInfo = oData.caseInfo;
87
+ const oCaseInfo = oData["caseInfo"];
85
88
 
86
89
  if (oCaseInfo && oCaseInfo.actionButtons) {
87
90
  setActionButtons(oCaseInfo.actionButtons);
@@ -109,7 +109,7 @@ export default function DashboardFilter(props: DashboardFilterProps) {
109
109
  fireFilterChange(e.id);
110
110
  };
111
111
  return getPConnect().createComponent(metadata,
112
- null, null, {}); // 2nd, 3rd, and 4th args empty string/object/null until typedef marked correctly as optional;
112
+ '', '', {}); // 2nd, 3rd, and 4th args empty string/object/null until typedef marked correctly as optional);
113
113
  };
114
114
 
115
115
  const onChange = dates => {
@@ -91,7 +91,8 @@ export const createFilterComponent = (getPConnect, filterMeta, index) => {
91
91
  metadata={filterMeta}
92
92
  type={filterMeta.type}
93
93
  >
94
- {getPConnect().createComponent(filterMeta, '','', {})}
94
+ {getPConnect().createComponent(filterMeta,
95
+ '', '', {})}
95
96
  </DashboardFilter>
96
97
  );
97
98
  };
@@ -38,7 +38,7 @@ export default function ErrorBoundary(props: ErrorBoundaryProps) {
38
38
  Raw meta data for the component:`, localeCategory)} ${JSON.stringify(pConn.getRawMetadata())}`);
39
39
  }
40
40
 
41
- if (pConn.getConfigProps().type === "page") {
41
+ if (pConn.getConfigProps()["type"] === "page") {
42
42
  return (
43
43
  theErrorDiv
44
44
  );
@@ -93,7 +93,7 @@ export default function AppShell(props:AppShellProps) {
93
93
  useEffect(() => {
94
94
  setAppName(PCore.getEnvironmentInfo().getApplicationName());
95
95
 
96
- const tempMap: any = pConn.getChildren()?.map((child: any, index) => {
96
+ const tempMap: any = pConn.getChildren()?.["map"]((child: any, index) => {
97
97
  const theChildComp = child.getPConnect().getComponentName();
98
98
  const theKey = `.${index}`;
99
99
  return (
@@ -13,7 +13,9 @@ export default function CaseSummary(props: CaseSummaryProps) {
13
13
  const { getPConnect, children } = props;
14
14
  const thePConn = getPConnect();
15
15
  const theConfigProps = thePConn.getConfigProps();
16
- const { status, showStatus } = theConfigProps;
16
+ // const { status, showStatus } = theConfigProps;
17
+ const status = theConfigProps["status"];
18
+ const showStatus = theConfigProps["showStatus"];
17
19
 
18
20
  // from Constellation DX Components
19
21
  // get the primary and secondary fields with the raw data (which has the non-resolved property values)