@darajs/core 0.4.8
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 +101 -0
- package/dist/actions/download-variable.d.ts +8 -0
- package/dist/actions/download-variable.d.ts.map +1 -0
- package/dist/actions/download-variable.js +140 -0
- package/dist/actions/download-variable.js.map +1 -0
- package/dist/actions/index.d.ts +7 -0
- package/dist/actions/index.d.ts.map +1 -0
- package/dist/actions/index.js +7 -0
- package/dist/actions/index.js.map +1 -0
- package/dist/actions/navigate-to.d.ts +8 -0
- package/dist/actions/navigate-to.d.ts.map +1 -0
- package/dist/actions/navigate-to.js +37 -0
- package/dist/actions/navigate-to.js.map +1 -0
- package/dist/actions/notify.d.ts +4 -0
- package/dist/actions/notify.d.ts.map +1 -0
- package/dist/actions/notify.js +11 -0
- package/dist/actions/notify.js.map +1 -0
- package/dist/actions/reset-variables.d.ts +8 -0
- package/dist/actions/reset-variables.d.ts.map +1 -0
- package/dist/actions/reset-variables.js +37 -0
- package/dist/actions/reset-variables.js.map +1 -0
- package/dist/actions/trigger-variable.d.ts +8 -0
- package/dist/actions/trigger-variable.d.ts.map +1 -0
- package/dist/actions/trigger-variable.js +14 -0
- package/dist/actions/trigger-variable.js.map +1 -0
- package/dist/actions/update-variable.d.ts +15 -0
- package/dist/actions/update-variable.d.ts.map +1 -0
- package/dist/actions/update-variable.js +56 -0
- package/dist/actions/update-variable.js.map +1 -0
- package/dist/api/core.d.ts +35 -0
- package/dist/api/core.d.ts.map +1 -0
- package/dist/api/core.js +112 -0
- package/dist/api/core.js.map +1 -0
- package/dist/api/http.d.ts +29 -0
- package/dist/api/http.d.ts.map +1 -0
- package/dist/api/http.js +126 -0
- package/dist/api/http.js.map +1 -0
- package/dist/api/index.d.ts +5 -0
- package/dist/api/index.d.ts.map +1 -0
- package/dist/api/index.js +5 -0
- package/dist/api/index.js.map +1 -0
- package/dist/api/websocket.d.ts +222 -0
- package/dist/api/websocket.d.ts.map +1 -0
- package/dist/api/websocket.js +353 -0
- package/dist/api/websocket.js.map +1 -0
- package/dist/assets/causalens-dark.svg +29 -0
- package/dist/assets/causalens-light.svg +29 -0
- package/dist/assets/dara-dark.svg +20 -0
- package/dist/assets/dara-light.svg +15 -0
- package/dist/assets/fonts/Manrope-VariableFont_wght.ttf +0 -0
- package/dist/auth/auth-wrapper.d.ts +15 -0
- package/dist/auth/auth-wrapper.d.ts.map +1 -0
- package/dist/auth/auth-wrapper.js +72 -0
- package/dist/auth/auth-wrapper.js.map +1 -0
- package/dist/auth/auth.d.ts +61 -0
- package/dist/auth/auth.d.ts.map +1 -0
- package/dist/auth/auth.js +163 -0
- package/dist/auth/auth.js.map +1 -0
- package/dist/auth/basic/basic-auth-login.d.ts +6 -0
- package/dist/auth/basic/basic-auth-login.d.ts.map +1 -0
- package/dist/auth/basic/basic-auth-login.js +171 -0
- package/dist/auth/basic/basic-auth-login.js.map +1 -0
- package/dist/auth/basic/basic-auth-logout.d.ts +6 -0
- package/dist/auth/basic/basic-auth-logout.d.ts.map +1 -0
- package/dist/auth/basic/basic-auth-logout.js +18 -0
- package/dist/auth/basic/basic-auth-logout.js.map +1 -0
- package/dist/auth/default/default-auth-login.d.ts +6 -0
- package/dist/auth/default/default-auth-login.d.ts.map +1 -0
- package/dist/auth/default/default-auth-login.js +59 -0
- package/dist/auth/default/default-auth-login.js.map +1 -0
- package/dist/auth/index.d.ts +7 -0
- package/dist/auth/index.d.ts.map +1 -0
- package/dist/auth/index.js +7 -0
- package/dist/auth/index.js.map +1 -0
- package/dist/auth/use-session-token.d.ts +19 -0
- package/dist/auth/use-session-token.d.ts.map +1 -0
- package/dist/auth/use-session-token.js +30 -0
- package/dist/auth/use-session-token.js.map +1 -0
- package/dist/components/fallback/default.d.ts +5 -0
- package/dist/components/fallback/default.d.ts.map +1 -0
- package/dist/components/fallback/default.js +10 -0
- package/dist/components/fallback/default.js.map +1 -0
- package/dist/components/fallback/dots.d.ts +7 -0
- package/dist/components/fallback/dots.d.ts.map +1 -0
- package/dist/components/fallback/dots.js +78 -0
- package/dist/components/fallback/dots.js.map +1 -0
- package/dist/components/fallback/row.d.ts +5 -0
- package/dist/components/fallback/row.d.ts.map +1 -0
- package/dist/components/fallback/row.js +14 -0
- package/dist/components/fallback/row.js.map +1 -0
- package/dist/components/for/for.d.ts +35 -0
- package/dist/components/for/for.d.ts.map +1 -0
- package/dist/components/for/for.js +44 -0
- package/dist/components/for/for.js.map +1 -0
- package/dist/components/index.d.ts +9 -0
- package/dist/components/index.d.ts.map +1 -0
- package/dist/components/index.js +9 -0
- package/dist/components/index.js.map +1 -0
- package/dist/components/menu/menu.d.ts +14 -0
- package/dist/components/menu/menu.d.ts.map +1 -0
- package/dist/components/menu/menu.js +58 -0
- package/dist/components/menu/menu.js.map +1 -0
- package/dist/components/progress-tracker/progress-tracker.d.ts +18 -0
- package/dist/components/progress-tracker/progress-tracker.d.ts.map +1 -0
- package/dist/components/progress-tracker/progress-tracker.js +204 -0
- package/dist/components/progress-tracker/progress-tracker.js.map +1 -0
- package/dist/components/router-content/router-content.d.ts +14 -0
- package/dist/components/router-content/router-content.d.ts.map +1 -0
- package/dist/components/router-content/router-content.js +17 -0
- package/dist/components/router-content/router-content.js.map +1 -0
- package/dist/components/side-bar-frame/side-bar-frame.d.ts +21 -0
- package/dist/components/side-bar-frame/side-bar-frame.d.ts.map +1 -0
- package/dist/components/side-bar-frame/side-bar-frame.js +87 -0
- package/dist/components/side-bar-frame/side-bar-frame.js.map +1 -0
- package/dist/components/top-bar-frame/top-bar-frame.d.ts +16 -0
- package/dist/components/top-bar-frame/top-bar-frame.d.ts.map +1 -0
- package/dist/components/top-bar-frame/top-bar-frame.js +89 -0
- package/dist/components/top-bar-frame/top-bar-frame.js.map +1 -0
- package/dist/dara_core-0.4.8-py3-none-any.whl +0 -0
- package/dist/devtools/backend-errors/backend-errors-ctx.d.ts +17 -0
- package/dist/devtools/backend-errors/backend-errors-ctx.d.ts.map +1 -0
- package/dist/devtools/backend-errors/backend-errors-ctx.js +37 -0
- package/dist/devtools/backend-errors/backend-errors-ctx.js.map +1 -0
- package/dist/devtools/backend-errors/backend-errors.d.ts +6 -0
- package/dist/devtools/backend-errors/backend-errors.d.ts.map +1 -0
- package/dist/devtools/backend-errors/backend-errors.js +57 -0
- package/dist/devtools/backend-errors/backend-errors.js.map +1 -0
- package/dist/devtools/backend-errors/error-display.d.ts +22 -0
- package/dist/devtools/backend-errors/error-display.d.ts.map +1 -0
- package/dist/devtools/backend-errors/error-display.js +101 -0
- package/dist/devtools/backend-errors/error-display.js.map +1 -0
- package/dist/devtools/backend-errors/index.d.ts +3 -0
- package/dist/devtools/backend-errors/index.d.ts.map +1 -0
- package/dist/devtools/backend-errors/index.js +3 -0
- package/dist/devtools/backend-errors/index.js.map +1 -0
- package/dist/devtools/devtools-content.d.ts +12 -0
- package/dist/devtools/devtools-content.d.ts.map +1 -0
- package/dist/devtools/devtools-content.js +73 -0
- package/dist/devtools/devtools-content.js.map +1 -0
- package/dist/devtools/devtools-context.d.ts +7 -0
- package/dist/devtools/devtools-context.d.ts.map +1 -0
- package/dist/devtools/devtools-context.js +9 -0
- package/dist/devtools/devtools-context.js.map +1 -0
- package/dist/devtools/devtools-wrapper.d.ts +8 -0
- package/dist/devtools/devtools-wrapper.d.ts.map +1 -0
- package/dist/devtools/devtools-wrapper.js +64 -0
- package/dist/devtools/devtools-wrapper.js.map +1 -0
- package/dist/devtools/devtools.d.ts +5 -0
- package/dist/devtools/devtools.d.ts.map +1 -0
- package/dist/devtools/devtools.js +10 -0
- package/dist/devtools/devtools.js.map +1 -0
- package/dist/devtools/floating-button.d.ts +23 -0
- package/dist/devtools/floating-button.d.ts.map +1 -0
- package/dist/devtools/floating-button.js +94 -0
- package/dist/devtools/floating-button.js.map +1 -0
- package/dist/devtools/index.d.ts +2 -0
- package/dist/devtools/index.d.ts.map +1 -0
- package/dist/devtools/index.js +2 -0
- package/dist/devtools/index.js.map +1 -0
- package/dist/devtools/resizer.d.ts +18 -0
- package/dist/devtools/resizer.d.ts.map +1 -0
- package/dist/devtools/resizer.js +49 -0
- package/dist/devtools/resizer.js.map +1 -0
- package/dist/devtools/use-move.d.ts +21 -0
- package/dist/devtools/use-move.d.ts.map +1 -0
- package/dist/devtools/use-move.js +56 -0
- package/dist/devtools/use-move.js.map +1 -0
- package/dist/index.css +95 -0
- package/dist/index.d.ts +17 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +14 -0
- package/dist/index.js.map +1 -0
- package/dist/jest-setup.d.ts +2 -0
- package/dist/jest-setup.d.ts.map +1 -0
- package/dist/jest-setup.js +18 -0
- package/dist/jest-setup.js.map +1 -0
- package/dist/pages/error-page.d.ts +3 -0
- package/dist/pages/error-page.d.ts.map +1 -0
- package/dist/pages/error-page.js +32 -0
- package/dist/pages/error-page.js.map +1 -0
- package/dist/pages/sso-callback-page.d.ts +6 -0
- package/dist/pages/sso-callback-page.d.ts.map +1 -0
- package/dist/pages/sso-callback-page.js +8 -0
- package/dist/pages/sso-callback-page.js.map +1 -0
- package/dist/run.d.ts +22 -0
- package/dist/run.d.ts.map +1 -0
- package/dist/run.js +40 -0
- package/dist/run.js.map +1 -0
- package/dist/shared/center/center.d.ts +5 -0
- package/dist/shared/center/center.d.ts.map +1 -0
- package/dist/shared/center/center.js +15 -0
- package/dist/shared/center/center.js.map +1 -0
- package/dist/shared/context/direction-context.d.ts +6 -0
- package/dist/shared/context/direction-context.d.ts.map +1 -0
- package/dist/shared/context/direction-context.js +4 -0
- package/dist/shared/context/direction-context.js.map +1 -0
- package/dist/shared/context/display-context.d.ts +13 -0
- package/dist/shared/context/display-context.d.ts.map +1 -0
- package/dist/shared/context/display-context.js +4 -0
- package/dist/shared/context/display-context.js.map +1 -0
- package/dist/shared/context/fallback-context.d.ts +11 -0
- package/dist/shared/context/fallback-context.d.ts.map +1 -0
- package/dist/shared/context/fallback-context.js +4 -0
- package/dist/shared/context/fallback-context.js.map +1 -0
- package/dist/shared/context/global-task-context.d.ts +40 -0
- package/dist/shared/context/global-task-context.d.ts.map +1 -0
- package/dist/shared/context/global-task-context.js +81 -0
- package/dist/shared/context/global-task-context.js.map +1 -0
- package/dist/shared/context/importers-context.d.ts +6 -0
- package/dist/shared/context/importers-context.d.ts.map +1 -0
- package/dist/shared/context/importers-context.js +4 -0
- package/dist/shared/context/importers-context.js.map +1 -0
- package/dist/shared/context/index.d.ts +10 -0
- package/dist/shared/context/index.d.ts.map +1 -0
- package/dist/shared/context/index.js +10 -0
- package/dist/shared/context/index.js.map +1 -0
- package/dist/shared/context/registries-context.d.ts +20 -0
- package/dist/shared/context/registries-context.d.ts.map +1 -0
- package/dist/shared/context/registries-context.js +8 -0
- package/dist/shared/context/registries-context.js.map +1 -0
- package/dist/shared/context/request-extras-context.d.ts +33 -0
- package/dist/shared/context/request-extras-context.d.ts.map +1 -0
- package/dist/shared/context/request-extras-context.js +55 -0
- package/dist/shared/context/request-extras-context.js.map +1 -0
- package/dist/shared/context/variable-context.d.ts +10 -0
- package/dist/shared/context/variable-context.d.ts.map +1 -0
- package/dist/shared/context/variable-context.js +4 -0
- package/dist/shared/context/variable-context.js.map +1 -0
- package/dist/shared/context/websocket-context.d.ts +7 -0
- package/dist/shared/context/websocket-context.d.ts.map +1 -0
- package/dist/shared/context/websocket-context.js +4 -0
- package/dist/shared/context/websocket-context.js.map +1 -0
- package/dist/shared/dynamic-component/clean-props.d.ts +6 -0
- package/dist/shared/dynamic-component/clean-props.d.ts.map +1 -0
- package/dist/shared/dynamic-component/clean-props.js +13 -0
- package/dist/shared/dynamic-component/clean-props.js.map +1 -0
- package/dist/shared/dynamic-component/dynamic-component.d.ts +16 -0
- package/dist/shared/dynamic-component/dynamic-component.d.ts.map +1 -0
- package/dist/shared/dynamic-component/dynamic-component.js +252 -0
- package/dist/shared/dynamic-component/dynamic-component.js.map +1 -0
- package/dist/shared/error-handling/error-display.d.ts +8 -0
- package/dist/shared/error-handling/error-display.d.ts.map +1 -0
- package/dist/shared/error-handling/error-display.js +94 -0
- package/dist/shared/error-handling/error-display.js.map +1 -0
- package/dist/shared/error-handling/index.d.ts +3 -0
- package/dist/shared/error-handling/index.d.ts.map +1 -0
- package/dist/shared/error-handling/index.js +3 -0
- package/dist/shared/error-handling/index.js.map +1 -0
- package/dist/shared/error-handling/types.d.ts +11 -0
- package/dist/shared/error-handling/types.d.ts.map +1 -0
- package/dist/shared/error-handling/types.js +9 -0
- package/dist/shared/error-handling/types.js.map +1 -0
- package/dist/shared/event-bus/event-bus.d.ts +27 -0
- package/dist/shared/event-bus/event-bus.d.ts.map +1 -0
- package/dist/shared/event-bus/event-bus.js +58 -0
- package/dist/shared/event-bus/event-bus.js.map +1 -0
- package/dist/shared/global-state-store.d.ts +54 -0
- package/dist/shared/global-state-store.d.ts.map +1 -0
- package/dist/shared/global-state-store.js +168 -0
- package/dist/shared/global-state-store.js.map +1 -0
- package/dist/shared/index.d.ts +12 -0
- package/dist/shared/index.d.ts.map +1 -0
- package/dist/shared/index.js +10 -0
- package/dist/shared/index.js.map +1 -0
- package/dist/shared/interactivity/data-variable.d.ts +78 -0
- package/dist/shared/interactivity/data-variable.d.ts.map +1 -0
- package/dist/shared/interactivity/data-variable.js +218 -0
- package/dist/shared/interactivity/data-variable.js.map +1 -0
- package/dist/shared/interactivity/derived-variable.d.ts +160 -0
- package/dist/shared/interactivity/derived-variable.d.ts.map +1 -0
- package/dist/shared/interactivity/derived-variable.js +446 -0
- package/dist/shared/interactivity/derived-variable.js.map +1 -0
- package/dist/shared/interactivity/filtering.d.ts +9 -0
- package/dist/shared/interactivity/filtering.d.ts.map +1 -0
- package/dist/shared/interactivity/filtering.js +20 -0
- package/dist/shared/interactivity/filtering.js.map +1 -0
- package/dist/shared/interactivity/index.d.ts +10 -0
- package/dist/shared/interactivity/index.d.ts.map +1 -0
- package/dist/shared/interactivity/index.js +9 -0
- package/dist/shared/interactivity/index.js.map +1 -0
- package/dist/shared/interactivity/internal.d.ts +9 -0
- package/dist/shared/interactivity/internal.d.ts.map +1 -0
- package/dist/shared/interactivity/internal.js +11 -0
- package/dist/shared/interactivity/internal.js.map +1 -0
- package/dist/shared/interactivity/nested.d.ts +16 -0
- package/dist/shared/interactivity/nested.d.ts.map +1 -0
- package/dist/shared/interactivity/nested.js +54 -0
- package/dist/shared/interactivity/nested.js.map +1 -0
- package/dist/shared/interactivity/persistence.d.ts +43 -0
- package/dist/shared/interactivity/persistence.d.ts.map +1 -0
- package/dist/shared/interactivity/persistence.js +215 -0
- package/dist/shared/interactivity/persistence.js.map +1 -0
- package/dist/shared/interactivity/plain-variable.d.ts +17 -0
- package/dist/shared/interactivity/plain-variable.d.ts.map +1 -0
- package/dist/shared/interactivity/plain-variable.js +222 -0
- package/dist/shared/interactivity/plain-variable.js.map +1 -0
- package/dist/shared/interactivity/resolve-value.d.ts +13 -0
- package/dist/shared/interactivity/resolve-value.d.ts.map +1 -0
- package/dist/shared/interactivity/resolve-value.js +36 -0
- package/dist/shared/interactivity/resolve-value.js.map +1 -0
- package/dist/shared/interactivity/resolve-variable.d.ts +18 -0
- package/dist/shared/interactivity/resolve-variable.d.ts.map +1 -0
- package/dist/shared/interactivity/resolve-variable.js +46 -0
- package/dist/shared/interactivity/resolve-variable.js.map +1 -0
- package/dist/shared/interactivity/store.d.ts +76 -0
- package/dist/shared/interactivity/store.d.ts.map +1 -0
- package/dist/shared/interactivity/store.js +99 -0
- package/dist/shared/interactivity/store.js.map +1 -0
- package/dist/shared/interactivity/triggers.d.ts +31 -0
- package/dist/shared/interactivity/triggers.d.ts.map +1 -0
- package/dist/shared/interactivity/triggers.js +105 -0
- package/dist/shared/interactivity/triggers.js.map +1 -0
- package/dist/shared/interactivity/url-variable.d.ts +12 -0
- package/dist/shared/interactivity/url-variable.d.ts.map +1 -0
- package/dist/shared/interactivity/url-variable.js +27 -0
- package/dist/shared/interactivity/url-variable.js.map +1 -0
- package/dist/shared/interactivity/use-any-variable.d.ts +8 -0
- package/dist/shared/interactivity/use-any-variable.d.ts.map +1 -0
- package/dist/shared/interactivity/use-any-variable.js +39 -0
- package/dist/shared/interactivity/use-any-variable.js.map +1 -0
- package/dist/shared/interactivity/use-data-variable.d.ts +18 -0
- package/dist/shared/interactivity/use-data-variable.d.ts.map +1 -0
- package/dist/shared/interactivity/use-data-variable.js +58 -0
- package/dist/shared/interactivity/use-data-variable.js.map +1 -0
- package/dist/shared/interactivity/use-refresh-selector.d.ts +5 -0
- package/dist/shared/interactivity/use-refresh-selector.d.ts.map +1 -0
- package/dist/shared/interactivity/use-refresh-selector.js +20 -0
- package/dist/shared/interactivity/use-refresh-selector.js.map +1 -0
- package/dist/shared/interactivity/use-server-component.d.ts +24 -0
- package/dist/shared/interactivity/use-server-component.d.ts.map +1 -0
- package/dist/shared/interactivity/use-server-component.js +256 -0
- package/dist/shared/interactivity/use-server-component.js.map +1 -0
- package/dist/shared/interactivity/use-variable-state.d.ts +9 -0
- package/dist/shared/interactivity/use-variable-state.d.ts.map +1 -0
- package/dist/shared/interactivity/use-variable-state.js +26 -0
- package/dist/shared/interactivity/use-variable-state.js.map +1 -0
- package/dist/shared/interactivity/use-variable-value.d.ts +33 -0
- package/dist/shared/interactivity/use-variable-value.d.ts.map +1 -0
- package/dist/shared/interactivity/use-variable-value.js +94 -0
- package/dist/shared/interactivity/use-variable-value.js.map +1 -0
- package/dist/shared/interactivity/use-variable.d.ts +12 -0
- package/dist/shared/interactivity/use-variable.d.ts.map +1 -0
- package/dist/shared/interactivity/use-variable.js +84 -0
- package/dist/shared/interactivity/use-variable.js.map +1 -0
- package/dist/shared/private-route/private-route.d.ts +19 -0
- package/dist/shared/private-route/private-route.d.ts.map +1 -0
- package/dist/shared/private-route/private-route.js +35 -0
- package/dist/shared/private-route/private-route.js.map +1 -0
- package/dist/shared/template-root/dynamic-context.d.ts +9 -0
- package/dist/shared/template-root/dynamic-context.d.ts.map +1 -0
- package/dist/shared/template-root/dynamic-context.js +29 -0
- package/dist/shared/template-root/dynamic-context.js.map +1 -0
- package/dist/shared/template-root/template-root.d.ts +12 -0
- package/dist/shared/template-root/template-root.d.ts.map +1 -0
- package/dist/shared/template-root/template-root.js +94 -0
- package/dist/shared/template-root/template-root.js.map +1 -0
- package/dist/shared/utils/clean-session-cache.d.ts +9 -0
- package/dist/shared/utils/clean-session-cache.d.ts.map +1 -0
- package/dist/shared/utils/clean-session-cache.js +19 -0
- package/dist/shared/utils/clean-session-cache.js.map +1 -0
- package/dist/shared/utils/embed.d.ts +22 -0
- package/dist/shared/utils/embed.d.ts.map +1 -0
- package/dist/shared/utils/embed.js +43 -0
- package/dist/shared/utils/embed.js.map +1 -0
- package/dist/shared/utils/get-icon.d.ts +9 -0
- package/dist/shared/utils/get-icon.d.ts.map +1 -0
- package/dist/shared/utils/get-icon.js +30 -0
- package/dist/shared/utils/get-icon.js.map +1 -0
- package/dist/shared/utils/hashing.d.ts +14 -0
- package/dist/shared/utils/hashing.d.ts.map +1 -0
- package/dist/shared/utils/hashing.js +26 -0
- package/dist/shared/utils/hashing.js.map +1 -0
- package/dist/shared/utils/index.d.ts +19 -0
- package/dist/shared/utils/index.d.ts.map +1 -0
- package/dist/shared/utils/index.js +17 -0
- package/dist/shared/utils/index.js.map +1 -0
- package/dist/shared/utils/inject-css.d.ts +12 -0
- package/dist/shared/utils/inject-css.d.ts.map +1 -0
- package/dist/shared/utils/inject-css.js +25 -0
- package/dist/shared/utils/inject-css.js.map +1 -0
- package/dist/shared/utils/is-js-component.d.ts +9 -0
- package/dist/shared/utils/is-js-component.d.ts.map +1 -0
- package/dist/shared/utils/is-js-component.js +11 -0
- package/dist/shared/utils/is-js-component.js.map +1 -0
- package/dist/shared/utils/normalization.d.ts +19 -0
- package/dist/shared/utils/normalization.d.ts.map +1 -0
- package/dist/shared/utils/normalization.js +121 -0
- package/dist/shared/utils/normalization.js.map +1 -0
- package/dist/shared/utils/resolve-theme.d.ts +9 -0
- package/dist/shared/utils/resolve-theme.d.ts.map +1 -0
- package/dist/shared/utils/resolve-theme.js +28 -0
- package/dist/shared/utils/resolve-theme.js.map +1 -0
- package/dist/shared/utils/templating.d.ts +24 -0
- package/dist/shared/utils/templating.d.ts.map +1 -0
- package/dist/shared/utils/templating.js +67 -0
- package/dist/shared/utils/templating.js.map +1 -0
- package/dist/shared/utils/use-action-registry.d.ts +11 -0
- package/dist/shared/utils/use-action-registry.d.ts.map +1 -0
- package/dist/shared/utils/use-action-registry.js +18 -0
- package/dist/shared/utils/use-action-registry.js.map +1 -0
- package/dist/shared/utils/use-action.d.ts +34 -0
- package/dist/shared/utils/use-action.d.ts.map +1 -0
- package/dist/shared/utils/use-action.js +314 -0
- package/dist/shared/utils/use-action.js.map +1 -0
- package/dist/shared/utils/use-component-registry.d.ts +11 -0
- package/dist/shared/utils/use-component-registry.d.ts.map +1 -0
- package/dist/shared/utils/use-component-registry.js +57 -0
- package/dist/shared/utils/use-component-registry.js.map +1 -0
- package/dist/shared/utils/use-component-styles.d.ts +24 -0
- package/dist/shared/utils/use-component-styles.d.ts.map +1 -0
- package/dist/shared/utils/use-component-styles.js +69 -0
- package/dist/shared/utils/use-component-styles.js.map +1 -0
- package/dist/shared/utils/use-defer-loadable.d.ts +8 -0
- package/dist/shared/utils/use-defer-loadable.d.ts.map +1 -0
- package/dist/shared/utils/use-defer-loadable.js +44 -0
- package/dist/shared/utils/use-defer-loadable.js.map +1 -0
- package/dist/shared/utils/use-interval.d.ts +9 -0
- package/dist/shared/utils/use-interval.d.ts.map +1 -0
- package/dist/shared/utils/use-interval.js +19 -0
- package/dist/shared/utils/use-interval.js.map +1 -0
- package/dist/shared/utils/use-previous.d.ts +10 -0
- package/dist/shared/utils/use-previous.d.ts.map +1 -0
- package/dist/shared/utils/use-previous.js +17 -0
- package/dist/shared/utils/use-previous.js.map +1 -0
- package/dist/shared/utils/use-url-sync.d.ts +20 -0
- package/dist/shared/utils/use-url-sync.d.ts.map +1 -0
- package/dist/shared/utils/use-url-sync.js +68 -0
- package/dist/shared/utils/use-url-sync.js.map +1 -0
- package/dist/shared/utils/use-window-title.d.ts +3 -0
- package/dist/shared/utils/use-window-title.d.ts.map +1 -0
- package/dist/shared/utils/use-window-title.js +14 -0
- package/dist/shared/utils/use-window-title.js.map +1 -0
- package/dist/shared/variable-state-provider/variable-state-provider.d.ts +10 -0
- package/dist/shared/variable-state-provider/variable-state-provider.d.ts.map +1 -0
- package/dist/shared/variable-state-provider/variable-state-provider.js +29 -0
- package/dist/shared/variable-state-provider/variable-state-provider.js.map +1 -0
- package/dist/shared/wrapper/wrapper.d.ts +7 -0
- package/dist/shared/wrapper/wrapper.d.ts.map +1 -0
- package/dist/shared/wrapper/wrapper.js +14 -0
- package/dist/shared/wrapper/wrapper.js.map +1 -0
- package/dist/types/auth.d.ts +15 -0
- package/dist/types/auth.d.ts.map +1 -0
- package/dist/types/auth.js +6 -0
- package/dist/types/auth.js.map +1 -0
- package/dist/types/core.d.ts +440 -0
- package/dist/types/core.d.ts.map +1 -0
- package/dist/types/core.js +22 -0
- package/dist/types/core.js.map +1 -0
- package/dist/types/index.d.ts +7 -0
- package/dist/types/index.d.ts.map +1 -0
- package/dist/types/index.js +4 -0
- package/dist/types/index.js.map +1 -0
- package/dist/types/utils.d.ts +56 -0
- package/dist/types/utils.d.ts.map +1 -0
- package/dist/types/utils.js +93 -0
- package/dist/types/utils.js.map +1 -0
- package/dist/umd/dara.core.umd.js +86508 -0
- package/dist/umd/style.css +848 -0
- package/dist/utils.d.ts +11 -0
- package/dist/utils.d.ts.map +1 -0
- package/dist/utils.js +20 -0
- package/dist/utils.js.map +1 -0
- package/package.json +121 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"importers-context.d.ts","sourceRoot":"","sources":["../../../js/shared/context/importers-context.tsx"],"names":[],"mappings":"AAEA,KAAK,YAAY,GAAG;IAChB,CAAC,CAAC,EAAE,MAAM,GAAG,MAAM,OAAO,CAAC,GAAG,CAAC,CAAC;CACnC,CAAC;AAEF,QAAA,MAAM,YAAY,uCAAkC,CAAC;AAErD,eAAe,YAAY,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"importers-context.js","sourceRoot":"","sources":["../../../js/shared/context/importers-context.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAMtC,MAAM,YAAY,GAAG,aAAa,CAAe,EAAE,CAAC,CAAC;AAErD,eAAe,YAAY,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export { default as DirectionCtx } from './direction-context';
|
|
2
|
+
export { default as ImportersCtx } from './importers-context';
|
|
3
|
+
export { default as GlobalTaskProvider, useTaskContext } from './global-task-context';
|
|
4
|
+
export { default as VariableCtx } from './variable-context';
|
|
5
|
+
export { default as WebSocketCtx } from './websocket-context';
|
|
6
|
+
export { default as RegistriesCtx } from './registries-context';
|
|
7
|
+
export { default as DisplayCtx } from './display-context';
|
|
8
|
+
export { default as FallbackCtx } from './fallback-context';
|
|
9
|
+
export { default as RequestExtrasCtx, useRequestExtras, RequestExtrasProvider, PartialRequestExtrasProvider, } from './request-extras-context';
|
|
10
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../js/shared/context/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,YAAY,EAAE,MAAM,qBAAqB,CAAC;AAC9D,OAAO,EAAE,OAAO,IAAI,YAAY,EAAE,MAAM,qBAAqB,CAAC;AAC9D,OAAO,EAAE,OAAO,IAAI,kBAAkB,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AACtF,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,oBAAoB,CAAC;AAC5D,OAAO,EAAE,OAAO,IAAI,YAAY,EAAE,MAAM,qBAAqB,CAAC;AAC9D,OAAO,EAAE,OAAO,IAAI,aAAa,EAAE,MAAM,sBAAsB,CAAC;AAChE,OAAO,EAAE,OAAO,IAAI,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAC1D,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,oBAAoB,CAAC;AAC5D,OAAO,EACH,OAAO,IAAI,gBAAgB,EAC3B,gBAAgB,EAChB,qBAAqB,EACrB,4BAA4B,GAC/B,MAAM,0BAA0B,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export { default as DirectionCtx } from './direction-context';
|
|
2
|
+
export { default as ImportersCtx } from './importers-context';
|
|
3
|
+
export { default as GlobalTaskProvider, useTaskContext } from './global-task-context';
|
|
4
|
+
export { default as VariableCtx } from './variable-context';
|
|
5
|
+
export { default as WebSocketCtx } from './websocket-context';
|
|
6
|
+
export { default as RegistriesCtx } from './registries-context';
|
|
7
|
+
export { default as DisplayCtx } from './display-context';
|
|
8
|
+
export { default as FallbackCtx } from './fallback-context';
|
|
9
|
+
export { default as RequestExtrasCtx, useRequestExtras, RequestExtrasProvider, PartialRequestExtrasProvider, } from './request-extras-context';
|
|
10
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../js/shared/context/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,YAAY,EAAE,MAAM,qBAAqB,CAAC;AAC9D,OAAO,EAAE,OAAO,IAAI,YAAY,EAAE,MAAM,qBAAqB,CAAC;AAC9D,OAAO,EAAE,OAAO,IAAI,kBAAkB,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AACtF,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,oBAAoB,CAAC;AAC5D,OAAO,EAAE,OAAO,IAAI,YAAY,EAAE,MAAM,qBAAqB,CAAC;AAC9D,OAAO,EAAE,OAAO,IAAI,aAAa,EAAE,MAAM,sBAAsB,CAAC;AAChE,OAAO,EAAE,OAAO,IAAI,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAC1D,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,oBAAoB,CAAC;AAC5D,OAAO,EACH,OAAO,IAAI,gBAAgB,EAC3B,gBAAgB,EAChB,qBAAqB,EACrB,4BAA4B,GAC/B,MAAM,0BAA0B,CAAC"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { QueryObserverResult, RefetchOptions } from '@tanstack/react-query';
|
|
2
|
+
import { RequestError } from '@darajs/ui-utils';
|
|
3
|
+
import { ActionDef, Component } from '../../types';
|
|
4
|
+
type RegistriesCtx = {
|
|
5
|
+
/**
|
|
6
|
+
* Action registry
|
|
7
|
+
*/
|
|
8
|
+
actionRegistry: Record<string, ActionDef>;
|
|
9
|
+
/**
|
|
10
|
+
* Component registry
|
|
11
|
+
*/
|
|
12
|
+
componentRegistry: Record<string, Component>;
|
|
13
|
+
/**
|
|
14
|
+
* Callback to force a refetch of the components registry
|
|
15
|
+
*/
|
|
16
|
+
refetchComponents: (options?: RefetchOptions) => Promise<QueryObserverResult<Record<string, Component>, RequestError>>;
|
|
17
|
+
};
|
|
18
|
+
declare const registriesCtx: import("react").Context<RegistriesCtx>;
|
|
19
|
+
export default registriesCtx;
|
|
20
|
+
//# sourceMappingURL=registries-context.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"registries-context.d.ts","sourceRoot":"","sources":["../../../js/shared/context/registries-context.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,mBAAmB,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAG5E,OAAO,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAEhD,OAAO,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAE/C,KAAK,aAAa,GAAG;IACjB;;OAEG;IACH,cAAc,EAAE,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC,CAAC;IAC1C;;OAEG;IACH,iBAAiB,EAAE,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC,CAAC;IAC7C;;OAEG;IACH,iBAAiB,EAAE,CACf,OAAO,CAAC,EAAE,cAAc,KACvB,OAAO,CAAC,mBAAmB,CAAC,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC,EAAE,YAAY,CAAC,CAAC,CAAC;CAC9E,CAAC;AAEF,QAAA,MAAM,aAAa,wCAIjB,CAAC;AAEH,eAAe,aAAa,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"registries-context.js","sourceRoot":"","sources":["../../../js/shared/context/registries-context.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAuBtC,MAAM,aAAa,GAAG,aAAa,CAAgB;IAC/C,cAAc,EAAE,EAAE;IAClB,iBAAiB,EAAE,EAAE;IACrB,iBAAiB,EAAE,IAAI;CAC1B,CAAC,CAAC;AAEH,eAAe,aAAa,CAAC"}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { RequestExtras } from '../../api/http';
|
|
2
|
+
interface RequestExtrasCtx {
|
|
3
|
+
options: RequestInit;
|
|
4
|
+
}
|
|
5
|
+
declare const requestExtrasCtx: import("react").Context<RequestExtrasCtx>;
|
|
6
|
+
export default requestExtrasCtx;
|
|
7
|
+
/**
|
|
8
|
+
* Get request extras to be passed into request function.
|
|
9
|
+
*/
|
|
10
|
+
export declare function useRequestExtras(): RequestExtras;
|
|
11
|
+
/**
|
|
12
|
+
* Request extras provider that sets the default options for all requests.
|
|
13
|
+
*
|
|
14
|
+
* @param props
|
|
15
|
+
* @param props.children Child components
|
|
16
|
+
* @param props.options RequestInit object to provide
|
|
17
|
+
*/
|
|
18
|
+
export declare function RequestExtrasProvider({ children, options, }: {
|
|
19
|
+
children: React.ReactNode;
|
|
20
|
+
options: RequestInit;
|
|
21
|
+
}): JSX.Element;
|
|
22
|
+
/**
|
|
23
|
+
* Request extras provider which merges the provided options with the parent options.
|
|
24
|
+
*
|
|
25
|
+
* @param props
|
|
26
|
+
* @param props.children Child components
|
|
27
|
+
* @param props.options RequestInit object to merge with parent options
|
|
28
|
+
*/
|
|
29
|
+
export declare function PartialRequestExtrasProvider({ children, options, }: {
|
|
30
|
+
children: React.ReactNode;
|
|
31
|
+
options: RequestInit;
|
|
32
|
+
}): JSX.Element;
|
|
33
|
+
//# sourceMappingURL=request-extras-context.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"request-extras-context.d.ts","sourceRoot":"","sources":["../../../js/shared/context/request-extras-context.tsx"],"names":[],"mappings":"AAIA,OAAO,EAAE,aAAa,EAAE,MAAM,YAAY,CAAC;AAE3C,UAAU,gBAAgB;IACtB,OAAO,EAAE,WAAW,CAAC;CACxB;AAED,QAAA,MAAM,gBAAgB,2CAAmD,CAAC;AAE1E,eAAe,gBAAgB,CAAC;AAEhC;;GAEG;AACH,wBAAgB,gBAAgB,IAAI,aAAa,CAShD;AAED;;;;;;GAMG;AACH,wBAAgB,qBAAqB,CAAC,EAClC,QAAQ,EACR,OAAO,GACV,EAAE;IACC,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B,OAAO,EAAE,WAAW,CAAC;CACxB,GAAG,GAAG,CAAC,OAAO,CAEd;AAyBD;;;;;;GAMG;AACH,wBAAgB,4BAA4B,CAAC,EACzC,QAAQ,EACR,OAAO,GACV,EAAE;IACC,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B,OAAO,EAAE,WAAW,CAAC;CACxB,GAAG,GAAG,CAAC,OAAO,CAMd"}
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { createContext, useContext, useMemo } from 'react';
|
|
3
|
+
import { useDeepCompare } from '@darajs/ui-utils';
|
|
4
|
+
const requestExtrasCtx = createContext({ options: {} });
|
|
5
|
+
export default requestExtrasCtx;
|
|
6
|
+
/**
|
|
7
|
+
* Get request extras to be passed into request function.
|
|
8
|
+
*/
|
|
9
|
+
export function useRequestExtras() {
|
|
10
|
+
const { options } = useContext(requestExtrasCtx);
|
|
11
|
+
const extras = useMemo(() => {
|
|
12
|
+
return options;
|
|
13
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
14
|
+
}, [useDeepCompare(options)]);
|
|
15
|
+
return extras;
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* Request extras provider that sets the default options for all requests.
|
|
19
|
+
*
|
|
20
|
+
* @param props
|
|
21
|
+
* @param props.children Child components
|
|
22
|
+
* @param props.options RequestInit object to provide
|
|
23
|
+
*/
|
|
24
|
+
export function RequestExtrasProvider({ children, options, }) {
|
|
25
|
+
return _jsx(requestExtrasCtx.Provider, { value: { options }, children: children });
|
|
26
|
+
}
|
|
27
|
+
/**
|
|
28
|
+
* Merge second request extras into first.
|
|
29
|
+
*
|
|
30
|
+
* Handles merging header objects rather than overwriting.
|
|
31
|
+
*
|
|
32
|
+
* @param a First request init
|
|
33
|
+
* @param b Second request init
|
|
34
|
+
*/
|
|
35
|
+
function mergeRequestInits(a, b) {
|
|
36
|
+
const mergedHeaders = new Headers(a.headers);
|
|
37
|
+
const bHeaders = new Headers(b.headers);
|
|
38
|
+
bHeaders.forEach((value, key) => {
|
|
39
|
+
mergedHeaders.set(key, value);
|
|
40
|
+
});
|
|
41
|
+
return Object.assign(Object.assign(Object.assign({}, a), b), { headers: mergedHeaders });
|
|
42
|
+
}
|
|
43
|
+
/**
|
|
44
|
+
* Request extras provider which merges the provided options with the parent options.
|
|
45
|
+
*
|
|
46
|
+
* @param props
|
|
47
|
+
* @param props.children Child components
|
|
48
|
+
* @param props.options RequestInit object to merge with parent options
|
|
49
|
+
*/
|
|
50
|
+
export function PartialRequestExtrasProvider({ children, options, }) {
|
|
51
|
+
const { options: parentOptions } = useContext(requestExtrasCtx);
|
|
52
|
+
const mergedInits = useMemo(() => mergeRequestInits(parentOptions, options), [parentOptions, options]);
|
|
53
|
+
return _jsx(requestExtrasCtx.Provider, { value: { options: mergedInits }, children: children });
|
|
54
|
+
}
|
|
55
|
+
//# sourceMappingURL=request-extras-context.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"request-extras-context.js","sourceRoot":"","sources":["../../../js/shared/context/request-extras-context.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,aAAa,EAAE,UAAU,EAAE,OAAO,EAAE,MAAM,OAAO,CAAC;AAE3D,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAQlD,MAAM,gBAAgB,GAAG,aAAa,CAAmB,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC,CAAC;AAE1E,eAAe,gBAAgB,CAAC;AAEhC;;GAEG;AACH,MAAM,UAAU,gBAAgB;IAC5B,MAAM,EAAE,OAAO,EAAE,GAAG,UAAU,CAAC,gBAAgB,CAAC,CAAC;IAEjD,MAAM,MAAM,GAAG,OAAO,CAAC,GAAG,EAAE;QACxB,OAAO,OAAO,CAAC;QACf,uDAAuD;IAC3D,CAAC,EAAE,CAAC,cAAc,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC;IAE9B,OAAO,MAAM,CAAC;AAClB,CAAC;AAED;;;;;;GAMG;AACH,MAAM,UAAU,qBAAqB,CAAC,EAClC,QAAQ,EACR,OAAO,GAIV;IACG,OAAO,KAAC,gBAAgB,CAAC,QAAQ,IAAC,KAAK,EAAE,EAAE,OAAO,EAAE,YAAG,QAAQ,GAA6B,CAAC;AACjG,CAAC;AAED;;;;;;;GAOG;AACH,SAAS,iBAAiB,CAAC,CAAc,EAAE,CAAc;IACrD,MAAM,aAAa,GAAG,IAAI,OAAO,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC;IAC7C,MAAM,QAAQ,GAAG,IAAI,OAAO,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC;IAExC,QAAQ,CAAC,OAAO,CAAC,CAAC,KAAK,EAAE,GAAG,EAAE,EAAE;QAC5B,aAAa,CAAC,GAAG,CAAC,GAAG,EAAE,KAAK,CAAC,CAAC;IAClC,CAAC,CAAC,CAAC;IAEH,qDACO,CAAC,GACD,CAAC,KACJ,OAAO,EAAE,aAAa,IACxB;AACN,CAAC;AAED;;;;;;GAMG;AACH,MAAM,UAAU,4BAA4B,CAAC,EACzC,QAAQ,EACR,OAAO,GAIV;IACG,MAAM,EAAE,OAAO,EAAE,aAAa,EAAE,GAAG,UAAU,CAAC,gBAAgB,CAAC,CAAC;IAEhE,MAAM,WAAW,GAAG,OAAO,CAAC,GAAG,EAAE,CAAC,iBAAiB,CAAC,aAAa,EAAE,OAAO,CAAC,EAAE,CAAC,aAAa,EAAE,OAAO,CAAC,CAAC,CAAC;IAEvG,OAAO,KAAC,gBAAgB,CAAC,QAAQ,IAAC,KAAK,EAAE,EAAE,OAAO,EAAE,WAAW,EAAE,YAAG,QAAQ,GAA6B,CAAC;AAC9G,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
export interface VariableContext {
|
|
3
|
+
/**
|
|
4
|
+
* Set of variables subscribed to (with useVariable)
|
|
5
|
+
*/
|
|
6
|
+
variables: React.MutableRefObject<Set<string>>;
|
|
7
|
+
}
|
|
8
|
+
declare const variablesCtx: React.Context<VariableContext>;
|
|
9
|
+
export default variablesCtx;
|
|
10
|
+
//# sourceMappingURL=variable-context.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"variable-context.d.ts","sourceRoot":"","sources":["../../../js/shared/context/variable-context.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAE/B,MAAM,WAAW,eAAe;IAC5B;;OAEG;IACH,SAAS,EAAE,KAAK,CAAC,gBAAgB,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC,CAAC;CAClD;AAED,QAAA,MAAM,YAAY,gCAA6C,CAAC;AAEhE,eAAe,YAAY,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"variable-context.js","sourceRoot":"","sources":["../../../js/shared/context/variable-context.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAS/B,MAAM,YAAY,GAAG,KAAK,CAAC,aAAa,CAAkB,IAAI,CAAC,CAAC;AAEhE,eAAe,YAAY,CAAC"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { WebSocketClientInterface } from '../../api/websocket';
|
|
2
|
+
interface WebsocketCtx {
|
|
3
|
+
client?: WebSocketClientInterface;
|
|
4
|
+
}
|
|
5
|
+
declare const websocketCtx: import("react").Context<WebsocketCtx>;
|
|
6
|
+
export default websocketCtx;
|
|
7
|
+
//# sourceMappingURL=websocket-context.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"websocket-context.d.ts","sourceRoot":"","sources":["../../../js/shared/context/websocket-context.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,wBAAwB,EAAE,MAAM,iBAAiB,CAAC;AAE3D,UAAU,YAAY;IAClB,MAAM,CAAC,EAAE,wBAAwB,CAAC;CACrC;AAED,QAAA,MAAM,YAAY,uCAAkC,CAAC;AAErD,eAAe,YAAY,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"websocket-context.js","sourceRoot":"","sources":["../../../js/shared/context/websocket-context.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAQtC,MAAM,YAAY,GAAG,aAAa,CAAe,EAAE,CAAC,CAAC;AAErD,eAAe,YAAY,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"clean-props.d.ts","sourceRoot":"","sources":["../../../js/shared/dynamic-component/clean-props.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAqB,MAAM,SAAS,CAAC;AAEhE;;GAEG;AACH,wBAAgB,UAAU,CAAC,KAAK,EAAE,kBAAkB,GAAG,kBAAkB,CAUxE"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Clean properties for a component.
|
|
3
|
+
*/
|
|
4
|
+
export function cleanProps(props) {
|
|
5
|
+
// filter out null/undefined children
|
|
6
|
+
if ('children' in props && Array.isArray(props.children)) {
|
|
7
|
+
const propsCopy = Object.assign({}, props);
|
|
8
|
+
propsCopy.children = props.children.filter(Boolean);
|
|
9
|
+
return propsCopy;
|
|
10
|
+
}
|
|
11
|
+
return props;
|
|
12
|
+
}
|
|
13
|
+
//# sourceMappingURL=clean-props.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"clean-props.js","sourceRoot":"","sources":["../../../js/shared/dynamic-component/clean-props.tsx"],"names":[],"mappings":"AAEA;;GAEG;AACH,MAAM,UAAU,UAAU,CAAC,KAAyB;IAChD,qCAAqC;IACrC,IAAI,UAAU,IAAI,KAAK,IAAI,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,QAAQ,CAAC,EAAE,CAAC;QACvD,MAAM,SAAS,GAAG,kBAAK,KAAK,CAAwE,CAAC;QACrG,SAAS,CAAC,QAAQ,GAAG,KAAK,CAAC,QAAQ,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC;QAEpD,OAAO,SAAS,CAAC;IACrB,CAAC;IAED,OAAO,KAAK,CAAC;AACjB,CAAC"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { ComponentInstance } from '../../types';
|
|
2
|
+
interface DynamicComponentProps {
|
|
3
|
+
/** The component instance to inject */
|
|
4
|
+
component: ComponentInstance;
|
|
5
|
+
}
|
|
6
|
+
/**
|
|
7
|
+
* This component dynamically loads a component from the component registry. This component can either be another JS
|
|
8
|
+
* component or it can be a python component defined in the backend. For JS components we use the importers context to
|
|
9
|
+
* load the appropriate module and then extract the right component from that by its name. For python components we hand
|
|
10
|
+
* off to the PythonWrapper component which makes the call to the backend to get the html string to inject into the DOM.
|
|
11
|
+
*
|
|
12
|
+
* @param props - the components props
|
|
13
|
+
*/
|
|
14
|
+
declare function DynamicComponent(props: DynamicComponentProps): JSX.Element;
|
|
15
|
+
export default DynamicComponent;
|
|
16
|
+
//# sourceMappingURL=dynamic-component.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dynamic-component.d.ts","sourceRoot":"","sources":["../../../js/shared/dynamic-component/dynamic-component.tsx"],"names":[],"mappings":"AAWA,OAAO,EAEH,iBAAiB,EAKpB,MAAM,SAAS,CAAC;AAoJjB,UAAU,qBAAqB;IAC3B,uCAAuC;IACvC,SAAS,EAAE,iBAAiB,CAAC;CAChC;AA8BD;;;;;;;GAOG;AACH,iBAAS,gBAAgB,CAAC,KAAK,EAAE,qBAAqB,GAAG,GAAG,CAAC,OAAO,CAwFnE;AA4DD,eAAe,gBAAgB,CAAC"}
|
|
@@ -0,0 +1,252 @@
|
|
|
1
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
2
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
3
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
4
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
5
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
6
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
7
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
8
|
+
});
|
|
9
|
+
};
|
|
10
|
+
import { jsx as _jsx, Fragment as _Fragment } from "react/jsx-runtime";
|
|
11
|
+
/* eslint-disable react-hooks/exhaustive-deps */
|
|
12
|
+
import { Suspense, useContext, useEffect, useMemo, useRef, useState } from 'react';
|
|
13
|
+
import { ErrorBoundary } from 'react-error-boundary';
|
|
14
|
+
import DefaultFallback from '../../components/fallback/default';
|
|
15
|
+
import ProgressTracker from '../../components/progress-tracker/progress-tracker';
|
|
16
|
+
import { FallbackCtx, ImportersCtx, VariableCtx, useTaskContext } from '../../shared/context';
|
|
17
|
+
import { ErrorDisplay, isSelectorError } from '../../shared/error-handling';
|
|
18
|
+
import { useRefreshSelector } from '../../shared/interactivity';
|
|
19
|
+
import useServerComponent, { useRefreshServerComponent } from '../../shared/interactivity/use-server-component';
|
|
20
|
+
import { hasTemplateMarkers, isJsComponent, useComponentRegistry, useInterval } from '../../shared/utils';
|
|
21
|
+
import { isDerivedDataVariable, isDerivedVariable, } from '../../types';
|
|
22
|
+
import { isInvalidComponent, isRawString } from '../../types/core';
|
|
23
|
+
import { cleanProps } from './clean-props';
|
|
24
|
+
/**
|
|
25
|
+
* Helper function to take a derived variable and get the lowest polling_interval of it and its chained derived
|
|
26
|
+
* variables. It will recursively call itself to get the polling_interval of the chained derived variables.
|
|
27
|
+
*
|
|
28
|
+
* @param variable the derived variable to get the polling interval
|
|
29
|
+
*/
|
|
30
|
+
function getDerivedVariablePollingInterval(variable) {
|
|
31
|
+
let pollingInterval;
|
|
32
|
+
if (variable.polling_interval) {
|
|
33
|
+
pollingInterval = variable.polling_interval;
|
|
34
|
+
}
|
|
35
|
+
variable.variables.forEach((value) => {
|
|
36
|
+
if (isDerivedVariable(value) || isDerivedDataVariable(value)) {
|
|
37
|
+
const innerPollingInterval = getDerivedVariablePollingInterval(value);
|
|
38
|
+
if (innerPollingInterval && (!pollingInterval || pollingInterval > innerPollingInterval)) {
|
|
39
|
+
pollingInterval = innerPollingInterval;
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
});
|
|
43
|
+
return pollingInterval;
|
|
44
|
+
}
|
|
45
|
+
/**
|
|
46
|
+
* Compute the polling interval for a component. This will take the polling_interval of the component and the
|
|
47
|
+
* polling_interval of any derived variables in the component kwargs and return the lowest value.
|
|
48
|
+
*
|
|
49
|
+
* @param kwargs component kwargs
|
|
50
|
+
* @param componentInterval component polling interval
|
|
51
|
+
*/
|
|
52
|
+
function computePollingInterval(kwargs, componentInterval) {
|
|
53
|
+
let pollingInterval;
|
|
54
|
+
Object.values(kwargs).forEach((value) => {
|
|
55
|
+
if (isDerivedVariable(value) || isDerivedDataVariable(value)) {
|
|
56
|
+
const innerPollingInterval = getDerivedVariablePollingInterval(value);
|
|
57
|
+
if (innerPollingInterval && (!pollingInterval || pollingInterval > innerPollingInterval)) {
|
|
58
|
+
pollingInterval = innerPollingInterval;
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
});
|
|
62
|
+
if (componentInterval && (!pollingInterval || pollingInterval > componentInterval)) {
|
|
63
|
+
pollingInterval = componentInterval;
|
|
64
|
+
}
|
|
65
|
+
return pollingInterval;
|
|
66
|
+
}
|
|
67
|
+
/**
|
|
68
|
+
* Resolve a component instance definition to an actual component to render
|
|
69
|
+
*
|
|
70
|
+
* @param component component instance definition
|
|
71
|
+
* @param getComponentEntry callback to get component registry entry
|
|
72
|
+
* @param importers importers registry
|
|
73
|
+
*/
|
|
74
|
+
function resolveComponent(component, getComponentEntry, importers) {
|
|
75
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
76
|
+
var _a;
|
|
77
|
+
const componentEntry = yield getComponentEntry(component);
|
|
78
|
+
// It's a JS component - dynamically import the right component
|
|
79
|
+
if (isJsComponent(componentEntry)) {
|
|
80
|
+
const importer = importers[componentEntry.py_module];
|
|
81
|
+
// Importer entry not present
|
|
82
|
+
if (!importer) {
|
|
83
|
+
// This error should only be seen by the app developer, so include details on how to solve it
|
|
84
|
+
const errorDescription = componentEntry.py_module === 'LOCAL' ?
|
|
85
|
+
`This is a local component so make sure you are in production mode and dara.config.json is present.
|
|
86
|
+
You can try re-building JavaScript by running Dara with the --rebuild flag.`
|
|
87
|
+
: `This means that the JavaScript module for the component was not included by the discovery system.
|
|
88
|
+
You can try re-building JavaScript by running Dara with the --rebuild flag
|
|
89
|
+
and/or explicitly registering the component with "config.add_component(MyComponentClass)".`;
|
|
90
|
+
return (_jsx(ErrorDisplay, { config: {
|
|
91
|
+
description: `Importer for module "${componentEntry.py_module}" was not found. ${errorDescription}`,
|
|
92
|
+
title: `Component "${componentEntry.name}" could not be resolved`,
|
|
93
|
+
} }));
|
|
94
|
+
}
|
|
95
|
+
let moduleContent = null;
|
|
96
|
+
try {
|
|
97
|
+
moduleContent = yield importer();
|
|
98
|
+
}
|
|
99
|
+
catch (e) {
|
|
100
|
+
// eslint-disable-next-line no-console
|
|
101
|
+
console.error(e);
|
|
102
|
+
}
|
|
103
|
+
// Could not import module
|
|
104
|
+
if (!moduleContent) {
|
|
105
|
+
return (_jsx(ErrorDisplay, { config: {
|
|
106
|
+
description: `Failed to import the JavaScript module for the component.
|
|
107
|
+
This likely means that the module was not installed properly.
|
|
108
|
+
You can try re-building JavaScript by running Dara with the --rebuild flag
|
|
109
|
+
and/or explicitly registering the component with "config.add_component(MyComponentClass)".`,
|
|
110
|
+
title: `Component "${componentEntry.name}" could not be resolved`,
|
|
111
|
+
} }));
|
|
112
|
+
}
|
|
113
|
+
const ResolvedComponent = moduleContent[(_a = componentEntry.js_component) !== null && _a !== void 0 ? _a : componentEntry.name];
|
|
114
|
+
// Component does not exist in the module
|
|
115
|
+
if (!ResolvedComponent) {
|
|
116
|
+
return (_jsx(ErrorDisplay, { config: {
|
|
117
|
+
description: `The JavaScript module was imported successfully but the component was not found within the module.`,
|
|
118
|
+
title: `Component "${componentEntry.name}" could not be resolved`,
|
|
119
|
+
} }));
|
|
120
|
+
}
|
|
121
|
+
const props = cleanProps(component.props);
|
|
122
|
+
return _jsx(ResolvedComponent, Object.assign({ uid: component.uid }, props));
|
|
123
|
+
}
|
|
124
|
+
// Otherwise it's a @py_component
|
|
125
|
+
return (
|
|
126
|
+
// eslint-disable-next-line @typescript-eslint/no-use-before-define
|
|
127
|
+
_jsx(PythonWrapper, { dynamic_kwargs: component.props.dynamic_kwargs, func_name: component.props.func_name, name: component.name, polling_interval: component.props.polling_interval, uid: component.uid }));
|
|
128
|
+
});
|
|
129
|
+
}
|
|
130
|
+
/**
|
|
131
|
+
* Get the fallback component for a given component instance
|
|
132
|
+
*
|
|
133
|
+
* @param fallback the fallback component instance
|
|
134
|
+
* @param track_progress whether to track progress
|
|
135
|
+
* @param variablesRef ref to set of variables to track
|
|
136
|
+
* @param taskRef ref to task id of the running task
|
|
137
|
+
*/
|
|
138
|
+
function getFallbackComponent(fallback, track_progress, variablesRef) {
|
|
139
|
+
let fallbackComponent = _jsx(DefaultFallback, {});
|
|
140
|
+
// user overrode the default fallback
|
|
141
|
+
if (fallback) {
|
|
142
|
+
// eslint-disable-next-line @typescript-eslint/no-use-before-define
|
|
143
|
+
fallbackComponent = _jsx(DynamicComponent, { component: fallback });
|
|
144
|
+
}
|
|
145
|
+
if (track_progress) {
|
|
146
|
+
return _jsx(ProgressTracker, { fallback: fallbackComponent, variablesRef: variablesRef });
|
|
147
|
+
}
|
|
148
|
+
return fallbackComponent;
|
|
149
|
+
}
|
|
150
|
+
/**
|
|
151
|
+
* This component dynamically loads a component from the component registry. This component can either be another JS
|
|
152
|
+
* component or it can be a python component defined in the backend. For JS components we use the importers context to
|
|
153
|
+
* load the appropriate module and then extract the right component from that by its name. For python components we hand
|
|
154
|
+
* off to the PythonWrapper component which makes the call to the backend to get the html string to inject into the DOM.
|
|
155
|
+
*
|
|
156
|
+
* @param props - the components props
|
|
157
|
+
*/
|
|
158
|
+
function DynamicComponent(props) {
|
|
159
|
+
var _a, _b, _c, _d, _e, _f;
|
|
160
|
+
const [isLoading, setIsLoading] = useState(true);
|
|
161
|
+
const [component, setComponent] = useState();
|
|
162
|
+
const { get: getComponent } = useComponentRegistry();
|
|
163
|
+
const importers = useContext(ImportersCtx);
|
|
164
|
+
const fallbackCtx = useContext(FallbackCtx);
|
|
165
|
+
const firstRender = useRef(true);
|
|
166
|
+
if (firstRender.current) {
|
|
167
|
+
if (hasTemplateMarkers(props.component)) {
|
|
168
|
+
throw new Error(`Component "${props.component.name}" has unhandled template markers. Make sure it's used in a component which handles templated components`);
|
|
169
|
+
}
|
|
170
|
+
firstRender.current = false;
|
|
171
|
+
}
|
|
172
|
+
useEffect(() => {
|
|
173
|
+
var _a;
|
|
174
|
+
if (((_a = props.component) === null || _a === void 0 ? void 0 : _a.name) === 'RawString') {
|
|
175
|
+
setComponent(props.component.props.content);
|
|
176
|
+
setIsLoading(false);
|
|
177
|
+
return;
|
|
178
|
+
}
|
|
179
|
+
if (props.component) {
|
|
180
|
+
resolveComponent(props.component, getComponent, importers).then((ResolvedComponent) => {
|
|
181
|
+
setComponent(ResolvedComponent);
|
|
182
|
+
setIsLoading(false);
|
|
183
|
+
});
|
|
184
|
+
}
|
|
185
|
+
}, [props.component, getComponent]);
|
|
186
|
+
const refreshSelector = useRefreshSelector();
|
|
187
|
+
function onResetErrorBoundary(error) {
|
|
188
|
+
if (isSelectorError(error)) {
|
|
189
|
+
refreshSelector(error.selectorId, error.selectorExtras);
|
|
190
|
+
}
|
|
191
|
+
}
|
|
192
|
+
const taskCtx = useTaskContext();
|
|
193
|
+
const variables = useRef(new Set());
|
|
194
|
+
/*
|
|
195
|
+
When this component unmounts, then cancel any pending tasks for this component. This is required because recoil uses
|
|
196
|
+
React.Suspense which at the time of writing does not support cancellation
|
|
197
|
+
This does not necessarily cancel the task, on the backend we keep track of number of subscribers,
|
|
198
|
+
'cancelling' the task actually decrements the number of subs; the task is only cancelled once there are 0 subscribers left
|
|
199
|
+
*/
|
|
200
|
+
useEffect(() => {
|
|
201
|
+
return () => {
|
|
202
|
+
// If there are running tasks and this component is subscribed to variables
|
|
203
|
+
if (variables.current.size > 0 && taskCtx.hasRunningTasks()) {
|
|
204
|
+
taskCtx.cleanupRunningTasks(...variables.current.values());
|
|
205
|
+
}
|
|
206
|
+
};
|
|
207
|
+
}, []);
|
|
208
|
+
const [fallback] = useState(() => { var _a, _b, _c, _d; return getFallbackComponent((_b = (_a = props.component) === null || _a === void 0 ? void 0 : _a.props) === null || _b === void 0 ? void 0 : _b.fallback, (_d = (_c = props.component) === null || _c === void 0 ? void 0 : _c.props) === null || _d === void 0 ? void 0 : _d.track_progress, variables); });
|
|
209
|
+
if (isLoading) {
|
|
210
|
+
return null;
|
|
211
|
+
}
|
|
212
|
+
// Compute the suspend setting for the component in order of precedence:
|
|
213
|
+
// 1) explicit suspend_render setting on the component
|
|
214
|
+
// 2) setting inherited from a parent component
|
|
215
|
+
// 3) default value of 200ms
|
|
216
|
+
const suspend = (_f = (_e = (_d = (_c = (_b = (_a = props.component) === null || _a === void 0 ? void 0 : _a.props) === null || _b === void 0 ? void 0 : _b.fallback) === null || _c === void 0 ? void 0 : _c.props) === null || _d === void 0 ? void 0 : _d.suspend_render) !== null && _e !== void 0 ? _e : fallbackCtx === null || fallbackCtx === void 0 ? void 0 : fallbackCtx.suspend) !== null && _f !== void 0 ? _f : 200;
|
|
217
|
+
return (_jsx(ErrorBoundary, { fallbackRender: (fallbackProps) => {
|
|
218
|
+
var _a, _b;
|
|
219
|
+
return (_jsx(ErrorDisplay, Object.assign({ config: (_b = (_a = props.component) === null || _a === void 0 ? void 0 : _a.props) === null || _b === void 0 ? void 0 : _b.error_handler }, fallbackProps)));
|
|
220
|
+
}, onReset: onResetErrorBoundary, children: _jsx(FallbackCtx.Provider, { value: { suspend }, children: _jsx(VariableCtx.Provider, { value: { variables }, children: _jsx(Suspense, { fallback: fallback, children: component }) }) }) }));
|
|
221
|
+
}
|
|
222
|
+
/**
|
|
223
|
+
* This component handles rendering a server component. Utilises the
|
|
224
|
+
* useServerComponent hook to make the call to the backend and then renders the returned component definition.
|
|
225
|
+
*
|
|
226
|
+
* Handles polling for the component if polling_interval is set in the component definition or in any of the
|
|
227
|
+
* dynamic_kwargs (checked recursively).
|
|
228
|
+
*/
|
|
229
|
+
function PythonWrapper(props) {
|
|
230
|
+
const component = useServerComponent(props.name, props.uid, props.dynamic_kwargs);
|
|
231
|
+
const refresh = useRefreshServerComponent(props.uid);
|
|
232
|
+
// Poll to update the component if polling_interval is set
|
|
233
|
+
const pollingInterval = useMemo(() => computePollingInterval(props.dynamic_kwargs, props.polling_interval), [props.polling_interval]);
|
|
234
|
+
useInterval(refresh, pollingInterval);
|
|
235
|
+
if (component === null) {
|
|
236
|
+
return null;
|
|
237
|
+
}
|
|
238
|
+
if (isRawString(component)) {
|
|
239
|
+
return _jsx(_Fragment, { children: component.props.content });
|
|
240
|
+
}
|
|
241
|
+
if (isInvalidComponent(component)) {
|
|
242
|
+
return (_jsx(ErrorDisplay, { config: {
|
|
243
|
+
description: component.props.error,
|
|
244
|
+
title: `Component "${props.func_name}" returned an invalid component`,
|
|
245
|
+
}, resetErrorBoundary: () => {
|
|
246
|
+
refresh();
|
|
247
|
+
} }));
|
|
248
|
+
}
|
|
249
|
+
return _jsx(DynamicComponent, { component: component }, component.uid);
|
|
250
|
+
}
|
|
251
|
+
export default DynamicComponent;
|
|
252
|
+
//# sourceMappingURL=dynamic-component.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dynamic-component.js","sourceRoot":"","sources":["../../../js/shared/dynamic-component/dynamic-component.tsx"],"names":[],"mappings":";;;;;;;;;;AAAA,gDAAgD;AAChD,OAAO,EAAoB,QAAQ,EAAE,UAAU,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACrG,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AAErD,OAAO,eAAe,MAAM,+BAA+B,CAAC;AAC5D,OAAO,eAAe,MAAM,gDAAgD,CAAC;AAC7E,OAAO,EAAE,WAAW,EAAE,YAAY,EAAE,WAAW,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAC1F,OAAO,EAAE,YAAY,EAAE,eAAe,EAAE,MAAM,yBAAyB,CAAC;AACxE,OAAO,EAAE,kBAAkB,EAAE,MAAM,wBAAwB,CAAC;AAC5D,OAAO,kBAAkB,EAAE,EAAE,yBAAyB,EAAE,MAAM,6CAA6C,CAAC;AAC5G,OAAO,EAAE,kBAAkB,EAAE,aAAa,EAAE,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E,CAAC;QACzB,OAAO,4BAAG,SAAS,CAAC,KAAK,CAAC,OAAO,GAAI,CAAC;IAC1C,CAAC;IAED,IAAI,kBAAkB,CAAC,SAAS,CAAC,EAAE,CAAC;QAChC,OAAO,CACH,KAAC,YAAY,IACT,MAAM,EAAE;gBACJ,WAAW,EAAE,SAAS,CAAC,KAAK,CAAC,KAAK;gBAClC,KAAK,EAAE,cAAc,KAAK,CAAC,SAAS,iCAAiC;aACxE,EACD,kBAAkB,EAAE,GAAG,EAAE;gBACrB,OAAO,EAAE,CAAC;YACd,CAAC,GACH,CACL,CAAC;IACN,CAAC;IAED,OAAO,KAAC,gBAAgB,IAAC,SAAS,EAAE,SAAS,IAAO,SAAS,CAAC,GAAG,CAAI,CAAC;AAC1E,CAAC;AAED,eAAe,gBAAgB,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { FallbackProps } from 'react-error-boundary';
|
|
2
|
+
import { ErrorHandlingConfig } from '../../types/core';
|
|
3
|
+
interface ErrorDisplayProps extends Partial<FallbackProps> {
|
|
4
|
+
config?: ErrorHandlingConfig;
|
|
5
|
+
}
|
|
6
|
+
declare function ErrorDisplay(props: ErrorDisplayProps): JSX.Element;
|
|
7
|
+
export default ErrorDisplay;
|
|
8
|
+
//# sourceMappingURL=error-display.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"error-display.d.ts","sourceRoot":"","sources":["../../../js/shared/error-handling/error-display.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AAKrD,OAAO,EAAE,mBAAmB,EAAE,MAAM,cAAc,CAAC;AA6FnD,UAAU,iBAAkB,SAAQ,OAAO,CAAC,aAAa,CAAC;IACtD,MAAM,CAAC,EAAE,mBAAmB,CAAC;CAChC;AAED,iBAAS,YAAY,CAAC,KAAK,EAAE,iBAAiB,GAAG,GAAG,CAAC,OAAO,CAuB3D;AAED,eAAe,YAAY,CAAC"}
|