/**
 * Public SDK contracts for the node DSL used in block manifests/layouts.
 *
 * This is an SDK-owned copy of the structural type used by the blocks runtime,
 * so SDK consumers don't need to install `@riverbankcms/blocks` for typings.
 *
 * Keep this structurally compatible with:
 * - packages/blocks/src/system/node/schema.ts
 */
export type TransformStep = {
    id: string;
    options?: Record<string, unknown>;
};
export type Binding = {
    from: string;
    fallback?: unknown;
    transforms?: TransformStep[];
    pick?: 'value' | 'collection' | 'context';
    coerce?: 'number' | 'boolean' | 'string';
};
export type RepeatConfig = {
    collection: Binding;
    itemName?: string;
    indexName?: string;
    limit?: number;
    sortBy?: {
        path: string;
        direction?: 'asc' | 'desc';
    };
};
export type ConditionConfig = {
    when: Binding;
    equals?: unknown;
    not?: boolean;
};
export type DataScope = {
    name: string;
    from: Binding;
};
export type NodeDefinition = {
    type: string;
    key?: string;
    props?: Record<string, unknown>;
    children?: NodeDefinition[];
    $bind?: Binding;
    $repeat?: RepeatConfig;
    $when?: ConditionConfig;
    $scopes?: DataScope[];
    [key: string]: unknown;
};
