briantrice / react-tangle

A tangle.js-style numeric input for React.js.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

react-tangle

A tangle.js-style numeric input for React.js.

api

required

<TangleText
  value={numeric value}
  onChange={function to be called on change} />

optional

onInput={function}
className={string, default 'react-tangle-input'}
min={numeric, default -Infinity}
max={numeric, default Infinity}
step={numeric, default 1}
pixelDistance={numeric, default null}
format={function, function(x) { return x; }}
disabled={boolean, default false}

Step is a ratio of pixels moved by mouse versus change in the number.

Up/Down arrows increment the value by the step value.

Pixel distance is the number of pixels the mouse has to travel before incrementing by step.

See Also

About

A tangle.js-style numeric input for React.js.


Languages

Language:JavaScript 99.8%Language:HTML 0.1%Language:CSS 0.0%