@ai-matrx/messaging 0.6.0 → 0.7.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 +29 -0
- package/README.md +2 -1
- package/dist/index.cjs +4 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +19 -2
- package/dist/index.d.ts +19 -2
- package/dist/index.js +4 -1
- package/dist/index.js.map +1 -1
- package/dist/react.cjs +4 -1
- package/dist/react.cjs.map +1 -1
- package/dist/react.d.cts +19 -2
- package/dist/react.d.ts +19 -2
- package/dist/react.js +4 -1
- package/dist/react.js.map +1 -1
- package/package.json +3 -3
package/dist/react.cjs
CHANGED
|
@@ -39,6 +39,7 @@ __export(react_exports, {
|
|
|
39
39
|
EmptyState: () => EmptyState,
|
|
40
40
|
LinkIcon: () => LinkIcon,
|
|
41
41
|
MESSAGING_EVENTS: () => MESSAGING_EVENTS,
|
|
42
|
+
MESSAGING_RPC_SCHEMA: () => MESSAGING_RPC_SCHEMA,
|
|
42
43
|
MESSAGING_SCHEMA: () => MESSAGING_SCHEMA,
|
|
43
44
|
MessageActionChips: () => MessageActionChips,
|
|
44
45
|
MessageBubble: () => MessageBubble,
|
|
@@ -1448,6 +1449,7 @@ function createReadCache(options) {
|
|
|
1448
1449
|
|
|
1449
1450
|
// src/core/repository.ts
|
|
1450
1451
|
var MESSAGING_SCHEMA = "communication";
|
|
1452
|
+
var MESSAGING_RPC_SCHEMA = "public";
|
|
1451
1453
|
var TABLES = {
|
|
1452
1454
|
conversations: "dm_conversations",
|
|
1453
1455
|
participants: "dm_conversation_participants",
|
|
@@ -1482,6 +1484,7 @@ function createMessagingRepository(options) {
|
|
|
1482
1484
|
...options.now !== void 0 ? { now: options.now } : {}
|
|
1483
1485
|
});
|
|
1484
1486
|
const db = () => client.schema(MESSAGING_SCHEMA);
|
|
1487
|
+
const rpcDb = () => client.schema(MESSAGING_RPC_SCHEMA);
|
|
1485
1488
|
async function withSessionRetry(operation, run) {
|
|
1486
1489
|
try {
|
|
1487
1490
|
return await run();
|
|
@@ -1499,7 +1502,7 @@ function createMessagingRepository(options) {
|
|
|
1499
1502
|
}
|
|
1500
1503
|
}
|
|
1501
1504
|
async function rpc(fn, args, operation) {
|
|
1502
|
-
const { data, error } = await
|
|
1505
|
+
const { data, error } = await rpcDb().rpc(fn, args);
|
|
1503
1506
|
if (error !== null) throw normalizeMessagingError(error, operation);
|
|
1504
1507
|
return data;
|
|
1505
1508
|
}
|