import React from "react";
import Textarea, { TextareaControlled } from "../Textarea";
import componentCategories from "../../../docs-utils/componentCategories";
import componentGroups from "../../../docs-utils/componentGroups";
import { TextareaControlledExample } from "./Textarea.example1";

const ParentComponent = props => {
  let [myText, setText] = React.useState("Karups");
  return /*#__PURE__*/React.createElement("div", null, props.component(myText), /*#__PURE__*/React.createElement("button", {
    onClick: () => {
      setText("karups");
    }
  }, " ", "API Versioning", " "));
};

const TextareaState = props => {
  let [myText, setText] = React.useState("test");
  return /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(Textarea, {
    defaultValue: myText,
    onChange: (value, ev) => {
      setText(value);
    }
  }));
};

export default function Textarea__default(props) {
  return /*#__PURE__*/React.createElement("div", {
    style: {
      padding: "0 20px 50px 20px"
    }
  }, /*#__PURE__*/React.createElement("br", null), /*#__PURE__*/React.createElement("div", null, "Usage"), /*#__PURE__*/React.createElement("br", null), /*#__PURE__*/React.createElement(TextareaControlledExample, null), /*#__PURE__*/React.createElement("br", null), /*#__PURE__*/React.createElement("br", null), /*#__PURE__*/React.createElement("div", null, "Variant"), /*#__PURE__*/React.createElement("br", null), /*#__PURE__*/React.createElement(TextareaState, null), /*#__PURE__*/React.createElement("br", null), /*#__PURE__*/React.createElement("br", null));
}

if (false) {
  Textarea__default.docs = {
    componentGroup: componentGroups.Components,
    folderName: componentCategories.UCL
  };
}