Constructor

BrowseItem

new BrowseItem(entity, title, subtitle, image)

Parameter

entity

string

Content entity information.

title

Optional

string

Main text of the browse item.

subtitle

Optional

string

Secondary text of the element. Both title and subtitle can be provided, but at least one of them is required.

image

Optional

cast.framework.messages.Image

Image displayed for browse item. It's highly recommended to have image aspect ratio matching BrowseContent#targetAspectRatio value. If image is too narrow/tall, it will be pillarboxed. If image is too wide/short, it will be letterboxed.

Value must not be null.

Properties

duration

Content duration in seconds. If provided, duration indicator will be displayed over media browse item image. For example, if duration = 150, label will be 2:30. If duration is 0, no label will be displayed.

entity

Content entity information.

image

Image displayed for browse item. It's highly recommended to have image aspect ratio matching BrowseContent#targetAspectRatio value. If image is too narrow/tall, it will be pillarboxed. If image is too wide/short, it will be letterboxed.

imageType

Type of placeholder that will be used if image is not available for the browse item.

mediaBadge

Additional badge to be displayed over the browse item image.

subtitle

Secondary text of the element. Both title and subtitle can be provided, but at least one of them is required.

title

Main text of the browse item.