• What is KendoReact
  • Getting Started
  • Server Components
  • Components
    • Animation
    • Barcodes
    • Buttons
    • Chartsupdated
    • Common Utilities
    • Conversational UIupdated
    • Data Gridupdated
    • Data Query
    • Data Tools
    • Date Inputs
    • Date Math
    • Dialogs
    • Drawing
    • Dropdownsupdated
    • Editor
    • Excel Export
    • File Saver
    • Formupdated
    • Ganttupdated
    • Gauges
    • Indicators
    • Inputsupdated
    • Labels
    • Layoutupdated
    • ListBox
    • ListView
    • Map
    • Notification
    • OrgChartnew
    • PDF Processing
    • PDFViewer
    • PivotGrid
    • Popup
    • Progress Bars
    • Ripple
    • Scheduler
    • ScrollView
    • Sortable
    • Spreadsheetupdated
    • TaskBoard
    • Tooltips
    • TreeList
    • TreeViewupdated
    • Upload
  • Sample Applications
  • Styling & Themes
  • Common Features
  • Project Setup
  • Knowledge Base
  • Changelog
  • Updates
  • Troubleshooting

RatingProps

Represents the properties of [Rating](% slug api_inputs_rating %) component.

NameTypeDefaultDescription

ariaDescribedBy?

string

Identifies the element(s) which will describe the component, similar to HTML aria-describedby attribute. For example these elements could contain error or hint message.

ariaLabelledBy?

string

Identifies the element(s) which will label the component.

children?

React.ReactNode

Determines the children nodes.

className?

string

Sets additional classes to the Rating.

defaultValue?

number

Sets the default value of the Rating, used in uncontrolled mode. See example

dir?

string

Determines the Rating direction ltr - by default, or rtl.

disabled?

boolean

Sets the disabled mode of the Rating, if it is set to true. See example

half?

boolean

Determines if value represents half icon -> true, or not -> false. See example

icon?

string

Sets custom Rating icon, by default - star. See example

id?

string

Sets the id property of the top div element of the Rating.

item?

React.ComponentType<RatingItemProps>

Represents the rendered Rating item.

label?

string

Determines if the Rating has a label and is it a custom one.

max?

number

Sets the max possible icon value or star value in the main use-case.

min?

number

Sets the min possible icon value or star value in the main use-case.

name?

string

Specifies the name property of the input DOM element.

This property is part of the FormComponentProps interface.

onBlur?

(event: RatingItemFocusEvent) => void

Triggered after onBlur event. Gets outside access to the target element and the event type.

onChange?

(event: RatingChangeEvent) => void

Triggered after value change. Gets outside access to the target element, the new value and the event type.

onClick?

(event: RatingItemMouseEvent) => void

Triggered after onClick event. Gets outside access to the target element, the new value and the event type.

onFocus?

(event: RatingItemFocusEvent) => void

Triggered after onFocus event. Gets outside access to the target element and the event type.

onKeyDown?

(event: RatingKeyboardEvent) => void

Triggered after onKeyDown event. Gets outside access to the target element, the new value and the event type.

precision?

"item" | "half"

Determines the precision of the Rating. By default set to item. See example

readonly?

boolean

Sets the readonly mode of the Rating, if it is set to true. See example

required?

boolean

Specifies if null is a valid value for the component.

This property is part of the FormComponentProps interface.

selection?

"single" | "continues"

Determines the selection mode. By default set to continues. See example

step?

number

Sets the step value between the min and max value.

style?

React.CSSProperties

Sets additional CSS styles to the Rating.

svgIcon?

SVGIcon

Sets custom Rating SVG icon.

svgIconOutline?

SVGIcon

Sets custom Rating SVG icon.

tabIndex?

number

Sets the tabIndex attribute.

valid?

boolean

Overrides the validity state of the component. If valid is set, the required property will be ignored.

This property is part of the FormComponentProps interface.

validationMessage?

string

Controls the form error message of the component. If set to an empty string, no error will be thrown.

This property is part of the FormComponentProps interface.

validityStyles?

boolean

If set to false, no visual representation of the invalid state of the component will be applied.

This property is part of the FormComponentProps interface.

value?

number

Sets the current value of the Rating, used in controlled mode. See example