@ixo/editor 6.21.0 → 6.23.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/index.d.ts CHANGED
@@ -1,7 +1,7 @@
1
- export { q 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, v as Entity, w as EntityResponse, f as EntitySigningSetup, x as EntityVariables, E as EvaluationTab, e as EvaluationTabState, F as FlowPermissionsPanel, n as FlowStepRefProps, l as FlowStepRefSpec, G as GrantPermissionModal, y as GraphQLClient, M as GraphQLRequest, J 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, o as OverviewBlockProps, p as ProposalBlockProps, P as ProposalBlockSpec, t as getEntity, m as inlineContentSpecs, z as ixoGraphQLClient, r as useBlockPresence, a as useCreateCollaborativeIxoEditor, u as useCreateIxoEditor, s as useTrackBlockFocus } from './graphql-client-j-P2Llxg.js';
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-Ba-HGtSG.js';
1
+ export { q 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, v as Entity, w as EntityResponse, f as EntitySigningSetup, x as EntityVariables, E as EvaluationTab, e as EvaluationTabState, F as FlowPermissionsPanel, n as FlowStepRefProps, l as FlowStepRefSpec, G as GrantPermissionModal, y as GraphQLClient, M as GraphQLRequest, J 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, o as OverviewBlockProps, p as ProposalBlockProps, P as ProposalBlockSpec, t as getEntity, m as inlineContentSpecs, z as ixoGraphQLClient, r as useBlockPresence, a as useCreateCollaborativeIxoEditor, u as useCreateIxoEditor, s as useTrackBlockFocus } from './graphql-client-DQD1v9Yw.js';
2
+ export { A as AuthorizationResult, U as BaseUcanFlow, ad as BuildFlowAgentContextParams, W as CompiledFlow, L as CompilerRegistry, E as ExecuteNodeParams, d as ExecutionContext, c as ExecutionOutcome, G as FLOW_CONNECTIONS_MAP_KEY, H as FLOW_CONNECTION_BINDINGS_MAP_KEY, F as FLOW_PARTICIPANTS_MAP_KEY, ae as FlowAgentActor, af as FlowAgentCommand, ag as FlowAgentCommandResult, ah as FlowAgentContext, ai as FlowAgentExecutor, aj as FlowAgentLease, ak as FlowAgentNodeSnapshot, al as FlowAgentPublicNodeState, Y as FlowAgentService, am as FlowAgentTickResult, V as FlowCapability, P as FlowConnection, Q as FlowConnectionBinding, T as FlowConnectionRequirementKey, O as FlowParticipant, X as FlowStrategy, M as MergeResult, N as NodeActionResult, R as ReadFlowOptions, J as ReadFlowResult, K as ReadableEditor, S as SetupFlowOptions, I as SetupFlowResult, Z as acquireFlowAgentLease, _ as appendAgentLedgerEvent, a as buildAuthzFromProps, $ as buildFlowAgentContext, b as buildFlowNodeFromBlock, a0 as cleanupExpiredFlowAgentLeases, k as compileBaseUcanFlow, a1 as createAgentCommand, n as decompileToBaseUcanFlow, a2 as evaluateFlowAgentPolicy, e as executeNode, a3 as executeQueuedAgentCommands, j as getActiveEditor, a4 as getFlowAgentMaps, i as isAuthorized, m as mergeCompiledFlows, a5 as planRalphLoopCommands, a6 as queueAgentCommand, a7 as readAgentLedgerEvents, l as readCompiledFlowFromYDoc, g as readFlow, r as readFlowAsBaseUcan, B as readFlowConnectionBindings, v as readFlowConnections, f as readFlowFromEditor, o as readFlowParticipants, a8 as readQueuedAgentCommands, a9 as releaseFlowAgentLease, x as removeFlowConnection, D as removeFlowConnectionBinding, p as removeFlowParticipant, h as setActiveEditor, y as setFlowConnectionOptional, z as setFlowConnectionRequires, q as setFlowParticipantPowerLevel, t as setFlowParticipantRequirements, s as setupFlowFromBaseUcan, aa as tickFlowAgent, w as upsertFlowConnection, C as upsertFlowConnectionBinding, u as upsertFlowParticipant, ab as validateAgentCommand, ac as validateFlowAgentLease } from './store-B60v3oba.js';
3
+ export { K as Addr, A as AuthzExecActionTypes, z as BlockRequirements, y as BlocknoteContextValue, x as BlocknoteHandlers, B as BlocknoteProvider, R as CosmosMsgForEmpty, D as DelegationChainValidationResult, l as DelegationGrant, M as Expiration, F as FlowRuntimeStateManager, $ as ImportProtocolTemplateResult, _ as ImportProtocolTemplatesToSpaceParams, I as InvocationStore, q as IxoCollaborativeEditorOptions, p as IxoCollaborativeUser, o as IxoEditorConfig, m as IxoEditorOptions, n as IxoEditorTheme, X as ListProtocolDeedsWithTemplatesParams, a0 as MatrixPrivacySettings, a1 as MatrixRoom, a2 as MatrixSpace, a4 as MatrixSpaceStructure, a3 as MatrixSubspace, W as ProposalAction, P as ProposalResponse, Y as ProtocolDeedWithTemplates, Z as ProtocolTemplateSummary, C as SingleChoiceProposal, w as StakeType, w as StakeTypeValue, N as Status, S as StoredDelegation, k as StoredInvocation, O as Threshold, T as Timestamp, a5 as Translate, j as UcanCapability, U as UcanDelegationStore, g as UcanService, h as UcanServiceConfig, i as UcanServiceHandlers, L as Uint128, J as User, V as ValidatorActionType, H as Vote, G as VoteInfo, E as VoteResponse, Q as Votes, r as blockSpecs, d as createInvocationStore, e as createMemoryInvocationStore, b as createMemoryUcanDelegationStore, c as createRuntimeStateManager, a as createUcanDelegationStore, f as createUcanService, s as getExtraSlashMenuItems, u as useBlocknoteContext, t as useBlocknoteHandlers, v as useTranslate } from './index-x1R0c9P_.js';
3
4
  export { Block, BlockNoteEditor, BlockNoteSchema, DefaultBlockSchema, DefaultInlineContentSchema, DefaultStyleSchema, PartialBlock } from '@blocknote/core';
4
- 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-BC4ycOwH.js';
5
5
  export { CloneDocumentResult, cloneDocument } from '@ixo/matrix-crdt';
6
6
  import 'yjs';
7
7
  import 'react';
package/dist/index.js CHANGED
@@ -30,9 +30,18 @@ import {
30
30
  useCreateIxoEditor,
31
31
  useTrackBlockFocus,
32
32
  useTranslate
33
- } from "./chunk-I4NSQ7X4.js";
34
- import "./chunk-EO2K4IDP.js";
33
+ } from "./chunk-UIZV4YAW.js";
35
34
  import {
35
+ FLOW_PARTICIPANTS_MAP_KEY,
36
+ readFlowParticipants,
37
+ removeFlowParticipant,
38
+ setFlowParticipantPowerLevel,
39
+ setFlowParticipantRequirements,
40
+ upsertFlowParticipant
41
+ } from "./chunk-LBFFAKSN.js";
42
+ import {
43
+ FLOW_CONNECTIONS_MAP_KEY,
44
+ FLOW_CONNECTION_BINDINGS_MAP_KEY,
36
45
  FlowAgentService,
37
46
  acquireFlowAgentLease,
38
47
  appendAgentLedgerEvent,
@@ -62,15 +71,23 @@ import {
62
71
  readCompiledFlowFromYDoc,
63
72
  readFlow,
64
73
  readFlowAsBaseUcan,
74
+ readFlowConnectionBindings,
75
+ readFlowConnections,
65
76
  readFlowFromEditor,
66
77
  readQueuedAgentCommands,
67
78
  releaseFlowAgentLease,
79
+ removeFlowConnection,
80
+ removeFlowConnectionBinding,
68
81
  setActiveEditor,
82
+ setFlowConnectionOptional,
83
+ setFlowConnectionRequires,
69
84
  setupFlowFromBaseUcan,
70
85
  tickFlowAgent,
86
+ upsertFlowConnection,
87
+ upsertFlowConnectionBinding,
71
88
  validateAgentCommand,
72
89
  validateFlowAgentLease
73
- } from "./chunk-2WSXLAX5.js";
90
+ } from "./chunk-VFYF2B5E.js";
74
91
 
75
92
  // src/index.ts
76
93
  import { cloneDocument } from "@ixo/matrix-crdt";
@@ -84,6 +101,9 @@ export {
84
101
  DevUcanGrantButton,
85
102
  EntitySigningSetup,
86
103
  EvaluationTab,
104
+ FLOW_CONNECTIONS_MAP_KEY,
105
+ FLOW_CONNECTION_BINDINGS_MAP_KEY,
106
+ FLOW_PARTICIPANTS_MAP_KEY,
87
107
  FlowAgentService,
88
108
  FlowPermissionsPanel,
89
109
  FlowStepRefSpec,
@@ -129,12 +149,25 @@ export {
129
149
  readCompiledFlowFromYDoc,
130
150
  readFlow,
131
151
  readFlowAsBaseUcan,
152
+ readFlowConnectionBindings,
153
+ readFlowConnections,
132
154
  readFlowFromEditor,
155
+ readFlowParticipants,
133
156
  readQueuedAgentCommands,
134
157
  releaseFlowAgentLease,
158
+ removeFlowConnection,
159
+ removeFlowConnectionBinding,
160
+ removeFlowParticipant,
135
161
  setActiveEditor,
162
+ setFlowConnectionOptional,
163
+ setFlowConnectionRequires,
164
+ setFlowParticipantPowerLevel,
165
+ setFlowParticipantRequirements,
136
166
  setupFlowFromBaseUcan,
137
167
  tickFlowAgent,
168
+ upsertFlowConnection,
169
+ upsertFlowConnectionBinding,
170
+ upsertFlowParticipant,
138
171
  useBlockPresence,
139
172
  useBlocknoteContext,
140
173
  useBlocknoteHandlers,
package/dist/index.js.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 { FlowStepRefSpec, inlineContentSpecs } from './mantine/inline';\nexport type { FlowStepRefProps } from './mantine/inline';\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":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAiKA,SAAS,qBAAqB;","names":[]}
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 { FlowStepRefSpec, inlineContentSpecs } from './mantine/inline';\nexport type { FlowStepRefProps } from './mantine/inline';\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 readFlowParticipants,\n upsertFlowParticipant,\n removeFlowParticipant,\n setFlowParticipantPowerLevel,\n setFlowParticipantRequirements,\n FLOW_PARTICIPANTS_MAP_KEY,\n readFlowConnections,\n upsertFlowConnection,\n removeFlowConnection,\n setFlowConnectionOptional,\n setFlowConnectionRequires,\n readFlowConnectionBindings,\n upsertFlowConnectionBinding,\n removeFlowConnectionBinding,\n FLOW_CONNECTIONS_MAP_KEY,\n FLOW_CONNECTION_BINDINGS_MAP_KEY,\n} from './core/lib/flowCompiler';\nexport type {\n SetupFlowOptions,\n SetupFlowResult,\n ReadFlowOptions,\n ReadFlowResult,\n ReadableEditor,\n CompilerRegistry,\n MergeResult,\n FlowParticipant,\n FlowConnection,\n FlowConnectionBinding,\n FlowConnectionRequirementKey,\n} 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":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA6LA,SAAS,qBAAqB;","names":[]}
@@ -1,14 +1,14 @@
1
- export { q 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, Q as DropPosition, v as Entity, w as EntityResponse, f as EntitySigningSetup, x as EntityVariables, E as EvaluationTab, e as EvaluationTabState, N as ExternalDropZone, F as FlowPermissionsPanel, n as FlowStepRefProps, l as FlowStepRefSpec, G as GrantPermissionModal, y as GraphQLClient, M as GraphQLRequest, J 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, o as OverviewBlockProps, p as ProposalBlockProps, P as ProposalBlockSpec, t as getEntity, m as inlineContentSpecs, z as ixoGraphQLClient, r as useBlockPresence, a as useCreateCollaborativeIxoEditor, u as useCreateIxoEditor, s as useTrackBlockFocus } from '../graphql-client-j-P2Llxg.js';
1
+ export { q 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, Q as DropPosition, v as Entity, w as EntityResponse, f as EntitySigningSetup, x as EntityVariables, E as EvaluationTab, e as EvaluationTabState, N as ExternalDropZone, F as FlowPermissionsPanel, n as FlowStepRefProps, l as FlowStepRefSpec, G as GrantPermissionModal, y as GraphQLClient, M as GraphQLRequest, J 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, o as OverviewBlockProps, p as ProposalBlockProps, P as ProposalBlockSpec, t as getEntity, m as inlineContentSpecs, z as ixoGraphQLClient, r as useBlockPresence, a as useCreateCollaborativeIxoEditor, u as useCreateIxoEditor, s as useTrackBlockFocus } from '../graphql-client-DQD1v9Yw.js';
2
2
  import React__default, { PropsWithChildren } from 'react';
3
- import { ap as IxoBlockProps, a5 as IxoEditorType, w as BlocknoteHandlers, a4 as FlowNodeRuntimeState } from '../index-BC4ycOwH.js';
4
- export { H as Addr, A as AuthzExecActionTypes, y as BlockRequirements, x as BlocknoteContextValue, B as BlocknoteProvider, O as CosmosMsgForEmpty, av as DomainCardData, au as DomainCardRenderer, ar as DynamicListData, as as DynamicListDataProvider, at 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, aq 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-BC4ycOwH.js';
3
+ import { ah as IxoBlockProps, a9 as IxoEditorType, x as BlocknoteHandlers, ad as RunEventAppender, ag as FlowNodeRuntimeState } from '../index-x1R0c9P_.js';
4
+ export { K as Addr, A as AuthzExecActionTypes, z as BlockRequirements, y as BlocknoteContextValue, B as BlocknoteProvider, R as CosmosMsgForEmpty, an as DomainCardData, am as DomainCardRenderer, aj as DynamicListData, ak as DynamicListDataProvider, al as DynamicListPanelRenderer, M as Expiration, $ as ImportProtocolTemplateResult, _ as ImportProtocolTemplatesToSpaceParams, q as IxoCollaborativeEditorOptions, p as IxoCollaborativeUser, o as IxoEditorConfig, m as IxoEditorOptions, n as IxoEditorTheme, X as ListProtocolDeedsWithTemplatesParams, a0 as MatrixPrivacySettings, a1 as MatrixRoom, a2 as MatrixSpace, a4 as MatrixSpaceStructure, a3 as MatrixSubspace, W as ProposalAction, P as ProposalResponse, Y as ProtocolDeedWithTemplates, Z as ProtocolTemplateSummary, C as SingleChoiceProposal, w as StakeType, w as StakeTypeValue, N as Status, O as Threshold, T as Timestamp, L as Uint128, J as User, V as ValidatorActionType, ai as VisualizationRenderer, H as Vote, G as VoteInfo, E as VoteResponse, Q as Votes, r as blockSpecs, s as getExtraSlashMenuItems, u as useBlocknoteContext, t as useBlocknoteHandlers } from '../index-x1R0c9P_.js';
5
5
  import * as zustand from 'zustand';
6
6
  import { SurveyModel } from '@ixo/surveys';
7
7
  import { N as NodeContextRecord } from '../nodeContext-C-BsYuYi.js';
8
8
  import * as _blocknote_core from '@blocknote/core';
9
9
  export { Block, BlockNoteEditor, BlockNoteSchema, DefaultBlockSchema, DefaultInlineContentSchema, DefaultStyleSchema, PartialBlock } from '@blocknote/core';
10
10
  import { MatrixClient } from 'matrix-js-sdk';
11
- import { Map as Map$1 } from 'yjs';
11
+ import { Doc } from 'yjs';
12
12
  import '@tiptap/core';
13
13
  import '@ixo/ucan';
14
14
 
@@ -146,6 +146,11 @@ interface DynamicListPanelConfig {
146
146
  actions?: DynamicListAction[];
147
147
  }
148
148
 
149
+ /**
150
+ * Dev-tools launcher: a single round button pinned to the bottom-right (the Next.js
151
+ * dev indicator owns the bottom-left) that expands into the individual tools, so the
152
+ * dev overlay costs one small dot instead of a row of bars across the flow canvas.
153
+ */
149
154
  declare function DebugButton({ editor, handlers }: {
150
155
  editor: IxoEditorType;
151
156
  handlers?: BlocknoteHandlers;
@@ -197,6 +202,9 @@ interface FlowNodePanelProps {
197
202
  isDisabled: 'disable';
198
203
  message?: string;
199
204
  };
205
+ /** Explicit session whose runtime state this panel reads and writes. */
206
+ sessionRunId?: string;
207
+ runEventLog?: RunEventAppender;
200
208
  }
201
209
  /**
202
210
  * Single dispatcher that, given a flow editor and a step block, renders that
@@ -211,6 +219,15 @@ interface FlowNodePanelProps {
211
219
  */
212
220
  declare function FlowNodePanel(props: FlowNodePanelProps): React__default.JSX.Element;
213
221
 
222
+ declare function RunSessionProvider({ sessionRunId, runEventLog, children }: {
223
+ sessionRunId?: string;
224
+ runEventLog?: RunEventAppender;
225
+ children: React__default.ReactNode;
226
+ }): React__default.JSX.Element;
227
+ /** Selected session for this rendered surface; never a document-global lock. */
228
+ declare function useRunSessionId(): string | undefined;
229
+ declare function useRunEventLog(): RunEventAppender | undefined;
230
+
214
231
  interface FlowNodeConfigPanelProps {
215
232
  editor: IxoBlockProps['editor'];
216
233
  block: IxoBlockProps['block'];
@@ -373,14 +390,39 @@ interface UseRegisterOpenSurveyParams {
373
390
  declare function useRegisterOpenSurvey({ id, title, source, schema, context, model, readonly, enabled, }: UseRegisterOpenSurveyParams): void;
374
391
 
375
392
  /**
376
- * Reactive hook that subscribes to a single node's runtime state in yDoc.runtime.
393
+ * Reactive hook over a single block's per-run execution state.
377
394
  *
378
395
  * Usage:
379
396
  * const [runtime, updateRuntime] = useNodeRuntime(editor, block.id);
380
397
  * // runtime.state, runtime.output, runtime.error, etc.
381
398
  * // updateRuntime({ state: 'completed', output: { ... } });
399
+ *
400
+ * # Ignition Phase A — this is THE React write path
401
+ *
402
+ * `updateRuntime` is created once per block in `ActionFlowPanel` and prop-drilled
403
+ * to every FlowDetail, so the ~100 `updateRuntime({...})` call sites in the repo
404
+ * — every "Reset" button, every checkbox toggle, every completion write — reach
405
+ * the doc through this one function. It therefore routes through the waist
406
+ * (`core/lib/flowEngine/runs.ts`) rather than touching `editor._yRuntime`.
407
+ *
408
+ * That matters far beyond tidiness. The freshness predicate is deliberately
409
+ * **non-downgrading** (a started side beats an unstarted side), which is what
410
+ * stops an old tab's completed payment reading as `idle`. The corollary is the
411
+ * trap: a legitimate transition to a **lower** state — Reset, an unchecked box —
412
+ * written flat-only can never be materialised into the run, so the run entry
413
+ * keeps the stale higher state **forever** (CRDT history is immutable: no
414
+ * convergence path, no repair in code). The symptom inverts the bug the
415
+ * predicate fixed — with a stale `completed` run entry, a reset-then-re-run
416
+ * resolves `prev.state === 'completed'`, the guard below never fires,
417
+ * `step.completed` is never emitted, and the flow **stalls**. See §9.3 The
418
+ * adoption gate.
419
+ *
420
+ * @param runId The **session run** to read and write. Phase A has exactly one,
421
+ * so it defaults to {@link resolveActiveRunId}; the parameter exists so Phase
422
+ * B's run selection is a call-site change and not a signature change. Never an
423
+ * execution id (D2).
382
424
  */
383
- declare function useNodeRuntime(editor: IxoEditorType, nodeId: string): [FlowNodeRuntimeState, (updates: Partial<FlowNodeRuntimeState>) => void];
425
+ declare function useNodeRuntime(editor: IxoEditorType, nodeId: string, runId?: string): [FlowNodeRuntimeState, (updates: Partial<FlowNodeRuntimeState>) => Promise<void>];
384
426
 
385
427
  /**
386
428
  * Reactive hook that subscribes to a single node's flow-manager context
@@ -615,6 +657,59 @@ declare function sendDirectMessage(matrixClient: MatrixClient, targetDid: string
615
657
  roomId: string;
616
658
  }>;
617
659
 
660
+ /**
661
+ * Top-level Y.Doc map that owns all DM notification dedup state.
662
+ *
663
+ * Ignition Phase A prerequisite: these records used to squat as reserved
664
+ * `__`-prefixed keys inside the flat `runtime` map. Run adoption iterates that
665
+ * map and copies every entry into `runs[<runId>].actions`, so leaving them
666
+ * there manufactures phantom "actions" that later get quantified over as if
667
+ * they were blocks (close folds, `actions.forEach`, block counts).
668
+ *
669
+ * DM dedup state is flow-scoped, not run-scoped, so it gets its own map rather
670
+ * than moving under a run.
671
+ *
672
+ * ## Why this module DUAL-WRITES rather than forking one-way
673
+ *
674
+ * The first cut of this move wrote only the new map and kept a **read-only**
675
+ * fallback to the legacy keys. That forks dedup in one direction and reopens
676
+ * the bug it was meant to close:
677
+ *
678
+ * - Before the move both generations shared one key, so dedup worked across
679
+ * them: whoever DM'd first, everyone saw it.
680
+ * - After a one-way fork, an already-deployed client reads **only** the legacy
681
+ * key. Every block a new client notified is invisible to it, so it re-DMs the
682
+ * assignee — one duplicate per block, forever, for as long as an old tab is
683
+ * open.
684
+ *
685
+ * So writes go to **both** places, in one transaction, exactly as
686
+ * `runs.ts#writeActionState` mirrors run state into the flat `runtime` map.
687
+ * Both generations then converge on the same dedup facts.
688
+ *
689
+ * **This is safe only because the legacy keys are `__`-prefixed.**
690
+ * `adoptLegacyRuntime` (`runs.ts`) skips every key starting with
691
+ * `RESERVED_RUNTIME_KEY_PREFIX`, so writing them back into `runtime` cannot
692
+ * leak a phantom "action" into `runs[<runId>].actions`. That coupling is
693
+ * asserted in `dmNotificationState.test.ts` — if the prefix or these key names
694
+ * ever change, that test fails rather than the leak shipping silently.
695
+ *
696
+ * ## The read rule: per-record freshness, NOT blanket precedence
697
+ *
698
+ * Both bags must be merged (an old client only ever writes the legacy one), but
699
+ * a naive union with a fixed winner still misfires, because a dedup record is
700
+ * **overwritten, not accumulated**: `shouldNotify` compares `assignedDid`, so a
701
+ * reassignment rewrites the record for that block. Give either side blanket
702
+ * precedence and the loser's *newer* record gets shadowed by the winner's
703
+ * *older* one — `shouldNotify` sees the previous assignee, and the client
704
+ * re-DMs someone who was already notified.
705
+ *
706
+ * The rule is therefore the same shape as `runs.ts#resolveActionState`: resolve
707
+ * **per record**, newest `notifiedAt` wins, and on a tie the new map wins as a
708
+ * deterministic tiebreak so every peer resolves an identical pair identically.
709
+ * `notifiedAt` is stamped at DM time by whoever sent it, which makes it the
710
+ * natural freshness key — the direct analogue of `executedAt`.
711
+ */
712
+ declare const DM_NOTIFICATIONS_MAP_KEY = "dmNotificationState";
618
713
  interface DMNotificationRecord {
619
714
  /** DID of the assigned actor who was notified */
620
715
  assignedDid: string;
@@ -627,13 +722,24 @@ interface DMNotificationState {
627
722
  [blockId: string]: DMNotificationRecord;
628
723
  }
629
724
  /**
630
- * Read the DM notification dedup state from the runtime Y.Map.
725
+ * Read the DM notification dedup state: the union of the dedicated map and the
726
+ * legacy `runtime` key, resolved **per block** by {@link resolveRecord}.
727
+ *
728
+ * Union, because an already-deployed client only ever writes the legacy key, so
729
+ * a whole-bag fallback would go blind to it the instant the new map became
730
+ * non-empty. Per-record freshness rather than blanket precedence, because a
731
+ * reassignment *overwrites* a block's record — see the module header.
732
+ *
733
+ * PHASE A COMPAT — REMOVAL TRIGGER: when the legacy side stops being written
734
+ * (compat register item 7).
631
735
  */
632
- declare function getDMNotificationState(runtimeMap: Map$1<any>): DMNotificationState;
736
+ declare function getDMNotificationState(yDoc: Doc): DMNotificationState;
633
737
  /**
634
738
  * Write a DM notification record for a block, merging with existing state.
739
+ * Dual-writes the dedicated map and the legacy `runtime` key (one transaction),
740
+ * so both client generations dedup against the same facts.
635
741
  */
636
- declare function setDMNotificationRecord(runtimeMap: Map$1<any>, blockId: string, record: DMNotificationRecord): void;
742
+ declare function setDMNotificationRecord(yDoc: Doc, blockId: string, record: DMNotificationRecord): void;
637
743
  /**
638
744
  * Check whether a DM notification should be sent for a given block.
639
745
  * Returns true if:
@@ -642,4 +748,4 @@ declare function setDMNotificationRecord(runtimeMap: Map$1<any>, blockId: string
642
748
  */
643
749
  declare function shouldNotify(state: DMNotificationState, blockId: string, currentAssignedDid: string): boolean;
644
750
 
645
- export { BaseIconPicker, type BlockActionDefinition, BlocknoteHandlers, type CollapseEvent, type ColumnPosition, type DMNotificationRecord, type DMNotificationState, type DataSource, DebugButton, type DynamicListAction, type DynamicListBlockProps, DynamicListBlockSpec, type DynamicListColumn, type DynamicListPanelConfig, type FillOpenSurveyResult, FlowNodeConfigPanel, type FlowNodeConfigPanelProps, FlowNodePanel, type FlowNodePanelProps, type HookedActionInstanceConfig, type HookedActionType, type HookedActionsConfig, HookedActionsTab, IxoEditorType, type ListBlocksUIContextValue, type Listener, type OpenSurveyContext, type OpenSurveyEntry, type OpenSurveyQuestionSummary, type OpenSurveySnapshot, PageHeader, type PageHeaderMenuItem, type PageHeaderProps, PageTitle, type PageTitleProps, type PayloadField, didToMatrixUserId, fillOpenSurvey, findOrCreateDMRoom, getAllHookedActionTypes, getBlockActions, getDMNotificationState, getHomeserver, getHookedActionType, initializeHookedActions, registerBlockActions, registerBuiltInActionTypes, registerHookedActionType, sendDirectMessage, setDMNotificationRecord, shouldNotify, snapshotOpenSurvey, useHookedActions, useListBlocksUI, useListBlocksUIStore, useNodeContext, useNodeRuntime, useOpenSurveyStore, usePanel, usePanelStore, useRegisterOpenSurvey };
751
+ export { BaseIconPicker, type BlockActionDefinition, BlocknoteHandlers, type CollapseEvent, type ColumnPosition, type DMNotificationRecord, type DMNotificationState, DM_NOTIFICATIONS_MAP_KEY, type DataSource, DebugButton, type DynamicListAction, type DynamicListBlockProps, DynamicListBlockSpec, type DynamicListColumn, type DynamicListPanelConfig, type FillOpenSurveyResult, FlowNodeConfigPanel, type FlowNodeConfigPanelProps, FlowNodePanel, type FlowNodePanelProps, type HookedActionInstanceConfig, type HookedActionType, type HookedActionsConfig, HookedActionsTab, IxoEditorType, type ListBlocksUIContextValue, type Listener, type OpenSurveyContext, type OpenSurveyEntry, type OpenSurveyQuestionSummary, type OpenSurveySnapshot, PageHeader, type PageHeaderMenuItem, type PageHeaderProps, PageTitle, type PageTitleProps, type PayloadField, RunSessionProvider, didToMatrixUserId, fillOpenSurvey, findOrCreateDMRoom, getAllHookedActionTypes, getBlockActions, getDMNotificationState, getHomeserver, getHookedActionType, initializeHookedActions, registerBlockActions, registerBuiltInActionTypes, registerHookedActionType, sendDirectMessage, setDMNotificationRecord, shouldNotify, snapshotOpenSurvey, useHookedActions, useListBlocksUI, useListBlocksUIStore, useNodeContext, useNodeRuntime, useOpenSurveyStore, usePanel, usePanelStore, useRegisterOpenSurvey, useRunEventLog, useRunSessionId };