@pega/react-sdk-overrides 23.1.10 → 23.1.12
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/LICENSE +201 -0
- package/README.md +17 -0
- package/SECURITY.md +10 -0
- package/lib/designSystemExtension/AlertBanner/AlertBanner.tsx +6 -14
- package/lib/designSystemExtension/Banner/Banner.tsx +14 -11
- package/lib/designSystemExtension/CaseSummaryFields/CaseSummaryFields.css +0 -1
- package/lib/designSystemExtension/CaseSummaryFields/CaseSummaryFields.tsx +27 -22
- package/lib/designSystemExtension/DetailsFields/DetailsFields.tsx +14 -20
- package/lib/designSystemExtension/DetailsFields/index.tsx +1 -1
- package/lib/designSystemExtension/FieldGroup/FieldGroup.tsx +44 -19
- package/lib/designSystemExtension/FieldGroupList/FieldGroupList.tsx +7 -12
- package/lib/designSystemExtension/FieldValueList/FieldValueList.tsx +21 -32
- package/lib/designSystemExtension/Operator/Operator.tsx +94 -82
- package/lib/designSystemExtension/Pulse/Pulse.tsx +14 -16
- package/lib/designSystemExtension/RichTextEditor/RichTextEditor.tsx +6 -5
- package/lib/designSystemExtension/WssQuickCreate/WssQuickCreate.tsx +14 -14
- package/lib/field/AutoComplete/AutoComplete.tsx +24 -26
- package/lib/field/AutoComplete/config-ext.json +2 -3
- package/lib/field/CancelAlert/CancelAlert.tsx +98 -84
- package/lib/field/CancelAlert/index.tsx +1 -1
- package/lib/field/Checkbox/Checkbox.tsx +120 -63
- package/lib/field/Checkbox/config-ext.json +2 -3
- package/lib/field/Currency/Currency.tsx +25 -50
- package/lib/field/Currency/config-ext.json +2 -3
- package/lib/field/Currency/currency-utils.ts +9 -16
- package/lib/field/Date/Date.tsx +15 -11
- package/lib/field/Date/config-ext.json +2 -3
- package/lib/field/DateTime/DateTime.tsx +9 -9
- package/lib/field/DateTime/config-ext.json +1 -2
- package/lib/field/Decimal/Decimal.tsx +33 -44
- package/lib/field/Decimal/config-ext.json +1 -2
- package/lib/field/Decimal/index.tsx +1 -1
- package/lib/field/Dropdown/Dropdown.tsx +122 -31
- package/lib/field/Dropdown/config-ext.json +1 -2
- package/lib/field/Email/Email.tsx +11 -10
- package/lib/field/Email/config-ext.json +1 -2
- package/lib/field/Email/index.tsx +1 -1
- package/lib/field/Group/Group.tsx +39 -0
- package/lib/field/Group/config-ext.json +7 -0
- package/lib/field/Group/index.tsx +1 -0
- package/lib/field/Integer/Integer.tsx +8 -7
- package/lib/field/Integer/config-ext.json +1 -2
- package/lib/field/MultiSelect/Multiselect.tsx +244 -0
- package/lib/field/MultiSelect/index.tsx +1 -0
- package/lib/field/MultiSelect/utils.ts +230 -0
- package/lib/field/Percentage/Percentage.tsx +46 -41
- package/lib/field/Percentage/config-ext.json +1 -2
- package/lib/field/Phone/Phone.tsx +13 -12
- package/lib/field/Phone/index.tsx +1 -1
- package/lib/field/RadioButtons/RadioButtons.tsx +20 -18
- package/lib/field/RadioButtons/config-ext.json +1 -2
- package/lib/field/RichText/RichText.tsx +8 -7
- package/lib/field/ScalarList/ScalarList.tsx +3 -13
- package/lib/field/ScalarList/config-ext.json +1 -2
- package/lib/field/SemanticLink/SemanticLink.tsx +7 -7
- package/lib/field/SemanticLink/config-ext.json +1 -2
- package/lib/field/SemanticLink/utils.ts +8 -11
- package/lib/field/TextArea/TextArea.tsx +7 -6
- package/lib/field/TextArea/config-ext.json +1 -2
- package/lib/field/TextContent/TextContent.tsx +4 -6
- package/lib/field/TextContent/config-ext.json +1 -2
- package/lib/field/TextInput/TextInput.tsx +9 -7
- package/lib/field/TextInput/config-ext.json +1 -2
- package/lib/field/TextInput/index.tsx +1 -1
- package/lib/field/Time/Time.tsx +11 -11
- package/lib/field/Time/config-ext.json +1 -2
- package/lib/field/URL/URL.tsx +9 -8
- package/lib/field/URL/config-ext.json +1 -2
- package/lib/field/URL/index.tsx +1 -1
- package/lib/field/UserReference/UserReference.tsx +18 -16
- package/lib/field/UserReference/UserReferenceUtils.ts +2 -2
- package/lib/field/UserReference/config-ext.json +1 -2
- package/lib/helpers/attachmentHelpers.ts +13 -8
- package/lib/helpers/case-utils.tsx +4 -8
- package/lib/helpers/common-utils.ts +5 -1
- package/lib/helpers/data_page.ts +3 -7
- package/lib/helpers/date-format-utils.ts +3 -3
- package/lib/helpers/event-utils.ts +3 -3
- package/lib/helpers/field-group-utils.ts +1 -1
- package/lib/helpers/formatters/Boolean.ts +9 -26
- package/lib/helpers/formatters/Currency.ts +15 -21
- package/lib/helpers/formatters/CurrencyMap.ts +505 -501
- package/lib/helpers/formatters/Date.ts +20 -26
- package/lib/helpers/formatters/common.ts +1 -2
- package/lib/helpers/formatters/index.ts +26 -19
- package/lib/helpers/instructions-utils.ts +38 -0
- package/lib/helpers/reactContextHelpers.ts +2 -2
- package/lib/helpers/simpleTableHelpers.ts +59 -83
- package/lib/helpers/state-utils.tsx +5 -9
- package/lib/helpers/template-utils.ts +3 -6
- package/lib/helpers/utils.ts +5 -5
- package/lib/helpers/versionHelpers.ts +1 -4
- package/lib/infra/ActionButtons/ActionButtons.tsx +38 -29
- package/lib/infra/ActionButtons/index.tsx +1 -1
- package/lib/infra/Assignment/Assignment.tsx +99 -79
- package/lib/infra/Assignment/index.tsx +1 -1
- package/lib/infra/AssignmentCard/AssignmentCard.tsx +13 -16
- package/lib/infra/AssignmentCard/index.tsx +1 -1
- package/lib/infra/Containers/FlowContainer/FlowContainer.tsx +67 -213
- package/lib/infra/Containers/FlowContainer/helpers.ts +34 -45
- package/lib/infra/Containers/FlowContainer/index.tsx +1 -1
- package/lib/infra/Containers/ModalViewContainer/ListViewActionButtons/ListViewActionButtons.tsx +65 -0
- package/lib/infra/Containers/ModalViewContainer/ListViewActionButtons/index.tsx +1 -0
- package/lib/infra/Containers/ModalViewContainer/ModalViewContainer.tsx +227 -218
- package/lib/infra/Containers/ModalViewContainer/index.tsx +1 -1
- package/lib/infra/Containers/SimpleView/SimpleView.tsx +48 -0
- package/lib/infra/Containers/SimpleView/helper.ts +125 -0
- package/lib/infra/Containers/SimpleView/index.tsx +1 -0
- package/lib/infra/Containers/ViewContainer/ViewContainer.tsx +36 -46
- package/lib/infra/Containers/helpers.ts +6 -0
- package/lib/infra/DashboardFilter/DashboardFilter.tsx +21 -42
- package/lib/infra/DashboardFilter/filterUtils.tsx +12 -43
- package/lib/infra/DeferLoad/DeferLoad.tsx +22 -28
- package/lib/infra/DeferLoad/index.tsx +1 -1
- package/lib/infra/ErrorBoundary/ErrorBoundary.tsx +16 -30
- package/lib/infra/MultiStep/MultiStep.css +11 -15
- package/lib/infra/MultiStep/MultiStep.tsx +176 -212
- package/lib/infra/MultiStep/index.tsx +1 -1
- package/lib/infra/NavBar/NavBar.css +103 -105
- package/lib/infra/NavBar/NavBar.tsx +19 -31
- package/lib/infra/Reference/Reference.tsx +16 -18
- package/lib/infra/Region/Region.tsx +4 -6
- package/lib/infra/RootContainer/RootContainer.tsx +75 -111
- package/lib/infra/RootContainer/index.tsx +1 -1
- package/lib/infra/Stages/Stages.tsx +32 -39
- package/lib/infra/VerticalTabs/LeftAlignVerticalTabs/LeftAlignVerticalTabs.tsx +11 -11
- package/lib/infra/VerticalTabs/VerticalTabs/VerticalTabs.tsx +21 -28
- package/lib/infra/View/View.tsx +17 -21
- package/lib/template/AppShell/AppShell.css +22 -23
- package/lib/template/AppShell/AppShell.tsx +39 -74
- package/lib/template/BannerPage/BannerPage.tsx +12 -14
- package/lib/template/CaseSummary/CaseSummary.tsx +58 -18
- package/lib/template/CaseSummary/config-ext.json +1 -2
- package/lib/template/CaseView/CaseView.tsx +34 -63
- package/lib/template/CaseView/config-ext.json +1 -2
- package/lib/template/CaseViewActionsMenu/CaseViewActionsMenu.tsx +63 -19
- package/lib/template/Confirmation/Confirmation.tsx +12 -17
- package/lib/template/Confirmation/config-ext.json +1 -2
- package/lib/template/DataReference/DataReference.tsx +95 -121
- package/lib/template/DataReference/config-ext.json +1 -2
- package/lib/template/DefaultForm/DefaultForm.css +7 -3
- package/lib/template/DefaultForm/DefaultForm.tsx +13 -16
- package/lib/template/DefaultForm/config-ext.json +1 -2
- package/lib/template/Details/Details/Details.tsx +19 -22
- package/lib/template/Details/DetailsSubTabs/DetailsSubTabs.tsx +9 -13
- package/lib/template/Details/DetailsSubTabs/config-ext.json +1 -2
- package/lib/template/Details/DetailsThreeColumn/DetailsThreeColumn.tsx +19 -24
- package/lib/template/Details/DetailsThreeColumn/config-ext.json +1 -2
- package/lib/template/Details/DetailsTwoColumn/DetailsTwoColumn.tsx +19 -25
- package/lib/template/Details/DetailsTwoColumn/config-ext.json +1 -2
- package/lib/template/Details/DetailsTwoColumn/index.tsx +1 -1
- package/lib/template/Details/DynamicTabs/DynamicTabs.tsx +15 -14
- package/lib/template/FieldGroupTemplate/FieldGroupTemplate.tsx +15 -22
- package/lib/template/InlineDashboard/InlineDashboard.tsx +12 -14
- package/lib/template/InlineDashboardPage/InlineDashboardPage.tsx +12 -16
- package/lib/template/ListPage/ListPage.tsx +5 -10
- package/lib/template/ListPage/config-ext.json +1 -2
- package/lib/template/ListView/DefaultViewMeta.ts +1 -3
- package/lib/template/ListView/ListView.tsx +185 -175
- package/lib/template/ListView/config-ext.json +1 -2
- package/lib/template/ListView/hooks.ts +24 -26
- package/lib/template/ListView/utils.ts +51 -87
- package/lib/template/MultiReferenceReadOnly/MultiReferenceReadOnly.tsx +20 -20
- package/lib/template/NarrowWide/NarrowWide/NarrowWide.css +0 -2
- package/lib/template/NarrowWide/NarrowWide/NarrowWide.tsx +25 -38
- package/lib/template/NarrowWide/NarrowWideDetails/NarrowWideDetails.tsx +20 -25
- package/lib/template/NarrowWide/NarrowWideDetails/config-ext.json +1 -2
- package/lib/template/NarrowWide/NarrowWideForm/NarrowWideForm.css +0 -2
- package/lib/template/NarrowWide/NarrowWideForm/NarrowWideForm.tsx +14 -24
- package/lib/template/NarrowWide/NarrowWideForm/config-ext.json +1 -2
- package/lib/template/NarrowWide/NarrowWidePage/NarrowWidePage.tsx +9 -19
- package/lib/template/NarrowWide/NarrowWidePage/config-ext.json +1 -2
- package/lib/template/OneColumn/OneColumn/OneColumn.tsx +14 -15
- package/lib/template/OneColumn/OneColumn/config-ext.json +1 -2
- package/lib/template/OneColumn/OneColumnPage/OneColumnPage.tsx +3 -10
- package/lib/template/OneColumn/OneColumnPage/config-ext.json +1 -2
- package/lib/template/OneColumn/OneColumnTab/OneColumnTab.tsx +6 -10
- package/lib/template/OneColumn/OneColumnTab/config-ext.json +1 -2
- package/lib/template/PromotedFilters/PromotedFilters.css +1 -1
- package/lib/template/PromotedFilters/PromotedFilters.tsx +32 -28
- package/lib/template/SimpleTable/SimpleTable/SimpleTable.tsx +37 -33
- package/lib/template/SimpleTable/SimpleTable/config-ext.json +1 -2
- package/lib/template/SimpleTable/SimpleTableManual/SimpleTableManual.tsx +187 -121
- package/lib/template/SimpleTable/SimpleTableSelect/SimpleTableSelect.tsx +24 -25
- package/lib/template/SingleReferenceReadOnly/SingleReferenceReadOnly.tsx +30 -30
- package/lib/template/SubTabs/SubTabs.tsx +22 -40
- package/lib/template/SubTabs/config-ext.json +1 -2
- package/lib/template/SubTabs/tabUtils.ts +2 -5
- package/lib/template/TwoColumn/TwoColumn/TwoColumn.css +0 -1
- package/lib/template/TwoColumn/TwoColumn/TwoColumn.tsx +30 -28
- package/lib/template/TwoColumn/TwoColumn/config-ext.json +1 -2
- package/lib/template/TwoColumn/TwoColumnPage/TwoColumnPage.tsx +3 -10
- package/lib/template/TwoColumn/TwoColumnPage/config-ext.json +1 -2
- package/lib/template/TwoColumn/TwoColumnTab/TwoColumnTab.tsx +30 -28
- package/lib/template/TwoColumn/TwoColumnTab/config-ext.json +1 -2
- package/lib/template/WideNarrow/WideNarrow/WideNarrow.css +0 -2
- package/lib/template/WideNarrow/WideNarrow/WideNarrow.tsx +22 -34
- package/lib/template/WideNarrow/WideNarrowDetails/WideNarrowDetails.tsx +24 -28
- package/lib/template/WideNarrow/WideNarrowDetails/config-ext.json +1 -2
- package/lib/template/WideNarrow/WideNarrowForm/WideNarrowForm.css +0 -2
- package/lib/template/WideNarrow/WideNarrowForm/WideNarrowForm.tsx +13 -21
- package/lib/template/WideNarrow/WideNarrowForm/config-ext.json +1 -2
- package/lib/template/WideNarrow/WideNarrowPage/WideNarrowPage.tsx +8 -16
- package/lib/template/WideNarrow/WideNarrowPage/config-ext.json +1 -2
- package/lib/template/WideNarrow/WideNarrowPage/index.tsx +1 -1
- package/lib/template/WssNavBar/WssNavBar.tsx +18 -21
- package/lib/widget/AppAnnouncement/AppAnnouncement.tsx +29 -28
- package/lib/widget/AppAnnouncement/config-ext.json +1 -2
- package/lib/widget/Attachment/Attachment.css +60 -1
- package/lib/widget/Attachment/Attachment.tsx +378 -405
- package/lib/widget/Attachment/index.tsx +1 -1
- package/lib/widget/CaseHistory/CaseHistory.tsx +64 -66
- package/lib/widget/CaseHistory/config-ext.json +1 -2
- package/lib/widget/CaseHistory/index.tsx +1 -1
- package/lib/widget/FileUtility/ActionButtonsForFileUtil/ActionButtonsForFileUtil.tsx +16 -18
- package/lib/widget/FileUtility/FileUtility/FileUtility.css +2 -2
- package/lib/widget/FileUtility/FileUtility/FileUtility.tsx +310 -246
- package/lib/widget/FileUtility/FileUtility/config-ext.json +1 -2
- package/lib/widget/Followers/Followers.tsx +23 -20
- package/lib/widget/Followers/config-ext.json +1 -2
- package/lib/widget/QuickCreate/QuickCreate.tsx +68 -42
- package/lib/widget/SummaryItem/SummaryItem.css +9 -9
- package/lib/widget/SummaryItem/SummaryItem.tsx +58 -58
- package/lib/widget/SummaryItem/index.tsx +1 -1
- package/lib/widget/SummaryList/SummaryList.tsx +7 -10
- package/lib/widget/ToDo/ToDo.css +4 -4
- package/lib/widget/ToDo/ToDo.tsx +52 -53
- package/lib/widget/ToDo/config-ext.json +1 -2
- package/package.json +5 -2
- package/lib/helpers/auth.js +0 -834
- package/lib/helpers/authManager.ts +0 -933
- package/lib/helpers/config_access.js +0 -186
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
1
|
import Typography from '@material-ui/core/Typography';
|
|
3
2
|
import Grid from '@material-ui/core/Grid';
|
|
4
3
|
import { makeStyles } from '@material-ui/core/styles';
|
|
4
|
+
|
|
5
5
|
import { getComponentFromMap } from '@pega/react-sdk-components/lib/bridge/helpers/sdk_component_map';
|
|
6
|
-
import
|
|
6
|
+
import { PConnFieldProps } from '@pega/react-sdk-components/lib/types/PConnProps';
|
|
7
7
|
|
|
8
8
|
/* although this is called the SemanticLink component, we are not yet displaying as a
|
|
9
9
|
SemanticLink in SDK and only showing the value as a read only text field. */
|
|
10
10
|
|
|
11
|
-
const useStyles = makeStyles(
|
|
11
|
+
const useStyles = makeStyles(theme => ({
|
|
12
12
|
root: {
|
|
13
13
|
paddingRight: theme.spacing(1),
|
|
14
14
|
paddingLeft: theme.spacing(1),
|
|
@@ -55,14 +55,14 @@ export default function SemanticLink(props: SemanticLinkProps) {
|
|
|
55
55
|
if (displayMode === 'LABELS_LEFT' || (!displayMode && label !== undefined)) {
|
|
56
56
|
const value = text || '---';
|
|
57
57
|
return (
|
|
58
|
-
<Grid container spacing={1} style={{ padding: '4px 0px' }} id=
|
|
58
|
+
<Grid container spacing={1} style={{ padding: '4px 0px' }} id='semantic-link-grid'>
|
|
59
59
|
<Grid item xs={6}>
|
|
60
|
-
<Typography variant=
|
|
60
|
+
<Typography variant='body2' component='span' className={`${classes.fieldLabel} ${classes.fieldMargin}`}>
|
|
61
61
|
{label}
|
|
62
62
|
</Typography>
|
|
63
63
|
</Grid>
|
|
64
64
|
<Grid item xs={6}>
|
|
65
|
-
<Typography variant=
|
|
65
|
+
<Typography variant='body2' component='span' className={classes.fieldValue}>
|
|
66
66
|
{value}
|
|
67
67
|
</Typography>
|
|
68
68
|
</Grid>
|
|
@@ -71,6 +71,6 @@ export default function SemanticLink(props: SemanticLinkProps) {
|
|
|
71
71
|
}
|
|
72
72
|
|
|
73
73
|
if (displayMode === 'STACKED_LARGE_VAL') {
|
|
74
|
-
return <FieldValueList name={hideLabel ? '' : label} value={text} variant=
|
|
74
|
+
return <FieldValueList name={hideLabel ? '' : label} value={text} variant='stacked' />;
|
|
75
75
|
}
|
|
76
76
|
}
|
|
@@ -1,12 +1,9 @@
|
|
|
1
|
-
// Remove this and use "real" PCore type once .d.ts is fixed (currently shows 2 errors)
|
|
2
|
-
declare const PCore: any;
|
|
3
|
-
|
|
4
1
|
function getDataReferenceInfo(pConnect, dataRelationshipContext) {
|
|
5
2
|
if (!pConnect) {
|
|
6
|
-
throw Error(
|
|
3
|
+
throw Error('PConnect parameter is required');
|
|
7
4
|
}
|
|
8
5
|
|
|
9
|
-
let dataContext =
|
|
6
|
+
let dataContext = '';
|
|
10
7
|
const payload = {};
|
|
11
8
|
const pageReference = pConnect.getPageReference();
|
|
12
9
|
const annotationUtils = PCore.getAnnotationUtils();
|
|
@@ -17,7 +14,7 @@ function getDataReferenceInfo(pConnect, dataRelationshipContext) {
|
|
|
17
14
|
For page list the page refernce will be something like caseInfo.content.EmployeeRef[1].
|
|
18
15
|
Need to extract EmployeeRef from caseInfo.content.EmployeeRef[1]
|
|
19
16
|
*/
|
|
20
|
-
const propertySplit = pageReference.split(
|
|
17
|
+
const propertySplit = pageReference.split('.');
|
|
21
18
|
|
|
22
19
|
// Regex to match if the property is list type. Eg: EmployeeRef[1]
|
|
23
20
|
const listPropertyRegex = /([a-z|A-Z]*[[][\d]*)[\]]$/gm;
|
|
@@ -26,9 +23,7 @@ function getDataReferenceInfo(pConnect, dataRelationshipContext) {
|
|
|
26
23
|
|
|
27
24
|
let contextProperty = dataRelationshipContext !== null ? dataRelationshipContext : propertySplit.pop();
|
|
28
25
|
const isListProperty = listPropertyRegex.test(contextProperty);
|
|
29
|
-
contextProperty = isListProperty
|
|
30
|
-
? contextProperty.replace(indexRegex, "")
|
|
31
|
-
: contextProperty;
|
|
26
|
+
contextProperty = isListProperty ? contextProperty.replace(indexRegex, '') : contextProperty;
|
|
32
27
|
fieldMetadata = pConnect.getFieldMetadata(contextProperty);
|
|
33
28
|
}
|
|
34
29
|
|
|
@@ -36,7 +31,9 @@ function getDataReferenceInfo(pConnect, dataRelationshipContext) {
|
|
|
36
31
|
const { name, parameters } = fieldMetadata.datasource;
|
|
37
32
|
dataContext = name;
|
|
38
33
|
for (const [key, value] of Object.entries(parameters)) {
|
|
39
|
-
const property =
|
|
34
|
+
const property =
|
|
35
|
+
// @ts-ignore - Property 'getLeafPropertyName' is private and only accessible within class 'AnnotationUtils'
|
|
36
|
+
dataRelationshipContext !== null ? annotationUtils.getPropertyName(value as string) : annotationUtils.getLeafPropertyName(value);
|
|
40
37
|
payload[key] = pConnect.getValue(`.${property}`);
|
|
41
38
|
}
|
|
42
39
|
return { dataContext, dataContextParameters: payload };
|
|
@@ -46,7 +43,7 @@ function getDataReferenceInfo(pConnect, dataRelationshipContext) {
|
|
|
46
43
|
}
|
|
47
44
|
|
|
48
45
|
function isLinkTextEmpty(text) {
|
|
49
|
-
return text ===
|
|
46
|
+
return text === '' || text === undefined || text === null;
|
|
50
47
|
}
|
|
51
48
|
|
|
52
49
|
export default { getDataReferenceInfo, isLinkTextEmpty };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
1
|
import { TextField } from '@material-ui/core';
|
|
2
|
+
|
|
3
3
|
import { getComponentFromMap } from '@pega/react-sdk-components/lib/bridge/helpers/sdk_component_map';
|
|
4
|
-
import
|
|
4
|
+
import { PConnFieldProps } from '@pega/react-sdk-components/lib/types/PConnProps';
|
|
5
5
|
|
|
6
6
|
interface TextAreaProps extends PConnFieldProps {
|
|
7
7
|
// If any, enter additional props that only exist on TextArea here
|
|
@@ -26,7 +26,8 @@ export default function TextArea(props: TextAreaProps) {
|
|
|
26
26
|
fieldMetadata,
|
|
27
27
|
helperText,
|
|
28
28
|
displayMode,
|
|
29
|
-
hideLabel
|
|
29
|
+
hideLabel,
|
|
30
|
+
placeholder
|
|
30
31
|
} = props;
|
|
31
32
|
const helperTextToDisplay = validatemessage || helperText;
|
|
32
33
|
|
|
@@ -39,7 +40,7 @@ export default function TextArea(props: TextAreaProps) {
|
|
|
39
40
|
}
|
|
40
41
|
|
|
41
42
|
if (displayMode === 'STACKED_LARGE_VAL') {
|
|
42
|
-
return <FieldValueList name={hideLabel ? '' : label} value={value} variant=
|
|
43
|
+
return <FieldValueList name={hideLabel ? '' : label} value={value} variant='stacked' />;
|
|
43
44
|
}
|
|
44
45
|
|
|
45
46
|
if (readOnly) {
|
|
@@ -62,8 +63,8 @@ export default function TextArea(props: TextAreaProps) {
|
|
|
62
63
|
fullWidth
|
|
63
64
|
variant={readOnly ? 'standard' : 'outlined'}
|
|
64
65
|
helperText={helperTextToDisplay}
|
|
65
|
-
placeholder=
|
|
66
|
-
size=
|
|
66
|
+
placeholder={placeholder ?? ''}
|
|
67
|
+
size='small'
|
|
67
68
|
required={required}
|
|
68
69
|
disabled={disabled}
|
|
69
70
|
onChange={onChange}
|
|
@@ -1,15 +1,13 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
1
|
import { Typography } from '@material-ui/core';
|
|
3
|
-
|
|
2
|
+
|
|
3
|
+
import { PConnProps } from '@pega/react-sdk-components/lib/types/PConnProps';
|
|
4
4
|
|
|
5
5
|
interface TextContentProps extends PConnProps {
|
|
6
6
|
// If any, enter additional props that only exist on TextContent here
|
|
7
|
-
content: string
|
|
8
|
-
displayAs: 'Paragraph' | 'Heading 1' | 'Heading 2' | 'Heading 3' | 'Heading 4'
|
|
7
|
+
content: string;
|
|
8
|
+
displayAs: 'Paragraph' | 'Heading 1' | 'Heading 2' | 'Heading 3' | 'Heading 4';
|
|
9
9
|
}
|
|
10
10
|
|
|
11
|
-
|
|
12
|
-
|
|
13
11
|
export default function TextContent(props: TextContentProps) {
|
|
14
12
|
type ExpectedDisplayAs = 'Paragraph' | 'Heading 1' | 'Heading 2' | 'Heading 3' | 'Heading 4';
|
|
15
13
|
type ExpectedVariants = 'body1' | 'h1' | 'h2' | 'h3' | 'h4';
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { useState, useEffect } from 'react';
|
|
2
2
|
import { TextField } from '@material-ui/core';
|
|
3
|
+
|
|
3
4
|
import handleEvent from '@pega/react-sdk-components/lib/components/helpers/event-utils';
|
|
4
5
|
import { getComponentFromMap } from '@pega/react-sdk-components/lib/bridge/helpers/sdk_component_map';
|
|
5
|
-
import
|
|
6
|
+
import { PConnFieldProps } from '@pega/react-sdk-components/lib/types/PConnProps';
|
|
6
7
|
|
|
7
8
|
interface TextInputProps extends PConnFieldProps {
|
|
8
9
|
// If any, enter additional props that only exist on TextInput here
|
|
@@ -27,12 +28,13 @@ export default function TextInput(props: TextInputProps) {
|
|
|
27
28
|
fieldMetadata,
|
|
28
29
|
helperText,
|
|
29
30
|
displayMode,
|
|
30
|
-
hideLabel
|
|
31
|
+
hideLabel,
|
|
32
|
+
placeholder
|
|
31
33
|
} = props;
|
|
32
34
|
|
|
33
35
|
const pConn = getPConnect();
|
|
34
36
|
const actions = pConn.getActionsApi();
|
|
35
|
-
const propName = pConn.getStateProps()
|
|
37
|
+
const propName = (pConn.getStateProps() as any).value;
|
|
36
38
|
|
|
37
39
|
const helperTextToDisplay = validatemessage || helperText;
|
|
38
40
|
|
|
@@ -50,7 +52,7 @@ export default function TextInput(props: TextInputProps) {
|
|
|
50
52
|
}
|
|
51
53
|
|
|
52
54
|
if (displayMode === 'STACKED_LARGE_VAL') {
|
|
53
|
-
return <FieldValueList name={hideLabel ? '' : label} value={value} variant=
|
|
55
|
+
return <FieldValueList name={hideLabel ? '' : label} value={value} variant='stacked' />;
|
|
54
56
|
}
|
|
55
57
|
|
|
56
58
|
if (readOnly) {
|
|
@@ -77,8 +79,8 @@ export default function TextInput(props: TextInputProps) {
|
|
|
77
79
|
fullWidth
|
|
78
80
|
variant={readOnly ? 'standard' : 'outlined'}
|
|
79
81
|
helperText={helperTextToDisplay}
|
|
80
|
-
placeholder=
|
|
81
|
-
size=
|
|
82
|
+
placeholder={placeholder ?? ''}
|
|
83
|
+
size='small'
|
|
82
84
|
required={required}
|
|
83
85
|
disabled={disabled}
|
|
84
86
|
onChange={handleChange}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { default } from './TextInput';
|
|
1
|
+
export { default } from './TextInput';
|
package/lib/field/Time/Time.tsx
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
1
|
import { KeyboardTimePicker } from '@material-ui/pickers';
|
|
3
2
|
import AccessTimeIcon from '@material-ui/icons/AccessTime';
|
|
4
3
|
import dayjs from 'dayjs';
|
|
4
|
+
|
|
5
5
|
import { getComponentFromMap } from '@pega/react-sdk-components/lib/bridge/helpers/sdk_component_map';
|
|
6
|
-
import
|
|
6
|
+
import { PConnFieldProps } from '@pega/react-sdk-components/lib/types/PConnProps';
|
|
7
7
|
|
|
8
8
|
interface TimeProps extends PConnFieldProps {
|
|
9
9
|
// If any, enter additional props that only exist on Time here
|
|
@@ -22,7 +22,7 @@ export default function Time(props: TimeProps) {
|
|
|
22
22
|
}
|
|
23
23
|
|
|
24
24
|
if (displayMode === 'STACKED_LARGE_VAL') {
|
|
25
|
-
return <FieldValueList name={hideLabel ? '' : label} value={value} variant=
|
|
25
|
+
return <FieldValueList name={hideLabel ? '' : label} value={value} variant='stacked' />;
|
|
26
26
|
}
|
|
27
27
|
|
|
28
28
|
if (readOnly) {
|
|
@@ -35,14 +35,14 @@ export default function Time(props: TimeProps) {
|
|
|
35
35
|
'data-test-id': testId
|
|
36
36
|
};
|
|
37
37
|
|
|
38
|
-
const handleChange =
|
|
38
|
+
const handleChange = date => {
|
|
39
39
|
const theValue = date && date.isValid() ? date.format('HH:mm') : null;
|
|
40
40
|
onChange({ value: theValue });
|
|
41
41
|
};
|
|
42
42
|
|
|
43
43
|
let timeValue: any = null;
|
|
44
44
|
if (value) {
|
|
45
|
-
const timeArray = value.split(':').map(
|
|
45
|
+
const timeArray = value.split(':').map(itm => Number(itm));
|
|
46
46
|
timeValue = dayjs().hour(timeArray[0]).minute(timeArray[1]);
|
|
47
47
|
}
|
|
48
48
|
|
|
@@ -53,9 +53,9 @@ export default function Time(props: TimeProps) {
|
|
|
53
53
|
|
|
54
54
|
return (
|
|
55
55
|
<KeyboardTimePicker
|
|
56
|
-
variant=
|
|
57
|
-
inputVariant=
|
|
58
|
-
placeholder=
|
|
56
|
+
variant='inline'
|
|
57
|
+
inputVariant='outlined'
|
|
58
|
+
placeholder='hh:mm am'
|
|
59
59
|
keyboardIcon={<AccessTimeIcon />}
|
|
60
60
|
fullWidth
|
|
61
61
|
required={required}
|
|
@@ -63,11 +63,11 @@ export default function Time(props: TimeProps) {
|
|
|
63
63
|
error={status === 'error'}
|
|
64
64
|
helperText={helperTextToDisplay}
|
|
65
65
|
minutesStep={5}
|
|
66
|
-
size=
|
|
66
|
+
size='small'
|
|
67
67
|
label={label}
|
|
68
68
|
autoOk
|
|
69
|
-
mask=
|
|
70
|
-
format=
|
|
69
|
+
mask='__:__ _m'
|
|
70
|
+
format='hh:mm a'
|
|
71
71
|
value={timeValue}
|
|
72
72
|
onChange={handleChange}
|
|
73
73
|
InputProps={{ inputProps: { ...testProp } }}
|
package/lib/field/URL/URL.tsx
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
1
|
import { TextField } from '@material-ui/core';
|
|
2
|
+
|
|
3
3
|
import { getComponentFromMap } from '@pega/react-sdk-components/lib/bridge/helpers/sdk_component_map';
|
|
4
|
-
import
|
|
4
|
+
import { PConnFieldProps } from '@pega/react-sdk-components/lib/types/PConnProps';
|
|
5
5
|
|
|
6
6
|
interface URLComponentProps extends PConnFieldProps {
|
|
7
7
|
// If any, enter additional props that only exist on URLComponent here
|
|
@@ -28,7 +28,8 @@ export default function URLComponent(props: URLComponentProps) {
|
|
|
28
28
|
testId,
|
|
29
29
|
helperText,
|
|
30
30
|
displayMode,
|
|
31
|
-
hideLabel
|
|
31
|
+
hideLabel,
|
|
32
|
+
placeholder
|
|
32
33
|
} = props;
|
|
33
34
|
const helperTextToDisplay = validatemessage || helperText;
|
|
34
35
|
|
|
@@ -37,7 +38,7 @@ export default function URLComponent(props: URLComponentProps) {
|
|
|
37
38
|
}
|
|
38
39
|
|
|
39
40
|
if (displayMode === 'STACKED_LARGE_VAL') {
|
|
40
|
-
return <FieldValueList name={hideLabel ? '' : label} value={value} variant=
|
|
41
|
+
return <FieldValueList name={hideLabel ? '' : label} value={value} variant='stacked' />;
|
|
41
42
|
}
|
|
42
43
|
|
|
43
44
|
if (readOnly) {
|
|
@@ -52,12 +53,12 @@ export default function URLComponent(props: URLComponentProps) {
|
|
|
52
53
|
|
|
53
54
|
return (
|
|
54
55
|
<TextField
|
|
55
|
-
type=
|
|
56
|
+
type='url'
|
|
56
57
|
fullWidth
|
|
57
|
-
variant=
|
|
58
|
+
variant='outlined'
|
|
58
59
|
helperText={helperTextToDisplay}
|
|
59
|
-
placeholder=
|
|
60
|
-
size=
|
|
60
|
+
placeholder={placeholder ?? ''}
|
|
61
|
+
size='small'
|
|
61
62
|
required={required}
|
|
62
63
|
disabled={disabled}
|
|
63
64
|
onChange={onChange}
|
package/lib/field/URL/index.tsx
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export { default } from './URL';
|
|
1
|
+
export { default } from './URL';
|
|
@@ -1,11 +1,10 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { memo, useEffect, useState } from 'react';
|
|
2
2
|
import { Typography } from '@material-ui/core';
|
|
3
|
-
|
|
3
|
+
|
|
4
4
|
import { getComponentFromMap } from '@pega/react-sdk-components/lib/bridge/helpers/sdk_component_map';
|
|
5
|
-
import
|
|
5
|
+
import { PConnProps } from '@pega/react-sdk-components/lib/types/PConnProps';
|
|
6
6
|
|
|
7
|
-
|
|
8
|
-
declare const PCore: any;
|
|
7
|
+
import { getUserId, isUserNameAvailable } from './UserReferenceUtils';
|
|
9
8
|
|
|
10
9
|
const DROPDOWN_LIST = 'Drop-down list';
|
|
11
10
|
const SEARCH_BOX = 'Search box';
|
|
@@ -50,7 +49,7 @@ const UserReference = (props: UserReferenceProps) => {
|
|
|
50
49
|
required = false,
|
|
51
50
|
disabled = false,
|
|
52
51
|
onChange,
|
|
53
|
-
// eslint-disable-next-line
|
|
52
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
54
53
|
variant = 'inline'
|
|
55
54
|
} = props;
|
|
56
55
|
const [dropDownDataSource, setDropDownDataSource] = useState([]);
|
|
@@ -66,7 +65,7 @@ const UserReference = (props: UserReferenceProps) => {
|
|
|
66
65
|
// if same user ref field is referred in view as editable & readonly formatted text
|
|
67
66
|
// referenced users won't be available, so get user details from dx api
|
|
68
67
|
const { getOperatorDetails } = PCore.getUserApi();
|
|
69
|
-
getOperatorDetails(userId).then((res) => {
|
|
68
|
+
getOperatorDetails(userId).then((res: any) => {
|
|
70
69
|
if (res.data && res.data.pyOperatorInfo && res.data.pyOperatorInfo.pyUserName) {
|
|
71
70
|
setUserName(res.data.pyOperatorInfo.pyUserName);
|
|
72
71
|
}
|
|
@@ -76,16 +75,19 @@ const UserReference = (props: UserReferenceProps) => {
|
|
|
76
75
|
const queryPayload = {
|
|
77
76
|
dataViewName: OPERATORS_DP
|
|
78
77
|
};
|
|
78
|
+
|
|
79
79
|
PCore.getRestClient()
|
|
80
|
+
// @ts-ignore - Argument of type '{ queryPayload: { dataViewName: string; }; }' is not assignable to parameter of type 'RestApiOptionsObject'
|
|
81
|
+
// @ts-ignore - Expected 3 arguments, but got 2
|
|
80
82
|
.invokeRestApi('getListData', { queryPayload })
|
|
81
|
-
.then((res) => {
|
|
82
|
-
const ddDataSource = res.data.data.map(
|
|
83
|
+
.then((res: any) => {
|
|
84
|
+
const ddDataSource = res.data.data.map(listItem => ({
|
|
83
85
|
key: listItem.pyUserIdentifier,
|
|
84
86
|
value: listItem.pyUserName
|
|
85
87
|
}));
|
|
86
88
|
setDropDownDataSource(ddDataSource);
|
|
87
89
|
})
|
|
88
|
-
.catch(
|
|
90
|
+
.catch(err => {
|
|
89
91
|
// eslint-disable-next-line no-console
|
|
90
92
|
console.error(err);
|
|
91
93
|
});
|
|
@@ -97,15 +99,15 @@ const UserReference = (props: UserReferenceProps) => {
|
|
|
97
99
|
if (readOnly && showAsFormattedText) {
|
|
98
100
|
if (userId) {
|
|
99
101
|
userReferenceComponent = (
|
|
100
|
-
|
|
102
|
+
<>
|
|
101
103
|
{/*
|
|
102
104
|
TODO: This has to be replaced with Operator Component
|
|
103
105
|
*/}
|
|
104
106
|
<div>
|
|
105
|
-
<Typography variant=
|
|
106
|
-
<Typography variant=
|
|
107
|
+
<Typography variant='caption'>{label}</Typography>
|
|
108
|
+
<Typography variant='body1'>{userName}</Typography>
|
|
107
109
|
</div>
|
|
108
|
-
|
|
110
|
+
</>
|
|
109
111
|
);
|
|
110
112
|
}
|
|
111
113
|
} else {
|
|
@@ -133,7 +135,7 @@ const UserReference = (props: UserReferenceProps) => {
|
|
|
133
135
|
label={label}
|
|
134
136
|
getPConnect={getPConnect}
|
|
135
137
|
datasource={OPERATORS_DP}
|
|
136
|
-
listType=
|
|
138
|
+
listType='datapage'
|
|
137
139
|
columns={columns}
|
|
138
140
|
testId={testId}
|
|
139
141
|
placeholder={placeholder}
|
|
@@ -153,7 +155,7 @@ const UserReference = (props: UserReferenceProps) => {
|
|
|
153
155
|
<Dropdown
|
|
154
156
|
additionalProps={additionalProps}
|
|
155
157
|
datasource={dropDownDataSource}
|
|
156
|
-
listType=
|
|
158
|
+
listType='associated'
|
|
157
159
|
getPConnect={getPConnect}
|
|
158
160
|
label={label}
|
|
159
161
|
value={userId}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export const getUserId =
|
|
1
|
+
export const getUserId = user => {
|
|
2
2
|
let userId = '';
|
|
3
3
|
if (typeof user === 'object' && user !== null && user.userId) {
|
|
4
4
|
userId = user.userId;
|
|
@@ -8,6 +8,6 @@ export const getUserId = (user) => {
|
|
|
8
8
|
return userId;
|
|
9
9
|
};
|
|
10
10
|
|
|
11
|
-
export const isUserNameAvailable =
|
|
11
|
+
export const isUserNameAvailable = user => {
|
|
12
12
|
return typeof user === 'object' && user !== null && user.userName;
|
|
13
13
|
};
|
|
@@ -28,8 +28,8 @@ export const getIconFromFileType = (fileType): string => {
|
|
|
28
28
|
icon = 'document-pdf';
|
|
29
29
|
} else {
|
|
30
30
|
const [, subtype] = fileType.split('/');
|
|
31
|
-
const foundMatch =
|
|
32
|
-
return sources.some(
|
|
31
|
+
const foundMatch = sources => {
|
|
32
|
+
return sources.some(key => subtype.includes(key));
|
|
33
33
|
};
|
|
34
34
|
|
|
35
35
|
if (foundMatch(['excel', 'spreadsheet'])) {
|
|
@@ -42,22 +42,27 @@ export const getIconFromFileType = (fileType): string => {
|
|
|
42
42
|
return icon;
|
|
43
43
|
};
|
|
44
44
|
|
|
45
|
-
export const getIconForAttachment = (inThis:any
|
|
45
|
+
export const getIconForAttachment = (inThis: any, attachment: any): string => {
|
|
46
46
|
let icon;
|
|
47
47
|
switch (attachment.type) {
|
|
48
|
-
case
|
|
48
|
+
case 'FILE':
|
|
49
49
|
icon = inThis.getIconFromFileType(attachment.mimeType);
|
|
50
50
|
break;
|
|
51
|
-
case
|
|
52
|
-
icon =
|
|
51
|
+
case 'URL':
|
|
52
|
+
icon = 'chain';
|
|
53
53
|
break;
|
|
54
54
|
default:
|
|
55
|
-
icon =
|
|
55
|
+
icon = 'document-doc';
|
|
56
56
|
}
|
|
57
57
|
return icon;
|
|
58
58
|
};
|
|
59
59
|
|
|
60
|
-
export const buildFilePropsFromResponse = (
|
|
60
|
+
export const buildFilePropsFromResponse = (
|
|
61
|
+
respObj
|
|
62
|
+
): {
|
|
63
|
+
props: { meta: string; name: string; icon: string };
|
|
64
|
+
responseProps: any;
|
|
65
|
+
} => {
|
|
61
66
|
return {
|
|
62
67
|
props: {
|
|
63
68
|
meta: `${respObj.pyCategoryName}, ${respObj.pxCreateOperator}`,
|
|
@@ -1,9 +1,5 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
1
|
import { getComponentFromMap } from '@pega/react-sdk-components/lib/bridge/helpers/sdk_component_map';
|
|
3
2
|
|
|
4
|
-
// Remove this and use "real" PCore type once .d.ts is fixed (currently shows 1 error)
|
|
5
|
-
declare const PCore: any;
|
|
6
|
-
|
|
7
3
|
/**
|
|
8
4
|
* Function that accepts array of messages as input and group them by their type and returns the resulting object
|
|
9
5
|
* @param {Array} inputMessages
|
|
@@ -25,7 +21,7 @@ function getMessagesGrouped(inputMessages) {
|
|
|
25
21
|
const messages = {};
|
|
26
22
|
|
|
27
23
|
if (inputMessages && inputMessages instanceof Array && inputMessages.length > 0) {
|
|
28
|
-
inputMessages.forEach(
|
|
24
|
+
inputMessages.forEach(item => {
|
|
29
25
|
const { message, type } = item;
|
|
30
26
|
messages[type] = [...(messages[type] || []), message];
|
|
31
27
|
});
|
|
@@ -69,7 +65,7 @@ function getBanners(config) {
|
|
|
69
65
|
const banners: any = [];
|
|
70
66
|
const groupedPageMessages = getMessagesGrouped(pageMessages);
|
|
71
67
|
|
|
72
|
-
Object.keys(groupedPageMessages).forEach(
|
|
68
|
+
Object.keys(groupedPageMessages).forEach(type => {
|
|
73
69
|
const messagesByType = groupedPageMessages[type];
|
|
74
70
|
const variant = getVariant(type);
|
|
75
71
|
const pageMessagesBannerID = `${target}_${PAGE}_${type}`.toLowerCase().replace('/', '_');
|
|
@@ -86,7 +82,7 @@ function getBanners(config) {
|
|
|
86
82
|
category: PAGE,
|
|
87
83
|
type,
|
|
88
84
|
context: target
|
|
89
|
-
});
|
|
85
|
+
} as any);
|
|
90
86
|
}
|
|
91
87
|
}
|
|
92
88
|
/>
|
|
@@ -94,7 +90,7 @@ function getBanners(config) {
|
|
|
94
90
|
});
|
|
95
91
|
|
|
96
92
|
if (httpMessages && httpMessages.length > 0) {
|
|
97
|
-
banners.push(<AlertBanner id=
|
|
93
|
+
banners.push(<AlertBanner id='modalViewContainerBanner' variant='urgent' messages={httpMessages} />);
|
|
98
94
|
}
|
|
99
95
|
|
|
100
96
|
return banners;
|
|
@@ -1,4 +1,8 @@
|
|
|
1
|
-
// eslint-disable-next-line import/prefer-default-export
|
|
2
1
|
export function isEmptyObject(obj: Object): boolean {
|
|
3
2
|
return Object.keys(obj).length === 0;
|
|
4
3
|
}
|
|
4
|
+
|
|
5
|
+
export function isInfinity23OrHigher() {
|
|
6
|
+
const pCoreVersion = PCore.getPCoreVersion();
|
|
7
|
+
return ['8.23.0', '23.1.1', '23.1.2'].includes(pCoreVersion);
|
|
8
|
+
}
|
package/lib/helpers/data_page.ts
CHANGED
|
@@ -1,17 +1,13 @@
|
|
|
1
|
-
// Remove this and use "real" PCore type once .d.ts is fixed (currently shows 1 error)
|
|
2
|
-
declare const PCore: any;
|
|
3
|
-
|
|
4
1
|
// eslint-disable-next-line import/prefer-default-export
|
|
5
2
|
export const getDataPage = (dataPageName, parameters, context) => {
|
|
6
3
|
let dataViewParams;
|
|
7
|
-
if(parameters){
|
|
4
|
+
if (parameters) {
|
|
8
5
|
dataViewParams = {
|
|
9
|
-
|
|
6
|
+
dataViewParameters: parameters
|
|
10
7
|
};
|
|
11
8
|
}
|
|
12
9
|
return new Promise((resolve, reject) => {
|
|
13
|
-
PCore.getDataApiUtils()
|
|
14
|
-
.getData(dataPageName, dataViewParams, context)
|
|
10
|
+
(PCore.getDataApiUtils().getData(dataPageName, dataViewParams, context) as any)
|
|
15
11
|
.then(response => {
|
|
16
12
|
resolve(response.data.data);
|
|
17
13
|
})
|
|
@@ -39,7 +39,7 @@ export const getDateFormatInfo = (): typeof dateFormatInfoDefault => {
|
|
|
39
39
|
longFormat: 'MMM',
|
|
40
40
|
placeholder: localizedPlaceholderExists ? localizedVal('month_placeholder', localeCategory) : 'mm',
|
|
41
41
|
mask: '__',
|
|
42
|
-
separator: theTestDateLocaleString[locMM+2]
|
|
42
|
+
separator: theTestDateLocaleString[locMM + 2]
|
|
43
43
|
},
|
|
44
44
|
{
|
|
45
45
|
loc: locDD,
|
|
@@ -47,7 +47,7 @@ export const getDateFormatInfo = (): typeof dateFormatInfoDefault => {
|
|
|
47
47
|
longFormat: 'DD',
|
|
48
48
|
placeholder: localizedPlaceholderExists ? localizedVal('day_placeholder', localeCategory) : 'dd',
|
|
49
49
|
mask: '__',
|
|
50
|
-
separator: theTestDateLocaleString[locDD+2]
|
|
50
|
+
separator: theTestDateLocaleString[locDD + 2]
|
|
51
51
|
},
|
|
52
52
|
{
|
|
53
53
|
loc: locYYYY,
|
|
@@ -55,7 +55,7 @@ export const getDateFormatInfo = (): typeof dateFormatInfoDefault => {
|
|
|
55
55
|
longFormat: 'YYYY',
|
|
56
56
|
placeholder: localizedPlaceholderExists ? localizedVal('year_placeholder', localeCategory) : 'yyyy',
|
|
57
57
|
mask: '____',
|
|
58
|
-
separator: theTestDateLocaleString[locYYYY+4]
|
|
58
|
+
separator: theTestDateLocaleString[locYYYY + 4]
|
|
59
59
|
}
|
|
60
60
|
];
|
|
61
61
|
|