@ixo/editor 5.19.0 → 5.20.0-experimental.1
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-TZBRXBBJ.mjs → chunk-IALS3KWH.mjs} +2483 -5088
- package/dist/chunk-IALS3KWH.mjs.map +1 -0
- package/dist/chunk-OK2W66I7.mjs +1 -0
- package/dist/chunk-OK2W66I7.mjs.map +1 -0
- package/dist/{chunk-67477PYU.mjs → chunk-XGQRYGA3.mjs} +1200 -217
- package/dist/chunk-XGQRYGA3.mjs.map +1 -0
- package/dist/core/index.d.ts +57 -45
- package/dist/core/index.mjs +3 -4
- package/dist/core/index.mjs.map +1 -1
- package/dist/{graphql-client-xxQMIQzo.d.ts → graphql-client-Dhxgv06u.d.ts} +1 -1
- package/dist/{index-BoRWeiDg.d.ts → index-DMNPdv6v.d.ts} +112 -2
- package/dist/index.d.ts +3 -3
- package/dist/index.mjs +3 -3
- package/dist/index.mjs.map +1 -1
- package/dist/mantine/index.d.ts +3 -3
- package/dist/mantine/index.mjs +2 -2
- package/dist/{store-DZobLMG3.d.ts → store-Bx5ezUFS.d.ts} +76 -67
- package/package.json +1 -1
- package/dist/chunk-67477PYU.mjs.map +0 -1
- package/dist/chunk-K4YAG7AQ.mjs +0 -63
- package/dist/chunk-K4YAG7AQ.mjs.map +0 -1
- package/dist/chunk-TZBRXBBJ.mjs.map +0 -1
package/dist/core/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { a5 as ActionDefinition, a6 as ActionServices, Z as FlowAgentCommand, $ as FlowAgentContext, _ as FlowAgentCommandResult, a0 as FlowAgentExecutor, a2 as FlowAgentNodeSnapshot, a7 as FlowAgentBlockerCause, a3 as FlowAgentPublicNodeState } from '../store-
|
|
2
|
-
export { aj as AcquireFlowAgentLeaseParams, a9 as ActionContext, aa as ActionResult, ax as ActorConstraint, A as AuthorizationResult, B as BaseUcanFlow, X as BuildFlowAgentContextParams, aA as CompiledBlock, aB as CompiledEdge, v as CompiledFlow, aC as CompiledFlowNode, C as CompilerRegistry, aw as ConditionRef, ak as CreateAgentCommandParams, al as EvaluateFlowAgentPolicyParams, E as ExecuteNodeParams, f as ExecutionContext, d as ExecutionOutcome, Y as FlowAgentActor, ao as FlowAgentCommandBase, ap as FlowAgentCommandStatus, aq as FlowAgentCommandType, a1 as FlowAgentLease, ar as FlowAgentLedgerEvent, as as FlowAgentLedgerEventType, at as FlowAgentMaps, am as FlowAgentOrchestratorOptions, au as FlowAgentPolicyDecision, av as FlowAgentRunPhase, x as FlowAgentService, an as FlowAgentServiceOptions, a4 as FlowAgentTickResult, u as FlowCapability, F as FlowRuntimeStateManager, w as FlowStrategy, M as MergeResult, N as NodeActionResult, ab as OutputSchemaField, R as ReadFlowOptions, q as ReadFlowResult, az as RuntimeRef, S as SetupFlowOptions, p as SetupFlowResult, ay as TTLConstraint, aD as TriggerSpec, y as acquireFlowAgentLease, z as appendAgentLedgerEvent, a as buildAuthzFromProps, D as buildFlowAgentContext, b as buildFlowNodeFromBlock, ac as canMatches, G as cleanupExpiredFlowAgentLeases, a8 as clearRuntimeForTemplateClone, l as compileBaseUcanFlow, ad as computeAgentCommandId, H as createAgentCommand, c as createRuntimeStateManager, o as decompileToBaseUcanFlow, I as evaluateFlowAgentPolicy, e as executeNode, J as executeQueuedAgentCommands, k as getActiveEditor, K as getFlowAgentMaps, i as isAuthorized, ae as isCapabilityMatch, af as isExternalMutation, aE as isRuntimeRef, n as mergeCompiledFlows, L as planRalphLoopCommands, O as queueAgentCommand, P as readAgentLedgerEvents, m as readCompiledFlowFromYDoc, h as readFlow, r as readFlowAsBaseUcan, g as readFlowFromEditor, Q as readQueuedAgentCommands, T as releaseFlowAgentLease, ag as requiredCapabilityForCommand, ah as resourceMatches, j as setActiveEditor, s as setupFlowFromBaseUcan, U as tickFlowAgent, ai as updateAgentCommand, V as validateAgentCommand, W as validateFlowAgentLease } from '../store-
|
|
3
|
-
import {
|
|
4
|
-
export {
|
|
1
|
+
import { a5 as ActionDefinition, a6 as ActionServices, Z as FlowAgentCommand, $ as FlowAgentContext, _ as FlowAgentCommandResult, a0 as FlowAgentExecutor, a2 as FlowAgentNodeSnapshot, a7 as FlowAgentBlockerCause, a3 as FlowAgentPublicNodeState } from '../store-Bx5ezUFS.mjs';
|
|
2
|
+
export { aj as AcquireFlowAgentLeaseParams, a9 as ActionContext, aa as ActionResult, ax as ActorConstraint, A as AuthorizationResult, B as BaseUcanFlow, X as BuildFlowAgentContextParams, aA as CompiledBlock, aB as CompiledEdge, v as CompiledFlow, aC as CompiledFlowNode, C as CompilerRegistry, aw as ConditionRef, ak as CreateAgentCommandParams, al as EvaluateFlowAgentPolicyParams, E as ExecuteNodeParams, f as ExecutionContext, d as ExecutionOutcome, Y as FlowAgentActor, ao as FlowAgentCommandBase, ap as FlowAgentCommandStatus, aq as FlowAgentCommandType, a1 as FlowAgentLease, ar as FlowAgentLedgerEvent, as as FlowAgentLedgerEventType, at as FlowAgentMaps, am as FlowAgentOrchestratorOptions, au as FlowAgentPolicyDecision, av as FlowAgentRunPhase, x as FlowAgentService, an as FlowAgentServiceOptions, a4 as FlowAgentTickResult, u as FlowCapability, F as FlowRuntimeStateManager, w as FlowStrategy, M as MergeResult, N as NodeActionResult, ab as OutputSchemaField, R as ReadFlowOptions, q as ReadFlowResult, az as RuntimeRef, S as SetupFlowOptions, p as SetupFlowResult, ay as TTLConstraint, aD as TriggerSpec, y as acquireFlowAgentLease, z as appendAgentLedgerEvent, a as buildAuthzFromProps, D as buildFlowAgentContext, b as buildFlowNodeFromBlock, ac as canMatches, G as cleanupExpiredFlowAgentLeases, a8 as clearRuntimeForTemplateClone, l as compileBaseUcanFlow, ad as computeAgentCommandId, H as createAgentCommand, c as createRuntimeStateManager, o as decompileToBaseUcanFlow, I as evaluateFlowAgentPolicy, e as executeNode, J as executeQueuedAgentCommands, k as getActiveEditor, K as getFlowAgentMaps, i as isAuthorized, ae as isCapabilityMatch, af as isExternalMutation, aE as isRuntimeRef, n as mergeCompiledFlows, L as planRalphLoopCommands, O as queueAgentCommand, P as readAgentLedgerEvents, m as readCompiledFlowFromYDoc, h as readFlow, r as readFlowAsBaseUcan, g as readFlowFromEditor, Q as readQueuedAgentCommands, T as releaseFlowAgentLease, ag as requiredCapabilityForCommand, ah as resourceMatches, j as setActiveEditor, s as setupFlowFromBaseUcan, U as tickFlowAgent, ai as updateAgentCommand, V as validateAgentCommand, W as validateFlowAgentLease } from '../store-Bx5ezUFS.mjs';
|
|
3
|
+
import { a4 as IxoEditorType, f as UcanService, U as UcanDelegationStore, S as StoredDelegation, I as InvocationStore, a5 as FlowNodeRuntimeState, a6 as FlowMetadata, a7 as FlowNode } from '../index-DMNPdv6v.mjs';
|
|
4
|
+
export { af as ActionReadBackMetadata, a9 as ClaimCollectionURI, am as CreateDelegationParams, an as CreateInvocationParams, al as CreateRootDelegationParams, a8 as DID, D as DelegationChainValidationResult, k as DelegationGrant, aa as EvaluationStatus, aj as ExecutionWithInvocationResult, ak as FindProofsResult, ac as FlowNodeAuthzExtension, ag as FlowNodeBase, ah as InvocationRequest, ai as InvocationResult, ab as LinkedClaim, ad as NodeState, ae as ReadBackTerminalState, j as StoredInvocation, i as UcanCapability, g as UcanServiceConfig, h as UcanServiceHandlers, b as createInvocationStore, d as createMemoryInvocationStore, a as createMemoryUcanDelegationStore, c as createUcanDelegationStore, e as createUcanService } from '../index-DMNPdv6v.mjs';
|
|
5
5
|
import * as Y from 'yjs';
|
|
6
6
|
import 'matrix-js-sdk';
|
|
7
7
|
import '@blocknote/core';
|
|
@@ -38,6 +38,47 @@ declare function getAllCanMappings(): ReadonlyArray<{
|
|
|
38
38
|
*/
|
|
39
39
|
declare function buildServicesFromHandlers(handlers: any): ActionServices;
|
|
40
40
|
|
|
41
|
+
/**
|
|
42
|
+
* Context passed to resolveRuntimeRefs when resolving inputs for a triggered
|
|
43
|
+
* listener block. The runtime constructs this from a PendingInvocation when
|
|
44
|
+
* the assignee invokes the listener.
|
|
45
|
+
*
|
|
46
|
+
* - `payload`: the frozen event payload, used to resolve `trigger.payload.*` refs
|
|
47
|
+
* - `refSnapshots`: frozen `nodeId.output.*` values captured at queue time,
|
|
48
|
+
* used to resolve those refs against the moment of emission rather than
|
|
49
|
+
* current state. See docs/events-and-triggers-plan.md §3.5.1 for the
|
|
50
|
+
* Sally → Mike scenario this fixes.
|
|
51
|
+
*/
|
|
52
|
+
interface TriggerResolutionContext {
|
|
53
|
+
payload: Record<string, unknown>;
|
|
54
|
+
refSnapshots: Record<string, unknown>;
|
|
55
|
+
}
|
|
56
|
+
/**
|
|
57
|
+
* Resolve runtime references in an nb (caveats) object.
|
|
58
|
+
*
|
|
59
|
+
* At compile time, `{ "$ref": "nodeId.output.fieldPath" }` values are serialized
|
|
60
|
+
* as-is into the block's `inputs` JSON string. At execution time, this function
|
|
61
|
+
* replaces them with actual output values from upstream nodes.
|
|
62
|
+
*
|
|
63
|
+
* Two ref namespaces are supported:
|
|
64
|
+
* - `nodeId.output.fieldPath` — looked up via `getNodeOutput`. When a
|
|
65
|
+
* `triggerContext` is provided AND `refSnapshots[ref]` exists, the
|
|
66
|
+
* snapshot is preferred over the live lookup. This is the load-bearing
|
|
67
|
+
* fix for the lag-time scenario where multiple pending invocations are
|
|
68
|
+
* queued and the source block re-runs before the assignee acts on them.
|
|
69
|
+
* - `trigger.payload.fieldPath` — looked up in `triggerContext.payload`.
|
|
70
|
+
* Only valid when `triggerContext` is provided (i.e. resolving inputs
|
|
71
|
+
* for a triggered listener invocation). Compile-time validation in
|
|
72
|
+
* compiler.ts guarantees these only appear on `block.event`-triggered
|
|
73
|
+
* blocks.
|
|
74
|
+
*
|
|
75
|
+
* @param nb - The caveats object (may contain nested RuntimeRef values)
|
|
76
|
+
* @param getNodeOutput - Lookup function for upstream node outputs
|
|
77
|
+
* @param triggerContext - Optional, present only for triggered listener invocations
|
|
78
|
+
* @returns A new object with all $ref values resolved
|
|
79
|
+
*/
|
|
80
|
+
declare function resolveRuntimeRefs(nb: Record<string, unknown>, getNodeOutput: (nodeId: string) => Record<string, unknown> | undefined, triggerContext?: TriggerResolutionContext): Record<string, unknown>;
|
|
81
|
+
|
|
41
82
|
/**
|
|
42
83
|
* Run record stored in the audit trail as `type: 'block.run'`.
|
|
43
84
|
*
|
|
@@ -68,11 +109,19 @@ interface RunRecordDetails {
|
|
|
68
109
|
completedAt: string;
|
|
69
110
|
/** DID of the actor who signed the invocation that produced this run. */
|
|
70
111
|
actorDid: string;
|
|
112
|
+
/** UCAN invocation CID when execution produced one. */
|
|
113
|
+
invocationCid?: string;
|
|
114
|
+
/** Capability/proof CID used when no invocation CID was produced. */
|
|
115
|
+
capabilityId?: string;
|
|
71
116
|
/** Optional error if the run failed. */
|
|
72
117
|
error?: {
|
|
73
118
|
message: string;
|
|
74
119
|
code?: string;
|
|
75
120
|
};
|
|
121
|
+
/** External read-back metadata associated with this run or reconciliation. */
|
|
122
|
+
readBack?: Record<string, unknown>;
|
|
123
|
+
/** True when this audit entry was written by external read-back reconciliation. */
|
|
124
|
+
reconciled?: boolean;
|
|
76
125
|
/**
|
|
77
126
|
* If this run was triggered by a pending invocation (i.e. it's a listener
|
|
78
127
|
* run), the id of that pending invocation. Used to dedup replays and trace
|
|
@@ -88,6 +137,8 @@ interface RunRecordDetails {
|
|
|
88
137
|
sourceBlockId: string;
|
|
89
138
|
eventName: string;
|
|
90
139
|
};
|
|
140
|
+
/** Source run id for listener runs, stored explicitly for failure lookups. */
|
|
141
|
+
sourceRunId?: string;
|
|
91
142
|
}
|
|
92
143
|
declare const RUN_RECORD_AUDIT_TYPE = "block.run";
|
|
93
144
|
/**
|
|
@@ -289,57 +340,18 @@ declare function writeRunRecordAndReconcile(editor: IxoEditorType, blockId: stri
|
|
|
289
340
|
sourceRunId?: string;
|
|
290
341
|
}): void;
|
|
291
342
|
|
|
292
|
-
/**
|
|
293
|
-
* Context passed to resolveRuntimeRefs when resolving inputs for a triggered
|
|
294
|
-
* listener block. The runtime constructs this from a PendingInvocation when
|
|
295
|
-
* the assignee invokes the listener.
|
|
296
|
-
*
|
|
297
|
-
* - `payload`: the frozen event payload, used to resolve `trigger.payload.*` refs
|
|
298
|
-
* - `refSnapshots`: frozen `nodeId.output.*` values captured at queue time,
|
|
299
|
-
* used to resolve those refs against the moment of emission rather than
|
|
300
|
-
* current state. See docs/events-and-triggers-plan.md §3.5.1 for the
|
|
301
|
-
* Sally → Mike scenario this fixes.
|
|
302
|
-
*/
|
|
303
|
-
interface TriggerResolutionContext {
|
|
304
|
-
payload: Record<string, unknown>;
|
|
305
|
-
refSnapshots: Record<string, unknown>;
|
|
306
|
-
}
|
|
307
|
-
/**
|
|
308
|
-
* Resolve runtime references in an nb (caveats) object.
|
|
309
|
-
*
|
|
310
|
-
* At compile time, `{ "$ref": "nodeId.output.fieldPath" }` values are serialized
|
|
311
|
-
* as-is into the block's `inputs` JSON string. At execution time, this function
|
|
312
|
-
* replaces them with actual output values from upstream nodes.
|
|
313
|
-
*
|
|
314
|
-
* Two ref namespaces are supported:
|
|
315
|
-
* - `nodeId.output.fieldPath` — looked up via `getNodeOutput`. When a
|
|
316
|
-
* `triggerContext` is provided AND `refSnapshots[ref]` exists, the
|
|
317
|
-
* snapshot is preferred over the live lookup. This is the load-bearing
|
|
318
|
-
* fix for the lag-time scenario where multiple pending invocations are
|
|
319
|
-
* queued and the source block re-runs before the assignee acts on them.
|
|
320
|
-
* - `trigger.payload.fieldPath` — looked up in `triggerContext.payload`.
|
|
321
|
-
* Only valid when `triggerContext` is provided (i.e. resolving inputs
|
|
322
|
-
* for a triggered listener invocation). Compile-time validation in
|
|
323
|
-
* compiler.ts guarantees these only appear on `block.event`-triggered
|
|
324
|
-
* blocks.
|
|
325
|
-
*
|
|
326
|
-
* @param nb - The caveats object (may contain nested RuntimeRef values)
|
|
327
|
-
* @param getNodeOutput - Lookup function for upstream node outputs
|
|
328
|
-
* @param triggerContext - Optional, present only for triggered listener invocations
|
|
329
|
-
* @returns A new object with all $ref values resolved
|
|
330
|
-
*/
|
|
331
|
-
declare function resolveRuntimeRefs(nb: Record<string, unknown>, getNodeOutput: (nodeId: string) => Record<string, unknown> | undefined, triggerContext?: TriggerResolutionContext): Record<string, unknown>;
|
|
332
|
-
|
|
333
343
|
interface ExecuteFlowAgentCoreCommandOptions {
|
|
334
344
|
ucanService: UcanService;
|
|
335
345
|
pin: string;
|
|
336
346
|
actorType: 'entity' | 'user';
|
|
337
347
|
entityRoomId?: string;
|
|
338
348
|
actionServices?: ActionServices;
|
|
349
|
+
actionHandlers?: unknown;
|
|
339
350
|
delegationStore?: UcanDelegationStore;
|
|
340
351
|
delegations?: StoredDelegation[];
|
|
341
352
|
invocationStore?: InvocationStore;
|
|
342
353
|
leaseTtlMs?: number;
|
|
354
|
+
flowOwnerDid?: string;
|
|
343
355
|
schemaVersion?: string;
|
|
344
356
|
now?: () => number;
|
|
345
357
|
}
|
package/dist/core/index.mjs
CHANGED
|
@@ -1,6 +1,4 @@
|
|
|
1
|
-
import
|
|
2
|
-
resolveRuntimeRefs
|
|
3
|
-
} from "../chunk-K4YAG7AQ.mjs";
|
|
1
|
+
import "../chunk-OK2W66I7.mjs";
|
|
4
2
|
import {
|
|
5
3
|
FlowAgentService,
|
|
6
4
|
RUN_RECORD_AUDIT_TYPE,
|
|
@@ -66,6 +64,7 @@ import {
|
|
|
66
64
|
removePendingInvocation,
|
|
67
65
|
replayFailedListenerRun,
|
|
68
66
|
requiredCapabilityForCommand,
|
|
67
|
+
resolveRuntimeRefs,
|
|
69
68
|
resourceMatches,
|
|
70
69
|
setActiveEditor,
|
|
71
70
|
setupFlowFromBaseUcan,
|
|
@@ -77,7 +76,7 @@ import {
|
|
|
77
76
|
validateAgentCommand,
|
|
78
77
|
validateFlowAgentLease,
|
|
79
78
|
writeRunRecordAndReconcile
|
|
80
|
-
} from "../chunk-
|
|
79
|
+
} from "../chunk-XGQRYGA3.mjs";
|
|
81
80
|
import {
|
|
82
81
|
computeCID,
|
|
83
82
|
computeJsonCID
|
package/dist/core/index.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/core/templates/oracleInitFlow.ts"],"sourcesContent":["import type { FlowMetadata } from '../types/editor';\nimport type { FlowNode } from '../types/authorization';\n\n// ---------------------------------------------------------------------------\n// SurveyJS schema for the oracle configuration form\n// ---------------------------------------------------------------------------\n\nexport const oracleInitSurveySchema = {\n title: 'Oracle Configuration',\n description: 'Provide the details needed to initialise a new oracle on the IXO network.',\n logoPosition: 'right',\n pages: [\n {\n name: 'basicInfo',\n title: 'Basic Information',\n elements: [\n {\n type: 'text',\n name: 'projectName',\n title: 'Project Name',\n description: 'Used as the folder name — no spaces or special characters.',\n isRequired: true,\n validators: [\n {\n type: 'regex',\n text: 'Only lowercase letters, numbers, and hyphens are allowed (no spaces or special characters).',\n regex: '^[a-z0-9]+(-[a-z0-9]+)*$',\n },\n ],\n },\n {\n type: 'text',\n name: 'pin',\n title: 'PIN',\n description: 'A 6-digit PIN used to secure wallet operations.',\n isRequired: true,\n inputType: 'password',\n maxLength: 6,\n validators: [\n {\n type: 'regex',\n text: 'PIN must be exactly 6 digits.',\n regex: '^\\\\d{6}$',\n },\n ],\n },\n ],\n },\n {\n name: 'oracleDetails',\n title: 'Oracle Details',\n elements: [\n {\n type: 'text',\n name: 'oracleName',\n title: 'Oracle Name',\n isRequired: true,\n },\n {\n type: 'text',\n name: 'orgName',\n title: 'Organisation Name',\n isRequired: true,\n },\n {\n type: 'comment',\n name: 'description',\n title: 'Description',\n isRequired: true,\n },\n {\n type: 'text',\n name: 'location',\n title: 'Location',\n isRequired: true,\n },\n {\n type: 'text',\n name: 'logoUrl',\n title: 'Logo URL',\n isRequired: true,\n inputType: 'url',\n validators: [{ type: 'url' }],\n },\n {\n type: 'text',\n name: 'coverImageUrl',\n title: 'Cover Image URL',\n isRequired: true,\n inputType: 'url',\n validators: [{ type: 'url' }],\n },\n ],\n },\n {\n name: 'serviceConfig',\n title: 'Service Configuration',\n elements: [\n {\n type: 'text',\n name: 'apiUrl',\n title: 'API URL',\n isRequired: true,\n inputType: 'url',\n defaultValue: 'http://localhost:4000',\n validators: [{ type: 'url' }],\n },\n {\n type: 'text',\n name: 'price',\n title: 'Price',\n description: 'Service price in IXO tokens (minimum 1).',\n isRequired: true,\n inputType: 'number',\n defaultValue: 100,\n validators: [\n {\n type: 'numeric',\n text: 'Price must be at least 1.',\n minValue: 1,\n },\n ],\n },\n {\n type: 'dropdown',\n name: 'llmModel',\n title: 'LLM Model',\n isRequired: true,\n choices: [\n { value: 'kimi-k2.5', text: 'Kimi K2.5' },\n { value: 'claude-sonnet', text: 'Claude Sonnet' },\n { value: 'gpt-4o', text: 'GPT-4o' },\n { value: 'gemini-2.5', text: 'Gemini 2.5' },\n { value: 'llama-4', text: 'Llama 4' },\n { value: 'custom', text: 'Custom' },\n ],\n },\n {\n type: 'comment',\n name: 'opening',\n title: 'Opening Message',\n description: 'The greeting or introduction the agent uses when starting a conversation.',\n isRequired: false,\n },\n {\n type: 'comment',\n name: 'communicationStyle',\n title: 'Communication Style',\n description: 'How the agent should communicate (e.g. formal, friendly, concise).',\n isRequired: false,\n },\n {\n type: 'comment',\n name: 'capabilities',\n title: 'What can the agent do?',\n description: 'Describe what this agent is capable of doing for users.',\n isRequired: false,\n },\n ],\n },\n ],\n};\n\n// ---------------------------------------------------------------------------\n// Template generator\n// ---------------------------------------------------------------------------\n\nexport function createOracleInitFlowTemplate(): {\n metadata: FlowMetadata;\n nodes: FlowNode[];\n} {\n const metadata: FlowMetadata = {\n '@context': 'https://schema.ixo.world/flow/v1',\n _type: 'flow/oracle-init',\n schema_version: '1.0.0',\n doc_id: '',\n title: 'Oracle Init Flow',\n createdAt: new Date().toISOString(),\n createdBy: '',\n flowOwnerDid: '',\n };\n\n const nodes: FlowNode[] = [\n // ------------------------------------------------------------------\n // [1] Form — collects all oracle configuration\n // ------------------------------------------------------------------\n {\n id: 'oracle-form',\n type: 'form',\n props: {\n title: 'Oracle Configuration',\n description: 'Enter the details for your new oracle.',\n icon: 'checklist',\n surveySchema: JSON.stringify(oracleInitSurveySchema),\n },\n },\n\n // ------------------------------------------------------------------\n // [2] Skills — skill/MCP configuration\n // ------------------------------------------------------------------\n {\n id: 'oracle-skills',\n type: 'skills',\n props: {\n title: 'Oracle Skills & MCP Servers',\n description: 'Configure skills and MCP servers for the oracle.',\n icon: 'tools',\n skills: '[]',\n entityDid: '',\n mcpServers: '[]',\n status: 'pending',\n },\n activationCondition: {\n upstreamNodeId: 'oracle-form',\n requiredStatus: 'approved',\n },\n },\n\n // ------------------------------------------------------------------\n // [3] Action — Generate & Fund Wallet\n // Generates a new wallet and funds it in one step.\n // ------------------------------------------------------------------\n {\n id: 'oracle-wallet',\n type: 'action',\n props: {\n title: 'Generate & Fund Wallet',\n description: 'Generate a new IXO wallet and fund it with tokens.',\n icon: 'bolt',\n actionType: 'qi/wallet.generateAndFund',\n inputs: JSON.stringify({}),\n requiresConfirmation: '',\n },\n activationCondition: {\n upstreamNodeId: 'oracle-skills',\n requiredStatus: 'approved',\n },\n },\n\n // ------------------------------------------------------------------\n // [4] Action — Create Identity (IID + Matrix)\n // Creates the on-chain IID document, then registers the Matrix account.\n // ------------------------------------------------------------------\n {\n id: 'oracle-identity',\n type: 'action',\n props: {\n title: 'Create Identity',\n description: 'Create on-chain DID document and register Matrix account.',\n icon: 'bolt',\n actionType: 'qi/identity.create',\n inputs: JSON.stringify({\n mnemonic: '{{oracle-wallet.output.mnemonic}}',\n did: '{{oracle-wallet.output.did}}',\n address: '{{oracle-wallet.output.address}}',\n pubKey: '{{oracle-wallet.output.pubKey}}',\n formAnswers: '{{oracle-form.output.form.answers}}',\n }),\n requiresConfirmation: '',\n },\n activationCondition: {\n upstreamNodeId: 'oracle-wallet',\n requiredStatus: 'approved',\n },\n },\n\n // ------------------------------------------------------------------\n // [5] Action — Create Oracle Entity\n // On-chain entity creation with P-256 encryption key.\n // ------------------------------------------------------------------\n {\n id: 'oracle-entity-create',\n type: 'action',\n props: {\n title: 'Create Oracle Entity',\n description: 'Create the oracle entity on the IXO network.',\n icon: 'bolt',\n actionType: 'qi/entity.createOracle',\n inputs: JSON.stringify({\n // Wallet outputs\n mnemonic: '{{oracle-wallet.output.mnemonic}}',\n address: '{{oracle-wallet.output.address}}',\n did: '{{oracle-wallet.output.did}}',\n pubKey: '{{oracle-wallet.output.pubKey}}',\n // Matrix outputs (from identity block)\n matrixAccessToken: '{{oracle-identity.output.matrixAccessToken}}',\n matrixRoomId: '{{oracle-identity.output.matrixRoomId}}',\n // Form outputs — whole blob, action parses & destructures\n formAnswers: '{{oracle-form.output.form.answers}}',\n }),\n requiresConfirmation: '',\n },\n activationCondition: {\n upstreamNodeId: 'oracle-identity',\n requiredStatus: 'approved',\n },\n },\n\n // ------------------------------------------------------------------\n // [6] Action — Configure Oracle (contract + secrets + config)\n // Creates the user↔oracle DM room, encrypts secrets, stores config.\n // ------------------------------------------------------------------\n {\n id: 'oracle-configure',\n type: 'action',\n props: {\n title: 'Configure Oracle',\n description: 'Contract oracle, encrypt secrets, and store configuration.',\n icon: 'bolt',\n actionType: 'qi/oracle.configureOracle',\n inputs: JSON.stringify({\n // Contract input\n oracleEntityDid: '{{oracle-entity-create.output.entityDid}}',\n // Secrets routing (matrixRoomId comes from contract phase, not inputs)\n publicKeyMultibase: '{{oracle-entity-create.output.encryptionPublicKeyMultibase}}',\n verificationMethodId: '{{oracle-entity-create.output.encryptionVerificationMethodId}}',\n // Fresh mxLogin params\n matrixHomeServerUrl: '{{oracle-identity.output.matrixHomeServerUrl}}',\n matrixUsername: '{{oracle-identity.output.matrixUserId}}',\n // Sensitive plaintext values\n mnemonic: '{{oracle-wallet.output.mnemonic}}',\n matrixPassword: '{{oracle-identity.output.matrixPassword}}',\n matrixRecoveryPhrase: '{{oracle-identity.output.matrixRecoveryPhrase}}',\n // MCP auth secrets (already JWE-encrypted by skills block FlowDetail)\n mcpAuthSecrets: '{{oracle-skills.output.mcpAuthSecrets}}',\n // Skills outputs\n skills: '{{oracle-skills.output.skills}}',\n mcpServers: '{{oracle-skills.output.mcpServers}}',\n // Identifiers\n matrixUserId: '{{oracle-identity.output.matrixUserId}}',\n matrixAccountRoomId: '{{oracle-identity.output.matrixRoomId}}',\n entityDid: '{{oracle-entity-create.output.entityDid}}',\n oracleAddress: '{{oracle-wallet.output.address}}',\n oracleDid: '{{oracle-wallet.output.did}}',\n // Form outputs — whole blob, action parses & destructures\n formAnswers: '{{oracle-form.output.form.answers}}',\n }),\n requiresConfirmation: '',\n },\n activationCondition: {\n upstreamNodeId: 'oracle-entity-create',\n requiredStatus: 'approved',\n },\n },\n\n // ------------------------------------------------------------------\n // [7] Action — Deploy Oracle (setup + start)\n // Clones repo, writes config, builds, then starts the process.\n // ------------------------------------------------------------------\n {\n id: 'oracle-deploy',\n type: 'action',\n props: {\n title: 'Deploy Oracle',\n description: 'Set up environment and start the oracle process.',\n icon: 'bolt',\n actionType: 'qi/oracle.deploy',\n inputs: JSON.stringify({\n entityDid: '{{oracle-entity-create.output.entityDid}}',\n roomId: '{{oracle-configure.output.userOracleRoomId}}',\n skills: '{{oracle-skills.output.skills}}',\n mcpServers: '{{oracle-skills.output.mcpServers}}',\n mnemonic: '{{oracle-wallet.output.mnemonic}}',\n matrixPassword: '{{oracle-identity.output.matrixPassword}}',\n matrixRecoveryPhrase: '{{oracle-identity.output.matrixRecoveryPhrase}}',\n matrixUsername: '{{oracle-identity.output.matrixUserId}}',\n matrixAccountRoomId: '{{oracle-identity.output.matrixRoomId}}',\n freshAccessToken: '{{oracle-configure.output.freshAccessToken}}',\n openRouterApiKey: '{{oracle-configure.output.openRouterApiKeyPlaintext}}',\n // Form outputs — whole blob, action parses & destructures\n formAnswers: '{{oracle-form.output.form.answers}}',\n }),\n requiresConfirmation: '',\n },\n activationCondition: {\n upstreamNodeId: 'oracle-configure',\n requiredStatus: 'approved',\n },\n },\n\n // ------------------------------------------------------------------\n // [8] Secrets — display credentials and download\n // ------------------------------------------------------------------\n {\n id: 'oracle-secrets',\n type: 'secrets',\n props: {\n title: 'Oracle Credentials',\n description: 'Download your oracle credentials after setup is complete.',\n icon: 'key',\n downloadEndpoint: '',\n entityDid: '{{oracle-entity-create.output.entityDid}}',\n },\n activationCondition: {\n upstreamNodeId: 'oracle-deploy',\n requiredStatus: 'approved',\n },\n },\n ];\n\n return { metadata, nodes };\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAOO,IAAM,yBAAyB;AAAA,EACpC,OAAO;AAAA,EACP,aAAa;AAAA,EACb,cAAc;AAAA,EACd,OAAO;AAAA,IACL;AAAA,MACE,MAAM;AAAA,MACN,OAAO;AAAA,MACP,UAAU;AAAA,QACR;AAAA,UACE,MAAM;AAAA,UACN,MAAM;AAAA,UACN,OAAO;AAAA,UACP,aAAa;AAAA,UACb,YAAY;AAAA,UACZ,YAAY;AAAA,YACV;AAAA,cACE,MAAM;AAAA,cACN,MAAM;AAAA,cACN,OAAO;AAAA,YACT;AAAA,UACF;AAAA,QACF;AAAA,QACA;AAAA,UACE,MAAM;AAAA,UACN,MAAM;AAAA,UACN,OAAO;AAAA,UACP,aAAa;AAAA,UACb,YAAY;AAAA,UACZ,WAAW;AAAA,UACX,WAAW;AAAA,UACX,YAAY;AAAA,YACV;AAAA,cACE,MAAM;AAAA,cACN,MAAM;AAAA,cACN,OAAO;AAAA,YACT;AAAA,UACF;AAAA,QACF;AAAA,MACF;AAAA,IACF;AAAA,IACA;AAAA,MACE,MAAM;AAAA,MACN,OAAO;AAAA,MACP,UAAU;AAAA,QACR;AAAA,UACE,MAAM;AAAA,UACN,MAAM;AAAA,UACN,OAAO;AAAA,UACP,YAAY;AAAA,QACd;AAAA,QACA;AAAA,UACE,MAAM;AAAA,UACN,MAAM;AAAA,UACN,OAAO;AAAA,UACP,YAAY;AAAA,QACd;AAAA,QACA;AAAA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AAA,MACN,OAAO;AAAA,QACL,OAAO;AAAA,QACP,aAAa;AAAA,QACb,MAAM;AAAA,QACN,kBAAkB;AAAA,QAClB,WAAW;AAAA,MACb;AAAA,MACA,qBAAqB;AAAA,QACnB,gBAAgB;AAAA,QAChB,gBAAgB;AAAA,MAClB;AAAA,IACF;AAAA,EACF;AAEA,SAAO,EAAE,UAAU,MAAM;AAC3B;","names":[]}
|
|
1
|
+
{"version":3,"sources":["../../src/core/templates/oracleInitFlow.ts"],"sourcesContent":["import type { FlowMetadata } from '../types/editor';\nimport type { FlowNode } from '../types/authorization';\n\n// ---------------------------------------------------------------------------\n// SurveyJS schema for the oracle configuration form\n// ---------------------------------------------------------------------------\n\nexport const oracleInitSurveySchema = {\n title: 'Oracle Configuration',\n description: 'Provide the details needed to initialise a new oracle on the IXO network.',\n logoPosition: 'right',\n pages: [\n {\n name: 'basicInfo',\n title: 'Basic Information',\n elements: [\n {\n type: 'text',\n name: 'projectName',\n title: 'Project Name',\n description: 'Used as the folder name — no spaces or special characters.',\n isRequired: true,\n validators: [\n {\n type: 'regex',\n text: 'Only lowercase letters, numbers, and hyphens are allowed (no spaces or special characters).',\n regex: '^[a-z0-9]+(-[a-z0-9]+)*$',\n },\n ],\n },\n {\n type: 'text',\n name: 'pin',\n title: 'PIN',\n description: 'A 6-digit PIN used to secure wallet operations.',\n isRequired: true,\n inputType: 'password',\n maxLength: 6,\n validators: [\n {\n type: 'regex',\n text: 'PIN must be exactly 6 digits.',\n regex: '^\\\\d{6}$',\n },\n ],\n },\n ],\n },\n {\n name: 'oracleDetails',\n title: 'Oracle Details',\n elements: [\n {\n type: 'text',\n name: 'oracleName',\n title: 'Oracle Name',\n isRequired: true,\n },\n {\n type: 'text',\n name: 'orgName',\n title: 'Organisation Name',\n isRequired: true,\n },\n {\n type: 'comment',\n name: 'description',\n title: 'Description',\n isRequired: true,\n },\n {\n type: 'text',\n name: 'location',\n title: 'Location',\n isRequired: true,\n },\n {\n type: 'text',\n name: 'logoUrl',\n title: 'Logo URL',\n isRequired: true,\n inputType: 'url',\n validators: [{ type: 'url' }],\n },\n {\n type: 'text',\n name: 'coverImageUrl',\n title: 'Cover Image URL',\n isRequired: true,\n inputType: 'url',\n validators: [{ type: 'url' }],\n },\n ],\n },\n {\n name: 'serviceConfig',\n title: 'Service Configuration',\n elements: [\n {\n type: 'text',\n name: 'apiUrl',\n title: 'API URL',\n isRequired: true,\n inputType: 'url',\n defaultValue: 'http://localhost:4000',\n validators: [{ type: 'url' }],\n },\n {\n type: 'text',\n name: 'price',\n title: 'Price',\n description: 'Service price in IXO tokens (minimum 1).',\n isRequired: true,\n inputType: 'number',\n defaultValue: 100,\n validators: [\n {\n type: 'numeric',\n text: 'Price must be at least 1.',\n minValue: 1,\n },\n ],\n },\n {\n type: 'dropdown',\n name: 'llmModel',\n title: 'LLM Model',\n isRequired: true,\n choices: [\n { value: 'kimi-k2.5', text: 'Kimi K2.5' },\n { value: 'claude-sonnet', text: 'Claude Sonnet' },\n { value: 'gpt-4o', text: 'GPT-4o' },\n { value: 'gemini-2.5', text: 'Gemini 2.5' },\n { value: 'llama-4', text: 'Llama 4' },\n { value: 'custom', text: 'Custom' },\n ],\n },\n {\n type: 'comment',\n name: 'opening',\n title: 'Opening Message',\n description: 'The greeting or introduction the agent uses when starting a conversation.',\n isRequired: false,\n },\n {\n type: 'comment',\n name: 'communicationStyle',\n title: 'Communication Style',\n description: 'How the agent should communicate (e.g. formal, friendly, concise).',\n isRequired: false,\n },\n {\n type: 'comment',\n name: 'capabilities',\n title: 'What can the agent do?',\n description: 'Describe what this agent is capable of doing for users.',\n isRequired: false,\n },\n ],\n },\n ],\n};\n\n// ---------------------------------------------------------------------------\n// Template generator\n// ---------------------------------------------------------------------------\n\nexport function createOracleInitFlowTemplate(): {\n metadata: FlowMetadata;\n nodes: FlowNode[];\n} {\n const metadata: FlowMetadata = {\n '@context': 'https://schema.ixo.world/flow/v1',\n _type: 'flow/oracle-init',\n schema_version: '1.0.0',\n doc_id: '',\n title: 'Oracle Init Flow',\n createdAt: new Date().toISOString(),\n createdBy: '',\n flowOwnerDid: '',\n };\n\n const nodes: FlowNode[] = [\n // ------------------------------------------------------------------\n // [1] Form — collects all oracle configuration\n // ------------------------------------------------------------------\n {\n id: 'oracle-form',\n type: 'form',\n props: {\n title: 'Oracle Configuration',\n description: 'Enter the details for your new oracle.',\n icon: 'checklist',\n surveySchema: JSON.stringify(oracleInitSurveySchema),\n },\n },\n\n // ------------------------------------------------------------------\n // [2] Skills — skill/MCP configuration\n // ------------------------------------------------------------------\n {\n id: 'oracle-skills',\n type: 'skills',\n props: {\n title: 'Oracle Skills & MCP Servers',\n description: 'Configure skills and MCP servers for the oracle.',\n icon: 'tools',\n skills: '[]',\n entityDid: '',\n mcpServers: '[]',\n status: 'pending',\n },\n activationCondition: {\n upstreamNodeId: 'oracle-form',\n requiredStatus: 'approved',\n },\n },\n\n // ------------------------------------------------------------------\n // [3] Action — Generate & Fund Wallet\n // Generates a new wallet and funds it in one step.\n // ------------------------------------------------------------------\n {\n id: 'oracle-wallet',\n type: 'action',\n props: {\n title: 'Generate & Fund Wallet',\n description: 'Generate a new IXO wallet and fund it with tokens.',\n icon: 'bolt',\n actionType: 'qi/wallet.generateAndFund',\n inputs: JSON.stringify({}),\n requiresConfirmation: '',\n },\n activationCondition: {\n upstreamNodeId: 'oracle-skills',\n requiredStatus: 'approved',\n },\n },\n\n // ------------------------------------------------------------------\n // [4] Action — Create Identity (IID + Matrix)\n // Creates the on-chain IID document, then registers the Matrix account.\n // ------------------------------------------------------------------\n {\n id: 'oracle-identity',\n type: 'action',\n props: {\n title: 'Create Identity',\n description: 'Create on-chain DID document and register Matrix account.',\n icon: 'bolt',\n actionType: 'qi/identity.create',\n inputs: JSON.stringify({\n mnemonic: '{{oracle-wallet.output.mnemonic}}',\n did: '{{oracle-wallet.output.did}}',\n address: '{{oracle-wallet.output.address}}',\n pubKey: '{{oracle-wallet.output.pubKey}}',\n formAnswers: '{{oracle-form.output.form.answers}}',\n }),\n requiresConfirmation: '',\n },\n activationCondition: {\n upstreamNodeId: 'oracle-wallet',\n requiredStatus: 'approved',\n },\n },\n\n // ------------------------------------------------------------------\n // [5] Action — Create Oracle Entity\n // On-chain entity creation with P-256 encryption key.\n // ------------------------------------------------------------------\n {\n id: 'oracle-entity-create',\n type: 'action',\n props: {\n title: 'Create Oracle Entity',\n description: 'Create the oracle entity on the IXO network.',\n icon: 'bolt',\n actionType: 'qi/entity.createOracle',\n inputs: JSON.stringify({\n // Wallet outputs\n mnemonic: '{{oracle-wallet.output.mnemonic}}',\n address: '{{oracle-wallet.output.address}}',\n did: '{{oracle-wallet.output.did}}',\n pubKey: '{{oracle-wallet.output.pubKey}}',\n // Matrix outputs (from identity block)\n matrixAccessToken: '{{oracle-identity.output.matrixAccessToken}}',\n matrixRoomId: '{{oracle-identity.output.matrixRoomId}}',\n // Form outputs — whole blob, action parses & destructures\n formAnswers: '{{oracle-form.output.form.answers}}',\n }),\n requiresConfirmation: '',\n },\n activationCondition: {\n upstreamNodeId: 'oracle-identity',\n requiredStatus: 'approved',\n },\n },\n\n // ------------------------------------------------------------------\n // [6] Action — Configure Oracle (contract + secrets + config)\n // Creates the user↔oracle DM room, encrypts secrets, stores config.\n // ------------------------------------------------------------------\n {\n id: 'oracle-configure',\n type: 'action',\n props: {\n title: 'Configure Oracle',\n description: 'Contract oracle, encrypt secrets, and store configuration.',\n icon: 'bolt',\n actionType: 'qi/oracle.configureOracle',\n inputs: JSON.stringify({\n // Contract input\n oracleEntityDid: '{{oracle-entity-create.output.entityDid}}',\n // Secrets routing (matrixRoomId comes from contract phase, not inputs)\n publicKeyMultibase: '{{oracle-entity-create.output.encryptionPublicKeyMultibase}}',\n verificationMethodId: '{{oracle-entity-create.output.encryptionVerificationMethodId}}',\n // Fresh mxLogin params\n matrixHomeServerUrl: '{{oracle-identity.output.matrixHomeServerUrl}}',\n matrixUsername: '{{oracle-identity.output.matrixUserId}}',\n // Sensitive plaintext values\n mnemonic: '{{oracle-wallet.output.mnemonic}}',\n matrixPassword: '{{oracle-identity.output.matrixPassword}}',\n matrixRecoveryPhrase: '{{oracle-identity.output.matrixRecoveryPhrase}}',\n // MCP auth secrets (already JWE-encrypted by skills block FlowDetail)\n mcpAuthSecrets: '{{oracle-skills.output.mcpAuthSecrets}}',\n // Skills outputs\n skills: '{{oracle-skills.output.skills}}',\n mcpServers: '{{oracle-skills.output.mcpServers}}',\n // Identifiers\n matrixUserId: '{{oracle-identity.output.matrixUserId}}',\n matrixAccountRoomId: '{{oracle-identity.output.matrixRoomId}}',\n entityDid: '{{oracle-entity-create.output.entityDid}}',\n oracleAddress: '{{oracle-wallet.output.address}}',\n oracleDid: '{{oracle-wallet.output.did}}',\n // Form outputs — whole blob, action parses & destructures\n formAnswers: '{{oracle-form.output.form.answers}}',\n }),\n requiresConfirmation: '',\n },\n activationCondition: {\n upstreamNodeId: 'oracle-entity-create',\n requiredStatus: 'approved',\n },\n },\n\n // ------------------------------------------------------------------\n // [7] Action — Deploy Oracle (setup + start)\n // Clones repo, writes config, builds, then starts the process.\n // ------------------------------------------------------------------\n {\n id: 'oracle-deploy',\n type: 'action',\n props: {\n title: 'Deploy Oracle',\n description: 'Set up environment and start the oracle process.',\n icon: 'bolt',\n actionType: 'qi/oracle.deploy',\n inputs: JSON.stringify({\n entityDid: '{{oracle-entity-create.output.entityDid}}',\n roomId: '{{oracle-configure.output.userOracleRoomId}}',\n skills: '{{oracle-skills.output.skills}}',\n mcpServers: '{{oracle-skills.output.mcpServers}}',\n mnemonic: '{{oracle-wallet.output.mnemonic}}',\n matrixPassword: '{{oracle-identity.output.matrixPassword}}',\n matrixRecoveryPhrase: '{{oracle-identity.output.matrixRecoveryPhrase}}',\n matrixUsername: '{{oracle-identity.output.matrixUserId}}',\n matrixAccountRoomId: '{{oracle-identity.output.matrixRoomId}}',\n freshAccessToken: '{{oracle-configure.output.freshAccessToken}}',\n openRouterApiKey: '{{oracle-configure.output.openRouterApiKeyPlaintext}}',\n // Form outputs — whole blob, action parses & destructures\n formAnswers: '{{oracle-form.output.form.answers}}',\n }),\n requiresConfirmation: '',\n },\n activationCondition: {\n upstreamNodeId: 'oracle-configure',\n requiredStatus: 'approved',\n },\n },\n\n // ------------------------------------------------------------------\n // [8] Secrets — display credentials and download\n // ------------------------------------------------------------------\n {\n id: 'oracle-secrets',\n type: 'secrets',\n props: {\n title: 'Oracle Credentials',\n description: 'Download your oracle credentials after setup is complete.',\n icon: 'key',\n downloadEndpoint: '',\n entityDid: '{{oracle-entity-create.output.entityDid}}',\n },\n activationCondition: {\n upstreamNodeId: 'oracle-deploy',\n requiredStatus: 'approved',\n },\n },\n ];\n\n return { metadata, nodes };\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAOO,IAAM,yBAAyB;AAAA,EACpC,OAAO;AAAA,EACP,aAAa;AAAA,EACb,cAAc;AAAA,EACd,OAAO;AAAA,IACL;AAAA,MACE,MAAM;AAAA,MACN,OAAO;AAAA,MACP,UAAU;AAAA,QACR;AAAA,UACE,MAAM;AAAA,UACN,MAAM;AAAA,UACN,OAAO;AAAA,UACP,aAAa;AAAA,UACb,YAAY;AAAA,UACZ,YAAY;AAAA,YACV;AAAA,cACE,MAAM;AAAA,cACN,MAAM;AAAA,cACN,OAAO;AAAA,YACT;AAAA,UACF;AAAA,QACF;AAAA,QACA;AAAA,UACE,MAAM;AAAA,UACN,MAAM;AAAA,UACN,OAAO;AAAA,UACP,aAAa;AAAA,UACb,YAAY;AAAA,UACZ,WAAW;AAAA,UACX,WAAW;AAAA,UACX,YAAY;AAAA,YACV;AAAA,cACE,MAAM;AAAA,cACN,MAAM;AAAA,cACN,OAAO;AAAA,YACT;AAAA,UACF;AAAA,QACF;AAAA,MACF;AAAA,IACF;AAAA,IACA;AAAA,MACE,MAAM;AAAA,MACN,OAAO;AAAA,MACP,UAAU;AAA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ACf,CAAC;AAAA,QACD,sBAAsB;AAAA,MACxB;AAAA,MACA,qBAAqB;AAAA,QACnB,gBAAgB;AAAA,QAChB,gBAAgB;AAAA,MAClB;AAAA,IACF;AAAA;AAAA;AAAA;AAAA,IAKA;AAAA,MACE,IAAI;AAAA,MACJ,MAAM;AAAA,MACN,OAAO;AAAA,QACL,OAAO;AAAA,QACP,aAAa;AAAA,QACb,MAAM;AAAA,QACN,kBAAkB;AAAA,QAClB,WAAW;AAAA,MACb;AAAA,MACA,qBAAqB;AAAA,QACnB,gBAAgB;AAAA,QAChB,gBAAgB;AAAA,MAClB;AAAA,IACF;AAAA,EACF;AAEA,SAAO,EAAE,UAAU,MAAM;AAC3B;","names":[]}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as _blocknote_core from '@blocknote/core';
|
|
2
|
-
import {
|
|
2
|
+
import { ao as IxoBlockProps, l as IxoEditorOptions, a4 as IxoEditorType, p as IxoCollaborativeEditorOptions, w as BlocknoteHandlers, y as BlockRequirements, av as UnlMapConfig, ar as DynamicListDataProvider, as as DynamicListPanelRenderer, at as DomainCardRenderer, a3 as Translate, k as DelegationGrant } from './index-DMNPdv6v.mjs';
|
|
3
3
|
import { Text, Doc, Map, Array as Array$1 } from 'yjs';
|
|
4
4
|
import React__default from 'react';
|
|
5
5
|
|
|
@@ -1290,6 +1290,72 @@ interface NotificationResponse {
|
|
|
1290
1290
|
status: 'accepted' | 'rejected';
|
|
1291
1291
|
timestamp: string;
|
|
1292
1292
|
}
|
|
1293
|
+
type ListProtocolDeedsWithTemplatesParams = {
|
|
1294
|
+
entityDid?: string;
|
|
1295
|
+
domainFlowsSubspaceId?: string;
|
|
1296
|
+
includeEmpty?: boolean;
|
|
1297
|
+
};
|
|
1298
|
+
type ProtocolTemplateSummary = {
|
|
1299
|
+
sourceRoomId: string;
|
|
1300
|
+
label: string;
|
|
1301
|
+
path?: string;
|
|
1302
|
+
alreadyImported?: boolean;
|
|
1303
|
+
};
|
|
1304
|
+
type ProtocolDeedWithTemplates = {
|
|
1305
|
+
protocolDid: string;
|
|
1306
|
+
name: string;
|
|
1307
|
+
description?: string;
|
|
1308
|
+
type?: string;
|
|
1309
|
+
owner?: string;
|
|
1310
|
+
templates: ProtocolTemplateSummary[];
|
|
1311
|
+
importedCount?: number;
|
|
1312
|
+
};
|
|
1313
|
+
type ImportProtocolTemplatesToSpaceParams = {
|
|
1314
|
+
protocolDid: string;
|
|
1315
|
+
entityDid: string;
|
|
1316
|
+
targetFlowsSubspaceId: string;
|
|
1317
|
+
templates: {
|
|
1318
|
+
sourceRoomId: string;
|
|
1319
|
+
sourceLabel?: string;
|
|
1320
|
+
}[];
|
|
1321
|
+
};
|
|
1322
|
+
type ImportProtocolTemplateResult = {
|
|
1323
|
+
sourceRoomId: string;
|
|
1324
|
+
newRoomId?: string;
|
|
1325
|
+
status: 'success' | 'error';
|
|
1326
|
+
error?: string;
|
|
1327
|
+
};
|
|
1328
|
+
type MatrixPrivacySettings = {
|
|
1329
|
+
encrypted: boolean;
|
|
1330
|
+
join_rule: 'invite' | 'public' | 'knock' | 'private';
|
|
1331
|
+
history_visibility: 'invited' | 'joined' | 'shared' | 'world_readable';
|
|
1332
|
+
};
|
|
1333
|
+
type MatrixRoom = {
|
|
1334
|
+
roomId: string;
|
|
1335
|
+
roomAlias: string;
|
|
1336
|
+
roomPrivacySettings: MatrixPrivacySettings;
|
|
1337
|
+
};
|
|
1338
|
+
type MatrixSpace = {
|
|
1339
|
+
space_id: string;
|
|
1340
|
+
space_alias: string;
|
|
1341
|
+
privacy: MatrixPrivacySettings;
|
|
1342
|
+
rooms: MatrixRoom[];
|
|
1343
|
+
};
|
|
1344
|
+
type MatrixSubspace = MatrixSpace;
|
|
1345
|
+
type MatrixSpaceStructure = {
|
|
1346
|
+
success: boolean;
|
|
1347
|
+
space_id: string;
|
|
1348
|
+
space_alias: string;
|
|
1349
|
+
privacy: MatrixPrivacySettings;
|
|
1350
|
+
rooms: MatrixRoom[];
|
|
1351
|
+
subspaces: {
|
|
1352
|
+
'domain pods': MatrixSubspace;
|
|
1353
|
+
'domain pages': MatrixSubspace;
|
|
1354
|
+
'domain flows': MatrixSubspace;
|
|
1355
|
+
oracles: MatrixSubspace;
|
|
1356
|
+
community: MatrixSubspace;
|
|
1357
|
+
};
|
|
1358
|
+
};
|
|
1293
1359
|
interface WorkspacePage {
|
|
1294
1360
|
id: string;
|
|
1295
1361
|
type: string;
|
|
@@ -2129,6 +2195,26 @@ interface BlocknoteHandlers {
|
|
|
2129
2195
|
name?: string;
|
|
2130
2196
|
description?: string;
|
|
2131
2197
|
}>>;
|
|
2198
|
+
/**
|
|
2199
|
+
* List protocol deeds and their available flow templates.
|
|
2200
|
+
* Used by host apps to browse protocol templates before importing them into a space.
|
|
2201
|
+
*/
|
|
2202
|
+
listProtocolDeedsWithTemplates?: (params?: ListProtocolDeedsWithTemplatesParams) => Promise<{
|
|
2203
|
+
protocols: ProtocolDeedWithTemplates[];
|
|
2204
|
+
}>;
|
|
2205
|
+
/**
|
|
2206
|
+
* Import selected protocol flow templates into a target flows subspace.
|
|
2207
|
+
*/
|
|
2208
|
+
importProtocolTemplatesToSpace?: (params: ImportProtocolTemplatesToSpaceParams) => Promise<{
|
|
2209
|
+
imported: ImportProtocolTemplateResult[];
|
|
2210
|
+
}>;
|
|
2211
|
+
/**
|
|
2212
|
+
* Source/create the Matrix space structure for a domain entity.
|
|
2213
|
+
* Returns the root space plus standard domain subspaces, including "domain flows".
|
|
2214
|
+
*/
|
|
2215
|
+
sourceDomainSpaces?: (params?: {
|
|
2216
|
+
entityDid?: string;
|
|
2217
|
+
}) => Promise<MatrixSpaceStructure>;
|
|
2132
2218
|
/**
|
|
2133
2219
|
* Create a Cosmos governance group from explicit members and decision policy.
|
|
2134
2220
|
* Used by the POD setup flow after domain entity creation.
|
|
@@ -4515,7 +4601,29 @@ interface LinkedClaim {
|
|
|
4515
4601
|
interface FlowNodeAuthzExtension {
|
|
4516
4602
|
linkedClaim?: LinkedClaim;
|
|
4517
4603
|
}
|
|
4518
|
-
type NodeState = 'idle' | 'running' | 'completed' | 'failed' | 'cancelled';
|
|
4604
|
+
type NodeState = 'idle' | 'running' | 'completed' | 'failed' | 'cancelled' | 'awaiting_readback';
|
|
4605
|
+
type ReadBackTerminalState = 'pending' | 'completed' | 'failed';
|
|
4606
|
+
interface ActionReadBackMetadata {
|
|
4607
|
+
kind: string;
|
|
4608
|
+
status?: ReadBackTerminalState;
|
|
4609
|
+
correlationId?: string;
|
|
4610
|
+
validationSource?: string;
|
|
4611
|
+
requestedAt?: string;
|
|
4612
|
+
lastCheckedAt?: string;
|
|
4613
|
+
terminalAt?: string;
|
|
4614
|
+
blockId?: string;
|
|
4615
|
+
actionType?: string;
|
|
4616
|
+
actorDid?: DID;
|
|
4617
|
+
invocationCid?: string;
|
|
4618
|
+
capabilityId?: string;
|
|
4619
|
+
pendingInvocation?: {
|
|
4620
|
+
id: string;
|
|
4621
|
+
triggeringBlockId: string;
|
|
4622
|
+
eventName: string;
|
|
4623
|
+
sourceRunId?: string;
|
|
4624
|
+
};
|
|
4625
|
+
[key: string]: any;
|
|
4626
|
+
}
|
|
4519
4627
|
interface FlowNodeRuntimeState {
|
|
4520
4628
|
state?: NodeState;
|
|
4521
4629
|
output?: Record<string, any>;
|
|
@@ -4523,6 +4631,8 @@ interface FlowNodeRuntimeState {
|
|
|
4523
4631
|
executedAt?: number;
|
|
4524
4632
|
/** Unix timestamp (ms) when the block first became enabled/activated */
|
|
4525
4633
|
enabledAt?: number;
|
|
4634
|
+
/** Metadata needed to reconcile an externally completed action later. */
|
|
4635
|
+
readBack?: ActionReadBackMetadata;
|
|
4526
4636
|
invocations?: string[];
|
|
4527
4637
|
lastInvocationCid?: string;
|
|
4528
4638
|
assignments?: Array<{
|
|
@@ -5430,4 +5540,4 @@ interface IxoEditorConfig {
|
|
|
5430
5540
|
tableHandles: boolean;
|
|
5431
5541
|
}
|
|
5432
5542
|
|
|
5433
|
-
export { type
|
|
5543
|
+
export { type MatrixRoom as $, AuthzExecActionTypes as A, BlocknoteProvider as B, type VoteResponse as C, type DelegationChainValidationResult as D, type VoteInfo as E, type Vote as F, type User as G, type Addr as H, type InvocationStore as I, type Uint128 as J, type Expiration as K, type Status as L, type Threshold as M, type Votes as N, type CosmosMsgForEmpty as O, type ProposalResponse as P, type ProposalAction as Q, type ListProtocolDeedsWithTemplatesParams as R, type StoredDelegation as S, type Timestamp as T, type UcanDelegationStore as U, ValidatorActionType as V, type ProtocolDeedWithTemplates as W, type ProtocolTemplateSummary as X, type ImportProtocolTemplatesToSpaceParams as Y, type ImportProtocolTemplateResult as Z, type MatrixPrivacySettings as _, createMemoryUcanDelegationStore as a, type MatrixSpace as a0, type MatrixSubspace as a1, type MatrixSpaceStructure as a2, type Translate as a3, type IxoEditorType as a4, type FlowNodeRuntimeState as a5, type FlowMetadata as a6, type FlowNode as a7, type DID as a8, type ClaimCollectionURI as a9, type EvaluationStatus as aa, type LinkedClaim as ab, type FlowNodeAuthzExtension as ac, type NodeState as ad, type ReadBackTerminalState as ae, type ActionReadBackMetadata as af, type FlowNodeBase as ag, type InvocationRequest as ah, type InvocationResult as ai, type ExecutionWithInvocationResult as aj, type FindProofsResult as ak, type CreateRootDelegationParams as al, type CreateDelegationParams as am, type CreateInvocationParams as an, type IxoBlockProps as ao, type VisualizationRenderer as ap, type DynamicListData as aq, type DynamicListDataProvider as ar, type DynamicListPanelRenderer as as, type DomainCardRenderer as at, type DomainCardData as au, type UnlMapConfig as av, createInvocationStore as b, createUcanDelegationStore as c, createMemoryInvocationStore as d, createUcanService as e, type UcanService as f, type UcanServiceConfig as g, type UcanServiceHandlers as h, type UcanCapability as i, type StoredInvocation as j, type DelegationGrant as k, type IxoEditorOptions as l, type IxoEditorTheme as m, type IxoEditorConfig as n, type IxoCollaborativeUser as o, type IxoCollaborativeEditorOptions as p, blockSpecs as q, getExtraSlashMenuItems as r, useBlocknoteHandlers as s, useTranslate as t, useBlocknoteContext as u, StakeType as v, type BlocknoteHandlers as w, type BlocknoteContextValue as x, type BlockRequirements as y, type SingleChoiceProposal as z };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export { n as ApiRequestBlockProps, h as ApiRequestBlockSpec, A as AuthorizationTab, d as AuthorizationTabState, B as BlockPresenceUser, i as CheckboxBlockProps, g as CheckboxBlockSpec, C as CoverImage, c as CoverImageProps, D as DevUcanGrantButton, r as Entity, s as EntityResponse, f as EntitySigningSetup, t as EntityVariables, E as EvaluationTab, e as EvaluationTabState, F as FlowPermissionsPanel, G as GrantPermissionModal, v as GraphQLClient, y as GraphQLRequest, x as GraphQLResponse, H as HttpMethod, I as IxoEditor, b as IxoEditorProps, K as KeyValuePair, k as ListBlockProps, j as ListBlockSettings, L as ListBlockSpec, O as OverviewBlock, l as OverviewBlockProps, m as ProposalBlockProps, P as ProposalBlockSpec, q as getEntity, w as ixoGraphQLClient, o as useBlockPresence, a as useCreateCollaborativeIxoEditor, u as useCreateIxoEditor, p as useTrackBlockFocus } from './graphql-client-
|
|
2
|
-
export { A as AuthorizationResult, B as BaseUcanFlow, X as BuildFlowAgentContextParams, v as CompiledFlow, C as CompilerRegistry, E as ExecuteNodeParams, f as ExecutionContext, d as ExecutionOutcome, Y as FlowAgentActor, Z as FlowAgentCommand, _ as FlowAgentCommandResult, $ as FlowAgentContext, a0 as FlowAgentExecutor, a1 as FlowAgentLease, a2 as FlowAgentNodeSnapshot, a3 as FlowAgentPublicNodeState, x as FlowAgentService, a4 as FlowAgentTickResult, u as FlowCapability, F as FlowRuntimeStateManager, w as FlowStrategy, M as MergeResult, N as NodeActionResult, R as ReadFlowOptions, q as ReadFlowResult, t as ReadableEditor, S as SetupFlowOptions, p as SetupFlowResult, y as acquireFlowAgentLease, z as appendAgentLedgerEvent, a as buildAuthzFromProps, D as buildFlowAgentContext, b as buildFlowNodeFromBlock, G as cleanupExpiredFlowAgentLeases, l as compileBaseUcanFlow, H as createAgentCommand, c as createRuntimeStateManager, o as decompileToBaseUcanFlow, I as evaluateFlowAgentPolicy, e as executeNode, J as executeQueuedAgentCommands, k as getActiveEditor, K as getFlowAgentMaps, i as isAuthorized, n as mergeCompiledFlows, L as planRalphLoopCommands, O as queueAgentCommand, P as readAgentLedgerEvents, m as readCompiledFlowFromYDoc, h as readFlow, r as readFlowAsBaseUcan, g as readFlowFromEditor, Q as readQueuedAgentCommands, T as releaseFlowAgentLease, j as setActiveEditor, s as setupFlowFromBaseUcan, U as tickFlowAgent, V as validateAgentCommand, W as validateFlowAgentLease } from './store-
|
|
3
|
-
export { H as Addr, A as AuthzExecActionTypes, y as BlockRequirements, x as BlocknoteContextValue, w as BlocknoteHandlers, B as BlocknoteProvider, O as CosmosMsgForEmpty, D as DelegationChainValidationResult, k as DelegationGrant, K as Expiration, I as InvocationStore, p as IxoCollaborativeEditorOptions, o as IxoCollaborativeUser, n as IxoEditorConfig, l as IxoEditorOptions, m as IxoEditorTheme, Q as ProposalAction, P as ProposalResponse, z as SingleChoiceProposal, v as StakeType, v as StakeTypeValue, L as Status, S as StoredDelegation, j as StoredInvocation, M as Threshold, T as Timestamp,
|
|
1
|
+
export { n as ApiRequestBlockProps, h as ApiRequestBlockSpec, A as AuthorizationTab, d as AuthorizationTabState, B as BlockPresenceUser, i as CheckboxBlockProps, g as CheckboxBlockSpec, C as CoverImage, c as CoverImageProps, D as DevUcanGrantButton, r as Entity, s as EntityResponse, f as EntitySigningSetup, t as EntityVariables, E as EvaluationTab, e as EvaluationTabState, F as FlowPermissionsPanel, G as GrantPermissionModal, v as GraphQLClient, y as GraphQLRequest, x as GraphQLResponse, H as HttpMethod, I as IxoEditor, b as IxoEditorProps, K as KeyValuePair, k as ListBlockProps, j as ListBlockSettings, L as ListBlockSpec, O as OverviewBlock, l as OverviewBlockProps, m as ProposalBlockProps, P as ProposalBlockSpec, q as getEntity, w as ixoGraphQLClient, o as useBlockPresence, a as useCreateCollaborativeIxoEditor, u as useCreateIxoEditor, p as useTrackBlockFocus } from './graphql-client-Dhxgv06u.mjs';
|
|
2
|
+
export { A as AuthorizationResult, B as BaseUcanFlow, X as BuildFlowAgentContextParams, v as CompiledFlow, C as CompilerRegistry, E as ExecuteNodeParams, f as ExecutionContext, d as ExecutionOutcome, Y as FlowAgentActor, Z as FlowAgentCommand, _ as FlowAgentCommandResult, $ as FlowAgentContext, a0 as FlowAgentExecutor, a1 as FlowAgentLease, a2 as FlowAgentNodeSnapshot, a3 as FlowAgentPublicNodeState, x as FlowAgentService, a4 as FlowAgentTickResult, u as FlowCapability, F as FlowRuntimeStateManager, w as FlowStrategy, M as MergeResult, N as NodeActionResult, R as ReadFlowOptions, q as ReadFlowResult, t as ReadableEditor, S as SetupFlowOptions, p as SetupFlowResult, y as acquireFlowAgentLease, z as appendAgentLedgerEvent, a as buildAuthzFromProps, D as buildFlowAgentContext, b as buildFlowNodeFromBlock, G as cleanupExpiredFlowAgentLeases, l as compileBaseUcanFlow, H as createAgentCommand, c as createRuntimeStateManager, o as decompileToBaseUcanFlow, I as evaluateFlowAgentPolicy, e as executeNode, J as executeQueuedAgentCommands, k as getActiveEditor, K as getFlowAgentMaps, i as isAuthorized, n as mergeCompiledFlows, L as planRalphLoopCommands, O as queueAgentCommand, P as readAgentLedgerEvents, m as readCompiledFlowFromYDoc, h as readFlow, r as readFlowAsBaseUcan, g as readFlowFromEditor, Q as readQueuedAgentCommands, T as releaseFlowAgentLease, j as setActiveEditor, s as setupFlowFromBaseUcan, U as tickFlowAgent, V as validateAgentCommand, W as validateFlowAgentLease } from './store-Bx5ezUFS.mjs';
|
|
3
|
+
export { H as Addr, A as AuthzExecActionTypes, y as BlockRequirements, x as BlocknoteContextValue, w as BlocknoteHandlers, B as BlocknoteProvider, O as CosmosMsgForEmpty, D as DelegationChainValidationResult, k as DelegationGrant, K as Expiration, Z as ImportProtocolTemplateResult, Y as ImportProtocolTemplatesToSpaceParams, I as InvocationStore, p as IxoCollaborativeEditorOptions, o as IxoCollaborativeUser, n as IxoEditorConfig, l as IxoEditorOptions, m as IxoEditorTheme, R as ListProtocolDeedsWithTemplatesParams, _ as MatrixPrivacySettings, $ as MatrixRoom, a0 as MatrixSpace, a2 as MatrixSpaceStructure, a1 as MatrixSubspace, Q as ProposalAction, P as ProposalResponse, W as ProtocolDeedWithTemplates, X as ProtocolTemplateSummary, z as SingleChoiceProposal, v as StakeType, v as StakeTypeValue, L as Status, S as StoredDelegation, j as StoredInvocation, M as Threshold, T as Timestamp, a3 as Translate, i as UcanCapability, U as UcanDelegationStore, f as UcanService, g as UcanServiceConfig, h as UcanServiceHandlers, J as Uint128, G as User, V as ValidatorActionType, F as Vote, E as VoteInfo, C as VoteResponse, N as Votes, q as blockSpecs, b as createInvocationStore, d as createMemoryInvocationStore, a as createMemoryUcanDelegationStore, c as createUcanDelegationStore, e as createUcanService, r as getExtraSlashMenuItems, u as useBlocknoteContext, s as useBlocknoteHandlers, t as useTranslate } from './index-DMNPdv6v.mjs';
|
|
4
4
|
export { Block, BlockNoteEditor, BlockNoteSchema, DefaultBlockSchema, DefaultInlineContentSchema, DefaultStyleSchema, PartialBlock } from '@blocknote/core';
|
|
5
5
|
export { CloneDocumentResult, cloneDocument } from '@ixo/matrix-crdt';
|
|
6
6
|
import 'yjs';
|
package/dist/index.mjs
CHANGED
|
@@ -28,8 +28,8 @@ import {
|
|
|
28
28
|
useCreateIxoEditor,
|
|
29
29
|
useTrackBlockFocus,
|
|
30
30
|
useTranslate
|
|
31
|
-
} from "./chunk-
|
|
32
|
-
import "./chunk-
|
|
31
|
+
} from "./chunk-IALS3KWH.mjs";
|
|
32
|
+
import "./chunk-OK2W66I7.mjs";
|
|
33
33
|
import {
|
|
34
34
|
FlowAgentService,
|
|
35
35
|
acquireFlowAgentLease,
|
|
@@ -68,7 +68,7 @@ import {
|
|
|
68
68
|
tickFlowAgent,
|
|
69
69
|
validateAgentCommand,
|
|
70
70
|
validateFlowAgentLease
|
|
71
|
-
} from "./chunk-
|
|
71
|
+
} from "./chunk-XGQRYGA3.mjs";
|
|
72
72
|
|
|
73
73
|
// src/index.ts
|
|
74
74
|
import { cloneDocument } from "@ixo/matrix-crdt";
|
package/dist/index.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/index.ts"],"sourcesContent":["// Main exports for ixo-editor package\n// This exports the mantine version by default\n// For explicit mantine imports, use:\n// - import { ... } from \"@ixo/editor/mantine\"\n\n// Export the main hook (mantine version by default)\nexport { useCreateIxoEditor } from './mantine/hooks/useCreateIxoEditor';\nexport { useCreateCollaborativeIxoEditor } from './mantine/hooks/useCollaborativeIxoEditor';\n\n// Export the main component (mantine version by default)\nexport { IxoEditor, type IxoEditorProps } from './mantine/IxoEditor';\n\n// Export CoverImage component\nexport { CoverImage, type CoverImageProps } from './mantine/components/CoverImage';\nexport { DevUcanGrantButton } from './mantine/components/DevUcanGrantButton';\n\n// Export authorization components\nexport { AuthorizationTab, type AuthorizationTabState } from './mantine/components/AuthorizationTab';\nexport { EvaluationTab, type EvaluationTabState } from './mantine/components/EvaluationTab';\nexport { EntitySigningSetup } from './mantine/components/EntitySigningSetup';\nexport { FlowPermissionsPanel } from './mantine/components/FlowPermissionsPanel';\nexport { GrantPermissionModal } from './mantine/components/GrantPermissionModal';\n\n// Export flow engine\nexport {\n executeNode,\n isAuthorized,\n createRuntimeStateManager,\n buildFlowNodeFromBlock,\n buildAuthzFromProps,\n createUcanDelegationStore,\n createMemoryUcanDelegationStore,\n createInvocationStore,\n createMemoryInvocationStore,\n createUcanService,\n} from './core/lib/flowEngine';\nexport type {\n ExecuteNodeParams,\n ExecutionOutcome,\n NodeActionResult,\n ExecutionContext,\n AuthorizationResult,\n UcanDelegationStore,\n InvocationStore,\n UcanService,\n UcanServiceConfig,\n UcanServiceHandlers,\n FlowRuntimeStateManager,\n} from './core/lib/flowEngine';\n\n// Export UCAN types\nexport type { UcanCapability, StoredDelegation, StoredInvocation, DelegationChainValidationResult } from './core/types/ucan';\nexport type { DelegationGrant } from './core/types/capability';\n\n// Export types from core\nexport type { IxoEditorOptions, IxoEditorTheme, IxoEditorConfig, IxoCollaborativeUser, IxoCollaborativeEditorOptions } from './core/types';\n\n// Export custom blocks (mantine version by default)\nexport { CheckboxBlockSpec, ListBlockSpec, OverviewBlock, ProposalBlockSpec, ApiRequestBlockSpec, blockSpecs, getExtraSlashMenuItems } from './mantine/blocks';\nexport type { CheckboxBlockProps, ListBlockSettings, ListBlockProps } from './mantine/blocks';\nexport type { OverviewBlockProps } from './mantine/blocks';\nexport type { ProposalBlockProps } from './mantine/blocks';\nexport type { ApiRequestBlockProps, HttpMethod, KeyValuePair } from './mantine/blocks';\n\n// Export block presence hooks\nexport { useBlockPresence, type BlockPresenceUser } from './mantine/hooks/useBlockPresence';\nexport { useTrackBlockFocus } from './mantine/hooks/useTrackBlockFocus';\n\n// Export context and handlers\nexport { BlocknoteProvider, useBlocknoteContext, useBlocknoteHandlers, useTranslate, StakeType, AuthzExecActionTypes, ValidatorActionType } from './mantine/context';\nexport type {\n BlocknoteHandlers,\n BlocknoteContextValue,\n BlockRequirements,\n ProposalResponse,\n SingleChoiceProposal,\n VoteResponse,\n VoteInfo,\n Vote,\n User,\n Addr,\n Uint128,\n Timestamp,\n Expiration,\n Status,\n Threshold,\n Votes,\n CosmosMsgForEmpty,\n ProposalAction,\n StakeTypeValue,\n Translate,\n} from './mantine/context';\n\n// Export GraphQL client and queries from core\nexport { getEntity } from './core/lib/graphql-queries';\nexport type { Entity, EntityResponse, EntityVariables } from './core/lib/graphql-queries';\nexport { GraphQLClient, ixoGraphQLClient } from './core/lib/graphql-client';\nexport type { GraphQLResponse, GraphQLRequest } from './core/lib/graphql-client';\n\n// Export flow compiler (Base UCAN → flow setup)\nexport {\n setupFlowFromBaseUcan,\n readFlowAsBaseUcan,\n readFlowFromEditor,\n readFlow,\n setActiveEditor,\n getActiveEditor,\n compileBaseUcanFlow,\n readCompiledFlowFromYDoc,\n mergeCompiledFlows,\n decompileToBaseUcanFlow,\n} from './core/lib/flowCompiler';\nexport type { SetupFlowOptions, SetupFlowResult, ReadFlowOptions, ReadFlowResult, ReadableEditor, CompilerRegistry, MergeResult } from './core/lib/flowCompiler';\nexport type { BaseUcanFlow, FlowCapability, CompiledFlow, FlowStrategy } from './core/types/baseUcan';\n\n// Export Flow Agent runtime\nexport {\n FlowAgentService,\n acquireFlowAgentLease,\n appendAgentLedgerEvent,\n buildFlowAgentContext,\n cleanupExpiredFlowAgentLeases,\n createAgentCommand,\n evaluateFlowAgentPolicy,\n executeQueuedAgentCommands,\n getFlowAgentMaps,\n planRalphLoopCommands,\n queueAgentCommand,\n readAgentLedgerEvents,\n readQueuedAgentCommands,\n releaseFlowAgentLease,\n tickFlowAgent,\n validateAgentCommand,\n validateFlowAgentLease,\n type BuildFlowAgentContextParams,\n} from './core/lib/flowAgent';\nexport type {\n FlowAgentActor,\n FlowAgentCommand,\n FlowAgentCommandResult,\n FlowAgentContext,\n FlowAgentExecutor,\n FlowAgentLease,\n FlowAgentNodeSnapshot,\n FlowAgentPublicNodeState,\n FlowAgentTickResult,\n} from './core/types/flowAgent';\n\n// Re-export cloneDocument from matrix-crdt\nexport { cloneDocument } from '@ixo/matrix-crdt';\nexport type { CloneDocumentResult } from '@ixo/matrix-crdt';\n\n// Re-export useful BlockNote types that users might need\nexport type { BlockNoteEditor, BlockNoteSchema, DefaultBlockSchema, DefaultInlineContentSchema, DefaultStyleSchema, PartialBlock, Block } from '@blocknote/core';\n\n// Note: Additional BlockNote utilities can be imported directly from @blocknote/react if needed\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"sources":["../src/index.ts"],"sourcesContent":["// Main exports for ixo-editor package\n// This exports the mantine version by default\n// For explicit mantine imports, use:\n// - import { ... } from \"@ixo/editor/mantine\"\n\n// Export the main hook (mantine version by default)\nexport { useCreateIxoEditor } from './mantine/hooks/useCreateIxoEditor';\nexport { useCreateCollaborativeIxoEditor } from './mantine/hooks/useCollaborativeIxoEditor';\n\n// Export the main component (mantine version by default)\nexport { IxoEditor, type IxoEditorProps } from './mantine/IxoEditor';\n\n// Export CoverImage component\nexport { CoverImage, type CoverImageProps } from './mantine/components/CoverImage';\nexport { DevUcanGrantButton } from './mantine/components/DevUcanGrantButton';\n\n// Export authorization components\nexport { AuthorizationTab, type AuthorizationTabState } from './mantine/components/AuthorizationTab';\nexport { EvaluationTab, type EvaluationTabState } from './mantine/components/EvaluationTab';\nexport { EntitySigningSetup } from './mantine/components/EntitySigningSetup';\nexport { FlowPermissionsPanel } from './mantine/components/FlowPermissionsPanel';\nexport { GrantPermissionModal } from './mantine/components/GrantPermissionModal';\n\n// Export flow engine\nexport {\n executeNode,\n isAuthorized,\n createRuntimeStateManager,\n buildFlowNodeFromBlock,\n buildAuthzFromProps,\n createUcanDelegationStore,\n createMemoryUcanDelegationStore,\n createInvocationStore,\n createMemoryInvocationStore,\n createUcanService,\n} from './core/lib/flowEngine';\nexport type {\n ExecuteNodeParams,\n ExecutionOutcome,\n NodeActionResult,\n ExecutionContext,\n AuthorizationResult,\n UcanDelegationStore,\n InvocationStore,\n UcanService,\n UcanServiceConfig,\n UcanServiceHandlers,\n FlowRuntimeStateManager,\n} from './core/lib/flowEngine';\n\n// Export UCAN types\nexport type { UcanCapability, StoredDelegation, StoredInvocation, DelegationChainValidationResult } from './core/types/ucan';\nexport type { DelegationGrant } from './core/types/capability';\n\n// Export types from core\nexport type { IxoEditorOptions, IxoEditorTheme, IxoEditorConfig, IxoCollaborativeUser, IxoCollaborativeEditorOptions } from './core/types';\n\n// Export custom blocks (mantine version by default)\nexport { CheckboxBlockSpec, ListBlockSpec, OverviewBlock, ProposalBlockSpec, ApiRequestBlockSpec, blockSpecs, getExtraSlashMenuItems } from './mantine/blocks';\nexport type { CheckboxBlockProps, ListBlockSettings, ListBlockProps } from './mantine/blocks';\nexport type { OverviewBlockProps } from './mantine/blocks';\nexport type { ProposalBlockProps } from './mantine/blocks';\nexport type { ApiRequestBlockProps, HttpMethod, KeyValuePair } from './mantine/blocks';\n\n// Export block presence hooks\nexport { useBlockPresence, type BlockPresenceUser } from './mantine/hooks/useBlockPresence';\nexport { useTrackBlockFocus } from './mantine/hooks/useTrackBlockFocus';\n\n// Export context and handlers\nexport { BlocknoteProvider, useBlocknoteContext, useBlocknoteHandlers, useTranslate, StakeType, AuthzExecActionTypes, ValidatorActionType } from './mantine/context';\nexport type {\n BlocknoteHandlers,\n BlocknoteContextValue,\n BlockRequirements,\n ProposalResponse,\n SingleChoiceProposal,\n VoteResponse,\n VoteInfo,\n Vote,\n User,\n Addr,\n Uint128,\n Timestamp,\n Expiration,\n Status,\n Threshold,\n Votes,\n CosmosMsgForEmpty,\n ProposalAction,\n StakeTypeValue,\n ListProtocolDeedsWithTemplatesParams,\n ProtocolDeedWithTemplates,\n ProtocolTemplateSummary,\n ImportProtocolTemplatesToSpaceParams,\n ImportProtocolTemplateResult,\n MatrixPrivacySettings,\n MatrixRoom,\n MatrixSpace,\n MatrixSubspace,\n MatrixSpaceStructure,\n Translate,\n} from './mantine/context';\n\n// Export GraphQL client and queries from core\nexport { getEntity } from './core/lib/graphql-queries';\nexport type { Entity, EntityResponse, EntityVariables } from './core/lib/graphql-queries';\nexport { GraphQLClient, ixoGraphQLClient } from './core/lib/graphql-client';\nexport type { GraphQLResponse, GraphQLRequest } from './core/lib/graphql-client';\n\n// Export flow compiler (Base UCAN → flow setup)\nexport {\n setupFlowFromBaseUcan,\n readFlowAsBaseUcan,\n readFlowFromEditor,\n readFlow,\n setActiveEditor,\n getActiveEditor,\n compileBaseUcanFlow,\n readCompiledFlowFromYDoc,\n mergeCompiledFlows,\n decompileToBaseUcanFlow,\n} from './core/lib/flowCompiler';\nexport type { SetupFlowOptions, SetupFlowResult, ReadFlowOptions, ReadFlowResult, ReadableEditor, CompilerRegistry, MergeResult } from './core/lib/flowCompiler';\nexport type { BaseUcanFlow, FlowCapability, CompiledFlow, FlowStrategy } from './core/types/baseUcan';\n\n// Export Flow Agent runtime\nexport {\n FlowAgentService,\n acquireFlowAgentLease,\n appendAgentLedgerEvent,\n buildFlowAgentContext,\n cleanupExpiredFlowAgentLeases,\n createAgentCommand,\n evaluateFlowAgentPolicy,\n executeQueuedAgentCommands,\n getFlowAgentMaps,\n planRalphLoopCommands,\n queueAgentCommand,\n readAgentLedgerEvents,\n readQueuedAgentCommands,\n releaseFlowAgentLease,\n tickFlowAgent,\n validateAgentCommand,\n validateFlowAgentLease,\n type BuildFlowAgentContextParams,\n} from './core/lib/flowAgent';\nexport type {\n FlowAgentActor,\n FlowAgentCommand,\n FlowAgentCommandResult,\n FlowAgentContext,\n FlowAgentExecutor,\n FlowAgentLease,\n FlowAgentNodeSnapshot,\n FlowAgentPublicNodeState,\n FlowAgentTickResult,\n} from './core/types/flowAgent';\n\n// Re-export cloneDocument from matrix-crdt\nexport { cloneDocument } from '@ixo/matrix-crdt';\nexport type { CloneDocumentResult } from '@ixo/matrix-crdt';\n\n// Re-export useful BlockNote types that users might need\nexport type { BlockNoteEditor, BlockNoteSchema, DefaultBlockSchema, DefaultInlineContentSchema, DefaultStyleSchema, PartialBlock, Block } from '@blocknote/core';\n\n// Note: Additional BlockNote utilities can be imported directly from @blocknote/react if needed\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA+JA,SAAS,qBAAqB;","names":[]}
|
package/dist/mantine/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export { n as ApiRequestBlockProps, h as ApiRequestBlockSpec, A as AuthorizationTab, d as AuthorizationTabState, B as BlockPresenceUser, i as CheckboxBlockProps, g as CheckboxBlockSpec, C as CoverImage, c as CoverImageProps, D as DevUcanGrantButton, J as DropPosition, r as Entity, s as EntityResponse, f as EntitySigningSetup, t as EntityVariables, E as EvaluationTab, e as EvaluationTabState, z as ExternalDropZone, F as FlowPermissionsPanel, G as GrantPermissionModal, v as GraphQLClient, y as GraphQLRequest, x as GraphQLResponse, H as HttpMethod, I as IxoEditor, b as IxoEditorProps, K as KeyValuePair, k as ListBlockProps, j as ListBlockSettings, L as ListBlockSpec, O as OverviewBlock, l as OverviewBlockProps, m as ProposalBlockProps, P as ProposalBlockSpec, q as getEntity, w as ixoGraphQLClient, o as useBlockPresence, a as useCreateCollaborativeIxoEditor, u as useCreateIxoEditor, p as useTrackBlockFocus } from '../graphql-client-
|
|
1
|
+
export { n as ApiRequestBlockProps, h as ApiRequestBlockSpec, A as AuthorizationTab, d as AuthorizationTabState, B as BlockPresenceUser, i as CheckboxBlockProps, g as CheckboxBlockSpec, C as CoverImage, c as CoverImageProps, D as DevUcanGrantButton, J as DropPosition, r as Entity, s as EntityResponse, f as EntitySigningSetup, t as EntityVariables, E as EvaluationTab, e as EvaluationTabState, z as ExternalDropZone, F as FlowPermissionsPanel, G as GrantPermissionModal, v as GraphQLClient, y as GraphQLRequest, x as GraphQLResponse, H as HttpMethod, I as IxoEditor, b as IxoEditorProps, K as KeyValuePair, k as ListBlockProps, j as ListBlockSettings, L as ListBlockSpec, O as OverviewBlock, l as OverviewBlockProps, m as ProposalBlockProps, P as ProposalBlockSpec, q as getEntity, w as ixoGraphQLClient, o as useBlockPresence, a as useCreateCollaborativeIxoEditor, u as useCreateIxoEditor, p as useTrackBlockFocus } from '../graphql-client-Dhxgv06u.mjs';
|
|
2
2
|
import React__default, { PropsWithChildren } from 'react';
|
|
3
|
-
import {
|
|
4
|
-
export { H as Addr, A as AuthzExecActionTypes, y as BlockRequirements, x as BlocknoteContextValue, B as BlocknoteProvider, O as CosmosMsgForEmpty,
|
|
3
|
+
import { ao as IxoBlockProps, a4 as IxoEditorType, w as BlocknoteHandlers, a5 as FlowNodeRuntimeState } from '../index-DMNPdv6v.mjs';
|
|
4
|
+
export { H as Addr, A as AuthzExecActionTypes, y as BlockRequirements, x as BlocknoteContextValue, B as BlocknoteProvider, O as CosmosMsgForEmpty, au as DomainCardData, at as DomainCardRenderer, aq as DynamicListData, ar as DynamicListDataProvider, as as DynamicListPanelRenderer, K as Expiration, Z as ImportProtocolTemplateResult, Y as ImportProtocolTemplatesToSpaceParams, p as IxoCollaborativeEditorOptions, o as IxoCollaborativeUser, n as IxoEditorConfig, l as IxoEditorOptions, m as IxoEditorTheme, R as ListProtocolDeedsWithTemplatesParams, _ as MatrixPrivacySettings, $ as MatrixRoom, a0 as MatrixSpace, a2 as MatrixSpaceStructure, a1 as MatrixSubspace, Q as ProposalAction, P as ProposalResponse, W as ProtocolDeedWithTemplates, X as ProtocolTemplateSummary, z as SingleChoiceProposal, v as StakeType, v as StakeTypeValue, L as Status, M as Threshold, T as Timestamp, J as Uint128, G as User, V as ValidatorActionType, ap as VisualizationRenderer, F as Vote, E as VoteInfo, C as VoteResponse, N as Votes, q as blockSpecs, r as getExtraSlashMenuItems, u as useBlocknoteContext, s as useBlocknoteHandlers } from '../index-DMNPdv6v.mjs';
|
|
5
5
|
import * as zustand from 'zustand';
|
|
6
6
|
import { SurveyModel } from '@ixo/surveys';
|
|
7
7
|
import * as _blocknote_core from '@blocknote/core';
|
package/dist/mantine/index.mjs
CHANGED
|
@@ -54,13 +54,13 @@ import {
|
|
|
54
54
|
usePanelStore,
|
|
55
55
|
useRegisterOpenSurvey,
|
|
56
56
|
useTrackBlockFocus
|
|
57
|
-
} from "../chunk-
|
|
57
|
+
} from "../chunk-IALS3KWH.mjs";
|
|
58
58
|
import {
|
|
59
59
|
didToMatrixUserId,
|
|
60
60
|
findOrCreateDMRoom,
|
|
61
61
|
getHomeserver,
|
|
62
62
|
sendDirectMessage
|
|
63
|
-
} from "../chunk-
|
|
63
|
+
} from "../chunk-XGQRYGA3.mjs";
|
|
64
64
|
export {
|
|
65
65
|
ApiRequestBlockSpec,
|
|
66
66
|
AuthorizationTab,
|