tinybase 5.0.1 → 5.0.3

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 (82) hide show
  1. package/@types/synchronizers/synchronizer-ws-server/index.d.cts +32 -27
  2. package/@types/synchronizers/synchronizer-ws-server/index.d.ts +32 -27
  3. package/@types/synchronizers/synchronizer-ws-server/with-schemas/index.d.cts +32 -27
  4. package/@types/synchronizers/synchronizer-ws-server/with-schemas/index.d.ts +32 -27
  5. package/@types/ui-react/index.d.cts +62 -45
  6. package/@types/ui-react/index.d.ts +62 -45
  7. package/@types/ui-react/with-schemas/index.d.cts +83 -59
  8. package/@types/ui-react/with-schemas/index.d.ts +83 -59
  9. package/cjs/es6/min/synchronizers/synchronizer-ws-server/index.cjs +1 -1
  10. package/cjs/es6/min/synchronizers/synchronizer-ws-server/index.cjs.gz +0 -0
  11. package/cjs/es6/min/synchronizers/synchronizer-ws-server/with-schemas/index.cjs +1 -1
  12. package/cjs/es6/min/synchronizers/synchronizer-ws-server/with-schemas/index.cjs.gz +0 -0
  13. package/cjs/es6/min/ui-react/index.cjs +1 -1
  14. package/cjs/es6/min/ui-react/index.cjs.gz +0 -0
  15. package/cjs/es6/min/ui-react/with-schemas/index.cjs +1 -1
  16. package/cjs/es6/min/ui-react/with-schemas/index.cjs.gz +0 -0
  17. package/cjs/es6/synchronizers/synchronizer-ws-server/index.cjs +4 -6
  18. package/cjs/es6/synchronizers/synchronizer-ws-server/with-schemas/index.cjs +4 -6
  19. package/cjs/es6/ui-react/index.cjs +13 -6
  20. package/cjs/es6/ui-react/with-schemas/index.cjs +13 -6
  21. package/cjs/min/synchronizers/synchronizer-ws-server/index.cjs +1 -1
  22. package/cjs/min/synchronizers/synchronizer-ws-server/index.cjs.gz +0 -0
  23. package/cjs/min/synchronizers/synchronizer-ws-server/with-schemas/index.cjs +1 -1
  24. package/cjs/min/synchronizers/synchronizer-ws-server/with-schemas/index.cjs.gz +0 -0
  25. package/cjs/min/ui-react/index.cjs +1 -1
  26. package/cjs/min/ui-react/index.cjs.gz +0 -0
  27. package/cjs/min/ui-react/with-schemas/index.cjs +1 -1
  28. package/cjs/min/ui-react/with-schemas/index.cjs.gz +0 -0
  29. package/cjs/synchronizers/synchronizer-ws-server/index.cjs +4 -4
  30. package/cjs/synchronizers/synchronizer-ws-server/with-schemas/index.cjs +4 -4
  31. package/cjs/ui-react/index.cjs +11 -6
  32. package/cjs/ui-react/with-schemas/index.cjs +11 -6
  33. package/es6/min/synchronizers/synchronizer-ws-server/index.js +1 -1
  34. package/es6/min/synchronizers/synchronizer-ws-server/index.js.gz +0 -0
  35. package/es6/min/synchronizers/synchronizer-ws-server/with-schemas/index.js +1 -1
  36. package/es6/min/synchronizers/synchronizer-ws-server/with-schemas/index.js.gz +0 -0
  37. package/es6/min/ui-react/index.js +1 -1
  38. package/es6/min/ui-react/index.js.gz +0 -0
  39. package/es6/min/ui-react/with-schemas/index.js +1 -1
  40. package/es6/min/ui-react/with-schemas/index.js.gz +0 -0
  41. package/es6/synchronizers/synchronizer-ws-server/index.js +4 -6
  42. package/es6/synchronizers/synchronizer-ws-server/with-schemas/index.js +4 -6
  43. package/es6/ui-react/index.js +13 -6
  44. package/es6/ui-react/with-schemas/index.js +13 -6
  45. package/min/synchronizers/synchronizer-ws-server/index.js +1 -1
  46. package/min/synchronizers/synchronizer-ws-server/index.js.gz +0 -0
  47. package/min/synchronizers/synchronizer-ws-server/with-schemas/index.js +1 -1
  48. package/min/synchronizers/synchronizer-ws-server/with-schemas/index.js.gz +0 -0
  49. package/min/ui-react/index.js +1 -1
  50. package/min/ui-react/index.js.gz +0 -0
  51. package/min/ui-react/with-schemas/index.js +1 -1
  52. package/min/ui-react/with-schemas/index.js.gz +0 -0
  53. package/package.json +1 -1
  54. package/readme.md +2 -2
  55. package/synchronizers/synchronizer-ws-server/index.js +4 -4
  56. package/synchronizers/synchronizer-ws-server/with-schemas/index.js +4 -4
  57. package/ui-react/index.js +11 -6
  58. package/ui-react/with-schemas/index.js +11 -6
  59. package/umd/es6/min/synchronizers/synchronizer-ws-server/index.js +1 -1
  60. package/umd/es6/min/synchronizers/synchronizer-ws-server/index.js.gz +0 -0
  61. package/umd/es6/min/synchronizers/synchronizer-ws-server/with-schemas/index.js +1 -1
  62. package/umd/es6/min/synchronizers/synchronizer-ws-server/with-schemas/index.js.gz +0 -0
  63. package/umd/es6/min/ui-react/index.js +1 -1
  64. package/umd/es6/min/ui-react/index.js.gz +0 -0
  65. package/umd/es6/min/ui-react/with-schemas/index.js +1 -1
  66. package/umd/es6/min/ui-react/with-schemas/index.js.gz +0 -0
  67. package/umd/es6/synchronizers/synchronizer-ws-server/index.js +4 -6
  68. package/umd/es6/synchronizers/synchronizer-ws-server/with-schemas/index.js +4 -6
  69. package/umd/es6/ui-react/index.js +16 -6
  70. package/umd/es6/ui-react/with-schemas/index.js +16 -6
  71. package/umd/min/synchronizers/synchronizer-ws-server/index.js +1 -1
  72. package/umd/min/synchronizers/synchronizer-ws-server/index.js.gz +0 -0
  73. package/umd/min/synchronizers/synchronizer-ws-server/with-schemas/index.js +1 -1
  74. package/umd/min/synchronizers/synchronizer-ws-server/with-schemas/index.js.gz +0 -0
  75. package/umd/min/ui-react/index.js +1 -1
  76. package/umd/min/ui-react/index.js.gz +0 -0
  77. package/umd/min/ui-react/with-schemas/index.js +1 -1
  78. package/umd/min/ui-react/with-schemas/index.js.gz +0 -0
  79. package/umd/synchronizers/synchronizer-ws-server/index.js +4 -6
  80. package/umd/synchronizers/synchronizer-ws-server/with-schemas/index.js +4 -6
  81. package/umd/ui-react/index.js +12 -6
  82. package/umd/ui-react/with-schemas/index.js +12 -6
@@ -2684,7 +2684,7 @@ export function useSetTablesCallback<Parameter>(
2684
2684
  * @param getTableDeps An optional array of dependencies for the `getTable`
2685
2685
  * function, which, if any change, result in the regeneration of the callback.
2686
2686
  * This parameter defaults to an empty array. Also use this to indicate the
2687
- * dependencies of a GetId functions if used as the tableId argument.
2687
+ * dependencies of a GetId function if used as the tableId argument.
2688
2688
  * @param storeOrStoreId The Store to be updated: omit for the default context
2689
2689
  * Store, provide an Id for a named context Store, or provide an explicit
2690
2690
  * reference.
@@ -2882,7 +2882,7 @@ export function useSetRowCallback<Parameter>(
2882
2882
  * @param getRowDeps An optional array of dependencies for the `getRow`
2883
2883
  * function, which, if any change, result in the regeneration of the callback.
2884
2884
  * This parameter defaults to an empty array. Also use this to indicate the
2885
- * dependencies of a GetId functions if used as the tableId argument.
2885
+ * dependencies of a GetId function if used as the tableId argument.
2886
2886
  * @param storeOrStoreId The Store to be updated: omit for the default context
2887
2887
  * Store, provide an Id for a named context Store, or provide an explicit
2888
2888
  * reference.
@@ -3466,7 +3466,7 @@ export function useSetValueCallback<Parameter>(
3466
3466
  * all of the tabular data in a Store.
3467
3467
  *
3468
3468
  * This hook is useful, for example, when creating an event handler that will
3469
- * delete data in a Store.
3469
+ * delete data in the Store.
3470
3470
  *
3471
3471
  * For convenience, you can optionally provide a `then` function (with its own
3472
3472
  * set of dependencies) which will be called just after the Store has been
@@ -3530,11 +3530,12 @@ export function useDelTablesCallback(
3530
3530
  ): Callback;
3531
3531
 
3532
3532
  /**
3533
- * The useDelTableCallback hook returns a callback that can be used to remove a
3534
- * single Table from a Store.
3533
+ * The useDelTableCallback hook returns a parameterized callback that can be
3534
+ * used to remove a single Table from a Store.
3535
3535
  *
3536
3536
  * This hook is useful, for example, when creating an event handler that will
3537
- * delete data in a Store.
3537
+ * delete data in the Store. In this case, the parameter will likely be the
3538
+ * event, so that you can use data from it as part of the deletion.
3538
3539
  *
3539
3540
  * For convenience, you can optionally provide a `then` function (with its own
3540
3541
  * set of dependencies) which will be called just after the Store has been
@@ -3544,7 +3545,8 @@ export function useDelTablesCallback(
3544
3545
  * The Store to which the callback will make the deletion (indicated by the
3545
3546
  * hook's `storeOrStoreId` parameter) is always automatically used as a hook
3546
3547
  * dependency for the callback.
3547
- * @param tableId The Id of the Table in the Store.
3548
+ * @param tableId The Id of the Table in the Store to delete, or a GetId
3549
+ * function that will return it.
3548
3550
  * @param storeOrStoreId The Store to be updated: omit for the default context
3549
3551
  * Store, provide an Id for a named context Store, or provide an explicit
3550
3552
  * reference.
@@ -3552,8 +3554,9 @@ export function useDelTablesCallback(
3552
3554
  * to the Store.
3553
3555
  * @param thenDeps An optional array of dependencies for the `then` function,
3554
3556
  * which, if any change, result in the regeneration of the callback. This
3555
- * parameter defaults to an empty array.
3556
- * @returns A callback for subsequent use.
3557
+ * parameter defaults to an empty array. Also use this to indicate the
3558
+ * dependencies of an GetId function if used as the tableId argument.
3559
+ * @returns A parameterized callback for subsequent use.
3557
3560
  * @example
3558
3561
  * This example uses the useDelTableCallback hook to create an event handler
3559
3562
  * which deletes from the Store when the `span` element is clicked.
@@ -3592,19 +3595,20 @@ export function useDelTablesCallback(
3592
3595
  * @category Store hooks
3593
3596
  * @since v1.0.0
3594
3597
  */
3595
- export function useDelTableCallback(
3596
- tableId: Id,
3598
+ export function useDelTableCallback<Parameter>(
3599
+ tableId: Id | GetId<Parameter>,
3597
3600
  storeOrStoreId?: StoreOrStoreId,
3598
3601
  then?: (store: Store) => void,
3599
3602
  thenDeps?: React.DependencyList,
3600
- ): Callback;
3603
+ ): ParameterizedCallback<Parameter>;
3601
3604
 
3602
3605
  /**
3603
- * The useDelRowCallback hook returns a callback that can be used to remove a
3604
- * single Row from a Table.
3606
+ * The useDelRowCallback hook returns a parameterized callback that can be used
3607
+ * to remove a single Row from a Table.
3605
3608
  *
3606
3609
  * This hook is useful, for example, when creating an event handler that will
3607
- * delete data in a Store.
3610
+ * delete data in the Store. In this case, the parameter will likely be the
3611
+ * event, so that you can use data from it as part of the deletion.
3608
3612
  *
3609
3613
  * For convenience, you can optionally provide a `then` function (with its own
3610
3614
  * set of dependencies) which will be called just after the Store has been
@@ -3614,8 +3618,10 @@ export function useDelTableCallback(
3614
3618
  * The Store to which the callback will make the deletion (indicated by the
3615
3619
  * hook's `storeOrStoreId` parameter) is always automatically used as a hook
3616
3620
  * dependency for the callback.
3617
- * @param tableId The Id of the Table in the Store.
3618
- * @param rowId The Id of the Row in the Table.
3621
+ * @param tableId The Id of the Table in the Store, or a GetId function that
3622
+ * will return it.
3623
+ * @param rowId The Id of the Row in the Table to delete, or a GetId function
3624
+ * that will return it.
3619
3625
  * @param storeOrStoreId The Store to be updated: omit for the default context
3620
3626
  * Store, provide an Id for a named context Store, or provide an explicit
3621
3627
  * reference.
@@ -3623,8 +3629,10 @@ export function useDelTableCallback(
3623
3629
  * to the Store.
3624
3630
  * @param thenDeps An optional array of dependencies for the `then` function,
3625
3631
  * which, if any change, result in the regeneration of the callback. This
3626
- * parameter defaults to an empty array.
3627
- * @returns A callback for subsequent use.
3632
+ * parameter defaults to an empty array. Also use this to indicate the
3633
+ * dependencies of any GetId functions if used as the tableId or rowId
3634
+ * arguments.
3635
+ * @returns A parameterized callback for subsequent use.
3628
3636
  * @example
3629
3637
  * This example uses the useDelRowCallback hook to create an event handler which
3630
3638
  * deletes from the Store when the `span` element is clicked.
@@ -3663,20 +3671,21 @@ export function useDelTableCallback(
3663
3671
  * @category Store hooks
3664
3672
  * @since v1.0.0
3665
3673
  */
3666
- export function useDelRowCallback(
3667
- tableId: Id,
3668
- rowId: Id,
3674
+ export function useDelRowCallback<Parameter>(
3675
+ tableId: Id | GetId<Parameter>,
3676
+ rowId: Id | GetId<Parameter>,
3669
3677
  storeOrStoreId?: StoreOrStoreId,
3670
3678
  then?: (store: Store) => void,
3671
3679
  thenDeps?: React.DependencyList,
3672
- ): Callback;
3680
+ ): ParameterizedCallback<Parameter>;
3673
3681
 
3674
3682
  /**
3675
- * The useDelCellCallback hook returns a callback that can be used to remove a
3676
- * single Cell from a Row.
3683
+ * The useDelCellCallback hook returns a parameterized callback that can be used
3684
+ * to remove a single Cell from a Row.
3677
3685
  *
3678
3686
  * This hook is useful, for example, when creating an event handler that will
3679
- * delete data in a Store.
3687
+ * delete data in the Store. In this case, the parameter will likely be the
3688
+ * event, so that you can use data from it as part of the deletion.
3680
3689
  *
3681
3690
  * For convenience, you can optionally provide a `then` function (with its own
3682
3691
  * set of dependencies) which will be called just after the Store has been
@@ -3686,9 +3695,12 @@ export function useDelRowCallback(
3686
3695
  * The Store to which the callback will make the deletion (indicated by the
3687
3696
  * hook's `storeOrStoreId` parameter) is always automatically used as a hook
3688
3697
  * dependency for the callback.
3689
- * @param tableId The Id of the Table in the Store.
3690
- * @param rowId The Id of the Row in the Table.
3691
- * @param cellId The Id of the Cell in the Row.
3698
+ * @param tableId The Id of the Table in the Store, or a GetId function that
3699
+ * will return it.
3700
+ * @param rowId The Id of the Row in the Table, or a GetId function that will
3701
+ * return it.
3702
+ * @param cellId The Id of the Cell in the Row to delete, or a GetId function
3703
+ * that will return it.
3692
3704
  * @param forceDel An optional flag to indicate that the whole Row should be
3693
3705
  * deleted, even if a TablesSchema provides a default value for this Cell.
3694
3706
  * Defaults to `false`.
@@ -3699,8 +3711,10 @@ export function useDelRowCallback(
3699
3711
  * to the Store.
3700
3712
  * @param thenDeps An optional array of dependencies for the `then` function,
3701
3713
  * which, if any change, result in the regeneration of the callback. This
3702
- * parameter defaults to an empty array.
3703
- * @returns A callback for subsequent use.
3714
+ * parameter defaults to an empty array. Also use this to indicate the
3715
+ * dependencies of any GetId functions if used as the tableId, rowId, or cellId
3716
+ * arguments.
3717
+ * @returns A parameterized callback for subsequent use.
3704
3718
  * @example
3705
3719
  * This example uses the useDelCellCallback hook to create an event handler
3706
3720
  * which deletes from the Store when the `span` element is clicked.
@@ -3744,15 +3758,15 @@ export function useDelRowCallback(
3744
3758
  * @category Store hooks
3745
3759
  * @since v1.0.0
3746
3760
  */
3747
- export function useDelCellCallback(
3748
- tableId: Id,
3749
- rowId: Id,
3750
- cellId: Id,
3761
+ export function useDelCellCallback<Parameter>(
3762
+ tableId: Id | GetId<Parameter>,
3763
+ rowId: Id | GetId<Parameter>,
3764
+ cellId: Id | GetId<Parameter>,
3751
3765
  forceDel?: boolean,
3752
3766
  storeOrStoreId?: StoreOrStoreId,
3753
3767
  then?: (store: Store) => void,
3754
3768
  thenDeps?: React.DependencyList,
3755
- ): Callback;
3769
+ ): ParameterizedCallback<Parameter>;
3756
3770
 
3757
3771
  /**
3758
3772
  * The useDelValuesCallback hook returns a callback that can be used to remove
@@ -3823,11 +3837,12 @@ export function useDelValuesCallback(
3823
3837
  ): Callback;
3824
3838
 
3825
3839
  /**
3826
- * The useDelValueCallback hook returns a callback that can be used to remove a
3827
- * single Value from a Store.
3840
+ * The useDelValueCallback hook returns a parameterized callback that can be
3841
+ * used to remove a single Value from a Store.
3828
3842
  *
3829
3843
  * This hook is useful, for example, when creating an event handler that will
3830
- * delete data in a Store.
3844
+ * delete data in the Store. In this case, the parameter will likely be the
3845
+ * event, so that you can use data from it as part of the deletion.
3831
3846
  *
3832
3847
  * For convenience, you can optionally provide a `then` function (with its own
3833
3848
  * set of dependencies) which will be called just after the Store has been
@@ -3837,7 +3852,8 @@ export function useDelValuesCallback(
3837
3852
  * The Store to which the callback will make the deletion (indicated by the
3838
3853
  * hook's `storeOrStoreId` parameter) is always automatically used as a hook
3839
3854
  * dependency for the callback.
3840
- * @param valueId The Id of the Value in the Store.
3855
+ * @param valueId The Id of the Value in the Store to delete, or a GetId
3856
+ * function that will return it.
3841
3857
  * @param storeOrStoreId The Store to be updated: omit for the default context
3842
3858
  * Store, provide an Id for a named context Store, or provide an explicit
3843
3859
  * reference.
@@ -3845,8 +3861,9 @@ export function useDelValuesCallback(
3845
3861
  * to the Store.
3846
3862
  * @param thenDeps An optional array of dependencies for the `then` function,
3847
3863
  * which, if any change, result in the regeneration of the callback. This
3848
- * parameter defaults to an empty array.
3849
- * @returns A callback for subsequent use.
3864
+ * parameter defaults to an empty array. Also use this to indicate the
3865
+ * dependencies of a GetId function if used as the valueId argument.
3866
+ * @returns A parameterized callback for subsequent use.
3850
3867
  * @example
3851
3868
  * This example uses the useDelValueCallback hook to create an event handler
3852
3869
  * which deletes from the Store when the `span` element is clicked.
@@ -3885,12 +3902,12 @@ export function useDelValuesCallback(
3885
3902
  * @category Store hooks
3886
3903
  * @since v3.0.0
3887
3904
  */
3888
- export function useDelValueCallback(
3889
- valueId: Id,
3905
+ export function useDelValueCallback<Parameter>(
3906
+ valueId: Id | GetId<Parameter>,
3890
3907
  storeOrStoreId?: StoreOrStoreId,
3891
3908
  then?: (store: Store) => void,
3892
3909
  thenDeps?: React.DependencyList,
3893
- ): Callback;
3910
+ ): ParameterizedCallback<Parameter>;
3894
3911
 
3895
3912
  /**
3896
3913
  * The useHasTablesListener hook registers a listener function with the Store
@@ -2684,7 +2684,7 @@ export function useSetTablesCallback<Parameter>(
2684
2684
  * @param getTableDeps An optional array of dependencies for the `getTable`
2685
2685
  * function, which, if any change, result in the regeneration of the callback.
2686
2686
  * This parameter defaults to an empty array. Also use this to indicate the
2687
- * dependencies of a GetId functions if used as the tableId argument.
2687
+ * dependencies of a GetId function if used as the tableId argument.
2688
2688
  * @param storeOrStoreId The Store to be updated: omit for the default context
2689
2689
  * Store, provide an Id for a named context Store, or provide an explicit
2690
2690
  * reference.
@@ -2882,7 +2882,7 @@ export function useSetRowCallback<Parameter>(
2882
2882
  * @param getRowDeps An optional array of dependencies for the `getRow`
2883
2883
  * function, which, if any change, result in the regeneration of the callback.
2884
2884
  * This parameter defaults to an empty array. Also use this to indicate the
2885
- * dependencies of a GetId functions if used as the tableId argument.
2885
+ * dependencies of a GetId function if used as the tableId argument.
2886
2886
  * @param storeOrStoreId The Store to be updated: omit for the default context
2887
2887
  * Store, provide an Id for a named context Store, or provide an explicit
2888
2888
  * reference.
@@ -3466,7 +3466,7 @@ export function useSetValueCallback<Parameter>(
3466
3466
  * all of the tabular data in a Store.
3467
3467
  *
3468
3468
  * This hook is useful, for example, when creating an event handler that will
3469
- * delete data in a Store.
3469
+ * delete data in the Store.
3470
3470
  *
3471
3471
  * For convenience, you can optionally provide a `then` function (with its own
3472
3472
  * set of dependencies) which will be called just after the Store has been
@@ -3530,11 +3530,12 @@ export function useDelTablesCallback(
3530
3530
  ): Callback;
3531
3531
 
3532
3532
  /**
3533
- * The useDelTableCallback hook returns a callback that can be used to remove a
3534
- * single Table from a Store.
3533
+ * The useDelTableCallback hook returns a parameterized callback that can be
3534
+ * used to remove a single Table from a Store.
3535
3535
  *
3536
3536
  * This hook is useful, for example, when creating an event handler that will
3537
- * delete data in a Store.
3537
+ * delete data in the Store. In this case, the parameter will likely be the
3538
+ * event, so that you can use data from it as part of the deletion.
3538
3539
  *
3539
3540
  * For convenience, you can optionally provide a `then` function (with its own
3540
3541
  * set of dependencies) which will be called just after the Store has been
@@ -3544,7 +3545,8 @@ export function useDelTablesCallback(
3544
3545
  * The Store to which the callback will make the deletion (indicated by the
3545
3546
  * hook's `storeOrStoreId` parameter) is always automatically used as a hook
3546
3547
  * dependency for the callback.
3547
- * @param tableId The Id of the Table in the Store.
3548
+ * @param tableId The Id of the Table in the Store to delete, or a GetId
3549
+ * function that will return it.
3548
3550
  * @param storeOrStoreId The Store to be updated: omit for the default context
3549
3551
  * Store, provide an Id for a named context Store, or provide an explicit
3550
3552
  * reference.
@@ -3552,8 +3554,9 @@ export function useDelTablesCallback(
3552
3554
  * to the Store.
3553
3555
  * @param thenDeps An optional array of dependencies for the `then` function,
3554
3556
  * which, if any change, result in the regeneration of the callback. This
3555
- * parameter defaults to an empty array.
3556
- * @returns A callback for subsequent use.
3557
+ * parameter defaults to an empty array. Also use this to indicate the
3558
+ * dependencies of an GetId function if used as the tableId argument.
3559
+ * @returns A parameterized callback for subsequent use.
3557
3560
  * @example
3558
3561
  * This example uses the useDelTableCallback hook to create an event handler
3559
3562
  * which deletes from the Store when the `span` element is clicked.
@@ -3592,19 +3595,20 @@ export function useDelTablesCallback(
3592
3595
  * @category Store hooks
3593
3596
  * @since v1.0.0
3594
3597
  */
3595
- export function useDelTableCallback(
3596
- tableId: Id,
3598
+ export function useDelTableCallback<Parameter>(
3599
+ tableId: Id | GetId<Parameter>,
3597
3600
  storeOrStoreId?: StoreOrStoreId,
3598
3601
  then?: (store: Store) => void,
3599
3602
  thenDeps?: React.DependencyList,
3600
- ): Callback;
3603
+ ): ParameterizedCallback<Parameter>;
3601
3604
 
3602
3605
  /**
3603
- * The useDelRowCallback hook returns a callback that can be used to remove a
3604
- * single Row from a Table.
3606
+ * The useDelRowCallback hook returns a parameterized callback that can be used
3607
+ * to remove a single Row from a Table.
3605
3608
  *
3606
3609
  * This hook is useful, for example, when creating an event handler that will
3607
- * delete data in a Store.
3610
+ * delete data in the Store. In this case, the parameter will likely be the
3611
+ * event, so that you can use data from it as part of the deletion.
3608
3612
  *
3609
3613
  * For convenience, you can optionally provide a `then` function (with its own
3610
3614
  * set of dependencies) which will be called just after the Store has been
@@ -3614,8 +3618,10 @@ export function useDelTableCallback(
3614
3618
  * The Store to which the callback will make the deletion (indicated by the
3615
3619
  * hook's `storeOrStoreId` parameter) is always automatically used as a hook
3616
3620
  * dependency for the callback.
3617
- * @param tableId The Id of the Table in the Store.
3618
- * @param rowId The Id of the Row in the Table.
3621
+ * @param tableId The Id of the Table in the Store, or a GetId function that
3622
+ * will return it.
3623
+ * @param rowId The Id of the Row in the Table to delete, or a GetId function
3624
+ * that will return it.
3619
3625
  * @param storeOrStoreId The Store to be updated: omit for the default context
3620
3626
  * Store, provide an Id for a named context Store, or provide an explicit
3621
3627
  * reference.
@@ -3623,8 +3629,10 @@ export function useDelTableCallback(
3623
3629
  * to the Store.
3624
3630
  * @param thenDeps An optional array of dependencies for the `then` function,
3625
3631
  * which, if any change, result in the regeneration of the callback. This
3626
- * parameter defaults to an empty array.
3627
- * @returns A callback for subsequent use.
3632
+ * parameter defaults to an empty array. Also use this to indicate the
3633
+ * dependencies of any GetId functions if used as the tableId or rowId
3634
+ * arguments.
3635
+ * @returns A parameterized callback for subsequent use.
3628
3636
  * @example
3629
3637
  * This example uses the useDelRowCallback hook to create an event handler which
3630
3638
  * deletes from the Store when the `span` element is clicked.
@@ -3663,20 +3671,21 @@ export function useDelTableCallback(
3663
3671
  * @category Store hooks
3664
3672
  * @since v1.0.0
3665
3673
  */
3666
- export function useDelRowCallback(
3667
- tableId: Id,
3668
- rowId: Id,
3674
+ export function useDelRowCallback<Parameter>(
3675
+ tableId: Id | GetId<Parameter>,
3676
+ rowId: Id | GetId<Parameter>,
3669
3677
  storeOrStoreId?: StoreOrStoreId,
3670
3678
  then?: (store: Store) => void,
3671
3679
  thenDeps?: React.DependencyList,
3672
- ): Callback;
3680
+ ): ParameterizedCallback<Parameter>;
3673
3681
 
3674
3682
  /**
3675
- * The useDelCellCallback hook returns a callback that can be used to remove a
3676
- * single Cell from a Row.
3683
+ * The useDelCellCallback hook returns a parameterized callback that can be used
3684
+ * to remove a single Cell from a Row.
3677
3685
  *
3678
3686
  * This hook is useful, for example, when creating an event handler that will
3679
- * delete data in a Store.
3687
+ * delete data in the Store. In this case, the parameter will likely be the
3688
+ * event, so that you can use data from it as part of the deletion.
3680
3689
  *
3681
3690
  * For convenience, you can optionally provide a `then` function (with its own
3682
3691
  * set of dependencies) which will be called just after the Store has been
@@ -3686,9 +3695,12 @@ export function useDelRowCallback(
3686
3695
  * The Store to which the callback will make the deletion (indicated by the
3687
3696
  * hook's `storeOrStoreId` parameter) is always automatically used as a hook
3688
3697
  * dependency for the callback.
3689
- * @param tableId The Id of the Table in the Store.
3690
- * @param rowId The Id of the Row in the Table.
3691
- * @param cellId The Id of the Cell in the Row.
3698
+ * @param tableId The Id of the Table in the Store, or a GetId function that
3699
+ * will return it.
3700
+ * @param rowId The Id of the Row in the Table, or a GetId function that will
3701
+ * return it.
3702
+ * @param cellId The Id of the Cell in the Row to delete, or a GetId function
3703
+ * that will return it.
3692
3704
  * @param forceDel An optional flag to indicate that the whole Row should be
3693
3705
  * deleted, even if a TablesSchema provides a default value for this Cell.
3694
3706
  * Defaults to `false`.
@@ -3699,8 +3711,10 @@ export function useDelRowCallback(
3699
3711
  * to the Store.
3700
3712
  * @param thenDeps An optional array of dependencies for the `then` function,
3701
3713
  * which, if any change, result in the regeneration of the callback. This
3702
- * parameter defaults to an empty array.
3703
- * @returns A callback for subsequent use.
3714
+ * parameter defaults to an empty array. Also use this to indicate the
3715
+ * dependencies of any GetId functions if used as the tableId, rowId, or cellId
3716
+ * arguments.
3717
+ * @returns A parameterized callback for subsequent use.
3704
3718
  * @example
3705
3719
  * This example uses the useDelCellCallback hook to create an event handler
3706
3720
  * which deletes from the Store when the `span` element is clicked.
@@ -3744,15 +3758,15 @@ export function useDelRowCallback(
3744
3758
  * @category Store hooks
3745
3759
  * @since v1.0.0
3746
3760
  */
3747
- export function useDelCellCallback(
3748
- tableId: Id,
3749
- rowId: Id,
3750
- cellId: Id,
3761
+ export function useDelCellCallback<Parameter>(
3762
+ tableId: Id | GetId<Parameter>,
3763
+ rowId: Id | GetId<Parameter>,
3764
+ cellId: Id | GetId<Parameter>,
3751
3765
  forceDel?: boolean,
3752
3766
  storeOrStoreId?: StoreOrStoreId,
3753
3767
  then?: (store: Store) => void,
3754
3768
  thenDeps?: React.DependencyList,
3755
- ): Callback;
3769
+ ): ParameterizedCallback<Parameter>;
3756
3770
 
3757
3771
  /**
3758
3772
  * The useDelValuesCallback hook returns a callback that can be used to remove
@@ -3823,11 +3837,12 @@ export function useDelValuesCallback(
3823
3837
  ): Callback;
3824
3838
 
3825
3839
  /**
3826
- * The useDelValueCallback hook returns a callback that can be used to remove a
3827
- * single Value from a Store.
3840
+ * The useDelValueCallback hook returns a parameterized callback that can be
3841
+ * used to remove a single Value from a Store.
3828
3842
  *
3829
3843
  * This hook is useful, for example, when creating an event handler that will
3830
- * delete data in a Store.
3844
+ * delete data in the Store. In this case, the parameter will likely be the
3845
+ * event, so that you can use data from it as part of the deletion.
3831
3846
  *
3832
3847
  * For convenience, you can optionally provide a `then` function (with its own
3833
3848
  * set of dependencies) which will be called just after the Store has been
@@ -3837,7 +3852,8 @@ export function useDelValuesCallback(
3837
3852
  * The Store to which the callback will make the deletion (indicated by the
3838
3853
  * hook's `storeOrStoreId` parameter) is always automatically used as a hook
3839
3854
  * dependency for the callback.
3840
- * @param valueId The Id of the Value in the Store.
3855
+ * @param valueId The Id of the Value in the Store to delete, or a GetId
3856
+ * function that will return it.
3841
3857
  * @param storeOrStoreId The Store to be updated: omit for the default context
3842
3858
  * Store, provide an Id for a named context Store, or provide an explicit
3843
3859
  * reference.
@@ -3845,8 +3861,9 @@ export function useDelValuesCallback(
3845
3861
  * to the Store.
3846
3862
  * @param thenDeps An optional array of dependencies for the `then` function,
3847
3863
  * which, if any change, result in the regeneration of the callback. This
3848
- * parameter defaults to an empty array.
3849
- * @returns A callback for subsequent use.
3864
+ * parameter defaults to an empty array. Also use this to indicate the
3865
+ * dependencies of a GetId function if used as the valueId argument.
3866
+ * @returns A parameterized callback for subsequent use.
3850
3867
  * @example
3851
3868
  * This example uses the useDelValueCallback hook to create an event handler
3852
3869
  * which deletes from the Store when the `span` element is clicked.
@@ -3885,12 +3902,12 @@ export function useDelValuesCallback(
3885
3902
  * @category Store hooks
3886
3903
  * @since v3.0.0
3887
3904
  */
3888
- export function useDelValueCallback(
3889
- valueId: Id,
3905
+ export function useDelValueCallback<Parameter>(
3906
+ valueId: Id | GetId<Parameter>,
3890
3907
  storeOrStoreId?: StoreOrStoreId,
3891
3908
  then?: (store: Store) => void,
3892
3909
  thenDeps?: React.DependencyList,
3893
- ): Callback;
3910
+ ): ParameterizedCallback<Parameter>;
3894
3911
 
3895
3912
  /**
3896
3913
  * The useHasTablesListener hook registers a listener function with the Store