@epam/uui-db 5.0.0 → 5.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/readme.md CHANGED
@@ -1,17 +1,17 @@
1
- # UUI DB package
2
-
3
- This package is a part of [EPAM UUI](https://github.com/epam/UUI) library.
4
-
5
- @epam/uui-db is an experimental state-management solution. It maintains immutable relational database on client, provides means to load data from server, update it both from client, and save it to server asynchronously with UI operations.
6
-
7
- ## Features
8
-
9
- - relation data model for state, providing a normalized storage for UI state
10
- - data loading from server, with automatic GraphQL response normalization into tables
11
- - synchronous and transactional updates of state from UI
12
- - asynchronous bi-directional state synchronization between UI and server. UI changes in terms of 'patches' are batched and sent to server. Server can also push updates to UI state
13
- - GIT-like branch-rebase approach to handle state concurrency
14
- - tables can be indexed to speed-up queries
15
- - Views to build arbitrary state projections
16
- - subscriptions to subscribe parts of UI to changes in Views
17
-
1
+ # UUI DB package
2
+
3
+ This package is a part of [EPAM UUI](https://github.com/epam/UUI) library.
4
+
5
+ @epam/uui-db is an experimental state-management solution. It maintains immutable relational database on client, provides means to load data from server, update it both from client, and save it to server asynchronously with UI operations.
6
+
7
+ ## Features
8
+
9
+ - relation data model for state, providing a normalized storage for UI state
10
+ - data loading from server, with automatic GraphQL response normalization into tables
11
+ - synchronous and transactional updates of state from UI
12
+ - asynchronous bi-directional state synchronization between UI and server. UI changes in terms of 'patches' are batched and sent to server. Server can also push updates to UI state
13
+ - GIT-like branch-rebase approach to handle state concurrency
14
+ - tables can be indexed to speed-up queries
15
+ - Views to build arbitrary state projections
16
+ - subscriptions to subscribe parts of UI to changes in Views
17
+
package/stats.html CHANGED
@@ -6157,7 +6157,7 @@ var drawChart = (function (exports) {
6157
6157
  </script>
6158
6158
  <script>
6159
6159
  /*<!--*/
6160
- const data = {"version":2,"tree":{"name":"root","children":[{"name":"index.esm.js","children":[{"name":"build/rollup:/@epam/uui-db","children":[{"name":"src","children":[{"uid":"ef1d-54","name":"types.ts"},{"uid":"ef1d-56","name":"utils.ts"},{"uid":"ef1d-58","name":"Db.ts"},{"uid":"ef1d-62","name":"DbTable.ts"},{"uid":"ef1d-64","name":"patchHelpers.ts"},{"uid":"ef1d-66","name":"tempIds.tsx"},{"uid":"ef1d-68","name":"Loader.ts"},{"uid":"ef1d-70","name":"SimpleLoadingTracker.ts"},{"uid":"ef1d-72","name":"ListLoadingTracker.ts"},{"uid":"ef1d-74","name":"DbRef.ts"},{"uid":"ef1d-76","name":"reactHooks.ts"}]},{"name":"node_modules/tslib/tslib.es6.js","uid":"ef1d-60"}]}]}],"isRoot":true},"nodeParts":{"ef1d-54":{"renderedLength":232,"gzipLength":0,"brotliLength":0,"metaUid":"ef1d-53"},"ef1d-56":{"renderedLength":775,"gzipLength":0,"brotliLength":0,"metaUid":"ef1d-55"},"ef1d-58":{"renderedLength":2104,"gzipLength":0,"brotliLength":0,"metaUid":"ef1d-57"},"ef1d-60":{"renderedLength":1979,"gzipLength":0,"brotliLength":0,"metaUid":"ef1d-59"},"ef1d-62":{"renderedLength":6566,"gzipLength":0,"brotliLength":0,"metaUid":"ef1d-61"},"ef1d-64":{"renderedLength":6081,"gzipLength":0,"brotliLength":0,"metaUid":"ef1d-63"},"ef1d-66":{"renderedLength":6328,"gzipLength":0,"brotliLength":0,"metaUid":"ef1d-65"},"ef1d-68":{"renderedLength":2277,"gzipLength":0,"brotliLength":0,"metaUid":"ef1d-67"},"ef1d-70":{"renderedLength":291,"gzipLength":0,"brotliLength":0,"metaUid":"ef1d-69"},"ef1d-72":{"renderedLength":2894,"gzipLength":0,"brotliLength":0,"metaUid":"ef1d-71"},"ef1d-74":{"renderedLength":5920,"gzipLength":0,"brotliLength":0,"metaUid":"ef1d-73"},"ef1d-76":{"renderedLength":442,"gzipLength":0,"brotliLength":0,"metaUid":"ef1d-75"}},"nodeMetas":{"ef1d-53":{"id":"/build/rollup:/@epam/uui-db/src/types.ts","moduleParts":{"index.esm.js":"ef1d-54"},"imported":[],"importedBy":[]},"ef1d-55":{"id":"/build/rollup:/@epam/uui-db/src/utils.ts","moduleParts":{"index.esm.js":"ef1d-56"},"imported":[],"importedBy":[]},"ef1d-57":{"id":"/build/rollup:/@epam/uui-db/src/Db.ts","moduleParts":{"index.esm.js":"ef1d-58"},"imported":[],"importedBy":[]},"ef1d-59":{"id":"/build/rollup:/@epam/uui-db/node_modules/tslib/tslib.es6.js","moduleParts":{"index.esm.js":"ef1d-60"},"imported":[],"importedBy":[]},"ef1d-61":{"id":"/build/rollup:/@epam/uui-db/src/DbTable.ts","moduleParts":{"index.esm.js":"ef1d-62"},"imported":[],"importedBy":[]},"ef1d-63":{"id":"/build/rollup:/@epam/uui-db/src/patchHelpers.ts","moduleParts":{"index.esm.js":"ef1d-64"},"imported":[],"importedBy":[]},"ef1d-65":{"id":"/build/rollup:/@epam/uui-db/src/tempIds.tsx","moduleParts":{"index.esm.js":"ef1d-66"},"imported":[],"importedBy":[]},"ef1d-67":{"id":"/build/rollup:/@epam/uui-db/src/Loader.ts","moduleParts":{"index.esm.js":"ef1d-68"},"imported":[],"importedBy":[]},"ef1d-69":{"id":"/build/rollup:/@epam/uui-db/src/SimpleLoadingTracker.ts","moduleParts":{"index.esm.js":"ef1d-70"},"imported":[],"importedBy":[]},"ef1d-71":{"id":"/build/rollup:/@epam/uui-db/src/ListLoadingTracker.ts","moduleParts":{"index.esm.js":"ef1d-72"},"imported":[],"importedBy":[]},"ef1d-73":{"id":"/build/rollup:/@epam/uui-db/src/DbRef.ts","moduleParts":{"index.esm.js":"ef1d-74"},"imported":[],"importedBy":[]},"ef1d-75":{"id":"/build/rollup:/@epam/uui-db/src/reactHooks.ts","moduleParts":{"index.esm.js":"ef1d-76"},"imported":[],"importedBy":[]},"ef1d-77":{"id":"/index.tsx","moduleParts":{},"imported":[{"uid":"ef1d-78"}],"importedBy":[],"isEntry":true},"ef1d-78":{"id":"/src/index.ts","moduleParts":{},"imported":[{"uid":"ef1d-79"},{"uid":"ef1d-80"},{"uid":"ef1d-81"},{"uid":"ef1d-82"},{"uid":"ef1d-83"},{"uid":"ef1d-84"},{"uid":"ef1d-85"},{"uid":"ef1d-86"}],"importedBy":[{"uid":"ef1d-77"}]},"ef1d-79":{"id":"/src/types.ts","moduleParts":{},"imported":[],"importedBy":[{"uid":"ef1d-78"},{"uid":"ef1d-85"}]},"ef1d-80":{"id":"/src/Db.ts","moduleParts":{},"imported":[{"uid":"ef1d-84"},{"uid":"ef1d-87"}],"importedBy":[{"uid":"ef1d-78"}]},"ef1d-81":{"id":"/src/DbTable.ts","moduleParts":{},"imported":[{"uid":"ef1d-88"},{"uid":"ef1d-89"},{"uid":"ef1d-90"}],"importedBy":[{"uid":"ef1d-78"}]},"ef1d-82":{"id":"/src/DbRef.ts","moduleParts":{},"imported":[{"uid":"ef1d-88"},{"uid":"ef1d-85"},{"uid":"ef1d-83"},{"uid":"ef1d-84"},{"uid":"ef1d-91"},{"uid":"ef1d-92"},{"uid":"ef1d-90"},{"uid":"ef1d-93"},{"uid":"ef1d-94"}],"importedBy":[{"uid":"ef1d-78"}]},"ef1d-83":{"id":"/src/tempIds.tsx","moduleParts":{},"imported":[{"uid":"ef1d-84"}],"importedBy":[{"uid":"ef1d-78"},{"uid":"ef1d-82"}]},"ef1d-84":{"id":"/src/utils.ts","moduleParts":{},"imported":[{"uid":"ef1d-95"},{"uid":"ef1d-96"},{"uid":"ef1d-97"},{"uid":"ef1d-87"}],"importedBy":[{"uid":"ef1d-78"},{"uid":"ef1d-80"},{"uid":"ef1d-82"},{"uid":"ef1d-83"},{"uid":"ef1d-85"}]},"ef1d-85":{"id":"/src/patchHelpers.ts","moduleParts":{},"imported":[{"uid":"ef1d-79"},{"uid":"ef1d-89"},{"uid":"ef1d-84"},{"uid":"ef1d-98"},{"uid":"ef1d-99"},{"uid":"ef1d-100"},{"uid":"ef1d-101"},{"uid":"ef1d-102"},{"uid":"ef1d-103"},{"uid":"ef1d-104"}],"importedBy":[{"uid":"ef1d-78"},{"uid":"ef1d-82"}]},"ef1d-86":{"id":"/src/reactHooks.ts","moduleParts":{},"imported":[{"uid":"ef1d-105"}],"importedBy":[{"uid":"ef1d-78"}]},"ef1d-87":{"id":"lodash.isequal","moduleParts":{},"imported":[],"importedBy":[{"uid":"ef1d-80"},{"uid":"ef1d-84"}],"isExternal":true},"ef1d-88":{"id":"/Users/Aliaksei_Manetau/WebstormProjects/uui/node_modules/tslib/tslib.es6.js","moduleParts":{},"imported":[],"importedBy":[{"uid":"ef1d-81"},{"uid":"ef1d-82"},{"uid":"ef1d-94"}]},"ef1d-89":{"id":"immutable","moduleParts":{},"imported":[],"importedBy":[{"uid":"ef1d-81"},{"uid":"ef1d-85"}],"isExternal":true},"ef1d-90":{"id":"@epam/uui-core","moduleParts":{},"imported":[],"importedBy":[{"uid":"ef1d-81"},{"uid":"ef1d-82"}],"isExternal":true},"ef1d-91":{"id":"lodash.isempty","moduleParts":{},"imported":[],"importedBy":[{"uid":"ef1d-82"}],"isExternal":true},"ef1d-92":{"id":"/src/Loader.ts","moduleParts":{},"imported":[],"importedBy":[{"uid":"ef1d-82"}]},"ef1d-93":{"id":"/src/SimpleLoadingTracker.ts","moduleParts":{},"imported":[],"importedBy":[{"uid":"ef1d-82"}]},"ef1d-94":{"id":"/src/ListLoadingTracker.ts","moduleParts":{},"imported":[{"uid":"ef1d-88"}],"importedBy":[{"uid":"ef1d-82"}]},"ef1d-95":{"id":"shallowequal","moduleParts":{},"imported":[],"importedBy":[{"uid":"ef1d-84"}],"isExternal":true},"ef1d-96":{"id":"lodash.zip","moduleParts":{},"imported":[],"importedBy":[{"uid":"ef1d-84"}],"isExternal":true},"ef1d-97":{"id":"lodash.transform","moduleParts":{},"imported":[],"importedBy":[{"uid":"ef1d-84"}],"isExternal":true},"ef1d-98":{"id":"lodash.groupby","moduleParts":{},"imported":[],"importedBy":[{"uid":"ef1d-85"}],"isExternal":true},"ef1d-99":{"id":"lodash.map","moduleParts":{},"imported":[],"importedBy":[{"uid":"ef1d-85"}],"isExternal":true},"ef1d-100":{"id":"lodash.merge","moduleParts":{},"imported":[],"importedBy":[{"uid":"ef1d-85"}],"isExternal":true},"ef1d-101":{"id":"lodash.countby","moduleParts":{},"imported":[],"importedBy":[{"uid":"ef1d-85"}],"isExternal":true},"ef1d-102":{"id":"lodash.filter","moduleParts":{},"imported":[],"importedBy":[{"uid":"ef1d-85"}],"isExternal":true},"ef1d-103":{"id":"lodash.foreach","moduleParts":{},"imported":[],"importedBy":[{"uid":"ef1d-85"}],"isExternal":true},"ef1d-104":{"id":"lodash.pick","moduleParts":{},"imported":[],"importedBy":[{"uid":"ef1d-85"}],"isExternal":true},"ef1d-105":{"id":"react","moduleParts":{},"imported":[],"importedBy":[{"uid":"ef1d-86"}],"isExternal":true}},"env":{"rollup":"3.22.0"},"options":{"gzip":false,"brotli":false,"sourcemap":true}};
6160
+ const data = {"version":2,"tree":{"name":"root","children":[{"name":"index.esm.js","children":[{"name":"build/rollup:/@epam/uui-db","children":[{"name":"src","children":[{"uid":"eb03-54","name":"types.ts"},{"uid":"eb03-56","name":"utils.ts"},{"uid":"eb03-58","name":"Db.ts"},{"uid":"eb03-62","name":"DbTable.ts"},{"uid":"eb03-64","name":"patchHelpers.ts"},{"uid":"eb03-66","name":"tempIds.tsx"},{"uid":"eb03-68","name":"Loader.ts"},{"uid":"eb03-70","name":"SimpleLoadingTracker.ts"},{"uid":"eb03-72","name":"ListLoadingTracker.ts"},{"uid":"eb03-74","name":"DbRef.ts"},{"uid":"eb03-76","name":"reactHooks.ts"}]},{"name":"node_modules/tslib/tslib.es6.js","uid":"eb03-60"}]}]}],"isRoot":true},"nodeParts":{"eb03-54":{"renderedLength":232,"gzipLength":0,"brotliLength":0,"metaUid":"eb03-53"},"eb03-56":{"renderedLength":775,"gzipLength":0,"brotliLength":0,"metaUid":"eb03-55"},"eb03-58":{"renderedLength":2104,"gzipLength":0,"brotliLength":0,"metaUid":"eb03-57"},"eb03-60":{"renderedLength":1979,"gzipLength":0,"brotliLength":0,"metaUid":"eb03-59"},"eb03-62":{"renderedLength":6566,"gzipLength":0,"brotliLength":0,"metaUid":"eb03-61"},"eb03-64":{"renderedLength":6081,"gzipLength":0,"brotliLength":0,"metaUid":"eb03-63"},"eb03-66":{"renderedLength":6328,"gzipLength":0,"brotliLength":0,"metaUid":"eb03-65"},"eb03-68":{"renderedLength":2277,"gzipLength":0,"brotliLength":0,"metaUid":"eb03-67"},"eb03-70":{"renderedLength":291,"gzipLength":0,"brotliLength":0,"metaUid":"eb03-69"},"eb03-72":{"renderedLength":2894,"gzipLength":0,"brotliLength":0,"metaUid":"eb03-71"},"eb03-74":{"renderedLength":5920,"gzipLength":0,"brotliLength":0,"metaUid":"eb03-73"},"eb03-76":{"renderedLength":442,"gzipLength":0,"brotliLength":0,"metaUid":"eb03-75"}},"nodeMetas":{"eb03-53":{"id":"\\build\\rollup:\\@epam\\uui-db\\src\\types.ts","moduleParts":{"index.esm.js":"eb03-54"},"imported":[],"importedBy":[]},"eb03-55":{"id":"\\build\\rollup:\\@epam\\uui-db\\src\\utils.ts","moduleParts":{"index.esm.js":"eb03-56"},"imported":[],"importedBy":[]},"eb03-57":{"id":"\\build\\rollup:\\@epam\\uui-db\\src\\Db.ts","moduleParts":{"index.esm.js":"eb03-58"},"imported":[],"importedBy":[]},"eb03-59":{"id":"\\build\\rollup:\\@epam\\uui-db\\node_modules\\tslib\\tslib.es6.js","moduleParts":{"index.esm.js":"eb03-60"},"imported":[],"importedBy":[]},"eb03-61":{"id":"\\build\\rollup:\\@epam\\uui-db\\src\\DbTable.ts","moduleParts":{"index.esm.js":"eb03-62"},"imported":[],"importedBy":[]},"eb03-63":{"id":"\\build\\rollup:\\@epam\\uui-db\\src\\patchHelpers.ts","moduleParts":{"index.esm.js":"eb03-64"},"imported":[],"importedBy":[]},"eb03-65":{"id":"\\build\\rollup:\\@epam\\uui-db\\src\\tempIds.tsx","moduleParts":{"index.esm.js":"eb03-66"},"imported":[],"importedBy":[]},"eb03-67":{"id":"\\build\\rollup:\\@epam\\uui-db\\src\\Loader.ts","moduleParts":{"index.esm.js":"eb03-68"},"imported":[],"importedBy":[]},"eb03-69":{"id":"\\build\\rollup:\\@epam\\uui-db\\src\\SimpleLoadingTracker.ts","moduleParts":{"index.esm.js":"eb03-70"},"imported":[],"importedBy":[]},"eb03-71":{"id":"\\build\\rollup:\\@epam\\uui-db\\src\\ListLoadingTracker.ts","moduleParts":{"index.esm.js":"eb03-72"},"imported":[],"importedBy":[]},"eb03-73":{"id":"\\build\\rollup:\\@epam\\uui-db\\src\\DbRef.ts","moduleParts":{"index.esm.js":"eb03-74"},"imported":[],"importedBy":[]},"eb03-75":{"id":"\\build\\rollup:\\@epam\\uui-db\\src\\reactHooks.ts","moduleParts":{"index.esm.js":"eb03-76"},"imported":[],"importedBy":[]},"eb03-77":{"id":"\\index.tsx","moduleParts":{},"imported":[{"uid":"eb03-78"}],"importedBy":[],"isEntry":true},"eb03-78":{"id":"\\src\\index.ts","moduleParts":{},"imported":[{"uid":"eb03-79"},{"uid":"eb03-80"},{"uid":"eb03-81"},{"uid":"eb03-82"},{"uid":"eb03-83"},{"uid":"eb03-84"},{"uid":"eb03-85"},{"uid":"eb03-86"}],"importedBy":[{"uid":"eb03-77"}]},"eb03-79":{"id":"\\src\\types.ts","moduleParts":{},"imported":[],"importedBy":[{"uid":"eb03-78"},{"uid":"eb03-85"}]},"eb03-80":{"id":"\\src\\Db.ts","moduleParts":{},"imported":[{"uid":"eb03-84"},{"uid":"eb03-87"}],"importedBy":[{"uid":"eb03-78"}]},"eb03-81":{"id":"\\src\\DbTable.ts","moduleParts":{},"imported":[{"uid":"eb03-88"},{"uid":"eb03-89"},{"uid":"eb03-90"}],"importedBy":[{"uid":"eb03-78"}]},"eb03-82":{"id":"\\src\\DbRef.ts","moduleParts":{},"imported":[{"uid":"eb03-88"},{"uid":"eb03-85"},{"uid":"eb03-83"},{"uid":"eb03-84"},{"uid":"eb03-91"},{"uid":"eb03-92"},{"uid":"eb03-90"},{"uid":"eb03-93"},{"uid":"eb03-94"}],"importedBy":[{"uid":"eb03-78"}]},"eb03-83":{"id":"\\src\\tempIds.tsx","moduleParts":{},"imported":[{"uid":"eb03-84"}],"importedBy":[{"uid":"eb03-78"},{"uid":"eb03-82"}]},"eb03-84":{"id":"\\src\\utils.ts","moduleParts":{},"imported":[{"uid":"eb03-95"},{"uid":"eb03-96"},{"uid":"eb03-97"},{"uid":"eb03-87"}],"importedBy":[{"uid":"eb03-78"},{"uid":"eb03-80"},{"uid":"eb03-82"},{"uid":"eb03-83"},{"uid":"eb03-85"}]},"eb03-85":{"id":"\\src\\patchHelpers.ts","moduleParts":{},"imported":[{"uid":"eb03-79"},{"uid":"eb03-89"},{"uid":"eb03-84"},{"uid":"eb03-98"},{"uid":"eb03-99"},{"uid":"eb03-100"},{"uid":"eb03-101"},{"uid":"eb03-102"},{"uid":"eb03-103"},{"uid":"eb03-104"}],"importedBy":[{"uid":"eb03-78"},{"uid":"eb03-82"}]},"eb03-86":{"id":"\\src\\reactHooks.ts","moduleParts":{},"imported":[{"uid":"eb03-105"}],"importedBy":[{"uid":"eb03-78"}]},"eb03-87":{"id":"lodash.isequal","moduleParts":{},"imported":[],"importedBy":[{"uid":"eb03-80"},{"uid":"eb03-84"}],"isExternal":true},"eb03-88":{"id":"D:\\dev\\UUI-main\\node_modules\\tslib\\tslib.es6.js","moduleParts":{},"imported":[],"importedBy":[{"uid":"eb03-81"},{"uid":"eb03-82"},{"uid":"eb03-94"}]},"eb03-89":{"id":"immutable","moduleParts":{},"imported":[],"importedBy":[{"uid":"eb03-81"},{"uid":"eb03-85"}],"isExternal":true},"eb03-90":{"id":"@epam/uui-core","moduleParts":{},"imported":[],"importedBy":[{"uid":"eb03-81"},{"uid":"eb03-82"}],"isExternal":true},"eb03-91":{"id":"lodash.isempty","moduleParts":{},"imported":[],"importedBy":[{"uid":"eb03-82"}],"isExternal":true},"eb03-92":{"id":"\\src\\Loader.ts","moduleParts":{},"imported":[],"importedBy":[{"uid":"eb03-82"}]},"eb03-93":{"id":"\\src\\SimpleLoadingTracker.ts","moduleParts":{},"imported":[],"importedBy":[{"uid":"eb03-82"}]},"eb03-94":{"id":"\\src\\ListLoadingTracker.ts","moduleParts":{},"imported":[{"uid":"eb03-88"}],"importedBy":[{"uid":"eb03-82"}]},"eb03-95":{"id":"shallowequal","moduleParts":{},"imported":[],"importedBy":[{"uid":"eb03-84"}],"isExternal":true},"eb03-96":{"id":"lodash.zip","moduleParts":{},"imported":[],"importedBy":[{"uid":"eb03-84"}],"isExternal":true},"eb03-97":{"id":"lodash.transform","moduleParts":{},"imported":[],"importedBy":[{"uid":"eb03-84"}],"isExternal":true},"eb03-98":{"id":"lodash.groupby","moduleParts":{},"imported":[],"importedBy":[{"uid":"eb03-85"}],"isExternal":true},"eb03-99":{"id":"lodash.map","moduleParts":{},"imported":[],"importedBy":[{"uid":"eb03-85"}],"isExternal":true},"eb03-100":{"id":"lodash.merge","moduleParts":{},"imported":[],"importedBy":[{"uid":"eb03-85"}],"isExternal":true},"eb03-101":{"id":"lodash.countby","moduleParts":{},"imported":[],"importedBy":[{"uid":"eb03-85"}],"isExternal":true},"eb03-102":{"id":"lodash.filter","moduleParts":{},"imported":[],"importedBy":[{"uid":"eb03-85"}],"isExternal":true},"eb03-103":{"id":"lodash.foreach","moduleParts":{},"imported":[],"importedBy":[{"uid":"eb03-85"}],"isExternal":true},"eb03-104":{"id":"lodash.pick","moduleParts":{},"imported":[],"importedBy":[{"uid":"eb03-85"}],"isExternal":true},"eb03-105":{"id":"react","moduleParts":{},"imported":[],"importedBy":[{"uid":"eb03-86"}],"isExternal":true}},"env":{"rollup":"3.22.0"},"options":{"gzip":false,"brotli":false,"sourcemap":true}};
6161
6161
 
6162
6162
  const run = () => {
6163
6163
  const width = window.innerWidth;