"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.FormTreeAsyncAutocomplete = void 0;
const jsx_runtime_1 = require("react/jsx-runtime");
const TreeAsyncAutocomplete_1 = require("../../components/TreeAsyncAutocomplete");
const useFormFieldProps_1 = require("../useFormFieldProps");
/**
 * FormTreeAsyncAutocomplete для формы
 */
const FormTreeAsyncAutocomplete = (props) => {
    const { error, ...fieldProps } = (0, useFormFieldProps_1.useFormFieldProps)({
        ...props,
        defaultValue: props.defaultValue || null,
    });
    return (0, jsx_runtime_1.jsx)(TreeAsyncAutocomplete_1.TreeAsyncAutocomplete, { isError: error, ...fieldProps });
};
exports.FormTreeAsyncAutocomplete = FormTreeAsyncAutocomplete;
