@pega/react-sdk-components 24.2.11 → 25.1.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/bridge/Context/StoreContext.d.ts +0 -1
- package/lib/bridge/Context/StoreContext.d.ts.map +1 -1
- package/lib/bridge/Context/StoreContext.js.map +1 -1
- package/lib/bridge/helpers/sdk_component_map.d.ts.map +1 -1
- package/lib/bridge/helpers/sdk_component_map.js +0 -6
- package/lib/bridge/helpers/sdk_component_map.js.map +1 -1
- package/lib/bridge/react_pconnect.d.ts.map +1 -1
- package/lib/bridge/react_pconnect.js +11 -14
- package/lib/bridge/react_pconnect.js.map +1 -1
- package/lib/components/designSystemExtension/AlertBanner/AlertBanner.js.map +1 -1
- package/lib/components/designSystemExtension/Banner/Banner.css +1 -1
- package/lib/components/designSystemExtension/Banner/Banner.d.ts.map +1 -1
- package/lib/components/designSystemExtension/Banner/Banner.js +2 -2
- package/lib/components/designSystemExtension/Banner/Banner.js.map +1 -1
- package/lib/components/designSystemExtension/CaseSummaryFields/CaseSummaryFields.css +0 -1
- package/lib/components/designSystemExtension/CaseSummaryFields/CaseSummaryFields.d.ts.map +1 -1
- package/lib/components/designSystemExtension/CaseSummaryFields/CaseSummaryFields.js +50 -35
- package/lib/components/designSystemExtension/CaseSummaryFields/CaseSummaryFields.js.map +1 -1
- package/lib/components/designSystemExtension/DetailsFields/DetailsFields.d.ts.map +1 -1
- package/lib/components/designSystemExtension/DetailsFields/DetailsFields.js +6 -8
- package/lib/components/designSystemExtension/DetailsFields/DetailsFields.js.map +1 -1
- package/lib/components/designSystemExtension/FieldGroup/FieldGroup.d.ts +1 -1
- package/lib/components/designSystemExtension/FieldGroup/FieldGroup.d.ts.map +1 -1
- package/lib/components/designSystemExtension/FieldGroup/FieldGroup.js +3 -5
- package/lib/components/designSystemExtension/FieldGroup/FieldGroup.js.map +1 -1
- package/lib/components/designSystemExtension/FieldGroupList/FieldGroupList.js +2 -2
- package/lib/components/designSystemExtension/FieldGroupList/FieldGroupList.js.map +1 -1
- package/lib/components/designSystemExtension/FieldValueList/FieldValueList.d.ts.map +1 -1
- package/lib/components/designSystemExtension/FieldValueList/FieldValueList.js +4 -6
- package/lib/components/designSystemExtension/FieldValueList/FieldValueList.js.map +1 -1
- package/lib/components/designSystemExtension/Operator/Operator.d.ts +1 -1
- package/lib/components/designSystemExtension/Operator/Operator.d.ts.map +1 -1
- package/lib/components/designSystemExtension/Operator/Operator.js +12 -9
- package/lib/components/designSystemExtension/Operator/Operator.js.map +1 -1
- package/lib/components/designSystemExtension/Pulse/Pulse.d.ts +1 -1
- package/lib/components/designSystemExtension/Pulse/Pulse.d.ts.map +1 -1
- package/lib/components/designSystemExtension/Pulse/Pulse.js.map +1 -1
- package/lib/components/designSystemExtension/RichTextEditor/RichTextEditor.d.ts.map +1 -1
- package/lib/components/designSystemExtension/RichTextEditor/RichTextEditor.js +32 -4
- package/lib/components/designSystemExtension/RichTextEditor/RichTextEditor.js.map +1 -1
- package/lib/components/designSystemExtension/WssQuickCreate/WssQuickCreate.css +7 -14
- package/lib/components/designSystemExtension/WssQuickCreate/WssQuickCreate.d.ts.map +1 -1
- package/lib/components/designSystemExtension/WssQuickCreate/WssQuickCreate.js +12 -2
- package/lib/components/designSystemExtension/WssQuickCreate/WssQuickCreate.js.map +1 -1
- package/lib/components/field/AutoComplete/AutoComplete.d.ts +1 -1
- package/lib/components/field/AutoComplete/AutoComplete.d.ts.map +1 -1
- package/lib/components/field/AutoComplete/AutoComplete.js.map +1 -1
- package/lib/components/field/CancelAlert/CancelAlert.css +4 -4
- package/lib/components/field/CancelAlert/CancelAlert.d.ts +1 -1
- package/lib/components/field/CancelAlert/CancelAlert.d.ts.map +1 -1
- package/lib/components/field/CancelAlert/CancelAlert.js +3 -3
- package/lib/components/field/CancelAlert/CancelAlert.js.map +1 -1
- package/lib/components/field/Checkbox/Checkbox.d.ts +9 -1
- package/lib/components/field/Checkbox/Checkbox.d.ts.map +1 -1
- package/lib/components/field/Checkbox/Checkbox.js +52 -3
- package/lib/components/field/Checkbox/Checkbox.js.map +1 -1
- package/lib/components/field/Currency/Currency.d.ts +1 -1
- package/lib/components/field/Currency/Currency.d.ts.map +1 -1
- package/lib/components/field/Currency/Currency.js +2 -2
- package/lib/components/field/Currency/Currency.js.map +1 -1
- package/lib/components/field/Currency/currency-utils.d.ts.map +1 -1
- package/lib/components/field/Currency/currency-utils.js +0 -2
- package/lib/components/field/Currency/currency-utils.js.map +1 -1
- package/lib/components/field/Date/Date.d.ts +1 -1
- package/lib/components/field/Date/Date.d.ts.map +1 -1
- package/lib/components/field/Date/Date.js +3 -6
- package/lib/components/field/Date/Date.js.map +1 -1
- package/lib/components/field/DateTime/DateTime.d.ts +1 -1
- package/lib/components/field/DateTime/DateTime.d.ts.map +1 -1
- package/lib/components/field/DateTime/DateTime.js +4 -7
- package/lib/components/field/DateTime/DateTime.js.map +1 -1
- package/lib/components/field/Decimal/Decimal.d.ts +1 -1
- package/lib/components/field/Decimal/Decimal.d.ts.map +1 -1
- package/lib/components/field/Decimal/Decimal.js +2 -4
- package/lib/components/field/Decimal/Decimal.js.map +1 -1
- package/lib/components/field/Dropdown/Dropdown.d.ts +1 -1
- package/lib/components/field/Dropdown/Dropdown.d.ts.map +1 -1
- package/lib/components/field/Dropdown/Dropdown.js +6 -9
- package/lib/components/field/Dropdown/Dropdown.js.map +1 -1
- package/lib/components/field/Email/Email.d.ts +1 -1
- package/lib/components/field/Email/Email.d.ts.map +1 -1
- package/lib/components/field/Email/Email.js +6 -7
- package/lib/components/field/Email/Email.js.map +1 -1
- package/lib/components/field/Group/Group.d.ts +2 -2
- package/lib/components/field/Group/Group.d.ts.map +1 -1
- package/lib/components/field/Group/Group.js +4 -3
- package/lib/components/field/Group/Group.js.map +1 -1
- package/lib/components/field/Integer/Integer.d.ts +1 -1
- package/lib/components/field/Integer/Integer.d.ts.map +1 -1
- package/lib/components/field/Integer/Integer.js +4 -5
- package/lib/components/field/Integer/Integer.js.map +1 -1
- package/lib/components/field/Location/Location.css +4 -0
- package/lib/components/field/Location/Location.d.ts +11 -0
- package/lib/components/field/Location/Location.d.ts.map +1 -0
- package/lib/components/field/Location/Location.js +158 -0
- package/lib/components/field/Location/Location.js.map +1 -0
- package/lib/components/field/Location/index.d.ts +2 -0
- package/lib/components/field/Location/index.d.ts.map +1 -0
- package/lib/components/field/Location/index.js +2 -0
- package/lib/components/field/Location/index.js.map +1 -0
- package/lib/components/field/Multiselect/Multiselect.js.map +1 -1
- package/lib/components/field/Multiselect/utils.d.ts +2 -1
- package/lib/components/field/Multiselect/utils.d.ts.map +1 -1
- package/lib/components/field/Multiselect/utils.js +1 -1
- package/lib/components/field/Multiselect/utils.js.map +1 -1
- package/lib/components/field/ObjectReference/ObjectReference.d.ts +16 -0
- package/lib/components/field/ObjectReference/ObjectReference.d.ts.map +1 -0
- package/lib/components/field/ObjectReference/ObjectReference.js +165 -0
- package/lib/components/field/ObjectReference/ObjectReference.js.map +1 -0
- package/lib/components/field/ObjectReference/index.d.ts +2 -0
- package/lib/components/field/ObjectReference/index.d.ts.map +1 -0
- package/lib/components/field/ObjectReference/index.js +2 -0
- package/lib/components/field/ObjectReference/index.js.map +1 -0
- package/lib/components/field/ObjectReference/utils.d.ts +17 -0
- package/lib/components/field/ObjectReference/utils.d.ts.map +1 -0
- package/lib/components/field/ObjectReference/utils.js +99 -0
- package/lib/components/field/ObjectReference/utils.js.map +1 -0
- package/lib/components/field/Percentage/Percentage.d.ts +1 -1
- package/lib/components/field/Percentage/Percentage.d.ts.map +1 -1
- package/lib/components/field/Percentage/Percentage.js +2 -5
- package/lib/components/field/Percentage/Percentage.js.map +1 -1
- package/lib/components/field/Phone/Phone.d.ts +1 -1
- package/lib/components/field/Phone/Phone.d.ts.map +1 -1
- package/lib/components/field/Phone/Phone.js +6 -4
- package/lib/components/field/Phone/Phone.js.map +1 -1
- package/lib/components/field/RadioButtons/RadioButtons.d.ts +8 -1
- package/lib/components/field/RadioButtons/RadioButtons.d.ts.map +1 -1
- package/lib/components/field/RadioButtons/RadioButtons.js +12 -1
- package/lib/components/field/RadioButtons/RadioButtons.js.map +1 -1
- package/lib/components/field/RichText/RichText.css +79 -0
- package/lib/components/field/RichText/RichText.d.ts +2 -1
- package/lib/components/field/RichText/RichText.d.ts.map +1 -1
- package/lib/components/field/RichText/RichText.js +1 -0
- package/lib/components/field/RichText/RichText.js.map +1 -1
- package/lib/components/field/ScalarList/ScalarList.d.ts +1 -1
- package/lib/components/field/ScalarList/ScalarList.d.ts.map +1 -1
- package/lib/components/field/ScalarList/ScalarList.js +1 -2
- package/lib/components/field/ScalarList/ScalarList.js.map +1 -1
- package/lib/components/field/SelectableCard/SelectableCard.d.ts +2 -0
- package/lib/components/field/SelectableCard/SelectableCard.d.ts.map +1 -0
- package/lib/components/field/SelectableCard/SelectableCard.js +57 -0
- package/lib/components/field/SelectableCard/SelectableCard.js.map +1 -0
- package/lib/components/field/SelectableCard/index.d.ts +2 -0
- package/lib/components/field/SelectableCard/index.d.ts.map +1 -0
- package/lib/components/field/SelectableCard/index.js +2 -0
- package/lib/components/field/SelectableCard/index.js.map +1 -0
- package/lib/components/field/SelectableCard/utils.d.ts +13 -0
- package/lib/components/field/SelectableCard/utils.d.ts.map +1 -0
- package/lib/components/field/SelectableCard/utils.js +183 -0
- package/lib/components/field/SelectableCard/utils.js.map +1 -0
- package/lib/components/field/SemanticLink/SemanticLink.d.ts +10 -2
- package/lib/components/field/SemanticLink/SemanticLink.d.ts.map +1 -1
- package/lib/components/field/SemanticLink/SemanticLink.js +128 -15
- package/lib/components/field/SemanticLink/SemanticLink.js.map +1 -1
- package/lib/components/field/SemanticLink/utils.js +1 -1
- package/lib/components/field/SemanticLink/utils.js.map +1 -1
- package/lib/components/field/TextArea/TextArea.d.ts +1 -1
- package/lib/components/field/TextArea/TextArea.d.ts.map +1 -1
- package/lib/components/field/TextArea/TextArea.js +4 -5
- package/lib/components/field/TextArea/TextArea.js.map +1 -1
- package/lib/components/field/TextContent/TextContent.d.ts +1 -1
- package/lib/components/field/TextContent/TextContent.d.ts.map +1 -1
- package/lib/components/field/TextContent/TextContent.js +0 -1
- package/lib/components/field/TextContent/TextContent.js.map +1 -1
- package/lib/components/field/TextInput/TextInput.d.ts +1 -1
- package/lib/components/field/TextInput/TextInput.d.ts.map +1 -1
- package/lib/components/field/TextInput/TextInput.js +4 -5
- package/lib/components/field/TextInput/TextInput.js.map +1 -1
- package/lib/components/field/Time/Time.d.ts +1 -1
- package/lib/components/field/Time/Time.d.ts.map +1 -1
- package/lib/components/field/Time/Time.js +2 -5
- package/lib/components/field/Time/Time.js.map +1 -1
- package/lib/components/field/URL/URL.d.ts +1 -1
- package/lib/components/field/URL/URL.d.ts.map +1 -1
- package/lib/components/field/URL/URL.js +4 -5
- package/lib/components/field/URL/URL.js.map +1 -1
- package/lib/components/field/UserReference/UserReference.d.ts +1 -2
- package/lib/components/field/UserReference/UserReference.d.ts.map +1 -1
- package/lib/components/field/UserReference/UserReference.js +1 -2
- package/lib/components/field/UserReference/UserReference.js.map +1 -1
- package/lib/components/field/UserReference/UserReferenceUtils.d.ts.map +1 -1
- package/lib/components/field/UserReference/UserReferenceUtils.js.map +1 -1
- package/lib/components/helpers/attachmentShared.d.ts +2 -0
- package/lib/components/helpers/attachmentShared.d.ts.map +1 -0
- package/lib/components/helpers/attachmentShared.js +6 -0
- package/lib/components/helpers/attachmentShared.js.map +1 -0
- package/lib/components/helpers/case-utils.js.map +1 -1
- package/lib/components/helpers/common-utils.d.ts +1 -1
- package/lib/components/helpers/common-utils.d.ts.map +1 -1
- package/lib/components/helpers/common-utils.js +1 -2
- package/lib/components/helpers/common-utils.js.map +1 -1
- package/lib/components/helpers/data_page.d.ts.map +1 -1
- package/lib/components/helpers/data_page.js +0 -1
- package/lib/components/helpers/data_page.js.map +1 -1
- package/lib/components/helpers/date-format-utils.d.ts.map +1 -1
- package/lib/components/helpers/event-utils.d.ts.map +1 -1
- package/lib/components/helpers/event-utils.js.map +1 -1
- package/lib/components/helpers/field-group-utils.d.ts +1 -1
- package/lib/components/helpers/field-group-utils.d.ts.map +1 -1
- package/lib/components/helpers/field-group-utils.js.map +1 -1
- package/lib/components/helpers/formatters/Boolean.js.map +1 -1
- package/lib/components/helpers/formatters/Currency.d.ts +1 -0
- package/lib/components/helpers/formatters/Currency.d.ts.map +1 -1
- package/lib/components/helpers/formatters/Currency.js +8 -4
- package/lib/components/helpers/formatters/Currency.js.map +1 -1
- package/lib/components/helpers/formatters/CurrencyMap.d.ts.map +1 -1
- package/lib/components/helpers/formatters/CurrencyMap.js +0 -1
- package/lib/components/helpers/formatters/CurrencyMap.js.map +1 -1
- package/lib/components/helpers/formatters/Date.js.map +1 -1
- package/lib/components/helpers/formatters/index.d.ts +1 -0
- package/lib/components/helpers/formatters/index.d.ts.map +1 -1
- package/lib/components/helpers/formatters/index.js.map +1 -1
- package/lib/components/helpers/instructions-utils.d.ts.map +1 -1
- package/lib/components/helpers/object-utils.d.ts +9 -0
- package/lib/components/helpers/object-utils.d.ts.map +1 -0
- package/lib/components/helpers/object-utils.js +11 -0
- package/lib/components/helpers/object-utils.js.map +1 -0
- package/lib/components/helpers/reactContextHelpers.d.ts +0 -1
- package/lib/components/helpers/reactContextHelpers.d.ts.map +1 -1
- package/lib/components/helpers/simpleTableHelpers.d.ts +15 -1
- package/lib/components/helpers/simpleTableHelpers.d.ts.map +1 -1
- package/lib/components/helpers/simpleTableHelpers.js +111 -5
- package/lib/components/helpers/simpleTableHelpers.js.map +1 -1
- package/lib/components/helpers/state-utils.d.ts.map +1 -1
- package/lib/components/helpers/state-utils.js.map +1 -1
- package/lib/components/helpers/template-utils.js.map +1 -1
- package/lib/components/helpers/utils.d.ts +1 -0
- package/lib/components/helpers/utils.d.ts.map +1 -1
- package/lib/components/helpers/utils.js +7 -1
- package/lib/components/helpers/utils.js.map +1 -1
- package/lib/components/helpers/versionHelpers.d.ts.map +1 -1
- package/lib/components/helpers/versionHelpers.js +0 -1
- package/lib/components/helpers/versionHelpers.js.map +1 -1
- package/lib/components/infra/ActionButtons/ActionButtons.d.ts.map +1 -1
- package/lib/components/infra/ActionButtons/ActionButtons.js +12 -7
- package/lib/components/infra/ActionButtons/ActionButtons.js.map +1 -1
- package/lib/components/infra/Assignment/Assignment.d.ts +2 -2
- package/lib/components/infra/Assignment/Assignment.d.ts.map +1 -1
- package/lib/components/infra/Assignment/Assignment.js +32 -28
- package/lib/components/infra/Assignment/Assignment.js.map +1 -1
- package/lib/components/infra/AssignmentCard/AssignmentCard.d.ts +2 -2
- package/lib/components/infra/AssignmentCard/AssignmentCard.d.ts.map +1 -1
- package/lib/components/infra/AssignmentCard/AssignmentCard.js.map +1 -1
- package/lib/components/infra/Containers/FlowContainer/FlowContainer.d.ts +1 -2
- package/lib/components/infra/Containers/FlowContainer/FlowContainer.d.ts.map +1 -1
- package/lib/components/infra/Containers/FlowContainer/FlowContainer.js +15 -79
- package/lib/components/infra/Containers/FlowContainer/FlowContainer.js.map +1 -1
- package/lib/components/infra/Containers/FlowContainer/helpers.d.ts.map +1 -1
- package/lib/components/infra/Containers/FlowContainer/helpers.js.map +1 -1
- package/lib/components/infra/Containers/ModalViewContainer/ListViewActionButtons/ListViewActionButtons.d.ts +1 -1
- package/lib/components/infra/Containers/ModalViewContainer/ListViewActionButtons/ListViewActionButtons.d.ts.map +1 -1
- package/lib/components/infra/Containers/ModalViewContainer/ListViewActionButtons/ListViewActionButtons.js +0 -1
- package/lib/components/infra/Containers/ModalViewContainer/ListViewActionButtons/ListViewActionButtons.js.map +1 -1
- package/lib/components/infra/Containers/ModalViewContainer/ModalViewContainer.d.ts +1 -1
- package/lib/components/infra/Containers/ModalViewContainer/ModalViewContainer.d.ts.map +1 -1
- package/lib/components/infra/Containers/ModalViewContainer/ModalViewContainer.js +4 -5
- package/lib/components/infra/Containers/ModalViewContainer/ModalViewContainer.js.map +1 -1
- package/lib/components/infra/Containers/SimpleView/SimpleView.d.ts +0 -1
- package/lib/components/infra/Containers/SimpleView/SimpleView.d.ts.map +1 -1
- package/lib/components/infra/Containers/SimpleView/helper.d.ts +0 -1
- package/lib/components/infra/Containers/SimpleView/helper.d.ts.map +1 -1
- package/lib/components/infra/Containers/SimpleView/helper.js.map +1 -1
- package/lib/components/infra/Containers/ViewContainer/ViewContainer.d.ts +1 -1
- package/lib/components/infra/Containers/ViewContainer/ViewContainer.d.ts.map +1 -1
- package/lib/components/infra/Containers/ViewContainer/ViewContainer.js +3 -4
- package/lib/components/infra/Containers/ViewContainer/ViewContainer.js.map +1 -1
- package/lib/components/infra/Containers/container-helpers.d.ts +1 -0
- package/lib/components/infra/Containers/container-helpers.d.ts.map +1 -1
- package/lib/components/infra/Containers/container-helpers.js +46 -1
- package/lib/components/infra/Containers/container-helpers.js.map +1 -1
- package/lib/components/infra/DashboardFilter/DashboardFilter.d.ts +2 -2
- package/lib/components/infra/DashboardFilter/DashboardFilter.d.ts.map +1 -1
- package/lib/components/infra/DashboardFilter/DashboardFilter.js +1 -4
- package/lib/components/infra/DashboardFilter/DashboardFilter.js.map +1 -1
- package/lib/components/infra/DashboardFilter/filterUtils.d.ts.map +1 -1
- package/lib/components/infra/DashboardFilter/filterUtils.js +2 -3
- package/lib/components/infra/DashboardFilter/filterUtils.js.map +1 -1
- package/lib/components/infra/DeferLoad/DeferLoad.d.ts +1 -1
- package/lib/components/infra/DeferLoad/DeferLoad.d.ts.map +1 -1
- package/lib/components/infra/DeferLoad/DeferLoad.js +2 -4
- package/lib/components/infra/DeferLoad/DeferLoad.js.map +1 -1
- package/lib/components/infra/ErrorBoundary/ErrorBoundary.d.ts +1 -1
- package/lib/components/infra/ErrorBoundary/ErrorBoundary.d.ts.map +1 -1
- package/lib/components/infra/ErrorBoundary/ErrorBoundary.js +0 -2
- package/lib/components/infra/ErrorBoundary/ErrorBoundary.js.map +1 -1
- package/lib/components/infra/MultiStep/MultiStep.css +48 -70
- package/lib/components/infra/MultiStep/MultiStep.d.ts +2 -2
- package/lib/components/infra/MultiStep/MultiStep.d.ts.map +1 -1
- package/lib/components/infra/MultiStep/MultiStep.js +19 -37
- package/lib/components/infra/MultiStep/MultiStep.js.map +1 -1
- package/lib/components/infra/NavBar/NavBar.css +1 -1
- package/lib/components/infra/NavBar/NavBar.d.ts +1 -1
- package/lib/components/infra/NavBar/NavBar.d.ts.map +1 -1
- package/lib/components/infra/NavBar/NavBar.js +13 -7
- package/lib/components/infra/NavBar/NavBar.js.map +1 -1
- package/lib/components/infra/Reference/Reference.d.ts +1 -1
- package/lib/components/infra/Reference/Reference.d.ts.map +1 -1
- package/lib/components/infra/Reference/Reference.js +2 -3
- package/lib/components/infra/Reference/Reference.js.map +1 -1
- package/lib/components/infra/Region/Region.d.ts +1 -1
- package/lib/components/infra/Region/Region.d.ts.map +1 -1
- package/lib/components/infra/Region/Region.js.map +1 -1
- package/lib/components/infra/RootContainer/RootContainer.d.ts +2 -2
- package/lib/components/infra/RootContainer/RootContainer.d.ts.map +1 -1
- package/lib/components/infra/RootContainer/RootContainer.js +0 -1
- package/lib/components/infra/RootContainer/RootContainer.js.map +1 -1
- package/lib/components/infra/Stages/Stages.d.ts +1 -1
- package/lib/components/infra/Stages/Stages.d.ts.map +1 -1
- package/lib/components/infra/Stages/Stages.js +2 -2
- package/lib/components/infra/Stages/Stages.js.map +1 -1
- package/lib/components/infra/VerticalTabs/VerticalTabs/VerticalTabs.js +1 -1
- package/lib/components/infra/VerticalTabs/VerticalTabs/VerticalTabs.js.map +1 -1
- package/lib/components/infra/View/View.d.ts +2 -2
- package/lib/components/infra/View/View.d.ts.map +1 -1
- package/lib/components/infra/View/View.js +2 -1
- package/lib/components/infra/View/View.js.map +1 -1
- package/lib/components/template/AdvancedSearch/AdvancedSearch.d.ts +2 -0
- package/lib/components/template/AdvancedSearch/AdvancedSearch.d.ts.map +1 -0
- package/lib/components/template/AdvancedSearch/AdvancedSearch.js +68 -0
- package/lib/components/template/AdvancedSearch/AdvancedSearch.js.map +1 -0
- package/lib/components/template/AdvancedSearch/SearchGroup/persistUtils.d.ts +23 -0
- package/lib/components/template/AdvancedSearch/SearchGroup/persistUtils.d.ts.map +1 -0
- package/lib/components/template/AdvancedSearch/SearchGroup/persistUtils.js +26 -0
- package/lib/components/template/AdvancedSearch/SearchGroup/persistUtils.js.map +1 -0
- package/lib/components/template/AdvancedSearch/SearchGroups/SearchGroups.d.ts +3 -0
- package/lib/components/template/AdvancedSearch/SearchGroups/SearchGroups.d.ts.map +1 -0
- package/lib/components/template/AdvancedSearch/SearchGroups/SearchGroups.js +179 -0
- package/lib/components/template/AdvancedSearch/SearchGroups/SearchGroups.js.map +1 -0
- package/lib/components/template/AdvancedSearch/SearchGroups/hooks.d.ts +10 -0
- package/lib/components/template/AdvancedSearch/SearchGroups/hooks.d.ts.map +1 -0
- package/lib/components/template/AdvancedSearch/SearchGroups/hooks.js +25 -0
- package/lib/components/template/AdvancedSearch/SearchGroups/hooks.js.map +1 -0
- package/lib/components/template/AdvancedSearch/SearchGroups/index.d.ts +2 -0
- package/lib/components/template/AdvancedSearch/SearchGroups/index.d.ts.map +1 -0
- package/lib/components/template/AdvancedSearch/SearchGroups/index.js +2 -0
- package/lib/components/template/AdvancedSearch/SearchGroups/index.js.map +1 -0
- package/lib/components/template/AdvancedSearch/SearchGroups/utils.d.ts +16 -0
- package/lib/components/template/AdvancedSearch/SearchGroups/utils.d.ts.map +1 -0
- package/lib/components/template/AdvancedSearch/SearchGroups/utils.js +22 -0
- package/lib/components/template/AdvancedSearch/SearchGroups/utils.js.map +1 -0
- package/lib/components/template/AdvancedSearch/TemplateContext.d.ts +10 -0
- package/lib/components/template/AdvancedSearch/TemplateContext.d.ts.map +1 -0
- package/lib/components/template/AdvancedSearch/TemplateContext.js +11 -0
- package/lib/components/template/AdvancedSearch/TemplateContext.js.map +1 -0
- package/lib/components/template/AdvancedSearch/index.d.ts +2 -0
- package/lib/components/template/AdvancedSearch/index.d.ts.map +1 -0
- package/lib/components/template/AdvancedSearch/index.js +2 -0
- package/lib/components/template/AdvancedSearch/index.js.map +1 -0
- package/lib/components/template/AppShell/AppShell.css +1 -1
- package/lib/components/template/AppShell/AppShell.d.ts +2 -2
- package/lib/components/template/AppShell/AppShell.d.ts.map +1 -1
- package/lib/components/template/AppShell/AppShell.js +10 -13
- package/lib/components/template/AppShell/AppShell.js.map +1 -1
- package/lib/components/template/BannerPage/BannerPage.d.ts +2 -2
- package/lib/components/template/BannerPage/BannerPage.d.ts.map +1 -1
- package/lib/components/template/BannerPage/BannerPage.js.map +1 -1
- package/lib/components/template/CaseSummary/CaseSummary.d.ts +4 -2
- package/lib/components/template/CaseSummary/CaseSummary.d.ts.map +1 -1
- package/lib/components/template/CaseSummary/CaseSummary.js +24 -37
- package/lib/components/template/CaseSummary/CaseSummary.js.map +1 -1
- package/lib/components/template/CaseView/CaseView.d.ts +2 -2
- package/lib/components/template/CaseView/CaseView.d.ts.map +1 -1
- package/lib/components/template/CaseView/CaseView.js +13 -15
- package/lib/components/template/CaseView/CaseView.js.map +1 -1
- package/lib/components/template/CaseViewActionsMenu/CaseViewActionsMenu.d.ts +1 -1
- package/lib/components/template/CaseViewActionsMenu/CaseViewActionsMenu.d.ts.map +1 -1
- package/lib/components/template/CaseViewActionsMenu/CaseViewActionsMenu.js +1 -1
- package/lib/components/template/CaseViewActionsMenu/CaseViewActionsMenu.js.map +1 -1
- package/lib/components/template/Confirmation/Confirmation.d.ts +2 -2
- package/lib/components/template/Confirmation/Confirmation.d.ts.map +1 -1
- package/lib/components/template/Confirmation/Confirmation.js +0 -1
- package/lib/components/template/Confirmation/Confirmation.js.map +1 -1
- package/lib/components/template/DataReference/DataReference.d.ts +9 -2
- package/lib/components/template/DataReference/DataReference.d.ts.map +1 -1
- package/lib/components/template/DataReference/DataReference.js +239 -80
- package/lib/components/template/DataReference/DataReference.js.map +1 -1
- package/lib/components/template/DataReference/DataReferenceAdvancedSearchContext.d.ts +8 -0
- package/lib/components/template/DataReference/DataReferenceAdvancedSearchContext.d.ts.map +1 -0
- package/lib/components/template/DataReference/DataReferenceAdvancedSearchContext.js +9 -0
- package/lib/components/template/DataReference/DataReferenceAdvancedSearchContext.js.map +1 -0
- package/lib/components/template/DataReference/SearchForm.d.ts +3 -0
- package/lib/components/template/DataReference/SearchForm.d.ts.map +1 -0
- package/lib/components/template/DataReference/SearchForm.js +87 -0
- package/lib/components/template/DataReference/SearchForm.js.map +1 -0
- package/lib/components/template/DataReference/utils.d.ts +15 -0
- package/lib/components/template/DataReference/utils.d.ts.map +1 -0
- package/lib/components/template/DataReference/utils.js +75 -0
- package/lib/components/template/DataReference/utils.js.map +1 -0
- package/lib/components/template/DefaultForm/DefaultForm.d.ts +2 -2
- package/lib/components/template/DefaultForm/DefaultForm.d.ts.map +1 -1
- package/lib/components/template/DefaultForm/DefaultForm.js.map +1 -1
- package/lib/components/template/DefaultForm/utils/index.d.ts.map +1 -1
- package/lib/components/template/DefaultForm/utils/index.js +1 -2
- package/lib/components/template/DefaultForm/utils/index.js.map +1 -1
- package/lib/components/template/DefaultPage/DefaultPage.d.ts +36 -0
- package/lib/components/template/DefaultPage/DefaultPage.d.ts.map +1 -0
- package/lib/components/template/DefaultPage/DefaultPage.js +28 -0
- package/lib/components/template/DefaultPage/DefaultPage.js.map +1 -0
- package/lib/components/template/DefaultPage/index.d.ts +2 -0
- package/lib/components/template/DefaultPage/index.d.ts.map +1 -0
- package/lib/components/template/DefaultPage/index.js +2 -0
- package/lib/components/template/DefaultPage/index.js.map +1 -0
- package/lib/components/template/Details/Details/Details.d.ts +1 -1
- package/lib/components/template/Details/Details/Details.d.ts.map +1 -1
- package/lib/components/template/Details/Details/Details.js +2 -3
- package/lib/components/template/Details/Details/Details.js.map +1 -1
- package/lib/components/template/Details/DetailsSubTabs/DetailsSubTabs.d.ts +2 -2
- package/lib/components/template/Details/DetailsSubTabs/DetailsSubTabs.d.ts.map +1 -1
- package/lib/components/template/Details/DetailsSubTabs/DetailsSubTabs.js.map +1 -1
- package/lib/components/template/Details/DetailsThreeColumn/DetailsThreeColumn.d.ts +1 -1
- package/lib/components/template/Details/DetailsThreeColumn/DetailsThreeColumn.d.ts.map +1 -1
- package/lib/components/template/Details/DetailsThreeColumn/DetailsThreeColumn.js +2 -3
- package/lib/components/template/Details/DetailsThreeColumn/DetailsThreeColumn.js.map +1 -1
- package/lib/components/template/Details/DetailsTwoColumn/DetailsTwoColumn.d.ts +1 -1
- package/lib/components/template/Details/DetailsTwoColumn/DetailsTwoColumn.d.ts.map +1 -1
- package/lib/components/template/Details/DetailsTwoColumn/DetailsTwoColumn.js +2 -3
- package/lib/components/template/Details/DetailsTwoColumn/DetailsTwoColumn.js.map +1 -1
- package/lib/components/template/Details/DynamicTabs/DynamicTabs.d.ts +1 -1
- package/lib/components/template/Details/DynamicTabs/DynamicTabs.d.ts.map +1 -1
- package/lib/components/template/Details/DynamicTabs/DynamicTabs.js.map +1 -1
- package/lib/components/template/FieldGroupTemplate/FieldGroupTemplate.d.ts +1 -1
- package/lib/components/template/FieldGroupTemplate/FieldGroupTemplate.d.ts.map +1 -1
- package/lib/components/template/FieldGroupTemplate/FieldGroupTemplate.js +1 -2
- package/lib/components/template/FieldGroupTemplate/FieldGroupTemplate.js.map +1 -1
- package/lib/components/template/InlineDashboard/InlineDashboard.d.ts +2 -2
- package/lib/components/template/InlineDashboard/InlineDashboard.d.ts.map +1 -1
- package/lib/components/template/InlineDashboard/InlineDashboard.js +2 -2
- package/lib/components/template/InlineDashboard/InlineDashboard.js.map +1 -1
- package/lib/components/template/InlineDashboardPage/InlineDashboardPage.d.ts +2 -2
- package/lib/components/template/InlineDashboardPage/InlineDashboardPage.d.ts.map +1 -1
- package/lib/components/template/InlineDashboardPage/InlineDashboardPage.js.map +1 -1
- package/lib/components/template/ListPage/ListPage.d.ts +1 -1
- package/lib/components/template/ListPage/ListPage.d.ts.map +1 -1
- package/lib/components/template/ListPage/ListPage.js.map +1 -1
- package/lib/components/template/ListView/DefaultViewMeta.js.map +1 -1
- package/lib/components/template/ListView/ListView.d.ts +4 -1
- package/lib/components/template/ListView/ListView.d.ts.map +1 -1
- package/lib/components/template/ListView/ListView.js +133 -64
- package/lib/components/template/ListView/ListView.js.map +1 -1
- package/lib/components/template/ListView/hooks.d.ts.map +1 -1
- package/lib/components/template/ListView/hooks.js +2 -5
- package/lib/components/template/ListView/hooks.js.map +1 -1
- package/lib/components/template/ListView/utils.d.ts.map +1 -1
- package/lib/components/template/ListView/utils.js +28 -5
- package/lib/components/template/ListView/utils.js.map +1 -1
- package/lib/components/template/MultiReferenceReadOnly/MultiReferenceReadOnly.d.ts +1 -1
- package/lib/components/template/MultiReferenceReadOnly/MultiReferenceReadOnly.d.ts.map +1 -1
- package/lib/components/template/MultiReferenceReadOnly/MultiReferenceReadOnly.js.map +1 -1
- package/lib/components/template/NarrowWide/NarrowWide/NarrowWide.d.ts +2 -2
- package/lib/components/template/NarrowWide/NarrowWide/NarrowWide.d.ts.map +1 -1
- package/lib/components/template/NarrowWide/NarrowWide/NarrowWide.js.map +1 -1
- package/lib/components/template/NarrowWide/NarrowWideDetails/NarrowWideDetails.d.ts +1 -1
- package/lib/components/template/NarrowWide/NarrowWideDetails/NarrowWideDetails.d.ts.map +1 -1
- package/lib/components/template/NarrowWide/NarrowWideDetails/NarrowWideDetails.js +2 -3
- package/lib/components/template/NarrowWide/NarrowWideDetails/NarrowWideDetails.js.map +1 -1
- package/lib/components/template/NarrowWide/NarrowWideForm/NarrowWideForm.d.ts +2 -2
- package/lib/components/template/NarrowWide/NarrowWideForm/NarrowWideForm.d.ts.map +1 -1
- package/lib/components/template/NarrowWide/NarrowWideForm/NarrowWideForm.js.map +1 -1
- package/lib/components/template/NarrowWide/NarrowWidePage/NarrowWidePage.d.ts +2 -2
- package/lib/components/template/NarrowWide/NarrowWidePage/NarrowWidePage.d.ts.map +1 -1
- package/lib/components/template/NarrowWide/NarrowWidePage/NarrowWidePage.js.map +1 -1
- package/lib/components/template/OneColumn/OneColumn/OneColumn.d.ts +2 -2
- package/lib/components/template/OneColumn/OneColumn/OneColumn.d.ts.map +1 -1
- package/lib/components/template/OneColumn/OneColumn/OneColumn.js +2 -2
- package/lib/components/template/OneColumn/OneColumn/OneColumn.js.map +1 -1
- package/lib/components/template/OneColumn/OneColumnPage/OneColumnPage.d.ts +1 -1
- package/lib/components/template/OneColumn/OneColumnPage/OneColumnPage.d.ts.map +1 -1
- package/lib/components/template/OneColumn/OneColumnPage/OneColumnPage.js.map +1 -1
- package/lib/components/template/OneColumn/OneColumnTab/OneColumnTab.d.ts +2 -2
- package/lib/components/template/OneColumn/OneColumnTab/OneColumnTab.d.ts.map +1 -1
- package/lib/components/template/OneColumn/OneColumnTab/OneColumnTab.js.map +1 -1
- package/lib/components/template/PromotedFilters/PromotedFilters.d.ts +1 -1
- package/lib/components/template/PromotedFilters/PromotedFilters.d.ts.map +1 -1
- package/lib/components/template/PromotedFilters/PromotedFilters.js +0 -1
- package/lib/components/template/PromotedFilters/PromotedFilters.js.map +1 -1
- package/lib/components/template/SelfServiceCaseView/SelfServiceCaseView.d.ts +2 -0
- package/lib/components/template/SelfServiceCaseView/SelfServiceCaseView.d.ts.map +1 -0
- package/lib/components/template/SelfServiceCaseView/SelfServiceCaseView.js +73 -0
- package/lib/components/template/SelfServiceCaseView/SelfServiceCaseView.js.map +1 -0
- package/lib/components/template/SelfServiceCaseView/index.d.ts +2 -0
- package/lib/components/template/SelfServiceCaseView/index.d.ts.map +1 -0
- package/lib/components/template/SelfServiceCaseView/index.js +2 -0
- package/lib/components/template/SelfServiceCaseView/index.js.map +1 -0
- package/lib/components/template/SimpleTable/SimpleTable/SimpleTable.d.ts +1 -1
- package/lib/components/template/SimpleTable/SimpleTable/SimpleTable.d.ts.map +1 -1
- package/lib/components/template/SimpleTable/SimpleTable/SimpleTable.js +1 -2
- package/lib/components/template/SimpleTable/SimpleTable/SimpleTable.js.map +1 -1
- package/lib/components/template/SimpleTable/SimpleTableManual/SimpleTableManual.d.ts +2 -2
- package/lib/components/template/SimpleTable/SimpleTableManual/SimpleTableManual.d.ts.map +1 -1
- package/lib/components/template/SimpleTable/SimpleTableManual/SimpleTableManual.js +34 -32
- package/lib/components/template/SimpleTable/SimpleTableManual/SimpleTableManual.js.map +1 -1
- package/lib/components/template/SimpleTable/SimpleTableSelect/SimpleTableSelect.d.ts +1 -1
- package/lib/components/template/SimpleTable/SimpleTableSelect/SimpleTableSelect.d.ts.map +1 -1
- package/lib/components/template/SimpleTable/SimpleTableSelect/SimpleTableSelect.js.map +1 -1
- package/lib/components/template/SingleReferenceReadOnly/SingleReferenceReadOnly.d.ts +1 -1
- package/lib/components/template/SingleReferenceReadOnly/SingleReferenceReadOnly.d.ts.map +1 -1
- package/lib/components/template/SingleReferenceReadOnly/SingleReferenceReadOnly.js +3 -2
- package/lib/components/template/SingleReferenceReadOnly/SingleReferenceReadOnly.js.map +1 -1
- package/lib/components/template/SubTabs/SubTabs.d.ts +2 -2
- package/lib/components/template/SubTabs/SubTabs.d.ts.map +1 -1
- package/lib/components/template/SubTabs/SubTabs.js.map +1 -1
- package/lib/components/template/SubTabs/tabUtils.d.ts +10 -0
- package/lib/components/template/SubTabs/tabUtils.d.ts.map +1 -1
- package/lib/components/template/SubTabs/tabUtils.js +102 -1
- package/lib/components/template/SubTabs/tabUtils.js.map +1 -1
- package/lib/components/template/TwoColumn/TwoColumn/TwoColumn.d.ts +2 -2
- package/lib/components/template/TwoColumn/TwoColumn/TwoColumn.d.ts.map +1 -1
- package/lib/components/template/TwoColumn/TwoColumn/TwoColumn.js +2 -3
- package/lib/components/template/TwoColumn/TwoColumn/TwoColumn.js.map +1 -1
- package/lib/components/template/TwoColumn/TwoColumnPage/TwoColumnPage.d.ts +1 -1
- package/lib/components/template/TwoColumn/TwoColumnPage/TwoColumnPage.d.ts.map +1 -1
- package/lib/components/template/TwoColumn/TwoColumnPage/TwoColumnPage.js.map +1 -1
- package/lib/components/template/TwoColumn/TwoColumnTab/TwoColumnTab.d.ts +2 -2
- package/lib/components/template/TwoColumn/TwoColumnTab/TwoColumnTab.d.ts.map +1 -1
- package/lib/components/template/TwoColumn/TwoColumnTab/TwoColumnTab.js +2 -3
- package/lib/components/template/TwoColumn/TwoColumnTab/TwoColumnTab.js.map +1 -1
- package/lib/components/template/WideNarrow/WideNarrow/WideNarrow.d.ts +2 -2
- package/lib/components/template/WideNarrow/WideNarrow/WideNarrow.d.ts.map +1 -1
- package/lib/components/template/WideNarrow/WideNarrow/WideNarrow.js.map +1 -1
- package/lib/components/template/WideNarrow/WideNarrowDetails/WideNarrowDetails.d.ts +1 -1
- package/lib/components/template/WideNarrow/WideNarrowDetails/WideNarrowDetails.d.ts.map +1 -1
- package/lib/components/template/WideNarrow/WideNarrowDetails/WideNarrowDetails.js +2 -3
- package/lib/components/template/WideNarrow/WideNarrowDetails/WideNarrowDetails.js.map +1 -1
- package/lib/components/template/WideNarrow/WideNarrowForm/WideNarrowForm.d.ts +2 -2
- package/lib/components/template/WideNarrow/WideNarrowForm/WideNarrowForm.d.ts.map +1 -1
- package/lib/components/template/WideNarrow/WideNarrowForm/WideNarrowForm.js.map +1 -1
- package/lib/components/template/WideNarrow/WideNarrowPage/WideNarrowPage.d.ts +2 -2
- package/lib/components/template/WideNarrow/WideNarrowPage/WideNarrowPage.d.ts.map +1 -1
- package/lib/components/template/WideNarrow/WideNarrowPage/WideNarrowPage.js.map +1 -1
- package/lib/components/template/WssNavBar/WssNavBar.css +1 -1
- package/lib/components/template/WssNavBar/WssNavBar.d.ts +1 -1
- package/lib/components/template/WssNavBar/WssNavBar.d.ts.map +1 -1
- package/lib/components/template/WssNavBar/WssNavBar.js +4 -4
- package/lib/components/template/WssNavBar/WssNavBar.js.map +1 -1
- package/lib/components/template/utils.d.ts +7 -0
- package/lib/components/template/utils.d.ts.map +1 -0
- package/lib/components/template/utils.js +52 -0
- package/lib/components/template/utils.js.map +1 -0
- package/lib/components/widget/AppAnnouncement/AppAnnouncement.d.ts +1 -1
- package/lib/components/widget/AppAnnouncement/AppAnnouncement.d.ts.map +1 -1
- package/lib/components/widget/AppAnnouncement/AppAnnouncement.js.map +1 -1
- package/lib/components/widget/Attachment/Attachment.css +6 -8
- package/lib/components/widget/Attachment/Attachment.d.ts +4 -2
- package/lib/components/widget/Attachment/Attachment.d.ts.map +1 -1
- package/lib/components/widget/Attachment/Attachment.js +255 -202
- package/lib/components/widget/Attachment/Attachment.js.map +1 -1
- package/lib/components/widget/Attachment/Attachment.types.d.ts +90 -0
- package/lib/components/widget/Attachment/Attachment.types.d.ts.map +1 -0
- package/lib/components/widget/Attachment/Attachment.types.js +2 -0
- package/lib/components/widget/Attachment/Attachment.types.js.map +1 -0
- package/lib/components/widget/Attachment/AttachmentUtils.d.ts +25 -0
- package/lib/components/widget/Attachment/AttachmentUtils.d.ts.map +1 -0
- package/lib/components/widget/Attachment/AttachmentUtils.js +255 -0
- package/lib/components/widget/Attachment/AttachmentUtils.js.map +1 -0
- package/lib/components/widget/CaseHistory/CaseHistory.d.ts +1 -1
- package/lib/components/widget/CaseHistory/CaseHistory.d.ts.map +1 -1
- package/lib/components/widget/CaseHistory/CaseHistory.js +2 -2
- package/lib/components/widget/CaseHistory/CaseHistory.js.map +1 -1
- package/lib/components/widget/FileUtility/ActionButtonsForFileUtil/ActionButtonsForFileUtil.css +0 -14
- package/lib/components/widget/FileUtility/ActionButtonsForFileUtil/ActionButtonsForFileUtil.d.ts +1 -1
- package/lib/components/widget/FileUtility/ActionButtonsForFileUtil/ActionButtonsForFileUtil.d.ts.map +1 -1
- package/lib/components/widget/FileUtility/ActionButtonsForFileUtil/ActionButtonsForFileUtil.js +1 -1
- package/lib/components/widget/FileUtility/ActionButtonsForFileUtil/ActionButtonsForFileUtil.js.map +1 -1
- package/lib/components/widget/FileUtility/FileUtility/FileUtility.css +7 -6
- package/lib/components/widget/FileUtility/FileUtility/FileUtility.d.ts +2 -1
- package/lib/components/widget/FileUtility/FileUtility/FileUtility.d.ts.map +1 -1
- package/lib/components/widget/FileUtility/FileUtility/FileUtility.js +29 -17
- package/lib/components/widget/FileUtility/FileUtility/FileUtility.js.map +1 -1
- package/lib/components/widget/Followers/Followers.d.ts +2 -2
- package/lib/components/widget/Followers/Followers.d.ts.map +1 -1
- package/lib/components/widget/Followers/Followers.js +0 -2
- package/lib/components/widget/Followers/Followers.js.map +1 -1
- package/lib/components/widget/QuickCreate/QuickCreate.d.ts +1 -1
- package/lib/components/widget/QuickCreate/QuickCreate.d.ts.map +1 -1
- package/lib/components/widget/QuickCreate/QuickCreate.js +0 -1
- package/lib/components/widget/QuickCreate/QuickCreate.js.map +1 -1
- package/lib/components/widget/SummaryItem/SummaryItem.css +9 -11
- package/lib/components/widget/SummaryItem/SummaryItem.d.ts +1 -1
- package/lib/components/widget/SummaryItem/SummaryItem.d.ts.map +1 -1
- package/lib/components/widget/SummaryItem/SummaryItem.js +1 -1
- package/lib/components/widget/SummaryItem/SummaryItem.js.map +1 -1
- package/lib/components/widget/SummaryList/SummaryList.d.ts +1 -1
- package/lib/components/widget/SummaryList/SummaryList.d.ts.map +1 -1
- package/lib/components/widget/SummaryList/SummaryList.js.map +1 -1
- package/lib/components/widget/ToDo/ToDo.css +1 -13
- package/lib/components/widget/ToDo/ToDo.d.ts +1 -1
- package/lib/components/widget/ToDo/ToDo.d.ts.map +1 -1
- package/lib/components/widget/ToDo/ToDo.js +21 -16
- package/lib/components/widget/ToDo/ToDo.js.map +1 -1
- package/lib/hooks/useAfterInitialEffect.d.ts +1 -1
- package/lib/hooks/useAfterInitialEffect.d.ts.map +1 -1
- package/lib/hooks/useAfterInitialEffect.js.map +1 -1
- package/lib/hooks/useConsolidatedRef.d.ts +1 -1
- package/lib/hooks/useConsolidatedRef.d.ts.map +1 -1
- package/lib/hooks/useConsolidatedRef.js.map +1 -1
- package/lib/hooks/useFocusFirstField.d.ts.map +1 -1
- package/lib/hooks/useFocusFirstField.js.map +1 -1
- package/lib/hooks/useGetTabsCount.d.ts +10 -0
- package/lib/hooks/useGetTabsCount.d.ts.map +1 -0
- package/lib/hooks/useGetTabsCount.js +165 -0
- package/lib/hooks/useGetTabsCount.js.map +1 -0
- package/lib/hooks/useIsMount.d.ts +2 -0
- package/lib/hooks/useIsMount.d.ts.map +1 -0
- package/lib/hooks/useIsMount.js +9 -0
- package/lib/hooks/useIsMount.js.map +1 -0
- package/lib/hooks/useScrolltoTop.d.ts.map +1 -1
- package/lib/mediaco/ToDo/ToDo.css +81 -0
- package/lib/mediaco/ToDo/ToDo.d.ts +16 -0
- package/lib/mediaco/ToDo/ToDo.d.ts.map +1 -0
- package/lib/mediaco/ToDo/ToDo.js +187 -0
- package/lib/mediaco/ToDo/ToDo.js.map +1 -0
- package/lib/mediaco/ToDo/index.d.ts +2 -0
- package/lib/mediaco/ToDo/index.d.ts.map +1 -0
- package/lib/mediaco/ToDo/index.js +2 -0
- package/lib/mediaco/ToDo/index.js.map +1 -0
- package/lib/samples/Embedded/styles.css +26 -0
- package/lib/sdk-pega-component-map.d.ts +119 -103
- package/lib/sdk-pega-component-map.d.ts.map +1 -1
- package/lib/sdk-pega-component-map.js +20 -3
- package/lib/sdk-pega-component-map.js.map +1 -1
- package/lib/theme.d.ts +30 -1
- package/lib/theme.d.ts.map +1 -1
- package/lib/theme.js +209 -2
- package/lib/theme.js.map +1 -1
- package/lib/types/PConnProps.d.ts +1 -1
- package/package.json +32 -1
- package/lib/components/helpers/attachmentHelpers.d.ts +0 -13
- package/lib/components/helpers/attachmentHelpers.d.ts.map +0 -1
- package/lib/components/helpers/attachmentHelpers.js +0 -72
- package/lib/components/helpers/attachmentHelpers.js.map +0 -1
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
.tox .tox-toolbar {
|
|
2
|
+
background-color: var(--app-background-color) !important;
|
|
3
|
+
}
|
|
4
|
+
|
|
5
|
+
.tox .tox-toolbar__primary {
|
|
6
|
+
background-color: var(--app-background-color) !important;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
.tox .tox-toolbar__button {
|
|
10
|
+
color: var(--app-text-color) !important;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.tox .tox-toolbar__button--enabled {
|
|
14
|
+
background: var(--app-primary-color) !important;
|
|
15
|
+
color: #fff !important;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
.tox .tox-dialog {
|
|
19
|
+
background-color: var(--modal-top-color) !important;
|
|
20
|
+
color: var(--app-text-color) !important;
|
|
21
|
+
border: 1px solid var(--modal-border-color) !important;
|
|
22
|
+
padding: 20px !important;
|
|
23
|
+
box-shadow: 0 0 10px 3px var(--modal-box-shadow-color) !important;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
.tox .tox-dialog__header {
|
|
27
|
+
background-color: var(--modal-top-color) !important;
|
|
28
|
+
color: var(--app-text-color) !important;
|
|
29
|
+
font-weight: 500;
|
|
30
|
+
border-bottom: 1px solid var(--modal-border-color);
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
.tox .tox-dialog__footer {
|
|
34
|
+
background: transparent !important;
|
|
35
|
+
border-top: 1px solid var(--modal-border-color);
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.tox .tox-dialog-wrap__backdrop {
|
|
39
|
+
background-color: var(--modal-background-color) !important;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
.tox .tox-dialog__body input,
|
|
43
|
+
.tox .tox-dialog__body textarea,
|
|
44
|
+
.tox .tox-dialog__body select {
|
|
45
|
+
background: initial !important;
|
|
46
|
+
color: var(--app-text-color) !important;
|
|
47
|
+
border: 1px solid var(--app-neutral-color) !important;
|
|
48
|
+
border-radius: 4px !important;
|
|
49
|
+
padding: 6px 10px !important;
|
|
50
|
+
font-size: 1em !important;
|
|
51
|
+
font-family: inherit !important;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
.tox .tox-dialog__body button {
|
|
55
|
+
background: transparent;
|
|
56
|
+
color: #fff !important;
|
|
57
|
+
border: none !important;
|
|
58
|
+
border-radius: 4px !important;
|
|
59
|
+
padding: 8px 16px !important;
|
|
60
|
+
font-size: 1em !important;
|
|
61
|
+
cursor: pointer !important;
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
.tox .tox-dialog__footer .tox-button {
|
|
65
|
+
background: var(--app-primary-color) !important;
|
|
66
|
+
color: #fff !important;
|
|
67
|
+
border: none !important;
|
|
68
|
+
border-radius: 4px !important;
|
|
69
|
+
padding: 8px 16px !important;
|
|
70
|
+
font-size: 1em !important;
|
|
71
|
+
cursor: pointer !important;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
.tox .tox-dialog__footer .tox-button--secondary {
|
|
75
|
+
background: var(--app-secondary-color) !important;
|
|
76
|
+
color: var(--secondary-button-text-color) !important;
|
|
77
|
+
font-size: 0.875rem !important;
|
|
78
|
+
cursor: pointer !important;
|
|
79
|
+
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RichText.d.ts","sourceRoot":"","sources":["../../../../src/components/field/RichText/RichText.tsx"],"names":[],"mappings":"AAIA,OAAO,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAC;
|
|
1
|
+
{"version":3,"file":"RichText.d.ts","sourceRoot":"","sources":["../../../../src/components/field/RichText/RichText.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAC;AAEjE,OAAO,gBAAgB,CAAC;AAExB,UAAU,aAAc,SAAQ,eAAe;IAE7C,eAAe,CAAC,EAAE,MAAM,CAAC;CAC1B;AAED,MAAM,CAAC,OAAO,UAAU,QAAQ,CAAC,KAAK,EAAE,aAAa,OAoFpD"}
|
|
@@ -2,6 +2,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
2
2
|
import { useRef } from 'react';
|
|
3
3
|
import handleEvent from '../../helpers/event-utils';
|
|
4
4
|
import { getComponentFromMap } from '../../../bridge/helpers/sdk_component_map';
|
|
5
|
+
import './RichText.css';
|
|
5
6
|
export default function RichText(props) {
|
|
6
7
|
// Get emitted components from map (so we can get any override that may exist)
|
|
7
8
|
const FieldValueList = getComponentFromMap('FieldValueList');
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RichText.js","sourceRoot":"","sources":["../../../../src/components/field/RichText/RichText.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,OAAO,CAAC;AAE/B,OAAO,WAAW,MAAM,2BAA2B,CAAC;AACpD,OAAO,EAAE,mBAAmB,EAAE,MAAM,2CAA2C,CAAC;
|
|
1
|
+
{"version":3,"file":"RichText.js","sourceRoot":"","sources":["../../../../src/components/field/RichText/RichText.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,OAAO,CAAC;AAE/B,OAAO,WAAW,MAAM,2BAA2B,CAAC;AACpD,OAAO,EAAE,mBAAmB,EAAE,MAAM,2CAA2C,CAAC;AAGhF,OAAO,gBAAgB,CAAC;AAOxB,MAAM,CAAC,OAAO,UAAU,QAAQ,CAAC,KAAoB;IACnD,8EAA8E;IAC9E,MAAM,cAAc,GAAG,mBAAmB,CAAC,gBAAgB,CAAC,CAAC;IAC7D,MAAM,cAAc,GAAG,mBAAmB,CAAC,gBAAgB,CAAC,CAAC;IAE7D,MAAM,EAAE,WAAW,EAAE,KAAK,EAAE,WAAW,EAAE,eAAe,EAAE,KAAK,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,EAAE,WAAW,EAAE,eAAe,EAAE,GAAG,KAAK,CAAC;IACvI,MAAM,KAAK,GAAG,WAAW,EAAE,CAAC;IAC5B,MAAM,SAAS,GAAQ,MAAM,CAAC,IAAI,CAAC,CAAC;IAEpC,IAAI,EAAE,QAAQ,EAAE,QAAQ,EAAE,QAAQ,EAAE,GAAG,KAAK,CAAC;IAC7C,CAAC,QAAQ,EAAE,QAAQ,EAAE,QAAQ,CAAC,GAAG,CAAC,QAAQ,EAAE,QAAQ,EAAE,QAAQ,CAAC,CAAC,GAAG,CAAC,IAAI,CAAC,EAAE,CAAC,IAAI,KAAK,IAAI,IAAI,CAAC,OAAO,IAA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Q;oBACR,QAAQ,EAAE,EAAE;oBACZ,OAAO,EAAE,EAAE;iBACZ,CAAC,CAAC;YACL,CAAC;QACH,CAAC,CAAC;QAEF,MAAM,UAAU,GAAG,GAAG,EAAE;YACtB,IAAI,SAAS,CAAC,OAAO,EAAE,CAAC;gBACtB,MAAM,WAAW,GAAG,SAAS,CAAC,OAAO,CAAC,UAAU,CAAC,EAAE,MAAM,EAAE,MAAM,EAAE,CAAC,CAAC;gBACrE,MAAM,QAAQ,GAAI,KAAK,CAAC,aAAa,EAAU,CAAC,KAAK,CAAC;gBACtD,WAAW,CAAC,UAAU,EAAE,aAAa,EAAE,QAAQ,EAAE,WAAW,CAAC,CAAC;YAChE,CAAC;QACH,CAAC,CAAC;QAEF,iBAAiB,GAAG,CAClB,KAAC,cAAc,OACT,eAAe,EACnB,KAAK,EAAE,KAAK,EACZ,WAAW,EAAE,SAAS,EACtB,IAAI,EAAE,mBAAmB,EACzB,YAAY,EAAE,KAAK,EACnB,WAAW,EAAE,WAAW,EACxB,QAAQ,EAAE,QAAQ,EAClB,QAAQ,EAAE,QAAQ,EAClB,MAAM,EAAE,MAAM,EACd,GAAG,EAAE,SAAS,EACd,KAAK,EAAE,MAAM,KAAK,OAAO,EACzB,MAAM,EAAE,UAAU,EAClB,QAAQ,EAAE,YAAY,GACtB,CACH,CAAC;IACJ,CAAC;IAED,OAAO,iBAAiB,CAAC;AAC3B,CAAC","sourcesContent":["import { useRef } from 'react';\n\nimport handleEvent from '../../helpers/event-utils';\nimport { getComponentFromMap } from '../../../bridge/helpers/sdk_component_map';\nimport type { PConnFieldProps } from '../../../types/PConnProps';\n\nimport './RichText.css';\n\ninterface RichTextProps extends PConnFieldProps {\n // If any, enter additional props that only exist on TextArea here\n additionalProps?: object;\n}\n\nexport default function RichText(props: RichTextProps) {\n // Get emitted components from map (so we can get any override that may exist)\n const FieldValueList = getComponentFromMap('FieldValueList');\n const RichTextEditor = getComponentFromMap('RichTextEditor');\n\n const { getPConnect, value, placeholder, validatemessage, label, hideLabel, helperText, testId, displayMode, additionalProps } = props;\n const pConn = getPConnect();\n const editorRef: any = useRef(null);\n\n let { readOnly, required, disabled } = props;\n [readOnly, required, disabled] = [readOnly, required, disabled].map(prop => prop === true || (typeof prop === 'string' && prop === 'true'));\n\n const helperTextToDisplay = validatemessage || helperText;\n\n if (displayMode === 'DISPLAY_ONLY') {\n return <FieldValueList name={hideLabel ? '' : label} value={value} isHtml />;\n }\n\n if (displayMode === 'STACKED_LARGE_VAL') {\n return <FieldValueList name={hideLabel ? '' : label} value={value} isHtml variant='stacked' />;\n }\n\n let richTextComponent;\n\n if (readOnly) {\n // Rich Text read-only component\n richTextComponent = (\n <RichTextEditor\n {...additionalProps}\n label={label}\n labelHidden={hideLabel}\n defaultValue={value}\n testId={testId}\n info={helperTextToDisplay}\n ref={editorRef}\n readOnly\n />\n );\n } else {\n // Rich Text editable component\n const actionsApi = pConn.getActionsApi();\n let status = '';\n if (validatemessage !== '') {\n status = 'error';\n }\n const handleChange = () => {\n if (status === 'error') {\n const property = (pConn.getStateProps() as any).value;\n pConn.clearErrorMessages({\n property,\n category: '',\n context: ''\n });\n }\n };\n\n const handleBlur = () => {\n if (editorRef.current) {\n const editorValue = editorRef.current.getContent({ format: 'html' });\n const property = (pConn.getStateProps() as any).value;\n handleEvent(actionsApi, 'changeNblur', property, editorValue);\n }\n };\n\n richTextComponent = (\n <RichTextEditor\n {...additionalProps}\n label={label}\n labelHidden={hideLabel}\n info={helperTextToDisplay}\n defaultValue={value}\n placeholder={placeholder}\n disabled={disabled}\n required={required}\n testId={testId}\n ref={editorRef}\n error={status === 'error'}\n onBlur={handleBlur}\n onChange={handleChange}\n />\n );\n }\n\n return richTextComponent;\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ScalarList.d.ts","sourceRoot":"","sources":["../../../../src/components/field/ScalarList/ScalarList.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ScalarList.d.ts","sourceRoot":"","sources":["../../../../src/components/field/ScalarList/ScalarList.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,2BAA2B,CAAC;AAG5D,UAAU,eAAgB,SAAQ,UAAU;IAE1C,cAAc,EAAE,OAAO,CAAC;IACxB,SAAS,EAAE,OAAO,CAAC;IACnB,KAAK,EAAE,GAAG,EAAE,CAAC;IACb,aAAa,EAAE,MAAM,CAAC;IACtB,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;CACrB;AAcD,MAAM,CAAC,OAAO,UAAU,UAAU,CAAC,KAAK,EAAE,eAAe,2CAoCxD"}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
/* eslint-disable react/no-array-index-key */
|
|
3
2
|
import { getComponentFromMap } from '../../../bridge/helpers/sdk_component_map';
|
|
4
3
|
function CommaSeparatedList(props) {
|
|
5
4
|
const { items } = props;
|
|
@@ -22,7 +21,7 @@ export default function ScalarList(props) {
|
|
|
22
21
|
readOnly: 'true'
|
|
23
22
|
}
|
|
24
23
|
}, '',
|
|
25
|
-
// @ts-
|
|
24
|
+
// @ts-expect-error
|
|
26
25
|
'', {}); // 2nd, 3rd, and 4th args empty string/object/null until typedef marked correctly as optional;
|
|
27
26
|
});
|
|
28
27
|
if (['STACKED_LARGE_VAL', 'DISPLAY_ONLY'].includes(displayMode)) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ScalarList.js","sourceRoot":"","sources":["../../../../src/components/field/ScalarList/ScalarList.tsx"],"names":[],"mappings":";AAAA,
|
|
1
|
+
{"version":3,"file":"ScalarList.js","sourceRoot":"","sources":["../../../../src/components/field/ScalarList/ScalarList.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,mBAAmB,EAAE,MAAM,2CAA2C,CAAC;AAchF,SAAS,kBAAkB,CAAC,KAAK;IAC/B,MAAM,EAAE,KAAK,EA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AAE,CAAC,CAAC,CAAC,KAAK,EAAE,KAAK,EAAE,WAAW,EAAE,OAAO,EAAC,SAAS,GAAG,CAAC;AAChG,CAAC","sourcesContent":["import { getComponentFromMap } from '../../../bridge/helpers/sdk_component_map';\nimport type { PConnProps } from '../../../types/PConnProps';\n\n// ScalarListProps can't extend PConnFieldProps because its 'value' has a different type\ninterface ScalarListProps extends PConnProps {\n // If any, enter additional props that only exist on this component\n displayInModal: boolean;\n hideLabel: boolean;\n value: any[];\n componentType: string;\n label: string;\n displayMode: string;\n}\n\nfunction CommaSeparatedList(props) {\n const { items } = props;\n\n return (\n <ul style={{ padding: '0', margin: '0' }}>\n {items.map((value, index) => {\n return <span key={index}>{value}</span>;\n })}\n </ul>\n );\n}\n\nexport default function ScalarList(props: ScalarListProps) {\n // Get emitted components from map (so we can get any override that may exist)\n const FieldValueList = getComponentFromMap('FieldValueList');\n\n const { label, getPConnect, componentType, value: scalarValues, displayMode, hideLabel, ...restProps } = props;\n\n const items = scalarValues?.map(scalarValue => {\n return getPConnect().createComponent(\n {\n type: componentType,\n config: {\n value: scalarValue,\n displayMode: 'DISPLAY_ONLY',\n label,\n ...restProps,\n readOnly: 'true'\n }\n },\n '',\n // @ts-expect-error\n '',\n {}\n ); // 2nd, 3rd, and 4th args empty string/object/null until typedef marked correctly as optional;\n });\n\n if (['STACKED_LARGE_VAL', 'DISPLAY_ONLY'].includes(displayMode)) {\n return (\n <div>\n <CommaSeparatedList items={items} />\n </div>\n );\n }\n\n const displayComp = <CommaSeparatedList items={items} />;\n\n return <FieldValueList name={hideLabel ? '' : label} value={displayComp} variant='stacked' />;\n}\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SelectableCard.d.ts","sourceRoot":"","sources":["../../../../src/components/field/SelectableCard/SelectableCard.tsx"],"names":[],"mappings":"AAGA,MAAM,CAAC,OAAO,UAAU,cAAc,CAAC,KAAK,KAAA,2CA2K3C"}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
|
+
import { Radio, Checkbox, FormControlLabel, Card, CardContent, Typography } from '@mui/material';
|
|
3
|
+
import { resolveReferenceFields } from './utils';
|
|
4
|
+
export default function SelectableCard(props) {
|
|
5
|
+
const { getPConnect, type, image: { imagePosition, imageSize, showImageDescription, imageField = '', imageDescription = '' }, dataSource, recordKey = '', className, cardLabel, hideFieldLabels = false, readOnly, disabled, readOnlyList = [], displayMode, radioBtnValue, onChange, onBlur, onClick, onKeyDown, additionalProps, testId, setIsRadioCardSelected, showNoValue = false } = props;
|
|
6
|
+
const pConn = getPConnect();
|
|
7
|
+
if (showNoValue)
|
|
8
|
+
return _jsx(Typography, { children: "No Value" });
|
|
9
|
+
const cardDataSource = readOnly || displayMode === 'DISPLAY_ONLY' ? readOnlyList || [] : dataSource?.source;
|
|
10
|
+
const imageDescriptionKey = showImageDescription ? imageDescription : undefined;
|
|
11
|
+
let radioItemSelected = false;
|
|
12
|
+
return (_jsxs(_Fragment, { children: [(cardDataSource || []).map(item => {
|
|
13
|
+
const resolvedFields = resolveReferenceFields(item, hideFieldLabels, recordKey, pConn);
|
|
14
|
+
const commonProps = {
|
|
15
|
+
id: item[recordKey],
|
|
16
|
+
key: item[recordKey],
|
|
17
|
+
fields: resolvedFields,
|
|
18
|
+
label: item[cardLabel]
|
|
19
|
+
};
|
|
20
|
+
const image = item[imageField]
|
|
21
|
+
? {
|
|
22
|
+
src: item[imageField],
|
|
23
|
+
alt: showImageDescription && imageDescriptionKey ? item[imageDescriptionKey] : '',
|
|
24
|
+
style: { width: imageSize, objectPosition: imagePosition }
|
|
25
|
+
}
|
|
26
|
+
: undefined;
|
|
27
|
+
const cardContent = (_jsxs(Card, { className: className, style: { display: 'flex' }, "data-testid": testId, children: [image && _jsx("img", { src: image.src, alt: image.alt, style: { width: '100px' } }), _jsxs(CardContent, { children: [_jsx(Typography, { variant: 'body1', children: item[cardLabel] }), commonProps.fields.map((field, index) => (_jsx(Typography, { variant: 'body2', children: field.value }, index)))] })] }));
|
|
28
|
+
if (displayMode === 'DISPLAY_ONLY') {
|
|
29
|
+
return cardContent;
|
|
30
|
+
}
|
|
31
|
+
const component = (_jsx("div", { style: { paddingTop: '15px' }, children: _jsx(Card, { className: className, style: { display: 'flex', flexDirection: 'column', height: '100%' }, "data-testid": testId, children: _jsxs(CardContent, { style: {
|
|
32
|
+
...((imagePosition === 'inline-start' || imagePosition === 'inline-end') && { display: 'flex', height: '100%' }),
|
|
33
|
+
...(imagePosition === 'inline-end' && { flexDirection: 'row-reverse' })
|
|
34
|
+
}, children: [_jsx("div", { style: {
|
|
35
|
+
...((imagePosition === 'inline-start' || imagePosition === 'inline-end') && { width: '40%' })
|
|
36
|
+
}, children: image && (_jsx("img", { src: image.src, alt: image.alt, style: {
|
|
37
|
+
width: '100%',
|
|
38
|
+
backgroundColor: 'transparent',
|
|
39
|
+
aspectRatio: '16 / 9',
|
|
40
|
+
maxHeight: '100%',
|
|
41
|
+
height: '100%',
|
|
42
|
+
objectFit: 'contain',
|
|
43
|
+
maxWidth: '100%'
|
|
44
|
+
} })) }), _jsxs("div", { style: {
|
|
45
|
+
...((imagePosition === 'inline-start' || imagePosition === 'inline-end') && { width: '60%' })
|
|
46
|
+
}, children: [type === 'radio' ? (_jsx(FormControlLabel, { control: _jsx(Radio, { value: item[recordKey], checked: radioBtnValue === item[recordKey], onChange: onChange, onBlur: onBlur, onClick: onClick, onKeyDown: onKeyDown, disabled: disabled, ...additionalProps }), label: _jsx(Typography, { variant: 'body1', children: item[cardLabel] }) })) : (_jsx(FormControlLabel, { control: _jsx(Checkbox, { id: item[recordKey], getPConnect: getPConnect, checked: readOnlyList.some(data => data[recordKey] === item[recordKey]), onChange: onChange, onBlur: onBlur, onClick: onClick, onKeyDown: onKeyDown, disabled: disabled, ...additionalProps }), label: _jsx(Typography, { variant: 'body1', children: item[cardLabel] }) })), commonProps.fields.map((field, index) => (_jsxs("div", { style: {
|
|
47
|
+
fontSize: '0.875rem',
|
|
48
|
+
...(field.type !== 'TextArea' && { display: 'grid', gridTemplateColumns: '1fr 1fr' }),
|
|
49
|
+
margin: '5px'
|
|
50
|
+
}, children: [field.name && _jsx("div", { children: field.name }), _jsx("div", { children: field?.value?.props.value })] }, index)))] })] }) }) }, item[recordKey]));
|
|
51
|
+
if (type === 'radio' && radioBtnValue === item[recordKey]) {
|
|
52
|
+
radioItemSelected = true;
|
|
53
|
+
}
|
|
54
|
+
return component;
|
|
55
|
+
}), type === 'radio' && setIsRadioCardSelected && setIsRadioCardSelected(radioItemSelected)] }));
|
|
56
|
+
}
|
|
57
|
+
//# sourceMappingURL=SelectableCard.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SelectableCard.js","sourceRoot":"","sources":["../../../../src/components/field/SelectableCard/SelectableCard.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,KAAK,EAAE,QAAQ,EAAE,gBAAgB,EAAE,IAAI,EAAE,WAAW,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AACjG,OAAO,EAAE,sBAAsB,EAAE,MAAM,SAAS,CAAC;AAEjD,MAAM,CAAC,OAAO,UAAU,cAAc,CAAC,KAAK;IAC1C,MAAM,EACJ,WAAW,EACX,IAAI,EACJ,KAAK,EAAE,EAAE,aAAa,EAAE,SAAS,EAAE,oBAAoB,EAAE,UAAU,GAAG,EAAE,EAAE,gBAAgB,GAAG,EAAE,EAAE,EACjG,UAAU,EACV,SAAS,GAAG,EAAE,EACd,SAAS,EACT,SAAS,EACT,eAAe,GAAG,KAAK,EACvB,QAAQ,EACR,QAAQ,EACR,YAAY,GAAG,EAAE,EACjB,WAAW,EACX,aAAa,EACb,QAAQ,EACR,MAAM,EACN,OAAO,EACP,SAAS,EACT,eAAe,EACf,MAAM,EACN,sBAAsB,EACtB,WAAW,GAAG,KAAK,EACpB,GAAG,KAAK,CAAC;IAEV,MAAM,KAAK,GAAG,W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AAS,CAAC,GAAc,GACjE,CACH,EAEA,WAAW,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,KAAK,EAAE,KAAK,EAAE,EAAE,CAAC,CACxC,eAEE,KAAK,EAAE;gDACL,QAAQ,EAAE,UAAU;gDACpB,GAAG,CAAC,KAAK,CAAC,IAAI,KAAK,UAAU,IAAI,EAAE,OAAO,EAAE,MAAM,EAAE,mBAAmB,EAAE,SAAS,EAAE,CAAC;gDACrF,MAAM,EAAE,KAAK;6CACd,aAEA,KAAK,CAAC,IAAI,IAAI,wBAAM,KAAK,CAAC,IAAI,GAAO,EACtC,wBAAM,KAAK,EAAE,KAAK,EAAE,KAAK,CAAC,KAAK,GAAO,KARjC,KAAK,CASN,CACP,CAAC,IACE,IACM,GACT,IApFC,IAAI,CAAC,SAAS,CAAC,CAqFnB,CACP,CAAC;gBAEF,IAAI,IAAI,KAAK,OAAO,IAAI,aAAa,KAAK,IAAI,CAAC,SAAS,CAAC,EAAE,CAAC;oBAC1D,iBAAiB,GAAG,IAAI,CAAC;gBAC3B,CAAC;gBAED,OAAO,SAAS,CAAC;YACnB,CAAC,CAAC,EAED,IAAI,KAAK,OAAO,IAAI,sBAAsB,IAAI,sBAAsB,CAAC,iBAAiB,CAAC,IACvF,CACJ,CAAC;AACJ,CAAC","sourcesContent":["import { Radio, Checkbox, FormControlLabel, Card, CardContent, Typography } from '@mui/material';\nimport { resolveReferenceFields } from './utils';\n\nexport default function SelectableCard(props) {\n const {\n getPConnect,\n type,\n image: { imagePosition, imageSize, showImageDescription, imageField = '', imageDescription = '' },\n dataSource,\n recordKey = '',\n className,\n cardLabel,\n hideFieldLabels = false,\n readOnly,\n disabled,\n readOnlyList = [],\n displayMode,\n radioBtnValue,\n onChange,\n onBlur,\n onClick,\n onKeyDown,\n additionalProps,\n testId,\n setIsRadioCardSelected,\n showNoValue = false\n } = props;\n\n const pConn = getPConnect();\n\n if (showNoValue) return <Typography>No Value</Typography>;\n\n const cardDataSource = readOnly || displayMode === 'DISPLAY_ONLY' ? readOnlyList || [] : dataSource?.source;\n const imageDescriptionKey = showImageDescription ? imageDescription : undefined;\n\n let radioItemSelected = false;\n\n return (\n <>\n {(cardDataSource || []).map(item => {\n const resolvedFields = resolveReferenceFields(item, hideFieldLabels, recordKey, pConn);\n\n const commonProps = {\n id: item[recordKey],\n key: item[recordKey],\n fields: resolvedFields,\n label: item[cardLabel]\n };\n\n const image = item[imageField]\n ? {\n src: item[imageField],\n alt: showImageDescription && imageDescriptionKey ? item[imageDescriptionKey] : '',\n style: { width: imageSize, objectPosition: imagePosition }\n }\n : undefined;\n\n const cardContent = (\n <Card className={className} style={{ display: 'flex' }} data-testid={testId}>\n {image && <img src={image.src} alt={image.alt} style={{ width: '100px' }} />}\n <CardContent>\n <Typography variant='body1'>{item[cardLabel]}</Typography>\n {commonProps.fields.map((field, index) => (\n <Typography key={index} variant='body2'>\n {field.value}\n </Typography>\n ))}\n </CardContent>\n </Card>\n );\n\n if (displayMode === 'DISPLAY_ONLY') {\n return cardContent;\n }\n\n const component = (\n <div key={item[recordKey]} style={{ paddingTop: '15px' }}>\n <Card className={className} style={{ display: 'flex', flexDirection: 'column', height: '100%' }} data-testid={testId}>\n <CardContent\n style={{\n ...((imagePosition === 'inline-start' || imagePosition === 'inline-end') && { display: 'flex', height: '100%' }),\n ...(imagePosition === 'inline-end' && { flexDirection: 'row-reverse' })\n }}\n >\n <div\n style={{\n ...((imagePosition === 'inline-start' || imagePosition === 'inline-end') && { width: '40%' })\n }}\n >\n {image && (\n <img\n src={image.src}\n alt={image.alt}\n style={{\n width: '100%',\n backgroundColor: 'transparent',\n aspectRatio: '16 / 9',\n maxHeight: '100%',\n height: '100%',\n objectFit: 'contain',\n maxWidth: '100%'\n }}\n />\n )}\n </div>\n <div\n style={{\n ...((imagePosition === 'inline-start' || imagePosition === 'inline-end') && { width: '60%' })\n }}\n >\n {type === 'radio' ? (\n <FormControlLabel\n control={\n <Radio\n value={item[recordKey]}\n checked={radioBtnValue === item[recordKey]}\n onChange={onChange}\n onBlur={onBlur}\n onClick={onClick}\n onKeyDown={onKeyDown}\n disabled={disabled}\n {...additionalProps}\n />\n }\n label={<Typography variant='body1'>{item[cardLabel]}</Typography>}\n />\n ) : (\n <FormControlLabel\n control={\n <Checkbox\n id={item[recordKey]}\n getPConnect={getPConnect}\n checked={readOnlyList.some(data => data[recordKey] === item[recordKey])}\n onChange={onChange}\n onBlur={onBlur}\n onClick={onClick}\n onKeyDown={onKeyDown}\n disabled={disabled}\n {...additionalProps}\n />\n }\n label={<Typography variant='body1'>{item[cardLabel]}</Typography>}\n />\n )}\n\n {commonProps.fields.map((field, index) => (\n <div\n key={index}\n style={{\n fontSize: '0.875rem',\n ...(field.type !== 'TextArea' && { display: 'grid', gridTemplateColumns: '1fr 1fr' }),\n margin: '5px'\n }}\n >\n {field.name && <div>{field.name}</div>}\n <div>{field?.value?.props.value}</div>\n </div>\n ))}\n </div>\n </CardContent>\n </Card>\n </div>\n );\n\n if (type === 'radio' && radioBtnValue === item[recordKey]) {\n radioItemSelected = true;\n }\n\n return component;\n })}\n\n {type === 'radio' && setIsRadioCardSelected && setIsRadioCardSelected(radioItemSelected)}\n </>\n );\n}\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/field/SelectableCard/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/components/field/SelectableCard/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC","sourcesContent":["export { default } from './SelectableCard';\n"]}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export declare const resolveReferencedPConnect: (pConnect: any) => any;
|
|
2
|
+
/**
|
|
3
|
+
* A helper function to create an object consisting react component as per the type.
|
|
4
|
+
* This is used by CaseSummary template.
|
|
5
|
+
* @param {object} pConnectMeta Object containing meta information for the particular field authored
|
|
6
|
+
* @param {Function} getPConnect PConnect function passed along to other components.
|
|
7
|
+
* @param {string} displayMode displayMode string contains information about the layout of component in review mode.
|
|
8
|
+
*/
|
|
9
|
+
export declare function prepareComponentInCaseSummary(pConnectMeta: any, getPConnect: Function): any;
|
|
10
|
+
export declare function resolveReferenceFields(item: {
|
|
11
|
+
[key: string]: unknown;
|
|
12
|
+
}, hideFieldLabels: boolean, recordKey: string, pConnect: typeof PConnect): any;
|
|
13
|
+
//# sourceMappingURL=utils.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../../src/components/field/SelectableCard/utils.tsx"],"names":[],"mappings":"AAIA,eAAO,MAAM,yBAAyB,GAAG,aAAQ,QAKhD,CAAC;AAEF;;;;;;GAMG;AACH,wBAAgB,6BAA6B,CAAC,YAAY,EAAE,GAAG,EAAE,WAAW,EAAE,QAAQ,OA0JrF;AAED,wBAAgB,sBAAsB,CACpC,IAAI,EAAE;IACJ,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC;CACxB,EACD,eAAe,EAAE,OAAO,EACxB,SAAS,EAAE,MAAM,EACjB,QAAQ,EAAE,OAAO,QAAQ,OA0C1B"}
|
|
@@ -0,0 +1,183 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { Link } from '@mui/material';
|
|
3
|
+
import { Utils } from '../../helpers/utils';
|
|
4
|
+
export const resolveReferencedPConnect = pConnect => {
|
|
5
|
+
if (!pConnect || !pConnect.meta)
|
|
6
|
+
return undefined;
|
|
7
|
+
const type = pConnect?._type ?? undefined;
|
|
8
|
+
const referencedPConnect = type === 'reference' && pConnect.getReferencedViewPConnect().getPConnect();
|
|
9
|
+
return referencedPConnect || pConnect;
|
|
10
|
+
};
|
|
11
|
+
/**
|
|
12
|
+
* A helper function to create an object consisting react component as per the type.
|
|
13
|
+
* This is used by CaseSummary template.
|
|
14
|
+
* @param {object} pConnectMeta Object containing meta information for the particular field authored
|
|
15
|
+
* @param {Function} getPConnect PConnect function passed along to other components.
|
|
16
|
+
* @param {string} displayMode displayMode string contains information about the layout of component in review mode.
|
|
17
|
+
*/
|
|
18
|
+
export function prepareComponentInCaseSummary(pConnectMeta, getPConnect) {
|
|
19
|
+
const { config, children } = pConnectMeta;
|
|
20
|
+
const noValueComponent = _jsx("div", { children: "No Value" });
|
|
21
|
+
const placeholder = '...';
|
|
22
|
+
const pConnect = getPConnect();
|
|
23
|
+
const caseSummaryComponentObject = {};
|
|
24
|
+
let { type } = pConnectMeta;
|
|
25
|
+
let showAddressLabel = true;
|
|
26
|
+
if (config && config.value === `@P .${Utils.getMappedKey('pyStatusWork')}`) {
|
|
27
|
+
config.displayAsStatus = true;
|
|
28
|
+
type = 'TextInput'; // force the type to be TextInput for status field.
|
|
29
|
+
// As TextInput is loaded forcefully sometimes, TextInput component might not be available in lazy map.
|
|
30
|
+
// Load TextInput if it is not available.
|
|
31
|
+
if (!PCore.getComponentsRegistry().getLazyComponent(type)) {
|
|
32
|
+
PCore.getAssetLoader().getLoader('component-loader')([type]);
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
caseSummaryComponentObject.name = pConnect.resolveConfigProps({ label: config.label }).label;
|
|
36
|
+
if (config.inheritedProps) {
|
|
37
|
+
const labelInInheritedProp = config.inheritedProps.find(inheritedProp => inheritedProp.prop === 'label');
|
|
38
|
+
if (labelInInheritedProp) {
|
|
39
|
+
labelInInheritedProp.value = pConnect.resolveConfigProps({ label: labelInInheritedProp.value }).label;
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
switch (type) {
|
|
43
|
+
case 'CaseOperator': {
|
|
44
|
+
if (config.label.includes('Create operator')) {
|
|
45
|
+
caseSummaryComponentObject.name = pConnect.resolveConfigProps({
|
|
46
|
+
createLabel: config.createLabel
|
|
47
|
+
}).createLabel;
|
|
48
|
+
}
|
|
49
|
+
else if (config.label.includes('Update operator')) {
|
|
50
|
+
caseSummaryComponentObject.name = pConnect.resolveConfigProps({
|
|
51
|
+
updateLabel: config.updateLabel
|
|
52
|
+
}).updateLabel;
|
|
53
|
+
}
|
|
54
|
+
else {
|
|
55
|
+
caseSummaryComponentObject.name = pConnect.resolveConfigProps({
|
|
56
|
+
resolveLabel: config.resolveLabel
|
|
57
|
+
}).resolveLabel;
|
|
58
|
+
}
|
|
59
|
+
break;
|
|
60
|
+
}
|
|
61
|
+
case 'Checkbox': {
|
|
62
|
+
caseSummaryComponentObject.name = pConnect.resolveConfigProps({
|
|
63
|
+
label: config.caption
|
|
64
|
+
}).label;
|
|
65
|
+
break;
|
|
66
|
+
}
|
|
67
|
+
case 'Pega_UI_PercentageWidget': {
|
|
68
|
+
const rawValue = pConnect.resolveConfigProps({
|
|
69
|
+
value: config.value
|
|
70
|
+
}).value;
|
|
71
|
+
caseSummaryComponentObject.simpleValue = rawValue || rawValue === 0 ? `${rawValue}%` : noValueComponent;
|
|
72
|
+
break;
|
|
73
|
+
}
|
|
74
|
+
case 'Address': {
|
|
75
|
+
showAddressLabel = false;
|
|
76
|
+
caseSummaryComponentObject.variant = 'stacked';
|
|
77
|
+
break;
|
|
78
|
+
}
|
|
79
|
+
case 'Location':
|
|
80
|
+
case 'RichText': {
|
|
81
|
+
const rawValue = pConnect.resolveConfigProps({
|
|
82
|
+
value: config.value
|
|
83
|
+
}).value;
|
|
84
|
+
caseSummaryComponentObject.variant = 'stacked';
|
|
85
|
+
caseSummaryComponentObject.simpleValue = rawValue?.length ? rawValue : noValueComponent;
|
|
86
|
+
break;
|
|
87
|
+
}
|
|
88
|
+
case 'TextArea': {
|
|
89
|
+
const rawValue = pConnect.resolveConfigProps({
|
|
90
|
+
value: config.value
|
|
91
|
+
}).value;
|
|
92
|
+
if (rawValue?.length > 22) {
|
|
93
|
+
caseSummaryComponentObject.variant = 'stacked';
|
|
94
|
+
}
|
|
95
|
+
caseSummaryComponentObject.simpleValue = rawValue?.length ? rawValue : noValueComponent;
|
|
96
|
+
break;
|
|
97
|
+
}
|
|
98
|
+
case 'URL': {
|
|
99
|
+
if (config.displayAs === 'Image') {
|
|
100
|
+
const rawValue = pConnect.resolveConfigProps({
|
|
101
|
+
value: config.value
|
|
102
|
+
}).value;
|
|
103
|
+
caseSummaryComponentObject.variant = 'stacked';
|
|
104
|
+
caseSummaryComponentObject.simpleValue = rawValue?.length ? _jsx(Link, { href: rawValue, children: rawValue }) : noValueComponent;
|
|
105
|
+
}
|
|
106
|
+
break;
|
|
107
|
+
}
|
|
108
|
+
case 'reference': {
|
|
109
|
+
const referencedPConnect = resolveReferencedPConnect(pConnect);
|
|
110
|
+
const viewType = referencedPConnect?.meta?.config.type;
|
|
111
|
+
const viewTemplate = referencedPConnect?.meta?.config.template;
|
|
112
|
+
const isTable = ['multirecordlist'].includes(viewType);
|
|
113
|
+
const isDataReference = viewTemplate === 'DataReference';
|
|
114
|
+
if (isTable || !isDataReference) {
|
|
115
|
+
caseSummaryComponentObject.variant = 'stacked';
|
|
116
|
+
caseSummaryComponentObject.simpleValue = placeholder;
|
|
117
|
+
}
|
|
118
|
+
break;
|
|
119
|
+
}
|
|
120
|
+
case 'view': {
|
|
121
|
+
caseSummaryComponentObject.variant = 'stacked';
|
|
122
|
+
caseSummaryComponentObject.simpleValue = placeholder;
|
|
123
|
+
break;
|
|
124
|
+
}
|
|
125
|
+
default:
|
|
126
|
+
break;
|
|
127
|
+
}
|
|
128
|
+
const createdComponent = pConnect.createComponent({
|
|
129
|
+
type,
|
|
130
|
+
children: children ? [...children] : [],
|
|
131
|
+
showAddressLabel,
|
|
132
|
+
config: {
|
|
133
|
+
...config,
|
|
134
|
+
// Need a unique key for each summary component which helps in creating new component based on visibility
|
|
135
|
+
// Also a consistent key helps in rerendering summary components instead of remounting
|
|
136
|
+
key: config
|
|
137
|
+
}
|
|
138
|
+
});
|
|
139
|
+
createdComponent.props.getPConnect().setInheritedProp('displayMode', 'DISPLAY_ONLY');
|
|
140
|
+
createdComponent.props.getPConnect().setInheritedProp('readOnly', true);
|
|
141
|
+
if (type === 'Address') {
|
|
142
|
+
createdComponent.props.getPConnect().setInheritedProp('showAddressLabel', showAddressLabel);
|
|
143
|
+
}
|
|
144
|
+
// Add field label for reference summary item when not Embedded data
|
|
145
|
+
if (type === 'reference') {
|
|
146
|
+
const isEmbeddedData = config.context && config.displayAs === 'Form';
|
|
147
|
+
if (!isEmbeddedData) {
|
|
148
|
+
caseSummaryComponentObject.name = createdComponent.props.getPConnect().getInheritedProps().label;
|
|
149
|
+
}
|
|
150
|
+
}
|
|
151
|
+
caseSummaryComponentObject.value = createdComponent;
|
|
152
|
+
return caseSummaryComponentObject;
|
|
153
|
+
}
|
|
154
|
+
export function resolveReferenceFields(item, hideFieldLabels, recordKey, pConnect) {
|
|
155
|
+
const presets = (pConnect.getRawMetadata()?.config).presets ?? [];
|
|
156
|
+
const presetChildren = presets[0]?.children?.[0]?.children ?? [];
|
|
157
|
+
const maxFields = 5;
|
|
158
|
+
return presetChildren.slice(0, maxFields).map((preset, index) => {
|
|
159
|
+
const fieldMeta = {
|
|
160
|
+
meta: {
|
|
161
|
+
...preset,
|
|
162
|
+
config: {
|
|
163
|
+
...preset.config,
|
|
164
|
+
displayMode: 'DISPLAY_ONLY',
|
|
165
|
+
contextName: pConnect.getContextName()
|
|
166
|
+
}
|
|
167
|
+
},
|
|
168
|
+
useCustomContext: item
|
|
169
|
+
};
|
|
170
|
+
const configObj = PCore.createPConnect(fieldMeta);
|
|
171
|
+
const meta = configObj.getPConnect().getMetadata();
|
|
172
|
+
const fieldInfo = meta ? prepareComponentInCaseSummary(meta, configObj.getPConnect) : {};
|
|
173
|
+
return hideFieldLabels
|
|
174
|
+
? { id: `${item[recordKey]} - ${index}`, value: fieldInfo.value }
|
|
175
|
+
: {
|
|
176
|
+
id: `${item[recordKey]} - ${index}`,
|
|
177
|
+
name: fieldInfo.name,
|
|
178
|
+
value: fieldInfo.value,
|
|
179
|
+
type: preset.type
|
|
180
|
+
};
|
|
181
|
+
});
|
|
182
|
+
}
|
|
183
|
+
//# sourceMappingURL=utils.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"utils.js","sourceRoot":"","sources":["../../../../src/components/field/SelectableCard/utils.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,eAAe,CAAC;AAErC,OAAO,EAAE,KAAK,EAAE,MAAM,qBAAqB,CAAC;AAE5C,MAAM,CAAC,MAAM,yBAAyB,GAAG,QAAQ,CAAC,EAAE;IAClD,IAAI,CAAC,QAAQ,IAAI,CAAC,QAAQ,CAAC,IAAI;QAAE,OAAO,SAAS,CAAC;IAClD,MAAM,IAAI,GAAG,QAAQ,EAAE,KAAK,IAAI,SAAS,CAAC;IAC1C,MAAM,kBAAkB,GAAG,IAAI,KAAK,WAAW,IAAI,QAAQ,CAAC,yBAAyB,EAAE,CAAC,WAAW,EAAE,CAAC;IACtG,OAAO,kBAAkB,IAAI,QAAQ,CAAC;AACxC,CAAC,CAAC;AAEF;;;;;;GAMG;AACH,MAAM,UAAU,6BAA6B,CAAC,YAAiB,EAAE,WAAqB;IACpF,MAAM,EAAE,MAAM,EAAE,QAAQ,EAAE,GAAG,YAAY,CAAC;IAE1C,MAAM,gBAAgB,GAAG,qCAAmB,CAAC;IAC7C,MAAM,WAAW,GAAG,KAAK,CAAC;IAC1B,MAAM,QAAQ,GAAG,WAAW,EAAE,CAAC;IAE/B,MAAM,0BAA0B,GAAQ,EAAE,CAAC;IAE3C,IAAI,EAAE,IAAI,EAAE,GAAG,YAAY,CAAC;IAC5B,IAAI,gBAAgB,GAAG,IAAI,CAAC;IAE5B,IAAI,MAAM,IAAI,MAAM,CAAC,KAAK,KAAK,OAAO,KAAK,CAAC,YAAY,CAAC,cAAc,CAAC,EAAE,EAAE,CAAC;QAC3E,MAAM,CAAC,eAAe,GAAG,IAAI,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AAC;gBACE,EAAE,EAAE,GAAG,IAAI,CAAC,SAAS,CAAC,MAAM,KAAK,EAAE;gBACnC,IAAI,EAAE,SAAS,CAAC,IAAI;gBACpB,KAAK,EAAE,SAAS,CAAC,KAAK;gBACtB,IAAI,EAAE,MAAM,CAAC,IAAI;aAClB,CAAC;IACR,CAAC,CAAC,CAAC;AACL,CAAC","sourcesContent":["import { Link } from '@mui/material';\n\nimport { Utils } from '../../helpers/utils';\n\nexport const resolveReferencedPConnect = pConnect => {\n if (!pConnect || !pConnect.meta) return undefined;\n const type = pConnect?._type ?? undefined;\n const referencedPConnect = type === 'reference' && pConnect.getReferencedViewPConnect().getPConnect();\n return referencedPConnect || pConnect;\n};\n\n/**\n * A helper function to create an object consisting react component as per the type.\n * This is used by CaseSummary template.\n * @param {object} pConnectMeta Object containing meta information for the particular field authored\n * @param {Function} getPConnect PConnect function passed along to other components.\n * @param {string} displayMode displayMode string contains information about the layout of component in review mode.\n */\nexport function prepareComponentInCaseSummary(pConnectMeta: any, getPConnect: Function) {\n const { config, children } = pConnectMeta;\n\n const noValueComponent = <div>No Value</div>;\n const placeholder = '...';\n const pConnect = getPConnect();\n\n const caseSummaryComponentObject: any = {};\n\n let { type } = pConnectMeta;\n let showAddressLabel = true;\n\n if (config && config.value === `@P .${Utils.getMappedKey('pyStatusWork')}`) {\n config.displayAsStatus = true;\n type = 'TextInput'; // force the type to be TextInput for status field.\n // As TextInput is loaded forcefully sometimes, TextInput component might not be available in lazy map.\n // Load TextInput if it is not available.\n if (!PCore.getComponentsRegistry().getLazyComponent(type)) {\n PCore.getAssetLoader().getLoader('component-loader')([type]);\n }\n }\n\n caseSummaryComponentObject.name = pConnect.resolveConfigProps({ label: config.label }).label;\n\n if (config.inheritedProps) {\n const labelInInheritedProp = config.inheritedProps.find(inheritedProp => inheritedProp.prop === 'label');\n if (labelInInheritedProp) {\n labelInInheritedProp.value = pConnect.resolveConfigProps({ label: labelInInheritedProp.value }).label;\n }\n }\n\n switch (type) {\n case 'CaseOperator': {\n if (config.label.includes('Create operator')) {\n caseSummaryComponentObject.name = pConnect.resolveConfigProps({\n createLabel: config.createLabel\n }).createLabel;\n } else if (config.label.includes('Update operator')) {\n caseSummaryComponentObject.name = pConnect.resolveConfigProps({\n updateLabel: config.updateLabel\n }).updateLabel;\n } else {\n caseSummaryComponentObject.name = pConnect.resolveConfigProps({\n resolveLabel: config.resolveLabel\n }).resolveLabel;\n }\n\n break;\n }\n case 'Checkbox': {\n caseSummaryComponentObject.name = pConnect.resolveConfigProps({\n label: config.caption\n }).label;\n\n break;\n }\n case 'Pega_UI_PercentageWidget': {\n const rawValue = pConnect.resolveConfigProps({\n value: config.value\n }).value;\n\n caseSummaryComponentObject.simpleValue = rawValue || rawValue === 0 ? `${rawValue}%` : noValueComponent;\n break;\n }\n case 'Address': {\n showAddressLabel = false;\n\n caseSummaryComponentObject.variant = 'stacked';\n break;\n }\n case 'Location':\n case 'RichText': {\n const rawValue = pConnect.resolveConfigProps({\n value: config.value\n }).value;\n\n caseSummaryComponentObject.variant = 'stacked';\n caseSummaryComponentObject.simpleValue = rawValue?.length ? rawValue : noValueComponent;\n break;\n }\n case 'TextArea': {\n const rawValue = pConnect.resolveConfigProps({\n value: config.value\n }).value;\n\n if (rawValue?.length > 22) {\n caseSummaryComponentObject.variant = 'stacked';\n }\n\n caseSummaryComponentObject.simpleValue = rawValue?.length ? rawValue : noValueComponent;\n break;\n }\n case 'URL': {\n if (config.displayAs === 'Image') {\n const rawValue = pConnect.resolveConfigProps({\n value: config.value\n }).value;\n\n caseSummaryComponentObject.variant = 'stacked';\n caseSummaryComponentObject.simpleValue = rawValue?.length ? <Link href={rawValue}>{rawValue}</Link> : noValueComponent;\n }\n break;\n }\n case 'reference': {\n const referencedPConnect = resolveReferencedPConnect(pConnect);\n const viewType = referencedPConnect?.meta?.config.type;\n const viewTemplate = referencedPConnect?.meta?.config.template;\n const isTable = ['multirecordlist'].includes(viewType);\n const isDataReference = viewTemplate === 'DataReference';\n\n if (isTable || !isDataReference) {\n caseSummaryComponentObject.variant = 'stacked';\n caseSummaryComponentObject.simpleValue = placeholder;\n }\n break;\n }\n case 'view': {\n caseSummaryComponentObject.variant = 'stacked';\n caseSummaryComponentObject.simpleValue = placeholder;\n break;\n }\n default:\n break;\n }\n\n const createdComponent = pConnect.createComponent({\n type,\n children: children ? [...children] : [],\n showAddressLabel,\n config: {\n ...config,\n // Need a unique key for each summary component which helps in creating new component based on visibility\n // Also a consistent key helps in rerendering summary components instead of remounting\n key: config\n }\n });\n\n createdComponent.props.getPConnect().setInheritedProp('displayMode', 'DISPLAY_ONLY');\n createdComponent.props.getPConnect().setInheritedProp('readOnly', true);\n\n if (type === 'Address') {\n createdComponent.props.getPConnect().setInheritedProp('showAddressLabel', showAddressLabel);\n }\n // Add field label for reference summary item when not Embedded data\n if (type === 'reference') {\n const isEmbeddedData = config.context && config.displayAs === 'Form';\n if (!isEmbeddedData) {\n caseSummaryComponentObject.name = createdComponent.props.getPConnect().getInheritedProps().label;\n }\n }\n\n caseSummaryComponentObject.value = createdComponent;\n\n return caseSummaryComponentObject;\n}\n\nexport function resolveReferenceFields(\n item: {\n [key: string]: unknown;\n },\n hideFieldLabels: boolean,\n recordKey: string,\n pConnect: typeof PConnect\n) {\n const presets: {\n children?: {\n children?: {\n config;\n type;\n };\n config?;\n };\n } = (pConnect.getRawMetadata()?.config as any).presets ?? [];\n\n const presetChildren = presets[0]?.children?.[0]?.children ?? [];\n\n const maxFields = 5;\n return presetChildren.slice(0, maxFields).map((preset, index) => {\n const fieldMeta = {\n meta: {\n ...preset,\n config: {\n ...preset.config,\n displayMode: 'DISPLAY_ONLY',\n contextName: pConnect.getContextName()\n }\n },\n useCustomContext: item\n };\n const configObj = PCore.createPConnect(fieldMeta);\n const meta = configObj.getPConnect().getMetadata();\n const fieldInfo: {\n name?: string;\n value?: React.ReactNode;\n } = meta ? prepareComponentInCaseSummary(meta, configObj.getPConnect) : {};\n return hideFieldLabels\n ? { id: `${item[recordKey]} - ${index}`, value: fieldInfo.value }\n : {\n id: `${item[recordKey]} - ${index}`,\n name: fieldInfo.name,\n value: fieldInfo.value,\n type: preset.type\n };\n });\n}\n"]}
|
|
@@ -1,7 +1,15 @@
|
|
|
1
|
-
import { PConnFieldProps } from '../../../types/PConnProps';
|
|
1
|
+
import type { PConnFieldProps } from '../../../types/PConnProps';
|
|
2
2
|
interface SemanticLinkProps extends PConnFieldProps {
|
|
3
3
|
text: string;
|
|
4
|
+
resourcePayload: any;
|
|
5
|
+
resourceParams: any;
|
|
6
|
+
previewKey: string | null;
|
|
7
|
+
onClick: (event: any) => void;
|
|
8
|
+
testId: string;
|
|
9
|
+
referenceType: string | null;
|
|
10
|
+
dataRelationshipContext: string | null;
|
|
11
|
+
contextPage: any;
|
|
4
12
|
}
|
|
5
|
-
export default function SemanticLink(props: SemanticLinkProps): import("react/jsx-runtime").JSX.Element
|
|
13
|
+
export default function SemanticLink(props: SemanticLinkProps): import("react/jsx-runtime").JSX.Element;
|
|
6
14
|
export {};
|
|
7
15
|
//# sourceMappingURL=SemanticLink.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SemanticLink.d.ts","sourceRoot":"","sources":["../../../../src/components/field/SemanticLink/SemanticLink.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"SemanticLink.d.ts","sourceRoot":"","sources":["../../../../src/components/field/SemanticLink/SemanticLink.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAC;AAoCjE,UAAU,iBAAkB,SAAQ,eAAe;IAEjD,IAAI,EAAE,MAAM,CAAC;IACb,eAAe,EAAE,GAAG,CAAC;IACrB,cAAc,EAAE,GAAG,CAAC;IACpB,UAAU,EAAE,MAAM,GAAG,IAAI,CAAC;IAC1B,OAAO,EAAE,CAAC,KAAK,EAAE,GAAG,KAAK,IAAI,CAAC;IAC9B,MAAM,EAAE,MAAM,CAAC;IACf,aAAa,EAAE,MAAM,GAAG,IAAI,CAAC;IAC7B,uBAAuB,EAAE,MAAM,GAAG,IAAI,CAAC;IACvC,WAAW,EAAE,GAAG,CAAC;CAClB;AAED,MAAM,CAAC,OAAO,UAAU,YAAY,CAAC,KAAK,EAAE,iBAAiB,2CA2J5D"}
|