@nu-art/thunderstorm-frontend 0.400.5
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/_ats/ATS_ActionProcessor/ATS_ActionProcessor.d.ts +17 -0
- package/_ats/ATS_ActionProcessor/ATS_ActionProcessor.js +52 -0
- package/_ats/ATS_ActionProcessor/ATS_ActionProcessor.scss +43 -0
- package/_ats/ATS_AppConfigEditor/ATS_AppConfigEditor.d.ts +25 -0
- package/_ats/ATS_AppConfigEditor/ATS_AppConfigEditor.js +88 -0
- package/_ats/ATS_AppConfigEditor/ATS_AppConfigEditor.scss +117 -0
- package/_ats/ATS_CollectionUpgrades/ATS_CollectionUpgrades.d.ts +17 -0
- package/_ats/ATS_CollectionUpgrades/ATS_CollectionUpgrades.js +45 -0
- package/_ats/ATS_CollectionUpgrades/ATS_CollectionUpgrades.scss +24 -0
- package/_ats/ATS_CrudOperations/ATS_CrudOperations.d.ts +29 -0
- package/_ats/ATS_CrudOperations/ATS_CrudOperations.js +93 -0
- package/_ats/ATS_CrudOperations/ATS_CrudOperations.scss +46 -0
- package/_ats/ATS_CrudOperations/ui-components.d.ts +24 -0
- package/_ats/ATS_CrudOperations/ui-components.js +11 -0
- package/_ats/ATS_EditableItem/ATS_EditableItem.d.ts +16 -0
- package/_ats/ATS_EditableItem/ATS_EditableItem.js +48 -0
- package/_ats/ATS_IDBCacheComparison/ATS_IDBCacheComparison.d.ts +18 -0
- package/_ats/ATS_IDBCacheComparison/ATS_IDBCacheComparison.js +28 -0
- package/_ats/ATS_IDBCacheComparison/ATS_IDBCacheComparison.scss +7 -0
- package/_ats/ATS_IDBCacheComparison/Component_CollectionGrid.d.ts +23 -0
- package/_ats/ATS_IDBCacheComparison/Component_CollectionGrid.js +66 -0
- package/_ats/ATS_IDBCacheComparison/Component_CollectionGrid.scss +52 -0
- package/_ats/ATS_IDBCacheComparison/Dialog_IDBCacheComparison.d.ts +17 -0
- package/_ats/ATS_IDBCacheComparison/Dialog_IDBCacheComparison.js +30 -0
- package/_ats/ATS_IDBCacheComparison/Dialog_IDBCacheComparison.scss +25 -0
- package/_ats/ATS_Printables/ATS_AbstractPrintable.d.ts +16 -0
- package/_ats/ATS_Printables/ATS_AbstractPrintable.js +37 -0
- package/_ats/ATS_Printables/ATS_Printable.d.ts +13 -0
- package/_ats/ATS_Printables/ATS_Printable.js +45 -0
- package/_ats/ATS_Printables/ATS_Printable.scss +40 -0
- package/_ats/ATS_ProtoComponent/ATS_ProtoComponent.d.ts +33 -0
- package/_ats/ATS_ProtoComponent/ATS_ProtoComponent.js +80 -0
- package/_ats/ATS_ProtoComponent/ATS_ProtoComponent.scss +19 -0
- package/_ats/ATS_SyncEnv/ATS_SyncEnv.d.ts +51 -0
- package/_ats/ATS_SyncEnv/ATS_SyncEnv.js +215 -0
- package/_ats/ATS_SyncEnv/ATS_SyncEnv.scss +172 -0
- package/_ats/ATS_Toaster/ATS_Toaster.d.ts +23 -0
- package/_ats/ATS_Toaster/ATS_Toaster.js +48 -0
- package/_ats/ATS_Toaster/ATS_Toaster.scss +2 -0
- package/_ats/ATS_Toaster/index.d.ts +1 -0
- package/_ats/ATS_Toaster/index.js +1 -0
- package/_ats/dialogs/Dialog_ActionProcessorConfirmation/Dialog_ActionProcessorConfirmation.d.ts +18 -0
- package/_ats/dialogs/Dialog_ActionProcessorConfirmation/Dialog_ActionProcessorConfirmation.js +41 -0
- package/_ats/dialogs/Dialog_ActionProcessorConfirmation/Dialog_ActionProcessorConfirmation.scss +71 -0
- package/_ats/dialogs/index.d.ts +1 -0
- package/_ats/dialogs/index.js +1 -0
- package/_ats/index.d.ts +8 -0
- package/_ats/index.js +8 -0
- package/_entity/app-config/ModuleFE_AppConfig.d.ts +24 -0
- package/_entity/app-config/ModuleFE_AppConfig.js +52 -0
- package/_entity/app-config/index.d.ts +2 -0
- package/_entity/app-config/index.js +2 -0
- package/_entity/app-config/module-pack.d.ts +1 -0
- package/_entity/app-config/module-pack.js +2 -0
- package/_entity/editable-test/ModuleFE_EditableTest.d.ts +11 -0
- package/_entity/editable-test/ModuleFE_EditableTest.js +12 -0
- package/_entity/editable-test/index.d.ts +2 -0
- package/_entity/editable-test/index.js +2 -0
- package/_entity/editable-test/module-pack.d.ts +1 -0
- package/_entity/editable-test/module-pack.js +2 -0
- package/_entity/editable-test/ui-components.d.ts +37 -0
- package/_entity/editable-test/ui-components.js +21 -0
- package/_entity.d.ts +2 -0
- package/_entity.js +2 -0
- package/_to-refactor/MenuAndButton.d.ts +1 -0
- package/_to-refactor/MenuAndButton.js +87 -0
- package/behavior-functions/index.d.ts +1 -0
- package/behavior-functions/index.js +1 -0
- package/behavior-functions/scroll-into-view.d.ts +6 -0
- package/behavior-functions/scroll-into-view.js +55 -0
- package/component-modules/ModuleFE_Dialog.d.ts +27 -0
- package/component-modules/ModuleFE_Dialog.js +48 -0
- package/component-modules/ModuleFE_Notifications.d.ts +45 -0
- package/component-modules/ModuleFE_Notifications.js +133 -0
- package/component-modules/ModuleFE_Toaster.d.ts +28 -0
- package/component-modules/ModuleFE_Toaster.js +97 -0
- package/component-modules/mouse-interactivity/ModuleFE_MouseInteractivity.d.ts +9 -0
- package/component-modules/mouse-interactivity/ModuleFE_MouseInteractivity.js +35 -0
- package/component-modules/mouse-interactivity/helper-functions.d.ts +108 -0
- package/component-modules/mouse-interactivity/helper-functions.js +339 -0
- package/component-modules/mouse-interactivity/index.d.ts +3 -0
- package/component-modules/mouse-interactivity/index.js +3 -0
- package/component-modules/mouse-interactivity/types.d.ts +37 -0
- package/component-modules/mouse-interactivity/types.js +2 -0
- package/components/ActionButton.d.ts +7 -0
- package/components/ActionButton.js +29 -0
- package/components/AwaitModules/AwaitModules.d.ts +40 -0
- package/components/AwaitModules/AwaitModules.js +95 -0
- package/components/AwaitModules/AwaitModules.scss +53 -0
- package/components/AwaitSync/AwaitSync.d.ts +18 -0
- package/components/AwaitSync/AwaitSync.js +25 -0
- package/components/AwaitSync/AwaitSync.scss +13 -0
- package/components/Button/ATS_Button.d.ts +21 -0
- package/components/Button/ATS_Button.js +66 -0
- package/components/Button/ATS_Button.scss +19 -0
- package/components/Button/Button.d.ts +40 -0
- package/components/Button/Button.js +94 -0
- package/components/Button/Button.scss +151 -0
- package/components/FrameLayout/FrameLayout.d.ts +7 -0
- package/components/FrameLayout/FrameLayout.js +10 -0
- package/components/FrameLayout/FrameLayout.scss +5 -0
- package/components/FrameLayout/index.d.ts +1 -0
- package/components/FrameLayout/index.js +1 -0
- package/components/GenericDropDown/GenericDropDownV3.d.ts +108 -0
- package/components/GenericDropDown/GenericDropDownV3.js +98 -0
- package/components/GenericDropDown/index.d.ts +1 -0
- package/components/GenericDropDown/index.js +1 -0
- package/components/GenericRenderer/Component_GenericRenderer.d.ts +15 -0
- package/components/GenericRenderer/Component_GenericRenderer.js +13 -0
- package/components/HeightBounder.d.ts +11 -0
- package/components/HeightBounder.js +25 -0
- package/components/Label/ATS_Label.d.ts +12 -0
- package/components/Label/ATS_Label.js +34 -0
- package/components/Label/ATS_Label.scss +24 -0
- package/components/Label/Label.d.ts +30 -0
- package/components/Label/Label.js +84 -0
- package/components/Label/Label.scss +89 -0
- package/components/Layouts/Layouts.d.ts +38 -0
- package/components/Layouts/Layouts.js +56 -0
- package/components/Layouts/_Layouts.scss +53 -0
- package/components/Layouts/_Layouts_.scss +69 -0
- package/components/Layouts/index.d.ts +1 -0
- package/components/Layouts/index.js +21 -0
- package/components/Page_ItemsEditor/Page_ItemsEditor.d.ts +66 -0
- package/components/Page_ItemsEditor/Page_ItemsEditor.js +134 -0
- package/components/Page_ItemsEditor/Page_ItemsEditor.scss +104 -0
- package/components/Page_ItemsEditor/defaults/ItemEditor_DefaultFilter/ItemEditor_DefaultFilter.d.ts +16 -0
- package/components/Page_ItemsEditor/defaults/ItemEditor_DefaultFilter/ItemEditor_DefaultFilter.js +15 -0
- package/components/Page_ItemsEditor/defaults/ItemEditor_DefaultFilter/ItemEditor_DefaultFilter.scss +4 -0
- package/components/Page_ItemsEditor/defaults/ItemEditor_DefaultFilter/index.d.ts +1 -0
- package/components/Page_ItemsEditor/defaults/ItemEditor_DefaultFilter/index.js +1 -0
- package/components/Page_ItemsEditor/defaults/ItemEditor_ListRenderer/ItemEditor_DefaultList.d.ts +26 -0
- package/components/Page_ItemsEditor/defaults/ItemEditor_ListRenderer/ItemEditor_DefaultList.js +68 -0
- package/components/Page_ItemsEditor/defaults/ItemEditor_ListRenderer/ItemEditor_DefaultList.scss +4 -0
- package/components/Page_ItemsEditor/defaults/ItemEditor_ListRenderer/index.d.ts +1 -0
- package/components/Page_ItemsEditor/defaults/ItemEditor_ListRenderer/index.js +1 -0
- package/components/Page_ItemsEditor/index.d.ts +1 -0
- package/components/Page_ItemsEditor/index.js +1 -0
- package/components/Page_ItemsEditor/types.d.ts +4 -0
- package/components/Page_ItemsEditor/types.js +1 -0
- package/components/RelativeLayout/RelativeLayout.d.ts +7 -0
- package/components/RelativeLayout/RelativeLayout.js +10 -0
- package/components/RelativeLayout/RelativeLayout.scss +3 -0
- package/components/RelativeLayout/index.d.ts +1 -0
- package/components/RelativeLayout/index.js +1 -0
- package/components/Show.d.ts +20 -0
- package/components/Show.js +30 -0
- package/components/TS_AppTools/TS_AppTools.d.ts +30 -0
- package/components/TS_AppTools/TS_AppTools.js +144 -0
- package/components/TS_AppTools/TS_AppTools.scss +193 -0
- package/components/TS_AppTools/TS_AppTools_Default.d.ts +7 -0
- package/components/TS_AppTools/TS_AppTools_Default.js +16 -0
- package/components/TS_AppTools/index.d.ts +2 -0
- package/components/TS_AppTools/index.js +22 -0
- package/components/TS_AppTools/types.d.ts +19 -0
- package/components/TS_AppTools/types.js +6 -0
- package/components/TS_ButtonGroup/TS_ButtonGroup.d.ts +12 -0
- package/components/TS_ButtonGroup/TS_ButtonGroup.js +94 -0
- package/components/TS_ButtonGroup/TS_ButtonGroup.scss +58 -0
- package/components/TS_ButtonGroup/index.d.ts +2 -0
- package/components/TS_ButtonGroup/index.js +2 -0
- package/components/TS_ButtonGroup/types.d.ts +38 -0
- package/components/TS_ButtonGroup/types.js +1 -0
- package/components/TS_ButtonLoader/TS_ButtonLoader.d.ts +5 -0
- package/components/TS_ButtonLoader/TS_ButtonLoader.js +8 -0
- package/components/TS_ButtonLoader/TS_ButtonLoader.scss +63 -0
- package/components/TS_ButtonLoader/index.d.ts +1 -0
- package/components/TS_ButtonLoader/index.js +1 -0
- package/components/TS_Card/TS_Card.d.ts +7 -0
- package/components/TS_Card/TS_Card.js +14 -0
- package/components/TS_Card/TS_Card.scss +7 -0
- package/components/TS_Card/index.d.ts +1 -0
- package/components/TS_Card/index.js +1 -0
- package/components/TS_Checkbox/ATS_CheckboxV2.d.ts +3 -0
- package/components/TS_Checkbox/ATS_CheckboxV2.js +30 -0
- package/components/TS_Checkbox/ATS_CheckboxV2.scss +4 -0
- package/components/TS_Checkbox/TS_Checkbox.d.ts +48 -0
- package/components/TS_Checkbox/TS_Checkbox.js +46 -0
- package/components/TS_Checkbox/TS_Checkbox.scss +62 -0
- package/components/TS_Checkbox/TS_CheckboxV2.d.ts +37 -0
- package/components/TS_Checkbox/TS_CheckboxV2.js +53 -0
- package/components/TS_Checkbox/TS_CheckboxV2.scss +97 -0
- package/components/TS_Checkbox/index.d.ts +1 -0
- package/components/TS_Checkbox/index.js +21 -0
- package/components/TS_CheckboxGroup/ATS_CheckboxGroup.d.ts +19 -0
- package/components/TS_CheckboxGroup/ATS_CheckboxGroup.js +89 -0
- package/components/TS_CheckboxGroup/ATS_CheckboxGroup.scss +6 -0
- package/components/TS_CheckboxGroup/TS_CheckboxGroup.d.ts +35 -0
- package/components/TS_CheckboxGroup/TS_CheckboxGroup.js +47 -0
- package/components/TS_CheckboxGroup/TS_CheckboxGroup.scss +32 -0
- package/components/TS_CheckboxGroup/index.d.ts +1 -0
- package/components/TS_CheckboxGroup/index.js +1 -0
- package/components/TS_CollapsableContainer/TS_CollapsableContainer.d.ts +44 -0
- package/components/TS_CollapsableContainer/TS_CollapsableContainer.js +80 -0
- package/components/TS_CollapsableContainer/TS_CollapsableContainer.scss +47 -0
- package/components/TS_CollapsableContainer/index.d.ts +1 -0
- package/components/TS_CollapsableContainer/index.js +1 -0
- package/components/TS_CollapsableContainerV2/TS_CollapsableContainerV2.d.ts +36 -0
- package/components/TS_CollapsableContainerV2/TS_CollapsableContainerV2.js +46 -0
- package/components/TS_CollapsableContainerV2/TS_CollapsableContainerV2.scss +66 -0
- package/components/TS_CollapsableContainerV2/ats.d.ts +3 -0
- package/components/TS_CollapsableContainerV2/ats.js +39 -0
- package/components/TS_CollapsableContainerV2/ats.scss +35 -0
- package/components/TS_CollapsableContainerV2/index.d.ts +2 -0
- package/components/TS_CollapsableContainerV2/index.js +2 -0
- package/components/TS_ComponentTransition/TS_ComponentTransition.d.ts +25 -0
- package/components/TS_ComponentTransition/TS_ComponentTransition.js +65 -0
- package/components/TS_ComponentTransition/index.d.ts +1 -0
- package/components/TS_ComponentTransition/index.js +1 -0
- package/components/TS_CopyToClipboard/TS_CopyToClipboard.d.ts +4 -0
- package/components/TS_CopyToClipboard/TS_CopyToClipboard.js +11 -0
- package/components/TS_CopyToClipboard/index.d.ts +1 -0
- package/components/TS_CopyToClipboard/index.js +21 -0
- package/components/TS_Dialog/TS_Dialog.d.ts +89 -0
- package/components/TS_Dialog/TS_Dialog.js +140 -0
- package/components/TS_Dialog/TS_Dialog.scss +116 -0
- package/components/TS_Dialog/TS_DialogOverlay.d.ts +15 -0
- package/components/TS_Dialog/TS_DialogOverlay.js +48 -0
- package/components/TS_Dialog/TS_DialogOverlay.scss +41 -0
- package/components/TS_Dialog/TS_SimpleDialog.d.ts +21 -0
- package/components/TS_Dialog/TS_SimpleDialog.js +37 -0
- package/components/TS_Dialog/TS_SimpleDialog.scss +5 -0
- package/components/TS_Dialog/TS_SimpleDialogue.d.ts +28 -0
- package/components/TS_Dialog/TS_SimpleDialogue.js +38 -0
- package/components/TS_Dialog/index.d.ts +2 -0
- package/components/TS_Dialog/index.js +22 -0
- package/components/TS_DragAndDrop/TS_DragAndDrop.d.ts +48 -0
- package/components/TS_DragAndDrop/TS_DragAndDrop.js +105 -0
- package/components/TS_DragAndDrop/TS_DragAndDrop.scss +61 -0
- package/components/TS_DragAndDrop/index.d.ts +1 -0
- package/components/TS_DragAndDrop/index.js +21 -0
- package/components/TS_Dropdown/TS_DropDown.d.ts +120 -0
- package/components/TS_Dropdown/TS_DropDown.js +332 -0
- package/components/TS_Dropdown/TS_DropDown.scss +134 -0
- package/components/TS_Dropdown/index.d.ts +1 -0
- package/components/TS_Dropdown/index.js +21 -0
- package/components/TS_EditableContent/TS_EditableContent.d.ts +19 -0
- package/components/TS_EditableContent/TS_EditableContent.js +32 -0
- package/components/TS_EditableContent/types.d.ts +4 -0
- package/components/TS_EditableContent/types.js +1 -0
- package/components/TS_EditableItemComponent/TS_EditableItemComponent.d.ts +23 -0
- package/components/TS_EditableItemComponent/TS_EditableItemComponent.js +47 -0
- package/components/TS_EditableItemController/TS_EditableItemController.d.ts +36 -0
- package/components/TS_EditableItemController/TS_EditableItemController.js +54 -0
- package/components/TS_EditableItemController/TS_EditableItemController.scss +3 -0
- package/components/TS_EditableItemController/index.d.ts +1 -0
- package/components/TS_EditableItemController/index.js +1 -0
- package/components/TS_EditableItemControllerProto/TS_EditableItemControllerProto.d.ts +32 -0
- package/components/TS_EditableItemControllerProto/TS_EditableItemControllerProto.js +53 -0
- package/components/TS_EditableItemControllerProto/TS_EditableItemControllerProto.scss +3 -0
- package/components/TS_EditableItemControllerProto/index.d.ts +1 -0
- package/components/TS_EditableItemControllerProto/index.js +1 -0
- package/components/TS_EditableItemStatus/TS_EditableItemStatus.d.ts +20 -0
- package/components/TS_EditableItemStatus/TS_EditableItemStatus.js +34 -0
- package/components/TS_EditableText/TS_EditableText.d.ts +57 -0
- package/components/TS_EditableText/TS_EditableText.js +100 -0
- package/components/TS_EditableText/TS_EditableText.scss +90 -0
- package/components/TS_EditableText/index.d.ts +1 -0
- package/components/TS_EditableText/index.js +1 -0
- package/components/TS_ErrorBoundary/TS_ErrorBoundary.d.ts +54 -0
- package/components/TS_ErrorBoundary/TS_ErrorBoundary.js +103 -0
- package/components/TS_ErrorBoundary/TS_ErrorBoundary.scss +95 -0
- package/components/TS_ErrorBoundary/index.d.ts +1 -0
- package/components/TS_ErrorBoundary/index.js +21 -0
- package/components/TS_Form/TS_Form.d.ts +9 -0
- package/components/TS_Form/TS_Form.js +11 -0
- package/components/TS_Form/TS_Form.scss +0 -0
- package/components/TS_Form/consts.d.ts +1 -0
- package/components/TS_Form/consts.js +1 -0
- package/components/TS_Form/index.d.ts +3 -0
- package/components/TS_Form/index.js +3 -0
- package/components/TS_Form/types.d.ts +13 -0
- package/components/TS_Form/types.js +1 -0
- package/components/TS_GridTableProto/TS_GridTableProto.d.ts +18 -0
- package/components/TS_GridTableProto/TS_GridTableProto.js +22 -0
- package/components/TS_GridTableProto/TS_GridTableProto.scss +4 -0
- package/components/TS_GridTableProto/index.d.ts +1 -0
- package/components/TS_GridTableProto/index.js +1 -0
- package/components/TS_Input/ATS_TextArea.d.ts +14 -0
- package/components/TS_Input/ATS_TextArea.js +24 -0
- package/components/TS_Input/ATS_TextArea.scss +24 -0
- package/components/TS_Input/TS_BaseInput.d.ts +44 -0
- package/components/TS_Input/TS_BaseInput.js +47 -0
- package/components/TS_Input/TS_Input.d.ts +24 -0
- package/components/TS_Input/TS_Input.js +53 -0
- package/components/TS_Input/TS_Input.scss +64 -0
- package/components/TS_Input/TS_TextArea.d.ts +14 -0
- package/components/TS_Input/TS_TextArea.js +72 -0
- package/components/TS_Input/TS_TextArea.scss +41 -0
- package/components/TS_Input/index.d.ts +4 -0
- package/components/TS_Input/index.js +25 -0
- package/components/TS_JSONViewer/TS_JSONViewer.d.ts +18 -0
- package/components/TS_JSONViewer/TS_JSONViewer.js +64 -0
- package/components/TS_JSONViewer/TS_JSONViewer.scss +87 -0
- package/components/TS_JSONViewer/types.d.ts +10 -0
- package/components/TS_JSONViewer/types.js +1 -0
- package/components/TS_Link/TS_Link.d.ts +15 -0
- package/components/TS_Link/TS_Link.js +36 -0
- package/components/TS_Link/TS_Link.scss +32 -0
- package/components/TS_Link/index.d.ts +1 -0
- package/components/TS_Link/index.js +21 -0
- package/components/TS_ListOrganizer/TS_ListOrganizer.d.ts +33 -0
- package/components/TS_ListOrganizer/TS_ListOrganizer.js +64 -0
- package/components/TS_ListOrganizer/TS_ListOrganizer.scss +37 -0
- package/components/TS_ListOrganizer/index.d.ts +1 -0
- package/components/TS_ListOrganizer/index.js +21 -0
- package/components/TS_Loader/TS_Loader.d.ts +6 -0
- package/components/TS_Loader/TS_Loader.js +9 -0
- package/components/TS_Loader/TS_Loader.scss +71 -0
- package/components/TS_Loader/index.d.ts +1 -0
- package/components/TS_Loader/index.js +1 -0
- package/components/TS_MemoryMonitor/TS_MemoryMonitor.d.ts +10 -0
- package/components/TS_MemoryMonitor/TS_MemoryMonitor.js +48 -0
- package/components/TS_MemoryMonitor/TS_MemoryMonitor.scss +31 -0
- package/components/TS_MemoryMonitor/index.d.ts +1 -0
- package/components/TS_MemoryMonitor/index.js +21 -0
- package/components/TS_MouseInteractivity/TS_PopUp/TS_PopUp.d.ts +9 -0
- package/components/TS_MouseInteractivity/TS_PopUp/TS_PopUp.js +28 -0
- package/components/TS_MouseInteractivity/TS_PopUp/TS_PopUp.scss +53 -0
- package/components/TS_MouseInteractivity/TS_Tooltip/TS_ToolTip.d.ts +12 -0
- package/components/TS_MouseInteractivity/TS_Tooltip/TS_ToolTip.js +65 -0
- package/components/TS_MouseInteractivity/TS_Tooltip/TS_ToolTip.scss +46 -0
- package/components/TS_MouseInteractivity/base/TS_MouseInteractivity.d.ts +18 -0
- package/components/TS_MouseInteractivity/base/TS_MouseInteractivity.js +100 -0
- package/components/TS_MouseInteractivity/index.d.ts +2 -0
- package/components/TS_MouseInteractivity/index.js +22 -0
- package/components/TS_MultiSelect/TS_MultiSelect.scss +34 -0
- package/components/TS_MultiSelect/TS_MultiSelect_V2.d.ts +36 -0
- package/components/TS_MultiSelect/TS_MultiSelect_V2.js +41 -0
- package/components/TS_MultiSelect/index.d.ts +1 -0
- package/components/TS_MultiSelect/index.js +21 -0
- package/components/TS_Notifications/TS_Notifications.d.ts +22 -0
- package/components/TS_Notifications/TS_Notifications.js +96 -0
- package/components/TS_Notifications/TS_Notifications.scss +120 -0
- package/components/TS_Notifications/genericNotificationAction.d.ts +8 -0
- package/components/TS_Notifications/genericNotificationAction.js +16 -0
- package/components/TS_Notifications/index.d.ts +2 -0
- package/components/TS_Notifications/index.js +2 -0
- package/components/TS_Overlay/TS_Overlay.d.ts +12 -0
- package/components/TS_Overlay/TS_Overlay.js +32 -0
- package/components/TS_Overlay/TS_Overlay.scss +41 -0
- package/components/TS_Overlay/index.d.ts +1 -0
- package/components/TS_Overlay/index.js +21 -0
- package/components/TS_Printable/TS_Printable.d.ts +13 -0
- package/components/TS_Printable/TS_Printable.js +20 -0
- package/components/TS_Printable/TS_Printable.scss +47 -0
- package/components/TS_Printable/index.d.ts +1 -0
- package/components/TS_Printable/index.js +21 -0
- package/components/TS_ProgressBar/TS_ProgressBar.d.ts +22 -0
- package/components/TS_ProgressBar/TS_ProgressBar.js +47 -0
- package/components/TS_ProgressBar/TS_ProgressBar.scss +79 -0
- package/components/TS_ProgressBar/index.d.ts +1 -0
- package/components/TS_ProgressBar/index.js +1 -0
- package/components/TS_PropRenderer/TS_PropRenderer.d.ts +18 -0
- package/components/TS_PropRenderer/TS_PropRenderer.js +36 -0
- package/components/TS_PropRenderer/TS_PropRenderer.scss +19 -0
- package/components/TS_PropRenderer/index.d.ts +1 -0
- package/components/TS_PropRenderer/index.js +1 -0
- package/components/TS_Radio/TS_Radio.d.ts +34 -0
- package/components/TS_Radio/TS_Radio.js +49 -0
- package/components/TS_Radio/TS_Radio.scss +68 -0
- package/components/TS_Radio/index.d.ts +1 -0
- package/components/TS_Radio/index.js +1 -0
- package/components/TS_ReadMore/TS_ReadMore.d.ts +26 -0
- package/components/TS_ReadMore/TS_ReadMore.js +86 -0
- package/components/TS_ReadMore/TS_ReadMore.scss +36 -0
- package/components/TS_ReadMore/index.d.ts +1 -0
- package/components/TS_ReadMore/index.js +1 -0
- package/components/TS_Slider/TS_Slider.d.ts +26 -0
- package/components/TS_Slider/TS_Slider.js +42 -0
- package/components/TS_Slider/TS_Slider.scss +68 -0
- package/components/TS_Slider/index.d.ts +1 -0
- package/components/TS_Slider/index.js +1 -0
- package/components/TS_Space/TS_Space.d.ts +8 -0
- package/components/TS_Space/TS_Space.js +8 -0
- package/components/TS_Space/index.d.ts +1 -0
- package/components/TS_Space/index.js +1 -0
- package/components/TS_Space/ts-space.scss +3 -0
- package/components/TS_Table/TS_Table.d.ts +42 -0
- package/components/TS_Table/TS_Table.js +74 -0
- package/components/TS_Table/TS_Table.scss +51 -0
- package/components/TS_Table/index.d.ts +1 -0
- package/components/TS_Table/index.js +21 -0
- package/components/TS_Tabs/TS_Tabs.d.ts +55 -0
- package/components/TS_Tabs/TS_Tabs.js +102 -0
- package/components/TS_Tabs/TS_Tabs.scss +103 -0
- package/components/TS_Tabs/index.d.ts +1 -0
- package/components/TS_Tabs/index.js +21 -0
- package/components/TS_Toaster/TS_Toast.d.ts +5 -0
- package/components/TS_Toaster/TS_Toast.js +9 -0
- package/components/TS_Toaster/TS_Toast.scss +80 -0
- package/components/TS_Toaster/TS_ToastOverlay.d.ts +16 -0
- package/components/TS_Toaster/TS_ToastOverlay.js +26 -0
- package/components/TS_Toaster/TS_ToastOverlay.scss +33 -0
- package/components/TS_Toaster/index.d.ts +2 -0
- package/components/TS_Toaster/index.js +22 -0
- package/components/TS_Toggle/ATS_Toggle.d.ts +11 -0
- package/components/TS_Toggle/ATS_Toggle.js +18 -0
- package/components/TS_Toggle/TS_Toggle.d.ts +21 -0
- package/components/TS_Toggle/TS_Toggle.js +26 -0
- package/components/TS_Toggle/TS_Toggle.scss +56 -0
- package/components/TS_Toggle/index.d.ts +2 -0
- package/components/TS_Toggle/index.js +2 -0
- package/components/TS_Toggler/TS_Toggler.d.ts +23 -0
- package/components/TS_Toggler/TS_Toggler.js +50 -0
- package/components/TS_Toggler/TS_Toggler.scss +83 -0
- package/components/TS_Toggler/index.d.ts +1 -0
- package/components/TS_Toggler/index.js +1 -0
- package/components/TS_Tree/SimpleTreeNodeRenderer.d.ts +9 -0
- package/components/TS_Tree/SimpleTreeNodeRenderer.js +53 -0
- package/components/TS_Tree/TS_Tree.d.ts +68 -0
- package/components/TS_Tree/TS_Tree.js +174 -0
- package/components/TS_Tree/TS_Tree.scss +44 -0
- package/components/TS_Tree/index.d.ts +3 -0
- package/components/TS_Tree/index.js +23 -0
- package/components/TS_Tree/types.d.ts +4 -0
- package/components/TS_Tree/types.js +21 -0
- package/components/TS_V2_Input/TS_InputV2.d.ts +93 -0
- package/components/TS_V2_Input/TS_InputV2.js +220 -0
- package/components/TS_V2_Input/index.d.ts +1 -0
- package/components/TS_V2_Input/index.js +21 -0
- package/components/TS_V2_TextArea/TS_BaseInput.d.ts +42 -0
- package/components/TS_V2_TextArea/TS_BaseInput.js +46 -0
- package/components/TS_V2_TextArea/TS_TextAreaV2.d.ts +78 -0
- package/components/TS_V2_TextArea/TS_TextAreaV2.js +178 -0
- package/components/TS_V2_TextArea/TS_TextAreaV2.scss +49 -0
- package/components/TS_V2_TextArea/index.d.ts +2 -0
- package/components/TS_V2_TextArea/index.js +22 -0
- package/components/TS_VirtualizedList/TS_VirtualizedList.d.ts +14 -0
- package/components/TS_VirtualizedList/TS_VirtualizedList.js +22 -0
- package/components/TS_VirtualizedList/index.d.ts +1 -0
- package/components/TS_VirtualizedList/index.js +1 -0
- package/components/Video/Video.d.ts +16 -0
- package/components/Video/Video.js +40 -0
- package/components/Video/VideoDialog.d.ts +20 -0
- package/components/Video/VideoDialog.js +44 -0
- package/components/Video/VideoDialog.scss +31 -0
- package/components/Video/types.d.ts +20 -0
- package/components/Video/types.js +1 -0
- package/components/_TS_MultiSelect/DBItemDropDownMultiSelector.d.ts +57 -0
- package/components/_TS_MultiSelect/DBItemDropDownMultiSelector.js +63 -0
- package/components/adapter/Adapter.d.ts +139 -0
- package/components/adapter/Adapter.js +259 -0
- package/components/adapter/BaseRenderer.d.ts +24 -0
- package/components/adapter/BaseRenderer.js +31 -0
- package/components/ats-group.d.ts +2 -0
- package/components/ats-group.js +14 -0
- package/components/form/Form.d.ts +24 -0
- package/components/form/Form.js +34 -0
- package/components/form/types.d.ts +23 -0
- package/components/form/types.js +21 -0
- package/components/formv3/FormV3.d.ts +25 -0
- package/components/formv3/FormV3.js +23 -0
- package/components/formv3/types.d.ts +29 -0
- package/components/formv3/types.js +1 -0
- package/components/treeicons.d.ts +10 -0
- package/components/treeicons.js +3 -0
- package/components/types.d.ts +23 -0
- package/components/types.js +22 -0
- package/components/utils.d.ts +1 -0
- package/components/utils.js +7 -0
- package/consts.d.ts +2 -0
- package/consts.js +2 -0
- package/core/AppPage.d.ts +11 -0
- package/core/AppPage.js +52 -0
- package/core/AppPageV2.d.ts +9 -0
- package/core/AppPageV2.js +53 -0
- package/core/AppWrapper.d.ts +4 -0
- package/core/AppWrapper.js +34 -0
- package/core/ComponentAsync.d.ts +16 -0
- package/core/ComponentAsync.js +64 -0
- package/core/ComponentBase.d.ts +28 -0
- package/core/ComponentBase.js +152 -0
- package/core/ComponentSync.d.ts +13 -0
- package/core/ComponentSync.js +49 -0
- package/core/Controller.d.ts +13 -0
- package/core/Controller.js +28 -0
- package/core/IndexedDB.d.ts +42 -0
- package/core/IndexedDB.js +259 -0
- package/core/IndexedDBV3.d.ts +43 -0
- package/core/IndexedDBV3.js +259 -0
- package/core/IndexedDBV4/IndexedDB_Database.d.ts +20 -0
- package/core/IndexedDBV4/IndexedDB_Database.js +268 -0
- package/core/IndexedDBV4/IndexedDB_Store.d.ts +34 -0
- package/core/IndexedDBV4/IndexedDB_Store.js +207 -0
- package/core/IndexedDBV4/ModuleFE_IDBManager.d.ts +11 -0
- package/core/IndexedDBV4/ModuleFE_IDBManager.js +19 -0
- package/core/IndexedDBV4/types.d.ts +16 -0
- package/core/IndexedDBV4/types.js +1 -0
- package/core/SimpleScriptInjector.d.ts +13 -0
- package/core/SimpleScriptInjector.js +42 -0
- package/core/Thunder.d.ts +37 -0
- package/core/Thunder.js +139 -0
- package/core/ThunderstormDefaultApp.d.ts +12 -0
- package/core/ThunderstormDefaultApp.js +29 -0
- package/core/consts.d.ts +6 -0
- package/core/consts.js +2 -0
- package/core/db-api-gen/consts.d.ts +22 -0
- package/core/db-api-gen/consts.js +25 -0
- package/core/db-api-gen/db-def.d.ts +9 -0
- package/core/db-api-gen/db-def.js +16 -0
- package/core/db-api-gen/types.d.ts +23 -0
- package/core/db-api-gen/types.js +3 -0
- package/core/proto-component/ProtoComponent.d.ts +57 -0
- package/core/proto-component/ProtoComponent.js +73 -0
- package/core/proto-component/UrlState.d.ts +42 -0
- package/core/proto-component/UrlState.js +59 -0
- package/core/proto-component/index.d.ts +2 -0
- package/core/proto-component/index.js +2 -0
- package/core/proto-component/types.d.ts +25 -0
- package/core/proto-component/types.js +15 -0
- package/core/thunder-dispatcher.d.ts +13 -0
- package/core/thunder-dispatcher.js +69 -0
- package/core/thunder-helpers.d.ts +7 -0
- package/core/thunder-helpers.js +171 -0
- package/core/thunder-modulepack.d.ts +3 -0
- package/core/thunder-modulepack.js +34 -0
- package/core/typed-api.d.ts +6 -0
- package/core/typed-api.js +41 -0
- package/core/types.d.ts +6 -0
- package/core/types.js +1 -0
- package/editable-item.d.ts +7 -0
- package/editable-item.js +7 -0
- package/index.d.ts +112 -0
- package/index.js +134 -0
- package/modules/ModuleFE_BaseTheme.d.ts +18 -0
- package/modules/ModuleFE_BaseTheme.js +27 -0
- package/modules/ModuleFE_BroadcastChannel/ModuleFE_BroadcastChannel.d.ts +20 -0
- package/modules/ModuleFE_BroadcastChannel/ModuleFE_BroadcastChannel.js +66 -0
- package/modules/ModuleFE_BrowserHistory.d.ts +46 -0
- package/modules/ModuleFE_BrowserHistory.js +165 -0
- package/modules/ModuleFE_BrowserHistoryV2.d.ts +43 -0
- package/modules/ModuleFE_BrowserHistoryV2.js +113 -0
- package/modules/ModuleFE_CSVParser.d.ts +12 -0
- package/modules/ModuleFE_CSVParser.js +52 -0
- package/modules/ModuleFE_CollectionActions.d.ts +10 -0
- package/modules/ModuleFE_CollectionActions.js +18 -0
- package/modules/ModuleFE_ConnectivityModule.d.ts +15 -0
- package/modules/ModuleFE_ConnectivityModule.js +31 -0
- package/modules/ModuleFE_ForceUpgrade.d.ts +20 -0
- package/modules/ModuleFE_ForceUpgrade.js +54 -0
- package/modules/ModuleFE_LocalStorage.d.ts +46 -0
- package/modules/ModuleFE_LocalStorage.js +179 -0
- package/modules/ModuleFE_Locale.d.ts +44 -0
- package/modules/ModuleFE_Locale.js +83 -0
- package/modules/ModuleFE_Print.d.ts +16 -0
- package/modules/ModuleFE_Print.js +116 -0
- package/modules/ModuleFE_StorageCleaner.d.ts +17 -0
- package/modules/ModuleFE_StorageCleaner.js +90 -0
- package/modules/ModuleFE_Thunderstorm.d.ts +31 -0
- package/modules/ModuleFE_Thunderstorm.js +122 -0
- package/modules/ModuleFE_Utils/ModuleFE_Utils.d.ts +29 -0
- package/modules/ModuleFE_Utils/ModuleFE_Utils.js +43 -0
- package/modules/ModuleFE_Window.d.ts +19 -0
- package/modules/ModuleFE_Window.js +42 -0
- package/modules/ModuleFE_WindowMessenger.d.ts +62 -0
- package/modules/ModuleFE_WindowMessenger.js +128 -0
- package/modules/action-processor/ModuleFE_ActionProcessor.d.ts +9 -0
- package/modules/action-processor/ModuleFE_ActionProcessor.js +14 -0
- package/modules/archiving/ModuleFE_Archiving.d.ts +8 -0
- package/modules/archiving/ModuleFE_Archiving.js +15 -0
- package/modules/clearWebsiteDataDispatcher.d.ts +5 -0
- package/modules/clearWebsiteDataDispatcher.js +2 -0
- package/modules/component-loader/ReactEntryComponentInjector.d.ts +23 -0
- package/modules/component-loader/ReactEntryComponentInjector.js +59 -0
- package/modules/component-loader/entry-component-loading-module.d.ts +7 -0
- package/modules/component-loader/entry-component-loading-module.js +52 -0
- package/modules/component-loader/index.d.ts +2 -0
- package/modules/component-loader/index.js +2 -0
- package/modules/db-api-gen/ModuleFE_BaseApi.d.ts +45 -0
- package/modules/db-api-gen/ModuleFE_BaseApi.js +152 -0
- package/modules/db-api-gen/ModuleFE_BaseDB.d.ts +146 -0
- package/modules/db-api-gen/ModuleFE_BaseDB.js +433 -0
- package/modules/db-api-gen/types.d.ts +13 -0
- package/modules/db-api-gen/types.js +6 -0
- package/modules/http/ModuleFE_XHR.d.ts +20 -0
- package/modules/http/ModuleFE_XHR.js +175 -0
- package/modules/routing/LocationChangeListener.d.ts +6 -0
- package/modules/routing/LocationChangeListener.js +15 -0
- package/modules/routing/ModuleFE_Routing.d.ts +30 -0
- package/modules/routing/ModuleFE_Routing.js +122 -0
- package/modules/routing/ModuleFE_RoutingV2.d.ts +25 -0
- package/modules/routing/ModuleFE_RoutingV2.js +143 -0
- package/modules/routing/index.d.ts +5 -0
- package/modules/routing/index.js +5 -0
- package/modules/routing/route.d.ts +22 -0
- package/modules/routing/route.js +83 -0
- package/modules/routing/types.d.ts +20 -0
- package/modules/routing/types.js +1 -0
- package/modules/sync-env/ModuleFE_SyncEnvV2.d.ts +8 -0
- package/modules/sync-env/ModuleFE_SyncEnvV2.js +18 -0
- package/modules/sync-manager/ModuleFE_SyncManager.d.ts +59 -0
- package/modules/sync-manager/ModuleFE_SyncManager.js +378 -0
- package/modules/sync-manager/ModuleFE_SyncManager_CSV.d.ts +11 -0
- package/modules/sync-manager/ModuleFE_SyncManager_CSV.js +121 -0
- package/package.json +107 -0
- package/server-info/Button_VersionUpdate.d.ts +15 -0
- package/server-info/Button_VersionUpdate.js +29 -0
- package/server-info/Button_VersionUpdate.scss +29 -0
- package/server-info/ModuleFE_ServerInfo.d.ts +26 -0
- package/server-info/ModuleFE_ServerInfo.js +73 -0
- package/server-info/index.d.ts +2 -0
- package/server-info/index.js +2 -0
- package/shared.d.ts +1 -0
- package/shared.js +21 -0
- package/styles/declaration/basic.scss +155 -0
- package/styles/declaration/mixins.scss +58 -0
- package/styles/impl/basic.scss +141 -0
- package/styles/impl/icons.scss +34 -0
- package/styles.scss +40 -0
- package/utils/EditableItem.d.ts +240 -0
- package/utils/EditableItem.js +552 -0
- package/utils/console/LogClient_ConsoleInterceptor.d.ts +5 -0
- package/utils/console/LogClient_ConsoleInterceptor.js +70 -0
- package/utils/perform-action/genereteToasts.d.ts +3 -0
- package/utils/perform-action/genereteToasts.js +14 -0
- package/utils/perform-action/index.d.ts +2 -0
- package/utils/perform-action/index.js +2 -0
- package/utils/perform-action/notification-dispatchers.d.ts +6 -0
- package/utils/perform-action/notification-dispatchers.js +2 -0
- package/utils/perform-action/performAction.d.ts +34 -0
- package/utils/perform-action/performAction.js +77 -0
- package/utils/perform-action/resolve-dependency-toast/ResolveDependencyToast.d.ts +8 -0
- package/utils/perform-action/resolve-dependency-toast/ResolveDependencyToast.js +11 -0
- package/utils/perform-action/resolve-dependency-toast/ResolveDependencyToast.scss +12 -0
- package/utils/tools.d.ts +31 -0
- package/utils/tools.js +138 -0
- package/utils/types.d.ts +3 -0
- package/utils/types.js +1 -0
- package/widgets/FieldEditor.d.ts +29 -0
- package/widgets/FieldEditor.js +47 -0
- package/widgets/FieldEditorClick.d.ts +33 -0
- package/widgets/FieldEditorClick.js +49 -0
- package/widgets/FieldEditorWithButtons.d.ts +32 -0
- package/widgets/FieldEditorWithButtons.js +42 -0
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { Module, RouteParams } from '@nu-art/ts-common';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
import { RoutePath } from './route.js';
|
|
4
|
+
import { QueryParams } from '@nu-art/thunderstorm-shared';
|
|
5
|
+
declare class ModuleFE_Routing_Class extends Module<{}> {
|
|
6
|
+
private readonly routes;
|
|
7
|
+
private readonly ordinalRoutes;
|
|
8
|
+
private readonly createNavLinkNode;
|
|
9
|
+
private readonly createRouteNode;
|
|
10
|
+
private readonly createLinkNode;
|
|
11
|
+
constructor();
|
|
12
|
+
init(): void;
|
|
13
|
+
clearRoutes(): void;
|
|
14
|
+
addRoute(key: string, route: string, component: React.ComponentClass<any, any> | string): RoutePath;
|
|
15
|
+
getRoute(key: string): RoutePath;
|
|
16
|
+
getPath(key: string): string;
|
|
17
|
+
goToRoute(key: string, params?: RouteParams): void;
|
|
18
|
+
redirect(key: string): import("react/jsx-runtime").JSX.Element;
|
|
19
|
+
getMyRouteKey: () => string | undefined;
|
|
20
|
+
getNavLinks(keys: string[]): React.ReactElement<any, string | React.JSXElementConstructor<any>>[];
|
|
21
|
+
getNavLink(key: string): React.ReactElement<any, string | React.JSXElementConstructor<any>>;
|
|
22
|
+
getLink(key: string): React.ReactElement<any, string | React.JSXElementConstructor<any>>;
|
|
23
|
+
getRoutesMap(keys?: string[]): import("react/jsx-runtime").JSX.Element;
|
|
24
|
+
getCurrentUrl: () => string;
|
|
25
|
+
private getEncodedQueryParams;
|
|
26
|
+
getSearch(): QueryParams;
|
|
27
|
+
goToUrl: (url: string) => string;
|
|
28
|
+
}
|
|
29
|
+
export declare const ModuleFE_Routing: ModuleFE_Routing_Class;
|
|
30
|
+
export {};
|
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
/*
|
|
3
|
+
* Thunderstorm is a full web app framework!
|
|
4
|
+
*
|
|
5
|
+
* Typescript & Express backend infrastructure that natively runs on firebase function
|
|
6
|
+
* Typescript & React frontend infrastructure
|
|
7
|
+
*
|
|
8
|
+
* Copyright (C) 2020 Adam van der Kruk aka TacB0sS
|
|
9
|
+
*
|
|
10
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
11
|
+
* you may not use this file except in compliance with the License.
|
|
12
|
+
* You may obtain a copy of the License at
|
|
13
|
+
*
|
|
14
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
15
|
+
*
|
|
16
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
17
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
18
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
19
|
+
* See the License for the specific language governing permissions and
|
|
20
|
+
* limitations under the License.
|
|
21
|
+
*/
|
|
22
|
+
import { _keys, addItemToArray, BadImplementationException, composeQueryParams, Module } from '@nu-art/ts-common';
|
|
23
|
+
import { defaultLinkNode, defaultNavLinkNode, defaultRouteNode, RoutePath } from './route.js';
|
|
24
|
+
import { ModuleFE_BrowserHistory } from '../ModuleFE_BrowserHistory.js';
|
|
25
|
+
import { Navigate, Routes } from 'react-router-dom';
|
|
26
|
+
class ModuleFE_Routing_Class extends Module {
|
|
27
|
+
routes = {};
|
|
28
|
+
ordinalRoutes = [];
|
|
29
|
+
createNavLinkNode;
|
|
30
|
+
createRouteNode;
|
|
31
|
+
createLinkNode;
|
|
32
|
+
constructor() {
|
|
33
|
+
super();
|
|
34
|
+
this.createNavLinkNode = defaultNavLinkNode;
|
|
35
|
+
this.createLinkNode = defaultLinkNode;
|
|
36
|
+
this.createRouteNode = defaultRouteNode;
|
|
37
|
+
}
|
|
38
|
+
init() {
|
|
39
|
+
}
|
|
40
|
+
clearRoutes() {
|
|
41
|
+
for (const item of this.ordinalRoutes) {
|
|
42
|
+
delete this.routes[item];
|
|
43
|
+
}
|
|
44
|
+
this.ordinalRoutes.splice(0);
|
|
45
|
+
}
|
|
46
|
+
addRoute(key, route, component) {
|
|
47
|
+
const previousRoute = this.routes[key];
|
|
48
|
+
if (previousRoute)
|
|
49
|
+
throw new BadImplementationException(`Route key '${key}' MUST be unique!!\n Found two routes with matching key: '${route}' && '${previousRoute.path}'`);
|
|
50
|
+
addItemToArray(this.ordinalRoutes, key);
|
|
51
|
+
return this.routes[key] = new RoutePath(key, route, component);
|
|
52
|
+
}
|
|
53
|
+
getRoute(key) {
|
|
54
|
+
const route = this.routes[key];
|
|
55
|
+
if (!route)
|
|
56
|
+
throw new BadImplementationException(`No Route for key '${key}'... Did you forget to add it??`);
|
|
57
|
+
return route;
|
|
58
|
+
}
|
|
59
|
+
getPath(key) {
|
|
60
|
+
return this.getRoute(key).path;
|
|
61
|
+
}
|
|
62
|
+
goToRoute(key, params) {
|
|
63
|
+
const pathname = this.getPath(key);
|
|
64
|
+
const search = composeQueryParams(params);
|
|
65
|
+
ModuleFE_BrowserHistory.push({ pathname, search });
|
|
66
|
+
}
|
|
67
|
+
redirect(key) {
|
|
68
|
+
return _jsx(Navigate, { to: ModuleFE_Routing.getPath(key) });
|
|
69
|
+
}
|
|
70
|
+
getMyRouteKey = () => Object.keys(this.routes).find(key => this.routes[key].path === ModuleFE_BrowserHistory.getCurrent().pathname);
|
|
71
|
+
// need to figure out how to create parameterized urls from this call !!
|
|
72
|
+
getNavLinks(keys) {
|
|
73
|
+
return keys.map(key => this.getRoute(key)).filter(route => route.visible && route.visible()).map(route => this.createNavLinkNode(route));
|
|
74
|
+
}
|
|
75
|
+
getNavLink(key) {
|
|
76
|
+
return this.createNavLinkNode(this.getRoute(key));
|
|
77
|
+
}
|
|
78
|
+
getLink(key) {
|
|
79
|
+
return this.createLinkNode(this.getRoute(key));
|
|
80
|
+
}
|
|
81
|
+
getRoutesMap(keys) {
|
|
82
|
+
return _jsx(Routes, { children: (keys || this.ordinalRoutes).map(key => this.createRouteNode(this.getRoute(key))) });
|
|
83
|
+
}
|
|
84
|
+
getCurrentUrl = () => window.location.href;
|
|
85
|
+
getEncodedQueryParams = () => {
|
|
86
|
+
const queryParams = {};
|
|
87
|
+
let queryAsString = window.location.search;
|
|
88
|
+
if (!queryAsString || queryAsString.length === 0)
|
|
89
|
+
return {};
|
|
90
|
+
while (queryAsString.startsWith('?') || queryAsString.startsWith('/?')) {
|
|
91
|
+
if (queryAsString.startsWith('?'))
|
|
92
|
+
queryAsString = queryAsString.substring(1);
|
|
93
|
+
else if (queryAsString.startsWith('/?'))
|
|
94
|
+
queryAsString = queryAsString.substring(2);
|
|
95
|
+
else
|
|
96
|
+
break;
|
|
97
|
+
}
|
|
98
|
+
const query = queryAsString.split('&');
|
|
99
|
+
return query.map(param => {
|
|
100
|
+
const parts = param.split('=');
|
|
101
|
+
return { key: parts[0], value: parts[1] };
|
|
102
|
+
}).reduce((toRet, param) => {
|
|
103
|
+
if (param.key && param.value)
|
|
104
|
+
toRet[param.key] = param.value;
|
|
105
|
+
return toRet;
|
|
106
|
+
}, queryParams);
|
|
107
|
+
};
|
|
108
|
+
getSearch() {
|
|
109
|
+
const params = this.getEncodedQueryParams();
|
|
110
|
+
_keys(params).forEach(key => {
|
|
111
|
+
const value = `${params[key]}`;
|
|
112
|
+
if (!value) {
|
|
113
|
+
delete params[key];
|
|
114
|
+
return;
|
|
115
|
+
}
|
|
116
|
+
params[key] = decodeURIComponent(value);
|
|
117
|
+
});
|
|
118
|
+
return params;
|
|
119
|
+
}
|
|
120
|
+
goToUrl = (url) => window.location.href = url;
|
|
121
|
+
}
|
|
122
|
+
export const ModuleFE_Routing = new ModuleFE_Routing_Class();
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { NavigateFunction, NavLinkProps } from 'react-router-dom';
|
|
2
|
+
import { TS_Route } from './types.js';
|
|
3
|
+
import { Module } from '@nu-art/ts-common';
|
|
4
|
+
import { QueryParams } from '@nu-art/thunderstorm-shared';
|
|
5
|
+
declare class ModuleFE_RoutingV2_Class extends Module<{}> {
|
|
6
|
+
private routesMapByKey;
|
|
7
|
+
private routesMapByPath;
|
|
8
|
+
private navigate;
|
|
9
|
+
goToRoute<P extends QueryParams>(route: TS_Route<P>, params?: Partial<P>): void;
|
|
10
|
+
redirect<P extends QueryParams>(route: TS_Route<P>, params?: Partial<P>): import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
generateRoutes(rootRoute: TS_Route): import("react/jsx-runtime").JSX.Element;
|
|
12
|
+
buildRouteMap(route: TS_Route, _path?: string): void;
|
|
13
|
+
private routeBuilder;
|
|
14
|
+
private resolveRouteComponent;
|
|
15
|
+
getRouteByKey(routeKey: string): TS_Route | undefined;
|
|
16
|
+
getFullPath(routeKey: string): string;
|
|
17
|
+
getCurrentRouteKey(): TS_Route;
|
|
18
|
+
setNavigate(navigate: NavigateFunction): void;
|
|
19
|
+
}
|
|
20
|
+
export declare const TS_NavLink: (props: {
|
|
21
|
+
route: TS_Route;
|
|
22
|
+
ignoreClickOnSameRoute?: boolean;
|
|
23
|
+
} & Partial<NavLinkProps>) => import("react/jsx-runtime").JSX.Element;
|
|
24
|
+
export declare const ModuleFE_RoutingV2: ModuleFE_RoutingV2_Class;
|
|
25
|
+
export {};
|
|
@@ -0,0 +1,143 @@
|
|
|
1
|
+
import { createElement as _createElement } from "react";
|
|
2
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
3
|
+
import { BrowserRouter, Navigate, NavLink, Route, Routes } from 'react-router-dom';
|
|
4
|
+
import { BadImplementationException, composeUrl, Module, removeItemFromArray } from '@nu-art/ts-common';
|
|
5
|
+
import { LocationChangeListener } from './LocationChangeListener.js';
|
|
6
|
+
import { mouseEventHandler, stopPropagation } from '../../utils/tools.js';
|
|
7
|
+
import { AwaitModules } from '../../components/AwaitModules/AwaitModules.js';
|
|
8
|
+
import { AwaitSync } from '../../components/AwaitSync/AwaitSync.js';
|
|
9
|
+
class ModuleFE_RoutingV2_Class extends Module {
|
|
10
|
+
// ######################## Inner Data ########################
|
|
11
|
+
routesMapByKey = {};
|
|
12
|
+
routesMapByPath = {};
|
|
13
|
+
navigate;
|
|
14
|
+
// ######################## Public Functions ########################
|
|
15
|
+
goToRoute(route, params) {
|
|
16
|
+
const fullPath = this.getFullPath(route.key);
|
|
17
|
+
try {
|
|
18
|
+
const url = composeUrl(fullPath, params, window.location.hash);
|
|
19
|
+
if (window.location.href === url)
|
|
20
|
+
return this.logWarning(`attempting to set same route: ${url}`);
|
|
21
|
+
this.navigate(url);
|
|
22
|
+
}
|
|
23
|
+
catch (e) {
|
|
24
|
+
this.logError(`cannot resolve route for route: `, route, e);
|
|
25
|
+
throw e;
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
redirect(route, params) {
|
|
29
|
+
const url = composeUrl(this.getFullPath(route.key), params);
|
|
30
|
+
return _jsx(Navigate, { to: url });
|
|
31
|
+
}
|
|
32
|
+
generateRoutes(rootRoute) {
|
|
33
|
+
// This needs to be a component in order to be build the routes on rendering after modules are awaited
|
|
34
|
+
this.buildRouteMap(rootRoute);
|
|
35
|
+
const RoutesRenderer = () => _jsx(Routes, { children: this.routeBuilder(rootRoute) });
|
|
36
|
+
return _jsxs(BrowserRouter, { children: [_jsx(LocationChangeListener, {}), _jsx(RoutesRenderer, {})] });
|
|
37
|
+
}
|
|
38
|
+
buildRouteMap(route, _path = '') {
|
|
39
|
+
const path = `${_path}/`;
|
|
40
|
+
this.routesMapByKey[route.key] = { route, fullPath: _path };
|
|
41
|
+
this.routesMapByPath[_path] = route;
|
|
42
|
+
route.children?.map(route => this.buildRouteMap(route, `${path}${route.path}`));
|
|
43
|
+
}
|
|
44
|
+
routeBuilder = (route) => {
|
|
45
|
+
this.logDebug(`building route for: ${route.key}`);
|
|
46
|
+
const path = this.routesMapByKey[route.key].fullPath;
|
|
47
|
+
const routes = route.children || [];
|
|
48
|
+
const indicesRoutes = routes?.filter(route => route.index);
|
|
49
|
+
if (indicesRoutes && indicesRoutes.length > 1)
|
|
50
|
+
throw new BadImplementationException(`more than one index route found in ${path}: ${indicesRoutes.map(r => r.key).join(', ')}`);
|
|
51
|
+
const indexRoute = indicesRoutes?.[0];
|
|
52
|
+
let _indexRoute;
|
|
53
|
+
if (indexRoute) {
|
|
54
|
+
const Component = this.resolveRouteComponent(indexRoute);
|
|
55
|
+
if (indexRoute.path) {
|
|
56
|
+
this.logDebug(`index route redirect to path: ${path}/${indexRoute.path}`);
|
|
57
|
+
// force redirect to a different route
|
|
58
|
+
_indexRoute = _jsx(Route, { index: true, element: _jsx(Navigate, { to: `${path}/${indexRoute.path}` }) });
|
|
59
|
+
}
|
|
60
|
+
else {
|
|
61
|
+
// default index route renderer
|
|
62
|
+
this.logDebug(`index route render component: ${path}/${indexRoute.path}`);
|
|
63
|
+
_indexRoute = _jsx(Route, { index: true, Component: Component, element: indexRoute.element });
|
|
64
|
+
removeItemFromArray(routes, indexRoute);
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
if (route.fallback)
|
|
68
|
+
this.logDebug(`fallback: ${path}`);
|
|
69
|
+
const children = route.children?.filter(route => {
|
|
70
|
+
return route.enabled?.() ?? true;
|
|
71
|
+
}) ?? [];
|
|
72
|
+
const Component = this.resolveRouteComponent(route);
|
|
73
|
+
return _jsxs(Route, { path: route.path, Component: Component, element: route.element, children: [_indexRoute, children.map(route => this.routeBuilder(route))] }, route.key);
|
|
74
|
+
};
|
|
75
|
+
resolveRouteComponent = (route) => {
|
|
76
|
+
if (!route.Component)
|
|
77
|
+
return undefined;
|
|
78
|
+
const shouldAwaitModules = !!route.modulesToAwait;
|
|
79
|
+
const shouldAwaitSync = !!route.awaitSync;
|
|
80
|
+
//No awaiting of any type
|
|
81
|
+
if (!shouldAwaitModules && !shouldAwaitSync)
|
|
82
|
+
return route.Component;
|
|
83
|
+
//Awaiting both modules and sync
|
|
84
|
+
if (shouldAwaitModules && shouldAwaitSync) {
|
|
85
|
+
if (route.Component.prototype?.render) {
|
|
86
|
+
const Component = route.Component;
|
|
87
|
+
return () => _jsx(AwaitSync, { customLoader: route.awaitSyncLoader, children: _jsx(AwaitModules, { modules: route.modulesToAwait, customLoader: route.awaitModulesLoader, children: _jsx(Component, {}) }) });
|
|
88
|
+
}
|
|
89
|
+
const component = route.Component;
|
|
90
|
+
return () => _jsx(AwaitSync, { customLoader: route.awaitSyncLoader, children: _jsx(AwaitModules, { modules: route.modulesToAwait, customLoader: route.awaitModulesLoader, children: component({}) }) });
|
|
91
|
+
}
|
|
92
|
+
//Awaiting only modules
|
|
93
|
+
if (shouldAwaitModules && !shouldAwaitSync) {
|
|
94
|
+
//route.Component is a class component
|
|
95
|
+
if (route.Component.prototype?.render) {
|
|
96
|
+
const Component = route.Component;
|
|
97
|
+
return () => _jsx(AwaitModules, { modules: route.modulesToAwait, customLoader: route.awaitModulesLoader, children: _jsx(Component, {}) });
|
|
98
|
+
}
|
|
99
|
+
//route.Component is a function component
|
|
100
|
+
const component = route.Component;
|
|
101
|
+
return () => _jsx(AwaitModules, { modules: route.modulesToAwait, customLoader: route.awaitModulesLoader, children: component({}) });
|
|
102
|
+
}
|
|
103
|
+
//Awaiting only sync
|
|
104
|
+
if (shouldAwaitModules && !shouldAwaitSync) {
|
|
105
|
+
if (route.Component.prototype.render) {
|
|
106
|
+
const Component = route.Component;
|
|
107
|
+
return () => _jsx(AwaitSync, { customLoader: route.awaitSyncLoader, children: _jsx(Component, {}) });
|
|
108
|
+
}
|
|
109
|
+
//route.Component is a function component
|
|
110
|
+
const component = route.Component;
|
|
111
|
+
return () => _jsx(AwaitSync, { customLoader: route.awaitSyncLoader, children: component({}) });
|
|
112
|
+
}
|
|
113
|
+
};
|
|
114
|
+
getRouteByKey(routeKey) {
|
|
115
|
+
return this.routesMapByKey[routeKey]?.route;
|
|
116
|
+
}
|
|
117
|
+
getFullPath(routeKey) {
|
|
118
|
+
const route = this.routesMapByKey[routeKey];
|
|
119
|
+
if (!route)
|
|
120
|
+
throw new BadImplementationException(`Cannot find full path for route key: ${routeKey}`);
|
|
121
|
+
return route.fullPath;
|
|
122
|
+
}
|
|
123
|
+
getCurrentRouteKey() {
|
|
124
|
+
return this.routesMapByPath[window.location.pathname];
|
|
125
|
+
}
|
|
126
|
+
setNavigate(navigate) {
|
|
127
|
+
this.navigate = navigate;
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
export const TS_NavLink = (props) => {
|
|
131
|
+
const { route, children, ignoreClickOnSameRoute, ..._props } = props;
|
|
132
|
+
const fullPath = ModuleFE_RoutingV2.getFullPath(route.key);
|
|
133
|
+
if (!fullPath)
|
|
134
|
+
throw new BadImplementationException(`Route with key ${route.key} is not defined in routing module`);
|
|
135
|
+
return _createElement(NavLink, { ..._props, to: fullPath, key: route.key, onClick: e => {
|
|
136
|
+
const pathname = window.location.pathname;
|
|
137
|
+
if (props.ignoreClickOnSameRoute && pathname === fullPath)
|
|
138
|
+
stopPropagation(e);
|
|
139
|
+
}, onMouseUp: e => mouseEventHandler(e, {
|
|
140
|
+
middle: () => window.open(fullPath, '_blank'),
|
|
141
|
+
}) }, children);
|
|
142
|
+
};
|
|
143
|
+
export const ModuleFE_RoutingV2 = new ModuleFE_RoutingV2_Class();
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { RouteParams } from '@nu-art/ts-common';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
export declare class RoutePath {
|
|
4
|
+
key: string;
|
|
5
|
+
path: string;
|
|
6
|
+
exact: boolean;
|
|
7
|
+
component: React.ComponentClass | string;
|
|
8
|
+
logMessage?: string;
|
|
9
|
+
label?: React.ElementType | string;
|
|
10
|
+
visible: () => boolean;
|
|
11
|
+
enabled?: () => boolean;
|
|
12
|
+
constructor(key: string, route: string, component: React.ComponentClass | string);
|
|
13
|
+
setLogMessage(logMessage: string): this;
|
|
14
|
+
setLabel(label: React.ElementType | string): this;
|
|
15
|
+
setVisible(visible: () => boolean): this;
|
|
16
|
+
setEnabled(enabled: () => boolean): this;
|
|
17
|
+
setExact(exact: boolean): this;
|
|
18
|
+
compose(params?: RouteParams): string;
|
|
19
|
+
}
|
|
20
|
+
export declare const defaultNavLinkNode: (route: RoutePath) => React.ReactElement;
|
|
21
|
+
export declare const defaultLinkNode: (route: RoutePath, node?: React.ReactNode) => React.ReactElement;
|
|
22
|
+
export declare const defaultRouteNode: (route: RoutePath) => React.ReactElement;
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
/*
|
|
3
|
+
* Thunderstorm is a full web app framework!
|
|
4
|
+
*
|
|
5
|
+
* Typescript & Express backend infrastructure that natively runs on firebase function
|
|
6
|
+
* Typescript & React frontend infrastructure
|
|
7
|
+
*
|
|
8
|
+
* Copyright (C) 2020 Adam van der Kruk aka TacB0sS
|
|
9
|
+
*
|
|
10
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
11
|
+
* you may not use this file except in compliance with the License.
|
|
12
|
+
* You may obtain a copy of the License at
|
|
13
|
+
*
|
|
14
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
15
|
+
*
|
|
16
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
17
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
18
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
19
|
+
* See the License for the specific language governing permissions and
|
|
20
|
+
* limitations under the License.
|
|
21
|
+
*/
|
|
22
|
+
import { composeUrl } from '@nu-art/ts-common';
|
|
23
|
+
import { Link, NavLink, Route } from 'react-router-dom';
|
|
24
|
+
export class RoutePath {
|
|
25
|
+
key;
|
|
26
|
+
path;
|
|
27
|
+
exact = false;
|
|
28
|
+
component;
|
|
29
|
+
logMessage;
|
|
30
|
+
label;
|
|
31
|
+
visible = () => !!this.label;
|
|
32
|
+
enabled;
|
|
33
|
+
constructor(key, route, component) {
|
|
34
|
+
this.key = key;
|
|
35
|
+
this.path = route;
|
|
36
|
+
this.component = component;
|
|
37
|
+
}
|
|
38
|
+
setLogMessage(logMessage) {
|
|
39
|
+
// @ts-ignore
|
|
40
|
+
this.logMessage = logMessage;
|
|
41
|
+
return this;
|
|
42
|
+
}
|
|
43
|
+
setLabel(label) {
|
|
44
|
+
// @ts-ignore
|
|
45
|
+
this.label = label;
|
|
46
|
+
return this;
|
|
47
|
+
}
|
|
48
|
+
setVisible(visible) {
|
|
49
|
+
// @ts-ignore
|
|
50
|
+
this.visible = visible;
|
|
51
|
+
return this;
|
|
52
|
+
}
|
|
53
|
+
setEnabled(enabled) {
|
|
54
|
+
// @ts-ignore
|
|
55
|
+
this.enabled = enabled;
|
|
56
|
+
return this;
|
|
57
|
+
}
|
|
58
|
+
setExact(exact) {
|
|
59
|
+
// @ts-ignore
|
|
60
|
+
this.exact = exact;
|
|
61
|
+
return this;
|
|
62
|
+
}
|
|
63
|
+
compose(params) {
|
|
64
|
+
return composeUrl(this.path, params);
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
const getNavStyles = (props) => {
|
|
68
|
+
return {
|
|
69
|
+
color: props.isActive ? 'blue' : undefined,
|
|
70
|
+
};
|
|
71
|
+
};
|
|
72
|
+
export const defaultNavLinkNode = (route) => {
|
|
73
|
+
return _jsx(NavLink, { to: route.path, style: getNavStyles, children: route.label }, route.key);
|
|
74
|
+
};
|
|
75
|
+
export const defaultLinkNode = (route, node) => {
|
|
76
|
+
return _jsx(Link, { to: route.path, children: node || route.label || route.key }, route.key);
|
|
77
|
+
};
|
|
78
|
+
export const defaultRouteNode = (route) => {
|
|
79
|
+
// if (typeof route.component === 'string')
|
|
80
|
+
// return <ReactEntryComponentInjector src={route.component}/>;
|
|
81
|
+
const Component = route.component;
|
|
82
|
+
return _jsx(Route, { path: route.path, element: _jsx(Component, {}) }, route.key);
|
|
83
|
+
};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { QueryParams } from '../../shared.js';
|
|
3
|
+
import { ResolvableContent } from '@nu-art/ts-common';
|
|
4
|
+
import { ModuleFE_BaseDB } from '../db-api-gen/ModuleFE_BaseDB.js';
|
|
5
|
+
import { AwaitModule_LoaderProps } from '../../components/AwaitModules/AwaitModules.js';
|
|
6
|
+
export type TS_Route<T extends QueryParams = QueryParams> = {
|
|
7
|
+
key: string;
|
|
8
|
+
path: string;
|
|
9
|
+
enabled?: () => boolean;
|
|
10
|
+
element?: React.ReactNode;
|
|
11
|
+
Component?: React.ComponentType<any>;
|
|
12
|
+
paramKeys?: (keyof T)[];
|
|
13
|
+
fallback?: boolean;
|
|
14
|
+
index?: boolean;
|
|
15
|
+
children?: TS_Route<any>[];
|
|
16
|
+
modulesToAwait?: ResolvableContent<(ModuleFE_BaseDB<any, any>)[]>;
|
|
17
|
+
awaitModulesLoader?: ResolvableContent<React.ReactNode, [AwaitModule_LoaderProps]>;
|
|
18
|
+
awaitSync?: boolean;
|
|
19
|
+
awaitSyncLoader?: ResolvableContent<React.ReactNode>;
|
|
20
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Module } from '@nu-art/ts-common';
|
|
2
|
+
import { ApiDefCaller, ApiStruct_SyncEnv } from '../../shared.js';
|
|
3
|
+
declare class ModuleFE_SyncEnvV2_Class extends Module {
|
|
4
|
+
readonly vv1: ApiDefCaller<ApiStruct_SyncEnv>['vv1'];
|
|
5
|
+
constructor();
|
|
6
|
+
}
|
|
7
|
+
export declare const ModuleFE_SyncEnvV2: ModuleFE_SyncEnvV2_Class;
|
|
8
|
+
export {};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { Module } from '@nu-art/ts-common';
|
|
2
|
+
import { ApiDef_SyncEnv } from '../../shared.js';
|
|
3
|
+
import { apiWithBody, apiWithQuery } from '../../core/typed-api.js';
|
|
4
|
+
class ModuleFE_SyncEnvV2_Class extends Module {
|
|
5
|
+
vv1;
|
|
6
|
+
constructor() {
|
|
7
|
+
super();
|
|
8
|
+
this.vv1 = {
|
|
9
|
+
getLatestBackup: apiWithQuery(ApiDef_SyncEnv.vv1.getLatestBackup),
|
|
10
|
+
syncToEnv: apiWithBody(ApiDef_SyncEnv.vv1.syncToEnv),
|
|
11
|
+
syncFromEnvBackup: apiWithBody(ApiDef_SyncEnv.vv1.syncFromEnvBackup),
|
|
12
|
+
createBackup: apiWithQuery(ApiDef_SyncEnv.vv1.createBackup),
|
|
13
|
+
fetchBackupMetadata: apiWithQuery(ApiDef_SyncEnv.vv1.fetchBackupMetadata),
|
|
14
|
+
syncFirebaseFromBackup: apiWithQuery(ApiDef_SyncEnv.vv1.syncFirebaseFromBackup)
|
|
15
|
+
};
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
export const ModuleFE_SyncEnvV2 = new ModuleFE_SyncEnvV2_Class();
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
import { Module, ResolvableContent } from '@nu-art/ts-common';
|
|
2
|
+
import { SyncDataFirebaseState } from '@nu-art/thunderstorm-shared/sync-manager/types';
|
|
3
|
+
import { OnConnectivityChange } from '../ModuleFE_ConnectivityModule.js';
|
|
4
|
+
import { ModuleFE_BaseApi } from '../db-api-gen/ModuleFE_BaseApi.js';
|
|
5
|
+
import { SyncManagerAPI_SmartSync } from '@nu-art/thunderstorm-shared/sync-manager/apis';
|
|
6
|
+
export interface PermissibleModulesUpdated {
|
|
7
|
+
__onPermissibleModulesUpdated: () => void;
|
|
8
|
+
}
|
|
9
|
+
export declare const Default_SyncManagerNodePath = "/state/ModuleBE_SyncManager/syncData";
|
|
10
|
+
export declare class ModuleFE_SyncManager_Class extends Module implements OnConnectivityChange {
|
|
11
|
+
__onConnectivityChange(): Promise<void>;
|
|
12
|
+
private syncedModules;
|
|
13
|
+
private readonly currentlySyncingModules;
|
|
14
|
+
private syncFirebaseListener?;
|
|
15
|
+
private outOfSyncCollections;
|
|
16
|
+
private syncing?;
|
|
17
|
+
private pendingSync?;
|
|
18
|
+
private cancelledSyncs;
|
|
19
|
+
private cleanIDBOnFullSync;
|
|
20
|
+
private syncManagerNodePath;
|
|
21
|
+
private smartSyncApiUrl;
|
|
22
|
+
private currentSyncData;
|
|
23
|
+
private _smartSyncCompleted?;
|
|
24
|
+
private _onSyncDataChanged?;
|
|
25
|
+
private _debounceTimeout;
|
|
26
|
+
private _debounceMaxTimeout;
|
|
27
|
+
private syncDebouncer?;
|
|
28
|
+
private syncQueue;
|
|
29
|
+
constructor();
|
|
30
|
+
setShouldCleanIDBOnFullSync: (cleanIDBOnFullSync: boolean) => void;
|
|
31
|
+
getPermissibleModuleNames: () => string[];
|
|
32
|
+
getCurrentlySyncingModules: () => ModuleFE_BaseApi<any, object, object & import("../../core/db-api-gen/db-def.js").DBApiFEConfig<any>>[];
|
|
33
|
+
cancelSync: () => void;
|
|
34
|
+
private getModulesToSync;
|
|
35
|
+
private getLocalSyncData;
|
|
36
|
+
private smartSync;
|
|
37
|
+
private clearSyncingStatus;
|
|
38
|
+
private debounceSyncImpl;
|
|
39
|
+
/**
|
|
40
|
+
* Perform no sync, delta sync and full sync on modules. Intention is to get all modules to DataStatus "ContainsData".
|
|
41
|
+
*/
|
|
42
|
+
onSmartSyncCompleted: (response: SyncManagerAPI_SmartSync["response"]) => Promise<void>;
|
|
43
|
+
private performSync;
|
|
44
|
+
private performNoSync;
|
|
45
|
+
private performDeltaSync;
|
|
46
|
+
private performFullSync;
|
|
47
|
+
private generateSyncRequestId;
|
|
48
|
+
private removeFromCancelledSyncs;
|
|
49
|
+
startListening(): void;
|
|
50
|
+
stopListening(): void;
|
|
51
|
+
private onSyncDataChanged;
|
|
52
|
+
setNodeContext: (nodeContextResolver: ResolvableContent<string>) => ResolvableContent<string>;
|
|
53
|
+
setSmartSyncUrl: (baseUrlResolver: ResolvableContent<string | undefined>) => ResolvableContent<string | undefined>;
|
|
54
|
+
setOnSyncCompleted: (smartSyncCompleted: (syncData: SyncDataFirebaseState) => void) => (syncData: SyncDataFirebaseState) => void;
|
|
55
|
+
setOnSyncDataChanged: (onSyncDataChanged: (syncData?: SyncDataFirebaseState) => void) => (syncData?: SyncDataFirebaseState) => void;
|
|
56
|
+
setDebounceTimeout: (debounceTimeout: number) => number;
|
|
57
|
+
setDebounceMaxTimeout: (debounceTimeout: number) => number;
|
|
58
|
+
}
|
|
59
|
+
export declare const ModuleFE_SyncManager: ModuleFE_SyncManager_Class;
|