rubensousa / DpadRecyclerView

A RecyclerView built for Android TV with Compose in mind and as a replacement for Leanback's BaseGridView.
https://rubensousa.github.io/DpadRecyclerView/
Apache License 2.0
136 stars 17 forks source link

Nested vertical lists #175

Closed fankloano closed 11 months ago

fankloano commented 11 months ago

Hello, first of all, thanks for giving us the opportunity to use this library. As a beginner in developing an app for Android TV (it's just a hobby) and facing difficulties with leanback, I liked its setup. Now, I want to implement a nested recyclerview with both vertical orientations. Explanation: In my layout, I have two dpadrecyclerviews, country-rv, and todo-rv (both vertical). The country-rv contains another vertical dpadrecyclerview (category-rv) in its item, which should display the categories (dynamic size; the user can select the categories they want to be shown for each country) related to the clicked country. If a category is then clicked, the todo-rv shows different things based on the clicked category of the related country. Using the same approach as with a normal RecyclerView, dpadrecyclerview shows me only one category item at a time, which is probably its normal behavior, but I want that all categories are shown. Is there a workaround to implement this, or is it simply not possible with dpadrecyclerview?

rubensousa commented 11 months ago

Hey. Nested RecyclerViews in the same orientation is generally an anti-pattern. You generally want to combine nested RecyclerViews if they have opposite scroll directions, otherwise it's considered a bad UX since the user won't understand how the navigation works. Please reconsider your design choices and prefer UX patterns that users are already used to. There's not much I can do here, so I'm closing this