tinybase 8.1.0-beta.0 → 8.1.0-beta.2
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/@types/_internal/ui/index.d.ts +0 -0
- package/@types/_internal/ui/with-schemas/index.d.ts +47 -0
- package/@types/_internal/ui-react/with-schemas/index.d.ts +9 -31
- package/@types/omni/index.d.ts +0 -3
- package/@types/omni/with-schemas/index.d.ts +0 -3
- package/@types/ui-react/with-schemas/index.d.ts +10 -8
- package/@types/ui-react-dom/with-schemas/index.d.ts +6 -4
- package/@types/ui-svelte/index.d.ts +3484 -0
- package/@types/ui-svelte/with-schemas/index.d.ts +3628 -0
- package/checkpoints/index.js +4 -1
- package/checkpoints/with-schemas/index.js +4 -1
- package/common/index.js +4 -1
- package/common/with-schemas/index.js +4 -1
- package/index.js +4 -1
- package/indexes/index.js +4 -1
- package/indexes/with-schemas/index.js +4 -1
- package/mergeable-store/index.js +4 -1
- package/mergeable-store/with-schemas/index.js +4 -1
- package/metrics/index.js +4 -1
- package/metrics/with-schemas/index.js +4 -1
- package/min/omni/index.js +1 -1
- package/min/omni/index.js.gz +0 -0
- package/min/omni/with-schemas/index.js +1 -1
- package/min/omni/with-schemas/index.js.gz +0 -0
- package/min/ui-react/index.js +1 -1
- package/min/ui-react/index.js.gz +0 -0
- package/min/ui-react/with-schemas/index.js +1 -1
- package/min/ui-react/with-schemas/index.js.gz +0 -0
- package/min/ui-svelte/index.js +1 -0
- package/min/ui-svelte/index.js.gz +0 -0
- package/min/ui-svelte/with-schemas/index.js +1 -0
- package/min/ui-svelte/with-schemas/index.js.gz +0 -0
- package/omni/index.js +11 -4739
- package/omni/with-schemas/index.js +11 -4739
- package/package.json +47 -7
- package/persisters/index.js +4 -1
- package/persisters/persister-automerge/index.js +4 -1
- package/persisters/persister-automerge/with-schemas/index.js +4 -1
- package/persisters/persister-browser/index.js +4 -1
- package/persisters/persister-browser/with-schemas/index.js +4 -1
- package/persisters/persister-cr-sqlite-wasm/index.js +4 -1
- package/persisters/persister-cr-sqlite-wasm/with-schemas/index.js +4 -1
- package/persisters/persister-durable-object-sql-storage/index.js +4 -1
- package/persisters/persister-durable-object-sql-storage/with-schemas/index.js +4 -1
- package/persisters/persister-durable-object-storage/index.js +4 -1
- package/persisters/persister-durable-object-storage/with-schemas/index.js +4 -1
- package/persisters/persister-electric-sql/index.js +4 -1
- package/persisters/persister-electric-sql/with-schemas/index.js +4 -1
- package/persisters/persister-expo-sqlite/index.js +4 -1
- package/persisters/persister-expo-sqlite/with-schemas/index.js +4 -1
- package/persisters/persister-file/index.js +4 -1
- package/persisters/persister-file/with-schemas/index.js +4 -1
- package/persisters/persister-indexed-db/index.js +4 -1
- package/persisters/persister-indexed-db/with-schemas/index.js +4 -1
- package/persisters/persister-libsql/index.js +4 -1
- package/persisters/persister-libsql/with-schemas/index.js +4 -1
- package/persisters/persister-partykit-client/index.js +4 -1
- package/persisters/persister-partykit-client/with-schemas/index.js +4 -1
- package/persisters/persister-partykit-server/index.js +4 -1
- package/persisters/persister-partykit-server/with-schemas/index.js +4 -1
- package/persisters/persister-pglite/index.js +4 -1
- package/persisters/persister-pglite/with-schemas/index.js +4 -1
- package/persisters/persister-postgres/index.js +4 -1
- package/persisters/persister-postgres/with-schemas/index.js +4 -1
- package/persisters/persister-powersync/index.js +4 -1
- package/persisters/persister-powersync/with-schemas/index.js +4 -1
- package/persisters/persister-react-native-mmkv/index.js +4 -1
- package/persisters/persister-react-native-mmkv/with-schemas/index.js +4 -1
- package/persisters/persister-react-native-sqlite/index.js +4 -1
- package/persisters/persister-react-native-sqlite/with-schemas/index.js +4 -1
- package/persisters/persister-remote/index.js +4 -1
- package/persisters/persister-remote/with-schemas/index.js +4 -1
- package/persisters/persister-sqlite-bun/index.js +4 -1
- package/persisters/persister-sqlite-bun/with-schemas/index.js +4 -1
- package/persisters/persister-sqlite-wasm/index.js +4 -1
- package/persisters/persister-sqlite-wasm/with-schemas/index.js +4 -1
- package/persisters/persister-sqlite3/index.js +4 -1
- package/persisters/persister-sqlite3/with-schemas/index.js +4 -1
- package/persisters/persister-yjs/index.js +4 -1
- package/persisters/persister-yjs/with-schemas/index.js +4 -1
- package/persisters/with-schemas/index.js +4 -1
- package/queries/index.js +4 -1
- package/queries/with-schemas/index.js +4 -1
- package/readme.md +14 -14
- package/relationships/index.js +4 -1
- package/relationships/with-schemas/index.js +4 -1
- package/releases.md +70 -44
- package/schematizers/index.js +4 -1
- package/schematizers/schematizer-arktype/index.js +4 -1
- package/schematizers/schematizer-arktype/with-schemas/index.js +4 -1
- package/schematizers/schematizer-effect/index.js +4 -1
- package/schematizers/schematizer-effect/with-schemas/index.js +4 -1
- package/schematizers/schematizer-typebox/index.js +4 -1
- package/schematizers/schematizer-typebox/with-schemas/index.js +4 -1
- package/schematizers/schematizer-valibot/index.js +4 -1
- package/schematizers/schematizer-valibot/with-schemas/index.js +4 -1
- package/schematizers/schematizer-yup/index.js +4 -1
- package/schematizers/schematizer-yup/with-schemas/index.js +4 -1
- package/schematizers/schematizer-zod/index.js +4 -1
- package/schematizers/schematizer-zod/with-schemas/index.js +4 -1
- package/schematizers/with-schemas/index.js +4 -1
- package/store/index.js +4 -1
- package/store/with-schemas/index.js +4 -1
- package/synchronizers/index.js +4 -1
- package/synchronizers/synchronizer-broadcast-channel/index.js +4 -1
- package/synchronizers/synchronizer-broadcast-channel/with-schemas/index.js +4 -1
- package/synchronizers/synchronizer-local/index.js +4 -1
- package/synchronizers/synchronizer-local/with-schemas/index.js +4 -1
- package/synchronizers/synchronizer-ws-client/index.js +4 -1
- package/synchronizers/synchronizer-ws-client/with-schemas/index.js +4 -1
- package/synchronizers/synchronizer-ws-server/index.js +4 -1
- package/synchronizers/synchronizer-ws-server/with-schemas/index.js +4 -1
- package/synchronizers/synchronizer-ws-server-durable-object/index.js +4 -1
- package/synchronizers/synchronizer-ws-server-durable-object/with-schemas/index.js +4 -1
- package/synchronizers/synchronizer-ws-server-simple/index.js +4 -1
- package/synchronizers/synchronizer-ws-server-simple/with-schemas/index.js +4 -1
- package/synchronizers/with-schemas/index.js +4 -1
- package/ui-react/index.js +100 -100
- package/ui-react/with-schemas/index.js +100 -100
- package/ui-react-dom/index.js +4 -1
- package/ui-react-dom/with-schemas/index.js +4 -1
- package/ui-react-inspector/index.js +4 -1
- package/ui-react-inspector/with-schemas/index.js +4 -1
- package/ui-svelte/index.js +2684 -0
- package/ui-svelte/with-schemas/index.js +2684 -0
- package/with-schemas/index.js +4 -1
|
@@ -0,0 +1,3484 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The ui-svelte module of the TinyBase project provides both hooks and
|
|
3
|
+
* components to make it easy to create reactive Svelte 5 apps with Store
|
|
4
|
+
* objects.
|
|
5
|
+
*
|
|
6
|
+
* The hooks in this module provide access to the data and structures exposed by
|
|
7
|
+
* other modules in the project. They return reactive objects with a `current`
|
|
8
|
+
* property. Hooks register listeners such that components using those hooks
|
|
9
|
+
* re-render when data changes.
|
|
10
|
+
*
|
|
11
|
+
* Hook parameters accept either plain values or reactive getter functions
|
|
12
|
+
* (`MaybeGetter<T> = T | (() => T)`), so passing `() => tableId` from a
|
|
13
|
+
* `let`-bound Svelte prop makes the hook re-execute whenever the prop changes.
|
|
14
|
+
*
|
|
15
|
+
* The components in this module provide a further abstraction over those hooks
|
|
16
|
+
* to ease the composition of user interfaces that use TinyBase.
|
|
17
|
+
* @see Building UIs With Svelte guide
|
|
18
|
+
* @packageDocumentation
|
|
19
|
+
* @module ui-svelte
|
|
20
|
+
* @since v8.1.0
|
|
21
|
+
*/
|
|
22
|
+
import type {Component, Snippet} from 'svelte';
|
|
23
|
+
import type {
|
|
24
|
+
CheckpointIds,
|
|
25
|
+
CheckpointIdsListener,
|
|
26
|
+
CheckpointListener,
|
|
27
|
+
Checkpoints,
|
|
28
|
+
} from '../checkpoints/index.d.ts';
|
|
29
|
+
import type {Id, IdOrNull, Ids} from '../common/index.d.ts';
|
|
30
|
+
import type {
|
|
31
|
+
Indexes,
|
|
32
|
+
SliceIdsListener,
|
|
33
|
+
SliceRowIdsListener,
|
|
34
|
+
} from '../indexes/index.d.ts';
|
|
35
|
+
import type {MetricListener, Metrics} from '../metrics/index.d.ts';
|
|
36
|
+
import type {
|
|
37
|
+
AnyPersister,
|
|
38
|
+
Status,
|
|
39
|
+
StatusListener,
|
|
40
|
+
} from '../persisters/index.d.ts';
|
|
41
|
+
import type {
|
|
42
|
+
ParamValueListener,
|
|
43
|
+
ParamValuesListener,
|
|
44
|
+
Queries,
|
|
45
|
+
ResultCellIdsListener,
|
|
46
|
+
ResultCellListener,
|
|
47
|
+
ResultRowCountListener,
|
|
48
|
+
ResultRowIdsListener,
|
|
49
|
+
ResultRowListener,
|
|
50
|
+
ResultSortedRowIdsListener,
|
|
51
|
+
ResultTableCellIdsListener,
|
|
52
|
+
ResultTableListener,
|
|
53
|
+
} from '../queries/index.d.ts';
|
|
54
|
+
import type {
|
|
55
|
+
LinkedRowIdsListener,
|
|
56
|
+
LocalRowIdsListener,
|
|
57
|
+
Relationships,
|
|
58
|
+
RemoteRowIdListener,
|
|
59
|
+
} from '../relationships/index.d.ts';
|
|
60
|
+
import type {
|
|
61
|
+
Cell,
|
|
62
|
+
CellIdsListener,
|
|
63
|
+
CellListener,
|
|
64
|
+
CellOrUndefined,
|
|
65
|
+
HasCellListener,
|
|
66
|
+
HasRowListener,
|
|
67
|
+
HasTableCellListener,
|
|
68
|
+
HasTableListener,
|
|
69
|
+
HasTablesListener,
|
|
70
|
+
HasValueListener,
|
|
71
|
+
HasValuesListener,
|
|
72
|
+
Row,
|
|
73
|
+
RowCountListener,
|
|
74
|
+
RowIdsListener,
|
|
75
|
+
RowListener,
|
|
76
|
+
SortedRowIdsListener,
|
|
77
|
+
Store,
|
|
78
|
+
Table,
|
|
79
|
+
TableCellIdsListener,
|
|
80
|
+
TableIdsListener,
|
|
81
|
+
TableListener,
|
|
82
|
+
Tables,
|
|
83
|
+
TablesListener,
|
|
84
|
+
TransactionListener,
|
|
85
|
+
Value,
|
|
86
|
+
ValueIdsListener,
|
|
87
|
+
ValueListener,
|
|
88
|
+
ValueOrUndefined,
|
|
89
|
+
Values,
|
|
90
|
+
ValuesListener,
|
|
91
|
+
} from '../store/index.d.ts';
|
|
92
|
+
import type {Synchronizer} from '../synchronizers/index.d.ts';
|
|
93
|
+
|
|
94
|
+
/**
|
|
95
|
+
* The MaybeGetter type represents a value that can be provided either as a
|
|
96
|
+
* plain value or as a reactive getter function.
|
|
97
|
+
*
|
|
98
|
+
* When a getter function is provided to a hook, the hook's internal `$effect`
|
|
99
|
+
* will re-run whenever the getter's reactive dependencies change. This is the
|
|
100
|
+
* mechanism that makes Svelte 5 props reactive in hooks.
|
|
101
|
+
* @category Identity
|
|
102
|
+
* @since v8.1.0
|
|
103
|
+
*/
|
|
104
|
+
export type MaybeGetter<T> = T | (() => T);
|
|
105
|
+
|
|
106
|
+
/**
|
|
107
|
+
* The StoreOrStoreId type is used when you need to refer to a Store in a
|
|
108
|
+
* Svelte hook or component.
|
|
109
|
+
*
|
|
110
|
+
* In some simple cases you will already have a direct reference to the Store.
|
|
111
|
+
*
|
|
112
|
+
* This module also includes a Provider component that can be used to wrap
|
|
113
|
+
* multiple Store objects into a context that can be used throughout the app. In
|
|
114
|
+
* this case you will want to refer to a Store by its Id in that context.
|
|
115
|
+
*
|
|
116
|
+
* Many hooks and components in this ui-svelte module take this type as a
|
|
117
|
+
* parameter or a prop, allowing you to pass in either the Store or its Id.
|
|
118
|
+
* @category Identity
|
|
119
|
+
* @since v8.1.0
|
|
120
|
+
*/
|
|
121
|
+
export type StoreOrStoreId = Store | Id;
|
|
122
|
+
|
|
123
|
+
/**
|
|
124
|
+
* The MetricsOrMetricsId type is used when you need to refer to a Metrics
|
|
125
|
+
* object in a Svelte hook or component.
|
|
126
|
+
*
|
|
127
|
+
* In some simple cases you will already have a direct reference to the Metrics
|
|
128
|
+
* object.
|
|
129
|
+
*
|
|
130
|
+
* This module also includes a Provider component that can be used to wrap
|
|
131
|
+
* multiple Metrics objects into a context that can be used throughout the app.
|
|
132
|
+
* In this case you will want to refer to a Metrics object by its Id in that
|
|
133
|
+
* context.
|
|
134
|
+
*
|
|
135
|
+
* Many hooks and components in this ui-svelte module take this type as a
|
|
136
|
+
* parameter or a prop, allowing you to pass in either the Metrics object or its
|
|
137
|
+
* Id.
|
|
138
|
+
* @category Identity
|
|
139
|
+
* @since v8.1.0
|
|
140
|
+
*/
|
|
141
|
+
export type MetricsOrMetricsId = Metrics | Id;
|
|
142
|
+
|
|
143
|
+
/**
|
|
144
|
+
* The IndexesOrIndexesId type is used when you need to refer to an Indexes
|
|
145
|
+
* object in a Svelte hook or component.
|
|
146
|
+
*
|
|
147
|
+
* In some simple cases you will already have a direct reference to the Indexes
|
|
148
|
+
* object.
|
|
149
|
+
*
|
|
150
|
+
* This module also includes a Provider component that can be used to wrap
|
|
151
|
+
* multiple Indexes objects into a context that can be used throughout the app.
|
|
152
|
+
* In this case you will want to refer to an Indexes object by its Id in that
|
|
153
|
+
* context.
|
|
154
|
+
*
|
|
155
|
+
* Many hooks and components in this ui-svelte module take this type as a
|
|
156
|
+
* parameter or a prop, allowing you to pass in either the Indexes object or its
|
|
157
|
+
* Id.
|
|
158
|
+
* @category Identity
|
|
159
|
+
* @since v8.1.0
|
|
160
|
+
*/
|
|
161
|
+
export type IndexesOrIndexesId = Indexes | Id;
|
|
162
|
+
|
|
163
|
+
/**
|
|
164
|
+
* The RelationshipsOrRelationshipsId type is used when you need to refer to a
|
|
165
|
+
* Relationships object in a Svelte hook or component.
|
|
166
|
+
*
|
|
167
|
+
* In some simple cases you will already have a direct reference to the
|
|
168
|
+
* Relationships object.
|
|
169
|
+
*
|
|
170
|
+
* This module also includes a Provider component that can be used to wrap
|
|
171
|
+
* multiple Relationships objects into a context that can be used throughout the
|
|
172
|
+
* app. In this case you will want to refer to a Relationships object by its Id
|
|
173
|
+
* in that context.
|
|
174
|
+
*
|
|
175
|
+
* Many hooks and components in this ui-svelte module take this type as a
|
|
176
|
+
* parameter or a prop, allowing you to pass in either the Relationships object
|
|
177
|
+
* or its Id.
|
|
178
|
+
* @category Identity
|
|
179
|
+
* @since v8.1.0
|
|
180
|
+
*/
|
|
181
|
+
export type RelationshipsOrRelationshipsId = Relationships | Id;
|
|
182
|
+
|
|
183
|
+
/**
|
|
184
|
+
* The QueriesOrQueriesId type is used when you need to refer to a Queries
|
|
185
|
+
* object in a Svelte hook or component.
|
|
186
|
+
*
|
|
187
|
+
* In some simple cases you will already have a direct reference to the Queries
|
|
188
|
+
* object.
|
|
189
|
+
*
|
|
190
|
+
* This module also includes a Provider component that can be used to wrap
|
|
191
|
+
* multiple Queries objects into a context that can be used throughout the app.
|
|
192
|
+
* In this case you will want to refer to a Queries object by its Id in that
|
|
193
|
+
* context.
|
|
194
|
+
*
|
|
195
|
+
* Many hooks and components in this ui-svelte module take this type as a
|
|
196
|
+
* parameter or a prop, allowing you to pass in either the Queries object or its
|
|
197
|
+
* Id.
|
|
198
|
+
* @category Identity
|
|
199
|
+
* @since v8.1.0
|
|
200
|
+
*/
|
|
201
|
+
export type QueriesOrQueriesId = Queries | Id;
|
|
202
|
+
|
|
203
|
+
/**
|
|
204
|
+
* The CheckpointsOrCheckpointsId type is used when you need to refer to a
|
|
205
|
+
* Checkpoints object in a Svelte hook or component.
|
|
206
|
+
*
|
|
207
|
+
* In some simple cases you will already have a direct reference to the
|
|
208
|
+
* Checkpoints object.
|
|
209
|
+
*
|
|
210
|
+
* This module also includes a Provider component that can be used to wrap
|
|
211
|
+
* multiple Checkpoints objects into a context that can be used throughout the
|
|
212
|
+
* app. In this case you will want to refer to a Checkpoints object by its Id in
|
|
213
|
+
* that context.
|
|
214
|
+
*
|
|
215
|
+
* Many hooks and components in this ui-svelte module take this type as a
|
|
216
|
+
* parameter or a prop, allowing you to pass in either the Checkpoints object or
|
|
217
|
+
* its Id.
|
|
218
|
+
* @category Identity
|
|
219
|
+
* @since v8.1.0
|
|
220
|
+
*/
|
|
221
|
+
export type CheckpointsOrCheckpointsId = Checkpoints | Id;
|
|
222
|
+
|
|
223
|
+
/**
|
|
224
|
+
* The PersisterOrPersisterId type is used when you need to refer to a Persister
|
|
225
|
+
* object in a Svelte hook or component.
|
|
226
|
+
*
|
|
227
|
+
* In some simple cases you will already have a direct reference to the
|
|
228
|
+
* Persister object.
|
|
229
|
+
*
|
|
230
|
+
* This module also includes a Provider component that can be used to wrap
|
|
231
|
+
* multiple Persister objects into a context that can be used throughout the
|
|
232
|
+
* app. In this case you will want to refer to a Persister object by its Id in
|
|
233
|
+
* that context.
|
|
234
|
+
*
|
|
235
|
+
* Many hooks and components in this ui-svelte module take this type as a
|
|
236
|
+
* parameter or a prop, allowing you to pass in either the Persister or its Id.
|
|
237
|
+
* @category Identity
|
|
238
|
+
* @since v8.1.0
|
|
239
|
+
*/
|
|
240
|
+
export type PersisterOrPersisterId = AnyPersister | Id;
|
|
241
|
+
|
|
242
|
+
/**
|
|
243
|
+
* The SynchronizerOrSynchronizerId type is used when you need to refer to a
|
|
244
|
+
* Synchronizer object in a Svelte hook or component.
|
|
245
|
+
*
|
|
246
|
+
* In some simple cases you will already have a direct reference to the
|
|
247
|
+
* Synchronizer object.
|
|
248
|
+
*
|
|
249
|
+
* This module also includes a Provider component that can be used to wrap
|
|
250
|
+
* multiple Synchronizer objects into a context that can be used throughout the
|
|
251
|
+
* app. In this case you will want to refer to a Synchronizer object by its Id
|
|
252
|
+
* in that context.
|
|
253
|
+
*
|
|
254
|
+
* Many hooks and components in this ui-svelte module take this type as a
|
|
255
|
+
* parameter or a prop, allowing you to pass in either the Synchronizer or its
|
|
256
|
+
* Id.
|
|
257
|
+
* @category Identity
|
|
258
|
+
* @since v8.1.0
|
|
259
|
+
*/
|
|
260
|
+
export type SynchronizerOrSynchronizerId = Synchronizer | Id;
|
|
261
|
+
|
|
262
|
+
/**
|
|
263
|
+
* ProviderProps props are used with the Provider component, so that Store,
|
|
264
|
+
* Metrics, Indexes, Relationships, Queries, and Checkpoints objects can be
|
|
265
|
+
* passed into the context of a Svelte 5 application and used throughout.
|
|
266
|
+
*
|
|
267
|
+
* One of each type of object can be provided as a default within the context.
|
|
268
|
+
* Additionally, multiple of each type of object can be provided in an Id-keyed
|
|
269
|
+
* map to the `___ById` props.
|
|
270
|
+
* @category Props
|
|
271
|
+
* @since v8.1.0
|
|
272
|
+
*/
|
|
273
|
+
export type ProviderProps = {
|
|
274
|
+
/**
|
|
275
|
+
* A default single Store object that will be available within the Provider
|
|
276
|
+
* context.
|
|
277
|
+
* @category Prop
|
|
278
|
+
* @since v8.1.0
|
|
279
|
+
*/
|
|
280
|
+
readonly store?: Store;
|
|
281
|
+
/**
|
|
282
|
+
* An object containing multiple Store objects that will be available within
|
|
283
|
+
* the Provider context by their Id.
|
|
284
|
+
* @category Prop
|
|
285
|
+
* @since v8.1.0
|
|
286
|
+
*/
|
|
287
|
+
readonly storesById?: {readonly [id: Id]: Store};
|
|
288
|
+
/**
|
|
289
|
+
* A default single Metrics object that will be available within the Provider
|
|
290
|
+
* context.
|
|
291
|
+
* @category Prop
|
|
292
|
+
* @since v8.1.0
|
|
293
|
+
*/
|
|
294
|
+
readonly metrics?: Metrics;
|
|
295
|
+
/**
|
|
296
|
+
* An object containing multiple Metrics objects that will be available within
|
|
297
|
+
* the Provider context by their Id.
|
|
298
|
+
* @category Prop
|
|
299
|
+
* @since v8.1.0
|
|
300
|
+
*/
|
|
301
|
+
readonly metricsById?: {readonly [id: Id]: Metrics};
|
|
302
|
+
/**
|
|
303
|
+
* A default single Indexes object that will be available within the Provider
|
|
304
|
+
* context.
|
|
305
|
+
* @category Prop
|
|
306
|
+
* @since v8.1.0
|
|
307
|
+
*/
|
|
308
|
+
readonly indexes?: Indexes;
|
|
309
|
+
/**
|
|
310
|
+
* An object containing multiple Indexes objects that will be available within
|
|
311
|
+
* the Provider context by their Id.
|
|
312
|
+
* @category Prop
|
|
313
|
+
* @since v8.1.0
|
|
314
|
+
*/
|
|
315
|
+
readonly indexesById?: {readonly [id: Id]: Indexes};
|
|
316
|
+
/**
|
|
317
|
+
* A default single Relationships object that will be available within the
|
|
318
|
+
* Provider context.
|
|
319
|
+
* @category Prop
|
|
320
|
+
* @since v8.1.0
|
|
321
|
+
*/
|
|
322
|
+
readonly relationships?: Relationships;
|
|
323
|
+
/**
|
|
324
|
+
* An object containing multiple Relationships objects that will be available
|
|
325
|
+
* within the Provider context by their Id.
|
|
326
|
+
* @category Prop
|
|
327
|
+
* @since v8.1.0
|
|
328
|
+
*/
|
|
329
|
+
readonly relationshipsById?: {readonly [id: Id]: Relationships};
|
|
330
|
+
/**
|
|
331
|
+
* A default single Queries object that will be available within the Provider
|
|
332
|
+
* context.
|
|
333
|
+
* @category Prop
|
|
334
|
+
* @since v8.1.0
|
|
335
|
+
*/
|
|
336
|
+
readonly queries?: Queries;
|
|
337
|
+
/**
|
|
338
|
+
* An object containing multiple Queries objects that will be available within
|
|
339
|
+
* the Provider context by their Id.
|
|
340
|
+
* @category Prop
|
|
341
|
+
* @since v8.1.0
|
|
342
|
+
*/
|
|
343
|
+
readonly queriesById?: {readonly [id: Id]: Queries};
|
|
344
|
+
/**
|
|
345
|
+
* A default single Checkpoints object that will be available within the
|
|
346
|
+
* Provider context.
|
|
347
|
+
* @category Prop
|
|
348
|
+
* @since v8.1.0
|
|
349
|
+
*/
|
|
350
|
+
readonly checkpoints?: Checkpoints;
|
|
351
|
+
/**
|
|
352
|
+
* An object containing multiple Checkpoints objects that will be available
|
|
353
|
+
* within the Provider context by their Id.
|
|
354
|
+
* @category Prop
|
|
355
|
+
* @since v8.1.0
|
|
356
|
+
*/
|
|
357
|
+
readonly checkpointsById?: {readonly [id: Id]: Checkpoints};
|
|
358
|
+
/**
|
|
359
|
+
* A default single Persister object that will be available within the
|
|
360
|
+
* Provider context.
|
|
361
|
+
* @category Prop
|
|
362
|
+
* @since v8.1.0
|
|
363
|
+
*/
|
|
364
|
+
readonly persister?: AnyPersister;
|
|
365
|
+
/**
|
|
366
|
+
* An object containing multiple Persister objects that will be available
|
|
367
|
+
* within the Provider context by their Id.
|
|
368
|
+
* @category Prop
|
|
369
|
+
* @since v8.1.0
|
|
370
|
+
*/
|
|
371
|
+
readonly persistersById?: {readonly [id: Id]: AnyPersister};
|
|
372
|
+
/**
|
|
373
|
+
* A default single Synchronizer object that will be available within the
|
|
374
|
+
* Provider context.
|
|
375
|
+
* @category Prop
|
|
376
|
+
* @since v8.1.0
|
|
377
|
+
*/
|
|
378
|
+
readonly synchronizer?: Synchronizer;
|
|
379
|
+
/**
|
|
380
|
+
* An object containing multiple Synchronizer objects that will be available
|
|
381
|
+
* within the Provider context by their Id.
|
|
382
|
+
* @category Prop
|
|
383
|
+
* @since v8.1.0
|
|
384
|
+
*/
|
|
385
|
+
readonly synchronizersById?: {readonly [id: Id]: Synchronizer};
|
|
386
|
+
/**
|
|
387
|
+
* The `children` prop of a ProviderProps object — the app subtree that will
|
|
388
|
+
* have access to the provided context.
|
|
389
|
+
* @category Prop
|
|
390
|
+
* @since v8.1.0
|
|
391
|
+
*/
|
|
392
|
+
readonly children: Snippet;
|
|
393
|
+
};
|
|
394
|
+
|
|
395
|
+
/**
|
|
396
|
+
* The CellViewProps type describes the props of the CellView component.
|
|
397
|
+
* @category Props
|
|
398
|
+
* @since v8.1.0
|
|
399
|
+
*/
|
|
400
|
+
export type CellViewProps = {
|
|
401
|
+
/**
|
|
402
|
+
* The `tableId` prop of a CellViewProps object.
|
|
403
|
+
* @category Props
|
|
404
|
+
* @since v8.1.0
|
|
405
|
+
*/
|
|
406
|
+
readonly tableId: Id;
|
|
407
|
+
/**
|
|
408
|
+
* The `rowId` prop of a CellViewProps object.
|
|
409
|
+
* @category Props
|
|
410
|
+
* @since v8.1.0
|
|
411
|
+
*/
|
|
412
|
+
readonly rowId: Id;
|
|
413
|
+
/**
|
|
414
|
+
* The `cellId` prop of a CellViewProps object.
|
|
415
|
+
* @category Props
|
|
416
|
+
* @since v8.1.0
|
|
417
|
+
*/
|
|
418
|
+
readonly cellId: Id;
|
|
419
|
+
/**
|
|
420
|
+
* The `store` prop of a CellViewProps object.
|
|
421
|
+
* @category Props
|
|
422
|
+
* @since v8.1.0
|
|
423
|
+
*/
|
|
424
|
+
readonly store?: StoreOrStoreId;
|
|
425
|
+
/**
|
|
426
|
+
* The `debugIds` prop of a CellViewProps object.
|
|
427
|
+
* @category Props
|
|
428
|
+
* @since v8.1.0
|
|
429
|
+
*/
|
|
430
|
+
readonly debugIds?: boolean;
|
|
431
|
+
};
|
|
432
|
+
|
|
433
|
+
/**
|
|
434
|
+
* The ValueViewProps type describes the props of the ValueView component.
|
|
435
|
+
* @category Props
|
|
436
|
+
* @since v8.1.0
|
|
437
|
+
*/
|
|
438
|
+
export type ValueViewProps = {
|
|
439
|
+
/**
|
|
440
|
+
* The `valueId` prop of a ValueViewProps object.
|
|
441
|
+
* @category Props
|
|
442
|
+
* @since v8.1.0
|
|
443
|
+
*/
|
|
444
|
+
readonly valueId: Id;
|
|
445
|
+
/**
|
|
446
|
+
* The `store` prop of a ValueViewProps object.
|
|
447
|
+
* @category Props
|
|
448
|
+
* @since v8.1.0
|
|
449
|
+
*/
|
|
450
|
+
readonly store?: StoreOrStoreId;
|
|
451
|
+
/**
|
|
452
|
+
* The `debugIds` prop of a ValueViewProps object.
|
|
453
|
+
* @category Props
|
|
454
|
+
* @since v8.1.0
|
|
455
|
+
*/
|
|
456
|
+
readonly debugIds?: boolean;
|
|
457
|
+
};
|
|
458
|
+
|
|
459
|
+
/**
|
|
460
|
+
* The MetricViewProps type describes the props of the MetricView component.
|
|
461
|
+
* @category Props
|
|
462
|
+
* @since v8.1.0
|
|
463
|
+
*/
|
|
464
|
+
export type MetricViewProps = {
|
|
465
|
+
/**
|
|
466
|
+
* The `metricId` prop of a MetricViewProps object.
|
|
467
|
+
* @category Props
|
|
468
|
+
* @since v8.1.0
|
|
469
|
+
*/
|
|
470
|
+
readonly metricId: Id;
|
|
471
|
+
/**
|
|
472
|
+
* The `metrics` prop of a MetricViewProps object.
|
|
473
|
+
* @category Props
|
|
474
|
+
* @since v8.1.0
|
|
475
|
+
*/
|
|
476
|
+
readonly metrics?: MetricsOrMetricsId;
|
|
477
|
+
/**
|
|
478
|
+
* The `debugIds` prop of a MetricViewProps object.
|
|
479
|
+
* @category Props
|
|
480
|
+
* @since v8.1.0
|
|
481
|
+
*/
|
|
482
|
+
readonly debugIds?: boolean;
|
|
483
|
+
};
|
|
484
|
+
|
|
485
|
+
/**
|
|
486
|
+
* The CheckpointViewProps type describes the props of the CheckpointView
|
|
487
|
+
* component.
|
|
488
|
+
* @category Props
|
|
489
|
+
* @since v8.1.0
|
|
490
|
+
*/
|
|
491
|
+
export type CheckpointViewProps = {
|
|
492
|
+
/**
|
|
493
|
+
* The `checkpointId` prop of a CheckpointViewProps object.
|
|
494
|
+
* @category Props
|
|
495
|
+
* @since v8.1.0
|
|
496
|
+
*/
|
|
497
|
+
readonly checkpointId: Id;
|
|
498
|
+
/**
|
|
499
|
+
* The `checkpoints` prop of a CheckpointViewProps object.
|
|
500
|
+
* @category Props
|
|
501
|
+
* @since v8.1.0
|
|
502
|
+
*/
|
|
503
|
+
readonly checkpoints?: CheckpointsOrCheckpointsId;
|
|
504
|
+
/**
|
|
505
|
+
* The `debugIds` prop of a CheckpointViewProps object.
|
|
506
|
+
* @category Props
|
|
507
|
+
* @since v8.1.0
|
|
508
|
+
*/
|
|
509
|
+
readonly debugIds?: boolean;
|
|
510
|
+
};
|
|
511
|
+
|
|
512
|
+
/**
|
|
513
|
+
* The RowViewProps type describes the props of the RowView component.
|
|
514
|
+
* @category Props
|
|
515
|
+
* @since v8.1.0
|
|
516
|
+
*/
|
|
517
|
+
export type RowViewProps = {
|
|
518
|
+
/**
|
|
519
|
+
* The `tableId` prop of a RowViewProps object.
|
|
520
|
+
* @category Props
|
|
521
|
+
* @since v8.1.0
|
|
522
|
+
*/
|
|
523
|
+
readonly tableId: Id;
|
|
524
|
+
/**
|
|
525
|
+
* The `rowId` prop of a RowViewProps object.
|
|
526
|
+
* @category Props
|
|
527
|
+
* @since v8.1.0
|
|
528
|
+
*/
|
|
529
|
+
readonly rowId: Id;
|
|
530
|
+
/**
|
|
531
|
+
* The `store` prop of a RowViewProps object.
|
|
532
|
+
* @category Props
|
|
533
|
+
* @since v8.1.0
|
|
534
|
+
*/
|
|
535
|
+
readonly store?: StoreOrStoreId;
|
|
536
|
+
/**
|
|
537
|
+
* The `customCellIds` prop of a RowViewProps object.
|
|
538
|
+
* @category Props
|
|
539
|
+
* @since v8.1.0
|
|
540
|
+
*/
|
|
541
|
+
readonly customCellIds?: Ids;
|
|
542
|
+
/**
|
|
543
|
+
* The `separator` prop of a RowViewProps object.
|
|
544
|
+
* @category Props
|
|
545
|
+
* @since v8.1.0
|
|
546
|
+
*/
|
|
547
|
+
readonly separator?: Snippet<[]>;
|
|
548
|
+
/**
|
|
549
|
+
* The `debugIds` prop of a RowViewProps object.
|
|
550
|
+
* @category Props
|
|
551
|
+
* @since v8.1.0
|
|
552
|
+
*/
|
|
553
|
+
readonly debugIds?: boolean;
|
|
554
|
+
/**
|
|
555
|
+
* The `cell` snippet prop of a RowViewProps object.
|
|
556
|
+
* @category Props
|
|
557
|
+
* @since v8.1.0
|
|
558
|
+
*/
|
|
559
|
+
readonly cell?: Snippet<[cellId: Id]>;
|
|
560
|
+
};
|
|
561
|
+
|
|
562
|
+
/**
|
|
563
|
+
* The TableViewProps type describes the props of the TableView component.
|
|
564
|
+
* @category Props
|
|
565
|
+
* @since v8.1.0
|
|
566
|
+
*/
|
|
567
|
+
export type TableViewProps = {
|
|
568
|
+
/**
|
|
569
|
+
* The `tableId` prop of a TableViewProps object.
|
|
570
|
+
* @category Props
|
|
571
|
+
* @since v8.1.0
|
|
572
|
+
*/
|
|
573
|
+
readonly tableId: Id;
|
|
574
|
+
/**
|
|
575
|
+
* The `store` prop of a TableViewProps object.
|
|
576
|
+
* @category Props
|
|
577
|
+
* @since v8.1.0
|
|
578
|
+
*/
|
|
579
|
+
readonly store?: StoreOrStoreId;
|
|
580
|
+
/**
|
|
581
|
+
* The `customCellIds` prop of a TableViewProps object.
|
|
582
|
+
* @category Props
|
|
583
|
+
* @since v8.1.0
|
|
584
|
+
*/
|
|
585
|
+
readonly customCellIds?: Ids;
|
|
586
|
+
/**
|
|
587
|
+
* The `separator` prop of a TableViewProps object.
|
|
588
|
+
* @category Props
|
|
589
|
+
* @since v8.1.0
|
|
590
|
+
*/
|
|
591
|
+
readonly separator?: Snippet<[]>;
|
|
592
|
+
/**
|
|
593
|
+
* The `debugIds` prop of a TableViewProps object.
|
|
594
|
+
* @category Props
|
|
595
|
+
* @since v8.1.0
|
|
596
|
+
*/
|
|
597
|
+
readonly debugIds?: boolean;
|
|
598
|
+
/**
|
|
599
|
+
* The `row` snippet prop of a TableViewProps object.
|
|
600
|
+
* @category Props
|
|
601
|
+
* @since v8.1.0
|
|
602
|
+
*/
|
|
603
|
+
readonly row?: Snippet<[rowId: Id]>;
|
|
604
|
+
};
|
|
605
|
+
|
|
606
|
+
/**
|
|
607
|
+
* The SortedTableViewProps type describes the props of the SortedTableView
|
|
608
|
+
* component.
|
|
609
|
+
* @category Props
|
|
610
|
+
* @since v8.1.0
|
|
611
|
+
*/
|
|
612
|
+
export type SortedTableViewProps = {
|
|
613
|
+
/**
|
|
614
|
+
* The `tableId` prop of a SortedTableViewProps object.
|
|
615
|
+
* @category Props
|
|
616
|
+
* @since v8.1.0
|
|
617
|
+
*/
|
|
618
|
+
readonly tableId: Id;
|
|
619
|
+
/**
|
|
620
|
+
* The `cellId` prop of a SortedTableViewProps object.
|
|
621
|
+
* @category Props
|
|
622
|
+
* @since v8.1.0
|
|
623
|
+
*/
|
|
624
|
+
readonly cellId?: Id;
|
|
625
|
+
/**
|
|
626
|
+
* The `descending` prop of a SortedTableViewProps object.
|
|
627
|
+
* @category Props
|
|
628
|
+
* @since v8.1.0
|
|
629
|
+
*/
|
|
630
|
+
readonly descending?: boolean;
|
|
631
|
+
/**
|
|
632
|
+
* The `offset` prop of a SortedTableViewProps object.
|
|
633
|
+
* @category Props
|
|
634
|
+
* @since v8.1.0
|
|
635
|
+
*/
|
|
636
|
+
readonly offset?: number;
|
|
637
|
+
/**
|
|
638
|
+
* The `limit` prop of a SortedTableViewProps object.
|
|
639
|
+
* @category Props
|
|
640
|
+
* @since v8.1.0
|
|
641
|
+
*/
|
|
642
|
+
readonly limit?: number;
|
|
643
|
+
/**
|
|
644
|
+
* The `store` prop of a SortedTableViewProps object.
|
|
645
|
+
* @category Props
|
|
646
|
+
* @since v8.1.0
|
|
647
|
+
*/
|
|
648
|
+
readonly store?: StoreOrStoreId;
|
|
649
|
+
/**
|
|
650
|
+
* The `customCellIds` prop of a SortedTableViewProps object.
|
|
651
|
+
* @category Props
|
|
652
|
+
* @since v8.1.0
|
|
653
|
+
*/
|
|
654
|
+
readonly customCellIds?: Ids;
|
|
655
|
+
/**
|
|
656
|
+
* The `separator` prop of a SortedTableViewProps object.
|
|
657
|
+
* @category Props
|
|
658
|
+
* @since v8.1.0
|
|
659
|
+
*/
|
|
660
|
+
readonly separator?: Snippet<[]>;
|
|
661
|
+
/**
|
|
662
|
+
* The `debugIds` prop of a SortedTableViewProps object.
|
|
663
|
+
* @category Props
|
|
664
|
+
* @since v8.1.0
|
|
665
|
+
*/
|
|
666
|
+
readonly debugIds?: boolean;
|
|
667
|
+
/**
|
|
668
|
+
* The `row` snippet prop of a SortedTableViewProps object.
|
|
669
|
+
* @category Props
|
|
670
|
+
* @since v8.1.0
|
|
671
|
+
*/
|
|
672
|
+
readonly row?: Snippet<[rowId: Id]>;
|
|
673
|
+
};
|
|
674
|
+
|
|
675
|
+
/**
|
|
676
|
+
* The TablesViewProps type describes the props of the TablesView component.
|
|
677
|
+
* @category Props
|
|
678
|
+
* @since v8.1.0
|
|
679
|
+
*/
|
|
680
|
+
export type TablesViewProps = {
|
|
681
|
+
/**
|
|
682
|
+
* The `store` prop of a TablesViewProps object.
|
|
683
|
+
* @category Props
|
|
684
|
+
* @since v8.1.0
|
|
685
|
+
*/
|
|
686
|
+
readonly store?: StoreOrStoreId;
|
|
687
|
+
/**
|
|
688
|
+
* The `separator` prop of a TablesViewProps object.
|
|
689
|
+
* @category Props
|
|
690
|
+
* @since v8.1.0
|
|
691
|
+
*/
|
|
692
|
+
readonly separator?: Snippet<[]>;
|
|
693
|
+
/**
|
|
694
|
+
* The `debugIds` prop of a TablesViewProps object.
|
|
695
|
+
* @category Props
|
|
696
|
+
* @since v8.1.0
|
|
697
|
+
*/
|
|
698
|
+
readonly debugIds?: boolean;
|
|
699
|
+
/**
|
|
700
|
+
* The `table` snippet prop of a TablesViewProps object.
|
|
701
|
+
* @category Props
|
|
702
|
+
* @since v8.1.0
|
|
703
|
+
*/
|
|
704
|
+
readonly table?: Snippet<[tableId: Id]>;
|
|
705
|
+
};
|
|
706
|
+
|
|
707
|
+
/**
|
|
708
|
+
* The ValuesViewProps type describes the props of the ValuesView component.
|
|
709
|
+
* @category Props
|
|
710
|
+
* @since v8.1.0
|
|
711
|
+
*/
|
|
712
|
+
export type ValuesViewProps = {
|
|
713
|
+
/**
|
|
714
|
+
* The `store` prop of a ValuesViewProps object.
|
|
715
|
+
* @category Props
|
|
716
|
+
* @since v8.1.0
|
|
717
|
+
*/
|
|
718
|
+
readonly store?: StoreOrStoreId;
|
|
719
|
+
/**
|
|
720
|
+
* The `separator` prop of a ValuesViewProps object.
|
|
721
|
+
* @category Props
|
|
722
|
+
* @since v8.1.0
|
|
723
|
+
*/
|
|
724
|
+
readonly separator?: Snippet<[]>;
|
|
725
|
+
/**
|
|
726
|
+
* The `debugIds` prop of a ValuesViewProps object.
|
|
727
|
+
* @category Props
|
|
728
|
+
* @since v8.1.0
|
|
729
|
+
*/
|
|
730
|
+
readonly debugIds?: boolean;
|
|
731
|
+
/**
|
|
732
|
+
* The `value` snippet prop of a ValuesViewProps object.
|
|
733
|
+
* @category Props
|
|
734
|
+
* @since v8.1.0
|
|
735
|
+
*/
|
|
736
|
+
readonly value?: Snippet<[valueId: Id]>;
|
|
737
|
+
};
|
|
738
|
+
|
|
739
|
+
/**
|
|
740
|
+
* The IndexViewProps type describes the props of the IndexView component.
|
|
741
|
+
* @category Props
|
|
742
|
+
* @since v8.1.0
|
|
743
|
+
*/
|
|
744
|
+
export type IndexViewProps = {
|
|
745
|
+
/**
|
|
746
|
+
* The `indexId` prop of an IndexViewProps object.
|
|
747
|
+
* @category Props
|
|
748
|
+
* @since v8.1.0
|
|
749
|
+
*/
|
|
750
|
+
readonly indexId: Id;
|
|
751
|
+
/**
|
|
752
|
+
* The `indexes` prop of an IndexViewProps object.
|
|
753
|
+
* @category Props
|
|
754
|
+
* @since v8.1.0
|
|
755
|
+
*/
|
|
756
|
+
readonly indexes?: IndexesOrIndexesId;
|
|
757
|
+
/**
|
|
758
|
+
* The `separator` prop of an IndexViewProps object.
|
|
759
|
+
* @category Props
|
|
760
|
+
* @since v8.1.0
|
|
761
|
+
*/
|
|
762
|
+
readonly separator?: Snippet<[]>;
|
|
763
|
+
/**
|
|
764
|
+
* The `debugIds` prop of an IndexViewProps object.
|
|
765
|
+
* @category Props
|
|
766
|
+
* @since v8.1.0
|
|
767
|
+
*/
|
|
768
|
+
readonly debugIds?: boolean;
|
|
769
|
+
/**
|
|
770
|
+
* The `slice` snippet prop of an IndexViewProps object.
|
|
771
|
+
* @category Props
|
|
772
|
+
* @since v8.1.0
|
|
773
|
+
*/
|
|
774
|
+
readonly slice?: Snippet<[sliceId: Id]>;
|
|
775
|
+
};
|
|
776
|
+
|
|
777
|
+
/**
|
|
778
|
+
* The SliceViewProps type describes the props of the SliceView component.
|
|
779
|
+
* @category Props
|
|
780
|
+
* @since v8.1.0
|
|
781
|
+
*/
|
|
782
|
+
export type SliceViewProps = {
|
|
783
|
+
/**
|
|
784
|
+
* The `indexId` prop of a SliceViewProps object.
|
|
785
|
+
* @category Props
|
|
786
|
+
* @since v8.1.0
|
|
787
|
+
*/
|
|
788
|
+
readonly indexId: Id;
|
|
789
|
+
/**
|
|
790
|
+
* The `sliceId` prop of a SliceViewProps object.
|
|
791
|
+
* @category Props
|
|
792
|
+
* @since v8.1.0
|
|
793
|
+
*/
|
|
794
|
+
readonly sliceId: Id;
|
|
795
|
+
/**
|
|
796
|
+
* The `indexes` prop of a SliceViewProps object.
|
|
797
|
+
* @category Props
|
|
798
|
+
* @since v8.1.0
|
|
799
|
+
*/
|
|
800
|
+
readonly indexes?: IndexesOrIndexesId;
|
|
801
|
+
/**
|
|
802
|
+
* The `separator` prop of a SliceViewProps object.
|
|
803
|
+
* @category Props
|
|
804
|
+
* @since v8.1.0
|
|
805
|
+
*/
|
|
806
|
+
readonly separator?: Snippet<[]>;
|
|
807
|
+
/**
|
|
808
|
+
* The `debugIds` prop of a SliceViewProps object.
|
|
809
|
+
* @category Props
|
|
810
|
+
* @since v8.1.0
|
|
811
|
+
*/
|
|
812
|
+
readonly debugIds?: boolean;
|
|
813
|
+
/**
|
|
814
|
+
* The `row` snippet prop of a SliceViewProps object.
|
|
815
|
+
* @category Props
|
|
816
|
+
* @since v8.1.0
|
|
817
|
+
*/
|
|
818
|
+
readonly row?: Snippet<[rowId: Id]>;
|
|
819
|
+
};
|
|
820
|
+
|
|
821
|
+
/**
|
|
822
|
+
* The RemoteRowViewProps type describes the props of the RemoteRowView
|
|
823
|
+
* component.
|
|
824
|
+
* @category Props
|
|
825
|
+
* @since v8.1.0
|
|
826
|
+
*/
|
|
827
|
+
export type RemoteRowViewProps = {
|
|
828
|
+
/**
|
|
829
|
+
* The `relationshipId` prop of a RemoteRowViewProps object.
|
|
830
|
+
* @category Props
|
|
831
|
+
* @since v8.1.0
|
|
832
|
+
*/
|
|
833
|
+
readonly relationshipId: Id;
|
|
834
|
+
/**
|
|
835
|
+
* The `localRowId` prop of a RemoteRowViewProps object.
|
|
836
|
+
* @category Props
|
|
837
|
+
* @since v8.1.0
|
|
838
|
+
*/
|
|
839
|
+
readonly localRowId: Id;
|
|
840
|
+
/**
|
|
841
|
+
* The `relationships` prop of a RemoteRowViewProps object.
|
|
842
|
+
* @category Props
|
|
843
|
+
* @since v8.1.0
|
|
844
|
+
*/
|
|
845
|
+
readonly relationships?: RelationshipsOrRelationshipsId;
|
|
846
|
+
/**
|
|
847
|
+
* The `debugIds` prop of a RemoteRowViewProps object.
|
|
848
|
+
* @category Props
|
|
849
|
+
* @since v8.1.0
|
|
850
|
+
*/
|
|
851
|
+
readonly debugIds?: boolean;
|
|
852
|
+
/**
|
|
853
|
+
* The `row` snippet prop of a RemoteRowViewProps object.
|
|
854
|
+
* @category Props
|
|
855
|
+
* @since v8.1.0
|
|
856
|
+
*/
|
|
857
|
+
readonly row?: Snippet<[rowId: Id]>;
|
|
858
|
+
};
|
|
859
|
+
|
|
860
|
+
/**
|
|
861
|
+
* The LocalRowsViewProps type describes the props of the LocalRowsView
|
|
862
|
+
* component.
|
|
863
|
+
* @category Props
|
|
864
|
+
* @since v8.1.0
|
|
865
|
+
*/
|
|
866
|
+
export type LocalRowsViewProps = {
|
|
867
|
+
/**
|
|
868
|
+
* The `relationshipId` prop of a LocalRowsViewProps object.
|
|
869
|
+
* @category Props
|
|
870
|
+
* @since v8.1.0
|
|
871
|
+
*/
|
|
872
|
+
readonly relationshipId: Id;
|
|
873
|
+
/**
|
|
874
|
+
* The `remoteRowId` prop of a LocalRowsViewProps object.
|
|
875
|
+
* @category Props
|
|
876
|
+
* @since v8.1.0
|
|
877
|
+
*/
|
|
878
|
+
readonly remoteRowId: Id;
|
|
879
|
+
/**
|
|
880
|
+
* The `relationships` prop of a LocalRowsViewProps object.
|
|
881
|
+
* @category Props
|
|
882
|
+
* @since v8.1.0
|
|
883
|
+
*/
|
|
884
|
+
readonly relationships?: RelationshipsOrRelationshipsId;
|
|
885
|
+
/**
|
|
886
|
+
* The `separator` prop of a LocalRowsViewProps object.
|
|
887
|
+
* @category Props
|
|
888
|
+
* @since v8.1.0
|
|
889
|
+
*/
|
|
890
|
+
readonly separator?: Snippet<[]>;
|
|
891
|
+
/**
|
|
892
|
+
* The `debugIds` prop of a LocalRowsViewProps object.
|
|
893
|
+
* @category Props
|
|
894
|
+
* @since v8.1.0
|
|
895
|
+
*/
|
|
896
|
+
readonly debugIds?: boolean;
|
|
897
|
+
/**
|
|
898
|
+
* The `row` snippet prop of a LocalRowsViewProps object.
|
|
899
|
+
* @category Props
|
|
900
|
+
* @since v8.1.0
|
|
901
|
+
*/
|
|
902
|
+
readonly row?: Snippet<[rowId: Id]>;
|
|
903
|
+
};
|
|
904
|
+
|
|
905
|
+
/**
|
|
906
|
+
* The LinkedRowsViewProps type describes the props of the LinkedRowsView
|
|
907
|
+
* component.
|
|
908
|
+
* @category Props
|
|
909
|
+
* @since v8.1.0
|
|
910
|
+
*/
|
|
911
|
+
export type LinkedRowsViewProps = {
|
|
912
|
+
/**
|
|
913
|
+
* The `relationshipId` prop of a LinkedRowsViewProps object.
|
|
914
|
+
* @category Props
|
|
915
|
+
* @since v8.1.0
|
|
916
|
+
*/
|
|
917
|
+
readonly relationshipId: Id;
|
|
918
|
+
/**
|
|
919
|
+
* The `firstRowId` prop of a LinkedRowsViewProps object.
|
|
920
|
+
* @category Props
|
|
921
|
+
* @since v8.1.0
|
|
922
|
+
*/
|
|
923
|
+
readonly firstRowId: Id;
|
|
924
|
+
/**
|
|
925
|
+
* The `relationships` prop of a LinkedRowsViewProps object.
|
|
926
|
+
* @category Props
|
|
927
|
+
* @since v8.1.0
|
|
928
|
+
*/
|
|
929
|
+
readonly relationships?: RelationshipsOrRelationshipsId;
|
|
930
|
+
/**
|
|
931
|
+
* The `separator` prop of a LinkedRowsViewProps object.
|
|
932
|
+
* @category Props
|
|
933
|
+
* @since v8.1.0
|
|
934
|
+
*/
|
|
935
|
+
readonly separator?: Snippet<[]>;
|
|
936
|
+
/**
|
|
937
|
+
* The `debugIds` prop of a LinkedRowsViewProps object.
|
|
938
|
+
* @category Props
|
|
939
|
+
* @since v8.1.0
|
|
940
|
+
*/
|
|
941
|
+
readonly debugIds?: boolean;
|
|
942
|
+
/**
|
|
943
|
+
* The `row` snippet prop of a LinkedRowsViewProps object.
|
|
944
|
+
* @category Props
|
|
945
|
+
* @since v8.1.0
|
|
946
|
+
*/
|
|
947
|
+
readonly row?: Snippet<[rowId: Id]>;
|
|
948
|
+
};
|
|
949
|
+
|
|
950
|
+
/**
|
|
951
|
+
* The ResultCellViewProps type describes the props of the ResultCellView
|
|
952
|
+
* component.
|
|
953
|
+
* @category Props
|
|
954
|
+
* @since v8.1.0
|
|
955
|
+
*/
|
|
956
|
+
export type ResultCellViewProps = {
|
|
957
|
+
/**
|
|
958
|
+
* The `queryId` prop of a ResultCellViewProps object.
|
|
959
|
+
* @category Props
|
|
960
|
+
* @since v8.1.0
|
|
961
|
+
*/
|
|
962
|
+
readonly queryId: Id;
|
|
963
|
+
/**
|
|
964
|
+
* The `rowId` prop of a ResultCellViewProps object.
|
|
965
|
+
* @category Props
|
|
966
|
+
* @since v8.1.0
|
|
967
|
+
*/
|
|
968
|
+
readonly rowId: Id;
|
|
969
|
+
/**
|
|
970
|
+
* The `cellId` prop of a ResultCellViewProps object.
|
|
971
|
+
* @category Props
|
|
972
|
+
* @since v8.1.0
|
|
973
|
+
*/
|
|
974
|
+
readonly cellId: Id;
|
|
975
|
+
/**
|
|
976
|
+
* The `queries` prop of a ResultCellViewProps object.
|
|
977
|
+
* @category Props
|
|
978
|
+
* @since v8.1.0
|
|
979
|
+
*/
|
|
980
|
+
readonly queries?: QueriesOrQueriesId;
|
|
981
|
+
/**
|
|
982
|
+
* The `debugIds` prop of a ResultCellViewProps object.
|
|
983
|
+
* @category Props
|
|
984
|
+
* @since v8.1.0
|
|
985
|
+
*/
|
|
986
|
+
readonly debugIds?: boolean;
|
|
987
|
+
};
|
|
988
|
+
|
|
989
|
+
/**
|
|
990
|
+
* The ResultRowViewProps type describes the props of the ResultRowView
|
|
991
|
+
* component.
|
|
992
|
+
* @category Props
|
|
993
|
+
* @since v8.1.0
|
|
994
|
+
*/
|
|
995
|
+
export type ResultRowViewProps = {
|
|
996
|
+
/**
|
|
997
|
+
* The `queryId` prop of a ResultRowViewProps object.
|
|
998
|
+
* @category Props
|
|
999
|
+
* @since v8.1.0
|
|
1000
|
+
*/
|
|
1001
|
+
readonly queryId: Id;
|
|
1002
|
+
/**
|
|
1003
|
+
* The `rowId` prop of a ResultRowViewProps object.
|
|
1004
|
+
* @category Props
|
|
1005
|
+
* @since v8.1.0
|
|
1006
|
+
*/
|
|
1007
|
+
readonly rowId: Id;
|
|
1008
|
+
/**
|
|
1009
|
+
* The `queries` prop of a ResultRowViewProps object.
|
|
1010
|
+
* @category Props
|
|
1011
|
+
* @since v8.1.0
|
|
1012
|
+
*/
|
|
1013
|
+
readonly queries?: QueriesOrQueriesId;
|
|
1014
|
+
/**
|
|
1015
|
+
* The `separator` prop of a ResultRowViewProps object.
|
|
1016
|
+
* @category Props
|
|
1017
|
+
* @since v8.1.0
|
|
1018
|
+
*/
|
|
1019
|
+
readonly separator?: Snippet<[]>;
|
|
1020
|
+
/**
|
|
1021
|
+
* The `debugIds` prop of a ResultRowViewProps object.
|
|
1022
|
+
* @category Props
|
|
1023
|
+
* @since v8.1.0
|
|
1024
|
+
*/
|
|
1025
|
+
readonly debugIds?: boolean;
|
|
1026
|
+
/**
|
|
1027
|
+
* The `cell` snippet prop of a ResultRowViewProps object.
|
|
1028
|
+
* @category Props
|
|
1029
|
+
* @since v8.1.0
|
|
1030
|
+
*/
|
|
1031
|
+
readonly cell?: Snippet<[cellId: Id]>;
|
|
1032
|
+
};
|
|
1033
|
+
|
|
1034
|
+
/**
|
|
1035
|
+
* The ResultTableViewProps type describes the props of the ResultTableView
|
|
1036
|
+
* component.
|
|
1037
|
+
* @category Props
|
|
1038
|
+
* @since v8.1.0
|
|
1039
|
+
*/
|
|
1040
|
+
export type ResultTableViewProps = {
|
|
1041
|
+
/**
|
|
1042
|
+
* The `queryId` prop of a ResultTableViewProps object.
|
|
1043
|
+
* @category Props
|
|
1044
|
+
* @since v8.1.0
|
|
1045
|
+
*/
|
|
1046
|
+
readonly queryId: Id;
|
|
1047
|
+
/**
|
|
1048
|
+
* The `queries` prop of a ResultTableViewProps object.
|
|
1049
|
+
* @category Props
|
|
1050
|
+
* @since v8.1.0
|
|
1051
|
+
*/
|
|
1052
|
+
readonly queries?: QueriesOrQueriesId;
|
|
1053
|
+
/**
|
|
1054
|
+
* The `separator` prop of a ResultTableViewProps object.
|
|
1055
|
+
* @category Props
|
|
1056
|
+
* @since v8.1.0
|
|
1057
|
+
*/
|
|
1058
|
+
readonly separator?: Snippet<[]>;
|
|
1059
|
+
/**
|
|
1060
|
+
* The `debugIds` prop of a ResultTableViewProps object.
|
|
1061
|
+
* @category Props
|
|
1062
|
+
* @since v8.1.0
|
|
1063
|
+
*/
|
|
1064
|
+
readonly debugIds?: boolean;
|
|
1065
|
+
/**
|
|
1066
|
+
* The `row` snippet prop of a ResultTableViewProps object.
|
|
1067
|
+
* @category Props
|
|
1068
|
+
* @since v8.1.0
|
|
1069
|
+
*/
|
|
1070
|
+
readonly row?: Snippet<[rowId: Id]>;
|
|
1071
|
+
};
|
|
1072
|
+
|
|
1073
|
+
/**
|
|
1074
|
+
* The ResultSortedTableViewProps type describes the props of the
|
|
1075
|
+
* ResultSortedTableView component.
|
|
1076
|
+
* @category Props
|
|
1077
|
+
* @since v8.1.0
|
|
1078
|
+
*/
|
|
1079
|
+
export type ResultSortedTableViewProps = {
|
|
1080
|
+
/**
|
|
1081
|
+
* The `queryId` prop of a ResultSortedTableViewProps object.
|
|
1082
|
+
* @category Props
|
|
1083
|
+
* @since v8.1.0
|
|
1084
|
+
*/
|
|
1085
|
+
readonly queryId: Id;
|
|
1086
|
+
/**
|
|
1087
|
+
* The `cellId` prop of a ResultSortedTableViewProps object.
|
|
1088
|
+
* @category Props
|
|
1089
|
+
* @since v8.1.0
|
|
1090
|
+
*/
|
|
1091
|
+
readonly cellId?: Id;
|
|
1092
|
+
/**
|
|
1093
|
+
* The `descending` prop of a ResultSortedTableViewProps object.
|
|
1094
|
+
* @category Props
|
|
1095
|
+
* @since v8.1.0
|
|
1096
|
+
*/
|
|
1097
|
+
readonly descending?: boolean;
|
|
1098
|
+
/**
|
|
1099
|
+
* The `offset` prop of a ResultSortedTableViewProps object.
|
|
1100
|
+
* @category Props
|
|
1101
|
+
* @since v8.1.0
|
|
1102
|
+
*/
|
|
1103
|
+
readonly offset?: number;
|
|
1104
|
+
/**
|
|
1105
|
+
* The `limit` prop of a ResultSortedTableViewProps object.
|
|
1106
|
+
* @category Props
|
|
1107
|
+
* @since v8.1.0
|
|
1108
|
+
*/
|
|
1109
|
+
readonly limit?: number;
|
|
1110
|
+
/**
|
|
1111
|
+
* The `queries` prop of a ResultSortedTableViewProps object.
|
|
1112
|
+
* @category Props
|
|
1113
|
+
* @since v8.1.0
|
|
1114
|
+
*/
|
|
1115
|
+
readonly queries?: QueriesOrQueriesId;
|
|
1116
|
+
/**
|
|
1117
|
+
* The `separator` prop of a ResultSortedTableViewProps object.
|
|
1118
|
+
* @category Props
|
|
1119
|
+
* @since v8.1.0
|
|
1120
|
+
*/
|
|
1121
|
+
readonly separator?: Snippet<[]>;
|
|
1122
|
+
/**
|
|
1123
|
+
* The `debugIds` prop of a ResultSortedTableViewProps object.
|
|
1124
|
+
* @category Props
|
|
1125
|
+
* @since v8.1.0
|
|
1126
|
+
*/
|
|
1127
|
+
readonly debugIds?: boolean;
|
|
1128
|
+
/**
|
|
1129
|
+
* The `row` snippet prop of a ResultSortedTableViewProps object.
|
|
1130
|
+
* @category Props
|
|
1131
|
+
* @since v8.1.0
|
|
1132
|
+
*/
|
|
1133
|
+
readonly row?: Snippet<[rowId: Id]>;
|
|
1134
|
+
};
|
|
1135
|
+
|
|
1136
|
+
/**
|
|
1137
|
+
* The BackwardCheckpointsViewProps type describes the props of the
|
|
1138
|
+
* BackwardCheckpointsView component.
|
|
1139
|
+
* @category Props
|
|
1140
|
+
* @since v8.1.0
|
|
1141
|
+
*/
|
|
1142
|
+
export type BackwardCheckpointsViewProps = {
|
|
1143
|
+
/**
|
|
1144
|
+
* The `checkpoints` prop of a BackwardCheckpointsViewProps object.
|
|
1145
|
+
* @category Props
|
|
1146
|
+
* @since v8.1.0
|
|
1147
|
+
*/
|
|
1148
|
+
readonly checkpoints?: CheckpointsOrCheckpointsId;
|
|
1149
|
+
/**
|
|
1150
|
+
* The `separator` prop of a BackwardCheckpointsViewProps object.
|
|
1151
|
+
* @category Props
|
|
1152
|
+
* @since v8.1.0
|
|
1153
|
+
*/
|
|
1154
|
+
readonly separator?: Snippet<[]>;
|
|
1155
|
+
/**
|
|
1156
|
+
* The `debugIds` prop of a BackwardCheckpointsViewProps object.
|
|
1157
|
+
* @category Props
|
|
1158
|
+
* @since v8.1.0
|
|
1159
|
+
*/
|
|
1160
|
+
readonly debugIds?: boolean;
|
|
1161
|
+
/**
|
|
1162
|
+
* The `checkpoint` snippet prop of a BackwardCheckpointsViewProps object.
|
|
1163
|
+
* @category Props
|
|
1164
|
+
* @since v8.1.0
|
|
1165
|
+
*/
|
|
1166
|
+
readonly checkpoint?: Snippet<[checkpointId: Id]>;
|
|
1167
|
+
};
|
|
1168
|
+
|
|
1169
|
+
/**
|
|
1170
|
+
* The ForwardCheckpointsViewProps type describes the props of the
|
|
1171
|
+
* ForwardCheckpointsView component.
|
|
1172
|
+
* @category Props
|
|
1173
|
+
* @since v8.1.0
|
|
1174
|
+
*/
|
|
1175
|
+
export type ForwardCheckpointsViewProps = {
|
|
1176
|
+
/**
|
|
1177
|
+
* The `checkpoints` prop of a ForwardCheckpointsViewProps object.
|
|
1178
|
+
* @category Props
|
|
1179
|
+
* @since v8.1.0
|
|
1180
|
+
*/
|
|
1181
|
+
readonly checkpoints?: CheckpointsOrCheckpointsId;
|
|
1182
|
+
/**
|
|
1183
|
+
* The `separator` prop of a ForwardCheckpointsViewProps object.
|
|
1184
|
+
* @category Props
|
|
1185
|
+
* @since v8.1.0
|
|
1186
|
+
*/
|
|
1187
|
+
readonly separator?: Snippet<[]>;
|
|
1188
|
+
/**
|
|
1189
|
+
* The `debugIds` prop of a ForwardCheckpointsViewProps object.
|
|
1190
|
+
* @category Props
|
|
1191
|
+
* @since v8.1.0
|
|
1192
|
+
*/
|
|
1193
|
+
readonly debugIds?: boolean;
|
|
1194
|
+
/**
|
|
1195
|
+
* The `checkpoint` snippet prop of a ForwardCheckpointsViewProps object.
|
|
1196
|
+
* @category Props
|
|
1197
|
+
* @since v8.1.0
|
|
1198
|
+
*/
|
|
1199
|
+
readonly checkpoint?: Snippet<[checkpointId: Id]>;
|
|
1200
|
+
};
|
|
1201
|
+
|
|
1202
|
+
/**
|
|
1203
|
+
* The CurrentCheckpointViewProps type describes the props of the
|
|
1204
|
+
* CurrentCheckpointView component.
|
|
1205
|
+
* @category Props
|
|
1206
|
+
* @since v8.1.0
|
|
1207
|
+
*/
|
|
1208
|
+
export type CurrentCheckpointViewProps = {
|
|
1209
|
+
/**
|
|
1210
|
+
* The `checkpoints` prop of a CurrentCheckpointViewProps object.
|
|
1211
|
+
* @category Props
|
|
1212
|
+
* @since v8.1.0
|
|
1213
|
+
*/
|
|
1214
|
+
readonly checkpoints?: CheckpointsOrCheckpointsId;
|
|
1215
|
+
/**
|
|
1216
|
+
* The `debugIds` prop of a CurrentCheckpointViewProps object.
|
|
1217
|
+
* @category Props
|
|
1218
|
+
* @since v8.1.0
|
|
1219
|
+
*/
|
|
1220
|
+
readonly debugIds?: boolean;
|
|
1221
|
+
/**
|
|
1222
|
+
* The `checkpoint` snippet prop of a CurrentCheckpointViewProps object.
|
|
1223
|
+
* @category Props
|
|
1224
|
+
* @since v8.1.0
|
|
1225
|
+
*/
|
|
1226
|
+
readonly checkpoint?: Snippet<[checkpointId: Id]>;
|
|
1227
|
+
};
|
|
1228
|
+
|
|
1229
|
+
/**
|
|
1230
|
+
* The Provider component wraps part of an application to make TinyBase objects
|
|
1231
|
+
* available throughout its component subtree via Svelte context.
|
|
1232
|
+
*
|
|
1233
|
+
* Store objects, Metrics, Indexes, Relationships, Queries, Checkpoints,
|
|
1234
|
+
* Persisters, and Synchronizers can all be provided both as single defaults and
|
|
1235
|
+
* as named instances in a `*ById` map.
|
|
1236
|
+
* @param props The props for this component.
|
|
1237
|
+
* @example
|
|
1238
|
+
* This example creates a Provider context with a default Store.
|
|
1239
|
+
*
|
|
1240
|
+
* ```ts
|
|
1241
|
+
* // In a .svelte file:
|
|
1242
|
+
* // <Provider store={createStore()}>
|
|
1243
|
+
* // <App />
|
|
1244
|
+
* // </Provider>
|
|
1245
|
+
* ```
|
|
1246
|
+
* @category Component
|
|
1247
|
+
* @since v8.1.0
|
|
1248
|
+
*/
|
|
1249
|
+
export const Provider: Component<ProviderProps>;
|
|
1250
|
+
|
|
1251
|
+
/**
|
|
1252
|
+
* The BackwardCheckpointsView component renders the list of checkpoint Ids that
|
|
1253
|
+
* represent backward checkpoints in a Checkpoints object, and registers a
|
|
1254
|
+
* listener so that any changes to that result will cause a re-render.
|
|
1255
|
+
* @param props The props for this component.
|
|
1256
|
+
* @returns A rendering of the backward checkpoint Ids.
|
|
1257
|
+
* @category Component
|
|
1258
|
+
* @since v8.1.0
|
|
1259
|
+
*/
|
|
1260
|
+
export const BackwardCheckpointsView: Component<BackwardCheckpointsViewProps>;
|
|
1261
|
+
|
|
1262
|
+
/**
|
|
1263
|
+
* The CellView component renders the value of a single Cell in a given Row in a
|
|
1264
|
+
* given Table, and registers a listener so that any changes to that result will
|
|
1265
|
+
* cause a re-render.
|
|
1266
|
+
* @param props The props for this component.
|
|
1267
|
+
* @returns A rendering of the Cell, or nothing if not present.
|
|
1268
|
+
* @category Component
|
|
1269
|
+
* @since v8.1.0
|
|
1270
|
+
*/
|
|
1271
|
+
export const CellView: Component<CellViewProps>;
|
|
1272
|
+
|
|
1273
|
+
/**
|
|
1274
|
+
* The CheckpointView component renders the label of a checkpoint in a
|
|
1275
|
+
* Checkpoints object, and registers a listener so that any changes to that
|
|
1276
|
+
* result will cause a re-render.
|
|
1277
|
+
* @param props The props for this component.
|
|
1278
|
+
* @returns A rendering of the checkpoint label.
|
|
1279
|
+
* @category Component
|
|
1280
|
+
* @since v8.1.0
|
|
1281
|
+
*/
|
|
1282
|
+
export const CheckpointView: Component<CheckpointViewProps>;
|
|
1283
|
+
|
|
1284
|
+
/**
|
|
1285
|
+
* The CurrentCheckpointView component renders the current checkpoint in a
|
|
1286
|
+
* Checkpoints object, and registers a listener so that any changes to that
|
|
1287
|
+
* result will cause a re-render.
|
|
1288
|
+
* @param props The props for this component.
|
|
1289
|
+
* @returns A rendering of the current checkpoint.
|
|
1290
|
+
* @category Component
|
|
1291
|
+
* @since v8.1.0
|
|
1292
|
+
*/
|
|
1293
|
+
export const CurrentCheckpointView: Component<CurrentCheckpointViewProps>;
|
|
1294
|
+
|
|
1295
|
+
/**
|
|
1296
|
+
* The ForwardCheckpointsView component renders the list of checkpoint Ids that
|
|
1297
|
+
* represent forward checkpoints in a Checkpoints object, and registers a
|
|
1298
|
+
* listener so that any changes to that result will cause a re-render.
|
|
1299
|
+
* @param props The props for this component.
|
|
1300
|
+
* @returns A rendering of the forward checkpoint Ids.
|
|
1301
|
+
* @category Component
|
|
1302
|
+
* @since v8.1.0
|
|
1303
|
+
*/
|
|
1304
|
+
export const ForwardCheckpointsView: Component<ForwardCheckpointsViewProps>;
|
|
1305
|
+
|
|
1306
|
+
/**
|
|
1307
|
+
* The IndexView component renders the slices in a named Index, and registers a
|
|
1308
|
+
* listener so that any changes to that result will cause a re-render.
|
|
1309
|
+
* @param props The props for this component.
|
|
1310
|
+
* @returns A rendering of the slices.
|
|
1311
|
+
* @category Component
|
|
1312
|
+
* @since v8.1.0
|
|
1313
|
+
*/
|
|
1314
|
+
export const IndexView: Component<IndexViewProps>;
|
|
1315
|
+
|
|
1316
|
+
/**
|
|
1317
|
+
* The LinkedRowsView component renders the Rows in a linked list Relationship,
|
|
1318
|
+
* and registers a listener so that any changes to that result will cause a
|
|
1319
|
+
* re-render.
|
|
1320
|
+
* @param props The props for this component.
|
|
1321
|
+
* @returns A rendering of the linked Row Ids.
|
|
1322
|
+
* @category Component
|
|
1323
|
+
* @since v8.1.0
|
|
1324
|
+
*/
|
|
1325
|
+
export const LinkedRowsView: Component<LinkedRowsViewProps>;
|
|
1326
|
+
|
|
1327
|
+
/**
|
|
1328
|
+
* The LocalRowsView component renders the local Row Ids for a given remote Row
|
|
1329
|
+
* in a Relationship, and registers a listener so that any changes to that
|
|
1330
|
+
* result will cause a re-render.
|
|
1331
|
+
* @param props The props for this component.
|
|
1332
|
+
* @returns A rendering of the local Row Ids.
|
|
1333
|
+
* @category Component
|
|
1334
|
+
* @since v8.1.0
|
|
1335
|
+
*/
|
|
1336
|
+
export const LocalRowsView: Component<LocalRowsViewProps>;
|
|
1337
|
+
|
|
1338
|
+
/**
|
|
1339
|
+
* The MetricView component renders the value of a named Metric in a Metrics
|
|
1340
|
+
* object, and registers a listener so that any changes to that result will
|
|
1341
|
+
* cause a re-render.
|
|
1342
|
+
* @param props The props for this component.
|
|
1343
|
+
* @returns A rendering of the Metric value.
|
|
1344
|
+
* @category Component
|
|
1345
|
+
* @since v8.1.0
|
|
1346
|
+
*/
|
|
1347
|
+
export const MetricView: Component<MetricViewProps>;
|
|
1348
|
+
|
|
1349
|
+
/**
|
|
1350
|
+
* The RemoteRowView component renders the remote Row Id for a given local Row
|
|
1351
|
+
* in a Relationship, and registers a listener so that any changes to that
|
|
1352
|
+
* result will cause a re-render.
|
|
1353
|
+
* @param props The props for this component.
|
|
1354
|
+
* @returns A rendering of the remote Row.
|
|
1355
|
+
* @category Component
|
|
1356
|
+
* @since v8.1.0
|
|
1357
|
+
*/
|
|
1358
|
+
export const RemoteRowView: Component<RemoteRowViewProps>;
|
|
1359
|
+
|
|
1360
|
+
/**
|
|
1361
|
+
* The ResultCellView component renders the value of a single Cell in a given
|
|
1362
|
+
* Result Row in a given Result Table of a Queries object, and registers a
|
|
1363
|
+
* listener so that any changes to that result will cause a re-render.
|
|
1364
|
+
* @param props The props for this component.
|
|
1365
|
+
* @returns A rendering of the result Cell.
|
|
1366
|
+
* @category Component
|
|
1367
|
+
* @since v8.1.0
|
|
1368
|
+
*/
|
|
1369
|
+
export const ResultCellView: Component<ResultCellViewProps>;
|
|
1370
|
+
|
|
1371
|
+
/**
|
|
1372
|
+
* The ResultRowView component renders the contents of a single Result Row in a
|
|
1373
|
+
* given Result Table, and registers a listener so that any changes to that
|
|
1374
|
+
* result will cause a re-render.
|
|
1375
|
+
* @param props The props for this component.
|
|
1376
|
+
* @returns A rendering of the result Row.
|
|
1377
|
+
* @category Component
|
|
1378
|
+
* @since v8.1.0
|
|
1379
|
+
*/
|
|
1380
|
+
export const ResultRowView: Component<ResultRowViewProps>;
|
|
1381
|
+
|
|
1382
|
+
/**
|
|
1383
|
+
* The ResultSortedTableView component renders the contents of a single sorted
|
|
1384
|
+
* Result Table in a Queries object, and registers a listener so that any
|
|
1385
|
+
* changes to that result will cause a re-render.
|
|
1386
|
+
* @param props The props for this component.
|
|
1387
|
+
* @returns A rendering of the sorted result Table.
|
|
1388
|
+
* @category Component
|
|
1389
|
+
* @since v8.1.0
|
|
1390
|
+
*/
|
|
1391
|
+
export const ResultSortedTableView: Component<ResultSortedTableViewProps>;
|
|
1392
|
+
|
|
1393
|
+
/**
|
|
1394
|
+
* The ResultTableView component renders the contents of a single Result Table
|
|
1395
|
+
* in a Queries object, and registers a listener so that any changes to that
|
|
1396
|
+
* result will cause a re-render.
|
|
1397
|
+
* @param props The props for this component.
|
|
1398
|
+
* @returns A rendering of the result Table.
|
|
1399
|
+
* @category Component
|
|
1400
|
+
* @since v8.1.0
|
|
1401
|
+
*/
|
|
1402
|
+
export const ResultTableView: Component<ResultTableViewProps>;
|
|
1403
|
+
|
|
1404
|
+
/**
|
|
1405
|
+
* The RowView component renders the contents of a single Row in a given Table,
|
|
1406
|
+
* and registers a listener so that any changes to that result will cause a
|
|
1407
|
+
* re-render.
|
|
1408
|
+
* @param props The props for this component.
|
|
1409
|
+
* @returns A rendering of the Row, or nothing if not present.
|
|
1410
|
+
* @category Component
|
|
1411
|
+
* @since v8.1.0
|
|
1412
|
+
*/
|
|
1413
|
+
export const RowView: Component<RowViewProps>;
|
|
1414
|
+
|
|
1415
|
+
/**
|
|
1416
|
+
* The SliceView component renders the Row Ids in a named Slice in an Index, and
|
|
1417
|
+
* registers a listener so that any changes to that result will cause a
|
|
1418
|
+
* re-render.
|
|
1419
|
+
* @param props The props for this component.
|
|
1420
|
+
* @returns A rendering of the Rows in the Slice.
|
|
1421
|
+
* @category Component
|
|
1422
|
+
* @since v8.1.0
|
|
1423
|
+
*/
|
|
1424
|
+
export const SliceView: Component<SliceViewProps>;
|
|
1425
|
+
|
|
1426
|
+
/**
|
|
1427
|
+
* The SortedTableView component renders the contents of a single Table in a
|
|
1428
|
+
* sorted order, and registers a listener so that any changes to that result
|
|
1429
|
+
* will cause a re-render.
|
|
1430
|
+
* @param props The props for this component.
|
|
1431
|
+
* @returns A rendering of the sorted Table.
|
|
1432
|
+
* @category Component
|
|
1433
|
+
* @since v8.1.0
|
|
1434
|
+
*/
|
|
1435
|
+
export const SortedTableView: Component<SortedTableViewProps>;
|
|
1436
|
+
|
|
1437
|
+
/**
|
|
1438
|
+
* The TableView component renders the contents of a single Table, and registers
|
|
1439
|
+
* a listener so that any changes to that result will cause a re-render.
|
|
1440
|
+
* @param props The props for this component.
|
|
1441
|
+
* @returns A rendering of the Table.
|
|
1442
|
+
* @category Component
|
|
1443
|
+
* @since v8.1.0
|
|
1444
|
+
*/
|
|
1445
|
+
export const TableView: Component<TableViewProps>;
|
|
1446
|
+
|
|
1447
|
+
/**
|
|
1448
|
+
* The TablesView component renders the contents of all Tables in a Store, and
|
|
1449
|
+
* registers a listener so that any changes to that result will cause a
|
|
1450
|
+
* re-render.
|
|
1451
|
+
* @param props The props for this component.
|
|
1452
|
+
* @returns A rendering of all Tables.
|
|
1453
|
+
* @category Component
|
|
1454
|
+
* @since v8.1.0
|
|
1455
|
+
*/
|
|
1456
|
+
export const TablesView: Component<TablesViewProps>;
|
|
1457
|
+
|
|
1458
|
+
/**
|
|
1459
|
+
* The ValueView component renders the value of a single Value in a Store, and
|
|
1460
|
+
* registers a listener so that any changes to that result will cause a
|
|
1461
|
+
* re-render.
|
|
1462
|
+
* @param props The props for this component.
|
|
1463
|
+
* @returns A rendering of the Value, or nothing if not present.
|
|
1464
|
+
* @category Component
|
|
1465
|
+
* @since v8.1.0
|
|
1466
|
+
*/
|
|
1467
|
+
export const ValueView: Component<ValueViewProps>;
|
|
1468
|
+
|
|
1469
|
+
/**
|
|
1470
|
+
* The ValuesView component renders all Values in a Store, and registers a
|
|
1471
|
+
* listener so that any changes to that result will cause a re-render.
|
|
1472
|
+
* @param props The props for this component.
|
|
1473
|
+
* @returns A rendering of all Values.
|
|
1474
|
+
* @category Component
|
|
1475
|
+
* @since v8.1.0
|
|
1476
|
+
*/
|
|
1477
|
+
export const ValuesView: Component<ValuesViewProps>;
|
|
1478
|
+
|
|
1479
|
+
/**
|
|
1480
|
+
* The useHasTables hook returns a reactive object indicating whether any Tables
|
|
1481
|
+
* exist in the Store, and registers a listener so that any changes to that
|
|
1482
|
+
* result will update `.current`.
|
|
1483
|
+
* @param storeOrStoreId The Store to use, or its Id in a Provider context.
|
|
1484
|
+
* @returns A reactive object with a `current` boolean property.
|
|
1485
|
+
* @category Hook
|
|
1486
|
+
* @since v8.1.0
|
|
1487
|
+
*/
|
|
1488
|
+
export function useHasTables(
|
|
1489
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
1490
|
+
): {
|
|
1491
|
+
readonly current: boolean;
|
|
1492
|
+
};
|
|
1493
|
+
|
|
1494
|
+
/**
|
|
1495
|
+
* The useTables hook returns a reactive object reflecting the Tables in the
|
|
1496
|
+
* Store, and registers a listener so that any changes to those Tables will
|
|
1497
|
+
* update `.current`.
|
|
1498
|
+
* @param storeOrStoreId The Store to use, or its Id in a Provider context.
|
|
1499
|
+
* @returns A reactive object with a `current` Tables property.
|
|
1500
|
+
* @category Hook
|
|
1501
|
+
* @since v8.1.0
|
|
1502
|
+
*/
|
|
1503
|
+
export function useTables(
|
|
1504
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
1505
|
+
): {
|
|
1506
|
+
readonly current: Tables;
|
|
1507
|
+
};
|
|
1508
|
+
|
|
1509
|
+
/**
|
|
1510
|
+
* The useTableIds hook returns a reactive object reflecting the Ids of the
|
|
1511
|
+
* Tables in a Store, and registers a listener so that any changes to those Ids
|
|
1512
|
+
* will update `.current`.
|
|
1513
|
+
* @param storeOrStoreId The Store to use (plain value or getter), or its Id.
|
|
1514
|
+
* @returns A reactive object with a `current` Ids property.
|
|
1515
|
+
* @category Hook
|
|
1516
|
+
* @since v8.1.0
|
|
1517
|
+
*/
|
|
1518
|
+
export function useTableIds(
|
|
1519
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
1520
|
+
): {
|
|
1521
|
+
readonly current: Ids;
|
|
1522
|
+
};
|
|
1523
|
+
|
|
1524
|
+
/**
|
|
1525
|
+
* The useHasTable hook returns a reactive object indicating whether a Table
|
|
1526
|
+
* exists in the Store, and registers a listener so that any changes to that
|
|
1527
|
+
* result will update `.current`.
|
|
1528
|
+
* @param tableId The Id of the Table (or a getter returning it).
|
|
1529
|
+
* @param storeOrStoreId The Store to use (plain value or getter), or its Id.
|
|
1530
|
+
* @returns A reactive object with a `current` boolean property.
|
|
1531
|
+
* @category Hook
|
|
1532
|
+
* @since v8.1.0
|
|
1533
|
+
*/
|
|
1534
|
+
export function useHasTable(
|
|
1535
|
+
tableId: MaybeGetter<Id>,
|
|
1536
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
1537
|
+
): {readonly current: boolean};
|
|
1538
|
+
|
|
1539
|
+
/**
|
|
1540
|
+
* The useTable hook returns a reactive object reflecting a Table in a Store,
|
|
1541
|
+
* and registers a listener so that any changes to that Table will update
|
|
1542
|
+
* `.current`.
|
|
1543
|
+
* @param tableId The Id of the Table (or a getter returning it).
|
|
1544
|
+
* @param storeOrStoreId The Store to use (plain value or getter), or its Id.
|
|
1545
|
+
* @returns A reactive object with a `current` Table property.
|
|
1546
|
+
* @category Hook
|
|
1547
|
+
* @since v8.1.0
|
|
1548
|
+
*/
|
|
1549
|
+
export function useTable(
|
|
1550
|
+
tableId: MaybeGetter<Id>,
|
|
1551
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
1552
|
+
): {readonly current: Table};
|
|
1553
|
+
|
|
1554
|
+
/**
|
|
1555
|
+
* The useTableCellIds hook returns a reactive object reflecting the Ids of all
|
|
1556
|
+
* Cells used across a Table, and registers a listener so that any changes to
|
|
1557
|
+
* those Ids will update `.current`.
|
|
1558
|
+
* @param tableId The Id of the Table (or a getter returning it).
|
|
1559
|
+
* @param storeOrStoreId The Store to use (plain value or getter), or its Id.
|
|
1560
|
+
* @returns A reactive object with a `current` Ids property.
|
|
1561
|
+
* @category Hook
|
|
1562
|
+
* @since v8.1.0
|
|
1563
|
+
*/
|
|
1564
|
+
export function useTableCellIds(
|
|
1565
|
+
tableId: MaybeGetter<Id>,
|
|
1566
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
1567
|
+
): {readonly current: Ids};
|
|
1568
|
+
|
|
1569
|
+
/**
|
|
1570
|
+
* The useHasTableCell hook returns a reactive object indicating whether a
|
|
1571
|
+
* particular Cell is used anywhere in a Table, and registers a listener so that
|
|
1572
|
+
* any changes to that result will update `.current`.
|
|
1573
|
+
* @param tableId The Id of the Table (or a getter returning it).
|
|
1574
|
+
* @param cellId The Id of the Cell (or a getter returning it).
|
|
1575
|
+
* @param storeOrStoreId The Store to use (plain value or getter), or its Id.
|
|
1576
|
+
* @returns A reactive object with a `current` boolean property.
|
|
1577
|
+
* @category Hook
|
|
1578
|
+
* @since v8.1.0
|
|
1579
|
+
*/
|
|
1580
|
+
export function useHasTableCell(
|
|
1581
|
+
tableId: MaybeGetter<Id>,
|
|
1582
|
+
cellId: MaybeGetter<Id>,
|
|
1583
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
1584
|
+
): {readonly current: boolean};
|
|
1585
|
+
|
|
1586
|
+
/**
|
|
1587
|
+
* The useRowCount hook returns a reactive object reflecting the number of Rows
|
|
1588
|
+
* in a Table, and registers a listener so that any changes will update
|
|
1589
|
+
* `.current`.
|
|
1590
|
+
* @param tableId The Id of the Table (or a getter returning it).
|
|
1591
|
+
* @param storeOrStoreId The Store to use (plain value or getter), or its Id.
|
|
1592
|
+
* @returns A reactive object with a `current` number property.
|
|
1593
|
+
* @category Hook
|
|
1594
|
+
* @since v8.1.0
|
|
1595
|
+
*/
|
|
1596
|
+
export function useRowCount(
|
|
1597
|
+
tableId: MaybeGetter<Id>,
|
|
1598
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
1599
|
+
): {readonly current: number};
|
|
1600
|
+
|
|
1601
|
+
/**
|
|
1602
|
+
* The useRowIds hook returns a reactive object reflecting the Ids of the Rows
|
|
1603
|
+
* in a Table, and registers a listener so that any changes will update
|
|
1604
|
+
* `.current`.
|
|
1605
|
+
* @param tableId The Id of the Table (or a getter returning it).
|
|
1606
|
+
* @param storeOrStoreId The Store to use (plain value or getter), or its Id.
|
|
1607
|
+
* @returns A reactive object with a `current` Ids property.
|
|
1608
|
+
* @category Hook
|
|
1609
|
+
* @since v8.1.0
|
|
1610
|
+
*/
|
|
1611
|
+
export function useRowIds(
|
|
1612
|
+
tableId: MaybeGetter<Id>,
|
|
1613
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
1614
|
+
): {readonly current: Ids};
|
|
1615
|
+
|
|
1616
|
+
/**
|
|
1617
|
+
* The useSortedRowIds hook returns a reactive object reflecting the sorted Row
|
|
1618
|
+
* Ids in a Table, and registers a listener so that any changes will update
|
|
1619
|
+
* `.current`.
|
|
1620
|
+
* @param tableId The Id of the Table (or a getter returning it).
|
|
1621
|
+
* @param cellId The Id of the Cell to sort by (or a getter returning it).
|
|
1622
|
+
* @param descending Whether to sort descending (or a getter returning it).
|
|
1623
|
+
* @param offset The starting Row offset (or a getter returning it).
|
|
1624
|
+
* @param limit The maximum number of Rows to return (or a getter returning it).
|
|
1625
|
+
* @param storeOrStoreId The Store to use (plain value or getter), or its Id.
|
|
1626
|
+
* @returns A reactive object with a `current` Ids property.
|
|
1627
|
+
* @category Hook
|
|
1628
|
+
* @since v8.1.0
|
|
1629
|
+
*/
|
|
1630
|
+
export function useSortedRowIds(
|
|
1631
|
+
tableId: MaybeGetter<Id>,
|
|
1632
|
+
cellId?: MaybeGetter<Id | undefined>,
|
|
1633
|
+
descending?: MaybeGetter<boolean>,
|
|
1634
|
+
offset?: MaybeGetter<number>,
|
|
1635
|
+
limit?: MaybeGetter<number | undefined>,
|
|
1636
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
1637
|
+
): {readonly current: Ids};
|
|
1638
|
+
|
|
1639
|
+
/**
|
|
1640
|
+
* The useHasRow hook returns a reactive object indicating whether a Row exists
|
|
1641
|
+
* in a Table, and registers a listener so that any changes to that result will
|
|
1642
|
+
* update `.current`.
|
|
1643
|
+
* @param tableId The Id of the Table (or a getter returning it).
|
|
1644
|
+
* @param rowId The Id of the Row (or a getter returning it).
|
|
1645
|
+
* @param storeOrStoreId The Store to use (plain value or getter), or its Id.
|
|
1646
|
+
* @returns A reactive object with a `current` boolean property.
|
|
1647
|
+
* @category Hook
|
|
1648
|
+
* @since v8.1.0
|
|
1649
|
+
*/
|
|
1650
|
+
export function useHasRow(
|
|
1651
|
+
tableId: MaybeGetter<Id>,
|
|
1652
|
+
rowId: MaybeGetter<Id>,
|
|
1653
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
1654
|
+
): {readonly current: boolean};
|
|
1655
|
+
|
|
1656
|
+
/**
|
|
1657
|
+
* The useRow hook returns a reactive object reflecting a Row in a Table, and
|
|
1658
|
+
* registers a listener so that any changes to that Row will update `.current`.
|
|
1659
|
+
* @param tableId The Id of the Table (or a getter returning it).
|
|
1660
|
+
* @param rowId The Id of the Row (or a getter returning it).
|
|
1661
|
+
* @param storeOrStoreId The Store to use (plain value or getter), or its Id.
|
|
1662
|
+
* @returns A reactive object with a `current` Row property.
|
|
1663
|
+
* @category Hook
|
|
1664
|
+
* @since v8.1.0
|
|
1665
|
+
*/
|
|
1666
|
+
export function useRow(
|
|
1667
|
+
tableId: MaybeGetter<Id>,
|
|
1668
|
+
rowId: MaybeGetter<Id>,
|
|
1669
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
1670
|
+
): {readonly current: Row};
|
|
1671
|
+
|
|
1672
|
+
/**
|
|
1673
|
+
* The useCellIds hook returns a reactive object reflecting the Ids of the Cells
|
|
1674
|
+
* in a Row, and registers a listener so that any changes will update
|
|
1675
|
+
* `.current`.
|
|
1676
|
+
* @param tableId The Id of the Table (or a getter returning it).
|
|
1677
|
+
* @param rowId The Id of the Row (or a getter returning it).
|
|
1678
|
+
* @param storeOrStoreId The Store to use (plain value or getter), or its Id.
|
|
1679
|
+
* @returns A reactive object with a `current` Ids property.
|
|
1680
|
+
* @category Hook
|
|
1681
|
+
* @since v8.1.0
|
|
1682
|
+
*/
|
|
1683
|
+
export function useCellIds(
|
|
1684
|
+
tableId: MaybeGetter<Id>,
|
|
1685
|
+
rowId: MaybeGetter<Id>,
|
|
1686
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
1687
|
+
): {readonly current: Ids};
|
|
1688
|
+
|
|
1689
|
+
/**
|
|
1690
|
+
* The useHasCell hook returns a reactive object indicating whether a Cell
|
|
1691
|
+
* exists in a Row in a Table, and registers a listener so that any changes to
|
|
1692
|
+
* that result will update `.current`.
|
|
1693
|
+
* @param tableId The Id of the Table (or a getter returning it).
|
|
1694
|
+
* @param rowId The Id of the Row (or a getter returning it).
|
|
1695
|
+
* @param cellId The Id of the Cell (or a getter returning it).
|
|
1696
|
+
* @param storeOrStoreId The Store to use (plain value or getter), or its Id.
|
|
1697
|
+
* @returns A reactive object with a `current` boolean property.
|
|
1698
|
+
* @category Hook
|
|
1699
|
+
* @since v8.1.0
|
|
1700
|
+
*/
|
|
1701
|
+
export function useHasCell(
|
|
1702
|
+
tableId: MaybeGetter<Id>,
|
|
1703
|
+
rowId: MaybeGetter<Id>,
|
|
1704
|
+
cellId: MaybeGetter<Id>,
|
|
1705
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
1706
|
+
): {readonly current: boolean};
|
|
1707
|
+
|
|
1708
|
+
/**
|
|
1709
|
+
* The useCell hook returns a reactive object reflecting the value of a Cell in
|
|
1710
|
+
* a Row in a Table, and registers a listener so that any changes to that Cell
|
|
1711
|
+
* will update `.current`.
|
|
1712
|
+
* @param tableId The Id of the Table (or a getter returning it).
|
|
1713
|
+
* @param rowId The Id of the Row (or a getter returning it).
|
|
1714
|
+
* @param cellId The Id of the Cell (or a getter returning it).
|
|
1715
|
+
* @param storeOrStoreId The Store to use (plain value or getter), or its Id.
|
|
1716
|
+
* @returns A reactive object with a `current` CellOrUndefined property.
|
|
1717
|
+
* @example
|
|
1718
|
+
* This example uses the useCell hook to display a Cell value reactively.
|
|
1719
|
+
*
|
|
1720
|
+
* ```ts
|
|
1721
|
+
* // In a .svelte file:
|
|
1722
|
+
* // const store = createStore().setCell('pets', 'cat', 'name', 'Fido');
|
|
1723
|
+
* // const name = useCell('pets', 'cat', 'name', store);
|
|
1724
|
+
* // $: console.log(name.current); // 'Fido'
|
|
1725
|
+
* ```
|
|
1726
|
+
* @category Hook
|
|
1727
|
+
* @since v8.1.0
|
|
1728
|
+
*/
|
|
1729
|
+
export function useCell(
|
|
1730
|
+
tableId: MaybeGetter<Id>,
|
|
1731
|
+
rowId: MaybeGetter<Id>,
|
|
1732
|
+
cellId: MaybeGetter<Id>,
|
|
1733
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
1734
|
+
): {readonly current: CellOrUndefined};
|
|
1735
|
+
|
|
1736
|
+
/**
|
|
1737
|
+
* The useBindableCell hook returns a reactive object reflecting the value of a
|
|
1738
|
+
* Cell, with a settable `current` property that writes back to the Store.
|
|
1739
|
+
* @param tableId The Id of the Table (or a getter returning it).
|
|
1740
|
+
* @param rowId The Id of the Row (or a getter returning it).
|
|
1741
|
+
* @param cellId The Id of the Cell (or a getter returning it).
|
|
1742
|
+
* @param storeOrStoreId The Store to use (plain value or getter), or its Id.
|
|
1743
|
+
* @returns A reactive object with gettable and settable `current`.
|
|
1744
|
+
* @category Hook
|
|
1745
|
+
* @since v8.1.0
|
|
1746
|
+
*/
|
|
1747
|
+
export function useBindableCell(
|
|
1748
|
+
tableId: MaybeGetter<Id>,
|
|
1749
|
+
rowId: MaybeGetter<Id>,
|
|
1750
|
+
cellId: MaybeGetter<Id>,
|
|
1751
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
1752
|
+
): {get current(): CellOrUndefined; set current(v: Cell)};
|
|
1753
|
+
|
|
1754
|
+
/**
|
|
1755
|
+
* The useHasValues hook returns a reactive object indicating whether any Values
|
|
1756
|
+
* exist in the Store, and registers a listener so that any changes to that
|
|
1757
|
+
* result will update `.current`.
|
|
1758
|
+
* @param storeOrStoreId The Store to use, or its Id in a Provider context.
|
|
1759
|
+
* @returns A reactive object with a `current` boolean property.
|
|
1760
|
+
* @category Hook
|
|
1761
|
+
* @since v8.1.0
|
|
1762
|
+
*/
|
|
1763
|
+
export function useHasValues(
|
|
1764
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
1765
|
+
): {
|
|
1766
|
+
readonly current: boolean;
|
|
1767
|
+
};
|
|
1768
|
+
|
|
1769
|
+
/**
|
|
1770
|
+
* The useValues hook returns a reactive object reflecting the Values in the
|
|
1771
|
+
* Store, and registers a listener so that any changes will update `.current`.
|
|
1772
|
+
* @param storeOrStoreId The Store to use, or its Id in a Provider context.
|
|
1773
|
+
* @returns A reactive object with a `current` Values property.
|
|
1774
|
+
* @category Hook
|
|
1775
|
+
* @since v8.1.0
|
|
1776
|
+
*/
|
|
1777
|
+
export function useValues(
|
|
1778
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
1779
|
+
): {
|
|
1780
|
+
readonly current: Values;
|
|
1781
|
+
};
|
|
1782
|
+
|
|
1783
|
+
/**
|
|
1784
|
+
* The useValueIds hook returns a reactive object reflecting the Ids of the
|
|
1785
|
+
* Values in a Store, and registers a listener so that any changes will update
|
|
1786
|
+
* `.current`.
|
|
1787
|
+
* @param storeOrStoreId The Store to use (plain value or getter), or its Id.
|
|
1788
|
+
* @returns A reactive object with a `current` Ids property.
|
|
1789
|
+
* @category Hook
|
|
1790
|
+
* @since v8.1.0
|
|
1791
|
+
*/
|
|
1792
|
+
export function useValueIds(
|
|
1793
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
1794
|
+
): {
|
|
1795
|
+
readonly current: Ids;
|
|
1796
|
+
};
|
|
1797
|
+
|
|
1798
|
+
/**
|
|
1799
|
+
* The useHasValue hook returns a reactive object indicating whether a Value
|
|
1800
|
+
* exists in the Store, and registers a listener so that any changes to that
|
|
1801
|
+
* result will update `.current`.
|
|
1802
|
+
* @param valueId The Id of the Value (or a getter returning it).
|
|
1803
|
+
* @param storeOrStoreId The Store to use (plain value or getter), or its Id.
|
|
1804
|
+
* @returns A reactive object with a `current` boolean property.
|
|
1805
|
+
* @category Hook
|
|
1806
|
+
* @since v8.1.0
|
|
1807
|
+
*/
|
|
1808
|
+
export function useHasValue(
|
|
1809
|
+
valueId: MaybeGetter<Id>,
|
|
1810
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
1811
|
+
): {readonly current: boolean};
|
|
1812
|
+
|
|
1813
|
+
/**
|
|
1814
|
+
* The useValue hook returns a reactive object reflecting the value of a Value
|
|
1815
|
+
* in a Store, and registers a listener so that any changes to that Value will
|
|
1816
|
+
* update `.current`.
|
|
1817
|
+
* @param valueId The Id of the Value (or a getter returning it).
|
|
1818
|
+
* @param storeOrStoreId The Store to use (plain value or getter), or its Id.
|
|
1819
|
+
* @returns A reactive object with a `current` ValueOrUndefined property.
|
|
1820
|
+
* @category Hook
|
|
1821
|
+
* @since v8.1.0
|
|
1822
|
+
*/
|
|
1823
|
+
export function useValue(
|
|
1824
|
+
valueId: MaybeGetter<Id>,
|
|
1825
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
1826
|
+
): {readonly current: ValueOrUndefined};
|
|
1827
|
+
|
|
1828
|
+
/**
|
|
1829
|
+
* The useBindableValue hook returns a reactive object reflecting the value of a
|
|
1830
|
+
* Value, with a settable `current` property that writes back to the Store.
|
|
1831
|
+
* @param valueId The Id of the Value (or a getter returning it).
|
|
1832
|
+
* @param storeOrStoreId The Store to use (plain value or getter), or its Id.
|
|
1833
|
+
* @returns A reactive object with gettable and settable `current`.
|
|
1834
|
+
* @category Hook
|
|
1835
|
+
* @since v8.1.0
|
|
1836
|
+
*/
|
|
1837
|
+
export function useBindableValue(
|
|
1838
|
+
valueId: MaybeGetter<Id>,
|
|
1839
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
1840
|
+
): {get current(): ValueOrUndefined; set current(v: Value)};
|
|
1841
|
+
|
|
1842
|
+
/**
|
|
1843
|
+
* The useStore hook returns the default Store from the current Provider context
|
|
1844
|
+
* (or a named Store if an Id is provided).
|
|
1845
|
+
* @param id An optional Id of a named Store in the Provider context.
|
|
1846
|
+
* @returns The Store, or `undefined` if not found.
|
|
1847
|
+
* @category Hook
|
|
1848
|
+
* @since v8.1.0
|
|
1849
|
+
*/
|
|
1850
|
+
export function useStore(id?: Id): Store | undefined;
|
|
1851
|
+
|
|
1852
|
+
/**
|
|
1853
|
+
* The useStoreOrStoreById hook is used to get a reference to a Store object
|
|
1854
|
+
* from a Provider context, or have it passed directly.
|
|
1855
|
+
* @param storeOrStoreId The Store, its Id, or a getter returning either.
|
|
1856
|
+
* @returns A getter function returning the Store, or `undefined`.
|
|
1857
|
+
* @category Hook
|
|
1858
|
+
* @since v8.1.0
|
|
1859
|
+
*/
|
|
1860
|
+
export function useStoreOrStoreById(
|
|
1861
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
1862
|
+
): () => Store | undefined;
|
|
1863
|
+
|
|
1864
|
+
/**
|
|
1865
|
+
* The useStoreIds hook returns a reactive object with the Ids of all Stores
|
|
1866
|
+
* registered in the current Provider context.
|
|
1867
|
+
* @returns A reactive object with a `current` Ids property.
|
|
1868
|
+
* @category Hook
|
|
1869
|
+
* @since v8.1.0
|
|
1870
|
+
*/
|
|
1871
|
+
export function useStoreIds(): {readonly current: Ids};
|
|
1872
|
+
|
|
1873
|
+
/**
|
|
1874
|
+
* The useMetrics hook returns the default Metrics object from the current
|
|
1875
|
+
* Provider context (or a named one if an Id is provided).
|
|
1876
|
+
* @param id An optional Id of a named Metrics object in the Provider context.
|
|
1877
|
+
* @returns The Metrics object, or `undefined` if not found.
|
|
1878
|
+
* @category Hook
|
|
1879
|
+
* @since v8.1.0
|
|
1880
|
+
*/
|
|
1881
|
+
export function useMetrics(id?: Id): Metrics | undefined;
|
|
1882
|
+
|
|
1883
|
+
/**
|
|
1884
|
+
* The useMetricsOrMetricsById hook is used to get a reference to a Metrics
|
|
1885
|
+
* object from a Provider context, or have it passed directly.
|
|
1886
|
+
* @param metricsOrMetricsId The Metrics object, its Id, or a getter returning
|
|
1887
|
+
* either.
|
|
1888
|
+
* @returns A getter function returning the Metrics object, or `undefined`.
|
|
1889
|
+
* @category Hook
|
|
1890
|
+
* @since v8.1.0
|
|
1891
|
+
*/
|
|
1892
|
+
export function useMetricsOrMetricsById(
|
|
1893
|
+
metricsOrMetricsId?: MaybeGetter<MetricsOrMetricsId | undefined>,
|
|
1894
|
+
): () => Metrics | undefined;
|
|
1895
|
+
|
|
1896
|
+
/**
|
|
1897
|
+
* The useMetricsIds hook returns a reactive object with the Ids of all Metrics
|
|
1898
|
+
* objects registered in the current Provider context.
|
|
1899
|
+
* @returns A reactive object with a `current` Ids property.
|
|
1900
|
+
* @category Hook
|
|
1901
|
+
* @since v8.1.0
|
|
1902
|
+
*/
|
|
1903
|
+
export function useMetricsIds(): {readonly current: Ids};
|
|
1904
|
+
|
|
1905
|
+
/**
|
|
1906
|
+
* The useMetricIds hook returns a reactive object reflecting the Ids of the
|
|
1907
|
+
* Metrics in a Metrics object, and registers a listener so that any changes
|
|
1908
|
+
* will update `.current`.
|
|
1909
|
+
* @param metricsOrMetricsId The Metrics object to use, or its Id.
|
|
1910
|
+
* @returns A reactive object with a `current` Ids property.
|
|
1911
|
+
* @category Hook
|
|
1912
|
+
* @since v8.1.0
|
|
1913
|
+
*/
|
|
1914
|
+
export function useMetricIds(
|
|
1915
|
+
metricsOrMetricsId?: MaybeGetter<MetricsOrMetricsId | undefined>,
|
|
1916
|
+
): {
|
|
1917
|
+
readonly current: Ids;
|
|
1918
|
+
};
|
|
1919
|
+
|
|
1920
|
+
/**
|
|
1921
|
+
* The useMetric hook returns a reactive object reflecting the value of a named
|
|
1922
|
+
* Metric in a Metrics object, and registers a listener so that any changes to
|
|
1923
|
+
* that Metric will update `.current`.
|
|
1924
|
+
* @param metricId The Id of the Metric (or a getter returning it).
|
|
1925
|
+
* @param metricsOrMetricsId The Metrics object to use (plain or getter), or its
|
|
1926
|
+
* Id.
|
|
1927
|
+
* @returns A reactive object with a `current` number | undefined property.
|
|
1928
|
+
* @category Hook
|
|
1929
|
+
* @since v8.1.0
|
|
1930
|
+
*/
|
|
1931
|
+
export function useMetric(
|
|
1932
|
+
metricId: MaybeGetter<Id>,
|
|
1933
|
+
metricsOrMetricsId?: MaybeGetter<MetricsOrMetricsId | undefined>,
|
|
1934
|
+
): {readonly current: number | undefined};
|
|
1935
|
+
|
|
1936
|
+
/**
|
|
1937
|
+
* The useIndexes hook returns the default Indexes object from the current
|
|
1938
|
+
* Provider context (or a named one if an Id is provided).
|
|
1939
|
+
* @param id An optional Id of a named Indexes object in the Provider context.
|
|
1940
|
+
* @returns The Indexes object, or `undefined` if not found.
|
|
1941
|
+
* @category Hook
|
|
1942
|
+
* @since v8.1.0
|
|
1943
|
+
*/
|
|
1944
|
+
export function useIndexes(id?: Id): Indexes | undefined;
|
|
1945
|
+
|
|
1946
|
+
/**
|
|
1947
|
+
* The useIndexesOrIndexesById hook is used to get a reference to an Indexes
|
|
1948
|
+
* object from a Provider context, or have it passed directly.
|
|
1949
|
+
* @param indexesOrIndexesId The Indexes object, its Id, or a getter returning
|
|
1950
|
+
* either.
|
|
1951
|
+
* @returns A getter function returning the Indexes object, or `undefined`.
|
|
1952
|
+
* @category Hook
|
|
1953
|
+
* @since v8.1.0
|
|
1954
|
+
*/
|
|
1955
|
+
export function useIndexesOrIndexesById(
|
|
1956
|
+
indexesOrIndexesId?: MaybeGetter<IndexesOrIndexesId | undefined>,
|
|
1957
|
+
): () => Indexes | undefined;
|
|
1958
|
+
|
|
1959
|
+
/**
|
|
1960
|
+
* The useIndexStoreTableId hook returns the Store and table Id for a given
|
|
1961
|
+
* Indexes object and index Id.
|
|
1962
|
+
* @param indexesOrId The Indexes object, its Id, or a getter returning either.
|
|
1963
|
+
* @param indexId The Id of the index, or a getter returning it.
|
|
1964
|
+
* @returns An object with `store` and `tableId` getter properties.
|
|
1965
|
+
* @category Hook
|
|
1966
|
+
* @since v8.1.0
|
|
1967
|
+
*/
|
|
1968
|
+
export function useIndexStoreTableId(
|
|
1969
|
+
indexesOrId: MaybeGetter<IndexesOrIndexesId | undefined>,
|
|
1970
|
+
indexId: MaybeGetter<Id>,
|
|
1971
|
+
): {readonly store: Store | undefined; readonly tableId: Id | undefined};
|
|
1972
|
+
|
|
1973
|
+
/**
|
|
1974
|
+
* The useIndexesIds hook returns a reactive object with the Ids of all Indexes
|
|
1975
|
+
* objects registered in the current Provider context.
|
|
1976
|
+
* @returns A reactive object with a `current` Ids property.
|
|
1977
|
+
* @category Hook
|
|
1978
|
+
* @since v8.1.0
|
|
1979
|
+
*/
|
|
1980
|
+
export function useIndexesIds(): {readonly current: Ids};
|
|
1981
|
+
|
|
1982
|
+
/**
|
|
1983
|
+
* The useIndexIds hook returns a reactive object reflecting the Ids of the
|
|
1984
|
+
* Indexes in an Indexes object, and registers a listener so that any changes
|
|
1985
|
+
* will update `.current`.
|
|
1986
|
+
* @param indexesOrIndexesId The Indexes object to use, or its Id.
|
|
1987
|
+
* @returns A reactive object with a `current` Ids property.
|
|
1988
|
+
* @category Hook
|
|
1989
|
+
* @since v8.1.0
|
|
1990
|
+
*/
|
|
1991
|
+
export function useIndexIds(
|
|
1992
|
+
indexesOrIndexesId?: MaybeGetter<IndexesOrIndexesId | undefined>,
|
|
1993
|
+
): {
|
|
1994
|
+
readonly current: Ids;
|
|
1995
|
+
};
|
|
1996
|
+
|
|
1997
|
+
/**
|
|
1998
|
+
* The useSliceIds hook returns a reactive object reflecting the Ids of the
|
|
1999
|
+
* Slices in an Index, and registers a listener so that any changes will update
|
|
2000
|
+
* `.current`.
|
|
2001
|
+
* @param indexId The Id of the Index (or a getter returning it).
|
|
2002
|
+
* @param indexesOrIndexesId The Indexes object to use (plain or getter), or its
|
|
2003
|
+
* Id.
|
|
2004
|
+
* @returns A reactive object with a `current` Ids property.
|
|
2005
|
+
* @category Hook
|
|
2006
|
+
* @since v8.1.0
|
|
2007
|
+
*/
|
|
2008
|
+
export function useSliceIds(
|
|
2009
|
+
indexId: MaybeGetter<Id>,
|
|
2010
|
+
indexesOrIndexesId?: MaybeGetter<IndexesOrIndexesId | undefined>,
|
|
2011
|
+
): {readonly current: Ids};
|
|
2012
|
+
|
|
2013
|
+
/**
|
|
2014
|
+
* The useSliceRowIds hook returns a reactive object reflecting the Ids of the
|
|
2015
|
+
* Rows in a Slice, and registers a listener so that any changes will update
|
|
2016
|
+
* `.current`.
|
|
2017
|
+
* @param indexId The Id of the Index (or a getter returning it).
|
|
2018
|
+
* @param sliceId The Id of the Slice (or a getter returning it).
|
|
2019
|
+
* @param indexesOrIndexesId The Indexes object to use (plain or getter), or its
|
|
2020
|
+
* Id.
|
|
2021
|
+
* @returns A reactive object with a `current` Ids property.
|
|
2022
|
+
* @category Hook
|
|
2023
|
+
* @since v8.1.0
|
|
2024
|
+
*/
|
|
2025
|
+
export function useSliceRowIds(
|
|
2026
|
+
indexId: MaybeGetter<Id>,
|
|
2027
|
+
sliceId: MaybeGetter<Id>,
|
|
2028
|
+
indexesOrIndexesId?: MaybeGetter<IndexesOrIndexesId | undefined>,
|
|
2029
|
+
): {readonly current: Ids};
|
|
2030
|
+
|
|
2031
|
+
/**
|
|
2032
|
+
* The useQueries hook returns the default Queries object from the current
|
|
2033
|
+
* Provider context (or a named one if an Id is provided).
|
|
2034
|
+
* @param id An optional Id of a named Queries object in the Provider context.
|
|
2035
|
+
* @returns The Queries object, or `undefined` if not found.
|
|
2036
|
+
* @category Hook
|
|
2037
|
+
* @since v8.1.0
|
|
2038
|
+
*/
|
|
2039
|
+
export function useQueries(id?: Id): Queries | undefined;
|
|
2040
|
+
|
|
2041
|
+
/**
|
|
2042
|
+
* The useQueriesOrQueriesById hook is used to get a reference to a Queries
|
|
2043
|
+
* object from a Provider context, or have it passed directly.
|
|
2044
|
+
* @param queriesOrQueriesId The Queries object, its Id, or a getter returning
|
|
2045
|
+
* either.
|
|
2046
|
+
* @returns A getter function returning the Queries object, or `undefined`.
|
|
2047
|
+
* @category Hook
|
|
2048
|
+
* @since v8.1.0
|
|
2049
|
+
*/
|
|
2050
|
+
export function useQueriesOrQueriesById(
|
|
2051
|
+
queriesOrQueriesId?: MaybeGetter<QueriesOrQueriesId | undefined>,
|
|
2052
|
+
): () => Queries | undefined;
|
|
2053
|
+
|
|
2054
|
+
/**
|
|
2055
|
+
* The useQueriesIds hook returns a reactive object with the Ids of all Queries
|
|
2056
|
+
* objects registered in the current Provider context.
|
|
2057
|
+
* @returns A reactive object with a `current` Ids property.
|
|
2058
|
+
* @category Hook
|
|
2059
|
+
* @since v8.1.0
|
|
2060
|
+
*/
|
|
2061
|
+
export function useQueriesIds(): {readonly current: Ids};
|
|
2062
|
+
|
|
2063
|
+
/**
|
|
2064
|
+
* The useQueryIds hook returns a reactive object reflecting the Ids of the
|
|
2065
|
+
* Queries in a Queries object, and registers a listener so that any changes
|
|
2066
|
+
* will update `.current`.
|
|
2067
|
+
* @param queriesOrQueriesId The Queries object to use, or its Id.
|
|
2068
|
+
* @returns A reactive object with a `current` Ids property.
|
|
2069
|
+
* @category Hook
|
|
2070
|
+
* @since v8.1.0
|
|
2071
|
+
*/
|
|
2072
|
+
export function useQueryIds(
|
|
2073
|
+
queriesOrQueriesId?: MaybeGetter<QueriesOrQueriesId | undefined>,
|
|
2074
|
+
): {
|
|
2075
|
+
readonly current: Ids;
|
|
2076
|
+
};
|
|
2077
|
+
|
|
2078
|
+
/**
|
|
2079
|
+
* The useResultTable hook returns a reactive object reflecting a result Table
|
|
2080
|
+
* in a Queries object, and registers a listener so that any changes to that
|
|
2081
|
+
* result will update `.current`.
|
|
2082
|
+
* @param queryId The Id of the Query (or a getter returning it).
|
|
2083
|
+
* @param queriesOrQueriesId The Queries object to use (plain or getter), or its
|
|
2084
|
+
* Id.
|
|
2085
|
+
* @returns A reactive object with a `current` Table property.
|
|
2086
|
+
* @category Hook
|
|
2087
|
+
* @since v8.1.0
|
|
2088
|
+
*/
|
|
2089
|
+
export function useResultTable(
|
|
2090
|
+
queryId: MaybeGetter<Id>,
|
|
2091
|
+
queriesOrQueriesId?: MaybeGetter<QueriesOrQueriesId | undefined>,
|
|
2092
|
+
): {readonly current: Table};
|
|
2093
|
+
|
|
2094
|
+
/**
|
|
2095
|
+
* The useResultTableCellIds hook returns a reactive object reflecting the Ids
|
|
2096
|
+
* of all Cells used across a result Table, and registers a listener so that any
|
|
2097
|
+
* changes will update `.current`.
|
|
2098
|
+
* @param queryId The Id of the Query (or a getter returning it).
|
|
2099
|
+
* @param queriesOrQueriesId The Queries object to use (plain or getter), or its
|
|
2100
|
+
* Id.
|
|
2101
|
+
* @returns A reactive object with a `current` Ids property.
|
|
2102
|
+
* @category Hook
|
|
2103
|
+
* @since v8.1.0
|
|
2104
|
+
*/
|
|
2105
|
+
export function useResultTableCellIds(
|
|
2106
|
+
queryId: MaybeGetter<Id>,
|
|
2107
|
+
queriesOrQueriesId?: MaybeGetter<QueriesOrQueriesId | undefined>,
|
|
2108
|
+
): {readonly current: Ids};
|
|
2109
|
+
|
|
2110
|
+
/**
|
|
2111
|
+
* The useResultRowCount hook returns a reactive object reflecting the number of
|
|
2112
|
+
* Rows in a result Table, and registers a listener so that any changes will
|
|
2113
|
+
* update `.current`.
|
|
2114
|
+
* @param queryId The Id of the Query (or a getter returning it).
|
|
2115
|
+
* @param queriesOrQueriesId The Queries object to use (plain or getter), or its
|
|
2116
|
+
* Id.
|
|
2117
|
+
* @returns A reactive object with a `current` number property.
|
|
2118
|
+
* @category Hook
|
|
2119
|
+
* @since v8.1.0
|
|
2120
|
+
*/
|
|
2121
|
+
export function useResultRowCount(
|
|
2122
|
+
queryId: MaybeGetter<Id>,
|
|
2123
|
+
queriesOrQueriesId?: MaybeGetter<QueriesOrQueriesId | undefined>,
|
|
2124
|
+
): {readonly current: number};
|
|
2125
|
+
|
|
2126
|
+
/**
|
|
2127
|
+
* The useResultRowIds hook returns a reactive object reflecting the Ids of the
|
|
2128
|
+
* Rows in a result Table, and registers a listener so that any changes will
|
|
2129
|
+
* update `.current`.
|
|
2130
|
+
* @param queryId The Id of the Query (or a getter returning it).
|
|
2131
|
+
* @param queriesOrQueriesId The Queries object to use (plain or getter), or its
|
|
2132
|
+
* Id.
|
|
2133
|
+
* @returns A reactive object with a `current` Ids property.
|
|
2134
|
+
* @category Hook
|
|
2135
|
+
* @since v8.1.0
|
|
2136
|
+
*/
|
|
2137
|
+
export function useResultRowIds(
|
|
2138
|
+
queryId: MaybeGetter<Id>,
|
|
2139
|
+
queriesOrQueriesId?: MaybeGetter<QueriesOrQueriesId | undefined>,
|
|
2140
|
+
): {readonly current: Ids};
|
|
2141
|
+
|
|
2142
|
+
/**
|
|
2143
|
+
* The useResultSortedRowIds hook returns a reactive object reflecting the
|
|
2144
|
+
* sorted Row Ids in a result Table, and registers a listener so that any
|
|
2145
|
+
* changes will update `.current`.
|
|
2146
|
+
* @param queryId The Id of the Query (or a getter returning it).
|
|
2147
|
+
* @param cellId The Id of the Cell to sort by (or a getter returning it).
|
|
2148
|
+
* @param descending Whether to sort descending (or a getter returning it).
|
|
2149
|
+
* @param offset The starting Row offset (or a getter returning it).
|
|
2150
|
+
* @param limit The maximum number of Rows (or a getter returning it).
|
|
2151
|
+
* @param queriesOrQueriesId The Queries object to use (plain or getter), or its
|
|
2152
|
+
* Id.
|
|
2153
|
+
* @returns A reactive object with a `current` Ids property.
|
|
2154
|
+
* @category Hook
|
|
2155
|
+
* @since v8.1.0
|
|
2156
|
+
*/
|
|
2157
|
+
export function useResultSortedRowIds(
|
|
2158
|
+
queryId: MaybeGetter<Id>,
|
|
2159
|
+
cellId?: MaybeGetter<Id | undefined>,
|
|
2160
|
+
descending?: MaybeGetter<boolean>,
|
|
2161
|
+
offset?: MaybeGetter<number>,
|
|
2162
|
+
limit?: MaybeGetter<number | undefined>,
|
|
2163
|
+
queriesOrQueriesId?: MaybeGetter<QueriesOrQueriesId | undefined>,
|
|
2164
|
+
): {readonly current: Ids};
|
|
2165
|
+
|
|
2166
|
+
/**
|
|
2167
|
+
* The useResultRow hook returns a reactive object reflecting a result Row in a
|
|
2168
|
+
* result Table, and registers a listener so that any changes will update
|
|
2169
|
+
* `.current`.
|
|
2170
|
+
* @param queryId The Id of the Query (or a getter returning it).
|
|
2171
|
+
* @param rowId The Id of the Row (or a getter returning it).
|
|
2172
|
+
* @param queriesOrQueriesId The Queries object to use (plain or getter), or its
|
|
2173
|
+
* Id.
|
|
2174
|
+
* @returns A reactive object with a `current` Row property.
|
|
2175
|
+
* @category Hook
|
|
2176
|
+
* @since v8.1.0
|
|
2177
|
+
*/
|
|
2178
|
+
export function useResultRow(
|
|
2179
|
+
queryId: MaybeGetter<Id>,
|
|
2180
|
+
rowId: MaybeGetter<Id>,
|
|
2181
|
+
queriesOrQueriesId?: MaybeGetter<QueriesOrQueriesId | undefined>,
|
|
2182
|
+
): {readonly current: Row};
|
|
2183
|
+
|
|
2184
|
+
/**
|
|
2185
|
+
* The useResultCellIds hook returns a reactive object reflecting the Ids of the
|
|
2186
|
+
* Cells in a result Row, and registers a listener so that any changes will
|
|
2187
|
+
* update `.current`.
|
|
2188
|
+
* @param queryId The Id of the Query (or a getter returning it).
|
|
2189
|
+
* @param rowId The Id of the Row (or a getter returning it).
|
|
2190
|
+
* @param queriesOrQueriesId The Queries object to use (plain or getter), or its
|
|
2191
|
+
* Id.
|
|
2192
|
+
* @returns A reactive object with a `current` Ids property.
|
|
2193
|
+
* @category Hook
|
|
2194
|
+
* @since v8.1.0
|
|
2195
|
+
*/
|
|
2196
|
+
export function useResultCellIds(
|
|
2197
|
+
queryId: MaybeGetter<Id>,
|
|
2198
|
+
rowId: MaybeGetter<Id>,
|
|
2199
|
+
queriesOrQueriesId?: MaybeGetter<QueriesOrQueriesId | undefined>,
|
|
2200
|
+
): {readonly current: Ids};
|
|
2201
|
+
|
|
2202
|
+
/**
|
|
2203
|
+
* The useResultCell hook returns a reactive object reflecting the value of a
|
|
2204
|
+
* Cell in a result Row, and registers a listener so that any changes will
|
|
2205
|
+
* update `.current`.
|
|
2206
|
+
* @param queryId The Id of the Query (or a getter returning it).
|
|
2207
|
+
* @param rowId The Id of the Row (or a getter returning it).
|
|
2208
|
+
* @param cellId The Id of the Cell (or a getter returning it).
|
|
2209
|
+
* @param queriesOrQueriesId The Queries object to use (plain or getter), or its
|
|
2210
|
+
* Id.
|
|
2211
|
+
* @returns A reactive object with a `current` Cell | undefined property.
|
|
2212
|
+
* @category Hook
|
|
2213
|
+
* @since v8.1.0
|
|
2214
|
+
*/
|
|
2215
|
+
export function useResultCell(
|
|
2216
|
+
queryId: MaybeGetter<Id>,
|
|
2217
|
+
rowId: MaybeGetter<Id>,
|
|
2218
|
+
cellId: MaybeGetter<Id>,
|
|
2219
|
+
queriesOrQueriesId?: MaybeGetter<QueriesOrQueriesId | undefined>,
|
|
2220
|
+
): {readonly current: CellOrUndefined};
|
|
2221
|
+
|
|
2222
|
+
/**
|
|
2223
|
+
* The useRelationships hook returns the default Relationships object from the
|
|
2224
|
+
* current Provider context (or a named one if an Id is provided).
|
|
2225
|
+
* @param id An optional Id of a named Relationships object in the Provider
|
|
2226
|
+
* context.
|
|
2227
|
+
* @returns The Relationships object, or `undefined` if not found.
|
|
2228
|
+
* @category Hook
|
|
2229
|
+
* @since v8.1.0
|
|
2230
|
+
*/
|
|
2231
|
+
export function useRelationships(id?: Id): Relationships | undefined;
|
|
2232
|
+
|
|
2233
|
+
/**
|
|
2234
|
+
* The useRelationshipsOrRelationshipsById hook is used to get a reference to a
|
|
2235
|
+
* Relationships object from a Provider context, or have it passed directly.
|
|
2236
|
+
* @param relationshipsOrRelationshipsId The Relationships object, its Id, or a
|
|
2237
|
+
* getter returning either.
|
|
2238
|
+
* @returns A getter function returning the Relationships object, or
|
|
2239
|
+
* `undefined`.
|
|
2240
|
+
* @category Hook
|
|
2241
|
+
* @since v8.1.0
|
|
2242
|
+
*/
|
|
2243
|
+
export function useRelationshipsOrRelationshipsById(
|
|
2244
|
+
relationshipsOrRelationshipsId?: MaybeGetter<
|
|
2245
|
+
RelationshipsOrRelationshipsId | undefined
|
|
2246
|
+
>,
|
|
2247
|
+
): () => Relationships | undefined;
|
|
2248
|
+
|
|
2249
|
+
/**
|
|
2250
|
+
* The useRelationshipsStoreTableIds hook returns the Store, local table Id, and
|
|
2251
|
+
* remote table Id for a given Relationships object and relationship Id.
|
|
2252
|
+
* @param relationshipsOrId The Relationships object, its Id, or a getter
|
|
2253
|
+
* returning either.
|
|
2254
|
+
* @param relationshipId The Id of the relationship, or a getter returning it.
|
|
2255
|
+
* @returns An object with `store`, `localTableId`, and `remoteTableId` getter
|
|
2256
|
+
* properties.
|
|
2257
|
+
* @category Hook
|
|
2258
|
+
* @since v8.1.0
|
|
2259
|
+
*/
|
|
2260
|
+
export function useRelationshipsStoreTableIds(
|
|
2261
|
+
relationshipsOrId: MaybeGetter<RelationshipsOrRelationshipsId | undefined>,
|
|
2262
|
+
relationshipId: MaybeGetter<Id>,
|
|
2263
|
+
): {
|
|
2264
|
+
readonly store: Store | undefined;
|
|
2265
|
+
readonly localTableId: Id | undefined;
|
|
2266
|
+
readonly remoteTableId: Id | undefined;
|
|
2267
|
+
};
|
|
2268
|
+
|
|
2269
|
+
/**
|
|
2270
|
+
* The useRelationshipsIds hook returns a reactive object with the Ids of all
|
|
2271
|
+
* Relationships objects registered in the current Provider context.
|
|
2272
|
+
* @returns A reactive object with a `current` Ids property.
|
|
2273
|
+
* @category Hook
|
|
2274
|
+
* @since v8.1.0
|
|
2275
|
+
*/
|
|
2276
|
+
export function useRelationshipsIds(): {readonly current: Ids};
|
|
2277
|
+
|
|
2278
|
+
/**
|
|
2279
|
+
* The useRelationshipIds hook returns a reactive object reflecting the Ids of
|
|
2280
|
+
* the Relationships in a Relationships object, and registers a listener so that
|
|
2281
|
+
* any changes will update `.current`.
|
|
2282
|
+
* @param relationshipsOrRelationshipsId The Relationships object to use, or its
|
|
2283
|
+
* Id.
|
|
2284
|
+
* @returns A reactive object with a `current` Ids property.
|
|
2285
|
+
* @category Hook
|
|
2286
|
+
* @since v8.1.0
|
|
2287
|
+
*/
|
|
2288
|
+
export function useRelationshipIds(
|
|
2289
|
+
relationshipsOrRelationshipsId?: MaybeGetter<
|
|
2290
|
+
RelationshipsOrRelationshipsId | undefined
|
|
2291
|
+
>,
|
|
2292
|
+
): {readonly current: Ids};
|
|
2293
|
+
|
|
2294
|
+
/**
|
|
2295
|
+
* The useRemoteRowId hook returns a reactive object reflecting the remote Row
|
|
2296
|
+
* Id for a given local Row in a Relationship, and registers a listener so that
|
|
2297
|
+
* any changes will update `.current`.
|
|
2298
|
+
* @param relationshipId The Id of the Relationship (or a getter returning it).
|
|
2299
|
+
* @param localRowId The Id of the local Row (or a getter returning it).
|
|
2300
|
+
* @param relationshipsOrRelationshipsId The Relationships object to use (plain
|
|
2301
|
+
* or getter), or its Id.
|
|
2302
|
+
* @returns A reactive object with a `current` Id | undefined property.
|
|
2303
|
+
* @category Hook
|
|
2304
|
+
* @since v8.1.0
|
|
2305
|
+
*/
|
|
2306
|
+
export function useRemoteRowId(
|
|
2307
|
+
relationshipId: MaybeGetter<Id>,
|
|
2308
|
+
localRowId: MaybeGetter<Id>,
|
|
2309
|
+
relationshipsOrRelationshipsId?: MaybeGetter<
|
|
2310
|
+
RelationshipsOrRelationshipsId | undefined
|
|
2311
|
+
>,
|
|
2312
|
+
): {readonly current: Id | undefined};
|
|
2313
|
+
|
|
2314
|
+
/**
|
|
2315
|
+
* The useLocalRowIds hook returns a reactive object reflecting the local Row
|
|
2316
|
+
* Ids for a given remote Row in a Relationship, and registers a listener so
|
|
2317
|
+
* that any changes will update `.current`.
|
|
2318
|
+
* @param relationshipId The Id of the Relationship (or a getter returning it).
|
|
2319
|
+
* @param remoteRowId The Id of the remote Row (or a getter returning it).
|
|
2320
|
+
* @param relationshipsOrRelationshipsId The Relationships object to use (plain
|
|
2321
|
+
* or getter), or its Id.
|
|
2322
|
+
* @returns A reactive object with a `current` Ids property.
|
|
2323
|
+
* @category Hook
|
|
2324
|
+
* @since v8.1.0
|
|
2325
|
+
*/
|
|
2326
|
+
export function useLocalRowIds(
|
|
2327
|
+
relationshipId: MaybeGetter<Id>,
|
|
2328
|
+
remoteRowId: MaybeGetter<Id>,
|
|
2329
|
+
relationshipsOrRelationshipsId?: MaybeGetter<
|
|
2330
|
+
RelationshipsOrRelationshipsId | undefined
|
|
2331
|
+
>,
|
|
2332
|
+
): {readonly current: Ids};
|
|
2333
|
+
|
|
2334
|
+
/**
|
|
2335
|
+
* The useLinkedRowIds hook returns a reactive object reflecting the linked Row
|
|
2336
|
+
* Ids in a Relationship, and registers a listener so that any changes will
|
|
2337
|
+
* update `.current`.
|
|
2338
|
+
* @param relationshipId The Id of the Relationship (or a getter returning it).
|
|
2339
|
+
* @param firstRowId The Id of the first Row (or a getter returning it).
|
|
2340
|
+
* @param relationshipsOrRelationshipsId The Relationships object to use (plain
|
|
2341
|
+
* or getter), or its Id.
|
|
2342
|
+
* @returns A reactive object with a `current` Ids property.
|
|
2343
|
+
* @category Hook
|
|
2344
|
+
* @since v8.1.0
|
|
2345
|
+
*/
|
|
2346
|
+
export function useLinkedRowIds(
|
|
2347
|
+
relationshipId: MaybeGetter<Id>,
|
|
2348
|
+
firstRowId: MaybeGetter<Id>,
|
|
2349
|
+
relationshipsOrRelationshipsId?: MaybeGetter<
|
|
2350
|
+
RelationshipsOrRelationshipsId | undefined
|
|
2351
|
+
>,
|
|
2352
|
+
): {readonly current: Ids};
|
|
2353
|
+
|
|
2354
|
+
/**
|
|
2355
|
+
* The useCheckpoints hook returns the default Checkpoints object from the
|
|
2356
|
+
* current Provider context (or a named one if an Id is provided).
|
|
2357
|
+
* @param id An optional Id of a named Checkpoints object in the Provider
|
|
2358
|
+
* context.
|
|
2359
|
+
* @returns The Checkpoints object, or `undefined` if not found.
|
|
2360
|
+
* @category Hook
|
|
2361
|
+
* @since v8.1.0
|
|
2362
|
+
*/
|
|
2363
|
+
export function useCheckpoints(id?: Id): Checkpoints | undefined;
|
|
2364
|
+
|
|
2365
|
+
/**
|
|
2366
|
+
* The useCheckpointsOrCheckpointsById hook is used to get a reference to a
|
|
2367
|
+
* Checkpoints object from a Provider context, or have it passed directly.
|
|
2368
|
+
* @param checkpointsOrCheckpointsId The Checkpoints object, its Id, or a
|
|
2369
|
+
* getter returning either.
|
|
2370
|
+
* @returns A getter function returning the Checkpoints object, or `undefined`.
|
|
2371
|
+
* @category Hook
|
|
2372
|
+
* @since v8.1.0
|
|
2373
|
+
*/
|
|
2374
|
+
export function useCheckpointsOrCheckpointsById(
|
|
2375
|
+
checkpointsOrCheckpointsId?: MaybeGetter<
|
|
2376
|
+
CheckpointsOrCheckpointsId | undefined
|
|
2377
|
+
>,
|
|
2378
|
+
): () => Checkpoints | undefined;
|
|
2379
|
+
|
|
2380
|
+
/**
|
|
2381
|
+
* The useCheckpointsIds hook returns a reactive object with the Ids of all
|
|
2382
|
+
* Checkpoints objects registered in the current Provider context.
|
|
2383
|
+
* @returns A reactive object with a `current` Ids property.
|
|
2384
|
+
* @category Hook
|
|
2385
|
+
* @since v8.1.0
|
|
2386
|
+
*/
|
|
2387
|
+
export function useCheckpointsIds(): {readonly current: Ids};
|
|
2388
|
+
|
|
2389
|
+
/**
|
|
2390
|
+
* The useCheckpointIds hook returns a reactive object reflecting the
|
|
2391
|
+
* CheckpointIds (backward, current, forward) in a Checkpoints object, and
|
|
2392
|
+
* registers a listener so that any changes will update `.current`.
|
|
2393
|
+
* @param checkpointsOrCheckpointsId The Checkpoints object to use (plain or
|
|
2394
|
+
* getter), or its Id.
|
|
2395
|
+
* @returns A reactive object with a `current` CheckpointIds property.
|
|
2396
|
+
* @category Hook
|
|
2397
|
+
* @since v8.1.0
|
|
2398
|
+
*/
|
|
2399
|
+
export function useCheckpointIds(
|
|
2400
|
+
checkpointsOrCheckpointsId?: MaybeGetter<
|
|
2401
|
+
CheckpointsOrCheckpointsId | undefined
|
|
2402
|
+
>,
|
|
2403
|
+
): {readonly current: CheckpointIds};
|
|
2404
|
+
|
|
2405
|
+
/**
|
|
2406
|
+
* The useCheckpoint hook returns a reactive object reflecting the label of a
|
|
2407
|
+
* checkpoint, and registers a listener so that any changes will update
|
|
2408
|
+
* `.current`.
|
|
2409
|
+
* @param checkpointId The Id of the checkpoint (or a getter returning it).
|
|
2410
|
+
* @param checkpointsOrCheckpointsId The Checkpoints object to use (plain or
|
|
2411
|
+
* getter), or its Id.
|
|
2412
|
+
* @returns A reactive object with a `current` string | undefined property.
|
|
2413
|
+
* @category Hook
|
|
2414
|
+
* @since v8.1.0
|
|
2415
|
+
*/
|
|
2416
|
+
export function useCheckpoint(
|
|
2417
|
+
checkpointId: MaybeGetter<Id>,
|
|
2418
|
+
checkpointsOrCheckpointsId?: MaybeGetter<
|
|
2419
|
+
CheckpointsOrCheckpointsId | undefined
|
|
2420
|
+
>,
|
|
2421
|
+
): {readonly current: string | undefined};
|
|
2422
|
+
|
|
2423
|
+
/**
|
|
2424
|
+
* The useGoBackwardCallback hook returns a callback function that, when called,
|
|
2425
|
+
* moves the Checkpoints object backward to the previous checkpoint.
|
|
2426
|
+
* @param checkpointsOrCheckpointsId The Checkpoints object to use, or its Id.
|
|
2427
|
+
* @returns A callback function.
|
|
2428
|
+
* @category Hook
|
|
2429
|
+
* @since v8.1.0
|
|
2430
|
+
*/
|
|
2431
|
+
export function useGoBackwardCallback(
|
|
2432
|
+
checkpointsOrCheckpointsId?: MaybeGetter<
|
|
2433
|
+
CheckpointsOrCheckpointsId | undefined
|
|
2434
|
+
>,
|
|
2435
|
+
): () => void;
|
|
2436
|
+
|
|
2437
|
+
/**
|
|
2438
|
+
* The useGoForwardCallback hook returns a callback function that, when called,
|
|
2439
|
+
* moves the Checkpoints object forward to the next checkpoint.
|
|
2440
|
+
* @param checkpointsOrCheckpointsId The Checkpoints object to use, or its Id.
|
|
2441
|
+
* @returns A callback function.
|
|
2442
|
+
* @category Hook
|
|
2443
|
+
* @since v8.1.0
|
|
2444
|
+
*/
|
|
2445
|
+
export function useGoForwardCallback(
|
|
2446
|
+
checkpointsOrCheckpointsId?: MaybeGetter<
|
|
2447
|
+
CheckpointsOrCheckpointsId | undefined
|
|
2448
|
+
>,
|
|
2449
|
+
): () => void;
|
|
2450
|
+
|
|
2451
|
+
/**
|
|
2452
|
+
* The usePersister hook returns the default Persister from the current Provider
|
|
2453
|
+
* context (or a named one if an Id is provided).
|
|
2454
|
+
* @param id An optional Id of a named Persister in the Provider context.
|
|
2455
|
+
* @returns The Persister, or `undefined` if not found.
|
|
2456
|
+
* @category Hook
|
|
2457
|
+
* @since v8.1.0
|
|
2458
|
+
*/
|
|
2459
|
+
export function usePersister(id?: Id): AnyPersister | undefined;
|
|
2460
|
+
|
|
2461
|
+
/**
|
|
2462
|
+
* The usePersisterOrPersisterById hook is used to get a reference to a
|
|
2463
|
+
* Persister object from a Provider context, or have it passed directly.
|
|
2464
|
+
* @param persisterOrPersisterId The Persister object, its Id, or a getter
|
|
2465
|
+
* returning either.
|
|
2466
|
+
* @returns A getter function returning the Persister object, or `undefined`.
|
|
2467
|
+
* @category Hook
|
|
2468
|
+
* @since v8.1.0
|
|
2469
|
+
*/
|
|
2470
|
+
export function usePersisterOrPersisterById(
|
|
2471
|
+
persisterOrPersisterId?: MaybeGetter<PersisterOrPersisterId | undefined>,
|
|
2472
|
+
): () => AnyPersister | undefined;
|
|
2473
|
+
|
|
2474
|
+
/**
|
|
2475
|
+
* The usePersisterIds hook returns a reactive object with the Ids of all
|
|
2476
|
+
* Persisters registered in the current Provider context.
|
|
2477
|
+
* @returns A reactive object with a `current` Ids property.
|
|
2478
|
+
* @category Hook
|
|
2479
|
+
* @since v8.1.0
|
|
2480
|
+
*/
|
|
2481
|
+
export function usePersisterIds(): {readonly current: Ids};
|
|
2482
|
+
|
|
2483
|
+
/**
|
|
2484
|
+
* The usePersisterStatus hook returns a reactive object reflecting the status
|
|
2485
|
+
* of a Persister, and registers a listener so that any changes will update
|
|
2486
|
+
* `.current`.
|
|
2487
|
+
* @param persisterOrPersisterId The Persister to use, or its Id.
|
|
2488
|
+
* @returns A reactive object with a `current` Status property.
|
|
2489
|
+
* @category Hook
|
|
2490
|
+
* @since v8.1.0
|
|
2491
|
+
*/
|
|
2492
|
+
export function usePersisterStatus(
|
|
2493
|
+
persisterOrPersisterId?: MaybeGetter<PersisterOrPersisterId | undefined>,
|
|
2494
|
+
): {readonly current: Status};
|
|
2495
|
+
|
|
2496
|
+
/**
|
|
2497
|
+
* The useSynchronizer hook returns the default Synchronizer from the current
|
|
2498
|
+
* Provider context (or a named one if an Id is provided).
|
|
2499
|
+
* @param id An optional Id of a named Synchronizer in the Provider context.
|
|
2500
|
+
* @returns The Synchronizer, or `undefined` if not found.
|
|
2501
|
+
* @category Hook
|
|
2502
|
+
* @since v8.1.0
|
|
2503
|
+
*/
|
|
2504
|
+
export function useSynchronizer(id?: Id): Synchronizer | undefined;
|
|
2505
|
+
|
|
2506
|
+
/**
|
|
2507
|
+
* The useSynchronizerOrSynchronizerById hook is used to get a reference to a
|
|
2508
|
+
* Synchronizer object from a Provider context, or have it passed directly.
|
|
2509
|
+
* @param synchronizerOrSynchronizerId The Synchronizer object, its Id, or a
|
|
2510
|
+
* getter returning either.
|
|
2511
|
+
* @returns A getter function returning the Synchronizer object, or `undefined`.
|
|
2512
|
+
* @category Hook
|
|
2513
|
+
* @since v8.1.0
|
|
2514
|
+
*/
|
|
2515
|
+
export function useSynchronizerOrSynchronizerById(
|
|
2516
|
+
synchronizerOrSynchronizerId?: MaybeGetter<
|
|
2517
|
+
SynchronizerOrSynchronizerId | undefined
|
|
2518
|
+
>,
|
|
2519
|
+
): () => Synchronizer | undefined;
|
|
2520
|
+
|
|
2521
|
+
/**
|
|
2522
|
+
* The useSynchronizerIds hook returns a reactive object with the Ids of all
|
|
2523
|
+
* Synchronizers registered in the current Provider context.
|
|
2524
|
+
* @returns A reactive object with a `current` Ids property.
|
|
2525
|
+
* @category Hook
|
|
2526
|
+
* @since v8.1.0
|
|
2527
|
+
*/
|
|
2528
|
+
export function useSynchronizerIds(): {readonly current: Ids};
|
|
2529
|
+
|
|
2530
|
+
/**
|
|
2531
|
+
* The useSynchronizerStatus hook returns a reactive object reflecting the
|
|
2532
|
+
* status of a Synchronizer, and registers a listener so that any changes will
|
|
2533
|
+
* update `.current`.
|
|
2534
|
+
* @param synchronizerOrSynchronizerId The Synchronizer to use, or its Id.
|
|
2535
|
+
* @returns A reactive object with a `current` Status property.
|
|
2536
|
+
* @category Hook
|
|
2537
|
+
* @since v8.1.0
|
|
2538
|
+
*/
|
|
2539
|
+
export function useSynchronizerStatus(
|
|
2540
|
+
synchronizerOrSynchronizerId?: MaybeGetter<
|
|
2541
|
+
SynchronizerOrSynchronizerId | undefined
|
|
2542
|
+
>,
|
|
2543
|
+
): {readonly current: Status};
|
|
2544
|
+
|
|
2545
|
+
/**
|
|
2546
|
+
* The useHasTablesListener hook registers a listener that is
|
|
2547
|
+
* called whenever any Tables are added to or removed from the
|
|
2548
|
+
* Store. The listener is tied to the component's `$effect`
|
|
2549
|
+
* lifecycle and is removed when the component unmounts.
|
|
2550
|
+
* @param listener The function to call when table presence
|
|
2551
|
+
* changes.
|
|
2552
|
+
* @param mutator An optional boolean indicating the listener
|
|
2553
|
+
* mutates Store data.
|
|
2554
|
+
* @param storeOrStoreId The Store to use, or its Id.
|
|
2555
|
+
* @category Hook
|
|
2556
|
+
* @since v8.1.0
|
|
2557
|
+
*/
|
|
2558
|
+
export function useHasTablesListener(
|
|
2559
|
+
listener: HasTablesListener,
|
|
2560
|
+
mutator?: boolean,
|
|
2561
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
2562
|
+
): void;
|
|
2563
|
+
|
|
2564
|
+
/**
|
|
2565
|
+
* The useTablesListener hook registers a listener that is
|
|
2566
|
+
* called whenever tabular data in the Store changes.
|
|
2567
|
+
* @param listener The function to call when Tables change.
|
|
2568
|
+
* @param mutator An optional boolean indicating the listener
|
|
2569
|
+
* mutates Store data.
|
|
2570
|
+
* @param storeOrStoreId The Store to use, or its Id.
|
|
2571
|
+
* @category Hook
|
|
2572
|
+
* @since v8.1.0
|
|
2573
|
+
*/
|
|
2574
|
+
export function useTablesListener(
|
|
2575
|
+
listener: TablesListener,
|
|
2576
|
+
mutator?: boolean,
|
|
2577
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
2578
|
+
): void;
|
|
2579
|
+
|
|
2580
|
+
/**
|
|
2581
|
+
* The useTableIdsListener hook registers a listener that is
|
|
2582
|
+
* called whenever the set of Table Ids in the Store changes.
|
|
2583
|
+
* @param listener The function to call when Table Ids change.
|
|
2584
|
+
* @param mutator An optional boolean indicating the listener
|
|
2585
|
+
* mutates Store data.
|
|
2586
|
+
* @param storeOrStoreId The Store to use, or its Id.
|
|
2587
|
+
* @category Hook
|
|
2588
|
+
* @since v8.1.0
|
|
2589
|
+
*/
|
|
2590
|
+
export function useTableIdsListener(
|
|
2591
|
+
listener: TableIdsListener,
|
|
2592
|
+
mutator?: boolean,
|
|
2593
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
2594
|
+
): void;
|
|
2595
|
+
|
|
2596
|
+
/**
|
|
2597
|
+
* The useHasTableListener hook registers a listener that is
|
|
2598
|
+
* called whenever a specified Table is added to or removed
|
|
2599
|
+
* from the Store.
|
|
2600
|
+
* @param tableId The Id of the Table to listen to, or `null`
|
|
2601
|
+
* to listen to any Table.
|
|
2602
|
+
* @param listener The function to call when the Table changes.
|
|
2603
|
+
* @param mutator An optional boolean indicating the listener
|
|
2604
|
+
* mutates Store data.
|
|
2605
|
+
* @param storeOrStoreId The Store to use, or its Id.
|
|
2606
|
+
* @category Hook
|
|
2607
|
+
* @since v8.1.0
|
|
2608
|
+
*/
|
|
2609
|
+
export function useHasTableListener(
|
|
2610
|
+
tableId: MaybeGetter<IdOrNull>,
|
|
2611
|
+
listener: HasTableListener,
|
|
2612
|
+
mutator?: boolean,
|
|
2613
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
2614
|
+
): void;
|
|
2615
|
+
|
|
2616
|
+
/**
|
|
2617
|
+
* The useTableListener hook registers a listener that is
|
|
2618
|
+
* called whenever data in a specified Table changes.
|
|
2619
|
+
* @param tableId The Id of the Table to listen to, or `null`
|
|
2620
|
+
* to listen to any Table.
|
|
2621
|
+
* @param listener The function to call when the Table changes.
|
|
2622
|
+
* @param mutator An optional boolean indicating the listener
|
|
2623
|
+
* mutates Store data.
|
|
2624
|
+
* @param storeOrStoreId The Store to use, or its Id.
|
|
2625
|
+
* @category Hook
|
|
2626
|
+
* @since v8.1.0
|
|
2627
|
+
*/
|
|
2628
|
+
export function useTableListener(
|
|
2629
|
+
tableId: MaybeGetter<IdOrNull>,
|
|
2630
|
+
listener: TableListener,
|
|
2631
|
+
mutator?: boolean,
|
|
2632
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
2633
|
+
): void;
|
|
2634
|
+
|
|
2635
|
+
/**
|
|
2636
|
+
* The useTableCellIdsListener hook registers a listener that
|
|
2637
|
+
* is called whenever the Cell Ids used across a Table change.
|
|
2638
|
+
* @param tableId The Id of the Table to listen to, or `null`
|
|
2639
|
+
* to listen to any Table.
|
|
2640
|
+
* @param listener The function to call when Cell Ids change.
|
|
2641
|
+
* @param mutator An optional boolean indicating the listener
|
|
2642
|
+
* mutates Store data.
|
|
2643
|
+
* @param storeOrStoreId The Store to use, or its Id.
|
|
2644
|
+
* @category Hook
|
|
2645
|
+
* @since v8.1.0
|
|
2646
|
+
*/
|
|
2647
|
+
export function useTableCellIdsListener(
|
|
2648
|
+
tableId: MaybeGetter<IdOrNull>,
|
|
2649
|
+
listener: TableCellIdsListener,
|
|
2650
|
+
mutator?: boolean,
|
|
2651
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
2652
|
+
): void;
|
|
2653
|
+
|
|
2654
|
+
/**
|
|
2655
|
+
* The useHasTableCellListener hook registers a listener that
|
|
2656
|
+
* is called whenever a specified Cell Id is added to or
|
|
2657
|
+
* removed from across a Table.
|
|
2658
|
+
* @param tableId The Id of the Table to listen to, or `null`
|
|
2659
|
+
* to listen to any Table.
|
|
2660
|
+
* @param cellId The Id of the Cell to listen to, or `null`
|
|
2661
|
+
* to listen to any Cell Id.
|
|
2662
|
+
* @param listener The function to call when the Cell Id
|
|
2663
|
+
* changes.
|
|
2664
|
+
* @param mutator An optional boolean indicating the listener
|
|
2665
|
+
* mutates Store data.
|
|
2666
|
+
* @param storeOrStoreId The Store to use, or its Id.
|
|
2667
|
+
* @category Hook
|
|
2668
|
+
* @since v8.1.0
|
|
2669
|
+
*/
|
|
2670
|
+
export function useHasTableCellListener(
|
|
2671
|
+
tableId: MaybeGetter<IdOrNull>,
|
|
2672
|
+
cellId: MaybeGetter<IdOrNull>,
|
|
2673
|
+
listener: HasTableCellListener,
|
|
2674
|
+
mutator?: boolean,
|
|
2675
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
2676
|
+
): void;
|
|
2677
|
+
|
|
2678
|
+
/**
|
|
2679
|
+
* The useRowCountListener hook registers a listener that is
|
|
2680
|
+
* called whenever the count of Rows in a Table changes.
|
|
2681
|
+
* @param tableId The Id of the Table to listen to, or `null`
|
|
2682
|
+
* to listen to any Table.
|
|
2683
|
+
* @param listener The function to call when the Row count
|
|
2684
|
+
* changes.
|
|
2685
|
+
* @param mutator An optional boolean indicating the listener
|
|
2686
|
+
* mutates Store data.
|
|
2687
|
+
* @param storeOrStoreId The Store to use, or its Id.
|
|
2688
|
+
* @category Hook
|
|
2689
|
+
* @since v8.1.0
|
|
2690
|
+
*/
|
|
2691
|
+
export function useRowCountListener(
|
|
2692
|
+
tableId: MaybeGetter<IdOrNull>,
|
|
2693
|
+
listener: RowCountListener,
|
|
2694
|
+
mutator?: boolean,
|
|
2695
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
2696
|
+
): void;
|
|
2697
|
+
|
|
2698
|
+
/**
|
|
2699
|
+
* The useRowIdsListener hook registers a listener that is
|
|
2700
|
+
* called whenever the Row Ids in a Table change.
|
|
2701
|
+
* @param tableId The Id of the Table to listen to, or `null`
|
|
2702
|
+
* to listen to any Table.
|
|
2703
|
+
* @param listener The function to call when Row Ids change.
|
|
2704
|
+
* @param mutator An optional boolean indicating the listener
|
|
2705
|
+
* mutates Store data.
|
|
2706
|
+
* @param storeOrStoreId The Store to use, or its Id.
|
|
2707
|
+
* @category Hook
|
|
2708
|
+
* @since v8.1.0
|
|
2709
|
+
*/
|
|
2710
|
+
export function useRowIdsListener(
|
|
2711
|
+
tableId: MaybeGetter<IdOrNull>,
|
|
2712
|
+
listener: RowIdsListener,
|
|
2713
|
+
mutator?: boolean,
|
|
2714
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
2715
|
+
): void;
|
|
2716
|
+
|
|
2717
|
+
/**
|
|
2718
|
+
* The useSortedRowIdsListener hook registers a listener that
|
|
2719
|
+
* is called whenever the sorted Row Ids in a Table change.
|
|
2720
|
+
* @param tableId The Id of the Table to listen to.
|
|
2721
|
+
* @param cellId The Id of the Cell to sort by, or `undefined`
|
|
2722
|
+
* for default order.
|
|
2723
|
+
* @param descending Whether to sort descending.
|
|
2724
|
+
* @param offset The index of the first Row to include.
|
|
2725
|
+
* @param limit The maximum number of Rows to include, or
|
|
2726
|
+
* `undefined` for all.
|
|
2727
|
+
* @param listener The function to call when sorted Row Ids
|
|
2728
|
+
* change.
|
|
2729
|
+
* @param mutator An optional boolean indicating the listener
|
|
2730
|
+
* mutates Store data.
|
|
2731
|
+
* @param storeOrStoreId The Store to use, or its Id.
|
|
2732
|
+
* @category Hook
|
|
2733
|
+
* @since v8.1.0
|
|
2734
|
+
*/
|
|
2735
|
+
export function useSortedRowIdsListener(
|
|
2736
|
+
tableId: MaybeGetter<Id>,
|
|
2737
|
+
cellId: MaybeGetter<Id | undefined>,
|
|
2738
|
+
descending: MaybeGetter<boolean>,
|
|
2739
|
+
offset: MaybeGetter<number>,
|
|
2740
|
+
limit: MaybeGetter<number | undefined>,
|
|
2741
|
+
listener: SortedRowIdsListener,
|
|
2742
|
+
mutator?: boolean,
|
|
2743
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
2744
|
+
): void;
|
|
2745
|
+
|
|
2746
|
+
/**
|
|
2747
|
+
* The useHasRowListener hook registers a listener that is
|
|
2748
|
+
* called whenever a specified Row is added to or removed from
|
|
2749
|
+
* a Table.
|
|
2750
|
+
* @param tableId The Id of the Table to listen to, or `null`
|
|
2751
|
+
* to listen to any Table.
|
|
2752
|
+
* @param rowId The Id of the Row to listen to, or `null` to
|
|
2753
|
+
* listen to any Row.
|
|
2754
|
+
* @param listener The function to call when the Row changes.
|
|
2755
|
+
* @param mutator An optional boolean indicating the listener
|
|
2756
|
+
* mutates Store data.
|
|
2757
|
+
* @param storeOrStoreId The Store to use, or its Id.
|
|
2758
|
+
* @category Hook
|
|
2759
|
+
* @since v8.1.0
|
|
2760
|
+
*/
|
|
2761
|
+
export function useHasRowListener(
|
|
2762
|
+
tableId: MaybeGetter<IdOrNull>,
|
|
2763
|
+
rowId: MaybeGetter<IdOrNull>,
|
|
2764
|
+
listener: HasRowListener,
|
|
2765
|
+
mutator?: boolean,
|
|
2766
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
2767
|
+
): void;
|
|
2768
|
+
|
|
2769
|
+
/**
|
|
2770
|
+
* The useRowListener hook registers a listener that is called
|
|
2771
|
+
* whenever data in a specified Row changes.
|
|
2772
|
+
* @param tableId The Id of the Table to listen to, or `null`
|
|
2773
|
+
* to listen to any Table.
|
|
2774
|
+
* @param rowId The Id of the Row to listen to, or `null` to
|
|
2775
|
+
* listen to any Row.
|
|
2776
|
+
* @param listener The function to call when the Row changes.
|
|
2777
|
+
* @param mutator An optional boolean indicating the listener
|
|
2778
|
+
* mutates Store data.
|
|
2779
|
+
* @param storeOrStoreId The Store to use, or its Id.
|
|
2780
|
+
* @category Hook
|
|
2781
|
+
* @since v8.1.0
|
|
2782
|
+
*/
|
|
2783
|
+
export function useRowListener(
|
|
2784
|
+
tableId: MaybeGetter<IdOrNull>,
|
|
2785
|
+
rowId: MaybeGetter<IdOrNull>,
|
|
2786
|
+
listener: RowListener,
|
|
2787
|
+
mutator?: boolean,
|
|
2788
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
2789
|
+
): void;
|
|
2790
|
+
|
|
2791
|
+
/**
|
|
2792
|
+
* The useCellIdsListener hook registers a listener that is
|
|
2793
|
+
* called whenever the Cell Ids in a Row change.
|
|
2794
|
+
* @param tableId The Id of the Table to listen to, or `null`
|
|
2795
|
+
* to listen to any Table.
|
|
2796
|
+
* @param rowId The Id of the Row to listen to, or `null` to
|
|
2797
|
+
* listen to any Row.
|
|
2798
|
+
* @param listener The function to call when Cell Ids change.
|
|
2799
|
+
* @param mutator An optional boolean indicating the listener
|
|
2800
|
+
* mutates Store data.
|
|
2801
|
+
* @param storeOrStoreId The Store to use, or its Id.
|
|
2802
|
+
* @category Hook
|
|
2803
|
+
* @since v8.1.0
|
|
2804
|
+
*/
|
|
2805
|
+
export function useCellIdsListener(
|
|
2806
|
+
tableId: MaybeGetter<IdOrNull>,
|
|
2807
|
+
rowId: MaybeGetter<IdOrNull>,
|
|
2808
|
+
listener: CellIdsListener,
|
|
2809
|
+
mutator?: boolean,
|
|
2810
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
2811
|
+
): void;
|
|
2812
|
+
|
|
2813
|
+
/**
|
|
2814
|
+
* The useHasCellListener hook registers a listener that is
|
|
2815
|
+
* called whenever a specified Cell is added to or removed from
|
|
2816
|
+
* a Row.
|
|
2817
|
+
* @param tableId The Id of the Table to listen to, or `null`
|
|
2818
|
+
* to listen to any Table.
|
|
2819
|
+
* @param rowId The Id of the Row to listen to, or `null` to
|
|
2820
|
+
* listen to any Row.
|
|
2821
|
+
* @param cellId The Id of the Cell to listen to, or `null` to
|
|
2822
|
+
* listen to any Cell.
|
|
2823
|
+
* @param listener The function to call when the Cell changes.
|
|
2824
|
+
* @param mutator An optional boolean indicating the listener
|
|
2825
|
+
* mutates Store data.
|
|
2826
|
+
* @param storeOrStoreId The Store to use, or its Id.
|
|
2827
|
+
* @category Hook
|
|
2828
|
+
* @since v8.1.0
|
|
2829
|
+
*/
|
|
2830
|
+
export function useHasCellListener(
|
|
2831
|
+
tableId: MaybeGetter<IdOrNull>,
|
|
2832
|
+
rowId: MaybeGetter<IdOrNull>,
|
|
2833
|
+
cellId: MaybeGetter<IdOrNull>,
|
|
2834
|
+
listener: HasCellListener,
|
|
2835
|
+
mutator?: boolean,
|
|
2836
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
2837
|
+
): void;
|
|
2838
|
+
|
|
2839
|
+
/**
|
|
2840
|
+
* The useCellListener hook registers a listener that is called
|
|
2841
|
+
* whenever the value of a specified Cell changes.
|
|
2842
|
+
* @param tableId The Id of the Table to listen to, or `null`
|
|
2843
|
+
* to listen to any Table.
|
|
2844
|
+
* @param rowId The Id of the Row to listen to, or `null` to
|
|
2845
|
+
* listen to any Row.
|
|
2846
|
+
* @param cellId The Id of the Cell to listen to, or `null` to
|
|
2847
|
+
* listen to any Cell.
|
|
2848
|
+
* @param listener The function to call when the Cell changes.
|
|
2849
|
+
* @param mutator An optional boolean indicating the listener
|
|
2850
|
+
* mutates Store data.
|
|
2851
|
+
* @param storeOrStoreId The Store to use, or its Id.
|
|
2852
|
+
* @category Hook
|
|
2853
|
+
* @since v8.1.0
|
|
2854
|
+
*/
|
|
2855
|
+
export function useCellListener(
|
|
2856
|
+
tableId: MaybeGetter<IdOrNull>,
|
|
2857
|
+
rowId: MaybeGetter<IdOrNull>,
|
|
2858
|
+
cellId: MaybeGetter<IdOrNull>,
|
|
2859
|
+
listener: CellListener,
|
|
2860
|
+
mutator?: boolean,
|
|
2861
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
2862
|
+
): void;
|
|
2863
|
+
|
|
2864
|
+
/**
|
|
2865
|
+
* The useHasValuesListener hook registers a listener that is
|
|
2866
|
+
* called whenever any Values are added to or removed from the
|
|
2867
|
+
* Store.
|
|
2868
|
+
* @param listener The function to call when value presence
|
|
2869
|
+
* changes.
|
|
2870
|
+
* @param mutator An optional boolean indicating the listener
|
|
2871
|
+
* mutates Store data.
|
|
2872
|
+
* @param storeOrStoreId The Store to use, or its Id.
|
|
2873
|
+
* @category Hook
|
|
2874
|
+
* @since v8.1.0
|
|
2875
|
+
*/
|
|
2876
|
+
export function useHasValuesListener(
|
|
2877
|
+
listener: HasValuesListener,
|
|
2878
|
+
mutator?: boolean,
|
|
2879
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
2880
|
+
): void;
|
|
2881
|
+
|
|
2882
|
+
/**
|
|
2883
|
+
* The useValuesListener hook registers a listener that is
|
|
2884
|
+
* called whenever any Values in the Store change.
|
|
2885
|
+
* @param listener The function to call when Values change.
|
|
2886
|
+
* @param mutator An optional boolean indicating the listener
|
|
2887
|
+
* mutates Store data.
|
|
2888
|
+
* @param storeOrStoreId The Store to use, or its Id.
|
|
2889
|
+
* @category Hook
|
|
2890
|
+
* @since v8.1.0
|
|
2891
|
+
*/
|
|
2892
|
+
export function useValuesListener(
|
|
2893
|
+
listener: ValuesListener,
|
|
2894
|
+
mutator?: boolean,
|
|
2895
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
2896
|
+
): void;
|
|
2897
|
+
|
|
2898
|
+
/**
|
|
2899
|
+
* The useValueIdsListener hook registers a listener that is
|
|
2900
|
+
* called whenever the Value Ids in the Store change.
|
|
2901
|
+
* @param listener The function to call when Value Ids change.
|
|
2902
|
+
* @param mutator An optional boolean indicating the listener
|
|
2903
|
+
* mutates Store data.
|
|
2904
|
+
* @param storeOrStoreId The Store to use, or its Id.
|
|
2905
|
+
* @category Hook
|
|
2906
|
+
* @since v8.1.0
|
|
2907
|
+
*/
|
|
2908
|
+
export function useValueIdsListener(
|
|
2909
|
+
listener: ValueIdsListener,
|
|
2910
|
+
mutator?: boolean,
|
|
2911
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
2912
|
+
): void;
|
|
2913
|
+
|
|
2914
|
+
/**
|
|
2915
|
+
* The useHasValueListener hook registers a listener that is
|
|
2916
|
+
* called whenever a specified Value is added to or removed
|
|
2917
|
+
* from the Store.
|
|
2918
|
+
* @param valueId The Id of the Value to listen to, or `null`
|
|
2919
|
+
* to listen to any Value.
|
|
2920
|
+
* @param listener The function to call when the Value changes.
|
|
2921
|
+
* @param mutator An optional boolean indicating the listener
|
|
2922
|
+
* mutates Store data.
|
|
2923
|
+
* @param storeOrStoreId The Store to use, or its Id.
|
|
2924
|
+
* @category Hook
|
|
2925
|
+
* @since v8.1.0
|
|
2926
|
+
*/
|
|
2927
|
+
export function useHasValueListener(
|
|
2928
|
+
valueId: MaybeGetter<IdOrNull>,
|
|
2929
|
+
listener: HasValueListener,
|
|
2930
|
+
mutator?: boolean,
|
|
2931
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
2932
|
+
): void;
|
|
2933
|
+
|
|
2934
|
+
/**
|
|
2935
|
+
* The useValueListener hook registers a listener that is
|
|
2936
|
+
* called whenever the value of a specified Value changes.
|
|
2937
|
+
* @param valueId The Id of the Value to listen to, or `null`
|
|
2938
|
+
* to listen to any Value.
|
|
2939
|
+
* @param listener The function to call when the Value changes.
|
|
2940
|
+
* @param mutator An optional boolean indicating the listener
|
|
2941
|
+
* mutates Store data.
|
|
2942
|
+
* @param storeOrStoreId The Store to use, or its Id.
|
|
2943
|
+
* @category Hook
|
|
2944
|
+
* @since v8.1.0
|
|
2945
|
+
*/
|
|
2946
|
+
export function useValueListener(
|
|
2947
|
+
valueId: MaybeGetter<IdOrNull>,
|
|
2948
|
+
listener: ValueListener,
|
|
2949
|
+
mutator?: boolean,
|
|
2950
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
2951
|
+
): void;
|
|
2952
|
+
|
|
2953
|
+
/**
|
|
2954
|
+
* The useStartTransactionListener hook registers a listener
|
|
2955
|
+
* that is called at the start of every Store transaction.
|
|
2956
|
+
* @param listener The function to call at transaction start.
|
|
2957
|
+
* @param storeOrStoreId The Store to use, or its Id.
|
|
2958
|
+
* @category Hook
|
|
2959
|
+
* @since v8.1.0
|
|
2960
|
+
*/
|
|
2961
|
+
export function useStartTransactionListener(
|
|
2962
|
+
listener: TransactionListener,
|
|
2963
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
2964
|
+
): void;
|
|
2965
|
+
|
|
2966
|
+
/**
|
|
2967
|
+
* The useWillFinishTransactionListener hook registers a
|
|
2968
|
+
* listener called just before a Store transaction completes.
|
|
2969
|
+
* @param listener The function to call before transaction end.
|
|
2970
|
+
* @param storeOrStoreId The Store to use, or its Id.
|
|
2971
|
+
* @category Hook
|
|
2972
|
+
* @since v8.1.0
|
|
2973
|
+
*/
|
|
2974
|
+
export function useWillFinishTransactionListener(
|
|
2975
|
+
listener: TransactionListener,
|
|
2976
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
2977
|
+
): void;
|
|
2978
|
+
|
|
2979
|
+
/**
|
|
2980
|
+
* The useDidFinishTransactionListener hook registers a
|
|
2981
|
+
* listener called just after a Store transaction completes.
|
|
2982
|
+
* @param listener The function to call after transaction end.
|
|
2983
|
+
* @param storeOrStoreId The Store to use, or its Id.
|
|
2984
|
+
* @category Hook
|
|
2985
|
+
* @since v8.1.0
|
|
2986
|
+
*/
|
|
2987
|
+
export function useDidFinishTransactionListener(
|
|
2988
|
+
listener: TransactionListener,
|
|
2989
|
+
storeOrStoreId?: MaybeGetter<StoreOrStoreId | undefined>,
|
|
2990
|
+
): void;
|
|
2991
|
+
|
|
2992
|
+
/**
|
|
2993
|
+
* The useMetricListener hook registers a listener that is
|
|
2994
|
+
* called whenever a specified Metric value changes.
|
|
2995
|
+
* @param metricId The Id of the Metric to listen to, or
|
|
2996
|
+
* `null` to listen to any Metric.
|
|
2997
|
+
* @param listener The function to call when the Metric
|
|
2998
|
+
* changes.
|
|
2999
|
+
* @param metricsOrMetricsId The Metrics object to use, or
|
|
3000
|
+
* its Id.
|
|
3001
|
+
* @category Hook
|
|
3002
|
+
* @since v8.1.0
|
|
3003
|
+
*/
|
|
3004
|
+
export function useMetricListener(
|
|
3005
|
+
metricId: MaybeGetter<IdOrNull>,
|
|
3006
|
+
listener: MetricListener,
|
|
3007
|
+
metricsOrMetricsId?: MaybeGetter<MetricsOrMetricsId | undefined>,
|
|
3008
|
+
): void;
|
|
3009
|
+
|
|
3010
|
+
/**
|
|
3011
|
+
* The useSliceIdsListener hook registers a listener that is
|
|
3012
|
+
* called whenever the Slice Ids in an Index change.
|
|
3013
|
+
* @param indexId The Id of the Index to listen to, or `null`
|
|
3014
|
+
* to listen to any Index.
|
|
3015
|
+
* @param listener The function to call when Slice Ids change.
|
|
3016
|
+
* @param indexesOrIndexesId The Indexes object to use, or its
|
|
3017
|
+
* Id.
|
|
3018
|
+
* @category Hook
|
|
3019
|
+
* @since v8.1.0
|
|
3020
|
+
*/
|
|
3021
|
+
export function useSliceIdsListener(
|
|
3022
|
+
indexId: MaybeGetter<IdOrNull>,
|
|
3023
|
+
listener: SliceIdsListener,
|
|
3024
|
+
indexesOrIndexesId?: MaybeGetter<IndexesOrIndexesId | undefined>,
|
|
3025
|
+
): void;
|
|
3026
|
+
|
|
3027
|
+
/**
|
|
3028
|
+
* The useSliceRowIdsListener hook registers a listener that
|
|
3029
|
+
* is called whenever the Row Ids in a Slice change.
|
|
3030
|
+
* @param indexId The Id of the Index to listen to, or `null`
|
|
3031
|
+
* to listen to any Index.
|
|
3032
|
+
* @param sliceId The Id of the Slice to listen to, or `null`
|
|
3033
|
+
* to listen to any Slice.
|
|
3034
|
+
* @param listener The function to call when Slice Row Ids
|
|
3035
|
+
* change.
|
|
3036
|
+
* @param indexesOrIndexesId The Indexes object to use, or its
|
|
3037
|
+
* Id.
|
|
3038
|
+
* @category Hook
|
|
3039
|
+
* @since v8.1.0
|
|
3040
|
+
*/
|
|
3041
|
+
export function useSliceRowIdsListener(
|
|
3042
|
+
indexId: MaybeGetter<IdOrNull>,
|
|
3043
|
+
sliceId: MaybeGetter<IdOrNull>,
|
|
3044
|
+
listener: SliceRowIdsListener,
|
|
3045
|
+
indexesOrIndexesId?: MaybeGetter<IndexesOrIndexesId | undefined>,
|
|
3046
|
+
): void;
|
|
3047
|
+
|
|
3048
|
+
/**
|
|
3049
|
+
* The useRemoteRowIdListener hook registers a listener that
|
|
3050
|
+
* is called whenever the remote Row Id for a local Row
|
|
3051
|
+
* changes.
|
|
3052
|
+
* @param relationshipId The Id of the Relationship, or `null`
|
|
3053
|
+
* to listen to any Relationship.
|
|
3054
|
+
* @param localRowId The Id of the local Row, or `null` to
|
|
3055
|
+
* listen to any local Row.
|
|
3056
|
+
* @param listener The function to call when the remote Row Id
|
|
3057
|
+
* changes.
|
|
3058
|
+
* @param relationshipsOrRelationshipsId The Relationships
|
|
3059
|
+
* object to use, or its Id.
|
|
3060
|
+
* @category Hook
|
|
3061
|
+
* @since v8.1.0
|
|
3062
|
+
*/
|
|
3063
|
+
export function useRemoteRowIdListener(
|
|
3064
|
+
relationshipId: MaybeGetter<IdOrNull>,
|
|
3065
|
+
localRowId: MaybeGetter<IdOrNull>,
|
|
3066
|
+
listener: RemoteRowIdListener,
|
|
3067
|
+
relationshipsOrRelationshipsId?: MaybeGetter<
|
|
3068
|
+
RelationshipsOrRelationshipsId | undefined
|
|
3069
|
+
>,
|
|
3070
|
+
): void;
|
|
3071
|
+
|
|
3072
|
+
/**
|
|
3073
|
+
* The useLocalRowIdsListener hook registers a listener that
|
|
3074
|
+
* is called whenever the local Row Ids for a remote Row
|
|
3075
|
+
* change.
|
|
3076
|
+
* @param relationshipId The Id of the Relationship, or `null`
|
|
3077
|
+
* to listen to any Relationship.
|
|
3078
|
+
* @param remoteRowId The Id of the remote Row, or `null` to
|
|
3079
|
+
* listen to any remote Row.
|
|
3080
|
+
* @param listener The function to call when local Row Ids
|
|
3081
|
+
* change.
|
|
3082
|
+
* @param relationshipsOrRelationshipsId The Relationships
|
|
3083
|
+
* object to use, or its Id.
|
|
3084
|
+
* @category Hook
|
|
3085
|
+
* @since v8.1.0
|
|
3086
|
+
*/
|
|
3087
|
+
export function useLocalRowIdsListener(
|
|
3088
|
+
relationshipId: MaybeGetter<IdOrNull>,
|
|
3089
|
+
remoteRowId: MaybeGetter<IdOrNull>,
|
|
3090
|
+
listener: LocalRowIdsListener,
|
|
3091
|
+
relationshipsOrRelationshipsId?: MaybeGetter<
|
|
3092
|
+
RelationshipsOrRelationshipsId | undefined
|
|
3093
|
+
>,
|
|
3094
|
+
): void;
|
|
3095
|
+
|
|
3096
|
+
/**
|
|
3097
|
+
* The useLinkedRowIdsListener hook registers a listener that
|
|
3098
|
+
* is called whenever the linked Row Ids for a first Row
|
|
3099
|
+
* change.
|
|
3100
|
+
* @param relationshipId The Id of the Relationship.
|
|
3101
|
+
* @param firstRowId The Id of the first Row.
|
|
3102
|
+
* @param listener The function to call when linked Row Ids
|
|
3103
|
+
* change.
|
|
3104
|
+
* @param relationshipsOrRelationshipsId The Relationships
|
|
3105
|
+
* object to use, or its Id.
|
|
3106
|
+
* @category Hook
|
|
3107
|
+
* @since v8.1.0
|
|
3108
|
+
*/
|
|
3109
|
+
export function useLinkedRowIdsListener(
|
|
3110
|
+
relationshipId: MaybeGetter<Id>,
|
|
3111
|
+
firstRowId: MaybeGetter<Id>,
|
|
3112
|
+
listener: LinkedRowIdsListener,
|
|
3113
|
+
relationshipsOrRelationshipsId?: MaybeGetter<
|
|
3114
|
+
RelationshipsOrRelationshipsId | undefined
|
|
3115
|
+
>,
|
|
3116
|
+
): void;
|
|
3117
|
+
|
|
3118
|
+
/**
|
|
3119
|
+
* The useResultTableListener hook registers a listener that
|
|
3120
|
+
* is called whenever the result Table of a query changes.
|
|
3121
|
+
* @param queryId The Id of the query to listen to, or `null`
|
|
3122
|
+
* to listen to any query.
|
|
3123
|
+
* @param listener The function to call when the result Table
|
|
3124
|
+
* changes.
|
|
3125
|
+
* @param queriesOrQueriesId The Queries object to use, or its
|
|
3126
|
+
* Id.
|
|
3127
|
+
* @category Hook
|
|
3128
|
+
* @since v8.1.0
|
|
3129
|
+
*/
|
|
3130
|
+
export function useResultTableListener(
|
|
3131
|
+
queryId: MaybeGetter<IdOrNull>,
|
|
3132
|
+
listener: ResultTableListener,
|
|
3133
|
+
queriesOrQueriesId?: MaybeGetter<QueriesOrQueriesId | undefined>,
|
|
3134
|
+
): void;
|
|
3135
|
+
|
|
3136
|
+
/**
|
|
3137
|
+
* The useResultTableCellIdsListener hook registers a listener
|
|
3138
|
+
* that is called whenever the Cell Ids across a result Table
|
|
3139
|
+
* change.
|
|
3140
|
+
* @param queryId The Id of the query to listen to, or `null`
|
|
3141
|
+
* to listen to any query.
|
|
3142
|
+
* @param listener The function to call when Cell Ids change.
|
|
3143
|
+
* @param queriesOrQueriesId The Queries object to use, or its
|
|
3144
|
+
* Id.
|
|
3145
|
+
* @category Hook
|
|
3146
|
+
* @since v8.1.0
|
|
3147
|
+
*/
|
|
3148
|
+
export function useResultTableCellIdsListener(
|
|
3149
|
+
queryId: MaybeGetter<IdOrNull>,
|
|
3150
|
+
listener: ResultTableCellIdsListener,
|
|
3151
|
+
queriesOrQueriesId?: MaybeGetter<QueriesOrQueriesId | undefined>,
|
|
3152
|
+
): void;
|
|
3153
|
+
|
|
3154
|
+
/**
|
|
3155
|
+
* The useResultRowCountListener hook registers a listener that
|
|
3156
|
+
* is called whenever the count of result Rows changes.
|
|
3157
|
+
* @param queryId The Id of the query to listen to, or `null`
|
|
3158
|
+
* to listen to any query.
|
|
3159
|
+
* @param listener The function to call when the count changes.
|
|
3160
|
+
* @param queriesOrQueriesId The Queries object to use, or its
|
|
3161
|
+
* Id.
|
|
3162
|
+
* @category Hook
|
|
3163
|
+
* @since v8.1.0
|
|
3164
|
+
*/
|
|
3165
|
+
export function useResultRowCountListener(
|
|
3166
|
+
queryId: MaybeGetter<IdOrNull>,
|
|
3167
|
+
listener: ResultRowCountListener,
|
|
3168
|
+
queriesOrQueriesId?: MaybeGetter<QueriesOrQueriesId | undefined>,
|
|
3169
|
+
): void;
|
|
3170
|
+
|
|
3171
|
+
/**
|
|
3172
|
+
* The useResultRowIdsListener hook registers a listener that
|
|
3173
|
+
* is called whenever the result Row Ids of a query change.
|
|
3174
|
+
* @param queryId The Id of the query to listen to, or `null`
|
|
3175
|
+
* to listen to any query.
|
|
3176
|
+
* @param listener The function to call when result Row Ids
|
|
3177
|
+
* change.
|
|
3178
|
+
* @param queriesOrQueriesId The Queries object to use, or its
|
|
3179
|
+
* Id.
|
|
3180
|
+
* @category Hook
|
|
3181
|
+
* @since v8.1.0
|
|
3182
|
+
*/
|
|
3183
|
+
export function useResultRowIdsListener(
|
|
3184
|
+
queryId: MaybeGetter<IdOrNull>,
|
|
3185
|
+
listener: ResultRowIdsListener,
|
|
3186
|
+
queriesOrQueriesId?: MaybeGetter<QueriesOrQueriesId | undefined>,
|
|
3187
|
+
): void;
|
|
3188
|
+
|
|
3189
|
+
/**
|
|
3190
|
+
* The useResultSortedRowIdsListener hook registers a listener
|
|
3191
|
+
* that is called whenever the sorted result Row Ids change.
|
|
3192
|
+
* @param queryId The Id of the query to listen to.
|
|
3193
|
+
* @param cellId The Id of the Cell to sort by, or `undefined`
|
|
3194
|
+
* for default order.
|
|
3195
|
+
* @param descending Whether to sort descending.
|
|
3196
|
+
* @param offset The index of the first Row to include.
|
|
3197
|
+
* @param limit The maximum number of Rows to include, or
|
|
3198
|
+
* `undefined` for all.
|
|
3199
|
+
* @param listener The function to call when sorted Row Ids
|
|
3200
|
+
* change.
|
|
3201
|
+
* @param queriesOrQueriesId The Queries object to use, or its
|
|
3202
|
+
* Id.
|
|
3203
|
+
* @category Hook
|
|
3204
|
+
* @since v8.1.0
|
|
3205
|
+
*/
|
|
3206
|
+
export function useResultSortedRowIdsListener(
|
|
3207
|
+
queryId: MaybeGetter<Id>,
|
|
3208
|
+
cellId: MaybeGetter<Id | undefined>,
|
|
3209
|
+
descending: MaybeGetter<boolean>,
|
|
3210
|
+
offset: MaybeGetter<number>,
|
|
3211
|
+
limit: MaybeGetter<number | undefined>,
|
|
3212
|
+
listener: ResultSortedRowIdsListener,
|
|
3213
|
+
queriesOrQueriesId?: MaybeGetter<QueriesOrQueriesId | undefined>,
|
|
3214
|
+
): void;
|
|
3215
|
+
|
|
3216
|
+
/**
|
|
3217
|
+
* The useResultRowListener hook registers a listener that is
|
|
3218
|
+
* called whenever a result Row changes.
|
|
3219
|
+
* @param queryId The Id of the query to listen to, or `null`
|
|
3220
|
+
* to listen to any query.
|
|
3221
|
+
* @param rowId The Id of the result Row to listen to, or
|
|
3222
|
+
* `null` to listen to any result Row.
|
|
3223
|
+
* @param listener The function to call when the result Row
|
|
3224
|
+
* changes.
|
|
3225
|
+
* @param queriesOrQueriesId The Queries object to use, or its
|
|
3226
|
+
* Id.
|
|
3227
|
+
* @category Hook
|
|
3228
|
+
* @since v8.1.0
|
|
3229
|
+
*/
|
|
3230
|
+
export function useResultRowListener(
|
|
3231
|
+
queryId: MaybeGetter<IdOrNull>,
|
|
3232
|
+
rowId: MaybeGetter<IdOrNull>,
|
|
3233
|
+
listener: ResultRowListener,
|
|
3234
|
+
queriesOrQueriesId?: MaybeGetter<QueriesOrQueriesId | undefined>,
|
|
3235
|
+
): void;
|
|
3236
|
+
|
|
3237
|
+
/**
|
|
3238
|
+
* The useResultCellIdsListener hook registers a listener that
|
|
3239
|
+
* is called whenever the Cell Ids in a result Row change.
|
|
3240
|
+
* @param queryId The Id of the query to listen to, or `null`
|
|
3241
|
+
* to listen to any query.
|
|
3242
|
+
* @param rowId The Id of the result Row to listen to, or
|
|
3243
|
+
* `null` to listen to any result Row.
|
|
3244
|
+
* @param listener The function to call when Cell Ids change.
|
|
3245
|
+
* @param queriesOrQueriesId The Queries object to use, or its
|
|
3246
|
+
* Id.
|
|
3247
|
+
* @category Hook
|
|
3248
|
+
* @since v8.1.0
|
|
3249
|
+
*/
|
|
3250
|
+
export function useResultCellIdsListener(
|
|
3251
|
+
queryId: MaybeGetter<IdOrNull>,
|
|
3252
|
+
rowId: MaybeGetter<IdOrNull>,
|
|
3253
|
+
listener: ResultCellIdsListener,
|
|
3254
|
+
queriesOrQueriesId?: MaybeGetter<QueriesOrQueriesId | undefined>,
|
|
3255
|
+
): void;
|
|
3256
|
+
|
|
3257
|
+
/**
|
|
3258
|
+
* The useResultCellListener hook registers a listener that is
|
|
3259
|
+
* called whenever the value of a result Cell changes.
|
|
3260
|
+
* @param queryId The Id of the query to listen to, or `null`
|
|
3261
|
+
* to listen to any query.
|
|
3262
|
+
* @param rowId The Id of the result Row to listen to, or
|
|
3263
|
+
* `null` to listen to any result Row.
|
|
3264
|
+
* @param cellId The Id of the result Cell to listen to, or
|
|
3265
|
+
* `null` to listen to any result Cell.
|
|
3266
|
+
* @param listener The function to call when the result Cell
|
|
3267
|
+
* changes.
|
|
3268
|
+
* @param queriesOrQueriesId The Queries object to use, or its
|
|
3269
|
+
* Id.
|
|
3270
|
+
* @category Hook
|
|
3271
|
+
* @since v8.1.0
|
|
3272
|
+
*/
|
|
3273
|
+
export function useResultCellListener(
|
|
3274
|
+
queryId: MaybeGetter<IdOrNull>,
|
|
3275
|
+
rowId: MaybeGetter<IdOrNull>,
|
|
3276
|
+
cellId: MaybeGetter<IdOrNull>,
|
|
3277
|
+
listener: ResultCellListener,
|
|
3278
|
+
queriesOrQueriesId?: MaybeGetter<QueriesOrQueriesId | undefined>,
|
|
3279
|
+
): void;
|
|
3280
|
+
|
|
3281
|
+
/**
|
|
3282
|
+
* The useParamValuesListener hook registers a listener that
|
|
3283
|
+
* is called whenever the parameter values for a query change.
|
|
3284
|
+
* @param queryId The Id of the query to listen to, or `null`
|
|
3285
|
+
* to listen to any query.
|
|
3286
|
+
* @param listener The function to call when parameter values
|
|
3287
|
+
* change.
|
|
3288
|
+
* @param queriesOrQueriesId The Queries object to use, or its
|
|
3289
|
+
* Id.
|
|
3290
|
+
* @category Hook
|
|
3291
|
+
* @since v8.1.0
|
|
3292
|
+
*/
|
|
3293
|
+
export function useParamValuesListener(
|
|
3294
|
+
queryId: MaybeGetter<IdOrNull>,
|
|
3295
|
+
listener: ParamValuesListener,
|
|
3296
|
+
queriesOrQueriesId?: MaybeGetter<QueriesOrQueriesId | undefined>,
|
|
3297
|
+
): void;
|
|
3298
|
+
|
|
3299
|
+
/**
|
|
3300
|
+
* The useParamValueListener hook registers a listener that is
|
|
3301
|
+
* called whenever a specific parameter value for a query
|
|
3302
|
+
* changes.
|
|
3303
|
+
* @param queryId The Id of the query to listen to, or `null`
|
|
3304
|
+
* to listen to any query.
|
|
3305
|
+
* @param paramId The Id of the parameter to listen to, or
|
|
3306
|
+
* `null` to listen to any parameter.
|
|
3307
|
+
* @param listener The function to call when the parameter
|
|
3308
|
+
* value changes.
|
|
3309
|
+
* @param queriesOrQueriesId The Queries object to use, or its
|
|
3310
|
+
* Id.
|
|
3311
|
+
* @category Hook
|
|
3312
|
+
* @since v8.1.0
|
|
3313
|
+
*/
|
|
3314
|
+
export function useParamValueListener(
|
|
3315
|
+
queryId: MaybeGetter<IdOrNull>,
|
|
3316
|
+
paramId: MaybeGetter<IdOrNull>,
|
|
3317
|
+
listener: ParamValueListener,
|
|
3318
|
+
queriesOrQueriesId?: MaybeGetter<QueriesOrQueriesId | undefined>,
|
|
3319
|
+
): void;
|
|
3320
|
+
|
|
3321
|
+
/**
|
|
3322
|
+
* The useCheckpointIdsListener hook registers a listener that
|
|
3323
|
+
* is called whenever the Checkpoint Ids change.
|
|
3324
|
+
* @param listener The function to call when Checkpoint Ids
|
|
3325
|
+
* change.
|
|
3326
|
+
* @param checkpointsOrCheckpointsId The Checkpoints object to
|
|
3327
|
+
* use, or its Id.
|
|
3328
|
+
* @category Hook
|
|
3329
|
+
* @since v8.1.0
|
|
3330
|
+
*/
|
|
3331
|
+
export function useCheckpointIdsListener(
|
|
3332
|
+
listener: CheckpointIdsListener,
|
|
3333
|
+
checkpointsOrCheckpointsId?: MaybeGetter<
|
|
3334
|
+
CheckpointsOrCheckpointsId | undefined
|
|
3335
|
+
>,
|
|
3336
|
+
): void;
|
|
3337
|
+
|
|
3338
|
+
/**
|
|
3339
|
+
* The useCheckpointListener hook registers a listener that is
|
|
3340
|
+
* called whenever the label of a specified Checkpoint changes.
|
|
3341
|
+
* @param checkpointId The Id of the Checkpoint to listen to,
|
|
3342
|
+
* or `null` to listen to any Checkpoint.
|
|
3343
|
+
* @param listener The function to call when the Checkpoint
|
|
3344
|
+
* label changes.
|
|
3345
|
+
* @param checkpointsOrCheckpointsId The Checkpoints object to
|
|
3346
|
+
* use, or its Id.
|
|
3347
|
+
* @category Hook
|
|
3348
|
+
* @since v8.1.0
|
|
3349
|
+
*/
|
|
3350
|
+
export function useCheckpointListener(
|
|
3351
|
+
checkpointId: MaybeGetter<IdOrNull>,
|
|
3352
|
+
listener: CheckpointListener,
|
|
3353
|
+
checkpointsOrCheckpointsId?: MaybeGetter<
|
|
3354
|
+
CheckpointsOrCheckpointsId | undefined
|
|
3355
|
+
>,
|
|
3356
|
+
): void;
|
|
3357
|
+
|
|
3358
|
+
/**
|
|
3359
|
+
* The usePersisterStatusListener hook registers a listener
|
|
3360
|
+
* that is called whenever the status of a Persister changes.
|
|
3361
|
+
* @param listener The function to call when the status
|
|
3362
|
+
* changes.
|
|
3363
|
+
* @param persisterOrPersisterId The Persister to use, or its
|
|
3364
|
+
* Id.
|
|
3365
|
+
* @category Hook
|
|
3366
|
+
* @since v8.1.0
|
|
3367
|
+
*/
|
|
3368
|
+
export function usePersisterStatusListener(
|
|
3369
|
+
listener: StatusListener,
|
|
3370
|
+
persisterOrPersisterId?: MaybeGetter<PersisterOrPersisterId | undefined>,
|
|
3371
|
+
): void;
|
|
3372
|
+
|
|
3373
|
+
/**
|
|
3374
|
+
* The useSynchronizerStatusListener hook registers a listener
|
|
3375
|
+
* that is called whenever the status of a Synchronizer
|
|
3376
|
+
* changes.
|
|
3377
|
+
* @param listener The function to call when the status
|
|
3378
|
+
* changes.
|
|
3379
|
+
* @param synchronizerOrSynchronizerId The Synchronizer to use,
|
|
3380
|
+
* or its Id.
|
|
3381
|
+
* @category Hook
|
|
3382
|
+
* @since v8.1.0
|
|
3383
|
+
*/
|
|
3384
|
+
export function useSynchronizerStatusListener(
|
|
3385
|
+
listener: StatusListener,
|
|
3386
|
+
synchronizerOrSynchronizerId?: MaybeGetter<
|
|
3387
|
+
SynchronizerOrSynchronizerId | undefined
|
|
3388
|
+
>,
|
|
3389
|
+
): void;
|
|
3390
|
+
|
|
3391
|
+
/**
|
|
3392
|
+
* The provideStore function registers a Store with a given Id into the current
|
|
3393
|
+
* Provider context, making it available to all descendant components.
|
|
3394
|
+
*
|
|
3395
|
+
* This function must be called inside a Svelte component's `<script>` block
|
|
3396
|
+
* that is a descendant of a Provider component.
|
|
3397
|
+
* @param storeId The Id to register the Store under.
|
|
3398
|
+
* @param store The Store to register.
|
|
3399
|
+
* @category Provider
|
|
3400
|
+
* @since v8.1.0
|
|
3401
|
+
*/
|
|
3402
|
+
export function provideStore(storeId: Id, store: Store): void;
|
|
3403
|
+
|
|
3404
|
+
/**
|
|
3405
|
+
* The provideMetrics function registers a Metrics object with a given Id into
|
|
3406
|
+
* the current Provider context.
|
|
3407
|
+
* @param metricsId The Id to register the Metrics object under.
|
|
3408
|
+
* @param metrics The Metrics object to register.
|
|
3409
|
+
* @category Provider
|
|
3410
|
+
* @since v8.1.0
|
|
3411
|
+
*/
|
|
3412
|
+
export function provideMetrics(metricsId: Id, metrics: Metrics): void;
|
|
3413
|
+
|
|
3414
|
+
/**
|
|
3415
|
+
* The provideIndexes function registers an Indexes object with a given Id into
|
|
3416
|
+
* the current Provider context.
|
|
3417
|
+
* @param indexesId The Id to register the Indexes object under.
|
|
3418
|
+
* @param indexes The Indexes object to register.
|
|
3419
|
+
* @category Provider
|
|
3420
|
+
* @since v8.1.0
|
|
3421
|
+
*/
|
|
3422
|
+
export function provideIndexes(indexesId: Id, indexes: Indexes): void;
|
|
3423
|
+
|
|
3424
|
+
/**
|
|
3425
|
+
* The provideRelationships function registers a Relationships object with a
|
|
3426
|
+
* given Id into the current Provider context.
|
|
3427
|
+
* @param relationshipsId The Id to register the Relationships object under.
|
|
3428
|
+
* @param relationships The Relationships object to register.
|
|
3429
|
+
* @category Provider
|
|
3430
|
+
* @since v8.1.0
|
|
3431
|
+
*/
|
|
3432
|
+
export function provideRelationships(
|
|
3433
|
+
relationshipsId: Id,
|
|
3434
|
+
relationships: Relationships,
|
|
3435
|
+
): void;
|
|
3436
|
+
|
|
3437
|
+
/**
|
|
3438
|
+
* The provideQueries function registers a Queries object with a given Id into
|
|
3439
|
+
* the current Provider context.
|
|
3440
|
+
* @param queriesId The Id to register the Queries object under.
|
|
3441
|
+
* @param queries The Queries object to register.
|
|
3442
|
+
* @category Provider
|
|
3443
|
+
* @since v8.1.0
|
|
3444
|
+
*/
|
|
3445
|
+
export function provideQueries(queriesId: Id, queries: Queries): void;
|
|
3446
|
+
|
|
3447
|
+
/**
|
|
3448
|
+
* The provideCheckpoints function registers a Checkpoints object with a given
|
|
3449
|
+
* Id into the current Provider context.
|
|
3450
|
+
* @param checkpointsId The Id to register the Checkpoints object under.
|
|
3451
|
+
* @param checkpoints The Checkpoints object to register.
|
|
3452
|
+
* @category Provider
|
|
3453
|
+
* @since v8.1.0
|
|
3454
|
+
*/
|
|
3455
|
+
export function provideCheckpoints(
|
|
3456
|
+
checkpointsId: Id,
|
|
3457
|
+
checkpoints: Checkpoints,
|
|
3458
|
+
): void;
|
|
3459
|
+
|
|
3460
|
+
/**
|
|
3461
|
+
* The providePersister function registers a Persister with a given Id into the
|
|
3462
|
+
* current Provider context.
|
|
3463
|
+
* @param persisterId The Id to register the Persister under.
|
|
3464
|
+
* @param persister The Persister to register.
|
|
3465
|
+
* @category Provider
|
|
3466
|
+
* @since v8.1.0
|
|
3467
|
+
*/
|
|
3468
|
+
export function providePersister(
|
|
3469
|
+
persisterId: Id,
|
|
3470
|
+
persister: AnyPersister,
|
|
3471
|
+
): void;
|
|
3472
|
+
|
|
3473
|
+
/**
|
|
3474
|
+
* The provideSynchronizer function registers a Synchronizer with a given Id
|
|
3475
|
+
* into the current Provider context.
|
|
3476
|
+
* @param synchronizerId The Id to register the Synchronizer under.
|
|
3477
|
+
* @param synchronizer The Synchronizer to register.
|
|
3478
|
+
* @category Provider
|
|
3479
|
+
* @since v8.1.0
|
|
3480
|
+
*/
|
|
3481
|
+
export function provideSynchronizer(
|
|
3482
|
+
synchronizerId: Id,
|
|
3483
|
+
synchronizer: Synchronizer,
|
|
3484
|
+
): void;
|