npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@beisen/text-area

v0.2.25

Published

BeisenCloudComponents-textarea

Downloads

82

Readme

Textarea

项目简介

本项目为textarea文本输入框。对本项目有任何疑问或建议,欢迎联系~(邮箱:[email protected])

项目运行

  1. cnpm install 或 npm install

  2. npm run dev (开发环境打包、项目启动,默认端口 port:8080)

  3. npm run test (测试用例)

  4. npm run build (生产环境打包)

Textarea参数

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.引用组件

import Textarea from "@beisen/text-area"

3.传入参数


  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>
    )
  }