import { jsx as _jsx } from "react/jsx-runtime";
import { TextArea as TextAreaUIKIT } from '@gravity-ui/uikit';
import { getValueByPath } from "../../utils/fields.js";
import Base from "../Base/Base.js";
import BaseInput from "../BaseInput/BaseInput.js";
const TextArea = ({ when, title, content, name, onUpdate, defaultValue }) => {
    const value = getValueByPath(content, name) ?? defaultValue ?? '';
    return (_jsx(Base, { when: when, content: content, name: name, onUpdate: onUpdate, defaultValue: defaultValue, children: _jsx(BaseInput, { title: title, children: _jsx(TextAreaUIKIT, { value: value, name: name, onUpdate: (v) => onUpdate(name, v), minRows: 3 }) }) }));
};
export default TextArea;
//# sourceMappingURL=TextArea.js.map
