@voltro/plugin-presence 0.32.0 → 0.34.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/CHANGELOG.md +2006 -0
- package/README.md +1 -1
- package/dist/index.d.ts +72 -71
- package/dist/index.js +132 -144
- package/dist/rpc.d.ts +16 -1
- package/dist/rpc.js +10 -10
- package/dist/web.d.ts +0 -1
- package/package.json +6 -6
package/dist/rpc.js
CHANGED
|
@@ -1,15 +1,14 @@
|
|
|
1
1
|
import { PresenceKeyMissing as e, PresenceStoreUnavailable as t } from "./errors.js";
|
|
2
2
|
import { Schema as n } from "effect";
|
|
3
|
-
import { defineMutation as r, defineQuery as i } from "@voltro/protocol";
|
|
3
|
+
import { defineMutation as r, defineQuery as i, reactivityChannel as a } from "@voltro/protocol";
|
|
4
4
|
//#region src/rpc.ts
|
|
5
|
-
var a = n.Struct({
|
|
5
|
+
var o = a("presence"), s = n.Struct({
|
|
6
6
|
key: n.String,
|
|
7
7
|
meta: n.NullOr(n.Record({
|
|
8
8
|
key: n.String,
|
|
9
9
|
value: n.Unknown
|
|
10
|
-
}))
|
|
11
|
-
|
|
12
|
-
}), o = r({
|
|
10
|
+
}))
|
|
11
|
+
}), c = r({
|
|
13
12
|
name: "presence.heartbeat",
|
|
14
13
|
input: n.Struct({
|
|
15
14
|
channel: n.String,
|
|
@@ -21,12 +20,13 @@ var a = n.Struct({
|
|
|
21
20
|
}),
|
|
22
21
|
output: n.Struct({ ok: n.Boolean }),
|
|
23
22
|
error: n.Union(e, t)
|
|
24
|
-
}),
|
|
23
|
+
}), l = i({
|
|
25
24
|
name: "presence.list",
|
|
25
|
+
source: o,
|
|
26
26
|
input: n.Struct({ channel: n.String }),
|
|
27
|
-
output: n.Array(
|
|
27
|
+
output: n.Array(s),
|
|
28
28
|
error: t
|
|
29
|
-
}),
|
|
29
|
+
}), u = r({
|
|
30
30
|
name: "presence.leave",
|
|
31
31
|
input: n.Struct({
|
|
32
32
|
channel: n.String,
|
|
@@ -34,7 +34,7 @@ var a = n.Struct({
|
|
|
34
34
|
}),
|
|
35
35
|
output: n.Struct({ ok: n.Boolean }),
|
|
36
36
|
error: n.Union(e, t)
|
|
37
|
-
}),
|
|
37
|
+
}), d = [
|
|
38
38
|
{
|
|
39
39
|
tag: "presence.heartbeat",
|
|
40
40
|
kind: "mutation",
|
|
@@ -61,4 +61,4 @@ var a = n.Struct({
|
|
|
61
61
|
}
|
|
62
62
|
];
|
|
63
63
|
//#endregion
|
|
64
|
-
export {
|
|
64
|
+
export { c as heartbeatDescriptor, u as leaveDescriptor, l as listDescriptor, o as presenceRoster, d as presenceRpcClientImports };
|
package/dist/web.d.ts
CHANGED
|
@@ -5,7 +5,6 @@ export declare const activeTypers: (members: ReadonlyArray<PresenceMember>, self
|
|
|
5
5
|
export declare interface PresenceMember {
|
|
6
6
|
readonly key: string;
|
|
7
7
|
readonly meta: Record<string, unknown> | null;
|
|
8
|
-
readonly lastSeen: number;
|
|
9
8
|
}
|
|
10
9
|
|
|
11
10
|
export declare interface TypingState {
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@voltro/plugin-presence",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"description": "Ephemeral realtime presence — who is online in a channel, with heartbeat + live roster + per-member metadata (cursor, status).
|
|
3
|
+
"version": "0.34.0",
|
|
4
|
+
"description": "Ephemeral realtime presence — who is online in a channel, with heartbeat + live roster + per-member metadata (cursor, status). Held in memory, owner-partitioned; cross-instance with @voltro/plugin-broadcast.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"voltro",
|
|
7
7
|
"typescript",
|
|
@@ -37,7 +37,8 @@
|
|
|
37
37
|
"types": "./dist/rpc.d.ts",
|
|
38
38
|
"import": "./dist/rpc.js",
|
|
39
39
|
"default": "./dist/rpc.js"
|
|
40
|
-
}
|
|
40
|
+
},
|
|
41
|
+
"./package.json": "./package.json"
|
|
41
42
|
},
|
|
42
43
|
"main": "./dist/index.js",
|
|
43
44
|
"module": "./dist/index.js",
|
|
@@ -47,9 +48,8 @@
|
|
|
47
48
|
"node": ">=24.0.0"
|
|
48
49
|
},
|
|
49
50
|
"dependencies": {
|
|
50
|
-
"@voltro/client": "0.
|
|
51
|
-
"@voltro/
|
|
52
|
-
"@voltro/protocol": "0.32.0"
|
|
51
|
+
"@voltro/client": "0.34.0",
|
|
52
|
+
"@voltro/protocol": "0.34.0"
|
|
53
53
|
},
|
|
54
54
|
"peerDependencies": {
|
|
55
55
|
"effect": "^3.22.0",
|