1.0.1 • Published 8 years ago

react-thermometer-component v1.0.1

Weekly downloads
79
License
ISC
Repository
-
Last release
8 years ago

A React Thermometer Component

Install

$ npm install --save react-thermometer-component

View demo

https://zamarrowski.github.io/react-thermometer-component/

Usage

import React from 'react'
import { render } from 'react-dom'
import Thermometer from 'react-thermometer-component'

render(
  <Thermometer
    theme="light"
    value="18"
    max="100"
    steps="3"
    format="°C"
    size="large"
    height="300"
  />
, document.getElementById('container'))

Browserify

browserify is supported, but you have to install browserify-css@^0.12.0 manually.

API:

ParamTypeDescriptionExampleDefault
themeStringLight or Darktheme="light"light
valueNumberTemperature valuevalue={27}0
maxNumberMaximum value of thermometermax={100}100
stepsNumberThermometer dividerssteps={3}0
formatStringDegrees formatformat="°C"''
sizeStringThermometer size. Can be small, normal or largesize="large"normal
heightNumberThermometer heightheight={300}200

Contributors

I have made improvements to this component. The original component is http://www.interaminense.com/react-ui-thermomete.