Coder Social home page Coder Social logo

zq.js's Introduction

将工作中比较常用的组件整合成插件。

  1. zq.bindKeyEvent() 监听input金额输入,只能输入两位小数
  $(document).ready(function(){
       zq.bindKeyEvent($(".aa"),"正则");
    });

  1. zq.tipsbox() 鼠标移上去显示提示
    zq.tipsbox({
         obj: $(".st_tipsbox"),   //选择器
         position: 'right',       //显示位置   上下左右
         width: 'more-line',      //当要换行时  他的宽度。不设置宽度不换行。
         align: 'center'          //字体对齐方式
      })

  1. zq.addreduce() 数字加减插件 此插件默认限制了只能输入数字 ,可做其他正则限制。
zq.addreduce({
    obj: $(".st_addreduce"),    //调用该方法的选择器
    maxnum: 99999,              //可输入最大数
    minnum: 0,                 //可输入最小数
    reg:/^[0-9]\d*/,            //input的框的限制输入格式
})

  1. zq.countdown() 倒计时插件
zq.countdown({
  time:120,                   //倒计时时间
  tip:获取手机验证码           //结束提示语     
})

  1. 图片上传插件 支持点击放大
 zq.imgUpload({                //图片上传插件   支持点击放大
	obj:$(".imgUpload")
})

zq.js's People

Contributors

snail017 avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.