import { MessageTextArea } from '.';
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
var meta = {
  title: 'Components/MessageTextArea',
  tags: ['autodocs'],
  component: MessageTextArea,
  args: {
    limitation: 500,
    placeholder: 'please input',
    styles: {
      display: 'flex'
    }
  },
  argTypes: {}
};
export var Doc = function Doc(props) {
  var limitation = props.limitation,
    placeholder = props.placeholder,
    styles = props.styles;
  var handleMsg = function handleMsg(msg) {
    alert('send msg: ' + msg);
  };
  var handleError = function handleError() {
    alert('message is too long');
  };
  return /*#__PURE__*/_jsxs("div", {
    children: [/*#__PURE__*/_jsxs("div", {
      style: {
        width: 200,
        marginBottom: 50
      },
      children: ["Basic:", /*#__PURE__*/_jsx(MessageTextArea, {
        onMsg: function onMsg(msg) {
          alert('send msg: ' + msg);
        },
        onEmoji: function onEmoji(emoji) {
          console.log({
            emoji: emoji
          }, '获取到表情');
        }
      })]
    }), /*#__PURE__*/_jsxs("div", {
      children: ["Please Change Properties:", /*#__PURE__*/_jsx("br", {}), "Change placeholder to 'please input':", /*#__PURE__*/_jsx("div", {
        style: {
          width: 200,
          marginBottom: 50
        },
        children: /*#__PURE__*/_jsx(MessageTextArea, {
          placeholder: placeholder,
          onMsg: handleMsg
        })
      }), "Change limitation to 500:", /*#__PURE__*/_jsx("div", {
        style: {
          width: 200,
          marginBottom: 50
        },
        children: /*#__PURE__*/_jsx(MessageTextArea, {
          limitation: limitation,
          onMsg: handleMsg
        })
      })]
    })]
  });
};
export default meta;