Implementation of the 'rating' markup element. A div HTML element is created and the class lto-rating is added to allow CSS modifications.

see

  IRenderable

see

  IStackeable

### Hierarchy

- Rating

### Implements

- IRenderable
- IStackeable

## Index

### Constructors

- constructor

### Properties

- ratingButtons
- ratingContainer
- selectedRatingButtonType
- spec
- TYPE

### Methods

- getScoreOfClickedButton
- ratingButtonOnClick
- render
- renderRatingButton

## Constructors

### constructor

- new Rating(message: ISpecification): Rating

- - Defined in lib/renderable/rating/index.ts:23

  #### Parameters

  - ##### message: ISpecification

  #### Returns Rating

## Properties

### Private ratingButtons

ratingButtons: Map<RatingButtonType, RatingButton>

- Defined in lib/renderable/rating/index.ts:22

### Private ratingContainer

ratingContainer: INode

- Defined in lib/renderable/rating/index.ts:21

### Private selectedRatingButtonType

selectedRatingButtonType: RatingButtonType

- Defined in lib/renderable/rating/index.ts:23

### Private spec

spec: ISpecification

- Defined in lib/renderable/rating/index.ts:20

### Static TYPE

TYPE: "rating" = "rating"

- Defined in lib/renderable/rating/index.ts:19

## Methods

### Private getScoreOfClickedButton

- getScoreOfClickedButton(): string

- - Defined in lib/renderable/rating/index.ts:109

  #### Returns string

### Private ratingButtonOnClick

- ratingButtonOnClick(buttonType: RatingButtonType, commentForm: INode): void

- - Defined in lib/renderable/rating/index.ts:99

  #### Parameters

  - ##### buttonType: RatingButtonType

  - ##### commentForm: INode

  #### Returns void

### render

- render(renderer: IRenderer, isNested: boolean): HTMLElement

- Implementation of IStackeable.render

  - Defined in lib/renderable/rating/index.ts:35

  Renders an element

  #### Parameters

  - ##### renderer: IRenderer

  - ##### isNested: boolean

  #### Returns HTMLElement

  the element which was rendered

### Private renderRatingButton

- renderRatingButton(): void

- - Defined in lib/renderable/rating/index.ts:45

  #### Returns void

Generated using TypeDoc