Skip to content

stulip/mb-sketch-ruler

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

mb-sketch-ruler

A sketch like ruler in javascript

NPM JavaScript Style Guide

Live Demo

Click here

Install

npm install --save mb-sketch-ruler

Usage

import React, { PureComponent } from 'react'

import ReactRuler from 'mb-sketch-ruler'

class Example extends PureComponent {
  render () {
    return (
      <ReactRuler
        thick={thick}
        scale={scale}
        width={582}
        height={482}
        startX={startX}
        startY={startY}
        shadow={shadow}
        horLineArr={h}
        verLineArr={v}
        handleLine={this.handleLine}
        cornerActive={true}
        onCornerClick={this.handleCornerClick}

        // 右键菜单props
        isOpenMenuFeature={true}
        handleShowRuler={this.handleShowRuler}
        isShowReferLine={isShowReferLine}
        handleShowReferLine={this.handleShowReferLine}
      />
    )
  }
}

License

MIT © MockingBot

###© 2016 MockingBot

About

A sketch like ruler in javascript

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 96.2%
  • CSS 2.5%
  • HTML 1.3%