UNPKG

@wufengteam/inputs

Version:

平台提供的右侧属性编辑器,需要在主工程中注册

27 lines 876 B
import React from 'react'; import { Form, Input, ConfigProvider } from 'antd'; import 'antd/lib/input/style/index'; var AndTextArea = Input.TextArea; var TextArea = function TextArea(_ref) { var name = _ref.name, label = _ref.label, rules = _ref.rules, _ref$placeholder = _ref.placeholder, placeholder = _ref$placeholder === void 0 ? '' : _ref$placeholder, _ref$rows = _ref.rows, rows = _ref$rows === void 0 ? 3 : _ref$rows, lableStyle = _ref.lableStyle; return /*#__PURE__*/React.createElement(ConfigProvider, { prefixCls: "ant" }, /*#__PURE__*/React.createElement(Form.Item, { name: name, label: /*#__PURE__*/React.createElement("span", { style: lableStyle }, label), rules: rules }, /*#__PURE__*/React.createElement(AndTextArea, { placeholder: placeholder, rows: rows }))); }; export default TextArea;