@readr-media/react-feedback
Version:
## Installation `yarn install`
45 lines (36 loc) • 1.4 kB
JavaScript
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = CustomTextarea;
var _react = _interopRequireDefault(require("react"));
var _styledComponents = _interopRequireDefault(require("styled-components"));
var _jsxRuntime = require("react/jsx-runtime");
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
// eslint-disable-line
const Wrapper = _styledComponents.default.div.withConfig({
displayName: "texarea__Wrapper",
componentId: "sc-wf6cn8-0"
})(["width:100%;"]);
const Textarea = _styledComponents.default.textarea.withConfig({
displayName: "texarea__Textarea",
componentId: "sc-wf6cn8-1"
})(["width:100%;height:159px;padding:12px 16px;border:1px solid #e0e0e0;border-radius:6px;resize:none;outline:none;box-sizing:border-box;vertical-align:top;overflow:auto;"]);
/**
* @param {Object} props
* @param {string} props.placeholder
* @param {string} props.textAreaValue
* @param {React.ChangeEventHandler<HTMLTextAreaElement>} props.onChange
* @return {JSX.Element}
*/
function CustomTextarea(props) {
return /*#__PURE__*/(0, _jsxRuntime.jsx)(Wrapper, {
className: "input-wrapper",
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(Textarea, {
placeholder: props.placeholder,
name: "feedback-post",
onChange: props.onChange,
value: props.textAreaValue
})
});
}
;