Git Product home page Git Product logo

scratch-tickets's Introduction

scratch-tickets

scratch tickets(刮刮乐)

###配置

  • @param Element // element, 内容节点
  • @param Object // options
    • @width Int // 宽度
    • @height Int // 高度
    • @text Object // 文本配置
      • @size Int // 文本大小
      • @content String // 文本内容
    • @area Object // 刮刮乐主体区域配置
      • @width Int // 主体宽度
      • @height Int // 主体高度
      • @x Int // 主体横向位移
      • @y Int // 主体纵向位移
    • @scratchSize Int // 刮的触点大小
    • @callback Function // 回调

###例子

    scratchTickets(document.getElementById('J_scratchTickets'), {  
      width: 410,  
      height: 210,  
      text: {  
        size: 30,  
        content: '明天再试一次吧,亲'  
      },  
      //url: 'tumblr_mz3jdlGmgl1qbfo7so1_1280.jpg',  
      area: {  
        width: 330,  
        height: 30,  
        x: 80,  
        y: 90  
      },  
      scratchSize: 16,  
      callback: function(){  
        console.log('ok');  
      }  
    });  

scratch-tickets's People

Contributors

lemonlwz avatar

Stargazers

Chai avatar

Watchers

James Cloos avatar  avatar

Forkers

githubyang

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.