-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Display feed tag selector on top of subscriptions screen #5374
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- There is now a "#root" tag in the navigation drawer
- The "more" button is too prominent. It makes the screen feel like some kind of "editor", not like a normal main screen
- Does not work together with multi-select
- Why are there two lists of tags? I would just make it a single list where tags can be selected
- The "All" chip has a nice checkbox when selected. The others have colorful, overlayed icons. Please make all look like the "All" one.
- After playing around with it, I think it is okay to not filter the tags when changing the feed filter. That reduces the complexity and could even be easier to understand for users
- When changing the sort order while all subscriptions are displayed, it sometimes starts filtering by tag
- When removing the tag of a subscription, RecyclerView displays a nice animation. When changing the filter on top, it doesn't. Why?
- When there are no tags stored, there should be no tag bar
Screenshot:
app/src/main/java/de/danoeh/antennapod/adapter/FeedTagAdapter.java
Outdated
Show resolved
Hide resolved
app/src/main/java/de/danoeh/antennapod/adapter/FeedTagAdapter.java
Outdated
Show resolved
Hide resolved
app/src/main/java/de/danoeh/antennapod/adapter/SubscriptionsRecyclerAdapter.java
Show resolved
Hide resolved
Chip rootChip = null; | ||
folderChipGroup.removeAllViews(); | ||
for (NavDrawerData.FolderDrawerItem folderItem : feedFolders) { | ||
Chip folderChip = new Chip(getActivity()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don't you already have an adapter for this? Also, this is too much code in the RxJava handler. Please extract to a method.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No this is not a RecyclerView. It is ChipGroup, used for the second tag list. I don't think RecyclerView would work, since it doesn't provide wrapping (LinearLayout) or varying sizes for items (GridLayout)
app/src/main/java/de/danoeh/antennapod/fragment/SubscriptionFragment.java
Show resolved
Hide resolved
} | ||
|
||
public static void addTagFilterId(long tagFilterId) { | ||
Set<String> tagFilterIds = prefs.getStringSet(PREF_TAG_FILTER, new HashSet<>()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This stores which tags are selected on the subscriptions screen, right? So this would only be needed on the subscriptions screen. The UserPreferences class is already monstrous, so please move the code directly to the subscriptions screen.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
But this allows the the selected tags to be persisted. If removed, the user would have to re select tags. I think it is a useful feature to have.
For instance, imagine a scenario where you have many podcasts but a few ones that you actively care about. It would be annoying to have to reselect that tag every time. Instead, if persisted you could just open the app and have the tags with the primary podcasts already shown.
Besides, it's already implemented, and a user(s) will probably ask for it in the feature. Just seems like one those little 'it would be nice' request that users are bound to bring up.
If the User preferences is too large, I wouldn't mind helping to refactor it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My idea was not to not store it. It was to move the storage code to the only fragment that uses it - just like how the number of columns is stored directly in the subscription fragment. This also decouples the different components of the app from each other.
core/src/main/java/de/danoeh/antennapod/core/storage/DBReader.java
Outdated
Show resolved
Hide resolved
items.add(drawerItem); | ||
continue; | ||
} | ||
feedCounters.get(feed.getId()), playedCounters.get(feed.getId(), -1), recentPubDate); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This means that AntennaPod always needs to do 2 additional SQL queries that could potentially affect all episodes. Seems like it could cause performance problems. The app is rather sluggish with >150 subscriptions already.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was trying to extract the sorting logic to a sepearate class, but it was coupled with the adapter. I noticed that you had members in the NavDrawerData class to hold them. So I thought maybe will could store them in those, which does work. But didn't realize the performance overhead. The queries are rather complex.
I guess I could pass in the adapter into the sorter class instead. Would that work for you?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess I could pass in the adapter into the sorter class instead. Would that work for you?
Hmm, not really happy with that either, to be honest. The database stuff shouldn't be passed over to the UI. How about introducing a getFilteredSubscriptions
method to DbReader
(that is also used internally by getNavDrawerData
) that takes a SubscriptionsFilter
as a parameter? That filter could then contain information about tags. Then the fragment does not need to do any filtering.
@@ -31,6 +38,7 @@ | |||
*/ | |||
@SuppressWarnings("ConstantConditions") | |||
@RunWith(RobolectricTestRunner.class) | |||
@Config(sdk = {Build.VERSION_CODES.O_MR1}) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why? Looks like you need to update your local Java install instead (I think API30 is only supported on Java 9+)
|
||
public void setTags(Set<String> tags) { | ||
Set<String> newTags = new HashSet<>(); | ||
newTags.addAll(this.tags); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This adds tags, it doesn't set them
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, i know. Is this not okay?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it is only used for testing.
I'll remove it
Yeah, I know. Mostly doing this as a mock up. I hope to replace it with an rotating arrow button as discussed in #5318
Yes, i left this out as well. Will implement now
This was suggested by one of the users and favored by @keunes. I also like this design too. I think if we improve the design of it, it can work. The purpose for two is the first shows the selected tags and the second shows all the tags. The second one is shown when user clicks the more button. From the second, the user can update the selected tags.
Yeah, we still need to work on the design. I was hoping to have it resemble the mock up shown in #5318.
Do you mean reset the tag filter to 'All' when the filter is changed?
Must be a bug. Thanks for finding it.
Filtering requesting reloading all the feeds from the db, so the whole fragment and recyclerview is recreated. Removing and adding tags doesn't only requires updating the recyclerview which provides an update animation.
But i think it helps with discoverability. Maybe when the user clicks on more, if not tags are stored, instead of showing the second tag list a message telling them how to add tags can be displayed. For example, 'There are currently no tags. To add tags go to podcast settings, and can click on tag settings. |
As I understood it, the idea was to have one expanding list when having more tags than what fits on the screen - not two lists. This "duplicate" tag bar basically eliminates the advantage of the tag bars: When you want to change the tags, you always have to do two taps.
When just loading the new list contents into the RecyclerView, it should animate. Maybe the IDs are somehow not persistent.
The most important thing for new users is to subscribe and listen to podcasts. Tags only become relevant when you have dozens of subscriptions - before that, they are just additional visual clutter that people need to deal with. Discoverability is already achieved by having a pretty prominent long-press menu item. I wonder if it should be possible to select multiple tags. Only selecting one tag at a time is just as powerful and saves one click. |
I don't think it eliminates the advantage: sure, it might require an extra click. But if we used a dialog or somewhere similar, it would still require more clicks. And it is a lot cleaner and less decluttered to display only the selected tags and display all of them when needed. This is quoted from the OP of #5318:
The only detail that differs is that the top tags do not wrap when tags span more than the visible area.
Yeah, that is a good point. I'll add this suggestion.
Selecting one tag is powerful, but not as powerful or flexible as selecting multiple tags. To be honest, i don't know why, but I completely neglecting if thinking about only selecting one tag, when I implemented it I just assumed that users should be able to select multiple tags. The former probably would have been easier ;). After thinking over again, I really do think we should let users be able to select multiple tags. I mean, it is already built into the implementation. And selecting one tag is already a subfeature of being able to include multiple tags. It is only a plus. Also, consider this use case. Let's say you have a set of podcasts in different groups that you actively listen to, and you have one or a few others you don't. For the groups you actively listen to you can select them and have the app always show those. This would be nearly impossible by only being able to select one tag at a time. Maybe if you only had 2 groups, but that would defeat the purpose of having groups. Maybe it's probably easier to think of selecting multiple tags as a filter where you can add and modify the feeds shown based on which tags are selected, not just selecting one at a time as if they were separate lists. |
I understood this to be a single list that shows/hides the non-selected tags. I think having a single list would already help to no longer make it feel like an editor screen. Also, showing two lists makes you see the selected tags twice. Thinking about this more, I am no longer really a fan of having an expanding list. My original idea why I suggested a tag bar was the following:
The tag bar is supposed to be a quick way to switch between tags. If the tag bar is not quick and needs something like 4 taps to change to another tag (expand, de-select one, select the other, collapse), we can just make it a dialog and have more screen space for the actual subscriptions. I will copy this to the issue for discussion. |
@ByteHamster So do we just have one single bar that fades the tags that don't fit? |
I would say a single bar that can be expanded if it is too long. Selected items are moved to the front. Still, I am not 100% sure about the fact that selecting multi-selects - this makes selecting a lot more clicks. |
I say we just let the user scroll if it is too long. Many apps including Youtube do the same. The expanding bar idea was brought up by a user who disliked horizontal scrolling. I don't think we should always try to accommodate the request of a single user especially when there are no user studies to support it. Well, i am the sole developer implementing it, so I think I my opinion counts ;) I say we keep multi select for tags. Yes, UX should limit the number of actions needed to accomplish a task, but it alos depends on how often that task is done. For common tasks, it matters. However, the user will not always be using the tag bar everytime they open the app. In fact, the only users would probably be power users with many subscribed podcasts. And I think power users will appreciate the added ability to multi select. Also, it only increases the clicks by at most one. Users can just click on 'All' to reset the selected tags. So it only requires at most one more click. @keunes what do you think? |
This would be an argument for not using a tag bar but a tag dialog, leaving more space for the actual subscriptions. |
Well, we already decided on using a tag bar based on previous discussions and have already started working on the tag bar. If you ask me, pretty unwise to turn around and decide to do a dialog. Let's just do the tag bar with horizontal scrolling and multiselect. Your main objection to multiselect was that it requires more clicks, but that isn't true as I stated above. |
Are you still interested in working on this, @peakvalleytech? |
Sure, how would you like to proceed? It's been a while |
I would argue for going for a list, as proposed before and already largely implemented (from what I gather from the conversation - I haven't tried a debug build): I can also imagine this without horizontal scrolling, and instead take as much space as necessary vertically (full screen with vertical scrolling if more than 1/3 of the screen would be occupied). This may indeed be easier if you have a lot of tags. From what I read in earlier feedback, there are two main points that @ByteHamster mentioned that I think would need to be addressed to get the original proposal:
In my mock-up, I didn't have a text-based but icon-based button. Implementing that would address the first point.
Is it that if you tap two tags, both get selected, rather than switching from tag A to B? If that's what you meant, @ByteHamster: I agree with @peakvalleytech that it would be nice to be able to have the option of multi-select.
Curious what you both think of this proposal Are there any other major points under discussion? |
I like that!
Yeah, it was partly also because I envisioned two lines - the single downward arrow for two lines looked odd. But if we go for a single line as you proposed above, then indeed just the arrow will work nice.
Great! |
I wonder if we should continue displaying the tags in the grid when no tag (from the selector on top) is selected. It could be helpful to see them all at once when starting the app. Also, it would mean that users can still keep using the app like it is without having to change their muscle memory. |
To me that sounds like duplicating navigation.
Tags have been there so short that I think very few users will have developed muscle memory. |
What do we then show when no tag is selected and a user un-checked "show in main list" from all subscriptions? An empty screen? I just noticed that long-press-to-select conflicts with long-press-to-rename. So maybe we cannot actually do long-press-to-select. |
This pull request has been mentioned on AntennaPod Forum. There might be relevant details there: https://forum.antennapod.org/t/folder-logo-as-collage-of-subscriptions/1682/2 |
The default state should be to have an overview of all podcasts, without having to multi-select each of the tags (which would be bad UX IMHO). I would go for either of these options:
(I would go for the first. I think it'd be a better UX if 'show in main list' would be made redundant, by a) adding an automatic section 'not tagged' and b) allowing users to switch on & off the main & tag list separately. The first option is easier to implement for now and does not lead to unexpected behaviour changes, e.g. when the user removes the last 'show in main list'.)
The action that is available through long-press should be the one that is used second-most. That would be multi-select. Changing tag names can be accessible from the settings (where it should also be possible to delete them). @ByteHamster @peakvalleytech What d'you think? |
Hello, sorry, i'm late. I've changed my stance on how it should be designed.
|
I would go with the second suggestion. I am using an "Archive" folder and remove the "show in main list" from these subscriptions. Simply showing all, even when the "show in main list" box is unchecked, basically makes the use-case of an archive folder impossible.
Hmm, not completely happy about that. I like the fact that AntennaPod currently separates between app content and (behavior-like) app preferences.
I agree. That's the easiest option and users are already used to that pattern from sites like YouTube.
I think the expanded view can be added relatively easy later when needed. It just needs another layout manager for the @peakvalleytech would you be up for adapting your PR accordingly (and rebasing it)? |
Are you still interested in this PR, @peakvalleytech? |
This PR will be closed when we don't get a reply within 15 days. |
This PR was closed because we didn't get a reply for 30 days. |
Fixes #5318