/**
 * This file is part of the NocoBase (R) project.
 * Copyright (c) 2020-2024 NocoBase Co., Ltd.
 * Authors: NocoBase Team.
 *
 * This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
 * For more information, please refer to: https://www.nocobase.com/agreement.
 */
import type { MetaTreeNode } from '@nocobase/flow-engine';
export type UseWorkflowVariableOptions = {
    types?: any[];
    fieldNames?: {
        label?: string;
        value?: string;
        children?: string;
    };
    appends?: string[] | null;
    depth?: number;
    /**
     * Include the `$scopes` root. Scope providers (loop / parallel) building
     * their own local variables must disable this when they call back into the
     * workflow aggregator, otherwise the scope chain recursively nests itself.
     */
    includeScopes?: boolean;
};
/**
 * Build the workflow variable MetaTree for the current node's config form.
 * Aggregates every scope in v1's display order, dropping the ones that
 * contribute nothing.
 *
 * The result is **referentially stable** across re-renders for the same inputs
 * (memoized on the current node + upstream/scope node keys + workflow id). This
 * is load-bearing for lazy relation expansion: `TypedVariableInput.loadData`
 * resolves a node's children and mutates them onto the meta node in place, then
 * forces a re-render — if this hook returned a brand-new tree each render, that
 * mutated (resolved) child list would be discarded and the cascader column would
 * spin forever. Memoizing keeps the same tree objects alive so the resolved
 * children survive the re-render.
 */
export declare function useWorkflowVariableOptions(options?: UseWorkflowVariableOptions): MetaTreeNode[];
