[Bug]: Interests top-level nav label sources string from feature/search instead of feature/interests

Open Beginner friendly
#2,112 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
1/5
Estimated time
Under an hour
Newbie friendliness
90/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Quiet
Tech stack
android, kotlin
Domain
mobile-dev

Research direction

Start in app/src/main/kotlin/com/google/samples/apps/nowinandroid/navigation/TopLevelNavItem.kt and compare the INTERESTS entry with feature/interests/api/src/main/res/values/strings.xml. Use the interests module's dedicated title resource for the top-level navigation labels, and confirm the search module's feature_search_api_interests resource remains specific to SearchScreen.kt.

Written by the indexing model from the issue text.

Description

Is there an existing issue for this?
  • I have searched the existing issues
Is there a StackOverflow question about this issue?
  • I have searched StackOverflow
What happened?

The INTERESTS entry in TopLevelNavItem.kt sources its iconTextId and titleTextId from the search module's string resource rather than from the interests module:

https://github.com/android/nowinandroid/blob/main/app/src/main/kotlin/com/google/samples/apps/nowinandroid/navigation/TopLevelNavItem.kt#L62-L67

val INTERESTS = TopLevelNavItem(
    selectedIcon = NiaIcons.Grid3x3,
    unselectedIcon = NiaIcons.Grid3x3,
    iconTextId = searchR.string.feature_search_api_interests,
    titleTextId = searchR.string.feature_search_api_interests,
)

feature_search_api_interests is the inline "Interests" link label used by the search screen's empty-result body at SearchScreen.kt:248 (the "Try another search or Interests to browse topics" text). Reusing it as the bottom-nav tab title creates a silent cross-feature coupling: a contributor changing the in-search "Interests" link text would unintentionally change the bottom-nav tab label too.

Meanwhile, the interests module already has its own dedicated title resource that is completely unused anywhere in the codebase:

https://github.com/android/nowinandroid/blob/main/feature/interests/api/src/main/res/values/strings.xml#L18

<string name="feature_interests_api_title">Interests</string>

The resource was added on 2025-11-19 in commit 068d8cc ("Split feature modules into api and impl modules") but never wired up.

This also breaks the per-module-ownership pattern used by the other top-level nav items in the same file:

  • FOR_YOUforYouR.string.feature_foryou_api_title
  • BOOKMARKSbookmarksR.string.feature_bookmarks_api_title
  • INTERESTS → ❌ searchR.string.feature_search_api_interests
Relevant logcat output

Code of Conduct
  • I agree to follow this project's Code of Conduct
Dominant language
Kotlin
Stars
21.8k
Forks
4.6k
Avg merge
19h 20m
Merged PRs (30d)
2

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from android/nowinandroid

All issues in android/nowinandroid

Similar issues

More Kotlin issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.