@singularsystems/neo-react 1.0.0-alpha.2 → 1.0.0-beta.0
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 +98 -0
- package/README.md +4 -0
- package/dist/Modules/NeoReactModule.d.ts +4 -4
- package/dist/Modules/NeoReactModule.js +28 -26
- package/dist/Modules/ReactSetup.d.ts +2 -2
- package/dist/Modules/ReactSetup.js +17 -17
- package/dist/Modules/Types.d.ts +63 -61
- package/dist/Modules/Types.js +13 -12
- package/dist/React/AutoRunner.d.ts +5 -5
- package/dist/React/AutoRunner.js +94 -92
- package/dist/React/DataView.d.ts +6 -6
- package/dist/React/DataView.js +11 -11
- package/dist/React/ReactModelCreator.d.ts +11 -11
- package/dist/React/ReactModelCreator.js +165 -162
- package/dist/ReactComponents/Button.d.ts +24 -23
- package/dist/ReactComponents/Button.js +131 -123
- package/dist/ReactComponents/Card.d.ts +24 -23
- package/dist/ReactComponents/Card.js +56 -54
- package/dist/ReactComponents/Collapsable.d.ts +23 -23
- package/dist/ReactComponents/Collapsable.js +38 -38
- package/dist/ReactComponents/CollapsableBase.d.ts +13 -13
- package/dist/ReactComponents/CollapsableBase.js +42 -42
- package/dist/ReactComponents/ColorPicker.d.ts +26 -26
- package/dist/ReactComponents/ColorPicker.js +67 -67
- package/dist/ReactComponents/ComponentBase.d.ts +17 -17
- package/dist/ReactComponents/ComponentBase.js +33 -33
- package/dist/ReactComponents/ContextMenu/ContextMenu.d.ts +25 -24
- package/dist/ReactComponents/ContextMenu/ContextMenu.js +91 -88
- package/dist/ReactComponents/ContextMenu/ContextMenuContainer.d.ts +14 -14
- package/dist/ReactComponents/ContextMenu/ContextMenuContainer.js +48 -48
- package/dist/ReactComponents/ContextMenu/ContextMenuState.d.ts +8 -7
- package/dist/ReactComponents/ContextMenu/ContextMenuState.js +23 -23
- package/dist/ReactComponents/DatePicker.d.ts +19 -19
- package/dist/ReactComponents/DatePicker.js +53 -53
- package/dist/ReactComponents/DropDown/AutoCompleteDropDown.d.ts +93 -83
- package/dist/ReactComponents/DropDown/AutoCompleteDropDown.js +222 -188
- package/dist/ReactComponents/DropDown/DropDown.d.ts +44 -44
- package/dist/ReactComponents/DropDown/DropDown.js +138 -134
- package/dist/ReactComponents/DropDown/DropDownBase.d.ts +16 -15
- package/dist/ReactComponents/DropDown/DropDownBase.js +86 -108
- package/dist/ReactComponents/DropDown/LookupHelper.d.ts +13 -0
- package/dist/ReactComponents/DropDown/LookupHelper.js +45 -0
- package/dist/ReactComponents/ErrorHandler.d.ts +9 -8
- package/dist/ReactComponents/ErrorHandler.js +92 -91
- package/dist/ReactComponents/FileManager/FileBasicInput.d.ts +20 -20
- package/dist/ReactComponents/FileManager/FileBasicInput.js +70 -70
- package/dist/ReactComponents/FileManager/FileContext.d.ts +16 -16
- package/dist/ReactComponents/FileManager/FileContext.js +24 -24
- package/dist/ReactComponents/FileManager/FileDropArea.d.ts +19 -18
- package/dist/ReactComponents/FileManager/FileDropArea.js +66 -64
- package/dist/ReactComponents/FileManager/FileInput.d.ts +44 -42
- package/dist/ReactComponents/FileManager/FileInput.js +191 -189
- package/dist/ReactComponents/FileManager/FileUploadButton.d.ts +17 -17
- package/dist/ReactComponents/FileManager/FileUploadButton.js +49 -49
- package/dist/ReactComponents/FileManager/FileUploadProgress.d.ts +14 -14
- package/dist/ReactComponents/FileManager/FileUploadProgress.js +35 -35
- package/dist/ReactComponents/Form.d.ts +19 -18
- package/dist/ReactComponents/Form.js +90 -90
- package/dist/ReactComponents/FormContext.d.ts +33 -31
- package/dist/ReactComponents/FormContext.js +39 -40
- package/dist/ReactComponents/FormGroup/FormGroup.d.ts +37 -37
- package/dist/ReactComponents/FormGroup/FormGroup.js +83 -84
- package/dist/ReactComponents/FormGroup/FormGroupFloating.d.ts +19 -19
- package/dist/ReactComponents/FormGroup/FormGroupFloating.js +97 -97
- package/dist/ReactComponents/FormGroup/FormGroupInline.d.ts +11 -11
- package/dist/ReactComponents/FormGroup/FormGroupInline.js +43 -43
- package/dist/ReactComponents/Grid/ButtonColumn.d.ts +47 -47
- package/dist/ReactComponents/Grid/ButtonColumn.js +81 -82
- package/dist/ReactComponents/Grid/Column.d.ts +47 -47
- package/dist/ReactComponents/Grid/Column.js +205 -205
- package/dist/ReactComponents/Grid/ColumnHelper.d.ts +12 -12
- package/dist/ReactComponents/Grid/ColumnHelper.js +19 -19
- package/dist/ReactComponents/Grid/Grid.d.ts +87 -90
- package/dist/ReactComponents/Grid/Grid.js +203 -203
- package/dist/ReactComponents/Grid/Row.d.ts +81 -81
- package/dist/ReactComponents/Grid/Row.js +200 -201
- package/dist/ReactComponents/Grid/_Exports.d.ts +5 -5
- package/dist/ReactComponents/Grid/_Exports.js +5 -5
- package/dist/ReactComponents/GridLayout.d.ts +20 -20
- package/dist/ReactComponents/GridLayout.js +38 -38
- package/dist/ReactComponents/Icons/FontAwesomeIconFactory.d.ts +23 -0
- package/dist/ReactComponents/Icons/FontAwesomeIconFactory.js +43 -0
- package/dist/ReactComponents/Icons/IIconFactory.d.ts +21 -0
- package/dist/ReactComponents/Icons/IIconFactory.js +1 -0
- package/dist/ReactComponents/Icons/IconFactory.d.ts +9 -0
- package/dist/ReactComponents/Icons/IconFactory.js +45 -0
- package/dist/ReactComponents/Icons/index.d.ts +3 -0
- package/dist/ReactComponents/Icons/index.js +2 -0
- package/dist/ReactComponents/Input.d.ts +45 -45
- package/dist/ReactComponents/Input.js +153 -152
- package/dist/ReactComponents/InputHelpers.d.ts +6 -5
- package/dist/ReactComponents/InputHelpers.js +29 -33
- package/dist/ReactComponents/Link.d.ts +13 -13
- package/dist/ReactComponents/Link.js +28 -28
- package/dist/ReactComponents/Loader.d.ts +18 -18
- package/dist/ReactComponents/Loader.js +57 -57
- package/dist/ReactComponents/Misc.d.ts +15 -15
- package/dist/ReactComponents/Misc.js +28 -28
- package/dist/ReactComponents/Modal/Modal.d.ts +11 -11
- package/dist/ReactComponents/Modal/Modal.js +129 -129
- package/dist/ReactComponents/Modal/ModalContainer.d.ts +17 -17
- package/dist/ReactComponents/Modal/ModalContainer.js +37 -37
- package/dist/ReactComponents/Modal/ModalPortal.d.ts +16 -15
- package/dist/ReactComponents/Modal/ModalPortal.js +27 -27
- package/dist/ReactComponents/Notifications/Alert.d.ts +7 -6
- package/dist/ReactComponents/Notifications/Alert.js +38 -35
- package/dist/ReactComponents/Notifications/Toast.d.ts +9 -8
- package/dist/ReactComponents/Notifications/Toast.js +47 -45
- package/dist/ReactComponents/Notifications/ToastContainer.d.ts +8 -8
- package/dist/ReactComponents/Notifications/ToastContainer.js +18 -18
- package/dist/ReactComponents/NumberInput.d.ts +57 -50
- package/dist/ReactComponents/NumberInput.js +260 -246
- package/dist/ReactComponents/Paging/BasicPagerControls.d.ts +26 -25
- package/dist/ReactComponents/Paging/BasicPagerControls.js +57 -55
- package/dist/ReactComponents/Paging/PageSizeControl.d.ts +11 -11
- package/dist/ReactComponents/Paging/PageSizeControl.js +21 -21
- package/dist/ReactComponents/Paging/Pager.d.ts +24 -24
- package/dist/ReactComponents/Paging/Pager.js +41 -41
- package/dist/ReactComponents/ProgressBar.d.ts +19 -19
- package/dist/ReactComponents/ProgressBar.js +52 -52
- package/dist/ReactComponents/PropTypes.d.ts +161 -161
- package/dist/ReactComponents/PropTypes.js +253 -236
- package/dist/ReactComponents/RadioList.d.ts +29 -29
- package/dist/ReactComponents/RadioList.js +59 -77
- package/dist/ReactComponents/Slider.d.ts +28 -28
- package/dist/ReactComponents/Slider.js +76 -76
- package/dist/ReactComponents/StateObserver.d.ts +15 -15
- package/dist/ReactComponents/StateObserver.js +35 -35
- package/dist/ReactComponents/Tabs/Tab.d.ts +42 -41
- package/dist/ReactComponents/Tabs/Tab.js +71 -72
- package/dist/ReactComponents/Tabs/TabContainer.d.ts +44 -44
- package/dist/ReactComponents/Tabs/TabContainer.js +98 -98
- package/dist/ReactComponents/Tabs/TabManager.d.ts +62 -62
- package/dist/ReactComponents/Tabs/TabManager.js +154 -154
- package/dist/ReactComponents/Tooltip.d.ts +20 -19
- package/dist/ReactComponents/Tooltip.js +51 -51
- package/dist/ReactComponents/TooltipHelper.d.ts +8 -8
- package/dist/ReactComponents/TooltipHelper.js +84 -84
- package/dist/ReactComponents/TooltipProvider.d.ts +30 -30
- package/dist/ReactComponents/TooltipProvider.js +111 -111
- package/dist/ReactComponents/ValidationSummary.d.ts +23 -22
- package/dist/ReactComponents/ValidationSummary.js +46 -43
- package/dist/ReactComponents/_Exports.d.ts +41 -41
- package/dist/ReactComponents/_Exports.js +41 -41
- package/dist/ReactComponents/_Managers.d.ts +4 -4
- package/dist/ReactComponents/_Managers.js +4 -4
- package/dist/Routing/BreadCrumbItem.d.ts +14 -14
- package/dist/Routing/BreadCrumbItem.js +12 -12
- package/dist/Routing/IRouteChangedProps.d.ts +31 -31
- package/dist/Routing/IRouteChangedProps.js +1 -1
- package/dist/Routing/IRouteParameter.d.ts +22 -22
- package/dist/Routing/IRouteParameter.js +9 -9
- package/dist/Routing/MenuRoute.d.ts +25 -24
- package/dist/Routing/MenuRoute.js +24 -24
- package/dist/Routing/NavigationHelper.d.ts +41 -40
- package/dist/Routing/NavigationHelper.js +61 -61
- package/dist/Routing/PageLeaveHandler.d.ts +13 -13
- package/dist/Routing/PageLeaveHandler.js +74 -74
- package/dist/Routing/RouteProvider.d.ts +31 -31
- package/dist/Routing/RouteProvider.js +92 -92
- package/dist/Routing/RouteView.d.ts +50 -50
- package/dist/Routing/RouteView.js +143 -144
- package/dist/Routing/RoutingState.d.ts +18 -15
- package/dist/Routing/RoutingState.js +45 -40
- package/dist/Routing/ViewParameter.d.ts +80 -58
- package/dist/Routing/ViewParameter.js +116 -95
- package/dist/Routing/ViewParameterList.d.ts +53 -53
- package/dist/Routing/ViewParameterList.js +163 -145
- package/dist/Routing/index.d.ts +9 -9
- package/dist/Routing/index.js +6 -6
- package/dist/Services/DisposeHelper.d.ts +15 -15
- package/dist/Services/DisposeHelper.js +40 -41
- package/dist/Services/IDisposeHelper.d.ts +12 -12
- package/dist/Services/IDisposeHelper.js +1 -1
- package/dist/Views/EmptyViewModel.d.ts +5 -5
- package/dist/Views/EmptyViewModel.js +14 -14
- package/dist/Views/IViewModel.d.ts +16 -16
- package/dist/Views/IViewModel.js +1 -1
- package/dist/Views/PersistentViewBase.d.ts +10 -10
- package/dist/Views/PersistentViewBase.js +21 -21
- package/dist/Views/ViewBase.d.ts +70 -71
- package/dist/Views/ViewBase.js +166 -153
- package/dist/Views/ViewComponentBase.d.ts +19 -13
- package/dist/Views/ViewComponentBase.js +24 -21
- package/dist/Views/ViewModelBase.d.ts +57 -56
- package/dist/Views/ViewModelBase.js +122 -118
- package/dist/Views/ViewState.d.ts +13 -13
- package/dist/Views/ViewState.js +9 -9
- package/dist/Views/index.d.ts +5 -5
- package/dist/Views/index.js +5 -5
- package/dist/index.d.ts +11 -10
- package/dist/index.js +10 -9
- package/package.json +26 -26
- package/styles/DatePicker.scss +2 -2
- package/styles/Forms.scss +5 -0
- 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
|
+
The changes required are detailed below:
|
|
6
|
+
|
|
7
|
+
## Package changes:
|
|
8
|
+
|
|
9
|
+
* Update all neo packages to the latest 1.x version.
|
|
10
|
+
* Update the following packages to the latest version (these were the latest at time of writing):
|
|
11
|
+
* dependencies
|
|
12
|
+
* `"axios": "1.4.0"`,
|
|
13
|
+
* `"mobx": "6.9.0"`,
|
|
14
|
+
* `"mobx-react": "7.6.0"`,
|
|
15
|
+
* `"react": "18.2.0"`,
|
|
16
|
+
* `"react-dom": "18.2.0"`,
|
|
17
|
+
* `"react-router": "5.2.1"`, - Must be version 5.x
|
|
18
|
+
* `"react-router-dom": "5.3.0"`, - Must be version 5.x
|
|
19
|
+
* `"react-select": "5.7.3"`,
|
|
20
|
+
|
|
21
|
+
* devDependencies
|
|
22
|
+
* `"@types/react": "18.2.4"`,
|
|
23
|
+
* `"@types/react-dom": "18.2.3"`,
|
|
24
|
+
* `"@types/react-router": "5.1.17"`, - Must be version 5.x
|
|
25
|
+
* `"@types/react-router-dom": "5.3.3"`, - Must be version 5.x
|
|
26
|
+
* resolutions
|
|
27
|
+
* remove all entries
|
|
28
|
+
* delete yarn.lock, and run `yarn install`
|
|
29
|
+
|
|
30
|
+
## Fix errors
|
|
31
|
+
|
|
32
|
+
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:
|
|
33
|
+
|
|
34
|
+
```typescript
|
|
35
|
+
interface MyProps {
|
|
36
|
+
...
|
|
37
|
+
children: React.ReactNode;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
// or if the component has no other props:
|
|
41
|
+
|
|
42
|
+
MyComponent extends React.Component<{ children: React.ReactNode }> {
|
|
43
|
+
...
|
|
44
|
+
}
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
The React root api has also changed in version 18. Make the following changes to your `index.tsx` file:
|
|
48
|
+
|
|
49
|
+
Your existing code will look something like this:
|
|
50
|
+
|
|
51
|
+
```typescript
|
|
52
|
+
import ReactDOM from 'react-dom';
|
|
53
|
+
...
|
|
54
|
+
// React init
|
|
55
|
+
ReactDOM.render(
|
|
56
|
+
renderComponent,
|
|
57
|
+
document.getElementById('root') as HTMLElement
|
|
58
|
+
);
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
Change the `ReactDOM` import, and the react init code:
|
|
62
|
+
|
|
63
|
+
```typescript
|
|
64
|
+
import ReactDOM from 'react-dom/client';
|
|
65
|
+
...
|
|
66
|
+
// React init
|
|
67
|
+
const root = ReactDOM.createRoot(document.getElementById('root') as HTMLElement);
|
|
68
|
+
root.render(renderComponent);
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
## Mobx
|
|
72
|
+
|
|
73
|
+
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)).
|
|
74
|
+
|
|
75
|
+
For any class that extends `ModelBase`, `ValueObject`, `ViewModelBase` etc, this change is handled by neo, and you will not need to change any code.
|
|
76
|
+
|
|
77
|
+
For other classes, you will need to add initialisation code to the constructor.
|
|
78
|
+
|
|
79
|
+
* Search for `@observable` in your project. (In most projects this will be in the Sidebar and AppLayout components)
|
|
80
|
+
* In the constructor of the class that contains the property, add:
|
|
81
|
+
|
|
82
|
+
```typescript
|
|
83
|
+
makeObservable(this);
|
|
84
|
+
```
|
|
85
|
+
|
|
86
|
+
### Decorators on neo models
|
|
87
|
+
|
|
88
|
+
If you try use mobx decorators on any models that extend `ModelBase` or `ViewModelBase`, you will receive this error:
|
|
89
|
+
|
|
90
|
+
> [MobX] makeObservable second arg must be nullish when using decorators. Mixing @decorator syntax with annotations is not supported.
|
|
91
|
+
|
|
92
|
+
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.
|
|
93
|
+
|
|
94
|
+
* Search for `@action` in your project. Remove the decorator **only** if the class extends `ModelBase` or `ViewModelBase`.
|
|
95
|
+
|
|
96
|
+
## Testing
|
|
97
|
+
|
|
98
|
+
Both React 18, and Mobx 6 behave differently enough to their previous versions that new bugs are almost guaranteed. 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.
|
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
|
-
|
|
15
|
-
|
|
16
|
-
container.bind(AppServices.NeoTypes.Core.
|
|
17
|
-
container.bind(AppServices.NeoTypes.
|
|
18
|
-
container.bind(AppServices.NeoTypes.
|
|
19
|
-
container.bind(AppServices.NeoTypes.UI.
|
|
20
|
-
container.bind(AppServices.NeoTypes.
|
|
21
|
-
container.bind(
|
|
22
|
-
container.bind(NeoReactTypes.
|
|
23
|
-
container.bind(NeoReactTypes.
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
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
|
|
4
|
-
import
|
|
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(
|
|
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
|
+
}
|
package/dist/Modules/Types.d.ts
CHANGED
|
@@ -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
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
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 };
|
package/dist/Modules/Types.js
CHANGED
|
@@ -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
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
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
|
+
}
|
package/dist/React/AutoRunner.js
CHANGED
|
@@ -1,92 +1,94 @@
|
|
|
1
|
-
import { __decorate } from "tslib";
|
|
2
|
-
import {
|
|
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
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
this.
|
|
21
|
-
this.
|
|
22
|
-
this.
|
|
23
|
-
this.
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
*
|
|
51
|
-
*
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
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
|
+
}());
|
package/dist/React/DataView.d.ts
CHANGED
|
@@ -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>>;
|
package/dist/React/DataView.js
CHANGED
|
@@ -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());
|