@pega/custom-dx-components 0.242.37 → 0.242.38
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/package.json +1 -1
- package/src/tasks/build-jest-assets/index.js +26 -5
- package/src/tasks/create/templates/Constellation/Field/Integer/index.tsx.mustache +0 -3
- package/src/tasks/create-all/index.js +1 -0
- package/src/tasks/init/template/package.json.mustache +1 -1
- package/src/util.js +19 -4
- package/tests/assets/library/components/create/Pega_DXIL_MyTestText/config.json +1 -1
- package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyBoolean/config.json +1 -1
- package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyCaseWidget/config.json +1 -1
- package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyCurrency/config.json +1 -1
- package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyDate/config.json +1 -1
- package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyDateTime/config.json +1 -1
- package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyDecimal/config.json +1 -1
- package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyDetails/config.json +1 -1
- package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyEmail/config.json +1 -1
- package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyForm/config.json +1 -1
- package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyIconButtonURL/config.json +1 -1
- package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyInteger/config.json +1 -1
- package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyInteger/index.tsx +0 -3
- package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyPage/config.json +1 -1
- package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyPageCaseWidget/config.json +1 -1
- package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyPageWidget/config.json +1 -1
- package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyParagraph/config.json +1 -1
- package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyPercentage/config.json +1 -1
- package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyPhone/config.json +1 -1
- package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyPicklist/config.json +1 -1
- package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyRadiobuttons/config.json +1 -1
- package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MySearchbox/config.json +1 -1
- package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyText/config.json +1 -1
- package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyTextInput/config.json +1 -1
- package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyTimeOfDay/config.json +1 -1
- package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyTwoColumnDetails/config.json +1 -1
- package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyTwoColumnForm/config.json +1 -1
- package/tests/assets/library/components/createAll/Constellation/Pega_DXIL_MyURL/config.json +1 -1
- package/tests/assets/original/components/createAll/Constellation/Pega_DXIL_MyInteger/index.tsx +0 -3
- package/tests/assets/original/components/createAll/Launchpad/Pega_DXIL_MyInteger/index.tsx +0 -3
- package/tests/functional/localCreatePublishAllDeleteAll.test.js +1 -1
- package/tests/functional/localLibCreateLibListDeleteLib.test.js +1 -1
- package/tests/functional/localLibCreateLibValidateDeleteLib.test.js +11 -1
- package/tests/functional/localLibCreateLibVersionDeleteLib.test.js +4 -4
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyBoolean/Boolean.ts +0 -35
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyBoolean/PConnProps.d.ts +0 -46
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyBoolean/boolean-format.ts +0 -25
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyBoolean/config.json +0 -145
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyBoolean/demo.stories.tsx +0 -70
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyBoolean/event-utils.ts +0 -18
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyBoolean/index.tsx +0 -165
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyBoolean/mock.ts +0 -22
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyBoolean/styles.ts +0 -8
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyCaseWidget/OneColumnPage.svg +0 -36
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyCaseWidget/PConnProps.d.ts +0 -46
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyCaseWidget/config.json +0 -23
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyCaseWidget/demo.stories.tsx +0 -84
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyCaseWidget/index.tsx +0 -72
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyCaseWidget/mock.ts +0 -391
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyCaseWidget/styles.ts +0 -8
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyCurrency/PConnProps.d.ts +0 -46
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyCurrency/config.json +0 -291
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyCurrency/demo.stories.tsx +0 -68
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyCurrency/event-utils.ts +0 -18
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyCurrency/index.tsx +0 -279
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyCurrency/mock.ts +0 -33
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyCurrency/styles.ts +0 -8
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyCurrency/suggestions-handler.ts +0 -9
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDate/DateFormatter.ts +0 -61
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDate/FormattedText.tsx +0 -20
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDate/PConnProps.d.ts +0 -46
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDate/config.json +0 -199
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDate/date.ts +0 -439
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDate/demo.stories.tsx +0 -86
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDate/index.tsx +0 -260
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDate/mock.ts +0 -25
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDate/styles.ts +0 -8
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDate/suggestions-handler.ts +0 -9
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDateTime/PConnProps.d.ts +0 -46
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDateTime/config.json +0 -256
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDateTime/date-time.ts +0 -92
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDateTime/date-utils.ts +0 -288
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDateTime/date.ts +0 -331
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDateTime/demo.stories.tsx +0 -85
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDateTime/index.tsx +0 -251
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDateTime/mock.ts +0 -27
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDateTime/styles.ts +0 -8
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDateTime/suggestions-handler.ts +0 -10
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDecimal/PConnProps.d.ts +0 -46
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDecimal/config.json +0 -278
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDecimal/demo.stories.tsx +0 -63
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDecimal/event-utils.ts +0 -18
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDecimal/index.tsx +0 -244
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDecimal/mock.ts +0 -30
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDecimal/styles.ts +0 -8
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDecimal/suggestions-handler.ts +0 -9
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDetails/Avatar.tsx +0 -76
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDetails/DetailsRender.tsx +0 -52
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDetails/HighlightRender.tsx +0 -46
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDetails/OneColumnDetails.svg +0 -22
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDetails/Operator.tsx +0 -215
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDetails/PConnProps.d.ts +0 -46
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDetails/StatusWork.tsx +0 -26
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDetails/config.json +0 -35
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDetails/demo.stories.tsx +0 -204
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDetails/index.tsx +0 -99
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDetails/mock.ts +0 -248
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDetails/styles.ts +0 -24
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyDetails/utils.js +0 -151
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyEmail/PConnProps.d.ts +0 -46
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyEmail/config.json +0 -111
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyEmail/demo.stories.tsx +0 -63
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyEmail/event-utils.ts +0 -18
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyEmail/index.tsx +0 -212
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyEmail/mock.ts +0 -31
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyEmail/styles.ts +0 -8
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyEmail/suggestions-handler.ts +0 -9
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyForm/DefaultForm.svg +0 -29
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyForm/DetailsRender.tsx +0 -59
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyForm/PConnProps.d.ts +0 -46
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyForm/config.json +0 -45
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyForm/demo.stories.tsx +0 -246
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyForm/index.tsx +0 -68
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyForm/mock.ts +0 -139
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyForm/styles.ts +0 -8
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyIconButtonURL/PConnProps.d.ts +0 -46
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyIconButtonURL/config.json +0 -32
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyIconButtonURL/demo.stories.tsx +0 -102
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyIconButtonURL/index.tsx +0 -212
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyIconButtonURL/mock.ts +0 -4
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyIconButtonURL/styles.ts +0 -8
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyInteger/PConnProps.d.ts +0 -46
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyInteger/config.json +0 -344
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyInteger/demo.stories.tsx +0 -63
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyInteger/event-utils.ts +0 -18
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyInteger/index.tsx +0 -305
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyInteger/mock.ts +0 -29
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyInteger/styles.ts +0 -8
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyInteger/suggestions-handler.ts +0 -9
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPage/GetNextWork.tsx +0 -45
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPage/OneColumnPage.svg +0 -36
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPage/PConnProps.d.ts +0 -46
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPage/config.json +0 -32
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPage/demo.stories.tsx +0 -111
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPage/index.tsx +0 -71
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPage/localizations.json +0 -6
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPage/mock.ts +0 -94
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPage/styles.ts +0 -8
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPage/utils.ts +0 -229
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPageCaseWidget/Avatar.tsx +0 -76
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPageCaseWidget/OneColumnPage.svg +0 -36
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPageCaseWidget/Operator.tsx +0 -210
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPageCaseWidget/PConnProps.d.ts +0 -46
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPageCaseWidget/config.json +0 -55
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPageCaseWidget/demo.stories.tsx +0 -80
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPageCaseWidget/index.tsx +0 -89
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPageCaseWidget/mock.ts +0 -51
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPageCaseWidget/styles.ts +0 -8
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPageWidget/OneColumnPage.svg +0 -36
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPageWidget/PConnProps.d.ts +0 -46
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPageWidget/config.json +0 -59
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPageWidget/demo.stories.tsx +0 -118
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPageWidget/index.tsx +0 -106
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPageWidget/mock.ts +0 -24
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPageWidget/styles.ts +0 -8
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyParagraph/PConnProps.d.ts +0 -46
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyParagraph/config.json +0 -111
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyParagraph/demo.stories.tsx +0 -63
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyParagraph/event-utils.ts +0 -18
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyParagraph/index.tsx +0 -210
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyParagraph/mock.ts +0 -28
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyParagraph/styles.ts +0 -8
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyParagraph/suggestions-handler.ts +0 -9
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPercentage/PConnProps.d.ts +0 -46
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPercentage/config.json +0 -93
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPercentage/demo.stories.tsx +0 -64
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPercentage/event-utils.ts +0 -18
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPercentage/index.tsx +0 -262
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPercentage/mock.ts +0 -29
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPercentage/styles.ts +0 -8
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPercentage/suggestions-handler.ts +0 -9
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPhone/PConnProps.d.ts +0 -46
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPhone/config.json +0 -123
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPhone/demo.stories.tsx +0 -61
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPhone/event-utils.ts +0 -18
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPhone/index.tsx +0 -245
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPhone/mock.ts +0 -45
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPhone/styles.ts +0 -8
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPhone/suggestions-handler.ts +0 -9
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPicklist/PConnProps.d.ts +0 -46
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPicklist/config.json +0 -114
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPicklist/demo.stories.tsx +0 -92
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPicklist/event-utils.ts +0 -18
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPicklist/index.tsx +0 -338
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPicklist/mock.ts +0 -76
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPicklist/styles.ts +0 -8
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyPicklist/suggestions-handler.ts +0 -9
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyRadiobuttons/PConnProps.d.ts +0 -46
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyRadiobuttons/config.json +0 -113
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyRadiobuttons/demo.stories.tsx +0 -95
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyRadiobuttons/event-utils.ts +0 -18
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyRadiobuttons/index.tsx +0 -191
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyRadiobuttons/mock.ts +0 -75
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyRadiobuttons/styles.ts +0 -8
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyRadiobuttons/suggestions-handler.ts +0 -9
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyRadiobuttons/textformat-utils.tsx +0 -162
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MySearchbox/PConnProps.d.ts +0 -46
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MySearchbox/component-constants.ts +0 -5
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MySearchbox/config.json +0 -115
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MySearchbox/date.ts +0 -163
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MySearchbox/demo.stories.tsx +0 -100
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MySearchbox/embed-utils.ts +0 -314
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MySearchbox/event-utils.ts +0 -18
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MySearchbox/format-constants.ts +0 -41
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MySearchbox/index.tsx +0 -1144
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MySearchbox/mock.ts +0 -74
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MySearchbox/picklist-utils.ts +0 -88
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MySearchbox/repeat-constants.ts +0 -20
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MySearchbox/repeat-utils.ts +0 -658
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MySearchbox/styles.ts +0 -8
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MySearchbox/suggestions-handler.ts +0 -9
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MySearchbox/textformat-utils.tsx +0 -181
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MySearchbox/utils.ts +0 -221
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyText/PConnProps.d.ts +0 -46
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyText/config.json +0 -55
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyText/demo.stories.tsx +0 -67
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyText/index.tsx +0 -145
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyText/mock.ts +0 -21
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyText/styles.ts +0 -8
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTextInput/PConnProps.d.ts +0 -46
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTextInput/StatusWork.tsx +0 -26
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTextInput/config.json +0 -111
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTextInput/demo.stories.tsx +0 -63
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTextInput/event-utils.ts +0 -18
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTextInput/index.tsx +0 -224
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTextInput/mock.ts +0 -30
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTextInput/styles.ts +0 -8
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTextInput/suggestions-handler.ts +0 -9
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTimeOfDay/PConnProps.d.ts +0 -46
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTimeOfDay/config.json +0 -185
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTimeOfDay/demo.stories.tsx +0 -65
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTimeOfDay/index.tsx +0 -209
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTimeOfDay/mock.ts +0 -21
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTimeOfDay/styles.ts +0 -8
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTimeOfDay/suggestions-handler.ts +0 -9
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTimeOfDay/time-of-day.ts +0 -288
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnDetails/Avatar.tsx +0 -76
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnDetails/DetailsRender.tsx +0 -52
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnDetails/HighlightRender.tsx +0 -46
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnDetails/Operator.tsx +0 -215
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnDetails/PConnProps.d.ts +0 -46
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnDetails/StatusWork.tsx +0 -26
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnDetails/TwoColumnDetails.svg +0 -28
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnDetails/config.json +0 -42
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnDetails/demo.stories.tsx +0 -221
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnDetails/index.tsx +0 -86
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnDetails/mock.ts +0 -288
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnDetails/styles.ts +0 -23
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnDetails/utils.ts +0 -149
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnForm/DetailsRender.tsx +0 -59
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnForm/PConnProps.d.ts +0 -46
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnForm/TwoColumn.svg +0 -38
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnForm/config.json +0 -27
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnForm/demo.stories.tsx +0 -192
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnForm/index.tsx +0 -73
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnForm/mock.ts +0 -145
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnForm/styles.ts +0 -8
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyURL/PConnProps.d.ts +0 -46
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyURL/config.json +0 -237
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyURL/demo.stories.tsx +0 -60
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyURL/event-utils.ts +0 -18
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyURL/index.tsx +0 -203
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyURL/mock.ts +0 -30
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyURL/styles.ts +0 -8
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyURL/suggestions-handler.ts +0 -9
- package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyURL/text-url.tsx +0 -179
- package/tests/assets/library/components/createAll/Launchpad/shared/PConnProps.d.ts +0 -46
- package/tests/assets/library/components/createAll/Launchpad/shared/suggestions-handler.ts +0 -9
- package/tests/assets/original/components/create/shared/PConnProps.d.ts +0 -46
- package/tests/assets/original/components/create/shared/create-nonce.ts +0 -6
- package/tests/assets/original/components/create/shared/suggestions-handler.ts +0 -9
- package/tests/assets/original/components/createAll/Constellation/shared/PConnProps.d.ts +0 -46
- package/tests/assets/original/components/createAll/Constellation/shared/create-nonce.ts +0 -6
- package/tests/assets/original/components/createAll/Constellation/shared/suggestions-handler.ts +0 -9
- package/tests/assets/original/components/createAll/Launchpad/shared/PConnProps.d.ts +0 -46
- package/tests/assets/original/components/createAll/Launchpad/shared/create-nonce.ts +0 -6
- package/tests/assets/original/components/createAll/Launchpad/shared/suggestions-handler.ts +0 -9
|
@@ -1,68 +0,0 @@
|
|
|
1
|
-
import { Grid, Flex, FieldGroup, withConfiguration } from '@pega/cosmos-react-core';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
import type { PConnFieldProps } from './PConnProps';
|
|
5
|
-
import DetailsRender from './DetailsRender';
|
|
6
|
-
|
|
7
|
-
import StyledPegaDxilMyFormWrapper from './styles';
|
|
8
|
-
|
|
9
|
-
// interface for props
|
|
10
|
-
interface PegaDxilMyFormProps extends PConnFieldProps {
|
|
11
|
-
// If any, enter additional props that only exist on TextInput here
|
|
12
|
-
showLabel: boolean;
|
|
13
|
-
NumCols: string;
|
|
14
|
-
children: any;
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
// props passed in combination of props from property panel (config.json) and run time props from Constellation
|
|
18
|
-
// any default values in config.pros should be set in defaultProps at bottom of this file
|
|
19
|
-
function PegaDxilMyForm(props: PegaDxilMyFormProps) {
|
|
20
|
-
|
|
21
|
-
const { children = [], NumCols = '1', label, showLabel, getPConnect, readOnly, displayMode } = props;
|
|
22
|
-
const propsToUse = { label, showLabel, ...getPConnect().getInheritedProps() };
|
|
23
|
-
|
|
24
|
-
const nCols = parseInt(NumCols, 10);
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
if (readOnly && readOnly === true || displayMode && displayMode === 'DISPLAY_ONLY') {
|
|
28
|
-
const numRegions = '1';
|
|
29
|
-
const gridRepeat = 'repeat('.concat(numRegions).concat(', 1fr)');
|
|
30
|
-
const gridContainer = { colGap: 0, 'margin-line-start': 0 };
|
|
31
|
-
// @ts-ignore
|
|
32
|
-
gridContainer.cols = gridRepeat;
|
|
33
|
-
// @ts-ignore
|
|
34
|
-
gridContainer.gap = 2;
|
|
35
|
-
|
|
36
|
-
return (
|
|
37
|
-
<StyledPegaDxilMyFormWrapper>
|
|
38
|
-
<FieldGroup name={propsToUse.showLabel ? propsToUse.label : ''}>
|
|
39
|
-
<Grid container={gridContainer} data-testid={`column-count-${numRegions}`}>
|
|
40
|
-
{children.map((child: any, i: number) => (
|
|
41
|
-
<Flex
|
|
42
|
-
// @ts-ignore
|
|
43
|
-
container={{ direction: 'column', alignItems: 'normal', colGap: 1, rowGap: 1.5 }}
|
|
44
|
-
key={`r-${i + 1}`}
|
|
45
|
-
>
|
|
46
|
-
<DetailsRender child={child} />
|
|
47
|
-
</Flex>
|
|
48
|
-
))}
|
|
49
|
-
</Grid>
|
|
50
|
-
</FieldGroup>
|
|
51
|
-
</StyledPegaDxilMyFormWrapper>
|
|
52
|
-
);
|
|
53
|
-
}
|
|
54
|
-
return (
|
|
55
|
-
<StyledPegaDxilMyFormWrapper>
|
|
56
|
-
<FieldGroup name={propsToUse.showLabel ? propsToUse.label : ''}>
|
|
57
|
-
<Grid container={{
|
|
58
|
-
cols: `repeat(${nCols}, minmax(0, 1fr))`,
|
|
59
|
-
gap: 2
|
|
60
|
-
}}>
|
|
61
|
-
{children}
|
|
62
|
-
</Grid>
|
|
63
|
-
</FieldGroup>
|
|
64
|
-
</StyledPegaDxilMyFormWrapper>
|
|
65
|
-
);
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
export default withConfiguration(PegaDxilMyForm);
|
|
@@ -1,139 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
// @ts-nocheck
|
|
3
|
-
export const pyReviewRaw = {
|
|
4
|
-
name: 'CollectInformation',
|
|
5
|
-
type: 'View',
|
|
6
|
-
config: {
|
|
7
|
-
template: 'DefaultForm',
|
|
8
|
-
ruleClass: 'OM5W9U-SampleApp-Work-Test',
|
|
9
|
-
localeReference: '@LR OM5W9U-SAMPLEAPP-WORK-TEST!VIEW!COLLECTINFORMATION',
|
|
10
|
-
context: '@P .pyViewContext'
|
|
11
|
-
},
|
|
12
|
-
children: [
|
|
13
|
-
{
|
|
14
|
-
name: 'Fields',
|
|
15
|
-
type: 'Region',
|
|
16
|
-
children: [
|
|
17
|
-
{
|
|
18
|
-
type: 'TextInput',
|
|
19
|
-
config: {
|
|
20
|
-
value: '@P .FirstName',
|
|
21
|
-
label: '@L First Name',
|
|
22
|
-
key: 'FirstName'
|
|
23
|
-
}
|
|
24
|
-
},
|
|
25
|
-
{
|
|
26
|
-
type: 'TextInput',
|
|
27
|
-
config: {
|
|
28
|
-
value: '@P .MiddleName',
|
|
29
|
-
label: '@L Middle Name',
|
|
30
|
-
key: 'MiddleName'
|
|
31
|
-
}
|
|
32
|
-
},
|
|
33
|
-
{
|
|
34
|
-
type: 'TextInput',
|
|
35
|
-
config: {
|
|
36
|
-
value: '@P .LastName',
|
|
37
|
-
label: '@L Last Name',
|
|
38
|
-
key: 'LastName'
|
|
39
|
-
}
|
|
40
|
-
},
|
|
41
|
-
{
|
|
42
|
-
type: 'Email',
|
|
43
|
-
config: {
|
|
44
|
-
value: '@P .Email',
|
|
45
|
-
label: '@L Email',
|
|
46
|
-
key: 'Email'
|
|
47
|
-
}
|
|
48
|
-
},
|
|
49
|
-
{
|
|
50
|
-
type: 'Phone',
|
|
51
|
-
config: {
|
|
52
|
-
value: '@P .PhoneNumber',
|
|
53
|
-
label: '@L Phone Number',
|
|
54
|
-
datasource: {
|
|
55
|
-
source: '@DATASOURCE D_pyCountryCallingCodeList.pxResults',
|
|
56
|
-
fields: {
|
|
57
|
-
value: '@P .pyCallingCode'
|
|
58
|
-
}
|
|
59
|
-
},
|
|
60
|
-
key: 'PhoneNumber'
|
|
61
|
-
}
|
|
62
|
-
},
|
|
63
|
-
{
|
|
64
|
-
type: 'Date',
|
|
65
|
-
config: {
|
|
66
|
-
value: '@P .ServiceDate',
|
|
67
|
-
label: '@L Service Date',
|
|
68
|
-
key: 'ServiceDate'
|
|
69
|
-
}
|
|
70
|
-
}
|
|
71
|
-
]
|
|
72
|
-
}
|
|
73
|
-
],
|
|
74
|
-
classID: 'OM5W9U-SampleApp-Work-Test'
|
|
75
|
-
};
|
|
76
|
-
|
|
77
|
-
export const regionChildrenResolved = [
|
|
78
|
-
{
|
|
79
|
-
readOnly: undefined,
|
|
80
|
-
value: 'John',
|
|
81
|
-
label: 'First Name',
|
|
82
|
-
hasSuggestions: false,
|
|
83
|
-
key: 'firstName'
|
|
84
|
-
},
|
|
85
|
-
{
|
|
86
|
-
readOnly: undefined,
|
|
87
|
-
value: '',
|
|
88
|
-
label: 'Middle Name',
|
|
89
|
-
hasSuggestions: false,
|
|
90
|
-
key: 'middleName'
|
|
91
|
-
},
|
|
92
|
-
{
|
|
93
|
-
readOnly: undefined,
|
|
94
|
-
value: 'Doe',
|
|
95
|
-
label: 'Last Name',
|
|
96
|
-
hasSuggestions: false,
|
|
97
|
-
key: 'lastName'
|
|
98
|
-
},
|
|
99
|
-
{
|
|
100
|
-
readOnly: undefined,
|
|
101
|
-
value: 'John@doe.com',
|
|
102
|
-
label: 'Email',
|
|
103
|
-
hasSuggestions: false,
|
|
104
|
-
key: 'email'
|
|
105
|
-
},
|
|
106
|
-
{
|
|
107
|
-
readOnly: undefined,
|
|
108
|
-
value: '+16397975093',
|
|
109
|
-
label: 'Phone Number',
|
|
110
|
-
datasource: {
|
|
111
|
-
fields: {
|
|
112
|
-
value: undefined
|
|
113
|
-
},
|
|
114
|
-
source: [
|
|
115
|
-
{
|
|
116
|
-
value: '+1'
|
|
117
|
-
},
|
|
118
|
-
{
|
|
119
|
-
value: '+91'
|
|
120
|
-
},
|
|
121
|
-
{
|
|
122
|
-
value: '+48'
|
|
123
|
-
},
|
|
124
|
-
{
|
|
125
|
-
value: '+44'
|
|
126
|
-
}
|
|
127
|
-
]
|
|
128
|
-
},
|
|
129
|
-
hasSuggestions: false,
|
|
130
|
-
key: 'phoneNumber'
|
|
131
|
-
},
|
|
132
|
-
{
|
|
133
|
-
readOnly: undefined,
|
|
134
|
-
value: '2023-01-25',
|
|
135
|
-
label: 'Service Date',
|
|
136
|
-
hasSuggestions: false,
|
|
137
|
-
key: 'serviceDate'
|
|
138
|
-
}
|
|
139
|
-
];
|
|
@@ -1,46 +0,0 @@
|
|
|
1
|
-
import {PConnect } from '@pega/pcore-pconnect-typedefs';
|
|
2
|
-
|
|
3
|
-
// PConnProps.d.ts
|
|
4
|
-
// This gives us a place to have each component (which is most DX Components) that is
|
|
5
|
-
// expected to have a getPConnect extend its props (from BaseProps)
|
|
6
|
-
// such that every component will be expected to have a getPConnect() function
|
|
7
|
-
// that returns a PConnect object. (new/better way of doing .propTypes).
|
|
8
|
-
// This PConnProps can be extended to include other props that we know are in every component
|
|
9
|
-
export interface PConnProps {
|
|
10
|
-
// getPConnect should exist for every C11n component. (add @ts-ignore in special cases where it isn't)
|
|
11
|
-
getPConnect: () => typeof PConnect;
|
|
12
|
-
|
|
13
|
-
// Allow any/all other key/value pairs in the BaseProps for now
|
|
14
|
-
// TODO: refine which other props are always expected for various component
|
|
15
|
-
// types and consider further interface "subclassing". For example, we may
|
|
16
|
-
// want to create a "BasePropsForm" that gives guidance on required, readonly, etc.
|
|
17
|
-
// and any other props that every Form component expects.
|
|
18
|
-
// For example, see the PConnFieldProps below.
|
|
19
|
-
// NOTE: if you uncomment the line below, the PConnProps type will allow
|
|
20
|
-
// otherwise undefined types to appear. This can be helpful for debugging
|
|
21
|
-
// or when adding new components whose types aren't yet known.
|
|
22
|
-
// [key: string]: any;
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
// PConnFieldProps extends PConnProps to bring in the common properties that are
|
|
27
|
-
// associated with most field components (ex: Dropdown, TextInput, etc.) in the
|
|
28
|
-
// components/field directory
|
|
29
|
-
export interface PConnFieldProps extends PConnProps {
|
|
30
|
-
label: string,
|
|
31
|
-
required: boolean,
|
|
32
|
-
disabled: boolean,
|
|
33
|
-
value: any,
|
|
34
|
-
validatemessage: string,
|
|
35
|
-
status?: string,
|
|
36
|
-
onChange?: any,
|
|
37
|
-
onBlur?: any,
|
|
38
|
-
readOnly: boolean,
|
|
39
|
-
testId: string,
|
|
40
|
-
helperText: string,
|
|
41
|
-
displayMode?: string,
|
|
42
|
-
hideLabel: boolean,
|
|
43
|
-
placeholder?: string,
|
|
44
|
-
fieldMetadata?: any,
|
|
45
|
-
additionalProps?: any
|
|
46
|
-
}
|
package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyIconButtonURL/config.json
DELETED
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "Pega_DXIL_MyIconButtonURL",
|
|
3
|
-
"label": "My Icon Button URL",
|
|
4
|
-
"description": "My Icon Button URL",
|
|
5
|
-
"organization": "Pega",
|
|
6
|
-
"version": "0.0.1",
|
|
7
|
-
"library": "DXIL",
|
|
8
|
-
"allowedApplications": [],
|
|
9
|
-
"componentKey": "Pega_DXIL_MyIconButtonURL",
|
|
10
|
-
"type": "Field",
|
|
11
|
-
"subtype": "Text-URL",
|
|
12
|
-
"icon": "images/pz-url-active.svg",
|
|
13
|
-
"properties": [
|
|
14
|
-
{
|
|
15
|
-
"label": "Advanced",
|
|
16
|
-
"format": "GROUP",
|
|
17
|
-
"collapsible": true,
|
|
18
|
-
"properties": [
|
|
19
|
-
{
|
|
20
|
-
"name": "testId",
|
|
21
|
-
"label": "Test ID",
|
|
22
|
-
"format": "TEXT",
|
|
23
|
-
"ignorePattern": "[^-_\\p{N}\\p{L}]",
|
|
24
|
-
"includeAnnotations": false
|
|
25
|
-
}
|
|
26
|
-
]
|
|
27
|
-
}
|
|
28
|
-
],
|
|
29
|
-
"defaultConfig": {
|
|
30
|
-
"label": "@L $this.label"
|
|
31
|
-
}
|
|
32
|
-
}
|
|
@@ -1,102 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
/* eslint-disable react/jsx-no-useless-fragment */
|
|
3
|
-
import type { Meta, StoryObj } from '@storybook/react';
|
|
4
|
-
|
|
5
|
-
import PegaDxilMyIconButtonUrl from './index';
|
|
6
|
-
import { configProps } from './mock';
|
|
7
|
-
|
|
8
|
-
const meta: Meta<typeof PegaDxilMyIconButtonUrl> = {
|
|
9
|
-
title: 'PegaDxilMyIconButtonUrl',
|
|
10
|
-
component: PegaDxilMyIconButtonUrl,
|
|
11
|
-
excludeStories: /.*Data$/
|
|
12
|
-
};
|
|
13
|
-
|
|
14
|
-
export default meta;
|
|
15
|
-
type Story = StoryObj<typeof PegaDxilMyIconButtonUrl>;
|
|
16
|
-
|
|
17
|
-
if (!window.PCore) {
|
|
18
|
-
window.PCore = {};
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
const countrylistData = {
|
|
22
|
-
data: [
|
|
23
|
-
{
|
|
24
|
-
Name: 'United States of America',
|
|
25
|
-
ShortName: 'USA'
|
|
26
|
-
},
|
|
27
|
-
{
|
|
28
|
-
Name: 'Canada',
|
|
29
|
-
ShortName: 'CAN'
|
|
30
|
-
},
|
|
31
|
-
{
|
|
32
|
-
Name: 'Mexico',
|
|
33
|
-
ShortName: 'MEX'
|
|
34
|
-
}
|
|
35
|
-
]
|
|
36
|
-
};
|
|
37
|
-
|
|
38
|
-
window.PCore.getDataPageUtils = () => {
|
|
39
|
-
return {
|
|
40
|
-
getData: () => {
|
|
41
|
-
return new Promise(resolve => {
|
|
42
|
-
resolve(countrylistData);
|
|
43
|
-
});
|
|
44
|
-
},
|
|
45
|
-
getDataAsync: () => {
|
|
46
|
-
return new Promise(resolve => {
|
|
47
|
-
resolve(countrylistData);
|
|
48
|
-
});
|
|
49
|
-
}
|
|
50
|
-
};
|
|
51
|
-
};
|
|
52
|
-
|
|
53
|
-
export const BasePegaDxilMyIconButtonUrl: Story = (args: any) => {
|
|
54
|
-
|
|
55
|
-
const props = {
|
|
56
|
-
getPConnect: () => {
|
|
57
|
-
return {
|
|
58
|
-
getValue: (value: any) => {
|
|
59
|
-
return value;
|
|
60
|
-
},
|
|
61
|
-
getContextName: () => {
|
|
62
|
-
return 'app/primary_1';
|
|
63
|
-
},
|
|
64
|
-
getLocalizedValue: (value: any) => {
|
|
65
|
-
return value;
|
|
66
|
-
},
|
|
67
|
-
getActionsApi: () => {
|
|
68
|
-
return {
|
|
69
|
-
updateFieldValue: () => {
|
|
70
|
-
/* nothing */
|
|
71
|
-
},
|
|
72
|
-
triggerFieldChange: () => {
|
|
73
|
-
/* nothing */
|
|
74
|
-
}
|
|
75
|
-
};
|
|
76
|
-
},
|
|
77
|
-
ignoreSuggestion: () => {
|
|
78
|
-
/* nothing */
|
|
79
|
-
},
|
|
80
|
-
acceptSuggestion: () => {
|
|
81
|
-
/* nothing */
|
|
82
|
-
},
|
|
83
|
-
setInheritedProps: () => {
|
|
84
|
-
/* nothing */
|
|
85
|
-
},
|
|
86
|
-
resolveConfigProps: () => {
|
|
87
|
-
/* nothing */
|
|
88
|
-
}
|
|
89
|
-
};
|
|
90
|
-
}
|
|
91
|
-
};
|
|
92
|
-
|
|
93
|
-
return (
|
|
94
|
-
<>
|
|
95
|
-
<PegaDxilMyIconButtonUrl {...props} {...args} />
|
|
96
|
-
</>
|
|
97
|
-
);
|
|
98
|
-
};
|
|
99
|
-
|
|
100
|
-
BasePegaDxilMyIconButtonUrl.args = {
|
|
101
|
-
|
|
102
|
-
};
|
package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyIconButtonURL/index.tsx
DELETED
|
@@ -1,212 +0,0 @@
|
|
|
1
|
-
import { useEffect, useState } from 'react';
|
|
2
|
-
import {
|
|
3
|
-
Icon,
|
|
4
|
-
Button,
|
|
5
|
-
withConfiguration,
|
|
6
|
-
registerIcon,
|
|
7
|
-
Table,
|
|
8
|
-
Label,
|
|
9
|
-
Link,
|
|
10
|
-
URLDisplay
|
|
11
|
-
} from '@pega/cosmos-react-core';
|
|
12
|
-
import type { PConnFieldProps } from './PConnProps';
|
|
13
|
-
|
|
14
|
-
// IMPORTANT
|
|
15
|
-
// To use Icons, need to individually import the icon file form @pega/cosmos-react-core (see path below)
|
|
16
|
-
// Icons filename is kabab case (file-name), where as the icon you import is camel case (fileName)
|
|
17
|
-
// Icons need to be registered (camel case), and then used (kabab case)
|
|
18
|
-
import * as listNumber from '@pega/cosmos-react-core/lib/components/Icon/icons/list-number.icon';
|
|
19
|
-
import * as arrowRight from '@pega/cosmos-react-core/lib/components/Icon/icons/arrow-right.icon';
|
|
20
|
-
import * as globe from '@pega/cosmos-react-core/lib/components/Icon/icons/globe.icon';
|
|
21
|
-
|
|
22
|
-
import StyledPegaDxilMyIconButtonUrlWrapper from './styles';
|
|
23
|
-
|
|
24
|
-
// interface for props
|
|
25
|
-
interface PegaDxilMyIconButtonUrlProps extends PConnFieldProps {
|
|
26
|
-
// If any, enter additional props that only exist on TextInput here
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
export const textFormatter = (value: string) => {
|
|
30
|
-
const displayComponent = (
|
|
31
|
-
<URLDisplay target='_blank' value={value} displayText={value} variant='link' />
|
|
32
|
-
);
|
|
33
|
-
|
|
34
|
-
return displayComponent;
|
|
35
|
-
};
|
|
36
|
-
|
|
37
|
-
// *************
|
|
38
|
-
// This component is meant to be an example of usage (Icon, Button, Link, etc.) and NOT meant to be
|
|
39
|
-
// used "as is"
|
|
40
|
-
//
|
|
41
|
-
// In this example, Icon is shown on its own and inside a Button
|
|
42
|
-
// Though an Icon can have an "onClick" event is it recommended if you want to click on it,
|
|
43
|
-
// to put it in a Button (shown below), so you can have a tooltip and hover style or put it
|
|
44
|
-
// in a Link (shown below) as a URL.
|
|
45
|
-
//
|
|
46
|
-
// For the button, the click will get a list of countries and display in a table
|
|
47
|
-
//
|
|
48
|
-
// Globe icon is an icon placed in a Link element. The Link element to use an icon internally. (NOTE: In general
|
|
49
|
-
// the Link element shows the open icon to the left of the link text, but here we are using
|
|
50
|
-
// another icon, so with "icon" specified in the Link element, the open icon doesn't show)
|
|
51
|
-
// Link elements do not handle bad urls well, so we have a simple validator to prevent the Link element
|
|
52
|
-
// from getting most bad urls.
|
|
53
|
-
//
|
|
54
|
-
// NOTE: because icons have to be imported and registered, you can NOT put the icon name
|
|
55
|
-
// inside the config.json and let the user pick it, if it is not already part of your
|
|
56
|
-
// import and registration (can't be done on the fly)
|
|
57
|
-
// **************
|
|
58
|
-
|
|
59
|
-
// props passed in combination of props from property panel (config.json) and run time props from Constellation
|
|
60
|
-
// any default values in config.pros should be set in defaultProps at bottom of this file
|
|
61
|
-
function PegaDxilMyIconButtonUrl(props: PegaDxilMyIconButtonUrlProps) {
|
|
62
|
-
const { value, displayMode, getPConnect, testId } = props;
|
|
63
|
-
const [countrylist, setCountrylist] = useState([]);
|
|
64
|
-
const [showTable, setShowTable] = useState(false);
|
|
65
|
-
const [isLoading, setIsLoading] = useState(true);
|
|
66
|
-
const [validUrl, setValidUrl] = useState('about:blank');
|
|
67
|
-
const PConnect = getPConnect();
|
|
68
|
-
const dataViewName = 'CountryList';
|
|
69
|
-
const context = PConnect.getContextName();
|
|
70
|
-
|
|
71
|
-
// IMPORTANT: need to register icons used in camel case
|
|
72
|
-
registerIcon(listNumber, arrowRight, globe);
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
// setting up columns for the work list table
|
|
76
|
-
const columns = [
|
|
77
|
-
{ renderer: 'countryName', label: PConnect.getLocalizedValue('Country Name', '', '') },
|
|
78
|
-
{ renderer: 'shortName', label: PConnect.getLocalizedValue('Abbreviation', '', '') }
|
|
79
|
-
];
|
|
80
|
-
|
|
81
|
-
// toggle showing table and getting table data
|
|
82
|
-
function showHideTable() {
|
|
83
|
-
setShowTable(prevShowTable => !prevShowTable);
|
|
84
|
-
}
|
|
85
|
-
|
|
86
|
-
// check if url is valid (simple)
|
|
87
|
-
function validateUrl(href: string) {
|
|
88
|
-
return /^(?:(?:(?:https?|ftp):)?\/\/)(?:\S+(?::\S*)?@)?(?:(?!(?:10|127)(?:\.\d{1,3}){3})(?!(?:169\.254|192\.168)(?:\.\d{1,3}){2})(?!172\.(?:1[6-9]|2\d|3[0-1])(?:\.\d{1,3}){2})(?:[1-9]\d?|1\d\d|2[01]\d|22[0-3])(?:\.(?:1?\d{1,2}|2[0-4]\d|25[0-5])){2}(?:\.(?:[1-9]\d?|1\d\d|2[0-4]\d|25[0-4]))|(?:(?:[a-z\u00a1-\uffff0-9]-*)*[a-z\u00a1-\uffff0-9]+)(?:\.(?:[a-z\u00a1-\uffff0-9]-*)*[a-z\u00a1-\uffff0-9]+)*(?:\.(?:[a-z\u00a1-\uffff]{2,})))(?::\d{2,5})?(?:[/?#]\S*)?$/i.test(
|
|
89
|
-
href
|
|
90
|
-
);
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
// Testing to see if value entered is valid url, if not can't use it.
|
|
94
|
-
// Reason for this code is that you can NOT pass to Link component
|
|
95
|
-
// a bad url, or it will error out.
|
|
96
|
-
// For example: Since the value is the property field,
|
|
97
|
-
// it could be entered from another component and thus as it is
|
|
98
|
-
// entered (typed in), it won't be valid until it is all entered.
|
|
99
|
-
// NOTE: can't have a blank value for the url as the Link element will error out
|
|
100
|
-
// in App studio preview
|
|
101
|
-
useEffect(() => {
|
|
102
|
-
if (validateUrl(value)) {
|
|
103
|
-
setValidUrl(value);
|
|
104
|
-
} else {
|
|
105
|
-
setValidUrl('about:blank');
|
|
106
|
-
}
|
|
107
|
-
}, [value]);
|
|
108
|
-
|
|
109
|
-
// going to get data for worklist to put into a table
|
|
110
|
-
// data comes from calling a PCore function to get
|
|
111
|
-
// get data from a data page and a PConnect function
|
|
112
|
-
// to get getContextName
|
|
113
|
-
useEffect(() => {
|
|
114
|
-
const params = { };
|
|
115
|
-
|
|
116
|
-
// only retrieve table data if table is shown
|
|
117
|
-
if (showTable) {
|
|
118
|
-
PCore.getDataPageUtils()
|
|
119
|
-
.getDataAsync(dataViewName, context, params, null, null)
|
|
120
|
-
.then((response: any) => {
|
|
121
|
-
setIsLoading(false);
|
|
122
|
-
// table requires an index or will get setExtraStackFrame error
|
|
123
|
-
if (response.data !== null) {
|
|
124
|
-
setCountrylist(
|
|
125
|
-
response.data.map((entry: any, index: number) => {
|
|
126
|
-
// mapping the data into the column names
|
|
127
|
-
// MUST have an id/index or will get a setExtraStackFrame error
|
|
128
|
-
// put a key in the table
|
|
129
|
-
return {
|
|
130
|
-
countryName: entry.Name,
|
|
131
|
-
shortName: entry.ShortName,
|
|
132
|
-
id: index
|
|
133
|
-
};
|
|
134
|
-
})
|
|
135
|
-
);
|
|
136
|
-
}
|
|
137
|
-
else {
|
|
138
|
-
setCountrylist([]);
|
|
139
|
-
setIsLoading(false);
|
|
140
|
-
}
|
|
141
|
-
|
|
142
|
-
})
|
|
143
|
-
.catch((error: any) => {
|
|
144
|
-
setCountrylist([]);
|
|
145
|
-
setIsLoading(false);
|
|
146
|
-
console.log(error);
|
|
147
|
-
});
|
|
148
|
-
}
|
|
149
|
-
}, [context, showTable]);
|
|
150
|
-
|
|
151
|
-
// when DISPLAY_ONLY, in this example we will just show the URL.
|
|
152
|
-
if (displayMode === 'DISPLAY_ONLY') {
|
|
153
|
-
const displayComp = textFormatter(validUrl);
|
|
154
|
-
return (
|
|
155
|
-
<StyledPegaDxilMyIconButtonUrlWrapper> {displayComp} </StyledPegaDxilMyIconButtonUrlWrapper>
|
|
156
|
-
);
|
|
157
|
-
}
|
|
158
|
-
|
|
159
|
-
return (
|
|
160
|
-
<StyledPegaDxilMyIconButtonUrlWrapper>
|
|
161
|
-
<div style={{ display: 'flex' }} data-testid={testId}>
|
|
162
|
-
<Icon
|
|
163
|
-
style={{ height: '1.5rem', width: '1.5rem' }}
|
|
164
|
-
// icon name is kabab case
|
|
165
|
-
name='arrow-right'
|
|
166
|
-
role='img'
|
|
167
|
-
aria-label='arrow right'
|
|
168
|
-
/>
|
|
169
|
-
<Label style={{ margin: '0.1rem' }}>
|
|
170
|
-
{' '}
|
|
171
|
-
{PConnect.getLocalizedValue('List of countries', '', '')}{' '}
|
|
172
|
-
</Label>
|
|
173
|
-
<Button
|
|
174
|
-
icon
|
|
175
|
-
label={PConnect.getLocalizedValue('Click to show/hide country list', '', '')}
|
|
176
|
-
variant='link'
|
|
177
|
-
compact={false}
|
|
178
|
-
onClick={showHideTable}
|
|
179
|
-
>
|
|
180
|
-
<Icon
|
|
181
|
-
style={{ height: '1.5rem', width: '1.5rem' }}
|
|
182
|
-
// icon name is kabab case
|
|
183
|
-
name='list-number'
|
|
184
|
-
role='img'
|
|
185
|
-
aria-label='numbered list'
|
|
186
|
-
/>
|
|
187
|
-
</Button>
|
|
188
|
-
<Link href={validUrl} variant='link' label={validUrl} icon>
|
|
189
|
-
<Icon
|
|
190
|
-
style={{ height: '1.5rem', width: '1.5rem' }}
|
|
191
|
-
// icon name is kabab case
|
|
192
|
-
name='globe'
|
|
193
|
-
role='img'
|
|
194
|
-
aria-label='open link'
|
|
195
|
-
/>
|
|
196
|
-
</Link>
|
|
197
|
-
</div>
|
|
198
|
-
{showTable && (
|
|
199
|
-
<Table
|
|
200
|
-
title={PConnect.getLocalizedValue('State list', '', '')}
|
|
201
|
-
columns={columns}
|
|
202
|
-
data={countrylist}
|
|
203
|
-
loading={isLoading}
|
|
204
|
-
loadingMessage={PConnect.getLocalizedValue('Loading country list', '', '')}
|
|
205
|
-
/>
|
|
206
|
-
)}
|
|
207
|
-
</StyledPegaDxilMyIconButtonUrlWrapper>
|
|
208
|
-
);
|
|
209
|
-
}
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
export default withConfiguration(PegaDxilMyIconButtonUrl);
|
package/tests/assets/library/components/createAll/Launchpad/Pega_DXIL_MyInteger/PConnProps.d.ts
DELETED
|
@@ -1,46 +0,0 @@
|
|
|
1
|
-
import {PConnect } from '@pega/pcore-pconnect-typedefs';
|
|
2
|
-
|
|
3
|
-
// PConnProps.d.ts
|
|
4
|
-
// This gives us a place to have each component (which is most DX Components) that is
|
|
5
|
-
// expected to have a getPConnect extend its props (from BaseProps)
|
|
6
|
-
// such that every component will be expected to have a getPConnect() function
|
|
7
|
-
// that returns a PConnect object. (new/better way of doing .propTypes).
|
|
8
|
-
// This PConnProps can be extended to include other props that we know are in every component
|
|
9
|
-
export interface PConnProps {
|
|
10
|
-
// getPConnect should exist for every C11n component. (add @ts-ignore in special cases where it isn't)
|
|
11
|
-
getPConnect: () => typeof PConnect;
|
|
12
|
-
|
|
13
|
-
// Allow any/all other key/value pairs in the BaseProps for now
|
|
14
|
-
// TODO: refine which other props are always expected for various component
|
|
15
|
-
// types and consider further interface "subclassing". For example, we may
|
|
16
|
-
// want to create a "BasePropsForm" that gives guidance on required, readonly, etc.
|
|
17
|
-
// and any other props that every Form component expects.
|
|
18
|
-
// For example, see the PConnFieldProps below.
|
|
19
|
-
// NOTE: if you uncomment the line below, the PConnProps type will allow
|
|
20
|
-
// otherwise undefined types to appear. This can be helpful for debugging
|
|
21
|
-
// or when adding new components whose types aren't yet known.
|
|
22
|
-
// [key: string]: any;
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
// PConnFieldProps extends PConnProps to bring in the common properties that are
|
|
27
|
-
// associated with most field components (ex: Dropdown, TextInput, etc.) in the
|
|
28
|
-
// components/field directory
|
|
29
|
-
export interface PConnFieldProps extends PConnProps {
|
|
30
|
-
label: string,
|
|
31
|
-
required: boolean,
|
|
32
|
-
disabled: boolean,
|
|
33
|
-
value: any,
|
|
34
|
-
validatemessage: string,
|
|
35
|
-
status?: string,
|
|
36
|
-
onChange?: any,
|
|
37
|
-
onBlur?: any,
|
|
38
|
-
readOnly: boolean,
|
|
39
|
-
testId: string,
|
|
40
|
-
helperText: string,
|
|
41
|
-
displayMode?: string,
|
|
42
|
-
hideLabel: boolean,
|
|
43
|
-
placeholder?: string,
|
|
44
|
-
fieldMetadata?: any,
|
|
45
|
-
additionalProps?: any
|
|
46
|
-
}
|