tinybase 3.1.0-beta.4 → 3.1.0-beta.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (85) hide show
  1. package/lib/debug/ui-react.js +2 -2
  2. package/lib/{cjs-es6 → types}/checkpoints.d.ts +11 -13
  3. package/lib/{debug → types}/indexes.d.ts +8 -16
  4. package/lib/{debug → types}/metrics.d.ts +47 -50
  5. package/lib/{cjs → types}/persisters.d.ts +24 -30
  6. package/lib/{cjs-es6 → types}/queries.d.ts +472 -309
  7. package/lib/{debug → types}/relationships.d.ts +9 -17
  8. package/lib/{cjs-es6 → types}/store.d.ts +176 -1084
  9. package/lib/types/tinybase.d.ts +14 -0
  10. package/lib/{cjs-es6 → types}/tools.d.ts +7 -12
  11. package/lib/{debug → types}/ui-react.d.ts +11 -5
  12. package/lib/{checkpoints.d.ts → types/with-schemas/checkpoints.d.ts} +9 -7
  13. package/lib/{cjs → types/with-schemas}/indexes.d.ts +31 -18
  14. package/lib/types/with-schemas/internal/queries.d.ts +15 -0
  15. package/lib/types/with-schemas/internal/store.d.ts +101 -0
  16. package/lib/types/with-schemas/internal/ui-react.d.ts +776 -0
  17. package/lib/{cjs → types/with-schemas}/metrics.d.ts +54 -50
  18. package/lib/{debug → types/with-schemas}/persisters.d.ts +4 -4
  19. package/lib/{debug → types/with-schemas}/queries.d.ts +607 -346
  20. package/lib/{cjs → types/with-schemas}/relationships.d.ts +29 -20
  21. package/lib/{debug → types/with-schemas}/store.d.ts +386 -829
  22. package/lib/types/with-schemas/tinybase.d.ts +14 -0
  23. package/lib/{debug → types/with-schemas}/tools.d.ts +7 -10
  24. package/lib/{cjs-es6 → types/with-schemas}/ui-react.d.ts +817 -1314
  25. package/package.json +145 -29
  26. package/readme.md +3 -3
  27. package/lib/cjs/checkpoints.d.ts +0 -961
  28. package/lib/cjs/queries.d.ts +0 -3028
  29. package/lib/cjs/store.d.ts +0 -6143
  30. package/lib/cjs/tinybase.d.ts +0 -14
  31. package/lib/cjs/tools.d.ts +0 -536
  32. package/lib/cjs/ui-react.d.ts +0 -10921
  33. package/lib/cjs-es6/indexes.d.ts +0 -974
  34. package/lib/cjs-es6/metrics.d.ts +0 -829
  35. package/lib/cjs-es6/persisters.d.ts +0 -733
  36. package/lib/cjs-es6/relationships.d.ts +0 -1209
  37. package/lib/cjs-es6/tinybase.d.ts +0 -14
  38. package/lib/common.d.ts +0 -115
  39. package/lib/debug/checkpoints.d.ts +0 -961
  40. package/lib/debug/common.d.ts +0 -115
  41. package/lib/debug/tinybase.d.ts +0 -14
  42. package/lib/es6/checkpoints.d.ts +0 -961
  43. package/lib/es6/common.d.ts +0 -115
  44. package/lib/es6/indexes.d.ts +0 -974
  45. package/lib/es6/metrics.d.ts +0 -829
  46. package/lib/es6/persisters.d.ts +0 -733
  47. package/lib/es6/queries.d.ts +0 -3028
  48. package/lib/es6/relationships.d.ts +0 -1209
  49. package/lib/es6/store.d.ts +0 -6143
  50. package/lib/es6/tinybase.d.ts +0 -14
  51. package/lib/es6/tools.d.ts +0 -536
  52. package/lib/es6/ui-react.d.ts +0 -10921
  53. package/lib/indexes.d.ts +0 -974
  54. package/lib/metrics.d.ts +0 -829
  55. package/lib/persisters.d.ts +0 -733
  56. package/lib/queries.d.ts +0 -3028
  57. package/lib/relationships.d.ts +0 -1209
  58. package/lib/store.d.ts +0 -6143
  59. package/lib/tinybase.d.ts +0 -14
  60. package/lib/tools.d.ts +0 -536
  61. package/lib/ui-react.d.ts +0 -10921
  62. package/lib/umd/checkpoints.d.ts +0 -961
  63. package/lib/umd/common.d.ts +0 -115
  64. package/lib/umd/indexes.d.ts +0 -974
  65. package/lib/umd/metrics.d.ts +0 -829
  66. package/lib/umd/persisters.d.ts +0 -733
  67. package/lib/umd/queries.d.ts +0 -3028
  68. package/lib/umd/relationships.d.ts +0 -1209
  69. package/lib/umd/store.d.ts +0 -6143
  70. package/lib/umd/tinybase.d.ts +0 -14
  71. package/lib/umd/tools.d.ts +0 -536
  72. package/lib/umd/ui-react.d.ts +0 -10921
  73. package/lib/umd-es6/checkpoints.d.ts +0 -961
  74. package/lib/umd-es6/common.d.ts +0 -115
  75. package/lib/umd-es6/indexes.d.ts +0 -974
  76. package/lib/umd-es6/metrics.d.ts +0 -829
  77. package/lib/umd-es6/persisters.d.ts +0 -733
  78. package/lib/umd-es6/queries.d.ts +0 -3028
  79. package/lib/umd-es6/relationships.d.ts +0 -1209
  80. package/lib/umd-es6/store.d.ts +0 -6143
  81. package/lib/umd-es6/tinybase.d.ts +0 -14
  82. package/lib/umd-es6/tools.d.ts +0 -536
  83. package/lib/umd-es6/ui-react.d.ts +0 -10921
  84. /package/lib/{cjs-es6 → types}/common.d.ts +0 -0
  85. /package/lib/{cjs → types/with-schemas}/common.d.ts +0 -0
@@ -11,13 +11,7 @@
11
11
  * @module relationships
12
12
  */
13
13
 
14
- import {
15
- GetCell,
16
- NoSchemas,
17
- OptionalSchemas,
18
- RowCallback,
19
- Store,
20
- } from './store.d';
14
+ import {GetCell, RowCallback, Store} from './store.d';
21
15
  import {Id, IdOrNull, Ids} from './common.d';
22
16
 
23
17
  /**
@@ -253,7 +247,7 @@ export type RelationshipsListenerStats = {
253
247
  * @see Drawing demo
254
248
  * @category Relationships
255
249
  */
256
- export interface Relationships<Schemas extends OptionalSchemas = NoSchemas> {
250
+ export interface Relationships {
257
251
  /**
258
252
  * The setRelationshipDefinition method lets you set the definition of a
259
253
  * Relationship.
@@ -345,7 +339,7 @@ export interface Relationships<Schemas extends OptionalSchemas = NoSchemas> {
345
339
  localTableId: Id,
346
340
  remoteTableId: Id,
347
341
  getRemoteRowId: Id | ((getCell: GetCell, localRowId: Id) => Id),
348
- ): Relationships<Schemas>;
342
+ ): Relationships;
349
343
 
350
344
  /**
351
345
  * The delRelationshipDefinition method removes an existing Relationship
@@ -385,7 +379,7 @@ export interface Relationships<Schemas extends OptionalSchemas = NoSchemas> {
385
379
  * ```
386
380
  * @category Configuration
387
381
  */
388
- delRelationshipDefinition(relationshipId: Id): Relationships<Schemas>;
382
+ delRelationshipDefinition(relationshipId: Id): Relationships;
389
383
 
390
384
  /**
391
385
  * The getStore method returns a reference to the underlying Store that is
@@ -410,7 +404,7 @@ export interface Relationships<Schemas extends OptionalSchemas = NoSchemas> {
410
404
  * ```
411
405
  * @category Getter
412
406
  */
413
- getStore(): Store<Schemas>;
407
+ getStore(): Store;
414
408
 
415
409
  /**
416
410
  * The getRelationshipIds method returns an array of the Relationship Ids
@@ -528,7 +522,7 @@ export interface Relationships<Schemas extends OptionalSchemas = NoSchemas> {
528
522
  * ```
529
523
  * @category Getter
530
524
  */
531
- getLocalTableId(relationshipId: Id): Id;
525
+ getLocalTableId(relationshipId: Id): Id | undefined;
532
526
 
533
527
  /**
534
528
  * The getRemoteTableId method returns the Id of the underlying remote Table
@@ -560,7 +554,7 @@ export interface Relationships<Schemas extends OptionalSchemas = NoSchemas> {
560
554
  * ```
561
555
  * @category Getter
562
556
  */
563
- getRemoteTableId(relationshipId: Id): Id;
557
+ getRemoteTableId(relationshipId: Id): Id | undefined;
564
558
 
565
559
  /**
566
560
  * The getRemoteRowId method gets the remote Row Id for a given local Row in a
@@ -1087,7 +1081,7 @@ export interface Relationships<Schemas extends OptionalSchemas = NoSchemas> {
1087
1081
  * ```
1088
1082
  * @category Listener
1089
1083
  */
1090
- delListener(listenerId: Id): Relationships<Schemas>;
1084
+ delListener(listenerId: Id): Relationships;
1091
1085
 
1092
1086
  /**
1093
1087
  * The destroy method should be called when this Relationships object is no
@@ -1204,6 +1198,4 @@ export interface Relationships<Schemas extends OptionalSchemas = NoSchemas> {
1204
1198
  * ```
1205
1199
  * @category Creation
1206
1200
  */
1207
- export function createRelationships<Schemas extends OptionalSchemas>(
1208
- store: Store<Schemas>,
1209
- ): Relationships<Schemas>;
1201
+ export function createRelationships(store: Store): Relationships;