SkillAgentSearch skills...

PreviewCard

Show live previews of video content using Jetpack Compose for Android TV

Install / Use

/learn @hitherejoe/PreviewCard
About this skill

Quality Score

0/100

Supported Platforms

Universal

README

Preview Card

A composable to show live video previews in Android TV content feeds.

@Composable
fun PreviewCard(
    modifier: Modifier = Modifier,
    cardWidth: Dp,
    cardHeight: Dp,
    videoUrl: String,
    hasFocus: Boolean,
    clipStartPosition: Long = 2000000,
    clipEndPosition: Long = 8000000,
    thumbnailFrame: Long = 5000000,
    thumbnailUrl: String? = null
)

How does it work?

Using ExoPlayer and the provided clipStartPosition / clipEndPosition, when the item hasFocus a preview clip will be shown in the card. When not in focus, the provided thumbnail details will be used to display a placeholder image.

If the thumbnailUrl is provided, this will simply be loaded. Otherwise, a thumbnail will be loaded from the provided thumbnailFrame.

Related Skills

View on GitHub
GitHub Stars59
CategoryContent
Updated2mo ago
Forks4

Languages

Kotlin

Security Score

80/100

Audited on Jan 4, 2026

No findings