@ixo/editor 5.25.0 → 5.27.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{chunk-VECEVZ6B.mjs → chunk-MP7Q5F3L.mjs} +3914 -1789
- package/dist/chunk-MP7Q5F3L.mjs.map +1 -0
- package/dist/{chunk-UMS6GCME.mjs → chunk-W5M4NLHK.mjs} +935 -6
- package/dist/chunk-W5M4NLHK.mjs.map +1 -0
- package/dist/core/index.d.ts +4 -4
- package/dist/core/index.mjs +1 -1
- package/dist/{graphql-client-DrJ0WoCv.d.ts → graphql-client-C2YnVMPy.d.ts} +1 -1
- package/dist/{index-CU_uhH5a.d.ts → index-Bdh5jcT4.d.ts} +33 -0
- package/dist/index.d.ts +3 -3
- package/dist/index.mjs +2 -2
- package/dist/mantine/index.d.ts +3 -3
- package/dist/mantine/index.mjs +2 -2
- package/dist/{store-tXzh_kNG.d.ts → store-CiuZEEsv.d.ts} +438 -1
- package/package.json +1 -1
- package/dist/chunk-UMS6GCME.mjs.map +0 -1
- package/dist/chunk-VECEVZ6B.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 { 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-
|
|
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-
|
|
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-CiuZEEsv.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-CiuZEEsv.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-Bdh5jcT4.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-Bdh5jcT4.mjs';
|
|
5
5
|
import * as Y from 'yjs';
|
|
6
6
|
import 'matrix-js-sdk';
|
|
7
7
|
import '@blocknote/core';
|
package/dist/core/index.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as _blocknote_core from '@blocknote/core';
|
|
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-
|
|
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-Bdh5jcT4.mjs';
|
|
3
3
|
import { Text, Doc, Map, Array as Array$1 } from 'yjs';
|
|
4
4
|
import React__default from 'react';
|
|
5
5
|
|
|
@@ -959,6 +959,32 @@ type ClaimCollectionResponse = {
|
|
|
959
959
|
adminAddress: string;
|
|
960
960
|
collections: ClaimCollection[];
|
|
961
961
|
};
|
|
962
|
+
/**
|
|
963
|
+
* A verifiableClaim protocol attached to an entity, derived by hydrating the
|
|
964
|
+
* entity's `linkedClaim[]` (each resolves to `entityClaims[].template`). Used by
|
|
965
|
+
* the claim-collection create config so the protocol the user picks is always
|
|
966
|
+
* one actually linked to the chosen entity, not a free-text DID that can drift.
|
|
967
|
+
*
|
|
968
|
+
* `protocolId` is the normalized `template.id` (with any `{id}` placeholder
|
|
969
|
+
* replaced by the entity DID) — the value stored as the collection's `protocol`.
|
|
970
|
+
*/
|
|
971
|
+
type EntityClaimProtocol = {
|
|
972
|
+
/** Normalized `template.id` — the value persisted as the collection protocol. */
|
|
973
|
+
protocolId: string;
|
|
974
|
+
/** `template.title` — the dropdown label. */
|
|
975
|
+
title: string;
|
|
976
|
+
/** `template.type`, when present. */
|
|
977
|
+
type?: string;
|
|
978
|
+
/** `template.description`, when present. */
|
|
979
|
+
description?: string;
|
|
980
|
+
/** Whether this template is the entity's headline metric. */
|
|
981
|
+
isHeadlineMetric?: boolean;
|
|
982
|
+
/** `false` when the linkedClaim hydrated but carried no template (greyed-out). */
|
|
983
|
+
hasValidClaim: boolean;
|
|
984
|
+
};
|
|
985
|
+
type EntityClaimProtocolsResponse = {
|
|
986
|
+
protocols: EntityClaimProtocol[];
|
|
987
|
+
};
|
|
962
988
|
type Claim = {
|
|
963
989
|
claimId: string;
|
|
964
990
|
collectionId: string;
|
|
@@ -1600,6 +1626,13 @@ interface BlocknoteHandlers {
|
|
|
1600
1626
|
submitText?: string;
|
|
1601
1627
|
}) => Promise<string>;
|
|
1602
1628
|
getClaimCollections: (deedDid: string) => Promise<ClaimCollectionResponse>;
|
|
1629
|
+
/**
|
|
1630
|
+
* List the verifiableClaim protocols attached to an entity, by hydrating the
|
|
1631
|
+
* entity's `linkedClaim[]` to their `entityClaims[].template`. Drives the
|
|
1632
|
+
* claim-collection create config's protocol picker so the selected protocol is
|
|
1633
|
+
* guaranteed to be linked to the chosen entity (IXO-2429).
|
|
1634
|
+
*/
|
|
1635
|
+
getEntityClaimProtocols: (entityDid: string) => Promise<EntityClaimProtocolsResponse>;
|
|
1603
1636
|
getClaimsPerCollectionId: (params: GetClaimsPerCollectionIdParams) => Promise<Claim[]>;
|
|
1604
1637
|
getClaimsPerUserAddress: (params: GetClaimsPerUserAddressParams) => Promise<Claim[]>;
|
|
1605
1638
|
getClaimData: (collectionId: string, claimId: string, options?: {
|
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, 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-
|
|
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-C2YnVMPy.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-CiuZEEsv.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-Bdh5jcT4.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,7 +28,7 @@ import {
|
|
|
28
28
|
useCreateIxoEditor,
|
|
29
29
|
useTrackBlockFocus,
|
|
30
30
|
useTranslate
|
|
31
|
-
} from "./chunk-
|
|
31
|
+
} from "./chunk-MP7Q5F3L.mjs";
|
|
32
32
|
import "./chunk-OK2W66I7.mjs";
|
|
33
33
|
import {
|
|
34
34
|
FlowAgentService,
|
|
@@ -68,7 +68,7 @@ import {
|
|
|
68
68
|
tickFlowAgent,
|
|
69
69
|
validateAgentCommand,
|
|
70
70
|
validateFlowAgentLease
|
|
71
|
-
} from "./chunk-
|
|
71
|
+
} from "./chunk-W5M4NLHK.mjs";
|
|
72
72
|
|
|
73
73
|
// src/index.ts
|
|
74
74
|
import { cloneDocument } from "@ixo/matrix-crdt";
|
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-C2YnVMPy.mjs';
|
|
2
2
|
import React__default, { PropsWithChildren } from 'react';
|
|
3
|
-
import { ao as IxoBlockProps, a4 as IxoEditorType, w as BlocknoteHandlers, a5 as FlowNodeRuntimeState } from '../index-
|
|
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-
|
|
3
|
+
import { ao as IxoBlockProps, a4 as IxoEditorType, w as BlocknoteHandlers, a5 as FlowNodeRuntimeState } from '../index-Bdh5jcT4.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-Bdh5jcT4.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-MP7Q5F3L.mjs";
|
|
58
58
|
import {
|
|
59
59
|
didToMatrixUserId,
|
|
60
60
|
findOrCreateDMRoom,
|
|
61
61
|
getHomeserver,
|
|
62
62
|
sendDirectMessage
|
|
63
|
-
} from "../chunk-
|
|
63
|
+
} from "../chunk-W5M4NLHK.mjs";
|
|
64
64
|
export {
|
|
65
65
|
ApiRequestBlockSpec,
|
|
66
66
|
AuthorizationTab,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { a7 as FlowNode, ac as FlowNodeAuthzExtension, a5 as FlowNodeRuntimeState, a4 as IxoEditorType, f as UcanService, I as InvocationStore, aa as EvaluationStatus, i as UcanCapability, U as UcanDelegationStore, S as StoredDelegation } from './index-
|
|
1
|
+
import { a7 as FlowNode, ac as FlowNodeAuthzExtension, a5 as FlowNodeRuntimeState, a4 as IxoEditorType, f as UcanService, I as InvocationStore, aa as EvaluationStatus, i as UcanCapability, U as UcanDelegationStore, S as StoredDelegation } from './index-Bdh5jcT4.mjs';
|
|
2
2
|
import * as Y from 'yjs';
|
|
3
3
|
import { Doc, Map } from 'yjs';
|
|
4
4
|
import { MatrixClient } from 'matrix-js-sdk';
|
|
@@ -238,6 +238,256 @@ interface ActionContext {
|
|
|
238
238
|
editor?: any;
|
|
239
239
|
pendingInvocation?: any;
|
|
240
240
|
}
|
|
241
|
+
/**
|
|
242
|
+
* Lifecycle state of an IXO claims-module collection.
|
|
243
|
+
*
|
|
244
|
+
* Mirrors `ixo.claims.v1beta1.CollectionState` (the on-chain enum). Carried as
|
|
245
|
+
* a numeric enum at this boundary so the consumer-side handler can map it
|
|
246
|
+
* directly onto the SDK enum without a string lookup.
|
|
247
|
+
*
|
|
248
|
+
* - `OPEN` (0) — accepting claims/bids.
|
|
249
|
+
* - `PAUSED` (1) — temporarily not accepting submissions.
|
|
250
|
+
* - `CLOSED` (2) — permanently closed.
|
|
251
|
+
*/
|
|
252
|
+
declare enum CollectionStateEnum {
|
|
253
|
+
OPEN = 0,
|
|
254
|
+
PAUSED = 1,
|
|
255
|
+
CLOSED = 2
|
|
256
|
+
}
|
|
257
|
+
/**
|
|
258
|
+
* A single coin amount. Mirrors `cosmos.base.v1beta1.Coin`. `amount` is the
|
|
259
|
+
* integer base-denom amount carried as a string (no `Long`/`bigint` at this
|
|
260
|
+
* boundary).
|
|
261
|
+
*/
|
|
262
|
+
interface CollectionCoin {
|
|
263
|
+
denom: string;
|
|
264
|
+
amount: string;
|
|
265
|
+
}
|
|
266
|
+
/**
|
|
267
|
+
* A CW20 token payment leg. Mirrors `ixo.claims.v1beta1.CW20Payment`.
|
|
268
|
+
*/
|
|
269
|
+
interface CollectionCW20Payment {
|
|
270
|
+
address: string;
|
|
271
|
+
/** Integer amount carried as a string. */
|
|
272
|
+
amount: string;
|
|
273
|
+
}
|
|
274
|
+
/**
|
|
275
|
+
* A CW1155 contract payment leg. Mirrors `ixo.claims.v1beta1.Contract1155Payment`.
|
|
276
|
+
*/
|
|
277
|
+
interface CollectionContract1155Payment {
|
|
278
|
+
address: string;
|
|
279
|
+
tokenId: string;
|
|
280
|
+
/** Integer amount carried as a string. */
|
|
281
|
+
amount: string;
|
|
282
|
+
}
|
|
283
|
+
/**
|
|
284
|
+
* One payment leg of a collection (submission / evaluation / approval /
|
|
285
|
+
* rejection). Mirrors `ixo.claims.v1beta1.Payment`.
|
|
286
|
+
*
|
|
287
|
+
* Optional/empty legs are represented by an empty `amount` array. The consumer
|
|
288
|
+
* handler fills `account` with the collection admin address when creating.
|
|
289
|
+
*/
|
|
290
|
+
interface CollectionPayment {
|
|
291
|
+
/** Destination/charging account address. */
|
|
292
|
+
account: string;
|
|
293
|
+
/** Native-coin amounts. Empty when this leg charges nothing in native coin. */
|
|
294
|
+
amount: CollectionCoin[];
|
|
295
|
+
/** Optional CW20 payment legs. */
|
|
296
|
+
cw20Payment?: CollectionCW20Payment[];
|
|
297
|
+
/** Optional CW1155 contract payment. */
|
|
298
|
+
contract_1155Payment?: CollectionContract1155Payment;
|
|
299
|
+
/** Optional payment timeout in nanoseconds, carried as a string. */
|
|
300
|
+
timeoutNs?: string;
|
|
301
|
+
/** Whether this leg is paid by the oracle rather than the claimant. */
|
|
302
|
+
isOraclePayment?: boolean;
|
|
303
|
+
}
|
|
304
|
+
/**
|
|
305
|
+
* The four payment legs of a collection. Mirrors `ixo.claims.v1beta1.Payments`.
|
|
306
|
+
*/
|
|
307
|
+
interface Payments {
|
|
308
|
+
submission?: CollectionPayment;
|
|
309
|
+
evaluation?: CollectionPayment;
|
|
310
|
+
approval?: CollectionPayment;
|
|
311
|
+
rejection?: CollectionPayment;
|
|
312
|
+
}
|
|
313
|
+
/**
|
|
314
|
+
* Per-intent configuration for a collection. Mirrors the
|
|
315
|
+
* `ixo.claims.v1beta1.CollectionIntentOptions` shape — controls whether/how
|
|
316
|
+
* claimants can declare an intent before submitting.
|
|
317
|
+
*/
|
|
318
|
+
interface CollectionIntentOptions {
|
|
319
|
+
/** Whether intents are enabled on this collection. */
|
|
320
|
+
allowed?: boolean;
|
|
321
|
+
/** Optional intent timeout in nanoseconds, carried as a string. */
|
|
322
|
+
timeoutNs?: string;
|
|
323
|
+
/** Optional per-intent payment override. */
|
|
324
|
+
payment?: CollectionPayment;
|
|
325
|
+
}
|
|
326
|
+
/**
|
|
327
|
+
* Parameters for creating a collection (`MsgCreateCollection`).
|
|
328
|
+
*
|
|
329
|
+
* `entity` and `protocol` are template configuration; the consumer resolves the
|
|
330
|
+
* `signer`/admin from its own wallet context, so it is not part of this
|
|
331
|
+
* boundary. `quota` is carried as a string (`0` = unlimited).
|
|
332
|
+
*/
|
|
333
|
+
interface CollectionCreateParams {
|
|
334
|
+
/** Entity (deed) DID the collection belongs to. */
|
|
335
|
+
entity: string;
|
|
336
|
+
/** Protocol DID/id the collection follows. */
|
|
337
|
+
protocol: string;
|
|
338
|
+
/** Initial lifecycle state. Defaults to OPEN if omitted by the consumer. */
|
|
339
|
+
state?: CollectionStateEnum;
|
|
340
|
+
/** ISO-8601 start date. */
|
|
341
|
+
startDate?: string;
|
|
342
|
+
/** ISO-8601 end date. */
|
|
343
|
+
endDate?: string;
|
|
344
|
+
/** Max number of claims; `0` = unlimited. Carried as a string. */
|
|
345
|
+
quota?: string;
|
|
346
|
+
/** Payment configuration for the four claim legs. */
|
|
347
|
+
payments?: Payments;
|
|
348
|
+
/** Intent configuration. */
|
|
349
|
+
intents?: CollectionIntentOptions;
|
|
350
|
+
}
|
|
351
|
+
/**
|
|
352
|
+
* The full, canonical on-chain state of a collection, returned by every
|
|
353
|
+
* `collection.*` operation (read or write) and stored verbatim as
|
|
354
|
+
* `runtime.output`. It is never a delta — see IXO-2573: `output` always holds
|
|
355
|
+
* the latest full on-chain collection state.
|
|
356
|
+
*
|
|
357
|
+
* Field names mirror `ixo.claims.v1beta1.Collection`. Numeric chain types
|
|
358
|
+
* (`Long`/uint64) are carried as strings; `state` is the numeric enum.
|
|
359
|
+
*/
|
|
360
|
+
interface CollectionState {
|
|
361
|
+
/** Collection identifier (the chain-assigned id). */
|
|
362
|
+
collectionId: string;
|
|
363
|
+
/** Entity (deed) DID the collection belongs to. */
|
|
364
|
+
entity: string;
|
|
365
|
+
/** Protocol DID/id the collection follows. */
|
|
366
|
+
protocol: string;
|
|
367
|
+
/** Admin address authorised to mutate the collection. */
|
|
368
|
+
admin?: string;
|
|
369
|
+
/** Current lifecycle state. */
|
|
370
|
+
state: CollectionStateEnum;
|
|
371
|
+
/** ISO-8601 start date, if set. */
|
|
372
|
+
startDate?: string;
|
|
373
|
+
/** ISO-8601 end date, if set. */
|
|
374
|
+
endDate?: string;
|
|
375
|
+
/** Max number of claims; `0` = unlimited. Carried as a string. */
|
|
376
|
+
quota: string;
|
|
377
|
+
/** Number of claims submitted so far. Carried as a string. */
|
|
378
|
+
count: string;
|
|
379
|
+
/** Number of claims evaluated so far. Carried as a string. */
|
|
380
|
+
evaluated?: string;
|
|
381
|
+
/** Number of approved claims. Carried as a string. */
|
|
382
|
+
approved?: string;
|
|
383
|
+
/** Number of rejected claims. Carried as a string. */
|
|
384
|
+
rejected?: string;
|
|
385
|
+
/** Number of disputed claims. Carried as a string. */
|
|
386
|
+
disputed?: string;
|
|
387
|
+
/** Payment configuration for the four claim legs. */
|
|
388
|
+
payments?: Payments;
|
|
389
|
+
/** Intent configuration. */
|
|
390
|
+
intents?: CollectionIntentOptions;
|
|
391
|
+
}
|
|
392
|
+
/**
|
|
393
|
+
* Role a grantee holds on a claim collection. Drives which custom claims-module
|
|
394
|
+
* authorization is granted: `submit` → `SubmitClaimAuthorization`,
|
|
395
|
+
* `evaluate` → `EvaluateClaimAuthorization` (each carries `[]constraints`, one
|
|
396
|
+
* per collection). See IXO-2586.
|
|
397
|
+
*/
|
|
398
|
+
type CollectionUserRole = 'submit' | 'evaluate';
|
|
399
|
+
/**
|
|
400
|
+
* One per-collection authorization constraint held by a grantee for a role.
|
|
401
|
+
* Carries the LIVE (decremented) limits as read back from chain — the revoke
|
|
402
|
+
* read-modify-write must preserve these verbatim (IXO-2590), so re-granting
|
|
403
|
+
* from a template would wrongly reset spent quota.
|
|
404
|
+
*/
|
|
405
|
+
interface CollectionGrantee {
|
|
406
|
+
/** Grantee bech32 address. */
|
|
407
|
+
address: string;
|
|
408
|
+
/** Optional resolved DID (display / audit). */
|
|
409
|
+
did?: string;
|
|
410
|
+
/** Role this grant confers. */
|
|
411
|
+
role: CollectionUserRole;
|
|
412
|
+
/** Remaining agent quota; `0` = unlimited. Carried as a string. */
|
|
413
|
+
agentQuota?: string;
|
|
414
|
+
/** Per-claim max amount cap (evaluate role). */
|
|
415
|
+
maxAmount?: CollectionCoin[];
|
|
416
|
+
/** Intent duration in nanoseconds, carried as a string. */
|
|
417
|
+
intentDurationNs?: string;
|
|
418
|
+
}
|
|
419
|
+
/**
|
|
420
|
+
* A member enumerated from a group account, used for grant fan-out. Mirrors the
|
|
421
|
+
* `PODMember` shape produced by the `pod/memberMultiSelect` enumeration
|
|
422
|
+
* (abstracts cw4 members / token-staking stakers / nft-staking / multisig
|
|
423
|
+
* signers).
|
|
424
|
+
*/
|
|
425
|
+
interface CollectionMember {
|
|
426
|
+
address: string;
|
|
427
|
+
did?: string;
|
|
428
|
+
role?: string;
|
|
429
|
+
votingPower?: number;
|
|
430
|
+
}
|
|
431
|
+
/**
|
|
432
|
+
* DAO DAO classification of an address. On IXO both user accounts and CosmWasm
|
|
433
|
+
* contracts share the `ixo1…` prefix, so classification is layered: bech32
|
|
434
|
+
* byte-length heuristic → Wasm `ContractInfo` query → cw2 `{ "info": {} }`
|
|
435
|
+
* smart query (IXO-2592).
|
|
436
|
+
*/
|
|
437
|
+
interface AddressClassification {
|
|
438
|
+
/** `user` = plain account; `contract` = CosmWasm contract / module account. */
|
|
439
|
+
kind: 'user' | 'contract';
|
|
440
|
+
/** Present when `kind === 'contract'` and cw2 info resolved a DAO DAO group type. */
|
|
441
|
+
daodao?: {
|
|
442
|
+
/** cw2 contract name family, e.g. `dao-dao-core`, `cw4-group`, `dao-voting-cw4`. */
|
|
443
|
+
type: string;
|
|
444
|
+
/** Whether the contract can itself exercise a granted authz (only dao-core can MsgExec). */
|
|
445
|
+
canExerciseGrant: boolean;
|
|
446
|
+
};
|
|
447
|
+
}
|
|
448
|
+
/**
|
|
449
|
+
* Provenance/identity of a carbon batch (= a CARBON token group; the batch id
|
|
450
|
+
* is the on-chain token id). `entityDid` + `adminAddress` identify the entity
|
|
451
|
+
* admin account the batch was minted from — both are REQUIRED to construct a
|
|
452
|
+
* harvest (the authz grant + exec transfer target that account). The host
|
|
453
|
+
* `loadBatches` handler performs provenance recovery for transferred batches so
|
|
454
|
+
* these are populated before the editor ever sees them. See the carbon-credit
|
|
455
|
+
* technical doc §4–§5 (IXO-2675).
|
|
456
|
+
*/
|
|
457
|
+
interface CarbonBatchRef {
|
|
458
|
+
/** Token/batch id. */
|
|
459
|
+
id: string;
|
|
460
|
+
/** Minter entity DID. */
|
|
461
|
+
entityDid: string;
|
|
462
|
+
/** Entity admin account address (the FROM account for a harvest transfer). */
|
|
463
|
+
adminAddress: string;
|
|
464
|
+
/** Human-readable entity name, for display. */
|
|
465
|
+
alsoKnownAs?: string;
|
|
466
|
+
}
|
|
467
|
+
/**
|
|
468
|
+
* A harvestable batch: held on an entity admin account the user owns but not
|
|
469
|
+
* yet pulled into their wallet. `claimable` = the admin-held amount that
|
|
470
|
+
* becomes the user's on harvest.
|
|
471
|
+
*/
|
|
472
|
+
interface CarbonHarvestableBatch extends CarbonBatchRef {
|
|
473
|
+
/** Harvestable amount (admin-held; becomes user `amount` after harvest). */
|
|
474
|
+
claimable: number;
|
|
475
|
+
}
|
|
476
|
+
/**
|
|
477
|
+
* A retireable batch: credits the user already holds in their wallet and can
|
|
478
|
+
* burn/offset. `entityDid` is best-effort (display/provenance) and not required
|
|
479
|
+
* to retire — retirement is a single owner-signed message.
|
|
480
|
+
*/
|
|
481
|
+
interface CarbonRetireableBatch {
|
|
482
|
+
/** Token/batch id. */
|
|
483
|
+
id: string;
|
|
484
|
+
/** Amount available in the user's wallet to retire. */
|
|
485
|
+
amount: number;
|
|
486
|
+
/** Minter entity DID, when known. */
|
|
487
|
+
entityDid?: string;
|
|
488
|
+
/** Human-readable entity name, for display. */
|
|
489
|
+
alsoKnownAs?: string;
|
|
490
|
+
}
|
|
241
491
|
interface ActionServices {
|
|
242
492
|
http?: {
|
|
243
493
|
request: (params: {
|
|
@@ -369,6 +619,132 @@ interface ActionServices {
|
|
|
369
619
|
};
|
|
370
620
|
createUdid?: (params: any) => Promise<any>;
|
|
371
621
|
};
|
|
622
|
+
/**
|
|
623
|
+
* Claims-module collection lifecycle service. The editor declares the
|
|
624
|
+
* contract only; the consumer app implements each method (broadcast on chain,
|
|
625
|
+
* resolve admin from its wallet context, map string<->Long).
|
|
626
|
+
*
|
|
627
|
+
* Per IXO-2573, each write op should broadcast then the dispatcher re-fetches
|
|
628
|
+
* via `get(...)` so `runtime.output` always holds the latest full
|
|
629
|
+
* `CollectionState`. `get` is the read-only `refresh` primitive.
|
|
630
|
+
*/
|
|
631
|
+
collection?: {
|
|
632
|
+
/** Read the full current on-chain state of a collection. */
|
|
633
|
+
get: (params: {
|
|
634
|
+
collectionId: string;
|
|
635
|
+
}) => Promise<CollectionState>;
|
|
636
|
+
/** Broadcast `MsgCreateCollection`. Returns the new collectionId + tx hash. */
|
|
637
|
+
create: (params: CollectionCreateParams) => Promise<{
|
|
638
|
+
transactionHash: string;
|
|
639
|
+
collectionId: string;
|
|
640
|
+
}>;
|
|
641
|
+
/** Broadcast `MsgUpdateCollectionState`. */
|
|
642
|
+
updateState: (params: {
|
|
643
|
+
collectionId: string;
|
|
644
|
+
state: CollectionStateEnum;
|
|
645
|
+
adminAddress: string;
|
|
646
|
+
}) => Promise<{
|
|
647
|
+
transactionHash: string;
|
|
648
|
+
}>;
|
|
649
|
+
/** Broadcast `MsgUpdateCollectionDates`. */
|
|
650
|
+
updateDates: (params: {
|
|
651
|
+
collectionId: string;
|
|
652
|
+
startDate?: string;
|
|
653
|
+
endDate?: string;
|
|
654
|
+
adminAddress: string;
|
|
655
|
+
}) => Promise<{
|
|
656
|
+
transactionHash: string;
|
|
657
|
+
}>;
|
|
658
|
+
/** Broadcast `MsgUpdateCollectionQuota`. `quota` carried as a string; `0` = unlimited. */
|
|
659
|
+
updateQuota: (params: {
|
|
660
|
+
collectionId: string;
|
|
661
|
+
quota: string;
|
|
662
|
+
adminAddress: string;
|
|
663
|
+
}) => Promise<{
|
|
664
|
+
transactionHash: string;
|
|
665
|
+
}>;
|
|
666
|
+
/** Broadcast `MsgUpdateCollectionPayments`. */
|
|
667
|
+
updatePayments: (params: {
|
|
668
|
+
collectionId: string;
|
|
669
|
+
payments: Payments;
|
|
670
|
+
adminAddress: string;
|
|
671
|
+
}) => Promise<{
|
|
672
|
+
transactionHash: string;
|
|
673
|
+
}>;
|
|
674
|
+
/** Broadcast `MsgUpdateCollectionIntents`. */
|
|
675
|
+
updateIntents: (params: {
|
|
676
|
+
collectionId: string;
|
|
677
|
+
intents: CollectionIntentOptions;
|
|
678
|
+
adminAddress: string;
|
|
679
|
+
}) => Promise<{
|
|
680
|
+
transactionHash: string;
|
|
681
|
+
}>;
|
|
682
|
+
};
|
|
683
|
+
/**
|
|
684
|
+
* Claim-collection user-management service (IXO-2586). The editor declares the
|
|
685
|
+
* contract only; the consumer app implements each method (build/broadcast the
|
|
686
|
+
* claims-module authz messages, query authz grants, classify addresses,
|
|
687
|
+
* enumerate group members). Extends → replaces the reactive `bid` service.
|
|
688
|
+
*/
|
|
689
|
+
collectionUsers?: {
|
|
690
|
+
/**
|
|
691
|
+
* Grant submit/evaluate authz for ONE collection to a grantee. The handler
|
|
692
|
+
* reads the grantee's existing authz for the role's msgTypeUrl and APPENDS a
|
|
693
|
+
* per-collection constraint (preserving other collections' live values),
|
|
694
|
+
* then broadcasts `MsgCreateClaimAuthorization` routed via
|
|
695
|
+
* `MsgGrantEntityAccountAuthz` (entity admin = granter). See IXO-2589.
|
|
696
|
+
*/
|
|
697
|
+
grant: (params: {
|
|
698
|
+
granterAdminAddress: string;
|
|
699
|
+
granteeAddress: string;
|
|
700
|
+
collectionId: string;
|
|
701
|
+
role: CollectionUserRole;
|
|
702
|
+
agentQuota?: string;
|
|
703
|
+
maxAmount?: CollectionCoin[];
|
|
704
|
+
intentDurationNs?: string;
|
|
705
|
+
deedDid?: string;
|
|
706
|
+
}) => Promise<{
|
|
707
|
+
transactionHash: string;
|
|
708
|
+
}>;
|
|
709
|
+
/**
|
|
710
|
+
* Per-collection read-modify-write revoke (IXO-2590). Reads the grantee's
|
|
711
|
+
* live authz, drops the target collection's constraint, and — when other
|
|
712
|
+
* constraints remain — broadcasts a single atomic tx ordered
|
|
713
|
+
* `[MsgRevokeEntityAccountAuthz, then one MsgCreateClaimAuthorization per
|
|
714
|
+
* remaining constraint]`, preserving each remaining constraint's live
|
|
715
|
+
* (decremented) quota/limits. Short-circuits to a plain revoke when the
|
|
716
|
+
* target was the only constraint.
|
|
717
|
+
*/
|
|
718
|
+
revoke: (params: {
|
|
719
|
+
granterAdminAddress: string;
|
|
720
|
+
granteeAddress: string;
|
|
721
|
+
collectionId: string;
|
|
722
|
+
role: CollectionUserRole;
|
|
723
|
+
}) => Promise<{
|
|
724
|
+
transactionHash: string;
|
|
725
|
+
}>;
|
|
726
|
+
/**
|
|
727
|
+
* List the grantees holding a submit/evaluate constraint for a collection.
|
|
728
|
+
* Queries authz grants against the entity admin account, decodes the
|
|
729
|
+
* authorizations, and filters constraints by `collectionId` (IXO-2591).
|
|
730
|
+
*/
|
|
731
|
+
list: (params: {
|
|
732
|
+
granterAdminAddress: string;
|
|
733
|
+
collectionId: string;
|
|
734
|
+
}) => Promise<{
|
|
735
|
+
grantees: CollectionGrantee[];
|
|
736
|
+
}>;
|
|
737
|
+
/** Classify an address as a plain user vs a DAO DAO contract (IXO-2592). */
|
|
738
|
+
classifyAddress: (params: {
|
|
739
|
+
address: string;
|
|
740
|
+
}) => Promise<AddressClassification>;
|
|
741
|
+
/** Enumerate the members of a group account for grant fan-out (IXO-2592). */
|
|
742
|
+
enumerateMembers: (params: {
|
|
743
|
+
groupAddress: string;
|
|
744
|
+
}) => Promise<{
|
|
745
|
+
members: CollectionMember[];
|
|
746
|
+
}>;
|
|
747
|
+
};
|
|
372
748
|
matrix?: {
|
|
373
749
|
storeCredential: (params: {
|
|
374
750
|
roomId: string;
|
|
@@ -594,6 +970,67 @@ interface ActionServices {
|
|
|
594
970
|
transactionHash: string;
|
|
595
971
|
}>;
|
|
596
972
|
};
|
|
973
|
+
/**
|
|
974
|
+
* Carbon credit batch service (IXO-2675). The editor declares the contract
|
|
975
|
+
* only; the consumer app implements each method (run the owner/admin
|
|
976
|
+
* reconciliation read, build + broadcast the harvest grant/exec pair and the
|
|
977
|
+
* retire message, sign via its own wallet/SignX). Both writes are USER-signed
|
|
978
|
+
* — the editor never signs on the user's behalf.
|
|
979
|
+
*/
|
|
980
|
+
carbon?: {
|
|
981
|
+
/**
|
|
982
|
+
* Reconcile the user's owner-side and entity-admin-side batches into the
|
|
983
|
+
* unified view. Pure read (no signing). Performs provenance recovery for
|
|
984
|
+
* transferred batches so every `harvestableBatch` carries `entityDid` +
|
|
985
|
+
* `adminAddress`. See technical doc §3–§4.
|
|
986
|
+
*/
|
|
987
|
+
loadBatches: (params: {
|
|
988
|
+
ownerAddress: string;
|
|
989
|
+
}) => Promise<{
|
|
990
|
+
harvestableBatches: CarbonHarvestableBatch[];
|
|
991
|
+
retireableBatches: CarbonRetireableBatch[];
|
|
992
|
+
totalClaimable: number;
|
|
993
|
+
totalAvailable: number;
|
|
994
|
+
totalRetired: number;
|
|
995
|
+
}>;
|
|
996
|
+
/**
|
|
997
|
+
* Harvest (claim) the given batches: per entity, grant the owner authz to
|
|
998
|
+
* transfer out of the entity admin account, then exec that transfer into
|
|
999
|
+
* the owner's wallet (ordered pairs, 30-min grant). User-signed. See §5.2.
|
|
1000
|
+
*/
|
|
1001
|
+
harvest: (params: {
|
|
1002
|
+
ownerAddress: string;
|
|
1003
|
+
tokens: Array<{
|
|
1004
|
+
id: string;
|
|
1005
|
+
entityDid: string;
|
|
1006
|
+
adminAddress: string;
|
|
1007
|
+
claimable: number;
|
|
1008
|
+
}>;
|
|
1009
|
+
}) => Promise<{
|
|
1010
|
+
transactionHash: string;
|
|
1011
|
+
harvestedBatchIds: string[];
|
|
1012
|
+
harvestedAmount: number;
|
|
1013
|
+
}>;
|
|
1014
|
+
/**
|
|
1015
|
+
* Retire (burn/offset) the given amounts from the owner's wallet. Single
|
|
1016
|
+
* owner-signed `MsgRetireToken`. Irreversible. `jurisdiction` arrives
|
|
1017
|
+
* pre-composed as a string (default "Global"); `reason` defaults to
|
|
1018
|
+
* "offset". See §5.1.
|
|
1019
|
+
*/
|
|
1020
|
+
retire: (params: {
|
|
1021
|
+
owner: string;
|
|
1022
|
+
reason?: string;
|
|
1023
|
+
jurisdiction?: string;
|
|
1024
|
+
tokens: Array<{
|
|
1025
|
+
id: string;
|
|
1026
|
+
amount: number;
|
|
1027
|
+
}>;
|
|
1028
|
+
}) => Promise<{
|
|
1029
|
+
transactionHash: string;
|
|
1030
|
+
retiredBatchIds: string[];
|
|
1031
|
+
retiredAmount: number;
|
|
1032
|
+
}>;
|
|
1033
|
+
};
|
|
597
1034
|
}
|
|
598
1035
|
interface OutputSchemaField {
|
|
599
1036
|
path: string;
|