@singularsystems/neo-react 1.0.0-alpha.3 → 1.0.0-beta.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.
Files changed (200) hide show
  1. package/CHANGELOG.md +98 -0
  2. package/README.md +4 -0
  3. package/dist/Modules/NeoReactModule.d.ts +4 -4
  4. package/dist/Modules/NeoReactModule.js +28 -26
  5. package/dist/Modules/ReactSetup.d.ts +2 -2
  6. package/dist/Modules/ReactSetup.js +17 -17
  7. package/dist/Modules/Types.d.ts +63 -61
  8. package/dist/Modules/Types.js +13 -12
  9. package/dist/React/AutoRunner.d.ts +5 -5
  10. package/dist/React/AutoRunner.js +94 -92
  11. package/dist/React/DataView.d.ts +6 -6
  12. package/dist/React/DataView.js +11 -11
  13. package/dist/React/ReactModelCreator.d.ts +11 -11
  14. package/dist/React/ReactModelCreator.js +165 -162
  15. package/dist/ReactComponents/Button.d.ts +24 -23
  16. package/dist/ReactComponents/Button.js +132 -123
  17. package/dist/ReactComponents/Card.d.ts +24 -23
  18. package/dist/ReactComponents/Card.js +57 -54
  19. package/dist/ReactComponents/Collapsable.d.ts +23 -23
  20. package/dist/ReactComponents/Collapsable.js +38 -38
  21. package/dist/ReactComponents/CollapsableBase.d.ts +13 -13
  22. package/dist/ReactComponents/CollapsableBase.js +42 -42
  23. package/dist/ReactComponents/ColorPicker.d.ts +26 -26
  24. package/dist/ReactComponents/ColorPicker.js +67 -67
  25. package/dist/ReactComponents/ComponentBase.d.ts +17 -17
  26. package/dist/ReactComponents/ComponentBase.js +33 -33
  27. package/dist/ReactComponents/ContextMenu/ContextMenu.d.ts +25 -24
  28. package/dist/ReactComponents/ContextMenu/ContextMenu.js +91 -89
  29. package/dist/ReactComponents/ContextMenu/ContextMenuContainer.d.ts +14 -14
  30. package/dist/ReactComponents/ContextMenu/ContextMenuContainer.js +48 -48
  31. package/dist/ReactComponents/ContextMenu/ContextMenuState.d.ts +8 -8
  32. package/dist/ReactComponents/ContextMenu/ContextMenuState.js +23 -24
  33. package/dist/ReactComponents/DatePicker.d.ts +20 -19
  34. package/dist/ReactComponents/DatePicker.js +57 -53
  35. package/dist/ReactComponents/DropDown/AutoCompleteDropDown.d.ts +97 -83
  36. package/dist/ReactComponents/DropDown/AutoCompleteDropDown.js +225 -188
  37. package/dist/ReactComponents/DropDown/DropDown.d.ts +44 -44
  38. package/dist/ReactComponents/DropDown/DropDown.js +138 -134
  39. package/dist/ReactComponents/DropDown/DropDownBase.d.ts +16 -15
  40. package/dist/ReactComponents/DropDown/DropDownBase.js +86 -108
  41. package/dist/ReactComponents/DropDown/LookupHelper.d.ts +13 -0
  42. package/dist/ReactComponents/DropDown/LookupHelper.js +45 -0
  43. package/dist/ReactComponents/ErrorHandler.d.ts +9 -9
  44. package/dist/ReactComponents/ErrorHandler.js +92 -93
  45. package/dist/ReactComponents/FileManager/FileBasicInput.d.ts +20 -20
  46. package/dist/ReactComponents/FileManager/FileBasicInput.js +70 -70
  47. package/dist/ReactComponents/FileManager/FileContext.d.ts +16 -16
  48. package/dist/ReactComponents/FileManager/FileContext.js +24 -24
  49. package/dist/ReactComponents/FileManager/FileDropArea.d.ts +19 -19
  50. package/dist/ReactComponents/FileManager/FileDropArea.js +66 -66
  51. package/dist/ReactComponents/FileManager/FileInput.d.ts +44 -43
  52. package/dist/ReactComponents/FileManager/FileInput.js +191 -191
  53. package/dist/ReactComponents/FileManager/FileUploadButton.d.ts +17 -17
  54. package/dist/ReactComponents/FileManager/FileUploadButton.js +49 -49
  55. package/dist/ReactComponents/FileManager/FileUploadProgress.d.ts +14 -14
  56. package/dist/ReactComponents/FileManager/FileUploadProgress.js +35 -35
  57. package/dist/ReactComponents/Form.d.ts +19 -19
  58. package/dist/ReactComponents/Form.js +90 -90
  59. package/dist/ReactComponents/FormContext.d.ts +33 -33
  60. package/dist/ReactComponents/FormContext.js +39 -40
  61. package/dist/ReactComponents/FormGroup/FormGroup.d.ts +37 -37
  62. package/dist/ReactComponents/FormGroup/FormGroup.js +83 -84
  63. package/dist/ReactComponents/FormGroup/FormGroupFloating.d.ts +19 -19
  64. package/dist/ReactComponents/FormGroup/FormGroupFloating.js +97 -97
  65. package/dist/ReactComponents/FormGroup/FormGroupInline.d.ts +11 -11
  66. package/dist/ReactComponents/FormGroup/FormGroupInline.js +43 -43
  67. package/dist/ReactComponents/Grid/ButtonColumn.d.ts +48 -47
  68. package/dist/ReactComponents/Grid/ButtonColumn.js +81 -82
  69. package/dist/ReactComponents/Grid/Column.d.ts +47 -47
  70. package/dist/ReactComponents/Grid/Column.js +205 -205
  71. package/dist/ReactComponents/Grid/ColumnHelper.d.ts +12 -12
  72. package/dist/ReactComponents/Grid/ColumnHelper.js +19 -19
  73. package/dist/ReactComponents/Grid/Grid.d.ts +95 -87
  74. package/dist/ReactComponents/Grid/Grid.js +218 -203
  75. package/dist/ReactComponents/Grid/Row.d.ts +81 -81
  76. package/dist/ReactComponents/Grid/Row.js +200 -202
  77. package/dist/ReactComponents/Grid/StickyTableHeader.d.ts +27 -0
  78. package/dist/ReactComponents/Grid/StickyTableHeader.js +107 -0
  79. package/dist/ReactComponents/Grid/_Exports.d.ts +5 -5
  80. package/dist/ReactComponents/Grid/_Exports.js +5 -5
  81. package/dist/ReactComponents/GridLayout.d.ts +20 -20
  82. package/dist/ReactComponents/GridLayout.js +38 -38
  83. package/dist/ReactComponents/Icons/FontAwesomeIconFactory.d.ts +23 -0
  84. package/dist/ReactComponents/Icons/FontAwesomeIconFactory.js +43 -0
  85. package/dist/ReactComponents/Icons/IIconFactory.d.ts +21 -0
  86. package/dist/ReactComponents/Icons/IIconFactory.js +1 -0
  87. package/dist/ReactComponents/Icons/IconFactory.d.ts +9 -0
  88. package/dist/ReactComponents/Icons/IconFactory.js +45 -0
  89. package/dist/ReactComponents/Icons/index.d.ts +3 -0
  90. package/dist/ReactComponents/Icons/index.js +2 -0
  91. package/dist/ReactComponents/Input.d.ts +45 -45
  92. package/dist/ReactComponents/Input.js +153 -153
  93. package/dist/ReactComponents/InputHelpers.d.ts +6 -5
  94. package/dist/ReactComponents/InputHelpers.js +29 -33
  95. package/dist/ReactComponents/Link.d.ts +13 -13
  96. package/dist/ReactComponents/Link.js +28 -28
  97. package/dist/ReactComponents/Loader.d.ts +18 -18
  98. package/dist/ReactComponents/Loader.js +57 -57
  99. package/dist/ReactComponents/Misc.d.ts +15 -15
  100. package/dist/ReactComponents/Misc.js +28 -28
  101. package/dist/ReactComponents/Modal/Modal.d.ts +11 -11
  102. package/dist/ReactComponents/Modal/Modal.js +133 -129
  103. package/dist/ReactComponents/Modal/ModalContainer.d.ts +17 -17
  104. package/dist/ReactComponents/Modal/ModalContainer.js +37 -37
  105. package/dist/ReactComponents/Modal/ModalPortal.d.ts +16 -16
  106. package/dist/ReactComponents/Modal/ModalPortal.js +27 -27
  107. package/dist/ReactComponents/Notifications/Alert.d.ts +7 -6
  108. package/dist/ReactComponents/Notifications/Alert.js +38 -35
  109. package/dist/ReactComponents/Notifications/Toast.d.ts +9 -8
  110. package/dist/ReactComponents/Notifications/Toast.js +47 -45
  111. package/dist/ReactComponents/Notifications/ToastContainer.d.ts +8 -8
  112. package/dist/ReactComponents/Notifications/ToastContainer.js +18 -18
  113. package/dist/ReactComponents/NumberInput.d.ts +57 -50
  114. package/dist/ReactComponents/NumberInput.js +267 -246
  115. package/dist/ReactComponents/Paging/BasicPagerControls.d.ts +26 -25
  116. package/dist/ReactComponents/Paging/BasicPagerControls.js +57 -55
  117. package/dist/ReactComponents/Paging/PageSizeControl.d.ts +11 -11
  118. package/dist/ReactComponents/Paging/PageSizeControl.js +21 -21
  119. package/dist/ReactComponents/Paging/Pager.d.ts +24 -24
  120. package/dist/ReactComponents/Paging/Pager.js +41 -41
  121. package/dist/ReactComponents/ProgressBar.d.ts +19 -19
  122. package/dist/ReactComponents/ProgressBar.js +52 -52
  123. package/dist/ReactComponents/PropTypes.d.ts +154 -161
  124. package/dist/ReactComponents/PropTypes.js +263 -236
  125. package/dist/ReactComponents/RadioList.d.ts +29 -29
  126. package/dist/ReactComponents/RadioList.js +59 -77
  127. package/dist/ReactComponents/Slider.d.ts +28 -28
  128. package/dist/ReactComponents/Slider.js +76 -76
  129. package/dist/ReactComponents/StateObserver.d.ts +15 -15
  130. package/dist/ReactComponents/StateObserver.js +35 -35
  131. package/dist/ReactComponents/Tabs/Tab.d.ts +42 -41
  132. package/dist/ReactComponents/Tabs/Tab.js +71 -72
  133. package/dist/ReactComponents/Tabs/TabContainer.d.ts +44 -44
  134. package/dist/ReactComponents/Tabs/TabContainer.js +98 -98
  135. package/dist/ReactComponents/Tabs/TabManager.d.ts +62 -62
  136. package/dist/ReactComponents/Tabs/TabManager.js +154 -154
  137. package/dist/ReactComponents/Tooltip.d.ts +20 -20
  138. package/dist/ReactComponents/Tooltip.js +51 -51
  139. package/dist/ReactComponents/TooltipHelper.d.ts +8 -8
  140. package/dist/ReactComponents/TooltipHelper.js +84 -84
  141. package/dist/ReactComponents/TooltipProvider.d.ts +30 -30
  142. package/dist/ReactComponents/TooltipProvider.js +111 -111
  143. package/dist/ReactComponents/ValidationSummary.d.ts +23 -22
  144. package/dist/ReactComponents/ValidationSummary.js +46 -43
  145. package/dist/ReactComponents/_Exports.d.ts +41 -41
  146. package/dist/ReactComponents/_Exports.js +41 -41
  147. package/dist/ReactComponents/_Managers.d.ts +4 -4
  148. package/dist/ReactComponents/_Managers.js +4 -4
  149. package/dist/Routing/BreadCrumbItem.d.ts +14 -14
  150. package/dist/Routing/BreadCrumbItem.js +12 -12
  151. package/dist/Routing/IRouteChangedProps.d.ts +31 -31
  152. package/dist/Routing/IRouteChangedProps.js +1 -1
  153. package/dist/Routing/IRouteParameter.d.ts +22 -22
  154. package/dist/Routing/IRouteParameter.js +9 -9
  155. package/dist/Routing/MenuRoute.d.ts +25 -24
  156. package/dist/Routing/MenuRoute.js +24 -24
  157. package/dist/Routing/NavigationHelper.d.ts +41 -40
  158. package/dist/Routing/NavigationHelper.js +61 -61
  159. package/dist/Routing/PageLeaveHandler.d.ts +13 -13
  160. package/dist/Routing/PageLeaveHandler.js +74 -75
  161. package/dist/Routing/RouteProvider.d.ts +31 -31
  162. package/dist/Routing/RouteProvider.js +92 -92
  163. package/dist/Routing/RouteView.d.ts +50 -50
  164. package/dist/Routing/RouteView.js +143 -143
  165. package/dist/Routing/RoutingState.d.ts +18 -18
  166. package/dist/Routing/RoutingState.js +45 -46
  167. package/dist/Routing/ViewParameter.d.ts +80 -58
  168. package/dist/Routing/ViewParameter.js +116 -96
  169. package/dist/Routing/ViewParameterList.d.ts +53 -53
  170. package/dist/Routing/ViewParameterList.js +163 -145
  171. package/dist/Routing/index.d.ts +9 -9
  172. package/dist/Routing/index.js +6 -6
  173. package/dist/Services/DisposeHelper.d.ts +15 -15
  174. package/dist/Services/DisposeHelper.js +40 -41
  175. package/dist/Services/IDisposeHelper.d.ts +12 -12
  176. package/dist/Services/IDisposeHelper.js +1 -1
  177. package/dist/Views/EmptyViewModel.d.ts +5 -5
  178. package/dist/Views/EmptyViewModel.js +14 -14
  179. package/dist/Views/IViewModel.d.ts +16 -16
  180. package/dist/Views/IViewModel.js +1 -1
  181. package/dist/Views/PersistentViewBase.d.ts +10 -10
  182. package/dist/Views/PersistentViewBase.js +21 -21
  183. package/dist/Views/ViewBase.d.ts +70 -70
  184. package/dist/Views/ViewBase.js +166 -155
  185. package/dist/Views/ViewComponentBase.d.ts +19 -13
  186. package/dist/Views/ViewComponentBase.js +24 -21
  187. package/dist/Views/ViewModelBase.d.ts +57 -56
  188. package/dist/Views/ViewModelBase.js +122 -118
  189. package/dist/Views/ViewState.d.ts +13 -13
  190. package/dist/Views/ViewState.js +9 -9
  191. package/dist/Views/index.d.ts +5 -5
  192. package/dist/Views/index.js +5 -5
  193. package/dist/index.d.ts +11 -10
  194. package/dist/index.js +10 -9
  195. package/package.json +18 -20
  196. package/styles/Card.scss +8 -1
  197. package/styles/DatePicker.scss +13 -2
  198. package/styles/Forms.scss +5 -0
  199. package/styles/Grid.scss +5 -0
  200. package/styles/Validation.scss +0 -9
package/CHANGELOG.md ADDED
@@ -0,0 +1,98 @@
1
+ # Version 1.x
2
+
3
+ Version 1 of neo-react upgrades react to version 18, and mobX to version 6. Both of these are major updates and will require you to make code changes to your project.
4
+
5
+ ## Testing
6
+
7
+ In addition to requiring code / syntax changes, both React 18, and Mobx 6 behave differently enough to their previous versions that runtime bugs may be introduced into your project. You should only update to this version when you and the client have enough time to test the project thoroughly. If you find any issues, please report them so this document can be updated.
8
+
9
+ The project changes required are detailed below:
10
+
11
+ ## Package changes:
12
+
13
+ * Update all neo packages to the latest 1.x version.
14
+ * Update the following packages to the latest version (these were the latest at time of writing):
15
+ * dependencies
16
+ * `"axios": "1.4.0"`,
17
+ * `"mobx": "6.9.0"`,
18
+ * `"mobx-react": "7.6.0"`,
19
+ * `"react": "18.2.0"`,
20
+ * `"react-dom": "18.2.0"`,
21
+ * `"react-router": "5.2.1"`, - Must be version 5.x
22
+ * `"react-router-dom": "5.3.0"`, - Must be version 5.x
23
+ * `"react-select": "5.7.3"`,
24
+
25
+ * devDependencies
26
+ * `"@types/react": "18.2.4"`,
27
+ * `"@types/react-dom": "18.2.3"`,
28
+ * `"@types/react-router": "5.1.17"`, - Must be version 5.x
29
+ * `"@types/react-router-dom": "5.3.3"`, - Must be version 5.x
30
+ * resolutions
31
+ * remove all entries
32
+ * delete yarn.lock, and run `yarn install`
33
+
34
+ ## Fix errors
35
+
36
+ If any of your components allow children, React 18 requires to you have an explicit `children` prop. Add this to the props definition of the component:
37
+
38
+ ```typescript
39
+ interface MyProps {
40
+ ...
41
+ children: React.ReactNode;
42
+ }
43
+
44
+ // or if the component has no other props:
45
+
46
+ MyComponent extends React.Component<{ children: React.ReactNode }> {
47
+ ...
48
+ }
49
+ ```
50
+
51
+ The React root api has also changed in version 18. Make the following changes to your `index.tsx` file:
52
+
53
+ Your existing code will look something like this:
54
+
55
+ ```typescript
56
+ import ReactDOM from 'react-dom';
57
+ ...
58
+ // React init
59
+ ReactDOM.render(
60
+ renderComponent,
61
+ document.getElementById('root') as HTMLElement
62
+ );
63
+ ```
64
+
65
+ Change the `ReactDOM` import, and the react init code:
66
+
67
+ ```typescript
68
+ import ReactDOM from 'react-dom/client';
69
+ ...
70
+ // React init
71
+ const root = ReactDOM.createRoot(document.getElementById('root') as HTMLElement);
72
+ root.render(renderComponent);
73
+ ```
74
+
75
+ ## Mobx
76
+
77
+ Before mobx 6, you could mark a property as being observable by adding an `@observable` decorator to the property. In mobx 6 this no longer works ([read more](https://mobx.js.org/migrating-from-4-or-5.html)).
78
+
79
+ For any class that extends `ModelBase`, `ValueObject`, `ViewModelBase` etc, this change is handled by neo, and you will not need to change any code.
80
+
81
+ For other classes, you will need to add initialisation code to the constructor.
82
+
83
+ * Search for `@observable` in your project. (In most projects this will be in the Sidebar and AppLayout components)
84
+ * In the constructor of the class that contains the property, add:
85
+
86
+ ```typescript
87
+ makeObservable(this);
88
+ ```
89
+
90
+ ### Decorators on neo models
91
+
92
+ If you try use mobx decorators on any models that extend `ModelBase`, `ValueObject` or `ViewModelBase`, you will receive this error:
93
+
94
+ > [MobX] makeObservable second arg must be nullish when using decorators. Mixing @decorator syntax with annotations is not supported.
95
+
96
+ This is most likely because you have used an `@action` decorator on a method. Neo now marks all methods as actions, so you can remove the `@action` decorator.
97
+
98
+ * Search for `@action` in your project. Remove the decorator **only** if the class extends `ModelBase` (and its decendents e.g. `ValueObject`) or `ViewModelBase`.
package/README.md CHANGED
@@ -4,6 +4,10 @@ This project contains the react/mobx implementation of the neo client library.
4
4
 
5
5
  It also contains UI components built for react.
6
6
 
7
+ ## Changelog
8
+
9
+ View the changelog [here](./CHANGELOG.md).
10
+
7
11
  ## Testing
8
12
 
9
13
  To debug the tests, you need to add the following to .vscode\launch.json
@@ -1,4 +1,4 @@
1
- import { AppServices } from '@singularsystems/neo-core';
2
- import '../React/DataView';
3
- declare const neoReactModule: AppServices.Module;
4
- export default neoReactModule;
1
+ import { AppServices } from '@singularsystems/neo-core';
2
+ import '../React/DataView';
3
+ declare const neoReactModule: AppServices.Module;
4
+ export default neoReactModule;
@@ -1,26 +1,28 @@
1
- import { AppServices } from '@singularsystems/neo-core';
2
- import { NeoReactTypes } from './Types';
3
- import { ReactModelCreator } from '../React/ReactModelCreator';
4
- import { ErrorHandler } from '../ReactComponents/ErrorHandler';
5
- import '../React/DataView';
6
- import { PageLeaveHandler } from '../Routing/PageLeaveHandler';
7
- import NavigationHelper from '../Routing/NavigationHelper';
8
- import { runReactSetup } from './ReactSetup';
9
- import { AutoRunnerFactory } from '../React/AutoRunner';
10
- import { RoutingState } from '../Routing/RoutingState';
11
- import { ContextMenuState } from '../ReactComponents/ContextMenu/ContextMenuState';
12
- import { DisposeHelper } from '../Services/DisposeHelper';
13
- import Decimal from 'decimal.js-light';
14
- var neoReactModule = new AppServices.Module("neo-react", function (container) {
15
- container.bind(AppServices.NeoTypes.Core.AutoRunnerFactory).to(AutoRunnerFactory).inSingletonScope();
16
- container.bind(AppServices.NeoTypes.Core.ModelCreator).to(ReactModelCreator).inTransientScope();
17
- container.bind(AppServices.NeoTypes.Misc.DecimalType).toConstantValue(Decimal);
18
- container.bind(AppServices.NeoTypes.UI.ErrorHandler).to(ErrorHandler).inSingletonScope();
19
- container.bind(AppServices.NeoTypes.UI.GlobalContextMenuState).toConstantValue(new ContextMenuState());
20
- container.bind(AppServices.NeoTypes.Routing.PageLeaveHandler).to(PageLeaveHandler).inSingletonScope();
21
- container.bind(NeoReactTypes.Routing.GlobalRoutingState).to(RoutingState).inSingletonScope();
22
- container.bind(NeoReactTypes.Routing.NavigationHelper).to(NavigationHelper).inSingletonScope();
23
- container.bind(NeoReactTypes.Services.DisposeHelper).to(DisposeHelper).inTransientScope();
24
- runReactSetup(container);
25
- });
26
- export default neoReactModule;
1
+ import { AppServices } from '@singularsystems/neo-core';
2
+ import { NeoReactTypes } from './Types';
3
+ import { ReactModelCreator } from '../React/ReactModelCreator';
4
+ import { ErrorHandler } from '../ReactComponents/ErrorHandler';
5
+ import '../React/DataView';
6
+ import { PageLeaveHandler } from '../Routing/PageLeaveHandler';
7
+ import NavigationHelper from '../Routing/NavigationHelper';
8
+ import { runReactSetup } from './ReactSetup';
9
+ import { AutoRunnerFactory } from '../React/AutoRunner';
10
+ import { RoutingState } from '../Routing/RoutingState';
11
+ import { ContextMenuState } from '../ReactComponents/ContextMenu/ContextMenuState';
12
+ import { DisposeHelper } from '../Services/DisposeHelper';
13
+ import Decimal from 'decimal.js-light';
14
+ import { IconFactory } from '../ReactComponents/Icons/IconFactory';
15
+ var neoReactModule = new AppServices.Module("neo-react", function (container) {
16
+ container.bind(AppServices.NeoTypes.Core.AutoRunnerFactory).to(AutoRunnerFactory).inSingletonScope();
17
+ container.bind(AppServices.NeoTypes.Core.ModelCreator).to(ReactModelCreator).inTransientScope();
18
+ container.bind(AppServices.NeoTypes.Misc.DecimalType).toConstantValue(Decimal);
19
+ container.bind(AppServices.NeoTypes.UI.ErrorHandler).to(ErrorHandler).inSingletonScope();
20
+ container.bind(AppServices.NeoTypes.UI.GlobalContextMenuState).toConstantValue(new ContextMenuState());
21
+ container.bind(AppServices.NeoTypes.Routing.PageLeaveHandler).to(PageLeaveHandler).inSingletonScope();
22
+ container.bind(NeoReactTypes.Components.IconFactory).to(IconFactory).inSingletonScope();
23
+ container.bind(NeoReactTypes.Routing.GlobalRoutingState).to(RoutingState).inSingletonScope();
24
+ container.bind(NeoReactTypes.Routing.NavigationHelper).to(NavigationHelper).inSingletonScope();
25
+ container.bind(NeoReactTypes.Services.DisposeHelper).to(DisposeHelper).inTransientScope();
26
+ runReactSetup(container);
27
+ });
28
+ export default neoReactModule;
@@ -1,2 +1,2 @@
1
- import { NeoContainer } from '@singularsystems/neo-core/dist/AppServices/NeoContainer';
2
- export declare function runReactSetup(container: NeoContainer): void;
1
+ import { NeoContainer } from '@singularsystems/neo-core/dist/AppServices/NeoContainer';
2
+ export declare function runReactSetup(container: NeoContainer): void;
@@ -1,17 +1,17 @@
1
- import { AppServices, Utils } from '@singularsystems/neo-core';
2
- import { configure, runInAction, untracked } from 'mobx';
3
- import React from 'react';
4
- import { NeoReactTypes } from './Types';
5
- export function runReactSetup(container) {
6
- Utils.peek = function (target, propertyName) {
7
- return untracked(function () { return target[propertyName]; });
8
- };
9
- Utils.suppressHtmlEncode = function (html) {
10
- return React.createElement("div", { dangerouslySetInnerHTML: { __html: html } });
11
- };
12
- Utils.batchUpdate = runInAction;
13
- window.addEventListener("beforeunload", function (e) {
14
- container.get(AppServices.NeoTypes.Routing.PageLeaveHandler).onWindowUnload(container.get(NeoReactTypes.Routing.GlobalRoutingState).currentView, e);
15
- });
16
- configure({ enforceActions: "never", useProxies: "never" });
17
- }
1
+ import { AppServices, Utils } from '@singularsystems/neo-core';
2
+ import { configure, runInAction, untracked } from 'mobx';
3
+ import React from 'react';
4
+ import { NeoReactTypes } from './Types';
5
+ export function runReactSetup(container) {
6
+ Utils.peek = function (target, propertyName) {
7
+ return untracked(function () { return target[propertyName]; });
8
+ };
9
+ Utils.suppressHtmlEncode = function (html) {
10
+ return React.createElement("div", { dangerouslySetInnerHTML: { __html: html } });
11
+ };
12
+ Utils.batchUpdate = runInAction;
13
+ window.addEventListener("beforeunload", function (e) {
14
+ container.get(AppServices.NeoTypes.Routing.PageLeaveHandler).onWindowUnload(container.get(NeoReactTypes.Routing.GlobalRoutingState).currentView, e);
15
+ });
16
+ configure({ enforceActions: "never", useProxies: "never" });
17
+ }
@@ -1,61 +1,63 @@
1
- import { AppServices } from '@singularsystems/neo-core';
2
- import { INavigationHelper } from '../Routing/NavigationHelper';
3
- import { RoutingState } from '../Routing/RoutingState';
4
- import Slider, { Range } from 'rc-slider';
5
- import { SketchPicker } from 'react-color';
6
- import AsyncSelect from 'react-select/async';
7
- import { AxiosStatic } from 'axios';
8
- import Decimal from 'decimal.js-light';
9
- import Select from 'react-select';
10
- import { IDisposeHelper } from '../Services/IDisposeHelper';
11
- declare const NeoReactTypes: {
12
- Components: {
13
- Slider: AppServices.ServiceIdentifier<typeof Slider>;
14
- Range: AppServices.ServiceIdentifier<typeof Range>;
15
- SketchPicker: AppServices.ServiceIdentifier<typeof SketchPicker>;
16
- ReactSelect: AppServices.ServiceIdentifier<Select>;
17
- AsyncSelect: AppServices.ServiceIdentifier<AsyncSelect>;
18
- };
19
- Routing: {
20
- NavigationHelper: AppServices.ServiceIdentifier<INavigationHelper>;
21
- GlobalRoutingState: AppServices.ServiceIdentifier<RoutingState>;
22
- MenuItemProvider: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/Routing").IMenuItemProvider<import("@singularsystems/neo-core/dist/Routing").IMenuRoute>>;
23
- PageLeaveHandler: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/Routing").IPageLeaveHandler>;
24
- RouteSecurityService: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/Routing").IRouteSecurityService>;
25
- };
26
- Services: {
27
- DisposeHelper: AppServices.ServiceIdentifier<IDisposeHelper>;
28
- };
29
- Axios: AppServices.ServiceIdentifier<AxiosStatic>;
30
- Config: {
31
- ConfigModel: AppServices.ServiceIdentifier<AppServices.IConfigModel>;
32
- ConfigService: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/AppServices/Config/ConfigService").IConfigService>;
33
- };
34
- Core: {
35
- AutoRunnerFactory: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/Model/IAutoRunner").IAutoRunnerFactory>;
36
- ConnectionManager: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/ConnectionManager").IConnectionManager>;
37
- ModelCreator: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/Model/IModelCreatorBase").default>;
38
- };
39
- Localisation: {
40
- LocalisationService: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/Localisation").ILocalisationService>;
41
- };
42
- Misc: {
43
- DecimalType: AppServices.ServiceIdentifier<typeof Decimal>;
44
- };
45
- Security: {
46
- AuthenticationService: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/Security").IAuthenticationService>;
47
- AuthorisationService: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/Security").IAuthorisationService>;
48
- LoginErrorHandler: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/Security").ILoginErrorHandler>;
49
- SecurityService: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/Security/ISecurityService").default>;
50
- };
51
- TaskRunner: AppServices.ServiceIdentifier<import("@singularsystems/neo-core").ITaskRunner>;
52
- UI: {
53
- ErrorHandler: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/Components").IErrorHandler>;
54
- GlobalContextMenuState: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/Components/ContextMenu/ContextMenu").IContextMenuState>;
55
- GlobalNotifications: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/Components").INotificationHelper>;
56
- ModalStore: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/Components/Modal/ModalStore").IModalStore>;
57
- NotificationHelper: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/Components").INotificationHelper>;
58
- NotificationStore: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/Components").INotificationStore>;
59
- };
60
- };
61
- export { NeoReactTypes };
1
+ import { AppServices } from '@singularsystems/neo-core';
2
+ import { INavigationHelper } from '../Routing/NavigationHelper';
3
+ import { RoutingState } from '../Routing/RoutingState';
4
+ import Slider, { Range } from 'rc-slider';
5
+ import { SketchPicker } from 'react-color';
6
+ import AsyncSelect from 'react-select/async';
7
+ import { AxiosStatic } from 'axios';
8
+ import Decimal from 'decimal.js-light';
9
+ import Select from 'react-select';
10
+ import { IDisposeHelper } from '../Services/IDisposeHelper';
11
+ import { IIconFactory } from '../ReactComponents/Icons/IIconFactory';
12
+ declare const NeoReactTypes: {
13
+ Components: {
14
+ Slider: AppServices.ServiceIdentifier<typeof Slider>;
15
+ Range: AppServices.ServiceIdentifier<typeof Range>;
16
+ SketchPicker: AppServices.ServiceIdentifier<typeof SketchPicker>;
17
+ ReactSelect: AppServices.ServiceIdentifier<Select>;
18
+ AsyncSelect: AppServices.ServiceIdentifier<AsyncSelect>;
19
+ IconFactory: AppServices.ServiceIdentifier<IIconFactory>;
20
+ };
21
+ Routing: {
22
+ NavigationHelper: AppServices.ServiceIdentifier<INavigationHelper>;
23
+ GlobalRoutingState: AppServices.ServiceIdentifier<RoutingState>;
24
+ MenuItemProvider: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/Routing").IMenuItemProvider<import("@singularsystems/neo-core/dist/Routing").IMenuRoute>>;
25
+ PageLeaveHandler: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/Routing").IPageLeaveHandler>;
26
+ RouteSecurityService: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/Routing").IRouteSecurityService>;
27
+ };
28
+ Services: {
29
+ DisposeHelper: AppServices.ServiceIdentifier<IDisposeHelper>;
30
+ };
31
+ Axios: AppServices.ServiceIdentifier<AxiosStatic>;
32
+ Config: {
33
+ ConfigModel: AppServices.ServiceIdentifier<AppServices.IConfigModel>;
34
+ ConfigService: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/AppServices/Config/ConfigService").IConfigService>;
35
+ };
36
+ Core: {
37
+ AutoRunnerFactory: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/Model/IAutoRunner").IAutoRunnerFactory>;
38
+ ConnectionManager: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/ConnectionManager").IConnectionManager>;
39
+ ModelCreator: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/Model/IModelCreatorBase").default>;
40
+ };
41
+ Localisation: {
42
+ LocalisationService: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/Localisation").ILocalisationService>;
43
+ };
44
+ Misc: {
45
+ DecimalType: AppServices.ServiceIdentifier<typeof Decimal>;
46
+ };
47
+ Security: {
48
+ AuthenticationService: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/Security").IAuthenticationService>;
49
+ AuthorisationService: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/Security").IAuthorisationService>;
50
+ LoginErrorHandler: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/Security").ILoginErrorHandler>;
51
+ SecurityService: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/Security/ISecurityService").default>;
52
+ };
53
+ TaskRunner: AppServices.ServiceIdentifier<import("@singularsystems/neo-core").ITaskRunner>;
54
+ UI: {
55
+ ErrorHandler: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/Components").IErrorHandler>;
56
+ GlobalContextMenuState: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/Components/ContextMenu/ContextMenu").IContextMenuState>;
57
+ GlobalNotifications: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/Components").INotificationHelper>;
58
+ ModalStore: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/Components/Modal/ModalStore").IModalStore>;
59
+ NotificationHelper: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/Components").INotificationHelper>;
60
+ NotificationStore: AppServices.ServiceIdentifier<import("@singularsystems/neo-core/dist/Components").INotificationStore>;
61
+ };
62
+ };
63
+ export { NeoReactTypes };
@@ -1,12 +1,13 @@
1
- import { __assign } from "tslib";
2
- import { AppServices } from '@singularsystems/neo-core';
3
- var NeoReactTypes = __assign(__assign({}, AppServices.NeoTypes), { Components: {
4
- Slider: new AppServices.ServiceIdentifier("NeoReact.Slider"),
5
- Range: new AppServices.ServiceIdentifier("NeoReact.Range"),
6
- SketchPicker: new AppServices.ServiceIdentifier("NeoReact.SketchPicker"),
7
- ReactSelect: new AppServices.ServiceIdentifier("NeoReact.ReactSelect"),
8
- AsyncSelect: new AppServices.ServiceIdentifier("NeoReact.AsyncSelect"),
9
- }, Routing: __assign(__assign({}, AppServices.NeoTypes.Routing), { NavigationHelper: AppServices.NeoTypes.Routing.NavigationHelper.asType(), GlobalRoutingState: new AppServices.ServiceIdentifier("NeoReact.GlobalRoutingState") }), Services: {
10
- DisposeHelper: new AppServices.ServiceIdentifier("NeoReact.DisposeHelper")
11
- } });
12
- export { NeoReactTypes };
1
+ import { __assign } from "tslib";
2
+ import { AppServices } from '@singularsystems/neo-core';
3
+ var NeoReactTypes = __assign(__assign({}, AppServices.NeoTypes), { Components: {
4
+ Slider: new AppServices.ServiceIdentifier("NeoReact.Slider"),
5
+ Range: new AppServices.ServiceIdentifier("NeoReact.Range"),
6
+ SketchPicker: new AppServices.ServiceIdentifier("NeoReact.SketchPicker"),
7
+ ReactSelect: new AppServices.ServiceIdentifier("NeoReact.ReactSelect"),
8
+ AsyncSelect: new AppServices.ServiceIdentifier("NeoReact.AsyncSelect"),
9
+ IconFactory: new AppServices.ServiceIdentifier("NeoReact.IconFactory")
10
+ }, Routing: __assign(__assign({}, AppServices.NeoTypes.Routing), { NavigationHelper: AppServices.NeoTypes.Routing.NavigationHelper.asType(), GlobalRoutingState: new AppServices.ServiceIdentifier("NeoReact.GlobalRoutingState") }), Services: {
11
+ DisposeHelper: new AppServices.ServiceIdentifier("NeoReact.DisposeHelper")
12
+ } });
13
+ export { NeoReactTypes };
@@ -1,5 +1,5 @@
1
- import { Misc, Model } from '@singularsystems/neo-core';
2
- import { IAutoRunnerFactory } from '@singularsystems/neo-core/dist/Model/IAutoRunner';
3
- export declare class AutoRunnerFactory implements IAutoRunnerFactory {
4
- create<T extends Model.IModelBase>(model: T, callback: (model: T) => void, options?: Misc.IAutoRunnerOptions<T>): Misc.IAutoRunner;
5
- }
1
+ import { Misc, Model } from '@singularsystems/neo-core';
2
+ import { IAutoRunnerFactory } from '@singularsystems/neo-core/dist/Model/IAutoRunner';
3
+ export declare class AutoRunnerFactory implements IAutoRunnerFactory {
4
+ create<T extends Model.IModelBase>(model: T, callback: (model: T) => void, options?: Misc.IAutoRunnerOptions<T>): Misc.IAutoRunner;
5
+ }
@@ -1,92 +1,94 @@
1
- import { __decorate } from "tslib";
2
- import { Utils, Misc } from '@singularsystems/neo-core';
3
- import { reaction } from 'mobx';
4
- import { injectable } from 'inversify';
5
- var AutoRunnerFactory = /** @class */ (function () {
6
- function AutoRunnerFactory() {
7
- }
8
- AutoRunnerFactory.prototype.create = function (model, callback, options) {
9
- return new AutoRunner(model, callback, options);
10
- };
11
- AutoRunnerFactory = __decorate([
12
- injectable()
13
- ], AutoRunnerFactory);
14
- return AutoRunnerFactory;
15
- }());
16
- export { AutoRunnerFactory };
17
- var AutoRunner = /** @class */ (function () {
18
- function AutoRunner(model, callback, options) {
19
- var _this = this;
20
- this.isPaused = false;
21
- this.propertyMap = {};
22
- this.options = options !== null && options !== void 0 ? options : {};
23
- this.disposerDelayed = reaction(function () { return _this.accessAllValues(model, true, new Map(), ""); }, function () { var _a; return _this.runCallback(model, callback, (_a = _this.options.delayMs) !== null && _a !== void 0 ? _a : 500); });
24
- this.disposerImmediate = reaction(function () { return _this.accessAllValues(model, false, new Map(), ""); }, function () { return _this.runCallback(model, callback, 0); });
25
- }
26
- AutoRunner.prototype.cancelPending = function () {
27
- Utils.clearDebounce(this);
28
- };
29
- AutoRunner.prototype.dispose = function () {
30
- this.disposerDelayed();
31
- this.disposerImmediate();
32
- };
33
- AutoRunner.prototype.runCallback = function (model, callback, delay) {
34
- var _this = this;
35
- if (!this.isPaused) {
36
- Utils.debounce(this, function () {
37
- _this.isPaused = true;
38
- try {
39
- callback(model);
40
- }
41
- finally {
42
- _this.isPaused = false;
43
- }
44
- }, delay);
45
- }
46
- };
47
- /**
48
- * Access all the property values of a model including it's value objects properties.
49
- * @param instance Instance to access.
50
- * @param delayed True if only delayed properties should be accessed. A delayed property is one where the user
51
- * types in the value over a short period of time. E.g. numeric input or text input.
52
- */
53
- AutoRunner.prototype.accessAllValues = function (instance, delayed, trackedInstances, path) {
54
- var _a;
55
- if (instance && !trackedInstances.has(instance)) {
56
- trackedInstances.set(instance, true);
57
- var info = instance.constructor.neo;
58
- var filterProperties = path === "" ? this.options.rootProperties : undefined;
59
- for (var _i = 0, _b = info.properties; _i < _b.length; _i++) {
60
- var propertyInfo = _b[_i];
61
- if (!propertyInfo.noTrack && instance.meta[propertyInfo.propertyName] && (!filterProperties || filterProperties.indexOf(propertyInfo.propertyName) >= 0)) {
62
- if (propertyInfo.relationType === Misc.RelationType.None) {
63
- var key = path + propertyInfo.propertyName;
64
- var useDelay = this.propertyMap[key];
65
- if (useDelay === undefined) {
66
- // This needs to be calculated once, otherwise null -> string value changes cause properties to no longer be tracked.
67
- useDelay = (_a = propertyInfo.debounce) !== null && _a !== void 0 ? _a : ([Misc.DataType.Int, Misc.DataType.Float].indexOf(propertyInfo.propertyType) >= 0 ||
68
- (typeof instance.meta[propertyInfo.propertyName].peek === "string"));
69
- this.propertyMap[key] = useDelay;
70
- }
71
- if (useDelay === delayed) {
72
- void instance[propertyInfo.propertyName];
73
- }
74
- }
75
- else if (propertyInfo.relationType === Misc.RelationType.ValueObject ||
76
- (propertyInfo.relationType === Misc.RelationType.ChildObject && this.options.includeChildObjects)) {
77
- this.accessAllValues(instance[propertyInfo.propertyName], delayed, trackedInstances, path + propertyInfo.propertyName + ".");
78
- }
79
- else if (propertyInfo.relationType === Misc.RelationType.ChildList && this.options.includeChildLists) {
80
- var index = 0;
81
- for (var _c = 0, _d = instance[propertyInfo.propertyName]; _c < _d.length; _c++) {
82
- var child = _d[_c];
83
- this.accessAllValues(child, delayed, trackedInstances, "".concat(path).concat(propertyInfo.propertyName, "[").concat(index++, "]."));
84
- }
85
- }
86
- }
87
- }
88
- }
89
- return {};
90
- };
91
- return AutoRunner;
92
- }());
1
+ import { __decorate } from "tslib";
2
+ import { Misc, DebounceHelper } from '@singularsystems/neo-core';
3
+ import { reaction } from 'mobx';
4
+ import { injectable } from 'inversify';
5
+ export var AutoRunnerFactory = /** @class */ (function () {
6
+ function AutoRunnerFactory() {
7
+ }
8
+ AutoRunnerFactory.prototype.create = function (model, callback, options) {
9
+ return new AutoRunner(model, callback, options);
10
+ };
11
+ AutoRunnerFactory = __decorate([
12
+ injectable()
13
+ ], AutoRunnerFactory);
14
+ return AutoRunnerFactory;
15
+ }());
16
+ var AutoRunner = /** @class */ (function () {
17
+ function AutoRunner(model, callback, options) {
18
+ var _this = this;
19
+ this.isPaused = false;
20
+ this.propertyMap = {};
21
+ this.options = options !== null && options !== void 0 ? options : {};
22
+ this.disposerDelayed = reaction(function () { return _this.accessAllValues(model, true, new Map(), ""); }, function () { var _a; return _this.runCallback(model, callback, (_a = _this.options.delayMs) !== null && _a !== void 0 ? _a : 500); });
23
+ this.disposerImmediate = reaction(function () { return _this.accessAllValues(model, false, new Map(), ""); }, function () { return _this.runCallback(model, callback, 0); });
24
+ }
25
+ AutoRunner.prototype.cancelPending = function () {
26
+ DebounceHelper.cancelPending(this);
27
+ };
28
+ AutoRunner.prototype.fireImmediate = function () {
29
+ DebounceHelper.executeImmediate(this);
30
+ };
31
+ AutoRunner.prototype.dispose = function () {
32
+ this.disposerDelayed();
33
+ this.disposerImmediate();
34
+ };
35
+ AutoRunner.prototype.runCallback = function (model, callback, delay) {
36
+ var _this = this;
37
+ if (!this.isPaused) {
38
+ DebounceHelper.debounce(this, function () {
39
+ _this.isPaused = true;
40
+ try {
41
+ callback(model);
42
+ }
43
+ finally {
44
+ _this.isPaused = false;
45
+ }
46
+ }, delay);
47
+ }
48
+ };
49
+ /**
50
+ * Access all the property values of a model including it's value objects properties.
51
+ * @param instance Instance to access.
52
+ * @param delayed True if only delayed properties should be accessed. A delayed property is one where the user
53
+ * types in the value over a short period of time. E.g. numeric input or text input.
54
+ */
55
+ AutoRunner.prototype.accessAllValues = function (instance, delayed, trackedInstances, path) {
56
+ var _a;
57
+ if (instance && !trackedInstances.has(instance)) {
58
+ trackedInstances.set(instance, true);
59
+ var info = instance.constructor.neo;
60
+ var filterProperties = path === "" ? this.options.rootProperties : undefined;
61
+ for (var _i = 0, _b = info.properties; _i < _b.length; _i++) {
62
+ var propertyInfo = _b[_i];
63
+ if (!propertyInfo.noTrack && instance.meta[propertyInfo.propertyName] && (!filterProperties || filterProperties.indexOf(propertyInfo.propertyName) >= 0)) {
64
+ if (propertyInfo.relationType === Misc.RelationType.None) {
65
+ var key = path + propertyInfo.propertyName;
66
+ var useDelay = this.propertyMap[key];
67
+ if (useDelay === undefined) {
68
+ // This needs to be calculated once, otherwise null -> string value changes cause properties to no longer be tracked.
69
+ useDelay = (_a = propertyInfo.debounce) !== null && _a !== void 0 ? _a : ([Misc.DataType.Int, Misc.DataType.Float].indexOf(propertyInfo.propertyType) >= 0 ||
70
+ (typeof instance.meta[propertyInfo.propertyName].peek === "string"));
71
+ this.propertyMap[key] = useDelay;
72
+ }
73
+ if (useDelay === delayed) {
74
+ void instance[propertyInfo.propertyName];
75
+ }
76
+ }
77
+ else if (propertyInfo.relationType === Misc.RelationType.ValueObject ||
78
+ (propertyInfo.relationType === Misc.RelationType.ChildObject && this.options.includeChildObjects)) {
79
+ this.accessAllValues(instance[propertyInfo.propertyName], delayed, trackedInstances, path + propertyInfo.propertyName + ".");
80
+ }
81
+ else if (propertyInfo.relationType === Misc.RelationType.ChildList && this.options.includeChildLists) {
82
+ var index = 0;
83
+ for (var _c = 0, _d = instance[propertyInfo.propertyName]; _c < _d.length; _c++) {
84
+ var child = _d[_c];
85
+ this.accessAllValues(child, delayed, trackedInstances, "".concat(path).concat(propertyInfo.propertyName, "[").concat(index++, "]."));
86
+ }
87
+ }
88
+ }
89
+ }
90
+ }
91
+ return {};
92
+ };
93
+ return AutoRunner;
94
+ }());
@@ -1,6 +1,6 @@
1
- import React from 'react';
2
- import { Data } from '@singularsystems/neo-core';
3
- export declare class DataViewContextParams<T> {
4
- dataView: Data.DataViewBase<T>;
5
- }
6
- export declare const DataViewContext: React.Context<DataViewContextParams<unknown>>;
1
+ import React from 'react';
2
+ import { Data } from '@singularsystems/neo-core';
3
+ export declare class DataViewContextParams<T> {
4
+ dataView: Data.DataViewBase<T>;
5
+ }
6
+ export declare const DataViewContext: React.Context<DataViewContextParams<unknown>>;
@@ -1,11 +1,11 @@
1
- import React from 'react';
2
- import { Data } from '@singularsystems/neo-core';
3
- import { untracked } from 'mobx';
4
- Data.DataViewBase.unTrackedSort = untracked;
5
- var DataViewContextParams = /** @class */ (function () {
6
- function DataViewContextParams() {
7
- }
8
- return DataViewContextParams;
9
- }());
10
- export { DataViewContextParams };
11
- export var DataViewContext = React.createContext(new DataViewContextParams());
1
+ import React from 'react';
2
+ import { Data } from '@singularsystems/neo-core';
3
+ import { untracked } from 'mobx';
4
+ Data.DataViewBase.unTrackedSort = untracked;
5
+ var DataViewContextParams = /** @class */ (function () {
6
+ function DataViewContextParams() {
7
+ }
8
+ return DataViewContextParams;
9
+ }());
10
+ export { DataViewContextParams };
11
+ export var DataViewContext = React.createContext(new DataViewContextParams());