import * as _blocknote_core from '@blocknote/core';
import { ac as IxoBlockProps, l as IxoEditorOptions, W as IxoEditorType, p as IxoCollaborativeEditorOptions, w as BlocknoteHandlers, y as BlockRequirements, aj as UnlMapConfig, af as DynamicListDataProvider, ag as DynamicListPanelRenderer, ah as DomainCardRenderer, R as Translate, k as DelegationGrant } from './index-C0ikjICf.mjs';
import { Text, Doc, Map, Array as Array$1 } from 'yjs';
import React__default from 'react';

declare const CheckboxBlockSpec: {
    config: {
        readonly type: "checkbox";
        readonly propSchema: {
            readonly checked: {
                readonly default: false;
            };
            readonly allowedCheckers: {
                readonly default: "all";
            };
            readonly initialChecked: {
                readonly default: false;
            };
            readonly title: {
                readonly default: "";
            };
            readonly description: {
                readonly default: "";
            };
            readonly icon: {
                readonly default: "square-check";
            };
            readonly conditions: {
                readonly default: "";
            };
            readonly ttlAbsoluteDueDate: {
                readonly default: "";
            };
            readonly ttlFromEnablement: {
                readonly default: "";
            };
            readonly ttlFromCommitment: {
                readonly default: "";
            };
            readonly skill: {
                readonly default: "";
            };
        };
        readonly content: "none";
    };
    implementation: _blocknote_core.TiptapBlockImplementation<{
        readonly type: "checkbox";
        readonly propSchema: {
            readonly checked: {
                readonly default: false;
            };
            readonly allowedCheckers: {
                readonly default: "all";
            };
            readonly initialChecked: {
                readonly default: false;
            };
            readonly title: {
                readonly default: "";
            };
            readonly description: {
                readonly default: "";
            };
            readonly icon: {
                readonly default: "square-check";
            };
            readonly conditions: {
                readonly default: "";
            };
            readonly ttlAbsoluteDueDate: {
                readonly default: "";
            };
            readonly ttlFromEnablement: {
                readonly default: "";
            };
            readonly ttlFromCommitment: {
                readonly default: "";
            };
            readonly skill: {
                readonly default: "";
            };
        };
        readonly content: "none";
    }, any, _blocknote_core.InlineContentSchema, _blocknote_core.StyleSchema>;
};

type CheckboxBlockProps = IxoBlockProps;

declare const ListBlockSpec: {
    config: {
        readonly type: "list";
        readonly propSchema: {
            readonly listType: {
                readonly default: "";
            };
            readonly sort: {
                readonly default: "{}";
            };
            readonly filter: {
                readonly default: "{}";
            };
            readonly filterOptions: {
                readonly default: "{}";
            };
            readonly sortOptions: {
                readonly default: "{}";
            };
            readonly listConfig: {
                readonly default: "{}";
            };
            readonly icon: {
                readonly default: "📋";
            };
            readonly skill: {
                readonly default: "";
            };
        };
        readonly content: "none";
    };
    implementation: _blocknote_core.TiptapBlockImplementation<{
        readonly type: "list";
        readonly propSchema: {
            readonly listType: {
                readonly default: "";
            };
            readonly sort: {
                readonly default: "{}";
            };
            readonly filter: {
                readonly default: "{}";
            };
            readonly filterOptions: {
                readonly default: "{}";
            };
            readonly sortOptions: {
                readonly default: "{}";
            };
            readonly listConfig: {
                readonly default: "{}";
            };
            readonly icon: {
                readonly default: "📋";
            };
            readonly skill: {
                readonly default: "";
            };
        };
        readonly content: "none";
    }, any, _blocknote_core.InlineContentSchema, _blocknote_core.StyleSchema>;
};

interface ListBlockSettings {
    listType: string | null;
    listConfig: string;
}
interface ListBlockProps extends IxoBlockProps {
}

interface OverviewBlockProps {
    block: any;
    editor: any;
}
declare const OverviewBlock: {
    config: {
        readonly type: "overview";
        readonly propSchema: {
            readonly skill: {
                readonly default: "";
            };
        };
        readonly content: "none";
    };
    implementation: _blocknote_core.TiptapBlockImplementation<{
        readonly type: "overview";
        readonly propSchema: {
            readonly skill: {
                readonly default: "";
            };
        };
        readonly content: "none";
    }, any, _blocknote_core.InlineContentSchema, _blocknote_core.StyleSchema>;
};

declare const ProposalBlockSpec: {
    config: {
        readonly type: "proposal";
        readonly propSchema: {
            readonly status: {
                readonly default: "draft";
                readonly values: readonly ["draft", "open", "passed", "rejected", "executed", "closed", "execution_failed", "veto_timelock"];
            };
            readonly title: {
                readonly default: "";
            };
            readonly description: {
                readonly default: "";
            };
            readonly icon: {
                readonly default: "file-text";
            };
            readonly proposalId: {
                readonly default: "";
            };
            readonly actions: {
                readonly default: "[]";
            };
            readonly voteEnabled: {
                readonly default: true;
            };
            readonly voteTitle: {
                readonly default: "";
            };
            readonly voteSubtitle: {
                readonly default: "";
            };
            readonly voteIcon: {
                readonly default: "checklist";
            };
            readonly daysLeft: {
                readonly default: 0;
            };
            readonly proposalContractAddress: {
                readonly default: "";
            };
            readonly coreAddress: {
                readonly default: "";
            };
            readonly conditions: {
                readonly default: "";
            };
            readonly ttlAbsoluteDueDate: {
                readonly default: "";
            };
            readonly ttlFromEnablement: {
                readonly default: "";
            };
            readonly ttlFromCommitment: {
                readonly default: "";
            };
            readonly skill: {
                readonly default: "";
            };
        };
        readonly content: "none";
    };
    implementation: _blocknote_core.TiptapBlockImplementation<{
        readonly type: "proposal";
        readonly propSchema: {
            readonly status: {
                readonly default: "draft";
                readonly values: readonly ["draft", "open", "passed", "rejected", "executed", "closed", "execution_failed", "veto_timelock"];
            };
            readonly title: {
                readonly default: "";
            };
            readonly description: {
                readonly default: "";
            };
            readonly icon: {
                readonly default: "file-text";
            };
            readonly proposalId: {
                readonly default: "";
            };
            readonly actions: {
                readonly default: "[]";
            };
            readonly voteEnabled: {
                readonly default: true;
            };
            readonly voteTitle: {
                readonly default: "";
            };
            readonly voteSubtitle: {
                readonly default: "";
            };
            readonly voteIcon: {
                readonly default: "checklist";
            };
            readonly daysLeft: {
                readonly default: 0;
            };
            readonly proposalContractAddress: {
                readonly default: "";
            };
            readonly coreAddress: {
                readonly default: "";
            };
            readonly conditions: {
                readonly default: "";
            };
            readonly ttlAbsoluteDueDate: {
                readonly default: "";
            };
            readonly ttlFromEnablement: {
                readonly default: "";
            };
            readonly ttlFromCommitment: {
                readonly default: "";
            };
            readonly skill: {
                readonly default: "";
            };
        };
        readonly content: "none";
    }, any, _blocknote_core.InlineContentSchema, _blocknote_core.StyleSchema>;
};

type ProposalBlockProps = IxoBlockProps;

declare const ApiRequestBlockSpec: {
    config: {
        readonly type: "apiRequest";
        readonly propSchema: {
            readonly title: {
                readonly default: "";
            };
            readonly description: {
                readonly default: "";
            };
            readonly icon: {
                readonly default: "square-check";
            };
            readonly endpoint: {
                readonly default: "";
            };
            readonly method: {
                readonly default: "GET";
            };
            readonly headers: {
                readonly default: "[]";
            };
            readonly body: {
                readonly default: "[]";
            };
            readonly response: {
                readonly default: "";
            };
            readonly status: {
                readonly default: "idle";
            };
            readonly responseSchema: {
                readonly default: "";
            };
            readonly conditions: {
                readonly default: "";
            };
            readonly ttlAbsoluteDueDate: {
                readonly default: "";
            };
            readonly ttlFromEnablement: {
                readonly default: "";
            };
            readonly ttlFromCommitment: {
                readonly default: "";
            };
            readonly assignment: {
                readonly default: string;
            };
            readonly commitment: {
                readonly default: string;
            };
            readonly skill: {
                readonly default: "";
            };
        };
        readonly content: "none";
    };
    implementation: _blocknote_core.TiptapBlockImplementation<{
        readonly type: "apiRequest";
        readonly propSchema: {
            readonly title: {
                readonly default: "";
            };
            readonly description: {
                readonly default: "";
            };
            readonly icon: {
                readonly default: "square-check";
            };
            readonly endpoint: {
                readonly default: "";
            };
            readonly method: {
                readonly default: "GET";
            };
            readonly headers: {
                readonly default: "[]";
            };
            readonly body: {
                readonly default: "[]";
            };
            readonly response: {
                readonly default: "";
            };
            readonly status: {
                readonly default: "idle";
            };
            readonly responseSchema: {
                readonly default: "";
            };
            readonly conditions: {
                readonly default: "";
            };
            readonly ttlAbsoluteDueDate: {
                readonly default: "";
            };
            readonly ttlFromEnablement: {
                readonly default: "";
            };
            readonly ttlFromCommitment: {
                readonly default: "";
            };
            readonly assignment: {
                readonly default: string;
            };
            readonly commitment: {
                readonly default: string;
            };
            readonly skill: {
                readonly default: "";
            };
        };
        readonly content: "none";
    }, any, _blocknote_core.InlineContentSchema, _blocknote_core.StyleSchema>;
};

type ApiRequestBlockProps = IxoBlockProps;
type HttpMethod = 'GET' | 'POST' | 'PUT' | 'DELETE' | 'PATCH';
type KeyValuePair = {
    key: string;
    value: string;
};

/**
 * Custom hook that wraps useCreateBlockNote with IXO-specific configurations (Mantine version)
 * @param options - Configuration options for the IxoEditor
 * @returns A configured IxoEditor instance with augmented type properties
 */
declare function useCreateIxoEditor(options?: IxoEditorOptions): IxoEditorType | undefined;

/**
 * Custom hook that wraps useCreateBlockNote with IXO-specific configurations (Mantine version)
 * @param options - Configuration options for the IxoEditor
 * @returns A configured collaborative IxoEditor instance with augmented type properties
 */
declare function useCreateCollaborativeIxoEditor(options: IxoCollaborativeEditorOptions): {
    editor: IxoEditorType | undefined;
    connectionStatus: string;
    title: Text;
    yDoc: Doc;
    root: Map<any>;
    flowArray: Array$1<any>;
    connectedUsers: Array<{
        clientId: string;
        state: any;
    }>;
    awarenessInstance: any;
};

/** Position info passed to drop callback */
interface DropPosition {
    blockId: string;
    placement: 'before' | 'after';
    index: number;
}
interface ExternalDropZoneProps {
    /** Editor instance to get block positions from */
    editor: any;
    /** Callback when external data is dropped or placed - position only, caller handles data */
    onDrop: (position: DropPosition) => void;
    /** MIME type to accept (default: 'application/x-artifact') */
    acceptedType?: string;
    /** Drop indicator element to show (provided by caller, already has data) */
    dropIndicator?: React__default.ReactNode;
    /** Whether placement mode is active (click-to-place) */
    isPlacementMode?: boolean;
    /** Callback when placement mode should be canceled */
    onPlacementCancel?: () => void;
    /** Children (the editor content) */
    children: React__default.ReactNode;
}
declare const ExternalDropZone: React__default.FC<ExternalDropZoneProps>;

interface IxoEditorProps {
    editor: IxoEditorType | undefined;
    editable?: boolean;
    className?: string;
    onChange?: () => void;
    onSelectionChange?: () => void;
    children?: React__default.ReactNode;
    mantineTheme?: any;
    handlers?: BlocknoteHandlers;
    blockRequirements?: BlockRequirements;
    mapConfig?: UnlMapConfig;
    isPanelVisible?: boolean;
    coverImageUrl?: string;
    logoUrl?: string;
    visualizationRenderer?: (vizType: string, config: object) => React__default.ReactNode;
    getDynamicListData?: DynamicListDataProvider;
    dynamicListPanelRenderer?: DynamicListPanelRenderer;
    domainCardRenderer?: DomainCardRenderer;
    /** Callback when external content is dropped into the editor (receives position only) */
    onExternalDrop?: (position: DropPosition) => void;
    /** MIME type to accept for external drops (default: 'application/x-artifact') */
    externalDropType?: string;
    /** Drop indicator element to show during drag (caller provides with data already populated) */
    dropIndicator?: React__default.ReactNode;
    /** Whether placement mode is active (click-to-place) */
    isPlacementMode?: boolean;
    /** Callback when placement mode should be canceled */
    onPlacementCancel?: () => void;
    /** Connected users from awareness (for block presence) */
    connectedUsers?: Array<{
        clientId: string;
        state: any;
    }>;
    /** Yjs awareness instance (for block presence) */
    awarenessInstance?: any;
    /** Slot rendered between the page title and the editor body (e.g. a details strip). */
    belowTitleSlot?: React__default.ReactNode;
    /** Translation function — pass `t` from the host app's i18n setup. Optional. */
    translate?: Translate;
}
/**
 * IxoEditor component - A customized BlockNote editor for IXO (Mantine UI)
 */
declare function IxoEditor({ editor, editable, className, onChange, onSelectionChange, children, mantineTheme: _mantineTheme, handlers, blockRequirements, isPanelVisible, coverImageUrl, logoUrl, visualizationRenderer, getDynamicListData, dynamicListPanelRenderer, domainCardRenderer, onExternalDrop, externalDropType, dropIndicator, isPlacementMode, onPlacementCancel, mapConfig, connectedUsers, awarenessInstance, belowTitleSlot, translate, }: IxoEditorProps): React__default.ReactElement | null;

interface CoverImageProps {
    coverImageUrl?: string;
    logoUrl?: string;
}
declare function CoverImage({ coverImageUrl, logoUrl }: CoverImageProps): React__default.ReactElement | null;

/** @deprecated The activation gating fields were removed; this type is kept
 *  empty for any external imports during the transition. */
type AuthorizationTabState = Record<string, never>;
interface AuthorizationTabProps extends IxoBlockProps {
    /** Flow URI for capability scoping */
    flowUri?: string;
    /** Entity DID that owns this flow */
    entityDid?: string;
    /** Callback to open flow permissions panel */
    onOpenFlowPermissions?: () => void;
}
declare const AuthorizationTab: React__default.FC<AuthorizationTabProps>;

type EvaluationTabState = {
    linkedClaimCollectionId: string;
};
interface EvaluationTabProps extends IxoBlockProps {
}
declare const EvaluationTab: React__default.FC<EvaluationTabProps>;

interface EntitySigningSetupProps {
    opened: boolean;
    onClose: () => void;
    entityDid: string;
    entityName?: string;
    onSetup: (pin: string) => Promise<{
        success: boolean;
        error?: string;
    }>;
}
declare const EntitySigningSetup: React__default.FC<EntitySigningSetupProps>;

interface FlowPermissionsPanelProps {
    editor: IxoEditorType;
    entityDid: string;
    entityName?: string;
    currentUserDid: string;
    onGrantPermission: () => void;
    onRevokePermission: (capabilityId: string) => Promise<void>;
    getUserDisplayName?: (did: string) => Promise<string>;
}
declare const FlowPermissionsPanel: React__default.FC<FlowPermissionsPanelProps>;

interface GrantPermissionModalProps {
    opened: boolean;
    onClose: () => void;
    flowUri: string;
    /** Blocks available for scope selection. If single block, scope UI is hidden. */
    blocks: Array<{
        id: string;
        type: string;
        name?: string;
    }>;
    /** Optional: specific block to grant permission for (hides scope selection) */
    targetBlockId?: string;
    searchUsers: (query: string) => Promise<Array<{
        did: string;
        displayName: string;
        avatarUrl?: string;
    }>>;
    getOracles?: () => Promise<Array<{
        did: string;
        name: string;
    }>>;
    onGrant: (grant: DelegationGrant, pin: string) => Promise<{
        success: boolean;
        error?: string;
    }>;
}
declare const GrantPermissionModal: React__default.FC<GrantPermissionModalProps>;

interface BlockPresenceUser {
    clientId: string;
    name: string;
    color: string;
    avatar?: string;
}
/**
 * Hook that returns the list of users currently active on a specific block.
 * Subscribes directly to awareness changes for reliable updates.
 * @param blockId - The block ID to check presence for
 * @param options.includeSelf - If true, includes the local user in the results (default: false)
 */
declare function useBlockPresence(blockId: string | undefined, options?: {
    includeSelf?: boolean;
}): BlockPresenceUser[];

/**
 * Hook that tracks when a user interacts with a block and updates awareness state.
 * Returns event handlers (onPointerDown) to attach to block containers.
 *
 * For custom (non-editable) blocks: attach the returned onPointerDown to the container.
 * For text blocks: use editor-level onSelectionChange instead.
 */
declare function useTrackBlockFocus(blockId: string | undefined, editor: IxoEditorType | undefined): {
    onPointerDown: () => void;
};

/**
 * GraphQL queries and types for IXO network
 */
interface Entity {
    context: string;
    relayerNode: string;
    controller: string;
    id: string;
    type: string;
    startDate: string;
    endDate: string;
    metadata: string;
    linkedResource: any[];
    settings: Record<string, Record<string, any>>;
    service: string;
    externalId: string;
}
interface EntityResponse {
    entity: Entity;
}
interface EntityVariables {
    entityId: string;
}
/**
 * Fetches entity data by ID from the IXO network
 * @param entityId - The unique identifier for the entity
 * @returns Promise resolving to the entity data
 */
declare function getEntity(entityId: string): Promise<Entity>;

/**
 * Lightweight GraphQL client for IXO network queries
 */
interface GraphQLResponse<T = any> {
    data?: T;
    errors?: Array<{
        message: string;
        locations?: Array<{
            line: number;
            column: number;
        }>;
        path?: Array<string | number>;
    }>;
}
interface GraphQLRequest {
    query: string;
    variables?: Record<string, any>;
    operationName?: string;
}
declare class GraphQLClient {
    private endpoint;
    private headers;
    constructor(endpoint: string, headers?: Record<string, string>);
    request<T = any>(request: GraphQLRequest): Promise<T>;
}
declare const ixoGraphQLClient: GraphQLClient;

export { AuthorizationTab as A, type BlockPresenceUser as B, CoverImage as C, type DropPosition as D, EvaluationTab as E, FlowPermissionsPanel as F, GrantPermissionModal as G, type HttpMethod as H, IxoEditor as I, type KeyValuePair as K, ListBlockSpec as L, OverviewBlock as O, ProposalBlockSpec as P, useCreateCollaborativeIxoEditor as a, type IxoEditorProps as b, type CoverImageProps as c, type AuthorizationTabState as d, type EvaluationTabState as e, EntitySigningSetup as f, CheckboxBlockSpec as g, ApiRequestBlockSpec as h, type CheckboxBlockProps as i, type ListBlockSettings as j, type ListBlockProps as k, type OverviewBlockProps as l, type ProposalBlockProps as m, type ApiRequestBlockProps as n, useBlockPresence as o, useTrackBlockFocus as p, getEntity as q, type Entity as r, type EntityResponse as s, type EntityVariables as t, useCreateIxoEditor as u, GraphQLClient as v, ixoGraphQLClient as w, type GraphQLResponse as x, type GraphQLRequest as y, ExternalDropZone as z };
