2.2.1 • Published 4 years ago

react-score-indicator v2.2.1

Weekly downloads
487
License
MIT
Repository
github
Last release
4 years ago

Install

npm install --save react-score-indicator

Usage

import React, { Component } from 'react'

import ReactStoreIndicator from 'react-score-indicator'

class Example extends Component {
  render () {
    return (
      <ReactStoreIndicator
        value={30}
        maxValue={100}
      />
    )
  }
}

Props

NameTypeDefaultDescriptionRequired
valuenumberValue of scoreyes
maxValuenumberValue of max total scoreyes
widthnumber200Width of componentno
stepColorsarrayview belowArray with n hex colors corresponding to steps in the chartno
lineWidthnumber5Width of lineno
lineGapnumber5Space between the linesno
fadedOpacitynumber40Opacity percentage of the "disabled" stepsno
styleobject{}Style to customize the component wrapperno
textStyleobject{}Style to customize the score value text inside the chartno

DEFAULT COLOR PALETTE

[
  '#d12000',
  '#ed8d00',
  '#f1bc00',
  '#84c42b',
  '#53b83a',
  '#3da940',
  '#3da940',
  '#3da940',
]

License

MIT © tomma5o

2.2.1

4 years ago

2.1.1

5 years ago

2.1.0

5 years ago

2.0.1

5 years ago

2.0.0

5 years ago

1.0.1

5 years ago

1.0.0

5 years ago