shadow
The wje-rate page was auto-generated to keep API documentation coverage in sync with the current component set.
Detailed usage and best-practice guidance will be expanded in the next content phase.
Use wje-rate when users need to enter values, choose options, or trigger form-related actions.
Do not use it as a decorative element without interaction. Prefer presentational components in that case.
Always provide a label (label/aria-label), keep keyboard support, and surface clear validation feedback.
- Keep validation rules and error behavior consistent across the entire form.
- Show loading or disabled states during async operations.
- Split complex forms into smaller sections with immediate feedback.
| Description | Controls how is-hover behaves in the component. |
| Attribute | is-hover |
| Type | any |
| Default | - |
| Description | Gets the value of the rating component. |
| Attribute | value |
| Type | number |
| Default | - |
| Description | The maximum value of the rating component. |
| Attribute | max |
| Type | number |
| Default | - |
| Description | Disables user interaction with the component. |
| Attribute | disabled |
| Type | any |
| Default | - |
| Description | Prevents the value from being edited by the user. |
| Attribute | readonly |
| Type | any |
| Default | - |
| Description | The precision of the rating component. |
| Attribute | precision |
| Type | number |
| Default | - |
| Description | The icons of the rating component. |
| Attribute | icons |
| Type | Array<string> |
| Default | - |
No events available for this component.
| Description | Creates the icons for the rating component. |
| Signature | (i: number) => Element |
| Description | Changes the rate of the rating component. |
| Signature | () => void |
| Description | Returns the icons for the rating component. |
| Signature | (index: number) => Element |
| Description | Returns the value from the x position. |
| Signature | (coordinate: number) => number |
| Description | Rounds a given number to the nearest specified precision. |
| Signature | (numberToRound: number, precision?: number) => number |
| Name | Description |
|---|
native | The native part of the rating component. |
| Name | Description |
|---|
--wje-rate-gap | Defines the spacing (gap) between individual items in the rating component. Accepts any valid CSS length unit (e.g., px, rem, em) to adjust the distance between rating elements. |
--wje-rate-color | Specifies the default color of the rating items. Accepts any valid CSS color value, including named colors, hex values, RGB, or CSS variables. |
--wje-rate-selected-color | Sets the color for selected or highlighted rating items. This property helps visually distinguish selected ratings. Accepts any valid CSS color value. |
No slots available for this component.