@elliemae/pui-app-sdk 2.21.1 → 3.0.0-beta.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/analytics/appdynamics.js +40 -30
- package/dist/cjs/analytics/index.js +33 -26
- package/dist/cjs/analytics/page-view-event.js +35 -34
- package/dist/cjs/analytics/user-session-event.js +35 -27
- package/dist/cjs/analytics/user-wait-event.js +32 -17
- package/dist/cjs/analytics/web-analytics.js +33 -19
- package/dist/cjs/api/auth/index.js +42 -39
- package/dist/cjs/api/helpers.js +34 -99
- package/dist/cjs/api/users/index.js +29 -16
- package/dist/cjs/communication/http-client/index.js +50 -48
- package/dist/cjs/communication/http-client/request-interceptor.js +29 -12
- package/dist/cjs/communication/http-client/response-interceptor.js +47 -38
- package/dist/cjs/communication/http-client/retry-axios.js +74 -122
- package/dist/cjs/communication/http-client/retry.js +43 -36
- package/dist/cjs/communication/http-client/tests/index.test-disable.js +48 -56
- package/dist/cjs/data/auth/actions.js +34 -26
- package/dist/cjs/data/auth/reducer.js +36 -18
- package/dist/cjs/data/breakpoint/index.js +44 -32
- package/dist/cjs/data/error/index.js +34 -18
- package/dist/cjs/data/index.js +35 -0
- package/dist/cjs/data/live-message/index.js +35 -25
- package/dist/cjs/data/logout/actions.js +29 -9
- package/dist/cjs/data/navigation-prompt/actions.js +29 -9
- package/dist/cjs/data/react-redux.js +30 -13
- package/dist/cjs/data/reducers.js +36 -23
- package/dist/cjs/data/saga.js +29 -9
- package/dist/cjs/data/store.js +51 -65
- package/dist/cjs/data/wait-message/actions.js +31 -13
- package/dist/cjs/data/wait-message/reducer.js +38 -24
- package/dist/cjs/index.js +195 -809
- package/dist/cjs/micro-frontend.js +34 -0
- package/dist/cjs/route/index.js +44 -32
- package/dist/cjs/route/page-view.js +36 -22
- package/dist/cjs/route/private-route/index.js +59 -60
- package/dist/cjs/sideeffect/auth/index.js +43 -30
- package/dist/cjs/sideeffect/error-toast/index.js +40 -26
- package/dist/cjs/sideeffect/wait-message/index.js +46 -29
- package/dist/cjs/typings/custom.d.js +0 -0
- package/dist/cjs/typings/elliemae.d.js +0 -0
- package/dist/cjs/typings/styled.d.js +1 -0
- package/dist/cjs/typings/thirdparty.d.js +0 -0
- package/dist/cjs/utils/app-config/config.js +39 -33
- package/dist/cjs/utils/app-config/index.js +48 -44
- package/dist/cjs/utils/app-host-integration/react.js +28 -14
- package/dist/cjs/utils/auth/helper.js +36 -18
- package/dist/cjs/utils/auth/index.js +77 -116
- package/dist/cjs/utils/await.js +20 -0
- package/dist/cjs/utils/constants.js +39 -21
- package/dist/cjs/utils/font-size.js +30 -14
- package/dist/cjs/utils/guest-with-service.js +28 -12
- package/dist/cjs/utils/helpers.js +32 -19
- package/dist/cjs/utils/history.js +30 -12
- package/dist/cjs/utils/log-records.js +55 -35
- package/dist/cjs/utils/micro-frontend/console-logger.js +40 -23
- package/dist/cjs/utils/micro-frontend/guest.js +86 -127
- package/dist/cjs/utils/micro-frontend/host.js +86 -125
- package/dist/cjs/utils/micro-frontend/index.js +66 -61
- package/dist/cjs/utils/micro-frontend/types.js +20 -5
- package/dist/cjs/utils/redact-pii.js +32 -17
- package/dist/cjs/utils/service-worker.js +37 -21
- package/dist/cjs/utils/session.js +65 -70
- package/dist/cjs/utils/storybook/cjs/main.js +53 -0
- package/dist/cjs/utils/storybook/cjs/middleware.js +5 -0
- package/dist/cjs/utils/storybook/cjs/vite.js +6 -0
- package/dist/cjs/utils/storybook/cjs/webpack.js +21 -0
- package/dist/cjs/utils/storybook/manager.js +32 -16
- package/dist/cjs/utils/storybook/preview.js +59 -50
- package/dist/cjs/utils/storybook/theme.js +31 -14
- package/dist/cjs/utils/testing/index.js +45 -50
- package/dist/cjs/utils/testing/render-with-redux.js +41 -27
- package/dist/cjs/utils/testing/render-with-router-redux.js +47 -37
- package/dist/cjs/utils/testing/render-with-router.js +41 -28
- package/dist/cjs/utils/testing/render-with-state-addons.js +47 -36
- package/dist/cjs/utils/types.js +20 -0
- package/dist/cjs/utils/url.js +29 -13
- package/dist/cjs/utils/web-storage.js +46 -30
- package/dist/cjs/utils/window.js +37 -28
- package/dist/cjs/view/app-root/hosted-app.js +42 -32
- package/dist/cjs/view/app-root/index.js +64 -62
- package/dist/cjs/view/app-root/stand-alone-app.js +45 -37
- package/dist/cjs/view/app-root/style.js +51 -12
- package/dist/cjs/view/error-boundary/default-error-template.js +33 -15
- package/dist/cjs/view/error-boundary/index.js +47 -43
- package/dist/cjs/view/error-toast/index.js +49 -32
- package/dist/cjs/view/fetch-host-app-data/index.js +40 -26
- package/dist/cjs/view/fetch-host-app-data/store.js +32 -24
- package/dist/cjs/view/fields/check-box/index.js +41 -39
- package/dist/cjs/view/fields/combo-box/index.js +44 -31
- package/dist/cjs/view/fields/connect-form.js +31 -15
- package/dist/cjs/view/fields/date-input/index.js +41 -26
- package/dist/cjs/view/fields/date-picker/index.js +41 -26
- package/dist/cjs/view/fields/form-item-layout/index.js +43 -30
- package/dist/cjs/view/fields/input-mask/index.js +42 -41
- package/dist/cjs/view/fields/large-text-box/index.js +41 -26
- package/dist/cjs/view/fields/radio/index.js +41 -30
- package/dist/cjs/view/fields/radio-group/index.js +39 -27
- package/dist/cjs/view/fields/text-box/index.js +41 -26
- package/dist/cjs/view/fields/watch-value.js +48 -35
- package/dist/cjs/view/form/index.js +48 -34
- package/dist/cjs/view/form/personal-info-section.js +63 -80
- package/dist/cjs/view/form/submit-button/index.js +41 -23
- package/dist/cjs/view/guest-unload-handlers/index.js +34 -22
- package/dist/cjs/view/header/center-region/index.js +68 -38
- package/dist/cjs/view/header/index.js +48 -35
- package/dist/cjs/view/header/logo-region/index.js +38 -23
- package/dist/cjs/view/header/nav-region/index.js +51 -30
- package/dist/cjs/view/header/nav-region/notification/index.js +35 -18
- package/dist/cjs/view/header/nav-region/user/index.js +35 -18
- package/dist/cjs/view/host-binding-events/index.js +27 -11
- package/dist/cjs/view/intro.stories.mdx +1 -1
- package/dist/cjs/view/live-message/index.js +40 -34
- package/dist/cjs/view/loadable/index.js +40 -27
- package/dist/cjs/view/login/index.js +43 -30
- package/dist/cjs/view/media-breakpoint/index.js +50 -34
- package/dist/cjs/view/message-to-host-app/index.js +32 -20
- package/dist/cjs/view/micro-app/app-factory/index.js +101 -135
- package/dist/cjs/view/micro-app/const.js +27 -7
- package/dist/cjs/view/micro-app/index.js +44 -27
- package/dist/cjs/view/micro-app/resources/manifest.js +44 -35
- package/dist/cjs/view/micro-app/resources/script.js +57 -53
- package/dist/cjs/view/micro-app/resources/style.js +45 -38
- package/dist/cjs/view/micro-app/types.js +20 -5
- package/dist/cjs/view/micro-app/use-app-will-render.js +59 -50
- package/dist/cjs/view/micro-app/utils.js +33 -21
- package/dist/cjs/view/micro-iframe-app/app.js +44 -39
- package/dist/cjs/view/micro-iframe-app/iframe/const.js +27 -7
- package/dist/cjs/view/micro-iframe-app/iframe/index.js +58 -47
- package/dist/cjs/view/micro-iframe-app/index.js +43 -24
- package/dist/cjs/view/micro-iframe-app/types.js +20 -5
- package/dist/cjs/view/micro-iframe-app/use-frame-loaded.js +43 -37
- package/dist/cjs/view/modals/error/index.js +42 -28
- package/dist/cjs/view/modals/navigation-prompt/index.js +45 -37
- package/dist/cjs/view/modals/session-expiry/customHooks.js +41 -35
- package/dist/cjs/view/modals/session-expiry/index.js +53 -51
- package/dist/cjs/view/modals/wait-message/html-wait-message.js +39 -18
- package/dist/cjs/view/modals/wait-message/index.js +57 -53
- package/dist/cjs/view/modals/wait-message/wait-message-launcher.js +40 -21
- package/dist/cjs/view/render-with-delay/index.js +37 -19
- package/dist/cjs/view/render-with-host-data/index.js +42 -30
- package/dist/cjs/view/session-timeout/index.js +51 -35
- package/dist/cjs/view/storybook/decorator.js +39 -21
- package/dist/cjs/view/use-previous.js +30 -13
- package/dist/cjs/view/useMediaBreakpoints/index.js +35 -19
- package/dist/cjs/view/visually-hidden/index.js +48 -21
- package/dist/cjs/view/window-size/index.js +41 -22
- package/dist/es/analytics/appdynamics.js +14 -15
- package/dist/es/analytics/index.js +8 -14
- package/dist/es/analytics/page-view-event.js +11 -25
- package/dist/es/analytics/user-session-event.js +11 -13
- package/dist/es/analytics/user-wait-event.js +9 -5
- package/dist/es/analytics/web-analytics.js +12 -10
- package/dist/es/api/auth/index.js +21 -26
- package/dist/es/api/helpers.js +8 -81
- package/dist/es/api/users/index.js +6 -7
- package/dist/es/communication/http-client/index.js +19 -25
- package/dist/es/communication/http-client/request-interceptor.js +5 -2
- package/dist/es/communication/http-client/response-interceptor.js +20 -21
- package/dist/es/communication/http-client/retry-axios.js +45 -105
- package/dist/es/communication/http-client/retry.js +22 -25
- package/dist/es/communication/http-client/tests/index.test-disable.js +25 -44
- package/dist/es/data/auth/actions.js +13 -19
- package/dist/es/data/auth/reducer.js +8 -6
- package/dist/es/data/breakpoint/index.js +19 -21
- package/dist/es/data/error/index.js +11 -9
- package/dist/es/data/index.js +11 -0
- package/dist/es/data/live-message/index.js +12 -16
- package/dist/es/data/logout/actions.js +9 -5
- package/dist/es/data/navigation-prompt/actions.js +9 -5
- package/dist/es/data/react-redux.js +7 -3
- package/dist/es/data/reducers.js +6 -3
- package/dist/es/data/saga.js +8 -5
- package/dist/es/data/store.js +24 -51
- package/dist/es/data/wait-message/actions.js +11 -9
- package/dist/es/data/wait-message/reducer.js +9 -9
- package/dist/es/index.js +192 -83
- package/dist/es/micro-frontend.js +10 -0
- package/dist/es/route/index.js +16 -18
- package/dist/es/route/page-view.js +8 -8
- package/dist/es/route/private-route/index.js +24 -31
- package/dist/es/sideeffect/auth/index.js +24 -11
- package/dist/es/sideeffect/error-toast/index.js +11 -10
- package/dist/es/sideeffect/wait-message/index.js +14 -10
- package/dist/es/typings/custom.d.js +0 -0
- package/dist/es/typings/elliemae.d.js +0 -0
- package/dist/es/typings/styled.d.js +1 -0
- package/dist/es/typings/thirdparty.d.js +0 -0
- package/dist/es/utils/app-config/config.js +11 -9
- package/dist/es/utils/app-config/index.js +17 -27
- package/dist/es/utils/app-host-integration/react.js +8 -6
- package/dist/es/utils/auth/helper.js +7 -3
- package/dist/es/utils/auth/index.js +51 -75
- package/dist/es/utils/constants.js +18 -13
- package/dist/es/utils/font-size.js +7 -3
- package/dist/es/utils/guest-with-service.js +6 -7
- package/dist/es/utils/helpers.js +10 -6
- package/dist/es/utils/history.js +7 -3
- package/dist/es/utils/log-records.js +34 -31
- package/dist/es/utils/micro-frontend/console-logger.js +16 -12
- package/dist/es/utils/micro-frontend/guest.js +44 -100
- package/dist/es/utils/micro-frontend/host.js +41 -77
- package/dist/es/utils/micro-frontend/index.js +35 -33
- package/dist/es/utils/micro-frontend/types.js +0 -1
- package/dist/es/utils/redact-pii.js +10 -11
- package/dist/es/utils/service-worker.js +13 -10
- package/dist/es/utils/session.js +45 -46
- package/dist/es/utils/storybook/manager.js +7 -4
- package/dist/es/utils/storybook/preview.js +27 -24
- package/dist/es/utils/storybook/theme.js +9 -6
- package/dist/es/utils/testing/index.js +12 -18
- package/dist/es/utils/testing/render-with-redux.js +12 -11
- package/dist/es/utils/testing/render-with-router-redux.js +18 -19
- package/dist/es/utils/testing/render-with-router.js +15 -16
- package/dist/es/utils/testing/render-with-state-addons.js +19 -18
- package/dist/es/utils/url.js +7 -3
- package/dist/es/utils/web-storage.js +21 -17
- package/dist/es/utils/window.js +18 -18
- package/dist/es/view/app-root/hosted-app.js +10 -13
- package/dist/es/view/app-root/index.js +29 -33
- package/dist/es/view/app-root/stand-alone-app.js +11 -12
- package/dist/es/view/app-root/style.js +30 -5
- package/dist/es/view/error-boundary/default-error-template.js +5 -5
- package/dist/es/view/error-boundary/index.js +18 -25
- package/dist/es/view/error-toast/index.js +15 -14
- package/dist/es/view/fetch-host-app-data/index.js +14 -11
- package/dist/es/view/fetch-host-app-data/store.js +10 -7
- package/dist/es/view/fields/check-box/index.js +17 -18
- package/dist/es/view/fields/combo-box/index.js +20 -19
- package/dist/es/view/fields/connect-form.js +8 -6
- package/dist/es/view/fields/date-input/index.js +17 -14
- package/dist/es/view/fields/date-picker/index.js +17 -14
- package/dist/es/view/fields/form-item-layout/index.js +15 -15
- package/dist/es/view/fields/input-mask/index.js +22 -14
- package/dist/es/view/fields/large-text-box/index.js +17 -14
- package/dist/es/view/fields/radio/index.js +17 -18
- package/dist/es/view/fields/radio-group/index.js +15 -15
- package/dist/es/view/fields/text-box/index.js +17 -14
- package/dist/es/view/fields/watch-value.js +20 -24
- package/dist/es/view/form/index.js +23 -22
- package/dist/es/view/form/personal-info-section.js +28 -48
- package/dist/es/view/form/submit-button/index.js +13 -10
- package/dist/es/view/guest-unload-handlers/index.js +10 -9
- package/dist/es/view/header/center-region/index.js +41 -23
- package/dist/es/view/header/index.js +16 -15
- package/dist/es/view/header/logo-region/index.js +9 -9
- package/dist/es/view/header/nav-region/index.js +21 -13
- package/dist/es/view/header/nav-region/notification/index.js +6 -6
- package/dist/es/view/header/nav-region/user/index.js +6 -6
- package/dist/es/view/host-binding-events/index.js +7 -3
- package/dist/es/view/intro.stories.mdx +1 -1
- package/dist/es/view/live-message/index.js +13 -22
- package/dist/es/view/loadable/index.js +13 -15
- package/dist/es/view/login/index.js +12 -15
- package/dist/es/view/media-breakpoint/index.js +16 -13
- package/dist/es/view/message-to-host-app/index.js +10 -9
- package/dist/es/view/micro-app/app-factory/index.js +67 -82
- package/dist/es/view/micro-app/const.js +4 -1
- package/dist/es/view/micro-app/index.js +12 -9
- package/dist/es/view/micro-app/resources/manifest.js +17 -16
- package/dist/es/view/micro-app/resources/script.js +35 -35
- package/dist/es/view/micro-app/resources/style.js +22 -21
- package/dist/es/view/micro-app/types.js +0 -1
- package/dist/es/view/micro-app/use-app-will-render.js +35 -26
- package/dist/es/view/micro-app/utils.js +11 -13
- package/dist/es/view/micro-iframe-app/app.js +14 -20
- package/dist/es/view/micro-iframe-app/iframe/const.js +4 -1
- package/dist/es/view/micro-iframe-app/iframe/index.js +27 -31
- package/dist/es/view/micro-iframe-app/index.js +10 -10
- package/dist/es/view/micro-iframe-app/types.js +0 -1
- package/dist/es/view/micro-iframe-app/use-frame-loaded.js +15 -19
- package/dist/es/view/modals/error/index.js +13 -10
- package/dist/es/view/modals/navigation-prompt/index.js +11 -14
- package/dist/es/view/modals/session-expiry/customHooks.js +11 -13
- package/dist/es/view/modals/session-expiry/index.js +13 -20
- package/dist/es/view/modals/wait-message/html-wait-message.js +11 -10
- package/dist/es/view/modals/wait-message/index.js +30 -37
- package/dist/es/view/modals/wait-message/wait-message-launcher.js +8 -6
- package/dist/es/view/render-with-delay/index.js +8 -10
- package/dist/es/view/render-with-host-data/index.js +10 -13
- package/dist/es/view/session-timeout/index.js +20 -10
- package/dist/es/view/storybook/decorator.js +8 -5
- package/dist/es/view/use-previous.js +6 -3
- package/dist/es/view/useMediaBreakpoints/index.js +11 -9
- package/dist/es/view/visually-hidden/index.js +20 -10
- package/dist/es/view/window-size/index.js +12 -10
- package/dist/types/communication/http-client/retry.d.ts +1 -1
- package/dist/types/data/index.d.ts +4 -0
- package/dist/types/data/react-redux.d.ts +11 -11
- package/dist/types/data/reducers.d.ts +6 -6
- package/dist/types/data/store.d.ts +29 -29
- package/dist/types/index.d.ts +79 -79
- package/dist/types/micro-frontend.d.ts +6 -0
- package/dist/types/route/private-route/index.d.ts +1 -1
- package/dist/types/sideeffect/auth/index.d.ts +1 -1
- package/dist/types/utils/app-host-integration/react.d.ts +1 -1
- package/dist/types/utils/micro-frontend/guest.d.ts +2 -2
- package/dist/types/utils/micro-frontend/host.d.ts +1 -1
- package/dist/types/utils/micro-frontend/index.d.ts +2 -2
- package/dist/types/utils/micro-frontend/types.d.ts +1 -1
- package/dist/types/utils/storybook/cjs/main.d.ts +63 -0
- package/dist/types/utils/storybook/{middleware.d.ts → cjs/middleware.d.ts} +0 -0
- package/dist/types/utils/storybook/cjs/vite.d.ts +4 -0
- package/dist/types/utils/storybook/cjs/webpack.d.ts +16 -0
- package/dist/types/utils/storybook/preview.d.ts +9 -3
- package/dist/types/utils/testing/render-with-redux.d.ts +20 -20
- package/dist/types/utils/testing/render-with-router-redux.d.ts +20 -20
- package/dist/types/utils/window.d.ts +1 -1
- package/dist/types/view/app-root/index.d.ts +1 -1
- package/dist/types/view/fields/check-box/index.stories.d.ts +1 -1
- package/dist/types/view/fields/check-box/set-value.stories.d.ts +1 -1
- package/dist/types/view/fields/combo-box/index.stories.d.ts +1 -1
- package/dist/types/view/fields/date-input/index.stories.d.ts +1 -1
- package/dist/types/view/fields/date-picker/index.stories.d.ts +1 -1
- package/dist/types/view/fields/form-item-layout/index.stories.d.ts +1 -1
- package/dist/types/view/fields/input-mask/index.stories.d.ts +1 -1
- package/dist/types/view/fields/large-text-box/index.stories.d.ts +1 -1
- package/dist/types/view/fields/radio/index.stories.d.ts +1 -1
- package/dist/types/view/fields/radio/set-value.stories.d.ts +1 -1
- package/dist/types/view/fields/radio-group/index.stories.d.ts +1 -1
- package/dist/types/view/fields/text-box/index.stories.d.ts +1 -1
- package/dist/types/view/form/usecases.stories.d.ts +1 -1
- package/dist/types/view/header/index.d.ts +1 -1
- package/dist/types/view/header/index.stories.d.ts +1 -1
- package/dist/types/view/micro-app/app-factory/index.d.ts +2 -2
- package/dist/types/view/micro-app/index.d.ts +1 -1
- package/dist/types/view/micro-app/resources/script.d.ts +1 -1
- package/dist/types/view/micro-app/resources/style.d.ts +1 -1
- package/dist/types/view/micro-app/use-app-will-render.d.ts +1 -1
- package/dist/types/view/micro-iframe-app/app.d.ts +2 -2
- package/dist/types/view/micro-iframe-app/index.d.ts +1 -1
- package/dist/types/view/micro-iframe-app/types.d.ts +1 -1
- package/dist/types/view/micro-iframe-app/use-frame-loaded.d.ts +1 -1
- package/dist/types/view/modals/error/index.stories.d.ts +1 -1
- package/dist/types/view/modals/navigation-prompt/index.stories.d.ts +1 -1
- package/dist/types/view/modals/session-expiry/index.stories.d.ts +1 -1
- package/dist/types/view/modals/wait-message/index.stories.d.ts +1 -1
- package/dist/types/view/storybook/decorator.d.ts +1 -1
- package/dist/types/view/visually-hidden/index.d.ts +1 -3
- package/package.json +36 -25
- package/dist/cjs/api/users/index.endpoint.js +0 -14
- package/dist/cjs/communication/http-client/tests/hello.endpoint.js +0 -14
- package/dist/cjs/communication/http-client/tests/private.endpoint.js +0 -14
- package/dist/cjs/utils/storybook/main.js +0 -38
- package/dist/cjs/utils/storybook/middleware.js +0 -9
- package/dist/cjs/view/error-toast/index.stories.js +0 -128
- package/dist/cjs/view/fields/check-box/index.stories.js +0 -64
- package/dist/cjs/view/fields/check-box/set-value.stories.js +0 -83
- package/dist/cjs/view/fields/combo-box/index.stories.js +0 -65
- package/dist/cjs/view/fields/date-input/index.stories.js +0 -53
- package/dist/cjs/view/fields/date-input/index1.stories.js +0 -53
- package/dist/cjs/view/fields/date-picker/index.stories.js +0 -53
- package/dist/cjs/view/fields/form-item-layout/index.stories.js +0 -43
- package/dist/cjs/view/fields/input-mask/index.stories.js +0 -52
- package/dist/cjs/view/fields/large-text-box/index.stories.js +0 -47
- package/dist/cjs/view/fields/radio/index.stories.js +0 -60
- package/dist/cjs/view/fields/radio/set-value.stories.js +0 -81
- package/dist/cjs/view/fields/radio-group/index.stories.js +0 -85
- package/dist/cjs/view/fields/text-box/index.stories.js +0 -48
- package/dist/cjs/view/form/index.stories.js +0 -71
- package/dist/cjs/view/form/usecases.stories.js +0 -59
- package/dist/cjs/view/header/index.stories.js +0 -24
- package/dist/cjs/view/live-message/index.stories.js +0 -53
- package/dist/cjs/view/media-breakpoint/index.stories.js +0 -24
- package/dist/cjs/view/modals/error/index.stories.js +0 -36
- package/dist/cjs/view/modals/navigation-prompt/index.stories.js +0 -32
- package/dist/cjs/view/modals/session-expiry/index.stories.js +0 -30
- package/dist/cjs/view/modals/wait-message/index.stories.js +0 -47
- package/dist/cjs/view/session-timeout/index.stories.js +0 -28
- package/dist/es/api/users/index.endpoint.js +0 -14
- package/dist/es/communication/http-client/tests/hello.endpoint.js +0 -14
- package/dist/es/communication/http-client/tests/private.endpoint.js +0 -14
- package/dist/es/utils/storybook/main.js +0 -38
- package/dist/es/utils/storybook/middleware.js +0 -9
- package/dist/es/view/error-toast/index.stories.js +0 -108
- package/dist/es/view/fields/check-box/index.stories.js +0 -47
- package/dist/es/view/fields/check-box/set-value.stories.js +0 -65
- package/dist/es/view/fields/combo-box/index.stories.js +0 -48
- package/dist/es/view/fields/date-input/index.stories.js +0 -35
- package/dist/es/view/fields/date-input/index1.stories.js +0 -35
- package/dist/es/view/fields/date-picker/index.stories.js +0 -35
- package/dist/es/view/fields/form-item-layout/index.stories.js +0 -27
- package/dist/es/view/fields/input-mask/index.stories.js +0 -35
- package/dist/es/view/fields/large-text-box/index.stories.js +0 -30
- package/dist/es/view/fields/radio/index.stories.js +0 -43
- package/dist/es/view/fields/radio/set-value.stories.js +0 -63
- package/dist/es/view/fields/radio-group/index.stories.js +0 -68
- package/dist/es/view/fields/text-box/index.stories.js +0 -31
- package/dist/es/view/form/index.stories.js +0 -56
- package/dist/es/view/form/usecases.stories.js +0 -43
- package/dist/es/view/header/index.stories.js +0 -14
- package/dist/es/view/live-message/index.stories.js +0 -32
- package/dist/es/view/media-breakpoint/index.stories.js +0 -10
- package/dist/es/view/modals/error/index.stories.js +0 -21
- package/dist/es/view/modals/navigation-prompt/index.stories.js +0 -18
- package/dist/es/view/modals/session-expiry/index.stories.js +0 -18
- package/dist/es/view/modals/wait-message/index.stories.js +0 -33
- package/dist/es/view/session-timeout/index.stories.js +0 -13
- package/dist/types/utils/storybook/main.d.ts +0 -30
- package/dist/types/view/fields/date-input/index1.stories.d.ts +0 -24
|
@@ -1,73 +1,77 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
Object.
|
|
4
|
-
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
+
var __markAsModule = (target) => __defProp(target, "__esModule", { value: true });
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __reExport = (target, module2, copyDefault, desc) => {
|
|
11
|
+
if (module2 && typeof module2 === "object" || typeof module2 === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(module2))
|
|
13
|
+
if (!__hasOwnProp.call(target, key) && (copyDefault || key !== "default"))
|
|
14
|
+
__defProp(target, key, { get: () => module2[key], enumerable: !(desc = __getOwnPropDesc(module2, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return target;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = /* @__PURE__ */ ((cache) => {
|
|
19
|
+
return (module2, temp) => {
|
|
20
|
+
return cache && cache.get(module2) || (temp = __reExport(__markAsModule({}), module2, 1), cache && cache.set(module2, temp), temp);
|
|
21
|
+
};
|
|
22
|
+
})(typeof WeakMap !== "undefined" ? /* @__PURE__ */ new WeakMap() : 0);
|
|
23
|
+
var script_exports = {};
|
|
24
|
+
__export(script_exports, {
|
|
25
|
+
APP_SCRIPT_ID_PREFIX: () => APP_SCRIPT_ID_PREFIX,
|
|
26
|
+
addScriptToDOM: () => addScriptToDOM,
|
|
27
|
+
removeDynamicImportedScripts: () => removeDynamicImportedScripts,
|
|
28
|
+
removePrefetchLinks: () => removePrefetchLinks,
|
|
29
|
+
removeScriptFromDOM: () => removeScriptFromDOM
|
|
5
30
|
});
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
const
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
const isHeadScript = scriptSrc => HEAD_SCRIPTS.test(scriptSrc);
|
|
15
|
-
|
|
16
|
-
const addScriptToDOM = ({
|
|
17
|
-
name,
|
|
18
|
-
hostUrl,
|
|
19
|
-
documentEle
|
|
20
|
-
}, fileName, index) => new Promise((resolve, reject) => {
|
|
21
|
-
const ele = documentEle.createElement('script');
|
|
22
|
-
if (!ele) reject(new Error('Unable to insert Application scripts.'));
|
|
31
|
+
var import_url = require("../../../utils/url.js");
|
|
32
|
+
const APP_SCRIPT_ID_PREFIX = "emui-script-";
|
|
33
|
+
const HEAD_SCRIPTS = new RegExp("/(?:emuiDiagnostics|global|global-prod|emuiUserMonitoring)(?:..*)?.js", "i");
|
|
34
|
+
const isHeadScript = (scriptSrc) => HEAD_SCRIPTS.test(scriptSrc);
|
|
35
|
+
const addScriptToDOM = ({ name, hostUrl, documentEle }, fileName, index) => new Promise((resolve, reject) => {
|
|
36
|
+
const ele = documentEle.createElement("script");
|
|
37
|
+
if (!ele)
|
|
38
|
+
reject(new Error("Unable to insert Application scripts."));
|
|
23
39
|
ele.id = `${APP_SCRIPT_ID_PREFIX}${name}-${index}`;
|
|
24
40
|
const url = new URL(fileName, hostUrl);
|
|
25
|
-
ele.src = (0,
|
|
41
|
+
ele.src = (0, import_url.removeDoubleSlash)(url.href);
|
|
26
42
|
ele.onload = resolve.bind(null, ele.id);
|
|
27
43
|
ele.onerror = reject.bind(null, ele.id);
|
|
28
|
-
ele.async = false;
|
|
29
|
-
|
|
30
|
-
|
|
44
|
+
ele.async = false;
|
|
45
|
+
if (isHeadScript(ele.src))
|
|
46
|
+
documentEle.head.appendChild(ele);
|
|
47
|
+
else
|
|
48
|
+
documentEle.body.appendChild(ele);
|
|
31
49
|
});
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
const ele = documentEle.getElementById(elementId); // eslint-disable-next-line no-console
|
|
37
|
-
|
|
38
|
-
if (!ele) console.warn(new Error(`script with id ${elementId} not found`));
|
|
50
|
+
const removeScriptFromDOM = (elementId = "", documentEle = document) => new Promise((resolve) => {
|
|
51
|
+
const ele = documentEle.getElementById(elementId);
|
|
52
|
+
if (!ele)
|
|
53
|
+
console.warn(new Error(`script with id ${elementId} not found`));
|
|
39
54
|
ele.remove();
|
|
40
55
|
resolve();
|
|
41
56
|
});
|
|
42
|
-
|
|
43
|
-
exports.removeScriptFromDOM = removeScriptFromDOM;
|
|
44
|
-
|
|
45
57
|
const removeDynamicImportedScripts = (hostUrl, documentEle) => {
|
|
46
|
-
const hostPattern = new RegExp(hostUrl,
|
|
47
|
-
const scriptElements = documentEle.getElementsByTagName(
|
|
48
|
-
|
|
58
|
+
const hostPattern = new RegExp(hostUrl, "i");
|
|
59
|
+
const scriptElements = documentEle.getElementsByTagName("script");
|
|
49
60
|
for (let index = scriptElements.length - 1; index >= 0; index -= 1) {
|
|
50
61
|
const scriptEle = scriptElements[index];
|
|
51
|
-
const {
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
if (hostPattern.test(src)) scriptEle.remove();
|
|
62
|
+
const { src } = scriptEle;
|
|
63
|
+
if (hostPattern.test(src))
|
|
64
|
+
scriptEle.remove();
|
|
55
65
|
}
|
|
56
66
|
};
|
|
57
|
-
|
|
58
|
-
exports.removeDynamicImportedScripts = removeDynamicImportedScripts;
|
|
59
|
-
|
|
60
67
|
const removePrefetchLinks = (hostUrl, documentEle) => {
|
|
61
|
-
const hostPattern = new RegExp(hostUrl,
|
|
68
|
+
const hostPattern = new RegExp(hostUrl, "i");
|
|
62
69
|
const prefetchElements = documentEle.querySelectorAll('[rel="prefetch"]');
|
|
63
|
-
|
|
64
70
|
for (let index = prefetchElements.length - 1; index >= 0; index -= 1) {
|
|
65
71
|
const ele = prefetchElements[index];
|
|
66
|
-
const {
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
if (hostPattern.test(href)) ele.remove();
|
|
72
|
+
const { href } = ele;
|
|
73
|
+
if (hostPattern.test(href))
|
|
74
|
+
ele.remove();
|
|
70
75
|
}
|
|
71
76
|
};
|
|
72
|
-
|
|
73
|
-
exports.removePrefetchLinks = removePrefetchLinks;
|
|
77
|
+
module.exports = __toCommonJS(script_exports);
|
|
@@ -1,53 +1,60 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
Object.
|
|
4
|
-
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
+
var __markAsModule = (target) => __defProp(target, "__esModule", { value: true });
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __reExport = (target, module2, copyDefault, desc) => {
|
|
11
|
+
if (module2 && typeof module2 === "object" || typeof module2 === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(module2))
|
|
13
|
+
if (!__hasOwnProp.call(target, key) && (copyDefault || key !== "default"))
|
|
14
|
+
__defProp(target, key, { get: () => module2[key], enumerable: !(desc = __getOwnPropDesc(module2, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return target;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = /* @__PURE__ */ ((cache) => {
|
|
19
|
+
return (module2, temp) => {
|
|
20
|
+
return cache && cache.get(module2) || (temp = __reExport(__markAsModule({}), module2, 1), cache && cache.set(module2, temp), temp);
|
|
21
|
+
};
|
|
22
|
+
})(typeof WeakMap !== "undefined" ? /* @__PURE__ */ new WeakMap() : 0);
|
|
23
|
+
var style_exports = {};
|
|
24
|
+
__export(style_exports, {
|
|
25
|
+
APP_STYLE_ID_PREFIX: () => APP_STYLE_ID_PREFIX,
|
|
26
|
+
addStylesToDOM: () => addStylesToDOM,
|
|
27
|
+
removeDynamicImportedStyles: () => removeDynamicImportedStyles,
|
|
28
|
+
removeStyleFromDOM: () => removeStyleFromDOM
|
|
5
29
|
});
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
const addStylesToDOM = ({
|
|
14
|
-
name,
|
|
15
|
-
hostUrl,
|
|
16
|
-
documentEle
|
|
17
|
-
}, fileName, index) => new Promise((resolve, reject) => {
|
|
18
|
-
const ele = documentEle.createElement('link');
|
|
19
|
-
if (!ele) reject(new Error('Unable to insert Application styles.'));
|
|
30
|
+
var import_url = require("../../../utils/url.js");
|
|
31
|
+
const APP_STYLE_ID_PREFIX = "emui-style-";
|
|
32
|
+
const addStylesToDOM = ({ name, hostUrl, documentEle }, fileName, index) => new Promise((resolve, reject) => {
|
|
33
|
+
const ele = documentEle.createElement("link");
|
|
34
|
+
if (!ele)
|
|
35
|
+
reject(new Error("Unable to insert Application styles."));
|
|
20
36
|
ele.id = `${APP_STYLE_ID_PREFIX}${name}-${index}`;
|
|
21
|
-
ele.rel =
|
|
37
|
+
ele.rel = "stylesheet";
|
|
22
38
|
const url = new URL(fileName, hostUrl);
|
|
23
|
-
ele.href = (0,
|
|
39
|
+
ele.href = (0, import_url.removeDoubleSlash)(url.href);
|
|
24
40
|
ele.onload = resolve.bind(null, ele.id);
|
|
25
41
|
documentEle.head.appendChild(ele);
|
|
26
42
|
});
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
const ele = documentEle.getElementById(elementId); // eslint-disable-next-line no-console
|
|
32
|
-
|
|
33
|
-
if (!ele) console.warn(new Error(`style with id ${elementId} not found`));
|
|
43
|
+
const removeStyleFromDOM = (elementId = "", documentEle = document) => new Promise((resolve) => {
|
|
44
|
+
const ele = documentEle.getElementById(elementId);
|
|
45
|
+
if (!ele)
|
|
46
|
+
console.warn(new Error(`style with id ${elementId} not found`));
|
|
34
47
|
ele.remove();
|
|
35
48
|
resolve();
|
|
36
49
|
});
|
|
37
|
-
|
|
38
|
-
exports.removeStyleFromDOM = removeStyleFromDOM;
|
|
39
|
-
|
|
40
50
|
const removeDynamicImportedStyles = (hostUrl, documentEle) => {
|
|
41
|
-
const hostPattern = new RegExp(hostUrl,
|
|
51
|
+
const hostPattern = new RegExp(hostUrl, "i");
|
|
42
52
|
const prefetchElements = documentEle.querySelectorAll('[rel="stylesheet"]');
|
|
43
|
-
|
|
44
53
|
for (let index = prefetchElements.length - 1; index >= 0; index -= 1) {
|
|
45
54
|
const ele = prefetchElements[index];
|
|
46
|
-
const {
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
if (hostPattern.test(href)) ele.remove();
|
|
55
|
+
const { href } = ele;
|
|
56
|
+
if (hostPattern.test(href))
|
|
57
|
+
ele.remove();
|
|
50
58
|
}
|
|
51
59
|
};
|
|
52
|
-
|
|
53
|
-
exports.removeDynamicImportedStyles = removeDynamicImportedStyles;
|
|
60
|
+
module.exports = __toCommonJS(style_exports);
|
|
@@ -1,5 +1,20 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
Object.
|
|
4
|
-
|
|
5
|
-
});
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
+
var __markAsModule = (target) => __defProp(target, "__esModule", { value: true });
|
|
6
|
+
var __reExport = (target, module2, copyDefault, desc) => {
|
|
7
|
+
if (module2 && typeof module2 === "object" || typeof module2 === "function") {
|
|
8
|
+
for (let key of __getOwnPropNames(module2))
|
|
9
|
+
if (!__hasOwnProp.call(target, key) && (copyDefault || key !== "default"))
|
|
10
|
+
__defProp(target, key, { get: () => module2[key], enumerable: !(desc = __getOwnPropDesc(module2, key)) || desc.enumerable });
|
|
11
|
+
}
|
|
12
|
+
return target;
|
|
13
|
+
};
|
|
14
|
+
var __toCommonJS = /* @__PURE__ */ ((cache) => {
|
|
15
|
+
return (module2, temp) => {
|
|
16
|
+
return cache && cache.get(module2) || (temp = __reExport(__markAsModule({}), module2, 1), cache && cache.set(module2, temp), temp);
|
|
17
|
+
};
|
|
18
|
+
})(typeof WeakMap !== "undefined" ? /* @__PURE__ */ new WeakMap() : 0);
|
|
19
|
+
var types_exports = {};
|
|
20
|
+
module.exports = __toCommonJS(types_exports);
|
|
@@ -1,26 +1,36 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
var
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
+
var __markAsModule = (target) => __defProp(target, "__esModule", { value: true });
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __reExport = (target, module2, copyDefault, desc) => {
|
|
11
|
+
if (module2 && typeof module2 === "object" || typeof module2 === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(module2))
|
|
13
|
+
if (!__hasOwnProp.call(target, key) && (copyDefault || key !== "default"))
|
|
14
|
+
__defProp(target, key, { get: () => module2[key], enumerable: !(desc = __getOwnPropDesc(module2, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return target;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = /* @__PURE__ */ ((cache) => {
|
|
19
|
+
return (module2, temp) => {
|
|
20
|
+
return cache && cache.get(module2) || (temp = __reExport(__markAsModule({}), module2, 1), cache && cache.set(module2, temp), temp);
|
|
21
|
+
};
|
|
22
|
+
})(typeof WeakMap !== "undefined" ? /* @__PURE__ */ new WeakMap() : 0);
|
|
23
|
+
var use_app_will_render_exports = {};
|
|
24
|
+
__export(use_app_will_render_exports, {
|
|
25
|
+
useAppWillRender: () => useAppWillRender
|
|
7
26
|
});
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
var
|
|
11
|
-
|
|
12
|
-
var
|
|
13
|
-
|
|
14
|
-
var
|
|
15
|
-
|
|
16
|
-
var _actions = require("../../data/wait-message/actions.js");
|
|
17
|
-
|
|
18
|
-
var _index = require("./app-factory/index.js");
|
|
19
|
-
|
|
20
|
-
var _index2 = require("../../utils/micro-frontend/index.js");
|
|
21
|
-
|
|
22
|
-
var _logRecords = require("../../utils/log-records.js");
|
|
23
|
-
|
|
27
|
+
var import_react = require("react");
|
|
28
|
+
var import_lodash = require("lodash");
|
|
29
|
+
var import_react_redux = require("react-redux");
|
|
30
|
+
var import_actions = require("../../data/wait-message/actions.js");
|
|
31
|
+
var import_app_factory = require("./app-factory/index.js");
|
|
32
|
+
var import_micro_frontend = require("../../utils/micro-frontend/index.js");
|
|
33
|
+
var import_log_records = require("../../utils/log-records.js");
|
|
24
34
|
const useAppWillRender = ({
|
|
25
35
|
id,
|
|
26
36
|
documentEle,
|
|
@@ -29,51 +39,50 @@ const useAppWillRender = ({
|
|
|
29
39
|
homeRoute,
|
|
30
40
|
onUnloadComplete
|
|
31
41
|
}) => {
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
const
|
|
35
|
-
const ref = (0, _react.useRef)(Promise.resolve());
|
|
36
|
-
const getConfig = (0, _react.useCallback)(() => (0, _index2.getMicroFrontEndAppConfig)({
|
|
42
|
+
const dispatch = import_react_redux.useDispatch ? (0, import_react_redux.useDispatch)() : null;
|
|
43
|
+
const ref = (0, import_react.useRef)(Promise.resolve());
|
|
44
|
+
const getConfig = (0, import_react.useCallback)(() => (0, import_micro_frontend.getMicroFrontEndAppConfig)({
|
|
37
45
|
id
|
|
38
46
|
}), [id]);
|
|
39
|
-
const unload = (0,
|
|
40
|
-
await (0,
|
|
41
|
-
(0,
|
|
42
|
-
if (!loadFailed && onUnloadComplete)
|
|
43
|
-
|
|
44
|
-
[]);
|
|
45
|
-
const load = (0,
|
|
46
|
-
if (dispatch)
|
|
47
|
-
|
|
47
|
+
const unload = (0, import_react.useCallback)(async (appConfig, loadFailed = false) => {
|
|
48
|
+
await (0, import_app_factory.unmountApp)(appConfig);
|
|
49
|
+
(0, import_app_factory.unloadApp)(appConfig);
|
|
50
|
+
if (!loadFailed && onUnloadComplete)
|
|
51
|
+
onUnloadComplete();
|
|
52
|
+
}, []);
|
|
53
|
+
const load = (0, import_react.useCallback)(async (appConfig) => {
|
|
54
|
+
if (dispatch)
|
|
55
|
+
dispatch(import_actions.waitMessage.open());
|
|
48
56
|
try {
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
await (0,
|
|
52
|
-
await (0,
|
|
57
|
+
if (ref.current)
|
|
58
|
+
await ref.current;
|
|
59
|
+
await (0, import_app_factory.loadApp)(appConfig);
|
|
60
|
+
await (0, import_app_factory.mountApp)(appConfig);
|
|
53
61
|
} catch (ex) {
|
|
54
|
-
(0,
|
|
62
|
+
(0, import_micro_frontend.getLogger)().error({
|
|
63
|
+
...import_log_records.logRecords.APP_CONFIG_LOAD_FAILED,
|
|
55
64
|
exception: ex
|
|
56
65
|
});
|
|
57
66
|
await unload(appConfig, true);
|
|
58
67
|
throw ex;
|
|
59
68
|
}
|
|
60
|
-
|
|
61
|
-
|
|
69
|
+
if (dispatch)
|
|
70
|
+
dispatch(import_actions.waitMessage.close());
|
|
62
71
|
}, [dispatch, unload]);
|
|
63
|
-
(0,
|
|
64
|
-
if (!documentEle)
|
|
65
|
-
|
|
72
|
+
(0, import_react.useLayoutEffect)(() => {
|
|
73
|
+
if (!documentEle)
|
|
74
|
+
return () => {
|
|
75
|
+
};
|
|
76
|
+
const appConfig = (0, import_lodash.merge)(getConfig(), {
|
|
66
77
|
documentEle,
|
|
67
78
|
history,
|
|
68
79
|
theme,
|
|
69
80
|
homeRoute
|
|
70
|
-
});
|
|
71
|
-
|
|
81
|
+
});
|
|
72
82
|
load(appConfig);
|
|
73
83
|
return () => {
|
|
74
84
|
ref.current = unload(appConfig);
|
|
75
85
|
};
|
|
76
86
|
}, [documentEle, getConfig, history, theme, homeRoute, load, unload]);
|
|
77
87
|
};
|
|
78
|
-
|
|
79
|
-
exports.useAppWillRender = useAppWillRender;
|
|
88
|
+
module.exports = __toCommonJS(use_app_will_render_exports);
|
|
@@ -1,27 +1,39 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
Object.
|
|
4
|
-
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
+
var __markAsModule = (target) => __defProp(target, "__esModule", { value: true });
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __reExport = (target, module2, copyDefault, desc) => {
|
|
11
|
+
if (module2 && typeof module2 === "object" || typeof module2 === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(module2))
|
|
13
|
+
if (!__hasOwnProp.call(target, key) && (copyDefault || key !== "default"))
|
|
14
|
+
__defProp(target, key, { get: () => module2[key], enumerable: !(desc = __getOwnPropDesc(module2, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return target;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = /* @__PURE__ */ ((cache) => {
|
|
19
|
+
return (module2, temp) => {
|
|
20
|
+
return cache && cache.get(module2) || (temp = __reExport(__markAsModule({}), module2, 1), cache && cache.set(module2, temp), temp);
|
|
21
|
+
};
|
|
22
|
+
})(typeof WeakMap !== "undefined" ? /* @__PURE__ */ new WeakMap() : 0);
|
|
23
|
+
var utils_exports = {};
|
|
24
|
+
__export(utils_exports, {
|
|
25
|
+
getNavigationLinks: () => getNavigationLinks
|
|
5
26
|
});
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
var _config = require("../../utils/app-config/config.js");
|
|
9
|
-
|
|
27
|
+
var import_config = require("../../utils/app-config/config.js");
|
|
10
28
|
const getNavigationLinks = () => {
|
|
11
|
-
const microApps = (0,
|
|
12
|
-
if (!microApps)
|
|
29
|
+
const microApps = (0, import_config.getAppConfigValue)("microFrontendApps");
|
|
30
|
+
if (!microApps)
|
|
31
|
+
return [];
|
|
13
32
|
return Object.keys(microApps).reduce((value, id) => {
|
|
14
|
-
const {
|
|
15
|
-
|
|
16
|
-
homeRoute
|
|
17
|
-
} = microApps[id] || {};
|
|
18
|
-
if (name && homeRoute) value.push({
|
|
19
|
-
id,
|
|
20
|
-
name,
|
|
21
|
-
path: homeRoute
|
|
22
|
-
});
|
|
33
|
+
const { name, homeRoute } = microApps[id] || {};
|
|
34
|
+
if (name && homeRoute)
|
|
35
|
+
value.push({ id, name, path: homeRoute });
|
|
23
36
|
return value;
|
|
24
37
|
}, []);
|
|
25
38
|
};
|
|
26
|
-
|
|
27
|
-
exports.getNavigationLinks = getNavigationLinks;
|
|
39
|
+
module.exports = __toCommonJS(utils_exports);
|
|
@@ -1,49 +1,54 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
var
|
|
4
|
-
|
|
5
|
-
Object.
|
|
6
|
-
|
|
1
|
+
var __create = Object.create;
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
6
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
|
+
var __markAsModule = (target) => __defProp(target, "__esModule", { value: true });
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all)
|
|
10
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
+
};
|
|
12
|
+
var __reExport = (target, module2, copyDefault, desc) => {
|
|
13
|
+
if (module2 && typeof module2 === "object" || typeof module2 === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(module2))
|
|
15
|
+
if (!__hasOwnProp.call(target, key) && (copyDefault || key !== "default"))
|
|
16
|
+
__defProp(target, key, { get: () => module2[key], enumerable: !(desc = __getOwnPropDesc(module2, key)) || desc.enumerable });
|
|
17
|
+
}
|
|
18
|
+
return target;
|
|
19
|
+
};
|
|
20
|
+
var __toESM = (module2, isNodeMode) => {
|
|
21
|
+
return __reExport(__markAsModule(__defProp(module2 != null ? __create(__getProtoOf(module2)) : {}, "default", !isNodeMode && module2 && module2.__esModule ? { get: () => module2.default, enumerable: true } : { value: module2, enumerable: true })), module2);
|
|
22
|
+
};
|
|
23
|
+
var __toCommonJS = /* @__PURE__ */ ((cache) => {
|
|
24
|
+
return (module2, temp) => {
|
|
25
|
+
return cache && cache.get(module2) || (temp = __reExport(__markAsModule({}), module2, 1), cache && cache.set(module2, temp), temp);
|
|
26
|
+
};
|
|
27
|
+
})(typeof WeakMap !== "undefined" ? /* @__PURE__ */ new WeakMap() : 0);
|
|
28
|
+
var app_exports = {};
|
|
29
|
+
__export(app_exports, {
|
|
30
|
+
App: () => App
|
|
7
31
|
});
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
var
|
|
11
|
-
|
|
12
|
-
var
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
var _useAppWillRender = require("../micro-app/use-app-will-render.js");
|
|
19
|
-
|
|
20
|
-
var _jsxRuntime = require("react/jsx-runtime");
|
|
21
|
-
|
|
22
|
-
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
23
|
-
// @ts-ignore
|
|
24
|
-
const App = /*#__PURE__*/(0, _react.memo)(({
|
|
25
|
-
id,
|
|
26
|
-
dispose,
|
|
27
|
-
onUnloadComplete,
|
|
28
|
-
...rest
|
|
29
|
-
}) => {
|
|
30
|
-
const [documentEle, setDocumentEle] = (0, _react.useState)(null);
|
|
31
|
-
(0, _useFrameLoaded.useFrameLoaded)({
|
|
32
|
-
id,
|
|
33
|
-
documentEle,
|
|
34
|
-
...rest
|
|
35
|
-
});
|
|
36
|
-
(0, _useAppWillRender.useAppWillRender)({
|
|
32
|
+
var React = __toESM(require("react"));
|
|
33
|
+
var import_react = require("react");
|
|
34
|
+
var import_iframe = __toESM(require("file-loader?name=iframe.[contenthash].[ext]!./iframe/index.html"));
|
|
35
|
+
var import_iframe2 = require("./iframe/index.js");
|
|
36
|
+
var import_use_frame_loaded = require("./use-frame-loaded.js");
|
|
37
|
+
var import_use_app_will_render = require("../micro-app/use-app-will-render.js");
|
|
38
|
+
const App = (0, import_react.memo)(({ id, dispose, onUnloadComplete, ...rest }) => {
|
|
39
|
+
const [documentEle, setDocumentEle] = (0, import_react.useState)(null);
|
|
40
|
+
(0, import_use_frame_loaded.useFrameLoaded)({ id, documentEle, ...rest });
|
|
41
|
+
(0, import_use_app_will_render.useAppWillRender)({
|
|
37
42
|
id,
|
|
38
43
|
documentEle: dispose ? null : documentEle,
|
|
39
44
|
onUnloadComplete,
|
|
40
45
|
...rest
|
|
41
46
|
});
|
|
42
|
-
return
|
|
43
|
-
id
|
|
44
|
-
src:
|
|
47
|
+
return /* @__PURE__ */ React.createElement(import_iframe2.IFrame, {
|
|
48
|
+
id,
|
|
49
|
+
src: import_iframe.default,
|
|
45
50
|
...rest,
|
|
46
51
|
onFrameReady: setDocumentEle
|
|
47
52
|
});
|
|
48
53
|
});
|
|
49
|
-
exports
|
|
54
|
+
module.exports = __toCommonJS(app_exports);
|
|
@@ -1,8 +1,28 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
Object.
|
|
4
|
-
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
+
var __markAsModule = (target) => __defProp(target, "__esModule", { value: true });
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __reExport = (target, module2, copyDefault, desc) => {
|
|
11
|
+
if (module2 && typeof module2 === "object" || typeof module2 === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(module2))
|
|
13
|
+
if (!__hasOwnProp.call(target, key) && (copyDefault || key !== "default"))
|
|
14
|
+
__defProp(target, key, { get: () => module2[key], enumerable: !(desc = __getOwnPropDesc(module2, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return target;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = /* @__PURE__ */ ((cache) => {
|
|
19
|
+
return (module2, temp) => {
|
|
20
|
+
return cache && cache.get(module2) || (temp = __reExport(__markAsModule({}), module2, 1), cache && cache.set(module2, temp), temp);
|
|
21
|
+
};
|
|
22
|
+
})(typeof WeakMap !== "undefined" ? /* @__PURE__ */ new WeakMap() : 0);
|
|
23
|
+
var const_exports = {};
|
|
24
|
+
__export(const_exports, {
|
|
25
|
+
IFRAME_CONTAINER_ID_PREFIX: () => IFRAME_CONTAINER_ID_PREFIX
|
|
5
26
|
});
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
exports.IFRAME_CONTAINER_ID_PREFIX = IFRAME_CONTAINER_ID_PREFIX;
|
|
27
|
+
const IFRAME_CONTAINER_ID_PREFIX = "pui-iframe-container-";
|
|
28
|
+
module.exports = __toCommonJS(const_exports);
|