1.1.2 • Published 5 years ago

react-rating-scale v1.1.2

Weekly downloads
3
License
ISC
Repository
github
Last release
5 years ago

Install

npm install --save react-rating-scale

Demo

https://stas-raranetskyi.github.io/react-rating-scale/

Usage

import React from 'react';
import Rating  from 'react-rating-scale';

class App extends React.Component {
    render() {
        return <Rating />;
    }
}

Settings

OptionTypeDefaultDescription
lengthnumber10The max number of items to choose from or to display.
ratingnumber0The user's rating. Number of items to highlight. Ranging from 0 to max number of items.
readonlyboolfalseDetermines whether user can select a new rating or whether the items are just for display.
onSelectfunction() => {}Callback that will be passed the new rating a user selects.
beforeSelectfunction() => trueCallback that will before calling onSelect. Must return true for the function onSelect to execute.
iconstring''Path to your icon.
widthnumber20Icon width.
heightnumber19Icon height.
classNameRatingWrapstring''Class name for rating wrap.
classNameRatingItemstring''Class name for rating icon.
classNameRatingItemActivestring''Class name for rating icon active.

Author

@Stas Raranetskyi
Stas Raranetskyi
1.1.2

5 years ago

1.1.1

5 years ago

1.1.0

5 years ago

1.0.6

5 years ago

1.0.5

5 years ago

1.0.4

5 years ago

1.0.3

5 years ago

1.0.2

5 years ago

1.0.1

5 years ago

1.0.0

5 years ago