Skip to content

feat(ui): set up Navigation Compose with Welcome → ChannelList placeholder (#8)#29

Merged
ilmoniemi merged 3 commits into
mainfrom
feature/8
May 11, 2026
Merged

feat(ui): set up Navigation Compose with Welcome → ChannelList placeholder (#8)#29
ilmoniemi merged 3 commits into
mainfrom
feature/8

Conversation

@ilmoniemi
Copy link
Copy Markdown
Contributor

What

Replaces the AGP-template Greeting("Android") in MainActivity with a NavHost rooted at WelcomeScreen and adds a channel_list placeholder destination.

  • gradle/libs.versions.toml — adds navigationCompose = "2.9.5" and the androidx-navigation-compose library alias (Navigation Compose is not in the Compose BOM).
  • app/build.gradle.kts — adds implementation(libs.androidx.navigation.compose) (alphabetically placed; no inline version literal).
  • MainActivity.kt — deletes the template Greeting and GreetingPreview, introduces a private PyryNavHost that owns rememberNavController(), and a private object Routes with Welcome / ChannelList string constants. onPaired navigates to channel_list; onSetup is a no-op with a TODO(#14) comment.

Issue

Closes #8

Testing

  • ./gradlew assembleDebug — passes (the only AC-binding gate).
  • ./gradlew test — passes.
  • ./gradlew lint — passes (clean).
  • ./gradlew connectedAndroidTest — not run, no emulator/device attached in this environment.

No navigation tests added per the spec's "Testing strategy" section (instrumentation tests deferred; spec explicitly says not to add androidx-navigation-testing for this ticket).

Architecture compliance

Follows docs/specs/architecture/8-navigation-compose-welcome-channellist-placeholder.md exactly:

  • PyryNavHost extracted as a private Composable inside MainActivity.kt, keeping setContent at a single level of abstraction (theme → scaffold → nav host).
  • Route strings live in a single private object Routes; no sealed class Route / type-safe navigation refactor.
  • onPaired uses plain navController.navigate(Routes.ChannelList) — no popUpTo / launchSingleTop. Back from channel_list returns to welcome, as expected for this scaffolding ticket.
  • channel_list route renders bare Text("Channel list placeholder") — no Surface, no Scaffold, no padding, as specified.
  • enableEdgeToEdge() and the outer Scaffold(modifier = Modifier.fillMaxSize()) preserved; WelcomeScreen is untouched.

🤖 Generated with Claude Code

ilmoniemi and others added 2 commits May 11, 2026 12:20
…older

Replace AGP-template Greeting in MainActivity with a NavHost rooted at
WelcomeScreen, with a channel_list placeholder destination. onPaired
navigates to channel_list; onSetup is an inert TODO(#14) for the later
external-browser intent.

Closes #8

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
@ilmoniemi
Copy link
Copy Markdown
Contributor Author

Code Review: #8

Decision: PASS

Findings

None.

Summary

Implementation matches the architect's spec exactly. All six acceptance criteria are satisfied:

  • navigationCompose = "2.9.5" added to [versions], androidx-navigation-compose alias added to [libraries], consumed via libs.androidx.navigation.compose in app/build.gradle.kts — no inline version literal (AC1).
  • Greeting and GreetingPreview deleted; androidx.compose.ui.tooling.preview.Preview import removed cleanly (AC2).
  • NavHost with welcome (start) and channel_list destinations, extracted into a private PyryNavHost Composable that owns rememberNavController() — stateless host pattern per the ticket's Technical Notes (AC3).
  • WelcomeScreen wired with onPaired = { navController.navigate(Routes.ChannelList) } and an inert onSetup no-op carrying the TODO(#14) comment (AC4).
  • channel_list route body is the bare Text("Channel list placeholder") — no extra chrome, matching the spec's instruction that the outer Scaffold provides padding (AC5).
  • ./gradlew assembleDebug passes; ./gradlew lint and ./gradlew test are also clean (AC6).

Route strings centralised in a private object Routes, PyryNavHost is private, no back-stack tuning, no deep links, no test deps added — all in line with the spec's "do not implement" list. Trailing newline restored on MainActivity.kt (the old file was missing one).

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
@ilmoniemi ilmoniemi merged commit 0aef586 into main May 11, 2026
@ilmoniemi ilmoniemi deleted the feature/8 branch May 11, 2026 09:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(ui): set up Navigation Compose with Welcome → ChannelList placeholder

1 participant