@graphrefly/graphrefly 0.10.0 → 0.12.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/{chunk-QTZSBQGJ.js → chunk-4F2ZFD5L.js} +19 -1
- package/dist/chunk-4F2ZFD5L.js.map +1 -0
- package/dist/{chunk-LR2CLSEF.js → chunk-6OLNYOGU.js} +2 -3
- package/dist/chunk-6OLNYOGU.js.map +1 -0
- package/dist/{chunk-TZLX4KIT.js → chunk-BRPCN2HJ.js} +46 -17
- package/dist/chunk-BRPCN2HJ.js.map +1 -0
- package/dist/{chunk-A2AJJOSJ.js → chunk-IXTW3BIO.js} +3 -3
- package/dist/{chunk-XCZPGOVP.js → chunk-JYRHO63K.js} +3 -3
- package/dist/{chunk-UCW3VWMN.js → chunk-NULSP7U4.js} +4 -4
- package/dist/{chunk-WYI7YW54.js → chunk-VQWLA6XQ.js} +3 -3
- package/dist/{chunk-YWTP2XRJ.js → chunk-X732W3QA.js} +2 -2
- package/dist/{chunk-E7OH6ZAZ.js → chunk-XWMTVV2D.js} +62 -3
- package/dist/chunk-XWMTVV2D.js.map +1 -0
- package/dist/compat/nestjs/index.cjs +10 -1
- package/dist/compat/nestjs/index.cjs.map +1 -1
- package/dist/compat/nestjs/index.d.cts +4 -4
- package/dist/compat/nestjs/index.d.ts +4 -4
- package/dist/compat/nestjs/index.js +7 -7
- package/dist/core/index.cjs +74 -1
- package/dist/core/index.cjs.map +1 -1
- package/dist/core/index.d.cts +2 -2
- package/dist/core/index.d.ts +2 -2
- package/dist/core/index.js +12 -3
- package/dist/extra/index.cjs +52 -14
- package/dist/extra/index.cjs.map +1 -1
- package/dist/extra/index.d.cts +4 -4
- package/dist/extra/index.d.ts +4 -4
- package/dist/extra/index.js +5 -5
- package/dist/graph/index.cjs +10 -1
- package/dist/graph/index.cjs.map +1 -1
- package/dist/graph/index.d.cts +3 -3
- package/dist/graph/index.d.ts +3 -3
- package/dist/graph/index.js +4 -4
- package/dist/{graph-DqTICAY2.d.cts → graph-BE10ujU9.d.cts} +1 -1
- package/dist/{graph-X9uwnD_z.d.ts → graph-DXT95WZ3.d.ts} +1 -1
- package/dist/{index-DLO8wnYU.d.ts → index-53cDGX7F.d.ts} +3 -3
- package/dist/{index-DMv1Etbi.d.ts → index-B10Q0sQB.d.ts} +2 -2
- package/dist/{index-BPCeYDS4.d.ts → index-C0_7g9sj.d.ts} +1 -1
- package/dist/{index-3U0WxdD-.d.cts → index-CCvzN5GB.d.cts} +2 -2
- package/dist/{index-BP1t_38S.d.cts → index-CiAqgfFg.d.ts} +17 -13
- package/dist/{index-a5gHmH5b.d.ts → index-CthwPnHQ.d.cts} +17 -13
- package/dist/{index-BVG5pjin.d.ts → index-Dzdm20sx.d.ts} +88 -3
- package/dist/{index-BYEgosAX.d.cts → index-QfbXNW1N.d.cts} +88 -3
- package/dist/{index-BYa2YMat.d.cts → index-aBZ2RoP0.d.cts} +3 -3
- package/dist/{index-DbwgQ4Cw.d.cts → index-nRulwTr-.d.cts} +1 -1
- package/dist/index.cjs +1084 -118
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +422 -22
- package/dist/index.d.ts +422 -22
- package/dist/index.js +988 -120
- package/dist/index.js.map +1 -1
- package/dist/{meta-BJEU8fYz.d.cts → meta-BcuDhtwu.d.cts} +33 -1
- package/dist/{meta-BJEU8fYz.d.ts → meta-BcuDhtwu.d.ts} +33 -1
- package/dist/patterns/reactive-layout/index.cjs +10 -1
- package/dist/patterns/reactive-layout/index.cjs.map +1 -1
- package/dist/patterns/reactive-layout/index.d.cts +3 -3
- package/dist/patterns/reactive-layout/index.d.ts +3 -3
- package/dist/patterns/reactive-layout/index.js +4 -4
- package/dist/{reactive-log-RhgIog2Z.d.ts → reactive-log-Cu0VdqkT.d.ts} +2 -2
- package/dist/{reactive-log-BfX6bOSZ.d.cts → reactive-log-OULQssZg.d.cts} +2 -2
- package/package.json +7 -2
- package/dist/chunk-E7OH6ZAZ.js.map +0 -1
- package/dist/chunk-LR2CLSEF.js.map +0 -1
- package/dist/chunk-QTZSBQGJ.js.map +0 -1
- package/dist/chunk-TZLX4KIT.js.map +0 -1
- /package/dist/{chunk-A2AJJOSJ.js.map → chunk-IXTW3BIO.js.map} +0 -0
- /package/dist/{chunk-XCZPGOVP.js.map → chunk-JYRHO63K.js.map} +0 -0
- /package/dist/{chunk-UCW3VWMN.js.map → chunk-NULSP7U4.js.map} +0 -0
- /package/dist/{chunk-WYI7YW54.js.map → chunk-VQWLA6XQ.js.map} +0 -0
- /package/dist/{chunk-YWTP2XRJ.js.map → chunk-X732W3QA.js.map} +0 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export { o as observeGraph$, c as observeNode$, t as toMessages$, d as toObservable } from '../../reactive-log-
|
|
2
|
-
export { A as ACTOR_KEY, a as ActorExtractor, C as COMMAND_HANDLERS, b as CQRS_EVENT_HANDLERS, d as CRON_HANDLERS, e as CommandHandler, f as CommandHandlerMeta, E as EVENT_HANDLERS, g as EventHandler, h as EventHandlerMeta, G as GRAPHREFLY_REQUEST_GRAPH, j as GRAPHREFLY_ROOT_GRAPH, k as GraphCron, l as GraphCronMeta, m as GraphInterval, n as GraphIntervalMeta, o as GraphReflyCqrsOptions, p as GraphReflyEventExplorer, q as GraphReflyFeatureOptions, r as GraphReflyGuard, s as GraphReflyGuardImpl, t as GraphReflyModule, u as GraphReflyRootOptions, I as INTERVAL_HANDLERS, v as InjectCqrsGraph, w as InjectGraph, x as InjectNode, O as ObserveGateway, y as ObserveGatewayOptions, z as ObserveSSEOptions, B as ObserveSubscriptionOptions, D as ObserveWsCommand, F as ObserveWsMessage, H as OnGraphEvent, J as OnGraphEventMeta, Q as QUERY_HANDLERS, K as QueryHandler, L as QueryHandlerMeta, S as SAGA_HANDLERS, M as SagaHandler, N as SagaHandlerMeta, P as fromHeader, R as fromJwtPayload, T as getActor, U as getGraphToken, V as getNodeToken, W as observeSSE, X as observeSubscription } from '../../index-
|
|
1
|
+
export { o as observeGraph$, c as observeNode$, t as toMessages$, d as toObservable } from '../../reactive-log-OULQssZg.cjs';
|
|
2
|
+
export { A as ACTOR_KEY, a as ActorExtractor, C as COMMAND_HANDLERS, b as CQRS_EVENT_HANDLERS, d as CRON_HANDLERS, e as CommandHandler, f as CommandHandlerMeta, E as EVENT_HANDLERS, g as EventHandler, h as EventHandlerMeta, G as GRAPHREFLY_REQUEST_GRAPH, j as GRAPHREFLY_ROOT_GRAPH, k as GraphCron, l as GraphCronMeta, m as GraphInterval, n as GraphIntervalMeta, o as GraphReflyCqrsOptions, p as GraphReflyEventExplorer, q as GraphReflyFeatureOptions, r as GraphReflyGuard, s as GraphReflyGuardImpl, t as GraphReflyModule, u as GraphReflyRootOptions, I as INTERVAL_HANDLERS, v as InjectCqrsGraph, w as InjectGraph, x as InjectNode, O as ObserveGateway, y as ObserveGatewayOptions, z as ObserveSSEOptions, B as ObserveSubscriptionOptions, D as ObserveWsCommand, F as ObserveWsMessage, H as OnGraphEvent, J as OnGraphEventMeta, Q as QUERY_HANDLERS, K as QueryHandler, L as QueryHandlerMeta, S as SAGA_HANDLERS, M as SagaHandler, N as SagaHandlerMeta, P as fromHeader, R as fromJwtPayload, T as getActor, U as getGraphToken, V as getNodeToken, W as observeSSE, X as observeSubscription } from '../../index-aBZ2RoP0.cjs';
|
|
3
3
|
import 'rxjs';
|
|
4
|
-
import '../../meta-
|
|
5
|
-
import '../../graph-
|
|
4
|
+
import '../../meta-BcuDhtwu.cjs';
|
|
5
|
+
import '../../graph-BE10ujU9.cjs';
|
|
6
6
|
import '@nestjs/common';
|
|
7
7
|
import '@nestjs/core';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export { o as observeGraph$, c as observeNode$, t as toMessages$, d as toObservable } from '../../reactive-log-
|
|
2
|
-
export { A as ACTOR_KEY, a as ActorExtractor, C as COMMAND_HANDLERS, b as CQRS_EVENT_HANDLERS, d as CRON_HANDLERS, e as CommandHandler, f as CommandHandlerMeta, E as EVENT_HANDLERS, g as EventHandler, h as EventHandlerMeta, G as GRAPHREFLY_REQUEST_GRAPH, j as GRAPHREFLY_ROOT_GRAPH, k as GraphCron, l as GraphCronMeta, m as GraphInterval, n as GraphIntervalMeta, o as GraphReflyCqrsOptions, p as GraphReflyEventExplorer, q as GraphReflyFeatureOptions, r as GraphReflyGuard, s as GraphReflyGuardImpl, t as GraphReflyModule, u as GraphReflyRootOptions, I as INTERVAL_HANDLERS, v as InjectCqrsGraph, w as InjectGraph, x as InjectNode, O as ObserveGateway, y as ObserveGatewayOptions, z as ObserveSSEOptions, B as ObserveSubscriptionOptions, D as ObserveWsCommand, F as ObserveWsMessage, H as OnGraphEvent, J as OnGraphEventMeta, Q as QUERY_HANDLERS, K as QueryHandler, L as QueryHandlerMeta, S as SAGA_HANDLERS, M as SagaHandler, N as SagaHandlerMeta, P as fromHeader, R as fromJwtPayload, T as getActor, U as getGraphToken, V as getNodeToken, W as observeSSE, X as observeSubscription } from '../../index-
|
|
1
|
+
export { o as observeGraph$, c as observeNode$, t as toMessages$, d as toObservable } from '../../reactive-log-Cu0VdqkT.js';
|
|
2
|
+
export { A as ACTOR_KEY, a as ActorExtractor, C as COMMAND_HANDLERS, b as CQRS_EVENT_HANDLERS, d as CRON_HANDLERS, e as CommandHandler, f as CommandHandlerMeta, E as EVENT_HANDLERS, g as EventHandler, h as EventHandlerMeta, G as GRAPHREFLY_REQUEST_GRAPH, j as GRAPHREFLY_ROOT_GRAPH, k as GraphCron, l as GraphCronMeta, m as GraphInterval, n as GraphIntervalMeta, o as GraphReflyCqrsOptions, p as GraphReflyEventExplorer, q as GraphReflyFeatureOptions, r as GraphReflyGuard, s as GraphReflyGuardImpl, t as GraphReflyModule, u as GraphReflyRootOptions, I as INTERVAL_HANDLERS, v as InjectCqrsGraph, w as InjectGraph, x as InjectNode, O as ObserveGateway, y as ObserveGatewayOptions, z as ObserveSSEOptions, B as ObserveSubscriptionOptions, D as ObserveWsCommand, F as ObserveWsMessage, H as OnGraphEvent, J as OnGraphEventMeta, Q as QUERY_HANDLERS, K as QueryHandler, L as QueryHandlerMeta, S as SAGA_HANDLERS, M as SagaHandler, N as SagaHandlerMeta, P as fromHeader, R as fromJwtPayload, T as getActor, U as getGraphToken, V as getNodeToken, W as observeSSE, X as observeSubscription } from '../../index-53cDGX7F.js';
|
|
3
3
|
import 'rxjs';
|
|
4
|
-
import '../../meta-
|
|
5
|
-
import '../../graph-
|
|
4
|
+
import '../../meta-BcuDhtwu.js';
|
|
5
|
+
import '../../graph-DXT95WZ3.js';
|
|
6
6
|
import '@nestjs/common';
|
|
7
7
|
import '@nestjs/core';
|
|
@@ -31,19 +31,19 @@ import {
|
|
|
31
31
|
getNodeToken,
|
|
32
32
|
observeSSE,
|
|
33
33
|
observeSubscription
|
|
34
|
-
} from "../../chunk-
|
|
35
|
-
import "../../chunk-
|
|
34
|
+
} from "../../chunk-NULSP7U4.js";
|
|
35
|
+
import "../../chunk-XWMTVV2D.js";
|
|
36
|
+
import "../../chunk-IXTW3BIO.js";
|
|
36
37
|
import {
|
|
37
38
|
observeGraph$,
|
|
38
39
|
observeNode$,
|
|
39
40
|
toMessages$,
|
|
40
41
|
toObservable
|
|
41
|
-
} from "../../chunk-
|
|
42
|
+
} from "../../chunk-X732W3QA.js";
|
|
42
43
|
import "../../chunk-WZ2Z2CRV.js";
|
|
43
|
-
import "../../chunk-
|
|
44
|
-
import "../../chunk-
|
|
45
|
-
import "../../chunk-
|
|
46
|
-
import "../../chunk-QTZSBQGJ.js";
|
|
44
|
+
import "../../chunk-VQWLA6XQ.js";
|
|
45
|
+
import "../../chunk-6OLNYOGU.js";
|
|
46
|
+
import "../../chunk-4F2ZFD5L.js";
|
|
47
47
|
export {
|
|
48
48
|
ACTOR_KEY,
|
|
49
49
|
COMMAND_HANDLERS,
|
package/dist/core/index.cjs
CHANGED
|
@@ -20,9 +20,11 @@ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: tru
|
|
|
20
20
|
// src/core/index.ts
|
|
21
21
|
var core_exports = {};
|
|
22
22
|
__export(core_exports, {
|
|
23
|
+
CLEANUP_RESULT: () => CLEANUP_RESULT,
|
|
23
24
|
COMPLETE: () => COMPLETE,
|
|
24
25
|
DATA: () => DATA,
|
|
25
26
|
DEFAULT_ACTOR: () => DEFAULT_ACTOR,
|
|
27
|
+
DEFAULT_DOWN: () => DEFAULT_DOWN,
|
|
26
28
|
DIRTY: () => DIRTY,
|
|
27
29
|
DynamicNodeImpl: () => DynamicNodeImpl,
|
|
28
30
|
ERROR: () => ERROR,
|
|
@@ -36,6 +38,8 @@ __export(core_exports, {
|
|
|
36
38
|
accessHintForGuard: () => accessHintForGuard,
|
|
37
39
|
advanceVersion: () => advanceVersion,
|
|
38
40
|
batch: () => batch,
|
|
41
|
+
bridge: () => bridge,
|
|
42
|
+
cleanupResult: () => cleanupResult,
|
|
39
43
|
createVersioning: () => createVersioning,
|
|
40
44
|
defaultHash: () => defaultHash,
|
|
41
45
|
derived: () => derived,
|
|
@@ -464,6 +468,7 @@ function isV1(info) {
|
|
|
464
468
|
|
|
465
469
|
// src/core/node.ts
|
|
466
470
|
var NO_VALUE = /* @__PURE__ */ Symbol.for("graphrefly/NO_VALUE");
|
|
471
|
+
var CLEANUP_RESULT = /* @__PURE__ */ Symbol.for("graphrefly/CLEANUP_RESULT");
|
|
467
472
|
function createIntBitSet() {
|
|
468
473
|
let bits = 0;
|
|
469
474
|
return {
|
|
@@ -526,6 +531,12 @@ function createBitSet(size) {
|
|
|
526
531
|
}
|
|
527
532
|
var isNodeArray = (value) => Array.isArray(value);
|
|
528
533
|
var isNodeOptions = (value) => typeof value === "object" && value != null && !Array.isArray(value);
|
|
534
|
+
function cleanupResult(cleanup, ...args) {
|
|
535
|
+
const r = { [CLEANUP_RESULT]: true, cleanup };
|
|
536
|
+
if (args.length > 0) r.value = args[0];
|
|
537
|
+
return r;
|
|
538
|
+
}
|
|
539
|
+
var isCleanupResult = (value) => typeof value === "object" && value !== null && CLEANUP_RESULT in value;
|
|
529
540
|
var isCleanupFn = (value) => typeof value === "function";
|
|
530
541
|
var statusAfterMessage = (status, msg) => {
|
|
531
542
|
const t = msg[0];
|
|
@@ -941,6 +952,14 @@ var NodeImpl = class {
|
|
|
941
952
|
this._lastDepValues = depValues;
|
|
942
953
|
this._inspectorHook?.({ kind: "run", depValues });
|
|
943
954
|
const out = this._fn(depValues, this._actions);
|
|
955
|
+
if (isCleanupResult(out)) {
|
|
956
|
+
this._cleanup = out.cleanup;
|
|
957
|
+
if (this._manualEmitUsed) return;
|
|
958
|
+
if ("value" in out) {
|
|
959
|
+
this._emitAutoValue(out.value);
|
|
960
|
+
}
|
|
961
|
+
return;
|
|
962
|
+
}
|
|
944
963
|
if (isCleanupFn(out)) {
|
|
945
964
|
this._cleanup = out;
|
|
946
965
|
return;
|
|
@@ -1098,6 +1117,57 @@ function node(depsOrFn, fnOrOpts, optsArg) {
|
|
|
1098
1117
|
return new NodeImpl(deps, fn, opts);
|
|
1099
1118
|
}
|
|
1100
1119
|
|
|
1120
|
+
// src/core/bridge.ts
|
|
1121
|
+
var DEFAULT_DOWN = [
|
|
1122
|
+
DATA,
|
|
1123
|
+
DIRTY,
|
|
1124
|
+
RESOLVED,
|
|
1125
|
+
COMPLETE,
|
|
1126
|
+
ERROR,
|
|
1127
|
+
TEARDOWN,
|
|
1128
|
+
PAUSE,
|
|
1129
|
+
RESUME,
|
|
1130
|
+
INVALIDATE
|
|
1131
|
+
];
|
|
1132
|
+
var STANDARD_TYPES = /* @__PURE__ */ new Set([
|
|
1133
|
+
DATA,
|
|
1134
|
+
DIRTY,
|
|
1135
|
+
RESOLVED,
|
|
1136
|
+
COMPLETE,
|
|
1137
|
+
ERROR,
|
|
1138
|
+
TEARDOWN,
|
|
1139
|
+
PAUSE,
|
|
1140
|
+
RESUME,
|
|
1141
|
+
INVALIDATE
|
|
1142
|
+
]);
|
|
1143
|
+
function bridge(from, to, opts) {
|
|
1144
|
+
const allowedDown = new Set(opts?.down ?? DEFAULT_DOWN);
|
|
1145
|
+
const onMessage = (msg, _depIndex, _actions) => {
|
|
1146
|
+
const type = msg[0];
|
|
1147
|
+
if (!STANDARD_TYPES.has(type)) {
|
|
1148
|
+
to.down([msg]);
|
|
1149
|
+
return true;
|
|
1150
|
+
}
|
|
1151
|
+
if (type === COMPLETE || type === ERROR) {
|
|
1152
|
+
if (allowedDown.has(type)) {
|
|
1153
|
+
to.down([msg]);
|
|
1154
|
+
}
|
|
1155
|
+
return false;
|
|
1156
|
+
}
|
|
1157
|
+
if (!allowedDown.has(type)) {
|
|
1158
|
+
return true;
|
|
1159
|
+
}
|
|
1160
|
+
to.down([msg]);
|
|
1161
|
+
return true;
|
|
1162
|
+
};
|
|
1163
|
+
return node([from], void 0, {
|
|
1164
|
+
name: opts?.name,
|
|
1165
|
+
describeKind: "effect",
|
|
1166
|
+
onMessage,
|
|
1167
|
+
meta: { _internal: true }
|
|
1168
|
+
});
|
|
1169
|
+
}
|
|
1170
|
+
|
|
1101
1171
|
// src/core/dynamic-node.ts
|
|
1102
1172
|
function dynamicNode(fn, opts) {
|
|
1103
1173
|
return new DynamicNodeImpl(fn, opts ?? {});
|
|
@@ -1578,7 +1648,6 @@ function resolveDescribeFields(detail, fields) {
|
|
|
1578
1648
|
case "full":
|
|
1579
1649
|
return null;
|
|
1580
1650
|
// null = include everything
|
|
1581
|
-
case "minimal":
|
|
1582
1651
|
default:
|
|
1583
1652
|
return /* @__PURE__ */ new Set(["type", "deps"]);
|
|
1584
1653
|
}
|
|
@@ -1713,9 +1782,11 @@ var ResettableTimer = class {
|
|
|
1713
1782
|
};
|
|
1714
1783
|
// Annotate the CommonJS export names for ESM import in node:
|
|
1715
1784
|
0 && (module.exports = {
|
|
1785
|
+
CLEANUP_RESULT,
|
|
1716
1786
|
COMPLETE,
|
|
1717
1787
|
DATA,
|
|
1718
1788
|
DEFAULT_ACTOR,
|
|
1789
|
+
DEFAULT_DOWN,
|
|
1719
1790
|
DIRTY,
|
|
1720
1791
|
DynamicNodeImpl,
|
|
1721
1792
|
ERROR,
|
|
@@ -1729,6 +1800,8 @@ var ResettableTimer = class {
|
|
|
1729
1800
|
accessHintForGuard,
|
|
1730
1801
|
advanceVersion,
|
|
1731
1802
|
batch,
|
|
1803
|
+
bridge,
|
|
1804
|
+
cleanupResult,
|
|
1732
1805
|
createVersioning,
|
|
1733
1806
|
defaultHash,
|
|
1734
1807
|
derived,
|