@inditextech/weave-store-azure-web-pubsub 0.2.0 → 0.3.0
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/client.cjs +1075 -46
- package/dist/client.d.cts +60 -21
- package/dist/client.d.ts +61 -22
- package/dist/client.js +1010 -3
- package/dist/server.cjs +1059 -30
- package/dist/server.d.cts +36 -1
- package/dist/server.d.ts +36 -1
- package/dist/server.js +1009 -2
- package/package.json +6 -5
- package/dist/awareness-CJH5s1Gv.cjs +0 -1153
- package/dist/awareness-CZbSemWr.js +0 -1010
- package/dist/types.d-BjiC_a5v.d.cts +0 -38
- package/dist/types.d-Cw5mafrL.d.ts +0 -38
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
import * as Y from "yjs";
|
|
2
|
-
|
|
3
|
-
//#region src/constants.d.ts
|
|
4
|
-
declare const WEAVE_STORE_AZURE_WEB_PUBSUB = "store-azure-web-pubsub";
|
|
5
|
-
declare const WEAVE_STORE_AZURE_WEB_PUBSUB_CONNECTION_STATUS: {
|
|
6
|
-
readonly "CONNECTED": "connected";
|
|
7
|
-
readonly "DISCONNECTED": "disconnected";
|
|
8
|
-
};
|
|
9
|
-
|
|
10
|
-
//#endregion
|
|
11
|
-
//#region src/types.d.ts
|
|
12
|
-
type WeaveStoreAzureWebPubsubConnectionStatusKeys = keyof typeof WEAVE_STORE_AZURE_WEB_PUBSUB_CONNECTION_STATUS;
|
|
13
|
-
type WeaveStoreAzureWebPubsubConnectionStatus = (typeof WEAVE_STORE_AZURE_WEB_PUBSUB_CONNECTION_STATUS)[WeaveStoreAzureWebPubsubConnectionStatusKeys];
|
|
14
|
-
type WeaveAzureWebPubsubConfig = {
|
|
15
|
-
endpoint: string;
|
|
16
|
-
key: string;
|
|
17
|
-
hubName: string;
|
|
18
|
-
};
|
|
19
|
-
type WeaveStoreAzureWebPubsubOptions = {
|
|
20
|
-
roomId: string;
|
|
21
|
-
url: string;
|
|
22
|
-
fetchClient?: FetchClient;
|
|
23
|
-
callbacks?: WeaveStoreAzureWebPubsubStoreCallbacks;
|
|
24
|
-
};
|
|
25
|
-
type WeaveStoreAzureWebPubsubStoreCallbacks = {
|
|
26
|
-
onFetchConnectionUrl?: (payload: {
|
|
27
|
-
loading: boolean;
|
|
28
|
-
error: Error | null;
|
|
29
|
-
}) => void;
|
|
30
|
-
onConnectionStatusChange?: (status: WeaveStoreAzureWebPubsubConnectionStatus) => void;
|
|
31
|
-
};
|
|
32
|
-
type FetchClient = (input: string | URL | globalThis.Request, init?: RequestInit) => Promise<Response>;
|
|
33
|
-
type FetchInitialState = (doc: Y.Doc) => void;
|
|
34
|
-
type PersistRoom = (roomId: string, actualState: Uint8Array<ArrayBufferLike>) => Promise<void>;
|
|
35
|
-
type FetchRoom = (roomId: string) => Promise<Uint8Array | null>;
|
|
36
|
-
|
|
37
|
-
//#endregion
|
|
38
|
-
export { FetchClient, FetchInitialState, FetchRoom, PersistRoom, WEAVE_STORE_AZURE_WEB_PUBSUB, WEAVE_STORE_AZURE_WEB_PUBSUB_CONNECTION_STATUS, WeaveAzureWebPubsubConfig, WeaveStoreAzureWebPubsubConnectionStatus, WeaveStoreAzureWebPubsubConnectionStatusKeys, WeaveStoreAzureWebPubsubOptions, WeaveStoreAzureWebPubsubStoreCallbacks };
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
import * as Y from "yjs";
|
|
2
|
-
|
|
3
|
-
//#region src/constants.d.ts
|
|
4
|
-
declare const WEAVE_STORE_AZURE_WEB_PUBSUB = "store-azure-web-pubsub";
|
|
5
|
-
declare const WEAVE_STORE_AZURE_WEB_PUBSUB_CONNECTION_STATUS: {
|
|
6
|
-
readonly "CONNECTED": "connected";
|
|
7
|
-
readonly "DISCONNECTED": "disconnected";
|
|
8
|
-
};
|
|
9
|
-
|
|
10
|
-
//#endregion
|
|
11
|
-
//#region src/types.d.ts
|
|
12
|
-
type WeaveStoreAzureWebPubsubConnectionStatusKeys = keyof typeof WEAVE_STORE_AZURE_WEB_PUBSUB_CONNECTION_STATUS;
|
|
13
|
-
type WeaveStoreAzureWebPubsubConnectionStatus = (typeof WEAVE_STORE_AZURE_WEB_PUBSUB_CONNECTION_STATUS)[WeaveStoreAzureWebPubsubConnectionStatusKeys];
|
|
14
|
-
type WeaveAzureWebPubsubConfig = {
|
|
15
|
-
endpoint: string;
|
|
16
|
-
key: string;
|
|
17
|
-
hubName: string;
|
|
18
|
-
};
|
|
19
|
-
type WeaveStoreAzureWebPubsubOptions = {
|
|
20
|
-
roomId: string;
|
|
21
|
-
url: string;
|
|
22
|
-
fetchClient?: FetchClient;
|
|
23
|
-
callbacks?: WeaveStoreAzureWebPubsubStoreCallbacks;
|
|
24
|
-
};
|
|
25
|
-
type WeaveStoreAzureWebPubsubStoreCallbacks = {
|
|
26
|
-
onFetchConnectionUrl?: (payload: {
|
|
27
|
-
loading: boolean;
|
|
28
|
-
error: Error | null;
|
|
29
|
-
}) => void;
|
|
30
|
-
onConnectionStatusChange?: (status: WeaveStoreAzureWebPubsubConnectionStatus) => void;
|
|
31
|
-
};
|
|
32
|
-
type FetchClient = (input: string | URL | globalThis.Request, init?: RequestInit) => Promise<Response>;
|
|
33
|
-
type FetchInitialState = (doc: Y.Doc) => void;
|
|
34
|
-
type PersistRoom = (roomId: string, actualState: Uint8Array<ArrayBufferLike>) => Promise<void>;
|
|
35
|
-
type FetchRoom = (roomId: string) => Promise<Uint8Array | null>;
|
|
36
|
-
|
|
37
|
-
//#endregion
|
|
38
|
-
export { FetchClient, FetchInitialState, FetchRoom, PersistRoom, WEAVE_STORE_AZURE_WEB_PUBSUB as WEAVE_STORE_AZURE_WEB_PUBSUB$1, WEAVE_STORE_AZURE_WEB_PUBSUB_CONNECTION_STATUS as WEAVE_STORE_AZURE_WEB_PUBSUB_CONNECTION_STATUS$1, WeaveAzureWebPubsubConfig, WeaveStoreAzureWebPubsubConnectionStatus, WeaveStoreAzureWebPubsubConnectionStatusKeys, WeaveStoreAzureWebPubsubOptions, WeaveStoreAzureWebPubsubStoreCallbacks };
|