@xh/hoist 57.0.0 → 57.0.1
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/CHANGELOG.md +6 -0
- package/build/types/admin/AppComponent.d.ts +4 -0
- package/build/types/admin/AppModel.d.ts +13 -0
- package/build/types/admin/columns/Core.d.ts +6 -0
- package/build/types/admin/columns/Rest.d.ts +5 -0
- package/build/types/admin/columns/Tracking.d.ts +18 -0
- package/build/types/admin/columns/User.d.ts +9 -0
- package/build/types/admin/columns/UserData.d.ts +7 -0
- package/build/types/admin/columns/index.d.ts +5 -0
- package/build/types/admin/differ/Differ.d.ts +2 -0
- package/build/types/admin/differ/DifferDetail.d.ts +3 -0
- package/build/types/admin/differ/DifferDetailModel.d.ts +17 -0
- package/build/types/admin/differ/DifferModel.d.ts +43 -0
- package/build/types/admin/regroup/RegroupDialog.d.ts +2 -0
- package/build/types/admin/regroup/RegroupDialogModel.d.ts +20 -0
- package/build/types/admin/tabs/activity/ActivityTab.d.ts +2 -0
- package/build/types/admin/tabs/activity/aggregators/RangeAggregator.d.ts +8 -0
- package/build/types/admin/tabs/activity/clienterrors/ClientErrorDetail.d.ts +2 -0
- package/build/types/admin/tabs/activity/clienterrors/ClientErrorsModel.d.ts +30 -0
- package/build/types/admin/tabs/activity/clienterrors/ClientErrorsPanel.d.ts +2 -0
- package/build/types/admin/tabs/activity/feedback/FeedbackPanel.d.ts +1 -0
- package/build/types/admin/tabs/activity/tracking/ActivityTrackingModel.d.ts +50 -0
- package/build/types/admin/tabs/activity/tracking/ActivityTrackingPanel.d.ts +2 -0
- package/build/types/admin/tabs/activity/tracking/charts/ChartsModel.d.ts +32 -0
- package/build/types/admin/tabs/activity/tracking/charts/ChartsPanel.d.ts +2 -0
- package/build/types/admin/tabs/activity/tracking/detail/ActivityDetailModel.d.ts +15 -0
- package/build/types/admin/tabs/activity/tracking/detail/ActivityDetailView.d.ts +2 -0
- package/build/types/admin/tabs/general/GeneralTab.d.ts +1 -0
- package/build/types/admin/tabs/general/about/AboutPanel.d.ts +2 -0
- package/build/types/admin/tabs/general/alertBanner/AlertBannerModel.d.ts +24 -0
- package/build/types/admin/tabs/general/alertBanner/AlertBannerPanel.d.ts +3 -0
- package/build/types/admin/tabs/general/config/ConfigPanel.d.ts +2 -0
- package/build/types/admin/tabs/general/config/ConfigPanelModel.d.ts +19 -0
- package/build/types/admin/tabs/general/users/UserModel.d.ts +12 -0
- package/build/types/admin/tabs/general/users/UserPanel.d.ts +2 -0
- package/build/types/admin/tabs/monitor/MonitorColumns.d.ts +15 -0
- package/build/types/admin/tabs/monitor/MonitorEditorPanel.d.ts +1 -0
- package/build/types/admin/tabs/monitor/MonitorResultsModel.d.ts +17 -0
- package/build/types/admin/tabs/monitor/MonitorResultsPanel.d.ts +3 -0
- package/build/types/admin/tabs/monitor/MonitorResultsToolbar.d.ts +2 -0
- package/build/types/admin/tabs/monitor/MonitorTab.d.ts +1 -0
- package/build/types/admin/tabs/monitor/Tile.d.ts +2 -0
- package/build/types/admin/tabs/server/ServerTab.d.ts +1 -0
- package/build/types/admin/tabs/server/ehcache/EhCacheModel.d.ts +10 -0
- package/build/types/admin/tabs/server/ehcache/EhCachePanel.d.ts +2 -0
- package/build/types/admin/tabs/server/environment/ServerEnvModel.d.ts +11 -0
- package/build/types/admin/tabs/server/environment/ServerEnvPanel.d.ts +2 -0
- package/build/types/admin/tabs/server/logLevel/LogLevelColumns.d.ts +5 -0
- package/build/types/admin/tabs/server/logLevel/LogLevelPanel.d.ts +1 -0
- package/build/types/admin/tabs/server/logViewer/LogDisplay.d.ts +6 -0
- package/build/types/admin/tabs/server/logViewer/LogDisplayModel.d.ts +29 -0
- package/build/types/admin/tabs/server/logViewer/LogViewer.d.ts +3 -0
- package/build/types/admin/tabs/server/logViewer/LogViewerModel.d.ts +23 -0
- package/build/types/admin/tabs/server/memory/MemoryMonitorModel.d.ts +15 -0
- package/build/types/admin/tabs/server/memory/MemoryMonitorPanel.d.ts +2 -0
- package/build/types/admin/tabs/server/services/ServiceModel.d.ts +8 -0
- package/build/types/admin/tabs/server/services/ServicePanel.d.ts +2 -0
- package/build/types/admin/tabs/server/websocket/WebSocketColumns.d.ts +8 -0
- package/build/types/admin/tabs/server/websocket/WebSocketModel.d.ts +12 -0
- package/build/types/admin/tabs/server/websocket/WebSocketPanel.d.ts +2 -0
- package/build/types/admin/tabs/userData/JsonBlobColumns.d.ts +9 -0
- package/build/types/admin/tabs/userData/JsonBlobModel.d.ts +15 -0
- package/build/types/admin/tabs/userData/JsonBlobPanel.d.ts +2 -0
- package/build/types/admin/tabs/userData/PreferenceModel.d.ts +16 -0
- package/build/types/admin/tabs/userData/PreferencePanel.d.ts +2 -0
- package/build/types/admin/tabs/userData/UserDataTab.d.ts +1 -0
- package/build/types/admin/tabs/userData/UserPreferencePanel.d.ts +1 -0
- package/build/types/appcontainer/AboutDialogModel.d.ts +15 -0
- package/build/types/appcontainer/AppContainerModel.d.ts +43 -0
- package/build/types/appcontainer/AppOption.d.ts +23 -0
- package/build/types/appcontainer/BannerModel.d.ts +26 -0
- package/build/types/appcontainer/BannerSourceModel.d.ts +15 -0
- package/build/types/appcontainer/ChangelogDialogModel.d.ts +9 -0
- package/build/types/appcontainer/ErrorBoundary.d.ts +16 -0
- package/build/types/appcontainer/ExceptionDialogModel.d.ts +28 -0
- package/build/types/appcontainer/FeedbackDialogModel.d.ts +24 -0
- package/build/types/appcontainer/ImpersonationBarModel.d.ts +20 -0
- package/build/types/appcontainer/MessageModel.d.ts +35 -0
- package/build/types/appcontainer/MessageSourceModel.d.ts +18 -0
- package/build/types/appcontainer/OptionsDialogModel.d.ts +23 -0
- package/build/types/appcontainer/SizingModeModel.d.ts +13 -0
- package/build/types/appcontainer/ThemeModel.d.ts +13 -0
- package/build/types/appcontainer/ToastModel.d.ts +27 -0
- package/build/types/appcontainer/ToastSourceModel.d.ts +13 -0
- package/build/types/appcontainer/ViewportSizeModel.d.ts +19 -0
- package/build/types/appcontainer/login/LoginPanelModel.d.ts +15 -0
- package/build/types/cmp/ag-grid/AgGrid.d.ts +31 -0
- package/build/types/cmp/ag-grid/AgGridModel.d.ts +183 -0
- package/build/types/cmp/ag-grid/index.d.ts +2 -0
- package/build/types/cmp/badge/Badge.d.ts +13 -0
- package/build/types/cmp/badge/index.d.ts +1 -0
- package/build/types/cmp/chart/Chart.d.ts +18 -0
- package/build/types/cmp/chart/ChartModel.d.ts +48 -0
- package/build/types/cmp/chart/impl/copyToClipboard.d.ts +6 -0
- package/build/types/cmp/chart/impl/zoomout.d.ts +5 -0
- package/build/types/cmp/chart/index.d.ts +2 -0
- package/build/types/cmp/chart/theme/Dark.d.ts +216 -0
- package/build/types/cmp/chart/theme/Light.d.ts +193 -0
- package/build/types/cmp/clock/Clock.d.ts +26 -0
- package/build/types/cmp/clock/index.d.ts +1 -0
- package/build/types/cmp/dataview/DataView.d.ts +22 -0
- package/build/types/cmp/dataview/DataViewModel.d.ts +103 -0
- package/build/types/cmp/dataview/index.d.ts +2 -0
- package/build/types/cmp/filter/FilterChooserFieldSpec.d.ts +39 -0
- package/build/types/cmp/filter/FilterChooserModel.d.ts +130 -0
- package/build/types/cmp/filter/impl/Option.d.ts +47 -0
- package/build/types/cmp/filter/impl/QueryEngine.d.ts +29 -0
- package/build/types/cmp/filter/index.d.ts +1 -0
- package/build/types/cmp/form/BaseFormFieldProps.d.ts +33 -0
- package/build/types/cmp/form/Form.d.ts +35 -0
- package/build/types/cmp/form/FormModel.d.ts +130 -0
- package/build/types/cmp/form/field/BaseFieldModel.d.ts +156 -0
- package/build/types/cmp/form/field/FieldModel.d.ts +11 -0
- package/build/types/cmp/form/field/SubformsFieldModel.d.ts +65 -0
- package/build/types/cmp/form/index.d.ts +6 -0
- package/build/types/cmp/grid/Grid.d.ts +39 -0
- package/build/types/cmp/grid/GridAutosizeOptions.d.ts +44 -0
- package/build/types/cmp/grid/GridContextMenu.d.ts +28 -0
- package/build/types/cmp/grid/GridModel.d.ts +556 -0
- package/build/types/cmp/grid/GridSorter.d.ts +23 -0
- package/build/types/cmp/grid/Types.d.ts +274 -0
- package/build/types/cmp/grid/columns/Column.d.ts +362 -0
- package/build/types/cmp/grid/columns/ColumnGroup.d.ts +56 -0
- package/build/types/cmp/grid/columns/Core.d.ts +9 -0
- package/build/types/cmp/grid/columns/DatesTimes.d.ts +12 -0
- package/build/types/cmp/grid/columns/index.d.ts +4 -0
- package/build/types/cmp/grid/enums/ExcelFormat.d.ts +33 -0
- package/build/types/cmp/grid/enums/GridAutosizeMode.d.ts +24 -0
- package/build/types/cmp/grid/enums/TreeStyle.d.ts +15 -0
- package/build/types/cmp/grid/filter/GridFilterFieldSpec.d.ts +38 -0
- package/build/types/cmp/grid/filter/GridFilterModel.d.ts +44 -0
- package/build/types/cmp/grid/helpers/GridCountLabel.d.ts +25 -0
- package/build/types/cmp/grid/impl/ColumnGroupHeader.d.ts +24 -0
- package/build/types/cmp/grid/impl/ColumnHeader.d.ts +55 -0
- package/build/types/cmp/grid/impl/ColumnWidthCalculator.d.ts +41 -0
- package/build/types/cmp/grid/impl/GridPersistenceModel.d.ts +34 -0
- package/build/types/cmp/grid/impl/MenuSupport.d.ts +7 -0
- package/build/types/cmp/grid/impl/RowKeyNavSupport.d.ts +11 -0
- package/build/types/cmp/grid/impl/Utils.d.ts +5 -0
- package/build/types/cmp/grid/index.d.ts +15 -0
- package/build/types/cmp/grid/renderers/MultiFieldRenderer.d.ts +27 -0
- package/build/types/cmp/grid/renderers/TagsRenderer.d.ts +3 -0
- package/build/types/cmp/grouping/GroupingChooserModel.d.ts +89 -0
- package/build/types/cmp/grouping/index.d.ts +1 -0
- package/build/types/cmp/input/HoistInputModel.d.ts +148 -0
- package/build/types/cmp/input/HoistInputProps.d.ts +19 -0
- package/build/types/cmp/input/index.d.ts +2 -0
- package/build/types/cmp/layout/Box.d.ts +17 -0
- package/build/types/cmp/layout/Frame.d.ts +15 -0
- package/build/types/cmp/layout/Placeholder.d.ts +12 -0
- package/build/types/cmp/layout/Spacer.d.ts +15 -0
- package/build/types/cmp/layout/Tags.d.ts +32 -0
- package/build/types/cmp/layout/TileFrame.d.ts +38 -0
- package/build/types/cmp/layout/Viewport.d.ts +9 -0
- package/build/types/cmp/layout/index.d.ts +7 -0
- package/build/types/cmp/pinpad/PinPad.d.ts +10 -0
- package/build/types/cmp/pinpad/PinPadModel.d.ts +35 -0
- package/build/types/cmp/pinpad/index.d.ts +2 -0
- package/build/types/cmp/relativetimestamp/RelativeTimestamp.d.ts +46 -0
- package/build/types/cmp/relativetimestamp/index.d.ts +1 -0
- package/build/types/cmp/spinner/Spinner.d.ts +16 -0
- package/build/types/cmp/spinner/index.d.ts +1 -0
- package/build/types/cmp/store/StoreCountLabel.d.ts +18 -0
- package/build/types/cmp/store/StoreFilterField.d.ts +82 -0
- package/build/types/cmp/store/impl/StoreFilterFieldImplModel.d.ts +23 -0
- package/build/types/cmp/store/index.d.ts +2 -0
- package/build/types/cmp/tab/TabContainer.d.ts +20 -0
- package/build/types/cmp/tab/TabContainerModel.d.ts +114 -0
- package/build/types/cmp/tab/TabModel.d.ts +71 -0
- package/build/types/cmp/tab/TabSwitcherProps.d.ts +16 -0
- package/build/types/cmp/tab/index.d.ts +4 -0
- package/build/types/cmp/websocket/WebSocketIndicator.d.ts +10 -0
- package/build/types/cmp/websocket/index.d.ts +1 -0
- package/build/types/core/AppSpec.d.ts +106 -0
- package/build/types/core/AppState.d.ts +13 -0
- package/build/types/core/HoistAppModel.d.ts +81 -0
- package/build/types/core/HoistBase.d.ts +160 -0
- package/build/types/core/HoistBaseDecorators.d.ts +20 -0
- package/build/types/core/HoistComponent.d.ts +109 -0
- package/build/types/core/HoistProps.d.ts +91 -0
- package/build/types/core/HoistService.d.ts +56 -0
- package/build/types/core/RefreshContextView.d.ts +11 -0
- package/build/types/core/RouterModel.d.ts +41 -0
- package/build/types/core/TaskObserver.d.ts +75 -0
- package/build/types/core/XH.d.ts +358 -0
- package/build/types/core/elem.d.ts +55 -0
- package/build/types/core/enums/RefreshMode.d.ts +16 -0
- package/build/types/core/enums/RenderMode.d.ts +13 -0
- package/build/types/core/enums/SizingMode.d.ts +10 -0
- package/build/types/core/exception/Exception.d.ts +63 -0
- package/build/types/core/exception/ExceptionHandler.d.ts +121 -0
- package/build/types/core/exception/Types.d.ts +50 -0
- package/build/types/core/impl/InstallServices.d.ts +18 -0
- package/build/types/core/impl/InstanceManager.d.ts +19 -0
- package/build/types/core/impl/PlatformManager.d.ts +13 -0
- package/build/types/core/index.d.ts +24 -0
- package/build/types/core/load/LoadSpec.d.ts +50 -0
- package/build/types/core/load/LoadSupport.d.ts +36 -0
- package/build/types/core/load/Loadable.d.ts +48 -0
- package/build/types/core/load/index.d.ts +3 -0
- package/build/types/core/model/CreatesSpec.d.ts +29 -0
- package/build/types/core/model/HoistModel.d.ts +121 -0
- package/build/types/core/model/Hooks.d.ts +28 -0
- package/build/types/core/model/ManagedRefreshContextModel.d.ts +23 -0
- package/build/types/core/model/ModelLookup.d.ts +27 -0
- package/build/types/core/model/ModelSelector.d.ts +28 -0
- package/build/types/core/model/ModelSpec.d.ts +30 -0
- package/build/types/core/model/RefreshContextModel.d.ts +45 -0
- package/build/types/core/model/RootRefreshContextModel.d.ts +14 -0
- package/build/types/core/model/UsesSpec.d.ts +49 -0
- package/build/types/core/model/index.d.ts +10 -0
- package/build/types/core/persist/CustomProvider.d.ts +16 -0
- package/build/types/core/persist/DashViewProvider.d.ts +11 -0
- package/build/types/core/persist/LocalStorageProvider.d.ts +11 -0
- package/build/types/core/persist/PersistOptions.d.ts +31 -0
- package/build/types/core/persist/PersistenceProvider.d.ts +49 -0
- package/build/types/core/persist/PrefProvider.d.ts +11 -0
- package/build/types/core/persist/index.d.ts +6 -0
- package/build/types/core/types/Interfaces.d.ts +232 -0
- package/build/types/core/types/Types.d.ts +41 -0
- package/build/types/data/Field.d.ts +72 -0
- package/build/types/data/RecordAction.d.ts +114 -0
- package/build/types/data/Store.d.ts +386 -0
- package/build/types/data/StoreRecord.d.ts +167 -0
- package/build/types/data/StoreSelectionModel.d.ts +52 -0
- package/build/types/data/UrlStore.d.ts +26 -0
- package/build/types/data/cube/BucketSpec.d.ts +13 -0
- package/build/types/data/cube/Cube.d.ts +159 -0
- package/build/types/data/cube/CubeField.d.ts +52 -0
- package/build/types/data/cube/Query.d.ts +63 -0
- package/build/types/data/cube/View.d.ts +97 -0
- package/build/types/data/cube/aggregate/AggregationContext.d.ts +21 -0
- package/build/types/data/cube/aggregate/Aggregator.d.ts +40 -0
- package/build/types/data/cube/aggregate/AverageAggregator.d.ts +4 -0
- package/build/types/data/cube/aggregate/AverageStrictAggregator.d.ts +5 -0
- package/build/types/data/cube/aggregate/ChildCountAggregator.d.ts +5 -0
- package/build/types/data/cube/aggregate/LeafCountAggregator.d.ts +5 -0
- package/build/types/data/cube/aggregate/MaxAggregator.d.ts +5 -0
- package/build/types/data/cube/aggregate/MinAggregator.d.ts +5 -0
- package/build/types/data/cube/aggregate/NullAggregator.d.ts +4 -0
- package/build/types/data/cube/aggregate/SingleAggregator.d.ts +4 -0
- package/build/types/data/cube/aggregate/SumAggregator.d.ts +5 -0
- package/build/types/data/cube/aggregate/SumStrictAggregator.d.ts +5 -0
- package/build/types/data/cube/aggregate/UniqueAggregator.d.ts +5 -0
- package/build/types/data/cube/row/AggregateRow.d.ts +13 -0
- package/build/types/data/cube/row/BaseRow.d.ts +27 -0
- package/build/types/data/cube/row/BucketRow.d.ts +12 -0
- package/build/types/data/cube/row/LeafRow.d.ts +12 -0
- package/build/types/data/cube/row/RowUpdate.d.ts +10 -0
- package/build/types/data/filter/BaseFilterFieldSpec.d.ts +73 -0
- package/build/types/data/filter/CompoundFilter.d.ts +23 -0
- package/build/types/data/filter/FieldFilter.d.ts +32 -0
- package/build/types/data/filter/Filter.d.ts +25 -0
- package/build/types/data/filter/FunctionFilter.d.ts +20 -0
- package/build/types/data/filter/Types.d.ts +31 -0
- package/build/types/data/filter/Utils.d.ts +49 -0
- package/build/types/data/impl/RecordSet.d.ts +44 -0
- package/build/types/data/impl/RecordValidator.d.ts +39 -0
- package/build/types/data/impl/StoreValidator.d.ts +47 -0
- package/build/types/data/index.d.ts +31 -0
- package/build/types/data/validation/Rule.d.ts +51 -0
- package/build/types/data/validation/ValidationState.d.ts +6 -0
- package/build/types/data/validation/constraints.d.ts +64 -0
- package/build/types/deprecated/index.d.ts +0 -0
- package/build/types/desktop/appcontainer/AboutDialog.d.ts +11 -0
- package/build/types/desktop/appcontainer/AppContainer.d.ts +13 -0
- package/build/types/desktop/appcontainer/Banner.d.ts +8 -0
- package/build/types/desktop/appcontainer/ChangelogDialog.d.ts +3 -0
- package/build/types/desktop/appcontainer/ExceptionDialog.d.ts +13 -0
- package/build/types/desktop/appcontainer/ExceptionDialogDetails.d.ts +8 -0
- package/build/types/desktop/appcontainer/FeedbackDialog.d.ts +6 -0
- package/build/types/desktop/appcontainer/IdlePanel.d.ts +8 -0
- package/build/types/desktop/appcontainer/ImpersonationBar.d.ts +9 -0
- package/build/types/desktop/appcontainer/LockoutPanel.d.ts +8 -0
- package/build/types/desktop/appcontainer/LoginPanel.d.ts +9 -0
- package/build/types/desktop/appcontainer/Message.d.ts +8 -0
- package/build/types/desktop/appcontainer/MessageSource.d.ts +6 -0
- package/build/types/desktop/appcontainer/OptionsDialog.d.ts +9 -0
- package/build/types/desktop/appcontainer/SuspendPanel.d.ts +6 -0
- package/build/types/desktop/appcontainer/ToastSource.d.ts +8 -0
- package/build/types/desktop/appcontainer/VersionBar.d.ts +3 -0
- package/build/types/desktop/appcontainer/index.d.ts +1 -0
- package/build/types/desktop/cmp/appOption/AutoRefreshAppOption.d.ts +340 -0
- package/build/types/desktop/cmp/appOption/SizingModeAppOption.d.ts +17 -0
- package/build/types/desktop/cmp/appOption/ThemeAppOption.d.ts +340 -0
- package/build/types/desktop/cmp/appOption/index.d.ts +3 -0
- package/build/types/desktop/cmp/appbar/AppBar.d.ts +34 -0
- package/build/types/desktop/cmp/appbar/AppBarSeparator.d.ts +6 -0
- package/build/types/desktop/cmp/appbar/index.d.ts +2 -0
- package/build/types/desktop/cmp/button/AppMenuButton.d.ts +36 -0
- package/build/types/desktop/cmp/button/Button.d.ts +28 -0
- package/build/types/desktop/cmp/button/ButtonGroup.d.ts +17 -0
- package/build/types/desktop/cmp/button/ColAutosizeButton.d.ts +14 -0
- package/build/types/desktop/cmp/button/ColChooserButton.d.ts +19 -0
- package/build/types/desktop/cmp/button/DashCanvasAddViewButton.d.ts +11 -0
- package/build/types/desktop/cmp/button/ExportButton.d.ts +22 -0
- package/build/types/desktop/cmp/button/FeedbackButton.d.ts +9 -0
- package/build/types/desktop/cmp/button/LaunchAdminButton.d.ts +9 -0
- package/build/types/desktop/cmp/button/LogoutButton.d.ts +11 -0
- package/build/types/desktop/cmp/button/ModalToggleButton.d.ts +11 -0
- package/build/types/desktop/cmp/button/OptionsButton.d.ts +10 -0
- package/build/types/desktop/cmp/button/RefreshButton.d.ts +13 -0
- package/build/types/desktop/cmp/button/RestoreDefaultsButton.d.ts +16 -0
- package/build/types/desktop/cmp/button/ThemeToggleButton.d.ts +8 -0
- package/build/types/desktop/cmp/button/WhatsNewButton.d.ts +11 -0
- package/build/types/desktop/cmp/button/index.d.ts +15 -0
- package/build/types/desktop/cmp/clipboard/ClipboardButton.d.ts +13 -0
- package/build/types/desktop/cmp/clipboard/ClipboardMenuItem.d.ts +7 -0
- package/build/types/desktop/cmp/clipboard/index.d.ts +2 -0
- package/build/types/desktop/cmp/contextmenu/ContextMenu.d.ts +21 -0
- package/build/types/desktop/cmp/contextmenu/index.d.ts +1 -0
- package/build/types/desktop/cmp/dash/DashConfig.d.ts +33 -0
- package/build/types/desktop/cmp/dash/DashModel.d.ts +19 -0
- package/build/types/desktop/cmp/dash/DashViewModel.d.ts +52 -0
- package/build/types/desktop/cmp/dash/DashViewSpec.d.ts +41 -0
- package/build/types/desktop/cmp/dash/canvas/DashCanvas.d.ts +19 -0
- package/build/types/desktop/cmp/dash/canvas/DashCanvasModel.d.ts +104 -0
- package/build/types/desktop/cmp/dash/canvas/DashCanvasViewModel.d.ts +27 -0
- package/build/types/desktop/cmp/dash/canvas/DashCanvasViewSpec.d.ts +30 -0
- package/build/types/desktop/cmp/dash/canvas/impl/DashCanvasContextMenu.d.ts +8 -0
- package/build/types/desktop/cmp/dash/canvas/impl/DashCanvasView.d.ts +12 -0
- package/build/types/desktop/cmp/dash/canvas/impl/utils.d.ts +10 -0
- package/build/types/desktop/cmp/dash/container/DashContainer.d.ts +9 -0
- package/build/types/desktop/cmp/dash/container/DashContainerModel.d.ts +143 -0
- package/build/types/desktop/cmp/dash/container/DashContainerViewSpec.d.ts +17 -0
- package/build/types/desktop/cmp/dash/container/impl/DashContainerContextMenu.d.ts +15 -0
- package/build/types/desktop/cmp/dash/container/impl/DashContainerMenuButton.d.ts +7 -0
- package/build/types/desktop/cmp/dash/container/impl/DashContainerUtils.d.ts +14 -0
- package/build/types/desktop/cmp/dash/container/impl/DashContainerView.d.ts +12 -0
- package/build/types/desktop/cmp/dash/index.d.ts +11 -0
- package/build/types/desktop/cmp/dock/DockContainer.d.ts +26 -0
- package/build/types/desktop/cmp/dock/DockContainerModel.d.ts +33 -0
- package/build/types/desktop/cmp/dock/DockViewModel.d.ts +75 -0
- package/build/types/desktop/cmp/dock/impl/DockContainer.d.ts +10 -0
- package/build/types/desktop/cmp/dock/impl/DockView.d.ts +15 -0
- package/build/types/desktop/cmp/dock/index.d.ts +3 -0
- package/build/types/desktop/cmp/error/ErrorMessage.d.ts +33 -0
- package/build/types/desktop/cmp/error/index.d.ts +1 -0
- package/build/types/desktop/cmp/filechooser/FileChooser.d.ts +42 -0
- package/build/types/desktop/cmp/filechooser/FileChooserModel.d.ts +25 -0
- package/build/types/desktop/cmp/filechooser/index.d.ts +2 -0
- package/build/types/desktop/cmp/filter/FilterChooser.d.ts +28 -0
- package/build/types/desktop/cmp/filter/index.d.ts +2 -0
- package/build/types/desktop/cmp/form/FormField.d.ts +63 -0
- package/build/types/desktop/cmp/form/index.d.ts +1 -0
- package/build/types/desktop/cmp/grid/columns/Actions.d.ts +29 -0
- package/build/types/desktop/cmp/grid/editors/BooleanEditor.d.ts +16 -0
- package/build/types/desktop/cmp/grid/editors/DateEditor.d.ts +7 -0
- package/build/types/desktop/cmp/grid/editors/EditorProps.d.ts +17 -0
- package/build/types/desktop/cmp/grid/editors/NumberEditor.d.ts +7 -0
- package/build/types/desktop/cmp/grid/editors/SelectEditor.d.ts +7 -0
- package/build/types/desktop/cmp/grid/editors/TextAreaEditor.d.ts +7 -0
- package/build/types/desktop/cmp/grid/editors/TextEditor.d.ts +7 -0
- package/build/types/desktop/cmp/grid/editors/impl/InlineEditorModel.d.ts +15 -0
- package/build/types/desktop/cmp/grid/editors/index.d.ts +6 -0
- package/build/types/desktop/cmp/grid/find/GridFindField.d.ts +43 -0
- package/build/types/desktop/cmp/grid/find/impl/GridFindFieldImplModel.d.ts +37 -0
- package/build/types/desktop/cmp/grid/impl/colchooser/ColChooser.d.ts +18 -0
- package/build/types/desktop/cmp/grid/impl/colchooser/ColChooserDialog.d.ts +2 -0
- package/build/types/desktop/cmp/grid/impl/colchooser/ColChooserModel.d.ts +33 -0
- package/build/types/desktop/cmp/grid/impl/filter/ColumnHeaderFilter.d.ts +9 -0
- package/build/types/desktop/cmp/grid/impl/filter/ColumnHeaderFilterModel.d.ts +38 -0
- package/build/types/desktop/cmp/grid/impl/filter/GridFilterDialog.d.ts +11 -0
- package/build/types/desktop/cmp/grid/impl/filter/custom/CustomRow.d.ts +6 -0
- package/build/types/desktop/cmp/grid/impl/filter/custom/CustomRowModel.d.ts +28 -0
- package/build/types/desktop/cmp/grid/impl/filter/custom/CustomTab.d.ts +7 -0
- package/build/types/desktop/cmp/grid/impl/filter/custom/CustomTabModel.d.ts +21 -0
- package/build/types/desktop/cmp/grid/impl/filter/values/ValuesTab.d.ts +7 -0
- package/build/types/desktop/cmp/grid/impl/filter/values/ValuesTabModel.d.ts +33 -0
- package/build/types/desktop/cmp/grid/index.d.ts +3 -0
- package/build/types/desktop/cmp/grouping/GroupingChooser.d.ts +26 -0
- package/build/types/desktop/cmp/grouping/index.d.ts +2 -0
- package/build/types/desktop/cmp/input/ButtonGroupInput.d.ts +26 -0
- package/build/types/desktop/cmp/input/Checkbox.d.ts +28 -0
- package/build/types/desktop/cmp/input/CodeInput.d.ts +80 -0
- package/build/types/desktop/cmp/input/DateInput.d.ts +117 -0
- package/build/types/desktop/cmp/input/JsonInput.d.ts +9 -0
- package/build/types/desktop/cmp/input/NumberInput.d.ts +77 -0
- package/build/types/desktop/cmp/input/RadioInput.d.ts +22 -0
- package/build/types/desktop/cmp/input/Select.d.ts +139 -0
- package/build/types/desktop/cmp/input/Slider.d.ts +33 -0
- package/build/types/desktop/cmp/input/SwitchInput.d.ts +21 -0
- package/build/types/desktop/cmp/input/TextArea.d.ts +26 -0
- package/build/types/desktop/cmp/input/TextInput.d.ts +55 -0
- package/build/types/desktop/cmp/input/index.d.ts +12 -0
- package/build/types/desktop/cmp/leftrightchooser/LeftRightChooser.d.ts +14 -0
- package/build/types/desktop/cmp/leftrightchooser/LeftRightChooserFilter.d.ts +15 -0
- package/build/types/desktop/cmp/leftrightchooser/LeftRightChooserModel.d.ts +83 -0
- package/build/types/desktop/cmp/leftrightchooser/impl/ChooserToolbar.d.ts +3 -0
- package/build/types/desktop/cmp/leftrightchooser/impl/Description.d.ts +3 -0
- package/build/types/desktop/cmp/leftrightchooser/index.d.ts +3 -0
- package/build/types/desktop/cmp/loadingindicator/LoadingIndicator.d.ts +27 -0
- package/build/types/desktop/cmp/loadingindicator/index.d.ts +1 -0
- package/build/types/desktop/cmp/mask/Mask.d.ts +27 -0
- package/build/types/desktop/cmp/mask/index.d.ts +1 -0
- package/build/types/desktop/cmp/modalsupport/ModalSupport.d.ts +16 -0
- package/build/types/desktop/cmp/modalsupport/ModalSupportModel.d.ts +30 -0
- package/build/types/desktop/cmp/modalsupport/index.d.ts +2 -0
- package/build/types/desktop/cmp/panel/Panel.d.ts +60 -0
- package/build/types/desktop/cmp/panel/PanelModel.d.ts +112 -0
- package/build/types/desktop/cmp/panel/impl/PanelHeader.d.ts +2 -0
- package/build/types/desktop/cmp/panel/impl/ResizeContainer.d.ts +1 -0
- package/build/types/desktop/cmp/panel/impl/Splitter.d.ts +2 -0
- package/build/types/desktop/cmp/panel/impl/dragger/Dragger.d.ts +3 -0
- package/build/types/desktop/cmp/panel/impl/dragger/DraggerModel.d.ts +33 -0
- package/build/types/desktop/cmp/panel/index.d.ts +2 -0
- package/build/types/desktop/cmp/pinpad/impl/PinPad.d.ts +11 -0
- package/build/types/desktop/cmp/record/RecordActionBar.d.ts +33 -0
- package/build/types/desktop/cmp/record/impl/RecordActionButton.d.ts +21 -0
- package/build/types/desktop/cmp/record/index.d.ts +1 -0
- package/build/types/desktop/cmp/rest/Actions.d.ts +7 -0
- package/build/types/desktop/cmp/rest/RestGrid.d.ts +24 -0
- package/build/types/desktop/cmp/rest/RestGridModel.d.ts +98 -0
- package/build/types/desktop/cmp/rest/data/RestField.d.ts +37 -0
- package/build/types/desktop/cmp/rest/data/RestStore.d.ts +39 -0
- package/build/types/desktop/cmp/rest/impl/RestForm.d.ts +6 -0
- package/build/types/desktop/cmp/rest/impl/RestFormField.d.ts +5 -0
- package/build/types/desktop/cmp/rest/impl/RestFormModel.d.ts +48 -0
- package/build/types/desktop/cmp/rest/impl/RestGridToolbar.d.ts +5 -0
- package/build/types/desktop/cmp/rest/index.d.ts +4 -0
- package/build/types/desktop/cmp/store/impl/StoreFilterField.d.ts +7 -0
- package/build/types/desktop/cmp/tab/TabSwitcher.d.ts +15 -0
- package/build/types/desktop/cmp/tab/impl/Tab.d.ts +12 -0
- package/build/types/desktop/cmp/tab/impl/TabContainer.d.ts +8 -0
- package/build/types/desktop/cmp/tab/index.d.ts +1 -0
- package/build/types/desktop/cmp/toolbar/Toolbar.d.ts +31 -0
- package/build/types/desktop/cmp/toolbar/ToolbarSep.d.ts +11 -0
- package/build/types/desktop/cmp/toolbar/index.d.ts +2 -0
- package/build/types/desktop/cmp/treemap/SplitTreeMap.d.ts +11 -0
- package/build/types/desktop/cmp/treemap/SplitTreeMapModel.d.ts +79 -0
- package/build/types/desktop/cmp/treemap/TreeMap.d.ts +16 -0
- package/build/types/desktop/cmp/treemap/TreeMapModel.d.ts +182 -0
- package/build/types/desktop/cmp/treemap/impl/Splitter.d.ts +6 -0
- package/build/types/desktop/cmp/treemap/index.d.ts +4 -0
- package/build/types/desktop/hooks/UseContextMenu.d.ts +11 -0
- package/build/types/desktop/hooks/UseHotkeys.d.ts +14 -0
- package/build/types/desktop/hooks/index.d.ts +2 -0
- package/build/types/desktop/register.d.ts +1 -0
- package/build/types/dynamics/desktop.d.ts +27 -0
- package/build/types/dynamics/mobile.d.ts +21 -0
- package/build/types/format/FormatDate.d.ts +52 -0
- package/build/types/format/FormatMisc.d.ts +41 -0
- package/build/types/format/FormatNumber.d.ts +112 -0
- package/build/types/format/FormatUtils.d.ts +11 -0
- package/build/types/format/impl/Utils.d.ts +7 -0
- package/build/types/format/index.d.ts +4 -0
- package/build/types/icon/Icon.d.ts +340 -0
- package/build/types/icon/XHLogo.d.ts +4 -0
- package/build/types/icon/impl/IconCmp.d.ts +6 -0
- package/build/types/icon/impl/IconHtml.d.ts +13 -0
- package/build/types/icon/index.d.ts +2 -0
- package/build/types/inspector/InspectorPanel.d.ts +5 -0
- package/build/types/inspector/instances/InstancesModel.d.ts +48 -0
- package/build/types/inspector/instances/InstancesPanel.d.ts +2 -0
- package/build/types/inspector/stats/StatsModel.d.ts +19 -0
- package/build/types/inspector/stats/StatsPanel.d.ts +2 -0
- package/build/types/kit/ag-grid/index.d.ts +19 -0
- package/build/types/kit/blueprint/Dialog.d.ts +13 -0
- package/build/types/kit/blueprint/Wrappers.d.ts +5 -0
- package/build/types/kit/blueprint/index.d.ts +8 -0
- package/build/types/kit/highcharts/index.d.ts +6 -0
- package/build/types/kit/onsen/index.d.ts +8 -0
- package/build/types/kit/react-beautiful-dnd/index.d.ts +3 -0
- package/build/types/kit/react-dates/index.d.ts +5 -0
- package/build/types/kit/react-dropzone/index.d.ts +3 -0
- package/build/types/kit/react-select/index.d.ts +7 -0
- package/build/types/mobile/appcontainer/AboutDialog.d.ts +10 -0
- package/build/types/mobile/appcontainer/AppContainer.d.ts +13 -0
- package/build/types/mobile/appcontainer/Banner.d.ts +8 -0
- package/build/types/mobile/appcontainer/ExceptionDialog.d.ts +13 -0
- package/build/types/mobile/appcontainer/ExceptionDialogDetails.d.ts +7 -0
- package/build/types/mobile/appcontainer/FeedbackDialog.d.ts +6 -0
- package/build/types/mobile/appcontainer/IdlePanel.d.ts +8 -0
- package/build/types/mobile/appcontainer/ImpersonationBar.d.ts +9 -0
- package/build/types/mobile/appcontainer/LockoutPanel.d.ts +7 -0
- package/build/types/mobile/appcontainer/LoginPanel.d.ts +9 -0
- package/build/types/mobile/appcontainer/Message.d.ts +7 -0
- package/build/types/mobile/appcontainer/MessageSource.d.ts +6 -0
- package/build/types/mobile/appcontainer/OptionsDialog.d.ts +6 -0
- package/build/types/mobile/appcontainer/SuspendPanel.d.ts +6 -0
- package/build/types/mobile/appcontainer/Toast.d.ts +6 -0
- package/build/types/mobile/appcontainer/ToastSource.d.ts +7 -0
- package/build/types/mobile/appcontainer/VersionBar.d.ts +5 -0
- package/build/types/mobile/appcontainer/index.d.ts +1 -0
- package/build/types/mobile/cmp/appOption/AutoRefreshAppOption.d.ts +333 -0
- package/build/types/mobile/cmp/appOption/SizingModeAppOption.d.ts +336 -0
- package/build/types/mobile/cmp/appOption/ThemeAppOption.d.ts +333 -0
- package/build/types/mobile/cmp/appOption/index.d.ts +3 -0
- package/build/types/mobile/cmp/button/Button.d.ts +22 -0
- package/build/types/mobile/cmp/button/ButtonGroup.d.ts +13 -0
- package/build/types/mobile/cmp/button/ColAutosizeButton.d.ts +14 -0
- package/build/types/mobile/cmp/button/ColChooserButton.d.ts +15 -0
- package/build/types/mobile/cmp/button/ExpandCollapseButton.d.ts +12 -0
- package/build/types/mobile/cmp/button/FeedbackButton.d.ts +9 -0
- package/build/types/mobile/cmp/button/LogoutButton.d.ts +11 -0
- package/build/types/mobile/cmp/button/NavigatorBackButton.d.ts +8 -0
- package/build/types/mobile/cmp/button/OptionsButton.d.ts +10 -0
- package/build/types/mobile/cmp/button/RefreshButton.d.ts +13 -0
- package/build/types/mobile/cmp/button/RestoreDefaultsButton.d.ts +16 -0
- package/build/types/mobile/cmp/button/ThemeToggleButton.d.ts +8 -0
- package/build/types/mobile/cmp/button/index.d.ts +11 -0
- package/build/types/mobile/cmp/dialog/Dialog.d.ts +17 -0
- package/build/types/mobile/cmp/dialog/index.d.ts +1 -0
- package/build/types/mobile/cmp/error/ErrorMessage.d.ts +33 -0
- package/build/types/mobile/cmp/error/index.d.ts +1 -0
- package/build/types/mobile/cmp/form/FormField.d.ts +26 -0
- package/build/types/mobile/cmp/form/index.d.ts +1 -0
- package/build/types/mobile/cmp/grid/impl/ColChooser.d.ts +22 -0
- package/build/types/mobile/cmp/grid/impl/ColChooserModel.d.ts +46 -0
- package/build/types/mobile/cmp/grouping/GroupingChooser.d.ts +20 -0
- package/build/types/mobile/cmp/grouping/index.d.ts +2 -0
- package/build/types/mobile/cmp/header/AppBar.d.ts +39 -0
- package/build/types/mobile/cmp/header/AppMenuButton.d.ts +31 -0
- package/build/types/mobile/cmp/header/index.d.ts +2 -0
- package/build/types/mobile/cmp/input/ButtonGroupInput.d.ts +23 -0
- package/build/types/mobile/cmp/input/Checkbox.d.ts +14 -0
- package/build/types/mobile/cmp/input/DateInput.d.ts +53 -0
- package/build/types/mobile/cmp/input/Label.d.ts +11 -0
- package/build/types/mobile/cmp/input/NumberInput.d.ts +52 -0
- package/build/types/mobile/cmp/input/SearchInput.d.ts +24 -0
- package/build/types/mobile/cmp/input/Select.d.ts +122 -0
- package/build/types/mobile/cmp/input/SwitchInput.d.ts +14 -0
- package/build/types/mobile/cmp/input/TextArea.d.ts +22 -0
- package/build/types/mobile/cmp/input/TextInput.d.ts +39 -0
- package/build/types/mobile/cmp/input/index.d.ts +10 -0
- package/build/types/mobile/cmp/loadingindicator/LoadingIndicator.d.ts +27 -0
- package/build/types/mobile/cmp/loadingindicator/index.d.ts +1 -0
- package/build/types/mobile/cmp/mask/Mask.d.ts +25 -0
- package/build/types/mobile/cmp/mask/index.d.ts +1 -0
- package/build/types/mobile/cmp/menu/MenuButton.d.ts +21 -0
- package/build/types/mobile/cmp/menu/impl/Menu.d.ts +12 -0
- package/build/types/mobile/cmp/menu/index.d.ts +1 -0
- package/build/types/mobile/cmp/navigator/Navigator.d.ts +13 -0
- package/build/types/mobile/cmp/navigator/NavigatorModel.d.ts +55 -0
- package/build/types/mobile/cmp/navigator/PageModel.d.ts +60 -0
- package/build/types/mobile/cmp/navigator/impl/Page.d.ts +12 -0
- package/build/types/mobile/cmp/navigator/impl/swipe/BackIndicator.d.ts +6 -0
- package/build/types/mobile/cmp/navigator/impl/swipe/RefreshIndicator.d.ts +6 -0
- package/build/types/mobile/cmp/navigator/impl/swipe/Swiper.d.ts +8 -0
- package/build/types/mobile/cmp/navigator/impl/swipe/SwiperModel.d.ts +23 -0
- package/build/types/mobile/cmp/navigator/index.d.ts +2 -0
- package/build/types/mobile/cmp/panel/DialogPanel.d.ts +15 -0
- package/build/types/mobile/cmp/panel/Panel.d.ts +39 -0
- package/build/types/mobile/cmp/panel/impl/PanelHeader.d.ts +6 -0
- package/build/types/mobile/cmp/panel/index.d.ts +2 -0
- package/build/types/mobile/cmp/pinpad/impl/PinPad.d.ts +9 -0
- package/build/types/mobile/cmp/popover/Popover.d.ts +36 -0
- package/build/types/mobile/cmp/popover/index.d.ts +1 -0
- package/build/types/mobile/cmp/store/impl/StoreFilterField.d.ts +7 -0
- package/build/types/mobile/cmp/tab/impl/Tab.d.ts +13 -0
- package/build/types/mobile/cmp/tab/impl/TabContainer.d.ts +10 -0
- package/build/types/mobile/cmp/toolbar/Toolbar.d.ts +12 -0
- package/build/types/mobile/cmp/toolbar/ToolbarSeparator.d.ts +8 -0
- package/build/types/mobile/cmp/toolbar/index.d.ts +2 -0
- package/build/types/mobile/register.d.ts +1 -0
- package/build/types/mobx/decorators.d.ts +11 -0
- package/build/types/mobx/index.d.ts +5 -0
- package/build/types/mobx/overrides.d.ts +9 -0
- package/build/types/promise/Promise.d.ts +107 -0
- package/build/types/promise/index.d.ts +1 -0
- package/build/types/svc/AlertBannerService.d.ts +19 -0
- package/build/types/svc/AutoRefreshService.d.ts +28 -0
- package/build/types/svc/ChangelogService.d.ts +62 -0
- package/build/types/svc/ConfigService.d.ts +36 -0
- package/build/types/svc/EnvironmentService.d.ts +24 -0
- package/build/types/svc/FetchService.d.ts +139 -0
- package/build/types/svc/GridAutosizeService.d.ts +38 -0
- package/build/types/svc/GridExportService.d.ts +56 -0
- package/build/types/svc/IdentityService.d.ts +61 -0
- package/build/types/svc/IdleService.d.ts +21 -0
- package/build/types/svc/InspectorService.d.ts +74 -0
- package/build/types/svc/JsonBlobService.d.ts +35 -0
- package/build/types/svc/LocalStorageService.d.ts +24 -0
- package/build/types/svc/PrefService.d.ts +76 -0
- package/build/types/svc/TrackService.d.ts +15 -0
- package/build/types/svc/WebSocketService.d.ts +94 -0
- package/build/types/svc/index.d.ts +16 -0
- package/build/types/utils/async/AsyncUtils.d.ts +40 -0
- package/build/types/utils/async/Timer.d.ts +89 -0
- package/build/types/utils/async/index.d.ts +2 -0
- package/build/types/utils/datetime/DateTimeUtils.d.ts +10 -0
- package/build/types/utils/datetime/LocalDate.d.ts +94 -0
- package/build/types/utils/datetime/index.d.ts +2 -0
- package/build/types/utils/impl/Equals.d.ts +4 -0
- package/build/types/utils/impl/IsOmitted.d.ts +7 -0
- package/build/types/utils/impl/Separators.d.ts +10 -0
- package/build/types/utils/impl/TimeZone.d.ts +4 -0
- package/build/types/utils/impl/index.d.ts +4 -0
- package/build/types/utils/js/BrowserUtils.d.ts +4 -0
- package/build/types/utils/js/Decorators.d.ts +25 -0
- package/build/types/utils/js/DomUtils.d.ts +46 -0
- package/build/types/utils/js/HtmlUtils.d.ts +4 -0
- package/build/types/utils/js/LangUtils.d.ts +112 -0
- package/build/types/utils/js/LogUtils.d.ts +32 -0
- package/build/types/utils/js/VersionUtils.d.ts +17 -0
- package/build/types/utils/js/index.d.ts +7 -0
- package/build/types/utils/react/ClassName.d.ts +14 -0
- package/build/types/utils/react/Hooks.d.ts +47 -0
- package/build/types/utils/react/LayoutPropUtils.d.ts +42 -0
- package/build/types/utils/react/ObservableRef.d.ts +13 -0
- package/build/types/utils/react/ReactUtils.d.ts +19 -0
- package/build/types/utils/react/index.d.ts +5 -0
- package/package.json +2 -2
- package/tsconfig.json +14 -7
- package/tsconfig.tsbuildinfo +1 -0
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import { PlainObject } from '@xh/hoist/core';
|
|
2
|
+
import { FetchOptions } from '@xh/hoist/svc';
|
|
3
|
+
/**
|
|
4
|
+
* A Hoist optimized Javascript Error object.
|
|
5
|
+
*/
|
|
6
|
+
export interface HoistException extends Error {
|
|
7
|
+
isHoistException: true;
|
|
8
|
+
/**
|
|
9
|
+
* Is the exception an expected, normal behavior of the app?
|
|
10
|
+
*
|
|
11
|
+
* Set to true for exceptions that should not be treated or logged as technical 'errors'.
|
|
12
|
+
* (e.g. validation errors, permission errors, time-of-day errors). Default false.
|
|
13
|
+
*/
|
|
14
|
+
isRoutine: boolean;
|
|
15
|
+
[x: string]: any;
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* Exception thrown to indicate a timeout.
|
|
19
|
+
*
|
|
20
|
+
* Typically generated by the `Promise.timeout()` extension or calls to FetchService.
|
|
21
|
+
*/
|
|
22
|
+
export interface TimeoutException extends HoistException {
|
|
23
|
+
isTimeout: true;
|
|
24
|
+
/** Time in Milliseconds that was waited before exception was thrown. */
|
|
25
|
+
interval: number;
|
|
26
|
+
}
|
|
27
|
+
/**
|
|
28
|
+
* Exception thrown to indicate an HTTP error resulting from a call to FetchService.
|
|
29
|
+
*/
|
|
30
|
+
export interface FetchException extends HoistException {
|
|
31
|
+
/** Http Status code associated with exception. 0 if no response received. */
|
|
32
|
+
httpStatus: number;
|
|
33
|
+
/** Rich object or string containing details about the exception as sent by server. */
|
|
34
|
+
serverDetails: string | PlainObject;
|
|
35
|
+
/** Options of underlying fetch call. */
|
|
36
|
+
fetchOptions: FetchOptions;
|
|
37
|
+
/**
|
|
38
|
+
* True if exception resulted from the fetch being aborted by fetchService, or the application.
|
|
39
|
+
* @see FetchService.abort and FetchOptions.autoAbortKey.
|
|
40
|
+
*/
|
|
41
|
+
isFetchAborted: boolean;
|
|
42
|
+
}
|
|
43
|
+
/**
|
|
44
|
+
* Configuration for generating a timeout exception.
|
|
45
|
+
*
|
|
46
|
+
* @internal
|
|
47
|
+
*/
|
|
48
|
+
export interface TimeoutExceptionConfig extends PlainObject {
|
|
49
|
+
interval: number;
|
|
50
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { HoistServiceClass, Some } from '@xh/hoist/core';
|
|
2
|
+
/**
|
|
3
|
+
* Install HoistServices on XH.
|
|
4
|
+
*
|
|
5
|
+
* @param serviceClasses - Classes extending HoistService
|
|
6
|
+
*
|
|
7
|
+
* This method will create, initialize, and install the services classes listed on XH.
|
|
8
|
+
* All services will be initialized concurrently. To guarantee execution order of service
|
|
9
|
+
* initialization, make multiple calls to this method with await.
|
|
10
|
+
*
|
|
11
|
+
* The created service will also be set on the 'instance' property of its own class.
|
|
12
|
+
*
|
|
13
|
+
* Applications must choose a unique name of the form xxxService to avoid naming collisions on
|
|
14
|
+
* the target. If naming collisions are detected, an error will be thrown.
|
|
15
|
+
*
|
|
16
|
+
* @internal - apps should use {@link XH.installServicesAsync} instead.
|
|
17
|
+
*/
|
|
18
|
+
export declare function installServicesAsync(serviceClasses: Some<HoistServiceClass>): Promise<void>;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { HoistService, HoistModel } from './..';
|
|
2
|
+
import { Store } from '@xh/hoist/data';
|
|
3
|
+
/**
|
|
4
|
+
* Generic singleton object for cataloging global models and services.
|
|
5
|
+
* @internal
|
|
6
|
+
*/
|
|
7
|
+
declare class InstanceManager {
|
|
8
|
+
services: Set<HoistService>;
|
|
9
|
+
models: Set<HoistModel>;
|
|
10
|
+
stores: Set<Store>;
|
|
11
|
+
registerModel(m: HoistModel): void;
|
|
12
|
+
unregisterModel(m: HoistModel): void;
|
|
13
|
+
registerService(s: HoistService): void;
|
|
14
|
+
registerStore(s: Store): void;
|
|
15
|
+
unregisterStore(s: Store): void;
|
|
16
|
+
constructor();
|
|
17
|
+
}
|
|
18
|
+
export declare const instanceManager: InstanceManager;
|
|
19
|
+
export {};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generic singleton object for registering Mobile and Desktop Components and ensuring that they
|
|
3
|
+
* are never cross-imported within the same client application bundle.
|
|
4
|
+
* @internal
|
|
5
|
+
*/
|
|
6
|
+
declare class PlatformManager {
|
|
7
|
+
private mobileAPIRegistered;
|
|
8
|
+
private desktopAPIRegistered;
|
|
9
|
+
registerDesktop(): void;
|
|
10
|
+
registerMobile(): void;
|
|
11
|
+
}
|
|
12
|
+
export declare const platformManager: PlatformManager;
|
|
13
|
+
export {};
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
export * from './enums/RefreshMode';
|
|
2
|
+
export * from './enums/RenderMode';
|
|
3
|
+
export * from './enums/SizingMode';
|
|
4
|
+
export * from './types/Interfaces';
|
|
5
|
+
export * from './types/Types';
|
|
6
|
+
export * from './elem';
|
|
7
|
+
export * from './persist/';
|
|
8
|
+
export * from './TaskObserver';
|
|
9
|
+
export * from './HoistBase';
|
|
10
|
+
export * from './HoistBaseDecorators';
|
|
11
|
+
export * from './load';
|
|
12
|
+
export * from './model';
|
|
13
|
+
export * from './HoistService';
|
|
14
|
+
export * from './AppState';
|
|
15
|
+
export * from './AppSpec';
|
|
16
|
+
export * from './HoistProps';
|
|
17
|
+
export * from './HoistComponent';
|
|
18
|
+
export * from './RefreshContextView';
|
|
19
|
+
export * from './RouterModel';
|
|
20
|
+
export * from './HoistAppModel';
|
|
21
|
+
export * from './exception/ExceptionHandler';
|
|
22
|
+
export * from './exception/Exception';
|
|
23
|
+
export * from './exception/Types';
|
|
24
|
+
export { XH, XHApi } from './XH';
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import { LoadSupport } from './';
|
|
2
|
+
import { PlainObject } from '../types/Types';
|
|
3
|
+
/**
|
|
4
|
+
* Object describing a load/refresh request in Hoist.
|
|
5
|
+
*
|
|
6
|
+
* Instances of this class are created within the public APIs provided by {@link LoadSupport}
|
|
7
|
+
* and are passed to subclass (i.e. app-level) implementations of `doLoadAsync()`.
|
|
8
|
+
*
|
|
9
|
+
* Application implementations of `doLoadAsync()` can consult this object's flags. Of particular
|
|
10
|
+
* interest are {@link isStale} and {@link isObsolete}, which implementations can read after any
|
|
11
|
+
* async calls return to determine if a newer, subsequent load has already been requested.
|
|
12
|
+
*
|
|
13
|
+
* In addition, `doLoadAsync()` implementations should typically pass along this object to any
|
|
14
|
+
* calls they make to `loadAsync()` on other objects + all calls to {@link FetchService} APIs.
|
|
15
|
+
*
|
|
16
|
+
* Note that Hoist's exception handling and activity tracking will consult the {@link isAutoRefresh}
|
|
17
|
+
* flag on specs passed to their calls to automatically adjust their behavior (e.g. not showing an
|
|
18
|
+
* exception dialog on error, not tracking background refresh activity).
|
|
19
|
+
*
|
|
20
|
+
* @see LoadSupport
|
|
21
|
+
*/
|
|
22
|
+
export declare class LoadSpec {
|
|
23
|
+
get isLoadSpec(): boolean;
|
|
24
|
+
/** index of the associated load on this object. 0 for the first load. */
|
|
25
|
+
loadNumber: number;
|
|
26
|
+
/** True if triggered by a refresh request (automatic or user). */
|
|
27
|
+
isRefresh: boolean;
|
|
28
|
+
/** true if triggered by an automatic refresh process. */
|
|
29
|
+
isAutoRefresh: boolean;
|
|
30
|
+
/** Time the load started. */
|
|
31
|
+
dateCreated: Date;
|
|
32
|
+
/** Owner of this object. */
|
|
33
|
+
owner: LoadSupport;
|
|
34
|
+
/** Application specific information about the load request */
|
|
35
|
+
meta: PlainObject;
|
|
36
|
+
/** True if a more recent request to load this object's owner has *started*. */
|
|
37
|
+
get isStale(): boolean;
|
|
38
|
+
/** True if a more recent request to load this object's owner has *successfully completed*. */
|
|
39
|
+
get isObsolete(): boolean;
|
|
40
|
+
/**
|
|
41
|
+
* display type of refresh for troubleshooting and logging.
|
|
42
|
+
*/
|
|
43
|
+
get typeDisplay(): string;
|
|
44
|
+
/**
|
|
45
|
+
* Construct this object.
|
|
46
|
+
*
|
|
47
|
+
* Not for direct application use -- LoadSpecs are constructed by Hoist internally.
|
|
48
|
+
*/
|
|
49
|
+
constructor({ isRefresh, isAutoRefresh, meta, owner }: Partial<LoadSpec>);
|
|
50
|
+
}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { HoistBase, TaskObserver } from '../';
|
|
2
|
+
import { LoadSpec, Loadable } from './';
|
|
3
|
+
/**
|
|
4
|
+
* Provides support for objects that participate in Hoist's loading/refresh lifecycle.
|
|
5
|
+
*
|
|
6
|
+
* This utility is used by core Hoist classes such as {@link HoistModel} and {@link HoistService}.
|
|
7
|
+
* Model and service instances will automatically create an instance of this class if they have
|
|
8
|
+
* declared a concrete implementation of `doLoadAsync()`, signalling that they wish to take
|
|
9
|
+
* advantage of the additional tracking and management provided here.
|
|
10
|
+
*
|
|
11
|
+
* Not typically created directly by applications.
|
|
12
|
+
*/
|
|
13
|
+
export declare class LoadSupport extends HoistBase implements Loadable {
|
|
14
|
+
lastRequested: LoadSpec;
|
|
15
|
+
lastSucceeded: LoadSpec;
|
|
16
|
+
loadModel: TaskObserver;
|
|
17
|
+
lastLoadRequested: Date;
|
|
18
|
+
lastLoadCompleted: Date;
|
|
19
|
+
lastLoadException: any;
|
|
20
|
+
target: Loadable;
|
|
21
|
+
constructor(target: Loadable);
|
|
22
|
+
loadAsync(loadSpec?: LoadSpec | Partial<LoadSpec>): Promise<void>;
|
|
23
|
+
refreshAsync(meta?: object): Promise<void>;
|
|
24
|
+
autoRefreshAsync(meta?: object): Promise<void>;
|
|
25
|
+
doLoadAsync(loadSpec: LoadSpec): Promise<void>;
|
|
26
|
+
}
|
|
27
|
+
/**
|
|
28
|
+
* Load a collection of objects concurrently.
|
|
29
|
+
*
|
|
30
|
+
* Note that this method uses 'allSettled' in its implementation, meaning a failure of any one call
|
|
31
|
+
* will not cause the entire batch to throw.
|
|
32
|
+
*
|
|
33
|
+
* @param objs - list of objects to be loaded
|
|
34
|
+
* @param loadSpec - optional metadata related to this request.
|
|
35
|
+
*/
|
|
36
|
+
export declare function loadAllAsync(objs: Loadable[], loadSpec?: LoadSpec | any): Promise<PromiseSettledResult<void>[]>;
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import { TaskObserver } from '../';
|
|
2
|
+
import { LoadSpec } from './';
|
|
3
|
+
/**
|
|
4
|
+
* Interface for the primary load/refresh APIs on models and services with {@link LoadSupport}.
|
|
5
|
+
*/
|
|
6
|
+
export interface Loadable {
|
|
7
|
+
/**
|
|
8
|
+
* For tracking the loading of this object.
|
|
9
|
+
* Note that this model will *not* track auto-refreshes.
|
|
10
|
+
*/
|
|
11
|
+
loadModel: TaskObserver;
|
|
12
|
+
/** Date when last load was initiated. */
|
|
13
|
+
lastLoadRequested: Date;
|
|
14
|
+
/** Date when last load was completed. */
|
|
15
|
+
lastLoadCompleted: Date;
|
|
16
|
+
/** Any exception that occurred during last load. */
|
|
17
|
+
lastLoadException: any;
|
|
18
|
+
/**
|
|
19
|
+
* Load the target.
|
|
20
|
+
*
|
|
21
|
+
* This method is the main public entry point for this interface and is responsible for
|
|
22
|
+
* calling the objects `doLoadAsync()` implementation. See also `refreshAsync()` and
|
|
23
|
+
* `autoRefreshAsync()` for convenience variants of this method.
|
|
24
|
+
*
|
|
25
|
+
* @param loadSpec - a {@link LoadSpec}, or an object containing properties to create one.
|
|
26
|
+
*/
|
|
27
|
+
loadAsync(loadSpec?: LoadSpec | Partial<LoadSpec>): Promise<void>;
|
|
28
|
+
/**
|
|
29
|
+
* Refresh the target.
|
|
30
|
+
* @param meta - optional metadata for the request.
|
|
31
|
+
*/
|
|
32
|
+
refreshAsync(meta?: object): Promise<void>;
|
|
33
|
+
/**
|
|
34
|
+
* Auto-refresh the target.
|
|
35
|
+
* @param meta - optional metadata for the request.
|
|
36
|
+
*/
|
|
37
|
+
autoRefreshAsync(meta?: object): Promise<void>;
|
|
38
|
+
/**
|
|
39
|
+
* Implement this method to load data or other state from external data sources or services.
|
|
40
|
+
* This is a template method - callers should call `loadAsync()` or `refreshAsync()` instead.
|
|
41
|
+
*
|
|
42
|
+
* @param loadSpec - metadata about the underlying request. Implementations should
|
|
43
|
+
* take care to pass this parameter in calls to any delegates that support it, e.g.
|
|
44
|
+
* when calling the `loadAsync()` method of other services or child models with
|
|
45
|
+
* `loadSupport` or when making calls to {@link FetchService} APIs.
|
|
46
|
+
*/
|
|
47
|
+
doLoadAsync(loadSpec: LoadSpec): Promise<void>;
|
|
48
|
+
}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { Thunkable } from './../types/Types';
|
|
2
|
+
import { HoistModel, HoistModelClass, ModelPublishMode } from './';
|
|
3
|
+
/**
|
|
4
|
+
* Returns a ModelSpec to define how a functional HoistComponent should create its primary backing
|
|
5
|
+
* HoistModel. Use this option when your component will create its own model internally, and does
|
|
6
|
+
* *not* expect one to be provided via props or context.
|
|
7
|
+
*
|
|
8
|
+
* The constructed model instance will be provided to the component via props and placed in context
|
|
9
|
+
* for access by all subcomponents.
|
|
10
|
+
*
|
|
11
|
+
* The model created will be considered to be 'owned' by the receiving component. If it implements
|
|
12
|
+
* loading it will be loaded on component mount, and it will always be destroyed on
|
|
13
|
+
* component unmount.
|
|
14
|
+
*
|
|
15
|
+
* @param spec - HoistModel Class to construct, or a function returning a concrete HoistModel instance.
|
|
16
|
+
* @param opts - additional options
|
|
17
|
+
*/
|
|
18
|
+
export declare function creates<T extends HoistModel>(spec: Thunkable<HoistModelClass<T>> | (() => T), opts?: CreatesOptions): CreatesSpec<T>;
|
|
19
|
+
export interface CreatesOptions {
|
|
20
|
+
/** Mode for publishing this model to context. */
|
|
21
|
+
publishMode?: ModelPublishMode;
|
|
22
|
+
}
|
|
23
|
+
export declare class CreatesSpec<T extends HoistModel> {
|
|
24
|
+
fromContext: boolean;
|
|
25
|
+
optional: boolean;
|
|
26
|
+
publishMode: ModelPublishMode;
|
|
27
|
+
createFn: () => T;
|
|
28
|
+
constructor(spec: any, publishMode: ModelPublishMode);
|
|
29
|
+
}
|
|
@@ -0,0 +1,121 @@
|
|
|
1
|
+
import { DefaultHoistProps, HoistBase, PlainObject } from '../';
|
|
2
|
+
import { ModelSelector } from './';
|
|
3
|
+
import { LoadSupport, LoadSpec, Loadable } from '../load';
|
|
4
|
+
/**
|
|
5
|
+
* Core superclass for stateful Models in Hoist. Models are used throughout the toolkit and
|
|
6
|
+
* applications as backing stores for components and as general all-purpose constructs for
|
|
7
|
+
* loading, storing, processing, and observing business data and other application state.
|
|
8
|
+
*
|
|
9
|
+
* The most common use of `HoistModel` is to support Hoist components. Components can be configured
|
|
10
|
+
* to create or lookup an instance of an appropriate model subclass using the `model` config passed
|
|
11
|
+
* to {@link hoistComponent.factory}. Hoist will automatically pass the resolved model instance as a
|
|
12
|
+
* prop to the component's `render()` function, where the model's properties can be read/rendered
|
|
13
|
+
* and any imperative APIs wired to buttons, callbacks, and other handlers.
|
|
14
|
+
*
|
|
15
|
+
* Certain models are instantiated by Hoist and linked directly in a one-to-one relationship with
|
|
16
|
+
* a specific component that renders them. These models are considered "linked", and they play a
|
|
17
|
+
* special role in the framework. In particular, linked models:
|
|
18
|
+
* - are specified by the {@link creates} directive as well as the {@link useLocalModel} hook.
|
|
19
|
+
* - support an observable {@link componentProps} property which can be used to observe the
|
|
20
|
+
* props of their associated component.
|
|
21
|
+
* - support a {@link lookupModel} method and a `@lookup` decorator that can be used to acquire
|
|
22
|
+
* references to "ancestors" to this model in the component hierarchy.
|
|
23
|
+
* - support {@link onLinked} and {@link afterLinked} lifecycle methods, called during the
|
|
24
|
+
* first rendering of their associated component. Use these methods for any work requiring the
|
|
25
|
+
* availability of lookups or `componentProps`.
|
|
26
|
+
* - have `loadAsync()` called automatically when their component is first mounted, as well
|
|
27
|
+
* as register themselves for subsequent refreshes with the nearest {@link RefreshContextModel}
|
|
28
|
+
* in the component hierarchy.
|
|
29
|
+
* - are destroyed when their linked component is unmounted.
|
|
30
|
+
*
|
|
31
|
+
* It is very common to decorate properties on models with `@observable` and related field-level
|
|
32
|
+
* annotations. This enables automatic, MobX-powered re-rendering of components when these model
|
|
33
|
+
* properties change, or when specific reactions have been wired by the developer via
|
|
34
|
+
* `addReaction()` and related utils from {@link HoistBase}.
|
|
35
|
+
*
|
|
36
|
+
* When declaring any observable properties on your model class, note that you **must** call
|
|
37
|
+
* `makeObservable(this)` within your model's constructor in order for MobX to begin tracking your
|
|
38
|
+
* observables and reacting to changes.
|
|
39
|
+
*
|
|
40
|
+
* HoistModels that need to load or refresh their state from any external source (e.g. a remote
|
|
41
|
+
* API or local service call) are encouraged to implement the abstract `doLoadAsync()` method
|
|
42
|
+
* defined on this superclass. This will trigger the installation of a {@link LoadSupport} instance
|
|
43
|
+
* on the model and enable several extensions to help track and manage async loads via the model's
|
|
44
|
+
* public `loadAsync()` entry point.
|
|
45
|
+
*/
|
|
46
|
+
export declare abstract class HoistModel extends HoistBase implements Loadable {
|
|
47
|
+
/** Type for constructing an instance of this model */
|
|
48
|
+
config: unknown;
|
|
49
|
+
static get isHoistModel(): boolean;
|
|
50
|
+
get isHoistModel(): boolean;
|
|
51
|
+
_componentProps: {};
|
|
52
|
+
_modelLookup: any;
|
|
53
|
+
_created: () => number;
|
|
54
|
+
constructor();
|
|
55
|
+
/**
|
|
56
|
+
* Provides optional support for Hoist's approach to managed loading.
|
|
57
|
+
*
|
|
58
|
+
* Applications will not typically need to access this object directly. If a subclass
|
|
59
|
+
* declares a concrete implementation of the `doLoadAsync()` template method, an instance of
|
|
60
|
+
* `LoadSupport` will automatically be created and installed to support the extensions below.
|
|
61
|
+
*
|
|
62
|
+
* See the class-level comments above for additional details.
|
|
63
|
+
*/
|
|
64
|
+
loadSupport: LoadSupport;
|
|
65
|
+
get loadModel(): import("../TaskObserver").TaskObserver;
|
|
66
|
+
get lastLoadRequested(): Date;
|
|
67
|
+
get lastLoadCompleted(): Date;
|
|
68
|
+
get lastLoadException(): any;
|
|
69
|
+
refreshAsync(meta?: PlainObject): Promise<void>;
|
|
70
|
+
autoRefreshAsync(meta?: PlainObject): Promise<void>;
|
|
71
|
+
doLoadAsync(loadSpec: LoadSpec): Promise<void>;
|
|
72
|
+
loadAsync(loadSpec?: LoadSpec | Partial<LoadSpec>): Promise<void>;
|
|
73
|
+
get isLinked(): boolean;
|
|
74
|
+
/**
|
|
75
|
+
* React props on component linked to this model.
|
|
76
|
+
*
|
|
77
|
+
* Only available for linked models.
|
|
78
|
+
*
|
|
79
|
+
* Observability is based on a shallow computation for each prop (i.e. a reference
|
|
80
|
+
* change in any particular prop will trigger observers to be notified).
|
|
81
|
+
*/
|
|
82
|
+
get componentProps(): DefaultHoistProps;
|
|
83
|
+
/**
|
|
84
|
+
* Called during first render of the component linked to this model.
|
|
85
|
+
*
|
|
86
|
+
* Only available for linked models.
|
|
87
|
+
*
|
|
88
|
+
* This method will be called when this model has been fully linked to the component
|
|
89
|
+
* hierarchy. Use this method for any work requiring the availability of lookup models or
|
|
90
|
+
* componentProps. Note that this method is called *during* the initial rendering of the
|
|
91
|
+
* linked component. See also `afterLinked` for a version of this method, that will be called
|
|
92
|
+
* after the first render is complete.
|
|
93
|
+
*/
|
|
94
|
+
onLinked(): void;
|
|
95
|
+
/**
|
|
96
|
+
* Called after first render of the component linked to this model.
|
|
97
|
+
*
|
|
98
|
+
* Only available for linked models.
|
|
99
|
+
*
|
|
100
|
+
* This method is similar to `onLinked`, however it will be called after rendering has completed
|
|
101
|
+
* using the native react `useEffect` hook.
|
|
102
|
+
*/
|
|
103
|
+
afterLinked(): void;
|
|
104
|
+
/**
|
|
105
|
+
* Lookup an ancestor model in the context hierarchy.
|
|
106
|
+
*
|
|
107
|
+
* Only available for linked models.
|
|
108
|
+
*
|
|
109
|
+
* @param selector - type of model to lookup.
|
|
110
|
+
* @returns model, or null if no matching model found.
|
|
111
|
+
*/
|
|
112
|
+
lookupModel<T extends HoistModel>(selector: ModelSelector<T>): T;
|
|
113
|
+
/** @internal */
|
|
114
|
+
setComponentProps(newProps: any): void;
|
|
115
|
+
/** @internal */
|
|
116
|
+
matchesSelector(selector: ModelSelector, acceptWildcard?: boolean): boolean;
|
|
117
|
+
destroy(): void;
|
|
118
|
+
}
|
|
119
|
+
export interface HoistModelClass<T extends HoistModel> extends Function {
|
|
120
|
+
prototype: T;
|
|
121
|
+
}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { HoistModel, HoistModelClass, ModelSelector, ModelLookup } from './';
|
|
2
|
+
/**
|
|
3
|
+
* Hook to allow a component to access a HoistModel provided in context by an ancestor component.
|
|
4
|
+
* @param selector - selector to identify the model to be returned.
|
|
5
|
+
* @returns model or null if no matching model found.
|
|
6
|
+
*/
|
|
7
|
+
export declare function useContextModel<T extends HoistModel>(selector?: ModelSelector<T>): T;
|
|
8
|
+
/**
|
|
9
|
+
* Create a new model that will be maintained for lifetime of the component and destroyed when the
|
|
10
|
+
* component is unmounted.
|
|
11
|
+
* @param spec - class of HoistModel to create, or a function returning one.
|
|
12
|
+
*/
|
|
13
|
+
export declare function useLocalModel<T extends HoistModel>(spec?: HoistModelClass<T> | (() => T)): T;
|
|
14
|
+
/**
|
|
15
|
+
* Integrate a HoistModel owned by a component into the component's lifecycle, enabling support for
|
|
16
|
+
* both the Loading lifecycle and destruction. No-op, if model is null.
|
|
17
|
+
* @internal
|
|
18
|
+
*/
|
|
19
|
+
export declare function useModelLinker(model: HoistModel, modelLookup: ModelLookup, props: object): void;
|
|
20
|
+
/**
|
|
21
|
+
* Default Context for useLocalModel.
|
|
22
|
+
* Set by HoistComponent during render to minimize app boilerplate required.
|
|
23
|
+
* @internal
|
|
24
|
+
*/
|
|
25
|
+
export declare const localModelContext: {
|
|
26
|
+
modelLookup: any;
|
|
27
|
+
props: any;
|
|
28
|
+
};
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { Loadable, LoadSpec } from '../load';
|
|
2
|
+
import { RefreshContextModel } from './';
|
|
3
|
+
import { RefreshMode } from '../';
|
|
4
|
+
export type ManagedRefreshTarget = Loadable & {
|
|
5
|
+
isActive: boolean;
|
|
6
|
+
refreshMode: RefreshMode;
|
|
7
|
+
};
|
|
8
|
+
/**
|
|
9
|
+
* A refresh context model that consults a model's RefreshMode and active state to manage
|
|
10
|
+
* refreshes of its target models.
|
|
11
|
+
*
|
|
12
|
+
* The associated Loadable must have both:
|
|
13
|
+
* a) An observable `isActive` property, that returns a boolean value.
|
|
14
|
+
* b) A `refreshMode` property, that returns a RefreshMode enum value.
|
|
15
|
+
*/
|
|
16
|
+
export declare class ManagedRefreshContextModel extends RefreshContextModel {
|
|
17
|
+
xhImpl: boolean;
|
|
18
|
+
model: ManagedRefreshTarget;
|
|
19
|
+
refreshPending: boolean;
|
|
20
|
+
constructor(model: ManagedRefreshTarget);
|
|
21
|
+
doLoadAsync(loadSpec: LoadSpec): Promise<void>;
|
|
22
|
+
noteActiveChanged(isActive: boolean): void;
|
|
23
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { ModelSelector, HoistModel, ModelPublishMode } from './..';
|
|
3
|
+
/**
|
|
4
|
+
* Support for making models available to components via React context.
|
|
5
|
+
*
|
|
6
|
+
* Not created directly by applications. Components specify how/if they publish/source their
|
|
7
|
+
* models from context via the `model` config option passed into the `hoistCmp()` factory.
|
|
8
|
+
* Hoist will in turn create and manage instances of this class to power those links.
|
|
9
|
+
*
|
|
10
|
+
* @internal
|
|
11
|
+
*/
|
|
12
|
+
export declare class ModelLookup {
|
|
13
|
+
model: HoistModel;
|
|
14
|
+
parent: ModelLookup;
|
|
15
|
+
publishMode: ModelPublishMode;
|
|
16
|
+
constructor(model: HoistModel, parent: ModelLookup, publishMode: ModelPublishMode);
|
|
17
|
+
/**
|
|
18
|
+
* Lookup a model in the context hierarchy
|
|
19
|
+
* @returns model, or null if no matching model found.
|
|
20
|
+
*/
|
|
21
|
+
lookupModel(selector: ModelSelector): HoistModel;
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* Context used to publish a ModelLookup
|
|
25
|
+
*/
|
|
26
|
+
export declare const ModelLookupContext: import("react").Context<any>;
|
|
27
|
+
export declare const modelLookupContextProvider: import("./..").ElementFactory<any>;
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { HoistModel, HoistModelClass } from './';
|
|
2
|
+
/**
|
|
3
|
+
* Type for use in identifying a model or set of models. May be one of:
|
|
4
|
+
*
|
|
5
|
+
* - class (or superclass) to match
|
|
6
|
+
* - class name (as a string)
|
|
7
|
+
* - `"*"` to accept any Model
|
|
8
|
+
* - boolean
|
|
9
|
+
* - function taking a model and returning any of the above.
|
|
10
|
+
*/
|
|
11
|
+
export type ModelSelector<T extends HoistModel = HoistModel> = HoistModelClass<T> | string | boolean | ((model: HoistModel) => ModelSelector<T>);
|
|
12
|
+
/**
|
|
13
|
+
* Ensure an object is a ModelSelector, or throw.
|
|
14
|
+
*/
|
|
15
|
+
export declare function ensureIsSelector(s: any): void;
|
|
16
|
+
/**
|
|
17
|
+
* Format a ModelSelector for debugging purposes.
|
|
18
|
+
*/
|
|
19
|
+
export declare function formatSelector(selector: ModelSelector): string;
|
|
20
|
+
/**
|
|
21
|
+
* Parameterized decorator to inject an instance of an ancestor model in the Model lookup
|
|
22
|
+
* hierarchy into this object.
|
|
23
|
+
*
|
|
24
|
+
* The decorated property will be filled only when the Model is linked to the Component hierarchy.
|
|
25
|
+
* Accessing properties decorated with `@lookup` should first be done in the
|
|
26
|
+
* {@link HoistModel.onLinked} or {@link HoistModel.afterLinked} handlers.
|
|
27
|
+
*/
|
|
28
|
+
export declare const lookup: any;
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { CreatesSpec, UsesSpec, HoistModel } from './';
|
|
2
|
+
/**
|
|
3
|
+
* Specification for model to be rendered by a HoistComponent.
|
|
4
|
+
* See {@link uses} and {@link creates} for standard factories that produce instances of this type.
|
|
5
|
+
* @internal
|
|
6
|
+
*/
|
|
7
|
+
export type ModelSpec<T extends HoistModel = HoistModel> = CreatesSpec<T> | UsesSpec<T>;
|
|
8
|
+
/**
|
|
9
|
+
* Options for how a Model should be published to context.
|
|
10
|
+
*/
|
|
11
|
+
export declare const ModelPublishMode: Readonly<{
|
|
12
|
+
/**
|
|
13
|
+
* Model may be looked up from context using wildcard ('*') and model's top-level
|
|
14
|
+
* properties will also be searched for an appropriate model during lookup. This is the
|
|
15
|
+
* default mode and typical mode used by application models.
|
|
16
|
+
*/
|
|
17
|
+
DEFAULT: "default";
|
|
18
|
+
/**
|
|
19
|
+
* Model may be looked up via context using an explicit selector, but NOT wildcard (*).
|
|
20
|
+
* Model's internal properties will never be searched for matching models during lookup.
|
|
21
|
+
* Useful for component or toolkit models that should be available for querying via context,
|
|
22
|
+
* but are not intended to serve as default models or model providers.
|
|
23
|
+
*/
|
|
24
|
+
LIMITED: "limited";
|
|
25
|
+
/**
|
|
26
|
+
* Do not publish the model to context.
|
|
27
|
+
*/
|
|
28
|
+
NONE: "none";
|
|
29
|
+
}>;
|
|
30
|
+
export type ModelPublishMode = (typeof ModelPublishMode)[keyof typeof ModelPublishMode];
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import { HoistModel } from './';
|
|
2
|
+
import { LoadSpec, Loadable } from '../load';
|
|
3
|
+
/**
|
|
4
|
+
* A model to manage refreshing sections of the application, where "refreshing" refers to app-
|
|
5
|
+
* specific actions to load and display updated data. Calling `refreshAsync()` on this model will
|
|
6
|
+
* refresh all linked models underneath its corresponding component hierarchy.
|
|
7
|
+
*
|
|
8
|
+
* An instance of this class is provided by the framework as `XH.refreshContextModel` and
|
|
9
|
+
* installed at the top level of the application's component hierarchy, allowing for an "app-wide"
|
|
10
|
+
* refresh trigger via `XH.refreshAppAsync()`.
|
|
11
|
+
*
|
|
12
|
+
* Apps can create additional sub-contexts using a `RefreshContextView` paired with this model if
|
|
13
|
+
* they need to coordinate refreshes within a more targeted sections of their UI.
|
|
14
|
+
*
|
|
15
|
+
* HoistModels that enable LoadSupport are the primary targets for the refresh calls made by this
|
|
16
|
+
* class. Such models are auto-linked to the nearest RefreshContextModel when their associated
|
|
17
|
+
* component is mounted.
|
|
18
|
+
*
|
|
19
|
+
* (Note that models must be "owned" by their Component to be auto-linked in this way - meaning they
|
|
20
|
+
* must be internally created by the Component, either directly or from a config passed via props.)
|
|
21
|
+
*
|
|
22
|
+
* Note that TabContainer automatically establishes separate refresh contexts for its tabs and uses
|
|
23
|
+
* these to implement efficient refresh handling of inactive and not-yet-rendered tabs. See the
|
|
24
|
+
* `refreshMode` configs on `TabContainerModel` and `TabModel` for more information on this common
|
|
25
|
+
* use case.
|
|
26
|
+
*
|
|
27
|
+
* @see RootRefreshContextModel
|
|
28
|
+
* @see HoistModel.loadSupport
|
|
29
|
+
*/
|
|
30
|
+
export declare class RefreshContextModel extends HoistModel {
|
|
31
|
+
/** Targets registered for refresh. */
|
|
32
|
+
refreshTargets: Loadable[];
|
|
33
|
+
/**
|
|
34
|
+
* Register a target with this model for refreshing.
|
|
35
|
+
*
|
|
36
|
+
* Not typically called directly by applications. Hoist will automatically register
|
|
37
|
+
* HoistModels that implement loading when their owning Component is first mounted.
|
|
38
|
+
*/
|
|
39
|
+
register(target: Loadable): void;
|
|
40
|
+
/**
|
|
41
|
+
* Unregister a target from this model.
|
|
42
|
+
*/
|
|
43
|
+
unregister(target: Loadable): void;
|
|
44
|
+
doLoadAsync(loadSpec: LoadSpec): Promise<void>;
|
|
45
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { LoadSpec } from '../load';
|
|
2
|
+
import { RefreshContextModel } from './';
|
|
3
|
+
/**
|
|
4
|
+
* Top-level refresh context model - triggers a full refresh of the app via a call to `loadAsync()`
|
|
5
|
+
* on the AppModel, followed by refreshes of any target models within the component hierarchy.
|
|
6
|
+
*
|
|
7
|
+
* An instance of this object is installed and linked by the framework as `XH.refreshContextModel`
|
|
8
|
+
* and should *not* be created or managed by application code.
|
|
9
|
+
*
|
|
10
|
+
* The `XH.refreshAppAsync()` convenience method is the recommended entry-point for apps to call.
|
|
11
|
+
*/
|
|
12
|
+
export declare class RootRefreshContextModel extends RefreshContextModel {
|
|
13
|
+
doLoadAsync(loadSpec: LoadSpec): Promise<void>;
|
|
14
|
+
}
|