Guide · Agent skill
How to use the Leanback to Compose TV Migration agent skill
Updated · written with AI from the project's own documentation and checked against our catalogue data
The Leanback to Compose TV Migration skill is a set of instructions and architectural patterns that tells an AI agent how to convert Android TV apps built with the Leanback toolkit, Android Views or Support Fragments into Jetpack Compose for TV. It is written for Android TV developers who want the agent to produce Compose code that follows TV conventions. After this guide you will know how to install the skill, how to ask for migration work in plain language, and what your project needs before you start.
Quick start
- 1Download the ZIP. Get the leanback-to-compose-tv-migration skill ZIP from the page where you found this guide.
- 2Unzip into a skills folder. Extract it into ~/.claude/skills/ for personal use, or into your project's .claude/skills/ folder for one project.
- 3Or upload it in the Claude apps. In the Claude apps, open Settings, go to Capabilities, then Skills, and upload the skill.
- 4Check your project. Confirm you have Android Studio and a Gradle-based Android TV project with the TV dependencies the skill lists.
- 5Ask for a migration in plain language. Name the Leanback or Views screen you want converted, such as BrowseSupportFragment or VideoSupportFragment.
- 6Build and test focus. Build the generated code and move through every screen with a remote or emulator to confirm the D-pad never gets stuck.
What the skill makes the agent do
When the skill is installed, the agent follows its rules when it writes or restructures Android TV UI code. The rules cover 10-foot design (the layout viewed from about 3 meters away), TV Material 3 components from androidx.tv, D-pad remote focus handling so users can move around the screen without getting stuck, focus zoom on cards, Media3 video playback, and file naming and import conventions.
The skill is instructional. It tells the agent how to write and structure the code. It does not run any tools itself.
- Replaces screens such as BrowseSupportFragment, settings, login and video playback with Compose equivalents
- Uses CompactCard, ClassicCard or WideCardContainer with a focus zoom scale for interactive cards
- Names screen files after the screen, for example BrowseScreen.kt, and avoids generic prefixes like Main
- Forbids AndroidView wrappers, so migrated screens use Compose components or Media3 PlayerSurface
How to install the leanback-to-compose-tv-migration skill
Download the skill ZIP from the page where you found this guide. Unzip it so the skill folder ends up in one of two places. For a personal setup that applies across your projects, use ~/.claude/skills/. For a single project, place it in that project's .claude/skills/ folder.
If you use the Claude apps instead, open Settings, go to Capabilities, then Skills, and upload the skill there.
- Personal install: unzip into ~/.claude/skills/
- Project install: unzip into the project's .claude/skills/ folder
- Claude apps: Settings → Capabilities → Skills, then upload
How to trigger the skill with natural requests
You do not need a special command. Describe the migration task in plain language and name the Leanback class or screen involved. The skill's description lists the triggers it responds to, including browse, settings, authentication, login and video playback screens, and classes such as BrowseSupportFragment, LeanbackSettingsFragment, VideoSupportFragment and GuidedStepSupportFragment.
Specific requests work better than general ones because they tell the agent which screen to convert and which patterns apply.
- Migrate my BrowseSupportFragment home screen to Compose for TV with focus memory per row.
- Convert this LeanbackSettingsFragment and its preferences into a Compose settings screen.
- Replace my VideoSupportFragment playback screen with Media3 PlayerSurface.
- Rewrite this login screen in androidx.tv Material 3 and set initial focus on the first button.
Initial focus and D-pad navigation
Compose for TV components do not receive initial focus automatically. The skill's rules require the agent to give the primary interactive element on each screen a FocusRequester and request focus when the screen opens. The pattern below comes from the skill's guidance.
For rows of cards, the rules require Modifier.focusRestorer on each LazyRow so the row remembers the last card the user focused. They also say not to set up/down overrides that target individual items inside lazy lists.
val focusRequester = remember { FocusRequester() }
val focusManager = LocalFocusManager.current
LaunchedEffect(Unit) {
focusRequester.requestFocus()
}What the project needs and safety notes
Before you ask for a migration, make sure your project is a Gradle-based Android TV project that you can open in Android Studio. The skill expects these dependencies, depending on the screens you are converting.
The skill runs no scripts and makes no network calls. It only provides instructions for the agent to follow. You should still review the generated code, build it, and test focus movement with a remote or the emulator before you ship.
- Android Studio and a Gradle-based Android TV project
- androidx.tv:tv-material for TV Material 3 components
- io.coil-kt:coil-compose if you use AsyncImage
- androidx.media3:media3-ui-compose for playback screens
- Runs scripts: no. Uses network: no.
Tips for getting good results
Give the agent the existing screen's source file along with your request, so it can map each Leanback presenter or adapter to a Compose equivalent. Ask for one screen at a time, then build and test before moving to the next. The skill's references cover navigation, the Compose catalog browser and Compose for TV setup, so mention the screen type when you ask.
- Migrate one screen per request and test focus before continuing
- Name the exact class you are replacing
- Check generated imports, because the skill requires explicit imports rather than wildcards
What people use it for
- Moving a home screen built on BrowseSupportFragment to a Compose carousel layout with row focus memory
- Converting a LeanbackSettingsFragment or PreferenceFragment settings screen to Compose
- Replacing a VideoSupportFragment playback screen with Media3 PlayerSurface
- Rebuilding a login or authentication screen with TV Material 3 components and initial focus
Frequently asked questions
How do I install the leanback to compose TV migration skill?
Download the skill ZIP and unzip it into ~/.claude/skills/ for personal use, or into a project's .claude/skills/ folder. In the Claude apps, you can instead upload it under Settings → Capabilities → Skills.
What do I need to use the Leanback to Compose migration skill?
You need Android Studio and a Gradle-based Android TV project. Depending on the screens, you also need androidx.tv:tv-material, io.coil-kt:coil-compose if you use AsyncImage, and androidx.media3:media3-ui-compose for playback screens.
Is the Leanback to Compose TV Migration skill free?
The listing states the licence is Apache-2.0. The skill's SKILL.md points to a LICENSE.txt file for the complete terms, so read that file for the full conditions.
Does the skill run code or access the internet?
No. The listing says it runs no scripts and uses no network. It contains instructions and reference files that the agent reads, and you still need to build and test the generated code yourself.
Can I use this skill for a phone or tablet app?
No. The rules target TV dependencies and D-pad navigation, so they are the wrong platform for phone or tablet apps.
Why does the agent refuse to keep AndroidView wrappers in my migrated screen?
The skill forbids legacy AndroidView wrappers, so all migrated screens use Compose components or Media3 Compose surfaces such as PlayerSurface. If your project must keep Leanback or Views for compatibility reasons, do not apply this skill blindly, because it could break existing code.
New agent skills, repos and AI tools — every week
The best new skills and open-source projects, the fastest-growing repos, and one free prompt. Five minutes to read. Unsubscribe anytime.
Our verdict
Use this skill if you are an Android TV developer moving a Leanback app to Jetpack Compose for TV, especially BrowseSupportFragment, settings, login or playback screens. Pick something else if you build phone or tablet apps, or if your project must keep Leanback or Views, since the skill mandates Compose for TV and forbids AndroidView wrappers.
Download the skill