@comapeo/core-react 11.0.3 → 11.0.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/commonjs/hooks/invites.d.ts +12 -12
- package/dist/commonjs/hooks/invites.js +1 -4
- package/dist/esm/hooks/invites.d.ts +12 -12
- package/dist/esm/hooks/invites.js +1 -4
- package/docs/API.md +53 -53
- package/package.json +29 -30
|
@@ -73,44 +73,44 @@ export declare function useAcceptInvite(): Pick<import("@tanstack/react-query").
|
|
|
73
73
|
/**
|
|
74
74
|
* Reject an invite that has been received.
|
|
75
75
|
*/
|
|
76
|
-
export declare function useRejectInvite(): Pick<import("@tanstack/react-query").Override<import("@tanstack/react-query").MutationObserverIdleResult<
|
|
76
|
+
export declare function useRejectInvite(): Pick<import("@tanstack/react-query").Override<import("@tanstack/react-query").MutationObserverIdleResult<void, Error, {
|
|
77
77
|
inviteId: string;
|
|
78
78
|
}, unknown>, {
|
|
79
|
-
mutate: import("@tanstack/react-query").UseMutateFunction<
|
|
79
|
+
mutate: import("@tanstack/react-query").UseMutateFunction<void, Error, {
|
|
80
80
|
inviteId: string;
|
|
81
81
|
}, unknown>;
|
|
82
82
|
}> & {
|
|
83
|
-
mutateAsync: import("@tanstack/react-query").UseMutateAsyncFunction<
|
|
83
|
+
mutateAsync: import("@tanstack/react-query").UseMutateAsyncFunction<void, Error, {
|
|
84
84
|
inviteId: string;
|
|
85
85
|
}, unknown>;
|
|
86
|
-
}, "error" | "status" | "mutate" | "reset" | "mutateAsync"> | Pick<import("@tanstack/react-query").Override<import("@tanstack/react-query").MutationObserverLoadingResult<
|
|
86
|
+
}, "error" | "status" | "mutate" | "reset" | "mutateAsync"> | Pick<import("@tanstack/react-query").Override<import("@tanstack/react-query").MutationObserverLoadingResult<void, Error, {
|
|
87
87
|
inviteId: string;
|
|
88
88
|
}, unknown>, {
|
|
89
|
-
mutate: import("@tanstack/react-query").UseMutateFunction<
|
|
89
|
+
mutate: import("@tanstack/react-query").UseMutateFunction<void, Error, {
|
|
90
90
|
inviteId: string;
|
|
91
91
|
}, unknown>;
|
|
92
92
|
}> & {
|
|
93
|
-
mutateAsync: import("@tanstack/react-query").UseMutateAsyncFunction<
|
|
93
|
+
mutateAsync: import("@tanstack/react-query").UseMutateAsyncFunction<void, Error, {
|
|
94
94
|
inviteId: string;
|
|
95
95
|
}, unknown>;
|
|
96
|
-
}, "error" | "status" | "mutate" | "reset" | "mutateAsync"> | Pick<import("@tanstack/react-query").Override<import("@tanstack/react-query").MutationObserverErrorResult<
|
|
96
|
+
}, "error" | "status" | "mutate" | "reset" | "mutateAsync"> | Pick<import("@tanstack/react-query").Override<import("@tanstack/react-query").MutationObserverErrorResult<void, Error, {
|
|
97
97
|
inviteId: string;
|
|
98
98
|
}, unknown>, {
|
|
99
|
-
mutate: import("@tanstack/react-query").UseMutateFunction<
|
|
99
|
+
mutate: import("@tanstack/react-query").UseMutateFunction<void, Error, {
|
|
100
100
|
inviteId: string;
|
|
101
101
|
}, unknown>;
|
|
102
102
|
}> & {
|
|
103
|
-
mutateAsync: import("@tanstack/react-query").UseMutateAsyncFunction<
|
|
103
|
+
mutateAsync: import("@tanstack/react-query").UseMutateAsyncFunction<void, Error, {
|
|
104
104
|
inviteId: string;
|
|
105
105
|
}, unknown>;
|
|
106
|
-
}, "error" | "status" | "mutate" | "reset" | "mutateAsync"> | Pick<import("@tanstack/react-query").Override<import("@tanstack/react-query").MutationObserverSuccessResult<
|
|
106
|
+
}, "error" | "status" | "mutate" | "reset" | "mutateAsync"> | Pick<import("@tanstack/react-query").Override<import("@tanstack/react-query").MutationObserverSuccessResult<void, Error, {
|
|
107
107
|
inviteId: string;
|
|
108
108
|
}, unknown>, {
|
|
109
|
-
mutate: import("@tanstack/react-query").UseMutateFunction<
|
|
109
|
+
mutate: import("@tanstack/react-query").UseMutateFunction<void, Error, {
|
|
110
110
|
inviteId: string;
|
|
111
111
|
}, unknown>;
|
|
112
112
|
}> & {
|
|
113
|
-
mutateAsync: import("@tanstack/react-query").UseMutateAsyncFunction<
|
|
113
|
+
mutateAsync: import("@tanstack/react-query").UseMutateAsyncFunction<void, Error, {
|
|
114
114
|
inviteId: string;
|
|
115
115
|
}, unknown>;
|
|
116
116
|
}, "error" | "status" | "mutate" | "reset" | "mutateAsync">;
|
|
@@ -84,15 +84,12 @@ function useRejectInvite() {
|
|
|
84
84
|
return (0, react_query_js_1.filterMutationResult)((0, react_query_1.useMutation)({
|
|
85
85
|
...(0, react_query_js_1.baseMutationOptions)(),
|
|
86
86
|
mutationFn: async ({ inviteId }) => {
|
|
87
|
-
return clientApi.invite.
|
|
87
|
+
return clientApi.invite.reject({ inviteId });
|
|
88
88
|
},
|
|
89
89
|
onSuccess: () => {
|
|
90
90
|
queryClient.invalidateQueries({
|
|
91
91
|
queryKey: (0, react_query_js_1.getInvitesQueryKey)(),
|
|
92
92
|
});
|
|
93
|
-
queryClient.invalidateQueries({
|
|
94
|
-
queryKey: (0, react_query_js_1.getProjectsQueryKey)(),
|
|
95
|
-
});
|
|
96
93
|
},
|
|
97
94
|
}));
|
|
98
95
|
}
|
|
@@ -73,44 +73,44 @@ export declare function useAcceptInvite(): Pick<import("@tanstack/react-query").
|
|
|
73
73
|
/**
|
|
74
74
|
* Reject an invite that has been received.
|
|
75
75
|
*/
|
|
76
|
-
export declare function useRejectInvite(): Pick<import("@tanstack/react-query").Override<import("@tanstack/react-query").MutationObserverIdleResult<
|
|
76
|
+
export declare function useRejectInvite(): Pick<import("@tanstack/react-query").Override<import("@tanstack/react-query").MutationObserverIdleResult<void, Error, {
|
|
77
77
|
inviteId: string;
|
|
78
78
|
}, unknown>, {
|
|
79
|
-
mutate: import("@tanstack/react-query").UseMutateFunction<
|
|
79
|
+
mutate: import("@tanstack/react-query").UseMutateFunction<void, Error, {
|
|
80
80
|
inviteId: string;
|
|
81
81
|
}, unknown>;
|
|
82
82
|
}> & {
|
|
83
|
-
mutateAsync: import("@tanstack/react-query").UseMutateAsyncFunction<
|
|
83
|
+
mutateAsync: import("@tanstack/react-query").UseMutateAsyncFunction<void, Error, {
|
|
84
84
|
inviteId: string;
|
|
85
85
|
}, unknown>;
|
|
86
|
-
}, "error" | "status" | "mutate" | "reset" | "mutateAsync"> | Pick<import("@tanstack/react-query").Override<import("@tanstack/react-query").MutationObserverLoadingResult<
|
|
86
|
+
}, "error" | "status" | "mutate" | "reset" | "mutateAsync"> | Pick<import("@tanstack/react-query").Override<import("@tanstack/react-query").MutationObserverLoadingResult<void, Error, {
|
|
87
87
|
inviteId: string;
|
|
88
88
|
}, unknown>, {
|
|
89
|
-
mutate: import("@tanstack/react-query").UseMutateFunction<
|
|
89
|
+
mutate: import("@tanstack/react-query").UseMutateFunction<void, Error, {
|
|
90
90
|
inviteId: string;
|
|
91
91
|
}, unknown>;
|
|
92
92
|
}> & {
|
|
93
|
-
mutateAsync: import("@tanstack/react-query").UseMutateAsyncFunction<
|
|
93
|
+
mutateAsync: import("@tanstack/react-query").UseMutateAsyncFunction<void, Error, {
|
|
94
94
|
inviteId: string;
|
|
95
95
|
}, unknown>;
|
|
96
|
-
}, "error" | "status" | "mutate" | "reset" | "mutateAsync"> | Pick<import("@tanstack/react-query").Override<import("@tanstack/react-query").MutationObserverErrorResult<
|
|
96
|
+
}, "error" | "status" | "mutate" | "reset" | "mutateAsync"> | Pick<import("@tanstack/react-query").Override<import("@tanstack/react-query").MutationObserverErrorResult<void, Error, {
|
|
97
97
|
inviteId: string;
|
|
98
98
|
}, unknown>, {
|
|
99
|
-
mutate: import("@tanstack/react-query").UseMutateFunction<
|
|
99
|
+
mutate: import("@tanstack/react-query").UseMutateFunction<void, Error, {
|
|
100
100
|
inviteId: string;
|
|
101
101
|
}, unknown>;
|
|
102
102
|
}> & {
|
|
103
|
-
mutateAsync: import("@tanstack/react-query").UseMutateAsyncFunction<
|
|
103
|
+
mutateAsync: import("@tanstack/react-query").UseMutateAsyncFunction<void, Error, {
|
|
104
104
|
inviteId: string;
|
|
105
105
|
}, unknown>;
|
|
106
|
-
}, "error" | "status" | "mutate" | "reset" | "mutateAsync"> | Pick<import("@tanstack/react-query").Override<import("@tanstack/react-query").MutationObserverSuccessResult<
|
|
106
|
+
}, "error" | "status" | "mutate" | "reset" | "mutateAsync"> | Pick<import("@tanstack/react-query").Override<import("@tanstack/react-query").MutationObserverSuccessResult<void, Error, {
|
|
107
107
|
inviteId: string;
|
|
108
108
|
}, unknown>, {
|
|
109
|
-
mutate: import("@tanstack/react-query").UseMutateFunction<
|
|
109
|
+
mutate: import("@tanstack/react-query").UseMutateFunction<void, Error, {
|
|
110
110
|
inviteId: string;
|
|
111
111
|
}, unknown>;
|
|
112
112
|
}> & {
|
|
113
|
-
mutateAsync: import("@tanstack/react-query").UseMutateAsyncFunction<
|
|
113
|
+
mutateAsync: import("@tanstack/react-query").UseMutateAsyncFunction<void, Error, {
|
|
114
114
|
inviteId: string;
|
|
115
115
|
}, unknown>;
|
|
116
116
|
}, "error" | "status" | "mutate" | "reset" | "mutateAsync">;
|
|
@@ -76,15 +76,12 @@ export function useRejectInvite() {
|
|
|
76
76
|
return filterMutationResult(useMutation({
|
|
77
77
|
...baseMutationOptions(),
|
|
78
78
|
mutationFn: async ({ inviteId }) => {
|
|
79
|
-
return clientApi.invite.
|
|
79
|
+
return clientApi.invite.reject({ inviteId });
|
|
80
80
|
},
|
|
81
81
|
onSuccess: () => {
|
|
82
82
|
queryClient.invalidateQueries({
|
|
83
83
|
queryKey: getInvitesQueryKey(),
|
|
84
84
|
});
|
|
85
|
-
queryClient.invalidateQueries({
|
|
86
|
-
queryKey: getProjectsQueryKey(),
|
|
87
|
-
});
|
|
88
85
|
},
|
|
89
86
|
}));
|
|
90
87
|
}
|
package/docs/API.md
CHANGED
|
@@ -94,7 +94,7 @@ set up, it will throw an error.
|
|
|
94
94
|
|
|
95
95
|
| Function | Type |
|
|
96
96
|
| ---------- | ---------- |
|
|
97
|
-
| `useClientApi` | `() =>
|
|
97
|
+
| `useClientApi` | `() => ClientApi<Omit<MapeoManager, "getProject"> and { getProject: (projectPublicId: string) => Promise<ClientApi<MapeoProject>>; }>` |
|
|
98
98
|
|
|
99
99
|
Returns:
|
|
100
100
|
|
|
@@ -126,7 +126,7 @@ Retrieve info about the current device.
|
|
|
126
126
|
|
|
127
127
|
| Function | Type |
|
|
128
128
|
| ---------- | ---------- |
|
|
129
|
-
| `useOwnDeviceInfo` | `() => Pick<UseSuspenseQueryResult<
|
|
129
|
+
| `useOwnDeviceInfo` | `() => Pick<UseSuspenseQueryResult<{ deviceId: string; deviceType: "device_type_unspecified" or "mobile" or "tablet" or "desktop" or "selfHostedServer" or "UNRECOGNIZED"; } and Partial<DeviceInfoParam>>, "data" or ... 1 more ... or "isRefetching">` |
|
|
130
130
|
|
|
131
131
|
Examples:
|
|
132
132
|
|
|
@@ -143,7 +143,7 @@ Retrieve whether the current device is an archive device or not.
|
|
|
143
143
|
|
|
144
144
|
| Function | Type |
|
|
145
145
|
| ---------- | ---------- |
|
|
146
|
-
| `useIsArchiveDevice` | `() => { data:
|
|
146
|
+
| `useIsArchiveDevice` | `() => { data: boolean; error: Error or null; isRefetching: boolean; }` |
|
|
147
147
|
|
|
148
148
|
Examples:
|
|
149
149
|
|
|
@@ -160,7 +160,7 @@ Update the device info for the current device.
|
|
|
160
160
|
|
|
161
161
|
| Function | Type |
|
|
162
162
|
| ---------- | ---------- |
|
|
163
|
-
| `useSetOwnDeviceInfo` | `() => Pick<Override<MutationObserverIdleResult<
|
|
163
|
+
| `useSetOwnDeviceInfo` | `() => Pick<Override<MutationObserverIdleResult<void, Error, { name: string; deviceType: "device_type_unspecified" or "mobile" or "tablet" or "desktop" or "selfHostedServer" or "UNRECOGNIZED"; }, unknown>, { ...; }> and { ...; }, "error" or ... 3 more ... or "mutateAsync"> or Pick<...> or Pick<...> or Pick<...>` |
|
|
164
164
|
|
|
165
165
|
### useSetIsArchiveDevice
|
|
166
166
|
|
|
@@ -168,13 +168,13 @@ Set or unset the current device as an archive device.
|
|
|
168
168
|
|
|
169
169
|
| Function | Type |
|
|
170
170
|
| ---------- | ---------- |
|
|
171
|
-
| `useSetIsArchiveDevice` | `() => Pick<Override<MutationObserverIdleResult<
|
|
171
|
+
| `useSetIsArchiveDevice` | `() => Pick<Override<MutationObserverIdleResult<void, Error, { isArchiveDevice: boolean; }, unknown>, { mutate: UseMutateFunction<void, Error, { isArchiveDevice: boolean; }, unknown>; }> and { ...; }, "error" or ... 3 more ... or "mutateAsync"> or Pick<...> or Pick<...> or Pick<...>` |
|
|
172
172
|
|
|
173
173
|
### ReceivedMapSharesProvider
|
|
174
174
|
|
|
175
175
|
| Function | Type |
|
|
176
176
|
| ---------- | ---------- |
|
|
177
|
-
| `ReceivedMapSharesProvider` | `({ children, clientApi, mapServerApi, queryClient, }: { clientApi:
|
|
177
|
+
| `ReceivedMapSharesProvider` | `({ children, clientApi, mapServerApi, queryClient, }: { clientApi: ClientApi<Omit<MapeoManager, "getProject"> and { getProject: (projectPublicId: string) => Promise<ClientApi<MapeoProject>>; }>; mapServerApi: MapServerApi; } and { ...; } and { ...; }) => Element` |
|
|
178
178
|
|
|
179
179
|
### SentMapSharesProvider
|
|
180
180
|
|
|
@@ -192,31 +192,31 @@ Set or unset the current device as an archive device.
|
|
|
192
192
|
|
|
193
193
|
| Function | Type |
|
|
194
194
|
| ---------- | ---------- |
|
|
195
|
-
| `useReceivedMapSharesState` | `{ ():
|
|
195
|
+
| `useReceivedMapSharesState` | `{ (): ReceivedMapShareState[]; <T>(selector: (state: ReceivedMapShareState[]) => T): T; }` |
|
|
196
196
|
|
|
197
197
|
### useReceivedMapSharesState
|
|
198
198
|
|
|
199
199
|
| Function | Type |
|
|
200
200
|
| ---------- | ---------- |
|
|
201
|
-
| `useReceivedMapSharesState` | `{ ():
|
|
201
|
+
| `useReceivedMapSharesState` | `{ (): ReceivedMapShareState[]; <T>(selector: (state: ReceivedMapShareState[]) => T): T; }` |
|
|
202
202
|
|
|
203
203
|
### useReceivedMapSharesState
|
|
204
204
|
|
|
205
205
|
| Function | Type |
|
|
206
206
|
| ---------- | ---------- |
|
|
207
|
-
| `useReceivedMapSharesState` | `{ ():
|
|
207
|
+
| `useReceivedMapSharesState` | `{ (): ReceivedMapShareState[]; <T>(selector: (state: ReceivedMapShareState[]) => T): T; }` |
|
|
208
208
|
|
|
209
209
|
### useSentMapSharesActions
|
|
210
210
|
|
|
211
211
|
| Function | Type |
|
|
212
212
|
| ---------- | ---------- |
|
|
213
|
-
| `useSentMapSharesActions` | `() => { createAndSend({ receiverDeviceId, mapId, }: CreateAndSendMapShareOptions): Promise<
|
|
213
|
+
| `useSentMapSharesActions` | `() => { createAndSend({ receiverDeviceId, mapId, }: CreateAndSendMapShareOptions): Promise<MapShareState>; cancel({ shareId }: CancelMapShareOptions): Promise<...>; }` |
|
|
214
214
|
|
|
215
215
|
### useSentMapSharesState
|
|
216
216
|
|
|
217
217
|
| Function | Type |
|
|
218
218
|
| ---------- | ---------- |
|
|
219
|
-
| `useSentMapSharesState` | `<T>(selector?: ((state:
|
|
219
|
+
| `useSentMapSharesState` | `<T>(selector?: ((state: MapShareState[]) => T) or undefined) => T` |
|
|
220
220
|
|
|
221
221
|
### createMapServerApi
|
|
222
222
|
|
|
@@ -295,7 +295,7 @@ Retrieve the project settings for a project.
|
|
|
295
295
|
|
|
296
296
|
| Function | Type |
|
|
297
297
|
| ---------- | ---------- |
|
|
298
|
-
| `useProjectSettings` | `({ projectId, }: { projectId: string; }) => Pick<UseSuspenseQueryResult<
|
|
298
|
+
| `useProjectSettings` | `({ projectId, }: { projectId: string; }) => Pick<UseSuspenseQueryResult<EditableProjectSettings>, "data" or "error" or "isRefetching">` |
|
|
299
299
|
|
|
300
300
|
Parameters:
|
|
301
301
|
|
|
@@ -321,7 +321,7 @@ This is mostly used internally by the other hooks and should only be used if cer
|
|
|
321
321
|
|
|
322
322
|
| Function | Type |
|
|
323
323
|
| ---------- | ---------- |
|
|
324
|
-
| `useSingleProject` | `({ projectId, }: { projectId: string; }) => Pick<UseSuspenseQueryResult<
|
|
324
|
+
| `useSingleProject` | `({ projectId, }: { projectId: string; }) => Pick<UseSuspenseQueryResult<ClientApi<MapeoProject>>, "data" or "error" or "isRefetching">` |
|
|
325
325
|
|
|
326
326
|
Parameters:
|
|
327
327
|
|
|
@@ -343,7 +343,7 @@ Retrieve project information for each project that exists.
|
|
|
343
343
|
|
|
344
344
|
| Function | Type |
|
|
345
345
|
| ---------- | ---------- |
|
|
346
|
-
| `useManyProjects` | `() => Pick<UseSuspenseQueryResult<
|
|
346
|
+
| `useManyProjects` | `() => Pick<UseSuspenseQueryResult<ListedProject[]>, "data" or "error" or "isRefetching">` |
|
|
347
347
|
|
|
348
348
|
Examples:
|
|
349
349
|
|
|
@@ -362,7 +362,7 @@ Retrieve a single member of a project.
|
|
|
362
362
|
|
|
363
363
|
| Function | Type |
|
|
364
364
|
| ---------- | ---------- |
|
|
365
|
-
| `useSingleMember` | `({ projectId, deviceId, }: { projectId: string; deviceId: string; }) => Pick<UseSuspenseQueryResult<
|
|
365
|
+
| `useSingleMember` | `({ projectId, deviceId, }: { projectId: string; deviceId: string; }) => Pick<UseSuspenseQueryResult<MemberInfo>, "data" or "error" or "isRefetching">` |
|
|
366
366
|
|
|
367
367
|
Parameters:
|
|
368
368
|
|
|
@@ -518,7 +518,7 @@ Retrieve the device ID that created a document.
|
|
|
518
518
|
|
|
519
519
|
| Function | Type |
|
|
520
520
|
| ---------- | ---------- |
|
|
521
|
-
| `useDocumentCreatedBy` | `({ projectId, originalVersionId, }: { projectId: string; originalVersionId: string; }) => { data:
|
|
521
|
+
| `useDocumentCreatedBy` | `({ projectId, originalVersionId, }: { projectId: string; originalVersionId: string; }) => { data: string; error: Error or null; isRefetching: boolean; }` |
|
|
522
522
|
|
|
523
523
|
Parameters:
|
|
524
524
|
|
|
@@ -545,7 +545,7 @@ This is a more convenient alternative to using the `useOwnDeviceInfo` and `useMa
|
|
|
545
545
|
|
|
546
546
|
| Function | Type |
|
|
547
547
|
| ---------- | ---------- |
|
|
548
|
-
| `useOwnRoleInProject` | `({ projectId, }: { projectId: string; }) => Pick<UseSuspenseQueryResult<
|
|
548
|
+
| `useOwnRoleInProject` | `({ projectId, }: { projectId: string; }) => Pick<UseSuspenseQueryResult<Role and { reason: string or undefined; }>, "data" or "error" or "isRefetching">` |
|
|
549
549
|
|
|
550
550
|
Parameters:
|
|
551
551
|
|
|
@@ -567,13 +567,13 @@ function BasicExample() {
|
|
|
567
567
|
|
|
568
568
|
| Function | Type |
|
|
569
569
|
| ---------- | ---------- |
|
|
570
|
-
| `useAddServerPeer` | `({ projectId }: { projectId: string; }) => Pick<Override<MutationObserverIdleResult<
|
|
570
|
+
| `useAddServerPeer` | `({ projectId }: { projectId: string; }) => Pick<Override<MutationObserverIdleResult<void, Error, { baseUrl: string; dangerouslyAllowInsecureConnections?: boolean or undefined; }, unknown>, { ...; }> and { ...; }, "error" or ... 3 more ... or "mutateAsync"> or Pick<...> or Pick<...> or Pick<...>` |
|
|
571
571
|
|
|
572
572
|
### useRemoveServerPeer
|
|
573
573
|
|
|
574
574
|
| Function | Type |
|
|
575
575
|
| ---------- | ---------- |
|
|
576
|
-
| `useRemoveServerPeer` | `({ projectId }: { projectId: string; }) => Pick<Override<MutationObserverIdleResult<
|
|
576
|
+
| `useRemoveServerPeer` | `({ projectId }: { projectId: string; }) => Pick<Override<MutationObserverIdleResult<void, Error, { serverDeviceId: string; dangerouslyAllowInsecureConnections?: boolean or undefined; }, unknown>, { ...; }> and { ...; }, "error" or ... 3 more ... or "mutateAsync"> or Pick<...> or Pick<...> or Pick<...>` |
|
|
577
577
|
|
|
578
578
|
### useCreateProject
|
|
579
579
|
|
|
@@ -581,7 +581,7 @@ Create a new project.
|
|
|
581
581
|
|
|
582
582
|
| Function | Type |
|
|
583
583
|
| ---------- | ---------- |
|
|
584
|
-
| `useCreateProject` | `() => Pick<Override<MutationObserverIdleResult<
|
|
584
|
+
| `useCreateProject` | `() => Pick<Override<MutationObserverIdleResult<string, Error, { name?: string or undefined; configPath?: string or undefined; projectColor?: string or undefined; projectDescription?: string or undefined; } or undefined, unknown>, { ...; }> and { ...; }, "error" or ... 3 more ... or "mutateAsync"> or Pick<...> or Pick<...> or Pi...` |
|
|
585
585
|
|
|
586
586
|
### useLeaveProject
|
|
587
587
|
|
|
@@ -589,7 +589,7 @@ Leave an existing project.
|
|
|
589
589
|
|
|
590
590
|
| Function | Type |
|
|
591
591
|
| ---------- | ---------- |
|
|
592
|
-
| `useLeaveProject` | `() => Pick<Override<MutationObserverIdleResult<
|
|
592
|
+
| `useLeaveProject` | `() => Pick<Override<MutationObserverIdleResult<void, Error, { projectId: string; }, unknown>, { mutate: UseMutateFunction<void, Error, { projectId: string; }, unknown>; }> and { ...; }, "error" or ... 3 more ... or "mutateAsync"> or Pick<...> or Pick<...> or Pick<...>` |
|
|
593
593
|
|
|
594
594
|
### useImportProjectCategories
|
|
595
595
|
|
|
@@ -597,7 +597,7 @@ Update the categories of a project using an external file.
|
|
|
597
597
|
|
|
598
598
|
| Function | Type |
|
|
599
599
|
| ---------- | ---------- |
|
|
600
|
-
| `useImportProjectCategories` | `({ projectId, }: { projectId: string; }) => Pick<Override<MutationObserverIdleResult<
|
|
600
|
+
| `useImportProjectCategories` | `({ projectId, }: { projectId: string; }) => Pick<Override<MutationObserverIdleResult<void, Error, { filePath: string; }, unknown>, { mutate: UseMutateFunction<void, Error, { ...; }, unknown>; }> and { ...; }, "error" or ... 3 more ... or "mutateAsync"> or Pick<...> or Pick<...> or Pick<...>` |
|
|
601
601
|
|
|
602
602
|
Parameters:
|
|
603
603
|
|
|
@@ -610,7 +610,7 @@ Update the configuration of a project using an external file.
|
|
|
610
610
|
|
|
611
611
|
| Function | Type |
|
|
612
612
|
| ---------- | ---------- |
|
|
613
|
-
| `useImportProjectConfig` | `({ projectId }: { projectId: string; }) => Pick<Override<MutationObserverIdleResult<
|
|
613
|
+
| `useImportProjectConfig` | `({ projectId }: { projectId: string; }) => Pick<Override<MutationObserverIdleResult<Error[], Error, { configPath: string; }, unknown>, { mutate: UseMutateFunction<Error[], Error, { ...; }, unknown>; }> and { ...; }, "error" or ... 3 more ... or "mutateAsync"> or Pick<...> or Pick<...> or Pick<...>` |
|
|
614
614
|
|
|
615
615
|
Parameters:
|
|
616
616
|
|
|
@@ -636,7 +636,7 @@ Change a project member's role.
|
|
|
636
636
|
|
|
637
637
|
| Function | Type |
|
|
638
638
|
| ---------- | ---------- |
|
|
639
|
-
| `useChangeMemberRole` | `({ projectId }: { projectId: string; }) => Pick<Override<MutationObserverIdleResult<
|
|
639
|
+
| `useChangeMemberRole` | `({ projectId }: { projectId: string; }) => Pick<Override<MutationObserverIdleResult<void, Error, { deviceId: string; roleId: "f7c150f5a3a9a855" or "012fd2d431c0bf60" or "9e6d29263cba36c9"; }, unknown>, { ...; }> and { ...; }, "error" or ... 3 more ... or "mutateAsync"> or Pick<...> or Pick<...> or Pick<...>` |
|
|
640
640
|
|
|
641
641
|
Parameters:
|
|
642
642
|
|
|
@@ -662,7 +662,7 @@ Do NOT use this for removing your own device from a project. Use `useLeaveProjec
|
|
|
662
662
|
|
|
663
663
|
| Function | Type |
|
|
664
664
|
| ---------- | ---------- |
|
|
665
|
-
| `useRemoveMember` | `({ projectId }: { projectId: string; }) => Pick<Override<MutationObserverIdleResult<
|
|
665
|
+
| `useRemoveMember` | `({ projectId }: { projectId: string; }) => Pick<Override<MutationObserverIdleResult<void, Error, { deviceId: string; reason?: string or undefined; }, unknown>, { mutate: UseMutateFunction<...>; }> and { ...; }, "error" or ... 3 more ... or "mutateAsync"> or Pick<...> or Pick<...> or Pick<...>` |
|
|
666
666
|
|
|
667
667
|
Parameters:
|
|
668
668
|
|
|
@@ -726,7 +726,7 @@ Create a blob for a project.
|
|
|
726
726
|
|
|
727
727
|
| Function | Type |
|
|
728
728
|
| ---------- | ---------- |
|
|
729
|
-
| `useCreateBlob` | `({ projectId }: { projectId: string; }) => Pick<Override<MutationObserverIdleResult<
|
|
729
|
+
| `useCreateBlob` | `({ projectId }: { projectId: string; }) => Pick<Override<MutationObserverIdleResult<{ driveId: string; name: string; type: "photo" or "audio" or "video"; hash: string; }, Error, { original: string; preview?: string or undefined; thumbnail?: string or undefined; metadata: Metadata; }, unknown>, { ...; }> and { ...; }, "err...` |
|
|
730
730
|
|
|
731
731
|
Parameters:
|
|
732
732
|
|
|
@@ -743,7 +743,7 @@ additional listeners across the IPC channel.
|
|
|
743
743
|
|
|
744
744
|
| Function | Type |
|
|
745
745
|
| ---------- | ---------- |
|
|
746
|
-
| `useSyncState` | `({ projectId, }: { projectId: string; }) =>
|
|
746
|
+
| `useSyncState` | `({ projectId, }: { projectId: string; }) => State or null` |
|
|
747
747
|
|
|
748
748
|
Parameters:
|
|
749
749
|
|
|
@@ -781,31 +781,31 @@ Returns:
|
|
|
781
781
|
|
|
782
782
|
| Function | Type |
|
|
783
783
|
| ---------- | ---------- |
|
|
784
|
-
| `useStartSync` | `({ projectId }: { projectId: string; }) => Pick<Override<MutationObserverIdleResult<
|
|
784
|
+
| `useStartSync` | `({ projectId }: { projectId: string; }) => Pick<Override<MutationObserverIdleResult<void, Error, { autostopDataSyncAfter: number or null; } or undefined, unknown>, { ...; }> and { ...; }, "error" or ... 3 more ... or "mutateAsync"> or Pick<...> or Pick<...> or Pick<...>` |
|
|
785
785
|
|
|
786
786
|
### useStopSync
|
|
787
787
|
|
|
788
788
|
| Function | Type |
|
|
789
789
|
| ---------- | ---------- |
|
|
790
|
-
| `useStopSync` | `({ projectId }: { projectId: string; }) => Pick<Override<MutationObserverIdleResult<
|
|
790
|
+
| `useStopSync` | `({ projectId }: { projectId: string; }) => Pick<Override<MutationObserverIdleResult<void, Error, void, unknown>, { mutate: UseMutateFunction<void, Error, void, unknown>; }> and { ...; }, "error" or ... 3 more ... or "mutateAsync"> or Pick<...> or Pick<...> or Pick<...>` |
|
|
791
791
|
|
|
792
792
|
### useConnectSyncServers
|
|
793
793
|
|
|
794
794
|
| Function | Type |
|
|
795
795
|
| ---------- | ---------- |
|
|
796
|
-
| `useConnectSyncServers` | `({ projectId }: { projectId: string; }) => Pick<Override<MutationObserverIdleResult<
|
|
796
|
+
| `useConnectSyncServers` | `({ projectId }: { projectId: string; }) => Pick<Override<MutationObserverIdleResult<void, Error, void, unknown>, { mutate: UseMutateFunction<void, Error, void, unknown>; }> and { ...; }, "error" or ... 3 more ... or "mutateAsync"> or Pick<...> or Pick<...> or Pick<...>` |
|
|
797
797
|
|
|
798
798
|
### useDisconnectSyncServers
|
|
799
799
|
|
|
800
800
|
| Function | Type |
|
|
801
801
|
| ---------- | ---------- |
|
|
802
|
-
| `useDisconnectSyncServers` | `({ projectId }: { projectId: string; }) => Pick<Override<MutationObserverIdleResult<
|
|
802
|
+
| `useDisconnectSyncServers` | `({ projectId }: { projectId: string; }) => Pick<Override<MutationObserverIdleResult<void, Error, void, unknown>, { mutate: UseMutateFunction<void, Error, void, unknown>; }> and { ...; }, "error" or ... 3 more ... or "mutateAsync"> or Pick<...> or Pick<...> or Pick<...>` |
|
|
803
803
|
|
|
804
804
|
### useSetAutostopDataSyncTimeout
|
|
805
805
|
|
|
806
806
|
| Function | Type |
|
|
807
807
|
| ---------- | ---------- |
|
|
808
|
-
| `useSetAutostopDataSyncTimeout` | `({ projectId, }: { projectId: string; }) => Pick<Override<MutationObserverIdleResult<
|
|
808
|
+
| `useSetAutostopDataSyncTimeout` | `({ projectId, }: { projectId: string; }) => Pick<Override<MutationObserverIdleResult<void, Error, { after: number or null; }, unknown>, { mutate: UseMutateFunction<void, Error, { ...; }, unknown>; }> and { ...; }, "error" or ... 3 more ... or "mutateAsync"> or Pick<...> or Pick<...> or Pick<...>` |
|
|
809
809
|
|
|
810
810
|
### useExportGeoJSON
|
|
811
811
|
|
|
@@ -813,7 +813,7 @@ Creates a GeoJson file with all the observations and/or tracks in the project.
|
|
|
813
813
|
|
|
814
814
|
| Function | Type |
|
|
815
815
|
| ---------- | ---------- |
|
|
816
|
-
| `useExportGeoJSON` | `({ projectId }: { projectId: string; }) => Pick<Override<MutationObserverIdleResult<
|
|
816
|
+
| `useExportGeoJSON` | `({ projectId }: { projectId: string; }) => Pick<Override<MutationObserverIdleResult<string, Error, { path: string; exportOptions: { observations?: boolean or undefined; tracks?: boolean or undefined; lang?: string or undefined; }; }, unknown>, { ...; }> and { ...; }, "error" or ... 3 more ... or "mutateAsync"> or Pick<...> ...` |
|
|
817
817
|
|
|
818
818
|
Parameters:
|
|
819
819
|
|
|
@@ -826,7 +826,7 @@ Creates a zip file containing a GeoJson file with all the observations and/or tr
|
|
|
826
826
|
|
|
827
827
|
| Function | Type |
|
|
828
828
|
| ---------- | ---------- |
|
|
829
|
-
| `useExportZipFile` | `({ projectId }: { projectId: string; }) => Pick<Override<MutationObserverIdleResult<
|
|
829
|
+
| `useExportZipFile` | `({ projectId }: { projectId: string; }) => Pick<Override<MutationObserverIdleResult<string, Error, { path: string; exportOptions: { observations?: boolean or undefined; tracks?: boolean or undefined; lang?: string or undefined; attachments?: boolean or undefined; }; }, unknown>, { ...; }> and { ...; }, "error" or ... 3 mor...` |
|
|
830
830
|
|
|
831
831
|
Parameters:
|
|
832
832
|
|
|
@@ -841,7 +841,7 @@ Triggers the closest error boundary if the document cannot be found
|
|
|
841
841
|
|
|
842
842
|
| Function | Type |
|
|
843
843
|
| ---------- | ---------- |
|
|
844
|
-
| `useSingleDocByDocId` | `<D extends WriteableDocumentType>({ projectId, docType, docId, lang, }: { projectId: string; docType: D; docId: string; lang?: string or undefined; }) => Pick<UseSuspenseQueryResult<
|
|
844
|
+
| `useSingleDocByDocId` | `<D extends WriteableDocumentType>({ projectId, docType, docId, lang, }: { projectId: string; docType: D; docId: string; lang?: string or undefined; }) => Pick<UseSuspenseQueryResult<Awaited<ReturnType<ClientApi<MapeoProject>[D]["getByDocId"]>>>, "data" or ... 1 more ... or "isRefetching">` |
|
|
845
845
|
|
|
846
846
|
Parameters:
|
|
847
847
|
|
|
@@ -874,7 +874,7 @@ Triggers the closest error boundary if the document cannot be found.
|
|
|
874
874
|
|
|
875
875
|
| Function | Type |
|
|
876
876
|
| ---------- | ---------- |
|
|
877
|
-
| `useSingleDocByVersionId` | `<D extends WriteableDocumentType>({ projectId, docType, versionId, lang, }: { projectId: string; docType: D; versionId: string; lang?: string or undefined; }) => Pick<UseSuspenseQueryResult<
|
|
877
|
+
| `useSingleDocByVersionId` | `<D extends WriteableDocumentType>({ projectId, docType, versionId, lang, }: { projectId: string; docType: D; versionId: string; lang?: string or undefined; }) => Pick<UseSuspenseQueryResult<Awaited<ReturnType<ClientApi<MapeoProject>[D]["getByVersionId"]>>>, "data" or ... 1 more ... or "isRefetching">` |
|
|
878
878
|
|
|
879
879
|
Parameters:
|
|
880
880
|
|
|
@@ -907,7 +907,7 @@ Retrieve all documents of a specific `docType`.
|
|
|
907
907
|
|
|
908
908
|
| Function | Type |
|
|
909
909
|
| ---------- | ---------- |
|
|
910
|
-
| `useManyDocs` | `<D extends WriteableDocumentType>({ projectId, docType, includeDeleted, lang, }: { projectId: string; docType: D; includeDeleted?: boolean or undefined; lang?: string or undefined; }) => Pick<UseSuspenseQueryResult<
|
|
910
|
+
| `useManyDocs` | `<D extends WriteableDocumentType>({ projectId, docType, includeDeleted, lang, }: { projectId: string; docType: D; includeDeleted?: boolean or undefined; lang?: string or undefined; }) => Pick<UseSuspenseQueryResult<Awaited<ReturnType<ClientApi<MapeoProject>[D]["getMany"]>>>, "data" or ... 1 more ... or "isRefetching">` |
|
|
911
911
|
|
|
912
912
|
Parameters:
|
|
913
913
|
|
|
@@ -951,7 +951,7 @@ Create a document for a project.
|
|
|
951
951
|
|
|
952
952
|
| Function | Type |
|
|
953
953
|
| ---------- | ---------- |
|
|
954
|
-
| `useCreateDocument` | `<D extends WriteableDocumentType>({ docType, projectId, }: { docType: D; projectId: string; }) => FilteredMutationResult<UseMutationResult<
|
|
954
|
+
| `useCreateDocument` | `<D extends WriteableDocumentType>({ docType, projectId, }: { docType: D; projectId: string; }) => FilteredMutationResult<UseMutationResult<Awaited<ReturnType<ClientApi<MapeoProject>[D]["create"]>>, Error, { ...; }>>` |
|
|
955
955
|
|
|
956
956
|
Parameters:
|
|
957
957
|
|
|
@@ -965,7 +965,7 @@ Update a document within a project.
|
|
|
965
965
|
|
|
966
966
|
| Function | Type |
|
|
967
967
|
| ---------- | ---------- |
|
|
968
|
-
| `useUpdateDocument` | `<D extends WriteableDocumentType>({ docType, projectId, }: { docType: D; projectId: string; }) => FilteredMutationResult<UseMutationResult<
|
|
968
|
+
| `useUpdateDocument` | `<D extends WriteableDocumentType>({ docType, projectId, }: { docType: D; projectId: string; }) => FilteredMutationResult<UseMutationResult<Awaited<ReturnType<ClientApi<MapeoProject>[D]["update"]>>, Error, { ...; }>>` |
|
|
969
969
|
|
|
970
970
|
Parameters:
|
|
971
971
|
|
|
@@ -979,7 +979,7 @@ Delete a document within a project.
|
|
|
979
979
|
|
|
980
980
|
| Function | Type |
|
|
981
981
|
| ---------- | ---------- |
|
|
982
|
-
| `useDeleteDocument` | `<D extends WriteableDocumentType>({ docType, projectId, }: { docType: D; projectId: string; }) => FilteredMutationResult<UseMutationResult<
|
|
982
|
+
| `useDeleteDocument` | `<D extends WriteableDocumentType>({ docType, projectId, }: { docType: D; projectId: string; }) => FilteredMutationResult<UseMutationResult<Awaited<ReturnType<ClientApi<MapeoProject>[D]["delete"]>>, Error, { ...; }>>` |
|
|
983
983
|
|
|
984
984
|
Parameters:
|
|
985
985
|
|
|
@@ -996,7 +996,7 @@ specified data type. Falls back to alphabetical order (by preset name) if no def
|
|
|
996
996
|
|
|
997
997
|
| Function | Type |
|
|
998
998
|
| ---------- | ---------- |
|
|
999
|
-
| `usePresetsSelection` | `({ projectId, dataType, lang, }: { projectId: string; dataType: "
|
|
999
|
+
| `usePresetsSelection` | `({ projectId, dataType, lang, }: { projectId: string; dataType: "track" or "observation"; lang?: string or undefined; }) => { schemaName: "preset"; name: string; geometry: ("point" or "line" or "vertex" or "area" or "relation")[]; ... 13 more ...; deleted: boolean; }[]` |
|
|
1000
1000
|
|
|
1001
1001
|
Parameters:
|
|
1002
1002
|
|
|
@@ -1071,7 +1071,7 @@ Accept an invite that has been received.
|
|
|
1071
1071
|
|
|
1072
1072
|
| Function | Type |
|
|
1073
1073
|
| ---------- | ---------- |
|
|
1074
|
-
| `useAcceptInvite` | `() => Pick<Override<MutationObserverIdleResult<
|
|
1074
|
+
| `useAcceptInvite` | `() => Pick<Override<MutationObserverIdleResult<string, Error, { inviteId: string; }, unknown>, { mutate: UseMutateFunction<string, Error, { inviteId: string; }, unknown>; }> and { ...; }, "error" or ... 3 more ... or "mutateAsync"> or Pick<...> or Pick<...> or Pick<...>` |
|
|
1075
1075
|
|
|
1076
1076
|
### useRejectInvite
|
|
1077
1077
|
|
|
@@ -1079,7 +1079,7 @@ Reject an invite that has been received.
|
|
|
1079
1079
|
|
|
1080
1080
|
| Function | Type |
|
|
1081
1081
|
| ---------- | ---------- |
|
|
1082
|
-
| `useRejectInvite` | `() => Pick<Override<MutationObserverIdleResult<
|
|
1082
|
+
| `useRejectInvite` | `() => Pick<Override<MutationObserverIdleResult<void, Error, { inviteId: string; }, unknown>, { mutate: UseMutateFunction<void, Error, { inviteId: string; }, unknown>; }> and { ...; }, "error" or ... 3 more ... or "mutateAsync"> or Pick<...> or Pick<...> or Pick<...>` |
|
|
1083
1083
|
|
|
1084
1084
|
### useSendInvite
|
|
1085
1085
|
|
|
@@ -1087,7 +1087,7 @@ Send an invite for a project.
|
|
|
1087
1087
|
|
|
1088
1088
|
| Function | Type |
|
|
1089
1089
|
| ---------- | ---------- |
|
|
1090
|
-
| `useSendInvite` | `({ projectId }: { projectId: string; }) => Pick<Override<MutationObserverIdleResult<
|
|
1090
|
+
| `useSendInvite` | `({ projectId }: { projectId: string; }) => Pick<Override<MutationObserverIdleResult<"ACCEPT" or "REJECT" or "ALREADY", Error, { deviceId: string; roleDescription?: string or undefined; roleId: "f7c150f5a3a9a855" or "012fd2d431c0bf60" or "9e6d29263cba36c9"; roleName?: string or undefined; }, unknown>, { ...; }> and { ...; },...` |
|
|
1091
1091
|
|
|
1092
1092
|
Parameters:
|
|
1093
1093
|
|
|
@@ -1100,7 +1100,7 @@ Request a cancellation of an invite sent to another device.
|
|
|
1100
1100
|
|
|
1101
1101
|
| Function | Type |
|
|
1102
1102
|
| ---------- | ---------- |
|
|
1103
|
-
| `useRequestCancelInvite` | `({ projectId }: { projectId: string; }) => Pick<Override<MutationObserverIdleResult<
|
|
1103
|
+
| `useRequestCancelInvite` | `({ projectId }: { projectId: string; }) => Pick<Override<MutationObserverIdleResult<void, Error, { deviceId: string; }, unknown>, { mutate: UseMutateFunction<void, Error, { ...; }, unknown>; }> and { ...; }, "error" or ... 3 more ... or "mutateAsync"> or Pick<...> or Pick<...> or Pick<...>` |
|
|
1104
1104
|
|
|
1105
1105
|
Parameters:
|
|
1106
1106
|
|
|
@@ -1159,7 +1159,7 @@ Note that this is _not_ a suspenseful hook. The different read states should be
|
|
|
1159
1159
|
|
|
1160
1160
|
| Function | Type |
|
|
1161
1161
|
| ---------- | ---------- |
|
|
1162
|
-
| `useGetCustomMapInfo` | `() => Pick<QueryObserverRefetchErrorResult<
|
|
1162
|
+
| `useGetCustomMapInfo` | `() => Pick<QueryObserverRefetchErrorResult<{ name: string; size: number; created: number; }, Error>, "data" or "error" or "status" or "isRefetching"> or ... 4 more ... or Pick<...>` |
|
|
1163
1163
|
|
|
1164
1164
|
Examples:
|
|
1165
1165
|
|
|
@@ -1199,7 +1199,7 @@ a specific share, including download progress.
|
|
|
1199
1199
|
|
|
1200
1200
|
| Function | Type |
|
|
1201
1201
|
| ---------- | ---------- |
|
|
1202
|
-
| `useManyReceivedMapShares` | `() =>
|
|
1202
|
+
| `useManyReceivedMapShares` | `() => ReceivedMapShareState[]` |
|
|
1203
1203
|
|
|
1204
1204
|
Examples:
|
|
1205
1205
|
|
|
@@ -1222,7 +1222,7 @@ Get a single received map share based on its shareId.
|
|
|
1222
1222
|
|
|
1223
1223
|
| Function | Type |
|
|
1224
1224
|
| ---------- | ---------- |
|
|
1225
|
-
| `useSingleReceivedMapShare` | `({ shareId }: { shareId: string; }) =>
|
|
1225
|
+
| `useSingleReceivedMapShare` | `({ shareId }: { shareId: string; }) => ReceivedMapShareState` |
|
|
1226
1226
|
|
|
1227
1227
|
Parameters:
|
|
1228
1228
|
|
|
@@ -1326,7 +1326,7 @@ can be used to track the share status with `useSingleSentMapShare`.
|
|
|
1326
1326
|
|
|
1327
1327
|
| Function | Type |
|
|
1328
1328
|
| ---------- | ---------- |
|
|
1329
|
-
| `useSendMapShare` | `() => Pick<Override<MutationObserverIdleResult<
|
|
1329
|
+
| `useSendMapShare` | `() => Pick<Override<MutationObserverIdleResult<MapShareState, Error, CreateAndSendMapShareOptions, unknown>, { ...; }> and { ...; }, "error" or ... 3 more ... or "mutateAsync"> or Pick<...> or Pick<...> or Pick<...>` |
|
|
1330
1330
|
|
|
1331
1331
|
Examples:
|
|
1332
1332
|
|
|
@@ -1387,7 +1387,7 @@ if they decline the share, then the returned share will update.
|
|
|
1387
1387
|
|
|
1388
1388
|
| Function | Type |
|
|
1389
1389
|
| ---------- | ---------- |
|
|
1390
|
-
| `useSingleSentMapShare` | `({ shareId, }: { shareId: string; }) =>
|
|
1390
|
+
| `useSingleSentMapShare` | `({ shareId, }: { shareId: string; }) => MapShareState` |
|
|
1391
1391
|
|
|
1392
1392
|
Parameters:
|
|
1393
1393
|
|
|
@@ -1423,19 +1423,19 @@ function SentShareStatus({ shareId }: { shareId: string }) {
|
|
|
1423
1423
|
|
|
1424
1424
|
| Constant | Type |
|
|
1425
1425
|
| ---------- | ---------- |
|
|
1426
|
-
| `ClientApiContext` | `Context<
|
|
1426
|
+
| `ClientApiContext` | `Context<ClientApi<Omit<MapeoManager, "getProject"> and { getProject: (projectPublicId: string) => Promise<ClientApi<MapeoProject>>; }> or null>` |
|
|
1427
1427
|
|
|
1428
1428
|
### ReceivedMapSharesContext
|
|
1429
1429
|
|
|
1430
1430
|
| Constant | Type |
|
|
1431
1431
|
| ---------- | ---------- |
|
|
1432
|
-
| `ReceivedMapSharesContext` | `Context<{ subscribe: (listener: () => void) => () => boolean; getSnapshot: () =>
|
|
1432
|
+
| `ReceivedMapSharesContext` | `Context<{ subscribe: (listener: () => void) => () => boolean; getSnapshot: () => ReceivedMapShareState[]; actions: { download({ shareId }: DownloadMapShareOptions): Promise<...>; decline({ shareId, reason }: DeclineMapShareOptions): Promise<...>; abort({ shareId }: AbortMapShareOptions): Promise<...>; }; } or null>` |
|
|
1433
1433
|
|
|
1434
1434
|
### SentMapSharesContext
|
|
1435
1435
|
|
|
1436
1436
|
| Constant | Type |
|
|
1437
1437
|
| ---------- | ---------- |
|
|
1438
|
-
| `SentMapSharesContext` | `Context<{ subscribe: (listener: () => void) => () => boolean; getSnapshot: () =>
|
|
1438
|
+
| `SentMapSharesContext` | `Context<{ subscribe: (listener: () => void) => () => boolean; getSnapshot: () => MapShareState[]; actions: { createAndSend({ receiverDeviceId, mapId, }: CreateAndSendMapShareOptions): Promise<...>; cancel({ shareId }: CancelMapShareOptions): Promise<...>; }; } or null>` |
|
|
1439
1439
|
|
|
1440
1440
|
### MapServerContext
|
|
1441
1441
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@comapeo/core-react",
|
|
3
|
-
"version": "11.0.
|
|
3
|
+
"version": "11.0.5",
|
|
4
4
|
"description": "React wrapper for working with @comapeo/core",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -64,55 +64,54 @@
|
|
|
64
64
|
"types": "tsc"
|
|
65
65
|
},
|
|
66
66
|
"dependencies": {
|
|
67
|
-
"@comapeo/map-server": "^1.1.
|
|
68
|
-
"ensure-error": "5.0.0",
|
|
69
|
-
"eventsource-client": "1.2.0",
|
|
70
|
-
"type-fest": "5.
|
|
67
|
+
"@comapeo/map-server": "^1.1.3",
|
|
68
|
+
"ensure-error": "^5.0.0",
|
|
69
|
+
"eventsource-client": "^1.2.0",
|
|
70
|
+
"type-fest": "^5.6.0"
|
|
71
71
|
},
|
|
72
72
|
"peerDependencies": {
|
|
73
|
-
"@comapeo/core": "^7.0
|
|
73
|
+
"@comapeo/core": "^7.2.0",
|
|
74
74
|
"@comapeo/ipc": "^8.0.0",
|
|
75
75
|
"@tanstack/react-query": "^5",
|
|
76
76
|
"react": "^18 || ^19"
|
|
77
77
|
},
|
|
78
78
|
"devDependencies": {
|
|
79
|
-
"@comapeo/core": "7.0
|
|
79
|
+
"@comapeo/core": "7.2.0",
|
|
80
80
|
"@comapeo/ipc": "8.0.0",
|
|
81
|
-
"@eslint/
|
|
82
|
-
"@eslint/js": "9.39.4",
|
|
81
|
+
"@eslint/js": "10.0.1",
|
|
83
82
|
"@ianvs/prettier-plugin-sort-imports": "4.7.1",
|
|
84
|
-
"@mapeo/crypto": "1.
|
|
83
|
+
"@mapeo/crypto": "1.1.0",
|
|
85
84
|
"@mapeo/default-config": "6.0.0",
|
|
86
85
|
"@mapeo/mock-data": "5.0.0",
|
|
87
|
-
"@tanstack/eslint-plugin-query": "5.
|
|
88
|
-
"@tanstack/react-query": "5.
|
|
86
|
+
"@tanstack/eslint-plugin-query": "5.100.11",
|
|
87
|
+
"@tanstack/react-query": "5.100.11",
|
|
89
88
|
"@testing-library/dom": "10.4.1",
|
|
90
89
|
"@testing-library/react": "16.3.2",
|
|
91
|
-
"@types/jsdom": "28.0.
|
|
92
|
-
"@types/node": "24.12.
|
|
90
|
+
"@types/jsdom": "28.0.3",
|
|
91
|
+
"@types/node": "24.12.4",
|
|
93
92
|
"@types/react": "19.2.14",
|
|
94
93
|
"@types/react-dom": "19.2.3",
|
|
95
|
-
"@vitest/eslint-plugin": "1.6.
|
|
96
|
-
"eslint": "
|
|
97
|
-
"eslint-plugin-react-hooks": "7.
|
|
98
|
-
"eslint-plugin-testing-library": "7.16.
|
|
94
|
+
"@vitest/eslint-plugin": "1.6.17",
|
|
95
|
+
"eslint": "10.4.0",
|
|
96
|
+
"eslint-plugin-react-hooks": "7.1.1",
|
|
97
|
+
"eslint-plugin-testing-library": "7.16.2",
|
|
99
98
|
"fastify": "4.29.1",
|
|
100
|
-
"globals": "17.
|
|
99
|
+
"globals": "17.6.0",
|
|
101
100
|
"husky": "9.1.7",
|
|
102
|
-
"jsdom": "29.
|
|
103
|
-
"ky": "
|
|
104
|
-
"lint-staged": "
|
|
101
|
+
"jsdom": "29.1.1",
|
|
102
|
+
"ky": "2.0.2",
|
|
103
|
+
"lint-staged": "17.0.5",
|
|
105
104
|
"npm-run-all2": "8.0.4",
|
|
106
|
-
"prettier": "3.8.
|
|
105
|
+
"prettier": "3.8.3",
|
|
107
106
|
"random-access-memory": "6.2.1",
|
|
108
|
-
"react": "19.2.
|
|
109
|
-
"react-dom": "19.2.
|
|
107
|
+
"react": "19.2.6",
|
|
108
|
+
"react-dom": "19.2.6",
|
|
110
109
|
"secret-stream-http": "1.0.1",
|
|
111
|
-
"tsdoc-markdown": "1.
|
|
112
|
-
"tshy": "
|
|
113
|
-
"typescript": "
|
|
114
|
-
"typescript-eslint": "8.
|
|
110
|
+
"tsdoc-markdown": "1.5.0",
|
|
111
|
+
"tshy": "4.1.2",
|
|
112
|
+
"typescript": "6.0.3",
|
|
113
|
+
"typescript-eslint": "8.59.4",
|
|
115
114
|
"uint8array-extras": "1.5.0",
|
|
116
|
-
"vitest": "4.1.
|
|
115
|
+
"vitest": "4.1.6"
|
|
117
116
|
}
|
|
118
117
|
}
|