@pega/react-sdk-overrides 24.2.11 → 25.1.11
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.
- package/lib/designSystemExtension/AlertBanner/AlertBanner.css +46 -0
- package/lib/designSystemExtension/AlertBanner/AlertBanner.tsx +37 -20
- package/lib/designSystemExtension/Banner/Banner.css +1 -1
- package/lib/designSystemExtension/Banner/Banner.tsx +10 -7
- package/lib/designSystemExtension/CaseSummaryFields/CaseSummaryFields.css +0 -1
- package/lib/designSystemExtension/CaseSummaryFields/CaseSummaryFields.tsx +53 -37
- package/lib/designSystemExtension/DetailsFields/DetailsFields.tsx +11 -13
- package/lib/designSystemExtension/FieldGroup/FieldGroup.tsx +8 -9
- package/lib/designSystemExtension/FieldGroupList/FieldGroupList.tsx +9 -9
- package/lib/designSystemExtension/FieldValueList/FieldValueList.tsx +7 -8
- package/lib/designSystemExtension/Operator/Operator.tsx +21 -19
- package/lib/designSystemExtension/Pulse/Pulse.tsx +1 -1
- package/lib/designSystemExtension/RichTextEditor/RichTextEditor.tsx +32 -4
- package/lib/designSystemExtension/WssQuickCreate/WssQuickCreate.css +7 -14
- package/lib/designSystemExtension/WssQuickCreate/WssQuickCreate.tsx +13 -2
- package/lib/field/AutoComplete/AutoComplete.tsx +1 -1
- package/lib/field/CancelAlert/CancelAlert.css +4 -4
- package/lib/field/CancelAlert/CancelAlert.tsx +6 -6
- package/lib/field/Checkbox/Checkbox.tsx +97 -4
- package/lib/field/Currency/Currency.tsx +3 -3
- package/lib/field/Currency/currency-utils.ts +1 -2
- package/lib/field/Date/Date.tsx +3 -7
- package/lib/field/DateTime/DateTime.tsx +3 -8
- package/lib/field/Decimal/Decimal.tsx +3 -5
- package/lib/field/Dropdown/Dropdown.tsx +5 -7
- package/lib/field/Email/Email.tsx +11 -13
- package/lib/field/Group/Group.tsx +10 -8
- package/lib/field/Integer/Integer.tsx +5 -7
- package/lib/field/Location/Location.css +4 -0
- package/lib/field/Location/Location.tsx +258 -0
- package/lib/field/Location/config-ext.json +8 -0
- package/lib/field/Location/index.tsx +1 -0
- package/lib/field/Multiselect/utils.ts +1 -1
- package/lib/field/ObjectReference/ObjectReference.tsx +235 -0
- package/lib/field/ObjectReference/index.tsx +1 -0
- package/lib/field/ObjectReference/utils.ts +111 -0
- package/lib/field/Percentage/Percentage.tsx +3 -7
- package/lib/field/Phone/Phone.tsx +7 -5
- package/lib/field/RadioButtons/RadioButtons.tsx +47 -2
- package/lib/field/RichText/RichText.css +79 -0
- package/lib/field/RichText/RichText.tsx +3 -1
- package/lib/field/ScalarList/ScalarList.tsx +2 -3
- package/lib/field/SelectableCard/SelectableCard.tsx +189 -0
- package/lib/field/SelectableCard/index.tsx +1 -0
- package/lib/field/SelectableCard/utils.tsx +223 -0
- package/lib/field/SemanticLink/SemanticLink.tsx +160 -28
- package/lib/field/SemanticLink/utils.ts +1 -1
- package/lib/field/TextArea/TextArea.tsx +5 -7
- package/lib/field/TextContent/TextContent.tsx +1 -2
- package/lib/field/TextInput/TextInput.tsx +5 -7
- package/lib/field/Time/Time.tsx +3 -7
- package/lib/field/URL/URL.tsx +5 -7
- package/lib/field/UserReference/UserReference.tsx +2 -3
- package/lib/helpers/attachmentShared.ts +6 -0
- package/lib/helpers/common-utils.ts +3 -4
- package/lib/helpers/data_page.ts +0 -1
- package/lib/helpers/field-group-utils.ts +1 -1
- package/lib/helpers/formatters/Currency.ts +9 -4
- package/lib/helpers/formatters/CurrencyMap.ts +0 -2
- package/lib/helpers/object-utils.ts +10 -0
- package/lib/helpers/simpleTableHelpers.ts +118 -6
- package/lib/helpers/utils.ts +8 -1
- package/lib/helpers/versionHelpers.ts +0 -1
- package/lib/infra/ActionButtons/ActionButtons.tsx +28 -21
- package/lib/infra/Assignment/Assignment.tsx +47 -31
- package/lib/infra/Assignment/useValidationBanner.ts +29 -0
- package/lib/infra/AssignmentCard/AssignmentCard.tsx +2 -2
- package/lib/infra/Containers/FlowContainer/FlowContainer.tsx +22 -102
- package/lib/infra/Containers/ModalViewContainer/ListViewActionButtons/ListViewActionButtons.tsx +1 -2
- package/lib/infra/Containers/ModalViewContainer/ModalViewContainer.tsx +12 -6
- package/lib/infra/Containers/ViewContainer/ViewContainer.tsx +8 -13
- package/lib/infra/Containers/container-helpers.ts +47 -1
- package/lib/infra/DashboardFilter/DashboardFilter.tsx +3 -6
- package/lib/infra/DashboardFilter/filterUtils.tsx +3 -4
- package/lib/infra/DeferLoad/DeferLoad.tsx +26 -13
- package/lib/infra/ErrorBoundary/ErrorBoundary.tsx +1 -3
- package/lib/infra/MultiStep/MultiStep.css +48 -70
- package/lib/infra/MultiStep/MultiStep.tsx +27 -53
- package/lib/infra/NavBar/NavBar.css +1 -1
- package/lib/infra/NavBar/NavBar.tsx +49 -34
- package/lib/infra/Reference/Reference.tsx +8 -4
- package/lib/infra/Region/Region.tsx +1 -1
- package/lib/infra/RootContainer/RootContainer.tsx +6 -8
- package/lib/infra/Stages/Stages.tsx +3 -4
- package/lib/infra/View/View.tsx +9 -9
- package/lib/template/AdvancedSearch/AdvancedSearch.tsx +86 -0
- package/lib/template/AdvancedSearch/SearchGroup/persistUtils.ts +52 -0
- package/lib/template/AdvancedSearch/SearchGroups/SearchGroups.tsx +244 -0
- package/lib/template/AdvancedSearch/SearchGroups/hooks.ts +37 -0
- package/lib/template/AdvancedSearch/SearchGroups/index.tsx +1 -0
- package/lib/template/AdvancedSearch/SearchGroups/utils.ts +29 -0
- package/lib/template/AdvancedSearch/TemplateContext.ts +11 -0
- package/lib/template/AdvancedSearch/config-ext.json +9 -0
- package/lib/template/AdvancedSearch/index.tsx +1 -0
- package/lib/template/AppShell/AppShell.css +1 -5
- package/lib/template/AppShell/AppShell.tsx +16 -17
- package/lib/template/BannerPage/BannerPage.tsx +2 -2
- package/lib/template/CaseSummary/CaseSummary.tsx +25 -43
- package/lib/template/CaseView/CaseView.tsx +28 -35
- package/lib/template/CaseViewActionsMenu/CaseViewActionsMenu.tsx +1 -1
- package/lib/template/Confirmation/Confirmation.tsx +2 -3
- package/lib/template/DataReference/DataReference.tsx +312 -106
- package/lib/template/DataReference/DataReferenceAdvancedSearchContext.ts +10 -0
- package/lib/template/DataReference/SearchForm.tsx +149 -0
- package/lib/template/DataReference/utils.ts +90 -0
- package/lib/template/DefaultForm/DefaultForm.tsx +3 -3
- package/lib/template/DefaultForm/utils/index.ts +1 -3
- package/lib/template/DefaultPage/DefaultPage.tsx +108 -0
- package/lib/template/DefaultPage/index.tsx +1 -0
- package/lib/template/Details/Details/Details.tsx +11 -11
- package/lib/template/Details/DetailsSubTabs/DetailsSubTabs.tsx +2 -2
- package/lib/template/Details/DetailsThreeColumn/DetailsThreeColumn.tsx +11 -11
- package/lib/template/Details/DetailsTwoColumn/DetailsTwoColumn.tsx +11 -11
- package/lib/template/Details/DynamicTabs/DynamicTabs.tsx +1 -1
- package/lib/template/FieldGroupTemplate/FieldGroupTemplate.tsx +12 -6
- package/lib/template/HierarchicalForm/HierarchicalForm.tsx +58 -0
- package/lib/template/HierarchicalForm/hooks.ts +224 -0
- package/lib/template/HierarchicalForm/index.tsx +1 -0
- package/lib/template/InlineDashboard/InlineDashboard.tsx +14 -16
- package/lib/template/InlineDashboardPage/InlineDashboardPage.tsx +2 -2
- package/lib/template/ListPage/ListPage.tsx +1 -1
- package/lib/template/ListView/ListView.tsx +342 -204
- package/lib/template/ListView/hooks.ts +1 -5
- package/lib/template/ListView/utils.ts +38 -5
- package/lib/template/MultiReferenceReadOnly/MultiReferenceReadOnly.tsx +17 -2
- package/lib/template/NarrowWide/NarrowWide/NarrowWide.tsx +5 -5
- package/lib/template/NarrowWide/NarrowWideDetails/NarrowWideDetails.tsx +11 -11
- package/lib/template/NarrowWide/NarrowWideForm/NarrowWideForm.tsx +2 -2
- package/lib/template/NarrowWide/NarrowWidePage/NarrowWidePage.tsx +2 -2
- package/lib/template/ObjectPage/index.tsx +1 -0
- package/lib/template/OneColumn/OneColumn/OneColumn.tsx +7 -7
- package/lib/template/OneColumn/OneColumnPage/OneColumnPage.tsx +1 -1
- package/lib/template/OneColumn/OneColumnTab/OneColumnTab.tsx +2 -2
- package/lib/template/PromotedFilters/PromotedFilters.tsx +1 -2
- package/lib/template/SelfServiceCaseView/SelfServiceCaseView.tsx +153 -0
- package/lib/template/SelfServiceCaseView/index.tsx +1 -0
- package/lib/template/SimpleTable/SimpleTable/SimpleTable.tsx +2 -3
- package/lib/template/SimpleTable/SimpleTableManual/SimpleTableManual.tsx +45 -34
- package/lib/template/SimpleTable/SimpleTableSelect/SimpleTableSelect.tsx +1 -1
- package/lib/template/SimpleTable/SimpleTableSelectReadonly/SimpleTableSelectReadonly.tsx +179 -0
- package/lib/template/SimpleTable/SimpleTableSelectReadonly/index.tsx +1 -0
- package/lib/template/SingleReferenceReadOnly/SingleReferenceReadOnly.tsx +10 -2
- package/lib/template/SubTabs/SubTabs.tsx +2 -2
- package/lib/template/SubTabs/tabUtils.ts +118 -1
- package/lib/template/TwoColumn/TwoColumn/TwoColumn.tsx +9 -10
- package/lib/template/TwoColumn/TwoColumnPage/TwoColumnPage.tsx +1 -1
- package/lib/template/TwoColumn/TwoColumnTab/TwoColumnTab.tsx +9 -10
- package/lib/template/WideNarrow/WideNarrow/WideNarrow.tsx +5 -5
- package/lib/template/WideNarrow/WideNarrowDetails/WideNarrowDetails.tsx +11 -11
- package/lib/template/WideNarrow/WideNarrowForm/WideNarrowForm.tsx +2 -2
- package/lib/template/WideNarrow/WideNarrowPage/WideNarrowPage.tsx +2 -2
- package/lib/template/WssNavBar/WssNavBar.css +1 -1
- package/lib/template/WssNavBar/WssNavBar.tsx +6 -6
- package/lib/template/utils.tsx +58 -0
- package/lib/widget/AppAnnouncement/AppAnnouncement.tsx +1 -1
- package/lib/widget/Attachment/Attachment.css +6 -8
- package/lib/widget/Attachment/Attachment.tsx +303 -225
- package/lib/widget/Attachment/Attachment.types.ts +96 -0
- package/lib/widget/Attachment/AttachmentUtils.ts +316 -0
- package/lib/widget/CaseHistory/CaseHistory.tsx +5 -5
- package/lib/widget/FileUtility/ActionButtonsForFileUtil/ActionButtonsForFileUtil.css +0 -14
- package/lib/widget/FileUtility/ActionButtonsForFileUtil/ActionButtonsForFileUtil.tsx +3 -3
- package/lib/widget/FileUtility/FileUtility/FileUtility.css +7 -6
- package/lib/widget/FileUtility/FileUtility/FileUtility.tsx +29 -22
- package/lib/widget/Followers/Followers.tsx +2 -4
- package/lib/widget/QuickCreate/QuickCreate.tsx +1 -2
- package/lib/widget/SummaryItem/SummaryItem.css +9 -11
- package/lib/widget/SummaryItem/SummaryItem.tsx +2 -2
- package/lib/widget/SummaryList/SummaryList.tsx +1 -1
- package/lib/widget/ToDo/ToDo.css +1 -13
- package/lib/widget/ToDo/ToDo.tsx +37 -36
- package/package.json +1 -1
- package/lib/helpers/attachmentHelpers.ts +0 -76
|
@@ -2,7 +2,7 @@ import { useEffect, useState } from 'react';
|
|
|
2
2
|
import { NumericFormat } from 'react-number-format';
|
|
3
3
|
import { TextField } from '@mui/material';
|
|
4
4
|
import { getComponentFromMap } from '@pega/react-sdk-components/lib/bridge/helpers/sdk_component_map';
|
|
5
|
-
import { PConnFieldProps } from '@pega/react-sdk-components/lib/types/PConnProps';
|
|
5
|
+
import type { PConnFieldProps } from '@pega/react-sdk-components/lib/types/PConnProps';
|
|
6
6
|
import { getCurrencyCharacters, getCurrencyOptions } from '@pega/react-sdk-components/lib/components/field/Currency/currency-utils';
|
|
7
7
|
import handleEvent from '@pega/react-sdk-components/lib/components/helpers/event-utils';
|
|
8
8
|
import { format } from '@pega/react-sdk-components/lib/components/helpers/formatters';
|
|
@@ -70,11 +70,7 @@ export default function Percentage(props: PercentageProps) {
|
|
|
70
70
|
return <FieldValueList name={hideLabel ? '' : label} value={formattedValue} variant='stacked' />;
|
|
71
71
|
}
|
|
72
72
|
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
testProp = {
|
|
76
|
-
'data-test-id': testId
|
|
77
|
-
};
|
|
73
|
+
const testProps: any = { 'data-test-id': testId };
|
|
78
74
|
|
|
79
75
|
const theSymbols = getCurrencyCharacters(currencyISOCode);
|
|
80
76
|
const theCurrDec = theSymbols.theDecimalIndicator;
|
|
@@ -109,7 +105,7 @@ export default function Percentage(props: PercentageProps) {
|
|
|
109
105
|
thousandSeparator={showGroupSeparators ? theCurrSep : ''}
|
|
110
106
|
decimalScale={decimalPrecision}
|
|
111
107
|
suffix='%'
|
|
112
|
-
|
|
108
|
+
slotProps={{ input: { ...readOnlyProp, inputProps: { ...testProps } } }}
|
|
113
109
|
customInput={TextField}
|
|
114
110
|
/>
|
|
115
111
|
);
|
|
@@ -2,7 +2,7 @@ import { useEffect, useState } from 'react';
|
|
|
2
2
|
import { MuiTelInput } from 'mui-tel-input';
|
|
3
3
|
|
|
4
4
|
import { getComponentFromMap } from '@pega/react-sdk-components/lib/bridge/helpers/sdk_component_map';
|
|
5
|
-
import { PConnFieldProps } from '@pega/react-sdk-components/lib/types/PConnProps';
|
|
5
|
+
import type { PConnFieldProps } from '@pega/react-sdk-components/lib/types/PConnProps';
|
|
6
6
|
import handleEvent from '@pega/react-sdk-components/lib/components/helpers/event-utils';
|
|
7
7
|
|
|
8
8
|
interface PhoneProps extends PConnFieldProps {
|
|
@@ -69,9 +69,11 @@ export default function Phone(props: PhoneProps) {
|
|
|
69
69
|
error={status === 'error'}
|
|
70
70
|
label={label}
|
|
71
71
|
value={value}
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
72
|
+
slotProps={{
|
|
73
|
+
input: {
|
|
74
|
+
readOnly: true,
|
|
75
|
+
...testProp
|
|
76
|
+
}
|
|
75
77
|
}}
|
|
76
78
|
disableDropdown={disableDropdown}
|
|
77
79
|
/>
|
|
@@ -105,7 +107,7 @@ export default function Phone(props: PhoneProps) {
|
|
|
105
107
|
error={status === 'error'}
|
|
106
108
|
label={label}
|
|
107
109
|
value={inputValue}
|
|
108
|
-
|
|
110
|
+
slotProps={{ input: { ...testProp } }}
|
|
109
111
|
/>
|
|
110
112
|
);
|
|
111
113
|
}
|
|
@@ -4,18 +4,26 @@ import { Radio, RadioGroup, FormControl, FormControlLabel, FormLabel, FormHelper
|
|
|
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 { getComponentFromMap } from '@pega/react-sdk-components/lib/bridge/helpers/sdk_component_map';
|
|
7
|
-
import { PConnFieldProps } from '@pega/react-sdk-components/lib/types/PConnProps';
|
|
7
|
+
import type { PConnFieldProps } from '@pega/react-sdk-components/lib/types/PConnProps';
|
|
8
8
|
|
|
9
9
|
// Can't use RadioButtonProps until getLocaleRuleNameFromKeys is NOT private
|
|
10
10
|
interface RadioButtonsProps extends PConnFieldProps {
|
|
11
11
|
// If any, enter additional props that only exist on RadioButtons here
|
|
12
12
|
inline: boolean;
|
|
13
13
|
fieldMetadata?: any;
|
|
14
|
+
variant?: string;
|
|
15
|
+
hideFieldLabels?: boolean;
|
|
16
|
+
additionalProps?: any;
|
|
17
|
+
imagePosition?: string;
|
|
18
|
+
imageSize?: string;
|
|
19
|
+
showImageDescription?: boolean;
|
|
20
|
+
datasource?: any;
|
|
14
21
|
}
|
|
15
22
|
|
|
16
23
|
export default function RadioButtons(props: RadioButtonsProps) {
|
|
17
24
|
// Get emitted components from map (so we can get any override that may exist)
|
|
18
25
|
const FieldValueList = getComponentFromMap('FieldValueList');
|
|
26
|
+
const SelectableCard = getComponentFromMap('SelectableCard');
|
|
19
27
|
|
|
20
28
|
const {
|
|
21
29
|
getPConnect,
|
|
@@ -29,7 +37,14 @@ export default function RadioButtons(props: RadioButtonsProps) {
|
|
|
29
37
|
inline,
|
|
30
38
|
displayMode,
|
|
31
39
|
hideLabel,
|
|
32
|
-
fieldMetadata
|
|
40
|
+
fieldMetadata,
|
|
41
|
+
variant,
|
|
42
|
+
hideFieldLabels,
|
|
43
|
+
additionalProps,
|
|
44
|
+
datasource,
|
|
45
|
+
imagePosition,
|
|
46
|
+
imageSize,
|
|
47
|
+
showImageDescription
|
|
33
48
|
} = props;
|
|
34
49
|
const [theSelectedButton, setSelectedButton] = useState(value);
|
|
35
50
|
|
|
@@ -88,6 +103,36 @@ export default function RadioButtons(props: RadioButtonsProps) {
|
|
|
88
103
|
thePConn.getValidationApi().validate(event.target.value, ''); // 2nd arg empty string until typedef marked correctly as optional
|
|
89
104
|
};
|
|
90
105
|
|
|
106
|
+
if (variant === 'card') {
|
|
107
|
+
const stateProps = thePConn.getStateProps();
|
|
108
|
+
return (
|
|
109
|
+
<div>
|
|
110
|
+
<h4 style={{ marginTop: 0, marginBottom: 0 }}>{label}</h4>
|
|
111
|
+
<div id='selectable-card' style={{ display: 'grid', gridTemplateColumns: 'repeat(auto-fit, minmax(min(200px, 100%), 1fr))', gap: '1rem' }}>
|
|
112
|
+
<SelectableCard
|
|
113
|
+
hideFieldLabels={hideFieldLabels}
|
|
114
|
+
additionalProps={additionalProps}
|
|
115
|
+
getPConnect={getPConnect}
|
|
116
|
+
dataSource={datasource}
|
|
117
|
+
image={{
|
|
118
|
+
imagePosition,
|
|
119
|
+
imageSize,
|
|
120
|
+
showImageDescription,
|
|
121
|
+
imageField: stateProps.image?.split('.').pop(),
|
|
122
|
+
imageDescription: stateProps.imageDescription?.split('.').pop()
|
|
123
|
+
}}
|
|
124
|
+
onChange={handleChange}
|
|
125
|
+
recordKey={stateProps.value?.split('.').pop()}
|
|
126
|
+
cardLabel={stateProps.primaryField?.split('.').pop()}
|
|
127
|
+
radioBtnValue={value}
|
|
128
|
+
type='radio'
|
|
129
|
+
setIsRadioCardSelected={displayMode !== 'DISPLAY_ONLY' ? setSelectedButton : undefined}
|
|
130
|
+
/>
|
|
131
|
+
</div>
|
|
132
|
+
</div>
|
|
133
|
+
);
|
|
134
|
+
}
|
|
135
|
+
|
|
91
136
|
return (
|
|
92
137
|
<FormControl variant='standard' error={status === 'error'} required={required}>
|
|
93
138
|
<FormLabel component='legend'>{label}</FormLabel>
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
.tox .tox-toolbar {
|
|
2
|
+
background-color: var(--app-background-color) !important;
|
|
3
|
+
}
|
|
4
|
+
|
|
5
|
+
.tox .tox-toolbar__primary {
|
|
6
|
+
background-color: var(--app-background-color) !important;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
.tox .tox-toolbar__button {
|
|
10
|
+
color: var(--app-text-color) !important;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.tox .tox-toolbar__button--enabled {
|
|
14
|
+
background: var(--app-primary-color) !important;
|
|
15
|
+
color: #fff !important;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
.tox .tox-dialog {
|
|
19
|
+
background-color: var(--modal-top-color) !important;
|
|
20
|
+
color: var(--app-text-color) !important;
|
|
21
|
+
border: 1px solid var(--modal-border-color) !important;
|
|
22
|
+
padding: 20px !important;
|
|
23
|
+
box-shadow: 0 0 10px 3px var(--modal-box-shadow-color) !important;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
.tox .tox-dialog__header {
|
|
27
|
+
background-color: var(--modal-top-color) !important;
|
|
28
|
+
color: var(--app-text-color) !important;
|
|
29
|
+
font-weight: 500;
|
|
30
|
+
border-bottom: 1px solid var(--modal-border-color);
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
.tox .tox-dialog__footer {
|
|
34
|
+
background: transparent !important;
|
|
35
|
+
border-top: 1px solid var(--modal-border-color);
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.tox .tox-dialog-wrap__backdrop {
|
|
39
|
+
background-color: var(--modal-background-color) !important;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
.tox .tox-dialog__body input,
|
|
43
|
+
.tox .tox-dialog__body textarea,
|
|
44
|
+
.tox .tox-dialog__body select {
|
|
45
|
+
background: initial !important;
|
|
46
|
+
color: var(--app-text-color) !important;
|
|
47
|
+
border: 1px solid var(--app-neutral-color) !important;
|
|
48
|
+
border-radius: 4px !important;
|
|
49
|
+
padding: 6px 10px !important;
|
|
50
|
+
font-size: 1em !important;
|
|
51
|
+
font-family: inherit !important;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
.tox .tox-dialog__body button {
|
|
55
|
+
background: transparent;
|
|
56
|
+
color: #fff !important;
|
|
57
|
+
border: none !important;
|
|
58
|
+
border-radius: 4px !important;
|
|
59
|
+
padding: 8px 16px !important;
|
|
60
|
+
font-size: 1em !important;
|
|
61
|
+
cursor: pointer !important;
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
.tox .tox-dialog__footer .tox-button {
|
|
65
|
+
background: var(--app-primary-color) !important;
|
|
66
|
+
color: #fff !important;
|
|
67
|
+
border: none !important;
|
|
68
|
+
border-radius: 4px !important;
|
|
69
|
+
padding: 8px 16px !important;
|
|
70
|
+
font-size: 1em !important;
|
|
71
|
+
cursor: pointer !important;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
.tox .tox-dialog__footer .tox-button--secondary {
|
|
75
|
+
background: var(--app-secondary-color) !important;
|
|
76
|
+
color: var(--secondary-button-text-color) !important;
|
|
77
|
+
font-size: 0.875rem !important;
|
|
78
|
+
cursor: pointer !important;
|
|
79
|
+
}
|
|
@@ -2,7 +2,9 @@ import { useRef } from 'react';
|
|
|
2
2
|
|
|
3
3
|
import handleEvent from '@pega/react-sdk-components/lib/components/helpers/event-utils';
|
|
4
4
|
import { getComponentFromMap } from '@pega/react-sdk-components/lib/bridge/helpers/sdk_component_map';
|
|
5
|
-
import { PConnFieldProps } from '@pega/react-sdk-components/lib/types/PConnProps';
|
|
5
|
+
import type { PConnFieldProps } from '@pega/react-sdk-components/lib/types/PConnProps';
|
|
6
|
+
|
|
7
|
+
import './RichText.css';
|
|
6
8
|
|
|
7
9
|
interface RichTextProps extends PConnFieldProps {
|
|
8
10
|
// If any, enter additional props that only exist on TextArea here
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
/* eslint-disable react/no-array-index-key */
|
|
2
1
|
import { getComponentFromMap } from '@pega/react-sdk-components/lib/bridge/helpers/sdk_component_map';
|
|
3
|
-
import { PConnProps } from '@pega/react-sdk-components/lib/types/PConnProps';
|
|
2
|
+
import type { PConnProps } from '@pega/react-sdk-components/lib/types/PConnProps';
|
|
4
3
|
|
|
5
4
|
// ScalarListProps can't extend PConnFieldProps because its 'value' has a different type
|
|
6
5
|
interface ScalarListProps extends PConnProps {
|
|
@@ -44,7 +43,7 @@ export default function ScalarList(props: ScalarListProps) {
|
|
|
44
43
|
}
|
|
45
44
|
},
|
|
46
45
|
'',
|
|
47
|
-
// @ts-
|
|
46
|
+
// @ts-expect-error
|
|
48
47
|
'',
|
|
49
48
|
{}
|
|
50
49
|
); // 2nd, 3rd, and 4th args empty string/object/null until typedef marked correctly as optional;
|
|
@@ -0,0 +1,189 @@
|
|
|
1
|
+
import { Radio, Checkbox, FormControlLabel, Card, CardContent, Typography } from '@mui/material';
|
|
2
|
+
import { resolveReferenceFields } from './utils';
|
|
3
|
+
|
|
4
|
+
export default function SelectableCard(props) {
|
|
5
|
+
const {
|
|
6
|
+
getPConnect,
|
|
7
|
+
type,
|
|
8
|
+
image: { imagePosition, imageSize, showImageDescription, imageField = '', imageDescription = '' },
|
|
9
|
+
dataSource,
|
|
10
|
+
recordKey = '',
|
|
11
|
+
className,
|
|
12
|
+
cardLabel,
|
|
13
|
+
hideFieldLabels = false,
|
|
14
|
+
readOnly,
|
|
15
|
+
disabled,
|
|
16
|
+
readOnlyList = [],
|
|
17
|
+
displayMode,
|
|
18
|
+
radioBtnValue,
|
|
19
|
+
onChange,
|
|
20
|
+
onBlur,
|
|
21
|
+
onClick,
|
|
22
|
+
onKeyDown,
|
|
23
|
+
additionalProps,
|
|
24
|
+
testId,
|
|
25
|
+
setIsRadioCardSelected,
|
|
26
|
+
showNoValue = false
|
|
27
|
+
} = props;
|
|
28
|
+
|
|
29
|
+
const pConn = getPConnect();
|
|
30
|
+
|
|
31
|
+
if (showNoValue) return <Typography>No Value</Typography>;
|
|
32
|
+
|
|
33
|
+
const cardDataSource = readOnly || displayMode === 'DISPLAY_ONLY' ? readOnlyList || [] : dataSource?.source;
|
|
34
|
+
const imageDescriptionKey = showImageDescription ? imageDescription : undefined;
|
|
35
|
+
|
|
36
|
+
const handleCardClick = event => {
|
|
37
|
+
if (disabled || readOnly) return;
|
|
38
|
+
// If the click landed on or inside a label/input, native behavior already handles it.
|
|
39
|
+
if (event.target.closest?.('label, input')) return;
|
|
40
|
+
// Find the radio/checkbox input inside this card and click it programmatically.
|
|
41
|
+
const input = event.currentTarget.querySelector('input[type="radio"], input[type="checkbox"]');
|
|
42
|
+
if (input) input.click();
|
|
43
|
+
};
|
|
44
|
+
|
|
45
|
+
let radioItemSelected = false;
|
|
46
|
+
|
|
47
|
+
return (
|
|
48
|
+
<>
|
|
49
|
+
{(cardDataSource || []).map(item => {
|
|
50
|
+
const resolvedFields = resolveReferenceFields(item, hideFieldLabels, recordKey, pConn);
|
|
51
|
+
|
|
52
|
+
const commonProps = {
|
|
53
|
+
id: item[recordKey],
|
|
54
|
+
key: item[recordKey],
|
|
55
|
+
fields: resolvedFields,
|
|
56
|
+
label: item[cardLabel]
|
|
57
|
+
};
|
|
58
|
+
|
|
59
|
+
const image = item[imageField]
|
|
60
|
+
? {
|
|
61
|
+
src: item[imageField],
|
|
62
|
+
alt: showImageDescription && imageDescriptionKey ? item[imageDescriptionKey] : '',
|
|
63
|
+
style: { width: imageSize, objectPosition: imagePosition }
|
|
64
|
+
}
|
|
65
|
+
: undefined;
|
|
66
|
+
|
|
67
|
+
const cardContent = (
|
|
68
|
+
<Card className={className} style={{ display: 'flex' }} data-testid={testId}>
|
|
69
|
+
{image && <img src={image.src} alt={image.alt} style={{ width: '100px' }} />}
|
|
70
|
+
<CardContent>
|
|
71
|
+
<Typography variant='body1'>{item[cardLabel]}</Typography>
|
|
72
|
+
{commonProps.fields.map((field, index) => (
|
|
73
|
+
<Typography key={index} variant='body2'>
|
|
74
|
+
{field.value}
|
|
75
|
+
</Typography>
|
|
76
|
+
))}
|
|
77
|
+
</CardContent>
|
|
78
|
+
</Card>
|
|
79
|
+
);
|
|
80
|
+
|
|
81
|
+
if (displayMode === 'DISPLAY_ONLY') {
|
|
82
|
+
return cardContent;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
const component = (
|
|
86
|
+
<div key={item[recordKey]} style={{ paddingTop: '15px' }}>
|
|
87
|
+
<Card
|
|
88
|
+
className={className}
|
|
89
|
+
style={{ display: 'flex', flexDirection: 'column', height: '100%', cursor: disabled || readOnly ? 'default' : 'pointer' }}
|
|
90
|
+
data-testid={testId}
|
|
91
|
+
onClick={handleCardClick}
|
|
92
|
+
>
|
|
93
|
+
<CardContent
|
|
94
|
+
style={{
|
|
95
|
+
...((imagePosition === 'inline-start' || imagePosition === 'inline-end') && { display: 'flex', height: '100%' }),
|
|
96
|
+
...(imagePosition === 'inline-end' && { flexDirection: 'row-reverse' })
|
|
97
|
+
}}
|
|
98
|
+
>
|
|
99
|
+
<div
|
|
100
|
+
style={{
|
|
101
|
+
...((imagePosition === 'inline-start' || imagePosition === 'inline-end') && { width: '40%' })
|
|
102
|
+
}}
|
|
103
|
+
>
|
|
104
|
+
{image && (
|
|
105
|
+
<img
|
|
106
|
+
src={image.src}
|
|
107
|
+
alt={image.alt}
|
|
108
|
+
style={{
|
|
109
|
+
width: '100%',
|
|
110
|
+
backgroundColor: 'transparent',
|
|
111
|
+
aspectRatio: '16 / 9',
|
|
112
|
+
maxHeight: '100%',
|
|
113
|
+
height: '100%',
|
|
114
|
+
objectFit: 'contain',
|
|
115
|
+
maxWidth: '100%'
|
|
116
|
+
}}
|
|
117
|
+
/>
|
|
118
|
+
)}
|
|
119
|
+
</div>
|
|
120
|
+
<div
|
|
121
|
+
style={{
|
|
122
|
+
...((imagePosition === 'inline-start' || imagePosition === 'inline-end') && { width: '60%' })
|
|
123
|
+
}}
|
|
124
|
+
>
|
|
125
|
+
{type === 'radio' ? (
|
|
126
|
+
<FormControlLabel
|
|
127
|
+
control={
|
|
128
|
+
<Radio
|
|
129
|
+
value={item[recordKey]}
|
|
130
|
+
checked={radioBtnValue === item[recordKey]}
|
|
131
|
+
onChange={onChange}
|
|
132
|
+
onBlur={onBlur}
|
|
133
|
+
onClick={onClick}
|
|
134
|
+
onKeyDown={onKeyDown}
|
|
135
|
+
disabled={disabled || readOnly}
|
|
136
|
+
{...additionalProps}
|
|
137
|
+
/>
|
|
138
|
+
}
|
|
139
|
+
label={<Typography variant='body1'>{item[cardLabel]}</Typography>}
|
|
140
|
+
/>
|
|
141
|
+
) : (
|
|
142
|
+
<FormControlLabel
|
|
143
|
+
control={
|
|
144
|
+
<Checkbox
|
|
145
|
+
id={item[recordKey]}
|
|
146
|
+
getPConnect={getPConnect}
|
|
147
|
+
checked={readOnlyList.some(data => data[recordKey] === item[recordKey])}
|
|
148
|
+
onChange={onChange}
|
|
149
|
+
onBlur={onBlur}
|
|
150
|
+
onClick={onClick}
|
|
151
|
+
onKeyDown={onKeyDown}
|
|
152
|
+
disabled={disabled || readOnly}
|
|
153
|
+
{...additionalProps}
|
|
154
|
+
/>
|
|
155
|
+
}
|
|
156
|
+
label={<Typography variant='body1'>{item[cardLabel]}</Typography>}
|
|
157
|
+
/>
|
|
158
|
+
)}
|
|
159
|
+
|
|
160
|
+
{commonProps.fields.map((field, index) => (
|
|
161
|
+
<div
|
|
162
|
+
key={index}
|
|
163
|
+
style={{
|
|
164
|
+
fontSize: '0.875rem',
|
|
165
|
+
...(field.type !== 'TextArea' && { display: 'grid', gridTemplateColumns: '1fr 1fr' }),
|
|
166
|
+
margin: '5px'
|
|
167
|
+
}}
|
|
168
|
+
>
|
|
169
|
+
{field.name && <div>{field.name}</div>}
|
|
170
|
+
<div>{field?.value?.props.value}</div>
|
|
171
|
+
</div>
|
|
172
|
+
))}
|
|
173
|
+
</div>
|
|
174
|
+
</CardContent>
|
|
175
|
+
</Card>
|
|
176
|
+
</div>
|
|
177
|
+
);
|
|
178
|
+
|
|
179
|
+
if (type === 'radio' && radioBtnValue === item[recordKey]) {
|
|
180
|
+
radioItemSelected = true;
|
|
181
|
+
}
|
|
182
|
+
|
|
183
|
+
return component;
|
|
184
|
+
})}
|
|
185
|
+
|
|
186
|
+
{type === 'radio' && setIsRadioCardSelected && setIsRadioCardSelected(radioItemSelected)}
|
|
187
|
+
</>
|
|
188
|
+
);
|
|
189
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from './SelectableCard';
|
|
@@ -0,0 +1,223 @@
|
|
|
1
|
+
import { Link } from '@mui/material';
|
|
2
|
+
|
|
3
|
+
import { Utils } from '@pega/react-sdk-components/lib/components/helpers/utils';
|
|
4
|
+
|
|
5
|
+
export const resolveReferencedPConnect = pConnect => {
|
|
6
|
+
if (!pConnect || !pConnect.meta) return undefined;
|
|
7
|
+
const type = pConnect?._type ?? undefined;
|
|
8
|
+
const referencedPConnect = type === 'reference' && pConnect.getReferencedViewPConnect().getPConnect();
|
|
9
|
+
return referencedPConnect || pConnect;
|
|
10
|
+
};
|
|
11
|
+
|
|
12
|
+
/**
|
|
13
|
+
* A helper function to create an object consisting react component as per the type.
|
|
14
|
+
* This is used by CaseSummary template.
|
|
15
|
+
* @param {object} pConnectMeta Object containing meta information for the particular field authored
|
|
16
|
+
* @param {Function} getPConnect PConnect function passed along to other components.
|
|
17
|
+
* @param {string} displayMode displayMode string contains information about the layout of component in review mode.
|
|
18
|
+
*/
|
|
19
|
+
export function prepareComponentInCaseSummary(pConnectMeta: any, getPConnect: Function) {
|
|
20
|
+
const { config, children } = pConnectMeta;
|
|
21
|
+
|
|
22
|
+
const noValueComponent = <div>No Value</div>;
|
|
23
|
+
const placeholder = '...';
|
|
24
|
+
const pConnect = getPConnect();
|
|
25
|
+
|
|
26
|
+
const caseSummaryComponentObject: any = {};
|
|
27
|
+
|
|
28
|
+
let { type } = pConnectMeta;
|
|
29
|
+
let showAddressLabel = true;
|
|
30
|
+
|
|
31
|
+
if (config && config.value === `@P .${Utils.getMappedKey('pyStatusWork')}`) {
|
|
32
|
+
config.displayAsStatus = true;
|
|
33
|
+
type = 'TextInput'; // force the type to be TextInput for status field.
|
|
34
|
+
// As TextInput is loaded forcefully sometimes, TextInput component might not be available in lazy map.
|
|
35
|
+
// Load TextInput if it is not available.
|
|
36
|
+
if (!PCore.getComponentsRegistry().getLazyComponent(type)) {
|
|
37
|
+
PCore.getAssetLoader().getLoader('component-loader')([type]);
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
caseSummaryComponentObject.name = pConnect.resolveConfigProps({ label: config.label }).label;
|
|
42
|
+
|
|
43
|
+
if (config.inheritedProps) {
|
|
44
|
+
const labelInInheritedProp = config.inheritedProps.find(inheritedProp => inheritedProp.prop === 'label');
|
|
45
|
+
if (labelInInheritedProp) {
|
|
46
|
+
labelInInheritedProp.value = pConnect.resolveConfigProps({ label: labelInInheritedProp.value }).label;
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
switch (type) {
|
|
51
|
+
case 'CaseOperator': {
|
|
52
|
+
if (config.label.includes('Create operator')) {
|
|
53
|
+
caseSummaryComponentObject.name = pConnect.resolveConfigProps({
|
|
54
|
+
createLabel: config.createLabel
|
|
55
|
+
}).createLabel;
|
|
56
|
+
} else if (config.label.includes('Update operator')) {
|
|
57
|
+
caseSummaryComponentObject.name = pConnect.resolveConfigProps({
|
|
58
|
+
updateLabel: config.updateLabel
|
|
59
|
+
}).updateLabel;
|
|
60
|
+
} else {
|
|
61
|
+
caseSummaryComponentObject.name = pConnect.resolveConfigProps({
|
|
62
|
+
resolveLabel: config.resolveLabel
|
|
63
|
+
}).resolveLabel;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
break;
|
|
67
|
+
}
|
|
68
|
+
case 'Checkbox': {
|
|
69
|
+
caseSummaryComponentObject.name = pConnect.resolveConfigProps({
|
|
70
|
+
label: config.caption
|
|
71
|
+
}).label;
|
|
72
|
+
|
|
73
|
+
break;
|
|
74
|
+
}
|
|
75
|
+
case 'Pega_UI_PercentageWidget': {
|
|
76
|
+
const rawValue = pConnect.resolveConfigProps({
|
|
77
|
+
value: config.value
|
|
78
|
+
}).value;
|
|
79
|
+
|
|
80
|
+
caseSummaryComponentObject.simpleValue = rawValue || rawValue === 0 ? `${rawValue}%` : noValueComponent;
|
|
81
|
+
break;
|
|
82
|
+
}
|
|
83
|
+
case 'Address': {
|
|
84
|
+
showAddressLabel = false;
|
|
85
|
+
|
|
86
|
+
caseSummaryComponentObject.variant = 'stacked';
|
|
87
|
+
break;
|
|
88
|
+
}
|
|
89
|
+
case 'Location':
|
|
90
|
+
case 'RichText': {
|
|
91
|
+
const rawValue = pConnect.resolveConfigProps({
|
|
92
|
+
value: config.value
|
|
93
|
+
}).value;
|
|
94
|
+
|
|
95
|
+
caseSummaryComponentObject.variant = 'stacked';
|
|
96
|
+
caseSummaryComponentObject.simpleValue = rawValue?.length ? rawValue : noValueComponent;
|
|
97
|
+
break;
|
|
98
|
+
}
|
|
99
|
+
case 'TextArea': {
|
|
100
|
+
const rawValue = pConnect.resolveConfigProps({
|
|
101
|
+
value: config.value
|
|
102
|
+
}).value;
|
|
103
|
+
|
|
104
|
+
if (rawValue?.length > 22) {
|
|
105
|
+
caseSummaryComponentObject.variant = 'stacked';
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
caseSummaryComponentObject.simpleValue = rawValue?.length ? rawValue : noValueComponent;
|
|
109
|
+
break;
|
|
110
|
+
}
|
|
111
|
+
case 'URL': {
|
|
112
|
+
if (config.displayAs === 'Image') {
|
|
113
|
+
const rawValue = pConnect.resolveConfigProps({
|
|
114
|
+
value: config.value
|
|
115
|
+
}).value;
|
|
116
|
+
|
|
117
|
+
caseSummaryComponentObject.variant = 'stacked';
|
|
118
|
+
caseSummaryComponentObject.simpleValue = rawValue?.length ? <Link href={rawValue}>{rawValue}</Link> : noValueComponent;
|
|
119
|
+
}
|
|
120
|
+
break;
|
|
121
|
+
}
|
|
122
|
+
case 'reference': {
|
|
123
|
+
const referencedPConnect = resolveReferencedPConnect(pConnect);
|
|
124
|
+
const viewType = referencedPConnect?.meta?.config.type;
|
|
125
|
+
const viewTemplate = referencedPConnect?.meta?.config.template;
|
|
126
|
+
const isTable = ['multirecordlist'].includes(viewType);
|
|
127
|
+
const isDataReference = viewTemplate === 'DataReference';
|
|
128
|
+
|
|
129
|
+
if (isTable || !isDataReference) {
|
|
130
|
+
caseSummaryComponentObject.variant = 'stacked';
|
|
131
|
+
caseSummaryComponentObject.simpleValue = placeholder;
|
|
132
|
+
}
|
|
133
|
+
break;
|
|
134
|
+
}
|
|
135
|
+
case 'view': {
|
|
136
|
+
caseSummaryComponentObject.variant = 'stacked';
|
|
137
|
+
caseSummaryComponentObject.simpleValue = placeholder;
|
|
138
|
+
break;
|
|
139
|
+
}
|
|
140
|
+
default:
|
|
141
|
+
break;
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
const createdComponent = pConnect.createComponent({
|
|
145
|
+
type,
|
|
146
|
+
children: children ? [...children] : [],
|
|
147
|
+
showAddressLabel,
|
|
148
|
+
config: {
|
|
149
|
+
...config,
|
|
150
|
+
// Need a unique key for each summary component which helps in creating new component based on visibility
|
|
151
|
+
// Also a consistent key helps in rerendering summary components instead of remounting
|
|
152
|
+
key: config
|
|
153
|
+
}
|
|
154
|
+
});
|
|
155
|
+
|
|
156
|
+
createdComponent.props.getPConnect().setInheritedProp('displayMode', 'DISPLAY_ONLY');
|
|
157
|
+
createdComponent.props.getPConnect().setInheritedProp('readOnly', true);
|
|
158
|
+
|
|
159
|
+
if (type === 'Address') {
|
|
160
|
+
createdComponent.props.getPConnect().setInheritedProp('showAddressLabel', showAddressLabel);
|
|
161
|
+
}
|
|
162
|
+
// Add field label for reference summary item when not Embedded data
|
|
163
|
+
if (type === 'reference') {
|
|
164
|
+
const isEmbeddedData = config.context && config.displayAs === 'Form';
|
|
165
|
+
if (!isEmbeddedData) {
|
|
166
|
+
caseSummaryComponentObject.name = createdComponent.props.getPConnect().getInheritedProps().label;
|
|
167
|
+
}
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
caseSummaryComponentObject.value = createdComponent;
|
|
171
|
+
|
|
172
|
+
return caseSummaryComponentObject;
|
|
173
|
+
}
|
|
174
|
+
|
|
175
|
+
export function resolveReferenceFields(
|
|
176
|
+
item: {
|
|
177
|
+
[key: string]: unknown;
|
|
178
|
+
},
|
|
179
|
+
hideFieldLabels: boolean,
|
|
180
|
+
recordKey: string,
|
|
181
|
+
pConnect: typeof PConnect
|
|
182
|
+
) {
|
|
183
|
+
const presets: {
|
|
184
|
+
children?: {
|
|
185
|
+
children?: {
|
|
186
|
+
config;
|
|
187
|
+
type;
|
|
188
|
+
};
|
|
189
|
+
config?;
|
|
190
|
+
};
|
|
191
|
+
} = (pConnect.getRawMetadata()?.config as any).presets ?? [];
|
|
192
|
+
|
|
193
|
+
const presetChildren = presets[0]?.children?.[0]?.children ?? [];
|
|
194
|
+
|
|
195
|
+
const maxFields = 5;
|
|
196
|
+
return presetChildren.slice(0, maxFields).map((preset, index) => {
|
|
197
|
+
const fieldMeta = {
|
|
198
|
+
meta: {
|
|
199
|
+
...preset,
|
|
200
|
+
config: {
|
|
201
|
+
...preset.config,
|
|
202
|
+
displayMode: 'DISPLAY_ONLY',
|
|
203
|
+
contextName: pConnect.getContextName()
|
|
204
|
+
}
|
|
205
|
+
},
|
|
206
|
+
useCustomContext: item
|
|
207
|
+
};
|
|
208
|
+
const configObj = PCore.createPConnect(fieldMeta);
|
|
209
|
+
const meta = configObj.getPConnect().getMetadata();
|
|
210
|
+
const fieldInfo: {
|
|
211
|
+
name?: string;
|
|
212
|
+
value?: React.ReactNode;
|
|
213
|
+
} = meta ? prepareComponentInCaseSummary(meta, configObj.getPConnect) : {};
|
|
214
|
+
return hideFieldLabels
|
|
215
|
+
? { id: `${item[recordKey]} - ${index}`, value: fieldInfo.value }
|
|
216
|
+
: {
|
|
217
|
+
id: `${item[recordKey]} - ${index}`,
|
|
218
|
+
name: fieldInfo.name,
|
|
219
|
+
value: fieldInfo.value,
|
|
220
|
+
type: preset.type
|
|
221
|
+
};
|
|
222
|
+
});
|
|
223
|
+
}
|