@pega/react-sdk-components 8.23.11 → 23.1.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +201 -0
- package/README.md +17 -0
- package/SECURITY.md +10 -0
- package/lib/bridge/Context/StoreContext.js +3 -3
- 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 +24 -47
- 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 +17 -28
- package/lib/bridge/react_pconnect.js.map +1 -1
- package/lib/components/designSystemExtension/AlertBanner/AlertBanner.d.ts +7 -10
- package/lib/components/designSystemExtension/AlertBanner/AlertBanner.d.ts.map +1 -1
- package/lib/components/designSystemExtension/AlertBanner/AlertBanner.js +2 -9
- package/lib/components/designSystemExtension/AlertBanner/AlertBanner.js.map +1 -1
- package/lib/components/designSystemExtension/Banner/Banner.d.ts +15 -1
- package/lib/components/designSystemExtension/Banner/Banner.d.ts.map +1 -1
- package/lib/components/designSystemExtension/Banner/Banner.js +2 -10
- 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 +6 -9
- package/lib/components/designSystemExtension/CaseSummaryFields/CaseSummaryFields.d.ts.map +1 -1
- package/lib/components/designSystemExtension/CaseSummaryFields/CaseSummaryFields.js +32 -33
- package/lib/components/designSystemExtension/CaseSummaryFields/CaseSummaryFields.js.map +1 -1
- package/lib/components/designSystemExtension/DetailsFields/DetailsFields.d.ts +4 -10
- package/lib/components/designSystemExtension/DetailsFields/DetailsFields.d.ts.map +1 -1
- package/lib/components/designSystemExtension/DetailsFields/DetailsFields.js +10 -23
- package/lib/components/designSystemExtension/DetailsFields/DetailsFields.js.map +1 -1
- package/lib/components/designSystemExtension/DetailsFields/index.js.map +1 -1
- package/lib/components/designSystemExtension/FieldGroup/FieldGroup.d.ts +8 -3
- package/lib/components/designSystemExtension/FieldGroup/FieldGroup.d.ts.map +1 -1
- package/lib/components/designSystemExtension/FieldGroup/FieldGroup.js +25 -14
- package/lib/components/designSystemExtension/FieldGroup/FieldGroup.js.map +1 -1
- package/lib/components/designSystemExtension/FieldGroupList/FieldGroupList.d.ts +7 -2
- package/lib/components/designSystemExtension/FieldGroupList/FieldGroupList.d.ts.map +1 -1
- package/lib/components/designSystemExtension/FieldGroupList/FieldGroupList.js +6 -18
- package/lib/components/designSystemExtension/FieldGroupList/FieldGroupList.js.map +1 -1
- package/lib/components/designSystemExtension/FieldValueList/FieldValueList.d.ts +7 -2
- package/lib/components/designSystemExtension/FieldValueList/FieldValueList.d.ts.map +1 -1
- package/lib/components/designSystemExtension/FieldValueList/FieldValueList.js +6 -12
- package/lib/components/designSystemExtension/FieldValueList/FieldValueList.js.map +1 -1
- package/lib/components/designSystemExtension/Operator/Operator.d.ts +17 -7
- package/lib/components/designSystemExtension/Operator/Operator.d.ts.map +1 -1
- package/lib/components/designSystemExtension/Operator/Operator.js +49 -67
- package/lib/components/designSystemExtension/Operator/Operator.js.map +1 -1
- package/lib/components/designSystemExtension/Pulse/Pulse.d.ts +5 -2
- package/lib/components/designSystemExtension/Pulse/Pulse.d.ts.map +1 -1
- package/lib/components/designSystemExtension/Pulse/Pulse.js +9 -15
- package/lib/components/designSystemExtension/Pulse/Pulse.js.map +1 -1
- package/lib/components/designSystemExtension/RichTextEditor/RichTextEditor.d.ts +19 -0
- package/lib/components/designSystemExtension/RichTextEditor/RichTextEditor.d.ts.map +1 -0
- package/lib/components/designSystemExtension/RichTextEditor/RichTextEditor.js +75 -0
- package/lib/components/designSystemExtension/RichTextEditor/RichTextEditor.js.map +1 -0
- package/lib/components/designSystemExtension/RichTextEditor/index.d.ts +2 -0
- package/lib/components/designSystemExtension/RichTextEditor/index.d.ts.map +1 -0
- package/lib/components/designSystemExtension/RichTextEditor/index.js +2 -0
- package/lib/components/designSystemExtension/RichTextEditor/index.js.map +1 -0
- package/lib/components/designSystemExtension/WssQuickCreate/WssQuickCreate.d.ts +6 -1
- package/lib/components/designSystemExtension/WssQuickCreate/WssQuickCreate.d.ts.map +1 -1
- package/lib/components/designSystemExtension/WssQuickCreate/WssQuickCreate.js +5 -11
- package/lib/components/designSystemExtension/WssQuickCreate/WssQuickCreate.js.map +1 -1
- package/lib/components/field/AutoComplete/AutoComplete.d.ts +15 -1
- package/lib/components/field/AutoComplete/AutoComplete.d.ts.map +1 -1
- package/lib/components/field/AutoComplete/AutoComplete.js +17 -17
- package/lib/components/field/AutoComplete/AutoComplete.js.map +1 -1
- package/lib/components/field/CancelAlert/CancelAlert.d.ts +12 -2
- package/lib/components/field/CancelAlert/CancelAlert.d.ts.map +1 -1
- package/lib/components/field/CancelAlert/CancelAlert.js +78 -70
- package/lib/components/field/CancelAlert/CancelAlert.js.map +1 -1
- package/lib/components/field/CancelAlert/index.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 +13 -13
- package/lib/components/field/Checkbox/Checkbox.js.map +1 -1
- package/lib/components/field/Currency/Currency.d.ts +6 -1
- package/lib/components/field/Currency/Currency.d.ts.map +1 -1
- package/lib/components/field/Currency/Currency.js +15 -36
- 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 +5 -6
- package/lib/components/field/Currency/currency-utils.js.map +1 -1
- package/lib/components/field/Date/Date.d.ts +5 -1
- package/lib/components/field/Date/Date.d.ts.map +1 -1
- package/lib/components/field/Date/Date.js +15 -9
- package/lib/components/field/Date/Date.js.map +1 -1
- package/lib/components/field/DateTime/DateTime.d.ts +5 -1
- package/lib/components/field/DateTime/DateTime.d.ts.map +1 -1
- package/lib/components/field/DateTime/DateTime.js +15 -9
- package/lib/components/field/DateTime/DateTime.js.map +1 -1
- package/lib/components/field/Decimal/Decimal.d.ts +8 -1
- package/lib/components/field/Decimal/Decimal.d.ts.map +1 -1
- package/lib/components/field/Decimal/Decimal.js +13 -29
- package/lib/components/field/Decimal/Decimal.js.map +1 -1
- package/lib/components/field/Decimal/index.js.map +1 -1
- package/lib/components/field/Dropdown/Dropdown.d.ts +13 -1
- package/lib/components/field/Dropdown/Dropdown.d.ts.map +1 -1
- package/lib/components/field/Dropdown/Dropdown.js +105 -15
- package/lib/components/field/Dropdown/Dropdown.js.map +1 -1
- package/lib/components/field/Email/Email.d.ts +5 -1
- package/lib/components/field/Email/Email.d.ts.map +1 -1
- package/lib/components/field/Email/Email.js +12 -11
- package/lib/components/field/Email/Email.js.map +1 -1
- package/lib/components/field/Email/index.js.map +1 -1
- package/lib/components/field/Group/Group.d.ts +13 -0
- package/lib/components/field/Group/Group.d.ts.map +1 -0
- package/lib/components/field/Group/Group.js +15 -0
- package/lib/components/field/Group/Group.js.map +1 -0
- package/lib/components/field/Group/index.d.ts +2 -0
- package/lib/components/field/Group/index.d.ts.map +1 -0
- package/lib/components/field/Group/index.js +2 -0
- package/lib/components/field/Group/index.js.map +1 -0
- package/lib/components/field/Integer/Integer.d.ts +5 -1
- package/lib/components/field/Integer/Integer.d.ts.map +1 -1
- package/lib/components/field/Integer/Integer.js +10 -8
- package/lib/components/field/Integer/Integer.js.map +1 -1
- package/lib/components/field/Percentage/Percentage.d.ts +6 -1
- package/lib/components/field/Percentage/Percentage.d.ts.map +1 -1
- package/lib/components/field/Percentage/Percentage.js +28 -29
- package/lib/components/field/Percentage/Percentage.js.map +1 -1
- package/lib/components/field/Phone/Phone.d.ts +5 -1
- package/lib/components/field/Phone/Phone.d.ts.map +1 -1
- package/lib/components/field/Phone/Phone.js +10 -9
- package/lib/components/field/Phone/Phone.js.map +1 -1
- package/lib/components/field/Phone/index.js.map +1 -1
- package/lib/components/field/RadioButtons/RadioButtons.d.ts +7 -1
- package/lib/components/field/RadioButtons/RadioButtons.d.ts.map +1 -1
- package/lib/components/field/RadioButtons/RadioButtons.js +19 -15
- package/lib/components/field/RadioButtons/RadioButtons.js.map +1 -1
- package/lib/components/field/RichText/RichText.d.ts +7 -0
- package/lib/components/field/RichText/RichText.d.ts.map +1 -0
- package/lib/components/field/RichText/RichText.js +54 -0
- package/lib/components/field/RichText/RichText.js.map +1 -0
- package/lib/components/field/RichText/index.d.ts +2 -0
- package/lib/components/field/RichText/index.d.ts.map +1 -0
- package/lib/components/field/RichText/index.js +2 -0
- package/lib/components/field/RichText/index.js.map +1 -0
- package/lib/components/field/ScalarList/ScalarList.d.ts +13 -0
- package/lib/components/field/ScalarList/ScalarList.d.ts.map +1 -0
- package/lib/components/field/ScalarList/ScalarList.js +32 -0
- package/lib/components/field/ScalarList/ScalarList.js.map +1 -0
- package/lib/components/field/ScalarList/index.d.ts +2 -0
- package/lib/components/field/ScalarList/index.d.ts.map +1 -0
- package/lib/components/field/ScalarList/index.js +2 -0
- package/lib/components/field/ScalarList/index.js.map +1 -0
- package/lib/components/field/SemanticLink/SemanticLink.d.ts +5 -9
- package/lib/components/field/SemanticLink/SemanticLink.d.ts.map +1 -1
- package/lib/components/field/SemanticLink/SemanticLink.js +11 -19
- package/lib/components/field/SemanticLink/SemanticLink.js.map +1 -1
- package/lib/components/field/SemanticLink/utils.d.ts.map +1 -1
- package/lib/components/field/SemanticLink/utils.js +8 -8
- package/lib/components/field/SemanticLink/utils.js.map +1 -1
- package/lib/components/field/TextArea/TextArea.d.ts +6 -1
- package/lib/components/field/TextArea/TextArea.d.ts.map +1 -1
- package/lib/components/field/TextArea/TextArea.js +8 -6
- package/lib/components/field/TextArea/TextArea.js.map +1 -1
- package/lib/components/field/TextContent/TextContent.d.ts +7 -1
- package/lib/components/field/TextContent/TextContent.d.ts.map +1 -1
- package/lib/components/field/TextContent/TextContent.js +2 -2
- package/lib/components/field/TextContent/TextContent.js.map +1 -1
- package/lib/components/field/TextInput/TextInput.d.ts +6 -1
- package/lib/components/field/TextInput/TextInput.d.ts.map +1 -1
- package/lib/components/field/TextInput/TextInput.js +10 -7
- package/lib/components/field/TextInput/TextInput.js.map +1 -1
- package/lib/components/field/TextInput/index.js.map +1 -1
- package/lib/components/field/Time/Time.d.ts +5 -1
- package/lib/components/field/Time/Time.d.ts.map +1 -1
- package/lib/components/field/Time/Time.js +11 -9
- package/lib/components/field/Time/Time.js.map +1 -1
- package/lib/components/field/URL/URL.d.ts +5 -1
- package/lib/components/field/URL/URL.d.ts.map +1 -1
- package/lib/components/field/URL/URL.js +10 -8
- package/lib/components/field/URL/URL.js.map +1 -1
- package/lib/components/field/URL/index.js.map +1 -1
- package/lib/components/field/UserReference/UserReference.d.ts +20 -41
- package/lib/components/field/UserReference/UserReference.d.ts.map +1 -1
- package/lib/components/field/UserReference/UserReference.js +17 -46
- package/lib/components/field/UserReference/UserReference.js.map +1 -1
- package/lib/components/field/UserReference/UserReferenceUtils.js +2 -2
- package/lib/components/field/UserReference/UserReferenceUtils.js.map +1 -1
- package/lib/components/helpers/attachmentHelpers.d.ts +3 -3
- package/lib/components/helpers/attachmentHelpers.d.ts.map +1 -1
- package/lib/components/helpers/attachmentHelpers.js +6 -6
- package/lib/components/helpers/attachmentHelpers.js.map +1 -1
- package/lib/components/helpers/case-utils.d.ts.map +1 -1
- package/lib/components/helpers/case-utils.js +5 -4
- package/lib/components/helpers/case-utils.js.map +1 -1
- package/lib/components/helpers/common-utils.d.ts +2 -1
- package/lib/components/helpers/common-utils.d.ts.map +1 -1
- package/lib/components/helpers/common-utils.js +4 -1
- 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 +2 -3
- package/lib/components/helpers/data_page.js.map +1 -1
- package/lib/components/helpers/date-format-utils.d.ts +1 -6
- package/lib/components/helpers/date-format-utils.d.ts.map +1 -1
- package/lib/components/helpers/date-format-utils.js.map +1 -1
- package/lib/components/helpers/event-utils.d.ts +1 -1
- package/lib/components/helpers/event-utils.d.ts.map +1 -1
- package/lib/components/helpers/event-utils.js +3 -3
- package/lib/components/helpers/event-utils.js.map +1 -1
- package/lib/components/helpers/field-group-utils.d.ts.map +1 -1
- package/lib/components/helpers/field-group-utils.js +3 -7
- package/lib/components/helpers/field-group-utils.js.map +1 -1
- package/lib/components/helpers/formatters/Boolean.d.ts.map +1 -1
- package/lib/components/helpers/formatters/Boolean.js +9 -20
- package/lib/components/helpers/formatters/Boolean.js.map +1 -1
- package/lib/components/helpers/formatters/Currency.d.ts +6 -6
- package/lib/components/helpers/formatters/Currency.d.ts.map +1 -1
- package/lib/components/helpers/formatters/Currency.js +13 -14
- package/lib/components/helpers/formatters/Currency.js.map +1 -1
- package/lib/components/helpers/formatters/CurrencyMap.d.ts +69 -320
- package/lib/components/helpers/formatters/CurrencyMap.d.ts.map +1 -1
- package/lib/components/helpers/formatters/CurrencyMap.js +500 -500
- package/lib/components/helpers/formatters/CurrencyMap.js.map +1 -1
- package/lib/components/helpers/formatters/Date.d.ts +5 -5
- package/lib/components/helpers/formatters/Date.d.ts.map +1 -1
- package/lib/components/helpers/formatters/Date.js +20 -20
- package/lib/components/helpers/formatters/Date.js.map +1 -1
- package/lib/components/helpers/formatters/common.d.ts +1 -1
- package/lib/components/helpers/formatters/common.d.ts.map +1 -1
- package/lib/components/helpers/formatters/common.js +1 -1
- package/lib/components/helpers/formatters/common.js.map +1 -1
- package/lib/components/helpers/formatters/index.d.ts +12 -12
- package/lib/components/helpers/formatters/index.d.ts.map +1 -1
- package/lib/components/helpers/formatters/index.js +25 -19
- package/lib/components/helpers/formatters/index.js.map +1 -1
- package/lib/components/helpers/reactContextHelpers.d.ts.map +1 -1
- package/lib/components/helpers/reactContextHelpers.js +1 -1
- package/lib/components/helpers/reactContextHelpers.js.map +1 -1
- package/lib/components/helpers/simpleTableHelpers.d.ts +3 -1
- package/lib/components/helpers/simpleTableHelpers.d.ts.map +1 -1
- package/lib/components/helpers/simpleTableHelpers.js +48 -54
- 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 +6 -8
- package/lib/components/helpers/state-utils.js.map +1 -1
- package/lib/components/helpers/template-utils.d.ts +7 -3
- package/lib/components/helpers/template-utils.d.ts.map +1 -1
- package/lib/components/helpers/template-utils.js +2 -2
- package/lib/components/helpers/template-utils.js.map +1 -1
- package/lib/components/helpers/utils.d.ts +1 -1
- package/lib/components/helpers/utils.d.ts.map +1 -1
- package/lib/components/helpers/utils.js +3 -8
- package/lib/components/helpers/utils.js.map +1 -1
- package/lib/components/helpers/versionHelpers.d.ts +6 -0
- package/lib/components/helpers/versionHelpers.d.ts.map +1 -1
- package/lib/components/helpers/versionHelpers.js +7 -1
- package/lib/components/helpers/versionHelpers.js.map +1 -1
- package/lib/components/infra/ActionButtons/ActionButtons.d.ts +6 -13
- package/lib/components/infra/ActionButtons/ActionButtons.d.ts.map +1 -1
- package/lib/components/infra/ActionButtons/ActionButtons.js +11 -27
- package/lib/components/infra/ActionButtons/ActionButtons.js.map +1 -1
- package/lib/components/infra/ActionButtons/index.js.map +1 -1
- package/lib/components/infra/Assignment/Assignment.d.ts +9 -16
- package/lib/components/infra/Assignment/Assignment.d.ts.map +1 -1
- package/lib/components/infra/Assignment/Assignment.js +71 -74
- package/lib/components/infra/Assignment/Assignment.js.map +1 -1
- package/lib/components/infra/Assignment/index.js.map +1 -1
- package/lib/components/infra/AssignmentCard/AssignmentCard.d.ts +7 -15
- package/lib/components/infra/AssignmentCard/AssignmentCard.d.ts.map +1 -1
- package/lib/components/infra/AssignmentCard/AssignmentCard.js +6 -20
- package/lib/components/infra/AssignmentCard/AssignmentCard.js.map +1 -1
- package/lib/components/infra/AssignmentCard/index.js.map +1 -1
- package/lib/components/infra/Containers/FlowContainer/FlowContainer.d.ts +10 -20
- package/lib/components/infra/Containers/FlowContainer/FlowContainer.d.ts.map +1 -1
- package/lib/components/infra/Containers/FlowContainer/FlowContainer.js +63 -192
- 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 +30 -30
- package/lib/components/infra/Containers/FlowContainer/helpers.js.map +1 -1
- package/lib/components/infra/Containers/FlowContainer/index.js.map +1 -1
- package/lib/components/infra/Containers/ModalViewContainer/ListViewActionButtons/ListViewActionButtons.d.ts +9 -0
- package/lib/components/infra/Containers/ModalViewContainer/ListViewActionButtons/ListViewActionButtons.d.ts.map +1 -0
- package/lib/components/infra/Containers/ModalViewContainer/ListViewActionButtons/ListViewActionButtons.js +36 -0
- package/lib/components/infra/Containers/ModalViewContainer/ListViewActionButtons/ListViewActionButtons.js.map +1 -0
- package/lib/components/infra/Containers/ModalViewContainer/ListViewActionButtons/index.d.ts +2 -0
- package/lib/components/infra/Containers/ModalViewContainer/ListViewActionButtons/index.d.ts.map +1 -0
- package/lib/components/infra/Containers/ModalViewContainer/ListViewActionButtons/index.js +2 -0
- package/lib/components/infra/Containers/ModalViewContainer/ListViewActionButtons/index.js.map +1 -0
- package/lib/components/infra/Containers/ModalViewContainer/ModalViewContainer.d.ts +8 -17
- package/lib/components/infra/Containers/ModalViewContainer/ModalViewContainer.d.ts.map +1 -1
- package/lib/components/infra/Containers/ModalViewContainer/ModalViewContainer.js +179 -172
- package/lib/components/infra/Containers/ModalViewContainer/ModalViewContainer.js.map +1 -1
- package/lib/components/infra/Containers/ModalViewContainer/index.js.map +1 -1
- package/lib/components/infra/Containers/SimpleView/SimpleView.d.ts +9 -0
- package/lib/components/infra/Containers/SimpleView/SimpleView.d.ts.map +1 -0
- package/lib/components/infra/Containers/SimpleView/SimpleView.js +29 -0
- package/lib/components/infra/Containers/SimpleView/SimpleView.js.map +1 -0
- package/lib/components/infra/Containers/SimpleView/helper.d.ts +10 -0
- package/lib/components/infra/Containers/SimpleView/helper.d.ts.map +1 -0
- package/lib/components/infra/Containers/SimpleView/helper.js +102 -0
- package/lib/components/infra/Containers/SimpleView/helper.js.map +1 -0
- package/lib/components/infra/Containers/SimpleView/index.d.ts +2 -0
- package/lib/components/infra/Containers/SimpleView/index.d.ts.map +1 -0
- package/lib/components/infra/Containers/SimpleView/index.js +2 -0
- package/lib/components/infra/Containers/SimpleView/index.js.map +1 -0
- package/lib/components/infra/Containers/ViewContainer/ViewContainer.d.ts +9 -22
- package/lib/components/infra/Containers/ViewContainer/ViewContainer.d.ts.map +1 -1
- package/lib/components/infra/Containers/ViewContainer/ViewContainer.js +24 -44
- package/lib/components/infra/Containers/ViewContainer/ViewContainer.js.map +1 -1
- package/lib/components/infra/Containers/helpers.d.ts +2 -0
- package/lib/components/infra/Containers/helpers.d.ts.map +1 -0
- package/lib/components/infra/Containers/helpers.js +7 -0
- package/lib/components/infra/Containers/helpers.js.map +1 -0
- package/lib/components/infra/DashboardFilter/DashboardFilter.d.ts +9 -20
- package/lib/components/infra/DashboardFilter/DashboardFilter.d.ts.map +1 -1
- package/lib/components/infra/DashboardFilter/DashboardFilter.js +15 -33
- 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 +10 -12
- package/lib/components/infra/DashboardFilter/filterUtils.js.map +1 -1
- package/lib/components/infra/DeferLoad/DeferLoad.d.ts +8 -13
- package/lib/components/infra/DeferLoad/DeferLoad.d.ts.map +1 -1
- package/lib/components/infra/DeferLoad/DeferLoad.js +11 -22
- package/lib/components/infra/DeferLoad/DeferLoad.js.map +1 -1
- package/lib/components/infra/DeferLoad/index.js.map +1 -1
- package/lib/components/infra/ErrorBoundary/ErrorBoundary.d.ts +5 -12
- package/lib/components/infra/ErrorBoundary/ErrorBoundary.d.ts.map +1 -1
- package/lib/components/infra/ErrorBoundary/ErrorBoundary.js +17 -26
- package/lib/components/infra/ErrorBoundary/ErrorBoundary.js.map +1 -1
- package/lib/components/infra/MultiStep/MultiStep.css +11 -15
- package/lib/components/infra/MultiStep/MultiStep.d.ts +10 -18
- package/lib/components/infra/MultiStep/MultiStep.d.ts.map +1 -1
- package/lib/components/infra/MultiStep/MultiStep.js +32 -97
- package/lib/components/infra/MultiStep/MultiStep.js.map +1 -1
- package/lib/components/infra/MultiStep/index.js.map +1 -1
- package/lib/components/infra/NavBar/NavBar.css +103 -105
- package/lib/components/infra/NavBar/NavBar.d.ts +8 -16
- package/lib/components/infra/NavBar/NavBar.d.ts.map +1 -1
- package/lib/components/infra/NavBar/NavBar.js +19 -66
- package/lib/components/infra/NavBar/NavBar.js.map +1 -1
- package/lib/components/infra/Reference/Reference.d.ts +8 -17
- package/lib/components/infra/Reference/Reference.d.ts.map +1 -1
- package/lib/components/infra/Reference/Reference.js +5 -17
- package/lib/components/infra/Reference/Reference.js.map +1 -1
- package/lib/components/infra/Region/Region.d.ts +4 -8
- package/lib/components/infra/Region/Region.d.ts.map +1 -1
- package/lib/components/infra/Region/Region.js +2 -7
- package/lib/components/infra/Region/Region.js.map +1 -1
- package/lib/components/infra/RootContainer/RootContainer.d.ts +13 -20
- package/lib/components/infra/RootContainer/RootContainer.d.ts.map +1 -1
- package/lib/components/infra/RootContainer/RootContainer.js +41 -80
- package/lib/components/infra/RootContainer/RootContainer.js.map +1 -1
- package/lib/components/infra/RootContainer/index.js.map +1 -1
- package/lib/components/infra/Stages/Stages.d.ts +5 -8
- package/lib/components/infra/Stages/Stages.d.ts.map +1 -1
- package/lib/components/infra/Stages/Stages.js +19 -27
- package/lib/components/infra/Stages/Stages.js.map +1 -1
- package/lib/components/infra/VerticalTabs/LeftAlignVerticalTabs/LeftAlignVerticalTabs.d.ts.map +1 -1
- package/lib/components/infra/VerticalTabs/LeftAlignVerticalTabs/LeftAlignVerticalTabs.js +6 -8
- package/lib/components/infra/VerticalTabs/LeftAlignVerticalTabs/LeftAlignVerticalTabs.js.map +1 -1
- package/lib/components/infra/VerticalTabs/VerticalTabs/VerticalTabs.d.ts +4 -10
- package/lib/components/infra/VerticalTabs/VerticalTabs/VerticalTabs.d.ts.map +1 -1
- package/lib/components/infra/VerticalTabs/VerticalTabs/VerticalTabs.js +13 -17
- package/lib/components/infra/VerticalTabs/VerticalTabs/VerticalTabs.js.map +1 -1
- package/lib/components/infra/View/View.d.ts +13 -17
- package/lib/components/infra/View/View.d.ts.map +1 -1
- package/lib/components/infra/View/View.js +10 -32
- package/lib/components/infra/View/View.js.map +1 -1
- package/lib/components/template/AppShell/AppShell.css +22 -23
- package/lib/components/template/AppShell/AppShell.d.ts +20 -16
- package/lib/components/template/AppShell/AppShell.d.ts.map +1 -1
- package/lib/components/template/AppShell/AppShell.js +27 -45
- package/lib/components/template/AppShell/AppShell.js.map +1 -1
- package/lib/components/template/BannerPage/BannerPage.d.ts +12 -24
- package/lib/components/template/BannerPage/BannerPage.d.ts.map +1 -1
- package/lib/components/template/BannerPage/BannerPage.js +7 -25
- package/lib/components/template/BannerPage/BannerPage.js.map +1 -1
- package/lib/components/template/CaseSummary/CaseSummary.d.ts +5 -8
- package/lib/components/template/CaseSummary/CaseSummary.d.ts.map +1 -1
- package/lib/components/template/CaseSummary/CaseSummary.js +48 -12
- package/lib/components/template/CaseSummary/CaseSummary.js.map +1 -1
- package/lib/components/template/CaseView/CaseView.d.ts +10 -23
- package/lib/components/template/CaseView/CaseView.d.ts.map +1 -1
- package/lib/components/template/CaseView/CaseView.js +22 -58
- package/lib/components/template/CaseView/CaseView.js.map +1 -1
- package/lib/components/template/CaseViewActionsMenu/CaseViewActionsMenu.d.ts +8 -15
- package/lib/components/template/CaseViewActionsMenu/CaseViewActionsMenu.d.ts.map +1 -1
- package/lib/components/template/CaseViewActionsMenu/CaseViewActionsMenu.js +37 -19
- package/lib/components/template/CaseViewActionsMenu/CaseViewActionsMenu.js.map +1 -1
- package/lib/components/template/Confirmation/Confirmation.d.ts +10 -17
- package/lib/components/template/Confirmation/Confirmation.d.ts.map +1 -1
- package/lib/components/template/Confirmation/Confirmation.js +10 -28
- package/lib/components/template/Confirmation/Confirmation.js.map +1 -1
- package/lib/components/template/DataReference/DataReference.d.ts +15 -30
- package/lib/components/template/DataReference/DataReference.d.ts.map +1 -1
- package/lib/components/template/DataReference/DataReference.js +35 -72
- package/lib/components/template/DataReference/DataReference.js.map +1 -1
- package/lib/components/template/DefaultForm/DefaultForm.css +7 -3
- package/lib/components/template/DefaultForm/DefaultForm.d.ts +7 -11
- package/lib/components/template/DefaultForm/DefaultForm.d.ts.map +1 -1
- package/lib/components/template/DefaultForm/DefaultForm.js +5 -15
- package/lib/components/template/DefaultForm/DefaultForm.js.map +1 -1
- package/lib/components/template/Details/Details/Details.d.ts +7 -15
- package/lib/components/template/Details/Details/Details.d.ts.map +1 -1
- package/lib/components/template/Details/Details/Details.js +8 -21
- package/lib/components/template/Details/Details/Details.js.map +1 -1
- package/lib/components/template/Details/DetailsSubTabs/DetailsSubTabs.d.ts +7 -16
- package/lib/components/template/Details/DetailsSubTabs/DetailsSubTabs.d.ts.map +1 -1
- package/lib/components/template/Details/DetailsSubTabs/DetailsSubTabs.js +6 -23
- package/lib/components/template/Details/DetailsSubTabs/DetailsSubTabs.js.map +1 -1
- package/lib/components/template/Details/DetailsThreeColumn/DetailsThreeColumn.d.ts +7 -15
- package/lib/components/template/Details/DetailsThreeColumn/DetailsThreeColumn.d.ts.map +1 -1
- package/lib/components/template/Details/DetailsThreeColumn/DetailsThreeColumn.js +9 -22
- package/lib/components/template/Details/DetailsThreeColumn/DetailsThreeColumn.js.map +1 -1
- package/lib/components/template/Details/DetailsTwoColumn/DetailsTwoColumn.d.ts +7 -15
- package/lib/components/template/Details/DetailsTwoColumn/DetailsTwoColumn.d.ts.map +1 -1
- package/lib/components/template/Details/DetailsTwoColumn/DetailsTwoColumn.js +9 -22
- package/lib/components/template/Details/DetailsTwoColumn/DetailsTwoColumn.js.map +1 -1
- package/lib/components/template/Details/DetailsTwoColumn/index.js.map +1 -1
- package/lib/components/template/Details/DynamicTabs/DynamicTabs.d.ts +10 -0
- package/lib/components/template/Details/DynamicTabs/DynamicTabs.d.ts.map +1 -0
- package/lib/components/template/Details/DynamicTabs/DynamicTabs.js +45 -0
- package/lib/components/template/Details/DynamicTabs/DynamicTabs.js.map +1 -0
- package/lib/components/template/Details/DynamicTabs/index.d.ts +2 -0
- package/lib/components/template/Details/DynamicTabs/index.d.ts.map +1 -0
- package/lib/components/template/Details/DynamicTabs/index.js +2 -0
- package/lib/components/template/Details/DynamicTabs/index.js.map +1 -0
- package/lib/components/template/FieldGroupTemplate/FieldGroupTemplate.d.ts +12 -19
- package/lib/components/template/FieldGroupTemplate/FieldGroupTemplate.d.ts.map +1 -1
- package/lib/components/template/FieldGroupTemplate/FieldGroupTemplate.js +11 -26
- package/lib/components/template/FieldGroupTemplate/FieldGroupTemplate.js.map +1 -1
- package/lib/components/template/InlineDashboard/InlineDashboard.d.ts +7 -8
- package/lib/components/template/InlineDashboard/InlineDashboard.d.ts.map +1 -1
- package/lib/components/template/InlineDashboard/InlineDashboard.js +3 -14
- package/lib/components/template/InlineDashboard/InlineDashboard.js.map +1 -1
- package/lib/components/template/InlineDashboardPage/InlineDashboardPage.d.ts +8 -16
- package/lib/components/template/InlineDashboardPage/InlineDashboardPage.d.ts.map +1 -1
- package/lib/components/template/InlineDashboardPage/InlineDashboardPage.js +9 -17
- package/lib/components/template/InlineDashboardPage/InlineDashboardPage.js.map +1 -1
- package/lib/components/template/ListPage/ListPage.d.ts +5 -13
- package/lib/components/template/ListPage/ListPage.d.ts.map +1 -1
- package/lib/components/template/ListPage/ListPage.js +7 -11
- package/lib/components/template/ListPage/ListPage.js.map +1 -1
- package/lib/components/template/ListView/DefaultViewMeta.d.ts.map +1 -1
- package/lib/components/template/ListView/DefaultViewMeta.js.map +1 -1
- package/lib/components/template/ListView/ListView.d.ts +15 -8
- package/lib/components/template/ListView/ListView.d.ts.map +1 -1
- package/lib/components/template/ListView/ListView.js +168 -258
- 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 +4 -6
- package/lib/components/template/ListView/hooks.js.map +1 -1
- package/lib/components/template/ListView/utils.d.ts +45 -1
- package/lib/components/template/ListView/utils.d.ts.map +1 -1
- package/lib/components/template/ListView/utils.js +165 -32
- package/lib/components/template/ListView/utils.js.map +1 -1
- package/lib/components/template/MultiReferenceReadOnly/MultiReferenceReadOnly.d.ts +9 -13
- package/lib/components/template/MultiReferenceReadOnly/MultiReferenceReadOnly.d.ts.map +1 -1
- package/lib/components/template/MultiReferenceReadOnly/MultiReferenceReadOnly.js +5 -16
- package/lib/components/template/MultiReferenceReadOnly/MultiReferenceReadOnly.js.map +1 -1
- package/lib/components/template/NarrowWide/NarrowWide/NarrowWide.css +0 -2
- package/lib/components/template/NarrowWide/NarrowWide/NarrowWide.d.ts +11 -2
- package/lib/components/template/NarrowWide/NarrowWide/NarrowWide.d.ts.map +1 -1
- package/lib/components/template/NarrowWide/NarrowWide/NarrowWide.js +2 -10
- package/lib/components/template/NarrowWide/NarrowWide/NarrowWide.js.map +1 -1
- package/lib/components/template/NarrowWide/NarrowWideDetails/NarrowWideDetails.d.ts +7 -15
- package/lib/components/template/NarrowWide/NarrowWideDetails/NarrowWideDetails.d.ts.map +1 -1
- package/lib/components/template/NarrowWide/NarrowWideDetails/NarrowWideDetails.js +9 -22
- package/lib/components/template/NarrowWide/NarrowWideDetails/NarrowWideDetails.js.map +1 -1
- package/lib/components/template/NarrowWide/NarrowWideForm/NarrowWideForm.css +0 -2
- package/lib/components/template/NarrowWide/NarrowWideForm/NarrowWideForm.d.ts +6 -2
- package/lib/components/template/NarrowWide/NarrowWideForm/NarrowWideForm.d.ts.map +1 -1
- package/lib/components/template/NarrowWide/NarrowWideForm/NarrowWideForm.js +2 -5
- package/lib/components/template/NarrowWide/NarrowWideForm/NarrowWideForm.js.map +1 -1
- package/lib/components/template/NarrowWide/NarrowWidePage/NarrowWidePage.d.ts +8 -15
- package/lib/components/template/NarrowWide/NarrowWidePage/NarrowWidePage.d.ts.map +1 -1
- package/lib/components/template/NarrowWide/NarrowWidePage/NarrowWidePage.js +7 -18
- package/lib/components/template/NarrowWide/NarrowWidePage/NarrowWidePage.js.map +1 -1
- package/lib/components/template/OneColumn/OneColumn/OneColumn.d.ts +5 -8
- package/lib/components/template/OneColumn/OneColumn/OneColumn.d.ts.map +1 -1
- package/lib/components/template/OneColumn/OneColumn/OneColumn.js +9 -13
- package/lib/components/template/OneColumn/OneColumn/OneColumn.js.map +1 -1
- package/lib/components/template/OneColumn/OneColumnPage/OneColumnPage.d.ts +4 -8
- package/lib/components/template/OneColumn/OneColumnPage/OneColumnPage.d.ts.map +1 -1
- package/lib/components/template/OneColumn/OneColumnPage/OneColumnPage.js +5 -8
- package/lib/components/template/OneColumn/OneColumnPage/OneColumnPage.js.map +1 -1
- package/lib/components/template/OneColumn/OneColumnTab/OneColumnTab.d.ts +5 -8
- package/lib/components/template/OneColumn/OneColumnTab/OneColumnTab.d.ts.map +1 -1
- package/lib/components/template/OneColumn/OneColumnTab/OneColumnTab.js +2 -7
- package/lib/components/template/OneColumn/OneColumnTab/OneColumnTab.js.map +1 -1
- package/lib/components/template/PromotedFilters/PromotedFilters.css +1 -1
- package/lib/components/template/PromotedFilters/PromotedFilters.d.ts +9 -14
- package/lib/components/template/PromotedFilters/PromotedFilters.d.ts.map +1 -1
- package/lib/components/template/PromotedFilters/PromotedFilters.js +14 -27
- package/lib/components/template/PromotedFilters/PromotedFilters.js.map +1 -1
- package/lib/components/template/SimpleTable/SimpleTable/SimpleTable.d.ts +19 -1
- package/lib/components/template/SimpleTable/SimpleTable/SimpleTable.d.ts.map +1 -1
- package/lib/components/template/SimpleTable/SimpleTable/SimpleTable.js +62 -13
- package/lib/components/template/SimpleTable/SimpleTable/SimpleTable.js.map +1 -1
- package/lib/components/template/SimpleTable/SimpleTableManual/SimpleTableManual.d.ts +24 -2
- package/lib/components/template/SimpleTable/SimpleTableManual/SimpleTableManual.d.ts.map +1 -1
- package/lib/components/template/SimpleTable/SimpleTableManual/SimpleTableManual.js +120 -130
- package/lib/components/template/SimpleTable/SimpleTableManual/SimpleTableManual.js.map +1 -1
- package/lib/components/template/SimpleTable/SimpleTableSelect/SimpleTableSelect.d.ts +14 -29
- package/lib/components/template/SimpleTable/SimpleTableSelect/SimpleTableSelect.d.ts.map +1 -1
- package/lib/components/template/SimpleTable/SimpleTableSelect/SimpleTableSelect.js +15 -33
- package/lib/components/template/SimpleTable/SimpleTableSelect/SimpleTableSelect.js.map +1 -1
- package/lib/components/template/SingleReferenceReadOnly/SingleReferenceReadOnly.d.ts +14 -26
- package/lib/components/template/SingleReferenceReadOnly/SingleReferenceReadOnly.d.ts.map +1 -1
- package/lib/components/template/SingleReferenceReadOnly/SingleReferenceReadOnly.js +8 -29
- package/lib/components/template/SingleReferenceReadOnly/SingleReferenceReadOnly.js.map +1 -1
- package/lib/components/template/SubTabs/SubTabs.d.ts +5 -11
- package/lib/components/template/SubTabs/SubTabs.d.ts.map +1 -1
- package/lib/components/template/SubTabs/SubTabs.js +7 -17
- package/lib/components/template/SubTabs/SubTabs.js.map +1 -1
- package/lib/components/template/SubTabs/tabUtils.d.ts.map +1 -1
- package/lib/components/template/SubTabs/tabUtils.js +2 -4
- package/lib/components/template/SubTabs/tabUtils.js.map +1 -1
- package/lib/components/template/TwoColumn/TwoColumn/TwoColumn.css +0 -1
- package/lib/components/template/TwoColumn/TwoColumn/TwoColumn.d.ts +6 -12
- package/lib/components/template/TwoColumn/TwoColumn/TwoColumn.d.ts.map +1 -1
- package/lib/components/template/TwoColumn/TwoColumn/TwoColumn.js +15 -24
- package/lib/components/template/TwoColumn/TwoColumn/TwoColumn.js.map +1 -1
- package/lib/components/template/TwoColumn/TwoColumnPage/TwoColumnPage.d.ts +4 -8
- package/lib/components/template/TwoColumn/TwoColumnPage/TwoColumnPage.d.ts.map +1 -1
- package/lib/components/template/TwoColumn/TwoColumnPage/TwoColumnPage.js +5 -8
- package/lib/components/template/TwoColumn/TwoColumnPage/TwoColumnPage.js.map +1 -1
- package/lib/components/template/TwoColumn/TwoColumnTab/TwoColumnTab.d.ts +6 -12
- package/lib/components/template/TwoColumn/TwoColumnTab/TwoColumnTab.d.ts.map +1 -1
- package/lib/components/template/TwoColumn/TwoColumnTab/TwoColumnTab.js +15 -21
- package/lib/components/template/TwoColumn/TwoColumnTab/TwoColumnTab.js.map +1 -1
- package/lib/components/template/WideNarrow/WideNarrow/WideNarrow.css +0 -2
- package/lib/components/template/WideNarrow/WideNarrow/WideNarrow.d.ts +11 -2
- package/lib/components/template/WideNarrow/WideNarrow/WideNarrow.d.ts.map +1 -1
- package/lib/components/template/WideNarrow/WideNarrow/WideNarrow.js +3 -11
- package/lib/components/template/WideNarrow/WideNarrow/WideNarrow.js.map +1 -1
- package/lib/components/template/WideNarrow/WideNarrowDetails/WideNarrowDetails.d.ts +7 -15
- package/lib/components/template/WideNarrow/WideNarrowDetails/WideNarrowDetails.d.ts.map +1 -1
- package/lib/components/template/WideNarrow/WideNarrowDetails/WideNarrowDetails.js +23 -26
- package/lib/components/template/WideNarrow/WideNarrowDetails/WideNarrowDetails.js.map +1 -1
- package/lib/components/template/WideNarrow/WideNarrowForm/WideNarrowForm.css +0 -2
- package/lib/components/template/WideNarrow/WideNarrowForm/WideNarrowForm.d.ts +6 -2
- package/lib/components/template/WideNarrow/WideNarrowForm/WideNarrowForm.d.ts.map +1 -1
- package/lib/components/template/WideNarrow/WideNarrowForm/WideNarrowForm.js +2 -5
- package/lib/components/template/WideNarrow/WideNarrowForm/WideNarrowForm.js.map +1 -1
- package/lib/components/template/WideNarrow/WideNarrowPage/WideNarrowPage.d.ts +8 -15
- package/lib/components/template/WideNarrow/WideNarrowPage/WideNarrowPage.d.ts.map +1 -1
- package/lib/components/template/WideNarrow/WideNarrowPage/WideNarrowPage.js +7 -17
- package/lib/components/template/WideNarrow/WideNarrowPage/WideNarrowPage.js.map +1 -1
- package/lib/components/template/WideNarrow/WideNarrowPage/index.js.map +1 -1
- package/lib/components/template/WssNavBar/WssNavBar.d.ts +18 -1
- package/lib/components/template/WssNavBar/WssNavBar.d.ts.map +1 -1
- package/lib/components/template/WssNavBar/WssNavBar.js +20 -37
- package/lib/components/template/WssNavBar/WssNavBar.js.map +1 -1
- package/lib/components/widget/AppAnnouncement/AppAnnouncement.d.ts +9 -17
- package/lib/components/widget/AppAnnouncement/AppAnnouncement.d.ts.map +1 -1
- package/lib/components/widget/AppAnnouncement/AppAnnouncement.js +13 -37
- package/lib/components/widget/AppAnnouncement/AppAnnouncement.js.map +1 -1
- package/lib/components/widget/Attachment/Attachment.css +60 -1
- package/lib/components/widget/Attachment/Attachment.d.ts +8 -1
- package/lib/components/widget/Attachment/Attachment.d.ts.map +1 -1
- package/lib/components/widget/Attachment/Attachment.js +277 -343
- package/lib/components/widget/Attachment/Attachment.js.map +1 -1
- package/lib/components/widget/Attachment/index.js.map +1 -1
- package/lib/components/widget/CaseHistory/CaseHistory.d.ts +4 -7
- package/lib/components/widget/CaseHistory/CaseHistory.d.ts.map +1 -1
- package/lib/components/widget/CaseHistory/CaseHistory.js +38 -36
- package/lib/components/widget/CaseHistory/CaseHistory.js.map +1 -1
- package/lib/components/widget/CaseHistory/index.js.map +1 -1
- package/lib/components/widget/FileUtility/ActionButtonsForFileUtil/ActionButtonsForFileUtil.d.ts +9 -1
- package/lib/components/widget/FileUtility/ActionButtonsForFileUtil/ActionButtonsForFileUtil.d.ts.map +1 -1
- package/lib/components/widget/FileUtility/ActionButtonsForFileUtil/ActionButtonsForFileUtil.js +2 -4
- package/lib/components/widget/FileUtility/ActionButtonsForFileUtil/ActionButtonsForFileUtil.js.map +1 -1
- package/lib/components/widget/FileUtility/FileUtility/FileUtility.css +2 -2
- package/lib/components/widget/FileUtility/FileUtility/FileUtility.d.ts +5 -1
- package/lib/components/widget/FileUtility/FileUtility/FileUtility.d.ts.map +1 -1
- package/lib/components/widget/FileUtility/FileUtility/FileUtility.js +121 -140
- package/lib/components/widget/FileUtility/FileUtility/FileUtility.js.map +1 -1
- package/lib/components/widget/Followers/Followers.d.ts +5 -6
- package/lib/components/widget/Followers/Followers.d.ts.map +1 -1
- package/lib/components/widget/Followers/Followers.js +10 -25
- package/lib/components/widget/Followers/Followers.js.map +1 -1
- package/lib/components/widget/QuickCreate/QuickCreate.d.ts +8 -1
- package/lib/components/widget/QuickCreate/QuickCreate.d.ts.map +1 -1
- package/lib/components/widget/QuickCreate/QuickCreate.js +59 -29
- package/lib/components/widget/QuickCreate/QuickCreate.js.map +1 -1
- package/lib/components/widget/SummaryItem/SummaryItem.css +9 -9
- package/lib/components/widget/SummaryItem/SummaryItem.d.ts +8 -1
- package/lib/components/widget/SummaryItem/SummaryItem.d.ts.map +1 -1
- package/lib/components/widget/SummaryItem/SummaryItem.js +8 -23
- package/lib/components/widget/SummaryItem/SummaryItem.js.map +1 -1
- package/lib/components/widget/SummaryItem/index.js.map +1 -1
- package/lib/components/widget/SummaryList/SummaryList.d.ts +8 -1
- package/lib/components/widget/SummaryList/SummaryList.d.ts.map +1 -1
- package/lib/components/widget/SummaryList/SummaryList.js +6 -3
- package/lib/components/widget/SummaryList/SummaryList.js.map +1 -1
- package/lib/components/widget/ToDo/ToDo.css +4 -4
- package/lib/components/widget/ToDo/ToDo.d.ts +13 -27
- package/lib/components/widget/ToDo/ToDo.d.ts.map +1 -1
- package/lib/components/widget/ToDo/ToDo.js +26 -98
- package/lib/components/widget/ToDo/ToDo.js.map +1 -1
- package/lib/components_map.d.ts +2 -2
- package/lib/components_map.d.ts.map +1 -1
- package/lib/components_map.js +4 -2
- package/lib/components_map.js.map +1 -1
- package/lib/doc/KeyReleaseUpdates.md +39 -0
- package/lib/hooks/index.d.ts +4 -0
- package/lib/hooks/index.d.ts.map +1 -0
- package/lib/hooks/index.js +4 -0
- package/lib/hooks/index.js.map +1 -0
- package/lib/hooks/useAfterInitialEffect.d.ts +9 -0
- package/lib/hooks/useAfterInitialEffect.d.ts.map +1 -0
- package/lib/hooks/useAfterInitialEffect.js +16 -0
- package/lib/hooks/useAfterInitialEffect.js.map +1 -0
- package/lib/hooks/useConsolidatedRef.d.ts +9 -0
- package/lib/hooks/useConsolidatedRef.d.ts.map +1 -0
- package/lib/hooks/useConsolidatedRef.js +30 -0
- package/lib/hooks/useConsolidatedRef.js.map +1 -0
- package/lib/hooks/useUID.d.ts +8 -0
- package/lib/hooks/useUID.d.ts.map +1 -0
- package/lib/hooks/useUID.js +14 -0
- package/lib/hooks/useUID.js.map +1 -0
- package/lib/index.d.ts +1 -0
- package/lib/index.d.ts.map +1 -1
- package/lib/index.js +2 -1
- package/lib/index.js.map +1 -1
- package/lib/sdk-local-component-map.js +2 -2
- package/lib/sdk-pega-component-map.d.ts +21 -1
- package/lib/sdk-pega-component-map.js +112 -92
- package/lib/sdk-pega-component-map.js.map +1 -1
- package/lib/types/PConnProps.d.ts +41 -0
- package/package.json +5 -2
- package/lib/components/helpers/auth.d.ts +0 -16
- package/lib/components/helpers/auth.d.ts.map +0 -1
- package/lib/components/helpers/auth.js +0 -437
- package/lib/components/helpers/auth.js.map +0 -1
- package/lib/components/helpers/authManager.d.ts +0 -18
- package/lib/components/helpers/authManager.d.ts.map +0 -1
- package/lib/components/helpers/authManager.js +0 -592
- package/lib/components/helpers/authManager.js.map +0 -1
- package/lib/components/helpers/config_access.d.ts +0 -3
- package/lib/components/helpers/config_access.d.ts.map +0 -1
- package/lib/components/helpers/config_access.js +0 -261
- package/lib/components/helpers/config_access.js.map +0 -1
|
@@ -1,592 +0,0 @@
|
|
|
1
|
-
// This file wraps various calls related to logging in, logging out, etc.
|
|
2
|
-
// that use the auth.html/auth.js to do the work of logging in via OAuth 2.0.
|
|
3
|
-
import { getSdkConfig, SdkConfigAccess } from './config_access';
|
|
4
|
-
import PegaAuth from './auth';
|
|
5
|
-
// eslint-disable-next-line import/no-mutable-exports
|
|
6
|
-
export let gbLoggedIn = sessionStorage.getItem('rsdk_AH') !== null;
|
|
7
|
-
// eslint-disable-next-line import/no-mutable-exports
|
|
8
|
-
export let gbLoginInProgress = sessionStorage.getItem("rsdk_loggingIn") !== null;
|
|
9
|
-
// other sessionStorage items: rsdk_appName
|
|
10
|
-
// will store the PegaAuth instance
|
|
11
|
-
let authMgr = null;
|
|
12
|
-
// Since this variable is loaded in a separate instance in the popup scenario, use storage to coordinate across the two
|
|
13
|
-
let usePopupForRestOfSession = sessionStorage.getItem("rsdk_popup") === "1";
|
|
14
|
-
let gbC11NBootstrapInProgress = false;
|
|
15
|
-
// Some non Pega OAuth 2.0 Authentication in use (Basic or Custom for service package)
|
|
16
|
-
let gbCustomAuth = false;
|
|
17
|
-
/*
|
|
18
|
-
* Set to use popup experience for rest of session
|
|
19
|
-
*/
|
|
20
|
-
const forcePopupForReauths = (bForce) => {
|
|
21
|
-
if (bForce) {
|
|
22
|
-
sessionStorage.setItem("rsdk_popup", "1");
|
|
23
|
-
usePopupForRestOfSession = true;
|
|
24
|
-
}
|
|
25
|
-
else {
|
|
26
|
-
sessionStorage.removeItem("rsdk_popup");
|
|
27
|
-
usePopupForRestOfSession = false;
|
|
28
|
-
}
|
|
29
|
-
};
|
|
30
|
-
const setNoInitialRedirect = (bNoInitialRedirect) => {
|
|
31
|
-
if (bNoInitialRedirect) {
|
|
32
|
-
forcePopupForReauths(true);
|
|
33
|
-
sessionStorage.setItem("rsdk_noRedirect", "1");
|
|
34
|
-
}
|
|
35
|
-
else {
|
|
36
|
-
sessionStorage.removeItem("rsdk_noRedirect");
|
|
37
|
-
}
|
|
38
|
-
};
|
|
39
|
-
const isLoginExpired = () => {
|
|
40
|
-
let bExpired = true;
|
|
41
|
-
const sLoginStart = sessionStorage.getItem("rsdk_loggingIn");
|
|
42
|
-
if (sLoginStart !== null) {
|
|
43
|
-
const currTime = Date.now();
|
|
44
|
-
bExpired = currTime - parseInt(sLoginStart, 10) > 60000;
|
|
45
|
-
}
|
|
46
|
-
return bExpired;
|
|
47
|
-
};
|
|
48
|
-
/**
|
|
49
|
-
* Clean up any web storage allocated for the user session.
|
|
50
|
-
*/
|
|
51
|
-
const clearAuthMgr = (bFullReauth = false) => {
|
|
52
|
-
// Remove any local storage for the user
|
|
53
|
-
if (!gbCustomAuth) {
|
|
54
|
-
sessionStorage.removeItem('rsdk_AH');
|
|
55
|
-
}
|
|
56
|
-
if (!bFullReauth) {
|
|
57
|
-
sessionStorage.removeItem("rsdk_CI");
|
|
58
|
-
}
|
|
59
|
-
sessionStorage.removeItem("rsdk_TI");
|
|
60
|
-
sessionStorage.removeItem("rsdk_UI");
|
|
61
|
-
sessionStorage.removeItem("rsdk_loggingIn");
|
|
62
|
-
gbLoggedIn = false;
|
|
63
|
-
gbLoginInProgress = false;
|
|
64
|
-
forcePopupForReauths(bFullReauth);
|
|
65
|
-
// Not removing the authMgr structure itself...as it can be leveraged on next login
|
|
66
|
-
};
|
|
67
|
-
export const authNoRedirect = () => {
|
|
68
|
-
return sessionStorage.getItem("rsdk_noRedirect") === "1";
|
|
69
|
-
};
|
|
70
|
-
/**
|
|
71
|
-
* Initialize OAuth config structure members and create authMgr instance
|
|
72
|
-
* bInit - governs whether to create new sessionStorage or load existing one
|
|
73
|
-
*/
|
|
74
|
-
const initOAuth = (bInit) => {
|
|
75
|
-
return getSdkConfig().then(sdkConfig => {
|
|
76
|
-
const sdkConfigAuth = sdkConfig.authConfig;
|
|
77
|
-
const sdkConfigServer = sdkConfig.serverConfig;
|
|
78
|
-
let pegaUrl = sdkConfigServer.infinityRestServerUrl;
|
|
79
|
-
const bNoInitialRedirect = authNoRedirect();
|
|
80
|
-
// Construct default OAuth endpoints (if not explicitly specified)
|
|
81
|
-
if (pegaUrl) {
|
|
82
|
-
// Cope with trailing slash being present
|
|
83
|
-
if (!pegaUrl.endsWith('/')) {
|
|
84
|
-
pegaUrl += '/';
|
|
85
|
-
}
|
|
86
|
-
if (!sdkConfigAuth.authorize) {
|
|
87
|
-
sdkConfigAuth.authorize = `${pegaUrl}PRRestService/oauth2/v1/authorize`;
|
|
88
|
-
}
|
|
89
|
-
if (!sdkConfigAuth.token) {
|
|
90
|
-
sdkConfigAuth.token = `${pegaUrl}PRRestService/oauth2/v1/token`;
|
|
91
|
-
}
|
|
92
|
-
if (!sdkConfigAuth.revoke) {
|
|
93
|
-
sdkConfigAuth.revoke = `${pegaUrl}PRRestService/oauth2/v1/revoke`;
|
|
94
|
-
}
|
|
95
|
-
if (!sdkConfigAuth.redirectUri) {
|
|
96
|
-
sdkConfigAuth.redirectUri = `${window.location.origin}${window.location.pathname}`;
|
|
97
|
-
}
|
|
98
|
-
if (!sdkConfigAuth.userinfo) {
|
|
99
|
-
const appAliasSeg = sdkConfigServer.appAlias ? `app/${sdkConfigServer.appAlias}/` : '';
|
|
100
|
-
sdkConfigAuth.userinfo = `${pegaUrl}${appAliasSeg}api/oauthclients/v1/userinfo/JSON`;
|
|
101
|
-
}
|
|
102
|
-
}
|
|
103
|
-
// Auth service alias
|
|
104
|
-
if (!sdkConfigAuth.authService) {
|
|
105
|
-
sdkConfigAuth.authService = "pega";
|
|
106
|
-
}
|
|
107
|
-
// Construct path to auth.html (used for case when not doing a main window redirect)
|
|
108
|
-
let sNoMainRedirectUri = sdkConfigAuth.redirectUri;
|
|
109
|
-
const nLastPathSep = sNoMainRedirectUri.lastIndexOf("/");
|
|
110
|
-
sNoMainRedirectUri = nLastPathSep !== -1 ? `${sNoMainRedirectUri.substring(0, nLastPathSep + 1)}auth.html` : `${sNoMainRedirectUri}/auth.html`;
|
|
111
|
-
const authConfig = {
|
|
112
|
-
clientId: bNoInitialRedirect ? sdkConfigAuth.mashupClientId : sdkConfigAuth.portalClientId,
|
|
113
|
-
authorizeUri: sdkConfigAuth.authorize,
|
|
114
|
-
tokenUri: sdkConfigAuth.token,
|
|
115
|
-
revokeUri: sdkConfigAuth.revoke,
|
|
116
|
-
userinfoUri: sdkConfigAuth.userinfo,
|
|
117
|
-
redirectUri: bNoInitialRedirect || usePopupForRestOfSession
|
|
118
|
-
? sNoMainRedirectUri
|
|
119
|
-
: sdkConfigAuth.redirectUri,
|
|
120
|
-
authService: sdkConfigAuth.authService,
|
|
121
|
-
appAlias: sdkConfigServer.appAlias || '',
|
|
122
|
-
useLocking: true
|
|
123
|
-
};
|
|
124
|
-
// If no clientId is specified assume not OAuth but custom auth
|
|
125
|
-
if (!authConfig.clientId) {
|
|
126
|
-
gbCustomAuth = true;
|
|
127
|
-
return;
|
|
128
|
-
}
|
|
129
|
-
if ('silentTimeout' in sdkConfigAuth) {
|
|
130
|
-
authConfig.silentTimeout = sdkConfigAuth.silentTimeout;
|
|
131
|
-
}
|
|
132
|
-
if (bNoInitialRedirect && sdkConfigAuth.mashupUserIdentifier && sdkConfigAuth.mashupPassword) {
|
|
133
|
-
authConfig.userIdentifier = sdkConfigAuth.mashupUserIdentifier;
|
|
134
|
-
authConfig.password = sdkConfigAuth.mashupPassword;
|
|
135
|
-
}
|
|
136
|
-
if ('iframeLoginUI' in sdkConfigAuth) {
|
|
137
|
-
authConfig.iframeLoginUI = sdkConfigAuth.iframeLoginUI.toString().toLowerCase() === 'true';
|
|
138
|
-
}
|
|
139
|
-
// Check if sessionStorage exists (and if so if for same authorize endpoint). Otherwise, assume
|
|
140
|
-
// sessionStorage is out of date (user just edited endpoints). Else, logout required to clear
|
|
141
|
-
// sessionStorage and get other endpoints updates.
|
|
142
|
-
// Doing this as sessionIndex might have been added to this storage structure
|
|
143
|
-
let sSI = sessionStorage.getItem("rsdk_CI");
|
|
144
|
-
if (sSI) {
|
|
145
|
-
try {
|
|
146
|
-
const oSI = JSON.parse(sSI);
|
|
147
|
-
const aProps = ['authorizeUri', 'appAlias', 'clientId', 'authService', 'userIdentifier'];
|
|
148
|
-
for (let i = 0; i < aProps.length; i += 1) {
|
|
149
|
-
const prop = aProps[i];
|
|
150
|
-
const currValue = oSI[prop];
|
|
151
|
-
const newValue = authConfig[prop];
|
|
152
|
-
if (currValue !== newValue) {
|
|
153
|
-
// eslint-disable-next-line no-console
|
|
154
|
-
console.warn(`Clearing credentials due to mismatch for property: ${prop};` +
|
|
155
|
-
`currValue (${currValue}) does not match new desired value (${newValue})`);
|
|
156
|
-
clearAuthMgr();
|
|
157
|
-
sSI = null;
|
|
158
|
-
break;
|
|
159
|
-
}
|
|
160
|
-
}
|
|
161
|
-
}
|
|
162
|
-
catch (e) {
|
|
163
|
-
// do nothing
|
|
164
|
-
}
|
|
165
|
-
}
|
|
166
|
-
if (!sSI || bInit) {
|
|
167
|
-
sessionStorage.setItem('rsdk_CI', JSON.stringify(authConfig));
|
|
168
|
-
}
|
|
169
|
-
authMgr = new PegaAuth('rsdk_CI');
|
|
170
|
-
});
|
|
171
|
-
};
|
|
172
|
-
const getAuthMgr = (bInit) => {
|
|
173
|
-
return new Promise((resolve) => {
|
|
174
|
-
let idNextCheck = null;
|
|
175
|
-
const fnCheckForAuthMgr = () => {
|
|
176
|
-
if (PegaAuth && !authMgr) {
|
|
177
|
-
initOAuth(bInit);
|
|
178
|
-
}
|
|
179
|
-
if (authMgr) {
|
|
180
|
-
if (idNextCheck) {
|
|
181
|
-
clearInterval(idNextCheck);
|
|
182
|
-
}
|
|
183
|
-
return resolve(authMgr);
|
|
184
|
-
}
|
|
185
|
-
};
|
|
186
|
-
fnCheckForAuthMgr();
|
|
187
|
-
idNextCheck = setInterval(fnCheckForAuthMgr, 10);
|
|
188
|
-
});
|
|
189
|
-
};
|
|
190
|
-
export const sdkGetAuthHeader = () => {
|
|
191
|
-
return sessionStorage.getItem("rsdk_AH");
|
|
192
|
-
};
|
|
193
|
-
/**
|
|
194
|
-
* Initiate the process to get the Constellation bootstrap shell loaded and initialized
|
|
195
|
-
* @param {Object} authConfig
|
|
196
|
-
* @param {Object} tokenInfo
|
|
197
|
-
* @param {Function} authTokenUpdated - callback invoked when Constellation JS Engine silently updates
|
|
198
|
-
* an expired access_token
|
|
199
|
-
* @param {Function} fnReauth - callback invoked when a full or custom reauth is needed
|
|
200
|
-
*/
|
|
201
|
-
const constellationInit = (authConfig, tokenInfo, authTokenUpdated, fnReauth) => {
|
|
202
|
-
const constellationBootConfig = {};
|
|
203
|
-
const sdkConfigServer = SdkConfigAccess.getSdkConfigServer();
|
|
204
|
-
// Set up constellationConfig with data that bootstrapWithAuthHeader expects
|
|
205
|
-
constellationBootConfig.customRendering = true;
|
|
206
|
-
constellationBootConfig.restServerUrl = sdkConfigServer.infinityRestServerUrl;
|
|
207
|
-
// NOTE: Needs a trailing slash! So add one if not provided
|
|
208
|
-
if (!sdkConfigServer.sdkContentServerUrl.endsWith('/')) {
|
|
209
|
-
sdkConfigServer.sdkContentServerUrl = `${sdkConfigServer.sdkContentServerUrl}/`;
|
|
210
|
-
}
|
|
211
|
-
constellationBootConfig.staticContentServerUrl = `${sdkConfigServer.sdkContentServerUrl}constellation/`;
|
|
212
|
-
if (!constellationBootConfig.staticContentServerUrl.endsWith('/')) {
|
|
213
|
-
constellationBootConfig.staticContentServerUrl = `${constellationBootConfig.staticContentServerUrl}/`;
|
|
214
|
-
}
|
|
215
|
-
// If appAlias specified, use it
|
|
216
|
-
if (sdkConfigServer.appAlias) {
|
|
217
|
-
constellationBootConfig.appAlias = sdkConfigServer.appAlias;
|
|
218
|
-
}
|
|
219
|
-
if (tokenInfo) {
|
|
220
|
-
// Pass in auth info to Constellation
|
|
221
|
-
constellationBootConfig.authInfo = {
|
|
222
|
-
authType: "OAuth2.0",
|
|
223
|
-
tokenInfo,
|
|
224
|
-
// Set whether we want constellation to try to do a full re-Auth or not ()
|
|
225
|
-
// true doesn't seem to be working in SDK scenario so always passing false for now
|
|
226
|
-
popupReauth: false /* !authNoRedirect() */,
|
|
227
|
-
client_id: authConfig.clientId,
|
|
228
|
-
authentication_service: authConfig.authService,
|
|
229
|
-
redirect_uri: authConfig.redirectUri,
|
|
230
|
-
endPoints: {
|
|
231
|
-
authorize: authConfig.authorizeUri,
|
|
232
|
-
token: authConfig.tokenUri,
|
|
233
|
-
revoke: authConfig.revokeUri
|
|
234
|
-
},
|
|
235
|
-
// TODO: setup callback so we can update own storage
|
|
236
|
-
onTokenRetrieval: authTokenUpdated
|
|
237
|
-
};
|
|
238
|
-
}
|
|
239
|
-
else {
|
|
240
|
-
constellationBootConfig.authorizationHeader = sdkGetAuthHeader();
|
|
241
|
-
}
|
|
242
|
-
// Turn off dynamic load components (should be able to do it here instead of after load?)
|
|
243
|
-
constellationBootConfig.dynamicLoadComponents = false;
|
|
244
|
-
if (gbC11NBootstrapInProgress) {
|
|
245
|
-
return;
|
|
246
|
-
}
|
|
247
|
-
else {
|
|
248
|
-
gbC11NBootstrapInProgress = true;
|
|
249
|
-
}
|
|
250
|
-
// Note that staticContentServerUrl already ends with a slash (see above), so no slash added.
|
|
251
|
-
// In order to have this import succeed and to have it done with the webpackIgnore magic comment tag.
|
|
252
|
-
// See: https://webpack.js.org/api/module-methods/
|
|
253
|
-
import(/* webpackIgnore: true */ `${constellationBootConfig.staticContentServerUrl}bootstrap-shell.js`).then((bootstrapShell) => {
|
|
254
|
-
// NOTE: once this callback is done, we lose the ability to access loadMashup.
|
|
255
|
-
// So, create a reference to it
|
|
256
|
-
window.myLoadMashup = bootstrapShell.loadMashup;
|
|
257
|
-
window.myLoadPortal = bootstrapShell.loadPortal;
|
|
258
|
-
window.myLoadDefaultPortal = bootstrapShell.loadDefaultPortal;
|
|
259
|
-
bootstrapShell.bootstrapWithAuthHeader(constellationBootConfig, 'pega-root').then(() => {
|
|
260
|
-
// eslint-disable-next-line no-console
|
|
261
|
-
console.log('Bootstrap successful!');
|
|
262
|
-
gbC11NBootstrapInProgress = false;
|
|
263
|
-
// Setup listener for the reauth event
|
|
264
|
-
if (tokenInfo) {
|
|
265
|
-
PCore.getPubSubUtils().subscribe(PCore.getConstants().PUB_SUB_EVENTS.EVENT_FULL_REAUTH, fnReauth, "authFullReauth");
|
|
266
|
-
}
|
|
267
|
-
else {
|
|
268
|
-
// customReauth event introduced with 8.8
|
|
269
|
-
const sEvent = PCore.getConstants().PUB_SUB_EVENTS.EVENT_CUSTOM_REAUTH;
|
|
270
|
-
if (sEvent) {
|
|
271
|
-
PCore.getPubSubUtils().subscribe(sEvent, fnReauth, "doReauth");
|
|
272
|
-
}
|
|
273
|
-
}
|
|
274
|
-
// Fire SdkConstellationReady event so bridge and app route can do expected post PCore initializations
|
|
275
|
-
const event = new CustomEvent('SdkConstellationReady', {});
|
|
276
|
-
document.dispatchEvent(event);
|
|
277
|
-
})
|
|
278
|
-
.catch(e => {
|
|
279
|
-
// Assume error caught is because token is not valid and attempt a full reauth
|
|
280
|
-
// eslint-disable-next-line no-console
|
|
281
|
-
console.error(`Constellation JS Engine bootstrap failed. ${e}`);
|
|
282
|
-
gbC11NBootstrapInProgress = false;
|
|
283
|
-
fnReauth();
|
|
284
|
-
});
|
|
285
|
-
});
|
|
286
|
-
/* Ends here */
|
|
287
|
-
};
|
|
288
|
-
export const updateLoginStatus = () => {
|
|
289
|
-
const sAuthHdr = sdkGetAuthHeader();
|
|
290
|
-
gbLoggedIn = sAuthHdr && sAuthHdr.length > 0;
|
|
291
|
-
};
|
|
292
|
-
const getCurrentTokens = () => {
|
|
293
|
-
let tokens = null;
|
|
294
|
-
const sTI = sessionStorage.getItem('rsdk_TI');
|
|
295
|
-
if (sTI) {
|
|
296
|
-
try {
|
|
297
|
-
tokens = JSON.parse(sTI);
|
|
298
|
-
}
|
|
299
|
-
catch (e) {
|
|
300
|
-
tokens = null;
|
|
301
|
-
}
|
|
302
|
-
}
|
|
303
|
-
return tokens;
|
|
304
|
-
};
|
|
305
|
-
const fireTokenAvailable = (token, bLoadC11N = true) => {
|
|
306
|
-
if (!token) {
|
|
307
|
-
// This is used on page reload to load the token from sessionStorage and carry on
|
|
308
|
-
token = getCurrentTokens();
|
|
309
|
-
if (!token) {
|
|
310
|
-
return;
|
|
311
|
-
}
|
|
312
|
-
}
|
|
313
|
-
sessionStorage.setItem('rsdk_AH', `${token.token_type} ${token.access_token}`);
|
|
314
|
-
updateLoginStatus();
|
|
315
|
-
// gbLoggedIn is getting updated in updateLoginStatus
|
|
316
|
-
gbLoggedIn = true;
|
|
317
|
-
gbLoginInProgress = false;
|
|
318
|
-
sessionStorage.removeItem("rsdk_loggingIn");
|
|
319
|
-
forcePopupForReauths(true);
|
|
320
|
-
const sSI = sessionStorage.getItem("rsdk_CI");
|
|
321
|
-
let authConfig = null;
|
|
322
|
-
if (sSI) {
|
|
323
|
-
try {
|
|
324
|
-
authConfig = JSON.parse(sSI);
|
|
325
|
-
}
|
|
326
|
-
catch (e) {
|
|
327
|
-
// do nothing
|
|
328
|
-
}
|
|
329
|
-
}
|
|
330
|
-
if (!window.PCore && bLoadC11N) {
|
|
331
|
-
// eslint-disable-next-line @typescript-eslint/no-use-before-define
|
|
332
|
-
constellationInit(authConfig, token, authTokenUpdated, authFullReauth);
|
|
333
|
-
}
|
|
334
|
-
/*
|
|
335
|
-
// Create and dispatch the SdkLoggedIn event to trigger constellationInit
|
|
336
|
-
const event = new CustomEvent('SdkLoggedIn', { detail: { authConfig, tokenInfo: token } });
|
|
337
|
-
document.dispatchEvent(event);
|
|
338
|
-
*/
|
|
339
|
-
};
|
|
340
|
-
const processTokenOnLogin = (token, bLoadC11N = true) => {
|
|
341
|
-
sessionStorage.setItem("rsdk_TI", JSON.stringify(token));
|
|
342
|
-
if (window.PCore) {
|
|
343
|
-
window.PCore.getAuthUtils().setTokens(token);
|
|
344
|
-
}
|
|
345
|
-
else {
|
|
346
|
-
fireTokenAvailable(token, bLoadC11N);
|
|
347
|
-
}
|
|
348
|
-
};
|
|
349
|
-
const updateRedirectUri = (aMgr, sRedirectUri) => {
|
|
350
|
-
const sSI = sessionStorage.getItem("rsdk_CI");
|
|
351
|
-
let authConfig = null;
|
|
352
|
-
if (sSI) {
|
|
353
|
-
try {
|
|
354
|
-
authConfig = JSON.parse(sSI);
|
|
355
|
-
}
|
|
356
|
-
catch (e) {
|
|
357
|
-
// do nothing
|
|
358
|
-
}
|
|
359
|
-
}
|
|
360
|
-
authConfig.redirectUri = sRedirectUri;
|
|
361
|
-
sessionStorage.setItem("rsdk_CI", JSON.stringify(authConfig));
|
|
362
|
-
aMgr.reloadConfig();
|
|
363
|
-
};
|
|
364
|
-
// TODO: Cope with 401 and refresh token if possible (or just hope that it succeeds during login)
|
|
365
|
-
/**
|
|
366
|
-
* Retrieve UserInfo for current authentication service
|
|
367
|
-
*/
|
|
368
|
-
export const getUserInfo = (bUseSS = true) => {
|
|
369
|
-
const ssUserInfo = sessionStorage.getItem("rsdk_UI");
|
|
370
|
-
let userInfo = null;
|
|
371
|
-
if (bUseSS && ssUserInfo) {
|
|
372
|
-
try {
|
|
373
|
-
userInfo = JSON.parse(ssUserInfo);
|
|
374
|
-
return Promise.resolve(userInfo);
|
|
375
|
-
}
|
|
376
|
-
catch (e) {
|
|
377
|
-
// do nothing
|
|
378
|
-
}
|
|
379
|
-
}
|
|
380
|
-
getAuthMgr(false).then((aMgr) => {
|
|
381
|
-
const tokenInfo = getCurrentTokens();
|
|
382
|
-
return aMgr.getUserinfo(tokenInfo.access_token).then(data => {
|
|
383
|
-
userInfo = data;
|
|
384
|
-
if (userInfo) {
|
|
385
|
-
sessionStorage.setItem("rsdk_UI", JSON.stringify(userInfo));
|
|
386
|
-
}
|
|
387
|
-
else {
|
|
388
|
-
sessionStorage.removeItem("rsdk_UI");
|
|
389
|
-
}
|
|
390
|
-
return Promise.resolve(userInfo);
|
|
391
|
-
});
|
|
392
|
-
});
|
|
393
|
-
};
|
|
394
|
-
export const login = (bFullReauth = false) => {
|
|
395
|
-
if (gbCustomAuth)
|
|
396
|
-
return;
|
|
397
|
-
gbLoginInProgress = true;
|
|
398
|
-
// Needed so a redirect to login screen and back will know we are still in process of logging in
|
|
399
|
-
sessionStorage.setItem("rsdk_loggingIn", `${Date.now()}`);
|
|
400
|
-
getAuthMgr(!bFullReauth).then((aMgr) => {
|
|
401
|
-
const bMainRedirect = !authNoRedirect();
|
|
402
|
-
const sdkConfigAuth = SdkConfigAccess.getSdkConfigAuth();
|
|
403
|
-
let sRedirectUri = sdkConfigAuth.redirectUri;
|
|
404
|
-
// If initial main redirect is OK, redirect to main page, otherwise will authorize in a popup window
|
|
405
|
-
if (bMainRedirect && !bFullReauth) {
|
|
406
|
-
// update redirect uri to be the root
|
|
407
|
-
updateRedirectUri(aMgr, sRedirectUri);
|
|
408
|
-
aMgr.loginRedirect();
|
|
409
|
-
// Don't have token til after the redirect
|
|
410
|
-
return Promise.resolve(undefined);
|
|
411
|
-
}
|
|
412
|
-
else {
|
|
413
|
-
// Construct path to redirect uri
|
|
414
|
-
const nLastPathSep = sRedirectUri.lastIndexOf("/");
|
|
415
|
-
sRedirectUri = nLastPathSep !== -1 ? `${sRedirectUri.substring(0, nLastPathSep + 1)}auth.html` : `${sRedirectUri}/auth.html`;
|
|
416
|
-
// Set redirectUri to static auth.html
|
|
417
|
-
updateRedirectUri(aMgr, sRedirectUri);
|
|
418
|
-
return new Promise((resolve, reject) => {
|
|
419
|
-
aMgr.login().then(token => {
|
|
420
|
-
processTokenOnLogin(token);
|
|
421
|
-
// getUserInfo();
|
|
422
|
-
resolve(token.access_token);
|
|
423
|
-
}).catch((e) => {
|
|
424
|
-
gbLoginInProgress = false;
|
|
425
|
-
sessionStorage.removeItem("rsdk_loggingIn");
|
|
426
|
-
// eslint-disable-next-line no-console
|
|
427
|
-
console.log(e);
|
|
428
|
-
reject(e);
|
|
429
|
-
});
|
|
430
|
-
});
|
|
431
|
-
}
|
|
432
|
-
});
|
|
433
|
-
};
|
|
434
|
-
export const authRedirectCallback = (href, fnLoggedInCB = null) => {
|
|
435
|
-
// Get code from href and swap for token
|
|
436
|
-
const aHrefParts = href.split('?');
|
|
437
|
-
const urlParams = new URLSearchParams(aHrefParts.length > 1 ? `?${aHrefParts[1]}` : '');
|
|
438
|
-
const code = urlParams.get("code");
|
|
439
|
-
getAuthMgr(false).then((aMgr) => {
|
|
440
|
-
aMgr.getToken(code).then(token => {
|
|
441
|
-
if (token && token.access_token) {
|
|
442
|
-
processTokenOnLogin(token, false);
|
|
443
|
-
// getUserInfo();
|
|
444
|
-
if (fnLoggedInCB) {
|
|
445
|
-
fnLoggedInCB(token.access_token);
|
|
446
|
-
}
|
|
447
|
-
}
|
|
448
|
-
});
|
|
449
|
-
});
|
|
450
|
-
};
|
|
451
|
-
/**
|
|
452
|
-
* Silent or visible login based on login status
|
|
453
|
-
* @param {string} appName - unique name for application route (will be used to clear an session storage for another route)
|
|
454
|
-
* @param {boolean} noMainRedirect - avoid the initial main window redirect that happens in scenarios where it is OK to transition
|
|
455
|
-
* away from the main page
|
|
456
|
-
* @param {boolean} deferLogin - defer logging in (if not already authenticated)
|
|
457
|
-
*/
|
|
458
|
-
export const loginIfNecessary = (appName, noMainRedirect = false, deferLogin = false) => {
|
|
459
|
-
// If no initial redirect status of page changed...clearAuthMgr
|
|
460
|
-
const currNoMainRedirect = authNoRedirect();
|
|
461
|
-
const currAppName = sessionStorage.getItem("rsdk_appName");
|
|
462
|
-
if (appName !== currAppName || noMainRedirect !== currNoMainRedirect) {
|
|
463
|
-
clearAuthMgr();
|
|
464
|
-
sessionStorage.setItem("rsdk_appName", appName);
|
|
465
|
-
}
|
|
466
|
-
setNoInitialRedirect(noMainRedirect);
|
|
467
|
-
// If custom auth no need to do any OAuth logic
|
|
468
|
-
if (gbCustomAuth) {
|
|
469
|
-
if (!window.PCore) {
|
|
470
|
-
// eslint-disable-next-line @typescript-eslint/no-use-before-define
|
|
471
|
-
constellationInit(null, null, null, authCustomReauth);
|
|
472
|
-
}
|
|
473
|
-
return;
|
|
474
|
-
}
|
|
475
|
-
if (window.location.href.indexOf("?code") !== -1) {
|
|
476
|
-
// initialize authMgr
|
|
477
|
-
initOAuth(false);
|
|
478
|
-
return getAuthMgr(false).then(() => {
|
|
479
|
-
authRedirectCallback(window.location.href, () => {
|
|
480
|
-
window.location.href = window.location.pathname;
|
|
481
|
-
});
|
|
482
|
-
});
|
|
483
|
-
}
|
|
484
|
-
if (!deferLogin && (!gbLoginInProgress || isLoginExpired())) {
|
|
485
|
-
initOAuth(false);
|
|
486
|
-
return getAuthMgr(false).then(() => {
|
|
487
|
-
updateLoginStatus();
|
|
488
|
-
if (gbLoggedIn) {
|
|
489
|
-
fireTokenAvailable(getCurrentTokens());
|
|
490
|
-
// getUserInfo();
|
|
491
|
-
}
|
|
492
|
-
else {
|
|
493
|
-
return login();
|
|
494
|
-
}
|
|
495
|
-
});
|
|
496
|
-
}
|
|
497
|
-
};
|
|
498
|
-
export const getHomeUrl = () => {
|
|
499
|
-
return `${window.location.origin}/`;
|
|
500
|
-
};
|
|
501
|
-
export const authIsMainRedirect = () => {
|
|
502
|
-
// Even with main redirect, we want to use it only for the first login (so it doesn't wipe out any state or the reload)
|
|
503
|
-
return !authNoRedirect() && !usePopupForRestOfSession;
|
|
504
|
-
};
|
|
505
|
-
// Passive update where just session storage is updated so can be used on a window refresh
|
|
506
|
-
export const authTokenUpdated = (tokenInfo) => {
|
|
507
|
-
sessionStorage.setItem("rsdk_TI", JSON.stringify(tokenInfo));
|
|
508
|
-
};
|
|
509
|
-
export const logout = () => {
|
|
510
|
-
sessionStorage.removeItem('rsdk_portalName');
|
|
511
|
-
return new Promise((resolve) => {
|
|
512
|
-
const fnClearAndResolve = () => {
|
|
513
|
-
clearAuthMgr();
|
|
514
|
-
const event = new Event('SdkLoggedOut');
|
|
515
|
-
document.dispatchEvent(event);
|
|
516
|
-
resolve();
|
|
517
|
-
};
|
|
518
|
-
if (gbCustomAuth) {
|
|
519
|
-
sessionStorage.removeItem("rsdk_AH");
|
|
520
|
-
fnClearAndResolve();
|
|
521
|
-
return;
|
|
522
|
-
}
|
|
523
|
-
const tokenInfo = getCurrentTokens();
|
|
524
|
-
if (tokenInfo && tokenInfo.access_token) {
|
|
525
|
-
if (window.PCore) {
|
|
526
|
-
window.PCore.getAuthUtils().revokeTokens().then(() => {
|
|
527
|
-
fnClearAndResolve();
|
|
528
|
-
}).catch(err => {
|
|
529
|
-
// eslint-disable-next-line no-console
|
|
530
|
-
console.log("Error:", err?.message);
|
|
531
|
-
});
|
|
532
|
-
}
|
|
533
|
-
else {
|
|
534
|
-
getAuthMgr(false).then((aMgr) => {
|
|
535
|
-
aMgr.revokeTokens(tokenInfo.access_token, tokenInfo.refresh_token)
|
|
536
|
-
.then(() => {
|
|
537
|
-
// Go to finally
|
|
538
|
-
})
|
|
539
|
-
.finally(() => {
|
|
540
|
-
fnClearAndResolve();
|
|
541
|
-
});
|
|
542
|
-
});
|
|
543
|
-
}
|
|
544
|
-
}
|
|
545
|
-
else {
|
|
546
|
-
fnClearAndResolve();
|
|
547
|
-
}
|
|
548
|
-
});
|
|
549
|
-
};
|
|
550
|
-
// Callback routine for custom event to ask for updated tokens
|
|
551
|
-
export const authUpdateTokens = (token) => {
|
|
552
|
-
processTokenOnLogin(token);
|
|
553
|
-
};
|
|
554
|
-
// Initiate a full OAuth re-authorization (any refresh token has also expired).
|
|
555
|
-
export const authFullReauth = () => {
|
|
556
|
-
const bHandleHere = true; // Other alternative is to raise an event and have someone else handle it
|
|
557
|
-
if (bHandleHere) {
|
|
558
|
-
// Don't want to do a full clear of authMgr as will loose sessionIndex. Rather just clear the tokens
|
|
559
|
-
clearAuthMgr(true);
|
|
560
|
-
login(true);
|
|
561
|
-
}
|
|
562
|
-
else {
|
|
563
|
-
// Fire the SdkFullReauth event to indicate a new token is needed (PCore.getAuthUtils.setTokens method
|
|
564
|
-
// should be used to communicate the new token to Constellation JS Engine.
|
|
565
|
-
const event = new CustomEvent('SdkFullReauth', { detail: authUpdateTokens });
|
|
566
|
-
document.dispatchEvent(event);
|
|
567
|
-
}
|
|
568
|
-
};
|
|
569
|
-
// Set the custom authorization header for the SDK (and Constellation JS Engine) to
|
|
570
|
-
// utilize for every DX API request
|
|
571
|
-
export const sdkSetAuthHeader = (authHeader) => {
|
|
572
|
-
// set this within session storage so it survives a browser reload
|
|
573
|
-
if (authHeader) {
|
|
574
|
-
sessionStorage.setItem("rsdk_AH", authHeader);
|
|
575
|
-
// setAuthorizationHeader method not available til 8.8 so do safety check
|
|
576
|
-
if (window.PCore?.getAuthUtils().setAuthorizationHeader) {
|
|
577
|
-
window.PCore.getAuthUtils().setAuthorizationHeader(authHeader);
|
|
578
|
-
}
|
|
579
|
-
}
|
|
580
|
-
else {
|
|
581
|
-
sessionStorage.removeItem("rsdk_AH");
|
|
582
|
-
}
|
|
583
|
-
gbCustomAuth = true;
|
|
584
|
-
};
|
|
585
|
-
// Initiate a custom re-authorization.
|
|
586
|
-
export const authCustomReauth = () => {
|
|
587
|
-
// Fire the SdkCustomReauth event to indicate a new authHeader is needed. Event listener should invoke sdkSetAuthHeader
|
|
588
|
-
// to communicate the new token to sdk (and Constellation JS Engine)
|
|
589
|
-
const event = new CustomEvent('SdkCustomReauth', { detail: sdkSetAuthHeader });
|
|
590
|
-
document.dispatchEvent(event);
|
|
591
|
-
};
|
|
592
|
-
//# sourceMappingURL=authManager.js.map
|