@pega/dx-component-builder-sdk 24.1.10 → 24.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/package.json +1 -1
- package/src/constants.js +54 -2
- package/src/tasks/authenticate/index.js +1 -1
- package/src/tasks/create/templates/Constellation/field/Boolean/create-nonce.ts.mustache +5 -0
- package/src/tasks/create/templates/Constellation/field/Boolean/index.tsx.mustache +1 -0
- package/src/tasks/create/templates/Constellation/field/Date/create-nonce.ts.mustache +5 -0
- package/src/tasks/create/templates/Constellation/field/Date/index.tsx.mustache +1 -0
- package/src/tasks/create/templates/Constellation/field/DateTime/create-nonce.ts.mustache +5 -0
- package/src/tasks/create/templates/Constellation/field/DateTime/index.tsx.mustache +1 -0
- package/src/tasks/create/templates/Constellation/field/Decimal/create-nonce.ts.mustache +5 -0
- package/src/tasks/create/templates/Constellation/field/Decimal/index.tsx.mustache +1 -0
- package/src/tasks/create/templates/Constellation/field/Decimal-Currency/create-nonce.ts.mustache +5 -0
- package/src/tasks/create/templates/Constellation/field/Decimal-Currency/index.tsx.mustache +1 -0
- package/src/tasks/create/templates/Constellation/field/Decimal-Percentage/create-nonce.ts.mustache +5 -0
- package/src/tasks/create/templates/Constellation/field/Decimal-Percentage/index.tsx.mustache +1 -0
- package/src/tasks/create/templates/Constellation/field/Icon-Button-URL/create-nonce.ts.mustache +5 -0
- package/src/tasks/create/templates/Constellation/field/Icon-Button-URL/demo.stories.tsx.mustache +15 -10
- package/src/tasks/create/templates/Constellation/field/Icon-Button-URL/index.tsx.mustache +1 -0
- package/src/tasks/create/templates/Constellation/field/Integer/create-nonce.ts.mustache +5 -0
- package/src/tasks/create/templates/Constellation/field/Integer/index.tsx.mustache +1 -0
- package/src/tasks/create/templates/Constellation/field/Picklist/create-nonce.ts.mustache +5 -0
- package/src/tasks/create/templates/Constellation/field/Picklist/index.tsx.mustache +1 -0
- package/src/tasks/create/templates/Constellation/field/Picklist-Autocomplete/create-nonce.ts.mustache +5 -0
- package/src/tasks/create/templates/Constellation/field/Picklist-Autocomplete/index.tsx.mustache +1 -0
- package/src/tasks/create/templates/Constellation/field/Picklist-RadioButtons/create-nonce.ts.mustache +5 -0
- package/src/tasks/create/templates/Constellation/field/Picklist-RadioButtons/index.tsx.mustache +1 -0
- package/src/tasks/create/templates/Constellation/field/Text/create-nonce.ts.mustache +5 -0
- package/src/tasks/create/templates/Constellation/field/Text/index.tsx.mustache +1 -0
- package/src/tasks/create/templates/Constellation/field/Text-Email/create-nonce.ts.mustache +5 -0
- package/src/tasks/create/templates/Constellation/field/Text-Email/index.tsx.mustache +1 -0
- package/src/tasks/create/templates/Constellation/field/Text-Input/create-nonce.ts.mustache +5 -0
- package/src/tasks/create/templates/Constellation/field/Text-Input/index.tsx.mustache +1 -0
- package/src/tasks/create/templates/Constellation/field/Text-Paragraph/create-nonce.ts.mustache +5 -0
- package/src/tasks/create/templates/Constellation/field/Text-Paragraph/index.tsx.mustache +1 -0
- package/src/tasks/create/templates/Constellation/field/Text-Phone/create-nonce.ts.mustache +5 -0
- package/src/tasks/create/templates/Constellation/field/Text-Phone/index.tsx.mustache +1 -0
- package/src/tasks/create/templates/Constellation/field/Text-URL/create-nonce.ts.mustache +5 -0
- package/src/tasks/create/templates/Constellation/field/Text-URL/index.tsx.mustache +1 -0
- package/src/tasks/create/templates/Constellation/field/TimeOfDay/create-nonce.ts.mustache +5 -0
- package/src/tasks/create/templates/Constellation/field/TimeOfDay/index.tsx.mustache +1 -0
- package/src/tasks/create/templates/Constellation/template/DETAILS/create-nonce.ts.mustache +5 -0
- package/src/tasks/create/templates/Constellation/template/DETAILS/index.tsx.mustache +1 -0
- package/src/tasks/create/templates/Constellation/template/DETAILS-region/create-nonce.ts.mustache +5 -0
- package/src/tasks/create/templates/Constellation/template/DETAILS-region/index.tsx.mustache +1 -0
- package/src/tasks/create/templates/Constellation/template/FORM/create-nonce.ts.mustache +5 -0
- package/src/tasks/create/templates/Constellation/template/FORM/index.tsx.mustache +1 -0
- package/src/tasks/create/templates/Constellation/template/FORM-region/create-nonce.ts.mustache +5 -0
- package/src/tasks/create/templates/Constellation/template/FORM-region/index.tsx.mustache +1 -0
- package/src/tasks/create/templates/Constellation/template/PAGE/create-nonce.ts.mustache +5 -0
- package/src/tasks/create/templates/Constellation/template/PAGE/index.tsx.mustache +1 -0
- package/src/tasks/create/templates/Constellation/widget/CASE/create-nonce.ts.mustache +5 -0
- package/src/tasks/create/templates/Constellation/widget/CASE/demo.stories.tsx.mustache +22 -22
- package/src/tasks/create/templates/Constellation/widget/CASE/index.tsx.mustache +1 -0
- package/src/tasks/create/templates/Constellation/widget/PAGE/create-nonce.ts.mustache +5 -0
- package/src/tasks/create/templates/Constellation/widget/PAGE/demo.stories.tsx.mustache +15 -17
- package/src/tasks/create/templates/Constellation/widget/PAGE/index.tsx.mustache +1 -0
- package/src/tasks/create/templates/Constellation/widget/PAGE-CASE/create-nonce.ts.mustache +5 -0
- package/src/tasks/create/templates/Constellation/widget/PAGE-CASE/index.tsx.mustache +1 -0
- package/src/tasks/create/templates/SDK-Angular/field/Boolean/boolean.component.scss.mustache +14 -1
- package/src/tasks/create/templates/SDK-Angular/field/Boolean/boolean.component.ts.mustache +6 -7
- package/src/tasks/create/templates/SDK-Angular/field/Boolean/demo.stories.tsx.mustache +10 -0
- package/src/tasks/create/templates/SDK-Angular/field/DateTime/date-time.component.html.mustache +5 -5
- package/src/tasks/create/templates/SDK-Angular/field/DateTime/date-time.component.scss.mustache +0 -1
- package/src/tasks/create/templates/SDK-Angular/field/DateTime/date-time.component.ts.mustache +14 -37
- package/src/tasks/create/templates/SDK-Angular/field/Decimal/decimal.component.html.mustache +14 -4
- package/src/tasks/create/templates/SDK-Angular/field/Decimal/decimal.component.ts.mustache +42 -5
- package/src/tasks/create/templates/SDK-Angular/field/Decimal/demo.stories.tsx.mustache +3 -0
- package/src/tasks/create/templates/SDK-Angular/field/Decimal-Currency/config.json.mustache +166 -0
- package/src/tasks/create/templates/SDK-Angular/field/Decimal-Currency/decimal-currency.component.html.mustache +15 -6
- package/src/tasks/create/templates/SDK-Angular/field/Decimal-Currency/decimal-currency.component.scss.mustache +2 -2
- package/src/tasks/create/templates/SDK-Angular/field/Decimal-Currency/decimal-currency.component.ts.mustache +36 -18
- package/src/tasks/create/templates/SDK-Angular/field/Decimal-Percentage/decimal-percentage.component.html.mustache +15 -4
- package/src/tasks/create/templates/SDK-Angular/field/Decimal-Percentage/decimal-percentage.component.scss.mustache +18 -18
- package/src/tasks/create/templates/SDK-Angular/field/Decimal-Percentage/decimal-percentage.component.ts.mustache +29 -5
- package/src/tasks/create/templates/SDK-Angular/field/Icon-Button-URL/demo.stories.tsx.mustache +42 -41
- package/src/tasks/create/templates/SDK-Angular/field/Icon-Button-URL/icon-button-url.component.ts.mustache +1 -1
- package/src/tasks/create/templates/SDK-Angular/field/Picklist/picklist.component.ts.mustache +0 -3
- package/src/tasks/create/templates/SDK-Angular/field/Picklist-Autocomplete/picklist-autocomplete.component.ts.mustache +1 -1
- package/src/tasks/create/templates/SDK-Angular/field/Picklist-RadioButtons/picklist-radio-buttons.component.ts.mustache +1 -3
- package/src/tasks/create/templates/SDK-Angular/field/Text-Paragraph/text-paragraph.component.ts.mustache +0 -2
- package/src/tasks/create/templates/SDK-Angular/template/FORM/form.component.html.mustache +3 -4
- package/src/tasks/create/templates/SDK-Angular/template/FORM/form.component.ts.mustache +0 -1
- package/src/tasks/create/templates/SDK-Angular/template/FORM-region/form.component.html.mustache +1 -1
- package/src/tasks/create/templates/SDK-Angular/widget/CASE/case.component.ts.mustache +5 -5
- package/src/tasks/create/templates/SDK-Angular/widget/CASE/demo.stories.tsx.mustache +35 -34
- package/src/tasks/create/templates/SDK-Angular/widget/PAGE/demo.stories.tsx.mustache +27 -26
- package/src/tasks/create/templates/SDK-Angular/widget/PAGE-CASE/page-case.component.html.mustache +0 -2
- package/src/tasks/create/templates/SDK-React/field/Decimal-Currency/config.json.mustache +166 -0
- package/src/tasks/create/templates/SDK-React/widget/PAGE/index.tsx.mustache +1 -1
- package/src/tasks/override/index.js +11 -1
- package/src/tasks/override-all/index.js +12 -9
- package/tests/assets/sdk-a/components/create/_components.md +6 -0
- package/tests/assets/sdk-a/components/create/custom-constellation/field/Pega_DXIL_MyTestText/create-nonce.ts +5 -0
- package/tests/assets/sdk-a/components/create/custom-constellation/field/Pega_DXIL_MyTestText/demo.stories.tsx +23 -9
- package/tests/assets/sdk-a/components/create/custom-constellation/field/Pega_DXIL_MyTestText/index.tsx +97 -24
- package/tests/assets/sdk-a/components/create/custom-constellation/field/Pega_DXIL_MyTestText/mock.ts +8 -1
- package/tests/assets/sdk-a/components/create/custom-constellation/field/Pega_DXIL_MyTestText/styles.ts +7 -14
- package/tests/assets/sdk-a/components/create/override-sdk/designSystemExtension/banner/banner.component.html +28 -0
- package/tests/assets/sdk-a/components/create/override-sdk/designSystemExtension/banner/banner.component.scss +64 -0
- package/tests/assets/sdk-a/components/create/override-sdk/designSystemExtension/banner/banner.component.spec.ts +22 -0
- package/tests/assets/sdk-a/components/create/override-sdk/designSystemExtension/banner/banner.component.ts +26 -0
- package/tests/assets/sdk-a/components/create/override-sdk/designSystemExtension/material-case-summary/material-case-summary.component.html +7 -4
- package/tests/assets/sdk-a/components/create/override-sdk/designSystemExtension/material-case-summary/material-case-summary.component.ts +3 -1
- package/tests/assets/sdk-a/components/create/override-sdk/designSystemExtension/material-vertical-tabs/material-vertical-tabs.component.html +1 -1
- package/tests/assets/sdk-a/components/create/override-sdk/designSystemExtension/operator/operator.component.ts +10 -5
- package/tests/assets/sdk-a/components/create/override-sdk/designSystemExtension/wss-quick-create/wss-quick-create.component.html +13 -0
- package/tests/assets/sdk-a/components/create/override-sdk/designSystemExtension/wss-quick-create/wss-quick-create.component.scss +43 -0
- package/tests/assets/sdk-a/components/create/override-sdk/designSystemExtension/wss-quick-create/wss-quick-create.component.spec.ts +22 -0
- package/tests/assets/sdk-a/components/create/override-sdk/designSystemExtension/wss-quick-create/wss-quick-create.component.ts +15 -0
- package/tests/assets/sdk-a/components/create/override-sdk/field/auto-complete/auto-complete.component.ts +1 -1
- package/tests/assets/sdk-a/components/create/override-sdk/field/cancel-alert/cancel-alert.component.ts +0 -2
- package/tests/assets/sdk-a/components/create/override-sdk/field/check-box/check-box.component.html +16 -15
- package/tests/assets/sdk-a/components/create/override-sdk/field/check-box/check-box.component.scss +14 -1
- package/tests/assets/sdk-a/components/create/override-sdk/field/check-box/check-box.component.ts +126 -44
- package/tests/assets/sdk-a/components/create/override-sdk/field/currency/currency.component.html +15 -6
- package/tests/assets/sdk-a/components/create/override-sdk/field/currency/currency.component.ts +36 -18
- package/tests/assets/sdk-a/components/create/override-sdk/field/date-time/date-time.component.html +5 -5
- package/tests/assets/sdk-a/components/create/override-sdk/field/date-time/date-time.component.ts +15 -37
- package/tests/assets/sdk-a/components/create/override-sdk/field/decimal/decimal.component.html +14 -4
- package/tests/assets/sdk-a/components/create/override-sdk/field/decimal/decimal.component.ts +42 -5
- package/tests/assets/sdk-a/components/create/override-sdk/field/dropdown/dropdown.component.ts +0 -3
- package/tests/assets/sdk-a/components/create/override-sdk/field/group/group.component.html +1 -1
- package/tests/assets/sdk-a/components/create/override-sdk/field/group/group.component.ts +4 -0
- package/tests/assets/sdk-a/components/create/override-sdk/field/percentage/percentage.component.html +15 -4
- package/tests/assets/sdk-a/components/create/override-sdk/field/percentage/percentage.component.ts +29 -5
- package/tests/assets/sdk-a/components/create/override-sdk/field/radio-buttons/radio-buttons.component.ts +0 -3
- package/tests/assets/sdk-a/components/create/override-sdk/field/rich-text/config-ext.json +11 -0
- package/tests/assets/sdk-a/components/create/override-sdk/field/rich-text/rich-text.component.html +1 -1
- package/tests/assets/sdk-a/components/create/override-sdk/field/scalar-list/scalar-list.component.ts +2 -1
- package/tests/assets/sdk-a/components/create/override-sdk/field/text-area/text-area.component.ts +0 -2
- package/tests/assets/sdk-a/components/create/override-sdk/field/time/time.component.html +1 -0
- package/tests/assets/sdk-a/components/create/override-sdk/field/time/time.component.ts +2 -0
- package/tests/assets/sdk-a/components/create/override-sdk/field/url/url.component.html +1 -0
- package/tests/assets/sdk-a/components/create/override-sdk/field/url/url.component.ts +2 -0
- package/tests/assets/sdk-a/components/create/override-sdk/field/user-reference/user-reference.component.html +50 -45
- package/tests/assets/sdk-a/components/create/override-sdk/field/user-reference/user-reference.component.ts +33 -15
- package/tests/assets/sdk-a/components/create/override-sdk/infra/assignment/assignment.component.ts +38 -39
- package/tests/assets/sdk-a/components/create/override-sdk/infra/dashboard-filter/dashboard-filter.component.html +35 -0
- package/tests/assets/sdk-a/components/create/override-sdk/infra/dashboard-filter/dashboard-filter.component.scss +14 -0
- package/tests/assets/sdk-a/components/create/override-sdk/infra/dashboard-filter/dashboard-filter.component.spec.ts +24 -0
- package/tests/assets/sdk-a/components/create/override-sdk/infra/dashboard-filter/dashboard-filter.component.ts +89 -0
- package/tests/assets/sdk-a/components/create/override-sdk/infra/defer-load/defer-load.component.ts +5 -8
- package/tests/assets/sdk-a/components/create/override-sdk/infra/flow-container/flow-container.component.html +44 -0
- package/tests/assets/sdk-a/components/create/override-sdk/infra/flow-container/flow-container.component.scss +1 -0
- package/tests/assets/sdk-a/components/create/override-sdk/infra/flow-container/flow-container.component.spec.ts +24 -0
- package/tests/assets/sdk-a/components/create/override-sdk/infra/flow-container/flow-container.component.ts +634 -0
- package/tests/assets/sdk-a/components/create/override-sdk/infra/flow-container/helpers.ts +79 -0
- package/tests/assets/sdk-a/components/create/override-sdk/infra/hybrid-view-container/hybrid-view-container.component.html +1 -0
- package/tests/assets/sdk-a/components/create/override-sdk/infra/hybrid-view-container/hybrid-view-container.component.scss +0 -0
- package/tests/assets/sdk-a/components/create/override-sdk/infra/hybrid-view-container/hybrid-view-container.component.spec.ts +24 -0
- package/tests/assets/sdk-a/components/create/override-sdk/infra/hybrid-view-container/hybrid-view-container.component.ts +24 -0
- package/tests/assets/sdk-a/components/create/override-sdk/infra/modal-view-container/modal-view-container.component.html +35 -0
- package/tests/assets/sdk-a/components/create/override-sdk/infra/modal-view-container/modal-view-container.component.scss +1 -0
- package/tests/assets/sdk-a/components/create/override-sdk/infra/modal-view-container/modal-view-container.component.spec.ts +24 -0
- package/tests/assets/sdk-a/components/create/override-sdk/infra/modal-view-container/modal-view-container.component.ts +426 -0
- package/tests/assets/sdk-a/components/create/override-sdk/infra/multi-step/multi-step.component.html +1 -1
- package/tests/assets/sdk-a/components/create/override-sdk/infra/multi-step/multi-step.component.scss +1 -0
- package/tests/assets/sdk-a/components/create/override-sdk/infra/navbar/navbar.component.html +4 -4
- package/tests/assets/sdk-a/components/create/override-sdk/infra/navbar/navbar.component.ts +6 -3
- package/tests/assets/sdk-a/components/create/override-sdk/infra/preview-view-container/preview-view-container.component.html +1 -0
- package/tests/assets/sdk-a/components/create/override-sdk/infra/preview-view-container/preview-view-container.component.scss +0 -0
- package/tests/assets/sdk-a/components/create/override-sdk/infra/preview-view-container/preview-view-container.component.spec.ts +24 -0
- package/tests/assets/sdk-a/components/create/override-sdk/infra/preview-view-container/preview-view-container.component.ts +35 -0
- package/tests/assets/sdk-a/components/create/override-sdk/infra/root-container/root-container.component.html +36 -0
- package/tests/assets/sdk-a/components/create/override-sdk/infra/root-container/root-container.component.scss +18 -0
- package/tests/assets/sdk-a/components/create/override-sdk/infra/root-container/root-container.component.spec.ts +24 -0
- package/tests/assets/sdk-a/components/create/override-sdk/infra/root-container/root-container.component.ts +256 -0
- package/tests/assets/sdk-a/components/create/override-sdk/infra/view/view.component.ts +1 -1
- package/tests/assets/sdk-a/components/create/override-sdk/infra/view-container/view-container.component.html +31 -0
- package/tests/assets/sdk-a/components/create/override-sdk/infra/view-container/view-container.component.scss +1 -0
- package/tests/assets/sdk-a/components/create/override-sdk/infra/view-container/view-container.component.spec.ts +24 -0
- package/tests/assets/sdk-a/components/create/override-sdk/infra/view-container/view-container.component.ts +288 -0
- package/tests/assets/sdk-a/components/create/override-sdk/template/banner-page/banner-page.component.html +12 -0
- package/tests/assets/sdk-a/components/create/override-sdk/template/banner-page/banner-page.component.scss +0 -0
- package/tests/assets/sdk-a/components/create/override-sdk/template/banner-page/banner-page.component.spec.ts +22 -0
- package/tests/assets/sdk-a/components/create/override-sdk/template/banner-page/banner-page.component.ts +65 -0
- package/tests/assets/sdk-a/components/create/override-sdk/template/banner-page/config-ext.json +10 -0
- package/tests/assets/sdk-a/components/create/override-sdk/template/case-summary/case-summary.component.ts +37 -3
- package/tests/assets/sdk-a/components/create/override-sdk/template/case-view/case-view.component.html +3 -3
- package/tests/assets/sdk-a/components/create/override-sdk/template/case-view/case-view.component.scss +2 -0
- package/tests/assets/sdk-a/components/create/override-sdk/template/case-view/case-view.component.ts +0 -6
- package/tests/assets/sdk-a/components/create/override-sdk/template/data-reference/data-reference.component.ts +1 -3
- package/tests/assets/sdk-a/components/create/override-sdk/template/dynamic-tabs/config-ext.json +37 -0
- package/tests/assets/sdk-a/components/create/override-sdk/template/dynamic-tabs/dynamic-tabs.component.html +5 -0
- package/tests/assets/sdk-a/components/create/override-sdk/template/dynamic-tabs/dynamic-tabs.component.scss +0 -0
- package/tests/assets/sdk-a/components/create/override-sdk/template/dynamic-tabs/dynamic-tabs.component.spec.ts +22 -0
- package/tests/assets/sdk-a/components/create/override-sdk/template/dynamic-tabs/dynamic-tabs.component.ts +77 -0
- package/tests/assets/sdk-a/components/create/override-sdk/template/field-group-template/field-group-template.component.ts +4 -12
- package/tests/assets/sdk-a/components/create/override-sdk/template/field-value-list/field-value-list.component.html +7 -2
- package/tests/assets/sdk-a/components/create/override-sdk/template/field-value-list/field-value-list.component.ts +1 -0
- package/tests/assets/sdk-a/components/create/override-sdk/template/inline-dashboard-page/config-ext.json +10 -0
- package/tests/assets/sdk-a/components/create/override-sdk/template/list-view/list-view.component.html +6 -6
- package/tests/assets/sdk-a/components/create/override-sdk/template/list-view/list-view.component.ts +36 -28
- package/tests/assets/sdk-a/components/create/override-sdk/template/list-view/listViewHelpers.ts +0 -1
- package/tests/assets/sdk-a/components/create/override-sdk/template/repeating-structures/repeating-structures.component.ts +1 -2
- package/tests/assets/sdk-a/components/create/override-sdk/template/simple-table/simple-table.component.ts +0 -2
- package/tests/assets/sdk-a/components/create/override-sdk/template/simple-table-manual/helpers.ts +1 -1
- package/tests/assets/sdk-a/components/create/override-sdk/template/simple-table-manual/simple-table-manual.component.html +1 -1
- package/tests/assets/sdk-a/components/create/override-sdk/template/simple-table-manual/simple-table-manual.component.ts +49 -19
- package/tests/assets/sdk-a/components/create/override-sdk/template/simple-table-select/simple-table-select.component.ts +2 -4
- package/tests/assets/sdk-a/components/create/override-sdk/template/wss-nav-bar/wss-nav-bar.component.html +32 -0
- package/tests/assets/sdk-a/components/create/override-sdk/template/wss-nav-bar/wss-nav-bar.component.scss +164 -0
- package/tests/assets/sdk-a/components/create/override-sdk/template/wss-nav-bar/wss-nav-bar.component.spec.ts +22 -0
- package/tests/assets/sdk-a/components/create/override-sdk/template/wss-nav-bar/wss-nav-bar.component.ts +173 -0
- package/tests/assets/sdk-a/components/create/override-sdk/widget/attachment/attachment.component.html +50 -26
- package/tests/assets/sdk-a/components/create/override-sdk/widget/attachment/attachment.component.scss +118 -0
- package/tests/assets/sdk-a/components/create/override-sdk/widget/attachment/attachment.component.ts +256 -501
- package/tests/assets/sdk-a/components/create/override-sdk/widget/case-history/case-history.component.ts +1 -2
- package/tests/assets/sdk-a/components/create/override-sdk/widget/feed-container/feed-container.component.ts +0 -4
- package/tests/assets/sdk-a/components/create/override-sdk/widget/file-utility/file-utility.component.html +2 -2
- package/tests/assets/sdk-a/components/create/override-sdk/widget/file-utility/file-utility.component.ts +13 -17
- package/tests/assets/sdk-a/components/create/override-sdk/widget/list-utility/list-utility.component.html +1 -1
- package/tests/assets/sdk-a/components/create/override-sdk/widget/quick-create/config-ext.json +10 -0
- package/tests/assets/sdk-a/components/create/override-sdk/widget/quick-create/quick-create.component.html +1 -0
- package/tests/assets/sdk-a/components/create/override-sdk/widget/quick-create/quick-create.component.scss +0 -0
- package/tests/assets/sdk-a/components/create/override-sdk/widget/quick-create/quick-create.component.spec.ts +22 -0
- package/tests/assets/sdk-a/components/create/override-sdk/widget/quick-create/quick-create.component.ts +96 -0
- package/tests/assets/sdk-a/components/create/override-sdk/widget/todo/todo.component.html +6 -5
- package/tests/assets/sdk-a/components/create/override-sdk/widget/todo/todo.component.ts +7 -6
- package/tests/assets/sdk-a/components/createAll/_components.md +6 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyBoolean/Boolean.ts +35 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyBoolean/create-nonce.ts +5 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyBoolean/{demo.stories.jsx → demo.stories.tsx} +28 -20
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyBoolean/index.tsx +14 -49
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyBoolean/mock.ts +2 -1
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyBoolean/styles.ts +7 -14
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyCurrency/create-nonce.ts +5 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyCurrency/demo.stories.tsx +28 -15
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyCurrency/index.tsx +25 -76
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyCurrency/mock.ts +11 -1
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyCurrency/styles.ts +7 -14
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyDate/{DateFormatter.js → DateFormatter.ts} +6 -6
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyDate/FormattedText.tsx +20 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyDate/create-nonce.ts +5 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyDate/{date.js → date.ts} +3 -2
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyDate/demo.stories.tsx +31 -24
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyDate/index.tsx +20 -60
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyDate/mock.ts +2 -1
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyDate/styles.ts +7 -14
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyDateTime/create-nonce.ts +5 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyDateTime/{date-time.js → date-time.ts} +12 -12
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/{Pega_DXIL_MyTimeOfDay/time-of-day.js → Pega_DXIL_MyDateTime/date-utils.ts} +27 -26
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyDateTime/{date.js → date.ts} +1 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyDateTime/demo.stories.tsx +32 -25
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyDateTime/index.tsx +14 -60
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyDateTime/mock.ts +3 -1
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyDateTime/styles.ts +7 -14
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyDecimal/create-nonce.ts +5 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyDecimal/demo.stories.tsx +25 -13
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyDecimal/index.tsx +16 -68
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyDecimal/mock.ts +9 -1
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyDecimal/styles.ts +7 -14
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyEmail/create-nonce.ts +5 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyEmail/demo.stories.tsx +24 -11
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyEmail/index.tsx +11 -47
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyEmail/mock.ts +8 -1
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyEmail/styles.ts +7 -14
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyIconButtonURL/PConnProps.d.ts +46 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyIconButtonURL/create-nonce.ts +5 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyIconButtonURL/demo.stories.tsx +104 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyIconButtonURL/index.tsx +202 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyIconButtonURL/mock.ts +5 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyIconButtonURL/styles.ts +8 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyInteger/create-nonce.ts +5 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyInteger/demo.stories.tsx +25 -12
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyInteger/index.tsx +25 -88
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyInteger/mock.ts +8 -2
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyInteger/styles.ts +7 -14
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyParagraph/create-nonce.ts +5 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyParagraph/demo.stories.tsx +24 -11
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyParagraph/index.tsx +14 -49
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyParagraph/mock.ts +9 -1
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyParagraph/styles.ts +7 -14
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyPercentage/create-nonce.ts +5 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyPercentage/demo.stories.tsx +25 -12
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyPercentage/index.tsx +15 -55
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyPercentage/mock.ts +9 -2
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyPercentage/styles.ts +7 -14
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyPhone/create-nonce.ts +5 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyPhone/demo.stories.tsx +25 -11
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyPhone/index.tsx +15 -53
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyPhone/mock.ts +9 -1
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyPhone/styles.ts +7 -14
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyPicklist/create-nonce.ts +5 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyPicklist/demo.stories.tsx +25 -12
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyPicklist/index.tsx +14 -62
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyPicklist/mock.ts +9 -1
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyPicklist/styles.ts +7 -14
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyRadioButtons/create-nonce.ts +5 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyRadioButtons/demo.stories.tsx +25 -13
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyRadioButtons/index.tsx +12 -58
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyRadioButtons/mock.ts +9 -1
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyRadioButtons/styles.ts +7 -14
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyRadioButtons/{textformat-utils.jsx → textformat-utils.tsx} +1 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MySearchbox/create-nonce.ts +5 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MySearchbox/{date.js → date.ts} +16 -37
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MySearchbox/demo.stories.tsx +26 -14
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MySearchbox/{embed-utils.js → embed-utils.ts} +2 -1
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MySearchbox/index.tsx +27 -76
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MySearchbox/mock.ts +8 -1
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MySearchbox/{picklist-utils.js → picklist-utils.ts} +1 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MySearchbox/{repeat-constants.js → repeat-constants.ts} +1 -1
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MySearchbox/{repeat-utils.js → repeat-utils.ts} +6 -12
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MySearchbox/styles.ts +7 -14
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MySearchbox/{textformat-utils.jsx → textformat-utils.tsx} +30 -10
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MySearchbox/utils.ts +4 -1
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyText/create-nonce.ts +5 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyText/demo.stories.tsx +23 -9
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyText/index.tsx +97 -24
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyText/mock.ts +8 -1
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyText/styles.ts +7 -14
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyTextInput/StatusWork.tsx +3 -9
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyTextInput/create-nonce.ts +5 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyTextInput/demo.stories.tsx +24 -11
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyTextInput/index.tsx +12 -51
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyTextInput/mock.ts +9 -1
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyTextInput/styles.ts +7 -14
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyTimeOfDay/create-nonce.ts +5 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyTimeOfDay/demo.stories.tsx +28 -22
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyTimeOfDay/index.tsx +18 -53
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyTimeOfDay/mock.ts +2 -1
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyTimeOfDay/styles.ts +7 -14
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/{Pega_DXIL_MyDateTime/date-utils.js → Pega_DXIL_MyTimeOfDay/time-of-day.ts} +24 -23
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyURL/create-nonce.ts +5 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyURL/demo.stories.tsx +24 -11
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyURL/index.tsx +16 -71
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyURL/mock.ts +9 -1
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyURL/styles.ts +7 -14
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyURL/{text-url.jsx → text-url.tsx} +4 -3
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyDetails/Avatar.tsx +78 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyDetails/DetailsRender.tsx +52 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyDetails/HighlightRender.tsx +46 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyDetails/Operator.tsx +215 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyDetails/StatusWork.tsx +17 -19
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyDetails/create-nonce.ts +5 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyDetails/demo.stories.tsx +94 -29
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyDetails/index.tsx +51 -52
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyDetails/mock.ts +78 -20
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyDetails/styles.ts +21 -12
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyForm/DetailsRender.tsx +59 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyForm/create-nonce.ts +5 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyForm/demo.stories.tsx +91 -16
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyForm/index.tsx +34 -16
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyForm/styles.ts +7 -14
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyPage/GetNextWork.tsx +2 -1
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyPage/create-nonce.ts +5 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyPage/demo.stories.tsx +14 -8
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyPage/index.tsx +6 -16
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyPage/localizations.json +4 -2
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyPage/styles.ts +7 -14
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyPage/{utils.js → utils.ts} +28 -14
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyTwoColumnDetails/Avatar.tsx +78 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyTwoColumnDetails/DetailsRender.tsx +52 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyTwoColumnDetails/HighlightRender.tsx +46 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyTwoColumnDetails/Operator.tsx +215 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyTwoColumnDetails/StatusWork.tsx +17 -19
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyTwoColumnDetails/create-nonce.ts +5 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyTwoColumnDetails/demo.stories.tsx +112 -34
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyTwoColumnDetails/index.tsx +43 -53
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyTwoColumnDetails/mock.ts +68 -10
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyTwoColumnDetails/styles.ts +20 -12
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyTwoColumnDetails/{utils.js → utils.ts} +15 -13
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyTwoColumnForm/DetailsRender.tsx +59 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyTwoColumnForm/create-nonce.ts +5 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyTwoColumnForm/demo.stories.tsx +112 -22
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyTwoColumnForm/index.tsx +27 -13
- package/tests/assets/sdk-a/components/createAll/custom-constellation/template/Pega_DXIL_MyTwoColumnForm/styles.ts +7 -14
- package/tests/assets/sdk-a/components/createAll/custom-constellation/widget/Pega_DXIL_MyCaseWidget/create-nonce.ts +5 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/widget/Pega_DXIL_MyCaseWidget/demo.stories.tsx +34 -28
- package/tests/assets/sdk-a/components/createAll/custom-constellation/widget/Pega_DXIL_MyCaseWidget/index.tsx +4 -10
- package/tests/assets/sdk-a/components/createAll/custom-constellation/widget/Pega_DXIL_MyCaseWidget/styles.ts +7 -14
- package/tests/assets/sdk-a/components/createAll/custom-constellation/widget/Pega_DXIL_MyPageCaseWidget/Avatar.tsx +3 -13
- package/tests/assets/sdk-a/components/createAll/custom-constellation/widget/Pega_DXIL_MyPageCaseWidget/Operator.tsx +5 -20
- package/tests/assets/sdk-a/components/createAll/custom-constellation/widget/Pega_DXIL_MyPageCaseWidget/create-nonce.ts +5 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/widget/Pega_DXIL_MyPageCaseWidget/demo.stories.tsx +15 -9
- package/tests/assets/sdk-a/components/createAll/custom-constellation/widget/Pega_DXIL_MyPageCaseWidget/index.tsx +25 -39
- package/tests/assets/sdk-a/components/createAll/custom-constellation/widget/Pega_DXIL_MyPageCaseWidget/styles.ts +7 -14
- package/tests/assets/sdk-a/components/createAll/custom-constellation/widget/Pega_DXIL_MyPageWidget/create-nonce.ts +5 -0
- package/tests/assets/sdk-a/components/createAll/custom-constellation/widget/Pega_DXIL_MyPageWidget/demo.stories.tsx +100 -16
- package/tests/assets/sdk-a/components/createAll/custom-constellation/widget/Pega_DXIL_MyPageWidget/index.tsx +70 -21
- package/tests/assets/sdk-a/components/createAll/custom-constellation/widget/Pega_DXIL_MyPageWidget/styles.ts +7 -14
- package/tests/assets/sdk-a/components/createAll/custom-sdk/field/pega-dxil-my-boolean/demo.stories.tsx +10 -0
- package/tests/assets/sdk-a/components/createAll/custom-sdk/field/pega-dxil-my-boolean/pega-dxil-my-boolean.component.html +18 -17
- package/tests/assets/sdk-a/components/createAll/custom-sdk/field/pega-dxil-my-boolean/pega-dxil-my-boolean.component.scss +14 -1
- package/tests/assets/sdk-a/components/createAll/custom-sdk/field/pega-dxil-my-boolean/pega-dxil-my-boolean.component.ts +126 -44
- package/tests/assets/sdk-a/components/createAll/custom-sdk/field/pega-dxil-my-currency/config.json +166 -0
- package/tests/assets/sdk-a/components/createAll/custom-sdk/field/pega-dxil-my-currency/pega-dxil-my-currency.component.html +15 -6
- package/tests/assets/sdk-a/components/createAll/custom-sdk/field/pega-dxil-my-currency/pega-dxil-my-currency.component.scss +2 -2
- package/tests/assets/sdk-a/components/createAll/custom-sdk/field/pega-dxil-my-currency/pega-dxil-my-currency.component.ts +36 -18
- package/tests/assets/sdk-a/components/createAll/custom-sdk/field/pega-dxil-my-date-time/pega-dxil-my-date-time.component.html +5 -5
- package/tests/assets/sdk-a/components/createAll/custom-sdk/field/pega-dxil-my-date-time/pega-dxil-my-date-time.component.scss +0 -1
- package/tests/assets/sdk-a/components/createAll/custom-sdk/field/pega-dxil-my-date-time/pega-dxil-my-date-time.component.ts +14 -37
- package/tests/assets/sdk-a/components/createAll/custom-sdk/field/pega-dxil-my-decimal/demo.stories.tsx +3 -0
- package/tests/assets/sdk-a/components/createAll/custom-sdk/field/pega-dxil-my-decimal/pega-dxil-my-decimal.component.html +14 -4
- package/tests/assets/sdk-a/components/createAll/custom-sdk/field/pega-dxil-my-decimal/pega-dxil-my-decimal.component.ts +42 -5
- package/tests/assets/sdk-a/components/createAll/custom-sdk/field/pega-dxil-my-icon-button-url/config.json +64 -0
- package/tests/assets/sdk-a/components/createAll/custom-sdk/field/pega-dxil-my-icon-button-url/demo.stories.tsx +64 -0
- package/tests/assets/sdk-a/components/createAll/custom-sdk/field/pega-dxil-my-icon-button-url/mock.ts +37 -0
- package/tests/assets/sdk-a/components/createAll/custom-sdk/field/pega-dxil-my-icon-button-url/pega-dxil-my-icon-button-url.component.html +37 -0
- package/tests/assets/sdk-a/components/createAll/custom-sdk/field/pega-dxil-my-icon-button-url/pega-dxil-my-icon-button-url.component.scss +24 -0
- package/tests/assets/sdk-a/components/createAll/custom-sdk/field/pega-dxil-my-icon-button-url/pega-dxil-my-icon-button-url.component.spec.ts +26 -0
- package/tests/assets/sdk-a/components/createAll/custom-sdk/field/pega-dxil-my-icon-button-url/pega-dxil-my-icon-button-url.component.ts +195 -0
- package/tests/assets/sdk-a/components/createAll/custom-sdk/field/pega-dxil-my-paragraph/pega-dxil-my-paragraph.component.ts +0 -2
- package/tests/assets/sdk-a/components/createAll/custom-sdk/field/pega-dxil-my-percentage/pega-dxil-my-percentage.component.html +15 -4
- package/tests/assets/sdk-a/components/createAll/custom-sdk/field/pega-dxil-my-percentage/pega-dxil-my-percentage.component.scss +18 -18
- package/tests/assets/sdk-a/components/createAll/custom-sdk/field/pega-dxil-my-percentage/pega-dxil-my-percentage.component.ts +29 -5
- package/tests/assets/sdk-a/components/createAll/custom-sdk/field/pega-dxil-my-picklist/pega-dxil-my-picklist.component.ts +0 -3
- package/tests/assets/sdk-a/components/createAll/custom-sdk/field/pega-dxil-my-radiobuttons/pega-dxil-my-radiobuttons.component.ts +1 -3
- package/tests/assets/sdk-a/components/createAll/custom-sdk/field/pega-dxil-my-searchbox/pega-dxil-my-searchbox.component.ts +1 -1
- package/tests/assets/sdk-a/components/createAll/custom-sdk/field/pega-dxil-my-time-of-day/pega-dxil-my-time-of-day.component.html +1 -0
- package/tests/assets/sdk-a/components/createAll/custom-sdk/field/pega-dxil-my-time-of-day/pega-dxil-my-time-of-day.component.ts +2 -0
- package/tests/assets/sdk-a/components/createAll/custom-sdk/field/pega-dxil-my-url/pega-dxil-my-url.component.html +1 -0
- package/tests/assets/sdk-a/components/createAll/custom-sdk/field/pega-dxil-my-url/pega-dxil-my-url.component.ts +2 -0
- package/tests/assets/sdk-a/components/createAll/custom-sdk/template/pega-dxil-my-form/pega-dxil-my-form.component.html +3 -4
- package/tests/assets/sdk-a/components/createAll/custom-sdk/template/pega-dxil-my-form/pega-dxil-my-form.component.ts +0 -1
- package/tests/assets/sdk-a/components/createAll/custom-sdk/template/pega-dxil-my-two-column-form/pega-dxil-my-two-column-form.component.html +1 -1
- package/tests/assets/sdk-a/components/createAll/custom-sdk/template/pega-dxil-my-two-column-form/pega-dxil-my-two-column-form.component.scss +1 -1
- package/tests/assets/sdk-a/components/createAll/custom-sdk/widget/pega-dxil-my-case-widget/demo.stories.tsx +35 -34
- package/tests/assets/sdk-a/components/createAll/custom-sdk/widget/pega-dxil-my-case-widget/pega-dxil-my-case-widget.component.ts +7 -7
- package/tests/assets/sdk-a/components/createAll/custom-sdk/widget/pega-dxil-my-page-case-widget/pega-dxil-my-page-case-widget.component.html +0 -2
- package/tests/assets/sdk-a/components/createAll/custom-sdk/widget/pega-dxil-my-page-case-widget/pega-dxil-my-page-case-widget.component.ts +7 -5
- package/tests/assets/sdk-a/components/createAll/custom-sdk/widget/pega-dxil-my-page-widget/demo.stories.tsx +27 -9
- package/tests/assets/sdk-a/components/createAll/custom-sdk/widget/pega-dxil-my-page-widget/mock.ts +25 -0
- package/tests/assets/sdk-a/components/createAll/custom-sdk/widget/pega-dxil-my-page-widget/pega-dxil-my-page-widget.component.html +11 -1
- package/tests/assets/sdk-a/components/createAll/custom-sdk/widget/pega-dxil-my-page-widget/pega-dxil-my-page-widget.component.ts +93 -1
- package/tests/assets/sdk-a/components/createAll/override-sdk/designSystemExtension/banner/banner.component.html +28 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/designSystemExtension/banner/banner.component.scss +64 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/designSystemExtension/banner/banner.component.spec.ts +22 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/designSystemExtension/banner/banner.component.ts +26 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/designSystemExtension/material-case-summary/material-case-summary.component.html +7 -4
- package/tests/assets/sdk-a/components/createAll/override-sdk/designSystemExtension/material-case-summary/material-case-summary.component.ts +3 -1
- package/tests/assets/sdk-a/components/createAll/override-sdk/designSystemExtension/material-vertical-tabs/material-vertical-tabs.component.html +1 -1
- package/tests/assets/sdk-a/components/createAll/override-sdk/designSystemExtension/operator/operator.component.ts +10 -5
- package/tests/assets/sdk-a/components/createAll/override-sdk/designSystemExtension/wss-quick-create/wss-quick-create.component.html +13 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/designSystemExtension/wss-quick-create/wss-quick-create.component.scss +43 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/designSystemExtension/wss-quick-create/wss-quick-create.component.spec.ts +22 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/designSystemExtension/wss-quick-create/wss-quick-create.component.ts +15 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/field/auto-complete/auto-complete.component.ts +1 -1
- package/tests/assets/sdk-a/components/createAll/override-sdk/field/cancel-alert/cancel-alert.component.ts +0 -2
- package/tests/assets/sdk-a/components/createAll/override-sdk/field/check-box/check-box.component.html +16 -15
- package/tests/assets/sdk-a/components/createAll/override-sdk/field/check-box/check-box.component.scss +14 -1
- package/tests/assets/sdk-a/components/createAll/override-sdk/field/check-box/check-box.component.ts +126 -44
- package/tests/assets/sdk-a/components/createAll/override-sdk/field/currency/currency.component.html +15 -6
- package/tests/assets/sdk-a/components/createAll/override-sdk/field/currency/currency.component.ts +36 -18
- package/tests/assets/sdk-a/components/createAll/override-sdk/field/date-time/date-time.component.html +5 -5
- package/tests/assets/sdk-a/components/createAll/override-sdk/field/date-time/date-time.component.ts +15 -37
- package/tests/assets/sdk-a/components/createAll/override-sdk/field/decimal/decimal.component.html +14 -4
- package/tests/assets/sdk-a/components/createAll/override-sdk/field/decimal/decimal.component.ts +42 -5
- package/tests/assets/sdk-a/components/createAll/override-sdk/field/dropdown/dropdown.component.ts +0 -3
- package/tests/assets/sdk-a/components/createAll/override-sdk/field/group/group.component.html +1 -1
- package/tests/assets/sdk-a/components/createAll/override-sdk/field/group/group.component.ts +4 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/field/percentage/percentage.component.html +15 -4
- package/tests/assets/sdk-a/components/createAll/override-sdk/field/percentage/percentage.component.ts +29 -5
- package/tests/assets/sdk-a/components/createAll/override-sdk/field/radio-buttons/radio-buttons.component.ts +0 -3
- package/tests/assets/sdk-a/components/createAll/override-sdk/field/rich-text/config-ext.json +11 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/field/rich-text/rich-text.component.html +1 -1
- package/tests/assets/sdk-a/components/createAll/override-sdk/field/scalar-list/scalar-list.component.ts +2 -1
- package/tests/assets/sdk-a/components/createAll/override-sdk/field/text-area/text-area.component.ts +0 -2
- package/tests/assets/sdk-a/components/createAll/override-sdk/field/time/time.component.html +1 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/field/time/time.component.ts +2 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/field/url/url.component.html +1 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/field/url/url.component.ts +2 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/field/user-reference/user-reference.component.html +50 -45
- package/tests/assets/sdk-a/components/createAll/override-sdk/field/user-reference/user-reference.component.ts +33 -15
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/assignment/assignment.component.ts +38 -39
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/dashboard-filter/dashboard-filter.component.html +35 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/dashboard-filter/dashboard-filter.component.scss +14 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/dashboard-filter/dashboard-filter.component.spec.ts +24 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/dashboard-filter/dashboard-filter.component.ts +89 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/defer-load/defer-load.component.ts +5 -8
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/flow-container/flow-container.component.html +44 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/flow-container/flow-container.component.scss +1 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/flow-container/flow-container.component.spec.ts +24 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/flow-container/flow-container.component.ts +634 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/flow-container/helpers.ts +79 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/hybrid-view-container/hybrid-view-container.component.html +1 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/hybrid-view-container/hybrid-view-container.component.scss +0 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/hybrid-view-container/hybrid-view-container.component.spec.ts +24 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/hybrid-view-container/hybrid-view-container.component.ts +24 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/modal-view-container/modal-view-container.component.html +35 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/modal-view-container/modal-view-container.component.scss +1 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/modal-view-container/modal-view-container.component.spec.ts +24 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/modal-view-container/modal-view-container.component.ts +426 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/multi-step/multi-step.component.html +1 -1
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/multi-step/multi-step.component.scss +1 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/navbar/navbar.component.html +4 -4
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/navbar/navbar.component.ts +6 -3
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/preview-view-container/preview-view-container.component.html +1 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/preview-view-container/preview-view-container.component.scss +0 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/preview-view-container/preview-view-container.component.spec.ts +24 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/preview-view-container/preview-view-container.component.ts +35 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/root-container/root-container.component.html +36 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/root-container/root-container.component.scss +18 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/root-container/root-container.component.spec.ts +24 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/root-container/root-container.component.ts +256 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/view/view.component.ts +1 -1
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/view-container/view-container.component.html +31 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/view-container/view-container.component.scss +1 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/view-container/view-container.component.spec.ts +24 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/infra/view-container/view-container.component.ts +288 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/template/banner-page/banner-page.component.html +12 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/template/banner-page/banner-page.component.scss +0 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/template/banner-page/banner-page.component.spec.ts +22 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/template/banner-page/banner-page.component.ts +65 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/template/banner-page/config-ext.json +10 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/template/case-summary/case-summary.component.ts +37 -3
- package/tests/assets/sdk-a/components/createAll/override-sdk/template/case-view/case-view.component.html +3 -3
- package/tests/assets/sdk-a/components/createAll/override-sdk/template/case-view/case-view.component.scss +2 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/template/case-view/case-view.component.ts +0 -6
- package/tests/assets/sdk-a/components/createAll/override-sdk/template/data-reference/data-reference.component.ts +1 -3
- package/tests/assets/sdk-a/components/createAll/override-sdk/template/dynamic-tabs/config-ext.json +37 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/template/dynamic-tabs/dynamic-tabs.component.html +5 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/template/dynamic-tabs/dynamic-tabs.component.scss +0 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/template/dynamic-tabs/dynamic-tabs.component.spec.ts +22 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/template/dynamic-tabs/dynamic-tabs.component.ts +77 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/template/field-group-template/field-group-template.component.ts +4 -12
- package/tests/assets/sdk-a/components/createAll/override-sdk/template/field-value-list/field-value-list.component.html +7 -2
- package/tests/assets/sdk-a/components/createAll/override-sdk/template/field-value-list/field-value-list.component.ts +1 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/template/inline-dashboard-page/config-ext.json +10 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/template/list-view/list-view.component.html +6 -6
- package/tests/assets/sdk-a/components/createAll/override-sdk/template/list-view/list-view.component.ts +36 -28
- package/tests/assets/sdk-a/components/createAll/override-sdk/template/list-view/listViewHelpers.ts +0 -1
- package/tests/assets/sdk-a/components/createAll/override-sdk/template/repeating-structures/repeating-structures.component.ts +1 -2
- package/tests/assets/sdk-a/components/createAll/override-sdk/template/simple-table/simple-table.component.ts +0 -2
- package/tests/assets/sdk-a/components/createAll/override-sdk/template/simple-table-manual/helpers.ts +1 -1
- package/tests/assets/sdk-a/components/createAll/override-sdk/template/simple-table-manual/simple-table-manual.component.html +1 -1
- package/tests/assets/sdk-a/components/createAll/override-sdk/template/simple-table-manual/simple-table-manual.component.ts +49 -19
- package/tests/assets/sdk-a/components/createAll/override-sdk/template/simple-table-select/simple-table-select.component.ts +2 -4
- package/tests/assets/sdk-a/components/createAll/override-sdk/template/wss-nav-bar/wss-nav-bar.component.html +32 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/template/wss-nav-bar/wss-nav-bar.component.scss +164 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/template/wss-nav-bar/wss-nav-bar.component.spec.ts +22 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/template/wss-nav-bar/wss-nav-bar.component.ts +173 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/widget/attachment/attachment.component.html +50 -26
- package/tests/assets/sdk-a/components/createAll/override-sdk/widget/attachment/attachment.component.scss +118 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/widget/attachment/attachment.component.ts +256 -501
- package/tests/assets/sdk-a/components/createAll/override-sdk/widget/case-history/case-history.component.ts +1 -2
- package/tests/assets/sdk-a/components/createAll/override-sdk/widget/feed-container/feed-container.component.ts +0 -4
- package/tests/assets/sdk-a/components/createAll/override-sdk/widget/file-utility/file-utility.component.html +2 -2
- package/tests/assets/sdk-a/components/createAll/override-sdk/widget/file-utility/file-utility.component.ts +13 -17
- package/tests/assets/sdk-a/components/createAll/override-sdk/widget/list-utility/list-utility.component.html +1 -1
- package/tests/assets/sdk-a/components/createAll/override-sdk/widget/quick-create/config-ext.json +10 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/widget/quick-create/quick-create.component.html +1 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/widget/quick-create/quick-create.component.scss +0 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/widget/quick-create/quick-create.component.spec.ts +22 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/widget/quick-create/quick-create.component.ts +96 -0
- package/tests/assets/sdk-a/components/createAll/override-sdk/widget/todo/todo.component.html +6 -5
- package/tests/assets/sdk-a/components/createAll/override-sdk/widget/todo/todo.component.ts +7 -6
- package/tests/assets/sdk-r/components/create/custom-constellation/field/Pega_DXIL_MyTestText/create-nonce.ts +5 -0
- package/tests/assets/sdk-r/components/create/custom-constellation/field/Pega_DXIL_MyTestText/index.tsx +1 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyBoolean/create-nonce.ts +5 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyBoolean/index.tsx +1 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyCurrency/create-nonce.ts +5 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyCurrency/index.tsx +1 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyDate/create-nonce.ts +5 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyDate/index.tsx +1 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyDateTime/create-nonce.ts +5 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyDateTime/index.tsx +1 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyDecimal/create-nonce.ts +5 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyDecimal/index.tsx +1 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyEmail/create-nonce.ts +5 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyEmail/index.tsx +1 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyIconButtonURL/create-nonce.ts +5 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyIconButtonURL/demo.stories.tsx +15 -10
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyIconButtonURL/index.tsx +1 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyInteger/create-nonce.ts +5 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyInteger/index.tsx +1 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyParagraph/create-nonce.ts +5 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyParagraph/index.tsx +1 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyPercentage/create-nonce.ts +5 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyPercentage/index.tsx +1 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyPhone/create-nonce.ts +5 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyPhone/index.tsx +1 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyPicklist/create-nonce.ts +5 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyPicklist/index.tsx +1 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyRadiobuttons/create-nonce.ts +5 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyRadiobuttons/index.tsx +1 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MySearchbox/create-nonce.ts +5 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MySearchbox/index.tsx +1 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyText/create-nonce.ts +5 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyText/index.tsx +1 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyTextInput/create-nonce.ts +5 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyTextInput/index.tsx +1 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyTimeOfDay/create-nonce.ts +5 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyTimeOfDay/index.tsx +1 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyURL/create-nonce.ts +5 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyURL/index.tsx +1 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/template/Pega_DXIL_MyDetails/create-nonce.ts +5 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/template/Pega_DXIL_MyDetails/index.tsx +1 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/template/Pega_DXIL_MyForm/create-nonce.ts +5 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/template/Pega_DXIL_MyForm/index.tsx +1 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/template/Pega_DXIL_MyPage/create-nonce.ts +5 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/template/Pega_DXIL_MyPage/index.tsx +1 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/template/Pega_DXIL_MyTwoColumnDetails/create-nonce.ts +5 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/template/Pega_DXIL_MyTwoColumnDetails/index.tsx +1 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/template/Pega_DXIL_MyTwoColumnForm/create-nonce.ts +5 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/template/Pega_DXIL_MyTwoColumnForm/index.tsx +1 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/widget/Pega_DXIL_MyCaseWidget/create-nonce.ts +5 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/widget/Pega_DXIL_MyCaseWidget/demo.stories.tsx +22 -22
- package/tests/assets/sdk-r/components/createAll/custom-constellation/widget/Pega_DXIL_MyCaseWidget/index.tsx +1 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/widget/Pega_DXIL_MyPageCaseWidget/create-nonce.ts +5 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/widget/Pega_DXIL_MyPageCaseWidget/index.tsx +1 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/widget/Pega_DXIL_MyPageWidget/create-nonce.ts +5 -0
- package/tests/assets/sdk-r/components/createAll/custom-constellation/widget/Pega_DXIL_MyPageWidget/demo.stories.tsx +15 -17
- package/tests/assets/sdk-r/components/createAll/custom-constellation/widget/Pega_DXIL_MyPageWidget/index.tsx +1 -0
- package/tests/assets/sdk-r/components/createAll/custom-sdk/field/Pega_DXIL_MyCurrency/config.json +166 -0
- package/tests/assets/sdk-r/components/createAll/custom-sdk/widget/Pega_DXIL_MyPageWidget/index.tsx +1 -1
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyBoolean/Boolean.js +0 -38
- package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MyDate/FormattedText.jsx +0 -41
- /package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MySearchbox/{component-constants.js → component-constants.ts} +0 -0
- /package/tests/assets/sdk-a/components/createAll/custom-constellation/field/Pega_DXIL_MySearchbox/{format-constants.js → format-constants.ts} +0 -0
|
@@ -1,7 +1,9 @@
|
|
|
1
|
-
import { Component, OnInit, Input, NgZone, forwardRef, OnDestroy } from '@angular/core';
|
|
1
|
+
import { Component, OnInit, Input, NgZone, forwardRef, OnDestroy, ViewChild, ElementRef } from '@angular/core';
|
|
2
2
|
import { FormGroup } from '@angular/forms';
|
|
3
3
|
import { CommonModule } from '@angular/common';
|
|
4
4
|
import { MatButtonModule } from '@angular/material/button';
|
|
5
|
+
import { MatMenuModule } from '@angular/material/menu';
|
|
6
|
+
import { MatIconModule } from '@angular/material/icon';
|
|
5
7
|
import { MatProgressSpinnerModule } from '@angular/material/progress-spinner';
|
|
6
8
|
import download from 'downloadjs';
|
|
7
9
|
import { AngularPConnectData, AngularPConnectService } from '@pega/angular-sdk-components';
|
|
@@ -21,7 +23,7 @@ interface AttachmentProps extends Omit<PConnFieldProps, 'value'> {
|
|
|
21
23
|
templateUrl: './attachment.component.html',
|
|
22
24
|
styleUrls: ['./attachment.component.scss'],
|
|
23
25
|
standalone: true,
|
|
24
|
-
imports: [CommonModule, MatProgressSpinnerModule, MatButtonModule, forwardRef(() => ComponentMapperComponent)]
|
|
26
|
+
imports: [CommonModule, MatProgressSpinnerModule, MatMenuModule, MatIconModule, MatButtonModule, forwardRef(() => ComponentMapperComponent)]
|
|
25
27
|
})
|
|
26
28
|
export class AttachmentComponent implements OnInit, OnDestroy {
|
|
27
29
|
@Input() pConn$: typeof PConnect;
|
|
@@ -29,6 +31,7 @@ export class AttachmentComponent implements OnInit, OnDestroy {
|
|
|
29
31
|
|
|
30
32
|
// For interaction with AngularPConnect
|
|
31
33
|
angularPConnectData: AngularPConnectData = {};
|
|
34
|
+
@ViewChild('uploader', { static: false }) fileInput: ElementRef;
|
|
32
35
|
|
|
33
36
|
label$ = '';
|
|
34
37
|
value$: any;
|
|
@@ -37,16 +40,8 @@ export class AttachmentComponent implements OnInit, OnDestroy {
|
|
|
37
40
|
bDisabled$ = false;
|
|
38
41
|
bVisible$ = true;
|
|
39
42
|
bLoading$ = false;
|
|
40
|
-
arFiles$: any[] = [];
|
|
41
|
-
arFileList$: any[] = [];
|
|
42
|
-
removeFileFromList$: any;
|
|
43
|
-
arMenuList$: any[] = [];
|
|
44
43
|
bShowSelector$ = true;
|
|
45
|
-
bShowJustDelete$ = false;
|
|
46
|
-
att_valueRef: any;
|
|
47
44
|
att_categoryName: string;
|
|
48
|
-
att_id: string;
|
|
49
|
-
myFiles: any;
|
|
50
45
|
fileTemp: any = {};
|
|
51
46
|
caseID: any;
|
|
52
47
|
allowMultiple$ = false;
|
|
@@ -55,7 +50,17 @@ export class AttachmentComponent implements OnInit, OnDestroy {
|
|
|
55
50
|
validateMessage: string | undefined = '';
|
|
56
51
|
valueRef: string;
|
|
57
52
|
imagePath$: string;
|
|
58
|
-
|
|
53
|
+
localizedVal = PCore.getLocaleUtils().getLocaleValue;
|
|
54
|
+
localeCategory = 'CosmosFields';
|
|
55
|
+
uploadMultipleFilesLabel = this.localizedVal('file_upload_text_multiple', this.localeCategory);
|
|
56
|
+
uploadSingleFileLabel = this.localizedVal('file_upload_text_one', this.localeCategory);
|
|
57
|
+
filesWithError: any = [];
|
|
58
|
+
files: any = [];
|
|
59
|
+
categoryName: string;
|
|
60
|
+
displayMode: string | undefined;
|
|
61
|
+
srcImg: any;
|
|
62
|
+
deleteIcon: string;
|
|
63
|
+
tempFilesToBeUploaded: any[];
|
|
59
64
|
constructor(
|
|
60
65
|
private angularPConnect: AngularPConnectService,
|
|
61
66
|
private utils: Utils,
|
|
@@ -65,13 +70,36 @@ export class AttachmentComponent implements OnInit, OnDestroy {
|
|
|
65
70
|
ngOnInit(): void {
|
|
66
71
|
// // First thing in initialization is registering and subscribing to the AngularPConnect service
|
|
67
72
|
this.angularPConnectData = this.angularPConnect.registerAndSubscribeComponent(this, this.onStateChange);
|
|
68
|
-
|
|
69
|
-
this.removeFileFromList$ = { onClick: this._removeFileFromList.bind(this) };
|
|
70
|
-
|
|
71
73
|
this.caseID = PCore.getStoreValue('.pyID', 'caseInfo.content', this.pConn$.getContextName());
|
|
72
|
-
|
|
73
|
-
|
|
74
|
+
this.srcImg = this.utils.getImageSrc('document-doc', this.utils.getSDKStaticContentUrl());
|
|
75
|
+
this.deleteIcon = this.utils.getImageSrc('trash', this.utils.getSDKStaticContentUrl());
|
|
74
76
|
this.checkAndUpdate();
|
|
77
|
+
this.getAttachments();
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
getAttachments() {
|
|
81
|
+
let tempUploadedFiles = this.getCurrentAttachmentsList(this.getAttachmentKey(this.valueRef), this.pConn$.getContextName());
|
|
82
|
+
tempUploadedFiles = tempUploadedFiles.filter(f => f.label === this.valueRef && f.delete !== true);
|
|
83
|
+
this.files?.map(f => {
|
|
84
|
+
return f.responseProps?.pzInsKey && !f.responseProps.pzInsKey.includes('temp')
|
|
85
|
+
? {
|
|
86
|
+
...f,
|
|
87
|
+
props: {
|
|
88
|
+
...f.props,
|
|
89
|
+
onDelete: () => this.deleteFile(f)
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
: { ...f };
|
|
93
|
+
});
|
|
94
|
+
this.files = [...this.files, ...tempUploadedFiles];
|
|
95
|
+
PCore.getPubSubUtils().subscribe(
|
|
96
|
+
PCore.getConstants().PUB_SUB_EVENTS.CASE_EVENTS.ASSIGNMENT_SUBMISSION,
|
|
97
|
+
this.resetAttachmentStoredState.bind(this),
|
|
98
|
+
this.caseID
|
|
99
|
+
);
|
|
100
|
+
return () => {
|
|
101
|
+
PCore.getPubSubUtils().unsubscribe(PCore.getConstants().PUB_SUB_EVENTS.CASE_EVENTS.ASSIGNMENT_SUBMISSION, this.caseID);
|
|
102
|
+
};
|
|
75
103
|
}
|
|
76
104
|
|
|
77
105
|
checkAndUpdate() {
|
|
@@ -85,77 +113,15 @@ export class AttachmentComponent implements OnInit, OnDestroy {
|
|
|
85
113
|
}
|
|
86
114
|
}
|
|
87
115
|
|
|
88
|
-
ngOnDestroy(): void {
|
|
89
|
-
if (this.angularPConnectData.unsubscribeFn) {
|
|
90
|
-
this.angularPConnectData.unsubscribeFn();
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
PCore.getPubSubUtils().unsubscribe(PCore.getConstants().PUB_SUB_EVENTS.CASE_EVENTS.ASSIGNMENT_SUBMISSION, this.caseID);
|
|
94
|
-
}
|
|
95
|
-
|
|
96
116
|
// Callback passed when subscribing to store change
|
|
97
117
|
onStateChange() {
|
|
98
118
|
this.checkAndUpdate();
|
|
99
119
|
}
|
|
100
120
|
|
|
101
|
-
updateAttachmentsInfo() {
|
|
102
|
-
// @ts-ignore - Property 'attachmentsInfo' does not exist on type 'C11nEnv'
|
|
103
|
-
if (!this.pConn$.attachmentsInfo) {
|
|
104
|
-
// @ts-ignore - Property 'attachmentsInfo' does not exist on type 'C11nEnv'
|
|
105
|
-
this.pConn$.attachmentsInfo = {
|
|
106
|
-
type: 'File',
|
|
107
|
-
attachmentFieldName: this.att_valueRef,
|
|
108
|
-
category: this.att_categoryName
|
|
109
|
-
};
|
|
110
|
-
}
|
|
111
|
-
}
|
|
112
|
-
|
|
113
|
-
processFile(file, i) {
|
|
114
|
-
file.props.type = file.responseProps.pyMimeFileExtension;
|
|
115
|
-
file.props.mimeType = file.responseProps.pyMimeFileExtension;
|
|
116
|
-
file.props.ID = file.responseProps.pzInsKey;
|
|
117
|
-
|
|
118
|
-
const arMenuList = [
|
|
119
|
-
{
|
|
120
|
-
icon: 'download',
|
|
121
|
-
text: this.pConn$.getLocalizedValue('Download', '', ''),
|
|
122
|
-
onClick: () => this._downloadFileFromList(this.value$.pxResults[i])
|
|
123
|
-
},
|
|
124
|
-
{
|
|
125
|
-
icon: 'trash',
|
|
126
|
-
text: this.pConn$.getLocalizedValue('Delete', '', ''),
|
|
127
|
-
onClick: () => this._removeFileFromList(this.arFileList$[i])
|
|
128
|
-
}
|
|
129
|
-
];
|
|
130
|
-
|
|
131
|
-
const arFilesAttachmentIDs: any = [];
|
|
132
|
-
this.arFileList$.forEach(arFile => {
|
|
133
|
-
arFilesAttachmentIDs.push(arFile.id);
|
|
134
|
-
});
|
|
135
|
-
|
|
136
|
-
if (!arFilesAttachmentIDs.includes(file.props.ID)) {
|
|
137
|
-
this.arFileList$.push(
|
|
138
|
-
this.getNewListUtilityItemProps({
|
|
139
|
-
att: file.props,
|
|
140
|
-
downloadFile: null,
|
|
141
|
-
cancelFile: null,
|
|
142
|
-
deleteFile: null,
|
|
143
|
-
removeFile: null
|
|
144
|
-
})
|
|
145
|
-
);
|
|
146
|
-
}
|
|
147
|
-
|
|
148
|
-
this.arFileList$[i].actions = arMenuList;
|
|
149
|
-
this.arFileList$[i].noDeleteIcon = true;
|
|
150
|
-
|
|
151
|
-
this.bShowSelector$ = false;
|
|
152
|
-
}
|
|
153
|
-
|
|
154
121
|
updateSelf() {
|
|
155
122
|
const configProps: AttachmentProps = this.pConn$.resolveConfigProps(this.pConn$.getConfigProps()) as AttachmentProps;
|
|
156
123
|
const stateProps: any = this.pConn$.getStateProps();
|
|
157
|
-
|
|
158
|
-
const { value, label, extensions } = configProps;
|
|
124
|
+
const { value, label, extensions, displayMode } = configProps;
|
|
159
125
|
|
|
160
126
|
if (configProps.required != null) {
|
|
161
127
|
this.bRequired$ = this.utils.getBooleanValue(configProps.required);
|
|
@@ -177,114 +143,62 @@ export class AttachmentComponent implements OnInit, OnDestroy {
|
|
|
177
143
|
this.allowMultiple$ = this.utils.getBooleanValue(configProps.allowMultiple);
|
|
178
144
|
}
|
|
179
145
|
|
|
180
|
-
this.bShowJustDelete$ = true;
|
|
181
146
|
this.label$ = label;
|
|
182
147
|
this.value$ = value;
|
|
183
148
|
this.status = stateProps.status;
|
|
149
|
+
|
|
184
150
|
this.validateMessage = this.angularPConnectData.validateMessage;
|
|
185
151
|
this.extensions$ = extensions;
|
|
186
152
|
this.valueRef = (this.pConn$.getStateProps() as any).value;
|
|
187
153
|
this.valueRef = this.valueRef.startsWith('.') ? this.valueRef.substring(1) : this.valueRef;
|
|
188
|
-
|
|
154
|
+
this.displayMode = displayMode;
|
|
189
155
|
/* this is a temporary fix because required is supposed to be passed as a boolean and NOT as a string */
|
|
190
156
|
let { required, disabled } = configProps;
|
|
191
157
|
[required, disabled] = [required, disabled].map(prop => prop === true || (typeof prop === 'string' && prop === 'true'));
|
|
192
158
|
|
|
193
|
-
this.
|
|
159
|
+
this.categoryName = '';
|
|
194
160
|
if (value && value.pyCategoryName) {
|
|
195
|
-
this.
|
|
161
|
+
this.categoryName = value.pyCategoryName;
|
|
196
162
|
}
|
|
197
163
|
|
|
198
|
-
|
|
199
|
-
|
|
164
|
+
if (value?.pxResults && +value.pyCount > 0) {
|
|
165
|
+
this.files = value.pxResults.map(f => this.buildFilePropsFromResponse(f));
|
|
166
|
+
}
|
|
200
167
|
|
|
201
168
|
this.updateAttachments();
|
|
202
169
|
}
|
|
203
170
|
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
if (this.myFiles?.length && this.arFiles$.length === 0) {
|
|
214
|
-
this.arFileList$ = this.myFiles.map(att => {
|
|
215
|
-
return this.getNewListUtilityItemProps({
|
|
216
|
-
att,
|
|
217
|
-
downloadFile: null,
|
|
218
|
-
cancelFile: null,
|
|
219
|
-
deleteFile: null,
|
|
220
|
-
removeFile: null
|
|
221
|
-
});
|
|
222
|
-
});
|
|
171
|
+
buildFilePropsFromResponse(respObj) {
|
|
172
|
+
return {
|
|
173
|
+
props: {
|
|
174
|
+
meta: `${respObj.pyCategoryName}, ${respObj.pxCreateOperator}`,
|
|
175
|
+
name: respObj.pyAttachName,
|
|
176
|
+
icon: this.utils.getIconFromFileType(respObj.pyMimeFileExtension)
|
|
177
|
+
},
|
|
178
|
+
responseProps: {
|
|
179
|
+
...respObj
|
|
223
180
|
}
|
|
224
|
-
|
|
225
|
-
const myFilesAttachmentIDs: any = [];
|
|
226
|
-
this.myFiles.forEach(myFile => {
|
|
227
|
-
myFilesAttachmentIDs.push(myFile.ID);
|
|
228
|
-
});
|
|
229
|
-
|
|
230
|
-
this.arFiles$.forEach(arFile => {
|
|
231
|
-
if (!myFilesAttachmentIDs.includes(arFile.ID)) {
|
|
232
|
-
this.myFiles = [...this.myFiles, arFile];
|
|
233
|
-
}
|
|
234
|
-
});
|
|
235
|
-
}
|
|
236
|
-
|
|
237
|
-
this.bShowJustDelete$ = true;
|
|
238
|
-
this.bShowSelector$ = !(this.arFileList$?.length > 0) || this.allowMultiple$;
|
|
239
|
-
|
|
240
|
-
if (this.arFileList$.length > 0) {
|
|
241
|
-
this.CheckForInvalidAttachment();
|
|
242
|
-
}
|
|
243
|
-
PCore.getPubSubUtils().subscribe(
|
|
244
|
-
PCore.getConstants().PUB_SUB_EVENTS.CASE_EVENTS.ASSIGNMENT_SUBMISSION,
|
|
245
|
-
this.resetAttachmentStoredState.bind(this),
|
|
246
|
-
this.caseID
|
|
247
|
-
);
|
|
181
|
+
};
|
|
248
182
|
}
|
|
249
183
|
|
|
250
|
-
|
|
251
|
-
this.
|
|
252
|
-
const
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
if (file) {
|
|
259
|
-
const currentAttachmentList = this.getCurrentAttachmentsList(this.getAttachmentKey(this.att_valueRef), this.pConn$.getContextName());
|
|
260
|
-
const index = currentAttachmentList.findIndex(element => element.props.ID === file.props.ID);
|
|
261
|
-
let tempFiles: any = [];
|
|
262
|
-
if (index < 0) {
|
|
263
|
-
tempFiles = [file];
|
|
264
|
-
}
|
|
265
|
-
|
|
266
|
-
PCore.getStateUtils().updateState(
|
|
267
|
-
this.pConn$.getContextName(),
|
|
268
|
-
this.getAttachmentKey(this.att_valueRef),
|
|
269
|
-
[...currentAttachmentList, ...tempFiles],
|
|
270
|
-
{
|
|
271
|
-
pageReference: 'context_data',
|
|
272
|
-
isArrayDeepMerge: false
|
|
273
|
-
}
|
|
274
|
-
);
|
|
275
|
-
}
|
|
276
|
-
}
|
|
277
|
-
});
|
|
184
|
+
updateAttachments() {
|
|
185
|
+
if (this.files.length > 0 && this.displayMode !== 'DISPLAY_ONLY') {
|
|
186
|
+
const currentAttachmentList = this.getCurrentAttachmentsList(this.getAttachmentKey(this.valueRef), this.pConn$.getContextName());
|
|
187
|
+
// block duplicate files to redux store when added 1 after another to prevent multiple duplicates being added to the case on submit
|
|
188
|
+
const tempFiles = this.files.filter(f => currentAttachmentList.findIndex(fr => fr.ID === f.ID) === -1 && !f.inProgress && f.responseProps);
|
|
189
|
+
const updatedAttList = [...currentAttachmentList, ...tempFiles];
|
|
190
|
+
this.updateAttachmentState(this.pConn$, this.getAttachmentKey(this.valueRef), updatedAttList);
|
|
191
|
+
}
|
|
278
192
|
}
|
|
279
193
|
|
|
280
194
|
resetAttachmentStoredState() {
|
|
281
|
-
PCore.getStateUtils().updateState(this.pConn
|
|
195
|
+
PCore.getStateUtils().updateState(this.pConn$?.getContextName(), this.getAttachmentKey(this.valueRef), undefined, {
|
|
282
196
|
pageReference: 'context_data',
|
|
283
197
|
isArrayDeepMerge: false
|
|
284
198
|
});
|
|
285
199
|
}
|
|
286
200
|
|
|
287
|
-
|
|
201
|
+
downloadFile(fileObj: any) {
|
|
288
202
|
PCore.getAttachmentUtils()
|
|
289
203
|
// @ts-ignore - 3rd parameter "responseEncoding" should be optional
|
|
290
204
|
.downloadAttachment(fileObj.pzInsKey, this.pConn$.getContextName())
|
|
@@ -304,146 +218,198 @@ export class AttachmentComponent implements OnInit, OnDestroy {
|
|
|
304
218
|
|
|
305
219
|
getAttachmentKey = (name = '') => (name ? `attachmentsList.${name}` : 'attachmentsList');
|
|
306
220
|
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
this.arFileList$.forEach(file => {
|
|
310
|
-
if (file.secondary.error) {
|
|
311
|
-
isValid = false;
|
|
312
|
-
}
|
|
313
|
-
});
|
|
314
|
-
if (isValid) {
|
|
315
|
-
// @ts-ignore
|
|
316
|
-
PCore.getMessageManager().clearMessages({
|
|
317
|
-
type: PCore.getConstants().MESSAGES.MESSAGES_TYPE_ERROR,
|
|
318
|
-
property: (this.pConn$.getStateProps() as any).value,
|
|
319
|
-
pageReference: this.pConn$.getPageReference(),
|
|
320
|
-
context: this.pConn$.getContextName()
|
|
321
|
-
});
|
|
322
|
-
}
|
|
221
|
+
getCurrentAttachmentsList(key, context) {
|
|
222
|
+
return PCore.getStoreValue(`.${key}`, 'context_data', context) || [];
|
|
323
223
|
}
|
|
324
224
|
|
|
325
|
-
|
|
326
|
-
const
|
|
327
|
-
|
|
225
|
+
validateMaxSize(fileObj, maxSizeInMB): boolean {
|
|
226
|
+
const fileSize = (fileObj.size / 1048576).toFixed(2);
|
|
227
|
+
return parseFloat(fileSize) < parseFloat(maxSizeInMB);
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
validateFileExtension = (fileObj, allowedExtensions) => {
|
|
231
|
+
if (!allowedExtensions) {
|
|
232
|
+
return true;
|
|
233
|
+
}
|
|
234
|
+
const allowedExtensionList = allowedExtensions
|
|
235
|
+
.toLowerCase()
|
|
236
|
+
.split(',')
|
|
237
|
+
.map(item => item.replaceAll('.', '').trim());
|
|
238
|
+
const extension = fileObj.name.split('.').pop().toLowerCase();
|
|
239
|
+
return allowedExtensionList.includes(extension);
|
|
240
|
+
};
|
|
241
|
+
|
|
242
|
+
updateAttachmentState(pConn, key, attachments) {
|
|
243
|
+
PCore.getStateUtils().updateState(this.pConn$.getContextName(), key, attachments, {
|
|
244
|
+
pageReference: 'context_data',
|
|
245
|
+
isArrayDeepMerge: false
|
|
246
|
+
});
|
|
247
|
+
}
|
|
328
248
|
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
249
|
+
deleteFile(file) {
|
|
250
|
+
const attachmentsList: any[] = [];
|
|
251
|
+
let currentAttachmentList = this.getCurrentAttachmentsList(this.getAttachmentKey(this.valueRef), this.pConn$.getContextName());
|
|
252
|
+
|
|
253
|
+
// If file to be deleted is the one added in previous stage i.e. for which a file instance is created in server
|
|
254
|
+
// no need to filter currentAttachmentList as we will get another entry of file in redux with delete & label
|
|
255
|
+
// eslint-disable-next-line no-unsafe-optional-chaining
|
|
256
|
+
if (this.value$ && this.value$?.pxResults && +this.value$?.pyCount > 0 && file.responseProps && file?.responseProps?.pzInsKey !== 'temp') {
|
|
257
|
+
const updatedAttachments = this.files.map(f => {
|
|
258
|
+
if (f.responseProps && f.responseProps.pzInsKey === file.responseProps.pzInsKey) {
|
|
259
|
+
return { ...f, delete: true, label: this.valueRef };
|
|
335
260
|
}
|
|
336
|
-
return
|
|
261
|
+
return f;
|
|
337
262
|
});
|
|
338
263
|
|
|
339
264
|
// updating the redux store to help form-handler in passing the data to delete the file from server
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
} else {
|
|
345
|
-
currentAttachmentList = currentAttachmentList.filter(f => f.ID !== item.id);
|
|
346
|
-
PCore.getStateUtils().updateState(
|
|
347
|
-
this.pConn$.getContextName(),
|
|
348
|
-
this.getAttachmentKey(this.att_valueRef),
|
|
349
|
-
[...currentAttachmentList, ...attachmentsList],
|
|
350
|
-
{
|
|
351
|
-
pageReference: 'context_data',
|
|
352
|
-
isArrayDeepMerge: false
|
|
353
|
-
}
|
|
265
|
+
this.updateAttachmentState(this.pConn$, this.getAttachmentKey(this.valueRef), [...updatedAttachments]);
|
|
266
|
+
const newlyAddedFiles = this.files.filter(f => !!f.ID);
|
|
267
|
+
const filesPostDelete = this.files.filter(
|
|
268
|
+
f => f.responseProps?.pzInsKey !== 'temp' && f.responseProps?.pzInsKey !== file.responseProps?.pzInsKey
|
|
354
269
|
);
|
|
270
|
+
this.files = [...filesPostDelete, ...newlyAddedFiles];
|
|
271
|
+
} // if the file being deleted is the added in this stage i.e. whose data is not yet created in server
|
|
272
|
+
else {
|
|
273
|
+
// filter newly added files in this stage, later the updated current stage files will be added to redux once files state is updated
|
|
274
|
+
currentAttachmentList = currentAttachmentList.filter(f => f.ID !== file.ID);
|
|
275
|
+
this.files = this.files.filter(f => f.ID !== file.ID);
|
|
276
|
+
|
|
277
|
+
this.updateAttachmentState(this.pConn$, this.getAttachmentKey(this.valueRef), [...currentAttachmentList, ...attachmentsList]);
|
|
278
|
+
if (file.inProgress) {
|
|
279
|
+
// @ts-ignore - 3rd parameter "responseEncoding" should be optional
|
|
280
|
+
PCore.getAttachmentUtils().cancelRequest(file.ID, pConn.getContextName());
|
|
281
|
+
}
|
|
355
282
|
}
|
|
356
283
|
|
|
357
|
-
|
|
358
|
-
|
|
284
|
+
this.filesWithError = this.filesWithError?.filter(f => f.ID !== file.ID);
|
|
285
|
+
if (this.filesWithError.length === 0) {
|
|
286
|
+
this.clearFieldErrorMessages();
|
|
359
287
|
}
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
this.CheckForInvalidAttachment();
|
|
288
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-expressions
|
|
289
|
+
this.fileInput && this.fileInput.nativeElement.value ? null : '';
|
|
290
|
+
}
|
|
365
291
|
|
|
366
|
-
|
|
292
|
+
onFileAdded(event) {
|
|
293
|
+
let addedFiles = Array.from(event.target.files);
|
|
294
|
+
addedFiles = this.allowMultiple$ ? addedFiles : [addedFiles[0]];
|
|
295
|
+
const maxAttachmentSize = PCore.getEnvironmentInfo().getMaxAttachmentSize() || '5';
|
|
296
|
+
this.tempFilesToBeUploaded = [
|
|
297
|
+
...addedFiles.map((f: any, index) => {
|
|
298
|
+
f.ID = `${new Date().getTime()}I${index}`;
|
|
299
|
+
f.inProgress = true;
|
|
300
|
+
f.props = {
|
|
301
|
+
type: f.type,
|
|
302
|
+
name: f.name,
|
|
303
|
+
icon: this.utils.getIconFromFileType(f.type),
|
|
304
|
+
onDelete: () => this.deleteFile(f)
|
|
305
|
+
};
|
|
306
|
+
if (!this.validateMaxSize(f, maxAttachmentSize)) {
|
|
307
|
+
f.props.error = true;
|
|
308
|
+
f.inProgress = false;
|
|
309
|
+
f.props.meta = this.pConn$.getLocalizedValue(`File is too big. Max allowed size is ${maxAttachmentSize}MB.`, '', '');
|
|
310
|
+
} else if (!this.validateFileExtension(f, this.extensions$)) {
|
|
311
|
+
f.props.error = true;
|
|
312
|
+
f.inProgress = false;
|
|
313
|
+
f.props.meta = `${this.pConn$.getLocalizedValue(
|
|
314
|
+
'File has invalid extension. Allowed extensions are:',
|
|
315
|
+
'',
|
|
316
|
+
''
|
|
317
|
+
)} ${this.extensions$.replaceAll('.', '')}`;
|
|
318
|
+
}
|
|
319
|
+
if (f.props.error) {
|
|
320
|
+
const fieldName = (this.pConn$.getStateProps() as any).value;
|
|
321
|
+
const context = this.pConn$.getContextName();
|
|
322
|
+
PCore.getMessageManager().addMessages({
|
|
323
|
+
messages: [
|
|
324
|
+
{
|
|
325
|
+
type: 'error',
|
|
326
|
+
// @ts-ignore - Type '{ type: string; message: string; }' is not assignable to type 'MessagesConfigObject'.
|
|
327
|
+
message: pConn.getLocalizedValue('Error with one or more files', '', '')
|
|
328
|
+
}
|
|
329
|
+
],
|
|
330
|
+
property: fieldName,
|
|
331
|
+
pageReference: this.pConn$.getPageReference(),
|
|
332
|
+
context
|
|
333
|
+
});
|
|
334
|
+
}
|
|
335
|
+
return f;
|
|
336
|
+
})
|
|
337
|
+
];
|
|
338
|
+
const tempFilesWithError = this.tempFilesToBeUploaded.filter(f => f.props.error);
|
|
339
|
+
if (tempFilesWithError.length > 0) {
|
|
340
|
+
this.filesWithError = tempFilesWithError;
|
|
341
|
+
}
|
|
342
|
+
if (!this.allowMultiple$) {
|
|
343
|
+
this.files = [...this.tempFilesToBeUploaded];
|
|
344
|
+
} else {
|
|
345
|
+
this.files = [...this.files, ...this.tempFilesToBeUploaded];
|
|
346
|
+
}
|
|
347
|
+
this.uploadFiles();
|
|
367
348
|
}
|
|
368
349
|
|
|
369
|
-
|
|
370
|
-
|
|
350
|
+
clearFieldErrorMessages() {
|
|
351
|
+
const fieldName = (this.pConn$.getStateProps() as any).value;
|
|
352
|
+
const context = this.pConn$.getContextName();
|
|
353
|
+
PCore.getMessageManager().clearMessages({
|
|
354
|
+
type: PCore.getConstants().MESSAGES.MESSAGES_TYPE_ERROR,
|
|
355
|
+
property: fieldName,
|
|
356
|
+
pageReference: this.pConn$.getPageReference(),
|
|
357
|
+
context
|
|
358
|
+
});
|
|
371
359
|
}
|
|
372
360
|
|
|
373
|
-
|
|
361
|
+
onUploadProgress() {}
|
|
362
|
+
|
|
363
|
+
errorHandler(isFetchCanceled, attachedFile) {
|
|
374
364
|
return error => {
|
|
375
365
|
if (!isFetchCanceled(error)) {
|
|
376
366
|
let uploadFailMsg = this.pConn$.getLocalizedValue('Something went wrong', '', '');
|
|
377
367
|
if (error.response && error.response.data && error.response.data.errorDetails) {
|
|
378
368
|
uploadFailMsg = this.pConn$.getLocalizedValue(error.response.data.errorDetails[0].localizedValue, '', '');
|
|
379
369
|
}
|
|
380
|
-
for (const myFile of this.myFiles) {
|
|
381
|
-
if (myFile.ID === file.ID) {
|
|
382
|
-
myFile.meta = uploadFailMsg;
|
|
383
|
-
myFile.error = true;
|
|
384
|
-
myFile.fileName = this.pConn$.getLocalizedValue('Unable to upload file', '', '');
|
|
385
|
-
}
|
|
386
|
-
}
|
|
387
|
-
this.bShowSelector$ = false;
|
|
388
|
-
this.arFileList$ = this.myFiles.map(att => {
|
|
389
|
-
if (att.id) {
|
|
390
|
-
return att;
|
|
391
|
-
}
|
|
392
|
-
return this.getNewListUtilityItemProps({
|
|
393
|
-
att,
|
|
394
|
-
downloadFile: null,
|
|
395
|
-
cancelFile: null,
|
|
396
|
-
deleteFile: null,
|
|
397
|
-
removeFile: null
|
|
398
|
-
});
|
|
399
|
-
});
|
|
400
370
|
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
371
|
+
this.files.map(f => {
|
|
372
|
+
if (f.ID === attachedFile.ID) {
|
|
373
|
+
f.props.meta = uploadFailMsg;
|
|
374
|
+
f.props.error = true;
|
|
375
|
+
f.props.onDelete = () => this.deleteFile(f);
|
|
376
|
+
f.props.icon = this.utils.getIconFromFileType(f.type);
|
|
377
|
+
f.props.name = this.pConn$.getLocalizedValue('Unable to upload file', '', '');
|
|
378
|
+
f.inProgress = false;
|
|
379
|
+
const fieldName = (this.pConn$.getStateProps() as any).value;
|
|
380
|
+
const context = this.pConn$.getContextName();
|
|
381
|
+
// set errors to property to block submit even on errors in file upload
|
|
382
|
+
PCore.getMessageManager().addMessages({
|
|
383
|
+
messages: [
|
|
384
|
+
{
|
|
385
|
+
type: 'error',
|
|
386
|
+
// @ts-ignore - Type '{ type: string; message: string; }' is not assignable to type 'MessagesConfigObject'.
|
|
387
|
+
message: this.pConn$.getLocalizedValue('Error with one or more files', '', '')
|
|
388
|
+
}
|
|
389
|
+
],
|
|
390
|
+
property: fieldName,
|
|
391
|
+
pageReference: this.pConn$.getPageReference(),
|
|
392
|
+
context
|
|
393
|
+
});
|
|
394
|
+
delete f.props.progress;
|
|
395
|
+
}
|
|
396
|
+
return f;
|
|
412
397
|
});
|
|
413
|
-
|
|
414
|
-
this.bShowJustDelete$ = true;
|
|
415
|
-
this.bLoading$ = false;
|
|
416
398
|
}
|
|
417
399
|
throw error;
|
|
418
400
|
};
|
|
419
401
|
}
|
|
420
402
|
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
if (this.arFiles$.length) {
|
|
424
|
-
arrAttachmentFiles = this.arFiles$;
|
|
425
|
-
} else {
|
|
426
|
-
arrAttachmentFiles = this.arFileList$;
|
|
427
|
-
}
|
|
428
|
-
this.arFiles$ = [...arrAttachmentFiles, ...this.getFiles(event.target.files)];
|
|
429
|
-
|
|
430
|
-
// convert FileList to an array
|
|
431
|
-
this.myFiles = Array.from(this.arFiles$);
|
|
432
|
-
|
|
433
|
-
this.bLoading$ = true;
|
|
434
|
-
|
|
435
|
-
const filesToBeUploaded = this.myFiles
|
|
403
|
+
uploadFiles() {
|
|
404
|
+
const filesToBeUploaded = this.files
|
|
436
405
|
.filter(e => {
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
}
|
|
440
|
-
const isFileUploaded = e && e.progress === 100;
|
|
441
|
-
const fileHasError = e && e.error;
|
|
406
|
+
const isFileUploaded = e.props && e.props.progress === 100;
|
|
407
|
+
const fileHasError = e.props && e.props.error;
|
|
442
408
|
const isFileUploadedinLastStep = e.responseProps && e.responseProps.pzInsKey;
|
|
443
409
|
return !isFileUploaded && !fileHasError && !isFileUploadedinLastStep;
|
|
444
410
|
})
|
|
445
411
|
.map(f =>
|
|
446
|
-
PCore.getAttachmentUtils().uploadAttachment(
|
|
412
|
+
window.PCore.getAttachmentUtils().uploadAttachment(
|
|
447
413
|
f,
|
|
448
414
|
() => {
|
|
449
415
|
this.onUploadProgress();
|
|
@@ -454,252 +420,41 @@ export class AttachmentComponent implements OnInit, OnDestroy {
|
|
|
454
420
|
this.pConn$.getContextName()
|
|
455
421
|
)
|
|
456
422
|
);
|
|
457
|
-
|
|
458
423
|
Promise.allSettled(filesToBeUploaded)
|
|
459
424
|
.then((fileResponses: any) => {
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
if (index >= 0) {
|
|
477
|
-
reqObj = {
|
|
478
|
-
type: 'File',
|
|
479
|
-
label: this.att_valueRef,
|
|
480
|
-
category: this.att_categoryName,
|
|
481
|
-
handle: successFileResponses[index].value.ID,
|
|
482
|
-
ID: fileRes.ID,
|
|
483
|
-
name: fileRes.name
|
|
484
|
-
};
|
|
485
|
-
newAttachments = [...newAttachments, reqObj];
|
|
486
|
-
}
|
|
487
|
-
});
|
|
488
|
-
const currentAttachmentList = this.getCurrentAttachmentsList(this.getAttachmentKey(this.att_valueRef), this.pConn$.getContextName()).filter(
|
|
489
|
-
f => f.label !== this.att_valueRef
|
|
490
|
-
);
|
|
491
|
-
PCore.getStateUtils().updateState(
|
|
492
|
-
this.pConn$.getContextName(),
|
|
493
|
-
this.getAttachmentKey(this.att_valueRef),
|
|
494
|
-
[...currentAttachmentList, ...newAttachments],
|
|
495
|
-
{
|
|
496
|
-
pageReference: 'context_data',
|
|
497
|
-
isArrayDeepMerge: false
|
|
498
|
-
}
|
|
499
|
-
);
|
|
500
|
-
this.arFiles$ = tempFilesUploaded;
|
|
501
|
-
|
|
502
|
-
this.ngZone.run(() => {
|
|
503
|
-
this.bShowSelector$ = this.allowMultiple$;
|
|
504
|
-
this.arFiles$.forEach(file => {
|
|
505
|
-
if (!file.error) {
|
|
506
|
-
file.meta = this.pConn$.getLocalizedValue('File uploaded successfully', '', '');
|
|
507
|
-
}
|
|
508
|
-
});
|
|
509
|
-
this.arFileList$ = this.myFiles.map(att => {
|
|
510
|
-
if (att.id) {
|
|
511
|
-
return att;
|
|
512
|
-
}
|
|
513
|
-
return this.getNewListUtilityItemProps({
|
|
514
|
-
att,
|
|
515
|
-
downloadFile: null,
|
|
516
|
-
cancelFile: null,
|
|
517
|
-
deleteFile: null,
|
|
518
|
-
removeFile: null
|
|
425
|
+
fileResponses = fileResponses.filter(fr => fr.status !== 'rejected'); // in case of deleting an in progress file, promise gets cancelled but still enters then block
|
|
426
|
+
if (fileResponses.length > 0) {
|
|
427
|
+
this.files.forEach(f => {
|
|
428
|
+
const index = fileResponses.findIndex((fr: any) => fr.value.clientFileID === f.ID);
|
|
429
|
+
if (index >= 0) {
|
|
430
|
+
f.props.meta = this.pConn$.getLocalizedValue('Uploaded successfully', '', '');
|
|
431
|
+
f.props.progress = 100;
|
|
432
|
+
f.inProgress = false;
|
|
433
|
+
f.handle = fileResponses[index].value.ID;
|
|
434
|
+
f.label = this.valueRef;
|
|
435
|
+
f.category = this.categoryName;
|
|
436
|
+
f.responseProps = {
|
|
437
|
+
pzInsKey: 'temp',
|
|
438
|
+
pyAttachName: f.props.name
|
|
439
|
+
};
|
|
440
|
+
}
|
|
519
441
|
});
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
this.bShowJustDelete$ = true;
|
|
525
|
-
this.bLoading$ = false;
|
|
526
|
-
});
|
|
527
|
-
}
|
|
528
|
-
}
|
|
529
|
-
|
|
530
|
-
handleFileUploadFailure() {
|
|
531
|
-
this.bShowJustDelete$ = true;
|
|
532
|
-
this.bLoading$ = false;
|
|
533
|
-
this.bShowSelector$ = this.allowMultiple$;
|
|
534
|
-
this.myFiles.forEach(file => {
|
|
535
|
-
if (file?.secondary?.error) {
|
|
536
|
-
file.meta = 'File uploaded failed';
|
|
537
|
-
}
|
|
538
|
-
});
|
|
539
|
-
|
|
540
|
-
this.arFileList$ = this.myFiles.map(att => {
|
|
541
|
-
return this.getNewListUtilityItemProps({
|
|
542
|
-
att,
|
|
543
|
-
downloadFile: null,
|
|
544
|
-
cancelFile: null,
|
|
545
|
-
deleteFile: null,
|
|
546
|
-
removeFile: null
|
|
547
|
-
});
|
|
548
|
-
});
|
|
549
|
-
|
|
550
|
-
this.bShowJustDelete$ = true;
|
|
551
|
-
this.bLoading$ = false;
|
|
552
|
-
}
|
|
553
|
-
|
|
554
|
-
getNewListUtilityItemProps = ({ att, cancelFile, downloadFile, deleteFile, removeFile }) => {
|
|
555
|
-
let actions;
|
|
556
|
-
let isDownloadable = false;
|
|
557
|
-
|
|
558
|
-
if (att.progress && att.progress !== 100) {
|
|
559
|
-
actions = [
|
|
560
|
-
{
|
|
561
|
-
id: `Cancel-${att.ID}`,
|
|
562
|
-
text: this.pConn$.getLocalizedValue('Cancel', '', ''),
|
|
563
|
-
icon: 'times',
|
|
564
|
-
onClick: cancelFile
|
|
565
|
-
}
|
|
566
|
-
];
|
|
567
|
-
} else if (att.links) {
|
|
568
|
-
const isFile = att.type === 'FILE';
|
|
569
|
-
const ID = att.ID.replace(/\s/gi, '');
|
|
570
|
-
const actionsMap = new Map([
|
|
571
|
-
[
|
|
572
|
-
'download',
|
|
573
|
-
{
|
|
574
|
-
id: `download-${ID}`,
|
|
575
|
-
text: isFile ? this.pConn$.getLocalizedValue('Download', '', '') : this.pConn$.getLocalizedValue('Open', '', ''),
|
|
576
|
-
icon: isFile ? 'download' : 'open',
|
|
577
|
-
onClick: downloadFile
|
|
578
|
-
}
|
|
579
|
-
],
|
|
580
|
-
[
|
|
581
|
-
'delete',
|
|
582
|
-
{
|
|
583
|
-
id: `Delete-${ID}`,
|
|
584
|
-
text: this.pConn$.getLocalizedValue('Delete', '', ''),
|
|
585
|
-
icon: 'trash',
|
|
586
|
-
onClick: deleteFile
|
|
442
|
+
this.updateAttachments();
|
|
443
|
+
if (this.filesWithError?.length === 0) {
|
|
444
|
+
this.clearFieldErrorMessages();
|
|
587
445
|
}
|
|
588
|
-
]
|
|
589
|
-
]);
|
|
590
|
-
actions = [];
|
|
591
|
-
actionsMap.forEach((action, actionKey) => {
|
|
592
|
-
if (att.links[actionKey]) {
|
|
593
|
-
actions.push(action);
|
|
594
446
|
}
|
|
447
|
+
})
|
|
448
|
+
.catch(error => {
|
|
449
|
+
console.log(error);
|
|
595
450
|
});
|
|
596
|
-
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
597
|
-
isDownloadable = att.links.download;
|
|
598
|
-
} else if (att.error) {
|
|
599
|
-
actions = [
|
|
600
|
-
{
|
|
601
|
-
id: `Remove-${att.ID}`,
|
|
602
|
-
text: this.pConn$.getLocalizedValue('Remove', '', ''),
|
|
603
|
-
icon: 'trash',
|
|
604
|
-
onClick: removeFile
|
|
605
|
-
}
|
|
606
|
-
];
|
|
607
|
-
}
|
|
608
|
-
|
|
609
|
-
return {
|
|
610
|
-
id: att.ID,
|
|
611
|
-
visual: {
|
|
612
|
-
icon: this.utils.getIconForAttachment(att),
|
|
613
|
-
progress: att.progress == 100 ? undefined : att.progress
|
|
614
|
-
},
|
|
615
|
-
primary: {
|
|
616
|
-
type: att.type,
|
|
617
|
-
name: att.error ? att.fileName : att.name,
|
|
618
|
-
icon: 'trash',
|
|
619
|
-
click: removeFile
|
|
620
|
-
},
|
|
621
|
-
secondary: {
|
|
622
|
-
text: att.meta,
|
|
623
|
-
error: att.error
|
|
624
|
-
},
|
|
625
|
-
actions
|
|
626
|
-
};
|
|
627
|
-
};
|
|
628
|
-
|
|
629
|
-
onUploadProgress() {}
|
|
630
|
-
|
|
631
|
-
getFiles(arFiles: any[]): any[] {
|
|
632
|
-
const files = this.allowMultiple$ ? arFiles : [arFiles[0]];
|
|
633
|
-
return this.setNewFiles(files);
|
|
634
|
-
}
|
|
635
|
-
|
|
636
|
-
setNewFiles(arFiles) {
|
|
637
|
-
let index = 0;
|
|
638
|
-
const maxAttachmentSize = PCore.getEnvironmentInfo().getMaxAttachmentSize() || 5;
|
|
639
|
-
for (const file of arFiles) {
|
|
640
|
-
file.mimeType = file.type;
|
|
641
|
-
file.icon = this.utils.getIconFromFileType(file.type);
|
|
642
|
-
file.ID = `${new Date().getTime()}I${index}`;
|
|
643
|
-
|
|
644
|
-
if (!this.validateMaxSize(file, maxAttachmentSize)) {
|
|
645
|
-
file.error = true;
|
|
646
|
-
file.meta = this.pConn$.getLocalizedValue('File is too big. Max allowed size is 5MB.', '', '');
|
|
647
|
-
} else if (!this.validateFileExtension(file, this.extensions$)) {
|
|
648
|
-
file.error = true;
|
|
649
|
-
file.meta = `${this.pConn$.getLocalizedValue('File has invalid extension. Allowed extensions are:', '', '')} ${this.extensions$.replaceAll(
|
|
650
|
-
'.',
|
|
651
|
-
''
|
|
652
|
-
)}`;
|
|
653
|
-
}
|
|
654
|
-
if (file.error) {
|
|
655
|
-
const fieldName = (this.pConn$.getStateProps() as any).value;
|
|
656
|
-
const context = this.pConn$.getContextName();
|
|
657
|
-
PCore.getMessageManager().addMessages({
|
|
658
|
-
// @ts-ignore
|
|
659
|
-
messages: [
|
|
660
|
-
{
|
|
661
|
-
type: 'error',
|
|
662
|
-
message: this.pConn$.getLocalizedValue('Error with one or more files', '', '')
|
|
663
|
-
}
|
|
664
|
-
],
|
|
665
|
-
property: fieldName,
|
|
666
|
-
pageReference: this.pConn$.getPageReference(),
|
|
667
|
-
context
|
|
668
|
-
});
|
|
669
|
-
}
|
|
670
|
-
index++;
|
|
671
|
-
}
|
|
672
|
-
|
|
673
|
-
return [...arFiles];
|
|
674
451
|
}
|
|
675
452
|
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
}
|
|
680
|
-
|
|
681
|
-
validateFileExtension = (fileObj, allowedExtensions) => {
|
|
682
|
-
if (!allowedExtensions) {
|
|
683
|
-
return true;
|
|
453
|
+
ngOnDestroy(): void {
|
|
454
|
+
if (this.angularPConnectData.unsubscribeFn) {
|
|
455
|
+
this.angularPConnectData.unsubscribeFn();
|
|
684
456
|
}
|
|
685
|
-
const allowedExtensionList = allowedExtensions
|
|
686
|
-
.toLowerCase()
|
|
687
|
-
.split(',')
|
|
688
|
-
.map(item => item.replaceAll('.', '').trim());
|
|
689
|
-
const extension = fileObj.name.split('.').pop().toLowerCase();
|
|
690
|
-
return allowedExtensionList.includes(extension);
|
|
691
|
-
};
|
|
692
457
|
|
|
693
|
-
|
|
694
|
-
return {
|
|
695
|
-
props: {
|
|
696
|
-
meta: `${respObj.pyCategoryName}, ${respObj.pxCreateOperator}`,
|
|
697
|
-
name: respObj.pyAttachName,
|
|
698
|
-
icon: this.utils.getIconFromFileType(respObj.pyMimeFileExtension)
|
|
699
|
-
},
|
|
700
|
-
responseProps: {
|
|
701
|
-
...respObj
|
|
702
|
-
}
|
|
703
|
-
};
|
|
458
|
+
PCore.getPubSubUtils().unsubscribe(PCore.getConstants().PUB_SUB_EVENTS.CASE_EVENTS.ASSIGNMENT_SUBMISSION, this.caseID);
|
|
704
459
|
}
|
|
705
460
|
}
|