# @beisen-platform/text-area

> 无用于表单中的大段文本信息的输入，可设置是否显示最大、最少字数，当前字数，是否可拖拽

Latest version **1.0.9-rc.5** (published 2019-07-04) · ISC license · 0 weekly downloads

## Install

```sh
npm install @beisen-platform/text-area
pnpm add @beisen-platform/text-area
yarn add @beisen-platform/text-area
bun add @beisen-platform/text-area
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.9-rc.5 |
| Published | 2019-07-04 |
| First published | 2018-11-29 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 5 |
| Unpacked size | 379.3 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | beisen |
| Maintainers | beisencorp |
| Keywords | beisen, react-component, es6 |

## Links

- npm: https://www.npmjs.com/package/@beisen-platform/text-area
- npm.io page: https://npm.io/package/@beisen-platform/text-area

## Dependencies (5)

- [@beisen-platform/tool-tip](https://npm.io/package/@beisen-platform/tool-tip.md)
- [@beisen-platform/common-func](https://npm.io/package/@beisen-platform/common-func.md)
- [@beisen-platform/react-icons](https://npm.io/package/@beisen-platform/react-icons.md)
- [@beisen/es6-promise-debounce](https://npm.io/package/@beisen/es6-promise-debounce.md)
- [@beisen-platform/common-label](https://npm.io/package/@beisen-platform/common-label.md)

## Recent versions

- 1.0.9-rc.5 (latest) — 2019-07-04
- 1.0.9-rc.1 — 2019-04-29
- 1.0.9 — 2019-04-16
- 1.0.8 — 2019-03-15
- 1.0.7 — 2019-03-15
- 1.0.6 — 2019-03-14
- 1.0.4 — 2019-03-14
- 1.0.5 — 2019-03-14
- 1.0.3 — 2019-03-07
- 1.0.2 — 2019-02-15
- 1.0.1 — 2019-02-14
- 1.0.0 — 2019-01-06
- 0.2.19 — 2018-11-29

## README

# Textarea

## 项目简介
本项目为textarea文本输入框。对本项目有任何疑问或建议，欢迎联系~(邮箱：mengshuai@beisen.com)

## 项目运行

1. cnpm install 或 npm install

2. npm run dev （开发环境打包、项目启动，默认端口 port:8080）

3. npm run test （测试用例）

4. npm run build （生产环境打包）

## Textarea参数


```javascript
const props = {
  hidden: false,
  disabled: false,
  readOnly: false,
  maxlength: 140,          //文本域允许字数最大值
  defaultHeight: '130px', //默认的输入框高度，内置默认为91px
  labeltext: '默认title',
  required: true,
  textValue: '',          //初始值
  placeHolder:'',
  showStatus: '',         //显示状态 search or ''
  showText: '请填写正确',
  helpMsg: 'dqwdq',
  sideTip: false,         //toolTip是否左右显示
  hiddenTip: false,       //toolTip是否显示
  errorStatus: false,     //是否报错
  errorMsg: '出错了~~~！', //报错信息
  lablePos: true,         //label位置，true时在左边，false在上边
  lableTxt: false,        //label中文字对齐方式，true左对齐，false右对齐
  onClick: function (event) {
    console.log(event.target.value)
  },
  onFocus: function (event) {
    console.log(event.target.value)
  },
  onChange: function (event) {
    console.log(event.target.value)
  },
  onBlur: function (event) {
    console.log(event.target.value)
  },
  iconClick: function () {
    console.log(0)
  } //没有iconClick这个字段即不支持此功能。 有即是支持这个特性
}
```
## 调用方法
1.安装npm组件包

```
npm install @beisen/text-area --save-dev
```

2.引用组件

  ```javascript
import Textarea from "@beisen/text-area"
  ```
3.传入参数


```javascript

  state = {
    hidden: false
    ,disabled: false
    ,readOnly: false
    ,maxlength: 10 //文本域允许字数最大值
    ,labeltext: "默认title"
    ,required: true
    ,textValue: 'DCSDCDSCSDDCSDCDSCSD'
    ,"showStatus":""  //显示状态 "search" or ""
    ,"showText":"请填写正确"
    ,"helpMsg":"dqwdq"
    ,"sideTip":false //toolTip是否左右显示
    ,"hiddenTip":false //toolTip是否显示
    ,"errorStatus": false//是否报错
    ,"errorMsg":"出错了~~~！" //报错信息
    ,"lablePos":  true //label位置，true时在左边，false在上边
    ,"lableTxt": false//label中文字对齐方式，true左对齐，false右对齐
    ,onClick:function(event){console.log(event.target.value)}
    ,onFocus:function(event){console.log(event.target.value)}
    ,onChange:function(event){console.log(event.target.value)}
    ,onBlur:function(event){console.log(event.target.value)}
  }

  render () {
    return (
      <div>
          <Textarea {...this.state} />
      </div>
    )
  }


```

---
_Source: https://npm.io/package/@beisen-platform/text-area · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
